diff --git a/CHANGELOG.md b/CHANGELOG.md index c7bd85b8..fe817ac7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,9 @@ All notable changes to this project will be documented in this file. ## [Unreleased] +- [#153](https://github.com/os2display/display-templates/pull/153) + - Replace the temporary rejseplans "hack" with an actual solution. + ## [2.0.0] - 2024-04-09 - [#151](https://github.com/os2display/display-templates/pull/151) diff --git a/build/travel-config-develop.json b/build/travel-config-develop.json index f191bb6d..2624530c 100644 --- a/build/travel-config-develop.json +++ b/build/travel-config-develop.json @@ -4,8 +4,8 @@ "id": "01FZD7K807VAKZ99BGSSCHRJM6", "description": "Skabelon til rejseplanen.", "resources": { - "component": "https://raw.githubusercontent.com/os2display/display-templates/develop/build/travel.js?ts=1705317070424", - "admin": "https://raw.githubusercontent.com/os2display/display-templates/develop/build/travel-admin.json?ts=1705317070424", + "component": "https://raw.githubusercontent.com/os2display/display-templates/develop/build/travel.js?ts=1716881579494", + "admin": "https://raw.githubusercontent.com/os2display/display-templates/develop/build/travel-admin.json?ts=1716881579494", "schema": "", "assets": [], "options": {}, diff --git a/build/travel-config-main.json b/build/travel-config-main.json index b799a1f2..d200d754 100644 --- a/build/travel-config-main.json +++ b/build/travel-config-main.json @@ -4,8 +4,8 @@ "id": "01FZD7K807VAKZ99BGSSCHRJM6", "description": "Skabelon til rejseplanen.", "resources": { - "component": "https://raw.githubusercontent.com/os2display/display-templates/main/build/travel.js?ts=1705317070424", - "admin": "https://raw.githubusercontent.com/os2display/display-templates/main/build/travel-admin.json?ts=1705317070424", + "component": "https://raw.githubusercontent.com/os2display/display-templates/main/build/travel.js?ts=1716881579494", + "admin": "https://raw.githubusercontent.com/os2display/display-templates/main/build/travel-admin.json?ts=1716881579494", "schema": "", "assets": [], "options": {}, diff --git a/build/travel.js b/build/travel.js index eb072778..d9e9a5bc 100644 --- a/build/travel.js +++ b/build/travel.js @@ -1,2 +1,2 @@ /*! For license information please see travel.js.LICENSE.txt */ -(()=>{var e={6215:(e,t,r)=>{"use strict";r.d(t,{Z:()=>o});var n=r(3645),i=r.n(n)()((function(e){return e[1]}));i.push([e.id,'.slide{--color-white: #fff;--color-grey-100: hsl(0deg 0% 95%);--color-grey-200: hsl(0deg 0% 85%);--color-grey-300: hsl(0deg 0% 80%);--color-grey-400: hsl(0deg 0% 75%);--color-grey-500: hsl(0deg 0% 70%);--color-grey-600: hsl(0deg 0% 40%);--color-grey-700: hsl(0deg 0% 30%);--color-grey-800: hsl(0deg 0% 20%);--color-grey-900: hsl(0deg 0% 10%);--color-black: #000;--color-blue: hsl(219deg 89% 57%);--color-indigo: indigo;--color-purple: purple;--color-pink: pink;--color-red: red;--color-orange: orange;--color-yellow: yellow;--color-green: green;--color-teal: teal;--color-cyan: cyan;--color-gray: var(--color-grey-500);--color-gray-dark: var(--color-grey-900);--color-primary: var(--color-blue);--color-secondary: var(--color-orange);--color-success: var(--color-green);--color-info: var(--color-teal);--color-warning: var(--color-yellow);--color-danger: var(--color-red);--color-light: var(--color-white);--color-dark: var(--color-black);--bg-light: var(--color-light);--bg-dark: var(--color-dark);--bg-primary: var(--color-primary);--bg-secondary: var(--color-secondary);--bg-transparent: transparent;--text-light: var(--color-light);--text-dark: var(--color-dark);--font-family-base: system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;--font-weight-light: 300;--font-weight-normal: 400;--font-weight-bold: 700;--line-height-base: 1.5;--line-height-sm: 1.25;--line-height-lg: 2;--font-size-base: 1rem;--font-size-multiplier-050: 0.5;--font-size-multiplier-075: 0.75;--font-size-multiplier-090: 0.9;--font-size-multiplier-125: 1.25;--font-size-multiplier-150: 1.5;--font-size-multiplier-175: 1.75;--font-size-multiplier-200: 2;--font-size-multiplier-250: 2.5;--font-size-xs: calc(var(--font-size-base) * var(--font-size-multiplier-050));--font-size-sm: calc(var(--font-size-base) * var(--font-size-multiplier-075));--font-size-m: calc(var(--font-size-base) * 1);--font-size-lg: calc(var(--font-size-base) * var(--font-size-multiplier-125));--font-size-xl: calc(var(--font-size-base) * var(--font-size-multiplier-150));--h1-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-250));--h2-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-200));--h3-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-175));--h4-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-150));--h5-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-125));--h6-font-size: calc(var(--font-size-base));--spacer: 12px;--margin-size-base: calc(var(--spacer) * 3);--padding-size-base: calc(var(--spacer) * 3);--box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);--box-shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);--box-shadow-lg: 0 1rem 3rem rgba(0, 0, 0, 0.175);--box-shadow-inset: inset 0 1px 2px rgba(0, 0, 0, 0.075);--border-size: 1px;--border-style: solid;--border-color: var(--color-grey-900);--border: var(--border-size) var(--border-style) var(--border-color);--background-color: var(--bg-light, hsl(0deg, 0%, 100%));--background-color-secondary: var(--color-grey-100, hsl(0deg, 0%, 95%));--text-color: var(--text-dark, hsl(0deg, 0%, 0%))}*,*::before,*::after{box-sizing:border-box}html{font-size:1.125rem;height:100%;background-color:var(--background-color);color:var(--text-color)}body{margin:0;height:100%}@keyframes h1-underline{0%{opacity:0;width:100%}40%{opacity:1;width:100%;margin-top:.938em;height:.375em}70%{opacity:1;width:100%;margin-top:.625em;height:.2em}100%{opacity:1;width:5em;margin-top:.625em}}.color-scheme-dark .slide{--background-color: var(--bg-dark, hsl(0deg, 0%, 10%));--background-color-secondary: var(--bg-dark-secondary, hsl(0deg, 0%, 20%));--text-color: var(--text-light, hsl(0deg, 0%, 100%));--border-color: var(--color-light);--color-grey-100: hsl(0deg 0% 10%);--color-grey-200: hsl(0deg 0% 15%);--color-grey-300: hsl(0deg 0% 20%);--color-grey-400: hsl(0deg 0% 25%);--color-grey-500: hsl(0deg 0% 30%);--color-grey-600: hsl(0deg 0% 45%);--color-grey-700: hsl(0deg 0% 60%);--color-grey-800: hsl(0deg 0% 75%);--color-grey-900: hsl(0deg 0% 90%)}@media screen and (min-width: 1921px)and (orientation: landscape){.slide{--font-size-base: 2rem;--spacer: 24px}}@media screen and (min-width: 1081px)and (orientation: portrait){.slide{--font-size-base: 2rem;--spacer: 24px}}.slide .font-size-xs{--font-size-base: var(--font-size-xs);--h1-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-250));--h2-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-200));--h3-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-175));--h4-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-150));--h5-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-125))}.slide .font-size-s{--font-size-base: var(--font-size-sm);--h1-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-250));--h2-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-200));--h3-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-175));--h4-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-150));--h5-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-125))}.slide .font-size-m{--font-size-base: var(--font-size-m);--h1-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-250));--h2-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-200));--h3-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-175));--h4-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-150));--h5-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-125))}.slide .font-size-lg{--font-size-base: var(--font-size-lg);--h1-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-250));--h2-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-200));--h3-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-175));--h4-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-150));--h5-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-125))}.slide .font-size-xl{--font-size-base: var(--font-size-xl);--h1-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-250));--h2-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-200));--h3-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-175));--h4-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-150));--h5-font-size: calc(var(--font-size-base) * var(--font-size-multiplier-125))}.slide h1{font-size:var(--h1-font-size)}.slide h2{font-size:var(--h2-font-size)}.slide h3{font-size:var(--h3-font-size)}.slide h4{font-size:var(--h4-font-size)}.slide h5{font-size:var(--h5-font-size)}.slide h6{font-size:var(--h6-font-size)}',""]);const o=i},2026:(e,t,r)=>{"use strict";r.d(t,{Z:()=>u});var n=r(3645),i=r.n(n),o=r(1667),a=r.n(o),s=r(8522),l=i()((function(e){return e[1]})),c=a()(s.Z);l.push([e.id,'@font-face{font-family:"rubics";src:url('+c+') format("woff")}.grid{font-family:"rubics",Helvetica,sans-serif;color:#343433;font-size:1em;grid-template-rows:50% 50%;grid-template-columns:33% 67%;background-color:#f4f4ec;display:grid;height:100%;grid-template-areas:"a b" "c d"}.grid .info-box{grid-area:a;grid-template-rows:15% 1fr 20%;grid-template-columns:33% 33% 34%;margin:1em;display:grid;grid-template-areas:"a b c" "d e f" "g h i"}.grid .info-box .header{display:flex;align-items:center;font-size:1.4em;grid-area:a/a/c/c}.grid .info-box .header h1{margin:0}.grid .info-box .text{grid-area:d/d/f/f;font-size:1.5em}.grid .info-box .distance{padding:1em;display:flex;flex-direction:column;justify-content:space-around;background-color:#e1ded7;grid-area:g}.grid .info-box .distance .text{font-size:1.1em}.grid .info-box .time-fast{padding:1em;display:flex;flex-direction:column;justify-content:space-around;background-color:#e1ded7;grid-area:h;background-color:#f4f4ec}.grid .info-box .time-fast .text{font-size:1.1em}.grid .info-box .time-moderat{padding:1em;display:flex;flex-direction:column;justify-content:space-around;background-color:#e1ded7;grid-area:i}.grid .info-box .time-moderat .text{font-size:1.1em}.grid .info-box.grow{grid-area:a/c/c/c}.grid .map{grid-area:c;background-size:cover;background-position:center center}.grid .iframe{border-left:3px solid #e1ded7;grid-area:b/b/d/d}.grid .iframe.grow{grid-area:a/a/d/d;border-left:0}',""]);const u=l},3645:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r=e(t);return t[2]?"@media ".concat(t[2]," {").concat(r,"}"):r})).join("")},t.i=function(e,r,n){"string"==typeof e&&(e=[[null,e,""]]);var i={};if(n)for(var o=0;o{"use strict";e.exports=function(e,t){return t||(t={}),"string"!=typeof(e=e&&e.__esModule?e.default:e)?e:(/^['"].*['"]$/.test(e)&&(e=e.slice(1,-1)),t.hash&&(e+=t.hash),/["'() \t\n]/.test(e)||t.needQuotes?'"'.concat(e.replace(/"/g,'\\"').replace(/\n/g,"\\n"),'"'):e)}},9960:(e,t)=>{"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.Doctype=t.CDATA=t.Tag=t.Style=t.Script=t.Comment=t.Directive=t.Text=t.Root=t.isTag=t.ElementType=void 0,function(e){e.Root="root",e.Text="text",e.Directive="directive",e.Comment="comment",e.Script="script",e.Style="style",e.Tag="tag",e.CDATA="cdata",e.Doctype="doctype"}(r=t.ElementType||(t.ElementType={})),t.isTag=function(e){return e.type===r.Tag||e.type===r.Script||e.type===r.Style},t.Root=r.Root,t.Text=r.Text,t.Directive=r.Directive,t.Comment=r.Comment,t.Script=r.Script,t.Style=r.Style,t.Tag=r.Tag,t.CDATA=r.CDATA,t.Doctype=r.Doctype},7915:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.DomHandler=void 0;var o=r(9960),a=r(7790);i(r(7790),t);var s=/\s+/g,l={normalizeWhitespace:!1,withStartIndices:!1,withEndIndices:!1,xmlMode:!1},c=function(){function e(e,t,r){this.dom=[],this.root=new a.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,"function"==typeof t&&(r=t,t=l),"object"==typeof e&&(t=e,e=void 0),this.callback=null!=e?e:null,this.options=null!=t?t:l,this.elementCB=null!=r?r:null}return e.prototype.onparserinit=function(e){this.parser=e},e.prototype.onreset=function(){this.dom=[],this.root=new a.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},e.prototype.onend=function(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))},e.prototype.onerror=function(e){this.handleCallback(e)},e.prototype.onclosetag=function(){this.lastNode=null;var e=this.tagStack.pop();this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)},e.prototype.onopentag=function(e,t){var r=this.options.xmlMode?o.ElementType.Tag:void 0,n=new a.Element(e,t,void 0,r);this.addNode(n),this.tagStack.push(n)},e.prototype.ontext=function(e){var t=this.options.normalizeWhitespace,r=this.lastNode;if(r&&r.type===o.ElementType.Text)t?r.data=(r.data+e).replace(s," "):r.data+=e,this.options.withEndIndices&&(r.endIndex=this.parser.endIndex);else{t&&(e=e.replace(s," "));var n=new a.Text(e);this.addNode(n),this.lastNode=n}},e.prototype.oncomment=function(e){if(this.lastNode&&this.lastNode.type===o.ElementType.Comment)this.lastNode.data+=e;else{var t=new a.Comment(e);this.addNode(t),this.lastNode=t}},e.prototype.oncommentend=function(){this.lastNode=null},e.prototype.oncdatastart=function(){var e=new a.Text(""),t=new a.NodeWithChildren(o.ElementType.CDATA,[e]);this.addNode(t),e.parent=t,this.lastNode=e},e.prototype.oncdataend=function(){this.lastNode=null},e.prototype.onprocessinginstruction=function(e,t){var r=new a.ProcessingInstruction(e,t);this.addNode(r)},e.prototype.handleCallback=function(e){if("function"==typeof this.callback)this.callback(e,this.dom);else if(e)throw e},e.prototype.addNode=function(e){var t=this.tagStack[this.tagStack.length-1],r=t.children[t.children.length-1];this.options.withStartIndices&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),t.children.push(e),r&&(e.prev=r,r.next=e),e.parent=t,this.lastNode=null},e}();t.DomHandler=c,t.default=c},7790:function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=this&&this.__assign||function(){return o=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"childNodes",{get:function(){return this.children},set:function(e){this.children=e},enumerable:!1,configurable:!0}),t}(l);t.NodeWithChildren=p;var d=function(e){function t(t){return e.call(this,a.ElementType.Root,t)||this}return i(t,e),t}(p);t.Document=d;var m=function(e){function t(t,r,n,i){void 0===n&&(n=[]),void 0===i&&(i="script"===t?a.ElementType.Script:"style"===t?a.ElementType.Style:a.ElementType.Tag);var o=e.call(this,i,n)||this;return o.name=t,o.attribs=r,o}return i(t,e),Object.defineProperty(t.prototype,"tagName",{get:function(){return this.name},set:function(e){this.name=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"attributes",{get:function(){var e=this;return Object.keys(this.attribs).map((function(t){var r,n;return{name:t,value:e.attribs[t],namespace:null===(r=e["x-attribsNamespace"])||void 0===r?void 0:r[t],prefix:null===(n=e["x-attribsPrefix"])||void 0===n?void 0:n[t]}}))},enumerable:!1,configurable:!0}),t}(p);function g(e){return(0,a.isTag)(e)}function y(e){return e.type===a.ElementType.CDATA}function v(e){return e.type===a.ElementType.Text}function b(e){return e.type===a.ElementType.Comment}function E(e){return e.type===a.ElementType.Directive}function T(e){return e.type===a.ElementType.Root}function S(e,t){var r;if(void 0===t&&(t=!1),v(e))r=new u(e.data);else if(b(e))r=new h(e.data);else if(g(e)){var n=t?A(e.children):[],i=new m(e.name,o({},e.attribs),n);n.forEach((function(e){return e.parent=i})),null!=e.namespace&&(i.namespace=e.namespace),e["x-attribsNamespace"]&&(i["x-attribsNamespace"]=o({},e["x-attribsNamespace"])),e["x-attribsPrefix"]&&(i["x-attribsPrefix"]=o({},e["x-attribsPrefix"])),r=i}else if(y(e)){n=t?A(e.children):[];var s=new p(a.ElementType.CDATA,n);n.forEach((function(e){return e.parent=s})),r=s}else if(T(e)){n=t?A(e.children):[];var l=new d(n);n.forEach((function(e){return e.parent=l})),e["x-mode"]&&(l["x-mode"]=e["x-mode"]),r=l}else{if(!E(e))throw new Error("Not implemented yet: ".concat(e.type));var c=new f(e.name,e.data);null!=e["x-name"]&&(c["x-name"]=e["x-name"],c["x-publicId"]=e["x-publicId"],c["x-systemId"]=e["x-systemId"]),r=c}return r.startIndex=e.startIndex,r.endIndex=e.endIndex,null!=e.sourceCodeLocation&&(r.sourceCodeLocation=e.sourceCodeLocation),r}function A(e){for(var t=e.map((function(e){return S(e,!0)})),r=1;re.length)&&(t=e.length);for(var r=0,n=new Array(t);r1?r-1:0),i=1;i/gm),$=h(/\${[\w\W]*}/gm),W=h(/^data-[\-\w.\u00B7-\uFFFF]/),X=h(/^aria-[\-\w]+$/),Y=h(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Z=h(/^(?:\w+script|data):/i),q=h(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),K=h(/^html$/i),J=function(){return"undefined"==typeof window?null:window};return function t(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:J(),i=function(e){return t(e)};if(i.version="2.4.7",i.removed=[],!r||!r.document||9!==r.document.nodeType)return i.isSupported=!1,i;var o=r.document,a=r.document,s=r.DocumentFragment,l=r.HTMLTemplateElement,c=r.Node,h=r.Element,f=r.NodeFilter,p=r.NamedNodeMap,d=void 0===p?r.NamedNodeMap||r.MozNamedAttrMap:p,m=r.HTMLFormElement,g=r.DOMParser,N=r.trustedTypes,Q=h.prototype,ee=I(Q,"cloneNode"),te=I(Q,"nextSibling"),re=I(Q,"childNodes"),ne=I(Q,"parentNode");if("function"==typeof l){var ie=a.createElement("template");ie.content&&ie.content.ownerDocument&&(a=ie.content.ownerDocument)}var oe=function(t,r){if("object"!==e(t)||"function"!=typeof t.createPolicy)return null;var n=null,i="data-tt-policy-suffix";r.currentScript&&r.currentScript.hasAttribute(i)&&(n=r.currentScript.getAttribute(i));var o="dompurify"+(n?"#"+n:"");try{return t.createPolicy(o,{createHTML:function(e){return e},createScriptURL:function(e){return e}})}catch(e){return console.warn("TrustedTypes policy "+o+" could not be created."),null}}(N,o),ae=oe?oe.createHTML(""):"",se=a,le=se.implementation,ce=se.createNodeIterator,ue=se.createDocumentFragment,he=se.getElementsByTagName,fe=o.importNode,pe={};try{pe=O(a).documentMode?a.documentMode:{}}catch(e){}var de={};i.isSupported="function"==typeof ne&&le&&void 0!==le.createHTMLDocument&&9!==pe;var me,ge,ye=G,ve=V,be=$,Ee=W,Te=X,Se=Z,Ae=q,we=Y,Ce=null,xe=_({},[].concat(n(R),n(P),n(L),n(H),n(B))),ke=null,Ne=_({},[].concat(n(z),n(F),n(U),n(j))),_e=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Oe=null,Ie=null,Re=!0,Pe=!0,Le=!1,Me=!0,He=!1,De=!1,Be=!1,ze=!1,Fe=!1,Ue=!1,je=!1,Ge=!0,Ve=!1,$e=!0,We=!1,Xe={},Ye=null,Ze=_({},["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"]),qe=null,Ke=_({},["audio","video","img","source","image","track"]),Je=null,Qe=_({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),et="http://www.w3.org/1998/Math/MathML",tt="http://www.w3.org/2000/svg",rt="http://www.w3.org/1999/xhtml",nt=rt,it=!1,ot=null,at=_({},[et,tt,rt],T),st=["application/xhtml+xml","text/html"],lt=null,ct=a.createElement("form"),ut=function(e){return e instanceof RegExp||e instanceof Function},ht=function(t){lt&<===t||(t&&"object"===e(t)||(t={}),t=O(t),me=me=-1===st.indexOf(t.PARSER_MEDIA_TYPE)?"text/html":t.PARSER_MEDIA_TYPE,ge="application/xhtml+xml"===me?T:E,Ce="ALLOWED_TAGS"in t?_({},t.ALLOWED_TAGS,ge):xe,ke="ALLOWED_ATTR"in t?_({},t.ALLOWED_ATTR,ge):Ne,ot="ALLOWED_NAMESPACES"in t?_({},t.ALLOWED_NAMESPACES,T):at,Je="ADD_URI_SAFE_ATTR"in t?_(O(Qe),t.ADD_URI_SAFE_ATTR,ge):Qe,qe="ADD_DATA_URI_TAGS"in t?_(O(Ke),t.ADD_DATA_URI_TAGS,ge):Ke,Ye="FORBID_CONTENTS"in t?_({},t.FORBID_CONTENTS,ge):Ze,Oe="FORBID_TAGS"in t?_({},t.FORBID_TAGS,ge):{},Ie="FORBID_ATTR"in t?_({},t.FORBID_ATTR,ge):{},Xe="USE_PROFILES"in t&&t.USE_PROFILES,Re=!1!==t.ALLOW_ARIA_ATTR,Pe=!1!==t.ALLOW_DATA_ATTR,Le=t.ALLOW_UNKNOWN_PROTOCOLS||!1,Me=!1!==t.ALLOW_SELF_CLOSE_IN_ATTR,He=t.SAFE_FOR_TEMPLATES||!1,De=t.WHOLE_DOCUMENT||!1,Fe=t.RETURN_DOM||!1,Ue=t.RETURN_DOM_FRAGMENT||!1,je=t.RETURN_TRUSTED_TYPE||!1,ze=t.FORCE_BODY||!1,Ge=!1!==t.SANITIZE_DOM,Ve=t.SANITIZE_NAMED_PROPS||!1,$e=!1!==t.KEEP_CONTENT,We=t.IN_PLACE||!1,we=t.ALLOWED_URI_REGEXP||we,nt=t.NAMESPACE||rt,_e=t.CUSTOM_ELEMENT_HANDLING||{},t.CUSTOM_ELEMENT_HANDLING&&ut(t.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(_e.tagNameCheck=t.CUSTOM_ELEMENT_HANDLING.tagNameCheck),t.CUSTOM_ELEMENT_HANDLING&&ut(t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(_e.attributeNameCheck=t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),t.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(_e.allowCustomizedBuiltInElements=t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),He&&(Pe=!1),Ue&&(Fe=!0),Xe&&(Ce=_({},n(B)),ke=[],!0===Xe.html&&(_(Ce,R),_(ke,z)),!0===Xe.svg&&(_(Ce,P),_(ke,F),_(ke,j)),!0===Xe.svgFilters&&(_(Ce,L),_(ke,F),_(ke,j)),!0===Xe.mathMl&&(_(Ce,H),_(ke,U),_(ke,j))),t.ADD_TAGS&&(Ce===xe&&(Ce=O(Ce)),_(Ce,t.ADD_TAGS,ge)),t.ADD_ATTR&&(ke===Ne&&(ke=O(ke)),_(ke,t.ADD_ATTR,ge)),t.ADD_URI_SAFE_ATTR&&_(Je,t.ADD_URI_SAFE_ATTR,ge),t.FORBID_CONTENTS&&(Ye===Ze&&(Ye=O(Ye)),_(Ye,t.FORBID_CONTENTS,ge)),$e&&(Ce["#text"]=!0),De&&_(Ce,["html","head","body"]),Ce.table&&(_(Ce,["tbody"]),delete Oe.tbody),u&&u(t),lt=t)},ft=_({},["mi","mo","mn","ms","mtext"]),pt=_({},["foreignobject","desc","title","annotation-xml"]),dt=_({},["title","style","font","a","script"]),mt=_({},P);_(mt,L),_(mt,M);var gt=_({},H);_(gt,D);var yt=function(e){b(i.removed,{element:e});try{e.parentNode.removeChild(e)}catch(t){try{e.outerHTML=ae}catch(t){e.remove()}}},vt=function(e,t){try{b(i.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){b(i.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e&&!ke[e])if(Fe||Ue)try{yt(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},bt=function(e){var t,r;if(ze)e=""+e;else{var n=S(e,/^[\r\n\t ]+/);r=n&&n[0]}"application/xhtml+xml"===me&&nt===rt&&(e=''+e+"");var i=oe?oe.createHTML(e):e;if(nt===rt)try{t=(new g).parseFromString(i,me)}catch(e){}if(!t||!t.documentElement){t=le.createDocument(nt,"template",null);try{t.documentElement.innerHTML=it?ae:i}catch(e){}}var o=t.body||t.documentElement;return e&&r&&o.insertBefore(a.createTextNode(r),o.childNodes[0]||null),nt===rt?he.call(t,De?"html":"body")[0]:De?t.documentElement:o},Et=function(e){return ce.call(e.ownerDocument||e,e,f.SHOW_ELEMENT|f.SHOW_COMMENT|f.SHOW_TEXT,null,!1)},Tt=function(t){return"object"===e(c)?t instanceof c:t&&"object"===e(t)&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName},St=function(e,t,r){de[e]&&y(de[e],(function(e){e.call(i,t,r,lt)}))},At=function(e){var t,r;if(St("beforeSanitizeElements",e,null),(r=e)instanceof m&&("string"!=typeof r.nodeName||"string"!=typeof r.textContent||"function"!=typeof r.removeChild||!(r.attributes instanceof d)||"function"!=typeof r.removeAttribute||"function"!=typeof r.setAttribute||"string"!=typeof r.namespaceURI||"function"!=typeof r.insertBefore||"function"!=typeof r.hasChildNodes))return yt(e),!0;if(x(/[\u0080-\uFFFF]/,e.nodeName))return yt(e),!0;var n=ge(e.nodeName);if(St("uponSanitizeElement",e,{tagName:n,allowedTags:Ce}),e.hasChildNodes()&&!Tt(e.firstElementChild)&&(!Tt(e.content)||!Tt(e.content.firstElementChild))&&x(/<[/\w]/g,e.innerHTML)&&x(/<[/\w]/g,e.textContent))return yt(e),!0;if("select"===n&&x(/