@vandeurenglenn/lite-elements 0.3.81 → 0.3.83

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.
@@ -68,6 +68,7 @@ import{_ as t,a as e}from"./tslib.es6-B87RQr7F.js";import{s as o,i as s,x as i}f
68
68
  <custom-drawer-item route="toggle">toggle</custom-drawer-item>
69
69
  <custom-drawer-item route="toggle-button">toggle-button</custom-drawer-item>
70
70
  <custom-drawer-item route="time-picker">time-picker</custom-drawer-item>
71
+ <custom-drawer-item route="places-input">places-input</custom-drawer-item>
71
72
  </custom-selector>
72
73
  </flex-column>
73
74
 
@@ -536,6 +537,10 @@ import{_ as t,a as e}from"./tslib.es6-B87RQr7F.js";import{s as o,i as s,x as i}f
536
537
  </demo-section>
537
538
  </custom-pages>
538
539
  </flex-column>
540
+
541
+ <demo-section route="places-input">
542
+ <places-input placeholder="place"> </places-input>
543
+ </demo-section>
539
544
  </custom-drawer-layout>
540
545
  <!-- </custom-root> -->
541
546
  <!-- </flex-row> -->
@@ -25,6 +25,8 @@ import{_ as t,a as e}from"./tslib.es6-B87RQr7F.js";import{s as o,i as s,x as i}f
25
25
  <custom-drawer-item route="list-item">list-item</custom-drawer-item>
26
26
  <custom-drawer-item route="toggle">toggle</custom-drawer-item>
27
27
  <custom-drawer-item route="toggle-button">toggle-button</custom-drawer-item>
28
+
29
+ <custom-drawer-item route="places-input">places-input</custom-drawer-item>
28
30
  </custom-selector>
29
31
  </flex-column>
30
32
 
@@ -1,4 +1,4 @@
1
- import{_ as e,a as t}from"./tslib.es6-B87RQr7F.js";import{s,r as a,i as o,x as i}from"./dark-mode-m29sAj4H.js";import{e as r}from"./custom-element-B_TPyPQO.js";import"./icon-button.js";import"./button.js";import"./elevation.js";import"./button.css.js";import"./icon.js";let n=(()=>{let n,c,l,d,m,p=[r("custom-drawer-button")],u=[],b=s,h=[],_=[],g=[],w=[],v=[],y=[];return class extends b{static{c=this}static{const t="function"==typeof Symbol&&Symbol.metadata?Object.create(b[Symbol.metadata]??null):void 0;l=[a({type:Boolean,reflect:!0})],d=[a({type:Boolean,reflect:!0,attribute:"drawer-open"})],m=[a()],e(this,null,l,{kind:"accessor",name:"mobile",static:!1,private:!1,access:{has:e=>"mobile"in e,get:e=>e.mobile,set:(e,t)=>{e.mobile=t}},metadata:t},h,_),e(this,null,d,{kind:"accessor",name:"drawerOpen",static:!1,private:!1,access:{has:e=>"drawerOpen"in e,get:e=>e.drawerOpen,set:(e,t)=>{e.drawerOpen=t}},metadata:t},g,w),e(this,null,m,{kind:"accessor",name:"id",static:!1,private:!1,access:{has:e=>"id"in e,get:e=>e.id,set:(e,t)=>{e.id=t}},metadata:t},v,y),e(null,n={value:c},p,{kind:"class",name:c.name,metadata:t},null,u),c=n.value,t&&Object.defineProperty(c,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}#e=t(this,h,!1);get mobile(){return this.#e}set mobile(e){this.#e=e}#t=(t(this,_),t(this,g,void 0));get drawerOpen(){return this.#t}set drawerOpen(e){this.#t=e}#s=(t(this,w),t(this,v,void 0));get id(){return this.#s}set id(e){this.#s=e}openPane(){document.dispatchEvent(new CustomEvent("custom-pane-open",{detail:this.id}))}static styles=[o`
1
+ import{_ as e,a as t}from"./tslib.es6-B87RQr7F.js";import{s as a,r as s,i as r,x as o}from"./dark-mode-m29sAj4H.js";import{e as i}from"./custom-element-B_TPyPQO.js";import"./icon-button.js";import"./button.js";import"./elevation.js";import"./button.css.js";import"./icon.js";let n=(()=>{let n,c,l,d,p,m=[i("custom-drawer-button")],u=[],b=a,h=[],_=[],g=[],w=[],v=[],y=[];return class extends b{static{c=this}static{const t="function"==typeof Symbol&&Symbol.metadata?Object.create(b[Symbol.metadata]??null):void 0;l=[s({type:Boolean,reflect:!0,attribute:"drawer-open"})],d=[s()],p=[s({type:String,reflect:!0})],e(this,null,l,{kind:"accessor",name:"drawerOpen",static:!1,private:!1,access:{has:e=>"drawerOpen"in e,get:e=>e.drawerOpen,set:(e,t)=>{e.drawerOpen=t}},metadata:t},h,_),e(this,null,d,{kind:"accessor",name:"id",static:!1,private:!1,access:{has:e=>"id"in e,get:e=>e.id,set:(e,t)=>{e.id=t}},metadata:t},g,w),e(this,null,p,{kind:"accessor",name:"label",static:!1,private:!1,access:{has:e=>"label"in e,get:e=>e.label,set:(e,t)=>{e.label=t}},metadata:t},v,y),e(null,n={value:c},m,{kind:"class",name:c.name,metadata:t},null,u),c=n.value,t&&Object.defineProperty(c,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}#e=t(this,h,void 0);get drawerOpen(){return this.#e}set drawerOpen(e){this.#e=e}#t=(t(this,_),t(this,g,void 0));get id(){return this.#t}set id(e){this.#t=e}#a=(t(this,w),t(this,v,"menu"));get label(){return this.#a}set label(e){this.#a=e}openPane(){document.dispatchEvent(new CustomEvent("custom-pane-open",{detail:this.id}))}static styles=[r`
2
2
  :host {
3
3
  display: block;
4
4
  opacity: 1;
@@ -11,4 +11,6 @@ import{_ as e,a as t}from"./tslib.es6-B87RQr7F.js";import{s,r as a,i as o,x as i
11
11
  pointer-events: none;
12
12
  width: 0;
13
13
  }
14
- `];render(){return i` <custom-icon-button @click=${()=>this.openPane()} icon="menu"> </custom-icon-button> `}constructor(){super(...arguments),t(this,y)}static{t(c,u)}},c})();export{n as CustomDrawerButton};
14
+ `];render(){return o`
15
+ <custom-icon-button @click=${()=>this.openPane()} label="Open drawer" icon="menu"> </custom-icon-button>
16
+ `}constructor(){super(...arguments),t(this,y)}static{t(c,u)}},c})();export{n as CustomDrawerButton};
@@ -37,7 +37,7 @@ import{_ as t,a as e}from"./tslib.es6-B87RQr7F.js";import{i as s,s as a,r as o,x
37
37
  ::slotted(*) {
38
38
  pointer-events: none;
39
39
  }
40
- `;let l=(()=>{let s,l,c,m,d,p,h,g=[r("custom-drawer")],u=[],y=a,b=[],v=[],f=[],_=[],x=[],w=[],j=[],k=[],S=[],z=[];return class extends y{static{l=this}static{const e="function"==typeof Symbol&&Symbol.metadata?Object.create(y[Symbol.metadata]??null):void 0;c=[o({type:Boolean,reflect:!0})],m=[o({type:Boolean,reflect:!0})],d=[o({type:String,reflect:!0})],p=[o({type:Boolean})],h=[o({type:String})],t(this,null,c,{kind:"accessor",name:"open",static:!1,private:!1,access:{has:t=>"open"in t,get:t=>t.open,set:(t,e)=>{t.open=e}},metadata:e},b,v),t(this,null,m,{kind:"accessor",name:"mobile",static:!1,private:!1,access:{has:t=>"mobile"in t,get:t=>t.mobile,set:(t,e)=>{t.mobile=e}},metadata:e},f,_),t(this,null,d,{kind:"accessor",name:"type",static:!1,private:!1,access:{has:t=>"type"in t,get:t=>t.type,set:(t,e)=>{t.type=e}},metadata:e},x,w),t(this,null,p,{kind:"accessor",name:"right",static:!1,private:!1,access:{has:t=>"right"in t,get:t=>t.right,set:(t,e)=>{t.right=e}},metadata:e},j,k),t(this,null,h,{kind:"accessor",name:"id",static:!1,private:!1,access:{has:t=>"id"in t,get:t=>t.id,set:(t,e)=>{t.id=e}},metadata:e},S,z),t(null,s={value:l},g,{kind:"class",name:l.name,metadata:e},null,u),l=s.value,e&&Object.defineProperty(l,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}#t=e(this,b,void 0);get open(){return this.#t}set open(t){this.#t=t}#e=(e(this,v),e(this,f,void 0));get mobile(){return this.#e}set mobile(t){this.#e=t}#s=(e(this,_),e(this,x,void 0));get type(){return this.#s}set type(t){this.#s=t}#a=(e(this,w),e(this,j,void 0));get right(){return this.#a}set right(t){this.#a=t}#o=(e(this,k),e(this,S,void 0));get id(){return this.#o}set id(t){this.#o=t}connectedCallback(){document.addEventListener("custom-pane-close",(({detail:t})=>{this.id===t&&(this.open=!1)})),document.addEventListener("custom-pane-open",(({detail:t})=>{this.id===t&&(this.open=!0)}))}static styles=[n];render(){return i`
40
+ `;let l=(()=>{let s,l,c,m,d,p,h,g=[r("custom-drawer")],u=[],y=a,b=[],v=[],f=[],_=[],x=[],w=[],j=[],k=[],S=[],z=[];return class extends y{static{l=this}static{const e="function"==typeof Symbol&&Symbol.metadata?Object.create(y[Symbol.metadata]??null):void 0;c=[o({type:Boolean,reflect:!0})],m=[o({type:Boolean,reflect:!0})],d=[o({type:String,reflect:!0})],p=[o({type:Boolean})],h=[o({type:String})],t(this,null,c,{kind:"accessor",name:"open",static:!1,private:!1,access:{has:t=>"open"in t,get:t=>t.open,set:(t,e)=>{t.open=e}},metadata:e},b,v),t(this,null,m,{kind:"accessor",name:"mobile",static:!1,private:!1,access:{has:t=>"mobile"in t,get:t=>t.mobile,set:(t,e)=>{t.mobile=e}},metadata:e},f,_),t(this,null,d,{kind:"accessor",name:"type",static:!1,private:!1,access:{has:t=>"type"in t,get:t=>t.type,set:(t,e)=>{t.type=e}},metadata:e},x,w),t(this,null,p,{kind:"accessor",name:"right",static:!1,private:!1,access:{has:t=>"right"in t,get:t=>t.right,set:(t,e)=>{t.right=e}},metadata:e},j,k),t(this,null,h,{kind:"accessor",name:"id",static:!1,private:!1,access:{has:t=>"id"in t,get:t=>t.id,set:(t,e)=>{t.id=e}},metadata:e},S,z),t(null,s={value:l},g,{kind:"class",name:l.name,metadata:e},null,u),l=s.value,e&&Object.defineProperty(l,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}#t=e(this,b,void 0);get open(){return this.#t}set open(t){this.#t=t}#e=(e(this,v),e(this,f,void 0));get mobile(){return this.#e}set mobile(t){this.#e=t}#s=(e(this,_),e(this,x,void 0));get type(){return this.#s}set type(t){this.#s=t}#a=(e(this,w),e(this,j,void 0));get right(){return this.#a}set right(t){this.#a=t}#o=(e(this,k),e(this,S,void 0));get id(){return this.#o}set id(t){this.#o=t}firstRender(){document.addEventListener("custom-pane-close",(({detail:t})=>{this.id===t&&(this.open=!1)})),document.addEventListener("custom-pane-open",(({detail:t})=>{this.id===t&&(this.open=!0)}))}static styles=[n];render(){return i`
41
41
  <custom-pane .open=${this.open} .mobile=${this.mobile} .type=${this.type} .id=${this.id}>
42
42
  <slot name="headline" slot="headline"></slot>
43
43
  <slot name="menu-button" slot="menu-button"></slot>
@@ -36,9 +36,9 @@ import{_ as t,a as o}from"./tslib.es6-B87RQr7F.js";import{r as s,i as e,x as a}f
36
36
  --custom-icon-color: var(--md-sys-color-on-secondary-container);
37
37
  }
38
38
  `];render(){return a`
39
- <button label=${this.label}>
39
+ <button label=${this.label||this.icon}>
40
40
  <custom-elevation></custom-elevation>
41
- <slot name="icon"> <custom-icon .icon=${this.icon}></custom-icon></slot>
41
+ <slot name="icon"> <custom-icon .icon=${this.icon||this.label}></custom-icon></slot>
42
42
  <span class="label">${this.label}</span>
43
43
  <span class="hover"></span>
44
44
  </button>
@@ -0,0 +1 @@
1
+ import{_ as e,a as t}from"./tslib.es6-B87RQr7F.js";import{s as a,x as l}from"./dark-mode-m29sAj4H.js";import{e as r}from"./custom-element-B_TPyPQO.js";let s=(()=>{let s,o,m=[r("custom-pane")],n=[],c=a;return class extends c{static{o=this}static{const t="function"==typeof Symbol&&Symbol.metadata?Object.create(c[Symbol.metadata]??null):void 0;e(null,s={value:o},m,{kind:"class",name:o.name,metadata:t},null,n),o=s.value,t&&Object.defineProperty(o,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static styles=[];render(){return l`<input type="text" placeholder="Search for places..." />`}static{t(o,n)}},o})();export{s as CustomPlacesInput};
@@ -87,14 +87,15 @@ import{_ as e,a as t}from"./tslib.es6-B87RQr7F.js";import{i as s,s as o,r as a,x
87
87
  box-sizing: border-box;
88
88
  align-items: center;
89
89
  }
90
- `;let c=(()=>{let s,c,l,m,d,h,p,g,u=[r("custom-pane")],f=[],b=o,v=[],y=[],_=[],x=[],w=[],j=[],k=[],z=[],S=[],B=[],P=[],X=[];return class extends b{static{c=this}static{const t="function"==typeof Symbol&&Symbol.metadata?Object.create(b[Symbol.metadata]??null):void 0;l=[a({type:Boolean,reflect:!0})],m=[a({type:Boolean,reflect:!0})],d=[a({type:String,reflect:!0})],h=[a({type:Boolean,reflect:!0})],p=[a({type:Boolean,reflect:!0})],g=[a({type:String})],e(this,null,l,{kind:"accessor",name:"open",static:!1,private:!1,access:{has:e=>"open"in e,get:e=>e.open,set:(e,t)=>{e.open=t}},metadata:t},v,y),e(this,null,m,{kind:"accessor",name:"mobile",static:!1,private:!1,access:{has:e=>"mobile"in e,get:e=>e.mobile,set:(e,t)=>{e.mobile=t}},metadata:t},_,x),e(this,null,d,{kind:"accessor",name:"type",static:!1,private:!1,access:{has:e=>"type"in e,get:e=>e.type,set:(e,t)=>{e.type=t}},metadata:t},w,j),e(this,null,h,{kind:"accessor",name:"left",static:!1,private:!1,access:{has:e=>"left"in e,get:e=>e.left,set:(e,t)=>{e.left=t}},metadata:t},k,z),e(this,null,p,{kind:"accessor",name:"right",static:!1,private:!1,access:{has:e=>"right"in e,get:e=>e.right,set:(e,t)=>{e.right=t}},metadata:t},S,B),e(this,null,g,{kind:"accessor",name:"id",static:!1,private:!1,access:{has:e=>"id"in e,get:e=>e.id,set:(e,t)=>{e.id=t}},metadata:t},P,X),e(null,s={value:c},u,{kind:"class",name:c.name,metadata:t},null,f),c=s.value,t&&Object.defineProperty(c,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}#e=t(this,v,!1);get open(){return this.#e}set open(e){this.#e=e}#t=(t(this,y),t(this,_,!1));get mobile(){return this.#t}set mobile(e){this.#t=e}#s=(t(this,x),t(this,w,void 0));get type(){return this.#s}set type(e){this.#s=e}#o=(t(this,j),t(this,k,!0));get left(){return this.#o}set left(e){this.#o=e}#a=(t(this,z),t(this,S,!1));get right(){return this.#a}set right(e){this.#a=e}#i=(t(this,B),t(this,P,void 0));get id(){return this.#i}set id(e){this.#i=e}closePane(e){e.stopPropagation(),this.open=!1,document.dispatchEvent(new CustomEvent("custom-pane-close",{detail:this.id||""+(this.left?"left":"right")}))}static styles=[n];render(){return i`
90
+ `;let c=(()=>{let s,c,l,m,d,h,p,g,u,f=[r("custom-pane")],_=[],v=o,b=[],y=[],x=[],w=[],k=[],j=[],z=[],S=[],B=[],P=[],X=[],$=[],E=[],O=[];return class extends v{static{c=this}static{const t="function"==typeof Symbol&&Symbol.metadata?Object.create(v[Symbol.metadata]??null):void 0;l=[a({type:Boolean,reflect:!0})],m=[a({type:Boolean,reflect:!0})],d=[a({type:String,reflect:!0})],h=[a({type:Boolean,reflect:!0})],p=[a({type:Boolean,reflect:!0})],g=[a({type:String})],u=[a({type:String})],e(this,null,l,{kind:"accessor",name:"open",static:!1,private:!1,access:{has:e=>"open"in e,get:e=>e.open,set:(e,t)=>{e.open=t}},metadata:t},b,y),e(this,null,m,{kind:"accessor",name:"mobile",static:!1,private:!1,access:{has:e=>"mobile"in e,get:e=>e.mobile,set:(e,t)=>{e.mobile=t}},metadata:t},x,w),e(this,null,d,{kind:"accessor",name:"type",static:!1,private:!1,access:{has:e=>"type"in e,get:e=>e.type,set:(e,t)=>{e.type=t}},metadata:t},k,j),e(this,null,h,{kind:"accessor",name:"left",static:!1,private:!1,access:{has:e=>"left"in e,get:e=>e.left,set:(e,t)=>{e.left=t}},metadata:t},z,S),e(this,null,p,{kind:"accessor",name:"right",static:!1,private:!1,access:{has:e=>"right"in e,get:e=>e.right,set:(e,t)=>{e.right=t}},metadata:t},B,P),e(this,null,g,{kind:"accessor",name:"id",static:!1,private:!1,access:{has:e=>"id"in e,get:e=>e.id,set:(e,t)=>{e.id=t}},metadata:t},X,$),e(this,null,u,{kind:"accessor",name:"icon",static:!1,private:!1,access:{has:e=>"icon"in e,get:e=>e.icon,set:(e,t)=>{e.icon=t}},metadata:t},E,O),e(null,s={value:c},f,{kind:"class",name:c.name,metadata:t},null,_),c=s.value,t&&Object.defineProperty(c,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}#e=t(this,b,!1);get open(){return this.#e}set open(e){this.#e=e}#t=(t(this,y),t(this,x,!1));get mobile(){return this.#t}set mobile(e){this.#t=e}#s=(t(this,w),t(this,k,void 0));get type(){return this.#s}set type(e){this.#s=e}#o=(t(this,j),t(this,z,!0));get left(){return this.#o}set left(e){this.#o=e}#a=(t(this,S),t(this,B,!1));get right(){return this.#a}set right(e){this.#a=e}#i=(t(this,P),t(this,X,void 0));get id(){return this.#i}set id(e){this.#i=e}#r=(t(this,$),t(this,E,void 0));get icon(){return this.#r}set icon(e){this.#r=e}closePane(e){e.stopPropagation(),this.open=!1,document.dispatchEvent(new CustomEvent("custom-pane-close",{detail:this.id||""+(this.left?"left":"right")}))}static styles=[n];render(){return i`
91
91
  <custom-elevation></custom-elevation>
92
92
  <aside>
93
93
  <slot name="header">
94
94
  <flex-row center>
95
95
  <slot name="headline"></slot>
96
96
  <flex-it></flex-it>
97
- <custom-icon-button @click=${e=>this.closePane(e)} .id=${this.id} icon="menu_open">
97
+
98
+ <custom-icon-button @click=${e=>this.closePane(e)} .id=${this.id} .icon=${this.icon||"menu_open"}>
98
99
  </custom-icon-button>
99
100
  </flex-row>
100
101
  </slot>
@@ -105,4 +106,4 @@ import{_ as e,a as t}from"./tslib.es6-B87RQr7F.js";import{i as s,s as o,r as a,x
105
106
  <slot name="footer"></slot>
106
107
  </flex-row>
107
108
  </aside>
108
- `}constructor(){super(...arguments),t(this,X)}static{t(c,f)}},c})();export{c as CustomPane};
109
+ `}constructor(){super(...arguments),t(this,O)}static{t(c,_)}},c})();export{c as CustomPane};
@@ -171,6 +171,7 @@ let DemoShell = (() => {
171
171
  <custom-drawer-item route="toggle">toggle</custom-drawer-item>
172
172
  <custom-drawer-item route="toggle-button">toggle-button</custom-drawer-item>
173
173
  <custom-drawer-item route="time-picker">time-picker</custom-drawer-item>
174
+ <custom-drawer-item route="places-input">places-input</custom-drawer-item>
174
175
  </custom-selector>
175
176
  </flex-column>
176
177
 
@@ -639,6 +640,10 @@ let DemoShell = (() => {
639
640
  </demo-section>
640
641
  </custom-pages>
641
642
  </flex-column>
643
+
644
+ <demo-section route="places-input">
645
+ <places-input placeholder="place"> </places-input>
646
+ </demo-section>
642
647
  </custom-drawer-layout>
643
648
  <!-- </custom-root> -->
644
649
  <!-- </flex-row> -->
package/exports/demo.js CHANGED
@@ -79,6 +79,8 @@ let DemoShell = (() => {
79
79
  <custom-drawer-item route="list-item">list-item</custom-drawer-item>
80
80
  <custom-drawer-item route="toggle">toggle</custom-drawer-item>
81
81
  <custom-drawer-item route="toggle-button">toggle-button</custom-drawer-item>
82
+
83
+ <custom-drawer-item route="places-input">places-input</custom-drawer-item>
82
84
  </custom-selector>
83
85
  </flex-column>
84
86
 
@@ -1,9 +1,9 @@
1
1
  import { LiteElement } from '@vandeurenglenn/lite';
2
2
  import '../button/icon-button.js';
3
3
  export declare class CustomDrawerButton extends LiteElement {
4
- accessor mobile: boolean;
5
4
  accessor drawerOpen: boolean;
6
5
  accessor id: string;
6
+ accessor label: string;
7
7
  openPane(): void;
8
8
  static styles: import("lit").CSSResult[];
9
9
  render(): import("lit-html").TemplateResult<1>;
@@ -8,7 +8,7 @@ export declare class CustomDrawer extends LiteElement {
8
8
  accessor type: 'modal' | undefined;
9
9
  accessor right: boolean;
10
10
  accessor id: string;
11
- connectedCallback(): void;
12
- static styles?: import("lit").CSSResultOrNative[];
11
+ firstRender(): void;
12
+ static styles: import("lit").CSSResultOrNative[];
13
13
  render(): import("lit-html").TemplateResult<1>;
14
14
  }
@@ -13,38 +13,38 @@ let CustomDrawerButton = (() => {
13
13
  let _classExtraInitializers = [];
14
14
  let _classThis;
15
15
  let _classSuper = LiteElement;
16
- let _mobile_decorators;
17
- let _mobile_initializers = [];
18
- let _mobile_extraInitializers = [];
19
16
  let _drawerOpen_decorators;
20
17
  let _drawerOpen_initializers = [];
21
18
  let _drawerOpen_extraInitializers = [];
22
19
  let _id_decorators;
23
20
  let _id_initializers = [];
24
21
  let _id_extraInitializers = [];
22
+ let _label_decorators;
23
+ let _label_initializers = [];
24
+ let _label_extraInitializers = [];
25
25
  (class extends _classSuper {
26
26
  static { _classThis = this; }
27
27
  static {
28
28
  const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
29
- _mobile_decorators = [property({ type: Boolean, reflect: true })];
30
29
  _drawerOpen_decorators = [property({ type: Boolean, reflect: true, attribute: 'drawer-open' })];
31
30
  _id_decorators = [property()];
32
- __esDecorate(this, null, _mobile_decorators, { kind: "accessor", name: "mobile", static: false, private: false, access: { has: obj => "mobile" in obj, get: obj => obj.mobile, set: (obj, value) => { obj.mobile = value; } }, metadata: _metadata }, _mobile_initializers, _mobile_extraInitializers);
31
+ _label_decorators = [property({ type: String, reflect: true })];
33
32
  __esDecorate(this, null, _drawerOpen_decorators, { kind: "accessor", name: "drawerOpen", static: false, private: false, access: { has: obj => "drawerOpen" in obj, get: obj => obj.drawerOpen, set: (obj, value) => { obj.drawerOpen = value; } }, metadata: _metadata }, _drawerOpen_initializers, _drawerOpen_extraInitializers);
34
33
  __esDecorate(this, null, _id_decorators, { kind: "accessor", name: "id", static: false, private: false, access: { has: obj => "id" in obj, get: obj => obj.id, set: (obj, value) => { obj.id = value; } }, metadata: _metadata }, _id_initializers, _id_extraInitializers);
34
+ __esDecorate(this, null, _label_decorators, { kind: "accessor", name: "label", static: false, private: false, access: { has: obj => "label" in obj, get: obj => obj.label, set: (obj, value) => { obj.label = value; } }, metadata: _metadata }, _label_initializers, _label_extraInitializers);
35
35
  __esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
36
36
  _classThis = _classDescriptor.value;
37
37
  if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
38
38
  }
39
- #mobile_accessor_storage = __runInitializers(this, _mobile_initializers, false);
40
- get mobile() { return this.#mobile_accessor_storage; }
41
- set mobile(value) { this.#mobile_accessor_storage = value; }
42
- #drawerOpen_accessor_storage = (__runInitializers(this, _mobile_extraInitializers), __runInitializers(this, _drawerOpen_initializers, void 0));
39
+ #drawerOpen_accessor_storage = __runInitializers(this, _drawerOpen_initializers, void 0);
43
40
  get drawerOpen() { return this.#drawerOpen_accessor_storage; }
44
41
  set drawerOpen(value) { this.#drawerOpen_accessor_storage = value; }
45
42
  #id_accessor_storage = (__runInitializers(this, _drawerOpen_extraInitializers), __runInitializers(this, _id_initializers, void 0));
46
43
  get id() { return this.#id_accessor_storage; }
47
44
  set id(value) { this.#id_accessor_storage = value; }
45
+ #label_accessor_storage = (__runInitializers(this, _id_extraInitializers), __runInitializers(this, _label_initializers, 'menu'));
46
+ get label() { return this.#label_accessor_storage; }
47
+ set label(value) { this.#label_accessor_storage = value; }
48
48
  openPane() {
49
49
  document.dispatchEvent(new CustomEvent('custom-pane-open', { detail: this.id }));
50
50
  }
@@ -65,11 +65,13 @@ let CustomDrawerButton = (() => {
65
65
  `
66
66
  ];
67
67
  render() {
68
- return html ` <custom-icon-button @click=${() => this.openPane()} icon="menu"> </custom-icon-button> `;
68
+ return html `
69
+ <custom-icon-button @click=${() => this.openPane()} label="Open drawer" icon="menu"> </custom-icon-button>
70
+ `;
69
71
  }
70
72
  constructor() {
71
73
  super(...arguments);
72
- __runInitializers(this, _id_extraInitializers);
74
+ __runInitializers(this, _label_extraInitializers);
73
75
  }
74
76
  static {
75
77
  __runInitializers(_classThis, _classExtraInitializers);
package/exports/drawer.js CHANGED
@@ -64,7 +64,7 @@ let CustomDrawer = (() => {
64
64
  #id_accessor_storage = (__runInitializers(this, _right_extraInitializers), __runInitializers(this, _id_initializers, void 0));
65
65
  get id() { return this.#id_accessor_storage; }
66
66
  set id(value) { this.#id_accessor_storage = value; }
67
- connectedCallback() {
67
+ firstRender() {
68
68
  document.addEventListener('custom-pane-close', ({ detail }) => {
69
69
  if (this.id === detail)
70
70
  this.open = false;
@@ -71,9 +71,9 @@ let CustomIconButton = (() => {
71
71
  ];
72
72
  render() {
73
73
  return html `
74
- <button label=${this.label}>
74
+ <button label=${this.label || this.icon}>
75
75
  <custom-elevation></custom-elevation>
76
- <slot name="icon"> <custom-icon .icon=${this.icon}></custom-icon></slot>
76
+ <slot name="icon"> <custom-icon .icon=${this.icon || this.label}></custom-icon></slot>
77
77
  <span class="label">${this.label}</span>
78
78
  <span class="hover"></span>
79
79
  </button>
@@ -0,0 +1,29 @@
1
+ import { _ as __esDecorate, a as __runInitializers } from './tslib.es6-Cg9lAhfj.js';
2
+ import { customElement, LiteElement, html } from '@vandeurenglenn/lite';
3
+
4
+ let CustomPlacesInput = (() => {
5
+ let _classDecorators = [customElement('custom-pane')];
6
+ let _classDescriptor;
7
+ let _classExtraInitializers = [];
8
+ let _classThis;
9
+ let _classSuper = LiteElement;
10
+ (class extends _classSuper {
11
+ static { _classThis = this; }
12
+ static {
13
+ const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
14
+ __esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
15
+ _classThis = _classDescriptor.value;
16
+ if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
17
+ }
18
+ static styles = [];
19
+ render() {
20
+ return html `<input type="text" placeholder="Search for places..." />`;
21
+ }
22
+ static {
23
+ __runInitializers(_classThis, _classExtraInitializers);
24
+ }
25
+ });
26
+ return _classThis;
27
+ })();
28
+
29
+ export { CustomPlacesInput };
@@ -9,6 +9,7 @@ export declare class CustomPane extends LiteElement {
9
9
  accessor left: boolean;
10
10
  accessor right: boolean;
11
11
  accessor id: string;
12
+ accessor icon: string;
12
13
  closePane(event: any): void;
13
14
  static styles: import("lit").CSSResultOrNative[];
14
15
  render(): import("lit-html").TemplateResult<1>;
package/exports/pane.js CHANGED
@@ -32,6 +32,9 @@ let CustomPane = (() => {
32
32
  let _id_decorators;
33
33
  let _id_initializers = [];
34
34
  let _id_extraInitializers = [];
35
+ let _icon_decorators;
36
+ let _icon_initializers = [];
37
+ let _icon_extraInitializers = [];
35
38
  (class extends _classSuper {
36
39
  static { _classThis = this; }
37
40
  static {
@@ -42,12 +45,14 @@ let CustomPane = (() => {
42
45
  _left_decorators = [property({ type: Boolean, reflect: true })];
43
46
  _right_decorators = [property({ type: Boolean, reflect: true })];
44
47
  _id_decorators = [property({ type: String })];
48
+ _icon_decorators = [property({ type: String })];
45
49
  __esDecorate(this, null, _open_decorators, { kind: "accessor", name: "open", static: false, private: false, access: { has: obj => "open" in obj, get: obj => obj.open, set: (obj, value) => { obj.open = value; } }, metadata: _metadata }, _open_initializers, _open_extraInitializers);
46
50
  __esDecorate(this, null, _mobile_decorators, { kind: "accessor", name: "mobile", static: false, private: false, access: { has: obj => "mobile" in obj, get: obj => obj.mobile, set: (obj, value) => { obj.mobile = value; } }, metadata: _metadata }, _mobile_initializers, _mobile_extraInitializers);
47
51
  __esDecorate(this, null, _type_decorators, { kind: "accessor", name: "type", static: false, private: false, access: { has: obj => "type" in obj, get: obj => obj.type, set: (obj, value) => { obj.type = value; } }, metadata: _metadata }, _type_initializers, _type_extraInitializers);
48
52
  __esDecorate(this, null, _left_decorators, { kind: "accessor", name: "left", static: false, private: false, access: { has: obj => "left" in obj, get: obj => obj.left, set: (obj, value) => { obj.left = value; } }, metadata: _metadata }, _left_initializers, _left_extraInitializers);
49
53
  __esDecorate(this, null, _right_decorators, { kind: "accessor", name: "right", static: false, private: false, access: { has: obj => "right" in obj, get: obj => obj.right, set: (obj, value) => { obj.right = value; } }, metadata: _metadata }, _right_initializers, _right_extraInitializers);
50
54
  __esDecorate(this, null, _id_decorators, { kind: "accessor", name: "id", static: false, private: false, access: { has: obj => "id" in obj, get: obj => obj.id, set: (obj, value) => { obj.id = value; } }, metadata: _metadata }, _id_initializers, _id_extraInitializers);
55
+ __esDecorate(this, null, _icon_decorators, { kind: "accessor", name: "icon", static: false, private: false, access: { has: obj => "icon" in obj, get: obj => obj.icon, set: (obj, value) => { obj.icon = value; } }, metadata: _metadata }, _icon_initializers, _icon_extraInitializers);
51
56
  __esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
52
57
  _classThis = _classDescriptor.value;
53
58
  if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
@@ -70,6 +75,9 @@ let CustomPane = (() => {
70
75
  #id_accessor_storage = (__runInitializers(this, _right_extraInitializers), __runInitializers(this, _id_initializers, void 0));
71
76
  get id() { return this.#id_accessor_storage; }
72
77
  set id(value) { this.#id_accessor_storage = value; }
78
+ #icon_accessor_storage = (__runInitializers(this, _id_extraInitializers), __runInitializers(this, _icon_initializers, void 0));
79
+ get icon() { return this.#icon_accessor_storage; }
80
+ set icon(value) { this.#icon_accessor_storage = value; }
73
81
  closePane(event) {
74
82
  event.stopPropagation();
75
83
  this.open = false;
@@ -84,7 +92,8 @@ let CustomPane = (() => {
84
92
  <flex-row center>
85
93
  <slot name="headline"></slot>
86
94
  <flex-it></flex-it>
87
- <custom-icon-button @click=${(e) => this.closePane(e)} .id=${this.id} icon="menu_open">
95
+
96
+ <custom-icon-button @click=${(e) => this.closePane(e)} .id=${this.id} .icon=${this.icon || 'menu_open'}>
88
97
  </custom-icon-button>
89
98
  </flex-row>
90
99
  </slot>
@@ -99,7 +108,7 @@ let CustomPane = (() => {
99
108
  }
100
109
  constructor() {
101
110
  super(...arguments);
102
- __runInitializers(this, _id_extraInitializers);
111
+ __runInitializers(this, _icon_extraInitializers);
103
112
  }
104
113
  static {
105
114
  __runInitializers(_classThis, _classExtraInitializers);
@@ -0,0 +1,5 @@
1
+ import { LiteElement } from '@vandeurenglenn/lite';
2
+ export declare class CustomPlacesInput extends LiteElement {
3
+ static styles: any[];
4
+ render(): import("lit-html").TemplateResult<1>;
5
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vandeurenglenn/lite-elements",
3
- "version": "0.3.81",
3
+ "version": "0.3.83",
4
4
  "description": "set of lite elements following Material Design 3 spec",
5
5
  "type": "module",
6
6
  "scripts": {