bi-components-library 1.0.41 → 1.0.42

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.es.js CHANGED
@@ -1,15 +1,15 @@
1
- import { jsx as S, jsxs as oe, Fragment as ct } from "react/jsx-runtime";
2
- import ut, { useState as Z, useRef as ne, useMemo as et, useCallback as se, useEffect as ue, useLayoutEffect as We } from "react";
3
- import { Button as Se, Card as Re, Modal as dt, Table as Fe, Flex as Ke, Spin as pt, Empty as ft, Select as Pe, Form as De, Input as tt, Space as yt, DatePicker as mt, Dropdown as ht, Tooltip as gt, Progress as vt, Pagination as bt, theme as xt } from "antd";
4
- import { createFromIconfontCN as kt, LeftOutlined as wt, SearchOutlined as $t, ReloadOutlined as Et, InfoCircleOutlined as Ct, SendOutlined as St, PauseCircleOutlined as qt, PlayCircleOutlined as Tt } from "@ant-design/icons";
1
+ import { jsx as S, jsxs as re, Fragment as ut } from "react/jsx-runtime";
2
+ import dt, { useState as ee, useRef as ne, useMemo as tt, useCallback as le, useEffect as pe, useLayoutEffect as Ke } from "react";
3
+ import { Button as Ce, Card as Re, Modal as pt, Table as Fe, Flex as Ue, Spin as ft, Empty as mt, Select as Pe, Form as Me, Input as nt, Space as yt, DatePicker as ht, Dropdown as gt, Tooltip as vt, Progress as bt, Pagination as xt, theme as wt } from "antd";
4
+ import { createFromIconfontCN as kt, LeftOutlined as Et, SearchOutlined as $t, ReloadOutlined as Ct, InfoCircleOutlined as St, SendOutlined as Tt, PauseCircleOutlined as qt, PlayCircleOutlined as Nt } from "@ant-design/icons";
5
5
  import { createPortal as ze } from "react-dom";
6
- const Nt = ({
6
+ const At = ({
7
7
  variant: t = "primary",
8
- loading: u = !1,
8
+ loading: d = !1,
9
9
  children: i,
10
10
  ...s
11
11
  }) => /* @__PURE__ */ S(
12
- Se,
12
+ Ce,
13
13
  {
14
14
  ...s,
15
15
  type: ((E) => {
@@ -28,12 +28,12 @@ const Nt = ({
28
28
  return "primary";
29
29
  }
30
30
  })(t),
31
- loading: u,
31
+ loading: d,
32
32
  ghost: t === "ghost",
33
33
  children: i
34
34
  }
35
35
  );
36
- Nt.__docgenInfo = {
36
+ At.__docgenInfo = {
37
37
  displayName: "Button",
38
38
  description: "基础按钮,用于触发操作",
39
39
  props: {
@@ -77,12 +77,12 @@ Nt.__docgenInfo = {
77
77
  }
78
78
  }
79
79
  };
80
- const At = ({
80
+ const _t = ({
81
81
  title: t,
82
- children: u,
82
+ children: d,
83
83
  bordered: i = !0,
84
84
  hoverable: s = !1,
85
- size: f = "default",
85
+ size: u = "default",
86
86
  ...E
87
87
  }) => /* @__PURE__ */ S(
88
88
  Re,
@@ -91,11 +91,11 @@ const At = ({
91
91
  title: t,
92
92
  bordered: i,
93
93
  hoverable: s,
94
- size: f,
95
- children: u
94
+ size: u,
95
+ children: d
96
96
  }
97
97
  );
98
- At.__docgenInfo = {
98
+ _t.__docgenInfo = {
99
99
  displayName: "Card",
100
100
  description: "卡片容器,用于分组内容",
101
101
  props: {
@@ -146,23 +146,23 @@ At.__docgenInfo = {
146
146
  }
147
147
  }
148
148
  };
149
- const _t = ({
149
+ const Lt = ({
150
150
  showDefaultFooter: t = !0,
151
- ...u
151
+ ...d
152
152
  }) => {
153
- const i = u.footer !== void 0 ? u.footer : t ? (s, { OkBtn: f, CancelBtn: E }) => /* @__PURE__ */ oe(ct, { children: [
154
- /* @__PURE__ */ S(f, {}),
153
+ const i = d.footer !== void 0 ? d.footer : t ? (s, { OkBtn: u, CancelBtn: E }) => /* @__PURE__ */ re(ut, { children: [
154
+ /* @__PURE__ */ S(u, {}),
155
155
  /* @__PURE__ */ S(E, {})
156
156
  ] }) : null;
157
157
  return /* @__PURE__ */ S(
158
- dt,
158
+ pt,
159
159
  {
160
- ...u,
160
+ ...d,
161
161
  footer: i
162
162
  }
163
163
  );
164
164
  };
165
- _t.__docgenInfo = {
165
+ Lt.__docgenInfo = {
166
166
  displayName: "AppModal",
167
167
  description: "应用级模态框组件,基于 Ant Design Modal 封装",
168
168
  props: {
@@ -223,9 +223,9 @@ _t.__docgenInfo = {
223
223
  }
224
224
  }
225
225
  };
226
- const Lt = ({
226
+ const Mt = ({
227
227
  scrollX: t,
228
- showPagination: u = !0,
228
+ showPagination: d = !0,
229
229
  defaultPageSize: i = 10,
230
230
  ...s
231
231
  }) => /* @__PURE__ */ S(
@@ -236,7 +236,7 @@ const Lt = ({
236
236
  x: t || "max-content",
237
237
  y: "50vh"
238
238
  },
239
- pagination: u ? {
239
+ pagination: d ? {
240
240
  hideOnSinglePage: !0,
241
241
  showSizeChanger: !0,
242
242
  showQuickJumper: !0,
@@ -245,7 +245,7 @@ const Lt = ({
245
245
  } : !1
246
246
  }
247
247
  );
248
- Lt.__docgenInfo = {
248
+ Mt.__docgenInfo = {
249
249
  displayName: "PageTable",
250
250
  description: "页面级表格组件,高度铺满容器,自动滚动",
251
251
  props: {
@@ -297,28 +297,28 @@ Lt.__docgenInfo = {
297
297
  };
298
298
  const Dt = kt({
299
299
  scriptUrl: ["//at.alicdn.com/t/c/font_5037819_a72xy7yjoj.js"]
300
- }), Mt = ({
300
+ }), It = ({
301
301
  name: t,
302
- size: u,
302
+ size: d,
303
303
  color: i,
304
304
  style: s,
305
- ...f
305
+ ...u
306
306
  }) => {
307
307
  const E = {
308
- fontSize: u,
308
+ fontSize: d,
309
309
  color: i,
310
310
  ...s
311
311
  };
312
312
  return /* @__PURE__ */ S(
313
313
  Dt,
314
314
  {
315
- ...f,
315
+ ...u,
316
316
  type: t,
317
317
  style: E
318
318
  }
319
319
  );
320
320
  };
321
- Mt.__docgenInfo = {
321
+ It.__docgenInfo = {
322
322
  displayName: "XcIcon",
323
323
  description: "自定义图标组件,基于 iconfont",
324
324
  props: {
@@ -354,43 +354,43 @@ Mt.__docgenInfo = {
354
354
  }
355
355
  }
356
356
  };
357
- const It = ({
357
+ const Vt = ({
358
358
  loading: t,
359
- description: u = "暂无数据",
359
+ description: d = "暂无数据",
360
360
  className: i,
361
361
  emptyChildren: s,
362
- loadingText: f,
362
+ loadingText: u,
363
363
  emptyImage: E
364
- }) => t ? /* @__PURE__ */ oe(
365
- Ke,
364
+ }) => t ? /* @__PURE__ */ re(
365
+ Ue,
366
366
  {
367
367
  className: `pt-10 w-full ${i || ""}`,
368
368
  align: "center",
369
369
  justify: "center",
370
370
  vertical: !0,
371
371
  children: [
372
- /* @__PURE__ */ S(pt, { size: "large" }),
373
- f && /* @__PURE__ */ S("div", { className: "mt-4 text-gray-500", children: f })
372
+ /* @__PURE__ */ S(ft, { size: "large" }),
373
+ u && /* @__PURE__ */ S("div", { className: "mt-4 text-gray-500", children: u })
374
374
  ]
375
375
  }
376
376
  ) : /* @__PURE__ */ S(
377
- Ke,
377
+ Ue,
378
378
  {
379
379
  className: `pt-10 w-full ${i || ""}`,
380
380
  align: "center",
381
381
  justify: "center",
382
382
  children: /* @__PURE__ */ S(
383
- ft,
383
+ mt,
384
384
  {
385
385
  image: E,
386
- description: u,
386
+ description: d,
387
387
  imageStyle: { height: 180 },
388
388
  children: s
389
389
  }
390
390
  )
391
391
  }
392
392
  );
393
- It.__docgenInfo = {
393
+ Vt.__docgenInfo = {
394
394
  displayName: "EmptyAndSpin",
395
395
  description: "空状态和加载状态组合组件",
396
396
  props: {
@@ -433,24 +433,24 @@ It.__docgenInfo = {
433
433
  }
434
434
  }
435
435
  };
436
- const Vt = ({
436
+ const Pt = ({
437
437
  onClick: t,
438
- showText: u = !1,
438
+ showText: d = !1,
439
439
  className: i,
440
440
  size: s = "small",
441
- type: f = "default"
441
+ type: u = "default"
442
442
  }) => /* @__PURE__ */ S(
443
- Se,
443
+ Ce,
444
444
  {
445
445
  size: s,
446
- type: f,
447
- icon: /* @__PURE__ */ S(wt, {}),
446
+ type: u,
447
+ icon: /* @__PURE__ */ S(Et, {}),
448
448
  className: `cursor-pointer ${i || ""}`,
449
449
  onClick: t,
450
- children: u && "返回"
450
+ children: d && "返回"
451
451
  }
452
452
  );
453
- Vt.__docgenInfo = {
453
+ Pt.__docgenInfo = {
454
454
  displayName: "BackButton",
455
455
  description: "返回按钮组件",
456
456
  props: {
@@ -489,14 +489,14 @@ Vt.__docgenInfo = {
489
489
  }
490
490
  }
491
491
  };
492
- const Pt = ({
492
+ const Bt = ({
493
493
  removePadding: t = !0,
494
- className: u,
494
+ className: d,
495
495
  ...i
496
496
  }) => {
497
- const s = t ? `px-0 h-auto ${u || ""}` : u;
497
+ const s = t ? `px-0 h-auto ${d || ""}` : d;
498
498
  return /* @__PURE__ */ S(
499
- Se,
499
+ Ce,
500
500
  {
501
501
  type: "link",
502
502
  ...i,
@@ -505,7 +505,7 @@ const Pt = ({
505
505
  }
506
506
  );
507
507
  };
508
- Pt.__docgenInfo = {
508
+ Bt.__docgenInfo = {
509
509
  displayName: "LinkButton",
510
510
  description: "链接样式按钮组件,适用于表格操作列",
511
511
  props: {
@@ -542,87 +542,87 @@ Pt.__docgenInfo = {
542
542
  }
543
543
  }
544
544
  };
545
- const { Option: Bt } = Pe, Ot = ({
545
+ const { Option: Ot } = Pe, Ht = ({
546
546
  columns: t,
547
- request: u,
547
+ request: d,
548
548
  searchFields: i = [],
549
549
  showSearch: s = !0,
550
- showRefresh: f = !0,
550
+ showRefresh: u = !0,
551
551
  defaultPageSize: E = 10,
552
- pageSizeOptions: q = ["10", "20", "50", "100"],
553
- autoLoad: w = !0,
552
+ pageSizeOptions: T = ["10", "20", "50", "100"],
553
+ autoLoad: b = !0,
554
554
  externalParams: g = {},
555
555
  ...e
556
556
  }) => {
557
- const [C, y] = Z([]), [c, r] = Z(!1), [n, a] = Z({
557
+ const [C, m] = ee([]), [c, r] = ee(!1), [n, a] = ee({
558
558
  current: 1,
559
559
  pageSize: E,
560
560
  total: 0
561
- }), [o, p] = Z({}), [l, x] = Z({}), [T] = De.useForm(), P = ne(n);
561
+ }), [o, p] = ee({}), [l, x] = ee({}), [A] = Me.useForm(), P = ne(n);
562
562
  P.current = n;
563
563
  const k = ne(g);
564
564
  k.current = g;
565
- const G = ne(!1), R = et(() => t.map((h) => {
566
- const { sortable: d, render: v, ..._ } = h;
565
+ const G = ne(!1), R = tt(() => t.map((h) => {
566
+ const { sortable: f, render: w, ...q } = h;
567
567
  return {
568
- ..._,
569
- sorter: d ? !0 : void 0,
570
- render: v || ((L) => L)
568
+ ...q,
569
+ sorter: f ? !0 : void 0,
570
+ render: w || ((N) => N)
571
571
  };
572
- }), [t]), M = se(async (h = {}) => {
573
- if (u) {
572
+ }), [t]), D = le(async (h = {}) => {
573
+ if (d) {
574
574
  r(!0);
575
575
  try {
576
- const d = {
576
+ const f = {
577
577
  page: P.current.current,
578
578
  pageSize: P.current.pageSize,
579
579
  sortField: l.field,
580
580
  sortOrder: l.order,
581
581
  searchParams: { ...o, ...k.current },
582
582
  ...h
583
- }, v = await u(d);
584
- v.success && (y(v.data), a((_) => ({
585
- ..._,
586
- total: v.total,
587
- current: d.page || _.current
583
+ }, w = await d(f);
584
+ w.success && (m(w.data), a((q) => ({
585
+ ...q,
586
+ total: w.total,
587
+ current: f.page || q.current
588
588
  })));
589
- } catch (d) {
590
- console.error("加载数据失败:", d);
589
+ } catch (f) {
590
+ console.error("加载数据失败:", f);
591
591
  } finally {
592
592
  r(!1);
593
593
  }
594
594
  }
595
- }, [u, l, o]), F = se((h) => {
596
- p(h), a((d) => ({ ...d, current: 1 }));
597
- }, []), O = se(() => {
598
- T.resetFields(), p({}), a((h) => ({ ...h, current: 1 }));
599
- }, [T]), te = se(() => {
600
- M();
601
- }, [M]), de = se((h, d, v) => {
602
- const _ = {
595
+ }, [d, l, o]), F = le((h) => {
596
+ p(h), a((f) => ({ ...f, current: 1 }));
597
+ }, []), B = le(() => {
598
+ A.resetFields(), p({}), a((h) => ({ ...h, current: 1 }));
599
+ }, [A]), Z = le(() => {
600
+ D();
601
+ }, [D]), ie = le((h, f, w) => {
602
+ const q = {
603
603
  current: h.current || 1,
604
604
  pageSize: h.pageSize || E,
605
605
  total: h.total || 0
606
- }, L = {
607
- field: v?.field,
608
- order: v?.order
606
+ }, N = {
607
+ field: w?.field,
608
+ order: w?.order
609
609
  };
610
- a(_), x(L);
610
+ a(q), x(N);
611
611
  }, [E]);
612
- return ue(() => {
612
+ return pe(() => {
613
613
  const h = Object.keys(g).length > 0;
614
- (w && !G.current || h) && (M(), G.current = !0);
615
- }, [w, g, M]), /* @__PURE__ */ oe("div", { children: [
616
- s && i.length > 0 && /* @__PURE__ */ S(Re, { size: "small", style: { marginBottom: 16 }, children: /* @__PURE__ */ oe(
617
- De,
614
+ (b && !G.current || h) && (D(), G.current = !0);
615
+ }, [b, g, D]), /* @__PURE__ */ re("div", { children: [
616
+ s && i.length > 0 && /* @__PURE__ */ S(Re, { size: "small", style: { marginBottom: 16 }, children: /* @__PURE__ */ re(
617
+ Me,
618
618
  {
619
- form: T,
619
+ form: A,
620
620
  layout: "inline",
621
621
  onFinish: F,
622
- initialValues: i.reduce((h, d) => (d.defaultValue !== void 0 && (h[d.key] = d.defaultValue), h), {}),
622
+ initialValues: i.reduce((h, f) => (f.defaultValue !== void 0 && (h[f.key] = f.defaultValue), h), {}),
623
623
  children: [
624
- i.map((h) => /* @__PURE__ */ S(De.Item, { name: h.key, label: h.label, children: h.type === "input" ? /* @__PURE__ */ S(
625
- tt,
624
+ i.map((h) => /* @__PURE__ */ S(Me.Item, { name: h.key, label: h.label, children: h.type === "input" ? /* @__PURE__ */ S(
625
+ nt,
626
626
  {
627
627
  placeholder: h.placeholder || `请输入${h.label}`,
628
628
  style: { width: 200 }
@@ -633,13 +633,13 @@ const { Option: Bt } = Pe, Ot = ({
633
633
  placeholder: h.placeholder || `请选择${h.label}`,
634
634
  style: { width: 200 },
635
635
  allowClear: !0,
636
- children: h.options?.map((d) => /* @__PURE__ */ S(Bt, { value: d.value, children: d.label }, d.value))
636
+ children: h.options?.map((f) => /* @__PURE__ */ S(Ot, { value: f.value, children: f.label }, f.value))
637
637
  }
638
638
  ) }, h.key)),
639
- /* @__PURE__ */ S(De.Item, { children: /* @__PURE__ */ oe(yt, { children: [
640
- /* @__PURE__ */ S(Se, { type: "primary", htmlType: "submit", icon: /* @__PURE__ */ S($t, {}), children: "查询" }),
641
- /* @__PURE__ */ S(Se, { onClick: O, children: "重置" }),
642
- f && /* @__PURE__ */ S(Se, { icon: /* @__PURE__ */ S(Et, {}), onClick: te, children: "刷新" })
639
+ /* @__PURE__ */ S(Me.Item, { children: /* @__PURE__ */ re(yt, { children: [
640
+ /* @__PURE__ */ S(Ce, { type: "primary", htmlType: "submit", icon: /* @__PURE__ */ S($t, {}), children: "查询" }),
641
+ /* @__PURE__ */ S(Ce, { onClick: B, children: "重置" }),
642
+ u && /* @__PURE__ */ S(Ce, { icon: /* @__PURE__ */ S(Ct, {}), onClick: Z, children: "刷新" })
643
643
  ] }) })
644
644
  ]
645
645
  }
@@ -655,16 +655,16 @@ const { Option: Bt } = Pe, Ot = ({
655
655
  ...n,
656
656
  showSizeChanger: !0,
657
657
  showQuickJumper: !0,
658
- showTotal: (h, d) => `第 ${d[0]}-${d[1]} 条/共 ${h} 条`,
659
- pageSizeOptions: q
658
+ showTotal: (h, f) => `第 ${f[0]}-${f[1]} 条/共 ${h} 条`,
659
+ pageSizeOptions: T
660
660
  },
661
- onChange: de,
661
+ onChange: ie,
662
662
  scroll: { x: "max-content", y: "50vh" }
663
663
  }
664
664
  )
665
665
  ] });
666
666
  };
667
- Ot.__docgenInfo = {
667
+ Ht.__docgenInfo = {
668
668
  displayName: "AdvancedTable",
669
669
  description: "高阶表格组件,支持异步请求、搜索、排序等功能",
670
670
  props: {
@@ -731,22 +731,22 @@ Ot.__docgenInfo = {
731
731
  }
732
732
  }
733
733
  };
734
- function He(t, u, i) {
734
+ function He(t, d, i) {
735
735
  if (!t.current) return;
736
- const s = /* @__PURE__ */ new Set(), f = {};
737
- for (const y of u)
738
- y.exclusionGroup && y.exclusionGroup !== "separator" && (s.add(y.exclusionGroup), f[y.exclusionGroup] || (f[y.exclusionGroup] = []), f[y.exclusionGroup].push({
739
- type: y.type,
740
- key: y.key,
741
- exclusionGroup: y.exclusionGroup
736
+ const s = /* @__PURE__ */ new Set(), u = {};
737
+ for (const m of d)
738
+ m.exclusionGroup && m.exclusionGroup !== "separator" && (s.add(m.exclusionGroup), u[m.exclusionGroup] || (u[m.exclusionGroup] = []), u[m.exclusionGroup].push({
739
+ type: m.type,
740
+ key: m.key,
741
+ exclusionGroup: m.exclusionGroup
742
742
  }));
743
743
  const E = {};
744
- for (const y of s) {
745
- E[y] = !1;
746
- for (const c of f[y])
744
+ for (const m of s) {
745
+ E[m] = !1;
746
+ for (const c of u[m])
747
747
  if (c.type === "upload" && c.key) {
748
748
  if (i[c.key] !== null && i[c.key] !== void 0) {
749
- E[y] = !0;
749
+ E[m] = !0;
750
750
  break;
751
751
  }
752
752
  } else if ((c.type === "variable" || c.type === "multi-variable") && c.key) {
@@ -757,29 +757,29 @@ function He(t, u, i) {
757
757
  )].filter(Boolean);
758
758
  for (const n of r)
759
759
  if (!n.classList.contains("show-placeholder") && n.innerText.replace(/[\u200B\n]/g, "").trim().length > 0) {
760
- E[y] = !0;
760
+ E[m] = !0;
761
761
  break;
762
762
  }
763
- if (E[y])
763
+ if (E[m])
764
764
  break;
765
765
  }
766
766
  }
767
- const q = u.some((y) => y.exclusionGroup === "separator"), g = Object.keys(E).filter(
768
- (y) => E[y]
767
+ const T = d.some((m) => m.exclusionGroup === "separator"), g = Object.keys(E).filter(
768
+ (m) => E[m]
769
769
  ).length > 0;
770
770
  let e = null;
771
- if (g && q) {
772
- for (const y of u)
773
- if (y.exclusionGroup && y.exclusionGroup !== "separator" && E[y.exclusionGroup]) {
774
- e = y.exclusionGroup;
771
+ if (g && T) {
772
+ for (const m of d)
773
+ if (m.exclusionGroup && m.exclusionGroup !== "separator" && E[m.exclusionGroup]) {
774
+ e = m.exclusionGroup;
775
775
  break;
776
776
  }
777
777
  }
778
- for (const y of s) {
778
+ for (const m of s) {
779
779
  const c = t.current.querySelectorAll(
780
- `[data-group="${y}"]`
780
+ `[data-group="${m}"]`
781
781
  );
782
- q && g && e ? y === e ? c.forEach((r) => {
782
+ T && g && e ? m === e ? c.forEach((r) => {
783
783
  r.classList.contains("required-upload-group") ? r.style.setProperty("display", "inline-flex", "important") : (r.classList.contains("exclusion-wrapper"), r.style.setProperty("display", "inline-block", "important"));
784
784
  }) : c.forEach((r) => {
785
785
  r.style.display = "none", r.style.setProperty("display", "none", "important");
@@ -789,20 +789,20 @@ function He(t, u, i) {
789
789
  }
790
790
  t.current.querySelectorAll(
791
791
  '[data-group="separator"]'
792
- ).forEach((y) => {
793
- y.style.display = g ? "none" : "inline";
792
+ ).forEach((m) => {
793
+ m.style.display = g ? "none" : "inline";
794
794
  });
795
795
  }
796
- function Ge(t, u, i, s) {
796
+ function Ge(t, d, i, s) {
797
797
  if (!t.current) {
798
798
  s(!1);
799
799
  return;
800
800
  }
801
- const f = [];
802
- for (let c = 0; c < u.length; c++) {
803
- const r = u[c];
801
+ const u = [];
802
+ for (let c = 0; c < d.length; c++) {
803
+ const r = d[c];
804
804
  if ((r.type === "variable" || r.type === "upload" || r.type === "multi-variable" || r.type === "select" || r.type === "textarea" || r.type === "richtext" || r.type === "datepicker") && r.required && r.key) {
805
- f.push({
805
+ u.push({
806
806
  exclusionGroup: r.exclusionGroup || "",
807
807
  key: r.key,
808
808
  type: r.type === "multi-variable" ? "variable" : r.type,
@@ -814,10 +814,10 @@ function Ge(t, u, i, s) {
814
814
  }
815
815
  if (r.type === "text" && r.className?.includes("rte-text-required"))
816
816
  if (r.exclusionGroup)
817
- for (let n = c + 1; n < u.length; n++) {
818
- const a = u[n];
817
+ for (let n = c + 1; n < d.length; n++) {
818
+ const a = d[n];
819
819
  if (a.exclusionGroup === r.exclusionGroup && (a.type === "variable" || a.type === "upload" || a.type === "select" || a.type === "textarea" || a.type === "richtext" || a.type === "datepicker") && a.key) {
820
- f.push({
820
+ u.push({
821
821
  exclusionGroup: r.exclusionGroup,
822
822
  key: a.key,
823
823
  type: a.type,
@@ -827,10 +827,10 @@ function Ge(t, u, i, s) {
827
827
  }
828
828
  }
829
829
  else
830
- for (let n = c + 1; n < u.length; n++) {
831
- const a = u[n];
830
+ for (let n = c + 1; n < d.length; n++) {
831
+ const a = d[n];
832
832
  if ((a.type === "variable" || a.type === "upload" || a.type === "select" || a.type === "textarea" || a.type === "richtext" || a.type === "datepicker") && a.key) {
833
- f.push({
833
+ u.push({
834
834
  exclusionGroup: a.exclusionGroup || "",
835
835
  key: a.key,
836
836
  type: a.type,
@@ -840,19 +840,19 @@ function Ge(t, u, i, s) {
840
840
  }
841
841
  }
842
842
  }
843
- const E = u.some((c) => c.exclusionGroup === "separator"), q = [];
844
- if (E && f.length > 1) {
843
+ const E = d.some((c) => c.exclusionGroup === "separator"), T = [];
844
+ if (E && u.length > 1) {
845
845
  const c = [];
846
- u.forEach((r, n) => {
846
+ d.forEach((r, n) => {
847
847
  r.exclusionGroup === "separator" && c.push(n);
848
848
  });
849
849
  for (const r of c) {
850
- const a = f.filter((l) => typeof l.__index == "number" && l.__index < r).sort((l, x) => (x.__index ?? 0) - (l.__index ?? 0))[0], p = f.filter((l) => typeof l.__index == "number" && l.__index > r).sort((l, x) => (l.__index ?? 0) - (x.__index ?? 0))[0];
851
- a && p && q.push([a, p]);
850
+ const a = u.filter((l) => typeof l.__index == "number" && l.__index < r).sort((l, x) => (x.__index ?? 0) - (l.__index ?? 0))[0], p = u.filter((l) => typeof l.__index == "number" && l.__index > r).sort((l, x) => (l.__index ?? 0) - (x.__index ?? 0))[0];
851
+ a && p && T.push([a, p]);
852
852
  }
853
853
  }
854
- if (f.length === 0) {
855
- if (u.length === 0) {
854
+ if (u.length === 0) {
855
+ if (d.length === 0) {
856
856
  if (!t.current) {
857
857
  s(!1);
858
858
  return;
@@ -864,7 +864,7 @@ function Ge(t, u, i, s) {
864
864
  s(!0);
865
865
  return;
866
866
  }
867
- const w = f.filter((c) => {
867
+ const b = u.filter((c) => {
868
868
  if (!t.current) return !1;
869
869
  if (c.exclusionGroup) {
870
870
  const r = t.current.querySelectorAll(
@@ -932,21 +932,21 @@ function Ge(t, u, i, s) {
932
932
  }
933
933
  return !1;
934
934
  });
935
- if (w.length === 0) {
935
+ if (b.length === 0) {
936
936
  s(!0);
937
937
  return;
938
938
  }
939
939
  const g = /* @__PURE__ */ new Set();
940
- q.forEach((c) => {
940
+ T.forEach((c) => {
941
941
  c.forEach((r) => {
942
942
  r.key && g.add(r.key);
943
943
  });
944
944
  });
945
- const e = w.filter(
945
+ const e = b.filter(
946
946
  (c) => !c.key || !g.has(c.key)
947
947
  );
948
- let C = (q.length === 0, !0);
949
- for (const c of q) {
948
+ let C = (T.length === 0, !0);
949
+ for (const c of T) {
950
950
  const r = c.filter((a) => {
951
951
  if (!t.current) return !1;
952
952
  if (a.exclusionGroup) {
@@ -971,8 +971,8 @@ function Ge(t, u, i, s) {
971
971
  if (p.length === 0)
972
972
  continue;
973
973
  for (let l = 0; l < p.length; l++) {
974
- const T = p[l].dataset.key;
975
- T && i[T] != null && (o += 1);
974
+ const A = p[l].dataset.key;
975
+ A && i[A] != null && (o += 1);
976
976
  }
977
977
  if (o >= a.minCount) {
978
978
  n = !0;
@@ -1049,7 +1049,7 @@ function Ge(t, u, i, s) {
1049
1049
  break;
1050
1050
  }
1051
1051
  }
1052
- let y = !0;
1052
+ let m = !0;
1053
1053
  for (const c of e)
1054
1054
  if (c.type === "upload" && c.key) {
1055
1055
  if (c.minCount && c.minCount > 0) {
@@ -1058,7 +1058,7 @@ function Ge(t, u, i, s) {
1058
1058
  `[data-type="upload"][data-batch-key="${c.key}"]`
1059
1059
  );
1060
1060
  if (n.length === 0) {
1061
- y = !1;
1061
+ m = !1;
1062
1062
  break;
1063
1063
  }
1064
1064
  for (let a = 0; a < n.length; a++) {
@@ -1066,11 +1066,11 @@ function Ge(t, u, i, s) {
1066
1066
  p && i[p] != null && (r += 1);
1067
1067
  }
1068
1068
  if (r < c.minCount) {
1069
- y = !1;
1069
+ m = !1;
1070
1070
  break;
1071
1071
  }
1072
1072
  } else if (i[c.key] === null || i[c.key] === void 0) {
1073
- y = !1;
1073
+ m = !1;
1074
1074
  break;
1075
1075
  }
1076
1076
  } else if (c.type === "variable" && c.key)
@@ -1086,7 +1086,7 @@ function Ge(t, u, i, s) {
1086
1086
  }
1087
1087
  const a = c.minCount && c.minCount > 0 ? c.minCount : 1;
1088
1088
  if (n < a) {
1089
- y = !1;
1089
+ m = !1;
1090
1090
  break;
1091
1091
  }
1092
1092
  } else {
@@ -1094,15 +1094,15 @@ function Ge(t, u, i, s) {
1094
1094
  `[data-type="variable"][data-key="${c.key}"]`
1095
1095
  );
1096
1096
  if (!r) {
1097
- y = !1;
1097
+ m = !1;
1098
1098
  break;
1099
1099
  }
1100
1100
  if (r.classList.contains("show-placeholder")) {
1101
- y = !1;
1101
+ m = !1;
1102
1102
  break;
1103
1103
  }
1104
1104
  if (r.innerText.replace(/[\u200B\n]/g, "").trim().length === 0) {
1105
- y = !1;
1105
+ m = !1;
1106
1106
  break;
1107
1107
  }
1108
1108
  }
@@ -1111,7 +1111,7 @@ function Ge(t, u, i, s) {
1111
1111
  `[data-type="select"][data-key="${c.key}"]`
1112
1112
  );
1113
1113
  if (!r || (r.getAttribute("data-value") || "").trim().length === 0) {
1114
- y = !1;
1114
+ m = !1;
1115
1115
  break;
1116
1116
  }
1117
1117
  } else if (c.type === "textarea" && c.key) {
@@ -1119,7 +1119,7 @@ function Ge(t, u, i, s) {
1119
1119
  `[data-type="textarea"][data-key="${c.key}"]`
1120
1120
  );
1121
1121
  if (!r || (r.value || "").trim().length === 0) {
1122
- y = !1;
1122
+ m = !1;
1123
1123
  break;
1124
1124
  }
1125
1125
  } else if (c.type === "richtext" && c.key) {
@@ -1127,7 +1127,7 @@ function Ge(t, u, i, s) {
1127
1127
  `[data-type="richtext"][data-key="${c.key}"]`
1128
1128
  );
1129
1129
  if (!r || (r.textContent || "").replace(/[\u200B]/g, "").trim().length === 0) {
1130
- y = !1;
1130
+ m = !1;
1131
1131
  break;
1132
1132
  }
1133
1133
  } else if (c.type === "datepicker" && c.key) {
@@ -1135,40 +1135,40 @@ function Ge(t, u, i, s) {
1135
1135
  `[data-type="datepicker"][data-key="${c.key}"]`
1136
1136
  );
1137
1137
  if (!r || (r.getAttribute("data-value") || "").trim().length === 0) {
1138
- y = !1;
1138
+ m = !1;
1139
1139
  break;
1140
1140
  }
1141
1141
  }
1142
- s(C && y);
1142
+ s(C && m);
1143
1143
  }
1144
- function Oe(t, u) {
1144
+ function Oe(t, d) {
1145
1145
  if (!t.current) return;
1146
1146
  t.current.querySelectorAll('[data-type="variable"]').forEach((s) => {
1147
- const f = s.innerText;
1148
- f.replace(/\u200B/g, "").trim().length === 0 ? (f !== "​" && (s.innerText = "​"), s.classList.add("show-placeholder")) : s.classList.remove("show-placeholder");
1147
+ const u = s.innerText;
1148
+ u.replace(/\u200B/g, "").trim().length === 0 ? (u !== "​" && (s.innerText = "​"), s.classList.add("show-placeholder")) : s.classList.remove("show-placeholder");
1149
1149
  });
1150
1150
  }
1151
- const Ht = ({ host: t, onChange: u }) => {
1152
- const i = t.dataset.key, s = t.dataset.placeholder, f = t.dataset.options ? decodeURIComponent(t.dataset.options) : "[]", E = t.dataset.required === "true", q = t.dataset.value || "", w = ut.useMemo(() => {
1151
+ const Gt = ({ host: t, onChange: d }) => {
1152
+ const i = t.dataset.key, s = t.dataset.placeholder, u = t.dataset.options ? decodeURIComponent(t.dataset.options) : "[]", E = t.dataset.required === "true", T = t.dataset.value || "", b = dt.useMemo(() => {
1153
1153
  try {
1154
- return JSON.parse(f);
1154
+ return JSON.parse(u);
1155
1155
  } catch {
1156
1156
  return [];
1157
1157
  }
1158
- }, [f]), [g, e] = Z(q || void 0), [C, y] = Z(80), c = (n) => {
1158
+ }, [u]), [g, e] = ee(T || void 0), [C, m] = ee(80), c = (n) => {
1159
1159
  const o = document.createElement("canvas").getContext("2d");
1160
1160
  return o ? (o.font = '14px -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif', o.measureText(n).width) : n.length * 14;
1161
1161
  };
1162
- ue(() => {
1163
- const n = g ? w.find((p) => p.value === g)?.label || g : s || "请选择", a = c(n), o = Math.max(64, Math.ceil(a + 40));
1164
- y(o);
1165
- }, [g, w, s]);
1162
+ pe(() => {
1163
+ const n = g ? b.find((p) => p.value === g)?.label || g : s || "请选择", a = c(n), o = Math.max(64, Math.ceil(a + 40));
1164
+ m(o);
1165
+ }, [g, b, s]);
1166
1166
  const r = (n) => {
1167
- e(n), t.setAttribute("data-value", n), u(i, n);
1167
+ e(n), t.setAttribute("data-value", n), d(i, n);
1168
1168
  };
1169
- return ue(() => {
1170
- e(q || void 0);
1171
- }, [q]), ze(
1169
+ return pe(() => {
1170
+ e(T || void 0);
1171
+ }, [T]), ze(
1172
1172
  /* @__PURE__ */ S(
1173
1173
  "div",
1174
1174
  {
@@ -1182,7 +1182,7 @@ const Ht = ({ host: t, onChange: u }) => {
1182
1182
  onChange: r,
1183
1183
  placeholder: s || "请选择",
1184
1184
  style: { width: "100%", minWidth: C },
1185
- options: w,
1185
+ options: b,
1186
1186
  allowClear: !E,
1187
1187
  size: "small",
1188
1188
  dropdownClassName: "rte-select-dropdown",
@@ -1195,18 +1195,18 @@ const Ht = ({ host: t, onChange: u }) => {
1195
1195
  ),
1196
1196
  t
1197
1197
  );
1198
- }, Gt = (t) => {
1199
- const [u, i] = Z([]);
1200
- return ue(() => {
1198
+ }, Rt = (t) => {
1199
+ const [d, i] = ee([]);
1200
+ return pe(() => {
1201
1201
  const s = t.current;
1202
1202
  if (!s) return;
1203
- const f = () => {
1204
- const q = s.querySelectorAll(".rte-select-host"), w = [];
1205
- q.forEach((g) => {
1203
+ const u = () => {
1204
+ const T = s.querySelectorAll(".rte-select-host"), b = [];
1205
+ T.forEach((g) => {
1206
1206
  const e = g.getAttribute("data-key");
1207
- e && w.push(
1207
+ e && b.push(
1208
1208
  /* @__PURE__ */ S(
1209
- Ht,
1209
+ Gt,
1210
1210
  {
1211
1211
  host: g,
1212
1212
  onChange: () => {
@@ -1219,154 +1219,154 @@ const Ht = ({ host: t, onChange: u }) => {
1219
1219
  `select-${e}`
1220
1220
  )
1221
1221
  );
1222
- }), i(w);
1222
+ }), i(b);
1223
1223
  };
1224
- f();
1225
- const E = new MutationObserver((q) => {
1226
- let w = !1;
1227
- for (const g of q)
1224
+ u();
1225
+ const E = new MutationObserver((T) => {
1226
+ let b = !1;
1227
+ for (const g of T)
1228
1228
  if (g.type === "childList") {
1229
1229
  let e = !1;
1230
1230
  if (g.addedNodes.forEach((C) => {
1231
1231
  if (C.nodeType === Node.ELEMENT_NODE) {
1232
- const y = C;
1233
- (y.classList?.contains("rte-select-host") || y.querySelector?.(".rte-select-host")) && (e = !0);
1232
+ const m = C;
1233
+ (m.classList?.contains("rte-select-host") || m.querySelector?.(".rte-select-host")) && (e = !0);
1234
1234
  }
1235
1235
  }), g.removedNodes.forEach((C) => {
1236
1236
  if (C.nodeType === Node.ELEMENT_NODE) {
1237
- const y = C;
1238
- (y.classList?.contains("rte-select-host") || y.querySelector?.(".rte-select-host")) && (e = !0);
1237
+ const m = C;
1238
+ (m.classList?.contains("rte-select-host") || m.querySelector?.(".rte-select-host")) && (e = !0);
1239
1239
  }
1240
1240
  }), e) {
1241
- w = !0;
1241
+ b = !0;
1242
1242
  break;
1243
1243
  }
1244
1244
  }
1245
- w && f();
1245
+ b && u();
1246
1246
  });
1247
1247
  return E.observe(s, { childList: !0, subtree: !0 }), () => E.disconnect();
1248
- }, [t]), u;
1248
+ }, [t]), d;
1249
1249
  };
1250
- function Rt(t, u, i, s, f, E = {}, q) {
1250
+ function Ft(t, d, i, s, u, E = {}, T) {
1251
1251
  if (!t.current) return;
1252
- let w = "", g = 0;
1253
- for (; g < u.length; ) {
1254
- const e = u[g], C = g + 1 < u.length ? u[g + 1] : null;
1252
+ let b = "", g = 0;
1253
+ for (; g < d.length; ) {
1254
+ const e = d[g], C = g + 1 < d.length ? d[g + 1] : null;
1255
1255
  if (e.type === "text" && (e.text?.includes("icon-bitian") || e.className === "rte-text-required") && C) {
1256
1256
  const o = C.type === "upload" && C.exclusionGroup === "fileInput" && e.exclusionGroup === "fileInput" && e.exclusionGroup === C.exclusionGroup, p = C.type === "variable" && C.exclusionGroup === "textInput" && e.exclusionGroup === "textInput" && e.exclusionGroup === C.exclusionGroup;
1257
1257
  if (o) {
1258
- const l = e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : "", x = `<span ${l} class="exclusion-wrapper required-upload-group">`, T = "</span>";
1258
+ const l = e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : "", x = `<span ${l} class="exclusion-wrapper required-upload-group">`, A = "</span>";
1259
1259
  let P = "";
1260
1260
  e.className ? P = `<span class="${e.className}">${e.text ?? ""}</span>` : P = e.text ?? "";
1261
- const k = C, G = i[k.key] !== null && i[k.key] !== void 0, R = G ? i[k.key] : null, M = G ? i[k.key]?.name : k.text, F = G ? "" : "hidden", O = k.tooltip && !G ? "" : "hidden", te = G ? "has-file" : "", de = G && M ? ` data-file-name="${M.replace(/"/g, "&quot;")}"` : "";
1261
+ const k = C, G = i[k.key] !== null && i[k.key] !== void 0, R = G ? i[k.key] : null, D = G ? i[k.key]?.name : k.text, F = G ? "" : "hidden", B = k.tooltip && !G ? "" : "hidden", Z = G ? "has-file" : "", ie = G && D ? ` data-file-name="${D.replace(/"/g, "&quot;")}"` : "";
1262
1262
  let h = "";
1263
1263
  G && R ? R.type?.startsWith("image/") ? h = `<img class="upload-icon-img upload-icon-preview" src="${URL.createObjectURL(R)}" alt="preview" />` : h = "<i class='iconfont icon-exlwenjian'></i>" : h = "<i class='iconfont icon-shangchuan1'></i>";
1264
- const d = G && k.text ? `<span ${l} contenteditable="false" class="exclusion-wrapper upload-hint">${k.text}</span>` : "", v = `<span contenteditable="false" data-type="upload" data-key="${k.key}" class="upload-chip"><span class="upload-inner-wrapper ${te}"><span class="upload-icon">${h}</span><span class="upload-label"${de}>${M || k.text}</span>${k.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi upload-info-icon ${O}" data-upload-key="${k.key}" data-tooltip="${k.tooltip}" title="提示"></i>` : ""}<span class="file-remove-btn ${F}" title="移除文件">×</span></span></span>`;
1265
- w += x + P + v + T + d, g += 2;
1264
+ const f = (k.text || "").trim(), q = G && f.length >= 12 ? `<span ${l} contenteditable="false" class="exclusion-wrapper upload-hint">${f}</span>` : "", N = `<span contenteditable="false" data-type="upload" data-key="${k.key}" class="upload-chip"><span class="upload-inner-wrapper ${Z}"><span class="upload-icon">${h}</span><span class="upload-label"${ie}>${D || k.text}</span>${k.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi upload-info-icon ${B}" data-upload-key="${k.key}" data-tooltip="${k.tooltip}" title="提示"></i>` : ""}<span class="file-remove-btn ${F}" title="移除文件">×</span></span></span>`;
1265
+ b += x + P + N + A + q, g += 2;
1266
1266
  continue;
1267
1267
  }
1268
1268
  if (p) {
1269
- const x = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group">`, T = "</span>";
1269
+ const x = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group">`, A = "</span>";
1270
1270
  let P = "";
1271
1271
  e.className ? P = `<span class="${e.className}">${e.text ?? ""}</span>` : P = e.text ?? "";
1272
- const k = C, R = (k.key ? f[k.key] : void 0) || k.text || "", M = !R, F = M ? "​" : R, O = M ? "show-placeholder" : "", te = k.exclusionGroup ? ` data-group="${k.exclusionGroup}"` : "", de = k.tooltip ? ` data-tooltip="${k.tooltip.replace(/"/g, "&quot;")}" data-variable-key="${k.key || ""}"` : "", h = k.tooltip && M ? "" : "hidden", d = `<span contenteditable="true" data-type="variable" data-key="${k.key}" data-placeholder="${k.placeholder || ""}"${te}${de} class="variable-chip ${O}">${F}${k.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi variable-info-icon ${h}" data-variable-key="${k.key}" data-tooltip="${k.tooltip.replace(/"/g, "&quot;")}" title="提示"></i>` : ""}</span>`;
1273
- w += x + P + d + T, g += 2;
1272
+ const k = C, R = (k.key ? u[k.key] : void 0) || k.text || "", D = !R, F = D ? "​" : R, B = D ? "show-placeholder" : "", Z = k.exclusionGroup ? ` data-group="${k.exclusionGroup}"` : "", ie = k.tooltip ? ` data-tooltip="${k.tooltip.replace(/"/g, "&quot;")}" data-variable-key="${k.key || ""}"` : "", h = k.tooltip && D ? "" : "hidden", f = `<span contenteditable="true" data-type="variable" data-key="${k.key}" data-placeholder="${k.placeholder || ""}"${Z}${ie} class="variable-chip ${B}">${F}${k.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi variable-info-icon ${h}" data-variable-key="${k.key}" data-tooltip="${k.tooltip.replace(/"/g, "&quot;")}" title="提示"></i>` : ""}</span>`;
1273
+ b += x + P + f + A, g += 2;
1274
1274
  continue;
1275
1275
  }
1276
1276
  }
1277
1277
  const c = e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : "", r = e.exclusionGroup ? `<span ${c} class="exclusion-wrapper">` : "", n = e.exclusionGroup ? "</span>" : "";
1278
1278
  let a = "";
1279
1279
  if (e.type === "tag") {
1280
- const p = s || q === "hideTagClose" ? "" : '<span class="tag-close-btn" title="Clear (ESC)"><svg width="10" height="10" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="4" stroke-linecap="round" stroke-linejoin="round"><path d="M18 6L6 18M6 6l12 12"/></svg></span>', l = s ? ' data-locked="true"' : "", x = e.tooltip ? ` data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" data-tag-key="${e.key || ""}"` : "";
1280
+ const p = s || T === "hideTagClose" ? "" : '<span class="tag-close-btn" title="Clear (ESC)"><svg width="10" height="10" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="4" stroke-linecap="round" stroke-linejoin="round"><path d="M18 6L6 18M6 6l12 12"/></svg></span>', l = s ? ' data-locked="true"' : "", x = e.tooltip ? ` data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" data-tag-key="${e.key || ""}"` : "";
1281
1281
  a = `<span contenteditable="false" class="tag-node group"${l}${x}><span class="tag-label">${e.text}</span>${p}</span>`;
1282
1282
  } else if (e.type === "text") {
1283
1283
  const o = s ? ' data-locked="true" contenteditable="false"' : ' contenteditable="false"', l = (e.text ?? "").replace(/\n/g, "<br/>");
1284
1284
  e.className ? a = `<span data-type="text" class="${e.className}"${o}>${l}</span>` : a = s ? `<span data-type="text"${o}>${l}</span>` : `<span data-type="text" contenteditable="false">${l}</span>`;
1285
1285
  } else if (e.type === "variable" && e.key) {
1286
- const p = f[e.key] || e.text || "", l = !p, x = l ? "​" : p, T = l ? "show-placeholder" : "", P = e.exclusionGroup ? ` data-group="${e.exclusionGroup}"` : "", k = e.tooltip ? ` data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" data-variable-key="${e.key || ""}"` : "", G = e.tooltip && l ? "" : "hidden", R = `<span contenteditable="true" data-type="variable" data-key="${e.key}" data-placeholder="${e.placeholder || ""}"${P}${k} class="variable-chip ${T}">${x}${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi variable-info-icon ${G}" data-variable-key="${e.key}" data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" title="提示"></i>` : ""}</span>`;
1286
+ const p = u[e.key] || e.text || "", l = !p, x = l ? "​" : p, A = l ? "show-placeholder" : "", P = e.exclusionGroup ? ` data-group="${e.exclusionGroup}"` : "", k = e.tooltip ? ` data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" data-variable-key="${e.key || ""}"` : "", G = e.tooltip && l ? "" : "hidden", R = `<span contenteditable="true" data-type="variable" data-key="${e.key}" data-placeholder="${e.placeholder || ""}"${P}${k} class="variable-chip ${A}">${x}${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi variable-info-icon ${G}" data-variable-key="${e.key}" data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" title="提示"></i>` : ""}</span>`;
1287
1287
  e.required ? a = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>${R}</span>` : a = R;
1288
1288
  } else if (e.type === "upload" && e.key)
1289
- if (typeof e.maxCount == "number" && typeof e.minCount == "number") {
1289
+ if (typeof e.maxCount == "number" && typeof e.minCount == "number" && e.maxCount > 1) {
1290
1290
  const p = e.minCount || 1, l = e.maxCount || 3;
1291
1291
  let x = 0;
1292
1292
  for (let k = 0; k < l; k++) {
1293
1293
  const G = `${e.key}-${k}`;
1294
1294
  i[G] != null && (x += 1);
1295
1295
  }
1296
- const T = Math.min(
1296
+ const A = Math.min(
1297
1297
  l,
1298
1298
  Math.max(p, x + (x < l ? 1 : 0))
1299
1299
  );
1300
1300
  let P = "";
1301
- for (let k = 0; k < T; k++) {
1302
- const G = `${e.key}-${k}`, R = i[G] !== null && i[G] !== void 0, M = R ? i[G] : null, F = R ? i[G]?.name : e.text, O = R ? "" : "hidden", te = e.tooltip && !R ? "" : "hidden", de = R ? "has-file" : "", h = R && F ? ` data-file-name="${F.replace(/"/g, "&quot;")}"` : "";
1303
- let d = "";
1304
- R && M ? M.type?.startsWith("image/") ? d = `<img class="upload-icon-img upload-icon-preview" src="${URL.createObjectURL(M)}" alt="preview" />` : d = "<i class='iconfont icon-exlwenjian'></i>" : d = "<i class='iconfont icon-shangchuan1'></i>";
1305
- const v = ` data-batch-key="${e.key}"`, _ = ` data-batch-index="${k}"`, L = `<span contenteditable="false" data-type="upload" data-key="${G}"${v}${_} class="upload-chip upload-chip-batch"><span class="upload-inner-wrapper ${de}"><span class="upload-icon">${d}</span><span class="upload-label"${h}>${F || e.text}</span>${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi upload-info-icon ${te}" data-upload-key="${G}" data-tooltip="${e.tooltip}" title="提示"></i>` : ""}<span class="file-remove-btn ${O}" title="移除文件">×</span></span></span>`;
1306
- P += L;
1301
+ for (let k = 0; k < A; k++) {
1302
+ const G = `${e.key}-${k}`, R = i[G] !== null && i[G] !== void 0, D = R ? i[G] : null, F = R ? i[G]?.name : e.text, B = R ? "" : "hidden", Z = e.tooltip && !R ? "" : "hidden", ie = R ? "has-file" : "", h = R && F ? ` data-file-name="${F.replace(/"/g, "&quot;")}"` : "";
1303
+ let f = "";
1304
+ R && D ? D.type?.startsWith("image/") ? f = `<img class="upload-icon-img upload-icon-preview" src="${URL.createObjectURL(D)}" alt="preview" />` : f = "<i class='iconfont icon-exlwenjian'></i>" : f = "<i class='iconfont icon-shangchuan1'></i>";
1305
+ const w = ` data-batch-key="${e.key}"`, q = ` data-batch-index="${k}"`, N = `<span contenteditable="false" data-type="upload" data-key="${G}"${w}${q} class="upload-chip upload-chip-batch"><span class="upload-inner-wrapper ${ie}"><span class="upload-icon">${f}</span><span class="upload-label"${h}>${F || e.text}</span>${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi upload-info-icon ${Z}" data-upload-key="${G}" data-tooltip="${e.tooltip}" title="提示"></i>` : ""}<span class="file-remove-btn ${B}" title="移除文件">×</span></span></span>`;
1306
+ P += N;
1307
1307
  }
1308
1308
  e.required ? a = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group rte-required-upload-batch"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span><span class="rte-upload-batch-chips">${P}</span></span>` : a = P;
1309
1309
  } else {
1310
- const p = i[e.key] !== null && i[e.key] !== void 0, l = p ? i[e.key] : null, x = p ? i[e.key]?.name : e.text, T = p ? "" : "hidden", P = e.tooltip && !p ? "" : "hidden", k = p ? "has-file" : "", G = p && x ? ` data-file-name="${x.replace(/"/g, "&quot;")}"` : "";
1310
+ const p = i[e.key] !== null && i[e.key] !== void 0, l = p ? i[e.key] : null, x = p ? i[e.key]?.name : e.text, A = p ? "" : "hidden", P = e.tooltip && !p ? "" : "hidden", k = p ? "has-file" : "", G = p && x ? ` data-file-name="${x.replace(/"/g, "&quot;")}"` : "";
1311
1311
  let R = "";
1312
1312
  p && l ? l.type?.startsWith("image/") ? R = `<img class="upload-icon-img upload-icon-preview" src="${URL.createObjectURL(l)}" alt="preview" />` : R = "<i class='iconfont icon-exlwenjian'></i>" : R = "<i class='iconfont icon-shangchuan1'></i>";
1313
- const M = p && e.text ? `<span ${c} contenteditable="false" class="exclusion-wrapper upload-hint">${e.text}</span>` : "", F = `<span contenteditable="false" data-type="upload" data-key="${e.key}" class="upload-chip"><span class="upload-inner-wrapper ${k}"><span class="upload-icon">${R}</span><span class="upload-label"${G}>${x || e.text}</span>${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi upload-info-icon ${P}" data-upload-key="${e.key}" data-tooltip="${e.tooltip}" title="提示"></i>` : ""}<span class="file-remove-btn ${T}" title="移除文件">×</span></span></span>`;
1314
- e.required ? a = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>${F}</span>${M}` : a = F + M;
1313
+ const D = (e.text || "").trim(), B = p && D.length >= 12 ? `<span ${c} contenteditable="false" class="exclusion-wrapper upload-hint">${D}</span>` : "", Z = `<span contenteditable="false" data-type="upload" data-key="${e.key}" class="upload-chip"><span class="upload-inner-wrapper ${k}"><span class="upload-icon">${R}</span><span class="upload-label"${G}>${x || e.text}</span>${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi upload-info-icon ${P}" data-upload-key="${e.key}" data-tooltip="${e.tooltip}" title="提示"></i>` : ""}<span class="file-remove-btn ${A}" title="移除文件">×</span></span></span>`;
1314
+ e.required ? a = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>${Z}</span>${B}` : a = Z + B;
1315
1315
  }
1316
1316
  else if (e.type === "select" && e.key) {
1317
- const o = f[e.key] || e.defaultValue || "", p = encodeURIComponent(JSON.stringify(e.options || [])), l = e.placeholder ? ` data-placeholder="${e.placeholder}"` : "", x = e.exclusionGroup ? ` data-group="${e.exclusionGroup}"` : "", T = e.required ? ' data-required="true"' : "", P = `<div data-type="select" data-key="${e.key}" data-value="${o}" data-options="${p}"${l}${x}${T} class="rte-select-host"></div>`;
1317
+ const o = u[e.key] || e.defaultValue || "", p = encodeURIComponent(JSON.stringify(e.options || [])), l = e.placeholder ? ` data-placeholder="${e.placeholder}"` : "", x = e.exclusionGroup ? ` data-group="${e.exclusionGroup}"` : "", A = e.required ? ' data-required="true"' : "", P = `<div data-type="select" data-key="${e.key}" data-value="${o}" data-options="${p}"${l}${x}${A} class="rte-select-host"></div>`;
1318
1318
  e.required ? a = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>${P}</span>` : a = P;
1319
1319
  } else if (e.type === "textarea" && e.key) {
1320
- const o = f[e.key] || "", p = e.maxHeight || 252, l = e.expandable !== !1, x = e.placeholder ? ` placeholder="${e.placeholder}"` : "", T = `<textarea data-type="textarea" data-key="${e.key}" class="rte-textarea" data-max-height="${p}" style="max-height:${p}px;"${x}>${o}</textarea>`, P = l ? `<button type="button" class="rte-textarea-toggle" data-key="${e.key}" data-expanded="false">展开</button>` : "", k = `<div class="rte-textarea-wrapper" data-key="${e.key}">${T}${P}</div>`;
1320
+ const o = u[e.key] || "", p = e.maxHeight || 252, l = e.expandable !== !1, x = e.placeholder ? ` placeholder="${e.placeholder}"` : "", A = `<textarea data-type="textarea" data-key="${e.key}" class="rte-textarea" data-max-height="${p}" style="max-height:${p}px;"${x}>${o}</textarea>`, P = l ? `<button type="button" class="rte-textarea-toggle" data-key="${e.key}" data-expanded="false">展开</button>` : "", k = `<div class="rte-textarea-wrapper" data-key="${e.key}">${A}${P}</div>`;
1321
1321
  e.required ? a = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>${k}</span>` : a = k;
1322
1322
  } else if (e.type === "richtext" && e.key) {
1323
- const o = f[e.key] || e.text || "", p = e.minHeight || 140, l = e.placeholder ? ` data-placeholder="${e.placeholder}"` : "", x = e.expandable !== !1, T = o, P = `<div contenteditable="true" data-type="richtext" data-key="${e.key}" class="rte-richtext"${l} style="min-height:${p}px;">${T}</div>`, k = x ? `<button type="button" class="rte-richtext-toggle" data-key="${e.key}" data-expanded="false"><i class="iconfont icon-zhankai2"></i><span class="rte-richtext-toggle-label">展开</span></button>` : "", G = `<div class="rte-richtext-wrapper" data-key="${e.key}">${P}${k}</div>`, R = `<div class="rte-richtext-container" data-key="${e.key}">${G}</div>`;
1324
- e.required ? a = `<div ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group rte-richtext-required"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>${R}</div>` : a = R;
1323
+ const o = u[e.key] || e.text || "", p = typeof e.minHeight == "number" ? e.minHeight : 40, l = typeof e.maxHeight == "number" ? e.maxHeight : 160, x = Math.max(l, p), A = e.placeholder ? ` data-placeholder="${e.placeholder}"` : "", P = e.expandable !== !1, k = o, G = `<div contenteditable="true" data-type="richtext" data-key="${e.key}" class="rte-richtext"${A} style="min-height:${p}px;max-height:${x}px;overflow:auto;">${k}</div>`, R = P ? `<button type="button" class="rte-richtext-toggle" data-key="${e.key}" data-expanded="false"><i class="iconfont icon-zhankai2"></i><span class="rte-richtext-toggle-label">展开</span></button>` : "", D = `<div class="rte-richtext-wrapper" data-key="${e.key}">${G}${R}</div>`, F = `<div class="rte-richtext-container" data-key="${e.key}">${D}</div>`;
1324
+ e.required ? a = `<div ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper rte-richtext-required">${F}</div>` : a = F;
1325
1325
  } else if (e.type === "datepicker" && e.key) {
1326
- const o = f[e.key] || "", p = e.placeholder ? ` data-placeholder="${e.placeholder}"` : "", l = e.limitRange ? ` data-limit-range="${e.limitRange}"` : "", x = e.disableFuture ? ' data-disable-future="true"' : "", T = `<div data-type="datepicker" data-key="${e.key}" data-value="${o}" class="rte-datepicker-host"${p}${l}${x}></div>`;
1327
- e.required ? a = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>${T}</span>` : a = T;
1326
+ const o = u[e.key] || "", p = e.placeholder ? ` data-placeholder="${e.placeholder}"` : "", l = e.limitRange ? ` data-limit-range="${e.limitRange}"` : "", x = e.disableFuture ? ' data-disable-future="true"' : "", A = `<div data-type="datepicker" data-key="${e.key}" data-value="${o}" class="rte-datepicker-host"${p}${l}${x}></div>`;
1327
+ e.required ? a = `<span ${e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : ""} class="exclusion-wrapper required-upload-group"><span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>${A}</span>` : a = A;
1328
1328
  } else if (e.type === "multi-variable" && e.key) {
1329
1329
  const o = e.maxCount || 9, p = E[e.key] || 1, l = Math.min(p, o);
1330
1330
  if (e.required) {
1331
- const x = `<span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>`, T = e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : "";
1331
+ const x = `<span class="rte-text-required"><i class='iconfont icon-bitian' style='font-size: 10px;'></i></span>`, A = e.exclusionGroup ? `data-group="${e.exclusionGroup}"` : "";
1332
1332
  let P = "";
1333
1333
  for (let k = 0; k < l; k++) {
1334
- const G = `${e.key}_${k}`, R = f[G] || "", M = !R, F = M ? "​" : R, O = M ? "show-placeholder" : "", te = e.tooltip ? ` data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" data-variable-key="${e.key || ""}"` : "", de = e.tooltip && M ? "" : "hidden", h = e.exclusionGroup ? ` data-group="${e.exclusionGroup}"` : "", d = `<span contenteditable="true" data-type="variable" data-key="${G}" data-multi-key="${e.key}" data-index="${k}" data-placeholder="${e.placeholder || ""}"${h}${te} class="variable-chip ${O}">${F}${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi variable-info-icon ${de}" data-variable-key="${e.key}" data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" title="提示"></i>` : ""}</span>`;
1335
- k === 0 ? P += `<span ${T} class="exclusion-wrapper required-upload-group required-multi-first">${x}${d}</span>` : P += d;
1334
+ const G = `${e.key}_${k}`, R = u[G] || "", D = !R, F = D ? "​" : R, B = D ? "show-placeholder" : "", Z = e.tooltip ? ` data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" data-variable-key="${e.key || ""}"` : "", ie = e.tooltip && D ? "" : "hidden", h = e.exclusionGroup ? ` data-group="${e.exclusionGroup}"` : "", f = `<span contenteditable="true" data-type="variable" data-key="${G}" data-multi-key="${e.key}" data-index="${k}" data-placeholder="${e.placeholder || ""}"${h}${Z} class="variable-chip ${B}">${F}${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi variable-info-icon ${ie}" data-variable-key="${e.key}" data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" title="提示"></i>` : ""}</span>`;
1335
+ k === 0 ? P += `<span ${A} class="exclusion-wrapper required-upload-group required-multi-first">${x}${f}</span>` : P += f;
1336
1336
  }
1337
1337
  a = P;
1338
1338
  } else {
1339
1339
  let x = "";
1340
- for (let T = 0; T < l; T++) {
1341
- const P = `${e.key}_${T}`, k = f[P] || "", G = !k, R = G ? "​" : k, M = G ? "show-placeholder" : "", F = e.tooltip ? ` data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" data-variable-key="${e.key || ""}"` : "", O = e.tooltip && G ? "" : "hidden", te = e.exclusionGroup ? ` data-group="${e.exclusionGroup}"` : "", de = `<span contenteditable="true" data-type="variable" data-key="${P}" data-multi-key="${e.key}" data-index="${T}" data-placeholder="${e.placeholder || ""}"${te}${F} class="variable-chip ${M}">${R}${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi variable-info-icon ${O}" data-variable-key="${e.key}" data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" title="提示"></i>` : ""}</span>`;
1342
- x += de;
1340
+ for (let A = 0; A < l; A++) {
1341
+ const P = `${e.key}_${A}`, k = u[P] || "", G = !k, R = G ? "​" : k, D = G ? "show-placeholder" : "", F = e.tooltip ? ` data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" data-variable-key="${e.key || ""}"` : "", B = e.tooltip && G ? "" : "hidden", Z = e.exclusionGroup ? ` data-group="${e.exclusionGroup}"` : "", ie = `<span contenteditable="true" data-type="variable" data-key="${P}" data-multi-key="${e.key}" data-index="${A}" data-placeholder="${e.placeholder || ""}"${Z}${F} class="variable-chip ${D}">${R}${e.tooltip ? `<i contenteditable="false" class="iconfont icon-tishi variable-info-icon ${B}" data-variable-key="${e.key}" data-tooltip="${e.tooltip.replace(/"/g, "&quot;")}" title="提示"></i>` : ""}</span>`;
1342
+ x += ie;
1343
1343
  }
1344
1344
  a = x;
1345
1345
  }
1346
1346
  }
1347
- w += r + a + n, g++;
1347
+ b += r + a + n, g++;
1348
1348
  }
1349
- t.current && (t.current.innerHTML = w, setTimeout(() => {
1349
+ t.current && (t.current.innerHTML = b, setTimeout(() => {
1350
1350
  if (!t.current) return;
1351
1351
  t.current.querySelectorAll('[data-type="variable"]').forEach((C) => {
1352
- const y = C.innerText.replace(/\n/g, "");
1353
- y.replace(/\u200B/g, "") ? C.classList.remove("show-placeholder") : (y !== "​" && (C.innerText = "​"), C.classList.add("show-placeholder"));
1352
+ const m = C.innerText.replace(/\n/g, "");
1353
+ m.replace(/\u200B/g, "") ? C.classList.remove("show-placeholder") : (m !== "​" && (C.innerText = "​"), C.classList.add("show-placeholder"));
1354
1354
  });
1355
1355
  }, 0));
1356
1356
  }
1357
- function Ft(t, u, i, s, f = {}, E, q, w) {
1358
- const g = se(() => {
1357
+ function zt(t, d, i, s, u = {}, E, T, b) {
1358
+ const g = le(() => {
1359
1359
  if (!t.current) return;
1360
- if (u.length === 0) {
1360
+ if (d.length === 0) {
1361
1361
  t.current.innerHTML = "";
1362
1362
  return;
1363
1363
  }
1364
1364
  let e = {};
1365
- const y = t.current.__tempVariableValues;
1366
- if (y ? (e = y, setTimeout(() => {
1365
+ const m = t.current.__tempVariableValues;
1366
+ if (m ? (e = m, setTimeout(() => {
1367
1367
  if (t.current) {
1368
1368
  const c = t.current;
1369
- c.__tempVariableValues === y && delete c.__tempVariableValues;
1369
+ c.__tempVariableValues === m && delete c.__tempVariableValues;
1370
1370
  }
1371
1371
  }, 100)) : (t.current.querySelectorAll('[data-type="variable"]').forEach((p) => {
1372
1372
  const l = p.dataset.key;
@@ -1398,7 +1398,7 @@ function Ft(t, u, i, s, f = {}, E, q, w) {
1398
1398
  const x = (p.getAttribute("data-value") || "").trim();
1399
1399
  x && (e[l] = x);
1400
1400
  }
1401
- })), Rt(t, u, i, s, e, f, w), E?.current) {
1401
+ })), Ft(t, d, i, s, e, u, b), E?.current) {
1402
1402
  const { key: c, offset: r } = E.current;
1403
1403
  setTimeout(() => {
1404
1404
  if (!t.current) return;
@@ -1414,21 +1414,21 @@ function Ft(t, u, i, s, f = {}, E, q, w) {
1414
1414
  );
1415
1415
  let p = 0, l = null, x = 0;
1416
1416
  for (; o.nextNode(); ) {
1417
- const T = o.currentNode, P = T.textContent?.length || 0;
1417
+ const A = o.currentNode, P = A.textContent?.length || 0;
1418
1418
  if (p + P >= r) {
1419
- l = T, x = r - p;
1419
+ l = A, x = r - p;
1420
1420
  break;
1421
1421
  }
1422
1422
  p += P;
1423
1423
  }
1424
1424
  if (l) {
1425
1425
  a.setStart(l, Math.min(x, l.textContent?.length || 0)), a.collapse(!0);
1426
- const T = window.getSelection();
1427
- T && (T.removeAllRanges(), T.addRange(a), n.focus());
1426
+ const A = window.getSelection();
1427
+ A && (A.removeAllRanges(), A.addRange(a), n.focus());
1428
1428
  } else {
1429
1429
  a.selectNodeContents(n), a.collapse(!1);
1430
- const T = window.getSelection();
1431
- T && (T.removeAllRanges(), T.addRange(a), n.focus());
1430
+ const A = window.getSelection();
1431
+ A && (A.removeAllRanges(), A.addRange(a), n.focus());
1432
1432
  }
1433
1433
  } catch {
1434
1434
  const a = document.createRange();
@@ -1440,155 +1440,163 @@ function Ft(t, u, i, s, f = {}, E, q, w) {
1440
1440
  }
1441
1441
  }, 0);
1442
1442
  }
1443
- }, [u, i, s, t, f, E, q, w]);
1444
- ue(() => {
1443
+ }, [d, i, s, t, u, E, T, b]);
1444
+ pe(() => {
1445
1445
  g();
1446
1446
  }, [g]);
1447
1447
  }
1448
- function zt(t, u, i, s) {
1449
- ue(() => {
1450
- const f = t.current;
1451
- if (!f) return;
1452
- const E = (w) => {
1453
- const g = w.target?.closest(".upload-info-icon");
1448
+ function Yt(t, d, i, s) {
1449
+ pe(() => {
1450
+ const u = t.current;
1451
+ if (!u) return;
1452
+ const E = (b) => {
1453
+ const g = b.target?.closest(".upload-info-icon");
1454
1454
  if (g && g.classList.contains("upload-info-icon")) {
1455
1455
  const C = g.dataset.uploadKey;
1456
1456
  C && s({ key: C, anchorEl: g, type: "upload" });
1457
1457
  return;
1458
1458
  }
1459
- const e = w.target?.closest('[data-type="upload"]');
1459
+ const e = b.target?.closest('[data-type="upload"]');
1460
1460
  if (e) {
1461
1461
  const C = e.dataset.key;
1462
1462
  if (C) {
1463
- const y = i[C];
1464
- y && y.type && y.type.startsWith("image/") && s({ key: C, anchorEl: e, type: "upload-preview" });
1463
+ const m = i[C];
1464
+ m && m.type && m.type.startsWith("image/") && s({ key: C, anchorEl: e, type: "upload-preview" });
1465
1465
  }
1466
1466
  }
1467
- }, q = (w) => {
1468
- const g = w.target?.closest(".upload-info-icon"), e = w.relatedTarget;
1467
+ }, T = (b) => {
1468
+ const g = b.target?.closest(".upload-info-icon"), e = b.relatedTarget;
1469
1469
  if (g && g.classList.contains("upload-info-icon")) {
1470
- !e || !f.contains(e) ? s(null) : e.closest(".upload-info-icon") || s(null);
1470
+ !e || !u.contains(e) ? s(null) : e.closest(".upload-info-icon") || s(null);
1471
1471
  return;
1472
1472
  }
1473
- const C = w.target?.closest('[data-type="upload"]');
1473
+ const C = b.target?.closest('[data-type="upload"]');
1474
1474
  if (C) {
1475
- const y = e;
1476
- if (y && C.contains(y))
1475
+ const m = e;
1476
+ if (m && C.contains(m))
1477
1477
  return;
1478
1478
  s(null);
1479
1479
  }
1480
1480
  };
1481
- return f.addEventListener("mouseover", E, !0), f.addEventListener("mouseout", q, !0), () => {
1482
- f.removeEventListener("mouseover", E, !0), f.removeEventListener("mouseout", q, !0);
1481
+ return u.addEventListener("mouseover", E, !0), u.addEventListener("mouseout", T, !0), () => {
1482
+ u.removeEventListener("mouseover", E, !0), u.removeEventListener("mouseout", T, !0);
1483
1483
  };
1484
- }, [u, i, t, s]);
1484
+ }, [d, i, t, s]);
1485
1485
  }
1486
- function Yt(t, u, i, s) {
1487
- ue(() => {
1486
+ function jt(t, d, i, s) {
1487
+ pe(() => {
1488
1488
  if (!t.current) return;
1489
- const f = (g) => {
1489
+ const u = (g) => {
1490
1490
  if (s === "hideTagClose")
1491
1491
  return;
1492
- const e = g.currentTarget, C = e.dataset.tooltip, y = e.dataset.tagKey || "";
1493
- C && i({ key: y, anchorEl: e, type: "tag" });
1492
+ const e = g.currentTarget, C = e.dataset.tooltip, m = e.dataset.tagKey || "";
1493
+ C && i({ key: m, anchorEl: e, type: "tag" });
1494
1494
  }, E = () => {
1495
1495
  i(null);
1496
1496
  };
1497
- let q;
1498
- const w = () => {
1497
+ let T;
1498
+ const b = () => {
1499
1499
  if (!t.current) return;
1500
1500
  t.current.querySelectorAll(
1501
1501
  ".tag-node[data-tooltip]"
1502
1502
  ).forEach((e) => {
1503
- e.addEventListener("mouseenter", f), e.addEventListener("mouseleave", E);
1503
+ e.addEventListener("mouseenter", u), e.addEventListener("mouseleave", E);
1504
1504
  });
1505
1505
  };
1506
- return q = requestAnimationFrame(() => {
1507
- q = requestAnimationFrame(w);
1506
+ return T = requestAnimationFrame(() => {
1507
+ T = requestAnimationFrame(b);
1508
1508
  }), () => {
1509
- cancelAnimationFrame(q), t.current && t.current.querySelectorAll(
1509
+ cancelAnimationFrame(T), t.current && t.current.querySelectorAll(
1510
1510
  ".tag-node[data-tooltip]"
1511
1511
  ).forEach((e) => {
1512
- e.removeEventListener("mouseenter", f), e.removeEventListener("mouseleave", E);
1512
+ e.removeEventListener("mouseenter", u), e.removeEventListener("mouseleave", E);
1513
1513
  });
1514
1514
  };
1515
- }, [u, t, i, s]);
1515
+ }, [d, t, i, s]);
1516
1516
  }
1517
- function jt(t, u, i) {
1518
- ue(() => {
1517
+ function Wt(t, d, i) {
1518
+ pe(() => {
1519
1519
  const s = t.current;
1520
1520
  if (!s) return;
1521
- const f = (q) => {
1522
- const w = q.target?.closest(".variable-info-icon");
1523
- if (w && w.classList.contains("variable-info-icon")) {
1524
- const g = w.dataset.variableKey;
1525
- g && i({ key: g, anchorEl: w, type: "variable" });
1521
+ const u = (T) => {
1522
+ const b = T.target?.closest(".variable-info-icon");
1523
+ if (b && b.classList.contains("variable-info-icon")) {
1524
+ const g = b.dataset.variableKey;
1525
+ g && i({ key: g, anchorEl: b, type: "variable" });
1526
1526
  }
1527
- }, E = (q) => {
1528
- const w = q.target?.closest(".variable-info-icon"), g = q.relatedTarget;
1529
- w && w.classList.contains("variable-info-icon") && (!g || !s.contains(g) ? i(null) : g.closest(".variable-info-icon") || i(null));
1527
+ }, E = (T) => {
1528
+ const b = T.target?.closest(".variable-info-icon"), g = T.relatedTarget;
1529
+ b && b.classList.contains("variable-info-icon") && (!g || !s.contains(g) ? i(null) : g.closest(".variable-info-icon") || i(null));
1530
1530
  };
1531
- return s.addEventListener("mouseover", f, !0), s.addEventListener("mouseout", E, !0), () => {
1532
- s.removeEventListener("mouseover", f, !0), s.removeEventListener("mouseout", E, !0);
1531
+ return s.addEventListener("mouseover", u, !0), s.addEventListener("mouseout", E, !0), () => {
1532
+ s.removeEventListener("mouseover", u, !0), s.removeEventListener("mouseout", E, !0);
1533
1533
  };
1534
- }, [u, t, i]);
1534
+ }, [d, t, i]);
1535
1535
  }
1536
- function Wt(t, u, i, s) {
1537
- ue(() => {
1536
+ function Kt(t, d, i, s) {
1537
+ pe(() => {
1538
1538
  if (!t.current) return;
1539
- const f = (g) => {
1539
+ const u = (g) => {
1540
1540
  const e = g.currentTarget;
1541
1541
  e.dataset.fileName && s({ key: "", anchorEl: e, type: "upload-label" });
1542
1542
  }, E = () => {
1543
1543
  s(null);
1544
1544
  };
1545
- let q;
1546
- const w = () => {
1545
+ let T;
1546
+ const b = () => {
1547
1547
  if (!t.current) return;
1548
1548
  t.current.querySelectorAll(
1549
1549
  ".upload-label[data-file-name]"
1550
1550
  ).forEach((e) => {
1551
- e.addEventListener("mouseenter", f), e.addEventListener("mouseleave", E);
1551
+ e.addEventListener("mouseenter", u), e.addEventListener("mouseleave", E);
1552
1552
  });
1553
1553
  };
1554
- return q = requestAnimationFrame(() => {
1555
- q = requestAnimationFrame(w);
1554
+ return T = requestAnimationFrame(() => {
1555
+ T = requestAnimationFrame(b);
1556
1556
  }), () => {
1557
- cancelAnimationFrame(q), t.current && t.current.querySelectorAll(
1557
+ cancelAnimationFrame(T), t.current && t.current.querySelectorAll(
1558
1558
  ".upload-label[data-file-name]"
1559
1559
  ).forEach((e) => {
1560
- e.removeEventListener("mouseenter", f), e.removeEventListener("mouseleave", E);
1560
+ e.removeEventListener("mouseenter", u), e.removeEventListener("mouseleave", E);
1561
1561
  });
1562
1562
  };
1563
- }, [u, i, t, s]);
1563
+ }, [d, i, t, s]);
1564
1564
  }
1565
- function Kt(t, u, i, s) {
1566
- ue(() => {
1567
- const f = setTimeout(() => {
1568
- He(t, u, i), Ge(t, u, i, s);
1569
- }, 0);
1570
- return () => clearTimeout(f);
1571
- }, [i, u, t, s]);
1565
+ function Ut(t, d, i, s) {
1566
+ pe(() => {
1567
+ const u = t.current;
1568
+ if (!u) return;
1569
+ const E = () => {
1570
+ He(t, d, i), Ge(t, d, i, s);
1571
+ }, T = setTimeout(E, 0), b = () => {
1572
+ setTimeout(E, 0);
1573
+ }, g = () => {
1574
+ setTimeout(E, 0);
1575
+ };
1576
+ return u.addEventListener("input", b, !0), u.addEventListener("blur", g, !0), () => {
1577
+ clearTimeout(T), u.removeEventListener("input", b, !0), u.removeEventListener("blur", g, !0);
1578
+ };
1579
+ }, [i, d, t, s]);
1572
1580
  }
1573
- function Ut(t, u) {
1581
+ function Xt(t, d) {
1574
1582
  const i = ne(0), s = ne(0);
1575
- ue(() => {
1583
+ pe(() => {
1576
1584
  if (!t.current) return;
1577
- let f = !1, E = 0;
1578
- const q = (l) => l instanceof HTMLElement ? !!(l.closest(".rte-datepicker-wrapper") || l.closest(".rte-datepicker-host") || l.closest(".ant-picker") || l.closest(".ant-picker-dropdown")) : !1, w = (l) => l instanceof HTMLElement ? !!(l.closest(".rte-select-wrapper") || l.closest(".rte-select-host") || l.closest(".ant-select") || l.closest(".ant-select-dropdown")) : !1, g = (l) => {
1579
- f = !0, q(l.target) && (i.current = Date.now(), console.log("[SelectionCtrl] mousedown on datepicker target")), w(l.target) && (s.current = Date.now(), console.log("[SelectionCtrl] mousedown on select target"));
1585
+ let u = !1, E = 0;
1586
+ const T = (l) => l instanceof HTMLElement ? !!(l.closest(".rte-datepicker-wrapper") || l.closest(".rte-datepicker-host") || l.closest(".ant-picker") || l.closest(".ant-picker-dropdown")) : !1, b = (l) => l instanceof HTMLElement ? !!(l.closest(".rte-select-wrapper") || l.closest(".rte-select-host") || l.closest(".ant-select") || l.closest(".ant-select-dropdown")) : !1, g = (l) => {
1587
+ u = !0, T(l.target) && (i.current = Date.now(), console.log("[SelectionCtrl] mousedown on datepicker target")), b(l.target) && (s.current = Date.now(), console.log("[SelectionCtrl] mousedown on select target"));
1580
1588
  }, e = () => {
1581
- f = !1, E = Date.now();
1589
+ u = !1, E = Date.now();
1582
1590
  };
1583
- let C = !1, y = 0;
1591
+ let C = !1, m = 0;
1584
1592
  const c = () => {
1585
1593
  C = !0;
1586
1594
  }, r = () => {
1587
- C = !1, y = Date.now();
1595
+ C = !1, m = Date.now();
1588
1596
  }, n = () => {
1589
- y = Date.now();
1597
+ m = Date.now();
1590
1598
  }, a = (l) => {
1591
- q(l.target) && (i.current = Date.now(), console.log("[SelectionCtrl] focusin datepicker target")), w(l.target) && (s.current = Date.now(), console.log("[SelectionCtrl] focusin select target"));
1599
+ T(l.target) && (i.current = Date.now(), console.log("[SelectionCtrl] focusin datepicker target")), b(l.target) && (s.current = Date.now(), console.log("[SelectionCtrl] focusin select target"));
1592
1600
  }, o = () => {
1593
1601
  if (Date.now() - i.current < 800 || Date.now() - s.current < 800) {
1594
1602
  console.log("[SelectionCtrl] skip selectionchange due to recent picker/select interaction");
@@ -1602,21 +1610,21 @@ function Ut(t, u) {
1602
1610
  }
1603
1611
  if (!t.current) return;
1604
1612
  const x = window.getSelection();
1605
- if (!x || x.rangeCount === 0 || u.current || f || C || Date.now() - y < 500)
1613
+ if (!x || x.rangeCount === 0 || d.current || u || C || Date.now() - m < 500)
1606
1614
  return;
1607
- const T = x.getRangeAt(0);
1608
- if (!T.collapsed)
1609
- return t.current.contains(T.commonAncestorContainer), void 0;
1615
+ const A = x.getRangeAt(0);
1616
+ if (!A.collapsed)
1617
+ return t.current.contains(A.commonAncestorContainer), void 0;
1610
1618
  const P = x.anchorNode;
1611
1619
  if (!P || !t.current.contains(P))
1612
1620
  return;
1613
1621
  let k = !1, G = !1;
1614
1622
  if (P.nodeType === Node.ELEMENT_NODE) {
1615
- const M = P;
1616
- (M.closest('[data-type="datepicker"]') || M.closest(".rte-datepicker-wrapper") || M.closest(".rte-datepicker-host")) && (k = !0), (M.closest('[data-type="select"]') || M.closest(".rte-select-wrapper") || M.closest(".rte-select-host")) && (G = !0);
1623
+ const D = P;
1624
+ (D.closest('[data-type="datepicker"]') || D.closest(".rte-datepicker-wrapper") || D.closest(".rte-datepicker-host")) && (k = !0), (D.closest('[data-type="select"]') || D.closest(".rte-select-wrapper") || D.closest(".rte-select-host")) && (G = !0);
1617
1625
  } else if (P.parentElement) {
1618
- const M = P.parentElement;
1619
- (M.closest('[data-type="datepicker"]') || M.closest(".rte-datepicker-wrapper") || M.closest(".rte-datepicker-host")) && (k = !0), (M.closest('[data-type="select"]') || M.closest(".rte-select-wrapper") || M.closest(".rte-select-host")) && (G = !0);
1626
+ const D = P.parentElement;
1627
+ (D.closest('[data-type="datepicker"]') || D.closest(".rte-datepicker-wrapper") || D.closest(".rte-datepicker-host")) && (k = !0), (D.closest('[data-type="select"]') || D.closest(".rte-select-wrapper") || D.closest(".rte-select-host")) && (G = !0);
1620
1628
  }
1621
1629
  if (k || G)
1622
1630
  return;
@@ -1624,17 +1632,17 @@ function Ut(t, u) {
1624
1632
  if (P.nodeType === Node.ELEMENT_NODE ? R = P.closest('[data-type="variable"]') : P.nodeType === Node.TEXT_NODE && P.parentElement && (R = P.parentElement.closest('[data-type="variable"]')), !R) {
1625
1633
  if (Date.now() - E > 500)
1626
1634
  return;
1627
- const M = t.current.querySelectorAll('[data-type="variable"]');
1628
- if (M.length > 0) {
1635
+ const D = t.current.querySelectorAll('[data-type="variable"]');
1636
+ if (D.length > 0) {
1629
1637
  let F = null;
1630
- for (const O of Array.from(M))
1631
- if (O.style.display !== "none") {
1632
- F = O;
1638
+ for (const B of Array.from(D))
1639
+ if (B.style.display !== "none") {
1640
+ F = B;
1633
1641
  break;
1634
1642
  }
1635
- if (!F && M.length > 0 && (F = M[0]), F) {
1636
- const O = document.createRange();
1637
- O.selectNodeContents(F), O.collapse(!1), x.removeAllRanges(), x.addRange(O), F.focus();
1643
+ if (!F && D.length > 0 && (F = D[0]), F) {
1644
+ const B = document.createRange();
1645
+ B.selectNodeContents(F), B.collapse(!1), x.removeAllRanges(), x.addRange(B), F.focus();
1638
1646
  } else
1639
1647
  x.removeAllRanges();
1640
1648
  } else
@@ -1645,368 +1653,368 @@ function Ut(t, u) {
1645
1653
  const l = t.current;
1646
1654
  l && (l.removeEventListener("compositionstart", c), l.removeEventListener("compositionend", r), l.removeEventListener("input", n)), document.removeEventListener("mousedown", g), document.removeEventListener("mouseup", e), document.removeEventListener("focusin", a), document.removeEventListener("selectionchange", o);
1647
1655
  };
1648
- }, [t, u]);
1656
+ }, [t, d]);
1649
1657
  }
1650
- function Xt(t) {
1658
+ function Jt(t) {
1651
1659
  return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
1652
1660
  }
1653
- var Me = { exports: {} }, Jt = Me.exports, Ue;
1654
- function nt() {
1655
- return Ue || (Ue = 1, function(t, u) {
1661
+ var De = { exports: {} }, Qt = De.exports, Xe;
1662
+ function at() {
1663
+ return Xe || (Xe = 1, function(t, d) {
1656
1664
  (function(i, s) {
1657
1665
  t.exports = s();
1658
- })(Jt, function() {
1659
- var i = 1e3, s = 6e4, f = 36e5, E = "millisecond", q = "second", w = "minute", g = "hour", e = "day", C = "week", y = "month", c = "quarter", r = "year", n = "date", a = "Invalid Date", o = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, p = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, l = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(h) {
1660
- var d = ["th", "st", "nd", "rd"], v = h % 100;
1661
- return "[" + h + (d[(v - 20) % 10] || d[v] || d[0]) + "]";
1662
- } }, x = function(h, d, v) {
1663
- var _ = String(h);
1664
- return !_ || _.length >= d ? h : "" + Array(d + 1 - _.length).join(v) + h;
1665
- }, T = { s: x, z: function(h) {
1666
- var d = -h.utcOffset(), v = Math.abs(d), _ = Math.floor(v / 60), L = v % 60;
1667
- return (d <= 0 ? "+" : "-") + x(_, 2, "0") + ":" + x(L, 2, "0");
1668
- }, m: function h(d, v) {
1669
- if (d.date() < v.date()) return -h(v, d);
1670
- var _ = 12 * (v.year() - d.year()) + (v.month() - d.month()), L = d.clone().add(_, y), K = v - L < 0, U = d.clone().add(_ + (K ? -1 : 1), y);
1671
- return +(-(_ + (v - L) / (K ? L - U : U - L)) || 0);
1666
+ })(Qt, function() {
1667
+ var i = 1e3, s = 6e4, u = 36e5, E = "millisecond", T = "second", b = "minute", g = "hour", e = "day", C = "week", m = "month", c = "quarter", r = "year", n = "date", a = "Invalid Date", o = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, p = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, l = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(h) {
1668
+ var f = ["th", "st", "nd", "rd"], w = h % 100;
1669
+ return "[" + h + (f[(w - 20) % 10] || f[w] || f[0]) + "]";
1670
+ } }, x = function(h, f, w) {
1671
+ var q = String(h);
1672
+ return !q || q.length >= f ? h : "" + Array(f + 1 - q.length).join(w) + h;
1673
+ }, A = { s: x, z: function(h) {
1674
+ var f = -h.utcOffset(), w = Math.abs(f), q = Math.floor(w / 60), N = w % 60;
1675
+ return (f <= 0 ? "+" : "-") + x(q, 2, "0") + ":" + x(N, 2, "0");
1676
+ }, m: function h(f, w) {
1677
+ if (f.date() < w.date()) return -h(w, f);
1678
+ var q = 12 * (w.year() - f.year()) + (w.month() - f.month()), N = f.clone().add(q, m), K = w - N < 0, U = f.clone().add(q + (K ? -1 : 1), m);
1679
+ return +(-(q + (w - N) / (K ? N - U : U - N)) || 0);
1672
1680
  }, a: function(h) {
1673
1681
  return h < 0 ? Math.ceil(h) || 0 : Math.floor(h);
1674
1682
  }, p: function(h) {
1675
- return { M: y, y: r, w: C, d: e, D: n, h: g, m: w, s: q, ms: E, Q: c }[h] || String(h || "").toLowerCase().replace(/s$/, "");
1683
+ return { M: m, y: r, w: C, d: e, D: n, h: g, m: b, s: T, ms: E, Q: c }[h] || String(h || "").toLowerCase().replace(/s$/, "");
1676
1684
  }, u: function(h) {
1677
1685
  return h === void 0;
1678
1686
  } }, P = "en", k = {};
1679
1687
  k[P] = l;
1680
1688
  var G = "$isDayjsObject", R = function(h) {
1681
- return h instanceof te || !(!h || !h[G]);
1682
- }, M = function h(d, v, _) {
1683
- var L;
1684
- if (!d) return P;
1685
- if (typeof d == "string") {
1686
- var K = d.toLowerCase();
1687
- k[K] && (L = K), v && (k[K] = v, L = K);
1688
- var U = d.split("-");
1689
- if (!L && U.length > 1) return h(U[0]);
1689
+ return h instanceof Z || !(!h || !h[G]);
1690
+ }, D = function h(f, w, q) {
1691
+ var N;
1692
+ if (!f) return P;
1693
+ if (typeof f == "string") {
1694
+ var K = f.toLowerCase();
1695
+ k[K] && (N = K), w && (k[K] = w, N = K);
1696
+ var U = f.split("-");
1697
+ if (!N && U.length > 1) return h(U[0]);
1690
1698
  } else {
1691
- var ae = d.name;
1692
- k[ae] = d, L = ae;
1699
+ var ae = f.name;
1700
+ k[ae] = f, N = ae;
1693
1701
  }
1694
- return !_ && L && (P = L), L || !_ && P;
1695
- }, F = function(h, d) {
1702
+ return !q && N && (P = N), N || !q && P;
1703
+ }, F = function(h, f) {
1696
1704
  if (R(h)) return h.clone();
1697
- var v = typeof d == "object" ? d : {};
1698
- return v.date = h, v.args = arguments, new te(v);
1699
- }, O = T;
1700
- O.l = M, O.i = R, O.w = function(h, d) {
1701
- return F(h, { locale: d.$L, utc: d.$u, x: d.$x, $offset: d.$offset });
1705
+ var w = typeof f == "object" ? f : {};
1706
+ return w.date = h, w.args = arguments, new Z(w);
1707
+ }, B = A;
1708
+ B.l = D, B.i = R, B.w = function(h, f) {
1709
+ return F(h, { locale: f.$L, utc: f.$u, x: f.$x, $offset: f.$offset });
1702
1710
  };
1703
- var te = function() {
1704
- function h(v) {
1705
- this.$L = M(v.locale, null, !0), this.parse(v), this.$x = this.$x || v.x || {}, this[G] = !0;
1711
+ var Z = function() {
1712
+ function h(w) {
1713
+ this.$L = D(w.locale, null, !0), this.parse(w), this.$x = this.$x || w.x || {}, this[G] = !0;
1706
1714
  }
1707
- var d = h.prototype;
1708
- return d.parse = function(v) {
1709
- this.$d = function(_) {
1710
- var L = _.date, K = _.utc;
1711
- if (L === null) return /* @__PURE__ */ new Date(NaN);
1712
- if (O.u(L)) return /* @__PURE__ */ new Date();
1713
- if (L instanceof Date) return new Date(L);
1714
- if (typeof L == "string" && !/Z$/i.test(L)) {
1715
- var U = L.match(o);
1715
+ var f = h.prototype;
1716
+ return f.parse = function(w) {
1717
+ this.$d = function(q) {
1718
+ var N = q.date, K = q.utc;
1719
+ if (N === null) return /* @__PURE__ */ new Date(NaN);
1720
+ if (B.u(N)) return /* @__PURE__ */ new Date();
1721
+ if (N instanceof Date) return new Date(N);
1722
+ if (typeof N == "string" && !/Z$/i.test(N)) {
1723
+ var U = N.match(o);
1716
1724
  if (U) {
1717
- var ae = U[2] - 1 || 0, re = (U[7] || "0").substring(0, 3);
1718
- return K ? new Date(Date.UTC(U[1], ae, U[3] || 1, U[4] || 0, U[5] || 0, U[6] || 0, re)) : new Date(U[1], ae, U[3] || 1, U[4] || 0, U[5] || 0, U[6] || 0, re);
1725
+ var ae = U[2] - 1 || 0, ce = (U[7] || "0").substring(0, 3);
1726
+ return K ? new Date(Date.UTC(U[1], ae, U[3] || 1, U[4] || 0, U[5] || 0, U[6] || 0, ce)) : new Date(U[1], ae, U[3] || 1, U[4] || 0, U[5] || 0, U[6] || 0, ce);
1719
1727
  }
1720
1728
  }
1721
- return new Date(L);
1722
- }(v), this.init();
1723
- }, d.init = function() {
1724
- var v = this.$d;
1725
- this.$y = v.getFullYear(), this.$M = v.getMonth(), this.$D = v.getDate(), this.$W = v.getDay(), this.$H = v.getHours(), this.$m = v.getMinutes(), this.$s = v.getSeconds(), this.$ms = v.getMilliseconds();
1726
- }, d.$utils = function() {
1727
- return O;
1728
- }, d.isValid = function() {
1729
+ return new Date(N);
1730
+ }(w), this.init();
1731
+ }, f.init = function() {
1732
+ var w = this.$d;
1733
+ this.$y = w.getFullYear(), this.$M = w.getMonth(), this.$D = w.getDate(), this.$W = w.getDay(), this.$H = w.getHours(), this.$m = w.getMinutes(), this.$s = w.getSeconds(), this.$ms = w.getMilliseconds();
1734
+ }, f.$utils = function() {
1735
+ return B;
1736
+ }, f.isValid = function() {
1729
1737
  return this.$d.toString() !== a;
1730
- }, d.isSame = function(v, _) {
1731
- var L = F(v);
1732
- return this.startOf(_) <= L && L <= this.endOf(_);
1733
- }, d.isAfter = function(v, _) {
1734
- return F(v) < this.startOf(_);
1735
- }, d.isBefore = function(v, _) {
1736
- return this.endOf(_) < F(v);
1737
- }, d.$g = function(v, _, L) {
1738
- return O.u(v) ? this[_] : this.set(L, v);
1739
- }, d.unix = function() {
1738
+ }, f.isSame = function(w, q) {
1739
+ var N = F(w);
1740
+ return this.startOf(q) <= N && N <= this.endOf(q);
1741
+ }, f.isAfter = function(w, q) {
1742
+ return F(w) < this.startOf(q);
1743
+ }, f.isBefore = function(w, q) {
1744
+ return this.endOf(q) < F(w);
1745
+ }, f.$g = function(w, q, N) {
1746
+ return B.u(w) ? this[q] : this.set(N, w);
1747
+ }, f.unix = function() {
1740
1748
  return Math.floor(this.valueOf() / 1e3);
1741
- }, d.valueOf = function() {
1749
+ }, f.valueOf = function() {
1742
1750
  return this.$d.getTime();
1743
- }, d.startOf = function(v, _) {
1744
- var L = this, K = !!O.u(_) || _, U = O.p(v), ae = function(ge, he) {
1745
- var ke = O.w(L.$u ? Date.UTC(L.$y, he, ge) : new Date(L.$y, he, ge), L);
1746
- return K ? ke : ke.endOf(e);
1747
- }, re = function(ge, he) {
1748
- return O.w(L.toDate()[ge].apply(L.toDate("s"), (K ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(he)), L);
1749
- }, pe = this.$W, ye = this.$M, me = this.$D, xe = "set" + (this.$u ? "UTC" : "");
1751
+ }, f.startOf = function(w, q) {
1752
+ var N = this, K = !!B.u(q) || q, U = B.p(w), ae = function(ge, he) {
1753
+ var we = B.w(N.$u ? Date.UTC(N.$y, he, ge) : new Date(N.$y, he, ge), N);
1754
+ return K ? we : we.endOf(e);
1755
+ }, ce = function(ge, he) {
1756
+ return B.w(N.toDate()[ge].apply(N.toDate("s"), (K ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(he)), N);
1757
+ }, oe = this.$W, me = this.$M, ye = this.$D, xe = "set" + (this.$u ? "UTC" : "");
1750
1758
  switch (U) {
1751
1759
  case r:
1752
1760
  return K ? ae(1, 0) : ae(31, 11);
1753
- case y:
1754
- return K ? ae(1, ye) : ae(0, ye + 1);
1761
+ case m:
1762
+ return K ? ae(1, me) : ae(0, me + 1);
1755
1763
  case C:
1756
- var X = this.$locale().weekStart || 0, fe = (pe < X ? pe + 7 : pe) - X;
1757
- return ae(K ? me - fe : me + (6 - fe), ye);
1764
+ var X = this.$locale().weekStart || 0, fe = (oe < X ? oe + 7 : oe) - X;
1765
+ return ae(K ? ye - fe : ye + (6 - fe), me);
1758
1766
  case e:
1759
1767
  case n:
1760
- return re(xe + "Hours", 0);
1768
+ return ce(xe + "Hours", 0);
1761
1769
  case g:
1762
- return re(xe + "Minutes", 1);
1763
- case w:
1764
- return re(xe + "Seconds", 2);
1765
- case q:
1766
- return re(xe + "Milliseconds", 3);
1770
+ return ce(xe + "Minutes", 1);
1771
+ case b:
1772
+ return ce(xe + "Seconds", 2);
1773
+ case T:
1774
+ return ce(xe + "Milliseconds", 3);
1767
1775
  default:
1768
1776
  return this.clone();
1769
1777
  }
1770
- }, d.endOf = function(v) {
1771
- return this.startOf(v, !1);
1772
- }, d.$set = function(v, _) {
1773
- var L, K = O.p(v), U = "set" + (this.$u ? "UTC" : ""), ae = (L = {}, L[e] = U + "Date", L[n] = U + "Date", L[y] = U + "Month", L[r] = U + "FullYear", L[g] = U + "Hours", L[w] = U + "Minutes", L[q] = U + "Seconds", L[E] = U + "Milliseconds", L)[K], re = K === e ? this.$D + (_ - this.$W) : _;
1774
- if (K === y || K === r) {
1775
- var pe = this.clone().set(n, 1);
1776
- pe.$d[ae](re), pe.init(), this.$d = pe.set(n, Math.min(this.$D, pe.daysInMonth())).$d;
1777
- } else ae && this.$d[ae](re);
1778
+ }, f.endOf = function(w) {
1779
+ return this.startOf(w, !1);
1780
+ }, f.$set = function(w, q) {
1781
+ var N, K = B.p(w), U = "set" + (this.$u ? "UTC" : ""), ae = (N = {}, N[e] = U + "Date", N[n] = U + "Date", N[m] = U + "Month", N[r] = U + "FullYear", N[g] = U + "Hours", N[b] = U + "Minutes", N[T] = U + "Seconds", N[E] = U + "Milliseconds", N)[K], ce = K === e ? this.$D + (q - this.$W) : q;
1782
+ if (K === m || K === r) {
1783
+ var oe = this.clone().set(n, 1);
1784
+ oe.$d[ae](ce), oe.init(), this.$d = oe.set(n, Math.min(this.$D, oe.daysInMonth())).$d;
1785
+ } else ae && this.$d[ae](ce);
1778
1786
  return this.init(), this;
1779
- }, d.set = function(v, _) {
1780
- return this.clone().$set(v, _);
1781
- }, d.get = function(v) {
1782
- return this[O.p(v)]();
1783
- }, d.add = function(v, _) {
1784
- var L, K = this;
1785
- v = Number(v);
1786
- var U = O.p(_), ae = function(ye) {
1787
- var me = F(K);
1788
- return O.w(me.date(me.date() + Math.round(ye * v)), K);
1787
+ }, f.set = function(w, q) {
1788
+ return this.clone().$set(w, q);
1789
+ }, f.get = function(w) {
1790
+ return this[B.p(w)]();
1791
+ }, f.add = function(w, q) {
1792
+ var N, K = this;
1793
+ w = Number(w);
1794
+ var U = B.p(q), ae = function(me) {
1795
+ var ye = F(K);
1796
+ return B.w(ye.date(ye.date() + Math.round(me * w)), K);
1789
1797
  };
1790
- if (U === y) return this.set(y, this.$M + v);
1791
- if (U === r) return this.set(r, this.$y + v);
1798
+ if (U === m) return this.set(m, this.$M + w);
1799
+ if (U === r) return this.set(r, this.$y + w);
1792
1800
  if (U === e) return ae(1);
1793
1801
  if (U === C) return ae(7);
1794
- var re = (L = {}, L[w] = s, L[g] = f, L[q] = i, L)[U] || 1, pe = this.$d.getTime() + v * re;
1795
- return O.w(pe, this);
1796
- }, d.subtract = function(v, _) {
1797
- return this.add(-1 * v, _);
1798
- }, d.format = function(v) {
1799
- var _ = this, L = this.$locale();
1800
- if (!this.isValid()) return L.invalidDate || a;
1801
- var K = v || "YYYY-MM-DDTHH:mm:ssZ", U = O.z(this), ae = this.$H, re = this.$m, pe = this.$M, ye = L.weekdays, me = L.months, xe = L.meridiem, X = function(he, ke, Ee, Ce) {
1802
- return he && (he[ke] || he(_, K)) || Ee[ke].slice(0, Ce);
1802
+ var ce = (N = {}, N[b] = s, N[g] = u, N[T] = i, N)[U] || 1, oe = this.$d.getTime() + w * ce;
1803
+ return B.w(oe, this);
1804
+ }, f.subtract = function(w, q) {
1805
+ return this.add(-1 * w, q);
1806
+ }, f.format = function(w) {
1807
+ var q = this, N = this.$locale();
1808
+ if (!this.isValid()) return N.invalidDate || a;
1809
+ var K = w || "YYYY-MM-DDTHH:mm:ssZ", U = B.z(this), ae = this.$H, ce = this.$m, oe = this.$M, me = N.weekdays, ye = N.months, xe = N.meridiem, X = function(he, we, $e, Se) {
1810
+ return he && (he[we] || he(q, K)) || $e[we].slice(0, Se);
1803
1811
  }, fe = function(he) {
1804
- return O.s(ae % 12 || 12, he, "0");
1805
- }, ge = xe || function(he, ke, Ee) {
1806
- var Ce = he < 12 ? "AM" : "PM";
1807
- return Ee ? Ce.toLowerCase() : Ce;
1812
+ return B.s(ae % 12 || 12, he, "0");
1813
+ }, ge = xe || function(he, we, $e) {
1814
+ var Se = he < 12 ? "AM" : "PM";
1815
+ return $e ? Se.toLowerCase() : Se;
1808
1816
  };
1809
- return K.replace(p, function(he, ke) {
1810
- return ke || function(Ee) {
1811
- switch (Ee) {
1817
+ return K.replace(p, function(he, we) {
1818
+ return we || function($e) {
1819
+ switch ($e) {
1812
1820
  case "YY":
1813
- return String(_.$y).slice(-2);
1821
+ return String(q.$y).slice(-2);
1814
1822
  case "YYYY":
1815
- return O.s(_.$y, 4, "0");
1823
+ return B.s(q.$y, 4, "0");
1816
1824
  case "M":
1817
- return pe + 1;
1825
+ return oe + 1;
1818
1826
  case "MM":
1819
- return O.s(pe + 1, 2, "0");
1827
+ return B.s(oe + 1, 2, "0");
1820
1828
  case "MMM":
1821
- return X(L.monthsShort, pe, me, 3);
1829
+ return X(N.monthsShort, oe, ye, 3);
1822
1830
  case "MMMM":
1823
- return X(me, pe);
1831
+ return X(ye, oe);
1824
1832
  case "D":
1825
- return _.$D;
1833
+ return q.$D;
1826
1834
  case "DD":
1827
- return O.s(_.$D, 2, "0");
1835
+ return B.s(q.$D, 2, "0");
1828
1836
  case "d":
1829
- return String(_.$W);
1837
+ return String(q.$W);
1830
1838
  case "dd":
1831
- return X(L.weekdaysMin, _.$W, ye, 2);
1839
+ return X(N.weekdaysMin, q.$W, me, 2);
1832
1840
  case "ddd":
1833
- return X(L.weekdaysShort, _.$W, ye, 3);
1841
+ return X(N.weekdaysShort, q.$W, me, 3);
1834
1842
  case "dddd":
1835
- return ye[_.$W];
1843
+ return me[q.$W];
1836
1844
  case "H":
1837
1845
  return String(ae);
1838
1846
  case "HH":
1839
- return O.s(ae, 2, "0");
1847
+ return B.s(ae, 2, "0");
1840
1848
  case "h":
1841
1849
  return fe(1);
1842
1850
  case "hh":
1843
1851
  return fe(2);
1844
1852
  case "a":
1845
- return ge(ae, re, !0);
1853
+ return ge(ae, ce, !0);
1846
1854
  case "A":
1847
- return ge(ae, re, !1);
1855
+ return ge(ae, ce, !1);
1848
1856
  case "m":
1849
- return String(re);
1857
+ return String(ce);
1850
1858
  case "mm":
1851
- return O.s(re, 2, "0");
1859
+ return B.s(ce, 2, "0");
1852
1860
  case "s":
1853
- return String(_.$s);
1861
+ return String(q.$s);
1854
1862
  case "ss":
1855
- return O.s(_.$s, 2, "0");
1863
+ return B.s(q.$s, 2, "0");
1856
1864
  case "SSS":
1857
- return O.s(_.$ms, 3, "0");
1865
+ return B.s(q.$ms, 3, "0");
1858
1866
  case "Z":
1859
1867
  return U;
1860
1868
  }
1861
1869
  return null;
1862
1870
  }(he) || U.replace(":", "");
1863
1871
  });
1864
- }, d.utcOffset = function() {
1872
+ }, f.utcOffset = function() {
1865
1873
  return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
1866
- }, d.diff = function(v, _, L) {
1867
- var K, U = this, ae = O.p(_), re = F(v), pe = (re.utcOffset() - this.utcOffset()) * s, ye = this - re, me = function() {
1868
- return O.m(U, re);
1874
+ }, f.diff = function(w, q, N) {
1875
+ var K, U = this, ae = B.p(q), ce = F(w), oe = (ce.utcOffset() - this.utcOffset()) * s, me = this - ce, ye = function() {
1876
+ return B.m(U, ce);
1869
1877
  };
1870
1878
  switch (ae) {
1871
1879
  case r:
1872
- K = me() / 12;
1880
+ K = ye() / 12;
1873
1881
  break;
1874
- case y:
1875
- K = me();
1882
+ case m:
1883
+ K = ye();
1876
1884
  break;
1877
1885
  case c:
1878
- K = me() / 3;
1886
+ K = ye() / 3;
1879
1887
  break;
1880
1888
  case C:
1881
- K = (ye - pe) / 6048e5;
1889
+ K = (me - oe) / 6048e5;
1882
1890
  break;
1883
1891
  case e:
1884
- K = (ye - pe) / 864e5;
1892
+ K = (me - oe) / 864e5;
1885
1893
  break;
1886
1894
  case g:
1887
- K = ye / f;
1895
+ K = me / u;
1888
1896
  break;
1889
- case w:
1890
- K = ye / s;
1897
+ case b:
1898
+ K = me / s;
1891
1899
  break;
1892
- case q:
1893
- K = ye / i;
1900
+ case T:
1901
+ K = me / i;
1894
1902
  break;
1895
1903
  default:
1896
- K = ye;
1904
+ K = me;
1897
1905
  }
1898
- return L ? K : O.a(K);
1899
- }, d.daysInMonth = function() {
1900
- return this.endOf(y).$D;
1901
- }, d.$locale = function() {
1906
+ return N ? K : B.a(K);
1907
+ }, f.daysInMonth = function() {
1908
+ return this.endOf(m).$D;
1909
+ }, f.$locale = function() {
1902
1910
  return k[this.$L];
1903
- }, d.locale = function(v, _) {
1904
- if (!v) return this.$L;
1905
- var L = this.clone(), K = M(v, _, !0);
1906
- return K && (L.$L = K), L;
1907
- }, d.clone = function() {
1908
- return O.w(this.$d, this);
1909
- }, d.toDate = function() {
1911
+ }, f.locale = function(w, q) {
1912
+ if (!w) return this.$L;
1913
+ var N = this.clone(), K = D(w, q, !0);
1914
+ return K && (N.$L = K), N;
1915
+ }, f.clone = function() {
1916
+ return B.w(this.$d, this);
1917
+ }, f.toDate = function() {
1910
1918
  return new Date(this.valueOf());
1911
- }, d.toJSON = function() {
1919
+ }, f.toJSON = function() {
1912
1920
  return this.isValid() ? this.toISOString() : null;
1913
- }, d.toISOString = function() {
1921
+ }, f.toISOString = function() {
1914
1922
  return this.$d.toISOString();
1915
- }, d.toString = function() {
1923
+ }, f.toString = function() {
1916
1924
  return this.$d.toUTCString();
1917
1925
  }, h;
1918
- }(), de = te.prototype;
1919
- return F.prototype = de, [["$ms", E], ["$s", q], ["$m", w], ["$H", g], ["$W", e], ["$M", y], ["$y", r], ["$D", n]].forEach(function(h) {
1920
- de[h[1]] = function(d) {
1921
- return this.$g(d, h[0], h[1]);
1926
+ }(), ie = Z.prototype;
1927
+ return F.prototype = ie, [["$ms", E], ["$s", T], ["$m", b], ["$H", g], ["$W", e], ["$M", m], ["$y", r], ["$D", n]].forEach(function(h) {
1928
+ ie[h[1]] = function(f) {
1929
+ return this.$g(f, h[0], h[1]);
1922
1930
  };
1923
- }), F.extend = function(h, d) {
1924
- return h.$i || (h(d, te, F), h.$i = !0), F;
1925
- }, F.locale = M, F.isDayjs = R, F.unix = function(h) {
1931
+ }), F.extend = function(h, f) {
1932
+ return h.$i || (h(f, Z, F), h.$i = !0), F;
1933
+ }, F.locale = D, F.isDayjs = R, F.unix = function(h) {
1926
1934
  return F(1e3 * h);
1927
1935
  }, F.en = k[P], F.Ls = k, F.p = {}, F;
1928
1936
  });
1929
- }(Me)), Me.exports;
1937
+ }(De)), De.exports;
1930
1938
  }
1931
- var Qt = nt();
1932
- const Ie = /* @__PURE__ */ Xt(Qt);
1933
- var Ve = { exports: {} }, Zt = Ve.exports, Xe;
1934
- function en() {
1935
- return Xe || (Xe = 1, function(t, u) {
1939
+ var Zt = at();
1940
+ const Ie = /* @__PURE__ */ Jt(Zt);
1941
+ var Ve = { exports: {} }, en = Ve.exports, Je;
1942
+ function tn() {
1943
+ return Je || (Je = 1, function(t, d) {
1936
1944
  (function(i, s) {
1937
- t.exports = s(nt());
1938
- })(Zt, function(i) {
1939
- function s(q) {
1940
- return q && typeof q == "object" && "default" in q ? q : { default: q };
1945
+ t.exports = s(at());
1946
+ })(en, function(i) {
1947
+ function s(T) {
1948
+ return T && typeof T == "object" && "default" in T ? T : { default: T };
1941
1949
  }
1942
- var f = s(i), E = { name: "zh-cn", weekdays: "星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"), weekdaysShort: "周日_周一_周二_周三_周四_周五_周六".split("_"), weekdaysMin: "日_一_二_三_四_五_六".split("_"), months: "一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"), monthsShort: "1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"), ordinal: function(q, w) {
1943
- return w === "W" ? q + "周" : q + "日";
1944
- }, weekStart: 1, yearStart: 4, formats: { LT: "HH:mm", LTS: "HH:mm:ss", L: "YYYY/MM/DD", LL: "YYYY年M月D日", LLL: "YYYY年M月D日Ah点mm分", LLLL: "YYYY年M月D日ddddAh点mm分", l: "YYYY/M/D", ll: "YYYY年M月D日", lll: "YYYY年M月D日 HH:mm", llll: "YYYY年M月D日dddd HH:mm" }, relativeTime: { future: "%s内", past: "%s前", s: "几秒", m: "1 分钟", mm: "%d 分钟", h: "1 小时", hh: "%d 小时", d: "1 天", dd: "%d 天", M: "1 个月", MM: "%d 个月", y: "1 年", yy: "%d 年" }, meridiem: function(q, w) {
1945
- var g = 100 * q + w;
1950
+ var u = s(i), E = { name: "zh-cn", weekdays: "星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"), weekdaysShort: "周日_周一_周二_周三_周四_周五_周六".split("_"), weekdaysMin: "日_一_二_三_四_五_六".split("_"), months: "一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"), monthsShort: "1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"), ordinal: function(T, b) {
1951
+ return b === "W" ? T + "周" : T + "日";
1952
+ }, weekStart: 1, yearStart: 4, formats: { LT: "HH:mm", LTS: "HH:mm:ss", L: "YYYY/MM/DD", LL: "YYYY年M月D日", LLL: "YYYY年M月D日Ah点mm分", LLLL: "YYYY年M月D日ddddAh点mm分", l: "YYYY/M/D", ll: "YYYY年M月D日", lll: "YYYY年M月D日 HH:mm", llll: "YYYY年M月D日dddd HH:mm" }, relativeTime: { future: "%s内", past: "%s前", s: "几秒", m: "1 分钟", mm: "%d 分钟", h: "1 小时", hh: "%d 小时", d: "1 天", dd: "%d 天", M: "1 个月", MM: "%d 个月", y: "1 年", yy: "%d 年" }, meridiem: function(T, b) {
1953
+ var g = 100 * T + b;
1946
1954
  return g < 600 ? "凌晨" : g < 900 ? "早上" : g < 1100 ? "上午" : g < 1300 ? "中午" : g < 1800 ? "下午" : "晚上";
1947
1955
  } };
1948
- return f.default.locale(E, null, !0), E;
1956
+ return u.default.locale(E, null, !0), E;
1949
1957
  });
1950
1958
  }(Ve)), Ve.exports;
1951
1959
  }
1952
- en();
1953
- function Te(t) {
1960
+ tn();
1961
+ function qe(t) {
1954
1962
  "@babel/helpers - typeof";
1955
- return Te = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(u) {
1956
- return typeof u;
1957
- } : function(u) {
1958
- return u && typeof Symbol == "function" && u.constructor === Symbol && u !== Symbol.prototype ? "symbol" : typeof u;
1959
- }, Te(t);
1963
+ return qe = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(d) {
1964
+ return typeof d;
1965
+ } : function(d) {
1966
+ return d && typeof Symbol == "function" && d.constructor === Symbol && d !== Symbol.prototype ? "symbol" : typeof d;
1967
+ }, qe(t);
1960
1968
  }
1961
- function tn(t, u) {
1962
- if (Te(t) != "object" || !t) return t;
1969
+ function nn(t, d) {
1970
+ if (qe(t) != "object" || !t) return t;
1963
1971
  var i = t[Symbol.toPrimitive];
1964
1972
  if (i !== void 0) {
1965
- var s = i.call(t, u);
1966
- if (Te(s) != "object") return s;
1973
+ var s = i.call(t, d);
1974
+ if (qe(s) != "object") return s;
1967
1975
  throw new TypeError("@@toPrimitive must return a primitive value.");
1968
1976
  }
1969
- return (u === "string" ? String : Number)(t);
1977
+ return (d === "string" ? String : Number)(t);
1970
1978
  }
1971
- function nn(t) {
1972
- var u = tn(t, "string");
1973
- return Te(u) == "symbol" ? u : u + "";
1979
+ function an(t) {
1980
+ var d = nn(t, "string");
1981
+ return qe(d) == "symbol" ? d : d + "";
1974
1982
  }
1975
- function an(t, u, i) {
1976
- return (u = nn(u)) in t ? Object.defineProperty(t, u, {
1983
+ function rn(t, d, i) {
1984
+ return (d = an(d)) in t ? Object.defineProperty(t, d, {
1977
1985
  value: i,
1978
1986
  enumerable: !0,
1979
1987
  configurable: !0,
1980
1988
  writable: !0
1981
- }) : t[u] = i, t;
1989
+ }) : t[d] = i, t;
1982
1990
  }
1983
- function Je(t, u) {
1991
+ function Qe(t, d) {
1984
1992
  var i = Object.keys(t);
1985
1993
  if (Object.getOwnPropertySymbols) {
1986
1994
  var s = Object.getOwnPropertySymbols(t);
1987
- u && (s = s.filter(function(f) {
1988
- return Object.getOwnPropertyDescriptor(t, f).enumerable;
1995
+ d && (s = s.filter(function(u) {
1996
+ return Object.getOwnPropertyDescriptor(t, u).enumerable;
1989
1997
  })), i.push.apply(i, s);
1990
1998
  }
1991
1999
  return i;
1992
2000
  }
1993
- function Qe(t) {
1994
- for (var u = 1; u < arguments.length; u++) {
1995
- var i = arguments[u] != null ? arguments[u] : {};
1996
- u % 2 ? Je(Object(i), !0).forEach(function(s) {
1997
- an(t, s, i[s]);
1998
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(i)) : Je(Object(i)).forEach(function(s) {
2001
+ function Ze(t) {
2002
+ for (var d = 1; d < arguments.length; d++) {
2003
+ var i = arguments[d] != null ? arguments[d] : {};
2004
+ d % 2 ? Qe(Object(i), !0).forEach(function(s) {
2005
+ rn(t, s, i[s]);
2006
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(i)) : Qe(Object(i)).forEach(function(s) {
1999
2007
  Object.defineProperty(t, s, Object.getOwnPropertyDescriptor(i, s));
2000
2008
  });
2001
2009
  }
2002
2010
  return t;
2003
2011
  }
2004
- var rn = {
2012
+ var on = {
2005
2013
  yearFormat: "YYYY",
2006
2014
  dayFormat: "D",
2007
2015
  cellMeridiemFormat: "A",
2008
2016
  monthBeforeYear: !0
2009
- }, on = Qe(Qe({}, rn), {}, {
2017
+ }, sn = Ze(Ze({}, on), {}, {
2010
2018
  locale: "zh_CN",
2011
2019
  today: "今天",
2012
2020
  now: "此刻",
@@ -2034,10 +2042,10 @@ var rn = {
2034
2042
  cellDateFormat: "D",
2035
2043
  monthBeforeYear: !1
2036
2044
  });
2037
- const sn = {
2045
+ const ln = {
2038
2046
  placeholder: "请选择时间",
2039
2047
  rangePlaceholder: ["开始时间", "结束时间"]
2040
- }, at = {
2048
+ }, rt = {
2041
2049
  lang: Object.assign({
2042
2050
  placeholder: "请选择日期",
2043
2051
  yearPlaceholder: "请选择年份",
@@ -2049,59 +2057,59 @@ const sn = {
2049
2057
  rangeMonthPlaceholder: ["开始月份", "结束月份"],
2050
2058
  rangeQuarterPlaceholder: ["开始季度", "结束季度"],
2051
2059
  rangeWeekPlaceholder: ["开始周", "结束周"]
2052
- }, on),
2053
- timePickerLocale: Object.assign({}, sn)
2060
+ }, sn),
2061
+ timePickerLocale: Object.assign({}, ln)
2054
2062
  };
2055
- at.lang.ok = "确定";
2063
+ rt.lang.ok = "确定";
2056
2064
  Ie.locale("zh-cn");
2057
- const { RangePicker: ln } = mt, cn = ({ host: t, onChange: u }) => {
2058
- const i = t.dataset.key, s = t.dataset.value, f = t.dataset.placeholder, E = t.dataset.limitRange ? parseInt(t.dataset.limitRange, 10) : void 0, q = t.dataset.disableFuture === "true", [w, g] = Z(() => {
2065
+ const { RangePicker: cn } = ht, un = ({ host: t, onChange: d }) => {
2066
+ const i = t.dataset.key, s = t.dataset.value, u = t.dataset.placeholder, E = t.dataset.limitRange ? parseInt(t.dataset.limitRange, 10) : void 0, T = t.dataset.disableFuture === "true", [b, g] = ee(() => {
2059
2067
  if (!s) return null;
2060
2068
  const a = s.split(",");
2061
2069
  return a.length === 2 && a[0] && a[1] ? [Ie(a[0]), Ie(a[1])] : null;
2062
- }), [e, C] = Z(null);
2070
+ }), [e, C] = ee(null);
2063
2071
  return ze(
2064
2072
  /* @__PURE__ */ S("div", { className: "rte-datepicker-wrapper", contentEditable: !1, style: { display: "inline-block", verticalAlign: "middle", width: "240px" }, children: /* @__PURE__ */ S(
2065
- ln,
2073
+ cn,
2066
2074
  {
2067
- value: w,
2068
- disabledDate: (a) => a ? q && a.isAfter(Ie(), "day") ? !0 : !E || !e || !e[0] ? !1 : Math.abs(a.diff(e[0], "days")) > E : !1,
2075
+ value: b,
2076
+ disabledDate: (a) => a ? T && a.isAfter(Ie(), "day") ? !0 : !E || !e || !e[0] ? !1 : Math.abs(a.diff(e[0], "days")) > E : !1,
2069
2077
  onCalendarChange: (a) => {
2070
2078
  console.log("[DatePicker] onCalendarChange", a?.map((o) => o?.format("YYYY-MM-DD") || null)), C(a);
2071
2079
  },
2072
2080
  onChange: (a) => {
2073
2081
  if (console.log("[DatePicker] onChange", a?.map((o) => o?.format("YYYY-MM-DD") || null)), g(a), C(null), a && a[0] && a[1]) {
2074
2082
  const o = `${a[0].format("YYYY-MM-DD")},${a[1].format("YYYY-MM-DD")}`;
2075
- t.setAttribute("data-value", o), u(i, o);
2083
+ t.setAttribute("data-value", o), d(i, o);
2076
2084
  } else
2077
- t.setAttribute("data-value", ""), u(i, "");
2085
+ t.setAttribute("data-value", ""), d(i, "");
2078
2086
  },
2079
2087
  onOpenChange: (a) => {
2080
- console.log("[DatePicker] onOpenChange", a), C(a ? w : null);
2088
+ console.log("[DatePicker] onOpenChange", a), C(a ? b : null);
2081
2089
  },
2082
- placeholder: [f || "开始日期", f || "结束日期"],
2090
+ placeholder: [u || "开始日期", u || "结束日期"],
2083
2091
  style: { width: "100%" },
2084
2092
  size: "small",
2085
2093
  allowClear: !0,
2086
- locale: at,
2094
+ locale: rt,
2087
2095
  getPopupContainer: () => document.body,
2088
2096
  popupClassName: "rte-datepicker-dropdown"
2089
2097
  }
2090
2098
  ) }),
2091
2099
  t
2092
2100
  );
2093
- }, un = (t) => {
2094
- const [u, i] = Z([]);
2095
- return ue(() => {
2101
+ }, dn = (t) => {
2102
+ const [d, i] = ee([]);
2103
+ return pe(() => {
2096
2104
  const s = t.current;
2097
2105
  if (!s) return;
2098
- const f = () => {
2099
- const q = s.querySelectorAll(".rte-datepicker-host"), w = [];
2100
- q.forEach((g) => {
2106
+ const u = () => {
2107
+ const T = s.querySelectorAll(".rte-datepicker-host"), b = [];
2108
+ T.forEach((g) => {
2101
2109
  const e = g.getAttribute("data-key");
2102
- e && w.push(
2110
+ e && b.push(
2103
2111
  /* @__PURE__ */ S(
2104
- cn,
2112
+ un,
2105
2113
  {
2106
2114
  host: g,
2107
2115
  onChange: () => {
@@ -2114,191 +2122,191 @@ const { RangePicker: ln } = mt, cn = ({ host: t, onChange: u }) => {
2114
2122
  `datepicker-${e}`
2115
2123
  )
2116
2124
  );
2117
- }), i(w);
2125
+ }), i(b);
2118
2126
  };
2119
- f();
2120
- const E = new MutationObserver((q) => {
2121
- let w = !1;
2122
- for (const g of q)
2127
+ u();
2128
+ const E = new MutationObserver((T) => {
2129
+ let b = !1;
2130
+ for (const g of T)
2123
2131
  if (g.type === "childList") {
2124
2132
  let e = !1;
2125
2133
  if (g.addedNodes.forEach((C) => {
2126
2134
  if (C.nodeType === Node.ELEMENT_NODE) {
2127
- const y = C;
2128
- (y.classList?.contains("rte-datepicker-host") || y.querySelector?.(".rte-datepicker-host")) && (e = !0);
2135
+ const m = C;
2136
+ (m.classList?.contains("rte-datepicker-host") || m.querySelector?.(".rte-datepicker-host")) && (e = !0);
2129
2137
  }
2130
2138
  }), g.removedNodes.forEach((C) => {
2131
2139
  if (C.nodeType === Node.ELEMENT_NODE) {
2132
- const y = C;
2133
- (y.classList?.contains("rte-datepicker-host") || y.querySelector?.(".rte-datepicker-host")) && (e = !0);
2140
+ const m = C;
2141
+ (m.classList?.contains("rte-datepicker-host") || m.querySelector?.(".rte-datepicker-host")) && (e = !0);
2134
2142
  }
2135
2143
  }), e) {
2136
- w = !0;
2144
+ b = !0;
2137
2145
  break;
2138
2146
  }
2139
2147
  }
2140
- w && f();
2148
+ b && u();
2141
2149
  });
2142
2150
  return E.observe(s, { childList: !0, subtree: !0 }), () => E.disconnect();
2143
- }, [t]), u;
2144
- }, dn = ({
2151
+ }, [t]), d;
2152
+ }, pn = ({
2145
2153
  config: t,
2146
- onSend: u,
2154
+ onSend: d,
2147
2155
  isProcessing: i = !1,
2148
2156
  disabled: s = !1,
2149
- width: f,
2157
+ width: u,
2150
2158
  lockStructure: E = !1,
2151
- agentOptions: q = [],
2152
- onAgentSelect: w,
2159
+ agentOptions: T = [],
2160
+ onAgentSelect: b,
2153
2161
  onAgentExit: g,
2154
2162
  loading: e = !1,
2155
2163
  placeholder: C,
2156
- border: y,
2164
+ border: m,
2157
2165
  background: c = "transparent",
2158
2166
  hideButtons: r
2159
2167
  }) => {
2160
- const n = ne(null), a = ne(null), [o, p] = Z({}), [l, x] = Z(null), [T, P] = Z(null), [k, G] = Z(null), R = ne(!1), M = ne(null), [F, O] = Z(!1), te = ne(null), [de, h] = Z(!0), [d, v] = Z(() => {
2161
- const b = {};
2162
- return t.forEach((m) => {
2163
- m.type === "multi-variable" && m.key && (b[m.key] = 1);
2164
- }), b;
2165
- }), _ = ne({}), L = ne({}), K = ne({});
2166
- ue(() => {
2167
- L.current = o;
2168
- }, [o]), ue(() => {
2169
- K.current = d;
2170
- }, [d]);
2171
- const U = se((b) => b.find(($) => $.type === "tag")?.text || null, []), ae = ne(t), re = ne(null);
2172
- ue(() => {
2173
- const b = U(ae.current), m = U(t);
2174
- if (b && b !== m && n.current) {
2168
+ const n = ne(null), a = ne(null), [o, p] = ee({}), [l, x] = ee(null), [A, P] = ee(null), [k, G] = ee(null), R = ne(!1), D = ne(null), [F, B] = ee(!1), Z = ne(null), [ie, h] = ee(!0), f = ne(0), [w, q] = ee(() => {
2169
+ const v = {};
2170
+ return t.forEach((y) => {
2171
+ y.type === "multi-variable" && y.key && (v[y.key] = 1);
2172
+ }), v;
2173
+ }), N = ne({}), K = ne({}), U = ne({});
2174
+ pe(() => {
2175
+ K.current = o;
2176
+ }, [o]), pe(() => {
2177
+ U.current = w;
2178
+ }, [w]);
2179
+ const ae = le((v) => v.find(($) => $.type === "tag")?.text || null, []), ce = ne(t), oe = ne(null);
2180
+ pe(() => {
2181
+ const v = ae(ce.current), y = ae(t);
2182
+ if (v && v !== y && n.current) {
2175
2183
  const $ = {};
2176
- n.current.querySelectorAll('[data-type="variable"]').forEach((A) => {
2177
- const j = A.dataset.key;
2184
+ n.current.querySelectorAll('[data-type="variable"]').forEach((L) => {
2185
+ const j = L.dataset.key;
2178
2186
  if (j) {
2179
- const V = A.innerText.replace(/[\u200B\n]/g, "").trim();
2187
+ const V = L.innerText.replace(/[\u200B\n]/g, "").trim();
2180
2188
  V && ($[j] = V);
2181
2189
  }
2182
- }), n.current.querySelectorAll('[data-type="select"]').forEach((A) => {
2183
- const j = A.dataset.key;
2190
+ }), n.current.querySelectorAll('[data-type="select"]').forEach((L) => {
2191
+ const j = L.dataset.key;
2184
2192
  if (j) {
2185
- const V = (A.getAttribute("data-value") || "").trim();
2193
+ const V = (L.getAttribute("data-value") || "").trim();
2186
2194
  V && ($[j] = V);
2187
2195
  }
2188
- }), n.current.querySelectorAll('[data-type="textarea"]').forEach((A) => {
2189
- const j = A.dataset.key;
2196
+ }), n.current.querySelectorAll('[data-type="textarea"]').forEach((L) => {
2197
+ const j = L.dataset.key;
2190
2198
  if (j) {
2191
- const V = A.value.replace(/[\u200B]/g, "").trim();
2199
+ const V = L.value.replace(/[\u200B]/g, "").trim();
2192
2200
  V && ($[j] = V);
2193
2201
  }
2194
- }), _.current[b] = {
2202
+ }), N.current[v] = {
2195
2203
  variableValues: $,
2196
- files: { ...L.current },
2197
- multiVariableCounts: { ...K.current }
2204
+ files: { ...K.current },
2205
+ multiVariableCounts: { ...U.current }
2198
2206
  };
2199
2207
  }
2200
- if (m && _.current[m]) {
2201
- const $ = _.current[m];
2202
- re.current = $, p($.files), v($.multiVariableCounts);
2203
- } else if (m) {
2204
- re.current = null;
2208
+ if (y && N.current[y]) {
2209
+ const $ = N.current[y];
2210
+ oe.current = $, p($.files), q($.multiVariableCounts);
2211
+ } else if (y) {
2212
+ oe.current = null;
2205
2213
  const $ = {};
2206
- t.forEach((B) => {
2207
- B.type === "multi-variable" && B.key && ($[B.key] = 1);
2208
- }), v($), p({});
2214
+ t.forEach((O) => {
2215
+ O.type === "multi-variable" && O.key && ($[O.key] = 1);
2216
+ }), q($), p({});
2209
2217
  } else
2210
- re.current = null, v({}), p({});
2211
- ae.current = t;
2212
- }, [t, U]), We(() => {
2213
- re.current && n.current && (n.current.__tempVariableValues = re.current.variableValues, setTimeout(() => {
2214
- re.current && (re.current = null);
2218
+ oe.current = null, q({}), p({});
2219
+ ce.current = t;
2220
+ }, [t, ae]), Ke(() => {
2221
+ oe.current && n.current && (n.current.__tempVariableValues = oe.current.variableValues, setTimeout(() => {
2222
+ oe.current && (oe.current = null);
2215
2223
  }, 0));
2216
- }), Ft(n, t, o, E, d, te, void 0, r), zt(n, t, o, G), Yt(n, t, G, r), Wt(n, t, o, G), jt(n, t, G), Kt(n, t, o, O), Ut(n, R);
2217
- const pe = Gt(n);
2218
- ue(() => {
2224
+ }), zt(n, t, o, E, w, Z, void 0, r), Yt(n, t, o, G), jt(n, t, G, r), Kt(n, t, o, G), Wt(n, t, G), Ut(n, t, o, B), Xt(n, R);
2225
+ const me = Rt(n);
2226
+ pe(() => {
2219
2227
  if (!n.current) return;
2220
- n.current.querySelectorAll(".rte-richtext-toggle").forEach((m) => {
2221
- const $ = m.getAttribute("data-expanded") === "true";
2222
- m.innerHTML = $ ? '<i class="iconfont icon-shouqi1"></i><span class="rte-richtext-toggle-label">收起</span>' : '<i class="iconfont icon-zhankai2"></i><span class="rte-richtext-toggle-label">展开</span>';
2228
+ n.current.querySelectorAll(".rte-richtext-toggle").forEach((y) => {
2229
+ const $ = y.getAttribute("data-expanded") === "true";
2230
+ y.innerHTML = $ ? '<i class="iconfont icon-shouqi1"></i><span class="rte-richtext-toggle-label">收起</span>' : '<i class="iconfont icon-zhankai2"></i><span class="rte-richtext-toggle-label">展开</span>';
2223
2231
  });
2224
2232
  }, [t, n]);
2225
- const ye = un(n);
2226
- ue(() => {
2233
+ const ye = dn(n);
2234
+ pe(() => {
2227
2235
  if (t.length > 0) {
2228
2236
  h(!1);
2229
2237
  return;
2230
2238
  }
2231
- const b = () => {
2239
+ const v = () => {
2232
2240
  if (!n.current) {
2233
2241
  h(!0);
2234
2242
  return;
2235
2243
  }
2236
- const $ = n.current.textContent?.replace(/[\u200B\n]/g, "").trim() || "", B = n.current.querySelectorAll('[data-type="variable"]'), N = n.current.querySelectorAll('[data-type="upload"]');
2244
+ const $ = n.current.textContent?.replace(/[\u200B\n]/g, "").trim() || "", O = n.current.querySelectorAll('[data-type="variable"]'), _ = n.current.querySelectorAll('[data-type="upload"]');
2237
2245
  let I = !1;
2238
- B.forEach((j) => {
2246
+ O.forEach((j) => {
2239
2247
  (j.textContent?.replace(/[\u200B\n]/g, "").trim() || "") && (I = !0);
2240
- }), N.forEach((j) => {
2248
+ }), _.forEach((j) => {
2241
2249
  j.querySelector(".upload-inner-wrapper.has-file") && (I = !0);
2242
2250
  });
2243
- const A = !$ && !I;
2244
- h(A), t.length === 0 && O(!A);
2251
+ const L = !$ && !I;
2252
+ h(L), t.length === 0 && B(!L);
2245
2253
  };
2246
- b();
2247
- const m = new MutationObserver(b);
2248
- return n.current && m.observe(n.current, {
2254
+ v();
2255
+ const y = new MutationObserver(v);
2256
+ return n.current && y.observe(n.current, {
2249
2257
  childList: !0,
2250
2258
  subtree: !0,
2251
2259
  characterData: !0
2252
2260
  }), () => {
2253
- m.disconnect();
2261
+ y.disconnect();
2254
2262
  };
2255
2263
  }, [t]);
2256
- const me = (b) => {
2264
+ const xe = (v) => {
2257
2265
  if (s) {
2258
- b.preventDefault();
2266
+ v.preventDefault();
2259
2267
  return;
2260
2268
  }
2261
- b.preventDefault();
2262
- const m = b.clipboardData.getData("text/plain"), $ = window.getSelection();
2269
+ v.preventDefault();
2270
+ const y = v.clipboardData.getData("text/plain"), $ = window.getSelection();
2263
2271
  if ($ && $.rangeCount > 0) {
2264
- const B = $.anchorNode;
2265
- if (B) {
2266
- let N = null;
2267
- if (B.nodeType === Node.ELEMENT_NODE ? N = B.closest('[data-type="variable"]') : B.nodeType === Node.TEXT_NODE && B.parentElement && (N = B.parentElement.closest('[data-type="variable"]')), N) {
2268
- const I = N.dataset.multiKey;
2272
+ const O = $.anchorNode;
2273
+ if (O) {
2274
+ let _ = null;
2275
+ if (O.nodeType === Node.ELEMENT_NODE ? _ = O.closest('[data-type="variable"]') : O.nodeType === Node.TEXT_NODE && O.parentElement && (_ = O.parentElement.closest('[data-type="variable"]')), _) {
2276
+ const I = _.dataset.multiKey;
2269
2277
  if (I) {
2270
- const A = /[、,,\s\n\r\t]+/, j = m.split(A).map((V) => V.trim()).filter((V) => V.length > 0);
2271
- if (console.log("[Paste Event] 粘贴的内容:", m), console.log("[Paste Event] 拆分后的值:", j), j.length > 1) {
2272
- const V = parseInt(N.dataset.index || "0", 10), z = t.find((le) => le.type === "multi-variable" && le.key === I)?.maxCount || 9, W = d[I] || 1, D = Math.min(V + j.length, z);
2273
- D > W && v((Q) => ({
2278
+ const L = /[、,,\s\n\r\t]+/, j = y.split(L).map((V) => V.trim()).filter((V) => V.length > 0);
2279
+ if (console.log("[Paste Event] 粘贴的内容:", y), console.log("[Paste Event] 拆分后的值:", j), j.length > 1) {
2280
+ const V = parseInt(_.dataset.index || "0", 10), z = t.find((se) => se.type === "multi-variable" && se.key === I)?.maxCount || 9, W = w[I] || 1, M = Math.min(V + j.length, z);
2281
+ M > W && q((Q) => ({
2274
2282
  ...Q,
2275
- [I]: D
2283
+ [I]: M
2276
2284
  }));
2277
2285
  const Y = [];
2278
2286
  for (let Q = 0; Q < W; Q++) {
2279
- const le = `${I}_${Q}`, ce = n.current.querySelector(
2280
- `[data-type="variable"][data-key="${le}"][data-multi-key="${I}"]`
2287
+ const se = `${I}_${Q}`, de = n.current.querySelector(
2288
+ `[data-type="variable"][data-key="${se}"][data-multi-key="${I}"]`
2281
2289
  );
2282
- if (ce) {
2283
- const ve = ce.innerText.replace(/[\u200B\n]/g, "").trim();
2290
+ if (de) {
2291
+ const ve = de.innerText.replace(/[\u200B\n]/g, "").trim();
2284
2292
  Y.push(ve);
2285
2293
  }
2286
2294
  }
2287
2295
  Y.splice(V, 1, ...j.slice(0, z - V));
2288
2296
  const J = Y.slice(0, z);
2289
2297
  J.length > 0 && J[J.length - 1] !== "" && J.length < z && J.push("");
2290
- const H = Math.max(J.length, 1), ee = {};
2291
- J.forEach((Q, le) => {
2292
- Q && (ee[`${I}_${le}`] = Q);
2298
+ const H = Math.max(J.length, 1), te = {};
2299
+ J.forEach((Q, se) => {
2300
+ Q && (te[`${I}_${se}`] = Q);
2293
2301
  }), n.current.querySelectorAll(
2294
2302
  '[data-type="variable"]'
2295
2303
  ).forEach((Q) => {
2296
- const le = Q.dataset.key, ce = Q.dataset.multiKey;
2297
- if (le && ce !== I) {
2304
+ const se = Q.dataset.key, de = Q.dataset.multiKey;
2305
+ if (se && de !== I) {
2298
2306
  const ve = Q.innerText.replace(/[\u200B\n]/g, "").trim();
2299
- ve && (ee[le] = ve);
2307
+ ve && (te[se] = ve);
2300
2308
  }
2301
- }), n.current.__tempVariableValues = ee, v((Q) => ({
2309
+ }), n.current.__tempVariableValues = te, q((Q) => ({
2302
2310
  ...Q,
2303
2311
  [I]: H
2304
2312
  })), console.log("[Paste Event] 粘贴完成,已填充到多个输入框,值:", J);
@@ -2308,352 +2316,362 @@ const { RangePicker: ln } = mt, cn = ({ host: t, onChange: u }) => {
2308
2316
  }
2309
2317
  }
2310
2318
  }
2311
- document.execCommand("insertText", !1, m), Ce(), setTimeout(() => {
2312
- const B = window.getSelection();
2313
- if (B && B.rangeCount > 0) {
2314
- const N = B.anchorNode;
2315
- if (N) {
2319
+ document.execCommand("insertText", !1, y), Ye(), setTimeout(() => {
2320
+ const O = window.getSelection();
2321
+ if (O && O.rangeCount > 0) {
2322
+ const _ = O.anchorNode;
2323
+ if (_) {
2316
2324
  let I = null;
2317
- if (N.nodeType === Node.ELEMENT_NODE ? I = N.closest('[data-type="variable"][data-multi-key]') : N.nodeType === Node.TEXT_NODE && N.parentElement && (I = N.parentElement.closest('[data-type="variable"][data-multi-key]')), I) {
2318
- const A = I.innerText.replace(/[\u200B\n]/g, "").trim();
2319
- /[、,,\s]+/.test(A) && (console.log("[Paste Event] 粘贴后检测到分隔符,内容:", A), console.log("[Paste Event] 提示:失去焦点后将自动拆分"));
2325
+ if (_.nodeType === Node.ELEMENT_NODE ? I = _.closest('[data-type="variable"][data-multi-key]') : _.nodeType === Node.TEXT_NODE && _.parentElement && (I = _.parentElement.closest('[data-type="variable"][data-multi-key]')), I) {
2326
+ const L = I.innerText.replace(/[\u200B\n]/g, "").trim();
2327
+ /[、,,\s]+/.test(L) && (console.log("[Paste Event] 粘贴后检测到分隔符,内容:", L), console.log("[Paste Event] 提示:失去焦点后将自动拆分"));
2320
2328
  }
2321
2329
  }
2322
2330
  }
2323
2331
  }, 0);
2324
- }, xe = (b) => {
2325
- if (!b.target.files) {
2326
- b.target && (b.target.value = ""), x(null), P(null);
2332
+ }, X = (v) => {
2333
+ if (!v.target.files) {
2334
+ v.target && (v.target.value = ""), x(null), P(null);
2327
2335
  return;
2328
2336
  }
2329
- if (T && b.target.files && b.target.files.length > 0) {
2330
- const m = T, $ = t.find((B) => B.type === "upload" && B.key === m);
2337
+ if (A && v.target.files && v.target.files.length > 0) {
2338
+ const y = A, $ = t.find((O) => O.type === "upload" && O.key === y);
2331
2339
  if ($ && typeof $.maxCount == "number" && typeof $.minCount == "number") {
2332
- const B = $.maxCount, N = Array.from(b.target.files);
2340
+ const O = $.maxCount, _ = Array.from(v.target.files);
2333
2341
  let I = 0;
2334
- p((A) => {
2335
- for (let W = 0; W < B; W++) {
2336
- const D = `${m}-${W}`;
2337
- A[D] && (I = W + 1);
2342
+ p((L) => {
2343
+ for (let W = 0; W < O; W++) {
2344
+ const M = `${y}-${W}`;
2345
+ L[M] && (I = W + 1);
2338
2346
  }
2339
- const j = B - I, V = N.slice(0, j), z = { ...A };
2340
- return V.forEach((W, D) => {
2341
- const Y = `${m}-${I + D}`;
2347
+ const j = O - I, V = _.slice(0, j), z = { ...L };
2348
+ return V.forEach((W, M) => {
2349
+ const Y = `${y}-${I + M}`;
2342
2350
  z[Y] = W;
2343
2351
  }), z;
2344
2352
  });
2345
2353
  }
2346
- } else if (l && b.target.files[0]) {
2347
- const m = b.target.files[0], $ = l;
2348
- p((B) => ({ ...B, [$]: m }));
2354
+ } else if (l && v.target.files[0]) {
2355
+ const y = v.target.files[0], $ = l;
2356
+ p((O) => ({ ...O, [$]: y }));
2349
2357
  }
2350
- b.target && (b.target.value = ""), x(null), P(null);
2351
- }, X = (b) => {
2352
- p((m) => {
2353
- const $ = { ...m };
2354
- return delete $[b], $;
2358
+ v.target && (v.target.value = ""), x(null), P(null);
2359
+ }, fe = (v) => {
2360
+ p((y) => {
2361
+ const $ = { ...y };
2362
+ return delete $[v], $;
2355
2363
  });
2356
- }, fe = (b) => {
2357
- const m = b.target;
2358
- if (m.closest(".rte-datepicker-wrapper") || m.closest(".rte-datepicker-host") || m.closest(".rte-select-wrapper") || m.closest(".rte-select-host") || m.closest(".ant-select-dropdown"))
2364
+ }, ge = (v) => {
2365
+ const y = v.target;
2366
+ if (y.closest(".rte-datepicker-wrapper") || y.closest(".rte-datepicker-host") || y.closest(".rte-select-wrapper") || y.closest(".rte-select-host") || y.closest(".ant-select-dropdown"))
2359
2367
  return;
2360
- if (m.closest(".tag-close-btn")) {
2361
- if (b.preventDefault(), b.stopPropagation(), E)
2368
+ if (y.closest(".tag-close-btn")) {
2369
+ if (v.preventDefault(), v.stopPropagation(), E)
2362
2370
  return;
2363
2371
  G(null), g ? g() : n.current && (n.current.innerHTML = "", n.current.focus());
2364
2372
  return;
2365
2373
  }
2366
2374
  if (E) {
2367
- const N = m.closest(".tag-node"), I = m.closest('[data-type="text"]');
2368
- if (N || I) {
2369
- b.preventDefault(), b.stopPropagation();
2370
- const A = window.getSelection();
2371
- A && A.removeAllRanges();
2375
+ const _ = y.closest(".tag-node"), I = y.closest('[data-type="text"]');
2376
+ if (_ || I) {
2377
+ v.preventDefault(), v.stopPropagation();
2378
+ const L = window.getSelection();
2379
+ L && L.removeAllRanges();
2372
2380
  return;
2373
2381
  }
2374
2382
  }
2375
- m.closest('[data-type="variable"]') || (M.current = { x: b.clientX, y: b.clientY }, R.current = !1, m.closest(".file-remove-btn") && (b.preventDefault(), b.stopPropagation()));
2376
- }, ge = (b) => {
2377
- if (!b.target.closest('[data-type="variable"]') && M.current) {
2378
- const B = Math.abs(b.clientX - M.current.x), N = Math.abs(b.clientY - M.current.y);
2379
- (B > 3 || N > 3) && (R.current = !0);
2383
+ y.closest('[data-type="variable"]') || (D.current = { x: v.clientX, y: v.clientY }, R.current = !1, y.closest(".file-remove-btn") && (v.preventDefault(), v.stopPropagation()));
2384
+ }, he = (v) => {
2385
+ if (!v.target.closest('[data-type="variable"]') && D.current) {
2386
+ const O = Math.abs(v.clientX - D.current.x), _ = Math.abs(v.clientY - D.current.y);
2387
+ (O > 3 || _ > 3) && (R.current = !0);
2380
2388
  }
2381
- }, he = (b) => {
2382
- if (b.target.closest('[data-type="variable"]')) {
2383
- M.current = null, R.current = !1;
2389
+ }, we = (v) => {
2390
+ if (v.target.closest('[data-type="variable"]')) {
2391
+ D.current = null, R.current = !1;
2384
2392
  return;
2385
2393
  }
2386
- M.current = null, R.current = !1;
2387
- }, ke = (b) => {
2394
+ D.current = null, R.current = !1;
2395
+ }, $e = (v) => {
2388
2396
  if (s)
2389
2397
  return;
2390
- const m = b.target;
2391
- if (m.closest('[data-type="datepicker"]'))
2398
+ const y = v.target;
2399
+ if (y.closest('[data-type="datepicker"]'))
2392
2400
  return;
2393
- if (m.closest(".tag-close-btn")) {
2394
- b.preventDefault(), b.stopPropagation();
2401
+ if (y.closest(".tag-close-btn")) {
2402
+ v.preventDefault(), v.stopPropagation();
2395
2403
  return;
2396
2404
  }
2397
2405
  if (t.length === 0)
2398
2406
  return;
2399
- const N = (D, Y) => {
2407
+ const _ = (M, Y) => {
2400
2408
  if (!n.current) return;
2401
2409
  Array.from(n.current.children).forEach((H) => {
2402
- if (H !== D)
2410
+ if (H !== M)
2403
2411
  if (Y)
2404
2412
  H.dataset.prevDisplay === void 0 && (H.dataset.prevDisplay = H.style.display || ""), H.style.setProperty("display", "none", "important");
2405
2413
  else if (H.dataset.prevDisplay !== void 0) {
2406
- const ee = H.dataset.prevDisplay;
2407
- ee ? H.style.display = ee : H.style.removeProperty("display"), delete H.dataset.prevDisplay;
2414
+ const te = H.dataset.prevDisplay;
2415
+ te ? H.style.display = te : H.style.removeProperty("display"), delete H.dataset.prevDisplay;
2408
2416
  } else
2409
2417
  H.style.removeProperty("display");
2410
2418
  });
2411
- }, I = m.closest(".rte-textarea-toggle");
2419
+ }, I = y.closest(".rte-textarea-toggle");
2412
2420
  if (I) {
2413
- b.preventDefault(), b.stopPropagation();
2414
- const D = I.closest(".rte-textarea-wrapper"), Y = D?.querySelector('[data-type="textarea"]'), H = !(I.getAttribute("data-expanded") === "true");
2415
- I.setAttribute("data-expanded", String(H)), I.textContent = H ? "收起" : "展开", D && D.classList.toggle("rte-textarea-expanded", H);
2416
- const ee = D?.closest(".rte-textarea-required");
2417
- if (ee ? ee.classList.toggle("rte-textarea-overlay", H) : D && D.classList.toggle("rte-textarea-overlay", H), Y)
2421
+ v.preventDefault(), v.stopPropagation();
2422
+ const M = I.closest(".rte-textarea-wrapper"), Y = M?.querySelector('[data-type="textarea"]'), H = !(I.getAttribute("data-expanded") === "true");
2423
+ I.setAttribute("data-expanded", String(H)), I.textContent = H ? "收起" : "展开", M && M.classList.toggle("rte-textarea-expanded", H);
2424
+ const te = M?.closest(".rte-textarea-required");
2425
+ if (te ? te.classList.toggle("rte-textarea-overlay", H) : M && M.classList.toggle("rte-textarea-overlay", H), Y)
2418
2426
  if (H)
2419
2427
  Y.classList.add("rte-textarea-expanded"), Y.style.maxHeight = "none", Y.style.height = "100%";
2420
2428
  else {
2421
2429
  Y.classList.remove("rte-textarea-expanded");
2422
- const ie = Y.dataset.maxHeight || "252";
2423
- Y.style.maxHeight = `${ie}px`, Y.style.height = "auto";
2430
+ const ue = Y.dataset.maxHeight || "252";
2431
+ Y.style.maxHeight = `${ue}px`, Y.style.height = "auto";
2424
2432
  }
2425
2433
  n.current && (H ? n.current.classList.add("rte-overlay-active") : n.current.classList.remove("rte-overlay-active"));
2426
2434
  return;
2427
2435
  }
2428
- const A = m.closest(".rte-richtext-toggle");
2429
- if (A) {
2430
- b.preventDefault(), b.stopPropagation();
2431
- const D = A.closest(".rte-richtext-wrapper"), Y = D?.querySelector('[data-type="richtext"]'), H = !(A.getAttribute("data-expanded") === "true");
2432
- ((le, ce) => {
2433
- le.setAttribute("data-expanded", String(ce)), le.innerHTML = ce ? '<i class="iconfont icon-shouqi1"></i><span class="rte-richtext-toggle-label">收起</span>' : '<i class="iconfont icon-zhankai2"></i><span class="rte-richtext-toggle-label">展开</span>';
2434
- })(A, H);
2435
- const ie = D?.closest(".rte-richtext-required");
2436
- ie ? ie.classList.toggle("rte-richtext-expanded", H) : D && D.classList.toggle("rte-richtext-expanded", H);
2437
- const Q = D?.closest(".exclusion-wrapper") || D?.parentElement;
2438
- Y && (H ? (Y.style.height = "100%", Y.style.overflow = "auto") : (Y.style.height = "", Y.style.overflow = "")), Q && (Q.classList.toggle("rte-richtext-host-expanded", H), N(Q, H)), n.current && n.current.classList.toggle("rte-richtext-fullscreen-active", H);
2436
+ const L = y.closest(".rte-richtext-toggle");
2437
+ if (L) {
2438
+ v.preventDefault(), v.stopPropagation();
2439
+ const M = L.closest(".rte-richtext-wrapper"), Y = M?.querySelector('[data-type="richtext"]'), H = !(L.getAttribute("data-expanded") === "true");
2440
+ ((se, de) => {
2441
+ se.setAttribute("data-expanded", String(de)), se.innerHTML = de ? '<i class="iconfont icon-shouqi1"></i><span class="rte-richtext-toggle-label">收起</span>' : '<i class="iconfont icon-zhankai2"></i><span class="rte-richtext-toggle-label">展开</span>';
2442
+ })(L, H);
2443
+ const ue = M?.closest(".rte-richtext-required");
2444
+ ue ? ue.classList.toggle("rte-richtext-expanded", H) : M && M.classList.toggle("rte-richtext-expanded", H);
2445
+ const Q = M?.closest(".exclusion-wrapper") || M?.parentElement;
2446
+ if (Y && (H ? (Y.style.height = "100%", Y.style.overflow = "auto") : (Y.style.height = "", Y.style.overflow = "")), Q && (Q.classList.toggle("rte-richtext-host-expanded", H), _(Q, H)), n.current)
2447
+ if (n.current.classList.toggle("rte-richtext-fullscreen-active", H), H)
2448
+ f.current = n.current.scrollTop || 0, setTimeout(() => {
2449
+ n.current && (n.current.scrollTop = 0, n.current.scrollLeft = 0);
2450
+ }, 0);
2451
+ else {
2452
+ const se = f.current || 0;
2453
+ setTimeout(() => {
2454
+ n.current && (n.current.scrollTop = se);
2455
+ }, 0);
2456
+ }
2439
2457
  return;
2440
2458
  }
2441
- if (m.closest('[data-type="text"]')) {
2442
- b.preventDefault(), b.stopPropagation();
2443
- const D = window.getSelection();
2444
- D && D.removeAllRanges();
2459
+ if (y.closest('[data-type="text"]')) {
2460
+ v.preventDefault(), v.stopPropagation();
2461
+ const M = window.getSelection();
2462
+ M && M.removeAllRanges();
2445
2463
  return;
2446
2464
  }
2447
- if (E && m.closest(".tag-node")) {
2448
- b.preventDefault(), b.stopPropagation();
2465
+ if (E && y.closest(".tag-node")) {
2466
+ v.preventDefault(), v.stopPropagation();
2449
2467
  const Y = window.getSelection();
2450
2468
  Y && Y.removeAllRanges();
2451
2469
  return;
2452
2470
  }
2453
- if (m.closest('[data-type="variable"]')) {
2471
+ if (y.closest('[data-type="variable"]')) {
2454
2472
  if (R.current)
2455
2473
  return;
2456
2474
  setTimeout(() => {
2457
- const D = window.getSelection();
2458
- D && !D.isCollapsed || Oe(n);
2475
+ const M = window.getSelection();
2476
+ M && !M.isCollapsed || Oe(n);
2459
2477
  }, 10);
2460
2478
  return;
2461
2479
  }
2462
- const z = m.closest(".file-remove-btn");
2480
+ const z = y.closest(".file-remove-btn");
2463
2481
  if (z) {
2464
- b.preventDefault(), b.stopPropagation();
2465
- const D = z.closest('[data-type="upload"]'), Y = D?.dataset.key, J = D?.dataset.batchKey;
2482
+ v.preventDefault(), v.stopPropagation();
2483
+ const M = z.closest('[data-type="upload"]'), Y = M?.dataset.key, J = M?.dataset.batchKey;
2466
2484
  if (Y)
2467
2485
  if (J) {
2468
- const H = t.find((ee) => ee.type === "upload" && ee.key === J);
2486
+ const H = t.find((te) => te.type === "upload" && te.key === J);
2469
2487
  if (H && typeof H.maxCount == "number" && typeof H.minCount == "number") {
2470
- const ee = H.maxCount;
2471
- p((ie) => {
2472
- const Q = { ...ie }, le = [];
2473
- for (let ce = 0; ce < ee; ce++) {
2474
- const ve = `${J}-${ce}`, we = Q[ve];
2475
- we != null && ve !== Y && le.push(we);
2488
+ const te = H.maxCount;
2489
+ p((ue) => {
2490
+ const Q = { ...ue }, se = [];
2491
+ for (let de = 0; de < te; de++) {
2492
+ const ve = `${J}-${de}`, ke = Q[ve];
2493
+ ke != null && ve !== Y && se.push(ke);
2476
2494
  }
2477
- for (let ce = 0; ce < ee; ce++)
2478
- delete Q[`${J}-${ce}`];
2479
- return le.forEach((ce, ve) => {
2480
- Q[`${J}-${ve}`] = ce;
2495
+ for (let de = 0; de < te; de++)
2496
+ delete Q[`${J}-${de}`];
2497
+ return se.forEach((de, ve) => {
2498
+ Q[`${J}-${ve}`] = de;
2481
2499
  }), Q;
2482
2500
  });
2483
2501
  } else
2484
- X(Y);
2502
+ fe(Y);
2485
2503
  } else
2486
- X(Y);
2504
+ fe(Y);
2487
2505
  return;
2488
2506
  }
2489
- const W = m.closest('[data-type="upload"]');
2507
+ const W = y.closest('[data-type="upload"]');
2490
2508
  if (W) {
2491
- const D = W.dataset.key, Y = W.dataset.batchKey;
2492
- if (D)
2509
+ const M = W.dataset.key, Y = W.dataset.batchKey;
2510
+ if (M)
2493
2511
  if (Y) {
2494
2512
  const J = t.find((H) => H.type === "upload" && H.key === Y);
2495
2513
  if (J && typeof J.maxCount == "number" && typeof J.minCount == "number") {
2496
2514
  const H = J.maxCount;
2497
- let ee = 0;
2498
- for (let ie = 0; ie < H; ie++)
2499
- o[`${Y}-${ie}`] != null && (ee += 1);
2500
- ee < H && a.current ? (a.current.multiple = !0, P(Y), a.current.click()) : (a.current && (a.current.multiple = !1), x(D), a.current?.click());
2515
+ let te = 0;
2516
+ for (let ue = 0; ue < H; ue++)
2517
+ o[`${Y}-${ue}`] != null && (te += 1);
2518
+ te < H && a.current ? (a.current.multiple = !0, P(Y), a.current.click()) : (a.current && (a.current.multiple = !1), x(M), a.current?.click());
2501
2519
  } else
2502
- a.current && (a.current.multiple = !1), x(D), a.current?.click();
2520
+ a.current && (a.current.multiple = !1), x(M), a.current?.click();
2503
2521
  } else
2504
- a.current && (a.current.multiple = !1), x(D), a.current?.click();
2522
+ a.current && (a.current.multiple = !1), x(M), a.current?.click();
2505
2523
  return;
2506
2524
  }
2507
- }, Ee = (b) => {
2508
- const $ = b.target.closest('[data-type="variable"]');
2525
+ }, Se = (v) => {
2526
+ const $ = v.target.closest('[data-type="variable"]');
2509
2527
  if ($) {
2510
- const B = window.getSelection();
2511
- if (B) {
2512
- const N = document.createRange(), I = $.textContent || "";
2528
+ const O = window.getSelection();
2529
+ if (O) {
2530
+ const _ = document.createRange(), I = $.textContent || "";
2513
2531
  if (I.replace(/\u200B/g, "")) {
2514
2532
  let j = 0, V = I.length;
2515
2533
  I.startsWith("​") && (j = 1), I.endsWith("​") && I.length > 1 && (V = I.length - 1);
2516
2534
  const z = $.firstChild;
2517
- z && z.nodeType === Node.TEXT_NODE ? (N.setStart(z, j), N.setEnd(z, V)) : N.selectNodeContents($);
2535
+ z && z.nodeType === Node.TEXT_NODE ? (_.setStart(z, j), _.setEnd(z, V)) : _.selectNodeContents($);
2518
2536
  } else
2519
- N.selectNodeContents($), N.collapse(!0);
2520
- B.removeAllRanges(), B.addRange(N);
2537
+ _.selectNodeContents($), _.collapse(!0);
2538
+ O.removeAllRanges(), O.addRange(_);
2521
2539
  }
2522
2540
  }
2523
- }, Ce = () => {
2541
+ }, Ye = () => {
2524
2542
  if (t.length === 0) {
2525
2543
  if (n.current) {
2526
2544
  const $ = !(n.current.textContent?.replace(/[\u200B\n]/g, "").trim() || "");
2527
- h($), O(!$);
2545
+ h($), B(!$);
2528
2546
  }
2529
2547
  return;
2530
2548
  }
2531
2549
  if (Oe(n), n.current && n.current.querySelectorAll('[data-type="variable"]').forEach(($) => {
2532
- const B = $.querySelector(".variable-info-icon");
2533
- if (B) {
2534
- let N = !1;
2550
+ const O = $.querySelector(".variable-info-icon");
2551
+ if (O) {
2552
+ let _ = !1;
2535
2553
  const I = document.createTreeWalker(
2536
2554
  $,
2537
2555
  NodeFilter.SHOW_TEXT,
2538
2556
  {
2539
- acceptNode: (A) => B.contains(A) ? NodeFilter.FILTER_REJECT : NodeFilter.FILTER_ACCEPT
2557
+ acceptNode: (L) => O.contains(L) ? NodeFilter.FILTER_REJECT : NodeFilter.FILTER_ACCEPT
2540
2558
  }
2541
2559
  );
2542
2560
  for (; I.nextNode(); )
2543
2561
  if (I.currentNode.textContent?.replace(/[\u200B\n]/g, "").trim()) {
2544
- N = !0;
2562
+ _ = !0;
2545
2563
  break;
2546
2564
  }
2547
- N ? B.classList.add("hidden") : B.classList.remove("hidden");
2565
+ _ ? O.classList.add("hidden") : O.classList.remove("hidden");
2548
2566
  }
2549
- }), He(n, t, o), Ge(n, t, o, O), !n.current) return;
2550
- t.filter((m) => m.type === "multi-variable" && m.key).forEach((m) => {
2551
- if (!m.key) return;
2552
- const $ = m.maxCount || 9, B = d[m.key] || 1, N = [];
2553
- for (let z = 0; z < B; z++) {
2554
- const W = `${m.key}_${z}`, D = n.current.querySelector(
2555
- `[data-type="variable"][data-key="${W}"][data-multi-key="${m.key}"]`
2567
+ }), He(n, t, o), Ge(n, t, o, B), !n.current) return;
2568
+ t.filter((y) => y.type === "multi-variable" && y.key).forEach((y) => {
2569
+ if (!y.key) return;
2570
+ const $ = y.maxCount || 9, O = w[y.key] || 1, _ = [];
2571
+ for (let z = 0; z < O; z++) {
2572
+ const W = `${y.key}_${z}`, M = n.current.querySelector(
2573
+ `[data-type="variable"][data-key="${W}"][data-multi-key="${y.key}"]`
2556
2574
  );
2557
- if (D) {
2558
- const Y = D.innerText.replace(/[\u200B\n]/g, "").trim();
2559
- N.push(Y);
2575
+ if (M) {
2576
+ const Y = M.innerText.replace(/[\u200B\n]/g, "").trim();
2577
+ _.push(Y);
2560
2578
  }
2561
2579
  }
2562
- const A = (N[N.length - 1] || "") === "";
2580
+ const L = (_[_.length - 1] || "") === "";
2563
2581
  let j = !1, V = -1;
2564
- for (let z = 0; z < N.length - 1; z++)
2565
- if (N[z] === "") {
2582
+ for (let z = 0; z < _.length - 1; z++)
2583
+ if (_[z] === "") {
2566
2584
  j = !0, V = z;
2567
2585
  break;
2568
2586
  }
2569
2587
  if (j && V >= 0) {
2570
2588
  const z = window.getSelection();
2571
2589
  if (z && z.rangeCount > 0) {
2572
- const H = z.getRangeAt(0), ee = H.startContainer, ie = ee.nodeType === Node.ELEMENT_NODE ? ee.closest('[data-type="variable"][data-multi-key]') : ee.parentElement?.closest('[data-type="variable"][data-multi-key]');
2573
- if (ie) {
2574
- const Q = ie.dataset.key;
2590
+ const H = z.getRangeAt(0), te = H.startContainer, ue = te.nodeType === Node.ELEMENT_NODE ? te.closest('[data-type="variable"][data-multi-key]') : te.parentElement?.closest('[data-type="variable"][data-multi-key]');
2591
+ if (ue) {
2592
+ const Q = ue.dataset.key;
2575
2593
  if (Q) {
2576
- const le = document.createRange();
2577
- le.setStartBefore(ie), le.setEnd(H.startContainer, H.startOffset);
2578
- const ce = le.toString().length;
2579
- te.current = { key: Q, offset: ce };
2594
+ const se = document.createRange();
2595
+ se.setStartBefore(ue), se.setEnd(H.startContainer, H.startOffset);
2596
+ const de = se.toString().length;
2597
+ Z.current = { key: Q, offset: de };
2580
2598
  }
2581
2599
  }
2582
2600
  }
2583
- const W = [...N];
2601
+ const W = [..._];
2584
2602
  for (let H = V; H < W.length - 1; H++)
2585
2603
  W[H] = W[H + 1];
2586
2604
  W.pop();
2587
- const D = {};
2588
- W.forEach((H, ee) => {
2589
- H && (D[`${m.key}_${ee}`] = H);
2605
+ const M = {};
2606
+ W.forEach((H, te) => {
2607
+ H && (M[`${y.key}_${te}`] = H);
2590
2608
  });
2591
- const Y = Math.max(A ? W.length : W.length + 1, 1);
2609
+ const Y = Math.max(L ? W.length : W.length + 1, 1);
2592
2610
  n.current.querySelectorAll(
2593
2611
  '[data-type="variable"]'
2594
2612
  ).forEach((H) => {
2595
- const ee = H.dataset.key, ie = H.dataset.multiKey;
2596
- if (ee && ie !== m.key) {
2613
+ const te = H.dataset.key, ue = H.dataset.multiKey;
2614
+ if (te && ue !== y.key) {
2597
2615
  const Q = H.innerText.replace(/[\u200B\n]/g, "").trim();
2598
- Q && (D[ee] = Q);
2616
+ Q && (M[te] = Q);
2599
2617
  }
2600
- }), n.current.__tempVariableValues = D, v((H) => ({
2618
+ }), n.current.__tempVariableValues = M, q((H) => ({
2601
2619
  ...H,
2602
- [m.key]: Y
2620
+ [y.key]: Y
2603
2621
  }));
2604
2622
  return;
2605
2623
  }
2606
- if (!A) {
2607
- const z = B - 1, W = `${m.key}_${z}`, D = n.current.querySelector(
2608
- `[data-type="variable"][data-key="${W}"][data-multi-key="${m.key}"]`
2624
+ if (!L) {
2625
+ const z = O - 1, W = `${y.key}_${z}`, M = n.current.querySelector(
2626
+ `[data-type="variable"][data-key="${W}"][data-multi-key="${y.key}"]`
2609
2627
  );
2610
- if (D && D.innerText.replace(/[\u200B\n]/g, "").trim().length > 0 && B < $) {
2628
+ if (M && M.innerText.replace(/[\u200B\n]/g, "").trim().length > 0 && O < $) {
2611
2629
  const J = window.getSelection();
2612
2630
  if (J && J.rangeCount > 0) {
2613
- const H = J.getRangeAt(0), ee = H.startContainer, ie = ee.nodeType === Node.ELEMENT_NODE ? ee.closest('[data-type="variable"][data-multi-key]') : ee.parentElement?.closest('[data-type="variable"][data-multi-key]');
2614
- if (ie) {
2615
- const Q = ie.dataset.key;
2631
+ const H = J.getRangeAt(0), te = H.startContainer, ue = te.nodeType === Node.ELEMENT_NODE ? te.closest('[data-type="variable"][data-multi-key]') : te.parentElement?.closest('[data-type="variable"][data-multi-key]');
2632
+ if (ue) {
2633
+ const Q = ue.dataset.key;
2616
2634
  if (Q) {
2617
- const le = document.createRange();
2618
- le.setStartBefore(ie), le.setEnd(H.startContainer, H.startOffset);
2619
- const ce = le.toString().length;
2620
- te.current = { key: Q, offset: ce };
2635
+ const se = document.createRange();
2636
+ se.setStartBefore(ue), se.setEnd(H.startContainer, H.startOffset);
2637
+ const de = se.toString().length;
2638
+ Z.current = { key: Q, offset: de };
2621
2639
  }
2622
2640
  }
2623
2641
  }
2624
- v((H) => ({
2642
+ q((H) => ({
2625
2643
  ...H,
2626
- [m.key]: B + 1
2644
+ [y.key]: O + 1
2627
2645
  }));
2628
2646
  }
2629
2647
  }
2630
2648
  });
2631
2649
  };
2632
- We(() => {
2633
- const b = n.current;
2634
- if (!b) return;
2635
- const m = /* @__PURE__ */ new Map(), $ = (I) => {
2636
- const A = I.target, j = I.relatedTarget;
2637
- !A || !n.current || !n.current.contains(A) || j && n.current.contains(j) || setTimeout(() => {
2650
+ Ke(() => {
2651
+ const v = n.current;
2652
+ if (!v) return;
2653
+ const y = /* @__PURE__ */ new Map(), $ = (I) => {
2654
+ const L = I.target, j = I.relatedTarget;
2655
+ !L || !n.current || !n.current.contains(L) || j && n.current.contains(j) || setTimeout(() => {
2638
2656
  if (n.current) {
2639
2657
  if (t.length === 0) {
2640
2658
  const V = n.current.textContent?.replace(/[\u200B\n]/g, "").trim() || "";
2641
- O(V.length > 0);
2659
+ B(V.length > 0);
2642
2660
  return;
2643
2661
  }
2644
- Oe(n), He(n, t, o), Ge(n, t, o, O);
2662
+ Oe(n), He(n, t, o), Ge(n, t, o, B);
2645
2663
  }
2646
2664
  }, 0);
2647
2665
  };
2648
- b.addEventListener("blur", $, !0);
2649
- const B = () => {
2666
+ v.addEventListener("blur", $, !0);
2667
+ const O = () => {
2650
2668
  if (!n.current) return;
2651
- m.forEach((j, V) => {
2669
+ y.forEach((j, V) => {
2652
2670
  V.removeEventListener("blur", j, !1);
2653
- }), m.clear();
2671
+ }), y.clear();
2654
2672
  const I = n.current.querySelectorAll(
2655
2673
  '[data-type="variable"][data-multi-key]'
2656
- ), A = (j) => {
2674
+ ), L = (j) => {
2657
2675
  j.stopPropagation(), j.stopImmediatePropagation();
2658
2676
  const V = j.target;
2659
2677
  if (!V || !n.current || !n.current.contains(V))
@@ -2662,271 +2680,271 @@ const { RangePicker: ln } = mt, cn = ({ host: t, onChange: u }) => {
2662
2680
  if (!z || !n.current.contains(z))
2663
2681
  return;
2664
2682
  let W = !1;
2665
- if (m.forEach((le, ce) => {
2666
- (ce === z || ce.contains(V)) && (W = !0);
2683
+ if (y.forEach((se, de) => {
2684
+ (de === z || de.contains(V)) && (W = !0);
2667
2685
  }), !W)
2668
2686
  return;
2669
- const D = z.dataset.multiKey, Y = z.dataset.key, J = z.dataset.index;
2670
- if (!D || !Y || J === void 0) return;
2687
+ const M = z.dataset.multiKey, Y = z.dataset.key, J = z.dataset.index;
2688
+ if (!M || !Y || J === void 0) return;
2671
2689
  const H = j.relatedTarget;
2672
2690
  if (!(!H || !n.current.contains(H)))
2673
2691
  return;
2674
- const ie = z.innerText.replace(/[\u200B\n]/g, "").trim();
2692
+ const ue = z.innerText.replace(/[\u200B\n]/g, "").trim();
2675
2693
  console.log("[Blur Event] 失去焦点的 multi-variable 输入框:", {
2676
- multiKey: D,
2694
+ multiKey: M,
2677
2695
  currentKey: Y,
2678
2696
  index: J,
2679
- content: ie
2697
+ content: ue
2680
2698
  });
2681
2699
  const Q = /[、,,\s]+/;
2682
- if (Q.test(ie)) {
2683
- const le = ie.split(Q).map((we) => we.trim()).filter((we) => we.length > 0);
2684
- console.log("[Blur Event] 拆分前的内容:", ie), console.log("[Blur Event] 拆分后的部分:", le);
2685
- const ve = le.slice(0, 9);
2700
+ if (Q.test(ue)) {
2701
+ const se = ue.split(Q).map((ke) => ke.trim()).filter((ke) => ke.length > 0);
2702
+ console.log("[Blur Event] 拆分前的内容:", ue), console.log("[Blur Event] 拆分后的部分:", se);
2703
+ const ve = se.slice(0, 9);
2686
2704
  if (console.log("[Blur Event] 有效的部分(最多9个):", ve), ve.length > 1) {
2687
- const we = t.find((Ne) => Ne.type === "multi-variable" && Ne.key === D);
2688
- if (we) {
2689
- const Ne = d[D] || 1, Ye = parseInt(J, 10), je = we.maxCount || 9, Ae = [];
2705
+ const ke = t.find((Ne) => Ne.type === "multi-variable" && Ne.key === M);
2706
+ if (ke) {
2707
+ const Ne = w[M] || 1, je = parseInt(J, 10), We = ke.maxCount || 9, Ae = [];
2690
2708
  for (let be = 0; be < Ne; be++) {
2691
- const qe = `${D}_${be}`, _e = n.current.querySelector(
2692
- `[data-type="variable"][data-key="${qe}"][data-multi-key="${D}"]`
2709
+ const Te = `${M}_${be}`, _e = n.current.querySelector(
2710
+ `[data-type="variable"][data-key="${Te}"][data-multi-key="${M}"]`
2693
2711
  );
2694
2712
  if (_e) {
2695
2713
  const Le = _e.innerText.replace(/[\u200B\n]/g, "").trim();
2696
2714
  Ae.push(Le);
2697
2715
  }
2698
2716
  }
2699
- console.log("[Blur Event] 拆分前的所有值:", Ae), console.log("[Blur Event] 当前索引:", Ye), console.log("[Blur Event] 要插入的值:", ve), Ae.splice(Ye, 1, ...ve);
2700
- const $e = Ae.slice(0, je);
2701
- console.log("[Blur Event] 拆分后的所有值:", $e), $e.length > 0 && $e[$e.length - 1] !== "" && $e.length < je && $e.push("");
2702
- const it = Math.max($e.length, 1), Be = {};
2703
- $e.forEach((be, qe) => {
2704
- be && (Be[`${D}_${qe}`] = be);
2717
+ console.log("[Blur Event] 拆分前的所有值:", Ae), console.log("[Blur Event] 当前索引:", je), console.log("[Blur Event] 要插入的值:", ve), Ae.splice(je, 1, ...ve);
2718
+ const Ee = Ae.slice(0, We);
2719
+ console.log("[Blur Event] 拆分后的所有值:", Ee), Ee.length > 0 && Ee[Ee.length - 1] !== "" && Ee.length < We && Ee.push("");
2720
+ const ct = Math.max(Ee.length, 1), Be = {};
2721
+ Ee.forEach((be, Te) => {
2722
+ be && (Be[`${M}_${Te}`] = be);
2705
2723
  }), n.current.querySelectorAll(
2706
2724
  '[data-type="variable"]'
2707
2725
  ).forEach((be) => {
2708
- const qe = be.dataset.key, _e = be.dataset.multiKey;
2709
- if (qe && _e !== D) {
2726
+ const Te = be.dataset.key, _e = be.dataset.multiKey;
2727
+ if (Te && _e !== M) {
2710
2728
  const Le = be.innerText.replace(/[\u200B\n]/g, "").trim();
2711
- Le && (Be[qe] = Le);
2729
+ Le && (Be[Te] = Le);
2712
2730
  }
2713
- }), n.current.__tempVariableValues = Be, v((be) => ({
2731
+ }), n.current.__tempVariableValues = Be, q((be) => ({
2714
2732
  ...be,
2715
- [D]: it
2733
+ [M]: ct
2716
2734
  }));
2717
2735
  }
2718
2736
  }
2719
2737
  }
2720
2738
  };
2721
2739
  I.forEach((j) => {
2722
- j.addEventListener("blur", A, !1), m.set(j, A);
2740
+ j.addEventListener("blur", L, !1), y.set(j, L);
2723
2741
  });
2724
- }, N = setTimeout(() => {
2725
- B();
2742
+ }, _ = setTimeout(() => {
2743
+ O();
2726
2744
  }, 0);
2727
2745
  return () => {
2728
- clearTimeout(N), b.removeEventListener("blur", $, !0), m.forEach((I, A) => {
2729
- A.removeEventListener("blur", I, !1);
2730
- }), m.clear();
2746
+ clearTimeout(_), v.removeEventListener("blur", $, !0), y.forEach((I, L) => {
2747
+ L.removeEventListener("blur", I, !1);
2748
+ }), y.clear();
2731
2749
  };
2732
- }, [t, d, o]);
2733
- const ot = (b) => {
2750
+ }, [t, w, o]);
2751
+ const st = (v) => {
2734
2752
  if (s) {
2735
- b.preventDefault();
2753
+ v.preventDefault();
2736
2754
  return;
2737
2755
  }
2738
- if (b.key === "Enter") {
2739
- b.preventDefault();
2756
+ if (v.key === "Enter") {
2757
+ v.preventDefault();
2740
2758
  return;
2741
2759
  }
2742
- const m = window.getSelection();
2743
- if (m && m.rangeCount > 0) {
2744
- const $ = m.anchorNode;
2745
- let B = null;
2746
- if ($ && ($.nodeType === Node.ELEMENT_NODE ? B = $.closest('[data-type="text"]') : $.nodeType === Node.TEXT_NODE && $.parentElement && (B = $.parentElement.closest('[data-type="text"]'))), B) {
2747
- if (b.preventDefault(), b.stopPropagation(), n.current) {
2748
- const N = n.current.querySelector(
2760
+ const y = window.getSelection();
2761
+ if (y && y.rangeCount > 0) {
2762
+ const $ = y.anchorNode;
2763
+ let O = null;
2764
+ if ($ && ($.nodeType === Node.ELEMENT_NODE ? O = $.closest('[data-type="text"]') : $.nodeType === Node.TEXT_NODE && $.parentElement && (O = $.parentElement.closest('[data-type="text"]'))), O) {
2765
+ if (v.preventDefault(), v.stopPropagation(), n.current) {
2766
+ const _ = n.current.querySelector(
2749
2767
  '[data-type="variable"], [data-type="upload"]'
2750
2768
  );
2751
- N && N.focus();
2769
+ _ && _.focus();
2752
2770
  }
2753
2771
  return;
2754
2772
  }
2755
2773
  }
2756
- if (E && m && m.rangeCount > 0) {
2757
- const $ = m.anchorNode;
2758
- let B = null;
2759
- if ($ && ($.nodeType === Node.ELEMENT_NODE ? B = $.closest(".tag-node") : $.nodeType === Node.TEXT_NODE && $.parentElement && (B = $.parentElement.closest(".tag-node"))), B) {
2760
- if (b.preventDefault(), b.stopPropagation(), n.current) {
2761
- const N = n.current.querySelector(
2774
+ if (E && y && y.rangeCount > 0) {
2775
+ const $ = y.anchorNode;
2776
+ let O = null;
2777
+ if ($ && ($.nodeType === Node.ELEMENT_NODE ? O = $.closest(".tag-node") : $.nodeType === Node.TEXT_NODE && $.parentElement && (O = $.parentElement.closest(".tag-node"))), O) {
2778
+ if (v.preventDefault(), v.stopPropagation(), n.current) {
2779
+ const _ = n.current.querySelector(
2762
2780
  '[data-type="variable"], [data-type="upload"]'
2763
2781
  );
2764
- N && N.focus();
2782
+ _ && _.focus();
2765
2783
  }
2766
2784
  return;
2767
2785
  }
2768
2786
  }
2769
- if (b.key === "Escape" && n.current) {
2787
+ if (v.key === "Escape" && n.current) {
2770
2788
  if (E) {
2771
- b.preventDefault();
2789
+ v.preventDefault();
2772
2790
  return;
2773
2791
  }
2774
2792
  n.current.innerHTML = "", n.current.focus();
2775
2793
  }
2776
- if (b.key === "Backspace") {
2794
+ if (v.key === "Backspace") {
2777
2795
  const $ = window.getSelection();
2778
2796
  if ($ && $.rangeCount > 0) {
2779
- const B = $.getRangeAt(0), N = $.anchorNode;
2797
+ const O = $.getRangeAt(0), _ = $.anchorNode;
2780
2798
  if (E) {
2781
- let A = null, j = null;
2782
- if (N && (N.nodeType === Node.ELEMENT_NODE ? (A = N.closest(".tag-node"), j = N.closest('[data-type="text"]')) : N.nodeType === Node.TEXT_NODE && N.parentElement && (A = N.parentElement.closest(".tag-node"), j = N.parentElement.closest('[data-type="text"]'))), (A || j) && B.collapsed && B.startOffset === 0) {
2783
- b.preventDefault();
2799
+ let L = null, j = null;
2800
+ if (_ && (_.nodeType === Node.ELEMENT_NODE ? (L = _.closest(".tag-node"), j = _.closest('[data-type="text"]')) : _.nodeType === Node.TEXT_NODE && _.parentElement && (L = _.parentElement.closest(".tag-node"), j = _.parentElement.closest('[data-type="text"]'))), (L || j) && O.collapsed && O.startOffset === 0) {
2801
+ v.preventDefault();
2784
2802
  return;
2785
2803
  }
2786
2804
  }
2787
2805
  let I = null;
2788
- if (N && (N.nodeType === Node.ELEMENT_NODE ? I = N.closest(
2806
+ if (_ && (_.nodeType === Node.ELEMENT_NODE ? I = _.closest(
2789
2807
  '[data-type="variable"]'
2790
- ) : N.nodeType === Node.TEXT_NODE && N.parentElement && (I = N.parentElement.closest(
2808
+ ) : _.nodeType === Node.TEXT_NODE && _.parentElement && (I = _.parentElement.closest(
2791
2809
  '[data-type="variable"]'
2792
2810
  ))), I) {
2793
- if (!B.collapsed)
2811
+ if (!O.collapsed)
2794
2812
  return;
2795
- const A = I.innerText;
2796
- if (A === "​" || A === "") {
2797
- b.preventDefault();
2813
+ const L = I.innerText;
2814
+ if (L === "​" || L === "") {
2815
+ v.preventDefault();
2798
2816
  return;
2799
2817
  }
2800
- if (B.startOffset === 0) {
2801
- b.preventDefault();
2818
+ if (O.startOffset === 0) {
2819
+ v.preventDefault();
2802
2820
  return;
2803
2821
  }
2804
- if (A.startsWith("​") && B.startOffset === 1) {
2805
- b.preventDefault();
2822
+ if (L.startsWith("​") && O.startOffset === 1) {
2823
+ v.preventDefault();
2806
2824
  return;
2807
2825
  }
2808
2826
  }
2809
2827
  }
2810
2828
  }
2811
- }, st = () => {
2829
+ }, lt = () => {
2812
2830
  if (i || s || e || !F || !n.current) return;
2813
2831
  if (t.length === 0) {
2814
2832
  const I = n.current.textContent?.replace(/[\u200B\n]/g, "").trim() || "";
2815
2833
  if (!I) return;
2816
- u(I, I);
2834
+ d(I, I);
2817
2835
  return;
2818
2836
  }
2819
- const b = n.current;
2820
- let m = "";
2821
- const $ = {}, B = (I) => {
2837
+ const v = n.current;
2838
+ let y = "";
2839
+ const $ = {}, O = (I) => {
2822
2840
  if (!(I.nodeType === Node.ELEMENT_NODE && I.style.display === "none")) {
2823
2841
  if (I.nodeType === Node.TEXT_NODE)
2824
- m += (I.textContent || "").replace(/\u200B/g, "");
2842
+ y += (I.textContent || "").replace(/\u200B/g, "");
2825
2843
  else if (I.nodeType === Node.ELEMENT_NODE) {
2826
- const A = I, j = A.dataset.type, V = A.dataset.key;
2844
+ const L = I, j = L.dataset.type, V = L.dataset.key;
2827
2845
  if (j === "variable" && V) {
2828
2846
  let z = "";
2829
2847
  const W = document.createTreeWalker(
2830
- A,
2848
+ L,
2831
2849
  NodeFilter.SHOW_TEXT,
2832
2850
  {
2833
2851
  acceptNode: (Y) => {
2834
- const J = A.querySelector(".variable-info-icon");
2852
+ const J = L.querySelector(".variable-info-icon");
2835
2853
  return J && J.contains(Y) ? NodeFilter.FILTER_REJECT : NodeFilter.FILTER_ACCEPT;
2836
2854
  }
2837
2855
  }
2838
2856
  );
2839
2857
  for (; W.nextNode(); )
2840
2858
  z += W.currentNode.textContent || "";
2841
- const D = z.replace(/[\u200B\n]/g, "").trim();
2842
- if (D) {
2843
- const Y = A.dataset.multiKey;
2859
+ const M = z.replace(/[\u200B\n]/g, "").trim();
2860
+ if (M) {
2861
+ const Y = L.dataset.multiKey;
2844
2862
  if (Y) {
2845
2863
  (!$[Y] || !Array.isArray($[Y])) && ($[Y] = []);
2846
2864
  const J = $[Y];
2847
- J.push(D), J.length > 1 && (m += " "), m += D;
2865
+ J.push(M), J.length > 1 && (y += " "), y += M;
2848
2866
  } else
2849
- $[V] = D, m += D;
2867
+ $[V] = M, y += M;
2850
2868
  }
2851
2869
  } else if (j === "select" && V) {
2852
- const z = (A.getAttribute("data-value") || "").trim();
2853
- z && ($[V] = z, m += z);
2870
+ const z = (L.getAttribute("data-value") || "").trim();
2871
+ z && ($[V] = z, y += z);
2854
2872
  } else if (j === "textarea" && V) {
2855
- const W = (A.value || "").replace(/\u200B/g, "").trim();
2856
- W && ($[V] = W, m += W);
2873
+ const W = (L.value || "").replace(/\u200B/g, "").trim();
2874
+ W && ($[V] = W, y += W);
2857
2875
  } else if (j === "richtext" && V) {
2858
- const W = (A.textContent || "").replace(/\u200B/g, "").trim();
2859
- W && ($[V] = W, m += W);
2876
+ const W = (L.textContent || "").replace(/\u200B/g, "").trim();
2877
+ W && ($[V] = W, y += W);
2860
2878
  } else if (j === "datepicker" && V) {
2861
- const W = (A.getAttribute("data-value") || "").trim();
2879
+ const W = (L.getAttribute("data-value") || "").trim();
2862
2880
  if (W)
2863
2881
  if (W.includes(",")) {
2864
- const D = W.split(",");
2865
- D.length === 2 ? ($[V] = D, m += `[${D[0]}, ${D[1]}]`) : ($[V] = W, m += W);
2882
+ const M = W.split(",");
2883
+ M.length === 2 ? ($[V] = M, y += `[${M[0]}, ${M[1]}]`) : ($[V] = W, y += W);
2866
2884
  } else
2867
- $[V] = W, m += W;
2885
+ $[V] = W, y += W;
2868
2886
  } else if (j === "upload" && V) {
2869
- const z = A.dataset.batchKey;
2887
+ const z = L.dataset.batchKey;
2870
2888
  if (z) {
2871
- const W = t.find((D) => D.type === "upload" && D.key === z);
2889
+ const W = t.find((M) => M.type === "upload" && M.key === z);
2872
2890
  if (W && typeof W.maxCount == "number" && typeof W.minCount == "number") {
2873
- const D = [];
2891
+ const M = [];
2874
2892
  for (let Y = 0; Y < W.maxCount; Y++) {
2875
2893
  const J = `${z}-${Y}`, H = o[J];
2876
- H && D.push(H);
2894
+ H && M.push(H);
2877
2895
  }
2878
- $[z] || ($[z] = D.length > 0 ? D : null, D.length > 0 && (m += ` [附带${D.length}个文件: ${D.map((Y) => Y.name).join(", ")}] `));
2896
+ $[z] || ($[z] = M.length > 0 ? M : null, M.length > 0 && (y += ` [附带${M.length}个文件: ${M.map((Y) => Y.name).join(", ")}] `));
2879
2897
  } else
2880
- $[V] = o[V] ?? null, o[V] && (m += ` [附带文件: ${o[V]?.name}] `);
2898
+ $[V] = o[V] ?? null, o[V] && (y += ` [附带文件: ${o[V]?.name}] `);
2881
2899
  } else
2882
- $[V] = o[V] ?? null, o[V] && (m += ` [附带文件: ${o[V]?.name}] `);
2900
+ $[V] = o[V] ?? null, o[V] && (y += ` [附带文件: ${o[V]?.name}] `);
2883
2901
  } else {
2884
- if (A.classList.contains("tag-close-btn") || A.classList.contains("file-remove-btn")) return;
2885
- A.getAttribute("contenteditable") === "false" && !j && A.classList.contains("tag-node") ? m += A.innerText : A.childNodes.forEach(B);
2902
+ if (L.classList.contains("tag-close-btn") || L.classList.contains("file-remove-btn")) return;
2903
+ L.getAttribute("contenteditable") === "false" && !j && L.classList.contains("tag-node") ? y += L.innerText : L.childNodes.forEach(O);
2886
2904
  }
2887
2905
  }
2888
2906
  }
2889
2907
  };
2890
- if (b.childNodes.forEach(B), m = m.trim(), !m) return;
2891
- const N = new FormData();
2892
- N.append("fullPrompt", m), Object.keys($).forEach((I) => {
2893
- const A = $[I];
2894
- A != null && (A instanceof File ? N.append(I, A) : Array.isArray(A) ? t.some(
2908
+ if (v.childNodes.forEach(O), y = y.trim(), !y) return;
2909
+ const _ = new FormData();
2910
+ _.append("fullPrompt", y), Object.keys($).forEach((I) => {
2911
+ const L = $[I];
2912
+ L != null && (L instanceof File ? _.append(I, L) : Array.isArray(L) ? t.some(
2895
2913
  (V) => V.type === "multi-variable" && V.key === I
2896
- ) ? A.forEach((V) => {
2897
- V != null && V !== "" && N.append(I, String(V));
2898
- }) : A.forEach((V, z) => {
2899
- V != null && (V instanceof File ? N.append(`${I}[${z}]`, V) : typeof V == "string" ? N.append(`${I}[${z}]`, V) : N.append(`${I}[${z}]`, String(V)));
2900
- }) : typeof A == "string" ? N.append(I, A) : N.append(I, String(A)));
2901
- }), u(N, m);
2902
- }, lt = {
2903
- ...f ? { width: typeof f == "number" ? `${f}px` : f } : {},
2904
- ...y ? { border: y } : {},
2914
+ ) ? L.forEach((V) => {
2915
+ V != null && V !== "" && _.append(I, String(V));
2916
+ }) : L.forEach((V, z) => {
2917
+ V != null && (V instanceof File ? _.append(`${I}[${z}]`, V) : typeof V == "string" ? _.append(`${I}[${z}]`, V) : _.append(`${I}[${z}]`, String(V)));
2918
+ }) : typeof L == "string" ? _.append(I, L) : _.append(I, String(L)));
2919
+ }), d(_, y);
2920
+ }, it = {
2921
+ ...u ? { width: typeof u == "number" ? `${u}px` : u } : {},
2922
+ ...m ? { border: m } : {},
2905
2923
  ...c ? { background: c } : {}
2906
2924
  };
2907
- return /* @__PURE__ */ oe(
2925
+ return /* @__PURE__ */ re(
2908
2926
  "div",
2909
2927
  {
2910
2928
  className: "rich-text-editor",
2911
- style: lt,
2929
+ style: it,
2912
2930
  "data-disabled": s,
2913
2931
  children: [
2914
2932
  /* @__PURE__ */ S(
2915
2933
  "div",
2916
2934
  {
2917
2935
  ref: n,
2918
- className: `rte-editor ${t.length === 0 ? "rte-editor-default" : ""} ${de && C ? "rte-editor-empty" : ""}`,
2936
+ className: `rte-editor ${t.length === 0 ? "rte-editor-default" : ""} ${ie && C ? "rte-editor-empty" : ""}`,
2919
2937
  contentEditable: t.length === 0,
2920
2938
  suppressContentEditableWarning: !0,
2921
2939
  "data-placeholder": C,
2922
- onMouseDown: fe,
2923
- onMouseMove: ge,
2924
- onMouseUp: he,
2925
- onClick: ke,
2926
- onDoubleClick: Ee,
2927
- onInput: Ce,
2928
- onKeyDown: ot,
2929
- onPaste: me
2940
+ onMouseDown: ge,
2941
+ onMouseMove: he,
2942
+ onMouseUp: we,
2943
+ onClick: $e,
2944
+ onDoubleClick: Se,
2945
+ onInput: Ye,
2946
+ onKeyDown: st,
2947
+ onPaste: xe
2930
2948
  }
2931
2949
  ),
2932
2950
  /* @__PURE__ */ S(
@@ -2936,50 +2954,50 @@ const { RangePicker: ln } = mt, cn = ({ host: t, onChange: u }) => {
2936
2954
  ref: a,
2937
2955
  className: "rte-file-input",
2938
2956
  accept: ".csv,.xlsx,.xls,.txt,.pdf,image/*",
2939
- onChange: xe
2957
+ onChange: X
2940
2958
  }
2941
2959
  ),
2942
- /* @__PURE__ */ oe("div", { className: "rich-text-editor-footer", children: [
2943
- /* @__PURE__ */ S("div", { className: "rich-text-editor-footer-left", children: /* @__PURE__ */ oe("div", { className: "rich-text-editor-brand", children: [
2944
- /* @__PURE__ */ oe("div", { className: "rte-brand-badge", children: [
2960
+ /* @__PURE__ */ re("div", { className: "rich-text-editor-footer", children: [
2961
+ /* @__PURE__ */ S("div", { className: "rich-text-editor-footer-left", children: /* @__PURE__ */ re("div", { className: "rich-text-editor-brand", children: [
2962
+ /* @__PURE__ */ re("div", { className: "rte-brand-badge", children: [
2945
2963
  /* @__PURE__ */ S("img", { src: "https://oospublic.sealseek.cn/file/website/ball.png", alt: "" }),
2946
2964
  /* @__PURE__ */ S("span", { className: "rte-brand-text", children: "SealSeek 1.0" })
2947
2965
  ] }),
2948
2966
  r !== "hideAgent" && /* @__PURE__ */ S(
2949
- ht,
2967
+ gt,
2950
2968
  {
2951
2969
  placement: "top",
2952
2970
  menu: {
2953
- items: q.filter((b) => b.isShowNew !== 1).map((b) => ({
2954
- key: b.key,
2955
- label: /* @__PURE__ */ oe("div", { style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
2956
- b.icon && /* @__PURE__ */ S("i", { className: b.icon }),
2957
- /* @__PURE__ */ S("span", { children: b.label })
2971
+ items: T.filter((v) => v.isShowNew !== 1).map((v) => ({
2972
+ key: v.key,
2973
+ label: /* @__PURE__ */ re("div", { style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
2974
+ v.icon && /* @__PURE__ */ S("i", { className: v.icon }),
2975
+ /* @__PURE__ */ S("span", { children: v.label })
2958
2976
  ] }),
2959
2977
  onClick: () => {
2960
- w?.(b);
2978
+ b?.(v);
2961
2979
  }
2962
2980
  }))
2963
2981
  },
2964
2982
  trigger: ["click"],
2965
2983
  disabled: s || i,
2966
- children: /* @__PURE__ */ oe("div", { className: "rte-agent-badge", style: { cursor: q.length > 0 ? "pointer" : "default" }, children: [
2984
+ children: /* @__PURE__ */ re("div", { className: "rte-agent-badge", style: { cursor: T.length > 0 ? "pointer" : "default" }, children: [
2967
2985
  /* @__PURE__ */ S("i", { className: "iconfont icon-zhinengti", style: { fontSize: "16px" } }),
2968
2986
  /* @__PURE__ */ S("span", { className: "rte-agent-text", children: "智能体" })
2969
2987
  ] })
2970
2988
  }
2971
2989
  )
2972
2990
  ] }) }),
2973
- /* @__PURE__ */ oe("div", { style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
2991
+ /* @__PURE__ */ re("div", { style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
2974
2992
  (() => {
2975
- const b = t.find(($) => $.type === "tag");
2976
- if (!b || !b.text) return null;
2977
- const m = q.find(($) => $.label === b.text);
2978
- return !m || m.points === void 0 || m.points === null ? null : /* @__PURE__ */ oe("div", { className: "rte-points-badge", children: [
2993
+ const v = t.find(($) => $.type === "tag");
2994
+ if (!v || !v.text) return null;
2995
+ const y = T.find(($) => $.label === v.text);
2996
+ return !y || y.points === void 0 || y.points === null ? null : /* @__PURE__ */ re("div", { className: "rte-points-badge", children: [
2979
2997
  /* @__PURE__ */ S("i", { className: "iconfont icon-jifen", style: { marginRight: "4px" } }),
2980
- /* @__PURE__ */ oe("span", { style: { fontSize: "16px" }, children: [
2998
+ /* @__PURE__ */ re("span", { style: { fontSize: "16px" }, children: [
2981
2999
  "-",
2982
- String(m.points)
3000
+ String(y.points)
2983
3001
  ] })
2984
3002
  ] });
2985
3003
  })(),
@@ -2987,7 +3005,7 @@ const { RangePicker: ln } = mt, cn = ({ host: t, onChange: u }) => {
2987
3005
  "button",
2988
3006
  {
2989
3007
  type: "button",
2990
- onClick: st,
3008
+ onClick: lt,
2991
3009
  disabled: i || s || e || !F,
2992
3010
  className: "rich-text-editor-send-button",
2993
3011
  children: i || e ? /* @__PURE__ */ S("span", { className: "rte-send-spinner" }) : /* @__PURE__ */ S("i", { className: "iconfont icon-fasong" })
@@ -2998,42 +3016,42 @@ const { RangePicker: ln } = mt, cn = ({ host: t, onChange: u }) => {
2998
3016
  k?.anchorEl && (() => {
2999
3017
  if (!document.body.contains(k.anchorEl))
3000
3018
  return null;
3001
- let b = "", m = {
3019
+ let v = "", y = {
3002
3020
  background: "var(--neutral-800, #262626)"
3003
3021
  };
3004
3022
  if (k.type === "upload")
3005
- b = t.find(
3006
- (N) => N.type === "upload" && N.key === k.key
3023
+ v = t.find(
3024
+ (_) => _.type === "upload" && _.key === k.key
3007
3025
  )?.tooltip || "";
3008
3026
  else if (k.type === "tag")
3009
- b = k.anchorEl.dataset.tooltip || "";
3027
+ v = k.anchorEl.dataset.tooltip || "";
3010
3028
  else if (k.type === "upload-label")
3011
- b = k.anchorEl.dataset.fileName || "";
3029
+ v = k.anchorEl.dataset.fileName || "";
3012
3030
  else if (k.type === "variable")
3013
- b = k.anchorEl.dataset.tooltip || "";
3031
+ v = k.anchorEl.dataset.tooltip || "";
3014
3032
  else if (k.type === "upload-preview") {
3015
- const B = o[k.key];
3016
- if (B && B.type && B.type.startsWith("image/")) {
3017
- const N = URL.createObjectURL(B);
3018
- b = /* @__PURE__ */ S("div", { style: { width: 120, height: 120, display: "flex", alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ S("img", { src: N, style: { maxWidth: 120, maxHeight: 120, objectFit: "contain" } }) }), m = {
3033
+ const O = o[k.key];
3034
+ if (O && O.type && O.type.startsWith("image/")) {
3035
+ const _ = URL.createObjectURL(O);
3036
+ v = /* @__PURE__ */ S("div", { style: { width: 120, height: 120, display: "flex", alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ S("img", { src: _, style: { maxWidth: 120, maxHeight: 120, objectFit: "contain" } }) }), y = {
3019
3037
  background: "#fff",
3020
3038
  padding: 4
3021
- }, setTimeout(() => URL.revokeObjectURL(N), 1e3);
3039
+ }, setTimeout(() => URL.revokeObjectURL(_), 1e3);
3022
3040
  } else
3023
- b = "";
3041
+ v = "";
3024
3042
  }
3025
- if (!b) return null;
3043
+ if (!v) return null;
3026
3044
  const $ = k.type === "upload-preview" ? "#0A0A0A" : "#fff";
3027
3045
  return ze(
3028
3046
  /* @__PURE__ */ S(
3029
- gt,
3047
+ vt,
3030
3048
  {
3031
3049
  arrow: !1,
3032
- title: /* @__PURE__ */ S("div", { style: { maxWidth: "200px", fontSize: "12px", color: $ }, children: b }),
3050
+ title: /* @__PURE__ */ S("div", { style: { maxWidth: "200px", fontSize: "12px", color: $ }, children: v }),
3033
3051
  open: !0,
3034
3052
  placement: "top",
3035
3053
  getPopupContainer: () => document.body,
3036
- overlayInnerStyle: m,
3054
+ overlayInnerStyle: y,
3037
3055
  children: /* @__PURE__ */ S(
3038
3056
  "div",
3039
3057
  {
@@ -3053,12 +3071,12 @@ const { RangePicker: ln } = mt, cn = ({ host: t, onChange: u }) => {
3053
3071
  );
3054
3072
  })(),
3055
3073
  ye,
3056
- pe
3074
+ me
3057
3075
  ]
3058
3076
  }
3059
3077
  );
3060
3078
  };
3061
- dn.__docgenInfo = {
3079
+ pn.__docgenInfo = {
3062
3080
  displayName: "RichTextEditor",
3063
3081
  description: "结构化富文本输入组件,支持标签、变量输入块、文件上传以及互斥显示逻辑。",
3064
3082
  props: {
@@ -3086,23 +3104,23 @@ dn.__docgenInfo = {
3086
3104
  }
3087
3105
  }
3088
3106
  };
3089
- const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAFSSURBVHgB3ZTtccIwDIaVXv83I2SDZgSP0BHMBG0naEZhA2boBGQDswHdQJUOGRxjO0Z8HPDe6eJzJD2W4gjgEYSIn2xwK6EIFHqBGysJpMP3ZB0oRbEtmal1NtIxl4OWWsoxEsvqofJ0rgTNASOYq+7SXKDsuYvAcgkq/PWwBLQWqIfdjeRStaBUc4qzgLi9/BzJNmS/sh6bpvmrTfSFacU3scWy1mQryWdSnXiFE8QVUJINLTuyhWzzz/1OZmTN9hEckqtfUOwIGlGCpVRjE+94JFqpMtTeVzO8/UmPxpZU8Qa7aln8Tb9pfwla4WHWrjPvvbbnTBsX7PmLs83EDAH0BxSw1G31+/1FoDg/vPcXR+wocQS1apj4+P92FfhOoLyuBfYlmPgYnGoCjWADzAkzUyJ430awLmphPaxWQVU22BuuApPkHaanjcXSN3t6/QNjTMSJWDcs1QAAAABJRU5ErkJggg==", pn = [
3107
+ const et = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAFSSURBVHgB3ZTtccIwDIaVXv83I2SDZgSP0BHMBG0naEZhA2boBGQDswHdQJUOGRxjO0Z8HPDe6eJzJD2W4gjgEYSIn2xwK6EIFHqBGysJpMP3ZB0oRbEtmal1NtIxl4OWWsoxEsvqofJ0rgTNASOYq+7SXKDsuYvAcgkq/PWwBLQWqIfdjeRStaBUc4qzgLi9/BzJNmS/sh6bpvmrTfSFacU3scWy1mQryWdSnXiFE8QVUJINLTuyhWzzz/1OZmTN9hEckqtfUOwIGlGCpVRjE+94JFqpMtTeVzO8/UmPxpZU8Qa7aln8Tb9pfwla4WHWrjPvvbbnTBsX7PmLs83EDAH0BxSw1G31+/1FoDg/vPcXR+wocQS1apj4+P92FfhOoLyuBfYlmPgYnGoCjWADzAkzUyJ430awLmphPaxWQVU22BuuApPkHaanjcXSN3t6/QNjTMSJWDcs1QAAAABJRU5ErkJggg==", fn = [
3090
3108
  { label: "5页", value: 5 },
3091
3109
  { label: "10页", value: 10 },
3092
3110
  { label: "15页", value: 15 },
3093
3111
  { label: "30页", value: 30 }
3094
- ], fn = ({
3112
+ ], mn = ({
3095
3113
  autoLoading: t,
3096
- batchSize: u,
3114
+ batchSize: d,
3097
3115
  loadingProgress: i,
3098
3116
  loadIcon: s,
3099
- onBatchSizeChange: f,
3117
+ onBatchSizeChange: u,
3100
3118
  onLoadNextPage: E,
3101
- onStartAutoLoad: q,
3102
- onStopLoad: w
3103
- }) => t && i ? /* @__PURE__ */ oe("div", { className: "auto_load_progress", children: [
3104
- s || /* @__PURE__ */ S("img", { src: Ze, alt: "自动加载", width: 14, height: 14 }),
3105
- /* @__PURE__ */ oe("span", { children: [
3119
+ onStartAutoLoad: T,
3120
+ onStopLoad: b
3121
+ }) => t && i ? /* @__PURE__ */ re("div", { className: "auto_load_progress", children: [
3122
+ s || /* @__PURE__ */ S("img", { src: et, alt: "自动加载", width: 14, height: 14 }),
3123
+ /* @__PURE__ */ re("span", { children: [
3106
3124
  "正在加载第",
3107
3125
  i.currentPage,
3108
3126
  "/",
@@ -3110,15 +3128,15 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3110
3128
  "页"
3111
3129
  ] }),
3112
3130
  /* @__PURE__ */ S(
3113
- vt,
3131
+ bt,
3114
3132
  {
3115
3133
  percent: i.percentage,
3116
3134
  type: "line",
3117
3135
  size: [160, 8]
3118
3136
  }
3119
3137
  ),
3120
- /* @__PURE__ */ S("span", { onClick: w, className: "auto_load_stop_btn", children: "停止加载" })
3121
- ] }) : /* @__PURE__ */ oe("div", { className: "auto_load_container", children: [
3138
+ /* @__PURE__ */ S("span", { onClick: b, className: "auto_load_stop_btn", children: "停止加载" })
3139
+ ] }) : /* @__PURE__ */ re("div", { className: "auto_load_container", children: [
3122
3140
  /* @__PURE__ */ S(
3123
3141
  "div",
3124
3142
  {
@@ -3130,7 +3148,7 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3130
3148
  children: "加载下一页"
3131
3149
  }
3132
3150
  ),
3133
- /* @__PURE__ */ oe(
3151
+ /* @__PURE__ */ re(
3134
3152
  "div",
3135
3153
  {
3136
3154
  className: "right_control_wrap",
@@ -3138,13 +3156,13 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3138
3156
  backgroundColor: t ? "#f5f5f5" : "#2563eb"
3139
3157
  },
3140
3158
  children: [
3141
- /* @__PURE__ */ oe(
3159
+ /* @__PURE__ */ re(
3142
3160
  "div",
3143
3161
  {
3144
3162
  className: "auto_load_btn",
3145
- onClick: t ? void 0 : q,
3163
+ onClick: t ? void 0 : T,
3146
3164
  children: [
3147
- s || /* @__PURE__ */ S("img", { src: Ze, alt: "自动加载", width: 14, height: 14 }),
3165
+ s || /* @__PURE__ */ S("img", { src: et, alt: "自动加载", width: 14, height: 14 }),
3148
3166
  /* @__PURE__ */ S("span", { children: "自动加载" })
3149
3167
  ]
3150
3168
  }
@@ -3152,9 +3170,9 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3152
3170
  /* @__PURE__ */ S(
3153
3171
  Pe,
3154
3172
  {
3155
- value: u,
3156
- onChange: f,
3157
- options: pn,
3173
+ value: d,
3174
+ onChange: u,
3175
+ options: fn,
3158
3176
  disabled: t,
3159
3177
  size: "small",
3160
3178
  className: "auto_load_select",
@@ -3166,27 +3184,27 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3166
3184
  )
3167
3185
  ] }), yn = ({
3168
3186
  current: t,
3169
- loadIcon: u,
3187
+ loadIcon: d,
3170
3188
  pageSize: i,
3171
3189
  total: s,
3172
- cachedPages: f,
3190
+ cachedPages: u,
3173
3191
  loadedCount: E,
3174
- autoLoading: q = !1,
3175
- loadingProgress: w,
3192
+ autoLoading: T = !1,
3193
+ loadingProgress: b,
3176
3194
  onChange: g,
3177
3195
  onLoadNextPage: e,
3178
3196
  onStartAutoLoad: C,
3179
- onStopLoading: y
3197
+ onStopLoading: m
3180
3198
  }) => {
3181
- const [c, r] = Z(5), n = Math.ceil(s / i), a = et(() => f.length >= n, [f, n]), o = () => Array.from(
3199
+ const [c, r] = ee(5), n = Math.ceil(s / i), a = tt(() => u.length >= n, [u, n]), o = () => Array.from(
3182
3200
  { length: n },
3183
- (x, T) => T + 1
3184
- ).filter((x) => !f.includes(x)).slice(0, c);
3185
- return /* @__PURE__ */ oe("div", { className: "pagination_footer", children: [
3186
- /* @__PURE__ */ oe("div", { className: "pagination_leftWrap", children: [
3187
- /* @__PURE__ */ oe("span", { className: "pagination_total", children: [
3201
+ (x, A) => A + 1
3202
+ ).filter((x) => !u.includes(x)).slice(0, c);
3203
+ return /* @__PURE__ */ re("div", { className: "pagination_footer", children: [
3204
+ /* @__PURE__ */ re("div", { className: "pagination_leftWrap", children: [
3205
+ /* @__PURE__ */ re("span", { className: "pagination_total", children: [
3188
3206
  /* @__PURE__ */ S(
3189
- Ct,
3207
+ St,
3190
3208
  {
3191
3209
  style: { color: "#2563EB", marginRight: "4px" }
3192
3210
  }
@@ -3198,12 +3216,12 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3198
3216
  "条数据"
3199
3217
  ] }),
3200
3218
  !a && /* @__PURE__ */ S(
3201
- fn,
3219
+ mn,
3202
3220
  {
3203
- loadIcon: u || void 0,
3204
- autoLoading: q,
3221
+ loadIcon: d || void 0,
3222
+ autoLoading: T,
3205
3223
  batchSize: c,
3206
- loadingProgress: w,
3224
+ loadingProgress: b,
3207
3225
  disabled: !e || !C,
3208
3226
  onBatchSizeChange: r,
3209
3227
  onLoadNextPage: () => e?.(),
@@ -3211,12 +3229,12 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3211
3229
  const l = o();
3212
3230
  C?.(l);
3213
3231
  },
3214
- onStopLoad: () => y?.()
3232
+ onStopLoad: () => m?.()
3215
3233
  }
3216
3234
  )
3217
3235
  ] }),
3218
3236
  /* @__PURE__ */ S(
3219
- bt,
3237
+ xt,
3220
3238
  {
3221
3239
  current: t,
3222
3240
  pageSize: i,
@@ -3225,9 +3243,9 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3225
3243
  showSizeChanger: !1,
3226
3244
  showQuickJumper: !1,
3227
3245
  showTotal: (l, x) => "",
3228
- itemRender: (l, x, T) => {
3229
- const P = f.includes(l);
3230
- return x === "prev" || x === "next" || x === "jump-prev" || x === "jump-next" ? /* @__PURE__ */ S("div", { className: "pageBox", children: T }) : /* @__PURE__ */ oe(
3246
+ itemRender: (l, x, A) => {
3247
+ const P = u.includes(l);
3248
+ return x === "prev" || x === "next" || x === "jump-prev" || x === "jump-next" ? /* @__PURE__ */ S("div", { className: "pageBox", children: A }) : /* @__PURE__ */ re(
3231
3249
  "div",
3232
3250
  {
3233
3251
  className: "pageBox",
@@ -3245,37 +3263,37 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3245
3263
  }
3246
3264
  )
3247
3265
  ] });
3248
- }, mn = (t) => {
3266
+ }, hn = (t) => {
3249
3267
  const {
3250
- loading: u,
3268
+ loading: d,
3251
3269
  autoLoading: i,
3252
3270
  loadingProgress: s,
3253
- columns: f = [],
3271
+ columns: u = [],
3254
3272
  dataSource: E = [],
3255
- total: q,
3256
- current: w,
3273
+ total: T,
3274
+ current: b,
3257
3275
  pageSize: g,
3258
3276
  cachedPages: e,
3259
3277
  onChangePage: C,
3260
- onLoadNextPage: y,
3278
+ onLoadNextPage: m,
3261
3279
  onStartAutoLoad: c,
3262
3280
  onStopLoading: r,
3263
3281
  ...n
3264
- } = t, a = ne(null), o = se(
3282
+ } = t, a = ne(null), o = le(
3265
3283
  (p) => {
3266
3284
  C(p), e.includes(p) && a.current?.scrollTo({
3267
3285
  key: `${(p - 1) * g + 1}`
3268
3286
  });
3269
3287
  },
3270
- [w]
3288
+ [b]
3271
3289
  );
3272
- return /* @__PURE__ */ oe("div", { className: "flex flex-col", children: [
3290
+ return /* @__PURE__ */ re("div", { className: "flex flex-col", children: [
3273
3291
  /* @__PURE__ */ S(
3274
3292
  Fe,
3275
3293
  {
3276
3294
  ref: a,
3277
3295
  ...n,
3278
- columns: f,
3296
+ columns: u,
3279
3297
  dataSource: E,
3280
3298
  pagination: !1,
3281
3299
  virtual: !0
@@ -3284,23 +3302,23 @@ const Ze = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAA
3284
3302
  /* @__PURE__ */ S(
3285
3303
  yn,
3286
3304
  {
3287
- loading: u,
3305
+ loading: d,
3288
3306
  autoLoading: i,
3289
3307
  loadingProgress: s,
3290
- current: w,
3308
+ current: b,
3291
3309
  pageSize: g,
3292
- total: q,
3310
+ total: T,
3293
3311
  loadedCount: E.length,
3294
3312
  cachedPages: e,
3295
3313
  onChange: o,
3296
- onLoadNextPage: y,
3314
+ onLoadNextPage: m,
3297
3315
  onStartAutoLoad: c,
3298
3316
  onStopLoading: r
3299
3317
  }
3300
3318
  )
3301
3319
  ] });
3302
3320
  };
3303
- mn.__docgenInfo = {
3321
+ hn.__docgenInfo = {
3304
3322
  displayName: "VirtualTable",
3305
3323
  description: "虚拟滚动表格组件,支持分页、数据缓存和自动加载功能。",
3306
3324
  props: {
@@ -3407,77 +3425,77 @@ mn.__docgenInfo = {
3407
3425
  }
3408
3426
  }
3409
3427
  };
3410
- const hn = ({
3428
+ const gn = ({
3411
3429
  texts: t = [],
3412
- placeholder: u = "请输入内容",
3430
+ placeholder: d = "请输入内容",
3413
3431
  animationSpeed: i = 100,
3414
3432
  autoPlay: s = !0,
3415
- value: f,
3433
+ value: u,
3416
3434
  onChange: E,
3417
- ...q
3435
+ ...T
3418
3436
  }) => {
3419
- const [w, g] = Z(""), [e, C] = Z(0), [y, c] = Z(!1), [r, n] = Z(!1), [a, o] = Z(!1), p = ne(void 0), l = ne(void 0), x = ne(t), T = ne(e), P = ne(r), k = ne(w);
3420
- ue(() => {
3421
- x.current = t, T.current = e, P.current = r, k.current = w;
3437
+ const [b, g] = ee(""), [e, C] = ee(0), [m, c] = ee(!1), [r, n] = ee(!1), [a, o] = ee(!1), p = ne(void 0), l = ne(void 0), x = ne(t), A = ne(e), P = ne(r), k = ne(b);
3438
+ pe(() => {
3439
+ x.current = t, A.current = e, P.current = r, k.current = b;
3422
3440
  });
3423
- const G = se((h, d) => {
3424
- let v = 0;
3441
+ const G = le((h, f) => {
3442
+ let w = 0;
3425
3443
  o(!0);
3426
- const _ = () => {
3427
- v < h.length ? (g(h.slice(0, v + 1)), v++, l.current = window.setTimeout(_, i)) : (o(!1), d?.());
3444
+ const q = () => {
3445
+ w < h.length ? (g(h.slice(0, w + 1)), w++, l.current = window.setTimeout(q, i)) : (o(!1), f?.());
3428
3446
  };
3429
- _();
3430
- }, [i]), R = se((h) => {
3431
- let d = k.current.length;
3432
- const v = () => {
3433
- d > 0 ? (g(k.current.slice(0, d - 1)), d--, l.current = window.setTimeout(v, i / 2)) : h?.();
3447
+ q();
3448
+ }, [i]), R = le((h) => {
3449
+ let f = k.current.length;
3450
+ const w = () => {
3451
+ f > 0 ? (g(k.current.slice(0, f - 1)), f--, l.current = window.setTimeout(w, i / 2)) : h?.();
3434
3452
  };
3435
- v();
3436
- }, [i]), M = se(() => {
3453
+ w();
3454
+ }, [i]), D = le(() => {
3437
3455
  if (x.current.length === 0 || P.current) return;
3438
3456
  c(!0);
3439
- const h = x.current[T.current];
3457
+ const h = x.current[A.current];
3440
3458
  k.current ? R(() => {
3441
3459
  G(h, () => {
3442
3460
  p.current = window.setTimeout(() => {
3443
- C((d) => (d + 1) % x.current.length), c(!1);
3461
+ C((f) => (f + 1) % x.current.length), c(!1);
3444
3462
  }, 2e3);
3445
3463
  });
3446
3464
  }) : G(h, () => {
3447
3465
  p.current = window.setTimeout(() => {
3448
- C((d) => (d + 1) % x.current.length), c(!1);
3466
+ C((f) => (f + 1) % x.current.length), c(!1);
3449
3467
  }, 2e3);
3450
3468
  });
3451
3469
  }, [R, G]);
3452
- return ue(() => (s && t.length > 0 && !r && M(), () => {
3470
+ return pe(() => (s && t.length > 0 && !r && D(), () => {
3453
3471
  p.current && window.clearTimeout(p.current), l.current && window.clearTimeout(l.current);
3454
- }), [e, r, s, t.length, M]), ue(() => {
3455
- !y && s && t.length > 0 && !r && M();
3456
- }, [e, y, s, t.length, r, M]), /* @__PURE__ */ oe("div", { style: { position: "relative" }, children: [
3472
+ }), [e, r, s, t.length, D]), pe(() => {
3473
+ !m && s && t.length > 0 && !r && D();
3474
+ }, [e, m, s, t.length, r, D]), /* @__PURE__ */ re("div", { style: { position: "relative" }, children: [
3457
3475
  /* @__PURE__ */ S(
3458
- tt,
3476
+ nt,
3459
3477
  {
3460
- ...q,
3461
- value: f,
3478
+ ...T,
3479
+ value: u,
3462
3480
  onChange: (h) => {
3463
- E?.(h.target.value), q.onChange?.(h);
3481
+ E?.(h.target.value), T.onChange?.(h);
3464
3482
  },
3465
3483
  onFocus: (h) => {
3466
- n(!0), p.current && window.clearTimeout(p.current), l.current && window.clearTimeout(l.current), c(!1), o(!1), q.onFocus?.(h);
3484
+ n(!0), p.current && window.clearTimeout(p.current), l.current && window.clearTimeout(l.current), c(!1), o(!1), T.onFocus?.(h);
3467
3485
  },
3468
3486
  onBlur: (h) => {
3469
- n(!1), !f && t.length > 0 && (g(""), C(0)), q.onBlur?.(h);
3487
+ n(!1), !u && t.length > 0 && (g(""), C(0)), T.onBlur?.(h);
3470
3488
  },
3471
- placeholder: r || f ? u : w || u,
3489
+ placeholder: r || u ? d : b || d,
3472
3490
  style: {
3473
3491
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
3474
- ...q.style,
3492
+ ...T.style,
3475
3493
  position: "relative",
3476
3494
  zIndex: 1
3477
3495
  }
3478
3496
  }
3479
3497
  ),
3480
- !r && !f && w && /* @__PURE__ */ oe(
3498
+ !r && !u && b && /* @__PURE__ */ re(
3481
3499
  "div",
3482
3500
  {
3483
3501
  style: {
@@ -3497,7 +3515,7 @@ const hn = ({
3497
3515
  fontFamily: "inherit"
3498
3516
  },
3499
3517
  children: [
3500
- /* @__PURE__ */ S("span", { children: w }),
3518
+ /* @__PURE__ */ S("span", { children: b }),
3501
3519
  a && /* @__PURE__ */ S(
3502
3520
  "span",
3503
3521
  {
@@ -3522,7 +3540,7 @@ const hn = ({
3522
3540
  ` })
3523
3541
  ] });
3524
3542
  };
3525
- hn.__docgenInfo = {
3543
+ gn.__docgenInfo = {
3526
3544
  displayName: "DynamicInput",
3527
3545
  description: "动态文案输入框组件,支持流式文字动画效果",
3528
3546
  props: {
@@ -3567,22 +3585,22 @@ hn.__docgenInfo = {
3567
3585
  }
3568
3586
  }
3569
3587
  };
3570
- const gn = ({
3588
+ const vn = ({
3571
3589
  texts: t = [],
3572
3590
  // 动态文案数组,默认为空数组
3573
- placeholder: u = "请输入内容",
3591
+ placeholder: d = "请输入内容",
3574
3592
  // 占位符文本
3575
3593
  animationSpeed: i = 100,
3576
3594
  // 打字机动画速度,毫秒
3577
3595
  autoPlay: s = !0,
3578
3596
  // 是否自动播放动画
3579
- value: f = "",
3597
+ value: u = "",
3580
3598
  // 受控模式的值
3581
3599
  onChange: E,
3582
3600
  // 受控模式的变化回调
3583
- onSubmit: q,
3601
+ onSubmit: T,
3584
3602
  // 提交回调
3585
- maxLength: w = 500,
3603
+ maxLength: b = 500,
3586
3604
  // 最大字符数限制
3587
3605
  showCount: g = !0,
3588
3606
  // 是否显示字数统计
@@ -3590,86 +3608,86 @@ const gn = ({
3590
3608
  // 提交按钮文本
3591
3609
  disabled: C = !1,
3592
3610
  // 是否禁用组件
3593
- rows: y = 4,
3611
+ rows: m = 4,
3594
3612
  // 文本域行数
3595
3613
  style: c,
3596
3614
  // 自定义样式
3597
3615
  ...r
3598
3616
  // 其他原生属性
3599
3617
  }) => {
3600
- const [n, a] = Z(""), [o, p] = Z(0), [l, x] = Z(!1), [T, P] = Z(!1), [k, G] = Z(!1), [R, M] = Z(f || ""), F = ne(void 0), O = ne(void 0), te = ne(t), de = ne(o), h = ne(T), d = ne(n), v = ne(null);
3601
- ue(() => {
3602
- te.current = t, de.current = o, h.current = T, d.current = n;
3618
+ const [n, a] = ee(""), [o, p] = ee(0), [l, x] = ee(!1), [A, P] = ee(!1), [k, G] = ee(!1), [R, D] = ee(u || ""), F = ne(void 0), B = ne(void 0), Z = ne(t), ie = ne(o), h = ne(A), f = ne(n), w = ne(null);
3619
+ pe(() => {
3620
+ Z.current = t, ie.current = o, h.current = A, f.current = n;
3603
3621
  });
3604
- const _ = se((X, fe) => {
3622
+ const q = le((X, fe) => {
3605
3623
  let ge = 0;
3606
3624
  G(!0);
3607
3625
  const he = () => {
3608
- ge < X.length ? (a(X.slice(0, ge + 1)), ge++, O.current = window.setTimeout(he, i)) : (G(!1), fe?.());
3626
+ ge < X.length ? (a(X.slice(0, ge + 1)), ge++, B.current = window.setTimeout(he, i)) : (G(!1), fe?.());
3609
3627
  };
3610
3628
  he();
3611
- }, [i]), L = se((X) => {
3612
- let fe = d.current.length;
3629
+ }, [i]), N = le((X) => {
3630
+ let fe = f.current.length;
3613
3631
  const ge = () => {
3614
- fe > 0 ? (a(d.current.slice(0, fe - 1)), fe--, O.current = window.setTimeout(ge, i / 2)) : X?.();
3632
+ fe > 0 ? (a(f.current.slice(0, fe - 1)), fe--, B.current = window.setTimeout(ge, i / 2)) : X?.();
3615
3633
  };
3616
3634
  ge();
3617
- }, [i]), K = se(() => {
3618
- if (te.current.length === 0 || h.current) return;
3635
+ }, [i]), K = le(() => {
3636
+ if (Z.current.length === 0 || h.current) return;
3619
3637
  x(!0);
3620
- const X = te.current[de.current];
3621
- d.current ? L(() => {
3622
- _(X, () => {
3638
+ const X = Z.current[ie.current];
3639
+ f.current ? N(() => {
3640
+ q(X, () => {
3623
3641
  F.current = window.setTimeout(() => {
3624
- p((fe) => (fe + 1) % te.current.length), x(!1);
3642
+ p((fe) => (fe + 1) % Z.current.length), x(!1);
3625
3643
  }, 2e3);
3626
3644
  });
3627
- }) : _(X, () => {
3645
+ }) : q(X, () => {
3628
3646
  F.current = window.setTimeout(() => {
3629
- p((fe) => (fe + 1) % te.current.length), x(!1);
3647
+ p((fe) => (fe + 1) % Z.current.length), x(!1);
3630
3648
  }, 2e3);
3631
3649
  });
3632
- }, [L, _]);
3633
- ue(() => (s && t.length > 0 && !T && K(), () => {
3634
- F.current && window.clearTimeout(F.current), O.current && window.clearTimeout(O.current);
3635
- }), [o, T, s, t.length, K]), ue(() => {
3636
- !l && s && t.length > 0 && !T && K();
3637
- }, [o, l, s, t.length, T, K]);
3650
+ }, [N, q]);
3651
+ pe(() => (s && t.length > 0 && !A && K(), () => {
3652
+ F.current && window.clearTimeout(F.current), B.current && window.clearTimeout(B.current);
3653
+ }), [o, A, s, t.length, K]), pe(() => {
3654
+ !l && s && t.length > 0 && !A && K();
3655
+ }, [o, l, s, t.length, A, K]);
3638
3656
  const U = (X) => {
3639
- P(!0), F.current && window.clearTimeout(F.current), O.current && window.clearTimeout(O.current), x(!1), G(!1), r.onFocus?.(X);
3657
+ P(!0), F.current && window.clearTimeout(F.current), B.current && window.clearTimeout(B.current), x(!1), G(!1), r.onFocus?.(X);
3640
3658
  }, ae = (X) => {
3641
- P(!1), !f && t.length > 0 && (a(""), p(0)), r.onBlur?.(X);
3642
- }, re = (X) => {
3659
+ P(!1), !u && t.length > 0 && (a(""), p(0)), r.onBlur?.(X);
3660
+ }, ce = (X) => {
3643
3661
  const fe = X.target.value;
3644
- w && fe.length > w || (E ? E(fe) : M(fe), r.onChange?.(X));
3645
- }, pe = () => {
3646
- const X = E ? f : R;
3647
- X.trim() && !C && (q?.(X), E || M(""));
3648
- }, ye = (X) => {
3649
- (X.ctrlKey || X.metaKey) && X.key === "Enter" && (X.preventDefault(), pe()), r.onKeyDown?.(X);
3650
- }, me = E ? f : R, xe = C || !me.trim() || (w ? me.length > w : !1);
3651
- return /* @__PURE__ */ oe("div", { style: { position: "relative", ...c }, children: [
3652
- /* @__PURE__ */ oe("div", { style: { position: "relative" }, children: [
3662
+ b && fe.length > b || (E ? E(fe) : D(fe), r.onChange?.(X));
3663
+ }, oe = () => {
3664
+ const X = E ? u : R;
3665
+ X.trim() && !C && (T?.(X), E || D(""));
3666
+ }, me = (X) => {
3667
+ (X.ctrlKey || X.metaKey) && X.key === "Enter" && (X.preventDefault(), oe()), r.onKeyDown?.(X);
3668
+ }, ye = E ? u : R, xe = C || !ye.trim() || (b ? ye.length > b : !1);
3669
+ return /* @__PURE__ */ re("div", { style: { position: "relative", ...c }, children: [
3670
+ /* @__PURE__ */ re("div", { style: { position: "relative" }, children: [
3653
3671
  /* @__PURE__ */ S(
3654
3672
  "textarea",
3655
3673
  {
3656
- ref: v,
3657
- value: E ? f : R,
3658
- onChange: re,
3674
+ ref: w,
3675
+ value: E ? u : R,
3676
+ onChange: ce,
3659
3677
  onFocus: (X) => {
3660
3678
  X.target.style.borderColor = "#1890ff", X.target.style.boxShadow = "0 0 0 2px rgba(24, 144, 255, 0.2)", U(X);
3661
3679
  },
3662
3680
  onBlur: (X) => {
3663
3681
  X.target.style.borderColor = "#d9d9d9", X.target.style.boxShadow = "none", ae(X);
3664
3682
  },
3665
- onKeyDown: ye,
3666
- placeholder: T || me ? u : "",
3667
- maxLength: w,
3668
- rows: y,
3683
+ onKeyDown: me,
3684
+ placeholder: A || ye ? d : "",
3685
+ maxLength: b,
3686
+ rows: m,
3669
3687
  disabled: C,
3670
3688
  style: {
3671
3689
  width: "100%",
3672
- minHeight: `${y * 24 + 16}px`,
3690
+ minHeight: `${m * 24 + 16}px`,
3673
3691
  padding: "8px 60px 8px 12px",
3674
3692
  // 右侧留出按钮空间
3675
3693
  border: "1px solid #d9d9d9",
@@ -3687,7 +3705,7 @@ const gn = ({
3687
3705
  ...r
3688
3706
  }
3689
3707
  ),
3690
- !T && !me && n && /* @__PURE__ */ oe(
3708
+ !A && !ye && n && /* @__PURE__ */ re(
3691
3709
  "div",
3692
3710
  {
3693
3711
  style: {
@@ -3736,12 +3754,12 @@ const gn = ({
3736
3754
  zIndex: 3
3737
3755
  },
3738
3756
  children: /* @__PURE__ */ S(
3739
- Se,
3757
+ Ce,
3740
3758
  {
3741
3759
  type: "primary",
3742
3760
  size: "small",
3743
- icon: /* @__PURE__ */ S(St, {}),
3744
- onClick: pe,
3761
+ icon: /* @__PURE__ */ S(Tt, {}),
3762
+ onClick: oe,
3745
3763
  disabled: xe,
3746
3764
  style: {
3747
3765
  borderRadius: 6,
@@ -3757,7 +3775,7 @@ const gn = ({
3757
3775
  }
3758
3776
  )
3759
3777
  ] }),
3760
- g && /* @__PURE__ */ oe(
3778
+ g && /* @__PURE__ */ re(
3761
3779
  "div",
3762
3780
  {
3763
3781
  style: {
@@ -3767,9 +3785,9 @@ const gn = ({
3767
3785
  color: "#999"
3768
3786
  },
3769
3787
  children: [
3770
- me.length,
3788
+ ye.length,
3771
3789
  "/",
3772
- w
3790
+ b
3773
3791
  ]
3774
3792
  }
3775
3793
  ),
@@ -3781,7 +3799,7 @@ const gn = ({
3781
3799
  ` })
3782
3800
  ] });
3783
3801
  };
3784
- gn.__docgenInfo = {
3802
+ vn.__docgenInfo = {
3785
3803
  displayName: "DynamicTextArea",
3786
3804
  description: "动态文案文本域组件,支持流式文字动画效果",
3787
3805
  props: {
@@ -3867,46 +3885,46 @@ gn.__docgenInfo = {
3867
3885
  }
3868
3886
  }
3869
3887
  };
3870
- const rt = ({
3888
+ const ot = ({
3871
3889
  src: t,
3872
- poster: u,
3890
+ poster: d,
3873
3891
  width: i = 300,
3874
3892
  height: s,
3875
- videoWidth: f,
3893
+ videoWidth: u,
3876
3894
  // 参数保留但不使用,由CSS控制
3877
3895
  videoHeight: E,
3878
3896
  // 参数保留但不使用,由CSS控制
3879
- showPlayButton: q = !0,
3880
- autoPlayOnHover: w = !0,
3897
+ showPlayButton: T = !0,
3898
+ autoPlayOnHover: b = !0,
3881
3899
  onClick: g,
3882
3900
  onVideoLoaded: e,
3883
3901
  onVideoPlay: C,
3884
- onVideoPause: y,
3902
+ onVideoPause: m,
3885
3903
  onVideoEnded: c,
3886
3904
  className: r,
3887
3905
  style: n,
3888
3906
  ...a
3889
3907
  }) => {
3890
- const o = ne(null), [p, l] = Z(!1), [x, T] = Z(!1), [P, k] = Z(!1), G = se(() => {
3908
+ const o = ne(null), [p, l] = ee(!1), [x, A] = ee(!1), [P, k] = ee(!1), G = le(() => {
3891
3909
  o.current && (o.current.play(), l(!0), C?.());
3892
- }, [C]), R = se(() => {
3893
- o.current && (o.current.pause(), l(!1), y?.());
3894
- }, [y]), M = se((_) => {
3895
- _.stopPropagation(), p ? R() : G();
3896
- }, [p, G, R]), F = se(() => {
3897
- T(!0), w && !p && G();
3898
- }, [w, p, G]), O = se(() => {
3899
- T(!1), w && p && R();
3900
- }, [w, p, R]), te = se(() => {
3910
+ }, [C]), R = le(() => {
3911
+ o.current && (o.current.pause(), l(!1), m?.());
3912
+ }, [m]), D = le((q) => {
3913
+ q.stopPropagation(), p ? R() : G();
3914
+ }, [p, G, R]), F = le(() => {
3915
+ A(!0), b && !p && G();
3916
+ }, [b, p, G]), B = le(() => {
3917
+ A(!1), b && p && R();
3918
+ }, [b, p, R]), Z = le(() => {
3901
3919
  k(!0), e?.();
3902
- }, [e]), de = se(() => {
3920
+ }, [e]), ie = le(() => {
3903
3921
  l(!0), C?.();
3904
- }, [C]), h = se(() => {
3905
- l(!1), y?.();
3906
- }, [y]), d = se(() => {
3922
+ }, [C]), h = le(() => {
3923
+ l(!1), m?.();
3924
+ }, [m]), f = le(() => {
3907
3925
  l(!1), c?.();
3908
- }, [c]), v = se((_) => {
3909
- g?.(_);
3926
+ }, [c]), w = le((q) => {
3927
+ g?.(q);
3910
3928
  }, [g]);
3911
3929
  return /* @__PURE__ */ S(
3912
3930
  Re,
@@ -3925,30 +3943,30 @@ const rt = ({
3925
3943
  },
3926
3944
  bordered: !1,
3927
3945
  onMouseEnter: F,
3928
- onMouseLeave: O,
3929
- onClick: v,
3930
- children: /* @__PURE__ */ oe("div", { className: "video-card-container", children: [
3946
+ onMouseLeave: B,
3947
+ onClick: w,
3948
+ children: /* @__PURE__ */ re("div", { className: "video-card-container", children: [
3931
3949
  /* @__PURE__ */ S(
3932
3950
  "video",
3933
3951
  {
3934
3952
  ref: o,
3935
3953
  src: t,
3936
- poster: u,
3954
+ poster: d,
3937
3955
  preload: "metadata",
3938
- onLoadedData: te,
3939
- onPlay: de,
3956
+ onLoadedData: Z,
3957
+ onPlay: ie,
3940
3958
  onPause: h,
3941
- onEnded: d,
3959
+ onEnded: f,
3942
3960
  muted: !0,
3943
3961
  loop: !0
3944
3962
  }
3945
3963
  ),
3946
- q && /* @__PURE__ */ S(
3964
+ T && /* @__PURE__ */ S(
3947
3965
  "div",
3948
3966
  {
3949
3967
  className: `video-play-button ${x ? "hovered" : ""}`,
3950
- onClick: M,
3951
- children: p ? /* @__PURE__ */ S(qt, { className: "play-icon" }) : /* @__PURE__ */ S(Tt, { className: "play-icon" })
3968
+ onClick: D,
3969
+ children: p ? /* @__PURE__ */ S(qt, { className: "play-icon" }) : /* @__PURE__ */ S(Nt, { className: "play-icon" })
3952
3970
  }
3953
3971
  ),
3954
3972
  !P && /* @__PURE__ */ S("div", { className: "video-loading-mask", children: /* @__PURE__ */ S("div", { className: "loading-spinner" }) })
@@ -3956,7 +3974,7 @@ const rt = ({
3956
3974
  }
3957
3975
  );
3958
3976
  };
3959
- rt.__docgenInfo = {
3977
+ ot.__docgenInfo = {
3960
3978
  displayName: "VideoCard",
3961
3979
  description: "视频卡片组件,支持鼠标悬浮播放控制",
3962
3980
  props: {
@@ -4057,12 +4075,12 @@ rt.__docgenInfo = {
4057
4075
  }
4058
4076
  }
4059
4077
  };
4060
- const vn = (t) => [".mp4", ".webm", ".ogg", ".mov", ".avi", ".wmv", ".flv", ".mkv"].some((i) => t.toLowerCase().includes(i)), bn = (t) => t.type ? t.type : vn(t.url) ? "video" : "image", xn = ({
4078
+ const bn = (t) => [".mp4", ".webm", ".ogg", ".mov", ".avi", ".wmv", ".flv", ".mkv"].some((i) => t.toLowerCase().includes(i)), xn = (t) => t.type ? t.type : bn(t.url) ? "video" : "image", wn = ({
4061
4079
  items: t,
4062
- columns: u,
4080
+ columns: d,
4063
4081
  gap: i = 0,
4064
4082
  responsive: s = !0,
4065
- breakpoints: f = {
4083
+ breakpoints: u = {
4066
4084
  xs: 1,
4067
4085
  sm: 2,
4068
4086
  md: 3,
@@ -4071,44 +4089,44 @@ const vn = (t) => [".mp4", ".webm", ".ogg", ".mov", ".avi", ".wmv", ".flv", ".mk
4071
4089
  xxl: 6
4072
4090
  },
4073
4091
  className: E,
4074
- style: q,
4075
- onClick: w
4092
+ style: T,
4093
+ onClick: b
4076
4094
  }) => {
4077
- const g = ne(null), [e, C] = Z(u || f.md || 3), y = ne(/* @__PURE__ */ new Map()), c = se(() => {
4078
- if (!s || u)
4079
- return u || f.md || 3;
4095
+ const g = ne(null), [e, C] = ee(d || u.md || 3), m = ne(/* @__PURE__ */ new Map()), c = le(() => {
4096
+ if (!s || d)
4097
+ return d || u.md || 3;
4080
4098
  const o = window.innerWidth;
4081
- return o < 576 ? f.xs || 1 : o < 768 ? f.sm || 2 : o < 992 ? f.md || 3 : o < 1200 ? f.lg || 4 : o < 1600 ? f.xl || 5 : f.xxl || 6;
4082
- }, [s, u, f]), r = se(() => {
4099
+ return o < 576 ? u.xs || 1 : o < 768 ? u.sm || 2 : o < 992 ? u.md || 3 : o < 1200 ? u.lg || 4 : o < 1600 ? u.xl || 5 : u.xxl || 6;
4100
+ }, [s, d, u]), r = le(() => {
4083
4101
  if (!g.current) return;
4084
- const o = e, p = g.current, x = (p.offsetWidth - i * (o - 1)) / o, T = new Array(o).fill(0);
4102
+ const o = e, p = g.current, x = (p.offsetWidth - i * (o - 1)) / o, A = new Array(o).fill(0);
4085
4103
  t.forEach((k, G) => {
4086
- const R = k.id || G, M = y.current.get(R);
4087
- if (!M) return;
4088
- const F = Math.min(...T), O = T.indexOf(F), te = O * (x + i), de = T[O];
4089
- M.style.position = "absolute", M.style.left = `${te}px`, M.style.top = `${de}px`, M.style.width = `${x}px`, T[O] += M.offsetHeight + i;
4104
+ const R = k.id || G, D = m.current.get(R);
4105
+ if (!D) return;
4106
+ const F = Math.min(...A), B = A.indexOf(F), Z = B * (x + i), ie = A[B];
4107
+ D.style.position = "absolute", D.style.left = `${Z}px`, D.style.top = `${ie}px`, D.style.width = `${x}px`, A[B] += D.offsetHeight + i;
4090
4108
  });
4091
- const P = Math.max(...T);
4109
+ const P = Math.max(...A);
4092
4110
  p.style.height = `${P}px`;
4093
4111
  }, [t, e, i]);
4094
- ue(() => {
4112
+ pe(() => {
4095
4113
  const o = () => {
4096
4114
  const p = c();
4097
4115
  p !== e && C(p);
4098
4116
  };
4099
4117
  if (s)
4100
4118
  return window.addEventListener("resize", o), o(), () => window.removeEventListener("resize", o);
4101
- }, [s, c, e]), ue(() => {
4119
+ }, [s, c, e]), pe(() => {
4102
4120
  const o = setTimeout(() => {
4103
4121
  r();
4104
4122
  }, 100);
4105
4123
  return () => clearTimeout(o);
4106
4124
  }, [t, e, r]);
4107
- const n = se(() => {
4125
+ const n = le(() => {
4108
4126
  r();
4109
- }, [r]), a = se((o) => {
4110
- w && w(o), o.onClick?.(o);
4111
- }, [w]);
4127
+ }, [r]), a = le((o) => {
4128
+ b && b(o), o.onClick?.(o);
4129
+ }, [b]);
4112
4130
  return /* @__PURE__ */ S(
4113
4131
  "div",
4114
4132
  {
@@ -4117,24 +4135,24 @@ const vn = (t) => [".mp4", ".webm", ".ogg", ".mov", ".avi", ".wmv", ".flv", ".mk
4117
4135
  style: {
4118
4136
  position: "relative",
4119
4137
  width: "100%",
4120
- ...q
4138
+ ...T
4121
4139
  },
4122
4140
  children: t.map((o, p) => {
4123
- const l = o.id || p, x = bn(o);
4141
+ const l = o.id || p, x = xn(o);
4124
4142
  return /* @__PURE__ */ S(
4125
4143
  "div",
4126
4144
  {
4127
- ref: (T) => {
4128
- T ? y.current.set(l, T) : y.current.delete(l);
4145
+ ref: (A) => {
4146
+ A ? m.current.set(l, A) : m.current.delete(l);
4129
4147
  },
4130
4148
  className: "waterfall-item",
4131
4149
  children: x === "video" ? /* @__PURE__ */ S("div", { style: {
4132
4150
  width: "100%",
4133
4151
  position: "relative",
4134
4152
  paddingBottom: "56.25%",
4135
- cursor: w || o.onClick ? "pointer" : "default"
4153
+ cursor: b || o.onClick ? "pointer" : "default"
4136
4154
  }, children: /* @__PURE__ */ S("div", { style: { position: "absolute", top: 0, left: 0, width: "100%", height: "100%" }, children: /* @__PURE__ */ S(
4137
- rt,
4155
+ ot,
4138
4156
  {
4139
4157
  src: o.url,
4140
4158
  poster: o.poster,
@@ -4150,7 +4168,7 @@ const vn = (t) => [".mp4", ".webm", ".ogg", ".mov", ".avi", ".wmv", ".flv", ".mk
4150
4168
  {
4151
4169
  className: "waterfall-image-wrapper",
4152
4170
  onClick: () => a(o),
4153
- style: { cursor: w || o.onClick ? "pointer" : "default" },
4171
+ style: { cursor: b || o.onClick ? "pointer" : "default" },
4154
4172
  children: /* @__PURE__ */ S(
4155
4173
  "img",
4156
4174
  {
@@ -4171,7 +4189,7 @@ const vn = (t) => [".mp4", ".webm", ".ogg", ".mov", ".avi", ".wmv", ".flv", ".mk
4171
4189
  }
4172
4190
  );
4173
4191
  };
4174
- xn.__docgenInfo = {
4192
+ wn.__docgenInfo = {
4175
4193
  displayName: "Waterfall",
4176
4194
  description: "瀑布流布局组件,支持图片和视频混合展示",
4177
4195
  props: {
@@ -4228,7 +4246,7 @@ xn.__docgenInfo = {
4228
4246
  }
4229
4247
  };
4230
4248
  const qn = {
4231
- algorithm: xt.defaultAlgorithm,
4249
+ algorithm: wt.defaultAlgorithm,
4232
4250
  token: {
4233
4251
  // 主色
4234
4252
  colorPrimary: "#3b82f6",
@@ -4294,21 +4312,21 @@ const qn = {
4294
4312
  }
4295
4313
  };
4296
4314
  export {
4297
- Ot as AdvancedTable,
4298
- _t as AppModal,
4299
- Vt as BackButton,
4300
- Nt as Button,
4301
- At as Card,
4302
- hn as DynamicInput,
4303
- gn as DynamicTextArea,
4304
- It as EmptyAndSpin,
4305
- Pt as LinkButton,
4306
- Lt as PageTable,
4307
- dn as RichTextEditor,
4308
- rt as VideoCard,
4309
- mn as VirtualTable,
4310
- xn as Waterfall,
4311
- Mt as XcIcon,
4315
+ Ht as AdvancedTable,
4316
+ Lt as AppModal,
4317
+ Pt as BackButton,
4318
+ At as Button,
4319
+ _t as Card,
4320
+ gn as DynamicInput,
4321
+ vn as DynamicTextArea,
4322
+ Vt as EmptyAndSpin,
4323
+ Bt as LinkButton,
4324
+ Mt as PageTable,
4325
+ pn as RichTextEditor,
4326
+ ot as VideoCard,
4327
+ hn as VirtualTable,
4328
+ wn as Waterfall,
4329
+ It as XcIcon,
4312
4330
  qn as lightTheme
4313
4331
  };
4314
4332
  //# sourceMappingURL=index.es.js.map