@vtj/designer 0.12.0-alpha.1 → 0.12.0-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,14 +1,14 @@
1
1
  var tl = Object.defineProperty;
2
2
  var nl = (r, t, e) => t in r ? tl(r, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[t] = e;
3
3
  var Q = (r, t, e) => nl(r, typeof t != "symbol" ? t + "" : t, e);
4
- import { computed as V, unref as n, ref as C, watch as Z, reactive as zt, toValue as it, shallowRef as mt, shallowReadonly as sl, onMounted as tn, nextTick as at, getCurrentScope as ol, onScopeDispose as al, getCurrentInstance as As, toRaw as Ao, defineComponent as $, createElementBlock as R, openBlock as u, toDisplayString as ne, createVNode as p, withCtx as h, createElementVNode as T, createBlock as y, createCommentVNode as I, createTextVNode as X, mergeProps as Pe, h as Ut, Fragment as q, renderList as se, normalizeClass as pe, defineAsyncComponent as ll, resolveDynamicComponent as Vo, createSlots as To, renderSlot as At, withDirectives as jt, vShow as Yt, withModifiers as lt, isRef as Mn, normalizeStyle as rn, inject as Vs, provide as il, withKeys as yt, normalizeProps as Ro, guardReactiveProps as Io, onUnmounted as Ts, markRaw as ws, createApp as Oo, shallowReactive as rl, triggerRef as Mt, KeepAlive as jo } from "vue";
5
- import { ElNotification as Rs, ElMessage as wt, ElMessageBox as Vt, ElButton as ve, ElDivider as rt, ElInput as Me, ElRadioGroup as Do, ElRadioButton as yn, ElButtonGroup as cl, ElSwitch as Is, ElImage as $o, ElDropdown as No, ElDropdownMenu as Po, ElDropdownItem as Nn, ElEmpty as De, ElAlert as Ft, ElTooltip as Mo, ElTag as Os, ElTree as js, ElCollapse as Hn, ElCollapseItem as Gn, ElRow as Bn, ElCol as Ln, ElDrawer as Ds, ElForm as Ze, ElFormItem as cn, ElBreadcrumb as ul, ElBreadcrumbItem as dl, ElLoading as pl, ElBadge as ml, ElAvatar as qn, vLoading as vl, ElSelect as Bo, ElOption as Lo, ElCheckbox as gl, ElDialog as fl, ElSteps as hl, ElStep as ps, ElInputNumber as bl, ElColorPicker as yl, ElUpload as _l, ElSlider as wl, ElConfigProvider as kl, ElContainer as io, ElHeader as Sl, ElAside as ro, ElMain as xl, ElFooter as Cl } from "element-plus";
4
+ import { computed as V, unref as n, ref as C, watch as Z, reactive as zt, toValue as it, shallowRef as mt, shallowReadonly as sl, onMounted as nn, nextTick as at, getCurrentScope as ol, onScopeDispose as al, getCurrentInstance as As, toRaw as Ao, defineComponent as $, createElementBlock as R, openBlock as u, toDisplayString as ne, createVNode as p, withCtx as h, createElementVNode as T, createBlock as y, createCommentVNode as I, createTextVNode as X, mergeProps as Pe, h as Ut, Fragment as q, renderList as se, normalizeClass as pe, defineAsyncComponent as ll, resolveDynamicComponent as Vo, createSlots as To, renderSlot as At, withDirectives as Ot, vShow as Zt, withModifiers as lt, isRef as Mn, normalizeStyle as cn, inject as Vs, provide as il, withKeys as yt, normalizeProps as Ro, guardReactiveProps as Io, onUnmounted as Ts, markRaw as ws, createApp as jo, shallowReactive as rl, triggerRef as Mt, KeepAlive as Oo } from "vue";
5
+ import { ElNotification as Rs, ElMessage as wt, ElMessageBox as Vt, ElButton as ve, ElDivider as rt, ElInput as Me, ElRadioGroup as Do, ElRadioButton as _n, ElButtonGroup as cl, ElSwitch as Is, ElImage as $o, ElDropdown as No, ElDropdownMenu as Po, ElDropdownItem as Nn, ElEmpty as De, ElAlert as Ft, ElTooltip as Mo, ElTag as js, ElTree as Os, ElCollapse as Hn, ElCollapseItem as Gn, ElRow as Bn, ElCol as Ln, ElDrawer as Ds, ElForm as Ze, ElFormItem as un, ElBreadcrumb as ul, ElBreadcrumbItem as dl, ElLoading as pl, ElBadge as ml, ElAvatar as qn, vLoading as vl, ElSelect as Bo, ElOption as Lo, ElCheckbox as gl, ElDialog as fl, ElSteps as hl, ElStep as ps, ElInputNumber as bl, ElColorPicker as yl, ElUpload as _l, ElSlider as wl, ElConfigProvider as kl, ElContainer as io, ElHeader as Sl, ElAside as ro, ElMain as xl, ElFooter as Cl } from "element-plus";
6
6
  import El from "element-plus/es/locale/lang/zh-cn";
7
7
  import { XDialogForm as Rt, XField as F, createDialog as zo, XIcon as Tt, XDialog as kt, XPanel as Kn, XAction as Ve, XTabs as Xn, XContainer as de, XForm as $s, XAttachment as Al, XActionBar as Uo, XInputUnit as Fo, vResizable as co } from "@vtj/ui";
8
- import { kebabCase as Vl, jsonp as Lt, groupBy as wn, storage as dn, delay as Zt, dataURLtoBlob as Tl, upperFirstCamelCase as Wo, toRawType as ms, cloneDeep as Cn, logger as Dt, isPlainObject as Rl, fileToBase64 as Il, merge as Ns, toArray as Ps, debounce as Jo, uuid as Ol, getClientInfo as jl, base64 as Dl, arrayToMap as $l } from "@vtj/utils";
9
- import { BUILT_IN_NAME as zn, isBlock as Te, DirectiveModel as Ho, createNodeFrom as Nl, BUILT_IN_VUE as uo, BUILT_IN_VUE_ROUTER as Pl, emitter as je, EVENT_PROJECT_ACTIVED as ks, EVENT_NODE_CHANGE as kn, NodeModel as vs, EVENT_BLOCK_CHANGE as Ss, Base as Go, BUILT_IN_LIBRARAY_MAP as Ml, ProjectModel as Bl, EVENT_PROJECT_CHANGE as Ll, EVENT_PROJECT_BLOCKS_CHANGE as zl, EVENT_PROJECT_PAGES_CHANGE as Ul, EVENT_PROJECT_DEPS_CHANGE as Fl, EVENT_PROJECT_PUBLISH as Wl, EVENT_PROJECT_FILE_PUBLISH as Jl, EVENT_HISTORY_CHANGE as Hl, EVENT_HISTORY_LOAD as Gl, EVENT_PROJECT_GEN_SOURCE as ql, BlockModel as gs, HistoryModel as Kl } from "@vtj/core";
10
- import { parseExpression as Sn, parseFunction as qo, BUILT_IN_DIRECTIVES as Xl, JSCodeToString as pn, LIFE_CYCLES_LIST as Ql, DATA_TYPES as Yl, createMock as Zl, isJSExpression as en, ContextMode as Ko, clearLoaderCache as ei, parseDeps as ti, createAssetsCss as ni, createAssetScripts as po, getRawComponent as mo, createSchemaApis as si, mockCleanup as oi, mockApis as ai, Provider as li, Access as ii, isJSFunction as ri } from "@vtj/renderer";
11
- import { VtjIconBack as ci, VtjIconPc as ui, VtjIconPhone as di, VtjIconPad as pi, VtjIconEdit as Ms, VtjIconUndo as mi, VtjIconRedo as vi, VtjIconTemplate as Un, VtjIconPreview as gi, VtjIconRefresh as Xo, VtjIconSetting as Qo, VtjIconAi as Bs, Download as Fn, VtjIconPublish as fi, VtjIconProject as hi, icons as xs, ArrowDown as Qn, Search as nn, CopyDocument as Yo, Back as bi, VtjIconPlus as Zo, EditPen as yi, Delete as ea, VtjIconSave as _i, ArrowUp as ta, MoreFilled as vn, VtjIconCheck as na, VtjIconComponents as sa, VtjIconShare as wi, VtjIconHome as ki, VtjIconVisible as Si, VtjIconInvisible as oa, VtjIconUnlock as xi, VtjIconLock as aa, VtjIconRemove as Yn, VtjIconCopy as Ls, Files as Ci, VtjIconSearch as Ei, VtjIconHelp as la, VtjIconLayers as ia, Rank as Ai, VtjIconArrowUp as Vi, VtjIconArrowDown as Ti, IconDisplayBlock as Ri, IconDisplayFlex as Ii, IconDisplayInlineBlock as Oi, IconDisplayInline as ji, IconEyeInvisible as Di, IconFlexDirectionrow as $i, IconFlexDirectionrowReverse as Ni, IconFlexDirectioncolumn as Pi, IconFlexDirectioncolumnReverse as Mi, IconFlexJustifyflexStartrow as Bi, IconFlexJustifyflexEndrow as Li, IconFlexJustifycenterrow as zi, IconFlexJustifyspaceBetweenrow as Ui, IconFlexJustifyspaceAroundrow as Fi, IconFlexAlignflexStartrow as Wi, IconFlexAlignflexEndrow as Ji, IconFlexAligncenterrow as Hi, IconFlexAlignbaselinerow as Gi, IconFlexAlignstretchrow as qi, IconPositionTopLeft as Ki, IconPositionTopRight as Xi, IconPositionBottomLeft as Qi, IconPositionBottomRight as Yi, IconPositionLeft as Zi, IconPositionRight as er, IconPositionTop as tr, IconPositionBottom as nr, IconPositionAll as sr, IconTextAlignLeft as or, IconTextAlignCenter as ar, IconTextAlignRight as lr, IconTextAlignJustify as ir, IconFontStyleNone as rr, IconFontStyleItalic as cr, IconCross as ra, IconTextDecorationUnderline as ur, IconTextDecorationStrike as dr, IconTextDecorationOverline as pr, IconTileXy as mr, IconTileX as vr, IconTileY as gr, IconClose as fr, IconBorderAll as hr, IconBorderLeft as br, IconBorderTop as yr, IconBorderBottom as _r, IconBorderRight as wr, IconBorderStyleSolid as kr, IconBorderStyleDashed as Sr, IconBorderStyleDotted as xr, IconCursorAuto as Cr, IconCursorPointer as Er, IconCursorNotAllowed as Ar, IconCursorNone as Vr, ArrowRight as Tr, UserFilled as zs, VtjIconInfo as Rr, VtjIconNewChat as ca, Promotion as Ir, ArrowDownBold as Or, ArrowUpBold as jr, Refresh as Dr, View as ua, ShoppingCart as $r, Finished as Nr, Hide as Pr, Top as Mr, Bottom as Br, VtjIconChatRecord as Lr, VtjIconClose as zr, VtjIconDocument as Ur, VtjIconBlock as Fr, VtjIconOutline as Wr, VtjIconHistory as Jr, VtjIconApi as Hr, VtjIconCategory as Gr, VtjIconUniapp as qr, HomeFilled as Kr, Plus as Xr, Close as Qr, VtjIconVars as Yr, VtjIconSwitch as Zr, Switch as ec } from "@vtj/icons";
8
+ import { kebabCase as Vl, jsonp as Lt, groupBy as kn, storage as pn, delay as en, dataURLtoBlob as Tl, upperFirstCamelCase as Wo, toRawType as ms, cloneDeep as En, logger as Dt, isPlainObject as Rl, fileToBase64 as Il, merge as Ns, toArray as Ps, debounce as Jo, uuid as jl, getClientInfo as Ol, base64 as Dl, arrayToMap as $l } from "@vtj/utils";
9
+ import { BUILT_IN_NAME as zn, isBlock as Te, DirectiveModel as Ho, createNodeFrom as Nl, BUILT_IN_VUE as uo, BUILT_IN_VUE_ROUTER as Pl, emitter as Oe, EVENT_PROJECT_ACTIVED as ks, EVENT_NODE_CHANGE as Sn, NodeModel as vs, EVENT_BLOCK_CHANGE as Ss, Base as Go, BUILT_IN_LIBRARAY_MAP as Ml, ProjectModel as Bl, EVENT_PROJECT_CHANGE as Ll, EVENT_PROJECT_BLOCKS_CHANGE as zl, EVENT_PROJECT_PAGES_CHANGE as Ul, EVENT_PROJECT_DEPS_CHANGE as Fl, EVENT_PROJECT_PUBLISH as Wl, EVENT_PROJECT_FILE_PUBLISH as Jl, EVENT_HISTORY_CHANGE as Hl, EVENT_HISTORY_LOAD as Gl, EVENT_PROJECT_GEN_SOURCE as ql, BlockModel as gs, HistoryModel as Kl } from "@vtj/core";
10
+ import { parseExpression as xn, parseFunction as qo, BUILT_IN_DIRECTIVES as Xl, JSCodeToString as mn, LIFE_CYCLES_LIST as Ql, DATA_TYPES as Yl, createMock as Zl, isJSExpression as tn, ContextMode as Ko, clearLoaderCache as ei, parseDeps as ti, createAssetsCss as ni, createAssetScripts as po, getRawComponent as mo, createSchemaApis as si, mockCleanup as oi, mockApis as ai, Provider as li, Access as ii, isJSFunction as ri } from "@vtj/renderer";
11
+ import { VtjIconBack as ci, VtjIconPc as ui, VtjIconPhone as di, VtjIconPad as pi, VtjIconEdit as Ms, VtjIconUndo as mi, VtjIconRedo as vi, VtjIconTemplate as Un, VtjIconPreview as gi, VtjIconRefresh as Xo, VtjIconSetting as Qo, VtjIconAi as Bs, Download as Fn, VtjIconPublish as fi, VtjIconProject as hi, icons as xs, ArrowDown as Qn, Search as sn, CopyDocument as Yo, Back as bi, VtjIconPlus as Zo, EditPen as yi, Delete as ea, VtjIconSave as _i, ArrowUp as ta, MoreFilled as gn, VtjIconCheck as na, VtjIconComponents as sa, VtjIconShare as wi, VtjIconHome as ki, VtjIconVisible as Si, VtjIconInvisible as oa, VtjIconUnlock as xi, VtjIconLock as aa, VtjIconRemove as Yn, VtjIconCopy as Ls, Files as Ci, VtjIconSearch as Ei, VtjIconHelp as la, VtjIconLayers as ia, Rank as Ai, VtjIconArrowUp as Vi, VtjIconArrowDown as Ti, IconDisplayBlock as Ri, IconDisplayFlex as Ii, IconDisplayInlineBlock as ji, IconDisplayInline as Oi, IconEyeInvisible as Di, IconFlexDirectionrow as $i, IconFlexDirectionrowReverse as Ni, IconFlexDirectioncolumn as Pi, IconFlexDirectioncolumnReverse as Mi, IconFlexJustifyflexStartrow as Bi, IconFlexJustifyflexEndrow as Li, IconFlexJustifycenterrow as zi, IconFlexJustifyspaceBetweenrow as Ui, IconFlexJustifyspaceAroundrow as Fi, IconFlexAlignflexStartrow as Wi, IconFlexAlignflexEndrow as Ji, IconFlexAligncenterrow as Hi, IconFlexAlignbaselinerow as Gi, IconFlexAlignstretchrow as qi, IconPositionTopLeft as Ki, IconPositionTopRight as Xi, IconPositionBottomLeft as Qi, IconPositionBottomRight as Yi, IconPositionLeft as Zi, IconPositionRight as er, IconPositionTop as tr, IconPositionBottom as nr, IconPositionAll as sr, IconTextAlignLeft as or, IconTextAlignCenter as ar, IconTextAlignRight as lr, IconTextAlignJustify as ir, IconFontStyleNone as rr, IconFontStyleItalic as cr, IconCross as ra, IconTextDecorationUnderline as ur, IconTextDecorationStrike as dr, IconTextDecorationOverline as pr, IconTileXy as mr, IconTileX as vr, IconTileY as gr, IconClose as fr, IconBorderAll as hr, IconBorderLeft as br, IconBorderTop as yr, IconBorderBottom as _r, IconBorderRight as wr, IconBorderStyleSolid as kr, IconBorderStyleDashed as Sr, IconBorderStyleDotted as xr, IconCursorAuto as Cr, IconCursorPointer as Er, IconCursorNotAllowed as Ar, IconCursorNone as Vr, ArrowRight as Tr, UserFilled as zs, VtjIconInfo as Rr, VtjIconNewChat as ca, Promotion as Ir, ArrowDownBold as jr, ArrowUpBold as Or, Refresh as Dr, View as ua, ShoppingCart as $r, Finished as Nr, Hide as Pr, Top as Mr, Bottom as Br, VtjIconChatRecord as Lr, VtjIconClose as zr, VtjIconDocument as Ur, VtjIconBlock as Fr, VtjIconOutline as Wr, VtjIconHistory as Jr, VtjIconApi as Hr, VtjIconCategory as Gr, VtjIconUniapp as qr, HomeFilled as Kr, Plus as Xr, Close as Qr, VtjIconVars as Yr, VtjIconSwitch as Zr, Switch as ec } from "@vtj/icons";
12
12
  import tc from "html2canvas";
13
13
  import da from "mockjs";
14
14
  import { PAGE_LIFE_CYCLES_LIST as nc, APP_LIFE_CYCLE as sc, createUniAppComponent as oc, setupUniApp as ac } from "@vtj/uni";
@@ -18,10 +18,10 @@ import { editor as lc } from "monaco-editor";
18
18
  * Copyright (c) 2025, VTJ.PRO All rights reserved.
19
19
  * @name @vtj/designer
20
20
  * @author CHC chenhuachun1549@dingtalk.com
21
- * @version 0.12.0-alpha.1
21
+ * @version 0.12.0-alpha.2
22
22
  * @license <a href="https://vtj.pro/license.html">MIT License</a>
23
23
  */
24
- const xn = "0.12.0-alpha.1", ic = {
24
+ const Cn = "0.12.0-alpha.2", ic = {
25
25
  width: 390,
26
26
  height: 844
27
27
  }, rc = {
@@ -380,28 +380,28 @@ function Tc(r, t) {
380
380
  const e = C(""), { selected: s, isSelectBlock: o } = St(), i = V(() => s.value?.model.id), a = V(() => {
381
381
  const c = it(r), d = it(t), v = [];
382
382
  if (!c) return v;
383
- const m = d?.__contextRefs[i.value || ""], b = d === m || o.value ? [] : Object.keys(m?.context || {}).filter((O) => !["context", "ref"].includes(O)).map((O) => `this.context.${O}`);
383
+ const m = d?.__contextRefs[i.value || ""], b = d === m || o.value ? [] : Object.keys(m?.context || {}).filter((j) => !["context", "ref"].includes(j)).map((j) => `this.context.${j}`);
384
384
  b.length && v.push({ title: "上下文", items: b });
385
- const f = c.inject.map((O) => `this.${O.name}`);
385
+ const f = c.inject.map((j) => `this.${j.name}`);
386
386
  f.length && v.push({ title: "注入", items: f });
387
387
  const x = c.props.map(
388
- (O) => typeof O == "string" ? `this.props.${O}` : `this.props.${O.name}`
388
+ (j) => typeof j == "string" ? `this.props.${j}` : `this.props.${j.name}`
389
389
  );
390
390
  x.length && v.push({ title: "属性", items: x });
391
- const w = Object.keys(c.state).map((O) => `this.state.${O}`);
391
+ const w = Object.keys(c.state).map((j) => `this.state.${j}`);
392
392
  w.length && v.push({ title: "状态", items: w });
393
393
  const k = Object.keys(c.computed).map(
394
- (O) => `this.${O}.value`
394
+ (j) => `this.${j}.value`
395
395
  );
396
396
  k.length && v.push({ title: "计算属性", items: k });
397
- const _ = Object.keys(c.methods).map((O) => `this.${O}`);
397
+ const _ = Object.keys(c.methods).map((j) => `this.${j}`);
398
398
  _.length && v.push({ title: "方法", items: _ });
399
399
  const A = Object.keys(c.dataSources).map(
400
- (O) => `this.${O}`
400
+ (j) => `this.${j}`
401
401
  );
402
402
  A.length && v.push({ title: "数据源", items: A });
403
403
  const E = Object.keys(d?.$refs || {}).map(
404
- (O) => `this.$refs.${O}`
404
+ (j) => `this.$refs.${j}`
405
405
  );
406
406
  return E.length && v.push({ title: "refs", items: E }), v;
407
407
  }), l = V(() => {
@@ -513,7 +513,7 @@ function Rc(r) {
513
513
  isExist: a
514
514
  };
515
515
  }
516
- function un(r, t) {
516
+ function dn(r, t) {
517
517
  return Vt.alert(r, {
518
518
  title: "提示",
519
519
  type: "warning",
@@ -555,7 +555,7 @@ function Xe(r, t, e = !1) {
555
555
  let s = !0;
556
556
  const o = Ic(t);
557
557
  try {
558
- r.type === "JSExpression" ? Sn(r, o, e, !0) : qo(r, o, e, !0);
558
+ r.type === "JSExpression" ? xn(r, o, e, !0) : qo(r, o, e, !0);
559
559
  } catch (i) {
560
560
  s = !1, Rs.error({
561
561
  title: "代码错误",
@@ -564,7 +564,7 @@ function Xe(r, t, e = !1) {
564
564
  }
565
565
  return s;
566
566
  }
567
- function Oc(r) {
567
+ function jc(r) {
568
568
  return Object.keys(r).concat(
569
569
  Object.getPrototypeOf(r) ? Object.getOwnPropertyNames(Object.getPrototypeOf(r)) : []
570
570
  ).filter((t) => !["constructor"].includes(t));
@@ -598,14 +598,14 @@ function ma() {
598
598
  backwardDisabled: c
599
599
  };
600
600
  }
601
- function sn() {
601
+ function on() {
602
602
  const r = Be(), t = V(() => r.project.value);
603
603
  return {
604
604
  engine: r,
605
605
  project: t
606
606
  };
607
607
  }
608
- function jc(r) {
608
+ function Oc(r) {
609
609
  const t = Be(), e = V(() => {
610
610
  const l = r.value?.model || null;
611
611
  return !l || Te(l) ? null : l;
@@ -672,12 +672,12 @@ function Nc(r) {
672
672
  const t = Be(), e = V(() => {
673
673
  const E = r.value?.model || null;
674
674
  return Te(E) ? null : E;
675
- }), s = (E) => V(() => e.value && (e.value.directives || []).find((O) => O.name === E) || hs(E)), o = () => V(() => {
675
+ }), s = (E) => V(() => e.value && (e.value.directives || []).find((j) => j.name === E) || hs(E)), o = () => V(() => {
676
676
  if (!e.value) return [];
677
677
  const E = t.assets.componentMap.get(e.value.name || "");
678
- return (E ? $c(E) : []).map((j) => (e.value?.directives || []).find(
679
- (B) => B.name === "vModel" && B.arg == j.name
680
- ) || Dc(j.name));
678
+ return (E ? $c(E) : []).map((O) => (e.value?.directives || []).find(
679
+ (B) => B.name === "vModel" && B.arg == O.name
680
+ ) || Dc(O.name));
681
681
  }), i = () => V(() => e.value ? (e.value.directives || []).filter(
682
682
  (E) => !Xl.includes(E.name)
683
683
  ) : []), a = s("vIf"), l = s("vShow"), c = s("vBind"), d = s("vFor"), v = s("vHtml"), m = o(), g = i(), b = {
@@ -697,26 +697,26 @@ function Nc(r) {
697
697
  vHtml: v,
698
698
  vModels: m,
699
699
  customDirectives: g,
700
- onValueChange: (E, O) => {
701
- const j = b[E];
702
- e.value && (O ? (j.value.value = O, e.value.setDirective(j.value)) : (j.value.value = void 0, e.value.removeDirective(j.value)));
700
+ onValueChange: (E, j) => {
701
+ const O = b[E];
702
+ e.value && (j ? (O.value.value = j, e.value.setDirective(O.value)) : (O.value.value = void 0, e.value.removeDirective(O.value)));
703
703
  },
704
- onForChange: (E, O) => {
704
+ onForChange: (E, j) => {
705
705
  if (e.value) {
706
706
  if (E === "value") {
707
- O ? (d.value.value = O, e.value.setDirective(d.value)) : e.value.removeDirective(d.value);
707
+ j ? (d.value.value = j, e.value.setDirective(d.value)) : e.value.removeDirective(d.value);
708
708
  return;
709
709
  }
710
710
  (E === "item" || E === "index") && (d.value.iterator = {
711
711
  ...d.value.iterator,
712
- [E]: O || void 0
712
+ [E]: j || void 0
713
713
  }, e.value.setDirective(d.value));
714
714
  }
715
715
  },
716
- onModelChange: (E, O) => {
716
+ onModelChange: (E, j) => {
717
717
  if (!e.value) return;
718
- const j = parseInt(E), B = m.value[j];
719
- B && (O ? (B.value = O, e.value.setDirective(B)) : (B.value = void 0, e.value.removeDirective(B)));
718
+ const O = parseInt(E), B = m.value[O];
719
+ B && (j ? (B.value = j, e.value.setDirective(B)) : (B.value = void 0, e.value.removeDirective(B)));
720
720
  },
721
721
  onAddCustom: () => {
722
722
  const E = hs("");
@@ -725,13 +725,13 @@ function Nc(r) {
725
725
  onRemoveCustom: async (E) => {
726
726
  await Jt("确定删除指令?") && e.value?.removeDirective(E);
727
727
  },
728
- onCustomChange: (E) => (O, j) => {
729
- E.update({ [O]: j }), e.value?.setDirective(E);
728
+ onCustomChange: (E) => (j, O) => {
729
+ E.update({ [j]: O }), e.value?.setDirective(E);
730
730
  }
731
731
  };
732
732
  }
733
733
  function Pc() {
734
- const { engine: r, project: t } = sn(), e = V(() => t.value?.apis || []), s = V(() => t.value?.meta || []);
734
+ const { engine: r, project: t } = on(), e = V(() => t.value?.apis || []), s = V(() => t.value?.meta || []);
735
735
  return {
736
736
  engine: r,
737
737
  project: t,
@@ -838,7 +838,7 @@ function Ht() {
838
838
  },
839
839
  body: JSON.stringify(z)
840
840
  }).then((te) => te.json()).catch(() => null);
841
- return P?.success || await un(P.message || "未知错误"), P;
841
+ return P?.success || await dn(P.message || "未知错误"), P;
842
842
  },
843
843
  getChats: async (z) => {
844
844
  if (s?.getChats)
@@ -866,7 +866,7 @@ function Ht() {
866
866
  },
867
867
  body: JSON.stringify(z)
868
868
  }).then((te) => te.json()).catch(() => null);
869
- return P?.success || await un(P.message || "未知错误"), P;
869
+ return P?.success || await dn(P.message || "未知错误"), P;
870
870
  },
871
871
  removeTopic: async (z) => {
872
872
  if (s?.removeTopic)
@@ -894,13 +894,13 @@ function Ht() {
894
894
  }
895
895
  const et = Ge.decode(qe).split(`
896
896
  `);
897
- for (const nt of et)
898
- if (nt.startsWith("data: "))
897
+ for (const st of et)
898
+ if (st.startsWith("data: "))
899
899
  try {
900
- const vt = JSON.parse(nt.slice(6));
900
+ const vt = JSON.parse(st.slice(6));
901
901
  L && L(vt, Fe);
902
902
  } catch (vt) {
903
- const ut = nt.slice(6);
903
+ const ut = st.slice(6);
904
904
  P && P(ut ? new Error(ut) : vt);
905
905
  break;
906
906
  }
@@ -945,7 +945,7 @@ function Ht() {
945
945
  const z = t?.getData()?.token, D = `${e}/api/open/order/${z}`, L = await window.fetch(D, {
946
946
  method: "post"
947
947
  }).then((P) => P.json()).catch(() => null);
948
- return L?.success || await un(L.message || "未知错误"), L;
948
+ return L?.success || await dn(L.message || "未知错误"), L;
949
949
  },
950
950
  cancelOrder: async (z) => {
951
951
  if (s?.cancelOrder)
@@ -999,7 +999,7 @@ function Mc() {
999
999
  }, E.dsl = A, f.isPageFile(E) ? f.updatePage(E) : f.updateBlock(E));
1000
1000
  }, v = V(() => {
1001
1001
  const g = t?.getData()?.id;
1002
- return wn(l.value, (b) => b.author === g ? "我的" : b.category);
1002
+ return kn(l.value, (b) => b.author === g ? "我的" : b.category);
1003
1003
  }), m = () => {
1004
1004
  const g = r.project.value;
1005
1005
  c.value = !0, o(g?.platform).then((b) => {
@@ -1025,8 +1025,8 @@ function Mc() {
1025
1025
  }
1026
1026
  function va(r) {
1027
1027
  const t = C();
1028
- return t.value ? t.value !== xn && r && r(t.value) : window.fetch(fc).then((e) => e.json()).then((e) => {
1029
- e && (t.value = e["dist-tags"]?.latest, t.value && t.value !== xn && r && r(t.value));
1028
+ return t.value ? t.value !== Cn && r && r(t.value) : window.fetch(fc).then((e) => e.json()).then((e) => {
1029
+ e && (t.value = e["dist-tags"]?.latest, t.value && t.value !== Cn && r && r(t.value));
1030
1030
  }), {
1031
1031
  latest: t
1032
1032
  };
@@ -1036,7 +1036,7 @@ function Fs(r) {
1036
1036
  }
1037
1037
  const Zn = typeof window < "u" && typeof document < "u";
1038
1038
  typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
1039
- const Bc = (r) => typeof r < "u", Lc = Object.prototype.toString, zc = (r) => Lc.call(r) === "[object Object]", ln = () => {
1039
+ const Bc = (r) => typeof r < "u", Lc = Object.prototype.toString, zc = (r) => Lc.call(r) === "[object Object]", rn = () => {
1040
1040
  }, Uc = /* @__PURE__ */ Fc();
1041
1041
  function Fc() {
1042
1042
  var r, t;
@@ -1059,7 +1059,7 @@ function Jc(r) {
1059
1059
  return As();
1060
1060
  }
1061
1061
  function Hc(r, t = !0, e) {
1062
- Jc() ? tn(r, e) : t ? r() : at(r);
1062
+ Jc() ? nn(r, e) : t ? r() : at(r);
1063
1063
  }
1064
1064
  function Gc(r, t, e = {}) {
1065
1065
  const {
@@ -1100,7 +1100,7 @@ function _t(r) {
1100
1100
  const e = it(r);
1101
1101
  return (t = e?.$el) != null ? t : e;
1102
1102
  }
1103
- function Qt(...r) {
1103
+ function Yt(...r) {
1104
1104
  const t = [], e = () => {
1105
1105
  t.forEach((l) => l()), t.length = 0;
1106
1106
  }, s = (l, c, d, v) => (l.addEventListener(c, d, v), () => l.removeEventListener(c, d, v)), o = V(() => {
@@ -1139,11 +1139,11 @@ let ho = !1;
1139
1139
  function Kc(r, t, e = {}) {
1140
1140
  const { window: s = es, ignore: o = [], capture: i = !0, detectIframe: a = !1, controls: l = !1 } = e;
1141
1141
  if (!s)
1142
- return l ? { stop: ln, cancel: ln, trigger: ln } : ln;
1142
+ return l ? { stop: rn, cancel: rn, trigger: rn } : rn;
1143
1143
  if (Uc && !ho) {
1144
1144
  ho = !0;
1145
1145
  const w = { passive: !0 };
1146
- Array.from(s.document.body.children).forEach((k) => Qt(k, "click", ln, w)), Qt(s.document.documentElement, "click", ln, w);
1146
+ Array.from(s.document.body.children).forEach((k) => Yt(k, "click", rn, w)), Yt(s.document.documentElement, "click", rn, w);
1147
1147
  }
1148
1148
  let c = !0;
1149
1149
  const d = (w) => it(o).some((k) => {
@@ -1174,16 +1174,16 @@ function Kc(r, t, e = {}) {
1174
1174
  };
1175
1175
  let b = !1;
1176
1176
  const f = [
1177
- Qt(s, "click", (w) => {
1177
+ Yt(s, "click", (w) => {
1178
1178
  b || (b = !0, setTimeout(() => {
1179
1179
  b = !1;
1180
1180
  }, 0), g(w));
1181
1181
  }, { passive: !0, capture: i }),
1182
- Qt(s, "pointerdown", (w) => {
1182
+ Yt(s, "pointerdown", (w) => {
1183
1183
  const k = _t(r);
1184
1184
  c = !d(w) && !!(k && !w.composedPath().includes(k));
1185
1185
  }, { passive: !0 }),
1186
- a && Qt(s, "blur", (w) => {
1186
+ a && Yt(s, "blur", (w) => {
1187
1187
  setTimeout(() => {
1188
1188
  var k;
1189
1189
  const _ = _t(r);
@@ -1203,7 +1203,7 @@ function Kc(r, t, e = {}) {
1203
1203
  }
1204
1204
  function Xc() {
1205
1205
  const r = mt(!1), t = As();
1206
- return t && tn(() => {
1206
+ return t && nn(() => {
1207
1207
  r.value = !0;
1208
1208
  }, t), r;
1209
1209
  }
@@ -1219,7 +1219,7 @@ function bo(r, t = {}) {
1219
1219
  var v, m;
1220
1220
  l.value = (m = (v = i.value) == null ? void 0 : v.state) != null ? m : "prompt";
1221
1221
  };
1222
- Qt(i, "change", c, { passive: !0 });
1222
+ Yt(i, "change", c, { passive: !0 });
1223
1223
  const d = Wc(async () => {
1224
1224
  if (o.value) {
1225
1225
  if (!i.value)
@@ -1258,7 +1258,7 @@ function Js(r = {}) {
1258
1258
  }
1259
1259
  _ && (v.value = w());
1260
1260
  }
1261
- d.value && e && Qt(["copy", "cut"], b, { passive: !0 });
1261
+ d.value && e && Yt(["copy", "cut"], b, { passive: !0 });
1262
1262
  async function f(_ = it(s)) {
1263
1263
  if (d.value && _ != null) {
1264
1264
  let A = !(a.value && k(c.value));
@@ -1318,7 +1318,7 @@ function Yc(r, t, e = {}) {
1318
1318
  stop: v
1319
1319
  };
1320
1320
  }
1321
- function mn(r, t = { width: 0, height: 0 }, e = {}) {
1321
+ function vn(r, t = { width: 0, height: 0 }, e = {}) {
1322
1322
  const { window: s = es, box: o = "content-box" } = e, i = V(() => {
1323
1323
  var m, g;
1324
1324
  return (g = (m = _t(r)) == null ? void 0 : m.namespaceURI) == null ? void 0 : g.includes("svg");
@@ -1376,16 +1376,16 @@ function Zc(r, t, e, s = {}) {
1376
1376
  };
1377
1377
  if (c) {
1378
1378
  const A = k(), E = C(A);
1379
- let O = !1;
1379
+ let j = !1;
1380
1380
  return Z(
1381
1381
  () => r[t],
1382
- (j) => {
1383
- O || (O = !0, E.value = w(j), at(() => O = !1));
1382
+ (O) => {
1383
+ j || (j = !0, E.value = w(O), at(() => j = !1));
1384
1384
  }
1385
1385
  ), Z(
1386
1386
  E,
1387
- (j) => {
1388
- !O && (j !== r[t] || v) && _(j);
1387
+ (O) => {
1388
+ !j && (O !== r[t] || v) && _(O);
1389
1389
  },
1390
1390
  { deep: v }
1391
1391
  ), E;
@@ -1432,24 +1432,24 @@ function nu() {
1432
1432
  createOrder: g,
1433
1433
  cancelOrder: b,
1434
1434
  getOrder: f
1435
- } = Ht(), x = "CHAT_HIDE_CODE", w = t.skeleton?.getRegion("Apps").regionRef, k = C(!1), _ = C(!1), A = C(!0), E = C(!1), O = eu("LLM", e), j = C([]), B = C([]), N = C(null), W = C(null), z = C(), D = C(), L = C(!!dn.get(x, { type: "local" })), P = C(""), te = C(), ue = V(() => B.value.some((H) => H.status === "Pending")), Ue = V(() => te.value ? te.value.mode === 2 && !te.value.invited : !0), { height: _e } = mn(z), be = async (H) => {
1435
+ } = Ht(), x = "CHAT_HIDE_CODE", w = t.skeleton?.getRegion("Apps").regionRef, k = C(!1), _ = C(!1), A = C(!0), E = C(!1), j = eu("LLM", e), O = C([]), B = C([]), N = C(null), W = C(null), z = C(), D = C(), L = C(!!pn.get(x, { type: "local" })), P = C(""), te = C(), ue = V(() => B.value.some((H) => H.status === "Pending")), Ue = V(() => te.value ? te.value.mode === 2 && !te.value.invited : !0), { height: _e } = vn(z), be = async (H) => {
1436
1436
  const fe = await i(H);
1437
1437
  fe && fe.success && (B.value = fe.data);
1438
1438
  }, Ge = async (H) => {
1439
1439
  if (k.value = !1, te.value = await m(), !te.value || !H || H.id === N.value?.fileId) return;
1440
- j.value = [], B.value = [], A.value = !0;
1440
+ O.value = [], B.value = [], A.value = !0;
1441
1441
  const fe = await o(H.id).catch(() => null);
1442
- fe && fe.success && (j.value = fe.data), j.value.length && (A.value = !1, N.value = j.value[0], await be(N.value.id)), k.value = !0;
1442
+ fe && fe.success && (O.value = fe.data), O.value.length && (A.value = !1, N.value = O.value[0], await be(N.value.id)), k.value = !0;
1443
1443
  }, Fe = async (H) => {
1444
1444
  _.value = !0;
1445
1445
  const fe = await tu(H, t), Re = await s(fe).catch(() => null);
1446
1446
  if (_.value = !1, Re && Re.success) {
1447
1447
  const { topic: tt, chat: Le } = Re.data;
1448
- B.value = [], j.value.unshift(tt), A.value = !1, N.value = tt;
1448
+ B.value = [], O.value.unshift(tt), A.value = !1, N.value = tt;
1449
1449
  const xt = zt(Le);
1450
- B.value.push(xt), vt(xt, (hn) => {
1451
- H.auto && fn(hn);
1452
- }), await Zt(0), D.value && D.value.scrollToBottom();
1450
+ B.value.push(xt), vt(xt, (bn) => {
1451
+ H.auto && hn(bn);
1452
+ }), await en(0), D.value && D.value.scrollToBottom();
1453
1453
  } else
1454
1454
  await Ge(null);
1455
1455
  return Re;
@@ -1463,15 +1463,15 @@ function nu() {
1463
1463
  if (_.value = !1, Re && Re.success) {
1464
1464
  const tt = zt(Re.data);
1465
1465
  B.value.push(tt), vt(tt, (Le) => {
1466
- H.auto && fn(Le);
1467
- }), await Zt(0), D.value && D.value.scrollToBottom();
1466
+ H.auto && hn(Le);
1467
+ }), await en(0), D.value && D.value.scrollToBottom();
1468
1468
  } else
1469
1469
  await Ge(null);
1470
1470
  return Re;
1471
1471
  }, et = async (H) => {
1472
1472
  const fe = await l(H.id).catch(() => null);
1473
- fe && fe.success && (j.value = j.value.filter((Re) => Re.id !== H.id), H.id === N.value?.id && (B.value = [], N.value = null, A.value = !0));
1474
- }, nt = async (H) => {
1473
+ fe && fe.success && (O.value = O.value.filter((Re) => Re.id !== H.id), H.id === N.value?.id && (B.value = [], N.value = null, A.value = !0));
1474
+ }, st = async (H) => {
1475
1475
  if (!N.value) return;
1476
1476
  const fe = N.value?.fileId, Re = t.project.value?.toDsl(), { name: tt = "" } = t.current.value || {}, Le = ut(H.content);
1477
1477
  return await t.service.parseVue(Re, {
@@ -1489,13 +1489,22 @@ function nu() {
1489
1489
  async (Le, xt) => {
1490
1490
  const ft = Le?.choices?.[0]?.delta;
1491
1491
  if (ft) {
1492
- const $t = ft.content || "", st = ft.reasoning_content || "";
1493
- $t && (H.content += $t), st && (H.reasoning += st, Re += Date.now() - tt);
1492
+ const $t = ft.content || "", nt = ft.reasoning_content || "";
1493
+ $t && (H.content += $t), nt && (H.reasoning += nt, Re += Date.now() - tt);
1494
1494
  }
1495
1495
  if (Le?.usage && (H.tokens = Le.usage.total_tokens || 0), xt && H.status === "Pending") {
1496
1496
  H.status = "Success", H.thinking = Math.ceil(Re / 1e3), H.vue = ut(H.content);
1497
- const $t = await nt(H).catch((st) => (Array.isArray(st) ? H.message = st.join(`
1498
- `) : H.message = st?.message || "代码有错误。", H.status = "Error", null));
1497
+ const $t = await st(H).catch((nt) => {
1498
+ if (Array.isArray(nt))
1499
+ H.message = nt.join(`
1500
+ `);
1501
+ else {
1502
+ const Xt = nt?.data || nt?.message;
1503
+ H.message = Array.isArray(Xt) ? Xt.join(`
1504
+ `) : "代码有错误。";
1505
+ }
1506
+ return H.status = "Error", null;
1507
+ });
1499
1508
  $t && (H.dsl = $t), await d(H), fe && fe(H);
1500
1509
  }
1501
1510
  },
@@ -1507,7 +1516,7 @@ function nu() {
1507
1516
  }, ut = (H) => {
1508
1517
  const fe = /```vue\n([\w\W]*)```/;
1509
1518
  return H.match(fe)?.[1] ?? "";
1510
- }, on = async (H) => {
1519
+ }, an = async (H) => {
1511
1520
  if (!N.value || !W.value) return;
1512
1521
  const fe = N.value?.fileId, Re = t.project.value?.toDsl(), { name: tt = "" } = t.current.value || {}, Le = await t.service.parseVue(Re, {
1513
1522
  id: fe,
@@ -1515,7 +1524,7 @@ function nu() {
1515
1524
  source: H
1516
1525
  }).catch((xt) => xt);
1517
1526
  return Array.isArray(Le) ? Promise.reject(Le) : (W.value.dsl = Le, await d(W.value), Le);
1518
- }, gn = () => {
1527
+ }, fn = () => {
1519
1528
  D.value && !A.value && D.value.scrollToTop();
1520
1529
  }, qt = () => {
1521
1530
  D.value && !A.value && D.value.scrollToBottom();
@@ -1530,7 +1539,7 @@ function nu() {
1530
1539
  }, Kt = (H) => {
1531
1540
  if (!ue.value)
1532
1541
  return vt(H);
1533
- }, fn = (H) => {
1542
+ }, hn = (H) => {
1534
1543
  H.dsl && t.applyAI(H.dsl), E.value = !1, W.value = null;
1535
1544
  }, ns = (H) => {
1536
1545
  H.vue = ut(H.content), W.value = H, E.value = !0;
@@ -1539,11 +1548,11 @@ function nu() {
1539
1548
  const fe = H.message ? `页面存在以下问题:
1540
1549
  ${H.message}
1541
1550
  请检查代码并修复` : "请检查代码是否有错误,是否符合规则要求,并改正";
1542
- An(fe);
1543
- }, An = (H, fe) => {
1551
+ Vn(fe);
1552
+ }, Vn = (H, fe) => {
1544
1553
  P.value = H, fe && (A.value = fe);
1545
1554
  }, os = () => {
1546
- A.value || (L.value = !L.value, dn.save(x, L.value, { type: "local" }));
1555
+ A.value || (L.value = !L.value, pn.save(x, L.value, { type: "local" }));
1547
1556
  };
1548
1557
  return Z(
1549
1558
  () => w?.active,
@@ -1564,24 +1573,24 @@ function nu() {
1564
1573
  init: Ge,
1565
1574
  loading: _,
1566
1575
  isNewChat: A,
1567
- models: O,
1576
+ models: j,
1568
1577
  onPostTopic: Fe,
1569
- topics: j,
1578
+ topics: O,
1570
1579
  chats: B,
1571
1580
  currentTopic: N,
1572
1581
  onPostChat: qe,
1573
1582
  loadChats: be,
1574
1583
  onRemoveTopic: et,
1575
1584
  getVueCode: ut,
1576
- vue2Dsl: nt,
1585
+ vue2Dsl: st,
1577
1586
  onRefresh: Kt,
1578
- onApply: fn,
1587
+ onApply: hn,
1579
1588
  onView: ns,
1580
1589
  listRef: z,
1581
1590
  panelRef: D,
1582
1591
  currentChat: W,
1583
1592
  showDetail: E,
1584
- scrollToTop: gn,
1593
+ scrollToTop: fn,
1585
1594
  scrollToBottom: qt,
1586
1595
  expandAll: gt,
1587
1596
  collapseAll: We,
@@ -1589,7 +1598,7 @@ function nu() {
1589
1598
  toggleHideCode: os,
1590
1599
  isHideCode: L,
1591
1600
  onFix: ss,
1592
- fillPromptInput: An,
1601
+ fillPromptInput: Vn,
1593
1602
  promptText: P,
1594
1603
  getHotTopics: v,
1595
1604
  settings: te,
@@ -1597,7 +1606,7 @@ function nu() {
1597
1606
  createOrder: g,
1598
1607
  cancelOrder: b,
1599
1608
  getOrder: f,
1600
- updateChatDsl: on
1609
+ updateChatDsl: an
1601
1610
  };
1602
1611
  }
1603
1612
  const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20t='1711803009570'%20class='icon'%20viewBox='0%200%201280%201024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20p-id='1500'%20width='320'%20height='256'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cpath%20d='M557.85%201023l-122-35.4c-12.8-3.6-20-17-16.4-29.8L692.45%2017.4c3.6-12.8%2017-20%2029.8-16.4l122%2035.4c12.8%203.6%2020%2017%2016.4%2029.8L587.65%201006.6c-3.8%2012.8-17%2020.2-29.8%2016.4z%20m-228-224.4l87-92.8c9.2-9.8%208.6-25.4-1.6-34.4L234.05%20512l181.2-159.4c10.2-9%2011-24.6%201.6-34.4l-87-92.8c-9-9.6-24.2-10.2-34-1L7.65%20494.4c-10.2%209.4-10.2%2025.6%200%2035l288.2%20270.2c9.8%209.2%2025%208.8%2034-1z%20m654.4%201.2l288.2-270.2c10.2-9.4%2010.2-25.6%200-35L984.25%20224.2c-9.6-9-24.8-8.6-34%201L863.25%20318c-9.2%209.8-8.6%2025.4%201.6%2034.4L1046.05%20512l-181.2%20159.4c-10.2%209-11%2024.6-1.6%2034.4l87%2092.8c9%209.8%2024.2%2010.2%2034%201.2z'%20fill='%230157fe'%20p-id='1501'%3e%3c/path%3e%3c/svg%3e", ou = ["title", "src"], au = { key: 1 }, lu = /* @__PURE__ */ $({
@@ -1728,7 +1737,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
1728
1737
  "onUpdate:modelValue": b[0] || (b[0] = (f) => d.value = f)
1729
1738
  }, {
1730
1739
  default: h(() => [
1731
- p(n(yn), {
1740
+ p(n(_n), {
1732
1741
  label: "pc",
1733
1742
  value: "pc"
1734
1743
  }, {
@@ -1737,7 +1746,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
1737
1746
  ]),
1738
1747
  _: 1
1739
1748
  }),
1740
- p(n(yn), {
1749
+ p(n(_n), {
1741
1750
  label: "mobile",
1742
1751
  value: "mobile"
1743
1752
  }, {
@@ -1746,7 +1755,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
1746
1755
  ]),
1747
1756
  _: 1
1748
1757
  }),
1749
- p(n(yn), {
1758
+ p(n(_n), {
1750
1759
  label: "pad",
1751
1760
  value: "pad"
1752
1761
  }, {
@@ -1755,7 +1764,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
1755
1764
  ]),
1756
1765
  _: 1
1757
1766
  }),
1758
- p(n(yn), {
1767
+ p(n(_n), {
1759
1768
  label: "custom",
1760
1769
  value: "custom"
1761
1770
  }, {
@@ -1961,7 +1970,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
1961
1970
  const t = r, { engine: e, designer: s } = St(), { isLogined: o, toRemoteAuth: i } = Ht(), a = C(!1), l = C(!1), c = C(), d = () => {
1962
1971
  e.current.value ? (a.value ? e.skeleton?.getWidget("Previewer")?.widgetRef.refresh() : (s.value?.setSelected(null), e.simulator.refresh()), Ne("刷新完成", "success")) : Ne("请先打开文件", "warning");
1963
1972
  }, v = async () => {
1964
- e.current.value ? (a.value && (e.skeleton?.closePreview(), a.value = !1, await Zt(1e3)), s.value?.setSelected(e.current.value)) : Ne("请先打开文件", "warning");
1973
+ e.current.value ? (a.value && (e.skeleton?.closePreview(), a.value = !1, await en(1e3)), s.value?.setSelected(e.current.value)) : Ne("请先打开文件", "warning");
1965
1974
  }, m = () => {
1966
1975
  if (e.project.value)
1967
1976
  if (e.current.value) {
@@ -1980,13 +1989,13 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
1980
1989
  if (k)
1981
1990
  if (k.currentFile)
1982
1991
  if (await o()) {
1983
- const _ = await e.simulator.capture(), { name: A, title: E, market: O } = k.currentFile;
1992
+ const _ = await e.simulator.capture(), { name: A, title: E, market: j } = k.currentFile;
1984
1993
  if (!_) {
1985
1994
  Ne("截图失败", "warning");
1986
1995
  return;
1987
1996
  }
1988
1997
  c.value = {
1989
- id: O?.id,
1998
+ id: j?.id,
1990
1999
  canvas: _,
1991
2000
  name: A,
1992
2001
  label: E,
@@ -2224,7 +2233,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2224
2233
  T("div", Eu, [
2225
2234
  p(n(Me), {
2226
2235
  size: e.size,
2227
- "prefix-icon": n(nn),
2236
+ "prefix-icon": n(sn),
2228
2237
  clearable: "",
2229
2238
  modelValue: a.value,
2230
2239
  "onUpdate:modelValue": f[0] || (f[0] = (x) => a.value = x),
@@ -2245,7 +2254,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2245
2254
  ]));
2246
2255
  }
2247
2256
  }), Ae = ll({
2248
- loader: () => import("./Editor-COl9ea8e.js"),
2257
+ loader: () => import("./Editor-6X-LwFIT.js"),
2249
2258
  loadingComponent: $({
2250
2259
  render() {
2251
2260
  return Ut("div", "正在拼命加载...");
@@ -2264,7 +2273,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2264
2273
  parentId: {}
2265
2274
  },
2266
2275
  setup(r) {
2267
- const t = r, { project: e, engine: s } = sn(), { designer: o } = St(), i = V(() => t.item ? "编辑页面" : "新增页面"), a = V(() => {
2276
+ const t = r, { project: e, engine: s } = on(), { designer: o } = St(), i = V(() => t.item ? "编辑页面" : "新增页面"), a = V(() => {
2268
2277
  const { platform: _ = "web" } = e.value || {};
2269
2278
  return _ === "web";
2270
2279
  }), l = V(() => {
@@ -2576,17 +2585,17 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2576
2585
  E && E.scrollTo(0, E.scrollHeight);
2577
2586
  },
2578
2587
  autoScrollToBottom: (E = 200) => {
2579
- const O = a.value?.bodyRef?.$el;
2580
- if (O) {
2581
- const { offsetHeight: j, scrollHeight: B, scrollTop: N } = O;
2582
- B - (j + N) < E && O.scrollTo(0, O.scrollHeight);
2588
+ const j = a.value?.bodyRef?.$el;
2589
+ if (j) {
2590
+ const { offsetHeight: O, scrollHeight: B, scrollTop: N } = j;
2591
+ B - (O + N) < E && j.scrollTo(0, j.scrollHeight);
2583
2592
  }
2584
2593
  },
2585
2594
  scrollToTop: () => {
2586
2595
  const E = a.value?.bodyRef?.$el;
2587
2596
  E && E.scrollTo(0, 0);
2588
2597
  }
2589
- }), (E, O) => (u(), y(n(Kn), {
2598
+ }), (E, j) => (u(), y(n(Kn), {
2590
2599
  ref_key: "panelRef",
2591
2600
  ref: a,
2592
2601
  class: pe(["v-panel", l.value]),
@@ -2643,27 +2652,27 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2643
2652
  title: "保存",
2644
2653
  onClick: b
2645
2654
  }, null, 8, ["size", "icon"])) : I("", !0),
2646
- s.collapsable ? jt((u(), y(n(Ve), {
2655
+ s.collapsable ? Ot((u(), y(n(Ve), {
2647
2656
  key: 5,
2648
2657
  size: E.$attrs.size,
2649
2658
  mode: "icon",
2650
2659
  icon: n(Qn),
2651
2660
  background: "hover",
2652
2661
  title: "展开",
2653
- onClick: O[0] || (O[0] = (j) => w(!1))
2662
+ onClick: j[0] || (j[0] = (O) => w(!1))
2654
2663
  }, null, 8, ["size", "icon"])), [
2655
- [Yt, i.value]
2664
+ [Zt, i.value]
2656
2665
  ]) : I("", !0),
2657
- s.collapsable ? jt((u(), y(n(Ve), {
2666
+ s.collapsable ? Ot((u(), y(n(Ve), {
2658
2667
  key: 6,
2659
2668
  size: E.$attrs.size,
2660
2669
  mode: "icon",
2661
2670
  icon: n(ta),
2662
2671
  background: "hover",
2663
2672
  title: "收起",
2664
- onClick: O[1] || (O[1] = (j) => w(!0))
2673
+ onClick: j[1] || (j[1] = (O) => w(!0))
2665
2674
  }, null, 8, ["size", "icon"])), [
2666
- [Yt, !i.value]
2675
+ [Zt, !i.value]
2667
2676
  ]) : I("", !0),
2668
2677
  At(E.$slots, "actions")
2669
2678
  ]),
@@ -2741,7 +2750,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2741
2750
  key: 0,
2742
2751
  mode: "icon",
2743
2752
  size: "small",
2744
- icon: n(vn),
2753
+ icon: n(gn),
2745
2754
  background: "hover",
2746
2755
  dropdown: {
2747
2756
  size: "small",
@@ -2776,7 +2785,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2776
2785
  }), Iu = {
2777
2786
  key: 2,
2778
2787
  class: "v-item__index"
2779
- }, Ou = { class: "v-item__title-wrapper" }, ju = { class: "v-item__content" }, Du = {
2788
+ }, ju = { class: "v-item__title-wrapper" }, Ou = { class: "v-item__content" }, Du = {
2780
2789
  key: 3,
2781
2790
  class: "v-item__tags"
2782
2791
  }, He = /* @__PURE__ */ $({
@@ -2908,7 +2917,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2908
2917
  key: 0,
2909
2918
  icon: g.icon
2910
2919
  }, null, 8, ["icon"])) : I("", !0),
2911
- s.tag ? (u(), y(n(Os), {
2920
+ s.tag ? (u(), y(n(js), {
2912
2921
  key: 1,
2913
2922
  class: "v-item__tag",
2914
2923
  size: "small",
@@ -2920,8 +2929,8 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2920
2929
  _: 1
2921
2930
  }, 8, ["type"])) : I("", !0),
2922
2931
  g.index !== void 0 ? (u(), R("span", Iu, " # " + ne(g.index), 1)) : I("", !0),
2923
- T("div", Ou, [
2924
- T("span", ju, ne(g.title), 1),
2932
+ T("div", ju, [
2933
+ T("span", Ou, ne(g.title), 1),
2925
2934
  g.subtitle ? (u(), R("span", {
2926
2935
  key: 0,
2927
2936
  class: pe(["v-item__subtitle", s.subtitleCls])
@@ -2969,7 +2978,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
2969
2978
  }),
2970
2979
  s.actionInMore ? (u(), y(n(Ve), {
2971
2980
  key: 0,
2972
- icon: n(vn),
2981
+ icon: n(gn),
2973
2982
  mode: "icon",
2974
2983
  size: "small",
2975
2984
  background: "none",
@@ -3060,7 +3069,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3060
3069
  }, {
3061
3070
  default: h(() => [
3062
3071
  p(n(Ve), {
3063
- icon: n(vn),
3072
+ icon: n(gn),
3064
3073
  mode: "icon",
3065
3074
  size: "small",
3066
3075
  background: "none",
@@ -3100,7 +3109,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3100
3109
  type: ms(w),
3101
3110
  path: `${f}${_}`
3102
3111
  };
3103
- }) : Oc(b).map((w) => {
3112
+ }) : jc(b).map((w) => {
3104
3113
  const k = b[w];
3105
3114
  return {
3106
3115
  label: w,
@@ -3129,7 +3138,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3129
3138
  "onUpdate:modelValue": f[0] || (f[0] = (x) => i.value = x),
3130
3139
  size: "small",
3131
3140
  clearable: "",
3132
- "prefix-icon": n(nn),
3141
+ "prefix-icon": n(sn),
3133
3142
  placeholder: "筛选可用项"
3134
3143
  }, null, 8, ["modelValue", "prefix-icon"]),
3135
3144
  T("div", Lu, [
@@ -3139,7 +3148,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3139
3148
  ])),
3140
3149
  _: 1
3141
3150
  }),
3142
- b.context ? (u(), y(n(js), {
3151
+ b.context ? (u(), y(n(Os), {
3143
3152
  key: 0,
3144
3153
  ref_key: "treeRef",
3145
3154
  ref: a,
@@ -3257,13 +3266,13 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3257
3266
  flex: !1
3258
3267
  }, {
3259
3268
  default: h(() => [
3260
- jt(T("div", null, [
3269
+ Ot(T("div", null, [
3261
3270
  p(n(Me), {
3262
3271
  modelValue: n(i),
3263
3272
  "onUpdate:modelValue": _[0] || (_[0] = (A) => Mn(i) ? i.value = A : null),
3264
3273
  size: "small",
3265
3274
  clearable: "",
3266
- "prefix-icon": n(nn),
3275
+ "prefix-icon": n(sn),
3267
3276
  placeholder: "筛选可用项"
3268
3277
  }, null, 8, ["modelValue", "prefix-icon"]),
3269
3278
  (u(!0), R(q, null, se(n(o), (A) => (u(), R("div", null, [
@@ -3278,20 +3287,20 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3278
3287
  background: "",
3279
3288
  actions: ["copy"],
3280
3289
  small: "",
3281
- onClick: (O) => x(E),
3282
- onAction: (O) => w(E)
3290
+ onClick: (j) => x(E),
3291
+ onAction: (j) => w(E)
3283
3292
  }, null, 8, ["title", "onClick", "onAction"]))), 256))
3284
3293
  ]))), 256)),
3285
3294
  n(o).length ? I("", !0) : (u(), y(n(De), { key: 0 }))
3286
3295
  ], 512), [
3287
- [Yt, c.value === "normal"]
3296
+ [Zt, c.value === "normal"]
3288
3297
  ]),
3289
- jt(p(Uu, {
3298
+ Ot(p(Uu, {
3290
3299
  context: e.context,
3291
3300
  onCopy: w,
3292
3301
  onPick: x
3293
3302
  }, null, 8, ["context"]), [
3294
- [Yt, c.value === "viewer"]
3303
+ [Zt, c.value === "viewer"]
3295
3304
  ])
3296
3305
  ]),
3297
3306
  _: 1
@@ -3464,7 +3473,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3464
3473
  });
3465
3474
  return (a, l) => (u(), R("div", {
3466
3475
  class: pe(["v-viewport", e.value]),
3467
- style: rn(i.value)
3476
+ style: cn(i.value)
3468
3477
  }, [
3469
3478
  At(a.$slots, "default")
3470
3479
  ], 6));
@@ -3488,7 +3497,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3488
3497
  name: "PagesWidget",
3489
3498
  __name: "index",
3490
3499
  setup(r) {
3491
- const { project: t, engine: e } = sn(), s = V(() => t.value?.pages || []), { current: o } = Qe(), i = C(!1), a = C(), l = C(), c = V(() => `(共 ${s.value.length} 项)`), d = V(() => {
3500
+ const { project: t, engine: e } = on(), s = V(() => t.value?.pages || []), { current: o } = Qe(), i = C(!1), a = C(), l = C(), c = V(() => `(共 ${s.value.length} 项)`), d = V(() => {
3492
3501
  const { platform: w = "web" } = t.value || {};
3493
3502
  return w === "uniapp";
3494
3503
  }), v = (w) => {
@@ -3498,10 +3507,10 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3498
3507
  l.value = void 0, a.value = void 0, i.value = !0;
3499
3508
  }, g = async (w) => {
3500
3509
  const { name: k, modelValue: _ } = w, { data: A, node: E } = _;
3501
- if (k === "add" && (a.value = void 0, l.value = A.id, i.value = !0), k === "edit" && (a.value = Cn(A), l.value = void 0, i.value = !0), k === "remove") {
3510
+ if (k === "add" && (a.value = void 0, l.value = A.id, i.value = !0), k === "edit" && (a.value = En(A), l.value = void 0, i.value = !0), k === "remove") {
3502
3511
  if (A.dir) {
3503
- const O = t.value?.getPage(A.id);
3504
- if (O && O.children?.length) {
3512
+ const j = t.value?.getPage(A.id);
3513
+ if (j && j.children?.length) {
3505
3514
  xe("请先删除子页面");
3506
3515
  return;
3507
3516
  }
@@ -3509,8 +3518,8 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3509
3518
  t.value?.removePage(A.id);
3510
3519
  }
3511
3520
  if (k === "copy") {
3512
- const O = E.parent?.data.id;
3513
- t.value?.clonePage(A, O);
3521
+ const j = E.parent?.data.id;
3522
+ t.value?.clonePage(A, j);
3514
3523
  }
3515
3524
  k === "home" && (t.value?.setHomepage(A.id), Ne("设置主页成功", "success")), k === "saveToBlock" && (await t.value?.saveToBlock(A), Ne("已保存到区块", "success"));
3516
3525
  }, b = async (w) => {
@@ -3534,7 +3543,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3534
3543
  onPlus: m
3535
3544
  }, {
3536
3545
  default: h(() => [
3537
- p(n(js), {
3546
+ p(n(Os), {
3538
3547
  data: s.value,
3539
3548
  "node-key": "id",
3540
3549
  "default-expand-all": "",
@@ -3583,7 +3592,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3583
3592
  },
3584
3593
  emits: ["change", "update:modelValue"],
3585
3594
  setup(r, { emit: t }) {
3586
- const e = r, s = t, { engine: o, project: i } = sn(), a = C([]), l = C(!1), c = (_) => Array.isArray(_) ? _.map((A) => ({
3595
+ const e = r, s = t, { engine: o, project: i } = on(), a = C([]), l = C(!1), c = (_) => Array.isArray(_) ? _.map((A) => ({
3587
3596
  name: A.filename,
3588
3597
  url: A.filepath
3589
3598
  })) : _ ? { name: _.filename, url: _.filepath } : null, d = async (_) => {
@@ -3610,8 +3619,8 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3610
3619
  if (!m.value || Array.isArray(m.value) && m.value.length === 0)
3611
3620
  return xe("请选择文件"), !1;
3612
3621
  const _ = (e.attachment?.accept || "").toLowerCase().split(",");
3613
- return _.length > 0 ? [].concat(m.value).every((O) => {
3614
- const j = O.name || O.url.split("?")[0], B = j.substring(j.lastIndexOf(".")).toLowerCase();
3622
+ return _.length > 0 ? [].concat(m.value).every((j) => {
3623
+ const O = j.name || j.url.split("?")[0], B = O.substring(O.lastIndexOf(".")).toLowerCase();
3615
3624
  return _.includes(B);
3616
3625
  }) ? !0 : (xe(`只支持 ${_.join(",")} 文件`), !1) : !0;
3617
3626
  }, f = () => {
@@ -3674,7 +3683,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3674
3683
  __name: "index",
3675
3684
  setup(r) {
3676
3685
  const { span: t } = Us(), { blocks: e, engine: s } = wc(), o = C(""), i = V(() => o.value ? e.value.filter((P) => P.name.includes(o.value) || P.title?.includes(o.value)) : e.value), a = V(
3677
- () => wn(i.value, (P) => P.category || "默认分组")
3686
+ () => kn(i.value, (P) => P.category || "默认分组")
3678
3687
  ), l = V(() => Object.keys(a.value)), c = {
3679
3688
  filterable: !0,
3680
3689
  allowCreate: !0,
@@ -3736,10 +3745,10 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3736
3745
  else
3737
3746
  return xe(`名称【${te.name}】已经存在,请更换名称`), !1;
3738
3747
  return !0;
3739
- }, O = () => {
3748
+ }, j = () => {
3740
3749
  g.value = k(), f.value = !0;
3741
- }, j = (P) => {
3742
- g.value = Cn(P), f.value = !0;
3750
+ }, O = (P) => {
3751
+ g.value = En(P), f.value = !0;
3743
3752
  }, B = (P) => {
3744
3753
  s.project.value?.cloneBlock(P);
3745
3754
  }, N = (P) => {
@@ -3764,7 +3773,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3764
3773
  title: "区块管理",
3765
3774
  subtitle: w.value,
3766
3775
  plus: "",
3767
- onPlus: O
3776
+ onPlus: j
3768
3777
  }, {
3769
3778
  default: h(() => [
3770
3779
  T("div", qu, [
@@ -3772,7 +3781,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3772
3781
  size: "small",
3773
3782
  modelValue: o.value,
3774
3783
  "onUpdate:modelValue": te[0] || (te[0] = (ue) => o.value = ue),
3775
- "prefix-icon": n(nn),
3784
+ "prefix-icon": n(sn),
3776
3785
  placeholder: "搜索区块",
3777
3786
  clearable: ""
3778
3787
  }, null, 8, ["modelValue", "prefix-icon"])
@@ -3804,7 +3813,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
3804
3813
  editable: !_e.preset,
3805
3814
  tag: m[_e.fromType || "Schema"]?.label,
3806
3815
  tagType: m[_e.fromType || "Schema"]?.type,
3807
- onEdit: (be) => j(_e),
3816
+ onEdit: (be) => O(_e),
3808
3817
  onCopy: (be) => B(_e),
3809
3818
  onRemove: (be) => N(_e),
3810
3819
  onClick: (be) => z(_e),
@@ -4011,16 +4020,16 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4011
4020
  name: "OutlineWidget",
4012
4021
  __name: "index",
4013
4022
  setup(r) {
4014
- const { engine: t, designer: e, selected: s } = St(), { current: o } = Qe(), i = C([]), a = (j, B) => {
4023
+ const { engine: t, designer: e, selected: s } = St(), { current: o } = Qe(), i = C([]), a = (O, B) => {
4015
4024
  if (B === "slot") return [];
4016
- if (Te(j))
4017
- return j.locked ? ["unlock"] : ["lock"];
4018
- const N = j.parent;
4019
- return N && (N.locked || N.invisible) ? [] : o.value?.locked ? [] : j.locked ? ["unlock"] : j.invisible ? ["visible"] : ["lock", "invisible", "copy", "remove"];
4020
- }, l = (j, B) => {
4025
+ if (Te(O))
4026
+ return O.locked ? ["unlock"] : ["lock"];
4027
+ const N = O.parent;
4028
+ return N && (N.locked || N.invisible) ? [] : o.value?.locked ? [] : O.locked ? ["unlock"] : O.invisible ? ["visible"] : ["lock", "invisible", "copy", "remove"];
4029
+ }, l = (O, B) => {
4021
4030
  const N = {};
4022
- if (!j.some((D) => D.slot)) return c(j);
4023
- for (const D of j) {
4031
+ if (!O.some((D) => D.slot)) return c(O);
4032
+ for (const D of O) {
4024
4033
  const L = D.slot?.name || "default";
4025
4034
  N[L] || (N[L] = []), N[L].push(D);
4026
4035
  }
@@ -4035,9 +4044,9 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4035
4044
  children: c(L)
4036
4045
  });
4037
4046
  return z;
4038
- }, c = (j) => {
4047
+ }, c = (O) => {
4039
4048
  const B = [];
4040
- return j.forEach((N) => {
4049
+ return O.forEach((N) => {
4041
4050
  const W = {
4042
4051
  id: N.id,
4043
4052
  label: N.name,
@@ -4049,25 +4058,25 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4049
4058
  }), B;
4050
4059
  }, d = () => {
4051
4060
  if (!o.value) return [];
4052
- const { id: j, name: B, nodes: N } = o.value;
4061
+ const { id: O, name: B, nodes: N } = o.value;
4053
4062
  return [
4054
4063
  {
4055
- id: j,
4064
+ id: O,
4056
4065
  label: B,
4057
- type: j,
4066
+ type: O,
4058
4067
  model: o.value,
4059
4068
  children: c(N)
4060
4069
  }
4061
4070
  ];
4062
4071
  }, v = async () => {
4063
4072
  i.value = d(), s.value?.model && (await at(), e.value?.setSelected(s.value.model));
4064
- }, m = V(() => s.value?.model.id), g = (j) => {
4065
- const B = j.data;
4073
+ }, m = V(() => s.value?.model.id), g = (O) => {
4074
+ const B = O.data;
4066
4075
  if (B.type === "slot" || Te(B.model) || B.model.locked || B.model.name === "template")
4067
4076
  return !1;
4068
4077
  const N = t.assets.componentMap.get(B.model.name);
4069
4078
  return N ? (e.value?.setDragging(N), !0) : !1;
4070
- }, b = async (j, B, N) => {
4079
+ }, b = async (O, B, N) => {
4071
4080
  const W = B.data, D = {
4072
4081
  prev: "top",
4073
4082
  next: "bottom",
@@ -4081,15 +4090,15 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4081
4090
  L = !!await e.value?.allowDrop(P, D), e.value?.setDropping(L ? P : null, "inner");
4082
4091
  }
4083
4092
  return L;
4084
- }, f = (j) => {
4085
- const B = j?.model;
4086
- if (!B || B.invisible || j.type === "slot") {
4093
+ }, f = (O) => {
4094
+ const B = O?.model;
4095
+ if (!B || B.invisible || O.type === "slot") {
4087
4096
  e.value?.setSelected(null), e.value?.setHover(null);
4088
4097
  return;
4089
4098
  }
4090
4099
  e.value?.setSelected(B), e.value?.setHover(null);
4091
- }, x = async (j, B, N) => {
4092
- const W = j.data, z = B.data;
4100
+ }, x = async (O, B, N) => {
4101
+ const W = O.data, z = B.data;
4093
4102
  if (Te(z.model)) {
4094
4103
  const ue = W.model;
4095
4104
  delete ue.slot, o.value?.move(ue, void 0, "inner"), e.value?.setDropping(null), e.value?.setDragging(null);
@@ -4114,26 +4123,26 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4114
4123
  } else
4115
4124
  v();
4116
4125
  e.value?.setDropping(null), e.value?.setDragging(null), t.simulator.refresh();
4117
- }, w = (j) => {
4118
- if (j.type === "slot") {
4126
+ }, w = (O) => {
4127
+ if (O.type === "slot") {
4119
4128
  e.value?.setHover(null);
4120
4129
  return;
4121
4130
  }
4122
- Te(j.model) ? e.value?.setHover(j.model) : (e.value?.setHover(j.model), j.model.invisible && e.value?.setHover(null), j.model.name === "slot" && e.value?.setHover(null));
4131
+ Te(O.model) ? e.value?.setHover(O.model) : (e.value?.setHover(O.model), O.model.invisible && e.value?.setHover(null), O.model.name === "slot" && e.value?.setHover(null));
4123
4132
  }, k = () => {
4124
4133
  e.value?.setHover(null);
4125
- }, _ = (j) => {
4126
- const B = j.data;
4134
+ }, _ = (O) => {
4135
+ const B = O.data;
4127
4136
  B.dragging = !0;
4128
4137
  const N = t.assets.componentMap.get(B.model.name);
4129
4138
  N && e.value?.setDragging(N);
4130
- }, A = async (j) => {
4131
- const B = j.data;
4139
+ }, A = async (O) => {
4140
+ const B = O.data;
4132
4141
  B.dragging = !1;
4133
- }, E = (j, B) => {
4134
- j && ((j.id === B.id || !Te(j) && B.isChild(j)) && e.value?.setSelected(null), e.value?.setHover(null));
4135
- }, O = (j) => {
4136
- const { name: B, modelValue: N } = j, W = s.value?.model;
4142
+ }, E = (O, B) => {
4143
+ O && ((O.id === B.id || !Te(O) && B.isChild(O)) && e.value?.setSelected(null), e.value?.setHover(null));
4144
+ }, j = (O) => {
4145
+ const { name: B, modelValue: N } = O, W = s.value?.model;
4137
4146
  switch (B) {
4138
4147
  case "lock":
4139
4148
  E(W, N), N.lock();
@@ -4156,12 +4165,12 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4156
4165
  break;
4157
4166
  }
4158
4167
  };
4159
- return Z(t.changed, v, { immediate: !0 }), (j, B) => (u(), y(n(ce), {
4168
+ return Z(t.changed, v, { immediate: !0 }), (O, B) => (u(), y(n(ce), {
4160
4169
  class: "v-outline-widget",
4161
4170
  title: "大纲树"
4162
4171
  }, {
4163
4172
  default: h(() => [
4164
- (u(), y(n(js), {
4173
+ (u(), y(n(Os), {
4165
4174
  key: n(t).changed.value,
4166
4175
  data: i.value,
4167
4176
  "node-key": "id",
@@ -4196,7 +4205,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4196
4205
  title: N.label,
4197
4206
  subtitle: N.type,
4198
4207
  actions: a(N.model, N.type),
4199
- onAction: O,
4208
+ onAction: j,
4200
4209
  onMouseenter: (z) => w(N),
4201
4210
  onMouseleave: k
4202
4211
  }, null, 8, ["class", "active", "model-value", "icon", "title", "subtitle", "actions", "onMouseenter"])
@@ -4489,7 +4498,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4489
4498
  t.model ? [a.value.id] : []
4490
4499
  ) ? (xe(`API名称 [ ${a.value.name} ] 已存在`), !1) : a.value.headers && !Xe(a.value.headers, window) || a.value.mockTemplate && !Xe(a.value.mockTemplate, window) ? !1 : (t.project?.setApi(a.value), o.value?.close(), !0), f = () => {
4491
4500
  if (a.value.mockTemplate) {
4492
- const x = Sn(
4501
+ const x = xn(
4493
4502
  a.value.mockTemplate,
4494
4503
  {},
4495
4504
  !0
@@ -4584,8 +4593,8 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4584
4593
  submitMethod: b
4585
4594
  }, {
4586
4595
  default: h(() => [
4587
- jt(p(nd, { categories: x.categories }, null, 8, ["categories"]), [
4588
- [Yt, s.value === "base"]
4596
+ Ot(p(nd, { categories: x.categories }, null, 8, ["categories"]), [
4597
+ [Zt, s.value === "base"]
4589
4598
  ]),
4590
4599
  s.value === "settings" ? (u(), R("div", ld, [
4591
4600
  v.value ? (u(), y(od, { key: 0 })) : (u(), y(sd, { key: 1 }))
@@ -4629,11 +4638,11 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4629
4638
  name: "ApisWidget",
4630
4639
  __name: "index",
4631
4640
  setup(r) {
4632
- const { project: t } = sn(), e = C(!1), s = C(null), o = C(""), i = C(!1), a = V(() => {
4641
+ const { project: t } = on(), e = C(!1), s = C(null), o = C(""), i = C(!1), a = V(() => {
4633
4642
  const x = t.value?.apis || [];
4634
4643
  return o.value ? x.filter((w) => w.name.includes(o.value) || w.label?.includes(o.value) || w.url.includes(o.value)) : x;
4635
4644
  }), l = V(
4636
- () => wn(a.value, (x) => x.category || "默认分组")
4645
+ () => kn(a.value, (x) => x.category || "默认分组")
4637
4646
  ), c = V(() => Object.keys(l.value)), d = V(() => c.value[0]), v = () => ({
4638
4647
  id: "",
4639
4648
  method: "get",
@@ -4675,7 +4684,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4675
4684
  }, b = (x) => {
4676
4685
  x.name === "edit" && f(x.modelValue), x.name === "remove" && t.value?.removeApi(x.modelValue.name);
4677
4686
  }, f = (x) => {
4678
- i.value = !0, s.value = Cn(x), e.value = !0;
4687
+ i.value = !0, s.value = En(x), e.value = !0;
4679
4688
  };
4680
4689
  return (x, w) => (u(), y(n(ce), {
4681
4690
  class: "v-apis-widget",
@@ -4689,7 +4698,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4689
4698
  size: "small",
4690
4699
  modelValue: o.value,
4691
4700
  "onUpdate:modelValue": w[0] || (w[0] = (k) => o.value = k),
4692
- "prefix-icon": n(nn),
4701
+ "prefix-icon": n(sn),
4693
4702
  placeholder: "搜索API",
4694
4703
  clearable: ""
4695
4704
  }, null, 8, ["modelValue", "prefix-icon"])
@@ -4920,14 +4929,14 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4920
4929
  inheritAttrs: !1,
4921
4930
  __name: "index",
4922
4931
  setup(r, { expose: t }) {
4923
- const e = C(), s = C(), { width: o, height: i } = mn(e), { dependencies: a, engine: l, apis: c, meta: d } = pa(), { current: v, isEmpty: m } = Qe(), g = V(() => l.skeleton?.getWidget("Toolbar")?.widgetRef.mode ?? "pc"), b = V(() => l.skeleton?.getWidget("Toolbar")?.widgetRef.customSize), f = V(() => !!l.skeleton?.getWidget("Toolbar")?.widgetRef.outline), x = V(() => l.project.value?.config || {}), w = V(() => l.project.value?.uniConfig || {}), { designer: k, hover: _, dropping: A, selected: E, lines: O } = Cc(
4932
+ const e = C(), s = C(), { width: o, height: i } = vn(e), { dependencies: a, engine: l, apis: c, meta: d } = pa(), { current: v, isEmpty: m } = Qe(), g = V(() => l.skeleton?.getWidget("Toolbar")?.widgetRef.mode ?? "pc"), b = V(() => l.skeleton?.getWidget("Toolbar")?.widgetRef.customSize), f = V(() => !!l.skeleton?.getWidget("Toolbar")?.widgetRef.outline), x = V(() => l.project.value?.config || {}), w = V(() => l.project.value?.uniConfig || {}), { designer: k, hover: _, dropping: A, selected: E, lines: j } = Cc(
4924
4933
  s,
4925
4934
  a,
4926
4935
  c,
4927
4936
  d,
4928
4937
  x,
4929
4938
  w
4930
- ), j = (W) => {
4939
+ ), O = (W) => {
4931
4940
  const z = W.type, D = W.model;
4932
4941
  if (v.value)
4933
4942
  switch (z) {
@@ -4979,12 +4988,12 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4979
4988
  n(A) ? (u(), R("div", {
4980
4989
  key: 0,
4981
4990
  class: pe(["v-designer__dropping", "is-inner"]),
4982
- style: rn(n(A).style)
4991
+ style: cn(n(A).style)
4983
4992
  }, null, 4)) : I("", !0),
4984
4993
  n(_) ? (u(), R("div", {
4985
4994
  key: 1,
4986
4995
  class: "v-designer__hover",
4987
- style: rn(n(_).style)
4996
+ style: cn(n(_).style)
4988
4997
  }, [
4989
4998
  T("span", {
4990
4999
  class: pe(`is-${n(_).position}`)
@@ -4996,13 +5005,13 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
4996
5005
  n(E) ? (u(), R("div", {
4997
5006
  key: 2,
4998
5007
  class: "v-designer__selected",
4999
- style: rn(n(E).style)
5008
+ style: cn(n(E).style)
5000
5009
  }, [
5001
5010
  p(dd, {
5002
5011
  position: n(E).position,
5003
5012
  model: n(E).model,
5004
5013
  path: n(E).path,
5005
- onAction: j,
5014
+ onAction: O,
5006
5015
  onDragstart: B,
5007
5016
  onDragend: N
5008
5017
  }, null, 8, ["position", "model", "path"])
@@ -5011,9 +5020,9 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5011
5020
  key: 3,
5012
5021
  description: "请新建或打开文件"
5013
5022
  })),
5014
- f.value && n(O).length ? (u(), R("div", pd, [
5015
- (u(!0), R(q, null, se(n(O), (D) => (u(), R("div", {
5016
- style: rn(D)
5023
+ f.value && n(j).length ? (u(), R("div", pd, [
5024
+ (u(!0), R(q, null, se(n(j), (D) => (u(), R("div", {
5025
+ style: cn(D)
5017
5026
  }, null, 4))), 256))
5018
5027
  ])) : I("", !0),
5019
5028
  n(v) && n(m) ? (u(), R("div", md, " 您可以拖拽组件放置到这里 ")) : I("", !0),
@@ -5027,7 +5036,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5027
5036
  }, 8, ["mode", "width", "height", "customSize"])
5028
5037
  ], 512));
5029
5038
  }
5030
- }), En = /* @__PURE__ */ $({
5039
+ }), An = /* @__PURE__ */ $({
5031
5040
  __name: "group",
5032
5041
  props: {
5033
5042
  context: {},
@@ -5138,7 +5147,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5138
5147
  current: {}
5139
5148
  },
5140
5149
  setup(r) {
5141
- const t = r, e = V(() => Object.entries(t.current?.state || {}).map(([l, c]) => ({ name: l, value: pn(c) }))), s = () => ({
5150
+ const t = r, e = V(() => Object.entries(t.current?.state || {}).map(([l, c]) => ({ name: l, value: mn(c) }))), s = () => ({
5142
5151
  name: "",
5143
5152
  value: ""
5144
5153
  }), o = (a) => t.current?.removeState(a.name), i = async (a, l) => {
@@ -5151,7 +5160,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5151
5160
  };
5152
5161
  return Xe(v, t.context, !0) ? (t.current?.setState(c, v), !0) : !1;
5153
5162
  };
5154
- return (a, l) => (u(), y(En, {
5163
+ return (a, l) => (u(), y(An, {
5155
5164
  title: "状态数据",
5156
5165
  current: t.current,
5157
5166
  context: t.context,
@@ -5170,7 +5179,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5170
5179
  current: {}
5171
5180
  },
5172
5181
  setup(r) {
5173
- const t = r, e = V(() => Object.entries(t.current?.computed || {}).map(([l, c]) => ({ name: l, value: pn(c) }))), s = () => ({
5182
+ const t = r, e = V(() => Object.entries(t.current?.computed || {}).map(([l, c]) => ({ name: l, value: mn(c) }))), s = () => ({
5174
5183
  name: "",
5175
5184
  value: "() => { }"
5176
5185
  }), o = (a) => t.current?.removeFunction("computed", a.name), i = async (a, l) => {
@@ -5183,7 +5192,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5183
5192
  };
5184
5193
  return Xe(v, t.context, !0) ? (t.current?.setFunction("computed", c, v), !0) : !1;
5185
5194
  };
5186
- return (a, l) => (u(), y(En, {
5195
+ return (a, l) => (u(), y(An, {
5187
5196
  title: "计算属性",
5188
5197
  current: t.current,
5189
5198
  context: t.context,
@@ -5202,7 +5211,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5202
5211
  current: {}
5203
5212
  },
5204
5213
  setup(r) {
5205
- const t = r, e = V(() => Object.entries(t.current?.methods || {}).map(([l, c]) => ({ name: l, value: pn(c) }))), s = () => ({
5214
+ const t = r, e = V(() => Object.entries(t.current?.methods || {}).map(([l, c]) => ({ name: l, value: mn(c) }))), s = () => ({
5206
5215
  name: "",
5207
5216
  value: "() => { }"
5208
5217
  }), o = (a) => t.current?.removeFunction("methods", a.name), i = async (a, l) => {
@@ -5215,7 +5224,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5215
5224
  };
5216
5225
  return Xe(v, t.context, !0) ? (t.current?.setFunction("methods", c, v), !0) : !1;
5217
5226
  };
5218
- return (a, l) => (u(), y(En, {
5227
+ return (a, l) => (u(), y(An, {
5219
5228
  title: "组件方法",
5220
5229
  current: t.current,
5221
5230
  context: t.context,
@@ -5240,7 +5249,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5240
5249
  label: v,
5241
5250
  value: v
5242
5251
  }));
5243
- }), o = V(() => Object.entries(e.current?.lifeCycles || {}).map(([d, v]) => ({ name: d, value: pn(v) }))), i = () => ({
5252
+ }), o = V(() => Object.entries(e.current?.lifeCycles || {}).map(([d, v]) => ({ name: d, value: mn(v) }))), i = () => ({
5244
5253
  name: "",
5245
5254
  value: "() => { }"
5246
5255
  }), a = (c) => e.current?.removeFunction("lifeCycles", c.name), l = async (c, d) => {
@@ -5253,7 +5262,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5253
5262
  };
5254
5263
  return Xe(g, e.context, !0) ? (e.current?.setFunction("lifeCycles", v, g), !0) : !1;
5255
5264
  };
5256
- return (c, d) => (u(), y(En, {
5265
+ return (c, d) => (u(), y(An, {
5257
5266
  title: "生命周期",
5258
5267
  current: e.current,
5259
5268
  context: e.context,
@@ -5303,8 +5312,8 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5303
5312
  setup(r) {
5304
5313
  const t = r, e = V(() => (t.current?.watch || []).map((l) => ({
5305
5314
  ...l,
5306
- source: pn(l.source),
5307
- handler: pn(l.handler)
5315
+ source: mn(l.source),
5316
+ handler: mn(l.handler)
5308
5317
  }))), s = () => ({
5309
5318
  source: "() => { }",
5310
5319
  deep: !1,
@@ -5327,7 +5336,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5327
5336
  };
5328
5337
  return t.current?.setWatch(m), !0;
5329
5338
  };
5330
- return (l, c) => (u(), y(En, {
5339
+ return (l, c) => (u(), y(An, {
5331
5340
  title: "侦听器",
5332
5341
  current: t.current,
5333
5342
  context: t.context,
@@ -5676,11 +5685,11 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5676
5685
  name: "EventsWidget",
5677
5686
  __name: "index",
5678
5687
  setup(r) {
5679
- const { current: t, context: e } = Qe(), { selected: s } = St(), { mouseEventList: o, keyboardEventList: i, componentEventList: a } = jc(s), l = C({
5688
+ const { current: t, context: e } = Qe(), { selected: s } = St(), { mouseEventList: o, keyboardEventList: i, componentEventList: a } = Oc(s), l = C({
5680
5689
  name: "",
5681
5690
  event: void 0
5682
5691
  }), c = C(!1), d = (f) => {
5683
- l.value = Cn(f), c.value = !0;
5692
+ l.value = En(f), c.value = !0;
5684
5693
  }, v = async (f) => {
5685
5694
  const x = {
5686
5695
  ...f,
@@ -5836,7 +5845,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5836
5845
  onAddCustom: f,
5837
5846
  onRemoveCustom: x,
5838
5847
  onCustomChange: w
5839
- } = Nc(s), k = (_) => _.arg ? typeof _.arg == "string" ? _.arg : Sn(_.arg, {}) : "modelValue";
5848
+ } = Nc(s), k = (_) => _.arg ? typeof _.arg == "string" ? _.arg : xn(_.arg, {}) : "modelValue";
5840
5849
  return (_, A) => (u(), y(n(de), {
5841
5850
  class: "v-directives-widget",
5842
5851
  direction: "column",
@@ -5959,7 +5968,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5959
5968
  fit: !1
5960
5969
  }, {
5961
5970
  default: h(() => [
5962
- (u(!0), R(q, null, se(n(d), (E, O) => (u(), y(n(ce), {
5971
+ (u(!0), R(q, null, se(n(d), (E, j) => (u(), y(n(ce), {
5963
5972
  card: "",
5964
5973
  border: "",
5965
5974
  class: "v-sub-panel",
@@ -5977,7 +5986,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
5977
5986
  }, {
5978
5987
  default: h(() => [
5979
5988
  p(n(re), {
5980
- name: O.toString(),
5989
+ name: j.toString(),
5981
5990
  label: "绑定变量",
5982
5991
  setters: "ExpressionSetter",
5983
5992
  current: n(t),
@@ -6009,17 +6018,17 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6009
6018
  onPlus: n(f)
6010
6019
  }, {
6011
6020
  default: h(() => [
6012
- (u(!0), R(q, null, se(n(v), (E, O) => (u(), y(n(ce), {
6021
+ (u(!0), R(q, null, se(n(v), (E, j) => (u(), y(n(ce), {
6013
6022
  key: E.id,
6014
6023
  card: "",
6015
6024
  border: "",
6016
6025
  class: "v-sub-panel",
6017
6026
  size: "small",
6018
- title: `# ${O + 1}`,
6027
+ title: `# ${j + 1}`,
6019
6028
  body: { grow: !1 },
6020
6029
  fit: !1,
6021
6030
  remove: !0,
6022
- onRemove: (j) => n(x)(E)
6031
+ onRemove: (O) => n(x)(E)
6023
6032
  }, {
6024
6033
  default: h(() => [
6025
6034
  p(n(Ze), {
@@ -6345,13 +6354,13 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6345
6354
  }, E = (D) => {
6346
6355
  const { name: L, modelValue: P } = D;
6347
6356
  L === "edit" && A(P), L === "remove" && t.value?.removeEmit(P.name);
6348
- }, O = () => {
6357
+ }, j = () => {
6349
6358
  g.value = void 0, m.value = !0;
6350
- }, j = (D) => {
6359
+ }, O = (D) => {
6351
6360
  g.value = { ...D }, m.value = !0;
6352
6361
  }, B = (D) => {
6353
6362
  const { name: L, modelValue: P } = D;
6354
- L === "edit" && j(P), L === "remove" && t.value?.removeSlot(P.name);
6363
+ L === "edit" && O(P), L === "remove" && t.value?.removeSlot(P.name);
6355
6364
  }, N = () => {
6356
6365
  f.value = void 0, b.value = !0;
6357
6366
  }, W = (D) => {
@@ -6437,7 +6446,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6437
6446
  size: "small",
6438
6447
  plus: "",
6439
6448
  fit: !1,
6440
- onPlus: O
6449
+ onPlus: j
6441
6450
  }, {
6442
6451
  default: h(() => [
6443
6452
  (u(!0), R(q, null, se(i.value, (P) => (u(), y(n(He), {
@@ -6445,7 +6454,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6445
6454
  title: P.name,
6446
6455
  border: "",
6447
6456
  actions: ["remove"],
6448
- onClick: (te) => j(P),
6457
+ onClick: (te) => O(P),
6449
6458
  onAction: B
6450
6459
  }, null, 8, ["model-value", "title", "onClick"]))), 256)),
6451
6460
  i.value.length ? I("", !0) : (u(), y(n(De), {
@@ -6500,7 +6509,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6500
6509
  _: 1
6501
6510
  })) : I("", !0);
6502
6511
  }
6503
- }), Od = /* @__PURE__ */ $({
6512
+ }), jd = /* @__PURE__ */ $({
6504
6513
  name: "DataSourceDialogForm",
6505
6514
  __name: "form",
6506
6515
  props: {
@@ -6555,7 +6564,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6555
6564
  return {};
6556
6565
  }`
6557
6566
  }
6558
- }, Cn(t.item))
6567
+ }, En(t.item))
6559
6568
  ), d = C(!1), v = C(""), m = C(!1), g = V(() => c.value.type === "api" ? s.value.map((E) => ({
6560
6569
  label: E.label || "",
6561
6570
  value: E.id,
@@ -6572,25 +6581,25 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6572
6581
  }`);
6573
6582
  }, k = (E) => {
6574
6583
  if (c.value.type === "api") {
6575
- const O = s.value.find((j) => j.id === E);
6576
- O && (c.value.name = O.name, c.value.label = O.label || "");
6584
+ const j = s.value.find((O) => O.id === E);
6585
+ j && (c.value.name = j.name, c.value.label = j.label || "");
6577
6586
  }
6578
6587
  if (c.value.type === "meta") {
6579
- const O = o.value.find((j) => j.id === E);
6580
- O && (c.value.name = O.code, c.value.label = O.title || "");
6588
+ const j = o.value.find((O) => O.id === E);
6589
+ j && (c.value.name = j.code, c.value.label = j.title || "");
6581
6590
  }
6582
6591
  }, _ = async (E) => {
6583
- const { transform: O, test: j, name: B } = E;
6592
+ const { transform: j, test: O, name: B } = E;
6584
6593
  if (!t.current) return !1;
6585
6594
  if (!t.item && t.current.dataSources[B])
6586
6595
  return xe(`名称【${B}】已经存在,请更换名称`), !1;
6587
- if (O?.value) {
6588
- if (!Xe(O, t.context, !0))
6596
+ if (j?.value) {
6597
+ if (!Xe(j, t.context, !0))
6589
6598
  return !1;
6590
6599
  } else
6591
6600
  E.transform = void 0;
6592
- if (j?.value) {
6593
- if (!Xe(j, t.context, !0))
6601
+ if (O?.value) {
6602
+ if (!Xe(O, t.context, !0))
6594
6603
  return !1;
6595
6604
  } else
6596
6605
  E.test = void 0;
@@ -6607,7 +6616,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6607
6616
  }
6608
6617
  if (!Xe(c.value.test, t.context, !0))
6609
6618
  return;
6610
- const O = async (...N) => {
6619
+ const j = async (...N) => {
6611
6620
  if (c.value.type === "mock") {
6612
6621
  const W = Zl(c.value);
6613
6622
  return await W.apply(W, N);
@@ -6617,20 +6626,20 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6617
6626
  return await W.apply(W, N);
6618
6627
  Dt.warn(`API【${c.value.ref}】不存在`);
6619
6628
  }
6620
- }, j = Sn(c.value.test, {
6621
- runApi: O
6622
- }), B = c.value.transform?.value ? Sn(c.value.transform, {}, !0) : (N) => N;
6629
+ }, O = xn(c.value.test, {
6630
+ runApi: j
6631
+ }), B = c.value.transform?.value ? xn(c.value.transform, {}, !0) : (N) => N;
6623
6632
  d.value = !0;
6624
6633
  try {
6625
6634
  a?.disableIntercept();
6626
- const N = await j();
6635
+ const N = await O();
6627
6636
  v.value = JSON.stringify(await B(N), null, 2), a?.enableIntercept();
6628
6637
  } catch (N) {
6629
6638
  Dt.error(N);
6630
6639
  }
6631
6640
  d.value = !1, m.value = !0;
6632
6641
  };
6633
- return (E, O) => (u(), y(n(Rt), {
6642
+ return (E, j) => (u(), y(n(Rt), {
6634
6643
  width: "1000px",
6635
6644
  height: "700px",
6636
6645
  title: b.value,
@@ -6644,7 +6653,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6644
6653
  type: "warning",
6645
6654
  onClick: A
6646
6655
  }, {
6647
- default: h(() => O[4] || (O[4] = [
6656
+ default: h(() => j[4] || (j[4] = [
6648
6657
  X(" 运行测试用例 ")
6649
6658
  ])),
6650
6659
  _: 1
@@ -6672,9 +6681,9 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6672
6681
  props: { filterable: !0 },
6673
6682
  onChange: k
6674
6683
  }, {
6675
- option: h(({ option: j }) => [
6676
- X(ne(j.label) + " ", 1),
6677
- T("i", null, "[ " + ne(j.data.name || j.data.code) + " ]", 1)
6684
+ option: h(({ option: O }) => [
6685
+ X(ne(O.label) + " ", 1),
6686
+ T("i", null, "[ " + ne(O.data.name || O.data.code) + " ]", 1)
6678
6687
  ]),
6679
6688
  _: 1
6680
6689
  }, 8, ["disabled", "options"])),
@@ -6703,7 +6712,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6703
6712
  default: h(() => [
6704
6713
  p(n(Ae), {
6705
6714
  modelValue: c.value.transform.value,
6706
- "onUpdate:modelValue": O[0] || (O[0] = (j) => c.value.transform.value = j),
6715
+ "onUpdate:modelValue": j[0] || (j[0] = (O) => c.value.transform.value = O),
6707
6716
  height: "200px",
6708
6717
  dark: ""
6709
6718
  }, null, 8, ["modelValue"])
@@ -6719,7 +6728,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6719
6728
  default: h(() => [
6720
6729
  p(n(Ae), {
6721
6730
  modelValue: c.value.mockTemplate.value,
6722
- "onUpdate:modelValue": O[1] || (O[1] = (j) => c.value.mockTemplate.value = j),
6731
+ "onUpdate:modelValue": j[1] || (j[1] = (O) => c.value.mockTemplate.value = O),
6723
6732
  height: "300px",
6724
6733
  dark: ""
6725
6734
  }, null, 8, ["modelValue"])
@@ -6734,7 +6743,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6734
6743
  default: h(() => [
6735
6744
  p(n(Ae), {
6736
6745
  modelValue: c.value.test.value,
6737
- "onUpdate:modelValue": O[2] || (O[2] = (j) => c.value.test.value = j),
6746
+ "onUpdate:modelValue": j[2] || (j[2] = (O) => c.value.test.value = O),
6738
6747
  height: "100px",
6739
6748
  dark: ""
6740
6749
  }, null, 8, ["modelValue"])
@@ -6745,7 +6754,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6745
6754
  key: 0,
6746
6755
  class: "v-drawer",
6747
6756
  modelValue: m.value,
6748
- "onUpdate:modelValue": O[3] || (O[3] = (j) => m.value = j),
6757
+ "onUpdate:modelValue": j[3] || (j[3] = (O) => m.value = O),
6749
6758
  title: "测试用例运行结果",
6750
6759
  direction: "btt",
6751
6760
  "append-to-body": "",
@@ -6766,7 +6775,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6766
6775
  _: 1
6767
6776
  }, 8, ["title", "model"]));
6768
6777
  }
6769
- }), jd = /* @__PURE__ */ $({
6778
+ }), Od = /* @__PURE__ */ $({
6770
6779
  name: "DataSourcesWidget",
6771
6780
  __name: "index",
6772
6781
  setup(r) {
@@ -6817,7 +6826,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6817
6826
  ]),
6818
6827
  _: 1
6819
6828
  }),
6820
- s.value ? (u(), y(Od, {
6829
+ s.value ? (u(), y(jd, {
6821
6830
  key: 0,
6822
6831
  modelValue: s.value,
6823
6832
  "onUpdate:modelValue": m[0] || (m[0] = (g) => s.value = g),
@@ -6858,12 +6867,12 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
6858
6867
  {
6859
6868
  label: "inline-block-行内块级布局",
6860
6869
  value: "inline-block",
6861
- svg: Oi
6870
+ svg: ji
6862
6871
  },
6863
6872
  {
6864
6873
  label: "inline-行内布局",
6865
6874
  value: "inline",
6866
- svg: ji
6875
+ svg: Oi
6867
6876
  },
6868
6877
  {
6869
6878
  label: "invisible-不可见",
@@ -7033,7 +7042,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
7033
7042
  const { selected: t } = St(), e = C(), s = V(() => {
7034
7043
  const c = t.value?.model || null;
7035
7044
  return Te(c) ? null : c;
7036
- }), o = V(() => s.value?.getPropValue("style") || {}), i = V(() => en(o.value) ? JSON.stringify({}) : JSON.stringify(Cs(o.value), null, 2)), a = (c) => {
7045
+ }), o = V(() => s.value?.getPropValue("style") || {}), i = V(() => tn(o.value) ? JSON.stringify({}) : JSON.stringify(Cs(o.value), null, 2)), a = (c) => {
7037
7046
  try {
7038
7047
  const d = Cs(JSON.parse(c));
7039
7048
  s.value?.setProp("style", d);
@@ -7203,7 +7212,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
7203
7212
  setStyle: { type: Function }
7204
7213
  },
7205
7214
  setup(r) {
7206
- const t = r, e = C(), s = C(), { width: o, height: i } = mn(e), { width: a, height: l } = mn(s), c = C(!1), d = C(), v = C(), m = () => {
7215
+ const t = r, e = C(), s = C(), { width: o, height: i } = vn(e), { width: a, height: l } = vn(s), c = C(!1), d = C(), v = C(), m = () => {
7207
7216
  c.value = !1, d.value = void 0, v.value = void 0;
7208
7217
  }, g = (b) => {
7209
7218
  d.value = b, v.value = t.styleJson[b], c.value = !0;
@@ -7654,7 +7663,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
7654
7663
  setStyle: { type: Function }
7655
7664
  },
7656
7665
  setup(r) {
7657
- const t = r, e = C(), { width: s, height: o } = mn(e), i = C(!1), a = C(), l = C(), c = [
7666
+ const t = r, e = C(), { width: s, height: o } = vn(e), i = C(!1), a = C(), l = C(), c = [
7658
7667
  { label: "静态", value: "static" },
7659
7668
  { label: "相对", value: "relative" },
7660
7669
  { label: "绝对", value: "absolute" },
@@ -7707,7 +7716,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
7707
7716
  value: t.styleJson.inset,
7708
7717
  onChange: t.setStyle
7709
7718
  }, null, 8, ["value", "onChange"]),
7710
- p(n(cn), { label: " " }, {
7719
+ p(n(un), { label: " " }, {
7711
7720
  default: h(() => [
7712
7721
  T("div", vp, [
7713
7722
  T("div", {
@@ -8344,7 +8353,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8344
8353
  }), Ip = {
8345
8354
  key: 2,
8346
8355
  class: "v-style-widget__mask"
8347
- }, Op = /* @__PURE__ */ $({
8356
+ }, jp = /* @__PURE__ */ $({
8348
8357
  name: "StyleWidget",
8349
8358
  __name: "index",
8350
8359
  props: {
@@ -8354,7 +8363,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8354
8363
  const t = r, { selected: e } = St(), s = V(() => {
8355
8364
  const c = e.value?.model || null;
8356
8365
  return Te(c) ? null : c;
8357
- }), o = V(() => s.value?.getPropValue("style") || {}), i = V(() => Cs(o.value)), a = V(() => en(o.value)), l = (c, d) => {
8366
+ }), o = V(() => s.value?.getPropValue("style") || {}), i = V(() => Cs(o.value)), a = V(() => tn(o.value)), l = (c, d) => {
8358
8367
  const v = s.value?.getPropValue("style") || {};
8359
8368
  d !== void 0 && d !== "" ? v[c] = d : delete v[c], s.value?.setProp("style", v);
8360
8369
  };
@@ -8427,14 +8436,14 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8427
8436
  _: 1
8428
8437
  }));
8429
8438
  }
8430
- }), jp = ["src"], Dp = /* @__PURE__ */ $({
8439
+ }), Op = ["src"], Dp = /* @__PURE__ */ $({
8431
8440
  name: "PreviewerWidget",
8432
8441
  __name: "index",
8433
8442
  props: {
8434
8443
  path: { type: Function }
8435
8444
  },
8436
8445
  setup(r, { expose: t }) {
8437
- const e = r, s = C(), o = C(Symbol()), { current: i, engine: a } = Qe(), { width: l, height: c } = mn(s), d = V(() => i.value && e.path ? e.path(i.value, a.project.value) : null), v = V(() => a.skeleton?.getWidget("Toolbar")?.widgetRef.mode ?? "pc");
8446
+ const e = r, s = C(), o = C(Symbol()), { current: i, engine: a } = Qe(), { width: l, height: c } = vn(s), d = V(() => i.value && e.path ? e.path(i.value, a.project.value) : null), v = V(() => a.skeleton?.getWidget("Toolbar")?.widgetRef.mode ?? "pc");
8438
8447
  return t({
8439
8448
  refresh: () => {
8440
8449
  o.value = Symbol();
@@ -8456,7 +8465,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8456
8465
  ref: "iframe",
8457
8466
  frameborder: "0",
8458
8467
  src: d.value
8459
- }, null, 8, jp)) : I("", !0)
8468
+ }, null, 8, Op)) : I("", !0)
8460
8469
  ]),
8461
8470
  _: 1
8462
8471
  }, 8, ["mode", "width", "height"])
@@ -8591,7 +8600,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8591
8600
  }, c = () => {
8592
8601
  s.value = "//vtj.pro/help/index.html", l();
8593
8602
  };
8594
- tn(() => {
8603
+ nn(() => {
8595
8604
  i || (i = pl.service({ target: o.value?.$el }));
8596
8605
  }), Ts(() => {
8597
8606
  d(), i = null;
@@ -8643,7 +8652,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8643
8652
  p(n(ml), {
8644
8653
  value: n(o),
8645
8654
  title: "最新版本",
8646
- hidden: n(o) === n(xn)
8655
+ hidden: n(o) === n(Cn)
8647
8656
  }, {
8648
8657
  default: h(() => [
8649
8658
  T("img", { src: n(ya) }, null, 8, Fp)
@@ -8654,7 +8663,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8654
8663
  m[1] || (m[1] = T("div", { class: "v-about-widget__name" }, "VTJ.PRO", -1)),
8655
8664
  T("div", Wp, [
8656
8665
  m[0] || (m[0] = X(" 版本: ")),
8657
- T("span", null, ne(n(xn)), 1)
8666
+ T("span", null, ne(n(Cn)), 1)
8658
8667
  ])
8659
8668
  ]),
8660
8669
  a.value ? (u(), y(n(rt), {
@@ -8699,7 +8708,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8699
8708
  name: "ProjectConfigWidget",
8700
8709
  __name: "index",
8701
8710
  setup(r) {
8702
- const { project: t } = sn(), e = (s) => {
8711
+ const { project: t } = on(), e = (s) => {
8703
8712
  t.value?.setConfig(s);
8704
8713
  };
8705
8714
  return (s, o) => (u(), y(n(ce), {
@@ -8784,7 +8793,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8784
8793
  readonly: "",
8785
8794
  onFocus: m,
8786
8795
  "model-value": e.type,
8787
- "suffix-icon": n(vn)
8796
+ "suffix-icon": n(gn)
8788
8797
  }, g.$attrs), null, 16, ["model-value", "suffix-icon"]),
8789
8798
  a.value ? (u(), y(n(kt), {
8790
8799
  key: 0,
@@ -8858,7 +8867,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8858
8867
  readonly: "",
8859
8868
  onFocus: v,
8860
8869
  "model-value": "JSFunction",
8861
- "suffix-icon": n(vn)
8870
+ "suffix-icon": n(gn)
8862
8871
  }, m.$attrs), null, 16, ["suffix-icon"]),
8863
8872
  i.value ? (u(), y(n(kt), {
8864
8873
  key: 0,
@@ -8925,7 +8934,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8925
8934
  readonly: "",
8926
8935
  onFocus: v,
8927
8936
  "model-value": e.type,
8928
- "suffix-icon": n(vn)
8937
+ "suffix-icon": n(gn)
8929
8938
  }, m.$attrs), null, 16, ["model-value", "suffix-icon"]),
8930
8939
  a.value ? (u(), y(n(kt), {
8931
8940
  key: 0,
@@ -8972,7 +8981,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8972
8981
  name: "UniConfigWidget",
8973
8982
  __name: "index",
8974
8983
  setup(r) {
8975
- const t = sc, { project: e } = sn(), s = (i) => (e.value?.uniConfig || {})[i], o = (i, a) => {
8984
+ const t = sc, { project: e } = on(), s = (i) => (e.value?.uniConfig || {})[i], o = (i, a) => {
8976
8985
  console.log("change", e.value, i, a), e.value?.setUniConfig(i, a);
8977
8986
  };
8978
8987
  return (i, a) => (u(), y(n(ce), {
@@ -8994,7 +9003,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
8994
9003
  "label-position": "top"
8995
9004
  }, {
8996
9005
  default: h(() => [
8997
- p(n(cn), {
9006
+ p(n(un), {
8998
9007
  label: "manifest.json",
8999
9008
  onKeydown: a[1] || (a[1] = yt(lt(() => {
9000
9009
  }, ["prevent"]), ["enter", "native"]))
@@ -9007,7 +9016,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9007
9016
  ]),
9008
9017
  _: 1
9009
9018
  }),
9010
- p(n(cn), {
9019
+ p(n(un), {
9011
9020
  label: "pages.json",
9012
9021
  onKeydown: a[3] || (a[3] = yt(lt(() => {
9013
9022
  }, ["prevent"]), ["enter", "native"]))
@@ -9020,7 +9029,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9020
9029
  ]),
9021
9030
  _: 1
9022
9031
  }),
9023
- p(n(cn), {
9032
+ p(n(un), {
9024
9033
  label: "CSS",
9025
9034
  onKeydown: a[5] || (a[5] = yt(lt(() => {
9026
9035
  }, ["prevent"]), ["enter", "native"]))
@@ -9050,7 +9059,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9050
9059
  "label-position": "top"
9051
9060
  }, {
9052
9061
  default: h(() => [
9053
- (u(!0), R(q, null, se(n(t), (l) => (u(), y(n(cn), {
9062
+ (u(!0), R(q, null, se(n(t), (l) => (u(), y(n(un), {
9054
9063
  onKeydown: a[6] || (a[6] = yt(lt(() => {
9055
9064
  }, ["prevent"]), ["enter", "native"])),
9056
9065
  label: l,
@@ -9112,22 +9121,22 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9112
9121
  refreshTemplates: c,
9113
9122
  loading: d,
9114
9123
  removeTemplate: v
9115
- } = Mc(), m = C(""), g = C("0"), b = V(() => m.value ? s.value.filter((O) => O.name.includes(m.value) || O.label?.includes(m.value)) : s.value), f = V(() => {
9116
- const O = l?.getData()?.id, j = wn(b.value, (N) => N.userId === O ? "我的" : "共享"), B = [
9124
+ } = Mc(), m = C(""), g = C("0"), b = V(() => m.value ? s.value.filter((j) => j.name.includes(m.value) || j.label?.includes(m.value)) : s.value), f = V(() => {
9125
+ const j = l?.getData()?.id, O = kn(b.value, (N) => N.userId === j ? "我的" : "共享"), B = [
9117
9126
  { label: "我的", model: {} },
9118
9127
  { label: "共享", model: {} }
9119
9128
  ];
9120
9129
  return B.forEach((N) => {
9121
- N.model = wn(j[N.label], (W) => W.category);
9130
+ N.model = kn(O[N.label], (W) => W.category);
9122
9131
  }), B;
9123
9132
  }), x = V(() => {
9124
- const O = Number(g.value);
9125
- return Object.keys(f.value[O].model) || [];
9133
+ const j = Number(g.value);
9134
+ return Object.keys(f.value[j].model) || [];
9126
9135
  }), w = V(() => {
9127
- const O = Number(g.value);
9128
- return f.value[O].model;
9129
- }), k = V(() => `(共 ${s.value.length} 个)`), _ = async (O) => {
9130
- await i() ? await a(O.id) : await Vt.confirm(
9136
+ const j = Number(g.value);
9137
+ return f.value[j].model;
9138
+ }), k = V(() => `(共 ${s.value.length} 个)`), _ = async (j) => {
9139
+ await i() ? await a(j.id) : await Vt.confirm(
9131
9140
  "使用模版需登录,您还没登录或已过期,请重新登录!",
9132
9141
  "提示",
9133
9142
  {
@@ -9135,14 +9144,14 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9135
9144
  confirmButtonText: "立即登录"
9136
9145
  }
9137
9146
  ).catch(() => !1) && o();
9138
- }, A = (O) => O.share ? !1 : O.userId === l?.getData()?.id, E = async (O) => {
9147
+ }, A = (j) => j.share ? !1 : j.userId === l?.getData()?.id, E = async (j) => {
9139
9148
  await Vt.confirm("确定删除该模版?", "提示", {
9140
9149
  type: "warning"
9141
- }).catch(() => !1) && (await v(O.id), c());
9150
+ }).catch(() => !1) && (await v(j.id), c());
9142
9151
  };
9143
9152
  return t({
9144
9153
  refreshTemplates: c
9145
- }), (O, j) => jt((u(), y(n(ce), {
9154
+ }), (j, O) => Ot((u(), y(n(ce), {
9146
9155
  class: "v-blocks-widget v-templates-widgets",
9147
9156
  title: "模板",
9148
9157
  subtitle: k.value,
@@ -9155,8 +9164,8 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9155
9164
  p(n(Me), {
9156
9165
  size: "small",
9157
9166
  modelValue: m.value,
9158
- "onUpdate:modelValue": j[0] || (j[0] = (B) => m.value = B),
9159
- "prefix-icon": n(nn),
9167
+ "onUpdate:modelValue": O[0] || (O[0] = (B) => m.value = B),
9168
+ "prefix-icon": n(sn),
9160
9169
  placeholder: "搜索模板",
9161
9170
  clearable: ""
9162
9171
  }, null, 8, ["modelValue", "prefix-icon"])
@@ -9164,7 +9173,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9164
9173
  p(n(Xn), {
9165
9174
  items: f.value,
9166
9175
  modelValue: g.value,
9167
- "onUpdate:modelValue": j[1] || (j[1] = (B) => g.value = B),
9176
+ "onUpdate:modelValue": O[1] || (O[1] = (B) => g.value = B),
9168
9177
  class: "v-templates-widgets__tab"
9169
9178
  }, {
9170
9179
  default: h(() => [
@@ -9194,7 +9203,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9194
9203
  title: W.label
9195
9204
  }, {
9196
9205
  default: h(() => [
9197
- W.vip ? (u(), y(n(Os), {
9206
+ W.vip ? (u(), y(n(js), {
9198
9207
  key: 0,
9199
9208
  class: "is-vip",
9200
9209
  type: "danger",
@@ -9202,7 +9211,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9202
9211
  effect: "light",
9203
9212
  round: ""
9204
9213
  }, {
9205
- default: h(() => j[2] || (j[2] = [
9214
+ default: h(() => O[2] || (O[2] = [
9206
9215
  X(" VIP ")
9207
9216
  ])),
9208
9217
  _: 1
@@ -9232,7 +9241,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9232
9241
  round: "",
9233
9242
  onClick: (z) => _(W)
9234
9243
  }, {
9235
- default: h(() => j[3] || (j[3] = [
9244
+ default: h(() => O[3] || (O[3] = [
9236
9245
  X(" 使用 ")
9237
9246
  ])),
9238
9247
  _: 2
@@ -9355,7 +9364,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9355
9364
  },
9356
9365
  emits: ["update:modelValue", "send"],
9357
9366
  setup(r, { expose: t, emit: e }) {
9358
- const s = r, o = e, i = dn.get(_o, { type: "local" }) ?? !0, a = C(""), l = C(i), c = C(s.model || "");
9367
+ const s = r, o = e, i = pn.get(_o, { type: "local" }) ?? !0, a = C(""), l = C(i), c = C(s.model || "");
9359
9368
  Z(
9360
9369
  () => s.models,
9361
9370
  (m) => {
@@ -9371,7 +9380,7 @@ const su = "data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!
9371
9380
  immediate: !0
9372
9381
  }
9373
9382
  ), Z(l, (m) => {
9374
- dn.save(_o, m, { type: "local" }), wt.success({
9383
+ pn.save(_o, m, { type: "local" }), wt.success({
9375
9384
  message: m ? "您已开启自动应用到页面功能,当AI生成代码后将会自动更改当前低代码页面。" : "您已经关闭自动应用到页面功能,您可以通过手动的方式更改当前低代码页面"
9376
9385
  });
9377
9386
  });
@@ -9682,24 +9691,24 @@ function bm() {
9682
9691
  return J && J.index === 0;
9683
9692
  }
9684
9693
  const E = /\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;
9685
- function O(S, { joinWith: M }) {
9694
+ function j(S, { joinWith: M }) {
9686
9695
  let J = 0;
9687
9696
  return S.map((le) => {
9688
9697
  J += 1;
9689
9698
  const Ie = J;
9690
- let Oe = m(le), Y = "";
9691
- for (; Oe.length > 0; ) {
9692
- const K = E.exec(Oe);
9699
+ let je = m(le), Y = "";
9700
+ for (; je.length > 0; ) {
9701
+ const K = E.exec(je);
9693
9702
  if (!K) {
9694
- Y += Oe;
9703
+ Y += je;
9695
9704
  break;
9696
9705
  }
9697
- Y += Oe.substring(0, K.index), Oe = Oe.substring(K.index + K[0].length), K[0][0] === "\\" && K[1] ? Y += "\\" + String(Number(K[1]) + Ie) : (Y += K[0], K[0] === "(" && J++);
9706
+ Y += je.substring(0, K.index), je = je.substring(K.index + K[0].length), K[0][0] === "\\" && K[1] ? Y += "\\" + String(Number(K[1]) + Ie) : (Y += K[0], K[0] === "(" && J++);
9698
9707
  }
9699
9708
  return Y;
9700
9709
  }).map((le) => `(${le})`).join(M);
9701
9710
  }
9702
- const j = /\b\B/, B = "[a-zA-Z]\\w*", N = "[a-zA-Z_]\\w*", W = "\\b\\d+(\\.\\d+)?", z = "(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)", D = "\\b(0b[01]+)", L = "!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~", P = (S = {}) => {
9711
+ const O = /\b\B/, B = "[a-zA-Z]\\w*", N = "[a-zA-Z_]\\w*", W = "\\b\\d+(\\.\\d+)?", z = "(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)", D = "\\b(0b[01]+)", L = "!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~", P = (S = {}) => {
9703
9712
  const M = /^#![ ]*\//;
9704
9713
  return S.binary && (S.begin = x(
9705
9714
  M,
@@ -9803,7 +9812,7 @@ function bm() {
9803
9812
  scope: "number",
9804
9813
  begin: W,
9805
9814
  relevance: 0
9806
- }, nt = {
9815
+ }, st = {
9807
9816
  scope: "number",
9808
9817
  begin: z,
9809
9818
  relevance: 0
@@ -9824,11 +9833,11 @@ function bm() {
9824
9833
  contains: [te]
9825
9834
  }
9826
9835
  ]
9827
- }, on = {
9836
+ }, an = {
9828
9837
  scope: "title",
9829
9838
  begin: B,
9830
9839
  relevance: 0
9831
- }, gn = {
9840
+ }, fn = {
9832
9841
  scope: "title",
9833
9842
  begin: N,
9834
9843
  relevance: 0
@@ -9846,7 +9855,7 @@ function bm() {
9846
9855
  COMMENT: be,
9847
9856
  C_BLOCK_COMMENT_MODE: Fe,
9848
9857
  C_LINE_COMMENT_MODE: Ge,
9849
- C_NUMBER_MODE: nt,
9858
+ C_NUMBER_MODE: st,
9850
9859
  C_NUMBER_RE: z,
9851
9860
  END_SAME_AS_BEGIN: function(S) {
9852
9861
  return Object.assign(
@@ -9865,7 +9874,7 @@ function bm() {
9865
9874
  },
9866
9875
  HASH_COMMENT_MODE: qe,
9867
9876
  IDENT_RE: B,
9868
- MATCH_NOTHING_RE: j,
9877
+ MATCH_NOTHING_RE: O,
9869
9878
  METHOD_GUARD: qt,
9870
9879
  NUMBER_MODE: et,
9871
9880
  NUMBER_RE: W,
@@ -9874,14 +9883,14 @@ function bm() {
9874
9883
  REGEXP_MODE: ut,
9875
9884
  RE_STARTERS_RE: L,
9876
9885
  SHEBANG: P,
9877
- TITLE_MODE: on,
9886
+ TITLE_MODE: an,
9878
9887
  UNDERSCORE_IDENT_RE: N,
9879
- UNDERSCORE_TITLE_MODE: gn
9888
+ UNDERSCORE_TITLE_MODE: fn
9880
9889
  });
9881
9890
  function Kt(S, M) {
9882
9891
  S.input[S.index - 1] === "." && M.ignoreMatch();
9883
9892
  }
9884
- function fn(S, M) {
9893
+ function hn(S, M) {
9885
9894
  S.className !== void 0 && (S.scope = S.className, delete S.className);
9886
9895
  }
9887
9896
  function ns(S, M) {
@@ -9890,7 +9899,7 @@ function bm() {
9890
9899
  function ss(S, M) {
9891
9900
  Array.isArray(S.illegal) && (S.illegal = k(...S.illegal));
9892
9901
  }
9893
- function An(S, M) {
9902
+ function Vn(S, M) {
9894
9903
  if (S.match) {
9895
9904
  if (S.begin || S.end) throw new Error("begin & end are not supported with match");
9896
9905
  S.begin = S.match, delete S.match;
@@ -9929,16 +9938,16 @@ function bm() {
9929
9938
  ], Re = "keyword";
9930
9939
  function tt(S, M, J = Re) {
9931
9940
  const le = /* @__PURE__ */ Object.create(null);
9932
- return typeof S == "string" ? Ie(J, S.split(" ")) : Array.isArray(S) ? Ie(J, S) : Object.keys(S).forEach(function(Oe) {
9941
+ return typeof S == "string" ? Ie(J, S.split(" ")) : Array.isArray(S) ? Ie(J, S) : Object.keys(S).forEach(function(je) {
9933
9942
  Object.assign(
9934
9943
  le,
9935
- tt(S[Oe], M, Oe)
9944
+ tt(S[je], M, je)
9936
9945
  );
9937
9946
  }), le;
9938
- function Ie(Oe, Y) {
9947
+ function Ie(je, Y) {
9939
9948
  M && (Y = Y.map((K) => K.toLowerCase())), Y.forEach(function(K) {
9940
9949
  const ae = K.split("|");
9941
- le[ae[0]] = [Oe, Le(ae[0], ae[1])];
9950
+ le[ae[0]] = [je, Le(ae[0], ae[1])];
9942
9951
  });
9943
9952
  }
9944
9953
  }
@@ -9948,36 +9957,36 @@ function bm() {
9948
9957
  function xt(S) {
9949
9958
  return fe.includes(S.toLowerCase());
9950
9959
  }
9951
- const hn = {}, ft = (S) => {
9960
+ const bn = {}, ft = (S) => {
9952
9961
  console.error(S);
9953
9962
  }, $t = (S, ...M) => {
9954
9963
  console.log(`WARN: ${S}`, ...M);
9955
- }, st = (S, M) => {
9956
- hn[`${S}/${M}`] || (console.log(`Deprecated as of ${S}. ${M}`), hn[`${S}/${M}`] = !0);
9957
- }, Vn = new Error();
9964
+ }, nt = (S, M) => {
9965
+ bn[`${S}/${M}`] || (console.log(`Deprecated as of ${S}. ${M}`), bn[`${S}/${M}`] = !0);
9966
+ }, Xt = new Error();
9958
9967
  function qs(S, M, { key: J }) {
9959
9968
  let le = 0;
9960
- const Ie = S[J], Oe = {}, Y = {};
9969
+ const Ie = S[J], je = {}, Y = {};
9961
9970
  for (let K = 1; K <= M.length; K++)
9962
- Y[K + le] = Ie[K], Oe[K + le] = !0, le += _(M[K - 1]);
9963
- S[J] = Y, S[J]._emit = Oe, S[J]._multi = !0;
9971
+ Y[K + le] = Ie[K], je[K + le] = !0, le += _(M[K - 1]);
9972
+ S[J] = Y, S[J]._emit = je, S[J]._multi = !0;
9964
9973
  }
9965
9974
  function Va(S) {
9966
9975
  if (Array.isArray(S.begin)) {
9967
9976
  if (S.skip || S.excludeBegin || S.returnBegin)
9968
- throw ft("skip, excludeBegin, returnBegin not compatible with beginScope: {}"), Vn;
9977
+ throw ft("skip, excludeBegin, returnBegin not compatible with beginScope: {}"), Xt;
9969
9978
  if (typeof S.beginScope != "object" || S.beginScope === null)
9970
- throw ft("beginScope must be object"), Vn;
9971
- qs(S, S.begin, { key: "beginScope" }), S.begin = O(S.begin, { joinWith: "" });
9979
+ throw ft("beginScope must be object"), Xt;
9980
+ qs(S, S.begin, { key: "beginScope" }), S.begin = j(S.begin, { joinWith: "" });
9972
9981
  }
9973
9982
  }
9974
9983
  function Ta(S) {
9975
9984
  if (Array.isArray(S.end)) {
9976
9985
  if (S.skip || S.excludeEnd || S.returnEnd)
9977
- throw ft("skip, excludeEnd, returnEnd not compatible with endScope: {}"), Vn;
9986
+ throw ft("skip, excludeEnd, returnEnd not compatible with endScope: {}"), Xt;
9978
9987
  if (typeof S.endScope != "object" || S.endScope === null)
9979
- throw ft("endScope must be object"), Vn;
9980
- qs(S, S.end, { key: "endScope" }), S.end = O(S.end, { joinWith: "" });
9988
+ throw ft("endScope must be object"), Xt;
9989
+ qs(S, S.end, { key: "endScope" }), S.end = j(S.end, { joinWith: "" });
9981
9990
  }
9982
9991
  }
9983
9992
  function Ra(S) {
@@ -9986,7 +9995,7 @@ function bm() {
9986
9995
  function Ia(S) {
9987
9996
  Ra(S), typeof S.beginScope == "string" && (S.beginScope = { _wrap: S.beginScope }), typeof S.endScope == "string" && (S.endScope = { _wrap: S.endScope }), Va(S), Ta(S);
9988
9997
  }
9989
- function Oa(S) {
9998
+ function ja(S) {
9990
9999
  function M(Y, K) {
9991
10000
  return new RegExp(
9992
10001
  m(Y),
@@ -10004,7 +10013,7 @@ function bm() {
10004
10013
  compile() {
10005
10014
  this.regexes.length === 0 && (this.exec = () => null);
10006
10015
  const K = this.regexes.map((ae) => ae[1]);
10007
- this.matcherRe = M(O(K, { joinWith: "|" }), !0), this.lastIndex = 0;
10016
+ this.matcherRe = M(j(K, { joinWith: "|" }), !0), this.lastIndex = 0;
10008
10017
  }
10009
10018
  /** @param {string} s */
10010
10019
  exec(K) {
@@ -10012,7 +10021,7 @@ function bm() {
10012
10021
  const ae = this.matcherRe.exec(K);
10013
10022
  if (!ae)
10014
10023
  return null;
10015
- const Je = ae.findIndex((bn, ls) => ls > 0 && bn !== void 0), $e = this.matchIndexes[Je];
10024
+ const Je = ae.findIndex((yn, ls) => ls > 0 && yn !== void 0), $e = this.matchIndexes[Je];
10016
10025
  return ae.splice(0, Je), Object.assign(ae, $e);
10017
10026
  }
10018
10027
  }
@@ -10052,17 +10061,17 @@ function bm() {
10052
10061
  const K = new le();
10053
10062
  return Y.contains.forEach((ae) => K.addRule(ae.begin, { rule: ae, type: "begin" })), Y.terminatorEnd && K.addRule(Y.terminatorEnd, { type: "end" }), Y.illegal && K.addRule(Y.illegal, { type: "illegal" }), K;
10054
10063
  }
10055
- function Oe(Y, K) {
10064
+ function je(Y, K) {
10056
10065
  const ae = (
10057
10066
  /** @type CompiledMode */
10058
10067
  Y
10059
10068
  );
10060
10069
  if (Y.isCompiled) return ae;
10061
10070
  [
10062
- fn,
10071
+ hn,
10063
10072
  // do this early so compiler extensions generally don't have to worry about
10064
10073
  // the distinction between match/begin
10065
- An,
10074
+ Vn,
10066
10075
  Ia,
10067
10076
  H
10068
10077
  ].forEach(($e) => $e(Y, K)), S.compilerExtensions.forEach(($e) => $e(Y, K)), Y.__beforeBegin = null, [
@@ -10078,18 +10087,18 @@ function bm() {
10078
10087
  /** @type {RegExp | string} */
10079
10088
  Y.illegal
10080
10089
  )), Y.contains || (Y.contains = []), Y.contains = [].concat(...Y.contains.map(function($e) {
10081
- return ja($e === "self" ? Y : $e);
10090
+ return Oa($e === "self" ? Y : $e);
10082
10091
  })), Y.contains.forEach(function($e) {
10083
- Oe(
10092
+ je(
10084
10093
  /** @type Mode */
10085
10094
  $e,
10086
10095
  ae
10087
10096
  );
10088
- }), Y.starts && Oe(Y.starts, K), ae.matcher = Ie(ae), ae;
10097
+ }), Y.starts && je(Y.starts, K), ae.matcher = Ie(ae), ae;
10089
10098
  }
10090
10099
  if (S.compilerExtensions || (S.compilerExtensions = []), S.contains && S.contains.includes("self"))
10091
10100
  throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");
10092
- return S.classNameAliases = s(S.classNameAliases || {}), Oe(
10101
+ return S.classNameAliases = s(S.classNameAliases || {}), je(
10093
10102
  /** @type Mode */
10094
10103
  S
10095
10104
  );
@@ -10097,7 +10106,7 @@ function bm() {
10097
10106
  function Ks(S) {
10098
10107
  return S ? S.endsWithParent || Ks(S.starts) : !1;
10099
10108
  }
10100
- function ja(S) {
10109
+ function Oa(S) {
10101
10110
  return S.variants && !S.cachedVariants && (S.cachedVariants = S.variants.map(function(M) {
10102
10111
  return s(S, { variants: null }, M);
10103
10112
  })), S.cachedVariants ? S.cachedVariants : Ks(S) ? s(S, { starts: S.starts ? s(S.starts) : null }) : Object.isFrozen(S) ? s(S) : S;
@@ -10111,7 +10120,7 @@ function bm() {
10111
10120
  const as = e, Xs = s, Qs = Symbol("nomatch"), Na = 7, Ys = function(S) {
10112
10121
  const M = /* @__PURE__ */ Object.create(null), J = /* @__PURE__ */ Object.create(null), le = [];
10113
10122
  let Ie = !0;
10114
- const Oe = "Could not find the language '{}', did you forget to load/include a language module?", Y = { disableAutodetect: !0, name: "Plain text", contains: [] };
10123
+ const je = "Could not find the language '{}', did you forget to load/include a language module?", Y = { disableAutodetect: !0, name: "Plain text", contains: [] };
10115
10124
  let K = {
10116
10125
  ignoreUnescapedHTML: !1,
10117
10126
  throwUnescapedHTML: !1,
@@ -10133,23 +10142,23 @@ function bm() {
10133
10142
  const ge = K.languageDetectRe.exec(oe);
10134
10143
  if (ge) {
10135
10144
  const we = Nt(ge[1]);
10136
- return we || ($t(Oe.replace("{}", ge[1])), $t("Falling back to no-highlight mode for this block.", U)), we ? ge[1] : "no-highlight";
10145
+ return we || ($t(je.replace("{}", ge[1])), $t("Falling back to no-highlight mode for this block.", U)), we ? ge[1] : "no-highlight";
10137
10146
  }
10138
10147
  return oe.split(/\s+/).find((we) => ae(we) || Nt(we));
10139
10148
  }
10140
10149
  function $e(U, oe, ge) {
10141
10150
  let we = "", ze = "";
10142
- typeof oe == "object" ? (we = U, ge = oe.ignoreIllegals, ze = oe.language) : (st("10.7.0", "highlight(lang, code, ...args) has been deprecated."), st("10.7.0", `Please use highlight(code, options) instead.
10151
+ typeof oe == "object" ? (we = U, ge = oe.ignoreIllegals, ze = oe.language) : (nt("10.7.0", "highlight(lang, code, ...args) has been deprecated."), nt("10.7.0", `Please use highlight(code, options) instead.
10143
10152
  https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge === void 0 && (ge = !0);
10144
10153
  const ht = {
10145
10154
  code: we,
10146
10155
  language: ze
10147
10156
  };
10148
10157
  Rn("before:highlight", ht);
10149
- const Pt = ht.result ? ht.result : bn(ht.language, ht.code, ge);
10158
+ const Pt = ht.result ? ht.result : yn(ht.language, ht.code, ge);
10150
10159
  return Pt.code = ht.code, Rn("after:highlight", Pt), Pt;
10151
10160
  }
10152
- function bn(U, oe, ge, we) {
10161
+ function yn(U, oe, ge, we) {
10153
10162
  const ze = /* @__PURE__ */ Object.create(null);
10154
10163
  function ht(G, ee) {
10155
10164
  return G.keywords[ee];
@@ -10166,11 +10175,11 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10166
10175
  me += ke.substring(G, ee.index);
10167
10176
  const ye = Et.case_insensitive ? ee[0].toLowerCase() : ee[0], Ye = ht(ie, ye);
10168
10177
  if (Ye) {
10169
- const [Ot, Za] = Ye;
10170
- if (Ke.addText(me), me = "", ze[ye] = (ze[ye] || 0) + 1, ze[ye] <= Na && (jn += Za), Ot.startsWith("_"))
10178
+ const [jt, Za] = Ye;
10179
+ if (Ke.addText(me), me = "", ze[ye] = (ze[ye] || 0) + 1, ze[ye] <= Na && (On += Za), jt.startsWith("_"))
10171
10180
  me += ee[0];
10172
10181
  else {
10173
- const el = Et.classNameAliases[Ot] || Ot;
10182
+ const el = Et.classNameAliases[jt] || jt;
10174
10183
  Ct(ee[0], el);
10175
10184
  }
10176
10185
  } else
@@ -10187,11 +10196,11 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10187
10196
  Ke.addText(ke);
10188
10197
  return;
10189
10198
  }
10190
- G = bn(ie.subLanguage, ke, !0, lo[ie.subLanguage]), lo[ie.subLanguage] = /** @type {CompiledMode} */
10199
+ G = yn(ie.subLanguage, ke, !0, lo[ie.subLanguage]), lo[ie.subLanguage] = /** @type {CompiledMode} */
10191
10200
  G._top;
10192
10201
  } else
10193
10202
  G = is(ke, ie.subLanguage.length ? ie.subLanguage : null);
10194
- ie.relevance > 0 && (jn += G.relevance), Ke.__addSublanguage(G._emitter, G.language);
10203
+ ie.relevance > 0 && (On += G.relevance), Ke.__addSublanguage(G._emitter, G.language);
10195
10204
  }
10196
10205
  function ot() {
10197
10206
  ie.subLanguage != null ? In() : Pt(), ke = "";
@@ -10207,8 +10216,8 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10207
10216
  me++;
10208
10217
  continue;
10209
10218
  }
10210
- const Ye = Et.classNameAliases[G[me]] || G[me], Ot = ee[me];
10211
- Ye ? Ct(Ot, Ye) : (ke = Ot, Pt(), ke = ""), me++;
10219
+ const Ye = Et.classNameAliases[G[me]] || G[me], jt = ee[me];
10220
+ Ye ? Ct(jt, Ye) : (ke = jt, Pt(), ke = ""), me++;
10212
10221
  }
10213
10222
  }
10214
10223
  function so(G, ee) {
@@ -10235,8 +10244,8 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10235
10244
  }
10236
10245
  function Ka(G) {
10237
10246
  const ee = G[0], me = G.rule, ye = new t(me), Ye = [me.__beforeBegin, me["on:begin"]];
10238
- for (const Ot of Ye)
10239
- if (Ot && (Ot(G, ye), ye.isMatchIgnored))
10247
+ for (const jt of Ye)
10248
+ if (jt && (jt(G, ye), ye.isMatchIgnored))
10240
10249
  return qa(ee);
10241
10250
  return me.skip ? ke += ee : (me.excludeBegin && (ke += ee), ot(), !me.returnBegin && !me.excludeBegin && (ke = ee)), so(me, G), me.returnBegin ? 0 : ee.length;
10242
10251
  }
@@ -10247,7 +10256,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10247
10256
  const Ye = ie;
10248
10257
  ie.endScope && ie.endScope._wrap ? (ot(), Ct(ee, ie.endScope._wrap)) : ie.endScope && ie.endScope._multi ? (ot(), no(ie.endScope, G)) : Ye.skip ? ke += ee : (Ye.returnEnd || Ye.excludeEnd || (ke += ee), ot(), Ye.excludeEnd && (ke = ee));
10249
10258
  do
10250
- ie.scope && Ke.closeNode(), !ie.skip && !ie.subLanguage && (jn += ie.relevance), ie = ie.parent;
10259
+ ie.scope && Ke.closeNode(), !ie.skip && !ie.subLanguage && (On += ie.relevance), ie = ie.parent;
10251
10260
  while (ie !== ye.parent);
10252
10261
  return ye.starts && so(ye.starts, G), Ye.returnEnd ? 0 : ee.length;
10253
10262
  }
@@ -10257,19 +10266,19 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10257
10266
  ee.scope && G.unshift(ee.scope);
10258
10267
  G.forEach((ee) => Ke.openNode(ee));
10259
10268
  }
10260
- let On = {};
10269
+ let jn = {};
10261
10270
  function ao(G, ee) {
10262
10271
  const me = ee && ee[0];
10263
10272
  if (ke += G, me == null)
10264
10273
  return ot(), 0;
10265
- if (On.type === "begin" && ee.type === "end" && On.index === ee.index && me === "") {
10274
+ if (jn.type === "begin" && ee.type === "end" && jn.index === ee.index && me === "") {
10266
10275
  if (ke += oe.slice(ee.index, ee.index + 1), !Ie) {
10267
10276
  const ye = new Error(`0 width match regex (${U})`);
10268
- throw ye.languageName = U, ye.badRule = On.rule, ye;
10277
+ throw ye.languageName = U, ye.badRule = jn.rule, ye;
10269
10278
  }
10270
10279
  return 1;
10271
10280
  }
10272
- if (On = ee, ee.type === "begin")
10281
+ if (jn = ee, ee.type === "begin")
10273
10282
  return Ka(ee);
10274
10283
  if (ee.type === "illegal" && !ge) {
10275
10284
  const ye = new Error('Illegal lexeme "' + me + '" for mode "' + (ie.scope || "<unnamed>") + '"');
@@ -10288,29 +10297,29 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10288
10297
  }
10289
10298
  const Et = Nt(U);
10290
10299
  if (!Et)
10291
- throw ft(Oe.replace("{}", U)), new Error('Unknown language: "' + U + '"');
10292
- const Ya = Oa(Et);
10300
+ throw ft(je.replace("{}", U)), new Error('Unknown language: "' + U + '"');
10301
+ const Ya = ja(Et);
10293
10302
  let cs = "", ie = we || Ya;
10294
10303
  const lo = {}, Ke = new K.__emitter(K);
10295
10304
  Qa();
10296
- let ke = "", jn = 0, Xt = 0, us = 0, ds = !1;
10305
+ let ke = "", On = 0, Qt = 0, us = 0, ds = !1;
10297
10306
  try {
10298
10307
  if (Et.__emitTokens)
10299
10308
  Et.__emitTokens(oe, Ke);
10300
10309
  else {
10301
10310
  for (ie.matcher.considerAll(); ; ) {
10302
- us++, ds ? ds = !1 : ie.matcher.considerAll(), ie.matcher.lastIndex = Xt;
10311
+ us++, ds ? ds = !1 : ie.matcher.considerAll(), ie.matcher.lastIndex = Qt;
10303
10312
  const G = ie.matcher.exec(oe);
10304
10313
  if (!G) break;
10305
- const ee = oe.substring(Xt, G.index), me = ao(ee, G);
10306
- Xt = G.index + me;
10314
+ const ee = oe.substring(Qt, G.index), me = ao(ee, G);
10315
+ Qt = G.index + me;
10307
10316
  }
10308
- ao(oe.substring(Xt));
10317
+ ao(oe.substring(Qt));
10309
10318
  }
10310
10319
  return Ke.finalize(), cs = Ke.toHTML(), {
10311
10320
  language: U,
10312
10321
  value: cs,
10313
- relevance: jn,
10322
+ relevance: On,
10314
10323
  illegal: !1,
10315
10324
  _emitter: Ke,
10316
10325
  _top: ie
@@ -10324,8 +10333,8 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10324
10333
  relevance: 0,
10325
10334
  _illegalBy: {
10326
10335
  message: G.message,
10327
- index: Xt,
10328
- context: oe.slice(Xt - 100, Xt + 100),
10336
+ index: Qt,
10337
+ context: oe.slice(Qt - 100, Qt + 100),
10329
10338
  mode: G.mode,
10330
10339
  resultSoFar: cs
10331
10340
  },
@@ -10357,7 +10366,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10357
10366
  function is(U, oe) {
10358
10367
  oe = oe || K.languages || Object.keys(M);
10359
10368
  const ge = ls(U), we = oe.filter(Nt).filter(to).map(
10360
- (ot) => bn(ot, U, !1)
10369
+ (ot) => yn(ot, U, !1)
10361
10370
  );
10362
10371
  we.unshift(ge);
10363
10372
  const ze = we.sort((ot, Ct) => {
@@ -10408,10 +10417,10 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10408
10417
  K = Xs(K, U);
10409
10418
  }
10410
10419
  const Ba = () => {
10411
- Tn(), st("10.6.0", "initHighlighting() deprecated. Use highlightAll() now.");
10420
+ Tn(), nt("10.6.0", "initHighlighting() deprecated. Use highlightAll() now.");
10412
10421
  };
10413
10422
  function La() {
10414
- Tn(), st("10.6.0", "initHighlightingOnLoad() deprecated. Use highlightAll() now.");
10423
+ Tn(), nt("10.6.0", "initHighlightingOnLoad() deprecated. Use highlightAll() now.");
10415
10424
  }
10416
10425
  let Zs = !1;
10417
10426
  function Tn() {
@@ -10482,7 +10491,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10482
10491
  });
10483
10492
  }
10484
10493
  function Ga(U) {
10485
- return st("10.7.0", "highlightBlock will be removed entirely in v12.0"), st("10.7.0", "Please use highlightElement now."), rs(U);
10494
+ return nt("10.7.0", "highlightBlock will be removed entirely in v12.0"), nt("10.7.0", "Please use highlightElement now."), rs(U);
10486
10495
  }
10487
10496
  Object.assign(S, {
10488
10497
  highlight: $e,
@@ -10517,8 +10526,8 @@ https://github.com/highlightjs/highlight.js/issues/2277`), ze = U, we = oe), ge
10517
10526
  for (const U in We)
10518
10527
  typeof We[U] == "object" && r(We[U]);
10519
10528
  return Object.assign(S, We), S;
10520
- }, an = Ys({});
10521
- return an.newInstance = () => Ys({}), ys = an, an.HighlightJS = an, an.default = an, ys;
10529
+ }, ln = Ys({});
10530
+ return ln.newInstance = () => Ys({}), ys = ln, ln.HighlightJS = ln, ln.default = ln, ys;
10522
10531
  }
10523
10532
  var ym = /* @__PURE__ */ bm();
10524
10533
  const $n = /* @__PURE__ */ hm(ym);
@@ -10913,12 +10922,12 @@ function Cm(r) {
10913
10922
  }
10914
10923
  qe === ">" && (e(be, { after: Fe }) || Ge.ignoreMatch());
10915
10924
  let et;
10916
- const nt = be.input.substring(Fe);
10917
- if (et = nt.match(/^\s*=/)) {
10925
+ const st = be.input.substring(Fe);
10926
+ if (et = st.match(/^\s*=/)) {
10918
10927
  Ge.ignoreMatch();
10919
10928
  return;
10920
10929
  }
10921
- if ((et = nt.match(/^\s+extends\s+/)) && et.index === 0) {
10930
+ if ((et = st.match(/^\s+extends\s+/)) && et.index === 0) {
10922
10931
  Ge.ignoreMatch();
10923
10932
  return;
10924
10933
  }
@@ -11066,7 +11075,7 @@ function Cm(r) {
11066
11075
  "self"
11067
11076
  ].concat(A)
11068
11077
  });
11069
- const E = [].concat(_, g.contains), O = E.concat([
11078
+ const E = [].concat(_, g.contains), j = E.concat([
11070
11079
  // eat recursive parens in sub expressions
11071
11080
  {
11072
11081
  begin: /(\s*)\(/,
@@ -11074,7 +11083,7 @@ function Cm(r) {
11074
11083
  keywords: l,
11075
11084
  contains: ["self"].concat(E)
11076
11085
  }
11077
- ]), j = {
11086
+ ]), O = {
11078
11087
  className: "params",
11079
11088
  // convert this to negative lookbehind in v12
11080
11089
  begin: /(\s*)\(/,
@@ -11083,7 +11092,7 @@ function Cm(r) {
11083
11092
  excludeBegin: !0,
11084
11093
  excludeEnd: !0,
11085
11094
  keywords: l,
11086
- contains: O
11095
+ contains: j
11087
11096
  }, B = {
11088
11097
  variants: [
11089
11098
  // class Car extends vehicle
@@ -11169,7 +11178,7 @@ function Cm(r) {
11169
11178
  3: "title.function"
11170
11179
  },
11171
11180
  label: "func.def",
11172
- contains: [j],
11181
+ contains: [O],
11173
11182
  illegal: /%/
11174
11183
  }, D = {
11175
11184
  relevance: 0,
@@ -11217,7 +11226,7 @@ function Cm(r) {
11217
11226
  // eat to avoid empty params
11218
11227
  begin: /\(\)/
11219
11228
  },
11220
- j
11229
+ O
11221
11230
  ]
11222
11231
  }, Ue = "(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|" + r.UNDERSCORE_IDENT_RE + ")\\s*=>", _e = {
11223
11232
  match: [
@@ -11236,7 +11245,7 @@ function Cm(r) {
11236
11245
  3: "title.function"
11237
11246
  },
11238
11247
  contains: [
11239
- j
11248
+ O
11240
11249
  ]
11241
11250
  };
11242
11251
  return {
@@ -11244,7 +11253,7 @@ function Cm(r) {
11244
11253
  aliases: ["js", "jsx", "mjs", "cjs"],
11245
11254
  keywords: l,
11246
11255
  // this will be extended by TypeScript
11247
- exports: { PARAMS_CONTAINS: O, CLASS_REFERENCE: N },
11256
+ exports: { PARAMS_CONTAINS: j, CLASS_REFERENCE: N },
11248
11257
  illegal: /#(?![$_A-z])/,
11249
11258
  contains: [
11250
11259
  r.SHEBANG({
@@ -11305,7 +11314,7 @@ function Cm(r) {
11305
11314
  excludeBegin: !0,
11306
11315
  excludeEnd: !0,
11307
11316
  keywords: l,
11308
- contains: O
11317
+ contains: j
11309
11318
  }
11310
11319
  ]
11311
11320
  }
@@ -11360,7 +11369,7 @@ function Cm(r) {
11360
11369
  returnBegin: !0,
11361
11370
  label: "func.def",
11362
11371
  contains: [
11363
- j,
11372
+ O,
11364
11373
  r.inherit(r.TITLE_MODE, { begin: s, className: "title.function" })
11365
11374
  ]
11366
11375
  },
@@ -11380,7 +11389,7 @@ function Cm(r) {
11380
11389
  {
11381
11390
  match: [/\bconstructor(?=\s*\()/],
11382
11391
  className: { 1: "title.function" },
11383
- contains: [j]
11392
+ contains: [O]
11384
11393
  },
11385
11394
  P,
11386
11395
  D,
@@ -11658,7 +11667,7 @@ const Em = (r) => ({
11658
11667
  "visited",
11659
11668
  "where"
11660
11669
  // where()
11661
- ].sort().reverse(), Om = [
11670
+ ].sort().reverse(), jm = [
11662
11671
  "after",
11663
11672
  "backdrop",
11664
11673
  "before",
@@ -11673,7 +11682,7 @@ const Em = (r) => ({
11673
11682
  "selection",
11674
11683
  "slotted",
11675
11684
  "spelling-error"
11676
- ].sort().reverse(), jm = [
11685
+ ].sort().reverse(), Om = [
11677
11686
  "accent-color",
11678
11687
  "align-content",
11679
11688
  "align-items",
@@ -12226,7 +12235,7 @@ function Dm(r) {
12226
12235
  className: "selector-pseudo",
12227
12236
  variants: [
12228
12237
  { begin: ":(" + Im.join("|") + ")" },
12229
- { begin: ":(:)?(" + Om.join("|") + ")" }
12238
+ { begin: ":(:)?(" + jm.join("|") + ")" }
12230
12239
  ]
12231
12240
  },
12232
12241
  // we may actually need this (12/2020)
@@ -12238,7 +12247,7 @@ function Dm(r) {
12238
12247
  e.CSS_VARIABLE,
12239
12248
  {
12240
12249
  className: "attribute",
12241
- begin: "\\b(" + jm.join("|") + ")\\b"
12250
+ begin: "\\b(" + Om.join("|") + ")\\b"
12242
12251
  },
12243
12252
  // attribute values
12244
12253
  {
@@ -12365,7 +12374,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
12365
12374
  emits: ["refresh", "view", "download", "fix"],
12366
12375
  setup(r, { emit: t }) {
12367
12376
  const e = r, s = t, o = V(() => e.type === "ai"), i = V(() => e.data.status === "Success"), a = V(() => e.data.status === "Pending"), l = C(e.data.collapsed), c = V(
12368
- () => l.value ? Or : jr
12377
+ () => l.value ? jr : Or
12369
12378
  ), d = V(() => ({
12370
12379
  [`is-${e.data.status}`]: e.type === "ai"
12371
12380
  })), v = V(() => [
@@ -12424,7 +12433,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
12424
12433
  class: pe(["v-ai-widget-bubble__content", d.value])
12425
12434
  }, [
12426
12435
  o.value ? (u(), R(q, { key: 0 }, [
12427
- a.value ? I("", !0) : (u(), y(n(Os), {
12436
+ a.value ? I("", !0) : (u(), y(n(js), {
12428
12437
  key: 0,
12429
12438
  class: "v-ai-widget-bubble__toggle",
12430
12439
  size: "small",
@@ -12542,7 +12551,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
12542
12551
  }, c = (d) => {
12543
12552
  s("send", { type: a.value, ...d });
12544
12553
  };
12545
- return tn(async () => {
12554
+ return nn(async () => {
12546
12555
  const d = await o();
12547
12556
  d?.success && (i.value = d.data);
12548
12557
  }), (d, v) => (u(), R("div", Gm, [
@@ -12636,7 +12645,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
12636
12645
  o("change", a?.getValue(), m);
12637
12646
  }), a.onDidBlurEditorText(c);
12638
12647
  };
12639
- return tn(() => {
12648
+ return nn(() => {
12640
12649
  at(d);
12641
12650
  }), Ts(() => {
12642
12651
  a && a.dispose();
@@ -12651,7 +12660,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
12651
12660
  ref: i,
12652
12661
  onKeyup: g[0] || (g[0] = yt(lt(() => {
12653
12662
  }, ["stop"]), ["enter"])),
12654
- style: rn({ height: s.height })
12663
+ style: cn({ height: s.height })
12655
12664
  }, null, 38));
12656
12665
  }
12657
12666
  }), Ym = /* @__PURE__ */ $({
@@ -12785,7 +12794,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
12785
12794
  const b = await t.createOrder();
12786
12795
  b?.success && (s.value = !0, o.value = b.data);
12787
12796
  }, m = async () => {
12788
- ((await t.getOrder(o.value?.id))?.data).status === "Completed" ? (await un("订单已经支付成功,你权限已经开通!").catch(() => null), location.reload()) : await un("您的订单状态还没更新,支付后请与客服联系!", {
12797
+ ((await t.getOrder(o.value?.id))?.data).status === "Completed" ? (await dn("订单已经支付成功,你权限已经开通!").catch(() => null), location.reload()) : await dn("您的订单状态还没更新,支付后请与客服联系!", {
12789
12798
  type: "success",
12790
12799
  confirmButtonText: "再等等"
12791
12800
  }).catch(() => null);
@@ -12976,8 +12985,8 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
12976
12985
  currentChat: _,
12977
12986
  showDetail: A,
12978
12987
  scrollToTop: E,
12979
- scrollToBottom: O,
12980
- expandAll: j,
12988
+ scrollToBottom: j,
12989
+ expandAll: O,
12981
12990
  collapseAll: B,
12982
12991
  isPending: N,
12983
12992
  toggleHideCode: W,
@@ -12991,7 +13000,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
12991
13000
  cancelOrder: _e,
12992
13001
  getOrder: be,
12993
13002
  updateChatDsl: Ge
12994
- } = nu(), Fe = C(!0), qe = C(!1), et = V(() => !t.current.value), nt = V(() => z.value ? {
13003
+ } = nu(), Fe = C(!0), qe = C(!1), et = V(() => !t.current.value), st = V(() => z.value ? {
12995
13004
  icon: Pr,
12996
13005
  title: "显示代码块",
12997
13006
  type: "warning"
@@ -13000,7 +13009,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
13000
13009
  title: "隐藏代码块",
13001
13010
  type: "default"
13002
13011
  }), vt = V(() => !Fe.value || et.value ? "hidden" : "auto");
13003
- tn(async () => {
13012
+ nn(async () => {
13004
13013
  Fe.value = await e();
13005
13014
  });
13006
13015
  const ut = () => {
@@ -13019,9 +13028,9 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
13019
13028
  return;
13020
13029
  }
13021
13030
  qe.value = !qe.value;
13022
- }, on = () => {
13031
+ }, an = () => {
13023
13032
  N.value || (s.value = !0, qe.value = !1);
13024
- }, gn = (qt) => {
13033
+ }, fn = (qt) => {
13025
13034
  qe.value = !1, s.value = !1, c.value = qt, m(qt.id);
13026
13035
  };
13027
13036
  return (qt, gt) => (u(), y(n(de), {
@@ -13042,7 +13051,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
13042
13051
  mode: "icon",
13043
13052
  size: "small",
13044
13053
  disabled: n(s)
13045
- }, nt.value, { onClick: n(W) }), null, 16, ["disabled", "onClick"]),
13054
+ }, st.value, { onClick: n(W) }), null, 16, ["disabled", "onClick"]),
13046
13055
  p(n(rt), { direction: "vertical" }),
13047
13056
  p(n(Ve), {
13048
13057
  mode: "icon",
@@ -13062,7 +13071,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
13062
13071
  title: "滚动到底部",
13063
13072
  background: "hover",
13064
13073
  disabled: n(s),
13065
- onClick: n(O)
13074
+ onClick: n(j)
13066
13075
  }, null, 8, ["icon", "disabled", "onClick"]),
13067
13076
  p(n(rt), { direction: "vertical" }),
13068
13077
  p(n(Ve), {
@@ -13083,7 +13092,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
13083
13092
  title: "全部展开",
13084
13093
  background: "hover",
13085
13094
  disabled: n(s),
13086
- onClick: n(j)
13095
+ onClick: n(O)
13087
13096
  }, null, 8, ["icon", "disabled", "onClick"]),
13088
13097
  p(n(rt), { direction: "vertical" }),
13089
13098
  p(n(Ve), {
@@ -13153,7 +13162,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
13153
13162
  type: "primary",
13154
13163
  size: "small",
13155
13164
  icon: n(ca),
13156
- onClick: on
13165
+ onClick: an
13157
13166
  }, {
13158
13167
  default: h(() => gt[2] || (gt[2] = [
13159
13168
  X(" 开启新对话 ")
@@ -13207,8 +13216,8 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
13207
13216
  p(pm, {
13208
13217
  current: n(c),
13209
13218
  topics: n(v),
13210
- onNew: on,
13211
- onLoad: gn,
13219
+ onNew: an,
13220
+ onLoad: fn,
13212
13221
  onRemove: n(g)
13213
13222
  }, null, 8, ["current", "topics", "onRemove"])
13214
13223
  ]),
@@ -13254,8 +13263,8 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
13254
13263
  Css: Cd,
13255
13264
  Directives: Ed,
13256
13265
  Defined: Id,
13257
- DataSources: jd,
13258
- Style: Op,
13266
+ DataSources: Od,
13267
+ Style: jp,
13259
13268
  Previewer: Dp,
13260
13269
  NodePath: $p,
13261
13270
  Schema: Np,
@@ -14263,7 +14272,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
14263
14272
  setup(r, { emit: t }) {
14264
14273
  const e = (c = "") => ({
14265
14274
  type: "JSExpression",
14266
- value: en(c) ? c.value : c
14275
+ value: tn(c) ? c.value : c
14267
14276
  }), s = r, o = t, i = (c) => Xe(c, s.context, !0), a = C(e(s.modelValue).value);
14268
14277
  Z(
14269
14278
  () => s.modelValue,
@@ -14322,7 +14331,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
14322
14331
  },
14323
14332
  emits: ["change"],
14324
14333
  setup(r, { emit: t }) {
14325
- const e = r, s = t, o = V(() => en(e.modelValue) ? void 0 : Number(e.modelValue || 0)), i = (a) => {
14334
+ const e = r, s = t, o = V(() => tn(e.modelValue) ? void 0 : Number(e.modelValue || 0)), i = (a) => {
14326
14335
  s("change", a);
14327
14336
  };
14328
14337
  return (a, l) => (u(), y(n(bl), Pe({
@@ -14331,13 +14340,13 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
14331
14340
  "model-value": o.value
14332
14341
  }, a.$attrs, { onChange: i }), null, 16, ["model-value"]));
14333
14342
  }
14334
- }), Ov = /* @__PURE__ */ $({
14343
+ }), jv = /* @__PURE__ */ $({
14335
14344
  name: "ColorSetter",
14336
14345
  __name: "color",
14337
14346
  setup(r) {
14338
14347
  return (t, e) => (u(), y(n(yl), Ro(Io(t.$attrs)), null, 16));
14339
14348
  }
14340
- }), jv = /* @__PURE__ */ $({
14349
+ }), Ov = /* @__PURE__ */ $({
14341
14350
  name: "RadioSetter",
14342
14351
  __name: "radio",
14343
14352
  props: {
@@ -14350,7 +14359,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
14350
14359
  size: "small"
14351
14360
  }, e.$attrs), {
14352
14361
  default: h(() => [
14353
- (u(!0), R(q, null, se(t.options, (o) => (u(), y(n(yn), {
14362
+ (u(!0), R(q, null, se(t.options, (o) => (u(), y(n(_n), {
14354
14363
  label: o.label,
14355
14364
  value: o.value,
14356
14365
  title: o.label
@@ -14866,7 +14875,7 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
14866
14875
  T("div", Fv, [
14867
14876
  p(n(Me), {
14868
14877
  size: s.size,
14869
- "prefix-icon": n(nn),
14878
+ "prefix-icon": n(sn),
14870
14879
  clearable: "",
14871
14880
  modelValue: a.value,
14872
14881
  "onUpdate:modelValue": f[0] || (f[0] = (x) => a.value = x),
@@ -14902,11 +14911,11 @@ const $m = ["innerHTML"], Nm = /* @__PURE__ */ $({
14902
14911
  ExpressionSetter: Tv,
14903
14912
  SelectSetter: Rv,
14904
14913
  NumberSetter: Iv,
14905
- ColorSetter: Ov,
14914
+ ColorSetter: jv,
14906
14915
  IconSetter: fa,
14907
14916
  JsonSetter: Es,
14908
14917
  FunctionSetter: _a,
14909
- RadioSetter: jv,
14918
+ RadioSetter: Ov,
14910
14919
  TagSetter: $v,
14911
14920
  SizeSetter: Ea,
14912
14921
  ImageSetter: Pv,
@@ -15247,7 +15256,7 @@ class eg {
15247
15256
  return Object.values(this.setters).filter((s) => s.type.toLowerCase() === t.toLowerCase()).map((s) => s.name);
15248
15257
  }
15249
15258
  }
15250
- const _n = new eg();
15259
+ const wn = new eg();
15251
15260
  class tg {
15252
15261
  constructor() {
15253
15262
  Q(this, "window");
@@ -15272,7 +15281,7 @@ class tg {
15272
15281
  });
15273
15282
  }
15274
15283
  async load(t) {
15275
- this.enabled && (await Zt(200), this.window && this.appUnmount(this.window), t && this.appInit(t), this.isInited = !0);
15284
+ this.enabled && (await en(200), this.window && this.appUnmount(this.window), t && this.appInit(t), this.isInited = !0);
15276
15285
  }
15277
15286
  updateState(t) {
15278
15287
  t.key === go && (this.isOpen.value = !!this.getState().open);
@@ -15322,7 +15331,7 @@ class tg {
15322
15331
  }
15323
15332
  function ng(r, t) {
15324
15333
  return new Promise((e, s) => {
15325
- const o = Oo(Wu, {
15334
+ const o = jo(Wu, {
15326
15335
  name: r,
15327
15336
  slots: t,
15328
15337
  onClose: () => {
@@ -15366,10 +15375,10 @@ class sg {
15366
15375
  "click",
15367
15376
  this.bind(this.onSelected, "onSelected"),
15368
15377
  !0
15369
- ), je.on(
15378
+ ), Oe.on(
15370
15379
  ks,
15371
15380
  this.bind(this.onActiveChange, "onActiveChange")
15372
- ), je.on(kn, this.bind(this.onViewChange, "onViewChange")), Z(
15381
+ ), Oe.on(Sn, this.bind(this.onViewChange, "onViewChange")), Z(
15373
15382
  this.devtools.isOpen,
15374
15383
  (s) => {
15375
15384
  s && this.cleanHelper();
@@ -15395,11 +15404,11 @@ class sg {
15395
15404
  ), e.removeEventListener(
15396
15405
  "dragstart",
15397
15406
  this.bind(this.onDragStart, "onDragStart")
15398
- ), e.removeEventListener("dragend", this.bind(this.onDragEnd, "onDragEnd")), e.removeEventListener("drop", this.bind(this.onDrop, "onDrop")), e.removeEventListener("click", this.bind(this.onSelected, "onSelected")), je.off(
15407
+ ), e.removeEventListener("dragend", this.bind(this.onDragEnd, "onDragEnd")), e.removeEventListener("drop", this.bind(this.onDrop, "onDrop")), e.removeEventListener("click", this.bind(this.onSelected, "onSelected")), Oe.off(
15399
15408
  ks,
15400
15409
  this.bind(this.onActiveChange, "onActiveChange")
15401
- ), je.off(
15402
- kn,
15410
+ ), Oe.off(
15411
+ Sn,
15403
15412
  this.bind(this.onViewChange, "onViewChange")
15404
15413
  );
15405
15414
  }
@@ -15552,7 +15561,7 @@ class sg {
15552
15561
  this.setSelected(null), this.setHover(null), this.setDragging(null), this.setDropping(null);
15553
15562
  }
15554
15563
  async updateRect() {
15555
- await Zt(100);
15564
+ await en(100);
15556
15565
  const t = n(this.selected), e = n(this.hover);
15557
15566
  if (t) {
15558
15567
  const s = t.el.getBoundingClientRect();
@@ -15574,7 +15583,7 @@ class sg {
15574
15583
  this.lines.value = [];
15575
15584
  return;
15576
15585
  }
15577
- await Zt(50);
15586
+ await en(50);
15578
15587
  const t = this.engine.simulator.renderer?.context?.__refs || {}, e = [], s = Object.keys(vs.nodes);
15579
15588
  for (const o of s) {
15580
15589
  const i = t[o];
@@ -15705,11 +15714,11 @@ class ag {
15705
15714
  });
15706
15715
  }
15707
15716
  getSessionId() {
15708
- let t = dn.get(fo, { type: "session" });
15709
- return t || (t = Ol(), dn.save(fo, t, { type: "session" })), t;
15717
+ let t = pn.get(fo, { type: "session" });
15718
+ return t || (t = jl(), pn.save(fo, t, { type: "session" })), t;
15710
15719
  }
15711
15720
  send(t) {
15712
- const e = this.access.getData(), s = jl(), { href: o, protocol: i, host: a } = location, l = document.referrer, c = Object.assign(
15721
+ const e = this.access.getData(), s = Ol(), { href: o, protocol: i, host: a } = location, l = document.referrer, c = Object.assign(
15713
15722
  {
15714
15723
  ...s,
15715
15724
  url: o,
@@ -15718,7 +15727,7 @@ class ag {
15718
15727
  sessionId: this.getSessionId(),
15719
15728
  userId: e?.id,
15720
15729
  userName: e?.name,
15721
- engineVersion: xn
15730
+ engineVersion: Cn
15722
15731
  },
15723
15732
  t
15724
15733
  ), d = Dl(JSON.stringify(c));
@@ -15739,7 +15748,7 @@ class ag {
15739
15748
  });
15740
15749
  }
15741
15750
  async online() {
15742
- await Zt(5 * 60 * 1e3), this.debounceSend({
15751
+ await en(5 * 60 * 1e3), this.debounceSend({
15743
15752
  type: "online"
15744
15753
  }), this.online();
15745
15754
  }
@@ -15856,7 +15865,7 @@ class lg {
15856
15865
  file: t.toDsl()
15857
15866
  });
15858
15867
  }
15859
- this.context = d, je.on(kn, this.nodeChange), je.on(Ss, this.blockChange);
15868
+ this.context = d, Oe.on(Sn, this.nodeChange), Oe.on(Ss, this.blockChange);
15860
15869
  }
15861
15870
  dispose() {
15862
15871
  if (this.app) {
@@ -15869,7 +15878,7 @@ class lg {
15869
15878
  }
15870
15879
  this.app = null;
15871
15880
  }
15872
- this.dsl = null, this.context = null, this.file = null, ei(), je.off(kn, this.nodeChange), je.off(Ss, this.blockChange);
15881
+ this.dsl = null, this.context = null, this.file = null, ei(), Oe.off(Sn, this.nodeChange), Oe.off(Ss, this.blockChange);
15873
15882
  }
15874
15883
  updateChild(t, e) {
15875
15884
  const s = e.children || e.nodes || [];
@@ -16039,15 +16048,15 @@ class ig extends Go {
16039
16048
  for (const A of f.value) {
16040
16049
  const E = A.names || [];
16041
16050
  if (A.name === zn)
16042
- E.forEach((O) => {
16043
- const j = x.get(O), B = j?.package || "", N = Ml[B], W = m[N];
16044
- W && j && (b[O] = mo(j, W));
16051
+ E.forEach((j) => {
16052
+ const O = x.get(j), B = O?.package || "", N = Ml[B], W = m[N];
16053
+ W && O && (b[j] = mo(O, W));
16045
16054
  });
16046
16055
  else {
16047
- const O = m[s[A.library || ""]];
16048
- O && E.forEach((j) => {
16049
- const B = x.get(j);
16050
- B ? b[j] = mo(B, O) : b[j] = O[j];
16056
+ const j = m[s[A.library || ""]];
16057
+ j && E.forEach((O) => {
16058
+ const B = x.get(O);
16059
+ B ? b[O] = mo(B, j) : b[O] = j[O];
16051
16060
  });
16052
16061
  }
16053
16062
  }
@@ -16155,7 +16164,7 @@ class rg {
16155
16164
  let b = [];
16156
16165
  for (const f of g)
16157
16166
  b = b.concat(
16158
- _n.getByType(f)
16167
+ wn.getByType(f)
16159
16168
  );
16160
16169
  return b;
16161
16170
  }, v = {
@@ -16192,7 +16201,7 @@ class Zg extends Go {
16192
16201
  Q(this, "service");
16193
16202
  Q(this, "assets");
16194
16203
  Q(this, "simulator");
16195
- Q(this, "emitter", je);
16204
+ Q(this, "emitter", Oe);
16196
16205
  Q(this, "project", C(null));
16197
16206
  Q(this, "current", C(null));
16198
16207
  Q(this, "context", C(null));
@@ -16240,7 +16249,7 @@ class Zg extends Go {
16240
16249
  }), this.assets = new rg(this.service, this.provider), this.simulator = new ig({
16241
16250
  engine: this,
16242
16251
  materialPath: d
16243
- }), this.access = b || new ii({ alert: un, ...bc }), this.remote = f, this.report = new ag(f, this.access, this.service), this.checkVersion = x, this.bindEvents(), this.init(i).then(this.render.bind(this)), Ts(this.dispose.bind(this));
16252
+ }), this.access = b || new ii({ alert: dn, ...bc }), this.remote = f, this.report = new ag(f, this.access, this.service), this.checkVersion = x, this.bindEvents(), this.init(i).then(this.render.bind(this)), Ts(this.dispose.bind(this));
16244
16253
  }
16245
16254
  async init(e) {
16246
16255
  const s = await this.service.init(e).catch((o) => (Dt.warn("VTJEngine service init fail.", o), null));
@@ -16254,13 +16263,13 @@ class Zg extends Go {
16254
16263
  render() {
16255
16264
  const e = n(this.container);
16256
16265
  if (e) {
16257
- const s = Oo(cg);
16266
+ const s = jo(cg);
16258
16267
  this.options.install && s.use(this.options.install, this), s.provide(Aa, rl(this)), s.mount(e), this.app = s;
16259
16268
  } else
16260
16269
  Dt.warn("VTJEngine constructor param [ container ] is undefined");
16261
16270
  }
16262
16271
  bindEvents() {
16263
- je.on(Ll, (e) => this.saveProject(e)), je.on(zl, (e) => this.saveBlockFile(e)), je.on(Ul, (e) => this.saveBlockFile(e)), je.on(Fl, () => this.saveMaterials()), je.on(ks, (e) => this.activeFile(e)), je.on(Wl, () => this.publish()), je.on(Jl, () => this.publishCurrent()), je.on(Ss, (e) => this.changeFile(e)), je.on(kn, () => this.changeCurrentFile()), je.on(Hl, (e) => this.saveHistory(e)), je.on(Gl, (e) => this.loadHistory(e)), je.on(ql, () => this.genSource());
16272
+ Oe.on(Ll, (e) => this.saveProject(e)), Oe.on(zl, (e) => this.saveBlockFile(e)), Oe.on(Ul, (e) => this.saveBlockFile(e)), Oe.on(Fl, () => this.saveMaterials()), Oe.on(ks, (e) => this.activeFile(e)), Oe.on(Wl, () => this.publish()), Oe.on(Jl, () => this.publishCurrent()), Oe.on(Ss, (e) => this.changeFile(e)), Oe.on(Sn, () => this.changeCurrentFile()), Oe.on(Hl, (e) => this.saveHistory(e)), Oe.on(Gl, (e) => this.loadHistory(e)), Oe.on(ql, () => this.genSource());
16264
16273
  }
16265
16274
  async activeFile(e) {
16266
16275
  await at();
@@ -16564,7 +16573,7 @@ const Bt = $({
16564
16573
  type: [String, Object, Array],
16565
16574
  required: !0,
16566
16575
  default() {
16567
- return [_n.defaultSetter];
16576
+ return [wn.defaultSetter];
16568
16577
  }
16569
16578
  },
16570
16579
  options: {
@@ -16613,8 +16622,8 @@ const Bt = $({
16613
16622
  defaultSetter() {
16614
16623
  const { value: r, computedSetters: t } = this;
16615
16624
  let e = typeof r;
16616
- e === "object" && (Array.isArray(r) ? e = "array" : en(r) ? e = "object" : ri(r) && (e = "function"));
16617
- const s = _n.getByType(e) || [];
16625
+ e === "object" && (Array.isArray(r) ? e = "array" : tn(r) ? e = "object" : ri(r) && (e = "function"));
16626
+ const s = wn.getByType(e) || [];
16618
16627
  return s.length ? (t.find((o) => s.includes(o.name)) || t[0])?.name : t[0]?.name;
16619
16628
  }
16620
16629
  },
@@ -16653,7 +16662,7 @@ const Bt = $({
16653
16662
  emits: ["change", "remove"],
16654
16663
  methods: {
16655
16664
  getSetter(r) {
16656
- return typeof r == "string" ? _n.get(r) || _n.defaultSetter : r;
16665
+ return typeof r == "string" ? wn.get(r) || wn.defaultSetter : r;
16657
16666
  },
16658
16667
  changeValue(r) {
16659
16668
  this.$emit("change", this.name, r);
@@ -16699,8 +16708,8 @@ const Bt = $({
16699
16708
  onEnd(B, N) {
16700
16709
  c.value = N.elementWidth.value;
16701
16710
  }
16702
- }, g = C(), b = C(), f = C(), x = C(), w = C(), k = C(), _ = C(), A = C(), E = C(!1), O = C(!1);
16703
- return tn(async () => {
16711
+ }, g = C(), b = C(), f = C(), x = C(), w = C(), k = C(), _ = C(), A = C(), E = C(!1), j = C(!1);
16712
+ return nn(async () => {
16704
16713
  await i() || await o(), d();
16705
16714
  }), t({
16706
16715
  brand: g,
@@ -16711,7 +16720,7 @@ const Bt = $({
16711
16720
  settings: k,
16712
16721
  status: _,
16713
16722
  collapsed: E,
16714
- settable: O,
16723
+ settable: j,
16715
16724
  leftWidth: l,
16716
16725
  rightWidth: c,
16717
16726
  preview: A,
@@ -16746,7 +16755,7 @@ const Bt = $({
16746
16755
  }, 8, ["height"]),
16747
16756
  p(n(io), { class: "v-skeleton__wrapper" }, {
16748
16757
  default: h(() => [
16749
- a.value ? I("", !0) : jt((u(), y(n(ro), {
16758
+ a.value ? I("", !0) : Ot((u(), y(n(ro), {
16750
16759
  key: 0,
16751
16760
  width: e.leftWidth,
16752
16761
  class: pe(["v-skeleton__left", {
@@ -16773,17 +16782,17 @@ const Bt = $({
16773
16782
  region: "Preview",
16774
16783
  preview: a.value
16775
16784
  }, null, 8, ["preview"])) : I("", !0),
16776
- jt(p(n(Bt), {
16785
+ Ot(p(n(Bt), {
16777
16786
  ref_key: "workspace",
16778
16787
  ref: w,
16779
16788
  region: "Workspace"
16780
16789
  }, null, 512), [
16781
- [Yt, !a.value]
16790
+ [Zt, !a.value]
16782
16791
  ])
16783
16792
  ]),
16784
16793
  _: 1
16785
16794
  }),
16786
- a.value ? I("", !0) : jt((u(), y(n(ro), {
16795
+ a.value ? I("", !0) : Ot((u(), y(n(ro), {
16787
16796
  key: 1,
16788
16797
  width: e.rightWidth,
16789
16798
  class: "v-skeleton__right"
@@ -16797,7 +16806,7 @@ const Bt = $({
16797
16806
  ]),
16798
16807
  _: 1
16799
16808
  }, 8, ["width"])), [
16800
- [Yt, O.value],
16809
+ [Zt, j.value],
16801
16810
  [n(co), m]
16802
16811
  ])
16803
16812
  ]),
@@ -16847,7 +16856,7 @@ const Bt = $({
16847
16856
  setup(r, { emit: t }) {
16848
16857
  const e = r, s = t, o = C(!1), i = C(""), a = C(
16849
16858
  e.setters.find((k) => k.name === e.defaultSetter) || e.setters[0]
16850
- ), l = C(e.value), c = V(() => !!en(l.value)), d = {
16859
+ ), l = C(e.value), c = V(() => !!tn(l.value)), d = {
16851
16860
  [a.value.name]: l.value
16852
16861
  }, v = (k) => {
16853
16862
  d[a.value.name] = l.value, a.value = k, l.value = d[k.name] ?? void 0, m(l.value);
@@ -16870,13 +16879,13 @@ const Bt = $({
16870
16879
  }, g = () => {
16871
16880
  s("remove", e.name);
16872
16881
  }, b = () => {
16873
- o.value = !0, i.value = en(l.value) ? l.value.value : "";
16882
+ o.value = !0, i.value = tn(l.value) ? l.value.value : "";
16874
16883
  }, f = () => {
16875
16884
  o.value = !1, i.value = "";
16876
16885
  }, x = async (k) => Xe(k, e.context, !0) ? (d[a.value.name] = l.value, l.value = k, s("change", k), !0) : !1, w = async () => {
16877
16886
  await Jt("确定要解除绑定吗?") && (f(), l.value = void 0, s("change", void 0));
16878
16887
  };
16879
- return (k, _) => (u(), y(n(cn), {
16888
+ return (k, _) => (u(), y(n(un), {
16880
16889
  class: "v-setter",
16881
16890
  size: "small",
16882
16891
  "label-positon": "left"
@@ -17113,7 +17122,7 @@ const Bt = $({
17113
17122
  ])
17114
17123
  ]),
17115
17124
  T("div", Rg, [
17116
- (u(!0), R(q, null, se(c.value, (_) => (u(), y(jo, {
17125
+ (u(!0), R(q, null, se(c.value, (_) => (u(), y(Oo, {
17117
17126
  key: _.name
17118
17127
  }, [
17119
17128
  m.value?.name === _.name ? (u(), y(n(Gt), {
@@ -17128,7 +17137,7 @@ const Bt = $({
17128
17137
  ])
17129
17138
  ]));
17130
17139
  }
17131
- }), Og = /* @__PURE__ */ $({
17140
+ }), jg = /* @__PURE__ */ $({
17132
17141
  name: "WorkspaceRegion",
17133
17142
  __name: "workspace",
17134
17143
  props: {
@@ -17158,7 +17167,7 @@ const Bt = $({
17158
17167
  const A = a.find((E) => E.name === _.name);
17159
17168
  A && A.closable && (A.checked = !A.checked, A.checked && (d.value = A.name), !A.checked && d.value === A.name && (d.value = l.value[0]?.name));
17160
17169
  }, f = (_, A = {}) => {
17161
- const E = a.find((O) => O.name === _);
17170
+ const E = a.find((j) => j.name === _);
17162
17171
  E && (E.props = Object.assign({}, E.props, A), E.checked = !0, d.value = E.name);
17163
17172
  }, x = (_) => {
17164
17173
  if (o.value) {
@@ -17208,7 +17217,7 @@ const Bt = $({
17208
17217
  _: 1
17209
17218
  }, 8, ["items", "menus", "modelValue"]));
17210
17219
  }
17211
- }), jg = /* @__PURE__ */ $({
17220
+ }), Og = /* @__PURE__ */ $({
17212
17221
  name: "SettingsRegion",
17213
17222
  __name: "settings",
17214
17223
  props: {
@@ -17389,7 +17398,7 @@ const Bt = $({
17389
17398
  "onUpdate:modelValue": d[0] || (d[0] = (v) => l.value = v)
17390
17399
  }, {
17391
17400
  default: h(() => [
17392
- (u(!0), R(q, null, se(n(s), (v) => (u(), y(jo, {
17401
+ (u(!0), R(q, null, se(n(s), (v) => (u(), y(Oo, {
17393
17402
  key: v.name
17394
17403
  }, [
17395
17404
  l.value === v.name ? (u(), y(n(Gt), {
@@ -17411,8 +17420,8 @@ const Bt = $({
17411
17420
  Toolbar: Sg,
17412
17421
  Actions: Cg,
17413
17422
  Apps: Ig,
17414
- Workspace: Og,
17415
- Settings: jg,
17423
+ Workspace: jg,
17424
+ Settings: Og,
17416
17425
  Status: $g,
17417
17426
  Preview: Ng
17418
17427
  };
@@ -17448,18 +17457,18 @@ export {
17448
17457
  uc as a,
17449
17458
  Jn as a0,
17450
17459
  Zv as a1,
17451
- _n as a2,
17460
+ wn as a2,
17452
17461
  cg as a3,
17453
17462
  Bt as a4,
17454
17463
  Gt as a5,
17455
17464
  re as a6,
17456
- un as a7,
17465
+ dn as a7,
17457
17466
  xe as a8,
17458
17467
  Jt as a9,
17459
17468
  Ne as aa,
17460
17469
  Ic as ab,
17461
17470
  Xe as ac,
17462
- Oc as ad,
17471
+ jc as ad,
17463
17472
  Cs as ae,
17464
17473
  go as b,
17465
17474
  vc as c,
@@ -17481,7 +17490,7 @@ export {
17481
17490
  Se as s,
17482
17491
  Wu as t,
17483
17492
  ha as u,
17484
- xn as v,
17493
+ Cn as v,
17485
17494
  he as w,
17486
17495
  Qg as x,
17487
17496
  kd as y,