@varlet/ui 2.14.2 → 2.15.0-alpha.1692990022445

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.
Files changed (91) hide show
  1. package/es/action-sheet/props.mjs +2 -7
  2. package/es/app-bar/props.mjs +8 -29
  3. package/es/avatar/Avatar.mjs +6 -6
  4. package/es/avatar/props.mjs +8 -36
  5. package/es/avatar-group/props.mjs +2 -7
  6. package/es/back-top/props.mjs +3 -9
  7. package/es/badge/props.mjs +7 -27
  8. package/es/bottom-navigation/props.mjs +7 -22
  9. package/es/bottom-navigation-item/props.mjs +3 -9
  10. package/es/breadcrumb/props.mjs +1 -3
  11. package/es/button/props.mjs +14 -57
  12. package/es/button-group/props.mjs +6 -25
  13. package/es/cell/props.mjs +10 -32
  14. package/es/checkbox/Checkbox.mjs +23 -19
  15. package/es/checkbox/props.mjs +10 -22
  16. package/es/checkbox-group/props.mjs +4 -12
  17. package/es/chip/props.mjs +7 -28
  18. package/es/col/props.mjs +9 -35
  19. package/es/collapse/props.mjs +2 -7
  20. package/es/collapse-item/CollapseItem.mjs +15 -5
  21. package/es/collapse-item/props.mjs +3 -10
  22. package/es/counter/props.mjs +14 -48
  23. package/es/date-picker/props.mjs +10 -35
  24. package/es/dialog/props.mjs +13 -42
  25. package/es/divider/props.mjs +5 -18
  26. package/es/drag/Drag.mjs +20 -27
  27. package/es/drag/props.mjs +2 -7
  28. package/es/ellipsis/props.mjs +2 -10
  29. package/es/fab/props.mjs +14 -51
  30. package/es/field-decorator/props.mjs +13 -46
  31. package/es/form/props.mjs +3 -15
  32. package/es/icon/props.mjs +4 -12
  33. package/es/image/props.mjs +9 -33
  34. package/es/image-preview/ImagePreview.mjs +49 -66
  35. package/es/image-preview/props.mjs +4 -15
  36. package/es/index-anchor/props.mjs +1 -3
  37. package/es/index-bar/props.mjs +4 -15
  38. package/es/index.bundle.mjs +1 -1
  39. package/es/index.mjs +1 -1
  40. package/es/input/Input.mjs +12 -29
  41. package/es/input/props.mjs +9 -33
  42. package/es/link/props.mjs +9 -33
  43. package/es/list/props.mjs +6 -21
  44. package/es/loading/props.mjs +6 -23
  45. package/es/loading-bar/props.mjs +5 -16
  46. package/es/menu/props.mjs +9 -37
  47. package/es/option/Option.mjs +18 -4
  48. package/es/overlay/props.mjs +2 -7
  49. package/es/pagination/props.mjs +4 -14
  50. package/es/paper/props.mjs +6 -21
  51. package/es/picker/props.mjs +7 -23
  52. package/es/popup/props.mjs +7 -26
  53. package/es/progress/props.mjs +8 -31
  54. package/es/pull-refresh/props.mjs +7 -29
  55. package/es/radio/Radio.mjs +5 -11
  56. package/es/radio/props.mjs +6 -20
  57. package/es/radio-group/props.mjs +2 -8
  58. package/es/rate/Rate.mjs +12 -9
  59. package/es/rate/props.mjs +11 -37
  60. package/es/result/props.mjs +4 -14
  61. package/es/row/props.mjs +2 -10
  62. package/es/select/props.mjs +5 -20
  63. package/es/skeleton/props.mjs +7 -25
  64. package/es/slider/props.mjs +13 -46
  65. package/es/snackbar/props.mjs +8 -36
  66. package/es/space/Space.mjs +3 -3
  67. package/es/space/props.mjs +4 -17
  68. package/es/step/props.mjs +2 -6
  69. package/es/steps/props.mjs +3 -11
  70. package/es/sticky/props.mjs +2 -8
  71. package/es/swipe/Swipe.mjs +51 -65
  72. package/es/swipe/props.mjs +3 -10
  73. package/es/switch/Switch.mjs +11 -7
  74. package/es/switch/props.mjs +8 -27
  75. package/es/tab/props.mjs +2 -7
  76. package/es/tab-item/props.mjs +1 -3
  77. package/es/tabs/props.mjs +14 -48
  78. package/es/tabs-items/props.mjs +1 -4
  79. package/es/time-picker/props.mjs +9 -31
  80. package/es/tooltip/props.mjs +11 -45
  81. package/es/uploader/props.mjs +7 -25
  82. package/es/utils/{jest.mjs → test.mjs} +19 -14
  83. package/es/varlet.esm.js +6687 -7777
  84. package/es/watermark/props.mjs +3 -10
  85. package/highlight/web-types.en-US.json +17 -4
  86. package/highlight/web-types.zh-CN.json +15 -2
  87. package/lib/varlet.cjs.js +710 -1742
  88. package/package.json +13 -12
  89. package/types/checkbox.d.ts +3 -0
  90. package/types/col.d.ts +7 -5
  91. package/umd/varlet.js +4 -4
@@ -20,7 +20,7 @@ function __render__(_ctx, _cache) {
20
20
  var _component_var_form_details = _resolveComponent("var-form-details");
21
21
  return _openBlock(), _createElementBlock("div", {
22
22
  class: _normalizeClass(_ctx.classes(_ctx.n(), _ctx.n('$--box'))),
23
- onMousedown: _cache[15] || (_cache[15] = function () {
23
+ onMousedown: _cache[13] || (_cache[13] = function () {
24
24
  return _ctx.handleMousedown && _ctx.handleMousedown(...arguments);
25
25
  })
26
26
  }, [_createVNode(_component_var_field_decorator, _normalizeProps(_guardReactiveProps({
@@ -86,13 +86,10 @@ function __render__(_ctx, _cache) {
86
86
  onChange: _cache[3] || (_cache[3] = function () {
87
87
  return _ctx.handleChange && _ctx.handleChange(...arguments);
88
88
  }),
89
- onTouchstart: _cache[4] || (_cache[4] = function () {
90
- return _ctx.handleTouchstart && _ctx.handleTouchstart(...arguments);
91
- }),
92
- onCompositionstart: _cache[5] || (_cache[5] = function () {
89
+ onCompositionstart: _cache[4] || (_cache[4] = function () {
93
90
  return _ctx.handleCompositionStart && _ctx.handleCompositionStart(...arguments);
94
91
  }),
95
- onCompositionend: _cache[6] || (_cache[6] = function () {
92
+ onCompositionend: _cache[5] || (_cache[5] = function () {
96
93
  return _ctx.handleCompositionEnd && _ctx.handleCompositionEnd(...arguments);
97
94
  })
98
95
  }, "\n ", 46 /* CLASS, STYLE, PROPS, HYDRATE_EVENTS */, _hoisted_2)) : (_openBlock(), _createElementBlock("input", {
@@ -113,25 +110,22 @@ function __render__(_ctx, _cache) {
113
110
  caretColor: !_ctx.errorMessage ? _ctx.focusColor : undefined,
114
111
  '--input-placeholder-color': _ctx.placeholderColor
115
112
  }),
116
- onFocus: _cache[7] || (_cache[7] = function () {
113
+ onFocus: _cache[6] || (_cache[6] = function () {
117
114
  return _ctx.handleFocus && _ctx.handleFocus(...arguments);
118
115
  }),
119
- onBlur: _cache[8] || (_cache[8] = function () {
116
+ onBlur: _cache[7] || (_cache[7] = function () {
120
117
  return _ctx.handleBlur && _ctx.handleBlur(...arguments);
121
118
  }),
122
- onInput: _cache[9] || (_cache[9] = function () {
119
+ onInput: _cache[8] || (_cache[8] = function () {
123
120
  return _ctx.handleInput && _ctx.handleInput(...arguments);
124
121
  }),
125
- onChange: _cache[10] || (_cache[10] = function () {
122
+ onChange: _cache[9] || (_cache[9] = function () {
126
123
  return _ctx.handleChange && _ctx.handleChange(...arguments);
127
124
  }),
128
- onTouchstart: _cache[11] || (_cache[11] = function () {
129
- return _ctx.handleTouchstart && _ctx.handleTouchstart(...arguments);
130
- }),
131
- onCompositionstart: _cache[12] || (_cache[12] = function () {
125
+ onCompositionstart: _cache[10] || (_cache[10] = function () {
132
126
  return _ctx.handleCompositionStart && _ctx.handleCompositionStart(...arguments);
133
127
  }),
134
- onCompositionend: _cache[13] || (_cache[13] = function () {
128
+ onCompositionend: _cache[11] || (_cache[11] = function () {
135
129
  return _ctx.handleCompositionEnd && _ctx.handleCompositionEnd(...arguments);
136
130
  })
137
131
  }, null, 46 /* CLASS, STYLE, PROPS, HYDRATE_EVENTS */, _hoisted_3))]),
@@ -143,7 +137,7 @@ function __render__(_ctx, _cache) {
143
137
  } : undefined]), 1040 /* FULL_PROPS, DYNAMIC_SLOTS */), _createVNode(_component_var_form_details, {
144
138
  "error-message": _ctx.errorMessage,
145
139
  "extra-message": _ctx.maxlengthText,
146
- onMousedown: _cache[14] || (_cache[14] = _withModifiers(() => {}, ["stop"]))
140
+ onMousedown: _cache[12] || (_cache[12] = _withModifiers(() => {}, ["stop"]))
147
141
  }, _createSlots({
148
142
  _: 2 /* DYNAMIC */
149
143
  }, [_ctx.$slots['extra-message'] ? {
@@ -305,17 +299,7 @@ var __sfc__ = defineComponent({
305
299
  };
306
300
  var withTrim = value => props.modelModifiers.trim ? value.trim() : value;
307
301
  var withMaxlength = value => props.maxlength ? value.slice(0, toNumber(props.maxlength)) : value;
308
- var handleTouchstart = e => {
309
- var {
310
- disabled,
311
- readonly
312
- } = props;
313
- if (form != null && form.disabled.value || form != null && form.readonly.value || disabled || readonly) {
314
- return;
315
- }
316
- e.stopPropagation();
317
- };
318
- function handleMousedown(e) {
302
+ var handleMousedown = e => {
319
303
  var {
320
304
  disabled
321
305
  } = props;
@@ -324,7 +308,7 @@ var __sfc__ = defineComponent({
324
308
  }
325
309
  focus();
326
310
  e.preventDefault();
327
- }
311
+ };
328
312
 
329
313
  // expose
330
314
  var reset = () => {
@@ -379,7 +363,6 @@ var __sfc__ = defineComponent({
379
363
  handleChange,
380
364
  handleClear,
381
365
  handleClick,
382
- handleTouchstart,
383
366
  handleCompositionStart,
384
367
  handleCompositionEnd,
385
368
  handleMousedown,
@@ -1,55 +1,31 @@
1
1
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
2
  import { defineListenerProp, pickProps } from '../utils/components.mjs';
3
3
  import { props as fieldDecoratorProps } from '../field-decorator/props.mjs';
4
- export function typeValidator(type) {
5
- return ['text', 'password', 'number', 'tel', 'email'].includes(type);
6
- }
7
4
  export var props = _extends({
8
- modelValue: {
9
- type: String
10
- },
5
+ modelValue: String,
11
6
  modelModifiers: {
12
7
  type: Object,
13
8
  default: () => ({})
14
9
  },
15
10
  type: {
16
11
  type: String,
17
- default: 'text',
18
- validator: typeValidator
19
- },
20
- textarea: {
21
- type: Boolean,
22
- default: false
12
+ default: 'text'
23
13
  },
14
+ textarea: Boolean,
24
15
  rows: {
25
16
  type: [String, Number],
26
17
  default: 8
27
18
  },
28
- maxlength: {
29
- type: [String, Number]
30
- },
31
- readonly: {
32
- type: Boolean,
33
- default: false
34
- },
35
- resize: {
36
- type: Boolean,
37
- default: false
38
- },
39
- autofocus: {
40
- type: Boolean,
41
- default: false
42
- },
19
+ maxlength: [String, Number],
20
+ readonly: Boolean,
21
+ resize: Boolean,
22
+ autofocus: Boolean,
43
23
  validateTrigger: {
44
24
  type: Array,
45
25
  default: () => ['onInput', 'onClear']
46
26
  },
47
- rules: {
48
- type: Array
49
- },
50
- enterkeyhint: {
51
- type: String
52
- },
27
+ rules: Array,
28
+ enterkeyhint: String,
53
29
  onFocus: defineListenerProp(),
54
30
  onBlur: defineListenerProp(),
55
31
  onInput: defineListenerProp(),
package/es/link/props.mjs CHANGED
@@ -1,43 +1,19 @@
1
1
  import { defineListenerProp } from '../utils/components.mjs';
2
- function typeValidator(type) {
3
- return ['default', 'primary', 'info', 'success', 'warning', 'danger'].includes(type);
4
- }
5
- function underlineValidator(status) {
6
- return ['always', 'hover', 'none'].includes(status);
7
- }
8
2
  export var props = {
9
3
  type: {
10
4
  type: String,
11
- default: 'default',
12
- validator: typeValidator
13
- },
14
- href: {
15
- type: String
16
- },
17
- target: {
18
- type: String
19
- },
20
- to: {
21
- type: [String, Object]
22
- },
23
- replace: {
24
- type: Boolean,
25
- default: false
5
+ default: 'default'
26
6
  },
7
+ href: String,
8
+ target: String,
9
+ to: [String, Object],
10
+ replace: Boolean,
27
11
  underline: {
28
12
  type: String,
29
- default: 'always',
30
- validator: underlineValidator
31
- },
32
- disabled: {
33
- type: Boolean,
34
- default: false
35
- },
36
- textSize: {
37
- type: [String, Number]
38
- },
39
- textColor: {
40
- type: String
13
+ default: 'always'
41
14
  },
15
+ disabled: Boolean,
16
+ textSize: [String, Number],
17
+ textColor: String,
42
18
  onClick: defineListenerProp()
43
19
  };
package/es/list/props.mjs CHANGED
@@ -1,34 +1,19 @@
1
1
  import { defineListenerProp } from '../utils/components.mjs';
2
2
  export var props = {
3
- loading: {
4
- type: Boolean,
5
- default: false
6
- },
3
+ loading: Boolean,
7
4
  immediateCheck: {
8
5
  type: Boolean,
9
6
  default: true
10
7
  },
11
- finished: {
12
- type: Boolean,
13
- default: false
14
- },
15
- error: {
16
- type: Boolean,
17
- default: false
18
- },
8
+ finished: Boolean,
9
+ error: Boolean,
19
10
  offset: {
20
11
  type: [String, Number],
21
12
  default: 0
22
13
  },
23
- loadingText: {
24
- type: String
25
- },
26
- finishedText: {
27
- type: String
28
- },
29
- errorText: {
30
- type: String
31
- },
14
+ loadingText: String,
15
+ finishedText: String,
16
+ errorText: String,
32
17
  onLoad: defineListenerProp(),
33
18
  'onUpdate:loading': defineListenerProp(),
34
19
  'onUpdate:error': defineListenerProp()
@@ -1,31 +1,14 @@
1
- export function typeValidator(type) {
2
- return ['circle', 'wave', 'cube', 'rect', 'disappear'].includes(type);
3
- }
4
- export function sizeValidator(size) {
5
- return ['normal', 'mini', 'small', 'large'].includes(size);
6
- }
7
1
  export var props = {
8
2
  type: {
9
3
  type: String,
10
- default: 'circle',
11
- validator: typeValidator
12
- },
13
- radius: {
14
- type: [String, Number]
4
+ default: 'circle'
15
5
  },
6
+ radius: [String, Number],
16
7
  size: {
17
8
  type: String,
18
- default: 'normal',
19
- validator: sizeValidator
20
- },
21
- color: {
22
- type: String
23
- },
24
- description: {
25
- type: String
9
+ default: 'normal'
26
10
  },
27
- loading: {
28
- type: Boolean,
29
- default: false
30
- }
11
+ color: String,
12
+ description: String,
13
+ loading: Boolean
31
14
  };
@@ -7,20 +7,9 @@ export var props = {
7
7
  type: Number,
8
8
  default: 0
9
9
  },
10
- error: {
11
- type: Boolean,
12
- default: false
13
- },
14
- color: {
15
- type: String
16
- },
17
- errorColor: {
18
- type: String
19
- },
20
- height: {
21
- type: [Number, String]
22
- },
23
- top: {
24
- type: [Number, String]
25
- }
10
+ error: Boolean,
11
+ color: String,
12
+ errorColor: String,
13
+ height: [Number, String],
14
+ top: [Number, String]
26
15
  };
package/es/menu/props.mjs CHANGED
@@ -1,39 +1,19 @@
1
1
  import { defineListenerProp } from '../utils/components.mjs';
2
- function triggerValidator(trigger) {
3
- return ['click', 'hover'].includes(trigger);
4
- }
5
- function placementValidator(alignment) {
6
- return ['top', 'top-start', 'top-end', 'bottom', 'bottom-start', 'bottom-end', 'right', 'right-start', 'right-end', 'left', 'left-start', 'left-end', 'cover-top', 'cover-top-start', 'cover-top-end', 'cover-bottom', 'cover-bottom-start', 'cover-bottom-end', 'cover-left', 'cover-right'].includes(alignment);
7
- }
8
- function strategyValidator(strategy) {
9
- return ['absolute', 'fixed'].includes(strategy);
10
- }
11
2
  export var props = {
12
- show: {
13
- type: Boolean,
14
- default: false
15
- },
16
- disabled: {
17
- type: Boolean,
18
- default: false
19
- },
3
+ show: Boolean,
4
+ disabled: Boolean,
20
5
  trigger: {
21
6
  type: String,
22
- default: 'click',
23
- validator: triggerValidator
24
- },
25
- reference: {
26
- type: String
7
+ default: 'click'
27
8
  },
9
+ reference: String,
28
10
  placement: {
29
11
  type: String,
30
- default: 'cover-top-start',
31
- validator: placementValidator
12
+ default: 'cover-top-start'
32
13
  },
33
14
  strategy: {
34
15
  type: String,
35
- default: 'absolute',
36
- validator: strategyValidator
16
+ default: 'absolute'
37
17
  },
38
18
  offsetX: {
39
19
  type: [Number, String],
@@ -47,10 +27,7 @@ export var props = {
47
27
  type: [String, Object, Boolean],
48
28
  default: 'body'
49
29
  },
50
- sameWidth: {
51
- type: Boolean,
52
- default: false
53
- },
30
+ sameWidth: Boolean,
54
31
  elevation: {
55
32
  type: [Boolean, String, Number],
56
33
  default: true
@@ -59,13 +36,8 @@ export var props = {
59
36
  type: Boolean,
60
37
  default: true
61
38
  },
62
- popoverClass: {
63
- type: String
64
- },
65
- closeOnClickReference: {
66
- type: Boolean,
67
- default: false
68
- },
39
+ popoverClass: String,
40
+ closeOnClickReference: Boolean,
69
41
  onOpen: defineListenerProp(),
70
42
  onOpened: defineListenerProp(),
71
43
  onClose: defineListenerProp(),
@@ -4,14 +4,18 @@ import { defineComponent, computed, ref, watch } from 'vue';
4
4
  import { useSelect } from './provide.mjs';
5
5
  import { createNamespace } from '../utils/components.mjs';
6
6
  import { props } from './props.mjs';
7
+ import Hover from '../hover/index.mjs';
8
+ import VarHoverOverlay, { useHoverOverlay } from '../hover-overlay/index.mjs';
7
9
  var {
8
10
  n,
9
11
  classes
10
12
  } = createNamespace('option');
11
- import { normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, withModifiers as _withModifiers, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, renderSlot as _renderSlot, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, resolveDirective as _resolveDirective, createElementBlock as _createElementBlock, withDirectives as _withDirectives } from "vue";
13
+ import { normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, withModifiers as _withModifiers, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, renderSlot as _renderSlot, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, createVNode as _createVNode, resolveDirective as _resolveDirective, createElementBlock as _createElementBlock, withDirectives as _withDirectives } from "vue";
12
14
  function __render__(_ctx, _cache) {
13
15
  var _component_var_checkbox = _resolveComponent("var-checkbox");
16
+ var _component_var_hover_overlay = _resolveComponent("var-hover-overlay");
14
17
  var _directive_ripple = _resolveDirective("ripple");
18
+ var _directive_hover = _resolveDirective("hover");
15
19
  return _withDirectives((_openBlock(), _createElementBlock("div", {
16
20
  class: _normalizeClass(_ctx.classes(_ctx.n(), _ctx.n('$--box'), [_ctx.optionSelected, _ctx.n('--selected-color')])),
17
21
  style: _normalizeStyle({
@@ -35,15 +39,19 @@ function __render__(_ctx, _cache) {
35
39
  onChange: _ctx.handleSelect
36
40
  }, null, 8 /* PROPS */, ["checked-color", "modelValue", "onChange"])) : _createCommentVNode("v-if", true), _createElementVNode("div", {
37
41
  class: _normalizeClass(_ctx.classes(_ctx.n('text'), _ctx.n('$--ellipsis')))
38
- }, [_renderSlot(_ctx.$slots, "default", {}, () => [_createTextVNode(_toDisplayString(_ctx.label), 1 /* TEXT */)])], 2 /* CLASS */)], 6 /* CLASS, STYLE */)), [[_directive_ripple]]);
42
+ }, [_renderSlot(_ctx.$slots, "default", {}, () => [_createTextVNode(_toDisplayString(_ctx.label), 1 /* TEXT */)])], 2 /* CLASS */), _createVNode(_component_var_hover_overlay, {
43
+ hovering: _ctx.hovering
44
+ }, null, 8 /* PROPS */, ["hovering"])], 6 /* CLASS, STYLE */)), [[_directive_ripple], [_directive_hover, _ctx.handleHovering, "desktop"]]);
39
45
  }
40
46
  var __sfc__ = defineComponent({
41
47
  name: 'VarOption',
42
48
  directives: {
43
- Ripple
49
+ Ripple,
50
+ Hover
44
51
  },
45
52
  components: {
46
- VarCheckbox
53
+ VarCheckbox,
54
+ VarHoverOverlay
47
55
  },
48
56
  props,
49
57
  setup(props) {
@@ -61,6 +69,10 @@ var __sfc__ = defineComponent({
61
69
  onSelect,
62
70
  computeLabel
63
71
  } = select;
72
+ var {
73
+ hovering,
74
+ handleHovering
75
+ } = useHoverOverlay();
64
76
  var handleClick = () => {
65
77
  if (multiple.value) {
66
78
  optionSelected.value = !optionSelected.value;
@@ -85,6 +97,8 @@ var __sfc__ = defineComponent({
85
97
  optionSelected,
86
98
  multiple,
87
99
  focusColor,
100
+ hovering,
101
+ handleHovering,
88
102
  handleClick,
89
103
  handleSelect
90
104
  };
@@ -1,16 +1,11 @@
1
1
  import { defineListenerProp } from '../utils/components.mjs';
2
2
  export var props = {
3
- show: {
4
- type: Boolean,
5
- default: false
6
- },
3
+ show: Boolean,
7
4
  lockScroll: {
8
5
  type: Boolean,
9
6
  default: true
10
7
  },
11
- teleport: {
12
- type: String
13
- },
8
+ teleport: [String, Object, Boolean],
14
9
  onClick: defineListenerProp(),
15
10
  'onUpdate:show': defineListenerProp()
16
11
  };
@@ -1,8 +1,6 @@
1
1
  import { defineListenerProp } from '../utils/components.mjs';
2
2
  export var props = {
3
- current: {
4
- type: [Number, String]
5
- },
3
+ current: [Number, String],
6
4
  size: {
7
5
  type: [Number, String],
8
6
  default: 10
@@ -19,10 +17,7 @@ export var props = {
19
17
  type: Number,
20
18
  default: 3
21
19
  },
22
- disabled: {
23
- type: Boolean,
24
- default: false
25
- },
20
+ disabled: Boolean,
26
21
  simple: {
27
22
  type: Boolean,
28
23
  default: true
@@ -31,17 +26,12 @@ export var props = {
31
26
  type: Boolean,
32
27
  default: true
33
28
  },
34
- showQuickJumper: {
35
- type: Boolean,
36
- default: false
37
- },
29
+ showQuickJumper: Boolean,
38
30
  sizeOption: {
39
31
  type: Array,
40
32
  default: () => [10, 20, 50, 100]
41
33
  },
42
- showTotal: {
43
- type: Function
44
- },
34
+ showTotal: Function,
45
35
  onChange: defineListenerProp(),
46
36
  'onUpdate:current': defineListenerProp(),
47
37
  'onUpdate:size': defineListenerProp()
@@ -4,26 +4,11 @@ export var props = {
4
4
  type: [Boolean, Number, String],
5
5
  default: false
6
6
  },
7
- ripple: {
8
- type: Boolean,
9
- default: false
10
- },
11
- radius: {
12
- type: [Number, String]
13
- },
14
- width: {
15
- type: [Number, String]
16
- },
17
- height: {
18
- type: [Number, String]
19
- },
20
- round: {
21
- type: Boolean,
22
- default: false
23
- },
24
- inline: {
25
- type: Boolean,
26
- default: false
27
- },
7
+ ripple: Boolean,
8
+ radius: [Number, String],
9
+ width: [Number, String],
10
+ height: [Number, String],
11
+ round: Boolean,
12
+ inline: Boolean,
28
13
  onClick: defineListenerProp()
29
14
  };
@@ -6,9 +6,7 @@ export var props = _extends({
6
6
  type: Array,
7
7
  default: () => []
8
8
  },
9
- title: {
10
- type: String
11
- },
9
+ title: String,
12
10
  textKey: {
13
11
  type: String,
14
12
  default: 'text'
@@ -17,10 +15,7 @@ export var props = _extends({
17
15
  type: Boolean,
18
16
  default: true
19
17
  },
20
- cascade: {
21
- type: Boolean,
22
- default: false
23
- },
18
+ cascade: Boolean,
24
19
  cascadeInitialIndexes: {
25
20
  type: Array,
26
21
  default: () => []
@@ -33,23 +28,12 @@ export var props = _extends({
33
28
  type: [Number, String],
34
29
  default: 6
35
30
  },
36
- confirmButtonText: {
37
- type: String
38
- },
39
- cancelButtonText: {
40
- type: String
41
- },
42
- confirmButtonTextColor: {
43
- type: String
44
- },
45
- cancelButtonTextColor: {
46
- type: String
47
- },
31
+ confirmButtonText: String,
32
+ cancelButtonText: String,
33
+ confirmButtonTextColor: String,
34
+ cancelButtonTextColor: String,
48
35
  // dynamic internal
49
- dynamic: {
50
- type: Boolean,
51
- default: false
52
- },
36
+ dynamic: Boolean,
53
37
  textFormatter: {
54
38
  type: Function,
55
39
  default: text => text
@@ -1,30 +1,17 @@
1
1
  import { defineListenerProp } from '../utils/components.mjs';
2
- function positionValidator(position) {
3
- return ['top', 'bottom', 'right', 'left', 'center'].includes(position);
4
- }
5
2
  export var props = {
6
- show: {
7
- type: Boolean,
8
- default: false
9
- },
3
+ show: Boolean,
10
4
  position: {
11
5
  type: String,
12
- default: 'center',
13
- validator: positionValidator
14
- },
15
- transition: {
16
- type: String
6
+ default: 'center'
17
7
  },
8
+ transition: String,
18
9
  overlay: {
19
10
  type: Boolean,
20
11
  default: true
21
12
  },
22
- overlayClass: {
23
- type: String
24
- },
25
- overlayStyle: {
26
- type: Object
27
- },
13
+ overlayClass: String,
14
+ overlayStyle: Object,
28
15
  lockScroll: {
29
16
  type: Boolean,
30
17
  default: true
@@ -37,14 +24,8 @@ export var props = {
37
24
  type: Boolean,
38
25
  default: true
39
26
  },
40
- safeArea: {
41
- type: Boolean,
42
- default: false
43
- },
44
- safeAreaTop: {
45
- type: Boolean,
46
- default: false
47
- },
27
+ safeArea: Boolean,
28
+ safeAreaTop: Boolean,
48
29
  teleport: {
49
30
  type: [String, Object, Boolean],
50
31
  default: 'body'