@creaditor/web-starterkit 1.0.62 → 1.0.64

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/dist/2655.creaditor.bundle.js +16 -0
  2. package/dist/2655.creaditor.bundle.js.gz +0 -0
  3. package/dist/3521.creaditor.bundle.js +2 -11
  4. package/dist/3521.creaditor.bundle.js.gz +0 -0
  5. package/dist/3600.creaditor.bundle.js +1 -0
  6. package/dist/3600.creaditor.bundle.js.gz +0 -0
  7. package/dist/3847.creaditor.bundle.js +116 -69
  8. package/dist/3847.creaditor.bundle.js.gz +0 -0
  9. package/dist/4000.creaditor.bundle.js +1 -0
  10. package/dist/4000.creaditor.bundle.js.gz +0 -0
  11. package/dist/5884.creaditor.bundle.js +8 -8
  12. package/dist/5884.creaditor.bundle.js.gz +0 -0
  13. package/dist/5926.creaditor.bundle.js +1 -1
  14. package/dist/5926.creaditor.bundle.js.gz +0 -0
  15. package/dist/6442.creaditor.bundle.js +214 -155
  16. package/dist/6442.creaditor.bundle.js.gz +0 -0
  17. package/dist/{8547.creaditor.bundle.js → 7348.creaditor.bundle.js} +66 -131
  18. package/dist/7348.creaditor.bundle.js.gz +0 -0
  19. package/dist/7493.creaditor.bundle.js +48 -0
  20. package/dist/7493.creaditor.bundle.js.gz +0 -0
  21. package/dist/creaditor.bundle.js +948 -327
  22. package/dist/creaditor.bundle.js.LICENSE.txt +6 -0
  23. package/dist/creaditor.bundle.js.LICENSE.txt.gz +0 -0
  24. package/dist/creaditor.bundle.js.gz +0 -0
  25. package/dist/service-worker.js +1 -1
  26. package/dist/service-worker.js.gz +0 -0
  27. package/package.json +1 -1
  28. package/dist/1204.creaditor.bundle.js +0 -236
  29. package/dist/1204.creaditor.bundle.js.gz +0 -0
  30. package/dist/5119.creaditor.bundle.js +0 -48
  31. package/dist/5119.creaditor.bundle.js.gz +0 -0
  32. package/dist/6442.creaditor.bundle.js.LICENSE.txt +0 -23
  33. package/dist/6442.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  34. package/dist/7937.creaditor.bundle.js +0 -51
  35. package/dist/7937.creaditor.bundle.js.gz +0 -0
  36. package/dist/8547.creaditor.bundle.js.gz +0 -0
@@ -1,7 +1,7 @@
1
- "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[5884],{55884(e,t,r){r.d(t,{default:()=>L});var o=r(12106),s=r(59929);let i={};function n(e){i.selected=e}function c(e){return i.selected}var a=r(83423),l=r(81444);const d="https://img.creaditor.ai";function p(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const r=t.width??24,o=t.height??24;let s=t.color??"000000";s.startsWith("#")&&(s=s.slice(1));const i=`${d}/icons/serve/${encodeURIComponent(e.category)}/${encodeURIComponent(e.name)}.png?width=${r}&height=${o}`;return(0,l.tG)(i,s)}class h extends s.WF{constructor(){super(),this.searchQuery="",this.iconColor="000000",this.iconSize=34,this.selectedSrc="",this._icons=[],this._loading=!1,this._error=""}willUpdate(e){e.has("searchQuery")&&this.searchQuery?this._fetchIcons():e.has("searchQuery")&&!this.searchQuery&&(this._icons=[],this._error="")}async _fetchIcons(){const e=(this.searchQuery||"").trim();if(e){this._loading=!0,this._error="";try{const t=new URLSearchParams({q:e,limit:"20"}),r=await fetch(`${d}/icons/search?${t.toString()}`);if(!r.ok)throw new Error(r.statusText);const o=await r.json();this._icons=o.icons||[]}catch(e){this._icons=[],this._error=e.message||"Failed to load icons"}finally{this._loading=!1}}else this._icons=[]}_onSelect(e){const t=(this.iconColor||"000000").replace(/^#/,""),r=Number(this.iconSize)||34,o=p(e,{width:r,height:r,color:t});this.dispatchEvent(new CustomEvent("icon-selected",{detail:{src:o,icon:e},bubbles:!0,composed:!0}))}render(){if(!this.searchQuery?.trim())return s.qy``;if(this._loading)return s.qy`<div class="loading"><span class="spinner"></span>Loading icons…</div>`;if(this._error)return s.qy`<div class="error">${this._error}</div>`;if(!this._icons.length)return s.qy``;const e=(this.iconColor||"000000").replace(/^#/,"");return s.qy`
1
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[5884],{55884(e,t,r){r.d(t,{default:()=>L});var o=r(12106),i=r(59929);let s={};function n(e){s.selected=e}function c(e){return s.selected}var a=r(83423),l=r(81444);const d="https://img.creaditor.ai";function p(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const r=t.width??24,o=t.height??24;let i=t.color??"000000";i.startsWith("#")&&(i=i.slice(1));const s=`${d}/icons/serve/${encodeURIComponent(e.category)}/${encodeURIComponent(e.name)}.png?width=${r}&height=${o}`;return(0,l.tG)(s,i)}class h extends i.WF{constructor(){super(),this.searchQuery="",this.iconColor="000000",this.iconSize=34,this.selectedSrc="",this._icons=[],this._loading=!1,this._error=""}willUpdate(e){e.has("searchQuery")&&this.searchQuery?this._fetchIcons():e.has("searchQuery")&&!this.searchQuery&&(this._icons=[],this._error="")}async _fetchIcons(){const e=(this.searchQuery||"").trim();if(e){this._loading=!0,this._error="";try{const t=new URLSearchParams({q:e,limit:"20"}),r=await fetch(`${d}/icons/search?${t.toString()}`);if(!r.ok)throw new Error(r.statusText);const o=await r.json();this._icons=o.icons||[]}catch(e){this._icons=[],this._error=e.message||"Failed to load icons"}finally{this._loading=!1}}else this._icons=[]}_onSelect(e){const t=(this.iconColor||"000000").replace(/^#/,""),r=Number(this.iconSize)||34,o=p(e,{width:r,height:r,color:t});this.dispatchEvent(new CustomEvent("icon-selected",{detail:{src:o,icon:e},bubbles:!0,composed:!0}))}render(){if(!this.searchQuery?.trim())return i.qy``;if(this._loading)return i.qy`<div class="loading"><span class="spinner"></span>Loading icons…</div>`;if(this._error)return i.qy`<div class="error">${this._error}</div>`;if(!this._icons.length)return i.qy``;const e=(this.iconColor||"000000").replace(/^#/,"");return i.qy`
2
2
 
3
3
  <div class="grid">
4
- ${this._icons.map(t=>{const r=p(t,{width:24,height:24,color:e}),o=this.selectedSrc&&(this.selectedSrc.includes(t.name)||this.selectedSrc===r);return s.qy`
4
+ ${this._icons.map(t=>{const r=p(t,{width:24,height:24,color:e}),o=this.selectedSrc&&(this.selectedSrc.includes(t.name)||this.selectedSrc===r);return i.qy`
5
5
  <button
6
6
  type="button"
7
7
  class="icon-wrap ${o?"selected":""}"
@@ -12,7 +12,7 @@
12
12
  </button>
13
13
  `})}
14
14
  </div>
15
- `}}h.properties={searchQuery:{type:String},iconColor:{type:String},iconSize:{type:Number},selectedSrc:{type:String},_icons:{type:Array,state:!0},_loading:{type:Boolean,state:!0},_error:{type:String,state:!0}},h.styles=s.AH`
15
+ `}}h.properties={searchQuery:{type:String},iconColor:{type:String},iconSize:{type:Number},selectedSrc:{type:String},_icons:{type:Array,state:!0},_loading:{type:Boolean,state:!0},_error:{type:String,state:!0}},h.styles=i.AH`
16
16
  :host {
17
17
  display: block;
18
18
  font-size: 12px;
@@ -77,15 +77,15 @@
77
77
  .error {
78
78
  color: var(--error-color, #c00);
79
79
  }
80
- `,customElements.define("social-icon-suggestions",h);var m=r(61919);const f=e=>{{const{component:t,commands:r}=e,o=()=>{let e=c();if(e||(e=t.props.items.find(e=>!e.link),!e&&t.props.items.length>0&&(e=t.props.items[0])),e){!t.props.items.find(t=>t.id===e.id)&&t.props.items.length>0&&(e=t.props.items[0])}return e};return{select:e=>{let{changeTab:t,tab:r}=e;"link"!==r&&t("link")},tabs:e=>{e||(e="link");const t=[{text:"image"},{text:"design"},{text:"link",selected:!0}];return t.forEach(t=>t.selected=t.selected=t.text===e),t},layout:e=>{let{tab:i,changeTab:n,tabs:c}=e;const d=o(),p=[{type:"node",node:()=>s.qy`<img
80
+ `,customElements.define("social-icon-suggestions",h);var m=r(61919);const f=e=>{{const{component:t,commands:r}=e,o=()=>{let e=c();if(e||(e=t.props.items.find(e=>!e.link),!e&&t.props.items.length>0&&(e=t.props.items[0])),e){!t.props.items.find(t=>t.id===e.id)&&t.props.items.length>0&&(e=t.props.items[0])}return e};return{select:e=>{let{changeTab:t,tab:r}=e;"link"!==r&&t("link")},tabs:e=>{e||(e="link");const t=[{text:"image"},{text:"design"},{text:"link",selected:!0}];return t.forEach(t=>t.selected=t.selected=t.text===e),t},layout:e=>{let{tab:s,changeTab:n,tabs:c}=e;const d=o(),p=[{type:"node",node:()=>i.qy`<img
81
81
  style="padding:10px;display:block;margin:auto"
82
82
  width="52"
83
83
  height="52"
84
84
  src=${d?.src?(0,l.tG)(d.src,d.fgColor||d.iconColor):""}
85
- />`},{type:"button",text:"delete",bgColor:"#df381d",color:"#fff",icon:"deleteBin",active:!0,onClick:e=>{const s=o();if(!s)return;const i=[...t.props.items];if(i.length<2)return;const n=i.findIndex(e=>e.id===s.id);-1!==n&&(i.splice(n,1),r.execCommand("items",i))}},{type:"divider"},{type:"gallery",active:"image"===i.text,src:d?.src,hasPreview:!0,text:"open_gallery",justify:"flex-start",onChange:e=>{const s=o();if(!s)return;let i=e.detail;Array.isArray(i)&&(i=i[0]);const n=t.props,c=JSON.parse(JSON.stringify(n.items)),a=c.findIndex(e=>e.id===s.id);-1!==a&&(c[a].src=i.src,r.execCommand("items",c))}},{type:"custom",active:()=>{const e=d?.link?.href||d?.url,t=e?(0,l.IE)(a.A,e):null;return("link"===i.text||"image"===i.text)&&!!t},node:()=>{const e=d?.link?.href||d?.url,i=e&&(0,l.IE)(a.A,e)||"";return s.qy`<cdtr-editor-container><social-icon-suggestions
86
- .searchQuery=${i}
85
+ />`},{type:"button",text:"delete",bgColor:"#df381d",color:"#fff",icon:"deleteBin",active:!0,onClick:e=>{const i=o();if(!i)return;const s=[...t.props.items];if(s.length<2)return;const n=s.findIndex(e=>e.id===i.id);-1!==n&&(s.splice(n,1),r.execCommand("items",s))}},{type:"divider"},{type:"gallery",active:"image"===s.text,src:d?.src,hasPreview:!0,text:"open_gallery",justify:"flex-start",onChange:e=>{const i=o();if(!i)return;let s=e.detail;Array.isArray(s)&&(s=s[0]);const n=t.props,c=JSON.parse(JSON.stringify(n.items)),a=c.findIndex(e=>e.id===i.id);-1!==a&&(c[a].src=s.src,r.execCommand("items",c))}},{type:"custom",active:()=>{const e=d?.link?.href||d?.url,t=e?(0,l.IE)(a.A,e):null;return("link"===s.text||"image"===s.text)&&!!t},node:()=>{const e=d?.link?.href||d?.url,s=e&&(0,l.IE)(a.A,e)||"";return i.qy`<cdtr-editor-container><social-icon-suggestions
86
+ .searchQuery=${s}
87
87
  .iconColor=${d?.fgColor||d?.iconColor||"000000"}
88
88
  .iconSize=${parseInt(d?.style?.width,10)||34}
89
89
  .selectedSrc=${d?.src||""}
90
- @icon-selected=${e=>{const s=o();if(!s)return;const i=t.props,n=JSON.parse(JSON.stringify(i.items)),c=n.findIndex(e=>e.id===s.id);-1!==c&&(n[c].src=e.detail.src,r.execCommand("items",n))}}
91
- ></social-icon-suggestions></cdtr-editor-container>`}},{type:"divider"},{type:"linkpicker",href:d?.link||d?.url,active:()=>"link"===i.text&&!!d,onChange:e=>{const s=o();if(!s)return;const i=e.target.value,n=t.props,c=JSON.parse(JSON.stringify(n.items)),d=c.findIndex(e=>e.id===s.id);if(-1!==d){const e=c[d].fgColor||c[d].iconColor,t=function(e,t){const r=(0,l.IE)(a.A,e),o=r?a.A.find(e=>e.type===r):null,s=o?o.src:null;return s?(0,l.tG)(s,t):null}(i.href,e);t&&(c[d].src=t),c[d].url=i.href,c[d].link=i,r.execCommand("items",c)}}},{type:"slider",title:"size",active:"design"===i.text,value:parseInt(d?.style?.width),min:10,max:80,onInput:e=>{const o=e.target.value,s=[...t.props.items];s.forEach(e=>{e.style.width=o+"px",e.style.height=o+"px"}),r.execCommand("items",s)}},{type:"colorpicker",title:"icon_color",alpha:!1,active:()=>"design"===i.text&&!!d,value:d?.fgColor?d.fgColor.startsWith("#")?d.fgColor:"#"+d.fgColor:"#000000",onChange:e=>{const s=o();if(!s)return;let i=e.target.value;i=(0,m.A)(i).toHex(),i.startsWith("#")&&(i=i.slice(1)),8===i.length&&/^[0-9a-fA-F]+$/.test(i)&&(i=i.slice(0,6));const n=t.props,c=JSON.parse(JSON.stringify(n.items));if(!0===n.applyColorToAll)c.forEach(e=>{e.fgColor=i});else{const e=c.findIndex(e=>e.id===s.id);-1!==e&&(c[e].fgColor=i)}r.execCommand("items",c)}},{type:"checkbox",title:"color_them_all",checked:!!t.props.applyColorToAll,active:()=>"design"===i.text&&!!d,onChange:e=>{const t=!!e.target.checked;r.execCommand("applyColorToAll",t)}},{type:"divider"},{type:"slider",title:"spacing",active:"design"===i.text,value:parseFloat(t.props.style.gap),min:0,max:80,onInput:e=>{const t=e.target.value;r.execCommand("style",{gap:t+"px"})}}];return p}}}};var u=r(52144);const g=()=>({set:(e,t,r)=>{switch(t){case"style":if("object"==typeof r)return e[t]=(0,u.A)(e[t],r),!0;break;case"items":if(e[t]=r,Array.isArray(r)){const e=c(),t=r.find(t=>t.id===e?.id);t&&n(t)}return!0;case"src":const o=c();if(o&&Array.isArray(e.items)){const t=[...e.items],s=t.findIndex(e=>e.id===o.id);if(-1!==s)return t[s].src=r,e.items=t,!0}break;case"applyColorToAll":return e[t]=r,!0}}});var y=r(72591),x=r.n(y),b=r(88639),C=r.n(b),v=r(88128),A=r.n(v),k=r(30855),_=r.n(k),w=r(93051),S=r.n(w),I=r(89820),E={};E.setAttributes=_(),E.insert=A().bind(null,"head"),E.domAPI=C(),E.insertStyleElement=S();x()(I.A,E);const $=I.A&&I.A.locals?I.A.locals:void 0;var O=r(23571),T=r(91597);const L=()=>{const e="social";return{name:e,create:t=>{let{createElement:r,compose:s,helpers:i}=t;const d=(0,T.S)(),p=document.createElement("div"),h=document.createElement("div");h.classList.add($.root);new O.Ay(h,{sort:!0,delay:0,delayOnTouchOnly:!1,touchStartThreshold:0,disabled:!1,store:null,animation:150,easing:"cubic-bezier(1, 0, 0, 1)",preventOnFilter:!0,draggable:".item",dataIdAttr:"data-id",ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:1,direction:"horizontal",forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,dragoverBubble:!1,removeCloneOnHide:!0,emptyInsertThreshold:5,setData:function(e,t){e.setData("Text",t.textContent)},onChoose:function(e){e.oldIndex},onUnchoose:function(e){},onStart:function(e){e.oldIndex},onEnd:function(e){const t=JSON.parse(JSON.stringify(s.props.items)),{oldIndex:r,newIndex:o}=e,[i]=t.splice(r,1);t.splice(o,0,i),s.editor.store().execCommand("items",t)},onMove:function(e,t){e.dragged,e.draggedRect,e.related,e.relatedRect,e.willInsertAfter,t.clientY},onChange:function(e){e.newIndex}});p.appendChild(h);const m=r({name:e,id:s.id,template:p,draggable:{group:"element"},droppable:{group:"element"},render:()=>{const e=s.props.items;let t=!1;const r=e.map(e=>{const r=e.url||e.link?.link||"";if(!e.src&&r){const o=(0,l.IE)(a.A,r),s=o?a.A.find(e=>e.type===o):null;if(s)return t=!0,{...e,src:s.src}}return e});t&&setTimeout(()=>s.editor.store().execCommand("items",r),0);const d=t?r:e;for(;h.firstChild;)h.removeChild(h.firstChild);i.mergeDiff(h,{style:s.props.style});const p=c();d.forEach(e=>{const t=document.createElement("img");p?.id===e.id&&t.classList.add($.selected),t.addEventListener("click",()=>{n(e),Array.from(h.children).forEach(e=>{e.classList.remove($.selected)}),t.classList.add($.selected)}),t.classList.add("item"),e.id&&t.setAttribute("data-id",e.id);const r=(0,l.fm)(h);t.src=(0,l.Ff)(e,{color:e.fgColor||e.iconColor,bg:r})||"https://render.creaditor.ai/media/social-icons/broken-link-black-circle.png",i.mergeDiff(t,{style:e.style}),h.append(t)});const m=document.createElement("paper-button");m.style.minWidth="0",m.style.padding=0,m.innerHTML="<cdtr-icon icon='add'></cdtr-icon>",h.append(m),m.addEventListener("click",()=>{setTimeout(()=>{const e=s.props.items[s.props.items.length-1],t={id:(0,o.A)(),fgColor:"",bgColor:"",style:e.style,url:"",src:"https://render.creaditor.ai/media/social-icons/broken-link-black-circle.png"},r=[...s.props.items];r.push(t),n(t),s.editor.store().execCommand("items",r)},200)})},handleBar:!0,defaultProps:{},validator:g(),schema:s.schema,onSelect:e=>{const t=c();if(t){const r=document.querySelector(`[data-id="${t.id}"]`);r?(window.___social_cdtr_item=r,r.classList.add("selected_underlined")):p.classList.add(e)}},onDeselect:e=>{c();window.___social_cdtr_item&&window.___social_cdtr_item.classList.remove("selected_underlined"),p?.classList?.remove(e)},elementProps:s,remove:()=>{p.remove()},createEditor:f});return m.app.on("update",()=>{d.run(()=>{const e=(0,l.fm)(h);if(!e)return;const t=h.querySelectorAll("img"),r=s.props.items;t.forEach((t,o)=>{const s=r[o];if(!s)return;const i=(0,l.Ff)(s,{color:s.fgColor||s.iconColor,bg:e});i&&(t.src=i)})})}),m}}}},89820(e,t,r){r.d(t,{A:()=>c});var o=r(82001),s=r.n(o),i=r(40935),n=r.n(i)()(s());n.push([e.id,".Z7AEJu5h_9kumGVl3K4x{\n display: flex;\n}\n.UA2xJ_pGYNrGNLfjkExO{\n border:1px solid var(--primary);\n}","",{version:3,sources:["webpack://./../newsletter-editors/social-editor-component-newsletter/lib/style.module.css"],names:[],mappings:"AAAA;IACI,aAAa;AACjB;AACA;IACI,+BAA+B;AACnC",sourcesContent:[".root{\n display: flex;\n}\n.selected{\n border:1px solid var(--primary);\n}"],sourceRoot:""}]),n.locals={root:"Z7AEJu5h_9kumGVl3K4x",selected:"UA2xJ_pGYNrGNLfjkExO"};const c=n}}]);
90
+ @icon-selected=${e=>{const i=o();if(!i)return;const s=t.props,n=JSON.parse(JSON.stringify(s.items)),c=n.findIndex(e=>e.id===i.id);-1!==c&&(n[c].src=e.detail.src,r.execCommand("items",n))}}
91
+ ></social-icon-suggestions></cdtr-editor-container>`}},{type:"divider"},{type:"linkpicker",href:d?.link||d?.url,active:()=>"link"===s.text&&!!d,onChange:e=>{const i=o();if(!i)return;const s=e.target.value,n=t.props,c=JSON.parse(JSON.stringify(n.items)),d=c.findIndex(e=>e.id===i.id);if(-1!==d){const e=c[d].fgColor||c[d].iconColor,t=function(e,t){const r=(0,l.IE)(a.A,e),o=r?a.A.find(e=>e.type===r):null,i=o?o.src:null;return i?(0,l.tG)(i,t):null}(s.href,e);t&&(c[d].src=t),c[d].url=s.href,c[d].link=s,r.execCommand("items",c)}}},{type:"slider",title:"size",active:"design"===s.text,value:parseInt(d?.style?.width),min:10,max:80,onInput:e=>{const o=e.target.value,i=[...t.props.items];i.forEach(e=>{e.style.width=o+"px",e.style.height=o+"px"}),r.execCommand("items",i)}},{type:"colorpicker",title:"icon_color",alpha:!1,active:()=>"design"===s.text&&!!d,value:d?.fgColor?d.fgColor.startsWith("#")?d.fgColor:"#"+d.fgColor:"#000000",onChange:e=>{const i=o();if(!i)return;let s=e.target.value;s=(0,m.A)(s).toHex(),s.startsWith("#")&&(s=s.slice(1)),8===s.length&&/^[0-9a-fA-F]+$/.test(s)&&(s=s.slice(0,6));const n=t.props,c=JSON.parse(JSON.stringify(n.items));if(!0===n.applyColorToAll)c.forEach(e=>{e.fgColor=s});else{const e=c.findIndex(e=>e.id===i.id);-1!==e&&(c[e].fgColor=s)}r.execCommand("items",c)}},{type:"checkbox",title:"color_them_all",checked:!!t.props.applyColorToAll,active:()=>"design"===s.text&&!!d,onChange:e=>{const t=!!e.target.checked;r.execCommand("applyColorToAll",t)}},{type:"divider"},{type:"slider",title:"spacing",active:"design"===s.text,value:parseFloat(t.props.style.gap),min:0,max:80,onInput:e=>{const t=e.target.value;r.execCommand("style",{gap:t+"px"})}}];return p}}}};var u=r(52144);const g=()=>({set:(e,t,r)=>{switch(t){case"style":if("object"==typeof r)return e[t]=(0,u.A)(e[t],r),!0;break;case"items":if(e[t]=r,Array.isArray(r)){const e=c(),t=r.find(t=>t.id===e?.id);t&&n(t)}return!0;case"src":const o=c();if(o&&Array.isArray(e.items)){const t=[...e.items],i=t.findIndex(e=>e.id===o.id);if(-1!==i)return t[i].src=r,e.items=t,!0}break;case"applyColorToAll":return e[t]=r,!0}}});var y=r(72591),x=r.n(y),b=r(88639),C=r.n(b),v=r(88128),A=r.n(v),k=r(30855),w=r.n(k),_=r(93051),S=r.n(_),I=r(89820),E={};E.setAttributes=w(),E.insert=A().bind(null,"head"),E.domAPI=C(),E.insertStyleElement=S();x()(I.A,E);const $=I.A&&I.A.locals?I.A.locals:void 0;var T=r(23571),O=r(91597);const L=()=>{const e="social";return{name:e,create:t=>{let{createElement:r,compose:i,helpers:s}=t;const d=(0,O.S)(),p=document.createElement("div"),h=document.createElement("div");h.classList.add($.root);new T.Ay(h,{sort:!0,delay:0,delayOnTouchOnly:!1,touchStartThreshold:0,disabled:!1,store:null,animation:150,easing:"cubic-bezier(1, 0, 0, 1)",preventOnFilter:!0,draggable:".item",dataIdAttr:"data-id",ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:1,direction:"horizontal",forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,dragoverBubble:!1,removeCloneOnHide:!0,emptyInsertThreshold:5,setData:function(e,t){e.setData("Text",t.textContent)},onChoose:function(e){e.oldIndex},onUnchoose:function(e){},onStart:function(e){e.oldIndex},onEnd:function(e){const t=JSON.parse(JSON.stringify(i.props.items)),{oldIndex:r,newIndex:o}=e,[s]=t.splice(r,1);t.splice(o,0,s),i.editor.store().execCommand("items",t)},onMove:function(e,t){e.dragged,e.draggedRect,e.related,e.relatedRect,e.willInsertAfter,t.clientY},onChange:function(e){e.newIndex}});p.appendChild(h);const m=r({name:e,id:i.id,template:p,draggable:{group:"element"},droppable:{group:"element"},render:()=>{const e=i.props.items;let t=!1;const r=e.map(e=>{const r=e.url||e.link?.link||"";if(!e.src&&r){const o=(0,l.IE)(a.A,r),i=o?a.A.find(e=>e.type===o):null;if(i)return t=!0,{...e,src:i.src}}return e});t&&setTimeout(()=>i.editor.store().execCommand("items",r),0);const d=t?r:e;for(;h.firstChild;)h.removeChild(h.firstChild);s.mergeDiff(h,{style:i.props.style});const p=c();d.forEach(e=>{const t=document.createElement("img");p?.id===e.id&&t.classList.add($.selected),t.addEventListener("click",()=>{n(e),Array.from(h.children).forEach(e=>{e.classList.remove($.selected)}),t.classList.add($.selected)}),t.classList.add("item"),e.id&&t.setAttribute("data-id",e.id);const r=(0,l.fm)(h);t.src=(0,l.Ff)(e,{color:e.fgColor||e.iconColor,bg:r})||"https://render.creaditor.ai/media/social-icons/broken-link-black-circle.png",s.mergeDiff(t,{style:e.style}),h.append(t)});const m=document.createElement("paper-button");m.style.cssText=["min-width:0","padding:0","margin:0 4px","width:28px","height:28px","border-radius:50%","display:inline-flex","align-items:center","justify-content:center","vertical-align:middle","flex:none","background:#fff","color:#1f1b1d","border:1px solid rgba(0,0,0,.18)","box-shadow:0 1px 3px rgba(0,0,0,.28)"].join(";"),m.innerHTML="<cdtr-icon icon='add' width='18' height='18'></cdtr-icon>",h.append(m),m.addEventListener("click",()=>{setTimeout(()=>{const e=i.props.items[i.props.items.length-1],t={id:(0,o.A)(),fgColor:"",bgColor:"",style:e.style,url:"",src:"https://render.creaditor.ai/media/social-icons/broken-link-black-circle.png"},r=[...i.props.items];r.push(t),n(t),i.editor.store().execCommand("items",r)},200)})},handleBar:!0,defaultProps:{},validator:g(),schema:i.schema,onSelect:e=>{const t=c();if(t){const r=document.querySelector(`[data-id="${t.id}"]`);r?(window.___social_cdtr_item=r,r.classList.add("selected_underlined")):p.classList.add(e)}},onDeselect:e=>{c();window.___social_cdtr_item&&window.___social_cdtr_item.classList.remove("selected_underlined"),p?.classList?.remove(e)},elementProps:i,remove:()=>{p.remove()},createEditor:f});return m.app.on("update",()=>{d.run(()=>{const e=(0,l.fm)(h);if(!e)return;const t=h.querySelectorAll("img"),r=i.props.items;t.forEach((t,o)=>{const i=r[o];if(!i)return;const s=(0,l.Ff)(i,{color:i.fgColor||i.iconColor,bg:e});s&&(t.src=s)})})}),m}}}},89820(e,t,r){r.d(t,{A:()=>c});var o=r(82001),i=r.n(o),s=r(40935),n=r.n(s)()(i());n.push([e.id,".Z7AEJu5h_9kumGVl3K4x{\n display: flex;\n}\n.UA2xJ_pGYNrGNLfjkExO{\n border:1px solid var(--primary);\n}","",{version:3,sources:["webpack://./../newsletter-editors/social-editor-component-newsletter/lib/style.module.css"],names:[],mappings:"AAAA;IACI,aAAa;AACjB;AACA;IACI,+BAA+B;AACnC",sourcesContent:[".root{\n display: flex;\n}\n.selected{\n border:1px solid var(--primary);\n}"],sourceRoot:""}]),n.locals={root:"Z7AEJu5h_9kumGVl3K4x",selected:"UA2xJ_pGYNrGNLfjkExO"};const c=n}}]);
Binary file
@@ -1,4 +1,4 @@
1
- "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[5926],{83545(t,e,n){n.r(e),n.d(e,{EditorTabs:()=>l});var o=n(59929),s=n(54804),i=n(86319),a=n(40648);n.e(7937).then(n.bind(n,67937));const r="cdtr-editor-tabs-hint-seen";class l extends o.WF{constructor(){super(),this.onConnected=this.onConnected.bind(this),this.onArrowNavigation=this.onArrowNavigation.bind(this),this.dismissHint=this.dismissHint.bind(this),this.scheduleSync=this.scheduleSync.bind(this),this.observeContent=this.observeContent.bind(this),this.toggleAllSections=this.toggleAllSections.bind(this),this.tabs=[],this.showHint=!1,this._sectionCount=0,this._allExpanded=!1}sectionElements(){const t=this.shadowRoot?.querySelector('slot[name="content"]');if(!t)return[];const e=[];for(const n of t.assignedElements({flatten:!0})){"CDTR-EDITOR-SECTION"===n.tagName&&e.push(n);for(const t of n.children)"CDTR-EDITOR-SECTION"===t.tagName&&e.push(t)}return e}syncSections(){const t=this.sectionElements();this._sectionCount=t.length,this._allExpanded=t.length>0&&t.every(t=>t.open)}observeContent(){this._contentObserver||(this._contentObserver=new MutationObserver(this.scheduleSync)),this._contentObserver.disconnect();const t=this.shadowRoot?.querySelector('slot[name="content"]');if(t){for(const e of t.assignedElements({flatten:!0}))this._contentObserver.observe(e,{childList:!0});this.scheduleSync()}}scheduleSync(){this._syncPending||(this._syncPending=!0,setTimeout(()=>{this._syncPending=!1,this.isConnected&&this.syncSections()},0))}toggleAllSections(){const t=!this._allExpanded;for(const e of this.sectionElements())e.open=t,(0,a.Q)(e.persistKey,t);this._allExpanded=t}hintAlreadySeen(){try{return"1"===localStorage.getItem(r)}catch(t){return!0}}dismissHint(){this.showHint=!1;try{localStorage.setItem(r,"1")}catch(t){}}onClickItem(t){let{target:e}=t;const n=this.value=e.value,o=[...this.tabs],s=o.findIndex(t=>t.text===n);-1!==s&&(o.forEach(t=>{t.selected=!1}),o[s].selected=!0),this.tabs=o,this.scheduleSync(),this.showHint&&this.dismissHint();const i=new UIEvent("tabChanged",{view:window,bubbles:!0,cancelable:!0});this.dispatchEvent(i)}firstUpdated(){super.firstUpdated()}maybeShowHint(){this._hintChecked||this.tabs.length<=1||this.hintAlreadySeen()||(this._hintChecked=!0,setTimeout(()=>{this.isConnected&&!this.hintAlreadySeen()&&(this.showHint=!0)},700))}updated(){this.setAttribute("data-active-tab",this.value||""),this.maybeShowHint(),this.observeContent()}onConnected(t){let{name:e}=t;this.onClickItem({target:{value:e}})}onArrowNavigation(t){const{key:e,currentIcon:n}=t.detail,o=this.tabs.findIndex(t=>t.text===n);if(-1===o)return;let s=o;switch(e){case"ArrowUp":case"ArrowLeft":s=o>0?o-1:this.tabs.length-1;break;case"ArrowDown":case"ArrowRight":s=o<this.tabs.length-1?o+1:0;break;default:return}const i=this.tabs[s];i&&(this.onClickItem({target:{value:i.text}}),this.updateComplete.then(()=>{const t=this.shadowRoot.querySelector(`cdtr-editor-tab-item[icon="${i.text}"]`);t&&t.focus()}))}connectedCallback(){super.connectedCallback(),s.Ay.on("editor-tabs",this.onConnected),s.Ay.on("update",this.scheduleSync),s.Ay.on("select",this.scheduleSync)}disconnectedCallback(){super.disconnectedCallback(),s.Ay.off("editor-tabs",this.onConnected),s.Ay.off("update",this.scheduleSync),s.Ay.off("select",this.scheduleSync),this._contentObserver?.disconnect()}renderContent(){switch(this.value){case"animations":return n.e(3553).then(n.bind(n,3553)),o.qy`<cdtr-animations-editor>
1
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[5926],{83545(t,e,n){n.r(e),n.d(e,{EditorTabs:()=>l});var o=n(59929),s=n(54804),i=n(86319),a=n(40648);Promise.resolve().then(n.bind(n,67937));const r="cdtr-editor-tabs-hint-seen";class l extends o.WF{constructor(){super(),this.onConnected=this.onConnected.bind(this),this.onArrowNavigation=this.onArrowNavigation.bind(this),this.dismissHint=this.dismissHint.bind(this),this.scheduleSync=this.scheduleSync.bind(this),this.observeContent=this.observeContent.bind(this),this.toggleAllSections=this.toggleAllSections.bind(this),this.tabs=[],this.showHint=!1,this._sectionCount=0,this._allExpanded=!1}sectionElements(){const t=this.shadowRoot?.querySelector('slot[name="content"]');if(!t)return[];const e=[];for(const n of t.assignedElements({flatten:!0})){"CDTR-EDITOR-SECTION"===n.tagName&&e.push(n);for(const t of n.children)"CDTR-EDITOR-SECTION"===t.tagName&&e.push(t)}return e}syncSections(){const t=this.sectionElements();this._sectionCount=t.length,this._allExpanded=t.length>0&&t.every(t=>t.open)}observeContent(){this._contentObserver||(this._contentObserver=new MutationObserver(this.scheduleSync)),this._contentObserver.disconnect();const t=this.shadowRoot?.querySelector('slot[name="content"]');if(t){for(const e of t.assignedElements({flatten:!0}))this._contentObserver.observe(e,{childList:!0});this.scheduleSync()}}scheduleSync(){this._syncPending||(this._syncPending=!0,setTimeout(()=>{this._syncPending=!1,this.isConnected&&this.syncSections()},0))}toggleAllSections(){const t=!this._allExpanded;for(const e of this.sectionElements())e.open=t,(0,a.Q)(e.persistKey,t);this._allExpanded=t}hintAlreadySeen(){try{return"1"===localStorage.getItem(r)}catch(t){return!0}}dismissHint(){this.showHint=!1;try{localStorage.setItem(r,"1")}catch(t){}}onClickItem(t){let{target:e}=t;const n=this.value=e.value,o=[...this.tabs],s=o.findIndex(t=>t.text===n);-1!==s&&(o.forEach(t=>{t.selected=!1}),o[s].selected=!0),this.tabs=o,this.scheduleSync(),this.showHint&&this.dismissHint();const i=new UIEvent("tabChanged",{view:window,bubbles:!0,cancelable:!0});this.dispatchEvent(i)}firstUpdated(){super.firstUpdated()}maybeShowHint(){this._hintChecked||this.tabs.length<=1||this.hintAlreadySeen()||(this._hintChecked=!0,setTimeout(()=>{this.isConnected&&!this.hintAlreadySeen()&&(this.showHint=!0)},700))}updated(){this.setAttribute("data-active-tab",this.value||""),this.maybeShowHint(),this.observeContent()}onConnected(t){let{name:e}=t;this.onClickItem({target:{value:e}})}onArrowNavigation(t){const{key:e,currentIcon:n}=t.detail,o=this.tabs.findIndex(t=>t.text===n);if(-1===o)return;let s=o;switch(e){case"ArrowUp":case"ArrowLeft":s=o>0?o-1:this.tabs.length-1;break;case"ArrowDown":case"ArrowRight":s=o<this.tabs.length-1?o+1:0;break;default:return}const i=this.tabs[s];i&&(this.onClickItem({target:{value:i.text}}),this.updateComplete.then(()=>{const t=this.shadowRoot.querySelector(`cdtr-editor-tab-item[icon="${i.text}"]`);t&&t.focus()}))}connectedCallback(){super.connectedCallback(),s.Ay.on("editor-tabs",this.onConnected),s.Ay.on("update",this.scheduleSync),s.Ay.on("select",this.scheduleSync)}disconnectedCallback(){super.disconnectedCallback(),s.Ay.off("editor-tabs",this.onConnected),s.Ay.off("update",this.scheduleSync),s.Ay.off("select",this.scheduleSync),this._contentObserver?.disconnect()}renderContent(){switch(this.value){case"animations":return n.e(3553).then(n.bind(n,3553)),o.qy`<cdtr-animations-editor>
2
2
  <cdtr-block-loader></cdtr-block-loader
3
3
  ></cdtr-animations-editor>`;case"settings":case"setting":return n.e(7654).then(n.bind(n,37654)),o.qy`<cdtr-setting-editor>
4
4
  <cdtr-block-loader></cdtr-block-loader
Binary file
@@ -1,177 +1,236 @@
1
- /*! For license information please see 6442.creaditor.bundle.js.LICENSE.txt */
2
- "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[6442],{54061(){const t=window,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),s=new WeakMap;class n{constructor(t,e,s){if(this._$cssResult$=!0,s!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const i=this.t;if(e&&void 0===t){const e=void 0!==i&&1===i.length;e&&(t=s.get(i)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&s.set(i,t))}return t}toString(){return this.cssText}}const o=(i,s)=>{e?i.adoptedStyleSheets=s.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet):s.forEach(e=>{const s=document.createElement("style"),n=t.litNonce;void 0!==n&&s.setAttribute("nonce",n),s.textContent=e.cssText,i.appendChild(s)})},r=e?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return(t=>new n("string"==typeof t?t:t+"",void 0,i))(e)})(t):t;var l;const h=window,a=h.trustedTypes,d=a?a.emptyScript:"",c=h.reactiveElementPolyfillSupport,u={toAttribute(t,e){switch(e){case Boolean:t=t?d:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},p=(t,e)=>e!==t&&(e==e||t==t),v={attribute:!0,type:String,converter:u,reflect:!1,hasChanged:p},f="finalized";class $ extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this._$Eu()}static addInitializer(t){var e;this.finalize(),(null!==(e=this.h)&&void 0!==e?e:this.h=[]).push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach((e,i)=>{const s=this._$Ep(i,e);void 0!==s&&(this._$Ev.set(s,i),t.push(s))}),t}static createProperty(t,e=v){if(e.state&&(e.attribute=!1),this.finalize(),this.elementProperties.set(t,e),!e.noAccessor&&!this.prototype.hasOwnProperty(t)){const i="symbol"==typeof t?Symbol():"__"+t,s=this.getPropertyDescriptor(t,i,e);void 0!==s&&Object.defineProperty(this.prototype,t,s)}}static getPropertyDescriptor(t,e,i){return{get(){return this[e]},set(s){const n=this[t];this[e]=s,this.requestUpdate(t,n,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||v}static finalize(){if(this.hasOwnProperty(f))return!1;this[f]=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),void 0!==t.h&&(this.h=[...t.h]),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,e=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const i of e)this.createProperty(i,t[i])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(r(t))}else void 0!==t&&e.push(r(t));return e}static _$Ep(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}_$Eu(){var t;this._$E_=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach(t=>t(this))}addController(t){var e,i;(null!==(e=this._$ES)&&void 0!==e?e:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(i=t.hostConnected)||void 0===i||i.call(t))}removeController(t){var e;null===(e=this._$ES)||void 0===e||e.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach((t,e)=>{this.hasOwnProperty(e)&&(this._$Ei.set(e,this[e]),delete this[e])})}createRenderRoot(){var t;const e=null!==(t=this.shadowRoot)&&void 0!==t?t:this.attachShadow(this.constructor.shadowRootOptions);return o(e,this.constructor.elementStyles),e}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach(t=>{var e;return null===(e=t.hostConnected)||void 0===e?void 0:e.call(t)})}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach(t=>{var e;return null===(e=t.hostDisconnected)||void 0===e?void 0:e.call(t)})}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$EO(t,e,i=v){var s;const n=this.constructor._$Ep(t,i);if(void 0!==n&&!0===i.reflect){const o=(void 0!==(null===(s=i.converter)||void 0===s?void 0:s.toAttribute)?i.converter:u).toAttribute(e,i.type);this._$El=t,null==o?this.removeAttribute(n):this.setAttribute(n,o),this._$El=null}}_$AK(t,e){var i;const s=this.constructor,n=s._$Ev.get(t);if(void 0!==n&&this._$El!==n){const t=s.getPropertyOptions(n),o="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==(null===(i=t.converter)||void 0===i?void 0:i.fromAttribute)?t.converter:u;this._$El=n,this[n]=o.fromAttribute(e,t.type),this._$El=null}}requestUpdate(t,e,i){let s=!0;void 0!==t&&(((i=i||this.constructor.getPropertyOptions(t)).hasChanged||p)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===i.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,i))):s=!1),!this.isUpdatePending&&s&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach((t,e)=>this[e]=t),this._$Ei=void 0);let e=!1;const i=this._$AL;try{e=this.shouldUpdate(i),e?(this.willUpdate(i),null===(t=this._$ES)||void 0===t||t.forEach(t=>{var e;return null===(e=t.hostUpdate)||void 0===e?void 0:e.call(t)}),this.update(i)):this._$Ek()}catch(t){throw e=!1,this._$Ek(),t}e&&this._$AE(i)}willUpdate(t){}_$AE(t){var e;null===(e=this._$ES)||void 0===e||e.forEach(t=>{var e;return null===(e=t.hostUpdated)||void 0===e?void 0:e.call(t)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach((t,e)=>this._$EO(e,this[e],t)),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}}var _;$[f]=!0,$.elementProperties=new Map,$.elementStyles=[],$.shadowRootOptions={mode:"open"},null==c||c({ReactiveElement:$}),(null!==(l=h.reactiveElementVersions)&&void 0!==l?l:h.reactiveElementVersions=[]).push("1.6.3");const g=window,y=g.trustedTypes,m=y?y.createPolicy("lit-html",{createHTML:t=>t}):void 0,A="$lit$",b=`lit$${(Math.random()+"").slice(9)}$`,x="?"+b,E=`<${x}>`,w=document,S=()=>w.createComment(""),C=t=>null===t||"object"!=typeof t&&"function"!=typeof t,k=Array.isArray,T=t=>k(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]),P="[ \t\n\f\r]",U=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,H=/-->/g,N=/>/g,M=RegExp(`>|${P}(?:([^\\s"'>=/]+)(${P}*=${P}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),R=/'/g,O=/"/g,I=/^(?:script|style|textarea|title)$/i,z=t=>(e,...i)=>({_$litType$:t,strings:e,values:i}),B=z(1),j=(z(2),Symbol.for("lit-noChange")),L=Symbol.for("lit-nothing"),V=new WeakMap,D=w.createTreeWalker(w,129,null,!1);function G(t,e){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==m?m.createHTML(e):e}const W=(t,e)=>{const i=t.length-1,s=[];let n,o=2===e?"<svg>":"",r=U;for(let e=0;e<i;e++){const i=t[e];let l,h,a=-1,d=0;for(;d<i.length&&(r.lastIndex=d,h=r.exec(i),null!==h);)d=r.lastIndex,r===U?"!--"===h[1]?r=H:void 0!==h[1]?r=N:void 0!==h[2]?(I.test(h[2])&&(n=RegExp("</"+h[2],"g")),r=M):void 0!==h[3]&&(r=M):r===M?">"===h[0]?(r=null!=n?n:U,a=-1):void 0===h[1]?a=-2:(a=r.lastIndex-h[2].length,l=h[1],r=void 0===h[3]?M:'"'===h[3]?O:R):r===O||r===R?r=M:r===H||r===N?r=U:(r=M,n=void 0);const c=r===M&&t[e+1].startsWith("/>")?" ":"";o+=r===U?i+E:a>=0?(s.push(l),i.slice(0,a)+A+i.slice(a)+b+c):i+b+(-2===a?(s.push(void 0),e):c)}return[G(t,o+(t[i]||"<?>")+(2===e?"</svg>":"")),s]};class F{constructor({strings:t,_$litType$:e},i){let s;this.parts=[];let n=0,o=0;const r=t.length-1,l=this.parts,[h,a]=W(t,e);if(this.el=F.createElement(h,i),D.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(s=D.nextNode())&&l.length<r;){if(1===s.nodeType){if(s.hasAttributes()){const t=[];for(const e of s.getAttributeNames())if(e.endsWith(A)||e.startsWith(b)){const i=a[o++];if(t.push(e),void 0!==i){const t=s.getAttribute(i.toLowerCase()+A).split(b),e=/([.?@])?(.*)/.exec(i);l.push({type:1,index:n,name:e[2],strings:t,ctor:"."===e[1]?Y:"?"===e[1]?X:"@"===e[1]?tt:J})}else l.push({type:6,index:n})}for(const e of t)s.removeAttribute(e)}if(I.test(s.tagName)){const t=s.textContent.split(b),e=t.length-1;if(e>0){s.textContent=y?y.emptyScript:"";for(let i=0;i<e;i++)s.append(t[i],S()),D.nextNode(),l.push({type:2,index:++n});s.append(t[e],S())}}}else if(8===s.nodeType)if(s.data===x)l.push({type:2,index:n});else{let t=-1;for(;-1!==(t=s.data.indexOf(b,t+1));)l.push({type:7,index:n}),t+=b.length-1}n++}}static createElement(t,e){const i=w.createElement("template");return i.innerHTML=t,i}}function q(t,e,i=t,s){var n,o,r,l;if(e===j)return e;let h=void 0!==s?null===(n=i._$Co)||void 0===n?void 0:n[s]:i._$Cl;const a=C(e)?void 0:e._$litDirective$;return(null==h?void 0:h.constructor)!==a&&(null===(o=null==h?void 0:h._$AO)||void 0===o||o.call(h,!1),void 0===a?h=void 0:(h=new a(t),h._$AT(t,i,s)),void 0!==s?(null!==(r=(l=i)._$Co)&&void 0!==r?r:l._$Co=[])[s]=h:i._$Cl=h),void 0!==h&&(e=q(t,h._$AS(t,e.values),h,s)),e}class K{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var e;const{el:{content:i},parts:s}=this._$AD,n=(null!==(e=null==t?void 0:t.creationScope)&&void 0!==e?e:w).importNode(i,!0);D.currentNode=n;let o=D.nextNode(),r=0,l=0,h=s[0];for(;void 0!==h;){if(r===h.index){let e;2===h.type?e=new Q(o,o.nextSibling,this,t):1===h.type?e=new h.ctor(o,h.name,h.strings,this,t):6===h.type&&(e=new et(o,this,t)),this._$AV.push(e),h=s[++l]}r!==(null==h?void 0:h.index)&&(o=D.nextNode(),r++)}return D.currentNode=w,n}v(t){let e=0;for(const i of this._$AV)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}class Q{constructor(t,e,i,s){var n;this.type=2,this._$AH=L,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=s,this._$Cp=null===(n=null==s?void 0:s.isConnected)||void 0===n||n}get _$AU(){var t,e;return null!==(e=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==e?e:this._$Cp}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===(null==t?void 0:t.nodeType)&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=q(this,t,e),C(t)?t===L||null==t||""===t?(this._$AH!==L&&this._$AR(),this._$AH=L):t!==this._$AH&&t!==j&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):T(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==L&&C(this._$AH)?this._$AA.nextSibling.data=t:this.$(w.createTextNode(t)),this._$AH=t}g(t){var e;const{values:i,_$litType$:s}=t,n="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=F.createElement(G(s.h,s.h[0]),this.options)),s);if((null===(e=this._$AH)||void 0===e?void 0:e._$AD)===n)this._$AH.v(i);else{const t=new K(n,this),e=t.u(this.options);t.v(i),this.$(e),this._$AH=t}}_$AC(t){let e=V.get(t.strings);return void 0===e&&V.set(t.strings,e=new F(t)),e}T(t){k(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,s=0;for(const n of t)s===e.length?e.push(i=new Q(this.k(S()),this.k(S()),this,this.options)):i=e[s],i._$AI(n),s++;s<e.length&&(this._$AR(i&&i._$AB.nextSibling,s),e.length=s)}_$AR(t=this._$AA.nextSibling,e){var i;for(null===(i=this._$AP)||void 0===i||i.call(this,!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){var e;void 0===this._$AM&&(this._$Cp=t,null===(e=this._$AP)||void 0===e||e.call(this,t))}}class J{constructor(t,e,i,s,n){this.type=1,this._$AH=L,this._$AN=void 0,this.element=t,this.name=e,this._$AM=s,this.options=n,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=L}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,i,s){const n=this.strings;let o=!1;if(void 0===n)t=q(this,t,e,0),o=!C(t)||t!==this._$AH&&t!==j,o&&(this._$AH=t);else{const s=t;let r,l;for(t=n[0],r=0;r<n.length-1;r++)l=q(this,s[i+r],e,r),l===j&&(l=this._$AH[r]),o||(o=!C(l)||l!==this._$AH[r]),l===L?t=L:t!==L&&(t+=(null!=l?l:"")+n[r+1]),this._$AH[r]=l}o&&!s&&this.j(t)}j(t){t===L?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class Y extends J{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===L?void 0:t}}const Z=y?y.emptyScript:"";class X extends J{constructor(){super(...arguments),this.type=4}j(t){t&&t!==L?this.element.setAttribute(this.name,Z):this.element.removeAttribute(this.name)}}class tt extends J{constructor(t,e,i,s,n){super(t,e,i,s,n),this.type=5}_$AI(t,e=this){var i;if((t=null!==(i=q(this,t,e,0))&&void 0!==i?i:L)===j)return;const s=this._$AH,n=t===L&&s!==L||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,o=t!==L&&(s===L||n);n&&this.element.removeEventListener(this.name,this,s),o&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,i;"function"==typeof this._$AH?this._$AH.call(null!==(i=null===(e=this.options)||void 0===e?void 0:e.host)&&void 0!==i?i:this.element,t):this._$AH.handleEvent(t)}}class et{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){q(this,t)}}const it={O:A,P:b,A:x,C:1,M:W,L:K,R:T,D:q,I:Q,V:J,H:X,N:tt,U:Y,F:et},st=g.litHtmlPolyfillSupport;null==st||st(F,Q),(null!==(_=g.litHtmlVersions)&&void 0!==_?_:g.litHtmlVersions=[]).push("2.8.0");var nt,ot;class rt extends ${constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,e;const i=super.createRenderRoot();return null!==(t=(e=this.renderOptions).renderBefore)&&void 0!==t||(e.renderBefore=i.firstChild),i}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,e,i)=>{var s,n;const o=null!==(s=null==i?void 0:i.renderBefore)&&void 0!==s?s:e;let r=o._$litPart$;if(void 0===r){const t=null!==(n=null==i?void 0:i.renderBefore)&&void 0!==n?n:null;o._$litPart$=r=new Q(e.insertBefore(S(),t),t,void 0,null!=i?i:{})}return r._$AI(t),r})(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!1)}render(){return j}}rt.finalized=!0,rt._$litElement$=!0,null===(nt=globalThis.litElementHydrateSupport)||void 0===nt||nt.call(globalThis,{LitElement:rt});const lt=globalThis.litElementPolyfillSupport;null==lt||lt({LitElement:rt});(null!==(ot=globalThis.litElementVersions)&&void 0!==ot?ot:globalThis.litElementVersions=[]).push("3.3.3");const ht=(t,e)=>"method"===e.kind&&e.descriptor&&!("value"in e.descriptor)?{...e,finisher(i){i.createProperty(e.key,t)}}:{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:e.key,initializer(){"function"==typeof e.initializer&&(this[e.key]=e.initializer.call(this))},finisher(i){i.createProperty(e.key,t)}};function at(t){return(e,i)=>void 0!==i?((t,e,i)=>{e.constructor.createProperty(i,t)})(t,e,i):ht(t,e)}var dt;null===(dt=window.HTMLSlotElement)||void 0===dt||dt.prototype.assignedElements;const{I:ct}=it,ut=()=>document.createComment(""),pt=(t,e,i)=>{var s;const n=t._$AA.parentNode,o=void 0===e?t._$AB:e._$AA;if(void 0===i){const e=n.insertBefore(ut(),o),s=n.insertBefore(ut(),o);i=new ct(e,s,t,t.options)}else{const e=i._$AB.nextSibling,r=i._$AM,l=r!==t;if(l){let e;null===(s=i._$AQ)||void 0===s||s.call(i,t),i._$AM=t,void 0!==i._$AP&&(e=t._$AU)!==r._$AU&&i._$AP(e)}if(e!==o||l){let t=i._$AA;for(;t!==e;){const e=t.nextSibling;n.insertBefore(t,o),t=e}}}return i},vt=(t,e,i=t)=>(t._$AI(e,i),t),ft={},$t=t=>{var e;null===(e=t._$AP)||void 0===e||e.call(t,!1,!0);let i=t._$AA;const s=t._$AB.nextSibling;for(;i!==s;){const t=i.nextSibling;i.remove(),i=t}},_t=2,gt=t=>(...e)=>({_$litDirective$:t,values:e});class yt{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}const mt=(t,e)=>{var i,s;const n=t._$AN;if(void 0===n)return!1;for(const t of n)null===(s=(i=t)._$AO)||void 0===s||s.call(i,e,!1),mt(t,e);return!0},At=t=>{let e,i;do{if(void 0===(e=t._$AM))break;i=e._$AN,i.delete(t),t=e}while(0===(null==i?void 0:i.size))},bt=t=>{for(let e;e=t._$AM;t=e){let i=e._$AN;if(void 0===i)e._$AN=i=new Set;else if(i.has(t))break;i.add(t),wt(e)}};function xt(t){void 0!==this._$AN?(At(this),this._$AM=t,bt(this)):this._$AM=t}function Et(t,e=!1,i=0){const s=this._$AH,n=this._$AN;if(void 0!==n&&0!==n.size)if(e)if(Array.isArray(s))for(let t=i;t<s.length;t++)mt(s[t],!1),At(s[t]);else null!=s&&(mt(s,!1),At(s));else mt(this,t)}const wt=t=>{var e,i,s,n;t.type==_t&&(null!==(e=(s=t)._$AP)&&void 0!==e||(s._$AP=Et),null!==(i=(n=t)._$AQ)&&void 0!==i||(n._$AQ=xt))};class St extends yt{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,i){super._$AT(t,e,i),bt(this),this.isConnected=t._$AU}_$AO(t,e=!0){var i,s;t!==this.isConnected&&(this.isConnected=t,t?null===(i=this.reconnected)||void 0===i||i.call(this):null===(s=this.disconnected)||void 0===s||s.call(this)),e&&(mt(this,t),At(this))}setValue(t){if((t=>void 0===t.strings)(this._$Ct))this._$Ct._$AI(t,this);else{const e=[...this._$Ct._$AH];e[this._$Ci]=t,this._$Ct._$AI(e,this,0)}}disconnected(){}reconnected(){}}const Ct=()=>new kt;class kt{}const Tt=new WeakMap,Pt=gt(class extends St{render(t){return L}update(t,[e]){var i;const s=e!==this.G;return s&&void 0!==this.G&&this.ot(void 0),(s||this.rt!==this.lt)&&(this.G=e,this.dt=null===(i=t.options)||void 0===i?void 0:i.host,this.ot(this.lt=t.element)),L}ot(t){var e;if("function"==typeof this.G){const i=null!==(e=this.dt)&&void 0!==e?e:globalThis;let s=Tt.get(i);void 0===s&&(s=new WeakMap,Tt.set(i,s)),void 0!==s.get(this.G)&&this.G.call(this.dt,void 0),s.set(this.G,t),void 0!==t&&this.G.call(this.dt,t)}else this.G.value=t}get rt(){var t,e,i;return"function"==typeof this.G?null===(e=Tt.get(null!==(t=this.dt)&&void 0!==t?t:globalThis))||void 0===e?void 0:e.get(this.G):null===(i=this.G)||void 0===i?void 0:i.value}disconnected(){this.rt===this.lt&&this.ot(void 0)}reconnected(){this.ot(this.lt)}}),Ut=(t,e,i)=>{const s=new Map;for(let n=e;n<=i;n++)s.set(t[n],n);return s},Ht=gt(class extends yt{constructor(t){if(super(t),t.type!==_t)throw Error("repeat() can only be used in text expressions")}ct(t,e,i){let s;void 0===i?i=e:void 0!==e&&(s=e);const n=[],o=[];let r=0;for(const e of t)n[r]=s?s(e,r):r,o[r]=i(e,r),r++;return{values:o,keys:n}}render(t,e,i){return this.ct(t,e,i).values}update(t,[e,i,s]){var n;const o=(t=>t._$AH)(t),{values:r,keys:l}=this.ct(e,i,s);if(!Array.isArray(o))return this.ut=l,r;const h=null!==(n=this.ut)&&void 0!==n?n:this.ut=[],a=[];let d,c,u=0,p=o.length-1,v=0,f=r.length-1;for(;u<=p&&v<=f;)if(null===o[u])u++;else if(null===o[p])p--;else if(h[u]===l[v])a[v]=vt(o[u],r[v]),u++,v++;else if(h[p]===l[f])a[f]=vt(o[p],r[f]),p--,f--;else if(h[u]===l[f])a[f]=vt(o[u],r[f]),pt(t,a[f+1],o[u]),u++,f--;else if(h[p]===l[v])a[v]=vt(o[p],r[v]),pt(t,o[u],o[p]),p--,v++;else if(void 0===d&&(d=Ut(l,v,f),c=Ut(h,u,p)),d.has(h[u]))if(d.has(h[p])){const e=c.get(l[v]),i=void 0!==e?o[e]:null;if(null===i){const e=pt(t,o[u]);vt(e,r[v]),a[v]=e}else a[v]=vt(i,r[v]),pt(t,o[u],i),o[e]=null;v++}else $t(o[p]),p--;else $t(o[u]),u++;for(;v<=f;){const e=pt(t,a[f+1]);vt(e,r[v]),a[v++]=e}for(;u<=p;){const t=o[u++];null!==t&&$t(t)}return this.ut=l,((t,e=ft)=>{t._$AH=e})(t,a),j}});var Nt=function(t,e,i,s){var n,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var l=t.length-1;l>=0;l--)(n=t[l])&&(r=(o<3?n(r):o>3?n(e,i,r):n(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};let Mt=class extends rt{constructor(){super(),this.removeable=!0,this.inputValue="",this.placeholder="",this.max="50",this.primaryText="#fff",this.primary="#845EC2",this.maxItems=20,this.focused=!1,this.items=[],this.suggestions=[],this.filtered=[],this.opened=!1,this.freeSolo=!0,this.setFocus=this.setFocus.bind(this),this.addItem=this.addItem.bind(this),this.keypress=this.keypress.bind(this),this.onTabClicked=this.onTabClicked.bind(this),this.keyCount=0,this.items=[],this.focused=!1,this.inputRef=Ct(),this.suggestionElRef=Ct()}setFocus(){if(this.inputRef.value!==document.activeElement){this.inputRef.value.focus()}}removeItems(t){this.value=this.items[t];const e=[...this.items];e.splice(t,1),this.items=e;const i=new UIEvent("change",{view:window,bubbles:!0,cancelable:!0});this.dispatchEvent(i)}addItem(t){const e=[...this.items],i=this.inputRef.value;let s;s=t?t.split(","):i.value.split(","),s.forEach(t=>{const s=t.replace(/,/g,"");if(s&&s.trim()&&-1===this.items.findIndex(t=>t.value===s)){if(!this.freeSolo&&-1===this.suggestions.findIndex(t=>t.value===s))return;e.push({value:s}),i.value="",this.items=e,this.filtered=this.suggestions.filter(t=>t.value.includes(this.inputValue)&&-1===this.items.findIndex(e=>e.value===t.value));const t=new UIEvent("change",{view:window,bubbles:!0,cancelable:!0});this.dispatchEvent(t)}})}onTabClicked(t){const e=this.inputRef.value;"Tab"===t.key&&this.focused&&e.value.trim()&&(this.addItem(),t.preventDefault())}keypress(t){","===t.key||"Enter"===t.key?(this.opened=!1,this.addItem()):this.opened=!0;const e=this.inputRef.value;if(0===e.value.length&&"Backspace"===t.key&&this.keyCount++,"Backspace"===t.key&&""===e.value&&this.keyCount>1){this.keyCount=0;const t=[...this.items];t.pop(),this.items=t}this.inputValue=e.value,this.inputValue.trim()?this.filtered=this.suggestions.filter(t=>t.value.includes(this.inputValue)&&-1===this.items.findIndex(e=>e.value===t.value)):this.filtered=this.suggestions}connectedCallback(){super.connectedCallback(),document.addEventListener("keydown",this.onTabClicked),setTimeout(()=>{this.filtered=this.suggestions.filter(t=>t.value.includes(this.inputValue)&&-1===this.items.findIndex(e=>e.value===t.value))},50)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("keydown",this.onTabClicked)}render(){return B`<div class="container" @click=${this.setFocus}>
3
- <span
4
- >${Ht(this.items,t=>t.value,(t,e)=>B`<div
5
- .style="background:${this.primary};color:${this.primaryText}"
6
- class="chips"
7
- >
8
- <div>
9
- ${t.value}
10
- ${this.removeable?B`<button
11
- @click=${()=>this.removeItems(e)}
12
- class="remove_button"
13
- >
14
- <svg
15
- xmlns="http://www.w3.org/2000/svg"
16
- viewBox="0 0 24 24"
17
- width="13"
18
- height="20"
19
- fill="${this.primaryText}"
20
- >
21
- <path fill="none" d="M0 0h24v24H0z" />
22
- <path
23
- d="M12 10.586l4.95-4.95 1.414 1.414-4.95 4.95 4.95 4.95-1.414 1.414-4.95-4.95-4.95 4.95-1.414-1.414 4.95-4.95-4.95-4.95L7.05 5.636z"
24
- />
25
- </svg>
26
- </button>`:null}
27
- </div>
28
- </div>`)}
29
- <input
30
- dir="auto"
31
- ${Pt(this.inputRef)}
32
- .placeholder=${this.placeholder}
33
- .max=${this.max}
34
- @keyup=${this.keypress}
35
- @focus=${()=>{this.focused=!0,this.suggestions.length>0&&setTimeout(()=>{this.opened=!0},200)}}
36
- @blur=${()=>{this.focused=!1,setTimeout(()=>{this.opened=!1},200)}}
37
- /></span>
38
- </div>`}};Mt.styles=((t,...e)=>{const s=1===t.length?t[0]:e.reduce((e,i,s)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[s+1],t[0]);return new n(s,t,i)})`
39
- .full-width {
40
- width: 100%;
41
- }
42
- .container {
43
- border: 1px solid grey;
44
- border-radius: 0.25rem;
45
- line-height: 1.5;
46
- background: padding-box rgb(255, 255, 255);
47
- outline: 1px solid transparent;
48
- font-family: Arial, Helvetica, sans-serif;
49
- box-sizing: border-box;
1
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[6442],{66442(e,i,a){a.r(i),a.d(i,{CouchMark:()=>t});var s=a(59929);class t extends s.WF{constructor(){super()}render(){return s.qy`<div class="pulser">
2
+ <div class="pulse pulse1"></div>
3
+ <div class="pulse pulse2"></div>
4
+ <div class="pulse pulse4"></div>
5
+ </div>`}}t.properties={name:{}},t.styles=s.AH`
6
+ :host {
50
7
  position: relative;
8
+ display: inline-block;
51
9
  }
52
- .container:focus {
53
- border-color: blue;
10
+
11
+ .pulse {
12
+ position: absolute;
13
+ top: 50%;
14
+ left: 50%;
15
+ transform: translate(-50%, -50%);
16
+ width: 30px;
17
+ height: 30px;
18
+ -webkit-border-radius: 50%;
19
+ -moz-border-radius: 50%;
20
+ border-radius: 50%;
21
+ -webkit-box-sizing: border-box;
22
+ -moz-box-sizing: border-box;
23
+ box-sizing: border-box;
54
24
  }
55
- .suggestion-btn {
56
- background: #fff;
25
+
26
+ .pulse1 {
27
+ border: 13px solid #845EC2;
28
+ -webkit-animation: pulse1 2s linear infinite;
29
+ -moz-animation: pulse1 2s linear infinite;
30
+ animation: pulse1 2s linear infinite;
57
31
  }
58
- .suggestion-btn:hover {
59
- background: #f5f5f5;
32
+
33
+ .pulse2 {
34
+ border: 8px solid #845EC2;
35
+ opacity: 0.2;
36
+ -webkit-animation: pulse2 2s linear infinite;
37
+ -moz-animation: pulse2 2s linear infinite;
38
+ animation: pulse2 2s linear infinite;
60
39
  }
61
- .suggestions-holder {
62
- position: absolute;
63
- top: 105%;
64
- left: 0;
65
- width: 100%;
66
- height: 100%;
67
- background-color: #fff;
68
- /* transition: all 0.3s ease-in-out; */
40
+
41
+ .pulse3 {
42
+ border: 10px solid #845EC2;
43
+ opacity: 0.5;
44
+ -webkit-animation: pulse3 2s linear infinite;
45
+ -moz-animation: pulse3 2s linear infinite;
46
+ animation: pulse3 2s linear infinite;
69
47
  }
70
- .suggestions-content {
71
- top: 105%;
72
- left: 0;
73
- max-height: 400px;
74
- overflow-y: auto;
75
- overflow-x: hidden;
76
- max-width: 400px;
77
- width: 100%;
78
- padding: 10px;
79
- box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.1);
80
- z-index: 99;
48
+
49
+ .pulse4 {
50
+ border: 15px solid #845EC2;
51
+ opacity: 0.1;
52
+ -webkit-animation: pulse4 2s linear infinite;
53
+ -moz-animation: pulse4 2s linear infinite;
54
+ animation: pulse4 2s linear infinite;
55
+ width: 30px;
56
+ height: 30px;
81
57
  }
82
- .chips {
83
- border-radius: 30px;
84
- padding: 0 28px;
85
- background-color: blue;
86
- color: #fff;
87
- display: inline-block;
88
- margin: 5px;
89
- position: relative;
90
- font-family: Arial, Helvetica, sans-serif;
91
- font-size: 14px;
92
- animation: jackInTheBox 1s cubic-bezier(0.175, 0.885, 0.32, 1.275);
58
+
59
+ /* moz */
60
+ @-moz-keyframes pulse1 {
61
+ 0% {
62
+ -moz-transform: scale(0);
63
+ opacity: 0;
64
+ }
65
+ 20% {
66
+ -moz-transform: scale(0);
67
+ opacity: 0;
68
+ }
69
+ 40% {
70
+ -moz-transform: scale(0.2);
71
+ opacity: 0.4;
72
+ }
73
+ 60% {
74
+ -moz-transform: scale(0.4);
75
+ opacity: 0.6;
76
+ }
77
+ 100% {
78
+ -moz-transform: scale(0.6);
79
+ opacity: 0;
80
+ }
93
81
  }
94
82
 
95
- @keyframes jackInTheBox {
96
- from {
83
+ @-moz-keyframes pulse2 {
84
+ 0% {
85
+ -moz-transform: scale(0);
97
86
  opacity: 0;
98
- transform: scale(0.1) rotate(30deg);
99
- transform-origin: center bottom;
100
87
  }
88
+ 25% {
89
+ -moz-transform: scale(0.2);
90
+ opacity: 0.7;
91
+ }
92
+ 40% {
93
+ -moz-transform: scale(0.4);
94
+ opacity: 0.5;
95
+ }
96
+ 65% {
97
+ -moz-transform: scale(0.6);
98
+ opacity: 0.3;
99
+ }
100
+ 100% {
101
+ -moz-transform: scale(0.8);
102
+ opacity: 0;
103
+ }
104
+ }
101
105
 
106
+ @-moz-keyframes pulse3 {
107
+ 0% {
108
+ -moz-transform: scale(0.1);
109
+ opacity: 0;
110
+ }
111
+ 25% {
112
+ -moz-transform: scale(0.3);
113
+ opacity: 0.7;
114
+ }
102
115
  50% {
103
- transform: rotate(-10deg);
116
+ -moz-transform: scale(0.5);
117
+ opacity: 0.5;
104
118
  }
105
-
106
- 70% {
107
- transform: rotate(3deg);
119
+ 75% {
120
+ -moz-transform: scale(0.6);
121
+ opacity: 0.3;
108
122
  }
109
-
110
- to {
111
- opacity: 1;
112
- transform: scale(1);
123
+ 100% {
124
+ -moz-transform: scale(0.66);
125
+ opacity: 0;
113
126
  }
114
127
  }
115
- .remove_button {
116
- padding: 1px;
117
- background-color: #484553a6;
118
- border-radius: 100%;
119
- height: 17px;
120
- display: flex;
121
- align-items: center;
122
- justify-content: center;
123
- position: absolute;
124
- right: 2px;
125
- top: 50%;
126
- transform: translateY(-50%);
127
- transition: transform 0.2s ease-in-out;
128
+
129
+ @-moz-keyframes pulse4 {
130
+ 0% {
131
+ -moz-transform: scale(0.1);
132
+ opacity: 0;
133
+ }
134
+ 30% {
135
+ -moz-transform: scale(0.3);
136
+ opacity: 0.6;
137
+ }
138
+ 80% {
139
+ -moz-transform: scale(0.6);
140
+ opacity: 0.4;
141
+ }
142
+ 100% {
143
+ -moz-transform: scale(0.8);
144
+ opacity: 0;
145
+ }
128
146
  }
129
- .remove_button:hover {
130
- transform: translateY(-50%) scale(1.2);
147
+
148
+ /* webkit */
149
+ @-webkit-keyframes pulse1 {
150
+ 0% {
151
+ -webkit-transform: scale(0);
152
+ opacity: 0;
153
+ }
154
+ 20% {
155
+ -webkit-transform: scale(0);
156
+ opacity: 0;
157
+ }
158
+ 40% {
159
+ -webkit-transform: scale(0.2);
160
+ opacity: 0.4;
161
+ }
162
+ 60% {
163
+ -webkit-transform: scale(0.4);
164
+ opacity: 0.6;
165
+ }
166
+ 100% {
167
+ -webkit-transform: scale(0.6);
168
+ opacity: 0;
169
+ }
131
170
  }
132
- input {
133
- height: 30px;
134
- display: inline-block;
135
- padding: 10px;
136
- font-size: 14px;
137
- font-weight: 400;
138
- line-height: 1.5;
139
- color: #212529;
140
- background: #fff;
141
- background-clip: padding-box;
142
- border: 1px solid #ced4da;
143
- -webkit-appearance: none;
144
- -moz-appearance: none;
145
- appearance: none;
146
- margin: 0;
147
- font-family: Arial;
148
- border: none;
149
- outline: none;
150
- box-sizing: border-box;
171
+
172
+ @-webkit-keyframes pulse2 {
173
+ 0% {
174
+ -webkit-transform: scale(0);
175
+ opacity: 0;
176
+ }
177
+ 25% {
178
+ -webkit-transform: scale(0.2);
179
+ opacity: 0.7;
180
+ }
181
+ 40% {
182
+ -webkit-transform: scale(0.4);
183
+ opacity: 0.5;
184
+ }
185
+ 65% {
186
+ -webkit-transform: scale(0.6);
187
+ opacity: 0.3;
188
+ }
189
+ 100% {
190
+ -webkit-transform: scale(0.8);
191
+ opacity: 0;
192
+ }
151
193
  }
152
- input:hover {
153
- border: none;
154
- outline: none;
194
+
195
+ @-webkit-keyframes pulse3 {
196
+ 0% {
197
+ -webkit-transform: scale(0.1);
198
+ opacity: 0;
199
+ }
200
+ 25% {
201
+ -webkit-transform: scale(0.3);
202
+ opacity: 0.7;
203
+ }
204
+ 50% {
205
+ -webkit-transform: scale(0.5);
206
+ opacity: 0.5;
207
+ }
208
+ 75% {
209
+ -webkit-transform: scale(0.6);
210
+ opacity: 0.3;
211
+ }
212
+ 100% {
213
+ -webkit-transform: scale(0.66);
214
+ opacity: 0;
215
+ }
155
216
  }
156
- button {
157
- position: relative;
158
- display: inline-block;
159
- font-weight: 400;
160
- text-align: center;
161
- white-space: nowrap;
162
- vertical-align: middle;
163
- -webkit-user-select: none;
164
- -moz-user-select: none;
165
- -ms-user-select: none;
166
- user-select: none;
167
- border: 1px solid transparent;
168
- font-family: Arial;
169
- padding: 0.375rem 0.35rem;
170
- font-size: 13px;
171
- line-height: 1.5;
172
- border-radius: 3px;
173
- text-transform: none;
174
- transition: color 0.15s ease-in-out, background 0.15s ease-in-out,
175
- border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
217
+
218
+ @-webkit-keyframes pulse4 {
219
+ 0% {
220
+ -webkit-transform: scale(0.1);
221
+ opacity: 0;
222
+ }
223
+ 30% {
224
+ -webkit-transform: scale(0.3);
225
+ opacity: 0.6;
226
+ }
227
+ 80% {
228
+ -webkit-transform: scale(0.6);
229
+ opacity: 0.4;
230
+ }
231
+ 100% {
232
+ -webkit-transform: scale(0.8);
233
+ opacity: 0;
234
+ }
176
235
  }
177
- `,Nt([at({type:Boolean})],Mt.prototype,"removeable",void 0),Nt([at({type:String})],Mt.prototype,"value",void 0),Nt([at({type:String})],Mt.prototype,"inputValue",void 0),Nt([at({type:String})],Mt.prototype,"placeholder",void 0),Nt([at({type:String})],Mt.prototype,"max",void 0),Nt([at({type:String})],Mt.prototype,"primaryText",void 0),Nt([at({type:String})],Mt.prototype,"primary",void 0),Nt([at({type:Number})],Mt.prototype,"maxItems",void 0),Nt([at({type:Boolean})],Mt.prototype,"focused",void 0),Nt([at({type:Array})],Mt.prototype,"items",void 0),Nt([at({type:Array})],Mt.prototype,"suggestions",void 0),Nt([at({type:Array})],Mt.prototype,"filtered",void 0),Nt([at({type:Boolean})],Mt.prototype,"opened",void 0),Nt([at({type:Boolean})],Mt.prototype,"freeSolo",void 0),Mt=Nt([(t=>e=>"function"==typeof e?((t,e)=>(customElements.define(t,e),e))(t,e):((t,e)=>{const{kind:i,elements:s}=e;return{kind:i,elements:s,finisher(e){customElements.define(t,e)}}})(t,e))("cdtr-chips-input")],Mt)}}]);
236
+ `,customElements.define("cdtr-couch-mark",t)}}]);
Binary file