@jzg223/design-runtime 0.0.1 → 0.1.0-rc.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 (54) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/README.md +52 -0
  3. package/dist/board/api.js +57 -0
  4. package/dist/board/board-chart.vue.js +7 -0
  5. package/dist/board/board-chart2.vue.js +93 -0
  6. package/dist/board/context.js +15 -0
  7. package/dist/board/datav-map.js +66 -0
  8. package/dist/board/design-board.vue.js +172 -0
  9. package/dist/board/design-board2.vue.js +331 -0
  10. package/dist/board/echarts.js +40 -0
  11. package/dist/board/part-node.vue.js +63 -0
  12. package/dist/board/part-node2.vue.js +125 -0
  13. package/dist/board/part-renderer.vue.js +561 -0
  14. package/dist/board/part-renderer2.vue.js +884 -0
  15. package/dist/board/theme-host.js +129 -0
  16. package/dist/board-engine/asset.js +32 -0
  17. package/dist/board-engine/chart-option.js +377 -0
  18. package/dist/board-engine/data-hub.js +67 -0
  19. package/dist/board-engine/datav-meta.js +51 -0
  20. package/dist/board-engine/i18n.js +130 -0
  21. package/dist/board-engine/param-catalog.js +137 -0
  22. package/dist/board-engine/params.js +61 -0
  23. package/dist/board-engine/render-model.js +65 -0
  24. package/dist/board-engine/schema.js +856 -0
  25. package/dist/board-engine/theme-manifest.js +19 -0
  26. package/dist/board-engine/version.js +4 -0
  27. package/dist/host.js +6 -1
  28. package/dist/index.js +172 -24
  29. package/dist/style.css +1067 -0
  30. package/dist/types/board/api.d.ts +45 -0
  31. package/dist/types/board/board-chart.vue.d.ts +15 -0
  32. package/dist/types/board/context.d.ts +29 -0
  33. package/dist/types/board/datav-map.d.ts +24 -0
  34. package/dist/types/board/design-board.vue.d.ts +1409 -0
  35. package/dist/types/board/echarts.d.ts +25 -0
  36. package/dist/types/board/part-node.vue.d.ts +1237 -0
  37. package/dist/types/board/part-renderer.vue.d.ts +1205 -0
  38. package/dist/types/board/theme-host.d.ts +41 -0
  39. package/dist/types/board-engine/asset.d.ts +37 -0
  40. package/dist/types/board-engine/chart-option.d.ts +737 -0
  41. package/dist/types/board-engine/data-hub.d.ts +48 -0
  42. package/dist/types/board-engine/datav-meta.d.ts +37 -0
  43. package/dist/types/board-engine/i18n.d.ts +43 -0
  44. package/dist/types/board-engine/index.d.ts +25 -0
  45. package/dist/types/board-engine/param-catalog.d.ts +82 -0
  46. package/dist/types/board-engine/params.d.ts +37 -0
  47. package/dist/types/board-engine/render-model.d.ts +87 -0
  48. package/dist/types/board-engine/schema.d.ts +513 -0
  49. package/dist/types/board-engine/theme-manifest.d.ts +23 -0
  50. package/dist/types/board-engine/types.d.ts +147 -0
  51. package/dist/types/board-engine/version.d.ts +10 -0
  52. package/dist/types/host.d.ts +21 -0
  53. package/dist/types/index.d.ts +21 -2
  54. package/package.json +21 -4
@@ -0,0 +1,561 @@
1
+ import _sfc_main from "./part-renderer2.vue.js";
2
+ import { resolveComponent, openBlock, createElementBlock, normalizeStyle, normalizeClass, Fragment, createVNode, createCommentVNode, createElementVNode, toDisplayString, withModifiers, renderList, renderSlot, createBlock, resolveDynamicComponent, withKeys } from "vue";
3
+ /* empty css */
4
+ import _export_sfc from "../_virtual/_plugin-vue_export-helper.js";
5
+ const _hoisted_1 = {
6
+ key: 0,
7
+ class: "part-empty"
8
+ };
9
+ const _hoisted_2 = { class: "num" };
10
+ const _hoisted_3 = { class: "unit" };
11
+ const _hoisted_4 = {
12
+ key: 2,
13
+ class: "part-table-wrap"
14
+ };
15
+ const _hoisted_5 = ["onClick"];
16
+ const _hoisted_6 = { class: "th-label" };
17
+ const _hoisted_7 = {
18
+ key: 0,
19
+ class: "sort-mark"
20
+ };
21
+ const _hoisted_8 = ["onMousedown"];
22
+ const _hoisted_9 = ["onClick"];
23
+ const _hoisted_10 = { key: 0 };
24
+ const _hoisted_11 = ["colspan"];
25
+ const _hoisted_12 = { key: 0 };
26
+ const _hoisted_13 = {
27
+ key: 3,
28
+ class: "part-table-wrap"
29
+ };
30
+ const _hoisted_14 = ["colspan", "rowspan"];
31
+ const _hoisted_15 = ["onClick"];
32
+ const _hoisted_16 = ["onClick"];
33
+ const _hoisted_17 = {
34
+ key: 0,
35
+ class: "total"
36
+ };
37
+ const _hoisted_18 = { key: 0 };
38
+ const _hoisted_19 = ["colspan"];
39
+ const _hoisted_20 = { key: 0 };
40
+ const _hoisted_21 = { class: "total grand" };
41
+ const _hoisted_22 = {
42
+ key: 5,
43
+ class: "part-image"
44
+ };
45
+ const _hoisted_23 = ["src"];
46
+ const _hoisted_24 = {
47
+ key: 1,
48
+ class: "part-empty"
49
+ };
50
+ const _hoisted_25 = {
51
+ key: 6,
52
+ class: "part-border"
53
+ };
54
+ const _hoisted_26 = { class: "pt-text" };
55
+ const _hoisted_27 = {
56
+ key: 7,
57
+ class: "part-container"
58
+ };
59
+ const _hoisted_28 = {
60
+ key: 0,
61
+ class: "glass-run"
62
+ };
63
+ const _hoisted_29 = { class: "pt-text" };
64
+ const _hoisted_30 = {
65
+ key: 4,
66
+ class: "part-empty"
67
+ };
68
+ const _hoisted_31 = {
69
+ key: 8,
70
+ class: "part-tabs"
71
+ };
72
+ const _hoisted_32 = { class: "tab-head" };
73
+ const _hoisted_33 = ["onClick"];
74
+ const _hoisted_34 = {
75
+ key: 0,
76
+ class: "tab-content"
77
+ };
78
+ const _hoisted_35 = {
79
+ key: 1,
80
+ class: "part-empty"
81
+ };
82
+ const _hoisted_36 = {
83
+ key: 9,
84
+ class: "part-iframe"
85
+ };
86
+ const _hoisted_37 = ["src"];
87
+ const _hoisted_38 = {
88
+ key: 1,
89
+ class: "part-empty"
90
+ };
91
+ const _hoisted_39 = {
92
+ key: 10,
93
+ class: "part-video"
94
+ };
95
+ const _hoisted_40 = ["src", "autoplay", "loop", "muted", "controls"];
96
+ const _hoisted_41 = {
97
+ key: 1,
98
+ class: "part-empty"
99
+ };
100
+ const _hoisted_42 = {
101
+ key: 11,
102
+ class: "part-carousel"
103
+ };
104
+ const _hoisted_43 = ["src"];
105
+ const _hoisted_44 = {
106
+ key: 1,
107
+ class: "part-empty"
108
+ };
109
+ const _hoisted_45 = {
110
+ key: 2,
111
+ class: "carousel-title"
112
+ };
113
+ const _hoisted_46 = { class: "carousel-dots" };
114
+ const _hoisted_47 = ["onClick"];
115
+ const _hoisted_48 = {
116
+ key: 1,
117
+ class: "part-empty"
118
+ };
119
+ const _hoisted_49 = {
120
+ key: 12,
121
+ class: "part-marquee"
122
+ };
123
+ const _hoisted_50 = {
124
+ key: 13,
125
+ class: "part-decoration"
126
+ };
127
+ const _hoisted_51 = {
128
+ key: 14,
129
+ class: "part-progress"
130
+ };
131
+ const _hoisted_52 = { class: "pg-head" };
132
+ const _hoisted_53 = { key: 0 };
133
+ const _hoisted_54 = { class: "pg-bar" };
134
+ const _hoisted_55 = {
135
+ key: 15,
136
+ class: "part-button"
137
+ };
138
+ const _hoisted_56 = ["title", "onClick"];
139
+ const _hoisted_57 = { class: "nav-text" };
140
+ const _hoisted_58 = {
141
+ key: 17,
142
+ class: "part-filter"
143
+ };
144
+ const _hoisted_59 = { class: "filter-label" };
145
+ const _hoisted_60 = ["value"];
146
+ const _hoisted_61 = ["value"];
147
+ const _hoisted_62 = ["value"];
148
+ const _hoisted_63 = ["value"];
149
+ const _hoisted_64 = ["value", "placeholder"];
150
+ const _hoisted_65 = {
151
+ key: 18,
152
+ class: "part-empty"
153
+ };
154
+ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
155
+ const _component_board_chart = resolveComponent("board-chart");
156
+ return openBlock(), createElementBlock("div", {
157
+ class: normalizeClass(["part-body", $options.bodyClass]),
158
+ style: normalizeStyle($options.bodyStyle)
159
+ }, [
160
+ $props.part.type === "chart" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
161
+ createVNode(_component_board_chart, {
162
+ option: $options.chartOption,
163
+ onChartClick: $options.onChartClick
164
+ }, null, 8, ["option", "onChartClick"]),
165
+ !$options.hasData ? (openBlock(), createElementBlock("div", _hoisted_1, "未绑定数据集")) : createCommentVNode("", true)
166
+ ], 64)) : $props.part.type === "kpi" ? (openBlock(), createElementBlock("div", {
167
+ key: 1,
168
+ class: "kpi",
169
+ style: normalizeStyle($options.kpiBoxStyle)
170
+ }, [
171
+ createElementVNode("div", {
172
+ class: "kpi-title",
173
+ style: normalizeStyle($options.subStyle)
174
+ }, toDisplayString($options.kpiTitle), 5),
175
+ createElementVNode("div", {
176
+ class: "kpi-value",
177
+ style: normalizeStyle($options.valueStyle)
178
+ }, [
179
+ createElementVNode("span", _hoisted_2, toDisplayString($options.kpiValue), 1),
180
+ createElementVNode("span", _hoisted_3, toDisplayString($props.part.view.unit), 1)
181
+ ], 4)
182
+ ], 4)) : $props.part.type === "table" ? (openBlock(), createElementBlock("div", _hoisted_4, [
183
+ $props.part.view.exportCsv ? (openBlock(), createElementBlock("div", {
184
+ key: 0,
185
+ class: "part-toolbar",
186
+ onMousedown: _cache[1] || (_cache[1] = withModifiers(() => {
187
+ }, ["stop"]))
188
+ }, [
189
+ createElementVNode("button", {
190
+ type: "button",
191
+ class: "drb-export",
192
+ title: "导出当前明细为 CSV",
193
+ onClick: _cache[0] || (_cache[0] = withModifiers((...args) => $options.exportCsv && $options.exportCsv(...args), ["stop"]))
194
+ }, [..._cache[10] || (_cache[10] = [
195
+ createElementVNode("svg", {
196
+ class: "drb-export__icon",
197
+ viewBox: "0 0 16 16",
198
+ width: "13",
199
+ height: "13",
200
+ "aria-hidden": "true"
201
+ }, [
202
+ createElementVNode("path", {
203
+ fill: "currentColor",
204
+ d: "M7.25 1h1.5v7.19l2.22-2.22 1.06 1.06L8 11.06 3.97 7.03l1.06-1.06 2.22 2.22V1zM2.5 12h11v1.5h-11V12z"
205
+ })
206
+ ], -1)
207
+ ])])
208
+ ], 32)) : createCommentVNode("", true),
209
+ createElementVNode("table", {
210
+ class: normalizeClass(["part-table", { stripe: $props.part.view.stripe !== false, bordered: !!$props.part.view.bordered, fixed: $options.hasColWidths }]),
211
+ style: normalizeStyle($options.tableStyle)
212
+ }, [
213
+ createElementVNode("colgroup", null, [
214
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.tableColumns, (c) => {
215
+ return openBlock(), createElementBlock("col", {
216
+ key: c.name,
217
+ style: normalizeStyle({ width: $options.colWidthOf(c) })
218
+ }, null, 4);
219
+ }), 128))
220
+ ]),
221
+ createElementVNode("thead", null, [
222
+ createElementVNode("tr", null, [
223
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.tableColumns, (c) => {
224
+ return openBlock(), createElementBlock("th", {
225
+ key: c.name,
226
+ style: normalizeStyle($options.thStyle(c)),
227
+ class: normalizeClass({ sortable: $options.isSortable, sorted: $options.sortField === c.name }),
228
+ onClick: ($event) => $options.onSort(c)
229
+ }, [
230
+ createElementVNode("span", _hoisted_6, toDisplayString(c.label || c.alias || c.name), 1),
231
+ $options.isSortable && $options.sortField === c.name ? (openBlock(), createElementBlock("span", _hoisted_7, toDisplayString($props.part.data.orderDesc ? "▼" : "▲"), 1)) : createCommentVNode("", true),
232
+ $options.isResizable ? (openBlock(), createElementBlock("span", {
233
+ key: 1,
234
+ class: "col-resizer",
235
+ onMousedown: withModifiers(($event) => $options.startColResize($event, c), ["stop"]),
236
+ onClick: _cache[2] || (_cache[2] = withModifiers(() => {
237
+ }, ["stop"]))
238
+ }, null, 40, _hoisted_8)) : createCommentVNode("", true)
239
+ ], 14, _hoisted_5);
240
+ }), 128))
241
+ ])
242
+ ]),
243
+ createElementVNode("tbody", null, [
244
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.tableRows, (r, i) => {
245
+ return openBlock(), createElementBlock("tr", { key: i }, [
246
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.tableColumns, (c) => {
247
+ return openBlock(), createElementBlock("td", {
248
+ key: c.name,
249
+ onClick: ($event) => $options.onCellClick(r, c)
250
+ }, toDisplayString($options.cellText(r, c)), 9, _hoisted_9);
251
+ }), 128))
252
+ ]);
253
+ }), 128)),
254
+ !$options.tableRows.length ? (openBlock(), createElementBlock("tr", _hoisted_10, [
255
+ createElementVNode("td", {
256
+ colspan: $options.tableColumns.length || 1,
257
+ class: "part-empty"
258
+ }, toDisplayString($data.loading ? "加载中…" : "暂无数据"), 9, _hoisted_11)
259
+ ])) : createCommentVNode("", true)
260
+ ]),
261
+ $options.showSummary && $options.tableRows.length ? (openBlock(), createElementBlock("tfoot", _hoisted_12, [
262
+ createElementVNode("tr", null, [
263
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.tableColumns, (c, i) => {
264
+ return openBlock(), createElementBlock("td", {
265
+ key: c.name
266
+ }, toDisplayString(i === 0 ? "合计" : $options.summaryText(c)), 1);
267
+ }), 128))
268
+ ])
269
+ ])) : createCommentVNode("", true)
270
+ ], 6)
271
+ ])) : $props.part.type === "crossTable" ? (openBlock(), createElementBlock("div", _hoisted_13, [
272
+ $props.part.view.exportCsv ? (openBlock(), createElementBlock("div", {
273
+ key: 0,
274
+ class: "part-toolbar",
275
+ onMousedown: _cache[4] || (_cache[4] = withModifiers(() => {
276
+ }, ["stop"]))
277
+ }, [
278
+ createElementVNode("button", {
279
+ type: "button",
280
+ class: "drb-export",
281
+ title: "导出交叉表为 CSV",
282
+ onClick: _cache[3] || (_cache[3] = withModifiers((...args) => $options.exportCsv && $options.exportCsv(...args), ["stop"]))
283
+ }, [..._cache[11] || (_cache[11] = [
284
+ createElementVNode("svg", {
285
+ class: "drb-export__icon",
286
+ viewBox: "0 0 16 16",
287
+ width: "13",
288
+ height: "13",
289
+ "aria-hidden": "true"
290
+ }, [
291
+ createElementVNode("path", {
292
+ fill: "currentColor",
293
+ d: "M7.25 1h1.5v7.19l2.22-2.22 1.06 1.06L8 11.06 3.97 7.03l1.06-1.06 2.22 2.22V1zM2.5 12h11v1.5h-11V12z"
294
+ })
295
+ ], -1)
296
+ ])])
297
+ ], 32)) : createCommentVNode("", true),
298
+ createElementVNode("table", {
299
+ class: normalizeClass(["part-table cross", { stripe: $props.part.view.stripe !== false }])
300
+ }, [
301
+ createElementVNode("thead", null, [
302
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.crossView.headRows, (hrow, ri) => {
303
+ return openBlock(), createElementBlock("tr", {
304
+ key: "ch" + ri
305
+ }, [
306
+ (openBlock(true), createElementBlock(Fragment, null, renderList(hrow, (c, ci) => {
307
+ return openBlock(), createElementBlock("th", {
308
+ key: "ch" + ri + "_" + ci,
309
+ colspan: c.colspan || 1,
310
+ rowspan: c.rowspan || 1,
311
+ class: normalizeClass(c.cls),
312
+ style: { textAlign: "center" }
313
+ }, toDisplayString(c.text), 11, _hoisted_14);
314
+ }), 128))
315
+ ]);
316
+ }), 128))
317
+ ]),
318
+ createElementVNode("tbody", null, [
319
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.crossView.bodyRows, (r, ri) => {
320
+ return openBlock(), createElementBlock("tr", {
321
+ key: "cb" + ri
322
+ }, [
323
+ createElementVNode("td", {
324
+ class: "row-head",
325
+ onClick: ($event) => $options.onDrill($options.crossView.rowField, r.name)
326
+ }, toDisplayString(r.name), 9, _hoisted_15),
327
+ (openBlock(true), createElementBlock(Fragment, null, renderList(r.cells, (c, ci) => {
328
+ return openBlock(), createElementBlock("td", {
329
+ key: "cb" + ri + "_" + ci,
330
+ onClick: ($event) => $options.onDrill($options.crossView.rowField, r.name)
331
+ }, toDisplayString(c), 9, _hoisted_16);
332
+ }), 128)),
333
+ $props.part.view.showTotal !== false ? (openBlock(), createElementBlock("td", _hoisted_17, toDisplayString(r.total), 1)) : createCommentVNode("", true)
334
+ ]);
335
+ }), 128)),
336
+ !$options.crossView.bodyRows.length ? (openBlock(), createElementBlock("tr", _hoisted_18, [
337
+ createElementVNode("td", {
338
+ colspan: $options.crossView.colCount * Math.max(1, $options.crossMeasures.length) + 2,
339
+ class: "part-empty"
340
+ }, toDisplayString($data.loading ? "加载中…" : "暂无数据(请选择行维/列维/度量)"), 9, _hoisted_19)
341
+ ])) : createCommentVNode("", true)
342
+ ]),
343
+ $options.crossView.bodyRows.length && $props.part.view.showTotal !== false ? (openBlock(), createElementBlock("tfoot", _hoisted_20, [
344
+ createElementVNode("tr", null, [
345
+ _cache[12] || (_cache[12] = createElementVNode("td", { class: "row-head" }, "合计", -1)),
346
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.crossView.footCells, (c, ci) => {
347
+ return openBlock(), createElementBlock("td", {
348
+ key: "cf" + ci,
349
+ class: "total"
350
+ }, toDisplayString(c), 1);
351
+ }), 128)),
352
+ createElementVNode("td", _hoisted_21, toDisplayString($options.crossView.footTotal), 1)
353
+ ])
354
+ ])) : createCommentVNode("", true)
355
+ ], 2)
356
+ ])) : $props.part.type === "text" ? (openBlock(), createElementBlock("div", {
357
+ key: 4,
358
+ class: normalizeClass(["part-text", "ov-" + $options.textOverflow]),
359
+ style: normalizeStyle($options.textBoxStyle)
360
+ }, [
361
+ createElementVNode("span", { ref: "textInner" }, toDisplayString($props.part.view.content), 513)
362
+ ], 6)) : $props.part.type === "image" ? (openBlock(), createElementBlock("div", _hoisted_22, [
363
+ $props.part.view.src ? (openBlock(), createElementBlock("img", {
364
+ key: 0,
365
+ src: $options.mediaSrc($props.part.view.src),
366
+ style: normalizeStyle({ objectFit: $props.part.view.fit || "contain" })
367
+ }, null, 12, _hoisted_23)) : (openBlock(), createElementBlock("div", _hoisted_24, "未设置图片地址"))
368
+ ])) : $props.part.type === "border" ? (openBlock(), createElementBlock("div", _hoisted_25, [
369
+ $props.part.view.showTitle !== false ? (openBlock(), createElementBlock("div", {
370
+ key: 0,
371
+ class: normalizeClass(["border-title", "ts-" + $options.titleStyle]),
372
+ style: normalizeStyle($options.titleOffsetStyle)
373
+ }, [
374
+ createElementVNode("span", _hoisted_26, toDisplayString($props.part.view.title), 1)
375
+ ], 6)) : createCommentVNode("", true),
376
+ $props.childrenCount ? (openBlock(), createElementBlock("div", {
377
+ key: 1,
378
+ class: normalizeClass(["part-children", { "is-free": $options.childrenFree, "is-stacked": $props.stacked, "is-active": $props.design && $props.active }]),
379
+ style: normalizeStyle($options.childGridStyle)
380
+ }, [
381
+ renderSlot(_ctx.$slots, "children", {}, void 0, true)
382
+ ], 6)) : createCommentVNode("", true),
383
+ $props.design && $props.childrenCount ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
384
+ _cache[13] || (_cache[13] = createElementVNode("div", { class: "hit hit-t" }, null, -1)),
385
+ _cache[14] || (_cache[14] = createElementVNode("div", { class: "hit hit-b" }, null, -1)),
386
+ _cache[15] || (_cache[15] = createElementVNode("div", { class: "hit hit-l" }, null, -1)),
387
+ _cache[16] || (_cache[16] = createElementVNode("div", { class: "hit hit-r" }, null, -1))
388
+ ], 64)) : createCommentVNode("", true)
389
+ ])) : $props.part.type === "container" ? (openBlock(), createElementBlock("div", _hoisted_27, [
390
+ $options.borderPreset === "glow" ? (openBlock(), createElementBlock("div", _hoisted_28)) : createCommentVNode("", true),
391
+ $options.borderPreset === "datav" ? (openBlock(), createBlock(resolveDynamicComponent($options.datavBorder), {
392
+ key: 1,
393
+ ref: "datavFrame",
394
+ class: "datav-frame",
395
+ color: $options.datavColors
396
+ }, null, 8, ["color"])) : createCommentVNode("", true),
397
+ $props.part.view.showTitle ? (openBlock(), createElementBlock("div", {
398
+ key: 2,
399
+ class: normalizeClass(["container-title", "ts-" + $options.titleStyle]),
400
+ style: normalizeStyle($options.titleOffsetStyle)
401
+ }, [
402
+ createElementVNode("span", _hoisted_29, toDisplayString($props.part.view.title), 1)
403
+ ], 6)) : createCommentVNode("", true),
404
+ $props.childrenCount ? (openBlock(), createElementBlock("div", {
405
+ key: 3,
406
+ class: normalizeClass(["part-children", { "is-free": $options.childrenFree, "is-stacked": $props.stacked, "is-active": $props.design && $props.active }]),
407
+ style: normalizeStyle($options.childGridStyle)
408
+ }, [
409
+ renderSlot(_ctx.$slots, "children", {}, void 0, true)
410
+ ], 6)) : $props.design ? (openBlock(), createElementBlock("div", _hoisted_30, "自由容器:把左侧元素拖进来,子部件按容器内的 24 列栅格排列")) : createCommentVNode("", true),
411
+ $props.design && $props.childrenCount ? (openBlock(), createElementBlock(Fragment, { key: 5 }, [
412
+ _cache[17] || (_cache[17] = createElementVNode("div", { class: "hit hit-t" }, null, -1)),
413
+ _cache[18] || (_cache[18] = createElementVNode("div", { class: "hit hit-b" }, null, -1)),
414
+ _cache[19] || (_cache[19] = createElementVNode("div", { class: "hit hit-l" }, null, -1)),
415
+ _cache[20] || (_cache[20] = createElementVNode("div", { class: "hit hit-r" }, null, -1))
416
+ ], 64)) : createCommentVNode("", true)
417
+ ])) : $props.part.type === "tabContainer" ? (openBlock(), createElementBlock("div", _hoisted_31, [
418
+ createElementVNode("div", _hoisted_32, [
419
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.tabs, (t, i) => {
420
+ return openBlock(), createElementBlock("span", {
421
+ key: i,
422
+ class: normalizeClass(["tab-item", { active: i === $data.activeTab }]),
423
+ onClick: ($event) => $data.activeTab = i
424
+ }, toDisplayString(t), 11, _hoisted_33);
425
+ }), 128))
426
+ ]),
427
+ createElementVNode("div", {
428
+ class: normalizeClass(["tab-body", { "is-grid": $options.tabHasChildren, "is-free": $options.tabHasChildren && $options.childrenFree, "is-stacked": $options.tabHasChildren && $props.stacked }]),
429
+ style: normalizeStyle($options.tabHasChildren ? $options.childGridStyle : null)
430
+ }, [
431
+ $options.tabHasChildren ? renderSlot(_ctx.$slots, "children", { tab: $data.activeTab }, void 0, true, 0) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
432
+ $options.tabContents.length ? (openBlock(), createElementBlock("div", _hoisted_34, toDisplayString($options.tabContents[$data.activeTab] || "(本页签暂无内容)"), 1)) : $props.design ? (openBlock(), createElementBlock("div", _hoisted_35, "tab 容器:可在右侧配置页签与每页内容,或把部件拖进当前页签")) : createCommentVNode("", true)
433
+ ], 64))
434
+ ], 6)
435
+ ])) : $props.part.type === "iframe" ? (openBlock(), createElementBlock("div", _hoisted_36, [
436
+ $props.part.view.src ? (openBlock(), createElementBlock("iframe", {
437
+ key: 0,
438
+ src: $options.mediaSrc($props.part.view.src),
439
+ frameborder: "0"
440
+ }, null, 8, _hoisted_37)) : (openBlock(), createElementBlock("div", _hoisted_38, "未设置页面地址"))
441
+ ])) : $props.part.type === "video" ? (openBlock(), createElementBlock("div", _hoisted_39, [
442
+ $props.part.view.src ? (openBlock(), createElementBlock("video", {
443
+ key: 0,
444
+ src: $options.mediaSrc($props.part.view.src),
445
+ autoplay: !!$props.part.view.autoplay,
446
+ loop: $props.part.view.loop !== false,
447
+ muted: $props.part.view.muted !== false,
448
+ controls: $props.part.view.controls !== false
449
+ }, null, 8, _hoisted_40)) : (openBlock(), createElementBlock("div", _hoisted_41, "未设置视频地址"))
450
+ ])) : $props.part.type === "carousel" ? (openBlock(), createElementBlock("div", _hoisted_42, [
451
+ $options.carouselImages.length ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
452
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.carouselImages, (img, i) => {
453
+ return openBlock(), createElementBlock("div", {
454
+ key: i,
455
+ class: "carousel-item",
456
+ style: normalizeStyle({ opacity: i === $data.carouselIndex ? 1 : 0 })
457
+ }, [
458
+ img.src ? (openBlock(), createElementBlock("img", {
459
+ key: 0,
460
+ src: $options.mediaSrc(img.src)
461
+ }, null, 8, _hoisted_43)) : (openBlock(), createElementBlock("div", _hoisted_44, "第 " + toDisplayString(i + 1) + " 张未设置地址", 1)),
462
+ $props.part.view.showTitle !== false && img.title ? (openBlock(), createElementBlock("div", _hoisted_45, toDisplayString(img.title), 1)) : createCommentVNode("", true)
463
+ ], 4);
464
+ }), 128)),
465
+ createElementVNode("div", _hoisted_46, [
466
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.carouselImages, (img, i) => {
467
+ return openBlock(), createElementBlock("span", {
468
+ key: i,
469
+ class: normalizeClass({ active: i === $data.carouselIndex }),
470
+ onClick: ($event) => $data.carouselIndex = i
471
+ }, null, 10, _hoisted_47);
472
+ }), 128))
473
+ ])
474
+ ], 64)) : (openBlock(), createElementBlock("div", _hoisted_48, "未配置轮播图"))
475
+ ])) : $props.part.type === "marquee" ? (openBlock(), createElementBlock("div", _hoisted_49, [
476
+ createElementVNode("div", {
477
+ class: "marquee-inner",
478
+ style: normalizeStyle($options.marqueeStyle)
479
+ }, toDisplayString($props.part.view.content), 5)
480
+ ])) : $props.part.type === "decoration" ? (openBlock(), createElementBlock("div", _hoisted_50, [
481
+ (openBlock(), createBlock(resolveDynamicComponent($options.datavDecoration), {
482
+ ref: "datavDeco",
483
+ color: $options.datavDecoColors
484
+ }, null, 8, ["color"]))
485
+ ])) : $props.part.type === "progress" ? (openBlock(), createElementBlock("div", _hoisted_51, [
486
+ createElementVNode("div", _hoisted_52, [
487
+ createElementVNode("span", null, toDisplayString($props.part.view.title), 1),
488
+ $props.part.view.showValue !== false ? (openBlock(), createElementBlock("span", _hoisted_53, toDisplayString($options.progressValue) + toDisplayString($props.part.view.unit), 1)) : createCommentVNode("", true)
489
+ ]),
490
+ createElementVNode("div", _hoisted_54, [
491
+ createElementVNode("div", {
492
+ class: "pg-fill",
493
+ style: normalizeStyle({ width: Math.max(0, Math.min(100, $options.progressValue)) + "%" })
494
+ }, null, 4)
495
+ ])
496
+ ])) : $props.part.type === "button" ? (openBlock(), createElementBlock("div", _hoisted_55, [
497
+ createElementVNode("button", {
498
+ class: normalizeClass(["btn", "btn-" + ($props.part.view.type || "primary")]),
499
+ onClick: _cache[5] || (_cache[5] = (...args) => $options.onButtonClick && $options.onButtonClick(...args))
500
+ }, toDisplayString($props.part.view.text), 3)
501
+ ])) : $props.part.type === "nav" ? (openBlock(), createElementBlock("div", {
502
+ key: 16,
503
+ class: normalizeClass(["part-nav", ["nav-" + ($props.part.view.style || "plate"), { "is-absolute": $options.navAbsolute }]]),
504
+ style: normalizeStyle($options.navStyle)
505
+ }, [
506
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.navItems, (it, i) => {
507
+ return openBlock(), createElementBlock("div", {
508
+ key: i,
509
+ class: normalizeClass(["nav-item", { "is-active": $options.isNavActive(it) }]),
510
+ style: normalizeStyle($options.navItemStyle(it)),
511
+ role: "button",
512
+ title: it.label,
513
+ onClick: withModifiers(($event) => $options.onNavClick(it), ["stop"])
514
+ }, [
515
+ createElementVNode("span", _hoisted_57, toDisplayString(it.label), 1)
516
+ ], 14, _hoisted_56);
517
+ }), 128))
518
+ ], 6)) : $props.part.type === "filter" ? (openBlock(), createElementBlock("div", _hoisted_58, [
519
+ createElementVNode("span", _hoisted_59, toDisplayString($props.part.view.label || "筛选"), 1),
520
+ $options.filterCfg.type === "select" || $options.filterCfg.type === "period" ? (openBlock(), createElementBlock("select", {
521
+ key: 0,
522
+ class: "filter-input",
523
+ value: $options.currentParam,
524
+ onChange: _cache[6] || (_cache[6] = ($event) => $options.onFilterChange($event.target.value))
525
+ }, [
526
+ _cache[21] || (_cache[21] = createElementVNode("option", { value: "" }, "全部", -1)),
527
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.filterCfg.options, (o) => {
528
+ return openBlock(), createElementBlock("option", {
529
+ key: o,
530
+ value: o
531
+ }, toDisplayString(o), 9, _hoisted_61);
532
+ }), 128))
533
+ ], 40, _hoisted_60)) : $options.filterCfg.type === "date" ? (openBlock(), createElementBlock("input", {
534
+ key: 1,
535
+ class: "filter-input",
536
+ type: "date",
537
+ value: $options.currentParam,
538
+ onChange: _cache[7] || (_cache[7] = ($event) => $options.onFilterChange($event.target.value))
539
+ }, null, 40, _hoisted_62)) : $options.filterCfg.type === "year" ? (openBlock(), createElementBlock("input", {
540
+ key: 2,
541
+ class: "filter-input",
542
+ type: "number",
543
+ min: "1900",
544
+ max: "2999",
545
+ value: $options.currentParam,
546
+ placeholder: "如 2026",
547
+ onChange: _cache[8] || (_cache[8] = ($event) => $options.onFilterChange($event.target.value))
548
+ }, null, 40, _hoisted_63)) : (openBlock(), createElementBlock("input", {
549
+ key: 3,
550
+ class: "filter-input",
551
+ value: $options.currentParam,
552
+ placeholder: $options.filterCfg.type === "org" ? "机构编码(本期手填)" : "输入后回车",
553
+ onKeyup: _cache[9] || (_cache[9] = withKeys(($event) => $options.onFilterChange($event.target.value), ["enter"]))
554
+ }, null, 40, _hoisted_64))
555
+ ])) : (openBlock(), createElementBlock("div", _hoisted_65, "未知部件类型:" + toDisplayString($props.part.type), 1))
556
+ ], 6);
557
+ }
558
+ const PartRenderer = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-16075a7b"]]);
559
+ export {
560
+ PartRenderer as default
561
+ };