@undrr/undrr-mangrove 1.8.1 → 1.8.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/components/BookCard.js +2 -2
- package/components/BookCard.js.LICENSE.txt +2 -2
- package/components/Breadcrumbs.js +2 -3
- package/components/Checkbox.js +2 -3
- package/components/Chips.js +2 -3
- package/components/CtaButton.js +2 -3
- package/components/EmbedContainer.js +2 -3
- package/components/Footer.js +2 -2
- package/components/Footer.js.LICENSE.txt +1 -1
- package/components/FormErrorSummary.js +2 -3
- package/components/FormGroup.js +2 -3
- package/components/FullWidth.js +2 -3
- package/components/Gallery.js +2 -2
- package/components/Gallery.js.LICENSE.txt +1 -1
- package/components/Hero.js +2 -2
- package/components/Hero.js.LICENSE.txt +1 -1
- package/components/HighlightBox.js +2 -3
- package/components/HorizontalBookCard.js +2 -2
- package/components/HorizontalBookCard.js.LICENSE.txt +2 -2
- package/components/HorizontalCard.js +2 -2
- package/components/HorizontalCard.js.LICENSE.txt +2 -2
- package/components/IconCard.js +2 -2
- package/components/IconCard.js.LICENSE.txt +2 -2
- package/components/Loader.js +2 -3
- package/components/MegaMenu.js +2 -2
- package/components/MegaMenu.js.LICENSE.txt +1 -1
- package/components/PageHeader.js +2 -3
- package/components/Pager.js +2 -2
- package/components/Pager.js.LICENSE.txt +1 -1
- package/components/QuoteHighlight.js +2 -3
- package/components/Radio.js +2 -3
- package/components/ScrollContainer.js +2 -3
- package/components/Select.js +2 -3
- package/components/ShareButtons.js +2 -2
- package/components/ShareButtons.js.LICENSE.txt +1 -1
- package/components/ShowMore.js +2 -3
- package/components/StatsCard.js +2 -2
- package/components/StatsCard.js.LICENSE.txt +1 -11
- package/components/SyndicationSearchWidget.js +2 -2
- package/components/SyndicationSearchWidget.js.LICENSE.txt +1 -1
- package/components/Tab.js +2 -3
- package/components/TextCta.js +2 -2
- package/components/TextCta.js.LICENSE.txt +1 -11
- package/components/TextInput.js +2 -3
- package/components/Textarea.js +2 -3
- package/components/VerticalCard.js +2 -2
- package/components/VerticalCard.js.LICENSE.txt +2 -2
- package/components/hydrate.js +1 -1
- package/css/style-delta.css +4 -4
- package/css/style-delta.css.map +1 -1
- package/css/style-gutenberg.css +2 -2
- package/css/style-gutenberg.css.map +1 -1
- package/css/style-irp-legacy.css +4 -4
- package/css/style-irp-legacy.css.map +1 -1
- package/css/style-irp.css +4 -4
- package/css/style-irp.css.map +1 -1
- package/css/style-legacy.css +5 -5
- package/css/style-legacy.css.map +1 -1
- package/css/style-mcr-legacy.css +4 -4
- package/css/style-mcr-legacy.css.map +1 -1
- package/css/style-mcr.css +4 -4
- package/css/style-mcr.css.map +1 -1
- package/css/style-preventionweb-legacy.css +4 -4
- package/css/style-preventionweb-legacy.css.map +1 -1
- package/css/style-preventionweb.css +4 -4
- package/css/style-preventionweb.css.map +1 -1
- package/css/style.css +5 -5
- package/css/style.css.map +1 -1
- package/error-pages/401.html +1 -1
- package/error-pages/403.html +1 -1
- package/error-pages/404.html +1 -1
- package/error-pages/429.html +1 -1
- package/error-pages/500.html +1 -1
- package/error-pages/502.html +1 -1
- package/error-pages/503.html +1 -1
- package/error-pages/504.html +1 -1
- package/error-pages/5xx.html +1 -1
- package/error-pages/challenge.html +1 -1
- package/error-pages/managed-challenge.html +1 -1
- package/package.json +1 -1
- package/scss/Atom/Icons/_icon-definitions.scss +2 -2
- package/scss/Atom/Layout/Grid/grid.scss +31 -0
- package/scss/Components/Cards/Card/card.scss +4 -3
- package/scss/Components/SyndicationSearchWidget/_deprecated-teaser-hide.scss +19 -0
- package/scss/Components/SyndicationSearchWidget/syndication-search-widget.scss +5 -15
package/components/TextCta.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* This is a UNDRR Mangrove component: https://github.com/unisdr/undrr-mangrove?tab=readme-ov-file
|
|
3
|
-
* Compiled on: 2026-
|
|
3
|
+
* Compiled on: 2026-08-27T20:32:00.846Z
|
|
4
4
|
*/
|
|
5
5
|
/*! For license information please see TextCta.js.LICENSE.txt */
|
|
6
|
-
import{useId as e}from"react";var t={2694(e,t,n){var o=n(6925);function r(){}function a(){}a.resetWarningCache=r,e.exports=function(){function e(e,t,n,r,a,i){if(i!==o){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:a,resetWarningCache:r};return n.PropTypes=n,n}},5556(e,t,n){e.exports=n(2694)()},6925(e){e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},9698(e,t){var n=Symbol.for("react.transitional.element");function o(e,t,o){var r=null;if(void 0!==o&&(r=""+o),void 0!==t.key&&(r=""+t.key),"key"in t)for(var a in o={},t)"key"!==a&&(o[a]=t[a]);else o=t;return t=o.ref,{$$typeof:n,type:e,key:r,ref:void 0!==t?t:null,props:o}}Symbol.for("react.fragment"),t.jsx=o,t.jsxs=o},4848(e,t,n){e.exports=n(9698)}},n={};function o(e){var r=n[e];if(void 0!==r)return r.exports;var a=n[e]={exports:{}};return t[e](a,a.exports,o),a.exports}o.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},o.d=(e,t)=>{for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var r=o(5556),a=o.n(r);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=Array(t);n<t;n++)o[n]=e[n];return o}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o,r,a,i,l=[],c=!0,s=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(c=(o=a.call(n)).done)&&(l.push(o.value),l.length!==t);c=!0);}catch(e){s=!0,r=e}finally{try{if(!c&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(s)throw r}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const c=Object.entries,s=Object.setPrototypeOf,u=Object.isFrozen,f=Object.getPrototypeOf,m=Object.getOwnPropertyDescriptor;let p=Object.freeze,d=Object.seal,h=Object.create,g="undefined"!=typeof Reflect&&Reflect,y=g.apply,b=g.construct;p||(p=function(e){return e}),d||(d=function(e){return e}),y||(y=function(e,t){for(var n=arguments.length,o=new Array(n>2?n-2:0),r=2;r<n;r++)o[r-2]=arguments[r];return e.apply(t,o)}),b||(b=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return new e(...n)});const T=j(Array.prototype.forEach),S=j(Array.prototype.lastIndexOf),E=j(Array.prototype.pop),N=j(Array.prototype.push),_=j(Array.prototype.splice),A=Array.isArray,v=j(String.prototype.toLowerCase),O=j(String.prototype.toString),w=j(String.prototype.match),x=j(String.prototype.replace),k=j(String.prototype.indexOf),C=j(String.prototype.trim),R=j(Number.prototype.toString),D=j(Boolean.prototype.toString),I="undefined"==typeof BigInt?null:j(BigInt.prototype.toString),L="undefined"==typeof Symbol?null:j(Symbol.prototype.toString),M=j(Object.prototype.hasOwnProperty),P=j(Object.prototype.toString),z=j(RegExp.prototype.test),U=(F=TypeError,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return b(F,t)});var F;function j(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,o=new Array(n>1?n-1:0),r=1;r<n;r++)o[r-1]=arguments[r];return y(e,t,o)}}function H(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:v;if(s&&s(e,null),!A(t))return e;let o=t.length;for(;o--;){let r=t[o];if("string"==typeof r){const e=n(r);e!==r&&(u(t)||(t[o]=e),r=e)}e[r]=!0}return e}function B(e){for(let t=0;t<e.length;t++)M(e,t)||(e[t]=null);return e}function W(e){const t=h(null);for(const o of c(e)){var n=l(o,2);const r=n[0],a=n[1];M(e,r)&&(A(a)?t[r]=B(a):a&&"object"==typeof a&&a.constructor===Object?t[r]=W(a):t[r]=a)}return t}function G(e,t){for(;null!==e;){const n=m(e,t);if(n){if(n.get)return j(n.get);if("function"==typeof n.value)return j(n.value)}e=f(e)}return function(){return null}}const Y=p(["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"]),q=p(["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"]),$=p(["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"]),X=p(["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"]),K=p(["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"]),V=p(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Z=p(["#text"]),J=p(["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"]),Q=p(["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"]),ee=p(["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"]),te=p(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),ne=d(/{{[\w\W]*|^[\w\W]*}}/g),oe=d(/<%[\w\W]*|^[\w\W]*%>/g),re=d(/\${[\w\W]*/g),ae=d(/^data-[\-\w.\u00B7-\uFFFF]+$/),ie=d(/^aria-[\-\w]+$/),le=d(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ce=d(/^(?:\w+script|data):/i),se=d(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ue=d(/^html$/i),fe=d(/^[a-z][.\w]*(-[.\w]+)+$/i),me=d(/<[/\w!]/g),pe=d(/<[/\w]/g),de=d(/<\/no(script|embed|frames)/i),he=d(/\/>/i),ge=function(){return"undefined"==typeof window?null:window},ye=function(e,t,n,o){return M(e,t)&&A(e[t])?H(o.base?W(o.base):{},e[t],o.transform):n};var be=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ge();const n=t=>e(t);if(n.version="3.4.11",n.removed=[],!t||!t.document||9!==t.document.nodeType||!t.Element)return n.isSupported=!1,n;let o=t.document;const r=o,a=r.currentScript;t.DocumentFragment;const i=t.HTMLTemplateElement,l=t.Node,s=t.Element,u=t.NodeFilter;void 0===t.NamedNodeMap&&(t.NamedNodeMap||t.MozNamedAttrMap),t.HTMLFormElement;const f=t.DOMParser,m=t.trustedTypes,g=s.prototype,y=G(g,"cloneNode"),b=G(g,"remove"),F=G(g,"nextSibling"),j=G(g,"childNodes"),B=G(g,"parentNode"),be=G(g,"shadowRoot"),Te=G(g,"attributes"),Se=l&&l.prototype?G(l.prototype,"nodeType"):null,Ee=l&&l.prototype?G(l.prototype,"nodeName"):null;if("function"==typeof i){const e=o.createElement("template");e.content&&e.content.ownerDocument&&(o=e.content.ownerDocument)}let Ne,_e,Ae="",ve=!1,Oe=0;const we=function(){if(Oe>0)throw U('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},xe=function(e){we(),Oe++;try{return Ne.createHTML(e)}finally{Oe--}},ke=o,Ce=ke.implementation,Re=ke.createNodeIterator,De=ke.createDocumentFragment,Ie=ke.getElementsByTagName,Le=r.importNode;let Me={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};n.isSupported="function"==typeof c&&"function"==typeof B&&Ce&&void 0!==Ce.createHTMLDocument;const Pe=ne,ze=oe,Ue=re,Fe=ae,je=ie,He=ce,Be=se,We=fe;let Ge=le,Ye=null;const qe=H({},[...Y,...q,...$,...K,...Z]);let $e=null;const Xe=H({},[...J,...Q,...ee,...te]);let Ke=Object.seal(h(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}})),Ve=null,Ze=null;const Je=Object.seal(h(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Qe=!0,et=!0,tt=!1,nt=!0,ot=!1,rt=!0,at=!1,it=!1,lt=null,ct=null,st=!1,ut=!1,ft=!1,mt=!1,pt=!0,dt=!1;const ht="user-content-";let gt=!0,yt=!1,bt={},Tt=null;const St=H({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]);let Et=null;const Nt=H({},["audio","video","img","source","image","track"]);let _t=null;const At=H({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),vt="http://www.w3.org/1998/Math/MathML",Ot="http://www.w3.org/2000/svg",wt="http://www.w3.org/1999/xhtml";let xt=wt,kt=!1,Ct=null;const Rt=H({},[vt,Ot,wt],O),Dt=p(["mi","mo","mn","ms","mtext"]);let It=H({},Dt);const Lt=p(["annotation-xml"]);let Mt=H({},Lt);const Pt=H({},["title","style","font","a","script"]);let zt=null;const Ut=["application/xhtml+xml","text/html"];let Ft=null,jt=null;const Ht=o.createElement("form"),Bt=function(e){return e instanceof RegExp||e instanceof Function},Wt=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(jt&&jt===e)return;e&&"object"==typeof e||(e={}),e=W(e),zt=-1===Ut.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE,Ft="application/xhtml+xml"===zt?O:v,Ye=ye(e,"ALLOWED_TAGS",qe,{transform:Ft}),$e=ye(e,"ALLOWED_ATTR",Xe,{transform:Ft}),Ct=ye(e,"ALLOWED_NAMESPACES",Rt,{transform:O}),_t=ye(e,"ADD_URI_SAFE_ATTR",At,{transform:Ft,base:At}),Et=ye(e,"ADD_DATA_URI_TAGS",Nt,{transform:Ft,base:Nt}),Tt=ye(e,"FORBID_CONTENTS",St,{transform:Ft}),Ve=ye(e,"FORBID_TAGS",W({}),{transform:Ft}),Ze=ye(e,"FORBID_ATTR",W({}),{transform:Ft}),bt=!!M(e,"USE_PROFILES")&&(e.USE_PROFILES&&"object"==typeof e.USE_PROFILES?W(e.USE_PROFILES):e.USE_PROFILES),Qe=!1!==e.ALLOW_ARIA_ATTR,et=!1!==e.ALLOW_DATA_ATTR,tt=e.ALLOW_UNKNOWN_PROTOCOLS||!1,nt=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,ot=e.SAFE_FOR_TEMPLATES||!1,rt=!1!==e.SAFE_FOR_XML,at=e.WHOLE_DOCUMENT||!1,ut=e.RETURN_DOM||!1,ft=e.RETURN_DOM_FRAGMENT||!1,mt=e.RETURN_TRUSTED_TYPE||!1,st=e.FORCE_BODY||!1,pt=!1!==e.SANITIZE_DOM,dt=e.SANITIZE_NAMED_PROPS||!1,gt=!1!==e.KEEP_CONTENT,yt=e.IN_PLACE||!1,Ge=function(e){try{return z(e,""),!0}catch(e){return!1}}(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:le,xt="string"==typeof e.NAMESPACE?e.NAMESPACE:wt,It=M(e,"MATHML_TEXT_INTEGRATION_POINTS")&&e.MATHML_TEXT_INTEGRATION_POINTS&&"object"==typeof e.MATHML_TEXT_INTEGRATION_POINTS?W(e.MATHML_TEXT_INTEGRATION_POINTS):H({},Dt),Mt=M(e,"HTML_INTEGRATION_POINTS")&&e.HTML_INTEGRATION_POINTS&&"object"==typeof e.HTML_INTEGRATION_POINTS?W(e.HTML_INTEGRATION_POINTS):H({},Lt);const t=M(e,"CUSTOM_ELEMENT_HANDLING")&&e.CUSTOM_ELEMENT_HANDLING&&"object"==typeof e.CUSTOM_ELEMENT_HANDLING?W(e.CUSTOM_ELEMENT_HANDLING):h(null);if(Ke=h(null),M(t,"tagNameCheck")&&Bt(t.tagNameCheck)&&(Ke.tagNameCheck=t.tagNameCheck),M(t,"attributeNameCheck")&&Bt(t.attributeNameCheck)&&(Ke.attributeNameCheck=t.attributeNameCheck),M(t,"allowCustomizedBuiltInElements")&&"boolean"==typeof t.allowCustomizedBuiltInElements&&(Ke.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),d(Ke),ot&&(et=!1),ft&&(ut=!0),bt&&(Ye=H({},Z),$e=h(null),!0===bt.html&&(H(Ye,Y),H($e,J)),!0===bt.svg&&(H(Ye,q),H($e,Q),H($e,te)),!0===bt.svgFilters&&(H(Ye,$),H($e,Q),H($e,te)),!0===bt.mathMl&&(H(Ye,K),H($e,ee),H($e,te))),Je.tagCheck=null,Je.attributeCheck=null,M(e,"ADD_TAGS")&&("function"==typeof e.ADD_TAGS?Je.tagCheck=e.ADD_TAGS:A(e.ADD_TAGS)&&(Ye===qe&&(Ye=W(Ye)),H(Ye,e.ADD_TAGS,Ft))),M(e,"ADD_ATTR")&&("function"==typeof e.ADD_ATTR?Je.attributeCheck=e.ADD_ATTR:A(e.ADD_ATTR)&&($e===Xe&&($e=W($e)),H($e,e.ADD_ATTR,Ft))),M(e,"ADD_URI_SAFE_ATTR")&&A(e.ADD_URI_SAFE_ATTR)&&H(_t,e.ADD_URI_SAFE_ATTR,Ft),M(e,"FORBID_CONTENTS")&&A(e.FORBID_CONTENTS)&&(Tt===St&&(Tt=W(Tt)),H(Tt,e.FORBID_CONTENTS,Ft)),M(e,"ADD_FORBID_CONTENTS")&&A(e.ADD_FORBID_CONTENTS)&&(Tt===St&&(Tt=W(Tt)),H(Tt,e.ADD_FORBID_CONTENTS,Ft)),gt&&(Ye["#text"]=!0),at&&H(Ye,["html","head","body"]),Ye.table&&(H(Ye,["tbody"]),delete Ve.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');const t=Ne;Ne=e.TRUSTED_TYPES_POLICY;try{Ae=xe("")}catch(e){throw Ne=t,e}}else null===e.TRUSTED_TYPES_POLICY?(Ne=void 0,Ae=""):(void 0===Ne&&(ve||(_e=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let n=null;const o="data-tt-policy-suffix";t&&t.hasAttribute(o)&&(n=t.getAttribute(o));const r="dompurify"+(n?"#"+n:"");try{return e.createPolicy(r,{createHTML:e=>e,createScriptURL:e=>e})}catch(e){return console.warn("TrustedTypes policy "+r+" could not be created."),null}}(m,a),ve=!0),Ne=_e),Ne&&"string"==typeof Ae&&(Ae=xe("")));p&&p(e),jt=e},Gt=H({},[...q,...$,...X]),Yt=H({},[...K,...V]),qt=function(e){N(n.removed,{element:e});try{B(e).removeChild(e)}catch(t){if(b(e),!B(e))throw U("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},$t=function(e){const t=j(e);if(t){const e=[];T(t,t=>{N(e,t)}),T(e,e=>{try{b(e)}catch(e){}})}const n=Te(e);if(n)for(let t=n.length-1;t>=0;--t){const o=n[t],r=o&&o.name;if("string"==typeof r)try{e.removeAttribute(r)}catch(e){}}},Xt=function(e,t){try{N(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){N(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e)if(ut||ft)try{qt(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},Kt=function(e){const t=Te(e);if(t)for(let n=t.length-1;n>=0;--n){const o=t[n],r=o&&o.name;if("string"==typeof r&&!$e[Ft(r)])try{e.removeAttribute(r)}catch(e){}}},Vt=function(e){let t=null,n=null;if(st)e="<remove></remove>"+e;else{const t=w(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===zt&&xt===wt&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const r=Ne?xe(e):e;if(xt===wt)try{t=(new f).parseFromString(r,zt)}catch(e){}if(!t||!t.documentElement){t=Ce.createDocument(xt,"template",null);try{t.documentElement.innerHTML=kt?Ae:r}catch(e){}}const a=t.body||t.documentElement;return e&&n&&a.insertBefore(o.createTextNode(n),a.childNodes[0]||null),xt===wt?Ie.call(t,at?"html":"body")[0]:at?t.documentElement:a},Zt=function(e){return Re.call(e.ownerDocument||e,e,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},Jt=function(e){return e=x(e,Pe," "),e=x(e,ze," "),x(e,Ue," ")},Qt=function(e){var t;e.normalize();const n=Re.call(e.ownerDocument||e,e,u.SHOW_TEXT|u.SHOW_COMMENT|u.SHOW_CDATA_SECTION|u.SHOW_PROCESSING_INSTRUCTION,null);let o=n.nextNode();for(;o;)o.data=Jt(o.data),o=n.nextNode();const r=null===(t=e.querySelectorAll)||void 0===t?void 0:t.call(e,"template");r&&T(r,e=>{tn(e.content)&&Qt(e.content)})},en=function(e){const t=Ee?Ee(e):null;return"string"==typeof t&&"form"===Ft(t)&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||e.attributes!==Te(e)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes||e.nodeType!==Se(e)||e.childNodes!==j(e))},tn=function(e){if(!Se||"object"!=typeof e||null===e)return!1;try{return 11===Se(e)}catch(e){return!1}},nn=function(e){if(!Se||"object"!=typeof e||null===e)return!1;try{return"number"==typeof Se(e)}catch(e){return!1}};function on(e,t,o){0!==e.length&&T(e,e=>{e.call(n,t,o,jt)})}const rn=function(e){if(on(Me.beforeSanitizeElements,e,null),en(e))return qt(e),!0;const t=Ft(Ee?Ee(e):e.nodeName);if(on(Me.uponSanitizeElement,e,{tagName:t,allowedTags:Ye}),function(e,t){return!!(rt&&e.hasChildNodes()&&!nn(e.firstElementChild)&&z(me,e.textContent)&&z(me,e.innerHTML))||!(!rt||e.namespaceURI!==wt||"style"!==t||!nn(e.firstElementChild))||7===e.nodeType||!(!rt||8!==e.nodeType||!z(pe,e.data))}(e,t))return qt(e),!0;if(Ve[t]||!(Je.tagCheck instanceof Function&&Je.tagCheck(t))&&!Ye[t])return function(e,t){if(!Ve[t]&&cn(t)){if(Ke.tagNameCheck instanceof RegExp&&z(Ke.tagNameCheck,t))return!1;if(Ke.tagNameCheck instanceof Function&&Ke.tagNameCheck(t))return!1}if(gt&&!Tt[t]){const t=B(e),n=j(e);if(n&&t)for(let o=n.length-1;o>=0;--o){const r=yt?n[o]:y(n[o],!0);t.insertBefore(r,F(e))}}return qt(e),!0}(e,t);if(1===(Se?Se(e):e.nodeType)&&!function(e){let t=B(e);t&&t.tagName||(t={namespaceURI:xt,tagName:"template"});const n=v(e.tagName),o=v(t.tagName);return!!Ct[e.namespaceURI]&&(e.namespaceURI===Ot?function(e,t,n){return t.namespaceURI===wt?"svg"===e:t.namespaceURI===vt?"svg"===e&&("annotation-xml"===n||It[n]):Boolean(Gt[e])}(n,t,o):e.namespaceURI===vt?function(e,t,n){return t.namespaceURI===wt?"math"===e:t.namespaceURI===Ot?"math"===e&&Mt[n]:Boolean(Yt[e])}(n,t,o):e.namespaceURI===wt?function(e,t,n){return!(t.namespaceURI===Ot&&!Mt[n])&&!(t.namespaceURI===vt&&!It[n])&&!Yt[e]&&(Pt[e]||!Gt[e])}(n,t,o):!("application/xhtml+xml"!==zt||!Ct[e.namespaceURI]))}(e))return qt(e),!0;if(("noscript"===t||"noembed"===t||"noframes"===t)&&z(de,e.innerHTML))return qt(e),!0;if(ot&&3===e.nodeType){const t=Jt(e.textContent);e.textContent!==t&&(N(n.removed,{element:e.cloneNode()}),e.textContent=t)}return on(Me.afterSanitizeElements,e,null),!1},an=function(e,t,n){if(Ze[t])return!1;if(pt&&("id"===t||"name"===t)&&(n in o||n in Ht))return!1;const r=$e[t]||Je.attributeCheck instanceof Function&&Je.attributeCheck(t,e);if(et&&z(Fe,t));else if(Qe&&z(je,t));else if(r){if(_t[t]);else if(z(Ge,x(n,Be,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==k(n,"data:")||!Et[e])if(tt&&!z(He,x(n,Be,"")));else if(n)return!1}else if(!(cn(e)&&(Ke.tagNameCheck instanceof RegExp&&z(Ke.tagNameCheck,e)||Ke.tagNameCheck instanceof Function&&Ke.tagNameCheck(e))&&(Ke.attributeNameCheck instanceof RegExp&&z(Ke.attributeNameCheck,t)||Ke.attributeNameCheck instanceof Function&&Ke.attributeNameCheck(t,e))||"is"===t&&Ke.allowCustomizedBuiltInElements&&(Ke.tagNameCheck instanceof RegExp&&z(Ke.tagNameCheck,n)||Ke.tagNameCheck instanceof Function&&Ke.tagNameCheck(n))))return!1;return!0},ln=H({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),cn=function(e){return!ln[v(e)]&&z(We,e)},sn=function(e,t,n,o){if(Ne&&"object"==typeof m&&"function"==typeof m.getAttributeType&&!n)switch(m.getAttributeType(e,t)){case"TrustedHTML":return xe(o);case"TrustedScriptURL":return function(e){we(),Oe++;try{return Ne.createScriptURL(e)}finally{Oe--}}(o)}return o},un=function(e,t,o,r){try{o?e.setAttributeNS(o,t,r):e.setAttribute(t,r),en(e)?qt(e):E(n.removed)}catch(n){Xt(t,e)}},fn=function(e){on(Me.beforeSanitizeAttributes,e,null);const t=e.attributes;if(!t||en(e))return;const n={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:$e,forceKeepAttr:void 0};let o=t.length;const r=Ft(e.nodeName);for(;o--;){const a=t[o],i=a.name,l=a.namespaceURI,c=a.value,s=Ft(i),u=c;let f="value"===i?u:C(u);n.attrName=s,n.attrValue=f,n.keepAttr=!0,n.forceKeepAttr=void 0,on(Me.uponSanitizeAttribute,e,n),f=n.attrValue,!dt||"id"!==s&&"name"!==s||0===k(f,ht)||(Xt(i,e),f=ht+f),rt&&z(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)||"attributename"===s&&w(f,"href")?Xt(i,e):n.forceKeepAttr||(!n.keepAttr||!nt&&z(he,f)?Xt(i,e):(ot&&(f=Jt(f)),an(r,s,f)?(f=sn(r,s,l,f),f!==u&&un(e,i,l,f)):Xt(i,e)))}on(Me.afterSanitizeAttributes,e,null)},mn=function(e){let t=null;const n=Zt(e);for(on(Me.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if(on(Me.uponSanitizeShadowNode,t,null),rn(t),fn(t),tn(t.content)&&mn(t.content),1===(Se?Se(t):t.nodeType)){const e=be(t);tn(e)&&(pn(e),mn(e))}on(Me.afterSanitizeShadowDOM,e,null)},pn=function(e){const t=[{node:e,shadow:null}];for(;t.length>0;){const e=t.pop();if(e.shadow){mn(e.shadow);continue}const n=e.node,o=1===(Se?Se(n):n.nodeType),r=j(n);if(r)for(let e=r.length-1;e>=0;--e)t.push({node:r[e],shadow:null});if(o){const e=Ee?Ee(n):null;if("string"==typeof e&&"template"===Ft(e)){const e=n.content;tn(e)&&t.push({node:e,shadow:null})}}if(o){const e=be(n);tn(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return n.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=null,a=null,i=null,l=null;if(kt=!e,kt&&(e="\x3c!--\x3e"),"string"!=typeof e&&!nn(e)&&"string"!=typeof(e=function(e){switch(typeof e){case"string":return e;case"number":return R(e);case"boolean":return D(e);case"bigint":return I?I(e):"0";case"symbol":return L?L(e):"Symbol()";case"undefined":default:return P(e);case"function":case"object":{if(null===e)return P(e);const t=e,n=G(t,"toString");if("function"==typeof n){const e=n(t);return"string"==typeof e?e:P(e)}return P(e)}}}(e)))throw U("dirty is not a string, aborting");if(!n.isSupported)return e;it?(Ye=lt,$e=ct):Wt(t),(Me.uponSanitizeElement.length>0||Me.uponSanitizeAttribute.length>0)&&(Ye=W(Ye)),Me.uponSanitizeAttribute.length>0&&($e=W($e)),n.removed=[];const c=yt&&"string"!=typeof e&&nn(e);if(c){const t=Ee?Ee(e):e.nodeName;if("string"==typeof t){const e=Ft(t);if(!Ye[e]||Ve[e])throw U("root node is forbidden and cannot be sanitized in-place")}if(en(e))throw U("root node is clobbered and cannot be sanitized in-place");try{pn(e)}catch(t){throw $t(e),t}}else if(nn(e))o=Vt("\x3c!----\x3e"),a=o.ownerDocument.importNode(e,!0),1===a.nodeType&&"BODY"===a.nodeName||"HTML"===a.nodeName?o=a:o.appendChild(a),pn(a);else{if(!ut&&!ot&&!at&&-1===e.indexOf("<"))return Ne&&mt?xe(e):e;if(o=Vt(e),!o)return ut?null:mt?Ae:""}o&&st&&qt(o.firstChild);const s=Zt(c?e:o);try{for(;i=s.nextNode();)rn(i),fn(i),tn(i.content)&&mn(i.content)}catch(t){throw c&&$t(e),t}if(c)return T(n.removed,e=>{e.element&&function(e){const t=[e];for(;t.length>0;){const e=t.pop();1===(Se?Se(e):e.nodeType)&&Kt(e);const n=j(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}}(e.element)}),ot&&Qt(e),e;if(ut){if(ot&&Qt(o),ft)for(l=De.call(o.ownerDocument);o.firstChild;)l.appendChild(o.firstChild);else l=o;return($e.shadowroot||$e.shadowrootmode)&&(l=Le.call(r,l,!0)),l}let u=at?o.outerHTML:o.innerHTML;return at&&Ye["!doctype"]&&o.ownerDocument&&o.ownerDocument.doctype&&o.ownerDocument.doctype.name&&z(ue,o.ownerDocument.doctype.name)&&(u="<!DOCTYPE "+o.ownerDocument.doctype.name+">\n"+u),ot&&(u=Jt(u)),Ne&&mt?xe(u):u},n.setConfig=function(){Wt(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),it=!0,lt=Ye,ct=$e},n.clearConfig=function(){jt=null,it=!1,lt=null,ct=null,Ne=_e,Ae=""},n.isValidAttribute=function(e,t,n){jt||Wt({});const o=Ft(e),r=Ft(t);return an(o,r,n)},n.addHook=function(e,t){"function"==typeof t&&M(Me,e)&&N(Me[e],t)},n.removeHook=function(e,t){if(M(Me,e)){if(void 0!==t){const n=S(Me[e],t);return-1===n?void 0:_(Me[e],n,1)[0]}return E(Me[e])}},n.removeHooks=function(e){M(Me,e)&&(Me[e]=[])},n.removeAllHooks=function(){Me={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},n}(),Te=o(4848);const Se=(...e)=>e.filter(Boolean).join(" ")||null,Ee=[];function Ne({headline:t,headlineSize:n="600",headlineLevel:o=2,text:r,buttons:a=Ee,variant:i="primary",backgroundColor:l,padding:c,image:s,imageAlt:u="",centered:f=!0,className:m}){const p=!!s,d=e(),h=`h${o}`;return(0,Te.jsx)("section",{className:Se("mg-cta",i&&`mg-cta--${i}`,p&&"mg-cta--with-image",!p&&f&&"mg-cta--centered",m),...t?{"aria-labelledby":d}:{"aria-label":"Call to action"},...(l||c)&&{style:{...l&&{"--mg-cta-bg":l},...c&&{padding:c}}},children:(0,Te.jsxs)("div",{className:"mg-cta__inner mg-container",children:[(0,Te.jsxs)("div",{className:"mg-cta__body",children:[t&&(0,Te.jsx)(h,{id:d,className:Se("mg-cta__headline",`mg-u-font-size-${n}`),children:t}),r&&(0,Te.jsx)("div",{className:"mg-cta__text",dangerouslySetInnerHTML:{__html:be.sanitize(r)}}),a.length>0&&(0,Te.jsx)("div",{className:"mg-cta__actions",children:a.map((e,t)=>(0,Te.jsx)("a",{href:e.url||"#",className:Se("mg-button","Secondary"===e.type?"mg-button-secondary":"mg-button-primary"),children:e.label},t))})]}),p&&(0,Te.jsx)("div",{className:"mg-cta__image",children:(0,Te.jsx)("img",{src:s,alt:u})})]})})}Ne.propTypes={headline:a().string,headlineSize:a().string,headlineLevel:a().oneOf([2,3,4,5,6]),text:a().string,buttons:a().arrayOf(a().shape({label:a().string.isRequired,url:a().string,type:a().oneOf(["Primary","Secondary"])})),variant:a().oneOf(["primary","secondary","tertiary","quaternary"]),backgroundColor:a().string,padding:a().string,image:a().string,imageAlt:a().string,centered:a().bool,className:a().string};const _e=Ne;function Ae(e){const{dataset:t}=e;let n=[];try{n=t.buttons?JSON.parse(t.buttons):[]}catch{n=[]}const o=parseInt(t.headlineLevel,10),r=o>=2&&o<=6?o:2;return{headline:t.headline||"",headlineSize:t.headlineSize||"600",headlineLevel:r,text:t.text||"",buttons:n,variant:t.variant||"primary",backgroundColor:t.backgroundColor||void 0,padding:t.padding||void 0,image:t.image||void 0,imageAlt:t.imageAlt||"",centered:"false"!==t.centered,className:t.className||void 0}}export{Ne as TextCta,_e as default,Ae as fromElement};
|
|
6
|
+
import{useId as e}from"react";var t={2694(e,t,n){var o=n(6925);function r(){}function a(){}a.resetWarningCache=r,e.exports=function(){function e(e,t,n,r,a,i){if(i!==o){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:a,resetWarningCache:r};return n.PropTypes=n,n}},5556(e,t,n){e.exports=n(2694)()},6925(e){e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},1772(e,t){Symbol.for("react.fragment"),t.jsxDEV=void 0},5446(e,t,n){e.exports=n(1772)}};const n={};function o(e){const r=n[e];if(void 0!==r)return r.exports;const a=n[e]={exports:{}};return t[e](a,a.exports,o),a.exports}o.n=e=>{const t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},o.d=(e,t)=>{if(Array.isArray(t))for(var n=0;n<t.length;){var r=t[n++],a=t[n++];o.o(e,r)?0===a&&n++:0===a?Object.defineProperty(e,r,{enumerable:!0,value:t[n++]}):Object.defineProperty(e,r,{enumerable:!0,get:a})}else for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var r=o(5556),a=o.n(r);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=Array(t);n<t;n++)o[n]=e[n];return o}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o,r,a,i,l=[],c=!0,s=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(c=(o=a.call(n)).done)&&(l.push(o.value),l.length!==t);c=!0);}catch(e){s=!0,r=e}finally{try{if(!c&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(s)throw r}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const c=Object.entries,s=Object.setPrototypeOf,u=Object.isFrozen,f=Object.getPrototypeOf,m=Object.getOwnPropertyDescriptor;let p=Object.freeze,d=Object.seal,h=Object.create,g="undefined"!=typeof Reflect&&Reflect,y=g.apply,b=g.construct;p||(p=function(e){return e}),d||(d=function(e){return e}),y||(y=function(e,t){for(var n=arguments.length,o=new Array(n>2?n-2:0),r=2;r<n;r++)o[r-2]=arguments[r];return e.apply(t,o)}),b||(b=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return new e(...n)});const T=j(Array.prototype.forEach),S=j(Array.prototype.lastIndexOf),E=j(Array.prototype.pop),A=j(Array.prototype.push),N=j(Array.prototype.splice),_=Array.isArray,v=j(String.prototype.toLowerCase),O=j(String.prototype.toString),w=j(String.prototype.match),x=j(String.prototype.replace),D=j(String.prototype.indexOf),C=j(String.prototype.trim),R=j(Number.prototype.toString),I=j(Boolean.prototype.toString),k="undefined"==typeof BigInt?null:j(BigInt.prototype.toString),L="undefined"==typeof Symbol?null:j(Symbol.prototype.toString),M=j(Object.prototype.hasOwnProperty),P=j(Object.prototype.toString),z=j(RegExp.prototype.test),U=(F=TypeError,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return b(F,t)});var F;function j(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,o=new Array(n>1?n-1:0),r=1;r<n;r++)o[r-1]=arguments[r];return y(e,t,o)}}function H(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:v;if(s&&s(e,null),!_(t))return e;let o=t.length;for(;o--;){let r=t[o];if("string"==typeof r){const e=n(r);e!==r&&(u(t)||(t[o]=e),r=e)}e[r]=!0}return e}function B(e){for(let t=0;t<e.length;t++)M(e,t)||(e[t]=null);return e}function W(e){const t=h(null);for(const o of c(e)){var n=l(o,2);const r=n[0],a=n[1];M(e,r)&&(_(a)?t[r]=B(a):a&&"object"==typeof a&&a.constructor===Object?t[r]=W(a):t[r]=a)}return t}function G(e,t){for(;null!==e;){const n=m(e,t);if(n){if(n.get)return j(n.get);if("function"==typeof n.value)return j(n.value)}e=f(e)}return function(){return null}}const Y=p(["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"]),V=p(["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"]),q=p(["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"]),$=p(["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"]),X=p(["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"]),K=p(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Z=p(["#text"]),J=p(["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"]),Q=p(["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","dominant-baseline","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-orientation","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"]),ee=p(["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"]),te=p(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),ne=d(/{{[\w\W]*|^[\w\W]*}}/g),oe=d(/<%[\w\W]*|^[\w\W]*%>/g),re=d(/\${[\w\W]*/g),ae=d(/^data-[\-\w.\u00B7-\uFFFF]+$/),ie=d(/^aria-[\-\w]+$/),le=d(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ce=d(/^(?:\w+script|data):/i),se=d(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ue=d(/^html$/i),fe=d(/^[a-z][.\w]*(-[.\w]+)+$/i),me=d(/<[/\w!]/g),pe=d(/<[/\w]/g),de=d(/<\/no(script|embed|frames)/i),he=d(/\/>/i),ge=function(){return"undefined"==typeof window?null:window},ye=function(e,t,n,o){return M(e,t)&&_(e[t])?H(o.base?W(o.base):{},e[t],o.transform):n};var be=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ge();const n=t=>e(t);if(n.version="3.4.12",n.removed=[],!t||!t.document||9!==t.document.nodeType||!t.Element)return n.isSupported=!1,n;let o=t.document;const r=o,a=r.currentScript;t.DocumentFragment;const i=t.HTMLTemplateElement,l=t.Node,s=t.Element,u=t.NodeFilter;void 0===t.NamedNodeMap&&(t.NamedNodeMap||t.MozNamedAttrMap),t.HTMLFormElement;const f=t.DOMParser,m=t.trustedTypes,g=s.prototype,y=G(g,"cloneNode"),b=G(g,"remove"),F=G(g,"nextSibling"),j=G(g,"childNodes"),B=G(g,"parentNode"),be=G(g,"shadowRoot"),Te=G(g,"attributes"),Se=l&&l.prototype?G(l.prototype,"nodeType"):null,Ee=l&&l.prototype?G(l.prototype,"nodeName"):null;if("function"==typeof i){const e=o.createElement("template");e.content&&e.content.ownerDocument&&(o=e.content.ownerDocument)}let Ae,Ne,_e="",ve=!1,Oe=0;const we=function(){if(Oe>0)throw U('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},xe=function(e){we(),Oe++;try{return Ae.createHTML(e)}finally{Oe--}},De=o,Ce=De.implementation,Re=De.createNodeIterator,Ie=De.createDocumentFragment,ke=De.getElementsByTagName,Le=r.importNode;let Me={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};n.isSupported="function"==typeof c&&"function"==typeof B&&Ce&&void 0!==Ce.createHTMLDocument;const Pe=ne,ze=oe,Ue=re,Fe=ae,je=ie,He=ce,Be=se,We=fe;let Ge=le,Ye=null;const Ve=H({},[...Y,...V,...q,...X,...Z]);let qe=null;const $e=H({},[...J,...Q,...ee,...te]);let Xe=Object.seal(h(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}})),Ke=null,Ze=null;const Je=Object.seal(h(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Qe=!0,et=!0,tt=!1,nt=!0,ot=!1,rt=!0,at=!1,it=!1,lt=null,ct=null,st=!1,ut=!1,ft=!1,mt=!1,pt=!0,dt=!1;const ht="user-content-";let gt=!0,yt=!1,bt={},Tt=null;const St=H({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]);let Et=null;const At=H({},["audio","video","img","source","image","track"]);let Nt=null;const _t=H({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),vt="http://www.w3.org/1998/Math/MathML",Ot="http://www.w3.org/2000/svg",wt="http://www.w3.org/1999/xhtml";let xt=wt,Dt=!1,Ct=null;const Rt=H({},[vt,Ot,wt],O),It=p(["mi","mo","mn","ms","mtext"]);let kt=H({},It);const Lt=p(["annotation-xml"]);let Mt=H({},Lt);const Pt=H({},["title","style","font","a","script"]);let zt=null;const Ut=["application/xhtml+xml","text/html"];let Ft=null,jt=null;const Ht=o.createElement("form"),Bt=function(e){return e instanceof RegExp||e instanceof Function},Wt=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(jt&&jt===e)return;e&&"object"==typeof e||(e={}),e=W(e),zt=-1===Ut.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE,Ft="application/xhtml+xml"===zt?O:v,Ye=ye(e,"ALLOWED_TAGS",Ve,{transform:Ft}),qe=ye(e,"ALLOWED_ATTR",$e,{transform:Ft}),Ct=ye(e,"ALLOWED_NAMESPACES",Rt,{transform:O}),Nt=ye(e,"ADD_URI_SAFE_ATTR",_t,{transform:Ft,base:_t}),Et=ye(e,"ADD_DATA_URI_TAGS",At,{transform:Ft,base:At}),Tt=ye(e,"FORBID_CONTENTS",St,{transform:Ft}),Ke=ye(e,"FORBID_TAGS",W({}),{transform:Ft}),Ze=ye(e,"FORBID_ATTR",W({}),{transform:Ft}),bt=!!M(e,"USE_PROFILES")&&(e.USE_PROFILES&&"object"==typeof e.USE_PROFILES?W(e.USE_PROFILES):e.USE_PROFILES),Qe=!1!==e.ALLOW_ARIA_ATTR,et=!1!==e.ALLOW_DATA_ATTR,tt=e.ALLOW_UNKNOWN_PROTOCOLS||!1,nt=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,ot=e.SAFE_FOR_TEMPLATES||!1,rt=!1!==e.SAFE_FOR_XML,at=e.WHOLE_DOCUMENT||!1,ut=e.RETURN_DOM||!1,ft=e.RETURN_DOM_FRAGMENT||!1,mt=e.RETURN_TRUSTED_TYPE||!1,st=e.FORCE_BODY||!1,pt=!1!==e.SANITIZE_DOM,dt=e.SANITIZE_NAMED_PROPS||!1,gt=!1!==e.KEEP_CONTENT,yt=e.IN_PLACE||!1,Ge=function(e){try{return z(e,""),!0}catch(e){return!1}}(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:le,xt="string"==typeof e.NAMESPACE?e.NAMESPACE:wt,kt=M(e,"MATHML_TEXT_INTEGRATION_POINTS")&&e.MATHML_TEXT_INTEGRATION_POINTS&&"object"==typeof e.MATHML_TEXT_INTEGRATION_POINTS?W(e.MATHML_TEXT_INTEGRATION_POINTS):H({},It),Mt=M(e,"HTML_INTEGRATION_POINTS")&&e.HTML_INTEGRATION_POINTS&&"object"==typeof e.HTML_INTEGRATION_POINTS?W(e.HTML_INTEGRATION_POINTS):H({},Lt);const t=M(e,"CUSTOM_ELEMENT_HANDLING")&&e.CUSTOM_ELEMENT_HANDLING&&"object"==typeof e.CUSTOM_ELEMENT_HANDLING?W(e.CUSTOM_ELEMENT_HANDLING):h(null);if(Xe=h(null),M(t,"tagNameCheck")&&Bt(t.tagNameCheck)&&(Xe.tagNameCheck=t.tagNameCheck),M(t,"attributeNameCheck")&&Bt(t.attributeNameCheck)&&(Xe.attributeNameCheck=t.attributeNameCheck),M(t,"allowCustomizedBuiltInElements")&&"boolean"==typeof t.allowCustomizedBuiltInElements&&(Xe.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),d(Xe),ot&&(et=!1),ft&&(ut=!0),bt&&(Ye=H({},Z),qe=h(null),!0===bt.html&&(H(Ye,Y),H(qe,J)),!0===bt.svg&&(H(Ye,V),H(qe,Q),H(qe,te)),!0===bt.svgFilters&&(H(Ye,q),H(qe,Q),H(qe,te)),!0===bt.mathMl&&(H(Ye,X),H(qe,ee),H(qe,te))),Je.tagCheck=null,Je.attributeCheck=null,M(e,"ADD_TAGS")&&("function"==typeof e.ADD_TAGS?Je.tagCheck=e.ADD_TAGS:_(e.ADD_TAGS)&&(Ye===Ve&&(Ye=W(Ye)),H(Ye,e.ADD_TAGS,Ft))),M(e,"ADD_ATTR")&&("function"==typeof e.ADD_ATTR?Je.attributeCheck=e.ADD_ATTR:_(e.ADD_ATTR)&&(qe===$e&&(qe=W(qe)),H(qe,e.ADD_ATTR,Ft))),M(e,"ADD_URI_SAFE_ATTR")&&_(e.ADD_URI_SAFE_ATTR)&&H(Nt,e.ADD_URI_SAFE_ATTR,Ft),M(e,"FORBID_CONTENTS")&&_(e.FORBID_CONTENTS)&&(Tt===St&&(Tt=W(Tt)),H(Tt,e.FORBID_CONTENTS,Ft)),M(e,"ADD_FORBID_CONTENTS")&&_(e.ADD_FORBID_CONTENTS)&&(Tt===St&&(Tt=W(Tt)),H(Tt,e.ADD_FORBID_CONTENTS,Ft)),gt&&(Ye["#text"]=!0),at&&H(Ye,["html","head","body"]),Ye.table&&(H(Ye,["tbody"]),delete Ke.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');const t=Ae;Ae=e.TRUSTED_TYPES_POLICY;try{_e=xe("")}catch(e){throw Ae=t,e}}else null===e.TRUSTED_TYPES_POLICY?(Ae=void 0,_e=""):(void 0===Ae&&(ve||(Ne=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let n=null;const o="data-tt-policy-suffix";t&&t.hasAttribute(o)&&(n=t.getAttribute(o));const r="dompurify"+(n?"#"+n:"");try{return e.createPolicy(r,{createHTML:e=>e,createScriptURL:e=>e})}catch(e){return console.warn("TrustedTypes policy "+r+" could not be created."),null}}(m,a),ve=!0),Ae=Ne),Ae&&"string"==typeof _e&&(_e=xe("")));p&&p(e),jt=e},Gt=H({},[...V,...q,...$]),Yt=H({},[...X,...K]),Vt=function(e){A(n.removed,{element:e});try{B(e).removeChild(e)}catch(t){if(b(e),!B(e))throw U("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},qt=function(e){Kt(e);const t=j(e);if(t){const e=[];T(t,t=>{A(e,t)}),T(e,e=>{try{b(e)}catch(e){}})}const n=Te(e);if(n)for(let t=n.length-1;t>=0;--t){const o=n[t],r=o&&o.name;if("string"==typeof r)try{e.removeAttribute(r)}catch(e){}}},$t=function(e,t){try{A(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){A(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e)if(ut||ft)try{Vt(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},Xt=function(e){const t=Te(e);if(t)for(let n=t.length-1;n>=0;--n){const o=t[n],r=o&&o.name;if("string"==typeof r&&!qe[Ft(r)])try{e.removeAttribute(r)}catch(e){}}},Kt=function(e){const t=[e];for(;t.length>0;){const e=t.pop();1===(Se?Se(e):e.nodeType)&&Xt(e);const n=j(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}},Zt=function(e){let t=null,n=null;if(st)e="<remove></remove>"+e;else{const t=w(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===zt&&xt===wt&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const r=Ae?xe(e):e;if(xt===wt)try{t=(new f).parseFromString(r,zt)}catch(e){}if(!t||!t.documentElement){t=Ce.createDocument(xt,"template",null);try{t.documentElement.innerHTML=Dt?_e:r}catch(e){}}const a=t.body||t.documentElement;return e&&n&&a.insertBefore(o.createTextNode(n),a.childNodes[0]||null),xt===wt?ke.call(t,at?"html":"body")[0]:at?t.documentElement:a},Jt=function(e){return Re.call(e.ownerDocument||e,e,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},Qt=function(e){return e=x(e,Pe," "),e=x(e,ze," "),x(e,Ue," ")},en=function(e){var t;e.normalize();const n=Re.call(e.ownerDocument||e,e,u.SHOW_TEXT|u.SHOW_COMMENT|u.SHOW_CDATA_SECTION|u.SHOW_PROCESSING_INSTRUCTION,null);let o=n.nextNode();for(;o;)o.data=Qt(o.data),o=n.nextNode();const r=null===(t=e.querySelectorAll)||void 0===t?void 0:t.call(e,"template");r&&T(r,e=>{nn(e.content)&&en(e.content)})},tn=function(e){const t=Ee?Ee(e):null;return"string"==typeof t&&"form"===Ft(t)&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||e.attributes!==Te(e)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes||e.nodeType!==Se(e)||e.childNodes!==j(e))},nn=function(e){if(!Se||"object"!=typeof e||null===e)return!1;try{return 11===Se(e)}catch(e){return!1}},on=function(e){if(!Se||"object"!=typeof e||null===e)return!1;try{return"number"==typeof Se(e)}catch(e){return!1}};function rn(e,t,o){0!==e.length&&T(e,e=>{e.call(n,t,o,jt)})}const an=function(e,t){if(rn(Me.beforeSanitizeElements,e,null),e!==t&&null===B(e))return!0;if(tn(e))return Vt(e),!0;const o=Ft(Ee?Ee(e):e.nodeName);if(rn(Me.uponSanitizeElement,e,{tagName:o,allowedTags:Ye}),e!==t&&null===B(e))return!0;if(function(e,t){return!!(rt&&e.hasChildNodes()&&!on(e.firstElementChild)&&z(me,e.textContent)&&z(me,e.innerHTML))||!(!rt||e.namespaceURI!==wt||"style"!==t||!on(e.firstElementChild))||7===e.nodeType||!(!rt||8!==e.nodeType||!z(pe,e.data))}(e,o))return Vt(e),!0;if(Ke[o]||!(Je.tagCheck instanceof Function&&Je.tagCheck(o))&&!Ye[o]){const t=function(e,t){if(!Ke[t]&&sn(t)){if(Xe.tagNameCheck instanceof RegExp&&z(Xe.tagNameCheck,t))return!1;if(Xe.tagNameCheck instanceof Function&&Xe.tagNameCheck(t))return!1}if(gt&&!Tt[t]){const t=B(e),n=j(e);if(n&&t)for(let o=n.length-1;o>=0;--o){const r=yt?n[o]:y(n[o],!0);t.insertBefore(r,F(e))}}return Vt(e),!0}(e,o);return!1===t&&rn(Me.afterSanitizeElements,e,null),t}if(1===(Se?Se(e):e.nodeType)&&!function(e){let t=B(e);t&&t.tagName||(t={namespaceURI:xt,tagName:"template"});const n=v(e.tagName),o=v(t.tagName);return!!Ct[e.namespaceURI]&&(e.namespaceURI===Ot?function(e,t,n){return t.namespaceURI===wt?"svg"===e:t.namespaceURI===vt?"svg"===e&&("annotation-xml"===n||kt[n]):Boolean(Gt[e])}(n,t,o):e.namespaceURI===vt?function(e,t,n){return t.namespaceURI===wt?"math"===e:t.namespaceURI===Ot?"math"===e&&Mt[n]:Boolean(Yt[e])}(n,t,o):e.namespaceURI===wt?function(e,t,n){return!(t.namespaceURI===Ot&&!Mt[n])&&!(t.namespaceURI===vt&&!kt[n])&&!Yt[e]&&(Pt[e]||!Gt[e])}(n,t,o):!("application/xhtml+xml"!==zt||!Ct[e.namespaceURI]))}(e))return Vt(e),!0;if(("noscript"===o||"noembed"===o||"noframes"===o)&&z(de,e.innerHTML))return Vt(e),!0;if(ot&&3===e.nodeType){const t=Qt(e.textContent);e.textContent!==t&&(A(n.removed,{element:e.cloneNode()}),e.textContent=t)}return rn(Me.afterSanitizeElements,e,null),!1},ln=function(e,t,n){if(Ze[t])return!1;if(rt&&"patchsrc"===t)return!1;if(rt&&"for"===t&&"label"!==e&&"output"!==e)return!1;if(pt&&("id"===t||"name"===t)&&(n in o||n in Ht))return!1;const r=qe[t]||Je.attributeCheck instanceof Function&&Je.attributeCheck(t,e);if(et&&z(Fe,t));else if(Qe&&z(je,t));else if(r){if(Nt[t]);else if(z(Ge,x(n,Be,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==D(n,"data:")||!Et[e])if(tt&&!z(He,x(n,Be,"")));else if(n)return!1}else if(!(sn(e)&&(Xe.tagNameCheck instanceof RegExp&&z(Xe.tagNameCheck,e)||Xe.tagNameCheck instanceof Function&&Xe.tagNameCheck(e))&&(Xe.attributeNameCheck instanceof RegExp&&z(Xe.attributeNameCheck,t)||Xe.attributeNameCheck instanceof Function&&Xe.attributeNameCheck(t,e))||"is"===t&&Xe.allowCustomizedBuiltInElements&&(Xe.tagNameCheck instanceof RegExp&&z(Xe.tagNameCheck,n)||Xe.tagNameCheck instanceof Function&&Xe.tagNameCheck(n))))return!1;return!0},cn=H({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),sn=function(e){return!cn[v(e)]&&z(We,e)},un=function(e,t,n,o){if(Ae&&"object"==typeof m&&"function"==typeof m.getAttributeType&&!n)switch(m.getAttributeType(e,t)){case"TrustedHTML":return xe(o);case"TrustedScriptURL":return function(e){we(),Oe++;try{return Ae.createScriptURL(e)}finally{Oe--}}(o)}return o},fn=function(e,t,o,r){try{o?e.setAttributeNS(o,t,r):e.setAttribute(t,r),tn(e)?Vt(e):E(n.removed)}catch(n){$t(t,e)}},mn=function(e){rn(Me.beforeSanitizeAttributes,e,null);const t=e.attributes;if(!t||tn(e))return;const n={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:qe,forceKeepAttr:void 0};let o=t.length;const r=Ft(e.nodeName);for(;o--;){const a=t[o],i=a.name,l=a.namespaceURI,c=a.value,s=Ft(i),u=c;let f="value"===i?u:C(u);n.attrName=s,n.attrValue=f,n.keepAttr=!0,n.forceKeepAttr=void 0,rn(Me.uponSanitizeAttribute,e,n),f=n.attrValue,!dt||"id"!==s&&"name"!==s||0===D(f,ht)||($t(i,e),f=ht+f),rt&&z(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)||"attributename"===s&&w(f,"href")?$t(i,e):n.forceKeepAttr||(!n.keepAttr||!nt&&z(he,f)?$t(i,e):(ot&&(f=Qt(f)),ln(r,s,f)?(f=un(r,s,l,f),f!==u&&fn(e,i,l,f)):$t(i,e)))}rn(Me.afterSanitizeAttributes,e,null)},pn=function(e){let t=null;const n=Jt(e);for(rn(Me.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if(rn(Me.uponSanitizeShadowNode,t,null),an(t,e),mn(t),nn(t.content)&&pn(t.content),1===(Se?Se(t):t.nodeType)){const e=be(t);nn(e)&&(dn(e),pn(e))}rn(Me.afterSanitizeShadowDOM,e,null)},dn=function(e){const t=[{node:e,shadow:null}];for(;t.length>0;){const e=t.pop();if(e.shadow){pn(e.shadow);continue}const n=e.node,o=1===(Se?Se(n):n.nodeType),r=j(n);if(r)for(let e=r.length-1;e>=0;--e)t.push({node:r[e],shadow:null});if(o){const e=Ee?Ee(n):null;if("string"==typeof e&&"template"===Ft(e)){const e=n.content;nn(e)&&t.push({node:e,shadow:null})}}if(o){const e=be(n);nn(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return n.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=null,a=null,i=null,l=null;if(Dt=!e,Dt&&(e="\x3c!--\x3e"),"string"!=typeof e&&!on(e)&&"string"!=typeof(e=function(e){switch(typeof e){case"string":return e;case"number":return R(e);case"boolean":return I(e);case"bigint":return k?k(e):"0";case"symbol":return L?L(e):"Symbol()";case"undefined":default:return P(e);case"function":case"object":{if(null===e)return P(e);const t=e,n=G(t,"toString");if("function"==typeof n){const e=n(t);return"string"==typeof e?e:P(e)}return P(e)}}}(e)))throw U("dirty is not a string, aborting");if(!n.isSupported)return e;it?(Ye=lt,qe=ct):Wt(t),(Me.uponSanitizeElement.length>0||Me.uponSanitizeAttribute.length>0)&&(Ye=W(Ye)),Me.uponSanitizeAttribute.length>0&&(qe=W(qe)),n.removed=[];const c=yt&&"string"!=typeof e&&on(e);if(c){!function(e){if(!rt)return;const t=[e];for(;t.length>0;){const e=t.pop(),n=Se?Se(e):e.nodeType;if(7===n||8===n&&z(pe,e.data)){try{b(e)}catch(e){}continue}if(1===n){const t=e,n=Ft(Ee?Ee(e):e.nodeName);try{t.hasAttribute&&t.hasAttribute("patchsrc")&&t.removeAttribute("patchsrc"),t.hasAttribute&&t.hasAttribute("for")&&"label"!==n&&"output"!==n&&t.removeAttribute("for")}catch(e){}}const o=j(e);if(o)for(let e=o.length-1;e>=0;--e)t.push(o[e])}}(e);const t=Ee?Ee(e):e.nodeName;if("string"==typeof t){const n=Ft(t);if(!Ye[n]||Ke[n])throw qt(e),U("root node is forbidden and cannot be sanitized in-place")}if(tn(e))throw qt(e),U("root node is clobbered and cannot be sanitized in-place");try{dn(e)}catch(t){throw qt(e),t}}else if(on(e))o=Zt("\x3c!----\x3e"),a=o.ownerDocument.importNode(e,!0),1===a.nodeType&&"BODY"===a.nodeName||"HTML"===a.nodeName?o=a:o.appendChild(a),dn(a);else{if(!ut&&!ot&&!at&&-1===e.indexOf("<"))return Ae&&mt?xe(e):e;if(o=Zt(e),!o)return ut?null:mt?_e:""}o&&st&&Vt(o.firstChild);const s=c?e:o,u=Jt(s);try{for(;i=u.nextNode();)an(i,s),mn(i),nn(i.content)&&pn(i.content)}catch(t){throw c&&(qt(e),T(n.removed,e=>{e.element&&Kt(e.element)})),t}if(c)return T(n.removed,e=>{e.element&&Kt(e.element)}),ot&&en(e),e;if(ut){if(ot&&en(o),ft)for(l=Ie.call(o.ownerDocument);o.firstChild;)l.appendChild(o.firstChild);else l=o;return(qe.shadowroot||qe.shadowrootmode)&&(l=Le.call(r,l,!0)),l}let f=at?o.outerHTML:o.innerHTML;return at&&Ye["!doctype"]&&o.ownerDocument&&o.ownerDocument.doctype&&o.ownerDocument.doctype.name&&z(ue,o.ownerDocument.doctype.name)&&(f="<!DOCTYPE "+o.ownerDocument.doctype.name+">\n"+f),ot&&(f=Qt(f)),Ae&&mt?xe(f):f},n.setConfig=function(){Wt(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),it=!0,lt=Ye,ct=qe},n.clearConfig=function(){jt=null,it=!1,lt=null,ct=null,Ae=Ne,_e=""},n.isValidAttribute=function(e,t,n){jt||Wt({});const o=Ft(e),r=Ft(t);return ln(o,r,n)},n.addHook=function(e,t){"function"==typeof t&&M(Me,e)&&A(Me[e],t)},n.removeHook=function(e,t){if(M(Me,e)){if(void 0!==t){const n=S(Me[e],t);return-1===n?void 0:N(Me[e],n,1)[0]}return E(Me[e])}},n.removeHooks=function(e){M(Me,e)&&(Me[e]=[])},n.removeAllHooks=function(){Me={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},n}(),Te=o(5446);const Se=(...e)=>e.filter(Boolean).join(" ")||null,Ee=[];function Ae({headline:t,headlineSize:n="600",headlineLevel:o=2,text:r,buttons:a=Ee,variant:i="primary",backgroundColor:l,padding:c,image:s,imageAlt:u="",centered:f=!0,className:m}){const p=!!s,d=e(),h=`h${o}`;return(0,Te.jsxDEV)("section",{className:Se("mg-cta",i&&`mg-cta--${i}`,p&&"mg-cta--with-image",!p&&f&&"mg-cta--centered",m),...t?{"aria-labelledby":d}:{"aria-label":"Call to action"},...(l||c)&&{style:{...l&&{"--mg-cta-bg":l},...c&&{padding:c}}},children:(0,Te.jsxDEV)("div",{className:"mg-cta__inner mg-container",children:[(0,Te.jsxDEV)("div",{className:"mg-cta__body",children:[t&&(0,Te.jsxDEV)(h,{id:d,className:Se("mg-cta__headline",`mg-u-font-size-${n}`),children:t},void 0,!1),r&&(0,Te.jsxDEV)("div",{className:"mg-cta__text",dangerouslySetInnerHTML:{__html:be.sanitize(r)}},void 0,!1),a.length>0&&(0,Te.jsxDEV)("div",{className:"mg-cta__actions",children:a.map((e,t)=>(0,Te.jsxDEV)("a",{href:e.url||"#",className:Se("mg-button","Secondary"===e.type?"mg-button-secondary":"mg-button-primary"),children:e.label},t,!1))},void 0,!1)]},void 0,!0),p&&(0,Te.jsxDEV)("div",{className:"mg-cta__image",children:(0,Te.jsxDEV)("img",{src:s,alt:u},void 0,!1)},void 0,!1)]},void 0,!0)},void 0,!1)}Ae.propTypes={headline:a().string,headlineSize:a().string,headlineLevel:a().oneOf([2,3,4,5,6]),text:a().string,buttons:a().arrayOf(a().shape({label:a().string.isRequired,url:a().string,type:a().oneOf(["Primary","Secondary"])})),variant:a().oneOf(["primary","secondary","tertiary","quaternary"]),backgroundColor:a().string,padding:a().string,image:a().string,imageAlt:a().string,centered:a().bool,className:a().string};const Ne=Ae;function _e(e){const{dataset:t}=e;let n=[];try{n=t.buttons?JSON.parse(t.buttons):[]}catch{n=[]}const o=parseInt(t.headlineLevel,10),r=o>=2&&o<=6?o:2;return{headline:t.headline||"",headlineSize:t.headlineSize||"600",headlineLevel:r,text:t.text||"",buttons:n,variant:t.variant||"primary",backgroundColor:t.backgroundColor||void 0,padding:t.padding||void 0,image:t.image||void 0,imageAlt:t.imageAlt||"",centered:"false"!==t.centered,className:t.className||void 0}}export{Ae as TextCta,Ne as default,_e as fromElement};
|
|
@@ -1,11 +1 @@
|
|
|
1
|
-
/*! @license DOMPurify 3.4.
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* @license React
|
|
5
|
-
* react-jsx-runtime.production.js
|
|
6
|
-
*
|
|
7
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
8
|
-
*
|
|
9
|
-
* This source code is licensed under the MIT license found in the
|
|
10
|
-
* LICENSE file in the root directory of this source tree.
|
|
11
|
-
*/
|
|
1
|
+
/*! @license DOMPurify 3.4.12 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.4.12/LICENSE */
|
package/components/TextInput.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* This is a UNDRR Mangrove component: https://github.com/unisdr/undrr-mangrove?tab=readme-ov-file
|
|
3
|
-
* Compiled on: 2026-
|
|
3
|
+
* Compiled on: 2026-08-27T20:32:00.846Z
|
|
4
4
|
*/
|
|
5
|
-
|
|
6
|
-
import{useId as e}from"react";var r={2694(e,r,o){var a=o(6925);function t(){}function n(){}n.resetWarningCache=t,e.exports=function(){function e(e,r,o,t,n,l){if(l!==a){var i=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw i.name="Invariant Violation",i}}function r(){return e}e.isRequired=e;var o={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:r,element:e,elementType:e,instanceOf:r,node:e,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o}},5556(e,r,o){e.exports=o(2694)()},6925(e){e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},9698(e,r){var o=Symbol.for("react.transitional.element");function a(e,r,a){var t=null;if(void 0!==a&&(t=""+a),void 0!==r.key&&(t=""+r.key),"key"in r)for(var n in a={},r)"key"!==n&&(a[n]=r[n]);else a=r;return r=a.ref,{$$typeof:o,type:e,key:t,ref:void 0!==r?r:null,props:a}}Symbol.for("react.fragment"),r.jsx=a,r.jsxs=a},4848(e,r,o){e.exports=o(9698)}},o={};function a(e){var t=o[e];if(void 0!==t)return t.exports;var n=o[e]={exports:{}};return r[e](n,n.exports,a),n.exports}a.n=e=>{var r=e&&e.__esModule?()=>e.default:()=>e;return a.d(r,{a:r}),r},a.d=(e,r)=>{for(var o in r)a.o(r,o)&&!a.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:r[o]})},a.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r);var t=a(5556),n=a.n(t),l=a(4848);function i({id:r,name:o,type:a="text",label:t,hideLabel:n=!1,placeholder:i,value:s,defaultValue:p,onChange:d,disabled:c=!1,required:f=!1,helpText:u,error:m=!1,errorText:b,className:y,...g}){const h=e(),v=r||h,x=u?`${v}-help`:void 0,j=m&&b?`${v}-error`:void 0,T=[x,j].filter(Boolean).join(" ")||void 0,O=["mg-form-input",c&&"mg-form-input--disabled",m&&"mg-form-input--error"].filter(Boolean).join(" "),_=["mg-form-label",n&&"mg-u-sr-only",c&&"mg-form-label--disabled",f&&"mg-form-label--required"].filter(Boolean).join(" ");return(0,l.jsxs)("div",{className:["mg-form-field",y].filter(Boolean).join(" "),children:[t&&(0,l.jsx)("label",{className:_,htmlFor:v,children:t}),(0,l.jsx)("input",{className:O,type:a,id:v,name:o,placeholder:i,value:s,defaultValue:p,onChange:d,disabled:c,required:f,"aria-describedby":T,"aria-invalid":m||void 0,...t?{}:{"aria-label":i},...g}),u&&(0,l.jsx)("p",{className:"mg-form-help",id:x,children:u}),m&&b&&(0,l.jsx)("p",{className:"mg-form-error",id:j,role:"alert",children:b})]})}i.propTypes={id:n().string,name:n().string,type:n().oneOf(["text","email","password","number","tel","search","date","url"]),label:n().string,hideLabel:n().bool,placeholder:n().string,value:n().string,defaultValue:n().string,onChange:n().func,disabled:n().bool,required:n().bool,helpText:n().string,error:n().bool,errorText:n().string,className:n().string};const s=i;export{i as TextInput,s as default};
|
|
5
|
+
import{useId as e}from"react";var r={2694(e,r,o){var a=o(6925);function t(){}function n(){}n.resetWarningCache=t,e.exports=function(){function e(e,r,o,t,n,l){if(l!==a){var i=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw i.name="Invariant Violation",i}}function r(){return e}e.isRequired=e;var o={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:r,element:e,elementType:e,instanceOf:r,node:e,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o}},5556(e,r,o){e.exports=o(2694)()},6925(e){e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},1772(e,r){Symbol.for("react.fragment"),r.jsxDEV=void 0},5446(e,r,o){e.exports=o(1772)}};const o={};function a(e){const t=o[e];if(void 0!==t)return t.exports;const n=o[e]={exports:{}};return r[e](n,n.exports,a),n.exports}a.n=e=>{const r=e&&e.__esModule?()=>e.default:()=>e;return a.d(r,{a:r}),r},a.d=(e,r)=>{if(Array.isArray(r))for(var o=0;o<r.length;){var t=r[o++],n=r[o++];a.o(e,t)?0===n&&o++:0===n?Object.defineProperty(e,t,{enumerable:!0,value:r[o++]}):Object.defineProperty(e,t,{enumerable:!0,get:n})}else for(var t in r)a.o(r,t)&&!a.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},a.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r);var t=a(5556),n=a.n(t),l=a(5446);function i({id:r,name:o,type:a="text",label:t,hideLabel:n=!1,placeholder:i,value:s,defaultValue:d,onChange:p,disabled:c=!1,required:m=!1,helpText:u,error:f=!1,errorText:b,className:g,...h}){const y=e(),v=r||y,x=u?`${v}-help`:void 0,j=f&&b?`${v}-error`:void 0,O=[x,j].filter(Boolean).join(" ")||void 0,T=["mg-form-input",c&&"mg-form-input--disabled",f&&"mg-form-input--error"].filter(Boolean).join(" "),E=["mg-form-label",n&&"mg-u-sr-only",c&&"mg-form-label--disabled",m&&"mg-form-label--required"].filter(Boolean).join(" ");return(0,l.jsxDEV)("div",{className:["mg-form-field",g].filter(Boolean).join(" "),children:[t&&(0,l.jsxDEV)("label",{className:E,htmlFor:v,children:t},void 0,!1),(0,l.jsxDEV)("input",{className:T,type:a,id:v,name:o,placeholder:i,value:s,defaultValue:d,onChange:p,disabled:c,required:m,"aria-describedby":O,"aria-invalid":f||void 0,...t?{}:{"aria-label":i},...h},void 0,!1),u&&(0,l.jsxDEV)("p",{className:"mg-form-help",id:x,children:u},void 0,!1),f&&b&&(0,l.jsxDEV)("p",{className:"mg-form-error",id:j,role:"alert",children:b},void 0,!1)]},void 0,!0)}i.propTypes={id:n().string,name:n().string,type:n().oneOf(["text","email","password","number","tel","search","date","url"]),label:n().string,hideLabel:n().bool,placeholder:n().string,value:n().string,defaultValue:n().string,onChange:n().func,disabled:n().bool,required:n().bool,helpText:n().string,error:n().bool,errorText:n().string,className:n().string};const s=i;export{i as TextInput,s as default};
|
package/components/Textarea.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* This is a UNDRR Mangrove component: https://github.com/unisdr/undrr-mangrove?tab=readme-ov-file
|
|
3
|
-
* Compiled on: 2026-
|
|
3
|
+
* Compiled on: 2026-08-27T20:32:00.846Z
|
|
4
4
|
*/
|
|
5
|
-
|
|
6
|
-
import{useId as e}from"react";var r={2694(e,r,o){var a=o(6925);function t(){}function l(){}l.resetWarningCache=t,e.exports=function(){function e(e,r,o,t,l,n){if(n!==a){var i=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw i.name="Invariant Violation",i}}function r(){return e}e.isRequired=e;var o={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:r,element:e,elementType:e,instanceOf:r,node:e,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:l,resetWarningCache:t};return o.PropTypes=o,o}},5556(e,r,o){e.exports=o(2694)()},6925(e){e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},9698(e,r){var o=Symbol.for("react.transitional.element");function a(e,r,a){var t=null;if(void 0!==a&&(t=""+a),void 0!==r.key&&(t=""+r.key),"key"in r)for(var l in a={},r)"key"!==l&&(a[l]=r[l]);else a=r;return r=a.ref,{$$typeof:o,type:e,key:t,ref:void 0!==r?r:null,props:a}}Symbol.for("react.fragment"),r.jsx=a,r.jsxs=a},4848(e,r,o){e.exports=o(9698)}},o={};function a(e){var t=o[e];if(void 0!==t)return t.exports;var l=o[e]={exports:{}};return r[e](l,l.exports,a),l.exports}a.n=e=>{var r=e&&e.__esModule?()=>e.default:()=>e;return a.d(r,{a:r}),r},a.d=(e,r)=>{for(var o in r)a.o(r,o)&&!a.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:r[o]})},a.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r);var t=a(5556),l=a.n(t),n=a(4848);function i({id:r,name:o,label:a,hideLabel:t=!1,placeholder:l,value:i,defaultValue:s,onChange:d,rows:p=4,cols:c,disabled:f=!1,required:m=!1,helpText:u,error:b=!1,errorText:g,className:y,...h}){const v=e(),x=r||v,j=u?`${x}-help`:void 0,T=b&&g?`${x}-error`:void 0,O=[j,T].filter(Boolean).join(" ")||void 0,_=["mg-form-textarea",f&&"mg-form-textarea--disabled",b&&"mg-form-textarea--error"].filter(Boolean).join(" "),k=["mg-form-label",t&&"mg-u-sr-only",f&&"mg-form-label--disabled",m&&"mg-form-label--required"].filter(Boolean).join(" ");return(0,n.jsxs)("div",{className:["mg-form-field",y].filter(Boolean).join(" "),children:[a&&(0,n.jsx)("label",{className:k,htmlFor:x,children:a}),(0,n.jsx)("textarea",{className:_,id:x,name:o,placeholder:l,value:i,defaultValue:s,onChange:d,rows:p,cols:c,disabled:f,required:m,"aria-describedby":O,"aria-invalid":b||void 0,...a?{}:{"aria-label":l},...h}),u&&(0,n.jsx)("p",{className:"mg-form-help",id:j,children:u}),b&&g&&(0,n.jsx)("p",{className:"mg-form-error",id:T,role:"alert",children:g})]})}i.propTypes={id:l().string,name:l().string,label:l().string,hideLabel:l().bool,placeholder:l().string,value:l().string,defaultValue:l().string,onChange:l().func,rows:l().number,cols:l().number,disabled:l().bool,required:l().bool,helpText:l().string,error:l().bool,errorText:l().string,className:l().string};const s=i;export{i as Textarea,s as default};
|
|
5
|
+
import{useId as e}from"react";var r={2694(e,r,o){var a=o(6925);function t(){}function n(){}n.resetWarningCache=t,e.exports=function(){function e(e,r,o,t,n,l){if(l!==a){var i=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw i.name="Invariant Violation",i}}function r(){return e}e.isRequired=e;var o={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:r,element:e,elementType:e,instanceOf:r,node:e,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o}},5556(e,r,o){e.exports=o(2694)()},6925(e){e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},1772(e,r){Symbol.for("react.fragment"),r.jsxDEV=void 0},5446(e,r,o){e.exports=o(1772)}};const o={};function a(e){const t=o[e];if(void 0!==t)return t.exports;const n=o[e]={exports:{}};return r[e](n,n.exports,a),n.exports}a.n=e=>{const r=e&&e.__esModule?()=>e.default:()=>e;return a.d(r,{a:r}),r},a.d=(e,r)=>{if(Array.isArray(r))for(var o=0;o<r.length;){var t=r[o++],n=r[o++];a.o(e,t)?0===n&&o++:0===n?Object.defineProperty(e,t,{enumerable:!0,value:r[o++]}):Object.defineProperty(e,t,{enumerable:!0,get:n})}else for(var t in r)a.o(r,t)&&!a.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},a.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r);var t=a(5556),n=a.n(t),l=a(5446);function i({id:r,name:o,label:a,hideLabel:t=!1,placeholder:n,value:i,defaultValue:s,onChange:d,rows:c=4,cols:p,disabled:m=!1,required:f=!1,helpText:u,error:b=!1,errorText:g,className:h,...v}){const y=e(),x=r||y,j=u?`${x}-help`:void 0,T=b&&g?`${x}-error`:void 0,O=[j,T].filter(Boolean).join(" ")||void 0,E=["mg-form-textarea",m&&"mg-form-textarea--disabled",b&&"mg-form-textarea--error"].filter(Boolean).join(" "),_=["mg-form-label",t&&"mg-u-sr-only",m&&"mg-form-label--disabled",f&&"mg-form-label--required"].filter(Boolean).join(" ");return(0,l.jsxDEV)("div",{className:["mg-form-field",h].filter(Boolean).join(" "),children:[a&&(0,l.jsxDEV)("label",{className:_,htmlFor:x,children:a},void 0,!1),(0,l.jsxDEV)("textarea",{className:E,id:x,name:o,placeholder:n,value:i,defaultValue:s,onChange:d,rows:c,cols:p,disabled:m,required:f,"aria-describedby":O,"aria-invalid":b||void 0,...a?{}:{"aria-label":n},...v},void 0,!1),u&&(0,l.jsxDEV)("p",{className:"mg-form-help",id:j,children:u},void 0,!1),b&&g&&(0,l.jsxDEV)("p",{className:"mg-form-error",id:T,role:"alert",children:g},void 0,!1)]},void 0,!0)}i.propTypes={id:n().string,name:n().string,label:n().string,hideLabel:n().bool,placeholder:n().string,value:n().string,defaultValue:n().string,onChange:n().func,rows:n().number,cols:n().number,disabled:n().bool,required:n().bool,helpText:n().string,error:n().bool,errorText:n().string,className:n().string};const s=i;export{i as Textarea,s as default};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* This is a UNDRR Mangrove component: https://github.com/unisdr/undrr-mangrove?tab=readme-ov-file
|
|
3
|
-
* Compiled on: 2026-
|
|
3
|
+
* Compiled on: 2026-08-27T20:32:00.846Z
|
|
4
4
|
*/
|
|
5
5
|
/*! For license information please see VerticalCard.js.LICENSE.txt */
|
|
6
|
-
import*as e from"react";var t={6145(e,t,n){n.d(t,{F:()=>i}),n(1649);var r=n(5556),o=n.n(r),a=n(4848);function i({label:e,Type:t="Primary",State:n="Default",...r}){const o="Disabled"===n,i=["mg-button","mg-button-"+("Secondary"===t?"secondary":"primary"),o&&"disabled"].filter(Boolean).join(" ");return(0,a.jsx)("a",{className:i,...o?{"aria-disabled":"true"}:{href:"#"},...r,children:e})}i.propTypes={label:o().string.isRequired,Type:o().oneOf(["Primary","Secondary"]),State:o().oneOf(["Default","Disabled"])}},2694(e,t,n){var r=n(6925);function o(){}function a(){}a.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,a,i){if(i!==r){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:a,resetWarningCache:o};return n.PropTypes=n,n}},5556(e,t,n){e.exports=n(2694)()},6925(e){e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},9698(e,t){var n=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function o(e,t,r){var o=null;if(void 0!==r&&(o=""+r),void 0!==t.key&&(o=""+t.key),"key"in t)for(var a in r={},t)"key"!==a&&(r[a]=t[a]);else r=t;return t=r.ref,{$$typeof:n,type:e,key:o,ref:void 0!==t?t:null,props:r}}t.Fragment=r,t.jsx=o,t.jsxs=o},4848(e,t,n){e.exports=n(9698)},1649(e,t,n){var r;e.exports=(r={},n.d(r,{}),r)}},n={};function r(e){var o=n[e];if(void 0!==o)return o.exports;var a=n[e]={exports:{}};return t[e](a,a.exports,r),a.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r(1649);var o=r(5556),a=r.n(o);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],c=!0,s=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(c=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(s)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const c=Object.entries,s=Object.setPrototypeOf,u=Object.isFrozen,f=Object.getPrototypeOf,m=Object.getOwnPropertyDescriptor;let p=Object.freeze,d=Object.seal,h=Object.create,y="undefined"!=typeof Reflect&&Reflect,g=y.apply,b=y.construct;p||(p=function(e){return e}),d||(d=function(e){return e}),g||(g=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return e.apply(t,r)}),b||(b=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new e(...n)});const T=j(Array.prototype.forEach),S=j(Array.prototype.lastIndexOf),_=j(Array.prototype.pop),E=j(Array.prototype.push),N=j(Array.prototype.splice),A=Array.isArray,v=j(String.prototype.toLowerCase),O=j(String.prototype.toString),w=j(String.prototype.match),x=j(String.prototype.replace),k=j(String.prototype.indexOf),D=j(String.prototype.trim),R=j(Number.prototype.toString),C=j(Boolean.prototype.toString),I="undefined"==typeof BigInt?null:j(BigInt.prototype.toString),L="undefined"==typeof Symbol?null:j(Symbol.prototype.toString),M=j(Object.prototype.hasOwnProperty),P=j(Object.prototype.toString),z=j(RegExp.prototype.test),U=(F=TypeError,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return b(F,t)});var F;function j(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return g(e,t,r)}}function H(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:v;if(s&&s(e,null),!A(t))return e;let r=t.length;for(;r--;){let o=t[r];if("string"==typeof o){const e=n(o);e!==o&&(u(t)||(t[r]=e),o=e)}e[o]=!0}return e}function B(e){for(let t=0;t<e.length;t++)M(e,t)||(e[t]=null);return e}function W(e){const t=h(null);for(const r of c(e)){var n=l(r,2);const o=n[0],a=n[1];M(e,o)&&(A(a)?t[o]=B(a):a&&"object"==typeof a&&a.constructor===Object?t[o]=W(a):t[o]=a)}return t}function G(e,t){for(;null!==e;){const n=m(e,t);if(n){if(n.get)return j(n.get);if("function"==typeof n.value)return j(n.value)}e=f(e)}return function(){return null}}const Y=p(["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"]),q=p(["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"]),$=p(["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"]),X=p(["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"]),K=p(["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"]),V=p(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Z=p(["#text"]),J=p(["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"]),Q=p(["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"]),ee=p(["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"]),te=p(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),ne=d(/{{[\w\W]*|^[\w\W]*}}/g),re=d(/<%[\w\W]*|^[\w\W]*%>/g),oe=d(/\${[\w\W]*/g),ae=d(/^data-[\-\w.\u00B7-\uFFFF]+$/),ie=d(/^aria-[\-\w]+$/),le=d(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ce=d(/^(?:\w+script|data):/i),se=d(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ue=d(/^html$/i),fe=d(/^[a-z][.\w]*(-[.\w]+)+$/i),me=d(/<[/\w!]/g),pe=d(/<[/\w]/g),de=d(/<\/no(script|embed|frames)/i),he=d(/\/>/i),ye=function(){return"undefined"==typeof window?null:window},ge=function(e,t,n,r){return M(e,t)&&A(e[t])?H(r.base?W(r.base):{},e[t],r.transform):n};var be=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ye();const n=t=>e(t);if(n.version="3.4.11",n.removed=[],!t||!t.document||9!==t.document.nodeType||!t.Element)return n.isSupported=!1,n;let r=t.document;const o=r,a=o.currentScript;t.DocumentFragment;const i=t.HTMLTemplateElement,l=t.Node,s=t.Element,u=t.NodeFilter;void 0===t.NamedNodeMap&&(t.NamedNodeMap||t.MozNamedAttrMap),t.HTMLFormElement;const f=t.DOMParser,m=t.trustedTypes,y=s.prototype,g=G(y,"cloneNode"),b=G(y,"remove"),F=G(y,"nextSibling"),j=G(y,"childNodes"),B=G(y,"parentNode"),be=G(y,"shadowRoot"),Te=G(y,"attributes"),Se=l&&l.prototype?G(l.prototype,"nodeType"):null,_e=l&&l.prototype?G(l.prototype,"nodeName"):null;if("function"==typeof i){const e=r.createElement("template");e.content&&e.content.ownerDocument&&(r=e.content.ownerDocument)}let Ee,Ne,Ae="",ve=!1,Oe=0;const we=function(){if(Oe>0)throw U('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},xe=function(e){we(),Oe++;try{return Ee.createHTML(e)}finally{Oe--}},ke=r,De=ke.implementation,Re=ke.createNodeIterator,Ce=ke.createDocumentFragment,Ie=ke.getElementsByTagName,Le=o.importNode;let Me={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};n.isSupported="function"==typeof c&&"function"==typeof B&&De&&void 0!==De.createHTMLDocument;const Pe=ne,ze=re,Ue=oe,Fe=ae,je=ie,He=ce,Be=se,We=fe;let Ge=le,Ye=null;const qe=H({},[...Y,...q,...$,...K,...Z]);let $e=null;const Xe=H({},[...J,...Q,...ee,...te]);let Ke=Object.seal(h(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}})),Ve=null,Ze=null;const Je=Object.seal(h(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Qe=!0,et=!0,tt=!1,nt=!0,rt=!1,ot=!0,at=!1,it=!1,lt=null,ct=null,st=!1,ut=!1,ft=!1,mt=!1,pt=!0,dt=!1;const ht="user-content-";let yt=!0,gt=!1,bt={},Tt=null;const St=H({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]);let _t=null;const Et=H({},["audio","video","img","source","image","track"]);let Nt=null;const At=H({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),vt="http://www.w3.org/1998/Math/MathML",Ot="http://www.w3.org/2000/svg",wt="http://www.w3.org/1999/xhtml";let xt=wt,kt=!1,Dt=null;const Rt=H({},[vt,Ot,wt],O),Ct=p(["mi","mo","mn","ms","mtext"]);let It=H({},Ct);const Lt=p(["annotation-xml"]);let Mt=H({},Lt);const Pt=H({},["title","style","font","a","script"]);let zt=null;const Ut=["application/xhtml+xml","text/html"];let Ft=null,jt=null;const Ht=r.createElement("form"),Bt=function(e){return e instanceof RegExp||e instanceof Function},Wt=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(jt&&jt===e)return;e&&"object"==typeof e||(e={}),e=W(e),zt=-1===Ut.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE,Ft="application/xhtml+xml"===zt?O:v,Ye=ge(e,"ALLOWED_TAGS",qe,{transform:Ft}),$e=ge(e,"ALLOWED_ATTR",Xe,{transform:Ft}),Dt=ge(e,"ALLOWED_NAMESPACES",Rt,{transform:O}),Nt=ge(e,"ADD_URI_SAFE_ATTR",At,{transform:Ft,base:At}),_t=ge(e,"ADD_DATA_URI_TAGS",Et,{transform:Ft,base:Et}),Tt=ge(e,"FORBID_CONTENTS",St,{transform:Ft}),Ve=ge(e,"FORBID_TAGS",W({}),{transform:Ft}),Ze=ge(e,"FORBID_ATTR",W({}),{transform:Ft}),bt=!!M(e,"USE_PROFILES")&&(e.USE_PROFILES&&"object"==typeof e.USE_PROFILES?W(e.USE_PROFILES):e.USE_PROFILES),Qe=!1!==e.ALLOW_ARIA_ATTR,et=!1!==e.ALLOW_DATA_ATTR,tt=e.ALLOW_UNKNOWN_PROTOCOLS||!1,nt=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,rt=e.SAFE_FOR_TEMPLATES||!1,ot=!1!==e.SAFE_FOR_XML,at=e.WHOLE_DOCUMENT||!1,ut=e.RETURN_DOM||!1,ft=e.RETURN_DOM_FRAGMENT||!1,mt=e.RETURN_TRUSTED_TYPE||!1,st=e.FORCE_BODY||!1,pt=!1!==e.SANITIZE_DOM,dt=e.SANITIZE_NAMED_PROPS||!1,yt=!1!==e.KEEP_CONTENT,gt=e.IN_PLACE||!1,Ge=function(e){try{return z(e,""),!0}catch(e){return!1}}(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:le,xt="string"==typeof e.NAMESPACE?e.NAMESPACE:wt,It=M(e,"MATHML_TEXT_INTEGRATION_POINTS")&&e.MATHML_TEXT_INTEGRATION_POINTS&&"object"==typeof e.MATHML_TEXT_INTEGRATION_POINTS?W(e.MATHML_TEXT_INTEGRATION_POINTS):H({},Ct),Mt=M(e,"HTML_INTEGRATION_POINTS")&&e.HTML_INTEGRATION_POINTS&&"object"==typeof e.HTML_INTEGRATION_POINTS?W(e.HTML_INTEGRATION_POINTS):H({},Lt);const t=M(e,"CUSTOM_ELEMENT_HANDLING")&&e.CUSTOM_ELEMENT_HANDLING&&"object"==typeof e.CUSTOM_ELEMENT_HANDLING?W(e.CUSTOM_ELEMENT_HANDLING):h(null);if(Ke=h(null),M(t,"tagNameCheck")&&Bt(t.tagNameCheck)&&(Ke.tagNameCheck=t.tagNameCheck),M(t,"attributeNameCheck")&&Bt(t.attributeNameCheck)&&(Ke.attributeNameCheck=t.attributeNameCheck),M(t,"allowCustomizedBuiltInElements")&&"boolean"==typeof t.allowCustomizedBuiltInElements&&(Ke.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),d(Ke),rt&&(et=!1),ft&&(ut=!0),bt&&(Ye=H({},Z),$e=h(null),!0===bt.html&&(H(Ye,Y),H($e,J)),!0===bt.svg&&(H(Ye,q),H($e,Q),H($e,te)),!0===bt.svgFilters&&(H(Ye,$),H($e,Q),H($e,te)),!0===bt.mathMl&&(H(Ye,K),H($e,ee),H($e,te))),Je.tagCheck=null,Je.attributeCheck=null,M(e,"ADD_TAGS")&&("function"==typeof e.ADD_TAGS?Je.tagCheck=e.ADD_TAGS:A(e.ADD_TAGS)&&(Ye===qe&&(Ye=W(Ye)),H(Ye,e.ADD_TAGS,Ft))),M(e,"ADD_ATTR")&&("function"==typeof e.ADD_ATTR?Je.attributeCheck=e.ADD_ATTR:A(e.ADD_ATTR)&&($e===Xe&&($e=W($e)),H($e,e.ADD_ATTR,Ft))),M(e,"ADD_URI_SAFE_ATTR")&&A(e.ADD_URI_SAFE_ATTR)&&H(Nt,e.ADD_URI_SAFE_ATTR,Ft),M(e,"FORBID_CONTENTS")&&A(e.FORBID_CONTENTS)&&(Tt===St&&(Tt=W(Tt)),H(Tt,e.FORBID_CONTENTS,Ft)),M(e,"ADD_FORBID_CONTENTS")&&A(e.ADD_FORBID_CONTENTS)&&(Tt===St&&(Tt=W(Tt)),H(Tt,e.ADD_FORBID_CONTENTS,Ft)),yt&&(Ye["#text"]=!0),at&&H(Ye,["html","head","body"]),Ye.table&&(H(Ye,["tbody"]),delete Ve.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');const t=Ee;Ee=e.TRUSTED_TYPES_POLICY;try{Ae=xe("")}catch(e){throw Ee=t,e}}else null===e.TRUSTED_TYPES_POLICY?(Ee=void 0,Ae=""):(void 0===Ee&&(ve||(Ne=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let n=null;const r="data-tt-policy-suffix";t&&t.hasAttribute(r)&&(n=t.getAttribute(r));const o="dompurify"+(n?"#"+n:"");try{return e.createPolicy(o,{createHTML:e=>e,createScriptURL:e=>e})}catch(e){return console.warn("TrustedTypes policy "+o+" could not be created."),null}}(m,a),ve=!0),Ee=Ne),Ee&&"string"==typeof Ae&&(Ae=xe("")));p&&p(e),jt=e},Gt=H({},[...q,...$,...X]),Yt=H({},[...K,...V]),qt=function(e){E(n.removed,{element:e});try{B(e).removeChild(e)}catch(t){if(b(e),!B(e))throw U("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},$t=function(e){const t=j(e);if(t){const e=[];T(t,t=>{E(e,t)}),T(e,e=>{try{b(e)}catch(e){}})}const n=Te(e);if(n)for(let t=n.length-1;t>=0;--t){const r=n[t],o=r&&r.name;if("string"==typeof o)try{e.removeAttribute(o)}catch(e){}}},Xt=function(e,t){try{E(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){E(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e)if(ut||ft)try{qt(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},Kt=function(e){const t=Te(e);if(t)for(let n=t.length-1;n>=0;--n){const r=t[n],o=r&&r.name;if("string"==typeof o&&!$e[Ft(o)])try{e.removeAttribute(o)}catch(e){}}},Vt=function(e){let t=null,n=null;if(st)e="<remove></remove>"+e;else{const t=w(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===zt&&xt===wt&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const o=Ee?xe(e):e;if(xt===wt)try{t=(new f).parseFromString(o,zt)}catch(e){}if(!t||!t.documentElement){t=De.createDocument(xt,"template",null);try{t.documentElement.innerHTML=kt?Ae:o}catch(e){}}const a=t.body||t.documentElement;return e&&n&&a.insertBefore(r.createTextNode(n),a.childNodes[0]||null),xt===wt?Ie.call(t,at?"html":"body")[0]:at?t.documentElement:a},Zt=function(e){return Re.call(e.ownerDocument||e,e,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},Jt=function(e){return e=x(e,Pe," "),e=x(e,ze," "),x(e,Ue," ")},Qt=function(e){var t;e.normalize();const n=Re.call(e.ownerDocument||e,e,u.SHOW_TEXT|u.SHOW_COMMENT|u.SHOW_CDATA_SECTION|u.SHOW_PROCESSING_INSTRUCTION,null);let r=n.nextNode();for(;r;)r.data=Jt(r.data),r=n.nextNode();const o=null===(t=e.querySelectorAll)||void 0===t?void 0:t.call(e,"template");o&&T(o,e=>{tn(e.content)&&Qt(e.content)})},en=function(e){const t=_e?_e(e):null;return"string"==typeof t&&"form"===Ft(t)&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||e.attributes!==Te(e)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes||e.nodeType!==Se(e)||e.childNodes!==j(e))},tn=function(e){if(!Se||"object"!=typeof e||null===e)return!1;try{return 11===Se(e)}catch(e){return!1}},nn=function(e){if(!Se||"object"!=typeof e||null===e)return!1;try{return"number"==typeof Se(e)}catch(e){return!1}};function rn(e,t,r){0!==e.length&&T(e,e=>{e.call(n,t,r,jt)})}const on=function(e){if(rn(Me.beforeSanitizeElements,e,null),en(e))return qt(e),!0;const t=Ft(_e?_e(e):e.nodeName);if(rn(Me.uponSanitizeElement,e,{tagName:t,allowedTags:Ye}),function(e,t){return!!(ot&&e.hasChildNodes()&&!nn(e.firstElementChild)&&z(me,e.textContent)&&z(me,e.innerHTML))||!(!ot||e.namespaceURI!==wt||"style"!==t||!nn(e.firstElementChild))||7===e.nodeType||!(!ot||8!==e.nodeType||!z(pe,e.data))}(e,t))return qt(e),!0;if(Ve[t]||!(Je.tagCheck instanceof Function&&Je.tagCheck(t))&&!Ye[t])return function(e,t){if(!Ve[t]&&cn(t)){if(Ke.tagNameCheck instanceof RegExp&&z(Ke.tagNameCheck,t))return!1;if(Ke.tagNameCheck instanceof Function&&Ke.tagNameCheck(t))return!1}if(yt&&!Tt[t]){const t=B(e),n=j(e);if(n&&t)for(let r=n.length-1;r>=0;--r){const o=gt?n[r]:g(n[r],!0);t.insertBefore(o,F(e))}}return qt(e),!0}(e,t);if(1===(Se?Se(e):e.nodeType)&&!function(e){let t=B(e);t&&t.tagName||(t={namespaceURI:xt,tagName:"template"});const n=v(e.tagName),r=v(t.tagName);return!!Dt[e.namespaceURI]&&(e.namespaceURI===Ot?function(e,t,n){return t.namespaceURI===wt?"svg"===e:t.namespaceURI===vt?"svg"===e&&("annotation-xml"===n||It[n]):Boolean(Gt[e])}(n,t,r):e.namespaceURI===vt?function(e,t,n){return t.namespaceURI===wt?"math"===e:t.namespaceURI===Ot?"math"===e&&Mt[n]:Boolean(Yt[e])}(n,t,r):e.namespaceURI===wt?function(e,t,n){return!(t.namespaceURI===Ot&&!Mt[n])&&!(t.namespaceURI===vt&&!It[n])&&!Yt[e]&&(Pt[e]||!Gt[e])}(n,t,r):!("application/xhtml+xml"!==zt||!Dt[e.namespaceURI]))}(e))return qt(e),!0;if(("noscript"===t||"noembed"===t||"noframes"===t)&&z(de,e.innerHTML))return qt(e),!0;if(rt&&3===e.nodeType){const t=Jt(e.textContent);e.textContent!==t&&(E(n.removed,{element:e.cloneNode()}),e.textContent=t)}return rn(Me.afterSanitizeElements,e,null),!1},an=function(e,t,n){if(Ze[t])return!1;if(pt&&("id"===t||"name"===t)&&(n in r||n in Ht))return!1;const o=$e[t]||Je.attributeCheck instanceof Function&&Je.attributeCheck(t,e);if(et&&z(Fe,t));else if(Qe&&z(je,t));else if(o){if(Nt[t]);else if(z(Ge,x(n,Be,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==k(n,"data:")||!_t[e])if(tt&&!z(He,x(n,Be,"")));else if(n)return!1}else if(!(cn(e)&&(Ke.tagNameCheck instanceof RegExp&&z(Ke.tagNameCheck,e)||Ke.tagNameCheck instanceof Function&&Ke.tagNameCheck(e))&&(Ke.attributeNameCheck instanceof RegExp&&z(Ke.attributeNameCheck,t)||Ke.attributeNameCheck instanceof Function&&Ke.attributeNameCheck(t,e))||"is"===t&&Ke.allowCustomizedBuiltInElements&&(Ke.tagNameCheck instanceof RegExp&&z(Ke.tagNameCheck,n)||Ke.tagNameCheck instanceof Function&&Ke.tagNameCheck(n))))return!1;return!0},ln=H({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),cn=function(e){return!ln[v(e)]&&z(We,e)},sn=function(e,t,n,r){if(Ee&&"object"==typeof m&&"function"==typeof m.getAttributeType&&!n)switch(m.getAttributeType(e,t)){case"TrustedHTML":return xe(r);case"TrustedScriptURL":return function(e){we(),Oe++;try{return Ee.createScriptURL(e)}finally{Oe--}}(r)}return r},un=function(e,t,r,o){try{r?e.setAttributeNS(r,t,o):e.setAttribute(t,o),en(e)?qt(e):_(n.removed)}catch(n){Xt(t,e)}},fn=function(e){rn(Me.beforeSanitizeAttributes,e,null);const t=e.attributes;if(!t||en(e))return;const n={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:$e,forceKeepAttr:void 0};let r=t.length;const o=Ft(e.nodeName);for(;r--;){const a=t[r],i=a.name,l=a.namespaceURI,c=a.value,s=Ft(i),u=c;let f="value"===i?u:D(u);n.attrName=s,n.attrValue=f,n.keepAttr=!0,n.forceKeepAttr=void 0,rn(Me.uponSanitizeAttribute,e,n),f=n.attrValue,!dt||"id"!==s&&"name"!==s||0===k(f,ht)||(Xt(i,e),f=ht+f),ot&&z(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)||"attributename"===s&&w(f,"href")?Xt(i,e):n.forceKeepAttr||(!n.keepAttr||!nt&&z(he,f)?Xt(i,e):(rt&&(f=Jt(f)),an(o,s,f)?(f=sn(o,s,l,f),f!==u&&un(e,i,l,f)):Xt(i,e)))}rn(Me.afterSanitizeAttributes,e,null)},mn=function(e){let t=null;const n=Zt(e);for(rn(Me.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if(rn(Me.uponSanitizeShadowNode,t,null),on(t),fn(t),tn(t.content)&&mn(t.content),1===(Se?Se(t):t.nodeType)){const e=be(t);tn(e)&&(pn(e),mn(e))}rn(Me.afterSanitizeShadowDOM,e,null)},pn=function(e){const t=[{node:e,shadow:null}];for(;t.length>0;){const e=t.pop();if(e.shadow){mn(e.shadow);continue}const n=e.node,r=1===(Se?Se(n):n.nodeType),o=j(n);if(o)for(let e=o.length-1;e>=0;--e)t.push({node:o[e],shadow:null});if(r){const e=_e?_e(n):null;if("string"==typeof e&&"template"===Ft(e)){const e=n.content;tn(e)&&t.push({node:e,shadow:null})}}if(r){const e=be(n);tn(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return n.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null,a=null,i=null,l=null;if(kt=!e,kt&&(e="\x3c!--\x3e"),"string"!=typeof e&&!nn(e)&&"string"!=typeof(e=function(e){switch(typeof e){case"string":return e;case"number":return R(e);case"boolean":return C(e);case"bigint":return I?I(e):"0";case"symbol":return L?L(e):"Symbol()";case"undefined":default:return P(e);case"function":case"object":{if(null===e)return P(e);const t=e,n=G(t,"toString");if("function"==typeof n){const e=n(t);return"string"==typeof e?e:P(e)}return P(e)}}}(e)))throw U("dirty is not a string, aborting");if(!n.isSupported)return e;it?(Ye=lt,$e=ct):Wt(t),(Me.uponSanitizeElement.length>0||Me.uponSanitizeAttribute.length>0)&&(Ye=W(Ye)),Me.uponSanitizeAttribute.length>0&&($e=W($e)),n.removed=[];const c=gt&&"string"!=typeof e&&nn(e);if(c){const t=_e?_e(e):e.nodeName;if("string"==typeof t){const e=Ft(t);if(!Ye[e]||Ve[e])throw U("root node is forbidden and cannot be sanitized in-place")}if(en(e))throw U("root node is clobbered and cannot be sanitized in-place");try{pn(e)}catch(t){throw $t(e),t}}else if(nn(e))r=Vt("\x3c!----\x3e"),a=r.ownerDocument.importNode(e,!0),1===a.nodeType&&"BODY"===a.nodeName||"HTML"===a.nodeName?r=a:r.appendChild(a),pn(a);else{if(!ut&&!rt&&!at&&-1===e.indexOf("<"))return Ee&&mt?xe(e):e;if(r=Vt(e),!r)return ut?null:mt?Ae:""}r&&st&&qt(r.firstChild);const s=Zt(c?e:r);try{for(;i=s.nextNode();)on(i),fn(i),tn(i.content)&&mn(i.content)}catch(t){throw c&&$t(e),t}if(c)return T(n.removed,e=>{e.element&&function(e){const t=[e];for(;t.length>0;){const e=t.pop();1===(Se?Se(e):e.nodeType)&&Kt(e);const n=j(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}}(e.element)}),rt&&Qt(e),e;if(ut){if(rt&&Qt(r),ft)for(l=Ce.call(r.ownerDocument);r.firstChild;)l.appendChild(r.firstChild);else l=r;return($e.shadowroot||$e.shadowrootmode)&&(l=Le.call(o,l,!0)),l}let u=at?r.outerHTML:r.innerHTML;return at&&Ye["!doctype"]&&r.ownerDocument&&r.ownerDocument.doctype&&r.ownerDocument.doctype.name&&z(ue,r.ownerDocument.doctype.name)&&(u="<!DOCTYPE "+r.ownerDocument.doctype.name+">\n"+u),rt&&(u=Jt(u)),Ee&&mt?xe(u):u},n.setConfig=function(){Wt(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),it=!0,lt=Ye,ct=$e},n.clearConfig=function(){jt=null,it=!1,lt=null,ct=null,Ee=Ne,Ae=""},n.isValidAttribute=function(e,t,n){jt||Wt({});const r=Ft(e),o=Ft(t);return an(r,o,n)},n.addHook=function(e,t){"function"==typeof t&&M(Me,e)&&E(Me[e],t)},n.removeHook=function(e,t){if(M(Me,e)){if(void 0!==t){const n=S(Me[e],t);return-1===n?void 0:N(Me[e],n,1)[0]}return _(Me[e])}},n.removeHooks=function(e){M(Me,e)&&(Me[e]=[])},n.removeAllHooks=function(){Me={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},n}(),Te=r(6145),Se=r(4848);const _e=(...e)=>e.filter(Boolean).length>0?e.filter(Boolean).join(" "):null;function Ee({data:e,variant:t="primary",className:n}){const r=t&&"primary"!==t?`mg-card--${t}`:null;return(0,Se.jsx)(Se.Fragment,{children:e.map((e,t)=>(0,Se.jsxs)("article",{className:_e("mg-card","mg-card__vc",r,n),children:[e.imgback&&(0,Se.jsx)("div",{className:"mg-card__visual",children:(0,Se.jsx)("img",{src:e.imgback,alt:e.imgalt,className:"mg-card__image"})}),(0,Se.jsxs)("div",{className:"mg-card__content",children:[(e.label1||e.label2)&&(0,Se.jsxs)("div",{className:"mg-card__meta",children:[e.link&&e.label1&&(0,Se.jsx)("a",{href:e.link,className:"mg-card__label mg-card__label--active",children:e.label1}),e.link&&e.label2&&(0,Se.jsx)("a",{href:e.link,className:"mg-card__label mg-card__label--active",children:e.label2})]}),(0,Se.jsx)("header",{className:"mg-card__title",children:(0,Se.jsx)("a",{href:e.link,children:e.title?.trim()})}),e.summaryText&&(0,Se.jsx)("p",{className:"mg-card__summary",dangerouslySetInnerHTML:{__html:be.sanitize(e.summaryText)}}),e.button&&(0,Se.jsx)(Te.F,{type:"Primary",label:e.button,href:e.link})]})]},t))})}Ee.propTypes={data:a().array.isRequired,variant:a().oneOf(["primary","secondary","tertiary","quaternary"]),className:a().string};export{Ee as VerticalCard};
|
|
6
|
+
import*as e from"react";var t={6145(e,t,n){n.d(t,{F:()=>i}),n(1649);var r=n(5556),o=n.n(r),a=n(5446);function i({label:e,Type:t="Primary",State:n="Default",...r}){const o="Disabled"===n,i=["mg-button","mg-button-"+("Secondary"===t?"secondary":"primary"),o&&"disabled"].filter(Boolean).join(" ");return(0,a.jsxDEV)("a",{className:i,...o?{"aria-disabled":"true"}:{href:"#"},...r,children:e},void 0,!1)}i.propTypes={label:o().string.isRequired,Type:o().oneOf(["Primary","Secondary"]),State:o().oneOf(["Default","Disabled"])}},2694(e,t,n){var r=n(6925);function o(){}function a(){}a.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,a,i){if(i!==r){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:a,resetWarningCache:o};return n.PropTypes=n,n}},5556(e,t,n){e.exports=n(2694)()},6925(e){e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},1772(e,t){var n=Symbol.for("react.fragment");t.Fragment=n,t.jsxDEV=void 0},5446(e,t,n){e.exports=n(1772)},1649(e,t,n){e.exports=(()=>{const e={};return n.d(e,{}),e})()}};const n={};function r(e){const o=n[e];if(void 0!==o)return o.exports;const a=n[e]={exports:{}};return t[e](a,a.exports,r),a.exports}r.n=e=>{const t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{if(Array.isArray(t))for(var n=0;n<t.length;){var o=t[n++],a=t[n++];r.o(e,o)?0===a&&n++:0===a?Object.defineProperty(e,o,{enumerable:!0,value:t[n++]}):Object.defineProperty(e,o,{enumerable:!0,get:a})}else for(var o in t)r.o(t,o)&&!r.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r(1649);var o=r(5556),a=r.n(o);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],c=!0,s=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(c=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(s)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const c=Object.entries,s=Object.setPrototypeOf,u=Object.isFrozen,f=Object.getPrototypeOf,m=Object.getOwnPropertyDescriptor;let p=Object.freeze,d=Object.seal,h=Object.create,y="undefined"!=typeof Reflect&&Reflect,g=y.apply,b=y.construct;p||(p=function(e){return e}),d||(d=function(e){return e}),g||(g=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return e.apply(t,r)}),b||(b=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new e(...n)});const T=F(Array.prototype.forEach),E=F(Array.prototype.lastIndexOf),S=F(Array.prototype.pop),_=F(Array.prototype.push),N=F(Array.prototype.splice),A=Array.isArray,v=F(String.prototype.toLowerCase),O=F(String.prototype.toString),w=F(String.prototype.match),D=F(String.prototype.replace),x=F(String.prototype.indexOf),R=F(String.prototype.trim),k=F(Number.prototype.toString),C=F(Boolean.prototype.toString),I="undefined"==typeof BigInt?null:F(BigInt.prototype.toString),L="undefined"==typeof Symbol?null:F(Symbol.prototype.toString),M=F(Object.prototype.hasOwnProperty),P=F(Object.prototype.toString),z=F(RegExp.prototype.test),U=(j=TypeError,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return b(j,t)});var j;function F(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return g(e,t,r)}}function H(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:v;if(s&&s(e,null),!A(t))return e;let r=t.length;for(;r--;){let o=t[r];if("string"==typeof o){const e=n(o);e!==o&&(u(t)||(t[r]=e),o=e)}e[o]=!0}return e}function B(e){for(let t=0;t<e.length;t++)M(e,t)||(e[t]=null);return e}function W(e){const t=h(null);for(const r of c(e)){var n=l(r,2);const o=n[0],a=n[1];M(e,o)&&(A(a)?t[o]=B(a):a&&"object"==typeof a&&a.constructor===Object?t[o]=W(a):t[o]=a)}return t}function G(e,t){for(;null!==e;){const n=m(e,t);if(n){if(n.get)return F(n.get);if("function"==typeof n.value)return F(n.value)}e=f(e)}return function(){return null}}const Y=p(["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"]),V=p(["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"]),q=p(["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"]),X=p(["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"]),$=p(["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"]),K=p(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Z=p(["#text"]),J=p(["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"]),Q=p(["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","dominant-baseline","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-orientation","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"]),ee=p(["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"]),te=p(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),ne=d(/{{[\w\W]*|^[\w\W]*}}/g),re=d(/<%[\w\W]*|^[\w\W]*%>/g),oe=d(/\${[\w\W]*/g),ae=d(/^data-[\-\w.\u00B7-\uFFFF]+$/),ie=d(/^aria-[\-\w]+$/),le=d(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ce=d(/^(?:\w+script|data):/i),se=d(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ue=d(/^html$/i),fe=d(/^[a-z][.\w]*(-[.\w]+)+$/i),me=d(/<[/\w!]/g),pe=d(/<[/\w]/g),de=d(/<\/no(script|embed|frames)/i),he=d(/\/>/i),ye=function(){return"undefined"==typeof window?null:window},ge=function(e,t,n,r){return M(e,t)&&A(e[t])?H(r.base?W(r.base):{},e[t],r.transform):n};var be=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ye();const n=t=>e(t);if(n.version="3.4.12",n.removed=[],!t||!t.document||9!==t.document.nodeType||!t.Element)return n.isSupported=!1,n;let r=t.document;const o=r,a=o.currentScript;t.DocumentFragment;const i=t.HTMLTemplateElement,l=t.Node,s=t.Element,u=t.NodeFilter;void 0===t.NamedNodeMap&&(t.NamedNodeMap||t.MozNamedAttrMap),t.HTMLFormElement;const f=t.DOMParser,m=t.trustedTypes,y=s.prototype,g=G(y,"cloneNode"),b=G(y,"remove"),j=G(y,"nextSibling"),F=G(y,"childNodes"),B=G(y,"parentNode"),be=G(y,"shadowRoot"),Te=G(y,"attributes"),Ee=l&&l.prototype?G(l.prototype,"nodeType"):null,Se=l&&l.prototype?G(l.prototype,"nodeName"):null;if("function"==typeof i){const e=r.createElement("template");e.content&&e.content.ownerDocument&&(r=e.content.ownerDocument)}let _e,Ne,Ae="",ve=!1,Oe=0;const we=function(){if(Oe>0)throw U('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},De=function(e){we(),Oe++;try{return _e.createHTML(e)}finally{Oe--}},xe=r,Re=xe.implementation,ke=xe.createNodeIterator,Ce=xe.createDocumentFragment,Ie=xe.getElementsByTagName,Le=o.importNode;let Me={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};n.isSupported="function"==typeof c&&"function"==typeof B&&Re&&void 0!==Re.createHTMLDocument;const Pe=ne,ze=re,Ue=oe,je=ae,Fe=ie,He=ce,Be=se,We=fe;let Ge=le,Ye=null;const Ve=H({},[...Y,...V,...q,...$,...Z]);let qe=null;const Xe=H({},[...J,...Q,...ee,...te]);let $e=Object.seal(h(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}})),Ke=null,Ze=null;const Je=Object.seal(h(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Qe=!0,et=!0,tt=!1,nt=!0,rt=!1,ot=!0,at=!1,it=!1,lt=null,ct=null,st=!1,ut=!1,ft=!1,mt=!1,pt=!0,dt=!1;const ht="user-content-";let yt=!0,gt=!1,bt={},Tt=null;const Et=H({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]);let St=null;const _t=H({},["audio","video","img","source","image","track"]);let Nt=null;const At=H({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),vt="http://www.w3.org/1998/Math/MathML",Ot="http://www.w3.org/2000/svg",wt="http://www.w3.org/1999/xhtml";let Dt=wt,xt=!1,Rt=null;const kt=H({},[vt,Ot,wt],O),Ct=p(["mi","mo","mn","ms","mtext"]);let It=H({},Ct);const Lt=p(["annotation-xml"]);let Mt=H({},Lt);const Pt=H({},["title","style","font","a","script"]);let zt=null;const Ut=["application/xhtml+xml","text/html"];let jt=null,Ft=null;const Ht=r.createElement("form"),Bt=function(e){return e instanceof RegExp||e instanceof Function},Wt=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(Ft&&Ft===e)return;e&&"object"==typeof e||(e={}),e=W(e),zt=-1===Ut.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE,jt="application/xhtml+xml"===zt?O:v,Ye=ge(e,"ALLOWED_TAGS",Ve,{transform:jt}),qe=ge(e,"ALLOWED_ATTR",Xe,{transform:jt}),Rt=ge(e,"ALLOWED_NAMESPACES",kt,{transform:O}),Nt=ge(e,"ADD_URI_SAFE_ATTR",At,{transform:jt,base:At}),St=ge(e,"ADD_DATA_URI_TAGS",_t,{transform:jt,base:_t}),Tt=ge(e,"FORBID_CONTENTS",Et,{transform:jt}),Ke=ge(e,"FORBID_TAGS",W({}),{transform:jt}),Ze=ge(e,"FORBID_ATTR",W({}),{transform:jt}),bt=!!M(e,"USE_PROFILES")&&(e.USE_PROFILES&&"object"==typeof e.USE_PROFILES?W(e.USE_PROFILES):e.USE_PROFILES),Qe=!1!==e.ALLOW_ARIA_ATTR,et=!1!==e.ALLOW_DATA_ATTR,tt=e.ALLOW_UNKNOWN_PROTOCOLS||!1,nt=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,rt=e.SAFE_FOR_TEMPLATES||!1,ot=!1!==e.SAFE_FOR_XML,at=e.WHOLE_DOCUMENT||!1,ut=e.RETURN_DOM||!1,ft=e.RETURN_DOM_FRAGMENT||!1,mt=e.RETURN_TRUSTED_TYPE||!1,st=e.FORCE_BODY||!1,pt=!1!==e.SANITIZE_DOM,dt=e.SANITIZE_NAMED_PROPS||!1,yt=!1!==e.KEEP_CONTENT,gt=e.IN_PLACE||!1,Ge=function(e){try{return z(e,""),!0}catch(e){return!1}}(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:le,Dt="string"==typeof e.NAMESPACE?e.NAMESPACE:wt,It=M(e,"MATHML_TEXT_INTEGRATION_POINTS")&&e.MATHML_TEXT_INTEGRATION_POINTS&&"object"==typeof e.MATHML_TEXT_INTEGRATION_POINTS?W(e.MATHML_TEXT_INTEGRATION_POINTS):H({},Ct),Mt=M(e,"HTML_INTEGRATION_POINTS")&&e.HTML_INTEGRATION_POINTS&&"object"==typeof e.HTML_INTEGRATION_POINTS?W(e.HTML_INTEGRATION_POINTS):H({},Lt);const t=M(e,"CUSTOM_ELEMENT_HANDLING")&&e.CUSTOM_ELEMENT_HANDLING&&"object"==typeof e.CUSTOM_ELEMENT_HANDLING?W(e.CUSTOM_ELEMENT_HANDLING):h(null);if($e=h(null),M(t,"tagNameCheck")&&Bt(t.tagNameCheck)&&($e.tagNameCheck=t.tagNameCheck),M(t,"attributeNameCheck")&&Bt(t.attributeNameCheck)&&($e.attributeNameCheck=t.attributeNameCheck),M(t,"allowCustomizedBuiltInElements")&&"boolean"==typeof t.allowCustomizedBuiltInElements&&($e.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),d($e),rt&&(et=!1),ft&&(ut=!0),bt&&(Ye=H({},Z),qe=h(null),!0===bt.html&&(H(Ye,Y),H(qe,J)),!0===bt.svg&&(H(Ye,V),H(qe,Q),H(qe,te)),!0===bt.svgFilters&&(H(Ye,q),H(qe,Q),H(qe,te)),!0===bt.mathMl&&(H(Ye,$),H(qe,ee),H(qe,te))),Je.tagCheck=null,Je.attributeCheck=null,M(e,"ADD_TAGS")&&("function"==typeof e.ADD_TAGS?Je.tagCheck=e.ADD_TAGS:A(e.ADD_TAGS)&&(Ye===Ve&&(Ye=W(Ye)),H(Ye,e.ADD_TAGS,jt))),M(e,"ADD_ATTR")&&("function"==typeof e.ADD_ATTR?Je.attributeCheck=e.ADD_ATTR:A(e.ADD_ATTR)&&(qe===Xe&&(qe=W(qe)),H(qe,e.ADD_ATTR,jt))),M(e,"ADD_URI_SAFE_ATTR")&&A(e.ADD_URI_SAFE_ATTR)&&H(Nt,e.ADD_URI_SAFE_ATTR,jt),M(e,"FORBID_CONTENTS")&&A(e.FORBID_CONTENTS)&&(Tt===Et&&(Tt=W(Tt)),H(Tt,e.FORBID_CONTENTS,jt)),M(e,"ADD_FORBID_CONTENTS")&&A(e.ADD_FORBID_CONTENTS)&&(Tt===Et&&(Tt=W(Tt)),H(Tt,e.ADD_FORBID_CONTENTS,jt)),yt&&(Ye["#text"]=!0),at&&H(Ye,["html","head","body"]),Ye.table&&(H(Ye,["tbody"]),delete Ke.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');const t=_e;_e=e.TRUSTED_TYPES_POLICY;try{Ae=De("")}catch(e){throw _e=t,e}}else null===e.TRUSTED_TYPES_POLICY?(_e=void 0,Ae=""):(void 0===_e&&(ve||(Ne=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let n=null;const r="data-tt-policy-suffix";t&&t.hasAttribute(r)&&(n=t.getAttribute(r));const o="dompurify"+(n?"#"+n:"");try{return e.createPolicy(o,{createHTML:e=>e,createScriptURL:e=>e})}catch(e){return console.warn("TrustedTypes policy "+o+" could not be created."),null}}(m,a),ve=!0),_e=Ne),_e&&"string"==typeof Ae&&(Ae=De("")));p&&p(e),Ft=e},Gt=H({},[...V,...q,...X]),Yt=H({},[...$,...K]),Vt=function(e){_(n.removed,{element:e});try{B(e).removeChild(e)}catch(t){if(b(e),!B(e))throw U("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},qt=function(e){Kt(e);const t=F(e);if(t){const e=[];T(t,t=>{_(e,t)}),T(e,e=>{try{b(e)}catch(e){}})}const n=Te(e);if(n)for(let t=n.length-1;t>=0;--t){const r=n[t],o=r&&r.name;if("string"==typeof o)try{e.removeAttribute(o)}catch(e){}}},Xt=function(e,t){try{_(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){_(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e)if(ut||ft)try{Vt(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},$t=function(e){const t=Te(e);if(t)for(let n=t.length-1;n>=0;--n){const r=t[n],o=r&&r.name;if("string"==typeof o&&!qe[jt(o)])try{e.removeAttribute(o)}catch(e){}}},Kt=function(e){const t=[e];for(;t.length>0;){const e=t.pop();1===(Ee?Ee(e):e.nodeType)&&$t(e);const n=F(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}},Zt=function(e){let t=null,n=null;if(st)e="<remove></remove>"+e;else{const t=w(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===zt&&Dt===wt&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const o=_e?De(e):e;if(Dt===wt)try{t=(new f).parseFromString(o,zt)}catch(e){}if(!t||!t.documentElement){t=Re.createDocument(Dt,"template",null);try{t.documentElement.innerHTML=xt?Ae:o}catch(e){}}const a=t.body||t.documentElement;return e&&n&&a.insertBefore(r.createTextNode(n),a.childNodes[0]||null),Dt===wt?Ie.call(t,at?"html":"body")[0]:at?t.documentElement:a},Jt=function(e){return ke.call(e.ownerDocument||e,e,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},Qt=function(e){return e=D(e,Pe," "),e=D(e,ze," "),D(e,Ue," ")},en=function(e){var t;e.normalize();const n=ke.call(e.ownerDocument||e,e,u.SHOW_TEXT|u.SHOW_COMMENT|u.SHOW_CDATA_SECTION|u.SHOW_PROCESSING_INSTRUCTION,null);let r=n.nextNode();for(;r;)r.data=Qt(r.data),r=n.nextNode();const o=null===(t=e.querySelectorAll)||void 0===t?void 0:t.call(e,"template");o&&T(o,e=>{nn(e.content)&&en(e.content)})},tn=function(e){const t=Se?Se(e):null;return"string"==typeof t&&"form"===jt(t)&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||e.attributes!==Te(e)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes||e.nodeType!==Ee(e)||e.childNodes!==F(e))},nn=function(e){if(!Ee||"object"!=typeof e||null===e)return!1;try{return 11===Ee(e)}catch(e){return!1}},rn=function(e){if(!Ee||"object"!=typeof e||null===e)return!1;try{return"number"==typeof Ee(e)}catch(e){return!1}};function on(e,t,r){0!==e.length&&T(e,e=>{e.call(n,t,r,Ft)})}const an=function(e,t){if(on(Me.beforeSanitizeElements,e,null),e!==t&&null===B(e))return!0;if(tn(e))return Vt(e),!0;const r=jt(Se?Se(e):e.nodeName);if(on(Me.uponSanitizeElement,e,{tagName:r,allowedTags:Ye}),e!==t&&null===B(e))return!0;if(function(e,t){return!!(ot&&e.hasChildNodes()&&!rn(e.firstElementChild)&&z(me,e.textContent)&&z(me,e.innerHTML))||!(!ot||e.namespaceURI!==wt||"style"!==t||!rn(e.firstElementChild))||7===e.nodeType||!(!ot||8!==e.nodeType||!z(pe,e.data))}(e,r))return Vt(e),!0;if(Ke[r]||!(Je.tagCheck instanceof Function&&Je.tagCheck(r))&&!Ye[r]){const t=function(e,t){if(!Ke[t]&&sn(t)){if($e.tagNameCheck instanceof RegExp&&z($e.tagNameCheck,t))return!1;if($e.tagNameCheck instanceof Function&&$e.tagNameCheck(t))return!1}if(yt&&!Tt[t]){const t=B(e),n=F(e);if(n&&t)for(let r=n.length-1;r>=0;--r){const o=gt?n[r]:g(n[r],!0);t.insertBefore(o,j(e))}}return Vt(e),!0}(e,r);return!1===t&&on(Me.afterSanitizeElements,e,null),t}if(1===(Ee?Ee(e):e.nodeType)&&!function(e){let t=B(e);t&&t.tagName||(t={namespaceURI:Dt,tagName:"template"});const n=v(e.tagName),r=v(t.tagName);return!!Rt[e.namespaceURI]&&(e.namespaceURI===Ot?function(e,t,n){return t.namespaceURI===wt?"svg"===e:t.namespaceURI===vt?"svg"===e&&("annotation-xml"===n||It[n]):Boolean(Gt[e])}(n,t,r):e.namespaceURI===vt?function(e,t,n){return t.namespaceURI===wt?"math"===e:t.namespaceURI===Ot?"math"===e&&Mt[n]:Boolean(Yt[e])}(n,t,r):e.namespaceURI===wt?function(e,t,n){return!(t.namespaceURI===Ot&&!Mt[n])&&!(t.namespaceURI===vt&&!It[n])&&!Yt[e]&&(Pt[e]||!Gt[e])}(n,t,r):!("application/xhtml+xml"!==zt||!Rt[e.namespaceURI]))}(e))return Vt(e),!0;if(("noscript"===r||"noembed"===r||"noframes"===r)&&z(de,e.innerHTML))return Vt(e),!0;if(rt&&3===e.nodeType){const t=Qt(e.textContent);e.textContent!==t&&(_(n.removed,{element:e.cloneNode()}),e.textContent=t)}return on(Me.afterSanitizeElements,e,null),!1},ln=function(e,t,n){if(Ze[t])return!1;if(ot&&"patchsrc"===t)return!1;if(ot&&"for"===t&&"label"!==e&&"output"!==e)return!1;if(pt&&("id"===t||"name"===t)&&(n in r||n in Ht))return!1;const o=qe[t]||Je.attributeCheck instanceof Function&&Je.attributeCheck(t,e);if(et&&z(je,t));else if(Qe&&z(Fe,t));else if(o){if(Nt[t]);else if(z(Ge,D(n,Be,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==x(n,"data:")||!St[e])if(tt&&!z(He,D(n,Be,"")));else if(n)return!1}else if(!(sn(e)&&($e.tagNameCheck instanceof RegExp&&z($e.tagNameCheck,e)||$e.tagNameCheck instanceof Function&&$e.tagNameCheck(e))&&($e.attributeNameCheck instanceof RegExp&&z($e.attributeNameCheck,t)||$e.attributeNameCheck instanceof Function&&$e.attributeNameCheck(t,e))||"is"===t&&$e.allowCustomizedBuiltInElements&&($e.tagNameCheck instanceof RegExp&&z($e.tagNameCheck,n)||$e.tagNameCheck instanceof Function&&$e.tagNameCheck(n))))return!1;return!0},cn=H({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),sn=function(e){return!cn[v(e)]&&z(We,e)},un=function(e,t,n,r){if(_e&&"object"==typeof m&&"function"==typeof m.getAttributeType&&!n)switch(m.getAttributeType(e,t)){case"TrustedHTML":return De(r);case"TrustedScriptURL":return function(e){we(),Oe++;try{return _e.createScriptURL(e)}finally{Oe--}}(r)}return r},fn=function(e,t,r,o){try{r?e.setAttributeNS(r,t,o):e.setAttribute(t,o),tn(e)?Vt(e):S(n.removed)}catch(n){Xt(t,e)}},mn=function(e){on(Me.beforeSanitizeAttributes,e,null);const t=e.attributes;if(!t||tn(e))return;const n={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:qe,forceKeepAttr:void 0};let r=t.length;const o=jt(e.nodeName);for(;r--;){const a=t[r],i=a.name,l=a.namespaceURI,c=a.value,s=jt(i),u=c;let f="value"===i?u:R(u);n.attrName=s,n.attrValue=f,n.keepAttr=!0,n.forceKeepAttr=void 0,on(Me.uponSanitizeAttribute,e,n),f=n.attrValue,!dt||"id"!==s&&"name"!==s||0===x(f,ht)||(Xt(i,e),f=ht+f),ot&&z(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)||"attributename"===s&&w(f,"href")?Xt(i,e):n.forceKeepAttr||(!n.keepAttr||!nt&&z(he,f)?Xt(i,e):(rt&&(f=Qt(f)),ln(o,s,f)?(f=un(o,s,l,f),f!==u&&fn(e,i,l,f)):Xt(i,e)))}on(Me.afterSanitizeAttributes,e,null)},pn=function(e){let t=null;const n=Jt(e);for(on(Me.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if(on(Me.uponSanitizeShadowNode,t,null),an(t,e),mn(t),nn(t.content)&&pn(t.content),1===(Ee?Ee(t):t.nodeType)){const e=be(t);nn(e)&&(dn(e),pn(e))}on(Me.afterSanitizeShadowDOM,e,null)},dn=function(e){const t=[{node:e,shadow:null}];for(;t.length>0;){const e=t.pop();if(e.shadow){pn(e.shadow);continue}const n=e.node,r=1===(Ee?Ee(n):n.nodeType),o=F(n);if(o)for(let e=o.length-1;e>=0;--e)t.push({node:o[e],shadow:null});if(r){const e=Se?Se(n):null;if("string"==typeof e&&"template"===jt(e)){const e=n.content;nn(e)&&t.push({node:e,shadow:null})}}if(r){const e=be(n);nn(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return n.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null,a=null,i=null,l=null;if(xt=!e,xt&&(e="\x3c!--\x3e"),"string"!=typeof e&&!rn(e)&&"string"!=typeof(e=function(e){switch(typeof e){case"string":return e;case"number":return k(e);case"boolean":return C(e);case"bigint":return I?I(e):"0";case"symbol":return L?L(e):"Symbol()";case"undefined":default:return P(e);case"function":case"object":{if(null===e)return P(e);const t=e,n=G(t,"toString");if("function"==typeof n){const e=n(t);return"string"==typeof e?e:P(e)}return P(e)}}}(e)))throw U("dirty is not a string, aborting");if(!n.isSupported)return e;it?(Ye=lt,qe=ct):Wt(t),(Me.uponSanitizeElement.length>0||Me.uponSanitizeAttribute.length>0)&&(Ye=W(Ye)),Me.uponSanitizeAttribute.length>0&&(qe=W(qe)),n.removed=[];const c=gt&&"string"!=typeof e&&rn(e);if(c){!function(e){if(!ot)return;const t=[e];for(;t.length>0;){const e=t.pop(),n=Ee?Ee(e):e.nodeType;if(7===n||8===n&&z(pe,e.data)){try{b(e)}catch(e){}continue}if(1===n){const t=e,n=jt(Se?Se(e):e.nodeName);try{t.hasAttribute&&t.hasAttribute("patchsrc")&&t.removeAttribute("patchsrc"),t.hasAttribute&&t.hasAttribute("for")&&"label"!==n&&"output"!==n&&t.removeAttribute("for")}catch(e){}}const r=F(e);if(r)for(let e=r.length-1;e>=0;--e)t.push(r[e])}}(e);const t=Se?Se(e):e.nodeName;if("string"==typeof t){const n=jt(t);if(!Ye[n]||Ke[n])throw qt(e),U("root node is forbidden and cannot be sanitized in-place")}if(tn(e))throw qt(e),U("root node is clobbered and cannot be sanitized in-place");try{dn(e)}catch(t){throw qt(e),t}}else if(rn(e))r=Zt("\x3c!----\x3e"),a=r.ownerDocument.importNode(e,!0),1===a.nodeType&&"BODY"===a.nodeName||"HTML"===a.nodeName?r=a:r.appendChild(a),dn(a);else{if(!ut&&!rt&&!at&&-1===e.indexOf("<"))return _e&&mt?De(e):e;if(r=Zt(e),!r)return ut?null:mt?Ae:""}r&&st&&Vt(r.firstChild);const s=c?e:r,u=Jt(s);try{for(;i=u.nextNode();)an(i,s),mn(i),nn(i.content)&&pn(i.content)}catch(t){throw c&&(qt(e),T(n.removed,e=>{e.element&&Kt(e.element)})),t}if(c)return T(n.removed,e=>{e.element&&Kt(e.element)}),rt&&en(e),e;if(ut){if(rt&&en(r),ft)for(l=Ce.call(r.ownerDocument);r.firstChild;)l.appendChild(r.firstChild);else l=r;return(qe.shadowroot||qe.shadowrootmode)&&(l=Le.call(o,l,!0)),l}let f=at?r.outerHTML:r.innerHTML;return at&&Ye["!doctype"]&&r.ownerDocument&&r.ownerDocument.doctype&&r.ownerDocument.doctype.name&&z(ue,r.ownerDocument.doctype.name)&&(f="<!DOCTYPE "+r.ownerDocument.doctype.name+">\n"+f),rt&&(f=Qt(f)),_e&&mt?De(f):f},n.setConfig=function(){Wt(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),it=!0,lt=Ye,ct=qe},n.clearConfig=function(){Ft=null,it=!1,lt=null,ct=null,_e=Ne,Ae=""},n.isValidAttribute=function(e,t,n){Ft||Wt({});const r=jt(e),o=jt(t);return ln(r,o,n)},n.addHook=function(e,t){"function"==typeof t&&M(Me,e)&&_(Me[e],t)},n.removeHook=function(e,t){if(M(Me,e)){if(void 0!==t){const n=E(Me[e],t);return-1===n?void 0:N(Me[e],n,1)[0]}return S(Me[e])}},n.removeHooks=function(e){M(Me,e)&&(Me[e]=[])},n.removeAllHooks=function(){Me={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},n}(),Te=r(6145),Ee=r(5446);const Se=(...e)=>e.filter(Boolean).length>0?e.filter(Boolean).join(" "):null;function _e({data:e,variant:t="primary",className:n}){const r=t&&"primary"!==t?`mg-card--${t}`:null;return(0,Ee.jsxDEV)(Ee.Fragment,{children:e.map((e,t)=>(0,Ee.jsxDEV)("article",{className:Se("mg-card","mg-card__vc",r,n),children:[e.imgback&&(0,Ee.jsxDEV)("div",{className:"mg-card__visual",children:(0,Ee.jsxDEV)("img",{src:e.imgback,alt:e.imgalt,className:"mg-card__image"},void 0,!1)},void 0,!1),(0,Ee.jsxDEV)("div",{className:"mg-card__content",children:[(e.label1||e.label2)&&(0,Ee.jsxDEV)("div",{className:"mg-card__meta",children:[e.link&&e.label1&&(0,Ee.jsxDEV)("a",{href:e.link,className:"mg-card__label mg-card__label--active",children:e.label1},void 0,!1),e.link&&e.label2&&(0,Ee.jsxDEV)("a",{href:e.link,className:"mg-card__label mg-card__label--active",children:e.label2},void 0,!1)]},void 0,!0),(0,Ee.jsxDEV)("header",{className:"mg-card__title",children:(0,Ee.jsxDEV)("a",{href:e.link,children:e.title?.trim()},void 0,!1)},void 0,!1),e.summaryText&&(0,Ee.jsxDEV)("p",{className:"mg-card__summary",dangerouslySetInnerHTML:{__html:be.sanitize(e.summaryText)}},void 0,!1),e.button&&(0,Ee.jsxDEV)(Te.F,{type:"Primary",label:e.button,href:e.link},void 0,!1)]},void 0,!0)]},t,!0))},void 0,!1)}_e.propTypes={data:a().array.isRequired,variant:a().oneOf(["primary","secondary","tertiary","quaternary"]),className:a().string};export{_e as VerticalCard};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
/*! @license DOMPurify 3.4.
|
|
1
|
+
/*! @license DOMPurify 3.4.12 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.4.12/LICENSE */
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* @license React
|
|
5
|
-
* react-jsx-runtime.production.js
|
|
5
|
+
* react-jsx-dev-runtime.production.js
|
|
6
6
|
*
|
|
7
7
|
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
8
8
|
*
|
package/components/hydrate.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* This is a UNDRR Mangrove component: https://github.com/unisdr/undrr-mangrove?tab=readme-ov-file
|
|
3
|
-
* Compiled on: 2026-
|
|
3
|
+
* Compiled on: 2026-08-27T20:32:00.846Z
|
|
4
4
|
*/
|
|
5
5
|
import{default as r}from"react";import{createRoot as e}from"react-dom/client";function t({selector:t,component:o,fromElement:n,options:a={}}){const{clearContainer:c=!0,debugLabel:i=t,onError:l,identifierPrefix:u}=a,d=o?.default??o,s=u??t.replace(/[[\]\.#=>"' ]/g,"").replace(/^data-mg-?/,"mg-"),m=[];function f(o=document){const a=o.querySelectorAll(t),u=[];return a.forEach((t,o)=>{if("true"===t.dataset.mgHydrated)return;const a=c?t.innerHTML:null;try{const a=n(t);c&&(t.innerHTML="");const f=e(t,{identifierPrefix:`${s}-${o}-`,onCaughtError(r,e){console.error(`[${i}] Caught error in container #${o}:`,r,e),l&&l(r,t)},onUncaughtError(r,e){console.error(`[${i}] Uncaught error in container #${o}:`,r,e),l&&l(r,t)},onRecoverableError(r){console.warn(`[${i}] Recoverable error in container #${o}:`,r)}});f.render(r.createElement(d,a)),t.dataset.mgHydrated="true",m.push({root:f,container:t}),u.push(f)}catch(r){console.error(`[${i}] Container #${o}:`,r),null!==a&&(t.innerHTML=a),l&&l(r,t)}}),u}return f(),{get roots(){return m.map(r=>r.root)},update:f,unmountAll(){m.forEach(({root:r,container:e})=>{r.unmount(),delete e.dataset.mgHydrated}),m.length=0}}}export{t as default};
|