vxe-pc-ui 4.1.19 → 4.1.21
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 +83 -2
- package/es/anchor/src/anchor-link.js +1 -1
- package/es/anchor/src/anchor.js +1 -1
- package/es/breadcrumb/src/breadcrumb.js +1 -1
- package/es/button/src/button-group.js +4 -1
- package/es/button/src/button.js +2 -1
- package/es/calendar/src/calendar.js +64 -32
- package/es/card/src/card.js +4 -3
- package/es/carousel/src/carousel-item.js +13 -3
- package/es/carousel/src/carousel.js +16 -8
- package/es/checkbox/src/checkbox.js +30 -14
- package/es/checkbox/src/group.js +17 -8
- package/es/collapse-pane/index.js +1 -1
- package/es/countdown/src/countdown.js +17 -8
- package/es/date-picker/src/date-picker.js +148 -69
- package/es/drawer/src/drawer.js +86 -46
- package/es/form/render/index.js +1 -2
- package/es/form/src/form-config-item.js +4 -3
- package/es/form/src/form-gather.js +5 -3
- package/es/form/src/form-item.js +15 -10
- package/es/form/src/form.js +11 -8
- package/es/form/src/render.js +2 -1
- package/es/form/src/util.js +2 -1
- package/es/icon/src/icon.js +3 -0
- package/es/icon/style.css +1 -1
- package/es/icon-picker/src/icon-picker.js +24 -11
- package/es/image/src/group.js +4 -1
- package/es/image/src/preview.js +1 -1
- package/es/input/src/input.js +131 -66
- package/es/layout-aside/src/layout-aside.js +1 -1
- package/es/list/src/list.js +7 -5
- package/es/list-design/src/list-design.js +1 -1
- package/es/list-design/src/list-view.js +1 -1
- package/es/loading/src/loading.js +4 -1
- package/es/menu/src/menu.js +4 -3
- package/es/number-input/src/number-input.js +100 -77
- package/es/pager/src/pager.js +85 -45
- package/es/password-input/src/password-input.js +2 -2
- package/es/print/src/page-break.js +11 -2
- package/es/print/src/print.js +6 -4
- package/es/pulldown/src/pulldown.js +19 -13
- package/es/radio/src/button.js +2 -2
- package/es/radio/src/group.js +8 -4
- package/es/row/src/row.js +1 -1
- package/es/select/src/optgroup.js +19 -10
- package/es/select/src/option.js +17 -9
- package/es/select/src/select.js +64 -41
- package/es/select/src/util.js +2 -2
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/tabs/src/tab-pane.js +13 -3
- package/es/tabs/src/tabs.js +57 -47
- package/es/textarea/src/textarea.js +28 -10
- package/es/tooltip/src/tooltip.js +107 -78
- package/es/tree/src/tree.js +6 -3
- package/es/tree-select/src/tree-select.js +18 -10
- package/es/ui/index.js +1 -7
- package/es/ui/src/log.js +1 -1
- package/es/upload/src/upload.js +5 -5
- package/lib/anchor/src/anchor-link.js +1 -1
- package/lib/anchor/src/anchor-link.min.js +1 -1
- package/lib/anchor/src/anchor.js +1 -1
- package/lib/anchor/src/anchor.min.js +1 -1
- package/lib/breadcrumb/src/breadcrumb.js +1 -1
- package/lib/breadcrumb/src/breadcrumb.min.js +1 -1
- package/lib/button/src/button-group.js +4 -1
- package/lib/button/src/button-group.min.js +1 -1
- package/lib/button/src/button.js +2 -1
- package/lib/button/src/button.min.js +1 -1
- package/lib/calendar/src/calendar.js +42 -24
- package/lib/calendar/src/calendar.min.js +1 -1
- package/lib/card/src/card.js +6 -5
- package/lib/card/src/card.min.js +1 -1
- package/lib/carousel/src/carousel-item.js +16 -3
- package/lib/carousel/src/carousel-item.min.js +1 -1
- package/lib/carousel/src/carousel.js +18 -8
- package/lib/carousel/src/carousel.min.js +1 -1
- package/lib/checkbox/src/checkbox.js +16 -12
- package/lib/checkbox/src/checkbox.min.js +1 -1
- package/lib/checkbox/src/group.js +10 -7
- package/lib/checkbox/src/group.min.js +1 -1
- package/lib/collapse-pane/index.js +1 -1
- package/lib/collapse-pane/index.min.js +1 -1
- package/lib/countdown/src/countdown.js +15 -7
- package/lib/countdown/src/countdown.min.js +1 -1
- package/lib/date-picker/src/date-picker.js +124 -62
- package/lib/date-picker/src/date-picker.min.js +1 -1
- package/lib/drawer/src/drawer.js +15 -30
- package/lib/drawer/src/drawer.min.js +1 -1
- package/lib/form/render/index.js +1 -4
- package/lib/form/render/index.min.js +1 -1
- package/lib/form/src/form-config-item.js +4 -5
- package/lib/form/src/form-config-item.min.js +1 -1
- package/lib/form/src/form-gather.js +11 -9
- package/lib/form/src/form-gather.min.js +1 -1
- package/lib/form/src/form-item.js +11 -12
- package/lib/form/src/form-item.min.js +1 -1
- package/lib/form/src/form.js +7 -7
- package/lib/form/src/form.min.js +1 -1
- package/lib/form/src/render.js +2 -1
- package/lib/form/src/util.js +2 -1
- package/lib/icon/src/icon.js +3 -0
- package/lib/icon/src/icon.min.js +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/icon-picker/src/icon-picker.js +22 -12
- package/lib/icon-picker/src/icon-picker.min.js +1 -1
- package/lib/image/src/group.js +4 -1
- package/lib/image/src/group.min.js +1 -1
- package/lib/image/src/preview.js +1 -1
- package/lib/image/src/preview.min.js +1 -1
- package/lib/index.umd.js +884 -649
- package/lib/index.umd.min.js +1 -1
- package/lib/input/src/input.js +79 -51
- package/lib/input/src/input.min.js +1 -1
- package/lib/layout-aside/src/layout-aside.js +1 -1
- package/lib/layout-aside/src/layout-aside.min.js +1 -1
- package/lib/list/src/list.js +9 -5
- package/lib/list/src/list.min.js +1 -1
- package/lib/list-design/src/list-design.js +1 -1
- package/lib/list-design/src/list-design.min.js +1 -1
- package/lib/list-design/src/list-view.js +1 -1
- package/lib/list-design/src/list-view.min.js +1 -1
- package/lib/loading/src/loading.js +4 -1
- package/lib/loading/src/loading.min.js +1 -1
- package/lib/menu/src/menu.js +4 -3
- package/lib/menu/src/menu.min.js +1 -1
- package/lib/number-input/src/number-input.js +67 -69
- package/lib/number-input/src/number-input.min.js +1 -1
- package/lib/pager/src/pager.js +40 -39
- package/lib/pager/src/pager.min.js +1 -1
- package/lib/password-input/src/password-input.js +2 -2
- package/lib/print/src/page-break.js +14 -2
- package/lib/print/src/page-break.min.js +1 -1
- package/lib/print/src/print.js +8 -6
- package/lib/print/src/print.min.js +1 -1
- package/lib/pulldown/src/pulldown.js +19 -13
- package/lib/pulldown/src/pulldown.min.js +1 -1
- package/lib/radio/src/button.js +2 -2
- package/lib/radio/src/group.js +8 -4
- package/lib/radio/src/group.min.js +1 -1
- package/lib/row/src/row.js +1 -1
- package/lib/row/src/row.min.js +1 -1
- package/lib/select/src/optgroup.js +12 -9
- package/lib/select/src/optgroup.min.js +1 -1
- package/lib/select/src/option.js +9 -7
- package/lib/select/src/option.min.js +1 -1
- package/lib/select/src/select.js +52 -41
- package/lib/select/src/select.min.js +1 -1
- package/lib/select/src/util.js +2 -2
- package/lib/select/src/util.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/tabs/src/tab-pane.js +16 -3
- package/lib/tabs/src/tab-pane.min.js +1 -1
- package/lib/tabs/src/tabs.js +62 -50
- package/lib/tabs/src/tabs.min.js +1 -1
- package/lib/textarea/src/textarea.js +4 -4
- package/lib/tooltip/src/tooltip.js +96 -88
- package/lib/tooltip/src/tooltip.min.js +1 -1
- package/lib/tree/src/tree.js +2 -2
- package/lib/tree/src/tree.min.js +1 -1
- package/lib/tree-select/src/tree-select.js +13 -8
- package/lib/tree-select/src/tree-select.min.js +1 -1
- package/lib/ui/index.js +3 -10
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/lib/upload/src/upload.js +5 -5
- package/lib/upload/src/upload.min.js +1 -1
- package/package.json +2 -2
- package/packages/anchor/src/anchor-link.ts +2 -2
- package/packages/anchor/src/anchor.ts +2 -2
- package/packages/breadcrumb/src/breadcrumb.ts +2 -2
- package/packages/button/src/button-group.ts +4 -1
- package/packages/button/src/button.ts +6 -5
- package/packages/calendar/src/calendar.ts +67 -35
- package/packages/card/src/card.ts +6 -4
- package/packages/carousel/src/carousel-item.ts +19 -4
- package/packages/carousel/src/carousel.ts +19 -11
- package/packages/checkbox/src/checkbox.ts +34 -15
- package/packages/checkbox/src/group.ts +22 -10
- package/packages/collapse-pane/index.ts +1 -1
- package/packages/countdown/src/countdown.ts +20 -11
- package/packages/date-picker/src/date-picker.ts +160 -80
- package/packages/drawer/src/drawer.ts +91 -50
- package/packages/form/render/index.ts +1 -3
- package/packages/form/src/form-config-item.ts +4 -3
- package/packages/form/src/form-gather.ts +5 -3
- package/packages/form/src/form-item.ts +15 -10
- package/packages/form/src/form.ts +12 -10
- package/packages/form/src/render.ts +2 -1
- package/packages/form/src/util.ts +2 -1
- package/packages/icon/src/icon.ts +3 -0
- package/packages/icon-picker/src/icon-picker.ts +31 -17
- package/packages/image/src/group.ts +4 -1
- package/packages/image/src/preview.ts +2 -2
- package/packages/input/src/input.ts +138 -75
- package/packages/layout-aside/src/layout-aside.ts +2 -2
- package/packages/list/src/list.ts +12 -11
- package/packages/list-design/src/list-design.ts +2 -2
- package/packages/list-design/src/list-view.ts +2 -2
- package/packages/loading/src/loading.ts +5 -2
- package/packages/menu/src/menu.ts +5 -4
- package/packages/number-input/src/number-input.ts +102 -79
- package/packages/pager/src/pager.ts +91 -50
- package/packages/password-input/src/password-input.ts +2 -2
- package/packages/print/src/page-break.ts +18 -4
- package/packages/print/src/print.ts +10 -5
- package/packages/pulldown/src/pulldown.ts +28 -22
- package/packages/radio/src/button.ts +2 -2
- package/packages/radio/src/group.ts +9 -5
- package/packages/row/src/row.ts +2 -2
- package/packages/select/src/optgroup.ts +22 -13
- package/packages/select/src/option.ts +18 -10
- package/packages/select/src/select.ts +79 -52
- package/packages/select/src/util.ts +3 -3
- package/packages/tabs/src/tab-pane.ts +20 -5
- package/packages/tabs/src/tabs.ts +59 -49
- package/packages/textarea/src/textarea.ts +28 -10
- package/packages/tooltip/src/tooltip.ts +118 -84
- package/packages/tree/src/tree.ts +7 -4
- package/packages/tree-select/src/tree-select.ts +25 -16
- package/packages/ui/index.ts +0 -7
- package/packages/upload/src/upload.ts +6 -6
- package/types/components/calendar.d.ts +6 -0
- package/types/components/carousel.d.ts +5 -0
- package/types/components/countdown.d.ts +4 -0
- package/types/components/date-picker.d.ts +23 -5
- package/types/components/drawer.d.ts +0 -1
- package/types/components/form.d.ts +4 -2
- package/types/components/icon-picker.d.ts +4 -0
- package/types/components/input.d.ts +9 -1
- package/types/components/list.d.ts +1 -0
- package/types/components/number-input.d.ts +6 -2
- package/types/components/optgroup.d.ts +10 -4
- package/types/components/pulldown.d.ts +5 -1
- package/types/components/select.d.ts +4 -0
- package/types/components/tabs.d.ts +4 -0
- package/types/components/toolbar.d.ts +5 -0
- package/types/components/tooltip.d.ts +4 -0
- package/types/components/tree-select.d.ts +4 -0
- package/types/ui/index.d.ts +0 -22
- /package/es/{collapse-pane → collapse}/src/collapse-pane.js +0 -0
- /package/es/icon/style/{iconfont.1725597808239.ttf → iconfont.1725941866604.ttf} +0 -0
- /package/es/icon/style/{iconfont.1725597808239.woff → iconfont.1725941866604.woff} +0 -0
- /package/es/icon/style/{iconfont.1725597808239.woff2 → iconfont.1725941866604.woff2} +0 -0
- /package/es/{iconfont.1725597808239.ttf → iconfont.1725941866604.ttf} +0 -0
- /package/es/{iconfont.1725597808239.woff → iconfont.1725941866604.woff} +0 -0
- /package/es/{iconfont.1725597808239.woff2 → iconfont.1725941866604.woff2} +0 -0
- /package/lib/{collapse-pane → collapse}/src/collapse-pane.js +0 -0
- /package/lib/{collapse-pane → collapse}/src/collapse-pane.min.js +0 -0
- /package/lib/icon/style/{iconfont.1725597808239.ttf → iconfont.1725941866604.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1725597808239.woff → iconfont.1725941866604.woff} +0 -0
- /package/lib/icon/style/{iconfont.1725597808239.woff2 → iconfont.1725941866604.woff2} +0 -0
- /package/lib/{iconfont.1725597808239.ttf → iconfont.1725941866604.ttf} +0 -0
- /package/lib/{iconfont.1725597808239.woff → iconfont.1725941866604.woff} +0 -0
- /package/lib/{iconfont.1725597808239.woff2 → iconfont.1725941866604.woff2} +0 -0
- /package/packages/{collapse-pane → collapse}/src/collapse-pane.ts +0 -0
|
@@ -5,23 +5,44 @@ import { getLastZIndex, nextZIndex } from '../../ui/src/utils'
|
|
|
5
5
|
import { getAbsolutePos, getDomNode } from '../../ui/src/dom'
|
|
6
6
|
import { getSlotVNs } from '../../ui/src/vn'
|
|
7
7
|
|
|
8
|
-
import type { VxeTooltipPropTypes, VxeTooltipConstructor, VxeTooltipEmits, TooltipReactData, TooltipMethods, TooltipPrivateRef } from '../../../types'
|
|
8
|
+
import type { VxeTooltipPropTypes, VxeTooltipConstructor, VxeTooltipEmits, TooltipInternalData, TooltipReactData, TooltipMethods, TooltipPrivateRef } from '../../../types'
|
|
9
9
|
|
|
10
10
|
export default defineComponent({
|
|
11
11
|
name: 'VxeTooltip',
|
|
12
12
|
props: {
|
|
13
13
|
modelValue: Boolean,
|
|
14
|
-
size: {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
14
|
+
size: {
|
|
15
|
+
type: String as PropType<VxeTooltipPropTypes.Size>,
|
|
16
|
+
default: () => getConfig().tooltip.size || getConfig().size
|
|
17
|
+
},
|
|
18
|
+
trigger: {
|
|
19
|
+
type: String as PropType<VxeTooltipPropTypes.Trigger>,
|
|
20
|
+
default: () => getConfig().tooltip.trigger || 'hover'
|
|
21
|
+
},
|
|
22
|
+
theme: {
|
|
23
|
+
type: String as PropType<VxeTooltipPropTypes.Theme>,
|
|
24
|
+
default: () => getConfig().tooltip.theme || 'dark'
|
|
25
|
+
},
|
|
26
|
+
content: {
|
|
27
|
+
type: [String, Number] as PropType<VxeTooltipPropTypes.Content>,
|
|
28
|
+
default: null
|
|
29
|
+
},
|
|
18
30
|
useHTML: Boolean as PropType<VxeTooltipPropTypes.UseHTML>,
|
|
19
31
|
zIndex: [String, Number] as PropType<VxeTooltipPropTypes.ZIndex>,
|
|
20
32
|
popupClassName: [String, Function] as PropType<VxeTooltipPropTypes.PopupClassName>,
|
|
21
|
-
isArrow: {
|
|
33
|
+
isArrow: {
|
|
34
|
+
type: Boolean as PropType<VxeTooltipPropTypes.IsArrow>,
|
|
35
|
+
default: true
|
|
36
|
+
},
|
|
22
37
|
enterable: Boolean as PropType<VxeTooltipPropTypes.Enterable>,
|
|
23
|
-
enterDelay: {
|
|
24
|
-
|
|
38
|
+
enterDelay: {
|
|
39
|
+
type: Number as PropType<VxeTooltipPropTypes.EnterDelay>,
|
|
40
|
+
default: () => getConfig().tooltip.enterDelay
|
|
41
|
+
},
|
|
42
|
+
leaveDelay: {
|
|
43
|
+
type: Number as PropType<VxeTooltipPropTypes.LeaveDelay>,
|
|
44
|
+
default: () => getConfig().tooltip.leaveDelay
|
|
45
|
+
}
|
|
25
46
|
},
|
|
26
47
|
emits: [
|
|
27
48
|
'update:modelValue'
|
|
@@ -48,6 +69,9 @@ export default defineComponent({
|
|
|
48
69
|
}
|
|
49
70
|
})
|
|
50
71
|
|
|
72
|
+
const internalData: TooltipInternalData = {
|
|
73
|
+
}
|
|
74
|
+
|
|
51
75
|
const refElem = ref() as Ref<HTMLDivElement>
|
|
52
76
|
|
|
53
77
|
const refMaps: TooltipPrivateRef = {
|
|
@@ -59,6 +83,7 @@ export default defineComponent({
|
|
|
59
83
|
props,
|
|
60
84
|
context,
|
|
61
85
|
reactData,
|
|
86
|
+
internalData,
|
|
62
87
|
getRefMaps: () => refMaps
|
|
63
88
|
} as unknown as VxeTooltipConstructor
|
|
64
89
|
|
|
@@ -162,11 +187,13 @@ export default defineComponent({
|
|
|
162
187
|
return tooltipMethods.updatePlacement()
|
|
163
188
|
}
|
|
164
189
|
|
|
165
|
-
const
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
190
|
+
const handleDelayFn = () => {
|
|
191
|
+
internalData.showDelayTip = XEUtils.debounce(() => {
|
|
192
|
+
if (reactData.tipActive) {
|
|
193
|
+
showTip()
|
|
194
|
+
}
|
|
195
|
+
}, props.enterDelay, { leading: false, trailing: true })
|
|
196
|
+
}
|
|
170
197
|
|
|
171
198
|
const handleVisible = (target: HTMLElement | null, content?: VxeTooltipPropTypes.Content) => {
|
|
172
199
|
const contentSlot = slots.content
|
|
@@ -174,12 +201,15 @@ export default defineComponent({
|
|
|
174
201
|
return nextTick()
|
|
175
202
|
}
|
|
176
203
|
if (target) {
|
|
204
|
+
const { showDelayTip } = internalData
|
|
177
205
|
const { trigger, enterDelay } = props
|
|
178
206
|
reactData.tipActive = true
|
|
179
207
|
reactData.tipTarget = target
|
|
180
208
|
reactData.tipContent = content
|
|
181
209
|
if (enterDelay && trigger === 'hover') {
|
|
182
|
-
showDelayTip
|
|
210
|
+
if (showDelayTip) {
|
|
211
|
+
showDelayTip()
|
|
212
|
+
}
|
|
183
213
|
} else {
|
|
184
214
|
return showTip()
|
|
185
215
|
}
|
|
@@ -214,22 +244,85 @@ export default defineComponent({
|
|
|
214
244
|
const el = refElem.value
|
|
215
245
|
if (tipTarget && el) {
|
|
216
246
|
updateTipStyle()
|
|
217
|
-
return nextTick().then(
|
|
247
|
+
return nextTick().then(() => {
|
|
248
|
+
updateTipStyle()
|
|
249
|
+
})
|
|
218
250
|
}
|
|
219
251
|
})
|
|
220
252
|
},
|
|
221
253
|
isActived () {
|
|
222
254
|
return reactData.tipActive
|
|
223
255
|
},
|
|
224
|
-
setActived (
|
|
225
|
-
reactData.tipActive = !!
|
|
256
|
+
setActived (active) {
|
|
257
|
+
reactData.tipActive = !!active
|
|
226
258
|
}
|
|
227
259
|
}
|
|
228
260
|
|
|
229
261
|
Object.assign($xeTooltip, tooltipMethods)
|
|
230
262
|
|
|
231
|
-
|
|
232
|
-
|
|
263
|
+
const renderContent = () => {
|
|
264
|
+
const { useHTML } = props
|
|
265
|
+
const { tipContent } = reactData
|
|
266
|
+
const contentSlot = slots.content
|
|
267
|
+
if (contentSlot) {
|
|
268
|
+
return h('div', {
|
|
269
|
+
key: 1,
|
|
270
|
+
class: 'vxe-table--tooltip-content'
|
|
271
|
+
}, getSlotVNs(contentSlot({})))
|
|
272
|
+
}
|
|
273
|
+
if (useHTML) {
|
|
274
|
+
return h('div', {
|
|
275
|
+
key: 2,
|
|
276
|
+
class: 'vxe-table--tooltip-content',
|
|
277
|
+
innerHTML: tipContent
|
|
278
|
+
})
|
|
279
|
+
}
|
|
280
|
+
return h('div', {
|
|
281
|
+
key: 3,
|
|
282
|
+
class: 'vxe-table--tooltip-content'
|
|
283
|
+
}, `${tipContent}`)
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
const renderVN = () => {
|
|
287
|
+
const { popupClassName, theme, isArrow, enterable } = props
|
|
288
|
+
const { tipActive, visible, tipStore } = reactData
|
|
289
|
+
const defaultSlot = slots.default
|
|
290
|
+
const vSize = computeSize.value
|
|
291
|
+
let ons
|
|
292
|
+
if (enterable) {
|
|
293
|
+
ons = {
|
|
294
|
+
onMouseenter: wrapperMouseenterEvent,
|
|
295
|
+
onMouseleave: wrapperMouseleaveEvent
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
return h('div', {
|
|
299
|
+
ref: refElem,
|
|
300
|
+
class: ['vxe-table--tooltip-wrapper', `theme--${theme}`, popupClassName ? (XEUtils.isFunction(popupClassName) ? popupClassName({ $tooltip: $xeTooltip }) : popupClassName) : '', {
|
|
301
|
+
[`size--${vSize}`]: vSize,
|
|
302
|
+
[`placement--${tipStore.placement}`]: tipStore.placement,
|
|
303
|
+
'is--enterable': enterable,
|
|
304
|
+
'is--visible': visible,
|
|
305
|
+
'is--arrow': isArrow,
|
|
306
|
+
'is--active': tipActive
|
|
307
|
+
}],
|
|
308
|
+
style: tipStore.style,
|
|
309
|
+
...ons
|
|
310
|
+
}, [
|
|
311
|
+
renderContent(),
|
|
312
|
+
h('div', {
|
|
313
|
+
class: 'vxe-table--tooltip-arrow',
|
|
314
|
+
style: tipStore.arrowStyle
|
|
315
|
+
}),
|
|
316
|
+
...(defaultSlot ? getSlotVNs(defaultSlot({})) : [])
|
|
317
|
+
])
|
|
318
|
+
}
|
|
319
|
+
|
|
320
|
+
watch(() => props.enterDelay, () => {
|
|
321
|
+
handleDelayFn()
|
|
322
|
+
})
|
|
323
|
+
|
|
324
|
+
watch(() => props.content, (val) => {
|
|
325
|
+
reactData.tipContent = val
|
|
233
326
|
})
|
|
234
327
|
|
|
235
328
|
watch(() => props.modelValue, (val) => {
|
|
@@ -245,7 +338,7 @@ export default defineComponent({
|
|
|
245
338
|
|
|
246
339
|
onMounted(() => {
|
|
247
340
|
nextTick(() => {
|
|
248
|
-
const { trigger, content
|
|
341
|
+
const { trigger, content } = props
|
|
249
342
|
const wrapperElem = refElem.value
|
|
250
343
|
if (wrapperElem) {
|
|
251
344
|
const parentNode = wrapperElem.parentNode
|
|
@@ -270,7 +363,7 @@ export default defineComponent({
|
|
|
270
363
|
target.onclick = clickEvent
|
|
271
364
|
}
|
|
272
365
|
}
|
|
273
|
-
if (modelValue) {
|
|
366
|
+
if (props.modelValue) {
|
|
274
367
|
handleVisible(target, content)
|
|
275
368
|
}
|
|
276
369
|
}
|
|
@@ -279,16 +372,12 @@ export default defineComponent({
|
|
|
279
372
|
})
|
|
280
373
|
|
|
281
374
|
onBeforeUnmount(() => {
|
|
282
|
-
const { trigger } = props
|
|
283
375
|
const { target } = reactData
|
|
284
376
|
const wrapperElem = refElem.value
|
|
285
377
|
if (target) {
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
} else if (trigger === 'click') {
|
|
290
|
-
target.onclick = null
|
|
291
|
-
}
|
|
378
|
+
target.onmouseenter = null
|
|
379
|
+
target.onmouseleave = null
|
|
380
|
+
target.onclick = null
|
|
292
381
|
}
|
|
293
382
|
if (wrapperElem) {
|
|
294
383
|
const parentNode = wrapperElem.parentNode
|
|
@@ -298,62 +387,7 @@ export default defineComponent({
|
|
|
298
387
|
}
|
|
299
388
|
})
|
|
300
389
|
|
|
301
|
-
|
|
302
|
-
const { useHTML } = props
|
|
303
|
-
const { tipContent } = reactData
|
|
304
|
-
const contentSlot = slots.content
|
|
305
|
-
if (contentSlot) {
|
|
306
|
-
return h('div', {
|
|
307
|
-
key: 1,
|
|
308
|
-
class: 'vxe-table--tooltip-content'
|
|
309
|
-
}, getSlotVNs(contentSlot({})))
|
|
310
|
-
}
|
|
311
|
-
if (useHTML) {
|
|
312
|
-
return h('div', {
|
|
313
|
-
key: 2,
|
|
314
|
-
class: 'vxe-table--tooltip-content',
|
|
315
|
-
innerHTML: tipContent
|
|
316
|
-
})
|
|
317
|
-
}
|
|
318
|
-
return h('div', {
|
|
319
|
-
key: 3,
|
|
320
|
-
class: 'vxe-table--tooltip-content'
|
|
321
|
-
}, `${tipContent}`)
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
const renderVN = () => {
|
|
325
|
-
const { popupClassName, theme, isArrow, enterable } = props
|
|
326
|
-
const { tipActive, visible, tipStore } = reactData
|
|
327
|
-
const defaultSlot = slots.default
|
|
328
|
-
const vSize = computeSize.value
|
|
329
|
-
let ons
|
|
330
|
-
if (enterable) {
|
|
331
|
-
ons = {
|
|
332
|
-
onMouseenter: wrapperMouseenterEvent,
|
|
333
|
-
onMouseleave: wrapperMouseleaveEvent
|
|
334
|
-
}
|
|
335
|
-
}
|
|
336
|
-
return h('div', {
|
|
337
|
-
ref: refElem,
|
|
338
|
-
class: ['vxe-table--tooltip-wrapper', `theme--${theme}`, popupClassName ? (XEUtils.isFunction(popupClassName) ? popupClassName({ $tooltip: $xeTooltip }) : popupClassName) : '', {
|
|
339
|
-
[`size--${vSize}`]: vSize,
|
|
340
|
-
[`placement--${tipStore.placement}`]: tipStore.placement,
|
|
341
|
-
'is--enterable': enterable,
|
|
342
|
-
'is--visible': visible,
|
|
343
|
-
'is--arrow': isArrow,
|
|
344
|
-
'is--active': tipActive
|
|
345
|
-
}],
|
|
346
|
-
style: tipStore.style,
|
|
347
|
-
...ons
|
|
348
|
-
}, [
|
|
349
|
-
renderContent(),
|
|
350
|
-
h('div', {
|
|
351
|
-
class: 'vxe-table--tooltip-arrow',
|
|
352
|
-
style: tipStore.arrowStyle
|
|
353
|
-
}),
|
|
354
|
-
...(defaultSlot ? getSlotVNs(defaultSlot({})) : [])
|
|
355
|
-
])
|
|
356
|
-
}
|
|
390
|
+
handleDelayFn()
|
|
357
391
|
|
|
358
392
|
$xeTooltip.renderVN = renderVN
|
|
359
393
|
|
|
@@ -109,7 +109,10 @@ export default defineComponent({
|
|
|
109
109
|
type: String as PropType<VxeTreePropTypes.IconLoaded>,
|
|
110
110
|
default: () => getConfig().tree.iconLoaded
|
|
111
111
|
},
|
|
112
|
-
size: {
|
|
112
|
+
size: {
|
|
113
|
+
type: String as PropType<VxeTreePropTypes.Size>,
|
|
114
|
+
default: () => getConfig().tree.size || getConfig().size
|
|
115
|
+
}
|
|
113
116
|
},
|
|
114
117
|
emits: [
|
|
115
118
|
'update:modelValue',
|
|
@@ -490,7 +493,7 @@ export default defineComponent({
|
|
|
490
493
|
const { lazy, transform } = props
|
|
491
494
|
const { nodeMaps } = reactData
|
|
492
495
|
if (!lazy) {
|
|
493
|
-
return
|
|
496
|
+
return Promise.resolve([])
|
|
494
497
|
}
|
|
495
498
|
const childrenField = computeChildrenField.value
|
|
496
499
|
const parentNodeItem = nodeMaps[getNodeId(node)]
|
|
@@ -1135,8 +1138,6 @@ export default defineComponent({
|
|
|
1135
1138
|
])
|
|
1136
1139
|
}
|
|
1137
1140
|
|
|
1138
|
-
$xeTree.renderVN = renderVN
|
|
1139
|
-
|
|
1140
1141
|
const dataFlag = ref(0)
|
|
1141
1142
|
watch(() => props.data ? props.data.length : 0, () => {
|
|
1142
1143
|
dataFlag.value++
|
|
@@ -1172,6 +1173,8 @@ export default defineComponent({
|
|
|
1172
1173
|
updateData(props.data || [])
|
|
1173
1174
|
updateCheckboxChecked(props.checkNodeKeys || [])
|
|
1174
1175
|
|
|
1176
|
+
$xeTree.renderVN = renderVN
|
|
1177
|
+
|
|
1175
1178
|
return $xeTree
|
|
1176
1179
|
},
|
|
1177
1180
|
render () {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, ref, computed, h, PropType, Ref, nextTick, inject, reactive, Teleport, createCommentVNode, onMounted, onUnmounted, watch } from 'vue'
|
|
1
|
+
import { defineComponent, ref, computed, h, PropType, Ref, nextTick, inject, provide, reactive, Teleport, createCommentVNode, onMounted, onUnmounted, watch } from 'vue'
|
|
2
2
|
import { getConfig, getI18n, getIcon, globalEvents, createEvent, useSize } from '../../ui'
|
|
3
3
|
import { getEventTargetNode, getAbsolutePos } from '../../ui/src/dom'
|
|
4
4
|
import { getLastZIndex, nextZIndex } from '../../ui/src/utils'
|
|
@@ -6,7 +6,7 @@ import XEUtils from 'xe-utils'
|
|
|
6
6
|
import VxeInputComponent from '../../input/src/input'
|
|
7
7
|
import VxeTreeComponent from '../../tree/src/tree'
|
|
8
8
|
|
|
9
|
-
import type { TreeSelectReactData, VxeTreeSelectEmits, TreeSelectPrivateRef, TreeSelectPrivateMethods, TreeSelectMethods, VxeTreeSelectPrivateComputed, VxeTreeSelectPropTypes, VxeTreeSelectConstructor, VxeFormDefines, VxeTreeSelectPrivateMethods, VxeTableConstructor, VxeTablePrivateMethods, VxeFormConstructor, VxeFormPrivateMethods, VxeInputConstructor, VxeModalConstructor, VxeModalMethods } from '../../../types'
|
|
9
|
+
import type { TreeSelectReactData, VxeTreeSelectEmits, TreeSelectInternalData, TreeSelectPrivateRef, TreeSelectPrivateMethods, TreeSelectMethods, VxeTreeSelectPrivateComputed, VxeTreeSelectPropTypes, VxeTreeSelectConstructor, VxeFormDefines, VxeDrawerConstructor, VxeDrawerMethods, VxeTreeSelectPrivateMethods, VxeTableConstructor, VxeTablePrivateMethods, VxeFormConstructor, VxeFormPrivateMethods, VxeInputConstructor, VxeModalConstructor, VxeModalMethods } from '../../../types'
|
|
10
10
|
|
|
11
11
|
function getOptUniqueId () {
|
|
12
12
|
return XEUtils.uniqueId('node_')
|
|
@@ -37,7 +37,10 @@ export default defineComponent({
|
|
|
37
37
|
placement: String as PropType<VxeTreeSelectPropTypes.Placement>,
|
|
38
38
|
options: Array as PropType<VxeTreeSelectPropTypes.Options>,
|
|
39
39
|
optionProps: Object as PropType<VxeTreeSelectPropTypes.OptionProps>,
|
|
40
|
-
size: {
|
|
40
|
+
size: {
|
|
41
|
+
type: String as PropType<VxeTreeSelectPropTypes.Size>,
|
|
42
|
+
default: () => getConfig().select.size || getConfig().size
|
|
43
|
+
},
|
|
41
44
|
remote: Boolean as PropType<VxeTreeSelectPropTypes.Remote>,
|
|
42
45
|
remoteMethod: Function as PropType<VxeTreeSelectPropTypes.RemoteMethod>,
|
|
43
46
|
treeConfig: Object as PropType<VxeTreeSelectPropTypes.TreeConfig>,
|
|
@@ -58,9 +61,10 @@ export default defineComponent({
|
|
|
58
61
|
setup (props, context) {
|
|
59
62
|
const { emit, slots } = context
|
|
60
63
|
|
|
61
|
-
const $xeModal = inject<VxeModalConstructor & VxeModalMethods
|
|
62
|
-
const $
|
|
63
|
-
const $
|
|
64
|
+
const $xeModal = inject<(VxeModalConstructor & VxeModalMethods)| null>('$xeModal', null)
|
|
65
|
+
const $xeDrawer = inject<(VxeDrawerConstructor & VxeDrawerMethods) | null>('$xeDrawer', null)
|
|
66
|
+
const $xeTable = inject<(VxeTableConstructor & VxeTablePrivateMethods) | null>('$xeTable', null)
|
|
67
|
+
const $xeForm = inject<(VxeFormConstructor & VxeFormPrivateMethods) | null>('$xeForm', null)
|
|
64
68
|
const formItemInfo = inject<VxeFormDefines.ProvideItemInfo | null>('xeFormItemInfo', null)
|
|
65
69
|
|
|
66
70
|
const xID = XEUtils.uniqueId()
|
|
@@ -86,6 +90,10 @@ export default defineComponent({
|
|
|
86
90
|
isActivated: false
|
|
87
91
|
})
|
|
88
92
|
|
|
93
|
+
const internalData: TreeSelectInternalData = {
|
|
94
|
+
hpTimeout: undefined
|
|
95
|
+
}
|
|
96
|
+
|
|
89
97
|
const refMaps: TreeSelectPrivateRef = {
|
|
90
98
|
refElem
|
|
91
99
|
}
|
|
@@ -119,7 +127,7 @@ export default defineComponent({
|
|
|
119
127
|
if (XEUtils.isBoolean(globalTransfer)) {
|
|
120
128
|
return globalTransfer
|
|
121
129
|
}
|
|
122
|
-
if ($xeTable || $xeModal || $xeForm) {
|
|
130
|
+
if ($xeTable || $xeModal || $xeDrawer || $xeForm) {
|
|
123
131
|
return true
|
|
124
132
|
}
|
|
125
133
|
}
|
|
@@ -185,9 +193,9 @@ export default defineComponent({
|
|
|
185
193
|
const computeSelectLabel = computed(() => {
|
|
186
194
|
const { modelValue } = props
|
|
187
195
|
const { fullNodeMaps } = reactData
|
|
196
|
+
const labelField = computeLabelField.value
|
|
188
197
|
return (XEUtils.isArray(modelValue) ? modelValue : [modelValue]).map(value => {
|
|
189
198
|
const cacheItem = fullNodeMaps[value]
|
|
190
|
-
const labelField = computeLabelField.value
|
|
191
199
|
return cacheItem ? cacheItem.item[labelField] : value
|
|
192
200
|
}).join(', ')
|
|
193
201
|
})
|
|
@@ -200,6 +208,7 @@ export default defineComponent({
|
|
|
200
208
|
props,
|
|
201
209
|
context,
|
|
202
210
|
reactData,
|
|
211
|
+
internalData,
|
|
203
212
|
|
|
204
213
|
getRefMaps: () => refMaps,
|
|
205
214
|
getComputeMaps: () => computeMaps
|
|
@@ -235,7 +244,7 @@ export default defineComponent({
|
|
|
235
244
|
parent: any
|
|
236
245
|
nodes: any[]
|
|
237
246
|
}> = {}
|
|
238
|
-
XEUtils.eachTree(options, (item, index, items, parent, nodes) => {
|
|
247
|
+
XEUtils.eachTree(options, (item, index, items, path, parent, nodes) => {
|
|
239
248
|
let nodeid = getOptid(item)
|
|
240
249
|
if (!nodeid) {
|
|
241
250
|
nodeid = getOptUniqueId()
|
|
@@ -325,13 +334,11 @@ export default defineComponent({
|
|
|
325
334
|
})
|
|
326
335
|
}
|
|
327
336
|
|
|
328
|
-
let hidePanelTimeout: number
|
|
329
|
-
|
|
330
337
|
const showOptionPanel = () => {
|
|
331
338
|
const { loading } = props
|
|
332
339
|
const isDisabled = computeIsDisabled.value
|
|
333
340
|
if (!loading && !isDisabled) {
|
|
334
|
-
clearTimeout(
|
|
341
|
+
clearTimeout(internalData.hpTimeout)
|
|
335
342
|
if (!reactData.initialized) {
|
|
336
343
|
reactData.initialized = true
|
|
337
344
|
}
|
|
@@ -347,16 +354,16 @@ export default defineComponent({
|
|
|
347
354
|
|
|
348
355
|
const hideOptionPanel = () => {
|
|
349
356
|
reactData.visiblePanel = false
|
|
350
|
-
|
|
357
|
+
internalData.hpTimeout = window.setTimeout(() => {
|
|
351
358
|
reactData.visibleAnimate = false
|
|
352
359
|
}, 350)
|
|
353
360
|
}
|
|
354
361
|
|
|
355
362
|
const changeEvent = (evnt: Event, selectValue: any) => {
|
|
356
363
|
const { fullNodeMaps } = reactData
|
|
364
|
+
emit('update:modelValue', selectValue)
|
|
357
365
|
if (selectValue !== props.modelValue) {
|
|
358
366
|
const cacheItem = fullNodeMaps[selectValue]
|
|
359
|
-
emit('update:modelValue', selectValue)
|
|
360
367
|
treeSelectMethods.dispatchEvent('change', { value: selectValue, option: cacheItem ? cacheItem.item : null }, evnt)
|
|
361
368
|
// 自动更新校验状态
|
|
362
369
|
if ($xeForm && formItemInfo) {
|
|
@@ -609,8 +616,6 @@ export default defineComponent({
|
|
|
609
616
|
])
|
|
610
617
|
}
|
|
611
618
|
|
|
612
|
-
$xeTreeSelect.renderVN = renderVN
|
|
613
|
-
|
|
614
619
|
watch(() => props.options, () => {
|
|
615
620
|
cacheItemMap()
|
|
616
621
|
})
|
|
@@ -629,6 +634,10 @@ export default defineComponent({
|
|
|
629
634
|
globalEvents.off($xeTreeSelect, 'blur')
|
|
630
635
|
})
|
|
631
636
|
|
|
637
|
+
provide('$xeTreeSelect', $xeTreeSelect)
|
|
638
|
+
|
|
639
|
+
$xeTreeSelect.renderVN = renderVN
|
|
640
|
+
|
|
632
641
|
return $xeTreeSelect
|
|
633
642
|
},
|
|
634
643
|
render () {
|
package/packages/ui/index.ts
CHANGED
|
@@ -32,13 +32,6 @@ export function setup (options?: VxeGlobalConfig) {
|
|
|
32
32
|
VxeUI.config = config
|
|
33
33
|
VxeUI.setup = setup
|
|
34
34
|
|
|
35
|
-
/**
|
|
36
|
-
* 已废弃
|
|
37
|
-
* @deprecated
|
|
38
|
-
*/
|
|
39
|
-
export const globalStore = {}
|
|
40
|
-
VxeUI.globalStore = globalStore
|
|
41
|
-
|
|
42
35
|
setConfig({
|
|
43
36
|
alert: {},
|
|
44
37
|
anchor: {},
|
|
@@ -373,7 +373,7 @@ export default defineComponent({
|
|
|
373
373
|
emit(type, createEvent(evnt, { $upload: $xeUpload }, params))
|
|
374
374
|
}
|
|
375
375
|
|
|
376
|
-
const
|
|
376
|
+
const handleChange = (value: VxeUploadDefines.FileObjItem[]) => {
|
|
377
377
|
const { singleMode, urlMode } = props
|
|
378
378
|
const urlProp = computeUrlProp.value
|
|
379
379
|
let restList = value ? value.slice(0) : []
|
|
@@ -534,7 +534,7 @@ export default defineComponent({
|
|
|
534
534
|
cacheItem.percent = 0
|
|
535
535
|
handleUploadResult(item, file).then(() => {
|
|
536
536
|
if (urlMode) {
|
|
537
|
-
|
|
537
|
+
handleChange(reactData.fileList)
|
|
538
538
|
}
|
|
539
539
|
})
|
|
540
540
|
}
|
|
@@ -645,7 +645,7 @@ export default defineComponent({
|
|
|
645
645
|
reactData.fileList = newFileList
|
|
646
646
|
reactData.fileCacheMaps = cacheMaps
|
|
647
647
|
Promise.all(urlMode ? uploadPromiseRests : []).then(() => {
|
|
648
|
-
|
|
648
|
+
handleChange(newFileList)
|
|
649
649
|
// 自动更新校验状态
|
|
650
650
|
if ($xeForm && formItemInfo) {
|
|
651
651
|
$xeForm.triggerItemEvent(evnt as any, formItemInfo.itemConfig.field, newFileList)
|
|
@@ -682,7 +682,7 @@ export default defineComponent({
|
|
|
682
682
|
const handleRemoveEvent = (evnt: MouseEvent, item: VxeUploadDefines.FileObjItem, index: number) => {
|
|
683
683
|
const { fileList } = reactData
|
|
684
684
|
fileList.splice(index, 1)
|
|
685
|
-
|
|
685
|
+
handleChange(fileList)
|
|
686
686
|
// 自动更新校验状态
|
|
687
687
|
if ($xeForm && formItemInfo) {
|
|
688
688
|
$xeForm.triggerItemEvent(evnt, formItemInfo.itemConfig.field, fileList)
|
|
@@ -1278,8 +1278,6 @@ export default defineComponent({
|
|
|
1278
1278
|
])
|
|
1279
1279
|
}
|
|
1280
1280
|
|
|
1281
|
-
$xeUpload.renderVN = renderVN
|
|
1282
|
-
|
|
1283
1281
|
const listFlag = ref(0)
|
|
1284
1282
|
watch(() => props.modelValue ? props.modelValue.length : 0, () => {
|
|
1285
1283
|
listFlag.value++
|
|
@@ -1305,6 +1303,8 @@ export default defineComponent({
|
|
|
1305
1303
|
|
|
1306
1304
|
updateFileList()
|
|
1307
1305
|
|
|
1306
|
+
$xeUpload.renderVN = renderVN
|
|
1307
|
+
|
|
1308
1308
|
return $xeUpload
|
|
1309
1309
|
},
|
|
1310
1310
|
render () {
|
|
@@ -72,6 +72,12 @@ export interface CalendarReactData {
|
|
|
72
72
|
currentDate: any
|
|
73
73
|
}
|
|
74
74
|
|
|
75
|
+
export interface CalendarInternalData {
|
|
76
|
+
yearSize: number
|
|
77
|
+
monthSize: number
|
|
78
|
+
quarterSize: number
|
|
79
|
+
}
|
|
80
|
+
|
|
75
81
|
export interface CalendarMethods {
|
|
76
82
|
dispatchEvent(type: ValueOf<VxeCalendarEmits>, params: Record<string, any>, evnt: Event | null): void
|
|
77
83
|
}
|
|
@@ -63,6 +63,11 @@ export interface CarouselReactData {
|
|
|
63
63
|
itemHeight: number
|
|
64
64
|
}
|
|
65
65
|
|
|
66
|
+
export interface CarouselInternalData {
|
|
67
|
+
apTimeout: undefined | number
|
|
68
|
+
stopFlag: boolean
|
|
69
|
+
}
|
|
70
|
+
|
|
66
71
|
export interface CarouselMethods {
|
|
67
72
|
dispatchEvent(type: ValueOf<VxeCarouselEmits>, params: Record<string, any>, evnt: Event | null): void
|
|
68
73
|
/**
|
|
@@ -53,6 +53,10 @@ export interface CountdownReactData {
|
|
|
53
53
|
secondNum: number
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
+
export interface CountdownInternalData {
|
|
57
|
+
dnTimeout: number | undefined
|
|
58
|
+
}
|
|
59
|
+
|
|
56
60
|
export interface CountdownMethods {
|
|
57
61
|
dispatchEvent(type: ValueOf<VxeCountdownEmits>, params: Record<string, any>, evnt: Event | null): void
|
|
58
62
|
}
|
|
@@ -34,13 +34,13 @@ export namespace VxeDatePickerPropTypes {
|
|
|
34
34
|
export type Readonly = boolean
|
|
35
35
|
export type Disabled = boolean
|
|
36
36
|
export type Placeholder = string
|
|
37
|
-
export type
|
|
37
|
+
export type MaxLength = string | number
|
|
38
38
|
export type Multiple = boolean
|
|
39
39
|
export type ShowWordCount = boolean
|
|
40
40
|
export type CountMethod = (params: {
|
|
41
41
|
value: string
|
|
42
42
|
}) => number
|
|
43
|
-
export type
|
|
43
|
+
export type AutoComplete = string
|
|
44
44
|
export type Align = string
|
|
45
45
|
export type Form = string
|
|
46
46
|
export type Min = string | number
|
|
@@ -64,6 +64,17 @@ export namespace VxeDatePickerPropTypes {
|
|
|
64
64
|
export type SuffixIcon = string
|
|
65
65
|
export type Placement = 'top' | 'bottom' | '' | null
|
|
66
66
|
export type Transfer = boolean
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* 请使用 AutoComplete
|
|
70
|
+
* @deprecated
|
|
71
|
+
*/
|
|
72
|
+
export type Autocomplete = string
|
|
73
|
+
/**
|
|
74
|
+
* 请使用 MaxLength
|
|
75
|
+
* @deprecated
|
|
76
|
+
*/
|
|
77
|
+
export type Maxlength = string | number
|
|
67
78
|
}
|
|
68
79
|
|
|
69
80
|
export interface VxeDatePickerProps {
|
|
@@ -77,7 +88,7 @@ export interface VxeDatePickerProps {
|
|
|
77
88
|
readonly?: VxeDatePickerPropTypes.Readonly
|
|
78
89
|
disabled?: VxeDatePickerPropTypes.Disabled
|
|
79
90
|
placeholder?: VxeDatePickerPropTypes.Placeholder
|
|
80
|
-
|
|
91
|
+
maxLength?: VxeDatePickerPropTypes.MaxLength
|
|
81
92
|
multiple?: VxeDatePickerPropTypes.Multiple
|
|
82
93
|
/**
|
|
83
94
|
* 是否显示字数统计
|
|
@@ -131,11 +142,11 @@ export interface DatePickerReactData {
|
|
|
131
142
|
panelIndex: number
|
|
132
143
|
visiblePanel: boolean
|
|
133
144
|
isAniVisible: boolean
|
|
134
|
-
panelStyle: VxeComponentStyleType
|
|
145
|
+
panelStyle: VxeComponentStyleType
|
|
135
146
|
panelPlacement: VxeDatePickerPropTypes.Placement
|
|
136
147
|
isActivated: boolean
|
|
137
148
|
inputValue: any
|
|
138
|
-
datetimePanelValue:
|
|
149
|
+
datetimePanelValue: Date | null
|
|
139
150
|
datePanelValue: Date | null
|
|
140
151
|
datePanelLabel: string
|
|
141
152
|
datePanelType: VxeDatePickerDefines.DatePanelType
|
|
@@ -143,6 +154,13 @@ export interface DatePickerReactData {
|
|
|
143
154
|
currentDate: any
|
|
144
155
|
}
|
|
145
156
|
|
|
157
|
+
export interface DatePickerInternalData {
|
|
158
|
+
yearSize: number
|
|
159
|
+
monthSize: number
|
|
160
|
+
quarterSize: number
|
|
161
|
+
hpTimeout?: undefined | number
|
|
162
|
+
}
|
|
163
|
+
|
|
146
164
|
export interface DatePickerMethods {
|
|
147
165
|
dispatchEvent(type: ValueOf<VxeDatePickerEmits>, params: Record<string, any>, evnt: Event | null): void
|
|
148
166
|
/**
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { RenderFunction, SetupContext, Ref, ComputedRef } from 'vue'
|
|
2
2
|
import { DefineVxeComponentApp, DefineVxeComponentOptions, DefineVxeComponentInstance, VxeComponentBaseOptions, VxeComponentEventParams, VxeComponentSizeType, ValueOf, VxeComponentSlotType } from '@vxe-ui/core'
|
|
3
3
|
import { VxeFormItemPropTypes, VxeFormItemProps } from './form-item'
|
|
4
|
+
import { VxeGridConstructor } from './grid'
|
|
4
5
|
|
|
5
6
|
/* eslint-disable no-use-before-define,@typescript-eslint/ban-types */
|
|
6
7
|
|
|
@@ -18,7 +19,7 @@ export interface VxeFormConstructor<D = any> extends VxeComponentBaseOptions, Vx
|
|
|
18
19
|
getComputeMaps(): FormPrivateComputed
|
|
19
20
|
renderVN: RenderFunction
|
|
20
21
|
|
|
21
|
-
xegrid:
|
|
22
|
+
xegrid: VxeGridConstructor | null
|
|
22
23
|
}
|
|
23
24
|
|
|
24
25
|
export interface FormPrivateRef {
|
|
@@ -122,7 +123,8 @@ export interface FormReactData {
|
|
|
122
123
|
}
|
|
123
124
|
|
|
124
125
|
export interface FormInternalData {
|
|
125
|
-
|
|
126
|
+
meTimeout: undefined | number
|
|
127
|
+
stTimeout: undefined | number
|
|
126
128
|
tooltipStore: {
|
|
127
129
|
item: VxeFormDefines.ItemInfo | null
|
|
128
130
|
visible: boolean
|