@vunk/form 0.0.1-alpha.26 → 0.0.1-alpha.28
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/components/input-number/index.css +3 -0
- package/components/input-number/index.js +22 -4
- package/components/input-number/src/ctx.d.ts +8 -1
- package/components/input-number/src/ctx.js +13 -1
- package/components/input-number/src/index.vue.d.ts +18 -4
- package/components/upload/index.css +10 -10
- package/components/upload/index.d.ts +1 -0
- package/components/upload/index.js +65 -54
- package/components/upload/src/ctx.d.ts +5 -0
- package/components/upload/src/ctx.js +4 -1
- package/index.css +13 -10
- package/package.json +1 -1
- package/shared/element-plus/index.js +11 -11
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { _VkfFormItemCtx, VkfFormItem } from '@vunk/form/components/form-item';
|
|
2
2
|
import { inputNumberProps, inputNumberEmits, ElInputNumber } from 'element-plus';
|
|
3
|
-
import { defineComponent, resolveComponent, openBlock, createBlock, normalizeProps, guardReactiveProps, withCtx, createVNode, mergeProps, toHandlers } from 'vue';
|
|
3
|
+
import { defineComponent, resolveComponent, openBlock, createBlock, normalizeProps, guardReactiveProps, withCtx, createVNode, mergeProps, toHandlers, createElementBlock, toDisplayString, createCommentVNode } from 'vue';
|
|
4
4
|
import { createInputNumberBindProps, createInputNumberOnEmits } from '@vunk/form/shared/element-plus';
|
|
5
5
|
import { useComputedReadonly } from '@vunk/form/composables';
|
|
6
6
|
|
|
7
7
|
var __defProp = Object.defineProperty;
|
|
8
|
+
var __defProps = Object.defineProperties;
|
|
9
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
8
10
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
9
11
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
10
12
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
@@ -20,7 +22,17 @@ var __spreadValues = (a, b) => {
|
|
|
20
22
|
}
|
|
21
23
|
return a;
|
|
22
24
|
};
|
|
23
|
-
|
|
25
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
26
|
+
const props = __spreadProps(__spreadValues(__spreadValues({}, _VkfFormItemCtx.props), inputNumberProps), {
|
|
27
|
+
readonly: {
|
|
28
|
+
type: Boolean,
|
|
29
|
+
default: void 0
|
|
30
|
+
},
|
|
31
|
+
unit: {
|
|
32
|
+
type: String,
|
|
33
|
+
default: ""
|
|
34
|
+
}
|
|
35
|
+
});
|
|
24
36
|
const emits = __spreadValues({}, inputNumberEmits);
|
|
25
37
|
|
|
26
38
|
var script = defineComponent({
|
|
@@ -32,7 +44,7 @@ var script = defineComponent({
|
|
|
32
44
|
emits,
|
|
33
45
|
props,
|
|
34
46
|
setup(props2, { emit }) {
|
|
35
|
-
const iBindProps = createInputNumberBindProps(props2, ["disabled"]);
|
|
47
|
+
const iBindProps = createInputNumberBindProps(props2, ["disabled", "readonly"]);
|
|
36
48
|
const iOnEmits = createInputNumberOnEmits(emit);
|
|
37
49
|
const formItemBindProps = _VkfFormItemCtx.createBindProps(props2);
|
|
38
50
|
const readonly = useComputedReadonly(props2);
|
|
@@ -45,6 +57,10 @@ var script = defineComponent({
|
|
|
45
57
|
}
|
|
46
58
|
});
|
|
47
59
|
|
|
60
|
+
const _hoisted_1 = {
|
|
61
|
+
key: 0,
|
|
62
|
+
class: "vkf-input-number-unit"
|
|
63
|
+
};
|
|
48
64
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
49
65
|
const _component_ElInputNumber = resolveComponent("ElInputNumber");
|
|
50
66
|
const _component_VkfFormItem = resolveComponent("VkfFormItem");
|
|
@@ -55,8 +71,10 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
55
71
|
"is-readonly": _ctx.readonly
|
|
56
72
|
}
|
|
57
73
|
}, _ctx.iBindProps, toHandlers(_ctx.iOnEmits), {
|
|
74
|
+
readonly: _ctx.readonly,
|
|
58
75
|
disabled: _ctx.readonly || _ctx.disabled
|
|
59
|
-
}), null, 16, ["class", "disabled"])
|
|
76
|
+
}), null, 16, ["class", "readonly", "disabled"]),
|
|
77
|
+
_ctx.unit ? (openBlock(), createElementBlock("span", _hoisted_1, toDisplayString(_ctx.unit), 1)) : createCommentVNode("v-if", true)
|
|
60
78
|
]),
|
|
61
79
|
_: 1
|
|
62
80
|
}, 16);
|
|
@@ -1,11 +1,18 @@
|
|
|
1
1
|
export declare const props: {
|
|
2
|
+
readonly: {
|
|
3
|
+
type: BooleanConstructor;
|
|
4
|
+
default: undefined;
|
|
5
|
+
};
|
|
6
|
+
unit: {
|
|
7
|
+
type: StringConstructor;
|
|
8
|
+
default: string;
|
|
9
|
+
};
|
|
2
10
|
id: import("element-plus/es/utils").EpPropFinalized<StringConstructor, unknown, unknown, undefined, boolean>;
|
|
3
11
|
step: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, 1, boolean>;
|
|
4
12
|
stepStrictly: BooleanConstructor;
|
|
5
13
|
max: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, number, boolean>;
|
|
6
14
|
min: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, number, boolean>;
|
|
7
15
|
modelValue: NumberConstructor;
|
|
8
|
-
readonly: BooleanConstructor;
|
|
9
16
|
disabled: BooleanConstructor;
|
|
10
17
|
size: {
|
|
11
18
|
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
@@ -2,6 +2,8 @@ import { _VkfFormItemCtx } from '@vunk/form/components/form-item';
|
|
|
2
2
|
import { inputNumberProps, inputNumberEmits } from 'element-plus';
|
|
3
3
|
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
5
|
+
var __defProps = Object.defineProperties;
|
|
6
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
5
7
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
6
8
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
9
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
@@ -17,7 +19,17 @@ var __spreadValues = (a, b) => {
|
|
|
17
19
|
}
|
|
18
20
|
return a;
|
|
19
21
|
};
|
|
20
|
-
|
|
22
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
23
|
+
const props = __spreadProps(__spreadValues(__spreadValues({}, _VkfFormItemCtx.props), inputNumberProps), {
|
|
24
|
+
readonly: {
|
|
25
|
+
type: Boolean,
|
|
26
|
+
default: void 0
|
|
27
|
+
},
|
|
28
|
+
unit: {
|
|
29
|
+
type: String,
|
|
30
|
+
default: ""
|
|
31
|
+
}
|
|
32
|
+
});
|
|
21
33
|
const emits = __spreadValues({}, inputNumberEmits);
|
|
22
34
|
|
|
23
35
|
export { emits, props };
|
|
@@ -1,11 +1,18 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
readonly: {
|
|
3
|
+
type: BooleanConstructor;
|
|
4
|
+
default: undefined;
|
|
5
|
+
};
|
|
6
|
+
unit: {
|
|
7
|
+
type: StringConstructor;
|
|
8
|
+
default: string;
|
|
9
|
+
};
|
|
2
10
|
id: import("element-plus/es/utils").EpPropFinalized<StringConstructor, unknown, unknown, undefined, boolean>;
|
|
3
11
|
step: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, 1, boolean>;
|
|
4
12
|
stepStrictly: BooleanConstructor;
|
|
5
13
|
max: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, number, boolean>;
|
|
6
14
|
min: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, number, boolean>;
|
|
7
15
|
modelValue: NumberConstructor;
|
|
8
|
-
readonly: BooleanConstructor;
|
|
9
16
|
disabled: BooleanConstructor;
|
|
10
17
|
size: {
|
|
11
18
|
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
@@ -82,12 +89,11 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
82
89
|
formItemSlots: import("../../form-item/src/types").FormItemSlots | undefined;
|
|
83
90
|
elRef: any;
|
|
84
91
|
inline: boolean;
|
|
85
|
-
readonly: boolean;
|
|
92
|
+
readonly: boolean | undefined;
|
|
86
93
|
}>;
|
|
87
94
|
iBindProps: import("vue").ComputedRef<{
|
|
88
95
|
label: string | undefined;
|
|
89
96
|
size: import("element-plus/es/utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never> | undefined;
|
|
90
|
-
readonly: boolean;
|
|
91
97
|
name: string | undefined;
|
|
92
98
|
id: string | undefined;
|
|
93
99
|
validateEvent: import("element-plus/es/utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
@@ -117,13 +123,20 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
117
123
|
input: (val: number | null | undefined) => boolean;
|
|
118
124
|
"update:modelValue": (val: number | undefined) => boolean;
|
|
119
125
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
126
|
+
readonly: {
|
|
127
|
+
type: BooleanConstructor;
|
|
128
|
+
default: undefined;
|
|
129
|
+
};
|
|
130
|
+
unit: {
|
|
131
|
+
type: StringConstructor;
|
|
132
|
+
default: string;
|
|
133
|
+
};
|
|
120
134
|
id: import("element-plus/es/utils").EpPropFinalized<StringConstructor, unknown, unknown, undefined, boolean>;
|
|
121
135
|
step: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, 1, boolean>;
|
|
122
136
|
stepStrictly: BooleanConstructor;
|
|
123
137
|
max: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, number, boolean>;
|
|
124
138
|
min: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, number, boolean>;
|
|
125
139
|
modelValue: NumberConstructor;
|
|
126
|
-
readonly: BooleanConstructor;
|
|
127
140
|
disabled: BooleanConstructor;
|
|
128
141
|
size: {
|
|
129
142
|
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
@@ -209,5 +222,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
209
222
|
controls: import("element-plus/es/utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
210
223
|
controlsPosition: import("element-plus/es/utils").EpPropMergeType<StringConstructor, "" | "right", unknown>;
|
|
211
224
|
valueOnClear: any;
|
|
225
|
+
unit: string;
|
|
212
226
|
}>;
|
|
213
227
|
export default _default;
|
|
@@ -8,13 +8,13 @@
|
|
|
8
8
|
min-width: 100px;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
.el-upload-list__item-status-label{
|
|
13
|
-
z-index: 1;
|
|
14
|
-
}
|
|
15
|
-
.el-upload-list__item .el-icon--close{
|
|
16
|
-
z-index: 1;
|
|
17
|
-
}
|
|
18
|
-
.el-upload-list__item-name .el-icon.el-icon--download-primary{
|
|
19
|
-
color: var(--el-color-primary);
|
|
20
|
-
}
|
|
11
|
+
|
|
12
|
+
.el-upload-list__item-status-label{
|
|
13
|
+
z-index: 1;
|
|
14
|
+
}
|
|
15
|
+
.el-upload-list__item .el-icon--close{
|
|
16
|
+
z-index: 1;
|
|
17
|
+
}
|
|
18
|
+
.el-upload-list__item-name .el-icon.el-icon--download-primary{
|
|
19
|
+
color: var(--el-color-primary);
|
|
20
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { _VkfFormItemCtx, VkfFormItem } from '@vunk/form/components/form-item';
|
|
2
|
+
import { bindPropsFactory, onEmitsFactory } from '@vunk/core/shared/utils-vue';
|
|
2
3
|
import { uploadProps, ElProgress, ElIcon, useNamespace, useLocale, ElUpload, ElLink } from 'element-plus';
|
|
3
4
|
import { openBlock, createElementBlock, createElementVNode, defineComponent, resolveComponent, Fragment, createCommentVNode, normalizeClass, createBlock, withModifiers, createVNode, withCtx, toDisplayString, normalizeStyle, shallowRef, normalizeProps, guardReactiveProps, mergeProps, createSlots, renderSlot, createTextVNode } from 'vue';
|
|
4
5
|
import { pickObject } from '@vunk/core/shared/utils-object';
|
|
@@ -36,12 +37,22 @@ const props = __spreadProps(__spreadValues(__spreadValues({}, _VkfFormItemCtx.pr
|
|
|
36
37
|
default: ""
|
|
37
38
|
}
|
|
38
39
|
});
|
|
40
|
+
const createBindProps = bindPropsFactory(props);
|
|
39
41
|
const emits = {
|
|
40
42
|
"update:fileList": null,
|
|
41
43
|
"remove": (e) => e
|
|
42
44
|
};
|
|
45
|
+
const createOnEmits = onEmitsFactory(emits);
|
|
43
46
|
|
|
44
|
-
|
|
47
|
+
var ctx = /*#__PURE__*/Object.freeze({
|
|
48
|
+
__proto__: null,
|
|
49
|
+
props: props,
|
|
50
|
+
createBindProps: createBindProps,
|
|
51
|
+
emits: emits,
|
|
52
|
+
createOnEmits: createOnEmits
|
|
53
|
+
});
|
|
54
|
+
|
|
55
|
+
/*! Element Plus Icons Vue v2.0.9 */
|
|
45
56
|
|
|
46
57
|
// unplugin-vue:/plugin-vue/export-helper
|
|
47
58
|
var export_helper_default = (sfc, props) => {
|
|
@@ -65,100 +76,100 @@ function _sfc_render43(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
65
76
|
return openBlock(), createElementBlock("svg", _hoisted_143, _hoisted_342);
|
|
66
77
|
}
|
|
67
78
|
var check_default = /* @__PURE__ */ export_helper_default(_sfc_main43, [["render", _sfc_render43], ["__file", "check.vue"]]);
|
|
68
|
-
var
|
|
79
|
+
var _sfc_main49 = {
|
|
69
80
|
name: "CircleCheck"
|
|
70
|
-
},
|
|
81
|
+
}, _hoisted_149 = {
|
|
71
82
|
viewBox: "0 0 1024 1024",
|
|
72
83
|
xmlns: "http://www.w3.org/2000/svg"
|
|
73
|
-
},
|
|
84
|
+
}, _hoisted_249 = /* @__PURE__ */ createElementVNode("path", {
|
|
74
85
|
fill: "currentColor",
|
|
75
86
|
d: "M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z"
|
|
76
|
-
}, null, -1),
|
|
87
|
+
}, null, -1), _hoisted_348 = /* @__PURE__ */ createElementVNode("path", {
|
|
77
88
|
fill: "currentColor",
|
|
78
89
|
d: "M745.344 361.344a32 32 0 0 1 45.312 45.312l-288 288a32 32 0 0 1-45.312 0l-160-160a32 32 0 1 1 45.312-45.312L480 626.752l265.344-265.408z"
|
|
79
|
-
}, null, -1),
|
|
80
|
-
|
|
81
|
-
|
|
90
|
+
}, null, -1), _hoisted_415 = [
|
|
91
|
+
_hoisted_249,
|
|
92
|
+
_hoisted_348
|
|
82
93
|
];
|
|
83
|
-
function
|
|
84
|
-
return openBlock(), createElementBlock("svg",
|
|
94
|
+
function _sfc_render49(_ctx, _cache, $props, $setup, $data, $options) {
|
|
95
|
+
return openBlock(), createElementBlock("svg", _hoisted_149, _hoisted_415);
|
|
85
96
|
}
|
|
86
|
-
var circle_check_default = /* @__PURE__ */ export_helper_default(
|
|
87
|
-
var
|
|
97
|
+
var circle_check_default = /* @__PURE__ */ export_helper_default(_sfc_main49, [["render", _sfc_render49], ["__file", "circle-check.vue"]]);
|
|
98
|
+
var _sfc_main56 = {
|
|
88
99
|
name: "Close"
|
|
89
|
-
},
|
|
100
|
+
}, _hoisted_156 = {
|
|
90
101
|
viewBox: "0 0 1024 1024",
|
|
91
102
|
xmlns: "http://www.w3.org/2000/svg"
|
|
92
|
-
},
|
|
103
|
+
}, _hoisted_256 = /* @__PURE__ */ createElementVNode("path", {
|
|
93
104
|
fill: "currentColor",
|
|
94
105
|
d: "M764.288 214.592 512 466.88 259.712 214.592a31.936 31.936 0 0 0-45.12 45.12L466.752 512 214.528 764.224a31.936 31.936 0 1 0 45.12 45.184L512 557.184l252.288 252.288a31.936 31.936 0 0 0 45.12-45.12L557.12 512.064l252.288-252.352a31.936 31.936 0 1 0-45.12-45.184z"
|
|
95
|
-
}, null, -1),
|
|
96
|
-
|
|
106
|
+
}, null, -1), _hoisted_355 = [
|
|
107
|
+
_hoisted_256
|
|
97
108
|
];
|
|
98
|
-
function
|
|
99
|
-
return openBlock(), createElementBlock("svg",
|
|
109
|
+
function _sfc_render56(_ctx, _cache, $props, $setup, $data, $options) {
|
|
110
|
+
return openBlock(), createElementBlock("svg", _hoisted_156, _hoisted_355);
|
|
100
111
|
}
|
|
101
|
-
var close_default = /* @__PURE__ */ export_helper_default(
|
|
102
|
-
var
|
|
112
|
+
var close_default = /* @__PURE__ */ export_helper_default(_sfc_main56, [["render", _sfc_render56], ["__file", "close.vue"]]);
|
|
113
|
+
var _sfc_main80 = {
|
|
103
114
|
name: "Delete"
|
|
104
|
-
},
|
|
115
|
+
}, _hoisted_180 = {
|
|
105
116
|
viewBox: "0 0 1024 1024",
|
|
106
117
|
xmlns: "http://www.w3.org/2000/svg"
|
|
107
|
-
},
|
|
118
|
+
}, _hoisted_280 = /* @__PURE__ */ createElementVNode("path", {
|
|
108
119
|
fill: "currentColor",
|
|
109
120
|
d: "M160 256H96a32 32 0 0 1 0-64h256V95.936a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V192h256a32 32 0 1 1 0 64h-64v672a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32V256zm448-64v-64H416v64h192zM224 896h576V256H224v640zm192-128a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32zm192 0a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32z"
|
|
110
|
-
}, null, -1),
|
|
111
|
-
|
|
121
|
+
}, null, -1), _hoisted_379 = [
|
|
122
|
+
_hoisted_280
|
|
112
123
|
];
|
|
113
|
-
function
|
|
114
|
-
return openBlock(), createElementBlock("svg",
|
|
124
|
+
function _sfc_render80(_ctx, _cache, $props, $setup, $data, $options) {
|
|
125
|
+
return openBlock(), createElementBlock("svg", _hoisted_180, _hoisted_379);
|
|
115
126
|
}
|
|
116
|
-
var delete_default = /* @__PURE__ */ export_helper_default(
|
|
117
|
-
var
|
|
127
|
+
var delete_default = /* @__PURE__ */ export_helper_default(_sfc_main80, [["render", _sfc_render80], ["__file", "delete.vue"]]);
|
|
128
|
+
var _sfc_main90 = {
|
|
118
129
|
name: "Document"
|
|
119
|
-
},
|
|
130
|
+
}, _hoisted_190 = {
|
|
120
131
|
viewBox: "0 0 1024 1024",
|
|
121
132
|
xmlns: "http://www.w3.org/2000/svg"
|
|
122
|
-
},
|
|
133
|
+
}, _hoisted_290 = /* @__PURE__ */ createElementVNode("path", {
|
|
123
134
|
fill: "currentColor",
|
|
124
135
|
d: "M832 384H576V128H192v768h640V384zm-26.496-64L640 154.496V320h165.504zM160 64h480l256 256v608a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32zm160 448h384v64H320v-64zm0-192h160v64H320v-64zm0 384h384v64H320v-64z"
|
|
125
|
-
}, null, -1),
|
|
126
|
-
|
|
136
|
+
}, null, -1), _hoisted_389 = [
|
|
137
|
+
_hoisted_290
|
|
127
138
|
];
|
|
128
|
-
function
|
|
129
|
-
return openBlock(), createElementBlock("svg",
|
|
139
|
+
function _sfc_render90(_ctx, _cache, $props, $setup, $data, $options) {
|
|
140
|
+
return openBlock(), createElementBlock("svg", _hoisted_190, _hoisted_389);
|
|
130
141
|
}
|
|
131
|
-
var document_default = /* @__PURE__ */ export_helper_default(
|
|
132
|
-
var
|
|
142
|
+
var document_default = /* @__PURE__ */ export_helper_default(_sfc_main90, [["render", _sfc_render90], ["__file", "document.vue"]]);
|
|
143
|
+
var _sfc_main91 = {
|
|
133
144
|
name: "Download"
|
|
134
|
-
},
|
|
145
|
+
}, _hoisted_191 = {
|
|
135
146
|
viewBox: "0 0 1024 1024",
|
|
136
147
|
xmlns: "http://www.w3.org/2000/svg"
|
|
137
|
-
},
|
|
148
|
+
}, _hoisted_291 = /* @__PURE__ */ createElementVNode("path", {
|
|
138
149
|
fill: "currentColor",
|
|
139
150
|
d: "M160 832h704a32 32 0 1 1 0 64H160a32 32 0 1 1 0-64zm384-253.696 236.288-236.352 45.248 45.248L508.8 704 192 387.2l45.248-45.248L480 584.704V128h64v450.304z"
|
|
140
|
-
}, null, -1),
|
|
141
|
-
|
|
151
|
+
}, null, -1), _hoisted_390 = [
|
|
152
|
+
_hoisted_291
|
|
142
153
|
];
|
|
143
|
-
function
|
|
144
|
-
return openBlock(), createElementBlock("svg",
|
|
154
|
+
function _sfc_render91(_ctx, _cache, $props, $setup, $data, $options) {
|
|
155
|
+
return openBlock(), createElementBlock("svg", _hoisted_191, _hoisted_390);
|
|
145
156
|
}
|
|
146
|
-
var download_default = /* @__PURE__ */ export_helper_default(
|
|
147
|
-
var
|
|
157
|
+
var download_default = /* @__PURE__ */ export_helper_default(_sfc_main91, [["render", _sfc_render91], ["__file", "download.vue"]]);
|
|
158
|
+
var _sfc_main292 = {
|
|
148
159
|
name: "ZoomIn"
|
|
149
|
-
},
|
|
160
|
+
}, _hoisted_1292 = {
|
|
150
161
|
viewBox: "0 0 1024 1024",
|
|
151
162
|
xmlns: "http://www.w3.org/2000/svg"
|
|
152
|
-
},
|
|
163
|
+
}, _hoisted_2292 = /* @__PURE__ */ createElementVNode("path", {
|
|
153
164
|
fill: "currentColor",
|
|
154
165
|
d: "m795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704zm-32-384v-96a32 32 0 0 1 64 0v96h96a32 32 0 0 1 0 64h-96v96a32 32 0 0 1-64 0v-96h-96a32 32 0 0 1 0-64h96z"
|
|
155
|
-
}, null, -1),
|
|
156
|
-
|
|
166
|
+
}, null, -1), _hoisted_3291 = [
|
|
167
|
+
_hoisted_2292
|
|
157
168
|
];
|
|
158
|
-
function
|
|
159
|
-
return openBlock(), createElementBlock("svg",
|
|
169
|
+
function _sfc_render292(_ctx, _cache, $props, $setup, $data, $options) {
|
|
170
|
+
return openBlock(), createElementBlock("svg", _hoisted_1292, _hoisted_3291);
|
|
160
171
|
}
|
|
161
|
-
var zoom_in_default = /* @__PURE__ */ export_helper_default(
|
|
172
|
+
var zoom_in_default = /* @__PURE__ */ export_helper_default(_sfc_main292, [["render", _sfc_render292], ["__file", "zoom-in.vue"]]);
|
|
162
173
|
|
|
163
174
|
const restFetch = new RestFetch({
|
|
164
175
|
baseURL: ""
|
|
@@ -330,8 +341,8 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
330
341
|
createCommentVNode(" Due to close btn only appears when li gets focused disappears after li gets blurred, thus keyboard navigation can never reach close btn"),
|
|
331
342
|
createCommentVNode(" This is a bug which needs to be fixed "),
|
|
332
343
|
createCommentVNode(" TODO: Fix the incorrect navigation interaction "),
|
|
333
|
-
createCommentVNode(` <i v-if="!disabled" :class="nsIcon.m('close-tip')">{{
|
|
334
|
-
t('el.upload.deleteTip')
|
|
344
|
+
createCommentVNode(` <i v-if="!disabled" :class="nsIcon.m('close-tip')">{{
|
|
345
|
+
t('el.upload.deleteTip')
|
|
335
346
|
}}</i> `),
|
|
336
347
|
createCommentVNode(" picture-card "),
|
|
337
348
|
_ctx.listType === "picture-card" ? (openBlock(), createElementBlock("span", {
|
|
@@ -482,4 +493,4 @@ script.install = (app) => {
|
|
|
482
493
|
app.component(script.name, script);
|
|
483
494
|
};
|
|
484
495
|
|
|
485
|
-
export { script as VkfUpload, types as __VkfUpload, script as default };
|
|
496
|
+
export { script as VkfUpload, ctx as _VkfUploadCtx, types as __VkfUpload, script as default };
|
|
@@ -162,7 +162,12 @@ export declare const props: {
|
|
|
162
162
|
default: undefined;
|
|
163
163
|
};
|
|
164
164
|
};
|
|
165
|
+
export declare const createBindProps: <T2 extends import("@vunk/core").NormalObject, EX extends (Extract<"required", keyof T2> | Extract<"type", keyof T2> | Extract<"label", keyof T2> | Extract<"labelWidth", keyof T2> | Extract<"prop", keyof T2> | Extract<"rules", keyof T2> | Extract<"error", keyof T2> | Extract<"validateStatus", keyof T2> | Extract<"for", keyof T2> | Extract<"inlineMessage", keyof T2> | Extract<"showMessage", keyof T2> | Extract<"formItemSize", keyof T2> | Extract<"formItemSlots", keyof T2> | Extract<"elRef", keyof T2> | Extract<"inline", keyof T2> | Extract<"readonly", keyof T2> | Extract<"name", keyof T2> | Extract<"data", keyof T2> | Extract<"disabled", keyof T2> | Extract<"drag", keyof T2> | Extract<"multiple", keyof T2> | Extract<"onChange", keyof T2> | Extract<"onRemove", keyof T2> | Extract<"listType", keyof T2> | Extract<"onPreview", keyof T2> | Extract<"preview", keyof T2> | Extract<"method", keyof T2> | Extract<"beforeUpload", keyof T2> | Extract<"beforeRemove", keyof T2> | Extract<"onSuccess", keyof T2> | Extract<"onProgress", keyof T2> | Extract<"onError", keyof T2> | Extract<"onExceed", keyof T2> | Extract<"action", keyof T2> | Extract<"headers", keyof T2> | Extract<"withCredentials", keyof T2> | Extract<"showFileList", keyof T2> | Extract<"accept", keyof T2> | Extract<"fileList", keyof T2> | Extract<"autoUpload", keyof T2> | Extract<"httpRequest", keyof T2> | Extract<"limit", keyof T2> | Extract<"tip", keyof T2>)[] | undefined>(propsArg: T2, excludes?: EX | undefined) => import("vue").ComputedRef<{ [P in EX extends (infer KE)[] ? Exclude<Extract<"required", keyof T2>, KE> | Exclude<Extract<"type", keyof T2>, KE> | Exclude<Extract<"label", keyof T2>, KE> | Exclude<Extract<"labelWidth", keyof T2>, KE> | Exclude<Extract<"prop", keyof T2>, KE> | Exclude<Extract<"rules", keyof T2>, KE> | Exclude<Extract<"error", keyof T2>, KE> | Exclude<Extract<"validateStatus", keyof T2>, KE> | Exclude<Extract<"for", keyof T2>, KE> | Exclude<Extract<"inlineMessage", keyof T2>, KE> | Exclude<Extract<"showMessage", keyof T2>, KE> | Exclude<Extract<"formItemSize", keyof T2>, KE> | Exclude<Extract<"formItemSlots", keyof T2>, KE> | Exclude<Extract<"elRef", keyof T2>, KE> | Exclude<Extract<"inline", keyof T2>, KE> | Exclude<Extract<"readonly", keyof T2>, KE> | Exclude<Extract<"name", keyof T2>, KE> | Exclude<Extract<"data", keyof T2>, KE> | Exclude<Extract<"disabled", keyof T2>, KE> | Exclude<Extract<"drag", keyof T2>, KE> | Exclude<Extract<"multiple", keyof T2>, KE> | Exclude<Extract<"onChange", keyof T2>, KE> | Exclude<Extract<"onRemove", keyof T2>, KE> | Exclude<Extract<"listType", keyof T2>, KE> | Exclude<Extract<"onPreview", keyof T2>, KE> | Exclude<Extract<"preview", keyof T2>, KE> | Exclude<Extract<"method", keyof T2>, KE> | Exclude<Extract<"beforeUpload", keyof T2>, KE> | Exclude<Extract<"beforeRemove", keyof T2>, KE> | Exclude<Extract<"onSuccess", keyof T2>, KE> | Exclude<Extract<"onProgress", keyof T2>, KE> | Exclude<Extract<"onError", keyof T2>, KE> | Exclude<Extract<"onExceed", keyof T2>, KE> | Exclude<Extract<"action", keyof T2>, KE> | Exclude<Extract<"headers", keyof T2>, KE> | Exclude<Extract<"withCredentials", keyof T2>, KE> | Exclude<Extract<"showFileList", keyof T2>, KE> | Exclude<Extract<"accept", keyof T2>, KE> | Exclude<Extract<"fileList", keyof T2>, KE> | Exclude<Extract<"autoUpload", keyof T2>, KE> | Exclude<Extract<"httpRequest", keyof T2>, KE> | Exclude<Extract<"limit", keyof T2>, KE> | Exclude<Extract<"tip", keyof T2>, KE> : Extract<"required", keyof T2> | Extract<"type", keyof T2> | Extract<"label", keyof T2> | Extract<"labelWidth", keyof T2> | Extract<"prop", keyof T2> | Extract<"rules", keyof T2> | Extract<"error", keyof T2> | Extract<"validateStatus", keyof T2> | Extract<"for", keyof T2> | Extract<"inlineMessage", keyof T2> | Extract<"showMessage", keyof T2> | Extract<"formItemSize", keyof T2> | Extract<"formItemSlots", keyof T2> | Extract<"elRef", keyof T2> | Extract<"inline", keyof T2> | Extract<"readonly", keyof T2> | Extract<"name", keyof T2> | Extract<"data", keyof T2> | Extract<"disabled", keyof T2> | Extract<"drag", keyof T2> | Extract<"multiple", keyof T2> | Extract<"onChange", keyof T2> | Extract<"onRemove", keyof T2> | Extract<"listType", keyof T2> | Extract<"onPreview", keyof T2> | Extract<"preview", keyof T2> | Extract<"method", keyof T2> | Extract<"beforeUpload", keyof T2> | Extract<"beforeRemove", keyof T2> | Extract<"onSuccess", keyof T2> | Extract<"onProgress", keyof T2> | Extract<"onError", keyof T2> | Extract<"onExceed", keyof T2> | Extract<"action", keyof T2> | Extract<"headers", keyof T2> | Extract<"withCredentials", keyof T2> | Extract<"showFileList", keyof T2> | Extract<"accept", keyof T2> | Extract<"fileList", keyof T2> | Extract<"autoUpload", keyof T2> | Extract<"httpRequest", keyof T2> | Extract<"limit", keyof T2> | Extract<"tip", keyof T2>]: { [k in Extract<"required", keyof T2> | Extract<"type", keyof T2> | Extract<"label", keyof T2> | Extract<"labelWidth", keyof T2> | Extract<"prop", keyof T2> | Extract<"rules", keyof T2> | Extract<"error", keyof T2> | Extract<"validateStatus", keyof T2> | Extract<"for", keyof T2> | Extract<"inlineMessage", keyof T2> | Extract<"showMessage", keyof T2> | Extract<"formItemSize", keyof T2> | Extract<"formItemSlots", keyof T2> | Extract<"elRef", keyof T2> | Extract<"inline", keyof T2> | Extract<"readonly", keyof T2> | Extract<"name", keyof T2> | Extract<"data", keyof T2> | Extract<"disabled", keyof T2> | Extract<"drag", keyof T2> | Extract<"multiple", keyof T2> | Extract<"onChange", keyof T2> | Extract<"onRemove", keyof T2> | Extract<"listType", keyof T2> | Extract<"onPreview", keyof T2> | Extract<"preview", keyof T2> | Extract<"method", keyof T2> | Extract<"beforeUpload", keyof T2> | Extract<"beforeRemove", keyof T2> | Extract<"onSuccess", keyof T2> | Extract<"onProgress", keyof T2> | Extract<"onError", keyof T2> | Extract<"onExceed", keyof T2> | Extract<"action", keyof T2> | Extract<"headers", keyof T2> | Extract<"withCredentials", keyof T2> | Extract<"showFileList", keyof T2> | Extract<"accept", keyof T2> | Extract<"fileList", keyof T2> | Extract<"autoUpload", keyof T2> | Extract<"httpRequest", keyof T2> | Extract<"limit", keyof T2> | Extract<"tip", keyof T2>]: T2[k]; }[P]; }>;
|
|
165
166
|
export declare const emits: {
|
|
166
167
|
'update:fileList': null;
|
|
167
168
|
remove: (e: UploadFile) => UploadFile;
|
|
168
169
|
};
|
|
170
|
+
export declare const createOnEmits: <T2 extends import("@vunk/core").AnyFunc, EX extends ("remove" | "update:fileList")[] | undefined>(emit: T2, excludes?: EX | undefined) => { [P in EX extends (infer KE)[] ? Exclude<"remove", KE> | Exclude<"update:fileList", KE> : "remove" | "update:fileList"]: {
|
|
171
|
+
'update:fileList': (...e: import("@vunk/core").RestParameters<T2>) => void;
|
|
172
|
+
remove: (...e: import("@vunk/core").RestParameters<T2>) => void;
|
|
173
|
+
}[P]; };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { _VkfFormItemCtx } from '@vunk/form/components/form-item';
|
|
2
|
+
import { bindPropsFactory, onEmitsFactory } from '@vunk/core/shared/utils-vue';
|
|
2
3
|
import { uploadProps } from 'element-plus';
|
|
3
4
|
|
|
4
5
|
var __defProp = Object.defineProperty;
|
|
@@ -30,9 +31,11 @@ const props = __spreadProps(__spreadValues(__spreadValues({}, _VkfFormItemCtx.pr
|
|
|
30
31
|
default: ""
|
|
31
32
|
}
|
|
32
33
|
});
|
|
34
|
+
const createBindProps = bindPropsFactory(props);
|
|
33
35
|
const emits = {
|
|
34
36
|
"update:fileList": null,
|
|
35
37
|
"remove": (e) => e
|
|
36
38
|
};
|
|
39
|
+
const createOnEmits = onEmitsFactory(emits);
|
|
37
40
|
|
|
38
|
-
export { emits, props };
|
|
41
|
+
export { createBindProps, createOnEmits, emits, props };
|
package/index.css
CHANGED
|
@@ -51,6 +51,9 @@
|
|
|
51
51
|
}
|
|
52
52
|
|
|
53
53
|
|
|
54
|
+
.vkf-input-number-unit{
|
|
55
|
+
margin-left: 6px;
|
|
56
|
+
}
|
|
54
57
|
.el-input-number.is-readonly{
|
|
55
58
|
--el-readonly-cursor: text;
|
|
56
59
|
--el-disabled-bg-color: initial;
|
|
@@ -129,13 +132,13 @@
|
|
|
129
132
|
min-width: 100px;
|
|
130
133
|
}
|
|
131
134
|
|
|
132
|
-
|
|
133
|
-
.el-upload-list__item-status-label{
|
|
134
|
-
z-index: 1;
|
|
135
|
-
}
|
|
136
|
-
.el-upload-list__item .el-icon--close{
|
|
137
|
-
z-index: 1;
|
|
138
|
-
}
|
|
139
|
-
.el-upload-list__item-name .el-icon.el-icon--download-primary{
|
|
140
|
-
color: var(--el-color-primary);
|
|
141
|
-
}
|
|
135
|
+
|
|
136
|
+
.el-upload-list__item-status-label{
|
|
137
|
+
z-index: 1;
|
|
138
|
+
}
|
|
139
|
+
.el-upload-list__item .el-icon--close{
|
|
140
|
+
z-index: 1;
|
|
141
|
+
}
|
|
142
|
+
.el-upload-list__item-name .el-icon.el-icon--download-primary{
|
|
143
|
+
color: var(--el-color-primary);
|
|
144
|
+
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@ import { componentSizes, useTooltipContentProps, tagProps, timePickerDefaultProp
|
|
|
2
2
|
import { bindPropsFactory, onEmitsFactory } from '@vunk/core/shared/utils-vue';
|
|
3
3
|
import { openBlock, createElementBlock, createElementVNode } from 'vue';
|
|
4
4
|
|
|
5
|
-
/*! Element Plus Icons Vue v2.0.
|
|
5
|
+
/*! Element Plus Icons Vue v2.0.9 */
|
|
6
6
|
|
|
7
7
|
// unplugin-vue:/plugin-vue/export-helper
|
|
8
8
|
var export_helper_default = (sfc, props) => {
|
|
@@ -26,25 +26,25 @@ function _sfc_render6(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
26
26
|
return openBlock(), createElementBlock("svg", _hoisted_16, _hoisted_36);
|
|
27
27
|
}
|
|
28
28
|
var arrow_down_default = /* @__PURE__ */ export_helper_default(_sfc_main6, [["render", _sfc_render6], ["__file", "arrow-down.vue"]]);
|
|
29
|
-
var
|
|
29
|
+
var _sfc_main51 = {
|
|
30
30
|
name: "CircleClose"
|
|
31
|
-
},
|
|
31
|
+
}, _hoisted_151 = {
|
|
32
32
|
viewBox: "0 0 1024 1024",
|
|
33
33
|
xmlns: "http://www.w3.org/2000/svg"
|
|
34
|
-
},
|
|
34
|
+
}, _hoisted_251 = /* @__PURE__ */ createElementVNode("path", {
|
|
35
35
|
fill: "currentColor",
|
|
36
36
|
d: "m466.752 512-90.496-90.496a32 32 0 0 1 45.248-45.248L512 466.752l90.496-90.496a32 32 0 1 1 45.248 45.248L557.248 512l90.496 90.496a32 32 0 1 1-45.248 45.248L512 557.248l-90.496 90.496a32 32 0 0 1-45.248-45.248L466.752 512z"
|
|
37
|
-
}, null, -1),
|
|
37
|
+
}, null, -1), _hoisted_350 = /* @__PURE__ */ createElementVNode("path", {
|
|
38
38
|
fill: "currentColor",
|
|
39
39
|
d: "M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z"
|
|
40
|
-
}, null, -1),
|
|
41
|
-
|
|
42
|
-
|
|
40
|
+
}, null, -1), _hoisted_416 = [
|
|
41
|
+
_hoisted_251,
|
|
42
|
+
_hoisted_350
|
|
43
43
|
];
|
|
44
|
-
function
|
|
45
|
-
return openBlock(), createElementBlock("svg",
|
|
44
|
+
function _sfc_render51(_ctx, _cache, $props, $setup, $data, $options) {
|
|
45
|
+
return openBlock(), createElementBlock("svg", _hoisted_151, _hoisted_416);
|
|
46
46
|
}
|
|
47
|
-
var circle_close_default = /* @__PURE__ */ export_helper_default(
|
|
47
|
+
var circle_close_default = /* @__PURE__ */ export_helper_default(_sfc_main51, [["render", _sfc_render51], ["__file", "circle-close.vue"]]);
|
|
48
48
|
|
|
49
49
|
var _a;
|
|
50
50
|
const isClient = typeof window !== "undefined";
|