xmlui 0.11.23 → 0.11.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin/index.cjs +24 -22
- package/dist/bin/index.js +7 -5
- package/dist/lib/{index-Dh3wc_JX.js → index-9UB61miF.js} +1515 -1171
- package/dist/lib/index.css +1 -1
- package/dist/lib/{initMock-BE0szWSR.js → initMock-DppAqVHs.js} +1 -1
- package/dist/lib/language-server-web-worker.js +1 -1
- package/dist/lib/language-server.js +1 -1
- package/dist/lib/{metadata-utils-ow3vRMof.js → metadata-utils-X4ryJQBa.js} +1 -1
- package/dist/lib/{server-common-DjRwBoWi.js → server-common-BZY2B446.js} +2464 -1296
- package/dist/lib/syntax-textmate.d.ts +1 -1
- package/dist/lib/syntax-textmate.js +1 -1
- package/dist/lib/testing.d.ts +8 -1
- package/dist/lib/testing.js +1 -1
- package/dist/lib/{transform-vby4pBMJ.js → transform-FiPBuy3W.js} +6 -2
- package/dist/lib/vite-xmlui-plugin.js +4 -2
- package/dist/lib/{xmlui-parser-B2m1xG6D.js → xmlui-parser-DXCqrM50.js} +1 -1
- package/dist/lib/xmlui-parser.d.ts +8 -1
- package/dist/lib/xmlui-parser.js +2 -2
- package/dist/lib/{xmlui-serializer-DeegIW2y.js → xmlui-serializer-D4ixnQay.js} +1 -1
- package/dist/lib/xmlui.d.ts +15 -5
- package/dist/lib/xmlui.js +65 -64
- package/dist/metadata/{collectedComponentMetadata-BFVjl5S6.js → collectedComponentMetadata-CkHQSF65.js} +1443 -1103
- package/dist/metadata/{initMock-CyVKxVyG.js → initMock-KBzfT81H.js} +1 -1
- package/dist/metadata/xmlui-metadata.css +1 -1
- package/dist/metadata/xmlui-metadata.js +1 -1
- package/dist/metadata/xmlui-metadata.umd.cjs +3 -3
- package/dist/standalone/xmlui-standalone.es.d.ts +17 -5
- package/dist/standalone/xmlui-standalone.umd.js +8 -8
- package/package.json +1 -1
- package/src/syntax/textMate/xmlui.tmLanguage.json +1 -1
|
@@ -239,7 +239,7 @@ export declare const xmluiGrammar: {
|
|
|
239
239
|
"patterns": [{ "include": "#attribute" }, { "include": "#comments" }]
|
|
240
240
|
},
|
|
241
241
|
"componentTag": {
|
|
242
|
-
"begin": "(\\s
|
|
242
|
+
"begin": "(\\s*</?\\s*)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)([a-zA-Z][\\w\\.\\-]*)",
|
|
243
243
|
"beginCaptures": {
|
|
244
244
|
"1": { "name": "punctuation.definition.tag.xmlui" },
|
|
245
245
|
"2": { "name": "keyword.operator.namespace.xmlui" },
|
|
@@ -31,7 +31,7 @@ const xmlui = {
|
|
|
31
31
|
const name = "xmlui";
|
|
32
32
|
const scopeName = "source.xmlui";
|
|
33
33
|
const patterns = [{ "include": "#root" }];
|
|
34
|
-
const repository = { "root": { "patterns": [{ "include": "#comments" }, { "include": "#helperTag" }, { "include": "#componentTag" }, { "include": "#entity" }, { "include": "#textWithBindingExpr" }, { "begin": "(<!\\[)(CDATA)(\\[)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "storage.xmlui" }, "3": { "name": "punctuation.definition.tag.xmlui" } }, "end": "]]>", "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "contentName": "string.unquoted.cdata.xmlui" }] }, "methodTag": { "begin": "(<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(method)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "applyEndPatternLast": "1", "patterns": [{ "include": "#comments" }, { "include": "#valueAttributeScriptInside" }, { "include": "#attribute" }, { "begin": "(?<!/|(?:/\\s*(?:method))\\s*)>", "beginCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "contentName": "meta.embedded.block.javascript", "patterns": [{ "include": "source.js" }], "end": "(</)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(method)(?=\\s*>)" }], "end": "/?>" }, "eventTag": { "begin": "(<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(event)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "applyEndPatternLast": "1", "patterns": [{ "include": "#comments" }, { "include": "#valueAttributeScriptInside" }, { "include": "#attribute" }, { "begin": "(?<!/|(?:/\\s*event)\\s*)(>)", "beginCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "patterns": [{ "include": "#comments" }, { "include": "#componentTag" }, { "include": "source.js" }], "end": "(</)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(event)(?=\\s*>)" }], "end": ">" }, "fieldTag": { "begin": "(<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(field)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "applyEndPatternLast": "1", "patterns": [{ "include": "#comments" }, { "include": "#valueAttributeScriptInside" }, { "include": "#attribute" }, { "begin": "(?<!/|(?:/\\s*field)\\s*)(>)", "beginCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "patterns": [{ "include": "#comments" }, { "include": "#componentTag" }, { "include": "source.js" }], "end": "(</)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(field)(?=\\s*>)" }], "end": ">" }, "itemTag": { "begin": "(<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(item)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "applyEndPatternLast": "1", "patterns": [{ "include": "#comments" }, { "include": "#valueAttributeScriptInside" }, { "include": "#attribute" }, { "begin": "(?<!/|(?:/\\s*item)\\s*)(>)", "beginCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "patterns": [{ "include": "#comments" }, { "include": "#componentTag" }, { "include": "source.js" }], "end": "(</)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(item)(?=\\s*>)" }], "end": ">" }, "bindingExpr": { "contentName": "meta.embedded.block.javascript", "begin": "\\{", "end": "\\}", "beginCaptures": { "0": { "name": "entity.name.function.xmlui punctuation.definition.block.xmlui" } }, "endCaptures": { "0": { "name": "entity.name.function.xmlui punctuation.definition.block.xmlui" } }, "patterns": [{ "include": "source.js" }] }, "helperTag": { "patterns": [{ "include": "#scriptTag" }, { "include": "#eventTag" }, { "include": "#fieldTag" }, { "include": "#itemTag" }, { "include": "#methodTag" }, { "include": "#propOrVarTag" }] }, "valueAttributeScriptInside": { "patterns": [{ "captures": { "1": { "name": "entity.other.attribute-name.localname.xmlui" }, "2": { "name": "keyword.operator.xmlui" } }, "match": "(?:^|\\s+)(value)(\\s*=)" }, { "include": "#quotedStringJsInside" }] }, "scriptTag": { "begin": "(\\s*<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(script)(\\s*>)", "end": "(\\s*</)(\\2)(\\3)(\\s*>)", "contentName": "meta.embedded.block.javascript", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.function.xmlui" }, "4": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.function.xmlui" }, "4": { "name": "punctuation.definition.tag.xmlui" } }, "patterns": [{ "include": "source.js" }] }, "textWithBindingExpr": { "patterns": [{ "include": "#entity" }, { "match": "\\\\{" }, { "include": "#bindingExpr" }] }, "propOrVarTag": { "begin": "(</?)([a-zA-Z_][\\w\\.\\-]*?:)?((?:variable)|(?:property)|(?:prop))", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "end": "(/?>)", "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" } }, "patterns": [{ "include": "#attribute" }, { "include": "#comments" }] }, "componentTag": { "begin": "(\\s
|
|
34
|
+
const repository = { "root": { "patterns": [{ "include": "#comments" }, { "include": "#helperTag" }, { "include": "#componentTag" }, { "include": "#entity" }, { "include": "#textWithBindingExpr" }, { "begin": "(<!\\[)(CDATA)(\\[)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "storage.xmlui" }, "3": { "name": "punctuation.definition.tag.xmlui" } }, "end": "]]>", "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "contentName": "string.unquoted.cdata.xmlui" }] }, "methodTag": { "begin": "(<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(method)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "applyEndPatternLast": "1", "patterns": [{ "include": "#comments" }, { "include": "#valueAttributeScriptInside" }, { "include": "#attribute" }, { "begin": "(?<!/|(?:/\\s*(?:method))\\s*)>", "beginCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "contentName": "meta.embedded.block.javascript", "patterns": [{ "include": "source.js" }], "end": "(</)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(method)(?=\\s*>)" }], "end": "/?>" }, "eventTag": { "begin": "(<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(event)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "applyEndPatternLast": "1", "patterns": [{ "include": "#comments" }, { "include": "#valueAttributeScriptInside" }, { "include": "#attribute" }, { "begin": "(?<!/|(?:/\\s*event)\\s*)(>)", "beginCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "patterns": [{ "include": "#comments" }, { "include": "#componentTag" }, { "include": "source.js" }], "end": "(</)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(event)(?=\\s*>)" }], "end": ">" }, "fieldTag": { "begin": "(<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(field)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "applyEndPatternLast": "1", "patterns": [{ "include": "#comments" }, { "include": "#valueAttributeScriptInside" }, { "include": "#attribute" }, { "begin": "(?<!/|(?:/\\s*field)\\s*)(>)", "beginCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "patterns": [{ "include": "#comments" }, { "include": "#componentTag" }, { "include": "source.js" }], "end": "(</)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(field)(?=\\s*>)" }], "end": ">" }, "itemTag": { "begin": "(<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(item)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "endCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "applyEndPatternLast": "1", "patterns": [{ "include": "#comments" }, { "include": "#valueAttributeScriptInside" }, { "include": "#attribute" }, { "begin": "(?<!/|(?:/\\s*item)\\s*)(>)", "beginCaptures": { "0": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "patterns": [{ "include": "#comments" }, { "include": "#componentTag" }, { "include": "source.js" }], "end": "(</)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(item)(?=\\s*>)" }], "end": ">" }, "bindingExpr": { "contentName": "meta.embedded.block.javascript", "begin": "\\{", "end": "\\}", "beginCaptures": { "0": { "name": "entity.name.function.xmlui punctuation.definition.block.xmlui" } }, "endCaptures": { "0": { "name": "entity.name.function.xmlui punctuation.definition.block.xmlui" } }, "patterns": [{ "include": "source.js" }] }, "helperTag": { "patterns": [{ "include": "#scriptTag" }, { "include": "#eventTag" }, { "include": "#fieldTag" }, { "include": "#itemTag" }, { "include": "#methodTag" }, { "include": "#propOrVarTag" }] }, "valueAttributeScriptInside": { "patterns": [{ "captures": { "1": { "name": "entity.other.attribute-name.localname.xmlui" }, "2": { "name": "keyword.operator.xmlui" } }, "match": "(?:^|\\s+)(value)(\\s*=)" }, { "include": "#quotedStringJsInside" }] }, "scriptTag": { "begin": "(\\s*<)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)(script)(\\s*>)", "end": "(\\s*</)(\\2)(\\3)(\\s*>)", "contentName": "meta.embedded.block.javascript", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.function.xmlui" }, "4": { "name": "punctuation.definition.tag.xmlui" } }, "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.function.xmlui" }, "4": { "name": "punctuation.definition.tag.xmlui" } }, "patterns": [{ "include": "source.js" }] }, "textWithBindingExpr": { "patterns": [{ "include": "#entity" }, { "match": "\\\\{" }, { "include": "#bindingExpr" }] }, "propOrVarTag": { "begin": "(</?)([a-zA-Z_][\\w\\.\\-]*?:)?((?:variable)|(?:property)|(?:prop))", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "entity.name.tag.localname.xmlui" } }, "end": "(/?>)", "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" } }, "patterns": [{ "include": "#attribute" }, { "include": "#comments" }] }, "componentTag": { "begin": "(\\s*</?\\s*)((?:[a-zA-Z_][\\w\\.\\-]*?:)?)([a-zA-Z][\\w\\.\\-]*)", "beginCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" }, "2": { "name": "keyword.operator.namespace.xmlui" }, "3": { "name": "support.class.tag.component.xmlui" } }, "end": "(/?>)", "endCaptures": { "1": { "name": "punctuation.definition.tag.xmlui" } }, "patterns": [{ "include": "#comments" }, { "include": "#eventHandler" }, { "include": "#attribute" }] }, "quotedStringJsInside": { "begin": "\"|'|`", "beginCaptures": { "0": { "name": "string.xmlui" } }, "end": "\\0", "endCaptures": { "0": { "name": "string.xmlui" } }, "contentName": "meta.embedded.block.javascript", "patterns": [{ "include": "source.js" }] }, "entity": { "captures": { "1": { "name": "punctuation.definition.constant.xmlui" }, "2": { "name": "punctuation.definition.constant.xmlui" }, "3": { "name": "punctuation.definition.constant.xmlui" } }, "match": "(&)((?:amp)|(?:lt)|(?:gt)|(?:quot)|(?:apos))(;)" }, "eventHandler": { "patterns": [{ "captures": { "1": { "name": "entity.other.attribute-name.localname.xmlui" }, "2": { "name": "keyword.operator.xmlui" } }, "match": "(?:^|\\s+)(on[A-Z][-\\w.:$]*)(\\s*=)" }, { "include": "#quotedStringJsInside" }] }, "attribute": { "patterns": [{ "begin": "(?:^|\\s+)((?:[a-zA-Z$_][-\\w.$]*:)?)([a-zA-Z$_][-\\w.$]*)(\\s*=\\s*)(['\"`])", "end": "\\4", "beginCaptures": { "1": { "name": "keyword.operator.namespace.xmlui" }, "2": { "name": "entity.other.attribute-name.localname.xmlui" }, "3": { "name": "keyword.operator.xmlui" }, "4": { "name": "string.xmlui" } }, "endCaptures": { "0": { "name": "string.xmlui" } }, "contentName": "string.xmlui", "patterns": [{ "include": "#textWithBindingExpr" }] }, { "match": "(?:^|\\s+)((?:[a-zA-Z$_][-\\w.$]*:)?)([a-zA-Z$_][-\\w.$]*)(\\s*=\\s*)([a-zA-Z$_][-\\w.$]*)", "captures": { "1": { "name": "keyword.operator.namespace.xmlui" }, "2": { "name": "entity.other.attribute-name.localname.xmlui" }, "3": { "name": "keyword.operator.xmlui" }, "4": { "name": "string.xmlui" } } }, { "match": "(?:^|\\s+)((?:[a-zA-Z$_][-\\w.$]*:)?)([a-zA-Z$_][-\\w.$]*)", "name": "entity.other.attribute-name.localname.xmlui", "captures": { "1": { "name": "keyword.operator.namespace.xmlui" }, "2": { "name": "entity.other.attribute-name.localname.xmlui" } } }] }, "comments": { "patterns": [{ "begin": "<!--", "captures": { "0": { "name": "punctuation.definition.comment.xmlui" } }, "end": "-->", "name": "comment.block.xmlui" }] } };
|
|
35
35
|
const xmlui_tmLanguage = {
|
|
36
36
|
name,
|
|
37
37
|
scopeName,
|
package/dist/lib/testing.d.ts
CHANGED
|
@@ -224,6 +224,7 @@ declare type CollectedDeclarations = {
|
|
|
224
224
|
vars: Record<string, CodeDeclaration>;
|
|
225
225
|
functions: Record<string, CodeDeclaration>;
|
|
226
226
|
moduleErrors?: ModuleErrors;
|
|
227
|
+
hasInvalidStatements?: boolean;
|
|
227
228
|
};
|
|
228
229
|
|
|
229
230
|
declare type ComponentApiMetadata = {
|
|
@@ -345,9 +346,15 @@ declare type ComponentDriverParams = {
|
|
|
345
346
|
page: Page_2;
|
|
346
347
|
};
|
|
347
348
|
|
|
349
|
+
declare type ComponentEventMetadata = {
|
|
350
|
+
readonly description: string;
|
|
351
|
+
readonly signature?: string;
|
|
352
|
+
readonly parameters?: Record<string, string>;
|
|
353
|
+
};
|
|
354
|
+
|
|
348
355
|
declare type ComponentLike = ComponentDef | CompoundComponentDef;
|
|
349
356
|
|
|
350
|
-
declare type ComponentMetadata<TProps extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TEvents extends Record<string,
|
|
357
|
+
declare type ComponentMetadata<TProps extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TEvents extends Record<string, ComponentEventMetadata> = Record<string, any>, TContextValues extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TApis extends Record<string, ComponentApiMetadata> = Record<string, any>> = {
|
|
351
358
|
status?: "stable" | "experimental" | "deprecated" | "in progress" | "internal";
|
|
352
359
|
description?: string;
|
|
353
360
|
shortDescription?: string;
|
package/dist/lib/testing.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { expect as expect$1, test as test$1 } from "@playwright/test";
|
|
2
|
-
import { x as xmlUiMarkupToComponent, P as PART_START_ADORNMENT, a as PART_END_ADORNMENT, b as PART_INPUT } from "./xmlui-parser-
|
|
2
|
+
import { x as xmlUiMarkupToComponent, P as PART_START_ADORNMENT, a as PART_END_ADORNMENT, b as PART_INPUT } from "./xmlui-parser-DXCqrM50.js";
|
|
3
3
|
import "chroma-js";
|
|
4
4
|
function parseComponentIfNecessary(rawComponent) {
|
|
5
5
|
if (typeof rawComponent === "string") {
|
|
@@ -6188,7 +6188,8 @@ function collectCodeBehindFromSource(moduleName, source) {
|
|
|
6188
6188
|
const result = {
|
|
6189
6189
|
vars: {},
|
|
6190
6190
|
moduleErrors: {},
|
|
6191
|
-
functions: {}
|
|
6191
|
+
functions: {},
|
|
6192
|
+
hasInvalidStatements: false
|
|
6192
6193
|
};
|
|
6193
6194
|
const collectedFunctions = {};
|
|
6194
6195
|
const parsedModule = parseScriptModule(moduleName, source);
|
|
@@ -6212,7 +6213,7 @@ function collectCodeBehindFromSource(moduleName, source) {
|
|
|
6212
6213
|
addFunctionDeclaration(stmt);
|
|
6213
6214
|
break;
|
|
6214
6215
|
default:
|
|
6215
|
-
|
|
6216
|
+
result.hasInvalidStatements = true;
|
|
6216
6217
|
}
|
|
6217
6218
|
});
|
|
6218
6219
|
return result;
|
|
@@ -6603,6 +6604,9 @@ function nodeToComponentDef(node, originalGetText, fileId) {
|
|
|
6603
6604
|
try {
|
|
6604
6605
|
parser.parseStatements();
|
|
6605
6606
|
comp.scriptCollected = collectCodeBehindFromSource("Main", comp.script);
|
|
6607
|
+
if (comp.scriptCollected.hasInvalidStatements) {
|
|
6608
|
+
comp.scriptError = new Error(`Only reactive variable and function definitions are allowed in a code-behind module.`);
|
|
6609
|
+
}
|
|
6606
6610
|
} catch (err) {
|
|
6607
6611
|
if (parser.errors && parser.errors.length > 0) {
|
|
6608
6612
|
const errMsg = parser.errors[0];
|
|
@@ -5707,7 +5707,8 @@ function collectCodeBehindFromSource(moduleName, source) {
|
|
|
5707
5707
|
const result = {
|
|
5708
5708
|
vars: {},
|
|
5709
5709
|
moduleErrors: {},
|
|
5710
|
-
functions: {}
|
|
5710
|
+
functions: {},
|
|
5711
|
+
hasInvalidStatements: false
|
|
5711
5712
|
};
|
|
5712
5713
|
const collectedFunctions = {};
|
|
5713
5714
|
const parsedModule = parseScriptModule(moduleName, source);
|
|
@@ -5729,7 +5730,7 @@ function collectCodeBehindFromSource(moduleName, source) {
|
|
|
5729
5730
|
case T_FUNCTION_DECLARATION:
|
|
5730
5731
|
addFunctionDeclaration(stmt);
|
|
5731
5732
|
break;
|
|
5732
|
-
default:
|
|
5733
|
+
default: result.hasInvalidStatements = true;
|
|
5733
5734
|
}
|
|
5734
5735
|
});
|
|
5735
5736
|
return result;
|
|
@@ -7309,6 +7310,7 @@ function nodeToComponentDef(node, originalGetText, fileId) {
|
|
|
7309
7310
|
try {
|
|
7310
7311
|
parser.parseStatements();
|
|
7311
7312
|
comp.scriptCollected = collectCodeBehindFromSource("Main", comp.script);
|
|
7313
|
+
if (comp.scriptCollected.hasInvalidStatements) comp.scriptError = /* @__PURE__ */ new Error(`Only reactive variable and function definitions are allowed in a code-behind module.`);
|
|
7312
7314
|
} catch (err) {
|
|
7313
7315
|
if (parser.errors && parser.errors.length > 0) {
|
|
7314
7316
|
const errMsg = parser.errors[0];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { h as createXmlUiParser, w as nodeToComponentDef, D as DiagnosticCategory, E as ErrCodes, S as SyntaxKind } from "./transform-
|
|
1
|
+
import { h as createXmlUiParser, w as nodeToComponentDef, D as DiagnosticCategory, E as ErrCodes, S as SyntaxKind } from "./transform-FiPBuy3W.js";
|
|
2
2
|
const PART_LABEL = "label";
|
|
3
3
|
const PART_LABELED_ITEM = "labeledItem";
|
|
4
4
|
const PART_INPUT = "input";
|
|
@@ -244,6 +244,7 @@ declare type CollectedDeclarations = {
|
|
|
244
244
|
vars: Record<string, CodeDeclaration>;
|
|
245
245
|
functions: Record<string, CodeDeclaration>;
|
|
246
246
|
moduleErrors?: ModuleErrors;
|
|
247
|
+
hasInvalidStatements?: boolean;
|
|
247
248
|
};
|
|
248
249
|
|
|
249
250
|
declare type ComponentApiMetadata = {
|
|
@@ -329,6 +330,12 @@ declare interface ComponentDefCore {
|
|
|
329
330
|
debug?: Record<string, any>;
|
|
330
331
|
}
|
|
331
332
|
|
|
333
|
+
declare type ComponentEventMetadata = {
|
|
334
|
+
readonly description: string;
|
|
335
|
+
readonly signature?: string;
|
|
336
|
+
readonly parameters?: Record<string, string>;
|
|
337
|
+
};
|
|
338
|
+
|
|
332
339
|
export declare const componentFileExtension = "xmlui";
|
|
333
340
|
|
|
334
341
|
declare type ComponentLike = ComponentDef | CompoundComponentDef;
|
|
@@ -341,7 +348,7 @@ export declare type ComponentLints = {
|
|
|
341
348
|
componentName: string;
|
|
342
349
|
};
|
|
343
350
|
|
|
344
|
-
declare type ComponentMetadata<TProps extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TEvents extends Record<string,
|
|
351
|
+
declare type ComponentMetadata<TProps extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TEvents extends Record<string, ComponentEventMetadata> = Record<string, any>, TContextValues extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TApis extends Record<string, ComponentApiMetadata> = Record<string, any>> = {
|
|
345
352
|
status?: "stable" | "experimental" | "deprecated" | "in progress" | "internal";
|
|
346
353
|
description?: string;
|
|
347
354
|
shortDescription?: string;
|
package/dist/lib/xmlui-parser.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { q, s, A, t, v, C, r, a, b, f, e, g, c, D, o, E, N, P, S, T, U, j, h, d, i, B, n, k, m, l, w, u, p, x, z, y } from "./transform-
|
|
2
|
-
import { b as b2, L, X, a as a2, c as c2, g as g2, e as e2, l as l2, d as d2, m as m2, p as p2 } from "./xmlui-serializer-
|
|
1
|
+
import { q, s, A, t, v, C, r, a, b, f, e, g, c, D, o, E, N, P, S, T, U, j, h, d, i, B, n, k, m, l, w, u, p, x, z, y } from "./transform-FiPBuy3W.js";
|
|
2
|
+
import { b as b2, L, X, a as a2, c as c2, g as g2, e as e2, l as l2, d as d2, m as m2, p as p2 } from "./xmlui-serializer-D4ixnQay.js";
|
|
3
3
|
export {
|
|
4
4
|
q as AttributeKeyNode,
|
|
5
5
|
s as AttributeListNode,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { v as CORE_NAMESPACE_VALUE, t as COMPOUND_COMP_ID } from "./transform-
|
|
1
|
+
import { v as CORE_NAMESPACE_VALUE, t as COMPOUND_COMP_ID } from "./transform-FiPBuy3W.js";
|
|
2
2
|
const componentFileExtension = "xmlui";
|
|
3
3
|
const codeBehindFileExtension = "xmlui.xs";
|
|
4
4
|
const moduleFileExtension = "xs";
|
package/dist/lib/xmlui.d.ts
CHANGED
|
@@ -375,6 +375,7 @@ declare type CollectedDeclarations = {
|
|
|
375
375
|
vars: Record<string, CodeDeclaration>;
|
|
376
376
|
functions: Record<string, CodeDeclaration>;
|
|
377
377
|
moduleErrors?: ModuleErrors;
|
|
378
|
+
hasInvalidStatements?: boolean;
|
|
378
379
|
};
|
|
379
380
|
|
|
380
381
|
declare type ColorDef = {
|
|
@@ -488,11 +489,17 @@ declare interface ComponentDefCore {
|
|
|
488
489
|
debug?: Record<string, any>;
|
|
489
490
|
}
|
|
490
491
|
|
|
492
|
+
declare type ComponentEventMetadata = {
|
|
493
|
+
readonly description: string;
|
|
494
|
+
readonly signature?: string;
|
|
495
|
+
readonly parameters?: Record<string, string>;
|
|
496
|
+
};
|
|
497
|
+
|
|
491
498
|
declare type ComponentExtension = ComponentRendererDef | CompoundComponentRendererInfo;
|
|
492
499
|
|
|
493
500
|
export declare type ComponentLike = ComponentDef | CompoundComponentDef;
|
|
494
501
|
|
|
495
|
-
export declare type ComponentMetadata<TProps extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TEvents extends Record<string,
|
|
502
|
+
export declare type ComponentMetadata<TProps extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TEvents extends Record<string, ComponentEventMetadata> = Record<string, any>, TContextValues extends Record<string, ComponentPropertyMetadata> = Record<string, any>, TApis extends Record<string, ComponentApiMetadata> = Record<string, any>> = {
|
|
496
503
|
status?: "stable" | "experimental" | "deprecated" | "in progress" | "internal";
|
|
497
504
|
description?: string;
|
|
498
505
|
shortDescription?: string;
|
|
@@ -645,13 +652,13 @@ export declare function d(description: string, availableValues?: readonly Proper
|
|
|
645
652
|
|
|
646
653
|
export declare function dAutoFocus(): ComponentPropertyMetadata;
|
|
647
654
|
|
|
648
|
-
export declare function dClick(comp: string):
|
|
655
|
+
export declare function dClick(comp: string): ComponentEventMetadata;
|
|
649
656
|
|
|
650
657
|
export declare function dCollapse(comp: string): ComponentPropertyMetadata;
|
|
651
658
|
|
|
652
659
|
export declare function dComponent(description: string): ComponentPropertyMetadata;
|
|
653
660
|
|
|
654
|
-
export declare function dDidChange(comp: string):
|
|
661
|
+
export declare function dDidChange(comp: string): ComponentEventMetadata;
|
|
655
662
|
|
|
656
663
|
export declare function dDidClose(comp: string): ComponentPropertyMetadata;
|
|
657
664
|
|
|
@@ -687,7 +694,7 @@ export declare function dExpanded(comp: string): ComponentPropertyMetadata;
|
|
|
687
694
|
|
|
688
695
|
export declare function dFocus(comp: string): ComponentPropertyMetadata;
|
|
689
696
|
|
|
690
|
-
export declare function dGotFocus(comp: string):
|
|
697
|
+
export declare function dGotFocus(comp: string): ComponentEventMetadata;
|
|
691
698
|
|
|
692
699
|
declare enum DiagnosticCategory {
|
|
693
700
|
Error = 1,
|
|
@@ -698,6 +705,8 @@ declare enum DiagnosticCategory {
|
|
|
698
705
|
|
|
699
706
|
export declare function dIndeterminate(defaultValue?: boolean): ComponentPropertyMetadata;
|
|
700
707
|
|
|
708
|
+
export declare function dInit(comp: string): ComponentEventMetadata;
|
|
709
|
+
|
|
701
710
|
export declare function dInitialValue(value?: any): ComponentPropertyMetadata;
|
|
702
711
|
|
|
703
712
|
export declare function dInternal(description?: string): ComponentPropertyMetadata;
|
|
@@ -710,7 +719,7 @@ export declare function dLabelPosition(def?: string): ComponentPropertyMetadata;
|
|
|
710
719
|
|
|
711
720
|
export declare function dLabelWidth(comp: string): ComponentPropertyMetadata;
|
|
712
721
|
|
|
713
|
-
export declare function dLostFocus(comp: string):
|
|
722
|
+
export declare function dLostFocus(comp: string): ComponentEventMetadata;
|
|
714
723
|
|
|
715
724
|
export declare function dMaxLength(): ComponentPropertyMetadata;
|
|
716
725
|
|
|
@@ -983,6 +992,7 @@ declare interface IAppLayoutContext {
|
|
|
983
992
|
scrollWholePage?: boolean;
|
|
984
993
|
isFullVerticalWidth?: boolean;
|
|
985
994
|
isNested?: boolean;
|
|
995
|
+
setScrollRestorationEnabled?: (enabled: boolean) => void;
|
|
986
996
|
}
|
|
987
997
|
|
|
988
998
|
export declare const Icon: default_2.ForwardRefExoticComponent<IconBaseProps & default_2.RefAttributes<HTMLElement>>;
|
package/dist/lib/xmlui.js
CHANGED
|
@@ -1,39 +1,39 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { f as f2, x as x2 } from "./xmlui-parser-
|
|
3
|
-
import { X as X2 } from "./xmlui-serializer-
|
|
1
|
+
import { ab, _, am, a2, ay, aw, $, a0, aj, al, az, ax, ah, ac, a3, a1, S, as, b, ap, aq, a5, a6, af, ag, at, ak, au, av, ai, ae, c, f, e, h, j, k, l, i, n, p, q, s, u, v, x, w, t, y, z, A, B, C, D, E, F, G, H, I, J, K, L, M, N, Q, O, P, R, U, V, W, a4, X, Y, a8, ao, a7, a9, ar, aa, an, Z, ad } from "./index-9UB61miF.js";
|
|
2
|
+
import { f as f2, x as x2 } from "./xmlui-parser-DXCqrM50.js";
|
|
3
|
+
import { X as X2 } from "./xmlui-serializer-D4ixnQay.js";
|
|
4
4
|
export {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
5
|
+
ab as ApiInterceptorProvider,
|
|
6
|
+
_ as AppRoot,
|
|
7
|
+
am as Breakout,
|
|
8
|
+
a2 as Button,
|
|
9
|
+
ay as ContentSeparator,
|
|
10
|
+
aw as DropdownMenu,
|
|
11
|
+
$ as ErrorBoundary,
|
|
12
|
+
a0 as Icon,
|
|
13
|
+
aj as LinkNative,
|
|
14
|
+
al as Logo,
|
|
15
|
+
az as MemoizedItem,
|
|
16
|
+
ax as MenuItem,
|
|
17
|
+
ah as NestedApp,
|
|
18
|
+
ac as Spinner,
|
|
19
|
+
a3 as Splitter,
|
|
20
|
+
a1 as Stack,
|
|
21
21
|
S as StandaloneApp,
|
|
22
|
-
|
|
22
|
+
as as StandaloneComponent,
|
|
23
23
|
b as StandaloneExtensionManager,
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
24
|
+
ap as StyleProvider,
|
|
25
|
+
aq as StyleRegistry,
|
|
26
|
+
a5 as TabItem,
|
|
27
|
+
a6 as Tabs,
|
|
28
|
+
af as Text,
|
|
29
|
+
ag as TextBox,
|
|
30
|
+
at as Theme,
|
|
31
|
+
ak as ToneChangerButton,
|
|
32
|
+
au as ToneSwitch,
|
|
33
|
+
av as Tooltip,
|
|
34
|
+
ai as VisuallyHidden,
|
|
35
35
|
X2 as XmlUiHelper,
|
|
36
|
-
|
|
36
|
+
ae as builtInThemes,
|
|
37
37
|
c as createComponentRenderer,
|
|
38
38
|
f as createMetadata,
|
|
39
39
|
e as createUserDefinedComponentRenderer,
|
|
@@ -53,38 +53,39 @@ export {
|
|
|
53
53
|
t as dFocus,
|
|
54
54
|
y as dGotFocus,
|
|
55
55
|
z as dIndeterminate,
|
|
56
|
-
A as
|
|
57
|
-
B as
|
|
58
|
-
C as
|
|
59
|
-
D as
|
|
60
|
-
E as
|
|
61
|
-
F as
|
|
62
|
-
G as
|
|
63
|
-
H as
|
|
64
|
-
I as
|
|
65
|
-
J as
|
|
66
|
-
K as
|
|
67
|
-
L as
|
|
68
|
-
M as
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
O as
|
|
72
|
-
|
|
73
|
-
R as
|
|
74
|
-
U as
|
|
75
|
-
V as
|
|
56
|
+
A as dInit,
|
|
57
|
+
B as dInitialValue,
|
|
58
|
+
C as dInternal,
|
|
59
|
+
D as dLabel,
|
|
60
|
+
E as dLabelBreak,
|
|
61
|
+
F as dLabelPosition,
|
|
62
|
+
G as dLabelWidth,
|
|
63
|
+
H as dLostFocus,
|
|
64
|
+
I as dMaxLength,
|
|
65
|
+
J as dMulti,
|
|
66
|
+
K as dOrientation,
|
|
67
|
+
L as dPlaceholder,
|
|
68
|
+
M as dReadonly,
|
|
69
|
+
N as dRequired,
|
|
70
|
+
Q as dSetValueApi,
|
|
71
|
+
O as dStartIcon,
|
|
72
|
+
P as dStartText,
|
|
73
|
+
R as dTriggerTemplate,
|
|
74
|
+
U as dValidationStatus,
|
|
75
|
+
V as dValue,
|
|
76
|
+
W as dValueApi,
|
|
76
77
|
f2 as errReportComponent,
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
78
|
+
a4 as getColor,
|
|
79
|
+
X as parseScssVar,
|
|
80
|
+
Y as startApp,
|
|
81
|
+
a8 as toCssVar,
|
|
82
|
+
ao as useAppLayoutContext,
|
|
83
|
+
a7 as useColors,
|
|
84
|
+
a9 as useDevTools,
|
|
85
|
+
ar as useEvent,
|
|
86
|
+
aa as useLogger,
|
|
87
|
+
an as useSearchContextContent,
|
|
88
|
+
Z as useTheme,
|
|
89
|
+
ad as useThemes,
|
|
89
90
|
x2 as xmlUiMarkupToComponent
|
|
90
91
|
};
|