sun-card-design 1.3.0 → 1.3.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.
Files changed (70) hide show
  1. package/dist/mobile/sun-card-design-mobile.es10.js +6 -6
  2. package/dist/mobile/sun-card-design-mobile.es11.js +8 -8
  3. package/dist/mobile/sun-card-design-mobile.es12.js +1 -1
  4. package/dist/mobile/sun-card-design-mobile.es13.js +1 -1
  5. package/dist/mobile/sun-card-design-mobile.es14.js +6 -6
  6. package/dist/mobile/sun-card-design-mobile.es15.js +13 -12
  7. package/dist/mobile/sun-card-design-mobile.es16.js +6 -6
  8. package/dist/mobile/sun-card-design-mobile.es17.js +6 -6
  9. package/dist/mobile/sun-card-design-mobile.es18.js +6 -6
  10. package/dist/mobile/sun-card-design-mobile.es19.js +7 -7
  11. package/dist/mobile/sun-card-design-mobile.es2.js +15 -25
  12. package/dist/mobile/sun-card-design-mobile.es20.js +8 -10
  13. package/dist/mobile/sun-card-design-mobile.es21.js +1 -1
  14. package/dist/mobile/sun-card-design-mobile.es22.js +8 -9
  15. package/dist/mobile/sun-card-design-mobile.es23.js +1 -1
  16. package/dist/mobile/sun-card-design-mobile.es24.js +9 -10
  17. package/dist/mobile/sun-card-design-mobile.es25.js +75 -47
  18. package/dist/mobile/sun-card-design-mobile.es27.js +10 -0
  19. package/dist/mobile/sun-card-design-mobile.es28.js +60 -6
  20. package/dist/mobile/sun-card-design-mobile.es3.js +14 -14
  21. package/dist/mobile/sun-card-design-mobile.es37.js +1 -1
  22. package/dist/mobile/sun-card-design-mobile.es4.js +17 -17
  23. package/dist/mobile/sun-card-design-mobile.es42.js +1 -1
  24. package/dist/mobile/sun-card-design-mobile.es5.js +12 -12
  25. package/dist/mobile/sun-card-design-mobile.es55.js +1 -1
  26. package/dist/mobile/sun-card-design-mobile.es56.js +1 -1
  27. package/dist/mobile/sun-card-design-mobile.es57.js +13 -12
  28. package/dist/mobile/sun-card-design-mobile.es58.js +13 -12
  29. package/dist/mobile/sun-card-design-mobile.es59.js +13 -12
  30. package/dist/mobile/sun-card-design-mobile.es6.js +13 -13
  31. package/dist/mobile/sun-card-design-mobile.es60.js +13 -12
  32. package/dist/mobile/sun-card-design-mobile.es7.js +16 -16
  33. package/dist/mobile/sun-card-design-mobile.es8.js +1 -1
  34. package/dist/mobile/sun-card-design-mobile.es9.js +1 -1
  35. package/dist/pc/sun-card-design-pc.es10.js +6 -6
  36. package/dist/pc/sun-card-design-pc.es11.js +8 -8
  37. package/dist/pc/sun-card-design-pc.es12.js +1 -1
  38. package/dist/pc/sun-card-design-pc.es13.js +1 -1
  39. package/dist/pc/sun-card-design-pc.es14.js +6 -6
  40. package/dist/pc/sun-card-design-pc.es15.js +13 -12
  41. package/dist/pc/sun-card-design-pc.es16.js +6 -6
  42. package/dist/pc/sun-card-design-pc.es17.js +6 -6
  43. package/dist/pc/sun-card-design-pc.es18.js +6 -6
  44. package/dist/pc/sun-card-design-pc.es19.js +7 -7
  45. package/dist/pc/sun-card-design-pc.es2.js +16 -34
  46. package/dist/pc/sun-card-design-pc.es20.js +8 -10
  47. package/dist/pc/sun-card-design-pc.es21.js +1 -1
  48. package/dist/pc/sun-card-design-pc.es22.js +8 -9
  49. package/dist/pc/sun-card-design-pc.es23.js +1 -1
  50. package/dist/pc/sun-card-design-pc.es24.js +9 -10
  51. package/dist/pc/sun-card-design-pc.es25.js +75 -47
  52. package/dist/pc/sun-card-design-pc.es27.js +10 -0
  53. package/dist/pc/sun-card-design-pc.es28.js +60 -6
  54. package/dist/pc/sun-card-design-pc.es3.js +14 -14
  55. package/dist/pc/sun-card-design-pc.es37.js +1 -1
  56. package/dist/pc/sun-card-design-pc.es4.js +17 -17
  57. package/dist/pc/sun-card-design-pc.es42.js +1 -1
  58. package/dist/pc/sun-card-design-pc.es5.js +12 -12
  59. package/dist/pc/sun-card-design-pc.es55.js +1 -1
  60. package/dist/pc/sun-card-design-pc.es56.js +1 -1
  61. package/dist/pc/sun-card-design-pc.es57.js +13 -12
  62. package/dist/pc/sun-card-design-pc.es58.js +13 -12
  63. package/dist/pc/sun-card-design-pc.es59.js +13 -12
  64. package/dist/pc/sun-card-design-pc.es6.js +13 -13
  65. package/dist/pc/sun-card-design-pc.es60.js +13 -12
  66. package/dist/pc/sun-card-design-pc.es7.js +16 -16
  67. package/dist/pc/sun-card-design-pc.es8.js +1 -1
  68. package/dist/pc/sun-card-design-pc.es9.js +1 -1
  69. package/dist/public/sun-card-design.css +1 -1
  70. package/package.json +1 -1
@@ -1,14 +1,14 @@
1
1
  import { useCssVars, computed, resolveComponent, createElementBlock, openBlock, createElementVNode, createVNode, unref } from "vue";
2
- import { renderTextByVariables } from "./sun-card-design-mobile.es26.js";
2
+ import { renderTextByVariables } from "./sun-card-design-mobile.es28.js";
3
3
  /* empty css */
4
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
5
5
  const _hoisted_1 = { class: "main-rate" };
6
6
  const _sfc_main = {
7
7
  __name: "rateComp",
8
- props: ["record"],
8
+ props: ["record", "variableList"],
9
9
  setup(__props) {
10
10
  useCssVars((_ctx) => ({
11
- "v328335d6": mainPadding.value
11
+ "v842056f2": mainPadding.value
12
12
  }));
13
13
  const props = __props;
14
14
  const mainPadding = computed(() => {
@@ -21,7 +21,7 @@ const _sfc_main = {
21
21
  return openBlock(), createElementBlock("div", null, [
22
22
  createElementVNode("div", _hoisted_1, [
23
23
  createVNode(_component_a_rate, {
24
- value: unref(renderTextByVariables)(props.record.options.defaultValue) * 1,
24
+ value: unref(renderTextByVariables)(props.record.options.defaultValue, 0, props.variableList) * 1,
25
25
  count: props.record.options.count,
26
26
  "allow-half": "",
27
27
  disabled: ""
@@ -31,7 +31,7 @@ const _sfc_main = {
31
31
  };
32
32
  }
33
33
  };
34
- const Rate = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-560a4494"]]);
34
+ const Rate = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-e3bdff7b"]]);
35
35
  export {
36
36
  Rate as default
37
37
  };
@@ -1,17 +1,17 @@
1
1
  import { useCssVars, computed, resolveComponent, createElementBlock, openBlock, createElementVNode, createVNode, withCtx, createTextVNode, toDisplayString, unref } from "vue";
2
- import { renderTextByVariables } from "./sun-card-design-mobile.es26.js";
2
+ import { renderTextByVariables } from "./sun-card-design-mobile.es28.js";
3
3
  /* empty css */
4
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
5
5
  const _hoisted_1 = { class: "main-tag" };
6
6
  const _sfc_main = {
7
7
  __name: "tagComp",
8
- props: ["record"],
8
+ props: ["record", "variableList"],
9
9
  emits: ["clickEvent"],
10
10
  setup(__props, { emit: __emit }) {
11
11
  useCssVars((_ctx) => ({
12
- "v709d157f": mainPadding.value,
13
- "cd06f03c": tagColor.value,
14
- "c3dff7de": tagFontSize.value
12
+ "v249efca6": mainPadding.value,
13
+ "ce756bca": tagColor.value,
14
+ "v5211eb38": tagFontSize.value
15
15
  }));
16
16
  const props = __props;
17
17
  const emit = __emit;
@@ -37,7 +37,7 @@ const _sfc_main = {
37
37
  onClick
38
38
  }, {
39
39
  default: withCtx(() => [
40
- createTextVNode(toDisplayString(unref(renderTextByVariables)(props.record.options.defaultValue)), 1)
40
+ createTextVNode(toDisplayString(unref(renderTextByVariables)(props.record.options.defaultValue, 0, props.variableList)), 1)
41
41
  ]),
42
42
  _: 1
43
43
  }, 8, ["color"])
@@ -46,7 +46,7 @@ const _sfc_main = {
46
46
  };
47
47
  }
48
48
  };
49
- const Tag = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-6d50d817"]]);
49
+ const Tag = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-28154f11"]]);
50
50
  export {
51
51
  Tag as default
52
52
  };
@@ -1,6 +1,6 @@
1
1
  import { useCssVars, computed, resolveComponent, createElementBlock, openBlock, createElementVNode, createVNode } from "vue";
2
2
  /* empty css */
3
- import _export_sfc from "./sun-card-design-mobile.es28.js";
3
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
4
4
  const _hoisted_1 = { class: "main-divider" };
5
5
  const _sfc_main = {
6
6
  __name: "dividerComp",
@@ -2,7 +2,7 @@ import { useCssVars, computed, ref, resolveComponent, createElementBlock, openBl
2
2
  import { panoramaSvg } from "./sun-card-design-mobile.es34.js";
3
3
  import PanoramaView from "./sun-card-design-mobile.es42.js";
4
4
  /* empty css */
5
- import _export_sfc from "./sun-card-design-mobile.es28.js";
5
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
6
6
  const _hoisted_1 = { class: "main-panorama" };
7
7
  const _hoisted_2 = { class: "panorama-box" };
8
8
  const _hoisted_3 = ["src"];
@@ -1,15 +1,15 @@
1
1
  import { useCssVars, computed, resolveComponent, createElementBlock, openBlock, createVNode, withCtx, createTextVNode, toDisplayString, unref } from "vue";
2
2
  import html2canvas from "html2canvas";
3
- import { renderTextByVariables } from "./sun-card-design-mobile.es26.js";
3
+ import { renderTextByVariables } from "./sun-card-design-mobile.es28.js";
4
4
  /* empty css */
5
- import _export_sfc from "./sun-card-design-mobile.es28.js";
5
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
6
6
  const _hoisted_1 = { class: "main-button" };
7
7
  const _sfc_main = {
8
8
  __name: "generateImgComp",
9
- props: ["record"],
9
+ props: ["record", "variableList"],
10
10
  setup(__props) {
11
11
  useCssVars((_ctx) => ({
12
- "a09d9796": mainPadding.value
12
+ "bbada1d8": mainPadding.value
13
13
  }));
14
14
  const props = __props;
15
15
  const mainPadding = computed(() => {
@@ -53,7 +53,7 @@ const _sfc_main = {
53
53
  onClick: onGenerate
54
54
  }, {
55
55
  default: withCtx(() => [
56
- createTextVNode(toDisplayString(unref(renderTextByVariables)(props.record.options.defaultValue)), 1)
56
+ createTextVNode(toDisplayString(unref(renderTextByVariables)(props.record.options.defaultValue, 0, props.variableList)), 1)
57
57
  ]),
58
58
  _: 1
59
59
  })
@@ -61,7 +61,7 @@ const _sfc_main = {
61
61
  };
62
62
  }
63
63
  };
64
- const GenerateImg = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-a9ba174d"]]);
64
+ const GenerateImg = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-32aeb5a9"]]);
65
65
  export {
66
66
  GenerateImg as default
67
67
  };
@@ -1,23 +1,23 @@
1
1
  import { useCssVars, computed, resolveComponent, createElementBlock, openBlock, createVNode, withCtx, Fragment, renderList, createBlock, normalizeStyle, createElementVNode } from "vue";
2
2
  import FormItem from "./sun-card-design-mobile.es25.js";
3
3
  /* empty css */
4
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
5
5
  const _hoisted_1 = { class: "main-grid" };
6
6
  const _hoisted_2 = ["onClick"];
7
7
  const _sfc_main = {
8
8
  __name: "gridComp",
9
- props: ["record", "recordData", "columnsIndex"],
9
+ props: ["record", "recordData", "columnsIndex", "variableList"],
10
10
  emits: ["clickEvent", "clickColumnsEvent", "fileUpdateEvent"],
11
11
  setup(__props, { emit: __emit }) {
12
12
  useCssVars((_ctx) => ({
13
- "v006886e2": mainBackground.value,
14
- "v6ee75b91": boxBackground.value,
15
- "v74cc240f": boxBorder.value,
16
- "v91dc14fe": boxBorderRadius.value,
17
- "v1eb2eee4": boxPadding.value,
18
- "v709306a8": boxJustifyContent.value,
19
- "v77428154": boxMinHeight.value,
20
- "dd37adfa": boxShadow.value
13
+ "f9f4701c": mainBackground.value,
14
+ "v5a5cd7ce": boxBackground.value,
15
+ "v73897268": boxBorder.value,
16
+ "c9cd5304": boxBorderRadius.value,
17
+ "v65c8851e": boxPadding.value,
18
+ "v712cdb2e": boxJustifyContent.value,
19
+ "v585a4779": boxMinHeight.value,
20
+ "v3a596880": boxShadow.value
21
21
  }));
22
22
  const props = __props;
23
23
  const emit = __emit;
@@ -90,11 +90,12 @@ const _sfc_main = {
90
90
  (openBlock(true), createElementBlock(Fragment, null, renderList(item.list, (element, index2) => {
91
91
  return openBlock(), createBlock(FormItem, {
92
92
  record: element,
93
+ variableList: props.variableList,
93
94
  key: index2,
94
95
  columnsIndex: getIndex(item.index),
95
96
  onClickEvent: onClick,
96
97
  onFileUpdateEvent: onUpdate
97
- }, null, 8, ["record", "columnsIndex"]);
98
+ }, null, 8, ["record", "variableList", "columnsIndex"]);
98
99
  }), 128))
99
100
  ], 8, _hoisted_2)
100
101
  ]),
@@ -108,7 +109,7 @@ const _sfc_main = {
108
109
  };
109
110
  }
110
111
  };
111
- const Grid = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-5e173df1"]]);
112
+ const Grid = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-39c6b949"]]);
112
113
  export {
113
114
  Grid as default
114
115
  };
@@ -1,14 +1,14 @@
1
1
  import { useCssVars, computed, resolveComponent, createElementBlock, openBlock, createVNode, withCtx, unref } from "vue";
2
- import { renderTextByVariables } from "./sun-card-design-mobile.es26.js";
2
+ import { renderTextByVariables } from "./sun-card-design-mobile.es28.js";
3
3
  /* empty css */
4
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
5
5
  const _hoisted_1 = { class: "main-input" };
6
6
  const _sfc_main = {
7
7
  __name: "inputComp",
8
- props: ["record"],
8
+ props: ["record", "variableList"],
9
9
  setup(__props) {
10
10
  useCssVars((_ctx) => ({
11
- "v0cbc7152": mainPadding.value
11
+ "v7df9848d": mainPadding.value
12
12
  }));
13
13
  const props = __props;
14
14
  const mainPadding = computed(() => {
@@ -26,7 +26,7 @@ const _sfc_main = {
26
26
  }, {
27
27
  default: withCtx(() => [
28
28
  createVNode(_component_a_form_item, {
29
- label: unref(renderTextByVariables)(props.record.options.label)
29
+ label: unref(renderTextByVariables)(props.record.options.label, 0, props.variableList)
30
30
  }, {
31
31
  default: withCtx(() => [
32
32
  createVNode(_component_a_input, {
@@ -44,7 +44,7 @@ const _sfc_main = {
44
44
  };
45
45
  }
46
46
  };
47
- const Input = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-5a467bf8"]]);
47
+ const Input = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-a13d55b6"]]);
48
48
  export {
49
49
  Input as default
50
50
  };
@@ -1,14 +1,14 @@
1
1
  import { useCssVars, computed, resolveComponent, createElementBlock, openBlock, createVNode, withCtx, unref } from "vue";
2
- import { renderTextByVariables } from "./sun-card-design-mobile.es26.js";
2
+ import { renderTextByVariables } from "./sun-card-design-mobile.es28.js";
3
3
  /* empty css */
4
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
5
5
  const _hoisted_1 = { class: "main-select" };
6
6
  const _sfc_main = {
7
7
  __name: "selectComp",
8
- props: ["record"],
8
+ props: ["record", "variableList"],
9
9
  setup(__props) {
10
10
  useCssVars((_ctx) => ({
11
- "v238a1ca9": mainPadding.value
11
+ "v15e4499d": mainPadding.value
12
12
  }));
13
13
  const props = __props;
14
14
  const mainPadding = computed(() => {
@@ -26,7 +26,7 @@ const _sfc_main = {
26
26
  }, {
27
27
  default: withCtx(() => [
28
28
  createVNode(_component_a_form_item, {
29
- label: unref(renderTextByVariables)(props.record.options.label)
29
+ label: unref(renderTextByVariables)(props.record.options.label, 0, props.variableList)
30
30
  }, {
31
31
  default: withCtx(() => [
32
32
  createVNode(_component_a_select, {
@@ -46,7 +46,7 @@ const _sfc_main = {
46
46
  };
47
47
  }
48
48
  };
49
- const Select = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-571dd7f7"]]);
49
+ const Select = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-0b44cd1c"]]);
50
50
  export {
51
51
  Select as default
52
52
  };
@@ -1,14 +1,14 @@
1
1
  import { useCssVars, computed, ref, resolveComponent, createElementBlock, openBlock, createVNode, withCtx, unref } from "vue";
2
- import { renderTextByVariables } from "./sun-card-design-mobile.es26.js";
2
+ import { renderTextByVariables } from "./sun-card-design-mobile.es28.js";
3
3
  /* empty css */
4
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
5
5
  const _hoisted_1 = { class: "main-enterpriseSearch" };
6
6
  const _sfc_main = {
7
7
  __name: "enterpriseSearch",
8
- props: ["record"],
8
+ props: ["record", "variableList"],
9
9
  setup(__props) {
10
10
  useCssVars((_ctx) => ({
11
- "v0fe1127a": mainPadding.value
11
+ "v21023209": mainPadding.value
12
12
  }));
13
13
  const props = __props;
14
14
  const value = ref(props.record.options?.defaultValue || null);
@@ -27,7 +27,7 @@ const _sfc_main = {
27
27
  }, {
28
28
  default: withCtx(() => [
29
29
  createVNode(_component_a_form_item, {
30
- label: unref(renderTextByVariables)(props.record.options.label)
30
+ label: unref(renderTextByVariables)(props.record.options.label, 0, props.variableList)
31
31
  }, {
32
32
  default: withCtx(() => [
33
33
  createVNode(_component_a_select, {
@@ -47,7 +47,7 @@ const _sfc_main = {
47
47
  };
48
48
  }
49
49
  };
50
- const EnterpriseSearch = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-c8667f37"]]);
50
+ const EnterpriseSearch = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-40942fc1"]]);
51
51
  export {
52
52
  EnterpriseSearch as default
53
53
  };
@@ -1,15 +1,15 @@
1
1
  import { useCssVars, computed, resolveComponent, createElementBlock, openBlock, createVNode } from "vue";
2
2
  /* empty css */
3
- import _export_sfc from "./sun-card-design-mobile.es28.js";
3
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
4
4
  const _hoisted_1 = { class: "main-table" };
5
5
  const _sfc_main = {
6
6
  __name: "tableComp",
7
- props: ["record"],
7
+ props: ["record", "variableList"],
8
8
  setup(__props) {
9
9
  useCssVars((_ctx) => ({
10
- "v541db8cf": mainPadding.value,
11
- "v4a954456": tableFontSize.value,
12
- "v0db5956c": tableCellPadding.value
10
+ "v356dc688": mainPadding.value,
11
+ "v62d10afc": tableFontSize.value,
12
+ "v21e78506": tableCellPadding.value
13
13
  }));
14
14
  const props = __props;
15
15
  const mainPadding = computed(() => {
@@ -32,7 +32,7 @@ const _sfc_main = {
32
32
  };
33
33
  const resolveArrayFromVariable = (name) => {
34
34
  if (!name) return [];
35
- const v = (cardManageStore.variableList || []).find((e) => e.name === name);
35
+ const v = (props.variableList || []).find((e) => e.name === name);
36
36
  if (!v || !v.defaultValue) return [];
37
37
  const data = typeof v.defaultValue === "string" ? parseJsonSafe(v.defaultValue) : v.defaultValue;
38
38
  return Array.isArray(data) ? data : [];
@@ -58,7 +58,7 @@ const _sfc_main = {
58
58
  };
59
59
  }
60
60
  };
61
- const Table = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-287563f8"]]);
61
+ const Table = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-756a9985"]]);
62
62
  export {
63
63
  Table as default
64
64
  };
@@ -1,8 +1,7 @@
1
1
  import { createElementBlock, openBlock, normalizeStyle, Fragment, renderList, createBlock } from "vue";
2
2
  import FormItem from "./sun-card-design-mobile.es25.js";
3
- import { previewData } from "./sun-card-design-mobile.es26.js";
4
3
  /* empty css */
5
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
6
5
  const _sfc_main = {
7
6
  __name: "mobilePanel",
8
7
  props: ["record", "config"],
@@ -10,12 +9,8 @@ const _sfc_main = {
10
9
  setup(__props, { emit: __emit }) {
11
10
  const emit = __emit;
12
11
  const props = __props;
13
- if (props?.config?.variableList) {
14
- previewData.variableList = JSON.parse(JSON.stringify(props?.config?.variableList));
15
- console.info("config: ", props?.config);
16
- }
17
- adapter(props.record.list);
18
- console.info("props.record.list: ", props.record.list);
12
+ adapter(props.record.list, props.config?.variableList);
13
+ console.info("props: ", props);
19
14
  const onClick = (record) => {
20
15
  emit("clickEvent", record);
21
16
  };
@@ -25,13 +20,13 @@ const _sfc_main = {
25
20
  const onClickColumns = (record) => {
26
21
  emit("clickColumnsEvent", record);
27
22
  };
28
- function adapter(recordList = []) {
23
+ function adapter(recordList = [], variableList = []) {
29
24
  if (!Array.isArray(recordList)) return;
30
25
  recordList.forEach((item) => {
31
26
  if (!item || typeof item !== "object") return;
32
27
  if (["grid", "singleColumn", "multipleColumn", "multipleLine", "gridList"].includes(item.type)) {
33
28
  if (item.options.dataType === "动态格数" && item.options.variableName) {
34
- const variableItem = previewData.variableList.find(
29
+ const variableItem = variableList.find(
35
30
  (v) => v && v.name === item.options.variableName && v.type === "Array"
36
31
  );
37
32
  if (variableItem && variableItem.defaultValue) {
@@ -39,18 +34,12 @@ const _sfc_main = {
39
34
  const defaultValueArray = JSON.parse(variableItem.defaultValue);
40
35
  if (Array.isArray(defaultValueArray) && item.columns[0]) {
41
36
  const targetLength = defaultValueArray.length;
42
- const currentLength = item.columns.length;
43
- item.columns.forEach((col, idx) => {
44
- if (col && (col.index === void 0 || col.index === null)) {
45
- col.index = idx;
46
- }
47
- });
48
- if (currentLength !== targetLength) {
49
- for (let index = currentLength; index < targetLength; index++) {
50
- const newColumn = JSON.parse(JSON.stringify(item.columns[0]));
51
- newColumn.index = index;
52
- item.columns.push(newColumn);
53
- }
37
+ const templateColumn = item.columns[0];
38
+ item.columns = [];
39
+ for (let index = 0; index < targetLength; index++) {
40
+ const newColumn = JSON.parse(JSON.stringify(templateColumn));
41
+ newColumn.index = index;
42
+ item.columns.push(newColumn);
54
43
  }
55
44
  }
56
45
  } catch (error) {
@@ -61,7 +50,7 @@ const _sfc_main = {
61
50
  if (Array.isArray(item.columns)) {
62
51
  item.columns.forEach((e) => {
63
52
  if (e && e.list) {
64
- adapter(e.list);
53
+ adapter(e.list, variableList);
65
54
  }
66
55
  });
67
56
  }
@@ -80,18 +69,19 @@ const _sfc_main = {
80
69
  (openBlock(true), createElementBlock(Fragment, null, renderList(props.record.list, (item, index) => {
81
70
  return openBlock(), createBlock(FormItem, {
82
71
  recordData: props.record,
72
+ variableList: props.config?.variableList,
83
73
  record: item,
84
74
  key: index,
85
75
  onClickEvent: onClick,
86
76
  onFileUpdateEvent: onUpdated,
87
77
  onClickColumnsEvent: onClickColumns
88
- }, null, 8, ["recordData", "record"]);
78
+ }, null, 8, ["recordData", "variableList", "record"]);
89
79
  }), 128))
90
80
  ], 4);
91
81
  };
92
82
  }
93
83
  };
94
- const MobilePanel = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-098e6257"]]);
84
+ const MobilePanel = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-22934fb8"]]);
95
85
  export {
96
86
  MobilePanel as default
97
87
  };
@@ -1,17 +1,16 @@
1
1
  import { useCssVars, computed, ref, onMounted, nextTick, onBeforeUnmount, createElementBlock, openBlock, createElementVNode } from "vue";
2
- import { previewData } from "./sun-card-design-mobile.es26.js";
3
2
  import * as echarts from "echarts";
4
3
  /* empty css */
5
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
6
5
  const _hoisted_1 = { class: "barChart-table" };
7
6
  const _sfc_main = {
8
7
  __name: "barChartComp",
9
- props: ["record"],
8
+ props: ["record", "variableList"],
10
9
  setup(__props) {
11
10
  useCssVars((_ctx) => ({
12
- "v69bb11f9": mainPadding.value,
13
- "fdb12af2": chartWidth.value,
14
- "ec1226f4": chartHeight.value
11
+ "v54395fea": mainPadding.value,
12
+ "v259f1a76": chartWidth.value,
13
+ "v74753a77": chartHeight.value
15
14
  }));
16
15
  const props = __props;
17
16
  const mainPadding = computed(() => {
@@ -42,7 +41,7 @@ const _sfc_main = {
42
41
  };
43
42
  const resolveArrayFromVariable = (name) => {
44
43
  if (!name) return [];
45
- const v = (previewData.variableList || []).find((e) => e.name === name);
44
+ const v = (props.variableList || []).find((e) => e.name === name);
46
45
  if (!v || !v.defaultValue) return [];
47
46
  const data = typeof v.defaultValue === "string" ? parseJsonSafe(v.defaultValue) : v.defaultValue;
48
47
  if (!Array.isArray(data)) return [];
@@ -70,7 +69,7 @@ const _sfc_main = {
70
69
  const originalSeriesCfg = props.record.options.seriesConfig || [];
71
70
  const seriesCfg = deepClone(originalSeriesCfg);
72
71
  const firstSeriesData = originalSeriesCfg?.[0]?.data;
73
- const dyData = typeof firstSeriesData === "string" ? (previewData.variableList || []).find((v) => v.name === firstSeriesData) : null;
72
+ const dyData = typeof firstSeriesData === "string" ? (props.variableList || []).find((v) => v.name === firstSeriesData) : null;
74
73
  if (dyData) {
75
74
  const dyDataList = typeof dyData.defaultValue === "string" ? parseJsonSafe(dyData.defaultValue) : dyData.defaultValue;
76
75
  if (Array.isArray(dyDataList) && dyDataList.length > 0) {
@@ -93,7 +92,6 @@ const _sfc_main = {
93
92
  }
94
93
  });
95
94
  }
96
- console.error(seriesCfg);
97
95
  return {
98
96
  title: props.record.options.titleConfig,
99
97
  tooltip: props.record.options.tooltipConfig,
@@ -152,7 +150,7 @@ const _sfc_main = {
152
150
  };
153
151
  }
154
152
  };
155
- const BarChart = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-7dec52de"]]);
153
+ const BarChart = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-368b9c34"]]);
156
154
  export {
157
155
  BarChart as default
158
156
  };
@@ -4,7 +4,7 @@ import { OrbitControls } from "three/examples/jsm/controls/OrbitControls.js";
4
4
  import { CSS2DRenderer, CSS2DObject } from "three/examples/jsm/renderers/CSS2DRenderer.js";
5
5
  import { Pic1 } from "./sun-card-design-mobile.es32.js";
6
6
  /* empty css */
7
- import _export_sfc from "./sun-card-design-mobile.es28.js";
7
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
8
8
  const _sfc_main = {
9
9
  __name: "barChart3dComp",
10
10
  props: ["record"],
@@ -1,17 +1,16 @@
1
1
  import { useCssVars, computed, ref, onMounted, nextTick, onBeforeUnmount, createElementBlock, openBlock, createElementVNode } from "vue";
2
- import { previewData } from "./sun-card-design-mobile.es26.js";
3
2
  import * as echarts from "echarts";
4
3
  /* empty css */
5
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
6
5
  const _hoisted_1 = { class: "pieChart-table" };
7
6
  const _sfc_main = {
8
7
  __name: "pieChartComp",
9
- props: ["record"],
8
+ props: ["record", "variableList"],
10
9
  setup(__props) {
11
10
  useCssVars((_ctx) => ({
12
- "v05941e7c": mainPadding.value,
13
- "v1ced7cb8": chartWidth.value,
14
- "v25cff909": chartHeight.value
11
+ "d6945370": mainPadding.value,
12
+ "v06ab6058": chartWidth.value,
13
+ "v961c9e56": chartHeight.value
15
14
  }));
16
15
  const props = __props;
17
16
  const mainPadding = computed(() => {
@@ -42,7 +41,7 @@ const _sfc_main = {
42
41
  };
43
42
  const resolveArrayFromVariable = (name) => {
44
43
  if (!name) return [];
45
- const v = (previewData.variableList || []).find((e) => e.name === name);
44
+ const v = (props.variableList || []).find((e) => e.name === name);
46
45
  if (!v || !v.defaultValue) return [];
47
46
  const data = typeof v.defaultValue === "string" ? parseJsonSafe(v.defaultValue) : v.defaultValue;
48
47
  if (!Array.isArray(data)) return [];
@@ -69,7 +68,7 @@ const _sfc_main = {
69
68
  });
70
69
  const seriesCfg = deepClone(props.record.options.seriesConfig || []);
71
70
  seriesCfg.forEach((s) => {
72
- const dyData = typeof s.data === "string" ? (previewData.variableList || []).find((v) => v.name === s.data) : null;
71
+ const dyData = typeof s.data === "string" ? (props.variableList || []).find((v) => v.name === s.data) : null;
73
72
  if (dyData) {
74
73
  const dyDataList = JSON.parse(dyData.defaultValue) || [];
75
74
  s.data = dyDataList;
@@ -130,7 +129,7 @@ const _sfc_main = {
130
129
  };
131
130
  }
132
131
  };
133
- const PieChart = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-b7d21c4e"]]);
132
+ const PieChart = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-9d7b4107"]]);
134
133
  export {
135
134
  PieChart as default
136
135
  };
@@ -4,7 +4,7 @@ import { OrbitControls } from "three/examples/jsm/controls/OrbitControls.js";
4
4
  import { CSS2DRenderer, CSS2DObject } from "three/examples/jsm/renderers/CSS2DRenderer.js";
5
5
  import { Pic1 } from "./sun-card-design-mobile.es32.js";
6
6
  /* empty css */
7
- import _export_sfc from "./sun-card-design-mobile.es28.js";
7
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
8
8
  const _sfc_main = {
9
9
  __name: "pieChart3dComp",
10
10
  props: ["record"],
@@ -1,17 +1,16 @@
1
1
  import { useCssVars, computed, ref, onMounted, nextTick, onBeforeUnmount, watch, createElementBlock, openBlock, createElementVNode } from "vue";
2
- import { previewData } from "./sun-card-design-mobile.es26.js";
3
2
  import * as echarts from "echarts";
4
3
  /* empty css */
5
- import _export_sfc from "./sun-card-design-mobile.es28.js";
4
+ import _export_sfc from "./sun-card-design-mobile.es27.js";
6
5
  const _hoisted_1 = { class: "lineChart-table" };
7
6
  const _sfc_main = {
8
7
  __name: "lineChartComp",
9
- props: ["record"],
8
+ props: ["record", "variableList"],
10
9
  setup(__props) {
11
10
  useCssVars((_ctx) => ({
12
- "v6ebd4fce": mainPadding.value,
13
- "v26a8c3dc": chartWidth.value,
14
- "e20dab4a": chartHeight.value
11
+ "v65be307e": mainPadding.value,
12
+ "v36b3e762": chartWidth.value,
13
+ "f40be9ea": chartHeight.value
15
14
  }));
16
15
  const props = __props;
17
16
  const mainPadding = computed(() => {
@@ -42,7 +41,7 @@ const _sfc_main = {
42
41
  };
43
42
  const resolveArrayFromVariable = (name) => {
44
43
  if (!name) return [];
45
- const v = (previewData.variableList || []).find((e) => e.name === name);
44
+ const v = (props.variableList || []).find((e) => e.name === name);
46
45
  if (!v || !v.defaultValue) return [];
47
46
  const data = typeof v.defaultValue === "string" ? parseJsonSafe(v.defaultValue) : v.defaultValue;
48
47
  if (!Array.isArray(data)) return [];
@@ -70,7 +69,7 @@ const _sfc_main = {
70
69
  const originalSeriesCfg = props.record.options.seriesConfig || [];
71
70
  const seriesCfg = deepClone(originalSeriesCfg);
72
71
  const firstSeriesData = originalSeriesCfg?.[0]?.data;
73
- const dyData = typeof firstSeriesData === "string" ? (previewData.variableList || []).find((v) => v.name === firstSeriesData) : null;
72
+ const dyData = typeof firstSeriesData === "string" ? (props.variableList || []).find((v) => v.name === firstSeriesData) : null;
74
73
  if (dyData) {
75
74
  const dyDataList = typeof dyData.defaultValue === "string" ? parseJsonSafe(dyData.defaultValue) : Array.isArray(dyData.defaultValue) ? dyData.defaultValue : null;
76
75
  if (Array.isArray(dyDataList) && dyDataList.length > 0) {
@@ -164,7 +163,7 @@ const _sfc_main = {
164
163
  props.record.options.xAxisConfig,
165
164
  props.record.options.yAxisConfig,
166
165
  props.record.options.seriesConfig,
167
- previewData.variableList
166
+ props.variableList
168
167
  // 变量发生变化也要重算
169
168
  ],
170
169
  () => {
@@ -185,7 +184,7 @@ const _sfc_main = {
185
184
  };
186
185
  }
187
186
  };
188
- const LineChart = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-98c749fb"]]);
187
+ const LineChart = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-e8c89be8"]]);
189
188
  export {
190
189
  LineChart as default
191
190
  };