rettangoli-ui 0.0.8-rc1 → 0.0.9-rc1

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.
@@ -0,0 +1,650 @@
1
+ var{isArray:pt}=Array,{getPrototypeOf:Nt,getOwnPropertyDescriptor:Rt}=Object,C=[],gt=()=>document.createRange(),E=(e,t,o)=>(e.set(t,o),o),Et=(e,t)=>t.reduceRight(zt,e),zt=(e,t)=>e.childNodes[t],{setPrototypeOf:Lt}=Object,M,ut=(e,t,o)=>(M||(M=gt()),o?M.setStartAfter(e):M.setStartBefore(e),M.setEndAfter(t),M.deleteContents(),e),X=({firstChild:e,lastChild:t},o)=>ut(e,t,o),ft=!1,G=(e,t)=>ft&&e.nodeType===11?1/t<0?t?X(e,!0):e.lastChild:t?e.valueOf():e.firstChild:e,lt=e=>document.createComment(e),Y=class extends(t=>{function o(s){return Lt(s,new.target.prototype)}return o.prototype=t.prototype,o})(DocumentFragment){#e=lt("<>");#o=lt("</>");#t=C;constructor(t){super(t),this.replaceChildren(this.#e,...t.childNodes,this.#o),ft=!0}get firstChild(){return this.#e}get lastChild(){return this.#o}get parentNode(){return this.#e.parentNode}remove(){X(this,!1)}replaceWith(t){X(this,!0).replaceWith(t)}valueOf(){let{parentNode:t}=this;if(t===this)this.#t===C&&(this.#t=[...this.childNodes]);else{if(t){let{firstChild:o,lastChild:s}=this;for(this.#t=[o];o!==s;)this.#t.push(o=o.nextSibling)}this.replaceChildren(...this.#t)}return this}},mt=(e,t,o)=>e.setAttribute(t,o),P=(e,t)=>e.removeAttribute(t),V,Vt=(e,t,o)=>{o=o.slice(1),V||(V=new WeakMap);let s=V.get(e)||E(V,e,{}),r=s[o];return r&&r[0]&&e.removeEventListener(o,...r),r=pt(t)?t:[t,!1],s[o]=r,r[0]&&e.addEventListener(o,...r),t},z=(e,t)=>{let{t:o,n:s}=e,r=!1;switch(typeof t){case"object":if(t!==null){(s||o).replaceWith(e.n=t.valueOf());break}case"undefined":r=!0;default:o.data=r?"":t,s&&(e.n=null,s.replaceWith(o))}return t},B=(e,t,o)=>e[o]=t,Ht=(e,t,o)=>B(e,t,o.slice(1)),tt=(e,t,o)=>t==null?(P(e,o),t):B(e,t,o),bt=(e,t)=>(typeof t=="function"?t(e):t.current=e,t),Z=(e,t,o)=>(t==null?P(e,o):mt(e,o,t),t),Dt=(e,t,o)=>(e.toggleAttribute(o.slice(1),t),t),D=(e,t,o)=>{let{length:s}=t;if(e.data=`[${s}]`,s)return((r,n,a,i,d)=>{let u=a.length,l=n.length,c=u,h=0,p=0,f=null;for(;h<l||p<c;)if(l===h){let b=c<u?p?i(a[p-1],-0).nextSibling:i(a[c],0):d;for(;p<c;)r.insertBefore(i(a[p++],1),b)}else if(c===p)for(;h<l;)f&&f.has(n[h])||r.removeChild(i(n[h],-1)),h++;else if(n[h]===a[p])h++,p++;else if(n[l-1]===a[c-1])l--,c--;else if(n[h]===a[c-1]&&a[p]===n[l-1]){let b=i(n[--l],-0).nextSibling;r.insertBefore(i(a[p++],1),i(n[h++],-0).nextSibling),r.insertBefore(i(a[--c],1),b),n[l]=a[c]}else{if(!f){f=new Map;let b=p;for(;b<c;)f.set(a[b],b++)}if(f.has(n[h])){let b=f.get(n[h]);if(p<b&&b<c){let S=h,A=1;for(;++S<l&&S<c&&f.get(n[S])===b+A;)A++;if(A>b-p){let Q=i(n[h],0);for(;p<b;)r.insertBefore(i(a[p++],1),Q)}else r.replaceChild(i(a[p++],1),i(n[h++],-1))}else h++}else r.removeChild(i(n[h++],-1))}return a})(e.parentNode,o,t,G,e);switch(o.length){case 1:o[0].remove();case 0:break;default:ut(G(o[0],0),G(o.at(-1),-0),!1)}return C},Pt=new Map([["aria",(e,t)=>{for(let o in t){let s=t[o],r=o==="role"?o:`aria-${o}`;s==null?P(e,r):mt(e,r,s)}return t}],["class",(e,t)=>tt(e,t,t==null?"class":"className")],["data",(e,t)=>{let{dataset:o}=e;for(let s in t)t[s]==null?delete o[s]:o[s]=t[s];return t}],["ref",bt],["style",(e,t)=>t==null?tt(e,t,"style"):B(e.style,t,"cssText")]]),Bt=(e,t,o)=>{switch(t[0]){case".":return Ht;case"?":return Dt;case"@":return Vt;default:return o||"ownerSVGElement"in e?t==="ref"?bt:Z:Pt.get(t)||(t in e?t.startsWith("on")?B:((s,r)=>{let n;do n=Rt(s,r);while(!n&&(s=Nt(s)));return n})(e,t)?.set?tt:Z:Z)}},Ut=(e,t)=>(e.textContent=t??"",t),R=(e,t,o)=>({a:e,b:t,c:o}),W=()=>R(null,null,C),vt=e=>(t,o)=>{let{a:s,b:r,c:n}=e(t,o),a=document.importNode(s,!0),i=C;if(r!==C){i=[];for(let h,p,f=0;f<r.length;f++){let{a:b,b:S,c:A}=r[f],Q=b===p?h:h=Et(a,p=b);i[f]=(d=S,u=Q,l=A,c=S===D?[]:S===z?W():null,{v:C,u:d,t:u,n:l,c})}}var d,u,l,c;return((h,p)=>({b:h,c:p}))(n?a.firstChild:new Y(a),i)},Ft=/^(?:plaintext|script|style|textarea|title|xmp)$/i,It=/^(?:area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)$/i,Qt=/<([a-zA-Z0-9]+[a-zA-Z0-9:._-]*)([^>]*?)(\/?)>/g,Gt=/([^\s\\>"'=]+)\s*=\s*(['"]?)\x01/g,Zt=/[\x01\x02]/g,q,J,H=document.createElement("template"),qt=(e,t)=>{if(t)return q||(q=document.createElementNS("http://www.w3.org/2000/svg","svg"),J=gt(),J.selectNodeContents(q)),J.createContextualFragment(e);H.innerHTML=e;let{content:o}=H;return H=H.cloneNode(!1),o},K=e=>{let t=[],o;for(;o=e.parentNode;)t.push(t.indexOf.call(o.childNodes,e)),e=o;return t},ht=()=>document.createTextNode(""),Jt=(e,t,o)=>{let s=qt(((d,u,l)=>{let c=0;return d.join("").trim().replace(Qt,(h,p,f,b)=>`<${p}${f.replace(Gt,"=$2$1").trimEnd()}${b?l||It.test(p)?" /":`></${p}`:""}>`).replace(Zt,h=>h===""?`<!--${u+c++}-->`:u+c++)})(e,N,o),o),{length:r}=e,n=C;if(r>1){let d=[],u=document.createTreeWalker(s,129),l=0,c=`${N}${l++}`;for(n=[];l<r;){let h=u.nextNode();if(h.nodeType===8){if(h.data===c){let p=pt(t[l-1])?D:z;p===z&&d.push(h),n.push(R(K(h),p,null)),c=`${N}${l++}`}}else{let p;for(;h.hasAttribute(c);){p||(p=K(h));let f=h.getAttribute(c);n.push(R(p,Bt(h,f,o),f)),P(h,c),c=`${N}${l++}`}!o&&Ft.test(h.localName)&&h.textContent.trim()===`<!--${c}-->`&&(n.push(R(p||K(h),Ut,null)),c=`${N}${l++}`)}}for(l=0;l<d.length;l++)d[l].replaceWith(ht())}let{childNodes:a}=s,{length:i}=a;return i<1?(i=1,s.appendChild(ht())):i===1&&r!==1&&a[0].nodeType!==1&&(i=0),E(yt,e,R(s,n,i===1))},yt=new WeakMap,N="is\xB5",wt=e=>(t,o)=>yt.get(t)||Jt(t,o,e),Kt=vt(wt(!1)),Xt=vt(wt(!0)),et=(e,{s:t,t:o,v:s})=>{if(e.a!==o){let{b:r,c:n}=(t?Xt:Kt)(o,s);e.a=o,e.b=r,e.c=n}for(let{c:r}=e,n=0;n<r.length;n++){let a=s[n],i=r[n];switch(i.u){case D:i.v=D(i.t,Yt(i.c,a),i.v);break;case z:let d=a instanceof j?et(i.c||(i.c=W()),a):(i.c=null,a);d!==i.v&&(i.v=z(i,d));break;default:a!==i.v&&(i.v=i.u(i.t,a,i.n,i.v))}}return e.b},Yt=(e,t)=>{let o=0,{length:s}=t;for(s<e.length&&e.splice(s);o<s;o++){let r=t[o];r instanceof j?t[o]=et(e[o]||(e[o]=W()),r):e[o]=null}return t},j=class{constructor(t,o,s){this.s=t,this.t=o,this.v=s}toDOM(t=W()){return et(t,this)}};var xt=e=>(t,...o)=>new j(e,t,o),x=xt(!1),xe=xt(!0),ct=new WeakMap,y=(e,t)=>((o,s)=>{let r=ct.get(o)||E(ct,o,W()),{b:n}=r,a=typeof s=="function"?s():s,i=a instanceof j?a.toDOM(r):a;return n!==i&&o.replaceChildren((r.b=i).valueOf()),o})(e,t),dt=new WeakMap,St=e=>(t,o)=>{let s=dt.get(t)||E(dt,t,new Map);return s.get(o)||E(s,o,function(r,...n){return new j(e,r,n).toDOM(this)}.bind(W()))},Se=St(!1),$e=St(!0);function m(e,...t){let o="";return e.forEach((s,r)=>{o+=s+(t[r]||"")}),o}var $t={default:void 0,s:"@media only screen and (max-width: 640px)"},w=(e,t,o={})=>{let s="";for(let[r,n]of Object.entries($t)){r!=="default"&&(s+=`${n} {`);for(let[a,i]of Object.entries(t)){let d=o[a]?` ${o[a]} `:" ";for(let[u,l]of Object.entries(i)){let c=e[a],h=l.startsWith("--")?`var(${l})`:l,p=r==="default"?a:`${r}-${a}`,f=r==="default"?`h-${a}`:`${r}-h-${a}`;if(c){let S=c.split(" ").map(A=>`${A}: ${h};`).join(" ");s+=`
2
+ :host([${p}="${u}"])${d}{
3
+ ${S}
4
+ }
5
+ :host([${f}="${u}"]:hover)${d}{
6
+ ${S}
7
+ }
8
+ `}else s+=`
9
+ :host([${p}="${u}"])${d}{
10
+ ${l}
11
+ }
12
+ :host([${f}="${u}"]:hover)${d}{
13
+ ${l}
14
+ }
15
+ `}}r!=="default"&&(s+="}")}return s};function te(e){if(e===null||e.includes("/"))return!1;let t=String(e);return/[0-9]$/.test(t)}var ee=e=>/%$/.test(e),v=e=>{if(e!==void 0)return ee(e)?e:te(e)?`${e}px`:e},g={xs:"--spacing-xs",s:"--spacing-s",m:"--spacing-m",l:"--spacing-l",xl:"--spacing-xl"};function O(e){let t="";for(let[o,s]of Object.entries($t)){o!=="default"&&(t+=`${s} {
16
+ `);let r="";for(let[n,a]of Object.entries(e[o]))a!=null&&(r+=`${n}: ${a};
17
+ `);t+=`:host {
18
+ ${r.trim()}
19
+ }
20
+ `,o!=="default"&&(t+=`}
21
+ `)}return t}var k=m`
22
+ :host([flex="0"]) {
23
+ flex: 0;
24
+ }
25
+ :host([flex="1"]) {
26
+ flex: 1;
27
+ }
28
+ :host([flex="2"]) {
29
+ flex: 2;
30
+ }
31
+ :host([flex="3"]) {
32
+ flex: 3;
33
+ }
34
+ :host([flex="4"]) {
35
+ flex: 4;
36
+ }
37
+ :host([flex="5"]) {
38
+ flex: 5;
39
+ }
40
+ :host([flex="6"]) {
41
+ flex: 6;
42
+ }
43
+ :host([flex="7"]) {
44
+ flex: 7;
45
+ }
46
+ :host([flex="8"]) {
47
+ flex: 8;
48
+ }
49
+ :host([flex="9"]) {
50
+ flex: 9;
51
+ }
52
+ :host([flex="10"]) {
53
+ flex: 10;
54
+ }
55
+ :host([flex="11"]) {
56
+ flex: 11;
57
+ }
58
+ :host([flex="12"]) {
59
+ flex: 12;
60
+ }
61
+ `;var oe={mt:"margin-top",mr:"margin-right",mb:"margin-bottom",ml:"margin-left",m:"margin",mh:"margin-left margin-right",mv:"margin-top margin-bottom"},re={mt:g,mr:g,mb:g,ml:g,m:g,mh:g,mv:g},se={mt:"button",mr:"button",mb:"button",ml:"button",m:"button",mh:"button",mv:"button"},Ct=w(oe,re,se);var kt=new CSSStyleSheet;kt.replaceSync(m`
62
+ :host {
63
+ display: contents;
64
+ }
65
+ slot {
66
+ display: contents;
67
+ }
68
+
69
+ button {
70
+ border-style: solid;
71
+ padding: 0px;
72
+ font-size: var(--typography-body-s-font-size);
73
+ font-weight: var(--typography-body-s-font-weight);
74
+ line-height: var(--typography-body-s-line-height);
75
+ letter-spacing: var(--typography-body-s-letter-spacing);
76
+ }
77
+
78
+ button:hover {
79
+ cursor: pointer;
80
+ }
81
+
82
+ :host([t="ps"]) button,
83
+ :host([t="p"]) button,
84
+ :host([t="pl"]) button {
85
+ color: var(--color-on-primary);
86
+ border-color: var(--color-primary);
87
+ background-color: var(--color-primary);
88
+ }
89
+
90
+ :host([t="ps"]) button:hover,
91
+ :host([t="p"]) button:hover,
92
+ :host([t="pl"]) button:hover {
93
+ border-color: var(--color-primary-hover);
94
+ background-color: var(--color-primary-hover);
95
+ }
96
+
97
+ :host([t="ps"]) button:active,
98
+ :host([t="p"]) button:active,
99
+ :host([t="pl"]) button:active {
100
+ border-color: var(--color-primary-active);
101
+ background-color: var(--color-primary-active);
102
+ }
103
+
104
+ :host([t="ss"]) button,
105
+ :host([t="s"]) button,
106
+ :host([t="sl"]) button {
107
+ color: var(--color-on-secondary);
108
+ border-color: var(--color-secondary);
109
+ background-color: var(--color-secondary);
110
+ }
111
+
112
+ :host([t="ss"]) button:hover,
113
+ :host([t="s"]) button:hover,
114
+ :host([t="sl"]) button:hover {
115
+ background-color: var(--color-secondary-hover);
116
+ border-color: var(--color-secondary-hover);
117
+ }
118
+
119
+ :host([t="ss"]) button:active,
120
+ :host([t="s"]) button:active,
121
+ :host([t="sl"]) button:active {
122
+ background-color: var(--color-secondary-active);
123
+ border-color: var(--color-secondary-active);
124
+ }
125
+
126
+ :host([t="es"]) button,
127
+ :host([t="e"]) button,
128
+ :host([t="el"]) button {
129
+ color: var(--color-on-error);
130
+ border-color: var(--color-error);
131
+ background-color: var(--color-error);
132
+ }
133
+
134
+ :host([t="es"]) button:hover,
135
+ :host([t="e"]) button:hover,
136
+ :host([t="el"]) button:hover {
137
+ background-color: var(--color-error-hover);
138
+ border-color: var(--color-error-hover);
139
+ }
140
+
141
+ :host([t="es"]) button:active,
142
+ :host([t="e"]) button:active,
143
+ :host([t="el"]) button:active {
144
+ background-color: var(--color-error-active);
145
+ border-color: var(--color-error-active);
146
+ }
147
+
148
+ :host([t="ns"]) button,
149
+ :host([t="n"]) button,
150
+ :host([t="nl"]) button {
151
+ color: var(--color-on-surface);
152
+ border-color: var(--color-surface-container);
153
+ background-color: var(--color-surface-container);
154
+ }
155
+
156
+ :host([t="ns"]) button:hover,
157
+ :host([t="n"]) button:hover,
158
+ :host([t="nl"]) button:hover {
159
+ background-color: var(--color-surface-container-high);
160
+ border-color: var(--color-surface-container-high);
161
+ }
162
+
163
+ :host([t="ns"]) button:active,
164
+ :host([t="n"]) button:active,
165
+ :host([t="nl"]) button:active {
166
+ background-color: var(--color-surface-container-high);
167
+ border-color: var(--color-surface-container-high);
168
+ }
169
+
170
+ :host([t="ps"]) button,
171
+ :host([t="ss"]) button,
172
+ :host([t="es"]) button,
173
+ :host([t="ns"]) button {
174
+ height: var(--button-height-s);
175
+ padding-left: var(--button-padding-horizontal-s);
176
+ padding-right: var(--button-padding-horizontal-s);
177
+ border-radius: var(--button-border-radius-s);
178
+ }
179
+
180
+ :host([t="p"]) button,
181
+ :host([t="s"]) button,
182
+ :host([t="e"]) button,
183
+ :host([t="n"]) button {
184
+ height: var(--button-height-m);
185
+ padding-left: var(--button-padding-horizontal-m);
186
+ padding-right: var(--button-padding-horizontal-m);
187
+ border-radius: var(--button-border-radius-m);
188
+ }
189
+
190
+ :host([t="pl"]) button,
191
+ :host([t="sl"]) button,
192
+ :host([t="el"]) button,
193
+ :host([t="nl"]) button {
194
+ height: var(--button-height-l);
195
+ padding-left: var(--button-padding-horizontal-l);
196
+ padding-right: var(--button-padding-horizontal-l);
197
+ border-radius: var(--button-border-radius-l);
198
+ font-size: var(--typography-label-l-font-size);
199
+ font-weight: var(--typography-label-l-font-weight);
200
+ line-height: var(--typography-label-l-line-height);
201
+ letter-spacing: var(--typography-label-l-letter-spacing);
202
+ }
203
+ ${Ct}
204
+ ${k}
205
+ `);var ot=class extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[kt],y(this.shadow,this.render)}static get observedAttributes(){return["key","href","target","w","t"]}_buttonRef={};_assingRef=t=>{this._buttonRef.current=t;let o=v(this.getAttribute("w"));o==="f"?this._buttonRef.current.style.width="100%":o!=null&&(this._buttonRef.current.style.width=o)};attributeChangedCallback(t,o,s){if(!this._buttonRef.current)return;let r=v(this.getAttribute("w"));r==="f"?this._buttonRef.current.style.width="100%":r!=null&&(this._buttonRef.current.style.width=r,this._buttonRef.current.style.minWidth=r,this._buttonRef.current.style.maxWidth=r),y(this.shadow,this.render)}render=()=>this.getAttribute("href")?x`
206
+ <a
207
+ href=${this.getAttribute("href")}
208
+ target=${this.getAttribute("target")}
209
+ >
210
+ <button>
211
+ <slot></slot>
212
+ </button>
213
+ </a>
214
+ `:x`
215
+ <button ref=${this._assingRef}>
216
+ <slot></slot>
217
+ </button>
218
+ `},ne=ot;var U=m`
219
+
220
+ :host([d="h"]) {
221
+ flex-direction: row;
222
+ }
223
+ :host(:not([d])) {
224
+ flex-direction: column;
225
+ }
226
+ :host([d="h"]:not([ah])) {
227
+ justify-content: flex-start;
228
+ }
229
+ :host([d="h"][ah="c"]) {
230
+ justify-content: center;
231
+ /* align-content: center; */
232
+ }
233
+ :host([d="h"][ah="e"]) {
234
+ justify-content: flex-end;
235
+ }
236
+ :host([d="h"]:not([av])) {
237
+ align-items: flex-start;
238
+ }
239
+ :host([d="h"][av="c"]) {
240
+ align-items: center;
241
+ align-content: center;
242
+ }
243
+ :host([d="h"][av="e"]) {
244
+ align-items: flex-end;
245
+ align-content: flex-end;
246
+ }
247
+ :host(:not([d]):not([ah])) {
248
+ align-items: flex-start;
249
+ }
250
+ :host(:not([d])[ah="c"]) {
251
+ align-items: center;
252
+ align-content: center;
253
+ }
254
+ :host(:not([d])[ah="e"]) {
255
+ align-items: flex-end;
256
+ align-content: flex-end;
257
+ }
258
+ :host(:not([d]):not([av])) {
259
+ justify-content: flex-start;
260
+ }
261
+ :host(:not([d])[av="c"]) {
262
+ justify-content: center;
263
+ }
264
+ :host(:not([d])[av="e"]) {
265
+ justify-content: flex-end;
266
+ }
267
+ @media screen and (max-width: 640px) {
268
+ :host([s-d="v"]) {
269
+ flex-direction: column;
270
+ }
271
+ :host([s-d="h"]) {
272
+ flex-direction: row;
273
+ }
274
+ :host([s-d="h"][s-av="c"]) {
275
+ align-items: center;
276
+ align-content: center;
277
+ }
278
+ :host([s-d="v"][s-av="c"]) {
279
+ justify-content: center;
280
+ }
281
+ }
282
+ `;var ie={cur:"cursor"},ae={cur:{p:"pointer",m:"move",grab:"grab",grabbing:"grabbing"}},$=w(ie,ae);var F=m`
283
+ :host([sh]:not([sv])) {
284
+ overflow-x: scroll;
285
+ flex-wrap: nowrap;
286
+ }
287
+ :host([sv]:not([sh])) {
288
+ overflow-y: scroll;
289
+ flex-wrap: nowrap;
290
+ }
291
+ :host([sh][sv]) {
292
+ overflow: scroll;
293
+ flex-wrap: nowrap;
294
+ }
295
+ :host([overflow="hidden"]) {
296
+ overflow: hidden;
297
+ flex-wrap: nowrap;
298
+ }
299
+
300
+ `;var L={xs:"--border-width-xs",s:"--border-width-s",m:"--border-width-m",l:"--border-width-l",xl:"--border-width-xl"},le={pos:"position",shadow:"box-shadow",pt:"padding-top",pr:"padding-right",pb:"padding-bottom",pl:"padding-left",p:"padding",ph:"padding-left padding-right",pv:"padding-top padding-bottom",g:"gap",gv:"row-gap",gh:"column-gap",bw:"border-width",bwt:"border-top-width",bwr:"border-right-width",bwb:"border-bottom-width",bwl:"border-left-width",bc:"border-color",br:"border-radius"},he={bgc:{p:`
301
+ background-color: var(--color-primary);
302
+ color: var(--color-on-primary);
303
+ `,pc:`
304
+ background-color: var(--color-primary-container);
305
+ color: var(--color-on-primary-container);
306
+ `,s:`
307
+ background-color: var(--color-secondary);
308
+ color: var(--color-on-secondary);
309
+ `,sc:`
310
+ background-color: var(--color-secondary-container);
311
+ color: var(--color-on-secondary-container);
312
+ `,e:`
313
+ background-color: var(--color-error);
314
+ color: var(--color-on-error);
315
+ `,ec:`
316
+ background-color: var(--color-error-container);
317
+ color: var(--color-on-error-container);
318
+ `,su:`
319
+ background-color: var(--color-surface);
320
+ color: var(--color-on-surface);
321
+ `,sucl:`
322
+ background-color: var(--color-surface-container-low);
323
+ color: var(--color-on-surface);
324
+ `,suc:`
325
+ background-color: var(--color-surface-container);
326
+ color: var(--color-on-surface);
327
+ `,such:`
328
+ background-color: var(--color-surface-container-high);
329
+ color: var(--color-on-surface);
330
+ `,isu:`
331
+ background-color: var(--color-inverse-surface);
332
+ color: var(--color-inverse-on-surface);
333
+ `,o:`
334
+ background-color: var(--color-outline);
335
+ `,ov:`
336
+ background-color: var(--color-outline-variant);
337
+ `},pos:{rel:"relative",abs:"absolute",fix:"fixed"},cor:{full:`
338
+ top: 0;
339
+ right: 0;
340
+ bottom: 0;
341
+ left: 0;
342
+ height: 100%;
343
+ `,top:`
344
+ top: 0;
345
+ right: 0;
346
+ left: 0;
347
+ `,right:`
348
+ top: 0;
349
+ right: 0;
350
+ bottom: 0;
351
+ height: 100%;
352
+ `,bottom:`
353
+ right: 0;
354
+ bottom: 0;
355
+ left: 0;
356
+ `,left:`
357
+ bottom: 0;
358
+ left: 0;
359
+ top: 0;
360
+ height: 100%;
361
+ `},shadow:{s:"--shadow-s",m:"--shadow-m",l:"--shadow-l"},pt:g,pr:g,pb:g,pl:g,p:g,ph:g,pv:g,g,gv:g,gh:g,bw:L,bwt:L,bwr:L,bwb:L,bwl:L,bc:{p:"--color-primary",pc:"--color-primary-container",s:"--color-secondary",sc:"--color-secondary-container",e:"--color-error",ec:"--color-error-container",su:"--color-surface",sucl:"--color-surface-container-low",suc:"--color-surface-container",such:"--color-surface-container-high",isu:"--color-inverse-surface",o:"--color-outline",ov:"--color-outline-variant"},br:{xs:"--border-radius-xs",s:"--border-radius-s",m:"--border-radius-m",l:"--border-radius-l",xl:"--border-radius-xl",f:"50%"}},T=w(le,he);var ce={mt:"margin-top",mr:"margin-right",mb:"margin-bottom",ml:"margin-left",m:"margin",mh:"margin-left margin-right",mv:"margin-top margin-bottom"},de={mt:g,mr:g,mb:g,ml:g,m:g,mh:g,mv:g},_=w(ce,de);var _t=new CSSStyleSheet;_t.replaceSync(m`
362
+ slot {
363
+ display: contents;
364
+ }
365
+ :host([hidden]) {
366
+ display: none;
367
+ }
368
+ :host {
369
+ display: flex;
370
+ align-self: auto;
371
+ align-content: flex-start;
372
+ flex-wrap: wrap;
373
+ border-style: solid;
374
+ border-width: 0;
375
+ box-sizing: border-box;
376
+ }
377
+ :host([stretch]) {
378
+ align-self: stretch;
379
+ }
380
+ ${k}
381
+ ${F}
382
+ ${U}
383
+ ${_}
384
+ ${$}
385
+ ${T}
386
+ `);var rt=class extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[_t],y(this.shadow,this.render)}static get observedAttributes(){return["key","wh","w","h","hidden","s-w","s-h","s-d"]}_styles={default:{},s:{}};attributeChangedCallback(t,o,s){["default","s"].forEach(r=>{let n=c=>`${r==="default"?"":`${r}-`}${c}`,a=this.getAttribute(n("wh")),i=v(a===null?this.getAttribute(n("w")):a),d=v(a===null?this.getAttribute(n("h")):a),u=this.getAttribute(n("o")),l=this.getAttribute(n("z"));l!==null&&(this._styles[r]["z-index"]=l),u!==null&&(this._styles[r].opacity=u),i==="f"?this._styles[r].width="100%":i!==void 0&&(this._styles[r].width=i,this._styles[r]["min-width"]=i,this._styles[r]["max-width"]=i),d==="f"?this._styles[r].height="100%":d!==void 0&&(this._styles[r].height=d,this._styles[r]["min-height"]=d,this._styles[r]["max-height"]=d),this.hasAttribute("hidden")&&(this._styles[r].display="none")}),y(this.shadow,this.render)}render=()=>x`
387
+ <style>
388
+ ${O(this._styles)}
389
+ </style>
390
+ <slot></slot> `},pe=rt;var ge={at:"text-align"},ue={at:{c:"center",e:"right",j:"justify"},s:{dm:`
391
+ font-size: var(--typography-display-m-font-size);
392
+ font-weight: var(--typography-display-m-font-weight);
393
+ line-height: var(--typography-display-m-line-height);
394
+ letter-spacing: var(--typography-display-m-letter-spacing);
395
+ `,hm:`
396
+ font-size: var(--typography-headline-m-font-size);
397
+ font-weight: var(--typography-headline-m-font-weight);
398
+ line-height: var(--typography-headline-m-line-height);
399
+ letter-spacing: var(--typography-headline-m-letter-spacing);
400
+ `,tl:`
401
+ font-size: var(--typography-title-l-font-size);
402
+ font-weight: var(--typography-title-l-font-weight);
403
+ line-height: var(--typography-title-l-line-height);
404
+ letter-spacing: var(--typography-title-l-letter-spacing);
405
+ `,tm:`
406
+ font-size: var(--typography-title-m-font-size);
407
+ font-weight: var(--typography-title-m-font-weight);
408
+ line-height: var(--typography-title-m-line-height);
409
+ letter-spacing: var(--typography-title-m-letter-spacing);
410
+ `,ts:`
411
+ font-size: var(--typography-title-s-font-size);
412
+ font-weight: var(--typography-title-s-font-weight);
413
+ line-height: var(--typography-title-s-line-height);
414
+ letter-spacing: var(--typography-title-s-letter-spacing);
415
+ `,bl:`
416
+ font-size: var(--typography-body-l-font-size);
417
+ font-weight: var(--typography-body-l-font-weight);
418
+ line-height: var(--typography-body-l-line-height);
419
+ letter-spacing: var(--typography-body-l-letter-spacing);
420
+ `,bm:`
421
+ font-size: var(--typography-body-m-font-size);
422
+ font-weight: var(--typography-body-m-font-weight);
423
+ line-height: var(--typography-body-m-line-height);
424
+ letter-spacing: var(--typography-body-m-letter-spacing);
425
+ `,bs:`
426
+ font-size: var(--typography-body-s-font-size);
427
+ font-weight: var(--typography-body-s-font-weight);
428
+ line-height: var(--typography-body-s-line-height);
429
+ letter-spacing: var(--typography-body-s-letter-spacing);
430
+ `,ll:`
431
+ font-size: var(--typography-label-l-font-size);
432
+ font-weight: var(--typography-label-l-font-weight);
433
+ line-height: var(--typography-label-l-line-height);
434
+ letter-spacing: var(--typography-label-l-letter-spacing);
435
+ `,lm:`
436
+ font-size: var(--typography-label-m-font-size);
437
+ font-weight: var(--typography-label-m-font-weight);
438
+ line-height: var(--typography-label-m-line-height);
439
+ letter-spacing: var(--typography-label-m-letter-spacing);
440
+ `}},At=w(ge,ue);var fe={c:"color"},me={c:{"on-p":"--color-on-primary","on-pc":"--color-on-primary-container","on-s":"--color-on-secondary","on-sc":"--color-on-secondary-container","on-su":"--color-on-surface","on-su-v":"--color-on-surface-variant","i-on-su":"--color-inverse-on-surface","on-e":"--color-on-error","on-ec":"--color-on-error-container"}},I=w(fe,me);var jt=new CSSStyleSheet;jt.replaceSync(m`
441
+ :host {
442
+ display: block;
443
+ }
444
+ slot {
445
+ display: contents;
446
+ }
447
+ :host ::slotted(a) {
448
+ text-decoration: var(--anchor-text-decoration);
449
+ color: var(--anchor-color);
450
+ }
451
+ :host ::slotted(a:hover) {
452
+ text-decoration: var(--anchor-text-decoration-hover);
453
+ color: var(--anchor-color-hover);
454
+ }
455
+ ${At}
456
+ ${I}
457
+ ${_}
458
+ ${$}
459
+ `);var st=class extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[jt]}static get observedAttributes(){return["key","w","ellipsis"]}connectedCallback(){y(this.shadow,this.render)}attributeChangedCallback(t,o,s){let r=v(this.getAttribute("w"));this.hasAttribute("ellipsis")&&(this.style.overflow="hidden",this.style.textOverflow="ellipsis",this.style.whiteSpace="nowrap"),r==="f"?this.style.width="100%":r!==void 0&&(this.style.width=r),y(this.shadow,this.render)}render=()=>x`
460
+ <slot></slot>
461
+ `},be=st;var Mt=new CSSStyleSheet;Mt.replaceSync(m`
462
+ :host {
463
+ border-style: solid;
464
+ box-sizing: border-box;
465
+ overflow: hidden;
466
+ border-width: 0;
467
+ }
468
+ slot {
469
+ display: contents;
470
+ }
471
+ :host([of="con"]) img {
472
+ object-fit: contain;
473
+ }
474
+ :host([of="cov"]) img {
475
+ object-fit: cover;
476
+ }
477
+ :host([of="none"]) img {
478
+ object-fit: none;
479
+ }
480
+ img {
481
+ height: 100%;
482
+ width: 100%;
483
+ }
484
+ ${T}
485
+ ${_}
486
+ ${$}
487
+ `);var nt=class extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[Mt]}_styles={default:{},s:{}};static get observedAttributes(){return["key","src","wh","w","h","hidden","height","width","s-wh","s-w","s-h"]}connectedCallback(){y(this.shadow,this.render)}attributeChangedCallback(t,o,s){["default","s"].forEach(r=>{let n=c=>`${r==="default"?"":`${r}-`}${c}`,a=this.getAttribute(n("wh")),i=v(a===null?this.getAttribute(n("w")):a),d=v(a===null?this.getAttribute(n("h")):a),u=this.getAttribute(n("o")),l=this.getAttribute(n("z"));l!==null&&(this._styles[r].zIndex=l),u!==null&&(this._styles[r].opacity=u),i==="f"?this._styles[r].width="100%":i!==void 0&&(this._styles[r].width=i,this._styles[r]["min-width"]=i,this._styles[r]["max-width"]=i),d==="f"?this._styles[r].height="100%":d!==void 0&&(this._styles[r].height=d,this._styles[r]["min-height"]=d,this._styles[r]["max-height"]=d)}),y(this.shadow,this.render)}render=()=>x`
488
+ <style>
489
+ ${O(this._styles)}
490
+ </style>
491
+ <img
492
+ src="${this.getAttribute("src")}"
493
+ width="${this.getAttribute("width")}"
494
+ height="${this.getAttribute("height")}"
495
+ >
496
+ `},ve=nt;var Wt=m`
497
+ :host([pt="xs"]) svg {
498
+ padding-top: var(--spacing-xs);
499
+ }
500
+ :host([pt="s"]) svg {
501
+ padding-top: var(--spacing-s);
502
+ }
503
+ :host([pt="m"]) svg {
504
+ padding-top: var(--spacing-m);
505
+ }
506
+ :host([pt="l"]) svg {
507
+ padding-top: var(--spacing-l);
508
+ }
509
+ :host([pt="xl"]) svg {
510
+ padding-top: var(--spacing-xl);
511
+ }
512
+ :host([pr="xs"]) svg {
513
+ padding-right: var(--spacing-xs);
514
+ }
515
+ :host([pr="s"]) svg {
516
+ padding-right: var(--spacing-s);
517
+ }
518
+ :host([pr="m"]) svg {
519
+ padding-right: var(--spacing-m);
520
+ }
521
+ :host([pr="l"]) svg {
522
+ padding-right: var(--spacing-l);
523
+ }
524
+ :host([pr="xl"]) svg {
525
+ padding-right: var(--spacing-xl);
526
+ }
527
+ :host([pb="xs"]) svg {
528
+ padding-bottom: var(--spacing-xs);
529
+ }
530
+ :host([pb="s"]) svg {
531
+ padding-bottom: var(--spacing-s);
532
+ }
533
+ :host([pb="m"]) svg {
534
+ padding-bottom: var(--spacing-m);
535
+ }
536
+ :host([pb="l"]) svg {
537
+ padding-bottom: var(--spacing-l);
538
+ }
539
+ :host([pb="xl"]) svg {
540
+ padding-bottom: var(--spacing-xl);
541
+ }
542
+ :host([pl="xs"]) svg {
543
+ padding-left: var(--spacing-xs);
544
+ }
545
+ :host([pl="s"]) svg {
546
+ padding-left: var(--spacing-s);
547
+ }
548
+ :host([pl="m"]) svg {
549
+ padding-left: var(--spacing-m);
550
+ }
551
+ :host([pl="l"]) svg {
552
+ padding-left: var(--spacing-l);
553
+ }
554
+ :host([pl="xl"]) svg {
555
+ padding-left: var(--spacing-xl);
556
+ }
557
+ :host([p="xs"]) svg {
558
+ padding: var(--spacing-xs);
559
+ }
560
+ :host([p="s"]) svg {
561
+ padding: var(--spacing-s);
562
+ }
563
+ :host([p="m"]) svg {
564
+ padding: var(--spacing-m);
565
+ }
566
+ :host([p="l"]) svg {
567
+ padding: var(--spacing-l);
568
+ }
569
+ :host([p="xl"]) svg {
570
+ padding: var(--spacing-xl);
571
+ }
572
+ :host([ph="xs"]) svg {
573
+ padding-left: var(--spacing-xs);
574
+ padding-right: var(--spacing-xs);
575
+ }
576
+ :host([ph="s"]) svg {
577
+ padding-left: var(--spacing-s);
578
+ padding-right: var(--spacing-s);
579
+ }
580
+ :host([ph="m"]) svg {
581
+ padding-left: var(--spacing-m);
582
+ padding-right: var(--spacing-m);
583
+ }
584
+ :host([ph="l"]) svg {
585
+ padding-left: var(--spacing-l);
586
+ padding-right: var(--spacing-l);
587
+ }
588
+ :host([ph="xl"]) svg {
589
+ padding-left: var(--spacing-xl);
590
+ padding-right: var(--spacing-xl);
591
+ }
592
+ :host([pv="xs"]) svg {
593
+ padding-top: var(--spacing-xs);
594
+ padding-bottom: var(--spacing-xs);
595
+ }
596
+ :host([pv="s"]) svg {
597
+ padding-top: var(--spacing-s);
598
+ padding-bottom: var(--spacing-s);
599
+ }
600
+ :host([pv="m"]) svg {
601
+ padding-top: var(--spacing-m);
602
+ padding-bottom: var(--spacing-m);
603
+ }
604
+ :host([pv="l"]) svg {
605
+ padding-top: var(--spacing-l);
606
+ padding-bottom: var(--spacing-l);
607
+ }
608
+ :host([pv="xl"]) svg {
609
+ padding-top: var(--spacing-xl);
610
+ padding-bottom: var(--spacing-xl);
611
+ }
612
+ `;var Ot=new CSSStyleSheet;Ot.replaceSync(m`
613
+ ${I}
614
+ ${Wt}
615
+ ${k}
616
+ ${$}
617
+ `);var it=class e extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[Ot]}static _icons={};static get observedAttributes(){return["key","svg","w","h","wh"]}static get icons(){return e._icons}static addIcon(t,o){e._icons[t]=o}connectedCallback(){this.render()}attributeChangedCallback(t,o,s){let r=this.getAttribute("wh"),n=v(r===null?this.getAttribute("w"):r),a=v(r===null?this.getAttribute("h"):r);n&&(this.style.width=n),a&&(this.style.height=a),this.render()}render=()=>{try{let t=this.getAttribute("svg"),o=e._icons[t]||(window.rtglIcons||{})[t];if(o){this.shadow.innerHTML=o;return}}catch(t){console.log("error in rtgl-svg render",t)}this.shadow.innerHTML=""}},ye=it;var Tt=new CSSStyleSheet;Tt.replaceSync(m`
618
+ slot {
619
+ display: contents;
620
+ }
621
+ :host([hidden]) {
622
+ display: none;
623
+ }
624
+ :host {
625
+ display: flex;
626
+ align-self: auto;
627
+ align-content: flex-start;
628
+ flex-wrap: wrap;
629
+ border-style: solid;
630
+ border-width: 0;
631
+ box-sizing: border-box;
632
+ }
633
+ :host([stretch]) {
634
+ align-self: stretch;
635
+ }
636
+ ${k}
637
+ ${F}
638
+ ${U}
639
+ ${_}
640
+ ${$}
641
+ ${T}
642
+ `);var at=class extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[Tt]}connectedCallback(){y(this.shadow,this.render)}static get observedAttributes(){return["key","wh","w","h","hidden","s-w","s-h","s-d"]}_styles={default:{},s:{}};attributeChangedCallback(t,o,s){["default","s"].forEach(r=>{let n=c=>`${r==="default"?"":`${r}-`}${c}`,a=this.getAttribute(n("wh")),i=v(a===null?this.getAttribute(n("w")):a),d=v(a===null?this.getAttribute(n("h")):a),u=this.getAttribute(n("o")),l=this.getAttribute(n("z"));l!==null&&(this._styles[r]["z-index"]=l),u!==null&&(this._styles[r].opacity=u),i==="f"?this._styles[r].width="100%":i!==void 0&&(this._styles[r].width=i,this._styles[r]["min-width"]=i,this._styles[r]["max-width"]=i),d==="f"?this._styles[r].height="100%":d!==void 0&&(this._styles[r].height=d,this._styles[r]["min-height"]=d,this._styles[r]["max-height"]=d),this.hasAttribute("hidden")&&(this._styles[r].display="none")}),setTimeout(()=>{y(this.shadow,this.render)},0)}render=()=>x`
643
+ <style>
644
+ ${O(this._styles)}
645
+ </style>
646
+ <slot name="top"></slot>
647
+ ${this.items?.map((t,o)=>(typeof this.itemsRenderer=="function"?this.itemsRenderer:this.itemsRenderer.maps[t[this.itemsRenderer.key]])(t,o))}
648
+ <slot name="bottom"></slot>
649
+ `},we=at;export{ne as RettangoliButton,ve as RettangoliImage,we as RettangoliListView,ye as RettangoliSvg,be as RettangoliText,pe as RettangoliView};
650
+ /*! (c) Andrea Giammarchi - MIT */