ling-yun-custom-components 0.0.63 → 0.0.65

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.
@@ -1,35 +1,35 @@
1
- import { w as x } from "./chunks/index.bCzIhWFw.js";
2
- import { computed as B, createBlock as p, openBlock as t, unref as u, withCtx as M, createElementBlock as n, Fragment as f, renderList as H, normalizeClass as $, toDisplayString as h, createTextVNode as D, ref as g, watch as P, onMounted as z, createCommentVNode as o, createVNode as S, createElementVNode as V, renderSlot as b, nextTick as _ } from "vue";
3
- import { ElTable as R, ElTableColumn as j, ElButton as F, ElSegmented as J } from "element-plus";
4
- import { CustomTitle as v } from "color-star-custom-components";
5
- import { emitsMap as A } from "color-star-custom-methods";
1
+ import { w as $ } from "./chunks/index.bCzIhWFw.js";
2
+ import { computed as T, createBlock as p, openBlock as t, unref as u, withCtx as q, createElementBlock as n, Fragment as g, renderList as z, normalizeClass as O, toDisplayString as C, createTextVNode as B, ref as v, watch as I, onMounted as H, createCommentVNode as o, createVNode as V, createElementVNode as P, renderSlot as k, nextTick as _ } from "vue";
3
+ import { ElTable as R, ElTableColumn as j, ElButton as F, ElSegmented as U, ElInput as J } from "element-plus";
4
+ import { CustomTitle as S } from "color-star-custom-components";
5
+ import { emitsMap as x } from "color-star-custom-methods";
6
6
  import { _ as L } from "./chunks/_plugin-vue_export-helper.CHgC5LLL.js";
7
- import './assets/PluginDetail.css';const k = {
7
+ import './assets/PluginDetail.css';const w = {
8
8
  name: "name",
9
9
  type: "type",
10
10
  required: "required",
11
11
  description: "description"
12
- }, U = [
12
+ }, W = [
13
13
  {
14
14
  label: "参数名",
15
- prop: k.name
15
+ prop: w.name
16
16
  },
17
17
  {
18
18
  label: "参数类型",
19
- prop: k.type
19
+ prop: w.type
20
20
  },
21
21
  {
22
22
  label: "必填",
23
- prop: k.required
23
+ prop: w.required
24
24
  },
25
25
  {
26
26
  label: "描述",
27
- prop: k.description
27
+ prop: w.description
28
28
  }
29
- ], W = {
29
+ ], G = {
30
30
  key: 1,
31
31
  class: "type-tag"
32
- }, O = {
32
+ }, M = {
33
33
  __name: "ParamsTable",
34
34
  props: {
35
35
  data: {
@@ -38,7 +38,7 @@ import './assets/PluginDetail.css';const k = {
38
38
  },
39
39
  columns: {
40
40
  type: Array,
41
- default: () => U
41
+ default: () => W
42
42
  },
43
43
  hideColumns: {
44
44
  type: Array,
@@ -46,36 +46,36 @@ import './assets/PluginDetail.css';const k = {
46
46
  }
47
47
  },
48
48
  setup(a) {
49
- const i = a, T = B(() => {
50
- let r = i.data;
51
- if (typeof r == "string")
49
+ const i = a, A = T(() => {
50
+ let l = i.data;
51
+ if (typeof l == "string")
52
52
  try {
53
- r = JSON.parse(r);
53
+ l = JSON.parse(l);
54
54
  } catch (d) {
55
55
  return console.error("解析参数数据失败:", d), [];
56
56
  }
57
- return !r || !Array.isArray(r) ? [] : r;
58
- }), s = B(() => !i.hideColumns || i.hideColumns.length === 0 ? i.columns : i.columns.filter((r) => !i.hideColumns.includes(r.prop)));
59
- return (r, d) => (t(), p(u(R), {
60
- data: T.value,
57
+ return !l || !Array.isArray(l) ? [] : l;
58
+ }), s = T(() => !i.hideColumns || i.hideColumns.length === 0 ? i.columns : i.columns.filter((l) => !i.hideColumns.includes(l.prop)));
59
+ return (l, d) => (t(), p(u(R), {
60
+ data: A.value,
61
61
  "row-key": "uiid",
62
62
  "tree-props": { children: "children", hasChildren: "hasChildren" },
63
63
  stripe: ""
64
64
  }, {
65
- default: M(() => [
66
- (t(!0), n(f, null, H(s.value, (l) => (t(), p(u(j), {
67
- key: l.prop,
68
- prop: l.prop,
69
- label: l.label,
70
- width: l.width,
71
- "min-width": l.minWidth
65
+ default: q(() => [
66
+ (t(!0), n(g, null, z(s.value, (r) => (t(), p(u(j), {
67
+ key: r.prop,
68
+ prop: r.prop,
69
+ label: r.label,
70
+ width: r.width,
71
+ "min-width": r.minWidth
72
72
  }, {
73
- default: M(({ row: m }) => [
74
- l.prop === "required" ? (t(), n("span", {
73
+ default: q(({ row: m }) => [
74
+ r.prop === "required" ? (t(), n("span", {
75
75
  key: 0,
76
- class: $(m.required ? "required-yes" : "required-no")
77
- }, h(m.required ? "是" : "否"), 3)) : l.prop === "type" ? (t(), n("span", W, h(m.type), 1)) : (t(), n(f, { key: 2 }, [
78
- D(h(m[l.prop] || "-"), 1)
76
+ class: O(m.required ? "required-yes" : "required-no")
77
+ }, C(m.required ? "是" : "否"), 3)) : r.prop === "type" ? (t(), n("span", G, C(m.type), 1)) : (t(), n(g, { key: 2 }, [
78
+ B(C(m[r.prop] || "-"), 1)
79
79
  ], 64))
80
80
  ]),
81
81
  _: 2
@@ -84,10 +84,10 @@ import './assets/PluginDetail.css';const k = {
84
84
  _: 1
85
85
  }, 8, ["data"]));
86
86
  }
87
- }, G = { key: 0 }, K = { key: 1 }, Q = {
88
- key: 4,
87
+ }, K = { key: 0 }, Q = { key: 1 }, X = { class: "weight-400 fz-16 text-666" }, Y = {
88
+ key: 3,
89
89
  class: "radius-12 border-f0f0f0 pd-l-20 pd-r-20 pd-b-24 pd-t-20 mg-b-34"
90
- }, X = { class: "weight-400 fz-16 text-666666 lh-24" }, Y = { class: "flex justify-end items-center gap-10 text-right" }, Z = /* @__PURE__ */ Object.assign({
90
+ }, Z = { class: "weight-400 fz-16 text-666666 lh-24" }, ee = { class: "flex justify-end items-center gap-10 text-right" }, te = /* @__PURE__ */ Object.assign({
91
91
  name: "PluginDetail"
92
92
  }, {
93
93
  __name: "layout",
@@ -132,7 +132,7 @@ import './assets/PluginDetail.css';const k = {
132
132
  // 输出参数隐藏的列
133
133
  outputParamsHideColumns: {
134
134
  type: Array,
135
- default: () => [k.required]
135
+ default: () => [w.required]
136
136
  },
137
137
  // 是否 显示 插件简介
138
138
  showIntro: {
@@ -140,141 +140,140 @@ import './assets/PluginDetail.css';const k = {
140
140
  default: !0
141
141
  }
142
142
  },
143
- emits: [A.updateModelValue, A.tabChange],
144
- setup(a, { expose: i, emit: T }) {
145
- const s = a, r = T, d = g(!1), l = g(!1), m = g(null), c = g(s.modelValue), C = B(() => !s.tabItems?.length || !c.value ? null : s.tabItems.find((e) => e.bnid == c.value) || null), N = () => {
143
+ emits: [x.updateModelValue, x.tabChange],
144
+ setup(a, { expose: i, emit: A }) {
145
+ const s = a, l = A, d = v(!1), r = v(!1), m = v(null), c = v(s.modelValue), h = T(() => !s.tabItems?.length || !c.value ? null : s.tabItems.find((e) => e.bnid == c.value) || null), E = () => {
146
146
  d.value = !d.value;
147
- }, E = (e) => {
148
- r(A.updateModelValue, e), r(A.tabChange, e);
149
- }, q = () => {
147
+ }, N = (e) => {
148
+ l(x.updateModelValue, e), l(x.tabChange, e);
149
+ }, D = () => {
150
150
  _(() => {
151
151
  const e = m.value;
152
- e && (l.value = e.scrollHeight > 24);
152
+ e && (r.value = e.scrollHeight > 24);
153
153
  });
154
- }, y = g(null);
155
- return P(
156
- () => C.value?.bnid,
154
+ }, b = v(null);
155
+ return I(
156
+ () => h.value?.bnid,
157
157
  (e) => {
158
- e && s.pluginDetailApi(e).then((w) => {
159
- y.value = w?.data?.[0];
158
+ e && s.pluginDetailApi(e).then((f) => {
159
+ b.value = f?.data?.[0];
160
160
  });
161
161
  },
162
162
  { immediate: !0 }
163
- ), P(
163
+ ), I(
164
164
  () => s.modelValue,
165
165
  (e) => {
166
166
  c.value = e;
167
167
  }
168
- ), P(
168
+ ), I(
169
169
  () => s.tabItems,
170
170
  (e) => {
171
171
  c.value = e?.[0]?.bnid;
172
172
  },
173
173
  { immediate: !0 }
174
- ), P(
174
+ ), I(
175
175
  () => s.description,
176
176
  () => {
177
- q();
177
+ D();
178
178
  },
179
179
  { immediate: !0 }
180
- ), z(() => {
181
- q();
180
+ ), H(() => {
181
+ D();
182
182
  }), i({
183
- checkShowMoreBtn: q,
184
- currentTabItem: C
185
- }), (e, w) => (t(), n(f, null, [
186
- a.showIntro ? (t(), n(f, { key: 0 }, [
187
- S(u(v), {
183
+ checkShowMoreBtn: D,
184
+ currentTabItem: h
185
+ }), (e, f) => (t(), n(g, null, [
186
+ a.showIntro ? (t(), n(g, { key: 0 }, [
187
+ V(u(S), {
188
188
  content: "插件简介",
189
189
  class: "mg-b-16"
190
190
  }),
191
- V("div", {
192
- class: $(["weight-400 fz-16 text-666", d.value ? "" : "hide-more"]),
191
+ P("div", {
192
+ class: O(["weight-400 fz-16 text-666", d.value ? "" : "hide-more"]),
193
193
  ref_key: "descRef",
194
194
  ref: m
195
195
  }, [
196
- b(e.$slots, "intro", {}, () => [
197
- D(h(a.intro), 1)
196
+ k(e.$slots, "intro", {}, () => [
197
+ B(C(a.intro), 1)
198
198
  ], !0)
199
199
  ], 2)
200
200
  ], 64)) : o("", !0),
201
- S(u(v), {
202
- content: "工具描述",
203
- class: "mg-b-16 mg-t-34"
204
- }),
205
- V("div", {
206
- class: $(["weight-400 fz-16 text-666", d.value ? "" : "hide-more"]),
207
- ref_key: "descRef",
208
- ref: m
209
- }, [
210
- b(e.$slots, "description", {}, () => [
211
- D(h(C.value?.description), 1)
212
- ], !0)
213
- ], 2),
214
- l.value ? (t(), p(u(F), {
201
+ r.value ? (t(), p(u(F), {
215
202
  key: 1,
216
203
  type: "text",
217
- onClick: N
204
+ onClick: E
218
205
  }, {
219
- default: M(() => [
220
- d.value ? (t(), n("span", K, "收起")) : (t(), n("span", G, "查看更多"))
206
+ default: q(() => [
207
+ d.value ? (t(), n("span", Q, "收起")) : (t(), n("span", K, "查看更多"))
221
208
  ]),
222
209
  _: 1
223
210
  })) : o("", !0),
224
- a.tabItems?.length ? (t(), p(u(v), {
211
+ a.tabItems?.length ? (t(), p(u(U), {
225
212
  key: 2,
226
- content: "插件工具",
227
- class: "mg-b-16 mg-t-34"
228
- })) : o("", !0),
229
- a.tabItems?.length ? (t(), p(u(J), {
230
- key: 3,
231
213
  modelValue: c.value,
232
- "onUpdate:modelValue": w[0] || (w[0] = (I) => c.value = I),
233
- options: a.tabItems.map((I) => ({
234
- label: I.interfaceName,
235
- value: I.bnid
214
+ "onUpdate:modelValue": f[0] || (f[0] = (y) => c.value = y),
215
+ options: a.tabItems.map((y) => ({
216
+ label: y.interfaceName,
217
+ value: y.bnid
236
218
  })),
237
- onChange: E,
238
- class: "mg-b-16"
219
+ onChange: N,
220
+ class: "mg-b-16 mg-t-34"
239
221
  }, null, 8, ["modelValue", "options"])) : o("", !0),
240
- e.$slots.default || e.$slots.actions ? (t(), n("div", Q, [
241
- V("div", X, [
242
- b(e.$slots, "default", {}, () => [
243
- D(h(C.value?.description), 1)
222
+ V(u(S), {
223
+ content: "工具描述",
224
+ class: "mg-b-16"
225
+ }),
226
+ P("div", X, [
227
+ k(e.$slots, "description", {}, () => [
228
+ h.value ? (t(), p(u(J), {
229
+ key: 0,
230
+ type: "textarea",
231
+ modelValue: h.value.description,
232
+ "onUpdate:modelValue": f[1] || (f[1] = (y) => h.value.description = y),
233
+ autosize: { minRows: 1, maxRows: 3 },
234
+ maxlength: 300,
235
+ "show-word-limit": !0
236
+ }, null, 8, ["modelValue"])) : o("", !0)
237
+ ], !0)
238
+ ]),
239
+ e.$slots.default || e.$slots.actions ? (t(), n("div", Y, [
240
+ P("div", Z, [
241
+ k(e.$slots, "default", {}, () => [
242
+ B(C(h.value?.description), 1)
244
243
  ], !0)
245
244
  ]),
246
- V("div", Y, [
247
- b(e.$slots, "actions", {}, void 0, !0)
245
+ P("div", ee, [
246
+ k(e.$slots, "actions", {}, void 0, !0)
248
247
  ])
249
248
  ])) : o("", !0),
250
- a.showInputParams && a.tabItems?.length ? (t(), n(f, { key: 5 }, [
251
- S(u(v), {
249
+ a.showInputParams && a.tabItems?.length ? (t(), n(g, { key: 4 }, [
250
+ V(u(S), {
252
251
  content: "输入参数",
253
- class: "mg-b-16"
252
+ class: "mg-b-16 mg-t-34"
254
253
  }),
255
- y.value?.paramsOuter ? (t(), p(O, {
254
+ b.value?.paramsOuter ? (t(), p(M, {
256
255
  key: 0,
257
- data: y.value.paramsOuter,
256
+ data: b.value.paramsOuter,
258
257
  "hide-columns": a.inputParamsHideColumns
259
258
  }, null, 8, ["data", "hide-columns"])) : o("", !0)
260
259
  ], 64)) : o("", !0),
261
- a.showOutputParams && a.tabItems?.length ? (t(), n(f, { key: 6 }, [
262
- S(u(v), {
260
+ a.showOutputParams && a.tabItems?.length ? (t(), n(g, { key: 5 }, [
261
+ V(u(S), {
263
262
  content: "输出参数",
264
263
  class: "mg-b-16 mg-t-34"
265
264
  }),
266
- y.value?.responseOuter ? (t(), p(O, {
265
+ b.value?.responseOuter ? (t(), p(M, {
267
266
  key: 0,
268
- data: y.value.responseOuter,
267
+ data: b.value.responseOuter,
269
268
  "hide-columns": a.outputParamsHideColumns
270
269
  }, null, 8, ["data", "hide-columns"])) : o("", !0)
271
270
  ], 64)) : o("", !0),
272
- b(e.$slots, "plugin-detail", {}, void 0, !0)
271
+ k(e.$slots, "plugin-detail", {}, void 0, !0)
273
272
  ], 64));
274
273
  }
275
- }), ee = /* @__PURE__ */ L(Z, [["__scopeId", "data-v-b8ced588"]]), oe = x(ee), ue = x(O);
274
+ }), ae = /* @__PURE__ */ L(te, [["__scopeId", "data-v-c90740ac"]]), ie = $(ae), de = $(M);
276
275
  export {
277
- oe as PluginDetail,
278
- ue as PluginDetailParamsTable,
279
- oe as default
276
+ ie as PluginDetail,
277
+ de as PluginDetailParamsTable,
278
+ ie as default
280
279
  };
@@ -1 +1 @@
1
- .hide-more[data-v-b8ced588]{display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden}.border-f0f0f0[data-v-b8ced588]{border:1px solid var(--neutral-color-6)}
1
+ .hide-more[data-v-c90740ac]{display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden}.border-f0f0f0[data-v-c90740ac]{border:1px solid var(--neutral-color-6)}
package/es/index.mjs CHANGED
@@ -1,59 +1,85 @@
1
- import { AppIntro as m } from "./AppIntro.mjs";
2
- import { PaginationTable as i } from "./PaginationTable.mjs";
3
- import { GradientButton as n } from "./GradientButton.mjs";
4
- import { CustomDialog as e } from "./CustomDialog.mjs";
1
+ import { AppIntro as r } from "./AppIntro.mjs";
2
+ import { PaginationTable as m } from "./PaginationTable.mjs";
3
+ import { GradientButton as i } from "./GradientButton.mjs";
4
+ import { CustomDialog as l } from "./CustomDialog.mjs";
5
5
  import { CustomPagination as a } from "./CustomPagination.mjs";
6
- import { CustomDropdown as p } from "./CustomDropdown.mjs";
7
- import { PageNotFound as l } from "./PageNotFound.mjs";
6
+ import { CustomDropdown as n } from "./CustomDropdown.mjs";
7
+ import { PageNotFound as p } from "./PageNotFound.mjs";
8
8
  import { UpdatePasswordDialog as s } from "./UpdatePasswordDialog.mjs";
9
- import { BUILD_BIG_TITLES as f, BUILD_STEPS as u, BUILD_TITLES as d, BUILD_TYPES as P, BuildComponents as T, STEP_ARROW_IMAGE as _ } from "./BuildComponents.mjs";
10
- import { CustomTab as g } from "./CustomTab.mjs";
11
- import { PluginDetail as D, PluginDetailParamsTable as I } from "./PluginDetail.mjs";
12
- import { dayjs as S } from "element-plus";
9
+ import { BUILD_BIG_TITLES as c, BUILD_STEPS as S, BUILD_TITLES as f, BUILD_TYPES as u, BuildComponents as I, STEP_ARROW_IMAGE as T } from "./BuildComponents.mjs";
10
+ import { CustomTab as d } from "./CustomTab.mjs";
11
+ import { PluginDetail as P, PluginDetailParamsTable as B } from "./PluginDetail.mjs";
12
+ import { BatchImport as _, CustomSelect as g, CustomTitle as C, FileList as D, GlassProxy as E, IconEmpty as L, IconRenderer as y, IconSelect as U, SearchBar as b, TreeSelect as h, TreeShowSelect as w, UploadFile as x } from "color-star-custom-components";
13
+ import { BatchImport as V, CustomSelect as X, CustomTitle as Z, FileList as $, GlassProxy as oo, IconEmpty as to, IconRenderer as eo, IconSelect as ro, SearchBar as mo, TreeSelect as io, TreeShowSelect as lo, UploadFile as ao } from "color-star-custom-components";
14
+ import { dayjs as F } from "element-plus";
13
15
  const o = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14
16
  __proto__: null,
15
- AppIntro: m,
16
- BUILD_BIG_TITLES: f,
17
- BUILD_STEPS: u,
18
- BUILD_TITLES: d,
19
- BUILD_TYPES: P,
20
- BuildComponents: T,
21
- CustomDialog: e,
22
- CustomDropdown: p,
17
+ AppIntro: r,
18
+ BUILD_BIG_TITLES: c,
19
+ BUILD_STEPS: S,
20
+ BUILD_TITLES: f,
21
+ BUILD_TYPES: u,
22
+ BatchImport: _,
23
+ BuildComponents: I,
24
+ CustomDialog: l,
25
+ CustomDropdown: n,
23
26
  CustomPagination: a,
24
- CustomTab: g,
25
- GradientButton: n,
26
- PageNotFound: l,
27
- PaginationTable: i,
28
- PluginDetail: D,
29
- PluginDetailParamsTable: I,
30
- STEP_ARROW_IMAGE: _,
31
- UpdatePasswordDialog: s
27
+ CustomSelect: g,
28
+ CustomTab: d,
29
+ CustomTitle: C,
30
+ FileList: D,
31
+ GlassProxy: E,
32
+ GradientButton: i,
33
+ IconEmpty: L,
34
+ IconRenderer: y,
35
+ IconSelect: U,
36
+ PageNotFound: p,
37
+ PaginationTable: m,
38
+ PluginDetail: P,
39
+ PluginDetailParamsTable: B,
40
+ STEP_ARROW_IMAGE: T,
41
+ SearchBar: b,
42
+ TreeSelect: h,
43
+ TreeShowSelect: w,
44
+ UpdatePasswordDialog: s,
45
+ UploadFile: x
32
46
  }, Symbol.toStringTag, { value: "Module" }));
33
- S.en.weekStart = 1;
34
- const c = (r) => {
47
+ F.en.weekStart = 1;
48
+ const G = (e) => {
35
49
  for (const t in o)
36
- o[t].install && r.use(o[t]);
37
- }, x = {
38
- install: c
50
+ o[t].install && e.use(o[t]);
51
+ }, J = {
52
+ install: G
39
53
  };
40
54
  export {
41
- m as AppIntro,
42
- f as BUILD_BIG_TITLES,
43
- u as BUILD_STEPS,
44
- d as BUILD_TITLES,
45
- P as BUILD_TYPES,
46
- T as BuildComponents,
47
- e as CustomDialog,
48
- p as CustomDropdown,
55
+ r as AppIntro,
56
+ c as BUILD_BIG_TITLES,
57
+ S as BUILD_STEPS,
58
+ f as BUILD_TITLES,
59
+ u as BUILD_TYPES,
60
+ V as BatchImport,
61
+ I as BuildComponents,
62
+ l as CustomDialog,
63
+ n as CustomDropdown,
49
64
  a as CustomPagination,
50
- g as CustomTab,
51
- n as GradientButton,
52
- l as PageNotFound,
53
- i as PaginationTable,
54
- D as PluginDetail,
55
- I as PluginDetailParamsTable,
56
- _ as STEP_ARROW_IMAGE,
65
+ X as CustomSelect,
66
+ d as CustomTab,
67
+ Z as CustomTitle,
68
+ $ as FileList,
69
+ oo as GlassProxy,
70
+ i as GradientButton,
71
+ to as IconEmpty,
72
+ eo as IconRenderer,
73
+ ro as IconSelect,
74
+ p as PageNotFound,
75
+ m as PaginationTable,
76
+ P as PluginDetail,
77
+ B as PluginDetailParamsTable,
78
+ T as STEP_ARROW_IMAGE,
79
+ mo as SearchBar,
80
+ io as TreeSelect,
81
+ lo as TreeShowSelect,
57
82
  s as UpdatePasswordDialog,
58
- x as default
83
+ ao as UploadFile,
84
+ J as default
59
85
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});require('./assets/PluginDetail.css');const C=require("./chunks/index.CkihWzK6.js"),e=require("vue"),y=require("element-plus"),d=require("color-star-custom-components"),g=require("color-star-custom-methods"),N=require("./chunks/_plugin-vue_export-helper.BHFhmbuH.js"),m={name:"name",type:"type",required:"required",description:"description"},S=[{label:"参数名",prop:m.name},{label:"参数类型",prop:m.type},{label:"必填",prop:m.required},{label:"描述",prop:m.description}],E={key:1,class:"type-tag"},B={__name:"ParamsTable",props:{data:{type:[Array,String],default:()=>[]},columns:{type:Array,default:()=>S},hideColumns:{type:Array,default:()=>[]}},setup(a){const n=a,k=e.computed(()=>{let l=n.data;if(typeof l=="string")try{l=JSON.parse(l)}catch(s){return console.error("解析参数数据失败:",s),[]}return!l||!Array.isArray(l)?[]:l}),r=e.computed(()=>!n.hideColumns||n.hideColumns.length===0?n.columns:n.columns.filter(l=>!n.hideColumns.includes(l.prop)));return(l,s)=>(e.openBlock(),e.createBlock(e.unref(y.ElTable),{data:k.value,"row-key":"uiid","tree-props":{children:"children",hasChildren:"hasChildren"},stripe:""},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,o=>(e.openBlock(),e.createBlock(e.unref(y.ElTableColumn),{key:o.prop,prop:o.prop,label:o.label,width:o.width,"min-width":o.minWidth},{default:e.withCtx(({row:u})=>[o.prop==="required"?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(u.required?"required-yes":"required-no")},e.toDisplayString(u.required?"是":"否"),3)):o.prop==="type"?(e.openBlock(),e.createElementBlock("span",E,e.toDisplayString(u.type),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(u[o.prop]||"-"),1)],64))]),_:2},1032,["prop","label","width","min-width"]))),128))]),_:1},8,["data"]))}},T={key:0},P={key:1},D={key:4,class:"radius-12 border-f0f0f0 pd-l-20 pd-r-20 pd-b-24 pd-t-20 mg-b-34"},I={class:"weight-400 fz-16 text-666666 lh-24"},q={class:"flex justify-end items-center gap-10 text-right"},M=Object.assign({name:"PluginDetail"},{__name:"layout",props:{intro:{type:String,default:""},description:{type:String,default:""},modelValue:{type:[String,Number],default:""},tabItems:{type:Array,default:()=>[]},pluginDetailApi:{type:Function,default:()=>{}},showInputParams:{type:Boolean,default:!0},showOutputParams:{type:Boolean,default:!0},inputParamsHideColumns:{type:Array,default:()=>[]},outputParamsHideColumns:{type:Array,default:()=>[m.required]},showIntro:{type:Boolean,default:!0}},emits:[g.emitsMap.updateModelValue,g.emitsMap.tabChange],setup(a,{expose:n,emit:k}){const r=a,l=k,s=e.ref(!1),o=e.ref(!1),u=e.ref(null),i=e.ref(r.modelValue),p=e.computed(()=>!r.tabItems?.length||!i.value?null:r.tabItems.find(t=>t.bnid==i.value)||null),V=()=>{s.value=!s.value},w=t=>{l(g.emitsMap.updateModelValue,t),l(g.emitsMap.tabChange,t)},b=()=>{e.nextTick(()=>{const t=u.value;t&&(o.value=t.scrollHeight>24)})},c=e.ref(null);return e.watch(()=>p.value?.bnid,t=>{t&&r.pluginDetailApi(t).then(f=>{c.value=f?.data?.[0]})},{immediate:!0}),e.watch(()=>r.modelValue,t=>{i.value=t}),e.watch(()=>r.tabItems,t=>{i.value=t?.[0]?.bnid},{immediate:!0}),e.watch(()=>r.description,()=>{b()},{immediate:!0}),e.onMounted(()=>{b()}),n({checkShowMoreBtn:b,currentTabItem:p}),(t,f)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[a.showIntro?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(e.unref(d.CustomTitle),{content:"插件简介",class:"mg-b-16"}),e.createElementVNode("div",{class:e.normalizeClass(["weight-400 fz-16 text-666",s.value?"":"hide-more"]),ref_key:"descRef",ref:u},[e.renderSlot(t.$slots,"intro",{},()=>[e.createTextVNode(e.toDisplayString(a.intro),1)],!0)],2)],64)):e.createCommentVNode("",!0),e.createVNode(e.unref(d.CustomTitle),{content:"工具描述",class:"mg-b-16 mg-t-34"}),e.createElementVNode("div",{class:e.normalizeClass(["weight-400 fz-16 text-666",s.value?"":"hide-more"]),ref_key:"descRef",ref:u},[e.renderSlot(t.$slots,"description",{},()=>[e.createTextVNode(e.toDisplayString(p.value?.description),1)],!0)],2),o.value?(e.openBlock(),e.createBlock(e.unref(y.ElButton),{key:1,type:"text",onClick:V},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("span",P,"收起")):(e.openBlock(),e.createElementBlock("span",T,"查看更多"))]),_:1})):e.createCommentVNode("",!0),a.tabItems?.length?(e.openBlock(),e.createBlock(e.unref(d.CustomTitle),{key:2,content:"插件工具",class:"mg-b-16 mg-t-34"})):e.createCommentVNode("",!0),a.tabItems?.length?(e.openBlock(),e.createBlock(e.unref(y.ElSegmented),{key:3,modelValue:i.value,"onUpdate:modelValue":f[0]||(f[0]=h=>i.value=h),options:a.tabItems.map(h=>({label:h.interfaceName,value:h.bnid})),onChange:w,class:"mg-b-16"},null,8,["modelValue","options"])):e.createCommentVNode("",!0),t.$slots.default||t.$slots.actions?(e.openBlock(),e.createElementBlock("div",D,[e.createElementVNode("div",I,[e.renderSlot(t.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(p.value?.description),1)],!0)]),e.createElementVNode("div",q,[e.renderSlot(t.$slots,"actions",{},void 0,!0)])])):e.createCommentVNode("",!0),a.showInputParams&&a.tabItems?.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[e.createVNode(e.unref(d.CustomTitle),{content:"输入参数",class:"mg-b-16"}),c.value?.paramsOuter?(e.openBlock(),e.createBlock(B,{key:0,data:c.value.paramsOuter,"hide-columns":a.inputParamsHideColumns},null,8,["data","hide-columns"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),a.showOutputParams&&a.tabItems?.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:6},[e.createVNode(e.unref(d.CustomTitle),{content:"输出参数",class:"mg-b-16 mg-t-34"}),c.value?.responseOuter?(e.openBlock(),e.createBlock(B,{key:0,data:c.value.responseOuter,"hide-columns":a.outputParamsHideColumns},null,8,["data","hide-columns"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"plugin-detail",{},void 0,!0)],64))}}),x=N._export_sfc(M,[["__scopeId","data-v-b8ced588"]]),v=C.withInstall(x),A=C.withInstall(B);exports.PluginDetail=v;exports.PluginDetailParamsTable=A;exports.default=v;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});require('./assets/PluginDetail.css');const C=require("./chunks/index.CkihWzK6.js"),e=require("vue"),f=require("element-plus"),g=require("color-star-custom-components"),y=require("color-star-custom-methods"),N=require("./chunks/_plugin-vue_export-helper.BHFhmbuH.js"),h={name:"name",type:"type",required:"required",description:"description"},S=[{label:"参数名",prop:h.name},{label:"参数类型",prop:h.type},{label:"必填",prop:h.required},{label:"描述",prop:h.description}],E={key:1,class:"type-tag"},B={__name:"ParamsTable",props:{data:{type:[Array,String],default:()=>[]},columns:{type:Array,default:()=>S},hideColumns:{type:Array,default:()=>[]}},setup(a){const n=a,k=e.computed(()=>{let l=n.data;if(typeof l=="string")try{l=JSON.parse(l)}catch(s){return console.error("解析参数数据失败:",s),[]}return!l||!Array.isArray(l)?[]:l}),r=e.computed(()=>!n.hideColumns||n.hideColumns.length===0?n.columns:n.columns.filter(l=>!n.hideColumns.includes(l.prop)));return(l,s)=>(e.openBlock(),e.createBlock(e.unref(f.ElTable),{data:k.value,"row-key":"uiid","tree-props":{children:"children",hasChildren:"hasChildren"},stripe:""},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,o=>(e.openBlock(),e.createBlock(e.unref(f.ElTableColumn),{key:o.prop,prop:o.prop,label:o.label,width:o.width,"min-width":o.minWidth},{default:e.withCtx(({row:u})=>[o.prop==="required"?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(u.required?"required-yes":"required-no")},e.toDisplayString(u.required?"是":"否"),3)):o.prop==="type"?(e.openBlock(),e.createElementBlock("span",E,e.toDisplayString(u.type),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(u[o.prop]||"-"),1)],64))]),_:2},1032,["prop","label","width","min-width"]))),128))]),_:1},8,["data"]))}},P={key:0},I={key:1},T={class:"weight-400 fz-16 text-666"},D={key:3,class:"radius-12 border-f0f0f0 pd-l-20 pd-r-20 pd-b-24 pd-t-20 mg-b-34"},q={class:"weight-400 fz-16 text-666666 lh-24"},x={class:"flex justify-end items-center gap-10 text-right"},M=Object.assign({name:"PluginDetail"},{__name:"layout",props:{intro:{type:String,default:""},description:{type:String,default:""},modelValue:{type:[String,Number],default:""},tabItems:{type:Array,default:()=>[]},pluginDetailApi:{type:Function,default:()=>{}},showInputParams:{type:Boolean,default:!0},showOutputParams:{type:Boolean,default:!0},inputParamsHideColumns:{type:Array,default:()=>[]},outputParamsHideColumns:{type:Array,default:()=>[h.required]},showIntro:{type:Boolean,default:!0}},emits:[y.emitsMap.updateModelValue,y.emitsMap.tabChange],setup(a,{expose:n,emit:k}){const r=a,l=k,s=e.ref(!1),o=e.ref(!1),u=e.ref(null),i=e.ref(r.modelValue),c=e.computed(()=>!r.tabItems?.length||!i.value?null:r.tabItems.find(t=>t.bnid==i.value)||null),V=()=>{s.value=!s.value},w=t=>{l(y.emitsMap.updateModelValue,t),l(y.emitsMap.tabChange,t)},b=()=>{e.nextTick(()=>{const t=u.value;t&&(o.value=t.scrollHeight>24)})},p=e.ref(null);return e.watch(()=>c.value?.bnid,t=>{t&&r.pluginDetailApi(t).then(d=>{p.value=d?.data?.[0]})},{immediate:!0}),e.watch(()=>r.modelValue,t=>{i.value=t}),e.watch(()=>r.tabItems,t=>{i.value=t?.[0]?.bnid},{immediate:!0}),e.watch(()=>r.description,()=>{b()},{immediate:!0}),e.onMounted(()=>{b()}),n({checkShowMoreBtn:b,currentTabItem:c}),(t,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[a.showIntro?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(e.unref(g.CustomTitle),{content:"插件简介",class:"mg-b-16"}),e.createElementVNode("div",{class:e.normalizeClass(["weight-400 fz-16 text-666",s.value?"":"hide-more"]),ref_key:"descRef",ref:u},[e.renderSlot(t.$slots,"intro",{},()=>[e.createTextVNode(e.toDisplayString(a.intro),1)],!0)],2)],64)):e.createCommentVNode("",!0),o.value?(e.openBlock(),e.createBlock(e.unref(f.ElButton),{key:1,type:"text",onClick:V},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("span",I,"收起")):(e.openBlock(),e.createElementBlock("span",P,"查看更多"))]),_:1})):e.createCommentVNode("",!0),a.tabItems?.length?(e.openBlock(),e.createBlock(e.unref(f.ElSegmented),{key:2,modelValue:i.value,"onUpdate:modelValue":d[0]||(d[0]=m=>i.value=m),options:a.tabItems.map(m=>({label:m.interfaceName,value:m.bnid})),onChange:w,class:"mg-b-16 mg-t-34"},null,8,["modelValue","options"])):e.createCommentVNode("",!0),e.createVNode(e.unref(g.CustomTitle),{content:"工具描述",class:"mg-b-16"}),e.createElementVNode("div",T,[e.renderSlot(t.$slots,"description",{},()=>[c.value?(e.openBlock(),e.createBlock(e.unref(f.ElInput),{key:0,type:"textarea",modelValue:c.value.description,"onUpdate:modelValue":d[1]||(d[1]=m=>c.value.description=m),autosize:{minRows:1,maxRows:3},maxlength:300,"show-word-limit":!0},null,8,["modelValue"])):e.createCommentVNode("",!0)],!0)]),t.$slots.default||t.$slots.actions?(e.openBlock(),e.createElementBlock("div",D,[e.createElementVNode("div",q,[e.renderSlot(t.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(c.value?.description),1)],!0)]),e.createElementVNode("div",x,[e.renderSlot(t.$slots,"actions",{},void 0,!0)])])):e.createCommentVNode("",!0),a.showInputParams&&a.tabItems?.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createVNode(e.unref(g.CustomTitle),{content:"输入参数",class:"mg-b-16 mg-t-34"}),p.value?.paramsOuter?(e.openBlock(),e.createBlock(B,{key:0,data:p.value.paramsOuter,"hide-columns":a.inputParamsHideColumns},null,8,["data","hide-columns"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),a.showOutputParams&&a.tabItems?.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[e.createVNode(e.unref(g.CustomTitle),{content:"输出参数",class:"mg-b-16 mg-t-34"}),p.value?.responseOuter?(e.openBlock(),e.createBlock(B,{key:0,data:p.value.responseOuter,"hide-columns":a.outputParamsHideColumns},null,8,["data","hide-columns"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"plugin-detail",{},void 0,!0)],64))}}),A=N._export_sfc(M,[["__scopeId","data-v-c90740ac"]]),v=C.withInstall(A),O=C.withInstall(B);exports.PluginDetail=v;exports.PluginDetailParamsTable=O;exports.default=v;
@@ -1 +1 @@
1
- .hide-more[data-v-b8ced588]{display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden}.border-f0f0f0[data-v-b8ced588]{border:1px solid var(--neutral-color-6)}
1
+ .hide-more[data-v-c90740ac]{display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden}.border-f0f0f0[data-v-c90740ac]{border:1px solid var(--neutral-color-6)}
package/lib/index.js CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const a=require("./AppIntro.js"),i=require("./PaginationTable.js"),u=require("./GradientButton.js"),s=require("./CustomDialog.js"),r=require("./CustomPagination.js"),l=require("./CustomDropdown.js"),P=require("./PageNotFound.js"),T=require("./UpdatePasswordDialog.js"),o=require("./BuildComponents.js"),D=require("./CustomTab.js"),t=require("./PluginDetail.js"),g=require("element-plus"),e=Object.freeze(Object.defineProperty({__proto__:null,AppIntro:a.AppIntro,BUILD_BIG_TITLES:o.BUILD_BIG_TITLES,BUILD_STEPS:o.BUILD_STEPS,BUILD_TITLES:o.BUILD_TITLES,BUILD_TYPES:o.BUILD_TYPES,BuildComponents:o.BuildComponents,CustomDialog:s.CustomDialog,CustomDropdown:l.CustomDropdown,CustomPagination:r.CustomPagination,CustomTab:D.CustomTab,GradientButton:u.GradientButton,PageNotFound:P.PageNotFound,PaginationTable:i.PaginationTable,PluginDetail:t.PluginDetail,PluginDetailParamsTable:t.PluginDetailParamsTable,STEP_ARROW_IMAGE:o.STEP_ARROW_IMAGE,UpdatePasswordDialog:T.UpdatePasswordDialog},Symbol.toStringTag,{value:"Module"}));g.dayjs.en.weekStart=1;const I=d=>{for(const n in e)e[n].install&&d.use(e[n])},_={install:I};exports.AppIntro=a.AppIntro;exports.PaginationTable=i.PaginationTable;exports.GradientButton=u.GradientButton;exports.CustomDialog=s.CustomDialog;exports.CustomPagination=r.CustomPagination;exports.CustomDropdown=l.CustomDropdown;exports.PageNotFound=P.PageNotFound;exports.UpdatePasswordDialog=T.UpdatePasswordDialog;exports.BUILD_BIG_TITLES=o.BUILD_BIG_TITLES;exports.BUILD_STEPS=o.BUILD_STEPS;exports.BUILD_TITLES=o.BUILD_TITLES;exports.BUILD_TYPES=o.BUILD_TYPES;exports.BuildComponents=o.BuildComponents;exports.STEP_ARROW_IMAGE=o.STEP_ARROW_IMAGE;exports.CustomTab=D.CustomTab;exports.PluginDetail=t.PluginDetail;exports.PluginDetailParamsTable=t.PluginDetailParamsTable;exports.default=_;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const a=require("./AppIntro.js"),i=require("./PaginationTable.js"),l=require("./GradientButton.js"),u=require("./CustomDialog.js"),s=require("./CustomPagination.js"),c=require("./CustomDropdown.js"),P=require("./PageNotFound.js"),m=require("./UpdatePasswordDialog.js"),t=require("./BuildComponents.js"),d=require("./CustomTab.js"),o=require("./PluginDetail.js"),e=require("color-star-custom-components"),p=require("element-plus"),r=Object.freeze(Object.defineProperty({__proto__:null,AppIntro:a.AppIntro,BUILD_BIG_TITLES:t.BUILD_BIG_TITLES,BUILD_STEPS:t.BUILD_STEPS,BUILD_TITLES:t.BUILD_TITLES,BUILD_TYPES:t.BUILD_TYPES,BatchImport:e.BatchImport,BuildComponents:t.BuildComponents,CustomDialog:u.CustomDialog,CustomDropdown:c.CustomDropdown,CustomPagination:s.CustomPagination,CustomSelect:e.CustomSelect,CustomTab:d.CustomTab,CustomTitle:e.CustomTitle,FileList:e.FileList,GlassProxy:e.GlassProxy,GradientButton:l.GradientButton,IconEmpty:e.IconEmpty,IconRenderer:e.IconRenderer,IconSelect:e.IconSelect,PageNotFound:P.PageNotFound,PaginationTable:i.PaginationTable,PluginDetail:o.PluginDetail,PluginDetailParamsTable:o.PluginDetailParamsTable,STEP_ARROW_IMAGE:t.STEP_ARROW_IMAGE,SearchBar:e.SearchBar,TreeSelect:e.TreeSelect,TreeShowSelect:e.TreeShowSelect,UpdatePasswordDialog:m.UpdatePasswordDialog,UploadFile:e.UploadFile},Symbol.toStringTag,{value:"Module"}));p.dayjs.en.weekStart=1;const S=T=>{for(const n in r)r[n].install&&T.use(r[n])},I={install:S};exports.AppIntro=a.AppIntro;exports.PaginationTable=i.PaginationTable;exports.GradientButton=l.GradientButton;exports.CustomDialog=u.CustomDialog;exports.CustomPagination=s.CustomPagination;exports.CustomDropdown=c.CustomDropdown;exports.PageNotFound=P.PageNotFound;exports.UpdatePasswordDialog=m.UpdatePasswordDialog;exports.BUILD_BIG_TITLES=t.BUILD_BIG_TITLES;exports.BUILD_STEPS=t.BUILD_STEPS;exports.BUILD_TITLES=t.BUILD_TITLES;exports.BUILD_TYPES=t.BUILD_TYPES;exports.BuildComponents=t.BuildComponents;exports.STEP_ARROW_IMAGE=t.STEP_ARROW_IMAGE;exports.CustomTab=d.CustomTab;exports.PluginDetail=o.PluginDetail;exports.PluginDetailParamsTable=o.PluginDetailParamsTable;Object.defineProperty(exports,"BatchImport",{enumerable:!0,get:()=>e.BatchImport});Object.defineProperty(exports,"CustomSelect",{enumerable:!0,get:()=>e.CustomSelect});Object.defineProperty(exports,"CustomTitle",{enumerable:!0,get:()=>e.CustomTitle});Object.defineProperty(exports,"FileList",{enumerable:!0,get:()=>e.FileList});Object.defineProperty(exports,"GlassProxy",{enumerable:!0,get:()=>e.GlassProxy});Object.defineProperty(exports,"IconEmpty",{enumerable:!0,get:()=>e.IconEmpty});Object.defineProperty(exports,"IconRenderer",{enumerable:!0,get:()=>e.IconRenderer});Object.defineProperty(exports,"IconSelect",{enumerable:!0,get:()=>e.IconSelect});Object.defineProperty(exports,"SearchBar",{enumerable:!0,get:()=>e.SearchBar});Object.defineProperty(exports,"TreeSelect",{enumerable:!0,get:()=>e.TreeSelect});Object.defineProperty(exports,"TreeShowSelect",{enumerable:!0,get:()=>e.TreeShowSelect});Object.defineProperty(exports,"UploadFile",{enumerable:!0,get:()=>e.UploadFile});exports.default=I;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ling-yun-custom-components",
3
- "version": "0.0.63",
3
+ "version": "0.0.65",
4
4
  "keywords": [
5
5
  "component library",
6
6
  "ui framework",
@@ -185,11 +185,11 @@
185
185
  "axios": "^1.8.2",
186
186
  "vue": "^3.5.25",
187
187
  "color-message-lingyun-vue": "0.0.30",
188
- "color-star-atom-style": "0.0.2",
189
188
  "color-message-aibox-vue": "0.0.70",
190
- "color-star-custom-methods": "0.0.11",
191
- "color-star-custom-components": "0.0.7",
192
- "ling-yun-methods": "0.0.48"
189
+ "color-star-atom-style": "0.0.2",
190
+ "color-star-custom-methods": "0.0.13",
191
+ "ling-yun-methods": "0.0.49",
192
+ "color-star-custom-components": "0.0.8"
193
193
  },
194
194
  "optionalDependencies": {
195
195
  "@ast-grep/napi-linux-x64-musl": "^0.39.6",