@retailrocketgroup/retailrocket-create.welcome-sequence-vue-email-template-render 6.0.388803 → 6.0.388926

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.
@@ -144,7 +144,7 @@ Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function
144
144
  ${t.Width}px
145
145
  dotted
146
146
  ${c_({borderColor:t.Color,themeColors:e})}
147
- `}),md=t=>({borderTop:Yk(t.border.Top,t.themeColors),borderRight:Yk(t.border.Right,t.themeColors),borderBottom:Yk(t.border.Bottom,t.themeColors),borderLeft:Yk(t.border.Left,t.themeColors)}),bw=t=>t.borderCollapse!==void 0?{borderCollapse:ztt(t.borderCollapse)}:{borderCollapse:"collapse"},ztt=t=>{switch(t){case"Collapse":return"collapse";case"Separate":return"separate";default:return ls(t)}},jtt=t=>({Match:e=>{switch(t.Discriminator){case"None":return e.None();case"EmailBackgroundColor":return e.EmailBackgroundColor();case"BodyColor":return e.BodyColor();case"TitleColor":return e.TitleColor();case"HeadingColor":return e.HeadingColor();case"SubHeadingColor":return e.SubHeading();case"LargeTextColor":return e.LargeTextColor();case"NormalTextColor":return e.NormalTextColor();case"DescriptionTextColor":return e.DescriptionTextColor();case"PrimaryTextColor":return e.PrimaryTextColor();case"SecondaryTextColor":return e.SecondaryTextColor();case"ButtonTextColor":return e.ButtonTextColor();case"LinkColor":return e.LinkColor();case"PrimaryColor":return e.PrimaryColor();case"SecondaryColor":return e.SecondaryColor();case"CardBackgroundColor":return e.CardBackgroundColor();case"Custom":return e.Custom(t.CustomValue);default:return ls(t.Discriminator)}}}),Ll=t=>jtt(t.color).Match({None:()=>null,EmailBackgroundColor:()=>t.themeColors.EmailBackgroundColor,BodyColor:()=>t.themeColors.BodyColor,TitleColor:()=>t.themeColors.TitleColor,HeadingColor:()=>t.themeColors.HeadingColor,SubHeading:()=>t.themeColors.SubHeadingColor,LargeTextColor:()=>t.themeColors.LargeTextColor,NormalTextColor:()=>t.themeColors.NormalTextColor,DescriptionTextColor:()=>t.themeColors.DescriptionTextColor,PrimaryTextColor:()=>t.themeColors.PrimaryTextColor,SecondaryTextColor:()=>t.themeColors.SecondaryTextColor,LinkColor:()=>t.themeColors.LinkColor,PrimaryColor:()=>t.themeColors.PrimaryColor,SecondaryColor:()=>t.themeColors.SecondaryColor,CardBackgroundColor:()=>t.themeColors.CardBackgroundColor,ButtonTextColor:()=>t.themeColors.ButtonTextColor,Custom:e=>e}),I0e=t=>({Match:e=>{switch(t){case"Left":return e.Left();case"Center":return e.Center();case"Right":return e.Right();default:return ls(t)}}}),Utt=t=>t.containerAlign?I0e(t.containerAlign).Match({Left:()=>({textAlign:"left"}),Center:()=>({textAlign:"center"}),Right:()=>({textAlign:"right"})}):{},Lc=t=>t.containerAlign?I0e(t.containerAlign).Match({Left:()=>"left",Center:()=>"center",Right:()=>"right"}):"center",Ktt=Ze({__name:"If",props:{deps:{},theme:{},element:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=e,o=Mt({ifResult:!1,isLoading:!0});return n.deps.boolExpressionEvaluator({boolExpression:n.element.Predicate,context:n.context}).then(i=>{o.ifResult=i,o.isLoading=!1}),(i,s)=>(I(!0),J(ot,null,zn(o.ifResult?n.element.True:n.element.False,(a,l)=>(I(),et(kl,{key:l,deps:n.deps,theme:n.theme,element:a,context:n.context,path:[...n.path,o.ifResult?"True":"False",l],selectedElementPath:n.selectedElementPath,onOnImageSizeAdjusted:s[0]||(s[0]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[1]||(s[1]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementClicked:s[2]||(s[2]=u=>r("onElementClicked",u)),onOnElementUpdatedEvent:s[3]||(s[3]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[4]||(s[4]=u=>r("onElementRemoved",u))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))}}),vw=t=>({paddingTop:Sr({paddingExpression:t.paddings.Top,themeComponentPaddings:t.themeComponentPaddings,themeBodyPaddings:t.themeBodyPaddings})+"px",paddingRight:Sr({paddingExpression:t.paddings.Right,themeComponentPaddings:t.themeComponentPaddings,themeBodyPaddings:t.themeBodyPaddings})+"px",paddingBottom:Sr({paddingExpression:t.paddings.Bottom,themeComponentPaddings:t.themeComponentPaddings,themeBodyPaddings:t.themeBodyPaddings})+"px",paddingLeft:Sr({paddingExpression:t.paddings.Left,themeComponentPaddings:t.themeComponentPaddings,themeBodyPaddings:t.themeBodyPaddings})+"px"}),qtt=Wl,Jtt=t=>qtt(t.width).Match({Auto:()=>"initial",Pixel:e=>e.Value+"px",Percentage:e=>e.Value+"%"}),Gtt=["align"],Ytt=Ze({__name:"HeightContainer",props:{deps:{},theme:{},element:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("table",{class:"heightContainerRender",style:he([{"border-spacing":"0","border-collapse":"separate"},{width:z(Jtt)({width:n.element.Width})}])},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.element.ContainerAlign}),style:he([z(vw)({paddings:n.element.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),{height:n.element.Height?n.element.Height+"px":"",verticalAlign:n.element.VerticalAlign,backgroundRepeat:"no-repeat",backgroundSize:"contain",backgroundColor:z(Ll)({color:n.element.BackgroundColor,themeColors:n.theme.Colors})??"inherit"},z(md)({border:n.element.Border,themeColors:n.theme.Colors}),z(Wu)({borderRadius:n.element.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner})])},[(I(!0),J(ot,null,zn(n.element.Elements,(s,a)=>(I(),et(kl,{key:a,deps:n.deps,theme:n.theme,element:s,path:[...n.path,"Elements",a],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:i[0]||(i[0]=l=>r("onImageSizeAdjusted",l)),onOnImageOriginalSizeAdjusted:i[1]||(i[1]=l=>r("onImageOriginalSizeAdjusted",l)),onOnElementClicked:i[2]||(i[2]=l=>r("onElementClicked",l)),onOnElementUpdatedEvent:i[3]||(i[3]=l=>r("onElementUpdatedEvent",l)),onOnElementRemoved:i[4]||(i[4]=l=>r("onElementRemoved",l))},null,8,["deps","theme","element","path","selectedElementPath","context"]))),128))],12,Gtt)])])],4))}}),Xtt=t=>({Match:e=>{switch(t){case"Left":return e.Left();case"Center":return e.Center();case"Right":return e.Right();case"Inline":return e.Inline()}}}),qx=t=>Xtt(t.contentAlign).Match({Left:()=>({display:"block",textAlign:"left"}),Center:()=>({display:"block",textAlign:"center"}),Right:()=>({display:"block",textAlign:"right"}),Inline:()=>({})});let JI;const Jx={mounted(t,e){const n=e.value;JI=new ResizeObserver(r=>{r.forEach(o=>n(o.contentRect))}),JI.observe(t)},unmounted(t){JI.unobserve(t)}},Qtt=["href"],Ztt=["src","alt"],ent=["src","alt"],tnt=Ze({__name:"Image",props:{deps:{},theme:{},element:{},path:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementClicked"],setup(t,{emit:e}){const n=c=>{u("onImageOriginalSizeAdjusted",{Path:r.path,OriginalHeight:c.target.naturalHeight,OriginalWidth:c.target.naturalWidth})},r=t,o=Mt({href:"",src:"",alt:"",isLoaded:!1}),i=q(()=>r.element.IsResponsive?"100%":(r.element.IsRetina?r.element.OriginalWidth/2:r.element.OriginalWidth)+"px"),s=q(()=>r.element.IsResponsive?(r.element.IsRetina?r.element.OriginalWidth/2:r.element.OriginalWidth)+"px":"100%"),a=async c=>r.deps.stringExpressionEvaluator({stringExpression:c,context:r.context}),l=async()=>{const[c,d,h]=await Promise.all([a(r.element.Src),a(r.element.HRef),a(r.element.Alt)]);o.href=d,o.src=c,o.alt=h,o.isLoaded=!0};mn(()=>[r.element.Src,r.element.HRef,r.element.Alt,r.context],()=>l()),l();const u=e;return(c,d)=>r.element.IsLink?(I(),J("a",{key:0,href:o.href,style:he([z(qx)({contentAlign:r.element.ContentAlign})]),onClick:d[0]||(d[0]=wr(()=>u("onElementClicked"),["prevent"]))},[o.isLoaded?It((I(),J("img",{key:0,class:Me(["Image cursor-pointer",{"img-responsive":r.element.IsResponsive}]),src:o.src,alt:o.alt,style:he([z(Wu)({borderRadius:r.element.BorderRadius,borderRadiusCard:r.theme.BorderRadiusCard,bodyBorderRadius:r.theme.BorderRadius,borderButtonRadius:r.theme.BorderRadiusButton,borderBannerRadius:r.theme.BorderRadiusBanner}),z(md)({border:r.element.Border,themeColors:r.theme.Colors}),{width:i.value,maxWidth:s.value},{verticalAlign:r.element.VerticalAlign}]),onLoad:n},null,46,Ztt)),[[z(Jx),({width:h,height:m})=>u("onImageSizeAdjusted",{Path:r.path,AdjustedHeight:m,AdjustedWidth:h})]]):Ue("",!0)],12,Qtt)):(I(),J("span",{key:1,style:he([z(qx)({contentAlign:r.element.ContentAlign})]),onClick:d[1]||(d[1]=wr(()=>u("onElementClicked"),["prevent"]))},[o.isLoaded?It((I(),J("img",{key:0,class:Me(["Image cursor-pointer",{"img-responsive":r.element.IsResponsive}]),src:o.src,alt:o.alt,style:he([z(Wu)({borderRadius:r.element.BorderRadius,borderRadiusCard:r.theme.BorderRadiusCard,bodyBorderRadius:r.theme.BorderRadius,borderButtonRadius:r.theme.BorderRadiusButton,borderBannerRadius:r.theme.BorderRadiusBanner}),z(md)({border:r.element.Border,themeColors:r.theme.Colors}),{width:i.value,maxWidth:s.value},{verticalAlign:r.element.VerticalAlign}]),onLoad:n},null,46,ent)),[[z(Jx),({width:h,height:m})=>u("onImageSizeAdjusted",{Path:r.path,AdjustedHeight:m,AdjustedWidth:h})]]):Ue("",!0)],4))}}),nnt=Qe(tnt,[["__scopeId","data-v-67426858"]]),rnt=Wl,ont=t=>t.width===void 0?{}:rnt(t.width).Match({Auto:()=>({width:"auto"}),Pixel:e=>({width:e.Value+"px"}),Percentage:e=>({width:e.Value+"%"})}),int=t=>{switch(t){case"Auto":return{width:"auto"};case"FullWidth":return{width:"100%"};default:return ls(t)}},snt=Ze({__name:"OneLineList",props:{deps:{},theme:{},element:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onImageSizeAdjusted","onImageOriginalSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("table",{class:"oneLineList",style:he([{"border-spacing":"0","border-collapse":"collapse"},[z(int)(n.element.ContainerWidth)]])},[R("tbody",null,[R("tr",null,[(I(!0),J(ot,null,zn(n.element.Elements,(s,a)=>(I(),J("td",{key:a,class:"oneLineListItem",style:he([z(vw)({paddings:n.element.ItemPaddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),z(ont)({width:n.element.ItemWidth}),{lineHeight:"normal"}])},[(I(),et(kl,{key:a,deps:n.deps,theme:n.theme,element:s,path:[...n.path,"Elements",a],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:i[0]||(i[0]=l=>r("onImageSizeAdjusted",l)),onOnImageOriginalSizeAdjusted:i[1]||(i[1]=l=>r("onImageOriginalSizeAdjusted",l)),onOnElementClicked:i[2]||(i[2]=l=>r("onElementClicked",l)),onOnElementUpdatedEvent:i[3]||(i[3]=l=>r("onElementUpdatedEvent",l)),onOnElementRemoved:i[4]||(i[4]=l=>r("onElementRemoved",l))},null,8,["deps","theme","element","path","selectedElementPath","context"]))],4))),128))])])],4))}}),ant={style:{"border-spacing":"0","border-collapse":"collapse",width:"100%"}},lnt=Ze({__name:"Spacer",props:{theme:{},element:{}},emits:["onElementClicked"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("table",{class:"Spacer",width:"100%",style:{"border-spacing":"0","border-collapse":"collapse",width:"100%"},onClick:i[0]||(i[0]=()=>r("onElementClicked"))},[R("tbody",null,[R("tr",null,[R("td",{valign:"middle",style:he([{height:z(Sr)({paddingExpression:n.element.Height,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})+"px"}])},[R("table",ant,[R("tbody",null,[R("tr",null,[R("td",{style:he([[{borderTop:n.element.Weight+"px",borderStyle:n.element.Weight>0?"solid":"none",borderColor:z(Ll)({color:n.element.Color,themeColors:n.theme.Colors})}],{"font-size":"0","line-height":"0","border-bottom":"0","border-left":"0","border-right":"0"}])},"   ",4)])])])],4)])])]))}}),Dz={beforeMount(t,e){t.innerHTML=DX.sanitize(e.value)},beforeUpdate(t,e){t.innerHTML=DX.sanitize(e.value)}},unt=t=>({Match:e=>{switch(t.Discriminator){case"EmailBackgroundColor":return e.EmailBackgroundColor();case"BodyColor":return e.BodyColor();case"TitleColor":return e.TitleColor();case"HeadingColor":return e.HeadingColor();case"SubHeadingColor":return e.SubHeading();case"LargeTextColor":return e.LargeTextColor();case"NormalTextColor":return e.NormalTextColor();case"DescriptionTextColor":return e.DescriptionTextColor();case"PrimaryTextColor":return e.PrimaryTextColor();case"SecondaryTextColor":return e.SecondaryTextColor();case"ButtonTextColor":return e.ButtonTextColor();case"LinkColor":return e.LinkColor();case"PrimaryColor":return e.PrimaryColor();case"SecondaryColor":return e.SecondaryColor();case"CardBackgroundColor":return e.CardBackgroundColor();case"Custom":return e.Custom(t.CustomValue)}}}),PV=t=>unt(t.fontColor).Match({EmailBackgroundColor:()=>t.themeColors.EmailBackgroundColor,BodyColor:()=>t.themeColors.BodyColor,TitleColor:()=>t.themeColors.TitleColor,HeadingColor:()=>t.themeColors.HeadingColor,SubHeading:()=>t.themeColors.SubHeadingColor,LargeTextColor:()=>t.themeColors.LargeTextColor,NormalTextColor:()=>t.themeColors.NormalTextColor,DescriptionTextColor:()=>t.themeColors.DescriptionTextColor,PrimaryTextColor:()=>t.themeColors.PrimaryTextColor,SecondaryTextColor:()=>t.themeColors.SecondaryTextColor,LinkColor:()=>t.themeColors.LinkColor,PrimaryColor:()=>t.themeColors.PrimaryColor,SecondaryColor:()=>t.themeColors.SecondaryColor,CardBackgroundColor:()=>t.themeColors.CardBackgroundColor,ButtonTextColor:()=>t.themeColors.ButtonTextColor,Custom:e=>e}),cnt=t=>({Match:e=>{switch(t){case"None":return e.None();case"Underline":return e.Underline();case"LineThrough":return e.LineThrough()}}}),W7=t=>cnt(t.textDecoration).Match({None:()=>"none",Underline:()=>"underline",LineThrough:()=>"line-through"}),P0e=t=>({fontSize:t.customFontSettings.FontSize,lineHeight:t.customFontSettings.LineHeight,fontWeight:t.customFontSettings.IsBold?"bold":"normal",fontStyle:t.customFontSettings.IsItalic?"italic":"normal",textDecoration:W7({textDecoration:t.customFontSettings.Decoration}),fontFamily:t.customFontSettings.FontFamily,color:PV({fontColor:t.customFontSettings.FontColor,themeColors:t.themeColors})}),W0e=t=>({Match:e=>{switch(t.Discriminator){case"Heading":return e.Heading();case"Title":return e.Title();case"SubHeading":return e.SubHeading();case"LargeText":return e.LargeText();case"NormalText":return e.NormalText();case"DescriptionText":return e.DescriptionText();case"Link":return e.Link();case"Button":return e.Button();case"Custom":return e.Custom(t.CustomFontSettings);default:return ls(t.Discriminator)}}}),dnt=t=>({Match:e=>{switch(t.Discriminator){case"StyleLinkedColor":return e.FontStyle();case"EmailBackgroundColor":return e.EmailBackgroundColor();case"BodyColor":return e.BodyColor();case"TitleColor":return e.TitleColor();case"HeadingColor":return e.HeadingColor();case"SubHeadingColor":return e.SubHeading();case"LargeTextColor":return e.LargeTextColor();case"NormalTextColor":return e.NormalTextColor();case"DescriptionTextColor":return e.DescriptionTextColor();case"PrimaryTextColor":return e.PrimaryTextColor();case"SecondaryTextColor":return e.SecondaryTextColor();case"ButtonTextColor":return e.ButtonTextColor();case"LinkColor":return e.LinkColor();case"PrimaryColor":return e.PrimaryColor();case"SecondaryColor":return e.SecondaryColor();case"CardBackgroundColor":return e.CardBackgroundColor();case"Custom":return e.Custom(t.CustomValue)}}}),hnt=t=>dnt(t.fontStyleColor).Match({FontStyle:()=>W0e(t.fontStyle).Match({Heading:()=>t.themeColors.HeadingColor,Title:()=>t.themeColors.TitleColor,SubHeading:()=>t.themeColors.SubHeadingColor,LargeText:()=>t.themeColors.LargeTextColor,NormalText:()=>t.themeColors.NormalTextColor,DescriptionText:()=>t.themeColors.DescriptionTextColor,Button:()=>t.themeColors.ButtonTextColor,Link:()=>t.themeColors.LinkColor,Custom:e=>Ll({color:e.FontColor,themeColors:t.themeColors})}),EmailBackgroundColor:()=>t.themeColors.EmailBackgroundColor,BodyColor:()=>t.themeColors.BodyColor,TitleColor:()=>t.themeColors.TitleColor,HeadingColor:()=>t.themeColors.HeadingColor,SubHeading:()=>t.themeColors.SubHeadingColor,LargeTextColor:()=>t.themeColors.LargeTextColor,NormalTextColor:()=>t.themeColors.NormalTextColor,DescriptionTextColor:()=>t.themeColors.DescriptionTextColor,PrimaryTextColor:()=>t.themeColors.PrimaryTextColor,SecondaryTextColor:()=>t.themeColors.SecondaryTextColor,LinkColor:()=>t.themeColors.LinkColor,PrimaryColor:()=>t.themeColors.PrimaryColor,SecondaryColor:()=>t.themeColors.SecondaryColor,CardBackgroundColor:()=>t.themeColors.CardBackgroundColor,ButtonTextColor:()=>t.themeColors.ButtonTextColor,Custom:e=>e}),H0e=["Arial","Georgia","Tahoma","TimesNewRoman","Verdana"],Az={Arial:"Arial",Georgia:"Georgia",Tahoma:"Tahoma",TimesNewRoman:"Times New Roman",Verdana:"Verdana"},H7=t=>({fontSize:t.fontSize+"px",lineHeight:t.lineHeight+"px",fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:Az[t.fontFamily],textDecoration:t.textDecoration,color:t.color}),z7=t=>{const e=n=>({fontSize:n.FontSize,lineHeight:n.LineHeight,fontWeight:n.IsBold?"bold":"normal",fontStyle:n.IsItalic?"italic":"normal",fontFamily:t.fontFamily,textDecoration:W7({textDecoration:n.Decoration}),color:hnt({fontStyleColor:t.fontStyle.FontColor,fontStyle:t.fontStyle,themeColors:t.themeColors})});return W0e(t.fontStyle).Match({Heading:()=>e(t.themeDefinedFontSettings.Heading),Title:()=>e(t.themeDefinedFontSettings.Title),SubHeading:()=>e(t.themeDefinedFontSettings.SubHeading),LargeText:()=>e(t.themeDefinedFontSettings.LargeText),NormalText:()=>e(t.themeDefinedFontSettings.NormalText),DescriptionText:()=>e(t.themeDefinedFontSettings.DescriptionText),Link:()=>e(t.themeDefinedFontSettings.Link),Button:()=>e(t.themeDefinedFontSettings.Button),Custom:n=>P0e({customFontSettings:n,themeColors:t.themeColors})})},mnt=t=>({Match:e=>{switch(t.Discriminator){case"Theme":return e.Theme();case"Custom":return e.Custom(t.CustomValue);default:return ls(t.Discriminator)}}}),fnt=t=>mnt(t.buttonPaddings).Match({Theme:()=>({TopBottom:t.themeButtonPaddings.TopBottom,LeftRight:t.themeButtonPaddings.LeftRight}),Custom:e=>({TopBottom:e.TopBottom,LeftRight:e.LeftRight})}),pnt=["align"],gnt={class:"Button"},Cnt=["href"],ynt=Ze({__name:"ButtonVue",props:{deps:{},theme:{},element:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onElementClicked"],setup(t,{emit:e}){const n=t,r=q(()=>H7(z7({fontFamily:n.theme.FontFamily,fontStyle:n.element.TextStyle,themeDefinedFontSettings:n.theme.FontSettingsPresets,themeColors:n.theme.Colors}))),o=q(()=>c_({borderColor:n.element.Border.Left.Color,themeColors:n.theme.Colors})),i=q(()=>fnt({buttonPaddings:n.element.Paddings,themeButtonPaddings:n.theme.ButtonPaddings})),s=q(()=>Ll({color:n.element.BackgroundColor,themeColors:n.theme.Colors})),a=q(()=>{switch(n.element.ContentAlign){case"Center":return"center";case"Left":return"left";case"Right":return"right";default:return"center"}}),l=Mt({href:"",text:"",isLoading:!0}),u=n.deps.stringExpressionEvaluator,c=()=>{Promise.all([u({stringExpression:n.element.HRef,context:n.context}),u({stringExpression:n.element.Text,context:n.context})]).then(([h,m])=>{l.href=h,l.text=m,l.isLoading=!1})};c(),mn(()=>[n.element.HRef,n.element.Text,n.context],()=>c());const d=e;return(h,m)=>(I(),J("table",{style:{"border-spacing":"0","border-collapse":"collapse",width:"100%"},onClick:m[1]||(m[1]=wr(f=>d("onElementClicked"),["prevent"]))},[R("tbody",null,[R("tr",null,[R("td",{align:a.value},[R("div",gnt,[R("a",{style:he([{display:"block","text-decoration":"none"},[r.value]]),href:l.href,onClick:m[0]||(m[0]=wr(()=>{},["prevent"]))},[R("table",{style:he([[{backgroundColor:s.value},z(Wu)({borderRadius:n.element.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner}),{width:n.element.FullWidth?"100%":"auto"},z(md)({border:n.element.Border,themeColors:t.theme.Colors}),{borderColor:o.value}],{"text-align":"center","border-spacing":"0","border-collapse":"separate"}])},[R("tbody",null,[R("tr",null,[R("td",{align:"center",style:he([{"line-height":"normal"},[{paddingTop:i.value.TopBottom+"px",paddingBottom:i.value.TopBottom+"px",paddingLeft:i.value.LeftRight+"px",paddingRight:i.value.LeftRight+"px"}]])},[It(R("p",{class:"user-select-none",style:he([r.value])},null,4),[[z(Dz),l.text]])],4)])])],4)],12,Cnt)])],8,pnt)])])]))}}),bnt=Qe(ynt,[["__scopeId","data-v-f2906df7"]]),vnt=["href"],Tnt=Ze({__name:"SpanText",props:{deps:{},theme:{},element:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onElementClicked"],setup(t,{emit:e}){const n=t,r=n.deps.stringExpressionEvaluator,o=q(()=>{const u=z7({fontFamily:n.theme.FontFamily,fontStyle:n.element.Style,themeDefinedFontSettings:n.theme.FontSettingsPresets,themeColors:n.theme.Colors});if(n.element.Style.Discriminator==="Custom"){const c=P0e({customFontSettings:n.element.Style.CustomFontSettings,themeColors:n.theme.Colors});return{...c,fontSize:c.fontSize+"px",lineHeight:c.lineHeight+"px",minHeight:n.element.MinNumberOfLines*u.lineHeight+"px"}}return{minHeight:n.element.MinNumberOfLines*u.lineHeight+"px",color:u.color}}),i=Mt({href:"",text:"",isLoading:!0}),s=u=>u.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;"),a=()=>{Promise.all([r({stringExpression:n.element.HRef,context:n.context}),r({stringExpression:n.element.Text,context:n.context})]).then(([u,c])=>{i.href=u,i.text=s(c),i.isLoading=!1})};a(),mn(()=>[n.context,n.element.HRef,n.element.Text],()=>a());const l=e;return(u,c)=>n.element.IsLink?It((I(),J("a",{key:0,href:i.href,class:Me(["SpanText cursor-pointer user-select-none",n.element.Style.Discriminator]),style:he([{margin:"0"},[o.value,z(qx)({contentAlign:n.element.ContentAlign})]]),onClick:c[0]||(c[0]=wr(()=>l("onElementClicked"),["prevent"]))},null,14,vnt)),[[z(Dz),i.text]]):It((I(),J("span",{key:1,class:Me(["SpanText cursor-pointer user-select-none",n.element.Style.Discriminator]),style:he([{margin:"0"},[o.value,z(qx)({contentAlign:n.element.ContentAlign})]]),onClick:c[1]||(c[1]=wr(()=>l("onElementClicked"),["prevent"]))},null,6)),[[z(Dz),i.text]])}}),Fnt=Qe(Tnt,[["__scopeId","data-v-f6595f5e"]]),us=t=>({fontSize:t.themeFontSettings.FontSize,lineHeight:t.themeFontSettings.LineHeight,fontWeight:t.themeFontSettings.IsBold?"bold":"normal",fontStyle:t.themeFontSettings.IsItalic?"italic":"normal",fontFamily:t.fontFamily,textDecoration:W7({textDecoration:t.themeFontSettings.Decoration}),color:t.themeColor}),xnt={class:"bootstrap-styles modal fade show d-block position-absolute"},Snt={class:"bootstrap-styles modal-dialog modal-dialog-centered"},wnt={class:"bootstrap-styles modal-content border rounded-3 shadow","data-test":"modal-window__content"},knt={class:"bootstrap-styles modal-header p-0"},Ent={class:"bootstrap-styles container-fluid border-bottom g-0"},Rnt={class:"bootstrap-styles d-flex justify-content-between align-items-center px-11 py-7"},_nt={class:"bootstrap-styles modal-title border-0","data-test":"modal-window__header-text"},Dnt={class:"bootstrap-styles modal-body p-0","data-test":"modal-window__body"},Ant={class:"bootstrap-styles modal-footer p-0 g-0"},$nt={class:"bootstrap-styles container-fluid border-top"},Nnt={class:"bootstrap-styles d-flex justify-content-end py-8 px-11"},Bnt={class:"bootstrap-styles col-6 d-flex justify-content-end","data-test":"modal-window__footer-actions"},Lnt=Ze({__name:"ModalWindow",props:{headerText:{}},emits:["close"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("div",xnt,[R("div",{class:"bootstrap-styles modal-blur d-block position-fixed top-0 left-0 w-100 vh-100","data-test":"modal-window__outside",onClick:i[0]||(i[0]=s=>r("close"))}),R("div",Snt,[R("div",wnt,[R("div",knt,[R("div",Ent,[R("div",Rnt,[R("h5",_nt,en(n.headerText),1),R("button",{type:"button","aria-label":"Close","data-bs-dismiss":"modal","data-test":"modal-window__close-button",onClick:i[1]||(i[1]=s=>r("close"))},[...i[2]||(i[2]=[R("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[R("path",{d:"M3 3L13 13",stroke:"var(--gray-500)"}),R("path",{d:"M13 3L3 13",stroke:"var(--gray-500)"})],-1)])])])])]),R("div",Dnt,[M0(o.$slots,"body",{},void 0,!0)]),R("div",Ant,[R("div",$nt,[R("div",Nnt,[R("div",Bnt,[M0(o.$slots,"footer-actions",{},void 0,!0)])])])])])])]))}}),z0e=Qe(Lnt,[["__scopeId","data-v-7a4aac23"]]),Vnt={cancelButton:"Cancel",applyButton:"Delete"},Mnt={cancelButton:"Отмена",applyButton:"Удалить"},yee=jn({en:Vnt,ru:Mnt}),Ont={class:"bootstrap-styles px-11 py-7 text-start"},Int=Ze({__name:"RemoveConfirmModalWindow",props:{headerText:{},deps:{}},emits:["cancel","confirmed"],setup(t,{emit:e}){const n=t,r=()=>{i("cancel")},o={cancelButton:yee({localeKey:n.deps.localeKey}).cancelButton,applyButton:yee({localeKey:n.deps.localeKey}).applyButton},i=e;return(s,a)=>(I(),et(z0e,{headerText:n.headerText,class:"remove-element-confirm-modal-window",onClose:a[2]||(a[2]=()=>r())},{body:wu(()=>[R("div",Ont,[M0(s.$slots,"body-content")])]),"footer-actions":wu(()=>[R("button",{class:"modal-footer__button bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-3 rounded-2 bg-blue-selected button__hover-blue-100 text-color-selected",onClick:a[0]||(a[0]=wr(l=>r(),["stop"]))},en(o.cancelButton),1),R("button",{class:"modal-footer__button bootstrap-styles d-flex justify-content-center align-center py-1 px-3 rounded-2 text-white cursor-pointer remove-element-confirm__button",onClick:a[1]||(a[1]=wr(l=>i("confirmed"),["stop"]))},en(o.applyButton),1)]),_:3},8,["headerText"]))}}),Pnt={removeWindowTitle:"Delete element",removeWindowDescription:"Are you sure you want to delete the text element?"},Wnt={removeWindowTitle:"Удаление элемента",removeWindowDescription:"Вы действительно хотите удалить элемент ?"},bee=jn({en:Pnt,ru:Wnt}),vee=t=>({type:"doc",content:t.Content.map(Hnt)}),Hnt=t=>"ParagraphNode"in t?K0e(t):"BulletListNode"in t?znt(t):"OrderedListNode"in t?jnt(t):"DataFieldNode"in t?U0e(t):ls(t),j0e=t=>({type:"listItem",content:t.Content.map(e=>"ParagraphNode"in e?K0e(e):"ImageNode"in e?q0e(e):ls(e))}),U0e=t=>({type:"dataField",marks:j7({textStyle:t.DataFieldNode.TextStyle,commonLinkMark:t.DataFieldNode.CommonLinkMark}),attrs:{stringExpression:t.DataFieldNode.StringExpression}}),znt=t=>({type:"bulletList",content:t.BulletListNode.Content.map(j0e),attrs:{themeName:t.BulletListNode.ListStyle}}),jnt=t=>({type:"orderedList",content:t.OrderedListNode.Content.map(j0e),attrs:{themeName:t.OrderedListNode.ListStyle}}),K0e=t=>{const e=t.ParagraphNode.Content[0],n=t.ParagraphNode.Content.length===1&&e!==void 0&&"HardBreakNode"in e;return{type:"paragraph",attrs:{themeName:t.ParagraphNode.ThemeName,contentAlign:t.ParagraphNode.ContentAlign},content:n?[]:t.ParagraphNode.Content.map(Unt)}},Unt=t=>"TextNode"in t?Knt(t):"HardBreakNode"in t?Znt():"ImageNode"in t?q0e(t):"DataFieldNode"in t?U0e(t):ls(t),j7=t=>{const e=[];return t.textStyle&&e.push(Xnt(t.textStyle)),t.commonLinkMark&&e.push(Qnt(t.commonLinkMark)),e.filter(n=>n!==void 0)},Knt=t=>({type:"text",text:t.TextNode.Text,marks:j7({textStyle:t.TextNode.TextStyle,commonLinkMark:t.TextNode.CommonLinkMark})}),qnt=t=>{switch(t){case"Normal":return"normal";case"Bold":return"bold";default:return"normal"}},Jnt=t=>{switch(t){case"Normal":return"normal";case"Italic":return"italic";default:return"normal"}},Gnt=t=>{switch(t){case"None":return"none";case"Uppercase":return"uppercase";default:return"none"}},Ynt=t=>{switch(t){case"None":return"none";case"Underline":return"underline";case"LineThrough":return"line-through";default:return"none"}},Xnt=t=>({type:"textStyle",attrs:{themeName:t.ThemeName,color:t.Style.Color,fontWeight:t.Style.FontWeight?qnt(t.Style.FontWeight):void 0,fontStyle:t.Style.FontStyle?Jnt(t.Style.FontStyle):void 0,fontSize:t.Style.FontSize?t.Style.FontSize+"px":void 0,lineHeight:t.Style.LineHeight?t.Style.LineHeight+"px":void 0,fontFamily:t.Style.FontFamily,textTransform:t.Style.TextTransform?Gnt(t.Style.TextTransform):void 0,textDecoration:t.Style.TextDecoration?Ynt(t.Style.TextDecoration):void 0}}),Qnt=t=>Wl(t).Match({LinkMark:e=>ert({LinkMark:e}),UnsubscribeLinkMark:()=>trt()}),Znt=()=>({type:"hardBreak"}),q0e=t=>({type:"image",attrs:{src:t.ImageNode.Src,alt:t.ImageNode.Alt,isRetina:t.ImageNode.IsRetina,width:t.ImageNode.Width,height:t.ImageNode.Height},marks:j7({commonLinkMark:t.ImageNode.CommonLinkMark})}),ert=t=>({type:"link",attrs:{href:t.LinkMark.Href}}),trt=()=>({type:"unsubscribeLink"}),J0e=tc.create({name:"textTransform",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{textTransform:{default:"none",parseHTML:t=>t.style.textTransform,renderHTML:t=>t.textTransform?{style:`text-transform: ${t.textTransform}`}:{}}}}]},addCommands(){return{setTextTransform:t=>({chain:e})=>e().setMark("textStyle",{textTransform:t}).run(),unsetTextTransform:()=>({chain:t,state:e})=>{const{from:n,to:r,$from:o}=e.selection;return e.doc.textBetween(n,r," ").length?t().setMark("textStyle",{textTransform:"none"}).run():t().setTextSelection({from:o.pos-o.nodeBefore.nodeSize,to:o.pos+o.nodeAfter.nodeSize}).setMark("textStyle",{textTransform:"none"}).focus().run()}}},addKeyboardShortcuts(){const t=e=>e.isUppercase?this.editor.commands.unsetTextTransform():this.editor.commands.setTextTransform("uppercase");return{"Mod-Shift-u":()=>{const e=this.editor.isActive("textStyle",{textTransform:"uppercase"});return t({isUppercase:e})},"Mod-Shift-U":()=>{const e=this.editor.isActive("textStyle",{textTransform:"uppercase"});return t({isUppercase:e})}}}}),nrt=tc.create({name:"fontSize",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontSize:{default:null,parseHTML:t=>t.style.fontSize.replace(/['"]+/g,""),renderHTML:t=>t.fontSize?{style:`font-size: ${t.fontSize}`}:{}}}}]},addCommands(){return{setFontSize:t=>({chain:e})=>e().setMark("textStyle",{fontSize:t+"px"}).run(),unsetFontSize:()=>({chain:t})=>t().setMark("textStyle",{fontSize:null}).removeEmptyTextStyle().run()}}}),rrt=tc.create({name:"lineHeight",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{lineHeight:{default:null,parseHTML:t=>t.style.lineHeight.replace(/['"]+/g,""),renderHTML:t=>t.lineHeight?{style:`line-height: ${t.lineHeight}`}:{}}}}]},addCommands(){return{setLineHeight:t=>({chain:e})=>e().setMark("textStyle",{lineHeight:t+"px"}).run(),resetLineHeight:()=>({chain:t})=>t().setMark("textStyle",{lineHeight:null}).run()}}}),ort=t=>pn.create({name:"themeFontStyles",priority:1e3,addOptions(){return{types:["textStyle","bulletList","orderedList","paragraph"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{themeName:{default:t,parseHTML:e=>e.getAttribute("data-theme"),renderHTML:e=>e.themeName?{"data-theme":e.themeName,class:e.themeName}:{"data-theme":t,class:e.themeName}}}}]},addCommands(){return{setThemeSettings:e=>({chain:n,state:r})=>{const{$from:o}=r.selection,i=o.parent,s=o.index();return i.child(s).type.name==="image"?!1:n().setMark("textStyle",{themeName:e}).run()},applySiblingNodeThemeSettings:()=>({chain:e,state:n})=>{const{from:r,to:o,$from:i}=n.selection,s=i.parent,a=i.index(),l=i.node(i.depth)?.type.name==="dataField"||s.maybeChild(a)?.type.name==="dataField",u=s.child(a).type.name==="image",c=f=>{const p="NormalText",g=f.index>0?s.child(f.index-1):void 0,y=f.index+1<s.childCount?s.child(f.index+1):void 0,b=g??y;if(b){const F=b.marks.find(T=>T.type.name==="textStyle");if(F)return F.attrs.themeName}return p};if(l){const f=c({index:a});return e().unsetMark("textStyle",{extendEmptyMarkRange:!0}).setThemeSettings(f).run()}if(u)return!1;const d=c({index:a}),h=i.nodeBefore?i.pos-i.nodeBefore.nodeSize:r,m=i.nodeAfter?i.pos+i.nodeAfter.nodeSize:o;return e().setTextSelection({from:h,to:m}).setThemeSettings(d).run()}}},addProseMirrorPlugins(){return[new Xn({key:new Nr("syncBlockTheme"),appendTransaction:(e,n,r)=>{const o=r.tr;let i=!1;return r.doc.descendants((s,a)=>{if(s.type.name==="bulletList"||s.type.name==="orderedList"){const l=s.firstChild?.firstChild?.firstChild;if(l){const u=l.marks.find(c=>c.type.name==="textStyle")?.attrs.themeName;u&&s.attrs.themeName!==u&&(o.setNodeMarkup(a,void 0,{...s.attrs,themeName:u}),i=!0)}}if(s.type.name==="paragraph"){const l=s.firstChild;if(l){const u=l.marks.find(c=>c.type.name==="textStyle")?.attrs.themeName;u&&s.attrs.themeName!==u&&(o.setNodeMarkup(a,void 0,{...s.attrs,themeName:u}),i=!0)}}}),i?o:null}})]}}),irt=tc.create({name:"fontWeight",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontWeight:{default:null,parseHTML:t=>t.style.fontWeight,renderHTML:t=>t.fontWeight?{style:`font-weight: ${t.fontWeight}`}:{}}}}]},addCommands(){return{setFontWeight:t=>({chain:e})=>e().setMark("textStyle",{fontWeight:t}).run(),unsetFontWeight:()=>({chain:t,state:e})=>{const{from:n,to:r,$from:o}=e.selection;return e.doc.textBetween(n,r," ").length?t().setMark("textStyle",{fontWeight:"normal"}).run():t().setTextSelection({from:o.pos-o.nodeBefore.nodeSize,to:o.pos+o.nodeAfter.nodeSize}).setMark("textStyle",{fontWeight:"normal"}).focus().run()},resetFontWeight:()=>({chain:t})=>t().setMark("textStyle",{fontWeight:null}).removeEmptyTextStyle().run()}},addKeyboardShortcuts(){const t=e=>e.isBold?this.editor.commands.unsetFontWeight():this.editor.commands.setFontWeight("bold");return{"Mod-b":()=>{const e=this.editor.isActive("textStyle",{fontWeight:"bold"});return t({isBold:e})},"Mod-B":()=>{const e=this.editor.isActive("textStyle",{fontWeight:"bold"});return t({isBold:e})}}}}),srt=tc.create({name:"fontStyle",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontStyle:{default:null,parseHTML:t=>t.style.fontStyle,renderHTML:t=>t.fontStyle?{style:`font-style: ${t.fontStyle}`}:{}}}}]},addCommands(){return{setFontStyle:t=>({chain:e})=>e().setMark("textStyle",{fontStyle:t}).run(),unsetFontStyle:()=>({chain:t,state:e})=>{const{from:n,to:r,$from:o}=e.selection;return e.doc.textBetween(n,r," ").length?t().setMark("textStyle",{fontStyle:"normal"}).run():t().setTextSelection({from:o.pos-o.nodeBefore.nodeSize,to:o.pos+o.nodeAfter.nodeSize}).setMark("textStyle",{fontStyle:"normal"}).focus().run()},resetFontStyle:()=>({chain:t})=>t().setMark("textStyle",{fontStyle:null}).removeEmptyTextStyle().run()}},addKeyboardShortcuts(){const t=e=>e.isItalic?this.editor.commands.unsetFontStyle():this.editor.commands.setFontStyle("italic");return{"Mod-i":()=>{const e=this.editor.isActive("textStyle",{fontStyle:"italic"});return t({isItalic:e})},"Mod-I":()=>{const e=this.editor.isActive("textStyle",{fontStyle:"italic"});return t({isItalic:e})}}}}),U7=tc.create({name:"unsubscribeLink",priority:1e3,addOptions(){return{HTMLAttributes:{"data-type":"unsubscribe-link",class:"rich-text__unsubscribe-link"}}},parseHTML(){return[{tag:'span[data-type="unsubscribe-link"]'}]},renderHTML({HTMLAttributes:t}){return["span",ki(this.options.HTMLAttributes,t),0]},addCommands(){return{setUnsubscribeLink:()=>({chain:t})=>t().setMark("unsubscribeLink").focus().run(),unsetUnsubscribeLink:()=>({chain:t,state:e})=>{const{from:n,to:r}=e.selection,o=e.doc.textBetween(n,r," ");return e.doc.nodeAt(n)?.type.name==="image"?t().unsetMark("unsubscribeLink").focus().run():o.length?t().setTextSelection({from:n,to:n+o.length}).unsetMark("unsubscribeLink").focus().run():t().unsetMark("unsubscribeLink",{extendEmptyMarkRange:!0}).focus().run()}}}}),art=tc.create({name:"textDecoration",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{textDecoration:{parseHTML:t=>t.style.textDecoration,renderHTML:t=>t.textDecoration?{style:`text-decoration: ${t.textDecoration}`}:{}}}}]},addCommands(){return{setTextDecoration:t=>({chain:e})=>e().setMark("textStyle",{textDecoration:t}).run(),unsetTextDecoration:()=>({chain:t,state:e})=>{const{from:n,to:r,$from:o}=e.selection;return e.doc.textBetween(n,r," ").length?t().setMark("textStyle",{textDecoration:"none"}).run():t().setTextSelection({from:o.pos-o.nodeBefore.nodeSize,to:o.pos+o.nodeAfter.nodeSize}).setMark("textStyle",{textDecoration:"none"}).focus().run()}}},addKeyboardShortcuts(){const t=n=>n.isUnderline?this.editor.commands.unsetTextDecoration():this.editor.commands.setTextDecoration("underline"),e=n=>n.isLineThrough?this.editor.commands.unsetTextDecoration():this.editor.commands.setTextDecoration("line-through");return{"Mod-Shift-s":()=>{const n=this.editor.isActive("textStyle",{textDecoration:"line-through"});return e({isLineThrough:n})},"Mod-u":()=>{const n=this.editor.isActive("textStyle",{textDecoration:"underline"});return t({isUnderline:n})},"Mod-U":()=>{const n=this.editor.isActive("textStyle",{textDecoration:"underline"});return t({isUnderline:n})}}}}),lrt=t=>{if(!t.content)throw new Error("Invalid document: content is missing");return{Content:t.content.map(e=>{switch(e.type){case"paragraph":return G0e(e);case"bulletList":return drt(e);case"orderedList":return hrt(e);default:throw new Error(`Unknown node type: ${e.type}`)}})}},G0e=t=>t.content?{ParagraphNode:{ThemeName:t.attrs?t.attrs.themeName:void 0,ContentAlign:t.attrs?t.attrs.contentAlign:void 0,Content:t.content.map(e=>{switch(e.type){case"text":return urt(e);case"image":return X0e(e);case"hardBreak":return Tee();case"dataField":return crt(e);default:throw new Error(`Unknown node type: ${e.type}`)}})}}:{ParagraphNode:{ThemeName:t.attrs?t.attrs.themeName:void 0,ContentAlign:t.attrs?t.attrs.contentAlign:void 0,Content:[Tee()]}},K7=t=>{const e=t?t.find(r=>r.type==="textStyle"):void 0,n=t?t.find(r=>r.type==="link"||r.type==="unsubscribeLink"):void 0;return{TextStyle:e?yrt(e):void 0,CommonLinkMark:n?brt(n):void 0}},urt=t=>{if(typeof t.text!="string")throw new Error("Invalid text node: text is missing or not a string");const{TextStyle:e,CommonLinkMark:n}=K7(t.marks);return{TextNode:{Text:t.text,TextStyle:e,CommonLinkMark:n}}},Tee=()=>({HardBreakNode:{}}),crt=t=>{if(!t.attrs)throw new Error("Invalid variable node: attrs is missing");const{TextStyle:e,CommonLinkMark:n}=K7(t.marks);return{DataFieldNode:{StringExpression:t.attrs.stringExpression,TextStyle:e,CommonLinkMark:n}}},drt=t=>{if(!t.content)throw new Error("Invalid bulletList: content is missing");return{BulletListNode:{ListStyle:t.attrs?t.attrs.themeName:void 0,Content:t.content.map(Y0e)}}},hrt=t=>{if(!t.content)throw new Error("Invalid orderedList: content is missing");return{OrderedListNode:{ListStyle:t.attrs?t.attrs.themeName:void 0,Content:t.content.map(Y0e)}}},Y0e=t=>{if(!t.content)throw new Error("Invalid listItem: content is missing");return{Content:t.content.map(e=>{switch(e.type){case"paragraph":return G0e(e);case"image":return X0e(e);default:throw new Error(`Unknown node type: ${e.type}`)}})}},X0e=t=>{if(!t.attrs)throw new Error("Invalid image node: attrs is missing");const{CommonLinkMark:e}=K7(t.marks);return{ImageNode:{Src:t.attrs.src,Alt:t.attrs.alt,Width:t.attrs.width,Height:t.attrs.height,IsRetina:t.attrs.isRetina,CommonLinkMark:e}}},mrt=t=>t==="bold"?"Bold":"Normal",frt=t=>t==="italic"?"Italic":"Normal",prt=t=>t,grt=t=>{switch(t){case"uppercase":return"Uppercase";default:return"None"}},Crt=t=>{switch(t){case"underline":return"Underline";case"line-through":return"LineThrough";default:return"None"}},Fee=t=>{const e=t.replace(/px$/,"");return parseInt(e,10)},yrt=t=>{if(!t.attrs)throw new Error("Invalid textStyle mark: attrs is missing");return{ThemeName:t.attrs.themeName,Style:{Color:t.attrs.color?t.attrs.color:void 0,FontWeight:t.attrs.fontWeight?mrt(t.attrs.fontWeight):void 0,FontStyle:t.attrs.fontStyle?frt(t.attrs.fontStyle):void 0,FontSize:t.attrs.fontSize?Fee(t.attrs.fontSize):void 0,LineHeight:t.attrs.lineHeight?Fee(t.attrs.lineHeight):void 0,FontFamily:t.attrs.fontFamily?prt(t.attrs.fontFamily):void 0,TextTransform:t.attrs.textTransform?grt(t.attrs.textTransform):void 0,TextDecoration:t.attrs.textDecoration?Crt(t.attrs.textDecoration):void 0}}},brt=t=>{switch(t.type){case"link":{if(!t.attrs)throw new Error("Invalid link mark: attrs.href is missing");return{LinkMark:{Href:t.attrs.href}}}case"unsubscribeLink":return{UnsubscribeLinkMark:{}};default:return}},Q0e=t=>{if(!t)return null;if(/^#([A-Fa-f0-9]{3}){1,2}$/.test(t))return t;if(t.startsWith("rgb")){const n=t.replace(/[^\d,.]/g,"").split(","),r=n[0]?parseInt(n[0]):0,o=n[1]?parseInt(n[1]):0,i=n[2]?parseInt(n[2]):0;return`#${(1<<24|r<<16|o<<8|i).toString(16).slice(1)}`}if(t.startsWith("hsl")){const n=document.createElement("div");n.style.color=t,document.body.appendChild(n);const r=getComputedStyle(n).color;return document.body.removeChild(n),Q0e(r)}const e=document.createElement("canvas").getContext("2d");return e?(e.fillStyle=t,e.fillStyle):null},vrt=t=>pn.create({name:"color",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{color:{default:null,parseHTML:e=>{const n=e.getAttribute("data-theme-color")??"Custom",r=Q0e(e.style.color)??"#000000";return{Discriminator:n,CustomValue:r}},renderHTML:e=>{if(!e.color)return{};const n=PV({fontColor:e.color,themeColors:t.themeColors});return e.color.Discriminator==="Custom"?{"data-theme-color":e.color.Discriminator,style:`color: ${n}`}:{"data-theme-color":e.color.Discriminator}}}}}]},addCommands(){return{setColor:e=>({chain:n})=>n().setMark("textStyle",{color:e}).run(),unsetColor:()=>({chain:e})=>e().setMark("textStyle",{color:null}).removeEmptyTextStyle().run()}}}),Trt=pn.create({name:"fontFamily",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontFamily:{default:null,parseHTML:t=>{const e=t.style.fontFamily.split(",").map(n=>n.trim()).map(n=>n.replace(/^['"]|['"]$/g,"")).map(n=>n.replace(/ /g,""));return H0e.find(n=>e.includes(n))||null},renderHTML:t=>t.fontFamily?{style:`font-family: ${t.fontFamily}`}:{}}}}]},addCommands(){return{setFontFamily:t=>({chain:e})=>e().setMark("textStyle",{fontFamily:t}).run(),unsetFontFamily:()=>({chain:t})=>t().setMark("textStyle",{fontFamily:null}).removeEmptyTextStyle().run()}}}),Z0e=t=>Wl(t),Frt=t=>Il.create({name:"dataField",group:"inline",marks:"_",inline:!0,atom:!0,selectable:!0,addAttributes:()=>({stringExpression:{default:null,parseHTML:e=>JSON.parse(e.getAttribute("data-field")),renderHTML:e=>({"data-field":JSON.stringify(e.stringExpression)})}}),parseHTML:()=>[{tag:"data-field[data-field]"}],renderHTML:({node:e,HTMLAttributes:n})=>{const r=e.attrs.stringExpression,o=Z0e(r).Match({ContextValueExpression:()=>"contextValue",ContextValueExpressionWithFallback:()=>"contextValueWithFallback",ConstValueExpression:i=>i.Value,TruncateValueExpression:()=>"truncate",ConcatStringExpressions:()=>"concat",NumberToStringExpression:()=>"numberToString",DataSource:i=>t.dataSourceFieldNameDelegate({dataSource:i}),UnsubscribeUrlExpression:()=>"unsubscribeUrl",RecipientEmailAddressExpression:()=>"recipientEmailAddress"});return["data-field",ki(n,{class:"rich-text__variable","data-field":JSON.stringify(e.attrs.stringExpression),contenteditable:"false"}),o]},addCommands(){return{setVariable:e=>({chain:n,state:r})=>{const o=r.selection.$from.marks(),i=o.map(s=>({type:s.type.name,attrs:s.attrs}));return n().insertContent({type:this.name,attrs:{stringExpression:e,selectedMarks:o},marks:i}).focus().run()}}}}),ebe=t=>new Promise((e,n)=>{const r=new Image;r.onload=()=>{e({width:r.naturalWidth,height:r.naturalHeight})},r.onerror=n,r.src=t}),tbe=Il.create({name:"image",addOptions(){return{inline:!0,allowBase64:!1,HTMLAttributes:{}}},inline(){return this.options.inline},group(){return this.options.inline?"inline":"block"},draggable:!0,addAttributes(){return{src:{default:null},alt:{default:null},width:{default:null},height:{default:null},isRetina:{default:!1}}},parseHTML(){return[{tag:this.options.allowBase64?"img[src]":'img[src]:not([src^="data:"])'}]},renderHTML({HTMLAttributes:t}){return["img",ki(this.options.HTMLAttributes,{src:t.src,alt:t.alt,title:t.title,width:t.isRetina?t.width/2:t.width,height:t.isRetina?t.height/2:t.height,isRetina:t.isRetina})]},addCommands(){return{setImage:t=>({commands:e})=>e.insertContent({type:this.name,attrs:t})}},addInputRules(){return[RKe({find:/(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/,type:this.type,getAttributes:t=>{const[,,e,n,r]=t;return{src:n,alt:e,title:r}}})]},addProseMirrorPlugins(){return[new Xn({view:t=>((async()=>{const{state:e,dispatch:n}=t;e.doc.descendants((r,o)=>{if(r.type.name===this.name){const{src:i,width:s,height:a}=r.attrs;i&&(!s||!a)&&ebe(i).then(l=>{const u=e.tr.setNodeMarkup(o,void 0,{...r.attrs,width:l.width,height:l.height});n(u)})}})})(),{})})]}}),xrt=t=>pn.create({name:"paragraphContentAlign",addOptions(){return{defaultContentAlign:"Left"}},addGlobalAttributes(){return[{types:["paragraph"],attributes:{contentAlign:{default:t.fallbackContentAlign,parseHTML:e=>{const n=e.style.textAlign;return n===""?t.fallbackContentAlign:n==="left"?"Left":n==="center"?"Center":n==="right"?"Right":t.fallbackContentAlign},renderHTML:e=>{const n=e.contentAlign||this.options.defaultContentAlign||"Left";return{style:`text-align: ${{Left:"left",Center:"center",Right:"right"}[n]}`}}}}}]},addCommands(){return{setParagraphContentAlign:e=>({state:n,tr:r})=>{const{$from:o}=n.selection,i=o.parent;if(i.type.name!=="paragraph")return!1;const s=o.before(o.depth);return r.setNodeMarkup(s,void 0,{...i.attrs,contentAlign:e}),!0}}}}),Srt=t=>[pqe,tJe,fqe,RV.configure({mergeNestedSpanStyles:!0}),Pqe,Frt({dataSourceFieldNameDelegate:t.dataSourceFieldNameDelegate}),mqe.configure({className:"has-focus",mode:"all"}),d7.configure({keepMarks:!0,keepAttributes:!0}),m7.configure({keepMarks:!0,keepAttributes:!0}),YCe,eJe.configure({HTMLAttributes:{class:"hard-break"}}),c7.configure({HTMLAttributes:{class:"rich-text__link"},openOnClick:!1}),tbe.configure({inline:!0,HTMLAttributes:{class:"rich-text__image"}}),vrt({themeColors:t.themeColors}),ort(t.initialThemeName),irt,srt,nrt,rrt,J0e,art,U7,Trt,xrt({fallbackContentAlign:t.fallbackContentAlign})],wrt=t=>lrt(t.editor.getJSON()),krt=Ze({__name:"SelectItemColor",props:{isActive:{type:Boolean},color:{},label:{}},emits:["click"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("li",{class:Me(["bootstrap-styles dropdown-item p-0 user-select-none",{active:n.isActive}])},[R("span",{class:"bootstrap-styles d-block py-1 px-3 text-decoration-none text-reset cursor-pointer d-flex align-items-center justify-content-start",onClick:i[0]||(i[0]=s=>r("click"))},[R("i",{class:"bootstrap-styles input__color_selection d-block overflow-hidden me-2",style:he([{border:"1px solid rgba(0, 0, 0, 0.10)"},[{background:n.color}]])},null,4),rw(" "+en(n.label),1)])],2))}}),Ert={colorLabels:{none:"None",styleLinkedColor:"Link to style",emailBackgroundColor:"Email background",bodyColor:"Email body",primaryColor:"Primary color",secondaryColor:"Secondary color",primaryTextColor:"Primary text",secondaryTextColor:"Secondary text",cardBackgroundColor:"Product card color",buttonTextColor:"Buttons",titleColor:"Title",headingColor:"Heading",subHeadingColor:"Subheading",largeTextColor:"Large text",normalTextColor:"Text",descriptionTextColor:"Description",linkColor:"Link",custom:"Custom"}},Rrt={colorLabels:{none:"Нет",styleLinkedColor:"Связать со стилем",emailBackgroundColor:"Фон письма",bodyColor:"Тело письма",primaryColor:"Основной цвет",secondaryColor:"Вторичный цвет",primaryTextColor:"Текст на основном цвете",secondaryTextColor:"Текст на вторичном цвете",cardBackgroundColor:"Цвет карточек товара",buttonTextColor:"Кнопки",titleColor:"Большой заголовок",headingColor:"Заголовок",subHeadingColor:"Подзаголовок",largeTextColor:"Большой текст",normalTextColor:"Текст",descriptionTextColor:"Описание",linkColor:"Ссылка",custom:"Пользовательский"}},_rt=jn({en:Ert,ru:Rrt}),nbe=t=>({Match:e=>{switch(t){case"Heading":return e.whenHeading();case"Title":return e.whenTitle();case"SubHeading":return e.whenSubHeading();case"LargeText":return e.whenLargeText();case"NormalText":return e.whenNormalText();case"DescriptionText":return e.whenDescriptionText();case"Link":return e.whenLink();case"Button":return e.whenButton();default:return ls(t)}}}),WV=t=>nbe(t.themeName).Match({whenHeading:()=>t.themeFontColors.HeadingColor,whenTitle:()=>t.themeFontColors.TitleColor,whenSubHeading:()=>t.themeFontColors.SubHeadingColor,whenLargeText:()=>t.themeFontColors.LargeTextColor,whenNormalText:()=>t.themeFontColors.NormalTextColor,whenDescriptionText:()=>t.themeFontColors.DescriptionTextColor,whenLink:()=>t.themeFontColors.LinkColor,whenButton:()=>t.themeFontColors.ButtonTextColor}),Tw=t=>{const{FontFamily:e,FontSettingsPresets:n,Colors:r}=t.theme,o=!!t.editor.getAttributes("textStyle")[t.styleName],i=t.editor.getAttributes("paragraph").themeName||"NormalText",s=t.editor.getAttributes("textStyle").themeName||i;if(o)return t.editor.getAttributes("textStyle")[t.styleName];const a=us({fontFamily:e,themeFontSettings:n[s],themeColor:WV({themeName:s,themeFontColors:r})});return String(a[t.styleName])},rbe=t=>{const{FontFamily:e,FontSettingsPresets:n,Colors:r}=t.theme,o=!!t.editor.getAttributes("textStyle").color,i=t.editor.getAttributes("paragraph").themeName||"NormalText",s=t.editor.getAttributes("textStyle").themeName||i;if(o)return t.editor.getAttributes("textStyle").color;const a=us({fontFamily:e,themeFontSettings:n[s],themeColor:WV({themeName:s,themeFontColors:r})});return{Discriminator:nbe(s).Match({whenHeading:()=>"HeadingColor",whenTitle:()=>"TitleColor",whenSubHeading:()=>"SubHeadingColor",whenLargeText:()=>"LargeTextColor",whenNormalText:()=>"NormalTextColor",whenDescriptionText:()=>"DescriptionTextColor",whenLink:()=>"LinkColor",whenButton:()=>"ButtonTextColor"}),CustomValue:a.color}},Drt={class:"color-picker bootstrap-styles border rounded bg-white"},Art={class:"bootstrap-styles p-1 mb-5 bg-white"},$rt=["value"],Nrt=["value"],Brt=Ze({__name:"ColorPickerModalWindow",props:{editor:{},theme:{},deps:{}},emits:["onColorChanged","onColorPickerClosed"],setup(t,{emit:e}){const n=t,r={colorLabels:_rt({localeKey:n.deps.localeKey}).colorLabels},o=q(()=>PV({fontColor:rbe({editor:n.editor,theme:n.theme}),themeColors:n.theme.Colors})),i=Mt({color:o.value,isValidHexColor:!0}),s={StyleLinkedColor:r.colorLabels.styleLinkedColor,EmailBackgroundColor:r.colorLabels.emailBackgroundColor,BodyColor:r.colorLabels.bodyColor,PrimaryColor:r.colorLabels.primaryColor,SecondaryColor:r.colorLabels.secondaryColor,PrimaryTextColor:r.colorLabels.primaryTextColor,SecondaryTextColor:r.colorLabels.secondaryTextColor,CardBackgroundColor:r.colorLabels.cardBackgroundColor,ButtonTextColor:r.colorLabels.buttonTextColor,TitleColor:r.colorLabels.titleColor,HeadingColor:r.colorLabels.headingColor,SubHeadingColor:r.colorLabels.subHeadingColor,LargeTextColor:r.colorLabels.largeTextColor,NormalTextColor:r.colorLabels.normalTextColor,DescriptionTextColor:r.colorLabels.descriptionTextColor,LinkColor:r.colorLabels.linkColor,Custom:r.colorLabels.custom},a=["EmailBackgroundColor","BodyColor","PrimaryColor","SecondaryColor","PrimaryTextColor","SecondaryTextColor","ButtonTextColor","TitleColor","HeadingColor","SubHeadingColor","LargeTextColor","NormalTextColor","DescriptionTextColor","LinkColor"],l=R4e(h=>{d("onColorChanged",{Discriminator:"Custom",CustomValue:h})},100,{leading:!1,trailing:!0}),u=h=>/^#([0-9A-Fa-f]{6})$/.test(h.trim()),c=h=>{i.isValidHexColor=u(h),i.color=h,u(h)&&d("onColorChanged",{Discriminator:"Custom",CustomValue:h})};mn(()=>o.value,h=>{i.color=h,i.isValidHexColor=u(h)});const d=e;return(h,m)=>It((I(),J("div",null,[R("ul",Drt,[R("li",Art,[ie(z(AGe),{modelValue:o.value,width:220,canvasHeight:220,hideInputs:!0,hideSliders:!1,mode:"hex","onUpdate:modelValue":m[0]||(m[0]=f=>z(l)(f))},null,8,["modelValue"]),R("div",{class:Me(["bootstrap-styles border bg-color-input rounded-2 d-flex justify-content-between p-14",{"is-not-valid":!i.isValidHexColor}])},[R("input",{type:"color",class:"bootstrap-styles pe-none",style:{border:"1px solid rgba(0, 0, 0, 0.1)",cursor:"default"},value:o.value},null,8,$rt),R("input",{type:"text",class:"bootstrap-styles w-100 text-uppercase ps-1",value:i.color,placeholder:"#000000",onInput:m[1]||(m[1]=f=>c(f.target.value))},null,40,Nrt)],2)]),(I(),J(ot,null,zn(a,f=>ie(krt,{key:f,isActive:o.value===n.theme.Colors[f],color:n.theme.Colors[f],label:s[f],onClick:()=>{d("onColorChanged",{Discriminator:f,CustomValue:n.theme.Colors[f]}),d("onColorPickerClosed")}},null,8,["isActive","color","label","onClick"])),64))])])),[[z(Sd),()=>d("onColorPickerClosed")]])}}),Lrt=Qe(Brt,[["__scopeId","data-v-0ec36b1f"]]),Vrt={tooltip:"Text color"},Mrt={tooltip:"Цвет текста"},Ort=jn({en:Vrt,ru:Mrt}),Irt=["value"],Prt=Ze({__name:"ColorPicker",props:{editor:{},theme:{},isAllowToEdit:{type:Boolean},deps:{}},setup(t){const e=t,n={tooltip:Ort({localeKey:e.deps.localeKey}).tooltip},r=Mt({isColorPickerDropdownShown:!1}),o=yn(),i=yn(),{floatingStyles:s}=kpe(i,o,{whileElementsMounted:xpe,placement:"bottom",middleware:[Spe(({rects:l})=>({alignmentAxis:-l.floating.width/2-l.floating.width/2,mainAxis:15}))]}),a=q(()=>PV({fontColor:rbe({editor:e.editor,theme:e.theme}),themeColors:e.theme.Colors}));return(l,u)=>(I(),J(ot,null,[It((I(),J("button",{ref_key:"richTextColorPickerBtn",ref:i,class:Me(["bootstrap-styles border rich-text-color__input rich-text__handler",{disabled:!t.isAllowToEdit}]),value:a.value,onClick:u[0]||(u[0]=()=>r.isColorPickerDropdownShown=!r.isColorPickerDropdownShown)},[R("i",{style:he([{display:"block",width:"100%",height:"100%"},{backgroundColor:a.value}])},null,4)],10,Irt)),[[z(Br),{title:n.tooltip,placement:"top"}]]),r.isColorPickerDropdownShown?(I(),et(Lrt,{key:0,ref_key:"richTextColorPicker",ref:o,theme:e.theme,editor:e.editor,deps:e.deps.colorPickerModalWindowDeps,style:he(z(s)),onOnColorChanged:u[1]||(u[1]=c=>{e.editor.commands.setColor(c)}),onOnColorPickerClosed:u[2]||(u[2]=()=>{r.isColorPickerDropdownShown=!1,e.editor.commands.focus()})},null,8,["theme","editor","deps","style"])):Ue("",!0)],64))}}),Wrt=Qe(Prt,[["__scopeId","data-v-6624477a"]]),Hrt={},zrt={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function jrt(t,e){return I(),J("svg",zrt,[...e[0]||(e[0]=[R("path",{d:"M8.00033 10.0002L5.17188 7.17184L6.11469 6.229L8.00033 8.11464L9.88593 6.229L10.8287 7.17184L8.00033 10.0002Z",fill:"var(--gray-500)"},null,-1)])])}const obe=Qe(Hrt,[["render",jrt]]),Urt={tooltip:"Font family"},Krt={tooltip:"Шрифт"},qrt=jn({en:Urt,ru:Krt}),Jrt={class:"bootstrap-styles dropdown"},Grt={class:"bootstrap-styles me-14 overflow-hidden rich-text-toolbar__font-family-btn__text"},Yrt={class:"bootstrap-styles d-flex justify-content-center align-items-center"},Xrt=["onClick"],Qrt=Ze({__name:"FontFamilySelector",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:qrt({localeKey:e.deps.localeKey}).tooltip},r=RV.name,o=Mt({isOpened:!1}),i=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"fontFamily"})),s=a=>{e.editor.commands.setFontFamily(a),o.isOpened=!1,e.editor.commands.focus()};return(a,l)=>It((I(),J("div",Jrt,[R("button",{id:"richTextDropdownFontFamily",class:Me(["bootstrap-styles d-flex justify-content-between align-items-center py-1 px-3 text-nowrap rich-text-toolbar__font-family-btn border rounded-2 overflow-hidden",{disabled:!e.isAllowToEdit,show:o.isOpened}]),type:"button",onClick:l[0]||(l[0]=u=>o.isOpened=!o.isOpened)},[R("span",Grt,en(z(Az)[i.value]),1),R("i",Yrt,[ie(obe)])],2),R("ul",{class:Me([{show:o.isOpened},"bootstrap-styles dropdown-menu rounded-2 bg-white"]),"aria-labelledby":"richTextDropdownFontFamily"},[(I(!0),J(ot,null,zn(z(H0e),u=>(I(),J("li",{key:u,class:Me(["bootstrap-styles dropdown-item p-0",{active:e.editor.getAttributes(z(r)).fontFamily===u}]),onClick:()=>s(u)},[R("span",{class:"bootstrap-styles d-block py-1 px-3 text-decoration-none text-reset cursor-pointer",style:he({fontFamily:u})},en(z(Az)[u]),5)],10,Xrt))),128))],2)])),[[z(Sd),()=>o.isOpened=!1],[z(Br),{title:n.tooltip,placement:"top"}]])}}),Zrt=Qe(Qrt,[["__scopeId","data-v-cc496278"]]),eot={},tot={xmlns:"http://www.w3.org/2000/svg",width:"8",height:"8",viewBox:"0 0 8 8",fill:"none"};function not(t,e){return I(),J("svg",tot,[...e[0]||(e[0]=[R("path",{d:"M4.00003 2.38419e-07L1 2.99997L2.00001 4L4.00003 1.99998L6.00001 4L7 2.99997L4.00003 2.38419e-07Z",fill:"var(--gray-500)"},null,-1)])])}const ibe=Qe(eot,[["render",not],["__scopeId","data-v-19c42a7a"]]),rot={},oot={xmlns:"http://www.w3.org/2000/svg",width:"8",height:"8",viewBox:"0 0 8 8",fill:"none"};function iot(t,e){return I(),J("svg",oot,[...e[0]||(e[0]=[R("path",{d:"M4.00003 8L1 5.00003L2.00001 4L4.00003 6.00002L6.00001 4L7 5.00003L4.00003 8Z",fill:"var(--gray-500)"},null,-1)])])}const sbe=Qe(rot,[["render",iot],["__scopeId","data-v-313c2951"]]),sot={},aot={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function lot(t,e){return I(),J("svg",aot,[...e[0]||(e[0]=[R("path",{d:"M6.66634 4.00033V14.0003H5.33301V4.00033H1.33301V2.66699H10.6663V4.00033H6.66634ZM11.9997 9.33366V14.0003H10.6663V9.33366H8.66634V8.00033H13.9997V9.33366H11.9997Z",fill:"#999999"},null,-1)])])}const uot=Qe(sot,[["render",lot]]),cot={tooltip:"Font size"},dot={tooltip:"Размер текста"},hot=jn({en:cot,ru:dot}),mot=t=>{const{FontFamily:e,FontSettingsPresets:n,Colors:r}=t.theme,o=!!t.editor.getAttributes("textStyle").fontSize,i=t.editor.getAttributes("paragraph").themeName||"NormalText",s=t.editor.getAttributes("textStyle").themeName||i;return o?parseInt(t.editor.getAttributes("textStyle").fontSize,10):us({fontFamily:e,themeFontSettings:n[s],themeColor:WV({themeName:s,themeFontColors:r})}).fontSize},fot={class:"bootstrap-styles rich-text-toolbar__font-size-editor position-relative rounded-2 py-1 px-3 d-flex"},pot={class:"bootstrap-styles d-flex justify-content-center rich-text-icon me-14"},got=["value"],Cot={class:"bootstrap-styles rich-text-toolbar__input-button top-0 d-flex position-absolute align-items-end justify-content-center"},yot={class:"bootstrap-styles rich-text-toolbar__input-button bottom-0 d-flex position-absolute align-items-start justify-content-center"},bot=Ze({__name:"FontSizeEditor",props:{editor:{},theme:{},deps:{}},setup(t){const e=t,n={tooltip:hot({localeKey:e.deps.localeKey}).tooltip},r=q(()=>mot({editor:e.editor,theme:e.theme})),o=()=>{r.value&&e.editor.commands.setFontSize(r.value+1)},i=()=>{r.value&&r.value!==1&&e.editor.commands.setFontSize(r.value-1)},s=a=>{const l=a.target;let u=parseInt(l.value);const c=100;isNaN(u)||l.value===""?(u=0,l.value="0"):u>c&&(u=c,l.value=String(c)),e.editor.commands.setFontSize(u)};return(a,l)=>It((I(),J("div",fot,[R("i",pot,[ie(uot)]),R("input",{type:"number",class:"bootstrap-styles rich-text-toolbar__input-number rich-text__handler",value:r.value,onInput:s},null,40,got),R("div",Cot,[R("input",{type:"button",class:"bootstrap-styles position-absolute rich-text__handler",onClick:o}),ie(ibe)]),R("div",yot,[R("input",{type:"button",class:"bootstrap-styles position-absolute rich-text__handler",onClick:i}),ie(sbe)])])),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),vot=Qe(bot,[["__scopeId","data-v-ba95f865"]]),Tot=Ze({__name:"SelectItemTextStyle",props:{isActive:{type:Boolean},label:{},themeFontStyle:{},themeFontColor:{}},emits:["click"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("li",{class:Me(["bootstrap-styles dropdown-item p-0 d-flex align-items-center px-3 cursor-pointer",{active:n.isActive}]),onClick:i[0]||(i[0]=s=>r("click"))},[R("i",{class:"bootstrap-styles input__color_selection d-block overflow-hidden me-2",style:he([{background:n.themeFontColor??"linear-gradient(135deg, rgb(51, 132, 255) 0%, rgb(202, 101, 250) 34.37%, rgb(250, 101, 101) 61.98%, rgb(250, 235, 101) 100%)"},{"min-width":"24px"}])},null,4),R("span",{class:"bootstrap-styles d-block py-1 text-decoration-none overflow-hidden",style:he([n.themeFontStyle&&{fontSize:n.themeFontStyle.FontSize+"px",fontWeight:n.themeFontStyle.IsBold?"bold":"normal",fontStyle:n.themeFontStyle.IsItalic?"italic":"normal",textDecoration:n.themeFontStyle.Decoration},{"white-space":"nowrap",overflow:"hidden","text-overflow":"ellipsis"}])},en(n.label),5)],2))}}),Fot=Qe(Tot,[["__scopeId","data-v-3a2ee8e2"]]),xot={tooltip:"Text style",settingLabels:{title:"Title",heading:"Heading",subHeading:"Subheading",largeText:"Large text",normalText:"Text",descriptionText:"Description",link:"Link",button:"Button",custom:"Custom"}},Sot={tooltip:"Стиль текста",settingLabels:{title:"Большой заголовок",heading:"Заголовок",subHeading:"Подзаголовок",largeText:"Большой текст",normalText:"Текст",descriptionText:"Описание",link:"Ссылка",button:"Кнопка",custom:"Пользовательский"}},xee=jn({en:xot,ru:Sot}),wot={class:"bootstrap-styles dropdown"},kot={class:"bootstrap-styles rich-text-toolbar__font-style-selector__text"},Eot={class:"bootstrap-styles d-flex justify-content-center align-items-center rich-text-toolbar__icon"},Rot=Ze({__name:"ThemeSettingsSelector",props:{editor:{},theme:{},isAllowToEdit:{type:Boolean},initialThemeName:{},deps:{}},setup(t){const e=t,n=RV.name,r=Mt({isOpened:!1}),o={tooltip:xee({localeKey:e.deps.localeKey}).tooltip,settingLabels:xee({localeKey:e.deps.localeKey}).settingLabels},i={Title:o.settingLabels.title,Heading:o.settingLabels.heading,SubHeading:o.settingLabels.subHeading,LargeText:o.settingLabels.largeText,NormalText:o.settingLabels.normalText,DescriptionText:o.settingLabels.descriptionText,Link:o.settingLabels.link,Button:o.settingLabels.button,Custom:o.settingLabels.custom},s=["Title","Heading","SubHeading","LargeText","NormalText","DescriptionText","Link","Button"],a=["TitleColor","HeadingColor","SubHeadingColor","LargeTextColor","NormalTextColor","DescriptionTextColor","LinkColor","ButtonTextColor"],l=q(()=>{const c=e.initialThemeName,d=e.editor.getAttributes("paragraph").themeName||c;let h=s.find(F=>e.editor.getAttributes(n).themeName===F)||d;const{fontWeight:m,fontStyle:f,textDecoration:p,fontSize:g,fontFamily:y,lineHeight:b}=e.editor.getAttributes(n);return m||f||p||g||y||b?i.Custom:i[h]}),u=c=>{e.editor.commands.unsetMark(n),e.editor.chain().focus().setThemeSettings(c).run(),r.isOpened=!1};return(c,d)=>It((I(),J("div",wot,[R("button",{id:"dropdownMenuButtonFontStyleList",class:Me(["bootstrap-styles rich-text-toolbar__font-style-selector d-flex justify-content-between align-items-center py-1 px-3 text-nowrap border rounded-2",{disabled:!e.isAllowToEdit,show:r.isOpened}]),type:"button",onClick:d[0]||(d[0]=()=>r.isOpened=!r.isOpened)},[R("span",kot,en(l.value),1),R("i",Eot,[ie(obe)])],2),R("ul",{class:Me([{show:r.isOpened},"bootstrap-styles rich-text-toolbar__font-style-dropdown dropdown-menu rounded-2"]),"aria-labelledby":"dropdownMenuButtonFontStyleList"},[(I(),J(ot,null,zn(s,(h,m)=>ie(Fot,{key:h,isActive:e.editor.getAttributes(z(n)).themeName===h,label:i[h],themeFontStyle:e.theme.FontSettingsPresets[h],themeFontColor:e.theme.Colors[a[m]],onClick:()=>u(h)},null,8,["isActive","label","themeFontStyle","themeFontColor","onClick"])),64))],2)])),[[z(Sd),()=>r.isOpened=!1],[z(Br),{title:o.tooltip,placement:"top"}]])}}),_ot=Qe(Rot,[["__scopeId","data-v-37cbbac2"]]),Dot={},Aot={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function $ot(t,e){return I(),J("svg",Aot,[...e[0]||(e[0]=[R("path",{d:"M7.33317 2.66667H13.9998V4H7.33317V2.66667ZM3.99984 4.66667V7.33333H2.6665V4.66667H0.666504L3.33317 2L5.99984 4.66667H3.99984ZM3.99984 11.3333H5.99984L3.33317 14L0.666504 11.3333H2.6665V8.66667H3.99984V11.3333ZM7.33317 12H13.9998V13.3333H7.33317V12ZM5.99984 7.33333H13.9998V8.66667H5.99984V7.33333Z",fill:"var(--gray-500)"},null,-1)])])}const Not=Qe(Dot,[["render",$ot]]),Bot={tooltip:"Line height"},Lot={tooltip:"Высота строки"},Vot=jn({en:Bot,ru:Lot}),Mot=t=>{const{FontFamily:e,FontSettingsPresets:n,Colors:r}=t.theme,o=!!t.editor.getAttributes("textStyle").lineHeight,i=t.editor.getAttributes("paragraph").themeName||"NormalText",s=t.editor.getAttributes("textStyle").themeName||i;return o?parseInt(t.editor.getAttributes("textStyle").lineHeight,10):us({fontFamily:e,themeFontSettings:n[s],themeColor:WV({themeName:s,themeFontColors:r})}).lineHeight},Oot={class:"bootstrap-styles rich-text-toolbar__line-height-editor position-relative rounded-2 py-1 px-3 d-flex"},Iot={class:"bootstrap-styles d-flex justify-content-center rich-text-icon me-14"},Pot=["value"],Wot={class:"bootstrap-styles rich-text-toolbar__input-button d-flex position-absolute align-items-end justify-content-center",style:{right:"10px",top:"0",width:"16px",height:"16px"}},Hot={class:"bootstrap-styles rich-text-toolbar__input-button d-flex position-absolute align-items-start justify-content-center",style:{right:"10px",bottom:"0",width:"16px",height:"16px"}},zot=Ze({__name:"LineHeightEditor",props:{editor:{},theme:{},deps:{}},setup(t){const e=t,n={tooltip:Vot({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Mot({editor:e.editor,theme:e.theme})),o=()=>{r.value&&e.editor.commands.setLineHeight(r.value+1)},i=()=>{r.value&&r.value!==1&&e.editor.commands.setLineHeight(r.value-1)},s=a=>{const l=a.target;let u=parseInt(l.value);const c=100;isNaN(u)||l.value===""?(u=0,l.value="0"):u>c&&(u=c,l.value=String(c)),e.editor.commands.setLineHeight(u)};return(a,l)=>It((I(),J("div",Oot,[R("i",Iot,[ie(Not)]),R("input",{type:"number",class:"bootstrap-styles rich-text-toolbar__input-number rich-text__handler",value:r.value,onInput:s},null,40,Pot),R("div",Wot,[R("input",{type:"button",class:"bootstrap-styles position-absolute rich-text__handler",onClick:o}),ie(ibe)]),R("div",Hot,[R("input",{type:"button",class:"bootstrap-styles position-absolute rich-text__handler",onClick:i}),ie(sbe)])])),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),jot=Qe(zot,[["__scopeId","data-v-4e76ed1b"]]),Uot=["http:","https:","mailto:","tel:"],Kot={mounted(t,e){t.addEventListener("input",()=>{const n=t.value;let r=!1;try{const o=new URL(n);r=Uot.includes(o.protocol)}catch{r=!1}typeof e.value=="function"&&e.value(r)})}},abe={mounted(t,e){See(t,e)},updated(t,e){e.value&&See(t,e)}},See=(t,e)=>{document.activeElement!==t&&requestAnimationFrame(()=>{if(t.focus(),e.modifiers.selectAll&&t.select(),e.modifiers.end){const n=t.value.length;t.setSelectionRange(n,n)}})},qot={},Jot={xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none"};function Got(t,e){return I(),J("svg",Jot,[...e[0]||(e[0]=[R("path",{d:"M11.2432 9.35654L10.3003 8.41374L11.2432 7.47094C12.5449 6.16921 12.5449 4.05865 11.2432 2.75691C9.94139 1.45516 7.83086 1.45516 6.52912 2.75691L5.58631 3.69972L4.6435 2.75691L5.58631 1.8141C7.40879 -0.00834608 10.3635 -0.00834608 12.186 1.8141C14.0084 3.63655 14.0084 6.59134 12.186 8.41374L11.2432 9.35654ZM9.35752 11.2422L8.41472 12.185C6.59232 14.0075 3.63752 14.0075 1.81508 12.185C-0.00736952 10.3625 -0.00736952 7.40781 1.81508 5.58533L2.75788 4.64253L3.70069 5.58533L2.75788 6.52814C1.45614 7.82987 1.45614 9.94047 2.75788 11.2422C4.05963 12.5439 6.17019 12.5439 7.47192 11.2422L8.41472 10.2994L9.35752 11.2422ZM8.88612 4.17112L9.82893 5.11393L5.1149 9.82801L4.1721 8.88514L8.88612 4.17112Z",fill:"var(--black)"},null,-1)])])}const lbe=Qe(qot,[["render",Got]]),Yot={label:"Link",inputPlaceholder:"https://example.com",errorNotification:"The link must contain https://, http://, mailto:, tel:",applyButton:"Save",cancelButton:"Cancel"},Xot={label:"Ссылка",inputPlaceholder:"https://example.com",errorNotification:"Ссылка должна содержать https://, http://, mailto:, tel:",applyButton:"Сохранить",cancelButton:"Отмена"},n1=jn({en:Yot,ru:Xot}),Qot={},Zot={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function eit(t,e){return I(),J("svg",Zot,[...e[0]||(e[0]=[R("path",{d:"M11.333 3.99967H14.6663V5.33301H13.333V13.9997C13.333 14.3679 13.0345 14.6663 12.6663 14.6663H3.33301C2.96482 14.6663 2.66634 14.3679 2.66634 13.9997V5.33301H1.33301V3.99967H4.66634V1.99967C4.66634 1.63149 4.96482 1.33301 5.33301 1.33301H10.6663C11.0345 1.33301 11.333 1.63149 11.333 1.99967V3.99967ZM11.9997 5.33301H3.99967V13.333H11.9997V5.33301ZM5.99967 7.33301H7.33301V11.333H5.99967V7.33301ZM8.66634 7.33301H9.99967V11.333H8.66634V7.33301ZM5.99967 2.66634V3.99967H9.99967V2.66634H5.99967Z",fill:"white"},null,-1)])])}const ube=Qe(Qot,[["render",eit]]),tit={class:"bootstrap-styles bg-white border rounded-2 add-text-link-modal-window"},nit={class:"bootstrap-styles fw-bold mb-5 px-11 mt-10 d-block text-start"},rit={class:"bootstrap-styles px-11 mb-2"},oit={class:"bootstrap-styles d-flex justify-content-center align-items-center me-1"},iit=["placeholder","value"],sit={class:"bootstrap-styles px-11 py-5 d-flex align-items-center justify-content-end border-top"},ait=["disabled"],lit=Ze({__name:"AddLinkModalWindow",props:{isActive:{type:Boolean},currentHref:{},deps:{}},emits:["onClosed","onHrefChanged","onRemoved"],setup(t,{emit:e}){const n=t,r=Mt({href:n.currentHref,isValid:!0}),o=a=>{r.href=a,r.isValid=a.length>0},i={label:n1({localeKey:n.deps.localeKey}).label,inputPlaceholder:n1({localeKey:n.deps.localeKey}).inputPlaceholder,errorNotification:n1({localeKey:n.deps.localeKey}).errorNotification,applyButton:n1({localeKey:n.deps.localeKey}).applyButton,cancelButton:n1({localeKey:n.deps.localeKey}).cancelButton},s=e;return(a,l)=>It((I(),J("div",tit,[R("label",nit,en(i.label),1),R("div",rit,[R("div",{class:Me(["bootstrap-styles bg-color-input border rounded-2 py-1 px-3 d-flex mb-14",{"border-danger":!r.isValid}])},[R("i",oit,[ie(lbe)]),It(R("input",{type:"text",class:"bootstrap-styles w-100",placeholder:i.inputPlaceholder,value:r.href,onInput:l[0]||(l[0]=u=>o(u.target.value))},null,40,iit),[[z(Kot),u=>r.isValid=u],[z(abe),void 0,void 0,{selectAll:!0}]])],2),R("div",{class:Me(["bootstrap-styles text-start add-link-modal-window-notification",{invisible:r.isValid}])},en(i.errorNotification),3)]),R("div",sit,[n.isActive?(I(),J("button",{key:0,class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-auto rounded-2 add-text-link-modal-window__remove-button",onClick:l[1]||(l[1]=wr(()=>s("onRemoved"),["stop"]))},[R("i",null,[ie(ube)])])):Ue("",!0),R("button",{class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-3 border border-blue-selected rounded-2 bg-blue-selected button__hover-blue-100 text-color-selected",onClick:l[2]||(l[2]=()=>s("onClosed"))},en(i.cancelButton),1),R("button",{class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 border rounded-2 bg-color-selected text-white cursor-pointer",disabled:!r.href.length||!r.isValid,onClick:l[3]||(l[3]=()=>s("onHrefChanged",r.href))},en(i.applyButton),9,ait)])])),[[z(Sd),()=>s("onClosed")]])}}),uit=Qe(lit,[["__scopeId","data-v-dd4e68e8"]]),cit={};function dit(t,e){return I(),J(ot,null,[e[0]||(e[0]=R("svg",{class:"unlinked",xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"},[R("path",{d:"M12.7432 10.3565L11.8003 9.41374L12.7432 8.47094C14.0449 7.16921 14.0449 5.05865 12.7432 3.75691C11.4414 2.45516 9.33086 2.45516 8.02912 3.75691L7.08631 4.69972L6.1435 3.75691L7.08631 2.8141C8.90879 0.991654 11.8635 0.991654 13.686 2.8141C15.5084 4.63655 15.5084 7.59134 13.686 9.41374L12.7432 10.3565ZM10.8575 12.2422L9.91472 13.185C8.09232 15.0075 5.13752 15.0075 3.31508 13.185C1.49263 11.3625 1.49263 8.40781 3.31508 6.58533L4.25788 5.64253L5.20069 6.58533L4.25788 7.52814C2.95614 8.82987 2.95614 10.9405 4.25788 12.2422C5.55963 13.5439 7.67019 13.5439 8.97192 12.2422L9.91472 11.2994L10.8575 12.2422ZM10.3861 5.17112L11.3289 6.11393L6.6149 10.828L5.6721 9.88514L10.3861 5.17112Z",fill:"black"})],-1)),e[1]||(e[1]=R("svg",{class:"linked",xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[R("path",{d:"M11.7713 9.88573L10.8285 8.94287L11.7713 8.00007C12.8127 6.95867 12.8127 5.27025 11.7713 4.22885C10.7299 3.18745 9.04147 3.18745 8.00007 4.22885L7.05727 5.17166L6.11447 4.22885L7.05727 3.28605C8.6194 1.72395 11.1521 1.72395 12.7141 3.28605C14.2762 4.84814 14.2762 7.3808 12.7141 8.94287L11.7713 9.88573ZM9.88573 11.7713L8.94287 12.7141C7.3808 14.2762 4.84814 14.2762 3.28605 12.7141C1.72395 11.1521 1.72395 8.6194 3.28605 7.05727L4.22885 6.11447L5.17166 7.05727L4.22885 8.00007C3.18745 9.04147 3.18745 10.7299 4.22885 11.7713C5.27025 12.8127 6.95867 12.8127 8.00007 11.7713L8.94287 10.8285L9.88573 11.7713ZM9.88573 5.17166L10.8285 6.11447L6.11447 10.8285L5.17166 9.88573L9.88573 5.17166ZM3.85026 1.52869L5.13816 1.18359L5.82835 3.75939L4.54045 4.10449L3.85026 1.52869ZM10.1719 12.2408L11.4597 11.8957L12.1499 14.4715L10.862 14.8166L10.1719 12.2408ZM1.52869 3.85026L4.10449 4.54045L3.75939 5.82835L1.18359 5.13816L1.52869 3.85026ZM12.2408 10.1719L14.8166 10.862L14.4715 12.1499L11.8957 11.4597L12.2408 10.1719Z",fill:"black"})],-1))],64)}const hit=Qe(cit,[["render",dit],["__scopeId","data-v-730bc16f"]]),mit={tooltip:"Link"},fit={tooltip:"Ссылка"},pit=jn({en:mit,ru:fit}),git={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Cit=Ze({__name:"LinkEditor",props:{editor:{},isAllowToEdit:{type:Boolean},deps:{}},setup(t){const e=t,n={tooltip:pit({localeKey:e.deps.localeKey}).tooltip},r=c7.name,o=U7.name,i=Mt({isAddTextLinkModalWindowShown:!1}),s=q(()=>e.editor.isActive(o)),a=u=>{s.value&&e.editor.commands.unsetUnsubscribeLink(),e.editor.chain().focus().setLink({href:u}).setThemeSettings("Link").run(),i.isAddTextLinkModalWindowShown=!1},l=()=>{e.editor.chain().focus().unsetLink().applySiblingNodeThemeSettings().run(),i.isAddTextLinkModalWindowShown=!1};return(u,c)=>(I(),J(ot,null,[It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive(z(r)),disabled:!e.editor.isActive(z(r))&&!e.isAllowToEdit}]),onClick:c[0]||(c[0]=d=>{i.isAddTextLinkModalWindowShown=!i.isAddTextLinkModalWindowShown})},[R("i",git,[e.editor.isActive(z(r))?(I(),et(hit,{key:1})):(I(),et(lbe,{key:0}))])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]]),i.isAddTextLinkModalWindowShown?(I(),et(uit,{key:0,isActive:e.editor.isActive(z(r)),currentHref:e.editor.isActive(z(r))?e.editor.getAttributes(z(r)).href:"",deps:e.deps.addLinkModalWindowDeps,onOnRemoved:c[1]||(c[1]=()=>l()),onOnClosed:c[2]||(c[2]=d=>i.isAddTextLinkModalWindowShown=!1),onOnHrefChanged:c[3]||(c[3]=d=>a(d))},null,8,["isActive","currentHref","deps"])):Ue("",!0)],64))}}),yit=Qe(Cit,[["__scopeId","data-v-6460a995"]]),bit={label:"URL",placeholder:"URL...",cancel:"Cancel",apply:"Save",removeTooltip:"Delete image"},vit={label:"URL",placeholder:"URL...",cancel:"Отмена",apply:"Сохранить",removeTooltip:"Удалить изображение"},r1=jn({en:bit,ru:vit}),Tit={class:"bootstrap-styles bg-white border rounded-2 add-image-src-modal-window"},Fit={class:"bootstrap-styles fw-bold mb-5 px-11 mt-10 d-block text-start"},xit={class:"bootstrap-styles px-11 mb-11"},Sit=["placeholder","value"],wit={class:"bootstrap-styles px-11 py-5 d-flex align-items-center justify-content-end border-top"},kit=["disabled"],Eit=Ze({__name:"AddImageSrcModalWindow",props:{isActive:{type:Boolean},src:{},width:{},height:{},isRetina:{type:Boolean},deps:{}},emits:["onClosed","onRemoved","onImageSrcChanged"],setup(t,{emit:e}){const n=t,r=Mt({src:n.src,width:n.width,height:n.height,isBroken:!1}),o={label:r1({localeKey:n.deps.localeKey}).label,placeholder:r1({localeKey:n.deps.localeKey}).placeholder,cancel:r1({localeKey:n.deps.localeKey}).cancel,apply:r1({localeKey:n.deps.localeKey}).apply,removeTooltip:r1({localeKey:n.deps.localeKey}).removeTooltip},i=upe(l=>{ebe(l).then(u=>{r.width=u.width,r.height=u.height,r.isBroken=!1,r.src=l}).catch(()=>{r.src=l,r.isBroken=!0})},500),s=()=>{a("onImageSrcChanged",{src:r.src,width:r.width,height:r.height,isRetina:!1})},a=e;return(l,u)=>It((I(),J("div",Tit,[R("label",Fit,en(o.label),1),R("div",xit,[R("div",{class:Me(["bootstrap-styles bg-color-input border rounded-2 py-1 px-3 d-flex",{"border-danger":r.isBroken}])},[It(R("input",{type:"text",class:"bootstrap-styles w-100",placeholder:o.placeholder,value:r.src,onInput:u[0]||(u[0]=c=>z(i)(c.target.value))},null,40,Sit),[[z(abe),void 0,void 0,{selectAll:!0}]])],2)]),R("div",wit,[n.isActive?It((I(),J("button",{key:0,class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-auto rounded-2 add-image-src-modal-window__remove-button",onClick:u[1]||(u[1]=wr(()=>a("onRemoved"),["stop"]))},[R("i",null,[ie(ube)])])),[[z(Br),{placement:"top",title:o.removeTooltip}]]):Ue("",!0),R("button",{class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-3 border border-blue-selected rounded-2 bg-blue-selected button__hover-blue-100 text-color-selected",onClick:u[2]||(u[2]=wr(()=>a("onClosed"),["stop"]))},en(o.cancel),1),R("button",{class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 border rounded-2 bg-color-selected text-white cursor-pointer",disabled:!r.src.length||r.isBroken,onClick:u[3]||(u[3]=wr(()=>s(),["stop"]))},en(o.apply),9,kit)])])),[[z(Sd),()=>a("onClosed")]])}}),Rit=Qe(Eit,[["__scopeId","data-v-35966ae0"]]),_it={},Dit={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Ait(t,e){return I(),J("svg",Dit,[...e[0]||(e[0]=[R("path",{d:"M1.99453 14C1.62936 14 1.33333 13.7034 1.33333 13.3377V2.66227C1.33333 2.29651 1.63687 2 1.99453 2H14.0055C14.3707 2 14.6667 2.29663 14.6667 2.66227V13.3377C14.6667 13.7035 14.3631 14 14.0055 14H1.99453ZM13.3333 10V3.33333H2.66666V12.6667L9.33333 6L13.3333 10ZM13.3333 11.8856L9.33333 7.8856L4.55228 12.6667H13.3333V11.8856ZM5.33333 7.33333C4.59695 7.33333 3.99999 6.7364 3.99999 6C3.99999 5.26362 4.59695 4.66667 5.33333 4.66667C6.06971 4.66667 6.66666 5.26362 6.66666 6C6.66666 6.7364 6.06971 7.33333 5.33333 7.33333Z",fill:"#2F2F2F"},null,-1)])])}const $it=Qe(_it,[["render",Ait]]),Nit={tooltip:"Image",retinaLabel:"For retina screens"},Bit={tooltip:"Изображение",retinaLabel:"Для retina-экранов"},wee=jn({en:Nit,ru:Bit}),Lit=["checked"],Vit=Ze({__name:"Checkbox",props:{checked:{type:Boolean}},emits:["change"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("input",{class:"bootstrap-styles me-1 cursor-pointer",checked:n.checked,type:"checkbox","aria-label":"Checkbox for following text input",onChange:i[0]||(i[0]=s=>r("change"))},null,40,Lit))}}),Mit=Qe(Vit,[["__scopeId","data-v-6a8c2252"]]),Oit={class:"bootstrap-styles rich-text-icon icon-hover d-flex"},Iit={key:0,class:"bootstrap-styles d-flex align-items-center ms-14 me-1"},Pit={for:"rich-text__retina-checkbox",class:"bootstrap-styles label__checkbox-input text-nowrap"},Wit=Ze({__name:"ImageEditor",props:{editor:{},deps:{}},setup(t){const e=t,n={tooltip:wee({localeKey:e.deps.localeKey}).tooltip,retinaLabel:wee({localeKey:e.deps.localeKey}).retinaLabel},r=tbe.name,o=Mt({isAddImageSrcModalWindowShown:!1}),i=async()=>{const l=e.editor.view.state.selection.anchor,{src:u,width:c,height:d,isRetina:h}=e.editor.getAttributes(r);e.editor.chain().focus().updateAttributes("image",{src:u,width:c,height:d,isRetina:!h}).setNodeSelection(l).run()},s=l=>{const u=e.editor.view.state.selection.anchor;e.editor.isActive(r)?e.editor.chain().focus().updateAttributes("image",{src:l.src,width:l.width,height:l.height,alt:"img",isRetina:!1}).setNodeSelection(u).run():e.editor.chain().focus().setImage({src:l.src,width:l.width,height:l.height,alt:"img",isRetina:!1}).setNodeSelection(u).run(),o.isAddImageSrcModalWindowShown=!1},a=()=>{e.editor.commands.deleteSelection(),o.isAddImageSrcModalWindowShown=!1};return(l,u)=>(I(),J(ot,null,[It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button__image",{active:e.editor.isActive(z(r))}]),onClick:u[0]||(u[0]=c=>o.isAddImageSrcModalWindowShown=!o.isAddImageSrcModalWindowShown)},[R("i",Oit,[ie($it)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]]),e.editor.isActive(z(r))?(I(),J("div",Iit,[ie(Mit,{id:"rich-text__retina-checkbox",checked:e.editor.isActive(z(r),{isRetina:!0}),onChange:u[1]||(u[1]=()=>i())},null,8,["checked"]),R("label",Pit,en(n.retinaLabel),1)])):Ue("",!0),o.isAddImageSrcModalWindowShown?(I(),et(Rit,{key:1,isActive:e.editor.isActive(z(r)),src:e.editor.getAttributes(z(r)).src?e.editor.getAttributes(z(r)).src:"",width:e.editor.getAttributes(z(r)).width?e.editor.getAttributes(z(r)).width:0,height:e.editor.getAttributes(z(r)).height?e.editor.getAttributes(z(r)).height:0,isRetina:e.editor.getAttributes(z(r)).isRetina?e.editor.getAttributes(z(r)).isRetina:!1,deps:e.deps.addImageSrcModalWindowDeps,onOnRemoved:u[2]||(u[2]=()=>a()),onOnClosed:u[3]||(u[3]=c=>o.isAddImageSrcModalWindowShown=!1),onOnImageSrcChanged:u[4]||(u[4]=c=>s({src:c.src,width:c.width,height:c.height}))},null,8,["isActive","src","width","height","isRetina","deps"])):Ue("",!0)],64))}}),Hit=Qe(Wit,[["__scopeId","data-v-cf315655"]]),zit={},jit={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function Uit(t,e){return I(),J("svg",jit,[...e[0]||(e[0]=[R("path",{d:"M5.83333 7.33317H8.83333C9.7538 7.33317 10.5 6.58698 10.5 5.6665C10.5 4.74603 9.7538 3.99984 8.83333 3.99984H5.83333V7.33317ZM12.5 10.3332C12.5 11.99 11.1569 13.3332 9.5 13.3332H4.5V2.6665H8.83333C10.4902 2.6665 11.8333 4.00965 11.8333 5.6665C11.8333 6.46938 11.5179 7.19857 11.0043 7.73704C11.8986 8.2563 12.5 9.2245 12.5 10.3332ZM5.83333 8.6665V11.9998H9.5C10.4205 11.9998 11.1667 11.2536 11.1667 10.3332C11.1667 9.4127 10.4205 8.6665 9.5 8.6665H5.83333Z",fill:"var(--black)"},null,-1)])])}const Kit=Qe(zit,[["render",Uit]]),qit={tooltip:"Bold"},Jit={tooltip:"Полужирный"},Git=jn({en:qit,ru:Jit}),Yit={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Xit=Ze({__name:"FontWeightEditor",props:{editor:{},theme:{},isAllowToEdit:{type:Boolean},deps:{}},setup(t){const e=t,n={tooltip:Git({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"fontWeight"})==="bold"),o=()=>{r.value?e.editor.chain().focus().unsetFontWeight().run():e.editor.chain().focus().setFontWeight("bold").run(),e.editor.commands.focus()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:r.value,disabled:!e.isAllowToEdit&&!r.value}]),onClick:s[0]||(s[0]=()=>o())},[R("i",Yit,[ie(Kit)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),Qit=Qe(Xit,[["__scopeId","data-v-0e22dbf6"]]),Zit={},est={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function tst(t,e){return I(),J("svg",est,[...e[0]||(e[0]=[R("path",{d:"M11.9359 9.33317C12.0897 9.67724 12.1667 10.0594 12.1667 10.4796C12.1667 11.3748 11.8175 12.0742 11.1191 12.5778C10.4206 13.0814 9.45567 13.3332 8.22413 13.3332C7.13116 13.3332 6.0489 13.0788 4.97728 12.5702V11.0671C5.99025 11.652 7.0272 11.9445 8.08813 11.9445C9.78887 11.9445 10.6419 11.4562 10.6472 10.4796C10.6472 10.0624 10.5033 9.70637 10.2154 9.41137C10.1893 9.38464 10.1626 9.35857 10.1354 9.33317H2.5V7.99984H14.5V9.33317H11.9359ZM9.21733 7.33317H5.58605C5.47107 7.2287 5.36411 7.11264 5.26517 6.98504C4.97728 6.61373 4.83333 6.16356 4.83333 5.63455C4.83333 4.81052 5.14389 4.10984 5.76499 3.5325C6.38611 2.95516 7.34707 2.6665 8.64793 2.6665C9.62893 2.6665 10.5673 2.88522 11.4629 3.32268V4.75711C10.6632 4.29931 9.7862 4.07042 8.83187 4.07042C7.17913 4.07042 6.35278 4.59179 6.35278 5.63455C6.35278 5.91432 6.49806 6.15848 6.78862 6.36703C7.07919 6.57558 7.43773 6.74217 7.8642 6.86677C8.27767 6.98757 8.72873 7.14304 9.21733 7.33317Z",fill:"black"},null,-1)])])}const nst=Qe(Zit,[["render",tst]]),rst={tooltip:"Strikethrough"},ost={tooltip:"Зачеркнутый"},ist=jn({en:rst,ru:ost}),sst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},ast=Ze({__name:"LineThroughEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:ist({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"textDecoration"})==="line-through"),o=()=>{r.value?e.editor.chain().focus().unsetTextDecoration().run():e.editor.chain().focus().setTextDecoration("line-through").run(),e.editor.commands.focus()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:r.value,disabled:!t.isAllowToEdit&&!r.value}]),onClick:s[0]||(s[0]=a=>o())},[R("i",sst,[ie(nst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),lst=Qe(ast,[["__scopeId","data-v-fffc32ef"]]),ust={},cst={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function dst(t,e){return I(),J("svg",cst,[...e[0]||(e[0]=[R("path",{d:"M5.83366 2V8C5.83366 9.47273 7.02757 10.6667 8.50033 10.6667C9.97306 10.6667 11.167 9.47273 11.167 8V2H12.5003V8C12.5003 10.2091 10.7095 12 8.50033 12C6.29119 12 4.50033 10.2091 4.50033 8V2H5.83366ZM3.16699 13.3333H13.8337V14.6667H3.16699V13.3333Z",fill:"black"},null,-1)])])}const hst=Qe(ust,[["render",dst]]),mst={tooltip:"Underline"},fst={tooltip:"Подчеркнутый"},pst=jn({en:mst,ru:fst}),gst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Cst=Ze({__name:"UnderlineEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:pst({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"textDecoration"})==="underline"),o=()=>{r.value?e.editor.chain().focus().unsetTextDecoration().run():e.editor.chain().focus().setTextDecoration("underline").run()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:r.value,disabled:!t.isAllowToEdit&&!r.value}]),onClick:s[0]||(s[0]=()=>o())},[R("i",gst,[ie(hst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),yst=Qe(Cst,[["__scopeId","data-v-ae63be68"]]),bst={},vst={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function Tst(t,e){return I(),J("svg",vst,[...e[0]||(e[0]=[R("path",{d:"M10.4998 13.3332H5.1665V11.9998H7.11758L8.52817 3.99984H6.49984V2.6665H11.8332V3.99984H9.8821L8.4715 11.9998H10.4998V13.3332Z",fill:"black"},null,-1)])])}const Fst=Qe(bst,[["render",Tst]]),xst={tooltip:"Italic"},Sst={tooltip:"Курсив"},wst=jn({en:xst,ru:Sst}),kst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Est=Ze({__name:"FontStyleEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:wst({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"fontStyle"})==="italic"),o=()=>{r.value?e.editor.chain().focus().unsetFontStyle().run():e.editor.chain().focus().setFontStyle("italic").run(),e.editor.commands.focus()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:r.value,disabled:!t.isAllowToEdit&&!r.value}]),onClick:s[0]||(s[0]=()=>o())},[R("i",kst,[ie(Fst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),Rst=Qe(Est,[["__scopeId","data-v-ac6b2276"]]),_st={},Dst={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Ast(t,e){return I(),J("svg",Dst,[...e[0]||(e[0]=[R("path",{d:"M7.49699 9.99999H3.16912L1.83578 13.3333H0.399734L4.6664 2.66666H5.99973L10.2664 13.3333H8.83033L7.49699 9.99999ZM6.96366 8.66666L5.33307 4.5901L3.70245 8.66666H6.96366ZM13.9997 8.35672V7.99999H15.3331V13.3333H13.9997V12.9766C13.6075 13.2035 13.1521 13.3333 12.6664 13.3333C11.1937 13.3333 9.99973 12.1394 9.99973 10.6667C9.99973 9.19392 11.1937 7.99999 12.6664 7.99999C13.1521 7.99999 13.6075 8.12986 13.9997 8.35672ZM12.6664 12C13.4028 12 13.9997 11.4031 13.9997 10.6667C13.9997 9.93026 13.4028 9.33332 12.6664 9.33332C11.93 9.33332 11.3331 9.93026 11.3331 10.6667C11.3331 11.4031 11.93 12 12.6664 12Z",fill:"black"},null,-1)])])}const $st=Qe(_st,[["render",Ast]]),Nst={tooltip:"Uppercase"},Bst={tooltip:"Заглавные"},Lst=jn({en:Nst,ru:Bst}),Vst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Mst=Ze({__name:"TextTransformEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:Lst({localeKey:e.deps.localeKey}).tooltip},r=J0e.name,o=q(()=>e.editor.isActive({[r]:"uppercase"})),i=()=>{o.value?e.editor.commands.unsetTextTransform():e.editor.commands.setTextTransform("uppercase"),e.editor.commands.focus()};return(s,a)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive({[z(r)]:"uppercase"}),disabled:!t.isAllowToEdit&&!e.editor.isActive({[z(r)]:"uppercase"})}]),onClick:a[0]||(a[0]=l=>i())},[R("i",Vst,[ie($st)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),Ost=Qe(Mst,[["__scopeId","data-v-20dea8b8"]]),Ist={},Pst={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Wst(t,e){return I(),J("svg",Pst,[...e[0]||(e[0]=[R("path",{d:"M12.2432 8.47094C13.5449 7.16921 13.5449 5.05865 12.2432 3.75691C10.9414 2.45516 8.83086 2.45516 7.52912 3.75691L6.58631 4.69972L5.6435 3.75691L6.58631 2.8141C8.40879 0.991654 11.3635 0.991654 13.186 2.8141C15.0084 4.63655 15.0084 7.59134 13.186 9.41374L12.2432 8.47094ZM9.41472 13.185C7.59232 15.0075 4.63752 15.0075 2.81508 13.185C0.99263 11.3625 0.99263 8.40781 2.81508 6.58533L3.75788 5.64253L4.70069 6.58533L3.75788 7.52814C2.45614 8.82987 2.45614 10.9405 3.75788 12.2422C5.05963 13.5439 7.17019 13.5439 8.47192 12.2422L9.41472 13.185ZM9.88612 5.17112L10.8289 6.11393L6.1149 10.828L5.1721 9.88514L9.88612 5.17112Z",fill:"#2F2F2F"},null,-1),R("path",{d:"M14.714 13.7712L13.2998 12.357L14.714 10.9428L13.7712 10L12.357 11.4142L10.9428 10L10 10.9428L11.4142 12.357L10 13.7712L10.9428 14.714L12.357 13.2998L13.7712 14.714L14.714 13.7712Z",fill:"#2F2F2F"},null,-1)])])}const Hst=Qe(Ist,[["render",Wst]]),zst={tooltip:"Unsubscribe link"},jst={tooltip:"Ссылка на отписку"},Ust=jn({en:zst,ru:jst}),Kst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},qst=Ze({__name:"UnsubscribeLinkEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:Ust({localeKey:e.deps.localeKey}).tooltip},r=U7.name,o=c7.name,i=q(()=>e.editor.isActive(o)),s=()=>{i.value&&e.editor.commands.unsetLink(),e.editor.isActive(r)?e.editor.chain().unsetUnsubscribeLink().applySiblingNodeThemeSettings().run():e.editor.chain().setUnsubscribeLink().setThemeSettings("Link").run()};return(a,l)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive(z(r)),disabled:!e.editor.isActive(z(r))&&!e.isAllowToEdit}]),onClick:l[0]||(l[0]=()=>s())},[R("i",Kst,[ie(Hst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),Jst=Qe(qst,[["__scopeId","data-v-9ee287d3"]]),Gst={},Yst={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function Xst(t,e){return I(),J("svg",Yst,[...e[0]||(e[0]=[R("path",{d:"M6.16699 4.66667C6.16699 3.93029 5.57004 3.33333 4.83366 3.33333C4.09728 3.33333 3.50033 3.93029 3.50033 4.66667C3.50033 5.40305 4.09728 6 4.83366 6C5.57004 6 6.16699 5.40305 6.16699 4.66667ZM7.50033 4.66667C7.50033 6.13943 6.30642 7.33333 4.83366 7.33333C3.3609 7.33333 2.16699 6.13943 2.16699 4.66667C2.16699 3.19391 3.3609 2 4.83366 2C6.30642 2 7.50033 3.19391 7.50033 4.66667ZM14.5003 2.66667H9.16699V4H14.5003V2.66667ZM14.5003 7.33333H9.16699V8.66667H14.5003V7.33333ZM14.5003 12H9.16699V13.3333H14.5003V12ZM4.83366 12.6667C4.09728 12.6667 3.50033 12.0697 3.50033 11.3333C3.50033 10.5969 4.09728 10 4.83366 10C5.57004 10 6.16699 10.5969 6.16699 11.3333C6.16699 12.0697 5.57004 12.6667 4.83366 12.6667ZM4.83366 14C6.30642 14 7.50033 12.8061 7.50033 11.3333C7.50033 9.8606 6.30642 8.66667 4.83366 8.66667C3.3609 8.66667 2.16699 9.8606 2.16699 11.3333C2.16699 12.8061 3.3609 14 4.83366 14Z",fill:"black"},null,-1)])])}const Qst=Qe(Gst,[["render",Xst]]),Zst={tooltip:"Bullet list"},eat={tooltip:"Маркированный список"},tat=jn({en:Zst,ru:eat}),nat={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},rat=Ze({__name:"BulletListEditor",props:{editor:{},deps:{}},setup(t){const e=t,n={tooltip:tat({localeKey:e.deps.localeKey}).tooltip},r=d7.name,o=()=>{e.editor.chain().focus().toggleBulletList().run()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive(z(r))}]),onClick:s[0]||(s[0]=()=>o())},[R("i",nat,[ie(Qst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),oat=Qe(rat,[["__scopeId","data-v-c64632e3"]]),iat={},sat={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function aat(t,e){return I(),J("svg",sat,[...e[0]||(e[0]=[R("path",{d:"M4.33382 2.33301H3.64521L2.66699 2.59512V3.63022L3.33367 3.45155L3.33378 5.66634H2.50033V6.66634H5.16699V5.66634H4.33382V2.33301ZM7.16699 2.66634H14.5003V3.99967H7.16699V2.66634ZM7.16699 7.33301H14.5003V8.66634H7.16699V7.33301ZM7.16699 11.9997H14.5003V13.333H7.16699V11.9997ZM2.41699 10.4163C2.41699 9.63394 3.05125 8.99967 3.83366 8.99967C4.61607 8.99967 5.25033 9.63394 5.25033 10.4163C5.25033 10.7401 5.14155 11.0388 4.95864 11.2775L4.95547 11.2816L4.04424 12.333H5.16699V13.333H2.50041L2.50005 12.5854L4.14813 10.6897C4.21186 10.6165 4.25033 10.5211 4.25033 10.4163C4.25033 10.1862 4.06378 9.99967 3.83366 9.99967C3.61618 9.99967 3.43748 10.1664 3.41864 10.3789L3.41039 10.583H2.41699V10.4163Z",fill:"black"},null,-1)])])}const lat=Qe(iat,[["render",aat]]),uat={tooltip:"Ordered list"},cat={tooltip:"Нумерованный список"},dat=jn({en:uat,ru:cat}),hat={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},mat=Ze({__name:"OrderedListEditor",props:{editor:{},deps:{}},setup(t){const e=t,n={tooltip:dat({localeKey:e.deps.localeKey}).tooltip},r=m7.name,o=()=>{e.editor.chain().focus().toggleOrderedList().run()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive(z(r))}]),onClick:s[0]||(s[0]=()=>o())},[R("i",hat,[ie(lat)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),fat=Qe(mat,[["__scopeId","data-v-aaa43948"]]),pat={},gat={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Cat(t,e){return I(),J("svg",gat,[...e[0]||(e[0]=[R("path",{d:"M14 13.9995H2V12.6665H14V13.9995ZM14 10.6665H2V9.3335H14V10.6665ZM4.29102 7.3335H2.00684V5.99951H4.29102V7.3335ZM10.4434 7.3335H5.55664V2.68896H10.4434V7.3335ZM14 7.3335H11.7158V5.99951H14V7.3335ZM4.29102 3.99951H2.00684V2.6665H4.29102V3.99951ZM14 3.99951H11.7158V2.6665H14V3.99951Z",fill:"var(--black)"},null,-1)])])}const kee=Qe(pat,[["render",Cat]]),yat={},bat={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function vat(t,e){return I(),J("svg",bat,[...e[0]||(e[0]=[R("path",{d:"M14 13.9995H2V12.6665H14V13.9995ZM10.4434 10.6548H5.55664V6.01123H10.4434V10.6548ZM4.29102 10.6245H2.00684V9.29053H4.29102V10.6245ZM14 10.6245H11.7158V9.29053H14V10.6245ZM4.29102 7.29053H2.00684V5.95752H4.29102V7.29053ZM14 7.29053H11.7158V5.95752H14V7.29053Z",fill:"var(--black)"},null,-1),R("path",{d:"M14 2.6665H2V3.99984H14V2.6665Z",fill:"var(--black)"},null,-1)])])}const Eee=Qe(yat,[["render",vat]]),Tat={},Fat={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function xat(t,e){return I(),J("svg",Fat,[...e[0]||(e[0]=[R("path",{d:"M14 2.6665H2V3.99951H14V2.6665ZM14 5.99951H2V7.33252H14V5.99951ZM4.29102 9.33252H2.00684V10.6665H4.29102V9.33252ZM10.4434 9.33252H5.55664V13.9771H10.4434V9.33252ZM14 9.33252H11.7158V10.6665H14V9.33252ZM4.29102 12.6665H2.00684V13.9995H4.29102V12.6665ZM14 12.6665H11.7158V13.9995H14V12.6665Z",fill:"var(--black)"},null,-1)])])}const Ree=Qe(Tat,[["render",xat]]),Sat={},wat={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function kat(t,e){return I(),J("svg",wat,[...e[0]||(e[0]=[R("path",{d:"M14 11.9775H2V10.6445H14V11.9775ZM4.29102 8.64453H2.00684V7.31055H4.29102V8.64453ZM10.4434 8.64453H5.55664V4H10.4434V8.64453ZM14 8.64453H11.7158V7.31055H14V8.64453Z",fill:"var(--black)"},null,-1)])])}const _ee=Qe(Sat,[["render",kat]]),Eat={tooltip:"Vertical image alignment"},Rat={tooltip:"Выравнивание картинок по вертикали"},_at=jn({en:Eat,ru:Rat}),Dat={class:"bootstrap-styles vertical-align-editor dropdown rounded"},Aat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},$at={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Nat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Bat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Lat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Vat=Ze({__name:"VerticalAlignEditor",props:{editor:{},currentVerticalAlign:{},deps:{}},emits:["onVerticalAlignVariantChanged"],setup(t,{emit:e}){const n=t,r={tooltip:_at({localeKey:n.deps.localeKey}).tooltip},o=Mt({isOpened:!1}),i=a=>{s("onVerticalAlignVariantChanged",a),o.isOpened=!1},s=e;return(a,l)=>It((I(),J("div",Dat,[R("button",{id:"richTextDropdownVerticalAlign",class:Me(["bootstrap-styles p-1 rounded rich-text-button",{show:o.isOpened}]),type:"button",onClick:l[0]||(l[0]=u=>o.isOpened=!o.isOpened)},[R("i",Aat,[n.currentVerticalAlign==="Baseline"?(I(),et(_ee,{key:0})):Ue("",!0),n.currentVerticalAlign==="Top"?(I(),et(kee,{key:1})):Ue("",!0),n.currentVerticalAlign==="Middle"?(I(),et(Eee,{key:2})):Ue("",!0),n.currentVerticalAlign==="Bottom"?(I(),et(Ree,{key:3})):Ue("",!0)])],2),R("div",{class:Me([{show:o.isOpened},"bootstrap-styles vertical-align-dropdown bg-white p-1"]),"aria-labelledby":"richTextDropdownVerticalAlign"},[R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:n.currentVerticalAlign==="Baseline"}]),onClick:l[1]||(l[1]=()=>i("Baseline"))},[R("i",$at,[ie(_ee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:n.currentVerticalAlign==="Top"}]),onClick:l[2]||(l[2]=()=>i("Top"))},[R("i",Nat,[ie(kee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:n.currentVerticalAlign==="Middle"}]),onClick:l[3]||(l[3]=()=>i("Middle"))},[R("i",Bat,[ie(Eee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:n.currentVerticalAlign==="Bottom"}]),onClick:l[4]||(l[4]=()=>i("Bottom"))},[R("i",Lat,[ie(Ree)])],2)],2)])),[[z(Sd),()=>o.isOpened=!1],[z(Br),{title:r.tooltip,placement:"top"}]])}}),Mat=Qe(Vat,[["__scopeId","data-v-4a636ae8"]]),Oat={},Iat={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function Pat(t,e){return I(),J("svg",Iat,[...e[0]||(e[0]=[R("path",{d:"M2 2.6665H14V3.99984H2V2.6665ZM2 12.6665H11.3333V13.9998H2V12.6665ZM2 9.33317H14V10.6665H2V9.33317ZM2 5.99984H11.3333V7.33317H2V5.99984Z",fill:"var(--black)"},null,-1)])])}const Dee=Qe(Oat,[["render",Pat]]),Wat={},Hat={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function zat(t,e){return I(),J("svg",Hat,[...e[0]||(e[0]=[R("path",{d:"M2 2.6665H14V3.99984H2V2.6665ZM3.33333 12.6665H12.6667V13.9998H3.33333V12.6665ZM2 9.33317H14V10.6665H2V9.33317ZM3.33333 5.99984H12.6667V7.33317H3.33333V5.99984Z",fill:"var(--black)"},null,-1)])])}const Aee=Qe(Wat,[["render",zat]]),jat={},Uat={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function Kat(t,e){return I(),J("svg",Uat,[...e[0]||(e[0]=[R("path",{d:"M2 2.6665H14V3.99984H2V2.6665ZM4.66667 12.6665H14V13.9998H4.66667V12.6665ZM2 9.33317H14V10.6665H2V9.33317ZM4.66667 5.99984H14V7.33317H4.66667V5.99984Z",fill:"var(--black)"},null,-1)])])}const $ee=Qe(jat,[["render",Kat]]),qat={tooltip:"Alignment"},Jat={tooltip:"Выравнивание"},Gat=jn({en:qat,ru:Jat}),Yat={class:"bootstrap-styles content-align-editor dropdown rounded"},Xat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Qat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Zat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},elt={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},tlt=Ze({__name:"ContentAlignEditor",props:{editor:{},deps:{},initialContentAlign:{}},setup(t){const e=t,n={tooltip:Gat({localeKey:e.deps.localeKey}).tooltip},r=Mt({isOpened:!1}),o=q(()=>{const{$from:s}=e.editor.state.selection,a=s.parent;return a.type.name==="paragraph"&&a.attrs.contentAlign||e.initialContentAlign}),i=s=>{e.editor.chain().focus().setParagraphContentAlign(s).run(),r.isOpened=!1};return(s,a)=>It((I(),J("div",Yat,[R("button",{id:"richTextDropdownContentAlign",class:Me(["bootstrap-styles p-1 rounded rich-text-button",{show:r.isOpened}]),type:"button",onClick:a[0]||(a[0]=l=>r.isOpened=!r.isOpened)},[R("i",Xat,[o.value==="Left"?(I(),et(Dee,{key:0})):Ue("",!0),o.value==="Center"?(I(),et(Aee,{key:1})):Ue("",!0),o.value==="Right"?(I(),et($ee,{key:2})):Ue("",!0)])],2),R("div",{class:Me([{show:r.isOpened},"bootstrap-styles content-align-dropdown bg-white p-1"]),"aria-labelledby":"richTextDropdownContentAlign"},[R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:o.value==="Left"}]),onClick:a[1]||(a[1]=()=>i("Left"))},[R("i",Qat,[ie(Dee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:o.value==="Center"}]),onClick:a[2]||(a[2]=()=>i("Center"))},[R("i",Zat,[ie(Aee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:o.value==="Right"}]),onClick:a[3]||(a[3]=()=>i("Right"))},[R("i",elt,[ie($ee)])],2)],2)])),[[z(Sd),()=>r.isOpened=!1],[z(Br),{title:n.tooltip,placement:"top"}]])}}),nlt=Qe(tlt,[["__scopeId","data-v-e9d5324a"]]),rlt={class:"bootstrap-styles rich-text-toolbar d-flex align-items-center border gap-1 p-1"},olt={key:2,class:"bootstrap-styles position-relative h-100"},ilt={key:3,class:"bootstrap-styles position-relative h-100"},slt={key:4,class:"bootstrap-styles d-flex justify-content-center align-items-center"},alt={key:7,class:"vl"},llt={key:13,class:"vl"},ult={key:16,class:"vl"},clt=Ze({__name:"RichTextToolbar",props:{editor:{},deps:{},element:{},theme:{},initialThemeName:{},initialContentAlign:{}},emits:["onVerticalAlignVariantChanged"],setup(t,{emit:e}){const n=t,r=n.deps.richTextToolbarPlugins,o=q(()=>{const{from:a,to:l}=n.editor.state.selection;return a!==l}),i=q(()=>n.editor.isActive("image")),s=e;return(a,l)=>(I(),J("div",rlt,[i.value?Ue("",!0):(I(),et(_ot,{key:0,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,initialThemeName:n.initialThemeName,deps:n.deps.themeSettingsSelectorDeps},null,8,["editor","theme","isAllowToEdit","initialThemeName","deps"])),i.value?Ue("",!0):(I(),et(Zrt,{key:1,theme:n.theme,editor:n.editor,isAllowToEdit:o.value,deps:n.deps.fontFamilySelectorDeps},null,8,["theme","editor","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),J("div",olt,[ie(vot,{editor:n.editor,theme:n.theme,deps:n.deps.fontSizeEditorDeps,class:Me({disabled:!o.value})},null,8,["editor","theme","deps","class"])])),i.value?Ue("",!0):(I(),J("div",ilt,[ie(jot,{editor:n.editor,theme:n.theme,deps:n.deps.lineHeightEditorDeps,class:Me({disabled:!o.value})},null,8,["editor","theme","deps","class"])])),i.value?Ue("",!0):(I(),J("div",slt,[ie(Wrt,{editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.colorPickerDeps},null,8,["editor","theme","isAllowToEdit","deps"])])),i.value?(I(),et(Mat,{key:5,currentVerticalAlign:n.element.ImageVerticalAlign,editor:n.editor,deps:n.deps.verticalAlignEditorDeps,onOnVerticalAlignVariantChanged:l[0]||(l[0]=u=>s("onVerticalAlignVariantChanged",u))},null,8,["currentVerticalAlign","editor","deps"])):Ue("",!0),i.value?Ue("",!0):(I(),et(nlt,{key:6,editor:n.editor,initialContentAlign:n.initialContentAlign,deps:n.deps.contentAlignEditorDeps,class:Me({"bootstrap-styles me-14":i.value})},null,8,["editor","initialContentAlign","deps","class"])),i.value?Ue("",!0):(I(),J("div",alt)),i.value?Ue("",!0):(I(),et(Qit,{key:8,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.fontWeightEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),et(Rst,{key:9,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.fontStyleEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),et(lst,{key:10,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.lineThroughEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),et(yst,{key:11,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.underlineEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),et(Ost,{key:12,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.textTransformEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),J("div",llt)),i.value?Ue("",!0):(I(),et(oat,{key:14,editor:n.editor,deps:n.deps.bulletListEditorDeps},null,8,["editor","deps"])),i.value?Ue("",!0):(I(),et(fat,{key:15,editor:n.editor,deps:n.deps.orderedListEditorDeps},null,8,["editor","deps"])),i.value?Ue("",!0):(I(),J("div",ult)),ie(yit,{editor:n.editor,isAllowToEdit:o.value,deps:n.deps.linkEditorDeps},null,8,["editor","isAllowToEdit","deps"]),ie(Jst,{editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.unsubscribeLinkEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"]),ie(Hit,{editor:n.editor,deps:n.deps.imageEditorDeps},null,8,["editor","deps"]),(I(!0),J(ot,null,zn(z(r),(u,c)=>(I(),J("span",{key:c,class:"bootstrap-styles d-none"},[(I(),et(Hme(u),{editor:n.editor},null,8,["editor"]))]))),128))]))}}),dlt=Qe(clt,[["__scopeId","data-v-5331228b"]]),hlt=t=>({Match:e=>{switch(t){case"Baseline":return e.whenBaseline();case"Top":return e.whenTop();case"Middle":return e.whenMiddle();case"Bottom":return e.whenBottom();default:return ls(t)}}}),mlt=t=>hlt(t.verticalAlign).Match({whenBaseline:()=>"baseline",whenTop:()=>"top",whenMiddle:()=>"middle",whenBottom:()=>"bottom"}),Nee="NormalText",Bee="Left",flt=Ze({__name:"RichText",props:{deps:{},theme:{},element:{},isSelected:{type:Boolean}},emits:["onRichTextUpdated","onRichTextRemoved","onElementClicked"],setup(t,{emit:e}){Pm(b=>({v02808ab3:n.theme.Colors.PrimaryColor,v3d0e3a01:n.theme.Colors.SecondaryColor,a0933cf4:n.theme.Colors.PrimaryTextColor,fbc08c58:n.theme.Colors.SecondaryTextColor,v21838d33:n.theme.Colors.CardBackgroundColor,v13541c9c:n.theme.Colors.ButtonTextColor,v43d7209d:n.theme.Colors.TitleColor,ad47ca9a:n.theme.Colors.HeadingColor,v5a1db76f:n.theme.Colors.SubHeadingColor,v1bbaa8ed:n.theme.Colors.LargeTextColor,v7d1410c6:n.theme.Colors.NormalTextColor,bbd9c868:n.theme.Colors.DescriptionTextColor,v58f5d097:n.theme.Colors.LinkColor,v2a98cdcb:n.theme.Colors.EmailBackgroundColor,v04760fef:n.theme.Colors.BodyColor,v23127854:p.value}));const n=t,r=Mt({isRemoveComponentWindowShown:!1,isEditing:!1}),o={removeWindowTitle:bee({localeKey:n.deps.localeKey}).removeWindowTitle,removeWindowDescription:bee({localeKey:n.deps.localeKey}).removeWindowDescription},i=yn(null),s=yn(null),{floatingStyles:a}=kpe(s,i,{placement:"top",whileElementsMounted:xpe,middleware:[Spe(10)]}),l=q(()=>{const b=a.value.transform??"translate(0px, 0px)",F=new DOMMatrix(b).m42;return{...a.value,left:"50%",transform:`translate(-50%, ${F}px)`}}),u=tV(),c=n.element.ContentAlign||Bee,d=q(()=>us({fontFamily:n.theme.FontFamily,themeFontSettings:n.theme.FontSettingsPresets.NormalText,themeColor:n.theme.Colors.NormalTextColor})),h=q(()=>{const b={...H7(d.value)};return{fontSize:b.fontSize,lineHeight:b.lineHeight,fontFamily:b.fontFamily,fontWeight:b.fontWeight,fontStyle:b.fontStyle,color:b.color}}),m=IKe({content:vee(n.element.Text),extensions:[...Srt({dataSourceFieldNameDelegate:n.deps.dataSourceFieldNameDelegate,initialThemeName:Nee,themeColors:n.theme.Colors,fallbackContentAlign:n.element.ContentAlign||Bee})],editable:r.isEditing,autofocus:"all",onUpdate:({editor:b})=>{if(!r.isEditing)return;const F=wrt({editor:b});y("onRichTextUpdated",{...n.element,Text:F})}}),f=()=>{m.value&&(m.value.chain().focus().undo().run(),r.isRemoveComponentWindowShown=!1)},p=q(()=>mlt({verticalAlign:n.element.ImageVerticalAlign})),g=()=>[document.querySelector(".rich-text-toolbar"),document.querySelector(".string-expression-builder-modal-window"),document.querySelector(`.rich-text-editor__content-${u}`)];mn(()=>n.element.Text,()=>{m.value&&!r.isEditing&&m.value.commands.setContent(vee(n.element.Text))});const y=e;return(b,F)=>It((I(),J("span",{ref_key:"richTextElementRef",ref:s,class:Me(["RichText cursor-pointer user-select-none",{selected:n.isSelected}]),style:he([{...h.value,minHeight:n.element.MinHeight+"px",display:"block"}]),onClick:F[3]||(F[3]=wr(()=>{y("onElementClicked"),r.isEditing=!0,z(m)&&z(m).setEditable(!0)},["prevent"]))},[ie(z(OKe),{class:Me(["rich-text-editor__content",`rich-text-editor__content-${z(u)}`]),editor:z(m)},null,8,["class","editor"]),z(m)&&r.isEditing?(I(),et(dlt,{key:0,ref_key:"richTextToolbarRef",ref:i,editor:z(m),deps:n.deps.richTextToolbarDeps,element:n.element,theme:n.theme,initialThemeName:Nee,initialContentAlign:z(c),style:he(l.value),onOnVerticalAlignVariantChanged:F[0]||(F[0]=T=>y("onRichTextUpdated",{...n.element,ImageVerticalAlign:T}))},null,8,["editor","deps","element","theme","initialContentAlign","style"])):Ue("",!0),(I(),et(Yj,{to:"#app"},[r.isRemoveComponentWindowShown?(I(),et(Int,{key:0,deps:n.deps.removeConfirmModalWindowDeps,headerText:o.removeWindowTitle,onCancel:F[1]||(F[1]=()=>f()),onConfirmed:F[2]||(F[2]=()=>{r.isRemoveComponentWindowShown=!1,y("onRichTextRemoved")})},{"body-content":wu(()=>[rw(en(o.removeWindowDescription),1)]),_:1},8,["deps","headerText"])):Ue("",!0)]))],6)),[[z(Sd),{handler:()=>{r.isEditing=!1,z(m)&&z(m).setEditable(!1)},include:g}]])}}),plt=Qe(flt,[["__scopeId","data-v-caafc674"]]),glt=Ze({__name:"UnsubscribeLink",props:{theme:{},element:{}},emits:["onElementClicked"],setup(t,{emit:e}){const n=t,r=q(()=>{const i=z7({fontFamily:n.theme.FontFamily,fontStyle:n.element.Style,themeDefinedFontSettings:n.theme.FontSettingsPresets,themeColors:n.theme.Colors});return{...H7(i)}}),o=e;return(i,s)=>(I(),J("a",{href:"#",class:"cursor-pointer user-select-none",style:he([{margin:"0"},[r.value,z(qx)({contentAlign:n.element.ContentAlign})]]),onClick:s[0]||(s[0]=wr(()=>o("onElementClicked"),["prevent"]))},en(n.element.Text),5))}}),Clt=Qe(glt,[["__scopeId","data-v-68ed9754"]]),ylt=["src","alt"],blt={class:"bootstrap-styles position-absolute top-0 left-0",width:"100%",style:{"border-spacing":"0","border-collapse":"collapse",width:"100%",height:"100%"}},vlt={key:0},Tlt=["align"],Flt={style:{width:"auto","border-spacing":"0","border-collapse":"separate"}},xlt={align:"center",style:{width:"auto"}},Slt={key:0},wlt={key:1},klt=["align"],Elt={style:{width:"auto","border-spacing":"0","border-collapse":"separate"}},Rlt={align:"center",style:{width:"auto"}},_lt={key:2},Dlt=["align"],Alt={style:{width:"auto","border-spacing":"0","border-collapse":"separate"}},$lt={align:"center",style:{width:"auto"}},Nlt={key:3},Blt=["align"],Llt={style:{width:"auto","border-spacing":"0","border-collapse":"separate"}},Vlt={align:"center",style:{width:"auto"}},Mlt=Ze({__name:"BackgroundImage",props:{deps:{},theme:{},element:{},context:{type:[String,Number,Boolean,Array,Object]},path:{},selectedElementPath:{}},emits:["onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved","onElementWrapperClicked"],setup(t,{emit:e}){const n=t,r=Mt({src:"",href:"",isLoaded:!1}),o=async s=>n.deps.stringExpressionEvaluator({stringExpression:s,context:n.context});(async()=>(r.src=await o(n.element.Src),r.href=await o(n.element.HRef),r.isLoaded=!0))();const i=e;return(s,a)=>r.isLoaded?(I(),J("table",{key:0,class:"bootstrap-styles position-relative",style:he([{"border-spacing":"0","border-collapse":"separate"},{width:"100%"}]),onClick:a[20]||(a[20]=wr(()=>i("onElementWrapperClicked"),["prevent"]))},[R("tbody",null,[R("tr",null,[R("td",{align:"center",style:he([{height:n.element.AdjustedHeight+"px",verticalAlign:"top"}])},[It(R("img",{src:r.src,alt:r.src,style:{"max-width":"100%"}},null,8,ylt),[[z(Jx),({width:l,height:u})=>{i("onImageSizeAdjusted",{Path:n.path,AdjustedHeight:u,AdjustedWidth:l}),r.isLoaded=!0}]]),R("table",blt,[R("tbody",null,[n.element.TopElementList.List.length>0&&n.element.TopElementList.Direction==="Vertical"?(I(),J("tr",vlt,[R("td",{valign:"top",align:z(Lc)({containerAlign:n.element.TopElementList.ContentAlign})},[R("table",Flt,[R("tbody",null,[R("tr",null,[R("td",{style:he({height:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)]),(I(!0),J(ot,null,zn(n.element.TopElementList.List,(l,u)=>(I(),J(ot,{key:u},[R("tr",null,[n.element.TopElementList.ContentAlign==="Left"?(I(),J("td",{key:0,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),R("td",xlt,[ie(kl,{deps:n.deps,theme:n.theme,element:l,path:[...n.path,"TopElementList","List",u],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:a[0]||(a[0]=c=>i("onImageSizeAdjusted",c)),onOnImageOriginalSizeAdjusted:a[1]||(a[1]=c=>i("onImageOriginalSizeAdjusted",c)),onOnElementClicked:a[2]||(a[2]=c=>i("onElementClicked",c)),onOnElementUpdatedEvent:a[3]||(a[3]=c=>i("onElementUpdatedEvent",c)),onOnElementRemoved:a[4]||(a[4]=c=>i("onElementRemoved",c))},null,8,["deps","theme","element","path","selectedElementPath","context"])]),n.element.TopElementList.ContentAlign==="Right"?(I(),J("td",{key:1,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0)]),n.element.TopElementList.List.length-1!==u?(I(),J("tr",Slt,[R("td",{style:he({height:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)])):Ue("",!0)],64))),128))])])],8,Tlt)])):Ue("",!0),n.element.TopElementList.List.length>0&&n.element.TopElementList.Direction==="Horizontal"?(I(),J("tr",wlt,[R("td",{valign:"top",align:z(Lc)({containerAlign:n.element.TopElementList.ContentAlign})},[R("table",Elt,[R("tbody",null,[R("tr",null,[R("td",{style:he({height:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)]),R("tr",null,[(I(!0),J(ot,null,zn(n.element.TopElementList.List,(l,u)=>(I(),J(ot,{key:u},[n.element.TopElementList.ContentAlign==="Left"&&u===0?(I(),J("td",{key:0,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),R("td",Rlt,[ie(kl,{deps:n.deps,theme:n.theme,element:l,path:[...n.path,"TopElementList","List",u],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:a[5]||(a[5]=c=>i("onImageSizeAdjusted",c)),onOnImageOriginalSizeAdjusted:a[6]||(a[6]=c=>i("onImageOriginalSizeAdjusted",c)),onOnElementClicked:a[7]||(a[7]=c=>i("onElementClicked",c)),onOnElementUpdatedEvent:a[8]||(a[8]=c=>i("onElementUpdatedEvent",c)),onOnElementRemoved:a[9]||(a[9]=c=>i("onElementRemoved",c))},null,8,["deps","theme","element","path","selectedElementPath","context"])]),n.element.TopElementList.ContentAlign==="Center"&&n.element.TopElementList.List.length-1!==u?(I(),J("td",{key:1,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),n.element.TopElementList.ContentAlign==="Right"?(I(),J("td",{key:2,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),n.element.TopElementList.ContentAlign==="Left"&&n.element.TopElementList.List.length-1!==u?(I(),J("td",{key:3,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0)],64))),128))])])])],8,klt)])):Ue("",!0),n.element.BottomElementList.List.length>0&&n.element.BottomElementList.Direction==="Vertical"?(I(),J("tr",_lt,[R("td",{valign:"bottom",align:z(Lc)({containerAlign:n.element.BottomElementList.ContentAlign})},[R("table",Alt,[R("tbody",null,[(I(!0),J(ot,null,zn(n.element.BottomElementList.List,(l,u)=>(I(),J(ot,{key:u},[R("tr",null,[n.element.BottomElementList.ContentAlign==="Left"?(I(),J("td",{key:0,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),R("td",$lt,[ie(kl,{deps:n.deps,theme:n.theme,element:l,path:[...n.path,"BottomElementList","List",u],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:a[10]||(a[10]=c=>i("onImageSizeAdjusted",c)),onOnImageOriginalSizeAdjusted:a[11]||(a[11]=c=>i("onImageOriginalSizeAdjusted",c)),onOnElementClicked:a[12]||(a[12]=c=>i("onElementClicked",c)),onOnElementUpdatedEvent:a[13]||(a[13]=c=>i("onElementUpdatedEvent",c)),onOnElementRemoved:a[14]||(a[14]=c=>i("onElementRemoved",c))},null,8,["deps","theme","element","path","selectedElementPath","context"])]),n.element.BottomElementList.ContentAlign==="Right"?(I(),J("td",{key:1,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0)]),R("tr",null,[R("td",{style:he({height:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)])],64))),128))])])],8,Dlt)])):Ue("",!0),n.element.BottomElementList.List.length>0&&n.element.BottomElementList.Direction==="Horizontal"?(I(),J("tr",Nlt,[R("td",{valign:"bottom",align:z(Lc)({containerAlign:n.element.BottomElementList.ContentAlign})},[R("table",Llt,[R("tbody",null,[R("tr",null,[(I(!0),J(ot,null,zn(n.element.BottomElementList.List,(l,u)=>(I(),J(ot,{key:u},[n.element.BottomElementList.ContentAlign==="Left"&&u===0?(I(),J("td",{key:0,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),R("td",Vlt,[ie(kl,{deps:n.deps,theme:n.theme,element:l,path:[...n.path,"BottomElementList","List",u],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:a[15]||(a[15]=c=>i("onImageSizeAdjusted",c)),onOnImageOriginalSizeAdjusted:a[16]||(a[16]=c=>i("onImageOriginalSizeAdjusted",c)),onOnElementClicked:a[17]||(a[17]=c=>i("onElementClicked",c)),onOnElementUpdatedEvent:a[18]||(a[18]=c=>i("onElementUpdatedEvent",c)),onOnElementRemoved:a[19]||(a[19]=c=>i("onElementRemoved",c))},null,8,["deps","theme","element","path","selectedElementPath","context"])]),n.element.BottomElementList.ContentAlign==="Center"&&n.element.BottomElementList.List.length-1!==u?(I(),J("td",{key:1,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),n.element.BottomElementList.ContentAlign==="Right"?(I(),J("td",{key:2,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),n.element.BottomElementList.ContentAlign==="Left"&&n.element.BottomElementList.List.length-1!==u?(I(),J("td",{key:3,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0)],64))),128))])])])],8,Blt)])):Ue("",!0)])])],4)])])])):Ue("",!0)}}),kl=Ze({__name:"Elements",props:{deps:{},theme:{},element:{},path:{},context:{type:[String,Number,Boolean,Array,Object]},selectedElementPath:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=e,o=(i,s)=>{r("onElementClicked",{element:i,path:[...n.path,s]})};return(i,s)=>(I(),J("span",{onClick:s[31]||(s[31]=wr(()=>{},["stop"]))},[n.element.Button!==void 0?(I(),et(bnt,{key:0,deps:n.deps,theme:n.theme,element:n.element.Button,context:n.context,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"Button"])}),onOnElementClicked:s[0]||(s[0]=a=>o(n.element,"Button"))},null,8,["deps","theme","element","context","class"])):Ue("",!0),n.element.HeightContainer!==void 0?(I(),et(Ytt,{key:1,deps:n.deps,theme:n.theme,element:n.element.HeightContainer,path:[...n.path,"HeightContainer"],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageOriginalSizeAdjusted:s[1]||(s[1]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[2]||(s[2]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[3]||(s[3]=a=>r("onElementClicked",a)),onOnElementRemoved:s[4]||(s[4]=a=>r("onElementRemoved",a)),onOnElementUpdatedEvent:s[5]||(s[5]=a=>r("onElementUpdatedEvent",a))},null,8,["deps","theme","element","path","selectedElementPath","context"])):Ue("",!0),n.element.Image!==void 0?(I(),et(nnt,{key:2,deps:n.deps,theme:n.theme,element:n.element.Image,context:n.context,path:[...n.path,"Image"],class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"Image"])}),onOnImageOriginalSizeAdjusted:s[6]||(s[6]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[7]||(s[7]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[8]||(s[8]=a=>o(n.element,"Image"))},null,8,["deps","theme","element","context","path","class"])):Ue("",!0),n.element.Spacer!==void 0?(I(),et(lnt,{key:3,element:n.element.Spacer,theme:n.theme,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"Spacer"])}),onOnElementClicked:s[9]||(s[9]=a=>o(n.element,"Spacer"))},null,8,["element","theme","class"])):Ue("",!0),n.element.SpanText!==void 0?(I(),et(Fnt,{key:4,deps:n.deps,theme:n.theme,element:n.element.SpanText,context:n.context,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"SpanText"])}),onOnElementClicked:s[10]||(s[10]=a=>o(n.element,"SpanText"))},null,8,["deps","theme","element","context","class"])):Ue("",!0),n.element.RichText!==void 0?(I(),et(plt,{key:5,deps:n.deps.richTextDeps,theme:n.theme,element:n.element.RichText,isSelected:z(_f)(n.selectedElementPath,[...n.path,"RichText"]),onOnElementClicked:s[11]||(s[11]=a=>o(n.element,"RichText")),onOnRichTextUpdated:s[12]||(s[12]=a=>{r("onElementUpdatedEvent",{path:n.path,element:{RichText:a}})}),onOnRichTextRemoved:s[13]||(s[13]=()=>{r("onElementRemoved",n.path)})},null,8,["deps","theme","element","isSelected"])):Ue("",!0),n.element.OneLineList!==void 0?(I(),et(snt,{key:6,deps:n.deps,theme:n.theme,element:n.element.OneLineList,path:[...n.path,"OneLineList"],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageOriginalSizeAdjusted:s[14]||(s[14]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[15]||(s[15]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[16]||(s[16]=a=>r("onElementClicked",a)),onOnElementRemoved:s[17]||(s[17]=a=>r("onElementRemoved",a)),onOnElementUpdatedEvent:s[18]||(s[18]=a=>r("onElementUpdatedEvent",a))},null,8,["deps","theme","element","path","selectedElementPath","context"])):Ue("",!0),n.element.If!==void 0?(I(),et(Ktt,{key:7,deps:n.deps,theme:n.theme,element:n.element.If,context:n.context,path:[...n.path,"If"],selectedElementPath:n.selectedElementPath,onOnImageOriginalSizeAdjusted:s[19]||(s[19]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[20]||(s[20]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[21]||(s[21]=a=>r("onElementClicked",a)),onOnElementRemoved:s[22]||(s[22]=a=>r("onElementRemoved",a)),onOnElementUpdatedEvent:s[23]||(s[23]=a=>r("onElementUpdatedEvent",a))},null,8,["deps","theme","element","context","path","selectedElementPath"])):Ue("",!0),n.element.UnsubscribeLink!==void 0?(I(),et(Clt,{key:8,theme:n.theme,element:n.element.UnsubscribeLink,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"UnsubscribeLink"])}),onOnElementClicked:s[24]||(s[24]=a=>o(n.element,"UnsubscribeLink"))},null,8,["theme","element","class"])):Ue("",!0),n.element.BackgroundImage!==void 0?(I(),et(Mlt,{key:9,deps:n.deps,theme:n.theme,element:n.element.BackgroundImage,context:n.context,path:[...n.path,"BackgroundImage"],selectedElementPath:n.selectedElementPath,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"BackgroundImage"])}),onOnImageOriginalSizeAdjusted:s[25]||(s[25]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[26]||(s[26]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[27]||(s[27]=a=>r("onElementClicked",a)),onOnElementRemoved:s[28]||(s[28]=a=>r("onElementRemoved",a)),onOnElementUpdatedEvent:s[29]||(s[29]=a=>r("onElementUpdatedEvent",a)),onOnElementWrapperClicked:s[30]||(s[30]=a=>o(n.element,"BackgroundImage"))},null,8,["deps","theme","element","context","path","selectedElementPath","class"])):Ue("",!0)]))}}),Olt=["align"],Ilt=Ze({__name:"IteratedColumn",props:{deps:{},theme:{},iteratedColumn:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},containerWidth:{}},emits:["onImageSizeAdjusted","onImageOriginalSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(i=>({v63736150:o.value}));const n=t,r=e,o=q(()=>n.iteratedColumn.WidthInPercents*n.containerWidth+"px");return(i,s)=>(I(),J("div",{class:"iterated-column",style:he({display:"inline-block",verticalAlign:n.iteratedColumn.VerticalAlign})},[R("table",{style:he([[z(bw)({borderCollapse:n.iteratedColumn.BorderCollapse})],{width:"100%","border-spacing":"0"}]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.iteratedColumn.ContainerAlign}),style:he([[z(md)({border:n.iteratedColumn.Border,themeColors:n.theme.Colors}),{backgroundColor:z(Ll)({color:n.iteratedColumn.BgColor,themeColors:n.theme.Colors})},z(Wu)({borderRadius:n.iteratedColumn.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner})],{"line-height":"normal"}])},[(I(!0),J(ot,null,zn(n.iteratedColumn.Elements,(a,l)=>(I(),et(kl,{key:l,deps:n.deps.elementsDeps,theme:n.theme,element:a,context:n.context,path:[...n.path,"Elements",l],selectedElementPath:n.selectedElementPath,onOnElementClicked:s[0]||(s[0]=u=>r("onElementClicked",u)),onOnImageSizeAdjusted:s[1]||(s[1]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[2]||(s[2]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementUpdatedEvent:s[3]||(s[3]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[4]||(s[4]=u=>r("onElementRemoved",u))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))],12,Olt)])])],4)],4))}}),Plt=Qe(Ilt,[["__scopeId","data-v-4bdaa248"]]),Wlt=["align"],Hlt=Ze({__name:"IteratedColumnN21",props:{deps:{},theme:{},iteratedColumnN21:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},containerWidth:{}},emits:["onImageSizeAdjusted","onImageOriginalSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(i=>({v2fbddeb4:o.value}));const n=t,r=e,o=q(()=>n.iteratedColumnN21.WidthInPercents*n.containerWidth+"px");return(i,s)=>(I(),J("div",{class:"iterated-column__N-2-1",style:he({display:"inline-block",verticalAlign:n.iteratedColumnN21.VerticalAlign})},[R("table",{style:he([[z(bw)({borderCollapse:n.iteratedColumnN21.BorderCollapse})],{width:"100%","border-spacing":"0"}]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.iteratedColumnN21.ContainerAlign}),style:he([[z(md)({border:n.iteratedColumnN21.Border,themeColors:n.theme.Colors}),{backgroundColor:z(Ll)({color:n.iteratedColumnN21.BgColor,themeColors:n.theme.Colors})},z(Wu)({borderRadius:n.iteratedColumnN21.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner})],{"line-height":"normal"}])},[(I(!0),J(ot,null,zn(n.iteratedColumnN21.Elements,(a,l)=>(I(),et(kl,{key:l,deps:n.deps.elementsDeps,theme:n.theme,element:a,context:n.context,path:[...n.path,"Elements",l],selectedElementPath:n.selectedElementPath,onOnElementClicked:s[0]||(s[0]=u=>r("onElementClicked",u)),onOnImageSizeAdjusted:s[1]||(s[1]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[2]||(s[2]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementUpdatedEvent:s[3]||(s[3]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[4]||(s[4]=u=>r("onElementRemoved",u))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))],12,Wlt)])])],4)],4))}}),zlt=Qe(Hlt,[["__scopeId","data-v-b46af162"]]),jlt=["align"],Ult=Ze({__name:"IteratedColumnN22",props:{deps:{},theme:{},iteratedColumnN22:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},containerWidth:{}},emits:["onImageSizeAdjusted","onImageOriginalSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(i=>({v904d8f2c:o.value}));const n=t,r=e,o=q(()=>n.iteratedColumnN22.WidthInPercents*n.containerWidth+"px");return(i,s)=>(I(),J("div",{class:"iterated-column__N-2-2",style:he({display:"inline-block",verticalAlign:n.iteratedColumnN22.VerticalAlign})},[R("table",{style:he([[z(bw)({borderCollapse:n.iteratedColumnN22.BorderCollapse})],{width:"100%","border-spacing":"0"}]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.iteratedColumnN22.ContainerAlign}),style:he([[z(md)({border:n.iteratedColumnN22.Border,themeColors:n.theme.Colors}),{backgroundColor:z(Ll)({color:n.iteratedColumnN22.BgColor,themeColors:n.theme.Colors})},z(Wu)({borderRadius:n.iteratedColumnN22.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner})],{"line-height":"normal"}])},[(I(!0),J(ot,null,zn(n.iteratedColumnN22.Elements,(a,l)=>(I(),et(kl,{key:l,deps:n.deps.elementsDeps,theme:n.theme,element:a,context:n.context,path:[...n.path,"Elements",l],selectedElementPath:n.selectedElementPath,onOnElementClicked:s[0]||(s[0]=u=>r("onElementClicked",u)),onOnImageSizeAdjusted:s[1]||(s[1]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[2]||(s[2]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementUpdatedEvent:s[3]||(s[3]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[4]||(s[4]=u=>r("onElementRemoved",u))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))],12,jlt)])])],4)],4))}}),Klt=Qe(Ult,[["__scopeId","data-v-319c5209"]]),qlt={class:"iterated-column-container",style:{"border-spacing":"0","border-collapse":"collapse",width:"100%",margin:"0 auto"},width:"100%"},Jlt={align:"center",style:{"font-size":"0"}},Glt=Ze({__name:"IteratedColumnBodyRow",props:{deps:{},theme:{},iteratedColumnBodyRow:{},path:{},selectedElementPath:{},context:{},rowWidth:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(l=>({a80c0c96:i.value}));const n=t,r=Mt({dataList:[],isLoaded:!1}),o=()=>n.deps.listExpressionEvaluator({listExpression:n.iteratedColumnBodyRow.DataSource,context:n.context}).then(l=>{r.dataList=l,r.isLoaded=!0});o(),mn(()=>n.context,()=>o());const i=q(()=>Sr({paddingExpression:n.iteratedColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})+"px"),s={iteratedColumn:l=>l!==void 0,iteratedColumnVariant:l=>l!==void 0,iteratedColumnN21:l=>l!==void 0,iteratedColumnN22:l=>l!==void 0},a=e;return(l,u)=>(I(),J("table",qlt,[R("tbody",null,[R("tr",null,[R("td",Jlt,[(I(!0),J(ot,null,zn(r.dataList,(c,d)=>(I(),J(ot,{key:d},[s.iteratedColumn(n.iteratedColumnBodyRow.IteratedColumn)?(I(),et(Plt,{key:d,class:Me(["iterated-column-bottom-spacer",{"iterated-column__tablet-padding-right":(d+1)%2===1,"iterated-column__tablet-padding-left":(d+1)%2===0,"is-last-desktop-line":d>=r.dataList.length-n.iteratedColumnBodyRow.NumberColumnsInLine,"is-last-tablet-line":d>=r.dataList.length-2,"is-last-mobile-line":d==r.dataList.length-1}]),deps:n.deps.iteratedColumnDeps,theme:n.theme,style:he(z(u_)({numberColumnsInLine:n.iteratedColumnBodyRow.NumberColumnsInLine,index:d,paddingSize:z(Sr)({paddingExpression:n.iteratedColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),directionRtl:!1})),iteratedColumn:n.iteratedColumnBodyRow.IteratedColumn,path:[...n.path,"IteratedColumn"],selectedElementPath:n.selectedElementPath,context:{...n.context,[n.iteratedColumnBodyRow.IndexName]:c},containerWidth:n.rowWidth,onOnElementClicked:u[0]||(u[0]=h=>a("onElementClicked",h)),onOnImageOriginalSizeAdjusted:u[1]||(u[1]=h=>a("onImageOriginalSizeAdjusted",h)),onOnImageSizeAdjusted:u[2]||(u[2]=h=>a("onImageSizeAdjusted",h)),onOnElementUpdatedEvent:u[3]||(u[3]=h=>a("onElementUpdatedEvent",h)),onOnElementRemoved:u[4]||(u[4]=h=>a("onElementRemoved",h))},null,8,["deps","theme","class","style","iteratedColumn","path","selectedElementPath","context","containerWidth"])):Ue("",!0),s.iteratedColumnVariant(n.iteratedColumnBodyRow.IteratedColumnVariant)?(I(),J(ot,{key:1},[s.iteratedColumnN21(n.iteratedColumnBodyRow.IteratedColumnVariant.IteratedColumnN21)?(I(),et(zlt,{key:d,deps:n.deps.iteratedColumnVariantDeps.iteratedColumnN21Deps,theme:n.theme,class:Me(["iterated-column-bottom-spacer",{"iterated-column__tablet-padding-right":(d+1)%2===1,"iterated-column__tablet-padding-left":(d+1)%2===0,"is-last-desktop-line":d>=r.dataList.length-n.iteratedColumnBodyRow.NumberColumnsInLine,"is-last-tablet-line":d>=r.dataList.length-2,"is-last-mobile-line":d==r.dataList.length-1}]),style:he(z(u_)({numberColumnsInLine:n.iteratedColumnBodyRow.NumberColumnsInLine,index:d,paddingSize:z(Sr)({paddingExpression:n.iteratedColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),directionRtl:!1})),iteratedColumnN21:n.iteratedColumnBodyRow.IteratedColumnVariant.IteratedColumnN21,path:[...n.path,"IteratedColumnVariant","IteratedColumnN21"],selectedElementPath:n.selectedElementPath,context:{...n.context,[n.iteratedColumnBodyRow.IndexName]:c},containerWidth:n.rowWidth,onOnElementClicked:u[5]||(u[5]=h=>a("onElementClicked",h)),onOnImageOriginalSizeAdjusted:u[6]||(u[6]=h=>a("onImageOriginalSizeAdjusted",h)),onOnImageSizeAdjusted:u[7]||(u[7]=h=>a("onImageSizeAdjusted",h)),onOnElementUpdatedEvent:u[8]||(u[8]=h=>a("onElementUpdatedEvent",h)),onOnElementRemoved:u[9]||(u[9]=h=>a("onElementRemoved",h))},null,8,["deps","theme","class","style","iteratedColumnN21","path","selectedElementPath","context","containerWidth"])):Ue("",!0),s.iteratedColumnN22(n.iteratedColumnBodyRow.IteratedColumnVariant.IteratedColumnN22)?(I(),et(Klt,{key:d,deps:n.deps.iteratedColumnVariantDeps.iteratedColumnN22Deps,theme:n.theme,class:Me(["iterated-column-bottom-spacer",{"iterated-column__tablet-padding-right iterated-column__N-2-2_mobile-padding-right":(d+1)%2===1,"iterated-column__tablet-padding-left iterated-column__N-2-2_mobile-padding-left":(d+1)%2===0,"is-last-desktop-line":d>=r.dataList.length-n.iteratedColumnBodyRow.NumberColumnsInLine,"is-last-tablet-line is-last-mobile-line":d>=r.dataList.length-2}]),style:he(z(u_)({numberColumnsInLine:n.iteratedColumnBodyRow.NumberColumnsInLine,index:d,paddingSize:z(Sr)({paddingExpression:n.iteratedColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),directionRtl:!1})),iteratedColumnN22:n.iteratedColumnBodyRow.IteratedColumnVariant.IteratedColumnN22,path:[...n.path,"IteratedColumnVariant","IteratedColumnN22"],selectedElementPath:n.selectedElementPath,context:{...n.context,[n.iteratedColumnBodyRow.IndexName]:c},containerWidth:n.rowWidth,onOnElementClicked:u[10]||(u[10]=h=>a("onElementClicked",h)),onOnImageOriginalSizeAdjusted:u[11]||(u[11]=h=>a("onImageOriginalSizeAdjusted",h)),onOnImageSizeAdjusted:u[12]||(u[12]=h=>a("onImageSizeAdjusted",h)),onOnElementUpdatedEvent:u[13]||(u[13]=h=>a("onElementUpdatedEvent",h)),onOnElementRemoved:u[14]||(u[14]=h=>a("onElementRemoved",h))},null,8,["deps","theme","class","style","iteratedColumnN22","path","selectedElementPath","context","containerWidth"])):Ue("",!0)],64)):Ue("",!0)],64))),128))])])])]))}}),Ylt=Qe(Glt,[["__scopeId","data-v-69ed8d34"]]),Xlt={style:{"border-spacing":"0","border-collapse":"collapse",width:"100%",margin:"0 auto"}},Qlt=Ze({__name:"IteratedBodyRow",props:{theme:{},deps:{},iteratedBodyRow:{},path:{},selectedElementPath:{},context:{},containerWidth:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=Mt({dataList:[]});n.deps.listExpressionEvaluator({listExpression:n.iteratedBodyRow.DataSource,context:n.context}).then(i=>r.dataList=i);const o=e;return(i,s)=>(I(),J("table",Xlt,[(I(!0),J(ot,null,zn(r.dataList,(a,l)=>(I(),J("tr",{key:l},[R("td",{style:he([z(vw)({paddings:n.iteratedBodyRow.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})])},[ie(cbe,{emailComponentBodyRow:n.iteratedBodyRow.BodyRow,deps:{iteratedColumnBodyRowDeps:n.deps.iteratedColumnBodyRowDeps,multipleColumnBodyRowDeps:n.deps.multipleColumnBodyRowDeps,listExpressionEvaluator:n.deps.listExpressionEvaluator},theme:n.theme,context:{...n.context,[n.iteratedBodyRow.IndexName]:a},rowWidth:n.containerWidth,path:[...n.path,"BodyRow"],selectedElementPath:n.selectedElementPath,onOnElementClicked:s[0]||(s[0]=u=>o("onElementClicked",u)),onOnImageOriginalSizeAdjusted:s[1]||(s[1]=u=>o("onImageOriginalSizeAdjusted",u)),onOnImageSizeAdjusted:s[2]||(s[2]=u=>o("onImageSizeAdjusted",u)),onOnColumnWidthAdjusted:s[3]||(s[3]=u=>o("onColumnWidthAdjusted",u)),onOnElementUpdatedEvent:s[4]||(s[4]=u=>o("onElementUpdatedEvent",u)),onOnElementRemoved:s[5]||(s[5]=u=>o("onElementRemoved",u))},null,8,["emailComponentBodyRow","deps","theme","context","rowWidth","path","selectedElementPath"])],4)]))),128))]))}}),Zlt=t=>({Match:e=>{switch(t){case"Top":return e.Top();case"Middle":return e.Middle();case"Bottom":return e.Bottom();case"Baseline":return e.Baseline()}}}),eut=t=>Zlt(t).Match({Top:()=>"start",Middle:()=>"center",Bottom:()=>"end",Baseline:()=>"baseline"}),tut=Wl,nut=t=>({JustifyWidth:{WidthInPixels:t}}),rut=t=>({ShrinkToContentWidth:{WidthInPixels:t}}),out=Vtt,iut=["align"],sut=Ze({__name:"MultipleColumn",props:{deps:{},theme:{},multipleColumn:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},containerWidth:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(l=>({acad954c:a.value,v1971599c:s.value,v72b8524e:i.value}));const n=t,r=e,o=l=>{tut(n.multipleColumn.Width).Match({JustifyWidth:()=>DI.Some(nut(l)),ShrinkToContentWidth:()=>DI.Some(rut(l)),WidthInPercents:()=>DI.None}).map(u=>r("onColumnWidthAdjusted",{Path:n.path,Width:u}))},i=q(()=>out(n.multipleColumn.Width).Match({default:()=>"",WidthInPercents:l=>l.Value*n.containerWidth+"px"})),s=q(()=>eut(n.multipleColumn.VerticalAlign)),a=q(()=>n.multipleColumn.VerticalAlign);return(l,u)=>It((I(),J("div",{class:Me(["multiple-column",{"multiple-column--justifyWidth":n.multipleColumn.Width.JustifyWidth!==void 0,"multiple-column--shrinkToContentWidth":n.multipleColumn.Width.ShrinkToContentWidth!==void 0,"multiple-column--widthInPercents":n.multipleColumn.Width.WidthInPercents!==void 0}]),style:{direction:"ltr"}},[R("table",{style:he([{width:"100%","border-spacing":"0"},[z(bw)({borderCollapse:n.multipleColumn.BorderCollapse})]]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.multipleColumn.ContainerAlign}),style:he([[z(md)({border:n.multipleColumn.Border,themeColors:n.theme.Colors}),z(Wu)({borderRadius:n.multipleColumn.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner}),{backgroundColor:z(Ll)({color:n.multipleColumn.BgColor,themeColors:n.theme.Colors})},z(vw)({paddings:n.multipleColumn.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})],{"line-height":"normal"}])},[(I(!0),J(ot,null,zn(n.multipleColumn.Elements,(c,d)=>(I(),et(kl,{key:d,deps:n.deps.elementsDeps,theme:n.theme,element:c,context:n.context,path:[...n.path,"Elements",d],selectedElementPath:n.selectedElementPath,onOnElementClicked:u[0]||(u[0]=h=>r("onElementClicked",h)),onOnImageSizeAdjusted:u[1]||(u[1]=h=>r("onImageSizeAdjusted",h)),onOnImageOriginalSizeAdjusted:u[2]||(u[2]=h=>r("onImageOriginalSizeAdjusted",h)),onOnElementUpdatedEvent:u[3]||(u[3]=h=>r("onElementUpdatedEvent",h)),onOnElementRemoved:u[4]||(u[4]=h=>r("onElementRemoved",h))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))],12,iut)])])],4)],2)),[[z(Jx),c=>o(c.width)]])}}),aut=Qe(sut,[["__scopeId","data-v-bfa1869f"]]),lut=Ze({__name:"MultipleColumnBodyRow",props:{deps:{},theme:{},multipleColumnBodyRow:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},rowWidth:{}},emits:["onElementClicked","onImageSizeAdjusted","onImageOriginalSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(i=>({v36e68443:o.value}));const n=t,r=e,o=q(()=>Sr({paddingExpression:n.multipleColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})+"px");return(i,s)=>(I(),J("table",{class:"multiple-column-container",style:he([[z(bw)({borderCollapse:n.multipleColumnBodyRow.BorderCollapse}),z(md)({border:n.multipleColumnBodyRow.Border,themeColors:n.theme.Colors}),z(Wu)({borderRadius:n.multipleColumnBodyRow.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner}),{backgroundColor:z(Ll)({color:n.multipleColumnBodyRow.BgColor,themeColors:n.theme.Colors})}],{"border-spacing":"0",width:"100%",margin:"0 auto"}]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{class:"multiple-column-container__inner",style:he([{"font-size":"0"},[z(Utt)({containerAlign:n.multipleColumnBodyRow.ContainerAlign}),z(vw)({paddings:n.multipleColumnBodyRow.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),n.multipleColumnBodyRow.DirectionRtl?{direction:"rtl"}:{direction:"ltr"}]])},[(I(!0),J(ot,null,zn(n.multipleColumnBodyRow.Columns,(a,l)=>(I(),et(aut,{key:l,deps:n.deps.multipleColumnDeps,theme:n.theme,multipleColumn:a,path:[...n.path,"Columns",l],selectedElementPath:n.selectedElementPath,context:n.context,containerWidth:n.rowWidth-z(Sr)({paddingExpression:n.multipleColumnBodyRow.Paddings.Left,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})-z(Sr)({paddingExpression:n.multipleColumnBodyRow.Paddings.Right,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})-n.multipleColumnBodyRow.Border.Left.Width-n.multipleColumnBodyRow.Border.Right.Width,style:he(z(u_)({numberColumnsInLine:n.multipleColumnBodyRow.Columns.length,index:l,paddingSize:z(Sr)({paddingExpression:n.multipleColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),directionRtl:n.multipleColumnBodyRow.DirectionRtl})),class:Me({"is-last-tablet-line":l==n.multipleColumnBodyRow.Columns.length-1,"is-last-mobile-line":l==n.multipleColumnBodyRow.Columns.length-1}),onOnElementClicked:s[0]||(s[0]=u=>r("onElementClicked",u)),onOnColumnWidthAdjusted:s[1]||(s[1]=u=>r("onColumnWidthAdjusted",u)),onOnImageSizeAdjusted:s[2]||(s[2]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[3]||(s[3]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementUpdatedEvent:s[4]||(s[4]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[5]||(s[5]=u=>r("onElementRemoved",u))},null,8,["deps","theme","multipleColumn","path","selectedElementPath","context","containerWidth","style","class"]))),128))],4)])])],4))}}),uut=Qe(lut,[["__scopeId","data-v-c6ebdc94"]]),cbe=Ze({__name:"EmailComponentBodyRow",props:{deps:{},theme:{},emailComponentBodyRow:{},path:{},selectedElementPath:{},context:{},rowWidth:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r={multipleColumns:i=>i!==void 0,iteratedColumns:i=>i!==void 0,iteratedBodyRow:i=>i!==void 0},o=e;return(i,s)=>(I(),J("div",null,[r.multipleColumns(n.emailComponentBodyRow.MultipleColumnBodyRow)?(I(),et(uut,{key:0,deps:n.deps.multipleColumnBodyRowDeps,theme:n.theme,multipleColumnBodyRow:n.emailComponentBodyRow.MultipleColumnBodyRow,path:[...n.path,"MultipleColumnBodyRow"],selectedElementPath:n.selectedElementPath,context:t.context,rowWidth:n.rowWidth,onOnColumnWidthAdjusted:s[0]||(s[0]=a=>o("onColumnWidthAdjusted",a)),onOnImageOriginalSizeAdjusted:s[1]||(s[1]=a=>o("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[2]||(s[2]=a=>o("onImageSizeAdjusted",a)),onOnElementClicked:s[3]||(s[3]=a=>o("onElementClicked",a)),onOnElementUpdatedEvent:s[4]||(s[4]=a=>o("onElementUpdatedEvent",a)),onOnElementRemoved:s[5]||(s[5]=a=>o("onElementRemoved",a))},null,8,["deps","theme","multipleColumnBodyRow","path","selectedElementPath","context","rowWidth"])):Ue("",!0),r.iteratedColumns(n.emailComponentBodyRow.IteratedColumnBodyRow)?(I(),et(Ylt,{key:1,deps:n.deps.iteratedColumnBodyRowDeps,theme:n.theme,iteratedColumnBodyRow:n.emailComponentBodyRow.IteratedColumnBodyRow,path:[...n.path,"IteratedColumnBodyRow"],selectedElementPath:n.selectedElementPath,context:t.context,rowWidth:n.rowWidth,onOnElementClicked:s[6]||(s[6]=a=>o("onElementClicked",a)),onOnImageOriginalSizeAdjusted:s[7]||(s[7]=a=>o("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[8]||(s[8]=a=>o("onImageSizeAdjusted",a)),onOnElementUpdatedEvent:s[9]||(s[9]=a=>o("onElementUpdatedEvent",a)),onOnElementRemoved:s[10]||(s[10]=a=>o("onElementRemoved",a))},null,8,["deps","theme","iteratedColumnBodyRow","path","selectedElementPath","context","rowWidth"])):Ue("",!0),r.iteratedBodyRow(n.emailComponentBodyRow.IteratedBodyRow)?(I(),et(Qlt,{key:2,deps:{iteratedColumnBodyRowDeps:n.deps.iteratedColumnBodyRowDeps,multipleColumnBodyRowDeps:n.deps.multipleColumnBodyRowDeps,listExpressionEvaluator:n.deps.listExpressionEvaluator},theme:n.theme,iteratedBodyRow:n.emailComponentBodyRow.IteratedBodyRow,path:[...n.path,"IteratedBodyRow"],selectedElementPath:n.selectedElementPath,context:t.context,containerWidth:n.rowWidth,onOnElementClicked:s[11]||(s[11]=a=>o("onElementClicked",a)),onOnImageOriginalSizeAdjusted:s[12]||(s[12]=a=>o("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[13]||(s[13]=a=>o("onImageSizeAdjusted",a)),onOnElementUpdatedEvent:s[14]||(s[14]=a=>o("onElementUpdatedEvent",a)),onOnElementRemoved:s[15]||(s[15]=a=>o("onElementRemoved",a))},null,8,["deps","theme","iteratedBodyRow","path","selectedElementPath","context","containerWidth"])):Ue("",!0)]))}}),cut={emptyEmailComponentText:"Product shelf is hidden due to insufficient products",emptyEmailComponentTooltip:"The product shelf won't be displayed to recipients until it contains enough products",requiredComponentNotification:"Without this component the letter will not be sent"},dut={emptyEmailComponentText:"Товарная полка скрыта из-за недостатка товаров",emptyEmailComponentTooltip:"Товарная полка не будет отображаться у получателей письма пока в ней недостаточно товаров",requiredComponentNotification:"Без этого компонента письмо не будет отправлено"},GI=jn({en:cut,ru:dut}),hut={},mut={width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function fut(t,e){return I(),J("svg",mut,[...e[0]||(e[0]=[R("path",{d:"M6.99967 13.6663C3.31777 13.6663 0.333008 10.6815 0.333008 6.99967C0.333008 3.31777 3.31777 0.333008 6.99967 0.333008C10.6815 0.333008 13.6663 3.31777 13.6663 6.99967C13.6663 10.6815 10.6815 13.6663 6.99967 13.6663ZM6.99967 12.333C9.94521 12.333 12.333 9.94521 12.333 6.99967C12.333 4.05415 9.94521 1.66634 6.99967 1.66634C4.05415 1.66634 1.66634 4.05415 1.66634 6.99967C1.66634 9.94521 4.05415 12.333 6.99967 12.333ZM6.33301 3.66634H7.66634V4.99967H6.33301V3.66634ZM6.33301 6.33301H7.66634V10.333H6.33301V6.33301Z",fill:"var(--gray-500)"},null,-1)])])}const put=Qe(hut,[["render",fut]]),gut={key:0},Cut={key:0,class:"is-required-notification"},yut={class:"bootstrap-styles w-100 d-flex justify-content-center gap-5"},but=Ze({__name:"EmailComponent",props:{deps:{},theme:{},emailComponent:{},path:{},selectedElementPath:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=Mt({context:{},ifResult:!n.emailComponent.ContextBuilderExpression,isLoaded:!1}),o={emptyEmailComponentText:GI({localeKey:n.deps.localeKey}).emptyEmailComponentText,emptyEmailComponentTooltip:GI({localeKey:n.deps.localeKey}).emptyEmailComponentTooltip,requiredComponentNotification:GI({localeKey:n.deps.localeKey}).requiredComponentNotification},i=a=>{r.isLoaded=!1,n.deps.dataStructExpressionEvaluator({dataStructBuilderExpression:a,context:{}}).then(l=>{(n.emailComponent.IfExpression?n.deps.boolExpressionEvaluatorDelegate({boolExpression:n.emailComponent.IfExpression,context:l}):Promise.resolve(!0)).then(u=>{r.context=l,r.ifResult=u,r.isLoaded=!0})})};mn(()=>n.emailComponent.ContextBuilderExpression,a=>{a&&i(a)});const s=e;return n.emailComponent.ContextBuilderExpression?i(n.emailComponent.ContextBuilderExpression):r.isLoaded=!0,(a,l)=>r.isLoaded?(I(),J("div",gut,[n.emailComponent.IsRequired?(I(),J("div",Cut,[R("i",null,[ie(put)]),R("span",null,"   "+en(o.requiredComponentNotification),1)])):Ue("",!0),r.ifResult?(I(),J("table",{key:1,style:he([[{backgroundColor:z(Ll)({color:n.emailComponent.InnerBgColor,themeColors:n.theme.Colors})},z(Wu)({borderRadius:n.emailComponent.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner}),{maxWidth:n.theme.BodyWidth+"px"}],{"border-spacing":"0","border-collapse":"collapse",width:"100%",margin:"0 auto"}])},[R("tbody",null,[R("tr",null,[R("td",{class:"row__inner",style:he([z(Cee)({paddings:n.emailComponent.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings,fullWidth:n.emailComponent.FullWidth})])},[(I(!0),J(ot,null,zn(n.emailComponent.BodyRowList,(u,c)=>(I(),et(cbe,{key:c,deps:n.deps.emailComponentBodyRowDeps,theme:n.theme,emailComponentBodyRow:u,context:r.context,rowWidth:n.emailComponent.FullWidth?n.theme.BodyWidth:n.theme.BodyWidth-n.theme.BodyPaddings.Left-n.theme.BodyPaddings.Right,path:[...n.path,"BodyRowList",c],selectedElementPath:n.selectedElementPath,onOnElementClicked:l[0]||(l[0]=d=>s("onElementClicked",d)),onOnImageSizeAdjusted:l[1]||(l[1]=d=>s("onImageSizeAdjusted",d)),onOnImageOriginalSizeAdjusted:l[2]||(l[2]=d=>s("onImageOriginalSizeAdjusted",d)),onOnColumnWidthAdjusted:l[3]||(l[3]=d=>s("onColumnWidthAdjusted",d)),onOnElementUpdatedEvent:l[4]||(l[4]=d=>s("onElementUpdatedEvent",d)),onOnElementRemoved:l[5]||(l[5]=d=>s("onElementRemoved",d))},null,8,["deps","theme","emailComponentBodyRow","context","rowWidth","path","selectedElementPath"]))),128))],4)])])],4)):(I(),J("div",{key:2,class:Me(["empty-email-component",{"is-required-component__paddings":n.emailComponent.IsRequired}])},[rw(en(o.emptyEmailComponentText)+" ",1),It((I(),J("i",null,[...l[6]||(l[6]=[R("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[R("path",{d:"M6.99967 13.6663C3.31777 13.6663 0.333008 10.6815 0.333008 6.99967C0.333008 3.31777 3.31777 0.333008 6.99967 0.333008C10.6815 0.333008 13.6663 3.31777 13.6663 6.99967C13.6663 10.6815 10.6815 13.6663 6.99967 13.6663ZM6.99967 12.333C9.94521 12.333 12.333 9.94521 12.333 6.99967C12.333 4.05415 9.94521 1.66634 6.99967 1.66634C4.05415 1.66634 1.66634 4.05415 1.66634 6.99967C1.66634 9.94521 4.05415 12.333 6.99967 12.333ZM6.33301 3.66634H7.66634V4.99967H6.33301V3.66634ZM6.33301 6.33301H7.66634V10.333H6.33301V6.33301Z",fill:"var(--gray-500)"})],-1)])])),[[z(Br),{placement:"top",title:o.emptyEmailComponentTooltip}]])],2))])):(I(),J("div",{key:1,class:"bootstrap-styles w-100",style:he([z(Cee)({paddings:n.emailComponent.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings,fullWidth:n.emailComponent.FullWidth}),{backgroundColor:z(Ll)({color:n.emailComponent.InnerBgColor,themeColors:n.theme.Colors})||"transparent"}])},[ie(z($Z),{type:"text"}),R("div",yut,[(I(),J(ot,null,zn(3,u=>ie(z($Z),{key:u,type:"image, text, text, text, button",style:{width:"100%"}})),64))])],4))}}),dbe=Qe(but,[["__scopeId","data-v-38fe975b"]]),vut={class:"scale-to-width-fit-component",style:{display:"inline-block","transform-origin":"left top"}},hbe=Ze({__name:"ScaleToWidthFit",emits:["scaledElement"],setup(t,{emit:e}){const n=e;return(r,o)=>It((I(),J("div",vut,[M0(r.$slots,"default")])),[[z(Jx),({width:i})=>{r.$el.style.transform=`scale(${r.$el.parentElement.clientWidth/i}`,n("scaledElement",r.$el)}]])}}),Tut={title:"Preview",applyButton:"Select",cancelButton:"Cancel"},Fut={title:"Предпросмотр",applyButton:"Выбрать",cancelButton:"Отмена"},YI=jn({en:Tut,ru:Fut}),xut={class:"email-template-preview__inner-padding scrollable"},Sut={class:"emailTemplate-border-top"},wut={class:"emailTemplate-border-bottom"},kut=Ze({__name:"TemplatePreviewModalWindow",props:{template:{},deps:{}},emits:["templateSelected","close"],setup(t,{emit:e}){const n=t,r={title:YI({localeKey:n.deps.localeKey}).title,applyButton:YI({localeKey:n.deps.localeKey}).applyButton,cancelButton:YI({localeKey:n.deps.localeKey}).cancelButton},o=s=>{const a=s.parentElement;a&&(a.style.height=s.getBoundingClientRect().height+"px")},i=e;return(s,a)=>(I(),et(z0e,{headerText:r.title,class:"email-component__preview-modal-window",onClose:a[3]||(a[3]=()=>i("close"))},{body:wu(()=>[R("div",{style:he({backgroundColor:t.template.Theme.Colors.EmailBackgroundColor})},[ie(hbe,{onScaledElement:a[0]||(a[0]=l=>o(l))},{default:wu(()=>[R("div",xut,[R("div",{class:"bootstrap-styles pe-none email-template-preview",style:he({fontFamily:n.template.Theme.FontFamily,width:t.template.Theme.BodyWidth+"px"})},[R("div",{class:"webkit emailTemplate--desktop",style:he({borderTopLeftRadius:n.template.Theme.BorderRadius.TopLeft+"px",borderTopRightRadius:n.template.Theme.BorderRadius.TopRight+"px",borderBottomLeftRadius:n.template.Theme.BorderRadius.BottomLeft+"px",borderBottomRightRadius:n.template.Theme.BorderRadius.BottomRight+"px"})},[R("div",Sut,[R("table",{style:he([[{maxWidth:n.template.Theme.BodyWidth+"px",width:"100%"}],{"border-spacing":"0"}])},[R("tbody",null,[R("tr",null,[R("td",{style:he([{paddingTop:n.template.Theme.BodyPaddings.Top+"px"},{"font-size":"0","line-height":"0"}])},"   ",4)])])],4)]),(I(!0),J(ot,null,zn(n.template.Components,(l,u)=>(I(),J("div",{key:u},[ie(dbe,{deps:t.deps.emailComponentDeps,theme:n.template.Theme,emailComponent:l,path:[],selectedElementPath:[]},null,8,["deps","theme","emailComponent"])]))),128)),R("div",wut,[R("table",{style:he([[{maxWidth:n.template.Theme.BodyWidth+"px",width:"100%"}],{"border-spacing":"0"}])},[R("tbody",null,[R("tr",null,[R("td",{style:he([{paddingBottom:n.template.Theme.BodyPaddings.Bottom+"px"},{"font-size":"0","line-height":"0"}])},"   ",4)])])],4)])],4)],4)])]),_:1})],4)]),"footer-actions":wu(()=>[R("button",{type:"button",class:"modal-footer__button bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-3 rounded-2 bg-blue-selected button__hover-blue-100 text-color-selected",onClick:a[1]||(a[1]=wr(()=>i("close"),["stop"]))},en(r.cancelButton),1),R("button",{type:"submit",class:"modal-footer__button bootstrap-styles d-flex justify-content-center align-center py-1 px-3 rounded-2 bg-color-selected text-white cursor-pointer button__hover-blue-400",onClick:a[2]||(a[2]=()=>{i("templateSelected",n.template)})},en(r.applyButton),1)]),_:1},8,["headerText"]))}}),Eut=Qe(kut,[["__scopeId","data-v-eb5433f4"]]),Rut={class:"favorite-template-select__item-wrapper"},_ut={class:"favorite-template-select__item bootstrap-styles border rounded-3"},Dut={class:"email-template-preview__inner-padding scrollable"},Aut={class:"emailTemplate-border-top"},$ut={class:"emailTemplate-border-bottom"},Nut=Ze({__name:"TemplatePreviewCard",props:{deps:{},template:{},templateName:{}},emits:["templateSelected"],setup(t,{emit:e}){Pm(k=>({fe9947d8:s.value,v34e7e85f:a.value,v3793be74:i.value.Title.fontWeight,v1a5ad760:i.value.Title.fontFamily,v5b86af14:i.value.Title.color,v2e8d120a:i.value.Title.textDecoration,v70699b96:i.value.Title.fontStyle,v3a1cf2be:l.value,v3a467c89:u.value,v74e45a6c:i.value.Heading.fontWeight,af562894:i.value.Heading.fontFamily,v31de9340:i.value.Heading.color,v4e190b60:i.value.Heading.textDecoration,v16b23b1f:i.value.Heading.fontStyle,v0401dcf4:c.value,e3c7ed5e:d.value,efc37348:i.value.SubHeading.fontWeight,v6ae55f48:i.value.SubHeading.fontFamily,v71e6cf8e:i.value.SubHeading.color,b57d341c:i.value.SubHeading.textDecoration,ad47e566:i.value.SubHeading.fontStyle,v5af2b2c4:h.value,v7cac530f:m.value,v2325bf78:i.value.LargeText.fontWeight,v5d978da0:i.value.LargeText.fontFamily,v02e164a6:i.value.LargeText.color,v33410bda:i.value.LargeText.textDecoration,v62565665:i.value.LargeText.fontStyle,v54d3ba98:f.value,fb2a943a:p.value,v1da52c0a:i.value.NormalText.fontWeight,v006c44f6:i.value.NormalText.fontFamily,v14d2d5c0:i.value.NormalText.color,a73c76c0:i.value.NormalText.textDecoration,c4aa8c42:i.value.NormalText.fontStyle,v735bb105:g.value,v1ecec510:y.value,v02590823:i.value.DescriptionText.fontWeight,v35bfbde2:i.value.DescriptionText.fontFamily,v63cdcd67:i.value.DescriptionText.color,v1d27ec39:i.value.DescriptionText.textDecoration,v316e76a6:i.value.DescriptionText.fontStyle,v6c4cc8de:b.value,c04d6aae:F.value,aefb3c78:i.value.Link.fontWeight,e96d0aa0:i.value.Link.fontFamily,v75e93326:i.value.Link.color,v75d98d5a:i.value.Link.textDecoration,v57d2e4e5:i.value.Link.fontStyle,v6f4d39d4:T.value,v2b2836e1:v.value,v5ecd1d68:i.value.Button.fontWeight,v993eeb90:i.value.Button.fontFamily,v74f88e9e:i.value.Button.color,d564ce3c:i.value.Button.textDecoration,v4057c45d:i.value.Button.fontStyle}));const n=t,r=Mt({isPreviewComponentModalWindowShown:!1}),o=k=>{const _=k.parentElement;_&&(_.style.height=k.getBoundingClientRect().height+"px")},i=q(()=>{const{FontFamily:k,FontSettingsPresets:_,Colors:D}=n.template.Theme;return{Title:us({fontFamily:k,themeFontSettings:_.Title,themeColor:D.TitleColor}),Heading:us({fontFamily:k,themeFontSettings:_.Heading,themeColor:D.HeadingColor}),SubHeading:us({fontFamily:k,themeFontSettings:_.SubHeading,themeColor:D.SubHeadingColor}),LargeText:us({fontFamily:k,themeFontSettings:_.LargeText,themeColor:D.LargeTextColor}),NormalText:us({fontFamily:k,themeFontSettings:_.NormalText,themeColor:D.NormalTextColor}),DescriptionText:us({fontFamily:k,themeFontSettings:_.DescriptionText,themeColor:D.DescriptionTextColor}),Link:us({fontFamily:k,themeFontSettings:_.Link,themeColor:D.LinkColor}),Button:us({fontFamily:k,themeFontSettings:_.Button,themeColor:D.ButtonTextColor})}}),s=q(()=>i.value.Title.fontSize+"px"),a=q(()=>i.value.Title.lineHeight+"px"),l=q(()=>i.value.Heading.fontSize+"px"),u=q(()=>i.value.Heading.lineHeight+"px"),c=q(()=>i.value.SubHeading.fontSize+"px"),d=q(()=>i.value.SubHeading.lineHeight+"px"),h=q(()=>i.value.LargeText.fontSize+"px"),m=q(()=>i.value.LargeText.lineHeight+"px"),f=q(()=>i.value.NormalText.fontSize+"px"),p=q(()=>i.value.NormalText.lineHeight+"px"),g=q(()=>i.value.DescriptionText.fontSize+"px"),y=q(()=>i.value.DescriptionText.lineHeight+"px"),b=q(()=>i.value.Link.fontSize+"px"),F=q(()=>i.value.Link.lineHeight+"px"),T=q(()=>i.value.Button.fontSize+"px"),v=q(()=>i.value.Button.lineHeight+"px"),w=e;return(k,_)=>(I(),J("div",Rut,[R("div",_ut,[R("div",{class:"bootstrap-styles h-100",style:he({backgroundColor:n.template.Theme.Colors.EmailBackgroundColor}),onClick:_[1]||(_[1]=()=>{r.isPreviewComponentModalWindowShown=!0})},[ie(hbe,{onScaledElement:_[0]||(_[0]=D=>o(D))},{default:wu(()=>[R("div",Dut,[R("div",{class:"bootstrap-styles pe-none email-template-preview",style:he({fontFamily:n.template.Theme.FontFamily,width:t.template.Theme.BodyWidth+"px"})},[R("div",{class:"webkit emailTemplate--desktop",style:he({backgroundColor:n.template.Theme.Colors.BodyColor,borderTopLeftRadius:n.template.Theme.BorderRadius.TopLeft+"px",borderTopRightRadius:n.template.Theme.BorderRadius.TopRight+"px",borderBottomLeftRadius:n.template.Theme.BorderRadius.BottomLeft+"px",borderBottomRightRadius:n.template.Theme.BorderRadius.BottomRight+"px"})},[R("div",Aut,[R("table",{style:he([[{maxWidth:n.template.Theme.BodyWidth+"px",width:"100%"}],{"border-spacing":"0"}])},[R("tbody",null,[R("tr",null,[R("td",{style:he([{paddingTop:n.template.Theme.BodyPaddings.Top+"px"},{"font-size":"0","line-height":"0"}])},"   ",4)])])],4)]),(I(!0),J(ot,null,zn(n.template.Components,(D,L)=>(I(),J("div",{key:L},[ie(dbe,{deps:n.deps.emailComponentDeps,theme:n.template.Theme,emailComponent:D,path:[],selectedElementPath:[]},null,8,["deps","theme","emailComponent"])]))),128)),R("div",$ut,[R("table",{style:he([[{maxWidth:n.template.Theme.BodyWidth+"px",width:"100%"}],{"border-spacing":"0"}])},[R("tbody",null,[R("tr",null,[R("td",{style:he([{paddingBottom:n.template.Theme.BodyPaddings.Bottom+"px"},{"font-size":"0","line-height":"0"}])},"   ",4)])])],4)])],4)],4)])]),_:1})],4),(I(),et(Yj,{to:"#app"},[r.isPreviewComponentModalWindowShown?(I(),et(Eut,{key:0,template:n.template,deps:n.deps.templatePreviewModalWindowDeps,onClose:_[2]||(_[2]=()=>r.isPreviewComponentModalWindowShown=!1),onTemplateSelected:_[3]||(_[3]=()=>w("templateSelected",n.template))},null,8,["template","deps"])):Ue("",!0)]))]),R("div",{class:"bootstrap-styles favorite-template__name mt-2",onClick:_[4]||(_[4]=()=>{r.isPreviewComponentModalWindowShown=!0})},en(n.templateName),1)]))}}),But=Qe(Nut,[["__scopeId","data-v-d98cb6f0"]]),Lut={class:"template-selector__list"},Vut={class:"bootstrap-styles mb-3"},Mut=Ze({__name:"TemplatePreviewCardList",props:{templatesPreviewCard:{},initialTemplate:{},deps:{}},emits:["templateSelected"],setup(t,{emit:e}){const n=t,r={newTemplate:o_({localeKey:n.deps.localeKey}).newTemplate},o=e;return(i,s)=>(I(),J("div",Lut,[R("button",{class:"bootstrap-styles d-flex flex-column justify-content-center align-items-center template-selector__new-item overflow-hidden border rounded-3",type:"button",onClick:s[0]||(s[0]=a=>o("templateSelected",n.initialTemplate))},[R("i",Vut,[ie(GGe)]),rw(" "+en(r.newTemplate),1)]),(I(!0),J(ot,null,zn(n.templatesPreviewCard,a=>(I(),J("div",null,[ie(But,{deps:n.deps.templatePreviewCardDeps,template:a.template,templateName:a.templateName,onTemplateSelected:s[1]||(s[1]=l=>o("templateSelected",l))},null,8,["deps","template","templateName"])]))),256))]))}}),Lee=Qe(Mut,[["__scopeId","data-v-1f80466a"]]),Out={class:"template-gallery bootstrap-styles d-flex flex-column bg-white justify-content-start align-items-center"},Iut=["href"],Put={class:"icon-hover-stroke-black"},Wut={class:"bootstrap-styles mb-11"},Hut={class:"bootstrap-styles template-gallery__tab-list mb-13"},zut=Ze({__name:"TemplatesGallery",props:{commonFavoriteTemplates:{},customFavoriteTemplates:{},initialTemplate:{},deps:{}},emits:["templateSelected"],setup(t,{emit:e}){const n=t,r=n.customFavoriteTemplates.length?"custom":"common",o={title:o_({localeKey:n.deps.localeKey}).title,customFavoritesButton:o_({localeKey:n.deps.localeKey}).customFavoritesButton,commonFavoritesButton:o_({localeKey:n.deps.localeKey}).defaultFavoritesButton},i=Mt({activeTab:r}),s={custom:o.customFavoritesButton,common:o.commonFavoritesButton},a=e;return(l,u)=>(I(),J("div",Out,[R("a",{class:"template-gallery__close",href:n.deps.exitLink},[R("i",Put,[ie(OGe)])],8,Iut),R("h2",Wut,en(o.title),1),R("div",Hut,[ie(UGe,{initialTab:z(r),tabList:s,onOnTabClicked:u[0]||(u[0]=c=>i.activeTab=c)},null,8,["initialTab"])]),It(ie(Lee,{deps:n.deps.templatePreviewCardListDeps,templatesPreviewCard:n.customFavoriteTemplates,initialTemplate:n.initialTemplate,onTemplateSelected:u[1]||(u[1]=c=>a("templateSelected",c))},null,8,["deps","templatesPreviewCard","initialTemplate"]),[[vH,i.activeTab==="custom"]]),It(ie(Lee,{deps:n.deps.templatePreviewCardListDeps,templatesPreviewCard:n.commonFavoriteTemplates,initialTemplate:n.initialTemplate,onTemplateSelected:u[2]||(u[2]=c=>a("templateSelected",c))},null,8,["deps","templatesPreviewCard","initialTemplate"]),[[vH,i.activeTab==="common"]])]))}}),jut=Qe(zut,[["__scopeId","data-v-d3b96d8f"]]),Gx=t=>({Match:e=>{switch(typeof t){case"string":return(e.String??e.defaultValue)(t);case"number":return(e.Number??e.defaultValue)(t);case"boolean":return(e.Boolean??e.defaultValue)(t);case"object":return Uut(t)?(e.Array??e.defaultValue)(t):(e.Struct??e.defaultValue)(t);default:return ls(t)}}}),Uut=t=>Array.isArray(t),Kut=Wl,Fw=(t,e)=>{let n=e;for(const r of t)n=Kut(r).Match({PropertyName:o=>Gx(n).Match({defaultValue:()=>{throw console.error("Property not found: "+o),new Error("Property not found: "+o)},Struct:i=>i[o]}),ArrayIndex:o=>Gx(n).Match({defaultValue:()=>{throw console.error("Array index out of bounds: "+o),new Error("Array index out of bounds: "+o)},Array:i=>i[o]})});return n},qut=(t,e)=>Gx(Fw(t,e)).Match({defaultValue:()=>{throw console.error("Value is not a number"),new Error("Value is not a number")},Number:n=>n}),Jut=t=>Wl(t),Gut=t=>Wl(t),Yut=t=>Wl(t),Vee=t=>({dataStructBuilderExpression:e,context:n})=>Promise.all(Object.entries(e).map(async([r,o])=>({key:r,value:await t.expressionEvaluator({expression:o,context:n})}))).then(r=>Object.fromEntries(r.map(o=>[o.key,o.value]))),Xut=t=>{const e=({expression:n,context:r})=>{const o=t.dataStructBuilderExpressionEvaluatorFactory(e);return Yut(n).Match({NumberExpression:i=>t.numberExpressionEvaluator({numberExpression:i,context:r}),StringExpression:i=>t.stringExpressionEvaluator({stringExpression:i,context:r}),ListExpression:i=>t.listExpressionEvaluator({listExpression:i,context:r}),RecordBuilderExpression:i=>o({dataStructBuilderExpression:i,context:r})})};return e},Qut=(t,e)=>Gx(Fw(t,e)).Match({defaultValue:()=>{throw console.error("Value is not a list"),new Error("Value is not a list")},Array:n=>n}),Zut=t=>{const e=n=>Jut(n.listExpression).Match({ContextValueExpression:r=>Promise.resolve(Qut(r.Path,n.context)),ChunkExpression:async r=>{const o=await e({listExpression:r.ListExpression,context:n.context});return o.slice(0,Math.floor(o.length/r.ChunkSize)*r.ChunkSize)},LimitExpression:async r=>(await e({listExpression:r.ListExpression,context:n.context})).slice(0,r.Limit),DataSource:r=>t.listExpressionDataSourceEvaluator(r),ConcatListExpressions:async r=>Promise.all(r.ListExpressions.map(o=>e({listExpression:o,context:n.context}))).then(o=>o.flat())});return e},ect=(t,e)=>Gx(Fw(t,e)).Match({defaultValue:()=>{throw console.error("Value is not a string "+e+t),new Error("Value is not a string")},String:n=>n}),mbe=t=>({Match:e=>{switch(typeof t){case"string":return(e.String??e.defaultValue)(t);case"number":return(e.Number??e.defaultValue)(t);case"boolean":return(e.Boolean??e.defaultValue)(t);case"object":return tct(t)?(e.Array??e.defaultValue)(t):(e.Struct??e.defaultValue)(t);default:return e.defaultValue()}}}),tct=t=>Array.isArray(t),nct=t=>mbe(Fw(t.path,t.context)).Match({defaultValue:()=>t.fallbackValue,String:e=>e}),rct=t=>{const e=n=>{const r=t.stringExpressionDataSourceEvaluatorFactory(e);return Z0e(n.stringExpression).Match({ConcatStringExpressions:o=>uct({concatStringExpressions:o,stringExpressionEvaluator:e,context:n.context}),ContextValueExpression:o=>oct({contextValueExpression:o,context:n.context}),ContextValueExpressionWithFallback:o=>ict({contextValueExpressionWithFallback:o,context:n.context}),ConstValueExpression:o=>cct({stringConstValueExpression:o}),TruncateValueExpression:o=>sct({truncateValueExpression:o,context:n.context,stringExpressionEvaluator:e}),DataSource:o=>r({stringExpressionDataSource:o,context:n.context}),NumberToStringExpression:o=>lct({numberToStringExpression:o,context:n.context,numberExpressionEvaluator:t.numberExpressionEvaluator}),UnsubscribeUrlExpression:()=>Promise.resolve("#"),RecipientEmailAddressExpression:()=>Promise.resolve("RecipientEmailAddress")})};return e},oct=t=>Promise.resolve(ect(t.contextValueExpression.Path,t.context)),ict=t=>Promise.resolve(nct({path:t.contextValueExpressionWithFallback.Path,context:t.context,fallbackValue:t.contextValueExpressionWithFallback.FallbackValue})),sct=async t=>{const e=t.truncateValueExpression.MaxLength,n=await t.stringExpressionEvaluator({stringExpression:t.truncateValueExpression.StringExpression,context:t.context});return e<n.length?n.slice(0,t.truncateValueExpression.MaxLength)+t.truncateValueExpression.Tail:n},act=t=>{const e=t.value<0,n=Math.abs(t.value).toString();let[r="",o]=n.split(".");if(t.decimalSeparator===""||t.decimalPadString===""){if(o="",t.decimalSeparator==="")throw new Error("DecimalSeparator cannot be empty");if(t.decimalPadString==="")throw new Error("DecimalPadString cannot be empty")}if(!t.groupSizes||t.groupSizes.length===0)return(e?"-":"")+r+(o?t.decimalSeparator+o:"");t.decimalPadString&&t.decimalPadString!==""&&t.decimalSeparator!==""&&(o?o+=t.decimalPadString.slice(o.length):o=t.decimalPadString);let i="",s=r.length,a=0;for(;s>0;){const u=t.groupSizes[a]??t.groupSizes[t.groupSizes.length-1],c=r.slice(Math.max(0,s-u),s);i?i=c+t.groupSeparator+i:i=c,s-=u,a<t.groupSizes.length-1&&a++}let l=(e?"-":"")+i;return o&&o.length>0&&(l+=t.decimalSeparator+o),l},lct=async t=>{const e=await t.numberExpressionEvaluator({numberExpression:t.numberToStringExpression.NumberExpression,context:t.context});if(t.numberToStringExpression.Format){const n=t.numberToStringExpression.Format;return act({value:e,decimalSeparator:n.DecimalSeparator,groupSeparator:n.GroupSeparator,groupSizes:n.GroupSizes,decimalPadString:n.DecimalPadString})}return e.toString()},uct=t=>Promise.all(t.concatStringExpressions.StringExpressions.map(e=>t.stringExpressionEvaluator({stringExpression:e,context:t.context}))).then(e=>e.join("")),cct=t=>Promise.resolve(t.stringConstValueExpression.Value),dct=t=>mbe(Fw(t.path,t.context)).Match({defaultValue:()=>t.fallbackValue,Number:e=>e}),hct=t=>{const e=n=>{const r=t.numberExpressionDataSourceEvaluator;return Gut(n.numberExpression).Match({ContextValueExpressionWithFallback:o=>Promise.resolve(dct({fallbackValue:o.FallbackValue,path:o.Path,context:n.context})),ContextValueExpression:o=>Promise.resolve(qut(o.Path,n.context)),ConstValueExpression:o=>Promise.resolve(o.Value),ListLengthExpression:async o=>t.listExpressionEvaluator({listExpression:o.ListExpression,context:n.context}).then(i=>i.length),DataSource:o=>r({numberExpressionDataSource:o,context:n.context}),RoundExpression:async o=>e({numberExpression:o.NumberExpression,context:n.context}).then(i=>{const s=Math.pow(10,o.Digits);return Math.round(i*s)/s}),TruncateExpression:async o=>e({numberExpression:o.NumberExpression,context:n.context}).then(i=>{const s=Math.pow(10,o.Precision);return Math.trunc(i*s)/s})})};return e},mct=t=>{const e=document.createElement("form");e.method=t.method,e.action=t.action;for(const[n,r]of t.formData.entries()){if(r instanceof File)continue;const o=document.createElement("input");o.setAttribute("type","text"),o.setAttribute("name",n),o.setAttribute("value",r),e.appendChild(o)}return e},fct=t=>({elementsDeps:t.elementsDeps}),pct=t=>({elementsDeps:t.elementsDeps}),gct=t=>({elementsDeps:t.elementsDeps}),Cct=t=>({iteratedColumnN21Deps:pct({elementsDeps:t.elementsDeps}),iteratedColumnN22Deps:gct({elementsDeps:t.elementsDeps})}),yct=t=>({iteratedColumnDeps:fct({elementsDeps:t.elementsDeps}),iteratedColumnVariantDeps:Cct({elementsDeps:t.elementsDeps}),listExpressionEvaluator:t.listExpressionEvaluator}),bct=t=>({elementsDeps:t.elementsDeps}),vct=t=>({multipleColumnDeps:bct({elementsDeps:t.elementsDeps})}),Tct=t=>({iteratedColumnBodyRowDeps:yct({elementsDeps:t.elementsDeps,listExpressionEvaluator:t.listExpressionEvaluator}),multipleColumnBodyRowDeps:vct({elementsDeps:t.elementsDeps}),listExpressionEvaluator:t.listExpressionEvaluator}),fbe=t=>({localeKey:t.localeKey,emailComponentBodyRowDeps:Tct({elementsDeps:t.elementsDeps,listExpressionEvaluator:t.listExpressionEvaluator}),boolExpressionEvaluatorDelegate:t.boolExpressionEvaluator,dataStructExpressionEvaluator:t.dataStructExpressionEvaluator}),Fct=t=>({expressionEvaluator:t.expressionEvaluator}),xct=t=>({localeKey:t.localeKey}),Sct=t=>({localeKey:t.localeKey}),wct=t=>({localeKey:t.localeKey}),kct=t=>({localeKey:t.localeKey}),Ect=t=>({localeKey:t.localeKey}),Rct=t=>({localeKey:t.localeKey}),_ct=t=>({localeKey:t.localeKey}),Dct=t=>({localeKey:t.localeKey}),Act=t=>({localeKey:t.localeKey,colorPickerModalWindowDeps:Dct({localeKey:t.localeKey})}),$ct=t=>({localeKey:t.localeKey}),Nct=t=>({localeKey:t.localeKey}),Bct=t=>({localeKey:t.localeKey}),Lct=t=>({localeKey:t.localeKey}),Vct=t=>({localeKey:t.localeKey}),Mct=t=>({localeKey:t.localeKey}),Oct=t=>({localeKey:t.localeKey,addLinkModalWindowDeps:Mct({localeKey:t.localeKey})}),Ict=t=>({localeKey:t.localeKey}),Pct=t=>({localeKey:t.localeKey}),Wct=t=>({localeKey:t.localeKey,addImageSrcModalWindowDeps:Pct({localeKey:t.localeKey})}),Hct=t=>({localeKey:t.localeKey}),zct=t=>({localeKey:t.localeKey,richTextToolbarPlugins:t.richTextToolbarPlugins,bulletListEditorDeps:xct({localeKey:t.localeKey}),orderedListEditorDeps:Sct({localeKey:t.localeKey}),contentAlignEditorDeps:wct({localeKey:t.localeKey}),verticalAlignEditorDeps:kct({localeKey:t.localeKey}),fontFamilySelectorDeps:Ect({localeKey:t.localeKey}),fontSizeEditorDeps:Rct({localeKey:t.localeKey}),lineHeightEditorDeps:_ct({localeKey:t.localeKey}),colorPickerDeps:Act({localeKey:t.localeKey}),fontWeightEditorDeps:$ct({localeKey:t.localeKey}),fontStyleEditorDeps:Nct({localeKey:t.localeKey}),lineThroughEditorDeps:Bct({localeKey:t.localeKey}),underlineEditorDeps:Lct({localeKey:t.localeKey}),textTransformEditorDeps:Vct({localeKey:t.localeKey}),linkEditorDeps:Oct({localeKey:t.localeKey}),unsubscribeLinkEditorDeps:Ict({localeKey:t.localeKey}),imageEditorDeps:Wct({localeKey:t.localeKey}),themeSettingsSelectorDeps:Hct({localeKey:t.localeKey})}),jct=t=>({localeKey:t.localeKey}),Uct=t=>({localeKey:t.localeKey,dataSourceFieldNameDelegate:t.dataSourceFieldNameDelegate,richTextToolbarDeps:zct({localeKey:t.localeKey,richTextToolbarPlugins:t.richTextToolbarPlugins}),removeConfirmModalWindowDeps:jct({localeKey:t.localeKey})}),pbe=t=>({richTextDeps:Uct({dataSourceFieldNameDelegate:t.dataSourceFieldNameDelegate,richTextToolbarPlugins:t.richTextToolbarPlugins,localeKey:t.localeKey}),listExpressionEvaluator:t.listExpressionEvaluator,numberExpressionEvaluator:t.numberExpressionEvaluator,stringExpressionEvaluator:t.stringExpressionEvaluator,expressionVueDeps:Fct({expressionEvaluator:t.expressionEvaluator}),boolExpressionEvaluator:t.boolExpressionEvaluator}),{entries:gbe,setPrototypeOf:Mee,isFrozen:Kct,getPrototypeOf:qct,getOwnPropertyDescriptor:Jct}=Object;let{freeze:Ei,seal:Wa,create:$z}=Object,{apply:Nz,construct:Bz}=typeof Reflect<"u"&&Reflect;Ei||(Ei=function(t){return t});Wa||(Wa=function(t){return t});Nz||(Nz=function(t,e){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return t.apply(e,r)});Bz||(Bz=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return new t(...n)});const Xk=Ri(Array.prototype.forEach),Gct=Ri(Array.prototype.lastIndexOf),Oee=Ri(Array.prototype.pop),o1=Ri(Array.prototype.push),Yct=Ri(Array.prototype.splice),d_=Ri(String.prototype.toLowerCase),XI=Ri(String.prototype.toString),QI=Ri(String.prototype.match),i1=Ri(String.prototype.replace),Xct=Ri(String.prototype.indexOf),Qct=Ri(String.prototype.trim),Cl=Ri(Object.prototype.hasOwnProperty),Uo=Ri(RegExp.prototype.test),s1=Zct(TypeError);function Ri(t){return function(e){e instanceof RegExp&&(e.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 Nz(t,e,r)}}function Zct(t){return function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return Bz(t,n)}}function Wt(t,e){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:d_;Mee&&Mee(t,null);let r=e.length;for(;r--;){let o=e[r];if(typeof o=="string"){const i=n(o);i!==o&&(Kct(e)||(e[r]=i),o=i)}t[o]=!0}return t}function edt(t){for(let e=0;e<t.length;e++)Cl(t,e)||(t[e]=null);return t}function tu(t){const e=$z(null);for(const[n,r]of gbe(t))Cl(t,n)&&(Array.isArray(r)?e[n]=edt(r):r&&typeof r=="object"&&r.constructor===Object?e[n]=tu(r):e[n]=r);return e}function a1(t,e){for(;t!==null;){const r=Jct(t,e);if(r){if(r.get)return Ri(r.get);if(typeof r.value=="function")return Ri(r.value)}t=qct(t)}function n(){return null}return n}const Iee=Ei(["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"]),ZI=Ei(["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"]),e2=Ei(["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"]),tdt=Ei(["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"]),t2=Ei(["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"]),ndt=Ei(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Pee=Ei(["#text"]),Wee=Ei(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),n2=Ei(["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"]),Hee=Ei(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Qk=Ei(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),rdt=Wa(/\{\{[\w\W]*|[\w\W]*\}\}/gm),odt=Wa(/<%[\w\W]*|[\w\W]*%>/gm),idt=Wa(/\$\{[\w\W]*/gm),sdt=Wa(/^data-[\-\w.\u00B7-\uFFFF]+$/),adt=Wa(/^aria-[\-\w]+$/),Cbe=Wa(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ldt=Wa(/^(?:\w+script|data):/i),udt=Wa(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ybe=Wa(/^html$/i),cdt=Wa(/^[a-z][.\w]*(-[.\w]+)+$/i);var zee=Object.freeze({__proto__:null,ARIA_ATTR:adt,ATTR_WHITESPACE:udt,CUSTOM_ELEMENT:cdt,DATA_ATTR:sdt,DOCTYPE_NAME:ybe,ERB_EXPR:odt,IS_ALLOWED_URI:Cbe,IS_SCRIPT_OR_DATA:ldt,MUSTACHE_EXPR:rdt,TMPLIT_EXPR:idt});const l1={element:1,text:3,progressingInstruction:7,comment:8,document:9},ddt=function(){return typeof window>"u"?null:window},hdt=function(t,e){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let n=null;const r="data-tt-policy-suffix";e&&e.hasAttribute(r)&&(n=e.getAttribute(r));const o="dompurify"+(n?"#"+n:"");try{return t.createPolicy(o,{createHTML(i){return i},createScriptURL(i){return i}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}},jee=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function bbe(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ddt();const e=C=>bbe(C);if(e.version="3.3.1",e.removed=[],!t||!t.document||t.document.nodeType!==l1.document||!t.Element)return e.isSupported=!1,e;let{document:n}=t;const r=n,o=r.currentScript,{DocumentFragment:i,HTMLTemplateElement:s,Node:a,Element:l,NodeFilter:u,NamedNodeMap:c=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:d,DOMParser:h,trustedTypes:m}=t,f=l.prototype,p=a1(f,"cloneNode"),g=a1(f,"remove"),y=a1(f,"nextSibling"),b=a1(f,"childNodes"),F=a1(f,"parentNode");if(typeof s=="function"){const C=n.createElement("template");C.content&&C.content.ownerDocument&&(n=C.content.ownerDocument)}let T,v="";const{implementation:w,createNodeIterator:k,createDocumentFragment:_,getElementsByTagName:D}=n,{importNode:L}=r;let E=jee();e.isSupported=typeof gbe=="function"&&typeof F=="function"&&w&&w.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:A,ERB_EXPR:$,TMPLIT_EXPR:M,DATA_ATTR:O,ARIA_ATTR:V,IS_SCRIPT_OR_DATA:H,ATTR_WHITESPACE:Re,CUSTOM_ELEMENT:Pe}=zee;let{IS_ALLOWED_URI:Te}=zee,K=null;const We=Wt({},[...Iee,...ZI,...e2,...t2,...Pee]);let Y=null;const He=Wt({},[...Wee,...n2,...Hee,...Qk]);let P=Object.seal($z(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}})),_e=null,ae=null;const ne=Object.seal($z(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Et=!0,Tt=!0,gt=!1,N=!0,B=!1,j=!0,G=!1,Q=!1,Z=!1,te=!1,re=!1,U=!1,X=!0,Oe=!1;const ce="user-content-";let ue=!0,de=!1,Fe={},le=null;const ze=Wt({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let un=null;const cn=Wt({},["audio","video","img","source","image","track"]);let rn=null;const bn=Wt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),tn="http://www.w3.org/1998/Math/MathML",dn="http://www.w3.org/2000/svg",Ke="http://www.w3.org/1999/xhtml";let ft=Ke,Dn=!1,An=null;const ul=Wt({},[tn,dn,Ke],XI);let gn=Wt({},["mi","mo","mn","ms","mtext"]),Cn=Wt({},["annotation-xml"]);const cl=Wt({},["title","style","font","a","script"]);let nn=null;const dl=["application/xhtml+xml","text/html"],hl="text/html";let oe=null,_t=null;const ml=n.createElement("form"),so=function(C){return C instanceof RegExp||C instanceof Function},Qn=function(){let C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(_t&&_t===C)){if((!C||typeof C!="object")&&(C={}),C=tu(C),nn=dl.indexOf(C.PARSER_MEDIA_TYPE)===-1?hl:C.PARSER_MEDIA_TYPE,oe=nn==="application/xhtml+xml"?XI:d_,K=Cl(C,"ALLOWED_TAGS")?Wt({},C.ALLOWED_TAGS,oe):We,Y=Cl(C,"ALLOWED_ATTR")?Wt({},C.ALLOWED_ATTR,oe):He,An=Cl(C,"ALLOWED_NAMESPACES")?Wt({},C.ALLOWED_NAMESPACES,XI):ul,rn=Cl(C,"ADD_URI_SAFE_ATTR")?Wt(tu(bn),C.ADD_URI_SAFE_ATTR,oe):bn,un=Cl(C,"ADD_DATA_URI_TAGS")?Wt(tu(cn),C.ADD_DATA_URI_TAGS,oe):cn,le=Cl(C,"FORBID_CONTENTS")?Wt({},C.FORBID_CONTENTS,oe):ze,_e=Cl(C,"FORBID_TAGS")?Wt({},C.FORBID_TAGS,oe):tu({}),ae=Cl(C,"FORBID_ATTR")?Wt({},C.FORBID_ATTR,oe):tu({}),Fe=Cl(C,"USE_PROFILES")?C.USE_PROFILES:!1,Et=C.ALLOW_ARIA_ATTR!==!1,Tt=C.ALLOW_DATA_ATTR!==!1,gt=C.ALLOW_UNKNOWN_PROTOCOLS||!1,N=C.ALLOW_SELF_CLOSE_IN_ATTR!==!1,B=C.SAFE_FOR_TEMPLATES||!1,j=C.SAFE_FOR_XML!==!1,G=C.WHOLE_DOCUMENT||!1,te=C.RETURN_DOM||!1,re=C.RETURN_DOM_FRAGMENT||!1,U=C.RETURN_TRUSTED_TYPE||!1,Z=C.FORCE_BODY||!1,X=C.SANITIZE_DOM!==!1,Oe=C.SANITIZE_NAMED_PROPS||!1,ue=C.KEEP_CONTENT!==!1,de=C.IN_PLACE||!1,Te=C.ALLOWED_URI_REGEXP||Cbe,ft=C.NAMESPACE||Ke,gn=C.MATHML_TEXT_INTEGRATION_POINTS||gn,Cn=C.HTML_INTEGRATION_POINTS||Cn,P=C.CUSTOM_ELEMENT_HANDLING||{},C.CUSTOM_ELEMENT_HANDLING&&so(C.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(P.tagNameCheck=C.CUSTOM_ELEMENT_HANDLING.tagNameCheck),C.CUSTOM_ELEMENT_HANDLING&&so(C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(P.attributeNameCheck=C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),C.CUSTOM_ELEMENT_HANDLING&&typeof C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(P.allowCustomizedBuiltInElements=C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),B&&(Tt=!1),re&&(te=!0),Fe&&(K=Wt({},Pee),Y=[],Fe.html===!0&&(Wt(K,Iee),Wt(Y,Wee)),Fe.svg===!0&&(Wt(K,ZI),Wt(Y,n2),Wt(Y,Qk)),Fe.svgFilters===!0&&(Wt(K,e2),Wt(Y,n2),Wt(Y,Qk)),Fe.mathMl===!0&&(Wt(K,t2),Wt(Y,Hee),Wt(Y,Qk))),C.ADD_TAGS&&(typeof C.ADD_TAGS=="function"?ne.tagCheck=C.ADD_TAGS:(K===We&&(K=tu(K)),Wt(K,C.ADD_TAGS,oe))),C.ADD_ATTR&&(typeof C.ADD_ATTR=="function"?ne.attributeCheck=C.ADD_ATTR:(Y===He&&(Y=tu(Y)),Wt(Y,C.ADD_ATTR,oe))),C.ADD_URI_SAFE_ATTR&&Wt(rn,C.ADD_URI_SAFE_ATTR,oe),C.FORBID_CONTENTS&&(le===ze&&(le=tu(le)),Wt(le,C.FORBID_CONTENTS,oe)),C.ADD_FORBID_CONTENTS&&(le===ze&&(le=tu(le)),Wt(le,C.ADD_FORBID_CONTENTS,oe)),ue&&(K["#text"]=!0),G&&Wt(K,["html","head","body"]),K.table&&(Wt(K,["tbody"]),delete _e.tbody),C.TRUSTED_TYPES_POLICY){if(typeof C.TRUSTED_TYPES_POLICY.createHTML!="function")throw s1('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof C.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw s1('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');T=C.TRUSTED_TYPES_POLICY,v=T.createHTML("")}else T===void 0&&(T=hdt(m,o)),T!==null&&typeof v=="string"&&(v=T.createHTML(""));Ei&&Ei(C),_t=C}},ao=Wt({},[...ZI,...e2,...tdt]),lo=Wt({},[...t2,...ndt]),fl=function(C){let x=F(C);(!x||!x.tagName)&&(x={namespaceURI:ft,tagName:"template"});const S=d_(C.tagName),W=d_(x.tagName);return An[C.namespaceURI]?C.namespaceURI===dn?x.namespaceURI===Ke?S==="svg":x.namespaceURI===tn?S==="svg"&&(W==="annotation-xml"||gn[W]):!!ao[S]:C.namespaceURI===tn?x.namespaceURI===Ke?S==="math":x.namespaceURI===dn?S==="math"&&Cn[W]:!!lo[S]:C.namespaceURI===Ke?x.namespaceURI===dn&&!Cn[W]||x.namespaceURI===tn&&!gn[W]?!1:!lo[S]&&(cl[S]||!ao[S]):!!(nn==="application/xhtml+xml"&&An[C.namespaceURI]):!1},Ct=function(C){o1(e.removed,{element:C});try{F(C).removeChild(C)}catch{g(C)}},xt=function(C,x){try{o1(e.removed,{attribute:x.getAttributeNode(C),from:x})}catch{o1(e.removed,{attribute:null,from:x})}if(x.removeAttribute(C),C==="is")if(te||re)try{Ct(x)}catch{}else try{x.setAttribute(C,"")}catch{}},uo=function(C){let x=null,S=null;if(Z)C="<remove></remove>"+C;else{const ee=QI(C,/^[\r\n\t ]+/);S=ee&&ee[0]}nn==="application/xhtml+xml"&&ft===Ke&&(C='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+C+"</body></html>");const W=T?T.createHTML(C):C;if(ft===Ke)try{x=new h().parseFromString(W,nn)}catch{}if(!x||!x.documentElement){x=w.createDocument(ft,"template",null);try{x.documentElement.innerHTML=Dn?v:W}catch{}}const se=x.body||x.documentElement;return C&&S&&se.insertBefore(n.createTextNode(S),se.childNodes[0]||null),ft===Ke?D.call(x,G?"html":"body")[0]:G?x.documentElement:se},co=function(C){return k.call(C.ownerDocument||C,C,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},Zn=function(C){return C instanceof d&&(typeof C.nodeName!="string"||typeof C.textContent!="string"||typeof C.removeChild!="function"||!(C.attributes instanceof c)||typeof C.removeAttribute!="function"||typeof C.setAttribute!="function"||typeof C.namespaceURI!="string"||typeof C.insertBefore!="function"||typeof C.hasChildNodes!="function")},ho=function(C){return typeof a=="function"&&C instanceof a};function it(C,x,S){Xk(C,W=>{W.call(e,x,S,_t)})}const mo=function(C){let x=null;if(it(E.beforeSanitizeElements,C,null),Zn(C))return Ct(C),!0;const S=oe(C.nodeName);if(it(E.uponSanitizeElement,C,{tagName:S,allowedTags:K}),j&&C.hasChildNodes()&&!ho(C.firstElementChild)&&Uo(/<[/\w!]/g,C.innerHTML)&&Uo(/<[/\w!]/g,C.textContent)||C.nodeType===l1.progressingInstruction||j&&C.nodeType===l1.comment&&Uo(/<[/\w]/g,C.data))return Ct(C),!0;if(!(ne.tagCheck instanceof Function&&ne.tagCheck(S))&&(!K[S]||_e[S])){if(!_e[S]&&po(S)&&(P.tagNameCheck instanceof RegExp&&Uo(P.tagNameCheck,S)||P.tagNameCheck instanceof Function&&P.tagNameCheck(S)))return!1;if(ue&&!le[S]){const W=F(C)||C.parentNode,se=b(C)||C.childNodes;if(se&&W){const ee=se.length;for(let qe=ee-1;qe>=0;--qe){const je=p(se[qe],!0);je.__removalCount=(C.__removalCount||0)+1,W.insertBefore(je,y(C))}}}return Ct(C),!0}return C instanceof l&&!fl(C)||(S==="noscript"||S==="noembed"||S==="noframes")&&Uo(/<\/no(script|embed|frames)/i,C.innerHTML)?(Ct(C),!0):(B&&C.nodeType===l1.text&&(x=C.textContent,Xk([A,$,M],W=>{x=i1(x,W," ")}),C.textContent!==x&&(o1(e.removed,{element:C.cloneNode()}),C.textContent=x)),it(E.afterSanitizeElements,C,null),!1)},fo=function(C,x,S){if(X&&(x==="id"||x==="name")&&(S in n||S in ml))return!1;if(!(Tt&&!ae[x]&&Uo(O,x))&&!(Et&&Uo(V,x))&&!(ne.attributeCheck instanceof Function&&ne.attributeCheck(x,C))){if(!Y[x]||ae[x]){if(!(po(C)&&(P.tagNameCheck instanceof RegExp&&Uo(P.tagNameCheck,C)||P.tagNameCheck instanceof Function&&P.tagNameCheck(C))&&(P.attributeNameCheck instanceof RegExp&&Uo(P.attributeNameCheck,x)||P.attributeNameCheck instanceof Function&&P.attributeNameCheck(x,C))||x==="is"&&P.allowCustomizedBuiltInElements&&(P.tagNameCheck instanceof RegExp&&Uo(P.tagNameCheck,S)||P.tagNameCheck instanceof Function&&P.tagNameCheck(S))))return!1}else if(!rn[x]&&!Uo(Te,i1(S,Re,""))&&!((x==="src"||x==="xlink:href"||x==="href")&&C!=="script"&&Xct(S,"data:")===0&&un[C])&&!(gt&&!Uo(H,i1(S,Re,"")))&&S)return!1}return!0},po=function(C){return C!=="annotation-xml"&&QI(C,Pe)},go=function(C){it(E.beforeSanitizeAttributes,C,null);const{attributes:x}=C;if(!x||Zn(C))return;const S={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Y,forceKeepAttr:void 0};let W=x.length;for(;W--;){const se=x[W],{name:ee,namespaceURI:qe,value:je}=se,Xe=oe(ee),$n=je;let De=ee==="value"?$n:Qct($n);if(S.attrName=Xe,S.attrValue=De,S.keepAttr=!0,S.forceKeepAttr=void 0,it(E.uponSanitizeAttribute,C,S),De=S.attrValue,Oe&&(Xe==="id"||Xe==="name")&&(xt(ee,C),De=ce+De),j&&Uo(/((--!?|])>)|<\/(style|title|textarea)/i,De)){xt(ee,C);continue}if(Xe==="attributename"&&QI(De,"href")){xt(ee,C);continue}if(S.forceKeepAttr)continue;if(!S.keepAttr){xt(ee,C);continue}if(!N&&Uo(/\/>/i,De)){xt(ee,C);continue}B&&Xk([A,$,M],sa=>{De=i1(De,sa," ")});const hn=oe(C.nodeName);if(!fo(hn,Xe,De)){xt(ee,C);continue}if(T&&typeof m=="object"&&typeof m.getAttributeType=="function"&&!qe)switch(m.getAttributeType(hn,Xe)){case"TrustedHTML":{De=T.createHTML(De);break}case"TrustedScriptURL":{De=T.createScriptURL(De);break}}if(De!==$n)try{qe?C.setAttributeNS(qe,ee,De):C.setAttribute(ee,De),Zn(C)?Ct(C):Oee(e.removed)}catch{xt(ee,C)}}it(E.afterSanitizeAttributes,C,null)},pl=function C(x){let S=null;const W=co(x);for(it(E.beforeSanitizeShadowDOM,x,null);S=W.nextNode();)it(E.uponSanitizeShadowNode,S,null),mo(S),go(S),S.content instanceof i&&C(S.content);it(E.afterSanitizeShadowDOM,x,null)};return e.sanitize=function(C){let x=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},S=null,W=null,se=null,ee=null;if(Dn=!C,Dn&&(C="<!-->"),typeof C!="string"&&!ho(C))if(typeof C.toString=="function"){if(C=C.toString(),typeof C!="string")throw s1("dirty is not a string, aborting")}else throw s1("toString is not a function");if(!e.isSupported)return C;if(Q||Qn(x),e.removed=[],typeof C=="string"&&(de=!1),de){if(C.nodeName){const Xe=oe(C.nodeName);if(!K[Xe]||_e[Xe])throw s1("root node is forbidden and cannot be sanitized in-place")}}else if(C instanceof a)S=uo("<!---->"),W=S.ownerDocument.importNode(C,!0),W.nodeType===l1.element&&W.nodeName==="BODY"||W.nodeName==="HTML"?S=W:S.appendChild(W);else{if(!te&&!B&&!G&&C.indexOf("<")===-1)return T&&U?T.createHTML(C):C;if(S=uo(C),!S)return te?null:U?v:""}S&&Z&&Ct(S.firstChild);const qe=co(de?C:S);for(;se=qe.nextNode();)mo(se),go(se),se.content instanceof i&&pl(se.content);if(de)return C;if(te){if(re)for(ee=_.call(S.ownerDocument);S.firstChild;)ee.appendChild(S.firstChild);else ee=S;return(Y.shadowroot||Y.shadowrootmode)&&(ee=L.call(r,ee,!0)),ee}let je=G?S.outerHTML:S.innerHTML;return G&&K["!doctype"]&&S.ownerDocument&&S.ownerDocument.doctype&&S.ownerDocument.doctype.name&&Uo(ybe,S.ownerDocument.doctype.name)&&(je="<!DOCTYPE "+S.ownerDocument.doctype.name+`>
147
+ `}),md=t=>({borderTop:Yk(t.border.Top,t.themeColors),borderRight:Yk(t.border.Right,t.themeColors),borderBottom:Yk(t.border.Bottom,t.themeColors),borderLeft:Yk(t.border.Left,t.themeColors)}),bw=t=>t.borderCollapse!==void 0?{borderCollapse:ztt(t.borderCollapse)}:{borderCollapse:"collapse"},ztt=t=>{switch(t){case"Collapse":return"collapse";case"Separate":return"separate";default:return ls(t)}},jtt=t=>({Match:e=>{switch(t.Discriminator){case"None":return e.None();case"EmailBackgroundColor":return e.EmailBackgroundColor();case"BodyColor":return e.BodyColor();case"TitleColor":return e.TitleColor();case"HeadingColor":return e.HeadingColor();case"SubHeadingColor":return e.SubHeading();case"LargeTextColor":return e.LargeTextColor();case"NormalTextColor":return e.NormalTextColor();case"DescriptionTextColor":return e.DescriptionTextColor();case"PrimaryTextColor":return e.PrimaryTextColor();case"SecondaryTextColor":return e.SecondaryTextColor();case"ButtonTextColor":return e.ButtonTextColor();case"LinkColor":return e.LinkColor();case"PrimaryColor":return e.PrimaryColor();case"SecondaryColor":return e.SecondaryColor();case"CardBackgroundColor":return e.CardBackgroundColor();case"Custom":return e.Custom(t.CustomValue);default:return ls(t.Discriminator)}}}),Ll=t=>jtt(t.color).Match({None:()=>null,EmailBackgroundColor:()=>t.themeColors.EmailBackgroundColor,BodyColor:()=>t.themeColors.BodyColor,TitleColor:()=>t.themeColors.TitleColor,HeadingColor:()=>t.themeColors.HeadingColor,SubHeading:()=>t.themeColors.SubHeadingColor,LargeTextColor:()=>t.themeColors.LargeTextColor,NormalTextColor:()=>t.themeColors.NormalTextColor,DescriptionTextColor:()=>t.themeColors.DescriptionTextColor,PrimaryTextColor:()=>t.themeColors.PrimaryTextColor,SecondaryTextColor:()=>t.themeColors.SecondaryTextColor,LinkColor:()=>t.themeColors.LinkColor,PrimaryColor:()=>t.themeColors.PrimaryColor,SecondaryColor:()=>t.themeColors.SecondaryColor,CardBackgroundColor:()=>t.themeColors.CardBackgroundColor,ButtonTextColor:()=>t.themeColors.ButtonTextColor,Custom:e=>e}),I0e=t=>({Match:e=>{switch(t){case"Left":return e.Left();case"Center":return e.Center();case"Right":return e.Right();default:return ls(t)}}}),Utt=t=>t.containerAlign?I0e(t.containerAlign).Match({Left:()=>({textAlign:"left"}),Center:()=>({textAlign:"center"}),Right:()=>({textAlign:"right"})}):{},Lc=t=>t.containerAlign?I0e(t.containerAlign).Match({Left:()=>"left",Center:()=>"center",Right:()=>"right"}):"center",Ktt=Ze({__name:"If",props:{deps:{},theme:{},element:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=e,o=Mt({ifResult:!1,isLoading:!0});return n.deps.boolExpressionEvaluator({boolExpression:n.element.Predicate,context:n.context}).then(i=>{o.ifResult=i,o.isLoading=!1}),(i,s)=>(I(!0),J(ot,null,zn(o.ifResult?n.element.True:n.element.False,(a,l)=>(I(),et(kl,{key:l,deps:n.deps,theme:n.theme,element:a,context:n.context,path:[...n.path,o.ifResult?"True":"False",l],selectedElementPath:n.selectedElementPath,onOnImageSizeAdjusted:s[0]||(s[0]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[1]||(s[1]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementClicked:s[2]||(s[2]=u=>r("onElementClicked",u)),onOnElementUpdatedEvent:s[3]||(s[3]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[4]||(s[4]=u=>r("onElementRemoved",u))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))}}),vw=t=>({paddingTop:Sr({paddingExpression:t.paddings.Top,themeComponentPaddings:t.themeComponentPaddings,themeBodyPaddings:t.themeBodyPaddings})+"px",paddingRight:Sr({paddingExpression:t.paddings.Right,themeComponentPaddings:t.themeComponentPaddings,themeBodyPaddings:t.themeBodyPaddings})+"px",paddingBottom:Sr({paddingExpression:t.paddings.Bottom,themeComponentPaddings:t.themeComponentPaddings,themeBodyPaddings:t.themeBodyPaddings})+"px",paddingLeft:Sr({paddingExpression:t.paddings.Left,themeComponentPaddings:t.themeComponentPaddings,themeBodyPaddings:t.themeBodyPaddings})+"px"}),qtt=Wl,Jtt=t=>qtt(t.width).Match({Auto:()=>"initial",Pixel:e=>e.Value+"px",Percentage:e=>e.Value+"%"}),Gtt=["align"],Ytt=Ze({__name:"HeightContainer",props:{deps:{},theme:{},element:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("table",{class:"heightContainerRender",style:he([{"border-spacing":"0","border-collapse":"separate"},{width:z(Jtt)({width:n.element.Width})}])},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.element.ContainerAlign}),style:he([z(vw)({paddings:n.element.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),{height:n.element.Height?n.element.Height+"px":"",verticalAlign:n.element.VerticalAlign,backgroundRepeat:"no-repeat",backgroundSize:"contain",backgroundColor:z(Ll)({color:n.element.BackgroundColor,themeColors:n.theme.Colors})??"inherit"},z(md)({border:n.element.Border,themeColors:n.theme.Colors}),z(Wu)({borderRadius:n.element.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner})])},[(I(!0),J(ot,null,zn(n.element.Elements,(s,a)=>(I(),et(kl,{key:a,deps:n.deps,theme:n.theme,element:s,path:[...n.path,"Elements",a],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:i[0]||(i[0]=l=>r("onImageSizeAdjusted",l)),onOnImageOriginalSizeAdjusted:i[1]||(i[1]=l=>r("onImageOriginalSizeAdjusted",l)),onOnElementClicked:i[2]||(i[2]=l=>r("onElementClicked",l)),onOnElementUpdatedEvent:i[3]||(i[3]=l=>r("onElementUpdatedEvent",l)),onOnElementRemoved:i[4]||(i[4]=l=>r("onElementRemoved",l))},null,8,["deps","theme","element","path","selectedElementPath","context"]))),128))],12,Gtt)])])],4))}}),Xtt=t=>({Match:e=>{switch(t){case"Left":return e.Left();case"Center":return e.Center();case"Right":return e.Right();case"Inline":return e.Inline()}}}),qx=t=>Xtt(t.contentAlign).Match({Left:()=>({display:"block",textAlign:"left"}),Center:()=>({display:"block",textAlign:"center"}),Right:()=>({display:"block",textAlign:"right"}),Inline:()=>({})});let JI;const Jx={mounted(t,e){const n=e.value;JI=new ResizeObserver(r=>{r.forEach(o=>n(o.contentRect))}),JI.observe(t)},unmounted(t){JI.unobserve(t)}},Qtt=["href"],Ztt=["src","alt"],ent=["src","alt"],tnt=Ze({__name:"Image",props:{deps:{},theme:{},element:{},path:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementClicked"],setup(t,{emit:e}){const n=c=>{u("onImageOriginalSizeAdjusted",{Path:r.path,OriginalHeight:c.target.naturalHeight,OriginalWidth:c.target.naturalWidth})},r=t,o=Mt({href:"",src:"",alt:"",isLoaded:!1}),i=q(()=>r.element.IsResponsive?"100%":(r.element.IsRetina?r.element.OriginalWidth/2:r.element.OriginalWidth)+"px"),s=q(()=>r.element.IsResponsive?(r.element.IsRetina?r.element.OriginalWidth/2:r.element.OriginalWidth)+"px":"100%"),a=async c=>r.deps.stringExpressionEvaluator({stringExpression:c,context:r.context}),l=async()=>{const[c,d,h]=await Promise.all([a(r.element.Src),a(r.element.HRef),a(r.element.Alt)]);o.href=d,o.src=c,o.alt=h,o.isLoaded=!0};mn(()=>[r.element.Src,r.element.HRef,r.element.Alt,r.context],()=>l()),l();const u=e;return(c,d)=>r.element.IsLink?(I(),J("a",{key:0,href:o.href,style:he([z(qx)({contentAlign:r.element.ContentAlign})]),onClick:d[0]||(d[0]=wr(()=>u("onElementClicked"),["prevent"]))},[o.isLoaded?It((I(),J("img",{key:0,class:Me(["Image cursor-pointer",{"img-responsive":r.element.IsResponsive}]),src:o.src,alt:o.alt,style:he([z(Wu)({borderRadius:r.element.BorderRadius,borderRadiusCard:r.theme.BorderRadiusCard,bodyBorderRadius:r.theme.BorderRadius,borderButtonRadius:r.theme.BorderRadiusButton,borderBannerRadius:r.theme.BorderRadiusBanner}),z(md)({border:r.element.Border,themeColors:r.theme.Colors}),{width:i.value,maxWidth:s.value},{verticalAlign:r.element.VerticalAlign}]),onLoad:n},null,46,Ztt)),[[z(Jx),({width:h,height:m})=>u("onImageSizeAdjusted",{Path:r.path,AdjustedHeight:m,AdjustedWidth:h})]]):Ue("",!0)],12,Qtt)):(I(),J("span",{key:1,style:he([z(qx)({contentAlign:r.element.ContentAlign})]),onClick:d[1]||(d[1]=wr(()=>u("onElementClicked"),["prevent"]))},[o.isLoaded?It((I(),J("img",{key:0,class:Me(["Image cursor-pointer",{"img-responsive":r.element.IsResponsive}]),src:o.src,alt:o.alt,style:he([z(Wu)({borderRadius:r.element.BorderRadius,borderRadiusCard:r.theme.BorderRadiusCard,bodyBorderRadius:r.theme.BorderRadius,borderButtonRadius:r.theme.BorderRadiusButton,borderBannerRadius:r.theme.BorderRadiusBanner}),z(md)({border:r.element.Border,themeColors:r.theme.Colors}),{width:i.value,maxWidth:s.value},{verticalAlign:r.element.VerticalAlign}]),onLoad:n},null,46,ent)),[[z(Jx),({width:h,height:m})=>u("onImageSizeAdjusted",{Path:r.path,AdjustedHeight:m,AdjustedWidth:h})]]):Ue("",!0)],4))}}),nnt=Qe(tnt,[["__scopeId","data-v-67426858"]]),rnt=Wl,ont=t=>t.width===void 0?{}:rnt(t.width).Match({Auto:()=>({width:"auto"}),Pixel:e=>({width:e.Value+"px"}),Percentage:e=>({width:e.Value+"%"})}),int=t=>{switch(t){case"Auto":return{width:"auto"};case"FullWidth":return{width:"100%"};default:return ls(t)}},snt=Ze({__name:"OneLineList",props:{deps:{},theme:{},element:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onImageSizeAdjusted","onImageOriginalSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("table",{class:"oneLineList",style:he([{"border-spacing":"0","border-collapse":"collapse"},[z(int)(n.element.ContainerWidth)]])},[R("tbody",null,[R("tr",null,[(I(!0),J(ot,null,zn(n.element.Elements,(s,a)=>(I(),J("td",{key:a,class:"oneLineListItem",style:he([z(vw)({paddings:n.element.ItemPaddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),z(ont)({width:n.element.ItemWidth}),{lineHeight:"normal"}])},[(I(),et(kl,{key:a,deps:n.deps,theme:n.theme,element:s,path:[...n.path,"Elements",a],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:i[0]||(i[0]=l=>r("onImageSizeAdjusted",l)),onOnImageOriginalSizeAdjusted:i[1]||(i[1]=l=>r("onImageOriginalSizeAdjusted",l)),onOnElementClicked:i[2]||(i[2]=l=>r("onElementClicked",l)),onOnElementUpdatedEvent:i[3]||(i[3]=l=>r("onElementUpdatedEvent",l)),onOnElementRemoved:i[4]||(i[4]=l=>r("onElementRemoved",l))},null,8,["deps","theme","element","path","selectedElementPath","context"]))],4))),128))])])],4))}}),ant={style:{"border-spacing":"0","border-collapse":"collapse",width:"100%"}},lnt=Ze({__name:"Spacer",props:{theme:{},element:{}},emits:["onElementClicked"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("table",{class:"Spacer",width:"100%",style:{"border-spacing":"0","border-collapse":"collapse",width:"100%"},onClick:i[0]||(i[0]=()=>r("onElementClicked"))},[R("tbody",null,[R("tr",null,[R("td",{valign:"middle",style:he([{height:z(Sr)({paddingExpression:n.element.Height,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})+"px"}])},[R("table",ant,[R("tbody",null,[R("tr",null,[R("td",{style:he([[{borderTop:n.element.Weight+"px",borderStyle:n.element.Weight>0?"solid":"none",borderColor:z(Ll)({color:n.element.Color,themeColors:n.theme.Colors})}],{"font-size":"0","line-height":"0","border-bottom":"0","border-left":"0","border-right":"0"}])},"   ",4)])])])],4)])])]))}}),Dz={beforeMount(t,e){t.innerHTML=DX.sanitize(e.value)},beforeUpdate(t,e){t.innerHTML=DX.sanitize(e.value)}},unt=t=>({Match:e=>{switch(t.Discriminator){case"EmailBackgroundColor":return e.EmailBackgroundColor();case"BodyColor":return e.BodyColor();case"TitleColor":return e.TitleColor();case"HeadingColor":return e.HeadingColor();case"SubHeadingColor":return e.SubHeading();case"LargeTextColor":return e.LargeTextColor();case"NormalTextColor":return e.NormalTextColor();case"DescriptionTextColor":return e.DescriptionTextColor();case"PrimaryTextColor":return e.PrimaryTextColor();case"SecondaryTextColor":return e.SecondaryTextColor();case"ButtonTextColor":return e.ButtonTextColor();case"LinkColor":return e.LinkColor();case"PrimaryColor":return e.PrimaryColor();case"SecondaryColor":return e.SecondaryColor();case"CardBackgroundColor":return e.CardBackgroundColor();case"Custom":return e.Custom(t.CustomValue)}}}),PV=t=>unt(t.fontColor).Match({EmailBackgroundColor:()=>t.themeColors.EmailBackgroundColor,BodyColor:()=>t.themeColors.BodyColor,TitleColor:()=>t.themeColors.TitleColor,HeadingColor:()=>t.themeColors.HeadingColor,SubHeading:()=>t.themeColors.SubHeadingColor,LargeTextColor:()=>t.themeColors.LargeTextColor,NormalTextColor:()=>t.themeColors.NormalTextColor,DescriptionTextColor:()=>t.themeColors.DescriptionTextColor,PrimaryTextColor:()=>t.themeColors.PrimaryTextColor,SecondaryTextColor:()=>t.themeColors.SecondaryTextColor,LinkColor:()=>t.themeColors.LinkColor,PrimaryColor:()=>t.themeColors.PrimaryColor,SecondaryColor:()=>t.themeColors.SecondaryColor,CardBackgroundColor:()=>t.themeColors.CardBackgroundColor,ButtonTextColor:()=>t.themeColors.ButtonTextColor,Custom:e=>e}),cnt=t=>({Match:e=>{switch(t){case"None":return e.None();case"Underline":return e.Underline();case"LineThrough":return e.LineThrough()}}}),W7=t=>cnt(t.textDecoration).Match({None:()=>"none",Underline:()=>"underline",LineThrough:()=>"line-through"}),P0e=t=>({fontSize:t.customFontSettings.FontSize,lineHeight:t.customFontSettings.LineHeight,fontWeight:t.customFontSettings.IsBold?"bold":"normal",fontStyle:t.customFontSettings.IsItalic?"italic":"normal",textDecoration:W7({textDecoration:t.customFontSettings.Decoration}),fontFamily:t.customFontSettings.FontFamily,color:PV({fontColor:t.customFontSettings.FontColor,themeColors:t.themeColors})}),W0e=t=>({Match:e=>{switch(t.Discriminator){case"Heading":return e.Heading();case"Title":return e.Title();case"SubHeading":return e.SubHeading();case"LargeText":return e.LargeText();case"NormalText":return e.NormalText();case"DescriptionText":return e.DescriptionText();case"Link":return e.Link();case"Button":return e.Button();case"Custom":return e.Custom(t.CustomFontSettings);default:return ls(t.Discriminator)}}}),dnt=t=>({Match:e=>{switch(t.Discriminator){case"StyleLinkedColor":return e.FontStyle();case"EmailBackgroundColor":return e.EmailBackgroundColor();case"BodyColor":return e.BodyColor();case"TitleColor":return e.TitleColor();case"HeadingColor":return e.HeadingColor();case"SubHeadingColor":return e.SubHeading();case"LargeTextColor":return e.LargeTextColor();case"NormalTextColor":return e.NormalTextColor();case"DescriptionTextColor":return e.DescriptionTextColor();case"PrimaryTextColor":return e.PrimaryTextColor();case"SecondaryTextColor":return e.SecondaryTextColor();case"ButtonTextColor":return e.ButtonTextColor();case"LinkColor":return e.LinkColor();case"PrimaryColor":return e.PrimaryColor();case"SecondaryColor":return e.SecondaryColor();case"CardBackgroundColor":return e.CardBackgroundColor();case"Custom":return e.Custom(t.CustomValue)}}}),hnt=t=>dnt(t.fontStyleColor).Match({FontStyle:()=>W0e(t.fontStyle).Match({Heading:()=>t.themeColors.HeadingColor,Title:()=>t.themeColors.TitleColor,SubHeading:()=>t.themeColors.SubHeadingColor,LargeText:()=>t.themeColors.LargeTextColor,NormalText:()=>t.themeColors.NormalTextColor,DescriptionText:()=>t.themeColors.DescriptionTextColor,Button:()=>t.themeColors.ButtonTextColor,Link:()=>t.themeColors.LinkColor,Custom:e=>Ll({color:e.FontColor,themeColors:t.themeColors})}),EmailBackgroundColor:()=>t.themeColors.EmailBackgroundColor,BodyColor:()=>t.themeColors.BodyColor,TitleColor:()=>t.themeColors.TitleColor,HeadingColor:()=>t.themeColors.HeadingColor,SubHeading:()=>t.themeColors.SubHeadingColor,LargeTextColor:()=>t.themeColors.LargeTextColor,NormalTextColor:()=>t.themeColors.NormalTextColor,DescriptionTextColor:()=>t.themeColors.DescriptionTextColor,PrimaryTextColor:()=>t.themeColors.PrimaryTextColor,SecondaryTextColor:()=>t.themeColors.SecondaryTextColor,LinkColor:()=>t.themeColors.LinkColor,PrimaryColor:()=>t.themeColors.PrimaryColor,SecondaryColor:()=>t.themeColors.SecondaryColor,CardBackgroundColor:()=>t.themeColors.CardBackgroundColor,ButtonTextColor:()=>t.themeColors.ButtonTextColor,Custom:e=>e}),H0e=["Arial","Georgia","Tahoma","TimesNewRoman","Verdana"],Az={Arial:"Arial",Georgia:"Georgia",Tahoma:"Tahoma",TimesNewRoman:"Times New Roman",Verdana:"Verdana"},H7=t=>({fontSize:t.fontSize+"px",lineHeight:t.lineHeight+"px",fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:Az[t.fontFamily],textDecoration:t.textDecoration,color:t.color}),z7=t=>{const e=n=>({fontSize:n.FontSize,lineHeight:n.LineHeight,fontWeight:n.IsBold?"bold":"normal",fontStyle:n.IsItalic?"italic":"normal",fontFamily:t.fontFamily,textDecoration:W7({textDecoration:n.Decoration}),color:hnt({fontStyleColor:t.fontStyle.FontColor,fontStyle:t.fontStyle,themeColors:t.themeColors})});return W0e(t.fontStyle).Match({Heading:()=>e(t.themeDefinedFontSettings.Heading),Title:()=>e(t.themeDefinedFontSettings.Title),SubHeading:()=>e(t.themeDefinedFontSettings.SubHeading),LargeText:()=>e(t.themeDefinedFontSettings.LargeText),NormalText:()=>e(t.themeDefinedFontSettings.NormalText),DescriptionText:()=>e(t.themeDefinedFontSettings.DescriptionText),Link:()=>e(t.themeDefinedFontSettings.Link),Button:()=>e(t.themeDefinedFontSettings.Button),Custom:n=>P0e({customFontSettings:n,themeColors:t.themeColors})})},mnt=t=>({Match:e=>{switch(t.Discriminator){case"Theme":return e.Theme();case"Custom":return e.Custom(t.CustomValue);default:return ls(t.Discriminator)}}}),fnt=t=>mnt(t.buttonPaddings).Match({Theme:()=>({TopBottom:t.themeButtonPaddings.TopBottom,LeftRight:t.themeButtonPaddings.LeftRight}),Custom:e=>({TopBottom:e.TopBottom,LeftRight:e.LeftRight})}),pnt=["align"],gnt={class:"Button"},Cnt=["href"],ynt=Ze({__name:"ButtonVue",props:{deps:{},theme:{},element:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onElementClicked"],setup(t,{emit:e}){const n=t,r=q(()=>H7(z7({fontFamily:n.theme.FontFamily,fontStyle:n.element.TextStyle,themeDefinedFontSettings:n.theme.FontSettingsPresets,themeColors:n.theme.Colors}))),o=q(()=>c_({borderColor:n.element.Border.Left.Color,themeColors:n.theme.Colors})),i=q(()=>fnt({buttonPaddings:n.element.Paddings,themeButtonPaddings:n.theme.ButtonPaddings})),s=q(()=>Ll({color:n.element.BackgroundColor,themeColors:n.theme.Colors})),a=q(()=>{switch(n.element.ContentAlign){case"Center":return"center";case"Left":return"left";case"Right":return"right";default:return"center"}}),l=Mt({href:"",text:"",isLoading:!0}),u=n.deps.stringExpressionEvaluator,c=()=>{Promise.all([u({stringExpression:n.element.HRef,context:n.context}),u({stringExpression:n.element.Text,context:n.context})]).then(([h,m])=>{l.href=h,l.text=m,l.isLoading=!1})};c(),mn(()=>[n.element.HRef,n.element.Text,n.context],()=>c());const d=e;return(h,m)=>(I(),J("table",{style:{"border-spacing":"0","border-collapse":"collapse",width:"100%"},onClick:m[1]||(m[1]=wr(f=>d("onElementClicked"),["prevent"]))},[R("tbody",null,[R("tr",null,[R("td",{align:a.value},[R("div",gnt,[R("a",{style:he([{display:"block","text-decoration":"none"},[r.value]]),href:l.href,onClick:m[0]||(m[0]=wr(()=>{},["prevent"]))},[R("table",{style:he([[{backgroundColor:s.value},z(Wu)({borderRadius:n.element.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner}),{width:n.element.FullWidth?"100%":"auto"},z(md)({border:n.element.Border,themeColors:t.theme.Colors}),{borderColor:o.value}],{"text-align":"center","border-spacing":"0","border-collapse":"separate"}])},[R("tbody",null,[R("tr",null,[R("td",{align:"center",style:he([{"line-height":"normal"},[{paddingTop:i.value.TopBottom+"px",paddingBottom:i.value.TopBottom+"px",paddingLeft:i.value.LeftRight+"px",paddingRight:i.value.LeftRight+"px"}]])},[It(R("p",{class:"user-select-none",style:he([r.value])},null,4),[[z(Dz),l.text]])],4)])])],4)],12,Cnt)])],8,pnt)])])]))}}),bnt=Qe(ynt,[["__scopeId","data-v-f2906df7"]]),vnt=["href"],Tnt=Ze({__name:"SpanText",props:{deps:{},theme:{},element:{},context:{type:[String,Number,Boolean,Array,Object]}},emits:["onElementClicked"],setup(t,{emit:e}){const n=t,r=n.deps.stringExpressionEvaluator,o=q(()=>{const u=z7({fontFamily:n.theme.FontFamily,fontStyle:n.element.Style,themeDefinedFontSettings:n.theme.FontSettingsPresets,themeColors:n.theme.Colors});if(n.element.Style.Discriminator==="Custom"){const c=P0e({customFontSettings:n.element.Style.CustomFontSettings,themeColors:n.theme.Colors});return{...c,fontSize:c.fontSize+"px",lineHeight:c.lineHeight+"px",minHeight:n.element.MinNumberOfLines*u.lineHeight+"px"}}return{minHeight:n.element.MinNumberOfLines*u.lineHeight+"px",color:u.color}}),i=Mt({href:"",text:"",isLoading:!0}),s=u=>u.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;"),a=()=>{Promise.all([r({stringExpression:n.element.HRef,context:n.context}),r({stringExpression:n.element.Text,context:n.context})]).then(([u,c])=>{i.href=u,i.text=s(c),i.isLoading=!1})};a(),mn(()=>[n.context,n.element.HRef,n.element.Text],()=>a());const l=e;return(u,c)=>n.element.IsLink?It((I(),J("a",{key:0,href:i.href,class:Me(["SpanText cursor-pointer user-select-none",n.element.Style.Discriminator]),style:he([{margin:"0"},[o.value,z(qx)({contentAlign:n.element.ContentAlign})]]),onClick:c[0]||(c[0]=wr(()=>l("onElementClicked"),["prevent"]))},null,14,vnt)),[[z(Dz),i.text]]):It((I(),J("span",{key:1,class:Me(["SpanText cursor-pointer user-select-none",n.element.Style.Discriminator]),style:he([{margin:"0"},[o.value,z(qx)({contentAlign:n.element.ContentAlign})]]),onClick:c[1]||(c[1]=wr(()=>l("onElementClicked"),["prevent"]))},null,6)),[[z(Dz),i.text]])}}),Fnt=Qe(Tnt,[["__scopeId","data-v-f6595f5e"]]),us=t=>({fontSize:t.themeFontSettings.FontSize,lineHeight:t.themeFontSettings.LineHeight,fontWeight:t.themeFontSettings.IsBold?"bold":"normal",fontStyle:t.themeFontSettings.IsItalic?"italic":"normal",fontFamily:t.fontFamily,textDecoration:W7({textDecoration:t.themeFontSettings.Decoration}),color:t.themeColor}),xnt={class:"bootstrap-styles modal fade show d-block position-absolute"},Snt={class:"bootstrap-styles modal-dialog modal-dialog-centered"},wnt={class:"bootstrap-styles modal-content border rounded-3 shadow","data-test":"modal-window__content"},knt={class:"bootstrap-styles modal-header p-0"},Ent={class:"bootstrap-styles container-fluid border-bottom g-0"},Rnt={class:"bootstrap-styles d-flex justify-content-between align-items-center px-11 py-7"},_nt={class:"bootstrap-styles modal-title border-0","data-test":"modal-window__header-text"},Dnt={class:"bootstrap-styles modal-body p-0","data-test":"modal-window__body"},Ant={class:"bootstrap-styles modal-footer p-0 g-0"},$nt={class:"bootstrap-styles container-fluid border-top"},Nnt={class:"bootstrap-styles d-flex justify-content-end py-8 px-11"},Bnt={class:"bootstrap-styles col-6 d-flex justify-content-end","data-test":"modal-window__footer-actions"},Lnt=Ze({__name:"ModalWindow",props:{headerText:{}},emits:["close"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("div",xnt,[R("div",{class:"bootstrap-styles modal-blur d-block position-fixed top-0 left-0 w-100 vh-100","data-test":"modal-window__outside",onClick:i[0]||(i[0]=s=>r("close"))}),R("div",Snt,[R("div",wnt,[R("div",knt,[R("div",Ent,[R("div",Rnt,[R("h5",_nt,en(n.headerText),1),R("button",{type:"button","aria-label":"Close","data-bs-dismiss":"modal","data-test":"modal-window__close-button",onClick:i[1]||(i[1]=s=>r("close"))},[...i[2]||(i[2]=[R("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[R("path",{d:"M3 3L13 13",stroke:"var(--gray-500)"}),R("path",{d:"M13 3L3 13",stroke:"var(--gray-500)"})],-1)])])])])]),R("div",Dnt,[M0(o.$slots,"body",{},void 0,!0)]),R("div",Ant,[R("div",$nt,[R("div",Nnt,[R("div",Bnt,[M0(o.$slots,"footer-actions",{},void 0,!0)])])])])])])]))}}),z0e=Qe(Lnt,[["__scopeId","data-v-7a4aac23"]]),Vnt={cancelButton:"Cancel",applyButton:"Delete"},Mnt={cancelButton:"Отмена",applyButton:"Удалить"},yee=jn({en:Vnt,ru:Mnt}),Ont={class:"bootstrap-styles px-11 py-7 text-start"},Int=Ze({__name:"RemoveConfirmModalWindow",props:{headerText:{},deps:{}},emits:["cancel","confirmed"],setup(t,{emit:e}){const n=t,r=()=>{i("cancel")},o={cancelButton:yee({localeKey:n.deps.localeKey}).cancelButton,applyButton:yee({localeKey:n.deps.localeKey}).applyButton},i=e;return(s,a)=>(I(),et(z0e,{headerText:n.headerText,class:"remove-element-confirm-modal-window",onClose:a[2]||(a[2]=()=>r())},{body:wu(()=>[R("div",Ont,[M0(s.$slots,"body-content")])]),"footer-actions":wu(()=>[R("button",{class:"modal-footer__button bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-3 rounded-2 bg-blue-selected button__hover-blue-100 text-color-selected",onClick:a[0]||(a[0]=wr(l=>r(),["stop"]))},en(o.cancelButton),1),R("button",{class:"modal-footer__button bootstrap-styles d-flex justify-content-center align-center py-1 px-3 rounded-2 text-white cursor-pointer remove-element-confirm__button",onClick:a[1]||(a[1]=wr(l=>i("confirmed"),["stop"]))},en(o.applyButton),1)]),_:3},8,["headerText"]))}}),Pnt={removeWindowTitle:"Delete element",removeWindowDescription:"Are you sure you want to delete the text element?"},Wnt={removeWindowTitle:"Удаление элемента",removeWindowDescription:"Вы действительно хотите удалить элемент ?"},bee=jn({en:Pnt,ru:Wnt}),vee=t=>({type:"doc",content:t.Content.map(Hnt)}),Hnt=t=>"ParagraphNode"in t?K0e(t):"BulletListNode"in t?znt(t):"OrderedListNode"in t?jnt(t):"DataFieldNode"in t?U0e(t):ls(t),j0e=t=>({type:"listItem",content:t.Content.map(e=>"ParagraphNode"in e?K0e(e):"ImageNode"in e?q0e(e):ls(e))}),U0e=t=>({type:"dataField",marks:j7({textStyle:t.DataFieldNode.TextStyle,commonLinkMark:t.DataFieldNode.CommonLinkMark}),attrs:{stringExpression:t.DataFieldNode.StringExpression}}),znt=t=>({type:"bulletList",content:t.BulletListNode.Content.map(j0e),attrs:{themeName:t.BulletListNode.ListStyle}}),jnt=t=>({type:"orderedList",content:t.OrderedListNode.Content.map(j0e),attrs:{themeName:t.OrderedListNode.ListStyle}}),K0e=t=>{const e=t.ParagraphNode.Content[0],n=t.ParagraphNode.Content.length===1&&e!==void 0&&"HardBreakNode"in e;return{type:"paragraph",attrs:{themeName:t.ParagraphNode.ThemeName,contentAlign:t.ParagraphNode.ContentAlign},content:n?[]:t.ParagraphNode.Content.map(Unt)}},Unt=t=>"TextNode"in t?Knt(t):"HardBreakNode"in t?Znt():"ImageNode"in t?q0e(t):"DataFieldNode"in t?U0e(t):ls(t),j7=t=>{const e=[];return t.textStyle&&e.push(Xnt(t.textStyle)),t.commonLinkMark&&e.push(Qnt(t.commonLinkMark)),e.filter(n=>n!==void 0)},Knt=t=>({type:"text",text:t.TextNode.Text,marks:j7({textStyle:t.TextNode.TextStyle,commonLinkMark:t.TextNode.CommonLinkMark})}),qnt=t=>{switch(t){case"Normal":return"normal";case"Bold":return"bold";default:return"normal"}},Jnt=t=>{switch(t){case"Normal":return"normal";case"Italic":return"italic";default:return"normal"}},Gnt=t=>{switch(t){case"None":return"none";case"Uppercase":return"uppercase";default:return"none"}},Ynt=t=>{switch(t){case"None":return"none";case"Underline":return"underline";case"LineThrough":return"line-through";default:return"none"}},Xnt=t=>({type:"textStyle",attrs:{themeName:t.ThemeName,color:t.Style.Color,fontWeight:t.Style.FontWeight?qnt(t.Style.FontWeight):void 0,fontStyle:t.Style.FontStyle?Jnt(t.Style.FontStyle):void 0,fontSize:t.Style.FontSize?t.Style.FontSize+"px":void 0,lineHeight:t.Style.LineHeight?t.Style.LineHeight+"px":void 0,fontFamily:t.Style.FontFamily,textTransform:t.Style.TextTransform?Gnt(t.Style.TextTransform):void 0,textDecoration:t.Style.TextDecoration?Ynt(t.Style.TextDecoration):void 0}}),Qnt=t=>Wl(t).Match({LinkMark:e=>ert({LinkMark:e}),UnsubscribeLinkMark:()=>trt()}),Znt=()=>({type:"hardBreak"}),q0e=t=>({type:"image",attrs:{src:t.ImageNode.Src,alt:t.ImageNode.Alt,isRetina:t.ImageNode.IsRetina,width:t.ImageNode.Width,height:t.ImageNode.Height},marks:j7({commonLinkMark:t.ImageNode.CommonLinkMark})}),ert=t=>({type:"link",attrs:{href:t.LinkMark.Href}}),trt=()=>({type:"unsubscribeLink"}),J0e=tc.create({name:"textTransform",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{textTransform:{default:"none",parseHTML:t=>t.style.textTransform,renderHTML:t=>t.textTransform?{style:`text-transform: ${t.textTransform}`}:{}}}}]},addCommands(){return{setTextTransform:t=>({chain:e})=>e().setMark("textStyle",{textTransform:t}).run(),unsetTextTransform:()=>({chain:t,state:e})=>{const{from:n,to:r,$from:o}=e.selection;return e.doc.textBetween(n,r," ").length?t().setMark("textStyle",{textTransform:"none"}).run():t().setTextSelection({from:o.pos-o.nodeBefore.nodeSize,to:o.pos+o.nodeAfter.nodeSize}).setMark("textStyle",{textTransform:"none"}).focus().run()}}},addKeyboardShortcuts(){const t=e=>e.isUppercase?this.editor.commands.unsetTextTransform():this.editor.commands.setTextTransform("uppercase");return{"Mod-Shift-u":()=>{const e=this.editor.isActive("textStyle",{textTransform:"uppercase"});return t({isUppercase:e})},"Mod-Shift-U":()=>{const e=this.editor.isActive("textStyle",{textTransform:"uppercase"});return t({isUppercase:e})}}}}),nrt=tc.create({name:"fontSize",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontSize:{default:null,parseHTML:t=>t.style.fontSize.replace(/['"]+/g,""),renderHTML:t=>t.fontSize?{style:`font-size: ${t.fontSize}`}:{}}}}]},addCommands(){return{setFontSize:t=>({chain:e})=>e().setMark("textStyle",{fontSize:t+"px"}).run(),unsetFontSize:()=>({chain:t})=>t().setMark("textStyle",{fontSize:null}).removeEmptyTextStyle().run()}}}),rrt=tc.create({name:"lineHeight",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{lineHeight:{default:null,parseHTML:t=>t.style.lineHeight.replace(/['"]+/g,""),renderHTML:t=>t.lineHeight?{style:`line-height: ${t.lineHeight}`}:{}}}}]},addCommands(){return{setLineHeight:t=>({chain:e})=>e().setMark("textStyle",{lineHeight:t+"px"}).run(),resetLineHeight:()=>({chain:t})=>t().setMark("textStyle",{lineHeight:null}).run()}}}),ort=t=>pn.create({name:"themeFontStyles",priority:1e3,addOptions(){return{types:["textStyle","bulletList","orderedList","paragraph"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{themeName:{default:t,parseHTML:e=>e.getAttribute("data-theme"),renderHTML:e=>e.themeName?{"data-theme":e.themeName,class:e.themeName}:{"data-theme":t,class:e.themeName}}}}]},addCommands(){return{setThemeSettings:e=>({chain:n,state:r})=>{const{$from:o}=r.selection,i=o.parent,s=o.index();return i.child(s).type.name==="image"?!1:n().setMark("textStyle",{themeName:e}).run()},applySiblingNodeThemeSettings:()=>({chain:e,state:n})=>{const{from:r,to:o,$from:i}=n.selection,s=i.parent,a=i.index(),l=i.node(i.depth)?.type.name==="dataField"||s.maybeChild(a)?.type.name==="dataField",u=s.child(a).type.name==="image",c=f=>{const p="NormalText",g=f.index>0?s.child(f.index-1):void 0,y=f.index+1<s.childCount?s.child(f.index+1):void 0,b=g??y;if(b){const F=b.marks.find(T=>T.type.name==="textStyle");if(F)return F.attrs.themeName}return p};if(l){const f=c({index:a});return e().unsetMark("textStyle",{extendEmptyMarkRange:!0}).setThemeSettings(f).run()}if(u)return!1;const d=c({index:a}),h=i.nodeBefore?i.pos-i.nodeBefore.nodeSize:r,m=i.nodeAfter?i.pos+i.nodeAfter.nodeSize:o;return e().setTextSelection({from:h,to:m}).setThemeSettings(d).run()}}},addProseMirrorPlugins(){return[new Xn({key:new Nr("syncBlockTheme"),appendTransaction:(e,n,r)=>{const o=r.tr;let i=!1;return r.doc.descendants((s,a)=>{if(s.type.name==="bulletList"||s.type.name==="orderedList"){const l=s.firstChild?.firstChild?.firstChild;if(l){const u=l.marks.find(c=>c.type.name==="textStyle")?.attrs.themeName;u&&s.attrs.themeName!==u&&(o.setNodeMarkup(a,void 0,{...s.attrs,themeName:u}),i=!0)}}if(s.type.name==="paragraph"){const l=s.firstChild;if(l){const u=l.marks.find(c=>c.type.name==="textStyle")?.attrs.themeName;u&&s.attrs.themeName!==u&&(o.setNodeMarkup(a,void 0,{...s.attrs,themeName:u}),i=!0)}}}),i?o:null}})]}}),irt=tc.create({name:"fontWeight",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontWeight:{default:null,parseHTML:t=>t.style.fontWeight,renderHTML:t=>t.fontWeight?{style:`font-weight: ${t.fontWeight}`}:{}}}}]},addCommands(){return{setFontWeight:t=>({chain:e})=>e().setMark("textStyle",{fontWeight:t}).run(),unsetFontWeight:()=>({chain:t,state:e})=>{const{from:n,to:r,$from:o}=e.selection;return e.doc.textBetween(n,r," ").length?t().setMark("textStyle",{fontWeight:"normal"}).run():t().setTextSelection({from:o.pos-o.nodeBefore.nodeSize,to:o.pos+o.nodeAfter.nodeSize}).setMark("textStyle",{fontWeight:"normal"}).focus().run()},resetFontWeight:()=>({chain:t})=>t().setMark("textStyle",{fontWeight:null}).removeEmptyTextStyle().run()}},addKeyboardShortcuts(){const t=e=>e.isBold?this.editor.commands.unsetFontWeight():this.editor.commands.setFontWeight("bold");return{"Mod-b":()=>{const e=this.editor.isActive("textStyle",{fontWeight:"bold"});return t({isBold:e})},"Mod-B":()=>{const e=this.editor.isActive("textStyle",{fontWeight:"bold"});return t({isBold:e})}}}}),srt=tc.create({name:"fontStyle",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontStyle:{default:null,parseHTML:t=>t.style.fontStyle,renderHTML:t=>t.fontStyle?{style:`font-style: ${t.fontStyle}`}:{}}}}]},addCommands(){return{setFontStyle:t=>({chain:e})=>e().setMark("textStyle",{fontStyle:t}).run(),unsetFontStyle:()=>({chain:t,state:e})=>{const{from:n,to:r,$from:o}=e.selection;return e.doc.textBetween(n,r," ").length?t().setMark("textStyle",{fontStyle:"normal"}).run():t().setTextSelection({from:o.pos-o.nodeBefore.nodeSize,to:o.pos+o.nodeAfter.nodeSize}).setMark("textStyle",{fontStyle:"normal"}).focus().run()},resetFontStyle:()=>({chain:t})=>t().setMark("textStyle",{fontStyle:null}).removeEmptyTextStyle().run()}},addKeyboardShortcuts(){const t=e=>e.isItalic?this.editor.commands.unsetFontStyle():this.editor.commands.setFontStyle("italic");return{"Mod-i":()=>{const e=this.editor.isActive("textStyle",{fontStyle:"italic"});return t({isItalic:e})},"Mod-I":()=>{const e=this.editor.isActive("textStyle",{fontStyle:"italic"});return t({isItalic:e})}}}}),U7=tc.create({name:"unsubscribeLink",priority:1e3,addOptions(){return{HTMLAttributes:{"data-type":"unsubscribe-link",class:"rich-text__unsubscribe-link"}}},parseHTML(){return[{tag:'span[data-type="unsubscribe-link"]'}]},renderHTML({HTMLAttributes:t}){return["span",ki(this.options.HTMLAttributes,t),0]},addCommands(){return{setUnsubscribeLink:()=>({chain:t})=>t().setMark("unsubscribeLink").focus().run(),unsetUnsubscribeLink:()=>({chain:t,state:e})=>{const{from:n,to:r}=e.selection,o=e.doc.textBetween(n,r," ");return e.doc.nodeAt(n)?.type.name==="image"?t().unsetMark("unsubscribeLink").focus().run():o.length?t().setTextSelection({from:n,to:n+o.length}).unsetMark("unsubscribeLink").focus().run():t().unsetMark("unsubscribeLink",{extendEmptyMarkRange:!0}).focus().run()}}}}),art=tc.create({name:"textDecoration",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{textDecoration:{parseHTML:t=>t.style.textDecoration,renderHTML:t=>t.textDecoration?{style:`text-decoration: ${t.textDecoration}`}:{}}}}]},addCommands(){return{setTextDecoration:t=>({chain:e})=>e().setMark("textStyle",{textDecoration:t}).run(),unsetTextDecoration:()=>({chain:t,state:e})=>{const{from:n,to:r,$from:o}=e.selection;return e.doc.textBetween(n,r," ").length?t().setMark("textStyle",{textDecoration:"none"}).run():t().setTextSelection({from:o.pos-o.nodeBefore.nodeSize,to:o.pos+o.nodeAfter.nodeSize}).setMark("textStyle",{textDecoration:"none"}).focus().run()}}},addKeyboardShortcuts(){const t=n=>n.isUnderline?this.editor.commands.unsetTextDecoration():this.editor.commands.setTextDecoration("underline"),e=n=>n.isLineThrough?this.editor.commands.unsetTextDecoration():this.editor.commands.setTextDecoration("line-through");return{"Mod-Shift-s":()=>{const n=this.editor.isActive("textStyle",{textDecoration:"line-through"});return e({isLineThrough:n})},"Mod-u":()=>{const n=this.editor.isActive("textStyle",{textDecoration:"underline"});return t({isUnderline:n})},"Mod-U":()=>{const n=this.editor.isActive("textStyle",{textDecoration:"underline"});return t({isUnderline:n})}}}}),lrt=t=>{if(!t.content)throw new Error("Invalid document: content is missing");return{Content:t.content.map(e=>{switch(e.type){case"paragraph":return G0e(e);case"bulletList":return drt(e);case"orderedList":return hrt(e);default:throw new Error(`Unknown node type: ${e.type}`)}})}},G0e=t=>t.content?{ParagraphNode:{ThemeName:t.attrs?t.attrs.themeName:void 0,ContentAlign:t.attrs?t.attrs.contentAlign:void 0,Content:t.content.map(e=>{switch(e.type){case"text":return urt(e);case"image":return X0e(e);case"hardBreak":return Tee();case"dataField":return crt(e);default:throw new Error(`Unknown node type: ${e.type}`)}})}}:{ParagraphNode:{ThemeName:t.attrs?t.attrs.themeName:void 0,ContentAlign:t.attrs?t.attrs.contentAlign:void 0,Content:[Tee()]}},K7=t=>{const e=t?t.find(r=>r.type==="textStyle"):void 0,n=t?t.find(r=>r.type==="link"||r.type==="unsubscribeLink"):void 0;return{TextStyle:e?yrt(e):void 0,CommonLinkMark:n?brt(n):void 0}},urt=t=>{if(typeof t.text!="string")throw new Error("Invalid text node: text is missing or not a string");const{TextStyle:e,CommonLinkMark:n}=K7(t.marks);return{TextNode:{Text:t.text,TextStyle:e,CommonLinkMark:n}}},Tee=()=>({HardBreakNode:{}}),crt=t=>{if(!t.attrs)throw new Error("Invalid variable node: attrs is missing");const{TextStyle:e,CommonLinkMark:n}=K7(t.marks);return{DataFieldNode:{StringExpression:t.attrs.stringExpression,TextStyle:e,CommonLinkMark:n}}},drt=t=>{if(!t.content)throw new Error("Invalid bulletList: content is missing");return{BulletListNode:{ListStyle:t.attrs?t.attrs.themeName:void 0,Content:t.content.map(Y0e)}}},hrt=t=>{if(!t.content)throw new Error("Invalid orderedList: content is missing");return{OrderedListNode:{ListStyle:t.attrs?t.attrs.themeName:void 0,Content:t.content.map(Y0e)}}},Y0e=t=>{if(!t.content)throw new Error("Invalid listItem: content is missing");return{Content:t.content.map(e=>{switch(e.type){case"paragraph":return G0e(e);case"image":return X0e(e);default:throw new Error(`Unknown node type: ${e.type}`)}})}},X0e=t=>{if(!t.attrs)throw new Error("Invalid image node: attrs is missing");const{CommonLinkMark:e}=K7(t.marks);return{ImageNode:{Src:t.attrs.src,Alt:t.attrs.alt,Width:t.attrs.width,Height:t.attrs.height,IsRetina:t.attrs.isRetina,CommonLinkMark:e}}},mrt=t=>t==="bold"?"Bold":"Normal",frt=t=>t==="italic"?"Italic":"Normal",prt=t=>t,grt=t=>{switch(t){case"uppercase":return"Uppercase";default:return"None"}},Crt=t=>{switch(t){case"underline":return"Underline";case"line-through":return"LineThrough";default:return"None"}},Fee=t=>{const e=t.replace(/px$/,"");return parseInt(e,10)},yrt=t=>{if(!t.attrs)throw new Error("Invalid textStyle mark: attrs is missing");return{ThemeName:t.attrs.themeName,Style:{Color:t.attrs.color?t.attrs.color:void 0,FontWeight:t.attrs.fontWeight?mrt(t.attrs.fontWeight):void 0,FontStyle:t.attrs.fontStyle?frt(t.attrs.fontStyle):void 0,FontSize:t.attrs.fontSize?Fee(t.attrs.fontSize):void 0,LineHeight:t.attrs.lineHeight?Fee(t.attrs.lineHeight):void 0,FontFamily:t.attrs.fontFamily?prt(t.attrs.fontFamily):void 0,TextTransform:t.attrs.textTransform?grt(t.attrs.textTransform):void 0,TextDecoration:t.attrs.textDecoration?Crt(t.attrs.textDecoration):void 0}}},brt=t=>{switch(t.type){case"link":{if(!t.attrs)throw new Error("Invalid link mark: attrs.href is missing");return{LinkMark:{Href:t.attrs.href}}}case"unsubscribeLink":return{UnsubscribeLinkMark:{}};default:return}},Q0e=t=>{if(!t)return null;if(/^#([A-Fa-f0-9]{3}){1,2}$/.test(t))return t;if(t.startsWith("rgb")){const n=t.replace(/[^\d,.]/g,"").split(","),r=n[0]?parseInt(n[0]):0,o=n[1]?parseInt(n[1]):0,i=n[2]?parseInt(n[2]):0;return`#${(1<<24|r<<16|o<<8|i).toString(16).slice(1)}`}if(t.startsWith("hsl")){const n=document.createElement("div");n.style.color=t,document.body.appendChild(n);const r=getComputedStyle(n).color;return document.body.removeChild(n),Q0e(r)}const e=document.createElement("canvas").getContext("2d");return e?(e.fillStyle=t,e.fillStyle):null},vrt=t=>pn.create({name:"color",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{color:{default:null,parseHTML:e=>{const n=e.getAttribute("data-theme-color")??"Custom",r=Q0e(e.style.color)??"#000000";return{Discriminator:n,CustomValue:r}},renderHTML:e=>{if(!e.color)return{};const n=PV({fontColor:e.color,themeColors:t.themeColors});return e.color.Discriminator==="Custom"?{"data-theme-color":e.color.Discriminator,style:`color: ${n}`}:{"data-theme-color":e.color.Discriminator}}}}}]},addCommands(){return{setColor:e=>({chain:n})=>n().setMark("textStyle",{color:e}).run(),unsetColor:()=>({chain:e})=>e().setMark("textStyle",{color:null}).removeEmptyTextStyle().run()}}}),Trt=pn.create({name:"fontFamily",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontFamily:{default:null,parseHTML:t=>{const e=t.style.fontFamily.split(",").map(n=>n.trim()).map(n=>n.replace(/^['"]|['"]$/g,"")).map(n=>n.replace(/ /g,""));return H0e.find(n=>e.includes(n))||null},renderHTML:t=>t.fontFamily?{style:`font-family: ${t.fontFamily}`}:{}}}}]},addCommands(){return{setFontFamily:t=>({chain:e})=>e().setMark("textStyle",{fontFamily:t}).run(),unsetFontFamily:()=>({chain:t})=>t().setMark("textStyle",{fontFamily:null}).removeEmptyTextStyle().run()}}}),Z0e=t=>Wl(t),Frt=t=>Il.create({name:"dataField",group:"inline",marks:"_",inline:!0,atom:!0,selectable:!0,addAttributes:()=>({stringExpression:{default:null,parseHTML:e=>JSON.parse(e.getAttribute("data-field")),renderHTML:e=>({"data-field":JSON.stringify(e.stringExpression)})}}),parseHTML:()=>[{tag:"data-field[data-field]"}],renderHTML:({node:e,HTMLAttributes:n})=>{const r=e.attrs.stringExpression,o=Z0e(r).Match({ContextValueExpression:()=>"contextValue",ContextValueExpressionWithFallback:()=>"contextValueWithFallback",ConstValueExpression:i=>i.Value,TruncateValueExpression:()=>"truncate",ConcatStringExpressions:()=>"concat",NumberToStringExpression:()=>"numberToString",DataSource:i=>t.dataSourceFieldNameDelegate({dataSource:i}),UnsubscribeUrlExpression:()=>"unsubscribeUrl",RecipientEmailAddressExpression:()=>"recipientEmailAddress"});return["data-field",ki(n,{class:"rich-text__variable","data-field":JSON.stringify(e.attrs.stringExpression),contenteditable:"false"}),o]},addCommands(){return{setVariable:e=>({chain:n,state:r})=>{const o=r.selection.$from.marks(),i=o.map(s=>({type:s.type.name,attrs:s.attrs}));return n().insertContent({type:this.name,attrs:{stringExpression:e,selectedMarks:o},marks:i}).focus().run()}}}}),ebe=t=>new Promise((e,n)=>{const r=new Image;r.onload=()=>{e({width:r.naturalWidth,height:r.naturalHeight})},r.onerror=n,r.src=t}),tbe=Il.create({name:"image",addOptions(){return{inline:!0,allowBase64:!1,HTMLAttributes:{}}},inline(){return this.options.inline},group(){return this.options.inline?"inline":"block"},draggable:!0,addAttributes(){return{src:{default:null},alt:{default:null},width:{default:null},height:{default:null},isRetina:{default:!1}}},parseHTML(){return[{tag:this.options.allowBase64?"img[src]":'img[src]:not([src^="data:"])'}]},renderHTML({HTMLAttributes:t}){return["img",ki(this.options.HTMLAttributes,{src:t.src,alt:t.alt,title:t.title,width:t.isRetina?t.width/2:t.width,height:t.isRetina?t.height/2:t.height,isRetina:t.isRetina})]},addCommands(){return{setImage:t=>({commands:e})=>e.insertContent({type:this.name,attrs:t})}},addInputRules(){return[RKe({find:/(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/,type:this.type,getAttributes:t=>{const[,,e,n,r]=t;return{src:n,alt:e,title:r}}})]},addProseMirrorPlugins(){return[new Xn({view:t=>((async()=>{const{state:e,dispatch:n}=t;e.doc.descendants((r,o)=>{if(r.type.name===this.name){const{src:i,width:s,height:a}=r.attrs;i&&(!s||!a)&&ebe(i).then(l=>{const u=e.tr.setNodeMarkup(o,void 0,{...r.attrs,width:l.width,height:l.height});n(u)})}})})(),{})})]}}),xrt=t=>pn.create({name:"paragraphContentAlign",addOptions(){return{defaultContentAlign:"Left"}},addGlobalAttributes(){return[{types:["paragraph"],attributes:{contentAlign:{default:t.fallbackContentAlign,parseHTML:e=>{const n=e.style.textAlign;return n===""?t.fallbackContentAlign:n==="left"?"Left":n==="center"?"Center":n==="right"?"Right":t.fallbackContentAlign},renderHTML:e=>{const n=e.contentAlign||this.options.defaultContentAlign||"Left";return{style:`text-align: ${{Left:"left",Center:"center",Right:"right"}[n]}`}}}}}]},addCommands(){return{setParagraphContentAlign:e=>({state:n,tr:r})=>{const{$from:o}=n.selection,i=o.parent;if(i.type.name!=="paragraph")return!1;const s=o.before(o.depth);return r.setNodeMarkup(s,void 0,{...i.attrs,contentAlign:e}),!0}}}}),Srt=t=>[pqe,tJe,fqe,RV.configure({mergeNestedSpanStyles:!0}),Pqe,Frt({dataSourceFieldNameDelegate:t.dataSourceFieldNameDelegate}),mqe.configure({className:"has-focus",mode:"all"}),d7.configure({keepMarks:!0,keepAttributes:!0}),m7.configure({keepMarks:!0,keepAttributes:!0}),YCe,eJe.configure({HTMLAttributes:{class:"hard-break"}}),c7.configure({HTMLAttributes:{class:"rich-text__link"},openOnClick:!1}),tbe.configure({inline:!0,HTMLAttributes:{class:"rich-text__image"}}),vrt({themeColors:t.themeColors}),ort(t.initialThemeName),irt,srt,nrt,rrt,J0e,art,U7,Trt,xrt({fallbackContentAlign:t.fallbackContentAlign})],wrt=t=>lrt(t.editor.getJSON()),krt=Ze({__name:"SelectItemColor",props:{isActive:{type:Boolean},color:{},label:{}},emits:["click"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("li",{class:Me(["bootstrap-styles dropdown-item p-0 user-select-none",{active:n.isActive}])},[R("span",{class:"bootstrap-styles d-block py-1 px-3 text-decoration-none text-reset cursor-pointer d-flex align-items-center justify-content-start",onClick:i[0]||(i[0]=s=>r("click"))},[R("i",{class:"bootstrap-styles input__color_selection d-block overflow-hidden me-2",style:he([{border:"1px solid rgba(0, 0, 0, 0.10)"},[{background:n.color}]])},null,4),rw(" "+en(n.label),1)])],2))}}),Ert={colorLabels:{none:"None",styleLinkedColor:"Link to style",emailBackgroundColor:"Email background",bodyColor:"Email body",primaryColor:"Primary color",secondaryColor:"Secondary color",primaryTextColor:"Primary text",secondaryTextColor:"Secondary text",cardBackgroundColor:"Product card color",buttonTextColor:"Buttons",titleColor:"Title",headingColor:"Heading",subHeadingColor:"Subheading",largeTextColor:"Large text",normalTextColor:"Text",descriptionTextColor:"Description",linkColor:"Link",custom:"Custom"}},Rrt={colorLabels:{none:"Нет",styleLinkedColor:"Связать со стилем",emailBackgroundColor:"Фон письма",bodyColor:"Тело письма",primaryColor:"Основной цвет",secondaryColor:"Вторичный цвет",primaryTextColor:"Текст на основном цвете",secondaryTextColor:"Текст на вторичном цвете",cardBackgroundColor:"Цвет карточек товара",buttonTextColor:"Кнопки",titleColor:"Большой заголовок",headingColor:"Заголовок",subHeadingColor:"Подзаголовок",largeTextColor:"Большой текст",normalTextColor:"Текст",descriptionTextColor:"Описание",linkColor:"Ссылка",custom:"Пользовательский"}},_rt=jn({en:Ert,ru:Rrt}),nbe=t=>({Match:e=>{switch(t){case"Heading":return e.whenHeading();case"Title":return e.whenTitle();case"SubHeading":return e.whenSubHeading();case"LargeText":return e.whenLargeText();case"NormalText":return e.whenNormalText();case"DescriptionText":return e.whenDescriptionText();case"Link":return e.whenLink();case"Button":return e.whenButton();default:return ls(t)}}}),WV=t=>nbe(t.themeName).Match({whenHeading:()=>t.themeFontColors.HeadingColor,whenTitle:()=>t.themeFontColors.TitleColor,whenSubHeading:()=>t.themeFontColors.SubHeadingColor,whenLargeText:()=>t.themeFontColors.LargeTextColor,whenNormalText:()=>t.themeFontColors.NormalTextColor,whenDescriptionText:()=>t.themeFontColors.DescriptionTextColor,whenLink:()=>t.themeFontColors.LinkColor,whenButton:()=>t.themeFontColors.ButtonTextColor}),Tw=t=>{const{FontFamily:e,FontSettingsPresets:n,Colors:r}=t.theme,o=!!t.editor.getAttributes("textStyle")[t.styleName],i=t.editor.getAttributes("paragraph").themeName||"NormalText",s=t.editor.getAttributes("textStyle").themeName||i;if(o)return t.editor.getAttributes("textStyle")[t.styleName];const a=us({fontFamily:e,themeFontSettings:n[s],themeColor:WV({themeName:s,themeFontColors:r})});return String(a[t.styleName])},rbe=t=>{const{FontFamily:e,FontSettingsPresets:n,Colors:r}=t.theme,o=!!t.editor.getAttributes("textStyle").color,i=t.editor.getAttributes("paragraph").themeName||"NormalText",s=t.editor.getAttributes("textStyle").themeName||i;if(o)return t.editor.getAttributes("textStyle").color;const a=us({fontFamily:e,themeFontSettings:n[s],themeColor:WV({themeName:s,themeFontColors:r})});return{Discriminator:nbe(s).Match({whenHeading:()=>"HeadingColor",whenTitle:()=>"TitleColor",whenSubHeading:()=>"SubHeadingColor",whenLargeText:()=>"LargeTextColor",whenNormalText:()=>"NormalTextColor",whenDescriptionText:()=>"DescriptionTextColor",whenLink:()=>"LinkColor",whenButton:()=>"ButtonTextColor"}),CustomValue:a.color}},Drt={class:"color-picker bootstrap-styles border rounded bg-white"},Art={class:"bootstrap-styles p-1 mb-5 bg-white"},$rt=["value"],Nrt=["value"],Brt=Ze({__name:"ColorPickerModalWindow",props:{editor:{},theme:{},deps:{}},emits:["onColorChanged","onColorPickerClosed"],setup(t,{emit:e}){const n=t,r={colorLabels:_rt({localeKey:n.deps.localeKey}).colorLabels},o=q(()=>PV({fontColor:rbe({editor:n.editor,theme:n.theme}),themeColors:n.theme.Colors})),i=Mt({color:o.value,isValidHexColor:!0}),s={StyleLinkedColor:r.colorLabels.styleLinkedColor,EmailBackgroundColor:r.colorLabels.emailBackgroundColor,BodyColor:r.colorLabels.bodyColor,PrimaryColor:r.colorLabels.primaryColor,SecondaryColor:r.colorLabels.secondaryColor,PrimaryTextColor:r.colorLabels.primaryTextColor,SecondaryTextColor:r.colorLabels.secondaryTextColor,CardBackgroundColor:r.colorLabels.cardBackgroundColor,ButtonTextColor:r.colorLabels.buttonTextColor,TitleColor:r.colorLabels.titleColor,HeadingColor:r.colorLabels.headingColor,SubHeadingColor:r.colorLabels.subHeadingColor,LargeTextColor:r.colorLabels.largeTextColor,NormalTextColor:r.colorLabels.normalTextColor,DescriptionTextColor:r.colorLabels.descriptionTextColor,LinkColor:r.colorLabels.linkColor,Custom:r.colorLabels.custom},a=["EmailBackgroundColor","BodyColor","PrimaryColor","SecondaryColor","PrimaryTextColor","SecondaryTextColor","ButtonTextColor","TitleColor","HeadingColor","SubHeadingColor","LargeTextColor","NormalTextColor","DescriptionTextColor","LinkColor"],l=R4e(h=>{d("onColorChanged",{Discriminator:"Custom",CustomValue:h})},100,{leading:!1,trailing:!0}),u=h=>/^#([0-9A-Fa-f]{6})$/.test(h.trim()),c=h=>{i.isValidHexColor=u(h),i.color=h,u(h)&&d("onColorChanged",{Discriminator:"Custom",CustomValue:h})};mn(()=>o.value,h=>{i.color=h,i.isValidHexColor=u(h)});const d=e;return(h,m)=>It((I(),J("div",null,[R("ul",Drt,[R("li",Art,[ie(z(AGe),{modelValue:o.value,width:220,canvasHeight:220,hideInputs:!0,hideSliders:!1,mode:"hex","onUpdate:modelValue":m[0]||(m[0]=f=>z(l)(f))},null,8,["modelValue"]),R("div",{class:Me(["bootstrap-styles border bg-color-input rounded-2 d-flex justify-content-between p-14",{"is-not-valid":!i.isValidHexColor}])},[R("input",{type:"color",class:"bootstrap-styles pe-none",style:{border:"1px solid rgba(0, 0, 0, 0.1)",cursor:"default"},value:o.value},null,8,$rt),R("input",{type:"text",class:"bootstrap-styles w-100 text-uppercase ps-1",value:i.color,placeholder:"#000000",onInput:m[1]||(m[1]=f=>c(f.target.value))},null,40,Nrt)],2)]),(I(),J(ot,null,zn(a,f=>ie(krt,{key:f,isActive:o.value===n.theme.Colors[f],color:n.theme.Colors[f],label:s[f],onClick:()=>{d("onColorChanged",{Discriminator:f,CustomValue:n.theme.Colors[f]}),d("onColorPickerClosed")}},null,8,["isActive","color","label","onClick"])),64))])])),[[z(Sd),()=>d("onColorPickerClosed")]])}}),Lrt=Qe(Brt,[["__scopeId","data-v-0ec36b1f"]]),Vrt={tooltip:"Text color"},Mrt={tooltip:"Цвет текста"},Ort=jn({en:Vrt,ru:Mrt}),Irt=["value"],Prt=Ze({__name:"ColorPicker",props:{editor:{},theme:{},isAllowToEdit:{type:Boolean},deps:{}},setup(t){const e=t,n={tooltip:Ort({localeKey:e.deps.localeKey}).tooltip},r=Mt({isColorPickerDropdownShown:!1}),o=yn(),i=yn(),{floatingStyles:s}=kpe(i,o,{whileElementsMounted:xpe,placement:"bottom",middleware:[Spe(({rects:l})=>({alignmentAxis:-l.floating.width/2-l.floating.width/2,mainAxis:15}))]}),a=q(()=>PV({fontColor:rbe({editor:e.editor,theme:e.theme}),themeColors:e.theme.Colors}));return(l,u)=>(I(),J(ot,null,[It((I(),J("button",{ref_key:"richTextColorPickerBtn",ref:i,class:Me(["bootstrap-styles border rich-text-color__input rich-text__handler",{disabled:!t.isAllowToEdit}]),value:a.value,onClick:u[0]||(u[0]=()=>r.isColorPickerDropdownShown=!r.isColorPickerDropdownShown)},[R("i",{style:he([{display:"block",width:"100%",height:"100%"},{backgroundColor:a.value}])},null,4)],10,Irt)),[[z(Br),{title:n.tooltip,placement:"top"}]]),r.isColorPickerDropdownShown?(I(),et(Lrt,{key:0,ref_key:"richTextColorPicker",ref:o,theme:e.theme,editor:e.editor,deps:e.deps.colorPickerModalWindowDeps,style:he(z(s)),onOnColorChanged:u[1]||(u[1]=c=>{e.editor.commands.setColor(c)}),onOnColorPickerClosed:u[2]||(u[2]=()=>{r.isColorPickerDropdownShown=!1,e.editor.commands.focus()})},null,8,["theme","editor","deps","style"])):Ue("",!0)],64))}}),Wrt=Qe(Prt,[["__scopeId","data-v-6624477a"]]),Hrt={},zrt={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function jrt(t,e){return I(),J("svg",zrt,[...e[0]||(e[0]=[R("path",{d:"M8.00033 10.0002L5.17188 7.17184L6.11469 6.229L8.00033 8.11464L9.88593 6.229L10.8287 7.17184L8.00033 10.0002Z",fill:"var(--gray-500)"},null,-1)])])}const obe=Qe(Hrt,[["render",jrt]]),Urt={tooltip:"Font family"},Krt={tooltip:"Шрифт"},qrt=jn({en:Urt,ru:Krt}),Jrt={class:"bootstrap-styles dropdown"},Grt={class:"bootstrap-styles me-14 overflow-hidden rich-text-toolbar__font-family-btn__text"},Yrt={class:"bootstrap-styles d-flex justify-content-center align-items-center"},Xrt=["onClick"],Qrt=Ze({__name:"FontFamilySelector",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:qrt({localeKey:e.deps.localeKey}).tooltip},r=RV.name,o=Mt({isOpened:!1}),i=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"fontFamily"})),s=a=>{e.editor.commands.setFontFamily(a),o.isOpened=!1,e.editor.commands.focus()};return(a,l)=>It((I(),J("div",Jrt,[R("button",{id:"richTextDropdownFontFamily",class:Me(["bootstrap-styles d-flex justify-content-between align-items-center py-1 px-3 text-nowrap rich-text-toolbar__font-family-btn border rounded-2 overflow-hidden",{disabled:!e.isAllowToEdit,show:o.isOpened}]),type:"button",onClick:l[0]||(l[0]=u=>o.isOpened=!o.isOpened)},[R("span",Grt,en(z(Az)[i.value]),1),R("i",Yrt,[ie(obe)])],2),R("ul",{class:Me([{show:o.isOpened},"bootstrap-styles dropdown-menu rounded-2 bg-white"]),"aria-labelledby":"richTextDropdownFontFamily"},[(I(!0),J(ot,null,zn(z(H0e),u=>(I(),J("li",{key:u,class:Me(["bootstrap-styles dropdown-item p-0",{active:e.editor.getAttributes(z(r)).fontFamily===u}]),onClick:()=>s(u)},[R("span",{class:"bootstrap-styles d-block py-1 px-3 text-decoration-none text-reset cursor-pointer",style:he({fontFamily:u})},en(z(Az)[u]),5)],10,Xrt))),128))],2)])),[[z(Sd),()=>o.isOpened=!1],[z(Br),{title:n.tooltip,placement:"top"}]])}}),Zrt=Qe(Qrt,[["__scopeId","data-v-cc496278"]]),eot={},tot={xmlns:"http://www.w3.org/2000/svg",width:"8",height:"8",viewBox:"0 0 8 8",fill:"none"};function not(t,e){return I(),J("svg",tot,[...e[0]||(e[0]=[R("path",{d:"M4.00003 2.38419e-07L1 2.99997L2.00001 4L4.00003 1.99998L6.00001 4L7 2.99997L4.00003 2.38419e-07Z",fill:"var(--gray-500)"},null,-1)])])}const ibe=Qe(eot,[["render",not],["__scopeId","data-v-19c42a7a"]]),rot={},oot={xmlns:"http://www.w3.org/2000/svg",width:"8",height:"8",viewBox:"0 0 8 8",fill:"none"};function iot(t,e){return I(),J("svg",oot,[...e[0]||(e[0]=[R("path",{d:"M4.00003 8L1 5.00003L2.00001 4L4.00003 6.00002L6.00001 4L7 5.00003L4.00003 8Z",fill:"var(--gray-500)"},null,-1)])])}const sbe=Qe(rot,[["render",iot],["__scopeId","data-v-313c2951"]]),sot={},aot={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function lot(t,e){return I(),J("svg",aot,[...e[0]||(e[0]=[R("path",{d:"M6.66634 4.00033V14.0003H5.33301V4.00033H1.33301V2.66699H10.6663V4.00033H6.66634ZM11.9997 9.33366V14.0003H10.6663V9.33366H8.66634V8.00033H13.9997V9.33366H11.9997Z",fill:"#999999"},null,-1)])])}const uot=Qe(sot,[["render",lot]]),cot={tooltip:"Font size"},dot={tooltip:"Размер текста"},hot=jn({en:cot,ru:dot}),mot=t=>{const{FontFamily:e,FontSettingsPresets:n,Colors:r}=t.theme,o=!!t.editor.getAttributes("textStyle").fontSize,i=t.editor.getAttributes("paragraph").themeName||"NormalText",s=t.editor.getAttributes("textStyle").themeName||i;return o?parseInt(t.editor.getAttributes("textStyle").fontSize,10):us({fontFamily:e,themeFontSettings:n[s],themeColor:WV({themeName:s,themeFontColors:r})}).fontSize},fot={class:"bootstrap-styles rich-text-toolbar__font-size-editor position-relative rounded-2 py-1 px-3 d-flex"},pot={class:"bootstrap-styles d-flex justify-content-center rich-text-icon me-14"},got=["value"],Cot={class:"bootstrap-styles rich-text-toolbar__input-button top-0 d-flex position-absolute align-items-end justify-content-center"},yot={class:"bootstrap-styles rich-text-toolbar__input-button bottom-0 d-flex position-absolute align-items-start justify-content-center"},bot=Ze({__name:"FontSizeEditor",props:{editor:{},theme:{},deps:{}},setup(t){const e=t,n={tooltip:hot({localeKey:e.deps.localeKey}).tooltip},r=q(()=>mot({editor:e.editor,theme:e.theme})),o=()=>{r.value&&e.editor.commands.setFontSize(r.value+1)},i=()=>{r.value&&r.value!==1&&e.editor.commands.setFontSize(r.value-1)},s=a=>{const l=a.target;let u=parseInt(l.value);const c=100;isNaN(u)||l.value===""?(u=0,l.value="0"):u>c&&(u=c,l.value=String(c)),e.editor.commands.setFontSize(u)};return(a,l)=>It((I(),J("div",fot,[R("i",pot,[ie(uot)]),R("input",{type:"number",class:"bootstrap-styles rich-text-toolbar__input-number rich-text__handler",value:r.value,onInput:s},null,40,got),R("div",Cot,[R("input",{type:"button",class:"bootstrap-styles position-absolute rich-text__handler",onClick:o}),ie(ibe)]),R("div",yot,[R("input",{type:"button",class:"bootstrap-styles position-absolute rich-text__handler",onClick:i}),ie(sbe)])])),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),vot=Qe(bot,[["__scopeId","data-v-ba95f865"]]),Tot=Ze({__name:"SelectItemTextStyle",props:{isActive:{type:Boolean},label:{},themeFontStyle:{},themeFontColor:{}},emits:["click"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("li",{class:Me(["bootstrap-styles dropdown-item p-0 d-flex align-items-center px-3 cursor-pointer",{active:n.isActive}]),onClick:i[0]||(i[0]=s=>r("click"))},[R("i",{class:"bootstrap-styles input__color_selection d-block overflow-hidden me-2",style:he([{background:n.themeFontColor??"linear-gradient(135deg, rgb(51, 132, 255) 0%, rgb(202, 101, 250) 34.37%, rgb(250, 101, 101) 61.98%, rgb(250, 235, 101) 100%)"},{"min-width":"24px"}])},null,4),R("span",{class:"bootstrap-styles d-block py-1 text-decoration-none overflow-hidden",style:he([n.themeFontStyle&&{fontSize:n.themeFontStyle.FontSize+"px",fontWeight:n.themeFontStyle.IsBold?"bold":"normal",fontStyle:n.themeFontStyle.IsItalic?"italic":"normal",textDecoration:n.themeFontStyle.Decoration},{"white-space":"nowrap",overflow:"hidden","text-overflow":"ellipsis"}])},en(n.label),5)],2))}}),Fot=Qe(Tot,[["__scopeId","data-v-3a2ee8e2"]]),xot={tooltip:"Text style",settingLabels:{title:"Title",heading:"Heading",subHeading:"Subheading",largeText:"Large text",normalText:"Text",descriptionText:"Description",link:"Link",button:"Button",custom:"Custom"}},Sot={tooltip:"Стиль текста",settingLabels:{title:"Большой заголовок",heading:"Заголовок",subHeading:"Подзаголовок",largeText:"Большой текст",normalText:"Текст",descriptionText:"Описание",link:"Ссылка",button:"Кнопка",custom:"Пользовательский"}},xee=jn({en:xot,ru:Sot}),wot={class:"bootstrap-styles dropdown"},kot={class:"bootstrap-styles rich-text-toolbar__font-style-selector__text"},Eot={class:"bootstrap-styles d-flex justify-content-center align-items-center rich-text-toolbar__icon"},Rot=Ze({__name:"ThemeSettingsSelector",props:{editor:{},theme:{},isAllowToEdit:{type:Boolean},initialThemeName:{},deps:{}},setup(t){const e=t,n=RV.name,r=Mt({isOpened:!1}),o={tooltip:xee({localeKey:e.deps.localeKey}).tooltip,settingLabels:xee({localeKey:e.deps.localeKey}).settingLabels},i={Title:o.settingLabels.title,Heading:o.settingLabels.heading,SubHeading:o.settingLabels.subHeading,LargeText:o.settingLabels.largeText,NormalText:o.settingLabels.normalText,DescriptionText:o.settingLabels.descriptionText,Link:o.settingLabels.link,Button:o.settingLabels.button,Custom:o.settingLabels.custom},s=["Title","Heading","SubHeading","LargeText","NormalText","DescriptionText","Link","Button"],a=["TitleColor","HeadingColor","SubHeadingColor","LargeTextColor","NormalTextColor","DescriptionTextColor","LinkColor","ButtonTextColor"],l=q(()=>{const c=e.initialThemeName,d=e.editor.getAttributes("paragraph").themeName||c;let h=s.find(F=>e.editor.getAttributes(n).themeName===F)||d;const{fontWeight:m,fontStyle:f,textDecoration:p,fontSize:g,fontFamily:y,lineHeight:b}=e.editor.getAttributes(n);return m||f||p||g||y||b?i.Custom:i[h]}),u=c=>{e.editor.commands.unsetMark(n),e.editor.chain().focus().setThemeSettings(c).run(),r.isOpened=!1};return(c,d)=>It((I(),J("div",wot,[R("button",{id:"dropdownMenuButtonFontStyleList",class:Me(["bootstrap-styles rich-text-toolbar__font-style-selector d-flex justify-content-between align-items-center py-1 px-3 text-nowrap border rounded-2",{disabled:!e.isAllowToEdit,show:r.isOpened}]),type:"button",onClick:d[0]||(d[0]=()=>r.isOpened=!r.isOpened)},[R("span",kot,en(l.value),1),R("i",Eot,[ie(obe)])],2),R("ul",{class:Me([{show:r.isOpened},"bootstrap-styles rich-text-toolbar__font-style-dropdown dropdown-menu rounded-2"]),"aria-labelledby":"dropdownMenuButtonFontStyleList"},[(I(),J(ot,null,zn(s,(h,m)=>ie(Fot,{key:h,isActive:e.editor.getAttributes(z(n)).themeName===h,label:i[h],themeFontStyle:e.theme.FontSettingsPresets[h],themeFontColor:e.theme.Colors[a[m]],onClick:()=>u(h)},null,8,["isActive","label","themeFontStyle","themeFontColor","onClick"])),64))],2)])),[[z(Sd),()=>r.isOpened=!1],[z(Br),{title:o.tooltip,placement:"top"}]])}}),_ot=Qe(Rot,[["__scopeId","data-v-37cbbac2"]]),Dot={},Aot={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function $ot(t,e){return I(),J("svg",Aot,[...e[0]||(e[0]=[R("path",{d:"M7.33317 2.66667H13.9998V4H7.33317V2.66667ZM3.99984 4.66667V7.33333H2.6665V4.66667H0.666504L3.33317 2L5.99984 4.66667H3.99984ZM3.99984 11.3333H5.99984L3.33317 14L0.666504 11.3333H2.6665V8.66667H3.99984V11.3333ZM7.33317 12H13.9998V13.3333H7.33317V12ZM5.99984 7.33333H13.9998V8.66667H5.99984V7.33333Z",fill:"var(--gray-500)"},null,-1)])])}const Not=Qe(Dot,[["render",$ot]]),Bot={tooltip:"Line height"},Lot={tooltip:"Высота строки"},Vot=jn({en:Bot,ru:Lot}),Mot=t=>{const{FontFamily:e,FontSettingsPresets:n,Colors:r}=t.theme,o=!!t.editor.getAttributes("textStyle").lineHeight,i=t.editor.getAttributes("paragraph").themeName||"NormalText",s=t.editor.getAttributes("textStyle").themeName||i;return o?parseInt(t.editor.getAttributes("textStyle").lineHeight,10):us({fontFamily:e,themeFontSettings:n[s],themeColor:WV({themeName:s,themeFontColors:r})}).lineHeight},Oot={class:"bootstrap-styles rich-text-toolbar__line-height-editor position-relative rounded-2 py-1 px-3 d-flex"},Iot={class:"bootstrap-styles d-flex justify-content-center rich-text-icon me-14"},Pot=["value"],Wot={class:"bootstrap-styles rich-text-toolbar__input-button d-flex position-absolute align-items-end justify-content-center",style:{right:"10px",top:"0",width:"16px",height:"16px"}},Hot={class:"bootstrap-styles rich-text-toolbar__input-button d-flex position-absolute align-items-start justify-content-center",style:{right:"10px",bottom:"0",width:"16px",height:"16px"}},zot=Ze({__name:"LineHeightEditor",props:{editor:{},theme:{},deps:{}},setup(t){const e=t,n={tooltip:Vot({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Mot({editor:e.editor,theme:e.theme})),o=()=>{r.value&&e.editor.commands.setLineHeight(r.value+1)},i=()=>{r.value&&r.value!==1&&e.editor.commands.setLineHeight(r.value-1)},s=a=>{const l=a.target;let u=parseInt(l.value);const c=100;isNaN(u)||l.value===""?(u=0,l.value="0"):u>c&&(u=c,l.value=String(c)),e.editor.commands.setLineHeight(u)};return(a,l)=>It((I(),J("div",Oot,[R("i",Iot,[ie(Not)]),R("input",{type:"number",class:"bootstrap-styles rich-text-toolbar__input-number rich-text__handler",value:r.value,onInput:s},null,40,Pot),R("div",Wot,[R("input",{type:"button",class:"bootstrap-styles position-absolute rich-text__handler",onClick:o}),ie(ibe)]),R("div",Hot,[R("input",{type:"button",class:"bootstrap-styles position-absolute rich-text__handler",onClick:i}),ie(sbe)])])),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),jot=Qe(zot,[["__scopeId","data-v-4e76ed1b"]]),Uot=["http:","https:","mailto:","tel:"],Kot={mounted(t,e){t.addEventListener("input",()=>{const n=t.value;let r=!1;try{const o=new URL(n);r=Uot.includes(o.protocol)}catch{r=!1}typeof e.value=="function"&&e.value(r)})}},abe={mounted(t,e){See(t,e)},updated(t,e){e.value&&See(t,e)}},See=(t,e)=>{document.activeElement!==t&&requestAnimationFrame(()=>{if(t.focus(),e.modifiers.selectAll&&t.select(),e.modifiers.end){const n=t.value.length;t.setSelectionRange(n,n)}})},qot={},Jot={xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none"};function Got(t,e){return I(),J("svg",Jot,[...e[0]||(e[0]=[R("path",{d:"M11.2432 9.35654L10.3003 8.41374L11.2432 7.47094C12.5449 6.16921 12.5449 4.05865 11.2432 2.75691C9.94139 1.45516 7.83086 1.45516 6.52912 2.75691L5.58631 3.69972L4.6435 2.75691L5.58631 1.8141C7.40879 -0.00834608 10.3635 -0.00834608 12.186 1.8141C14.0084 3.63655 14.0084 6.59134 12.186 8.41374L11.2432 9.35654ZM9.35752 11.2422L8.41472 12.185C6.59232 14.0075 3.63752 14.0075 1.81508 12.185C-0.00736952 10.3625 -0.00736952 7.40781 1.81508 5.58533L2.75788 4.64253L3.70069 5.58533L2.75788 6.52814C1.45614 7.82987 1.45614 9.94047 2.75788 11.2422C4.05963 12.5439 6.17019 12.5439 7.47192 11.2422L8.41472 10.2994L9.35752 11.2422ZM8.88612 4.17112L9.82893 5.11393L5.1149 9.82801L4.1721 8.88514L8.88612 4.17112Z",fill:"var(--black)"},null,-1)])])}const lbe=Qe(qot,[["render",Got]]),Yot={label:"Link",inputPlaceholder:"https://example.com",errorNotification:"The link must contain https://, http://, mailto:, tel:",applyButton:"Save",cancelButton:"Cancel"},Xot={label:"Ссылка",inputPlaceholder:"https://example.com",errorNotification:"Ссылка должна содержать https://, http://, mailto:, tel:",applyButton:"Сохранить",cancelButton:"Отмена"},n1=jn({en:Yot,ru:Xot}),Qot={},Zot={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function eit(t,e){return I(),J("svg",Zot,[...e[0]||(e[0]=[R("path",{d:"M11.333 3.99967H14.6663V5.33301H13.333V13.9997C13.333 14.3679 13.0345 14.6663 12.6663 14.6663H3.33301C2.96482 14.6663 2.66634 14.3679 2.66634 13.9997V5.33301H1.33301V3.99967H4.66634V1.99967C4.66634 1.63149 4.96482 1.33301 5.33301 1.33301H10.6663C11.0345 1.33301 11.333 1.63149 11.333 1.99967V3.99967ZM11.9997 5.33301H3.99967V13.333H11.9997V5.33301ZM5.99967 7.33301H7.33301V11.333H5.99967V7.33301ZM8.66634 7.33301H9.99967V11.333H8.66634V7.33301ZM5.99967 2.66634V3.99967H9.99967V2.66634H5.99967Z",fill:"white"},null,-1)])])}const ube=Qe(Qot,[["render",eit]]),tit={class:"bootstrap-styles bg-white border rounded-2 add-text-link-modal-window"},nit={class:"bootstrap-styles fw-bold mb-5 px-11 mt-10 d-block text-start"},rit={class:"bootstrap-styles px-11 mb-2"},oit={class:"bootstrap-styles d-flex justify-content-center align-items-center me-1"},iit=["placeholder","value"],sit={class:"bootstrap-styles px-11 py-5 d-flex align-items-center justify-content-end border-top"},ait=["disabled"],lit=Ze({__name:"AddLinkModalWindow",props:{isActive:{type:Boolean},currentHref:{},deps:{}},emits:["onClosed","onHrefChanged","onRemoved"],setup(t,{emit:e}){const n=t,r=Mt({href:n.currentHref,isValid:!0}),o=a=>{r.href=a,r.isValid=a.length>0},i={label:n1({localeKey:n.deps.localeKey}).label,inputPlaceholder:n1({localeKey:n.deps.localeKey}).inputPlaceholder,errorNotification:n1({localeKey:n.deps.localeKey}).errorNotification,applyButton:n1({localeKey:n.deps.localeKey}).applyButton,cancelButton:n1({localeKey:n.deps.localeKey}).cancelButton},s=e;return(a,l)=>It((I(),J("div",tit,[R("label",nit,en(i.label),1),R("div",rit,[R("div",{class:Me(["bootstrap-styles bg-color-input border rounded-2 py-1 px-3 d-flex mb-14",{"border-danger":!r.isValid}])},[R("i",oit,[ie(lbe)]),It(R("input",{type:"text",class:"bootstrap-styles w-100",placeholder:i.inputPlaceholder,value:r.href,onInput:l[0]||(l[0]=u=>o(u.target.value))},null,40,iit),[[z(Kot),u=>r.isValid=u],[z(abe),void 0,void 0,{selectAll:!0}]])],2),R("div",{class:Me(["bootstrap-styles text-start add-link-modal-window-notification",{invisible:r.isValid}])},en(i.errorNotification),3)]),R("div",sit,[n.isActive?(I(),J("button",{key:0,class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-auto rounded-2 add-text-link-modal-window__remove-button",onClick:l[1]||(l[1]=wr(()=>s("onRemoved"),["stop"]))},[R("i",null,[ie(ube)])])):Ue("",!0),R("button",{class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-3 border border-blue-selected rounded-2 bg-blue-selected button__hover-blue-100 text-color-selected",onClick:l[2]||(l[2]=()=>s("onClosed"))},en(i.cancelButton),1),R("button",{class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 border rounded-2 bg-color-selected text-white cursor-pointer",disabled:!r.href.length||!r.isValid,onClick:l[3]||(l[3]=()=>s("onHrefChanged",r.href))},en(i.applyButton),9,ait)])])),[[z(Sd),()=>s("onClosed")]])}}),uit=Qe(lit,[["__scopeId","data-v-dd4e68e8"]]),cit={};function dit(t,e){return I(),J(ot,null,[e[0]||(e[0]=R("svg",{class:"unlinked",xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"},[R("path",{d:"M12.7432 10.3565L11.8003 9.41374L12.7432 8.47094C14.0449 7.16921 14.0449 5.05865 12.7432 3.75691C11.4414 2.45516 9.33086 2.45516 8.02912 3.75691L7.08631 4.69972L6.1435 3.75691L7.08631 2.8141C8.90879 0.991654 11.8635 0.991654 13.686 2.8141C15.5084 4.63655 15.5084 7.59134 13.686 9.41374L12.7432 10.3565ZM10.8575 12.2422L9.91472 13.185C8.09232 15.0075 5.13752 15.0075 3.31508 13.185C1.49263 11.3625 1.49263 8.40781 3.31508 6.58533L4.25788 5.64253L5.20069 6.58533L4.25788 7.52814C2.95614 8.82987 2.95614 10.9405 4.25788 12.2422C5.55963 13.5439 7.67019 13.5439 8.97192 12.2422L9.91472 11.2994L10.8575 12.2422ZM10.3861 5.17112L11.3289 6.11393L6.6149 10.828L5.6721 9.88514L10.3861 5.17112Z",fill:"black"})],-1)),e[1]||(e[1]=R("svg",{class:"linked",xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[R("path",{d:"M11.7713 9.88573L10.8285 8.94287L11.7713 8.00007C12.8127 6.95867 12.8127 5.27025 11.7713 4.22885C10.7299 3.18745 9.04147 3.18745 8.00007 4.22885L7.05727 5.17166L6.11447 4.22885L7.05727 3.28605C8.6194 1.72395 11.1521 1.72395 12.7141 3.28605C14.2762 4.84814 14.2762 7.3808 12.7141 8.94287L11.7713 9.88573ZM9.88573 11.7713L8.94287 12.7141C7.3808 14.2762 4.84814 14.2762 3.28605 12.7141C1.72395 11.1521 1.72395 8.6194 3.28605 7.05727L4.22885 6.11447L5.17166 7.05727L4.22885 8.00007C3.18745 9.04147 3.18745 10.7299 4.22885 11.7713C5.27025 12.8127 6.95867 12.8127 8.00007 11.7713L8.94287 10.8285L9.88573 11.7713ZM9.88573 5.17166L10.8285 6.11447L6.11447 10.8285L5.17166 9.88573L9.88573 5.17166ZM3.85026 1.52869L5.13816 1.18359L5.82835 3.75939L4.54045 4.10449L3.85026 1.52869ZM10.1719 12.2408L11.4597 11.8957L12.1499 14.4715L10.862 14.8166L10.1719 12.2408ZM1.52869 3.85026L4.10449 4.54045L3.75939 5.82835L1.18359 5.13816L1.52869 3.85026ZM12.2408 10.1719L14.8166 10.862L14.4715 12.1499L11.8957 11.4597L12.2408 10.1719Z",fill:"black"})],-1))],64)}const hit=Qe(cit,[["render",dit],["__scopeId","data-v-730bc16f"]]),mit={tooltip:"Link"},fit={tooltip:"Ссылка"},pit=jn({en:mit,ru:fit}),git={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Cit=Ze({__name:"LinkEditor",props:{editor:{},isAllowToEdit:{type:Boolean},deps:{}},setup(t){const e=t,n={tooltip:pit({localeKey:e.deps.localeKey}).tooltip},r=c7.name,o=U7.name,i=Mt({isAddTextLinkModalWindowShown:!1}),s=q(()=>e.editor.isActive(o)),a=u=>{s.value&&e.editor.commands.unsetUnsubscribeLink(),e.editor.chain().focus().setLink({href:u}).setThemeSettings("Link").run(),i.isAddTextLinkModalWindowShown=!1},l=()=>{e.editor.chain().focus().unsetLink().applySiblingNodeThemeSettings().run(),i.isAddTextLinkModalWindowShown=!1};return(u,c)=>(I(),J(ot,null,[It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive(z(r)),disabled:!e.editor.isActive(z(r))&&!e.isAllowToEdit}]),onClick:c[0]||(c[0]=d=>{i.isAddTextLinkModalWindowShown=!i.isAddTextLinkModalWindowShown})},[R("i",git,[e.editor.isActive(z(r))?(I(),et(hit,{key:1})):(I(),et(lbe,{key:0}))])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]]),i.isAddTextLinkModalWindowShown?(I(),et(uit,{key:0,isActive:e.editor.isActive(z(r)),currentHref:e.editor.isActive(z(r))?e.editor.getAttributes(z(r)).href:"",deps:e.deps.addLinkModalWindowDeps,onOnRemoved:c[1]||(c[1]=()=>l()),onOnClosed:c[2]||(c[2]=d=>i.isAddTextLinkModalWindowShown=!1),onOnHrefChanged:c[3]||(c[3]=d=>a(d))},null,8,["isActive","currentHref","deps"])):Ue("",!0)],64))}}),yit=Qe(Cit,[["__scopeId","data-v-6460a995"]]),bit={label:"URL",placeholder:"URL...",cancel:"Cancel",apply:"Save",removeTooltip:"Delete image"},vit={label:"URL",placeholder:"URL...",cancel:"Отмена",apply:"Сохранить",removeTooltip:"Удалить изображение"},r1=jn({en:bit,ru:vit}),Tit={class:"bootstrap-styles bg-white border rounded-2 add-image-src-modal-window"},Fit={class:"bootstrap-styles fw-bold mb-5 px-11 mt-10 d-block text-start"},xit={class:"bootstrap-styles px-11 mb-11"},Sit=["placeholder","value"],wit={class:"bootstrap-styles px-11 py-5 d-flex align-items-center justify-content-end border-top"},kit=["disabled"],Eit=Ze({__name:"AddImageSrcModalWindow",props:{isActive:{type:Boolean},src:{},width:{},height:{},isRetina:{type:Boolean},deps:{}},emits:["onClosed","onRemoved","onImageSrcChanged"],setup(t,{emit:e}){const n=t,r=Mt({src:n.src,width:n.width,height:n.height,isBroken:!1}),o={label:r1({localeKey:n.deps.localeKey}).label,placeholder:r1({localeKey:n.deps.localeKey}).placeholder,cancel:r1({localeKey:n.deps.localeKey}).cancel,apply:r1({localeKey:n.deps.localeKey}).apply,removeTooltip:r1({localeKey:n.deps.localeKey}).removeTooltip},i=upe(l=>{ebe(l).then(u=>{r.width=u.width,r.height=u.height,r.isBroken=!1,r.src=l}).catch(()=>{r.src=l,r.isBroken=!0})},500),s=()=>{a("onImageSrcChanged",{src:r.src,width:r.width,height:r.height,isRetina:!1})},a=e;return(l,u)=>It((I(),J("div",Tit,[R("label",Fit,en(o.label),1),R("div",xit,[R("div",{class:Me(["bootstrap-styles bg-color-input border rounded-2 py-1 px-3 d-flex",{"border-danger":r.isBroken}])},[It(R("input",{type:"text",class:"bootstrap-styles w-100",placeholder:o.placeholder,value:r.src,onInput:u[0]||(u[0]=c=>z(i)(c.target.value))},null,40,Sit),[[z(abe),void 0,void 0,{selectAll:!0}]])],2)]),R("div",wit,[n.isActive?It((I(),J("button",{key:0,class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-auto rounded-2 add-image-src-modal-window__remove-button",onClick:u[1]||(u[1]=wr(()=>a("onRemoved"),["stop"]))},[R("i",null,[ie(ube)])])),[[z(Br),{placement:"top",title:o.removeTooltip}]]):Ue("",!0),R("button",{class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-3 border border-blue-selected rounded-2 bg-blue-selected button__hover-blue-100 text-color-selected",onClick:u[2]||(u[2]=wr(()=>a("onClosed"),["stop"]))},en(o.cancel),1),R("button",{class:"bootstrap-styles d-flex justify-content-center align-center py-1 px-3 border rounded-2 bg-color-selected text-white cursor-pointer",disabled:!r.src.length||r.isBroken,onClick:u[3]||(u[3]=wr(()=>s(),["stop"]))},en(o.apply),9,kit)])])),[[z(Sd),()=>a("onClosed")]])}}),Rit=Qe(Eit,[["__scopeId","data-v-35966ae0"]]),_it={},Dit={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Ait(t,e){return I(),J("svg",Dit,[...e[0]||(e[0]=[R("path",{d:"M1.99453 14C1.62936 14 1.33333 13.7034 1.33333 13.3377V2.66227C1.33333 2.29651 1.63687 2 1.99453 2H14.0055C14.3707 2 14.6667 2.29663 14.6667 2.66227V13.3377C14.6667 13.7035 14.3631 14 14.0055 14H1.99453ZM13.3333 10V3.33333H2.66666V12.6667L9.33333 6L13.3333 10ZM13.3333 11.8856L9.33333 7.8856L4.55228 12.6667H13.3333V11.8856ZM5.33333 7.33333C4.59695 7.33333 3.99999 6.7364 3.99999 6C3.99999 5.26362 4.59695 4.66667 5.33333 4.66667C6.06971 4.66667 6.66666 5.26362 6.66666 6C6.66666 6.7364 6.06971 7.33333 5.33333 7.33333Z",fill:"#2F2F2F"},null,-1)])])}const $it=Qe(_it,[["render",Ait]]),Nit={tooltip:"Image",retinaLabel:"For retina screens"},Bit={tooltip:"Изображение",retinaLabel:"Для retina-экранов"},wee=jn({en:Nit,ru:Bit}),Lit=["checked"],Vit=Ze({__name:"Checkbox",props:{checked:{type:Boolean}},emits:["change"],setup(t,{emit:e}){const n=t,r=e;return(o,i)=>(I(),J("input",{class:"bootstrap-styles me-1 cursor-pointer",checked:n.checked,type:"checkbox","aria-label":"Checkbox for following text input",onChange:i[0]||(i[0]=s=>r("change"))},null,40,Lit))}}),Mit=Qe(Vit,[["__scopeId","data-v-6a8c2252"]]),Oit={class:"bootstrap-styles rich-text-icon icon-hover d-flex"},Iit={key:0,class:"bootstrap-styles d-flex align-items-center ms-14 me-1"},Pit={for:"rich-text__retina-checkbox",class:"bootstrap-styles label__checkbox-input text-nowrap"},Wit=Ze({__name:"ImageEditor",props:{editor:{},deps:{}},setup(t){const e=t,n={tooltip:wee({localeKey:e.deps.localeKey}).tooltip,retinaLabel:wee({localeKey:e.deps.localeKey}).retinaLabel},r=tbe.name,o=Mt({isAddImageSrcModalWindowShown:!1}),i=async()=>{const l=e.editor.view.state.selection.anchor,{src:u,width:c,height:d,isRetina:h}=e.editor.getAttributes(r);e.editor.chain().focus().updateAttributes("image",{src:u,width:c,height:d,isRetina:!h}).setNodeSelection(l).run()},s=l=>{const u=e.editor.view.state.selection.anchor;e.editor.isActive(r)?e.editor.chain().focus().updateAttributes("image",{src:l.src,width:l.width,height:l.height,alt:"img",isRetina:!1}).setNodeSelection(u).run():e.editor.chain().focus().setImage({src:l.src,width:l.width,height:l.height,alt:"img",isRetina:!1}).setNodeSelection(u).run(),o.isAddImageSrcModalWindowShown=!1},a=()=>{e.editor.commands.deleteSelection(),o.isAddImageSrcModalWindowShown=!1};return(l,u)=>(I(),J(ot,null,[It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button__image",{active:e.editor.isActive(z(r))}]),onClick:u[0]||(u[0]=c=>o.isAddImageSrcModalWindowShown=!o.isAddImageSrcModalWindowShown)},[R("i",Oit,[ie($it)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]]),e.editor.isActive(z(r))?(I(),J("div",Iit,[ie(Mit,{id:"rich-text__retina-checkbox",checked:e.editor.isActive(z(r),{isRetina:!0}),onChange:u[1]||(u[1]=()=>i())},null,8,["checked"]),R("label",Pit,en(n.retinaLabel),1)])):Ue("",!0),o.isAddImageSrcModalWindowShown?(I(),et(Rit,{key:1,isActive:e.editor.isActive(z(r)),src:e.editor.getAttributes(z(r)).src?e.editor.getAttributes(z(r)).src:"",width:e.editor.getAttributes(z(r)).width?e.editor.getAttributes(z(r)).width:0,height:e.editor.getAttributes(z(r)).height?e.editor.getAttributes(z(r)).height:0,isRetina:e.editor.getAttributes(z(r)).isRetina?e.editor.getAttributes(z(r)).isRetina:!1,deps:e.deps.addImageSrcModalWindowDeps,onOnRemoved:u[2]||(u[2]=()=>a()),onOnClosed:u[3]||(u[3]=c=>o.isAddImageSrcModalWindowShown=!1),onOnImageSrcChanged:u[4]||(u[4]=c=>s({src:c.src,width:c.width,height:c.height}))},null,8,["isActive","src","width","height","isRetina","deps"])):Ue("",!0)],64))}}),Hit=Qe(Wit,[["__scopeId","data-v-cf315655"]]),zit={},jit={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function Uit(t,e){return I(),J("svg",jit,[...e[0]||(e[0]=[R("path",{d:"M5.83333 7.33317H8.83333C9.7538 7.33317 10.5 6.58698 10.5 5.6665C10.5 4.74603 9.7538 3.99984 8.83333 3.99984H5.83333V7.33317ZM12.5 10.3332C12.5 11.99 11.1569 13.3332 9.5 13.3332H4.5V2.6665H8.83333C10.4902 2.6665 11.8333 4.00965 11.8333 5.6665C11.8333 6.46938 11.5179 7.19857 11.0043 7.73704C11.8986 8.2563 12.5 9.2245 12.5 10.3332ZM5.83333 8.6665V11.9998H9.5C10.4205 11.9998 11.1667 11.2536 11.1667 10.3332C11.1667 9.4127 10.4205 8.6665 9.5 8.6665H5.83333Z",fill:"var(--black)"},null,-1)])])}const Kit=Qe(zit,[["render",Uit]]),qit={tooltip:"Bold"},Jit={tooltip:"Полужирный"},Git=jn({en:qit,ru:Jit}),Yit={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Xit=Ze({__name:"FontWeightEditor",props:{editor:{},theme:{},isAllowToEdit:{type:Boolean},deps:{}},setup(t){const e=t,n={tooltip:Git({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"fontWeight"})==="bold"),o=()=>{r.value?e.editor.chain().focus().unsetFontWeight().run():e.editor.chain().focus().setFontWeight("bold").run(),e.editor.commands.focus()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:r.value,disabled:!e.isAllowToEdit&&!r.value}]),onClick:s[0]||(s[0]=()=>o())},[R("i",Yit,[ie(Kit)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),Qit=Qe(Xit,[["__scopeId","data-v-0e22dbf6"]]),Zit={},est={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function tst(t,e){return I(),J("svg",est,[...e[0]||(e[0]=[R("path",{d:"M11.9359 9.33317C12.0897 9.67724 12.1667 10.0594 12.1667 10.4796C12.1667 11.3748 11.8175 12.0742 11.1191 12.5778C10.4206 13.0814 9.45567 13.3332 8.22413 13.3332C7.13116 13.3332 6.0489 13.0788 4.97728 12.5702V11.0671C5.99025 11.652 7.0272 11.9445 8.08813 11.9445C9.78887 11.9445 10.6419 11.4562 10.6472 10.4796C10.6472 10.0624 10.5033 9.70637 10.2154 9.41137C10.1893 9.38464 10.1626 9.35857 10.1354 9.33317H2.5V7.99984H14.5V9.33317H11.9359ZM9.21733 7.33317H5.58605C5.47107 7.2287 5.36411 7.11264 5.26517 6.98504C4.97728 6.61373 4.83333 6.16356 4.83333 5.63455C4.83333 4.81052 5.14389 4.10984 5.76499 3.5325C6.38611 2.95516 7.34707 2.6665 8.64793 2.6665C9.62893 2.6665 10.5673 2.88522 11.4629 3.32268V4.75711C10.6632 4.29931 9.7862 4.07042 8.83187 4.07042C7.17913 4.07042 6.35278 4.59179 6.35278 5.63455C6.35278 5.91432 6.49806 6.15848 6.78862 6.36703C7.07919 6.57558 7.43773 6.74217 7.8642 6.86677C8.27767 6.98757 8.72873 7.14304 9.21733 7.33317Z",fill:"black"},null,-1)])])}const nst=Qe(Zit,[["render",tst]]),rst={tooltip:"Strikethrough"},ost={tooltip:"Зачеркнутый"},ist=jn({en:rst,ru:ost}),sst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},ast=Ze({__name:"LineThroughEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:ist({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"textDecoration"})==="line-through"),o=()=>{r.value?e.editor.chain().focus().unsetTextDecoration().run():e.editor.chain().focus().setTextDecoration("line-through").run(),e.editor.commands.focus()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:r.value,disabled:!t.isAllowToEdit&&!r.value}]),onClick:s[0]||(s[0]=a=>o())},[R("i",sst,[ie(nst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),lst=Qe(ast,[["__scopeId","data-v-fffc32ef"]]),ust={},cst={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function dst(t,e){return I(),J("svg",cst,[...e[0]||(e[0]=[R("path",{d:"M5.83366 2V8C5.83366 9.47273 7.02757 10.6667 8.50033 10.6667C9.97306 10.6667 11.167 9.47273 11.167 8V2H12.5003V8C12.5003 10.2091 10.7095 12 8.50033 12C6.29119 12 4.50033 10.2091 4.50033 8V2H5.83366ZM3.16699 13.3333H13.8337V14.6667H3.16699V13.3333Z",fill:"black"},null,-1)])])}const hst=Qe(ust,[["render",dst]]),mst={tooltip:"Underline"},fst={tooltip:"Подчеркнутый"},pst=jn({en:mst,ru:fst}),gst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Cst=Ze({__name:"UnderlineEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:pst({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"textDecoration"})==="underline"),o=()=>{r.value?e.editor.chain().focus().unsetTextDecoration().run():e.editor.chain().focus().setTextDecoration("underline").run()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:r.value,disabled:!t.isAllowToEdit&&!r.value}]),onClick:s[0]||(s[0]=()=>o())},[R("i",gst,[ie(hst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),yst=Qe(Cst,[["__scopeId","data-v-ae63be68"]]),bst={},vst={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function Tst(t,e){return I(),J("svg",vst,[...e[0]||(e[0]=[R("path",{d:"M10.4998 13.3332H5.1665V11.9998H7.11758L8.52817 3.99984H6.49984V2.6665H11.8332V3.99984H9.8821L8.4715 11.9998H10.4998V13.3332Z",fill:"black"},null,-1)])])}const Fst=Qe(bst,[["render",Tst]]),xst={tooltip:"Italic"},Sst={tooltip:"Курсив"},wst=jn({en:xst,ru:Sst}),kst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Est=Ze({__name:"FontStyleEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:wst({localeKey:e.deps.localeKey}).tooltip},r=q(()=>Tw({editor:e.editor,theme:e.theme,styleName:"fontStyle"})==="italic"),o=()=>{r.value?e.editor.chain().focus().unsetFontStyle().run():e.editor.chain().focus().setFontStyle("italic").run(),e.editor.commands.focus()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:r.value,disabled:!t.isAllowToEdit&&!r.value}]),onClick:s[0]||(s[0]=()=>o())},[R("i",kst,[ie(Fst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),Rst=Qe(Est,[["__scopeId","data-v-ac6b2276"]]),_st={},Dst={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Ast(t,e){return I(),J("svg",Dst,[...e[0]||(e[0]=[R("path",{d:"M7.49699 9.99999H3.16912L1.83578 13.3333H0.399734L4.6664 2.66666H5.99973L10.2664 13.3333H8.83033L7.49699 9.99999ZM6.96366 8.66666L5.33307 4.5901L3.70245 8.66666H6.96366ZM13.9997 8.35672V7.99999H15.3331V13.3333H13.9997V12.9766C13.6075 13.2035 13.1521 13.3333 12.6664 13.3333C11.1937 13.3333 9.99973 12.1394 9.99973 10.6667C9.99973 9.19392 11.1937 7.99999 12.6664 7.99999C13.1521 7.99999 13.6075 8.12986 13.9997 8.35672ZM12.6664 12C13.4028 12 13.9997 11.4031 13.9997 10.6667C13.9997 9.93026 13.4028 9.33332 12.6664 9.33332C11.93 9.33332 11.3331 9.93026 11.3331 10.6667C11.3331 11.4031 11.93 12 12.6664 12Z",fill:"black"},null,-1)])])}const $st=Qe(_st,[["render",Ast]]),Nst={tooltip:"Uppercase"},Bst={tooltip:"Заглавные"},Lst=jn({en:Nst,ru:Bst}),Vst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},Mst=Ze({__name:"TextTransformEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:Lst({localeKey:e.deps.localeKey}).tooltip},r=J0e.name,o=q(()=>e.editor.isActive({[r]:"uppercase"})),i=()=>{o.value?e.editor.commands.unsetTextTransform():e.editor.commands.setTextTransform("uppercase"),e.editor.commands.focus()};return(s,a)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive({[z(r)]:"uppercase"}),disabled:!t.isAllowToEdit&&!e.editor.isActive({[z(r)]:"uppercase"})}]),onClick:a[0]||(a[0]=l=>i())},[R("i",Vst,[ie($st)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),Ost=Qe(Mst,[["__scopeId","data-v-20dea8b8"]]),Ist={},Pst={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Wst(t,e){return I(),J("svg",Pst,[...e[0]||(e[0]=[R("path",{d:"M12.2432 8.47094C13.5449 7.16921 13.5449 5.05865 12.2432 3.75691C10.9414 2.45516 8.83086 2.45516 7.52912 3.75691L6.58631 4.69972L5.6435 3.75691L6.58631 2.8141C8.40879 0.991654 11.3635 0.991654 13.186 2.8141C15.0084 4.63655 15.0084 7.59134 13.186 9.41374L12.2432 8.47094ZM9.41472 13.185C7.59232 15.0075 4.63752 15.0075 2.81508 13.185C0.99263 11.3625 0.99263 8.40781 2.81508 6.58533L3.75788 5.64253L4.70069 6.58533L3.75788 7.52814C2.45614 8.82987 2.45614 10.9405 3.75788 12.2422C5.05963 13.5439 7.17019 13.5439 8.47192 12.2422L9.41472 13.185ZM9.88612 5.17112L10.8289 6.11393L6.1149 10.828L5.1721 9.88514L9.88612 5.17112Z",fill:"#2F2F2F"},null,-1),R("path",{d:"M14.714 13.7712L13.2998 12.357L14.714 10.9428L13.7712 10L12.357 11.4142L10.9428 10L10 10.9428L11.4142 12.357L10 13.7712L10.9428 14.714L12.357 13.2998L13.7712 14.714L14.714 13.7712Z",fill:"#2F2F2F"},null,-1)])])}const Hst=Qe(Ist,[["render",Wst]]),zst={tooltip:"Unsubscribe link"},jst={tooltip:"Ссылка на отписку"},Ust=jn({en:zst,ru:jst}),Kst={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},qst=Ze({__name:"UnsubscribeLinkEditor",props:{editor:{},isAllowToEdit:{type:Boolean},theme:{},deps:{}},setup(t){const e=t,n={tooltip:Ust({localeKey:e.deps.localeKey}).tooltip},r=U7.name,o=c7.name,i=q(()=>e.editor.isActive(o)),s=()=>{i.value&&e.editor.commands.unsetLink(),e.editor.isActive(r)?e.editor.chain().unsetUnsubscribeLink().applySiblingNodeThemeSettings().run():e.editor.chain().setUnsubscribeLink().setThemeSettings("Link").run()};return(a,l)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive(z(r)),disabled:!e.editor.isActive(z(r))&&!e.isAllowToEdit}]),onClick:l[0]||(l[0]=()=>s())},[R("i",Kst,[ie(Hst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),Jst=Qe(qst,[["__scopeId","data-v-9ee287d3"]]),Gst={},Yst={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function Xst(t,e){return I(),J("svg",Yst,[...e[0]||(e[0]=[R("path",{d:"M6.16699 4.66667C6.16699 3.93029 5.57004 3.33333 4.83366 3.33333C4.09728 3.33333 3.50033 3.93029 3.50033 4.66667C3.50033 5.40305 4.09728 6 4.83366 6C5.57004 6 6.16699 5.40305 6.16699 4.66667ZM7.50033 4.66667C7.50033 6.13943 6.30642 7.33333 4.83366 7.33333C3.3609 7.33333 2.16699 6.13943 2.16699 4.66667C2.16699 3.19391 3.3609 2 4.83366 2C6.30642 2 7.50033 3.19391 7.50033 4.66667ZM14.5003 2.66667H9.16699V4H14.5003V2.66667ZM14.5003 7.33333H9.16699V8.66667H14.5003V7.33333ZM14.5003 12H9.16699V13.3333H14.5003V12ZM4.83366 12.6667C4.09728 12.6667 3.50033 12.0697 3.50033 11.3333C3.50033 10.5969 4.09728 10 4.83366 10C5.57004 10 6.16699 10.5969 6.16699 11.3333C6.16699 12.0697 5.57004 12.6667 4.83366 12.6667ZM4.83366 14C6.30642 14 7.50033 12.8061 7.50033 11.3333C7.50033 9.8606 6.30642 8.66667 4.83366 8.66667C3.3609 8.66667 2.16699 9.8606 2.16699 11.3333C2.16699 12.8061 3.3609 14 4.83366 14Z",fill:"black"},null,-1)])])}const Qst=Qe(Gst,[["render",Xst]]),Zst={tooltip:"Bullet list"},eat={tooltip:"Маркированный список"},tat=jn({en:Zst,ru:eat}),nat={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},rat=Ze({__name:"BulletListEditor",props:{editor:{},deps:{}},setup(t){const e=t,n={tooltip:tat({localeKey:e.deps.localeKey}).tooltip},r=d7.name,o=()=>{e.editor.chain().focus().toggleBulletList().run()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive(z(r))}]),onClick:s[0]||(s[0]=()=>o())},[R("i",nat,[ie(Qst)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),oat=Qe(rat,[["__scopeId","data-v-c64632e3"]]),iat={},sat={xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"};function aat(t,e){return I(),J("svg",sat,[...e[0]||(e[0]=[R("path",{d:"M4.33382 2.33301H3.64521L2.66699 2.59512V3.63022L3.33367 3.45155L3.33378 5.66634H2.50033V6.66634H5.16699V5.66634H4.33382V2.33301ZM7.16699 2.66634H14.5003V3.99967H7.16699V2.66634ZM7.16699 7.33301H14.5003V8.66634H7.16699V7.33301ZM7.16699 11.9997H14.5003V13.333H7.16699V11.9997ZM2.41699 10.4163C2.41699 9.63394 3.05125 8.99967 3.83366 8.99967C4.61607 8.99967 5.25033 9.63394 5.25033 10.4163C5.25033 10.7401 5.14155 11.0388 4.95864 11.2775L4.95547 11.2816L4.04424 12.333H5.16699V13.333H2.50041L2.50005 12.5854L4.14813 10.6897C4.21186 10.6165 4.25033 10.5211 4.25033 10.4163C4.25033 10.1862 4.06378 9.99967 3.83366 9.99967C3.61618 9.99967 3.43748 10.1664 3.41864 10.3789L3.41039 10.583H2.41699V10.4163Z",fill:"black"},null,-1)])])}const lat=Qe(iat,[["render",aat]]),uat={tooltip:"Ordered list"},cat={tooltip:"Нумерованный список"},dat=jn({en:uat,ru:cat}),hat={class:"bootstrap-styles d-flex rich-text-icon icon-hover"},mat=Ze({__name:"OrderedListEditor",props:{editor:{},deps:{}},setup(t){const e=t,n={tooltip:dat({localeKey:e.deps.localeKey}).tooltip},r=m7.name,o=()=>{e.editor.chain().focus().toggleOrderedList().run()};return(i,s)=>It((I(),J("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:e.editor.isActive(z(r))}]),onClick:s[0]||(s[0]=()=>o())},[R("i",hat,[ie(lat)])],2)),[[z(Br),{title:n.tooltip,placement:"top"}]])}}),fat=Qe(mat,[["__scopeId","data-v-aaa43948"]]),pat={},gat={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Cat(t,e){return I(),J("svg",gat,[...e[0]||(e[0]=[R("path",{d:"M14 13.9995H2V12.6665H14V13.9995ZM14 10.6665H2V9.3335H14V10.6665ZM4.29102 7.3335H2.00684V5.99951H4.29102V7.3335ZM10.4434 7.3335H5.55664V2.68896H10.4434V7.3335ZM14 7.3335H11.7158V5.99951H14V7.3335ZM4.29102 3.99951H2.00684V2.6665H4.29102V3.99951ZM14 3.99951H11.7158V2.6665H14V3.99951Z",fill:"var(--black)"},null,-1)])])}const kee=Qe(pat,[["render",Cat]]),yat={},bat={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function vat(t,e){return I(),J("svg",bat,[...e[0]||(e[0]=[R("path",{d:"M14 13.9995H2V12.6665H14V13.9995ZM10.4434 10.6548H5.55664V6.01123H10.4434V10.6548ZM4.29102 10.6245H2.00684V9.29053H4.29102V10.6245ZM14 10.6245H11.7158V9.29053H14V10.6245ZM4.29102 7.29053H2.00684V5.95752H4.29102V7.29053ZM14 7.29053H11.7158V5.95752H14V7.29053Z",fill:"var(--black)"},null,-1),R("path",{d:"M14 2.6665H2V3.99984H14V2.6665Z",fill:"var(--black)"},null,-1)])])}const Eee=Qe(yat,[["render",vat]]),Tat={},Fat={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function xat(t,e){return I(),J("svg",Fat,[...e[0]||(e[0]=[R("path",{d:"M14 2.6665H2V3.99951H14V2.6665ZM14 5.99951H2V7.33252H14V5.99951ZM4.29102 9.33252H2.00684V10.6665H4.29102V9.33252ZM10.4434 9.33252H5.55664V13.9771H10.4434V9.33252ZM14 9.33252H11.7158V10.6665H14V9.33252ZM4.29102 12.6665H2.00684V13.9995H4.29102V12.6665ZM14 12.6665H11.7158V13.9995H14V12.6665Z",fill:"var(--black)"},null,-1)])])}const Ree=Qe(Tat,[["render",xat]]),Sat={},wat={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function kat(t,e){return I(),J("svg",wat,[...e[0]||(e[0]=[R("path",{d:"M14 11.9775H2V10.6445H14V11.9775ZM4.29102 8.64453H2.00684V7.31055H4.29102V8.64453ZM10.4434 8.64453H5.55664V4H10.4434V8.64453ZM14 8.64453H11.7158V7.31055H14V8.64453Z",fill:"var(--black)"},null,-1)])])}const _ee=Qe(Sat,[["render",kat]]),Eat={tooltip:"Vertical image alignment"},Rat={tooltip:"Выравнивание картинок по вертикали"},_at=jn({en:Eat,ru:Rat}),Dat={class:"bootstrap-styles vertical-align-editor dropdown rounded"},Aat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},$at={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Nat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Bat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Lat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Vat=Ze({__name:"VerticalAlignEditor",props:{editor:{},currentVerticalAlign:{},deps:{}},emits:["onVerticalAlignVariantChanged"],setup(t,{emit:e}){const n=t,r={tooltip:_at({localeKey:n.deps.localeKey}).tooltip},o=Mt({isOpened:!1}),i=a=>{s("onVerticalAlignVariantChanged",a),o.isOpened=!1},s=e;return(a,l)=>It((I(),J("div",Dat,[R("button",{id:"richTextDropdownVerticalAlign",class:Me(["bootstrap-styles p-1 rounded rich-text-button",{show:o.isOpened}]),type:"button",onClick:l[0]||(l[0]=u=>o.isOpened=!o.isOpened)},[R("i",Aat,[n.currentVerticalAlign==="Baseline"?(I(),et(_ee,{key:0})):Ue("",!0),n.currentVerticalAlign==="Top"?(I(),et(kee,{key:1})):Ue("",!0),n.currentVerticalAlign==="Middle"?(I(),et(Eee,{key:2})):Ue("",!0),n.currentVerticalAlign==="Bottom"?(I(),et(Ree,{key:3})):Ue("",!0)])],2),R("div",{class:Me([{show:o.isOpened},"bootstrap-styles vertical-align-dropdown bg-white p-1"]),"aria-labelledby":"richTextDropdownVerticalAlign"},[R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:n.currentVerticalAlign==="Baseline"}]),onClick:l[1]||(l[1]=()=>i("Baseline"))},[R("i",$at,[ie(_ee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:n.currentVerticalAlign==="Top"}]),onClick:l[2]||(l[2]=()=>i("Top"))},[R("i",Nat,[ie(kee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:n.currentVerticalAlign==="Middle"}]),onClick:l[3]||(l[3]=()=>i("Middle"))},[R("i",Bat,[ie(Eee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:n.currentVerticalAlign==="Bottom"}]),onClick:l[4]||(l[4]=()=>i("Bottom"))},[R("i",Lat,[ie(Ree)])],2)],2)])),[[z(Sd),()=>o.isOpened=!1],[z(Br),{title:r.tooltip,placement:"top"}]])}}),Mat=Qe(Vat,[["__scopeId","data-v-4a636ae8"]]),Oat={},Iat={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function Pat(t,e){return I(),J("svg",Iat,[...e[0]||(e[0]=[R("path",{d:"M2 2.6665H14V3.99984H2V2.6665ZM2 12.6665H11.3333V13.9998H2V12.6665ZM2 9.33317H14V10.6665H2V9.33317ZM2 5.99984H11.3333V7.33317H2V5.99984Z",fill:"var(--black)"},null,-1)])])}const Dee=Qe(Oat,[["render",Pat]]),Wat={},Hat={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function zat(t,e){return I(),J("svg",Hat,[...e[0]||(e[0]=[R("path",{d:"M2 2.6665H14V3.99984H2V2.6665ZM3.33333 12.6665H12.6667V13.9998H3.33333V12.6665ZM2 9.33317H14V10.6665H2V9.33317ZM3.33333 5.99984H12.6667V7.33317H3.33333V5.99984Z",fill:"var(--black)"},null,-1)])])}const Aee=Qe(Wat,[["render",zat]]),jat={},Uat={xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"};function Kat(t,e){return I(),J("svg",Uat,[...e[0]||(e[0]=[R("path",{d:"M2 2.6665H14V3.99984H2V2.6665ZM4.66667 12.6665H14V13.9998H4.66667V12.6665ZM2 9.33317H14V10.6665H2V9.33317ZM4.66667 5.99984H14V7.33317H4.66667V5.99984Z",fill:"var(--black)"},null,-1)])])}const $ee=Qe(jat,[["render",Kat]]),qat={tooltip:"Alignment"},Jat={tooltip:"Выравнивание"},Gat=jn({en:qat,ru:Jat}),Yat={class:"bootstrap-styles content-align-editor dropdown rounded"},Xat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Qat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},Zat={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},elt={class:"bootstrap-styles rich-text-icon icon-hover d-flex justify-content-center align-items-center"},tlt=Ze({__name:"ContentAlignEditor",props:{editor:{},deps:{},initialContentAlign:{}},setup(t){const e=t,n={tooltip:Gat({localeKey:e.deps.localeKey}).tooltip},r=Mt({isOpened:!1}),o=q(()=>{const{$from:s}=e.editor.state.selection,a=s.parent;return a.type.name==="paragraph"&&a.attrs.contentAlign||e.initialContentAlign}),i=s=>{e.editor.chain().focus().setParagraphContentAlign(s).run(),r.isOpened=!1};return(s,a)=>It((I(),J("div",Yat,[R("button",{id:"richTextDropdownContentAlign",class:Me(["bootstrap-styles p-1 rounded rich-text-button",{show:r.isOpened}]),type:"button",onClick:a[0]||(a[0]=l=>r.isOpened=!r.isOpened)},[R("i",Xat,[o.value==="Left"?(I(),et(Dee,{key:0})):Ue("",!0),o.value==="Center"?(I(),et(Aee,{key:1})):Ue("",!0),o.value==="Right"?(I(),et($ee,{key:2})):Ue("",!0)])],2),R("div",{class:Me([{show:r.isOpened},"bootstrap-styles content-align-dropdown bg-white p-1"]),"aria-labelledby":"richTextDropdownContentAlign"},[R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:o.value==="Left"}]),onClick:a[1]||(a[1]=()=>i("Left"))},[R("i",Qat,[ie(Dee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button me-14",{active:o.value==="Center"}]),onClick:a[2]||(a[2]=()=>i("Center"))},[R("i",Zat,[ie(Aee)])],2),R("button",{class:Me(["bootstrap-styles p-1 rounded rich-text-button",{active:o.value==="Right"}]),onClick:a[3]||(a[3]=()=>i("Right"))},[R("i",elt,[ie($ee)])],2)],2)])),[[z(Sd),()=>r.isOpened=!1],[z(Br),{title:n.tooltip,placement:"top"}]])}}),nlt=Qe(tlt,[["__scopeId","data-v-e9d5324a"]]),rlt={class:"bootstrap-styles rich-text-toolbar d-flex align-items-center border gap-1 p-1"},olt={key:2,class:"bootstrap-styles position-relative h-100"},ilt={key:3,class:"bootstrap-styles position-relative h-100"},slt={key:4,class:"bootstrap-styles d-flex justify-content-center align-items-center"},alt={key:7,class:"vl"},llt={key:13,class:"vl"},ult={key:16,class:"vl"},clt=Ze({__name:"RichTextToolbar",props:{editor:{},deps:{},element:{},theme:{},initialThemeName:{},initialContentAlign:{}},emits:["onVerticalAlignVariantChanged"],setup(t,{emit:e}){const n=t,r=n.deps.richTextToolbarPlugins,o=q(()=>{const{from:a,to:l}=n.editor.state.selection;return a!==l}),i=q(()=>n.editor.isActive("image")),s=e;return(a,l)=>(I(),J("div",rlt,[i.value?Ue("",!0):(I(),et(_ot,{key:0,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,initialThemeName:n.initialThemeName,deps:n.deps.themeSettingsSelectorDeps},null,8,["editor","theme","isAllowToEdit","initialThemeName","deps"])),i.value?Ue("",!0):(I(),et(Zrt,{key:1,theme:n.theme,editor:n.editor,isAllowToEdit:o.value,deps:n.deps.fontFamilySelectorDeps},null,8,["theme","editor","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),J("div",olt,[ie(vot,{editor:n.editor,theme:n.theme,deps:n.deps.fontSizeEditorDeps,class:Me({disabled:!o.value})},null,8,["editor","theme","deps","class"])])),i.value?Ue("",!0):(I(),J("div",ilt,[ie(jot,{editor:n.editor,theme:n.theme,deps:n.deps.lineHeightEditorDeps,class:Me({disabled:!o.value})},null,8,["editor","theme","deps","class"])])),i.value?Ue("",!0):(I(),J("div",slt,[ie(Wrt,{editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.colorPickerDeps},null,8,["editor","theme","isAllowToEdit","deps"])])),i.value?(I(),et(Mat,{key:5,currentVerticalAlign:n.element.ImageVerticalAlign,editor:n.editor,deps:n.deps.verticalAlignEditorDeps,onOnVerticalAlignVariantChanged:l[0]||(l[0]=u=>s("onVerticalAlignVariantChanged",u))},null,8,["currentVerticalAlign","editor","deps"])):Ue("",!0),i.value?Ue("",!0):(I(),et(nlt,{key:6,editor:n.editor,initialContentAlign:n.initialContentAlign,deps:n.deps.contentAlignEditorDeps,class:Me({"bootstrap-styles me-14":i.value})},null,8,["editor","initialContentAlign","deps","class"])),i.value?Ue("",!0):(I(),J("div",alt)),i.value?Ue("",!0):(I(),et(Qit,{key:8,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.fontWeightEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),et(Rst,{key:9,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.fontStyleEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),et(lst,{key:10,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.lineThroughEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),et(yst,{key:11,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.underlineEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),et(Ost,{key:12,editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.textTransformEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"])),i.value?Ue("",!0):(I(),J("div",llt)),i.value?Ue("",!0):(I(),et(oat,{key:14,editor:n.editor,deps:n.deps.bulletListEditorDeps},null,8,["editor","deps"])),i.value?Ue("",!0):(I(),et(fat,{key:15,editor:n.editor,deps:n.deps.orderedListEditorDeps},null,8,["editor","deps"])),i.value?Ue("",!0):(I(),J("div",ult)),ie(yit,{editor:n.editor,isAllowToEdit:o.value,deps:n.deps.linkEditorDeps},null,8,["editor","isAllowToEdit","deps"]),ie(Jst,{editor:n.editor,theme:n.theme,isAllowToEdit:o.value,deps:n.deps.unsubscribeLinkEditorDeps},null,8,["editor","theme","isAllowToEdit","deps"]),ie(Hit,{editor:n.editor,deps:n.deps.imageEditorDeps},null,8,["editor","deps"]),(I(!0),J(ot,null,zn(z(r),(u,c)=>(I(),J("span",{key:c,class:"bootstrap-styles d-none"},[(I(),et(Hme(u),{editor:n.editor},null,8,["editor"]))]))),128))]))}}),dlt=Qe(clt,[["__scopeId","data-v-5331228b"]]),hlt=t=>({Match:e=>{switch(t){case"Baseline":return e.whenBaseline();case"Top":return e.whenTop();case"Middle":return e.whenMiddle();case"Bottom":return e.whenBottom();default:return ls(t)}}}),mlt=t=>hlt(t.verticalAlign).Match({whenBaseline:()=>"baseline",whenTop:()=>"top",whenMiddle:()=>"middle",whenBottom:()=>"bottom"}),Nee="NormalText",Bee="Left",flt=Ze({__name:"RichText",props:{deps:{},theme:{},element:{},isSelected:{type:Boolean}},emits:["onRichTextUpdated","onRichTextRemoved","onElementClicked"],setup(t,{emit:e}){Pm(b=>({v02808ab3:n.theme.Colors.PrimaryColor,v3d0e3a01:n.theme.Colors.SecondaryColor,a0933cf4:n.theme.Colors.PrimaryTextColor,fbc08c58:n.theme.Colors.SecondaryTextColor,v21838d33:n.theme.Colors.CardBackgroundColor,v13541c9c:n.theme.Colors.ButtonTextColor,v43d7209d:n.theme.Colors.TitleColor,ad47ca9a:n.theme.Colors.HeadingColor,v5a1db76f:n.theme.Colors.SubHeadingColor,v1bbaa8ed:n.theme.Colors.LargeTextColor,v7d1410c6:n.theme.Colors.NormalTextColor,bbd9c868:n.theme.Colors.DescriptionTextColor,v58f5d097:n.theme.Colors.LinkColor,v2a98cdcb:n.theme.Colors.EmailBackgroundColor,v04760fef:n.theme.Colors.BodyColor,v23127854:p.value}));const n=t,r=Mt({isRemoveComponentWindowShown:!1,isEditing:!1}),o={removeWindowTitle:bee({localeKey:n.deps.localeKey}).removeWindowTitle,removeWindowDescription:bee({localeKey:n.deps.localeKey}).removeWindowDescription},i=yn(null),s=yn(null),{floatingStyles:a}=kpe(s,i,{placement:"top",whileElementsMounted:xpe,middleware:[Spe(10)]}),l=q(()=>{const b=a.value.transform??"translate(0px, 0px)",F=new DOMMatrix(b).m42;return{...a.value,left:"50%",transform:`translate(-50%, ${F}px)`}}),u=tV(),c=n.element.ContentAlign||Bee,d=q(()=>us({fontFamily:n.theme.FontFamily,themeFontSettings:n.theme.FontSettingsPresets.NormalText,themeColor:n.theme.Colors.NormalTextColor})),h=q(()=>{const b={...H7(d.value)};return{fontSize:b.fontSize,lineHeight:b.lineHeight,fontFamily:b.fontFamily,fontWeight:b.fontWeight,fontStyle:b.fontStyle,color:b.color}}),m=IKe({content:vee(n.element.Text),extensions:[...Srt({dataSourceFieldNameDelegate:n.deps.dataSourceFieldNameDelegate,initialThemeName:Nee,themeColors:n.theme.Colors,fallbackContentAlign:n.element.ContentAlign||Bee})],editable:r.isEditing,autofocus:"all",onUpdate:({editor:b})=>{if(!r.isEditing)return;const F=wrt({editor:b});y("onRichTextUpdated",{...n.element,Text:F})}}),f=()=>{m.value&&(m.value.chain().focus().undo().run(),r.isRemoveComponentWindowShown=!1)},p=q(()=>mlt({verticalAlign:n.element.ImageVerticalAlign})),g=()=>[document.querySelector(".rich-text-toolbar"),document.querySelector(".string-expression-builder-modal-window"),document.querySelector(`.rich-text-editor__content-${u}`)];mn(()=>n.element.Text,()=>{m.value&&!r.isEditing&&m.value.commands.setContent(vee(n.element.Text))});const y=e;return(b,F)=>It((I(),J("span",{ref_key:"richTextElementRef",ref:s,class:Me(["RichText cursor-pointer user-select-none",{selected:n.isSelected}]),style:he([{...h.value,minHeight:n.element.MinHeight+"px",display:"block"}]),onClick:F[3]||(F[3]=wr(()=>{y("onElementClicked"),r.isEditing=!0,z(m)&&z(m).setEditable(!0)},["prevent"]))},[ie(z(OKe),{class:Me(["rich-text-editor__content",`rich-text-editor__content-${z(u)}`]),editor:z(m)},null,8,["class","editor"]),z(m)&&r.isEditing?(I(),et(dlt,{key:0,ref_key:"richTextToolbarRef",ref:i,editor:z(m),deps:n.deps.richTextToolbarDeps,element:n.element,theme:n.theme,initialThemeName:Nee,initialContentAlign:z(c),style:he(l.value),onOnVerticalAlignVariantChanged:F[0]||(F[0]=T=>y("onRichTextUpdated",{...n.element,ImageVerticalAlign:T}))},null,8,["editor","deps","element","theme","initialContentAlign","style"])):Ue("",!0),(I(),et(Yj,{to:"#app"},[r.isRemoveComponentWindowShown?(I(),et(Int,{key:0,deps:n.deps.removeConfirmModalWindowDeps,headerText:o.removeWindowTitle,onCancel:F[1]||(F[1]=()=>f()),onConfirmed:F[2]||(F[2]=()=>{r.isRemoveComponentWindowShown=!1,y("onRichTextRemoved")})},{"body-content":wu(()=>[rw(en(o.removeWindowDescription),1)]),_:1},8,["deps","headerText"])):Ue("",!0)]))],6)),[[z(Sd),{handler:()=>{r.isEditing=!1,z(m)&&z(m).setEditable(!1)},include:g}]])}}),plt=Qe(flt,[["__scopeId","data-v-caafc674"]]),glt=Ze({__name:"UnsubscribeLink",props:{theme:{},element:{}},emits:["onElementClicked"],setup(t,{emit:e}){const n=t,r=q(()=>{const i=z7({fontFamily:n.theme.FontFamily,fontStyle:n.element.Style,themeDefinedFontSettings:n.theme.FontSettingsPresets,themeColors:n.theme.Colors});return{...H7(i)}}),o=e;return(i,s)=>(I(),J("a",{href:"#",class:"cursor-pointer user-select-none",style:he([{margin:"0"},[r.value,z(qx)({contentAlign:n.element.ContentAlign})]]),onClick:s[0]||(s[0]=wr(()=>o("onElementClicked"),["prevent"]))},en(n.element.Text),5))}}),Clt=Qe(glt,[["__scopeId","data-v-68ed9754"]]),ylt=["src","alt"],blt={class:"bootstrap-styles position-absolute top-0 left-0",width:"100%",style:{"border-spacing":"0","border-collapse":"collapse",width:"100%",height:"100%"}},vlt={key:0},Tlt=["align"],Flt={style:{width:"auto","border-spacing":"0","border-collapse":"separate"}},xlt={align:"center",style:{width:"auto"}},Slt={key:0},wlt={key:1},klt=["align"],Elt={style:{width:"auto","border-spacing":"0","border-collapse":"separate"}},Rlt={align:"center",style:{width:"auto"}},_lt={key:2},Dlt=["align"],Alt={style:{width:"auto","border-spacing":"0","border-collapse":"separate"}},$lt={align:"center",style:{width:"auto"}},Nlt={key:3},Blt=["align"],Llt={style:{width:"auto","border-spacing":"0","border-collapse":"separate"}},Vlt={align:"center",style:{width:"auto"}},Mlt=Ze({__name:"BackgroundImage",props:{deps:{},theme:{},element:{},context:{type:[String,Number,Boolean,Array,Object]},path:{},selectedElementPath:{}},emits:["onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved","onElementWrapperClicked"],setup(t,{emit:e}){const n=t,r=Mt({src:"",href:"",isLoaded:!1}),o=async s=>n.deps.stringExpressionEvaluator({stringExpression:s,context:n.context});(async()=>(r.src=await o(n.element.Src),r.href=await o(n.element.HRef),r.isLoaded=!0))();const i=e;return(s,a)=>r.isLoaded?(I(),J("table",{key:0,class:"bootstrap-styles position-relative",style:he([{"border-spacing":"0","border-collapse":"separate"},{width:"100%"}]),onClick:a[20]||(a[20]=wr(()=>i("onElementWrapperClicked"),["prevent"]))},[R("tbody",null,[R("tr",null,[R("td",{align:"center",style:he([{height:n.element.AdjustedHeight+"px",verticalAlign:"top"}])},[It(R("img",{src:r.src,alt:r.src,style:{"max-width":"100%"}},null,8,ylt),[[z(Jx),({width:l,height:u})=>{i("onImageSizeAdjusted",{Path:n.path,AdjustedHeight:u,AdjustedWidth:l}),r.isLoaded=!0}]]),R("table",blt,[R("tbody",null,[n.element.TopElementList.List.length>0&&n.element.TopElementList.Direction==="Vertical"?(I(),J("tr",vlt,[R("td",{valign:"top",align:z(Lc)({containerAlign:n.element.TopElementList.ContentAlign})},[R("table",Flt,[R("tbody",null,[R("tr",null,[R("td",{style:he({height:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)]),(I(!0),J(ot,null,zn(n.element.TopElementList.List,(l,u)=>(I(),J(ot,{key:u},[R("tr",null,[n.element.TopElementList.ContentAlign==="Left"?(I(),J("td",{key:0,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),R("td",xlt,[ie(kl,{deps:n.deps,theme:n.theme,element:l,path:[...n.path,"TopElementList","List",u],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:a[0]||(a[0]=c=>i("onImageSizeAdjusted",c)),onOnImageOriginalSizeAdjusted:a[1]||(a[1]=c=>i("onImageOriginalSizeAdjusted",c)),onOnElementClicked:a[2]||(a[2]=c=>i("onElementClicked",c)),onOnElementUpdatedEvent:a[3]||(a[3]=c=>i("onElementUpdatedEvent",c)),onOnElementRemoved:a[4]||(a[4]=c=>i("onElementRemoved",c))},null,8,["deps","theme","element","path","selectedElementPath","context"])]),n.element.TopElementList.ContentAlign==="Right"?(I(),J("td",{key:1,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0)]),n.element.TopElementList.List.length-1!==u?(I(),J("tr",Slt,[R("td",{style:he({height:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)])):Ue("",!0)],64))),128))])])],8,Tlt)])):Ue("",!0),n.element.TopElementList.List.length>0&&n.element.TopElementList.Direction==="Horizontal"?(I(),J("tr",wlt,[R("td",{valign:"top",align:z(Lc)({containerAlign:n.element.TopElementList.ContentAlign})},[R("table",Elt,[R("tbody",null,[R("tr",null,[R("td",{style:he({height:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)]),R("tr",null,[(I(!0),J(ot,null,zn(n.element.TopElementList.List,(l,u)=>(I(),J(ot,{key:u},[n.element.TopElementList.ContentAlign==="Left"&&u===0?(I(),J("td",{key:0,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),R("td",Rlt,[ie(kl,{deps:n.deps,theme:n.theme,element:l,path:[...n.path,"TopElementList","List",u],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:a[5]||(a[5]=c=>i("onImageSizeAdjusted",c)),onOnImageOriginalSizeAdjusted:a[6]||(a[6]=c=>i("onImageOriginalSizeAdjusted",c)),onOnElementClicked:a[7]||(a[7]=c=>i("onElementClicked",c)),onOnElementUpdatedEvent:a[8]||(a[8]=c=>i("onElementUpdatedEvent",c)),onOnElementRemoved:a[9]||(a[9]=c=>i("onElementRemoved",c))},null,8,["deps","theme","element","path","selectedElementPath","context"])]),n.element.TopElementList.ContentAlign==="Center"&&n.element.TopElementList.List.length-1!==u?(I(),J("td",{key:1,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),n.element.TopElementList.ContentAlign==="Right"?(I(),J("td",{key:2,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),n.element.TopElementList.ContentAlign==="Left"&&n.element.TopElementList.List.length-1!==u?(I(),J("td",{key:3,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0)],64))),128))])])])],8,klt)])):Ue("",!0),n.element.BottomElementList.List.length>0&&n.element.BottomElementList.Direction==="Vertical"?(I(),J("tr",_lt,[R("td",{valign:"bottom",align:z(Lc)({containerAlign:n.element.BottomElementList.ContentAlign})},[R("table",Alt,[R("tbody",null,[(I(!0),J(ot,null,zn(n.element.BottomElementList.List,(l,u)=>(I(),J(ot,{key:u},[R("tr",null,[n.element.BottomElementList.ContentAlign==="Left"?(I(),J("td",{key:0,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),R("td",$lt,[ie(kl,{deps:n.deps,theme:n.theme,element:l,path:[...n.path,"BottomElementList","List",u],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:a[10]||(a[10]=c=>i("onImageSizeAdjusted",c)),onOnImageOriginalSizeAdjusted:a[11]||(a[11]=c=>i("onImageOriginalSizeAdjusted",c)),onOnElementClicked:a[12]||(a[12]=c=>i("onElementClicked",c)),onOnElementUpdatedEvent:a[13]||(a[13]=c=>i("onElementUpdatedEvent",c)),onOnElementRemoved:a[14]||(a[14]=c=>i("onElementRemoved",c))},null,8,["deps","theme","element","path","selectedElementPath","context"])]),n.element.BottomElementList.ContentAlign==="Right"?(I(),J("td",{key:1,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0)]),R("tr",null,[R("td",{style:he({height:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)])],64))),128))])])],8,Dlt)])):Ue("",!0),n.element.BottomElementList.List.length>0&&n.element.BottomElementList.Direction==="Horizontal"?(I(),J("tr",Nlt,[R("td",{valign:"bottom",align:z(Lc)({containerAlign:n.element.BottomElementList.ContentAlign})},[R("table",Llt,[R("tbody",null,[R("tr",null,[(I(!0),J(ot,null,zn(n.element.BottomElementList.List,(l,u)=>(I(),J(ot,{key:u},[n.element.BottomElementList.ContentAlign==="Left"&&u===0?(I(),J("td",{key:0,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),R("td",Vlt,[ie(kl,{deps:n.deps,theme:n.theme,element:l,path:[...n.path,"BottomElementList","List",u],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageSizeAdjusted:a[15]||(a[15]=c=>i("onImageSizeAdjusted",c)),onOnImageOriginalSizeAdjusted:a[16]||(a[16]=c=>i("onImageOriginalSizeAdjusted",c)),onOnElementClicked:a[17]||(a[17]=c=>i("onElementClicked",c)),onOnElementUpdatedEvent:a[18]||(a[18]=c=>i("onElementUpdatedEvent",c)),onOnElementRemoved:a[19]||(a[19]=c=>i("onElementRemoved",c))},null,8,["deps","theme","element","path","selectedElementPath","context"])]),n.element.BottomElementList.ContentAlign==="Center"&&n.element.BottomElementList.List.length-1!==u?(I(),J("td",{key:1,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),n.element.BottomElementList.ContentAlign==="Right"?(I(),J("td",{key:2,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0),n.element.BottomElementList.ContentAlign==="Left"&&n.element.BottomElementList.List.length-1!==u?(I(),J("td",{key:3,style:he({width:n.element.ElementsSpacerSize+"px",fontSize:n.element.ElementsSpacerSize+"px",lineHeight:n.element.ElementsSpacerSize+"px"})},"   ",4)):Ue("",!0)],64))),128))])])])],8,Blt)])):Ue("",!0)])])],4)])])])):Ue("",!0)}}),kl=Ze({__name:"Elements",props:{deps:{},theme:{},element:{},path:{},context:{type:[String,Number,Boolean,Array,Object]},selectedElementPath:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=e,o=(i,s)=>{r("onElementClicked",{element:i,path:[...n.path,s]})};return(i,s)=>(I(),J("span",{onClick:s[31]||(s[31]=wr(()=>{},["stop"]))},[n.element.Button!==void 0?(I(),et(bnt,{key:0,deps:n.deps,theme:n.theme,element:n.element.Button,context:n.context,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"Button"])}),onOnElementClicked:s[0]||(s[0]=a=>o(n.element,"Button"))},null,8,["deps","theme","element","context","class"])):Ue("",!0),n.element.HeightContainer!==void 0?(I(),et(Ytt,{key:1,deps:n.deps,theme:n.theme,element:n.element.HeightContainer,path:[...n.path,"HeightContainer"],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageOriginalSizeAdjusted:s[1]||(s[1]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[2]||(s[2]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[3]||(s[3]=a=>r("onElementClicked",a)),onOnElementRemoved:s[4]||(s[4]=a=>r("onElementRemoved",a)),onOnElementUpdatedEvent:s[5]||(s[5]=a=>r("onElementUpdatedEvent",a))},null,8,["deps","theme","element","path","selectedElementPath","context"])):Ue("",!0),n.element.Image!==void 0?(I(),et(nnt,{key:2,deps:n.deps,theme:n.theme,element:n.element.Image,context:n.context,path:[...n.path,"Image"],class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"Image"])}),onOnImageOriginalSizeAdjusted:s[6]||(s[6]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[7]||(s[7]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[8]||(s[8]=a=>o(n.element,"Image"))},null,8,["deps","theme","element","context","path","class"])):Ue("",!0),n.element.Spacer!==void 0?(I(),et(lnt,{key:3,element:n.element.Spacer,theme:n.theme,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"Spacer"])}),onOnElementClicked:s[9]||(s[9]=a=>o(n.element,"Spacer"))},null,8,["element","theme","class"])):Ue("",!0),n.element.SpanText!==void 0?(I(),et(Fnt,{key:4,deps:n.deps,theme:n.theme,element:n.element.SpanText,context:n.context,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"SpanText"])}),onOnElementClicked:s[10]||(s[10]=a=>o(n.element,"SpanText"))},null,8,["deps","theme","element","context","class"])):Ue("",!0),n.element.RichText!==void 0?(I(),et(plt,{key:5,deps:n.deps.richTextDeps,theme:n.theme,element:n.element.RichText,isSelected:z(_f)(n.selectedElementPath,[...n.path,"RichText"]),onOnElementClicked:s[11]||(s[11]=a=>o(n.element,"RichText")),onOnRichTextUpdated:s[12]||(s[12]=a=>{r("onElementUpdatedEvent",{path:n.path,element:{RichText:a}})}),onOnRichTextRemoved:s[13]||(s[13]=()=>{r("onElementRemoved",n.path)})},null,8,["deps","theme","element","isSelected"])):Ue("",!0),n.element.OneLineList!==void 0?(I(),et(snt,{key:6,deps:n.deps,theme:n.theme,element:n.element.OneLineList,path:[...n.path,"OneLineList"],selectedElementPath:n.selectedElementPath,context:n.context,onOnImageOriginalSizeAdjusted:s[14]||(s[14]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[15]||(s[15]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[16]||(s[16]=a=>r("onElementClicked",a)),onOnElementRemoved:s[17]||(s[17]=a=>r("onElementRemoved",a)),onOnElementUpdatedEvent:s[18]||(s[18]=a=>r("onElementUpdatedEvent",a))},null,8,["deps","theme","element","path","selectedElementPath","context"])):Ue("",!0),n.element.If!==void 0?(I(),et(Ktt,{key:7,deps:n.deps,theme:n.theme,element:n.element.If,context:n.context,path:[...n.path,"If"],selectedElementPath:n.selectedElementPath,onOnImageOriginalSizeAdjusted:s[19]||(s[19]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[20]||(s[20]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[21]||(s[21]=a=>r("onElementClicked",a)),onOnElementRemoved:s[22]||(s[22]=a=>r("onElementRemoved",a)),onOnElementUpdatedEvent:s[23]||(s[23]=a=>r("onElementUpdatedEvent",a))},null,8,["deps","theme","element","context","path","selectedElementPath"])):Ue("",!0),n.element.UnsubscribeLink!==void 0?(I(),et(Clt,{key:8,theme:n.theme,element:n.element.UnsubscribeLink,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"UnsubscribeLink"])}),onOnElementClicked:s[24]||(s[24]=a=>o(n.element,"UnsubscribeLink"))},null,8,["theme","element","class"])):Ue("",!0),n.element.BackgroundImage!==void 0?(I(),et(Mlt,{key:9,deps:n.deps,theme:n.theme,element:n.element.BackgroundImage,context:n.context,path:[...n.path,"BackgroundImage"],selectedElementPath:n.selectedElementPath,class:Me({"element-selected":z(_f)(n.selectedElementPath,[...n.path,"BackgroundImage"])}),onOnImageOriginalSizeAdjusted:s[25]||(s[25]=a=>r("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[26]||(s[26]=a=>r("onImageSizeAdjusted",a)),onOnElementClicked:s[27]||(s[27]=a=>r("onElementClicked",a)),onOnElementRemoved:s[28]||(s[28]=a=>r("onElementRemoved",a)),onOnElementUpdatedEvent:s[29]||(s[29]=a=>r("onElementUpdatedEvent",a)),onOnElementWrapperClicked:s[30]||(s[30]=a=>o(n.element,"BackgroundImage"))},null,8,["deps","theme","element","context","path","selectedElementPath","class"])):Ue("",!0)]))}}),Olt=["align"],Ilt=Ze({__name:"IteratedColumn",props:{deps:{},theme:{},iteratedColumn:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},containerWidth:{}},emits:["onImageSizeAdjusted","onImageOriginalSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(i=>({v63736150:o.value}));const n=t,r=e,o=q(()=>n.iteratedColumn.WidthInPercents*n.containerWidth+"px");return(i,s)=>(I(),J("div",{class:"iterated-column",style:he({display:"inline-block",verticalAlign:n.iteratedColumn.VerticalAlign})},[R("table",{style:he([[z(bw)({borderCollapse:n.iteratedColumn.BorderCollapse})],{width:"100%","border-spacing":"0"}]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.iteratedColumn.ContainerAlign}),style:he([[z(md)({border:n.iteratedColumn.Border,themeColors:n.theme.Colors}),{backgroundColor:z(Ll)({color:n.iteratedColumn.BgColor,themeColors:n.theme.Colors})},z(Wu)({borderRadius:n.iteratedColumn.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner})],{"line-height":"normal"}])},[(I(!0),J(ot,null,zn(n.iteratedColumn.Elements,(a,l)=>(I(),et(kl,{key:l,deps:n.deps.elementsDeps,theme:n.theme,element:a,context:n.context,path:[...n.path,"Elements",l],selectedElementPath:n.selectedElementPath,onOnElementClicked:s[0]||(s[0]=u=>r("onElementClicked",u)),onOnImageSizeAdjusted:s[1]||(s[1]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[2]||(s[2]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementUpdatedEvent:s[3]||(s[3]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[4]||(s[4]=u=>r("onElementRemoved",u))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))],12,Olt)])])],4)],4))}}),Plt=Qe(Ilt,[["__scopeId","data-v-4bdaa248"]]),Wlt=["align"],Hlt=Ze({__name:"IteratedColumnN21",props:{deps:{},theme:{},iteratedColumnN21:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},containerWidth:{}},emits:["onImageSizeAdjusted","onImageOriginalSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(i=>({v2fbddeb4:o.value}));const n=t,r=e,o=q(()=>n.iteratedColumnN21.WidthInPercents*n.containerWidth+"px");return(i,s)=>(I(),J("div",{class:"iterated-column__N-2-1",style:he({display:"inline-block",verticalAlign:n.iteratedColumnN21.VerticalAlign})},[R("table",{style:he([[z(bw)({borderCollapse:n.iteratedColumnN21.BorderCollapse})],{width:"100%","border-spacing":"0"}]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.iteratedColumnN21.ContainerAlign}),style:he([[z(md)({border:n.iteratedColumnN21.Border,themeColors:n.theme.Colors}),{backgroundColor:z(Ll)({color:n.iteratedColumnN21.BgColor,themeColors:n.theme.Colors})},z(Wu)({borderRadius:n.iteratedColumnN21.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner})],{"line-height":"normal"}])},[(I(!0),J(ot,null,zn(n.iteratedColumnN21.Elements,(a,l)=>(I(),et(kl,{key:l,deps:n.deps.elementsDeps,theme:n.theme,element:a,context:n.context,path:[...n.path,"Elements",l],selectedElementPath:n.selectedElementPath,onOnElementClicked:s[0]||(s[0]=u=>r("onElementClicked",u)),onOnImageSizeAdjusted:s[1]||(s[1]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[2]||(s[2]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementUpdatedEvent:s[3]||(s[3]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[4]||(s[4]=u=>r("onElementRemoved",u))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))],12,Wlt)])])],4)],4))}}),zlt=Qe(Hlt,[["__scopeId","data-v-b46af162"]]),jlt=["align"],Ult=Ze({__name:"IteratedColumnN22",props:{deps:{},theme:{},iteratedColumnN22:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},containerWidth:{}},emits:["onImageSizeAdjusted","onImageOriginalSizeAdjusted","onElementClicked","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(i=>({v904d8f2c:o.value}));const n=t,r=e,o=q(()=>n.iteratedColumnN22.WidthInPercents*n.containerWidth+"px");return(i,s)=>(I(),J("div",{class:"iterated-column__N-2-2",style:he({display:"inline-block",verticalAlign:n.iteratedColumnN22.VerticalAlign})},[R("table",{style:he([[z(bw)({borderCollapse:n.iteratedColumnN22.BorderCollapse})],{width:"100%","border-spacing":"0"}]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.iteratedColumnN22.ContainerAlign}),style:he([[z(md)({border:n.iteratedColumnN22.Border,themeColors:n.theme.Colors}),{backgroundColor:z(Ll)({color:n.iteratedColumnN22.BgColor,themeColors:n.theme.Colors})},z(Wu)({borderRadius:n.iteratedColumnN22.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner})],{"line-height":"normal"}])},[(I(!0),J(ot,null,zn(n.iteratedColumnN22.Elements,(a,l)=>(I(),et(kl,{key:l,deps:n.deps.elementsDeps,theme:n.theme,element:a,context:n.context,path:[...n.path,"Elements",l],selectedElementPath:n.selectedElementPath,onOnElementClicked:s[0]||(s[0]=u=>r("onElementClicked",u)),onOnImageSizeAdjusted:s[1]||(s[1]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[2]||(s[2]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementUpdatedEvent:s[3]||(s[3]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[4]||(s[4]=u=>r("onElementRemoved",u))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))],12,jlt)])])],4)],4))}}),Klt=Qe(Ult,[["__scopeId","data-v-319c5209"]]),qlt={class:"iterated-column-container",style:{"border-spacing":"0","border-collapse":"collapse",width:"100%",margin:"0 auto"},width:"100%"},Jlt={align:"center",style:{"font-size":"0"}},Glt=Ze({__name:"IteratedColumnBodyRow",props:{deps:{},theme:{},iteratedColumnBodyRow:{},path:{},selectedElementPath:{},context:{},rowWidth:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(l=>({a80c0c96:i.value}));const n=t,r=Mt({dataList:[],isLoaded:!1}),o=()=>n.deps.listExpressionEvaluator({listExpression:n.iteratedColumnBodyRow.DataSource,context:n.context}).then(l=>{r.dataList=l,r.isLoaded=!0});o(),mn(()=>n.context,()=>o());const i=q(()=>Sr({paddingExpression:n.iteratedColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})+"px"),s={iteratedColumn:l=>l!==void 0,iteratedColumnVariant:l=>l!==void 0,iteratedColumnN21:l=>l!==void 0,iteratedColumnN22:l=>l!==void 0},a=e;return(l,u)=>(I(),J("table",qlt,[R("tbody",null,[R("tr",null,[R("td",Jlt,[(I(!0),J(ot,null,zn(r.dataList,(c,d)=>(I(),J(ot,{key:d},[s.iteratedColumn(n.iteratedColumnBodyRow.IteratedColumn)?(I(),et(Plt,{key:d,class:Me(["iterated-column-bottom-spacer",{"iterated-column__tablet-padding-right":(d+1)%2===1,"iterated-column__tablet-padding-left":(d+1)%2===0,"is-last-desktop-line":d>=r.dataList.length-n.iteratedColumnBodyRow.NumberColumnsInLine,"is-last-tablet-line":d>=r.dataList.length-2,"is-last-mobile-line":d==r.dataList.length-1}]),deps:n.deps.iteratedColumnDeps,theme:n.theme,style:he(z(u_)({numberColumnsInLine:n.iteratedColumnBodyRow.NumberColumnsInLine,index:d,paddingSize:z(Sr)({paddingExpression:n.iteratedColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),directionRtl:!1})),iteratedColumn:n.iteratedColumnBodyRow.IteratedColumn,path:[...n.path,"IteratedColumn"],selectedElementPath:n.selectedElementPath,context:{...n.context,[n.iteratedColumnBodyRow.IndexName]:c},containerWidth:n.rowWidth,onOnElementClicked:u[0]||(u[0]=h=>a("onElementClicked",h)),onOnImageOriginalSizeAdjusted:u[1]||(u[1]=h=>a("onImageOriginalSizeAdjusted",h)),onOnImageSizeAdjusted:u[2]||(u[2]=h=>a("onImageSizeAdjusted",h)),onOnElementUpdatedEvent:u[3]||(u[3]=h=>a("onElementUpdatedEvent",h)),onOnElementRemoved:u[4]||(u[4]=h=>a("onElementRemoved",h))},null,8,["deps","theme","class","style","iteratedColumn","path","selectedElementPath","context","containerWidth"])):Ue("",!0),s.iteratedColumnVariant(n.iteratedColumnBodyRow.IteratedColumnVariant)?(I(),J(ot,{key:1},[s.iteratedColumnN21(n.iteratedColumnBodyRow.IteratedColumnVariant.IteratedColumnN21)?(I(),et(zlt,{key:d,deps:n.deps.iteratedColumnVariantDeps.iteratedColumnN21Deps,theme:n.theme,class:Me(["iterated-column-bottom-spacer",{"iterated-column__tablet-padding-right":(d+1)%2===1,"iterated-column__tablet-padding-left":(d+1)%2===0,"is-last-desktop-line":d>=r.dataList.length-n.iteratedColumnBodyRow.NumberColumnsInLine,"is-last-tablet-line":d>=r.dataList.length-2,"is-last-mobile-line":d==r.dataList.length-1}]),style:he(z(u_)({numberColumnsInLine:n.iteratedColumnBodyRow.NumberColumnsInLine,index:d,paddingSize:z(Sr)({paddingExpression:n.iteratedColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),directionRtl:!1})),iteratedColumnN21:n.iteratedColumnBodyRow.IteratedColumnVariant.IteratedColumnN21,path:[...n.path,"IteratedColumnVariant","IteratedColumnN21"],selectedElementPath:n.selectedElementPath,context:{...n.context,[n.iteratedColumnBodyRow.IndexName]:c},containerWidth:n.rowWidth,onOnElementClicked:u[5]||(u[5]=h=>a("onElementClicked",h)),onOnImageOriginalSizeAdjusted:u[6]||(u[6]=h=>a("onImageOriginalSizeAdjusted",h)),onOnImageSizeAdjusted:u[7]||(u[7]=h=>a("onImageSizeAdjusted",h)),onOnElementUpdatedEvent:u[8]||(u[8]=h=>a("onElementUpdatedEvent",h)),onOnElementRemoved:u[9]||(u[9]=h=>a("onElementRemoved",h))},null,8,["deps","theme","class","style","iteratedColumnN21","path","selectedElementPath","context","containerWidth"])):Ue("",!0),s.iteratedColumnN22(n.iteratedColumnBodyRow.IteratedColumnVariant.IteratedColumnN22)?(I(),et(Klt,{key:d,deps:n.deps.iteratedColumnVariantDeps.iteratedColumnN22Deps,theme:n.theme,class:Me(["iterated-column-bottom-spacer",{"iterated-column__tablet-padding-right iterated-column__N-2-2_mobile-padding-right":(d+1)%2===1,"iterated-column__tablet-padding-left iterated-column__N-2-2_mobile-padding-left":(d+1)%2===0,"is-last-desktop-line":d>=r.dataList.length-n.iteratedColumnBodyRow.NumberColumnsInLine,"is-last-tablet-line is-last-mobile-line":d>=r.dataList.length-2}]),style:he(z(u_)({numberColumnsInLine:n.iteratedColumnBodyRow.NumberColumnsInLine,index:d,paddingSize:z(Sr)({paddingExpression:n.iteratedColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),directionRtl:!1})),iteratedColumnN22:n.iteratedColumnBodyRow.IteratedColumnVariant.IteratedColumnN22,path:[...n.path,"IteratedColumnVariant","IteratedColumnN22"],selectedElementPath:n.selectedElementPath,context:{...n.context,[n.iteratedColumnBodyRow.IndexName]:c},containerWidth:n.rowWidth,onOnElementClicked:u[10]||(u[10]=h=>a("onElementClicked",h)),onOnImageOriginalSizeAdjusted:u[11]||(u[11]=h=>a("onImageOriginalSizeAdjusted",h)),onOnImageSizeAdjusted:u[12]||(u[12]=h=>a("onImageSizeAdjusted",h)),onOnElementUpdatedEvent:u[13]||(u[13]=h=>a("onElementUpdatedEvent",h)),onOnElementRemoved:u[14]||(u[14]=h=>a("onElementRemoved",h))},null,8,["deps","theme","class","style","iteratedColumnN22","path","selectedElementPath","context","containerWidth"])):Ue("",!0)],64)):Ue("",!0)],64))),128))])])])]))}}),Ylt=Qe(Glt,[["__scopeId","data-v-69ed8d34"]]),Xlt={style:{"border-spacing":"0","border-collapse":"collapse",width:"100%",margin:"0 auto"}},Qlt=Ze({__name:"IteratedBodyRow",props:{theme:{},deps:{},iteratedBodyRow:{},path:{},selectedElementPath:{},context:{},containerWidth:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=Mt({dataList:[]});n.deps.listExpressionEvaluator({listExpression:n.iteratedBodyRow.DataSource,context:n.context}).then(i=>r.dataList=i);const o=e;return(i,s)=>(I(),J("table",Xlt,[(I(!0),J(ot,null,zn(r.dataList,(a,l)=>(I(),J("tr",{key:l},[R("td",{style:he([z(vw)({paddings:n.iteratedBodyRow.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})])},[ie(cbe,{emailComponentBodyRow:n.iteratedBodyRow.BodyRow,deps:{iteratedColumnBodyRowDeps:n.deps.iteratedColumnBodyRowDeps,multipleColumnBodyRowDeps:n.deps.multipleColumnBodyRowDeps,listExpressionEvaluator:n.deps.listExpressionEvaluator},theme:n.theme,context:{...n.context,[n.iteratedBodyRow.IndexName]:a},rowWidth:n.containerWidth,path:[...n.path,"BodyRow"],selectedElementPath:n.selectedElementPath,onOnElementClicked:s[0]||(s[0]=u=>o("onElementClicked",u)),onOnImageOriginalSizeAdjusted:s[1]||(s[1]=u=>o("onImageOriginalSizeAdjusted",u)),onOnImageSizeAdjusted:s[2]||(s[2]=u=>o("onImageSizeAdjusted",u)),onOnColumnWidthAdjusted:s[3]||(s[3]=u=>o("onColumnWidthAdjusted",u)),onOnElementUpdatedEvent:s[4]||(s[4]=u=>o("onElementUpdatedEvent",u)),onOnElementRemoved:s[5]||(s[5]=u=>o("onElementRemoved",u))},null,8,["emailComponentBodyRow","deps","theme","context","rowWidth","path","selectedElementPath"])],4)]))),128))]))}}),Zlt=t=>({Match:e=>{switch(t){case"Top":return e.Top();case"Middle":return e.Middle();case"Bottom":return e.Bottom();case"Baseline":return e.Baseline()}}}),eut=t=>Zlt(t).Match({Top:()=>"start",Middle:()=>"center",Bottom:()=>"end",Baseline:()=>"baseline"}),tut=Wl,nut=t=>({JustifyWidth:{WidthInPixels:t}}),rut=t=>({ShrinkToContentWidth:{WidthInPixels:t}}),out=Vtt,iut=["align"],sut=Ze({__name:"MultipleColumn",props:{deps:{},theme:{},multipleColumn:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},containerWidth:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(l=>({acad954c:a.value,v1971599c:s.value,v72b8524e:i.value}));const n=t,r=e,o=l=>{tut(n.multipleColumn.Width).Match({JustifyWidth:()=>DI.Some(nut(l)),ShrinkToContentWidth:()=>DI.Some(rut(l)),WidthInPercents:()=>DI.None}).map(u=>r("onColumnWidthAdjusted",{Path:n.path,Width:u}))},i=q(()=>out(n.multipleColumn.Width).Match({default:()=>"",WidthInPercents:l=>l.Value*n.containerWidth+"px"})),s=q(()=>eut(n.multipleColumn.VerticalAlign)),a=q(()=>n.multipleColumn.VerticalAlign);return(l,u)=>It((I(),J("div",{class:Me(["multiple-column",{"multiple-column--justifyWidth":n.multipleColumn.Width.JustifyWidth!==void 0,"multiple-column--shrinkToContentWidth":n.multipleColumn.Width.ShrinkToContentWidth!==void 0,"multiple-column--widthInPercents":n.multipleColumn.Width.WidthInPercents!==void 0}]),style:{direction:"ltr"}},[R("table",{style:he([{width:"100%","border-spacing":"0"},[z(bw)({borderCollapse:n.multipleColumn.BorderCollapse})]]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{align:z(Lc)({containerAlign:n.multipleColumn.ContainerAlign}),style:he([[z(md)({border:n.multipleColumn.Border,themeColors:n.theme.Colors}),z(Wu)({borderRadius:n.multipleColumn.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner}),{backgroundColor:z(Ll)({color:n.multipleColumn.BgColor,themeColors:n.theme.Colors})},z(vw)({paddings:n.multipleColumn.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})],{"line-height":"normal"}])},[(I(!0),J(ot,null,zn(n.multipleColumn.Elements,(c,d)=>(I(),et(kl,{key:d,deps:n.deps.elementsDeps,theme:n.theme,element:c,context:n.context,path:[...n.path,"Elements",d],selectedElementPath:n.selectedElementPath,onOnElementClicked:u[0]||(u[0]=h=>r("onElementClicked",h)),onOnImageSizeAdjusted:u[1]||(u[1]=h=>r("onImageSizeAdjusted",h)),onOnImageOriginalSizeAdjusted:u[2]||(u[2]=h=>r("onImageOriginalSizeAdjusted",h)),onOnElementUpdatedEvent:u[3]||(u[3]=h=>r("onElementUpdatedEvent",h)),onOnElementRemoved:u[4]||(u[4]=h=>r("onElementRemoved",h))},null,8,["deps","theme","element","context","path","selectedElementPath"]))),128))],12,iut)])])],4)],2)),[[z(Jx),c=>o(c.width)]])}}),aut=Qe(sut,[["__scopeId","data-v-bfa1869f"]]),lut=Ze({__name:"MultipleColumnBodyRow",props:{deps:{},theme:{},multipleColumnBodyRow:{},path:{},selectedElementPath:{},context:{type:[String,Number,Boolean,Array,Object]},rowWidth:{}},emits:["onElementClicked","onImageSizeAdjusted","onImageOriginalSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){Pm(i=>({v36e68443:o.value}));const n=t,r=e,o=q(()=>Sr({paddingExpression:n.multipleColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})+"px");return(i,s)=>(I(),J("table",{class:"multiple-column-container",style:he([[z(bw)({borderCollapse:n.multipleColumnBodyRow.BorderCollapse}),z(md)({border:n.multipleColumnBodyRow.Border,themeColors:n.theme.Colors}),z(Wu)({borderRadius:n.multipleColumnBodyRow.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner}),{backgroundColor:z(Ll)({color:n.multipleColumnBodyRow.BgColor,themeColors:n.theme.Colors})}],{"border-spacing":"0",width:"100%",margin:"0 auto"}]),width:"100%"},[R("tbody",null,[R("tr",null,[R("td",{class:"multiple-column-container__inner",style:he([{"font-size":"0"},[z(Utt)({containerAlign:n.multipleColumnBodyRow.ContainerAlign}),z(vw)({paddings:n.multipleColumnBodyRow.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),n.multipleColumnBodyRow.DirectionRtl?{direction:"rtl"}:{direction:"ltr"}]])},[(I(!0),J(ot,null,zn(n.multipleColumnBodyRow.Columns,(a,l)=>(I(),et(aut,{key:l,deps:n.deps.multipleColumnDeps,theme:n.theme,multipleColumn:a,path:[...n.path,"Columns",l],selectedElementPath:n.selectedElementPath,context:n.context,containerWidth:n.rowWidth-z(Sr)({paddingExpression:n.multipleColumnBodyRow.Paddings.Left,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})-z(Sr)({paddingExpression:n.multipleColumnBodyRow.Paddings.Right,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings})-n.multipleColumnBodyRow.Border.Left.Width-n.multipleColumnBodyRow.Border.Right.Width,style:he(z(u_)({numberColumnsInLine:n.multipleColumnBodyRow.Columns.length,index:l,paddingSize:z(Sr)({paddingExpression:n.multipleColumnBodyRow.ColumnSpacerSize,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings}),directionRtl:n.multipleColumnBodyRow.DirectionRtl})),class:Me({"is-last-tablet-line":l==n.multipleColumnBodyRow.Columns.length-1,"is-last-mobile-line":l==n.multipleColumnBodyRow.Columns.length-1}),onOnElementClicked:s[0]||(s[0]=u=>r("onElementClicked",u)),onOnColumnWidthAdjusted:s[1]||(s[1]=u=>r("onColumnWidthAdjusted",u)),onOnImageSizeAdjusted:s[2]||(s[2]=u=>r("onImageSizeAdjusted",u)),onOnImageOriginalSizeAdjusted:s[3]||(s[3]=u=>r("onImageOriginalSizeAdjusted",u)),onOnElementUpdatedEvent:s[4]||(s[4]=u=>r("onElementUpdatedEvent",u)),onOnElementRemoved:s[5]||(s[5]=u=>r("onElementRemoved",u))},null,8,["deps","theme","multipleColumn","path","selectedElementPath","context","containerWidth","style","class"]))),128))],4)])])],4))}}),uut=Qe(lut,[["__scopeId","data-v-c6ebdc94"]]),cbe=Ze({__name:"EmailComponentBodyRow",props:{deps:{},theme:{},emailComponentBodyRow:{},path:{},selectedElementPath:{},context:{},rowWidth:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r={multipleColumns:i=>i!==void 0,iteratedColumns:i=>i!==void 0,iteratedBodyRow:i=>i!==void 0},o=e;return(i,s)=>(I(),J("div",null,[r.multipleColumns(n.emailComponentBodyRow.MultipleColumnBodyRow)?(I(),et(uut,{key:0,deps:n.deps.multipleColumnBodyRowDeps,theme:n.theme,multipleColumnBodyRow:n.emailComponentBodyRow.MultipleColumnBodyRow,path:[...n.path,"MultipleColumnBodyRow"],selectedElementPath:n.selectedElementPath,context:t.context,rowWidth:n.rowWidth,onOnColumnWidthAdjusted:s[0]||(s[0]=a=>o("onColumnWidthAdjusted",a)),onOnImageOriginalSizeAdjusted:s[1]||(s[1]=a=>o("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[2]||(s[2]=a=>o("onImageSizeAdjusted",a)),onOnElementClicked:s[3]||(s[3]=a=>o("onElementClicked",a)),onOnElementUpdatedEvent:s[4]||(s[4]=a=>o("onElementUpdatedEvent",a)),onOnElementRemoved:s[5]||(s[5]=a=>o("onElementRemoved",a))},null,8,["deps","theme","multipleColumnBodyRow","path","selectedElementPath","context","rowWidth"])):Ue("",!0),r.iteratedColumns(n.emailComponentBodyRow.IteratedColumnBodyRow)?(I(),et(Ylt,{key:1,deps:n.deps.iteratedColumnBodyRowDeps,theme:n.theme,iteratedColumnBodyRow:n.emailComponentBodyRow.IteratedColumnBodyRow,path:[...n.path,"IteratedColumnBodyRow"],selectedElementPath:n.selectedElementPath,context:t.context,rowWidth:n.rowWidth,onOnElementClicked:s[6]||(s[6]=a=>o("onElementClicked",a)),onOnImageOriginalSizeAdjusted:s[7]||(s[7]=a=>o("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[8]||(s[8]=a=>o("onImageSizeAdjusted",a)),onOnElementUpdatedEvent:s[9]||(s[9]=a=>o("onElementUpdatedEvent",a)),onOnElementRemoved:s[10]||(s[10]=a=>o("onElementRemoved",a))},null,8,["deps","theme","iteratedColumnBodyRow","path","selectedElementPath","context","rowWidth"])):Ue("",!0),r.iteratedBodyRow(n.emailComponentBodyRow.IteratedBodyRow)?(I(),et(Qlt,{key:2,deps:{iteratedColumnBodyRowDeps:n.deps.iteratedColumnBodyRowDeps,multipleColumnBodyRowDeps:n.deps.multipleColumnBodyRowDeps,listExpressionEvaluator:n.deps.listExpressionEvaluator},theme:n.theme,iteratedBodyRow:n.emailComponentBodyRow.IteratedBodyRow,path:[...n.path,"IteratedBodyRow"],selectedElementPath:n.selectedElementPath,context:t.context,containerWidth:n.rowWidth,onOnElementClicked:s[11]||(s[11]=a=>o("onElementClicked",a)),onOnImageOriginalSizeAdjusted:s[12]||(s[12]=a=>o("onImageOriginalSizeAdjusted",a)),onOnImageSizeAdjusted:s[13]||(s[13]=a=>o("onImageSizeAdjusted",a)),onOnElementUpdatedEvent:s[14]||(s[14]=a=>o("onElementUpdatedEvent",a)),onOnElementRemoved:s[15]||(s[15]=a=>o("onElementRemoved",a))},null,8,["deps","theme","iteratedBodyRow","path","selectedElementPath","context","containerWidth"])):Ue("",!0)]))}}),cut={emptyEmailComponentText:"Product shelf is hidden due to insufficient products",emptyEmailComponentTooltip:"The product shelf won't be displayed to recipients until it contains enough products",requiredComponentNotification:"Without this component the letter will not be sent"},dut={emptyEmailComponentText:"Товарная полка скрыта из-за недостатка товаров",emptyEmailComponentTooltip:"Товарная полка не будет отображаться у получателей письма пока в ней недостаточно товаров",requiredComponentNotification:"Без этого компонента письмо не будет отправлено"},GI=jn({en:cut,ru:dut}),hut={},mut={width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function fut(t,e){return I(),J("svg",mut,[...e[0]||(e[0]=[R("path",{d:"M6.99967 13.6663C3.31777 13.6663 0.333008 10.6815 0.333008 6.99967C0.333008 3.31777 3.31777 0.333008 6.99967 0.333008C10.6815 0.333008 13.6663 3.31777 13.6663 6.99967C13.6663 10.6815 10.6815 13.6663 6.99967 13.6663ZM6.99967 12.333C9.94521 12.333 12.333 9.94521 12.333 6.99967C12.333 4.05415 9.94521 1.66634 6.99967 1.66634C4.05415 1.66634 1.66634 4.05415 1.66634 6.99967C1.66634 9.94521 4.05415 12.333 6.99967 12.333ZM6.33301 3.66634H7.66634V4.99967H6.33301V3.66634ZM6.33301 6.33301H7.66634V10.333H6.33301V6.33301Z",fill:"var(--gray-500)"},null,-1)])])}const put=Qe(hut,[["render",fut]]),gut={key:0},Cut={key:0,class:"is-required-notification"},yut={class:"bootstrap-styles w-100 d-flex justify-content-center gap-5"},but=Ze({__name:"EmailComponent",props:{deps:{},theme:{},emailComponent:{},path:{},selectedElementPath:{}},emits:["onElementClicked","onImageOriginalSizeAdjusted","onImageSizeAdjusted","onColumnWidthAdjusted","onElementUpdatedEvent","onElementRemoved"],setup(t,{emit:e}){const n=t,r=Mt({context:{},ifResult:!n.emailComponent.ContextBuilderExpression,isLoaded:!1}),o={emptyEmailComponentText:GI({localeKey:n.deps.localeKey}).emptyEmailComponentText,emptyEmailComponentTooltip:GI({localeKey:n.deps.localeKey}).emptyEmailComponentTooltip,requiredComponentNotification:GI({localeKey:n.deps.localeKey}).requiredComponentNotification},i=a=>{r.isLoaded=!1,n.deps.dataStructExpressionEvaluator({dataStructBuilderExpression:a,context:{}}).then(l=>{(n.emailComponent.IfExpression?n.deps.boolExpressionEvaluatorDelegate({boolExpression:n.emailComponent.IfExpression,context:l}):Promise.resolve(!0)).then(u=>{r.context=l,r.ifResult=u,r.isLoaded=!0})})};mn(()=>n.emailComponent.ContextBuilderExpression,a=>{a&&i(a)});const s=e;return n.emailComponent.ContextBuilderExpression?i(n.emailComponent.ContextBuilderExpression):r.isLoaded=!0,(a,l)=>r.isLoaded?(I(),J("div",gut,[n.emailComponent.IsRequired?(I(),J("div",Cut,[R("i",null,[ie(put)]),R("span",null,"   "+en(o.requiredComponentNotification),1)])):Ue("",!0),r.ifResult?(I(),J("table",{key:1,style:he([[{backgroundColor:z(Ll)({color:n.emailComponent.InnerBgColor,themeColors:n.theme.Colors})},z(Wu)({borderRadius:n.emailComponent.BorderRadius,borderRadiusCard:n.theme.BorderRadiusCard,bodyBorderRadius:n.theme.BorderRadius,borderButtonRadius:n.theme.BorderRadiusButton,borderBannerRadius:n.theme.BorderRadiusBanner}),{maxWidth:n.theme.BodyWidth+"px"}],{"border-spacing":"0","border-collapse":"collapse",width:"100%",margin:"0 auto"}])},[R("tbody",null,[R("tr",null,[R("td",{class:"row__inner",style:he([z(Cee)({paddings:n.emailComponent.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings,fullWidth:n.emailComponent.FullWidth})])},[(I(!0),J(ot,null,zn(n.emailComponent.BodyRowList,(u,c)=>(I(),et(cbe,{key:c,deps:n.deps.emailComponentBodyRowDeps,theme:n.theme,emailComponentBodyRow:u,context:r.context,rowWidth:n.emailComponent.FullWidth?n.theme.BodyWidth:n.theme.BodyWidth-n.theme.BodyPaddings.Left-n.theme.BodyPaddings.Right,path:[...n.path,"BodyRowList",c],selectedElementPath:n.selectedElementPath,onOnElementClicked:l[0]||(l[0]=d=>s("onElementClicked",d)),onOnImageSizeAdjusted:l[1]||(l[1]=d=>s("onImageSizeAdjusted",d)),onOnImageOriginalSizeAdjusted:l[2]||(l[2]=d=>s("onImageOriginalSizeAdjusted",d)),onOnColumnWidthAdjusted:l[3]||(l[3]=d=>s("onColumnWidthAdjusted",d)),onOnElementUpdatedEvent:l[4]||(l[4]=d=>s("onElementUpdatedEvent",d)),onOnElementRemoved:l[5]||(l[5]=d=>s("onElementRemoved",d))},null,8,["deps","theme","emailComponentBodyRow","context","rowWidth","path","selectedElementPath"]))),128))],4)])])],4)):(I(),J("div",{key:2,class:Me(["empty-email-component",{"is-required-component__paddings":n.emailComponent.IsRequired}])},[rw(en(o.emptyEmailComponentText)+" ",1),It((I(),J("i",null,[...l[6]||(l[6]=[R("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[R("path",{d:"M6.99967 13.6663C3.31777 13.6663 0.333008 10.6815 0.333008 6.99967C0.333008 3.31777 3.31777 0.333008 6.99967 0.333008C10.6815 0.333008 13.6663 3.31777 13.6663 6.99967C13.6663 10.6815 10.6815 13.6663 6.99967 13.6663ZM6.99967 12.333C9.94521 12.333 12.333 9.94521 12.333 6.99967C12.333 4.05415 9.94521 1.66634 6.99967 1.66634C4.05415 1.66634 1.66634 4.05415 1.66634 6.99967C1.66634 9.94521 4.05415 12.333 6.99967 12.333ZM6.33301 3.66634H7.66634V4.99967H6.33301V3.66634ZM6.33301 6.33301H7.66634V10.333H6.33301V6.33301Z",fill:"var(--gray-500)"})],-1)])])),[[z(Br),{placement:"top",title:o.emptyEmailComponentTooltip}]])],2))])):(I(),J("div",{key:1,class:"bootstrap-styles w-100",style:he([z(Cee)({paddings:n.emailComponent.Paddings,themeComponentPaddings:n.theme.ComponentPaddings,themeBodyPaddings:n.theme.BodyPaddings,fullWidth:n.emailComponent.FullWidth}),{backgroundColor:z(Ll)({color:n.emailComponent.InnerBgColor,themeColors:n.theme.Colors})||"transparent"}])},[ie(z($Z),{type:"text"}),R("div",yut,[(I(),J(ot,null,zn(3,u=>ie(z($Z),{key:u,type:"image, text, text, text, button",style:{width:"100%"}})),64))])],4))}}),dbe=Qe(but,[["__scopeId","data-v-38fe975b"]]),vut={class:"scale-to-width-fit-component",style:{display:"inline-block","transform-origin":"left top"}},hbe=Ze({__name:"ScaleToWidthFit",emits:["scaledElement"],setup(t,{emit:e}){const n=e;return(r,o)=>It((I(),J("div",vut,[M0(r.$slots,"default")])),[[z(Jx),({width:i})=>{r.$el.style.transform=`scale(${r.$el.parentElement.clientWidth/i}`,n("scaledElement",r.$el)}]])}}),Tut={title:"Preview",applyButton:"Select",cancelButton:"Cancel"},Fut={title:"Предпросмотр",applyButton:"Выбрать",cancelButton:"Отмена"},YI=jn({en:Tut,ru:Fut}),xut={class:"email-template-preview__inner-padding scrollable"},Sut={class:"emailTemplate-border-top"},wut={class:"emailTemplate-border-bottom"},kut=Ze({__name:"TemplatePreviewModalWindow",props:{template:{},deps:{}},emits:["templateSelected","close"],setup(t,{emit:e}){const n=t,r={title:YI({localeKey:n.deps.localeKey}).title,applyButton:YI({localeKey:n.deps.localeKey}).applyButton,cancelButton:YI({localeKey:n.deps.localeKey}).cancelButton},o=s=>{const a=s.parentElement;a&&(a.style.height=s.getBoundingClientRect().height+"px")},i=e;return(s,a)=>(I(),et(z0e,{headerText:r.title,class:"email-component__preview-modal-window",onClose:a[3]||(a[3]=()=>i("close"))},{body:wu(()=>[R("div",{style:he({backgroundColor:t.template.Theme.Colors.EmailBackgroundColor})},[ie(hbe,{onScaledElement:a[0]||(a[0]=l=>o(l))},{default:wu(()=>[R("div",xut,[R("div",{class:"bootstrap-styles pe-none email-template-preview",style:he({fontFamily:n.template.Theme.FontFamily,width:t.template.Theme.BodyWidth+"px"})},[R("div",{class:"webkit emailTemplate--desktop",style:he({borderTopLeftRadius:n.template.Theme.BorderRadius.TopLeft+"px",borderTopRightRadius:n.template.Theme.BorderRadius.TopRight+"px",borderBottomLeftRadius:n.template.Theme.BorderRadius.BottomLeft+"px",borderBottomRightRadius:n.template.Theme.BorderRadius.BottomRight+"px"})},[R("div",Sut,[R("table",{style:he([[{maxWidth:n.template.Theme.BodyWidth+"px",width:"100%"}],{"border-spacing":"0"}])},[R("tbody",null,[R("tr",null,[R("td",{style:he([{paddingTop:n.template.Theme.BodyPaddings.Top+"px"},{"font-size":"0","line-height":"0"}])},"   ",4)])])],4)]),(I(!0),J(ot,null,zn(n.template.Components,(l,u)=>(I(),J("div",{key:u},[ie(dbe,{deps:t.deps.emailComponentDeps,theme:n.template.Theme,emailComponent:l,path:[],selectedElementPath:[]},null,8,["deps","theme","emailComponent"])]))),128)),R("div",wut,[R("table",{style:he([[{maxWidth:n.template.Theme.BodyWidth+"px",width:"100%"}],{"border-spacing":"0"}])},[R("tbody",null,[R("tr",null,[R("td",{style:he([{paddingBottom:n.template.Theme.BodyPaddings.Bottom+"px"},{"font-size":"0","line-height":"0"}])},"   ",4)])])],4)])],4)],4)])]),_:1})],4)]),"footer-actions":wu(()=>[R("button",{type:"button",class:"modal-footer__button bootstrap-styles d-flex justify-content-center align-center py-1 px-3 me-3 rounded-2 bg-blue-selected button__hover-blue-100 text-color-selected",onClick:a[1]||(a[1]=wr(()=>i("close"),["stop"]))},en(r.cancelButton),1),R("button",{type:"submit",class:"modal-footer__button bootstrap-styles d-flex justify-content-center align-center py-1 px-3 rounded-2 bg-color-selected text-white cursor-pointer button__hover-blue-400",onClick:a[2]||(a[2]=()=>{i("templateSelected",n.template)})},en(r.applyButton),1)]),_:1},8,["headerText"]))}}),Eut=Qe(kut,[["__scopeId","data-v-eb5433f4"]]),Rut={class:"favorite-template-select__item-wrapper"},_ut={class:"favorite-template-select__item bootstrap-styles border rounded-3"},Dut={class:"email-template-preview__inner-padding scrollable"},Aut={class:"emailTemplate-border-top"},$ut={class:"emailTemplate-border-bottom"},Nut=Ze({__name:"TemplatePreviewCard",props:{deps:{},template:{},templateName:{}},emits:["templateSelected"],setup(t,{emit:e}){Pm(k=>({fe9947d8:s.value,v34e7e85f:a.value,v3793be74:i.value.Title.fontWeight,v1a5ad760:i.value.Title.fontFamily,v5b86af14:i.value.Title.color,v2e8d120a:i.value.Title.textDecoration,v70699b96:i.value.Title.fontStyle,v3a1cf2be:l.value,v3a467c89:u.value,v74e45a6c:i.value.Heading.fontWeight,af562894:i.value.Heading.fontFamily,v31de9340:i.value.Heading.color,v4e190b60:i.value.Heading.textDecoration,v16b23b1f:i.value.Heading.fontStyle,v0401dcf4:c.value,e3c7ed5e:d.value,efc37348:i.value.SubHeading.fontWeight,v6ae55f48:i.value.SubHeading.fontFamily,v71e6cf8e:i.value.SubHeading.color,b57d341c:i.value.SubHeading.textDecoration,ad47e566:i.value.SubHeading.fontStyle,v5af2b2c4:h.value,v7cac530f:m.value,v2325bf78:i.value.LargeText.fontWeight,v5d978da0:i.value.LargeText.fontFamily,v02e164a6:i.value.LargeText.color,v33410bda:i.value.LargeText.textDecoration,v62565665:i.value.LargeText.fontStyle,v54d3ba98:f.value,fb2a943a:p.value,v1da52c0a:i.value.NormalText.fontWeight,v006c44f6:i.value.NormalText.fontFamily,v14d2d5c0:i.value.NormalText.color,a73c76c0:i.value.NormalText.textDecoration,c4aa8c42:i.value.NormalText.fontStyle,v735bb105:g.value,v1ecec510:y.value,v02590823:i.value.DescriptionText.fontWeight,v35bfbde2:i.value.DescriptionText.fontFamily,v63cdcd67:i.value.DescriptionText.color,v1d27ec39:i.value.DescriptionText.textDecoration,v316e76a6:i.value.DescriptionText.fontStyle,v6c4cc8de:b.value,c04d6aae:F.value,aefb3c78:i.value.Link.fontWeight,e96d0aa0:i.value.Link.fontFamily,v75e93326:i.value.Link.color,v75d98d5a:i.value.Link.textDecoration,v57d2e4e5:i.value.Link.fontStyle,v6f4d39d4:T.value,v2b2836e1:v.value,v5ecd1d68:i.value.Button.fontWeight,v993eeb90:i.value.Button.fontFamily,v74f88e9e:i.value.Button.color,d564ce3c:i.value.Button.textDecoration,v4057c45d:i.value.Button.fontStyle}));const n=t,r=Mt({isPreviewComponentModalWindowShown:!1}),o=k=>{const _=k.parentElement;_&&(_.style.height=k.getBoundingClientRect().height+"px")},i=q(()=>{const{FontFamily:k,FontSettingsPresets:_,Colors:D}=n.template.Theme;return{Title:us({fontFamily:k,themeFontSettings:_.Title,themeColor:D.TitleColor}),Heading:us({fontFamily:k,themeFontSettings:_.Heading,themeColor:D.HeadingColor}),SubHeading:us({fontFamily:k,themeFontSettings:_.SubHeading,themeColor:D.SubHeadingColor}),LargeText:us({fontFamily:k,themeFontSettings:_.LargeText,themeColor:D.LargeTextColor}),NormalText:us({fontFamily:k,themeFontSettings:_.NormalText,themeColor:D.NormalTextColor}),DescriptionText:us({fontFamily:k,themeFontSettings:_.DescriptionText,themeColor:D.DescriptionTextColor}),Link:us({fontFamily:k,themeFontSettings:_.Link,themeColor:D.LinkColor}),Button:us({fontFamily:k,themeFontSettings:_.Button,themeColor:D.ButtonTextColor})}}),s=q(()=>i.value.Title.fontSize+"px"),a=q(()=>i.value.Title.lineHeight+"px"),l=q(()=>i.value.Heading.fontSize+"px"),u=q(()=>i.value.Heading.lineHeight+"px"),c=q(()=>i.value.SubHeading.fontSize+"px"),d=q(()=>i.value.SubHeading.lineHeight+"px"),h=q(()=>i.value.LargeText.fontSize+"px"),m=q(()=>i.value.LargeText.lineHeight+"px"),f=q(()=>i.value.NormalText.fontSize+"px"),p=q(()=>i.value.NormalText.lineHeight+"px"),g=q(()=>i.value.DescriptionText.fontSize+"px"),y=q(()=>i.value.DescriptionText.lineHeight+"px"),b=q(()=>i.value.Link.fontSize+"px"),F=q(()=>i.value.Link.lineHeight+"px"),T=q(()=>i.value.Button.fontSize+"px"),v=q(()=>i.value.Button.lineHeight+"px"),w=e;return(k,_)=>(I(),J("div",Rut,[R("div",_ut,[R("div",{class:"bootstrap-styles h-100",style:he({backgroundColor:n.template.Theme.Colors.EmailBackgroundColor}),onClick:_[1]||(_[1]=()=>{r.isPreviewComponentModalWindowShown=!0})},[ie(hbe,{onScaledElement:_[0]||(_[0]=D=>o(D))},{default:wu(()=>[R("div",Dut,[R("div",{class:"bootstrap-styles pe-none email-template-preview",style:he({fontFamily:n.template.Theme.FontFamily,width:t.template.Theme.BodyWidth+"px"})},[R("div",{class:"webkit emailTemplate--desktop",style:he({backgroundColor:n.template.Theme.Colors.BodyColor,borderTopLeftRadius:n.template.Theme.BorderRadius.TopLeft+"px",borderTopRightRadius:n.template.Theme.BorderRadius.TopRight+"px",borderBottomLeftRadius:n.template.Theme.BorderRadius.BottomLeft+"px",borderBottomRightRadius:n.template.Theme.BorderRadius.BottomRight+"px"})},[R("div",Aut,[R("table",{style:he([[{maxWidth:n.template.Theme.BodyWidth+"px",width:"100%"}],{"border-spacing":"0"}])},[R("tbody",null,[R("tr",null,[R("td",{style:he([{paddingTop:n.template.Theme.BodyPaddings.Top+"px"},{"font-size":"0","line-height":"0"}])},"   ",4)])])],4)]),(I(!0),J(ot,null,zn(n.template.Components,(D,L)=>(I(),J("div",{key:L},[ie(dbe,{deps:n.deps.emailComponentDeps,theme:n.template.Theme,emailComponent:D,path:[],selectedElementPath:[]},null,8,["deps","theme","emailComponent"])]))),128)),R("div",$ut,[R("table",{style:he([[{maxWidth:n.template.Theme.BodyWidth+"px",width:"100%"}],{"border-spacing":"0"}])},[R("tbody",null,[R("tr",null,[R("td",{style:he([{paddingBottom:n.template.Theme.BodyPaddings.Bottom+"px"},{"font-size":"0","line-height":"0"}])},"   ",4)])])],4)])],4)],4)])]),_:1})],4),(I(),et(Yj,{to:"#app"},[r.isPreviewComponentModalWindowShown?(I(),et(Eut,{key:0,template:n.template,deps:n.deps.templatePreviewModalWindowDeps,onClose:_[2]||(_[2]=()=>r.isPreviewComponentModalWindowShown=!1),onTemplateSelected:_[3]||(_[3]=()=>w("templateSelected",n.template))},null,8,["template","deps"])):Ue("",!0)]))]),R("div",{class:"bootstrap-styles favorite-template__name mt-2",onClick:_[4]||(_[4]=()=>{r.isPreviewComponentModalWindowShown=!0})},en(n.templateName),1)]))}}),But=Qe(Nut,[["__scopeId","data-v-d98cb6f0"]]),Lut={class:"template-selector__list"},Vut={class:"bootstrap-styles mb-3"},Mut=Ze({__name:"TemplatePreviewCardList",props:{templatesPreviewCard:{},deps:{}},emits:["templateSelected"],setup(t,{emit:e}){const n=t,r={newTemplate:o_({localeKey:n.deps.localeKey}).newTemplate},o=e;return(i,s)=>(I(),J("div",Lut,[R("button",{class:"bootstrap-styles d-flex flex-column justify-content-center align-items-center template-selector__new-item overflow-hidden border rounded-3",type:"button",onClick:s[0]||(s[0]=a=>o("templateSelected",n.deps.initialEmailTemplate))},[R("i",Vut,[ie(GGe)]),rw(" "+en(r.newTemplate),1)]),(I(!0),J(ot,null,zn(n.templatesPreviewCard,a=>(I(),J("div",null,[ie(But,{deps:n.deps.templatePreviewCardDeps,template:a.template,templateName:a.templateName,onTemplateSelected:s[1]||(s[1]=l=>o("templateSelected",l))},null,8,["deps","template","templateName"])]))),256))]))}}),Lee=Qe(Mut,[["__scopeId","data-v-f5d903f5"]]),Out={class:"template-gallery bootstrap-styles d-flex flex-column bg-white justify-content-start align-items-center"},Iut=["href"],Put={class:"icon-hover-stroke-black"},Wut={class:"bootstrap-styles mb-11"},Hut={class:"bootstrap-styles template-gallery__tab-list mb-13"},zut=Ze({__name:"TemplatesGallery",props:{commonFavoriteTemplates:{},customFavoriteTemplates:{},deps:{}},emits:["templateSelected"],setup(t,{emit:e}){const n=t,r=n.customFavoriteTemplates.length?"custom":"common",o={title:o_({localeKey:n.deps.localeKey}).title,customFavoritesButton:o_({localeKey:n.deps.localeKey}).customFavoritesButton,commonFavoritesButton:o_({localeKey:n.deps.localeKey}).defaultFavoritesButton},i=Mt({activeTab:r}),s={custom:o.customFavoritesButton,common:o.commonFavoritesButton},a=e;return(l,u)=>(I(),J("div",Out,[R("a",{class:"template-gallery__close",href:n.deps.exitLink},[R("i",Put,[ie(OGe)])],8,Iut),R("h2",Wut,en(o.title),1),R("div",Hut,[ie(UGe,{initialTab:z(r),tabList:s,onOnTabClicked:u[0]||(u[0]=c=>i.activeTab=c)},null,8,["initialTab"])]),It(ie(Lee,{deps:n.deps.templatePreviewCardListDeps,templatesPreviewCard:n.customFavoriteTemplates,onTemplateSelected:u[1]||(u[1]=c=>a("templateSelected",c))},null,8,["deps","templatesPreviewCard"]),[[vH,i.activeTab==="custom"]]),It(ie(Lee,{deps:n.deps.templatePreviewCardListDeps,templatesPreviewCard:n.commonFavoriteTemplates,onTemplateSelected:u[2]||(u[2]=c=>a("templateSelected",c))},null,8,["deps","templatesPreviewCard"]),[[vH,i.activeTab==="common"]])]))}}),jut=Qe(zut,[["__scopeId","data-v-f9070ee7"]]),Gx=t=>({Match:e=>{switch(typeof t){case"string":return(e.String??e.defaultValue)(t);case"number":return(e.Number??e.defaultValue)(t);case"boolean":return(e.Boolean??e.defaultValue)(t);case"object":return Uut(t)?(e.Array??e.defaultValue)(t):(e.Struct??e.defaultValue)(t);default:return ls(t)}}}),Uut=t=>Array.isArray(t),Kut=Wl,Fw=(t,e)=>{let n=e;for(const r of t)n=Kut(r).Match({PropertyName:o=>Gx(n).Match({defaultValue:()=>{throw console.error("Property not found: "+o),new Error("Property not found: "+o)},Struct:i=>i[o]}),ArrayIndex:o=>Gx(n).Match({defaultValue:()=>{throw console.error("Array index out of bounds: "+o),new Error("Array index out of bounds: "+o)},Array:i=>i[o]})});return n},qut=(t,e)=>Gx(Fw(t,e)).Match({defaultValue:()=>{throw console.error("Value is not a number"),new Error("Value is not a number")},Number:n=>n}),Jut=t=>Wl(t),Gut=t=>Wl(t),Yut=t=>Wl(t),Vee=t=>({dataStructBuilderExpression:e,context:n})=>Promise.all(Object.entries(e).map(async([r,o])=>({key:r,value:await t.expressionEvaluator({expression:o,context:n})}))).then(r=>Object.fromEntries(r.map(o=>[o.key,o.value]))),Xut=t=>{const e=({expression:n,context:r})=>{const o=t.dataStructBuilderExpressionEvaluatorFactory(e);return Yut(n).Match({NumberExpression:i=>t.numberExpressionEvaluator({numberExpression:i,context:r}),StringExpression:i=>t.stringExpressionEvaluator({stringExpression:i,context:r}),ListExpression:i=>t.listExpressionEvaluator({listExpression:i,context:r}),RecordBuilderExpression:i=>o({dataStructBuilderExpression:i,context:r})})};return e},Qut=(t,e)=>Gx(Fw(t,e)).Match({defaultValue:()=>{throw console.error("Value is not a list"),new Error("Value is not a list")},Array:n=>n}),Zut=t=>{const e=n=>Jut(n.listExpression).Match({ContextValueExpression:r=>Promise.resolve(Qut(r.Path,n.context)),ChunkExpression:async r=>{const o=await e({listExpression:r.ListExpression,context:n.context});return o.slice(0,Math.floor(o.length/r.ChunkSize)*r.ChunkSize)},LimitExpression:async r=>(await e({listExpression:r.ListExpression,context:n.context})).slice(0,r.Limit),DataSource:r=>t.listExpressionDataSourceEvaluator(r),ConcatListExpressions:async r=>Promise.all(r.ListExpressions.map(o=>e({listExpression:o,context:n.context}))).then(o=>o.flat())});return e},ect=(t,e)=>Gx(Fw(t,e)).Match({defaultValue:()=>{throw console.error("Value is not a string "+e+t),new Error("Value is not a string")},String:n=>n}),mbe=t=>({Match:e=>{switch(typeof t){case"string":return(e.String??e.defaultValue)(t);case"number":return(e.Number??e.defaultValue)(t);case"boolean":return(e.Boolean??e.defaultValue)(t);case"object":return tct(t)?(e.Array??e.defaultValue)(t):(e.Struct??e.defaultValue)(t);default:return e.defaultValue()}}}),tct=t=>Array.isArray(t),nct=t=>mbe(Fw(t.path,t.context)).Match({defaultValue:()=>t.fallbackValue,String:e=>e}),rct=t=>{const e=n=>{const r=t.stringExpressionDataSourceEvaluatorFactory(e);return Z0e(n.stringExpression).Match({ConcatStringExpressions:o=>uct({concatStringExpressions:o,stringExpressionEvaluator:e,context:n.context}),ContextValueExpression:o=>oct({contextValueExpression:o,context:n.context}),ContextValueExpressionWithFallback:o=>ict({contextValueExpressionWithFallback:o,context:n.context}),ConstValueExpression:o=>cct({stringConstValueExpression:o}),TruncateValueExpression:o=>sct({truncateValueExpression:o,context:n.context,stringExpressionEvaluator:e}),DataSource:o=>r({stringExpressionDataSource:o,context:n.context}),NumberToStringExpression:o=>lct({numberToStringExpression:o,context:n.context,numberExpressionEvaluator:t.numberExpressionEvaluator}),UnsubscribeUrlExpression:()=>Promise.resolve("#"),RecipientEmailAddressExpression:()=>Promise.resolve("RecipientEmailAddress")})};return e},oct=t=>Promise.resolve(ect(t.contextValueExpression.Path,t.context)),ict=t=>Promise.resolve(nct({path:t.contextValueExpressionWithFallback.Path,context:t.context,fallbackValue:t.contextValueExpressionWithFallback.FallbackValue})),sct=async t=>{const e=t.truncateValueExpression.MaxLength,n=await t.stringExpressionEvaluator({stringExpression:t.truncateValueExpression.StringExpression,context:t.context});return e<n.length?n.slice(0,t.truncateValueExpression.MaxLength)+t.truncateValueExpression.Tail:n},act=t=>{const e=t.value<0,n=Math.abs(t.value).toString();let[r="",o]=n.split(".");if(t.decimalSeparator===""||t.decimalPadString===""){if(o="",t.decimalSeparator==="")throw new Error("DecimalSeparator cannot be empty");if(t.decimalPadString==="")throw new Error("DecimalPadString cannot be empty")}if(!t.groupSizes||t.groupSizes.length===0)return(e?"-":"")+r+(o?t.decimalSeparator+o:"");t.decimalPadString&&t.decimalPadString!==""&&t.decimalSeparator!==""&&(o?o+=t.decimalPadString.slice(o.length):o=t.decimalPadString);let i="",s=r.length,a=0;for(;s>0;){const u=t.groupSizes[a]??t.groupSizes[t.groupSizes.length-1],c=r.slice(Math.max(0,s-u),s);i?i=c+t.groupSeparator+i:i=c,s-=u,a<t.groupSizes.length-1&&a++}let l=(e?"-":"")+i;return o&&o.length>0&&(l+=t.decimalSeparator+o),l},lct=async t=>{const e=await t.numberExpressionEvaluator({numberExpression:t.numberToStringExpression.NumberExpression,context:t.context});if(t.numberToStringExpression.Format){const n=t.numberToStringExpression.Format;return act({value:e,decimalSeparator:n.DecimalSeparator,groupSeparator:n.GroupSeparator,groupSizes:n.GroupSizes,decimalPadString:n.DecimalPadString})}return e.toString()},uct=t=>Promise.all(t.concatStringExpressions.StringExpressions.map(e=>t.stringExpressionEvaluator({stringExpression:e,context:t.context}))).then(e=>e.join("")),cct=t=>Promise.resolve(t.stringConstValueExpression.Value),dct=t=>mbe(Fw(t.path,t.context)).Match({defaultValue:()=>t.fallbackValue,Number:e=>e}),hct=t=>{const e=n=>{const r=t.numberExpressionDataSourceEvaluator;return Gut(n.numberExpression).Match({ContextValueExpressionWithFallback:o=>Promise.resolve(dct({fallbackValue:o.FallbackValue,path:o.Path,context:n.context})),ContextValueExpression:o=>Promise.resolve(qut(o.Path,n.context)),ConstValueExpression:o=>Promise.resolve(o.Value),ListLengthExpression:async o=>t.listExpressionEvaluator({listExpression:o.ListExpression,context:n.context}).then(i=>i.length),DataSource:o=>r({numberExpressionDataSource:o,context:n.context}),RoundExpression:async o=>e({numberExpression:o.NumberExpression,context:n.context}).then(i=>{const s=Math.pow(10,o.Digits);return Math.round(i*s)/s}),TruncateExpression:async o=>e({numberExpression:o.NumberExpression,context:n.context}).then(i=>{const s=Math.pow(10,o.Precision);return Math.trunc(i*s)/s})})};return e},mct=t=>{const e=document.createElement("form");e.method=t.method,e.action=t.action;for(const[n,r]of t.formData.entries()){if(r instanceof File)continue;const o=document.createElement("input");o.setAttribute("type","text"),o.setAttribute("name",n),o.setAttribute("value",r),e.appendChild(o)}return e},fct=t=>({elementsDeps:t.elementsDeps}),pct=t=>({elementsDeps:t.elementsDeps}),gct=t=>({elementsDeps:t.elementsDeps}),Cct=t=>({iteratedColumnN21Deps:pct({elementsDeps:t.elementsDeps}),iteratedColumnN22Deps:gct({elementsDeps:t.elementsDeps})}),yct=t=>({iteratedColumnDeps:fct({elementsDeps:t.elementsDeps}),iteratedColumnVariantDeps:Cct({elementsDeps:t.elementsDeps}),listExpressionEvaluator:t.listExpressionEvaluator}),bct=t=>({elementsDeps:t.elementsDeps}),vct=t=>({multipleColumnDeps:bct({elementsDeps:t.elementsDeps})}),Tct=t=>({iteratedColumnBodyRowDeps:yct({elementsDeps:t.elementsDeps,listExpressionEvaluator:t.listExpressionEvaluator}),multipleColumnBodyRowDeps:vct({elementsDeps:t.elementsDeps}),listExpressionEvaluator:t.listExpressionEvaluator}),fbe=t=>({localeKey:t.localeKey,emailComponentBodyRowDeps:Tct({elementsDeps:t.elementsDeps,listExpressionEvaluator:t.listExpressionEvaluator}),boolExpressionEvaluatorDelegate:t.boolExpressionEvaluator,dataStructExpressionEvaluator:t.dataStructExpressionEvaluator}),Fct=t=>({expressionEvaluator:t.expressionEvaluator}),xct=t=>({localeKey:t.localeKey}),Sct=t=>({localeKey:t.localeKey}),wct=t=>({localeKey:t.localeKey}),kct=t=>({localeKey:t.localeKey}),Ect=t=>({localeKey:t.localeKey}),Rct=t=>({localeKey:t.localeKey}),_ct=t=>({localeKey:t.localeKey}),Dct=t=>({localeKey:t.localeKey}),Act=t=>({localeKey:t.localeKey,colorPickerModalWindowDeps:Dct({localeKey:t.localeKey})}),$ct=t=>({localeKey:t.localeKey}),Nct=t=>({localeKey:t.localeKey}),Bct=t=>({localeKey:t.localeKey}),Lct=t=>({localeKey:t.localeKey}),Vct=t=>({localeKey:t.localeKey}),Mct=t=>({localeKey:t.localeKey}),Oct=t=>({localeKey:t.localeKey,addLinkModalWindowDeps:Mct({localeKey:t.localeKey})}),Ict=t=>({localeKey:t.localeKey}),Pct=t=>({localeKey:t.localeKey}),Wct=t=>({localeKey:t.localeKey,addImageSrcModalWindowDeps:Pct({localeKey:t.localeKey})}),Hct=t=>({localeKey:t.localeKey}),zct=t=>({localeKey:t.localeKey,richTextToolbarPlugins:t.richTextToolbarPlugins,bulletListEditorDeps:xct({localeKey:t.localeKey}),orderedListEditorDeps:Sct({localeKey:t.localeKey}),contentAlignEditorDeps:wct({localeKey:t.localeKey}),verticalAlignEditorDeps:kct({localeKey:t.localeKey}),fontFamilySelectorDeps:Ect({localeKey:t.localeKey}),fontSizeEditorDeps:Rct({localeKey:t.localeKey}),lineHeightEditorDeps:_ct({localeKey:t.localeKey}),colorPickerDeps:Act({localeKey:t.localeKey}),fontWeightEditorDeps:$ct({localeKey:t.localeKey}),fontStyleEditorDeps:Nct({localeKey:t.localeKey}),lineThroughEditorDeps:Bct({localeKey:t.localeKey}),underlineEditorDeps:Lct({localeKey:t.localeKey}),textTransformEditorDeps:Vct({localeKey:t.localeKey}),linkEditorDeps:Oct({localeKey:t.localeKey}),unsubscribeLinkEditorDeps:Ict({localeKey:t.localeKey}),imageEditorDeps:Wct({localeKey:t.localeKey}),themeSettingsSelectorDeps:Hct({localeKey:t.localeKey})}),jct=t=>({localeKey:t.localeKey}),Uct=t=>({localeKey:t.localeKey,dataSourceFieldNameDelegate:t.dataSourceFieldNameDelegate,richTextToolbarDeps:zct({localeKey:t.localeKey,richTextToolbarPlugins:t.richTextToolbarPlugins}),removeConfirmModalWindowDeps:jct({localeKey:t.localeKey})}),pbe=t=>({richTextDeps:Uct({dataSourceFieldNameDelegate:t.dataSourceFieldNameDelegate,richTextToolbarPlugins:t.richTextToolbarPlugins,localeKey:t.localeKey}),listExpressionEvaluator:t.listExpressionEvaluator,numberExpressionEvaluator:t.numberExpressionEvaluator,stringExpressionEvaluator:t.stringExpressionEvaluator,expressionVueDeps:Fct({expressionEvaluator:t.expressionEvaluator}),boolExpressionEvaluator:t.boolExpressionEvaluator}),{entries:gbe,setPrototypeOf:Mee,isFrozen:Kct,getPrototypeOf:qct,getOwnPropertyDescriptor:Jct}=Object;let{freeze:Ei,seal:Wa,create:$z}=Object,{apply:Nz,construct:Bz}=typeof Reflect<"u"&&Reflect;Ei||(Ei=function(t){return t});Wa||(Wa=function(t){return t});Nz||(Nz=function(t,e){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return t.apply(e,r)});Bz||(Bz=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return new t(...n)});const Xk=Ri(Array.prototype.forEach),Gct=Ri(Array.prototype.lastIndexOf),Oee=Ri(Array.prototype.pop),o1=Ri(Array.prototype.push),Yct=Ri(Array.prototype.splice),d_=Ri(String.prototype.toLowerCase),XI=Ri(String.prototype.toString),QI=Ri(String.prototype.match),i1=Ri(String.prototype.replace),Xct=Ri(String.prototype.indexOf),Qct=Ri(String.prototype.trim),Cl=Ri(Object.prototype.hasOwnProperty),Uo=Ri(RegExp.prototype.test),s1=Zct(TypeError);function Ri(t){return function(e){e instanceof RegExp&&(e.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 Nz(t,e,r)}}function Zct(t){return function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return Bz(t,n)}}function Wt(t,e){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:d_;Mee&&Mee(t,null);let r=e.length;for(;r--;){let o=e[r];if(typeof o=="string"){const i=n(o);i!==o&&(Kct(e)||(e[r]=i),o=i)}t[o]=!0}return t}function edt(t){for(let e=0;e<t.length;e++)Cl(t,e)||(t[e]=null);return t}function tu(t){const e=$z(null);for(const[n,r]of gbe(t))Cl(t,n)&&(Array.isArray(r)?e[n]=edt(r):r&&typeof r=="object"&&r.constructor===Object?e[n]=tu(r):e[n]=r);return e}function a1(t,e){for(;t!==null;){const r=Jct(t,e);if(r){if(r.get)return Ri(r.get);if(typeof r.value=="function")return Ri(r.value)}t=qct(t)}function n(){return null}return n}const Iee=Ei(["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"]),ZI=Ei(["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"]),e2=Ei(["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"]),tdt=Ei(["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"]),t2=Ei(["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"]),ndt=Ei(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Pee=Ei(["#text"]),Wee=Ei(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),n2=Ei(["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"]),Hee=Ei(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Qk=Ei(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),rdt=Wa(/\{\{[\w\W]*|[\w\W]*\}\}/gm),odt=Wa(/<%[\w\W]*|[\w\W]*%>/gm),idt=Wa(/\$\{[\w\W]*/gm),sdt=Wa(/^data-[\-\w.\u00B7-\uFFFF]+$/),adt=Wa(/^aria-[\-\w]+$/),Cbe=Wa(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ldt=Wa(/^(?:\w+script|data):/i),udt=Wa(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ybe=Wa(/^html$/i),cdt=Wa(/^[a-z][.\w]*(-[.\w]+)+$/i);var zee=Object.freeze({__proto__:null,ARIA_ATTR:adt,ATTR_WHITESPACE:udt,CUSTOM_ELEMENT:cdt,DATA_ATTR:sdt,DOCTYPE_NAME:ybe,ERB_EXPR:odt,IS_ALLOWED_URI:Cbe,IS_SCRIPT_OR_DATA:ldt,MUSTACHE_EXPR:rdt,TMPLIT_EXPR:idt});const l1={element:1,text:3,progressingInstruction:7,comment:8,document:9},ddt=function(){return typeof window>"u"?null:window},hdt=function(t,e){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let n=null;const r="data-tt-policy-suffix";e&&e.hasAttribute(r)&&(n=e.getAttribute(r));const o="dompurify"+(n?"#"+n:"");try{return t.createPolicy(o,{createHTML(i){return i},createScriptURL(i){return i}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}},jee=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function bbe(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ddt();const e=C=>bbe(C);if(e.version="3.3.1",e.removed=[],!t||!t.document||t.document.nodeType!==l1.document||!t.Element)return e.isSupported=!1,e;let{document:n}=t;const r=n,o=r.currentScript,{DocumentFragment:i,HTMLTemplateElement:s,Node:a,Element:l,NodeFilter:u,NamedNodeMap:c=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:d,DOMParser:h,trustedTypes:m}=t,f=l.prototype,p=a1(f,"cloneNode"),g=a1(f,"remove"),y=a1(f,"nextSibling"),b=a1(f,"childNodes"),F=a1(f,"parentNode");if(typeof s=="function"){const C=n.createElement("template");C.content&&C.content.ownerDocument&&(n=C.content.ownerDocument)}let T,v="";const{implementation:w,createNodeIterator:k,createDocumentFragment:_,getElementsByTagName:D}=n,{importNode:L}=r;let E=jee();e.isSupported=typeof gbe=="function"&&typeof F=="function"&&w&&w.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:A,ERB_EXPR:$,TMPLIT_EXPR:M,DATA_ATTR:O,ARIA_ATTR:V,IS_SCRIPT_OR_DATA:H,ATTR_WHITESPACE:Re,CUSTOM_ELEMENT:Pe}=zee;let{IS_ALLOWED_URI:Te}=zee,K=null;const We=Wt({},[...Iee,...ZI,...e2,...t2,...Pee]);let Y=null;const He=Wt({},[...Wee,...n2,...Hee,...Qk]);let P=Object.seal($z(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}})),_e=null,ae=null;const ne=Object.seal($z(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Et=!0,Tt=!0,gt=!1,N=!0,B=!1,j=!0,G=!1,Q=!1,Z=!1,te=!1,re=!1,U=!1,X=!0,Oe=!1;const ce="user-content-";let ue=!0,de=!1,Fe={},le=null;const ze=Wt({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let un=null;const cn=Wt({},["audio","video","img","source","image","track"]);let rn=null;const bn=Wt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),tn="http://www.w3.org/1998/Math/MathML",dn="http://www.w3.org/2000/svg",Ke="http://www.w3.org/1999/xhtml";let ft=Ke,Dn=!1,An=null;const ul=Wt({},[tn,dn,Ke],XI);let gn=Wt({},["mi","mo","mn","ms","mtext"]),Cn=Wt({},["annotation-xml"]);const cl=Wt({},["title","style","font","a","script"]);let nn=null;const dl=["application/xhtml+xml","text/html"],hl="text/html";let oe=null,_t=null;const ml=n.createElement("form"),so=function(C){return C instanceof RegExp||C instanceof Function},Qn=function(){let C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(_t&&_t===C)){if((!C||typeof C!="object")&&(C={}),C=tu(C),nn=dl.indexOf(C.PARSER_MEDIA_TYPE)===-1?hl:C.PARSER_MEDIA_TYPE,oe=nn==="application/xhtml+xml"?XI:d_,K=Cl(C,"ALLOWED_TAGS")?Wt({},C.ALLOWED_TAGS,oe):We,Y=Cl(C,"ALLOWED_ATTR")?Wt({},C.ALLOWED_ATTR,oe):He,An=Cl(C,"ALLOWED_NAMESPACES")?Wt({},C.ALLOWED_NAMESPACES,XI):ul,rn=Cl(C,"ADD_URI_SAFE_ATTR")?Wt(tu(bn),C.ADD_URI_SAFE_ATTR,oe):bn,un=Cl(C,"ADD_DATA_URI_TAGS")?Wt(tu(cn),C.ADD_DATA_URI_TAGS,oe):cn,le=Cl(C,"FORBID_CONTENTS")?Wt({},C.FORBID_CONTENTS,oe):ze,_e=Cl(C,"FORBID_TAGS")?Wt({},C.FORBID_TAGS,oe):tu({}),ae=Cl(C,"FORBID_ATTR")?Wt({},C.FORBID_ATTR,oe):tu({}),Fe=Cl(C,"USE_PROFILES")?C.USE_PROFILES:!1,Et=C.ALLOW_ARIA_ATTR!==!1,Tt=C.ALLOW_DATA_ATTR!==!1,gt=C.ALLOW_UNKNOWN_PROTOCOLS||!1,N=C.ALLOW_SELF_CLOSE_IN_ATTR!==!1,B=C.SAFE_FOR_TEMPLATES||!1,j=C.SAFE_FOR_XML!==!1,G=C.WHOLE_DOCUMENT||!1,te=C.RETURN_DOM||!1,re=C.RETURN_DOM_FRAGMENT||!1,U=C.RETURN_TRUSTED_TYPE||!1,Z=C.FORCE_BODY||!1,X=C.SANITIZE_DOM!==!1,Oe=C.SANITIZE_NAMED_PROPS||!1,ue=C.KEEP_CONTENT!==!1,de=C.IN_PLACE||!1,Te=C.ALLOWED_URI_REGEXP||Cbe,ft=C.NAMESPACE||Ke,gn=C.MATHML_TEXT_INTEGRATION_POINTS||gn,Cn=C.HTML_INTEGRATION_POINTS||Cn,P=C.CUSTOM_ELEMENT_HANDLING||{},C.CUSTOM_ELEMENT_HANDLING&&so(C.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(P.tagNameCheck=C.CUSTOM_ELEMENT_HANDLING.tagNameCheck),C.CUSTOM_ELEMENT_HANDLING&&so(C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(P.attributeNameCheck=C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),C.CUSTOM_ELEMENT_HANDLING&&typeof C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(P.allowCustomizedBuiltInElements=C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),B&&(Tt=!1),re&&(te=!0),Fe&&(K=Wt({},Pee),Y=[],Fe.html===!0&&(Wt(K,Iee),Wt(Y,Wee)),Fe.svg===!0&&(Wt(K,ZI),Wt(Y,n2),Wt(Y,Qk)),Fe.svgFilters===!0&&(Wt(K,e2),Wt(Y,n2),Wt(Y,Qk)),Fe.mathMl===!0&&(Wt(K,t2),Wt(Y,Hee),Wt(Y,Qk))),C.ADD_TAGS&&(typeof C.ADD_TAGS=="function"?ne.tagCheck=C.ADD_TAGS:(K===We&&(K=tu(K)),Wt(K,C.ADD_TAGS,oe))),C.ADD_ATTR&&(typeof C.ADD_ATTR=="function"?ne.attributeCheck=C.ADD_ATTR:(Y===He&&(Y=tu(Y)),Wt(Y,C.ADD_ATTR,oe))),C.ADD_URI_SAFE_ATTR&&Wt(rn,C.ADD_URI_SAFE_ATTR,oe),C.FORBID_CONTENTS&&(le===ze&&(le=tu(le)),Wt(le,C.FORBID_CONTENTS,oe)),C.ADD_FORBID_CONTENTS&&(le===ze&&(le=tu(le)),Wt(le,C.ADD_FORBID_CONTENTS,oe)),ue&&(K["#text"]=!0),G&&Wt(K,["html","head","body"]),K.table&&(Wt(K,["tbody"]),delete _e.tbody),C.TRUSTED_TYPES_POLICY){if(typeof C.TRUSTED_TYPES_POLICY.createHTML!="function")throw s1('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof C.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw s1('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');T=C.TRUSTED_TYPES_POLICY,v=T.createHTML("")}else T===void 0&&(T=hdt(m,o)),T!==null&&typeof v=="string"&&(v=T.createHTML(""));Ei&&Ei(C),_t=C}},ao=Wt({},[...ZI,...e2,...tdt]),lo=Wt({},[...t2,...ndt]),fl=function(C){let x=F(C);(!x||!x.tagName)&&(x={namespaceURI:ft,tagName:"template"});const S=d_(C.tagName),W=d_(x.tagName);return An[C.namespaceURI]?C.namespaceURI===dn?x.namespaceURI===Ke?S==="svg":x.namespaceURI===tn?S==="svg"&&(W==="annotation-xml"||gn[W]):!!ao[S]:C.namespaceURI===tn?x.namespaceURI===Ke?S==="math":x.namespaceURI===dn?S==="math"&&Cn[W]:!!lo[S]:C.namespaceURI===Ke?x.namespaceURI===dn&&!Cn[W]||x.namespaceURI===tn&&!gn[W]?!1:!lo[S]&&(cl[S]||!ao[S]):!!(nn==="application/xhtml+xml"&&An[C.namespaceURI]):!1},Ct=function(C){o1(e.removed,{element:C});try{F(C).removeChild(C)}catch{g(C)}},xt=function(C,x){try{o1(e.removed,{attribute:x.getAttributeNode(C),from:x})}catch{o1(e.removed,{attribute:null,from:x})}if(x.removeAttribute(C),C==="is")if(te||re)try{Ct(x)}catch{}else try{x.setAttribute(C,"")}catch{}},uo=function(C){let x=null,S=null;if(Z)C="<remove></remove>"+C;else{const ee=QI(C,/^[\r\n\t ]+/);S=ee&&ee[0]}nn==="application/xhtml+xml"&&ft===Ke&&(C='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+C+"</body></html>");const W=T?T.createHTML(C):C;if(ft===Ke)try{x=new h().parseFromString(W,nn)}catch{}if(!x||!x.documentElement){x=w.createDocument(ft,"template",null);try{x.documentElement.innerHTML=Dn?v:W}catch{}}const se=x.body||x.documentElement;return C&&S&&se.insertBefore(n.createTextNode(S),se.childNodes[0]||null),ft===Ke?D.call(x,G?"html":"body")[0]:G?x.documentElement:se},co=function(C){return k.call(C.ownerDocument||C,C,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},Zn=function(C){return C instanceof d&&(typeof C.nodeName!="string"||typeof C.textContent!="string"||typeof C.removeChild!="function"||!(C.attributes instanceof c)||typeof C.removeAttribute!="function"||typeof C.setAttribute!="function"||typeof C.namespaceURI!="string"||typeof C.insertBefore!="function"||typeof C.hasChildNodes!="function")},ho=function(C){return typeof a=="function"&&C instanceof a};function it(C,x,S){Xk(C,W=>{W.call(e,x,S,_t)})}const mo=function(C){let x=null;if(it(E.beforeSanitizeElements,C,null),Zn(C))return Ct(C),!0;const S=oe(C.nodeName);if(it(E.uponSanitizeElement,C,{tagName:S,allowedTags:K}),j&&C.hasChildNodes()&&!ho(C.firstElementChild)&&Uo(/<[/\w!]/g,C.innerHTML)&&Uo(/<[/\w!]/g,C.textContent)||C.nodeType===l1.progressingInstruction||j&&C.nodeType===l1.comment&&Uo(/<[/\w]/g,C.data))return Ct(C),!0;if(!(ne.tagCheck instanceof Function&&ne.tagCheck(S))&&(!K[S]||_e[S])){if(!_e[S]&&po(S)&&(P.tagNameCheck instanceof RegExp&&Uo(P.tagNameCheck,S)||P.tagNameCheck instanceof Function&&P.tagNameCheck(S)))return!1;if(ue&&!le[S]){const W=F(C)||C.parentNode,se=b(C)||C.childNodes;if(se&&W){const ee=se.length;for(let qe=ee-1;qe>=0;--qe){const je=p(se[qe],!0);je.__removalCount=(C.__removalCount||0)+1,W.insertBefore(je,y(C))}}}return Ct(C),!0}return C instanceof l&&!fl(C)||(S==="noscript"||S==="noembed"||S==="noframes")&&Uo(/<\/no(script|embed|frames)/i,C.innerHTML)?(Ct(C),!0):(B&&C.nodeType===l1.text&&(x=C.textContent,Xk([A,$,M],W=>{x=i1(x,W," ")}),C.textContent!==x&&(o1(e.removed,{element:C.cloneNode()}),C.textContent=x)),it(E.afterSanitizeElements,C,null),!1)},fo=function(C,x,S){if(X&&(x==="id"||x==="name")&&(S in n||S in ml))return!1;if(!(Tt&&!ae[x]&&Uo(O,x))&&!(Et&&Uo(V,x))&&!(ne.attributeCheck instanceof Function&&ne.attributeCheck(x,C))){if(!Y[x]||ae[x]){if(!(po(C)&&(P.tagNameCheck instanceof RegExp&&Uo(P.tagNameCheck,C)||P.tagNameCheck instanceof Function&&P.tagNameCheck(C))&&(P.attributeNameCheck instanceof RegExp&&Uo(P.attributeNameCheck,x)||P.attributeNameCheck instanceof Function&&P.attributeNameCheck(x,C))||x==="is"&&P.allowCustomizedBuiltInElements&&(P.tagNameCheck instanceof RegExp&&Uo(P.tagNameCheck,S)||P.tagNameCheck instanceof Function&&P.tagNameCheck(S))))return!1}else if(!rn[x]&&!Uo(Te,i1(S,Re,""))&&!((x==="src"||x==="xlink:href"||x==="href")&&C!=="script"&&Xct(S,"data:")===0&&un[C])&&!(gt&&!Uo(H,i1(S,Re,"")))&&S)return!1}return!0},po=function(C){return C!=="annotation-xml"&&QI(C,Pe)},go=function(C){it(E.beforeSanitizeAttributes,C,null);const{attributes:x}=C;if(!x||Zn(C))return;const S={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Y,forceKeepAttr:void 0};let W=x.length;for(;W--;){const se=x[W],{name:ee,namespaceURI:qe,value:je}=se,Xe=oe(ee),$n=je;let De=ee==="value"?$n:Qct($n);if(S.attrName=Xe,S.attrValue=De,S.keepAttr=!0,S.forceKeepAttr=void 0,it(E.uponSanitizeAttribute,C,S),De=S.attrValue,Oe&&(Xe==="id"||Xe==="name")&&(xt(ee,C),De=ce+De),j&&Uo(/((--!?|])>)|<\/(style|title|textarea)/i,De)){xt(ee,C);continue}if(Xe==="attributename"&&QI(De,"href")){xt(ee,C);continue}if(S.forceKeepAttr)continue;if(!S.keepAttr){xt(ee,C);continue}if(!N&&Uo(/\/>/i,De)){xt(ee,C);continue}B&&Xk([A,$,M],sa=>{De=i1(De,sa," ")});const hn=oe(C.nodeName);if(!fo(hn,Xe,De)){xt(ee,C);continue}if(T&&typeof m=="object"&&typeof m.getAttributeType=="function"&&!qe)switch(m.getAttributeType(hn,Xe)){case"TrustedHTML":{De=T.createHTML(De);break}case"TrustedScriptURL":{De=T.createScriptURL(De);break}}if(De!==$n)try{qe?C.setAttributeNS(qe,ee,De):C.setAttribute(ee,De),Zn(C)?Ct(C):Oee(e.removed)}catch{xt(ee,C)}}it(E.afterSanitizeAttributes,C,null)},pl=function C(x){let S=null;const W=co(x);for(it(E.beforeSanitizeShadowDOM,x,null);S=W.nextNode();)it(E.uponSanitizeShadowNode,S,null),mo(S),go(S),S.content instanceof i&&C(S.content);it(E.afterSanitizeShadowDOM,x,null)};return e.sanitize=function(C){let x=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},S=null,W=null,se=null,ee=null;if(Dn=!C,Dn&&(C="<!-->"),typeof C!="string"&&!ho(C))if(typeof C.toString=="function"){if(C=C.toString(),typeof C!="string")throw s1("dirty is not a string, aborting")}else throw s1("toString is not a function");if(!e.isSupported)return C;if(Q||Qn(x),e.removed=[],typeof C=="string"&&(de=!1),de){if(C.nodeName){const Xe=oe(C.nodeName);if(!K[Xe]||_e[Xe])throw s1("root node is forbidden and cannot be sanitized in-place")}}else if(C instanceof a)S=uo("<!---->"),W=S.ownerDocument.importNode(C,!0),W.nodeType===l1.element&&W.nodeName==="BODY"||W.nodeName==="HTML"?S=W:S.appendChild(W);else{if(!te&&!B&&!G&&C.indexOf("<")===-1)return T&&U?T.createHTML(C):C;if(S=uo(C),!S)return te?null:U?v:""}S&&Z&&Ct(S.firstChild);const qe=co(de?C:S);for(;se=qe.nextNode();)mo(se),go(se),se.content instanceof i&&pl(se.content);if(de)return C;if(te){if(re)for(ee=_.call(S.ownerDocument);S.firstChild;)ee.appendChild(S.firstChild);else ee=S;return(Y.shadowroot||Y.shadowrootmode)&&(ee=L.call(r,ee,!0)),ee}let je=G?S.outerHTML:S.innerHTML;return G&&K["!doctype"]&&S.ownerDocument&&S.ownerDocument.doctype&&S.ownerDocument.doctype.name&&Uo(ybe,S.ownerDocument.doctype.name)&&(je="<!DOCTYPE "+S.ownerDocument.doctype.name+`>
148
148
  `+je),B&&Xk([A,$,M],Xe=>{je=i1(je,Xe," ")}),T&&U?T.createHTML(je):je},e.setConfig=function(){let C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Qn(C),Q=!0},e.clearConfig=function(){_t=null,Q=!1},e.isValidAttribute=function(C,x,S){_t||Qn({});const W=oe(C),se=oe(x);return fo(W,se,S)},e.addHook=function(C,x){typeof x=="function"&&o1(E[C],x)},e.removeHook=function(C,x){if(x!==void 0){const S=Gct(E[C],x);return S===-1?void 0:Yct(E[C],S,1)[0]}return Oee(E[C])},e.removeHooks=function(C){E[C]=[]},e.removeAllHooks=function(){E=jee()},e}bbe();function yo(t){this.content=t}yo.prototype={constructor:yo,find:function(t){for(var e=0;e<this.content.length;e+=2)if(this.content[e]===t)return e;return-1},get:function(t){var e=this.find(t);return e==-1?void 0:this.content[e+1]},update:function(t,e,n){var r=n&&n!=t?this.remove(n):this,o=r.find(t),i=r.content.slice();return o==-1?i.push(n||t,e):(i[o+1]=e,n&&(i[o]=n)),new yo(i)},remove:function(t){var e=this.find(t);if(e==-1)return this;var n=this.content.slice();return n.splice(e,2),new yo(n)},addToStart:function(t,e){return new yo([t,e].concat(this.remove(t).content))},addToEnd:function(t,e){var n=this.remove(t).content.slice();return n.push(t,e),new yo(n)},addBefore:function(t,e,n){var r=this.remove(e),o=r.content.slice(),i=r.find(t);return o.splice(i==-1?o.length:i,0,e,n),new yo(o)},forEach:function(t){for(var e=0;e<this.content.length;e+=2)t(this.content[e],this.content[e+1])},prepend:function(t){return t=yo.from(t),t.size?new yo(t.content.concat(this.subtract(t).content)):this},append:function(t){return t=yo.from(t),t.size?new yo(this.subtract(t).content.concat(t.content)):this},subtract:function(t){var e=this;t=yo.from(t);for(var n=0;n<t.content.length;n+=2)e=e.remove(t.content[n]);return e},toObject:function(){var t={};return this.forEach(function(e,n){t[e]=n}),t},get size(){return this.content.length>>1}};yo.from=function(t){if(t instanceof yo)return t;var e=[];if(t)for(var n in t)e.push(n,t[n]);return new yo(e)};function vbe(t,e,n){for(let r=0;;r++){if(r==t.childCount||r==e.childCount)return t.childCount==e.childCount?null:n;let o=t.child(r),i=e.child(r);if(o==i){n+=o.nodeSize;continue}if(!o.sameMarkup(i))return n;if(o.isText&&o.text!=i.text){for(let s=0;o.text[s]==i.text[s];s++)n++;return n}if(o.content.size||i.content.size){let s=vbe(o.content,i.content,n+1);if(s!=null)return s}n+=o.nodeSize}}function Tbe(t,e,n,r){for(let o=t.childCount,i=e.childCount;;){if(o==0||i==0)return o==i?null:{a:n,b:r};let s=t.child(--o),a=e.child(--i),l=s.nodeSize;if(s==a){n-=l,r-=l;continue}if(!s.sameMarkup(a))return{a:n,b:r};if(s.isText&&s.text!=a.text){let u=0,c=Math.min(s.text.length,a.text.length);for(;u<c&&s.text[s.text.length-u-1]==a.text[a.text.length-u-1];)u++,n--,r--;return{a:n,b:r}}if(s.content.size||a.content.size){let u=Tbe(s.content,a.content,n-1,r-1);if(u)return u}n-=l,r-=l}}class xe{constructor(e,n){if(this.content=e,this.size=n||0,n==null)for(let r=0;r<e.length;r++)this.size+=e[r].nodeSize}nodesBetween(e,n,r,o=0,i){for(let s=0,a=0;a<n;s++){let l=this.content[s],u=a+l.nodeSize;if(u>e&&r(l,o+a,i||null,s)!==!1&&l.content.size){let c=a+1;l.nodesBetween(Math.max(0,e-c),Math.min(l.content.size,n-c),r,o+c)}a=u}}descendants(e){this.nodesBetween(0,this.size,e)}textBetween(e,n,r,o){let i="",s=!0;return this.nodesBetween(e,n,(a,l)=>{let u=a.isText?a.text.slice(Math.max(e,l)-l,n-l):a.isLeaf?o?typeof o=="function"?o(a):o:a.type.spec.leafText?a.type.spec.leafText(a):"":"";a.isBlock&&(a.isLeaf&&u||a.isTextblock)&&r&&(s?s=!1:i+=r),i+=u},0),i}append(e){if(!e.size)return this;if(!this.size)return e;let n=this.lastChild,r=e.firstChild,o=this.content.slice(),i=0;for(n.isText&&n.sameMarkup(r)&&(o[o.length-1]=n.withText(n.text+r.text),i=1);i<e.content.length;i++)o.push(e.content[i]);return new xe(o,this.size+e.size)}cut(e,n=this.size){if(e==0&&n==this.size)return this;let r=[],o=0;if(n>e)for(let i=0,s=0;s<n;i++){let a=this.content[i],l=s+a.nodeSize;l>e&&((s<e||l>n)&&(a.isText?a=a.cut(Math.max(0,e-s),Math.min(a.text.length,n-s)):a=a.cut(Math.max(0,e-s-1),Math.min(a.content.size,n-s-1))),r.push(a),o+=a.nodeSize),s=l}return new xe(r,o)}cutByIndex(e,n){return e==n?xe.empty:e==0&&n==this.content.length?this:new xe(this.content.slice(e,n))}replaceChild(e,n){let r=this.content[e];if(r==n)return this;let o=this.content.slice(),i=this.size+n.nodeSize-r.nodeSize;return o[e]=n,new xe(o,i)}addToStart(e){return new xe([e].concat(this.content),this.size+e.nodeSize)}addToEnd(e){return new xe(this.content.concat(e),this.size+e.nodeSize)}eq(e){if(this.content.length!=e.content.length)return!1;for(let n=0;n<this.content.length;n++)if(!this.content[n].eq(e.content[n]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(e){let n=this.content[e];if(!n)throw new RangeError("Index "+e+" out of range for "+this);return n}maybeChild(e){return this.content[e]||null}forEach(e){for(let n=0,r=0;n<this.content.length;n++){let o=this.content[n];e(o,r,n),r+=o.nodeSize}}findDiffStart(e,n=0){return vbe(this,e,n)}findDiffEnd(e,n=this.size,r=e.size){return Tbe(this,e,n,r)}findIndex(e){if(e==0)return Zk(0,e);if(e==this.size)return Zk(this.content.length,e);if(e>this.size||e<0)throw new RangeError(`Position ${e} outside of fragment (${this})`);for(let n=0,r=0;;n++){let o=this.child(n),i=r+o.nodeSize;if(i>=e)return i==e?Zk(n+1,i):Zk(n,r);r=i}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(e=>e.toJSON()):null}static fromJSON(e,n){if(!n)return xe.empty;if(!Array.isArray(n))throw new RangeError("Invalid input for Fragment.fromJSON");return new xe(n.map(e.nodeFromJSON))}static fromArray(e){if(!e.length)return xe.empty;let n,r=0;for(let o=0;o<e.length;o++){let i=e[o];r+=i.nodeSize,o&&i.isText&&e[o-1].sameMarkup(i)?(n||(n=e.slice(0,o)),n[n.length-1]=i.withText(n[n.length-1].text+i.text)):n&&n.push(i)}return new xe(n||e,r)}static from(e){if(!e)return xe.empty;if(e instanceof xe)return e;if(Array.isArray(e))return this.fromArray(e);if(e.attrs)return new xe([e],e.nodeSize);throw new RangeError("Can not convert "+e+" to a Fragment"+(e.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}xe.empty=new xe([],0);const r2={index:0,offset:0};function Zk(t,e){return r2.index=t,r2.offset=e,r2}function NA(t,e){if(t===e)return!0;if(!(t&&typeof t=="object")||!(e&&typeof e=="object"))return!1;let n=Array.isArray(t);if(Array.isArray(e)!=n)return!1;if(n){if(t.length!=e.length)return!1;for(let r=0;r<t.length;r++)if(!NA(t[r],e[r]))return!1}else{for(let r in t)if(!(r in e)||!NA(t[r],e[r]))return!1;for(let r in e)if(!(r in t))return!1}return!0}let Un=class Lz{constructor(e,n){this.type=e,this.attrs=n}addToSet(e){let n,r=!1;for(let o=0;o<e.length;o++){let i=e[o];if(this.eq(i))return e;if(this.type.excludes(i.type))n||(n=e.slice(0,o));else{if(i.type.excludes(this.type))return e;!r&&i.type.rank>this.type.rank&&(n||(n=e.slice(0,o)),n.push(this),r=!0),n&&n.push(i)}}return n||(n=e.slice()),r||n.push(this),n}removeFromSet(e){for(let n=0;n<e.length;n++)if(this.eq(e[n]))return e.slice(0,n).concat(e.slice(n+1));return e}isInSet(e){for(let n=0;n<e.length;n++)if(this.eq(e[n]))return!0;return!1}eq(e){return this==e||this.type==e.type&&NA(this.attrs,e.attrs)}toJSON(){let e={type:this.type.name};for(let n in this.attrs){e.attrs=this.attrs;break}return e}static fromJSON(e,n){if(!n)throw new RangeError("Invalid input for Mark.fromJSON");let r=e.marks[n.type];if(!r)throw new RangeError(`There is no mark type ${n.type} in this schema`);let o=r.create(n.attrs);return r.checkAttrs(o.attrs),o}static sameSet(e,n){if(e==n)return!0;if(e.length!=n.length)return!1;for(let r=0;r<e.length;r++)if(!e[r].eq(n[r]))return!1;return!0}static setFrom(e){if(!e||Array.isArray(e)&&e.length==0)return Lz.none;if(e instanceof Lz)return[e];let n=e.slice();return n.sort((r,o)=>r.type.rank-o.type.rank),n}};Un.none=[];let BA=class extends Error{},tt=class Cy{constructor(e,n,r){this.content=e,this.openStart=n,this.openEnd=r}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(e,n){let r=xbe(this.content,e+this.openStart,n);return r&&new Cy(r,this.openStart,this.openEnd)}removeBetween(e,n){return new Cy(Fbe(this.content,e+this.openStart,n+this.openStart),this.openStart,this.openEnd)}eq(e){return this.content.eq(e.content)&&this.openStart==e.openStart&&this.openEnd==e.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let e={content:this.content.toJSON()};return this.openStart>0&&(e.openStart=this.openStart),this.openEnd>0&&(e.openEnd=this.openEnd),e}static fromJSON(e,n){if(!n)return Cy.empty;let r=n.openStart||0,o=n.openEnd||0;if(typeof r!="number"||typeof o!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new Cy(xe.fromJSON(e,n.content),r,o)}static maxOpen(e,n=!0){let r=0,o=0;for(let i=e.firstChild;i&&!i.isLeaf&&(n||!i.type.spec.isolating);i=i.firstChild)r++;for(let i=e.lastChild;i&&!i.isLeaf&&(n||!i.type.spec.isolating);i=i.lastChild)o++;return new Cy(e,r,o)}};tt.empty=new tt(xe.empty,0,0);function Fbe(t,e,n){let{index:r,offset:o}=t.findIndex(e),i=t.maybeChild(r),{index:s,offset:a}=t.findIndex(n);if(o==e||i.isText){if(a!=n&&!t.child(s).isText)throw new RangeError("Removing non-flat range");return t.cut(0,e).append(t.cut(n))}if(r!=s)throw new RangeError("Removing non-flat range");return t.replaceChild(r,i.copy(Fbe(i.content,e-o-1,n-o-1)))}function xbe(t,e,n,r){let{index:o,offset:i}=t.findIndex(e),s=t.maybeChild(o);if(i==e||s.isText)return r&&!r.canReplace(o,o,n)?null:t.cut(0,e).append(n).append(t.cut(e));let a=xbe(s.content,e-i-1,n,s);return a&&t.replaceChild(o,s.copy(a))}function mdt(t,e,n){if(n.openStart>t.depth)throw new BA("Inserted content deeper than insertion position");if(t.depth-n.openStart!=e.depth-n.openEnd)throw new BA("Inconsistent open depths");return Sbe(t,e,n,0)}function Sbe(t,e,n,r){let o=t.index(r),i=t.node(r);if(o==e.index(r)&&r<t.depth-n.openStart){let s=Sbe(t,e,n,r+1);return i.copy(i.content.replaceChild(o,s))}else if(n.content.size)if(!n.openStart&&!n.openEnd&&t.depth==r&&e.depth==r){let s=t.parent,a=s.content;return Dp(s,a.cut(0,t.parentOffset).append(n.content).append(a.cut(e.parentOffset)))}else{let{start:s,end:a}=fdt(n,t);return Dp(i,kbe(t,s,a,e,r))}else return Dp(i,LA(t,e,r))}function wbe(t,e){if(!e.type.compatibleContent(t.type))throw new BA("Cannot join "+e.type.name+" onto "+t.type.name)}function Vz(t,e,n){let r=t.node(n);return wbe(r,e.node(n)),r}function _p(t,e){let n=e.length-1;n>=0&&t.isText&&t.sameMarkup(e[n])?e[n]=t.withText(e[n].text+t.text):e.push(t)}function lF(t,e,n,r){let o=(e||t).node(n),i=0,s=e?e.index(n):o.childCount;t&&(i=t.index(n),t.depth>n?i++:t.textOffset&&(_p(t.nodeAfter,r),i++));for(let a=i;a<s;a++)_p(o.child(a),r);e&&e.depth==n&&e.textOffset&&_p(e.nodeBefore,r)}function Dp(t,e){return t.type.checkContent(e),t.copy(e)}function kbe(t,e,n,r,o){let i=t.depth>o&&Vz(t,e,o+1),s=r.depth>o&&Vz(n,r,o+1),a=[];return lF(null,t,o,a),i&&s&&e.index(o)==n.index(o)?(wbe(i,s),_p(Dp(i,kbe(t,e,n,r,o+1)),a)):(i&&_p(Dp(i,LA(t,e,o+1)),a),lF(e,n,o,a),s&&_p(Dp(s,LA(n,r,o+1)),a)),lF(r,null,o,a),new xe(a)}function LA(t,e,n){let r=[];if(lF(null,t,n,r),t.depth>n){let o=Vz(t,e,n+1);_p(Dp(o,LA(t,e,n+1)),r)}return lF(e,null,n,r),new xe(r)}function fdt(t,e){let n=e.depth-t.openStart,r=e.node(n).copy(t.content);for(let o=n-1;o>=0;o--)r=e.node(o).copy(xe.from(r));return{start:r.resolveNoCache(t.openStart+n),end:r.resolveNoCache(r.content.size-t.openEnd-n)}}let Uee=class Mz{constructor(e,n,r){this.pos=e,this.path=n,this.parentOffset=r,this.depth=n.length/3-1}resolveDepth(e){return e==null?this.depth:e<0?this.depth+e:e}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(e){return this.path[this.resolveDepth(e)*3]}index(e){return this.path[this.resolveDepth(e)*3+1]}indexAfter(e){return e=this.resolveDepth(e),this.index(e)+(e==this.depth&&!this.textOffset?0:1)}start(e){return e=this.resolveDepth(e),e==0?0:this.path[e*3-1]+1}end(e){return e=this.resolveDepth(e),this.start(e)+this.node(e).content.size}before(e){if(e=this.resolveDepth(e),!e)throw new RangeError("There is no position before the top-level node");return e==this.depth+1?this.pos:this.path[e*3-1]}after(e){if(e=this.resolveDepth(e),!e)throw new RangeError("There is no position after the top-level node");return e==this.depth+1?this.pos:this.path[e*3-1]+this.path[e*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let e=this.parent,n=this.index(this.depth);if(n==e.childCount)return null;let r=this.pos-this.path[this.path.length-1],o=e.child(n);return r?e.child(n).cut(r):o}get nodeBefore(){let e=this.index(this.depth),n=this.pos-this.path[this.path.length-1];return n?this.parent.child(e).cut(0,n):e==0?null:this.parent.child(e-1)}posAtIndex(e,n){n=this.resolveDepth(n);let r=this.path[n*3],o=n==0?0:this.path[n*3-1]+1;for(let i=0;i<e;i++)o+=r.child(i).nodeSize;return o}marks(){let e=this.parent,n=this.index();if(e.content.size==0)return Un.none;if(this.textOffset)return e.child(n).marks;let r=e.maybeChild(n-1),o=e.maybeChild(n);if(!r){let a=r;r=o,o=a}let i=r.marks;for(var s=0;s<i.length;s++)i[s].type.spec.inclusive===!1&&(!o||!i[s].isInSet(o.marks))&&(i=i[s--].removeFromSet(i));return i}marksAcross(e){let n=this.parent.maybeChild(this.index());if(!n||!n.isInline)return null;let r=n.marks,o=e.parent.maybeChild(e.index());for(var i=0;i<r.length;i++)r[i].type.spec.inclusive===!1&&(!o||!r[i].isInSet(o.marks))&&(r=r[i--].removeFromSet(r));return r}sharedDepth(e){for(let n=this.depth;n>0;n--)if(this.start(n)<=e&&this.end(n)>=e)return n;return 0}blockRange(e=this,n){if(e.pos<this.pos)return e.blockRange(this);for(let r=this.depth-(this.parent.inlineContent||this.pos==e.pos?1:0);r>=0;r--)if(e.pos<=this.end(r)&&(!n||n(this.node(r))))return new VA(this,e,r);return null}sameParent(e){return this.pos-this.parentOffset==e.pos-e.parentOffset}max(e){return e.pos>this.pos?e:this}min(e){return e.pos<this.pos?e:this}toString(){let e="";for(let n=1;n<=this.depth;n++)e+=(e?"/":"")+this.node(n).type.name+"_"+this.index(n-1);return e+":"+this.parentOffset}static resolve(e,n){if(!(n>=0&&n<=e.content.size))throw new RangeError("Position "+n+" out of range");let r=[],o=0,i=n;for(let s=e;;){let{index:a,offset:l}=s.content.findIndex(i),u=i-l;if(r.push(s,a,o+l),!u||(s=s.child(a),s.isText))break;i=u-1,o+=l+1}return new Mz(n,r,i)}static resolveCached(e,n){let r=Kee.get(e);if(r)for(let i=0;i<r.elts.length;i++){let s=r.elts[i];if(s.pos==n)return s}else Kee.set(e,r=new pdt);let o=r.elts[r.i]=Mz.resolve(e,n);return r.i=(r.i+1)%gdt,o}},pdt=class{constructor(){this.elts=[],this.i=0}};const gdt=12,Kee=new WeakMap;let VA=class{constructor(e,n,r){this.$from=e,this.$to=n,this.depth=r}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}};const Cdt=Object.create(null);let Ap=class Oz{constructor(e,n,r,o=Un.none){this.type=e,this.attrs=n,this.marks=o,this.content=r||xe.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(e){return this.content.child(e)}maybeChild(e){return this.content.maybeChild(e)}forEach(e){this.content.forEach(e)}nodesBetween(e,n,r,o=0){this.content.nodesBetween(e,n,r,o,this)}descendants(e){this.nodesBetween(0,this.content.size,e)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(e,n,r,o){return this.content.textBetween(e,n,r,o)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(e){return this==e||this.sameMarkup(e)&&this.content.eq(e.content)}sameMarkup(e){return this.hasMarkup(e.type,e.attrs,e.marks)}hasMarkup(e,n,r){return this.type==e&&NA(this.attrs,n||e.defaultAttrs||Cdt)&&Un.sameSet(this.marks,r||Un.none)}copy(e=null){return e==this.content?this:new Oz(this.type,this.attrs,e,this.marks)}mark(e){return e==this.marks?this:new Oz(this.type,this.attrs,this.content,e)}cut(e,n=this.content.size){return e==0&&n==this.content.size?this:this.copy(this.content.cut(e,n))}slice(e,n=this.content.size,r=!1){if(e==n)return tt.empty;let o=this.resolve(e),i=this.resolve(n),s=r?0:o.sharedDepth(n),a=o.start(s),l=o.node(s).content.cut(o.pos-a,i.pos-a);return new tt(l,o.depth-s,i.depth-s)}replace(e,n,r){return mdt(this.resolve(e),this.resolve(n),r)}nodeAt(e){for(let n=this;;){let{index:r,offset:o}=n.content.findIndex(e);if(n=n.maybeChild(r),!n)return null;if(o==e||n.isText)return n;e-=o+1}}childAfter(e){let{index:n,offset:r}=this.content.findIndex(e);return{node:this.content.maybeChild(n),index:n,offset:r}}childBefore(e){if(e==0)return{node:null,index:0,offset:0};let{index:n,offset:r}=this.content.findIndex(e);if(r<e)return{node:this.content.child(n),index:n,offset:r};let o=this.content.child(n-1);return{node:o,index:n-1,offset:r-o.nodeSize}}resolve(e){return Uee.resolveCached(this,e)}resolveNoCache(e){return Uee.resolve(this,e)}rangeHasMark(e,n,r){let o=!1;return n>e&&this.nodesBetween(e,n,i=>(r.isInSet(i.marks)&&(o=!0),!o)),o}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let e=this.type.name;return this.content.size&&(e+="("+this.content.toStringInner()+")"),Ebe(this.marks,e)}contentMatchAt(e){let n=this.type.contentMatch.matchFragment(this.content,0,e);if(!n)throw new Error("Called contentMatchAt on a node with invalid content");return n}canReplace(e,n,r=xe.empty,o=0,i=r.childCount){let s=this.contentMatchAt(e).matchFragment(r,o,i),a=s&&s.matchFragment(this.content,n);if(!a||!a.validEnd)return!1;for(let l=o;l<i;l++)if(!this.type.allowsMarks(r.child(l).marks))return!1;return!0}canReplaceWith(e,n,r,o){if(o&&!this.type.allowsMarks(o))return!1;let i=this.contentMatchAt(e).matchType(r),s=i&&i.matchFragment(this.content,n);return s?s.validEnd:!1}canAppend(e){return e.content.size?this.canReplace(this.childCount,this.childCount,e.content):this.type.compatibleContent(e.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let e=Un.none;for(let n=0;n<this.marks.length;n++){let r=this.marks[n];r.type.checkAttrs(r.attrs),e=r.addToSet(e)}if(!Un.sameSet(e,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(n=>n.type.name)}`);this.content.forEach(n=>n.check())}toJSON(){let e={type:this.type.name};for(let n in this.attrs){e.attrs=this.attrs;break}return this.content.size&&(e.content=this.content.toJSON()),this.marks.length&&(e.marks=this.marks.map(n=>n.toJSON())),e}static fromJSON(e,n){if(!n)throw new RangeError("Invalid input for Node.fromJSON");let r;if(n.marks){if(!Array.isArray(n.marks))throw new RangeError("Invalid mark data for Node.fromJSON");r=n.marks.map(e.markFromJSON)}if(n.type=="text"){if(typeof n.text!="string")throw new RangeError("Invalid text node in JSON");return e.text(n.text,r)}let o=xe.fromJSON(e,n.content),i=e.nodeType(n.type).create(n.attrs,o,r);return i.type.checkAttrs(i.attrs),i}};Ap.prototype.text=void 0;let ydt=class Iz extends Ap{constructor(e,n,r,o){if(super(e,n,null,o),!r)throw new RangeError("Empty text nodes are not allowed");this.text=r}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):Ebe(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(e,n){return this.text.slice(e,n)}get nodeSize(){return this.text.length}mark(e){return e==this.marks?this:new Iz(this.type,this.attrs,this.text,e)}withText(e){return e==this.text?this:new Iz(this.type,this.attrs,e,this.marks)}cut(e=0,n=this.text.length){return e==0&&n==this.text.length?this:this.withText(this.text.slice(e,n))}eq(e){return this.sameMarkup(e)&&this.text==e.text}toJSON(){let e=super.toJSON();return e.text=this.text,e}};function Ebe(t,e){for(let n=t.length-1;n>=0;n--)e=t[n].type.name+"("+e+")";return e}let Yx=class Rbe{constructor(e){this.validEnd=e,this.next=[],this.wrapCache=[]}static parse(e,n){let r=new bdt(e,n);if(r.next==null)return Rbe.empty;let o=_be(r);r.next&&r.err("Unexpected trailing text");let i=kdt(wdt(o));return Edt(i,r),i}matchType(e){for(let n=0;n<this.next.length;n++)if(this.next[n].type==e)return this.next[n].next;return null}matchFragment(e,n=0,r=e.childCount){let o=this;for(let i=n;o&&i<r;i++)o=o.matchType(e.child(i).type);return o}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let e=0;e<this.next.length;e++){let{type:n}=this.next[e];if(!(n.isText||n.hasRequiredAttrs()))return n}return null}compatible(e){for(let n=0;n<this.next.length;n++)for(let r=0;r<e.next.length;r++)if(this.next[n].type==e.next[r].type)return!0;return!1}fillBefore(e,n=!1,r=0){let o=[this];function i(s,a){let l=s.matchFragment(e,r);if(l&&(!n||l.validEnd))return xe.from(a.map(u=>u.createAndFill()));for(let u=0;u<s.next.length;u++){let{type:c,next:d}=s.next[u];if(!(c.isText||c.hasRequiredAttrs())&&o.indexOf(d)==-1){o.push(d);let h=i(d,a.concat(c));if(h)return h}}return null}return i(this,[])}findWrapping(e){for(let r=0;r<this.wrapCache.length;r+=2)if(this.wrapCache[r]==e)return this.wrapCache[r+1];let n=this.computeWrapping(e);return this.wrapCache.push(e,n),n}computeWrapping(e){let n=Object.create(null),r=[{match:this,type:null,via:null}];for(;r.length;){let o=r.shift(),i=o.match;if(i.matchType(e)){let s=[];for(let a=o;a.type;a=a.via)s.push(a.type);return s.reverse()}for(let s=0;s<i.next.length;s++){let{type:a,next:l}=i.next[s];!a.isLeaf&&!a.hasRequiredAttrs()&&!(a.name in n)&&(!o.type||l.validEnd)&&(r.push({match:a.contentMatch,type:a,via:o}),n[a.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(e){if(e>=this.next.length)throw new RangeError(`There's no ${e}th edge in this content match`);return this.next[e]}toString(){let e=[];function n(r){e.push(r);for(let o=0;o<r.next.length;o++)e.indexOf(r.next[o].next)==-1&&n(r.next[o].next)}return n(this),e.map((r,o)=>{let i=o+(r.validEnd?"*":" ")+" ";for(let s=0;s<r.next.length;s++)i+=(s?", ":"")+r.next[s].type.name+"->"+e.indexOf(r.next[s].next);return i}).join(`
149
149
  `)}};Yx.empty=new Yx(!0);let bdt=class{constructor(e,n){this.string=e,this.nodeTypes=n,this.inline=null,this.pos=0,this.tokens=e.split(/\s*(?=\b|\W|$)/),this.tokens[this.tokens.length-1]==""&&this.tokens.pop(),this.tokens[0]==""&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(e){return this.next==e&&(this.pos++||!0)}err(e){throw new SyntaxError(e+" (in content expression '"+this.string+"')")}};function _be(t){let e=[];do e.push(vdt(t));while(t.eat("|"));return e.length==1?e[0]:{type:"choice",exprs:e}}function vdt(t){let e=[];do e.push(Tdt(t));while(t.next&&t.next!=")"&&t.next!="|");return e.length==1?e[0]:{type:"seq",exprs:e}}function Tdt(t){let e=Sdt(t);for(;;)if(t.eat("+"))e={type:"plus",expr:e};else if(t.eat("*"))e={type:"star",expr:e};else if(t.eat("?"))e={type:"opt",expr:e};else if(t.eat("{"))e=Fdt(t,e);else break;return e}function qee(t){/\D/.test(t.next)&&t.err("Expected number, got '"+t.next+"'");let e=Number(t.next);return t.pos++,e}function Fdt(t,e){let n=qee(t),r=n;return t.eat(",")&&(t.next!="}"?r=qee(t):r=-1),t.eat("}")||t.err("Unclosed braced range"),{type:"range",min:n,max:r,expr:e}}function xdt(t,e){let n=t.nodeTypes,r=n[e];if(r)return[r];let o=[];for(let i in n){let s=n[i];s.isInGroup(e)&&o.push(s)}return o.length==0&&t.err("No node type or group '"+e+"' found"),o}function Sdt(t){if(t.eat("(")){let e=_be(t);return t.eat(")")||t.err("Missing closing paren"),e}else if(/\W/.test(t.next))t.err("Unexpected token '"+t.next+"'");else{let e=xdt(t,t.next).map(n=>(t.inline==null?t.inline=n.isInline:t.inline!=n.isInline&&t.err("Mixing inline and block content"),{type:"name",value:n}));return t.pos++,e.length==1?e[0]:{type:"choice",exprs:e}}}function wdt(t){let e=[[]];return o(i(t,0),n()),e;function n(){return e.push([])-1}function r(s,a,l){let u={term:l,to:a};return e[s].push(u),u}function o(s,a){s.forEach(l=>l.to=a)}function i(s,a){if(s.type=="choice")return s.exprs.reduce((l,u)=>l.concat(i(u,a)),[]);if(s.type=="seq")for(let l=0;;l++){let u=i(s.exprs[l],a);if(l==s.exprs.length-1)return u;o(u,a=n())}else if(s.type=="star"){let l=n();return r(a,l),o(i(s.expr,l),l),[r(l)]}else if(s.type=="plus"){let l=n();return o(i(s.expr,a),l),o(i(s.expr,l),l),[r(l)]}else{if(s.type=="opt")return[r(a)].concat(i(s.expr,a));if(s.type=="range"){let l=a;for(let u=0;u<s.min;u++){let c=n();o(i(s.expr,l),c),l=c}if(s.max==-1)o(i(s.expr,l),l);else for(let u=s.min;u<s.max;u++){let c=n();r(l,c),o(i(s.expr,l),c),l=c}return[r(l)]}else{if(s.type=="name")return[r(a,void 0,s.value)];throw new Error("Unknown expr type")}}}}function Dbe(t,e){return e-t}function Jee(t,e){let n=[];return r(e),n.sort(Dbe);function r(o){let i=t[o];if(i.length==1&&!i[0].term)return r(i[0].to);n.push(o);for(let s=0;s<i.length;s++){let{term:a,to:l}=i[s];!a&&n.indexOf(l)==-1&&r(l)}}}function kdt(t){let e=Object.create(null);return n(Jee(t,0));function n(r){let o=[];r.forEach(s=>{t[s].forEach(({term:a,to:l})=>{if(!a)return;let u;for(let c=0;c<o.length;c++)o[c][0]==a&&(u=o[c][1]);Jee(t,l).forEach(c=>{u||o.push([a,u=[]]),u.indexOf(c)==-1&&u.push(c)})})});let i=e[r.join(",")]=new Yx(r.indexOf(t.length-1)>-1);for(let s=0;s<o.length;s++){let a=o[s][1].sort(Dbe);i.next.push({type:o[s][0],next:e[a.join(",")]||n(a)})}return i}}function Edt(t,e){for(let n=0,r=[t];n<r.length;n++){let o=r[n],i=!o.validEnd,s=[];for(let a=0;a<o.next.length;a++){let{type:l,next:u}=o.next[a];s.push(l.name),i&&!(l.isText||l.hasRequiredAttrs())&&(i=!1),r.indexOf(u)==-1&&r.push(u)}i&&e.err("Only non-generatable nodes ("+s.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}function Abe(t){let e=Object.create(null);for(let n in t){let r=t[n];if(!r.hasDefault)return null;e[n]=r.default}return e}function $be(t,e){let n=Object.create(null);for(let r in t){let o=e&&e[r];if(o===void 0){let i=t[r];if(i.hasDefault)o=i.default;else throw new RangeError("No value supplied for attribute "+r)}n[r]=o}return n}function Nbe(t,e,n,r){for(let o in e)if(!(o in t))throw new RangeError(`Unsupported attribute ${o} for ${n} of type ${o}`);for(let o in t){let i=t[o];i.validate&&i.validate(e[o])}}function Bbe(t,e){let n=Object.create(null);if(e)for(let r in e)n[r]=new _dt(t,r,e[r]);return n}let Gee=class Lbe{constructor(e,n,r){this.name=e,this.schema=n,this.spec=r,this.markSet=null,this.groups=r.group?r.group.split(" "):[],this.attrs=Bbe(e,r.attrs),this.defaultAttrs=Abe(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(r.inline||e=="text"),this.isText=e=="text"}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==Yx.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}isInGroup(e){return this.groups.indexOf(e)>-1}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let e in this.attrs)if(this.attrs[e].isRequired)return!0;return!1}compatibleContent(e){return this==e||this.contentMatch.compatible(e.contentMatch)}computeAttrs(e){return!e&&this.defaultAttrs?this.defaultAttrs:$be(this.attrs,e)}create(e=null,n,r){if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new Ap(this,this.computeAttrs(e),xe.from(n),Un.setFrom(r))}createChecked(e=null,n,r){return n=xe.from(n),this.checkContent(n),new Ap(this,this.computeAttrs(e),n,Un.setFrom(r))}createAndFill(e=null,n,r){if(e=this.computeAttrs(e),n=xe.from(n),n.size){let s=this.contentMatch.fillBefore(n);if(!s)return null;n=s.append(n)}let o=this.contentMatch.matchFragment(n),i=o&&o.fillBefore(xe.empty,!0);return i?new Ap(this,e,n.append(i),Un.setFrom(r)):null}validContent(e){let n=this.contentMatch.matchFragment(e);if(!n||!n.validEnd)return!1;for(let r=0;r<e.childCount;r++)if(!this.allowsMarks(e.child(r).marks))return!1;return!0}checkContent(e){if(!this.validContent(e))throw new RangeError(`Invalid content for node ${this.name}: ${e.toString().slice(0,50)}`)}checkAttrs(e){Nbe(this.attrs,e,"node",this.name)}allowsMarkType(e){return this.markSet==null||this.markSet.indexOf(e)>-1}allowsMarks(e){if(this.markSet==null)return!0;for(let n=0;n<e.length;n++)if(!this.allowsMarkType(e[n].type))return!1;return!0}allowedMarks(e){if(this.markSet==null)return e;let n;for(let r=0;r<e.length;r++)this.allowsMarkType(e[r].type)?n&&n.push(e[r]):n||(n=e.slice(0,r));return n?n.length?n:Un.none:e}static compile(e,n){let r=Object.create(null);e.forEach((i,s)=>r[i]=new Lbe(i,n,s));let o=n.spec.topNode||"doc";if(!r[o])throw new RangeError("Schema is missing its top node type ('"+o+"')");if(!r.text)throw new RangeError("Every schema needs a 'text' type");for(let i in r.text.attrs)throw new RangeError("The text node type should not have attributes");return r}};function Rdt(t,e,n){let r=n.split("|");return o=>{let i=o===null?"null":typeof o;if(r.indexOf(i)<0)throw new RangeError(`Expected value of type ${r} for attribute ${e} on type ${t}, got ${i}`)}}let _dt=class{constructor(e,n,r){this.hasDefault=Object.prototype.hasOwnProperty.call(r,"default"),this.default=r.default,this.validate=typeof r.validate=="string"?Rdt(e,n,r.validate):r.validate}get isRequired(){return!this.hasDefault}},Vbe=class Mbe{constructor(e,n,r,o){this.name=e,this.rank=n,this.schema=r,this.spec=o,this.attrs=Bbe(e,o.attrs),this.excluded=null;let i=Abe(this.attrs);this.instance=i?new Un(this,i):null}create(e=null){return!e&&this.instance?this.instance:new Un(this,$be(this.attrs,e))}static compile(e,n){let r=Object.create(null),o=0;return e.forEach((i,s)=>r[i]=new Mbe(i,o++,n,s)),r}removeFromSet(e){for(var n=0;n<e.length;n++)e[n].type==this&&(e=e.slice(0,n).concat(e.slice(n+1)),n--);return e}isInSet(e){for(let n=0;n<e.length;n++)if(e[n].type==this)return e[n]}checkAttrs(e){Nbe(this.attrs,e,"mark",this.name)}excludes(e){return this.excluded.indexOf(e)>-1}},Ddt=class{constructor(e){this.linebreakReplacement=null,this.cached=Object.create(null);let n=this.spec={};for(let o in e)n[o]=e[o];n.nodes=yo.from(e.nodes),n.marks=yo.from(e.marks||{}),this.nodes=Gee.compile(this.spec.nodes,this),this.marks=Vbe.compile(this.spec.marks,this);let r=Object.create(null);for(let o in this.nodes){if(o in this.marks)throw new RangeError(o+" can not be both a node and a mark");let i=this.nodes[o],s=i.spec.content||"",a=i.spec.marks;if(i.contentMatch=r[s]||(r[s]=Yx.parse(s,this.nodes)),i.inlineContent=i.contentMatch.inlineContent,i.spec.linebreakReplacement){if(this.linebreakReplacement)throw new RangeError("Multiple linebreak nodes defined");if(!i.isInline||!i.isLeaf)throw new RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=i}i.markSet=a=="_"?null:a?Yee(this,a.split(" ")):a==""||!i.inlineContent?[]:null}for(let o in this.marks){let i=this.marks[o],s=i.spec.excludes;i.excluded=s==null?[i]:s==""?[]:Yee(this,s.split(" "))}this.nodeFromJSON=o=>Ap.fromJSON(this,o),this.markFromJSON=o=>Un.fromJSON(this,o),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(e,n=null,r,o){if(typeof e=="string")e=this.nodeType(e);else if(e instanceof Gee){if(e.schema!=this)throw new RangeError("Node type from different schema used ("+e.name+")")}else throw new RangeError("Invalid node type: "+e);return e.createChecked(n,r,o)}text(e,n){let r=this.nodes.text;return new ydt(r,r.defaultAttrs,e,Un.setFrom(n))}mark(e,n){return typeof e=="string"&&(e=this.marks[e]),e.create(n)}nodeType(e){let n=this.nodes[e];if(!n)throw new RangeError("Unknown node type: "+e);return n}};function Yee(t,e){let n=[];for(let r=0;r<e.length;r++){let o=e[r],i=t.marks[o],s=i;if(i)n.push(i);else for(let a in t.marks){let l=t.marks[a];(o=="_"||l.spec.group&&l.spec.group.split(" ").indexOf(o)>-1)&&n.push(s=l)}if(!s)throw new SyntaxError("Unknown mark type: '"+e[r]+"'")}return n}function Adt(t){return t.tag!=null}function $dt(t){return t.style!=null}let h_=class Pz{constructor(e,n){this.schema=e,this.rules=n,this.tags=[],this.styles=[];let r=this.matchedStyles=[];n.forEach(o=>{if(Adt(o))this.tags.push(o);else if($dt(o)){let i=/[^=]*/.exec(o.style)[0];r.indexOf(i)<0&&r.push(i),this.styles.push(o)}}),this.normalizeLists=!this.tags.some(o=>{if(!/^(ul|ol)\b/.test(o.tag)||!o.node)return!1;let i=e.nodes[o.node];return i.contentMatch.matchType(i)})}parse(e,n={}){let r=new Qee(this,n,!1);return r.addAll(e,Un.none,n.from,n.to),r.finish()}parseSlice(e,n={}){let r=new Qee(this,n,!0);return r.addAll(e,Un.none,n.from,n.to),tt.maxOpen(r.finish())}matchTag(e,n,r){for(let o=r?this.tags.indexOf(r)+1:0;o<this.tags.length;o++){let i=this.tags[o];if(Ldt(e,i.tag)&&(i.namespace===void 0||e.namespaceURI==i.namespace)&&(!i.context||n.matchesContext(i.context))){if(i.getAttrs){let s=i.getAttrs(e);if(s===!1)continue;i.attrs=s||void 0}return i}}}matchStyle(e,n,r,o){for(let i=o?this.styles.indexOf(o)+1:0;i<this.styles.length;i++){let s=this.styles[i],a=s.style;if(!(a.indexOf(e)!=0||s.context&&!r.matchesContext(s.context)||a.length>e.length&&(a.charCodeAt(e.length)!=61||a.slice(e.length+1)!=n))){if(s.getAttrs){let l=s.getAttrs(n);if(l===!1)continue;s.attrs=l||void 0}return s}}}static schemaRules(e){let n=[];function r(o){let i=o.priority==null?50:o.priority,s=0;for(;s<n.length;s++){let a=n[s];if((a.priority==null?50:a.priority)<i)break}n.splice(s,0,o)}for(let o in e.marks){let i=e.marks[o].spec.parseDOM;i&&i.forEach(s=>{r(s=Zee(s)),s.mark||s.ignore||s.clearMark||(s.mark=o)})}for(let o in e.nodes){let i=e.nodes[o].spec.parseDOM;i&&i.forEach(s=>{r(s=Zee(s)),s.node||s.ignore||s.mark||(s.node=o)})}return n}static fromSchema(e){return e.cached.domParser||(e.cached.domParser=new Pz(e,Pz.schemaRules(e)))}};const Obe={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},Ndt={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},Ibe={ol:!0,ul:!0},Xx=1,Wz=2,uF=4;function Xee(t,e,n){return e!=null?(e?Xx:0)|(e==="full"?Wz:0):t&&t.whitespace=="pre"?Xx|Wz:n&~uF}let eE=class{constructor(e,n,r,o,i,s){this.type=e,this.attrs=n,this.marks=r,this.solid=o,this.options=s,this.content=[],this.activeMarks=Un.none,this.match=i||(s&uF?null:e.contentMatch)}findWrapping(e){if(!this.match){if(!this.type)return[];let n=this.type.contentMatch.fillBefore(xe.from(e));if(n)this.match=this.type.contentMatch.matchFragment(n);else{let r=this.type.contentMatch,o;return(o=r.findWrapping(e.type))?(this.match=r,o):null}}return this.match.findWrapping(e.type)}finish(e){if(!(this.options&Xx)){let r=this.content[this.content.length-1],o;if(r&&r.isText&&(o=/[ \t\r\n\u000c]+$/.exec(r.text))){let i=r;r.text.length==o[0].length?this.content.pop():this.content[this.content.length-1]=i.withText(i.text.slice(0,i.text.length-o[0].length))}}let n=xe.from(this.content);return!e&&this.match&&(n=n.append(this.match.fillBefore(xe.empty,!0))),this.type?this.type.create(this.attrs,n,this.marks):n}inlineContext(e){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:e.parentNode&&!Obe.hasOwnProperty(e.parentNode.nodeName.toLowerCase())}},Qee=class{constructor(e,n,r){this.parser=e,this.options=n,this.isOpen=r,this.open=0,this.localPreserveWS=!1;let o=n.topNode,i,s=Xee(null,n.preserveWhitespace,0)|(r?uF:0);o?i=new eE(o.type,o.attrs,Un.none,!0,n.topMatch||o.type.contentMatch,s):r?i=new eE(null,null,Un.none,!0,null,s):i=new eE(e.schema.topNodeType,null,Un.none,!0,null,s),this.nodes=[i],this.find=n.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(e,n){e.nodeType==3?this.addTextNode(e,n):e.nodeType==1&&this.addElement(e,n)}addTextNode(e,n){let r=e.nodeValue,o=this.top,i=o.options&Wz?"full":this.localPreserveWS||(o.options&Xx)>0,{schema:s}=this.parser;if(i==="full"||o.inlineContext(e)||/[^ \t\r\n\u000c]/.test(r)){if(i)if(i==="full")r=r.replace(/\r\n?/g,`
150
150
  `);else if(s.linebreakReplacement&&/[\r\n]/.test(r)&&this.top.findWrapping(s.linebreakReplacement.create())){let a=r.split(/\r?\n|\r/);for(let l=0;l<a.length;l++)l&&this.insertNode(s.linebreakReplacement.create(),n,!0),a[l]&&this.insertNode(s.text(a[l]),n,!/\S/.test(a[l]));r=""}else r=r.replace(/\r?\n|\r/g," ");else if(r=r.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(r)&&this.open==this.nodes.length-1){let a=o.content[o.content.length-1],l=e.previousSibling;(!a||l&&l.nodeName=="BR"||a.isText&&/[ \t\r\n\u000c]$/.test(a.text))&&(r=r.slice(1))}r&&this.insertNode(s.text(r),n,!/\S/.test(r)),this.findInText(e)}else this.findInside(e)}addElement(e,n,r){let o=this.localPreserveWS,i=this.top;(e.tagName=="PRE"||/pre/.test(e.style&&e.style.whiteSpace))&&(this.localPreserveWS=!0);let s=e.nodeName.toLowerCase(),a;Ibe.hasOwnProperty(s)&&this.parser.normalizeLists&&Bdt(e);let l=this.options.ruleFromNode&&this.options.ruleFromNode(e)||(a=this.parser.matchTag(e,this,r));e:if(l?l.ignore:Ndt.hasOwnProperty(s))this.findInside(e),this.ignoreFallback(e,n);else if(!l||l.skip||l.closeParent){l&&l.closeParent?this.open=Math.max(0,this.open-1):l&&l.skip.nodeType&&(e=l.skip);let u,c=this.needsBlock;if(Obe.hasOwnProperty(s))i.content.length&&i.content[0].isInline&&this.open&&(this.open--,i=this.top),u=!0,i.type||(this.needsBlock=!0);else if(!e.firstChild){this.leafFallback(e,n);break e}let d=l&&l.skip?n:this.readStyles(e,n);d&&this.addAll(e,d),u&&this.sync(i),this.needsBlock=c}else{let u=this.readStyles(e,n);u&&this.addElementByRule(e,l,u,l.consuming===!1?a:void 0)}this.localPreserveWS=o}leafFallback(e,n){e.nodeName=="BR"&&this.top.type&&this.top.type.inlineContent&&this.addTextNode(e.ownerDocument.createTextNode(`