@fangzhongya/fang-ui 0.0.98 → 0.0.99
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/components/alert/src/index2.cjs +11 -11
- package/dist/components/array/src/index2.cjs +45 -45
- package/dist/components/audios/src/index2.cjs +54 -54
- package/dist/components/autocomplete/src/index2.cjs +11 -11
- package/dist/components/box/src/index2.cjs +21 -21
- package/dist/components/box-adjust/index.css +17 -0
- package/dist/components/box-adjust/index.scss +18 -0
- package/dist/components/box-adjust/src/data.cjs +17 -1
- package/dist/components/box-adjust/src/data.d.ts +16 -0
- package/dist/components/box-adjust/src/data.js +17 -1
- package/dist/components/box-adjust/src/index2.cjs +69 -35
- package/dist/components/box-adjust/src/index2.js +37 -3
- package/dist/components/box-local/src/index2.cjs +20 -20
- package/dist/components/box-mask/src/index2.cjs +5 -5
- package/dist/components/box-teleport/src/index2.cjs +5 -5
- package/dist/components/box-title/src/index2.cjs +15 -15
- package/dist/components/button/src/index2.cjs +11 -11
- package/dist/components/buttons/src/index2.cjs +20 -20
- package/dist/components/card/src/index2.cjs +11 -11
- package/dist/components/cascader/src/index2.cjs +11 -11
- package/dist/components/cascader-panel/src/index2.cjs +11 -11
- package/dist/components/cascaders/src/index2.cjs +17 -17
- package/dist/components/checkbox/src/index2.cjs +11 -11
- package/dist/components/checkbox-button/src/index2.cjs +11 -11
- package/dist/components/checkbox-group/src/index2.cjs +11 -11
- package/dist/components/checks/src/index2.cjs +31 -31
- package/dist/components/choice-select/src/index2.cjs +5 -5
- package/dist/components/collapse/src/index2.cjs +11 -11
- package/dist/components/collapse-item/src/index2.cjs +11 -11
- package/dist/components/color-picker/src/index2.cjs +11 -11
- package/dist/components/common/list.cjs +5 -5
- package/dist/components/common/use.cjs +5 -5
- package/dist/components/company-select/src/index2.cjs +19 -19
- package/dist/components/config-provider/src/index2.cjs +11 -11
- package/dist/components/date-picker/src/index2.cjs +11 -11
- package/dist/components/date-picker/style/element.scss +1 -1
- package/dist/components/date-picker-panel/src/index2.cjs +11 -11
- package/dist/components/dates/src/index2.cjs +12 -12
- package/dist/components/dates-divide/src/index2.cjs +20 -20
- package/dist/components/dates-picker/src/index2.cjs +15 -15
- package/dist/components/dates2/src/index2.cjs +26 -26
- package/dist/components/department-select/src/index2.cjs +10 -10
- package/dist/components/dialog/src/index2.cjs +11 -11
- package/dist/components/dialogs/src/index2.cjs +23 -23
- package/dist/components/divider/src/index2.cjs +11 -11
- package/dist/components/drawer/src/index2.cjs +11 -11
- package/dist/components/dropdown/src/index2.cjs +11 -11
- package/dist/components/dropdown-item/src/index2.cjs +11 -11
- package/dist/components/dropdown-menu/src/index2.cjs +11 -11
- package/dist/components/edit/src/index2.cjs +24 -24
- package/dist/components/edit-float/src/index2.cjs +40 -40
- package/dist/components/form/src/index2.cjs +11 -11
- package/dist/components/form-item/src/index2.cjs +11 -11
- package/dist/components/forms/index.css +22 -0
- package/dist/components/forms/src/index2.cjs +65 -65
- package/dist/components/forms/src/setup.cjs +12 -12
- package/dist/components/forms-div/src/index2.cjs +11 -11
- package/dist/components/forms-drag/src/index2.cjs +73 -73
- package/dist/components/forms-item/src/index2.cjs +45 -45
- package/dist/components/forms-item/src/label.cjs +4 -4
- package/dist/components/forms-items/src/index2.cjs +23 -23
- package/dist/components/full-screen/src/index2.cjs +11 -11
- package/dist/components/global-config/src/index.cjs +5 -5
- package/dist/components/history/src/index2.cjs +26 -26
- package/dist/components/icon/src/index2.cjs +23 -23
- package/dist/components/icon-picker/src/index2.cjs +52 -52
- package/dist/components/iframe/src/data.cjs +1 -1
- package/dist/components/iframe/src/data.js +1 -1
- package/dist/components/iframe/src/index2.cjs +15 -10
- package/dist/components/iframe/src/index2.js +5 -0
- package/dist/components/image/src/index2.cjs +11 -11
- package/dist/components/image-viewer/src/index2.cjs +11 -11
- package/dist/components/images/src/index2.cjs +17 -17
- package/dist/components/input/src/index2.cjs +11 -11
- package/dist/components/input-array/src/index2.cjs +38 -38
- package/dist/components/input-history/src/index2.cjs +47 -47
- package/dist/components/input-history/src/util.cjs +4 -4
- package/dist/components/input-num/src/index2.cjs +17 -17
- package/dist/components/input-number/src/index2.cjs +11 -11
- package/dist/components/input-select/src/index2.cjs +51 -51
- package/dist/components/input-tag/src/index2.cjs +11 -11
- package/dist/components/inputs/src/index2.cjs +17 -17
- package/dist/components/keep-com/src/index2.cjs +16 -16
- package/dist/components/labels/src/index2.cjs +13 -13
- package/dist/components/list/src/index2.cjs +24 -24
- package/dist/components/lists/src/index2.cjs +51 -51
- package/dist/components/listsp/src/index2.cjs +35 -35
- package/dist/components/mention/src/index2.cjs +11 -11
- package/dist/components/menu/src/index2.cjs +11 -11
- package/dist/components/menu-item/src/index2.cjs +11 -11
- package/dist/components/menu-item-group/src/index2.cjs +11 -11
- package/dist/components/menus/src/index2.cjs +16 -16
- package/dist/components/menus/src/menu-ll2.cjs +11 -11
- package/dist/components/no-data/src/index2.cjs +5 -5
- package/dist/components/option/src/index2.cjs +10 -10
- package/dist/components/option-group/src/index2.cjs +11 -11
- package/dist/components/page/index.css +22 -0
- package/dist/components/page/src/index2.cjs +77 -77
- package/dist/components/page/src/set-column2.cjs +54 -54
- package/dist/components/pagination/src/index2.cjs +11 -11
- package/dist/components/paging/src/index2.cjs +13 -13
- package/dist/components/popconfirm/src/index2.cjs +11 -11
- package/dist/components/popover/src/index2.cjs +11 -11
- package/dist/components/popup/src/index2.cjs +29 -29
- package/dist/components/radio/src/index2.cjs +11 -11
- package/dist/components/radio-button/src/index2.cjs +11 -11
- package/dist/components/radio-group/src/index2.cjs +11 -11
- package/dist/components/retract/src/index2.cjs +14 -14
- package/dist/components/right-key/src/index2.cjs +30 -30
- package/dist/components/role-select/src/index2.cjs +38 -38
- package/dist/components/scrollbar/src/index2.cjs +11 -11
- package/dist/components/seamless-scroll/src/index2.cjs +24 -24
- package/dist/components/select/src/index2.cjs +11 -11
- package/dist/components/select-dialog/src/index2.cjs +65 -65
- package/dist/components/select-popover/src/index2.cjs +41 -41
- package/dist/components/select-scroll/src/index2.cjs +30 -30
- package/dist/components/selector/src/index2.cjs +39 -39
- package/dist/components/selects/src/index2.cjs +20 -20
- package/dist/components/slider/src/index2.cjs +11 -11
- package/dist/components/sliders/src/index2.cjs +13 -13
- package/dist/components/stick-div/src/index2.cjs +17 -17
- package/dist/components/stick-edge/src/index2.cjs +10 -10
- package/dist/components/stick-window/src/index2.cjs +22 -22
- package/dist/components/sub-menu/src/index2.cjs +10 -10
- package/dist/components/switch/src/index2.cjs +11 -11
- package/dist/components/switchs/src/index2.cjs +15 -15
- package/dist/components/tab-pane/src/index2.cjs +11 -11
- package/dist/components/table/src/index2.cjs +11 -11
- package/dist/components/table-column/src/index2.cjs +11 -11
- package/dist/components/tables/common/img2.cjs +7 -7
- package/dist/components/tables/common/pagin.cjs +16 -16
- package/dist/components/tables/common/table-but2.cjs +10 -10
- package/dist/components/tables/common/table-color2.cjs +7 -7
- package/dist/components/tables/common/table-list2.cjs +9 -9
- package/dist/components/tables/common/util.cjs +2 -2
- package/dist/components/tables/src/column.cjs +5 -5
- package/dist/components/tables/src/columns2.cjs +2 -2
- package/dist/components/tables/src/columns3.cjs +2 -2
- package/dist/components/tables/src/index2.cjs +29 -29
- package/dist/components/tablesp/src/index2.cjs +36 -36
- package/dist/components/tabless/src/index2.cjs +49 -49
- package/dist/components/tablesv/src/column.cjs +16 -16
- package/dist/components/tablesv/src/columns2.cjs +2 -2
- package/dist/components/tablesv/src/columns3.cjs +2 -2
- package/dist/components/tablesv/src/index2.cjs +30 -30
- package/dist/components/tablesvp/src/index2.cjs +30 -30
- package/dist/components/tabs/src/index2.cjs +11 -11
- package/dist/components/tag/src/index2.cjs +11 -11
- package/dist/components/text/src/index2.cjs +11 -11
- package/dist/components/text/style/element.scss +1 -1
- package/dist/components/texts/src/index2.cjs +8 -8
- package/dist/components/time-picker/src/index2.cjs +11 -11
- package/dist/components/time-select/src/index2.cjs +11 -11
- package/dist/components/tooltip/src/index2.cjs +11 -11
- package/dist/components/transfer/src/index2.cjs +11 -11
- package/dist/components/tree/src/index2.cjs +11 -11
- package/dist/components/tree-select/src/index2.cjs +11 -11
- package/dist/components/tree-select-box/src/index2.cjs +29 -29
- package/dist/components/upload/src/index2.cjs +11 -11
- package/dist/components/uploads/index.css +22 -0
- package/dist/components/uploads/index.scss +23 -0
- package/dist/components/uploads/src/index2.cjs +128 -138
- package/dist/components/uploads/src/index2.js +61 -71
- package/dist/components/uploads/src/util.cjs +80 -0
- package/dist/components/uploads/src/util.d.ts +10 -0
- package/dist/components/uploads/src/util.js +80 -0
- package/dist/components/uploads/src/views.cjs +4 -0
- package/dist/components/uploads/src/views.js +4 -0
- package/dist/components/uploads/src/views2.cjs +77 -0
- package/dist/components/uploads/src/views2.js +77 -0
- package/dist/components/user-select/src/index2.cjs +99 -99
- package/dist/components/videos/src/index2.cjs +97 -97
- package/dist/components/window/src/index2.cjs +61 -61
- package/dist/css/box-adjust.css +17 -0
- package/dist/css/forms.css +22 -0
- package/dist/css/index.css +39 -0
- package/dist/css/page.css +22 -0
- package/dist/css/uploads.css +22 -0
- package/dist/directives/scroll/index.cjs +6 -24
- package/dist/directives/scroll/index.js +1 -3
- package/dist/hooks/event-aliass/index.cjs +2 -2
- package/dist/hooks/full-screen/index.cjs +5 -5
- package/dist/hooks/global-config/index.cjs +8 -8
- package/dist/hooks/inherit/index.cjs +2 -2
- package/dist/hooks/locale/index.cjs +7 -7
- package/dist/icons/iconify.cjs +3 -3
- package/dist/icons/index.css +79 -79
- package/dist/icons/index.json +35 -35
- package/dist/icons/vue/bar.cjs +3 -3
- package/dist/icons/vue/below.cjs +3 -3
- package/dist/icons/vue/bicycle.cjs +3 -3
- package/dist/icons/vue/bottom-left.cjs +4 -4
- package/dist/icons/vue/bottom-right.cjs +4 -4
- package/dist/icons/vue/bottom.cjs +3 -3
- package/dist/icons/vue/catalogue.cjs +5 -5
- package/dist/icons/vue/clear.cjs +5 -5
- package/dist/icons/vue/close.cjs +3 -3
- package/dist/icons/vue/delete.cjs +3 -3
- package/dist/icons/vue/document.cjs +5 -5
- package/dist/icons/vue/down.cjs +3 -3
- package/dist/icons/vue/download.cjs +3 -3
- package/dist/icons/vue/edit.cjs +5 -5
- package/dist/icons/vue/enter.cjs +3 -3
- package/dist/icons/vue/frame.cjs +3 -3
- package/dist/icons/vue/left.cjs +3 -3
- package/dist/icons/vue/mute.cjs +3 -3
- package/dist/icons/vue/pause.cjs +4 -4
- package/dist/icons/vue/play.cjs +3 -3
- package/dist/icons/vue/plus.cjs +3 -3
- package/dist/icons/vue/retreat.cjs +3 -3
- package/dist/icons/vue/right.cjs +3 -3
- package/dist/icons/vue/sound.cjs +4 -4
- package/dist/icons/vue/star.cjs +4 -4
- package/dist/icons/vue/up.cjs +3 -3
- package/dist/icons/vue/views.cjs +5 -5
- package/dist/icons/vue/views.js +2 -2
- package/dist/index.css +39 -0
- package/dist/utils/vues/common.cjs +2 -2
- package/package.json +3 -3
- /package/dist/components/{alert → divider}/index.css +0 -0
- /package/dist/css/{alert.css → divider.css} +0 -0
|
@@ -12,6 +12,12 @@ $uploads: 'uploads';
|
|
|
12
12
|
display: flex;
|
|
13
13
|
align-items: center;
|
|
14
14
|
justify-content: center;
|
|
15
|
+
&.#{is('disabled')} {
|
|
16
|
+
box-shadow: 0 0 0 1px var(#{v(e() + 'disabled-border-color')}) inset;
|
|
17
|
+
background-color: var(#{v(e() + 'disabled-bg-color')});
|
|
18
|
+
color: var(#{v(e() + 'disabled-text-color')});
|
|
19
|
+
cursor: not-allowed;
|
|
20
|
+
}
|
|
15
21
|
}
|
|
16
22
|
&-list {
|
|
17
23
|
display: flex;
|
|
@@ -51,6 +57,23 @@ $uploads: 'uploads';
|
|
|
51
57
|
&-img {
|
|
52
58
|
height: 100%;
|
|
53
59
|
width: 100%;
|
|
60
|
+
&-error {
|
|
61
|
+
font-size: 14px;
|
|
62
|
+
background-color: var(#{v(e() + 'fill-color-light')});
|
|
63
|
+
color: var(#{v(e() + 'text-color-placeholder')});
|
|
64
|
+
max-height: 100%;
|
|
65
|
+
/* 换行设置 */
|
|
66
|
+
white-space: normal;
|
|
67
|
+
word-wrap: break-word;
|
|
68
|
+
overflow-wrap: break-word;
|
|
69
|
+
/* 多行省略 */
|
|
70
|
+
display: -webkit-box;
|
|
71
|
+
-webkit-box-orient: vertical;
|
|
72
|
+
-webkit-line-clamp: 4;
|
|
73
|
+
overflow: hidden;
|
|
74
|
+
|
|
75
|
+
line-height: 1.1;
|
|
76
|
+
}
|
|
54
77
|
}
|
|
55
78
|
&-document {
|
|
56
79
|
height: 100%;
|
|
@@ -1,46 +1,50 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const
|
|
3
|
+
const vue = require("vue");
|
|
4
4
|
const document = require("../../../icons/vue/document.cjs");
|
|
5
5
|
const download$1 = require("../../../icons/vue/download.cjs");
|
|
6
6
|
const plus = require("../../../icons/vue/plus.cjs");
|
|
7
7
|
const views = require("../../../icons/vue/views.cjs");
|
|
8
8
|
const _delete = require("../../../icons/vue/delete.cjs");
|
|
9
|
-
const index$
|
|
9
|
+
const index$6 = require("../../icon/index.cjs");
|
|
10
10
|
const index$8 = require("../../upload/index.cjs");
|
|
11
|
-
const index$
|
|
12
|
-
const index$
|
|
13
|
-
const index$7 = require("../../image-viewer/index.cjs");
|
|
11
|
+
const index$4 = require("../../message/index.cjs");
|
|
12
|
+
const index$7 = require("../../image/index.cjs");
|
|
14
13
|
const index$1 = require("../../../hooks/inherit/index.cjs");
|
|
15
14
|
const index$2 = require("../../../hooks/cssname/index.cjs");
|
|
16
|
-
const index$
|
|
15
|
+
const index$5 = require("../../../hooks/expose/index.cjs");
|
|
17
16
|
const data = require("./data.cjs");
|
|
18
17
|
const index = require("../../../hooks/locale/index.cjs");
|
|
19
18
|
const getUrlCatalogueObj = require("@fangzhongya/utils/urls/getUrlCatalogueObj");
|
|
20
19
|
const download = require("@fangzhongya/utils/window/download");
|
|
21
|
-
const util = require("../../players/common/util.cjs");
|
|
20
|
+
const util$1 = require("../../players/common/util.cjs");
|
|
21
|
+
const util = require("./util.cjs");
|
|
22
|
+
const index$3 = require("element-plus/es/components/form/index");
|
|
23
|
+
require("./views.cjs");
|
|
24
|
+
const views_vue_vue_type_script_setup_true_lang = require("./views2.cjs");
|
|
22
25
|
const _hoisted_1 = ["title"];
|
|
23
26
|
const _hoisted_2 = ["onClick", "title"];
|
|
24
27
|
const _hoisted_3 = ["onClick", "title"];
|
|
25
28
|
const _hoisted_4 = ["onClick", "title"];
|
|
26
|
-
const _sfc_main = /* @__PURE__ */
|
|
29
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
27
30
|
...{ inheritAttrs: false },
|
|
28
31
|
__name: "index",
|
|
29
32
|
props: data.dataProps,
|
|
30
33
|
emits: data.dataEmits,
|
|
31
34
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
32
35
|
const { getLocale } = index.useLocale();
|
|
33
|
-
const refEl =
|
|
34
|
-
const elRef =
|
|
35
|
-
const attrs = index$1.useInherit(
|
|
36
|
+
const refEl = vue.ref();
|
|
37
|
+
const elRef = vue.ref();
|
|
38
|
+
const attrs = index$1.useInherit(vue.useAttrs());
|
|
36
39
|
const cs = index$2.useCssName("uploads");
|
|
37
40
|
const props = __props;
|
|
38
41
|
const emit = __emit;
|
|
39
42
|
const listFuObj = data.dataHandle(props, emit);
|
|
40
43
|
const value = listFuObj.value;
|
|
41
44
|
const multiple = listFuObj.multiple;
|
|
42
|
-
const isloading =
|
|
43
|
-
const
|
|
45
|
+
const isloading = vue.ref(false);
|
|
46
|
+
const disabled = index$3.useDisabled();
|
|
47
|
+
const accept = vue.computed(() => {
|
|
44
48
|
if (props.accept) {
|
|
45
49
|
return props.accept;
|
|
46
50
|
} else {
|
|
@@ -59,64 +63,19 @@ const _sfc_main = /* @__PURE__ */ vues.defineComponent({
|
|
|
59
63
|
return "";
|
|
60
64
|
}
|
|
61
65
|
});
|
|
62
|
-
const
|
|
63
|
-
|
|
64
|
-
if (extension) {
|
|
65
|
-
const ks = Object.keys(data.types);
|
|
66
|
-
for (let index2 = 0; index2 < ks.length; index2++) {
|
|
67
|
-
const key = ks[index2];
|
|
68
|
-
if (data.types[key].includes(extension)) {
|
|
69
|
-
return key;
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
return "";
|
|
74
|
-
};
|
|
75
|
-
const getType = (accept2 = "") => {
|
|
76
|
-
if (accept2) {
|
|
77
|
-
if (accept2.includes("image/")) {
|
|
78
|
-
return "i";
|
|
79
|
-
} else if (accept2.includes("audio/")) {
|
|
80
|
-
return "a";
|
|
81
|
-
} else if (accept2.includes("video/")) {
|
|
82
|
-
return "v";
|
|
83
|
-
} else {
|
|
84
|
-
const extension = accept2.toLowerCase().split(",")[0];
|
|
85
|
-
return getExtension(extension);
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
return "";
|
|
89
|
-
};
|
|
90
|
-
const type = vues.computed(() => {
|
|
91
|
-
return props.type ?? getType(accept.value);
|
|
66
|
+
const type = vue.computed(() => {
|
|
67
|
+
return props.type ?? util.getType(accept.value);
|
|
92
68
|
});
|
|
93
|
-
const getListType = (obj) => {
|
|
94
|
-
if (props.type) {
|
|
95
|
-
return props.type;
|
|
96
|
-
}
|
|
97
|
-
if (obj) {
|
|
98
|
-
if (obj.type) {
|
|
99
|
-
return obj.type;
|
|
100
|
-
} else {
|
|
101
|
-
let v = getUrlCatalogueObj.getUrlCatalogueObj(obj.url);
|
|
102
|
-
if (v.suffix) {
|
|
103
|
-
return getExtension("." + v.suffix);
|
|
104
|
-
}
|
|
105
|
-
return getType(accept.value);
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
return "";
|
|
109
|
-
};
|
|
110
69
|
const getFileList = (arr) => {
|
|
111
70
|
if (props.formatter) {
|
|
112
71
|
return arr.map((v) => {
|
|
113
72
|
return props.formatter(v);
|
|
114
73
|
});
|
|
115
74
|
} else {
|
|
116
|
-
return util.getListValue(arr);
|
|
75
|
+
return util$1.getListValue(arr);
|
|
117
76
|
}
|
|
118
77
|
};
|
|
119
|
-
const fileList =
|
|
78
|
+
const fileList = vue.computed(() => {
|
|
120
79
|
if (value.value instanceof Array) {
|
|
121
80
|
return getFileList(value.value);
|
|
122
81
|
} else {
|
|
@@ -126,12 +85,16 @@ const _sfc_main = /* @__PURE__ */ vues.defineComponent({
|
|
|
126
85
|
return [];
|
|
127
86
|
}
|
|
128
87
|
});
|
|
129
|
-
const isUp =
|
|
130
|
-
if (
|
|
131
|
-
|
|
88
|
+
const isUp = vue.computed(() => {
|
|
89
|
+
if (disabled.value) {
|
|
90
|
+
if (value.value && value.value.length > 0) {
|
|
91
|
+
return false;
|
|
92
|
+
} else {
|
|
93
|
+
return true;
|
|
94
|
+
}
|
|
132
95
|
}
|
|
133
96
|
if (multiple.value) {
|
|
134
|
-
if (!value.value) {
|
|
97
|
+
if (!value.value || value.value.length == 0) {
|
|
135
98
|
return true;
|
|
136
99
|
}
|
|
137
100
|
if (props.limit) {
|
|
@@ -151,7 +114,7 @@ const _sfc_main = /* @__PURE__ */ vues.defineComponent({
|
|
|
151
114
|
}
|
|
152
115
|
}
|
|
153
116
|
});
|
|
154
|
-
const views$1 =
|
|
117
|
+
const views$1 = vue.reactive({
|
|
155
118
|
show: false,
|
|
156
119
|
value: void 0
|
|
157
120
|
});
|
|
@@ -160,7 +123,7 @@ const _sfc_main = /* @__PURE__ */ vues.defineComponent({
|
|
|
160
123
|
if (typeof props.isViews === "boolean") {
|
|
161
124
|
return true;
|
|
162
125
|
} else {
|
|
163
|
-
const type2 = getListType(item);
|
|
126
|
+
const type2 = util.getListType(item, props.type, accept.value);
|
|
164
127
|
if (props.isViews.includes(type2)) {
|
|
165
128
|
return true;
|
|
166
129
|
}
|
|
@@ -207,7 +170,7 @@ const _sfc_main = /* @__PURE__ */ vues.defineComponent({
|
|
|
207
170
|
if (props.errorPrompt) {
|
|
208
171
|
props.errorPrompt(ts, num);
|
|
209
172
|
} else {
|
|
210
|
-
index$
|
|
173
|
+
index$4.Message.error(ts);
|
|
211
174
|
}
|
|
212
175
|
};
|
|
213
176
|
const onBeforeUpload = (file) => {
|
|
@@ -273,7 +236,7 @@ const _sfc_main = /* @__PURE__ */ vues.defineComponent({
|
|
|
273
236
|
emit("httpRequest", obj, callback);
|
|
274
237
|
};
|
|
275
238
|
__expose(
|
|
276
|
-
index$
|
|
239
|
+
index$5.useExpose(
|
|
277
240
|
{
|
|
278
241
|
el: refEl
|
|
279
242
|
},
|
|
@@ -281,135 +244,162 @@ const _sfc_main = /* @__PURE__ */ vues.defineComponent({
|
|
|
281
244
|
)
|
|
282
245
|
);
|
|
283
246
|
return (_ctx, _cache) => {
|
|
284
|
-
return
|
|
247
|
+
return vue.openBlock(), vue.createElementBlock("div", vue.mergeProps({
|
|
285
248
|
ref_key: "refEl",
|
|
286
249
|
ref: refEl
|
|
287
|
-
},
|
|
288
|
-
class:
|
|
250
|
+
}, vue.unref(attrs).root, {
|
|
251
|
+
class: vue.unref(cs).z()
|
|
289
252
|
}), [
|
|
290
|
-
|
|
291
|
-
class:
|
|
253
|
+
vue.createElementVNode("div", {
|
|
254
|
+
class: vue.normalizeClass(vue.unref(cs).z("list"))
|
|
292
255
|
}, [
|
|
293
|
-
(
|
|
294
|
-
return
|
|
295
|
-
class:
|
|
256
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(fileList.value, (item, index2) => {
|
|
257
|
+
return vue.openBlock(), vue.createElementBlock("div", {
|
|
258
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li")),
|
|
296
259
|
key: index2
|
|
297
260
|
}, [
|
|
298
|
-
|
|
261
|
+
vue.renderSlot(_ctx.$slots, vue.unref(data.dataSlot).default, {
|
|
262
|
+
value: item,
|
|
263
|
+
type: props.type,
|
|
264
|
+
accept: accept.value,
|
|
265
|
+
disabled: vue.unref(disabled)
|
|
266
|
+
}, () => {
|
|
299
267
|
var _a;
|
|
300
268
|
return [
|
|
301
|
-
|
|
302
|
-
class:
|
|
269
|
+
vue.createElementVNode("div", {
|
|
270
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li-operation")),
|
|
303
271
|
title: item.url
|
|
304
272
|
}, [
|
|
305
|
-
props.isDownload ? (
|
|
273
|
+
props.isDownload ? (vue.openBlock(), vue.createElementBlock("span", {
|
|
306
274
|
key: 0,
|
|
307
275
|
onClick: ($event) => onDownload(item, index2),
|
|
308
|
-
title:
|
|
276
|
+
title: vue.unref(getLocale)("upload.download")
|
|
309
277
|
}, [
|
|
310
|
-
|
|
311
|
-
default:
|
|
312
|
-
|
|
278
|
+
vue.createVNode(vue.unref(index$6.Icon), null, {
|
|
279
|
+
default: vue.withCtx(() => [
|
|
280
|
+
vue.createVNode(download$1.default)
|
|
313
281
|
]),
|
|
314
282
|
_: 1
|
|
315
283
|
})
|
|
316
|
-
], 8, _hoisted_2)) :
|
|
317
|
-
|
|
284
|
+
], 8, _hoisted_2)) : vue.createCommentVNode("", true),
|
|
285
|
+
props.isViews ? (vue.openBlock(), vue.createElementBlock("span", {
|
|
318
286
|
key: 1,
|
|
319
287
|
onClick: ($event) => onViews(item, index2),
|
|
320
|
-
title:
|
|
288
|
+
title: vue.unref(getLocale)("upload.views")
|
|
321
289
|
}, [
|
|
322
|
-
|
|
323
|
-
default:
|
|
324
|
-
|
|
290
|
+
vue.createVNode(vue.unref(index$6.Icon), null, {
|
|
291
|
+
default: vue.withCtx(() => [
|
|
292
|
+
vue.createVNode(views.default)
|
|
325
293
|
]),
|
|
326
294
|
_: 1
|
|
327
295
|
})
|
|
328
|
-
], 8, _hoisted_3)) :
|
|
329
|
-
!(
|
|
296
|
+
], 8, _hoisted_3)) : vue.createCommentVNode("", true),
|
|
297
|
+
!(vue.unref(disabled) || item.disabled) ? (vue.openBlock(), vue.createElementBlock("span", {
|
|
330
298
|
key: 2,
|
|
331
|
-
class:
|
|
299
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li-operation-delete")),
|
|
332
300
|
onClick: ($event) => onDelete(item, index2),
|
|
333
|
-
title:
|
|
301
|
+
title: vue.unref(getLocale)("upload.delete")
|
|
334
302
|
}, [
|
|
335
|
-
|
|
336
|
-
default:
|
|
337
|
-
|
|
303
|
+
vue.createVNode(vue.unref(index$6.Icon), null, {
|
|
304
|
+
default: vue.withCtx(() => [
|
|
305
|
+
vue.createVNode(_delete.default)
|
|
338
306
|
]),
|
|
339
307
|
_: 1
|
|
340
308
|
})
|
|
341
|
-
], 10, _hoisted_4)) :
|
|
309
|
+
], 10, _hoisted_4)) : vue.createCommentVNode("", true)
|
|
342
310
|
], 10, _hoisted_1),
|
|
343
|
-
|
|
344
|
-
class:
|
|
311
|
+
vue.createElementVNode("div", {
|
|
312
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li-value"))
|
|
345
313
|
}, [
|
|
346
|
-
|
|
314
|
+
vue.unref(util.getListType)(
|
|
315
|
+
item,
|
|
316
|
+
props.type,
|
|
317
|
+
accept.value
|
|
318
|
+
).startsWith("i") ? (vue.openBlock(), vue.createBlock(vue.unref(index$7.Image), {
|
|
347
319
|
key: 0,
|
|
348
|
-
class:
|
|
320
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li-value-img")),
|
|
349
321
|
fit: "cover",
|
|
350
322
|
src: item.url
|
|
351
|
-
},
|
|
323
|
+
}, {
|
|
324
|
+
error: vue.withCtx(() => {
|
|
325
|
+
var _a2;
|
|
326
|
+
return [
|
|
327
|
+
vue.createElementVNode("div", {
|
|
328
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li-value-img-error"))
|
|
329
|
+
}, vue.toDisplayString(((_a2 = vue.unref(getUrlCatalogueObj.getUrlCatalogueObj)(item.url)) == null ? void 0 : _a2.name) || item.url), 3)
|
|
330
|
+
];
|
|
331
|
+
}),
|
|
332
|
+
_: 2
|
|
333
|
+
}, 1032, ["class", "src"])) : (vue.openBlock(), vue.createElementBlock("div", {
|
|
352
334
|
key: 1,
|
|
353
|
-
class:
|
|
335
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li-value-document"))
|
|
354
336
|
}, [
|
|
355
|
-
|
|
356
|
-
class:
|
|
337
|
+
vue.createElementVNode("span", {
|
|
338
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li-value-document-bg"))
|
|
357
339
|
}, [
|
|
358
|
-
|
|
340
|
+
vue.createVNode(document.default)
|
|
359
341
|
], 2),
|
|
360
|
-
|
|
361
|
-
class:
|
|
362
|
-
},
|
|
342
|
+
vue.createElementVNode("span", {
|
|
343
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-li-value-document-text"))
|
|
344
|
+
}, vue.toDisplayString(((_a = vue.unref(getUrlCatalogueObj.getUrlCatalogueObj)(item.url)) == null ? void 0 : _a.name) || item.url), 3)
|
|
363
345
|
], 2))
|
|
364
346
|
], 2)
|
|
365
347
|
];
|
|
366
348
|
})
|
|
367
349
|
], 2);
|
|
368
350
|
}), 128)),
|
|
369
|
-
|
|
351
|
+
props.isViews ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
370
352
|
key: 0,
|
|
371
|
-
class:
|
|
353
|
+
class: vue.normalizeClass(vue.unref(cs).z("list-views"))
|
|
372
354
|
}, [
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
355
|
+
vue.renderSlot(_ctx.$slots, vue.unref(data.dataSlot).views, {
|
|
356
|
+
type: props.type,
|
|
357
|
+
accept: accept.value,
|
|
358
|
+
value: views$1.value,
|
|
359
|
+
show: views$1.show,
|
|
360
|
+
onClose: _cache[0] || (_cache[0] = ($event) => views$1.show = false)
|
|
361
|
+
}, () => [
|
|
362
|
+
vue.createVNode(views_vue_vue_type_script_setup_true_lang.default, {
|
|
363
|
+
name: vue.unref(data.dataSlot).views,
|
|
364
|
+
type: props.type,
|
|
365
|
+
accept: accept.value,
|
|
366
|
+
value: views$1.value,
|
|
367
|
+
show: views$1.show,
|
|
368
|
+
onClose: _cache[1] || (_cache[1] = ($event) => views$1.show = false)
|
|
369
|
+
}, null, 8, ["name", "type", "accept", "value", "show"])
|
|
370
|
+
])
|
|
371
|
+
], 2)) : vue.createCommentVNode("", true)
|
|
385
372
|
], 2),
|
|
386
|
-
isUp.value ? (
|
|
373
|
+
isUp.value ? (vue.openBlock(), vue.createBlock(vue.unref(index$8.Upload), vue.mergeProps({ key: 0 }, vue.unref(attrs).assem, {
|
|
387
374
|
ref_key: "elRef",
|
|
388
375
|
ref: elRef,
|
|
389
|
-
disabled: isloading.value,
|
|
390
|
-
class:
|
|
376
|
+
disabled: vue.unref(disabled) || isloading.value,
|
|
377
|
+
class: vue.unref(cs).z("upload"),
|
|
391
378
|
action: "#",
|
|
392
|
-
multiple:
|
|
379
|
+
multiple: vue.unref(multiple),
|
|
393
380
|
"show-file-list": false,
|
|
394
381
|
accept: accept.value,
|
|
395
|
-
limit:
|
|
382
|
+
limit: vue.unref(multiple) ? props.limit : 1,
|
|
396
383
|
"before-upload": onBeforeUpload,
|
|
397
384
|
"http-request": httpRequest
|
|
398
385
|
}), {
|
|
399
|
-
trigger:
|
|
400
|
-
|
|
401
|
-
class:
|
|
386
|
+
trigger: vue.withCtx(() => [
|
|
387
|
+
vue.createElementVNode("div", {
|
|
388
|
+
class: vue.normalizeClass([
|
|
389
|
+
vue.unref(cs).z("upload-trigger"),
|
|
390
|
+
vue.unref(cs).is("disabled", vue.unref(disabled))
|
|
391
|
+
])
|
|
402
392
|
}, [
|
|
403
|
-
|
|
404
|
-
default:
|
|
405
|
-
!isloading.value ? (
|
|
393
|
+
vue.createVNode(vue.unref(index$6.Icon), null, {
|
|
394
|
+
default: vue.withCtx(() => [
|
|
395
|
+
!isloading.value ? (vue.openBlock(), vue.createBlock(plus.default, { key: 0 })) : vue.createCommentVNode("", true)
|
|
406
396
|
]),
|
|
407
397
|
_: 1
|
|
408
398
|
})
|
|
409
399
|
], 2)
|
|
410
400
|
]),
|
|
411
401
|
_: 1
|
|
412
|
-
}, 16, ["disabled", "class", "multiple", "accept", "limit"])) :
|
|
402
|
+
}, 16, ["disabled", "class", "multiple", "accept", "limit"])) : vue.createCommentVNode("", true)
|
|
413
403
|
], 16);
|
|
414
404
|
};
|
|
415
405
|
}
|