vxe-pc-ui 4.15.19 → 4.15.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/dist/all.esm.js +132 -67
- package/dist/style.css +1 -1
- package/dist/style.min.css +1 -1
- package/es/checkbox/src/button.js +9 -1
- package/es/checkbox/src/checkbox.js +27 -7
- package/es/icon/style.css +1 -1
- package/es/radio/src/button.js +27 -15
- package/es/radio/src/radio.js +27 -15
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/es/upload/src/upload.js +30 -13
- package/lib/checkbox/src/button.js +10 -0
- package/lib/checkbox/src/button.min.js +1 -1
- package/lib/checkbox/src/checkbox.js +37 -10
- package/lib/checkbox/src/checkbox.min.js +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/index.umd.js +146 -75
- package/lib/index.umd.min.js +1 -1
- package/lib/radio/src/button.js +31 -25
- package/lib/radio/src/button.min.js +1 -1
- package/lib/radio/src/radio.js +31 -25
- package/lib/radio/src/radio.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/ui/index.js +1 -1
- 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 +35 -13
- package/lib/upload/src/upload.min.js +1 -1
- package/package.json +1 -1
- package/packages/checkbox/src/button.ts +11 -1
- package/packages/checkbox/src/checkbox.ts +30 -7
- package/packages/radio/src/button.ts +30 -15
- package/packages/radio/src/radio.ts +30 -15
- package/packages/upload/src/upload.ts +30 -13
- package/types/components/checkbox-button.d.ts +3 -0
- package/types/components/checkbox.d.ts +6 -1
- package/types/components/radio-button.d.ts +3 -1
- package/types/components/radio.d.ts +6 -1
- package/types/components/table.d.ts +6 -1
- package/types/components/upload.d.ts +17 -0
- /package/es/icon/{iconfont.1782955796278.ttf → iconfont.1783046335286.ttf} +0 -0
- /package/es/icon/{iconfont.1782955796278.woff → iconfont.1783046335286.woff} +0 -0
- /package/es/icon/{iconfont.1782955796278.woff2 → iconfont.1783046335286.woff2} +0 -0
- /package/es/{iconfont.1782955796278.ttf → iconfont.1783046335286.ttf} +0 -0
- /package/es/{iconfont.1782955796278.woff → iconfont.1783046335286.woff} +0 -0
- /package/es/{iconfont.1782955796278.woff2 → iconfont.1783046335286.woff2} +0 -0
- /package/lib/icon/style/{iconfont.1782955796278.ttf → iconfont.1783046335286.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1782955796278.woff → iconfont.1783046335286.woff} +0 -0
- /package/lib/icon/style/{iconfont.1782955796278.woff2 → iconfont.1783046335286.woff2} +0 -0
- /package/lib/{iconfont.1782955796278.ttf → iconfont.1783046335286.ttf} +0 -0
- /package/lib/{iconfont.1782955796278.woff → iconfont.1783046335286.woff} +0 -0
- /package/lib/{iconfont.1782955796278.woff2 → iconfont.1783046335286.woff2} +0 -0
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
import { h, computed, reactive, inject, PropType } from 'vue'
|
|
1
|
+
import { h, computed, reactive, inject, PropType, onMounted } from 'vue'
|
|
2
2
|
import { defineVxeComponent } from '../../ui/src/comp'
|
|
3
3
|
import XEUtils from 'xe-utils'
|
|
4
4
|
import { getFuncText } from '../../ui/src/utils'
|
|
5
5
|
import { getConfig, createEvent, useSize, renderEmptyElement } from '../../ui'
|
|
6
|
+
import { createComponentLog } from '../../ui/src/log'
|
|
6
7
|
|
|
7
8
|
import type { VxeRadioButtonPropTypes, VxeRadioGroupConstructor, RadioButtonReactData, RadioButtonPrivateMethods, VxeRadioButtonConstructor, VxeRadioButtonEmits, VxeRadioGroupPrivateMethods, RadioButtonMethods, VxeFormConstructor, VxeFormPrivateMethods, VxeFormDefines, ValueOf } from '../../../types'
|
|
8
9
|
|
|
10
|
+
const { warnLog } = createComponentLog('radio-button')
|
|
11
|
+
|
|
9
12
|
export default defineVxeComponent({
|
|
10
13
|
name: 'VxeRadioButton',
|
|
11
14
|
props: {
|
|
@@ -32,6 +35,7 @@ export default defineVxeComponent({
|
|
|
32
35
|
|
|
33
36
|
/**
|
|
34
37
|
* 已废弃,被 checkedValue 替换
|
|
38
|
+
* @deprecated
|
|
35
39
|
*/
|
|
36
40
|
label: {
|
|
37
41
|
type: [String, Number, Boolean] as PropType<VxeRadioButtonPropTypes.Label>,
|
|
@@ -63,6 +67,11 @@ export default defineVxeComponent({
|
|
|
63
67
|
reactData
|
|
64
68
|
} as unknown as VxeRadioButtonConstructor
|
|
65
69
|
|
|
70
|
+
const computeCheckValue = computed(() => {
|
|
71
|
+
const { checkedValue, label } = props
|
|
72
|
+
return XEUtils.isUndefined(checkedValue) ? label : checkedValue
|
|
73
|
+
})
|
|
74
|
+
|
|
66
75
|
const computeIsDisabled = computed(() => {
|
|
67
76
|
const { disabled } = props
|
|
68
77
|
if (disabled === null) {
|
|
@@ -84,10 +93,12 @@ export default defineVxeComponent({
|
|
|
84
93
|
return $xeRadioGroup ? $xeRadioGroup.props.strict : props.strict
|
|
85
94
|
})
|
|
86
95
|
|
|
87
|
-
const
|
|
88
|
-
const
|
|
89
|
-
|
|
90
|
-
|
|
96
|
+
const computeIsChecked = computed(() => {
|
|
97
|
+
const checkValue = computeCheckValue.value
|
|
98
|
+
if ($xeRadioGroup) {
|
|
99
|
+
return $xeRadioGroup.props.modelValue === checkValue
|
|
100
|
+
}
|
|
101
|
+
return props.modelValue === checkValue
|
|
91
102
|
})
|
|
92
103
|
|
|
93
104
|
const dispatchEvent = (type: ValueOf<VxeRadioButtonEmits>, params: Record<string, any>, evnt: Event | null) => {
|
|
@@ -120,9 +131,8 @@ export default defineVxeComponent({
|
|
|
120
131
|
const changeEvent = (evnt: Event) => {
|
|
121
132
|
const isDisabled = computeIsDisabled.value
|
|
122
133
|
if (!isDisabled) {
|
|
123
|
-
const
|
|
124
|
-
|
|
125
|
-
handleValue(radioValue, evnt)
|
|
134
|
+
const checkValue = computeCheckValue.value
|
|
135
|
+
handleValue(checkValue, evnt)
|
|
126
136
|
}
|
|
127
137
|
}
|
|
128
138
|
|
|
@@ -130,21 +140,20 @@ export default defineVxeComponent({
|
|
|
130
140
|
const isDisabled = computeIsDisabled.value
|
|
131
141
|
const isStrict = computeStrict.value
|
|
132
142
|
if (!isDisabled && !isStrict) {
|
|
133
|
-
const
|
|
134
|
-
|
|
135
|
-
if (radioValue === ($xeRadioGroup ? $xeRadioGroup.props.modelValue : props.modelValue)) {
|
|
143
|
+
const isChecked = computeIsChecked.value
|
|
144
|
+
if (isChecked) {
|
|
136
145
|
handleValue(null, evnt)
|
|
137
146
|
}
|
|
138
147
|
}
|
|
139
148
|
}
|
|
140
149
|
|
|
141
150
|
const renderVN = () => {
|
|
142
|
-
const {
|
|
143
|
-
const radioValue = XEUtils.isUndefined(checkedValue) ? label : checkedValue
|
|
151
|
+
const { icon, content } = props
|
|
144
152
|
const vSize = computeSize.value
|
|
145
153
|
const isDisabled = computeIsDisabled.value
|
|
146
154
|
const name = computeName.value
|
|
147
|
-
const isChecked =
|
|
155
|
+
const isChecked = computeIsChecked.value
|
|
156
|
+
const checkValue = computeCheckValue.value
|
|
148
157
|
const defaultSlot = slots.default
|
|
149
158
|
|
|
150
159
|
if ($xeRadioGroup) {
|
|
@@ -182,7 +191,7 @@ export default defineVxeComponent({
|
|
|
182
191
|
}
|
|
183
192
|
}
|
|
184
193
|
return h('label', {
|
|
185
|
-
key:
|
|
194
|
+
key: `${checkValue}`,
|
|
186
195
|
class: ['vxe-radio vxe-radio--button', {
|
|
187
196
|
[`size--${vSize}`]: vSize,
|
|
188
197
|
'is--disabled': isDisabled
|
|
@@ -221,6 +230,12 @@ export default defineVxeComponent({
|
|
|
221
230
|
])
|
|
222
231
|
}
|
|
223
232
|
|
|
233
|
+
onMounted(() => {
|
|
234
|
+
if (props.label !== null) {
|
|
235
|
+
warnLog('vxe.error.delProp', ['label', 'checked-value'])
|
|
236
|
+
}
|
|
237
|
+
})
|
|
238
|
+
|
|
224
239
|
$xeRadioButton.renderVN = renderVN
|
|
225
240
|
|
|
226
241
|
return renderVN
|
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
import { h, computed, inject, PropType, reactive } from 'vue'
|
|
1
|
+
import { h, computed, inject, PropType, reactive, onMounted } from 'vue'
|
|
2
2
|
import { defineVxeComponent } from '../../ui/src/comp'
|
|
3
3
|
import XEUtils from 'xe-utils'
|
|
4
4
|
import { getFuncText } from '../../ui/src/utils'
|
|
5
5
|
import { getConfig, createEvent, useSize, getIcon, renderEmptyElement } from '../../ui'
|
|
6
|
+
import { createComponentLog } from '../../ui/src/log'
|
|
6
7
|
|
|
7
8
|
import type { VxeRadioPropTypes, VxeRadioConstructor, VxeRadioEmits, RadioReactData, RadioPrivateMethods, VxeRadioGroupConstructor, VxeRadioGroupPrivateMethods, RadioMethods, VxeFormConstructor, ValueOf, VxeFormPrivateMethods, VxeFormDefines } from '../../../types'
|
|
8
9
|
|
|
10
|
+
const { warnLog } = createComponentLog('radio')
|
|
11
|
+
|
|
9
12
|
export default defineVxeComponent({
|
|
10
13
|
name: 'VxeRadio',
|
|
11
14
|
props: {
|
|
@@ -32,6 +35,7 @@ export default defineVxeComponent({
|
|
|
32
35
|
|
|
33
36
|
/**
|
|
34
37
|
* 已废弃,被 checkedValue 替换
|
|
38
|
+
* @deprecated
|
|
35
39
|
*/
|
|
36
40
|
label: {
|
|
37
41
|
type: [String, Number, Boolean] as PropType<VxeRadioPropTypes.Label>,
|
|
@@ -63,6 +67,11 @@ export default defineVxeComponent({
|
|
|
63
67
|
|
|
64
68
|
const { computeSize } = useSize(props)
|
|
65
69
|
|
|
70
|
+
const computeCheckValue = computed(() => {
|
|
71
|
+
const { checkedValue, label } = props
|
|
72
|
+
return XEUtils.isUndefined(checkedValue) ? label : checkedValue
|
|
73
|
+
})
|
|
74
|
+
|
|
66
75
|
const computeIsDisabled = computed(() => {
|
|
67
76
|
const { disabled } = props
|
|
68
77
|
if (disabled === null) {
|
|
@@ -84,10 +93,12 @@ export default defineVxeComponent({
|
|
|
84
93
|
return $xeRadioGroup ? $xeRadioGroup.props.strict : props.strict
|
|
85
94
|
})
|
|
86
95
|
|
|
87
|
-
const
|
|
88
|
-
const
|
|
89
|
-
|
|
90
|
-
|
|
96
|
+
const computeIsChecked = computed(() => {
|
|
97
|
+
const checkValue = computeCheckValue.value
|
|
98
|
+
if ($xeRadioGroup) {
|
|
99
|
+
return $xeRadioGroup.props.modelValue === checkValue
|
|
100
|
+
}
|
|
101
|
+
return props.modelValue === checkValue
|
|
91
102
|
})
|
|
92
103
|
|
|
93
104
|
const handleValue = (checkedValue: VxeRadioPropTypes.CheckedValue, evnt: Event) => {
|
|
@@ -107,9 +118,8 @@ export default defineVxeComponent({
|
|
|
107
118
|
const changeEvent = (evnt: Event) => {
|
|
108
119
|
const isDisabled = computeIsDisabled.value
|
|
109
120
|
if (!isDisabled) {
|
|
110
|
-
const
|
|
111
|
-
|
|
112
|
-
handleValue(radioValue, evnt)
|
|
121
|
+
const checkValue = computeCheckValue.value
|
|
122
|
+
handleValue(checkValue, evnt)
|
|
113
123
|
}
|
|
114
124
|
}
|
|
115
125
|
|
|
@@ -117,9 +127,8 @@ export default defineVxeComponent({
|
|
|
117
127
|
const isDisabled = computeIsDisabled.value
|
|
118
128
|
const isStrict = computeStrict.value
|
|
119
129
|
if (!isDisabled && !isStrict) {
|
|
120
|
-
const
|
|
121
|
-
|
|
122
|
-
if (radioValue === ($xeRadioGroup ? $xeRadioGroup.props.modelValue : props.modelValue)) {
|
|
130
|
+
const isChecked = computeIsChecked.value
|
|
131
|
+
if (isChecked) {
|
|
123
132
|
handleValue(null, evnt)
|
|
124
133
|
}
|
|
125
134
|
}
|
|
@@ -139,12 +148,12 @@ export default defineVxeComponent({
|
|
|
139
148
|
Object.assign($xeRadio, radioMethods, radioPrivateMethods)
|
|
140
149
|
|
|
141
150
|
const renderVN = () => {
|
|
142
|
-
const {
|
|
143
|
-
const radioValue = XEUtils.isUndefined(checkedValue) ? label : checkedValue
|
|
151
|
+
const { content } = props
|
|
144
152
|
const vSize = computeSize.value
|
|
145
153
|
const isDisabled = computeIsDisabled.value
|
|
146
154
|
const name = computeName.value
|
|
147
|
-
const isChecked =
|
|
155
|
+
const isChecked = computeIsChecked.value
|
|
156
|
+
const checkValue = computeCheckValue.value
|
|
148
157
|
const defaultSlot = slots.default
|
|
149
158
|
|
|
150
159
|
if ($xeRadioGroup) {
|
|
@@ -167,7 +176,7 @@ export default defineVxeComponent({
|
|
|
167
176
|
}
|
|
168
177
|
}
|
|
169
178
|
return h('label', {
|
|
170
|
-
key:
|
|
179
|
+
key: `${checkValue}`,
|
|
171
180
|
class: ['vxe-radio vxe-radio--default', {
|
|
172
181
|
[`size--${vSize}`]: vSize,
|
|
173
182
|
'is--checked': isChecked,
|
|
@@ -193,6 +202,12 @@ export default defineVxeComponent({
|
|
|
193
202
|
])
|
|
194
203
|
}
|
|
195
204
|
|
|
205
|
+
onMounted(() => {
|
|
206
|
+
if (props.label !== null) {
|
|
207
|
+
warnLog('vxe.error.delProp', ['label', 'checked-value'])
|
|
208
|
+
}
|
|
209
|
+
})
|
|
210
|
+
|
|
196
211
|
$xeRadio.renderVN = renderVN
|
|
197
212
|
|
|
198
213
|
return $xeRadio
|
|
@@ -217,6 +217,7 @@ export default defineVxeComponent({
|
|
|
217
217
|
},
|
|
218
218
|
emits: [
|
|
219
219
|
'update:modelValue',
|
|
220
|
+
'change',
|
|
220
221
|
'add',
|
|
221
222
|
'remove',
|
|
222
223
|
'remove-fail',
|
|
@@ -491,11 +492,11 @@ export default defineVxeComponent({
|
|
|
491
492
|
emit('update:modelValue', value)
|
|
492
493
|
}
|
|
493
494
|
|
|
494
|
-
const
|
|
495
|
+
const handleChangeEvent = (evnt: Event | null, vals: VxeUploadDefines.FileObjItem[]) => {
|
|
495
496
|
const { singleMode, urlMode, urlArgs } = props
|
|
496
497
|
const urlProp = computeUrlProp.value
|
|
497
498
|
const nameProp = computeNameProp.value
|
|
498
|
-
let restList =
|
|
499
|
+
let restList = vals ? vals.slice(0) : []
|
|
499
500
|
if (urlMode) {
|
|
500
501
|
restList = restList.map(item => {
|
|
501
502
|
const url = item[urlProp]
|
|
@@ -510,7 +511,10 @@ export default defineVxeComponent({
|
|
|
510
511
|
return url
|
|
511
512
|
})
|
|
512
513
|
}
|
|
513
|
-
|
|
514
|
+
const value = singleMode ? (restList[0] || null) : restList
|
|
515
|
+
emitModel(value)
|
|
516
|
+
dispatchEvent('change', { value }, evnt)
|
|
517
|
+
return value
|
|
514
518
|
}
|
|
515
519
|
|
|
516
520
|
const getThumbnailFileUrl = (item: VxeUploadDefines.FileObjItem) => {
|
|
@@ -631,6 +635,7 @@ export default defineVxeComponent({
|
|
|
631
635
|
if (cacheItem) {
|
|
632
636
|
cacheItem.percent = 100
|
|
633
637
|
cacheItem.status = 'success'
|
|
638
|
+
cacheItem.response = res
|
|
634
639
|
}
|
|
635
640
|
Object.assign(item, res)
|
|
636
641
|
dispatchEvent('upload-success', { option: item, data: res }, null)
|
|
@@ -639,6 +644,7 @@ export default defineVxeComponent({
|
|
|
639
644
|
const cacheItem = fileCacheMaps[fileKey]
|
|
640
645
|
if (cacheItem) {
|
|
641
646
|
cacheItem.status = 'error'
|
|
647
|
+
cacheItem.response = res
|
|
642
648
|
}
|
|
643
649
|
if (showErrorStatus) {
|
|
644
650
|
Object.assign(item, res)
|
|
@@ -665,7 +671,7 @@ export default defineVxeComponent({
|
|
|
665
671
|
return Promise.resolve()
|
|
666
672
|
}
|
|
667
673
|
|
|
668
|
-
const
|
|
674
|
+
const handleReUploadEvent = (evnt: MouseEvent, item: VxeUploadDefines.FileObjItem) => {
|
|
669
675
|
const { uploadMethod, urlMode } = props
|
|
670
676
|
const { fileCacheMaps } = reactData
|
|
671
677
|
const fileKey = getFieldKey(item)
|
|
@@ -678,7 +684,7 @@ export default defineVxeComponent({
|
|
|
678
684
|
cacheItem.percent = 0
|
|
679
685
|
handleUploadResult(item, file).then(() => {
|
|
680
686
|
if (urlMode) {
|
|
681
|
-
|
|
687
|
+
handleChangeEvent(evnt, reactData.fileList)
|
|
682
688
|
}
|
|
683
689
|
})
|
|
684
690
|
}
|
|
@@ -784,7 +790,8 @@ export default defineVxeComponent({
|
|
|
784
790
|
file: file,
|
|
785
791
|
loading: !!autoSubmit,
|
|
786
792
|
status: 'pending',
|
|
787
|
-
percent: 0
|
|
793
|
+
percent: 0,
|
|
794
|
+
response: null
|
|
788
795
|
}
|
|
789
796
|
}
|
|
790
797
|
const item = reactive(fileObj)
|
|
@@ -803,9 +810,19 @@ export default defineVxeComponent({
|
|
|
803
810
|
dispatchEvent('add', { option: item }, evnt)
|
|
804
811
|
})
|
|
805
812
|
Promise.all(uploadPromiseRests).then(() => {
|
|
813
|
+
const { fileCacheMaps } = reactData
|
|
806
814
|
const restFileList = reactData.fileList
|
|
807
|
-
|
|
808
|
-
|
|
815
|
+
const uploadResults: VxeUploadDefines.UploadResultObj[] = restFileList.map(option => {
|
|
816
|
+
const fileKey = getFieldKey(option)
|
|
817
|
+
const cacheItem = fileCacheMaps[fileKey]
|
|
818
|
+
return {
|
|
819
|
+
option,
|
|
820
|
+
status: cacheItem ? cacheItem.status : null,
|
|
821
|
+
response: cacheItem ? cacheItem.response : null
|
|
822
|
+
}
|
|
823
|
+
})
|
|
824
|
+
const value = handleChangeEvent(evnt, restFileList)
|
|
825
|
+
dispatchEvent('upload-queue-end', { value, options: restFileList, results: uploadResults, files: selectFiles }, evnt)
|
|
809
826
|
// 自动更新校验状态
|
|
810
827
|
if ($xeForm && formItemInfo) {
|
|
811
828
|
$xeForm.triggerItemEvent(evnt as any, formItemInfo.itemConfig.field, restFileList)
|
|
@@ -842,7 +859,7 @@ export default defineVxeComponent({
|
|
|
842
859
|
const handleRemoveEvent = (evnt: Event | null, item: VxeUploadDefines.FileObjItem, index: number) => {
|
|
843
860
|
const { fileList } = reactData
|
|
844
861
|
fileList.splice(index, 1)
|
|
845
|
-
|
|
862
|
+
handleChangeEvent(evnt, fileList)
|
|
846
863
|
// 自动更新校验状态
|
|
847
864
|
if ($xeForm && formItemInfo) {
|
|
848
865
|
$xeForm.triggerItemEvent(evnt || { type: 'remove' }, formItemInfo.itemConfig.field, fileList)
|
|
@@ -1483,8 +1500,8 @@ export default defineVxeComponent({
|
|
|
1483
1500
|
mode: 'text',
|
|
1484
1501
|
status: 'primary',
|
|
1485
1502
|
content: isError ? getI18n('vxe.upload.reUpload') : getI18n('vxe.upload.manualUpload'),
|
|
1486
|
-
onClick () {
|
|
1487
|
-
|
|
1503
|
+
onClick (evnt) {
|
|
1504
|
+
handleReUploadEvent(evnt, item)
|
|
1488
1505
|
}
|
|
1489
1506
|
})
|
|
1490
1507
|
])
|
|
@@ -1730,8 +1747,8 @@ export default defineVxeComponent({
|
|
|
1730
1747
|
mode: 'text',
|
|
1731
1748
|
status: 'primary',
|
|
1732
1749
|
content: isError ? getI18n('vxe.upload.reUpload') : getI18n('vxe.upload.manualUpload'),
|
|
1733
|
-
onClick () {
|
|
1734
|
-
|
|
1750
|
+
onClick (evnt) {
|
|
1751
|
+
handleReUploadEvent(evnt, item)
|
|
1735
1752
|
}
|
|
1736
1753
|
})
|
|
1737
1754
|
])
|
|
@@ -28,6 +28,7 @@ export namespace VxeCheckboxButtonPropTypes {
|
|
|
28
28
|
export type ModelValue = any
|
|
29
29
|
/**
|
|
30
30
|
* 已废弃,被 CheckedValue 替换
|
|
31
|
+
* @deprecated
|
|
31
32
|
*/
|
|
32
33
|
export type Label = VxeCheckboxPropTypes.Label
|
|
33
34
|
export type Title = VxeCheckboxPropTypes.Title
|
|
@@ -43,6 +44,7 @@ export interface VxeCheckboxButtonProps {
|
|
|
43
44
|
modelValue?: VxeCheckboxButtonPropTypes.ModelValue
|
|
44
45
|
/**
|
|
45
46
|
* 已废弃,被 checked-value 替换
|
|
47
|
+
* @deprecated
|
|
46
48
|
*/
|
|
47
49
|
label?: VxeCheckboxButtonPropTypes.Label
|
|
48
50
|
title?: VxeCheckboxButtonPropTypes.Title
|
|
@@ -79,6 +81,7 @@ export namespace VxeCheckboxButtonDefines {
|
|
|
79
81
|
}
|
|
80
82
|
|
|
81
83
|
export interface ChangeParams {
|
|
84
|
+
value: any
|
|
82
85
|
label: any
|
|
83
86
|
}
|
|
84
87
|
export interface ChangeEventParams extends CheckboxButtonEventParams, ChangeParams { }
|
|
@@ -25,6 +25,10 @@ export interface VxeCheckboxPrivateRef extends CheckboxPrivateRef { }
|
|
|
25
25
|
export namespace VxeCheckboxPropTypes {
|
|
26
26
|
export type Size = VxeComponentSizeType
|
|
27
27
|
export type ModelValue = string | number | boolean | null
|
|
28
|
+
/**
|
|
29
|
+
* 已废弃,被 CheckedValue 替换
|
|
30
|
+
* @deprecated
|
|
31
|
+
*/
|
|
28
32
|
export type Label = string | number
|
|
29
33
|
export type Indeterminate = boolean
|
|
30
34
|
export type Title = string | number
|
|
@@ -41,7 +45,8 @@ export type VxeCheckboxProps = {
|
|
|
41
45
|
*/
|
|
42
46
|
modelValue?: VxeCheckboxPropTypes.ModelValue
|
|
43
47
|
/**
|
|
44
|
-
*
|
|
48
|
+
* 已废弃,被 checked-value 替换
|
|
49
|
+
* @deprecated
|
|
45
50
|
*/
|
|
46
51
|
label?: VxeCheckboxPropTypes.Label
|
|
47
52
|
/**
|
|
@@ -35,6 +35,7 @@ export namespace VxeRadioButtonPropTypes {
|
|
|
35
35
|
|
|
36
36
|
/**
|
|
37
37
|
* 已废弃,被 CheckedValue 替换
|
|
38
|
+
* @deprecated
|
|
38
39
|
*/
|
|
39
40
|
export type Label = VxeRadioPropTypes.Label
|
|
40
41
|
}
|
|
@@ -53,7 +54,8 @@ export interface VxeRadioButtonProps {
|
|
|
53
54
|
disabled?: VxeRadioButtonPropTypes.Disabled
|
|
54
55
|
|
|
55
56
|
/**
|
|
56
|
-
* 已废弃,被
|
|
57
|
+
* 已废弃,被 checked-value 替换
|
|
58
|
+
* @deprecated
|
|
57
59
|
*/
|
|
58
60
|
label?: VxeRadioButtonPropTypes.Label
|
|
59
61
|
}
|
|
@@ -26,6 +26,10 @@ export namespace VxeRadioPropTypes {
|
|
|
26
26
|
export type Size = VxeComponentSizeType
|
|
27
27
|
export type Strict = boolean
|
|
28
28
|
export type ModelValue = any
|
|
29
|
+
/**
|
|
30
|
+
* 已废弃,被 CheckedValue 替换
|
|
31
|
+
* @deprecated
|
|
32
|
+
*/
|
|
29
33
|
export type Label = any
|
|
30
34
|
export type CheckedValue = any
|
|
31
35
|
export type Title = string | number
|
|
@@ -66,7 +70,8 @@ export interface VxeRadioProps {
|
|
|
66
70
|
name?: VxeRadioPropTypes.Name
|
|
67
71
|
|
|
68
72
|
/**
|
|
69
|
-
* 已废弃,被
|
|
73
|
+
* 已废弃,被 checked-value 替换
|
|
74
|
+
* @deprecated
|
|
70
75
|
*/
|
|
71
76
|
label?: VxeRadioPropTypes.Label
|
|
72
77
|
}
|
|
@@ -1016,6 +1016,7 @@ export namespace VxeTablePropTypes {
|
|
|
1016
1016
|
resize?: VxeModalPropTypes.Resize
|
|
1017
1017
|
escClosable?: VxeModalPropTypes.EscClosable
|
|
1018
1018
|
maskClosable?: VxeModalPropTypes.MaskClosable
|
|
1019
|
+
transfer?: VxeModalPropTypes.Transfer
|
|
1019
1020
|
}
|
|
1020
1021
|
/**
|
|
1021
1022
|
* 抽屉模式配置项,用于 mode='drawer'
|
|
@@ -1030,6 +1031,7 @@ export namespace VxeTablePropTypes {
|
|
|
1030
1031
|
resize?: VxeDrawerPropTypes.Resize
|
|
1031
1032
|
escClosable?: VxeDrawerPropTypes.EscClosable
|
|
1032
1033
|
maskClosable?: VxeDrawerPropTypes.MaskClosable
|
|
1034
|
+
transfer?: VxeDrawerPropTypes.Transfer
|
|
1033
1035
|
}
|
|
1034
1036
|
/**
|
|
1035
1037
|
* 默认模式配置项
|
|
@@ -1037,6 +1039,8 @@ export namespace VxeTablePropTypes {
|
|
|
1037
1039
|
popupOptions?: {
|
|
1038
1040
|
mode?: 'inside' | 'outside' | 'auto' | '' | null
|
|
1039
1041
|
width?: number | string
|
|
1042
|
+
minWidth?: number | string
|
|
1043
|
+
maxWidth?: number | string
|
|
1040
1044
|
maxHeight?: number | string
|
|
1041
1045
|
transfer?: boolean
|
|
1042
1046
|
}
|
|
@@ -6994,7 +6998,8 @@ export namespace VxeTableDefines {
|
|
|
6994
6998
|
activeWrapper: boolean
|
|
6995
6999
|
visible: boolean
|
|
6996
7000
|
maxHeight: number | string | null
|
|
6997
|
-
|
|
7001
|
+
defPopupStyle: VxeComponentStyleType
|
|
7002
|
+
panePopupStyle: VxeComponentStyleType
|
|
6998
7003
|
oldSortMaps: Record<string, number>
|
|
6999
7004
|
oldFixedMaps: Record<string, VxeColumnPropTypes.Fixed>
|
|
7000
7005
|
oldVisibleMaps: Record<string, boolean>
|
|
@@ -317,6 +317,7 @@ export interface VxeUploadPrivateMethods extends UploadPrivateMethods { }
|
|
|
317
317
|
|
|
318
318
|
export type VxeUploadEmits = [
|
|
319
319
|
'update:modelValue',
|
|
320
|
+
'change',
|
|
320
321
|
'add',
|
|
321
322
|
'remove',
|
|
322
323
|
'remove-fail',
|
|
@@ -357,17 +358,28 @@ export namespace VxeUploadDefines {
|
|
|
357
358
|
file: File
|
|
358
359
|
}>
|
|
359
360
|
|
|
361
|
+
export interface UploadResultObj {
|
|
362
|
+
option: VxeUploadDefines.FileObjItem
|
|
363
|
+
status: 'error' | 'success' | 'pending' | null
|
|
364
|
+
response: any
|
|
365
|
+
}
|
|
366
|
+
|
|
360
367
|
export interface FileCacheItem {
|
|
361
368
|
file: File
|
|
362
369
|
loading: boolean
|
|
363
370
|
status: 'error' | 'success' | 'pending'
|
|
364
371
|
percent: number
|
|
372
|
+
response: any
|
|
365
373
|
}
|
|
366
374
|
|
|
367
375
|
export interface FileObjItem {
|
|
368
376
|
[key: string]: any
|
|
369
377
|
}
|
|
370
378
|
|
|
379
|
+
export interface ChangeEventParams {
|
|
380
|
+
value: VxeUploadPropTypes.ModelValue
|
|
381
|
+
}
|
|
382
|
+
|
|
371
383
|
export interface AddParams {
|
|
372
384
|
options: VxeUploadDefines.FileObjItem[]
|
|
373
385
|
option: VxeUploadDefines.FileObjItem
|
|
@@ -402,7 +414,9 @@ export namespace VxeUploadDefines {
|
|
|
402
414
|
files: File[]
|
|
403
415
|
}
|
|
404
416
|
export interface UploadQueueEndEventParams extends UploadQueueStartEventParams {
|
|
417
|
+
value: VxeUploadPropTypes.ModelValue
|
|
405
418
|
options: VxeUploadDefines.FileObjItem[]
|
|
419
|
+
results: VxeUploadDefines.UploadResultObj[]
|
|
406
420
|
}
|
|
407
421
|
|
|
408
422
|
export interface MoreVisibleEventParams {
|
|
@@ -412,6 +426,7 @@ export namespace VxeUploadDefines {
|
|
|
412
426
|
|
|
413
427
|
export type VxeUploadEventProps = {
|
|
414
428
|
'onUpdate:modelValue'?: VxeUploadEvents.UpdateModelValue
|
|
429
|
+
onChange?: VxeUploadEvents.Change
|
|
415
430
|
onAdd?: VxeUploadEvents.Add
|
|
416
431
|
onRemove?: VxeUploadEvents.Remove
|
|
417
432
|
onRemoveFail?: VxeUploadEvents.RemoveFail
|
|
@@ -428,6 +443,7 @@ export type VxeUploadEventProps = {
|
|
|
428
443
|
|
|
429
444
|
export interface VxeUploadListeners {
|
|
430
445
|
'update:modelValue'?: VxeUploadEvents.UpdateModelValue
|
|
446
|
+
change?: VxeUploadEvents.Change
|
|
431
447
|
add?: VxeUploadEvents.Add
|
|
432
448
|
remove?: VxeUploadEvents.Remove
|
|
433
449
|
removeFail?: VxeUploadEvents.RemoveFail
|
|
@@ -444,6 +460,7 @@ export interface VxeUploadListeners {
|
|
|
444
460
|
|
|
445
461
|
export namespace VxeUploadEvents {
|
|
446
462
|
export type UpdateModelValue = (modelValue: VxeUploadPropTypes.ModelValue) => void
|
|
463
|
+
export type Change = (params: VxeUploadDefines.ChangeEventParams) => void
|
|
447
464
|
export type Add = (params: VxeUploadDefines.AddEventParams) => void
|
|
448
465
|
export type Remove = (params: VxeUploadDefines.RemoveEventParams) => void
|
|
449
466
|
export type RemoveFail = (params: VxeUploadDefines.RemoveFailEventParams) => void
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|