@burger-editor/client 4.0.0-alpha.76 → 4.0.0-alpha.78

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. package/README.md +42 -41
  2. package/dist/block-swap-view-transition-css.d.ts +7 -0
  3. package/dist/block-swap-view-transition-css.d.ts.map +1 -0
  4. package/dist/burger-editor-root.d.ts +1 -1
  5. package/dist/client.css +158 -18
  6. package/dist/client.js +10865 -10524
  7. package/dist/client.js.map +1 -1
  8. package/dist/components/block-catalog.d.ts +1 -1
  9. package/dist/components/block-catalog.d.ts.map +1 -1
  10. package/dist/components/block-menu-anchors.d.ts +25 -0
  11. package/dist/components/block-menu-anchors.d.ts.map +1 -0
  12. package/dist/components/block-menu-button.d.ts +8 -3
  13. package/dist/components/block-menu-button.d.ts.map +1 -1
  14. package/dist/components/block-menu-view.d.ts +36 -30
  15. package/dist/components/block-menu-view.d.ts.map +1 -1
  16. package/dist/components/block-menu.d.ts +1 -1
  17. package/dist/components/block-menu.d.ts.map +1 -1
  18. package/dist/components/block-options.d.ts +1 -1
  19. package/dist/components/block-options.d.ts.map +1 -1
  20. package/dist/components/draft-switcher.d.ts +1 -1
  21. package/dist/components/editable-area-view.d.ts +1 -1
  22. package/dist/components/editable-area-view.d.ts.map +1 -1
  23. package/dist/components/file-list.d.ts +1 -1
  24. package/dist/components/file-uploader.d.ts +1 -1
  25. package/dist/components/front-matter-editor.d.ts +17 -6
  26. package/dist/components/front-matter-editor.d.ts.map +1 -1
  27. package/dist/components/index.d.ts +3 -1
  28. package/dist/components/index.d.ts.map +1 -1
  29. package/dist/components/initial-insertion-button.d.ts +1 -1
  30. package/dist/components/item-editor-host.d.ts +1 -1
  31. package/dist/components/preview.d.ts +1 -1
  32. package/dist/components/table-editor.d.ts +1 -1
  33. package/dist/components/tabs.d.ts +1 -1
  34. package/dist/components/thumbnail-button.d.ts +39 -0
  35. package/dist/components/thumbnail-button.d.ts.map +1 -0
  36. package/dist/components/thumbnail.d.ts +1 -1
  37. package/dist/components/wysiwyg-field.d.ts +1 -1
  38. package/dist/create-mock-engine-BloCpuEu.js +87 -0
  39. package/dist/create-mock-engine-BloCpuEu.js.map +1 -0
  40. package/dist/{engine-context-D0zt6fhJ.js → dist-DYydjVsL.js} +960 -577
  41. package/dist/dist-DYydjVsL.js.map +1 -0
  42. package/dist/{editable-area-view-S2Uz7pl8.js → editable-area-view-CAeVDyOh.js} +693 -672
  43. package/dist/editable-area-view-CAeVDyOh.js.map +1 -0
  44. package/dist/editor-dialog.d.ts +1 -1
  45. package/dist/engine-context-oEEsvNSx.js +49 -0
  46. package/dist/engine-context-oEEsvNSx.js.map +1 -0
  47. package/dist/engine-context.d.ts +9 -6
  48. package/dist/engine-context.d.ts.map +1 -1
  49. package/dist/form/checkbox.d.ts +1 -1
  50. package/dist/form/fieldset.d.ts +1 -1
  51. package/dist/form/number-field.d.ts +1 -1
  52. package/dist/form/radio-group.d.ts +1 -1
  53. package/dist/form/select-field.d.ts +5 -2
  54. package/dist/form/select-field.d.ts.map +1 -1
  55. package/dist/form/text-area.d.ts +1 -1
  56. package/dist/form/text-field.d.ts +12 -2
  57. package/dist/form/text-field.d.ts.map +1 -1
  58. package/dist/interest-hints.d.ts +21 -0
  59. package/dist/interest-hints.d.ts.map +1 -0
  60. package/dist/replace-element.d.ts +12 -4
  61. package/dist/replace-element.d.ts.map +1 -1
  62. package/dist/root-error-boundary.d.ts +1 -1
  63. package/dist/testing/create-mock-engine.d.ts +3 -0
  64. package/dist/testing/create-mock-engine.d.ts.map +1 -1
  65. package/dist/testing/render-with-engine.d.ts +1 -1
  66. package/dist/testing-mock-engine.js +1 -0
  67. package/dist/testing.js +4 -55
  68. package/dist/testing.js.map +1 -1
  69. package/dist/ui.d.ts +1 -0
  70. package/dist/ui.d.ts.map +1 -1
  71. package/dist/ui.js +267 -160
  72. package/dist/ui.js.map +1 -1
  73. package/package.json +26 -22
  74. package/dist/editable-area-view-S2Uz7pl8.js.map +0 -1
  75. package/dist/engine-context-D0zt6fhJ.js.map +0 -1
@@ -1,12 +1,11 @@
1
- import { createContext, createElement, use } from "react";
2
- //#region \0rolldown/runtime.js
1
+ // \0rolldown/runtime.js
3
2
  var __create = Object.create;
4
3
  var __defProp = Object.defineProperty;
5
4
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
5
  var __getOwnPropNames = Object.getOwnPropertyNames;
7
6
  var __getProtoOf = Object.getPrototypeOf;
8
7
  var __hasOwnProp = Object.prototype.hasOwnProperty;
9
- var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
8
+ var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod, mod.exports), cb = null), mod.exports);
10
9
  var __copyProps = (to, from, except, desc) => {
11
10
  if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
12
11
  key = keys[i];
@@ -21,8 +20,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
21
20
  value: mod,
22
21
  enumerable: true
23
22
  }) : target, mod));
24
- //#endregion
25
- //#region ../core/dist/block/change-frame-semantics.js
23
+ // ../core/dist/block/change-frame-semantics.js
26
24
  /**
27
25
  *
28
26
  * @param el
@@ -53,8 +51,7 @@ function copyAttributes(source, target) {
53
51
  for (const attr of source.attributes) target.setAttribute(attr.name, attr.value);
54
52
  if (source.className) target.className = source.className;
55
53
  }
56
- //#endregion
57
- //#region ../core/dist/const.js
54
+ // ../core/dist/const.js
58
55
  var CSS_LAYER = {
59
56
  base: "bge-component-bases",
60
57
  components: "bge-components",
@@ -62,8 +59,25 @@ var CSS_LAYER = {
62
59
  };
63
60
  var BLOCK_OPTION_CSS_CUSTOM_PROPERTY_PREFIX = "--bge-options-";
64
61
  var BLOCK_OPTION_SCOPE_SELECTOR = `[data-bge-container]`;
65
- //#endregion
66
- //#region ../core/dist/dom-helpers/sanitize-attrs.js
62
+ /**
63
+ * Stand-in for an empty custom property value (`--x: ;`).
64
+ *
65
+ * Browsers keep such a declaration with the value `' '`, and project CSS
66
+ * relies on it to hide a built-in style option, but jsdom drops it while
67
+ * parsing, so a lower-priority declaration of the same property would win
68
+ * instead. Code that loads CSS into jsdom (file-io's
69
+ * `createStylesheetDocument()`) writes this value in its place, and
70
+ * `getCustomProperties` treats it the same as an empty value.
71
+ * @example
72
+ * ```ts
73
+ * const css = '[data-bge-container] { --bge-options-margin--none: ; }'.replace(
74
+ * ': ;',
75
+ * `: ${EMPTY_CUSTOM_PROPERTY_VALUE};`,
76
+ * );
77
+ * ```
78
+ */
79
+ var EMPTY_CUSTOM_PROPERTY_VALUE = "--bge-empty-custom-property-value";
80
+ // ../core/dist/dom-helpers/sanitize-attrs.js
67
81
  var removeAttrNameIgnoreList = /* @__PURE__ */ new Set([
68
82
  "data-bge-container",
69
83
  "data-bge-name",
@@ -92,8 +106,7 @@ function sanitizeStyle(el) {
92
106
  el.removeAttribute("style");
93
107
  for (const [property, value] of customProperties) style.setProperty(property, value);
94
108
  }
95
- //#endregion
96
- //#region ../core/dist/block/import-container-props.js
109
+ // ../core/dist/block/import-container-props.js
97
110
  /**
98
111
  *
99
112
  * @param containerProps
@@ -113,8 +126,7 @@ function importContainerProps(containerProps) {
113
126
  if (repeatMinInlineSize) options.add(`--${repeatMinInlineSize}`);
114
127
  return [type, ...options].join(":");
115
128
  }
116
- //#endregion
117
- //#region ../core/dist/block/import-style-options.js
129
+ // ../core/dist/block/import-style-options.js
118
130
  /**
119
131
  *
120
132
  * @param el
@@ -128,8 +140,7 @@ function importStyleOptions(el, style) {
128
140
  el.style.setProperty(name, variable);
129
141
  }
130
142
  }
131
- //#endregion
132
- //#region ../core/dist/block/import-options.js
143
+ // ../core/dist/block/import-options.js
133
144
  /**
134
145
  *
135
146
  * @param el
@@ -150,8 +161,7 @@ function importOptions(el, options) {
150
161
  for (const group of groups) if (containerProps?.linkarea) group.dataset.bgeLinkarea = "";
151
162
  else delete group.dataset.bgeLinkarea;
152
163
  }
153
- //#endregion
154
- //#region ../core/dist/block/create-plain-structured-block-element.js
164
+ // ../core/dist/block/create-plain-structured-block-element.js
155
165
  /**
156
166
  * BlockDataからHTML要素を生成する
157
167
  *
@@ -193,8 +203,7 @@ async function createItemElements(items, createItemElement) {
193
203
  }
194
204
  return itemElements;
195
205
  }
196
- //#endregion
197
- //#region ../core/dist/utils/find-value-from-array.js
206
+ // ../core/dist/utils/find-value-from-array.js
198
207
  /**
199
208
  *
200
209
  * @param array
@@ -204,8 +213,7 @@ function findValueFromArray(array, searchValues) {
204
213
  for (const value of searchValues) if (array.includes(value)) return value;
205
214
  return null;
206
215
  }
207
- //#endregion
208
- //#region ../core/dist/utils/find-value-pattern-from-array.js
216
+ // ../core/dist/utils/find-value-pattern-from-array.js
209
217
  /**
210
218
  *
211
219
  * @param array
@@ -215,8 +223,7 @@ function findValuePatternFromArray(array, pattern) {
215
223
  for (const value of array) if (pattern.test(value)) return value;
216
224
  return null;
217
225
  }
218
- //#endregion
219
- //#region ../core/dist/block/export-container-props.js
226
+ // ../core/dist/block/export-container-props.js
220
227
  /**
221
228
  * コンテナ特性の文字列を解析してオブジェクトに変換する
222
229
  * @param containerPropsQuery - コンテナ特性の文字列(例: "grid:1", "inline:center:wrap", "float:start")
@@ -273,27 +280,67 @@ function exportContainerProps(containerPropsQuery) {
273
280
  repeatMinInlineSize: findValuePatternFromArray(options, /^--(.+)$/)?.slice(2) ?? null
274
281
  };
275
282
  }
276
- //#endregion
277
- //#region ../core/dist/block/export-style-options.js
283
+ // ../core/dist/block/parse-style-option-name.js
278
284
  /**
285
+ * Split a style option custom property name into its category and key.
279
286
  *
280
- * @param el
287
+ * `--bge-options-{category}` (the selected-value declaration) yields
288
+ * `key: null`; `--bge-options-{category}--{key}` (a choice) yields both.
289
+ * Option detection and the read-back of saved HTML both split through this
290
+ * function, so a name is offered as a choice exactly when it can be read
291
+ * back. Names that cannot be split unambiguously return `null`: an empty
292
+ * category or key, or more than one `--` after the prefix. Characters are
293
+ * otherwise not restricted.
294
+ * @param property - Custom property name, including the leading `--`
295
+ * @returns The category and key, or `null` when `property` is not a style
296
+ * option name
297
+ */
298
+ function parseStyleOptionName(property) {
299
+ if (!property.startsWith("--bge-options-")) return null;
300
+ const segments = property.slice(BLOCK_OPTION_CSS_CUSTOM_PROPERTY_PREFIX.length).split("--");
301
+ const [category, key] = segments;
302
+ if (!category || segments.length > 2 || key === "") return null;
303
+ return {
304
+ category,
305
+ key: key ?? null
306
+ };
307
+ }
308
+ // ../core/dist/block/export-style-options.js
309
+ /**
310
+ * Read the selected style options back from a block container's inline
311
+ * `style`.
312
+ *
313
+ * Each `--bge-options-{category}: var(--bge-options-{category}--{key})`
314
+ * declaration becomes `{ [category]: key }`, which is the inverse of
315
+ * `importStyleOptions`. Names are split the same way the editor's option
316
+ * detection splits them, so any category and key the editor offers as a
317
+ * choice round-trips, whatever characters they use. Names containing `--`
318
+ * (or a category ending in `-`) cannot be split unambiguously and are
319
+ * ignored, as are declarations whose `var()` points at another category or
320
+ * that are not a single `var()` reference.
321
+ * @param el - Block container element whose inline `style` holds the options
322
+ * @returns Map of category to selected key
323
+ * @example
324
+ * ```ts
325
+ * el.setAttribute('style', '--bge-options-gap: var(--bge-options-gap--2x)');
326
+ * exportStyleOptions(el); // { gap: '2x' }
327
+ * ```
281
328
  */
282
329
  function exportStyleOptions(el) {
283
330
  const style = {};
284
331
  const decl = el.style;
285
332
  for (let i = 0; i < decl.length; i++) {
286
333
  const property = decl.item(i);
287
- if (!property.startsWith("--bge-options-")) continue;
288
- const category = property.replace(BLOCK_OPTION_CSS_CUSTOM_PROPERTY_PREFIX, "");
289
- const [, _category, propName] = el.style.getPropertyValue(property).replace(`var(--bge-options-`, "").replace(/\)$/, "").match(/^((?:_[a-z]+_)?[a-z]+(?:-[a-z]+)*)--([a-z]+(?:-[a-z]+)*)$/) ?? [];
290
- if (category !== _category || !propName) continue;
291
- style[category] = propName;
334
+ const declared = parseStyleOptionName(property);
335
+ if (!declared || declared.key !== null) continue;
336
+ const reference = /^var\(\s*([^\s(),]+)\s*\)$/.exec(decl.getPropertyValue(property).trim())?.[1];
337
+ const referenced = reference ? parseStyleOptionName(reference) : null;
338
+ if (referenced?.key == null || referenced.category !== declared.category) continue;
339
+ style[declared.category] = referenced.key;
292
340
  }
293
341
  return style;
294
342
  }
295
- //#endregion
296
- //#region ../core/dist/block/export-options.js
343
+ // ../core/dist/block/export-options.js
297
344
  /**
298
345
  *
299
346
  * @param el
@@ -314,8 +361,7 @@ function exportOptions(el) {
314
361
  style
315
362
  };
316
363
  }
317
- //#endregion
318
- //#region ../core/dist/block/highlight.js
364
+ // ../core/dist/block/highlight.js
319
365
  var SCROLL_FALLBACK_MS = 400;
320
366
  var BLINK_FALLBACK_MS = 2e3;
321
367
  /**
@@ -392,8 +438,7 @@ function blinkOnce(el) {
392
438
  el.dataset.bgeHighlight = "";
393
439
  });
394
440
  }
395
- //#endregion
396
- //#region ../utils/dist/camel-case.js
441
+ // ../utils/dist/camel-case.js
397
442
  var camelCaseCache = /* @__PURE__ */ new Map();
398
443
  /**
399
444
  *
@@ -405,8 +450,7 @@ function camelCase(str) {
405
450
  camelCaseCache.set(str, result);
406
451
  return result;
407
452
  }
408
- //#endregion
409
- //#region ../utils/dist/kebab-case.js
453
+ // ../utils/dist/kebab-case.js
410
454
  var kebabCaseCache = /* @__PURE__ */ new Map();
411
455
  /**
412
456
  *
@@ -418,8 +462,7 @@ function kebabCase(str) {
418
462
  kebabCaseCache.set(str, result);
419
463
  return result;
420
464
  }
421
- //#endregion
422
- //#region ../../../node_modules/marked/lib/marked.esm.js
465
+ // ../../../node_modules/marked/lib/marked.esm.js
423
466
  /**
424
467
  * marked v17.0.6 - a markdown parser
425
468
  * Copyright (c) 2018-2026, MarkedJS. (MIT License)
@@ -1995,8 +2038,7 @@ var Ut = g.walkTokens;
1995
2038
  var Kt = g.parseInline;
1996
2039
  var Xt = b.parse;
1997
2040
  var Jt = x.lex;
1998
- //#endregion
1999
- //#region ../../../node_modules/turndown/lib/turndown.browser.es.js
2041
+ // ../../../node_modules/turndown/lib/turndown.browser.es.js
2000
2042
  function extend(destination) {
2001
2043
  for (var i = 1; i < arguments.length; i++) {
2002
2044
  var source = arguments[i];
@@ -2706,8 +2748,8 @@ TurndownService.prototype = {
2706
2748
  * Reduces a DOM node down to its Markdown string equivalent
2707
2749
  * @private
2708
2750
  * @param {HTMLElement} parentNode The node to convert
2709
- * @returns A Markdown representation of the node
2710
- * @type String
2751
+ * @returns Accumulator with Markdown representation parts of the node
2752
+ * @type Array
2711
2753
  */
2712
2754
  function process(parentNode) {
2713
2755
  var self = this;
@@ -2716,22 +2758,23 @@ function process(parentNode) {
2716
2758
  var replacement = "";
2717
2759
  if (node.nodeType === 3) replacement = node.isCode ? node.nodeValue : self.escape(node.nodeValue);
2718
2760
  else if (node.nodeType === 1) replacement = replacementForNode.call(self, node);
2719
- return join(output, replacement);
2720
- }, "");
2761
+ join(output, replacement);
2762
+ return output;
2763
+ }, []);
2721
2764
  }
2722
2765
  /**
2723
2766
  * Appends strings as each rule requires and trims the output
2724
2767
  * @private
2725
- * @param {String} output The conversion output
2768
+ * @param {Array} output The conversion output accumulator
2726
2769
  * @returns A trimmed version of the ouput
2727
2770
  * @type String
2728
2771
  */
2729
2772
  function postProcess(output) {
2730
2773
  var self = this;
2731
2774
  this.rules.forEach(function(rule) {
2732
- if (typeof rule.append === "function") output = join(output, rule.append(self.options));
2775
+ if (typeof rule.append === "function") join(output, rule.append(self.options));
2733
2776
  });
2734
- return output.replace(/^[\t\r\n]+/, "").replace(/[\t\r\n\s]+$/, "");
2777
+ return output.join("").replace(/^[\t\r\n]+/, "").replace(/[\t\r\n\s]+$/, "");
2735
2778
  }
2736
2779
  /**
2737
2780
  * Converts an element node to its Markdown equivalent
@@ -2742,24 +2785,27 @@ function postProcess(output) {
2742
2785
  */
2743
2786
  function replacementForNode(node) {
2744
2787
  var rule = this.rules.forNode(node);
2745
- var content = process.call(this, node);
2788
+ var content = process.call(this, node).join("");
2746
2789
  var whitespace = node.flankingWhitespace;
2747
2790
  if (whitespace.leading || whitespace.trailing) content = content.trim();
2748
2791
  return whitespace.leading + rule.replacement(content, node, this.options) + whitespace.trailing;
2749
2792
  }
2750
2793
  /**
2751
- * Joins replacement to the current output with appropriate number of new lines
2794
+ * Joins replacement with the current output accumulator using the appropriate number of new lines
2795
+ * (makes sure the only trailing whitespace will be in the last array element)
2752
2796
  * @private
2753
- * @param {String} output The current conversion output
2797
+ * @param {String} output The current conversion output accumulator
2754
2798
  * @param {String} replacement The string to append to the output
2755
- * @returns Joined output
2756
- * @type String
2757
2799
  */
2758
2800
  function join(output, replacement) {
2759
- var s1 = trimTrailingNewlines(output);
2801
+ var tail = output.pop() || "";
2802
+ var s1 = trimTrailingNewlines(tail);
2760
2803
  var s2 = trimLeadingNewlines(replacement);
2761
- var nls = Math.max(output.length - s1.length, replacement.length - s2.length);
2762
- return s1 + "\n\n".substring(0, nls) + s2;
2804
+ var nls = Math.max(tail.length - s1.length, replacement.length - s2.length);
2805
+ var separator = "\n\n".substring(0, nls);
2806
+ if (s1) output.push(s1);
2807
+ if (separator) output.push(separator);
2808
+ if (s2) output.push(s2);
2763
2809
  }
2764
2810
  /**
2765
2811
  * Determines whether an input can be converted
@@ -2771,12 +2817,11 @@ function join(output, replacement) {
2771
2817
  function canConvert(input) {
2772
2818
  return input != null && (typeof input === "string" || input.nodeType && (input.nodeType === 1 || input.nodeType === 9 || input.nodeType === 11));
2773
2819
  }
2774
- //#endregion
2775
- //#region ../../../node_modules/dayjs/dayjs.min.js
2776
- var require_dayjs_min = /* @__PURE__ */ __commonJSMin(((exports, module) => {
2820
+ // ../../../node_modules/dayjs/dayjs.min.js
2821
+ var require_dayjs_min = /* @__PURE__ */ __commonJSMin(((exports, module, this$2) => {
2777
2822
  (function(t, e) {
2778
2823
  "object" == typeof exports && "undefined" != typeof module ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : (t = "undefined" != typeof globalThis ? globalThis : t || self).dayjs = e();
2779
- })(exports, (function() {
2824
+ })(this$2, (function() {
2780
2825
  "use strict";
2781
2826
  var t = 1e3, e = 6e4, n = 36e5, r = "millisecond", i = "second", s = "minute", u = "hour", a = "day", o = "week", c = "month", f = "quarter", h = "year", d = "date", l = "Invalid Date", $ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y = /\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, M = {
2782
2827
  name: "en",
@@ -3069,8 +3114,7 @@ var require_dayjs_min = /* @__PURE__ */ __commonJSMin(((exports, module) => {
3069
3114
  }, O.en = D[g], O.Ls = D, O.p = {}, O;
3070
3115
  }));
3071
3116
  }));
3072
- //#endregion
3073
- //#region ../utils/dist/utils.js
3117
+ // ../utils/dist/utils.js
3074
3118
  var import_dayjs_min = /* @__PURE__ */ __toESM(require_dayjs_min(), 1);
3075
3119
  /**
3076
3120
  * 数値をバイトサイズ単位にフォーマットする
@@ -3108,8 +3152,7 @@ function formatByteSize(byteSize, digits = 2, autoFormat = true) {
3108
3152
  function formatDate(timestamp, format) {
3109
3153
  return import_dayjs_min.default.unix(timestamp).format(format);
3110
3154
  }
3111
- //#endregion
3112
- //#region ../frozen-patty/dist/normalize-indent.js
3155
+ // ../frozen-patty/dist/normalize-indent.js
3113
3156
  /**
3114
3157
  * Normalizes the indentation of a multi-line HTML string by detecting the indentation
3115
3158
  * of the first line and removing the same amount of leading whitespace (spaces or tabs)
@@ -3135,8 +3178,7 @@ function normalizeIndent(html) {
3135
3178
  if (firstLineIndent.length === 0) return trimmedHtml.trimEnd();
3136
3179
  return lines.map((line) => line.replace(firstLineIndent, "")).join("").trimEnd();
3137
3180
  }
3138
- //#endregion
3139
- //#region ../frozen-patty/dist/parse-fields.js
3181
+ // ../frozen-patty/dist/parse-fields.js
3140
3182
  var cache = /* @__PURE__ */ new Map();
3141
3183
  /**
3142
3184
  *
@@ -3165,10 +3207,26 @@ function parseField(field) {
3165
3207
  propName
3166
3208
  };
3167
3209
  }
3168
- //#endregion
3169
- //#region ../frozen-patty/dist/get-values.js
3210
+ // ../frozen-patty/dist/get-values.js
3211
+ /**
3212
+ * 属性が無いときに `null` として読む `<source>` の属性。要素のプロパティが
3213
+ * 属性の有無を隠す(空文字や `0` になる)ものだけを挙げる
3214
+ */
3215
+ var SOURCE_ATTRIBUTES = /* @__PURE__ */ new Set([
3216
+ "srcset",
3217
+ "media",
3218
+ "sizes",
3219
+ "width",
3220
+ "height"
3221
+ ]);
3170
3222
  /**
3171
3223
  * Get value from an element
3224
+ *
3225
+ * For a `<source>` element, an attribute that is not set (`srcset`, `media`,
3226
+ * `sizes`, `width`, `height`) is read as `null` instead of the empty string
3227
+ * or `0` that the element property would report. An attribute that is set
3228
+ * to an empty string stays an empty string, so "not set" and "empty" remain
3229
+ * distinguishable and a round trip does not leave `srcset=""` / `width="0"`.
3172
3230
  * @param el A target element
3173
3231
  * @param convertType Auto covert type of value
3174
3232
  * @param attr Data attribute name for specifying the node that FrozenPatty treats as a field
@@ -3204,6 +3262,7 @@ function getValues(el, convertType = false, attr = "field", filter) {
3204
3262
  else style = window.getComputedStyle(el);
3205
3263
  value = style.getPropertyValue(css);
3206
3264
  if (css === "background-image") value = getBackgroundImagePath(value);
3265
+ if (css.startsWith("--") && convertType) value = parse(value.trim());
3207
3266
  break;
3208
3267
  }
3209
3268
  value = getAttribute(el, propName, attr, convertType);
@@ -3230,6 +3289,7 @@ function getValues(el, convertType = false, attr = "field", filter) {
3230
3289
  * @param typeConvert
3231
3290
  */
3232
3291
  function getAttribute(el, keyAttr, attr, typeConvert) {
3292
+ if (el.localName === "source" && SOURCE_ATTRIBUTES.has(keyAttr) && !el.hasAttribute(keyAttr)) return null;
3233
3293
  switch (keyAttr) {
3234
3294
  case "contenteditable": if (el instanceof HTMLElement) return el.contentEditable === "" || el.contentEditable === "true";
3235
3295
  else return el.getAttribute(keyAttr) === "" || el.getAttribute(keyAttr) === "true";
@@ -3290,10 +3350,27 @@ function getBackgroundImagePath(value) {
3290
3350
  const origin = `${location.protocol}//${location.hostname}${location.port ? `:${location.port}` : ""}`;
3291
3351
  return decodeURI(value.replace(/^url\(["']?([^"']+)["']?\)$/i, "$1").replace(origin, ""));
3292
3352
  }
3293
- //#endregion
3294
- //#region ../frozen-patty/dist/utils.js
3353
+ // ../frozen-patty/dist/utils.js
3295
3354
  /**
3296
- * List of dangerous HTML elements to block for XSS protection
3355
+ * Elements (lower-case local names) that are always removed, together with their
3356
+ * content, for XSS protection.
3357
+ *
3358
+ * - `noscript` is parsed as elements when scripting is off (the inert document the
3359
+ * sanitizer parses in) and as raw text when it is on (a published page), so a
3360
+ * `</noscript>` inside an attribute value ends the element only in the page. No
3361
+ * amount of re-parsing in the sanitizer can see that, so the element goes.
3362
+ * - `base` rewrites every relative URL of the page.
3363
+ *
3364
+ * Entries are compared with the lower-cased `localName`.
3365
+ *
3366
+ * `meta`, `link` and the SVG animation elements (`animate`, `set`, `animateMotion`,
3367
+ * `animateTransform`) are not listed: only some of them do harm, depending on their
3368
+ * attributes (see {@link isDangerousElement}), so they are decided per element.
3369
+ * @example
3370
+ * ```ts
3371
+ * DANGEROUS_ELEMENTS.includes('noscript'); // true
3372
+ * DANGEROUS_ELEMENTS.includes('span'); // false
3373
+ * ```
3297
3374
  */
3298
3375
  var DANGEROUS_ELEMENTS = [
3299
3376
  "script",
@@ -3304,7 +3381,9 @@ var DANGEROUS_ELEMENTS = [
3304
3381
  "iframe",
3305
3382
  "frame",
3306
3383
  "frameset",
3307
- "applet"
3384
+ "applet",
3385
+ "noscript",
3386
+ "base"
3308
3387
  ];
3309
3388
  /**
3310
3389
  * `data-*-list` の子要素で、DOM 順と配列データの index が逆になる要素。
@@ -3321,33 +3400,25 @@ function isReverseListElement(el) {
3321
3400
  return REVERSE_LIST_ELEMENTS.includes(el.localName);
3322
3401
  }
3323
3402
  /**
3403
+ * Replaces `el` with an element named `nodeName`, carrying over its children and the
3404
+ * attributes that no field is bound to (the bound ones are written later, by the
3405
+ * fields).
3324
3406
  *
3325
- * @param kvs
3326
- */
3327
- function arrayToHash(kvs) {
3328
- const result = {};
3329
- for (const kv of kvs) {
3330
- const k = kv[0];
3331
- const v = kv[1];
3332
- if (!kv[2]) {
3333
- result[k] = v;
3334
- continue;
3335
- }
3336
- const arrayPropVal = result[k];
3337
- if (Array.isArray(arrayPropVal)) {
3338
- arrayPropVal.push(v);
3339
- continue;
3340
- }
3341
- result[k] = k in result ? [arrayPropVal, v] : [v];
3342
- }
3343
- return result;
3344
- }
3345
- /**
3346
- *
3347
- * @param el
3348
- * @param nodeName
3349
- * @param attr
3350
- * @param xssSanitize
3407
+ * With `xssSanitize`, the original `el` is returned and stays in place when the new
3408
+ * element would be dangerous. The name is checked first against {@link DANGEROUS_ELEMENTS}.
3409
+ * `meta` and `link` are decided by their attributes, so they are checked again once the
3410
+ * attributes are copied; `setComponent` checks them a third time after the fields have
3411
+ * written theirs.
3412
+ * @param el The element to replace
3413
+ * @param nodeName The local name of the new element
3414
+ * @param attr Data attribute name for specifying the node that FrozenPatty treats as a field
3415
+ * @param xssSanitize Enable XSS protection
3416
+ * @returns The new element, or `el` when nothing was replaced
3417
+ * @example
3418
+ * ```ts
3419
+ * replaceNode(document.createElement('div'), 'span', 'bge').localName; // 'span' (when `el` has a parent)
3420
+ * replaceNode(el, 'script', 'bge') === el; // true
3421
+ * ```
3351
3422
  */
3352
3423
  function replaceNode(el, nodeName, attr, xssSanitize = true) {
3353
3424
  nodeName = nodeName.toLowerCase();
@@ -3366,49 +3437,235 @@ function replaceNode(el, nodeName, attr, xssSanitize = true) {
3366
3437
  }
3367
3438
  node.setAttribute(name, value);
3368
3439
  }
3440
+ if (xssSanitize && isDangerousElement(node)) return el;
3369
3441
  el.replaceWith(node);
3370
3442
  return node;
3371
3443
  }
3372
3444
  /**
3373
- * Removes dangerous script elements from HTML string
3445
+ * The number of parse → clean → serialize rounds {@link sanitizeHtml} tries before it
3446
+ * gives up and returns an empty string.
3447
+ */
3448
+ var MAX_SANITIZE_PASSES = 5;
3449
+ /**
3450
+ * Elements whose content is run as script or applied as CSS, so that data written into
3451
+ * them is an injection by itself, whatever it contains
3452
+ */
3453
+ var CODE_CONTEXTS = /* @__PURE__ */ new Set(["script", "style"]);
3454
+ /**
3455
+ * One inert document per `document`, reused by every call: creating one costs more
3456
+ * than parsing a field's worth of HTML in it.
3457
+ */
3458
+ var inertDocuments = /* @__PURE__ */ new WeakMap();
3459
+ /**
3460
+ * @returns A document in which nothing is loaded and nothing runs
3461
+ */
3462
+ function getInertDocument() {
3463
+ let inert = inertDocuments.get(document);
3464
+ if (!inert) {
3465
+ inert = document.implementation.createHTMLDocument("");
3466
+ inertDocuments.set(document, inert);
3467
+ }
3468
+ return inert;
3469
+ }
3470
+ /**
3471
+ * Removes what could run script from an HTML string, and returns HTML that parses
3472
+ * to the same tree again.
3473
+ *
3474
+ * - The string is parsed once per round in an inert document (nothing is loaded,
3475
+ * nothing runs), as the children of an element like `context`. The context
3476
+ * matters: `<tr>` and `<td>` survive only inside a table-ish context, and the text
3477
+ * of `<style>` is raw text in HTML but elements in SVG. Pass the element itself, so
3478
+ * its namespace is kept, and what was checked is the tree that gets re-parsed on the
3479
+ * published page.
3480
+ * - Rounds repeat until the serialization stops changing (a parse → serialize
3481
+ * round trip of MathML / SVG with `style` is not stable, which is what mXSS
3482
+ * uses). A string that has not settled after {@link MAX_SANITIZE_PASSES}
3483
+ * rounds is dropped entirely rather than returned half-cleaned, and a warning says so.
3484
+ * - What is removed: the elements {@link isDangerousElement} reports, with their
3485
+ * content (a microdata `<link itemprop>` without `rel` is content and stays), and
3486
+ * the attributes {@link sanitizeAttributeValue} rejects.
3487
+ * - A string without `<` has no markup to clean (a character reference such as `&lt;`
3488
+ * decodes to text, never to an element) and is returned as it is.
3489
+ * - Nothing can be made safe to put in a `<script>` or a `<style>` (the data is the
3490
+ * code), so an empty string is returned for such a `context`.
3491
+ *
3492
+ * The result is only as safe as the place it is inserted: put it in the element, or an
3493
+ * element of the same name and namespace, that was passed as `context`.
3374
3494
  * @param html HTML string
3375
- * @returns Sanitized HTML
3495
+ * @param context The element the result is inserted into, or its local name (HTML namespace)
3496
+ * @returns Sanitized HTML, an empty string when it cannot be made stable, and an empty
3497
+ * string when `html` is not a string or `context` is a `script` or a `style`
3498
+ * @example
3499
+ * ```ts
3500
+ * sanitizeHtml('<a href="java&#x09;script:alert(1)">x</a>'); // '<a>x</a>'
3501
+ * sanitizeHtml('a<script>alert(1)<\/script>b'); // 'ab'
3502
+ * sanitizeHtml('<td>x</td>', 'tr'); // '<td>x</td>'
3503
+ *
3504
+ * const text = document.createElementNS('http://www.w3.org/2000/svg', 'text');
3505
+ * sanitizeHtml('<tspan>x</tspan><animate attributeName="href"/>', text); // '<tspan>x</tspan>'
3506
+ * ```
3376
3507
  */
3377
- function sanitizeHtml(html) {
3508
+ function sanitizeHtml(html, context = "div") {
3378
3509
  if (typeof html !== "string") return "";
3379
- let sanitized = html;
3380
- for (const tagName of DANGEROUS_ELEMENTS) {
3381
- const regex = new RegExp(`<${tagName}[^>]*>(.*?)<\\/${tagName}>`, "gis");
3382
- sanitized = sanitized.replace(regex, "$1");
3510
+ if (CODE_CONTEXTS.has((typeof context === "string" ? context : context.localName).toLowerCase())) return "";
3511
+ if (!html.includes("<")) return html;
3512
+ const inert = getInertDocument();
3513
+ let current = html;
3514
+ for (let pass = 0; pass < MAX_SANITIZE_PASSES; pass++) {
3515
+ const host = typeof context === "string" ? inert.createElement(context) : inert.createElementNS(context.namespaceURI, context.localName);
3516
+ host.innerHTML = current;
3517
+ sanitizeChildren(host instanceof HTMLTemplateElement ? host.content : host);
3518
+ const next = host.innerHTML;
3519
+ if (next === current) return next;
3520
+ current = next;
3521
+ }
3522
+ console.warn(`[frozen-patty] An HTML string did not settle within ${MAX_SANITIZE_PASSES} sanitizing rounds and was dropped.`);
3523
+ return "";
3524
+ }
3525
+ /**
3526
+ * Removes dangerous elements and attributes below `parent`
3527
+ * @param parent
3528
+ */
3529
+ function sanitizeChildren(parent) {
3530
+ const dangerous = [];
3531
+ for (const child of parent.children) {
3532
+ if (isDangerousElement(child)) {
3533
+ dangerous.push(child);
3534
+ continue;
3535
+ }
3536
+ sanitizeAttributes(child);
3537
+ sanitizeChildren(child instanceof HTMLTemplateElement ? child.content : child);
3383
3538
  }
3384
- const fragment = new Range().createContextualFragment(sanitized);
3385
- sanitizeElementAndChildren(fragment);
3386
- return [...fragment.childNodes].map((node) => {
3387
- if (node instanceof Element) return node.outerHTML;
3388
- return node.textContent ?? node.nodeValue ?? "";
3389
- }).join("");
3539
+ for (const child of dangerous) child.remove();
3540
+ }
3541
+ /**
3542
+ * SVG elements that set an attribute of their target at run time
3543
+ */
3544
+ var ANIMATION_ELEMENTS = /* @__PURE__ */ new Set([
3545
+ "animate",
3546
+ "set",
3547
+ "animatemotion",
3548
+ "animatetransform"
3549
+ ]);
3550
+ /**
3551
+ * Whether an SVG animation element sets `href` or an event handler of its target.
3552
+ * The value of what it sets (`to`, `values`, …) is never looked at by the attribute
3553
+ * checks, so a `javascript:` URL there reaches a link; the element goes instead. Only
3554
+ * `attributeName` decides, read as the SMIL engine does (case ignored, `xlink:` dropped).
3555
+ * @param el
3556
+ */
3557
+ function animatesDangerousAttribute(el) {
3558
+ for (const { name, value } of el.attributes) if (name.toLowerCase() === "attributename") {
3559
+ const target = value.trim().toLowerCase().replace(/^xlink:/, "");
3560
+ return target === "href" || target.startsWith("on");
3561
+ }
3562
+ return false;
3563
+ }
3564
+ /**
3565
+ * Whether the XSS protection removes an element together with its content: an element
3566
+ * in {@link DANGEROUS_ELEMENTS}, a `<meta>` with `http-equiv` (a redirect), a
3567
+ * `<link>` that is not plain microdata (without `itemprop`, or with `rel`, which loads
3568
+ * a stylesheet or a resource hint), and an SVG animation element (`animate`, `set`,
3569
+ * `animateMotion`, `animateTransform`) whose `attributeName` is `href` or an event
3570
+ * handler. Other animations (`attributeName="opacity"`) are content and stay.
3571
+ * @param el The element to judge, by its name and its attributes at this moment
3572
+ * @returns `true` when the element is removed together with its content
3573
+ * @example
3574
+ * ```ts
3575
+ * isDangerousElement(document.createElement('script')); // true
3576
+ * // <meta http-equiv="refresh" content="0;url=…"> redirects the page
3577
+ * // <meta itemprop="name" content="x"> is microdata
3578
+ * // <link rel="stylesheet" href="…"> and <link href="…"> load a resource
3579
+ * // <link itemprop="url" href="…"> is microdata
3580
+ * // <animate attributeName="href" to="javascript:…"> rewrites a link
3581
+ * // <animate attributeName="opacity" from="0" to="1"> is an animation
3582
+ * ```
3583
+ */
3584
+ function isDangerousElement(el) {
3585
+ const name = el.localName.toLowerCase();
3586
+ if (DANGEROUS_ELEMENTS.includes(name)) return true;
3587
+ if (name === "meta") return el.hasAttribute("http-equiv");
3588
+ if (name === "link") return !el.hasAttribute("itemprop") || el.hasAttribute("rel");
3589
+ if (ANIMATION_ELEMENTS.has(name)) return animatesDangerousAttribute(el);
3590
+ return false;
3390
3591
  }
3391
3592
  /**
3392
- * Sanitizes an element and all its child elements
3393
- * @param node Target element
3593
+ * Attributes whose value is a URL that the browser follows or loads. `poster`, `ping`,
3594
+ * `cite` and `background` do not run script in current browsers; they are checked
3595
+ * defensively, so that a stored page carries no `javascript:` or `data:` URL in any URL
3596
+ * attribute. (`ping` is a list: only its first URL is checked.)
3597
+ */
3598
+ var URL_ATTRIBUTES = /* @__PURE__ */ new Set([
3599
+ "href",
3600
+ "src",
3601
+ "action",
3602
+ "formaction",
3603
+ "xlink:href",
3604
+ "poster",
3605
+ "ping",
3606
+ "cite",
3607
+ "background"
3608
+ ]);
3609
+ /**
3610
+ * Names of the event handler attributes (`onclick`, `onerror`, …)
3611
+ */
3612
+ var EVENT_HANDLER_NAME = /^on[a-z]+$/;
3613
+ /**
3614
+ * The attributes in which an image is loaded as an image, so that a `data:` URL of a
3615
+ * raster image is content and cannot run script
3394
3616
  */
3395
- function sanitizeElementAndChildren(node) {
3396
- if (node instanceof Element) sanitizeAttributes(node);
3397
- for (const child of node.childNodes) sanitizeElementAndChildren(child);
3617
+ var DATA_IMAGE_ATTRIBUTES = /* @__PURE__ */ new Set(["src", "poster"]);
3618
+ /**
3619
+ * A `data:` URL of a raster image. SVG is left out: in `<img>` it does not run script,
3620
+ * but the same value is no safer for being named `src`.
3621
+ */
3622
+ var SAFE_DATA_IMAGE = /^data:image\/(?:png|jpeg|gif|webp|avif)[;,]/;
3623
+ /**
3624
+ * Reduces a URL attribute value to what the URL parser sees: leading C0 controls and
3625
+ * spaces dropped, ASCII tabs and newlines removed anywhere, lower-cased.
3626
+ * @param value
3627
+ */
3628
+ function normalizeUrl(value) {
3629
+ const noBreaks = value.replaceAll(/[\t\n\r]/g, "");
3630
+ let start = 0;
3631
+ while (start < noBreaks.length && noBreaks.codePointAt(start) <= 32) start++;
3632
+ return noBreaks.slice(start).toLowerCase();
3398
3633
  }
3399
3634
  /**
3400
- * Sanitizes attribute value
3401
- * @param name Attribute name
3635
+ * Judges whether an attribute may be written with the given value.
3636
+ *
3637
+ * - Event handler attributes (`on` and letters: `onclick`, `onerror`, …) and `manifest`
3638
+ * are never allowed.
3639
+ * - For the URL attributes (`href`, `src`, `action`, `formaction`, `xlink:href`,
3640
+ * `poster`, `ping`, `cite`, `background`) a value that starts with `javascript:`,
3641
+ * `data:` or `vbscript:` is not allowed. The value is read the way the URL parser
3642
+ * reads it (leading control characters and spaces dropped, tabs and newlines removed
3643
+ * anywhere, case ignored), because `java&#x09;script:alert(1)` is a `javascript:` URL
3644
+ * to the browser but not to a plain `startsWith`.
3645
+ * - The exception is a `data:` URL of a raster image (`png`, `jpeg`, `gif`, `webp`,
3646
+ * `avif`) in `src` or `poster`, which loads as an image and runs nothing.
3647
+ * - Anything else, and any value that is not a string, passes.
3648
+ * @param name Attribute name (case is ignored)
3402
3649
  * @param value Attribute value
3403
- * @returns Safe attribute value, or null if dangerous
3650
+ * @returns The value itself, or `null` when the attribute must not be written
3651
+ * @example
3652
+ * ```ts
3653
+ * sanitizeAttributeValue('href', 'java\tscript:alert(1)'); // null
3654
+ * sanitizeAttributeValue('onclick', 'x()'); // null
3655
+ * sanitizeAttributeValue('href', 'https://example.com/'); // 'https://example.com/'
3656
+ * sanitizeAttributeValue('title', 'javascript: is a language'); // 'javascript: is a language'
3657
+ * sanitizeAttributeValue('one-time', 'x'); // 'x'
3658
+ * sanitizeAttributeValue('src', 'data:image/png;base64,AAAA'); // 'data:image/png;base64,AAAA'
3659
+ * sanitizeAttributeValue('href', 'data:image/png;base64,AAAA'); // null
3660
+ * ```
3404
3661
  */
3405
3662
  function sanitizeAttributeValue(name, value) {
3406
3663
  if (typeof value !== "string") return value;
3407
3664
  name = name.toLowerCase();
3408
- if (name.startsWith("on")) return null;
3409
- if (name === "href" || name === "src" || name === "action" || name === "formaction" || name === "xlink:href") {
3410
- const trimmedValue = value.trim().toLowerCase();
3411
- if (trimmedValue.startsWith("javascript:") || trimmedValue.startsWith("data:") || trimmedValue.startsWith("vbscript:")) return null;
3665
+ if (EVENT_HANDLER_NAME.test(name)) return null;
3666
+ if (URL_ATTRIBUTES.has(name)) {
3667
+ const url = normalizeUrl(value);
3668
+ if (url.startsWith("javascript:") || url.startsWith("vbscript:") || url.startsWith("data:") && !(DATA_IMAGE_ATTRIBUTES.has(name) && SAFE_DATA_IMAGE.test(url))) return null;
3412
3669
  }
3413
3670
  if (["manifest"].includes(name)) return null;
3414
3671
  return value;
@@ -3496,7 +3753,11 @@ function flattenData(data, index) {
3496
3753
  /**
3497
3754
  * 特定の要素で、`propName in element`で判定できない属性名
3498
3755
  */
3499
- var specificProp = { source: ["width", "height"] };
3756
+ var specificProp = {
3757
+ source: ["width", "height"],
3758
+ img: ["loading"],
3759
+ button: ["command"]
3760
+ };
3500
3761
  /**
3501
3762
  *
3502
3763
  * @param el
@@ -3506,8 +3767,7 @@ function propInElement(el, name) {
3506
3767
  if (name in el) return true;
3507
3768
  return specificProp[el.localName]?.includes(name) ?? false;
3508
3769
  }
3509
- //#endregion
3510
- //#region ../frozen-patty/dist/get-component.js
3770
+ // ../frozen-patty/dist/get-component.js
3511
3771
  /**
3512
3772
  *
3513
3773
  * @param el
@@ -3526,13 +3786,103 @@ function getComponent(el, attr, typeConvert, filter) {
3526
3786
  }
3527
3787
  reverseListElement.append(...children);
3528
3788
  }
3789
+ const listAttr = `data-${attr}-list`;
3529
3790
  const filedElements = el.querySelectorAll(`[data-${attr}]`);
3530
- let values = [];
3531
- for (const _el of filedElements) values = [...values, ...getValues(_el, typeConvert, attr, filter)];
3532
- return arrayToHash(values);
3791
+ const values = [];
3792
+ const childIndexes = /* @__PURE__ */ new Map();
3793
+ for (const _el of filedElements) {
3794
+ const positions = listPositions(_el, listAttr, childIndexes);
3795
+ for (const [key, value, forceArray] of getValues(_el, typeConvert, attr, filter)) values.push([
3796
+ key,
3797
+ value,
3798
+ forceArray,
3799
+ positions
3800
+ ]);
3801
+ }
3802
+ return nestedArrayToHash(values);
3803
+ }
3804
+ /**
3805
+ * 要素を含むリスト(祖先のみ。自分自身は含まない)ごとの位置を、外側から順に返す。
3806
+ * `picture` の子は呼び出し側が先に反転しているので、DOM の順がデータの順になる
3807
+ * @param el
3808
+ * @param listAttr
3809
+ * @param childIndexes - リストの根ごとの、子の位置。フィールドの要素ごとに子を数え直さない
3810
+ * (数え直すと、リストの項目数とフィールド数の積の手間になる)よう、読み取り 1 回の間で使い回す
3811
+ */
3812
+ function listPositions(el, listAttr, childIndexes) {
3813
+ const positions = [];
3814
+ let child = el;
3815
+ let parent = child.parentElement;
3816
+ while (parent) {
3817
+ if (parent.hasAttribute(listAttr)) {
3818
+ let indexes = childIndexes.get(parent);
3819
+ if (!indexes) {
3820
+ indexes = new Map([...parent.children].map((item, index) => [item, index]));
3821
+ childIndexes.set(parent, indexes);
3822
+ }
3823
+ positions.unshift({
3824
+ index: indexes.get(child) ?? -1,
3825
+ length: parent.children.length
3826
+ });
3827
+ }
3828
+ child = parent;
3829
+ parent = parent.parentElement;
3830
+ }
3831
+ return positions;
3533
3832
  }
3534
- //#endregion
3535
- //#region ../frozen-patty/dist/set-value.js
3833
+ /**
3834
+ * 値をキーごとにまとめる。入れ子でない値(リストの外・深さ 1 のリスト)は
3835
+ * `arrayToHash` と同じ規則で、入れ子の値は外側の項目の位置ごとの配列に置く
3836
+ * @param values
3837
+ */
3838
+ function nestedArrayToHash(values) {
3839
+ const result = {};
3840
+ for (const [key, value, forceArray, positions] of values) {
3841
+ if (!forceArray) {
3842
+ result[key] = value;
3843
+ continue;
3844
+ }
3845
+ const outer = positions.slice(0, -1);
3846
+ const current = result[key];
3847
+ if (outer.length === 0) {
3848
+ if (Array.isArray(current)) {
3849
+ current.push(value);
3850
+ continue;
3851
+ }
3852
+ result[key] = key in result ? [current, value] : [value];
3853
+ continue;
3854
+ }
3855
+ let container;
3856
+ if (Array.isArray(current)) container = current;
3857
+ else {
3858
+ container = key in result ? [current] : [];
3859
+ result[key] = container;
3860
+ }
3861
+ place(container, outer, value);
3862
+ }
3863
+ return result;
3864
+ }
3865
+ /**
3866
+ * 外側の段の位置に従って、値を入れ子の配列に置く。最も内側では文書順に積む
3867
+ * @param container
3868
+ * @param outer
3869
+ * @param value
3870
+ */
3871
+ function place(container, outer, value) {
3872
+ const [position, ...rest] = outer;
3873
+ if (!position) {
3874
+ container.push(value);
3875
+ return;
3876
+ }
3877
+ while (container.length < position.length) container.push([]);
3878
+ let slot = container[position.index];
3879
+ if (!Array.isArray(slot)) {
3880
+ slot = slot === void 0 ? [] : [slot];
3881
+ container[position.index] = slot;
3882
+ }
3883
+ place(slot, rest, value);
3884
+ }
3885
+ // ../frozen-patty/dist/set-value.js
3536
3886
  /**
3537
3887
  * Set value to an element
3538
3888
  *
@@ -3874,7 +4224,7 @@ function setContent(el, datum, asHtml = true, xssSanitize = true) {
3874
4224
  }
3875
4225
  if (asHtml) {
3876
4226
  const htmlStr = datum == null ? "" : `${datum}`;
3877
- if (xssSanitize && typeof htmlStr === "string") el.innerHTML = sanitizeHtml(htmlStr);
4227
+ if (xssSanitize && typeof htmlStr === "string") el.innerHTML = sanitizeHtml(htmlStr, el);
3878
4228
  else el.innerHTML = htmlStr;
3879
4229
  return;
3880
4230
  }
@@ -3898,8 +4248,7 @@ function toNum(datum) {
3898
4248
  function toInt(datum) {
3899
4249
  return Math.floor(toNum(datum));
3900
4250
  }
3901
- //#endregion
3902
- //#region ../frozen-patty/dist/stringify-fields.js
4251
+ // ../frozen-patty/dist/stringify-fields.js
3903
4252
  /**
3904
4253
  * Combines multiple field definitions with comma separation
3905
4254
  * @param fields Array of field definitions
@@ -3919,8 +4268,7 @@ function stringifyField(fieldName, propName) {
3919
4268
  if (fieldName === propName) return `:${propName}`;
3920
4269
  return `${fieldName}:${propName}`;
3921
4270
  }
3922
- //#endregion
3923
- //#region ../frozen-patty/dist/set-component.js
4271
+ // ../frozen-patty/dist/set-component.js
3924
4272
  /**
3925
4273
  * `picture` 内の `source` で無効な、`img` 専用の属性。
3926
4274
  * `source` で有効な属性の allowlist にしないのは、グローバル属性・`data-*`・
@@ -3982,7 +4330,9 @@ function setComponent(el, data, attr, filter, xssSanitize = true) {
3982
4330
  const targetList = [el, ...el.querySelectorAll(`[data-${attr}*="${kebabCase(dataKeyName)}"]`)].filter((el) => hasField(el, attr, dataKeyName));
3983
4331
  for (const targetEl of targetList) setValue(targetEl, dataKeyName, datum, attr, filter, xssSanitize);
3984
4332
  }
4333
+ if (xssSanitize) for (const dangerous of [...el.querySelectorAll("meta, link")].filter((child) => isDangerousElement(child))) dangerous.remove();
3985
4334
  for (const listRoot of el.querySelectorAll(`[data-${attr}-list]`)) {
4335
+ if (!el.contains(listRoot)) continue;
3986
4336
  const reverse = isReverseListElement(listRoot);
3987
4337
  const decendants = listRoot.querySelectorAll("*");
3988
4338
  const maxLength = maxLengthOf(data, [...new Set([...decendants].flatMap((el) => definedFields(el, attr)))]);
@@ -4019,14 +4369,14 @@ function setComponent(el, data, attr, filter, xssSanitize = true) {
4019
4369
  }
4020
4370
  }
4021
4371
  const newEl = setComponent(item, itemData, attr, filter, xssSanitize);
4372
+ if (xssSanitize && isDangerousElement(newEl)) continue;
4022
4373
  if (reverse) listRoot.prepend(newEl);
4023
4374
  else listRoot.append(newEl);
4024
4375
  }
4025
4376
  }
4026
4377
  return el;
4027
4378
  }
4028
- //#endregion
4029
- //#region ../frozen-patty/dist/frozen-patty.js
4379
+ // ../frozen-patty/dist/frozen-patty.js
4030
4380
  var FrozenPatty = class {
4031
4381
  #attr = "field";
4032
4382
  #dom;
@@ -4045,11 +4395,11 @@ var FrozenPatty = class {
4045
4395
  * @param options Options
4046
4396
  */
4047
4397
  constructor(html, options) {
4048
- this.#dom = document.createElement("fp-placeholer");
4398
+ this.#dom = document.createElement("fp-placeholder");
4049
4399
  if (options?.xssSanitize === false) {
4050
4400
  this.#dom.innerHTML = html;
4051
4401
  this.#xssSanitize = false;
4052
- } else this.#dom.innerHTML = sanitizeHtml(html);
4402
+ } else this.#dom.innerHTML = sanitizeHtml(html, this.#dom);
4053
4403
  if (options) {
4054
4404
  if (options.attr) this.#attr = options.attr;
4055
4405
  this.#typeConvert = !!options.typeConvert;
@@ -4073,8 +4423,7 @@ var FrozenPatty = class {
4073
4423
  return getComponent(this.#dom, this.#attr, this.#typeConvert, filter);
4074
4424
  }
4075
4425
  };
4076
- //#endregion
4077
- //#region ../frozen-patty/dist/index.js
4426
+ // ../frozen-patty/dist/index.js
4078
4427
  /**
4079
4428
  * Pure HTML to JSON converter that not use template engine.
4080
4429
  * @param html Original HTML
@@ -4088,8 +4437,7 @@ var FrozenPatty = class {
4088
4437
  function frozenPatty(html, options) {
4089
4438
  return new FrozenPatty(html, options);
4090
4439
  }
4091
- //#endregion
4092
- //#region ../../../node_modules/jaco/dist/fn/replaceFromMap.js
4440
+ // ../../../node_modules/jaco/dist/fn/replaceFromMap.js
4093
4441
  /**
4094
4442
  * キーがパターン・値が置換文字列のハッシュマップによって置換する
4095
4443
  *
@@ -4101,8 +4449,7 @@ function replaceFromMap_default(str, convMap) {
4101
4449
  for (const [needle, replace] of Object.entries(convMap)) if (replace) str = str.replace(new RegExp(needle, "g"), replace);
4102
4450
  return str;
4103
4451
  }
4104
- //#endregion
4105
- //#region ../../../node_modules/jaco/dist/fn/combineSoundMarks.js
4452
+ // ../../../node_modules/jaco/dist/fn/combineSoundMarks.js
4106
4453
  /**
4107
4454
  * 濁点・半濁点とひらがな・かたかなを結合させる
4108
4455
  *
@@ -4180,8 +4527,7 @@ function combineSoundMarks(str, convertOnly = false) {
4180
4527
  });
4181
4528
  return str;
4182
4529
  }
4183
- //#endregion
4184
- //#region ../core/dist/item/value-filter.js
4530
+ // ../core/dist/item/value-filter.js
4185
4531
  /**
4186
4532
  *
4187
4533
  * @param datum
@@ -4191,22 +4537,18 @@ function valueFilter(datum) {
4191
4537
  let str = datum;
4192
4538
  str = combineSoundMarks(str);
4193
4539
  if (str.trim().startsWith("<")) {
4194
- const d = document.createElement("div");
4540
+ const d = document.implementation.createHTMLDocument("").createElement("div");
4195
4541
  d.innerHTML = str;
4196
4542
  const elements = d.querySelectorAll("*");
4197
4543
  for (const element of elements) {
4198
- const attrs = element.attributes;
4199
- for (let i = 0, l = attrs.length; i < l; i++) {
4200
- const attr = attrs.item(i);
4201
- if (attr && /data-bg[ebt](?:-.+)?/i.test(attr.name)) element.removeAttribute(attr.name);
4202
- }
4544
+ const markers = [...element.attributes].filter((attr) => /data-bg[ebt](?:-.+)?/i.test(attr.name));
4545
+ for (const attr of markers) element.removeAttribute(attr.name);
4203
4546
  }
4204
4547
  str = d.innerHTML;
4205
4548
  }
4206
4549
  return str;
4207
4550
  }
4208
- //#endregion
4209
- //#region ../core/dist/item/data-from-html.js
4551
+ // ../core/dist/item/data-from-html.js
4210
4552
  /**
4211
4553
  *
4212
4554
  * @param html
@@ -4218,8 +4560,7 @@ function dataFromHtml(html) {
4218
4560
  valueFilter
4219
4561
  }).toJSON();
4220
4562
  }
4221
- //#endregion
4222
- //#region ../core/dist/block/parse-html-to-definition.js
4563
+ // ../core/dist/block/parse-html-to-definition.js
4223
4564
  /**
4224
4565
  * HTMLElement(ブロック要素)をBlockDataに変換する
4225
4566
  * @param el HTMLElement(data-bge-name属性を持つ要素)
@@ -4269,8 +4610,7 @@ function getItemFromElement(el) {
4269
4610
  };
4270
4611
  });
4271
4612
  }
4272
- //#endregion
4273
- //#region ../core/dist/utils/replace-placeholders.js
4613
+ // ../core/dist/utils/replace-placeholders.js
4274
4614
  /**
4275
4615
  * テンプレート文字列のプレースホルダーを設定値で置換する
4276
4616
  * @param template
@@ -4279,8 +4619,7 @@ function getItemFromElement(el) {
4279
4619
  function replacePlaceholders(template, config) {
4280
4620
  return template.replaceAll("%sampleImagePath%", config.sampleImagePath).replaceAll("%sampleFilePath%", config.sampleFilePath).replaceAll("%googleMapsApiKey%", config.googleMapsApiKey ?? "");
4281
4621
  }
4282
- //#endregion
4283
- //#region ../core/dist/item/create-item.js
4622
+ // ../core/dist/item/create-item.js
4284
4623
  /**
4285
4624
  * アイテム定義(seed)を作成する
4286
4625
  *
@@ -4329,8 +4668,7 @@ function createUnknownContentItem(el, fallbackName = "unknown-content") {
4329
4668
  style: ""
4330
4669
  });
4331
4670
  }
4332
- //#endregion
4333
- //#region ../core/dist/item/data-to-html.js
4671
+ // ../core/dist/item/data-to-html.js
4334
4672
  /**
4335
4673
  *
4336
4674
  * @param html
@@ -4344,8 +4682,68 @@ function dataToHtml(html, data) {
4344
4682
  xssSanitize: !data.dangerouslySetInnerHTML
4345
4683
  }).merge(data).toHTML();
4346
4684
  }
4347
- //#endregion
4348
- //#region ../core/dist/item/item.js
4685
+ // ../core/dist/item/normalize-item-data.js
4686
+ /**
4687
+ * Pass item data through a seed's `normalizeItemData` right before it becomes
4688
+ * HTML. A seed without `normalizeItemData` leaves the data as it is.
4689
+ *
4690
+ * Every writer that turns item data into HTML (`Item.import`, `render()`, and
4691
+ * the agent tools that write to disk) calls this at the same point. A separate
4692
+ * normalization per path would let a save from the editor and a save from an
4693
+ * agent produce different HTML for the same data.
4694
+ *
4695
+ * The same object comes back when nothing changed, so a writer that reads
4696
+ * items back from raw HTML can tell whether it has to render again.
4697
+ * @param seed - The item definition. `null` / `undefined` (an item that is not
4698
+ * defined) leaves the data as it is
4699
+ * @param data - The data to become HTML: the merged data of an existing item,
4700
+ * or the supplied data (possibly partial) of a new one
4701
+ * @param config - The editor config
4702
+ * @example
4703
+ * ```ts
4704
+ * const data = normalizeItemData(
4705
+ * items.image,
4706
+ * { path: ['/img/pc.png', '/img/sp.png'], media: ['', ''] },
4707
+ * config,
4708
+ * );
4709
+ * // data.media is ['', '(max-width: 767px)']: the image seed fills the default
4710
+ * ```
4711
+ */
4712
+ function normalizeItemData(seed, data, config) {
4713
+ return seed?.normalizeItemData?.(data, config) ?? data;
4714
+ }
4715
+ // ../core/dist/item/import-item-html.js
4716
+ /**
4717
+ * Write data into an item's HTML: read the current data back from `html`,
4718
+ * shallow-merge `newData` over it, pass the result through the seed's
4719
+ * `normalizeItemData`, and render it with `html` as the template.
4720
+ *
4721
+ * `Item.import` and the agent tools that write to disk both use this, so a
4722
+ * save from the editor and a save from an agent go through the same steps in
4723
+ * the same order and produce the same HTML for the same data.
4724
+ * @param html - The item's current inner HTML (the content of `[data-bgi]`)
4725
+ * @param newData - The keys to change; the others keep their current values
4726
+ * @param seed - The item definition. `null` / `undefined` (an item that is not
4727
+ * defined) renders the merged data as it is
4728
+ * @param config - The editor config
4729
+ * @returns The new inner HTML
4730
+ * @example
4731
+ * ```ts
4732
+ * wrapper.innerHTML = importItemHtml(
4733
+ * wrapper.innerHTML,
4734
+ * { path: ['/img/pc.png', '/img/sp.png'] },
4735
+ * items.image,
4736
+ * config,
4737
+ * );
4738
+ * ```
4739
+ */
4740
+ function importItemHtml(html, newData, seed, config) {
4741
+ return dataToHtml(html, normalizeItemData(seed, {
4742
+ ...dataFromHtml(html),
4743
+ ...newData
4744
+ }, config));
4745
+ }
4746
+ // ../core/dist/item/item.js
4349
4747
  var elMap = /* @__PURE__ */ new WeakMap();
4350
4748
  var Item = class Item {
4351
4749
  config;
@@ -4371,12 +4769,20 @@ var Item = class Item {
4371
4769
  export() {
4372
4770
  return dataFromHtml(this.el.innerHTML);
4373
4771
  }
4772
+ /**
4773
+ * Write data into the item: the current data is read back from the item's
4774
+ * HTML, merged with `newData`, passed through the seed's `normalizeItemData`,
4775
+ * and rendered again. The saved HTML can therefore differ from `newData`
4776
+ * where the seed normalizes it (for example, an image's second `<source>` never
4777
+ * keeps an empty `media`).
4778
+ * @param newData - The keys to change; the others keep their current values
4779
+ * @example
4780
+ * ```ts
4781
+ * item.import({ path: ['/a.png', '/b.png'] });
4782
+ * ```
4783
+ */
4374
4784
  import(newData) {
4375
- const data = {
4376
- ...this.export(),
4377
- ...newData
4378
- };
4379
- this.el.innerHTML = Item.createElement(this.el.innerHTML, data);
4785
+ this.el.innerHTML = importItemHtml(this.el.innerHTML, newData, this.seed, this.config);
4380
4786
  }
4381
4787
  isDisable() {
4382
4788
  return this.seed.editorOptions?.isDisable?.(this) ?? "";
@@ -4411,8 +4817,7 @@ var Item = class Item {
4411
4817
  return elMap.get(el);
4412
4818
  }
4413
4819
  };
4414
- //#endregion
4415
- //#region ../core/dist/block/update-grid-items.js
4820
+ // ../core/dist/block/update-grid-items.js
4416
4821
  /**
4417
4822
  * グリッドアイテムを追加または削除する
4418
4823
  * @param $items - 子要素の配列
@@ -4451,8 +4856,7 @@ function updateGridItems($items, engine, addOrRemove, items, updateItem) {
4451
4856
  newItems.splice(-removeCount);
4452
4857
  updateItem(newItems);
4453
4858
  }
4454
- //#endregion
4455
- //#region ../core/dist/block/block.js
4859
+ // ../core/dist/block/block.js
4456
4860
  var bbMap = /* @__PURE__ */ new WeakMap();
4457
4861
  var _lastUID = 0;
4458
4862
  var BurgerBlock = class BurgerBlock {
@@ -4637,8 +5041,7 @@ function fallbackBlockData(html) {
4637
5041
  function isBurgerBlockElement(el) {
4638
5042
  return el.matches(["[data-bge-name][data-bge-container]:has(>[data-bge-container-frame]>[data-bge-group]>[data-bge-item])"].join(","));
4639
5043
  }
4640
- //#endregion
4641
- //#region ../core/dist/utils/as-disposable-fn.js
5044
+ // ../core/dist/utils/as-disposable-fn.js
4642
5045
  /**
4643
5046
  * Wraps a teardown function so it is also `Disposable`, letting callers
4644
5047
  * either invoke it directly (`detach()`) or hold it in a `using`
@@ -4658,8 +5061,7 @@ function isBurgerBlockElement(el) {
4658
5061
  function asDisposableFn(fn) {
4659
5062
  return Object.assign(fn, { [Symbol.dispose]: fn });
4660
5063
  }
4661
- //#endregion
4662
- //#region ../core/dist/command/command-bus.js
5064
+ // ../core/dist/command/command-bus.js
4663
5065
  /**
4664
5066
  * Prefix for the id assigned to every command bus receiver element.
4665
5067
  *
@@ -4707,7 +5109,7 @@ var CommandBus = class {
4707
5109
  * stay stable and readable across a test run or a debugging session.
4708
5110
  * Uniqueness holds only within one loaded copy of this module — the same
4709
5111
  * caveat as the `BurgerBlock`/`Item` module-level registries documented
4710
- * in ARCHITECTURE.md § 不変条件と否定的知識 applies here too.
5112
+ * in ARCHITECTURE.md § 不変条件と負の知識 applies here too.
4711
5113
  */
4712
5114
  receiverId = `${COMMAND_BUS_ID}-${++receiverSequence}`;
4713
5115
  #detachers = /* @__PURE__ */ new Map();
@@ -4775,8 +5177,7 @@ var CommandBus = class {
4775
5177
  this.#detachers.clear();
4776
5178
  }
4777
5179
  };
4778
- //#endregion
4779
- //#region ../core/dist/dom-helpers/create-stylesheet.js
5180
+ // ../core/dist/dom-helpers/create-stylesheet.js
4780
5181
  /**
4781
5182
  *
4782
5183
  * @param cssContents
@@ -4787,35 +5188,28 @@ function createStylesheet(cssContents, layer) {
4787
5188
  const blob = new Blob([css], { type: "text/css" });
4788
5189
  return URL.createObjectURL(blob);
4789
5190
  }
4790
- //#endregion
4791
- //#region ../core/dist/dom-helpers/create-component-stylesheet.js
5191
+ // ../core/dist/dom-helpers/editor-stylesheet-texts.js
4792
5192
  /**
4793
- *
4794
- * @param items
4795
- * @param generalCSS
4796
- * @param layer
5193
+ * The first two texts of {@link editorStylesheetTexts}: the layer order
5194
+ * statement and the base layer. Separate so the engine can create them
5195
+ * before it fetches `config.stylesheets`.
5196
+ * @param items - Item seeds whose `style` is loaded
5197
+ * @param generalCSS - Shared block CSS
4797
5198
  */
4798
- function createComponentStylesheet(items, generalCSS, layer) {
4799
- return createStylesheet(Object.values(items).map((item) => item.style).filter(Boolean).join("\n") + "\n" + generalCSS, layer);
5199
+ function editorBaseStylesheetTexts(items, generalCSS) {
5200
+ const itemStyles = Object.values(items).map((item) => item.style).filter(Boolean).join("\n");
5201
+ return [`@layer ${CSS_LAYER.base}, ${CSS_LAYER.components}, ${CSS_LAYER.ui};`, `@layer ${CSS_LAYER.base} {${itemStyles}\n${generalCSS}}`];
4800
5202
  }
4801
- //#endregion
4802
- //#region ../core/dist/dom-helpers/create-stylesheet-from-url.js
4803
5203
  /**
4804
- *
4805
- * @param url
4806
- * @param layer
5204
+ * One `config.stylesheets` entry as {@link editorStylesheetTexts} places it.
5205
+ * @param css - Stylesheet contents
5206
+ * @param layer - Cascade layer; the components layer when omitted, and no
5207
+ * layer at all for `''`
4807
5208
  */
4808
- async function createStylesheetFromUrl(url, layer) {
4809
- const cssContents = await (await fetch(url)).text();
4810
- const css = layer ? `@layer ${layer} {${cssContents}}` : cssContents;
4811
- const blob = new Blob([css], { type: "text/css" });
4812
- return {
4813
- blob: URL.createObjectURL(blob),
4814
- originalUrl: url
4815
- };
5209
+ function editorProjectStylesheetText(css, layer = CSS_LAYER.components) {
5210
+ return layer ? `@layer ${layer} {${css}}` : css;
4816
5211
  }
4817
- //#endregion
4818
- //#region ../core/dist/utils/compare-priority.js
5212
+ // ../core/dist/utils/compare-priority.js
4819
5213
  /**
4820
5214
  * Compare two priority arrays
4821
5215
  * Smaller numbers have higher priority.
@@ -4843,22 +5237,32 @@ function comparePriority(a, b) {
4843
5237
  if (a.length > b.length) return -1;
4844
5238
  return 0;
4845
5239
  }
4846
- //#endregion
4847
- //#region ../core/dist/dom-helpers/get-custom-properties.js
5240
+ // ../core/dist/dom-helpers/get-custom-properties.js
4848
5241
  /**
4849
- * Get all custom properties from document
5242
+ * Get all `--bge-options-*` custom properties from document, grouped by
5243
+ * category. See the file-level comment for the detection rules.
5244
+ *
5245
+ * Inside the editor, call `engine.getCustomProperties()` instead; this
5246
+ * free function is for scanning a document the engine does not own, such
5247
+ * as stylesheets loaded into a jsdom document on Node.
4850
5248
  * @param scope - Document to scan for CSS custom properties
4851
5249
  * @param containerType - Container type to filter container-scoped properties (prefixed with `_`)
4852
5250
  * @returns Categorized map of custom properties grouped by property name
5251
+ * @example
5252
+ * ```ts
5253
+ * for (const [id, category] of getCustomProperties(document, 'grid')) {
5254
+ * console.log(id, [...category.properties.keys()]); // 'margin' ['none', 'small', ...]
5255
+ * }
5256
+ * ```
4853
5257
  */
4854
5258
  function getCustomProperties(scope, containerType) {
4855
5259
  const categories = /* @__PURE__ */ new Map();
4856
5260
  const defaultValues = /* @__PURE__ */ new Map();
4857
5261
  const nestedDefaultValues = /* @__PURE__ */ new Map();
4858
5262
  searchCustomProperty(scope, (cssProperty, value, layers, isNested) => {
4859
- if (!cssProperty.startsWith("--bge-options-")) return;
4860
- const [propName, key] = cssProperty.slice(BLOCK_OPTION_CSS_CUSTOM_PROPERTY_PREFIX.length).split("--");
4861
- if (!propName) return;
5263
+ const parsed = parseStyleOptionName(cssProperty);
5264
+ if (!parsed) return;
5265
+ const { category: propName, key } = parsed;
4862
5266
  if (propName.startsWith("_") && !propName.startsWith(`_${containerType}_`)) return;
4863
5267
  const currentMap = categories.get(propName) ?? {
4864
5268
  id: propName,
@@ -4885,7 +5289,10 @@ function getCustomProperties(scope, containerType) {
4885
5289
  targetMap.set(propName, currentDefaultValue ? compareCustomPropertyByLayerPriority(currentDefaultValue, newDefaultValue) : newDefaultValue);
4886
5290
  }
4887
5291
  });
4888
- for (const propList of categories.values()) for (const [key, customProperty] of propList.properties.entries()) if (customProperty.value.trim() === "") propList.properties.delete(key);
5292
+ for (const propList of categories.values()) for (const [key, customProperty] of propList.properties.entries()) {
5293
+ const value = customProperty.value.trim();
5294
+ if (value === "" || value === "--bge-empty-custom-property-value") propList.properties.delete(key);
5295
+ }
4889
5296
  for (const [category, nestedProperty] of nestedDefaultValues.entries()) {
4890
5297
  const directProperty = defaultValues.get(category);
4891
5298
  if (directProperty) {
@@ -5017,11 +5424,13 @@ function searchCustomProperty(scope, found) {
5017
5424
  for (const cssRule of styleRules) {
5018
5425
  const rawSelector = cssRule.rule.selectorText.trim();
5019
5426
  const selector = rawSelector.replace(/^&/, "").trim();
5020
- if (selector === BLOCK_OPTION_SCOPE_SELECTOR || selector === ":scope" && cssRule.scopeRoot === BLOCK_OPTION_SCOPE_SELECTOR) {
5427
+ if (selector === "[data-bge-container]" || selector === ":scope" && cssRule.scopeRoot === "[data-bge-container]") {
5021
5428
  const isNested = rawSelector !== selector;
5022
- for (const cssProperty of cssRule.rule.style) {
5429
+ const declarations = cssRule.rule.style;
5430
+ for (let i = 0; i < declarations.length; i++) {
5431
+ const cssProperty = declarations.item(i);
5023
5432
  if (!cssProperty.startsWith("--")) continue;
5024
- found(cssProperty, cssRule.rule.style.getPropertyValue(cssProperty), cssRule.layers, isNested);
5433
+ found(cssProperty, declarations.getPropertyValue(cssProperty), cssRule.layers, isNested);
5025
5434
  }
5026
5435
  }
5027
5436
  }
@@ -5031,9 +5440,18 @@ function searchCustomProperty(scope, found) {
5031
5440
  }
5032
5441
  }
5033
5442
  /**
5034
- * Get repeat-min-inline-size variant definitions from document
5443
+ * Get repeat-min-inline-size variant definitions from document. Uses the
5444
+ * same detection rules as `getCustomProperties`, except that empty values
5445
+ * are not filtered out.
5446
+ *
5447
+ * Inside the editor, call `engine.getRepeatMinInlineSizeVariants()` instead.
5035
5448
  * @param scope - Document to scan for `--bge-repeat-min-inline-size` variants
5036
5449
  * @returns Category containing variant properties, or `null` if no variants found
5450
+ * @example
5451
+ * ```ts
5452
+ * const presets = getRepeatMinInlineSizeVariants(document);
5453
+ * const keys = presets ? [...presets.properties.keys()] : []; // ['small', 'medium', 'large']
5454
+ * ```
5037
5455
  */
5038
5456
  function getRepeatMinInlineSizeVariants(scope) {
5039
5457
  const PREFIX = "--bge-repeat-min-inline-size";
@@ -5090,8 +5508,7 @@ function compareCustomPropertyByLayerPriority(a, b) {
5090
5508
  if (comparePriority(a.priority, b.priority) === 1) return a;
5091
5509
  return b;
5092
5510
  }
5093
- //#endregion
5094
- //#region ../core/dist/error/errors.js
5511
+ // ../core/dist/error/errors.js
5095
5512
  var ElementNotFoundError = class extends Error {
5096
5513
  static {
5097
5514
  this.prototype.name = "ElementNotFoundError";
@@ -5113,8 +5530,7 @@ var NoHTMLElementError = class extends Error {
5113
5530
  super(message, rest);
5114
5531
  }
5115
5532
  };
5116
- //#endregion
5117
- //#region ../core/dist/dom-helpers/get-element.js
5533
+ // ../core/dist/dom-helpers/get-element.js
5118
5534
  /**
5119
5535
  * Resolve the engine's root element.
5120
5536
  *
@@ -5135,8 +5551,7 @@ function getElement(target) {
5135
5551
  if (node instanceof HTMLElement) return node;
5136
5552
  throw new NoHTMLElementError(target);
5137
5553
  }
5138
- //#endregion
5139
- //#region ../core/dist/engine/processing-scope.js
5554
+ // ../core/dist/engine/processing-scope.js
5140
5555
  /**
5141
5556
  * Marks `engine.isProcessed` as `true` for the current scope and guarantees
5142
5557
  * it is reset to `false` when the scope exits, including via an exception.
@@ -5158,8 +5573,7 @@ function beginProcessing(engine) {
5158
5573
  engine.isProcessed = false;
5159
5574
  } };
5160
5575
  }
5161
- //#endregion
5162
- //#region ../core/dist/insertion-point.js
5576
+ // ../core/dist/insertion-point.js
5163
5577
  var InsertionPoint = class {
5164
5578
  el;
5165
5579
  #engine;
@@ -5192,8 +5606,7 @@ var InsertionPoint = class {
5192
5606
  };
5193
5607
  }
5194
5608
  };
5195
- //#endregion
5196
- //#region ../core/dist/editable-content.js
5609
+ // ../core/dist/editable-content.js
5197
5610
  /**
5198
5611
  * The engine-side half of an editable area: block restoration,
5199
5612
  * serialization and sanitization of the content container.
@@ -5289,8 +5702,7 @@ var EditableContent = class EditableContent {
5289
5702
  return editableContent;
5290
5703
  }
5291
5704
  };
5292
- //#endregion
5293
- //#region ../core/dist/event/create-bge-event.js
5705
+ // ../core/dist/event/create-bge-event.js
5294
5706
  /**
5295
5707
  *
5296
5708
  * @param type
@@ -5299,8 +5711,7 @@ var EditableContent = class EditableContent {
5299
5711
  function createBgeEvent(type, eventData) {
5300
5712
  return new CustomEvent(type, { detail: eventData });
5301
5713
  }
5302
- //#endregion
5303
- //#region ../core/dist/health-monitor.js
5714
+ // ../core/dist/health-monitor.js
5304
5715
  /**
5305
5716
  * Monitors server health status and notifies offline/online state changes via events
5306
5717
  */
@@ -5427,8 +5838,30 @@ var HealthMonitor = class {
5427
5838
  }
5428
5839
  }
5429
5840
  };
5430
- //#endregion
5431
- //#region ../core/dist/engine/copy-editable-area.js
5841
+ // ../core/dist/item/normalize-item-html.js
5842
+ /**
5843
+ * Apply a seed's `normalizeItemData` to an item's HTML that was written as HTML
5844
+ * (source mode, an agent's raw block HTML) rather than through item data. The
5845
+ * item's data is read back, normalized and rendered again only when the seed
5846
+ * changes it; an item that needs nothing, or whose seed has no
5847
+ * `normalizeItemData`, keeps the markup as written (and is not even read back).
5848
+ * @param html - The item's inner HTML (the content of `[data-bgi]`)
5849
+ * @param seed - The item definition (`null` / `undefined` for an item that is not defined)
5850
+ * @param config - The editor config
5851
+ * @returns The new inner HTML, or `null` when nothing changed
5852
+ * @example
5853
+ * ```ts
5854
+ * const next = normalizeItemHtml(wrapper.innerHTML, items.image, config);
5855
+ * if (next !== null) wrapper.innerHTML = next;
5856
+ * ```
5857
+ */
5858
+ function normalizeItemHtml(html, seed, config) {
5859
+ if (!seed?.normalizeItemData) return null;
5860
+ const data = dataFromHtml(html);
5861
+ const normalized = normalizeItemData(seed, data, config);
5862
+ return normalized === data ? null : dataToHtml(html, normalized);
5863
+ }
5864
+ // ../core/dist/engine/copy-editable-area.js
5432
5865
  /**
5433
5866
  * 編集エリア間のコンテンツコピー(下書き⇄本稿)を安全に実行する
5434
5867
  *
@@ -5445,8 +5878,7 @@ async function copyEditableArea(source, destination, confirm) {
5445
5878
  await source.copyTo(destination);
5446
5879
  return true;
5447
5880
  }
5448
- //#endregion
5449
- //#region ../core/dist/engine/default-view.js
5881
+ // ../core/dist/engine/default-view.js
5450
5882
  /**
5451
5883
  * Headless fallback used when `BurgerEditorEngineOptions.view` is not
5452
5884
  * provided: each area is a bare `div` appended to the engine's view
@@ -5480,8 +5912,7 @@ function createDefaultView() {
5480
5912
  [Symbol.dispose]: teardown
5481
5913
  };
5482
5914
  }
5483
- //#endregion
5484
- //#region ../core/dist/engine/live-block-ops.js
5915
+ // ../core/dist/engine/live-block-ops.js
5485
5916
  /** Thrown when an `insert` op's block can't be added because it's disabled — the live-DOM twin of `engine.addBlock`'s `alert()` path, converted to a catchable error instead. */
5486
5917
  var DisabledBlockError = class extends Error {
5487
5918
  constructor(message) {
@@ -5682,8 +6113,7 @@ async function applyLiveBlockOp(engine, content, op, options = {}) {
5682
6113
  }
5683
6114
  }
5684
6115
  }
5685
- //#endregion
5686
- //#region ../core/dist/engine/ui-state.js
6116
+ // ../core/dist/engine/ui-state.js
5687
6117
  /**
5688
6118
  * External store for UI state, shaped for `useSyncExternalStore`:
5689
6119
  * `subscribe` registers an invalidation callback and `getSnapshot`
@@ -5827,8 +6257,7 @@ var UIStateStore = class {
5827
6257
  for (const listener of this.#listeners) listener();
5828
6258
  }
5829
6259
  };
5830
- //#endregion
5831
- //#region ../core/dist/engine/engine.js
6260
+ // ../core/dist/engine/engine.js
5832
6261
  var BurgerEditorEngine = class BurgerEditorEngine {
5833
6262
  catalog;
5834
6263
  commandBus = new CommandBus();
@@ -5944,7 +6373,8 @@ var BurgerEditorEngine = class BurgerEditorEngine {
5944
6373
  }
5945
6374
  /**
5946
6375
  * Replace an editable area's content with hand-edited HTML source and
5947
- * save. Used when leaving HTML-source editing mode, or whenever the UI
6376
+ * save. Each item's `normalizeItemData` is applied to what was written (an
6377
+ * image's second `<source>` never keeps an empty `media`, for example). Used when leaving HTML-source editing mode, or whenever the UI
5948
6378
  * layer wants to commit an in-progress edit (e.g. the source textarea
5949
6379
  * losing focus). A no-op when the area doesn't exist (e.g. no draft).
5950
6380
  * @param type - The editable area to commit into
@@ -5958,6 +6388,12 @@ var BurgerEditorEngine = class BurgerEditorEngine {
5958
6388
  const content = this.getEditableContent(type);
5959
6389
  if (!content) return;
5960
6390
  await content.replaceContents(html);
6391
+ for (const el of content.containerElement.querySelectorAll("[data-bgi]")) {
6392
+ const item = Item.getInstance(el);
6393
+ if (!item) continue;
6394
+ const html = normalizeItemHtml(item.el.innerHTML, item.seed, this.config);
6395
+ if (html !== null) item.el.innerHTML = html;
6396
+ }
5961
6397
  this.save();
5962
6398
  }
5963
6399
  /**
@@ -6010,6 +6446,29 @@ var BurgerEditorEngine = class BurgerEditorEngine {
6010
6446
  if (!currentBlock) console.warn("block is unselected.");
6011
6447
  return currentBlock;
6012
6448
  }
6449
+ /**
6450
+ * List the block style options (`--bge-options-{category}--{key}`)
6451
+ * declared on `[data-bge-container]` in the stylesheets loaded into the
6452
+ * current editable area's document. This is what the block options
6453
+ * dialog renders as its style-option selects.
6454
+ *
6455
+ * The stylesheets are scanned on every call (no caching), so the result
6456
+ * reflects whatever is loaded at that moment. Detection rules (traversed
6457
+ * at-rules, layer priority, empty-value exclusion, default resolution)
6458
+ * are documented in
6459
+ * `dom-helpers/get-custom-properties.ts`.
6460
+ * @param containerType - Also include categories prefixed `_{containerType}_`
6461
+ * (e.g. `_grid_subgrid-gap` for `'grid'`); without it they are omitted
6462
+ * @returns Map keyed by category id; each category's `properties` maps
6463
+ * the key to its resolved `value` and whether it is the CSS default
6464
+ * @example
6465
+ * ```ts
6466
+ * for (const [id, category] of engine.getCustomProperties('grid')) {
6467
+ * const keys = [...category.properties.keys()];
6468
+ * console.log(id, category.name, keys); // '_grid_subgrid-gap' 'subgrid-gap' [...]
6469
+ * }
6470
+ * ```
6471
+ */
6013
6472
  getCustomProperties(containerType) {
6014
6473
  return getCustomProperties(this.#current.containerElement.ownerDocument, containerType);
6015
6474
  }
@@ -6061,6 +6520,27 @@ var BurgerEditorEngine = class BurgerEditorEngine {
6061
6520
  getLiveBlocks() {
6062
6521
  return listLiveBlocks(this.#current);
6063
6522
  }
6523
+ /**
6524
+ * List the grid wrap-width presets (`--bge-repeat-min-inline-size--{key}`)
6525
+ * declared on `[data-bge-container]` in the current editable area's
6526
+ * document, used for the auto-fit / auto-fill "wrap width" select.
6527
+ *
6528
+ * Uses the same detection rules as {@link getCustomProperties}, except
6529
+ * that empty values are not filtered out. The default is the key
6530
+ * referenced by `--bge-repeat-min-inline-size: var(...)`. Each preset
6531
+ * also needs a selector rule in CSS that maps the container's
6532
+ * `--{key}` option to the variable; `general.css` ships it only for
6533
+ * `small` / `medium` / `large`.
6534
+ * @returns The preset category (id `'repeat-min-inline-size'`), or `null`
6535
+ * when no preset is declared
6536
+ * @example
6537
+ * ```ts
6538
+ * const presets = engine.getRepeatMinInlineSizeVariants();
6539
+ * const defaultKey = presets
6540
+ * ? [...presets.properties].find(([, p]) => p.isDefault)?.[0]
6541
+ * : undefined; // 'medium' with the bundled general.css
6542
+ * ```
6543
+ */
6064
6544
  getRepeatMinInlineSizeVariants() {
6065
6545
  return getRepeatMinInlineSizeVariants(this.#current.containerElement.ownerDocument);
6066
6546
  }
@@ -6196,34 +6676,23 @@ var BurgerEditorEngine = class BurgerEditorEngine {
6196
6676
  }
6197
6677
  }
6198
6678
  static async #finishConstruction(engine, options) {
6199
- const layers = createStylesheet(`@layer ${CSS_LAYER.base}, ${CSS_LAYER.components}, ${CSS_LAYER.ui};`);
6200
- engine.#disposables.defer(() => {
6201
- URL.revokeObjectURL(layers);
6202
- });
6203
- const baseStylesheet = createComponentStylesheet(options.items, options.generalCSS, CSS_LAYER.base);
6204
- engine.#disposables.defer(() => {
6205
- URL.revokeObjectURL(baseStylesheet);
6206
- });
6207
- const componentStylesheets = await Promise.all(options.config.stylesheets.map(async (stylesheet) => {
6208
- return createStylesheetFromUrl(stylesheet.path, stylesheet.layer ?? CSS_LAYER.components);
6679
+ const createDisposableStylesheet = (css, id) => {
6680
+ const path = createStylesheet(css);
6681
+ engine.#disposables.defer(() => {
6682
+ URL.revokeObjectURL(path);
6683
+ });
6684
+ return {
6685
+ path,
6686
+ id
6687
+ };
6688
+ };
6689
+ const [layerOrderCss, baseCss] = editorBaseStylesheetTexts(options.items, options.generalCSS);
6690
+ const baseStylesheets = [createDisposableStylesheet(layerOrderCss, "layers"), createDisposableStylesheet(baseCss, "base-stylesheet")];
6691
+ const cssContents = await Promise.all(options.config.stylesheets.map(async (stylesheet) => {
6692
+ return (await fetch(stylesheet.path)).text();
6209
6693
  }));
6210
- for (const { blob } of componentStylesheets) engine.#disposables.defer(() => {
6211
- URL.revokeObjectURL(blob);
6212
- });
6213
- const stylesheets = [
6214
- {
6215
- path: layers,
6216
- id: "layers"
6217
- },
6218
- {
6219
- path: baseStylesheet,
6220
- id: "base-stylesheet"
6221
- },
6222
- ...componentStylesheets.map(({ blob, originalUrl }) => ({
6223
- path: blob,
6224
- id: originalUrl
6225
- }))
6226
- ];
6694
+ const componentStylesheets = options.config.stylesheets.map((stylesheet, index) => createDisposableStylesheet(editorProjectStylesheetText(cssContents[index], stylesheet.layer), stylesheet.path));
6695
+ const stylesheets = [...baseStylesheets, ...componentStylesheets];
6227
6696
  const mainInitialContent = typeof options.initialContents === "string" ? options.initialContents : options.initialContents.main;
6228
6697
  engine.#view = options.view ?? createDefaultView();
6229
6698
  engine.#disposables.use(engine.#view);
@@ -6262,8 +6731,7 @@ var BurgerEditorEngine = class BurgerEditorEngine {
6262
6731
  return engine;
6263
6732
  }
6264
6733
  };
6265
- //#endregion
6266
- //#region ../core/dist/dom-helpers/get-css-property-as-number.js
6734
+ // ../core/dist/dom-helpers/get-css-property-as-number.js
6267
6735
  var getCSSPropertyAsNumberCache = /* @__PURE__ */ new Map();
6268
6736
  /**
6269
6737
  *
@@ -6280,8 +6748,7 @@ function getCSSPropertyAsNumber(el, property) {
6280
6748
  getCSSPropertyAsNumberCache.set(value, result);
6281
6749
  return result;
6282
6750
  }
6283
- //#endregion
6284
- //#region ../core/dist/get-block-at-position.js
6751
+ // ../core/dist/get-block-at-position.js
6285
6752
  /**
6286
6753
  *
6287
6754
  * @param doc
@@ -6301,13 +6768,11 @@ function getBlockAtPosition(doc, x, y) {
6301
6768
  }
6302
6769
  return null;
6303
6770
  }
6304
- //#endregion
6305
- //#region __vite-browser-external
6771
+ // __vite-browser-external
6306
6772
  var require___vite_browser_external = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6307
6773
  module.exports = {};
6308
6774
  }));
6309
- //#endregion
6310
- //#region ../../../node_modules/kind-of/index.js
6775
+ // ../../../node_modules/kind-of/index.js
6311
6776
  var require_kind_of = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6312
6777
  var toString = Object.prototype.toString;
6313
6778
  module.exports = function kindOf(val) {
@@ -6394,8 +6859,7 @@ var require_kind_of = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6394
6859
  return false;
6395
6860
  }
6396
6861
  }));
6397
- //#endregion
6398
- //#region ../../../node_modules/is-extendable/index.js
6862
+ // ../../../node_modules/is-extendable/index.js
6399
6863
  /*!
6400
6864
  * is-extendable <https://github.com/jonschlinkert/is-extendable>
6401
6865
  *
@@ -6407,8 +6871,7 @@ var require_is_extendable = /* @__PURE__ */ __commonJSMin(((exports, module) =>
6407
6871
  return typeof val !== "undefined" && val !== null && (typeof val === "object" || typeof val === "function");
6408
6872
  };
6409
6873
  }));
6410
- //#endregion
6411
- //#region ../../../node_modules/extend-shallow/index.js
6874
+ // ../../../node_modules/extend-shallow/index.js
6412
6875
  var require_extend_shallow = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6413
6876
  var isObject = require_is_extendable();
6414
6877
  module.exports = function extend(o) {
@@ -6430,8 +6893,7 @@ var require_extend_shallow = /* @__PURE__ */ __commonJSMin(((exports, module) =>
6430
6893
  return Object.prototype.hasOwnProperty.call(obj, key);
6431
6894
  }
6432
6895
  }));
6433
- //#endregion
6434
- //#region ../../../node_modules/section-matter/index.js
6896
+ // ../../../node_modules/section-matter/index.js
6435
6897
  var require_section_matter = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6436
6898
  var typeOf = require_kind_of();
6437
6899
  var extend = require_extend_shallow();
@@ -6534,8 +6996,7 @@ var require_section_matter = /* @__PURE__ */ __commonJSMin(((exports, module) =>
6534
6996
  return false;
6535
6997
  }
6536
6998
  }));
6537
- //#endregion
6538
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/common.js
6999
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/common.js
6539
7000
  var require_common = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6540
7001
  function isNothing(subject) {
6541
7002
  return typeof subject === "undefined" || subject === null;
@@ -6574,8 +7035,7 @@ var require_common = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6574
7035
  module.exports.isNegativeZero = isNegativeZero;
6575
7036
  module.exports.extend = extend;
6576
7037
  }));
6577
- //#endregion
6578
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/exception.js
7038
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/exception.js
6579
7039
  var require_exception = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6580
7040
  function YAMLException(reason, mark) {
6581
7041
  Error.call(this);
@@ -6596,8 +7056,7 @@ var require_exception = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6596
7056
  };
6597
7057
  module.exports = YAMLException;
6598
7058
  }));
6599
- //#endregion
6600
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/mark.js
7059
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/mark.js
6601
7060
  var require_mark = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6602
7061
  var common = require_common();
6603
7062
  function Mark(name, buffer, position, line, column) {
@@ -6647,8 +7106,7 @@ var require_mark = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6647
7106
  };
6648
7107
  module.exports = Mark;
6649
7108
  }));
6650
- //#endregion
6651
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type.js
7109
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type.js
6652
7110
  var require_type = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6653
7111
  var YAMLException = require_exception();
6654
7112
  var TYPE_CONSTRUCTOR_OPTIONS = [
@@ -6697,8 +7155,7 @@ var require_type = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6697
7155
  }
6698
7156
  module.exports = Type;
6699
7157
  }));
6700
- //#endregion
6701
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema.js
7158
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema.js
6702
7159
  var require_schema = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6703
7160
  var common = require_common();
6704
7161
  var YAMLException = require_exception();
@@ -6771,8 +7228,7 @@ var require_schema = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6771
7228
  };
6772
7229
  module.exports = Schema;
6773
7230
  }));
6774
- //#endregion
6775
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/str.js
7231
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/str.js
6776
7232
  var require_str = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6777
7233
  module.exports = new (require_type())("tag:yaml.org,2002:str", {
6778
7234
  kind: "scalar",
@@ -6781,8 +7237,7 @@ var require_str = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6781
7237
  }
6782
7238
  });
6783
7239
  }));
6784
- //#endregion
6785
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/seq.js
7240
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/seq.js
6786
7241
  var require_seq = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6787
7242
  module.exports = new (require_type())("tag:yaml.org,2002:seq", {
6788
7243
  kind: "sequence",
@@ -6791,8 +7246,7 @@ var require_seq = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6791
7246
  }
6792
7247
  });
6793
7248
  }));
6794
- //#endregion
6795
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/map.js
7249
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/map.js
6796
7250
  var require_map = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6797
7251
  module.exports = new (require_type())("tag:yaml.org,2002:map", {
6798
7252
  kind: "mapping",
@@ -6801,8 +7255,7 @@ var require_map = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6801
7255
  }
6802
7256
  });
6803
7257
  }));
6804
- //#endregion
6805
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/failsafe.js
7258
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/failsafe.js
6806
7259
  var require_failsafe = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6807
7260
  module.exports = new (require_schema())({ explicit: [
6808
7261
  require_str(),
@@ -6810,8 +7263,7 @@ var require_failsafe = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6810
7263
  require_map()
6811
7264
  ] });
6812
7265
  }));
6813
- //#endregion
6814
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/null.js
7266
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/null.js
6815
7267
  var require_null = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6816
7268
  var Type = require_type();
6817
7269
  function resolveYamlNull(data) {
@@ -6847,8 +7299,7 @@ var require_null = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6847
7299
  defaultStyle: "lowercase"
6848
7300
  });
6849
7301
  }));
6850
- //#endregion
6851
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/bool.js
7302
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/bool.js
6852
7303
  var require_bool = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6853
7304
  var Type = require_type();
6854
7305
  function resolveYamlBoolean(data) {
@@ -6881,8 +7332,7 @@ var require_bool = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6881
7332
  defaultStyle: "lowercase"
6882
7333
  });
6883
7334
  }));
6884
- //#endregion
6885
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/int.js
7335
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/int.js
6886
7336
  var require_int = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6887
7337
  var common = require_common();
6888
7338
  var Type = require_type();
@@ -7004,8 +7454,7 @@ var require_int = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7004
7454
  }
7005
7455
  });
7006
7456
  }));
7007
- //#endregion
7008
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/float.js
7457
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/float.js
7009
7458
  var require_float = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7010
7459
  var common = require_common();
7011
7460
  var Type = require_type();
@@ -7068,8 +7517,7 @@ var require_float = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7068
7517
  defaultStyle: "lowercase"
7069
7518
  });
7070
7519
  }));
7071
- //#endregion
7072
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/json.js
7520
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/json.js
7073
7521
  var require_json = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7074
7522
  module.exports = new (require_schema())({
7075
7523
  include: [require_failsafe()],
@@ -7081,13 +7529,11 @@ var require_json = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7081
7529
  ]
7082
7530
  });
7083
7531
  }));
7084
- //#endregion
7085
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/core.js
7532
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/core.js
7086
7533
  var require_core = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7087
7534
  module.exports = new (require_schema())({ include: [require_json()] });
7088
7535
  }));
7089
- //#endregion
7090
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/timestamp.js
7536
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/timestamp.js
7091
7537
  var require_timestamp = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7092
7538
  var Type = require_type();
7093
7539
  var YAML_DATE_REGEXP = /* @__PURE__ */ new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$");
@@ -7136,8 +7582,7 @@ var require_timestamp = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7136
7582
  represent: representYamlTimestamp
7137
7583
  });
7138
7584
  }));
7139
- //#endregion
7140
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/merge.js
7585
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/merge.js
7141
7586
  var require_merge = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7142
7587
  var Type = require_type();
7143
7588
  function resolveYamlMerge(data) {
@@ -7148,8 +7593,7 @@ var require_merge = /* @__PURE__ */ __commonJSMin(((exports, module) => {
7148
7593
  resolve: resolveYamlMerge
7149
7594
  });
7150
7595
  }));
7151
- //#endregion
7152
- //#region ../../../node_modules/base64-js/index.js
7596
+ // ../../../node_modules/base64-js/index.js
7153
7597
  var require_base64_js = /* @__PURE__ */ __commonJSMin(((exports) => {
7154
7598
  exports.byteLength = byteLength;
7155
7599
  exports.toByteArray = toByteArray;
@@ -7236,8 +7680,7 @@ var require_base64_js = /* @__PURE__ */ __commonJSMin(((exports) => {
7236
7680
  return parts.join("");
7237
7681
  }
7238
7682
  }));
7239
- //#endregion
7240
- //#region ../../../node_modules/ieee754/index.js
7683
+ // ../../../node_modules/ieee754/index.js
7241
7684
  var require_ieee754 = /* @__PURE__ */ __commonJSMin(((exports) => {
7242
7685
  /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
7243
7686
  exports.read = function(buffer, offset, isLE, mLen, nBytes) {
@@ -7309,8 +7752,7 @@ var require_ieee754 = /* @__PURE__ */ __commonJSMin(((exports) => {
7309
7752
  buffer[offset + i - d] |= s * 128;
7310
7753
  };
7311
7754
  }));
7312
- //#endregion
7313
- //#region ../../../node_modules/buffer/index.js
7755
+ // ../../../node_modules/buffer/index.js
7314
7756
  /*!
7315
7757
  * The buffer module from node.js, for the browser.
7316
7758
  *
@@ -8420,8 +8862,7 @@ var require_buffer = /* @__PURE__ */ __commonJSMin(((exports) => {
8420
8862
  return table;
8421
8863
  })();
8422
8864
  }));
8423
- //#endregion
8424
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/binary.js
8865
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/binary.js
8425
8866
  var require_binary = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8426
8867
  var NodeBuffer;
8427
8868
  try {
@@ -8503,15 +8944,14 @@ var require_binary = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8503
8944
  represent: representYamlBinary
8504
8945
  });
8505
8946
  }));
8506
- //#endregion
8507
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/omap.js
8947
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/omap.js
8508
8948
  var require_omap = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8509
8949
  var Type = require_type();
8510
8950
  var _hasOwnProperty = Object.prototype.hasOwnProperty;
8511
8951
  var _toString = Object.prototype.toString;
8512
8952
  function resolveYamlOmap(data) {
8513
8953
  if (data === null) return true;
8514
- var objectKeys = [], index, length, pair, pairKey, pairHasKey, object = data;
8954
+ var objectKeys = {}, index, length, pair, pairKey, pairHasKey, object = data;
8515
8955
  for (index = 0, length = object.length; index < length; index += 1) {
8516
8956
  pair = object[index];
8517
8957
  pairHasKey = false;
@@ -8521,8 +8961,8 @@ var require_omap = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8521
8961
  else return false;
8522
8962
  }
8523
8963
  if (!pairHasKey) return false;
8524
- if (objectKeys.indexOf(pairKey) === -1) objectKeys.push(pairKey);
8525
- else return false;
8964
+ if (_hasOwnProperty.call(objectKeys, pairKey)) return false;
8965
+ Object.defineProperty(objectKeys, pairKey, { value: true });
8526
8966
  }
8527
8967
  return true;
8528
8968
  }
@@ -8535,8 +8975,7 @@ var require_omap = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8535
8975
  construct: constructYamlOmap
8536
8976
  });
8537
8977
  }));
8538
- //#endregion
8539
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/pairs.js
8978
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/pairs.js
8540
8979
  var require_pairs = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8541
8980
  var Type = require_type();
8542
8981
  var _toString = Object.prototype.toString;
@@ -8570,8 +9009,7 @@ var require_pairs = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8570
9009
  construct: constructYamlPairs
8571
9010
  });
8572
9011
  }));
8573
- //#endregion
8574
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/set.js
9012
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/set.js
8575
9013
  var require_set = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8576
9014
  var Type = require_type();
8577
9015
  var _hasOwnProperty = Object.prototype.hasOwnProperty;
@@ -8592,8 +9030,7 @@ var require_set = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8592
9030
  construct: constructYamlSet
8593
9031
  });
8594
9032
  }));
8595
- //#endregion
8596
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/default_safe.js
9033
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/default_safe.js
8597
9034
  var require_default_safe = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8598
9035
  module.exports = new (require_schema())({
8599
9036
  include: [require_core()],
@@ -8606,8 +9043,7 @@ var require_default_safe = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8606
9043
  ]
8607
9044
  });
8608
9045
  }));
8609
- //#endregion
8610
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/js/undefined.js
9046
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/js/undefined.js
8611
9047
  var require_undefined = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8612
9048
  var Type = require_type();
8613
9049
  function resolveJavascriptUndefined() {
@@ -8628,8 +9064,7 @@ var require_undefined = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8628
9064
  represent: representJavascriptUndefined
8629
9065
  });
8630
9066
  }));
8631
- //#endregion
8632
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/js/regexp.js
9067
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/js/regexp.js
8633
9068
  var require_regexp = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8634
9069
  var Type = require_type();
8635
9070
  function resolveJavascriptRegExp(data) {
@@ -8669,38 +9104,37 @@ var require_regexp = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8669
9104
  represent: representJavascriptRegExp
8670
9105
  });
8671
9106
  }));
8672
- //#endregion
8673
- //#region ../../../node_modules/esprima/dist/esprima.js
8674
- var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9107
+ // ../../../node_modules/esprima/dist/esprima.js
9108
+ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module, this$1) => {
8675
9109
  (function webpackUniversalModuleDefinition(root, factory) {
8676
9110
  /* istanbul ignore next */
8677
9111
  if (typeof exports === "object" && typeof module === "object") module.exports = factory();
8678
9112
  else if (typeof define === "function" && define.amd) define([], factory);
8679
9113
  else if (typeof exports === "object") exports["esprima"] = factory();
8680
9114
  else root["esprima"] = factory();
8681
- })(exports, function() {
9115
+ })(this$1, function() {
8682
9116
  return (function(modules) {
8683
9117
  var installedModules = {};
8684
9118
  function __webpack_require__(moduleId) {
8685
9119
  /* istanbul ignore if */
8686
9120
  if (installedModules[moduleId]) return installedModules[moduleId].exports;
8687
- var module$1 = installedModules[moduleId] = {
9121
+ var module = installedModules[moduleId] = {
8688
9122
  exports: {},
8689
9123
  id: moduleId,
8690
9124
  loaded: false
8691
9125
  };
8692
- modules[moduleId].call(module$1.exports, module$1, module$1.exports, __webpack_require__);
8693
- module$1.loaded = true;
8694
- return module$1.exports;
9126
+ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
9127
+ module.loaded = true;
9128
+ return module.exports;
8695
9129
  }
8696
9130
  __webpack_require__.m = modules;
8697
9131
  __webpack_require__.c = installedModules;
8698
9132
  __webpack_require__.p = "";
8699
9133
  return __webpack_require__(0);
8700
9134
  })([
8701
- function(module$2, exports$1, __webpack_require__) {
9135
+ function(module, exports, __webpack_require__) {
8702
9136
  "use strict";
8703
- Object.defineProperty(exports$1, "__esModule", { value: true });
9137
+ Object.defineProperty(exports, "__esModule", { value: true });
8704
9138
  var comment_handler_1 = __webpack_require__(1);
8705
9139
  var jsx_parser_1 = __webpack_require__(3);
8706
9140
  var parser_1 = __webpack_require__(8);
@@ -8734,19 +9168,19 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8734
9168
  if (parser.config.tolerant) ast.errors = parser.errorHandler.errors;
8735
9169
  return ast;
8736
9170
  }
8737
- exports$1.parse = parse;
9171
+ exports.parse = parse;
8738
9172
  function parseModule(code, options, delegate) {
8739
9173
  var parsingOptions = options || {};
8740
9174
  parsingOptions.sourceType = "module";
8741
9175
  return parse(code, parsingOptions, delegate);
8742
9176
  }
8743
- exports$1.parseModule = parseModule;
9177
+ exports.parseModule = parseModule;
8744
9178
  function parseScript(code, options, delegate) {
8745
9179
  var parsingOptions = options || {};
8746
9180
  parsingOptions.sourceType = "script";
8747
9181
  return parse(code, parsingOptions, delegate);
8748
9182
  }
8749
- exports$1.parseScript = parseScript;
9183
+ exports.parseScript = parseScript;
8750
9184
  function tokenize(code, options, delegate) {
8751
9185
  var tokenizer = new tokenizer_1.Tokenizer(code, options);
8752
9186
  var tokens = [];
@@ -8763,15 +9197,15 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8763
9197
  if (tokenizer.errorHandler.tolerant) tokens.errors = tokenizer.errors();
8764
9198
  return tokens;
8765
9199
  }
8766
- exports$1.tokenize = tokenize;
8767
- exports$1.Syntax = __webpack_require__(2).Syntax;
8768
- exports$1.version = "4.0.1";
9200
+ exports.tokenize = tokenize;
9201
+ exports.Syntax = __webpack_require__(2).Syntax;
9202
+ exports.version = "4.0.1";
8769
9203
  },
8770
- function(module$3, exports$2, __webpack_require__) {
9204
+ function(module, exports, __webpack_require__) {
8771
9205
  "use strict";
8772
- Object.defineProperty(exports$2, "__esModule", { value: true });
9206
+ Object.defineProperty(exports, "__esModule", { value: true });
8773
9207
  var syntax_1 = __webpack_require__(2);
8774
- exports$2.CommentHandler = function() {
9208
+ exports.CommentHandler = function() {
8775
9209
  function CommentHandler() {
8776
9210
  this.attach = false;
8777
9211
  this.comments = [];
@@ -8887,10 +9321,10 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8887
9321
  return CommentHandler;
8888
9322
  }();
8889
9323
  },
8890
- function(module$4, exports$3) {
9324
+ function(module, exports) {
8891
9325
  "use strict";
8892
- Object.defineProperty(exports$3, "__esModule", { value: true });
8893
- exports$3.Syntax = {
9326
+ Object.defineProperty(exports, "__esModule", { value: true });
9327
+ exports.Syntax = {
8894
9328
  AssignmentExpression: "AssignmentExpression",
8895
9329
  AssignmentPattern: "AssignmentPattern",
8896
9330
  ArrayExpression: "ArrayExpression",
@@ -8959,7 +9393,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8959
9393
  YieldExpression: "YieldExpression"
8960
9394
  };
8961
9395
  },
8962
- function(module$5, exports$4, __webpack_require__) {
9396
+ function(module, exports, __webpack_require__) {
8963
9397
  "use strict";
8964
9398
  /* istanbul ignore next */
8965
9399
  var __extends = this && this.__extends || (function() {
@@ -8976,7 +9410,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8976
9410
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
8977
9411
  };
8978
9412
  })();
8979
- Object.defineProperty(exports$4, "__esModule", { value: true });
9413
+ Object.defineProperty(exports, "__esModule", { value: true });
8980
9414
  var character_1 = __webpack_require__(4);
8981
9415
  var JSXNode = __webpack_require__(5);
8982
9416
  var jsx_syntax_1 = __webpack_require__(6);
@@ -9002,7 +9436,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9002
9436
  }
9003
9437
  return qualifiedName;
9004
9438
  }
9005
- exports$4.JSXParser = function(_super) {
9439
+ exports.JSXParser = function(_super) {
9006
9440
  __extends(JSXParser, _super);
9007
9441
  function JSXParser(code, options, delegate) {
9008
9442
  return _super.call(this, code, options, delegate) || this;
@@ -9417,14 +9851,14 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9417
9851
  return JSXParser;
9418
9852
  }(parser_1.Parser);
9419
9853
  },
9420
- function(module$6, exports$5) {
9854
+ function(module, exports) {
9421
9855
  "use strict";
9422
- Object.defineProperty(exports$5, "__esModule", { value: true });
9856
+ Object.defineProperty(exports, "__esModule", { value: true });
9423
9857
  var Regex = {
9424
9858
  NonAsciiIdentifierStart: /[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]/,
9425
9859
  NonAsciiIdentifierPart: /[\xAA\xB5\xB7\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B4\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1369-\u1371\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/
9426
9860
  };
9427
- exports$5.Character = {
9861
+ exports.Character = {
9428
9862
  fromCodePoint: function(cp) {
9429
9863
  return cp < 65536 ? String.fromCharCode(cp) : String.fromCharCode(55296 + (cp - 65536 >> 10)) + String.fromCharCode(56320 + (cp - 65536 & 1023));
9430
9864
  },
@@ -9452,10 +9886,10 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9452
9886
  return cp === 10 || cp === 13 || cp === 8232 || cp === 8233;
9453
9887
  },
9454
9888
  isIdentifierStart: function(cp) {
9455
- return cp === 36 || cp === 95 || cp >= 65 && cp <= 90 || cp >= 97 && cp <= 122 || cp === 92 || cp >= 128 && Regex.NonAsciiIdentifierStart.test(exports$5.Character.fromCodePoint(cp));
9889
+ return cp === 36 || cp === 95 || cp >= 65 && cp <= 90 || cp >= 97 && cp <= 122 || cp === 92 || cp >= 128 && Regex.NonAsciiIdentifierStart.test(exports.Character.fromCodePoint(cp));
9456
9890
  },
9457
9891
  isIdentifierPart: function(cp) {
9458
- return cp === 36 || cp === 95 || cp >= 65 && cp <= 90 || cp >= 97 && cp <= 122 || cp >= 48 && cp <= 57 || cp === 92 || cp >= 128 && Regex.NonAsciiIdentifierPart.test(exports$5.Character.fromCodePoint(cp));
9892
+ return cp === 36 || cp === 95 || cp >= 65 && cp <= 90 || cp >= 97 && cp <= 122 || cp >= 48 && cp <= 57 || cp === 92 || cp >= 128 && Regex.NonAsciiIdentifierPart.test(exports.Character.fromCodePoint(cp));
9459
9893
  },
9460
9894
  isDecimalDigit: function(cp) {
9461
9895
  return cp >= 48 && cp <= 57;
@@ -9468,18 +9902,18 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9468
9902
  }
9469
9903
  };
9470
9904
  },
9471
- function(module$7, exports$6, __webpack_require__) {
9905
+ function(module, exports, __webpack_require__) {
9472
9906
  "use strict";
9473
- Object.defineProperty(exports$6, "__esModule", { value: true });
9907
+ Object.defineProperty(exports, "__esModule", { value: true });
9474
9908
  var jsx_syntax_1 = __webpack_require__(6);
9475
- exports$6.JSXClosingElement = function() {
9909
+ exports.JSXClosingElement = function() {
9476
9910
  function JSXClosingElement(name) {
9477
9911
  this.type = jsx_syntax_1.JSXSyntax.JSXClosingElement;
9478
9912
  this.name = name;
9479
9913
  }
9480
9914
  return JSXClosingElement;
9481
9915
  }();
9482
- exports$6.JSXElement = function() {
9916
+ exports.JSXElement = function() {
9483
9917
  function JSXElement(openingElement, children, closingElement) {
9484
9918
  this.type = jsx_syntax_1.JSXSyntax.JSXElement;
9485
9919
  this.openingElement = openingElement;
@@ -9488,27 +9922,27 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9488
9922
  }
9489
9923
  return JSXElement;
9490
9924
  }();
9491
- exports$6.JSXEmptyExpression = function() {
9925
+ exports.JSXEmptyExpression = function() {
9492
9926
  function JSXEmptyExpression() {
9493
9927
  this.type = jsx_syntax_1.JSXSyntax.JSXEmptyExpression;
9494
9928
  }
9495
9929
  return JSXEmptyExpression;
9496
9930
  }();
9497
- exports$6.JSXExpressionContainer = function() {
9931
+ exports.JSXExpressionContainer = function() {
9498
9932
  function JSXExpressionContainer(expression) {
9499
9933
  this.type = jsx_syntax_1.JSXSyntax.JSXExpressionContainer;
9500
9934
  this.expression = expression;
9501
9935
  }
9502
9936
  return JSXExpressionContainer;
9503
9937
  }();
9504
- exports$6.JSXIdentifier = function() {
9938
+ exports.JSXIdentifier = function() {
9505
9939
  function JSXIdentifier(name) {
9506
9940
  this.type = jsx_syntax_1.JSXSyntax.JSXIdentifier;
9507
9941
  this.name = name;
9508
9942
  }
9509
9943
  return JSXIdentifier;
9510
9944
  }();
9511
- exports$6.JSXMemberExpression = function() {
9945
+ exports.JSXMemberExpression = function() {
9512
9946
  function JSXMemberExpression(object, property) {
9513
9947
  this.type = jsx_syntax_1.JSXSyntax.JSXMemberExpression;
9514
9948
  this.object = object;
@@ -9516,7 +9950,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9516
9950
  }
9517
9951
  return JSXMemberExpression;
9518
9952
  }();
9519
- exports$6.JSXAttribute = function() {
9953
+ exports.JSXAttribute = function() {
9520
9954
  function JSXAttribute(name, value) {
9521
9955
  this.type = jsx_syntax_1.JSXSyntax.JSXAttribute;
9522
9956
  this.name = name;
@@ -9524,7 +9958,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9524
9958
  }
9525
9959
  return JSXAttribute;
9526
9960
  }();
9527
- exports$6.JSXNamespacedName = function() {
9961
+ exports.JSXNamespacedName = function() {
9528
9962
  function JSXNamespacedName(namespace, name) {
9529
9963
  this.type = jsx_syntax_1.JSXSyntax.JSXNamespacedName;
9530
9964
  this.namespace = namespace;
@@ -9532,7 +9966,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9532
9966
  }
9533
9967
  return JSXNamespacedName;
9534
9968
  }();
9535
- exports$6.JSXOpeningElement = function() {
9969
+ exports.JSXOpeningElement = function() {
9536
9970
  function JSXOpeningElement(name, selfClosing, attributes) {
9537
9971
  this.type = jsx_syntax_1.JSXSyntax.JSXOpeningElement;
9538
9972
  this.name = name;
@@ -9541,14 +9975,14 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9541
9975
  }
9542
9976
  return JSXOpeningElement;
9543
9977
  }();
9544
- exports$6.JSXSpreadAttribute = function() {
9978
+ exports.JSXSpreadAttribute = function() {
9545
9979
  function JSXSpreadAttribute(argument) {
9546
9980
  this.type = jsx_syntax_1.JSXSyntax.JSXSpreadAttribute;
9547
9981
  this.argument = argument;
9548
9982
  }
9549
9983
  return JSXSpreadAttribute;
9550
9984
  }();
9551
- exports$6.JSXText = function() {
9985
+ exports.JSXText = function() {
9552
9986
  function JSXText(value, raw) {
9553
9987
  this.type = jsx_syntax_1.JSXSyntax.JSXText;
9554
9988
  this.value = value;
@@ -9557,10 +9991,10 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9557
9991
  return JSXText;
9558
9992
  }();
9559
9993
  },
9560
- function(module$8, exports$7) {
9994
+ function(module, exports) {
9561
9995
  "use strict";
9562
- Object.defineProperty(exports$7, "__esModule", { value: true });
9563
- exports$7.JSXSyntax = {
9996
+ Object.defineProperty(exports, "__esModule", { value: true });
9997
+ exports.JSXSyntax = {
9564
9998
  JSXAttribute: "JSXAttribute",
9565
9999
  JSXClosingElement: "JSXClosingElement",
9566
10000
  JSXElement: "JSXElement",
@@ -9574,25 +10008,25 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9574
10008
  JSXText: "JSXText"
9575
10009
  };
9576
10010
  },
9577
- function(module$9, exports$8, __webpack_require__) {
10011
+ function(module, exports, __webpack_require__) {
9578
10012
  "use strict";
9579
- Object.defineProperty(exports$8, "__esModule", { value: true });
10013
+ Object.defineProperty(exports, "__esModule", { value: true });
9580
10014
  var syntax_1 = __webpack_require__(2);
9581
- exports$8.ArrayExpression = function() {
10015
+ exports.ArrayExpression = function() {
9582
10016
  function ArrayExpression(elements) {
9583
10017
  this.type = syntax_1.Syntax.ArrayExpression;
9584
10018
  this.elements = elements;
9585
10019
  }
9586
10020
  return ArrayExpression;
9587
10021
  }();
9588
- exports$8.ArrayPattern = function() {
10022
+ exports.ArrayPattern = function() {
9589
10023
  function ArrayPattern(elements) {
9590
10024
  this.type = syntax_1.Syntax.ArrayPattern;
9591
10025
  this.elements = elements;
9592
10026
  }
9593
10027
  return ArrayPattern;
9594
10028
  }();
9595
- exports$8.ArrowFunctionExpression = function() {
10029
+ exports.ArrowFunctionExpression = function() {
9596
10030
  function ArrowFunctionExpression(params, body, expression) {
9597
10031
  this.type = syntax_1.Syntax.ArrowFunctionExpression;
9598
10032
  this.id = null;
@@ -9604,7 +10038,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9604
10038
  }
9605
10039
  return ArrowFunctionExpression;
9606
10040
  }();
9607
- exports$8.AssignmentExpression = function() {
10041
+ exports.AssignmentExpression = function() {
9608
10042
  function AssignmentExpression(operator, left, right) {
9609
10043
  this.type = syntax_1.Syntax.AssignmentExpression;
9610
10044
  this.operator = operator;
@@ -9613,7 +10047,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9613
10047
  }
9614
10048
  return AssignmentExpression;
9615
10049
  }();
9616
- exports$8.AssignmentPattern = function() {
10050
+ exports.AssignmentPattern = function() {
9617
10051
  function AssignmentPattern(left, right) {
9618
10052
  this.type = syntax_1.Syntax.AssignmentPattern;
9619
10053
  this.left = left;
@@ -9621,7 +10055,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9621
10055
  }
9622
10056
  return AssignmentPattern;
9623
10057
  }();
9624
- exports$8.AsyncArrowFunctionExpression = function() {
10058
+ exports.AsyncArrowFunctionExpression = function() {
9625
10059
  function AsyncArrowFunctionExpression(params, body, expression) {
9626
10060
  this.type = syntax_1.Syntax.ArrowFunctionExpression;
9627
10061
  this.id = null;
@@ -9633,7 +10067,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9633
10067
  }
9634
10068
  return AsyncArrowFunctionExpression;
9635
10069
  }();
9636
- exports$8.AsyncFunctionDeclaration = function() {
10070
+ exports.AsyncFunctionDeclaration = function() {
9637
10071
  function AsyncFunctionDeclaration(id, params, body) {
9638
10072
  this.type = syntax_1.Syntax.FunctionDeclaration;
9639
10073
  this.id = id;
@@ -9645,7 +10079,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9645
10079
  }
9646
10080
  return AsyncFunctionDeclaration;
9647
10081
  }();
9648
- exports$8.AsyncFunctionExpression = function() {
10082
+ exports.AsyncFunctionExpression = function() {
9649
10083
  function AsyncFunctionExpression(id, params, body) {
9650
10084
  this.type = syntax_1.Syntax.FunctionExpression;
9651
10085
  this.id = id;
@@ -9657,14 +10091,14 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9657
10091
  }
9658
10092
  return AsyncFunctionExpression;
9659
10093
  }();
9660
- exports$8.AwaitExpression = function() {
10094
+ exports.AwaitExpression = function() {
9661
10095
  function AwaitExpression(argument) {
9662
10096
  this.type = syntax_1.Syntax.AwaitExpression;
9663
10097
  this.argument = argument;
9664
10098
  }
9665
10099
  return AwaitExpression;
9666
10100
  }();
9667
- exports$8.BinaryExpression = function() {
10101
+ exports.BinaryExpression = function() {
9668
10102
  function BinaryExpression(operator, left, right) {
9669
10103
  var logical = operator === "||" || operator === "&&";
9670
10104
  this.type = logical ? syntax_1.Syntax.LogicalExpression : syntax_1.Syntax.BinaryExpression;
@@ -9674,21 +10108,21 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9674
10108
  }
9675
10109
  return BinaryExpression;
9676
10110
  }();
9677
- exports$8.BlockStatement = function() {
10111
+ exports.BlockStatement = function() {
9678
10112
  function BlockStatement(body) {
9679
10113
  this.type = syntax_1.Syntax.BlockStatement;
9680
10114
  this.body = body;
9681
10115
  }
9682
10116
  return BlockStatement;
9683
10117
  }();
9684
- exports$8.BreakStatement = function() {
10118
+ exports.BreakStatement = function() {
9685
10119
  function BreakStatement(label) {
9686
10120
  this.type = syntax_1.Syntax.BreakStatement;
9687
10121
  this.label = label;
9688
10122
  }
9689
10123
  return BreakStatement;
9690
10124
  }();
9691
- exports$8.CallExpression = function() {
10125
+ exports.CallExpression = function() {
9692
10126
  function CallExpression(callee, args) {
9693
10127
  this.type = syntax_1.Syntax.CallExpression;
9694
10128
  this.callee = callee;
@@ -9696,7 +10130,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9696
10130
  }
9697
10131
  return CallExpression;
9698
10132
  }();
9699
- exports$8.CatchClause = function() {
10133
+ exports.CatchClause = function() {
9700
10134
  function CatchClause(param, body) {
9701
10135
  this.type = syntax_1.Syntax.CatchClause;
9702
10136
  this.param = param;
@@ -9704,14 +10138,14 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9704
10138
  }
9705
10139
  return CatchClause;
9706
10140
  }();
9707
- exports$8.ClassBody = function() {
10141
+ exports.ClassBody = function() {
9708
10142
  function ClassBody(body) {
9709
10143
  this.type = syntax_1.Syntax.ClassBody;
9710
10144
  this.body = body;
9711
10145
  }
9712
10146
  return ClassBody;
9713
10147
  }();
9714
- exports$8.ClassDeclaration = function() {
10148
+ exports.ClassDeclaration = function() {
9715
10149
  function ClassDeclaration(id, superClass, body) {
9716
10150
  this.type = syntax_1.Syntax.ClassDeclaration;
9717
10151
  this.id = id;
@@ -9720,7 +10154,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9720
10154
  }
9721
10155
  return ClassDeclaration;
9722
10156
  }();
9723
- exports$8.ClassExpression = function() {
10157
+ exports.ClassExpression = function() {
9724
10158
  function ClassExpression(id, superClass, body) {
9725
10159
  this.type = syntax_1.Syntax.ClassExpression;
9726
10160
  this.id = id;
@@ -9729,7 +10163,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9729
10163
  }
9730
10164
  return ClassExpression;
9731
10165
  }();
9732
- exports$8.ComputedMemberExpression = function() {
10166
+ exports.ComputedMemberExpression = function() {
9733
10167
  function ComputedMemberExpression(object, property) {
9734
10168
  this.type = syntax_1.Syntax.MemberExpression;
9735
10169
  this.computed = true;
@@ -9738,7 +10172,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9738
10172
  }
9739
10173
  return ComputedMemberExpression;
9740
10174
  }();
9741
- exports$8.ConditionalExpression = function() {
10175
+ exports.ConditionalExpression = function() {
9742
10176
  function ConditionalExpression(test, consequent, alternate) {
9743
10177
  this.type = syntax_1.Syntax.ConditionalExpression;
9744
10178
  this.test = test;
@@ -9747,20 +10181,20 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9747
10181
  }
9748
10182
  return ConditionalExpression;
9749
10183
  }();
9750
- exports$8.ContinueStatement = function() {
10184
+ exports.ContinueStatement = function() {
9751
10185
  function ContinueStatement(label) {
9752
10186
  this.type = syntax_1.Syntax.ContinueStatement;
9753
10187
  this.label = label;
9754
10188
  }
9755
10189
  return ContinueStatement;
9756
10190
  }();
9757
- exports$8.DebuggerStatement = function() {
10191
+ exports.DebuggerStatement = function() {
9758
10192
  function DebuggerStatement() {
9759
10193
  this.type = syntax_1.Syntax.DebuggerStatement;
9760
10194
  }
9761
10195
  return DebuggerStatement;
9762
10196
  }();
9763
- exports$8.Directive = function() {
10197
+ exports.Directive = function() {
9764
10198
  function Directive(expression, directive) {
9765
10199
  this.type = syntax_1.Syntax.ExpressionStatement;
9766
10200
  this.expression = expression;
@@ -9768,7 +10202,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9768
10202
  }
9769
10203
  return Directive;
9770
10204
  }();
9771
- exports$8.DoWhileStatement = function() {
10205
+ exports.DoWhileStatement = function() {
9772
10206
  function DoWhileStatement(body, test) {
9773
10207
  this.type = syntax_1.Syntax.DoWhileStatement;
9774
10208
  this.body = body;
@@ -9776,27 +10210,27 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9776
10210
  }
9777
10211
  return DoWhileStatement;
9778
10212
  }();
9779
- exports$8.EmptyStatement = function() {
10213
+ exports.EmptyStatement = function() {
9780
10214
  function EmptyStatement() {
9781
10215
  this.type = syntax_1.Syntax.EmptyStatement;
9782
10216
  }
9783
10217
  return EmptyStatement;
9784
10218
  }();
9785
- exports$8.ExportAllDeclaration = function() {
10219
+ exports.ExportAllDeclaration = function() {
9786
10220
  function ExportAllDeclaration(source) {
9787
10221
  this.type = syntax_1.Syntax.ExportAllDeclaration;
9788
10222
  this.source = source;
9789
10223
  }
9790
10224
  return ExportAllDeclaration;
9791
10225
  }();
9792
- exports$8.ExportDefaultDeclaration = function() {
10226
+ exports.ExportDefaultDeclaration = function() {
9793
10227
  function ExportDefaultDeclaration(declaration) {
9794
10228
  this.type = syntax_1.Syntax.ExportDefaultDeclaration;
9795
10229
  this.declaration = declaration;
9796
10230
  }
9797
10231
  return ExportDefaultDeclaration;
9798
10232
  }();
9799
- exports$8.ExportNamedDeclaration = function() {
10233
+ exports.ExportNamedDeclaration = function() {
9800
10234
  function ExportNamedDeclaration(declaration, specifiers, source) {
9801
10235
  this.type = syntax_1.Syntax.ExportNamedDeclaration;
9802
10236
  this.declaration = declaration;
@@ -9805,7 +10239,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9805
10239
  }
9806
10240
  return ExportNamedDeclaration;
9807
10241
  }();
9808
- exports$8.ExportSpecifier = function() {
10242
+ exports.ExportSpecifier = function() {
9809
10243
  function ExportSpecifier(local, exported) {
9810
10244
  this.type = syntax_1.Syntax.ExportSpecifier;
9811
10245
  this.exported = exported;
@@ -9813,14 +10247,14 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9813
10247
  }
9814
10248
  return ExportSpecifier;
9815
10249
  }();
9816
- exports$8.ExpressionStatement = function() {
10250
+ exports.ExpressionStatement = function() {
9817
10251
  function ExpressionStatement(expression) {
9818
10252
  this.type = syntax_1.Syntax.ExpressionStatement;
9819
10253
  this.expression = expression;
9820
10254
  }
9821
10255
  return ExpressionStatement;
9822
10256
  }();
9823
- exports$8.ForInStatement = function() {
10257
+ exports.ForInStatement = function() {
9824
10258
  function ForInStatement(left, right, body) {
9825
10259
  this.type = syntax_1.Syntax.ForInStatement;
9826
10260
  this.left = left;
@@ -9830,7 +10264,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9830
10264
  }
9831
10265
  return ForInStatement;
9832
10266
  }();
9833
- exports$8.ForOfStatement = function() {
10267
+ exports.ForOfStatement = function() {
9834
10268
  function ForOfStatement(left, right, body) {
9835
10269
  this.type = syntax_1.Syntax.ForOfStatement;
9836
10270
  this.left = left;
@@ -9839,7 +10273,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9839
10273
  }
9840
10274
  return ForOfStatement;
9841
10275
  }();
9842
- exports$8.ForStatement = function() {
10276
+ exports.ForStatement = function() {
9843
10277
  function ForStatement(init, test, update, body) {
9844
10278
  this.type = syntax_1.Syntax.ForStatement;
9845
10279
  this.init = init;
@@ -9849,7 +10283,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9849
10283
  }
9850
10284
  return ForStatement;
9851
10285
  }();
9852
- exports$8.FunctionDeclaration = function() {
10286
+ exports.FunctionDeclaration = function() {
9853
10287
  function FunctionDeclaration(id, params, body, generator) {
9854
10288
  this.type = syntax_1.Syntax.FunctionDeclaration;
9855
10289
  this.id = id;
@@ -9861,7 +10295,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9861
10295
  }
9862
10296
  return FunctionDeclaration;
9863
10297
  }();
9864
- exports$8.FunctionExpression = function() {
10298
+ exports.FunctionExpression = function() {
9865
10299
  function FunctionExpression(id, params, body, generator) {
9866
10300
  this.type = syntax_1.Syntax.FunctionExpression;
9867
10301
  this.id = id;
@@ -9873,14 +10307,14 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9873
10307
  }
9874
10308
  return FunctionExpression;
9875
10309
  }();
9876
- exports$8.Identifier = function() {
10310
+ exports.Identifier = function() {
9877
10311
  function Identifier(name) {
9878
10312
  this.type = syntax_1.Syntax.Identifier;
9879
10313
  this.name = name;
9880
10314
  }
9881
10315
  return Identifier;
9882
10316
  }();
9883
- exports$8.IfStatement = function() {
10317
+ exports.IfStatement = function() {
9884
10318
  function IfStatement(test, consequent, alternate) {
9885
10319
  this.type = syntax_1.Syntax.IfStatement;
9886
10320
  this.test = test;
@@ -9889,7 +10323,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9889
10323
  }
9890
10324
  return IfStatement;
9891
10325
  }();
9892
- exports$8.ImportDeclaration = function() {
10326
+ exports.ImportDeclaration = function() {
9893
10327
  function ImportDeclaration(specifiers, source) {
9894
10328
  this.type = syntax_1.Syntax.ImportDeclaration;
9895
10329
  this.specifiers = specifiers;
@@ -9897,21 +10331,21 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9897
10331
  }
9898
10332
  return ImportDeclaration;
9899
10333
  }();
9900
- exports$8.ImportDefaultSpecifier = function() {
10334
+ exports.ImportDefaultSpecifier = function() {
9901
10335
  function ImportDefaultSpecifier(local) {
9902
10336
  this.type = syntax_1.Syntax.ImportDefaultSpecifier;
9903
10337
  this.local = local;
9904
10338
  }
9905
10339
  return ImportDefaultSpecifier;
9906
10340
  }();
9907
- exports$8.ImportNamespaceSpecifier = function() {
10341
+ exports.ImportNamespaceSpecifier = function() {
9908
10342
  function ImportNamespaceSpecifier(local) {
9909
10343
  this.type = syntax_1.Syntax.ImportNamespaceSpecifier;
9910
10344
  this.local = local;
9911
10345
  }
9912
10346
  return ImportNamespaceSpecifier;
9913
10347
  }();
9914
- exports$8.ImportSpecifier = function() {
10348
+ exports.ImportSpecifier = function() {
9915
10349
  function ImportSpecifier(local, imported) {
9916
10350
  this.type = syntax_1.Syntax.ImportSpecifier;
9917
10351
  this.local = local;
@@ -9919,7 +10353,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9919
10353
  }
9920
10354
  return ImportSpecifier;
9921
10355
  }();
9922
- exports$8.LabeledStatement = function() {
10356
+ exports.LabeledStatement = function() {
9923
10357
  function LabeledStatement(label, body) {
9924
10358
  this.type = syntax_1.Syntax.LabeledStatement;
9925
10359
  this.label = label;
@@ -9927,7 +10361,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9927
10361
  }
9928
10362
  return LabeledStatement;
9929
10363
  }();
9930
- exports$8.Literal = function() {
10364
+ exports.Literal = function() {
9931
10365
  function Literal(value, raw) {
9932
10366
  this.type = syntax_1.Syntax.Literal;
9933
10367
  this.value = value;
@@ -9935,7 +10369,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9935
10369
  }
9936
10370
  return Literal;
9937
10371
  }();
9938
- exports$8.MetaProperty = function() {
10372
+ exports.MetaProperty = function() {
9939
10373
  function MetaProperty(meta, property) {
9940
10374
  this.type = syntax_1.Syntax.MetaProperty;
9941
10375
  this.meta = meta;
@@ -9943,7 +10377,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9943
10377
  }
9944
10378
  return MetaProperty;
9945
10379
  }();
9946
- exports$8.MethodDefinition = function() {
10380
+ exports.MethodDefinition = function() {
9947
10381
  function MethodDefinition(key, computed, value, kind, isStatic) {
9948
10382
  this.type = syntax_1.Syntax.MethodDefinition;
9949
10383
  this.key = key;
@@ -9954,7 +10388,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9954
10388
  }
9955
10389
  return MethodDefinition;
9956
10390
  }();
9957
- exports$8.Module = function() {
10391
+ exports.Module = function() {
9958
10392
  function Module(body) {
9959
10393
  this.type = syntax_1.Syntax.Program;
9960
10394
  this.body = body;
@@ -9962,7 +10396,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9962
10396
  }
9963
10397
  return Module;
9964
10398
  }();
9965
- exports$8.NewExpression = function() {
10399
+ exports.NewExpression = function() {
9966
10400
  function NewExpression(callee, args) {
9967
10401
  this.type = syntax_1.Syntax.NewExpression;
9968
10402
  this.callee = callee;
@@ -9970,21 +10404,21 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9970
10404
  }
9971
10405
  return NewExpression;
9972
10406
  }();
9973
- exports$8.ObjectExpression = function() {
10407
+ exports.ObjectExpression = function() {
9974
10408
  function ObjectExpression(properties) {
9975
10409
  this.type = syntax_1.Syntax.ObjectExpression;
9976
10410
  this.properties = properties;
9977
10411
  }
9978
10412
  return ObjectExpression;
9979
10413
  }();
9980
- exports$8.ObjectPattern = function() {
10414
+ exports.ObjectPattern = function() {
9981
10415
  function ObjectPattern(properties) {
9982
10416
  this.type = syntax_1.Syntax.ObjectPattern;
9983
10417
  this.properties = properties;
9984
10418
  }
9985
10419
  return ObjectPattern;
9986
10420
  }();
9987
- exports$8.Property = function() {
10421
+ exports.Property = function() {
9988
10422
  function Property(kind, key, computed, value, method, shorthand) {
9989
10423
  this.type = syntax_1.Syntax.Property;
9990
10424
  this.key = key;
@@ -9996,7 +10430,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9996
10430
  }
9997
10431
  return Property;
9998
10432
  }();
9999
- exports$8.RegexLiteral = function() {
10433
+ exports.RegexLiteral = function() {
10000
10434
  function RegexLiteral(value, raw, pattern, flags) {
10001
10435
  this.type = syntax_1.Syntax.Literal;
10002
10436
  this.value = value;
@@ -10008,21 +10442,21 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10008
10442
  }
10009
10443
  return RegexLiteral;
10010
10444
  }();
10011
- exports$8.RestElement = function() {
10445
+ exports.RestElement = function() {
10012
10446
  function RestElement(argument) {
10013
10447
  this.type = syntax_1.Syntax.RestElement;
10014
10448
  this.argument = argument;
10015
10449
  }
10016
10450
  return RestElement;
10017
10451
  }();
10018
- exports$8.ReturnStatement = function() {
10452
+ exports.ReturnStatement = function() {
10019
10453
  function ReturnStatement(argument) {
10020
10454
  this.type = syntax_1.Syntax.ReturnStatement;
10021
10455
  this.argument = argument;
10022
10456
  }
10023
10457
  return ReturnStatement;
10024
10458
  }();
10025
- exports$8.Script = function() {
10459
+ exports.Script = function() {
10026
10460
  function Script(body) {
10027
10461
  this.type = syntax_1.Syntax.Program;
10028
10462
  this.body = body;
@@ -10030,21 +10464,21 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10030
10464
  }
10031
10465
  return Script;
10032
10466
  }();
10033
- exports$8.SequenceExpression = function() {
10467
+ exports.SequenceExpression = function() {
10034
10468
  function SequenceExpression(expressions) {
10035
10469
  this.type = syntax_1.Syntax.SequenceExpression;
10036
10470
  this.expressions = expressions;
10037
10471
  }
10038
10472
  return SequenceExpression;
10039
10473
  }();
10040
- exports$8.SpreadElement = function() {
10474
+ exports.SpreadElement = function() {
10041
10475
  function SpreadElement(argument) {
10042
10476
  this.type = syntax_1.Syntax.SpreadElement;
10043
10477
  this.argument = argument;
10044
10478
  }
10045
10479
  return SpreadElement;
10046
10480
  }();
10047
- exports$8.StaticMemberExpression = function() {
10481
+ exports.StaticMemberExpression = function() {
10048
10482
  function StaticMemberExpression(object, property) {
10049
10483
  this.type = syntax_1.Syntax.MemberExpression;
10050
10484
  this.computed = false;
@@ -10053,13 +10487,13 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10053
10487
  }
10054
10488
  return StaticMemberExpression;
10055
10489
  }();
10056
- exports$8.Super = function() {
10490
+ exports.Super = function() {
10057
10491
  function Super() {
10058
10492
  this.type = syntax_1.Syntax.Super;
10059
10493
  }
10060
10494
  return Super;
10061
10495
  }();
10062
- exports$8.SwitchCase = function() {
10496
+ exports.SwitchCase = function() {
10063
10497
  function SwitchCase(test, consequent) {
10064
10498
  this.type = syntax_1.Syntax.SwitchCase;
10065
10499
  this.test = test;
@@ -10067,7 +10501,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10067
10501
  }
10068
10502
  return SwitchCase;
10069
10503
  }();
10070
- exports$8.SwitchStatement = function() {
10504
+ exports.SwitchStatement = function() {
10071
10505
  function SwitchStatement(discriminant, cases) {
10072
10506
  this.type = syntax_1.Syntax.SwitchStatement;
10073
10507
  this.discriminant = discriminant;
@@ -10075,7 +10509,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10075
10509
  }
10076
10510
  return SwitchStatement;
10077
10511
  }();
10078
- exports$8.TaggedTemplateExpression = function() {
10512
+ exports.TaggedTemplateExpression = function() {
10079
10513
  function TaggedTemplateExpression(tag, quasi) {
10080
10514
  this.type = syntax_1.Syntax.TaggedTemplateExpression;
10081
10515
  this.tag = tag;
@@ -10083,7 +10517,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10083
10517
  }
10084
10518
  return TaggedTemplateExpression;
10085
10519
  }();
10086
- exports$8.TemplateElement = function() {
10520
+ exports.TemplateElement = function() {
10087
10521
  function TemplateElement(value, tail) {
10088
10522
  this.type = syntax_1.Syntax.TemplateElement;
10089
10523
  this.value = value;
@@ -10091,7 +10525,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10091
10525
  }
10092
10526
  return TemplateElement;
10093
10527
  }();
10094
- exports$8.TemplateLiteral = function() {
10528
+ exports.TemplateLiteral = function() {
10095
10529
  function TemplateLiteral(quasis, expressions) {
10096
10530
  this.type = syntax_1.Syntax.TemplateLiteral;
10097
10531
  this.quasis = quasis;
@@ -10099,20 +10533,20 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10099
10533
  }
10100
10534
  return TemplateLiteral;
10101
10535
  }();
10102
- exports$8.ThisExpression = function() {
10536
+ exports.ThisExpression = function() {
10103
10537
  function ThisExpression() {
10104
10538
  this.type = syntax_1.Syntax.ThisExpression;
10105
10539
  }
10106
10540
  return ThisExpression;
10107
10541
  }();
10108
- exports$8.ThrowStatement = function() {
10542
+ exports.ThrowStatement = function() {
10109
10543
  function ThrowStatement(argument) {
10110
10544
  this.type = syntax_1.Syntax.ThrowStatement;
10111
10545
  this.argument = argument;
10112
10546
  }
10113
10547
  return ThrowStatement;
10114
10548
  }();
10115
- exports$8.TryStatement = function() {
10549
+ exports.TryStatement = function() {
10116
10550
  function TryStatement(block, handler, finalizer) {
10117
10551
  this.type = syntax_1.Syntax.TryStatement;
10118
10552
  this.block = block;
@@ -10121,7 +10555,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10121
10555
  }
10122
10556
  return TryStatement;
10123
10557
  }();
10124
- exports$8.UnaryExpression = function() {
10558
+ exports.UnaryExpression = function() {
10125
10559
  function UnaryExpression(operator, argument) {
10126
10560
  this.type = syntax_1.Syntax.UnaryExpression;
10127
10561
  this.operator = operator;
@@ -10130,7 +10564,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10130
10564
  }
10131
10565
  return UnaryExpression;
10132
10566
  }();
10133
- exports$8.UpdateExpression = function() {
10567
+ exports.UpdateExpression = function() {
10134
10568
  function UpdateExpression(operator, argument, prefix) {
10135
10569
  this.type = syntax_1.Syntax.UpdateExpression;
10136
10570
  this.operator = operator;
@@ -10139,7 +10573,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10139
10573
  }
10140
10574
  return UpdateExpression;
10141
10575
  }();
10142
- exports$8.VariableDeclaration = function() {
10576
+ exports.VariableDeclaration = function() {
10143
10577
  function VariableDeclaration(declarations, kind) {
10144
10578
  this.type = syntax_1.Syntax.VariableDeclaration;
10145
10579
  this.declarations = declarations;
@@ -10147,7 +10581,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10147
10581
  }
10148
10582
  return VariableDeclaration;
10149
10583
  }();
10150
- exports$8.VariableDeclarator = function() {
10584
+ exports.VariableDeclarator = function() {
10151
10585
  function VariableDeclarator(id, init) {
10152
10586
  this.type = syntax_1.Syntax.VariableDeclarator;
10153
10587
  this.id = id;
@@ -10155,7 +10589,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10155
10589
  }
10156
10590
  return VariableDeclarator;
10157
10591
  }();
10158
- exports$8.WhileStatement = function() {
10592
+ exports.WhileStatement = function() {
10159
10593
  function WhileStatement(test, body) {
10160
10594
  this.type = syntax_1.Syntax.WhileStatement;
10161
10595
  this.test = test;
@@ -10163,7 +10597,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10163
10597
  }
10164
10598
  return WhileStatement;
10165
10599
  }();
10166
- exports$8.WithStatement = function() {
10600
+ exports.WithStatement = function() {
10167
10601
  function WithStatement(object, body) {
10168
10602
  this.type = syntax_1.Syntax.WithStatement;
10169
10603
  this.object = object;
@@ -10171,7 +10605,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10171
10605
  }
10172
10606
  return WithStatement;
10173
10607
  }();
10174
- exports$8.YieldExpression = function() {
10608
+ exports.YieldExpression = function() {
10175
10609
  function YieldExpression(argument, delegate) {
10176
10610
  this.type = syntax_1.Syntax.YieldExpression;
10177
10611
  this.argument = argument;
@@ -10180,9 +10614,9 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10180
10614
  return YieldExpression;
10181
10615
  }();
10182
10616
  },
10183
- function(module$10, exports$9, __webpack_require__) {
10617
+ function(module, exports, __webpack_require__) {
10184
10618
  "use strict";
10185
- Object.defineProperty(exports$9, "__esModule", { value: true });
10619
+ Object.defineProperty(exports, "__esModule", { value: true });
10186
10620
  var assert_1 = __webpack_require__(9);
10187
10621
  var error_handler_1 = __webpack_require__(10);
10188
10622
  var messages_1 = __webpack_require__(11);
@@ -10191,7 +10625,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
10191
10625
  var syntax_1 = __webpack_require__(2);
10192
10626
  var token_1 = __webpack_require__(13);
10193
10627
  var ArrowParameterPlaceHolder = "ArrowParameterPlaceHolder";
10194
- exports$9.Parser = function() {
10628
+ exports.Parser = function() {
10195
10629
  function Parser(code, options, delegate) {
10196
10630
  if (options === void 0) options = {};
10197
10631
  this.config = {
@@ -12600,19 +13034,19 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
12600
13034
  return Parser;
12601
13035
  }();
12602
13036
  },
12603
- function(module$11, exports$10) {
13037
+ function(module, exports) {
12604
13038
  "use strict";
12605
- Object.defineProperty(exports$10, "__esModule", { value: true });
13039
+ Object.defineProperty(exports, "__esModule", { value: true });
12606
13040
  function assert(condition, message) {
12607
13041
  /* istanbul ignore if */
12608
13042
  if (!condition) throw new Error("ASSERT: " + message);
12609
13043
  }
12610
- exports$10.assert = assert;
13044
+ exports.assert = assert;
12611
13045
  },
12612
- function(module$12, exports$11) {
13046
+ function(module, exports) {
12613
13047
  "use strict";
12614
- Object.defineProperty(exports$11, "__esModule", { value: true });
12615
- exports$11.ErrorHandler = function() {
13048
+ Object.defineProperty(exports, "__esModule", { value: true });
13049
+ exports.ErrorHandler = function() {
12616
13050
  function ErrorHandler() {
12617
13051
  this.errors = [];
12618
13052
  this.tolerant = false;
@@ -12657,10 +13091,10 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
12657
13091
  return ErrorHandler;
12658
13092
  }();
12659
13093
  },
12660
- function(module$13, exports$12) {
13094
+ function(module, exports) {
12661
13095
  "use strict";
12662
- Object.defineProperty(exports$12, "__esModule", { value: true });
12663
- exports$12.Messages = {
13096
+ Object.defineProperty(exports, "__esModule", { value: true });
13097
+ exports.Messages = {
12664
13098
  BadGetterArity: "Getter must not have any formal parameters",
12665
13099
  BadSetterArity: "Setter must have exactly one formal parameter",
12666
13100
  BadSetterRestParameter: "Setter function argument must not be a rest parameter",
@@ -12721,9 +13155,9 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
12721
13155
  UnterminatedRegExp: "Invalid regular expression: missing /"
12722
13156
  };
12723
13157
  },
12724
- function(module$14, exports$13, __webpack_require__) {
13158
+ function(module, exports, __webpack_require__) {
12725
13159
  "use strict";
12726
- Object.defineProperty(exports$13, "__esModule", { value: true });
13160
+ Object.defineProperty(exports, "__esModule", { value: true });
12727
13161
  var assert_1 = __webpack_require__(9);
12728
13162
  var character_1 = __webpack_require__(4);
12729
13163
  var messages_1 = __webpack_require__(11);
@@ -12733,7 +13167,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
12733
13167
  function octalValue(ch) {
12734
13168
  return "01234567".indexOf(ch);
12735
13169
  }
12736
- exports$13.Scanner = function() {
13170
+ exports.Scanner = function() {
12737
13171
  function Scanner(code, handler) {
12738
13172
  this.source = code;
12739
13173
  this.errorHandler = handler;
@@ -13549,25 +13983,25 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
13549
13983
  return Scanner;
13550
13984
  }();
13551
13985
  },
13552
- function(module$15, exports$14) {
13986
+ function(module, exports) {
13553
13987
  "use strict";
13554
- Object.defineProperty(exports$14, "__esModule", { value: true });
13555
- exports$14.TokenName = {};
13556
- exports$14.TokenName[1] = "Boolean";
13557
- exports$14.TokenName[2] = "<end>";
13558
- exports$14.TokenName[3] = "Identifier";
13559
- exports$14.TokenName[4] = "Keyword";
13560
- exports$14.TokenName[5] = "Null";
13561
- exports$14.TokenName[6] = "Numeric";
13562
- exports$14.TokenName[7] = "Punctuator";
13563
- exports$14.TokenName[8] = "String";
13564
- exports$14.TokenName[9] = "RegularExpression";
13565
- exports$14.TokenName[10] = "Template";
13988
+ Object.defineProperty(exports, "__esModule", { value: true });
13989
+ exports.TokenName = {};
13990
+ exports.TokenName[1] = "Boolean";
13991
+ exports.TokenName[2] = "<end>";
13992
+ exports.TokenName[3] = "Identifier";
13993
+ exports.TokenName[4] = "Keyword";
13994
+ exports.TokenName[5] = "Null";
13995
+ exports.TokenName[6] = "Numeric";
13996
+ exports.TokenName[7] = "Punctuator";
13997
+ exports.TokenName[8] = "String";
13998
+ exports.TokenName[9] = "RegularExpression";
13999
+ exports.TokenName[10] = "Template";
13566
14000
  },
13567
- function(module$16, exports$15) {
14001
+ function(module, exports) {
13568
14002
  "use strict";
13569
- Object.defineProperty(exports$15, "__esModule", { value: true });
13570
- exports$15.XHTMLEntities = {
14003
+ Object.defineProperty(exports, "__esModule", { value: true });
14004
+ exports.XHTMLEntities = {
13571
14005
  quot: "\"",
13572
14006
  amp: "&",
13573
14007
  apos: "'",
@@ -13822,9 +14256,9 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
13822
14256
  rang: "⟩"
13823
14257
  };
13824
14258
  },
13825
- function(module$17, exports$16, __webpack_require__) {
14259
+ function(module, exports, __webpack_require__) {
13826
14260
  "use strict";
13827
- Object.defineProperty(exports$16, "__esModule", { value: true });
14261
+ Object.defineProperty(exports, "__esModule", { value: true });
13828
14262
  var error_handler_1 = __webpack_require__(10);
13829
14263
  var scanner_1 = __webpack_require__(12);
13830
14264
  var token_1 = __webpack_require__(13);
@@ -13924,7 +14358,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
13924
14358
  };
13925
14359
  return Reader;
13926
14360
  }();
13927
- exports$16.Tokenizer = function() {
14361
+ exports.Tokenizer = function() {
13928
14362
  function Tokenizer(code, config) {
13929
14363
  this.errorHandler = new error_handler_1.ErrorHandler();
13930
14364
  this.errorHandler.tolerant = config ? typeof config.tolerant === "boolean" && config.tolerant : false;
@@ -13990,8 +14424,7 @@ var require_esprima = /* @__PURE__ */ __commonJSMin(((exports, module) => {
13990
14424
  ]);
13991
14425
  });
13992
14426
  }));
13993
- //#endregion
13994
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/js/function.js
14427
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/type/js/function.js
13995
14428
  var require_function = /* @__PURE__ */ __commonJSMin(((exports, module) => {
13996
14429
  var esprima;
13997
14430
  try {
@@ -14034,8 +14467,7 @@ var require_function = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14034
14467
  represent: representJavascriptFunction
14035
14468
  });
14036
14469
  }));
14037
- //#endregion
14038
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/default_full.js
14470
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/schema/default_full.js
14039
14471
  var require_default_full = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14040
14472
  var Schema = require_schema();
14041
14473
  module.exports = Schema.DEFAULT = new Schema({
@@ -14047,8 +14479,7 @@ var require_default_full = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14047
14479
  ]
14048
14480
  });
14049
14481
  }));
14050
- //#endregion
14051
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/loader.js
14482
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/loader.js
14052
14483
  var require_loader = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14053
14484
  var common = require_common();
14054
14485
  var YAMLException = require_exception();
@@ -14130,6 +14561,7 @@ var require_loader = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14130
14561
  this.legacy = options["legacy"] || false;
14131
14562
  this.json = options["json"] || false;
14132
14563
  this.listener = options["listener"] || null;
14564
+ this.maxTotalMergeKeys = typeof options["maxTotalMergeKeys"] === "number" ? options["maxTotalMergeKeys"] : 1e4;
14133
14565
  this.implicitTypes = this.schema.compiledImplicit;
14134
14566
  this.typeMap = this.schema.compiledTypeMap;
14135
14567
  this.length = input.length;
@@ -14137,6 +14569,7 @@ var require_loader = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14137
14569
  this.line = 0;
14138
14570
  this.lineStart = 0;
14139
14571
  this.lineIndent = 0;
14572
+ this.totalMergeKeys = 0;
14140
14573
  this.documents = [];
14141
14574
  }
14142
14575
  function generateError(state, message) {
@@ -14185,12 +14618,18 @@ var require_loader = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14185
14618
  state.result += _result;
14186
14619
  }
14187
14620
  }
14621
+ function chargeMergeWork(state) {
14622
+ state.totalMergeKeys += 1;
14623
+ if (state.maxTotalMergeKeys !== -1 && state.totalMergeKeys > state.maxTotalMergeKeys) throwError(state, "merge keys exceeded maxTotalMergeKeys (" + state.maxTotalMergeKeys + ")");
14624
+ }
14188
14625
  function mergeMappings(state, destination, source, overridableKeys) {
14189
14626
  var sourceKeys, key, index, quantity;
14190
14627
  if (!common.isObject(source)) throwError(state, "cannot merge mappings; the provided source object is unacceptable");
14628
+ chargeMergeWork(state);
14191
14629
  sourceKeys = Object.keys(source);
14192
14630
  for (index = 0, quantity = sourceKeys.length; index < quantity; index += 1) {
14193
14631
  key = sourceKeys[index];
14632
+ chargeMergeWork(state);
14194
14633
  if (!_hasOwnProperty.call(destination, key)) {
14195
14634
  setProperty(destination, key, source[key]);
14196
14635
  overridableKeys[key] = true;
@@ -14210,8 +14649,10 @@ var require_loader = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14210
14649
  keyNode = String(keyNode);
14211
14650
  if (_result === null) _result = {};
14212
14651
  if (keyTag === "tag:yaml.org,2002:merge") {
14213
- if (Array.isArray(valueNode)) for (index = 0, quantity = valueNode.length; index < quantity; index += 1) mergeMappings(state, _result, valueNode[index], overridableKeys);
14214
- else mergeMappings(state, _result, valueNode, overridableKeys);
14652
+ if (Array.isArray(valueNode)) {
14653
+ if (valueNode.length > 100) throwError(state, "abnormal merge sequence size");
14654
+ for (index = 0, quantity = valueNode.length; index < quantity; index += 1) mergeMappings(state, _result, valueNode[index], overridableKeys);
14655
+ } else mergeMappings(state, _result, valueNode, overridableKeys);
14215
14656
  } else {
14216
14657
  if (!state.json && !_hasOwnProperty.call(overridableKeys, keyNode) && _hasOwnProperty.call(_result, keyNode)) {
14217
14658
  state.line = startLine || state.line;
@@ -14863,8 +15304,7 @@ var require_loader = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14863
15304
  module.exports.safeLoadAll = safeLoadAll;
14864
15305
  module.exports.safeLoad = safeLoad;
14865
15306
  }));
14866
- //#endregion
14867
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/dumper.js
15307
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml/dumper.js
14868
15308
  var require_dumper = /* @__PURE__ */ __commonJSMin(((exports, module) => {
14869
15309
  var common = require_common();
14870
15310
  var YAMLException = require_exception();
@@ -15307,8 +15747,7 @@ var require_dumper = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15307
15747
  module.exports.dump = dump;
15308
15748
  module.exports.safeDump = safeDump;
15309
15749
  }));
15310
- //#endregion
15311
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml.js
15750
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/lib/js-yaml.js
15312
15751
  var require_js_yaml$1 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15313
15752
  var loader = require_loader();
15314
15753
  var dumper = require_dumper();
@@ -15339,13 +15778,11 @@ var require_js_yaml$1 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15339
15778
  module.exports.compose = deprecated("compose");
15340
15779
  module.exports.addConstructor = deprecated("addConstructor");
15341
15780
  }));
15342
- //#endregion
15343
- //#region ../../../node_modules/gray-matter/node_modules/js-yaml/index.js
15781
+ // ../../../node_modules/gray-matter/node_modules/js-yaml/index.js
15344
15782
  var require_js_yaml = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15345
15783
  module.exports = require_js_yaml$1();
15346
15784
  }));
15347
- //#endregion
15348
- //#region ../../../node_modules/gray-matter/lib/engines.js
15785
+ // ../../../node_modules/gray-matter/lib/engines.js
15349
15786
  var require_engines = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15350
15787
  var yaml = require_js_yaml();
15351
15788
  /**
@@ -15390,8 +15827,7 @@ var require_engines = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15390
15827
  }
15391
15828
  };
15392
15829
  }));
15393
- //#endregion
15394
- //#region ../../../node_modules/strip-bom-string/index.js
15830
+ // ../../../node_modules/strip-bom-string/index.js
15395
15831
  /*!
15396
15832
  * strip-bom-string <https://github.com/jonschlinkert/strip-bom-string>
15397
15833
  *
@@ -15404,8 +15840,7 @@ var require_strip_bom_string = /* @__PURE__ */ __commonJSMin(((exports, module)
15404
15840
  return str;
15405
15841
  };
15406
15842
  }));
15407
- //#endregion
15408
- //#region ../../../node_modules/gray-matter/lib/utils.js
15843
+ // ../../../node_modules/gray-matter/lib/utils.js
15409
15844
  var require_utils = /* @__PURE__ */ __commonJSMin(((exports) => {
15410
15845
  var stripBom = require_strip_bom_string();
15411
15846
  var typeOf = require_kind_of();
@@ -15457,8 +15892,7 @@ var require_utils = /* @__PURE__ */ __commonJSMin(((exports) => {
15457
15892
  return str.slice(0, len) === substr;
15458
15893
  };
15459
15894
  }));
15460
- //#endregion
15461
- //#region ../../../node_modules/gray-matter/lib/defaults.js
15895
+ // ../../../node_modules/gray-matter/lib/defaults.js
15462
15896
  var require_defaults = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15463
15897
  var engines = require_engines();
15464
15898
  var utils = require_utils();
@@ -15471,8 +15905,7 @@ var require_defaults = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15471
15905
  return opts;
15472
15906
  };
15473
15907
  }));
15474
- //#endregion
15475
- //#region ../../../node_modules/gray-matter/lib/engine.js
15908
+ // ../../../node_modules/gray-matter/lib/engine.js
15476
15909
  var require_engine = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15477
15910
  module.exports = function(name, options) {
15478
15911
  let engine = options.engines[name] || options.engines[aliase(name)];
@@ -15493,8 +15926,7 @@ var require_engine = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15493
15926
  }
15494
15927
  }
15495
15928
  }));
15496
- //#endregion
15497
- //#region ../../../node_modules/gray-matter/lib/stringify.js
15929
+ // ../../../node_modules/gray-matter/lib/stringify.js
15498
15930
  var require_stringify = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15499
15931
  var typeOf = require_kind_of();
15500
15932
  var getEngine = require_engine();
@@ -15532,8 +15964,7 @@ var require_stringify = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15532
15964
  return str.slice(-1) !== "\n" ? str + "\n" : str;
15533
15965
  }
15534
15966
  }));
15535
- //#endregion
15536
- //#region ../../../node_modules/gray-matter/lib/excerpt.js
15967
+ // ../../../node_modules/gray-matter/lib/excerpt.js
15537
15968
  var require_excerpt = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15538
15969
  var defaults = require_defaults();
15539
15970
  module.exports = function(file, options) {
@@ -15548,8 +15979,7 @@ var require_excerpt = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15548
15979
  return file;
15549
15980
  };
15550
15981
  }));
15551
- //#endregion
15552
- //#region ../../../node_modules/gray-matter/lib/to-file.js
15982
+ // ../../../node_modules/gray-matter/lib/to-file.js
15553
15983
  var require_to_file = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15554
15984
  var typeOf = require_kind_of();
15555
15985
  var stringify = require_stringify();
@@ -15575,8 +16005,7 @@ var require_to_file = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15575
16005
  return file;
15576
16006
  };
15577
16007
  }));
15578
- //#endregion
15579
- //#region ../../../node_modules/gray-matter/lib/parse.js
16008
+ // ../../../node_modules/gray-matter/lib/parse.js
15580
16009
  var require_parse = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15581
16010
  var getEngine = require_engine();
15582
16011
  var defaults = require_defaults();
@@ -15587,8 +16016,7 @@ var require_parse = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15587
16016
  return engine.parse(str, opts);
15588
16017
  };
15589
16018
  }));
15590
- //#endregion
15591
- //#region ../../../node_modules/gray-matter/index.js
16019
+ // ../../../node_modules/gray-matter/index.js
15592
16020
  var require_gray_matter = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15593
16021
  var fs = require___vite_browser_external();
15594
16022
  var sections = require_section_matter();
@@ -15753,53 +16181,8 @@ var require_gray_matter = /* @__PURE__ */ __commonJSMin(((exports, module) => {
15753
16181
  };
15754
16182
  module.exports = matter;
15755
16183
  }));
15756
- //#endregion
15757
- //#region ../core/dist/document/front-matter.js
16184
+ // ../core/dist/document/front-matter.js
15758
16185
  var import_gray_matter = /* @__PURE__ */ __toESM(require_gray_matter(), 1);
15759
- //#endregion
15760
- //#region src/engine-context.ts
15761
- var EngineContext = createContext(null);
15762
- /**
15763
- * Wrap a subtree with the engine instance it belongs to. Every component
15764
- * rendered under a `BurgerEditorRoot` / editable-area tree reads the engine
15765
- * through {@link useEngine} instead of taking it as a prop — this is the
15766
- * single dependency-injection point for the whole client UI.
15767
- * @param root0
15768
- * @param root0.engine
15769
- * @param root0.children
15770
- * @example
15771
- * ```tsx
15772
- * <EngineProvider engine={engine}>
15773
- * <BurgerEditorRoot />
15774
- * </EngineProvider>
15775
- * ```
15776
- */
15777
- function EngineProvider({ engine, children }) {
15778
- return createElement(EngineContext, { value: engine }, children);
15779
- }
15780
- /**
15781
- * Read the engine instance from the nearest {@link EngineProvider}.
15782
- *
15783
- * Every root the client mounts (`BurgerEditorRoot`, the editable-area
15784
- * tree, `DraftSwitcher`) wraps itself in an `EngineProvider`, so item
15785
- * `Editor` components and every `@burger-editor/client/ui` component can
15786
- * call this instead of taking `engine` as a prop.
15787
- * @returns The engine instance
15788
- * @throws {Error} When called outside an `EngineProvider`
15789
- * @example
15790
- * ```tsx
15791
- * function MyField() {
15792
- * const engine = useEngine();
15793
- * return <button onClick={() => engine.save()}>Save</button>;
15794
- * }
15795
- * ```
15796
- */
15797
- function useEngine() {
15798
- const engine = use(EngineContext);
15799
- if (!engine) throw new Error("useEngine() must be called under an <EngineProvider>.");
15800
- return engine;
15801
- }
15802
- //#endregion
15803
- export { UIStateStore as a, CommandBus as c, formatDate as d, CSS_LAYER as f, BurgerEditorEngine as i, Item as l, useEngine as n, createBgeEvent as o, getBlockAtPosition as r, beginProcessing as s, EngineProvider as t, formatByteSize as u };
16186
+ export { beginProcessing as a, formatByteSize as c, createBgeEvent as i, formatDate as l, BurgerEditorEngine as n, CommandBus as o, UIStateStore as r, Item as s, getBlockAtPosition as t, CSS_LAYER as u };
15804
16187
 
15805
- //# sourceMappingURL=engine-context-D0zt6fhJ.js.map
16188
+ //# sourceMappingURL=dist-DYydjVsL.js.map