xmlui 0.9.90 → 0.9.93

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 (49) hide show
  1. package/dist/lib/{index-Bs4hp2dn.mjs → index-C4FeLQEv.mjs} +7988 -7791
  2. package/dist/lib/index.css +1 -1
  3. package/dist/lib/{initMock-DwAYhsKb.mjs → initMock-DwQKZ8T4.mjs} +1 -1
  4. package/dist/lib/language-server-web-worker.mjs +1 -1
  5. package/dist/lib/language-server.mjs +1 -1
  6. package/dist/lib/{metadata-utils-DJhOKFL6.mjs → metadata-utils-PjrGUxZN.mjs} +47 -49
  7. package/dist/lib/{server-common-CIqrGYx-.mjs → server-common-BbjTO8TH.mjs} +4446 -4476
  8. package/dist/lib/{transform-bUuxPyao.mjs → transform-CDSgqN5L.mjs} +1240 -1202
  9. package/dist/lib/xmlui-parser.d.ts +3 -1
  10. package/dist/lib/xmlui-parser.mjs +2 -2
  11. package/dist/lib/{xmlui-serializer-BLFl30t9.mjs → xmlui-serializer-D6rtRMNI.mjs} +1 -1
  12. package/dist/lib/xmlui.d.ts +17 -12
  13. package/dist/lib/xmlui.mjs +2 -2
  14. package/dist/metadata/{collectedComponentMetadata-fh2ak2QN.mjs → collectedComponentMetadata-CTFECKPI.mjs} +8885 -8651
  15. package/dist/metadata/{initMock-8hLEm7iV.mjs → initMock-DUtrSCpH.mjs} +1 -1
  16. package/dist/metadata/style.css +1 -1
  17. package/dist/metadata/xmlui-metadata.mjs +1 -1
  18. package/dist/metadata/xmlui-metadata.umd.js +102 -98
  19. package/dist/scripts/package.json +2 -1
  20. package/dist/scripts/src/components/AutoComplete/AutoComplete.js +5 -2
  21. package/dist/scripts/src/components/AutoComplete/AutoCompleteContext.js +1 -2
  22. package/dist/scripts/src/components/AutoComplete/AutoCompleteNative.js +9 -12
  23. package/dist/scripts/src/components/Bookmark/Bookmark.js +1 -1
  24. package/dist/scripts/src/components/ComponentProvider.js +2 -2
  25. package/dist/scripts/src/{components-core → components/Fragment}/Fragment.js +2 -2
  26. package/dist/scripts/src/components/Option/Option.js +11 -11
  27. package/dist/scripts/src/components/Select/HiddenOption.js +2 -2
  28. package/dist/scripts/src/components/Select/Select.js +5 -9
  29. package/dist/scripts/src/components/Select/SelectNative.js +95 -45
  30. package/dist/scripts/src/{components-core → components/Slot}/Slot.js +2 -2
  31. package/dist/scripts/src/components/SlotItem.js +1 -0
  32. package/dist/scripts/src/components/Spinner/SpinnerNative.js +3 -4
  33. package/dist/scripts/src/components/Tabs/TabItem.js +12 -1
  34. package/dist/scripts/src/components/Tabs/TabItemNative.js +4 -3
  35. package/dist/scripts/src/components/Tabs/Tabs.js +1 -1
  36. package/dist/scripts/src/components/Tabs/TabsNative.js +22 -43
  37. package/dist/scripts/src/components/TextArea/TextArea.js +1 -2
  38. package/dist/scripts/src/components/Toggle/Toggle.js +34 -10
  39. package/dist/scripts/src/components/abstractions.js +25 -6
  40. package/dist/scripts/src/components/container-helpers.js +2 -1
  41. package/dist/scripts/src/components-core/rendering/ComponentAdapter.js +4 -5
  42. package/dist/scripts/src/components-core/rendering/ComponentWrapper.js +2 -1
  43. package/dist/scripts/src/components-core/xmlui-parser.js +365 -196
  44. package/dist/scripts/src/parsers/xmlui-parser/diagnostics.js +1 -1
  45. package/dist/scripts/src/parsers/xmlui-parser/parser.js +69 -1
  46. package/dist/standalone/xmlui-standalone.es.d.ts +18 -12
  47. package/dist/standalone/xmlui-standalone.umd.js +252 -248
  48. package/package.json +2 -1
  49. package/dist/scripts/src/abstractions/scripting/modules.js +0 -2
@@ -503,7 +503,7 @@ export declare const DIAGS: {
503
503
  readonly unexpectedCloseTag: {
504
504
  readonly category: DiagnosticCategory.Error;
505
505
  readonly code: ErrCodes.unexpectedCloseTag;
506
- readonly message: "Read '</', but there's no opening tag to close. You have too many closing tags.";
506
+ readonly message: "Read '</', but there's no opening tag to close.";
507
507
  };
508
508
  readonly expCloseStartWithName: (openTagName: string) => {
509
509
  category: DiagnosticCategory;
@@ -642,6 +642,8 @@ declare interface Error_2 {
642
642
  readonly message: string;
643
643
  readonly pos: number;
644
644
  readonly end: number;
645
+ readonly contextPos: number;
646
+ readonly contextEnd: number;
645
647
  }
646
648
  export { Error_2 as Error }
647
649
 
@@ -1,5 +1,5 @@
1
- import { q as s, s as t, A as i, t as r, v as n, C as o, r as d, a as g, b as m, f as C, e as p, g as l, c as N, D as _, o as D, E as c, N as E, P as S, S as x, T as U, U as A, j as L, h as P, d as f, i as y, B as u, n as b, k as h, m as M, l as v, w as I, u as O, p as T, x as K, z as R, y as X } from "./transform-bUuxPyao.mjs";
2
- import { b as F, L as B, X as j, a as q, c as w, g as z, e as G, l as H, d as V, m as W, p as J } from "./xmlui-serializer-BLFl30t9.mjs";
1
+ import { q as s, s as t, A as i, t as r, v as n, C as o, r as d, a as g, b as m, f as C, e as p, g as l, c as N, D as _, o as D, E as c, N as E, P as S, S as x, T as U, U as A, j as L, h as P, d as f, i as y, B as u, n as b, k as h, m as M, l as v, w as I, u as O, p as T, x as K, z as R, y as X } from "./transform-CDSgqN5L.mjs";
2
+ import { b as F, L as B, X as j, a as q, c as w, g as z, e as G, l as H, d as V, m as W, p as J } from "./xmlui-serializer-D6rtRMNI.mjs";
3
3
  export {
4
4
  s as AttributeKeyNode,
5
5
  t as AttributeListNode,
@@ -1,4 +1,4 @@
1
- import { v as A, t as j } from "./transform-bUuxPyao.mjs";
1
+ import { v as A, t as j } from "./transform-CDSgqN5L.mjs";
2
2
  const k = "xmlui", P = "xmlui.xs", D = "xs";
3
3
  var V = /* @__PURE__ */ ((l) => (l[l.Skip = 0] = "Skip", l[l.Warning = 1] = "Warning", l[l.Error = 2] = "Error", l))(V || {}), w = /* @__PURE__ */ ((l) => (l[l.UnrecognisedProp = 0] = "UnrecognisedProp", l))(w || {});
4
4
  function L(l) {
@@ -636,6 +636,8 @@ declare interface Error_2 {
636
636
  readonly message: string;
637
637
  readonly pos: number;
638
638
  readonly end: number;
639
+ readonly contextPos: number;
640
+ readonly contextEnd: number;
639
641
  }
640
642
 
641
643
  /**
@@ -673,15 +675,14 @@ export declare class ErrorBoundary extends default_2.Component<Props, State> {
673
675
  render(): string | number | boolean | Iterable<default_2.ReactNode> | JSX_2.Element;
674
676
  }
675
677
 
676
- declare interface ErrorWithLineColInfo extends Error_2 {
677
- line: number;
678
- col: number;
678
+ declare interface ErrorForDisplay extends Error_2 {
679
+ contextStartLine: number;
680
+ contextSource: string;
681
+ errPosLine: number;
682
+ errPosCol: number;
679
683
  }
680
684
 
681
- /** returns a component definition containing the errors.
682
- * It is a component and a compound component definition at the same time,
683
- * so that it can be used to render the errors for a compound component as well*/
684
- export declare function errReportComponent(errors: ErrorWithLineColInfo[], fileName: number | string, compoundCompName: string | undefined): any;
685
+ export declare function errReportComponent(errors: ErrorForDisplay[], fileName: number | string, compoundCompName: string | undefined): any;
685
686
 
686
687
  declare type Expression = UnaryExpression | BinaryExpression | SequenceExpression | ConditionalExpression | FunctionInvocationExpression | MemberAccessExpression | CalculatedMemberAccessExpression | Identifier | TemplateLiteralExpression | Literal | ArrayLiteral | ObjectLiteral | SpreadExpression | AssignmentExpression | NoArgExpression | ArrowExpression | PrefixOpExpression | PostfixOpExpression | ReactiveVarDeclaration | VarDeclaration | Destructure | ObjectDestructure | ArrayDestructure | SwitchCase;
687
688
 
@@ -1005,6 +1006,12 @@ declare interface ParentRenderContext {
1005
1006
  props?: Record<string, any>;
1006
1007
  }
1007
1008
 
1009
+ declare type ParserResult = {
1010
+ component: null | ComponentDef | CompoundComponentDef;
1011
+ errors: ErrorForDisplay[];
1012
+ erroneousCompoundComponentName?: string;
1013
+ };
1014
+
1008
1015
  /**
1009
1016
  * This function extracts CSS variables from the specified SCSS input. It uses a hack to convert the CSS input to JSON
1010
1017
  * and then calls a JSON parser to create the desired object.
@@ -1068,6 +1075,7 @@ declare type Props_2 = {
1068
1075
  };
1069
1076
 
1070
1077
  declare type Props_3 = {
1078
+ id?: string;
1071
1079
  activeTab?: number;
1072
1080
  orientation?: "horizontal" | "vertical";
1073
1081
  tabRenderer?: (item: {
@@ -1454,6 +1462,7 @@ declare const T_WHILE_STATEMENT: number;
1454
1462
 
1455
1463
  declare type Tab = {
1456
1464
  label: string;
1465
+ labelRenderer?: (contextVars: any) => ReactNode;
1457
1466
  children?: ReactNode;
1458
1467
  style?: CSSProperties;
1459
1468
  };
@@ -1871,11 +1880,7 @@ export declare class XmlUiHelper {
1871
1880
  private addComponentList;
1872
1881
  }
1873
1882
 
1874
- export declare function xmlUiMarkupToComponent(source: string, fileId?: string | number): {
1875
- component: null | ComponentDef | CompoundComponentDef;
1876
- errors: ErrorWithLineColInfo[];
1877
- erroneousCompoundComponentName?: string;
1878
- };
1883
+ export declare function xmlUiMarkupToComponent(source: string, fileId?: string | number): ParserResult;
1879
1884
 
1880
1885
  export declare type XmlUiNode = XmlUiComment | XmlUiAttribute | XmlUiElement;
1881
1886
 
@@ -1,5 +1,5 @@
1
- import { y as e, A as t, B as o, E as r, I as n, L as p, J as u, N as i, z as l, i as m, h as C, S as d, b as x, k as T, l as c, F as S, G as A, H as g, V as h, D as v, c as B, e as I, f as L, w as b, j as k, p as y, s as E, t as M, M as V, n as f, q as H, O as N, v as R, K as D, u as U, C as X, x as j } from "./index-Bs4hp2dn.mjs";
2
- import { X as w } from "./xmlui-serializer-BLFl30t9.mjs";
1
+ import { y as e, A as t, B as o, E as r, I as n, L as p, J as u, N as i, z as l, i as m, h as C, S as d, b as x, k as T, l as c, F as S, G as A, H as g, V as h, D as v, c as B, e as I, f as L, w as b, j as k, p as y, s as E, t as M, M as V, n as f, q as H, O as N, v as R, K as D, u as U, C as X, x as j } from "./index-C4FeLQEv.mjs";
2
+ import { X as w } from "./xmlui-serializer-D6rtRMNI.mjs";
3
3
  export {
4
4
  e as ApiInterceptorProvider,
5
5
  t as AppRoot,