@kurot/cli 1.0.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.
- package/CHANGELOG.md +128 -0
- package/README.md +296 -0
- package/dist/commands/build.d.ts +3 -0
- package/dist/commands/build.d.ts.map +1 -0
- package/dist/commands/build.js +59 -0
- package/dist/commands/build.js.map +1 -0
- package/dist/commands/clean.d.ts +3 -0
- package/dist/commands/clean.d.ts.map +1 -0
- package/dist/commands/clean.js +15 -0
- package/dist/commands/clean.js.map +1 -0
- package/dist/commands/create.d.ts +3 -0
- package/dist/commands/create.d.ts.map +1 -0
- package/dist/commands/create.js +24 -0
- package/dist/commands/create.js.map +1 -0
- package/dist/commands/dev.d.ts +3 -0
- package/dist/commands/dev.d.ts.map +1 -0
- package/dist/commands/dev.js +25 -0
- package/dist/commands/dev.js.map +1 -0
- package/dist/core/config.d.ts +94 -0
- package/dist/core/config.d.ts.map +1 -0
- package/dist/core/config.js +70 -0
- package/dist/core/config.js.map +1 -0
- package/dist/core/dev-server.d.ts +21 -0
- package/dist/core/dev-server.d.ts.map +1 -0
- package/dist/core/dev-server.js +113 -0
- package/dist/core/dev-server.js.map +1 -0
- package/dist/core/errors.d.ts +16 -0
- package/dist/core/errors.d.ts.map +1 -0
- package/dist/core/errors.js +23 -0
- package/dist/core/errors.js.map +1 -0
- package/dist/core/exml/ast.d.ts +243 -0
- package/dist/core/exml/ast.d.ts.map +1 -0
- package/dist/core/exml/ast.js +8 -0
- package/dist/core/exml/ast.js.map +1 -0
- package/dist/core/exml/codegen.d.ts +23 -0
- package/dist/core/exml/codegen.d.ts.map +1 -0
- package/dist/core/exml/codegen.js +422 -0
- package/dist/core/exml/codegen.js.map +1 -0
- package/dist/core/exml/exml-parser.d.ts +27 -0
- package/dist/core/exml/exml-parser.d.ts.map +1 -0
- package/dist/core/exml/exml-parser.js +466 -0
- package/dist/core/exml/exml-parser.js.map +1 -0
- package/dist/core/exml/index.d.ts +52 -0
- package/dist/core/exml/index.d.ts.map +1 -0
- package/dist/core/exml/index.js +51 -0
- package/dist/core/exml/index.js.map +1 -0
- package/dist/core/exml/registry.d.ts +92 -0
- package/dist/core/exml/registry.d.ts.map +1 -0
- package/dist/core/exml/registry.js +177 -0
- package/dist/core/exml/registry.js.map +1 -0
- package/dist/core/exml/xml-parser.d.ts +61 -0
- package/dist/core/exml/xml-parser.d.ts.map +1 -0
- package/dist/core/exml/xml-parser.js +201 -0
- package/dist/core/exml/xml-parser.js.map +1 -0
- package/dist/core/namespace-external-plugin.d.ts +45 -0
- package/dist/core/namespace-external-plugin.d.ts.map +1 -0
- package/dist/core/namespace-external-plugin.js +66 -0
- package/dist/core/namespace-external-plugin.js.map +1 -0
- package/dist/core/pipeline.d.ts +75 -0
- package/dist/core/pipeline.d.ts.map +1 -0
- package/dist/core/pipeline.js +30 -0
- package/dist/core/pipeline.js.map +1 -0
- package/dist/core/plugins/clean-output.d.ts +3 -0
- package/dist/core/plugins/clean-output.d.ts.map +1 -0
- package/dist/core/plugins/clean-output.js +11 -0
- package/dist/core/plugins/clean-output.js.map +1 -0
- package/dist/core/plugins/compile-custom-namespaces.d.ts +19 -0
- package/dist/core/plugins/compile-custom-namespaces.d.ts.map +1 -0
- package/dist/core/plugins/compile-custom-namespaces.js +104 -0
- package/dist/core/plugins/compile-custom-namespaces.js.map +1 -0
- package/dist/core/plugins/compile-engine.d.ts +19 -0
- package/dist/core/plugins/compile-engine.d.ts.map +1 -0
- package/dist/core/plugins/compile-engine.js +75 -0
- package/dist/core/plugins/compile-engine.js.map +1 -0
- package/dist/core/plugins/compile-exml.d.ts +14 -0
- package/dist/core/plugins/compile-exml.d.ts.map +1 -0
- package/dist/core/plugins/compile-exml.js +223 -0
- package/dist/core/plugins/compile-exml.js.map +1 -0
- package/dist/core/plugins/compile-source.d.ts +14 -0
- package/dist/core/plugins/compile-source.d.ts.map +1 -0
- package/dist/core/plugins/compile-source.js +132 -0
- package/dist/core/plugins/compile-source.js.map +1 -0
- package/dist/core/plugins/copy-assets.d.ts +12 -0
- package/dist/core/plugins/copy-assets.d.ts.map +1 -0
- package/dist/core/plugins/copy-assets.js +33 -0
- package/dist/core/plugins/copy-assets.js.map +1 -0
- package/dist/core/plugins/generate-html.d.ts +16 -0
- package/dist/core/plugins/generate-html.d.ts.map +1 -0
- package/dist/core/plugins/generate-html.js +137 -0
- package/dist/core/plugins/generate-html.js.map +1 -0
- package/dist/core/plugins/index.d.ts +21 -0
- package/dist/core/plugins/index.d.ts.map +1 -0
- package/dist/core/plugins/index.js +39 -0
- package/dist/core/plugins/index.js.map +1 -0
- package/dist/core/plugins/manifest.d.ts +14 -0
- package/dist/core/plugins/manifest.d.ts.map +1 -0
- package/dist/core/plugins/manifest.js +28 -0
- package/dist/core/plugins/manifest.js.map +1 -0
- package/dist/core/project.d.ts +95 -0
- package/dist/core/project.d.ts.map +1 -0
- package/dist/core/project.js +79 -0
- package/dist/core/project.js.map +1 -0
- package/dist/core/template.d.ts +13 -0
- package/dist/core/template.d.ts.map +1 -0
- package/dist/core/template.js +79 -0
- package/dist/core/template.js.map +1 -0
- package/dist/define.d.ts +2 -0
- package/dist/define.d.ts.map +1 -0
- package/dist/define.js +2 -0
- package/dist/define.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +19 -0
- package/dist/index.js.map +1 -0
- package/dist/utils/fs.d.ts +5 -0
- package/dist/utils/fs.d.ts.map +1 -0
- package/dist/utils/fs.js +30 -0
- package/dist/utils/fs.js.map +1 -0
- package/dist/utils/logger.d.ts +11 -0
- package/dist/utils/logger.d.ts.map +1 -0
- package/dist/utils/logger.js +18 -0
- package/dist/utils/logger.js.map +1 -0
- package/package.json +45 -0
- package/templates/empty/kurot.config.ts +13 -0
- package/templates/empty/package.json +17 -0
- package/templates/empty/pnpm-workspace.yaml +3 -0
- package/templates/empty/src/Main.ts +32 -0
- package/templates/empty/template/web/index.html +38 -0
- package/templates/empty/tsconfig.json +10 -0
- package/templates/game/kurot.config.ts +16 -0
- package/templates/game/package.json +19 -0
- package/templates/game/pnpm-workspace.yaml +3 -0
- package/templates/game/resource/assets/eui.json +24 -0
- package/templates/game/resource/assets/eui.png +0 -0
- package/templates/game/resource/default.res.json +15 -0
- package/templates/game/resource/default.thm.json +19 -0
- package/templates/game/resource/skins/ButtonSkin.exml +16 -0
- package/templates/game/resource/skins/CheckBoxSkin.exml +18 -0
- package/templates/game/resource/skins/ComboBoxSkin.exml +31 -0
- package/templates/game/resource/skins/GroupSkin.exml +4 -0
- package/templates/game/resource/skins/HScrollBarSkin.exml +6 -0
- package/templates/game/resource/skins/HSliderSkin.exml +7 -0
- package/templates/game/resource/skins/ImageSkin.exml +4 -0
- package/templates/game/resource/skins/ItemRendererSkin.exml +15 -0
- package/templates/game/resource/skins/LabelSkin.exml +7 -0
- package/templates/game/resource/skins/ListSkin.exml +11 -0
- package/templates/game/resource/skins/PanelSkin.exml +15 -0
- package/templates/game/resource/skins/ProgressBarSkin.exml +11 -0
- package/templates/game/resource/skins/RadioButtonSkin.exml +18 -0
- package/templates/game/resource/skins/ScrollerSkin.exml +8 -0
- package/templates/game/resource/skins/TabBarSkin.exml +6 -0
- package/templates/game/resource/skins/TextInputSkin.exml +22 -0
- package/templates/game/resource/skins/ToggleButtonSkin.exml +21 -0
- package/templates/game/resource/skins/ToggleSwitchSkin.exml +15 -0
- package/templates/game/resource/skins/VScrollBarSkin.exml +6 -0
- package/templates/game/resource/skins/VSliderSkin.exml +7 -0
- package/templates/game/resource/skins/ViewStackSkin.exml +4 -0
- package/templates/game/src/LoadingUI.ts +27 -0
- package/templates/game/src/Main.ts +165 -0
- package/templates/game/template/web/index.html +109 -0
- package/templates/game/template/web/logo.png +0 -0
- package/templates/game/tsconfig.json +10 -0
|
@@ -0,0 +1,466 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* EXML Parser — converts an XML element tree into a SkinIR.
|
|
3
|
+
*
|
|
4
|
+
* Walks the XML tree produced by the lightweight XML parser and
|
|
5
|
+
* produces an intermediate representation ready for code generation.
|
|
6
|
+
*/
|
|
7
|
+
import { parseXML, filterElements, getTextContent } from './xml-parser.js';
|
|
8
|
+
import { lookupComponent, localName, isPropertyNode, parsePropertyNode } from './registry.js';
|
|
9
|
+
// ── Public API ───────────────────────────────────────────────────────
|
|
10
|
+
/**
|
|
11
|
+
* Parse an EXML source string into a SkinIR.
|
|
12
|
+
*
|
|
13
|
+
* @param source - EXML source text
|
|
14
|
+
* @param className - Optional class name (used for factory function name)
|
|
15
|
+
* @param customNamespaces - Project-defined EXML namespaces
|
|
16
|
+
* @returns The parsed skin intermediate representation
|
|
17
|
+
*/
|
|
18
|
+
export function parseEXML(source, className, customNamespaces = []) {
|
|
19
|
+
const root = parseXML(source);
|
|
20
|
+
const ir = parseSkinRoot(root, customNamespaces);
|
|
21
|
+
if (className) {
|
|
22
|
+
ir.className = className;
|
|
23
|
+
}
|
|
24
|
+
return ir;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Parse an already-parsed XML root element into a SkinIR.
|
|
28
|
+
*
|
|
29
|
+
* @param root - The parsed XML root element
|
|
30
|
+
* @param customNamespaces - Project-defined EXML namespaces
|
|
31
|
+
* @returns The parsed skin intermediate representation
|
|
32
|
+
*/
|
|
33
|
+
export function parseSkinRoot(root, customNamespaces = []) {
|
|
34
|
+
const ctx = new ParseContext(customNamespaces);
|
|
35
|
+
ctx.processRoot(root);
|
|
36
|
+
return ctx.toIR();
|
|
37
|
+
}
|
|
38
|
+
// ── Parse context ────────────────────────────────────────────────────
|
|
39
|
+
class ParseContext {
|
|
40
|
+
customNamespaces;
|
|
41
|
+
/**
|
|
42
|
+
* Collected imports: className → module.
|
|
43
|
+
*/
|
|
44
|
+
imports = new Map();
|
|
45
|
+
/**
|
|
46
|
+
* Skin part IDs.
|
|
47
|
+
*/
|
|
48
|
+
skinParts = [];
|
|
49
|
+
/**
|
|
50
|
+
* All nodes (flat list for state processing).
|
|
51
|
+
*/
|
|
52
|
+
allNodes = [];
|
|
53
|
+
/**
|
|
54
|
+
* State definitions.
|
|
55
|
+
*/
|
|
56
|
+
states = [];
|
|
57
|
+
/**
|
|
58
|
+
* Declarations.
|
|
59
|
+
*/
|
|
60
|
+
declarations = [];
|
|
61
|
+
/**
|
|
62
|
+
* Tag names that could not be resolved to a component or namespace.
|
|
63
|
+
*/
|
|
64
|
+
unresolvedTags = [];
|
|
65
|
+
/**
|
|
66
|
+
* Counter for generating unique variable names.
|
|
67
|
+
*/
|
|
68
|
+
varCounter = 0;
|
|
69
|
+
constructor(customNamespaces) {
|
|
70
|
+
this.customNamespaces = customNamespaces;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Process the root `<eui:Skin>` element.
|
|
74
|
+
*/
|
|
75
|
+
processRoot(root) {
|
|
76
|
+
// Root should be a Skin tag
|
|
77
|
+
const rootClass = localName(root.name);
|
|
78
|
+
if (rootClass !== 'Skin') {
|
|
79
|
+
throw new Error(`EXML: expected root element to be Skin, got "${rootClass}"`);
|
|
80
|
+
}
|
|
81
|
+
// Ensure Skin is imported
|
|
82
|
+
this.addImport('Skin', '@kurot/ui');
|
|
83
|
+
// Extract root-level properties (class, width, height, etc.)
|
|
84
|
+
for (const attr of root.attributes) {
|
|
85
|
+
if (attr.name === 'class') {
|
|
86
|
+
this._className = attr.value;
|
|
87
|
+
}
|
|
88
|
+
else if (attr.name === 'width') {
|
|
89
|
+
this._width = this.parseValue(attr.value);
|
|
90
|
+
}
|
|
91
|
+
else if (attr.name === 'height') {
|
|
92
|
+
this._height = this.parseValue(attr.value);
|
|
93
|
+
}
|
|
94
|
+
else if (attr.name === 'states') {
|
|
95
|
+
// Shorthand: states="up,down,disabled" → expand to StateDef list
|
|
96
|
+
const stateNames = attr.value
|
|
97
|
+
.split(',')
|
|
98
|
+
.map(s => s.trim())
|
|
99
|
+
.filter(Boolean);
|
|
100
|
+
for (const name of stateNames) {
|
|
101
|
+
if (!this.states.find(s => s.name === name)) {
|
|
102
|
+
this.states.push({ name, stateGroups: [], overrides: [] });
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
else if (attr.name === 'xmlns' || attr.name.startsWith('xmlns:')) {
|
|
107
|
+
// Skip namespace declarations
|
|
108
|
+
}
|
|
109
|
+
else {
|
|
110
|
+
const dotIndex = attr.name.indexOf('.');
|
|
111
|
+
this.rootProperties.push({
|
|
112
|
+
name: dotIndex >= 0 ? attr.name.substring(0, dotIndex) : attr.name,
|
|
113
|
+
state: dotIndex >= 0 ? attr.name.substring(dotIndex + 1) : '',
|
|
114
|
+
value: this.parseValue(attr.value),
|
|
115
|
+
});
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
// First pass: collect state definitions from property children
|
|
119
|
+
// (e.g. <eui:states><eui:State name="up"/></eui:states>)
|
|
120
|
+
const childElements = filterElements(root.children);
|
|
121
|
+
this.collectStates(childElements);
|
|
122
|
+
// Second pass: process non-state children
|
|
123
|
+
for (const el of childElements) {
|
|
124
|
+
const cls = localName(el.name);
|
|
125
|
+
const isPropNode = isPropertyNode(el.name);
|
|
126
|
+
const isLowerProp = cls.length > 0 && cls[0] === cls[0].toLowerCase();
|
|
127
|
+
// Skip property nodes (dot notation or lowercase-first like <eui:states>)
|
|
128
|
+
if (isPropNode || isLowerProp)
|
|
129
|
+
continue;
|
|
130
|
+
if (cls === 'Declarations') {
|
|
131
|
+
this.processDeclarations(el);
|
|
132
|
+
continue;
|
|
133
|
+
}
|
|
134
|
+
// Regular child node
|
|
135
|
+
const node = this.parseNode(el);
|
|
136
|
+
if (node) {
|
|
137
|
+
this.allNodes.push(node);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
// Collect state-specific property overrides from nodes
|
|
141
|
+
this.collectStateOverrides();
|
|
142
|
+
}
|
|
143
|
+
/**
|
|
144
|
+
* Class name extracted from the root `class` attribute.
|
|
145
|
+
*/
|
|
146
|
+
_className = '';
|
|
147
|
+
/**
|
|
148
|
+
* Root width/height.
|
|
149
|
+
*/
|
|
150
|
+
_width;
|
|
151
|
+
_height;
|
|
152
|
+
rootProperties = [];
|
|
153
|
+
/**
|
|
154
|
+
* Collect state definitions from children.
|
|
155
|
+
*
|
|
156
|
+
* Handles both direct `<eui:State>` children and `<eui:states>` property
|
|
157
|
+
* children.
|
|
158
|
+
*/
|
|
159
|
+
collectStates(childElements) {
|
|
160
|
+
for (const el of childElements) {
|
|
161
|
+
const cls = localName(el.name);
|
|
162
|
+
// Direct State child
|
|
163
|
+
if (cls === 'State') {
|
|
164
|
+
this.states.push(this.parseState(el));
|
|
165
|
+
continue;
|
|
166
|
+
}
|
|
167
|
+
// Property child with lowercase first char (e.g. <eui:states>)
|
|
168
|
+
const isLowerProp = cls.length > 0 && cls[0] === cls[0].toLowerCase();
|
|
169
|
+
if (isLowerProp || isPropertyNode(el.name)) {
|
|
170
|
+
// Look inside for State elements
|
|
171
|
+
for (const child of filterElements(el.children)) {
|
|
172
|
+
const childCls = localName(child.name);
|
|
173
|
+
if (childCls === 'State') {
|
|
174
|
+
this.states.push(this.parseState(child));
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
/**
|
|
181
|
+
* Process a `<Declarations>` element.
|
|
182
|
+
*/
|
|
183
|
+
processDeclarations(el) {
|
|
184
|
+
const children = filterElements(el.children);
|
|
185
|
+
for (const child of children) {
|
|
186
|
+
const node = this.parseNode(child);
|
|
187
|
+
if (node)
|
|
188
|
+
this.declarations.push(node);
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
/**
|
|
192
|
+
* Parse a `State` element and its overrides.
|
|
193
|
+
*/
|
|
194
|
+
parseState(el) {
|
|
195
|
+
const nameAttr = this.getAttr(el, 'name') ?? '';
|
|
196
|
+
const stateGroups = (this.getAttr(el, 'stateGroups') ?? '')
|
|
197
|
+
.split(',')
|
|
198
|
+
.map(s => s.trim())
|
|
199
|
+
.filter(Boolean);
|
|
200
|
+
const overrides = [];
|
|
201
|
+
for (const child of filterElements(el.children)) {
|
|
202
|
+
const cls = localName(child.name);
|
|
203
|
+
if (cls === 'AddItems') {
|
|
204
|
+
overrides.push(this.parseAddItems(child));
|
|
205
|
+
}
|
|
206
|
+
else if (cls === 'SetProperty') {
|
|
207
|
+
overrides.push(this.parseSetProperty(child));
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
return { name: nameAttr, stateGroups, overrides };
|
|
211
|
+
}
|
|
212
|
+
/**
|
|
213
|
+
* Parse an `AddItems` override.
|
|
214
|
+
*/
|
|
215
|
+
parseAddItems(el) {
|
|
216
|
+
return {
|
|
217
|
+
type: 'AddItems',
|
|
218
|
+
targetId: this.getAttr(el, 'target') ?? '',
|
|
219
|
+
destinationId: this.getAttr(el, 'destination') ?? '',
|
|
220
|
+
position: parseInt(this.getAttr(el, 'position') ?? '-1', 10),
|
|
221
|
+
propertyName: this.getAttr(el, 'propertyName') ?? '',
|
|
222
|
+
};
|
|
223
|
+
}
|
|
224
|
+
/**
|
|
225
|
+
* Parse a `SetProperty` override.
|
|
226
|
+
*/
|
|
227
|
+
parseSetProperty(el) {
|
|
228
|
+
const rawValue = this.getAttr(el, 'value') ?? '';
|
|
229
|
+
return {
|
|
230
|
+
type: 'SetProperty',
|
|
231
|
+
targetId: this.getAttr(el, 'target') ?? '',
|
|
232
|
+
name: this.getAttr(el, 'name') ?? '',
|
|
233
|
+
value: this.parseValue(rawValue),
|
|
234
|
+
};
|
|
235
|
+
}
|
|
236
|
+
/**
|
|
237
|
+
* Collected IDs for duplicate detection.
|
|
238
|
+
*/
|
|
239
|
+
_idSet = new Set();
|
|
240
|
+
/**
|
|
241
|
+
* Parse a component XML element into a `SkinNode`.
|
|
242
|
+
*/
|
|
243
|
+
parseNode(el) {
|
|
244
|
+
const cls = localName(el.name);
|
|
245
|
+
const info = lookupComponent(el.name, this.customNamespaces);
|
|
246
|
+
if (!info) {
|
|
247
|
+
// Unknown component — dropped from the generated skin; the caller
|
|
248
|
+
// (see `unresolvedTags`) is responsible for surfacing this as a warning.
|
|
249
|
+
this.unresolvedTags.push(el.name);
|
|
250
|
+
return null;
|
|
251
|
+
}
|
|
252
|
+
// Register import
|
|
253
|
+
this.addImport(cls, info.module);
|
|
254
|
+
// Generate variable name
|
|
255
|
+
const id = this.getAttr(el, 'id');
|
|
256
|
+
if (id) {
|
|
257
|
+
if (this._idSet.has(id)) {
|
|
258
|
+
throw new Error(`EXML: duplicate id "${id}" in skin`);
|
|
259
|
+
}
|
|
260
|
+
this._idSet.add(id);
|
|
261
|
+
}
|
|
262
|
+
const varName = id || this.genVar(cls);
|
|
263
|
+
// Track skin parts
|
|
264
|
+
if (id) {
|
|
265
|
+
this.skinParts.push(id);
|
|
266
|
+
}
|
|
267
|
+
// Parse properties from attributes
|
|
268
|
+
const properties = [];
|
|
269
|
+
const includeIn = this.getAttr(el, 'includeIn')
|
|
270
|
+
?.split(',')
|
|
271
|
+
.map(s => s.trim()) ?? [];
|
|
272
|
+
const excludeFrom = this.getAttr(el, 'excludeFrom')
|
|
273
|
+
?.split(',')
|
|
274
|
+
.map(s => s.trim()) ?? [];
|
|
275
|
+
for (const attr of el.attributes) {
|
|
276
|
+
const attrName = attr.name;
|
|
277
|
+
const attrValue = attr.value;
|
|
278
|
+
// Skip special attributes
|
|
279
|
+
if (attrName === 'id' || attrName === 'includeIn' || attrName === 'excludeFrom')
|
|
280
|
+
continue;
|
|
281
|
+
// Check for state-specific property (e.g. "label.up")
|
|
282
|
+
const dotIdx = attrName.lastIndexOf('.');
|
|
283
|
+
if (dotIdx > 0) {
|
|
284
|
+
const prop = attrName.substring(0, dotIdx);
|
|
285
|
+
const state = attrName.substring(dotIdx + 1);
|
|
286
|
+
properties.push({
|
|
287
|
+
name: prop,
|
|
288
|
+
state,
|
|
289
|
+
value: this.parseValue(attrValue),
|
|
290
|
+
});
|
|
291
|
+
}
|
|
292
|
+
else {
|
|
293
|
+
properties.push({
|
|
294
|
+
name: attrName,
|
|
295
|
+
state: '',
|
|
296
|
+
value: this.parseValue(attrValue),
|
|
297
|
+
});
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
// Process child elements
|
|
301
|
+
const children = [];
|
|
302
|
+
const propertyChildren = [];
|
|
303
|
+
for (const child of filterElements(el.children)) {
|
|
304
|
+
// Property node? Egret accepts both owner-qualified nodes such as
|
|
305
|
+
// <eui:Button.label> and lowercase shorthand such as <eui:layout>.
|
|
306
|
+
const childClass = localName(child.name);
|
|
307
|
+
const isLowerProperty = childClass.length > 0 && childClass[0] === childClass[0].toLowerCase();
|
|
308
|
+
if (isPropertyNode(child.name) || isLowerProperty) {
|
|
309
|
+
const parsed = parsePropertyNode(child.name);
|
|
310
|
+
const propertyName = parsed?.property ?? (isLowerProperty ? childClass : '');
|
|
311
|
+
if (propertyName) {
|
|
312
|
+
const childNodes = [];
|
|
313
|
+
// Check for text content
|
|
314
|
+
const text = getTextContent(child.children).trim();
|
|
315
|
+
if (text) {
|
|
316
|
+
childNodes.push(text);
|
|
317
|
+
}
|
|
318
|
+
// Check for element children
|
|
319
|
+
for (const sub of filterElements(child.children)) {
|
|
320
|
+
const node = this.parseNode(sub);
|
|
321
|
+
if (node)
|
|
322
|
+
childNodes.push(node);
|
|
323
|
+
}
|
|
324
|
+
propertyChildren.push({
|
|
325
|
+
propertyName,
|
|
326
|
+
nodes: childNodes,
|
|
327
|
+
});
|
|
328
|
+
}
|
|
329
|
+
continue;
|
|
330
|
+
}
|
|
331
|
+
// Regular child → goes to default property
|
|
332
|
+
const childNode = this.parseNode(child);
|
|
333
|
+
if (childNode) {
|
|
334
|
+
children.push(childNode);
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
// Check for text content (useful for Label, etc.)
|
|
338
|
+
const textContent = getTextContent(el.children).trim();
|
|
339
|
+
return {
|
|
340
|
+
className: cls,
|
|
341
|
+
module: info.module,
|
|
342
|
+
varName,
|
|
343
|
+
id,
|
|
344
|
+
properties,
|
|
345
|
+
children,
|
|
346
|
+
propertyChildren,
|
|
347
|
+
includeIn,
|
|
348
|
+
excludeFrom,
|
|
349
|
+
};
|
|
350
|
+
}
|
|
351
|
+
/**
|
|
352
|
+
* Parse a raw attribute value string into a `PropertyValue`.
|
|
353
|
+
*/
|
|
354
|
+
parseValue(raw) {
|
|
355
|
+
// Check for binding expression {expr}
|
|
356
|
+
const bindingMatch = raw.match(/^\{(.+)\}$/);
|
|
357
|
+
if (bindingMatch) {
|
|
358
|
+
return { type: 'binding', expression: bindingMatch[1].trim() };
|
|
359
|
+
}
|
|
360
|
+
// Check for percent value
|
|
361
|
+
if (raw.endsWith('%')) {
|
|
362
|
+
const num = parseFloat(raw);
|
|
363
|
+
if (!isNaN(num)) {
|
|
364
|
+
return { type: 'percent', value: num };
|
|
365
|
+
}
|
|
366
|
+
}
|
|
367
|
+
// Check for boolean
|
|
368
|
+
if (raw === 'true')
|
|
369
|
+
return { type: 'literal', value: true };
|
|
370
|
+
if (raw === 'false')
|
|
371
|
+
return { type: 'literal', value: false };
|
|
372
|
+
// Check for null
|
|
373
|
+
if (raw === 'null')
|
|
374
|
+
return { type: 'literal', value: null };
|
|
375
|
+
// Check for number
|
|
376
|
+
const num = Number(raw);
|
|
377
|
+
if (raw !== '' && !isNaN(num)) {
|
|
378
|
+
return { type: 'literal', value: num };
|
|
379
|
+
}
|
|
380
|
+
// Default to string
|
|
381
|
+
return { type: 'literal', value: raw };
|
|
382
|
+
}
|
|
383
|
+
/**
|
|
384
|
+
* After all nodes are parsed, collect state-specific overrides.
|
|
385
|
+
*/
|
|
386
|
+
collectStateOverrides() {
|
|
387
|
+
// Process includeIn/excludeFrom on nodes → generate AddItems overrides
|
|
388
|
+
for (const node of this.allNodes) {
|
|
389
|
+
const includedStates = node.includeIn.length > 0
|
|
390
|
+
? node.includeIn
|
|
391
|
+
: node.excludeFrom.length > 0
|
|
392
|
+
? this.states.map(state => state.name).filter(name => !node.excludeFrom.includes(name))
|
|
393
|
+
: [];
|
|
394
|
+
if (includedStates.length > 0) {
|
|
395
|
+
// Node should only exist in specified states
|
|
396
|
+
// Generate AddItems for each state, and the node is NOT added to
|
|
397
|
+
// elementsContent by default — it's only added via state overrides
|
|
398
|
+
for (const stateName of includedStates) {
|
|
399
|
+
this.addStateOverride(stateName, {
|
|
400
|
+
type: 'AddItems',
|
|
401
|
+
targetId: node.id ?? node.varName,
|
|
402
|
+
destinationId: '',
|
|
403
|
+
position: -1,
|
|
404
|
+
propertyName: 'elementsContent',
|
|
405
|
+
});
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
}
|
|
409
|
+
}
|
|
410
|
+
/**
|
|
411
|
+
* Add an override to an existing state definition.
|
|
412
|
+
*/
|
|
413
|
+
addStateOverride(stateName, override) {
|
|
414
|
+
const state = this.states.find(s => s.name === stateName);
|
|
415
|
+
if (state) {
|
|
416
|
+
state.overrides.push(override);
|
|
417
|
+
}
|
|
418
|
+
}
|
|
419
|
+
/**
|
|
420
|
+
* Generate a unique variable name.
|
|
421
|
+
*/
|
|
422
|
+
genVar(base) {
|
|
423
|
+
return `_${base.charAt(0).toLowerCase() + base.slice(1)}${++this.varCounter}`;
|
|
424
|
+
}
|
|
425
|
+
/**
|
|
426
|
+
* Get an attribute value by name.
|
|
427
|
+
*/
|
|
428
|
+
getAttr(el, name) {
|
|
429
|
+
return el.attributes.find(a => a.name === name)?.value;
|
|
430
|
+
}
|
|
431
|
+
/**
|
|
432
|
+
* Register an import.
|
|
433
|
+
*/
|
|
434
|
+
addImport(className, module) {
|
|
435
|
+
this.imports.set(className, module);
|
|
436
|
+
}
|
|
437
|
+
/**
|
|
438
|
+
* Build the final `SkinIR`.
|
|
439
|
+
*/
|
|
440
|
+
toIR() {
|
|
441
|
+
// Extract numeric width/height (percent not valid for skin itself)
|
|
442
|
+
let width;
|
|
443
|
+
let height;
|
|
444
|
+
if (this._width?.type === 'literal' && typeof this._width.value === 'number') {
|
|
445
|
+
width = this._width.value;
|
|
446
|
+
}
|
|
447
|
+
if (this._height?.type === 'literal' && typeof this._height.value === 'number') {
|
|
448
|
+
height = this._height.value;
|
|
449
|
+
}
|
|
450
|
+
return {
|
|
451
|
+
className: this._className,
|
|
452
|
+
superClassName: 'Skin',
|
|
453
|
+
width,
|
|
454
|
+
height,
|
|
455
|
+
properties: this.rootProperties,
|
|
456
|
+
imports: this.imports,
|
|
457
|
+
skinParts: this.skinParts,
|
|
458
|
+
children: this.allNodes,
|
|
459
|
+
propertyChildren: [],
|
|
460
|
+
states: this.states,
|
|
461
|
+
declarations: this.declarations,
|
|
462
|
+
unresolvedTags: this.unresolvedTags,
|
|
463
|
+
};
|
|
464
|
+
}
|
|
465
|
+
}
|
|
466
|
+
//# sourceMappingURL=exml-parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exml-parser.js","sourceRoot":"","sources":["../../../src/core/exml/exml-parser.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAC3E,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAc9F,wEAAwE;AAExE;;;;;;;GAOG;AACH,MAAM,UAAU,SAAS,CACxB,MAAc,EACd,SAAkB,EAClB,mBAA+C,EAAE;IAEjD,MAAM,IAAI,GAAG,QAAQ,CAAC,MAAM,CAAC,CAAC;IAC9B,MAAM,EAAE,GAAG,aAAa,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC;IACjD,IAAI,SAAS,EAAE,CAAC;QACd,EAA4B,CAAC,SAAS,GAAG,SAAS,CAAC;IACrD,CAAC;IACD,OAAO,EAAE,CAAC;AACX,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,aAAa,CAAC,IAAc,EAAE,mBAA+C,EAAE;IAC9F,MAAM,GAAG,GAAG,IAAI,YAAY,CAAC,gBAAgB,CAAC,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
|
4
|
+
* Parses EXML (XML-based skin description format) into an intermediate
|
|
5
|
+
* representation (SkinIR), then generates ESM-compatible JavaScript
|
|
6
|
+
* factory functions.
|
|
7
|
+
*
|
|
8
|
+
* ## Usage
|
|
9
|
+
*
|
|
10
|
+
* ```ts
|
|
11
|
+
* import { parseEXML, generateCode } from './exml/index.js';
|
|
12
|
+
*
|
|
13
|
+
* const ir = parseEXML(exmlSource, 'MySkin');
|
|
14
|
+
* const jsCode = generateCode(ir);
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
export { parseXML, filterElements, getTextContent } from './xml-parser.js';
|
|
18
|
+
export type { XNode, XText, XAttribute, XElement } from './xml-parser.js';
|
|
19
|
+
export type { SkinIR, SkinNode, PropertyAssignment, PropertyValue, PropertyChild, LiteralValue, PercentValue, BindingValue, RefValue, StateDef, StateOverride, StateAddItems, StateSetProperty, StateSetStateProperty, BindingDef, } from './ast.js';
|
|
20
|
+
export { lookupComponent, getDefaultProperty, resolveModule, localName, isPropertyNode, parsePropertyNode, } from './registry.js';
|
|
21
|
+
export type { ComponentInfo, NamespaceModule } from './registry.js';
|
|
22
|
+
export { parseEXML, parseSkinRoot } from './exml-parser.js';
|
|
23
|
+
export { generateCode } from './codegen.js';
|
|
24
|
+
export type { CodeGenOptions } from './codegen.js';
|
|
25
|
+
import type { CodeGenOptions } from './codegen.js';
|
|
26
|
+
import type { NamespaceModule } from './registry.js';
|
|
27
|
+
import type { SkinIR } from './ast.js';
|
|
28
|
+
export interface CompileExmlOptions extends CodeGenOptions {
|
|
29
|
+
/**
|
|
30
|
+
* Project-defined EXML namespaces (see `ProjectConfig.exml.namespaces`).
|
|
31
|
+
*/
|
|
32
|
+
customNamespaces?: readonly NamespaceModule[];
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Compile an EXML source string directly to JavaScript.
|
|
36
|
+
*
|
|
37
|
+
* @param source - EXML source text
|
|
38
|
+
* @param className - Optional class name (used for factory function name)
|
|
39
|
+
* @param options - Code generation options, plus project-defined namespaces
|
|
40
|
+
* @returns Generated JS source string
|
|
41
|
+
*/
|
|
42
|
+
export declare function compileEXML(source: string, className?: string, options?: CompileExmlOptions): string;
|
|
43
|
+
/**
|
|
44
|
+
* Compile an EXML source string to a SkinIR (parse only, no codegen).
|
|
45
|
+
*
|
|
46
|
+
* @param source - EXML source text
|
|
47
|
+
* @param className - Optional class name
|
|
48
|
+
* @param customNamespaces - Project-defined EXML namespaces
|
|
49
|
+
* @returns SkinIR intermediate representation
|
|
50
|
+
*/
|
|
51
|
+
export declare function parseToIR(source: string, className?: string, customNamespaces?: readonly NamespaceModule[]): SkinIR;
|
|
52
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/exml/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAGH,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAC3E,YAAY,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAG1E,YAAY,EACX,MAAM,EACN,QAAQ,EACR,kBAAkB,EAClB,aAAa,EACb,aAAa,EACb,YAAY,EACZ,YAAY,EACZ,YAAY,EACZ,QAAQ,EACR,QAAQ,EACR,aAAa,EACb,aAAa,EACb,gBAAgB,EAChB,qBAAqB,EACrB,UAAU,GACV,MAAM,UAAU,CAAC;AAGlB,OAAO,EACN,eAAe,EACf,kBAAkB,EAClB,aAAa,EACb,SAAS,EACT,cAAc,EACd,iBAAiB,GACjB,MAAM,eAAe,CAAC;AACvB,YAAY,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAGpE,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAG5D,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,YAAY,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAMnD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAEvC,MAAM,WAAW,kBAAmB,SAAQ,cAAc;IACzD;;OAEG;IACH,gBAAgB,CAAC,EAAE,SAAS,eAAe,EAAE,CAAC;CAC9C;AAED;;;;;;;GAOG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,kBAAkB,GAAG,MAAM,CAGpG;AAED;;;;;;;GAOG;AACH,wBAAgB,SAAS,CACxB,MAAM,EAAE,MAAM,EACd,SAAS,CAAC,EAAE,MAAM,EAClB,gBAAgB,GAAE,SAAS,eAAe,EAAO,GAC/C,MAAM,CAER"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* EXML skin file parser and code generator.
|
|
3
|
+
*
|
|
4
|
+
* Parses EXML (XML-based skin description format) into an intermediate
|
|
5
|
+
* representation (SkinIR), then generates ESM-compatible JavaScript
|
|
6
|
+
* factory functions.
|
|
7
|
+
*
|
|
8
|
+
* ## Usage
|
|
9
|
+
*
|
|
10
|
+
* ```ts
|
|
11
|
+
* import { parseEXML, generateCode } from './exml/index.js';
|
|
12
|
+
*
|
|
13
|
+
* const ir = parseEXML(exmlSource, 'MySkin');
|
|
14
|
+
* const jsCode = generateCode(ir);
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
// ── XML Parser ───────────────────────────────────────────────────────
|
|
18
|
+
export { parseXML, filterElements, getTextContent } from './xml-parser.js';
|
|
19
|
+
// ── Component Registry ───────────────────────────────────────────────
|
|
20
|
+
export { lookupComponent, getDefaultProperty, resolveModule, localName, isPropertyNode, parsePropertyNode, } from './registry.js';
|
|
21
|
+
// ── EXML Parser ──────────────────────────────────────────────────────
|
|
22
|
+
export { parseEXML, parseSkinRoot } from './exml-parser.js';
|
|
23
|
+
// ── Code Generator ───────────────────────────────────────────────────
|
|
24
|
+
export { generateCode } from './codegen.js';
|
|
25
|
+
// ── Convenience: parse + generate in one step ────────────────────────
|
|
26
|
+
import { parseEXML } from './exml-parser.js';
|
|
27
|
+
import { generateCode } from './codegen.js';
|
|
28
|
+
/**
|
|
29
|
+
* Compile an EXML source string directly to JavaScript.
|
|
30
|
+
*
|
|
31
|
+
* @param source - EXML source text
|
|
32
|
+
* @param className - Optional class name (used for factory function name)
|
|
33
|
+
* @param options - Code generation options, plus project-defined namespaces
|
|
34
|
+
* @returns Generated JS source string
|
|
35
|
+
*/
|
|
36
|
+
export function compileEXML(source, className, options) {
|
|
37
|
+
const ir = parseEXML(source, className, options?.customNamespaces ?? []);
|
|
38
|
+
return generateCode(ir, options);
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Compile an EXML source string to a SkinIR (parse only, no codegen).
|
|
42
|
+
*
|
|
43
|
+
* @param source - EXML source text
|
|
44
|
+
* @param className - Optional class name
|
|
45
|
+
* @param customNamespaces - Project-defined EXML namespaces
|
|
46
|
+
* @returns SkinIR intermediate representation
|
|
47
|
+
*/
|
|
48
|
+
export function parseToIR(source, className, customNamespaces = []) {
|
|
49
|
+
return parseEXML(source, className, customNamespaces);
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/core/exml/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,wEAAwE;AACxE,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAsB3E,wEAAwE;AACxE,OAAO,EACN,eAAe,EACf,kBAAkB,EAClB,aAAa,EACb,SAAS,EACT,cAAc,EACd,iBAAiB,GACjB,MAAM,eAAe,CAAC;AAGvB,wEAAwE;AACxE,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAE5D,wEAAwE;AACxE,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAG5C,wEAAwE;AAExE,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAY5C;;;;;;;GAOG;AACH,MAAM,UAAU,WAAW,CAAC,MAAc,EAAE,SAAkB,EAAE,OAA4B;IAC3F,MAAM,EAAE,GAAG,SAAS,CAAC,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,gBAAgB,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,YAAY,CAAC,EAAE,EAAE,OAAO,CAAC,CAAC;AAClC,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,SAAS,CACxB,MAAc,EACd,SAAkB,EAClB,mBAA+C,EAAE;IAEjD,OAAO,SAAS,CAAC,MAAM,EAAE,SAAS,EAAE,gBAAgB,CAAC,CAAC;AACvD,CAAC"}
|