@emailmaker/emailmaker 1.0.48 → 1.0.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/README.md +1 -1
  2. package/asset-manifest.json +32 -30
  3. package/emailmaker-esm.js +1 -1
  4. package/emailmaker.js +1 -1
  5. package/iframe/css/sandbox.css +20 -2
  6. package/iframe/{iframe-eblock.a19b4b005600512ad57d.html → iframe-eblock.c516d87b9fc19e67c43a.html} +1 -1
  7. package/iframe/{iframe.a19b4b005600512ad57d.html → iframe.c516d87b9fc19e67c43a.html} +1 -1
  8. package/iframe/js/cssbeautify.js +1 -1
  9. package/iframe/sandbox-eblock.js +1 -1
  10. package/iframe/sandbox.js +1 -1
  11. package/package.json +1 -1
  12. package/plugin.html +1 -1
  13. package/plugin_blocks_test.html +1 -1
  14. package/plugin_default.html +1 -1
  15. package/plugin_s.html +1 -1
  16. package/static/js/1477.46df6668.js +2 -0
  17. package/static/js/1481.cd1a0886.js +1 -0
  18. package/static/js/1729.48808a7e.chunk.js +1 -0
  19. package/static/js/1813.e0bee286.js +1 -0
  20. package/static/js/{1821.dafa50f8.js → 1821.3a961d73.js} +1 -1
  21. package/static/js/{2208.5f05988a.js → 2208.f73122ba.js} +1 -1
  22. package/static/js/{3430.bec16278.js → 3430.0fd120a4.js} +1 -1
  23. package/static/js/{3710.193d2d5a.chunk.js → 3710.0baf371f.chunk.js} +1 -1
  24. package/static/js/{5130.785486e8.js → 5130.0a524bcd.js} +2 -2
  25. package/static/js/{5974.b325ee33.chunk.js → 5974.b84228a5.chunk.js} +2 -2
  26. package/static/js/6003.8d228b96.js +1 -0
  27. package/static/js/6430.0f6c23d8.js +2 -0
  28. package/static/js/{4384.d7dc931a.js.LICENSE.txt → 6430.0f6c23d8.js.LICENSE.txt} +0 -7
  29. package/static/js/6453.bbda855c.js +1 -0
  30. package/static/js/7159.56dbb0aa.js +2 -0
  31. package/static/js/7159.56dbb0aa.js.LICENSE.txt +13 -0
  32. package/static/js/{8458.004e0f0c.js → 8458.f8ef5e55.js} +1 -1
  33. package/static/js/8689.5ec8c633.chunk.js +1 -0
  34. package/static/js/{9593.8a0e7a2e.js → 9202.de849f35.js} +2 -2
  35. package/static/js/{9593.8a0e7a2e.js.LICENSE.txt → 9202.de849f35.js.LICENSE.txt} +0 -7
  36. package/static/js/9689.a67829e8.js +1 -0
  37. package/static/js/{emailmaker_core.7cf76221.js → emailmaker_core.22b19970.js} +1 -1
  38. package/translations.pot +7 -7
  39. package/static/js/1472.4f1f2346.js +0 -1
  40. package/static/js/1729.b71e4a99.chunk.js +0 -1
  41. package/static/js/2896.ce4941ab.js +0 -2
  42. package/static/js/2896.ce4941ab.js.LICENSE.txt +0 -6
  43. package/static/js/353.3e6b29fb.js +0 -1
  44. package/static/js/3593.f09ad9a7.js +0 -1
  45. package/static/js/4384.d7dc931a.js +0 -2
  46. package/static/js/7698.28da948c.js +0 -1
  47. package/static/js/8689.63fa1dc3.chunk.js +0 -1
  48. package/static/js/9878.cca6854e.js +0 -2
  49. /package/static/js/{9878.cca6854e.js.LICENSE.txt → 1477.46df6668.js.LICENSE.txt} +0 -0
  50. /package/static/js/{5130.785486e8.js.LICENSE.txt → 5130.0a524bcd.js.LICENSE.txt} +0 -0
  51. /package/static/js/{5974.b325ee33.chunk.js.LICENSE.txt → 5974.b84228a5.chunk.js.LICENSE.txt} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(globalThis.webpackChunkemail_maker=globalThis.webpackChunkemail_maker||[]).push([[353],{45053:(t,e,n)=>{function s(t,e,n){const s=[];if(n&&(e=e.filter((t=>t.isVariable))),e.length){const n=function(t,e){const n=e.reduce(((t,{mapFn:e,start:n,end:s,syntax:a})=>(t[n]?t[n].push({value:s,mapFn:e,syntax:a}):t[n]=[{value:s,mapFn:e,syntax:a}],t)),Object.create(null)),s=new RegExp(e.map((({start:t})=>`(${t.replace(/[-[\]{}()*+?.,\\^$|]/g,"\\$&")})`)).join("|"),"g");return[...t.matchAll(s)].map((t=>({start:t.index,startToken:t[0],endTokens:n[t[0]]})))}(t,e);for(let e=0,a=n.length;e<a;e++){const{start:i,startToken:r,endTokens:o}=n[e];for(const{mapFn:c,value:h,syntax:d}of o){let r=t.indexOf(h,i);if(r>=0){for(let s=e+1;s<a;s++){const{start:e,startToken:a,endTokens:i}=n[s];i.some((t=>t.syntax===d))&&e<r&&(r=t.indexOf(h,r+1))}if(r>=0){const o=r+h.length,d=t.substring(i,o),l=c(d);!1!==l&&d!==l&&s.push({text:l,range:{start:i,end:o}});const p=n.findIndex((({start:t})=>t>=o));e=p>e?p-1:a;break}}}}}return s}function a(t,e){const n=[t];for(let s=e.length-1;s>=0;s--){const{text:t,range:a}=e[s],i=n[0];n.splice(0,1,i.substring(0,a.start),t,i.substring(a.end))}return n.join("")}function i(t){return`\x3c!--${t}--\x3e`}function r(t){return t.substring(4,t.length-3)}n.d(e,{Hk:()=>h,uI:()=>d});const o=/#set\s*\(\s*.*=.*\)/gm,c=/<!--#set\s*\(\s*.*=.*\)-->/gm,h=t=>{t.escape("\x3c!--","--\x3e",(t=>t),!1),t.escape("<style","</style>",(t=>t),!1),t.escape("<script","<\/script>",(t=>t),!1),t.escape("@{","}",i,!0).unescape("\x3c!--@{","}--\x3e",r,!0),t.unescape("\x3c!--%%%{{{","}}}%%%--\x3e",(t=>t.substring(10,t.length-9)),!1),t.escape("{%","%}",i,!0).unescape("\x3c!--{%","%}--\x3e",r,!0),t.escape("{#","#}",i,!0).unescape("\x3c!--{#","#}--\x3e",r,!0),t.escape("[[","]]",i,!0).unescape("\x3c!--[[","]]--\x3e",r,!0),t.createSyntax("ExpertSender").escape("<if",">",i).escape("</if",">",i).escape("<else",">",i).escape("</else",">",i).escape("<var ",">",i,!0).unescape("\x3c!--<if ",">--\x3e",r).unescape("\x3c!--</if",">--\x3e",r).unescape("\x3c!--<else ",">--\x3e",r).unescape("\x3c!--</else",">--\x3e",r).unescape("\x3c!--<var",">--\x3e",r,!0),t.createSyntax("velocity").escape("#if","#end",i).escape("#set",")",(t=>!!t.match(o)&&i(t)),!0).escape("#foreach","#end",i).escape("#macro","#end",i).unescape("\x3c!--#if","#end--\x3e",r).unescape("\x3c!--#set",")--\x3e",(t=>!!t.match(c)&&r(t)),!0).unescape("\x3c!--#foreach","#end--\x3e",r).unescape("\x3c!--#macro","#end--\x3e",r),t.escape("*|","|*",i,!0).unescape("\x3c!--*|","|*--\x3e",r,!0)};class d{constructor(t=h){this._disposables=[],this._escapes=[],this._unescapes=[];const{_escapes:e,_unescapes:n}=this;t({createSyntax(t){return{...this,syntax:t}},escape(t,n,s,a){return e.push({start:t,end:n,mapFn:s,isVariable:a,syntax:this.syntax||t}),this},unescape(t,e,s,a){return n.push({start:t,end:e,mapFn:s,isVariable:a,syntax:this.syntax||t}),this}})}getMappings(t,e){return s(t,this._escapes,e)}getRevertMappings(t,e){return s(t,this._unescapes,e)}getEscapedText(t,e){return a(t,this.getMappings(t,e))}getUnescapedText(t,e){return a(t,this.getRevertMappings(t,e))}addDisposable(t){this._disposables.push(t)}dispose(){for(const t of this._disposables)t.dispose()}}},80424:(t,e,n)=>{let s;async function a(){return s||(s=await n.e(1729).then(n.t.bind(n,1729,19)).then((t=>t.default)))}n.d(e,{F:()=>a})},74851:(t,e,n)=>{n.d(e,{C:()=>i,R:()=>a});var s=n(97717);function a(t){const e=(0,s.xy)(t);if(!t.querySelector("style[amp4email-boilerplate]")){const n=t.createElement("style");n.setAttribute("amp4email-boilerplate",""),n.innerHTML="body{visibility:hidden}",e.prepend(n)}}function i(t){const e=t.querySelector("style[amp4email-boilerplate]");e&&e.remove()}},91391:(t,e,n)=>{n.d(e,{Vq:()=>i,gP:()=>s,zq:()=>a});const s="https://cdn.ampproject.org/v0",a=`${s}.js`,i=`script[src='${a}']`},69279:(t,e,n)=>{n.d(e,{Q:()=>i,h:()=>r});var s=n(97717);const a="amp-custom";function i(t){const e=(0,s.xy)(t),n=t.querySelectorAll('link[rel="stylesheet"]'),i=[...t.querySelectorAll("style")].filter((t=>!t.hasAttribute("amp4email-boilerplate")));if(1===i.length){const t=i[0];if(t.parentElement===e&&""===t.getAttribute(a))return}let r=[];for(const s of i)r.push(s.innerHTML.replace(/!important/g,"")),s.remove();if(r.length){const n=t.createElement("style");n.innerHTML=`\n${r.join("")}\n`,n.setAttribute(a,""),e.append(n)}for(const s of n)s.remove()}function r(t){const e=t.querySelector(`style[${a}]`);e&&e.removeAttribute(a)}},59896:(t,e,n)=>{n.d(e,{C:()=>a});var s=n(97717);function a(t){let e=t.querySelectorAll("meta");for(const s of e){const t=s.getAttribute("charset");if(t)return void("utf-8"!==t&&s.setAttribute("charset","utf-8"))}const n=(0,s.xy)(t),a=t.createElement("meta");a.setAttribute("charset","utf-8"),n.appendChild(a)}},91981:(t,e,n)=>{function s(t,e,n){const s=n('script:not([type="application/ld+json"])'),a=t.querySelectorAll(s);for(const r of a){var i;null!==(i=r.getAttribute("src"))&&void 0!==i&&i.startsWith("https://cdn.ampproject.org/")||r.remove()}}n.d(e,{y:()=>s})},97717:(t,e,n)=>{function s(t){let e=t.documentElement;return e||(e=t.createElement("html"),t.appendChild(e)),e}function a(t){let e=t.head;if(!e){e=t.createElement("head");let n=s(t);n.insertBefore(e,n.firstChild)}return e}function i(t){const e=Object.create(null),n=t.getAttributeNames();for(const s of n)e[s]=t.getAttribute(s);return e}n.d(e,{ep:()=>s,gu:()=>i,xy:()=>a})},16799:(t,e,n)=>{n.d(e,{H:()=>s});class s{constructor(t){this._voidElements=void 0,this._voidElements=new Set(t)}isVoidElement(t,e){return this._voidElements.has(t.toLowerCase())}}},8357:(t,e,n)=>{n.d(e,{X:()=>y});var s=n(60439);let a;!function(t){t[t.StartCommentTag=0]="StartCommentTag",t[t.Comment=1]="Comment",t[t.EndCommentTag=2]="EndCommentTag",t[t.StartTagOpen=3]="StartTagOpen",t[t.StartTagClose=4]="StartTagClose",t[t.StartTagSelfClose=5]="StartTagSelfClose",t[t.StartTag=6]="StartTag",t[t.EndTagOpen=7]="EndTagOpen",t[t.EndTagClose=8]="EndTagClose",t[t.EndTag=9]="EndTag",t[t.DelimiterAssign=10]="DelimiterAssign",t[t.AttributeName=11]="AttributeName",t[t.AttributeValue=12]="AttributeValue",t[t.StartDoctypeTag=13]="StartDoctypeTag",t[t.Doctype=14]="Doctype",t[t.EndDoctypeTag=15]="EndDoctypeTag",t[t.Content=16]="Content",t[t.Whitespace=17]="Whitespace",t[t.Unknown=18]="Unknown",t[t.Script=19]="Script",t[t.Styles=20]="Styles",t[t.EOS=21]="EOS",t[t.AdvancedStart=100]="AdvancedStart",t[t.AdvancedEnd=101]="AdvancedEnd"}(a||(a={}));class i{constructor(t,e){this.source=void 0,this.len=void 0,this.position=void 0,this.source=t,this.len=t.length,this.position=e}eos(){return this.len<=this.position}getSource(){return this.source}pos(){return this.position}goBackTo(t){this.position=t}goBack(t){this.position-=t}advance(t){this.position+=t}goToEnd(){this.position=this.source.length}nextChar(){return this.source.charCodeAt(this.position++)||0}peekChar(t=0){return this.source.charCodeAt(this.position+t)||0}advanceIfChar(t){return t===this.source.charCodeAt(this.position)&&(this.position++,!0)}advanceIfChars(t){let e;if(this.position+t.length>this.source.length)return!1;for(e=0;e<t.length;e++)if(this.source.charCodeAt(this.position+e)!==t[e])return!1;return this.advance(e),!0}advanceIfRegExp(t){const e=this.source.substr(this.position).match(t);return e?(this.position=this.position+e.index+e[0].length,e[0]):""}advanceUntilRegExp(t){const e=this.source.substr(this.position).match(t);return e?(this.position=this.position+e.index,e[0]):(this.goToEnd(),"")}advanceUntilChar(t){for(;this.position<this.source.length;){if(this.source.charCodeAt(this.position)===t)return!0;this.advance(1)}return!1}advanceUntilChars(t){for(;this.position+t.length<=this.source.length;){let e=0;for(;e<t.length&&this.source.charCodeAt(this.position+e)===t[e];e++);if(e===t.length)return!0;this.advance(1)}return this.goToEnd(),!1}skipWhitespace(){return this.advanceWhileChar((t=>t===C||t===m||t===u||t===T||t===f))>0}advanceWhileChar(t){const e=this.position;for(;this.position<this.len&&t(this.source.charCodeAt(this.position));)this.position++;return this.position-e}}const r="!".charCodeAt(0),o="-".charCodeAt(0),c="<".charCodeAt(0),h=">".charCodeAt(0),d="/".charCodeAt(0),l="=".charCodeAt(0),p='"'.charCodeAt(0),g="'".charCodeAt(0),u="\n".charCodeAt(0),f="\r".charCodeAt(0),T="\f".charCodeAt(0),C=" ".charCodeAt(0),m="\t".charCodeAt(0),S={"text/x-handlebars-template":!0,"text/html":!0};function b(t,e=0,n=s.S5.WithinContent,u=!1){const f=new i(t,e);let T,C,m,b,v,E=n,x=0,k=a.Unknown;function y(){return f.advanceIfRegExp(/^[_:a-zA-Z][_:\w-.\d]*/).toLowerCase()}function A(t,e,n){return k=e,x=t,T=n,e}function W(){const t=f.pos();if(f.eos())return A(t,a.EOS);let e;switch(E){case s.S5.WithinComment:return f.advanceIfChars([o,o,h])?(E=s.S5.WithinContent,A(t,a.EndCommentTag)):(f.advanceUntilChars([o,o,h]),A(t,a.Comment));case s.S5.WithinDoctype:return f.advanceIfChar(h)?(E=s.S5.WithinContent,A(t,a.EndDoctypeTag)):(f.advanceUntilChar(h),A(t,a.Doctype));case s.S5.WithinContent:if(f.advanceIfChar(c)){if(!f.eos()&&f.peekChar()===r){if(f.advanceIfChars([r,o,o]))return E=s.S5.WithinComment,A(t,a.StartCommentTag);if(f.advanceIfRegExp(/^!doctype/i))return E=s.S5.WithinDoctype,A(t,a.StartDoctypeTag)}return f.advanceIfChar(d)?(E=s.S5.AfterOpeningEndTag,A(t,a.EndTagOpen)):(E=s.S5.AfterOpeningStartTag,A(t,a.StartTagOpen))}return f.advanceUntilChar(c),A(t,a.Content);case s.S5.AfterOpeningEndTag:return y().length>0?(E=s.S5.WithinEndTag,A(t,a.EndTag)):f.skipWhitespace()?A(t,a.Whitespace,"Tag name must directly follow the open bracket."):(E=s.S5.WithinEndTag,f.advanceUntilChar(h),t<f.pos()?A(t,a.Unknown,"End tag name expected."):W());case s.S5.WithinEndTag:if(f.skipWhitespace())return A(t,a.Whitespace);if(f.advanceIfChar(h))return E=s.S5.WithinContent,A(t,a.EndTagClose);if(u&&f.peekChar()===c)return E=s.S5.WithinContent,A(t,a.EndTagClose,"Closing bracket missing.");e="Closing bracket expected.";break;case s.S5.AfterOpeningStartTag:return m=y(),v=void 0,b=void 0,m.length>0?(C=!1,E=s.S5.WithinTag,A(t,a.StartTag)):f.skipWhitespace()?A(t,a.Whitespace,"Tag name must directly follow the open bracket."):(E=s.S5.WithinTag,f.advanceUntilChar(h),t<f.pos()?A(t,a.Unknown,"Start tag name expected."):W());case s.S5.WithinTag:return f.skipWhitespace()?(C=!0,A(t,a.Whitespace)):C&&(b=f.advanceIfRegExp(/^[^\s"'></=\x00-\x0F\x7F\x80-\x9F]*/).toLowerCase(),b.length>0)?(E=s.S5.AfterAttributeName,C=!1,A(t,a.AttributeName)):f.advanceIfChars([d,h])?(E=s.S5.WithinContent,A(t,a.StartTagSelfClose)):f.advanceIfChar(h)?(E="script"===m?v&&S[v]?s.S5.WithinContent:s.S5.WithinScriptContent:"style"===m?s.S5.WithinStyleContent:s.S5.WithinContent,A(t,a.StartTagClose)):u&&f.peekChar()===c?(E=s.S5.WithinContent,A(t,a.StartTagClose,"Closing bracket missing.")):(f.advance(1),A(t,a.Unknown,"Unexpected character in tag."));case s.S5.AfterAttributeName:return f.skipWhitespace()?(C=!0,A(t,a.Whitespace)):f.advanceIfChar(l)?(E=s.S5.BeforeAttributeValue,A(t,a.DelimiterAssign)):(E=s.S5.WithinTag,W());case s.S5.BeforeAttributeValue:if(f.skipWhitespace())return A(t,a.Whitespace);let n=f.advanceIfRegExp(/^[^\s"'`=<>]+/);if(n.length>0)return f.peekChar()===h&&f.peekChar(-1)===d&&(f.goBack(1),n=n.substr(0,n.length-1)),"type"===b&&(v=n),E=s.S5.WithinTag,C=!1,A(t,a.AttributeValue);const i=f.peekChar();return i===g||i===p?(f.advance(1),f.advanceUntilChar(i)&&f.advance(1),"type"===b&&(v=f.getSource().substring(t+1,f.pos()-1)),E=s.S5.WithinTag,C=!1,A(t,a.AttributeValue)):(E=s.S5.WithinTag,C=!1,W());case s.S5.WithinScriptContent:let T=1;for(;!f.eos();){const e=f.advanceIfRegExp(/<!--|-->|<\/?script\s*\/?>?/i);if(0===e.length)return f.goToEnd(),A(t,a.Script);if("\x3c!--"===e)1===T&&(T=2);else if("--\x3e"===e)T=1;else if("/"!==e[1])2===T&&(T=3);else{if(3!==T){f.goBack(e.length);break}T=2}}return E=s.S5.WithinContent,t<f.pos()?A(t,a.Script):W();case s.S5.WithinStyleContent:return f.advanceUntilRegExp(/<\/style/i),E=s.S5.WithinContent,t<f.pos()?A(t,a.Styles):W()}return f.advance(1),E=s.S5.WithinContent,A(t,a.Unknown,e)}return{scan:function(){const t=f.pos(),e=E,n=W();return n===a.EOS||t!==f.pos()||u&&(n===a.StartTagClose||n===a.EndTagClose)?n:(console.log("Scanner.scan has not advanced at offset "+t+", state before: "+e+" after: "+E),f.advance(1),A(t,a.Unknown))},getTokenType:()=>k,getTokenOffset:()=>x,getTokenLength:()=>f.pos()-x,getTokenEnd:()=>f.pos(),getTokenText:()=>f.getSource().substring(x,f.pos()),getScannerState:()=>E,getTokenError:()=>T}}var v=n(16799),E=n(61704);function x(t){if("string"===typeof t){const e=t.startsWith("'")||t.startsWith('"')?1:0,n=t.endsWith("'")||t.endsWith('"')?t.length-1:t.length;return t.substring(e,n)}return t}class k{constructor(t,e){this.text=t,this.type=e,this.node=void 0,this.replaces=void 0}get hasNode(){return!!this.node}addReplace(t){var e;null===(e=this.replaces)||void 0===e||e.push(t)}start(t,e,n){if(!this.node){const s=this.node=new E.b(t,this.text.length,[],n);s.type=this.type,s.startTagEnd=e,this.replaces=[]}}finish(t,e){const n=this.replaces,s=this.node,a=t+(e||0);if(n){for(const t of n){const e=t.parent;if(!e)throw new Error("parent not defined");const n=e.children.indexOf(t);e.children.splice(n,1)}this.replaces=void 0}if(s){const n=s.parent;if(!n)throw new Error("parent not defined");n.children.push(s),s.closed=void 0!==e,s.endTagStart=t,s.end=a,s.content=this.text.substring(s.startTagEnd,t),this.node=void 0}}}class y{constructor(t){this.dataManager=t}parse(t,e=[]){var n;const s=b(t,void 0,void 0,!0),i=new E.b(0,t.length,[],void 0);i.type=E.Z.ROOT;let r,o=i,c=-1,h=null,d=s.scan();const l=()=>{if(!o.tag){const e=o.parent.children,n=e[e.length-2],s=t.substring(o.start,o.end);(null===n||void 0===n?void 0:n.type)===E.Z.HTML?(n.content=(n.content||"")+s,n.end=o.end,e.splice(e.length-1,1)):(o.type=E.Z.HTML,o.content=s,o.children=[]),o.type=E.Z.HTML}o=o.parent},p=new k(t,E.Z.COMMENT),g=new k(t,E.Z.DOCTYPE),u=t=>{o.children.push(t)};for(;d!==a.EOS;){switch(d){case a.StartDoctypeTag:g.start(s.getTokenOffset(),s.getTokenEnd(),o);break;case a.EndDoctypeTag:{const e=o.lastChild,n=g.node;if(!n)throw new Error("");const a=e?e.end:void 0!==o.startTagEnd?o.startTagEnd:o.start;if(a!==n.start){const e=t.substring(a,n.start);if(e){const t=new E.b(a,n.start,[],o);t.type=E.Z.HTML,t.content=e,u(t)}}g.finish(s.getTokenOffset(),s.getTokenLength());break}case a.StartCommentTag:p.start(s.getTokenOffset(),s.getTokenEnd(),o);break;case a.EndCommentTag:{const e=o.lastChild,n=p.node;if(!n)throw new Error("");const a=e?e.end:void 0!==o.startTagEnd?o.startTagEnd:o.start;if(a!==n.start){const e=t.substring(a,n.start);if(e){const t=new E.b(a,n.start,[],o);t.type=E.Z.HTML,t.content=e,u(t)}}p.finish(s.getTokenOffset(),s.getTokenLength());break}case a.StartTagOpen:const n=o.lastChild,i=new E.b(s.getTokenOffset(),t.length,[],o),d=n?n.end:void 0!==o.startTagEnd?o.startTagEnd:o.start;if(d!==i.start){const e=t.substring(d,i.start);if(e){const t=new E.b(d,i.start,[],o);t.type=E.Z.HTML,t.content=e,u(t)}}u(i),o=i;break;case a.StartTag:o.tag=s.getTokenText();break;case a.StartTagClose:o.parent&&(o.end=s.getTokenEnd(),s.getTokenLength()?(o.startTagEnd=s.getTokenEnd(),o.tag&&this.dataManager.isVoidElement(o.tag,e)&&(o.closed=!0,l())):l());break;case a.StartTagSelfClose:o.parent&&(o.closed=!0,o.end=s.getTokenEnd(),o.startTagEnd=s.getTokenEnd(),l());break;case a.EndTagOpen:c=s.getTokenOffset(),r=void 0;break;case a.EndTag:r=s.getTokenText().toLowerCase();break;case a.EndTagClose:let f=o;for(;!f.isSameTag(r)&&f.parent;)f=f.parent;if(f.parent){const e=o.lastChild,n=e?e.end:void 0===o.startTagEnd?o.start:o.startTagEnd;if(n!==c){const e=t.substring(n,c);if(e){const t=new E.b(n,c,[],o);t.type=E.Z.HTML,t.content=e,u(t)}}for(;o!==f;)o.end=c,o.closed=!1,l();o.closed=!0,o.endTagStart=c,o.end=s.getTokenEnd(),l()}break;case a.AttributeName:{h=s.getTokenText();let t=o.attributes;t||(o.attributes=t={}),t[h]=null;break}case a.AttributeValue:{const t=s.getTokenText(),e=o.attributes;e&&h&&(e[h]=x(t),h=null);break}}d=s.scan()}for(;o.parent;)o.end=t.length,o.closed=!1,l();p.hasNode&&console.log("has unclosed comments"),p.finish(t.length);const f=(null===(n=i.lastChild)||void 0===n?void 0:n.end)||0;if(f<t.length){const e=t.substring(f);if(e){const n=new E.b(f,t.length,[],i);n.type=E.Z.HTML,n.content=e,u(n)}}return{roots:i.children,findNodeBefore:i.findNodeBefore.bind(i),findNodeAt:i.findNodeAt.bind(i)}}}const A=["area","base","br","col","embed","hr","img","input","link","meta","source","track","wbr"];new y(new v.H(A))},61704:(t,e,n)=>{n.d(e,{b:()=>r,Z:()=>a});new Set(["area","br","col","embed","hr","img","input","link","meta","param"]);Object.create(null);function s(t,e){let n=0,s=t.length;if(0===s)return 0;for(;n<s;){let a=Math.floor((n+s)/2);e(t[a])?s=a:n=a+1}return n}let a;!function(t){t[t.HTML=0]="HTML",t[t.ELEMENT=1]="ELEMENT",t[t.ROOT=2]="ROOT",t[t.COMMENT=3]="COMMENT",t[t.DOCTYPE=4]="DOCTYPE",t[t.ADVANCED=5]="ADVANCED"}(a||(a={}));const i=t=>t.type===a.HTML?t.start-1:t.start;class r{get attributeNames(){return this.attributes?Object.keys(this.attributes):[]}get root(){return this.parent?this.parent.root:this}constructor(t,e,n,s){this.start=t,this.end=e,this.children=n,this.parent=s,this.content=void 0,this.type=a.ELEMENT,this.tag=void 0,this.closed=!1,this.startTagEnd=void 0,this.endTagStart=void 0,this.attributes=void 0,this.createdBy=void 0,this.isDirty=void 0}isSameTag(t){return void 0===this.tag?void 0===t:void 0!==t&&this.tag.length===t.length&&this.tag.toLowerCase()===t}get firstChild(){return this.children[0]}get lastChild(){return this.children.length?this.children[this.children.length-1]:void 0}findNodeBefore(t){const e=s(this.children,(e=>t<=i(e)))-1;if(e>=0){const n=this.children[e];if(t>i(n)){if(t<n.end)return n.findNodeBefore(t);const e=n.lastChild;return e&&e.end===n.end?n.findNodeBefore(t):n}}return this}findNodeAt(t){const e=s(this.children,(e=>t<=i(e)))-1;if(e>=0){const s=this.children[e];if(t>=i(s)&&t<=((n=s).type===a.HTML?n.end+1:n.end))return s.findNodeAt(t)}var n;return this}find(t){if(t(this))return this;for(const e of this.children){let n=e.find(t);if(n)return n}}closest(t){let e=this;do{if(t(e))return e}while(e=e.parent)}parents(){return this.parent?[this.parent,...this.parent.parents()]:[]}closestFromRoot(t,e=!0){const n=e?[this,...this.parents()]:this.parents();for(let s=n.length-1;s>=0;s--){const e=n[s];if(t(e))return e}}contains(t){return Boolean(t.closest((t=>t===this)))}clone(t=this.parent,e=this.start,n=!0){const s=this.start-e,a=new r(e,this.end-s,[],t);return a.children=n?this.children.map((t=>t.clone(a,t.start-s))):[],a.attributes={...this.attributes},a.closed=this.closed,a.content=this.content,a.startTagEnd=this.startTagEnd,a.endTagStart=this.endTagStart,a.tag=this.tag,a.type=this.type,a}}}}]);
@@ -1 +0,0 @@
1
- "use strict";(globalThis.webpackChunkemail_maker=globalThis.webpackChunkemail_maker||[]).push([[3593],{84007:(e,t,r)=>{r.d(t,{$$:()=>m,Os:()=>l});var o=r(16799),n=r(8357),s=r(61704);const c=["area","base","br","col","embed","hr","img","input","link","meta","source","track","wbr"],i=new o.H(c),a=new n.X(i);function l(e,t,r){try{e.setAttribute(t,r)}catch{let o=e.tagName.toLowerCase();"html"===o&&(o="div");const n=`<${o} ${t}="${r}"/>`;let s=function(e){let t;switch(null===e||void 0===e?void 0:e.toLowerCase()){case"tr":t=document.createElement("table");break;case"td":t=document.createElement("tr");break;case"head":case"body":t=document.createElement("html");break;case"DocumentType":case"html":{const e=document.implementation.createHTMLDocument();for(const t of[...e.childNodes])t.remove();return e}default:t=document.createElement("div")}return t}(o);if(s instanceof Document)return;s.innerHTML=n;const c=1===s.children.length?s.firstElementChild:s.getElementsByTagName(o)[0];if(!c)throw new Error("targetElement is not defined");const i=c.getAttributeNode(t);i&&e.setAttributeNode(i.cloneNode())}}function u(e,t=!0){let r=e.content;switch(e.type){case s.Z.ROOT:{const r=document.implementation.createHTMLDocument();for(const e of[...r.childNodes])r.removeChild(e);if(t)for(const t of e.children)r.appendChild(u(t));return r}case s.Z.DOCTYPE:return(new DOMParser).parseFromString(`<!DOCTYPE${e.content}>`,"text/html").doctype;case s.Z.COMMENT:return document.createComment(r||"");case s.Z.ELEMENT:if(e.tag){const r=document.createElement(e.tag);if(Object.defineProperty(r,"$$tagName",{enumerable:!1,configurable:!1,value:e.tag}),e.attributes)for(const t of e.attributeNames){const n=e.attributes[t];try{l(r,t,"string"===typeof n?n:"")}catch(o){}}if(t)for(const t of e.children)r.appendChild(u(t));return r}return document.createTextNode("<");case s.Z.HTML:return function(e){if(e){const t=document.createElement("div");return t.insertAdjacentHTML("afterbegin",e),t.firstChild||document.createTextNode("")}return document.createTextNode("")}(r||"");default:throw new Error("unsupported node")}}function m(e){var t;return(t=e,a.parse(t)).roots.map((e=>u(e)))}},85974:(e,t,r)=>{r.d(t,{Km:()=>C,Sc:()=>E,Nh:()=>A});var o=r(90854),n=r(84007),s=r(74851),c=r(69279);const i='<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">',a="<!doctype html>";var l=r(97717);async function u(e,t={}){const r=document.createElement("amp-img"),s=await(0,o.rq)(e)||void 0,c=null!==s&&void 0!==s&&s.height?`${parseInt(s.height)}px`:"",i=null!==s&&void 0!==s&&s.width?`${parseInt(s.width)}px`:"",a=e.src||e.srcset.split(",")[0];"100%"===e.style.width&&e.style.removeProperty("width"),"100%"===e.style.maxWidth&&e.style.removeProperty("max-width"),t={...(0,l.gu)(e),alt:e.alt,width:i,height:c,src:a,layout:"responsive",...t};for(const o of Object.keys(t))(0,n.Os)(r,o,t[o]);return r}function m(e){const t=document.createElement("img"),{layout:r,height:o,...s}=(0,l.gu)(e),c="responsive"===r;for(const i of Object.keys(s))(0,n.Os)(t,i,s[i]);return c&&(t.style.maxWidth=s.width||"0px",t.style.width="100%"),t}var d=r(59896),f=r(91981),p=r(91391);var y=r(80424);const h=new Map;const v=new Map;const g="$GLOBAL_ATTRS",b=new Map;async function w(){if(!b.size){var e;const t=null===(e=(await(0,y.F)()).attrLists.find((e=>e.name===g)))||void 0===e?void 0:e.attrs;if(t)for(const e of t)b.set(e.name,e)}return b}function A(e){var t;return(0,o.vq)(e)&&(e.tagName.startsWith("AMP")||"FORM"===e.tagName||"TEMPLATE"===e.tagName&&"amp-mustache"===(null===(t=e.getAttribute("type"))||void 0===t?void 0:t.toLowerCase()))}function x(e,t,r){var n,s,c;if(t)if((0,o.vq)(e))switch(e.tagName.toLowerCase()){case"body":case r("script"):case"style":case"meta":case"title":return;case"head":case"html":a();break;default:i()||a()}else(0,o.wz)(e)?a():(0,o.ir)(e)&&(null!==(n=e.textContent)&&void 0!==n&&n.trim()||null!==(s=e.nextSibling)&&void 0!==s&&null!==(c=s.textContent)&&void 0!==c&&c.trim()&&(0,o.ir)(e.nextSibling))&&i();function i(){const r=t.compareDocumentPosition(e);if(!(8&r)){if(2&r)return t.insertBefore(e,t.firstChild),!0;if(4&r)return t.appendChild(e),!0}return!1}function a(){const o=[...e.childNodes];for(let e=o.length-1;e>=0;e--)x(o[e],t,r)}}async function T(e,t){const r=e=>t.replaceSelectors(e.toLowerCase());if(t.replaceImages&&await async function(e){const t=e.querySelectorAll("img");for(const o of t)o.replaceWith(await u(o));const r=e.querySelectorAll("picture");for(const o of r){const e=o.querySelector("img");if(e){const t=await u(e);o.replaceWith(t)}else o.remove()}}(e),t.injectExtensions){const A=t.replaceSelectors(p.Vq);if(!e.querySelector(A)){const T=t.createElementFn("script");T.setAttribute("src",p.zq),T.setAttribute("async","");(0,l.xy)(e).appendChild(T)}}t.injectRequiredTags&&((0,f.y)(e,t.createElementFn,r),function(e){const t=e.doctype;if(t){if((0,o.TM)(t)===a)return;const r=(new DOMParser).parseFromString(a,"text/html").doctype;e.replaceChild(r,t)}else{const t=(new DOMParser).parseFromString(a,"text/html").doctype;e.insertBefore(t,e.firstChild)}}(e),(0,s.R)(e),(0,d.C)(e)),t.replaceStylesAndLinks&&(0,c.Q)(e);const i=await(0,y.F)(),m=await async function(){if(!h.size){const e=await(0,y.F)(),t=e.tags;for(let r=0;r<t.length;r++){const o=t[r],{selector:n,attrs:s,attrLists:c}=o,i=(null===c||void 0===c?void 0:c.flatMap((t=>e.attrLists.filter((({name:e})=>e===t)).flatMap((e=>e.attrs)))))||[];h.set(n,{...o,priority:r,attrs:new Map([...s,...i].map((e=>[e.name,e])))})}}return h}(),g=new Set(t.removeUnsupportedTags?e.querySelectorAll("*"):[]),b=new Map;for(let[S,E]of m){S=r(S);let C=e.querySelectorAll(S);t.injectRequiredTags&&E.required&&!C.length&&(C=[...C,t.createElementFn(E.name)]);for(const q of C){const R=b.get(q);R&&R.priority>E.priority||b.set(q,E)}}for(let[O,L]of b){const P=L.requiredParent?"$ROOT"===L.requiredParent?e:e.querySelector(L.requiredParent):null;!P||O.parentNode&&!t.moveInvalidTagPosition?O.parentNode||e.body.appendChild(O):P!==O.parentNode&&("HEAD"===L.name?P.insertBefore(O,P.firstChild):P.appendChild(O)),t.removeUnsupportedTags&&g.delete(O);const M=await w();if(t.removeUnsupportedAttributes||t.injectRequiredAttributes){const N=L.attrs,k=t.injectRequiredAttributes?new Set([...N].map((([e,t])=>t)).filter((e=>e.required&&e.value))):void 0,F=O.getAttributeNames();for(const $ of F){const j=N.get($)||M.get($);if(j){if("id"===$||"class"===$||"style"===$){null===k||void 0===k||k.delete(j);continue}if(t.removeUnsupportedAttributes){const D=O.getAttribute($);if(j.value&&j.value.indexOf(D)<0&&O.removeAttribute($),j.valueRegex){new RegExp(j.valueRegex).test(D)||O.removeAttribute($)}if(j.disallowedValueRegex){new RegExp(j.disallowedValueRegex).test(D)&&O.removeAttribute($)}const U=j.valueUrl;if(U)if(""===D)U.allowEmpty||O.removeAttribute($);else if(D.indexOf("\x3c!--")>0&&D.indexOf("--\x3e")>0);else if(!U.allowRelative)if(D.startsWith("#")||D.startsWith("/"))O.removeAttribute($);else{const H=U.protocol.length?U.protocol:["https"];let W=D.substring(0,D.indexOf(":"));if(W)if(H.indexOf(W)<0){let I=H[0]+D.substring(D.indexOf(":"));URL.canParse(I)?(0,n.Os)(O,$,I):O.removeAttribute($)}else URL.canParse(D)||O.removeAttribute($);else{let z=H[0]+D;URL.canParse(z)?(0,n.Os)(O,$,z):O.removeAttribute($)}}}null===k||void 0===k||k.delete(j)}else{if("id"===$||"class"===$||"style"===$)continue;t.removeUnsupportedAttributes&&O.removeAttribute($)}}if(k)for(const B of k)(0,n.Os)(O,B.name,B.value[0])}}t.moveInvalidTagPosition&&x(e,e.body,r);for(const Z of g)Z.remove();if(t.removeUnsupportedStyles){const V=e.querySelectorAll("*"),Y=await async function(){if(!v.size){const e=await(0,y.F)();for(const t of e.declarations)v.set(t.name,t)}return v}();function _(e){const t=e.cssText.replaceAll(/\".*\"/g,"").replaceAll(/\'.*\'/g,"").replaceAll(/\/\*.*\*\/|(-moz-|-ms-|-o-|-webkit-)+\w+(?=:)/g,"").match(/[a-z-]+(?=:[^before|after|hover])/gi)||[];for(const r of t){if(!r)continue;const t=e.getPropertyValue(r);"important"===e.getPropertyPriority(r)&&e.setProperty(r,t);const o=Y.get(r);if(o){if(o.value)o.value.indexOf(t)<0&&e.removeProperty(r);else if(o.valueRegex){new RegExp(o.valueRegex).test(t)||e.removeProperty(r)}}else e.removeProperty(r)}}function G(e){return"CSSStyleRule"===e.constructor.name}function K(e){return"CSSMediaRule"===e.constructor.name}function Q(e){const t=e.cssRules;for(let r=t.length-1;r>=0;r--){const o=t[r];G(o)?o.selectorText.indexOf("[")>=0||o.selectorText.indexOf(":")>=0?e.deleteRule(r):(_(o.style),o.style.cssText||e.deleteRule(r)):K(o)?(Q(o),o.cssRules.length||e.deleteRule(r)):e.deleteRule(r)}}for(const J of V)if((0,o.uE)(J)){const ee=J.getAttribute("style");ee&&(_(J.style),J.style.length?J.style.cssText!==ee&&J.setAttribute("style",J.style.cssText):J.removeAttribute("style"))}const X=e.querySelector("style[amp-custom]");if(X){const te=X.sheet;te&&(Q(te),X.innerHTML=[...te.cssRules].map((e=>e.cssText)).join("\n"))}}await async function(e,t,r){for(const{name:s,versions:c}of t){let t=!1;switch(s){case"amp-mustache":t=!!e.querySelector("template[type='amp-mustache']"),t||(t=!!e.querySelector(r.replaceSelectors(r.replaceSelectors("script[template='amp-mustache']"))));break;case"amp-form":t=!!e.querySelector(s),!t&&r.formsAsAmpForms&&"amp-form"===s&&(t=!!e.querySelector("form"));break;case"amp-bind":t=!!e.querySelector(s),t||(t=!!e.querySelector("[on]"));break;default:t=!!e.querySelector(s)}if(t){const t=r.replaceSelectors("amp-mustache"===s?`script[async][custom-template='${s}']`:`script[async][custom-element='${s}']`);if(!e.querySelector(t)){const t=(0,l.xy)(e),i=r.createElementFn("script"),a=(o=s,n=c.findLast((e=>"latest"!==e))||"v0",`${p.gP}/${o.toLowerCase()}-${n}.js`);i.setAttribute("async",""),i.setAttribute("amp-mustache"===s?"custom-template":"custom-element",s),i.setAttribute("src",a),t.appendChild(i),t.appendChild(e.createTextNode("\n"))}}}var o,n}(e,i.extensions,t)}function S(e,t){return Object.keys(t).reduce(((e,r)=>e.replaceAll(r,t[r])),e)}function E(e,t={}){const{correct:r=!0,injectExtensions:o=!0,mappedTags:n={}}=t;return T(e,{replaceImages:r,replaceStylesAndLinks:r,injectRequiredTags:r,injectExtensions:o,formsAsAmpForms:o,injectRequiredAttributes:r,moveInvalidTagPosition:r,removeUnsupportedTags:r,removeUnsupportedAttributes:r,removeUnsupportedStyles:r,createElementFn:t=>e.createElement(n[t.toLowerCase()]||t),replaceSelectors:e=>S(e.toLowerCase(),n)})}function C(e,t={}){const{correct:r=!0,removeExtensions:n=!0,mappedTags:u={}}=t,d=t=>e.createElement(u[t.toLowerCase()]||t),f=e=>S(e,u);if(r){!function(e){const t=e.querySelectorAll("amp-img");for(const r of t)r.replaceWith(m(r))}(e),function(e){const t=e.doctype;if(t&&(0,o.TM)(t).toLowerCase()===a){const r=(new DOMParser).parseFromString(i,"text/html").doctype;e.replaceChild(r,t)}}(e),(0,c.h)(e),(0,s.C)(e);const t=(0,l.ep)(e);t.removeAttribute("\u26a14email"),t.removeAttribute("data-css-strict")}n&&function(e,t){const r=e.querySelectorAll("*"),o=e.querySelectorAll(t.replaceSelectors("script[src]"));for(const s of o){var n;null!==(n=s.getAttribute("src"))&&void 0!==n&&n.startsWith(p.gP)&&s.remove()}for(const s of r)A(s)&&"FORM"!==s.tagName&&s.remove()}(e,{formsAsAmpForms:t.removeExtensions,createElementFn:d,replaceSelectors:f})}}}]);