@vunk/form 0.0.1-alpha.24 → 0.0.1-alpha.26
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.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { _VkfFormItemCtx, VkfFormItem } from '@vunk/form/components/form-item';
|
|
2
2
|
import { selectProps, selectEmits, createSelectBindProps, createSelectOnEmits } from '@vunk/form/shared/element-plus';
|
|
3
|
-
import { defineComponent, computed, ref, watch, nextTick, resolveComponent, openBlock, createBlock, normalizeProps, guardReactiveProps, withCtx,
|
|
3
|
+
import { defineComponent, computed, ref, watch, nextTick, resolveComponent, openBlock, createBlock, normalizeProps, guardReactiveProps, withCtx, mergeProps, toHandlers, createSlots, createElementBlock, Fragment, renderList, renderSlot, resolveDynamicComponent, createCommentVNode } from 'vue';
|
|
4
4
|
import { ElSelect, ElOption } from 'element-plus';
|
|
5
5
|
import { isPlainObject } from '@vunk/core/shared/utils-object';
|
|
6
6
|
import { useComputedReadonly } from '@vunk/form/composables';
|
|
@@ -106,7 +106,6 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
106
106
|
const _component_VkfFormItem = resolveComponent("VkfFormItem");
|
|
107
107
|
return openBlock(), createBlock(_component_VkfFormItem, normalizeProps(guardReactiveProps(_ctx.formItemBindProps)), {
|
|
108
108
|
default: withCtx(() => [
|
|
109
|
-
createTextVNode(toDisplayString(_ctx.selectBindProps) + " ", 1),
|
|
110
109
|
_ctx.reshow ? (openBlock(), createBlock(_component_ElSelect, mergeProps({ key: 0 }, _ctx.selectBindProps, toHandlers(_ctx.selectOnEmits), {
|
|
111
110
|
disabled: _ctx.readonly || _ctx.disabled,
|
|
112
111
|
class: {
|
|
@@ -399,7 +399,7 @@ var script = defineComponent({
|
|
|
399
399
|
props,
|
|
400
400
|
setup(props2) {
|
|
401
401
|
const formItemBindProps = _VkfFormItemCtx.createBindProps(props2);
|
|
402
|
-
const coreBindProps = createUploadBindProps(props2, ["disabled"]);
|
|
402
|
+
const coreBindProps = createUploadBindProps(props2, ["disabled", "fileList"]);
|
|
403
403
|
const uploadRef = shallowRef();
|
|
404
404
|
const handleRemove = (file) => {
|
|
405
405
|
var _a;
|
|
@@ -425,44 +425,48 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
425
425
|
const _component_ElUpload = resolveComponent("ElUpload");
|
|
426
426
|
const _component_VkfFormItem = resolveComponent("VkfFormItem");
|
|
427
427
|
return openBlock(), createBlock(_component_VkfFormItem, normalizeProps(guardReactiveProps(_ctx.formItemBindProps)), {
|
|
428
|
-
default: withCtx(() =>
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
428
|
+
default: withCtx(() => {
|
|
429
|
+
var _a;
|
|
430
|
+
return [
|
|
431
|
+
createVNode(_component_ElUpload, mergeProps({
|
|
432
|
+
class: ["vkf-upload", {
|
|
433
|
+
"is-readonly": _ctx.readonly
|
|
434
|
+
}]
|
|
435
|
+
}, _ctx.coreBindProps, {
|
|
436
|
+
fileList: (_a = _ctx.fileList) != null ? _a : [],
|
|
437
|
+
"onUpdate:fileList": _cache[0] || (_cache[0] = ($event) => _ctx.$emit("update:fileList", $event)),
|
|
438
|
+
ref: "uploadRef",
|
|
439
|
+
disabled: _ctx.readonly || _ctx.disabled
|
|
440
|
+
}), createSlots({
|
|
441
|
+
file: withCtx(({ file }) => [
|
|
442
|
+
createVNode(_component_FileVue, {
|
|
443
|
+
file,
|
|
444
|
+
listType: _ctx.listType,
|
|
445
|
+
disabled: _ctx.readonly || _ctx.disabled,
|
|
446
|
+
onPreview: _ctx.onPreview,
|
|
447
|
+
onRemove: _ctx.handleRemove
|
|
448
|
+
}, null, 8, ["file", "listType", "disabled", "onPreview", "onRemove"])
|
|
449
|
+
]),
|
|
450
|
+
default: withCtx(() => [
|
|
451
|
+
createVNode(_component_ElLink, { type: "primary" }, {
|
|
452
|
+
default: withCtx(() => [
|
|
453
|
+
_hoisted_1
|
|
454
|
+
]),
|
|
455
|
+
_: 1
|
|
456
|
+
}),
|
|
457
|
+
renderSlot(_ctx.$slots, "default")
|
|
458
|
+
]),
|
|
459
|
+
_: 2
|
|
460
|
+
}, [
|
|
461
|
+
_ctx.tip ? {
|
|
462
|
+
name: "tip",
|
|
463
|
+
fn: withCtx(() => [
|
|
464
|
+
createElementVNode("div", _hoisted_2, toDisplayString(_ctx.tip), 1)
|
|
465
|
+
])
|
|
466
|
+
} : void 0
|
|
467
|
+
]), 1040, ["class", "fileList", "disabled"])
|
|
468
|
+
];
|
|
469
|
+
}),
|
|
466
470
|
_: 3
|
|
467
471
|
}, 16);
|
|
468
472
|
}
|
|
@@ -206,7 +206,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
206
206
|
withCredentials: boolean;
|
|
207
207
|
showFileList: import("element-plus/es/utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
208
208
|
accept: string;
|
|
209
|
-
fileList: import("element-plus").UploadUserFile[];
|
|
210
209
|
autoUpload: import("element-plus/es/utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
211
210
|
httpRequest: import("element-plus").UploadRequestHandler;
|
|
212
211
|
limit: number | undefined;
|