@webskill/sdk 0.3.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/dist/browser.d.ts +2 -2
  2. package/dist/browser.js +2 -6
  3. package/dist/{catalogComponents-C_V39rbF-BOHveMWa.js → catalogComponents-KsujmL4b-Clx1kCnU.js} +278 -122
  4. package/dist/{dist-rorEJsNi.js → dist-C-Sh0MDU.js} +498 -282
  5. package/dist/{dist-ZKaM8j06.js → dist-D9Lcn5Pp.js} +527 -837
  6. package/dist/governance.d.ts +45 -10
  7. package/dist/governance.js +151 -24
  8. package/dist/{index-wiV5X8Rz.d.ts → index-CHXxDccV.d.ts} +62 -144
  9. package/dist/{index-8d-oEDww.d.ts → index-DLfR2Y6I.d.ts} +215 -23
  10. package/dist/index.d.ts +3 -3
  11. package/dist/index.js +3 -2
  12. package/dist/mcp.d.ts +2 -2
  13. package/dist/mcp.js +1 -1
  14. package/dist/memoryArtifactStore-BtOeB_hm-tj3fC5ip.js +78 -0
  15. package/dist/node.d.ts +8 -4
  16. package/dist/node.js +1 -1
  17. package/dist/{openUiLibrary-B8-Cvou9-BbpNTXS3.js → openUiLibrary-YLS-cxyT-C96jWDQq.js} +6 -5
  18. package/dist/{skillVersionStore-DOEI9ptb-BxbYL70B.d.ts → skillVersionStore-uyefLPR1-DXOzbksv.d.ts} +41 -10
  19. package/dist/{testing-CsrG3XLz.js → testing-DDCJWvgA.js} +7 -5
  20. package/dist/testing.d.ts +1 -1
  21. package/dist/testing.js +2 -2
  22. package/dist/{types-AmKCKJn_-VGabeXK4.d.ts → types-7Wcg--Vh-1YlQ4jF9.d.ts} +85 -71
  23. package/dist/ui-react.d.ts +329 -18
  24. package/dist/ui-react.js +3714 -3463
  25. package/dist/ui-vue.d.ts +1 -1
  26. package/dist/ui-vue.js +1 -1
  27. package/dist/ui.d.ts +4 -3
  28. package/dist/ui.js +3 -3
  29. package/dist/{webskillLitCatalog-CNaUpasU-BslMcxRZ.js → webskillLitCatalog-CSTbhBe_-CYIs5BX8.js} +312 -122
  30. package/package.json +1 -1
  31. package/dist/jsonRenderRegistry-9GrWP_hE-U6Do3Kid.js +0 -2468
  32. package/dist/memoryArtifactStore-C9lFVqPF-yFz6yJj0.js +0 -48
@@ -1,4 +1,4 @@
1
- import { dt as renderMiniMarkdown, et as A2UI_CHILDREN_PROP, ft as uiCatalog, it as WEBSKILL_A2UI_CATALOG_ID, ot as a2uiComponentShapes, ut as renderMiniChart } from "./dist-ZKaM8j06.js";
1
+ import { G as mountEchart, I as A2UI_CHILDREN_PROP, K as renderMiniMarkdown, U as chartSpecFromProps, V as a2uiComponentShapes, q as uiCatalog, z as WEBSKILL_A2UI_CATALOG_ID } from "./dist-D9Lcn5Pp.js";
2
2
  import { A2uiController, A2uiLitElement } from "@a2ui/lit/v0_9";
3
3
  import { Catalog } from "@a2ui/web_core/v0_9";
4
4
  import { z } from "zod/v3";
@@ -677,21 +677,21 @@ const windowShim = new WindowShim(constructionToken);
677
677
  * Copyright 2019 Google LLC
678
678
  * SPDX-License-Identifier: BSD-3-Clause
679
679
  */
680
- const t$1 = globalThis;
681
- const e$1 = t$1.ShadowRoot && (void 0 === t$1.ShadyCSS || t$1.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype;
682
- const s$2 = Symbol();
683
- const o$3 = /* @__PURE__ */ new WeakMap();
684
- var n$2 = class {
680
+ const t$3 = globalThis;
681
+ const e$3 = t$3.ShadowRoot && (void 0 === t$3.ShadyCSS || t$3.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype;
682
+ const s$4 = Symbol();
683
+ const o$4 = /* @__PURE__ */ new WeakMap();
684
+ var n$4 = class {
685
685
  constructor(t, e, o) {
686
- if (this._$cssResult$ = !0, o !== s$2) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
686
+ if (this._$cssResult$ = !0, o !== s$4) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
687
687
  this.cssText = t, this.t = e;
688
688
  }
689
689
  get styleSheet() {
690
690
  let t = this.o;
691
691
  const s = this.t;
692
- if (e$1 && void 0 === t) {
692
+ if (e$3 && void 0 === t) {
693
693
  const e = void 0 !== s && 1 === s.length;
694
- e && (t = o$3.get(s)), void 0 === t && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), e && o$3.set(s, t));
694
+ e && (t = o$4.get(s)), void 0 === t && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), e && o$4.set(s, t));
695
695
  }
696
696
  return t;
697
697
  }
@@ -699,41 +699,41 @@ var n$2 = class {
699
699
  return this.cssText;
700
700
  }
701
701
  };
702
- const r$2 = (t) => new n$2("string" == typeof t ? t : t + "", void 0, s$2);
703
- const i$2 = (t, ...e) => {
702
+ const r$4 = (t) => new n$4("string" == typeof t ? t : t + "", void 0, s$4);
703
+ const i$4 = (t, ...e) => {
704
704
  const o = 1 === t.length ? t[0] : e.reduce((e, s, o) => e + ((t) => {
705
705
  if (!0 === t._$cssResult$) return t.cssText;
706
706
  if ("number" == typeof t) return t;
707
707
  throw Error("Value passed to 'css' function must be a 'css' function result: " + t + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
708
708
  })(s) + t[o + 1], t[0]);
709
- return new n$2(o, t, s$2);
709
+ return new n$4(o, t, s$4);
710
710
  };
711
711
  const S$1 = (s, o) => {
712
- if (e$1) s.adoptedStyleSheets = o.map((t) => t instanceof CSSStyleSheet ? t : t.styleSheet);
712
+ if (e$3) s.adoptedStyleSheets = o.map((t) => t instanceof CSSStyleSheet ? t : t.styleSheet);
713
713
  else for (const e of o) {
714
- const o = document.createElement("style"), n = t$1.litNonce;
714
+ const o = document.createElement("style"), n = t$3.litNonce;
715
715
  void 0 !== n && o.setAttribute("nonce", n), o.textContent = e.cssText, s.appendChild(o);
716
716
  }
717
717
  };
718
- const c$2 = e$1 || void 0 === t$1.CSSStyleSheet ? (t) => t : (t) => t instanceof CSSStyleSheet ? ((t) => {
718
+ const c$4 = e$3 || void 0 === t$3.CSSStyleSheet ? (t) => t : (t) => t instanceof CSSStyleSheet ? ((t) => {
719
719
  let e = "";
720
720
  for (const s of t.cssRules) e += s.cssText;
721
- return r$2(e);
721
+ return r$4(e);
722
722
  })(t) : t;
723
723
 
724
724
  //#endregion
725
725
  //#region ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/reactive-element.js
726
- const { is: h$1, defineProperty: r$1, getOwnPropertyDescriptor: o$2, getOwnPropertyNames: n$1, getOwnPropertySymbols: a$1, getPrototypeOf: c$1 } = Object, l$1 = globalThis;
727
- l$1.customElements ??= customElements$1;
728
- const p$1 = l$1.trustedTypes;
729
- const d$1 = p$1 ? p$1.emptyScript : "";
730
- const u$1 = l$1.reactiveElementPolyfillSupport;
731
- const f$1 = (t, s) => t;
726
+ const { is: h$3, defineProperty: r$3, getOwnPropertyDescriptor: o$3, getOwnPropertyNames: n$3, getOwnPropertySymbols: a$1, getPrototypeOf: c$3 } = Object, l$2 = globalThis;
727
+ l$2.customElements ??= customElements$1;
728
+ const p$2 = l$2.trustedTypes;
729
+ const d$2 = p$2 ? p$2.emptyScript : "";
730
+ const u$2 = l$2.reactiveElementPolyfillSupport;
731
+ const f$3 = (t, s) => t;
732
732
  const b$1 = {
733
733
  toAttribute(t, s) {
734
734
  switch (s) {
735
735
  case Boolean:
736
- t = t ? d$1 : null;
736
+ t = t ? d$2 : null;
737
737
  break;
738
738
  case Object:
739
739
  case Array: t = null == t ? t : JSON.stringify(t);
@@ -759,16 +759,16 @@ const b$1 = {
759
759
  return i;
760
760
  }
761
761
  };
762
- const m$1 = (t, s) => !h$1(t, s);
762
+ const m$2 = (t, s) => !h$3(t, s);
763
763
  const y$1 = {
764
764
  attribute: !0,
765
765
  type: String,
766
766
  converter: b$1,
767
767
  reflect: !1,
768
768
  useDefault: !1,
769
- hasChanged: m$1
769
+ hasChanged: m$2
770
770
  };
771
- Symbol.metadata ??= Symbol("metadata"), l$1.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
771
+ Symbol.metadata ??= Symbol("metadata"), l$2.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
772
772
  var g$1 = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType) {
773
773
  static addInitializer(t) {
774
774
  this._$Ei(), (this.l ??= []).push(t);
@@ -779,11 +779,11 @@ var g$1 = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType)
779
779
  static createProperty(t, s = y$1) {
780
780
  if (s.state && (s.attribute = !1), this._$Ei(), this.prototype.hasOwnProperty(t) && ((s = Object.create(s)).wrapped = !0), this.elementProperties.set(t, s), !s.noAccessor) {
781
781
  const i = Symbol(), e = this.getPropertyDescriptor(t, i, s);
782
- void 0 !== e && r$1(this.prototype, t, e);
782
+ void 0 !== e && r$3(this.prototype, t, e);
783
783
  }
784
784
  }
785
785
  static getPropertyDescriptor(t, s, i) {
786
- const { get: e, set: h } = o$2(this.prototype, t) ?? {
786
+ const { get: e, set: h } = o$3(this.prototype, t) ?? {
787
787
  get() {
788
788
  return this[s];
789
789
  },
@@ -805,14 +805,14 @@ var g$1 = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType)
805
805
  return this.elementProperties.get(t) ?? y$1;
806
806
  }
807
807
  static _$Ei() {
808
- if (this.hasOwnProperty(f$1("elementProperties"))) return;
809
- const t = c$1(this);
808
+ if (this.hasOwnProperty(f$3("elementProperties"))) return;
809
+ const t = c$3(this);
810
810
  t.finalize(), void 0 !== t.l && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
811
811
  }
812
812
  static finalize() {
813
- if (this.hasOwnProperty(f$1("finalized"))) return;
814
- if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(f$1("properties"))) {
815
- const t = this.properties, s = [...n$1(t), ...a$1(t)];
813
+ if (this.hasOwnProperty(f$3("finalized"))) return;
814
+ if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(f$3("properties"))) {
815
+ const t = this.properties, s = [...n$3(t), ...a$1(t)];
816
816
  for (const i of s) this.createProperty(i, t[i]);
817
817
  }
818
818
  const t = this[Symbol.metadata];
@@ -831,8 +831,8 @@ var g$1 = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType)
831
831
  const s = [];
832
832
  if (Array.isArray(t)) {
833
833
  const e = new Set(t.flat(Infinity).reverse());
834
- for (const t of e) s.unshift(c$2(t));
835
- } else void 0 !== t && s.push(c$2(t));
834
+ for (const t of e) s.unshift(c$4(t));
835
+ } else void 0 !== t && s.push(c$4(t));
836
836
  return s;
837
837
  }
838
838
  static _$Eu(t, s) {
@@ -889,7 +889,7 @@ var g$1 = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType)
889
889
  requestUpdate(t, s, i, e = !1, h) {
890
890
  if (void 0 !== t) {
891
891
  const r = this.constructor;
892
- if (!1 === e && (h = this[t]), i ??= r.getPropertyOptions(t), !((i.hasChanged ?? m$1)(h, s) || i.useDefault && i.reflect && h === this._$Ej?.get(t) && !this.hasAttribute(r._$Eu(t, i)))) return;
892
+ if (!1 === e && (h = this[t]), i ??= r.getPropertyOptions(t), !((i.hasChanged ?? m$2)(h, s) || i.useDefault && i.reflect && h === this._$Ej?.get(t) && !this.hasAttribute(r._$Eu(t, i)))) return;
893
893
  this.C(t, s, i);
894
894
  }
895
895
  !1 === this.isUpdatePending && (this._$ES = this._$EP());
@@ -954,7 +954,7 @@ var g$1 = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType)
954
954
  updated(t) {}
955
955
  firstUpdated(t) {}
956
956
  };
957
- g$1.elementStyles = [], g$1.shadowRootOptions = { mode: "open" }, g$1[f$1("elementProperties")] = /* @__PURE__ */ new Map(), g$1[f$1("finalized")] = /* @__PURE__ */ new Map(), u$1?.({ ReactiveElement: g$1 }), (l$1.reactiveElementVersions ??= []).push("2.1.2");
957
+ g$1.elementStyles = [], g$1.shadowRootOptions = { mode: "open" }, g$1[f$3("elementProperties")] = /* @__PURE__ */ new Map(), g$1[f$3("finalized")] = /* @__PURE__ */ new Map(), u$2?.({ ReactiveElement: g$1 }), (l$2.reactiveElementVersions ??= []).push("2.1.2");
958
958
 
959
959
  //#endregion
960
960
  //#region ../../node_modules/.pnpm/lit-html@3.3.3/node_modules/lit-html/node/lit-html.js
@@ -963,24 +963,24 @@ g$1.elementStyles = [], g$1.shadowRootOptions = { mode: "open" }, g$1[f$1("eleme
963
963
  * Copyright 2017 Google LLC
964
964
  * SPDX-License-Identifier: BSD-3-Clause
965
965
  */
966
- const t = globalThis;
967
- const i$1 = (t) => t;
968
- const s$1 = t.trustedTypes;
969
- const e = s$1 ? s$1.createPolicy("lit-html", { createHTML: (t) => t }) : void 0;
970
- const h = "$lit$";
971
- const o$1 = `lit$${Math.random().toFixed(9).slice(2)}$`;
972
- const n = "?" + o$1;
973
- const r = `<${n}>`;
974
- const l = void 0 === t.document ? { createTreeWalker: () => ({}) } : document;
975
- const c = () => l.createComment("");
966
+ const t$2 = globalThis;
967
+ const i$3 = (t) => t;
968
+ const s$3 = t$2.trustedTypes;
969
+ const e$2 = s$3 ? s$3.createPolicy("lit-html", { createHTML: (t) => t }) : void 0;
970
+ const h$2 = "$lit$";
971
+ const o$2 = `lit$${Math.random().toFixed(9).slice(2)}$`;
972
+ const n$2 = "?" + o$2;
973
+ const r$2 = `<${n$2}>`;
974
+ const l$1 = void 0 === t$2.document ? { createTreeWalker: () => ({}) } : document;
975
+ const c$2 = () => l$1.createComment("");
976
976
  const a = (t) => null === t || "object" != typeof t && "function" != typeof t;
977
- const u = Array.isArray;
978
- const d = (t) => u(t) || "function" == typeof t?.[Symbol.iterator];
979
- const f = "[ \n\f\r]";
980
- const v = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g;
977
+ const u$1 = Array.isArray;
978
+ const d$1 = (t) => u$1(t) || "function" == typeof t?.[Symbol.iterator];
979
+ const f$2 = "[ \n\f\r]";
980
+ const v$1 = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g;
981
981
  const _ = /-->/g;
982
- const m = />/g;
983
- const p = RegExp(`>|${f}(?:([^\\s"'>=/]+)(${f}*=${f}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`, "g");
982
+ const m$1 = />/g;
983
+ const p$1 = RegExp(`>|${f$2}(?:([^\\s"'>=/]+)(${f$2}*=${f$2}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`, "g");
984
984
  const g = /'/g;
985
985
  const $ = /"/g;
986
986
  const y = /^(?:script|style|textarea|title)$/i;
@@ -995,20 +995,20 @@ const w = x(3);
995
995
  const E = Symbol.for("lit-noChange");
996
996
  const A = Symbol.for("lit-nothing");
997
997
  const C = /* @__PURE__ */ new WeakMap();
998
- const P = l.createTreeWalker(l, 129);
998
+ const P = l$1.createTreeWalker(l$1, 129);
999
999
  function V(t, i) {
1000
- if (!u(t) || !t.hasOwnProperty("raw")) throw Error("invalid template strings array");
1001
- return void 0 !== e ? e.createHTML(i) : i;
1000
+ if (!u$1(t) || !t.hasOwnProperty("raw")) throw Error("invalid template strings array");
1001
+ return void 0 !== e$2 ? e$2.createHTML(i) : i;
1002
1002
  }
1003
1003
  const N = (t, i) => {
1004
1004
  const s = t.length - 1, e = [];
1005
- let n, l = 2 === i ? "<svg>" : 3 === i ? "<math>" : "", c = v;
1005
+ let n, l = 2 === i ? "<svg>" : 3 === i ? "<math>" : "", c = v$1;
1006
1006
  for (let i = 0; i < s; i++) {
1007
1007
  const s = t[i];
1008
1008
  let a, u, d = -1, f = 0;
1009
- for (; f < s.length && (c.lastIndex = f, u = c.exec(s), null !== u);) f = c.lastIndex, c === v ? "!--" === u[1] ? c = _ : void 0 !== u[1] ? c = m : void 0 !== u[2] ? (y.test(u[2]) && (n = RegExp("</" + u[2], "g")), c = p) : void 0 !== u[3] && (c = p) : c === p ? ">" === u[0] ? (c = n ?? v, d = -1) : void 0 === u[1] ? d = -2 : (d = c.lastIndex - u[2].length, a = u[1], c = void 0 === u[3] ? p : "\"" === u[3] ? $ : g) : c === $ || c === g ? c = p : c === _ || c === m ? c = v : (c = p, n = void 0);
1010
- const x = c === p && t[i + 1].startsWith("/>") ? " " : "";
1011
- l += c === v ? s + r : d >= 0 ? (e.push(a), s.slice(0, d) + h + s.slice(d) + o$1 + x) : s + o$1 + (-2 === d ? i : x);
1009
+ for (; f < s.length && (c.lastIndex = f, u = c.exec(s), null !== u);) f = c.lastIndex, c === v$1 ? "!--" === u[1] ? c = _ : void 0 !== u[1] ? c = m$1 : void 0 !== u[2] ? (y.test(u[2]) && (n = RegExp("</" + u[2], "g")), c = p$1) : void 0 !== u[3] && (c = p$1) : c === p$1 ? ">" === u[0] ? (c = n ?? v$1, d = -1) : void 0 === u[1] ? d = -2 : (d = c.lastIndex - u[2].length, a = u[1], c = void 0 === u[3] ? p$1 : "\"" === u[3] ? $ : g) : c === $ || c === g ? c = p$1 : c === _ || c === m$1 ? c = v$1 : (c = p$1, n = void 0);
1010
+ const x = c === p$1 && t[i + 1].startsWith("/>") ? " " : "";
1011
+ l += c === v$1 ? s + r$2 : d >= 0 ? (e.push(a), s.slice(0, d) + h$2 + s.slice(d) + o$2 + x) : s + o$2 + (-2 === d ? i : x);
1012
1012
  }
1013
1013
  return [V(t, l + (t[s] || "<?>") + (2 === i ? "</svg>" : 3 === i ? "</math>" : "")), e];
1014
1014
  };
@@ -1024,8 +1024,8 @@ var S = class S {
1024
1024
  }
1025
1025
  for (; null !== (r = P.nextNode()) && d.length < u;) {
1026
1026
  if (1 === r.nodeType) {
1027
- if (r.hasAttributes()) for (const t of r.getAttributeNames()) if (t.endsWith(h)) {
1028
- const i = v[a++], s = r.getAttribute(t).split(o$1), e = /([.?@])?(.*)/.exec(i);
1027
+ if (r.hasAttributes()) for (const t of r.getAttributeNames()) if (t.endsWith(h$2)) {
1028
+ const i = v[a++], s = r.getAttribute(t).split(o$2), e = /([.?@])?(.*)/.exec(i);
1029
1029
  d.push({
1030
1030
  type: 1,
1031
1031
  index: l,
@@ -1033,45 +1033,45 @@ var S = class S {
1033
1033
  strings: s,
1034
1034
  ctor: "." === e[1] ? I : "?" === e[1] ? L : "@" === e[1] ? z$1 : H
1035
1035
  }), r.removeAttribute(t);
1036
- } else t.startsWith(o$1) && (d.push({
1036
+ } else t.startsWith(o$2) && (d.push({
1037
1037
  type: 6,
1038
1038
  index: l
1039
1039
  }), r.removeAttribute(t));
1040
1040
  if (y.test(r.tagName)) {
1041
- const t = r.textContent.split(o$1), i = t.length - 1;
1041
+ const t = r.textContent.split(o$2), i = t.length - 1;
1042
1042
  if (i > 0) {
1043
- r.textContent = s$1 ? s$1.emptyScript : "";
1044
- for (let s = 0; s < i; s++) r.append(t[s], c()), P.nextNode(), d.push({
1043
+ r.textContent = s$3 ? s$3.emptyScript : "";
1044
+ for (let s = 0; s < i; s++) r.append(t[s], c$2()), P.nextNode(), d.push({
1045
1045
  type: 2,
1046
1046
  index: ++l
1047
1047
  });
1048
- r.append(t[i], c());
1048
+ r.append(t[i], c$2());
1049
1049
  }
1050
1050
  }
1051
- } else if (8 === r.nodeType) if (r.data === n) d.push({
1051
+ } else if (8 === r.nodeType) if (r.data === n$2) d.push({
1052
1052
  type: 2,
1053
1053
  index: l
1054
1054
  });
1055
1055
  else {
1056
1056
  let t = -1;
1057
- for (; -1 !== (t = r.data.indexOf(o$1, t + 1));) d.push({
1057
+ for (; -1 !== (t = r.data.indexOf(o$2, t + 1));) d.push({
1058
1058
  type: 7,
1059
1059
  index: l
1060
- }), t += o$1.length - 1;
1060
+ }), t += o$2.length - 1;
1061
1061
  }
1062
1062
  l++;
1063
1063
  }
1064
1064
  }
1065
1065
  static createElement(t, i) {
1066
- const s = l.createElement("template");
1066
+ const s = l$1.createElement("template");
1067
1067
  return s.innerHTML = t, s;
1068
1068
  }
1069
1069
  };
1070
- function M(t, i, s = t, e) {
1070
+ function M$1(t, i, s = t, e) {
1071
1071
  if (i === E) return i;
1072
1072
  let h = void 0 !== e ? s._$Co?.[e] : s._$Cl;
1073
1073
  const o = a(i) ? void 0 : i._$litDirective$;
1074
- return h?.constructor !== o && (h?._$AO?.(!1), void 0 === o ? h = void 0 : (h = new o(t), h._$AT(t, s, e)), void 0 !== e ? (s._$Co ??= [])[e] = h : s._$Cl = h), void 0 !== h && (i = M(t, h._$AS(t, i.values), h, e)), i;
1074
+ return h?.constructor !== o && (h?._$AO?.(!1), void 0 === o ? h = void 0 : (h = new o(t), h._$AT(t, s, e)), void 0 !== e ? (s._$Co ??= [])[e] = h : s._$Cl = h), void 0 !== h && (i = M$1(t, h._$AS(t, i.values), h, e)), i;
1075
1075
  }
1076
1076
  var k = class {
1077
1077
  constructor(t, i) {
@@ -1084,7 +1084,7 @@ var k = class {
1084
1084
  return this._$AM._$AU;
1085
1085
  }
1086
1086
  u(t) {
1087
- const { el: { content: i }, parts: s } = this._$AD, e = (t?.creationScope ?? l).importNode(i, !0);
1087
+ const { el: { content: i }, parts: s } = this._$AD, e = (t?.creationScope ?? l$1).importNode(i, !0);
1088
1088
  P.currentNode = e;
1089
1089
  let h = P.nextNode(), o = 0, n = 0, r = s[0];
1090
1090
  for (; void 0 !== r;) {
@@ -1094,7 +1094,7 @@ var k = class {
1094
1094
  }
1095
1095
  o !== r?.index && (h = P.nextNode(), o++);
1096
1096
  }
1097
- return P.currentNode = l, e;
1097
+ return P.currentNode = l$1, e;
1098
1098
  }
1099
1099
  p(t) {
1100
1100
  let i = 0;
@@ -1120,7 +1120,7 @@ var R = class R {
1120
1120
  return this._$AB;
1121
1121
  }
1122
1122
  _$AI(t, i = this) {
1123
- t = M(this, t, i), a(t) ? t === A || null == t || "" === t ? (this._$AH !== A && this._$AR(), this._$AH = A) : t !== this._$AH && t !== E && this._(t) : void 0 !== t._$litType$ ? this.$(t) : void 0 !== t.nodeType ? this.T(t) : d(t) ? this.k(t) : this._(t);
1123
+ t = M$1(this, t, i), a(t) ? t === A || null == t || "" === t ? (this._$AH !== A && this._$AR(), this._$AH = A) : t !== this._$AH && t !== E && this._(t) : void 0 !== t._$litType$ ? this.$(t) : void 0 !== t.nodeType ? this.T(t) : d$1(t) ? this.k(t) : this._(t);
1124
1124
  }
1125
1125
  O(t) {
1126
1126
  return this._$AA.parentNode.insertBefore(t, this._$AB);
@@ -1129,7 +1129,7 @@ var R = class R {
1129
1129
  this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
1130
1130
  }
1131
1131
  _(t) {
1132
- this._$AH !== A && a(this._$AH) ? this._$AA.nextSibling.data = t : this.T(l.createTextNode(t)), this._$AH = t;
1132
+ this._$AH !== A && a(this._$AH) ? this._$AA.nextSibling.data = t : this.T(l$1.createTextNode(t)), this._$AH = t;
1133
1133
  }
1134
1134
  $(t) {
1135
1135
  const { values: i, _$litType$: s } = t, e = "number" == typeof s ? this._$AC(t) : (void 0 === s.el && (s.el = S.createElement(V(s.h, s.h[0]), this.options)), s);
@@ -1144,16 +1144,16 @@ var R = class R {
1144
1144
  return void 0 === i && C.set(t.strings, i = new S(t)), i;
1145
1145
  }
1146
1146
  k(t) {
1147
- u(this._$AH) || (this._$AH = [], this._$AR());
1147
+ u$1(this._$AH) || (this._$AH = [], this._$AR());
1148
1148
  const i = this._$AH;
1149
1149
  let s, e = 0;
1150
- for (const h of t) e === i.length ? i.push(s = new R(this.O(c()), this.O(c()), this, this.options)) : s = i[e], s._$AI(h), e++;
1150
+ for (const h of t) e === i.length ? i.push(s = new R(this.O(c$2()), this.O(c$2()), this, this.options)) : s = i[e], s._$AI(h), e++;
1151
1151
  e < i.length && (this._$AR(s && s._$AB.nextSibling, e), i.length = e);
1152
1152
  }
1153
1153
  _$AR(t = this._$AA.nextSibling, s) {
1154
1154
  for (this._$AP?.(!1, !0, s); t !== this._$AB;) {
1155
- const s = i$1(t).nextSibling;
1156
- i$1(t).remove(), t = s;
1155
+ const s = i$3(t).nextSibling;
1156
+ i$3(t).remove(), t = s;
1157
1157
  }
1158
1158
  }
1159
1159
  setConnected(t) {
@@ -1173,11 +1173,11 @@ var H = class {
1173
1173
  _$AI(t, i = this, s, e) {
1174
1174
  const h = this.strings;
1175
1175
  let o = !1;
1176
- if (void 0 === h) t = M(this, t, i, 0), o = !a(t) || t !== this._$AH && t !== E, o && (this._$AH = t);
1176
+ if (void 0 === h) t = M$1(this, t, i, 0), o = !a(t) || t !== this._$AH && t !== E, o && (this._$AH = t);
1177
1177
  else {
1178
1178
  const e = t;
1179
1179
  let n, r;
1180
- for (t = h[0], n = 0; n < h.length - 1; n++) r = M(this, e[s + n], i, n), r === E && (r = this._$AH[n]), o ||= !a(r) || r !== this._$AH[n], r === A ? t = A : t !== A && (t += (r ?? "") + h[n + 1]), this._$AH[n] = r;
1180
+ for (t = h[0], n = 0; n < h.length - 1; n++) r = M$1(this, e[s + n], i, n), r === E && (r = this._$AH[n]), o ||= !a(r) || r !== this._$AH[n], r === A ? t = A : t !== A && (t += (r ?? "") + h[n + 1]), this._$AH[n] = r;
1181
1181
  }
1182
1182
  o && !e && this.j(t);
1183
1183
  }
@@ -1206,7 +1206,7 @@ var z$1 = class extends H {
1206
1206
  super(t, i, s, e, h), this.type = 5;
1207
1207
  }
1208
1208
  _$AI(t, i = this) {
1209
- if ((t = M(this, t, i, 0) ?? A) === E) return;
1209
+ if ((t = M$1(this, t, i, 0) ?? A) === E) return;
1210
1210
  const s = this._$AH, e = t === A && s !== A || t.capture !== s.capture || t.once !== s.once || t.passive !== s.passive, h = t !== A && (s === A || e);
1211
1211
  e && this.element.removeEventListener(this.name, this, s), h && this.element.addEventListener(this.name, this, t), this._$AH = t;
1212
1212
  }
@@ -1222,17 +1222,33 @@ var W = class {
1222
1222
  return this._$AM._$AU;
1223
1223
  }
1224
1224
  _$AI(t) {
1225
- M(this, t);
1225
+ M$1(this, t);
1226
1226
  }
1227
1227
  };
1228
- const j = t.litHtmlPolyfillSupport;
1229
- j?.(S, R), (t.litHtmlVersions ??= []).push("3.3.3");
1228
+ const Z = {
1229
+ M: h$2,
1230
+ P: o$2,
1231
+ A: n$2,
1232
+ C: 1,
1233
+ L: N,
1234
+ R: k,
1235
+ D: d$1,
1236
+ V: M$1,
1237
+ I: R,
1238
+ H,
1239
+ N: L,
1240
+ U: z$1,
1241
+ B: I,
1242
+ F: W
1243
+ };
1244
+ const j$1 = t$2.litHtmlPolyfillSupport;
1245
+ j$1?.(S, R), (t$2.litHtmlVersions ??= []).push("3.3.3");
1230
1246
  const B = (t, i, s) => {
1231
1247
  const e = s?.renderBefore ?? i;
1232
1248
  let h = e._$litPart$;
1233
1249
  if (void 0 === h) {
1234
1250
  const t = s?.renderBefore ?? null;
1235
- e._$litPart$ = h = new R(i.insertBefore(c(), t), t, void 0, s ?? {});
1251
+ e._$litPart$ = h = new R(i.insertBefore(c$2(), t), t, void 0, s ?? {});
1236
1252
  }
1237
1253
  return h._$AI(t), h;
1238
1254
  };
@@ -1243,8 +1259,8 @@ const B = (t, i, s) => {
1243
1259
  * @license
1244
1260
  * Copyright 2017 Google LLC
1245
1261
  * SPDX-License-Identifier: BSD-3-Clause
1246
- */ const s = globalThis;
1247
- var i = class extends g$1 {
1262
+ */ const s$2 = globalThis;
1263
+ var i$2 = class extends g$1 {
1248
1264
  constructor() {
1249
1265
  super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
1250
1266
  }
@@ -1266,20 +1282,189 @@ var i = class extends g$1 {
1266
1282
  return E;
1267
1283
  }
1268
1284
  };
1269
- i._$litElement$ = !0, i["finalized"] = !0, s.litElementHydrateSupport?.({ LitElement: i });
1270
- const o = s.litElementPolyfillSupport;
1271
- o?.({ LitElement: i });
1272
- (s.litElementVersions ??= []).push("4.2.2");
1285
+ i$2._$litElement$ = !0, i$2["finalized"] = !0, s$2.litElementHydrateSupport?.({ LitElement: i$2 });
1286
+ const o$1 = s$2.litElementPolyfillSupport;
1287
+ o$1?.({ LitElement: i$2 });
1288
+ (s$2.litElementVersions ??= []).push("4.2.2");
1273
1289
 
1274
1290
  //#endregion
1275
- //#region ../ui/dist/webskillLitCatalog-CNaUpasU.js
1291
+ //#region ../../node_modules/.pnpm/lit-html@3.3.3/node_modules/lit-html/node/directive-helpers.js
1292
+ /**
1293
+ * @license
1294
+ * Copyright 2020 Google LLC
1295
+ * SPDX-License-Identifier: BSD-3-Clause
1296
+ */ const { I: t$1 } = Z, i$1 = (o) => o, n$1 = (o) => null === o || "object" != typeof o && "function" != typeof o, e$1 = {
1297
+ HTML: 1,
1298
+ SVG: 2,
1299
+ MATHML: 3
1300
+ }, l = (o, t) => void 0 === t ? void 0 !== o?._$litType$ : o?._$litType$ === t, d = (o) => null != o?._$litType$?.h, c$1 = (o) => void 0 !== o?._$litDirective$, f$1 = (o) => o?._$litDirective$, r$1 = (o) => void 0 === o.strings, s$1 = () => document.createComment(""), v = (o, n, e) => {
1301
+ const l = o._$AA.parentNode, d = void 0 === n ? o._$AB : n._$AA;
1302
+ if (void 0 === e) {
1303
+ const i = l.insertBefore(s$1(), d), n = l.insertBefore(s$1(), d);
1304
+ e = new t$1(i, n, o, o.options);
1305
+ } else {
1306
+ const t = e._$AB.nextSibling, n = e._$AM, c = n !== o;
1307
+ if (c) {
1308
+ let t;
1309
+ e._$AQ?.(o), e._$AM = o, void 0 !== e._$AP && (t = o._$AU) !== n._$AU && e._$AP(t);
1310
+ }
1311
+ if (t !== d || c) {
1312
+ let o = e._$AA;
1313
+ for (; o !== t;) {
1314
+ const t = i$1(o).nextSibling;
1315
+ i$1(l).insertBefore(o, d), o = t;
1316
+ }
1317
+ }
1318
+ }
1319
+ return e;
1320
+ }, u = (o, t, i = o) => (o._$AI(t, i), o), m = {}, p = (o, t = m) => o._$AH = t, M = (o) => o._$AH, h$1 = (o) => {
1321
+ o._$AR(), o._$AA.remove();
1322
+ }, j = (o) => {
1323
+ o._$AR();
1324
+ };
1325
+
1326
+ //#endregion
1327
+ //#region ../../node_modules/.pnpm/lit-html@3.3.3/node_modules/lit-html/node/directive.js
1328
+ /**
1329
+ * @license
1330
+ * Copyright 2017 Google LLC
1331
+ * SPDX-License-Identifier: BSD-3-Clause
1332
+ */
1333
+ const t = {
1334
+ ATTRIBUTE: 1,
1335
+ CHILD: 2,
1336
+ PROPERTY: 3,
1337
+ BOOLEAN_ATTRIBUTE: 4,
1338
+ EVENT: 5,
1339
+ ELEMENT: 6
1340
+ };
1341
+ const e = (t) => (...e) => ({
1342
+ _$litDirective$: t,
1343
+ values: e
1344
+ });
1345
+ var i = class {
1346
+ constructor(t) {}
1347
+ get _$AU() {
1348
+ return this._$AM._$AU;
1349
+ }
1350
+ _$AT(t, e, i) {
1351
+ this._$Ct = t, this._$AM = e, this._$Ci = i;
1352
+ }
1353
+ _$AS(t, e) {
1354
+ return this.update(t, e);
1355
+ }
1356
+ update(t, e) {
1357
+ return this.render(...e);
1358
+ }
1359
+ };
1360
+
1361
+ //#endregion
1362
+ //#region ../../node_modules/.pnpm/lit-html@3.3.3/node_modules/lit-html/node/async-directive.js
1363
+ /**
1364
+ * @license
1365
+ * Copyright 2017 Google LLC
1366
+ * SPDX-License-Identifier: BSD-3-Clause
1367
+ */ const s = (i, t) => {
1368
+ const e = i._$AN;
1369
+ if (void 0 === e) return !1;
1370
+ for (const i of e) i._$AO?.(t, !1), s(i, t);
1371
+ return !0;
1372
+ };
1373
+ const o = (i) => {
1374
+ let t, e;
1375
+ do {
1376
+ if (void 0 === (t = i._$AM)) break;
1377
+ e = t._$AN, e.delete(i), i = t;
1378
+ } while (0 === e?.size);
1379
+ };
1380
+ const r = (i) => {
1381
+ for (let t; t = i._$AM; i = t) {
1382
+ let e = t._$AN;
1383
+ if (void 0 === e) t._$AN = e = /* @__PURE__ */ new Set();
1384
+ else if (e.has(i)) break;
1385
+ e.add(i), c(t);
1386
+ }
1387
+ };
1388
+ function h(i) {
1389
+ void 0 !== this._$AN ? (o(this), this._$AM = i, r(this)) : this._$AM = i;
1390
+ }
1391
+ function n(i, t = !1, e = 0) {
1392
+ const r = this._$AH, h = this._$AN;
1393
+ if (void 0 !== h && 0 !== h.size) if (t) if (Array.isArray(r)) for (let i = e; i < r.length; i++) s(r[i], !1), o(r[i]);
1394
+ else null != r && (s(r, !1), o(r));
1395
+ else s(this, i);
1396
+ }
1397
+ const c = (i) => {
1398
+ i.type == t.CHILD && (i._$AP ??= n, i._$AQ ??= h);
1399
+ };
1400
+ var f = class extends i {
1401
+ constructor() {
1402
+ super(...arguments), this._$AN = void 0;
1403
+ }
1404
+ _$AT(i, t, e) {
1405
+ super._$AT(i, t, e), r(this), this.isConnected = i._$AU;
1406
+ }
1407
+ _$AO(i, t = !0) {
1408
+ i !== this.isConnected && (this.isConnected = i, i ? this.reconnected?.() : this.disconnected?.()), t && (s(this, i), o(this));
1409
+ }
1410
+ setValue(t) {
1411
+ if (r$1(this._$Ct)) this._$Ct._$AI(t, this);
1412
+ else {
1413
+ const i = [...this._$Ct._$AH];
1414
+ i[this._$Ci] = t, this._$Ct._$AI(i, this, 0);
1415
+ }
1416
+ }
1417
+ disconnected() {}
1418
+ reconnected() {}
1419
+ };
1420
+
1421
+ //#endregion
1422
+ //#region ../ui/dist/webskillLitCatalog-CSTbhBe_.js
1423
+ /**
1424
+ * Lit 元素上的 echarts 挂载指令。
1425
+ * A2UI 档的 catalog `Chart` 渲染在 shadow root 里,实例必须随元素断开而 dispose,
1426
+ * 否则每次声明树重渲染都会留下一个仍在监听 resize 的 echarts 实例。
1427
+ */
1428
+ var EchartDirective = class extends f {
1429
+ #element;
1430
+ #handle;
1431
+ #chart;
1432
+ constructor(partInfo) {
1433
+ super(partInfo);
1434
+ if (partInfo.type !== t.ELEMENT) throw new Error("echart() must be used as an element directive");
1435
+ }
1436
+ render(_chart) {
1437
+ return A;
1438
+ }
1439
+ update(part, [chart]) {
1440
+ const element = part.element;
1441
+ if (this.#element !== element) {
1442
+ this.#handle?.dispose();
1443
+ this.#element = element;
1444
+ this.#handle = mountEchart(element);
1445
+ }
1446
+ this.#chart = chart;
1447
+ this.#handle?.setChart(chart);
1448
+ return A;
1449
+ }
1450
+ disconnected() {
1451
+ this.#handle?.dispose();
1452
+ this.#handle = void 0;
1453
+ }
1454
+ reconnected() {
1455
+ if (!this.#element || !this.#chart) return;
1456
+ this.#handle = mountEchart(this.#element);
1457
+ this.#handle.setChart(this.#chart);
1458
+ }
1459
+ };
1460
+ const echart = e(EchartDirective);
1276
1461
  /** 自定义元素 tag 前缀(同一文档里与 A2UI Basic Catalog 的 `a2ui-basic-*` 互不冲突) */
1277
1462
  const WEBSKILL_A2UI_TAG_PREFIX = "webskill-a2ui";
1278
1463
  /**
1279
1464
  * ui-kit 设计 token 是 `:root` 上的 CSS 自定义属性,CSS 变量天然继承进 shadow root,
1280
1465
  * 因此这些元素直接消费 `var(--border)` 等 token,亮暗切换随宿主 `.dark` 生效。
1281
1466
  */
1282
- const sharedStyles = i$2`
1467
+ const sharedStyles = i$4`
1283
1468
  :host {
1284
1469
  display: block;
1285
1470
  color: var(--foreground);
@@ -1342,13 +1527,28 @@ const sharedStyles = i$2`
1342
1527
  .metric strong {
1343
1528
  font-size: 1.125rem;
1344
1529
  }
1345
- table {
1530
+ /* 与 native 档的 .webskill-surface__chart 同尺寸:echarts 需要容器有显式高度才能测量 */
1531
+ .chart {
1346
1532
  width: 100%;
1533
+ height: 20rem;
1534
+ min-height: 14rem;
1535
+ }
1536
+ /* 与 native 档的 DataTable 同构:外框拥有边框与横向溢出,单元格宽度下限一致 */
1537
+ .table-frame {
1538
+ max-height: 22.5rem;
1539
+ overflow: auto;
1540
+ border: 1px solid var(--border);
1541
+ border-radius: var(--radius);
1542
+ }
1543
+ table {
1544
+ width: max-content;
1545
+ min-width: 100%;
1347
1546
  border-collapse: collapse;
1348
1547
  font-size: 0.8125rem;
1349
1548
  }
1350
1549
  th,
1351
1550
  td {
1551
+ min-width: 8rem;
1352
1552
  border-bottom: 1px solid var(--border);
1353
1553
  padding: 0.375rem 0.5rem;
1354
1554
  text-align: left;
@@ -1404,18 +1604,6 @@ const list = (value) => Array.isArray(value) ? value : [];
1404
1604
  function children(props, host) {
1405
1605
  return (props.children ?? []).map((ref) => host.renderChild(ref));
1406
1606
  }
1407
- function chartSpec(props) {
1408
- const series = list(props["series"]);
1409
- return {
1410
- kind: str(props, "type", "bar"),
1411
- labels: list(props["labels"]),
1412
- series: series.map((item) => ({
1413
- name: item.name,
1414
- data: item.values
1415
- })),
1416
- ...props["title"] ? { title: str(props, "title") } : {}
1417
- };
1418
- }
1419
1607
  /**
1420
1608
  * 16 个组件的 Lit 渲染实现。语义(标题层级、table/th/td、label、button、role=alert)
1421
1609
  * 与 React 三档共用的 `catalogComponentImpls` 对齐——像素可不同,语义不可不同。
@@ -1447,20 +1635,22 @@ const renderers = {
1447
1635
  </div>
1448
1636
  `,
1449
1637
  Table: (props) => T`
1450
- <table aria-label=${str(props, "title", "Data")}>
1451
- <thead>
1452
- <tr>
1453
- ${list(props["columns"]).map((column) => T`<th scope="col">${column}</th>`)}
1454
- </tr>
1455
- </thead>
1456
- <tbody>
1457
- ${list(props["rows"]).map((row) => T`<tr>
1458
- ${list(row).map((cell) => T`<td>${String(cell ?? "")}</td>`)}
1459
- </tr>`)}
1460
- </tbody>
1461
- </table>
1638
+ <div class="table-frame" data-webskill-data-table="">
1639
+ <table aria-label=${str(props, "title", "Data")}>
1640
+ <thead>
1641
+ <tr>
1642
+ ${list(props["columns"]).map((column) => T`<th scope="col">${column}</th>`)}
1643
+ </tr>
1644
+ </thead>
1645
+ <tbody>
1646
+ ${list(props["rows"]).map((row) => T`<tr>
1647
+ ${list(row).map((cell) => T`<td>${String(cell ?? "")}</td>`)}
1648
+ </tr>`)}
1649
+ </tbody>
1650
+ </table>
1651
+ </div>
1462
1652
  `,
1463
- Chart: (props) => renderMiniChart(chartSpec(props), document),
1653
+ Chart: (props) => T`<div class="chart" ${echart(chartSpecFromProps(props))}></div>`,
1464
1654
  FileLink: (props) => T`<p>${str(props, "label", str(props, "path"))}</p>`,
1465
1655
  Form: (props, host) => T`
1466
1656
  <form @submit=${(event) => event.preventDefault()}>