bm-admin-ui 1.0.27-alpha → 1.0.29-alpha
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/es/components/upload/index.d.ts +1 -0
- package/es/components/upload/index.js +8 -3
- package/es/components/upload/src/upload.vue.d.ts +1 -0
- package/index.esm.js +8 -3
- package/index.js +8 -3
- package/lib/components/upload/index.d.ts +1 -0
- package/lib/components/upload/index.js +8 -3
- package/lib/components/upload/src/upload.vue.d.ts +1 -0
- package/package.json +1 -1
- package/theme-chalk/float-table.css +1 -1
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/upload.css +1 -1
- package/types/components/upload/index.d.ts +1 -0
- package/types/components/upload/src/upload.vue.d.ts +1 -0
|
@@ -87,6 +87,7 @@ declare const BmUpload: import("bm-admin-ui/es/utils/with-install").SFCWithInsta
|
|
|
87
87
|
handleClosePictureView(): void;
|
|
88
88
|
reUpload(e: any, uid: any): void;
|
|
89
89
|
paste(event: ClipboardEvent): void;
|
|
90
|
+
handleReject(e: any): void;
|
|
90
91
|
icons: {
|
|
91
92
|
pdf: string;
|
|
92
93
|
ppt: string;
|
|
@@ -1585,6 +1585,9 @@ const _sfc_main = {
|
|
|
1585
1585
|
data: state.uploadConfigs.data
|
|
1586
1586
|
});
|
|
1587
1587
|
}
|
|
1588
|
+
},
|
|
1589
|
+
handleReject(e) {
|
|
1590
|
+
return methods.uploadError(new Error(props.customErrors?.format || `\u4E0D\u80FD\u4E0A\u4F20\u8BE5\u7C7B\u578B\u6587\u4EF6`));
|
|
1588
1591
|
}
|
|
1589
1592
|
};
|
|
1590
1593
|
watch(() => props.defaultList, function(list) {
|
|
@@ -1738,7 +1741,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1738
1741
|
const _component_a_modal = resolveComponent("a-modal");
|
|
1739
1742
|
return openBlock(), createElementBlock("div", {
|
|
1740
1743
|
class: normalizeClass(["bm-upload", {
|
|
1741
|
-
"bm-upload--text": _ctx.uploadConfigs.listType === "text"
|
|
1744
|
+
"bm-upload--text": _ctx.uploadConfigs.listType === "text",
|
|
1745
|
+
"bm-upload--picture-card--has-tips": !($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) && !_ctx.extraConfigs.myBtn && _ctx.uploadConfigs.listType === "picture-card" && _ctx.extraConfigs.tips && _ctx.extraConfigs.showTips
|
|
1742
1746
|
}])
|
|
1743
1747
|
}, [
|
|
1744
1748
|
_ctx.uploadConfigs.listType === "picture-card" ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.fileList, (item) => {
|
|
@@ -1870,7 +1874,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1870
1874
|
], 2);
|
|
1871
1875
|
}), 128)) : createCommentVNode("v-if", true),
|
|
1872
1876
|
!($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) ? (openBlock(), createBlock(_component_a_upload, mergeProps({ key: 1 }, _ctx.uploadConfigs, {
|
|
1873
|
-
class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn }
|
|
1877
|
+
class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn },
|
|
1878
|
+
onReject: _ctx.handleReject
|
|
1874
1879
|
}), {
|
|
1875
1880
|
default: withCtx(() => [
|
|
1876
1881
|
_ctx.extraConfigs.myBtn ? renderSlot(_ctx.$slots, "myBtn", { key: 0 }) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
@@ -1894,7 +1899,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1894
1899
|
], 2112))
|
|
1895
1900
|
]),
|
|
1896
1901
|
_: 3
|
|
1897
|
-
}, 16, ["class"])) : createCommentVNode("v-if", true),
|
|
1902
|
+
}, 16, ["class", "onReject"])) : createCommentVNode("v-if", true),
|
|
1898
1903
|
_ctx.uploadConfigs.listType === "text" && !_ctx.uploadConfigs.showSlotList ? (openBlock(), createElementBlock("div", _hoisted_24, [
|
|
1899
1904
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.fileList, (item) => {
|
|
1900
1905
|
return openBlock(), createElementBlock("div", {
|
package/index.esm.js
CHANGED
|
@@ -46321,6 +46321,9 @@ const _sfc_main$3 = {
|
|
|
46321
46321
|
data: state.uploadConfigs.data
|
|
46322
46322
|
});
|
|
46323
46323
|
}
|
|
46324
|
+
},
|
|
46325
|
+
handleReject(e) {
|
|
46326
|
+
return methods.uploadError(new Error(props.customErrors?.format || `\u4E0D\u80FD\u4E0A\u4F20\u8BE5\u7C7B\u578B\u6587\u4EF6`));
|
|
46324
46327
|
}
|
|
46325
46328
|
};
|
|
46326
46329
|
watch(() => props.defaultList, function(list) {
|
|
@@ -46474,7 +46477,8 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
46474
46477
|
const _component_a_modal = resolveComponent("a-modal");
|
|
46475
46478
|
return openBlock(), createElementBlock("div", {
|
|
46476
46479
|
class: normalizeClass(["bm-upload", {
|
|
46477
|
-
"bm-upload--text": _ctx.uploadConfigs.listType === "text"
|
|
46480
|
+
"bm-upload--text": _ctx.uploadConfigs.listType === "text",
|
|
46481
|
+
"bm-upload--picture-card--has-tips": !($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) && !_ctx.extraConfigs.myBtn && _ctx.uploadConfigs.listType === "picture-card" && _ctx.extraConfigs.tips && _ctx.extraConfigs.showTips
|
|
46478
46482
|
}])
|
|
46479
46483
|
}, [
|
|
46480
46484
|
_ctx.uploadConfigs.listType === "picture-card" ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.fileList, (item) => {
|
|
@@ -46606,7 +46610,8 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
46606
46610
|
], 2);
|
|
46607
46611
|
}), 128)) : createCommentVNode("v-if", true),
|
|
46608
46612
|
!($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) ? (openBlock(), createBlock(_component_a_upload, mergeProps$1({ key: 1 }, _ctx.uploadConfigs, {
|
|
46609
|
-
class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn }
|
|
46613
|
+
class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn },
|
|
46614
|
+
onReject: _ctx.handleReject
|
|
46610
46615
|
}), {
|
|
46611
46616
|
default: withCtx(() => [
|
|
46612
46617
|
_ctx.extraConfigs.myBtn ? renderSlot(_ctx.$slots, "myBtn", { key: 0 }) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
@@ -46630,7 +46635,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
46630
46635
|
], 2112))
|
|
46631
46636
|
]),
|
|
46632
46637
|
_: 3
|
|
46633
|
-
}, 16, ["class"])) : createCommentVNode("v-if", true),
|
|
46638
|
+
}, 16, ["class", "onReject"])) : createCommentVNode("v-if", true),
|
|
46634
46639
|
_ctx.uploadConfigs.listType === "text" && !_ctx.uploadConfigs.showSlotList ? (openBlock(), createElementBlock("div", _hoisted_24, [
|
|
46635
46640
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.fileList, (item) => {
|
|
46636
46641
|
return openBlock(), createElementBlock("div", {
|
package/index.js
CHANGED
|
@@ -46329,6 +46329,9 @@ var process = {
|
|
|
46329
46329
|
data: state.uploadConfigs.data
|
|
46330
46330
|
});
|
|
46331
46331
|
}
|
|
46332
|
+
},
|
|
46333
|
+
handleReject(e) {
|
|
46334
|
+
return methods.uploadError(new Error(props.customErrors?.format || `\u4E0D\u80FD\u4E0A\u4F20\u8BE5\u7C7B\u578B\u6587\u4EF6`));
|
|
46332
46335
|
}
|
|
46333
46336
|
};
|
|
46334
46337
|
require$$1$1.watch(() => props.defaultList, function(list) {
|
|
@@ -46482,7 +46485,8 @@ var process = {
|
|
|
46482
46485
|
const _component_a_modal = require$$1$1.resolveComponent("a-modal");
|
|
46483
46486
|
return require$$1$1.openBlock(), require$$1$1.createElementBlock("div", {
|
|
46484
46487
|
class: require$$1$1.normalizeClass(["bm-upload", {
|
|
46485
|
-
"bm-upload--text": _ctx.uploadConfigs.listType === "text"
|
|
46488
|
+
"bm-upload--text": _ctx.uploadConfigs.listType === "text",
|
|
46489
|
+
"bm-upload--picture-card--has-tips": !($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) && !_ctx.extraConfigs.myBtn && _ctx.uploadConfigs.listType === "picture-card" && _ctx.extraConfigs.tips && _ctx.extraConfigs.showTips
|
|
46486
46490
|
}])
|
|
46487
46491
|
}, [
|
|
46488
46492
|
_ctx.uploadConfigs.listType === "picture-card" ? (require$$1$1.openBlock(true), require$$1$1.createElementBlock(require$$1$1.Fragment, { key: 0 }, require$$1$1.renderList(_ctx.fileList, (item) => {
|
|
@@ -46614,7 +46618,8 @@ var process = {
|
|
|
46614
46618
|
], 2);
|
|
46615
46619
|
}), 128)) : require$$1$1.createCommentVNode("v-if", true),
|
|
46616
46620
|
!($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) ? (require$$1$1.openBlock(), require$$1$1.createBlock(_component_a_upload, require$$1$1.mergeProps({ key: 1 }, _ctx.uploadConfigs, {
|
|
46617
|
-
class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn }
|
|
46621
|
+
class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn },
|
|
46622
|
+
onReject: _ctx.handleReject
|
|
46618
46623
|
}), {
|
|
46619
46624
|
default: require$$1$1.withCtx(() => [
|
|
46620
46625
|
_ctx.extraConfigs.myBtn ? require$$1$1.renderSlot(_ctx.$slots, "myBtn", { key: 0 }) : (require$$1$1.openBlock(), require$$1$1.createElementBlock(require$$1$1.Fragment, { key: 1 }, [
|
|
@@ -46638,7 +46643,7 @@ var process = {
|
|
|
46638
46643
|
], 2112))
|
|
46639
46644
|
]),
|
|
46640
46645
|
_: 3
|
|
46641
|
-
}, 16, ["class"])) : require$$1$1.createCommentVNode("v-if", true),
|
|
46646
|
+
}, 16, ["class", "onReject"])) : require$$1$1.createCommentVNode("v-if", true),
|
|
46642
46647
|
_ctx.uploadConfigs.listType === "text" && !_ctx.uploadConfigs.showSlotList ? (require$$1$1.openBlock(), require$$1$1.createElementBlock("div", _hoisted_24, [
|
|
46643
46648
|
(require$$1$1.openBlock(true), require$$1$1.createElementBlock(require$$1$1.Fragment, null, require$$1$1.renderList(_ctx.fileList, (item) => {
|
|
46644
46649
|
return require$$1$1.openBlock(), require$$1$1.createElementBlock("div", {
|
|
@@ -87,6 +87,7 @@ declare const BmUpload: import("bm-admin-ui/es/utils/with-install").SFCWithInsta
|
|
|
87
87
|
handleClosePictureView(): void;
|
|
88
88
|
reUpload(e: any, uid: any): void;
|
|
89
89
|
paste(event: ClipboardEvent): void;
|
|
90
|
+
handleReject(e: any): void;
|
|
90
91
|
icons: {
|
|
91
92
|
pdf: string;
|
|
92
93
|
ppt: string;
|
|
@@ -1589,6 +1589,9 @@ const _sfc_main = {
|
|
|
1589
1589
|
data: state.uploadConfigs.data
|
|
1590
1590
|
});
|
|
1591
1591
|
}
|
|
1592
|
+
},
|
|
1593
|
+
handleReject(e) {
|
|
1594
|
+
return methods.uploadError(new Error(props.customErrors?.format || `\u4E0D\u80FD\u4E0A\u4F20\u8BE5\u7C7B\u578B\u6587\u4EF6`));
|
|
1592
1595
|
}
|
|
1593
1596
|
};
|
|
1594
1597
|
vue.watch(() => props.defaultList, function(list) {
|
|
@@ -1742,7 +1745,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1742
1745
|
const _component_a_modal = vue.resolveComponent("a-modal");
|
|
1743
1746
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
1744
1747
|
class: vue.normalizeClass(["bm-upload", {
|
|
1745
|
-
"bm-upload--text": _ctx.uploadConfigs.listType === "text"
|
|
1748
|
+
"bm-upload--text": _ctx.uploadConfigs.listType === "text",
|
|
1749
|
+
"bm-upload--picture-card--has-tips": !($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) && !_ctx.extraConfigs.myBtn && _ctx.uploadConfigs.listType === "picture-card" && _ctx.extraConfigs.tips && _ctx.extraConfigs.showTips
|
|
1746
1750
|
}])
|
|
1747
1751
|
}, [
|
|
1748
1752
|
_ctx.uploadConfigs.listType === "picture-card" ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 0 }, vue.renderList(_ctx.fileList, (item) => {
|
|
@@ -1874,7 +1878,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1874
1878
|
], 2);
|
|
1875
1879
|
}), 128)) : vue.createCommentVNode("v-if", true),
|
|
1876
1880
|
!($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) ? (vue.openBlock(), vue.createBlock(_component_a_upload, vue.mergeProps({ key: 1 }, _ctx.uploadConfigs, {
|
|
1877
|
-
class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn }
|
|
1881
|
+
class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn },
|
|
1882
|
+
onReject: _ctx.handleReject
|
|
1878
1883
|
}), {
|
|
1879
1884
|
default: vue.withCtx(() => [
|
|
1880
1885
|
_ctx.extraConfigs.myBtn ? vue.renderSlot(_ctx.$slots, "myBtn", { key: 0 }) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
@@ -1898,7 +1903,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1898
1903
|
], 2112))
|
|
1899
1904
|
]),
|
|
1900
1905
|
_: 3
|
|
1901
|
-
}, 16, ["class"])) : vue.createCommentVNode("v-if", true),
|
|
1906
|
+
}, 16, ["class", "onReject"])) : vue.createCommentVNode("v-if", true),
|
|
1902
1907
|
_ctx.uploadConfigs.listType === "text" && !_ctx.uploadConfigs.showSlotList ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_24, [
|
|
1903
1908
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.fileList, (item) => {
|
|
1904
1909
|
return vue.openBlock(), vue.createElementBlock("div", {
|