jaxs 0.2.1 → 0.3.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.
- package/cypress/jaxs-apps/dist/add-remove-root-children.3bb9b3f5.js +49 -64
- package/cypress/jaxs-apps/dist/add-remove-root-children.3bb9b3f5.js.map +1 -1
- package/cypress/jaxs-apps/svg.jsx +5 -5
- package/dist/jaxs.js +38 -40
- package/package.json +1 -1
- package/src/debugging.js +3 -3
- package/src/rendering/change/instructions/attributes.ts +4 -1
- package/src/rendering/change/instructions/children.ts +22 -23
- package/src/rendering/change/instructions/element.ts +7 -0
- package/src/rendering/change/instructions/node.ts +19 -2
- package/src/rendering/change.ts +17 -9
- package/src/rendering/dom/svg.ts +5 -3
- package/src/types.ts +3 -1
|
@@ -655,11 +655,12 @@ var normalizeValueForKey = (object, key, defaultValue = "")=>{
|
|
|
655
655
|
return object[key];
|
|
656
656
|
};
|
|
657
657
|
// src/rendering/dom/svg.ts
|
|
658
|
+
var namespace = "http://www.w3.org/2000/svg";
|
|
658
659
|
var isSvgTag = (tagType)=>tagType === "svg";
|
|
660
|
+
var isSvg = (element)=>element.namespaceURI === namespace;
|
|
659
661
|
var createSvgNode = (type, attributes, renderKit)=>{
|
|
660
662
|
const document = renderKit && renderKit.document || window.document;
|
|
661
|
-
const
|
|
662
|
-
const node = document.createElementNS(xmlns, type, xmlns);
|
|
663
|
+
const node = document.createElementNS(namespace, type);
|
|
663
664
|
for(const key in attributes){
|
|
664
665
|
if (key === "__self" || key === "xmlns") continue;
|
|
665
666
|
node.setAttributeNS(null, key, attributes[key]);
|
|
@@ -709,20 +710,20 @@ var isTextNode = (child)=>{
|
|
|
709
710
|
var textNode = (content)=>{
|
|
710
711
|
return new TextTemplate(content);
|
|
711
712
|
};
|
|
712
|
-
var withSvgFlag = (
|
|
713
|
-
template && (template.isSvg = template.isSvg ||
|
|
713
|
+
var withSvgFlag = (isSvg2)=>(template)=>{
|
|
714
|
+
template && (template.isSvg = template.isSvg || isSvg2);
|
|
714
715
|
return template;
|
|
715
716
|
};
|
|
716
717
|
class Children {
|
|
717
718
|
collection;
|
|
718
719
|
parentElement;
|
|
719
720
|
isSvg;
|
|
720
|
-
constructor(jsxChildren,
|
|
721
|
+
constructor(jsxChildren, isSvg2 = false){
|
|
721
722
|
this.collection = ensureArray(jsxChildren);
|
|
722
723
|
this.collection = this.collection.map(replaceTextNodes);
|
|
723
724
|
this.collection = this.collection.flat();
|
|
724
|
-
this.collection = this.collection.map(withSvgFlag(
|
|
725
|
-
this.isSvg =
|
|
725
|
+
this.collection = this.collection.map(withSvgFlag(isSvg2));
|
|
726
|
+
this.isSvg = isSvg2;
|
|
726
727
|
}
|
|
727
728
|
render(renderKit, parentElement) {
|
|
728
729
|
this.parentElement = parentElement;
|
|
@@ -746,14 +747,13 @@ class Tag {
|
|
|
746
747
|
attributes;
|
|
747
748
|
children;
|
|
748
749
|
isSvg;
|
|
749
|
-
constructor(tagType, combinedAttributes, children2,
|
|
750
|
+
constructor(tagType, combinedAttributes, children2, isSvg2 = false){
|
|
750
751
|
this.type = tagType;
|
|
751
752
|
const { events, attributes } = separateAttrsAndEvents(combinedAttributes);
|
|
752
753
|
this.events = events;
|
|
753
754
|
this.attributes = attributes;
|
|
754
|
-
this.isSvg =
|
|
755
|
+
this.isSvg = isSvg2 || isSvgTag(this.type);
|
|
755
756
|
this.children = new Children(children2, this.isSvg);
|
|
756
|
-
console.log(this.type, this.isSvg);
|
|
757
757
|
}
|
|
758
758
|
render(renderKit) {
|
|
759
759
|
const dom = this.generateDom(renderKit);
|
|
@@ -764,13 +764,8 @@ class Tag {
|
|
|
764
764
|
];
|
|
765
765
|
}
|
|
766
766
|
generateDom(renderKit) {
|
|
767
|
-
if (this.isSvg)
|
|
768
|
-
|
|
769
|
-
return this.generateSvnDom(renderKit);
|
|
770
|
-
} else {
|
|
771
|
-
console.log("rendering", this.type, "as normal node");
|
|
772
|
-
return this.generateHtmlDom(renderKit);
|
|
773
|
-
}
|
|
767
|
+
if (this.isSvg) return this.generateSvnDom(renderKit);
|
|
768
|
+
else return this.generateHtmlDom(renderKit);
|
|
774
769
|
}
|
|
775
770
|
generateHtmlDom(renderKit) {
|
|
776
771
|
const node = createDecoratedNode(this.type, this.attributes, this.events, renderKit);
|
|
@@ -1137,7 +1132,7 @@ var createIdMap = (list)=>{
|
|
|
1137
1132
|
return map;
|
|
1138
1133
|
};
|
|
1139
1134
|
// src/rendering/change/instructions/attributes.ts
|
|
1140
|
-
var compileForAttributes = (source, target)=>{
|
|
1135
|
+
var compileForAttributes = (source, target, isSvg2 = false)=>{
|
|
1141
1136
|
const instructions = [];
|
|
1142
1137
|
const sourceAttributes = source.attributes;
|
|
1143
1138
|
const sourceLength = sourceAttributes.length;
|
|
@@ -1159,11 +1154,13 @@ var compileForAttributes = (source, target)=>{
|
|
|
1159
1154
|
}
|
|
1160
1155
|
}
|
|
1161
1156
|
if (!matchingAttribute) instructions.push(removeAttribute(source, target, {
|
|
1162
|
-
name: sourceAttribute.name
|
|
1157
|
+
name: sourceAttribute.name,
|
|
1158
|
+
isSvg: isSvg2
|
|
1163
1159
|
}));
|
|
1164
1160
|
else if (sourceAttribute.value !== matchingAttribute.value) instructions.push(updateAttribute(source, target, {
|
|
1165
1161
|
name: sourceAttribute.name,
|
|
1166
|
-
value: matchingAttribute.value
|
|
1162
|
+
value: matchingAttribute.value,
|
|
1163
|
+
isSvg: isSvg2
|
|
1167
1164
|
}));
|
|
1168
1165
|
}
|
|
1169
1166
|
for(index = 0; index < targetLength; index++){
|
|
@@ -1180,7 +1177,8 @@ var compileForAttributes = (source, target)=>{
|
|
|
1180
1177
|
}
|
|
1181
1178
|
if (!matchingAttribute) instructions.push(addAttribute(source, target, {
|
|
1182
1179
|
name: targetAttribute.name,
|
|
1183
|
-
value: targetAttribute.value
|
|
1180
|
+
value: targetAttribute.value,
|
|
1181
|
+
isSvg: isSvg2
|
|
1184
1182
|
}));
|
|
1185
1183
|
}
|
|
1186
1184
|
return instructions;
|
|
@@ -1222,6 +1220,9 @@ var compileForElement = (source, target)=>{
|
|
|
1222
1220
|
const valueInstructions = compileForInputValue(source, target);
|
|
1223
1221
|
return attributeInstructions.concat(eventInstructions).concat(valueInstructions);
|
|
1224
1222
|
};
|
|
1223
|
+
var compileForSvg = (source, target)=>{
|
|
1224
|
+
return compileForAttributes(source, target, true);
|
|
1225
|
+
};
|
|
1225
1226
|
var compileForInputValue = (sourceElement, targetElement)=>{
|
|
1226
1227
|
const instructions = [];
|
|
1227
1228
|
if (sourceElement.tagName !== "INPUT") return instructions;
|
|
@@ -1248,7 +1249,13 @@ var NodeTypes;
|
|
|
1248
1249
|
})(NodeTypes || (NodeTypes = {}));
|
|
1249
1250
|
var compileForNodeGenerator = (compileForCollection)=>(source, target)=>{
|
|
1250
1251
|
let instructions = [];
|
|
1251
|
-
if (source.nodeType === NodeTypes.ElementNode) {
|
|
1252
|
+
if (source.nodeType === NodeTypes.ElementNode && isSvg(source)) {
|
|
1253
|
+
const sourceElement = source;
|
|
1254
|
+
const targetElement = target;
|
|
1255
|
+
const baseInstructions = compileForSvg(sourceElement, targetElement);
|
|
1256
|
+
const childrenInstructions = compileForCollection(sourceElement.childNodes, targetElement.childNodes, sourceElement);
|
|
1257
|
+
instructions = baseInstructions.concat(childrenInstructions);
|
|
1258
|
+
} else if (source.nodeType === NodeTypes.ElementNode) {
|
|
1252
1259
|
const sourceElement = source;
|
|
1253
1260
|
const targetElement = target;
|
|
1254
1261
|
const baseInstructions = compileForElement(sourceElement, targetElement);
|
|
@@ -1257,8 +1264,6 @@ var compileForNodeGenerator = (compileForCollection)=>(source, target)=>{
|
|
|
1257
1264
|
} else if (source.nodeType === NodeTypes.TextNode) instructions = compileForText(source, target);
|
|
1258
1265
|
return instructions;
|
|
1259
1266
|
};
|
|
1260
|
-
// src/debugging.js
|
|
1261
|
-
var debug = (...message)=>{};
|
|
1262
1267
|
// src/rendering/change/instructions/children.ts
|
|
1263
1268
|
var compileChildren = (sourceList, targetList, parent)=>{
|
|
1264
1269
|
const baseInstructions = [];
|
|
@@ -1270,55 +1275,37 @@ var compileChildren = (sourceList, targetList, parent)=>{
|
|
|
1270
1275
|
for(; index < length; index++){
|
|
1271
1276
|
const source = sourceList[index];
|
|
1272
1277
|
const target = targetList[index];
|
|
1273
|
-
debug("\n", "loop index", index, source && source.__jsx, target && target.__jsx);
|
|
1274
1278
|
if (target && targetMap.check(target)) {
|
|
1275
|
-
debug("target", target.__jsx, "index", index);
|
|
1276
1279
|
const matchingSource = sourceMap.pullMatch(target);
|
|
1277
1280
|
targetMap.clear(target);
|
|
1278
1281
|
if (matchingSource.element) {
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
parent,
|
|
1284
|
-
index
|
|
1285
|
-
}));
|
|
1286
|
-
}
|
|
1287
|
-
debug("updating to match target", matchingSource.element.__jsx, matchingSource.element.classList, target.__jsx, target.classList);
|
|
1282
|
+
if (matchingSource.index !== index) baseInstructions.push(insertNode(matchingSource.element, {
|
|
1283
|
+
parent,
|
|
1284
|
+
index
|
|
1285
|
+
}));
|
|
1288
1286
|
nodesPairsToDiff.push({
|
|
1289
1287
|
source: matchingSource.element,
|
|
1290
1288
|
target
|
|
1291
1289
|
});
|
|
1292
1290
|
} else if (source) {
|
|
1293
|
-
|
|
1294
|
-
if (targetMap.check(source)) {
|
|
1295
|
-
debug("adding", target.__jsx, "at", index);
|
|
1296
|
-
baseInstructions.push(insertNode(target, {
|
|
1297
|
-
parent,
|
|
1298
|
-
index
|
|
1299
|
-
}));
|
|
1300
|
-
} else {
|
|
1301
|
-
debug("replacing", source.__jsx, target.__jsx, "at", index);
|
|
1302
|
-
sourceMap.clear(source);
|
|
1303
|
-
baseInstructions.push(replaceNode(source, target));
|
|
1304
|
-
}
|
|
1305
|
-
} else {
|
|
1306
|
-
debug("adding target to end", target.__jsx);
|
|
1307
|
-
baseInstructions.push(insertNode(target, {
|
|
1291
|
+
if (targetMap.check(source)) baseInstructions.push(insertNode(target, {
|
|
1308
1292
|
parent,
|
|
1309
1293
|
index
|
|
1310
1294
|
}));
|
|
1311
|
-
|
|
1295
|
+
else {
|
|
1296
|
+
sourceMap.clear(source);
|
|
1297
|
+
baseInstructions.push(replaceNode(source, target));
|
|
1298
|
+
}
|
|
1299
|
+
} else baseInstructions.push(insertNode(target, {
|
|
1300
|
+
parent,
|
|
1301
|
+
index
|
|
1302
|
+
}));
|
|
1312
1303
|
} else if (source) {
|
|
1313
1304
|
const matchingSource = sourceMap.pullMatch(source);
|
|
1314
|
-
if (matchingSource.element)
|
|
1315
|
-
debug("removing", source.__jsx);
|
|
1316
|
-
baseInstructions.push(removeNode(source));
|
|
1317
|
-
}
|
|
1305
|
+
if (matchingSource.element) baseInstructions.push(removeNode(source));
|
|
1318
1306
|
}
|
|
1319
1307
|
}
|
|
1320
1308
|
sourceMap.remaining().forEach(({ element: element2 })=>{
|
|
1321
|
-
debug("removing", element2.__jsx);
|
|
1322
1309
|
baseInstructions.push(removeNode(element2));
|
|
1323
1310
|
});
|
|
1324
1311
|
const nodeInstructions = nodesPairsToDiff.reduce((collection, { source, target })=>{
|
|
@@ -1340,7 +1327,6 @@ var compileForNode = compileForNodeGenerator(compileChildren);
|
|
|
1340
1327
|
// src/rendering/change.ts
|
|
1341
1328
|
var change = (source, target, parent)=>{
|
|
1342
1329
|
const instructions = compileChildren(source, target, parent);
|
|
1343
|
-
debug("instructions", instructions.map((instruction)=>instruction.type));
|
|
1344
1330
|
instructions.forEach((instruction)=>{
|
|
1345
1331
|
performInstruction(instruction);
|
|
1346
1332
|
});
|
|
@@ -1357,7 +1343,6 @@ var changeText2 = (instruction)=>{
|
|
|
1357
1343
|
var removeNode2 = (instruction)=>{
|
|
1358
1344
|
const { source } = instruction;
|
|
1359
1345
|
source.remove();
|
|
1360
|
-
debug("removeNode called on", source.nodeName);
|
|
1361
1346
|
};
|
|
1362
1347
|
var insertNode2 = (instruction)=>{
|
|
1363
1348
|
const { target, data } = instruction;
|
|
@@ -1369,18 +1354,18 @@ var insertNode2 = (instruction)=>{
|
|
|
1369
1354
|
var replaceNode2 = (instruction)=>{
|
|
1370
1355
|
const { source, target } = instruction;
|
|
1371
1356
|
source.replaceWith(target);
|
|
1372
|
-
debug("replaceNode called on", source.nodeName, "with", target.nodeName);
|
|
1373
|
-
debug("parent", source.parentElement);
|
|
1374
1357
|
};
|
|
1375
1358
|
var removeAttribute2 = (instruction)=>{
|
|
1376
1359
|
const { source, data } = instruction;
|
|
1377
|
-
const { name } = data;
|
|
1378
|
-
source.
|
|
1360
|
+
const { name, isSvg: isSvg2 } = data;
|
|
1361
|
+
if (isSvg2) source.removeAttributeNS(null, name);
|
|
1362
|
+
else source.removeAttribute(name);
|
|
1379
1363
|
};
|
|
1380
1364
|
var addAttribute2 = (instruction)=>{
|
|
1381
1365
|
const { source, data } = instruction;
|
|
1382
|
-
const { name, value } = data;
|
|
1383
|
-
source.
|
|
1366
|
+
const { name, value, isSvg: isSvg2 } = data;
|
|
1367
|
+
if (isSvg2) source.setAttributeNS(null, name, value);
|
|
1368
|
+
else source.setAttribute(name, value);
|
|
1384
1369
|
};
|
|
1385
1370
|
var updateAttribute2 = (instruction)=>{
|
|
1386
1371
|
addAttribute2(instruction);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAI,WAAW;AAAK,IAAI,WAAW;AAAK,IAAI,aAAa;AAAM,IAAI,eAAe;AAAmB,OAAO,MAAM,CAAC,aAAa,GAAG;AAAmB;AAEtJ,iJAAiJ,GACjJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6CA,GACA,IAAI,aAAa;AACjB,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,EAAE,MAAM;AACjD;AAEA,qBAAqB;AACrB,IAAI,OAAO,CAAC,EAAE,UAAU,SAAS,EAAE,GAAG,OAAO;IAC3C,OAAO,YAAY,KAAK;QACtB,GAAG,KAAK;QACR,SAAS;IACX,GAAG;AACL;AAEA,eAAe;AACf,IAAI,QAAQ;IACV,GAAG,oBAAoB;IACvB;AACF;;;AC7pCA,QAAQ,cAAc,GAAG,SAAU,CAAC;IAClC,OAAO,KAAK,EAAE,UAAU,GAAG,IAAI;QAAC,SAAS;IAAC;AAC5C;AAEA,QAAQ,iBAAiB,GAAG,SAAU,CAAC;IACrC,OAAO,cAAc,CAAC,GAAG,cAAc;QAAC,OAAO;IAAI;AACrD;AAEA,QAAQ,SAAS,GAAG,SAAU,MAAM,EAAE,IAAI;IACxC,OAAO,IAAI,CAAC,QAAQ,OAAO,CAAC,SAAU,GAAG;QACvC,IACE,QAAQ,aACR,QAAQ,gBACR,OAAO,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,MAAM,MAE3C;QAGF,OAAO,cAAc,CAAC,MAAM,KAAK;YAC/B,YAAY;YACZ,KAAK;gBACH,OAAO,MAAM,CAAC,IAAI;YACpB;QACF;IACF;IAEA,OAAO;AACT;AAEA,QAAQ,MAAM,GAAG,SAAU,IAAI,EAAE,QAAQ,EAAE,GAAG;IAC5C,OAAO,cAAc,CAAC,MAAM,UAAU;QACpC,YAAY;QACZ,KAAK;IACP;AACF","sources":["node_modules/@parcel/runtime-browser-hmr/lib/runtime-530046016dc577f1.js","dist/jaxs.js","node_modules/@parcel/transformer-js/src/esmodule-helpers.js"],"sourcesContent":["var HMR_HOST = null;var HMR_PORT = null;var HMR_SECURE = false;var HMR_ENV_HASH = \"d6ea1d42532a7575\";module.bundle.HMR_BUNDLE_ID = \"64a677193bb9b3f5\";\"use strict\";\n\n/* global HMR_HOST, HMR_PORT, HMR_ENV_HASH, HMR_SECURE, chrome, browser, __parcel__import__, __parcel__importScripts__, ServiceWorkerGlobalScope */\n/*::\nimport type {\n HMRAsset,\n HMRMessage,\n} from '@parcel/reporter-dev-server/src/HMRServer.js';\ninterface ParcelRequire {\n (string): mixed;\n cache: {|[string]: ParcelModule|};\n hotData: {|[string]: mixed|};\n Module: any;\n parent: ?ParcelRequire;\n isParcelRequire: true;\n modules: {|[string]: [Function, {|[string]: string|}]|};\n HMR_BUNDLE_ID: string;\n root: ParcelRequire;\n}\ninterface ParcelModule {\n hot: {|\n data: mixed,\n accept(cb: (Function) => void): void,\n dispose(cb: (mixed) => void): void,\n // accept(deps: Array<string> | string, cb: (Function) => void): void,\n // decline(): void,\n _acceptCallbacks: Array<(Function) => void>,\n _disposeCallbacks: Array<(mixed) => void>,\n |};\n}\ninterface ExtensionContext {\n runtime: {|\n reload(): void,\n getURL(url: string): string;\n getManifest(): {manifest_version: number, ...};\n |};\n}\ndeclare var module: {bundle: ParcelRequire, ...};\ndeclare var HMR_HOST: string;\ndeclare var HMR_PORT: string;\ndeclare var HMR_ENV_HASH: string;\ndeclare var HMR_SECURE: boolean;\ndeclare var chrome: ExtensionContext;\ndeclare var browser: ExtensionContext;\ndeclare var __parcel__import__: (string) => Promise<void>;\ndeclare var __parcel__importScripts__: (string) => Promise<void>;\ndeclare var globalThis: typeof self;\ndeclare var ServiceWorkerGlobalScope: Object;\n*/\nvar OVERLAY_ID = '__parcel__error__overlay__';\nvar OldModule = module.bundle.Module;\nfunction Module(moduleName) {\n OldModule.call(this, moduleName);\n this.hot = {\n data: module.bundle.hotData[moduleName],\n _acceptCallbacks: [],\n _disposeCallbacks: [],\n accept: function (fn) {\n this._acceptCallbacks.push(fn || function () {});\n },\n dispose: function (fn) {\n this._disposeCallbacks.push(fn);\n }\n };\n module.bundle.hotData[moduleName] = undefined;\n}\nmodule.bundle.Module = Module;\nmodule.bundle.hotData = {};\nvar checkedAssets /*: {|[string]: boolean|} */, assetsToDispose /*: Array<[ParcelRequire, string]> */, assetsToAccept /*: Array<[ParcelRequire, string]> */;\n\nfunction getHostname() {\n return HMR_HOST || (location.protocol.indexOf('http') === 0 ? location.hostname : 'localhost');\n}\nfunction getPort() {\n return HMR_PORT || location.port;\n}\n\n// eslint-disable-next-line no-redeclare\nvar parent = module.bundle.parent;\nif ((!parent || !parent.isParcelRequire) && typeof WebSocket !== 'undefined') {\n var hostname = getHostname();\n var port = getPort();\n var protocol = HMR_SECURE || location.protocol == 'https:' && !['localhost', '127.0.0.1', '0.0.0.0'].includes(hostname) ? 'wss' : 'ws';\n var ws;\n try {\n ws = new WebSocket(protocol + '://' + hostname + (port ? ':' + port : '') + '/');\n } catch (err) {\n if (err.message) {\n console.error(err.message);\n }\n ws = {};\n }\n\n // Web extension context\n var extCtx = typeof browser === 'undefined' ? typeof chrome === 'undefined' ? null : chrome : browser;\n\n // Safari doesn't support sourceURL in error stacks.\n // eval may also be disabled via CSP, so do a quick check.\n var supportsSourceURL = false;\n try {\n (0, eval)('throw new Error(\"test\"); //# sourceURL=test.js');\n } catch (err) {\n supportsSourceURL = err.stack.includes('test.js');\n }\n\n // $FlowFixMe\n ws.onmessage = async function (event /*: {data: string, ...} */) {\n checkedAssets = {} /*: {|[string]: boolean|} */;\n assetsToAccept = [];\n assetsToDispose = [];\n var data /*: HMRMessage */ = JSON.parse(event.data);\n if (data.type === 'update') {\n // Remove error overlay if there is one\n if (typeof document !== 'undefined') {\n removeErrorOverlay();\n }\n let assets = data.assets.filter(asset => asset.envHash === HMR_ENV_HASH);\n\n // Handle HMR Update\n let handled = assets.every(asset => {\n return asset.type === 'css' || asset.type === 'js' && hmrAcceptCheck(module.bundle.root, asset.id, asset.depsByBundle);\n });\n if (handled) {\n console.clear();\n\n // Dispatch custom event so other runtimes (e.g React Refresh) are aware.\n if (typeof window !== 'undefined' && typeof CustomEvent !== 'undefined') {\n window.dispatchEvent(new CustomEvent('parcelhmraccept'));\n }\n await hmrApplyUpdates(assets);\n\n // Dispose all old assets.\n let processedAssets = {} /*: {|[string]: boolean|} */;\n for (let i = 0; i < assetsToDispose.length; i++) {\n let id = assetsToDispose[i][1];\n if (!processedAssets[id]) {\n hmrDispose(assetsToDispose[i][0], id);\n processedAssets[id] = true;\n }\n }\n\n // Run accept callbacks. This will also re-execute other disposed assets in topological order.\n processedAssets = {};\n for (let i = 0; i < assetsToAccept.length; i++) {\n let id = assetsToAccept[i][1];\n if (!processedAssets[id]) {\n hmrAccept(assetsToAccept[i][0], id);\n processedAssets[id] = true;\n }\n }\n } else fullReload();\n }\n if (data.type === 'error') {\n // Log parcel errors to console\n for (let ansiDiagnostic of data.diagnostics.ansi) {\n let stack = ansiDiagnostic.codeframe ? ansiDiagnostic.codeframe : ansiDiagnostic.stack;\n console.error('🚨 [parcel]: ' + ansiDiagnostic.message + '\\n' + stack + '\\n\\n' + ansiDiagnostic.hints.join('\\n'));\n }\n if (typeof document !== 'undefined') {\n // Render the fancy html overlay\n removeErrorOverlay();\n var overlay = createErrorOverlay(data.diagnostics.html);\n // $FlowFixMe\n document.body.appendChild(overlay);\n }\n }\n };\n ws.onerror = function (e) {\n if (e.message) {\n console.error(e.message);\n }\n };\n ws.onclose = function () {\n console.warn('[parcel] 🚨 Connection to the HMR server was lost');\n };\n}\nfunction removeErrorOverlay() {\n var overlay = document.getElementById(OVERLAY_ID);\n if (overlay) {\n overlay.remove();\n console.log('[parcel] ✨ Error resolved');\n }\n}\nfunction createErrorOverlay(diagnostics) {\n var overlay = document.createElement('div');\n overlay.id = OVERLAY_ID;\n let errorHTML = '<div style=\"background: black; opacity: 0.85; font-size: 16px; color: white; position: fixed; height: 100%; width: 100%; top: 0px; left: 0px; padding: 30px; font-family: Menlo, Consolas, monospace; z-index: 9999;\">';\n for (let diagnostic of diagnostics) {\n let stack = diagnostic.frames.length ? diagnostic.frames.reduce((p, frame) => {\n return `${p}\n<a href=\"/__parcel_launch_editor?file=${encodeURIComponent(frame.location)}\" style=\"text-decoration: underline; color: #888\" onclick=\"fetch(this.href); return false\">${frame.location}</a>\n${frame.code}`;\n }, '') : diagnostic.stack;\n errorHTML += `\n <div>\n <div style=\"font-size: 18px; font-weight: bold; margin-top: 20px;\">\n 🚨 ${diagnostic.message}\n </div>\n <pre>${stack}</pre>\n <div>\n ${diagnostic.hints.map(hint => '<div>💡 ' + hint + '</div>').join('')}\n </div>\n ${diagnostic.documentation ? `<div>📝 <a style=\"color: violet\" href=\"${diagnostic.documentation}\" target=\"_blank\">Learn more</a></div>` : ''}\n </div>\n `;\n }\n errorHTML += '</div>';\n overlay.innerHTML = errorHTML;\n return overlay;\n}\nfunction fullReload() {\n if ('reload' in location) {\n location.reload();\n } else if (extCtx && extCtx.runtime && extCtx.runtime.reload) {\n extCtx.runtime.reload();\n }\n}\nfunction getParents(bundle, id) /*: Array<[ParcelRequire, string]> */{\n var modules = bundle.modules;\n if (!modules) {\n return [];\n }\n var parents = [];\n var k, d, dep;\n for (k in modules) {\n for (d in modules[k][1]) {\n dep = modules[k][1][d];\n if (dep === id || Array.isArray(dep) && dep[dep.length - 1] === id) {\n parents.push([bundle, k]);\n }\n }\n }\n if (bundle.parent) {\n parents = parents.concat(getParents(bundle.parent, id));\n }\n return parents;\n}\nfunction updateLink(link) {\n var href = link.getAttribute('href');\n if (!href) {\n return;\n }\n var newLink = link.cloneNode();\n newLink.onload = function () {\n if (link.parentNode !== null) {\n // $FlowFixMe\n link.parentNode.removeChild(link);\n }\n };\n newLink.setAttribute('href',\n // $FlowFixMe\n href.split('?')[0] + '?' + Date.now());\n // $FlowFixMe\n link.parentNode.insertBefore(newLink, link.nextSibling);\n}\nvar cssTimeout = null;\nfunction reloadCSS() {\n if (cssTimeout) {\n return;\n }\n cssTimeout = setTimeout(function () {\n var links = document.querySelectorAll('link[rel=\"stylesheet\"]');\n for (var i = 0; i < links.length; i++) {\n // $FlowFixMe[incompatible-type]\n var href /*: string */ = links[i].getAttribute('href');\n var hostname = getHostname();\n var servedFromHMRServer = hostname === 'localhost' ? new RegExp('^(https?:\\\\/\\\\/(0.0.0.0|127.0.0.1)|localhost):' + getPort()).test(href) : href.indexOf(hostname + ':' + getPort());\n var absolute = /^https?:\\/\\//i.test(href) && href.indexOf(location.origin) !== 0 && !servedFromHMRServer;\n if (!absolute) {\n updateLink(links[i]);\n }\n }\n cssTimeout = null;\n }, 50);\n}\nfunction hmrDownload(asset) {\n if (asset.type === 'js') {\n if (typeof document !== 'undefined') {\n let script = document.createElement('script');\n script.src = asset.url + '?t=' + Date.now();\n if (asset.outputFormat === 'esmodule') {\n script.type = 'module';\n }\n return new Promise((resolve, reject) => {\n var _document$head;\n script.onload = () => resolve(script);\n script.onerror = reject;\n (_document$head = document.head) === null || _document$head === void 0 || _document$head.appendChild(script);\n });\n } else if (typeof importScripts === 'function') {\n // Worker scripts\n if (asset.outputFormat === 'esmodule') {\n return __parcel__import__(asset.url + '?t=' + Date.now());\n } else {\n return new Promise((resolve, reject) => {\n try {\n __parcel__importScripts__(asset.url + '?t=' + Date.now());\n resolve();\n } catch (err) {\n reject(err);\n }\n });\n }\n }\n }\n}\nasync function hmrApplyUpdates(assets) {\n global.parcelHotUpdate = Object.create(null);\n let scriptsToRemove;\n try {\n // If sourceURL comments aren't supported in eval, we need to load\n // the update from the dev server over HTTP so that stack traces\n // are correct in errors/logs. This is much slower than eval, so\n // we only do it if needed (currently just Safari).\n // https://bugs.webkit.org/show_bug.cgi?id=137297\n // This path is also taken if a CSP disallows eval.\n if (!supportsSourceURL) {\n let promises = assets.map(asset => {\n var _hmrDownload;\n return (_hmrDownload = hmrDownload(asset)) === null || _hmrDownload === void 0 ? void 0 : _hmrDownload.catch(err => {\n // Web extension fix\n if (extCtx && extCtx.runtime && extCtx.runtime.getManifest().manifest_version == 3 && typeof ServiceWorkerGlobalScope != 'undefined' && global instanceof ServiceWorkerGlobalScope) {\n extCtx.runtime.reload();\n return;\n }\n throw err;\n });\n });\n scriptsToRemove = await Promise.all(promises);\n }\n assets.forEach(function (asset) {\n hmrApply(module.bundle.root, asset);\n });\n } finally {\n delete global.parcelHotUpdate;\n if (scriptsToRemove) {\n scriptsToRemove.forEach(script => {\n if (script) {\n var _document$head2;\n (_document$head2 = document.head) === null || _document$head2 === void 0 || _document$head2.removeChild(script);\n }\n });\n }\n }\n}\nfunction hmrApply(bundle /*: ParcelRequire */, asset /*: HMRAsset */) {\n var modules = bundle.modules;\n if (!modules) {\n return;\n }\n if (asset.type === 'css') {\n reloadCSS();\n } else if (asset.type === 'js') {\n let deps = asset.depsByBundle[bundle.HMR_BUNDLE_ID];\n if (deps) {\n if (modules[asset.id]) {\n // Remove dependencies that are removed and will become orphaned.\n // This is necessary so that if the asset is added back again, the cache is gone, and we prevent a full page reload.\n let oldDeps = modules[asset.id][1];\n for (let dep in oldDeps) {\n if (!deps[dep] || deps[dep] !== oldDeps[dep]) {\n let id = oldDeps[dep];\n let parents = getParents(module.bundle.root, id);\n if (parents.length === 1) {\n hmrDelete(module.bundle.root, id);\n }\n }\n }\n }\n if (supportsSourceURL) {\n // Global eval. We would use `new Function` here but browser\n // support for source maps is better with eval.\n (0, eval)(asset.output);\n }\n\n // $FlowFixMe\n let fn = global.parcelHotUpdate[asset.id];\n modules[asset.id] = [fn, deps];\n } else if (bundle.parent) {\n hmrApply(bundle.parent, asset);\n }\n }\n}\nfunction hmrDelete(bundle, id) {\n let modules = bundle.modules;\n if (!modules) {\n return;\n }\n if (modules[id]) {\n // Collect dependencies that will become orphaned when this module is deleted.\n let deps = modules[id][1];\n let orphans = [];\n for (let dep in deps) {\n let parents = getParents(module.bundle.root, deps[dep]);\n if (parents.length === 1) {\n orphans.push(deps[dep]);\n }\n }\n\n // Delete the module. This must be done before deleting dependencies in case of circular dependencies.\n delete modules[id];\n delete bundle.cache[id];\n\n // Now delete the orphans.\n orphans.forEach(id => {\n hmrDelete(module.bundle.root, id);\n });\n } else if (bundle.parent) {\n hmrDelete(bundle.parent, id);\n }\n}\nfunction hmrAcceptCheck(bundle /*: ParcelRequire */, id /*: string */, depsByBundle /*: ?{ [string]: { [string]: string } }*/) {\n if (hmrAcceptCheckOne(bundle, id, depsByBundle)) {\n return true;\n }\n\n // Traverse parents breadth first. All possible ancestries must accept the HMR update, or we'll reload.\n let parents = getParents(module.bundle.root, id);\n let accepted = false;\n while (parents.length > 0) {\n let v = parents.shift();\n let a = hmrAcceptCheckOne(v[0], v[1], null);\n if (a) {\n // If this parent accepts, stop traversing upward, but still consider siblings.\n accepted = true;\n } else {\n // Otherwise, queue the parents in the next level upward.\n let p = getParents(module.bundle.root, v[1]);\n if (p.length === 0) {\n // If there are no parents, then we've reached an entry without accepting. Reload.\n accepted = false;\n break;\n }\n parents.push(...p);\n }\n }\n return accepted;\n}\nfunction hmrAcceptCheckOne(bundle /*: ParcelRequire */, id /*: string */, depsByBundle /*: ?{ [string]: { [string]: string } }*/) {\n var modules = bundle.modules;\n if (!modules) {\n return;\n }\n if (depsByBundle && !depsByBundle[bundle.HMR_BUNDLE_ID]) {\n // If we reached the root bundle without finding where the asset should go,\n // there's nothing to do. Mark as \"accepted\" so we don't reload the page.\n if (!bundle.parent) {\n return true;\n }\n return hmrAcceptCheck(bundle.parent, id, depsByBundle);\n }\n if (checkedAssets[id]) {\n return true;\n }\n checkedAssets[id] = true;\n var cached = bundle.cache[id];\n assetsToDispose.push([bundle, id]);\n if (!cached || cached.hot && cached.hot._acceptCallbacks.length) {\n assetsToAccept.push([bundle, id]);\n return true;\n }\n}\nfunction hmrDispose(bundle /*: ParcelRequire */, id /*: string */) {\n var cached = bundle.cache[id];\n bundle.hotData[id] = {};\n if (cached && cached.hot) {\n cached.hot.data = bundle.hotData[id];\n }\n if (cached && cached.hot && cached.hot._disposeCallbacks.length) {\n cached.hot._disposeCallbacks.forEach(function (cb) {\n cb(bundle.hotData[id]);\n });\n }\n delete bundle.cache[id];\n}\nfunction hmrAccept(bundle /*: ParcelRequire */, id /*: string */) {\n // Execute the module.\n bundle(id);\n\n // Run the accept callbacks in the new version of the module.\n var cached = bundle.cache[id];\n if (cached && cached.hot && cached.hot._acceptCallbacks.length) {\n cached.hot._acceptCallbacks.forEach(function (cb) {\n var assetsToAlsoAccept = cb(function () {\n return getParents(module.bundle.root, id);\n });\n if (assetsToAlsoAccept && assetsToAccept.length) {\n assetsToAlsoAccept.forEach(function (a) {\n hmrDispose(a[0], a[1]);\n });\n\n // $FlowFixMe[method-unbinding]\n assetsToAccept.push.apply(assetsToAccept, assetsToAlsoAccept);\n }\n });\n }\n}","var __defProp = Object.defineProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, {\n get: all[name],\n enumerable: true,\n configurable: true,\n set: (newValue) => all[name] = () => newValue\n });\n};\n\n// src/rendering/dom/create.ts\nvar setAttributesOnElement = (element, attributes) => {\n for (const key in attributes) {\n if (key === \"__self\")\n continue;\n if (key === \"value\") {\n element.value = attributes[key];\n } else {\n element.setAttribute(key, attributes[key]);\n }\n }\n};\nvar setEventsOnElement = (element, events, publish) => {\n const eventMaps = {};\n for (const domEvent in events) {\n const eventName = events[domEvent];\n const listener = (event) => publish(eventName, event);\n element.addEventListener(domEvent, listener);\n eventMaps[domEvent] = {\n domEvent,\n busEvent: eventName,\n listener\n };\n }\n element.eventMaps = eventMaps;\n};\nvar createNode = (type, document) => {\n document = document || window.document;\n return document.createElement(type);\n};\nvar createTextNode = (value, document) => {\n document = document || window.document;\n return document.createTextNode(value);\n};\nvar createDecoratedNode = (type, attributes, events, renderKit) => {\n const dom = createNode(type, renderKit.document);\n setAttributesOnElement(dom, attributes);\n setEventsOnElement(dom, events, renderKit.publish);\n return dom;\n};\n\n// src/rendering/dom/attributesAndEvents.ts\nvar separateAttrsAndEvents = (combined, defaultValue = \"\") => {\n const attributes = {};\n const events = {};\n for (const key in combined) {\n const value = combined[key];\n if (key.match(/^on.+/i)) {\n const eventKey = key.slice(2).toLowerCase();\n events[eventKey] = value;\n } else {\n attributes[key] = normalizeValueForKey(combined, key, defaultValue);\n }\n }\n return {\n attributes,\n events\n };\n};\nvar normalizeValueForKey = (object, key, defaultValue = \"\") => {\n if (object[key] === undefined)\n return defaultValue;\n return object[key];\n};\n\n// src/rendering/dom/svg.ts\nvar isSvgTag = (tagType) => tagType === \"svg\";\nvar createSvgNode = (type, attributes, renderKit) => {\n const document = renderKit && renderKit.document || window.document;\n const xmlns = \"http://www.w3.org/2000/svg\";\n const node = document.createElementNS(xmlns, type, xmlns);\n for (const key in attributes) {\n if (key === \"__self\" || key === \"xmlns\")\n continue;\n node.setAttributeNS(null, key, attributes[key]);\n }\n return node;\n};\n\n// src/rendering/templates/text.ts\nclass TextTemplate {\n value;\n constructor(content) {\n this.value = content.toString();\n }\n render(renderKit) {\n const textNode = createTextNode(this.value, renderKit.document);\n if (!textNode)\n return [];\n textNode.__jsx = \"TextNode\";\n return [textNode];\n }\n}\n\n// src/rendering/templates/children.ts\nvar ensureArray = (children) => {\n if (Array.isArray(children)) {\n return children.flat();\n }\n if (!children) {\n return [];\n }\n return [children];\n};\nvar recursiveRender = (children, renderKit, rendered = []) => children.reduce(renderReducer(renderKit), rendered).flat();\nvar renderReducer = (renderKit) => (aggregate, view) => {\n if (!view)\n return aggregate;\n if (Array.isArray(view)) {\n const dom = recursiveRender(view, renderKit, aggregate);\n return dom;\n }\n view.render(renderKit).forEach((template) => aggregate.push(template));\n return aggregate;\n};\nvar replaceTextNodes = (child) => {\n if (isTextNode(child)) {\n return textNode(child);\n }\n return child;\n};\nvar isTextNode = (child) => {\n return typeof child === \"string\" || typeof child === \"number\";\n};\nvar textNode = (content) => {\n return new TextTemplate(content);\n};\nvar withSvgFlag = (isSvg) => (template) => {\n template && (template.isSvg = template.isSvg || isSvg);\n return template;\n};\n\nclass Children {\n collection;\n parentElement;\n isSvg;\n constructor(jsxChildren, isSvg = false) {\n this.collection = ensureArray(jsxChildren);\n this.collection = this.collection.map(replaceTextNodes);\n this.collection = this.collection.flat();\n this.collection = this.collection.map(withSvgFlag(isSvg));\n this.isSvg = isSvg;\n }\n render(renderKit, parentElement) {\n this.parentElement = parentElement;\n const dom = this.generateDom(renderKit);\n this.attachToParent(dom);\n return dom;\n }\n generateDom(renderKit) {\n return recursiveRender(this.collection, renderKit);\n }\n attachToParent(dom) {\n if (this.parentElement === undefined)\n return;\n const parent = this.parentElement;\n dom.forEach((node) => parent.appendChild(node));\n }\n}\n\n// src/rendering/templates/tag.ts\nclass Tag {\n type;\n events;\n attributes;\n children;\n isSvg;\n constructor(tagType, combinedAttributes, children2, isSvg = false) {\n this.type = tagType;\n const { events, attributes } = separateAttrsAndEvents(combinedAttributes);\n this.events = events;\n this.attributes = attributes;\n this.isSvg = isSvg || isSvgTag(this.type);\n this.children = new Children(children2, this.isSvg);\n console.log(this.type, this.isSvg);\n }\n render(renderKit) {\n const dom = this.generateDom(renderKit);\n if (!dom)\n return [];\n this.children.render(renderKit, dom);\n return [dom];\n }\n generateDom(renderKit) {\n if (this.isSvg) {\n console.log(\"rendering\", this.type, \"as svg\");\n return this.generateSvnDom(renderKit);\n } else {\n console.log(\"rendering\", this.type, \"as normal node\");\n return this.generateHtmlDom(renderKit);\n }\n }\n generateHtmlDom(renderKit) {\n const node = createDecoratedNode(this.type, this.attributes, this.events, renderKit);\n node.__jsx = this.key();\n return node;\n }\n generateSvnDom(renderKit) {\n const node = createSvgNode(this.type, this.attributes, renderKit);\n node.__jsx = this.key();\n return node;\n }\n key() {\n return this.attributes.key || this.source() || this.createKey();\n }\n source() {\n if (this.attributes.__source) {\n const { fileName, lineNumber, columnNumber } = this.attributes.__source;\n return `${fileName}:${lineNumber}:${columnNumber}`;\n }\n }\n createKey() {\n const id = this.attributes.id ? `#${this.attributes.id}` : \"\";\n const type = this.attributes.type ? `[type=${this.attributes.type}]` : \"\";\n const name = this.attributes.name ? `[name=${this.attributes.name}]` : \"\";\n return `${this.type}${id}${type}${name}`;\n }\n}\n\n// src/jsx.js\nvar ensureChildrenArray = (maybeChildren, attributes) => maybeChildren || attributes.children || [];\nvar packageAttributes = (maybeAttributes, maybeChildren) => {\n const attributes = maybeAttributes || {};\n const children3 = ensureChildrenArray(maybeChildren, attributes);\n attributes.children = attributes.children || children3;\n return attributes;\n};\nvar jsx = (type, attributes, ...children3) => {\n if (typeof type === \"string\") {\n return new Tag(type, attributes, children3);\n }\n return type(packageAttributes(attributes, children3));\n};\njsx.fragment = (attributes, maybeChildren) => {\n const children3 = ensureChildrenArray(maybeChildren, attributes);\n return new Children(children3);\n};\nvar jsx_default = jsx;\n// src/rendering/templates/root.ts\nclass Root {\n template;\n selector;\n renderKit;\n dom;\n parentElement;\n constructor(template, selector, renderKit) {\n this.template = template;\n this.selector = selector;\n this.renderKit = renderKit;\n this.dom = [];\n this.parentElement = null;\n }\n renderAndAttach(renderKit) {\n this.parentElement = this.getParentElement();\n this.dom = this.render({ ...renderKit, parent: this.parentElement });\n if (this.parentElement) {\n this.attach();\n }\n }\n render(renderKit) {\n return this.template.render(renderKit);\n }\n attach() {\n this.parentElement && (this.parentElement.innerHTML = \"\");\n this.dom.forEach((element) => {\n this.parentElement && this.parentElement.appendChild(element);\n });\n }\n getParentElement() {\n return this.renderKit.document.querySelector(this.selector);\n }\n}\nvar render = (template, selector, renderKit) => {\n const root = new Root(template, selector, renderKit);\n root.renderAndAttach(renderKit);\n return root;\n};\n// src/state/testingTypes.js\nvar isBoolean = (value) => typeof value === \"boolean\";\nvar isNumber = (value) => typeof value === \"number\";\nvar isString = (value) => typeof value === \"string\";\nvar isArray = (value) => Array.isArray(value);\nvar isObject = (value) => value !== null && !isArray(value) && typeof value === \"object\";\n\n// src/state/equality.js\nvar areElementEqual = (oldValue, newValue) => oldValue === newValue;\nvar keyLengthSame = (oldValue, newValue) => Object.keys(oldValue).length === Object.keys(newValue).length;\nvar areObjectsEqual = (oldValue, newValue) => {\n if (!(isObject(oldValue) && isObject(newValue)))\n return false;\n if (!keyLengthSame(oldValue, newValue))\n return false;\n Object.keys(oldValue).every((key) => {\n const oldInnerValue = oldValue[key];\n const newInnerValue = newValue[key];\n return areEqual(oldInnerValue, newInnerValue);\n });\n};\nvar areArraysEqual = (oldValue, newValue) => {\n if (!(isArray(oldValue) && isArray(newValue)))\n return false;\n if (oldValue.length !== newValue.length)\n return false;\n oldValue.every((oldInnerValue, index) => {\n const newInnerValue = newValue[index];\n return areEqual(oldInnerValue, newInnerValue);\n });\n};\nvar areEqual = (oldValue, newValue) => {\n if (isObject(oldValue))\n return areObjectsEqual(oldValue, newValue);\n if (isArray(oldValue))\n return areArraysEqual(oldValue, newValue);\n return areElementEqual(oldValue, newValue);\n};\n\n// src/state/stores.js\nclass GeneralStore {\n nullEvent = {};\n constructor({ name, value, parent }) {\n this.name = name;\n this.value = value;\n this.parent = parent;\n this.initialState = value;\n }\n update(newValue) {\n if (this.isEqual(newValue))\n return;\n this.value = newValue;\n return this.parent.publish(this.event());\n }\n reset() {\n this.update(this.initialState);\n }\n isEqual(newValue) {\n return areElementEqual(this.value, newValue);\n }\n event() {\n return {\n name: this.name,\n value: this.value\n };\n }\n}\n\nclass BooleanStore extends GeneralStore {\n toggle() {\n this.update(!this.value);\n }\n}\n\nclass NumericStore extends GeneralStore {\n}\n\nclass StringStore extends GeneralStore {\n}\n\nclass ListStore extends GeneralStore {\n isEqual(newValue) {\n return areArraysEqual(this.value, newValue);\n }\n push(newValue) {\n const value = [...this.value, newValue];\n this.update(value);\n }\n}\n\nclass RecordStore extends GeneralStore {\n isEqual(newValue) {\n return areObjectsEqual(this.value, newValue);\n }\n}\n\n// src/state.js\nvar eventPrefix = \"state-change\";\nvar eventName = (name) => `${eventPrefix}:${name}`;\n\nclass State {\n constructor(publish) {\n this.publisher = publish;\n this.stores = {};\n this.events = [];\n this.transacting = false;\n }\n create(name, value) {\n const StoreClass = this.storeTypeFor(value);\n const store = new StoreClass({ name, value, parent: this });\n this.addStore(name, store);\n }\n add(store) {\n const name = store.name;\n this.addStore(name, store);\n }\n getStore(name) {\n return this.stores[name];\n }\n addStore(name, store) {\n this.stores[name] = store;\n this[name] = store;\n }\n storeTypeFor(value) {\n if (isArray(value))\n return ListStore;\n if (isObject(value))\n return RecordStore;\n if (isNumber(value))\n return NumericStore;\n if (isBoolean(value))\n return BooleanStore;\n if (isString(value))\n return StringStore;\n return GeneralStore;\n }\n publish(event) {\n this.events.push(event);\n if (!this.transacting)\n this.publishAll();\n }\n publishAll() {\n const publishedStores = [];\n this.events.reverse().forEach((event) => {\n const { name, value } = event;\n if (!publishedStores.includes(name)) {\n publishedStores.push(name);\n this.publisher(`${eventPrefix}:${name}`, value);\n }\n });\n this.events = [];\n }\n transaction(setter) {\n this.transacting = true;\n setter(this);\n this.transacting = false;\n this.publishAll();\n }\n value() {\n return Object.keys(this.stores).reduce((valueObject, key) => {\n valueObject[key] = this.stores[key].value;\n return valueObject;\n }, {});\n }\n}\n\n// src/types.ts\nvar ChangeInstructions;\n(function(ChangeInstructions2) {\n ChangeInstructions2[ChangeInstructions2[\"removeNode\"] = 0] = \"removeNode\";\n ChangeInstructions2[ChangeInstructions2[\"insertNode\"] = 1] = \"insertNode\";\n ChangeInstructions2[ChangeInstructions2[\"replaceNode\"] = 2] = \"replaceNode\";\n ChangeInstructions2[ChangeInstructions2[\"removeAttribute\"] = 3] = \"removeAttribute\";\n ChangeInstructions2[ChangeInstructions2[\"addAttribute\"] = 4] = \"addAttribute\";\n ChangeInstructions2[ChangeInstructions2[\"updateAttribute\"] = 5] = \"updateAttribute\";\n ChangeInstructions2[ChangeInstructions2[\"removeEvent\"] = 6] = \"removeEvent\";\n ChangeInstructions2[ChangeInstructions2[\"addEvent\"] = 7] = \"addEvent\";\n ChangeInstructions2[ChangeInstructions2[\"updateEvent\"] = 8] = \"updateEvent\";\n ChangeInstructions2[ChangeInstructions2[\"changeValue\"] = 9] = \"changeValue\";\n ChangeInstructions2[ChangeInstructions2[\"changeText\"] = 10] = \"changeText\";\n})(ChangeInstructions || (ChangeInstructions = {}));\n\n// src/rendering/change/instructions/generate.ts\nvar changeText = (source, target) => ({\n source,\n target,\n type: ChangeInstructions.changeText,\n data: {}\n});\nvar replaceNode = (source, target) => ({\n source,\n target,\n type: ChangeInstructions.replaceNode,\n data: {}\n});\nvar removeAttribute = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.removeAttribute\n});\nvar addAttribute = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.addAttribute\n});\nvar updateAttribute = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.updateAttribute\n});\nvar removeEvent = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.removeEvent\n});\nvar addEvent = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.addEvent\n});\nvar updateEvent = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.updateEvent\n});\nvar removeNode = (source) => ({\n source,\n target: source,\n type: ChangeInstructions.removeNode,\n data: {}\n});\nvar insertNode = (target, data) => ({\n target,\n source: target,\n type: ChangeInstructions.insertNode,\n data\n});\nvar changeValue = (source, target, data) => ({\n source,\n target,\n type: ChangeInstructions.changeValue,\n data\n});\n\n// src/rendering/change/instructions/idMap.js\nvar nullMatch = { index: -1 };\n\nclass IdMap {\n constructor() {\n this.map = {};\n }\n populate(list) {\n list.forEach((element, i) => {\n const id = element.__jsx;\n if (id) {\n this.map[id] = this.map[id] || [];\n this.map[id].push({\n element,\n index: i\n });\n }\n });\n }\n pullMatch(element) {\n const id = element && element.__jsx;\n if (!id)\n return nullMatch;\n if (!(this.map[id] && this.map[id].length))\n return nullMatch;\n return this.map[id].shift();\n }\n clear(element) {\n const id = element && element.__jsx;\n if (!(id && this.map[id] && this.map[id].length))\n return;\n const matches = this.map[id];\n this.map[id] = matches.reduce((collection, possibleMatch) => {\n if (possibleMatch.element !== element)\n collection.push(possibleMatch);\n return collection;\n }, []);\n }\n check(element) {\n const id = element && element.__jsx;\n if (!(id && this.map[id]))\n return false;\n return this.map[id].length > 0;\n }\n remaining() {\n return Object.values(this.map).flat();\n }\n}\nvar createIdMap = (list) => {\n const map = new IdMap;\n map.populate(list);\n return map;\n};\n\n// src/rendering/change/instructions/attributes.ts\nvar compileForAttributes = (source, target) => {\n const instructions = [];\n const sourceAttributes = source.attributes;\n const sourceLength = sourceAttributes.length;\n const targetAttributes = target.attributes;\n const targetLength = targetAttributes.length;\n let index;\n let innerIndex;\n let matchingAttribute;\n for (index = 0;index < sourceLength; index++) {\n matchingAttribute = null;\n const sourceAttribute = sourceAttributes.item(index);\n if (!sourceAttribute)\n continue;\n for (innerIndex = 0;innerIndex < targetLength; innerIndex++) {\n const targetAttribute = targetAttributes.item(innerIndex);\n if (!targetAttribute)\n continue;\n if (sourceAttribute.name == targetAttribute.name) {\n matchingAttribute = targetAttribute;\n break;\n }\n }\n if (!matchingAttribute) {\n instructions.push(removeAttribute(source, target, { name: sourceAttribute.name }));\n } else if (sourceAttribute.value !== matchingAttribute.value) {\n instructions.push(updateAttribute(source, target, {\n name: sourceAttribute.name,\n value: matchingAttribute.value\n }));\n }\n }\n for (index = 0;index < targetLength; index++) {\n matchingAttribute = null;\n const targetAttribute = targetAttributes.item(index);\n if (!targetAttribute)\n continue;\n for (innerIndex = 0;innerIndex < sourceLength; innerIndex++) {\n const sourceAttribute = sourceAttributes.item(innerIndex);\n if (!sourceAttribute)\n continue;\n if (sourceAttribute.name == targetAttribute.name) {\n matchingAttribute = sourceAttribute;\n break;\n }\n }\n if (!matchingAttribute) {\n instructions.push(addAttribute(source, target, {\n name: targetAttribute.name,\n value: targetAttribute.value\n }));\n }\n }\n return instructions;\n};\n\n// src/rendering/change/instructions/events.ts\nvar compileForEvents = (source, target) => {\n const instructions = [];\n const sourceEventMaps = source.eventMaps;\n const targetEventMaps = target.eventMaps;\n const sourceDomEvents = Object.keys(sourceEventMaps);\n const targetDomEvents = Object.keys(targetEventMaps);\n sourceDomEvents.forEach((domEvent) => {\n const sourceEventMap = sourceEventMaps[domEvent];\n const targetEventMap = targetEventMaps[domEvent];\n if (!targetEventMap) {\n instructions.push(removeEvent(source, target, {\n name: sourceEventMap.domEvent,\n value: sourceEventMap.listener\n }));\n } else if (targetEventMap.busEvent !== sourceEventMap.busEvent) {\n instructions.push(updateEvent(source, target, {\n name: domEvent,\n targetValue: targetEventMap.listener,\n sourceValue: sourceEventMap.listener\n }));\n }\n });\n targetDomEvents.forEach((domEvent) => {\n const sourceEventMap = sourceEventMaps[domEvent];\n const targetEventMap = targetEventMaps[domEvent];\n if (!sourceEventMap) {\n instructions.push(addEvent(source, target, {\n name: targetEventMap.domEvent,\n value: targetEventMap.listener\n }));\n }\n });\n return instructions;\n};\n\n// src/rendering/change/instructions/element.ts\nvar compileForElement = (source, target) => {\n const attributeInstructions = compileForAttributes(source, target);\n const eventInstructions = compileForEvents(source, target);\n const valueInstructions = compileForInputValue(source, target);\n return attributeInstructions.concat(eventInstructions).concat(valueInstructions);\n};\nvar compileForInputValue = (sourceElement, targetElement) => {\n const instructions = [];\n if (sourceElement.tagName !== \"INPUT\") {\n return instructions;\n }\n const source = sourceElement;\n const target = targetElement;\n if (source.value !== target.value) {\n instructions.push(changeValue(source, target, { name: \"value\", value: target.value }));\n }\n return instructions;\n};\n\n// src/rendering/change/instructions/text.ts\nvar compileForText = (source, target) => {\n if (source.textContent !== target.textContent) {\n return [changeText(source, target)];\n }\n return [];\n};\n\n// src/rendering/change/instructions/node.ts\nvar NodeTypes;\n(function(NodeTypes2) {\n NodeTypes2[NodeTypes2[\"ElementNode\"] = 1] = \"ElementNode\";\n NodeTypes2[NodeTypes2[\"TextNode\"] = 3] = \"TextNode\";\n})(NodeTypes || (NodeTypes = {}));\nvar compileForNodeGenerator = (compileForCollection) => (source, target) => {\n let instructions = [];\n if (source.nodeType === NodeTypes.ElementNode) {\n const sourceElement = source;\n const targetElement = target;\n const baseInstructions = compileForElement(sourceElement, targetElement);\n const childrenInstructions = compileForCollection(sourceElement.childNodes, targetElement.childNodes, sourceElement);\n instructions = baseInstructions.concat(childrenInstructions);\n } else if (source.nodeType === NodeTypes.TextNode) {\n instructions = compileForText(source, target);\n }\n return instructions;\n};\n\n// src/debugging.js\nvar debug = (...message) => {\n if (process.env.DEBUG === \"true\") {\n console.log(...message);\n }\n};\n\n// src/rendering/change/instructions/children.ts\nvar compileChildren = (sourceList, targetList, parent) => {\n const baseInstructions = [];\n const length = largerLength(sourceList, targetList);\n const sourceMap = createIdMap(sourceList);\n const targetMap = createIdMap(targetList);\n const nodesPairsToDiff = [];\n let index = 0;\n for (;index < length; index++) {\n const source = sourceList[index];\n const target = targetList[index];\n debug(\"\\n\", \"loop index\", index, source && source.__jsx, target && target.__jsx);\n if (target && targetMap.check(target)) {\n debug(\"target\", target.__jsx, \"index\", index);\n const matchingSource = sourceMap.pullMatch(target);\n targetMap.clear(target);\n if (matchingSource.element) {\n debug(\"matching source found for target\");\n if (matchingSource.index !== index) {\n debug(\"moving source\", matchingSource.element.__jsx, index);\n baseInstructions.push(insertNode(matchingSource.element, { parent, index }));\n }\n debug(\"updating to match target\", matchingSource.element.__jsx, matchingSource.element.classList, target.__jsx, target.classList);\n nodesPairsToDiff.push({\n source: matchingSource.element,\n target\n });\n } else if (source) {\n debug(\"NO matching source for target but source in slot\", source.__jsx);\n if (targetMap.check(source)) {\n debug(\"adding\", target.__jsx, \"at\", index);\n baseInstructions.push(insertNode(target, { parent, index }));\n } else {\n debug(\"replacing\", source.__jsx, target.__jsx, \"at\", index);\n sourceMap.clear(source);\n baseInstructions.push(replaceNode(source, target));\n }\n } else {\n debug(\"adding target to end\", target.__jsx);\n baseInstructions.push(insertNode(target, { parent, index }));\n }\n } else if (source) {\n const matchingSource = sourceMap.pullMatch(source);\n if (matchingSource.element) {\n debug(\"removing\", source.__jsx);\n baseInstructions.push(removeNode(source));\n }\n }\n }\n sourceMap.remaining().forEach(({ element: element2 }) => {\n debug(\"removing\", element2.__jsx);\n baseInstructions.push(removeNode(element2));\n });\n const nodeInstructions = nodesPairsToDiff.reduce((collection, { source, target }) => {\n return collection.concat(compileForNode(source, target));\n }, []);\n return baseInstructions.concat(nodeInstructions).sort(instructionsSorter);\n};\nvar instructionsSorter = (left, right) => {\n if (left.type > right.type)\n return 1;\n if (left.type < right.type)\n return -1;\n return 0;\n};\nvar largerLength = (sourceList, targetList) => {\n const sourceLength = Array.from(sourceList).length;\n const targetLength = Array.from(targetList).length;\n return sourceLength > targetLength ? sourceLength : targetLength;\n};\nvar compileForNode = compileForNodeGenerator(compileChildren);\n// src/rendering/change.ts\nvar change = (source, target, parent) => {\n const instructions = compileChildren(source, target, parent);\n debug(\"instructions\", instructions.map((instruction) => instruction.type));\n instructions.forEach((instruction) => {\n performInstruction(instruction);\n });\n};\nvar performInstruction = (instruction) => {\n const performer = performers[instruction.type] || noop;\n performer(instruction);\n};\nvar noop = (_instruction) => {\n};\nvar changeText2 = (instruction) => {\n const { source, target } = instruction;\n source.nodeValue = target.textContent;\n};\nvar removeNode2 = (instruction) => {\n const { source } = instruction;\n source.remove();\n debug(\"removeNode called on\", source.nodeName);\n};\nvar insertNode2 = (instruction) => {\n const { target, data } = instruction;\n const { parent, index } = data;\n const sibling = parent.childNodes[index];\n if (!sibling) {\n parent.appendChild(target);\n } else if (sibling && sibling !== target) {\n parent.insertBefore(target, sibling);\n }\n};\nvar replaceNode2 = (instruction) => {\n const { source, target } = instruction;\n source.replaceWith(target);\n debug(\"replaceNode called on\", source.nodeName, \"with\", target.nodeName);\n debug(\"parent\", source.parentElement);\n};\nvar removeAttribute2 = (instruction) => {\n const { source, data } = instruction;\n const { name } = data;\n source.removeAttribute(name);\n};\nvar addAttribute2 = (instruction) => {\n const { source, data } = instruction;\n const { name, value } = data;\n source.setAttribute(name, value);\n};\nvar updateAttribute2 = (instruction) => {\n addAttribute2(instruction);\n};\nvar removeEvent2 = (instruction) => {\n const data = instruction.data;\n const source = instruction.source;\n const { name, value } = data;\n source.removeEventListener(name, value);\n};\nvar addEvent2 = (instruction) => {\n const data = instruction.data;\n const source = instruction.source;\n const { name, value } = data;\n source.addEventListener(name, value);\n};\nvar updateEvent2 = (instruction) => {\n const data = instruction.data;\n const source = instruction.source;\n const { name, sourceValue, targetValue } = data;\n source.removeEventListener(name, sourceValue);\n source.addEventListener(name, targetValue);\n};\nvar changeValue2 = (instruction) => {\n const data = instruction.data;\n const source = instruction.source;\n const { value } = data;\n source.value = value;\n};\nvar performers = {\n [ChangeInstructions.changeText]: changeText2,\n [ChangeInstructions.removeNode]: removeNode2,\n [ChangeInstructions.insertNode]: insertNode2,\n [ChangeInstructions.replaceNode]: replaceNode2,\n [ChangeInstructions.removeAttribute]: removeAttribute2,\n [ChangeInstructions.addAttribute]: addAttribute2,\n [ChangeInstructions.updateAttribute]: updateAttribute2,\n [ChangeInstructions.removeEvent]: removeEvent2,\n [ChangeInstructions.addEvent]: addEvent2,\n [ChangeInstructions.updateEvent]: updateEvent2,\n [ChangeInstructions.changeValue]: changeValue2\n};\n\n// src/rendering/templates/bound.js\nclass Bound {\n constructor(TemplateClass, viewModel, subscriptions, attributes2) {\n this.TemplateClass = TemplateClass;\n this.viewModel = viewModel;\n this.attributes = attributes2 || {};\n this.subscriptions = subscriptions;\n this.dom = [];\n }\n render(renderKit) {\n this.parentElement = renderKit.parent;\n this.renderKit = renderKit;\n this.subscribeForRerender();\n this.dom = this._render(renderKit);\n return this.dom;\n }\n _render(renderKit) {\n const props = {\n ...this.attributes,\n ...this.viewModel(renderKit.state.value())\n };\n const template = this.TemplateClass(props);\n const dom = !template ? [] : template.render(renderKit);\n return dom;\n }\n rerender() {\n if (!this.parentElement) {\n this.parentElement = this.dom[0] && this.dom[0].parentElement;\n }\n const newDom = this._render(this.renderKit);\n change(this.dom, newDom, this.parentElement);\n if (this.parentElement) {\n this.dom = Array.from(this.parentElement.childNodes);\n }\n }\n subscribeForRerender() {\n this.subscriptions.forEach((storeName) => {\n this.renderKit.subscribe(eventName(storeName), () => this.rerender());\n });\n }\n}\nvar bind = ({ Template, viewModel, subscriptions }) => {\n subscriptions = subscriptions || [];\n return (attributes2) => new Bound(Template, viewModel, subscriptions, attributes2);\n};\n// src/messageBus.ts\nclass MessageBus {\n listeners;\n options;\n constructor() {\n this.options = {};\n this.listeners = {};\n }\n subscribe(eventName2, listener) {\n this.ensureListenerCollection(eventName2);\n this.listeners[eventName2].push(listener);\n }\n publish(eventName2, payload) {\n const listeners = this.listeners[eventName2];\n if (!listeners)\n return false;\n listeners.forEach((listener) => {\n listener(payload, this.buildListenerKit(eventName2));\n });\n return true;\n }\n ensureListenerCollection(eventName2) {\n if (this.listeners[eventName2])\n return;\n this.listeners[eventName2] = [];\n }\n buildListenerKit(eventName2) {\n return {\n eventName: eventName2,\n publish: this.publish.bind(this),\n ...this.options\n };\n }\n addListenerOptions(options) {\n this.options = {\n ...this.options,\n ...options\n };\n }\n}\nvar createBus = () => {\n const bus = new MessageBus;\n const publish = bus.publish.bind(bus);\n const subscribe = bus.subscribe.bind(bus);\n return {\n bus,\n publish,\n subscribe\n };\n};\n// src/navigation/routeState.js\nvar createRouteState = (state2) => {\n const store = new RecordStore({\n name: \"route\",\n value: {\n host: \"\",\n path: \"\",\n query: \"\"\n },\n parent: state2\n });\n state2.add(store);\n};\n\n// src/navigation/setupHistory.js\nvar locationChangeEvent = \"locationChange\";\nvar routeChangeEvent = \"routeChange\";\nvar extractQueryParams = (queryString) => {\n return queryString.replace(/^\\?/, \"\").split(\"&\").reduce((aggregate, pairString) => {\n if (!pairString)\n return aggregate;\n const pair = pairString.split(\"=\");\n aggregate[pair[0]] = pair[1];\n return aggregate;\n }, {});\n};\nvar onLocationChange = (_payload, { publish, state: state2 }) => {\n const { host, pathname, search } = window.location;\n const path = pathname;\n const query = extractQueryParams(search);\n state2.route.update({\n host,\n path,\n query\n });\n publish(routeChangeEvent, { host, path, query });\n};\nvar setupHistory = (app) => {\n const { publish, subscribe, state: state2 } = app;\n createRouteState(state2);\n window.addEventListener(\"popstate\", () => publish(locationChangeEvent));\n subscribe(locationChangeEvent, onLocationChange);\n};\n\n// src/navigation/findHref.js\nvar findHref = (node2) => {\n if (!node2 || !node2.getAttribute)\n return \"\";\n while (!node2.getAttribute(\"href\")) {\n node2 = node2.parentNode;\n if (!node2 || !node2.getAttribute)\n return \"\";\n }\n return node2.getAttribute(\"href\");\n};\n\n// src/navigation/setupNavigation.js\nvar linkNavigationEvent = \"goToHref\";\nvar programmaticNavigationEvent = \"navigate\";\nvar navigate = (path, { publish }) => {\n window.history.pushState(null, \"\", path);\n publish(locationChangeEvent);\n};\nvar onLinkClick = (domEvent, { publish }) => {\n if (!domEvent || !domEvent.target)\n return;\n domEvent.preventDefault();\n const href = findHref(domEvent.target);\n navigate(href, { publish });\n};\nvar setupNavigation = (app) => {\n const { subscribe } = app;\n subscribe(linkNavigationEvent, onLinkClick);\n subscribe(programmaticNavigationEvent, navigate);\n};\n\n// src/app.ts\nvar setupBus = (app) => {\n const { publish, subscribe, bus } = createBus();\n app.publish = publish;\n app.subscribe = subscribe;\n app.bus = bus;\n};\nvar setupState = (app) => {\n const state3 = new State(app.publish);\n app.state = state3;\n};\nvar connectBusToState = (app) => {\n const { bus } = app;\n bus.addListenerOptions({ state: app.state });\n};\nvar setupRenderKit = (app, document) => {\n app.renderKit = {\n publish: app.publish,\n subscribe: app.subscribe,\n state: app.state,\n document\n };\n};\nvar triggerRoute = (app) => {\n const publish = app.publish;\n setTimeout(() => {\n publish(locationChangeEvent, null);\n }, 0);\n};\nvar addRender = (app) => {\n app.render = (template, selector) => {\n return render(template, selector, app.renderKit);\n };\n};\nvar createApp = (document = window.document) => {\n const app = {};\n setupBus(app);\n setupState(app);\n connectBusToState(app);\n setupRenderKit(app, document);\n setupHistory(app);\n setupNavigation(app);\n triggerRoute(app);\n addRender(app);\n return app;\n};\n// src/navigation.ts\nvar exports_navigation = {};\n__export(exports_navigation, {\n setupNavigation: () => {\n {\n return setupNavigation;\n }\n },\n setupHistory: () => {\n {\n return setupHistory;\n }\n }\n});\n// src/views/conditionals.jsx\nvar exports_conditionals = {};\n__export(exports_conditionals, {\n Unless: () => {\n {\n return Unless;\n }\n },\n IfElse: () => {\n {\n return IfElse;\n }\n },\n If: () => {\n {\n return If;\n }\n }\n});\nvar If = ({ condition, children: children3 }) => {\n if (!condition)\n return;\n return jsx_default(jsx_default.fragment, null, children3);\n};\nvar Unless = ({ condition, children: children3 }) => {\n if (condition)\n return;\n return jsx_default(jsx_default.fragment, null, children3);\n};\nvar IfElse = ({ condition, children: children3 }) => {\n const [first, ...rest] = children3;\n if (condition)\n return jsx_default(jsx_default.fragment, null, first);\n return jsx_default(jsx_default.fragment, null, rest);\n};\n\n// src/views/link.jsx\nvar Link = ({ children: children3, ...props }) => {\n return jsx_default(\"a\", {\n ...props,\n onClick: \"goToHref\"\n }, children3);\n};\n\n// src/views.js\nvar views = {\n ...exports_conditionals,\n Link\n};\nexport {\n views,\n render,\n exports_navigation as navigation,\n jsx_default as jsx,\n createBus,\n createApp,\n bind,\n State\n};\n","exports.interopDefault = function (a) {\n return a && a.__esModule ? a : {default: a};\n};\n\nexports.defineInteropFlag = function (a) {\n Object.defineProperty(a, '__esModule', {value: true});\n};\n\nexports.exportAll = function (source, dest) {\n Object.keys(source).forEach(function (key) {\n if (\n key === 'default' ||\n key === '__esModule' ||\n Object.prototype.hasOwnProperty.call(dest, key)\n ) {\n return;\n }\n\n Object.defineProperty(dest, key, {\n enumerable: true,\n get: function () {\n return source[key];\n },\n });\n });\n\n return dest;\n};\n\nexports.export = function (dest, destName, get) {\n Object.defineProperty(dest, destName, {\n enumerable: true,\n get: get,\n });\n};\n"],"names":[],"version":3,"file":"add-remove-root-children.3bb9b3f5.js.map","sourceRoot":"/__parcel_source_root/"}
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAI,WAAW;AAAK,IAAI,WAAW;AAAK,IAAI,aAAa;AAAM,IAAI,eAAe;AAAmB,OAAO,MAAM,CAAC,aAAa,GAAG;AAAmB;AAEtJ,iJAAiJ,GACjJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AU,MAAM,EAAE,IAAI;IACxC,OAAO,IAAI,CAAC,QAAQ,OAAO,CAAC,SAAU,GAAG;QACvC,IACE,QAAQ,aACR,QAAQ,gBACR,OAAO,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,MAAM,MAE3C;QAGF,OAAO,cAAc,CAAC,MAAM,KAAK;YAC/B,YAAY;YACZ,KAAK;gBACH,OAAO,MAAM,CAAC,IAAI;YACpB;QACF;IACF;IAEA,OAAO;AACT;AAEA,QAAQ,MAAM,GAAG,SAAU,IAAI,EAAE,QAAQ,EAAE,GAAG;IAC5C,OAAO,cAAc,CAAC,MAAM,UAAU;QACpC,YAAY;QACZ,KAAK;IACP;AACF","sources":["node_modules/@parcel/runtime-browser-hmr/lib/runtime-530046016dc577f1.js","dist/jaxs.js","node_modules/@parcel/transformer-js/src/esmodule-helpers.js"],"sourcesContent":["var HMR_HOST = null;var HMR_PORT = null;var HMR_SECURE = false;var HMR_ENV_HASH = \"d6ea1d42532a7575\";module.bundle.HMR_BUNDLE_ID = \"64a677193bb9b3f5\";\"use strict\";\n\n/* global HMR_HOST, HMR_PORT, HMR_ENV_HASH, HMR_SECURE, chrome, browser, __parcel__import__, __parcel__importScripts__, ServiceWorkerGlobalScope */\n/*::\nimport type {\n HMRAsset,\n HMRMessage,\n} from '@parcel/reporter-dev-server/src/HMRServer.js';\ninterface ParcelRequire {\n (string): mixed;\n cache: {|[string]: ParcelModule|};\n hotData: {|[string]: mixed|};\n Module: any;\n parent: ?ParcelRequire;\n isParcelRequire: true;\n modules: {|[string]: [Function, {|[string]: string|}]|};\n HMR_BUNDLE_ID: string;\n root: ParcelRequire;\n}\ninterface ParcelModule {\n hot: {|\n data: mixed,\n accept(cb: (Function) => void): void,\n dispose(cb: (mixed) => void): void,\n // accept(deps: Array<string> | string, cb: (Function) => void): void,\n // decline(): void,\n _acceptCallbacks: Array<(Function) => void>,\n _disposeCallbacks: Array<(mixed) => void>,\n |};\n}\ninterface ExtensionContext {\n runtime: {|\n reload(): void,\n getURL(url: string): string;\n getManifest(): {manifest_version: number, ...};\n |};\n}\ndeclare var module: {bundle: ParcelRequire, ...};\ndeclare var HMR_HOST: string;\ndeclare var HMR_PORT: string;\ndeclare var HMR_ENV_HASH: string;\ndeclare var HMR_SECURE: boolean;\ndeclare var chrome: ExtensionContext;\ndeclare var browser: ExtensionContext;\ndeclare var __parcel__import__: (string) => Promise<void>;\ndeclare var __parcel__importScripts__: (string) => Promise<void>;\ndeclare var globalThis: typeof self;\ndeclare var ServiceWorkerGlobalScope: Object;\n*/\nvar OVERLAY_ID = '__parcel__error__overlay__';\nvar OldModule = module.bundle.Module;\nfunction Module(moduleName) {\n OldModule.call(this, moduleName);\n this.hot = {\n data: module.bundle.hotData[moduleName],\n _acceptCallbacks: [],\n _disposeCallbacks: [],\n accept: function (fn) {\n this._acceptCallbacks.push(fn || function () {});\n },\n dispose: function (fn) {\n this._disposeCallbacks.push(fn);\n }\n };\n module.bundle.hotData[moduleName] = undefined;\n}\nmodule.bundle.Module = Module;\nmodule.bundle.hotData = {};\nvar checkedAssets /*: {|[string]: boolean|} */, assetsToDispose /*: Array<[ParcelRequire, string]> */, assetsToAccept /*: Array<[ParcelRequire, string]> */;\n\nfunction getHostname() {\n return HMR_HOST || (location.protocol.indexOf('http') === 0 ? location.hostname : 'localhost');\n}\nfunction getPort() {\n return HMR_PORT || location.port;\n}\n\n// eslint-disable-next-line no-redeclare\nvar parent = module.bundle.parent;\nif ((!parent || !parent.isParcelRequire) && typeof WebSocket !== 'undefined') {\n var hostname = getHostname();\n var port = getPort();\n var protocol = HMR_SECURE || location.protocol == 'https:' && !['localhost', '127.0.0.1', '0.0.0.0'].includes(hostname) ? 'wss' : 'ws';\n var ws;\n try {\n ws = new WebSocket(protocol + '://' + hostname + (port ? ':' + port : '') + '/');\n } catch (err) {\n if (err.message) {\n console.error(err.message);\n }\n ws = {};\n }\n\n // Web extension context\n var extCtx = typeof browser === 'undefined' ? typeof chrome === 'undefined' ? null : chrome : browser;\n\n // Safari doesn't support sourceURL in error stacks.\n // eval may also be disabled via CSP, so do a quick check.\n var supportsSourceURL = false;\n try {\n (0, eval)('throw new Error(\"test\"); //# sourceURL=test.js');\n } catch (err) {\n supportsSourceURL = err.stack.includes('test.js');\n }\n\n // $FlowFixMe\n ws.onmessage = async function (event /*: {data: string, ...} */) {\n checkedAssets = {} /*: {|[string]: boolean|} */;\n assetsToAccept = [];\n assetsToDispose = [];\n var data /*: HMRMessage */ = JSON.parse(event.data);\n if (data.type === 'update') {\n // Remove error overlay if there is one\n if (typeof document !== 'undefined') {\n removeErrorOverlay();\n }\n let assets = data.assets.filter(asset => asset.envHash === HMR_ENV_HASH);\n\n // Handle HMR Update\n let handled = assets.every(asset => {\n return asset.type === 'css' || asset.type === 'js' && hmrAcceptCheck(module.bundle.root, asset.id, asset.depsByBundle);\n });\n if (handled) {\n console.clear();\n\n // Dispatch custom event so other runtimes (e.g React Refresh) are aware.\n if (typeof window !== 'undefined' && typeof CustomEvent !== 'undefined') {\n window.dispatchEvent(new CustomEvent('parcelhmraccept'));\n }\n await hmrApplyUpdates(assets);\n\n // Dispose all old assets.\n let processedAssets = {} /*: {|[string]: boolean|} */;\n for (let i = 0; i < assetsToDispose.length; i++) {\n let id = assetsToDispose[i][1];\n if (!processedAssets[id]) {\n hmrDispose(assetsToDispose[i][0], id);\n processedAssets[id] = true;\n }\n }\n\n // Run accept callbacks. This will also re-execute other disposed assets in topological order.\n processedAssets = {};\n for (let i = 0; i < assetsToAccept.length; i++) {\n let id = assetsToAccept[i][1];\n if (!processedAssets[id]) {\n hmrAccept(assetsToAccept[i][0], id);\n processedAssets[id] = true;\n }\n }\n } else fullReload();\n }\n if (data.type === 'error') {\n // Log parcel errors to console\n for (let ansiDiagnostic of data.diagnostics.ansi) {\n let stack = ansiDiagnostic.codeframe ? ansiDiagnostic.codeframe : ansiDiagnostic.stack;\n console.error('🚨 [parcel]: ' + ansiDiagnostic.message + '\\n' + stack + '\\n\\n' + ansiDiagnostic.hints.join('\\n'));\n }\n if (typeof document !== 'undefined') {\n // Render the fancy html overlay\n removeErrorOverlay();\n var overlay = createErrorOverlay(data.diagnostics.html);\n // $FlowFixMe\n document.body.appendChild(overlay);\n }\n }\n };\n ws.onerror = function (e) {\n if (e.message) {\n console.error(e.message);\n }\n };\n ws.onclose = function () {\n console.warn('[parcel] 🚨 Connection to the HMR server was lost');\n };\n}\nfunction removeErrorOverlay() {\n var overlay = document.getElementById(OVERLAY_ID);\n if (overlay) {\n overlay.remove();\n console.log('[parcel] ✨ Error resolved');\n }\n}\nfunction createErrorOverlay(diagnostics) {\n var overlay = document.createElement('div');\n overlay.id = OVERLAY_ID;\n let errorHTML = '<div style=\"background: black; opacity: 0.85; font-size: 16px; color: white; position: fixed; height: 100%; width: 100%; top: 0px; left: 0px; padding: 30px; font-family: Menlo, Consolas, monospace; z-index: 9999;\">';\n for (let diagnostic of diagnostics) {\n let stack = diagnostic.frames.length ? diagnostic.frames.reduce((p, frame) => {\n return `${p}\n<a href=\"/__parcel_launch_editor?file=${encodeURIComponent(frame.location)}\" style=\"text-decoration: underline; color: #888\" onclick=\"fetch(this.href); return false\">${frame.location}</a>\n${frame.code}`;\n }, '') : diagnostic.stack;\n errorHTML += `\n <div>\n <div style=\"font-size: 18px; font-weight: bold; margin-top: 20px;\">\n 🚨 ${diagnostic.message}\n </div>\n <pre>${stack}</pre>\n <div>\n ${diagnostic.hints.map(hint => '<div>💡 ' + hint + '</div>').join('')}\n </div>\n ${diagnostic.documentation ? `<div>📝 <a style=\"color: violet\" href=\"${diagnostic.documentation}\" target=\"_blank\">Learn more</a></div>` : ''}\n </div>\n `;\n }\n errorHTML += '</div>';\n overlay.innerHTML = errorHTML;\n return overlay;\n}\nfunction fullReload() {\n if ('reload' in location) {\n location.reload();\n } else if (extCtx && extCtx.runtime && extCtx.runtime.reload) {\n extCtx.runtime.reload();\n }\n}\nfunction getParents(bundle, id) /*: Array<[ParcelRequire, string]> */{\n var modules = bundle.modules;\n if (!modules) {\n return [];\n }\n var parents = [];\n var k, d, dep;\n for (k in modules) {\n for (d in modules[k][1]) {\n dep = modules[k][1][d];\n if (dep === id || Array.isArray(dep) && dep[dep.length - 1] === id) {\n parents.push([bundle, k]);\n }\n }\n }\n if (bundle.parent) {\n parents = parents.concat(getParents(bundle.parent, id));\n }\n return parents;\n}\nfunction updateLink(link) {\n var href = link.getAttribute('href');\n if (!href) {\n return;\n }\n var newLink = link.cloneNode();\n newLink.onload = function () {\n if (link.parentNode !== null) {\n // $FlowFixMe\n link.parentNode.removeChild(link);\n }\n };\n newLink.setAttribute('href',\n // $FlowFixMe\n href.split('?')[0] + '?' + Date.now());\n // $FlowFixMe\n link.parentNode.insertBefore(newLink, link.nextSibling);\n}\nvar cssTimeout = null;\nfunction reloadCSS() {\n if (cssTimeout) {\n return;\n }\n cssTimeout = setTimeout(function () {\n var links = document.querySelectorAll('link[rel=\"stylesheet\"]');\n for (var i = 0; i < links.length; i++) {\n // $FlowFixMe[incompatible-type]\n var href /*: string */ = links[i].getAttribute('href');\n var hostname = getHostname();\n var servedFromHMRServer = hostname === 'localhost' ? new RegExp('^(https?:\\\\/\\\\/(0.0.0.0|127.0.0.1)|localhost):' + getPort()).test(href) : href.indexOf(hostname + ':' + getPort());\n var absolute = /^https?:\\/\\//i.test(href) && href.indexOf(location.origin) !== 0 && !servedFromHMRServer;\n if (!absolute) {\n updateLink(links[i]);\n }\n }\n cssTimeout = null;\n }, 50);\n}\nfunction hmrDownload(asset) {\n if (asset.type === 'js') {\n if (typeof document !== 'undefined') {\n let script = document.createElement('script');\n script.src = asset.url + '?t=' + Date.now();\n if (asset.outputFormat === 'esmodule') {\n script.type = 'module';\n }\n return new Promise((resolve, reject) => {\n var _document$head;\n script.onload = () => resolve(script);\n script.onerror = reject;\n (_document$head = document.head) === null || _document$head === void 0 || _document$head.appendChild(script);\n });\n } else if (typeof importScripts === 'function') {\n // Worker scripts\n if (asset.outputFormat === 'esmodule') {\n return __parcel__import__(asset.url + '?t=' + Date.now());\n } else {\n return new Promise((resolve, reject) => {\n try {\n __parcel__importScripts__(asset.url + '?t=' + Date.now());\n resolve();\n } catch (err) {\n reject(err);\n }\n });\n }\n }\n }\n}\nasync function hmrApplyUpdates(assets) {\n global.parcelHotUpdate = Object.create(null);\n let scriptsToRemove;\n try {\n // If sourceURL comments aren't supported in eval, we need to load\n // the update from the dev server over HTTP so that stack traces\n // are correct in errors/logs. This is much slower than eval, so\n // we only do it if needed (currently just Safari).\n // https://bugs.webkit.org/show_bug.cgi?id=137297\n // This path is also taken if a CSP disallows eval.\n if (!supportsSourceURL) {\n let promises = assets.map(asset => {\n var _hmrDownload;\n return (_hmrDownload = hmrDownload(asset)) === null || _hmrDownload === void 0 ? void 0 : _hmrDownload.catch(err => {\n // Web extension fix\n if (extCtx && extCtx.runtime && extCtx.runtime.getManifest().manifest_version == 3 && typeof ServiceWorkerGlobalScope != 'undefined' && global instanceof ServiceWorkerGlobalScope) {\n extCtx.runtime.reload();\n return;\n }\n throw err;\n });\n });\n scriptsToRemove = await Promise.all(promises);\n }\n assets.forEach(function (asset) {\n hmrApply(module.bundle.root, asset);\n });\n } finally {\n delete global.parcelHotUpdate;\n if (scriptsToRemove) {\n scriptsToRemove.forEach(script => {\n if (script) {\n var _document$head2;\n (_document$head2 = document.head) === null || _document$head2 === void 0 || _document$head2.removeChild(script);\n }\n });\n }\n }\n}\nfunction hmrApply(bundle /*: ParcelRequire */, asset /*: HMRAsset */) {\n var modules = bundle.modules;\n if (!modules) {\n return;\n }\n if (asset.type === 'css') {\n reloadCSS();\n } else if (asset.type === 'js') {\n let deps = asset.depsByBundle[bundle.HMR_BUNDLE_ID];\n if (deps) {\n if (modules[asset.id]) {\n // Remove dependencies that are removed and will become orphaned.\n // This is necessary so that if the asset is added back again, the cache is gone, and we prevent a full page reload.\n let oldDeps = modules[asset.id][1];\n for (let dep in oldDeps) {\n if (!deps[dep] || deps[dep] !== oldDeps[dep]) {\n let id = oldDeps[dep];\n let parents = getParents(module.bundle.root, id);\n if (parents.length === 1) {\n hmrDelete(module.bundle.root, id);\n }\n }\n }\n }\n if (supportsSourceURL) {\n // Global eval. We would use `new Function` here but browser\n // support for source maps is better with eval.\n (0, eval)(asset.output);\n }\n\n // $FlowFixMe\n let fn = global.parcelHotUpdate[asset.id];\n modules[asset.id] = [fn, deps];\n } else if (bundle.parent) {\n hmrApply(bundle.parent, asset);\n }\n }\n}\nfunction hmrDelete(bundle, id) {\n let modules = bundle.modules;\n if (!modules) {\n return;\n }\n if (modules[id]) {\n // Collect dependencies that will become orphaned when this module is deleted.\n let deps = modules[id][1];\n let orphans = [];\n for (let dep in deps) {\n let parents = getParents(module.bundle.root, deps[dep]);\n if (parents.length === 1) {\n orphans.push(deps[dep]);\n }\n }\n\n // Delete the module. This must be done before deleting dependencies in case of circular dependencies.\n delete modules[id];\n delete bundle.cache[id];\n\n // Now delete the orphans.\n orphans.forEach(id => {\n hmrDelete(module.bundle.root, id);\n });\n } else if (bundle.parent) {\n hmrDelete(bundle.parent, id);\n }\n}\nfunction hmrAcceptCheck(bundle /*: ParcelRequire */, id /*: string */, depsByBundle /*: ?{ [string]: { [string]: string } }*/) {\n if (hmrAcceptCheckOne(bundle, id, depsByBundle)) {\n return true;\n }\n\n // Traverse parents breadth first. All possible ancestries must accept the HMR update, or we'll reload.\n let parents = getParents(module.bundle.root, id);\n let accepted = false;\n while (parents.length > 0) {\n let v = parents.shift();\n let a = hmrAcceptCheckOne(v[0], v[1], null);\n if (a) {\n // If this parent accepts, stop traversing upward, but still consider siblings.\n accepted = true;\n } else {\n // Otherwise, queue the parents in the next level upward.\n let p = getParents(module.bundle.root, v[1]);\n if (p.length === 0) {\n // If there are no parents, then we've reached an entry without accepting. Reload.\n accepted = false;\n break;\n }\n parents.push(...p);\n }\n }\n return accepted;\n}\nfunction hmrAcceptCheckOne(bundle /*: ParcelRequire */, id /*: string */, depsByBundle /*: ?{ [string]: { [string]: string } }*/) {\n var modules = bundle.modules;\n if (!modules) {\n return;\n }\n if (depsByBundle && !depsByBundle[bundle.HMR_BUNDLE_ID]) {\n // If we reached the root bundle without finding where the asset should go,\n // there's nothing to do. Mark as \"accepted\" so we don't reload the page.\n if (!bundle.parent) {\n return true;\n }\n return hmrAcceptCheck(bundle.parent, id, depsByBundle);\n }\n if (checkedAssets[id]) {\n return true;\n }\n checkedAssets[id] = true;\n var cached = bundle.cache[id];\n assetsToDispose.push([bundle, id]);\n if (!cached || cached.hot && cached.hot._acceptCallbacks.length) {\n assetsToAccept.push([bundle, id]);\n return true;\n }\n}\nfunction hmrDispose(bundle /*: ParcelRequire */, id /*: string */) {\n var cached = bundle.cache[id];\n bundle.hotData[id] = {};\n if (cached && cached.hot) {\n cached.hot.data = bundle.hotData[id];\n }\n if (cached && cached.hot && cached.hot._disposeCallbacks.length) {\n cached.hot._disposeCallbacks.forEach(function (cb) {\n cb(bundle.hotData[id]);\n });\n }\n delete bundle.cache[id];\n}\nfunction hmrAccept(bundle /*: ParcelRequire */, id /*: string */) {\n // Execute the module.\n bundle(id);\n\n // Run the accept callbacks in the new version of the module.\n var cached = bundle.cache[id];\n if (cached && cached.hot && cached.hot._acceptCallbacks.length) {\n cached.hot._acceptCallbacks.forEach(function (cb) {\n var assetsToAlsoAccept = cb(function () {\n return getParents(module.bundle.root, id);\n });\n if (assetsToAlsoAccept && assetsToAccept.length) {\n assetsToAlsoAccept.forEach(function (a) {\n hmrDispose(a[0], a[1]);\n });\n\n // $FlowFixMe[method-unbinding]\n assetsToAccept.push.apply(assetsToAccept, assetsToAlsoAccept);\n }\n });\n }\n}","var __defProp = Object.defineProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, {\n get: all[name],\n enumerable: true,\n configurable: true,\n set: (newValue) => all[name] = () => newValue\n });\n};\n\n// src/rendering/dom/create.ts\nvar setAttributesOnElement = (element, attributes) => {\n for (const key in attributes) {\n if (key === \"__self\")\n continue;\n if (key === \"value\") {\n element.value = attributes[key];\n } else {\n element.setAttribute(key, attributes[key]);\n }\n }\n};\nvar setEventsOnElement = (element, events, publish) => {\n const eventMaps = {};\n for (const domEvent in events) {\n const eventName = events[domEvent];\n const listener = (event) => publish(eventName, event);\n element.addEventListener(domEvent, listener);\n eventMaps[domEvent] = {\n domEvent,\n busEvent: eventName,\n listener\n };\n }\n element.eventMaps = eventMaps;\n};\nvar createNode = (type, document) => {\n document = document || window.document;\n return document.createElement(type);\n};\nvar createTextNode = (value, document) => {\n document = document || window.document;\n return document.createTextNode(value);\n};\nvar createDecoratedNode = (type, attributes, events, renderKit) => {\n const dom = createNode(type, renderKit.document);\n setAttributesOnElement(dom, attributes);\n setEventsOnElement(dom, events, renderKit.publish);\n return dom;\n};\n\n// src/rendering/dom/attributesAndEvents.ts\nvar separateAttrsAndEvents = (combined, defaultValue = \"\") => {\n const attributes = {};\n const events = {};\n for (const key in combined) {\n const value = combined[key];\n if (key.match(/^on.+/i)) {\n const eventKey = key.slice(2).toLowerCase();\n events[eventKey] = value;\n } else {\n attributes[key] = normalizeValueForKey(combined, key, defaultValue);\n }\n }\n return {\n attributes,\n events\n };\n};\nvar normalizeValueForKey = (object, key, defaultValue = \"\") => {\n if (object[key] === undefined)\n return defaultValue;\n return object[key];\n};\n\n// src/rendering/dom/svg.ts\nvar namespace = \"http://www.w3.org/2000/svg\";\nvar isSvgTag = (tagType) => tagType === \"svg\";\nvar isSvg = (element) => element.namespaceURI === namespace;\nvar createSvgNode = (type, attributes, renderKit) => {\n const document = renderKit && renderKit.document || window.document;\n const node = document.createElementNS(namespace, type);\n for (const key in attributes) {\n if (key === \"__self\" || key === \"xmlns\")\n continue;\n node.setAttributeNS(null, key, attributes[key]);\n }\n return node;\n};\n\n// src/rendering/templates/text.ts\nclass TextTemplate {\n value;\n constructor(content) {\n this.value = content.toString();\n }\n render(renderKit) {\n const textNode = createTextNode(this.value, renderKit.document);\n if (!textNode)\n return [];\n textNode.__jsx = \"TextNode\";\n return [textNode];\n }\n}\n\n// src/rendering/templates/children.ts\nvar ensureArray = (children) => {\n if (Array.isArray(children)) {\n return children.flat();\n }\n if (!children) {\n return [];\n }\n return [children];\n};\nvar recursiveRender = (children, renderKit, rendered = []) => children.reduce(renderReducer(renderKit), rendered).flat();\nvar renderReducer = (renderKit) => (aggregate, view) => {\n if (!view)\n return aggregate;\n if (Array.isArray(view)) {\n const dom = recursiveRender(view, renderKit, aggregate);\n return dom;\n }\n view.render(renderKit).forEach((template) => aggregate.push(template));\n return aggregate;\n};\nvar replaceTextNodes = (child) => {\n if (isTextNode(child)) {\n return textNode(child);\n }\n return child;\n};\nvar isTextNode = (child) => {\n return typeof child === \"string\" || typeof child === \"number\";\n};\nvar textNode = (content) => {\n return new TextTemplate(content);\n};\nvar withSvgFlag = (isSvg2) => (template) => {\n template && (template.isSvg = template.isSvg || isSvg2);\n return template;\n};\n\nclass Children {\n collection;\n parentElement;\n isSvg;\n constructor(jsxChildren, isSvg2 = false) {\n this.collection = ensureArray(jsxChildren);\n this.collection = this.collection.map(replaceTextNodes);\n this.collection = this.collection.flat();\n this.collection = this.collection.map(withSvgFlag(isSvg2));\n this.isSvg = isSvg2;\n }\n render(renderKit, parentElement) {\n this.parentElement = parentElement;\n const dom = this.generateDom(renderKit);\n this.attachToParent(dom);\n return dom;\n }\n generateDom(renderKit) {\n return recursiveRender(this.collection, renderKit);\n }\n attachToParent(dom) {\n if (this.parentElement === undefined)\n return;\n const parent = this.parentElement;\n dom.forEach((node) => parent.appendChild(node));\n }\n}\n\n// src/rendering/templates/tag.ts\nclass Tag {\n type;\n events;\n attributes;\n children;\n isSvg;\n constructor(tagType, combinedAttributes, children2, isSvg2 = false) {\n this.type = tagType;\n const { events, attributes } = separateAttrsAndEvents(combinedAttributes);\n this.events = events;\n this.attributes = attributes;\n this.isSvg = isSvg2 || isSvgTag(this.type);\n this.children = new Children(children2, this.isSvg);\n }\n render(renderKit) {\n const dom = this.generateDom(renderKit);\n if (!dom)\n return [];\n this.children.render(renderKit, dom);\n return [dom];\n }\n generateDom(renderKit) {\n if (this.isSvg) {\n return this.generateSvnDom(renderKit);\n } else {\n return this.generateHtmlDom(renderKit);\n }\n }\n generateHtmlDom(renderKit) {\n const node = createDecoratedNode(this.type, this.attributes, this.events, renderKit);\n node.__jsx = this.key();\n return node;\n }\n generateSvnDom(renderKit) {\n const node = createSvgNode(this.type, this.attributes, renderKit);\n node.__jsx = this.key();\n return node;\n }\n key() {\n return this.attributes.key || this.source() || this.createKey();\n }\n source() {\n if (this.attributes.__source) {\n const { fileName, lineNumber, columnNumber } = this.attributes.__source;\n return `${fileName}:${lineNumber}:${columnNumber}`;\n }\n }\n createKey() {\n const id = this.attributes.id ? `#${this.attributes.id}` : \"\";\n const type = this.attributes.type ? `[type=${this.attributes.type}]` : \"\";\n const name = this.attributes.name ? `[name=${this.attributes.name}]` : \"\";\n return `${this.type}${id}${type}${name}`;\n }\n}\n\n// src/jsx.js\nvar ensureChildrenArray = (maybeChildren, attributes) => maybeChildren || attributes.children || [];\nvar packageAttributes = (maybeAttributes, maybeChildren) => {\n const attributes = maybeAttributes || {};\n const children3 = ensureChildrenArray(maybeChildren, attributes);\n attributes.children = attributes.children || children3;\n return attributes;\n};\nvar jsx = (type, attributes, ...children3) => {\n if (typeof type === \"string\") {\n return new Tag(type, attributes, children3);\n }\n return type(packageAttributes(attributes, children3));\n};\njsx.fragment = (attributes, maybeChildren) => {\n const children3 = ensureChildrenArray(maybeChildren, attributes);\n return new Children(children3);\n};\nvar jsx_default = jsx;\n// src/rendering/templates/root.ts\nclass Root {\n template;\n selector;\n renderKit;\n dom;\n parentElement;\n constructor(template, selector, renderKit) {\n this.template = template;\n this.selector = selector;\n this.renderKit = renderKit;\n this.dom = [];\n this.parentElement = null;\n }\n renderAndAttach(renderKit) {\n this.parentElement = this.getParentElement();\n this.dom = this.render({ ...renderKit, parent: this.parentElement });\n if (this.parentElement) {\n this.attach();\n }\n }\n render(renderKit) {\n return this.template.render(renderKit);\n }\n attach() {\n this.parentElement && (this.parentElement.innerHTML = \"\");\n this.dom.forEach((element) => {\n this.parentElement && this.parentElement.appendChild(element);\n });\n }\n getParentElement() {\n return this.renderKit.document.querySelector(this.selector);\n }\n}\nvar render = (template, selector, renderKit) => {\n const root = new Root(template, selector, renderKit);\n root.renderAndAttach(renderKit);\n return root;\n};\n// src/state/testingTypes.js\nvar isBoolean = (value) => typeof value === \"boolean\";\nvar isNumber = (value) => typeof value === \"number\";\nvar isString = (value) => typeof value === \"string\";\nvar isArray = (value) => Array.isArray(value);\nvar isObject = (value) => value !== null && !isArray(value) && typeof value === \"object\";\n\n// src/state/equality.js\nvar areElementEqual = (oldValue, newValue) => oldValue === newValue;\nvar keyLengthSame = (oldValue, newValue) => Object.keys(oldValue).length === Object.keys(newValue).length;\nvar areObjectsEqual = (oldValue, newValue) => {\n if (!(isObject(oldValue) && isObject(newValue)))\n return false;\n if (!keyLengthSame(oldValue, newValue))\n return false;\n Object.keys(oldValue).every((key) => {\n const oldInnerValue = oldValue[key];\n const newInnerValue = newValue[key];\n return areEqual(oldInnerValue, newInnerValue);\n });\n};\nvar areArraysEqual = (oldValue, newValue) => {\n if (!(isArray(oldValue) && isArray(newValue)))\n return false;\n if (oldValue.length !== newValue.length)\n return false;\n oldValue.every((oldInnerValue, index) => {\n const newInnerValue = newValue[index];\n return areEqual(oldInnerValue, newInnerValue);\n });\n};\nvar areEqual = (oldValue, newValue) => {\n if (isObject(oldValue))\n return areObjectsEqual(oldValue, newValue);\n if (isArray(oldValue))\n return areArraysEqual(oldValue, newValue);\n return areElementEqual(oldValue, newValue);\n};\n\n// src/state/stores.js\nclass GeneralStore {\n nullEvent = {};\n constructor({ name, value, parent }) {\n this.name = name;\n this.value = value;\n this.parent = parent;\n this.initialState = value;\n }\n update(newValue) {\n if (this.isEqual(newValue))\n return;\n this.value = newValue;\n return this.parent.publish(this.event());\n }\n reset() {\n this.update(this.initialState);\n }\n isEqual(newValue) {\n return areElementEqual(this.value, newValue);\n }\n event() {\n return {\n name: this.name,\n value: this.value\n };\n }\n}\n\nclass BooleanStore extends GeneralStore {\n toggle() {\n this.update(!this.value);\n }\n}\n\nclass NumericStore extends GeneralStore {\n}\n\nclass StringStore extends GeneralStore {\n}\n\nclass ListStore extends GeneralStore {\n isEqual(newValue) {\n return areArraysEqual(this.value, newValue);\n }\n push(newValue) {\n const value = [...this.value, newValue];\n this.update(value);\n }\n}\n\nclass RecordStore extends GeneralStore {\n isEqual(newValue) {\n return areObjectsEqual(this.value, newValue);\n }\n}\n\n// src/state.js\nvar eventPrefix = \"state-change\";\nvar eventName = (name) => `${eventPrefix}:${name}`;\n\nclass State {\n constructor(publish) {\n this.publisher = publish;\n this.stores = {};\n this.events = [];\n this.transacting = false;\n }\n create(name, value) {\n const StoreClass = this.storeTypeFor(value);\n const store = new StoreClass({ name, value, parent: this });\n this.addStore(name, store);\n }\n add(store) {\n const name = store.name;\n this.addStore(name, store);\n }\n getStore(name) {\n return this.stores[name];\n }\n addStore(name, store) {\n this.stores[name] = store;\n this[name] = store;\n }\n storeTypeFor(value) {\n if (isArray(value))\n return ListStore;\n if (isObject(value))\n return RecordStore;\n if (isNumber(value))\n return NumericStore;\n if (isBoolean(value))\n return BooleanStore;\n if (isString(value))\n return StringStore;\n return GeneralStore;\n }\n publish(event) {\n this.events.push(event);\n if (!this.transacting)\n this.publishAll();\n }\n publishAll() {\n const publishedStores = [];\n this.events.reverse().forEach((event) => {\n const { name, value } = event;\n if (!publishedStores.includes(name)) {\n publishedStores.push(name);\n this.publisher(`${eventPrefix}:${name}`, value);\n }\n });\n this.events = [];\n }\n transaction(setter) {\n this.transacting = true;\n setter(this);\n this.transacting = false;\n this.publishAll();\n }\n value() {\n return Object.keys(this.stores).reduce((valueObject, key) => {\n valueObject[key] = this.stores[key].value;\n return valueObject;\n }, {});\n }\n}\n\n// src/types.ts\nvar ChangeInstructions;\n(function(ChangeInstructions2) {\n ChangeInstructions2[ChangeInstructions2[\"removeNode\"] = 0] = \"removeNode\";\n ChangeInstructions2[ChangeInstructions2[\"insertNode\"] = 1] = \"insertNode\";\n ChangeInstructions2[ChangeInstructions2[\"replaceNode\"] = 2] = \"replaceNode\";\n ChangeInstructions2[ChangeInstructions2[\"removeAttribute\"] = 3] = \"removeAttribute\";\n ChangeInstructions2[ChangeInstructions2[\"addAttribute\"] = 4] = \"addAttribute\";\n ChangeInstructions2[ChangeInstructions2[\"updateAttribute\"] = 5] = \"updateAttribute\";\n ChangeInstructions2[ChangeInstructions2[\"removeEvent\"] = 6] = \"removeEvent\";\n ChangeInstructions2[ChangeInstructions2[\"addEvent\"] = 7] = \"addEvent\";\n ChangeInstructions2[ChangeInstructions2[\"updateEvent\"] = 8] = \"updateEvent\";\n ChangeInstructions2[ChangeInstructions2[\"changeValue\"] = 9] = \"changeValue\";\n ChangeInstructions2[ChangeInstructions2[\"changeText\"] = 10] = \"changeText\";\n})(ChangeInstructions || (ChangeInstructions = {}));\n\n// src/rendering/change/instructions/generate.ts\nvar changeText = (source, target) => ({\n source,\n target,\n type: ChangeInstructions.changeText,\n data: {}\n});\nvar replaceNode = (source, target) => ({\n source,\n target,\n type: ChangeInstructions.replaceNode,\n data: {}\n});\nvar removeAttribute = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.removeAttribute\n});\nvar addAttribute = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.addAttribute\n});\nvar updateAttribute = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.updateAttribute\n});\nvar removeEvent = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.removeEvent\n});\nvar addEvent = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.addEvent\n});\nvar updateEvent = (source, target, data) => ({\n source,\n target,\n data,\n type: ChangeInstructions.updateEvent\n});\nvar removeNode = (source) => ({\n source,\n target: source,\n type: ChangeInstructions.removeNode,\n data: {}\n});\nvar insertNode = (target, data) => ({\n target,\n source: target,\n type: ChangeInstructions.insertNode,\n data\n});\nvar changeValue = (source, target, data) => ({\n source,\n target,\n type: ChangeInstructions.changeValue,\n data\n});\n\n// src/rendering/change/instructions/idMap.js\nvar nullMatch = { index: -1 };\n\nclass IdMap {\n constructor() {\n this.map = {};\n }\n populate(list) {\n list.forEach((element, i) => {\n const id = element.__jsx;\n if (id) {\n this.map[id] = this.map[id] || [];\n this.map[id].push({\n element,\n index: i\n });\n }\n });\n }\n pullMatch(element) {\n const id = element && element.__jsx;\n if (!id)\n return nullMatch;\n if (!(this.map[id] && this.map[id].length))\n return nullMatch;\n return this.map[id].shift();\n }\n clear(element) {\n const id = element && element.__jsx;\n if (!(id && this.map[id] && this.map[id].length))\n return;\n const matches = this.map[id];\n this.map[id] = matches.reduce((collection, possibleMatch) => {\n if (possibleMatch.element !== element)\n collection.push(possibleMatch);\n return collection;\n }, []);\n }\n check(element) {\n const id = element && element.__jsx;\n if (!(id && this.map[id]))\n return false;\n return this.map[id].length > 0;\n }\n remaining() {\n return Object.values(this.map).flat();\n }\n}\nvar createIdMap = (list) => {\n const map = new IdMap;\n map.populate(list);\n return map;\n};\n\n// src/rendering/change/instructions/attributes.ts\nvar compileForAttributes = (source, target, isSvg2 = false) => {\n const instructions = [];\n const sourceAttributes = source.attributes;\n const sourceLength = sourceAttributes.length;\n const targetAttributes = target.attributes;\n const targetLength = targetAttributes.length;\n let index;\n let innerIndex;\n let matchingAttribute;\n for (index = 0;index < sourceLength; index++) {\n matchingAttribute = null;\n const sourceAttribute = sourceAttributes.item(index);\n if (!sourceAttribute)\n continue;\n for (innerIndex = 0;innerIndex < targetLength; innerIndex++) {\n const targetAttribute = targetAttributes.item(innerIndex);\n if (!targetAttribute)\n continue;\n if (sourceAttribute.name == targetAttribute.name) {\n matchingAttribute = targetAttribute;\n break;\n }\n }\n if (!matchingAttribute) {\n instructions.push(removeAttribute(source, target, { name: sourceAttribute.name, isSvg: isSvg2 }));\n } else if (sourceAttribute.value !== matchingAttribute.value) {\n instructions.push(updateAttribute(source, target, {\n name: sourceAttribute.name,\n value: matchingAttribute.value,\n isSvg: isSvg2\n }));\n }\n }\n for (index = 0;index < targetLength; index++) {\n matchingAttribute = null;\n const targetAttribute = targetAttributes.item(index);\n if (!targetAttribute)\n continue;\n for (innerIndex = 0;innerIndex < sourceLength; innerIndex++) {\n const sourceAttribute = sourceAttributes.item(innerIndex);\n if (!sourceAttribute)\n continue;\n if (sourceAttribute.name == targetAttribute.name) {\n matchingAttribute = sourceAttribute;\n break;\n }\n }\n if (!matchingAttribute) {\n instructions.push(addAttribute(source, target, {\n name: targetAttribute.name,\n value: targetAttribute.value,\n isSvg: isSvg2\n }));\n }\n }\n return instructions;\n};\n\n// src/rendering/change/instructions/events.ts\nvar compileForEvents = (source, target) => {\n const instructions = [];\n const sourceEventMaps = source.eventMaps;\n const targetEventMaps = target.eventMaps;\n const sourceDomEvents = Object.keys(sourceEventMaps);\n const targetDomEvents = Object.keys(targetEventMaps);\n sourceDomEvents.forEach((domEvent) => {\n const sourceEventMap = sourceEventMaps[domEvent];\n const targetEventMap = targetEventMaps[domEvent];\n if (!targetEventMap) {\n instructions.push(removeEvent(source, target, {\n name: sourceEventMap.domEvent,\n value: sourceEventMap.listener\n }));\n } else if (targetEventMap.busEvent !== sourceEventMap.busEvent) {\n instructions.push(updateEvent(source, target, {\n name: domEvent,\n targetValue: targetEventMap.listener,\n sourceValue: sourceEventMap.listener\n }));\n }\n });\n targetDomEvents.forEach((domEvent) => {\n const sourceEventMap = sourceEventMaps[domEvent];\n const targetEventMap = targetEventMaps[domEvent];\n if (!sourceEventMap) {\n instructions.push(addEvent(source, target, {\n name: targetEventMap.domEvent,\n value: targetEventMap.listener\n }));\n }\n });\n return instructions;\n};\n\n// src/rendering/change/instructions/element.ts\nvar compileForElement = (source, target) => {\n const attributeInstructions = compileForAttributes(source, target);\n const eventInstructions = compileForEvents(source, target);\n const valueInstructions = compileForInputValue(source, target);\n return attributeInstructions.concat(eventInstructions).concat(valueInstructions);\n};\nvar compileForSvg = (source, target) => {\n return compileForAttributes(source, target, true);\n};\nvar compileForInputValue = (sourceElement, targetElement) => {\n const instructions = [];\n if (sourceElement.tagName !== \"INPUT\") {\n return instructions;\n }\n const source = sourceElement;\n const target = targetElement;\n if (source.value !== target.value) {\n instructions.push(changeValue(source, target, { name: \"value\", value: target.value }));\n }\n return instructions;\n};\n\n// src/rendering/change/instructions/text.ts\nvar compileForText = (source, target) => {\n if (source.textContent !== target.textContent) {\n return [changeText(source, target)];\n }\n return [];\n};\n\n// src/rendering/change/instructions/node.ts\nvar NodeTypes;\n(function(NodeTypes2) {\n NodeTypes2[NodeTypes2[\"ElementNode\"] = 1] = \"ElementNode\";\n NodeTypes2[NodeTypes2[\"TextNode\"] = 3] = \"TextNode\";\n})(NodeTypes || (NodeTypes = {}));\nvar compileForNodeGenerator = (compileForCollection) => (source, target) => {\n let instructions = [];\n if (source.nodeType === NodeTypes.ElementNode && isSvg(source)) {\n const sourceElement = source;\n const targetElement = target;\n const baseInstructions = compileForSvg(sourceElement, targetElement);\n const childrenInstructions = compileForCollection(sourceElement.childNodes, targetElement.childNodes, sourceElement);\n instructions = baseInstructions.concat(childrenInstructions);\n } else if (source.nodeType === NodeTypes.ElementNode) {\n const sourceElement = source;\n const targetElement = target;\n const baseInstructions = compileForElement(sourceElement, targetElement);\n const childrenInstructions = compileForCollection(sourceElement.childNodes, targetElement.childNodes, sourceElement);\n instructions = baseInstructions.concat(childrenInstructions);\n } else if (source.nodeType === NodeTypes.TextNode) {\n instructions = compileForText(source, target);\n }\n return instructions;\n};\n\n// src/rendering/change/instructions/children.ts\nvar compileChildren = (sourceList, targetList, parent) => {\n const baseInstructions = [];\n const length = largerLength(sourceList, targetList);\n const sourceMap = createIdMap(sourceList);\n const targetMap = createIdMap(targetList);\n const nodesPairsToDiff = [];\n let index = 0;\n for (;index < length; index++) {\n const source = sourceList[index];\n const target = targetList[index];\n if (target && targetMap.check(target)) {\n const matchingSource = sourceMap.pullMatch(target);\n targetMap.clear(target);\n if (matchingSource.element) {\n if (matchingSource.index !== index) {\n baseInstructions.push(insertNode(matchingSource.element, { parent, index }));\n }\n nodesPairsToDiff.push({\n source: matchingSource.element,\n target\n });\n } else if (source) {\n if (targetMap.check(source)) {\n baseInstructions.push(insertNode(target, { parent, index }));\n } else {\n sourceMap.clear(source);\n baseInstructions.push(replaceNode(source, target));\n }\n } else {\n baseInstructions.push(insertNode(target, { parent, index }));\n }\n } else if (source) {\n const matchingSource = sourceMap.pullMatch(source);\n if (matchingSource.element) {\n baseInstructions.push(removeNode(source));\n }\n }\n }\n sourceMap.remaining().forEach(({ element: element2 }) => {\n baseInstructions.push(removeNode(element2));\n });\n const nodeInstructions = nodesPairsToDiff.reduce((collection, { source, target }) => {\n return collection.concat(compileForNode(source, target));\n }, []);\n return baseInstructions.concat(nodeInstructions).sort(instructionsSorter);\n};\nvar instructionsSorter = (left, right) => {\n if (left.type > right.type)\n return 1;\n if (left.type < right.type)\n return -1;\n return 0;\n};\nvar largerLength = (sourceList, targetList) => {\n const sourceLength = Array.from(sourceList).length;\n const targetLength = Array.from(targetList).length;\n return sourceLength > targetLength ? sourceLength : targetLength;\n};\nvar compileForNode = compileForNodeGenerator(compileChildren);\n// src/rendering/change.ts\nvar change = (source, target, parent) => {\n const instructions = compileChildren(source, target, parent);\n instructions.forEach((instruction) => {\n performInstruction(instruction);\n });\n};\nvar performInstruction = (instruction) => {\n const performer = performers[instruction.type] || noop;\n performer(instruction);\n};\nvar noop = (_instruction) => {\n};\nvar changeText2 = (instruction) => {\n const { source, target } = instruction;\n source.nodeValue = target.textContent;\n};\nvar removeNode2 = (instruction) => {\n const { source } = instruction;\n source.remove();\n};\nvar insertNode2 = (instruction) => {\n const { target, data } = instruction;\n const { parent, index } = data;\n const sibling = parent.childNodes[index];\n if (!sibling) {\n parent.appendChild(target);\n } else if (sibling && sibling !== target) {\n parent.insertBefore(target, sibling);\n }\n};\nvar replaceNode2 = (instruction) => {\n const { source, target } = instruction;\n source.replaceWith(target);\n};\nvar removeAttribute2 = (instruction) => {\n const { source, data } = instruction;\n const { name, isSvg: isSvg2 } = data;\n if (isSvg2) {\n source.removeAttributeNS(null, name);\n } else {\n source.removeAttribute(name);\n }\n};\nvar addAttribute2 = (instruction) => {\n const { source, data } = instruction;\n const { name, value, isSvg: isSvg2 } = data;\n if (isSvg2) {\n source.setAttributeNS(null, name, value);\n } else {\n source.setAttribute(name, value);\n }\n};\nvar updateAttribute2 = (instruction) => {\n addAttribute2(instruction);\n};\nvar removeEvent2 = (instruction) => {\n const data = instruction.data;\n const source = instruction.source;\n const { name, value } = data;\n source.removeEventListener(name, value);\n};\nvar addEvent2 = (instruction) => {\n const data = instruction.data;\n const source = instruction.source;\n const { name, value } = data;\n source.addEventListener(name, value);\n};\nvar updateEvent2 = (instruction) => {\n const data = instruction.data;\n const source = instruction.source;\n const { name, sourceValue, targetValue } = data;\n source.removeEventListener(name, sourceValue);\n source.addEventListener(name, targetValue);\n};\nvar changeValue2 = (instruction) => {\n const data = instruction.data;\n const source = instruction.source;\n const { value } = data;\n source.value = value;\n};\nvar performers = {\n [ChangeInstructions.changeText]: changeText2,\n [ChangeInstructions.removeNode]: removeNode2,\n [ChangeInstructions.insertNode]: insertNode2,\n [ChangeInstructions.replaceNode]: replaceNode2,\n [ChangeInstructions.removeAttribute]: removeAttribute2,\n [ChangeInstructions.addAttribute]: addAttribute2,\n [ChangeInstructions.updateAttribute]: updateAttribute2,\n [ChangeInstructions.removeEvent]: removeEvent2,\n [ChangeInstructions.addEvent]: addEvent2,\n [ChangeInstructions.updateEvent]: updateEvent2,\n [ChangeInstructions.changeValue]: changeValue2\n};\n\n// src/rendering/templates/bound.js\nclass Bound {\n constructor(TemplateClass, viewModel, subscriptions, attributes2) {\n this.TemplateClass = TemplateClass;\n this.viewModel = viewModel;\n this.attributes = attributes2 || {};\n this.subscriptions = subscriptions;\n this.dom = [];\n }\n render(renderKit) {\n this.parentElement = renderKit.parent;\n this.renderKit = renderKit;\n this.subscribeForRerender();\n this.dom = this._render(renderKit);\n return this.dom;\n }\n _render(renderKit) {\n const props = {\n ...this.attributes,\n ...this.viewModel(renderKit.state.value())\n };\n const template = this.TemplateClass(props);\n const dom = !template ? [] : template.render(renderKit);\n return dom;\n }\n rerender() {\n if (!this.parentElement) {\n this.parentElement = this.dom[0] && this.dom[0].parentElement;\n }\n const newDom = this._render(this.renderKit);\n change(this.dom, newDom, this.parentElement);\n if (this.parentElement) {\n this.dom = Array.from(this.parentElement.childNodes);\n }\n }\n subscribeForRerender() {\n this.subscriptions.forEach((storeName) => {\n this.renderKit.subscribe(eventName(storeName), () => this.rerender());\n });\n }\n}\nvar bind = ({ Template, viewModel, subscriptions }) => {\n subscriptions = subscriptions || [];\n return (attributes2) => new Bound(Template, viewModel, subscriptions, attributes2);\n};\n// src/messageBus.ts\nclass MessageBus {\n listeners;\n options;\n constructor() {\n this.options = {};\n this.listeners = {};\n }\n subscribe(eventName2, listener) {\n this.ensureListenerCollection(eventName2);\n this.listeners[eventName2].push(listener);\n }\n publish(eventName2, payload) {\n const listeners = this.listeners[eventName2];\n if (!listeners)\n return false;\n listeners.forEach((listener) => {\n listener(payload, this.buildListenerKit(eventName2));\n });\n return true;\n }\n ensureListenerCollection(eventName2) {\n if (this.listeners[eventName2])\n return;\n this.listeners[eventName2] = [];\n }\n buildListenerKit(eventName2) {\n return {\n eventName: eventName2,\n publish: this.publish.bind(this),\n ...this.options\n };\n }\n addListenerOptions(options) {\n this.options = {\n ...this.options,\n ...options\n };\n }\n}\nvar createBus = () => {\n const bus = new MessageBus;\n const publish = bus.publish.bind(bus);\n const subscribe = bus.subscribe.bind(bus);\n return {\n bus,\n publish,\n subscribe\n };\n};\n// src/navigation/routeState.js\nvar createRouteState = (state2) => {\n const store = new RecordStore({\n name: \"route\",\n value: {\n host: \"\",\n path: \"\",\n query: \"\"\n },\n parent: state2\n });\n state2.add(store);\n};\n\n// src/navigation/setupHistory.js\nvar locationChangeEvent = \"locationChange\";\nvar routeChangeEvent = \"routeChange\";\nvar extractQueryParams = (queryString) => {\n return queryString.replace(/^\\?/, \"\").split(\"&\").reduce((aggregate, pairString) => {\n if (!pairString)\n return aggregate;\n const pair = pairString.split(\"=\");\n aggregate[pair[0]] = pair[1];\n return aggregate;\n }, {});\n};\nvar onLocationChange = (_payload, { publish, state: state2 }) => {\n const { host, pathname, search } = window.location;\n const path = pathname;\n const query = extractQueryParams(search);\n state2.route.update({\n host,\n path,\n query\n });\n publish(routeChangeEvent, { host, path, query });\n};\nvar setupHistory = (app) => {\n const { publish, subscribe, state: state2 } = app;\n createRouteState(state2);\n window.addEventListener(\"popstate\", () => publish(locationChangeEvent));\n subscribe(locationChangeEvent, onLocationChange);\n};\n\n// src/navigation/findHref.js\nvar findHref = (node2) => {\n if (!node2 || !node2.getAttribute)\n return \"\";\n while (!node2.getAttribute(\"href\")) {\n node2 = node2.parentNode;\n if (!node2 || !node2.getAttribute)\n return \"\";\n }\n return node2.getAttribute(\"href\");\n};\n\n// src/navigation/setupNavigation.js\nvar linkNavigationEvent = \"goToHref\";\nvar programmaticNavigationEvent = \"navigate\";\nvar navigate = (path, { publish }) => {\n window.history.pushState(null, \"\", path);\n publish(locationChangeEvent);\n};\nvar onLinkClick = (domEvent, { publish }) => {\n if (!domEvent || !domEvent.target)\n return;\n domEvent.preventDefault();\n const href = findHref(domEvent.target);\n navigate(href, { publish });\n};\nvar setupNavigation = (app) => {\n const { subscribe } = app;\n subscribe(linkNavigationEvent, onLinkClick);\n subscribe(programmaticNavigationEvent, navigate);\n};\n\n// src/app.ts\nvar setupBus = (app) => {\n const { publish, subscribe, bus } = createBus();\n app.publish = publish;\n app.subscribe = subscribe;\n app.bus = bus;\n};\nvar setupState = (app) => {\n const state3 = new State(app.publish);\n app.state = state3;\n};\nvar connectBusToState = (app) => {\n const { bus } = app;\n bus.addListenerOptions({ state: app.state });\n};\nvar setupRenderKit = (app, document) => {\n app.renderKit = {\n publish: app.publish,\n subscribe: app.subscribe,\n state: app.state,\n document\n };\n};\nvar triggerRoute = (app) => {\n const publish = app.publish;\n setTimeout(() => {\n publish(locationChangeEvent, null);\n }, 0);\n};\nvar addRender = (app) => {\n app.render = (template, selector) => {\n return render(template, selector, app.renderKit);\n };\n};\nvar createApp = (document = window.document) => {\n const app = {};\n setupBus(app);\n setupState(app);\n connectBusToState(app);\n setupRenderKit(app, document);\n setupHistory(app);\n setupNavigation(app);\n triggerRoute(app);\n addRender(app);\n return app;\n};\n// src/navigation.ts\nvar exports_navigation = {};\n__export(exports_navigation, {\n setupNavigation: () => {\n {\n return setupNavigation;\n }\n },\n setupHistory: () => {\n {\n return setupHistory;\n }\n }\n});\n// src/views/conditionals.jsx\nvar exports_conditionals = {};\n__export(exports_conditionals, {\n Unless: () => {\n {\n return Unless;\n }\n },\n IfElse: () => {\n {\n return IfElse;\n }\n },\n If: () => {\n {\n return If;\n }\n }\n});\nvar If = ({ condition, children: children3 }) => {\n if (!condition)\n return;\n return jsx_default(jsx_default.fragment, null, children3);\n};\nvar Unless = ({ condition, children: children3 }) => {\n if (condition)\n return;\n return jsx_default(jsx_default.fragment, null, children3);\n};\nvar IfElse = ({ condition, children: children3 }) => {\n const [first, ...rest] = children3;\n if (condition)\n return jsx_default(jsx_default.fragment, null, first);\n return jsx_default(jsx_default.fragment, null, rest);\n};\n\n// src/views/link.jsx\nvar Link = ({ children: children3, ...props }) => {\n return jsx_default(\"a\", {\n ...props,\n onClick: \"goToHref\"\n }, children3);\n};\n\n// src/views.js\nvar views = {\n ...exports_conditionals,\n Link\n};\nexport {\n views,\n render,\n exports_navigation as navigation,\n jsx_default as jsx,\n createBus,\n createApp,\n bind,\n State\n};\n","exports.interopDefault = function (a) {\n return a && a.__esModule ? a : {default: a};\n};\n\nexports.defineInteropFlag = function (a) {\n Object.defineProperty(a, '__esModule', {value: true});\n};\n\nexports.exportAll = function (source, dest) {\n Object.keys(source).forEach(function (key) {\n if (\n key === 'default' ||\n key === '__esModule' ||\n Object.prototype.hasOwnProperty.call(dest, key)\n ) {\n return;\n }\n\n Object.defineProperty(dest, key, {\n enumerable: true,\n get: function () {\n return source[key];\n },\n });\n });\n\n return dest;\n};\n\nexports.export = function (dest, destName, get) {\n Object.defineProperty(dest, destName, {\n enumerable: true,\n get: get,\n });\n};\n"],"names":[],"version":3,"file":"add-remove-root-children.3bb9b3f5.js.map","sourceRoot":"/__parcel_source_root/"}
|
|
@@ -4,12 +4,12 @@ const app = createApp()
|
|
|
4
4
|
|
|
5
5
|
export const EyeIcon = () => {
|
|
6
6
|
return (
|
|
7
|
-
<svg xmlns=
|
|
8
|
-
<path stroke=
|
|
9
|
-
<path d=
|
|
10
|
-
<path d=
|
|
7
|
+
<svg xmlns='http://www.w3.org/2000/svg' class='icon icon-tabler icon-tabler-eye' width='24' height='24' viewBox='0 0 24 24' stroke-width='2' stroke='currentColor' fill='none' stroke-linecap='round' stroke-linejoin='round'>
|
|
8
|
+
<path stroke='none' d='M0 0h24v24H0z' fill='none' />
|
|
9
|
+
<path d='M10 12a2 2 0 1 0 4 0a2 2 0 0 0 -4 0' />
|
|
10
|
+
<path d='M21 12c-2.4 4 -5.4 6 -9 6c-3.6 0 -6.6 -2 -9 -6c2.4 -4 5.4 -6 9 -6c3.6 0 6.6 2 9 6' />
|
|
11
11
|
</svg>
|
|
12
12
|
)
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
app.render(<EyeIcon />, '#app')
|
|
15
|
+
app.render(<EyeIcon />, '#app')
|
package/dist/jaxs.js
CHANGED
|
@@ -75,11 +75,12 @@ var normalizeValueForKey = (object, key, defaultValue = "") => {
|
|
|
75
75
|
};
|
|
76
76
|
|
|
77
77
|
// src/rendering/dom/svg.ts
|
|
78
|
+
var namespace = "http://www.w3.org/2000/svg";
|
|
78
79
|
var isSvgTag = (tagType) => tagType === "svg";
|
|
80
|
+
var isSvg = (element) => element.namespaceURI === namespace;
|
|
79
81
|
var createSvgNode = (type, attributes, renderKit) => {
|
|
80
82
|
const document = renderKit && renderKit.document || window.document;
|
|
81
|
-
const
|
|
82
|
-
const node = document.createElementNS(xmlns, type, xmlns);
|
|
83
|
+
const node = document.createElementNS(namespace, type);
|
|
83
84
|
for (const key in attributes) {
|
|
84
85
|
if (key === "__self" || key === "xmlns")
|
|
85
86
|
continue;
|
|
@@ -136,8 +137,8 @@ var isTextNode = (child) => {
|
|
|
136
137
|
var textNode = (content) => {
|
|
137
138
|
return new TextTemplate(content);
|
|
138
139
|
};
|
|
139
|
-
var withSvgFlag = (
|
|
140
|
-
template && (template.isSvg = template.isSvg ||
|
|
140
|
+
var withSvgFlag = (isSvg2) => (template) => {
|
|
141
|
+
template && (template.isSvg = template.isSvg || isSvg2);
|
|
141
142
|
return template;
|
|
142
143
|
};
|
|
143
144
|
|
|
@@ -145,12 +146,12 @@ class Children {
|
|
|
145
146
|
collection;
|
|
146
147
|
parentElement;
|
|
147
148
|
isSvg;
|
|
148
|
-
constructor(jsxChildren,
|
|
149
|
+
constructor(jsxChildren, isSvg2 = false) {
|
|
149
150
|
this.collection = ensureArray(jsxChildren);
|
|
150
151
|
this.collection = this.collection.map(replaceTextNodes);
|
|
151
152
|
this.collection = this.collection.flat();
|
|
152
|
-
this.collection = this.collection.map(withSvgFlag(
|
|
153
|
-
this.isSvg =
|
|
153
|
+
this.collection = this.collection.map(withSvgFlag(isSvg2));
|
|
154
|
+
this.isSvg = isSvg2;
|
|
154
155
|
}
|
|
155
156
|
render(renderKit, parentElement) {
|
|
156
157
|
this.parentElement = parentElement;
|
|
@@ -176,12 +177,12 @@ class Tag {
|
|
|
176
177
|
attributes;
|
|
177
178
|
children;
|
|
178
179
|
isSvg;
|
|
179
|
-
constructor(tagType, combinedAttributes, children2,
|
|
180
|
+
constructor(tagType, combinedAttributes, children2, isSvg2 = false) {
|
|
180
181
|
this.type = tagType;
|
|
181
182
|
const { events, attributes } = separateAttrsAndEvents(combinedAttributes);
|
|
182
183
|
this.events = events;
|
|
183
184
|
this.attributes = attributes;
|
|
184
|
-
this.isSvg =
|
|
185
|
+
this.isSvg = isSvg2 || isSvgTag(this.type);
|
|
185
186
|
this.children = new Children(children2, this.isSvg);
|
|
186
187
|
}
|
|
187
188
|
render(renderKit) {
|
|
@@ -588,7 +589,7 @@ var createIdMap = (list) => {
|
|
|
588
589
|
};
|
|
589
590
|
|
|
590
591
|
// src/rendering/change/instructions/attributes.ts
|
|
591
|
-
var compileForAttributes = (source, target) => {
|
|
592
|
+
var compileForAttributes = (source, target, isSvg2 = false) => {
|
|
592
593
|
const instructions = [];
|
|
593
594
|
const sourceAttributes = source.attributes;
|
|
594
595
|
const sourceLength = sourceAttributes.length;
|
|
@@ -612,11 +613,12 @@ var compileForAttributes = (source, target) => {
|
|
|
612
613
|
}
|
|
613
614
|
}
|
|
614
615
|
if (!matchingAttribute) {
|
|
615
|
-
instructions.push(removeAttribute(source, target, { name: sourceAttribute.name }));
|
|
616
|
+
instructions.push(removeAttribute(source, target, { name: sourceAttribute.name, isSvg: isSvg2 }));
|
|
616
617
|
} else if (sourceAttribute.value !== matchingAttribute.value) {
|
|
617
618
|
instructions.push(updateAttribute(source, target, {
|
|
618
619
|
name: sourceAttribute.name,
|
|
619
|
-
value: matchingAttribute.value
|
|
620
|
+
value: matchingAttribute.value,
|
|
621
|
+
isSvg: isSvg2
|
|
620
622
|
}));
|
|
621
623
|
}
|
|
622
624
|
}
|
|
@@ -637,7 +639,8 @@ var compileForAttributes = (source, target) => {
|
|
|
637
639
|
if (!matchingAttribute) {
|
|
638
640
|
instructions.push(addAttribute(source, target, {
|
|
639
641
|
name: targetAttribute.name,
|
|
640
|
-
value: targetAttribute.value
|
|
642
|
+
value: targetAttribute.value,
|
|
643
|
+
isSvg: isSvg2
|
|
641
644
|
}));
|
|
642
645
|
}
|
|
643
646
|
}
|
|
@@ -687,6 +690,9 @@ var compileForElement = (source, target) => {
|
|
|
687
690
|
const valueInstructions = compileForInputValue(source, target);
|
|
688
691
|
return attributeInstructions.concat(eventInstructions).concat(valueInstructions);
|
|
689
692
|
};
|
|
693
|
+
var compileForSvg = (source, target) => {
|
|
694
|
+
return compileForAttributes(source, target, true);
|
|
695
|
+
};
|
|
690
696
|
var compileForInputValue = (sourceElement, targetElement) => {
|
|
691
697
|
const instructions = [];
|
|
692
698
|
if (sourceElement.tagName !== "INPUT") {
|
|
@@ -716,7 +722,13 @@ var NodeTypes;
|
|
|
716
722
|
})(NodeTypes || (NodeTypes = {}));
|
|
717
723
|
var compileForNodeGenerator = (compileForCollection) => (source, target) => {
|
|
718
724
|
let instructions = [];
|
|
719
|
-
if (source.nodeType === NodeTypes.ElementNode) {
|
|
725
|
+
if (source.nodeType === NodeTypes.ElementNode && isSvg(source)) {
|
|
726
|
+
const sourceElement = source;
|
|
727
|
+
const targetElement = target;
|
|
728
|
+
const baseInstructions = compileForSvg(sourceElement, targetElement);
|
|
729
|
+
const childrenInstructions = compileForCollection(sourceElement.childNodes, targetElement.childNodes, sourceElement);
|
|
730
|
+
instructions = baseInstructions.concat(childrenInstructions);
|
|
731
|
+
} else if (source.nodeType === NodeTypes.ElementNode) {
|
|
720
732
|
const sourceElement = source;
|
|
721
733
|
const targetElement = target;
|
|
722
734
|
const baseInstructions = compileForElement(sourceElement, targetElement);
|
|
@@ -728,13 +740,6 @@ var compileForNodeGenerator = (compileForCollection) => (source, target) => {
|
|
|
728
740
|
return instructions;
|
|
729
741
|
};
|
|
730
742
|
|
|
731
|
-
// src/debugging.js
|
|
732
|
-
var debug = (...message) => {
|
|
733
|
-
if (process.env.DEBUG === "true") {
|
|
734
|
-
console.log(...message);
|
|
735
|
-
}
|
|
736
|
-
};
|
|
737
|
-
|
|
738
743
|
// src/rendering/change/instructions/children.ts
|
|
739
744
|
var compileChildren = (sourceList, targetList, parent) => {
|
|
740
745
|
const baseInstructions = [];
|
|
@@ -746,46 +751,35 @@ var compileChildren = (sourceList, targetList, parent) => {
|
|
|
746
751
|
for (;index < length; index++) {
|
|
747
752
|
const source = sourceList[index];
|
|
748
753
|
const target = targetList[index];
|
|
749
|
-
debug("\n", "loop index", index, source && source.__jsx, target && target.__jsx);
|
|
750
754
|
if (target && targetMap.check(target)) {
|
|
751
|
-
debug("target", target.__jsx, "index", index);
|
|
752
755
|
const matchingSource = sourceMap.pullMatch(target);
|
|
753
756
|
targetMap.clear(target);
|
|
754
757
|
if (matchingSource.element) {
|
|
755
|
-
debug("matching source found for target");
|
|
756
758
|
if (matchingSource.index !== index) {
|
|
757
|
-
debug("moving source", matchingSource.element.__jsx, index);
|
|
758
759
|
baseInstructions.push(insertNode(matchingSource.element, { parent, index }));
|
|
759
760
|
}
|
|
760
|
-
debug("updating to match target", matchingSource.element.__jsx, matchingSource.element.classList, target.__jsx, target.classList);
|
|
761
761
|
nodesPairsToDiff.push({
|
|
762
762
|
source: matchingSource.element,
|
|
763
763
|
target
|
|
764
764
|
});
|
|
765
765
|
} else if (source) {
|
|
766
|
-
debug("NO matching source for target but source in slot", source.__jsx);
|
|
767
766
|
if (targetMap.check(source)) {
|
|
768
|
-
debug("adding", target.__jsx, "at", index);
|
|
769
767
|
baseInstructions.push(insertNode(target, { parent, index }));
|
|
770
768
|
} else {
|
|
771
|
-
debug("replacing", source.__jsx, target.__jsx, "at", index);
|
|
772
769
|
sourceMap.clear(source);
|
|
773
770
|
baseInstructions.push(replaceNode(source, target));
|
|
774
771
|
}
|
|
775
772
|
} else {
|
|
776
|
-
debug("adding target to end", target.__jsx);
|
|
777
773
|
baseInstructions.push(insertNode(target, { parent, index }));
|
|
778
774
|
}
|
|
779
775
|
} else if (source) {
|
|
780
776
|
const matchingSource = sourceMap.pullMatch(source);
|
|
781
777
|
if (matchingSource.element) {
|
|
782
|
-
debug("removing", source.__jsx);
|
|
783
778
|
baseInstructions.push(removeNode(source));
|
|
784
779
|
}
|
|
785
780
|
}
|
|
786
781
|
}
|
|
787
782
|
sourceMap.remaining().forEach(({ element: element2 }) => {
|
|
788
|
-
debug("removing", element2.__jsx);
|
|
789
783
|
baseInstructions.push(removeNode(element2));
|
|
790
784
|
});
|
|
791
785
|
const nodeInstructions = nodesPairsToDiff.reduce((collection, { source, target }) => {
|
|
@@ -809,7 +803,6 @@ var compileForNode = compileForNodeGenerator(compileChildren);
|
|
|
809
803
|
// src/rendering/change.ts
|
|
810
804
|
var change = (source, target, parent) => {
|
|
811
805
|
const instructions = compileChildren(source, target, parent);
|
|
812
|
-
debug("instructions", instructions.map((instruction) => instruction.type));
|
|
813
806
|
instructions.forEach((instruction) => {
|
|
814
807
|
performInstruction(instruction);
|
|
815
808
|
});
|
|
@@ -827,7 +820,6 @@ var changeText2 = (instruction) => {
|
|
|
827
820
|
var removeNode2 = (instruction) => {
|
|
828
821
|
const { source } = instruction;
|
|
829
822
|
source.remove();
|
|
830
|
-
debug("removeNode called on", source.nodeName);
|
|
831
823
|
};
|
|
832
824
|
var insertNode2 = (instruction) => {
|
|
833
825
|
const { target, data } = instruction;
|
|
@@ -842,18 +834,24 @@ var insertNode2 = (instruction) => {
|
|
|
842
834
|
var replaceNode2 = (instruction) => {
|
|
843
835
|
const { source, target } = instruction;
|
|
844
836
|
source.replaceWith(target);
|
|
845
|
-
debug("replaceNode called on", source.nodeName, "with", target.nodeName);
|
|
846
|
-
debug("parent", source.parentElement);
|
|
847
837
|
};
|
|
848
838
|
var removeAttribute2 = (instruction) => {
|
|
849
839
|
const { source, data } = instruction;
|
|
850
|
-
const { name } = data;
|
|
851
|
-
|
|
840
|
+
const { name, isSvg: isSvg2 } = data;
|
|
841
|
+
if (isSvg2) {
|
|
842
|
+
source.removeAttributeNS(null, name);
|
|
843
|
+
} else {
|
|
844
|
+
source.removeAttribute(name);
|
|
845
|
+
}
|
|
852
846
|
};
|
|
853
847
|
var addAttribute2 = (instruction) => {
|
|
854
848
|
const { source, data } = instruction;
|
|
855
|
-
const { name, value } = data;
|
|
856
|
-
|
|
849
|
+
const { name, value, isSvg: isSvg2 } = data;
|
|
850
|
+
if (isSvg2) {
|
|
851
|
+
source.setAttributeNS(null, name, value);
|
|
852
|
+
} else {
|
|
853
|
+
source.setAttribute(name, value);
|
|
854
|
+
}
|
|
857
855
|
};
|
|
858
856
|
var updateAttribute2 = (instruction) => {
|
|
859
857
|
addAttribute2(instruction);
|
package/package.json
CHANGED
package/src/debugging.js
CHANGED
|
@@ -4,6 +4,7 @@ import { addAttribute, removeAttribute, updateAttribute } from './generate';
|
|
|
4
4
|
export const compileForAttributes = (
|
|
5
5
|
source: ExpandedElement,
|
|
6
6
|
target: ExpandedElement,
|
|
7
|
+
isSvg = false,
|
|
7
8
|
) => {
|
|
8
9
|
const instructions = [] as Instructions;
|
|
9
10
|
const sourceAttributes = source.attributes;
|
|
@@ -37,13 +38,14 @@ export const compileForAttributes = (
|
|
|
37
38
|
|
|
38
39
|
if (!matchingAttribute) {
|
|
39
40
|
instructions.push(
|
|
40
|
-
removeAttribute(source, target, { name: sourceAttribute.name }),
|
|
41
|
+
removeAttribute(source, target, { name: sourceAttribute.name, isSvg, }),
|
|
41
42
|
);
|
|
42
43
|
} else if (sourceAttribute.value !== matchingAttribute.value) {
|
|
43
44
|
instructions.push(
|
|
44
45
|
updateAttribute(source, target, {
|
|
45
46
|
name: sourceAttribute.name,
|
|
46
47
|
value: matchingAttribute.value,
|
|
48
|
+
isSvg,
|
|
47
49
|
}),
|
|
48
50
|
);
|
|
49
51
|
}
|
|
@@ -69,6 +71,7 @@ export const compileForAttributes = (
|
|
|
69
71
|
addAttribute(source, target, {
|
|
70
72
|
name: targetAttribute.name,
|
|
71
73
|
value: targetAttribute.value,
|
|
74
|
+
isSvg,
|
|
72
75
|
}),
|
|
73
76
|
);
|
|
74
77
|
}
|
|
@@ -8,7 +8,6 @@ import type {
|
|
|
8
8
|
import { insertNode, removeNode, replaceNode } from './generate';
|
|
9
9
|
import { createIdMap } from './idMap';
|
|
10
10
|
import { compileForNodeGenerator } from './node';
|
|
11
|
-
import { debug } from '../../../debugging';
|
|
12
11
|
|
|
13
12
|
type DiffPair = {
|
|
14
13
|
source: Dom;
|
|
@@ -30,13 +29,13 @@ export const compileChildren = (
|
|
|
30
29
|
for (; index < length; index++) {
|
|
31
30
|
const source = sourceList[index] as ExpandedElement;
|
|
32
31
|
const target = targetList[index] as ExpandedElement;
|
|
33
|
-
debug(
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
);
|
|
32
|
+
// debug(
|
|
33
|
+
// '\n',
|
|
34
|
+
// 'loop index',
|
|
35
|
+
// index,
|
|
36
|
+
// source && source.__jsx,
|
|
37
|
+
// target && target.__jsx,
|
|
38
|
+
// );
|
|
40
39
|
|
|
41
40
|
// This algorithm uses the target as the source of truth, iterating
|
|
42
41
|
// through it first figuring out what to do. The length could be larger than
|
|
@@ -44,47 +43,47 @@ export const compileChildren = (
|
|
|
44
43
|
// Part of the goal of this flow is to ensure that insertions happen in
|
|
45
44
|
// accending order.
|
|
46
45
|
if (target && targetMap.check(target)) {
|
|
47
|
-
debug('target', target.__jsx, 'index', index);
|
|
46
|
+
// debug('target', target.__jsx, 'index', index);
|
|
48
47
|
const matchingSource = sourceMap.pullMatch(target);
|
|
49
48
|
targetMap.clear(target); // mark target as resolved
|
|
50
49
|
|
|
51
50
|
if (matchingSource.element) {
|
|
52
|
-
debug('matching source found for target');
|
|
51
|
+
// debug('matching source found for target');
|
|
53
52
|
if (matchingSource.index !== index) {
|
|
54
53
|
// move source to index
|
|
55
|
-
debug('moving source', matchingSource.element.__jsx, index);
|
|
54
|
+
// debug('moving source', matchingSource.element.__jsx, index);
|
|
56
55
|
baseInstructions.push(
|
|
57
56
|
insertNode(matchingSource.element, { parent, index }),
|
|
58
57
|
);
|
|
59
58
|
}
|
|
60
59
|
// update element for attribute, event and child changes
|
|
61
|
-
debug('updating to match target',
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
);
|
|
60
|
+
// debug('updating to match target',
|
|
61
|
+
// matchingSource.element.__jsx,
|
|
62
|
+
// matchingSource.element.classList,
|
|
63
|
+
// target.__jsx,
|
|
64
|
+
// target.classList
|
|
65
|
+
// );
|
|
67
66
|
nodesPairsToDiff.push({
|
|
68
67
|
source: matchingSource.element,
|
|
69
68
|
target,
|
|
70
69
|
});
|
|
71
70
|
} else if (source) {
|
|
72
|
-
debug('NO matching source for target but source in slot', source.__jsx);
|
|
71
|
+
// debug('NO matching source for target but source in slot', source.__jsx);
|
|
73
72
|
|
|
74
73
|
if (targetMap.check(source)) {
|
|
75
74
|
// the source is somewhere else in the target, so just add this
|
|
76
75
|
// target element and assume the source will get resolved later.
|
|
77
|
-
debug('adding', target.__jsx, 'at', index);
|
|
76
|
+
// debug('adding', target.__jsx, 'at', index);
|
|
78
77
|
baseInstructions.push(insertNode(target, { parent, index }));
|
|
79
78
|
} else {
|
|
80
79
|
// no matching target, but something is in the index/slot ... so swap
|
|
81
|
-
debug('replacing', source.__jsx, target.__jsx, 'at', index);
|
|
80
|
+
// debug('replacing', source.__jsx, target.__jsx, 'at', index);
|
|
82
81
|
sourceMap.clear(source); // resolve source
|
|
83
82
|
baseInstructions.push(replaceNode(source as Dom, target as Dom));
|
|
84
83
|
}
|
|
85
84
|
} else {
|
|
86
85
|
// extra targets, add these to the end of the parent in order received
|
|
87
|
-
debug('adding target to end', target.__jsx);
|
|
86
|
+
// debug('adding target to end', target.__jsx);
|
|
88
87
|
baseInstructions.push(insertNode(target, { parent, index }));
|
|
89
88
|
}
|
|
90
89
|
} else if (source) {
|
|
@@ -93,7 +92,7 @@ export const compileChildren = (
|
|
|
93
92
|
// if not remove from dom
|
|
94
93
|
const matchingSource = sourceMap.pullMatch(source);
|
|
95
94
|
if (matchingSource.element) {
|
|
96
|
-
debug('removing', source.__jsx);
|
|
95
|
+
// debug('removing', source.__jsx);
|
|
97
96
|
baseInstructions.push(removeNode(source));
|
|
98
97
|
}
|
|
99
98
|
}
|
|
@@ -101,7 +100,7 @@ export const compileChildren = (
|
|
|
101
100
|
|
|
102
101
|
// deal with unresolved sources
|
|
103
102
|
sourceMap.remaining().forEach(({ element }) => {
|
|
104
|
-
debug('removing', element.__jsx);
|
|
103
|
+
// debug('removing', element.__jsx);
|
|
105
104
|
baseInstructions.push(removeNode(element));
|
|
106
105
|
});
|
|
107
106
|
|
|
@@ -16,6 +16,13 @@ export const compileForElement = (
|
|
|
16
16
|
.concat(valueInstructions);
|
|
17
17
|
};
|
|
18
18
|
|
|
19
|
+
export const compileForSvg = (
|
|
20
|
+
source: ExpandedElement,
|
|
21
|
+
target: ExpandedElement,
|
|
22
|
+
) => {
|
|
23
|
+
return compileForAttributes(source, target, true);
|
|
24
|
+
}
|
|
25
|
+
|
|
19
26
|
const compileForInputValue = (
|
|
20
27
|
sourceElement: ExpandedElement,
|
|
21
28
|
targetElement: ExpandedElement,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { Dom, ExpandedElement, Instructions } from '../../../types';
|
|
2
|
-
import { compileForElement } from './element';
|
|
2
|
+
import { compileForElement, compileForSvg } from './element';
|
|
3
3
|
import { compileForText } from './text';
|
|
4
|
+
import { isSvg } from '../../dom/svg'
|
|
4
5
|
|
|
5
6
|
enum NodeTypes {
|
|
6
7
|
ElementNode = 1,
|
|
@@ -11,7 +12,23 @@ export const compileForNodeGenerator =
|
|
|
11
12
|
(compileForCollection: any) => (source: Dom, target: Dom) => {
|
|
12
13
|
let instructions = [] as Instructions;
|
|
13
14
|
|
|
14
|
-
if (source.nodeType === NodeTypes.ElementNode
|
|
15
|
+
if (source.nodeType === NodeTypes.ElementNode &&
|
|
16
|
+
isSvg(source as SVGElement)) {
|
|
17
|
+
const sourceElement = source as ExpandedElement;
|
|
18
|
+
const targetElement = target as ExpandedElement;
|
|
19
|
+
const baseInstructions = compileForSvg(
|
|
20
|
+
sourceElement,
|
|
21
|
+
targetElement
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
const childrenInstructions = compileForCollection(
|
|
25
|
+
sourceElement.childNodes,
|
|
26
|
+
targetElement.childNodes,
|
|
27
|
+
sourceElement,
|
|
28
|
+
);
|
|
29
|
+
|
|
30
|
+
instructions = baseInstructions.concat(childrenInstructions);
|
|
31
|
+
} else if (source.nodeType === NodeTypes.ElementNode) {
|
|
15
32
|
const sourceElement = source as ExpandedElement;
|
|
16
33
|
const targetElement = target as ExpandedElement;
|
|
17
34
|
|
package/src/rendering/change.ts
CHANGED
|
@@ -12,7 +12,7 @@ import type {
|
|
|
12
12
|
} from '../types';
|
|
13
13
|
import { ChangeInstructions } from '../types'
|
|
14
14
|
import { compileChange } from './change/compile';
|
|
15
|
-
import { debug } from '../debugging';
|
|
15
|
+
// import { debug } from '../debugging';
|
|
16
16
|
|
|
17
17
|
export const change = (
|
|
18
18
|
source: HtmlChildren,
|
|
@@ -21,7 +21,7 @@ export const change = (
|
|
|
21
21
|
) => {
|
|
22
22
|
const instructions = compileChange(source, target, parent);
|
|
23
23
|
|
|
24
|
-
debug('instructions', instructions.map((instruction) => instruction.type))
|
|
24
|
+
// debug('instructions', instructions.map((instruction) => instruction.type))
|
|
25
25
|
|
|
26
26
|
instructions.forEach((instruction) => {
|
|
27
27
|
performInstruction(instruction);
|
|
@@ -43,7 +43,7 @@ const changeText: Updater = (instruction: Instruction) => {
|
|
|
43
43
|
const removeNode: Updater = (instruction: Instruction) => {
|
|
44
44
|
const { source } = instruction;
|
|
45
45
|
source.remove();
|
|
46
|
-
debug('removeNode called on', source.nodeName)
|
|
46
|
+
// debug('removeNode called on', source.nodeName)
|
|
47
47
|
};
|
|
48
48
|
|
|
49
49
|
const insertNode: Updater = (instruction: Instruction) => {
|
|
@@ -61,22 +61,30 @@ const insertNode: Updater = (instruction: Instruction) => {
|
|
|
61
61
|
const replaceNode: Updater = (instruction: Instruction) => {
|
|
62
62
|
const { source, target } = instruction;
|
|
63
63
|
source.replaceWith(target);
|
|
64
|
-
debug('replaceNode called on', source.nodeName, 'with', target.nodeName)
|
|
65
|
-
debug('parent', source.parentElement)
|
|
64
|
+
// debug('replaceNode called on', source.nodeName, 'with', target.nodeName)
|
|
65
|
+
// debug('parent', source.parentElement)
|
|
66
66
|
};
|
|
67
67
|
|
|
68
68
|
const removeAttribute: Updater = (instruction: Instruction) => {
|
|
69
69
|
const { source, data } = instruction;
|
|
70
|
-
const { name } = data as RemoveInstructionData;
|
|
70
|
+
const { name, isSvg } = data as RemoveInstructionData;
|
|
71
71
|
|
|
72
|
-
|
|
72
|
+
if (isSvg) {
|
|
73
|
+
(source as SVGElement).removeAttributeNS(null, name)
|
|
74
|
+
} else {
|
|
75
|
+
(source as ExpandedElement).removeAttribute(name);
|
|
76
|
+
}
|
|
73
77
|
};
|
|
74
78
|
|
|
75
79
|
const addAttribute: Updater = (instruction: Instruction) => {
|
|
76
80
|
const { source, data } = instruction;
|
|
77
|
-
const { name, value } = data as AttributeInstructionData;
|
|
81
|
+
const { name, value, isSvg } = data as AttributeInstructionData;
|
|
78
82
|
|
|
79
|
-
(
|
|
83
|
+
if (isSvg) {
|
|
84
|
+
(source as SVGElement).setAttributeNS(null, name, value)
|
|
85
|
+
} else {
|
|
86
|
+
(source as ExpandedElement).setAttribute(name, value);
|
|
87
|
+
}
|
|
80
88
|
};
|
|
81
89
|
|
|
82
90
|
const updateAttribute: Updater = (instruction: Instruction) => {
|
package/src/rendering/dom/svg.ts
CHANGED
|
@@ -1,16 +1,18 @@
|
|
|
1
1
|
import type { RenderKit, Attributes, ExpandedElement } from "../../types"
|
|
2
2
|
|
|
3
|
+
export const namespace = 'http://www.w3.org/2000/svg'
|
|
3
4
|
export const isSvgTag = (tagType: string) => tagType === 'svg'
|
|
5
|
+
export const isSvg = (element: SVGElement) => element.namespaceURI === namespace
|
|
4
6
|
|
|
5
7
|
export const createSvgNode = (type: string, attributes: Attributes, renderKit: RenderKit) => {
|
|
6
8
|
const document = renderKit && renderKit.document || window.document;
|
|
7
|
-
const
|
|
8
|
-
const node = document.createElementNS(xmlns, type, xmlns)
|
|
9
|
+
const node = document.createElementNS(namespace, type)
|
|
9
10
|
|
|
10
11
|
for (const key in attributes) {
|
|
11
12
|
if (key === '__self' || key === 'xmlns') continue;
|
|
13
|
+
// adding namespace in as first argument makes it not really render!
|
|
12
14
|
node.setAttributeNS(null, key, attributes[key]);
|
|
13
15
|
}
|
|
14
16
|
|
|
15
|
-
return node as ExpandedElement
|
|
17
|
+
return node as unknown as ExpandedElement
|
|
16
18
|
}
|
package/src/types.ts
CHANGED
|
@@ -20,7 +20,7 @@ export interface InputElement extends ExpandedElement {
|
|
|
20
20
|
// deno-lint-ignore no-explicit-any
|
|
21
21
|
value: any;
|
|
22
22
|
}
|
|
23
|
-
export type Dom = Text | ExpandedElement;
|
|
23
|
+
export type Dom = Text | ExpandedElement | SVGElement;
|
|
24
24
|
export type DomCollection = Dom[];
|
|
25
25
|
export type HtmlChildren =
|
|
26
26
|
| HTMLCollection
|
|
@@ -81,11 +81,13 @@ export type BusListenersMap = Record<BusEventName, BusPayload>;
|
|
|
81
81
|
// Change instructions
|
|
82
82
|
export type RemoveInstructionData = {
|
|
83
83
|
name: string;
|
|
84
|
+
isSvg?: boolean;
|
|
84
85
|
};
|
|
85
86
|
|
|
86
87
|
export type AttributeInstructionData = {
|
|
87
88
|
name: string;
|
|
88
89
|
value: string;
|
|
90
|
+
isSvg?: boolean;
|
|
89
91
|
};
|
|
90
92
|
|
|
91
93
|
export type EventInstructionData = {
|