@enos5/enos-vue-default 1.8.10 → 1.8.11

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 (32) hide show
  1. package/dist/components/CustomSelect.vue.d.ts +18 -0
  2. package/dist/components/InputGroup.vue.d.ts +18 -0
  3. package/dist/components/SelectInput.vue.d.ts +18 -0
  4. package/dist/{index-Bsqrrc8R.js → index-6eLEqodC.js} +4 -35
  5. package/dist/index-6eLEqodC.js.map +1 -0
  6. package/dist/{index-BR_u7CCm.js → index-BHTvTOGk.js} +2 -4
  7. package/dist/{index-BR_u7CCm.js.map → index-BHTvTOGk.js.map} +1 -1
  8. package/dist/{index-ukywSRmc.js → index-BPcdR1qv.js} +9 -10
  9. package/dist/index-BPcdR1qv.js.map +1 -0
  10. package/dist/{index-BBGZQp5w.js → index-Ch9hFG6f.js} +6 -17
  11. package/dist/{index-BBGZQp5w.js.map → index-Ch9hFG6f.js.map} +1 -1
  12. package/dist/index-CiFpmPug.js.map +1 -1
  13. package/dist/{index-CuSlJQwq.js → index-Cjhk16SP.js} +8 -10
  14. package/dist/index-Cjhk16SP.js.map +1 -0
  15. package/dist/{index-D72Leh_x.js → index-D7sesyMc.js} +4 -4
  16. package/dist/{index-D72Leh_x.js.map → index-D7sesyMc.js.map} +1 -1
  17. package/dist/{index-1G1T4Qrv.js → index-G1cAlO5C.js} +203 -373
  18. package/dist/index-G1cAlO5C.js.map +1 -0
  19. package/dist/index.js +1 -1
  20. package/dist/index.node.js +1 -1
  21. package/dist/{plugin-m8XaPTjJ.js → plugin-Bl7pzq-e.js} +296 -52
  22. package/dist/plugin-Bl7pzq-e.js.map +1 -0
  23. package/dist/styles.css +76 -1552
  24. package/dist/{tinymce-Dg510HCs.js → tinymce-WPdeGquX.js} +388 -659
  25. package/dist/tinymce-WPdeGquX.js.map +1 -0
  26. package/package.json +36 -36
  27. package/dist/index-1G1T4Qrv.js.map +0 -1
  28. package/dist/index-Bsqrrc8R.js.map +0 -1
  29. package/dist/index-CuSlJQwq.js.map +0 -1
  30. package/dist/index-ukywSRmc.js.map +0 -1
  31. package/dist/plugin-m8XaPTjJ.js.map +0 -1
  32. package/dist/tinymce-Dg510HCs.js.map +0 -1
@@ -595,9 +595,9 @@ function requireTinymce() {
595
595
  copy2.sort(comparator);
596
596
  return copy2;
597
597
  };
598
- const get$c = (xs, i) => i >= 0 && i < xs.length ? Optional.some(xs[i]) : Optional.none();
599
- const head = (xs) => get$c(xs, 0);
600
- const last$2 = (xs) => get$c(xs, xs.length - 1);
598
+ const get$b = (xs, i) => i >= 0 && i < xs.length ? Optional.some(xs[i]) : Optional.none();
599
+ const head = (xs) => get$b(xs, 0);
600
+ const last$2 = (xs) => get$b(xs, xs.length - 1);
601
601
  const from = isFunction(Array.from) ? Array.from : (x) => nativeSlice.call(x);
602
602
  const findMap = (arr, f) => {
603
603
  for (let i = 0; i < arr.length; i++) {
@@ -672,7 +672,7 @@ function requireTinymce() {
672
672
  const values = (obj) => {
673
673
  return mapToArray(obj, identity);
674
674
  };
675
- const get$b = (obj, key) => {
675
+ const get$a = (obj, key) => {
676
676
  return has$2(obj, key) ? Optional.from(obj[key]) : Optional.none();
677
677
  };
678
678
  const has$2 = (obj, key) => hasOwnProperty$1.call(obj, key);
@@ -2011,7 +2011,7 @@ function requireTinymce() {
2011
2011
  throw new Error("Attribute value was not simple");
2012
2012
  }
2013
2013
  };
2014
- const set$5 = (element, key, value2) => {
2014
+ const set$4 = (element, key, value2) => {
2015
2015
  rawSet(element.dom, key, value2);
2016
2016
  };
2017
2017
  const setAll$1 = (element, attrs) => {
@@ -2020,11 +2020,11 @@ function requireTinymce() {
2020
2020
  rawSet(dom2, k, v);
2021
2021
  });
2022
2022
  };
2023
- const get$a = (element, key) => {
2023
+ const get$9 = (element, key) => {
2024
2024
  const v = element.dom.getAttribute(key);
2025
2025
  return v === null ? void 0 : v;
2026
2026
  };
2027
- const getOpt = (element, key) => Optional.from(get$a(element, key));
2027
+ const getOpt = (element, key) => Optional.from(get$9(element, key));
2028
2028
  const has$1 = (element, key) => {
2029
2029
  const dom2 = element.dom;
2030
2030
  return dom2 && dom2.hasAttribute ? dom2.hasAttribute(key) : false;
@@ -2083,8 +2083,8 @@ function requireTinymce() {
2083
2083
  return children$1(SugarElement.fromDom(div));
2084
2084
  };
2085
2085
  const fromDom$1 = (nodes) => map$3(nodes, SugarElement.fromDom);
2086
- const get$9 = (element) => element.dom.innerHTML;
2087
- const set$4 = (element, content) => {
2086
+ const get$8 = (element) => element.dom.innerHTML;
2087
+ const set$3 = (element, content) => {
2088
2088
  const owner2 = owner$1(element);
2089
2089
  const docDom = owner2.dom;
2090
2090
  const fragment = SugarElement.fromDom(docDom.createDocumentFragment());
@@ -2097,7 +2097,7 @@ function requireTinymce() {
2097
2097
  const container = SugarElement.fromTag("div");
2098
2098
  const clone2 = SugarElement.fromDom(element.dom.cloneNode(true));
2099
2099
  append$1(container, clone2);
2100
- return get$9(container);
2100
+ return get$8(container);
2101
2101
  };
2102
2102
  const isSupported = (dom2) => dom2.style !== void 0 && isFunction(dom2.style.getPropertyValue);
2103
2103
  const inBody = (element) => {
@@ -2122,7 +2122,7 @@ function requireTinymce() {
2122
2122
  dom2.style.removeProperty(property);
2123
2123
  }
2124
2124
  };
2125
- const set$3 = (element, property, value2) => {
2125
+ const set$2 = (element, property, value2) => {
2126
2126
  const dom2 = element.dom;
2127
2127
  internalSet(dom2, property, value2);
2128
2128
  };
@@ -2132,7 +2132,7 @@ function requireTinymce() {
2132
2132
  internalSet(dom2, k, v);
2133
2133
  });
2134
2134
  };
2135
- const get$8 = (element, property) => {
2135
+ const get$7 = (element, property) => {
2136
2136
  const dom2 = element.dom;
2137
2137
  const styles = window.getComputedStyle(dom2);
2138
2138
  const r2 = styles.getPropertyValue(property);
@@ -2176,14 +2176,14 @@ function requireTinymce() {
2176
2176
  const get2 = (element) => {
2177
2177
  const r2 = getOffset(element);
2178
2178
  if (r2 <= 0 || r2 === null) {
2179
- const css = get$8(element, name2);
2179
+ const css = get$7(element, name2);
2180
2180
  return parseFloat(css) || 0;
2181
2181
  }
2182
2182
  return r2;
2183
2183
  };
2184
2184
  const getOuter2 = get2;
2185
2185
  const aggregate = (element, properties) => foldl(properties, (acc, property) => {
2186
- const val = get$8(element, property);
2186
+ const val = get$7(element, property);
2187
2187
  const value2 = val === void 0 ? 0 : parseInt(val, 10);
2188
2188
  return isNaN(value2) ? acc : acc + value2;
2189
2189
  }, 0);
@@ -2204,7 +2204,7 @@ function requireTinymce() {
2204
2204
  const dom2 = element.dom;
2205
2205
  return inBody(element) ? dom2.getBoundingClientRect().height : dom2.offsetHeight;
2206
2206
  });
2207
- const get$7 = (element) => api$1.get(element);
2207
+ const get$6 = (element) => api$1.get(element);
2208
2208
  const r = (left, top) => {
2209
2209
  const translate2 = (x, y) => r(left + x, top + y);
2210
2210
  return {
@@ -2251,7 +2251,7 @@ function requireTinymce() {
2251
2251
  }
2252
2252
  return boxPosition(dom2);
2253
2253
  };
2254
- const get$6 = (_DOC) => {
2254
+ const get$5 = (_DOC) => {
2255
2255
  const doc = _DOC !== void 0 ? _DOC.dom : document;
2256
2256
  const x = doc.body.scrollLeft || doc.documentElement.scrollLeft;
2257
2257
  const y = doc.body.scrollTop || doc.documentElement.scrollTop;
@@ -2301,23 +2301,23 @@ function requireTinymce() {
2301
2301
  return SugarElement.fromDom(fragment);
2302
2302
  };
2303
2303
  const api = NodeValue(isText$c, "text");
2304
- const get$5 = (element) => api.get(element);
2304
+ const get$4 = (element) => api.get(element);
2305
2305
  const getOption = (element) => api.getOption(element);
2306
- const set$2 = (element, value2) => api.set(element, value2);
2306
+ const set$1 = (element, value2) => api.set(element, value2);
2307
2307
  const read$4 = (element, attr) => {
2308
- const value2 = get$a(element, attr);
2308
+ const value2 = get$9(element, attr);
2309
2309
  return value2 === void 0 || value2 === "" ? [] : value2.split(" ");
2310
2310
  };
2311
2311
  const add$4 = (element, attr, id) => {
2312
2312
  const old = read$4(element, attr);
2313
2313
  const nu2 = old.concat([id]);
2314
- set$5(element, attr, nu2.join(" "));
2314
+ set$4(element, attr, nu2.join(" "));
2315
2315
  return true;
2316
2316
  };
2317
2317
  const remove$6 = (element, attr, id) => {
2318
2318
  const nu2 = filter$5(read$4(element, attr), (v) => v !== id);
2319
2319
  if (nu2.length > 0) {
2320
- set$5(element, attr, nu2.join(" "));
2320
+ set$4(element, attr, nu2.join(" "));
2321
2321
  } else {
2322
2322
  remove$9(element, attr);
2323
2323
  }
@@ -2385,11 +2385,11 @@ function requireTinymce() {
2385
2385
  return ClosestOrAncestor(is2, ancestor$4, scope, selector, isRoot2);
2386
2386
  };
2387
2387
  const supports = (element) => element.dom.classList !== void 0;
2388
- const get$4 = (element) => read$4(element, "class");
2388
+ const get$3 = (element) => read$4(element, "class");
2389
2389
  const add$3 = (element, clazz) => add$4(element, "class", clazz);
2390
2390
  const remove$5 = (element, clazz) => remove$6(element, "class", clazz);
2391
2391
  const toggle$2 = (element, clazz) => {
2392
- if (contains$2(get$4(element), clazz)) {
2392
+ if (contains$2(get$3(element), clazz)) {
2393
2393
  return remove$5(element, clazz);
2394
2394
  } else {
2395
2395
  return add$3(element, clazz);
@@ -2403,7 +2403,7 @@ function requireTinymce() {
2403
2403
  }
2404
2404
  };
2405
2405
  const cleanClass = (element) => {
2406
- const classList = supports(element) ? element.dom.classList : get$4(element);
2406
+ const classList = supports(element) ? element.dom.classList : get$3(element);
2407
2407
  if (classList.length === 0) {
2408
2408
  remove$9(element, "class");
2409
2409
  }
@@ -2442,13 +2442,9 @@ function requireTinymce() {
2442
2442
  }
2443
2443
  };
2444
2444
  const getRaw = (element) => element.dom.contentEditable;
2445
- const set$1 = (element, editable) => {
2445
+ const set = (element, editable) => {
2446
2446
  element.dom.contentEditable = editable ? "true" : "false";
2447
2447
  };
2448
- const get$3 = (element) => element.dom.textContent;
2449
- const set = (element, value2) => {
2450
- element.dom.textContent = value2;
2451
- };
2452
2448
  const ancestors$1 = (scope, predicate, isRoot2) => filter$5(parents$1(scope, isRoot2), predicate);
2453
2449
  const children = (scope, predicate) => filter$5(children$1(scope), predicate);
2454
2450
  const descendants$1 = (scope, predicate) => {
@@ -2499,7 +2495,7 @@ function requireTinymce() {
2499
2495
  // but trim removes &nbsp; and that's allowed
2500
2496
  text2.trim().length !== 0 || text2.indexOf(nbsp) > -1
2501
2497
  )).isSome();
2502
- const isContentEditableFalse$b = (elem) => isHTMLElement$1(elem) && get$a(elem, "contenteditable") === "false";
2498
+ const isContentEditableFalse$b = (elem) => isHTMLElement$1(elem) && get$9(elem, "contenteditable") === "false";
2503
2499
  const elementsWithCursorPosition = ["img", "br"];
2504
2500
  const isCursorPosition = (elem) => {
2505
2501
  const hasCursorPosition = isTextNodeWithCursorPosition(elem);
@@ -2640,7 +2636,7 @@ function requireTinymce() {
2640
2636
  const getBounds = (_win) => {
2641
2637
  const win = _win === void 0 ? window : _win;
2642
2638
  const doc = win.document;
2643
- const scroll = get$6(SugarElement.fromDom(doc));
2639
+ const scroll = get$5(SugarElement.fromDom(doc));
2644
2640
  return get$2(win).fold(() => {
2645
2641
  const html2 = win.document.documentElement;
2646
2642
  const width = html2.clientWidth;
@@ -2852,7 +2848,7 @@ function requireTinymce() {
2852
2848
  const isDetails = matchNodeName$1("details");
2853
2849
  const isSummary$1 = matchNodeName$1("summary");
2854
2850
  const ucVideoNodeName = "uc-video";
2855
- const isUcVideo = matchNodeName$1(ucVideoNodeName);
2851
+ const isUcVideo = (el) => el.nodeName.toLowerCase() === ucVideoNodeName;
2856
2852
  const defaultOptionValues = {
2857
2853
  skipBogus: true,
2858
2854
  includeZwsp: false,
@@ -3052,7 +3048,7 @@ function requireTinymce() {
3052
3048
  const updateCaret = (schema, root, caretParent) => {
3053
3049
  const isRoot2 = (el) => eq(el, SugarElement.fromDom(root));
3054
3050
  const parents2 = parents$1(SugarElement.fromDom(caretParent), isRoot2);
3055
- get$c(parents2, parents2.length - 2).filter(isElement$8).fold(() => updateChildren(schema, root), (scope) => updateChildren(schema, scope.dom));
3051
+ get$b(parents2, parents2.length - 2).filter(isElement$8).fold(() => updateChildren(schema, root), (scope) => updateChildren(schema, scope.dom));
3056
3052
  };
3057
3053
  const hasBlockAttr = (el) => el.hasAttribute(transparentBlockAttr);
3058
3054
  const isTransparentElementName = (schema, name2) => has$2(schema.getTransparentElements(), name2);
@@ -3084,7 +3080,7 @@ function requireTinymce() {
3084
3080
  const doc = body.ownerDocument;
3085
3081
  rootElm = rootElm ? rootElm : body;
3086
3082
  if (elm) {
3087
- if (rootElm === body && elm.getBoundingClientRect && get$8(SugarElement.fromDom(body), "position") === "static") {
3083
+ if (rootElm === body && elm.getBoundingClientRect && get$7(SugarElement.fromDom(body), "position") === "static") {
3088
3084
  const pos = elm.getBoundingClientRect();
3089
3085
  x = pos.left + (doc.documentElement.scrollLeft || body.scrollLeft) - doc.documentElement.clientLeft;
3090
3086
  y = pos.top + (doc.documentElement.scrollTop || body.scrollTop) - doc.documentElement.clientTop;
@@ -3138,7 +3134,7 @@ function requireTinymce() {
3138
3134
  const styleContainer = getStyleContainer(edos);
3139
3135
  descendant$1(styleContainer, "#" + id).each(remove$8);
3140
3136
  };
3141
- const getOrCreateState = (url) => get$b(loadedStates, url).getOrThunk(() => ({
3137
+ const getOrCreateState = (url) => get$a(loadedStates, url).getOrThunk(() => ({
3142
3138
  id: "mce-u" + idCount++,
3143
3139
  passed: [],
3144
3140
  failed: [],
@@ -3189,16 +3185,16 @@ function requireTinymce() {
3189
3185
  });
3190
3186
  const crossorigin = getCrossOrigin$1(url, settings);
3191
3187
  if (crossorigin !== void 0) {
3192
- set$5(linkElem, "crossOrigin", crossorigin);
3188
+ set$4(linkElem, "crossOrigin", crossorigin);
3193
3189
  }
3194
3190
  if (settings.referrerPolicy) {
3195
- set$5(linkElem, "referrerpolicy", settings.referrerPolicy);
3191
+ set$4(linkElem, "referrerpolicy", settings.referrerPolicy);
3196
3192
  }
3197
3193
  link = linkElem.dom;
3198
3194
  link.onload = passed;
3199
3195
  link.onerror = failed;
3200
3196
  addStyle(linkElem);
3201
- set$5(linkElem, "href", urlWithSuffix);
3197
+ set$4(linkElem, "href", urlWithSuffix);
3202
3198
  });
3203
3199
  const loadRawCss = (key, css) => {
3204
3200
  const state = getOrCreateState(key);
@@ -3227,7 +3223,7 @@ function requireTinymce() {
3227
3223
  };
3228
3224
  const unload = (url) => {
3229
3225
  const urlWithSuffix = Tools._addCacheSuffix(url);
3230
- get$b(loadedStates, urlWithSuffix).each((state) => {
3226
+ get$a(loadedStates, urlWithSuffix).each((state) => {
3231
3227
  const count2 = --state.count;
3232
3228
  if (count2 === 0) {
3233
3229
  delete loadedStates[urlWithSuffix];
@@ -3236,7 +3232,7 @@ function requireTinymce() {
3236
3232
  });
3237
3233
  };
3238
3234
  const unloadRawCss = (key) => {
3239
- get$b(loadedStates, key).each((state) => {
3235
+ get$a(loadedStates, key).each((state) => {
3240
3236
  const count2 = --state.count;
3241
3237
  if (count2 === 0) {
3242
3238
  delete loadedStates[key];
@@ -4457,9 +4453,7 @@ function requireTinymce() {
4457
4453
  compress("border", "-style");
4458
4454
  compress("padding", "");
4459
4455
  compress("margin", "");
4460
- if (!/(#.* rgb(a?)\(.*)|(rgb(a?)\(.*\) )/.test(styles["border-color"])) {
4461
- compress2("border", "border-width", "border-style", "border-color");
4462
- }
4456
+ compress2("border", "border-width", "border-style", "border-color");
4463
4457
  if (styles.border === "medium none") {
4464
4458
  delete styles.border;
4465
4459
  }
@@ -4525,8 +4519,7 @@ function requireTinymce() {
4525
4519
  webkitMovementX: true,
4526
4520
  webkitMovementY: true,
4527
4521
  keyIdentifier: true,
4528
- mozPressure: true,
4529
- mozInputSource: true
4522
+ mozPressure: true
4530
4523
  };
4531
4524
  const isNativeEvent = (event) => event instanceof Event || isFunction(event.initEvent);
4532
4525
  const hasIsDefaultPrevented = (event) => event.isDefaultPrevented === always || event.isDefaultPrevented === never;
@@ -4875,7 +4868,7 @@ function requireTinymce() {
4875
4868
  if (isNullable(value2) || value2 === "") {
4876
4869
  remove$9(elm, name2);
4877
4870
  } else {
4878
- set$5(elm, name2, value2);
4871
+ set$4(elm, name2, value2);
4879
4872
  }
4880
4873
  };
4881
4874
  const camelCaseToHyphens = (name2) => name2.replace(/[A-Z]/g, (v) => "-" + v.toLowerCase());
@@ -4896,7 +4889,7 @@ function requireTinymce() {
4896
4889
  return idx;
4897
4890
  };
4898
4891
  const updateInternalStyleAttr = (styles, elm) => {
4899
- const rawValue = get$a(elm, "style");
4892
+ const rawValue = get$9(elm, "style");
4900
4893
  const value2 = styles.serialize(styles.parse(rawValue), name(elm));
4901
4894
  legacySetAttribute(elm, internalStyleName, value2);
4902
4895
  };
@@ -4912,7 +4905,7 @@ function requireTinymce() {
4912
4905
  if (isNullable(cssValue) || cssValue === "") {
4913
4906
  remove$7($elm, normalizedName);
4914
4907
  } else {
4915
- set$3($elm, normalizedName, convertStyleToString(cssValue, normalizedName));
4908
+ set$2($elm, normalizedName, convertStyleToString(cssValue, normalizedName));
4916
4909
  }
4917
4910
  };
4918
4911
  const setupAttrHooks = (styles, settings, getContext2) => {
@@ -4929,7 +4922,7 @@ function requireTinymce() {
4929
4922
  },
4930
4923
  get: (elm, name2) => {
4931
4924
  const sugarElm = SugarElement.fromDom(elm);
4932
- return get$a(sugarElm, "data-mce-" + name2) || get$a(sugarElm, name2);
4925
+ return get$9(sugarElm, "data-mce-" + name2) || get$9(sugarElm, name2);
4933
4926
  }
4934
4927
  };
4935
4928
  const attrHooks = {
@@ -4946,7 +4939,7 @@ function requireTinymce() {
4946
4939
  },
4947
4940
  get: (elm) => {
4948
4941
  const sugarElm = SugarElement.fromDom(elm);
4949
- const value2 = get$a(sugarElm, internalStyleName) || get$a(sugarElm, "style");
4942
+ const value2 = get$9(sugarElm, internalStyleName) || get$9(sugarElm, "style");
4950
4943
  return styles.serialize(styles.parse(value2), name(sugarElm));
4951
4944
  }
4952
4945
  }
@@ -5003,7 +4996,7 @@ function requireTinymce() {
5003
4996
  if (hook && hook.get) {
5004
4997
  value2 = hook.get($elm.dom, name2);
5005
4998
  } else {
5006
- value2 = get$a($elm, name2);
4999
+ value2 = get$9($elm, name2);
5007
5000
  }
5008
5001
  }
5009
5002
  return isNonNullable(value2) ? value2 : defaultVal;
@@ -5017,7 +5010,7 @@ function requireTinymce() {
5017
5010
  if (isElement$7(e)) {
5018
5011
  const $elm = SugarElement.fromDom(e);
5019
5012
  const val = value2 === "" ? null : value2;
5020
- const originalValue = get$a($elm, name2);
5013
+ const originalValue = get$9($elm, name2);
5021
5014
  const hook = attrHooks[name2];
5022
5015
  if (hook && hook.set) {
5023
5016
  hook.set($elm.dom, val, name2);
@@ -5075,7 +5068,7 @@ function requireTinymce() {
5075
5068
  return void 0;
5076
5069
  }
5077
5070
  if (computed) {
5078
- return get$8(SugarElement.fromDom($elm), camelCaseToHyphens(name2));
5071
+ return get$7(SugarElement.fromDom($elm), camelCaseToHyphens(name2));
5079
5072
  } else {
5080
5073
  name2 = name2.replace(/-(\D)/g, (a, b) => b.toUpperCase());
5081
5074
  if (name2 === "float") {
@@ -5203,7 +5196,7 @@ function requireTinymce() {
5203
5196
  const setHTML = (elm, html2) => {
5204
5197
  run(elm, (e) => {
5205
5198
  const $elm = SugarElement.fromDom(e);
5206
- set$4($elm, html2);
5199
+ set$3($elm, html2);
5207
5200
  });
5208
5201
  };
5209
5202
  const add2 = (parentElm, name2, attrs, html2, create3) => run(parentElm, (parentElm2) => {
@@ -5339,7 +5332,7 @@ function requireTinymce() {
5339
5332
  run(elm, (e) => remove$7(SugarElement.fromDom(e), "display"));
5340
5333
  };
5341
5334
  const hide = (elm) => {
5342
- run(elm, (e) => set$3(SugarElement.fromDom(e), "display", "none"));
5335
+ run(elm, (e) => set$2(SugarElement.fromDom(e), "display", "none"));
5343
5336
  };
5344
5337
  const isHidden = (elm) => {
5345
5338
  const $elm = _get(elm);
@@ -6320,7 +6313,7 @@ function requireTinymce() {
6320
6313
  loadScripts(scripts) {
6321
6314
  const self = this;
6322
6315
  const execCallbacks = (name2, url) => {
6323
- get$b(self.scriptLoadedCallbacks, url).each((callbacks) => {
6316
+ get$a(self.scriptLoadedCallbacks, url).each((callbacks) => {
6324
6317
  each$e(callbacks, (callback) => callback[name2](url));
6325
6318
  });
6326
6319
  delete self.scriptLoadedCallbacks[url];
@@ -6409,7 +6402,7 @@ function requireTinymce() {
6409
6402
  const isTokenised = (str) => isArray$1(str) && str.length > 1;
6410
6403
  const data = {};
6411
6404
  const currentCode = Cell("en");
6412
- const getLanguageData = () => get$b(data, currentCode.get());
6405
+ const getLanguageData = () => get$a(data, currentCode.get());
6413
6406
  const getData$1 = () => map$2(data, (value2) => ({ ...value2 }));
6414
6407
  const setCode = (newCode) => {
6415
6408
  if (newCode) {
@@ -6446,7 +6439,7 @@ function requireTinymce() {
6446
6439
  const isEmpty2 = (text3) => text3 === "" || text3 === null || text3 === void 0;
6447
6440
  const getLangData = (text3) => {
6448
6441
  const textStr = toString2(text3);
6449
- return has$2(langData, textStr) ? toString2(langData[textStr]) : get$b(langData, textStr.toLowerCase()).map(toString2).getOr(textStr);
6442
+ return has$2(langData, textStr) ? toString2(langData[textStr]) : get$a(langData, textStr.toLowerCase()).map(toString2).getOr(textStr);
6450
6443
  };
6451
6444
  const removeContext = (str) => str.replace(/{context:\w+}$/, "");
6452
6445
  const replaceWithEllipsisChar = (text3) => text3.replaceAll("...", ellipsis);
@@ -6463,7 +6456,7 @@ function requireTinymce() {
6463
6456
  }
6464
6457
  return replaceWithEllipsisChar(removeContext(getLangData(text2)));
6465
6458
  };
6466
- const isRtl$1 = () => getLanguageData().bind((items) => get$b(items, "_dir")).exists((dir) => dir === "rtl");
6459
+ const isRtl$1 = () => getLanguageData().bind((items) => get$a(items, "_dir")).exists((dir) => dir === "rtl");
6467
6460
  const hasCode = (code) => has$2(data, code);
6468
6461
  const I18n = {
6469
6462
  getData: getData$1,
@@ -6664,8 +6657,8 @@ function requireTinymce() {
6664
6657
  const directory = {};
6665
6658
  each$e(markers, (m) => {
6666
6659
  if (!isBogusElement(m, body)) {
6667
- const uid2 = get$a(m, dataAnnotationId());
6668
- const nodesAlready = get$b(directory, uid2).getOr([]);
6660
+ const uid2 = get$9(m, dataAnnotationId());
6661
+ const nodesAlready = get$a(directory, uid2).getOr([]);
6669
6662
  directory[uid2] = nodesAlready.concat([m]);
6670
6663
  }
6671
6664
  });
@@ -6685,7 +6678,7 @@ function requireTinymce() {
6685
6678
  };
6686
6679
  const updateCallbacks = (name2, f) => {
6687
6680
  const callbackMap = changeCallbacks.get();
6688
- const data2 = get$b(callbackMap, name2).getOrThunk(initData);
6681
+ const data2 = get$a(callbackMap, name2).getOrThunk(initData);
6689
6682
  const outputData = f(data2);
6690
6683
  callbackMap[name2] = outputData;
6691
6684
  changeCallbacks.set(callbackMap);
@@ -6706,7 +6699,7 @@ function requireTinymce() {
6706
6699
  const toggleActiveAttr = (uid2, state) => {
6707
6700
  each$e(findMarkers(editor, uid2), (elem) => {
6708
6701
  if (state) {
6709
- set$5(elem, dataAnnotationActive(), "true");
6702
+ set$4(elem, dataAnnotationActive(), "true");
6710
6703
  } else {
6711
6704
  remove$9(elem, dataAnnotationActive());
6712
6705
  }
@@ -6793,7 +6786,7 @@ function requireTinymce() {
6793
6786
  settings
6794
6787
  };
6795
6788
  };
6796
- const lookup2 = (name2) => get$b(annotations, name2).map((a) => a.settings);
6789
+ const lookup2 = (name2) => get$a(annotations, name2).map((a) => a.settings);
6797
6790
  const getNames = () => keys(annotations);
6798
6791
  return {
6799
6792
  register: register2,
@@ -6880,9 +6873,6 @@ function requireTinymce() {
6880
6873
  };
6881
6874
  const isTable$1 = (node) => name(node) === "table";
6882
6875
  const isBr$6 = (node) => isElement$8(node) && name(node) === "br";
6883
- const isScript = (node) => isElement$8(node) && name(node) === "script";
6884
- const isStyle = (node) => isElement$8(node) && name(node) === "style";
6885
- const isIframe = (node) => isElement$8(node) && name(node) === "iframe";
6886
6876
  const isTextBlock$3 = lazyLookup(textBlocks);
6887
6877
  const isList$1 = lazyLookup(lists);
6888
6878
  const isListItem$2 = lazyLookup(listItems$1);
@@ -6907,7 +6897,7 @@ function requireTinymce() {
6907
6897
  };
6908
6898
  const createPaddingBr = () => {
6909
6899
  const br = SugarElement.fromTag("br");
6910
- set$5(br, "data-mce-bogus", "1");
6900
+ set$4(br, "data-mce-bogus", "1");
6911
6901
  return br;
6912
6902
  };
6913
6903
  const fillWithPaddingBr = (elm) => {
@@ -7912,15 +7902,15 @@ function requireTinymce() {
7912
7902
  };
7913
7903
  const requiredAccess = (path2, obj, key, bundle) => (
7914
7904
  // In required mode, if it is undefined, it is an error.
7915
- get$b(obj, key).fold(() => missingRequired(path2, key, obj), bundle)
7905
+ get$a(obj, key).fold(() => missingRequired(path2, key, obj), bundle)
7916
7906
  );
7917
7907
  const fallbackAccess = (obj, key, fallback2, bundle) => {
7918
- const v = get$b(obj, key).getOrThunk(() => fallback2(obj));
7908
+ const v = get$a(obj, key).getOrThunk(() => fallback2(obj));
7919
7909
  return bundle(v);
7920
7910
  };
7921
- const optionAccess = (obj, key, bundle) => bundle(get$b(obj, key));
7911
+ const optionAccess = (obj, key, bundle) => bundle(get$a(obj, key));
7922
7912
  const optionDefaultedAccess = (obj, key, fallback2, bundle) => {
7923
- const opt = get$b(obj, key).map((val) => val === true ? fallback2(obj) : val);
7913
+ const opt = get$a(obj, key).map((val) => val === true ? fallback2(obj) : val);
7924
7914
  return bundle(opt);
7925
7915
  };
7926
7916
  const extractField = (field2, path2, obj, key, prop) => {
@@ -8195,7 +8185,7 @@ function requireTinymce() {
8195
8185
  if (valid) {
8196
8186
  if (value2.indexOf("=") !== -1) {
8197
8187
  const bodyObj = getHash(value2);
8198
- return { value: get$b(bodyObj, editor.id).getOr(defaultValue), valid };
8188
+ return { value: get$a(bodyObj, editor.id).getOr(defaultValue), valid };
8199
8189
  } else {
8200
8190
  return { value: value2, valid };
8201
8191
  }
@@ -8416,9 +8406,6 @@ function requireTinymce() {
8416
8406
  registerOption("content_style", {
8417
8407
  processor: "string"
8418
8408
  });
8419
- registerOption("content_language", {
8420
- processor: "string"
8421
- });
8422
8409
  registerOption("content_css_cors", {
8423
8410
  processor: "boolean",
8424
8411
  default: false
@@ -8835,10 +8822,6 @@ function requireTinymce() {
8835
8822
  },
8836
8823
  default: (_ctx) => []
8837
8824
  });
8838
- registerOption("allow_noneditable", {
8839
- processor: "boolean",
8840
- default: true
8841
- });
8842
8825
  registerOption("noneditable_class", {
8843
8826
  processor: "string",
8844
8827
  default: "mceNonEditable"
@@ -8920,9 +8903,6 @@ function requireTinymce() {
8920
8903
  processor: "string",
8921
8904
  default: "Anonymous"
8922
8905
  });
8923
- registerOption("content_id", {
8924
- processor: "string"
8925
- });
8926
8906
  registerOption("fetch_users", {
8927
8907
  processor: (value2) => {
8928
8908
  if (value2 === void 0) {
@@ -9014,7 +8994,6 @@ function requireTinymce() {
9014
8994
  const getIndentation = option("indentation");
9015
8995
  const getContentCss = option("content_css");
9016
8996
  const getContentStyle = option("content_style");
9017
- const getContentLanguage = option("content_language");
9018
8997
  const getFontCss = option("font_css");
9019
8998
  const getDirectionality = option("directionality");
9020
8999
  const getInlineBoundarySelector = option("inline_boundaries_selector");
@@ -9070,7 +9049,6 @@ function requireTinymce() {
9070
9049
  const shouldAllowHtmlDataUrls = option("allow_html_data_urls");
9071
9050
  const getTextPatterns = option("text_patterns");
9072
9051
  const getTextPatternsLookup = option("text_patterns_lookup");
9073
- const shouldAllowNonEditable = option("allow_noneditable");
9074
9052
  const getNonEditableClass = option("noneditable_class");
9075
9053
  const getEditableClass = option("editable_class");
9076
9054
  const getNonEditableRegExps = option("noneditable_regexp");
@@ -9361,7 +9339,7 @@ function requireTinymce() {
9361
9339
  const isRoot2 = (node2) => node2.dom === rootNode;
9362
9340
  return ancestor$5(SugarElement.fromDom(node), isCETrue, isRoot2).map((elm) => elm.dom).getOr(rootNode);
9363
9341
  };
9364
- const isAbsPositionedElement = (node) => isElement$7(node) && get$8(SugarElement.fromDom(node), "position") === "absolute";
9342
+ const isAbsPositionedElement = (node) => isElement$7(node) && get$7(SugarElement.fromDom(node), "position") === "absolute";
9365
9343
  const isInlineBlock = (node, rootNode) => node.parentNode !== rootNode;
9366
9344
  const isInlineAbsPositionedCEF = (node, rootNode) => isContentEditableFalse$6(node) && isAbsPositionedElement(node) && isInlineBlock(node, rootNode);
9367
9345
  const getParentBlock$3 = (node, rootNode) => {
@@ -10251,7 +10229,7 @@ function requireTinymce() {
10251
10229
  const isVariableFormatName = (editor, formatName) => {
10252
10230
  const hasVariableValues = (format) => {
10253
10231
  const isVariableValue = (val) => isFunction(val) || val.length > 1 && val.charAt(0) === "%";
10254
- return exists(["styles", "attributes"], (key) => get$b(format, key).exists((field2) => {
10232
+ return exists(["styles", "attributes"], (key) => get$a(format, key).exists((field2) => {
10255
10233
  const fieldValues = isArray$1(field2) ? field2 : values(field2);
10256
10234
  return exists(fieldValues, isVariableValue);
10257
10235
  }));
@@ -10274,7 +10252,7 @@ function requireTinymce() {
10274
10252
  const isNonWrappingBlockFormat = (format) => isBlockFormat(format) && format.wrapper !== true;
10275
10253
  const isSelectorFormat = (format) => hasNonNullableKey(format, "selector");
10276
10254
  const isInlineFormat = (format) => hasNonNullableKey(format, "inline");
10277
- const isMixedFormat = (format) => isSelectorFormat(format) && isInlineFormat(format) && is$4(get$b(format, "mixed"), true);
10255
+ const isMixedFormat = (format) => isSelectorFormat(format) && isInlineFormat(format) && is$4(get$a(format, "mixed"), true);
10278
10256
  const shouldExpandToSelector = (format) => isSelectorFormat(format) && format.expand !== false && !isInlineFormat(format);
10279
10257
  const getEmptyCaretContainers = (node) => {
10280
10258
  const nodes = [];
@@ -10611,7 +10589,7 @@ function requireTinymce() {
10611
10589
  // Footnootes plugin
10612
10590
  "div.mce-footnotes"
10613
10591
  ];
10614
- const isZeroWidth = (elem) => isText$c(elem) && get$5(elem) === ZWSP$1;
10592
+ const isZeroWidth = (elem) => isText$c(elem) && get$4(elem) === ZWSP$1;
10615
10593
  const context = (editor, elem, wrapName, nodeName) => parentElement(elem).fold(() => "skipping", (parent2) => {
10616
10594
  if (nodeName === "br" || isZeroWidth(elem)) {
10617
10595
  return "valid";
@@ -10636,18 +10614,18 @@ function requireTinymce() {
10636
10614
  const applyAnnotation = (elem, masterUId, data2, annotationName, decorate, directAnnotation) => {
10637
10615
  const { uid: uid2 = masterUId, ...otherData } = data2;
10638
10616
  add$2(elem, annotation());
10639
- set$5(elem, `${dataAnnotationId()}`, uid2);
10640
- set$5(elem, `${dataAnnotation()}`, annotationName);
10617
+ set$4(elem, `${dataAnnotationId()}`, uid2);
10618
+ set$4(elem, `${dataAnnotation()}`, annotationName);
10641
10619
  const { attributes = {}, classes = [] } = decorate(uid2, otherData);
10642
10620
  setAll$1(elem, attributes);
10643
10621
  add$1(elem, classes);
10644
10622
  if (directAnnotation) {
10645
10623
  if (classes.length > 0) {
10646
- set$5(elem, `${dataAnnotationClasses()}`, classes.join(","));
10624
+ set$4(elem, `${dataAnnotationClasses()}`, classes.join(","));
10647
10625
  }
10648
10626
  const attributeNames = keys(attributes);
10649
10627
  if (attributeNames.length > 0) {
10650
- set$5(elem, `${dataAnnotationAttributes()}`, attributeNames.join(","));
10628
+ set$4(elem, `${dataAnnotationAttributes()}`, attributeNames.join(","));
10651
10629
  }
10652
10630
  }
10653
10631
  };
@@ -10727,7 +10705,7 @@ function requireTinymce() {
10727
10705
  }
10728
10706
  if (selection.getRng().collapsed && !hasFakeSelection) {
10729
10707
  const wrapper = makeAnnotation(editor.getDoc(), masterUid, data2, name2, settings.decorate);
10730
- set$4(wrapper, nbsp);
10708
+ set$3(wrapper, nbsp);
10731
10709
  selection.getRng().insertNode(wrapper.dom);
10732
10710
  selection.select(wrapper.dom);
10733
10711
  } else {
@@ -10874,7 +10852,7 @@ function requireTinymce() {
10874
10852
  }
10875
10853
  };
10876
10854
  const clamp$1 = (offset, element) => {
10877
- const max2 = isText$c(element) ? get$5(element).length : children$1(element).length + 1;
10855
+ const max2 = isText$c(element) ? get$4(element).length : children$1(element).length + 1;
10878
10856
  if (offset > max2) {
10879
10857
  return max2;
10880
10858
  } else if (offset < 0) {
@@ -11873,7 +11851,7 @@ function requireTinymce() {
11873
11851
  });
11874
11852
  const find = (element) => {
11875
11853
  const doc = getDocument();
11876
- const scroll = get$6(doc);
11854
+ const scroll = get$5(doc);
11877
11855
  const frames = pathTo(element, Navigation);
11878
11856
  const offset = viewport(element);
11879
11857
  const r2 = foldr(frames, (b, a) => {
@@ -11907,7 +11885,7 @@ function requireTinymce() {
11907
11885
  if (name(last2) === "img") {
11908
11886
  return { element: last2, offset: 1 };
11909
11887
  } else if (isText$c(last2)) {
11910
- return { element: last2, offset: get$5(last2).length };
11888
+ return { element: last2, offset: get$4(last2).length };
11911
11889
  } else {
11912
11890
  return { element: last2, offset: children$1(last2).length };
11913
11891
  }
@@ -11916,7 +11894,7 @@ function requireTinymce() {
11916
11894
  };
11917
11895
  const markerInfo = (element, cleanupFun) => {
11918
11896
  const pos = absolute(element);
11919
- const height = get$7(element);
11897
+ const height = get$6(element);
11920
11898
  return {
11921
11899
  element,
11922
11900
  bottom: pos.top + height,
@@ -11940,7 +11918,7 @@ function requireTinymce() {
11940
11918
  if (fireScrollIntoViewEvent(editor, data2)) {
11941
11919
  return;
11942
11920
  }
11943
- const scrollTop = get$6(doc).top;
11921
+ const scrollTop = get$5(doc).top;
11944
11922
  f(editor, doc, scrollTop, marker, alignToTop);
11945
11923
  fireAfterScrollIntoViewEvent(editor, data2);
11946
11924
  };
@@ -12543,7 +12521,7 @@ function requireTinymce() {
12543
12521
  const trimTemporaryNodes = (tempAttrs, body) => {
12544
12522
  each$e(getTemporaryNodes(tempAttrs, body), (elm) => {
12545
12523
  const element = SugarElement.fromDom(elm);
12546
- if (get$a(element, "data-mce-bogus") === "all") {
12524
+ if (get$9(element, "data-mce-bogus") === "all") {
12547
12525
  remove$8(element);
12548
12526
  } else {
12549
12527
  each$e(tempAttrs, (attr) => {
@@ -12594,7 +12572,7 @@ function requireTinymce() {
12594
12572
  const cleanupBogusElements = (parent2) => {
12595
12573
  const bogusElements = descendants(parent2, "[data-mce-bogus]");
12596
12574
  each$e(bogusElements, (elem) => {
12597
- const bogusValue = get$a(elem, "data-mce-bogus");
12575
+ const bogusValue = get$9(elem, "data-mce-bogus");
12598
12576
  if (bogusValue === "all") {
12599
12577
  remove$8(elem);
12600
12578
  } else if (isBr$6(elem)) {
@@ -12622,13 +12600,13 @@ function requireTinymce() {
12622
12600
  const doc = editor.getDoc();
12623
12601
  const dos = getRootNode(SugarElement.fromDom(editor.getBody()));
12624
12602
  const offscreenDiv = SugarElement.fromTag("div", doc);
12625
- set$5(offscreenDiv, "data-mce-bogus", "all");
12603
+ set$4(offscreenDiv, "data-mce-bogus", "all");
12626
12604
  setAll(offscreenDiv, {
12627
12605
  position: "fixed",
12628
12606
  left: "-9999999px",
12629
12607
  top: "0"
12630
12608
  });
12631
- set$4(offscreenDiv, body.innerHTML);
12609
+ set$3(offscreenDiv, body.innerHTML);
12632
12610
  cleanupBogusElements(offscreenDiv);
12633
12611
  cleanupInputNames(offscreenDiv);
12634
12612
  const root = getContentContainer(dos);
@@ -12992,7 +12970,7 @@ function requireTinymce() {
12992
12970
  return isText$b(container) && (container.data.length === 0 || isZwsp(container.data) && BookmarkManager.isBookmarkNode(container.parentNode));
12993
12971
  };
12994
12972
  const matchesElementPosition = (before2, predicate) => (pos) => getChildNodeAtRelativeOffset(before2 ? 0 : -1, pos).filter(predicate).isSome();
12995
- const isImageBlock = (node) => isImg(node) && get$8(SugarElement.fromDom(node), "display") === "block";
12973
+ const isImageBlock = (node) => isImg(node) && get$7(SugarElement.fromDom(node), "display") === "block";
12996
12974
  const isCefNode = (node) => isContentEditableFalse$a(node) && !isBogusAll(node);
12997
12975
  const isBeforeImageBlock = matchesElementPosition(true, isImageBlock);
12998
12976
  const isAfterImageBlock = matchesElementPosition(false, isImageBlock);
@@ -13053,7 +13031,7 @@ function requireTinymce() {
13053
13031
  }
13054
13032
  };
13055
13033
  const isPreValue = (value2) => contains$2(["pre", "pre-wrap"], value2);
13056
- const isInPre = (pos) => getElementFromPosition(pos).bind((elm) => closest$5(elm, isElement$8)).exists((elm) => isPreValue(get$8(elm, "white-space")));
13034
+ const isInPre = (pos) => getElementFromPosition(pos).bind((elm) => closest$5(elm, isElement$8)).exists((elm) => isPreValue(get$7(elm, "white-space")));
13057
13035
  const isAtBeginningOfBody = (root, pos) => prevPosition(root.dom, pos).isNone();
13058
13036
  const isAtEndOfBody = (root, pos) => nextPosition(root.dom, pos).isNone();
13059
13037
  const isAtLineBoundary = (root, pos, schema) => isAtBeginningOfBody(root, pos) || isAtEndOfBody(root, pos) || isAtStartOfBlock(root, pos, schema) || isAtEndOfBlock(root, pos, schema) || isAfterBr(root, pos, schema) || isBeforeBr$1(root, pos, schema);
@@ -13579,7 +13557,7 @@ function requireTinymce() {
13579
13557
  editor.selection.collapse(true);
13580
13558
  }
13581
13559
  if (selectedCells.length > 1 && exists(selectedCells, (cell2) => eq(cell2, selectedNode))) {
13582
- set$5(selectedNode, "data-mce-selected", "1");
13560
+ set$4(selectedNode, "data-mce-selected", "1");
13583
13561
  }
13584
13562
  };
13585
13563
  const emptySingleTableCells = (editor, cells2, outsideDetails) => Optional.some(() => {
@@ -14132,7 +14110,7 @@ function requireTinymce() {
14132
14110
  return Optional.none();
14133
14111
  }
14134
14112
  };
14135
- const normalizeNbsps = (node) => set$2(node, get$5(node).replace(new RegExp(`${nbsp}$`), " "));
14113
+ const normalizeNbsps = (node) => set$1(node, get$4(node).replace(new RegExp(`${nbsp}$`), " "));
14136
14114
  const normalizeNbspsBetween = (editor, caretContainer) => {
14137
14115
  const handler = () => {
14138
14116
  if (caretContainer !== null && !editor.dom.isEmpty(caretContainer)) {
@@ -15352,13 +15330,12 @@ function requireTinymce() {
15352
15330
  const uniqueId$1 = (prefix) => {
15353
15331
  return "blobid" + count$1++;
15354
15332
  };
15355
- const utf8Encode = (str) => foldl(new window.TextEncoder().encode(str), (acc, charCode) => acc + String.fromCharCode(charCode), "");
15356
15333
  const processDataUri = (dataUri, base64Only, generateBlobInfo) => {
15357
15334
  return parseDataUri(dataUri).bind(({ data: data2, type: type2, base64Encoded }) => {
15358
15335
  if (base64Only && !base64Encoded) {
15359
15336
  return Optional.none();
15360
15337
  } else {
15361
- const base64 = base64Encoded ? data2 : btoa(utf8Encode(data2));
15338
+ const base64 = base64Encoded ? data2 : btoa(data2);
15362
15339
  return generateBlobInfo(base64, type2);
15363
15340
  }
15364
15341
  });
@@ -15393,7 +15370,7 @@ function requireTinymce() {
15393
15370
  }
15394
15371
  };
15395
15372
  const hostCaptureRegex = /^(?:(?:(?:[A-Za-z][A-Za-z\d.+-]{0,14}:\/\/(?:[-.~*+=!&;:'%@?^${}(),\w]+@)?|www\.|[-;:&=+$,.\w]+@)([A-Za-z\d-]+(?:\.[A-Za-z\d-]+)*))(?::\d+)?(?:\/(?:[-.~*+=!;:'%@$(),\/\w]*[-~*+=%@$()\/\w])?)?(?:\?(?:[-.~*+=!&;:'%@?^${}(),\/\w]+)?)?(?:#(?:[-.~*+=!&;:'%@?^${}(),\/\w]+)?)?)$/;
15396
- const extractHost = (url) => Optional.from(url.match(hostCaptureRegex)).bind((ms) => get$c(ms, 1)).map((h) => startsWith(h, "www.") ? h.substring(4) : h);
15373
+ const extractHost = (url) => Optional.from(url.match(hostCaptureRegex)).bind((ms) => get$b(ms, 1)).map((h) => startsWith(h, "www.") ? h.substring(4) : h);
15397
15374
  const sandboxIframe = (iframeNode, exclusions) => {
15398
15375
  if (Optional.from(iframeNode.attr("src")).bind(extractHost).forall((host) => !contains$2(exclusions, host))) {
15399
15376
  iframeNode.attr("sandbox", "");
@@ -15553,49 +15530,22 @@ function requireTinymce() {
15553
15530
  parser.addNodeFilter("iframe", (nodes) => each$e(nodes, (node) => sandboxIframe(node, sandboxIframesExclusions)));
15554
15531
  }
15555
15532
  };
15556
- function _arrayLikeToArray(r2, a) {
15557
- (null == a || a > r2.length) && (a = r2.length);
15558
- for (var e = 0, n = Array(a); e < a; e++) n[e] = r2[e];
15559
- return n;
15560
- }
15561
- function _arrayWithHoles(r2) {
15562
- if (Array.isArray(r2)) return r2;
15563
- }
15564
- function _iterableToArrayLimit(r2, l) {
15565
- var t = null == r2 ? null : "undefined" != typeof Symbol && r2[Symbol.iterator] || r2["@@iterator"];
15566
- if (null != t) {
15567
- var e, n, i, u, a = [], f = true, o = false;
15568
- try {
15569
- if (i = (t = t.call(r2)).next, 0 === l) ;
15570
- else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = true) ;
15571
- } catch (r3) {
15572
- o = true, n = r3;
15573
- } finally {
15574
- try {
15575
- if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
15576
- } finally {
15577
- if (o) throw n;
15578
- }
15579
- }
15580
- return a;
15581
- }
15582
- }
15583
- function _nonIterableRest() {
15584
- throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
15585
- }
15586
- function _slicedToArray(r2, e) {
15587
- return _arrayWithHoles(r2) || _iterableToArrayLimit(r2, e) || _unsupportedIterableToArray(r2, e) || _nonIterableRest();
15588
- }
15589
- function _unsupportedIterableToArray(r2, a) {
15590
- if (r2) {
15591
- if ("string" == typeof r2) return _arrayLikeToArray(r2, a);
15592
- var t = {}.toString.call(r2).slice(8, -1);
15593
- return "Object" === t && r2.constructor && (t = r2.constructor.name), "Map" === t || "Set" === t ? Array.from(r2) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r2, a) : void 0;
15594
- }
15595
- }
15596
- const entries = Object.entries, setPrototypeOf = Object.setPrototypeOf, isFrozen = Object.isFrozen, getPrototypeOf = Object.getPrototypeOf, getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
15597
- let freeze = Object.freeze, seal = Object.seal, create$7 = Object.create;
15598
- let _ref = typeof Reflect !== "undefined" && Reflect, apply = _ref.apply, construct = _ref.construct;
15533
+ const {
15534
+ entries,
15535
+ setPrototypeOf,
15536
+ isFrozen,
15537
+ getPrototypeOf,
15538
+ getOwnPropertyDescriptor
15539
+ } = Object;
15540
+ let {
15541
+ freeze,
15542
+ seal,
15543
+ create: create$7
15544
+ } = Object;
15545
+ let {
15546
+ apply,
15547
+ construct
15548
+ } = typeof Reflect !== "undefined" && Reflect;
15599
15549
  if (!freeze) {
15600
15550
  freeze = function freeze2(x) {
15601
15551
  return x;
@@ -15607,18 +15557,12 @@ function requireTinymce() {
15607
15557
  };
15608
15558
  }
15609
15559
  if (!apply) {
15610
- apply = function apply2(func, thisArg) {
15611
- for (var _len = arguments.length, args = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
15612
- args[_key - 2] = arguments[_key];
15613
- }
15614
- return func.apply(thisArg, args);
15560
+ apply = function apply2(fun, thisValue, args) {
15561
+ return fun.apply(thisValue, args);
15615
15562
  };
15616
15563
  }
15617
15564
  if (!construct) {
15618
- construct = function construct2(Func) {
15619
- for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
15620
- args[_key2 - 1] = arguments[_key2];
15621
- }
15565
+ construct = function construct2(Func, args) {
15622
15566
  return new Func(...args);
15623
15567
  };
15624
15568
  }
@@ -15627,19 +15571,13 @@ function requireTinymce() {
15627
15571
  const arrayPop = unapply(Array.prototype.pop);
15628
15572
  const arrayPush = unapply(Array.prototype.push);
15629
15573
  const arraySplice = unapply(Array.prototype.splice);
15630
- const arrayIsArray = Array.isArray;
15631
15574
  const stringToLowerCase = unapply(String.prototype.toLowerCase);
15632
15575
  const stringToString = unapply(String.prototype.toString);
15633
15576
  const stringMatch = unapply(String.prototype.match);
15634
15577
  const stringReplace = unapply(String.prototype.replace);
15635
15578
  const stringIndexOf = unapply(String.prototype.indexOf);
15636
15579
  const stringTrim = unapply(String.prototype.trim);
15637
- const numberToString = unapply(Number.prototype.toString);
15638
- const booleanToString = unapply(Boolean.prototype.toString);
15639
- const bigintToString = typeof BigInt === "undefined" ? null : unapply(BigInt.prototype.toString);
15640
- const symbolToString = typeof Symbol === "undefined" ? null : unapply(Symbol.prototype.toString);
15641
15580
  const objectHasOwnProperty = unapply(Object.prototype.hasOwnProperty);
15642
- const objectToString = unapply(Object.prototype.toString);
15643
15581
  const regExpTest = unapply(RegExp.prototype.test);
15644
15582
  const typeErrorCreate = unconstruct(TypeError);
15645
15583
  function unapply(func) {
@@ -15647,18 +15585,18 @@ function requireTinymce() {
15647
15585
  if (thisArg instanceof RegExp) {
15648
15586
  thisArg.lastIndex = 0;
15649
15587
  }
15650
- for (var _len3 = arguments.length, args = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
15651
- args[_key3 - 1] = arguments[_key3];
15588
+ for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
15589
+ args[_key - 1] = arguments[_key];
15652
15590
  }
15653
15591
  return apply(func, thisArg, args);
15654
15592
  };
15655
15593
  }
15656
- function unconstruct(Func) {
15594
+ function unconstruct(func) {
15657
15595
  return function() {
15658
- for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
15659
- args[_key4] = arguments[_key4];
15596
+ for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
15597
+ args[_key2] = arguments[_key2];
15660
15598
  }
15661
- return construct(Func, args);
15599
+ return construct(func, args);
15662
15600
  };
15663
15601
  }
15664
15602
  function addToSet(set2, array) {
@@ -15666,9 +15604,6 @@ function requireTinymce() {
15666
15604
  if (setPrototypeOf) {
15667
15605
  setPrototypeOf(set2, null);
15668
15606
  }
15669
- if (!arrayIsArray(array)) {
15670
- return set2;
15671
- }
15672
15607
  let l = array.length;
15673
15608
  while (l--) {
15674
15609
  let element = array[l];
@@ -15696,13 +15631,10 @@ function requireTinymce() {
15696
15631
  }
15697
15632
  function clone(object) {
15698
15633
  const newObject = create$7(null);
15699
- for (const _ref2 of entries(object)) {
15700
- var _ref3 = _slicedToArray(_ref2, 2);
15701
- const property = _ref3[0];
15702
- const value2 = _ref3[1];
15634
+ for (const [property, value2] of entries(object)) {
15703
15635
  const isPropertyExist = objectHasOwnProperty(object, property);
15704
15636
  if (isPropertyExist) {
15705
- if (arrayIsArray(value2)) {
15637
+ if (Array.isArray(value2)) {
15706
15638
  newObject[property] = cleanArray(value2);
15707
15639
  } else if (value2 && typeof value2 === "object" && value2.constructor === Object) {
15708
15640
  newObject[property] = clone(value2);
@@ -15713,44 +15645,6 @@ function requireTinymce() {
15713
15645
  }
15714
15646
  return newObject;
15715
15647
  }
15716
- function stringifyValue(value2) {
15717
- switch (typeof value2) {
15718
- case "string": {
15719
- return value2;
15720
- }
15721
- case "number": {
15722
- return numberToString(value2);
15723
- }
15724
- case "boolean": {
15725
- return booleanToString(value2);
15726
- }
15727
- case "bigint": {
15728
- return bigintToString ? bigintToString(value2) : "0";
15729
- }
15730
- case "symbol": {
15731
- return symbolToString ? symbolToString(value2) : "Symbol()";
15732
- }
15733
- case "undefined": {
15734
- return objectToString(value2);
15735
- }
15736
- case "function":
15737
- case "object": {
15738
- if (value2 === null) {
15739
- return objectToString(value2);
15740
- }
15741
- const valueAsRecord = value2;
15742
- const valueToString = lookupGetter(valueAsRecord, "toString");
15743
- if (typeof valueToString === "function") {
15744
- const stringified = valueToString(valueAsRecord);
15745
- return typeof stringified === "string" ? stringified : objectToString(stringified);
15746
- }
15747
- return objectToString(value2);
15748
- }
15749
- default: {
15750
- return objectToString(value2);
15751
- }
15752
- }
15753
- }
15754
15648
  function lookupGetter(object, prop) {
15755
15649
  while (object !== null) {
15756
15650
  const desc = getOwnPropertyDescriptor(object, prop);
@@ -15769,28 +15663,20 @@ function requireTinymce() {
15769
15663
  }
15770
15664
  return fallbackValue;
15771
15665
  }
15772
- function isRegex(value2) {
15773
- try {
15774
- regExpTest(value2, "");
15775
- return true;
15776
- } catch (_unused) {
15777
- return false;
15778
- }
15779
- }
15780
- const html$1 = freeze(["a", "abbr", "acronym", "address", "area", "article", "aside", "audio", "b", "bdi", "bdo", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "content", "data", "datalist", "dd", "decorator", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "element", "em", "fieldset", "figcaption", "figure", "font", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "hgroup", "hr", "html", "i", "img", "input", "ins", "kbd", "label", "legend", "li", "main", "map", "mark", "marquee", "menu", "menuitem", "meter", "nav", "nobr", "ol", "optgroup", "option", "output", "p", "picture", "pre", "progress", "q", "rp", "rt", "ruby", "s", "samp", "search", "section", "select", "shadow", "slot", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "tr", "track", "tt", "u", "ul", "var", "video", "wbr"]);
15781
- const svg$1 = freeze(["svg", "a", "altglyph", "altglyphdef", "altglyphitem", "animatecolor", "animatemotion", "animatetransform", "circle", "clippath", "defs", "desc", "ellipse", "enterkeyhint", "exportparts", "filter", "font", "g", "glyph", "glyphref", "hkern", "image", "inputmode", "line", "lineargradient", "marker", "mask", "metadata", "mpath", "part", "path", "pattern", "polygon", "polyline", "radialgradient", "rect", "stop", "style", "switch", "symbol", "text", "textpath", "title", "tref", "tspan", "view", "vkern"]);
15666
+ const html$1 = freeze(["a", "abbr", "acronym", "address", "area", "article", "aside", "audio", "b", "bdi", "bdo", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "content", "data", "datalist", "dd", "decorator", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "element", "em", "fieldset", "figcaption", "figure", "font", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "hgroup", "hr", "html", "i", "img", "input", "ins", "kbd", "label", "legend", "li", "main", "map", "mark", "marquee", "menu", "menuitem", "meter", "nav", "nobr", "ol", "optgroup", "option", "output", "p", "picture", "pre", "progress", "q", "rp", "rt", "ruby", "s", "samp", "section", "select", "shadow", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "tr", "track", "tt", "u", "ul", "var", "video", "wbr"]);
15667
+ const svg$1 = freeze(["svg", "a", "altglyph", "altglyphdef", "altglyphitem", "animatecolor", "animatemotion", "animatetransform", "circle", "clippath", "defs", "desc", "ellipse", "filter", "font", "g", "glyph", "glyphref", "hkern", "image", "line", "lineargradient", "marker", "mask", "metadata", "mpath", "path", "pattern", "polygon", "polyline", "radialgradient", "rect", "stop", "style", "switch", "symbol", "text", "textpath", "title", "tref", "tspan", "view", "vkern"]);
15782
15668
  const svgFilters = freeze(["feBlend", "feColorMatrix", "feComponentTransfer", "feComposite", "feConvolveMatrix", "feDiffuseLighting", "feDisplacementMap", "feDistantLight", "feDropShadow", "feFlood", "feFuncA", "feFuncB", "feFuncG", "feFuncR", "feGaussianBlur", "feImage", "feMerge", "feMergeNode", "feMorphology", "feOffset", "fePointLight", "feSpecularLighting", "feSpotLight", "feTile", "feTurbulence"]);
15783
15669
  const svgDisallowed = freeze(["animate", "color-profile", "cursor", "discard", "font-face", "font-face-format", "font-face-name", "font-face-src", "font-face-uri", "foreignobject", "hatch", "hatchpath", "mesh", "meshgradient", "meshpatch", "meshrow", "missing-glyph", "script", "set", "solidcolor", "unknown", "use"]);
15784
15670
  const mathMl$1 = freeze(["math", "menclose", "merror", "mfenced", "mfrac", "mglyph", "mi", "mlabeledtr", "mmultiscripts", "mn", "mo", "mover", "mpadded", "mphantom", "mroot", "mrow", "ms", "mspace", "msqrt", "mstyle", "msub", "msup", "msubsup", "mtable", "mtd", "mtext", "mtr", "munder", "munderover", "mprescripts"]);
15785
15671
  const mathMlDisallowed = freeze(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]);
15786
15672
  const text = freeze(["#text"]);
15787
- const html = freeze(["accept", "action", "align", "alt", "autocapitalize", "autocomplete", "autopictureinpicture", "autoplay", "background", "bgcolor", "border", "capture", "cellpadding", "cellspacing", "checked", "cite", "class", "clear", "color", "cols", "colspan", "command", "commandfor", "controls", "controlslist", "coords", "crossorigin", "datetime", "decoding", "default", "dir", "disabled", "disablepictureinpicture", "disableremoteplayback", "download", "draggable", "enctype", "enterkeyhint", "exportparts", "face", "for", "headers", "height", "hidden", "high", "href", "hreflang", "id", "inert", "inputmode", "integrity", "ismap", "kind", "label", "lang", "list", "loading", "loop", "low", "max", "maxlength", "media", "method", "min", "minlength", "multiple", "muted", "name", "nonce", "noshade", "novalidate", "nowrap", "open", "optimum", "part", "pattern", "placeholder", "playsinline", "popover", "popovertarget", "popovertargetaction", "poster", "preload", "pubdate", "radiogroup", "readonly", "rel", "required", "rev", "reversed", "role", "rows", "rowspan", "spellcheck", "scope", "selected", "shape", "size", "sizes", "slot", "span", "srclang", "start", "src", "srcset", "step", "style", "summary", "tabindex", "title", "translate", "type", "usemap", "valign", "value", "width", "wrap", "xmlns"]);
15788
- const svg = freeze(["accent-height", "accumulate", "additive", "alignment-baseline", "amplitude", "ascent", "attributename", "attributetype", "azimuth", "basefrequency", "baseline-shift", "begin", "bias", "by", "class", "clip", "clippathunits", "clip-path", "clip-rule", "color", "color-interpolation", "color-interpolation-filters", "color-profile", "color-rendering", "cx", "cy", "d", "dx", "dy", "diffuseconstant", "direction", "display", "divisor", "dur", "edgemode", "elevation", "end", "exponent", "fill", "fill-opacity", "fill-rule", "filter", "filterunits", "flood-color", "flood-opacity", "font-family", "font-size", "font-size-adjust", "font-stretch", "font-style", "font-variant", "font-weight", "fx", "fy", "g1", "g2", "glyph-name", "glyphref", "gradientunits", "gradienttransform", "height", "href", "id", "image-rendering", "in", "in2", "intercept", "k", "k1", "k2", "k3", "k4", "kerning", "keypoints", "keysplines", "keytimes", "lang", "lengthadjust", "letter-spacing", "kernelmatrix", "kernelunitlength", "lighting-color", "local", "marker-end", "marker-mid", "marker-start", "markerheight", "markerunits", "markerwidth", "maskcontentunits", "maskunits", "max", "mask", "mask-type", "media", "method", "mode", "min", "name", "numoctaves", "offset", "operator", "opacity", "order", "orient", "orientation", "origin", "overflow", "paint-order", "path", "pathlength", "patterncontentunits", "patterntransform", "patternunits", "points", "preservealpha", "preserveaspectratio", "primitiveunits", "r", "rx", "ry", "radius", "refx", "refy", "repeatcount", "repeatdur", "restart", "result", "rotate", "scale", "seed", "shape-rendering", "slope", "specularconstant", "specularexponent", "spreadmethod", "startoffset", "stddeviation", "stitchtiles", "stop-color", "stop-opacity", "stroke-dasharray", "stroke-dashoffset", "stroke-linecap", "stroke-linejoin", "stroke-miterlimit", "stroke-opacity", "stroke", "stroke-width", "style", "surfacescale", "systemlanguage", "tabindex", "tablevalues", "targetx", "targety", "transform", "transform-origin", "text-anchor", "text-decoration", "text-rendering", "textlength", "type", "u1", "u2", "unicode", "values", "viewbox", "visibility", "version", "vert-adv-y", "vert-origin-x", "vert-origin-y", "width", "word-spacing", "wrap", "writing-mode", "xchannelselector", "ychannelselector", "x", "x1", "x2", "xmlns", "y", "y1", "y2", "z", "zoomandpan"]);
15789
- const mathMl = freeze(["accent", "accentunder", "align", "bevelled", "close", "columnalign", "columnlines", "columnspacing", "columnspan", "denomalign", "depth", "dir", "display", "displaystyle", "encoding", "fence", "frame", "height", "href", "id", "largeop", "length", "linethickness", "lquote", "lspace", "mathbackground", "mathcolor", "mathsize", "mathvariant", "maxsize", "minsize", "movablelimits", "notation", "numalign", "open", "rowalign", "rowlines", "rowspacing", "rowspan", "rspace", "rquote", "scriptlevel", "scriptminsize", "scriptsizemultiplier", "selection", "separator", "separators", "stretchy", "subscriptshift", "supscriptshift", "symmetric", "voffset", "width", "xmlns"]);
15673
+ const html = freeze(["accept", "action", "align", "alt", "autocapitalize", "autocomplete", "autopictureinpicture", "autoplay", "background", "bgcolor", "border", "capture", "cellpadding", "cellspacing", "checked", "cite", "class", "clear", "color", "cols", "colspan", "controls", "controlslist", "coords", "crossorigin", "datetime", "decoding", "default", "dir", "disabled", "disablepictureinpicture", "disableremoteplayback", "download", "draggable", "enctype", "enterkeyhint", "face", "for", "headers", "height", "hidden", "high", "href", "hreflang", "id", "inputmode", "integrity", "ismap", "kind", "label", "lang", "list", "loading", "loop", "low", "max", "maxlength", "media", "method", "min", "minlength", "multiple", "muted", "name", "nonce", "noshade", "novalidate", "nowrap", "open", "optimum", "pattern", "placeholder", "playsinline", "popover", "popovertarget", "popovertargetaction", "poster", "preload", "pubdate", "radiogroup", "readonly", "rel", "required", "rev", "reversed", "role", "rows", "rowspan", "spellcheck", "scope", "selected", "shape", "size", "sizes", "span", "srclang", "start", "src", "srcset", "step", "style", "summary", "tabindex", "title", "translate", "type", "usemap", "valign", "value", "width", "wrap", "xmlns", "slot"]);
15674
+ const svg = freeze(["accent-height", "accumulate", "additive", "alignment-baseline", "amplitude", "ascent", "attributename", "attributetype", "azimuth", "basefrequency", "baseline-shift", "begin", "bias", "by", "class", "clip", "clippathunits", "clip-path", "clip-rule", "color", "color-interpolation", "color-interpolation-filters", "color-profile", "color-rendering", "cx", "cy", "d", "dx", "dy", "diffuseconstant", "direction", "display", "divisor", "dur", "edgemode", "elevation", "end", "exponent", "fill", "fill-opacity", "fill-rule", "filter", "filterunits", "flood-color", "flood-opacity", "font-family", "font-size", "font-size-adjust", "font-stretch", "font-style", "font-variant", "font-weight", "fx", "fy", "g1", "g2", "glyph-name", "glyphref", "gradientunits", "gradienttransform", "height", "href", "id", "image-rendering", "in", "in2", "intercept", "k", "k1", "k2", "k3", "k4", "kerning", "keypoints", "keysplines", "keytimes", "lang", "lengthadjust", "letter-spacing", "kernelmatrix", "kernelunitlength", "lighting-color", "local", "marker-end", "marker-mid", "marker-start", "markerheight", "markerunits", "markerwidth", "maskcontentunits", "maskunits", "max", "mask", "media", "method", "mode", "min", "name", "numoctaves", "offset", "operator", "opacity", "order", "orient", "orientation", "origin", "overflow", "paint-order", "path", "pathlength", "patterncontentunits", "patterntransform", "patternunits", "points", "preservealpha", "preserveaspectratio", "primitiveunits", "r", "rx", "ry", "radius", "refx", "refy", "repeatcount", "repeatdur", "restart", "result", "rotate", "scale", "seed", "shape-rendering", "slope", "specularconstant", "specularexponent", "spreadmethod", "startoffset", "stddeviation", "stitchtiles", "stop-color", "stop-opacity", "stroke-dasharray", "stroke-dashoffset", "stroke-linecap", "stroke-linejoin", "stroke-miterlimit", "stroke-opacity", "stroke", "stroke-width", "style", "surfacescale", "systemlanguage", "tabindex", "tablevalues", "targetx", "targety", "transform", "transform-origin", "text-anchor", "text-decoration", "text-rendering", "textlength", "type", "u1", "u2", "unicode", "values", "viewbox", "visibility", "version", "vert-adv-y", "vert-origin-x", "vert-origin-y", "width", "word-spacing", "wrap", "writing-mode", "xchannelselector", "ychannelselector", "x", "x1", "x2", "xmlns", "y", "y1", "y2", "z", "zoomandpan"]);
15675
+ const mathMl = freeze(["accent", "accentunder", "align", "bevelled", "close", "columnsalign", "columnlines", "columnspan", "denomalign", "depth", "dir", "display", "displaystyle", "encoding", "fence", "frame", "height", "href", "id", "largeop", "length", "linethickness", "lspace", "lquote", "mathbackground", "mathcolor", "mathsize", "mathvariant", "maxsize", "minsize", "movablelimits", "notation", "numalign", "open", "rowalign", "rowlines", "rowspacing", "rowspan", "rspace", "rquote", "scriptlevel", "scriptminsize", "scriptsizemultiplier", "selection", "separator", "separators", "stretchy", "subscriptshift", "supscriptshift", "symmetric", "voffset", "width", "xmlns"]);
15790
15676
  const xml = freeze(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]);
15791
- const MUSTACHE_EXPR = seal(/{{[\w\W]*|^[\w\W]*}}/g);
15792
- const ERB_EXPR = seal(/<%[\w\W]*|^[\w\W]*%>/g);
15793
- const TMPLIT_EXPR = seal(/\${[\w\W]*/g);
15677
+ const MUSTACHE_EXPR = seal(/\{\{[\w\W]*|[\w\W]*\}\}/gm);
15678
+ const ERB_EXPR = seal(/<%[\w\W]*|[\w\W]*%>/gm);
15679
+ const TMPLIT_EXPR = seal(/\$\{[\w\W]*/gm);
15794
15680
  const DATA_ATTR = seal(/^data-[\-\w.\u00B7-\uFFFF]+$/);
15795
15681
  const ARIA_ATTR = seal(/^aria-[\-\w]+$/);
15796
15682
  const IS_ALLOWED_URI = seal(
@@ -15804,6 +15690,19 @@ function requireTinymce() {
15804
15690
  );
15805
15691
  const DOCTYPE_NAME = seal(/^html$/i);
15806
15692
  const CUSTOM_ELEMENT = seal(/^[a-z][.\w]*(-[.\w]+)+$/i);
15693
+ var EXPRESSIONS = /* @__PURE__ */ Object.freeze({
15694
+ __proto__: null,
15695
+ ARIA_ATTR,
15696
+ ATTR_WHITESPACE,
15697
+ CUSTOM_ELEMENT,
15698
+ DATA_ATTR,
15699
+ DOCTYPE_NAME,
15700
+ ERB_EXPR,
15701
+ IS_ALLOWED_URI,
15702
+ IS_SCRIPT_OR_DATA,
15703
+ MUSTACHE_EXPR,
15704
+ TMPLIT_EXPR
15705
+ });
15807
15706
  const NODE_TYPE = {
15808
15707
  element: 1,
15809
15708
  text: 3,
@@ -15855,23 +15754,34 @@ function requireTinymce() {
15855
15754
  function createDOMPurify() {
15856
15755
  let window2 = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : getGlobal();
15857
15756
  const DOMPurify = (root) => createDOMPurify(root);
15858
- DOMPurify.version = "3.4.5";
15757
+ DOMPurify.version = "3.2.6";
15859
15758
  DOMPurify.removed = [];
15860
15759
  if (!window2 || !window2.document || window2.document.nodeType !== NODE_TYPE.document || !window2.Element) {
15861
15760
  DOMPurify.isSupported = false;
15862
15761
  return DOMPurify;
15863
15762
  }
15864
- let document2 = window2.document;
15763
+ let {
15764
+ document: document2
15765
+ } = window2;
15865
15766
  const originalDocument = document2;
15866
15767
  const currentScript = originalDocument.currentScript;
15867
- const DocumentFragment = window2.DocumentFragment, HTMLTemplateElement = window2.HTMLTemplateElement, Node = window2.Node, Element = window2.Element, NodeFilter2 = window2.NodeFilter, _window$NamedNodeMap = window2.NamedNodeMap, NamedNodeMap = _window$NamedNodeMap === void 0 ? window2.NamedNodeMap || window2.MozNamedAttrMap : _window$NamedNodeMap, HTMLFormElement = window2.HTMLFormElement, DOMParser2 = window2.DOMParser, trustedTypes = window2.trustedTypes;
15768
+ const {
15769
+ DocumentFragment,
15770
+ HTMLTemplateElement,
15771
+ Node,
15772
+ Element,
15773
+ NodeFilter: NodeFilter2,
15774
+ NamedNodeMap = window2.NamedNodeMap || window2.MozNamedAttrMap,
15775
+ HTMLFormElement,
15776
+ DOMParser: DOMParser2,
15777
+ trustedTypes
15778
+ } = window2;
15868
15779
  const ElementPrototype = Element.prototype;
15869
15780
  const cloneNode = lookupGetter(ElementPrototype, "cloneNode");
15870
15781
  const remove2 = lookupGetter(ElementPrototype, "remove");
15871
15782
  const getNextSibling = lookupGetter(ElementPrototype, "nextSibling");
15872
15783
  const getChildNodes2 = lookupGetter(ElementPrototype, "childNodes");
15873
15784
  const getParentNode = lookupGetter(ElementPrototype, "parentNode");
15874
- const getNodeType = Node && Node.prototype ? lookupGetter(Node.prototype, "nodeType") : null;
15875
15785
  if (typeof HTMLTemplateElement === "function") {
15876
15786
  const template = document2.createElement("template");
15877
15787
  if (template.content && template.content.ownerDocument) {
@@ -15880,12 +15790,30 @@ function requireTinymce() {
15880
15790
  }
15881
15791
  let trustedTypesPolicy;
15882
15792
  let emptyHTML = "";
15883
- const _document = document2, implementation = _document.implementation, createNodeIterator = _document.createNodeIterator, createDocumentFragment = _document.createDocumentFragment, getElementsByTagName = _document.getElementsByTagName;
15884
- const importNode2 = originalDocument.importNode;
15793
+ const {
15794
+ implementation,
15795
+ createNodeIterator,
15796
+ createDocumentFragment,
15797
+ getElementsByTagName
15798
+ } = document2;
15799
+ const {
15800
+ importNode: importNode2
15801
+ } = originalDocument;
15885
15802
  let hooks = _createHooksMap();
15886
15803
  DOMPurify.isSupported = typeof entries === "function" && typeof getParentNode === "function" && implementation && implementation.createHTMLDocument !== void 0;
15887
- const MUSTACHE_EXPR$1 = MUSTACHE_EXPR, ERB_EXPR$1 = ERB_EXPR, TMPLIT_EXPR$1 = TMPLIT_EXPR, DATA_ATTR$1 = DATA_ATTR, ARIA_ATTR$1 = ARIA_ATTR, IS_SCRIPT_OR_DATA$1 = IS_SCRIPT_OR_DATA, ATTR_WHITESPACE$1 = ATTR_WHITESPACE, CUSTOM_ELEMENT$1 = CUSTOM_ELEMENT;
15888
- let IS_ALLOWED_URI$1 = IS_ALLOWED_URI;
15804
+ const {
15805
+ MUSTACHE_EXPR: MUSTACHE_EXPR2,
15806
+ ERB_EXPR: ERB_EXPR2,
15807
+ TMPLIT_EXPR: TMPLIT_EXPR2,
15808
+ DATA_ATTR: DATA_ATTR2,
15809
+ ARIA_ATTR: ARIA_ATTR2,
15810
+ IS_SCRIPT_OR_DATA: IS_SCRIPT_OR_DATA2,
15811
+ ATTR_WHITESPACE: ATTR_WHITESPACE2,
15812
+ CUSTOM_ELEMENT: CUSTOM_ELEMENT2
15813
+ } = EXPRESSIONS;
15814
+ let {
15815
+ IS_ALLOWED_URI: IS_ALLOWED_URI$1
15816
+ } = EXPRESSIONS;
15889
15817
  let ALLOWED_TAGS = null;
15890
15818
  const DEFAULT_ALLOWED_TAGS = addToSet({}, [...html$1, ...svg$1, ...svgFilters, ...mathMl$1, ...text]);
15891
15819
  let ALLOWED_ATTR = null;
@@ -15912,20 +15840,6 @@ function requireTinymce() {
15912
15840
  }));
15913
15841
  let FORBID_TAGS = null;
15914
15842
  let FORBID_ATTR = null;
15915
- const EXTRA_ELEMENT_HANDLING = Object.seal(create$7(null, {
15916
- tagCheck: {
15917
- writable: true,
15918
- configurable: false,
15919
- enumerable: true,
15920
- value: null
15921
- },
15922
- attributeCheck: {
15923
- writable: true,
15924
- configurable: false,
15925
- enumerable: true,
15926
- value: null
15927
- }
15928
- }));
15929
15843
  let ALLOW_ARIA_ATTR = true;
15930
15844
  let ALLOW_DATA_ATTR = true;
15931
15845
  let ALLOW_UNKNOWN_PROTOCOLS = false;
@@ -15981,15 +15895,15 @@ function requireTinymce() {
15981
15895
  PARSER_MEDIA_TYPE = // eslint-disable-next-line unicorn/prefer-includes
15982
15896
  SUPPORTED_PARSER_MEDIA_TYPES.indexOf(cfg.PARSER_MEDIA_TYPE) === -1 ? DEFAULT_PARSER_MEDIA_TYPE : cfg.PARSER_MEDIA_TYPE;
15983
15897
  transformCaseFunc = PARSER_MEDIA_TYPE === "application/xhtml+xml" ? stringToString : stringToLowerCase;
15984
- ALLOWED_TAGS = objectHasOwnProperty(cfg, "ALLOWED_TAGS") && arrayIsArray(cfg.ALLOWED_TAGS) ? addToSet({}, cfg.ALLOWED_TAGS, transformCaseFunc) : DEFAULT_ALLOWED_TAGS;
15985
- ALLOWED_ATTR = objectHasOwnProperty(cfg, "ALLOWED_ATTR") && arrayIsArray(cfg.ALLOWED_ATTR) ? addToSet({}, cfg.ALLOWED_ATTR, transformCaseFunc) : DEFAULT_ALLOWED_ATTR;
15986
- ALLOWED_NAMESPACES = objectHasOwnProperty(cfg, "ALLOWED_NAMESPACES") && arrayIsArray(cfg.ALLOWED_NAMESPACES) ? addToSet({}, cfg.ALLOWED_NAMESPACES, stringToString) : DEFAULT_ALLOWED_NAMESPACES;
15987
- URI_SAFE_ATTRIBUTES = objectHasOwnProperty(cfg, "ADD_URI_SAFE_ATTR") && arrayIsArray(cfg.ADD_URI_SAFE_ATTR) ? addToSet(clone(DEFAULT_URI_SAFE_ATTRIBUTES), cfg.ADD_URI_SAFE_ATTR, transformCaseFunc) : DEFAULT_URI_SAFE_ATTRIBUTES;
15988
- DATA_URI_TAGS = objectHasOwnProperty(cfg, "ADD_DATA_URI_TAGS") && arrayIsArray(cfg.ADD_DATA_URI_TAGS) ? addToSet(clone(DEFAULT_DATA_URI_TAGS), cfg.ADD_DATA_URI_TAGS, transformCaseFunc) : DEFAULT_DATA_URI_TAGS;
15989
- FORBID_CONTENTS = objectHasOwnProperty(cfg, "FORBID_CONTENTS") && arrayIsArray(cfg.FORBID_CONTENTS) ? addToSet({}, cfg.FORBID_CONTENTS, transformCaseFunc) : DEFAULT_FORBID_CONTENTS;
15990
- FORBID_TAGS = objectHasOwnProperty(cfg, "FORBID_TAGS") && arrayIsArray(cfg.FORBID_TAGS) ? addToSet({}, cfg.FORBID_TAGS, transformCaseFunc) : clone({});
15991
- FORBID_ATTR = objectHasOwnProperty(cfg, "FORBID_ATTR") && arrayIsArray(cfg.FORBID_ATTR) ? addToSet({}, cfg.FORBID_ATTR, transformCaseFunc) : clone({});
15992
- USE_PROFILES = objectHasOwnProperty(cfg, "USE_PROFILES") ? cfg.USE_PROFILES && typeof cfg.USE_PROFILES === "object" ? clone(cfg.USE_PROFILES) : cfg.USE_PROFILES : false;
15898
+ ALLOWED_TAGS = objectHasOwnProperty(cfg, "ALLOWED_TAGS") ? addToSet({}, cfg.ALLOWED_TAGS, transformCaseFunc) : DEFAULT_ALLOWED_TAGS;
15899
+ ALLOWED_ATTR = objectHasOwnProperty(cfg, "ALLOWED_ATTR") ? addToSet({}, cfg.ALLOWED_ATTR, transformCaseFunc) : DEFAULT_ALLOWED_ATTR;
15900
+ ALLOWED_NAMESPACES = objectHasOwnProperty(cfg, "ALLOWED_NAMESPACES") ? addToSet({}, cfg.ALLOWED_NAMESPACES, stringToString) : DEFAULT_ALLOWED_NAMESPACES;
15901
+ URI_SAFE_ATTRIBUTES = objectHasOwnProperty(cfg, "ADD_URI_SAFE_ATTR") ? addToSet(clone(DEFAULT_URI_SAFE_ATTRIBUTES), cfg.ADD_URI_SAFE_ATTR, transformCaseFunc) : DEFAULT_URI_SAFE_ATTRIBUTES;
15902
+ DATA_URI_TAGS = objectHasOwnProperty(cfg, "ADD_DATA_URI_TAGS") ? addToSet(clone(DEFAULT_DATA_URI_TAGS), cfg.ADD_DATA_URI_TAGS, transformCaseFunc) : DEFAULT_DATA_URI_TAGS;
15903
+ FORBID_CONTENTS = objectHasOwnProperty(cfg, "FORBID_CONTENTS") ? addToSet({}, cfg.FORBID_CONTENTS, transformCaseFunc) : DEFAULT_FORBID_CONTENTS;
15904
+ FORBID_TAGS = objectHasOwnProperty(cfg, "FORBID_TAGS") ? addToSet({}, cfg.FORBID_TAGS, transformCaseFunc) : clone({});
15905
+ FORBID_ATTR = objectHasOwnProperty(cfg, "FORBID_ATTR") ? addToSet({}, cfg.FORBID_ATTR, transformCaseFunc) : clone({});
15906
+ USE_PROFILES = objectHasOwnProperty(cfg, "USE_PROFILES") ? cfg.USE_PROFILES : false;
15993
15907
  ALLOW_ARIA_ATTR = cfg.ALLOW_ARIA_ATTR !== false;
15994
15908
  ALLOW_DATA_ATTR = cfg.ALLOW_DATA_ATTR !== false;
15995
15909
  ALLOW_UNKNOWN_PROTOCOLS = cfg.ALLOW_UNKNOWN_PROTOCOLS || false;
@@ -16005,20 +15919,19 @@ function requireTinymce() {
16005
15919
  SANITIZE_NAMED_PROPS = cfg.SANITIZE_NAMED_PROPS || false;
16006
15920
  KEEP_CONTENT = cfg.KEEP_CONTENT !== false;
16007
15921
  IN_PLACE = cfg.IN_PLACE || false;
16008
- IS_ALLOWED_URI$1 = isRegex(cfg.ALLOWED_URI_REGEXP) ? cfg.ALLOWED_URI_REGEXP : IS_ALLOWED_URI;
16009
- NAMESPACE = typeof cfg.NAMESPACE === "string" ? cfg.NAMESPACE : HTML_NAMESPACE;
16010
- MATHML_TEXT_INTEGRATION_POINTS = objectHasOwnProperty(cfg, "MATHML_TEXT_INTEGRATION_POINTS") && cfg.MATHML_TEXT_INTEGRATION_POINTS && typeof cfg.MATHML_TEXT_INTEGRATION_POINTS === "object" ? clone(cfg.MATHML_TEXT_INTEGRATION_POINTS) : addToSet({}, ["mi", "mo", "mn", "ms", "mtext"]);
16011
- HTML_INTEGRATION_POINTS = objectHasOwnProperty(cfg, "HTML_INTEGRATION_POINTS") && cfg.HTML_INTEGRATION_POINTS && typeof cfg.HTML_INTEGRATION_POINTS === "object" ? clone(cfg.HTML_INTEGRATION_POINTS) : addToSet({}, ["annotation-xml"]);
16012
- const customElementHandling = objectHasOwnProperty(cfg, "CUSTOM_ELEMENT_HANDLING") && cfg.CUSTOM_ELEMENT_HANDLING && typeof cfg.CUSTOM_ELEMENT_HANDLING === "object" ? clone(cfg.CUSTOM_ELEMENT_HANDLING) : create$7(null);
16013
- CUSTOM_ELEMENT_HANDLING = create$7(null);
16014
- if (objectHasOwnProperty(customElementHandling, "tagNameCheck") && isRegexOrFunction(customElementHandling.tagNameCheck)) {
16015
- CUSTOM_ELEMENT_HANDLING.tagNameCheck = customElementHandling.tagNameCheck;
15922
+ IS_ALLOWED_URI$1 = cfg.ALLOWED_URI_REGEXP || IS_ALLOWED_URI;
15923
+ NAMESPACE = cfg.NAMESPACE || HTML_NAMESPACE;
15924
+ MATHML_TEXT_INTEGRATION_POINTS = cfg.MATHML_TEXT_INTEGRATION_POINTS || MATHML_TEXT_INTEGRATION_POINTS;
15925
+ HTML_INTEGRATION_POINTS = cfg.HTML_INTEGRATION_POINTS || HTML_INTEGRATION_POINTS;
15926
+ CUSTOM_ELEMENT_HANDLING = cfg.CUSTOM_ELEMENT_HANDLING || {};
15927
+ if (cfg.CUSTOM_ELEMENT_HANDLING && isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck)) {
15928
+ CUSTOM_ELEMENT_HANDLING.tagNameCheck = cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck;
16016
15929
  }
16017
- if (objectHasOwnProperty(customElementHandling, "attributeNameCheck") && isRegexOrFunction(customElementHandling.attributeNameCheck)) {
16018
- CUSTOM_ELEMENT_HANDLING.attributeNameCheck = customElementHandling.attributeNameCheck;
15930
+ if (cfg.CUSTOM_ELEMENT_HANDLING && isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)) {
15931
+ CUSTOM_ELEMENT_HANDLING.attributeNameCheck = cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck;
16019
15932
  }
16020
- if (objectHasOwnProperty(customElementHandling, "allowCustomizedBuiltInElements") && typeof customElementHandling.allowCustomizedBuiltInElements === "boolean") {
16021
- CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements = customElementHandling.allowCustomizedBuiltInElements;
15933
+ if (cfg.CUSTOM_ELEMENT_HANDLING && typeof cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements === "boolean") {
15934
+ CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements = cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements;
16022
15935
  }
16023
15936
  if (SAFE_FOR_TEMPLATES) {
16024
15937
  ALLOW_DATA_ATTR = false;
@@ -16028,7 +15941,7 @@ function requireTinymce() {
16028
15941
  }
16029
15942
  if (USE_PROFILES) {
16030
15943
  ALLOWED_TAGS = addToSet({}, text);
16031
- ALLOWED_ATTR = create$7(null);
15944
+ ALLOWED_ATTR = [];
16032
15945
  if (USE_PROFILES.html === true) {
16033
15946
  addToSet(ALLOWED_TAGS, html$1);
16034
15947
  addToSet(ALLOWED_ATTR, html);
@@ -16049,43 +15962,27 @@ function requireTinymce() {
16049
15962
  addToSet(ALLOWED_ATTR, xml);
16050
15963
  }
16051
15964
  }
16052
- EXTRA_ELEMENT_HANDLING.tagCheck = null;
16053
- EXTRA_ELEMENT_HANDLING.attributeCheck = null;
16054
- if (objectHasOwnProperty(cfg, "ADD_TAGS")) {
16055
- if (typeof cfg.ADD_TAGS === "function") {
16056
- EXTRA_ELEMENT_HANDLING.tagCheck = cfg.ADD_TAGS;
16057
- } else if (arrayIsArray(cfg.ADD_TAGS)) {
16058
- if (ALLOWED_TAGS === DEFAULT_ALLOWED_TAGS) {
16059
- ALLOWED_TAGS = clone(ALLOWED_TAGS);
16060
- }
16061
- addToSet(ALLOWED_TAGS, cfg.ADD_TAGS, transformCaseFunc);
15965
+ if (cfg.ADD_TAGS) {
15966
+ if (ALLOWED_TAGS === DEFAULT_ALLOWED_TAGS) {
15967
+ ALLOWED_TAGS = clone(ALLOWED_TAGS);
16062
15968
  }
15969
+ addToSet(ALLOWED_TAGS, cfg.ADD_TAGS, transformCaseFunc);
16063
15970
  }
16064
- if (objectHasOwnProperty(cfg, "ADD_ATTR")) {
16065
- if (typeof cfg.ADD_ATTR === "function") {
16066
- EXTRA_ELEMENT_HANDLING.attributeCheck = cfg.ADD_ATTR;
16067
- } else if (arrayIsArray(cfg.ADD_ATTR)) {
16068
- if (ALLOWED_ATTR === DEFAULT_ALLOWED_ATTR) {
16069
- ALLOWED_ATTR = clone(ALLOWED_ATTR);
16070
- }
16071
- addToSet(ALLOWED_ATTR, cfg.ADD_ATTR, transformCaseFunc);
15971
+ if (cfg.ADD_ATTR) {
15972
+ if (ALLOWED_ATTR === DEFAULT_ALLOWED_ATTR) {
15973
+ ALLOWED_ATTR = clone(ALLOWED_ATTR);
16072
15974
  }
15975
+ addToSet(ALLOWED_ATTR, cfg.ADD_ATTR, transformCaseFunc);
16073
15976
  }
16074
- if (objectHasOwnProperty(cfg, "ADD_URI_SAFE_ATTR") && arrayIsArray(cfg.ADD_URI_SAFE_ATTR)) {
15977
+ if (cfg.ADD_URI_SAFE_ATTR) {
16075
15978
  addToSet(URI_SAFE_ATTRIBUTES, cfg.ADD_URI_SAFE_ATTR, transformCaseFunc);
16076
15979
  }
16077
- if (objectHasOwnProperty(cfg, "FORBID_CONTENTS") && arrayIsArray(cfg.FORBID_CONTENTS)) {
15980
+ if (cfg.FORBID_CONTENTS) {
16078
15981
  if (FORBID_CONTENTS === DEFAULT_FORBID_CONTENTS) {
16079
15982
  FORBID_CONTENTS = clone(FORBID_CONTENTS);
16080
15983
  }
16081
15984
  addToSet(FORBID_CONTENTS, cfg.FORBID_CONTENTS, transformCaseFunc);
16082
15985
  }
16083
- if (objectHasOwnProperty(cfg, "ADD_FORBID_CONTENTS") && arrayIsArray(cfg.ADD_FORBID_CONTENTS)) {
16084
- if (FORBID_CONTENTS === DEFAULT_FORBID_CONTENTS) {
16085
- FORBID_CONTENTS = clone(FORBID_CONTENTS);
16086
- }
16087
- addToSet(FORBID_CONTENTS, cfg.ADD_FORBID_CONTENTS, transformCaseFunc);
16088
- }
16089
15986
  if (KEEP_CONTENT) {
16090
15987
  ALLOWED_TAGS["#text"] = true;
16091
15988
  }
@@ -16246,37 +16143,11 @@ function requireTinymce() {
16246
16143
  null
16247
16144
  );
16248
16145
  };
16249
- const _scrubTemplateExpressions = function _scrubTemplateExpressions2(node) {
16250
- node.normalize();
16251
- const walker = createNodeIterator.call(
16252
- node.ownerDocument || node,
16253
- node,
16254
- // eslint-disable-next-line no-bitwise
16255
- NodeFilter2.SHOW_TEXT | NodeFilter2.SHOW_COMMENT | NodeFilter2.SHOW_CDATA_SECTION | NodeFilter2.SHOW_PROCESSING_INSTRUCTION,
16256
- null
16257
- );
16258
- let currentNode = walker.nextNode();
16259
- while (currentNode) {
16260
- let data2 = currentNode.data;
16261
- arrayForEach([MUSTACHE_EXPR$1, ERB_EXPR$1, TMPLIT_EXPR$1], (expr) => {
16262
- data2 = stringReplace(data2, expr, " ");
16263
- });
16264
- currentNode.data = data2;
16265
- currentNode = walker.nextNode();
16266
- }
16267
- };
16268
16146
  const _isClobbered = function _isClobbered2(element) {
16269
16147
  return element instanceof HTMLFormElement && (typeof element.nodeName !== "string" || typeof element.textContent !== "string" || typeof element.removeChild !== "function" || !(element.attributes instanceof NamedNodeMap) || typeof element.removeAttribute !== "function" || typeof element.setAttribute !== "function" || typeof element.namespaceURI !== "string" || typeof element.insertBefore !== "function" || typeof element.hasChildNodes !== "function");
16270
16148
  };
16271
16149
  const _isNode = function _isNode2(value2) {
16272
- if (!getNodeType || typeof value2 !== "object" || value2 === null) {
16273
- return false;
16274
- }
16275
- try {
16276
- return typeof getNodeType(value2) === "number";
16277
- } catch (_) {
16278
- return false;
16279
- }
16150
+ return typeof Node === "function" && value2 instanceof Node;
16280
16151
  };
16281
16152
  function _executeHooks(hooks2, currentNode, data2) {
16282
16153
  arrayForEach(hooks2, (hook) => {
@@ -16299,10 +16170,6 @@ function requireTinymce() {
16299
16170
  _forceRemove(currentNode);
16300
16171
  return true;
16301
16172
  }
16302
- if (SAFE_FOR_XML && currentNode.namespaceURI === HTML_NAMESPACE && tagName === "style" && _isNode(currentNode.firstElementChild)) {
16303
- _forceRemove(currentNode);
16304
- return true;
16305
- }
16306
16173
  if (currentNode.nodeType === NODE_TYPE.progressingInstruction) {
16307
16174
  _forceRemove(currentNode);
16308
16175
  return true;
@@ -16311,7 +16178,7 @@ function requireTinymce() {
16311
16178
  _forceRemove(currentNode);
16312
16179
  return true;
16313
16180
  }
16314
- if (FORBID_TAGS[tagName] || !(EXTRA_ELEMENT_HANDLING.tagCheck instanceof Function && EXTRA_ELEMENT_HANDLING.tagCheck(tagName)) && !ALLOWED_TAGS[tagName]) {
16181
+ if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {
16315
16182
  if (!FORBID_TAGS[tagName] && _isBasicCustomElement(tagName)) {
16316
16183
  if (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, tagName)) {
16317
16184
  return false;
@@ -16327,6 +16194,7 @@ function requireTinymce() {
16327
16194
  const childCount = childNodes.length;
16328
16195
  for (let i = childCount - 1; i >= 0; --i) {
16329
16196
  const childClone = cloneNode(childNodes[i], true);
16197
+ childClone.__removalCount = (currentNode.__removalCount || 0) + 1;
16330
16198
  parentNode.insertBefore(childClone, getNextSibling(currentNode));
16331
16199
  }
16332
16200
  }
@@ -16344,7 +16212,7 @@ function requireTinymce() {
16344
16212
  }
16345
16213
  if (SAFE_FOR_TEMPLATES && currentNode.nodeType === NODE_TYPE.text) {
16346
16214
  content = currentNode.textContent;
16347
- arrayForEach([MUSTACHE_EXPR$1, ERB_EXPR$1, TMPLIT_EXPR$1], (expr) => {
16215
+ arrayForEach([MUSTACHE_EXPR2, ERB_EXPR2, TMPLIT_EXPR2], (expr) => {
16348
16216
  content = stringReplace(content, expr, " ");
16349
16217
  });
16350
16218
  if (currentNode.textContent !== content) {
@@ -16358,21 +16226,17 @@ function requireTinymce() {
16358
16226
  return false;
16359
16227
  };
16360
16228
  const _isValidAttribute = function _isValidAttribute2(lcTag, lcName, value2) {
16361
- if (FORBID_ATTR[lcName]) {
16362
- return false;
16363
- }
16364
16229
  if (SANITIZE_DOM && (lcName === "id" || lcName === "name") && (value2 in document2 || value2 in formElement)) {
16365
16230
  return false;
16366
16231
  }
16367
- const nameIsPermitted = ALLOWED_ATTR[lcName] || EXTRA_ELEMENT_HANDLING.attributeCheck instanceof Function && EXTRA_ELEMENT_HANDLING.attributeCheck(lcName, lcTag);
16368
- if (ALLOW_DATA_ATTR && !FORBID_ATTR[lcName] && regExpTest(DATA_ATTR$1, lcName)) ;
16369
- else if (ALLOW_ARIA_ATTR && regExpTest(ARIA_ATTR$1, lcName)) ;
16370
- else if (!nameIsPermitted || FORBID_ATTR[lcName]) {
16232
+ if (ALLOW_DATA_ATTR && !FORBID_ATTR[lcName] && regExpTest(DATA_ATTR2, lcName)) ;
16233
+ else if (ALLOW_ARIA_ATTR && regExpTest(ARIA_ATTR2, lcName)) ;
16234
+ else if (!ALLOWED_ATTR[lcName] || FORBID_ATTR[lcName]) {
16371
16235
  if (
16372
16236
  // First condition does a very basic check if a) it's basically a valid custom element tagname AND
16373
16237
  // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
16374
16238
  // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
16375
- _isBasicCustomElement(lcTag) && (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, lcTag) || CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.tagNameCheck(lcTag)) && (CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.attributeNameCheck, lcName) || CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.attributeNameCheck(lcName, lcTag)) || // Alternative, second condition checks if it's an `is`-attribute, AND
16239
+ _isBasicCustomElement(lcTag) && (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, lcTag) || CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.tagNameCheck(lcTag)) && (CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.attributeNameCheck, lcName) || CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.attributeNameCheck(lcName)) || // Alternative, second condition checks if it's an `is`-attribute, AND
16376
16240
  // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
16377
16241
  lcName === "is" && CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements && (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, value2) || CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.tagNameCheck(value2))
16378
16242
  ) ;
@@ -16380,21 +16244,22 @@ function requireTinymce() {
16380
16244
  return false;
16381
16245
  }
16382
16246
  } else if (URI_SAFE_ATTRIBUTES[lcName]) ;
16383
- else if (regExpTest(IS_ALLOWED_URI$1, stringReplace(value2, ATTR_WHITESPACE$1, ""))) ;
16247
+ else if (regExpTest(IS_ALLOWED_URI$1, stringReplace(value2, ATTR_WHITESPACE2, ""))) ;
16384
16248
  else if ((lcName === "src" || lcName === "xlink:href" || lcName === "href") && lcTag !== "script" && stringIndexOf(value2, "data:") === 0 && DATA_URI_TAGS[lcTag]) ;
16385
- else if (ALLOW_UNKNOWN_PROTOCOLS && !regExpTest(IS_SCRIPT_OR_DATA$1, stringReplace(value2, ATTR_WHITESPACE$1, ""))) ;
16249
+ else if (ALLOW_UNKNOWN_PROTOCOLS && !regExpTest(IS_SCRIPT_OR_DATA2, stringReplace(value2, ATTR_WHITESPACE2, ""))) ;
16386
16250
  else if (value2) {
16387
16251
  return false;
16388
16252
  } else ;
16389
16253
  return true;
16390
16254
  };
16391
- const RESERVED_CUSTOM_ELEMENT_NAMES = addToSet({}, ["annotation-xml", "color-profile", "font-face", "font-face-format", "font-face-name", "font-face-src", "font-face-uri", "missing-glyph"]);
16392
16255
  const _isBasicCustomElement = function _isBasicCustomElement2(tagName) {
16393
- return !RESERVED_CUSTOM_ELEMENT_NAMES[stringToLowerCase(tagName)] && regExpTest(CUSTOM_ELEMENT$1, tagName);
16256
+ return tagName !== "annotation-xml" && stringMatch(tagName, CUSTOM_ELEMENT2);
16394
16257
  };
16395
16258
  const _sanitizeAttributes = function _sanitizeAttributes2(currentNode) {
16396
16259
  _executeHooks(hooks.beforeSanitizeAttributes, currentNode, null);
16397
- const attributes = currentNode.attributes;
16260
+ const {
16261
+ attributes
16262
+ } = currentNode;
16398
16263
  if (!attributes || _isClobbered(currentNode)) {
16399
16264
  return;
16400
16265
  }
@@ -16408,7 +16273,11 @@ function requireTinymce() {
16408
16273
  let l = attributes.length;
16409
16274
  while (l--) {
16410
16275
  const attr = attributes[l];
16411
- const name2 = attr.name, namespaceURI = attr.namespaceURI, attrValue = attr.value;
16276
+ const {
16277
+ name: name2,
16278
+ namespaceURI,
16279
+ value: attrValue
16280
+ } = attr;
16412
16281
  const lcName = transformCaseFunc(name2);
16413
16282
  const initValue = attrValue;
16414
16283
  let value2 = name2 === "value" ? initValue : stringTrim(initValue);
@@ -16418,15 +16287,11 @@ function requireTinymce() {
16418
16287
  hookEvent.forceKeepAttr = void 0;
16419
16288
  _executeHooks(hooks.uponSanitizeAttribute, currentNode, hookEvent);
16420
16289
  value2 = hookEvent.attrValue;
16421
- if (SANITIZE_NAMED_PROPS && (lcName === "id" || lcName === "name") && stringIndexOf(value2, SANITIZE_NAMED_PROPS_PREFIX) !== 0) {
16290
+ if (SANITIZE_NAMED_PROPS && (lcName === "id" || lcName === "name")) {
16422
16291
  _removeAttribute(name2, currentNode);
16423
16292
  value2 = SANITIZE_NAMED_PROPS_PREFIX + value2;
16424
16293
  }
16425
- if (SAFE_FOR_XML && regExpTest(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i, value2)) {
16426
- _removeAttribute(name2, currentNode);
16427
- continue;
16428
- }
16429
- if (lcName === "attributename" && stringMatch(value2, "href")) {
16294
+ if (SAFE_FOR_XML && regExpTest(/((--!?|])>)|<\/(style|title)/i, value2)) {
16430
16295
  _removeAttribute(name2, currentNode);
16431
16296
  continue;
16432
16297
  }
@@ -16442,7 +16307,7 @@ function requireTinymce() {
16442
16307
  continue;
16443
16308
  }
16444
16309
  if (SAFE_FOR_TEMPLATES) {
16445
- arrayForEach([MUSTACHE_EXPR$1, ERB_EXPR$1, TMPLIT_EXPR$1], (expr) => {
16310
+ arrayForEach([MUSTACHE_EXPR2, ERB_EXPR2, TMPLIT_EXPR2], (expr) => {
16446
16311
  value2 = stringReplace(value2, expr, " ");
16447
16312
  });
16448
16313
  }
@@ -16485,7 +16350,7 @@ function requireTinymce() {
16485
16350
  }
16486
16351
  _executeHooks(hooks.afterSanitizeAttributes, currentNode, null);
16487
16352
  };
16488
- const _sanitizeShadowDOM2 = function _sanitizeShadowDOM(fragment) {
16353
+ const _sanitizeShadowDOM = function _sanitizeShadowDOM2(fragment) {
16489
16354
  let shadowNode = null;
16490
16355
  const shadowIterator = _createNodeIterator(fragment);
16491
16356
  _executeHooks(hooks.beforeSanitizeShadowDOM, fragment, null);
@@ -16499,24 +16364,6 @@ function requireTinymce() {
16499
16364
  }
16500
16365
  _executeHooks(hooks.afterSanitizeShadowDOM, fragment, null);
16501
16366
  };
16502
- const _sanitizeAttachedShadowRoots2 = function _sanitizeAttachedShadowRoots(root) {
16503
- if (root.nodeType === NODE_TYPE.element && root.shadowRoot instanceof DocumentFragment) {
16504
- const sr = root.shadowRoot;
16505
- _sanitizeAttachedShadowRoots2(sr);
16506
- _sanitizeShadowDOM2(sr);
16507
- }
16508
- const childNodes = root.childNodes;
16509
- if (!childNodes) {
16510
- return;
16511
- }
16512
- const snapshot = [];
16513
- arrayForEach(childNodes, (child2) => {
16514
- arrayPush(snapshot, child2);
16515
- });
16516
- for (const child2 of snapshot) {
16517
- _sanitizeAttachedShadowRoots2(child2);
16518
- }
16519
- };
16520
16367
  DOMPurify.sanitize = function(dirty) {
16521
16368
  let cfg = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
16522
16369
  let body = null;
@@ -16528,9 +16375,13 @@ function requireTinymce() {
16528
16375
  dirty = "<!-->";
16529
16376
  }
16530
16377
  if (typeof dirty !== "string" && !_isNode(dirty)) {
16531
- dirty = stringifyValue(dirty);
16532
- if (typeof dirty !== "string") {
16533
- throw typeErrorCreate("dirty is not a string, aborting");
16378
+ if (typeof dirty.toString === "function") {
16379
+ dirty = dirty.toString();
16380
+ if (typeof dirty !== "string") {
16381
+ throw typeErrorCreate("dirty is not a string, aborting");
16382
+ }
16383
+ } else {
16384
+ throw typeErrorCreate("toString is not a function");
16534
16385
  }
16535
16386
  }
16536
16387
  if (!DOMPurify.isSupported) {
@@ -16544,15 +16395,13 @@ function requireTinymce() {
16544
16395
  IN_PLACE = false;
16545
16396
  }
16546
16397
  if (IN_PLACE) {
16547
- const nn = dirty.nodeName;
16548
- if (typeof nn === "string") {
16549
- const tagName = transformCaseFunc(nn);
16398
+ if (dirty.nodeName) {
16399
+ const tagName = transformCaseFunc(dirty.nodeName);
16550
16400
  if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {
16551
16401
  throw typeErrorCreate("root node is forbidden and cannot be sanitized in-place");
16552
16402
  }
16553
16403
  }
16554
- _sanitizeAttachedShadowRoots2(dirty);
16555
- } else if (_isNode(dirty)) {
16404
+ } else if (dirty instanceof Node) {
16556
16405
  body = _initDocument("<!---->");
16557
16406
  importedNode = body.ownerDocument.importNode(dirty, true);
16558
16407
  if (importedNode.nodeType === NODE_TYPE.element && importedNode.nodeName === "BODY") {
@@ -16562,7 +16411,6 @@ function requireTinymce() {
16562
16411
  } else {
16563
16412
  body.appendChild(importedNode);
16564
16413
  }
16565
- _sanitizeAttachedShadowRoots2(importedNode);
16566
16414
  } else {
16567
16415
  if (!RETURN_DOM && !SAFE_FOR_TEMPLATES && !WHOLE_DOCUMENT && // eslint-disable-next-line unicorn/prefer-includes
16568
16416
  dirty.indexOf("<") === -1) {
@@ -16581,19 +16429,13 @@ function requireTinymce() {
16581
16429
  _sanitizeElements(currentNode);
16582
16430
  _sanitizeAttributes(currentNode);
16583
16431
  if (currentNode.content instanceof DocumentFragment) {
16584
- _sanitizeShadowDOM2(currentNode.content);
16432
+ _sanitizeShadowDOM(currentNode.content);
16585
16433
  }
16586
16434
  }
16587
16435
  if (IN_PLACE) {
16588
- if (SAFE_FOR_TEMPLATES) {
16589
- _scrubTemplateExpressions(dirty);
16590
- }
16591
16436
  return dirty;
16592
16437
  }
16593
16438
  if (RETURN_DOM) {
16594
- if (SAFE_FOR_TEMPLATES) {
16595
- _scrubTemplateExpressions(body);
16596
- }
16597
16439
  if (RETURN_DOM_FRAGMENT) {
16598
16440
  returnNode = createDocumentFragment.call(body.ownerDocument);
16599
16441
  while (body.firstChild) {
@@ -16612,7 +16454,7 @@ function requireTinymce() {
16612
16454
  serializedHTML = "<!DOCTYPE " + body.ownerDocument.doctype.name + ">\n" + serializedHTML;
16613
16455
  }
16614
16456
  if (SAFE_FOR_TEMPLATES) {
16615
- arrayForEach([MUSTACHE_EXPR$1, ERB_EXPR$1, TMPLIT_EXPR$1], (expr) => {
16457
+ arrayForEach([MUSTACHE_EXPR2, ERB_EXPR2, TMPLIT_EXPR2], (expr) => {
16616
16458
  serializedHTML = stringReplace(serializedHTML, expr, " ");
16617
16459
  });
16618
16460
  }
@@ -17071,18 +16913,8 @@ function requireTinymce() {
17071
16913
  return;
17072
16914
  }
17073
16915
  const element = SugarElement.fromDom(node);
17074
- if (settings.sanitize) {
17075
- const shouldKeepContent = isScript(element) && schema.isValid("script") || isStyle(element) && schema.isValid("style");
17076
- if (shouldKeepContent) {
17077
- Optional.from(get$3(element)).each((content) => set$5(element, "data-mce-tmp", content));
17078
- }
17079
- const shouldClearContent = isIframe(element) && schema.isValid("iframe");
17080
- if (shouldKeepContent || shouldClearContent) {
17081
- empty(element);
17082
- }
17083
- }
17084
16916
  const isInternalElement = has$1(element, internalElementAttr);
17085
- const bogus = get$a(element, "data-mce-bogus");
16917
+ const bogus = get$9(element, "data-mce-bogus");
17086
16918
  if (!isInternalElement && isString(bogus)) {
17087
16919
  if (bogus === "all") {
17088
16920
  remove$8(element);
@@ -17106,11 +16938,11 @@ function requireTinymce() {
17106
16938
  }
17107
16939
  if (validate2 && rule && !isInternalElement) {
17108
16940
  each$e(rule.attributesForced ?? [], (attr) => {
17109
- set$5(element, attr.name, attr.value === "{$uid}" ? `mce_${uid++}` : attr.value);
16941
+ set$4(element, attr.name, attr.value === "{$uid}" ? `mce_${uid++}` : attr.value);
17110
16942
  });
17111
16943
  each$e(rule.attributesDefault ?? [], (attr) => {
17112
16944
  if (!has$1(element, attr.name)) {
17113
- set$5(element, attr.name, attr.value === "{$uid}" ? `mce_${uid++}` : attr.value);
16945
+ set$4(element, attr.name, attr.value === "{$uid}" ? `mce_${uid++}` : attr.value);
17114
16946
  }
17115
16947
  });
17116
16948
  if (rule.attributesRequired && !exists(rule.attributesRequired, (attr) => has$1(element, attr))) {
@@ -17163,23 +16995,11 @@ function requireTinymce() {
17163
16995
  }
17164
16996
  }
17165
16997
  };
17166
- const restoreValidContent = (node) => {
17167
- const element = SugarElement.fromDom(node);
17168
- if (isScript(element) || isStyle(element)) {
17169
- getOpt(element, "data-mce-tmp").each((content) => {
17170
- set(element, content);
17171
- remove$9(element, "data-mce-tmp");
17172
- });
17173
- }
17174
- };
17175
16998
  const setupPurify = (settings, schema, namespaceTracker) => {
17176
16999
  const purify$1 = purify();
17177
17000
  purify$1.addHook("uponSanitizeElement", (ele, evt) => {
17178
17001
  processNode(ele, settings, schema, namespaceTracker.track(ele), evt);
17179
17002
  });
17180
- purify$1.addHook("afterSanitizeElements", (ele) => {
17181
- restoreValidContent(ele);
17182
- });
17183
17003
  purify$1.addHook("uponSanitizeAttribute", (ele, evt) => {
17184
17004
  processAttr(ele, settings, schema, namespaceTracker.current(), evt);
17185
17005
  });
@@ -18681,7 +18501,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
18681
18501
  const addListeners = (editor, registeredFormatListeners, formats, callback, similar, vars) => {
18682
18502
  const formatChangeItems = registeredFormatListeners.get();
18683
18503
  each$e(formats.split(","), (format) => {
18684
- const group = get$b(formatChangeItems, format).getOrThunk(() => {
18504
+ const group = get$a(formatChangeItems, format).getOrThunk(() => {
18685
18505
  const base = {
18686
18506
  withSimilar: {
18687
18507
  state: Cell(false),
@@ -18721,7 +18541,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
18721
18541
  };
18722
18542
  const removeListeners = (registeredFormatListeners, formats, callback) => {
18723
18543
  const formatChangeItems = registeredFormatListeners.get();
18724
- each$e(formats.split(","), (format) => get$b(formatChangeItems, format).each((group) => {
18544
+ each$e(formats.split(","), (format) => get$a(formatChangeItems, format).each((group) => {
18725
18545
  formatChangeItems[format] = {
18726
18546
  withSimilar: {
18727
18547
  ...group.withSimilar,
@@ -19193,12 +19013,12 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
19193
19013
  };
19194
19014
  const getCleanLevelContent = (isReadonly, level) => {
19195
19015
  const elm = SugarElement.fromTag("body", lazyTempDocument());
19196
- set$4(elm, getLevelContent(level));
19016
+ set$3(elm, getLevelContent(level));
19197
19017
  each$e(descendants(elm, "*[data-mce-bogus]"), unwrap);
19198
19018
  if (isReadonly) {
19199
19019
  each$e(descendants(elm, "details[open]"), (element) => remove$9(element, "open"));
19200
19020
  }
19201
- return get$9(elm);
19021
+ return get$8(elm);
19202
19022
  };
19203
19023
  const hasEqualContent = (level1, level2) => getLevelContent(level1) === getLevelContent(level2);
19204
19024
  const hasEqualCleanedContent = (isReadonly, level1, level2) => getCleanLevelContent(isReadonly, level1) === getCleanLevelContent(isReadonly, level2);
@@ -19524,7 +19344,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
19524
19344
  };
19525
19345
  };
19526
19346
  const isRtc = (editor) => has$2(editor.plugins, "rtc");
19527
- const getRtcSetup = (editor) => get$b(editor.plugins, "rtc").bind((rtcPlugin) => (
19347
+ const getRtcSetup = (editor) => get$a(editor.plugins, "rtc").bind((rtcPlugin) => (
19528
19348
  // This might not exist if the stub plugin is loaded on cloud
19529
19349
  Optional.from(rtcPlugin.setup)
19530
19350
  ));
@@ -20059,6 +19879,11 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
20059
19879
  node.name = "#cdata";
20060
19880
  node.type = 4;
20061
19881
  node.value = dom2.decode(value2.replace(/^\[CDATA\[|\]\]$/g, ""));
19882
+ } else if (value2?.indexOf("mce:protected ") === 0) {
19883
+ node.name = "#text";
19884
+ node.type = 3;
19885
+ node.raw = true;
19886
+ node.value = unescape(value2).substr(14);
20062
19887
  }
20063
19888
  }
20064
19889
  });
@@ -20458,7 +20283,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
20458
20283
  const rawElm = elm.dom;
20459
20284
  return rawElm[propName];
20460
20285
  };
20461
- const getComputedSizeProp = (propName, elm) => parseInt(get$8(elm, propName), 10);
20286
+ const getComputedSizeProp = (propName, elm) => parseInt(get$7(elm, propName), 10);
20462
20287
  const getClientWidth = curry(getProp, "clientWidth");
20463
20288
  const getClientHeight = curry(getProp, "clientHeight");
20464
20289
  const getMarginTop = curry(getComputedSizeProp, "margin-top");
@@ -21018,7 +20843,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
21018
20843
  const load = (editor, suffix) => {
21019
20844
  const strategy = determineStrategy(editor);
21020
20845
  if (strategy.type === "use_plugin") {
21021
- const externalUrl = get$b(getExternalPlugins$1(editor), PLUGIN_CODE).map(trim$4).filter(isNotEmpty);
20846
+ const externalUrl = get$a(getExternalPlugins$1(editor), PLUGIN_CODE).map(trim$4).filter(isNotEmpty);
21022
20847
  const url = externalUrl.getOr(`plugins/${PLUGIN_CODE}/plugin${suffix}.js`);
21023
20848
  addOnManager.load(ADDON_KEY, url).catch(() => {
21024
20849
  licenseKeyManagerLoadError(editor, url);
@@ -21103,7 +20928,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
21103
20928
  const body = SugarElement.fromDom(editor.getBody());
21104
20929
  toggleClass(body, "mce-content-readonly", false);
21105
20930
  if (editor.hasEditableRoot()) {
21106
- set$1(body, true);
20931
+ set(body, true);
21107
20932
  }
21108
20933
  setCommonEditorCommands(editor, false);
21109
20934
  if (hasEditorOrUiFocus(editor)) {
@@ -21116,21 +20941,21 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
21116
20941
  const internalContentEditableAttr = "data-mce-contenteditable";
21117
20942
  const switchOffContentEditableTrue = (elm) => {
21118
20943
  each$e(descendants(elm, '*[contenteditable="true"]'), (elm2) => {
21119
- set$5(elm2, internalContentEditableAttr, "true");
21120
- set$1(elm2, false);
20944
+ set$4(elm2, internalContentEditableAttr, "true");
20945
+ set(elm2, false);
21121
20946
  });
21122
20947
  };
21123
20948
  const switchOnContentEditableTrue = (elm) => {
21124
20949
  each$e(descendants(elm, `*[${internalContentEditableAttr}="true"]`), (elm2) => {
21125
20950
  remove$9(elm2, internalContentEditableAttr);
21126
- set$1(elm2, true);
20951
+ set(elm2, true);
21127
20952
  });
21128
20953
  };
21129
20954
  const toggleDisabled = (editor, state) => {
21130
20955
  const body = SugarElement.fromDom(editor.getBody());
21131
20956
  if (state) {
21132
20957
  disableEditor(editor);
21133
- set$1(body, false);
20958
+ set(body, false);
21134
20959
  switchOffContentEditableTrue(body);
21135
20960
  } else {
21136
20961
  switchOnContentEditableTrue(body);
@@ -21214,8 +21039,8 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
21214
21039
  registerDisabledModeEventHandlers(editor);
21215
21040
  };
21216
21041
  const isContentCssSkinName = (url) => /^[a-z0-9\-]+$/i.test(url);
21217
- const toContentSkinResourceName = (name2) => "content/" + name2 + "/content.css";
21218
- const isBundledCssSkinName = (name2) => tinymce.Resource.has(toContentSkinResourceName(name2));
21042
+ const toContentSkinResourceName = (url) => "content/" + url + "/content.css";
21043
+ const isBundledCssSkinName = (url) => tinymce.Resource.has(toContentSkinResourceName(url));
21219
21044
  const getContentCssUrls = (editor) => {
21220
21045
  return transformToUrls(editor, getContentCss(editor));
21221
21046
  };
@@ -21228,7 +21053,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
21228
21053
  const contentCssFile = `content${suffix}.css`;
21229
21054
  return map$3(cssLinks, (url) => {
21230
21055
  if (isBundledCssSkinName(url)) {
21231
- return toContentSkinResourceName(url);
21056
+ return url;
21232
21057
  } else if (isContentCssSkinName(url) && !editor.inline) {
21233
21058
  return `${skinUrl}/${url}/${contentCssFile}`;
21234
21059
  } else {
@@ -21385,7 +21210,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
21385
21210
  }
21386
21211
  };
21387
21212
  const toBlobInfo = (o) => {
21388
- if (isNullable(o.blob) || isNullable(o.base64) || o.base64 === "" && !o.allowEmptyFile) {
21213
+ if (!o.blob || !o.base64) {
21389
21214
  throw new Error("blob and base64 representations of the image are required for BlobInfo to be created");
21390
21215
  }
21391
21216
  const id = o.id || uuid("blobid");
@@ -22655,7 +22480,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
22655
22480
  level.bookmark = getUndoBookmark(editor.selection);
22656
22481
  editor.dispatch("change", {
22657
22482
  level,
22658
- lastLevel: get$c(undoManager.data, index.get()).getOrUndefined()
22483
+ lastLevel: get$b(undoManager.data, index.get()).getOrUndefined()
22659
22484
  });
22660
22485
  },
22661
22486
  /**
@@ -22845,49 +22670,6 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
22845
22670
  });
22846
22671
  }
22847
22672
  };
22848
- const createAndFireInputEvent = (eventType) => (editor, inputType, specifics = {}) => {
22849
- const target = editor.getBody();
22850
- const overrides = {
22851
- bubbles: true,
22852
- composed: true,
22853
- data: null,
22854
- isComposing: false,
22855
- detail: 0,
22856
- view: null,
22857
- target,
22858
- currentTarget: target,
22859
- eventPhase: Event.AT_TARGET,
22860
- originalTarget: target,
22861
- explicitOriginalTarget: target,
22862
- isTrusted: false,
22863
- srcElement: target,
22864
- cancelable: false,
22865
- preventDefault: noop,
22866
- inputType
22867
- };
22868
- const input = clone$2(new InputEvent(eventType));
22869
- return editor.dispatch(eventType, { ...input, ...overrides, ...specifics });
22870
- };
22871
- const fireInputEvent = createAndFireInputEvent("input");
22872
- const fireBeforeInputEvent = createAndFireInputEvent("beforeinput");
22873
- const symulateDelete = (editor, isForward, deleteFun) => {
22874
- let shouldFireInput = true;
22875
- const inputHandler = () => shouldFireInput = false;
22876
- const beforeInputEvent = fireBeforeInputEvent(editor, isForward ? "deleteContentForward" : "deleteContentBackward");
22877
- if (beforeInputEvent.isDefaultPrevented()) {
22878
- return false;
22879
- }
22880
- editor.on("input", inputHandler);
22881
- try {
22882
- deleteFun();
22883
- } finally {
22884
- editor.off("input", inputHandler);
22885
- }
22886
- if (shouldFireInput) {
22887
- editor.dispatch("input");
22888
- }
22889
- return true;
22890
- };
22891
22673
  const matchNodeName = (name2) => (node) => isNonNullable(node) && node.nodeName.toLowerCase() === name2;
22892
22674
  const matchNodeNames = (regex) => (node) => isNonNullable(node) && regex.test(node.nodeName);
22893
22675
  const isTextNode$1 = (node) => isNonNullable(node) && node.nodeType === 3;
@@ -22896,7 +22678,6 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
22896
22678
  const isOlUlNode = matchNodeNames(/^(OL|UL)$/);
22897
22679
  const isListItemNode = matchNodeNames(/^(LI|DT|DD)$/);
22898
22680
  const isDlItemNode = matchNodeNames(/^(DT|DD)$/);
22899
- const isTableCellNode = matchNodeNames(/^(TH|TD)$/);
22900
22681
  const isBr$1 = matchNodeName("br");
22901
22682
  const isFirstChild$1 = (node) => node.parentNode?.firstChild === node;
22902
22683
  const isTextBlock = (editor, node) => isNonNullable(node) && node.nodeName in editor.schema.getTextBlockElements();
@@ -22974,18 +22755,11 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
22974
22755
  outRng.setEnd(rangeEnd.container, rangeEnd.offset);
22975
22756
  return outRng;
22976
22757
  };
22977
- const isList = (el) => is$1(el, "OL,UL");
22978
- const isListItem$1 = (el) => is$1(el, "LI");
22979
- const hasFirstChildList = (el) => firstChild(el).exists(isList);
22980
- const hasLastChildList = (el) => lastChild(el).exists(isList);
22981
- const canIncreaseDepthOfList = (editor, amount) => {
22982
- return getListMaxDepth(editor).map((max2) => max2 >= amount).getOr(true);
22983
- };
22984
22758
  const listNames = ["OL", "UL", "DL"];
22985
22759
  const listSelector = listNames.join(",");
22986
22760
  const getParentList = (editor, node) => {
22987
22761
  const selectionStart = editor.selection.getStart(true);
22988
- return editor.dom.getParent(selectionStart, listSelector, getClosestListHost(editor, selectionStart, editor.selection.isCollapsed()));
22762
+ return editor.dom.getParent(selectionStart, listSelector, getClosestListHost(editor, selectionStart));
22989
22763
  };
22990
22764
  const isParentListSelected = (parentList, selectedBlocks) => isNonNullable(parentList) && selectedBlocks.length === 1 && selectedBlocks[0] === parentList;
22991
22765
  const findSubLists = (parentList) => filter$5(parentList.querySelectorAll(listSelector), isListNode);
@@ -23000,16 +22774,16 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
23000
22774
  });
23001
22775
  }
23002
22776
  };
23003
- const findParentListItemsNodes = (editor, elms, isCollapsed) => {
22777
+ const findParentListItemsNodes = (editor, elms) => {
23004
22778
  const listItemsElms = Tools.map(elms, (elm) => {
23005
- const parentLi = editor.dom.getParent(elm, "li,dd,dt", getClosestListHost(editor, elm, isCollapsed));
22779
+ const parentLi = editor.dom.getParent(elm, "li,dd,dt", getClosestListHost(editor, elm));
23006
22780
  return parentLi ? parentLi : elm;
23007
22781
  });
23008
22782
  return unique$1(listItemsElms);
23009
22783
  };
23010
22784
  const getSelectedListItems = (editor) => {
23011
22785
  const selectedBlocks = editor.selection.getSelectedBlocks();
23012
- return filter$5(findParentListItemsNodes(editor, selectedBlocks, editor.selection.isCollapsed()), isListItemNode);
22786
+ return filter$5(findParentListItemsNodes(editor, selectedBlocks), isListItemNode);
23013
22787
  };
23014
22788
  const getSelectedDlItems = (editor) => filter$5(getSelectedListItems(editor), isDlItemNode);
23015
22789
  const getClosestEditingHost = (editor, elm) => {
@@ -23017,34 +22791,15 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
23017
22791
  return parentTableCell.length > 0 ? parentTableCell[0] : editor.getBody();
23018
22792
  };
23019
22793
  const isListHost = (schema, node) => !isListNode(node) && !isListItemNode(node) && exists(listNames, (listName) => schema.isValidChild(node.nodeName, listName));
23020
- const requireLiElementFirst = (parentBlocks) => {
23021
- const result = findMap(parentBlocks, (element) => {
23022
- if (isListItem$1(SugarElement.fromDom(element))) {
23023
- return Optional.some(true);
23024
- }
23025
- if (isTableCellNode(element)) {
23026
- return Optional.some(false);
23027
- }
23028
- return Optional.none();
23029
- });
23030
- return result.getOr(false);
23031
- };
23032
- const getClosestListHost = (editor, elm, isCollapsed) => {
22794
+ const getClosestListHost = (editor, elm) => {
23033
22795
  const parentBlocks = editor.dom.getParents(elm, editor.dom.isBlock);
23034
- let foundListBlock = !requireLiElementFirst(parentBlocks);
23035
22796
  const isNotForcedRootBlock = (elm2) => elm2.nodeName.toLowerCase() !== getForcedRootBlock(editor);
23036
- const checkListRequirement = (element) => {
23037
- if (isListItem$1(SugarElement.fromDom(element)) || isList(SugarElement.fromDom(element))) {
23038
- foundListBlock = true;
23039
- }
23040
- return foundListBlock;
23041
- };
23042
- const parentBlock = find$2(parentBlocks, (elm2) => checkListRequirement(elm2) && (!isCollapsed || isNotForcedRootBlock(elm2)) && isListHost(editor.schema, elm2));
22797
+ const parentBlock = find$2(parentBlocks, (elm2) => isNotForcedRootBlock(elm2) && isListHost(editor.schema, elm2));
23043
22798
  return parentBlock.getOr(editor.getBody());
23044
22799
  };
23045
22800
  const isListInsideAnLiWithFirstAndLastNotListElement = (list) => parent(list).exists((parent2) => isListItemNode(parent2.dom) && firstChild(parent2).exists((firstChild2) => !isListNode(firstChild2.dom)) && lastChild(parent2).exists((lastChild2) => !isListNode(lastChild2.dom)));
23046
22801
  const findLastParentListNode = (editor, elm) => {
23047
- const parentLists = editor.dom.getParents(elm, "ol,ul", getClosestListHost(editor, elm, true));
22802
+ const parentLists = editor.dom.getParents(elm, "ol,ul", getClosestListHost(editor, elm));
23048
22803
  return last$2(parentLists);
23049
22804
  };
23050
22805
  const getSelectedLists = (editor) => {
@@ -23054,7 +22809,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
23054
22809
  };
23055
22810
  const getParentLists = (editor) => {
23056
22811
  const elm = editor.selection.getStart();
23057
- return editor.dom.getParents(elm, "ol,ul", getClosestListHost(editor, elm, editor.selection.isCollapsed()));
22812
+ return editor.dom.getParents(elm, "ol,ul", getClosestListHost(editor, elm));
23058
22813
  };
23059
22814
  const getSelectedListRoots = (editor) => {
23060
22815
  const selectedLists = getSelectedLists(editor);
@@ -23113,6 +22868,13 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
23113
22868
  }
23114
22869
  return fragment;
23115
22870
  };
22871
+ const isList = (el) => is$1(el, "OL,UL");
22872
+ const isListItem$1 = (el) => is$1(el, "LI");
22873
+ const hasFirstChildList = (el) => firstChild(el).exists(isList);
22874
+ const hasLastChildList = (el) => lastChild(el).exists(isList);
22875
+ const canIncreaseDepthOfList = (editor, amount) => {
22876
+ return getListMaxDepth(editor).map((max2) => max2 >= amount).getOr(true);
22877
+ };
23116
22878
  const isEntryList = (entry) => "listAttributes" in entry;
23117
22879
  const isEntryComment = (entry) => "isComment" in entry;
23118
22880
  const isEntryFragment = (entry) => "isFragment" in entry;
@@ -23161,7 +22923,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
23161
22923
  };
23162
22924
  const populateSegments = (segments, entry) => {
23163
22925
  for (let i = 0; i < segments.length - 1; i++) {
23164
- set$3(segments[i].item, "list-style-type", "none");
22926
+ set$2(segments[i].item, "list-style-type", "none");
23165
22927
  }
23166
22928
  last$2(segments).each((segment) => {
23167
22929
  if (isEntryList(entry)) {
@@ -23616,7 +23378,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
23616
23378
  const applyList = (editor, listName, detail) => {
23617
23379
  const rng = editor.selection.getRng();
23618
23380
  let listItemName = "LI";
23619
- const root = getClosestListHost(editor, getRootSearchStart(editor, rng), rng.collapsed);
23381
+ const root = getClosestListHost(editor, getRootSearchStart(editor, rng));
23620
23382
  const dom2 = editor.dom;
23621
23383
  if (dom2.getContentEditable(editor.selection.getNode()) === "false") {
23622
23384
  return;
@@ -23985,12 +23747,18 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
23985
23747
  const startListParent = editor.dom.getParent(selectionStartElm, "LI,DT,DD", root);
23986
23748
  return isNonNullable(startListParent) || getSelectedListItems(editor).length > 0;
23987
23749
  };
23988
- const backspaceDeleteRange$1 = (editor, isForward) => {
23750
+ const backspaceDeleteRange$1 = (editor) => {
23989
23751
  if (hasListSelection(editor)) {
23990
23752
  editor.undoManager.transact(() => {
23991
- if (symulateDelete(editor, isForward, () => editor.execCommand("Delete"))) {
23992
- normalizeLists(editor.dom, editor.getBody());
23753
+ let shouldFireInput = true;
23754
+ const inputHandler = () => shouldFireInput = false;
23755
+ editor.on("input", inputHandler);
23756
+ editor.execCommand("Delete");
23757
+ editor.off("input", inputHandler);
23758
+ if (shouldFireInput) {
23759
+ editor.dispatch("input");
23993
23760
  }
23761
+ normalizeLists(editor.dom, editor.getBody());
23994
23762
  });
23995
23763
  return true;
23996
23764
  }
@@ -23998,7 +23766,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
23998
23766
  };
23999
23767
  const backspaceDelete$c = (editor, isForward) => {
24000
23768
  const selection = editor.selection;
24001
- return !isWithinNonEditableList$1(editor, selection.getNode()) && (selection.isCollapsed() ? backspaceDeleteCaret$1(editor, isForward) : backspaceDeleteRange$1(editor, isForward));
23769
+ return !isWithinNonEditableList$1(editor, selection.getNode()) && (selection.isCollapsed() ? backspaceDeleteCaret$1(editor, isForward) : backspaceDeleteRange$1(editor));
24002
23770
  };
24003
23771
  const blockPosition = (block, position) => ({
24004
23772
  block,
@@ -25317,7 +25085,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
25317
25085
  const parseIndentValue = (value2) => toInt(value2 ?? "").getOr(0);
25318
25086
  const getIndentStyleName = (useMargin, element) => {
25319
25087
  const indentStyleName = useMargin || isTable$1(element) ? "margin" : "padding";
25320
- const suffix = get$8(element, "direction") === "rtl" ? "-right" : "-left";
25088
+ const suffix = get$7(element, "direction") === "rtl" ? "-right" : "-left";
25321
25089
  return indentStyleName + suffix;
25322
25090
  };
25323
25091
  const indentElement = (dom2, command, useMargin, value2, unit, element) => {
@@ -25378,9 +25146,8 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
25378
25146
  return Optional.none();
25379
25147
  };
25380
25148
  const deleteRange = (editor, forward) => {
25381
- const range2 = editor.selection.getRng();
25382
- const rng = normalize(range2);
25383
- return isSelectionOverWholeHTMLElement(rng) ? Optional.some(() => deleteElement$2(editor, forward, SugarElement.fromDom(range2.startContainer.childNodes[range2.startOffset]))) : Optional.none();
25149
+ const rng = normalize(editor.selection.getRng());
25150
+ return isSelectionOverWholeHTMLElement(rng) ? Optional.some(() => deleteElement$2(editor, forward, SugarElement.fromDom(editor.selection.getNode()))) : Optional.none();
25384
25151
  };
25385
25152
  const backspaceDelete$1 = (editor, forward) => editor.selection.isCollapsed() ? Optional.none() : deleteRange(editor, forward);
25386
25153
  const findAction = (editor, caret, forward) => findMap([
@@ -25669,43 +25436,6 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
25669
25436
  }
25670
25437
  });
25671
25438
  };
25672
- const setupInputFiltering = (editor, protect) => {
25673
- editor.on("BeforeSetContent", (e) => {
25674
- each$e(protect, (pattern) => {
25675
- e.content = e.content.replace(pattern, (str) => {
25676
- return "<!--mce:protected " + escape(str) + "-->";
25677
- });
25678
- });
25679
- });
25680
- };
25681
- const setupOutputFiltering = (editor, protect) => {
25682
- editor.serializer.addNodeFilter("#comment", (nodes) => {
25683
- let i = nodes.length;
25684
- while (i--) {
25685
- const node = nodes[i];
25686
- const value2 = node.value;
25687
- if (value2?.indexOf("mce:protected ") === 0) {
25688
- const protectedHtml = unescape(value2).substr(14);
25689
- const valid = exists(protect, (pattern) => {
25690
- const matches = protectedHtml.match(pattern);
25691
- return matches !== null && matches[0].length === protectedHtml.length;
25692
- });
25693
- if (valid) {
25694
- node.name = "#text";
25695
- node.type = 3;
25696
- node.raw = true;
25697
- node.value = protectedHtml;
25698
- } else {
25699
- node.remove();
25700
- }
25701
- }
25702
- }
25703
- });
25704
- };
25705
- const registerProtectedHtmlFilters = (editor, protect) => {
25706
- setupInputFiltering(editor, protect);
25707
- setupOutputFiltering(editor, protect);
25708
- };
25709
25439
  const findBlockCaretContainer = (editor) => descendant$1(SugarElement.fromDom(editor.getBody()), "*[data-mce-caret]").map((elm) => elm.dom).getOrNull();
25710
25440
  const showBlockCaretContainer = (editor, blockCaretContainer) => {
25711
25441
  if (blockCaretContainer.hasAttribute("data-mce-caret")) {
@@ -26060,7 +25790,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
26060
25790
  }
26061
25791
  return contains$2(["br", "img", "hr", "input"], name(element));
26062
25792
  };
26063
- const isNonEditable = (element) => isElement$8(element) && get$a(element, "contenteditable") === "false";
25793
+ const isNonEditable = (element) => isElement$8(element) && get$9(element, "contenteditable") === "false";
26064
25794
  const comparePosition = (element, other) => {
26065
25795
  return element.dom.compareDocumentPosition(other.dom);
26066
25796
  };
@@ -26095,14 +25825,14 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
26095
25825
  predicate: descendants$1
26096
25826
  }),
26097
25827
  styles: constant({
26098
- get: get$8,
25828
+ get: get$7,
26099
25829
  getRaw: getRaw$1,
26100
- set: set$3,
25830
+ set: set$2,
26101
25831
  remove: remove$7
26102
25832
  }),
26103
25833
  attrs: constant({
26104
- get: get$a,
26105
- set: set$5,
25834
+ get: get$9,
25835
+ set: set$4,
26106
25836
  remove: remove$9,
26107
25837
  copyTo: copyAttributesTo
26108
25838
  }),
@@ -26139,8 +25869,8 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
26139
25869
  isElement: isElement$8,
26140
25870
  isSpecial,
26141
25871
  getLanguage,
26142
- getText: get$5,
26143
- setText: set$2,
25872
+ getText: get$4,
25873
+ setText: set$1,
26144
25874
  isBoundary: isBoundary2,
26145
25875
  isEmptyTag,
26146
25876
  isNonEditable
@@ -27065,6 +26795,31 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
27065
26795
  }
27066
26796
  };
27067
26797
  const backspaceDelete = (editor, forward, granularity) => shouldPreventDeleteAction(editor, forward, granularity) || isSafari && handleDeleteActionSafari(editor, forward, granularity) ? Optional.some(noop) : Optional.none();
26798
+ const createAndFireInputEvent = (eventType) => (editor, inputType, specifics = {}) => {
26799
+ const target = editor.getBody();
26800
+ const overrides = {
26801
+ bubbles: true,
26802
+ composed: true,
26803
+ data: null,
26804
+ isComposing: false,
26805
+ detail: 0,
26806
+ view: null,
26807
+ target,
26808
+ currentTarget: target,
26809
+ eventPhase: Event.AT_TARGET,
26810
+ originalTarget: target,
26811
+ explicitOriginalTarget: target,
26812
+ isTrusted: false,
26813
+ srcElement: target,
26814
+ cancelable: false,
26815
+ preventDefault: noop,
26816
+ inputType
26817
+ };
26818
+ const input = clone$2(new InputEvent(eventType));
26819
+ return editor.dispatch(eventType, { ...input, ...overrides, ...specifics });
26820
+ };
26821
+ const fireInputEvent = createAndFireInputEvent("input");
26822
+ const fireBeforeInputEvent = createAndFireInputEvent("beforeinput");
27068
26823
  const platform$2 = detect$1();
27069
26824
  const os = platform$2.os;
27070
26825
  const isMacOSOriOS = os.isMacOS() || os.isiOS();
@@ -27149,21 +26904,19 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
27149
26904
  const setup$o = (editor, caret) => {
27150
26905
  let isBackspaceKeydown = false;
27151
26906
  let formatNodes = [];
27152
- editor.on("init", () => {
27153
- editor.on("keydown", (evt) => {
27154
- isBackspaceKeydown = evt.keyCode === VK.BACKSPACE;
27155
- formatNodes = getFormatNodesAtStart(editor);
27156
- if (!evt.isDefaultPrevented()) {
27157
- executeKeydownOverride$3(editor, caret, evt);
27158
- }
27159
- });
27160
- editor.on("keyup", (evt) => {
27161
- if (!evt.isDefaultPrevented()) {
27162
- executeKeyupOverride(editor, evt, isBackspaceKeydown, formatNodes);
27163
- formatNodes.length = 0;
27164
- }
27165
- isBackspaceKeydown = false;
27166
- });
26907
+ editor.on("keydown", (evt) => {
26908
+ isBackspaceKeydown = evt.keyCode === VK.BACKSPACE;
26909
+ formatNodes = getFormatNodesAtStart(editor);
26910
+ if (!evt.isDefaultPrevented()) {
26911
+ executeKeydownOverride$3(editor, caret, evt);
26912
+ }
26913
+ });
26914
+ editor.on("keyup", (evt) => {
26915
+ if (!evt.isDefaultPrevented()) {
26916
+ executeKeyupOverride(editor, evt, isBackspaceKeydown, formatNodes);
26917
+ formatNodes.length = 0;
26918
+ }
26919
+ isBackspaceKeydown = false;
27167
26920
  });
27168
26921
  };
27169
26922
  const reduceFontStyleNesting = (block, node) => {
@@ -27199,15 +26952,16 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
27199
26952
  if (!root) {
27200
26953
  return;
27201
26954
  }
27202
- if (isListItem$2(SugarElement.fromDom(root))) {
27203
- const findFirstList = (e) => isList$1(e) ? Optional.from(e) : descendant$2(e, isList$1);
26955
+ if (/^(LI|DT|DD)$/.test(root.nodeName)) {
26956
+ const isList2 = (e) => /^(ul|ol|dl)$/.test(name(e));
26957
+ const findFirstList = (e) => isList2(e) ? Optional.from(e) : descendant$2(e, isList2);
27204
26958
  const isEmpty2 = (e) => dom2.isEmpty(e.dom);
27205
26959
  firstNonWhiteSpaceNodeSibling(root.firstChild).each((firstChild2) => {
27206
26960
  findFirstList(firstChild2).fold(() => {
27207
26961
  if (isEmpty2(firstChild2)) {
27208
26962
  const element = toLeaf$1(firstChild2, 0).element;
27209
26963
  if (isElement$8(element) && !isBr$6(element)) {
27210
- append$1(element, SugarElement.fromHtml('<br data-mce-bogus="1" />'));
26964
+ append$1(element, SugarElement.fromText(nbsp));
27211
26965
  }
27212
26966
  }
27213
26967
  }, (firstList) => {
@@ -27661,16 +27415,6 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
27661
27415
  }
27662
27416
  return true;
27663
27417
  };
27664
- const isInsideLiBeforeAList = (newBlock2) => {
27665
- const nextSibling$1 = firstChild(newBlock2).bind(nextSibling);
27666
- return isListItem$2(newBlock2) && nextSibling$1.exists(isList$1);
27667
- };
27668
- const trimEmptySpacesInLeftLeaf = (newBlock2) => {
27669
- const leaf = toLeaf$1(SugarElement.fromDom(newBlock2), 0).element;
27670
- if (isText$c(leaf) && dom2.isEmpty(leaf.dom)) {
27671
- leaf.dom.remove();
27672
- }
27673
- };
27674
27418
  const insertNewBlockAfter = () => {
27675
27419
  let block;
27676
27420
  if (/^(H[1-6]|PRE|FIGURE)$/.test(parentBlockName) && containerBlockName !== "HGROUP") {
@@ -27774,12 +27518,8 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
27774
27518
  } else {
27775
27519
  dom2.insertAfter(fragment, parentBlock);
27776
27520
  }
27777
- if (!isInsideLiBeforeAList(SugarElement.fromDom(newBlock))) {
27778
- trimInlineElementsOnLeftSideOfBlock(dom2, nonEmptyElementsMap, newBlock);
27779
- addBrToBlockIfNeeded(dom2, parentBlock);
27780
- } else {
27781
- trimEmptySpacesInLeftLeaf(newBlock);
27782
- }
27521
+ trimInlineElementsOnLeftSideOfBlock(dom2, nonEmptyElementsMap, newBlock);
27522
+ addBrToBlockIfNeeded(dom2, parentBlock);
27783
27523
  if (dom2.isEmpty(parentBlock)) {
27784
27524
  emptyBlock(parentBlock);
27785
27525
  }
@@ -28336,21 +28076,16 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
28336
28076
  editor.addQueryStateHandler("InsertDefinitionList", queryListCommandState(editor, "DL"));
28337
28077
  };
28338
28078
  const setup$e = (editor) => {
28339
- editor.on("init", () => {
28340
- editor.on("keydown", (e) => {
28341
- if (e.defaultPrevented) {
28342
- return;
28079
+ editor.on("keydown", (e) => {
28080
+ if (e.keyCode === VK.BACKSPACE) {
28081
+ if (backspaceDelete$c(editor, false)) {
28082
+ e.preventDefault();
28343
28083
  }
28344
- if (e.keyCode === VK.BACKSPACE) {
28345
- if (backspaceDelete$c(editor, false)) {
28346
- e.preventDefault();
28347
- }
28348
- } else if (e.keyCode === VK.DELETE) {
28349
- if (backspaceDelete$c(editor, true)) {
28350
- e.preventDefault();
28351
- }
28084
+ } else if (e.keyCode === VK.DELETE) {
28085
+ if (backspaceDelete$c(editor, true)) {
28086
+ e.preventDefault();
28352
28087
  }
28353
- });
28088
+ }
28354
28089
  });
28355
28090
  };
28356
28091
  const isTextNode = (node) => node.type === 3;
@@ -30057,7 +29792,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
30057
29792
  const doc = editor.getDoc();
30058
29793
  const realSelectionContainer = descendant$1(body, "#" + realSelectionId).getOrThunk(() => {
30059
29794
  const newContainer = SugarElement.fromHtml('<div data-mce-bogus="all" class="mce-offscreen-selection"></div>', doc);
30060
- set$5(newContainer, "id", realSelectionId);
29795
+ set$4(newContainer, "id", realSelectionId);
30061
29796
  append$1(body, newContainer);
30062
29797
  return newContainer;
30063
29798
  });
@@ -30575,9 +30310,9 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
30575
30310
  const stripPattern = (dom2, block, pattern) => {
30576
30311
  stripPattern$1(dom2, block, pattern).each((node) => {
30577
30312
  const text2 = SugarElement.fromDom(node);
30578
- const textContent = get$5(text2);
30313
+ const textContent = get$4(text2);
30579
30314
  if (startsWithSingleSpace(textContent)) {
30580
- set$2(text2, textContent.slice(1));
30315
+ set$1(text2, textContent.slice(1));
30581
30316
  }
30582
30317
  });
30583
30318
  };
@@ -30766,13 +30501,13 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
30766
30501
  return;
30767
30502
  }
30768
30503
  e.preventDefault();
30769
- if (symulateDelete(editor, keyCode === DELETE2, () => editor.setContent(""))) {
30770
- if (body.firstChild && dom2.isBlock(body.firstChild)) {
30771
- editor.selection.setCursorLocation(body.firstChild, 0);
30772
- } else {
30773
- editor.selection.setCursorLocation(body, 0);
30774
- }
30504
+ editor.setContent("");
30505
+ if (body.firstChild && dom2.isBlock(body.firstChild)) {
30506
+ editor.selection.setCursorLocation(body.firstChild, 0);
30507
+ } else {
30508
+ editor.selection.setCursorLocation(body, 0);
30775
30509
  }
30510
+ editor.nodeChanged();
30776
30511
  }
30777
30512
  });
30778
30513
  };
@@ -31195,7 +30930,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
31195
30930
  };
31196
30931
  const loadComponentsForInlineEditor = (componentUrls) => {
31197
30932
  return mapToArray(componentUrls, (url, elementName) => {
31198
- return get$b(hostWindowComponentScripts, url).getOrThunk(() => {
30933
+ return get$a(hostWindowComponentScripts, url).getOrThunk(() => {
31199
30934
  if (isNullable(window.customElements.get(elementName))) {
31200
30935
  const loadPromise = loadComponent(url, getDocument());
31201
30936
  hostWindowComponentScripts[url] = loadPromise;
@@ -31241,7 +30976,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
31241
30976
  const body = SugarElement.fromDom(editor.getBody());
31242
30977
  const container = getStyleContainer(getRootNode(body));
31243
30978
  const style = SugarElement.fromTag("style");
31244
- set$5(style, "type", "text/css");
30979
+ set$4(style, "type", "text/css");
31245
30980
  append$1(style, SugarElement.fromText(text2));
31246
30981
  append$1(container, style);
31247
30982
  editor.on("remove", () => {
@@ -31320,11 +31055,6 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
31320
31055
  };
31321
31056
  const createParser = (editor) => {
31322
31057
  const parser = DomParser(mkParserSettings(editor), editor.schema);
31323
- parser.addAttributeFilter("data-mce-src,data-mce-href,data-mce-style", (nodes, name2) => {
31324
- for (let i = 0; i < nodes.length; i++) {
31325
- nodes[i].attr(name2, null);
31326
- }
31327
- });
31328
31058
  parser.addAttributeFilter("src,href,style,tabindex", (nodes, name2) => {
31329
31059
  const dom2 = editor.dom;
31330
31060
  const internalName = "data-mce-" + name2;
@@ -31430,11 +31160,11 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
31430
31160
  };
31431
31161
  const getStyleSheetLoader$1 = (editor) => editor.inline ? editor.ui.styleSheetLoader : editor.dom.styleSheetLoader;
31432
31162
  const makeStylesheetLoadingPromises = (editor, css, framedFonts) => {
31433
- const { pass: bundledCss, fail: normalCss } = partition$2(css, (key) => tinymce.Resource.has(key));
31434
- const bundledPromises = bundledCss.map((key) => {
31435
- const css2 = tinymce.Resource.get(key);
31163
+ const { pass: bundledCss, fail: normalCss } = partition$2(css, (name2) => tinymce.Resource.has(toContentSkinResourceName(name2)));
31164
+ const bundledPromises = bundledCss.map((url) => {
31165
+ const css2 = tinymce.Resource.get(toContentSkinResourceName(url));
31436
31166
  if (isString(css2)) {
31437
- return Promise.resolve(getStyleSheetLoader$1(editor).loadRawCss(key, css2));
31167
+ return Promise.resolve(getStyleSheetLoader$1(editor).loadRawCss(url, css2));
31438
31168
  }
31439
31169
  return Promise.resolve();
31440
31170
  });
@@ -31496,7 +31226,13 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
31496
31226
  }
31497
31227
  const protect = getProtect(editor);
31498
31228
  if (protect) {
31499
- registerProtectedHtmlFilters(editor, protect);
31229
+ editor.on("BeforeSetContent", (e) => {
31230
+ Tools.each(protect, (pattern) => {
31231
+ e.content = e.content.replace(pattern, (str) => {
31232
+ return "<!--mce:protected " + escape(str) + "-->";
31233
+ });
31234
+ });
31235
+ });
31500
31236
  }
31501
31237
  editor.on("SetContent", () => {
31502
31238
  editor.addVisual(editor.getBody());
@@ -31540,11 +31276,6 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
31540
31276
  editor.bodyElement = targetElm;
31541
31277
  editor.contentAreaContainer = targetElm;
31542
31278
  }
31543
- const contentLanguage = getContentLanguage(editor);
31544
- if (contentLanguage) {
31545
- const langTarget = editor.inline ? targetElm : doc.documentElement;
31546
- DOM$6.setAttrib(langTarget, "lang", contentLanguage);
31547
- }
31548
31279
  const body = editor.getBody();
31549
31280
  body.disabled = true;
31550
31281
  editor.readonly = isReadOnly$1(editor);
@@ -31586,9 +31317,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
31586
31317
  setup$b(editor);
31587
31318
  setup$u(editor);
31588
31319
  setup$6(editor);
31589
- if (shouldAllowNonEditable(editor)) {
31590
- setup$s(editor);
31591
- }
31320
+ setup$s(editor);
31592
31321
  if (!isRtc(editor)) {
31593
31322
  setup$5(editor);
31594
31323
  setup$1(editor);
@@ -31625,7 +31354,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
31625
31354
  const DOM$5 = DOMUtils.DOM;
31626
31355
  const createIframeElement = (id, title, customAttrs, tabindex) => {
31627
31356
  const iframe = SugarElement.fromTag("iframe");
31628
- tabindex.each((t) => set$5(iframe, "tabindex", t));
31357
+ tabindex.each((t) => set$4(iframe, "tabindex", t));
31629
31358
  setAll$1(iframe, customAttrs);
31630
31359
  setAll$1(iframe, {
31631
31360
  id: id + "_ifr",
@@ -32246,7 +31975,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
32246
31975
  };
32247
31976
  const getSection = (sectionResult2, name2, defaults = {}) => {
32248
31977
  const sections = sectionResult2.sections();
32249
- const sectionOptions = get$b(sections, name2).getOr({});
31978
+ const sectionOptions = get$a(sections, name2).getOr({});
32250
31979
  return Tools.extend({}, defaults, sectionOptions);
32251
31980
  };
32252
31981
  const hasSection = (sectionResult2, name2) => {
@@ -32263,7 +31992,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
32263
31992
  // No nice way to do object resizing at this stage
32264
31993
  resize: false,
32265
31994
  // Editor resize doesn't make sense on mobile
32266
- toolbar_mode: get$b(mobileOptions, "toolbar_mode").getOr("scrolling"),
31995
+ toolbar_mode: get$a(mobileOptions, "toolbar_mode").getOr("scrolling"),
32267
31996
  // Use the default side-scrolling toolbar for tablets/phones
32268
31997
  toolbar_sticky: false
32269
31998
  // Only enable sticky toolbar on desktop by default
@@ -32490,7 +32219,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
32490
32219
  const getSpecifiedFontProp = (propName, rootElm, elm) => {
32491
32220
  const getProperty = (elm2) => getRaw$1(elm2, propName).orThunk(() => {
32492
32221
  if (isFont(elm2)) {
32493
- return get$b(legacyPropNames, propName).bind((legacyPropName) => getOpt(elm2, legacyPropName));
32222
+ return get$a(legacyPropNames, propName).bind((legacyPropName) => getOpt(elm2, legacyPropName));
32494
32223
  } else {
32495
32224
  return Optional.none();
32496
32225
  }
@@ -32560,8 +32289,8 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
32560
32289
  const root = SugarElement.fromDom(editor.getBody());
32561
32290
  const specifiedStyle = closest$1(elm, (elm2) => getRaw$1(elm2, "line-height"), curry(eq, root));
32562
32291
  const computedStyle = () => {
32563
- const lineHeight = parseFloat(get$8(elm, "line-height"));
32564
- const fontSize = parseFloat(get$8(elm, "font-size"));
32292
+ const lineHeight = parseFloat(get$7(elm, "line-height"));
32293
+ const fontSize = parseFloat(get$7(elm, "font-size"));
32565
32294
  return String(lineHeight / fontSize);
32566
32295
  };
32567
32296
  return specifiedStyle.getOrThunk(computedStyle);
@@ -33483,11 +33212,11 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
33483
33212
  default: defaultValue,
33484
33213
  processor
33485
33214
  };
33486
- const initValue = get$b(values2, name2).orThunk(() => get$b(initialOptions, name2));
33215
+ const initValue = get$a(values2, name2).orThunk(() => get$a(initialOptions, name2));
33487
33216
  initValue.each((value2) => setValue(name2, value2, processor));
33488
33217
  };
33489
33218
  const isRegistered = (name2) => has$2(registry2, name2);
33490
- const get2 = (name2) => get$b(values2, name2).orThunk(() => get$b(registry2, name2).map((spec) => spec.default)).getOrUndefined();
33219
+ const get2 = (name2) => get$a(values2, name2).orThunk(() => get$a(registry2, name2).map((spec) => spec.default)).getOrUndefined();
33491
33220
  const set2 = (name2, value2) => {
33492
33221
  if (!isRegistered(name2)) {
33493
33222
  console.warn(`"${name2}" is not a registered option. Ensure the option has been registered before setting a value.`);
@@ -34972,14 +34701,14 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
34972
34701
  * @property minorVersion
34973
34702
  * @type String
34974
34703
  */
34975
- minorVersion: "6.0",
34704
+ minorVersion: "3.2",
34976
34705
  /**
34977
34706
  * Release date of TinyMCE build.
34978
34707
  *
34979
34708
  * @property releaseDate
34980
34709
  * @type String
34981
34710
  */
34982
- releaseDate: "2026-06-03",
34711
+ releaseDate: "2026-01-14",
34983
34712
  /**
34984
34713
  * Collection of language pack data.
34985
34714
  *
@@ -35113,7 +34842,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
35113
34842
  const createId = (elm) => {
35114
34843
  let id = elm.id;
35115
34844
  if (!id) {
35116
- id = get$b(elm, "name").filter((name2) => !DOM.get(name2)).getOrThunk(DOM.uniqueId);
34845
+ id = get$a(elm, "name").filter((name2) => !DOM.get(name2)).getOrThunk(DOM.uniqueId);
35117
34846
  elm.setAttribute("id", id);
35118
34847
  }
35119
34848
  return id;
@@ -35427,7 +35156,7 @@ Options:${listJoiner}${deprecatedOptions2.join(listJoiner)}` : "";
35427
35156
  const FakeClipboardItem = (items) => ({
35428
35157
  items,
35429
35158
  types: keys(items),
35430
- getType: (type2) => get$b(items, type2).getOrUndefined()
35159
+ getType: (type2) => get$a(items, type2).getOrUndefined()
35431
35160
  });
35432
35161
  const write2 = (data2) => {
35433
35162
  dataValue.set(data2);
@@ -35753,4 +35482,4 @@ const tinymce$2 = /* @__PURE__ */ _mergeNamespaces({
35753
35482
  export {
35754
35483
  tinymce$2 as t
35755
35484
  };
35756
- //# sourceMappingURL=tinymce-Dg510HCs.js.map
35485
+ //# sourceMappingURL=tinymce-WPdeGquX.js.map