Skip to content

Commit 28633f4

Browse files
committed
Add swipeable option, add fullscreen mode and color of overlay
1 parent 9c32f66 commit 28633f4

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

README.MD

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,9 @@ Vue.use(VueBottomSheet);
7070
| max-height | String | Set max-height of component card | `max-height="90%"` |
7171
| effect | String | Set effect for component card | `effect="fx-fadein-scale"` |
7272
| rounded | Boolean | Round the top two corners of the sheet | `:rounded="false"` |
73+
| is-full-screen | Boolean | Enable or disable full-screen mode | `:is-full-screen="true"` |
74+
| swipe-able | Boolean | Enable or disable swipe to close | `:swipe-able="false"` |
75+
| overlay-color | Boolean | Set overlay color with opacity | `:overlay-color="#0000004D"` |
7376

7477
## Events
7578

README_RU.MD

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,9 @@ Vue.use(VueBottomSheet);
6969
| max-height | String | Устанавливает максимальную высоту карточки компонента | `max-height="90%"` |
7070
| effect | String | Устанавливает эффект появление карточки компонента | `effect="fx-fadein-scale"` |
7171
| rounded | Boolean | Включает скругление 2 верхних углов компонента | `:rounded="false"` |
72+
| is-full-screen | Boolean | Включает и выключает полноэкранный режим | `:is-full-screen="true"` |
73+
| swipe-able | Boolean | Включает и выключает возможность закрытия окна свайпом | `:swipe-able="false"` |
74+
| overlay-color | Boolean | Задаёт цвет оверлея | `:overlay-color="#0000004D"` |
7275

7376
## События
7477

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@webzlodimir/vue-bottom-sheet",
3-
"version": "1.2.3",
3+
"version": "1.2.4",
44
"description": "",
55
"repository": {
66
"type": "git",

src/vue-bottom-sheet.vue

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,6 @@ export default {
108108
move(event, type) {
109109
if (this.swipeAble) {
110110
let delta = -event.deltaY;
111-
if (type === "content" && this.contentScroll === 0) {
112-
type = "pan";
113-
}
114111
if (
115112
(type === 'content' && event.type === 'panup') ||
116113
(type === 'content' && event.type === 'pandown' && this.contentScroll > 0)

0 commit comments

Comments
 (0)