@creaditor/newsletter-starterkit 1.0.54 → 1.0.56

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 (55) hide show
  1. package/dist/1260.creaditor.bundle.js +66 -22
  2. package/dist/1260.creaditor.bundle.js.gz +0 -0
  3. package/dist/1271.creaditor.bundle.js +1 -439
  4. package/dist/1271.creaditor.bundle.js.gz +0 -0
  5. package/dist/1403.creaditor.bundle.js +110 -0
  6. package/dist/1403.creaditor.bundle.js.gz +0 -0
  7. package/dist/1565.creaditor.bundle.js +106 -105
  8. package/dist/1565.creaditor.bundle.js.gz +0 -0
  9. package/dist/168.creaditor.bundle.js +4 -4
  10. package/dist/168.creaditor.bundle.js.gz +0 -0
  11. package/dist/170.creaditor.bundle.js +21 -20
  12. package/dist/170.creaditor.bundle.js.gz +0 -0
  13. package/dist/2384.creaditor.bundle.js +4 -4
  14. package/dist/2384.creaditor.bundle.js.gz +0 -0
  15. package/dist/4186.creaditor.bundle.js +1 -1
  16. package/dist/4186.creaditor.bundle.js.gz +0 -0
  17. package/dist/453.creaditor.bundle.js +11 -111
  18. package/dist/453.creaditor.bundle.js.gz +0 -0
  19. package/dist/4569.creaditor.bundle.js +64 -257
  20. package/dist/4569.creaditor.bundle.js.gz +0 -0
  21. package/dist/4819.creaditor.bundle.js +1 -1
  22. package/dist/4819.creaditor.bundle.js.gz +0 -0
  23. package/dist/4970.creaditor.bundle.js +1314 -0
  24. package/dist/4970.creaditor.bundle.js.gz +0 -0
  25. package/dist/5340.creaditor.bundle.js +19 -18
  26. package/dist/5340.creaditor.bundle.js.gz +0 -0
  27. package/dist/574.creaditor.bundle.js +5 -5
  28. package/dist/574.creaditor.bundle.js.gz +0 -0
  29. package/dist/5926.creaditor.bundle.js +10 -6
  30. package/dist/5926.creaditor.bundle.js.gz +0 -0
  31. package/dist/752.creaditor.bundle.js +4 -4
  32. package/dist/752.creaditor.bundle.js.gz +0 -0
  33. package/dist/763.creaditor.bundle.js +34 -1
  34. package/dist/763.creaditor.bundle.js.gz +0 -0
  35. package/dist/7789.creaditor.bundle.js +25 -0
  36. package/dist/7789.creaditor.bundle.js.LICENSE.txt +32 -0
  37. package/dist/7789.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  38. package/dist/7789.creaditor.bundle.js.gz +0 -0
  39. package/dist/7937.creaditor.bundle.js +17 -17
  40. package/dist/7937.creaditor.bundle.js.gz +0 -0
  41. package/dist/8173.creaditor.bundle.js +1 -1
  42. package/dist/8173.creaditor.bundle.js.gz +0 -0
  43. package/dist/8646.creaditor.bundle.js +1 -0
  44. package/dist/8646.creaditor.bundle.js.gz +0 -0
  45. package/dist/9158.creaditor.bundle.js +613 -0
  46. package/dist/9158.creaditor.bundle.js.LICENSE.txt +10 -0
  47. package/dist/9158.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  48. package/dist/9158.creaditor.bundle.js.gz +0 -0
  49. package/dist/9994.creaditor.bundle.js +114 -0
  50. package/dist/9994.creaditor.bundle.js.gz +0 -0
  51. package/dist/creaditor.bundle.js +1653 -565
  52. package/dist/creaditor.bundle.js.gz +0 -0
  53. package/dist/service-worker.js +1 -1
  54. package/dist/service-worker.js.gz +0 -0
  55. package/package.json +1 -1
Binary file
@@ -1,4 +1,4 @@
1
- "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[5340],{12258(e,t,o){o.d(t,{A:()=>i});var n=o(59929);class s extends n.WF{constructor(){super(),this.label="",this.open=!0}toggle(){this.open=!this.open}render(){return n.qy`
1
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[5340],{12258(e,t,o){o.d(t,{A:()=>r});var n=o(59929),s=o(40648);class i extends n.WF{constructor(){super(),this.label="",this.open=!0,this.persistKey=""}toggle(){this.open=!this.open,(0,s.Q)(this.persistKey,this.open)}render(){return n.qy`
2
2
  <div class="section">
3
3
  <div class="header" @click=${this.toggle}>
4
4
  <span class="title"><lang-text text="${this.label}"></lang-text></span>
@@ -12,44 +12,44 @@
12
12
  </div>
13
13
  </div>
14
14
  </div>
15
- `}}s.styles=n.AH`
15
+ `}}i.styles=n.AH`
16
16
  :host {
17
17
  display: block;
18
18
  direction: var(--direction-locale, ltr);
19
19
  --editor-container-inline-padding: 0;
20
20
  }
21
21
  .section {
22
- border-bottom: 1px solid #eaeaee;
22
+ border-bottom: 1px solid var(--color-border);
23
23
  }
24
24
  .header {
25
25
  display: flex;
26
26
  align-items: center;
27
27
  justify-content: space-between;
28
- padding: 12px 16px;
28
+ padding: var(--space-3) var(--space-4);
29
29
  cursor: pointer;
30
30
  user-select: none;
31
31
  }
32
32
  .title {
33
- font-size: 12.5px;
33
+ font-size: var(--text-md);
34
34
  font-weight: 600;
35
- color: #222;
35
+ color: var(--color-text);
36
36
  letter-spacing: 0.01em;
37
37
  }
38
38
  .chevron {
39
39
  width: 16px;
40
40
  height: 16px;
41
- transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), color 0.15s ease;
42
- color: #ccc;
41
+ transition: transform var(--duration-normal) var(--ease-default), color var(--duration-fast) var(--ease-default);
42
+ color: var(--color-text-faint);
43
43
  }
44
44
  .header:hover .chevron {
45
- color: #888;
45
+ color: var(--color-text-muted);
46
46
  }
47
47
  .chevron.open {
48
48
  transform: rotate(180deg);
49
49
  }
50
50
  .content {
51
51
  overflow: hidden;
52
- transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.2s ease;
52
+ transition: max-height var(--duration-normal) var(--ease-default), opacity var(--duration-fast) var(--ease-default);
53
53
  max-height: 0;
54
54
  opacity: 0;
55
55
  }
@@ -58,37 +58,38 @@
58
58
  opacity: 1;
59
59
  }
60
60
  .content-inner {
61
- padding: 0 16px 12px 16px;
61
+ padding: var(--space-3) var(--space-4) var(--space-3) var(--space-4);
62
62
  }
63
- `,s.properties={label:{type:String},open:{type:Boolean}},customElements.define("cdtr-editor-section",s);const i=(e,t)=>n.qy`
63
+ `,i.properties={label:{type:String},open:{type:Boolean},persistKey:{type:String}},customElements.define("cdtr-editor-section",i);const r=(e,t)=>n.qy`
64
64
  <cdtr-editor-section
65
65
  .label=${e.label}
66
66
  .open=${!1!==e.open}
67
+ .persistKey=${e.persistKey||""}
67
68
  >
68
69
  ${t}
69
70
  </cdtr-editor-section>
70
- `},45340(e,t,o){o.r(t),o.d(t,{SettingEditor:()=>l});var n=o(59929),s=o(86319),i=o(36565),c=(o(12258),o(79307));class l extends n.WF{constructor(){super(),this.onInspect=this.onInspect.bind(this),this.name="",this.element_ID=" ",this.cmds={onToggleDisplayMode:(e,t)=>{i.Ay.store().execCommand(`show_on_${e}`,t),this[`show_on_${e}`]=t},onChangeElementID(e){i.Ay.store().execCommand("element_ID",e.target.value)},onChangeName(e){i.Ay.store().execCommand("name",e.target.value)}}}onInspect(){if(i.Ay.components.length>0){const e=i.Ay.components[0].props;this.show_on_desktop=!!e.show_on_desktop,this.show_on_tablet=!!e.show_on_tablet,this.show_on_mobile=!!e.show_on_mobile,this.name=e.name||"",this.element_ID=e.element_ID||""}}connectedCallback(){super.connectedCallback(),i.Ay.on("select",this.onInspect),i.Ay.on("update",this.onInspect),this.onInspect()}disconnectedCallback(){super.disconnectedCallback(),i.Ay.off("select",this.onInspect),i.Ay.off("update",this.onInspect)}render(){const e="block"===i.Ay.getSelectedComponent()[0].type,t="web"===s.M.get("config","channel");return n.qy`
71
+ `},40648(e,t,o){o.d(t,{Q:()=>r,i:()=>i});const n="cdtr:section-open";function s(){try{const e=localStorage.getItem(n);return e?JSON.parse(e):{}}catch(e){return{}}}function i(e){if(!e)return;const t=s();return Object.prototype.hasOwnProperty.call(t,e)?!!t[e]:void 0}function r(e,t){if(!e)return;const o=s();o[e]=!!t,function(e){try{localStorage.setItem(n,JSON.stringify(e))}catch(e){}}(o)}},45340(e,t,o){o.r(t),o.d(t,{SettingEditor:()=>a});var n=o(59929),s=o(86319),i=o(36565),r=(o(12258),o(79307));class a extends n.WF{constructor(){super(),this.onInspect=this.onInspect.bind(this),this.name="",this.element_ID=" ",this.cmds={onToggleDisplayMode:(e,t)=>{i.Ay.store().execCommand(`show_on_${e}`,t),this[`show_on_${e}`]=t},onChangeElementID(e){i.Ay.store().execCommand("element_ID",e.target.value)},onChangeName(e){i.Ay.store().execCommand("name",e.target.value)}}}onInspect(){if(i.Ay.components.length>0){const e=i.Ay.components[0].props;this.show_on_desktop=!!e.show_on_desktop,this.show_on_tablet=!!e.show_on_tablet,this.show_on_mobile=!!e.show_on_mobile,this.name=e.name||"",this.element_ID=e.element_ID||""}}connectedCallback(){super.connectedCallback(),i.Ay.on("select",this.onInspect),i.Ay.on("update",this.onInspect),this.onInspect()}disconnectedCallback(){super.disconnectedCallback(),i.Ay.off("select",this.onInspect),i.Ay.off("update",this.onInspect)}render(){const e="block"===i.Ay.getSelectedComponent()[0].type,t="web"===s.M.get("config","channel");return n.qy`
71
72
  ${e&&t?n.qy`<cdtr-editor-section label="display_mode" .open=${!0}>
72
73
  <div class="device-toggle-row">
73
74
  <div
74
75
  class="device-toggle-btn ${this.show_on_desktop?"active":""}"
75
76
  @click=${()=>this.cmds.onToggleDisplayMode("desktop",!this.show_on_desktop)}
76
77
  >
77
- <svg width="14" height="14" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">${c.oe}</svg>
78
+ <svg width="14" height="14" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">${r.oe}</svg>
78
79
  <lang-text text="desktop"></lang-text>
79
80
  </div>
80
81
  <div
81
82
  class="device-toggle-btn ${this.show_on_tablet?"active":""}"
82
83
  @click=${()=>this.cmds.onToggleDisplayMode("tablet",!this.show_on_tablet)}
83
84
  >
84
- <svg width="14" height="14" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">${c.kN}</svg>
85
+ <svg width="14" height="14" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">${r.kN}</svg>
85
86
  <lang-text text="tablet"></lang-text>
86
87
  </div>
87
88
  <div
88
89
  class="device-toggle-btn ${this.show_on_mobile?"active":""}"
89
90
  @click=${()=>this.cmds.onToggleDisplayMode("mobile",!this.show_on_mobile)}
90
91
  >
91
- <svg width="14" height="14" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">${c.S9}</svg>
92
+ <svg width="14" height="14" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">${r.S9}</svg>
92
93
  <lang-text text="mobile"></lang-text>
93
94
  </div>
94
95
  </div>
@@ -119,7 +120,7 @@
119
120
  ></cdtr-input>
120
121
  </cdtr-row>
121
122
  </cdtr-editor-section>
122
- `}}l.properties={name:{},element_ID:{},show_on_desktop:{},show_on_tablet:{},show_on_mobile:{}},l.styles=n.AH`
123
+ `}}a.properties={name:{},element_ID:{},show_on_desktop:{},show_on_tablet:{},show_on_mobile:{}},a.styles=n.AH`
123
124
  :host {
124
125
  direction: var(--direction-locale);
125
126
  }
@@ -152,4 +153,4 @@
152
153
  background: color-mix(in srgb, var(--accent, #5B5FC7) 12%, transparent);
153
154
  color: var(--accent, #5B5FC7);
154
155
  }
155
- `,customElements.define("cdtr-setting-editor",l)}}]);
156
+ `,customElements.define("cdtr-setting-editor",a)}}]);
Binary file
@@ -1,5 +1,5 @@
1
1
  /*! For license information please see 574.creaditor.bundle.js.LICENSE.txt */
2
- "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[574],{74396(e,t,n){n.d(t,{L:()=>i});n(69130);const i=[{properties:{animationConfig:{type:Object},entryAnimation:{observer:"_entryAnimationChanged",type:String},exitAnimation:{observer:"_exitAnimationChanged",type:String}},_entryAnimationChanged:function(){this.animationConfig=this.animationConfig||{},this.animationConfig.entry=[{name:this.entryAnimation,node:this}]},_exitAnimationChanged:function(){this.animationConfig=this.animationConfig||{},this.animationConfig.exit=[{name:this.exitAnimation,node:this}]},_copyProperties:function(e,t){for(var n in t)e[n]=t[n]},_cloneConfig:function(e){var t={isClone:!0};return this._copyProperties(t,e),t},_getAnimationConfigRecursive:function(e,t,n){var i;if(this.animationConfig)if(this.animationConfig.value&&"function"==typeof this.animationConfig.value)this._warn(this._logf("playAnimation","Please put 'animationConfig' inside of your components 'properties' object instead of outside of it."));else if(i=e?this.animationConfig[e]:this.animationConfig,Array.isArray(i)||(i=[i]),i)for(var o,a=0;o=i[a];a++)if(o.animatable)o.animatable._getAnimationConfigRecursive(o.type||e,t,n);else if(o.id){var r=t[o.id];r?(r.isClone||(t[o.id]=this._cloneConfig(r),r=t[o.id]),this._copyProperties(r,o)):t[o.id]=o}else n.push(o)},getAnimationConfig:function(e){var t={},n=[];for(var i in this._getAnimationConfigRecursive(e,t,n),t)n.push(t[i]);return n}},{_configureAnimations:function(e){var t=[],n=[];if(e.length>0)for(let t,i=0;t=e[i];i++){let e=document.createElement(t.name);if(e.isNeonAnimation){let i=null;e.configure||(e.configure=function(e){return null}),i=e.configure(t),n.push({result:i,config:t,neonAnimation:e})}else console.warn(this.is+":",t.name,"not found!")}for(var i=0;i<n.length;i++){let e=n[i].result,o=n[i].config,a=n[i].neonAnimation;try{"function"!=typeof e.cancel&&(e=document.timeline.play(e))}catch(t){e=null,console.warn("Couldnt play","(",o.name,").",t)}e&&t.push({neonAnimation:a,config:o,animation:e})}return t},_shouldComplete:function(e){for(var t=!0,n=0;n<e.length;n++)if("finished"!=e[n].animation.playState){t=!1;break}return t},_complete:function(e){for(var t=0;t<e.length;t++)e[t].neonAnimation.complete(e[t].config);for(t=0;t<e.length;t++)e[t].animation.cancel()},playAnimation:function(e,t){var n=this.getAnimationConfig(e);if(n){this._active=this._active||{},this._active[e]&&(this._complete(this._active[e]),delete this._active[e]);var i=this._configureAnimations(n);if(0!=i.length){this._active[e]=i;for(var o=0;o<i.length;o++)i[o].animation.onfinish=function(){this._shouldComplete(i)&&(this._complete(i),delete this._active[e],this.fire("neon-animation-finish",t,{bubbles:!1}))}.bind(this)}else this.fire("neon-animation-finish",t,{bubbles:!1})}},cancelAnimation:function(){for(var e in this._active){var t=this._active[e];for(var n in t)t[n].animation.cancel()}this._active={}}}]},50574(e,t,n){var i=n(69130),o=n(35915),a=(n(12479),n(19)),r=n(95586),s=n(53874),l=n(47351);(0,r.b)({_template:l.q`
2
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[574],{50574(e,t,n){var i=n(69130),o=n(35915),a=(n(12479),n(19)),r=n(95586),s=n(53874),l=n(47351);(0,r.b)({_template:l.q`
3
3
  <style>
4
4
  :host {
5
5
  @apply --layout-inline;
@@ -20,7 +20,7 @@
20
20
  display: none;
21
21
  }
22
22
  </style>
23
- `,is:"iron-icon",properties:{icon:{type:String},theme:{type:String},src:{type:String},_meta:{value:i.C6.create("iron-meta",{type:"iconset"})}},observers:["_updateIcon(_meta, isAttached)","_updateIcon(theme, isAttached)","_srcChanged(src, isAttached)","_iconChanged(icon, isAttached)"],_DEFAULT_ICONSET:"icons",_iconChanged:function(e){var t=(e||"").split(":");this._iconName=t.pop(),this._iconsetName=t.pop()||this._DEFAULT_ICONSET,this._updateIcon()},_srcChanged:function(e){this._updateIcon()},_usesIconset:function(){return this.icon||!this.src},_updateIcon:function(){this._usesIconset()?(this._img&&this._img.parentNode&&(0,s.tT)(this.root).removeChild(this._img),""===this._iconName?this._iconset&&this._iconset.removeIcon(this):this._iconsetName&&this._meta&&(this._iconset=this._meta.byKey(this._iconsetName),this._iconset?(this._iconset.applyIcon(this,this._iconName,this.theme),this.unlisten(window,"iron-iconset-added","_updateIcon")):this.listen(window,"iron-iconset-added","_updateIcon"))):(this._iconset&&this._iconset.removeIcon(this),this._img||(this._img=document.createElement("img"),this._img.style.width="100%",this._img.style.height="100%",this._img.draggable=!1),this._img.src=this.src,(0,s.tT)(this.root).appendChild(this._img))}});n(95813);var c=n(90703),p=n(68876),d=n(74396);(0,r.b)({_template:l.q`
23
+ `,is:"iron-icon",properties:{icon:{type:String},theme:{type:String},src:{type:String},_meta:{value:i.C6.create("iron-meta",{type:"iconset"})}},observers:["_updateIcon(_meta, isAttached)","_updateIcon(theme, isAttached)","_srcChanged(src, isAttached)","_iconChanged(icon, isAttached)"],_DEFAULT_ICONSET:"icons",_iconChanged:function(e){var t=(e||"").split(":");this._iconName=t.pop(),this._iconsetName=t.pop()||this._DEFAULT_ICONSET,this._updateIcon()},_srcChanged:function(e){this._updateIcon()},_usesIconset:function(){return this.icon||!this.src},_updateIcon:function(){this._usesIconset()?(this._img&&this._img.parentNode&&(0,s.tT)(this.root).removeChild(this._img),""===this._iconName?this._iconset&&this._iconset.removeIcon(this):this._iconsetName&&this._meta&&(this._iconset=this._meta.byKey(this._iconsetName),this._iconset?(this._iconset.applyIcon(this,this._iconName,this.theme),this.unlisten(window,"iron-iconset-added","_updateIcon")):this.listen(window,"iron-iconset-added","_updateIcon"))):(this._iconset&&this._iconset.removeIcon(this),this._img||(this._img=document.createElement("img"),this._img.style.width="100%",this._img.style.height="100%",this._img.draggable=!1),this._img.src=this.src,(0,s.tT)(this.root).appendChild(this._img))}});n(9158);var p=n(90703),c=n(68876),d=n(74396);(0,r.b)({_template:l.q`
24
24
  <style>
25
25
  :host {
26
26
  position: fixed;
@@ -39,7 +39,7 @@
39
39
  <div id="contentWrapper">
40
40
  <slot id="content" name="dropdown-content"></slot>
41
41
  </div>
42
- `,is:"iron-dropdown",behaviors:[c.x,o.D,p.r,d.L],properties:{horizontalAlign:{type:String,value:"left",reflectToAttribute:!0},verticalAlign:{type:String,value:"top",reflectToAttribute:!0},openAnimationConfig:{type:Object},closeAnimationConfig:{type:Object},focusTarget:{type:Object},noAnimations:{type:Boolean,value:!1},allowOutsideScroll:{type:Boolean,value:!1,observer:"_allowOutsideScrollChanged"}},listeners:{"neon-animation-finish":"_onNeonAnimationFinish"},observers:["_updateOverlayPosition(positionTarget, verticalAlign, horizontalAlign, verticalOffset, horizontalOffset)"],get containedElement(){for(var e=(0,s.tT)(this.$.content).getDistributedNodes(),t=0,n=e.length;t<n;t++)if(e[t].nodeType===Node.ELEMENT_NODE)return e[t]},ready:function(){this.scrollAction||(this.scrollAction=this.allowOutsideScroll?"refit":"lock"),this._readied=!0},attached:function(){this.sizingTarget&&this.sizingTarget!==this||(this.sizingTarget=this.containedElement||this)},detached:function(){this.cancelAnimation()},_openedChanged:function(){this.opened&&this.disabled?this.cancel():(this.cancelAnimation(),this._updateAnimationConfig(),p.N._openedChanged.apply(this,arguments))},_renderOpened:function(){!this.noAnimations&&this.animationConfig.open?(this.$.contentWrapper.classList.add("animating"),this.playAnimation("open")):p.N._renderOpened.apply(this,arguments)},_renderClosed:function(){!this.noAnimations&&this.animationConfig.close?(this.$.contentWrapper.classList.add("animating"),this.playAnimation("close")):p.N._renderClosed.apply(this,arguments)},_onNeonAnimationFinish:function(){this.$.contentWrapper.classList.remove("animating"),this.opened?this._finishRenderOpened():this._finishRenderClosed()},_updateAnimationConfig:function(){for(var e=this.containedElement,t=[].concat(this.openAnimationConfig||[]).concat(this.closeAnimationConfig||[]),n=0;n<t.length;n++)t[n].node=e;this.animationConfig={open:this.openAnimationConfig,close:this.closeAnimationConfig}},_updateOverlayPosition:function(){this.isAttached&&this.notifyResize()},_allowOutsideScrollChanged:function(e){this._readied&&(e?this.scrollAction&&"lock"!==this.scrollAction||(this.scrollAction="refit"):this.scrollAction="lock")},_applyFocus:function(){var e=this.focusTarget||this.containedElement;e&&this.opened&&!this.noAutoFocus?e.focus():p.N._applyFocus.apply(this,arguments)}});const h={properties:{animationTiming:{type:Object,value:function(){return{duration:500,easing:"cubic-bezier(0.4, 0, 0.2, 1)",fill:"both"}}}},isNeonAnimation:!0,created:function(){document.body.animate||console.warn("No web animations detected. This element will not function without a web animations polyfill.")},timingFromConfig:function(e){if(e.timing)for(var t in e.timing)this.animationTiming[t]=e.timing[t];return this.animationTiming},setPrefixedProperty:function(e,t,n){for(var i,o={transform:["webkitTransform"],transformOrigin:["mozTransformOrigin","webkitTransformOrigin"]}[t],a=0;i=o[a];a++)e.style[i]=n;e.style[t]=n},complete:function(e){}};(0,r.b)({is:"fade-in-animation",behaviors:[h],configure:function(e){var t=e.node;return this._effect=new KeyframeEffect(t,[{opacity:"0"},{opacity:"1"}],this.timingFromConfig(e)),this._effect}}),(0,r.b)({is:"fade-out-animation",behaviors:[h],configure:function(e){var t=e.node;return this._effect=new KeyframeEffect(t,[{opacity:"1"},{opacity:"0"}],this.timingFromConfig(e)),this._effect}});n(45611),n(48176);(0,r.b)({is:"paper-menu-grow-height-animation",_template:null,behaviors:[h],configure:function(e){var t=e.node,n=t.getBoundingClientRect().height;return this._effect=new KeyframeEffect(t,[{height:n/2+"px"},{height:n+"px"}],this.timingFromConfig(e)),this._effect}}),(0,r.b)({is:"paper-menu-grow-width-animation",_template:null,behaviors:[h],configure:function(e){var t=e.node,n=t.getBoundingClientRect().width;return this._effect=new KeyframeEffect(t,[{width:n/2+"px"},{width:n+"px"}],this.timingFromConfig(e)),this._effect}}),(0,r.b)({is:"paper-menu-shrink-width-animation",_template:null,behaviors:[h],configure:function(e){var t=e.node,n=t.getBoundingClientRect().width;return this._effect=new KeyframeEffect(t,[{width:n+"px"},{width:n-n/20+"px"}],this.timingFromConfig(e)),this._effect}}),(0,r.b)({is:"paper-menu-shrink-height-animation",_template:null,behaviors:[h],configure:function(e){var t=e.node,n=t.getBoundingClientRect().height;return this.setPrefixedProperty(t,"transformOrigin","0 0"),this._effect=new KeyframeEffect(t,[{height:n+"px",transform:"translateY(0)"},{height:n/2+"px",transform:"translateY(-20px)"}],this.timingFromConfig(e)),this._effect}});var u={ANIMATION_CUBIC_BEZIER:"cubic-bezier(.3,.95,.5,1)",MAX_ANIMATION_TIME_MS:400};const m=(0,r.b)({_template:l.q`
42
+ `,is:"iron-dropdown",behaviors:[p.x,o.D,c.r,d.L],properties:{horizontalAlign:{type:String,value:"left",reflectToAttribute:!0},verticalAlign:{type:String,value:"top",reflectToAttribute:!0},openAnimationConfig:{type:Object},closeAnimationConfig:{type:Object},focusTarget:{type:Object},noAnimations:{type:Boolean,value:!1},allowOutsideScroll:{type:Boolean,value:!1,observer:"_allowOutsideScrollChanged"}},listeners:{"neon-animation-finish":"_onNeonAnimationFinish"},observers:["_updateOverlayPosition(positionTarget, verticalAlign, horizontalAlign, verticalOffset, horizontalOffset)"],get containedElement(){for(var e=(0,s.tT)(this.$.content).getDistributedNodes(),t=0,n=e.length;t<n;t++)if(e[t].nodeType===Node.ELEMENT_NODE)return e[t]},ready:function(){this.scrollAction||(this.scrollAction=this.allowOutsideScroll?"refit":"lock"),this._readied=!0},attached:function(){this.sizingTarget&&this.sizingTarget!==this||(this.sizingTarget=this.containedElement||this)},detached:function(){this.cancelAnimation()},_openedChanged:function(){this.opened&&this.disabled?this.cancel():(this.cancelAnimation(),this._updateAnimationConfig(),c.N._openedChanged.apply(this,arguments))},_renderOpened:function(){!this.noAnimations&&this.animationConfig.open?(this.$.contentWrapper.classList.add("animating"),this.playAnimation("open")):c.N._renderOpened.apply(this,arguments)},_renderClosed:function(){!this.noAnimations&&this.animationConfig.close?(this.$.contentWrapper.classList.add("animating"),this.playAnimation("close")):c.N._renderClosed.apply(this,arguments)},_onNeonAnimationFinish:function(){this.$.contentWrapper.classList.remove("animating"),this.opened?this._finishRenderOpened():this._finishRenderClosed()},_updateAnimationConfig:function(){for(var e=this.containedElement,t=[].concat(this.openAnimationConfig||[]).concat(this.closeAnimationConfig||[]),n=0;n<t.length;n++)t[n].node=e;this.animationConfig={open:this.openAnimationConfig,close:this.closeAnimationConfig}},_updateOverlayPosition:function(){this.isAttached&&this.notifyResize()},_allowOutsideScrollChanged:function(e){this._readied&&(e?this.scrollAction&&"lock"!==this.scrollAction||(this.scrollAction="refit"):this.scrollAction="lock")},_applyFocus:function(){var e=this.focusTarget||this.containedElement;e&&this.opened&&!this.noAutoFocus?e.focus():c.N._applyFocus.apply(this,arguments)}});const h={properties:{animationTiming:{type:Object,value:function(){return{duration:500,easing:"cubic-bezier(0.4, 0, 0.2, 1)",fill:"both"}}}},isNeonAnimation:!0,created:function(){document.body.animate||console.warn("No web animations detected. This element will not function without a web animations polyfill.")},timingFromConfig:function(e){if(e.timing)for(var t in e.timing)this.animationTiming[t]=e.timing[t];return this.animationTiming},setPrefixedProperty:function(e,t,n){for(var i,o={transform:["webkitTransform"],transformOrigin:["mozTransformOrigin","webkitTransformOrigin"]}[t],a=0;i=o[a];a++)e.style[i]=n;e.style[t]=n},complete:function(e){}};(0,r.b)({is:"fade-in-animation",behaviors:[h],configure:function(e){var t=e.node;return this._effect=new KeyframeEffect(t,[{opacity:"0"},{opacity:"1"}],this.timingFromConfig(e)),this._effect}}),(0,r.b)({is:"fade-out-animation",behaviors:[h],configure:function(e){var t=e.node;return this._effect=new KeyframeEffect(t,[{opacity:"1"},{opacity:"0"}],this.timingFromConfig(e)),this._effect}});n(45611),n(48176);(0,r.b)({is:"paper-menu-grow-height-animation",_template:null,behaviors:[h],configure:function(e){var t=e.node,n=t.getBoundingClientRect().height;return this._effect=new KeyframeEffect(t,[{height:n/2+"px"},{height:n+"px"}],this.timingFromConfig(e)),this._effect}}),(0,r.b)({is:"paper-menu-grow-width-animation",_template:null,behaviors:[h],configure:function(e){var t=e.node,n=t.getBoundingClientRect().width;return this._effect=new KeyframeEffect(t,[{width:n/2+"px"},{width:n+"px"}],this.timingFromConfig(e)),this._effect}}),(0,r.b)({is:"paper-menu-shrink-width-animation",_template:null,behaviors:[h],configure:function(e){var t=e.node,n=t.getBoundingClientRect().width;return this._effect=new KeyframeEffect(t,[{width:n+"px"},{width:n-n/20+"px"}],this.timingFromConfig(e)),this._effect}}),(0,r.b)({is:"paper-menu-shrink-height-animation",_template:null,behaviors:[h],configure:function(e){var t=e.node,n=t.getBoundingClientRect().height;return this.setPrefixedProperty(t,"transformOrigin","0 0"),this._effect=new KeyframeEffect(t,[{height:n+"px",transform:"translateY(0)"},{height:n/2+"px",transform:"translateY(-20px)"}],this.timingFromConfig(e)),this._effect}});var u={ANIMATION_CUBIC_BEZIER:"cubic-bezier(.3,.95,.5,1)",MAX_ANIMATION_TIME_MS:400};const m=(0,r.b)({_template:l.q`
43
43
  <style>
44
44
  :host {
45
45
  display: inline-block;
@@ -97,7 +97,7 @@
97
97
  <slot id="content" name="dropdown-content"></slot>
98
98
  </div>
99
99
  </iron-dropdown>
100
- `,is:"paper-menu-button",behaviors:[o.D,c.x],properties:{opened:{type:Boolean,value:!1,notify:!0,observer:"_openedChanged"},horizontalAlign:{type:String,value:"left",reflectToAttribute:!0},verticalAlign:{type:String,value:"top",reflectToAttribute:!0},dynamicAlign:{type:Boolean},horizontalOffset:{type:Number,value:0,notify:!0},verticalOffset:{type:Number,value:0,notify:!0},noOverlap:{type:Boolean},noAnimations:{type:Boolean,value:!1},ignoreSelect:{type:Boolean,value:!1},closeOnActivate:{type:Boolean,value:!1},openAnimationConfig:{type:Object,value:function(){return[{name:"fade-in-animation",timing:{delay:100,duration:200}},{name:"paper-menu-grow-width-animation",timing:{delay:100,duration:150,easing:u.ANIMATION_CUBIC_BEZIER}},{name:"paper-menu-grow-height-animation",timing:{delay:100,duration:275,easing:u.ANIMATION_CUBIC_BEZIER}}]}},closeAnimationConfig:{type:Object,value:function(){return[{name:"fade-out-animation",timing:{duration:150}},{name:"paper-menu-shrink-width-animation",timing:{delay:100,duration:50,easing:u.ANIMATION_CUBIC_BEZIER}},{name:"paper-menu-shrink-height-animation",timing:{duration:200,easing:"ease-in"}}]}},allowOutsideScroll:{type:Boolean,value:!1},restoreFocusOnClose:{type:Boolean,value:!0},expandSizingTargetForScrollbars:{type:Boolean,value:!1},_dropdownContent:{type:Object}},hostAttributes:{role:"group","aria-haspopup":"true"},listeners:{"iron-activate":"_onIronActivate","iron-select":"_onIronSelect"},get contentElement(){for(var e=(0,s.tT)(this.$.content).getDistributedNodes(),t=0,n=e.length;t<n;t++)if(e[t].nodeType===Node.ELEMENT_NODE)return e[t]},toggle:function(){this.opened?this.close():this.open()},open:function(){this.disabled||this.$.dropdown.open()},close:function(){this.$.dropdown.close()},_onIronSelect:function(e){this.ignoreSelect||this.close()},_onIronActivate:function(e){this.closeOnActivate&&this.close()},_openedChanged:function(e,t){e?(this._dropdownContent=this.contentElement,this.fire("paper-dropdown-open")):null!=t&&this.fire("paper-dropdown-close")},_disabledChanged:function(e){c.x._disabledChanged.apply(this,arguments),e&&this.opened&&this.close()},__onIronOverlayCanceled:function(e){var t=e.detail,n=this.$.trigger;(0,s.tT)(t).path.indexOf(n)>-1&&e.preventDefault()}});Object.keys(u).forEach(function(e){m[e]=u[e]});n(82491);(0,r.b)({is:"iron-iconset-svg",properties:{name:{type:String,observer:"_nameChanged"},size:{type:Number,value:24},rtlMirroring:{type:Boolean,value:!1},useGlobalRtlAttribute:{type:Boolean,value:!1}},created:function(){this._meta=new a.s({type:"iconset",key:null,value:null})},attached:function(){this.style.display="none"},getIconNames:function(){return this._icons=this._createIconMap(),Object.keys(this._icons).map(function(e){return this.name+":"+e},this)},applyIcon:function(e,t){this.removeIcon(e);var n=this._cloneIcon(t,this.rtlMirroring&&this._targetIsRTL(e));if(n){var i=(0,s.tT)(e.root||e);return i.insertBefore(n,i.childNodes[0]),e._svgIcon=n}return null},removeIcon:function(e){e._svgIcon&&((0,s.tT)(e.root||e).removeChild(e._svgIcon),e._svgIcon=null)},_targetIsRTL:function(e){if(null==this.__targetIsRTL)if(this.useGlobalRtlAttribute){var t=document.body&&document.body.hasAttribute("dir")?document.body:document.documentElement;this.__targetIsRTL="rtl"===t.getAttribute("dir")}else e&&e.nodeType!==Node.ELEMENT_NODE&&(e=e.host),this.__targetIsRTL=e&&"rtl"===window.getComputedStyle(e).direction;return this.__targetIsRTL},_nameChanged:function(){this._meta.value=null,this._meta.key=this.name,this._meta.value=this,this.async(function(){this.fire("iron-iconset-added",this,{node:window})})},_createIconMap:function(){var e=Object.create(null);return(0,s.tT)(this).querySelectorAll("[id]").forEach(function(t){e[t.id]=t}),e},_cloneIcon:function(e,t){return this._icons=this._icons||this._createIconMap(),this._prepareSvgClone(this._icons[e],this.size,t)},_prepareSvgClone:function(e,t,n){if(e){var i=e.cloneNode(!0),o=document.createElementNS("http://www.w3.org/2000/svg","svg"),a=i.getAttribute("viewBox")||"0 0 "+t+" "+t,r="pointer-events: none; display: block; width: 100%; height: 100%;";return n&&i.hasAttribute("mirror-in-rtl")&&(r+="-webkit-transform:scale(-1,1);transform:scale(-1,1);transform-origin:center;"),o.setAttribute("viewBox",a),o.setAttribute("preserveAspectRatio","xMidYMid meet"),o.setAttribute("focusable","false"),o.style.cssText=r,o.appendChild(i).removeAttribute("id"),o}return null}});const f=document.createElement("template");f.setAttribute("style","display: none;"),f.innerHTML='<iron-iconset-svg name="paper-dropdown-menu" size="24">\n<svg><defs>\n<g id="arrow-drop-down"><path d="M7 10l5 5 5-5z"></path></g>\n</defs></svg>\n</iron-iconset-svg>',document.head.appendChild(f.content);const g=document.createElement("template");g.setAttribute("style","display: none;"),g.innerHTML='<dom-module id="paper-dropdown-menu-shared-styles">\n <template>\n <style>\n :host {\n display: inline-block;\n position: relative;\n text-align: left;\n\n /* NOTE(cdata): Both values are needed, since some phones require the\n * value to be `transparent`.\n */\n -webkit-tap-highlight-color: rgba(0,0,0,0);\n -webkit-tap-highlight-color: transparent;\n\n --paper-input-container-input: {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n max-width: 100%;\n box-sizing: border-box;\n cursor: pointer;\n };\n\n @apply --paper-dropdown-menu;\n }\n\n /* paper-dropdown-menu and paper-dropdown-menu-light both delegate focus\n * to other internal elements which manage focus styling. */\n :host(:focus) {\n outline: none;\n }\n\n :host(:dir(rtl)) {\n text-align: right;\n\n @apply(--paper-dropdown-menu);\n }\n\n :host([disabled]) {\n @apply --paper-dropdown-menu-disabled;\n }\n\n :host([noink]) paper-ripple {\n display: none;\n }\n\n :host([no-label-float]) paper-ripple {\n top: 8px;\n }\n\n paper-ripple {\n top: 12px;\n left: 0px;\n bottom: 8px;\n right: 0px;\n\n @apply --paper-dropdown-menu-ripple;\n }\n\n paper-menu-button {\n display: block;\n padding: 0;\n\n @apply --paper-dropdown-menu-button;\n }\n\n paper-input {\n @apply --paper-dropdown-menu-input;\n }\n\n iron-icon {\n color: var(--disabled-text-color);\n\n @apply --paper-dropdown-menu-icon;\n }\n </style>\n </template>\n</dom-module>',document.head.appendChild(g.content);var v=n(71920),y=n(19911),_=n(18811),b=n(94794),w=n(15055),A=n(13107);const C=(0,b.r)(HTMLElement);(0,r.b)({_template:l.q`
100
+ `,is:"paper-menu-button",behaviors:[o.D,p.x],properties:{opened:{type:Boolean,value:!1,notify:!0,observer:"_openedChanged"},horizontalAlign:{type:String,value:"left",reflectToAttribute:!0},verticalAlign:{type:String,value:"top",reflectToAttribute:!0},dynamicAlign:{type:Boolean},horizontalOffset:{type:Number,value:0,notify:!0},verticalOffset:{type:Number,value:0,notify:!0},noOverlap:{type:Boolean},noAnimations:{type:Boolean,value:!1},ignoreSelect:{type:Boolean,value:!1},closeOnActivate:{type:Boolean,value:!1},openAnimationConfig:{type:Object,value:function(){return[{name:"fade-in-animation",timing:{delay:100,duration:200}},{name:"paper-menu-grow-width-animation",timing:{delay:100,duration:150,easing:u.ANIMATION_CUBIC_BEZIER}},{name:"paper-menu-grow-height-animation",timing:{delay:100,duration:275,easing:u.ANIMATION_CUBIC_BEZIER}}]}},closeAnimationConfig:{type:Object,value:function(){return[{name:"fade-out-animation",timing:{duration:150}},{name:"paper-menu-shrink-width-animation",timing:{delay:100,duration:50,easing:u.ANIMATION_CUBIC_BEZIER}},{name:"paper-menu-shrink-height-animation",timing:{duration:200,easing:"ease-in"}}]}},allowOutsideScroll:{type:Boolean,value:!1},restoreFocusOnClose:{type:Boolean,value:!0},expandSizingTargetForScrollbars:{type:Boolean,value:!1},_dropdownContent:{type:Object}},hostAttributes:{role:"group","aria-haspopup":"true"},listeners:{"iron-activate":"_onIronActivate","iron-select":"_onIronSelect"},get contentElement(){for(var e=(0,s.tT)(this.$.content).getDistributedNodes(),t=0,n=e.length;t<n;t++)if(e[t].nodeType===Node.ELEMENT_NODE)return e[t]},toggle:function(){this.opened?this.close():this.open()},open:function(){this.disabled||this.$.dropdown.open()},close:function(){this.$.dropdown.close()},_onIronSelect:function(e){this.ignoreSelect||this.close()},_onIronActivate:function(e){this.closeOnActivate&&this.close()},_openedChanged:function(e,t){e?(this._dropdownContent=this.contentElement,this.fire("paper-dropdown-open")):null!=t&&this.fire("paper-dropdown-close")},_disabledChanged:function(e){p.x._disabledChanged.apply(this,arguments),e&&this.opened&&this.close()},__onIronOverlayCanceled:function(e){var t=e.detail,n=this.$.trigger;(0,s.tT)(t).path.indexOf(n)>-1&&e.preventDefault()}});Object.keys(u).forEach(function(e){m[e]=u[e]});n(82491);(0,r.b)({is:"iron-iconset-svg",properties:{name:{type:String,observer:"_nameChanged"},size:{type:Number,value:24},rtlMirroring:{type:Boolean,value:!1},useGlobalRtlAttribute:{type:Boolean,value:!1}},created:function(){this._meta=new a.s({type:"iconset",key:null,value:null})},attached:function(){this.style.display="none"},getIconNames:function(){return this._icons=this._createIconMap(),Object.keys(this._icons).map(function(e){return this.name+":"+e},this)},applyIcon:function(e,t){this.removeIcon(e);var n=this._cloneIcon(t,this.rtlMirroring&&this._targetIsRTL(e));if(n){var i=(0,s.tT)(e.root||e);return i.insertBefore(n,i.childNodes[0]),e._svgIcon=n}return null},removeIcon:function(e){e._svgIcon&&((0,s.tT)(e.root||e).removeChild(e._svgIcon),e._svgIcon=null)},_targetIsRTL:function(e){if(null==this.__targetIsRTL)if(this.useGlobalRtlAttribute){var t=document.body&&document.body.hasAttribute("dir")?document.body:document.documentElement;this.__targetIsRTL="rtl"===t.getAttribute("dir")}else e&&e.nodeType!==Node.ELEMENT_NODE&&(e=e.host),this.__targetIsRTL=e&&"rtl"===window.getComputedStyle(e).direction;return this.__targetIsRTL},_nameChanged:function(){this._meta.value=null,this._meta.key=this.name,this._meta.value=this,this.async(function(){this.fire("iron-iconset-added",this,{node:window})})},_createIconMap:function(){var e=Object.create(null);return(0,s.tT)(this).querySelectorAll("[id]").forEach(function(t){e[t.id]=t}),e},_cloneIcon:function(e,t){return this._icons=this._icons||this._createIconMap(),this._prepareSvgClone(this._icons[e],this.size,t)},_prepareSvgClone:function(e,t,n){if(e){var i=e.cloneNode(!0),o=document.createElementNS("http://www.w3.org/2000/svg","svg"),a=i.getAttribute("viewBox")||"0 0 "+t+" "+t,r="pointer-events: none; display: block; width: 100%; height: 100%;";return n&&i.hasAttribute("mirror-in-rtl")&&(r+="-webkit-transform:scale(-1,1);transform:scale(-1,1);transform-origin:center;"),o.setAttribute("viewBox",a),o.setAttribute("preserveAspectRatio","xMidYMid meet"),o.setAttribute("focusable","false"),o.style.cssText=r,o.appendChild(i).removeAttribute("id"),o}return null}});const g=document.createElement("template");g.setAttribute("style","display: none;"),g.innerHTML='<iron-iconset-svg name="paper-dropdown-menu" size="24">\n<svg><defs>\n<g id="arrow-drop-down"><path d="M7 10l5 5 5-5z"></path></g>\n</defs></svg>\n</iron-iconset-svg>',document.head.appendChild(g.content);const f=document.createElement("template");f.setAttribute("style","display: none;"),f.innerHTML='<dom-module id="paper-dropdown-menu-shared-styles">\n <template>\n <style>\n :host {\n display: inline-block;\n position: relative;\n text-align: left;\n\n /* NOTE(cdata): Both values are needed, since some phones require the\n * value to be `transparent`.\n */\n -webkit-tap-highlight-color: rgba(0,0,0,0);\n -webkit-tap-highlight-color: transparent;\n\n --paper-input-container-input: {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n max-width: 100%;\n box-sizing: border-box;\n cursor: pointer;\n };\n\n @apply --paper-dropdown-menu;\n }\n\n /* paper-dropdown-menu and paper-dropdown-menu-light both delegate focus\n * to other internal elements which manage focus styling. */\n :host(:focus) {\n outline: none;\n }\n\n :host(:dir(rtl)) {\n text-align: right;\n\n @apply(--paper-dropdown-menu);\n }\n\n :host([disabled]) {\n @apply --paper-dropdown-menu-disabled;\n }\n\n :host([noink]) paper-ripple {\n display: none;\n }\n\n :host([no-label-float]) paper-ripple {\n top: 8px;\n }\n\n paper-ripple {\n top: 12px;\n left: 0px;\n bottom: 8px;\n right: 0px;\n\n @apply --paper-dropdown-menu-ripple;\n }\n\n paper-menu-button {\n display: block;\n padding: 0;\n\n @apply --paper-dropdown-menu-button;\n }\n\n paper-input {\n @apply --paper-dropdown-menu-input;\n }\n\n iron-icon {\n color: var(--disabled-text-color);\n\n @apply --paper-dropdown-menu-icon;\n }\n </style>\n </template>\n</dom-module>',document.head.appendChild(f.content);var y=n(71920),v=n(19911),_=n(18811),b=n(94794),w=n(15055),A=n(13107);const C=(0,b.r)(HTMLElement);(0,r.b)({_template:l.q`
101
101
  <style include="paper-dropdown-menu-shared-styles"></style>
102
102
 
103
103
  <paper-menu-button id="menuButton" vertical-align="[[verticalAlign]]" horizontal-align="[[horizontalAlign]]" dynamic-align="[[dynamicAlign]]" vertical-offset="[[_computeMenuVerticalOffset(noLabelFloat, verticalOffset)]]" disabled="[[disabled]]" no-animations="[[noAnimations]]" on-iron-select="_onIronSelect" on-iron-deselect="_onIronDeselect" opened="{{opened}}" close-on-activate allow-outside-scroll="[[allowOutsideScroll]]" restore-focus-on-close="[[restoreFocusOnClose]]" expand-sizing-target-for-scrollbars="[[expandSizingTargetForScrollbars]]">
@@ -112,4 +112,4 @@
112
112
  </div>
113
113
  <slot id="content" name="dropdown-content" slot="dropdown-content"></slot>
114
114
  </paper-menu-button>
115
- `,is:"paper-dropdown-menu",behaviors:[v.a,c.x,y.x,_.Q],properties:{selectedItemLabel:{type:String,notify:!0,readOnly:!0},selectedItem:{type:Object,notify:!0,readOnly:!0},value:{type:String,notify:!0},label:{type:String},placeholder:{type:String},errorMessage:{type:String},opened:{type:Boolean,notify:!0,value:!1,observer:"_openedChanged"},allowOutsideScroll:{type:Boolean,value:!1},noLabelFloat:{type:Boolean,value:!1,reflectToAttribute:!0},alwaysFloatLabel:{type:Boolean,value:!1},noAnimations:{type:Boolean,value:!1},horizontalAlign:{type:String,value:"right"},verticalAlign:{type:String,value:"top"},verticalOffset:Number,dynamicAlign:{type:Boolean},restoreFocusOnClose:{type:Boolean,value:!0},expandSizingTargetForScrollbars:{type:Boolean,value:!1}},listeners:{tap:"_onTap"},keyBindings:{"up down":"open",esc:"close"},observers:["_selectedItemChanged(selectedItem)"],_attachDom(e){const t=(0,A.L)(this);return t.attachShadow({mode:"open",delegatesFocus:!0,shadyUpgradeFragment:e}),t.shadowRoot.appendChild(e),C.prototype._attachDom.call(this,e)},focus(){this.$.input._focusableElement.focus()},attached:function(){var e=this.contentElement;e&&e.selectedItem&&this._setSelectedItem(e.selectedItem)},get contentElement(){for(var e=(0,s.tT)(this.$.content).getDistributedNodes(),t=0,n=e.length;t<n;t++)if(e[t].nodeType===Node.ELEMENT_NODE)return e[t]},open:function(){this.$.menuButton.open()},close:function(){this.$.menuButton.close()},_onIronSelect:function(e){this._setSelectedItem(e.detail.item)},_onIronDeselect:function(e){this._setSelectedItem(null)},_onTap:function(e){w.Ix(e)===this&&this.open()},_selectedItemChanged:function(e){var t="";t=e?e.label||e.getAttribute("label")||e.textContent.trim():"",this.value=t,this._setSelectedItemLabel(t)},_computeMenuVerticalOffset:function(e,t){return t||(e?-4:8)},_getValidity:function(e){return this.disabled||!this.required||this.required&&!!this.value},_openedChanged:function(){var e=this.opened?"true":"false",t=this.contentElement;t&&t.setAttribute("aria-expanded",e)}})}}]);
115
+ `,is:"paper-dropdown-menu",behaviors:[y.a,p.x,v.x,_.Q],properties:{selectedItemLabel:{type:String,notify:!0,readOnly:!0},selectedItem:{type:Object,notify:!0,readOnly:!0},value:{type:String,notify:!0},label:{type:String},placeholder:{type:String},errorMessage:{type:String},opened:{type:Boolean,notify:!0,value:!1,observer:"_openedChanged"},allowOutsideScroll:{type:Boolean,value:!1},noLabelFloat:{type:Boolean,value:!1,reflectToAttribute:!0},alwaysFloatLabel:{type:Boolean,value:!1},noAnimations:{type:Boolean,value:!1},horizontalAlign:{type:String,value:"right"},verticalAlign:{type:String,value:"top"},verticalOffset:Number,dynamicAlign:{type:Boolean},restoreFocusOnClose:{type:Boolean,value:!0},expandSizingTargetForScrollbars:{type:Boolean,value:!1}},listeners:{tap:"_onTap"},keyBindings:{"up down":"open",esc:"close"},observers:["_selectedItemChanged(selectedItem)"],_attachDom(e){const t=(0,A.L)(this);return t.attachShadow({mode:"open",delegatesFocus:!0,shadyUpgradeFragment:e}),t.shadowRoot.appendChild(e),C.prototype._attachDom.call(this,e)},focus(){this.$.input._focusableElement.focus()},attached:function(){var e=this.contentElement;e&&e.selectedItem&&this._setSelectedItem(e.selectedItem)},get contentElement(){for(var e=(0,s.tT)(this.$.content).getDistributedNodes(),t=0,n=e.length;t<n;t++)if(e[t].nodeType===Node.ELEMENT_NODE)return e[t]},open:function(){this.$.menuButton.open()},close:function(){this.$.menuButton.close()},_onIronSelect:function(e){this._setSelectedItem(e.detail.item)},_onIronDeselect:function(e){this._setSelectedItem(null)},_onTap:function(e){w.Ix(e)===this&&this.open()},_selectedItemChanged:function(e){var t="";t=e?e.label||e.getAttribute("label")||e.textContent.trim():"",this.value=t,this._setSelectedItemLabel(t)},_computeMenuVerticalOffset:function(e,t){return t||(e?-4:8)},_getValidity:function(e){return this.disabled||!this.required||this.required&&!!this.value},_openedChanged:function(){var e=this.opened?"true":"false",t=this.contentElement;t&&t.setAttribute("aria-expanded",e)}})}}]);
Binary file
@@ -25,21 +25,25 @@
25
25
  cdtr-editor-tab-item:focus {
26
26
  outline: none;
27
27
  }
28
+ cdtr-editor-tab-item:focus-visible {
29
+ outline: none;
30
+ box-shadow: var(--focus-ring-inset, inset 0 0 0 2px #6366f1);
31
+ }
28
32
  cdtr-editor-tab-item {
29
33
  width: 100%;
30
34
  }
31
35
  .icon-tabs {
32
- padding: 10px 0;
33
- background: #fafafa;
36
+ padding: var(--space-3, 12px) 0;
37
+ background: var(--color-bg-subtle, #fafafa);
34
38
  width: 52px;
35
39
  height: 100%;
36
40
  min-height: 400px;
37
- border-left: 1px solid #eaeaee;
41
+ border-left: 1px solid var(--color-border, #eaeaee);
38
42
  direction: ltr;
39
43
  display: flex;
40
44
  flex-direction: column;
41
45
  align-items: center;
42
- gap: 2px;
46
+ gap: var(--space-1, 4px);
43
47
  }
44
48
 
45
49
  .main {
@@ -49,8 +53,8 @@
49
53
  .content {
50
54
  overflow-y: auto;
51
55
  overflow-x: hidden;
52
- max-height: calc(100vh - 170px);
56
+ max-height: calc(100vh - 130px);
53
57
  min-height: 80%;
54
- padding-top: 12px;
58
+ padding-top: var(--space-3, 12px);
55
59
  }
56
60
  `,s.properties={tabs:{type:Array},value:{type:String}},customElements.define("cdtr-editor-tabs",s)}}]);
Binary file
@@ -1,4 +1,4 @@
1
- "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[752],{40752(t,i,e){e.r(i),e.d(i,{EditorContainer:()=>a});var n=e(59929);class a extends n.WF{constructor(){super(),this.pt="10px",this.isAnimate=!0}render(){return n.qy`<div
1
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[752],{40752(e,t,i){i.r(t),i.d(t,{EditorContainer:()=>a});var n=i(59929);class a extends n.WF{constructor(){super(),this.pt="10px",this.isAnimate=!0}render(){return n.qy`<div
2
2
  style="padding-top:${this.pt}"
3
3
  class="container ${this.isAnimate?"animate":""}"
4
4
  >
@@ -12,15 +12,15 @@
12
12
  direction: var(--direction-locale);
13
13
  }
14
14
  .container {
15
- padding-inline: var(--editor-container-inline-padding, 16px);
15
+ padding-inline: var(--editor-container-inline-padding, var(--space-4, 16px));
16
16
  display: block;
17
17
  width: 100%;
18
18
  min-height: 20px;
19
- padding-bottom: 8px;
19
+ padding-bottom: var(--space-2, 8px);
20
20
  box-sizing: border-box;
21
21
  }
22
22
  .animate {
23
- animation: slide-in 0.2s ease-in-out;
23
+ animation: slide-in var(--duration-normal, 200ms) var(--ease-default, ease-in-out);
24
24
  }
25
25
  @keyframes slide-in {
26
26
  from {
Binary file
@@ -1 +1,34 @@
1
- "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[763],{10763(e,t,n){n.d(t,{default:()=>w});var o=n(96374),i=n(86319);const a=e=>{{const{component:t,commands:n,helpers:a}=e;return{select:e=>{let{changeTab:t,tab:n}=e},tabs:e=>{const t=[{text:"design",selected:!0},{text:"link"},{text:"icons"},..."web"===i.M.get("config","channel")?[{text:"animations"}]:[],{text:"settings"}];return t.forEach(t=>t.selected=t.selected=t.text===e),t},layout:e=>{let{tab:a,changeTab:r,tabs:s}=e;return[{type:"heading",level:6,text:"settings",active:()=>"design"===a.text},{type:"input",title:"whatTheBtnSays",mergeTags:!0,emoji:!0,active:()=>"design"===a.text,value:t.props.text||"",onInput:e=>{const t=e.target.value;n.execCommand("text",t)}},{type:"heading",level:6,text:"typography",active:()=>"design"===a.text},{type:"typography",active:()=>"design"===a.text,bold:700===t.props.style.fontWeight,italic:"italic"===t.props.style.fontStyle,underline:"underline"===t.props.style.textDecoration,onChange:e=>{switch(e){case"bold":const e=700===t.props.style.fontWeight?400:700;n.execCommand("style",{fontWeight:e});break;case"italic":const o="italic"===t.props.style.fontStyle?"normal":"italic";n.execCommand("style",{fontStyle:o});break;case"underline":const i="underline"===t.props.style.textDecoration?"none":"underline";n.execCommand("style",{textDecoration:i})}}},{type:"fontFamily",active:()=>"design"===a.text,value:t.props.style.fontFamily,weight:"web"===i.M.get("config","channel"),weightValue:t.props.style.fontWeight,onChange:e=>{const t=e.target.value;n.execCommand("style",{fontFamily:t})},onWeightChange:e=>{n.execCommand("style",{fontWeight:e.detail.value})}},{type:"slider",title:"fontSize",step:1,min:8,max:50,active:()=>"design"===a.text,value:parseInt(t.props.style.fontSize)||14,onInput:e=>{const t=e.target.value;n.execCommand("style",{fontSize:t+"px",height:"auto"})}},{type:"heading",level:6,text:"dimensions",active:()=>"design"===a.text},{type:"slider",title:"width",min:10,max:500,active:()=>"design"===a.text,value:parseInt(t.props.style.width),onInput:e=>{const t=e.target.value;n.execCommand("style",{width:t+"px",minWidth:null})}},{type:"heading",level:6,text:"colors",active:()=>"design"===a.text},{type:"colorSwatchGroup",active:()=>"design"===a.text,columns:2,items:[{title:"button_background",allowGradient:!0,value:t.props.style.background||"#000000",onChange:e=>{const i=e.target.value;if(!i.includes("gradient(")){const e=(0,o.w)(t.props.style.color,i);n.execCommand("style",{color:e})}n.execCommand("style",{background:i,backgroundColor:null})}},{title:"font_color",value:t.props.style.color||"#ffffff",onChange:e=>{const t=e.target.value;n.execCommand("style",{color:t})}}]},{type:"heading",level:6,text:"border_design",active:()=>"design"===a.text},{type:"slider",title:"radius",min:0,max:100,active:()=>"design"===a.text,value:parseInt(t.props.style.borderRadius),onInput:e=>{const t=e.target.value;n.execCommand("style",{borderRadius:t+"px"})}},{type:"borderpicker",title:"border",active:()=>"design"===a.text,value:t.props.style.border,onChange:e=>{const t=e.target.value;n.execCommand("style",{border:t})}},{type:"slider",title:"borderWidth",active:()=>"design"===a.text,value:t.props.style.borderWidth,onInput:e=>{const t=e.target.value;n.execCommand("style",{borderWidth:t+"px"})}},{type:"colorpicker",title:"borderColor",active:()=>"design"===a.text,value:t.props.style.borderColor,onChange:e=>{const t=e.target.value;n.execCommand("style",{borderColor:t})}},{type:"linkpicker",href:t.props.onClick?.link,protocol:t.props.onClick?.link?.protocol,target:t.props.onClick?.link?.target,autofocus:!0,active:()=>"link"===a.text,onChange:e=>{const t={link:e.target.value};n.execCommand("onClick",t)}},{type:"checkbox",title:"hasIcon",useIconsApi:!0,checked:!!t.props.hasIcon,active:()=>"icons"===a.text,onChange:e=>{const t=e.target.checked;n.execCommand("hasIcon",t),n.execCommand("iconDirection","left")}},{type:"dropdown",active:()=>"icons"===a.text&&!0===t.props.hasIcon,title:"iconDirection",value:t.props.iconDirection,onChange:e=>{const t=e.target.value;n.execCommand("iconDirection",t)},items:[{value:"left",label:"left"},{value:"right",label:"right"}]},{type:"slider",title:"size",min:10,max:100,active:()=>"icons"===a.text&&!0===t.props.hasIcon,value:t.props.iconSize||16,onInput:e=>{const t=e.target.value;n.execCommand("iconSize",t)}},{type:"icons",active:()=>"icons"===a.text&&!0===t.props.hasIcon,selectedIcon:t.props.iconUrl,onChange:e=>{const t=e.detail;n.execCommand("iconUrl",t.src)}},{type:"heading",level:6,text:"spacing",active:()=>"design"===a.text},{type:"spacingPicker",active:()=>"design"===a.text,hasLeft:!1,hasRight:!1,value:{top:parseInt(t.props.style.paddingTop)||0,bottom:parseInt(t.props.style.paddingBottom)||0,left:parseInt(t.props.style.paddingLeft)||0,right:parseInt(t.props.style.paddingRight)||0},onChange:e=>{e.target.value;const t=e.target.topValue,o=e.target.bottomValue,i=e.target.leftValue,a=e.target.rightValue;n.execCommand("style",{paddingTop:t+"px",paddingBottom:o+"px",paddingLeft:i+"px",paddingRight:a+"px",padding:null})}}]}}}},r=e=>{let{helpers:t,editor:n,getFocused:o}=e;return{set:(e,i,a)=>{switch(i){case"style":return e[i]=t.deepMerge(e[i],a),!0;case"text":return e.text=a,o()||n.chain().setContent(a).run(),!0;case"ripple":case"rippleColor":case"scaleOnHover":case"hasIcon":case"iconUrl":case"iconSize":case"iconDirection":return e[i]=a,!0;case"onClick":if(a.link)return e[i]=a,!0}}}};var s=n(72591),l=n.n(s),c=n(88639),d=n.n(c),p=n(88128),u=n.n(p),g=n(30855),m=n.n(g),A=n(93051),h=n.n(A),y=n(49536),x={};x.setAttributes=m(),x.insert=u().bind(null,"head"),x.domAPI=d(),x.insertStyleElement=h();l()(y.A,x);const C=y.A&&y.A.locals?y.A.locals:void 0;var b=n(81318),f=n(1366);const v=b.bP.create({name:"paragraph",priority:1e3,addOptions:()=>({HTMLAttributes:{}}),group:"block",content:"inline*",parseHTML:()=>[{tag:"p"}],renderHTML({HTMLAttributes:e}){return["p",(0,b.KV)(this.options.HTMLAttributes,e),0]},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}});var E=n(85194),k=n(28396);const B=b.YY.create({addKeyboardShortcuts:()=>({Enter:()=>!0})});const w=()=>{const e="button";return{name:e,create:t=>{const{createElement:n,compose:o,helpers:i}=t,{arrayToString:s,mergeDiff:l}=i;let c=!1;const d=document.createElement("div"),p=document.createElement("div"),{editor:u}=function(e){let{content:t,element:n}=e;return{element:n,editor:new b.KE({element:n,extensions:[f.A,v,k.A,E.Ay,B],content:t})}}({content:o.props.text,element:p});d.appendChild(p);return u.view.dom.setAttribute("dir","auto"),u.on("update",e=>{let{editor:t}=e;const n=t.getText();o.editor.store().updateComponent(o,"text",n)}),u.on("focus",e=>{let{event:t,editor:n}=e;c=!0}),u.on("blur",e=>{let{event:t,editor:n}=e;c=!1}),d.className=C.button,n({name:e,id:o.id,template:d,commands:{insertContent:e=>{u.commands.insertContent(e),u.chain().focus()}},defaultProps:{style:{height:"auto",width:"200px",padding:"10px",borderRadius:"5px",fontFamily:"Arial",fontSize:"16px"},text:"button"},render:()=>{try{o.props.style.display="",o.props.style.direction=""}catch(e){console.error(e)}l(d,{style:o.props.style}),d.style.height="auto";const e=o.props.hasIcon,t=o.props.iconUrl,n=o.props.iconDirection,i=o.props.iconSize,a="icon_in_button";let r=d.querySelector(`.${a}`)||document.createElement("img");e&&t?(r.className=a,r.src=t,r.style.width=(i||16)+"px",r.style.height=(i||16)+"px",r.style.marginRight="8px",r.style.marginLeft="8px","left"===n?d.insertBefore(r,d.firstChild):d.appendChild(r)):r.remove()},draggable:{group:"element"},droppable:{group:"element"},resizeable:()=>d,handleBar:!0,validator:r({template:d,helpers:i,editor:u,getFocused:function(){return c}}),schema:o.schema,onSelect:e=>{d.classList.add(e)},onDeselect:e=>{d.classList.remove(e)},elementProps:o,destroy:()=>{u.destroy()},remove:()=>{d.remove()},createEditor:a})}}}},49536(e,t,n){n.d(t,{A:()=>s});var o=n(82001),i=n.n(o),a=n(40935),r=n.n(a)()(i());r.push([e.id,".BEr8unIfy4OEGYhlHclN {\n cursor: text !important;\n}\n.BEr8unIfy4OEGYhlHclN {\n min-width: 30px;\n display: flex;\n justify-content: center;\n align-items: center;\n text-align: center;\n padding:10px;\n}\n.BEr8unIfy4OEGYhlHclN p {\n margin: 0;\n line-height: 1;\n}\n.cI3RTMAdk9qoZ8mu9Sm9 {\n width: 100%;\n}\n.VSumPf0Ui7b1pl8cMATP {\n position: absolute;\n z-index: 9;\n width: 3px;\n height: 90%;\n background: var(--resizer-color);\n border-radius: 20px;\n}\n.Vo2Ewnq6ekWFdNMjxBIB {\n left: -8px;\n cursor: w-resize;\n}\n.WLZC84sb1rfaRnHCDyj8 {\n left: calc(100% + 5px);\n cursor: e-resize;\n}\n\n.BEr8unIfy4OEGYhlHclN .VSumPf0Ui7b1pl8cMATP {\n display: none;\n}\n.BEr8unIfy4OEGYhlHclN.Qh20ei1Fa8QUbGinFFbw .VSumPf0Ui7b1pl8cMATP {\n display: block;\n}\n/* .handle{\n display: none;\n}\n.button.selected .handle{\n display: block;\n} */\n","",{version:3,sources:["webpack://./../web-editors/button-editor-component/lib/style.module.css"],names:[],mappings:"AAAA;EACE,uBAAuB;AAOzB;AARA;EAEE,eAAe;EACf,aAAa;EACb,uBAAuB;EACvB,mBAAmB;EACnB,kBAAkB;EAClB,YAAY;AACd;AACA;EACE,SAAS;EACT,cAAc;AAChB;AACA;EACE,WAAW;AACb;AACA;EACE,kBAAkB;EAClB,UAAU;EACV,UAAU;EACV,WAAW;EACX,gCAAgC;EAChC,mBAAmB;AACrB;AACA;EACE,UAAU;EACV,gBAAgB;AAClB;AACA;EACE,sBAAsB;EACtB,gBAAgB;AAClB;;AAEA;EACE,aAAa;AACf;AACA;EACE,cAAc;AAChB;AACA;;;;;GAKG",sourcesContent:[".button {\n cursor: text !important;\n min-width: 30px;\n display: flex;\n justify-content: center;\n align-items: center;\n text-align: center;\n padding:10px;\n}\n.button p {\n margin: 0;\n line-height: 1;\n}\n.contentEditable {\n width: 100%;\n}\n.margin {\n position: absolute;\n z-index: 9;\n width: 3px;\n height: 90%;\n background: var(--resizer-color);\n border-radius: 20px;\n}\n.marginLeft {\n left: -8px;\n cursor: w-resize;\n}\n.marginRight {\n left: calc(100% + 5px);\n cursor: e-resize;\n}\n\n.button .margin {\n display: none;\n}\n.button.selected .margin {\n display: block;\n}\n/* .handle{\n display: none;\n}\n.button.selected .handle{\n display: block;\n} */\n"],sourceRoot:""}]),r.locals={button:"BEr8unIfy4OEGYhlHclN",contentEditable:"cI3RTMAdk9qoZ8mu9Sm9",margin:"VSumPf0Ui7b1pl8cMATP",marginLeft:"Vo2Ewnq6ekWFdNMjxBIB",marginRight:"WLZC84sb1rfaRnHCDyj8",selected:"Qh20ei1Fa8QUbGinFFbw"};const s=r}}]);
1
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[763],{10763(e,t,o){o.d(t,{default:()=>W});var n=o(96374),r=o(86319),l=o(59929);const a=e=>{{const{component:t,commands:o,helpers:a}=e;return{select:e=>{let{changeTab:t,tab:o}=e},tabs:e=>{const t=[{text:"design",selected:!0},{text:"styles"},{text:"link"},{text:"icons"},..."web"===r.M.get("config","channel")?[{text:"animations"},{text:"modal"}]:[],{text:"settings"}];return t.forEach(t=>t.selected=t.selected=t.text===e),t},layout:e=>{let{tab:a,changeTab:d,tabs:i}=e;const s=(r.M.get("components")||[]).filter(e=>e&&"block"===e.type&&e.props?.modalable),c=[{value:"",label:"modal_none"},...s.map((e,t)=>({value:e.id,label:e.props?.modalName||`modal ${t+1}`}))],p=t.props.modalBlockId||"",b=c.find(e=>e.value===p)?.label||"modal_none";return[{type:"custom",active:()=>"styles"===a.text,node:()=>{const e="web"===r.M.get("config","channel"),n={cart:"http://app.creaditor.com/assets/bullets/images/cart-icon.png",arrowRight:"http://app.creaditor.com/assets/bullets/images/1469020585_ic_keyboard_arrow_right_48px.png"},a=[{category:"Basic",presets:[{name:"Solid",style:{background:"#111111",color:"#ffffff",borderRadius:"6px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}},{name:"Pill",style:{background:"#2563eb",color:"#ffffff",borderRadius:"999px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}},{name:"Outline",style:{background:"transparent",color:"#111111",borderRadius:"6px",border:"1px solid #111111",borderWidth:"1px",borderColor:"#111111",boxShadow:null}},{name:"Soft",style:{background:"#eef2ff",color:"#3730a3",borderRadius:"10px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}}]},{category:"Gradients",presets:[{name:"Sunset",style:{background:"linear-gradient(135deg,#ff6a00,#ee0979)",color:"#ffffff",borderRadius:"8px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}},{name:"Ocean",style:{background:"linear-gradient(135deg,#2193b0,#6dd5ed)",color:"#ffffff",borderRadius:"8px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}},{name:"Grape",webOnly:!0,style:{background:"linear-gradient(135deg,#7b2ff7,#f107a3)",color:"#ffffff",borderRadius:"8px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}},{name:"Lime",webOnly:!0,style:{background:"linear-gradient(135deg,#11998e,#38ef7d)",color:"#ffffff",borderRadius:"8px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}}]},{category:"3D blocks",presets:[{name:"Orange",webOnly:!0,style:{background:"#ed8936",color:"#ffffff",borderRadius:"10px",padding:"14px 22px",fontWeight:700,border:"none",borderWidth:null,borderColor:null,boxShadow:"0px 5px 0px 0px #b45309"}},{name:"Green",webOnly:!0,style:{background:"#38a169",color:"#ffffff",borderRadius:"10px",padding:"14px 22px",fontWeight:700,border:"none",borderWidth:null,borderColor:null,boxShadow:"0px 5px 0px 0px #276749"}},{name:"Blue",webOnly:!0,style:{background:"#3182ce",color:"#ffffff",borderRadius:"10px",padding:"14px 22px",fontWeight:700,border:"none",borderWidth:null,borderColor:null,boxShadow:"0px 5px 0px 0px #2151a1"}},{name:"Red",webOnly:!0,style:{background:"#e53e3e",color:"#ffffff",borderRadius:"10px",padding:"14px 22px",fontWeight:700,border:"none",borderWidth:null,borderColor:null,boxShadow:"0px 5px 0px 0px #9b2c2c"}},{name:"Purple",webOnly:!0,style:{background:"#805ad5",color:"#ffffff",borderRadius:"10px",padding:"14px 22px",fontWeight:700,border:"none",borderWidth:null,borderColor:null,boxShadow:"0px 5px 0px 0px #553c9a"}},{name:"Dark",webOnly:!0,style:{background:"#2d3748",color:"#ffffff",borderRadius:"10px",padding:"14px 22px",fontWeight:700,border:"none",borderWidth:null,borderColor:null,boxShadow:"0px 5px 0px 0px #1a202c"}}]},{category:"Effects",presets:[{name:"Neon",webOnly:!0,style:{background:"#0a0a0a",color:"#39ff14",borderRadius:"8px",border:"1px solid #39ff14",borderWidth:"1px",borderColor:"#39ff14",boxShadow:"0 0 10px #39ff14, 0 0 22px rgba(57,255,20,0.5)"}},{name:"Glow",webOnly:!0,style:{background:"#7b2ff7",color:"#ffffff",borderRadius:"10px",border:"none",borderWidth:null,borderColor:null,boxShadow:"0 8px 24px rgba(123,47,247,0.55)"}},{name:"Glass",webOnly:!0,style:{background:"rgba(255,255,255,0.18)",color:"#111111",borderRadius:"12px",border:"1px solid rgba(255,255,255,0.6)",borderWidth:"1px",borderColor:"rgba(255,255,255,0.6)",backdropFilter:"blur(8px)",boxShadow:"0 4px 30px rgba(0,0,0,0.1)"}},{name:"Shadow",webOnly:!0,style:{background:"#ffffff",color:"#111111",borderRadius:"12px",border:"none",borderWidth:null,borderColor:null,boxShadow:"0 10px 24px rgba(0,0,0,0.18)"}},{name:"Emboss",webOnly:!0,style:{background:"#e2e8f0",color:"#2d3748",borderRadius:"10px",border:"none",borderWidth:null,borderColor:null,boxShadow:"inset 0 2px 4px rgba(255,255,255,0.9), inset 0 -2px 4px rgba(0,0,0,0.15), 0 2px 4px rgba(0,0,0,0.1)"}}]},{category:"Premium gradients",presets:[{name:"Aurora",webOnly:!0,style:{background:"linear-gradient(135deg,#667eea,#764ba2)",color:"#ffffff",borderRadius:"10px",border:"none",borderWidth:null,borderColor:null,boxShadow:"0 8px 20px rgba(118,75,162,0.4)"}},{name:"Peach",webOnly:!0,style:{background:"linear-gradient(135deg,#ff9a9e,#fecfef)",color:"#7a2e3a",borderRadius:"10px",border:"none",borderWidth:null,borderColor:null,boxShadow:"0 8px 20px rgba(255,154,158,0.45)"}},{name:"Gold",webOnly:!0,style:{background:"linear-gradient(135deg,#f6d365,#fda085)",color:"#5a3a1a",borderRadius:"10px",border:"none",borderWidth:null,borderColor:null,boxShadow:"0 8px 20px rgba(253,160,133,0.45)"}},{name:"Midnight",webOnly:!0,style:{background:"linear-gradient(135deg,#0f2027,#203a43,#2c5364)",color:"#ffffff",borderRadius:"10px",border:"none",borderWidth:null,borderColor:null,boxShadow:"0 8px 20px rgba(15,32,39,0.5)"}},{name:"Candy",webOnly:!0,style:{background:"linear-gradient(135deg,#f093fb,#f5576c)",color:"#ffffff",borderRadius:"10px",border:"none",borderWidth:null,borderColor:null,boxShadow:"0 8px 20px rgba(245,87,108,0.45)"}}]},{category:"With icon",presets:[{name:"Buy now",icon:{src:n.cart,direction:"left",size:18},style:{background:"#16a34a",color:"#ffffff",borderRadius:"8px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}},{name:"Continue",icon:{src:n.arrowRight,direction:"right",size:18},style:{background:"linear-gradient(135deg,#2563eb,#1e3a8a)",color:"#ffffff",borderRadius:"8px",border:"none",borderWidth:null,borderColor:null,boxShadow:null}}]}].map(t=>({...t,presets:t.presets.filter(t=>e||!t.webOnly)})).filter(e=>e.presets.length>0),d=t.props.text||"Button",i=e=>e.icon?l.qy`<img
2
+ src="${e.icon.src}"
3
+ style="width:16px;height:16px;object-fit:contain;vertical-align:middle;${"right"===e.icon.direction?"margin-left:6px;order:2;":"margin-right:6px;"}"
4
+ />`:"",s=e=>l.qy`
5
+ <button
6
+ type="button"
7
+ title="${e.name}"
8
+ @click=${()=>(e=>{o.execCommand("style",{...e.style}),e.icon&&(o.execCommand("hasIcon",!0),o.execCommand("iconUrl",e.icon.src),o.execCommand("iconDirection",e.icon.direction||"left"),o.execCommand("iconSize",e.icon.size||18))})(e)}
9
+ style="display:flex;align-items:center;justify-content:center;width:100%;cursor:pointer;padding:12px 14px;font-size:13px;overflow:hidden;white-space:nowrap;
10
+ background:${e.style.background};
11
+ color:${e.style.color};
12
+ border-radius:${e.style.borderRadius};
13
+ border:${e.style.border};
14
+ font-weight:${e.style.fontWeight||400};
15
+ box-shadow:${e.style.boxShadow||"none"};"
16
+ >
17
+ ${e.icon&&"right"!==e.icon.direction?i(e):""}
18
+ <span style="overflow:hidden;text-overflow:ellipsis;">${d}</span>
19
+ ${e.icon&&"right"===e.icon.direction?i(e):""}
20
+ </button>
21
+ `;return l.qy`
22
+ <cdtr-editor-container pt="0">
23
+ <div style="display:flex;flex-direction:column;gap:10px;padding:8px 16px;">
24
+ ${a.map(e=>l.qy`
25
+ <div
26
+ style="margin-top:6px;font-size:11px;font-weight:600;letter-spacing:0.04em;text-transform:uppercase;color:#888;"
27
+ >
28
+ ${e.category}
29
+ </div>
30
+ ${e.presets.map(e=>s(e))}
31
+ `)}
32
+ </div>
33
+ </cdtr-editor-container>
34
+ `}},{type:"heading",level:6,text:"open_modal",active:()=>"modal"===a.text},{type:"info",text:s.length?"modal_pick_hint":"modal_none_hint",active:()=>"modal"===a.text},{type:"dropdown",title:"modal_block",active:()=>"modal"===a.text,value:b,selected:p,items:c,onChange:e=>{o.execCommand("modalBlockId",e.target.value)}},{type:"heading",level:6,text:"settings",active:()=>"design"===a.text},{type:"input",title:"whatTheBtnSays",mergeTags:!0,emoji:!0,active:()=>"design"===a.text,value:t.props.text||"",onInput:e=>{const t=e.target.value;o.execCommand("text",t)}},{type:"heading",level:6,text:"typography",active:()=>"design"===a.text},{type:"typography",active:()=>"design"===a.text,bold:700===t.props.style.fontWeight,italic:"italic"===t.props.style.fontStyle,underline:"underline"===t.props.style.textDecoration,onChange:e=>{switch(e){case"bold":const e=700===t.props.style.fontWeight?400:700;o.execCommand("style",{fontWeight:e});break;case"italic":const n="italic"===t.props.style.fontStyle?"normal":"italic";o.execCommand("style",{fontStyle:n});break;case"underline":const r="underline"===t.props.style.textDecoration?"none":"underline";o.execCommand("style",{textDecoration:r})}}},{type:"fontFamily",active:()=>"design"===a.text,value:t.props.style.fontFamily,weight:"web"===r.M.get("config","channel"),weightValue:t.props.style.fontWeight,onChange:e=>{const t=e.target.value;o.execCommand("style",{fontFamily:t})},onWeightChange:e=>{o.execCommand("style",{fontWeight:e.detail.value})}},{type:"slider",title:"fontSize",step:1,min:8,max:50,active:()=>"design"===a.text,value:parseInt(t.props.style.fontSize)||14,onInput:e=>{const t=e.target.value;o.execCommand("style",{fontSize:t+"px",height:"auto"})}},{type:"heading",level:6,text:"dimensions",active:()=>"design"===a.text},{type:"slider",title:"width",min:10,max:500,active:()=>"design"===a.text,value:parseInt(t.props.style.width),onInput:e=>{const t=e.target.value;o.execCommand("style",{width:t+"px",minWidth:null})}},{type:"heading",level:6,text:"colors",active:()=>"design"===a.text},{type:"colorSwatchGroup",active:()=>"design"===a.text,columns:2,items:[{title:"button_background",allowGradient:!0,value:t.props.style.background||"#000000",onChange:e=>{const r=e.target.value;if(!r.includes("gradient(")){const e=(0,n.w)(t.props.style.color,r);o.execCommand("style",{color:e})}o.execCommand("style",{background:r,backgroundColor:null})}},{title:"font_color",value:t.props.style.color||"#ffffff",onChange:e=>{const t=e.target.value;o.execCommand("style",{color:t})}}]},{type:"heading",level:6,text:"border_design",active:()=>"design"===a.text},{type:"slider",title:"radius",min:0,max:100,active:()=>"design"===a.text,value:parseInt(t.props.style.borderRadius),onInput:e=>{const t=e.target.value;o.execCommand("style",{borderRadius:t+"px"})}},{type:"borderpicker",title:"border",active:()=>"design"===a.text,value:t.props.style.border,onChange:e=>{const t=e.target.value;o.execCommand("style",{border:t})}},{type:"slider",title:"borderWidth",active:()=>"design"===a.text,value:t.props.style.borderWidth,onInput:e=>{const t=e.target.value;o.execCommand("style",{borderWidth:t+"px"})}},{type:"colorpicker",title:"borderColor",active:()=>"design"===a.text,value:t.props.style.borderColor,onChange:e=>{const t=e.target.value;o.execCommand("style",{borderColor:t})}},{type:"heading",level:6,text:"shadow",active:()=>"design"===a.text},{type:"boxShadow",active:()=>"design"===a.text,value:t.props.style.boxShadow,onChange:e=>{o.execCommand("style",{boxShadow:e})}},{type:"linkpicker",href:t.props.onClick?.link,protocol:t.props.onClick?.link?.protocol,target:t.props.onClick?.link?.target,autofocus:!0,active:()=>"link"===a.text,onChange:e=>{const t={link:e.target.value};o.execCommand("onClick",t)}},{type:"checkbox",title:"hasIcon",useIconsApi:!0,checked:!!t.props.hasIcon,active:()=>"icons"===a.text,onChange:e=>{const t=e.target.checked;o.execCommand("hasIcon",t),o.execCommand("iconDirection","left")}},{type:"dropdown",active:()=>"icons"===a.text&&!0===t.props.hasIcon,title:"iconDirection",value:t.props.iconDirection,onChange:e=>{const t=e.target.value;o.execCommand("iconDirection",t)},items:[{value:"left",label:"left"},{value:"right",label:"right"}]},{type:"slider",title:"size",min:10,max:100,active:()=>"icons"===a.text&&!0===t.props.hasIcon,value:t.props.iconSize||16,onInput:e=>{const t=e.target.value;o.execCommand("iconSize",t)}},{type:"icons",active:()=>"icons"===a.text&&!0===t.props.hasIcon,selectedIcon:t.props.iconUrl,onChange:e=>{const t=e.detail;o.execCommand("iconUrl",t.src)}},{type:"heading",level:6,text:"spacing",active:()=>"design"===a.text},{type:"spacingPicker",active:()=>"design"===a.text,hasLeft:!1,hasRight:!1,value:{top:parseInt(t.props.style.paddingTop)||0,bottom:parseInt(t.props.style.paddingBottom)||0,left:parseInt(t.props.style.paddingLeft)||0,right:parseInt(t.props.style.paddingRight)||0},onChange:e=>{e.target.value;const t=e.target.topValue,n=e.target.bottomValue,r=e.target.leftValue,l=e.target.rightValue;o.execCommand("style",{paddingTop:t+"px",paddingBottom:n+"px",paddingLeft:r+"px",paddingRight:l+"px",padding:null})}}]}}}},d=e=>{let{helpers:t,editor:o,getFocused:n}=e;return{set:(e,r,l)=>{switch(r){case"style":return e[r]=t.deepMerge(e[r],l),!0;case"text":return e.text=l,n()||o.chain().setContent(l).run(),!0;case"ripple":case"rippleColor":case"scaleOnHover":case"hasIcon":case"iconUrl":case"iconSize":case"iconDirection":case"modalBlockId":return e[r]=l,!0;case"onClick":if(l.link)return e[r]=l,!0}}}};var i=o(72591),s=o.n(i),c=o(88639),p=o.n(c),b=o(88128),u=o.n(b),g=o(30855),x=o.n(g),f=o(93051),h=o.n(f),m=o(49536),y={};y.setAttributes=x(),y.insert=u().bind(null,"head"),y.domAPI=p(),y.insertStyleElement=h();s()(m.A,y);const A=m.A&&m.A.locals?m.A.locals:void 0;var C=o(81318),w=o(1366);const v=C.bP.create({name:"paragraph",priority:1e3,addOptions:()=>({HTMLAttributes:{}}),group:"block",content:"inline*",parseHTML:()=>[{tag:"p"}],renderHTML({HTMLAttributes:e}){return["p",(0,C.KV)(this.options.HTMLAttributes,e),0]},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}});var k=o(85194),S=o(28396);const E=C.YY.create({addKeyboardShortcuts:()=>({Enter:()=>!0})});const W=()=>{const e="button";return{name:e,create:t=>{const{createElement:o,compose:n,helpers:r}=t,{arrayToString:l,mergeDiff:i}=r;let s=!1;const c=document.createElement("div"),p=document.createElement("div"),{editor:b}=function(e){let{content:t,element:o}=e;return{element:o,editor:new C.KE({element:o,extensions:[w.A,v,S.A,k.Ay,E],content:t})}}({content:n.props.text,element:p});c.appendChild(p);return b.view.dom.setAttribute("dir","auto"),b.on("update",e=>{let{editor:t}=e;const o=t.getText();n.editor.store().updateComponent(n,"text",o)}),b.on("focus",e=>{let{event:t,editor:o}=e;s=!0}),b.on("blur",e=>{let{event:t,editor:o}=e;s=!1}),c.className=A.button,o({name:e,id:n.id,template:c,commands:{insertContent:e=>{b.commands.insertContent(e),b.chain().focus()}},defaultProps:{style:{height:"auto",width:"200px",padding:"10px",borderRadius:"5px",fontFamily:"Arial",fontSize:"16px"},text:"button"},render:()=>{try{n.props.style.display="",n.props.style.direction=""}catch(e){console.error(e)}i(c,{style:n.props.style}),c.style.height="auto";const e=n.props.hasIcon,t=n.props.iconUrl,o=n.props.iconDirection,r=n.props.iconSize,l="icon_in_button";let a=c.querySelector(`.${l}`)||document.createElement("img");e&&t?(a.className=l,a.src=t,a.style.width=(r||16)+"px",a.style.height=(r||16)+"px",a.style.marginRight="8px",a.style.marginLeft="8px","left"===o?c.insertBefore(a,c.firstChild):c.appendChild(a)):a.remove()},draggable:{group:"element"},droppable:{group:"element"},resizeable:()=>c,handleBar:!0,validator:d({template:c,helpers:r,editor:b,getFocused:function(){return s}}),schema:n.schema,onSelect:e=>{c.classList.add(e)},onDeselect:e=>{c.classList.remove(e)},elementProps:n,destroy:()=>{b.destroy()},remove:()=>{c.remove()},createEditor:a})}}}},49536(e,t,o){o.d(t,{A:()=>d});var n=o(82001),r=o.n(n),l=o(40935),a=o.n(l)()(r());a.push([e.id,".BEr8unIfy4OEGYhlHclN {\n cursor: text !important;\n}\n.BEr8unIfy4OEGYhlHclN {\n min-width: 30px;\n display: flex;\n justify-content: center;\n align-items: center;\n text-align: center;\n padding:10px;\n}\n.BEr8unIfy4OEGYhlHclN p {\n margin: 0;\n line-height: 1;\n}\n.cI3RTMAdk9qoZ8mu9Sm9 {\n width: 100%;\n}\n.VSumPf0Ui7b1pl8cMATP {\n position: absolute;\n z-index: 9;\n width: 3px;\n height: 90%;\n background: var(--resizer-color);\n border-radius: 20px;\n}\n.Vo2Ewnq6ekWFdNMjxBIB {\n left: -8px;\n cursor: w-resize;\n}\n.WLZC84sb1rfaRnHCDyj8 {\n left: calc(100% + 5px);\n cursor: e-resize;\n}\n\n.BEr8unIfy4OEGYhlHclN .VSumPf0Ui7b1pl8cMATP {\n display: none;\n}\n.BEr8unIfy4OEGYhlHclN.Qh20ei1Fa8QUbGinFFbw .VSumPf0Ui7b1pl8cMATP {\n display: block;\n}\n/* .handle{\n display: none;\n}\n.button.selected .handle{\n display: block;\n} */\n","",{version:3,sources:["webpack://./../web-editors/button-editor-component/lib/style.module.css"],names:[],mappings:"AAAA;EACE,uBAAuB;AAOzB;AARA;EAEE,eAAe;EACf,aAAa;EACb,uBAAuB;EACvB,mBAAmB;EACnB,kBAAkB;EAClB,YAAY;AACd;AACA;EACE,SAAS;EACT,cAAc;AAChB;AACA;EACE,WAAW;AACb;AACA;EACE,kBAAkB;EAClB,UAAU;EACV,UAAU;EACV,WAAW;EACX,gCAAgC;EAChC,mBAAmB;AACrB;AACA;EACE,UAAU;EACV,gBAAgB;AAClB;AACA;EACE,sBAAsB;EACtB,gBAAgB;AAClB;;AAEA;EACE,aAAa;AACf;AACA;EACE,cAAc;AAChB;AACA;;;;;GAKG",sourcesContent:[".button {\n cursor: text !important;\n min-width: 30px;\n display: flex;\n justify-content: center;\n align-items: center;\n text-align: center;\n padding:10px;\n}\n.button p {\n margin: 0;\n line-height: 1;\n}\n.contentEditable {\n width: 100%;\n}\n.margin {\n position: absolute;\n z-index: 9;\n width: 3px;\n height: 90%;\n background: var(--resizer-color);\n border-radius: 20px;\n}\n.marginLeft {\n left: -8px;\n cursor: w-resize;\n}\n.marginRight {\n left: calc(100% + 5px);\n cursor: e-resize;\n}\n\n.button .margin {\n display: none;\n}\n.button.selected .margin {\n display: block;\n}\n/* .handle{\n display: none;\n}\n.button.selected .handle{\n display: block;\n} */\n"],sourceRoot:""}]),a.locals={button:"BEr8unIfy4OEGYhlHclN",contentEditable:"cI3RTMAdk9qoZ8mu9Sm9",margin:"VSumPf0Ui7b1pl8cMATP",marginLeft:"Vo2Ewnq6ekWFdNMjxBIB",marginRight:"WLZC84sb1rfaRnHCDyj8",selected:"Qh20ei1Fa8QUbGinFFbw"};const d=a}}]);
Binary file
@@ -0,0 +1,25 @@
1
+ /*! For license information please see 7789.creaditor.bundle.js.LICENSE.txt */
2
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[7789],{68876(t,e,i){i.d(e,{r:()=>k,N:()=>N});i(69130);var n=i(53874);let o;const s={properties:{sizingTarget:{type:Object,value:function(){return this}},fitInto:{type:Object,value:window},noOverlap:{type:Boolean},positionTarget:{type:Element},horizontalAlign:{type:String},verticalAlign:{type:String},dynamicAlign:{type:Boolean},horizontalOffset:{type:Number,value:0,notify:!0},verticalOffset:{type:Number,value:0,notify:!0},autoFitOnAttach:{type:Boolean,value:!1},expandSizingTargetForScrollbars:{type:Boolean,value:!1},_fitInfo:{type:Object}},get _fitWidth(){return this.fitInto===window?this.fitInto.innerWidth:this.fitInto.getBoundingClientRect().width},get _fitHeight(){return this.fitInto===window?this.fitInto.innerHeight:this.fitInto.getBoundingClientRect().height},get _fitLeft(){return this.fitInto===window?0:this.fitInto.getBoundingClientRect().left},get _fitTop(){return this.fitInto===window?0:this.fitInto.getBoundingClientRect().top},get _defaultPositionTarget(){var t=(0,n.tT)(this).parentNode;return t&&t.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&(t=t.host),t},get _localeHorizontalAlign(){if(this._isRTL){if("right"===this.horizontalAlign)return"left";if("left"===this.horizontalAlign)return"right"}return this.horizontalAlign},get __shouldPosition(){return(this.horizontalAlign||this.verticalAlign)&&this.positionTarget},get _isRTL(){return void 0===this._memoizedIsRTL&&(this._memoizedIsRTL="rtl"==window.getComputedStyle(this).direction),this._memoizedIsRTL},attached:function(){this.positionTarget=this.positionTarget||this._defaultPositionTarget,this.autoFitOnAttach&&("none"===window.getComputedStyle(this).display?setTimeout(function(){this.fit()}.bind(this)):(window.ShadyDOM&&ShadyDOM.flush(),this.fit()))},detached:function(){this.__deferredFit&&(clearTimeout(this.__deferredFit),this.__deferredFit=null)},fit:function(){this.position(),this.constrain(),this.center()},_discoverInfo:function(){if(!this._fitInfo){var t=window.getComputedStyle(this),e=window.getComputedStyle(this.sizingTarget);this._fitInfo={inlineStyle:{top:this.style.top||"",left:this.style.left||"",position:this.style.position||""},sizerInlineStyle:{maxWidth:this.sizingTarget.style.maxWidth||"",maxHeight:this.sizingTarget.style.maxHeight||"",boxSizing:this.sizingTarget.style.boxSizing||""},positionedBy:{vertically:"auto"!==t.top?"top":"auto"!==t.bottom?"bottom":null,horizontally:"auto"!==t.left?"left":"auto"!==t.right?"right":null},sizedBy:{height:"none"!==e.maxHeight,width:"none"!==e.maxWidth,minWidth:parseInt(e.minWidth,10)||0,minHeight:parseInt(e.minHeight,10)||0},margin:{top:parseInt(t.marginTop,10)||0,right:parseInt(t.marginRight,10)||0,bottom:parseInt(t.marginBottom,10)||0,left:parseInt(t.marginLeft,10)||0}}}},resetFit:function(){var t=this._fitInfo||{};for(var e in t.sizerInlineStyle)this.sizingTarget.style[e]=t.sizerInlineStyle[e];for(var e in t.inlineStyle)this.style[e]=t.inlineStyle[e];this._fitInfo=null},refit:function(){var t=this.sizingTarget.scrollLeft,e=this.sizingTarget.scrollTop;this.resetFit(),this.fit(),this.sizingTarget.scrollLeft=t,this.sizingTarget.scrollTop=e},position:function(){if(!this.__shouldPosition)return;this._discoverInfo(),window.ShadyDOM&&window.ShadyDOM.flush(),this.style.position="fixed",this.sizingTarget.style.boxSizing="border-box",this.style.left="0px",this.style.top="0px";var t=this.getBoundingClientRect(),e=this.__getNormalizedRect(this.positionTarget),i=this.__getNormalizedRect(this.fitInto);let n,s,r,a;this.expandSizingTargetForScrollbars&&(n=this.sizingTarget.offsetWidth,s=this.sizingTarget.offsetHeight,r=this.sizingTarget.clientWidth,a=this.sizingTarget.clientHeight);var l=this._fitInfo.margin,h={width:t.width+l.left+l.right,height:t.height+l.top+l.bottom},c=this.__getPosition(this._localeHorizontalAlign,this.verticalAlign,h,t,e,i),d=c.left+l.left,f=c.top+l.top,u=Math.min(i.right-l.right,d+t.width),_=Math.min(i.bottom-l.bottom,f+t.height);d=Math.max(i.left+l.left,Math.min(d,u-this._fitInfo.sizedBy.minWidth)),f=Math.max(i.top+l.top,Math.min(f,_-this._fitInfo.sizedBy.minHeight));const p=Math.max(u-d,this._fitInfo.sizedBy.minWidth),g=Math.max(_-f,this._fitInfo.sizedBy.minHeight);this.sizingTarget.style.maxWidth=p+"px",this.sizingTarget.style.maxHeight=g+"px";const m=d-t.left,v=f-t.top;if(this.style.left=`${m}px`,this.style.top=`${v}px`,this.expandSizingTargetForScrollbars){const t=this.sizingTarget.offsetHeight,e=t-this.sizingTarget.clientHeight-(s-a);if(e>0){const n=i.height-l.top-l.bottom,o=Math.min(n,g+e);this.sizingTarget.style.maxHeight=`${o}px`;const s=this.sizingTarget.offsetHeight,r=s-t;let a;"top"===c.verticalAlign?a=v:"middle"===c.verticalAlign?a=v-r/2:"bottom"===c.verticalAlign&&(a=v-r),a=Math.max(i.top+l.top,Math.min(a,i.bottom-l.bottom-s)),this.style.top=`${a}px`}const h=this.sizingTarget.offsetWidth,d=h-this.sizingTarget.clientWidth-(n-r);if(d>0){const t=(()=>{if(void 0!==o)return o;const t=document.createElement("div");Object.assign(t.style,{overflow:"auto",position:"fixed",left:"0px",top:"0px",maxWidth:"100px",maxHeight:"100px"});const e=document.createElement("div");return e.style.width="200px",e.style.height="200px",t.appendChild(e),document.body.appendChild(t),o=Math.abs(t.offsetWidth-100)>1?t.offsetWidth-t.clientWidth:0,document.body.removeChild(t),o})(),e=i.width-l.left-l.right,n=Math.min(e,p+d-t);this.sizingTarget.style.maxWidth=`${n}px`;const s=this.sizingTarget.offsetWidth+t,r=s-h;let a;"left"===c.horizontalAlign?a=m:"center"===c.horizontalAlign?a=m-r/2:"right"===c.horizontalAlign&&(a=m-r),a=Math.max(i.left+l.left,Math.min(a,i.right-l.right-s)),this.style.left=`${a}px`}}},constrain:function(){if(!this.__shouldPosition){this._discoverInfo();var t=this._fitInfo;t.positionedBy.vertically||(this.style.position="fixed",this.style.top="0px"),t.positionedBy.horizontally||(this.style.position="fixed",this.style.left="0px"),this.sizingTarget.style.boxSizing="border-box";var e=this.getBoundingClientRect();t.sizedBy.height||this.__sizeDimension(e,t.positionedBy.vertically,"top","bottom","Height"),t.sizedBy.width||this.__sizeDimension(e,t.positionedBy.horizontally,"left","right","Width")}},_sizeDimension:function(t,e,i,n,o){this.__sizeDimension(t,e,i,n,o)},__sizeDimension:function(t,e,i,n,o){var s=this._fitInfo,r=this.__getNormalizedRect(this.fitInto),a="Width"===o?r.width:r.height,l=e===n,h=l?a-t[n]:t[i],c=s.margin[l?i:n],d="offset"+o,f=this[d]-this.sizingTarget[d];this.sizingTarget.style["max"+o]=a-c-h-f+"px"},center:function(){if(!this.__shouldPosition){this._discoverInfo();var t=this._fitInfo.positionedBy;if(!t.vertically||!t.horizontally){this.style.position="fixed",t.vertically||(this.style.top="0px"),t.horizontally||(this.style.left="0px");var e=this.getBoundingClientRect(),i=this.__getNormalizedRect(this.fitInto);if(!t.vertically){var n=i.top-e.top+(i.height-e.height)/2;this.style.top=n+"px"}if(!t.horizontally){var o=i.left-e.left+(i.width-e.width)/2;this.style.left=o+"px"}}}},__getNormalizedRect:function(t){return t===document.documentElement||t===window?{top:0,left:0,width:window.innerWidth,height:window.innerHeight,right:window.innerWidth,bottom:window.innerHeight}:t.getBoundingClientRect()},__getOffscreenArea:function(t,e,i){var n=Math.min(0,t.top)+Math.min(0,i.bottom-(t.top+e.height)),o=Math.min(0,t.left)+Math.min(0,i.right-(t.left+e.width));return Math.abs(n)*e.width+Math.abs(o)*e.height},__getPosition:function(t,e,i,n,o,s){var r,a=[{verticalAlign:"top",horizontalAlign:"left",top:o.top+this.verticalOffset,left:o.left+this.horizontalOffset},{verticalAlign:"top",horizontalAlign:"right",top:o.top+this.verticalOffset,left:o.right-i.width-this.horizontalOffset},{verticalAlign:"bottom",horizontalAlign:"left",top:o.bottom-i.height-this.verticalOffset,left:o.left+this.horizontalOffset},{verticalAlign:"bottom",horizontalAlign:"right",top:o.bottom-i.height-this.verticalOffset,left:o.right-i.width-this.horizontalOffset}];if(this.noOverlap){for(var l=0,h=a.length;l<h;l++){var c={};for(var d in a[l])c[d]=a[l][d];a.push(c)}a[0].top=a[1].top+=o.height,a[2].top=a[3].top-=o.height,a[4].left=a[6].left+=o.width,a[5].left=a[7].left-=o.width}e="auto"===e?null:e,(t="auto"===t?null:t)&&"center"!==t||(a.push({verticalAlign:"top",horizontalAlign:"center",top:o.top+this.verticalOffset+(this.noOverlap?o.height:0),left:o.left-n.width/2+o.width/2+this.horizontalOffset}),a.push({verticalAlign:"bottom",horizontalAlign:"center",top:o.bottom-i.height-this.verticalOffset-(this.noOverlap?o.height:0),left:o.left-n.width/2+o.width/2+this.horizontalOffset})),e&&"middle"!==e||(a.push({verticalAlign:"middle",horizontalAlign:"left",top:o.top-n.height/2+o.height/2+this.verticalOffset,left:o.left+this.horizontalOffset+(this.noOverlap?o.width:0)}),a.push({verticalAlign:"middle",horizontalAlign:"right",top:o.top-n.height/2+o.height/2+this.verticalOffset,left:o.right-i.width-this.horizontalOffset-(this.noOverlap?o.width:0)})),"middle"===e&&"center"===t&&a.push({verticalAlign:"middle",horizontalAlign:"center",top:o.top-n.height/2+o.height/2+this.verticalOffset,left:o.left-n.width/2+o.width/2+this.horizontalOffset});for(l=0;l<a.length;l++){var f=a[l],u=f.verticalAlign===e,_=f.horizontalAlign===t;if(!this.dynamicAlign&&!this.noOverlap&&u&&_){r=f;break}var p=(!e||u)&&(!t||_);if(this.dynamicAlign||p){if(f.offscreenArea=this.__getOffscreenArea(f,i,s),0===f.offscreenArea&&p){r=f;break}r=r||f;var g=f.offscreenArea-r.offscreenArea;(g<0||0===g&&(u||_))&&(r=f)}}return r}};var r=i(12822),a=new Set;const l={properties:{_parentResizable:{type:Object,observer:"_parentResizableChanged"},_notifyingDescendant:{type:Boolean,value:!1}},listeners:{"iron-request-resize-notifications":"_onIronRequestResizeNotifications"},created:function(){this._interestedResizables=[],this._boundNotifyResize=this.notifyResize.bind(this),this._boundOnDescendantIronResize=this._onDescendantIronResize.bind(this)},attached:function(){this._requestResizeNotifications()},detached:function(){this._parentResizable?this._parentResizable.stopResizeNotificationsFor(this):(a.delete(this),window.removeEventListener("resize",this._boundNotifyResize)),this._parentResizable=null},notifyResize:function(){this.isAttached&&(this._interestedResizables.forEach(function(t){this.resizerShouldNotify(t)&&this._notifyDescendant(t)},this),this._fireResize())},assignParentResizable:function(t){this._parentResizable&&this._parentResizable.stopResizeNotificationsFor(this),this._parentResizable=t,t&&-1===t._interestedResizables.indexOf(this)&&(t._interestedResizables.push(this),t._subscribeIronResize(this))},stopResizeNotificationsFor:function(t){var e=this._interestedResizables.indexOf(t);e>-1&&(this._interestedResizables.splice(e,1),this._unsubscribeIronResize(t))},_subscribeIronResize:function(t){t.addEventListener("iron-resize",this._boundOnDescendantIronResize)},_unsubscribeIronResize:function(t){t.removeEventListener("iron-resize",this._boundOnDescendantIronResize)},resizerShouldNotify:function(t){return!0},_onDescendantIronResize:function(t){this._notifyingDescendant?t.stopPropagation():r.sv||this._fireResize()},_fireResize:function(){this.fire("iron-resize",null,{node:this,bubbles:!1})},_onIronRequestResizeNotifications:function(t){var e=(0,n.tT)(t).rootTarget;e!==this&&(e.assignParentResizable(this),this._notifyDescendant(e),t.stopPropagation())},_parentResizableChanged:function(t){t&&window.removeEventListener("resize",this._boundNotifyResize)},_notifyDescendant:function(t){this.isAttached&&(this._notifyingDescendant=!0,t.notifyResize(),this._notifyingDescendant=!1)},_requestResizeNotifications:function(){if(this.isAttached)if("loading"===document.readyState){var t=this._requestResizeNotifications.bind(this);document.addEventListener("readystatechange",function e(){document.removeEventListener("readystatechange",e),t()})}else this._findParent(),this._parentResizable?this._parentResizable._interestedResizables.forEach(function(t){t!==this&&t._findParent()},this):(a.forEach(function(t){t!==this&&t._findParent()},this),window.addEventListener("resize",this._boundNotifyResize),this.notifyResize())},_findParent:function(){this.assignParentResizable(null),this.fire("iron-request-resize-notifications",null,{node:this,bubbles:!0,cancelable:!0}),this._parentResizable?a.delete(this):a.add(this)}};var h=Element.prototype,c=h.matches||h.matchesSelector||h.mozMatchesSelector||h.msMatchesSelector||h.oMatchesSelector||h.webkitMatchesSelector;const d=new class{getTabbableNodes(t){var e=[];return this._collectTabbableNodes(t,e)?this._sortByTabIndex(e):e}isFocusable(t){return c.call(t,"input, select, textarea, button, object")?c.call(t,":not([disabled])"):c.call(t,"a[href], area[href], iframe, [tabindex], [contentEditable]")}isTabbable(t){return this.isFocusable(t)&&c.call(t,':not([tabindex="-1"])')&&this._isVisible(t)}_normalizedTabIndex(t){if(this.isFocusable(t)){var e=t.getAttribute("tabindex")||0;return Number(e)}return-1}_collectTabbableNodes(t,e){if(t.nodeType!==Node.ELEMENT_NODE)return!1;var i=t;if(!this._isVisible(i))return!1;var o,s=this._normalizedTabIndex(i),r=s>0;s>=0&&e.push(i),o="content"===i.localName||"slot"===i.localName?(0,n.tT)(i).getDistributedNodes():(0,n.tT)(i.root||i).children;for(var a=0;a<o.length;a++)r=this._collectTabbableNodes(o[a],e)||r;return r}_isVisible(t){var e=t.style;return"hidden"!==e.visibility&&"none"!==e.display&&("hidden"!==(e=window.getComputedStyle(t)).visibility&&"none"!==e.display)}_sortByTabIndex(t){var e=t.length;if(e<2)return t;var i=Math.ceil(e/2),n=this._sortByTabIndex(t.slice(0,i)),o=this._sortByTabIndex(t.slice(i));return this._mergeSortByTabIndex(n,o)}_mergeSortByTabIndex(t,e){for(var i=[];t.length>0&&e.length>0;)this._hasLowerTabOrder(t[0],e[0])?i.push(e.shift()):i.push(t.shift());return i.concat(t,e)}_hasLowerTabOrder(t,e){var i=Math.max(t.tabIndex,0),n=Math.max(e.tabIndex,0);return 0===i||0===n?n>i:i>n}};var f=i(95586),u=i(47351);(0,f.b)({_template:u.q`
3
+ <style>
4
+ :host {
5
+ position: fixed;
6
+ top: 0;
7
+ left: 0;
8
+ width: 100%;
9
+ height: 100%;
10
+ background-color: var(--iron-overlay-backdrop-background-color, #000);
11
+ opacity: 0;
12
+ transition: opacity 0.2s;
13
+ pointer-events: none;
14
+ @apply --iron-overlay-backdrop;
15
+ }
16
+
17
+ :host(.opened) {
18
+ opacity: var(--iron-overlay-backdrop-opacity, 0.6);
19
+ pointer-events: auto;
20
+ @apply --iron-overlay-backdrop-opened;
21
+ }
22
+ </style>
23
+
24
+ <slot></slot>
25
+ `,is:"iron-overlay-backdrop",properties:{opened:{reflectToAttribute:!0,type:Boolean,value:!1,observer:"_openedChanged"}},listeners:{transitionend:"_onTransitionend"},created:function(){this.__openedRaf=null},attached:function(){this.opened&&this._openedChanged(this.opened)},prepare:function(){this.opened&&!this.parentNode&&(0,n.tT)(document.body).appendChild(this)},open:function(){this.opened=!0},close:function(){this.opened=!1},complete:function(){this.opened||this.parentNode!==document.body||(0,n.tT)(this.parentNode).removeChild(this)},_onTransitionend:function(t){t&&t.target===this&&this.complete()},_openedChanged:function(t){if(t)this.prepare();else{var e=window.getComputedStyle(this);"0s"!==e.transitionDuration&&0!=e.opacity||this.complete()}this.isAttached&&(this.__openedRaf&&(window.cancelAnimationFrame(this.__openedRaf),this.__openedRaf=null),this.scrollTop=this.scrollTop,this.__openedRaf=window.requestAnimationFrame(function(){this.__openedRaf=null,this.toggleClass("opened",this.opened)}.bind(this)))}});var _=i(35915),p=i(15055);const g=new class{constructor(){this._overlays=[],this._minimumZ=101,this._backdropElement=null,p.ch(document.documentElement,"tap",function(){}),document.addEventListener("tap",this._onCaptureClick.bind(this),!0),document.addEventListener("focus",this._onCaptureFocus.bind(this),!0),document.addEventListener("keydown",this._onCaptureKeyDown.bind(this),!0)}get backdropElement(){return this._backdropElement||(this._backdropElement=document.createElement("iron-overlay-backdrop")),this._backdropElement}get deepActiveElement(){var t=document.activeElement;for(t&&t instanceof Element!=!1||(t=document.body);t.root&&(0,n.tT)(t.root).activeElement;)t=(0,n.tT)(t.root).activeElement;return t}_bringOverlayAtIndexToFront(t){var e=this._overlays[t];if(e){var i=this._overlays.length-1,n=this._overlays[i];if(n&&this._shouldBeBehindOverlay(e,n)&&i--,!(t>=i)){var o=Math.max(this.currentOverlayZ(),this._minimumZ);for(this._getZ(e)<=o&&this._applyOverlayZ(e,o);t<i;)this._overlays[t]=this._overlays[t+1],t++;this._overlays[i]=e}}}addOrRemoveOverlay(t){t.opened?this.addOverlay(t):this.removeOverlay(t)}addOverlay(t){var e=this._overlays.indexOf(t);if(e>=0)return this._bringOverlayAtIndexToFront(e),void this.trackBackdrop();var i=this._overlays.length,n=this._overlays[i-1],o=Math.max(this._getZ(n),this._minimumZ),s=this._getZ(t);if(n&&this._shouldBeBehindOverlay(t,n)){this._applyOverlayZ(n,o),i--;var r=this._overlays[i-1];o=Math.max(this._getZ(r),this._minimumZ)}s<=o&&this._applyOverlayZ(t,o),this._overlays.splice(i,0,t),this.trackBackdrop()}removeOverlay(t){var e=this._overlays.indexOf(t);-1!==e&&(this._overlays.splice(e,1),this.trackBackdrop())}currentOverlay(){var t=this._overlays.length-1;return this._overlays[t]}currentOverlayZ(){return this._getZ(this.currentOverlay())}ensureMinimumZ(t){this._minimumZ=Math.max(this._minimumZ,t)}focusOverlay(){var t=this.currentOverlay();t&&t._applyFocus()}trackBackdrop(){var t=this._overlayWithBackdrop();(t||this._backdropElement)&&(this.backdropElement.style.zIndex=this._getZ(t)-1,this.backdropElement.opened=!!t,this.backdropElement.prepare())}getBackdrops(){for(var t=[],e=0;e<this._overlays.length;e++)this._overlays[e].withBackdrop&&t.push(this._overlays[e]);return t}backdropZ(){return this._getZ(this._overlayWithBackdrop())-1}_overlayWithBackdrop(){for(var t=this._overlays.length-1;t>=0;t--)if(this._overlays[t].withBackdrop)return this._overlays[t]}_getZ(t){var e=this._minimumZ;if(t){var i=Number(t.style.zIndex||window.getComputedStyle(t).zIndex);i==i&&(e=i)}return e}_setZ(t,e){t.style.zIndex=e}_applyOverlayZ(t,e){this._setZ(t,e+2)}_overlayInPath(t){t=t||[];for(var e=0;e<t.length;e++)if(t[e]._manager===this)return t[e]}_onCaptureClick(t){var e=this._overlays.length-1;if(-1!==e)for(var i,o=(0,n.tT)(t).path;(i=this._overlays[e])&&this._overlayInPath(o)!==i&&(i._onCaptureClick(t),i.allowClickThrough);)e--}_onCaptureFocus(t){var e=this.currentOverlay();e&&e._onCaptureFocus(t)}_onCaptureKeyDown(t){var e=this.currentOverlay();e&&(_.D.keyboardEventMatchesKeys(t,"esc")?e._onCaptureEsc(t):_.D.keyboardEventMatchesKeys(t,"tab")&&e._onCaptureTab(t))}_shouldBeBehindOverlay(t,e){return!t.alwaysOnTop&&e.alwaysOnTop}};var m,v,y={pageX:0,pageY:0},b=null,z=[],T=["wheel","mousewheel","DOMMouseScroll","touchstart","touchmove"];function w(t){A.indexOf(t)>=0||(0===A.length&&function(){m=m||R.bind(void 0);for(var t=0,e=T.length;t<e;t++)document.addEventListener(T[t],m,{capture:!0,passive:!1})}(),A.push(t),v=A[A.length-1],O=[],x=[])}function C(t){var e=A.indexOf(t);-1!==e&&(A.splice(e,1),v=A[A.length-1],O=[],x=[],0===A.length&&function(){for(var t=0,e=T.length;t<e;t++)document.removeEventListener(T[t],m,{capture:!0,passive:!1})}())}const A=[];let O=null,x=null;function R(t){if(t.cancelable&&function(t){var e=(0,n.tT)(t).rootTarget;"touchmove"!==t.type&&b!==e&&(b=e,z=function(t){for(var e=[],i=t.indexOf(v),n=0;n<=i;n++)if(t[n].nodeType===Node.ELEMENT_NODE){var o=t[n],s=o.style;"scroll"!==s.overflow&&"auto"!==s.overflow&&(s=window.getComputedStyle(o)),"scroll"!==s.overflow&&"auto"!==s.overflow||e.push(o)}return e}((0,n.tT)(t).path));if(!z.length)return!0;if("touchstart"===t.type)return!1;var i=function(t){var e={deltaX:t.deltaX,deltaY:t.deltaY};if("deltaX"in t);else if("wheelDeltaX"in t&&"wheelDeltaY"in t)e.deltaX=-t.wheelDeltaX,e.deltaY=-t.wheelDeltaY;else if("wheelDelta"in t)e.deltaX=0,e.deltaY=-t.wheelDelta;else if("axis"in t)e.deltaX=1===t.axis?t.detail:0,e.deltaY=2===t.axis?t.detail:0;else if(t.targetTouches){var i=t.targetTouches[0];e.deltaX=y.pageX-i.pageX,e.deltaY=y.pageY-i.pageY}return e}(t);return!function(t,e,i){if(!e&&!i)return;for(var n=Math.abs(i)>=Math.abs(e),o=0;o<t.length;o++){var s=t[o];if(n?i<0?s.scrollTop>0:s.scrollTop<s.scrollHeight-s.clientHeight:e<0?s.scrollLeft>0:s.scrollLeft<s.scrollWidth-s.clientWidth)return s}}(z,i.deltaX,i.deltaY)}(t)&&t.preventDefault(),t.targetTouches){var e=t.targetTouches[0];y.pageX=e.pageX,y.pageY=e.pageY}}const N={properties:{opened:{observer:"_openedChanged",type:Boolean,value:!1,notify:!0},canceled:{observer:"_canceledChanged",readOnly:!0,type:Boolean,value:!1},withBackdrop:{observer:"_withBackdropChanged",type:Boolean},noAutoFocus:{type:Boolean,value:!1},noCancelOnEscKey:{type:Boolean,value:!1},noCancelOnOutsideClick:{type:Boolean,value:!1},closingReason:{type:Object},restoreFocusOnClose:{type:Boolean,value:!1},allowClickThrough:{type:Boolean},alwaysOnTop:{type:Boolean},scrollAction:{type:String},_manager:{type:Object,value:g},_focusedChild:{type:Object}},listeners:{"iron-resize":"_onIronResize"},observers:["__updateScrollObservers(isAttached, opened, scrollAction)"],get backdropElement(){return this._manager.backdropElement},get _focusNode(){return this._focusedChild||(0,n.tT)(this).querySelector("[autofocus]")||this},get _focusableNodes(){return d.getTabbableNodes(this)},ready:function(){this.__isAnimating=!1,this.__shouldRemoveTabIndex=!1,this.__firstFocusableNode=this.__lastFocusableNode=null,this.__rafs={},this.__restoreFocusNode=null,this.__scrollTop=this.__scrollLeft=null,this.__onCaptureScroll=this.__onCaptureScroll.bind(this),this.__rootNodes=null,this._ensureSetup()},attached:function(){this.opened&&this._openedChanged(this.opened),this._observer=(0,n.tT)(this).observeNodes(this._onNodesChange)},detached:function(){for(var t in this._observer&&(0,n.tT)(this).unobserveNodes(this._observer),this._observer=null,this.__rafs)null!==this.__rafs[t]&&cancelAnimationFrame(this.__rafs[t]);this.__rafs={},this._manager.removeOverlay(this),this.__isAnimating&&(this.opened?this._finishRenderOpened():(this._applyFocus(),this._finishRenderClosed()))},toggle:function(){this._setCanceled(!1),this.opened=!this.opened},open:function(){this._setCanceled(!1),this.opened=!0},close:function(){this._setCanceled(!1),this.opened=!1},cancel:function(t){this.fire("iron-overlay-canceled",t,{cancelable:!0}).defaultPrevented||(this._setCanceled(!0),this.opened=!1)},invalidateTabbables:function(){this.__firstFocusableNode=this.__lastFocusableNode=null},_ensureSetup:function(){this._overlaySetup||(this._overlaySetup=!0,this.style.outline="none",this.style.display="none")},_openedChanged:function(t){t?this.removeAttribute("aria-hidden"):this.setAttribute("aria-hidden","true"),this.isAttached&&(this.__isAnimating=!0,this.__deraf("__openedChanged",this.__openedChanged))},_canceledChanged:function(){this.closingReason=this.closingReason||{},this.closingReason.canceled=this.canceled},_withBackdropChanged:function(){this.withBackdrop&&!this.hasAttribute("tabindex")?(this.setAttribute("tabindex","-1"),this.__shouldRemoveTabIndex=!0):this.__shouldRemoveTabIndex&&(this.removeAttribute("tabindex"),this.__shouldRemoveTabIndex=!1),this.opened&&this.isAttached&&this._manager.trackBackdrop()},_prepareRenderOpened:function(){this.__restoreFocusNode=this._manager.deepActiveElement,this._preparePositioning(),this.refit(),this._finishPositioning(),this.noAutoFocus&&document.activeElement===this._focusNode&&(this._focusNode.blur(),this.__restoreFocusNode.focus())},_renderOpened:function(){this._finishRenderOpened()},_renderClosed:function(){this._finishRenderClosed()},_finishRenderOpened:function(){this.notifyResize(),this.__isAnimating=!1,this.fire("iron-overlay-opened")},_finishRenderClosed:function(){this.style.display="none",this.style.zIndex="",this.notifyResize(),this.__isAnimating=!1,this.fire("iron-overlay-closed",this.closingReason)},_preparePositioning:function(){this.style.transition=this.style.webkitTransition="none",this.style.transform=this.style.webkitTransform="none",this.style.display=""},_finishPositioning:function(){this.style.display="none",this.scrollTop=this.scrollTop,this.style.transition=this.style.webkitTransition="",this.style.transform=this.style.webkitTransform="",this.style.display="",this.scrollTop=this.scrollTop},_applyFocus:function(){if(this.opened)this.noAutoFocus||this._focusNode.focus();else{if(this.restoreFocusOnClose&&this.__restoreFocusNode){var t=this._manager.deepActiveElement;(t===document.body||E(this,t))&&this.__restoreFocusNode.focus()}this.__restoreFocusNode=null,this._focusNode.blur(),this._focusedChild=null}},_onCaptureClick:function(t){this.noCancelOnOutsideClick||this.cancel(t)},_onCaptureFocus:function(t){if(this.withBackdrop){var e=(0,n.tT)(t).path;-1===e.indexOf(this)?(t.stopPropagation(),this._applyFocus()):this._focusedChild=e[0]}},_onCaptureEsc:function(t){this.noCancelOnEscKey||this.cancel(t)},_onCaptureTab:function(t){if(this.withBackdrop){this.__ensureFirstLastFocusables();var e=t.shiftKey,i=e?this.__firstFocusableNode:this.__lastFocusableNode,n=e?this.__lastFocusableNode:this.__firstFocusableNode,o=!1;if(i===n)o=!0;else{var s=this._manager.deepActiveElement;o=s===i||s===this}o&&(t.preventDefault(),this._focusedChild=n,this._applyFocus())}},_onIronResize:function(){this.opened&&!this.__isAnimating&&this.__deraf("refit",this.refit)},_onNodesChange:function(){this.opened&&!this.__isAnimating&&(this.invalidateTabbables(),this.notifyResize())},__ensureFirstLastFocusables:function(){var t=this._focusableNodes;this.__firstFocusableNode=t[0],this.__lastFocusableNode=t[t.length-1]},__openedChanged:function(){this.opened?(this._prepareRenderOpened(),this._manager.addOverlay(this),this._applyFocus(),this._renderOpened()):(this._manager.removeOverlay(this),this._applyFocus(),this._renderClosed())},__deraf:function(t,e){var i=this.__rafs;null!==i[t]&&cancelAnimationFrame(i[t]),i[t]=requestAnimationFrame(function(){i[t]=null,e.call(this)}.bind(this))},__updateScrollObservers:function(t,e,i){t&&e&&this.__isValidScrollAction(i)?("lock"===i&&(this.__saveScrollPosition(),w(this)),this.__addScrollListeners()):(C(this),this.__removeScrollListeners())},__addScrollListeners:function(){if(!this.__rootNodes){if(this.__rootNodes=[],r.sv)for(var t=this;t;)t.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&t.host&&this.__rootNodes.push(t),t=t.host||t.assignedSlot||t.parentNode;this.__rootNodes.push(document)}this.__rootNodes.forEach(function(t){t.addEventListener("scroll",this.__onCaptureScroll,{capture:!0,passive:!0})},this)},__removeScrollListeners:function(){this.__rootNodes&&this.__rootNodes.forEach(function(t){t.removeEventListener("scroll",this.__onCaptureScroll,{capture:!0,passive:!0})},this),this.isAttached||(this.__rootNodes=null)},__isValidScrollAction:function(t){return"lock"===t||"refit"===t||"cancel"===t},__onCaptureScroll:function(t){if(!(this.__isAnimating||(0,n.tT)(t).path.indexOf(this)>=0))switch(this.scrollAction){case"lock":this.__restoreScrollPosition();break;case"refit":this.__deraf("refit",this.refit);break;case"cancel":this.cancel(t)}},__saveScrollPosition:function(){document.scrollingElement?(this.__scrollTop=document.scrollingElement.scrollTop,this.__scrollLeft=document.scrollingElement.scrollLeft):(this.__scrollTop=Math.max(document.documentElement.scrollTop,document.body.scrollTop),this.__scrollLeft=Math.max(document.documentElement.scrollLeft,document.body.scrollLeft))},__restoreScrollPosition:function(){document.scrollingElement?(document.scrollingElement.scrollTop=this.__scrollTop,document.scrollingElement.scrollLeft=this.__scrollLeft):(document.documentElement.scrollTop=document.body.scrollTop=this.__scrollTop,document.documentElement.scrollLeft=document.body.scrollLeft=this.__scrollLeft)}},I=t=>t.assignedSlot||t.parentNode||t.host,E=(t,e)=>{for(let i=e;i;i=I(i))if(i===t)return!0;return!1},k=[s,l,N]},74396(t,e,i){i.d(e,{L:()=>n});i(69130);const n=[{properties:{animationConfig:{type:Object},entryAnimation:{observer:"_entryAnimationChanged",type:String},exitAnimation:{observer:"_exitAnimationChanged",type:String}},_entryAnimationChanged:function(){this.animationConfig=this.animationConfig||{},this.animationConfig.entry=[{name:this.entryAnimation,node:this}]},_exitAnimationChanged:function(){this.animationConfig=this.animationConfig||{},this.animationConfig.exit=[{name:this.exitAnimation,node:this}]},_copyProperties:function(t,e){for(var i in e)t[i]=e[i]},_cloneConfig:function(t){var e={isClone:!0};return this._copyProperties(e,t),e},_getAnimationConfigRecursive:function(t,e,i){var n;if(this.animationConfig)if(this.animationConfig.value&&"function"==typeof this.animationConfig.value)this._warn(this._logf("playAnimation","Please put 'animationConfig' inside of your components 'properties' object instead of outside of it."));else if(n=t?this.animationConfig[t]:this.animationConfig,Array.isArray(n)||(n=[n]),n)for(var o,s=0;o=n[s];s++)if(o.animatable)o.animatable._getAnimationConfigRecursive(o.type||t,e,i);else if(o.id){var r=e[o.id];r?(r.isClone||(e[o.id]=this._cloneConfig(r),r=e[o.id]),this._copyProperties(r,o)):e[o.id]=o}else i.push(o)},getAnimationConfig:function(t){var e={},i=[];for(var n in this._getAnimationConfigRecursive(t,e,i),e)i.push(e[n]);return i}},{_configureAnimations:function(t){var e=[],i=[];if(t.length>0)for(let e,n=0;e=t[n];n++){let t=document.createElement(e.name);if(t.isNeonAnimation){let n=null;t.configure||(t.configure=function(t){return null}),n=t.configure(e),i.push({result:n,config:e,neonAnimation:t})}else console.warn(this.is+":",e.name,"not found!")}for(var n=0;n<i.length;n++){let t=i[n].result,o=i[n].config,s=i[n].neonAnimation;try{"function"!=typeof t.cancel&&(t=document.timeline.play(t))}catch(e){t=null,console.warn("Couldnt play","(",o.name,").",e)}t&&e.push({neonAnimation:s,config:o,animation:t})}return e},_shouldComplete:function(t){for(var e=!0,i=0;i<t.length;i++)if("finished"!=t[i].animation.playState){e=!1;break}return e},_complete:function(t){for(var e=0;e<t.length;e++)t[e].neonAnimation.complete(t[e].config);for(e=0;e<t.length;e++)t[e].animation.cancel()},playAnimation:function(t,e){var i=this.getAnimationConfig(t);if(i){this._active=this._active||{},this._active[t]&&(this._complete(this._active[t]),delete this._active[t]);var n=this._configureAnimations(i);if(0!=n.length){this._active[t]=n;for(var o=0;o<n.length;o++)n[o].animation.onfinish=function(){this._shouldComplete(n)&&(this._complete(n),delete this._active[t],this.fire("neon-animation-finish",e,{bubbles:!1}))}.bind(this)}else this.fire("neon-animation-finish",e,{bubbles:!1})}},cancelAnimation:function(){for(var t in this._active){var e=this._active[t];for(var i in e)e[i].animation.cancel()}this._active={}}}]}}]);
@@ -0,0 +1,32 @@
1
+ /**
2
+ @license
3
+ Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
4
+ This code may only be used under the BSD style license found at
5
+ http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
6
+ http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
7
+ found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
8
+ part of the polymer project is also subject to an additional IP rights grant
9
+ found at http://polymer.github.io/PATENTS.txt
10
+ */
11
+
12
+ /**
13
+ @license
14
+ Copyright (c) 2016 The Polymer Project Authors. All rights reserved.
15
+ This code may only be used under the BSD style license found at
16
+ http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
17
+ http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
18
+ found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
19
+ part of the polymer project is also subject to an additional IP rights grant
20
+ found at http://polymer.github.io/PATENTS.txt
21
+ */
22
+
23
+ /**
24
+ @license
25
+ Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
26
+ This code may only be used under the BSD style license found at
27
+ http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
28
+ http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
29
+ found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
30
+ part of the polymer project is also subject to an additional IP rights grant
31
+ found at http://polymer.github.io/PATENTS.txt
32
+ */
Binary file