@orangelogic/design-system 2.56.0 → 2.57.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (131) hide show
  1. package/library/chunks/{button.CiWlWCNb.js → button.2-Io1Wm4.js} +80 -66
  2. package/library/chunks/{color-swatch-group.Bsa_Z57a.js → color-swatch-group.VXPK-2tU.js} +167 -157
  3. package/library/chunks/{color-swatch.CsKJgvVf.js → color-swatch.8OhqVqb6.js} +2 -2
  4. package/library/chunks/{confirm-popover.Bfuw361W.js → confirm-popover.DGvyB12c.js} +3 -3
  5. package/library/chunks/{content-builder.UlVFSATk.js → content-builder.WranV3P4.js} +6 -5
  6. package/library/chunks/{dialog.C28qzMSQ.js → dialog.CIeu0rVD.js} +2 -2
  7. package/library/chunks/{dot-pagination.D3RYAiHL.js → dot-pagination.CyCA3kSP.js} +1 -1
  8. package/library/chunks/{file-on-demand.Cr7E_KqH.js → file-on-demand.aux9gsvH.js} +10 -10
  9. package/library/chunks/{folder-select.ELghy6Qk.js → folder-select.B7u40ijN.js} +5 -5
  10. package/library/chunks/{format-time.HdcgoabZ.js → format-time.C56HetWv.js} +1 -1
  11. package/library/chunks/{header.oyZxakKM.js → header.RvymymCe.js} +1 -1
  12. package/library/chunks/{i18n.C3Z8Xe8q.js → i18n.dCiJrmqj.js} +74 -83
  13. package/library/chunks/{iframe.C6CLUrTT.js → iframe.Cwqniwf2.js} +1 -1
  14. package/library/chunks/{image.BJfasRY_.js → image.gpleN29o.js} +3 -3
  15. package/library/chunks/list-editor.BToq5cqp.js +1641 -0
  16. package/library/chunks/{option.BOHZB9Sv.js → option.CJ1p2V0m.js} +1 -1
  17. package/library/chunks/{popup.Ba501Rgg.js → popup.BE5MfEQJ.js} +1 -1
  18. package/library/chunks/purify.es.BGaRrCfO.js +553 -0
  19. package/library/chunks/{select.oVg7uA-M.js → select.xBh4yerC.js} +3 -3
  20. package/library/chunks/string.DPf4puTr.js +136 -0
  21. package/library/chunks/{tab-group.BWYMMhrE.js → tab-group.CjvHb3OJ.js} +3 -3
  22. package/library/chunks/{table.-ecyjIUr.js → table.CrX_NJiY.js} +2019 -1744
  23. package/library/chunks/{timecode.PY1bymeS.js → timecode.XXmVg6tU.js} +1 -1
  24. package/library/chunks/{tree.82OigIgE.js → tree.CDaFhGjU.js} +1 -1
  25. package/library/components/alert.js +1 -1
  26. package/library/components/asset-link-format.js +4 -4
  27. package/library/components/atoms.js +14 -14
  28. package/library/components/border-input-group.js +1 -1
  29. package/library/components/breadcrumb.js +1 -1
  30. package/library/components/button.js +2 -2
  31. package/library/components/color-picker.js +3 -3
  32. package/library/components/color-swatch-group.js +6 -6
  33. package/library/components/color-swatch.js +3 -3
  34. package/library/components/confirm-popover.js +4 -4
  35. package/library/components/copy-button.js +1 -1
  36. package/library/components/corner-position-input-group.js +3 -3
  37. package/library/components/details.js +1 -1
  38. package/library/components/dialog.js +3 -3
  39. package/library/components/dot-pagination.js +2 -2
  40. package/library/components/drawer.js +1 -1
  41. package/library/components/dropdown.js +2 -2
  42. package/library/components/dynamic-select.js +5 -5
  43. package/library/components/element-clamp.js +2 -2
  44. package/library/components/file-on-demand.js +11 -11
  45. package/library/components/folder-select.js +4 -4
  46. package/library/components/format-bytes.js +1 -1
  47. package/library/components/format-date.js +1 -1
  48. package/library/components/format-number.js +1 -1
  49. package/library/components/format-time.js +2 -2
  50. package/library/components/header.js +2 -2
  51. package/library/components/icon-button.js +1 -1
  52. package/library/components/iframe.js +2 -2
  53. package/library/components/image-comparer.js +1 -1
  54. package/library/components/image.js +3 -3
  55. package/library/components/input.js +1 -1
  56. package/library/components/line-clamp.js +31 -23
  57. package/library/components/list-editor.js +9 -8
  58. package/library/components/masonry.js +1 -1
  59. package/library/components/menu-item.js +2 -2
  60. package/library/components/menu.js +1 -1
  61. package/library/components/molecules.js +4 -4
  62. package/library/components/option.js +2 -2
  63. package/library/components/organisms.js +2 -2
  64. package/library/components/pagination.js +4 -4
  65. package/library/components/popup.js +2 -2
  66. package/library/components/position-picker.js +1 -1
  67. package/library/components/progress-bar.js +1 -1
  68. package/library/components/progress-ring.js +1 -1
  69. package/library/components/range.js +2 -2
  70. package/library/components/rating.js +1 -1
  71. package/library/components/relative-time.js +1 -1
  72. package/library/components/select.js +4 -4
  73. package/library/components/share-option-list.js +1 -1
  74. package/library/components/size-input-group.js +2 -2
  75. package/library/components/spinner.js +1 -1
  76. package/library/components/split-panel.js +1 -1
  77. package/library/components/tab-group.js +3 -3
  78. package/library/components/tab.js +1 -1
  79. package/library/components/table.js +2 -2
  80. package/library/components/tag.js +1 -1
  81. package/library/components/timecode.js +2 -2
  82. package/library/components/tooltip.js +2 -2
  83. package/library/components/tree-item.js +2 -2
  84. package/library/components/tree.js +2 -2
  85. package/library/components/typeface.js +1 -1
  86. package/library/components/types.js +30808 -30016
  87. package/library/components/video.js +2 -2
  88. package/library/package.json +1 -1
  89. package/library/packages/atoms/src/components/button/button.d.ts +4 -0
  90. package/library/packages/atoms/src/components/line-clamp/line-clamp.d.ts +3 -1
  91. package/library/packages/atoms/src/components/table/components/table-toolbar/table-saved-search-dropdown.d.ts +60 -0
  92. package/library/packages/atoms/src/components/table/components/table-toolbar/table-toolbar.d.ts +38 -5
  93. package/library/packages/atoms/src/components/table/table.d.ts +28 -5
  94. package/library/packages/atoms/src/components/table/tabulator-tables/core/row/Row.d.ts +2 -2
  95. package/library/packages/events/src/cx-content-builder-translatable-value-change.d.ts +13 -0
  96. package/library/packages/events/src/cx-table-export.d.ts +1 -1
  97. package/library/packages/events/src/cx-table-save-search-select.d.ts +8 -0
  98. package/library/packages/events/src/events.d.ts +2 -0
  99. package/library/packages/molecules/src/data-tab-group/data-tab-group.d.ts +1 -0
  100. package/library/packages/molecules/src/details-group/details-group.d.ts +1 -0
  101. package/library/packages/molecules/src/list-editor/list-editor.d.ts +14 -0
  102. package/library/packages/molecules/src/timeline/timeline.d.ts +4 -0
  103. package/library/packages/organisms/src/color-swatch-group/color-swatch-group.d.ts +1 -0
  104. package/library/packages/organisms/src/comment/comment.d.ts +13 -0
  105. package/library/packages/organisms/src/comment/components/comment-menu/comment-menu.d.ts +14 -0
  106. package/library/packages/organisms/src/content-builder/components/color-swatch-picker/color-swatch-picker.d.ts +21 -0
  107. package/library/packages/organisms/src/content-builder/components/config-form/config-form-controller.d.ts +19 -0
  108. package/library/packages/organisms/src/content-builder/components/config-form/config-form.d.ts +28 -8
  109. package/library/packages/organisms/src/content-builder/components/config-manager/config-manager.d.ts +28 -1
  110. package/library/packages/organisms/src/content-builder/components/gallery-config/gallery-config.d.ts +1 -0
  111. package/library/packages/organisms/src/content-builder/configs/accordion.d.ts +1 -0
  112. package/library/packages/organisms/src/content-builder/configs/color-swatches.d.ts +1 -0
  113. package/library/packages/organisms/src/content-builder/configs/gallery.d.ts +2 -0
  114. package/library/packages/organisms/src/content-builder/configs/tab-group.d.ts +1 -0
  115. package/library/packages/organisms/src/content-builder/configs/timeline.d.ts +1 -0
  116. package/library/packages/organisms/src/content-builder/configs-controller.d.ts +10 -0
  117. package/library/packages/organisms/src/content-builder/content-builder-constants.d.ts +2 -0
  118. package/library/packages/organisms/src/content-builder/content-builder.d.ts +19 -2
  119. package/library/packages/organisms/src/content-builder/content-builder.utils.d.ts +0 -7
  120. package/library/packages/organisms/src/content-builder/plugins/plugin-factory.d.ts +1 -0
  121. package/library/packages/organisms/src/content-builder/styleController.d.ts +3 -1
  122. package/library/packages/types/src/color-swatch.d.ts +1 -0
  123. package/library/packages/types/src/content-builder.d.ts +7 -0
  124. package/library/packages/types/src/table.d.ts +13 -1
  125. package/library/packages/utils/src/custom-element/i18n-utils.d.ts +2 -0
  126. package/library/packages/utils/src/custom-element/i18n.d.ts +32 -9
  127. package/library/packages/utils/src/string/string.d.ts +2 -0
  128. package/library/react-web-component.d.ts +115 -58
  129. package/package.json +1 -1
  130. package/library/chunks/list-editor.Ct803qvF.js +0 -737
  131. package/library/chunks/string.D6poLUEC.js +0 -678
@@ -1,678 +0,0 @@
1
- var $e = /* @__PURE__ */ ((e) => (e.Track = "track", e.Transition = "transition", e))($e || {}), I = /* @__PURE__ */ ((e) => (e.Frames = "Frames", e.SMPTE = "SMPTE", e.Standard = "Standard", e))(I || {});
2
- const bn = 50;
3
- /*! @license DOMPurify 3.3.0 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.0/LICENSE */
4
- const {
5
- entries: Ae,
6
- setPrototypeOf: me,
7
- isFrozen: Xe,
8
- getPrototypeOf: je,
9
- getOwnPropertyDescriptor: Ve
10
- } = Object;
11
- let {
12
- freeze: L,
13
- seal: D,
14
- create: Ut
15
- } = Object, {
16
- apply: Ht,
17
- construct: zt
18
- } = typeof Reflect < "u" && Reflect;
19
- L || (L = function(o) {
20
- return o;
21
- });
22
- D || (D = function(o) {
23
- return o;
24
- });
25
- Ht || (Ht = function(o, r) {
26
- for (var a = arguments.length, l = new Array(a > 2 ? a - 2 : 0), u = 2; u < a; u++)
27
- l[u - 2] = arguments[u];
28
- return o.apply(r, l);
29
- });
30
- zt || (zt = function(o) {
31
- for (var r = arguments.length, a = new Array(r > 1 ? r - 1 : 0), l = 1; l < r; l++)
32
- a[l - 1] = arguments[l];
33
- return new o(...a);
34
- });
35
- const dt = O(Array.prototype.forEach), Ze = O(Array.prototype.lastIndexOf), pe = O(Array.prototype.pop), tt = O(Array.prototype.push), qe = O(Array.prototype.splice), ht = O(String.prototype.toLowerCase), wt = O(String.prototype.toString), xt = O(String.prototype.match), et = O(String.prototype.replace), Ke = O(String.prototype.indexOf), Qe = O(String.prototype.trim), C = O(Object.prototype.hasOwnProperty), N = O(RegExp.prototype.test), nt = Je(TypeError);
36
- function O(e) {
37
- return function(o) {
38
- o instanceof RegExp && (o.lastIndex = 0);
39
- for (var r = arguments.length, a = new Array(r > 1 ? r - 1 : 0), l = 1; l < r; l++)
40
- a[l - 1] = arguments[l];
41
- return Ht(e, o, a);
42
- };
43
- }
44
- function Je(e) {
45
- return function() {
46
- for (var o = arguments.length, r = new Array(o), a = 0; a < o; a++)
47
- r[a] = arguments[a];
48
- return zt(e, r);
49
- };
50
- }
51
- function c(e, o) {
52
- let r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : ht;
53
- me && me(e, null);
54
- let a = o.length;
55
- for (; a--; ) {
56
- let l = o[a];
57
- if (typeof l == "string") {
58
- const u = r(l);
59
- u !== l && (Xe(o) || (o[a] = u), l = u);
60
- }
61
- e[l] = !0;
62
- }
63
- return e;
64
- }
65
- function tn(e) {
66
- for (let o = 0; o < e.length; o++)
67
- C(e, o) || (e[o] = null);
68
- return e;
69
- }
70
- function F(e) {
71
- const o = Ut(null);
72
- for (const [r, a] of Ae(e))
73
- C(e, r) && (Array.isArray(a) ? o[r] = tn(a) : a && typeof a == "object" && a.constructor === Object ? o[r] = F(a) : o[r] = a);
74
- return o;
75
- }
76
- function ot(e, o) {
77
- for (; e !== null; ) {
78
- const a = Ve(e, o);
79
- if (a) {
80
- if (a.get)
81
- return O(a.get);
82
- if (typeof a.value == "function")
83
- return O(a.value);
84
- }
85
- e = je(e);
86
- }
87
- function r() {
88
- return null;
89
- }
90
- return r;
91
- }
92
- const de = L(["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"]), Pt = L(["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"]), vt = L(["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"]), en = L(["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"]), kt = L(["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"]), nn = L(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), Te = L(["#text"]), he = L(["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", "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", "slot"]), Ft = L(["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"]), ge = L(["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"]), Tt = L(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), on = D(/\{\{[\w\W]*|[\w\W]*\}\}/gm), rn = D(/<%[\w\W]*|[\w\W]*%>/gm), an = D(/\$\{[\w\W]*/gm), sn = D(/^data-[\-\w.\u00B7-\uFFFF]+$/), ln = D(/^aria-[\-\w]+$/), Se = D(
93
- /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i
94
- // eslint-disable-line no-useless-escape
95
- ), cn = D(/^(?:\w+script|data):/i), un = D(
96
- /[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g
97
- // eslint-disable-line no-control-regex
98
- ), be = D(/^html$/i), fn = D(/^[a-z][.\w]*(-[.\w]+)+$/i);
99
- var Ee = /* @__PURE__ */ Object.freeze({
100
- __proto__: null,
101
- ARIA_ATTR: ln,
102
- ATTR_WHITESPACE: un,
103
- CUSTOM_ELEMENT: fn,
104
- DATA_ATTR: sn,
105
- DOCTYPE_NAME: be,
106
- ERB_EXPR: rn,
107
- IS_ALLOWED_URI: Se,
108
- IS_SCRIPT_OR_DATA: cn,
109
- MUSTACHE_EXPR: on,
110
- TMPLIT_EXPR: an
111
- });
112
- const rt = {
113
- element: 1,
114
- text: 3,
115
- // Deprecated
116
- progressingInstruction: 7,
117
- comment: 8,
118
- document: 9
119
- }, mn = function() {
120
- return typeof window > "u" ? null : window;
121
- }, pn = function(o, r) {
122
- if (typeof o != "object" || typeof o.createPolicy != "function")
123
- return null;
124
- let a = null;
125
- const l = "data-tt-policy-suffix";
126
- r && r.hasAttribute(l) && (a = r.getAttribute(l));
127
- const u = "dompurify" + (a ? "#" + a : "");
128
- try {
129
- return o.createPolicy(u, {
130
- createHTML(T) {
131
- return T;
132
- },
133
- createScriptURL(T) {
134
- return T;
135
- }
136
- });
137
- } catch {
138
- return console.warn("TrustedTypes policy " + u + " could not be created."), null;
139
- }
140
- }, _e = function() {
141
- return {
142
- afterSanitizeAttributes: [],
143
- afterSanitizeElements: [],
144
- afterSanitizeShadowDOM: [],
145
- beforeSanitizeAttributes: [],
146
- beforeSanitizeElements: [],
147
- beforeSanitizeShadowDOM: [],
148
- uponSanitizeAttribute: [],
149
- uponSanitizeElement: [],
150
- uponSanitizeShadowNode: []
151
- };
152
- };
153
- function Re() {
154
- let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : mn();
155
- const o = (s) => Re(s);
156
- if (o.version = "3.3.0", o.removed = [], !e || !e.document || e.document.nodeType !== rt.document || !e.Element)
157
- return o.isSupported = !1, o;
158
- let {
159
- document: r
160
- } = e;
161
- const a = r, l = a.currentScript, {
162
- DocumentFragment: u,
163
- HTMLTemplateElement: T,
164
- Node: y,
165
- Element: p,
166
- NodeFilter: A,
167
- NamedNodeMap: w = e.NamedNodeMap || e.MozNamedAttrMap,
168
- HTMLFormElement: V,
169
- DOMParser: Ne,
170
- trustedTypes: at
171
- } = e, Z = p.prototype, Le = ot(Z, "cloneNode"), Oe = ot(Z, "remove"), ye = ot(Z, "nextSibling"), Me = ot(Z, "childNodes"), it = ot(Z, "parentNode");
172
- if (typeof T == "function") {
173
- const s = r.createElement("template");
174
- s.content && s.content.ownerDocument && (r = s.content.ownerDocument);
175
- }
176
- let b, q = "";
177
- const {
178
- implementation: gt,
179
- createNodeIterator: Ie,
180
- createDocumentFragment: De,
181
- getElementsByTagName: Ce
182
- } = r, {
183
- importNode: we
184
- } = a;
185
- let R = _e();
186
- o.isSupported = typeof Ae == "function" && typeof it == "function" && gt && gt.createHTMLDocument !== void 0;
187
- const {
188
- MUSTACHE_EXPR: Et,
189
- ERB_EXPR: _t,
190
- TMPLIT_EXPR: At,
191
- DATA_ATTR: xe,
192
- ARIA_ATTR: Pe,
193
- IS_SCRIPT_OR_DATA: ve,
194
- ATTR_WHITESPACE: Gt,
195
- CUSTOM_ELEMENT: ke
196
- } = Ee;
197
- let {
198
- IS_ALLOWED_URI: Wt
199
- } = Ee, h = null;
200
- const Bt = c({}, [...de, ...Pt, ...vt, ...kt, ...Te]);
201
- let E = null;
202
- const Yt = c({}, [...he, ...Ft, ...ge, ...Tt]);
203
- let m = Object.seal(Ut(null, {
204
- tagNameCheck: {
205
- writable: !0,
206
- configurable: !1,
207
- enumerable: !0,
208
- value: null
209
- },
210
- attributeNameCheck: {
211
- writable: !0,
212
- configurable: !1,
213
- enumerable: !0,
214
- value: null
215
- },
216
- allowCustomizedBuiltInElements: {
217
- writable: !0,
218
- configurable: !1,
219
- enumerable: !0,
220
- value: !1
221
- }
222
- })), K = null, St = null;
223
- const z = Object.seal(Ut(null, {
224
- tagCheck: {
225
- writable: !0,
226
- configurable: !1,
227
- enumerable: !0,
228
- value: null
229
- },
230
- attributeCheck: {
231
- writable: !0,
232
- configurable: !1,
233
- enumerable: !0,
234
- value: null
235
- }
236
- }));
237
- let $t = !0, bt = !0, Xt = !1, jt = !0, G = !1, st = !0, U = !1, Rt = !1, Nt = !1, W = !1, lt = !1, ct = !1, Vt = !0, Zt = !1;
238
- const Fe = "user-content-";
239
- let Lt = !0, Q = !1, B = {}, Y = null;
240
- const qt = c({}, ["annotation-xml", "audio", "colgroup", "desc", "foreignobject", "head", "iframe", "math", "mi", "mn", "mo", "ms", "mtext", "noembed", "noframes", "noscript", "plaintext", "script", "style", "svg", "template", "thead", "title", "video", "xmp"]);
241
- let Kt = null;
242
- const Qt = c({}, ["audio", "video", "img", "source", "image", "track"]);
243
- let Ot = null;
244
- const Jt = c({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), ut = "http://www.w3.org/1998/Math/MathML", ft = "http://www.w3.org/2000/svg", P = "http://www.w3.org/1999/xhtml";
245
- let $ = P, yt = !1, Mt = null;
246
- const Ue = c({}, [ut, ft, P], wt);
247
- let mt = c({}, ["mi", "mo", "mn", "ms", "mtext"]), pt = c({}, ["annotation-xml"]);
248
- const He = c({}, ["title", "style", "font", "a", "script"]);
249
- let J = null;
250
- const ze = ["application/xhtml+xml", "text/html"], Ge = "text/html";
251
- let g = null, X = null;
252
- const We = r.createElement("form"), te = function(t) {
253
- return t instanceof RegExp || t instanceof Function;
254
- }, It = function() {
255
- let t = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
256
- if (!(X && X === t)) {
257
- if ((!t || typeof t != "object") && (t = {}), t = F(t), J = // eslint-disable-next-line unicorn/prefer-includes
258
- ze.indexOf(t.PARSER_MEDIA_TYPE) === -1 ? Ge : t.PARSER_MEDIA_TYPE, g = J === "application/xhtml+xml" ? wt : ht, h = C(t, "ALLOWED_TAGS") ? c({}, t.ALLOWED_TAGS, g) : Bt, E = C(t, "ALLOWED_ATTR") ? c({}, t.ALLOWED_ATTR, g) : Yt, Mt = C(t, "ALLOWED_NAMESPACES") ? c({}, t.ALLOWED_NAMESPACES, wt) : Ue, Ot = C(t, "ADD_URI_SAFE_ATTR") ? c(F(Jt), t.ADD_URI_SAFE_ATTR, g) : Jt, Kt = C(t, "ADD_DATA_URI_TAGS") ? c(F(Qt), t.ADD_DATA_URI_TAGS, g) : Qt, Y = C(t, "FORBID_CONTENTS") ? c({}, t.FORBID_CONTENTS, g) : qt, K = C(t, "FORBID_TAGS") ? c({}, t.FORBID_TAGS, g) : F({}), St = C(t, "FORBID_ATTR") ? c({}, t.FORBID_ATTR, g) : F({}), B = C(t, "USE_PROFILES") ? t.USE_PROFILES : !1, $t = t.ALLOW_ARIA_ATTR !== !1, bt = t.ALLOW_DATA_ATTR !== !1, Xt = t.ALLOW_UNKNOWN_PROTOCOLS || !1, jt = t.ALLOW_SELF_CLOSE_IN_ATTR !== !1, G = t.SAFE_FOR_TEMPLATES || !1, st = t.SAFE_FOR_XML !== !1, U = t.WHOLE_DOCUMENT || !1, W = t.RETURN_DOM || !1, lt = t.RETURN_DOM_FRAGMENT || !1, ct = t.RETURN_TRUSTED_TYPE || !1, Nt = t.FORCE_BODY || !1, Vt = t.SANITIZE_DOM !== !1, Zt = t.SANITIZE_NAMED_PROPS || !1, Lt = t.KEEP_CONTENT !== !1, Q = t.IN_PLACE || !1, Wt = t.ALLOWED_URI_REGEXP || Se, $ = t.NAMESPACE || P, mt = t.MATHML_TEXT_INTEGRATION_POINTS || mt, pt = t.HTML_INTEGRATION_POINTS || pt, m = t.CUSTOM_ELEMENT_HANDLING || {}, t.CUSTOM_ELEMENT_HANDLING && te(t.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (m.tagNameCheck = t.CUSTOM_ELEMENT_HANDLING.tagNameCheck), t.CUSTOM_ELEMENT_HANDLING && te(t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (m.attributeNameCheck = t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), t.CUSTOM_ELEMENT_HANDLING && typeof t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (m.allowCustomizedBuiltInElements = t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), G && (bt = !1), lt && (W = !0), B && (h = c({}, Te), E = [], B.html === !0 && (c(h, de), c(E, he)), B.svg === !0 && (c(h, Pt), c(E, Ft), c(E, Tt)), B.svgFilters === !0 && (c(h, vt), c(E, Ft), c(E, Tt)), B.mathMl === !0 && (c(h, kt), c(E, ge), c(E, Tt))), t.ADD_TAGS && (typeof t.ADD_TAGS == "function" ? z.tagCheck = t.ADD_TAGS : (h === Bt && (h = F(h)), c(h, t.ADD_TAGS, g))), t.ADD_ATTR && (typeof t.ADD_ATTR == "function" ? z.attributeCheck = t.ADD_ATTR : (E === Yt && (E = F(E)), c(E, t.ADD_ATTR, g))), t.ADD_URI_SAFE_ATTR && c(Ot, t.ADD_URI_SAFE_ATTR, g), t.FORBID_CONTENTS && (Y === qt && (Y = F(Y)), c(Y, t.FORBID_CONTENTS, g)), Lt && (h["#text"] = !0), U && c(h, ["html", "head", "body"]), h.table && (c(h, ["tbody"]), delete K.tbody), t.TRUSTED_TYPES_POLICY) {
259
- if (typeof t.TRUSTED_TYPES_POLICY.createHTML != "function")
260
- throw nt('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
261
- if (typeof t.TRUSTED_TYPES_POLICY.createScriptURL != "function")
262
- throw nt('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
263
- b = t.TRUSTED_TYPES_POLICY, q = b.createHTML("");
264
- } else
265
- b === void 0 && (b = pn(at, l)), b !== null && typeof q == "string" && (q = b.createHTML(""));
266
- L && L(t), X = t;
267
- }
268
- }, ee = c({}, [...Pt, ...vt, ...en]), ne = c({}, [...kt, ...nn]), Be = function(t) {
269
- let n = it(t);
270
- (!n || !n.tagName) && (n = {
271
- namespaceURI: $,
272
- tagName: "template"
273
- });
274
- const i = ht(t.tagName), f = ht(n.tagName);
275
- return Mt[t.namespaceURI] ? t.namespaceURI === ft ? n.namespaceURI === P ? i === "svg" : n.namespaceURI === ut ? i === "svg" && (f === "annotation-xml" || mt[f]) : !!ee[i] : t.namespaceURI === ut ? n.namespaceURI === P ? i === "math" : n.namespaceURI === ft ? i === "math" && pt[f] : !!ne[i] : t.namespaceURI === P ? n.namespaceURI === ft && !pt[f] || n.namespaceURI === ut && !mt[f] ? !1 : !ne[i] && (He[i] || !ee[i]) : !!(J === "application/xhtml+xml" && Mt[t.namespaceURI]) : !1;
276
- }, x = function(t) {
277
- tt(o.removed, {
278
- element: t
279
- });
280
- try {
281
- it(t).removeChild(t);
282
- } catch {
283
- Oe(t);
284
- }
285
- }, H = function(t, n) {
286
- try {
287
- tt(o.removed, {
288
- attribute: n.getAttributeNode(t),
289
- from: n
290
- });
291
- } catch {
292
- tt(o.removed, {
293
- attribute: null,
294
- from: n
295
- });
296
- }
297
- if (n.removeAttribute(t), t === "is")
298
- if (W || lt)
299
- try {
300
- x(n);
301
- } catch {
302
- }
303
- else
304
- try {
305
- n.setAttribute(t, "");
306
- } catch {
307
- }
308
- }, oe = function(t) {
309
- let n = null, i = null;
310
- if (Nt)
311
- t = "<remove></remove>" + t;
312
- else {
313
- const d = xt(t, /^[\r\n\t ]+/);
314
- i = d && d[0];
315
- }
316
- J === "application/xhtml+xml" && $ === P && (t = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + t + "</body></html>");
317
- const f = b ? b.createHTML(t) : t;
318
- if ($ === P)
319
- try {
320
- n = new Ne().parseFromString(f, J);
321
- } catch {
322
- }
323
- if (!n || !n.documentElement) {
324
- n = gt.createDocument($, "template", null);
325
- try {
326
- n.documentElement.innerHTML = yt ? q : f;
327
- } catch {
328
- }
329
- }
330
- const S = n.body || n.documentElement;
331
- return t && i && S.insertBefore(r.createTextNode(i), S.childNodes[0] || null), $ === P ? Ce.call(n, U ? "html" : "body")[0] : U ? n.documentElement : S;
332
- }, re = function(t) {
333
- return Ie.call(
334
- t.ownerDocument || t,
335
- t,
336
- // eslint-disable-next-line no-bitwise
337
- A.SHOW_ELEMENT | A.SHOW_COMMENT | A.SHOW_TEXT | A.SHOW_PROCESSING_INSTRUCTION | A.SHOW_CDATA_SECTION,
338
- null
339
- );
340
- }, Dt = function(t) {
341
- return t instanceof V && (typeof t.nodeName != "string" || typeof t.textContent != "string" || typeof t.removeChild != "function" || !(t.attributes instanceof w) || typeof t.removeAttribute != "function" || typeof t.setAttribute != "function" || typeof t.namespaceURI != "string" || typeof t.insertBefore != "function" || typeof t.hasChildNodes != "function");
342
- }, ae = function(t) {
343
- return typeof y == "function" && t instanceof y;
344
- };
345
- function v(s, t, n) {
346
- dt(s, (i) => {
347
- i.call(o, t, n, X);
348
- });
349
- }
350
- const ie = function(t) {
351
- let n = null;
352
- if (v(R.beforeSanitizeElements, t, null), Dt(t))
353
- return x(t), !0;
354
- const i = g(t.nodeName);
355
- if (v(R.uponSanitizeElement, t, {
356
- tagName: i,
357
- allowedTags: h
358
- }), st && t.hasChildNodes() && !ae(t.firstElementChild) && N(/<[/\w!]/g, t.innerHTML) && N(/<[/\w!]/g, t.textContent) || t.nodeType === rt.progressingInstruction || st && t.nodeType === rt.comment && N(/<[/\w]/g, t.data))
359
- return x(t), !0;
360
- if (!(z.tagCheck instanceof Function && z.tagCheck(i)) && (!h[i] || K[i])) {
361
- if (!K[i] && le(i) && (m.tagNameCheck instanceof RegExp && N(m.tagNameCheck, i) || m.tagNameCheck instanceof Function && m.tagNameCheck(i)))
362
- return !1;
363
- if (Lt && !Y[i]) {
364
- const f = it(t) || t.parentNode, S = Me(t) || t.childNodes;
365
- if (S && f) {
366
- const d = S.length;
367
- for (let M = d - 1; M >= 0; --M) {
368
- const k = Le(S[M], !0);
369
- k.__removalCount = (t.__removalCount || 0) + 1, f.insertBefore(k, ye(t));
370
- }
371
- }
372
- }
373
- return x(t), !0;
374
- }
375
- return t instanceof p && !Be(t) || (i === "noscript" || i === "noembed" || i === "noframes") && N(/<\/no(script|embed|frames)/i, t.innerHTML) ? (x(t), !0) : (G && t.nodeType === rt.text && (n = t.textContent, dt([Et, _t, At], (f) => {
376
- n = et(n, f, " ");
377
- }), t.textContent !== n && (tt(o.removed, {
378
- element: t.cloneNode()
379
- }), t.textContent = n)), v(R.afterSanitizeElements, t, null), !1);
380
- }, se = function(t, n, i) {
381
- if (Vt && (n === "id" || n === "name") && (i in r || i in We))
382
- return !1;
383
- if (!(bt && !St[n] && N(xe, n))) {
384
- if (!($t && N(Pe, n))) {
385
- if (!(z.attributeCheck instanceof Function && z.attributeCheck(n, t))) {
386
- if (!E[n] || St[n]) {
387
- if (
388
- // First condition does a very basic check if a) it's basically a valid custom element tagname AND
389
- // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
390
- // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
391
- !(le(t) && (m.tagNameCheck instanceof RegExp && N(m.tagNameCheck, t) || m.tagNameCheck instanceof Function && m.tagNameCheck(t)) && (m.attributeNameCheck instanceof RegExp && N(m.attributeNameCheck, n) || m.attributeNameCheck instanceof Function && m.attributeNameCheck(n, t)) || // Alternative, second condition checks if it's an `is`-attribute, AND
392
- // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
393
- n === "is" && m.allowCustomizedBuiltInElements && (m.tagNameCheck instanceof RegExp && N(m.tagNameCheck, i) || m.tagNameCheck instanceof Function && m.tagNameCheck(i)))
394
- ) return !1;
395
- } else if (!Ot[n]) {
396
- if (!N(Wt, et(i, Gt, ""))) {
397
- if (!((n === "src" || n === "xlink:href" || n === "href") && t !== "script" && Ke(i, "data:") === 0 && Kt[t])) {
398
- if (!(Xt && !N(ve, et(i, Gt, "")))) {
399
- if (i)
400
- return !1;
401
- }
402
- }
403
- }
404
- }
405
- }
406
- }
407
- }
408
- return !0;
409
- }, le = function(t) {
410
- return t !== "annotation-xml" && xt(t, ke);
411
- }, ce = function(t) {
412
- v(R.beforeSanitizeAttributes, t, null);
413
- const {
414
- attributes: n
415
- } = t;
416
- if (!n || Dt(t))
417
- return;
418
- const i = {
419
- attrName: "",
420
- attrValue: "",
421
- keepAttr: !0,
422
- allowedAttributes: E,
423
- forceKeepAttr: void 0
424
- };
425
- let f = n.length;
426
- for (; f--; ) {
427
- const S = n[f], {
428
- name: d,
429
- namespaceURI: M,
430
- value: k
431
- } = S, j = g(d), Ct = k;
432
- let _ = d === "value" ? Ct : Qe(Ct);
433
- if (i.attrName = j, i.attrValue = _, i.keepAttr = !0, i.forceKeepAttr = void 0, v(R.uponSanitizeAttribute, t, i), _ = i.attrValue, Zt && (j === "id" || j === "name") && (H(d, t), _ = Fe + _), st && N(/((--!?|])>)|<\/(style|title|textarea)/i, _)) {
434
- H(d, t);
435
- continue;
436
- }
437
- if (j === "attributename" && xt(_, "href")) {
438
- H(d, t);
439
- continue;
440
- }
441
- if (i.forceKeepAttr)
442
- continue;
443
- if (!i.keepAttr) {
444
- H(d, t);
445
- continue;
446
- }
447
- if (!jt && N(/\/>/i, _)) {
448
- H(d, t);
449
- continue;
450
- }
451
- G && dt([Et, _t, At], (fe) => {
452
- _ = et(_, fe, " ");
453
- });
454
- const ue = g(t.nodeName);
455
- if (!se(ue, j, _)) {
456
- H(d, t);
457
- continue;
458
- }
459
- if (b && typeof at == "object" && typeof at.getAttributeType == "function" && !M)
460
- switch (at.getAttributeType(ue, j)) {
461
- case "TrustedHTML": {
462
- _ = b.createHTML(_);
463
- break;
464
- }
465
- case "TrustedScriptURL": {
466
- _ = b.createScriptURL(_);
467
- break;
468
- }
469
- }
470
- if (_ !== Ct)
471
- try {
472
- M ? t.setAttributeNS(M, d, _) : t.setAttribute(d, _), Dt(t) ? x(t) : pe(o.removed);
473
- } catch {
474
- H(d, t);
475
- }
476
- }
477
- v(R.afterSanitizeAttributes, t, null);
478
- }, Ye = function s(t) {
479
- let n = null;
480
- const i = re(t);
481
- for (v(R.beforeSanitizeShadowDOM, t, null); n = i.nextNode(); )
482
- v(R.uponSanitizeShadowNode, n, null), ie(n), ce(n), n.content instanceof u && s(n.content);
483
- v(R.afterSanitizeShadowDOM, t, null);
484
- };
485
- return o.sanitize = function(s) {
486
- let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, n = null, i = null, f = null, S = null;
487
- if (yt = !s, yt && (s = "<!-->"), typeof s != "string" && !ae(s))
488
- if (typeof s.toString == "function") {
489
- if (s = s.toString(), typeof s != "string")
490
- throw nt("dirty is not a string, aborting");
491
- } else
492
- throw nt("toString is not a function");
493
- if (!o.isSupported)
494
- return s;
495
- if (Rt || It(t), o.removed = [], typeof s == "string" && (Q = !1), Q) {
496
- if (s.nodeName) {
497
- const k = g(s.nodeName);
498
- if (!h[k] || K[k])
499
- throw nt("root node is forbidden and cannot be sanitized in-place");
500
- }
501
- } else if (s instanceof y)
502
- n = oe("<!---->"), i = n.ownerDocument.importNode(s, !0), i.nodeType === rt.element && i.nodeName === "BODY" || i.nodeName === "HTML" ? n = i : n.appendChild(i);
503
- else {
504
- if (!W && !G && !U && // eslint-disable-next-line unicorn/prefer-includes
505
- s.indexOf("<") === -1)
506
- return b && ct ? b.createHTML(s) : s;
507
- if (n = oe(s), !n)
508
- return W ? null : ct ? q : "";
509
- }
510
- n && Nt && x(n.firstChild);
511
- const d = re(Q ? s : n);
512
- for (; f = d.nextNode(); )
513
- ie(f), ce(f), f.content instanceof u && Ye(f.content);
514
- if (Q)
515
- return s;
516
- if (W) {
517
- if (lt)
518
- for (S = De.call(n.ownerDocument); n.firstChild; )
519
- S.appendChild(n.firstChild);
520
- else
521
- S = n;
522
- return (E.shadowroot || E.shadowrootmode) && (S = we.call(a, S, !0)), S;
523
- }
524
- let M = U ? n.outerHTML : n.innerHTML;
525
- return U && h["!doctype"] && n.ownerDocument && n.ownerDocument.doctype && n.ownerDocument.doctype.name && N(be, n.ownerDocument.doctype.name) && (M = "<!DOCTYPE " + n.ownerDocument.doctype.name + `>
526
- ` + M), G && dt([Et, _t, At], (k) => {
527
- M = et(M, k, " ");
528
- }), b && ct ? b.createHTML(M) : M;
529
- }, o.setConfig = function() {
530
- let s = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
531
- It(s), Rt = !0;
532
- }, o.clearConfig = function() {
533
- X = null, Rt = !1;
534
- }, o.isValidAttribute = function(s, t, n) {
535
- X || It({});
536
- const i = g(s), f = g(t);
537
- return se(i, f, n);
538
- }, o.addHook = function(s, t) {
539
- typeof t == "function" && tt(R[s], t);
540
- }, o.removeHook = function(s, t) {
541
- if (t !== void 0) {
542
- const n = Ze(R[s], t);
543
- return n === -1 ? void 0 : qe(R[s], n, 1)[0];
544
- }
545
- return pe(R[s]);
546
- }, o.removeHooks = function(s) {
547
- R[s] = [];
548
- }, o.removeAllHooks = function() {
549
- R = _e();
550
- }, o;
551
- }
552
- var dn = Re();
553
- function Rn(e) {
554
- if (typeof e != "string")
555
- return null;
556
- const o = e.trim(), r = o.charAt(0).toUpperCase(), a = o.slice(1);
557
- return `${r}${a}`;
558
- }
559
- const Nn = (e, o, r, a) => e && e.length > o ? e.substring(0, r) + " ... " + e.substring(e.length - a, e.length) : e, Ln = (e) => e ? e.replaceAll(/([a-z0-9])([A-Z])/g, "$1 $2").replaceAll(/([A-Z])([A-Z][a-z])/g, "$1 $2").replaceAll(/([a-zA-Z])([0-9])/g, "$1 $2").replaceAll(/([0-9])([a-zA-Z])/g, "$1 $2").replaceAll(/\s+/g, " ").trim().toLowerCase() : "";
560
- function On(e, o = {}) {
561
- const {
562
- frameRate: r = 24,
563
- mode: a = I.Standard,
564
- showHours: l = !1,
565
- showMilliseconds: u = !1
566
- } = o, T = Number.isFinite(r) && r > 0 ? r : 24;
567
- if (typeof e != "number" || Number.isNaN(e) || e < 0)
568
- switch (a) {
569
- case I.Frames:
570
- return "0";
571
- case I.SMPTE:
572
- return "00:00:00:00";
573
- case I.Standard:
574
- return l ? "00:00:00" : "00:00";
575
- default:
576
- return "00:00";
577
- }
578
- switch (a) {
579
- case I.SMPTE:
580
- return hn(e, T);
581
- case I.Frames:
582
- return gn(e, T);
583
- case I.Standard:
584
- default:
585
- return En(e, u, l);
586
- }
587
- }
588
- function Tn(e) {
589
- return Math.abs(e - 29.97) < 0.01 || Math.abs(e - 59.94) < 0.01;
590
- }
591
- function hn(e, o) {
592
- const r = Math.floor(e), a = e - r, l = Math.floor(a * o), u = Math.floor(r / 3600), T = Math.floor(r % 3600 / 60), y = r % 60, p = Tn(o) ? ";" : ":";
593
- return u.toString().padStart(2, "0") + ":" + T.toString().padStart(2, "0") + ":" + y.toString().padStart(2, "0") + p + l.toString().padStart(2, "0");
594
- }
595
- function gn(e, o) {
596
- const r = e * o;
597
- return Math.floor(r + 1e-9).toString();
598
- }
599
- function En(e, o, r) {
600
- const a = Math.round(e * 100) / 100, l = Math.floor(a / 3600), u = Math.floor(a % 3600 / 60), T = Math.floor(a % 60), y = Math.round(a % 1 * 100), p = [];
601
- return (r || l > 0) && p.push(l.toString().padStart(2, "0")), p.push(u.toString().padStart(2, "0")), o && y > 0 ? p.push(
602
- `${T.toString().padStart(2, "0")}.${y.toString().padStart(2, "0")}`
603
- ) : p.push(T.toString().padStart(2, "0")), p.join(":");
604
- }
605
- function yn(e) {
606
- return e.endsWith("/") ? e : `${e}/`;
607
- }
608
- function Mn(e, o = {}) {
609
- const { frameRate: r = 24, mode: a = I.Standard } = o, l = Number.isFinite(r) && r > 0 ? r : 24;
610
- if (!e || typeof e != "string")
611
- return 0;
612
- const u = e.trim();
613
- if (u === "")
614
- return 0;
615
- switch (a) {
616
- case I.SMPTE:
617
- return _n(u, l);
618
- case I.Frames:
619
- return An(u, l);
620
- case I.Standard:
621
- default:
622
- return Sn(u);
623
- }
624
- }
625
- function _n(e, o) {
626
- const r = /^(\d{1,2}):(\d{1,2}):(\d{1,2})[:;](\d{1,2})$/, a = e.match(r);
627
- if (!a)
628
- return 0;
629
- const [, l, u, T, y] = a, p = Number.parseInt(l, 10), A = Number.parseInt(u, 10), w = Number.parseInt(T, 10), V = Number.parseInt(y, 10);
630
- return p < 0 || p > 23 || A < 0 || A > 59 || w < 0 || w > 59 || V < 0 || V >= o ? 0 : p * 3600 + A * 60 + w + V / o;
631
- }
632
- function An(e, o) {
633
- const r = Number.parseInt(e, 10);
634
- return Number.isNaN(r) || r < 0 ? 0 : r / o;
635
- }
636
- function Sn(e) {
637
- const o = /^(\d{1,2}):(\d{1,2})(?::(\d{1,2}))?(?:\.(\d{1,2}))?$/, r = e.match(o);
638
- if (!r)
639
- return 0;
640
- const [, a, l, u, T] = r;
641
- let y = 0, p = 0, A = 0, w = 0;
642
- if (u !== void 0 ? (y = Number.parseInt(a, 10), p = Number.parseInt(l, 10), A = Number.parseInt(u, 10)) : (p = Number.parseInt(a, 10), A = Number.parseInt(l, 10)), T !== void 0 && (w = Number.parseInt(T, 10)), y < 0 || p < 0 || A < 0 || w < 0)
643
- return 0;
644
- if (u !== void 0) {
645
- if (p > 59 || A > 59)
646
- return 0;
647
- } else if (A > 59)
648
- return 0;
649
- return w > 99 ? 0 : y * 3600 + p * 60 + A + w / 100;
650
- }
651
- function In(e) {
652
- if (typeof e != "string" || e.length === 0)
653
- return null;
654
- const o = e.split(/[?#]/)[0], r = (o.split("/").pop() ?? o).trim(), a = r.lastIndexOf(".");
655
- return a <= 0 ? null : r.slice(a).toLowerCase();
656
- }
657
- function Dn(e) {
658
- return dn.sanitize(e, {
659
- CUSTOM_ELEMENT_HANDLING: {
660
- allowCustomizedBuiltInElements: !0,
661
- attributeNameCheck: /^(?!on)[a-z][a-z0-9-]*$/i,
662
- tagNameCheck: /^cx-/
663
- }
664
- });
665
- }
666
- export {
667
- bn as F,
668
- $e as M,
669
- I as T,
670
- Ln as a,
671
- Mn as b,
672
- In as e,
673
- On as f,
674
- yn as p,
675
- Dn as s,
676
- Nn as t,
677
- Rn as u
678
- };