@kp-ui/lowcode 2.13.1 → 2.13.2

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/index.js CHANGED
@@ -22623,55 +22623,58 @@ const FileIcon = /* @__PURE__ */ defineComponent({
22623
22623
  handleDownload: a
22624
22624
  } = useFilePreview(), r = ref([]);
22625
22625
  return watchEffect(() => {
22626
- typeof o.data == "string" ? r.value = JSON.parse(o.data) : r.value = o.data;
22626
+ typeof o.data == "string" ? r.value = JSON.parse(o.data) || [] : r.value = o.data || [];
22627
22627
  }), onMounted(() => {
22628
- }), (d, s) => r.value.length ? (openBlock(), createElementBlock("div", _hoisted_1$x, [
22629
- createElementVNode("div", _hoisted_2$9, [
22630
- (openBlock(!0), createElementBlock(Fragment, null, renderList(r.value, (c, u) => (openBlock(), createElementBlock("div", {
22631
- key: u,
22632
- class: "file-item"
22633
- }, [
22634
- createElementVNode("div", _hoisted_3$4, [
22635
- createVNode(unref(FileIcon), { file: c }, null, 8, ["file"])
22636
- ]),
22637
- createElementVNode("span", _hoisted_4$3, toDisplayString(c.fileName), 1),
22638
- createVNode(unref(Button), {
22639
- type: "link",
22640
- onClick: () => unref(a)(c)
22641
- }, {
22642
- icon: withCtx(() => [
22643
- createVNode(unref(DownloadOutlined))
22644
- ]),
22645
- _: 2
22646
- }, 1032, ["onClick"]),
22647
- createVNode(unref(Button), {
22648
- type: "link",
22649
- onClick: () => unref(i)(c)
22650
- }, {
22651
- icon: withCtx(() => [
22652
- createVNode(unref(EyeOutlined))
22628
+ }), (d, s) => {
22629
+ var c;
22630
+ return (c = r.value) != null && c.length ? (openBlock(), createElementBlock("div", _hoisted_1$x, [
22631
+ createElementVNode("div", _hoisted_2$9, [
22632
+ (openBlock(!0), createElementBlock(Fragment, null, renderList(r.value, (u, m) => (openBlock(), createElementBlock("div", {
22633
+ key: m,
22634
+ class: "file-item"
22635
+ }, [
22636
+ createElementVNode("div", _hoisted_3$4, [
22637
+ createVNode(unref(FileIcon), { file: u }, null, 8, ["file"])
22653
22638
  ]),
22654
- _: 2
22655
- }, 1032, ["onClick"])
22656
- ]))), 128))
22657
- ]),
22658
- createVNode(unref(TpfModal), {
22659
- visible: unref(t),
22660
- "onUpdate:visible": s[0] || (s[0] = (c) => isRef(t) ? t.value = c : null),
22661
- title: unref(l),
22662
- footer: null
22663
- }, {
22664
- default: withCtx(() => [
22665
- createElementVNode("img", {
22666
- style: { width: "100%" },
22667
- src: unref(n)
22668
- }, null, 8, _hoisted_5$3)
22639
+ createElementVNode("span", _hoisted_4$3, toDisplayString(u.fileName), 1),
22640
+ createVNode(unref(Button), {
22641
+ type: "link",
22642
+ onClick: () => unref(a)(u)
22643
+ }, {
22644
+ icon: withCtx(() => [
22645
+ createVNode(unref(DownloadOutlined))
22646
+ ]),
22647
+ _: 2
22648
+ }, 1032, ["onClick"]),
22649
+ createVNode(unref(Button), {
22650
+ type: "link",
22651
+ onClick: () => unref(i)(u)
22652
+ }, {
22653
+ icon: withCtx(() => [
22654
+ createVNode(unref(EyeOutlined))
22655
+ ]),
22656
+ _: 2
22657
+ }, 1032, ["onClick"])
22658
+ ]))), 128))
22669
22659
  ]),
22670
- _: 1
22671
- }, 8, ["visible", "title"])
22672
- ])) : createCommentVNode("", !0);
22660
+ createVNode(unref(TpfModal), {
22661
+ visible: unref(t),
22662
+ "onUpdate:visible": s[0] || (s[0] = (u) => isRef(t) ? t.value = u : null),
22663
+ title: unref(l),
22664
+ footer: null
22665
+ }, {
22666
+ default: withCtx(() => [
22667
+ createElementVNode("img", {
22668
+ style: { width: "100%" },
22669
+ src: unref(n)
22670
+ }, null, 8, _hoisted_5$3)
22671
+ ]),
22672
+ _: 1
22673
+ }, 8, ["visible", "title"])
22674
+ ])) : createCommentVNode("", !0);
22675
+ };
22673
22676
  }
22674
- }), AttachmentRender = /* @__PURE__ */ _export_sfc(_sfc_main$J, [["__scopeId", "data-v-c73b2741"]]), AttachmentRender$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
22677
+ }), AttachmentRender = /* @__PURE__ */ _export_sfc(_sfc_main$J, [["__scopeId", "data-v-4b5130ce"]]), AttachmentRender$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
22675
22678
  __proto__: null,
22676
22679
  default: AttachmentRender
22677
22680
  }, Symbol.toStringTag, { value: "Module" }));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kp-ui/lowcode",
3
- "version": "2.13.1",
3
+ "version": "2.13.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },