vant 4.9.20 → 4.9.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/es/action-bar-button/index.css +1 -1
- package/es/action-sheet/ActionSheet.d.ts +1 -1
- package/es/action-sheet/index.d.ts +1 -1
- package/es/address-list/AddressListItem.d.ts +1 -1
- package/es/area/Area.d.ts +1 -1
- package/es/area/index.d.ts +1 -1
- package/es/calendar/index.css +1 -1
- package/es/checkbox/Checker.mjs +1 -1
- package/es/composables/on-popup-reopen.mjs +1 -1
- package/es/composables/use-tab-status.d.ts +3 -0
- package/es/composables/use-tab-status.mjs +17 -2
- package/es/composables/use-touch.mjs +4 -4
- package/es/date-picker/DatePicker.d.ts +1 -1
- package/es/date-picker/index.d.ts +1 -1
- package/es/dialog/Dialog.d.ts +1 -1
- package/es/dialog/index.css +1 -1
- package/es/dialog/index.d.ts +1 -1
- package/es/field/Field.d.ts +5 -5
- package/es/field/Field.mjs +3 -3
- package/es/field/index.d.ts +3 -3
- package/es/field/types.d.ts +1 -0
- package/es/floating-bubble/FloatingBubble.d.ts +3 -22
- package/es/floating-bubble/FloatingBubble.mjs +3 -9
- package/es/floating-bubble/index.d.ts +2 -15
- package/es/floating-panel/FloatingPanel.d.ts +13 -0
- package/es/floating-panel/FloatingPanel.mjs +14 -2
- package/es/floating-panel/index.d.ts +9 -0
- package/es/grid/Grid.d.ts +1 -1
- package/es/grid/index.d.ts +1 -1
- package/es/index.d.ts +1 -1
- package/es/index.mjs +1 -1
- package/es/list/List.d.ts +13 -3
- package/es/list/List.mjs +7 -4
- package/es/list/index.d.ts +9 -2
- package/es/picker/Picker.d.ts +1 -1
- package/es/picker/index.d.ts +1 -1
- package/es/progress/Progress.mjs +6 -3
- package/es/search/Search.d.ts +4 -4
- package/es/search/Search.mjs +1 -0
- package/es/search/index.d.ts +3 -3
- package/es/share-sheet/ShareSheet.d.ts +1 -1
- package/es/share-sheet/index.d.ts +1 -1
- package/es/stepper/Stepper.mjs +3 -0
- package/es/tab/Tab.mjs +3 -3
- package/es/tab/index.d.ts +1 -0
- package/es/tab/index.mjs +4 -1
- package/es/tabs/Tabs.d.ts +1 -1
- package/es/tabs/index.d.ts +1 -1
- package/es/time-picker/TimePicker.d.ts +1 -1
- package/es/time-picker/TimePicker.mjs +1 -1
- package/es/time-picker/index.d.ts +1 -1
- package/es/utils/constant.mjs +1 -1
- package/lib/action-bar-button/index.css +1 -1
- package/lib/action-sheet/ActionSheet.d.ts +1 -1
- package/lib/action-sheet/index.d.ts +1 -1
- package/lib/address-list/AddressListItem.d.ts +1 -1
- package/lib/area/Area.d.ts +1 -1
- package/lib/area/index.d.ts +1 -1
- package/lib/calendar/index.css +1 -1
- package/lib/checkbox/Checker.js +1 -1
- package/lib/composables/on-popup-reopen.js +1 -1
- package/lib/composables/use-tab-status.d.ts +3 -0
- package/lib/composables/use-tab-status.js +16 -1
- package/lib/composables/use-touch.js +4 -4
- package/lib/date-picker/DatePicker.d.ts +1 -1
- package/lib/date-picker/index.d.ts +1 -1
- package/lib/dialog/Dialog.d.ts +1 -1
- package/lib/dialog/index.css +1 -1
- package/lib/dialog/index.d.ts +1 -1
- package/lib/field/Field.d.ts +5 -5
- package/lib/field/Field.js +3 -3
- package/lib/field/index.d.ts +3 -3
- package/lib/field/types.d.ts +1 -0
- package/lib/floating-bubble/FloatingBubble.d.ts +3 -22
- package/lib/floating-bubble/FloatingBubble.js +3 -9
- package/lib/floating-bubble/index.d.ts +2 -15
- package/lib/floating-panel/FloatingPanel.d.ts +13 -0
- package/lib/floating-panel/FloatingPanel.js +14 -2
- package/lib/floating-panel/index.d.ts +9 -0
- package/lib/grid/Grid.d.ts +1 -1
- package/lib/grid/index.d.ts +1 -1
- package/lib/index.css +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/list/List.d.ts +13 -3
- package/lib/list/List.js +6 -3
- package/lib/list/index.d.ts +9 -2
- package/lib/picker/Picker.d.ts +1 -1
- package/lib/picker/index.d.ts +1 -1
- package/lib/progress/Progress.js +6 -3
- package/lib/search/Search.d.ts +4 -4
- package/lib/search/Search.js +1 -0
- package/lib/search/index.d.ts +3 -3
- package/lib/share-sheet/ShareSheet.d.ts +1 -1
- package/lib/share-sheet/index.d.ts +1 -1
- package/lib/stepper/Stepper.js +3 -0
- package/lib/tab/Tab.js +1 -1
- package/lib/tab/index.d.ts +1 -0
- package/lib/tab/index.js +4 -1
- package/lib/tabs/Tabs.d.ts +1 -1
- package/lib/tabs/index.d.ts +1 -1
- package/lib/time-picker/TimePicker.d.ts +1 -1
- package/lib/time-picker/TimePicker.js +1 -1
- package/lib/time-picker/index.d.ts +1 -1
- package/lib/utils/constant.js +1 -1
- package/lib/vant.cjs.js +57 -27
- package/lib/vant.es.js +57 -27
- package/lib/vant.js +65 -35
- package/lib/vant.min.js +3 -3
- package/lib/web-types.json +1 -1
- package/package.json +12 -12
package/README.md
CHANGED
|
@@ -129,9 +129,9 @@ Vant 3/4 supports modern browsers and Chrome >= 51、iOS >= 10.0 (same as Vue 3)
|
|
|
129
129
|
| [vant-playground](https://github.com/LadyChatterleyLover/vant-playground) | Vant Playground |
|
|
130
130
|
| [sfc-playground-vant](https://github.com/zhixiaoqiang/sfc-playground-vant) | Vant Playground |
|
|
131
131
|
| [vue3-h5-template](https://github.com/yulimchen/vue3-h5-template) | Mobile project template based on Vant |
|
|
132
|
-
| [vue3-vant-mobile](https://github.com/
|
|
132
|
+
| [vue3-vant-mobile](https://github.com/vue-zone/vue3-vant-mobile) | Mobile project template based on Vant, out of the box |
|
|
133
133
|
| [vscode-common-intellisense](https://github.com/Simon-He95/vscode-common-intellisense) | A VS Code extension that provides better intellisense to Vant developers |
|
|
134
|
-
| [nuxt-vant-mobile](https://github.com/
|
|
134
|
+
| [nuxt-vant-mobile](https://github.com/vue-zone/nuxt-vant-mobile) | Nuxt _⁴_ project template based on Vant, out of the box |
|
|
135
135
|
| [mobvue](https://github.com/un-pany/mobvue) | A well-crafted mobile web app template |
|
|
136
136
|
| [novlan1/press-ui](https://github.com/novlan1/press-ui) | Uni APP mobile UI Components based on Vant |
|
|
137
137
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
:root,:host{--van-action-bar-button-height: 40px;--van-action-bar-button-warning-color: var(--van-gradient-orange);--van-action-bar-button-danger-color: var(--van-gradient-red)}.van-action-bar-button{flex:1;height:var(--van-action-bar-button-height);font-weight:var(--van-font-bold);font-size:var(--van-font-size-md);border:none;border-radius:0}.van-action-bar-button--first{margin-left:5px;border-top-left-radius:var(--van-radius-max);border-bottom-left-radius:var(--van-radius-max)}.van-action-bar-button--last{margin-right:5px;border-top-right-radius:var(--van-radius-max);border-bottom-right-radius:var(--van-radius-max)}.van-action-bar-button--warning{background:var(--van-action-bar-button-warning-color)}.van-action-bar-button--danger{background:var(--van-action-bar-button-danger-color)}@media
|
|
1
|
+
:root,:host{--van-action-bar-button-height: 40px;--van-action-bar-button-warning-color: var(--van-gradient-orange);--van-action-bar-button-danger-color: var(--van-gradient-red)}.van-action-bar-button{flex:1;height:var(--van-action-bar-button-height);font-weight:var(--van-font-bold);font-size:var(--van-font-size-md);border:none;border-radius:0}.van-action-bar-button--first{margin-left:5px;border-top-left-radius:var(--van-radius-max);border-bottom-left-radius:var(--van-radius-max)}.van-action-bar-button--last{margin-right:5px;border-top-right-radius:var(--van-radius-max);border-bottom-right-radius:var(--van-radius-max)}.van-action-bar-button--warning{background:var(--van-action-bar-button-warning-color)}.van-action-bar-button--danger{background:var(--van-action-bar-button-danger-color)}@media(max-width:321px){.van-action-bar-button{font-size:13px}}
|
|
@@ -178,8 +178,8 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
178
178
|
};
|
|
179
179
|
}>> & Readonly<{
|
|
180
180
|
onSelect?: ((...args: any[]) => any) | undefined;
|
|
181
|
-
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
182
181
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
182
|
+
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
183
183
|
}>, {
|
|
184
184
|
round: boolean;
|
|
185
185
|
overlay: boolean;
|
|
@@ -110,8 +110,8 @@ export declare const ActionSheet: import("../utils").WithInstall<import("vue").D
|
|
|
110
110
|
};
|
|
111
111
|
}>> & Readonly<{
|
|
112
112
|
onSelect?: ((...args: any[]) => any) | undefined;
|
|
113
|
-
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
114
113
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
114
|
+
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
115
115
|
}>, {
|
|
116
116
|
round: boolean;
|
|
117
117
|
overlay: boolean;
|
|
@@ -34,8 +34,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
34
34
|
default: string;
|
|
35
35
|
};
|
|
36
36
|
}>> & Readonly<{
|
|
37
|
-
onClick?: ((...args: any[]) => any) | undefined;
|
|
38
37
|
onSelect?: ((...args: any[]) => any) | undefined;
|
|
38
|
+
onClick?: ((...args: any[]) => any) | undefined;
|
|
39
39
|
onEdit?: ((...args: any[]) => any) | undefined;
|
|
40
40
|
}>, {
|
|
41
41
|
disabled: boolean;
|
package/es/area/Area.d.ts
CHANGED
|
@@ -118,8 +118,8 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<import(".
|
|
|
118
118
|
};
|
|
119
119
|
}>> & Readonly<{
|
|
120
120
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
121
|
-
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
122
121
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
122
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
123
123
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
124
124
|
}>, {
|
|
125
125
|
readonly: boolean;
|
package/es/area/index.d.ts
CHANGED
|
@@ -76,8 +76,8 @@ export declare const Area: import("../utils").WithInstall<import("vue").DefineCo
|
|
|
76
76
|
};
|
|
77
77
|
}>> & Readonly<{
|
|
78
78
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
79
|
-
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
80
79
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
80
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
81
81
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
82
82
|
}>, {
|
|
83
83
|
readonly: boolean;
|
package/es/calendar/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
:root,:host{--van-calendar-background: var(--van-background-2);--van-calendar-popup-height: 80%;--van-calendar-header-shadow: 0 2px 10px rgba(125, 126, 128, .16);--van-calendar-header-title-height: 44px;--van-calendar-header-title-font-size: var(--van-font-size-lg);--van-calendar-header-subtitle-font-size: var(--van-font-size-md);--van-calendar-header-action-width: 28px;--van-calendar-header-action-color: var(--van-text-color);--van-calendar-header-action-disabled-color: var(--van-text-color-3);--van-calendar-weekdays-height: 30px;--van-calendar-weekdays-font-size: var(--van-font-size-sm);--van-calendar-month-title-font-size: var(--van-font-size-md);--van-calendar-month-mark-color: rgba(242, 243, 245, .8);--van-calendar-month-mark-font-size: 160px;--van-calendar-day-height: 64px;--van-calendar-day-font-size: var(--van-font-size-lg);--van-calendar-day-margin-bottom: 4px;--van-calendar-day-disabled-color: var(--van-text-color-3);--van-calendar-range-edge-color: var(--van-white);--van-calendar-range-edge-background: var(--van-primary-color);--van-calendar-range-middle-color: var(--van-primary-color);--van-calendar-range-middle-background-opacity: .1;--van-calendar-selected-day-size: 54px;--van-calendar-selected-day-color: var(--van-white);--van-calendar-selected-day-background: var(--van-primary-color);--van-calendar-info-font-size: var(--van-font-size-xs);--van-calendar-info-line-height: var(--van-line-height-xs);--van-calendar-confirm-button-height: 36px;--van-calendar-confirm-button-margin: 7px 0}.van-theme-dark{--van-calendar-month-mark-color: rgba(100, 101, 102, .2);--van-calendar-day-disabled-color: var(--van-gray-7)}.van-calendar{display:flex;flex-direction:column;height:100%;background:var(--van-calendar-background)}.van-calendar__popup.van-popup--top,.van-calendar__popup.van-popup--bottom{height:var(--van-calendar-popup-height)}.van-calendar__popup.van-popup--left,.van-calendar__popup.van-popup--right{height:100%}.van-calendar__popup .van-popup__close-icon{top:11px}.van-calendar__header{flex-shrink:0;box-shadow:var(--van-calendar-header-shadow)}.van-calendar__month-title,.van-calendar__header-title,.van-calendar__header-subtitle{color:var(--van-text-color);height:var(--van-calendar-header-title-height);font-weight:var(--van-font-bold);line-height:var(--van-calendar-header-title-height);text-align:center}.van-calendar__header-title{font-size:var(--van-calendar-header-title-font-size)}.van-calendar__header-subtitle{font-size:var(--van-calendar-header-subtitle-font-size)}.van-calendar__header-subtitle--with-switch{display:flex;align-items:center;padding:0 var(--van-padding-base)}.van-calendar__header-subtitle-text{flex:1}.van-calendar__header-action{display:flex;align-items:center;justify-content:center;min-width:var(--van-calendar-header-action-width);height:100%;color:var(--van-calendar-header-action-color);cursor:pointer}.van-calendar__header-action--disabled{color:var(--van-calendar-header-action-disabled-color);cursor:not-allowed}.van-calendar__month-title{font-size:var(--van-calendar-month-title-font-size)}.van-calendar__weekdays{display:flex}.van-calendar__weekday{flex:1;font-size:var(--van-calendar-weekdays-font-size);line-height:var(--van-calendar-weekdays-height);text-align:center}.van-calendar__body{flex:1;overflow:auto;-webkit-overflow-scrolling:touch}.van-calendar__days{position:relative;display:flex;flex-wrap:wrap;-webkit-user-select:none;user-select:none}.van-calendar__month-mark{position:absolute;top:50%;left:50%;z-index:0;color:var(--van-calendar-month-mark-color);font-size:var(--van-calendar-month-mark-font-size);transform:translate(-50%,-50%);pointer-events:none}.van-calendar__day,.van-calendar__selected-day{display:flex;align-items:center;justify-content:center;text-align:center}.van-calendar__day{position:relative;width:14.285%;height:var(--van-calendar-day-height);font-size:var(--van-calendar-day-font-size);margin-bottom:var(--van-calendar-day-margin-bottom);cursor:pointer}.van-calendar__day--end,.van-calendar__day--start,.van-calendar__day--start-end,.van-calendar__day--multiple-middle,.van-calendar__day--multiple-selected{color:var(--van-calendar-range-edge-color);background:var(--van-calendar-range-edge-background)}.van-calendar__day--start{border-radius:var(--van-radius-md) 0 0 var(--van-radius-md)}.van-calendar__day--end{border-radius:0 var(--van-radius-md) var(--van-radius-md) 0}.van-calendar__day--start-end,.van-calendar__day--multiple-selected{border-radius:var(--van-radius-md)}.van-calendar__day--middle{color:var(--van-calendar-range-middle-color)}.van-calendar__day--middle:after{position:absolute;top:0;right:0;bottom:0;left:0;background-color:currentColor;opacity:var(--van-calendar-range-middle-background-opacity);content:""}.van-calendar__day--disabled{color:var(--van-calendar-day-disabled-color);cursor:default}.van-calendar__top-info,.van-calendar__bottom-info{position:absolute;right:0;left:0;font-size:var(--van-calendar-info-font-size);line-height:var(--van-calendar-info-line-height)}@media
|
|
1
|
+
:root,:host{--van-calendar-background: var(--van-background-2);--van-calendar-popup-height: 80%;--van-calendar-header-shadow: 0 2px 10px rgba(125, 126, 128, .16);--van-calendar-header-title-height: 44px;--van-calendar-header-title-font-size: var(--van-font-size-lg);--van-calendar-header-subtitle-font-size: var(--van-font-size-md);--van-calendar-header-action-width: 28px;--van-calendar-header-action-color: var(--van-text-color);--van-calendar-header-action-disabled-color: var(--van-text-color-3);--van-calendar-weekdays-height: 30px;--van-calendar-weekdays-font-size: var(--van-font-size-sm);--van-calendar-month-title-font-size: var(--van-font-size-md);--van-calendar-month-mark-color: rgba(242, 243, 245, .8);--van-calendar-month-mark-font-size: 160px;--van-calendar-day-height: 64px;--van-calendar-day-font-size: var(--van-font-size-lg);--van-calendar-day-margin-bottom: 4px;--van-calendar-day-disabled-color: var(--van-text-color-3);--van-calendar-range-edge-color: var(--van-white);--van-calendar-range-edge-background: var(--van-primary-color);--van-calendar-range-middle-color: var(--van-primary-color);--van-calendar-range-middle-background-opacity: .1;--van-calendar-selected-day-size: 54px;--van-calendar-selected-day-color: var(--van-white);--van-calendar-selected-day-background: var(--van-primary-color);--van-calendar-info-font-size: var(--van-font-size-xs);--van-calendar-info-line-height: var(--van-line-height-xs);--van-calendar-confirm-button-height: 36px;--van-calendar-confirm-button-margin: 7px 0}.van-theme-dark{--van-calendar-month-mark-color: rgba(100, 101, 102, .2);--van-calendar-day-disabled-color: var(--van-gray-7)}.van-calendar{display:flex;flex-direction:column;height:100%;background:var(--van-calendar-background)}.van-calendar__popup.van-popup--top,.van-calendar__popup.van-popup--bottom{height:var(--van-calendar-popup-height)}.van-calendar__popup.van-popup--left,.van-calendar__popup.van-popup--right{height:100%}.van-calendar__popup .van-popup__close-icon{top:11px}.van-calendar__header{flex-shrink:0;box-shadow:var(--van-calendar-header-shadow)}.van-calendar__month-title,.van-calendar__header-title,.van-calendar__header-subtitle{color:var(--van-text-color);height:var(--van-calendar-header-title-height);font-weight:var(--van-font-bold);line-height:var(--van-calendar-header-title-height);text-align:center}.van-calendar__header-title{font-size:var(--van-calendar-header-title-font-size)}.van-calendar__header-subtitle{font-size:var(--van-calendar-header-subtitle-font-size)}.van-calendar__header-subtitle--with-switch{display:flex;align-items:center;padding:0 var(--van-padding-base)}.van-calendar__header-subtitle-text{flex:1}.van-calendar__header-action{display:flex;align-items:center;justify-content:center;min-width:var(--van-calendar-header-action-width);height:100%;color:var(--van-calendar-header-action-color);cursor:pointer}.van-calendar__header-action--disabled{color:var(--van-calendar-header-action-disabled-color);cursor:not-allowed}.van-calendar__month-title{font-size:var(--van-calendar-month-title-font-size)}.van-calendar__weekdays{display:flex}.van-calendar__weekday{flex:1;font-size:var(--van-calendar-weekdays-font-size);line-height:var(--van-calendar-weekdays-height);text-align:center}.van-calendar__body{flex:1;overflow:auto;-webkit-overflow-scrolling:touch}.van-calendar__days{position:relative;display:flex;flex-wrap:wrap;-webkit-user-select:none;user-select:none}.van-calendar__month-mark{position:absolute;top:50%;left:50%;z-index:0;color:var(--van-calendar-month-mark-color);font-size:var(--van-calendar-month-mark-font-size);transform:translate(-50%,-50%);pointer-events:none}.van-calendar__day,.van-calendar__selected-day{display:flex;align-items:center;justify-content:center;text-align:center}.van-calendar__day{position:relative;width:14.285%;height:var(--van-calendar-day-height);font-size:var(--van-calendar-day-font-size);margin-bottom:var(--van-calendar-day-margin-bottom);cursor:pointer}.van-calendar__day--end,.van-calendar__day--start,.van-calendar__day--start-end,.van-calendar__day--multiple-middle,.van-calendar__day--multiple-selected{color:var(--van-calendar-range-edge-color);background:var(--van-calendar-range-edge-background)}.van-calendar__day--start{border-radius:var(--van-radius-md) 0 0 var(--van-radius-md)}.van-calendar__day--end{border-radius:0 var(--van-radius-md) var(--van-radius-md) 0}.van-calendar__day--start-end,.van-calendar__day--multiple-selected{border-radius:var(--van-radius-md)}.van-calendar__day--middle{color:var(--van-calendar-range-middle-color)}.van-calendar__day--middle:after{position:absolute;top:0;right:0;bottom:0;left:0;background-color:currentColor;opacity:var(--van-calendar-range-middle-background-opacity);content:""}.van-calendar__day--disabled{color:var(--van-calendar-day-disabled-color);cursor:default}.van-calendar__top-info,.van-calendar__bottom-info{position:absolute;right:0;left:0;font-size:var(--van-calendar-info-font-size);line-height:var(--van-calendar-info-line-height)}@media(max-width:350px){.van-calendar__top-info,.van-calendar__bottom-info{font-size:9px}}.van-calendar__top-info{top:6px}.van-calendar__bottom-info{bottom:6px}.van-calendar__selected-day{width:var(--van-calendar-selected-day-size);height:var(--van-calendar-selected-day-size);color:var(--van-calendar-selected-day-color);background:var(--van-calendar-selected-day-background);border-radius:var(--van-radius-md)}.van-calendar__footer{flex-shrink:0;padding-left:var(--van-padding-md);padding-right:var(--van-padding-md)}.van-calendar__confirm{height:var(--van-calendar-confirm-button-height);margin:var(--van-calendar-confirm-button-margin)}
|
package/es/checkbox/Checker.mjs
CHANGED
|
@@ -50,7 +50,7 @@ var stdin_default = defineComponent({
|
|
|
50
50
|
const direction = computed(() => getParentProp("direction"));
|
|
51
51
|
const iconStyle = computed(() => {
|
|
52
52
|
const checkedColor = props.checkedColor || getParentProp("checkedColor");
|
|
53
|
-
if (checkedColor && props.checked && !disabled.value) {
|
|
53
|
+
if (checkedColor && (props.checked || props.indeterminate) && !disabled.value) {
|
|
54
54
|
return {
|
|
55
55
|
borderColor: checkedColor,
|
|
56
56
|
backgroundColor: checkedColor
|
|
@@ -1,3 +1,6 @@
|
|
|
1
1
|
import { ComputedRef, InjectionKey } from 'vue';
|
|
2
2
|
export declare const TAB_STATUS_KEY: InjectionKey<ComputedRef<boolean>>;
|
|
3
|
+
export declare const ALL_TAB_STATUS_KEY: InjectionKey<ComputedRef<boolean>>;
|
|
3
4
|
export declare const useTabStatus: () => ComputedRef<boolean> | null;
|
|
5
|
+
export declare const useAllTabStatus: () => ComputedRef<boolean> | null;
|
|
6
|
+
export declare const useProvideTabStatus: (status: ComputedRef<boolean>) => void;
|
|
@@ -1,7 +1,22 @@
|
|
|
1
|
-
import { inject } from "vue";
|
|
2
|
-
const TAB_STATUS_KEY = Symbol();
|
|
1
|
+
import { inject, provide, computed } from "vue";
|
|
2
|
+
const TAB_STATUS_KEY = /* @__PURE__ */ Symbol();
|
|
3
|
+
const ALL_TAB_STATUS_KEY = /* @__PURE__ */ Symbol();
|
|
3
4
|
const useTabStatus = () => inject(TAB_STATUS_KEY, null);
|
|
5
|
+
const useAllTabStatus = () => inject(ALL_TAB_STATUS_KEY, null);
|
|
6
|
+
const useProvideTabStatus = (status) => {
|
|
7
|
+
const allTabStatus = useAllTabStatus();
|
|
8
|
+
provide(TAB_STATUS_KEY, status);
|
|
9
|
+
provide(
|
|
10
|
+
ALL_TAB_STATUS_KEY,
|
|
11
|
+
computed(() => {
|
|
12
|
+
return (allTabStatus == null || allTabStatus.value) && status.value;
|
|
13
|
+
})
|
|
14
|
+
);
|
|
15
|
+
};
|
|
4
16
|
export {
|
|
17
|
+
ALL_TAB_STATUS_KEY,
|
|
5
18
|
TAB_STATUS_KEY,
|
|
19
|
+
useAllTabStatus,
|
|
20
|
+
useProvideTabStatus,
|
|
6
21
|
useTabStatus
|
|
7
22
|
};
|
|
@@ -28,12 +28,12 @@ function useTouch() {
|
|
|
28
28
|
direction.value = "";
|
|
29
29
|
isTap.value = true;
|
|
30
30
|
};
|
|
31
|
-
const start = (event) => {
|
|
31
|
+
const start = ((event) => {
|
|
32
32
|
reset();
|
|
33
33
|
startX.value = event.touches[0].clientX;
|
|
34
34
|
startY.value = event.touches[0].clientY;
|
|
35
|
-
};
|
|
36
|
-
const move = (event) => {
|
|
35
|
+
});
|
|
36
|
+
const move = ((event) => {
|
|
37
37
|
const touch = event.touches[0];
|
|
38
38
|
deltaX.value = (touch.clientX < 0 ? 0 : touch.clientX) - startX.value;
|
|
39
39
|
deltaY.value = touch.clientY - startY.value;
|
|
@@ -46,7 +46,7 @@ function useTouch() {
|
|
|
46
46
|
if (isTap.value && (offsetX.value > TAP_OFFSET || offsetY.value > TAP_OFFSET)) {
|
|
47
47
|
isTap.value = false;
|
|
48
48
|
}
|
|
49
|
-
};
|
|
49
|
+
});
|
|
50
50
|
return {
|
|
51
51
|
move,
|
|
52
52
|
start,
|
|
@@ -156,8 +156,8 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
156
156
|
};
|
|
157
157
|
}>> & Readonly<{
|
|
158
158
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
159
|
-
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
160
159
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
160
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
161
161
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
162
162
|
}>, {
|
|
163
163
|
formatter: (type: string, option: import("../picker").PickerOption) => import("../picker").PickerOption;
|
|
@@ -99,8 +99,8 @@ export declare const DatePicker: import("../utils").WithInstall<import("vue").De
|
|
|
99
99
|
};
|
|
100
100
|
}>> & Readonly<{
|
|
101
101
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
102
|
-
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
103
102
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
103
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
104
104
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
105
105
|
}>, {
|
|
106
106
|
formatter: (type: string, option: import("..").PickerOption) => import("..").PickerOption;
|
package/es/dialog/Dialog.d.ts
CHANGED
|
@@ -184,8 +184,8 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
184
184
|
destroyOnClose: BooleanConstructor;
|
|
185
185
|
}>> & Readonly<{
|
|
186
186
|
onKeydown?: ((...args: any[]) => any) | undefined;
|
|
187
|
-
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
188
187
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
188
|
+
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
189
189
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
190
190
|
}>, {
|
|
191
191
|
overlay: boolean;
|
package/es/dialog/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
:root,:host{--van-dialog-width: 320px;--van-dialog-small-screen-width: 90%;--van-dialog-font-size: var(--van-font-size-lg);--van-dialog-transition: var(--van-duration-base);--van-dialog-radius: 16px;--van-dialog-background: var(--van-background-2);--van-dialog-header-font-weight: var(--van-font-bold);--van-dialog-header-line-height: 24px;--van-dialog-header-padding-top: 26px;--van-dialog-header-isolated-padding: var(--van-padding-lg) 0;--van-dialog-message-padding: var(--van-padding-lg);--van-dialog-message-font-size: var(--van-font-size-md);--van-dialog-message-line-height: var(--van-line-height-md);--van-dialog-message-max-height: 60vh;--van-dialog-has-title-message-text-color: var(--van-gray-7);--van-dialog-has-title-message-padding-top: var(--van-padding-xs);--van-dialog-button-height: 48px;--van-dialog-round-button-height: 36px;--van-dialog-confirm-button-text-color: var(--van-primary-color)}.van-dialog{top:45%;width:var(--van-dialog-width);overflow:hidden;font-size:var(--van-dialog-font-size);background:var(--van-dialog-background);border-radius:var(--van-dialog-radius);-webkit-backface-visibility:hidden;backface-visibility:hidden;transition:var(--van-dialog-transition);transition-property:transform,opacity}@media
|
|
1
|
+
:root,:host{--van-dialog-width: 320px;--van-dialog-small-screen-width: 90%;--van-dialog-font-size: var(--van-font-size-lg);--van-dialog-transition: var(--van-duration-base);--van-dialog-radius: 16px;--van-dialog-background: var(--van-background-2);--van-dialog-header-font-weight: var(--van-font-bold);--van-dialog-header-line-height: 24px;--van-dialog-header-padding-top: 26px;--van-dialog-header-isolated-padding: var(--van-padding-lg) 0;--van-dialog-message-padding: var(--van-padding-lg);--van-dialog-message-font-size: var(--van-font-size-md);--van-dialog-message-line-height: var(--van-line-height-md);--van-dialog-message-max-height: 60vh;--van-dialog-has-title-message-text-color: var(--van-gray-7);--van-dialog-has-title-message-padding-top: var(--van-padding-xs);--van-dialog-button-height: 48px;--van-dialog-round-button-height: 36px;--van-dialog-confirm-button-text-color: var(--van-primary-color)}.van-dialog{top:45%;width:var(--van-dialog-width);overflow:hidden;font-size:var(--van-dialog-font-size);background:var(--van-dialog-background);border-radius:var(--van-dialog-radius);-webkit-backface-visibility:hidden;backface-visibility:hidden;transition:var(--van-dialog-transition);transition-property:transform,opacity}@media(max-width:321px){.van-dialog{width:var(--van-dialog-small-screen-width)}}.van-dialog__header{color:var(--van-text-color);padding-top:var(--van-dialog-header-padding-top);font-weight:var(--van-dialog-header-font-weight);line-height:var(--van-dialog-header-line-height);text-align:center}.van-dialog__header--isolated{padding:var(--van-dialog-header-isolated-padding)}.van-dialog__content--isolated{display:flex;align-items:center;min-height:104px}.van-dialog__message{color:var(--van-text-color);flex:1;max-height:var(--van-dialog-message-max-height);padding:26px var(--van-dialog-message-padding);overflow-y:auto;font-size:var(--van-dialog-message-font-size);line-height:var(--van-dialog-message-line-height);white-space:pre-wrap;text-align:center;word-wrap:break-word;-webkit-overflow-scrolling:touch}.van-dialog__message--has-title{padding-top:var(--van-dialog-has-title-message-padding-top);color:var(--van-dialog-has-title-message-text-color)}.van-dialog__message--left{text-align:left}.van-dialog__message--right{text-align:right}.van-dialog__message--justify{text-align:justify}.van-dialog__footer{display:flex;overflow:hidden;-webkit-user-select:none;user-select:none}.van-dialog__confirm,.van-dialog__cancel{flex:1;height:var(--van-dialog-button-height);margin:0;border:0;border-radius:0}.van-dialog__confirm,.van-dialog__confirm:active{color:var(--van-dialog-confirm-button-text-color)}.van-dialog--round-button .van-dialog__footer{position:relative;height:auto;padding:var(--van-padding-xs) var(--van-padding-lg) var(--van-padding-md)}.van-dialog--round-button .van-dialog__message{padding-bottom:var(--van-padding-md);color:var(--van-text-color)}.van-dialog--round-button .van-dialog__confirm,.van-dialog--round-button .van-dialog__cancel{height:var(--van-dialog-round-button-height)}.van-dialog--round-button .van-dialog__confirm{color:var(--van-white)}.van-dialog--round-button .van-action-bar-button--first{border-top-left-radius:var(--van-radius-max);border-bottom-left-radius:var(--van-radius-max)}.van-dialog--round-button .van-action-bar-button--last{border-top-right-radius:var(--van-radius-max);border-bottom-right-radius:var(--van-radius-max)}.van-dialog-bounce-enter-from{transform:translate3d(0,-50%,0) scale(.7);opacity:0}.van-dialog-bounce-leave-active{transform:translate3d(0,-50%,0) scale(.9);opacity:0}
|
package/es/dialog/index.d.ts
CHANGED
|
@@ -120,8 +120,8 @@ export declare const Dialog: import("../utils").WithInstall<import("vue").Define
|
|
|
120
120
|
destroyOnClose: BooleanConstructor;
|
|
121
121
|
}>> & Readonly<{
|
|
122
122
|
onKeydown?: ((...args: any[]) => any) | undefined;
|
|
123
|
-
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
124
123
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
124
|
+
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
125
125
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
126
126
|
}>, {
|
|
127
127
|
overlay: boolean;
|
package/es/field/Field.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type PropType, type ExtractPropTypes, type HTMLAttributes } from 'vue';
|
|
2
|
-
import type { FieldRule, FieldType, FieldTextAlign, FieldClearTrigger, FieldFormatTrigger, FieldAutosizeConfig } from './types';
|
|
2
|
+
import type { FieldRule, FieldType, FieldTextAlign, FieldClearTrigger, FieldFormatTrigger, FieldAutosizeConfig, FieldEnterKeyHint } from './types';
|
|
3
3
|
export declare const fieldSharedProps: {
|
|
4
4
|
id: StringConstructor;
|
|
5
5
|
name: StringConstructor;
|
|
@@ -25,7 +25,7 @@ export declare const fieldSharedProps: {
|
|
|
25
25
|
autocapitalize: StringConstructor;
|
|
26
26
|
autocorrect: StringConstructor;
|
|
27
27
|
errorMessage: StringConstructor;
|
|
28
|
-
enterkeyhint:
|
|
28
|
+
enterkeyhint: PropType<FieldEnterKeyHint>;
|
|
29
29
|
clearTrigger: {
|
|
30
30
|
type: PropType<FieldClearTrigger>;
|
|
31
31
|
default: FieldClearTrigger;
|
|
@@ -107,7 +107,7 @@ export declare const fieldProps: {
|
|
|
107
107
|
autocapitalize: StringConstructor;
|
|
108
108
|
autocorrect: StringConstructor;
|
|
109
109
|
errorMessage: StringConstructor;
|
|
110
|
-
enterkeyhint:
|
|
110
|
+
enterkeyhint: PropType<FieldEnterKeyHint>;
|
|
111
111
|
clearTrigger: {
|
|
112
112
|
type: PropType<FieldClearTrigger>;
|
|
113
113
|
default: FieldClearTrigger;
|
|
@@ -207,7 +207,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
207
207
|
autocapitalize: StringConstructor;
|
|
208
208
|
autocorrect: StringConstructor;
|
|
209
209
|
errorMessage: StringConstructor;
|
|
210
|
-
enterkeyhint:
|
|
210
|
+
enterkeyhint: PropType<FieldEnterKeyHint>;
|
|
211
211
|
clearTrigger: {
|
|
212
212
|
type: PropType<FieldClearTrigger>;
|
|
213
213
|
default: FieldClearTrigger;
|
|
@@ -305,7 +305,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
305
305
|
autocapitalize: StringConstructor;
|
|
306
306
|
autocorrect: StringConstructor;
|
|
307
307
|
errorMessage: StringConstructor;
|
|
308
|
-
enterkeyhint:
|
|
308
|
+
enterkeyhint: PropType<FieldEnterKeyHint>;
|
|
309
309
|
clearTrigger: {
|
|
310
310
|
type: PropType<FieldClearTrigger>;
|
|
311
311
|
default: FieldClearTrigger;
|
package/es/field/Field.mjs
CHANGED
|
@@ -219,7 +219,7 @@ var stdin_default = defineComponent({
|
|
|
219
219
|
var _a, _b;
|
|
220
220
|
const originalValue = value;
|
|
221
221
|
value = limitValueLength(value);
|
|
222
|
-
const limitDiffLen =
|
|
222
|
+
const limitDiffLen = originalValue.length - value.length;
|
|
223
223
|
if (props.type === "number" || props.type === "digit") {
|
|
224
224
|
const isNumber = props.type === "number";
|
|
225
225
|
value = formatNumber(value, isNumber, isNumber);
|
|
@@ -245,7 +245,7 @@ var stdin_default = defineComponent({
|
|
|
245
245
|
selectionEnd
|
|
246
246
|
} = inputRef.value;
|
|
247
247
|
const bcoVal = cutString(originalValue, selectionEnd);
|
|
248
|
-
formatterDiffLen =
|
|
248
|
+
formatterDiffLen = formatter(bcoVal).length - bcoVal.length;
|
|
249
249
|
}
|
|
250
250
|
}
|
|
251
251
|
if (inputRef.value && inputRef.value.value !== value) {
|
|
@@ -256,7 +256,7 @@ var stdin_default = defineComponent({
|
|
|
256
256
|
} = inputRef.value;
|
|
257
257
|
inputRef.value.value = value;
|
|
258
258
|
if (isDef(selectionStart) && isDef(selectionEnd)) {
|
|
259
|
-
const valueLen =
|
|
259
|
+
const valueLen = value.length;
|
|
260
260
|
if (limitDiffLen) {
|
|
261
261
|
selectionStart -= limitDiffLen;
|
|
262
262
|
selectionEnd -= limitDiffLen;
|
package/es/field/index.d.ts
CHANGED
|
@@ -54,7 +54,7 @@ export declare const Field: import("../utils").WithInstall<import("vue").DefineC
|
|
|
54
54
|
autocapitalize: StringConstructor;
|
|
55
55
|
autocorrect: StringConstructor;
|
|
56
56
|
errorMessage: StringConstructor;
|
|
57
|
-
enterkeyhint:
|
|
57
|
+
enterkeyhint: import("vue").PropType<import("./types").FieldEnterKeyHint>;
|
|
58
58
|
clearTrigger: {
|
|
59
59
|
type: import("vue").PropType<import("./types").FieldClearTrigger>;
|
|
60
60
|
default: import("./types").FieldClearTrigger;
|
|
@@ -152,7 +152,7 @@ export declare const Field: import("../utils").WithInstall<import("vue").DefineC
|
|
|
152
152
|
autocapitalize: StringConstructor;
|
|
153
153
|
autocorrect: StringConstructor;
|
|
154
154
|
errorMessage: StringConstructor;
|
|
155
|
-
enterkeyhint:
|
|
155
|
+
enterkeyhint: import("vue").PropType<import("./types").FieldEnterKeyHint>;
|
|
156
156
|
clearTrigger: {
|
|
157
157
|
type: import("vue").PropType<import("./types").FieldClearTrigger>;
|
|
158
158
|
default: import("./types").FieldClearTrigger;
|
|
@@ -230,7 +230,7 @@ export declare const Field: import("../utils").WithInstall<import("vue").DefineC
|
|
|
230
230
|
export default Field;
|
|
231
231
|
export { fieldProps } from './Field';
|
|
232
232
|
export type { FieldProps };
|
|
233
|
-
export type { FieldType, FieldRule, FieldInstance, FieldTextAlign, FieldThemeVars, FieldRuleMessage, FieldClearTrigger, FieldFormatTrigger, FieldRuleValidator, FieldRuleFormatter, FieldValidateError, FieldAutosizeConfig, FieldValidateTrigger, FieldValidationStatus, } from './types';
|
|
233
|
+
export type { FieldType, FieldRule, FieldInstance, FieldTextAlign, FieldThemeVars, FieldRuleMessage, FieldClearTrigger, FieldFormatTrigger, FieldRuleValidator, FieldRuleFormatter, FieldValidateError, FieldAutosizeConfig, FieldValidateTrigger, FieldValidationStatus, FieldEnterKeyHint, } from './types';
|
|
234
234
|
declare module 'vue' {
|
|
235
235
|
interface GlobalComponents {
|
|
236
236
|
VanField: typeof Field;
|
package/es/field/types.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ export type FieldTextAlign = 'left' | 'center' | 'right' | 'top';
|
|
|
5
5
|
export type FieldClearTrigger = 'always' | 'focus';
|
|
6
6
|
export type FieldFormatTrigger = 'onBlur' | 'onChange';
|
|
7
7
|
export type FieldValidateTrigger = 'onBlur' | 'onChange' | 'onSubmit';
|
|
8
|
+
export type FieldEnterKeyHint = 'search' | 'done' | 'enter' | 'go' | 'next' | 'previous' | 'send';
|
|
8
9
|
export type FieldAutosizeConfig = {
|
|
9
10
|
maxHeight?: number;
|
|
10
11
|
minHeight?: number;
|
|
@@ -11,13 +11,7 @@ export declare const floatingBubbleProps: {
|
|
|
11
11
|
default: FloatingBubbleAxis;
|
|
12
12
|
};
|
|
13
13
|
magnetic: PropType<FloatingBubbleMagnetic>;
|
|
14
|
-
offset:
|
|
15
|
-
type: PropType<FloatingBubbleOffset>;
|
|
16
|
-
default: () => {
|
|
17
|
-
x: number;
|
|
18
|
-
y: number;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
14
|
+
offset: PropType<FloatingBubbleOffset>;
|
|
21
15
|
teleport: {
|
|
22
16
|
type: PropType<TeleportProps["to"]>;
|
|
23
17
|
default: string;
|
|
@@ -35,13 +29,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
35
29
|
default: FloatingBubbleAxis;
|
|
36
30
|
};
|
|
37
31
|
magnetic: PropType<FloatingBubbleMagnetic>;
|
|
38
|
-
offset:
|
|
39
|
-
type: PropType<FloatingBubbleOffset>;
|
|
40
|
-
default: () => {
|
|
41
|
-
x: number;
|
|
42
|
-
y: number;
|
|
43
|
-
};
|
|
44
|
-
};
|
|
32
|
+
offset: PropType<FloatingBubbleOffset>;
|
|
45
33
|
teleport: {
|
|
46
34
|
type: PropType<TeleportProps["to"]>;
|
|
47
35
|
default: string;
|
|
@@ -57,13 +45,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
57
45
|
default: FloatingBubbleAxis;
|
|
58
46
|
};
|
|
59
47
|
magnetic: PropType<FloatingBubbleMagnetic>;
|
|
60
|
-
offset:
|
|
61
|
-
type: PropType<FloatingBubbleOffset>;
|
|
62
|
-
default: () => {
|
|
63
|
-
x: number;
|
|
64
|
-
y: number;
|
|
65
|
-
};
|
|
66
|
-
};
|
|
48
|
+
offset: PropType<FloatingBubbleOffset>;
|
|
67
49
|
teleport: {
|
|
68
50
|
type: PropType<TeleportProps["to"]>;
|
|
69
51
|
default: string;
|
|
@@ -73,7 +55,6 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
73
55
|
"onUpdate:offset"?: ((...args: any[]) => any) | undefined;
|
|
74
56
|
onOffsetChange?: ((...args: any[]) => any) | undefined;
|
|
75
57
|
}>, {
|
|
76
|
-
offset: FloatingBubbleOffset;
|
|
77
58
|
teleport: string | import("vue").RendererElement | null | undefined;
|
|
78
59
|
gap: FloatingBubbleGap;
|
|
79
60
|
axis: FloatingBubbleAxis;
|
|
@@ -11,13 +11,7 @@ const floatingBubbleProps = {
|
|
|
11
11
|
icon: String,
|
|
12
12
|
axis: makeStringProp("y"),
|
|
13
13
|
magnetic: String,
|
|
14
|
-
offset:
|
|
15
|
-
type: Object,
|
|
16
|
-
default: () => ({
|
|
17
|
-
x: -1,
|
|
18
|
-
y: -1
|
|
19
|
-
})
|
|
20
|
-
},
|
|
14
|
+
offset: Object,
|
|
21
15
|
teleport: {
|
|
22
16
|
type: [String, Object],
|
|
23
17
|
default: "body"
|
|
@@ -71,8 +65,8 @@ var stdin_default = defineComponent({
|
|
|
71
65
|
offset
|
|
72
66
|
} = props;
|
|
73
67
|
state.value = {
|
|
74
|
-
x: offset
|
|
75
|
-
y: offset
|
|
68
|
+
x: offset ? offset.x : windowWidth.value - width - gapX.value,
|
|
69
|
+
y: offset ? offset.y : windowHeight.value - height - gapY.value,
|
|
76
70
|
width,
|
|
77
71
|
height
|
|
78
72
|
};
|
|
@@ -9,13 +9,7 @@ export declare const FloatingBubble: import("../utils").WithInstall<import("vue"
|
|
|
9
9
|
default: import("./types").FloatingBubbleAxis;
|
|
10
10
|
};
|
|
11
11
|
magnetic: import("vue").PropType<import("./types").FloatingBubbleMagnetic>;
|
|
12
|
-
offset:
|
|
13
|
-
type: import("vue").PropType<import("./types").FloatingBubbleOffset>;
|
|
14
|
-
default: () => {
|
|
15
|
-
x: number;
|
|
16
|
-
y: number;
|
|
17
|
-
};
|
|
18
|
-
};
|
|
12
|
+
offset: import("vue").PropType<import("./types").FloatingBubbleOffset>;
|
|
19
13
|
teleport: {
|
|
20
14
|
type: import("vue").PropType<import("vue").TeleportProps["to"]>;
|
|
21
15
|
default: string;
|
|
@@ -31,13 +25,7 @@ export declare const FloatingBubble: import("../utils").WithInstall<import("vue"
|
|
|
31
25
|
default: import("./types").FloatingBubbleAxis;
|
|
32
26
|
};
|
|
33
27
|
magnetic: import("vue").PropType<import("./types").FloatingBubbleMagnetic>;
|
|
34
|
-
offset:
|
|
35
|
-
type: import("vue").PropType<import("./types").FloatingBubbleOffset>;
|
|
36
|
-
default: () => {
|
|
37
|
-
x: number;
|
|
38
|
-
y: number;
|
|
39
|
-
};
|
|
40
|
-
};
|
|
28
|
+
offset: import("vue").PropType<import("./types").FloatingBubbleOffset>;
|
|
41
29
|
teleport: {
|
|
42
30
|
type: import("vue").PropType<import("vue").TeleportProps["to"]>;
|
|
43
31
|
default: string;
|
|
@@ -47,7 +35,6 @@ export declare const FloatingBubble: import("../utils").WithInstall<import("vue"
|
|
|
47
35
|
"onUpdate:offset"?: ((...args: any[]) => any) | undefined;
|
|
48
36
|
onOffsetChange?: ((...args: any[]) => any) | undefined;
|
|
49
37
|
}>, {
|
|
50
|
-
offset: import("./types").FloatingBubbleOffset;
|
|
51
38
|
teleport: string | import("vue").RendererElement | null | undefined;
|
|
52
39
|
gap: import("./types").FloatingBubbleGap;
|
|
53
40
|
axis: import("./types").FloatingBubbleAxis;
|
|
@@ -12,6 +12,10 @@ export declare const floatingPanelProps: {
|
|
|
12
12
|
type: (NumberConstructor | StringConstructor)[];
|
|
13
13
|
default: number;
|
|
14
14
|
};
|
|
15
|
+
magnetic: {
|
|
16
|
+
type: BooleanConstructor;
|
|
17
|
+
default: true;
|
|
18
|
+
};
|
|
15
19
|
contentDraggable: {
|
|
16
20
|
type: BooleanConstructor;
|
|
17
21
|
default: true;
|
|
@@ -36,6 +40,10 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
36
40
|
type: (NumberConstructor | StringConstructor)[];
|
|
37
41
|
default: number;
|
|
38
42
|
};
|
|
43
|
+
magnetic: {
|
|
44
|
+
type: BooleanConstructor;
|
|
45
|
+
default: true;
|
|
46
|
+
};
|
|
39
47
|
contentDraggable: {
|
|
40
48
|
type: BooleanConstructor;
|
|
41
49
|
default: true;
|
|
@@ -58,6 +66,10 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
58
66
|
type: (NumberConstructor | StringConstructor)[];
|
|
59
67
|
default: number;
|
|
60
68
|
};
|
|
69
|
+
magnetic: {
|
|
70
|
+
type: BooleanConstructor;
|
|
71
|
+
default: true;
|
|
72
|
+
};
|
|
61
73
|
contentDraggable: {
|
|
62
74
|
type: BooleanConstructor;
|
|
63
75
|
default: true;
|
|
@@ -75,6 +87,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
75
87
|
safeAreaInsetBottom: boolean;
|
|
76
88
|
duration: string | number;
|
|
77
89
|
lockScroll: boolean;
|
|
90
|
+
magnetic: boolean;
|
|
78
91
|
anchors: number[];
|
|
79
92
|
contentDraggable: boolean;
|
|
80
93
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -8,6 +8,7 @@ const floatingPanelProps = {
|
|
|
8
8
|
height: makeNumericProp(0),
|
|
9
9
|
anchors: makeArrayProp(),
|
|
10
10
|
duration: makeNumericProp(0.3),
|
|
11
|
+
magnetic: truthProp,
|
|
11
12
|
contentDraggable: truthProp,
|
|
12
13
|
lockScroll: Boolean,
|
|
13
14
|
safeAreaInsetBottom: truthProp
|
|
@@ -84,7 +85,15 @@ var stdin_default = defineComponent({
|
|
|
84
85
|
const onTouchend = () => {
|
|
85
86
|
maxScroll = -1;
|
|
86
87
|
dragging.value = false;
|
|
87
|
-
|
|
88
|
+
if (props.magnetic) {
|
|
89
|
+
height.value = closest(anchors.value, height.value);
|
|
90
|
+
} else {
|
|
91
|
+
const {
|
|
92
|
+
min,
|
|
93
|
+
max
|
|
94
|
+
} = boundary.value;
|
|
95
|
+
height.value = Math.max(min, Math.min(max, height.value));
|
|
96
|
+
}
|
|
88
97
|
if (height.value !== -startY) {
|
|
89
98
|
emit("heightChange", {
|
|
90
99
|
height: height.value
|
|
@@ -123,7 +132,10 @@ var stdin_default = defineComponent({
|
|
|
123
132
|
"onTouchcancel": onTouchend
|
|
124
133
|
}, [renderHeader(), _createVNode("div", {
|
|
125
134
|
"class": bem("content"),
|
|
126
|
-
"ref": contentRef
|
|
135
|
+
"ref": contentRef,
|
|
136
|
+
"style": {
|
|
137
|
+
paddingBottom: addUnit(boundary.value.max - height.value)
|
|
138
|
+
}
|
|
127
139
|
}, [(_a = slots.default) == null ? void 0 : _a.call(slots)])]);
|
|
128
140
|
};
|
|
129
141
|
}
|
|
@@ -11,6 +11,10 @@ export declare const FloatingPanel: import("../utils").WithInstall<import("vue")
|
|
|
11
11
|
type: (NumberConstructor | StringConstructor)[];
|
|
12
12
|
default: number;
|
|
13
13
|
};
|
|
14
|
+
magnetic: {
|
|
15
|
+
type: BooleanConstructor;
|
|
16
|
+
default: true;
|
|
17
|
+
};
|
|
14
18
|
contentDraggable: {
|
|
15
19
|
type: BooleanConstructor;
|
|
16
20
|
default: true;
|
|
@@ -33,6 +37,10 @@ export declare const FloatingPanel: import("../utils").WithInstall<import("vue")
|
|
|
33
37
|
type: (NumberConstructor | StringConstructor)[];
|
|
34
38
|
default: number;
|
|
35
39
|
};
|
|
40
|
+
magnetic: {
|
|
41
|
+
type: BooleanConstructor;
|
|
42
|
+
default: true;
|
|
43
|
+
};
|
|
36
44
|
contentDraggable: {
|
|
37
45
|
type: BooleanConstructor;
|
|
38
46
|
default: true;
|
|
@@ -50,6 +58,7 @@ export declare const FloatingPanel: import("../utils").WithInstall<import("vue")
|
|
|
50
58
|
safeAreaInsetBottom: boolean;
|
|
51
59
|
duration: string | number;
|
|
52
60
|
lockScroll: boolean;
|
|
61
|
+
magnetic: boolean;
|
|
53
62
|
anchors: number[];
|
|
54
63
|
contentDraggable: boolean;
|
|
55
64
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>>;
|
package/es/grid/Grid.d.ts
CHANGED
|
@@ -66,8 +66,8 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
66
66
|
}>> & Readonly<{}>, {
|
|
67
67
|
reverse: boolean;
|
|
68
68
|
center: boolean;
|
|
69
|
-
border: boolean;
|
|
70
69
|
square: boolean;
|
|
70
|
+
border: boolean;
|
|
71
71
|
clickable: boolean;
|
|
72
72
|
columnNum: string | number;
|
|
73
73
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
package/es/grid/index.d.ts
CHANGED
|
@@ -39,8 +39,8 @@ export declare const Grid: import("../utils").WithInstall<import("vue").DefineCo
|
|
|
39
39
|
}>> & Readonly<{}>, {
|
|
40
40
|
reverse: boolean;
|
|
41
41
|
center: boolean;
|
|
42
|
-
border: boolean;
|
|
43
42
|
square: boolean;
|
|
43
|
+
border: boolean;
|
|
44
44
|
clickable: boolean;
|
|
45
45
|
columnNum: string | number;
|
|
46
46
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>>;
|
package/es/index.d.ts
CHANGED
package/es/index.mjs
CHANGED
|
@@ -99,7 +99,7 @@ import { Toast } from "./toast/index.mjs";
|
|
|
99
99
|
import { TreeSelect } from "./tree-select/index.mjs";
|
|
100
100
|
import { Uploader } from "./uploader/index.mjs";
|
|
101
101
|
import { Watermark } from "./watermark/index.mjs";
|
|
102
|
-
const version = "4.9.
|
|
102
|
+
const version = "4.9.22";
|
|
103
103
|
function install(app) {
|
|
104
104
|
const components = [
|
|
105
105
|
ActionBar,
|