bm-admin-ui 1.0.31-alpha → 1.0.32-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.
@@ -1396,7 +1396,7 @@ const _sfc_main = {
1396
1396
  fileList: {},
1397
1397
  onepViewImageHover: {},
1398
1398
  previewVisible: false,
1399
- onepViewImage: "",
1399
+ onepViewImage: {},
1400
1400
  extraConfigs: {
1401
1401
  maxSize: 5,
1402
1402
  maxCount: 5,
@@ -1446,7 +1446,22 @@ const _sfc_main = {
1446
1446
  }, 1e3);
1447
1447
  methods.customUploadRequest(file);
1448
1448
  }
1449
- }
1449
+ },
1450
+ pictureFileTypes: [
1451
+ "img",
1452
+ "image",
1453
+ "png",
1454
+ "PNG",
1455
+ "image/png",
1456
+ "jpg",
1457
+ "JPG",
1458
+ "jpeg",
1459
+ "JPEG",
1460
+ "image/jpeg",
1461
+ "gif",
1462
+ "GIF",
1463
+ "image/gif"
1464
+ ]
1450
1465
  });
1451
1466
  const methods = {
1452
1467
  updateUploadProgress(file, progress) {
@@ -1527,24 +1542,9 @@ const _sfc_main = {
1527
1542
  state.onepViewImageHover[uid] = false;
1528
1543
  },
1529
1544
  viewOnePicture(item) {
1530
- if ([
1531
- "img",
1532
- "image",
1533
- "png",
1534
- "PNG",
1535
- "image/png",
1536
- "jpg",
1537
- "JPG",
1538
- "jpeg",
1539
- "JPEG",
1540
- "image/jpeg",
1541
- "gif",
1542
- "GIF",
1543
- "image/gif"
1544
- ].includes(item.type.toLowerCase())) {
1545
+ if (state.pictureFileTypes.includes(item.type.toLowerCase())) {
1545
1546
  state.previewVisible = true;
1546
1547
  state.onepViewImage = item;
1547
- return;
1548
1548
  }
1549
1549
  emit("previewFile", item);
1550
1550
  },
@@ -1688,57 +1688,53 @@ const _hoisted_5 = ["src"];
1688
1688
  const _hoisted_6 = ["src"];
1689
1689
  const _hoisted_7 = ["src"];
1690
1690
  const _hoisted_8 = ["src"];
1691
- const _hoisted_9 = ["src"];
1692
- const _hoisted_10 = {
1693
- key: 6,
1694
- class: "bm-upload__picture-result__cover"
1695
- };
1696
- const _hoisted_11 = ["onClick"];
1697
- const _hoisted_12 = ["onClick"];
1698
- const _hoisted_13 = ["onMouseenter", "onMouseleave"];
1699
- const _hoisted_14 = /* @__PURE__ */ vue.createElementVNode("div", { class: "bm-upload__picture-error__image" }, null, -1);
1700
- const _hoisted_15 = /* @__PURE__ */ vue.createElementVNode("div", null, "\u4E0A\u4F20\u9519\u8BEF", -1);
1701
- const _hoisted_16 = {
1691
+ const _hoisted_9 = ["onClick"];
1692
+ const _hoisted_10 = ["onClick"];
1693
+ const _hoisted_11 = ["onMouseenter", "onMouseleave"];
1694
+ const _hoisted_12 = /* @__PURE__ */ vue.createElementVNode("div", { class: "bm-upload__picture-error__image" }, null, -1);
1695
+ const _hoisted_13 = /* @__PURE__ */ vue.createElementVNode("div", null, "\u4E0A\u4F20\u9519\u8BEF", -1);
1696
+ const _hoisted_14 = {
1702
1697
  key: 0,
1703
1698
  class: "bm-upload__picture-result__cover"
1704
1699
  };
1705
- const _hoisted_17 = ["onClick"];
1706
- const _hoisted_18 = ["onClick"];
1707
- const _hoisted_19 = {
1700
+ const _hoisted_15 = ["onClick"];
1701
+ const _hoisted_16 = ["onClick"];
1702
+ const _hoisted_17 = {
1708
1703
  key: 0,
1709
1704
  style: { "font-size": "24px", "color": "#9393a3" }
1710
1705
  };
1711
- const _hoisted_20 = { class: "ant-upload-text bm-upload__text" };
1712
- const _hoisted_21 = {
1706
+ const _hoisted_18 = { class: "ant-upload-text bm-upload__text" };
1707
+ const _hoisted_19 = {
1713
1708
  key: 0,
1714
1709
  class: "bm-upload__tips"
1715
1710
  };
1716
- const _hoisted_22 = { key: 1 };
1717
- const _hoisted_23 = {
1711
+ const _hoisted_20 = { key: 1 };
1712
+ const _hoisted_21 = {
1718
1713
  key: 0,
1719
1714
  class: "bm-upload__tips"
1720
1715
  };
1721
- const _hoisted_24 = {
1716
+ const _hoisted_22 = {
1722
1717
  key: 2,
1723
1718
  class: "bm-upload__file-list"
1724
1719
  };
1725
- const _hoisted_25 = { class: "bm-upload__file__detail" };
1726
- const _hoisted_26 = /* @__PURE__ */ vue.createElementVNode("div", { class: "bm-upload__file__icon" }, [
1720
+ const _hoisted_23 = { class: "bm-upload__file__detail" };
1721
+ const _hoisted_24 = /* @__PURE__ */ vue.createElementVNode("div", { class: "bm-upload__file__icon" }, [
1727
1722
  /* @__PURE__ */ vue.createElementVNode("div", { class: "bm-upload__attachment" })
1728
1723
  ], -1);
1729
- const _hoisted_27 = { class: "bm-upload__file__name" };
1730
- const _hoisted_28 = { class: "bm-upload__file__progress-tools" };
1731
- const _hoisted_29 = ["onClick"];
1732
- const _hoisted_30 = ["onClick"];
1733
- const _hoisted_31 = {
1724
+ const _hoisted_25 = { class: "bm-upload__file__name" };
1725
+ const _hoisted_26 = { class: "bm-upload__file__progress-tools" };
1726
+ const _hoisted_27 = ["onClick"];
1727
+ const _hoisted_28 = ["onClick"];
1728
+ const _hoisted_29 = {
1734
1729
  key: 0,
1735
1730
  class: "bm-upload__progress"
1736
1731
  };
1737
- const _hoisted_32 = { style: { "padding-top": "20px" } };
1738
- const _hoisted_33 = ["src"];
1739
- const _hoisted_34 = ["title", "src"];
1732
+ const _hoisted_30 = { style: { "padding-top": "20px" } };
1733
+ const _hoisted_31 = ["src"];
1734
+ const _hoisted_32 = ["title", "src"];
1740
1735
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
1741
1736
  const _component_a_progress = vue.resolveComponent("a-progress");
1737
+ const _component_a_image = vue.resolveComponent("a-image");
1742
1738
  const _component_PlusOutlined = vue.resolveComponent("PlusOutlined");
1743
1739
  const _component_UploadOutlined = vue.resolveComponent("UploadOutlined");
1744
1740
  const _component_a_button = vue.resolveComponent("a-button");
@@ -1751,145 +1747,141 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
1751
1747
  "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
1752
1748
  }])
1753
1749
  }, [
1754
- _ctx.uploadConfigs.listType === "picture-card" ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 0 }, vue.renderList(_ctx.fileList, (item) => {
1755
- return vue.openBlock(), vue.createElementBlock("div", {
1756
- key: item,
1757
- class: vue.normalizeClass(["bm-upload__picture", { "bm-upload__picture--error": item.status === "error" }])
1758
- }, [
1759
- vue.createCommentVNode(" \u4E0A\u4F20\u4E2D "),
1760
- item.progress < 100 && item.status !== "error" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
1761
- _hoisted_2,
1762
- vue.createVNode(_component_a_progress, {
1763
- type: "line",
1764
- "stroke-width": 2,
1765
- "show-info": false,
1766
- "stroke-color": _ctx.uploadBarColor,
1767
- percent: item.uid?.progress
1768
- }, null, 8, ["stroke-color", "percent"])
1769
- ])) : vue.createCommentVNode("v-if", true),
1770
- vue.createCommentVNode(" \u56FE\u7247\u5C55\u793A "),
1771
- item.progress >= 100 && item.status !== "error" ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
1772
- !_ctx.uploadConfigs.showSlotList ? (vue.openBlock(), vue.createElementBlock("div", {
1773
- key: 0,
1774
- class: "bm-upload__picture-result",
1775
- onMouseenter: ($event) => _ctx.pictureHoverEnter(item.uid),
1776
- onMouseleave: ($event) => _ctx.pictureHoverLeave(item.uid),
1777
- onClick: _cache[0] || (_cache[0] = (e) => e.stopPropagation())
1778
- }, [
1779
- ["pdf", "PDF", "application/pdf"].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1750
+ _ctx.uploadConfigs.listType === "picture-card" ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
1751
+ vue.createCommentVNode(" \u4E0D\u8981\u4F7F\u7528 a-image-preview-group \u5305\u88F9\uFF0C\u4E0D\u7136\u4F1A\u51FA\u73B0\u91CD\u590D\u56FE\u7247\u548C\u7A7A\u767D\u56FE\u7247 "),
1752
+ vue.createCommentVNode(" <a-image-preview-group> "),
1753
+ (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.fileList, (item) => {
1754
+ return vue.openBlock(), vue.createElementBlock("div", {
1755
+ key: item,
1756
+ class: vue.normalizeClass(["bm-upload__picture", { "bm-upload__picture--error": item.status === "error" }])
1757
+ }, [
1758
+ vue.createCommentVNode(" \u4E0A\u4F20\u4E2D "),
1759
+ item.progress < 100 && item.status !== "error" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
1760
+ _hoisted_2,
1761
+ vue.createVNode(_component_a_progress, {
1762
+ type: "line",
1763
+ "stroke-width": 2,
1764
+ "show-info": false,
1765
+ "stroke-color": _ctx.uploadBarColor,
1766
+ percent: item.uid?.progress
1767
+ }, null, 8, ["stroke-color", "percent"])
1768
+ ])) : vue.createCommentVNode("v-if", true),
1769
+ vue.createCommentVNode(" \u56FE\u7247\u5C55\u793A "),
1770
+ item.progress >= 100 && item.status !== "error" ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
1771
+ !_ctx.uploadConfigs.showSlotList ? (vue.openBlock(), vue.createElementBlock("div", {
1780
1772
  key: 0,
1781
- class: "bm-upload__picture-result__image",
1782
- src: $setup.icons.pdf,
1783
- alt: "avatar"
1784
- }, null, 8, _hoisted_4)) : [
1785
- "xlsx",
1786
- "XLSX",
1787
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
1788
- ].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1789
- key: 1,
1790
- class: "bm-upload__picture-result__image",
1791
- src: $setup.icons.excel,
1792
- alt: "avatar"
1793
- }, null, 8, _hoisted_5)) : [
1794
- "ppt",
1795
- "PPT",
1796
- "application/vnd.ms-powerpoint",
1797
- "pptx",
1798
- "PPTX",
1799
- "application/vnd.openxmlformats-officedocument.presentationml.presentation"
1800
- ].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1801
- key: 2,
1802
- class: "bm-upload__picture-result__image",
1803
- src: $setup.icons.ppt,
1804
- alt: "avatar"
1805
- }, null, 8, _hoisted_6)) : [
1806
- "doc",
1807
- "DOC",
1808
- "application/msword",
1809
- "docx",
1810
- "DOCX",
1811
- "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
1812
- ].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1813
- key: 3,
1814
- class: "bm-upload__picture-result__image",
1815
- src: $setup.icons.doc,
1816
- alt: "avatar"
1817
- }, null, 8, _hoisted_7)) : [
1818
- "img",
1819
- "image",
1820
- "png",
1821
- "PNG",
1822
- "image/png",
1823
- "jpg",
1824
- "JPG",
1825
- "jpeg",
1826
- "JPEG",
1827
- "image/jpeg",
1828
- "gif",
1829
- "GIF",
1830
- "image/gif"
1831
- ].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1832
- key: 4,
1833
- class: "bm-upload__picture-result__image",
1834
- src: item.url,
1835
- alt: "avatar"
1836
- }, null, 8, _hoisted_8)) : (vue.openBlock(), vue.createElementBlock("img", {
1837
- key: 5,
1838
- class: "bm-upload__picture-result__image",
1839
- src: $setup.icons.others,
1840
- alt: "avatar"
1841
- }, null, 8, _hoisted_9)),
1842
- _ctx.onepViewImageHover[item.uid] ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_10, [
1843
- !_ctx.extraConfigs.canNotViewAccept?.includes(item?.type) ? (vue.openBlock(), vue.createElementBlock("div", {
1773
+ class: "bm-upload__picture-result",
1774
+ onMouseenter: ($event) => _ctx.pictureHoverEnter(item.uid),
1775
+ onMouseleave: ($event) => _ctx.pictureHoverLeave(item.uid),
1776
+ onClick: _cache[0] || (_cache[0] = (e) => e.stopPropagation())
1777
+ }, [
1778
+ ["pdf", "PDF", "application/pdf"].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1844
1779
  key: 0,
1845
- class: "bm-upload__picture-result__icon bm-upload__picture-result__icon--view",
1846
- onClick: ($event) => _ctx.viewOnePicture(item)
1847
- }, null, 8, _hoisted_11)) : vue.createCommentVNode("v-if", true),
1848
- !(_ctx.extraConfigs.hidenDelBtn ?? false) ? (vue.openBlock(), vue.createElementBlock("div", {
1780
+ class: "bm-upload__picture-result__image",
1781
+ src: $setup.icons.pdf,
1782
+ alt: "\u56FE\u7247"
1783
+ }, null, 8, _hoisted_4)) : [
1784
+ "xlsx",
1785
+ "XLSX",
1786
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
1787
+ ].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1849
1788
  key: 1,
1789
+ class: "bm-upload__picture-result__image",
1790
+ src: $setup.icons.excel,
1791
+ alt: "\u56FE\u7247"
1792
+ }, null, 8, _hoisted_5)) : [
1793
+ "ppt",
1794
+ "PPT",
1795
+ "application/vnd.ms-powerpoint",
1796
+ "pptx",
1797
+ "PPTX",
1798
+ "application/vnd.openxmlformats-officedocument.presentationml.presentation"
1799
+ ].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1800
+ key: 2,
1801
+ class: "bm-upload__picture-result__image",
1802
+ src: $setup.icons.ppt,
1803
+ alt: "\u56FE\u7247"
1804
+ }, null, 8, _hoisted_6)) : [
1805
+ "doc",
1806
+ "DOC",
1807
+ "application/msword",
1808
+ "docx",
1809
+ "DOCX",
1810
+ "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
1811
+ ].includes(item.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1812
+ key: 3,
1813
+ class: "bm-upload__picture-result__image",
1814
+ src: $setup.icons.doc,
1815
+ alt: "\u56FE\u7247"
1816
+ }, null, 8, _hoisted_7)) : _ctx.pictureFileTypes.includes(item.type) ? (vue.openBlock(), vue.createBlock(_component_a_image, {
1817
+ key: 4,
1818
+ class: "bm-upload__picture-result__image",
1819
+ src: item.url,
1820
+ alt: "\u56FE\u7247"
1821
+ }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock("img", {
1822
+ key: 5,
1823
+ class: "bm-upload__picture-result__image",
1824
+ src: $setup.icons.others,
1825
+ alt: "\u56FE\u7247"
1826
+ }, null, 8, _hoisted_8)),
1827
+ _ctx.onepViewImageHover[item.uid] ? (vue.openBlock(), vue.createElementBlock("div", {
1828
+ key: 6,
1829
+ class: vue.normalizeClass(["bm-upload__picture-result__cover", {
1830
+ isPicture: _ctx.pictureFileTypes.includes(item.type)
1831
+ }])
1832
+ }, [
1833
+ !_ctx.extraConfigs.canNotViewAccept?.includes(item?.type) ? (vue.openBlock(), vue.createElementBlock("div", {
1834
+ key: 0,
1835
+ class: "bm-upload__picture-result__icon bm-upload__picture-result__icon--view",
1836
+ onClick: ($event) => _ctx.viewOnePicture(item)
1837
+ }, null, 8, _hoisted_9)) : vue.createCommentVNode("v-if", true),
1838
+ !(_ctx.extraConfigs.hidenDelBtn ?? false) ? (vue.openBlock(), vue.createElementBlock("div", {
1839
+ key: 1,
1840
+ class: "bm-upload__picture-result__icon bm-upload__picture-result__icon--delete",
1841
+ onClick: ($event) => _ctx.deleteFile(item.uid)
1842
+ }, null, 8, _hoisted_10)) : vue.createCommentVNode("v-if", true)
1843
+ ], 2)) : vue.createCommentVNode("v-if", true)
1844
+ ], 40, _hoisted_3)) : vue.renderSlot(_ctx.$slots, "file", {
1845
+ key: 1,
1846
+ file: item
1847
+ })
1848
+ ], 2112)) : vue.createCommentVNode("v-if", true),
1849
+ vue.createCommentVNode(" \u56FE\u7247\u9519\u8BEF\u5C55\u793A "),
1850
+ item.status === "error" ? (vue.openBlock(), vue.createElementBlock("div", {
1851
+ key: 2,
1852
+ class: "bm-upload__picture-error",
1853
+ onMouseenter: ($event) => _ctx.pictureHoverEnter(item.uid),
1854
+ onMouseleave: ($event) => _ctx.pictureHoverLeave(item.uid),
1855
+ onClick: _cache[1] || (_cache[1] = (e) => e.stopPropagation())
1856
+ }, [
1857
+ _hoisted_12,
1858
+ _hoisted_13,
1859
+ _ctx.onepViewImageHover[item.uid] ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_14, [
1860
+ vue.createElementVNode("div", {
1861
+ class: "bm-upload__picture-result__icon bm-upload__picture-result__icon--retry",
1862
+ onClick: (e) => _ctx.reUpload(e, item.uid)
1863
+ }, null, 8, _hoisted_15),
1864
+ vue.createElementVNode("div", {
1850
1865
  class: "bm-upload__picture-result__icon bm-upload__picture-result__icon--delete",
1851
1866
  onClick: ($event) => _ctx.deleteFile(item.uid)
1852
- }, null, 8, _hoisted_12)) : vue.createCommentVNode("v-if", true)
1867
+ }, null, 8, _hoisted_16)
1853
1868
  ])) : vue.createCommentVNode("v-if", true)
1854
- ], 40, _hoisted_3)) : vue.renderSlot(_ctx.$slots, "file", {
1855
- key: 1,
1856
- file: item
1857
- })
1858
- ], 2112)) : vue.createCommentVNode("v-if", true),
1859
- vue.createCommentVNode(" \u56FE\u7247\u9519\u8BEF\u5C55\u793A "),
1860
- item.status === "error" ? (vue.openBlock(), vue.createElementBlock("div", {
1861
- key: 2,
1862
- class: "bm-upload__picture-error",
1863
- onMouseenter: ($event) => _ctx.pictureHoverEnter(item.uid),
1864
- onMouseleave: ($event) => _ctx.pictureHoverLeave(item.uid),
1865
- onClick: _cache[1] || (_cache[1] = (e) => e.stopPropagation())
1866
- }, [
1867
- _hoisted_14,
1868
- _hoisted_15,
1869
- _ctx.onepViewImageHover[item.uid] ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_16, [
1870
- vue.createElementVNode("div", {
1871
- class: "bm-upload__picture-result__icon bm-upload__picture-result__icon--retry",
1872
- onClick: (e) => _ctx.reUpload(e, item.uid)
1873
- }, null, 8, _hoisted_17),
1874
- vue.createElementVNode("div", {
1875
- class: "bm-upload__picture-result__icon bm-upload__picture-result__icon--delete",
1876
- onClick: ($event) => _ctx.deleteFile(item.uid)
1877
- }, null, 8, _hoisted_18)
1878
- ])) : vue.createCommentVNode("v-if", true)
1879
- ], 40, _hoisted_13)) : vue.createCommentVNode("v-if", true)
1880
- ], 2);
1881
- }), 128)) : vue.createCommentVNode("v-if", true),
1869
+ ], 40, _hoisted_11)) : vue.createCommentVNode("v-if", true)
1870
+ ], 2);
1871
+ }), 128)),
1872
+ vue.createCommentVNode(" </a-image-preview-group> ")
1873
+ ], 2112)) : vue.createCommentVNode("v-if", true),
1882
1874
  !($setup.uploadDisabled && _ctx.extraConfigs?.hideDisabledBtn) ? (vue.openBlock(), vue.createBlock(_component_a_upload, vue.mergeProps({ key: 1 }, _ctx.uploadConfigs, {
1883
1875
  class: { "bm--upload__custom-button": _ctx.extraConfigs.myBtn },
1884
1876
  onReject: _ctx.handleReject
1885
1877
  }), {
1886
1878
  default: vue.withCtx(() => [
1887
1879
  _ctx.extraConfigs.myBtn ? vue.renderSlot(_ctx.$slots, "myBtn", { key: 0 }) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
1888
- _ctx.uploadConfigs.listType === "picture-card" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_19, [
1880
+ _ctx.uploadConfigs.listType === "picture-card" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_17, [
1889
1881
  vue.createVNode(_component_PlusOutlined),
1890
- vue.createElementVNode("div", _hoisted_20, vue.toDisplayString(_ctx.uploadConfigs.text || "\u4E0A\u4F20\u56FE\u7247"), 1),
1891
- _ctx.extraConfigs.tips && _ctx.extraConfigs.showTips ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_21, vue.toDisplayString(_ctx.extraConfigs.tips), 1)) : vue.createCommentVNode("v-if", true)
1892
- ])) : _ctx.uploadConfigs.listType === "text" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_22, [
1882
+ vue.createElementVNode("div", _hoisted_18, vue.toDisplayString(_ctx.uploadConfigs.text || "\u4E0A\u4F20\u56FE\u7247"), 1),
1883
+ _ctx.extraConfigs.tips && _ctx.extraConfigs.showTips ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_19, vue.toDisplayString(_ctx.extraConfigs.tips), 1)) : vue.createCommentVNode("v-if", true)
1884
+ ])) : _ctx.uploadConfigs.listType === "text" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_20, [
1893
1885
  vue.createVNode(_component_a_button, {
1894
1886
  class: vue.normalizeClass(_ctx.extraConfigs.btnClass),
1895
1887
  disabled: $setup.uploadDisabled && !_ctx.extraConfigs?.hideDisabledBtn
@@ -1900,39 +1892,39 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
1900
1892
  ]),
1901
1893
  _: 1
1902
1894
  }, 8, ["class", "disabled"]),
1903
- _ctx.extraConfigs.tips && _ctx.extraConfigs.showTips ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_23, vue.toDisplayString(_ctx.extraConfigs.tips), 1)) : vue.createCommentVNode("v-if", true)
1895
+ _ctx.extraConfigs.tips && _ctx.extraConfigs.showTips ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_21, vue.toDisplayString(_ctx.extraConfigs.tips), 1)) : vue.createCommentVNode("v-if", true)
1904
1896
  ])) : vue.createCommentVNode("v-if", true)
1905
1897
  ], 2112))
1906
1898
  ]),
1907
1899
  _: 3
1908
1900
  }, 16, ["class", "onReject"])) : vue.createCommentVNode("v-if", true),
1909
- _ctx.uploadConfigs.listType === "text" && !_ctx.uploadConfigs.showSlotList ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_24, [
1901
+ _ctx.uploadConfigs.listType === "text" && !_ctx.uploadConfigs.showSlotList ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_22, [
1910
1902
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.fileList, (item) => {
1911
1903
  return vue.openBlock(), vue.createElementBlock("div", {
1912
1904
  key: item,
1913
1905
  class: "bm-upload__file"
1914
1906
  }, [
1915
1907
  !_ctx.uploadConfigs.showSlotList ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
1916
- vue.createElementVNode("div", _hoisted_25, [
1917
- _hoisted_26,
1918
- vue.createElementVNode("div", _hoisted_27, [
1908
+ vue.createElementVNode("div", _hoisted_23, [
1909
+ _hoisted_24,
1910
+ vue.createElementVNode("div", _hoisted_25, [
1919
1911
  vue.createVNode(_component_OverTooltips, {
1920
1912
  title: item.name
1921
1913
  }, null, 8, ["title"])
1922
1914
  ]),
1923
- vue.createElementVNode("div", _hoisted_28, [
1915
+ vue.createElementVNode("div", _hoisted_26, [
1924
1916
  item.status === "error" ? (vue.openBlock(), vue.createElementBlock("div", {
1925
1917
  key: 0,
1926
1918
  class: "bm-upload__error-reload",
1927
1919
  onClick: (e) => _ctx.reUpload(e, item.uid)
1928
- }, null, 8, _hoisted_29)) : vue.createCommentVNode("v-if", true),
1920
+ }, null, 8, _hoisted_27)) : vue.createCommentVNode("v-if", true),
1929
1921
  vue.createElementVNode("div", {
1930
1922
  class: "bm-upload__trash",
1931
1923
  onClick: ($event) => _ctx.deleteFile(item.uid)
1932
- }, null, 8, _hoisted_30)
1924
+ }, null, 8, _hoisted_28)
1933
1925
  ])
1934
1926
  ]),
1935
- !item.isDoneDeloy || item.progress < 100 || item.status === "error" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_31, [
1927
+ !item.isDoneDeloy || item.progress < 100 || item.status === "error" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_29, [
1936
1928
  vue.createVNode(_component_a_progress, {
1937
1929
  type: "line",
1938
1930
  "stroke-width": 2,
@@ -1955,32 +1947,18 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
1955
1947
  onCancel: _ctx.handleClosePictureView
1956
1948
  }, {
1957
1949
  default: vue.withCtx(() => [
1958
- vue.createElementVNode("div", _hoisted_32, [
1959
- [
1960
- "img",
1961
- "image",
1962
- "png",
1963
- "PNG",
1964
- "image/png",
1965
- "jpg",
1966
- "JPG",
1967
- "jpeg",
1968
- "JPEG",
1969
- "image/jpeg",
1970
- "gif",
1971
- "GIF",
1972
- "image/gif"
1973
- ].includes(_ctx.onepViewImage.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1950
+ vue.createElementVNode("div", _hoisted_30, [
1951
+ _ctx.pictureFileTypes.includes(_ctx.onepViewImage.type) ? (vue.openBlock(), vue.createElementBlock("img", {
1974
1952
  key: 0,
1975
1953
  style: { "width": "100%" },
1976
1954
  src: _ctx.onepViewImage.url,
1977
1955
  alt: ""
1978
- }, null, 8, _hoisted_33)) : (vue.openBlock(), vue.createElementBlock("iframe", {
1956
+ }, null, 8, _hoisted_31)) : (vue.openBlock(), vue.createElementBlock("iframe", {
1979
1957
  key: 1,
1980
1958
  title: _ctx.onepViewImage.type,
1981
1959
  style: { "width": "100%", "min-height": "600px" },
1982
1960
  src: _ctx.onepViewImage.url
1983
- }, null, 8, _hoisted_34))
1961
+ }, null, 8, _hoisted_32))
1984
1962
  ])
1985
1963
  ]),
1986
1964
  _: 1
@@ -100,7 +100,7 @@ declare const _default: {
100
100
  fileList: import("vue").Ref<{}>;
101
101
  onepViewImageHover: import("vue").Ref<{}>;
102
102
  previewVisible: import("vue").Ref<boolean>;
103
- onepViewImage: import("vue").Ref<string>;
103
+ onepViewImage: import("vue").Ref<{}>;
104
104
  extraConfigs: import("vue").Ref<{
105
105
  maxSize: number;
106
106
  maxCount: number;
@@ -130,6 +130,7 @@ declare const _default: {
130
130
  data: any;
131
131
  }) => Promise<void>;
132
132
  }>;
133
+ pictureFileTypes: import("vue").Ref<string[]>;
133
134
  };
134
135
  };
135
136
  export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bm-admin-ui",
3
- "version": "1.0.31-alpha",
3
+ "version": "1.0.32-alpha",
4
4
  "private": false,
5
5
  "description": "An Admin Component Library for Bm",
6
6
  "license": "UNLICENSED",