rettangoli-ui 0.0.1
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.
- package/README.md +590 -0
- package/dist/rettangoli-ui.min.js +953 -0
- package/dist/rettangoli-ui.min.js.map +7 -0
- package/package.json +36 -0
@@ -0,0 +1,953 @@
|
|
1
|
+
var rettangoliUi=(()=>{var{isArray:rt}=Array,{getPrototypeOf:jt,getOwnPropertyDescriptor:Lt}=Object,w=[],et=()=>document.createRange(),E=(o,t,s)=>(o.set(t,s),s),{setPrototypeOf:Ot}=Object,C,at=(o,t,s)=>(C||(C=et()),s?C.setStartAfter(o):C.setStartBefore(o),C.setEndAfter(t),C.deleteContents(),o),P=({firstChild:o,lastChild:t},s)=>at(o,t,s),nt=!1,_=(o,t)=>nt&&o.nodeType===11?1/t<0?t?P(o,!0):o.lastChild:t?o.valueOf():o.firstChild:o,Y=o=>document.createComment(o),U=class extends(t=>{function s(e){return Ot(e,new.target.prototype)}return s.prototype=t.prototype,s})(DocumentFragment){#o=Y("<>");#s=Y("</>");#t=w;constructor(t){super(t),this.replaceChildren(this.#o,...t.childNodes,this.#s),nt=!0}get firstChild(){return this.#o}get lastChild(){return this.#s}get parentNode(){return this.#o.parentNode}remove(){P(this,!1)}replaceWith(t){P(this,!0).replaceWith(t)}valueOf(){let{firstChild:t,lastChild:s,parentNode:e}=this;if(e===this)this.#t===w&&(this.#t=[...this.childNodes]);else{if(e)for(this.#t=[t];t!==s;)this.#t.push(t=t.nextSibling);this.replaceChildren(...this.#t)}return this}},it=(o,t,s)=>o.setAttribute(t,s),L=(o,t)=>o.removeAttribute(t),M,Dt=(o,t,s)=>{s=s.slice(1),M||(M=new WeakMap);let e=M.get(o)||E(M,o,{}),r=e[s];return r&&r[0]&&o.removeEventListener(s,...r),r=rt(t)?t:[t,!1],e[s]=r,r[0]&&o.addEventListener(s,...r),t},T=(o,t)=>{let{t:s,n:e}=o,r=!1;switch(typeof t){case"object":if(t!==null){(e||s).replaceWith(o.n=t.valueOf());break}case"undefined":r=!0;default:s.data=r?"":t,e&&(o.n=null,e.replaceWith(s))}return t},O=(o,t,s)=>o[s]=t,Ht=(o,t,s)=>O(o,t,s.slice(1)),G=(o,t,s)=>t==null?(L(o,s),t):O(o,t,s),lt=(o,t)=>(typeof t=="function"?t(o):t.current=o,t),R=(o,t,s)=>(t==null?L(o,s):it(o,s,t),t),_t=(o,t,s)=>(o.toggleAttribute(s.slice(1),t),t),j=(o,t,s)=>{let{length:e}=t;if(o.data=`[${e}]`,e)return((r,a,i,n,d)=>{let u=i.length,p=a.length,c=u,l=0,h=0,m=null;for(;l<p||h<c;)if(p===l){let v=c<u?h?n(i[h-1],-0).nextSibling:n(i[c-h],0):d;for(;h<c;)r.insertBefore(n(i[h++],1),v)}else if(c===h)for(;l<p;)m&&m.has(a[l])||r.removeChild(n(a[l],-1)),l++;else if(a[l]===i[h])l++,h++;else if(a[p-1]===i[c-1])p--,c--;else if(a[l]===i[c-1]&&i[h]===a[p-1]){let v=n(a[--p],-1).nextSibling;r.insertBefore(n(i[h++],1),n(a[l++],-1).nextSibling),r.insertBefore(n(i[--c],1),v),a[p]=i[c]}else{if(!m){m=new Map;let v=h;for(;v<c;)m.set(i[v],v++)}if(m.has(a[l])){let v=m.get(a[l]);if(h<v&&v<c){let S=l,A=1;for(;++S<p&&S<c&&m.get(a[S])===v+A;)A++;if(A>v-h){let H=n(a[l],0);for(;h<v;)r.insertBefore(n(i[h++],1),H)}else r.replaceChild(n(i[h++],1),n(a[l++],-1))}else l++}else r.removeChild(n(a[l++],-1))}return i})(o.parentNode,s,t,_,o);switch(s.length){case 1:s[0].remove();case 0:break;default:at(_(s[0],0),_(s.at(-1),-0),!1)}return w},Rt=new Map([["aria",(o,t)=>{for(let s in t){let e=t[s],r=s==="role"?s:`aria-${s}`;e==null?L(o,r):it(o,r,e)}return t}],["class",(o,t)=>G(o,t,t==null?"class":"className")],["data",(o,t)=>{let{dataset:s}=o;for(let e in t)t[e]==null?delete s[e]:s[e]=t[e];return t}],["ref",lt],["style",(o,t)=>t==null?G(o,t,"style"):O(o.style,t,"cssText")]]),Ft=(o,t,s)=>{switch(t[0]){case".":return Ht;case"?":return _t;case"@":return Dt;default:return s||"ownerSVGElement"in o?t==="ref"?lt:R:Rt.get(t)||(t in o?t.startsWith("on")?O:((e,r)=>{let a;do a=Lt(e,r);while(!a&&(e=jt(e)));return a})(o,t)?.set?G:R:R)}},Vt=(o,t)=>(o.textContent=t??"",t),N=(o,t,s)=>({a:o,b:t,c:s}),k=()=>N(null,null,w),Bt=(o,t)=>t.reduceRight(Pt,o),Pt=(o,t)=>o.childNodes[t],ht=o=>(t,s)=>{let{a:e,b:r,c:a}=o(t,s),i=document.importNode(e,!0),n=w;if(r!==w){n=[];for(let l,h,m=0;m<r.length;m++){let{a:v,b:S,c:A}=r[m],H=v===h?l:l=Bt(i,h=v);n[m]=(d=S,u=H,p=A,c=S===j?[]:S===T?k():null,{v:w,u:d,t:u,n:p,c})}}var d,u,p,c;return((l,h)=>({b:l,c:h}))(a?i.firstChild:new U(i),n)},Ut=/^(?:plaintext|script|style|textarea|title|xmp)$/i,Gt=/^(?:area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)$/i,It=/<([a-zA-Z0-9]+[a-zA-Z0-9:._-]*)([^>]*?)(\/?)>/g,Zt=/([^\s\\>"'=]+)\s*=\s*(['"]?)\x01/g,qt=/[\x01\x02]/g,F,V,W=document.createElement("template"),Jt=(o,t)=>{if(t)return F||(F=document.createElementNS("http://www.w3.org/2000/svg","svg"),V=et(),V.selectNodeContents(F)),V.createContextualFragment(o);W.innerHTML=o;let{content:s}=W;return W=W.cloneNode(!1),s},B=o=>{let t=[],s;for(;s=o.parentNode;)t.push(t.indexOf.call(s.childNodes,o)),o=s;return t},tt=()=>document.createTextNode(""),Kt=(o,t,s)=>{let e=Jt(((d,u,p)=>{let c=0;return d.join("").trim().replace(It,(l,h,m,v)=>`<${h}${m.replace(Zt,"=$2$1").trimEnd()}${v?p||Gt.test(h)?" /":`></${h}`:""}>`).replace(qt,l=>l===""?`<!--${u+c++}-->`:u+c++)})(o,z,s),s),{length:r}=o,a=w;if(r>1){let d=[],u=document.createTreeWalker(e,129),p=0,c=`${z}${p++}`;for(a=[];p<r;){let l=u.nextNode();if(l.nodeType===8){if(l.data===c){let h=rt(t[p-1])?j:T;h===T&&d.push(l),a.push(N(B(l),h,null)),c=`${z}${p++}`}}else{let h;for(;l.hasAttribute(c);){h||(h=B(l));let m=l.getAttribute(c);a.push(N(h,Ft(l,m,s),m)),L(l,c),c=`${z}${p++}`}!s&&Ut.test(l.localName)&&l.textContent.trim()===`<!--${c}-->`&&(a.push(N(h||B(l),Vt,null)),c=`${z}${p++}`)}}for(p=0;p<d.length;p++)d[p].replaceWith(tt())}let{childNodes:i}=e,{length:n}=i;return n<1?(n=1,e.appendChild(tt())):n===1&&r!==1&&i[0].nodeType!==1&&(n=0),E(pt,o,N(e,a,n===1))},pt=new WeakMap,z="is\xB5",ct=o=>(t,s)=>pt.get(t)||Kt(t,s,o),Qt=ht(ct(!1)),Xt=ht(ct(!0)),I=(o,{s:t,t:s,v:e})=>{if(o.a!==s){let{b:r,c:a}=(t?Xt:Qt)(s,e);o.a=s,o.b=r,o.c=a}for(let{c:r}=o,a=0;a<r.length;a++){let i=e[a],n=r[a];switch(n.u){case j:n.v=j(n.t,Yt(n.c,i),n.v);break;case T:let d=i instanceof $?I(n.c||(n.c=k()),i):(n.c=null,i);d!==n.v&&(n.v=T(n,d));break;default:i!==n.v&&(n.v=n.u(n.t,i,n.n,n.v))}}return o.b},Yt=(o,t)=>{let s=0,{length:e}=t;for(e<o.length&&o.splice(e);s<e;s++){let r=t[s];r instanceof $?t[s]=I(o[s]||(o[s]=k()),r):o[s]=null}return t},$=class{constructor(t,s,e){this.s=t,this.t=s,this.v=e}toDOM(t=k()){return I(t,this)}};var gt=o=>(t,...s)=>new $(o,t,s),f=gt(!1),ro=gt(!0),ot=new WeakMap,x=(o,t)=>((s,e,r)=>{let a=ot.get(s)||E(ot,s,k()),{b:i}=a,n=r&&typeof e=="function"?e():e,d=n instanceof $?n.toDOM(a):n;return i!==d&&s.replaceChildren((a.b=d).valueOf()),s})(o,t,!0),st=new WeakMap,dt=o=>(t,s)=>{let e=st.get(t)||E(st,t,new Map);return e.get(s)||E(e,s,function(r,...a){return new $(o,r,a).toDOM(this)}.bind(k()))},eo=dt(!1),ao=dt(!0);function g(o,...t){let s="";return o.forEach((e,r)=>{s+=e+(t[r]||"")}),s}var b=g`
|
2
|
+
:host([mt="xs"]) {
|
3
|
+
margin-top: var(--spacing-xs);
|
4
|
+
}
|
5
|
+
:host([mt="s"]) {
|
6
|
+
margin-top: var(--spacing-s);
|
7
|
+
}
|
8
|
+
:host([mt="m"]) {
|
9
|
+
margin-top: var(--spacing-m);
|
10
|
+
}
|
11
|
+
:host([mt="l"]) {
|
12
|
+
margin-top: var(--spacing-l);
|
13
|
+
}
|
14
|
+
:host([mt="xl"]) {
|
15
|
+
margin-top: var(--spacing-xl);
|
16
|
+
}
|
17
|
+
:host([mr="xs"]) {
|
18
|
+
margin-right: var(--spacing-xs);
|
19
|
+
}
|
20
|
+
:host([mr="s"]) {
|
21
|
+
margin-right: var(--spacing-s);
|
22
|
+
}
|
23
|
+
:host([mr="m"]) {
|
24
|
+
margin-right: var(--spacing-m);
|
25
|
+
}
|
26
|
+
:host([mr="l"]) {
|
27
|
+
margin-right: var(--spacing-l);
|
28
|
+
}
|
29
|
+
:host([mr="xl"]) {
|
30
|
+
margin-right: var(--spacing-xl);
|
31
|
+
}
|
32
|
+
:host([mb="xs"]) {
|
33
|
+
margin-bottom: var(--spacing-xs);
|
34
|
+
}
|
35
|
+
:host([mb="s"]) {
|
36
|
+
margin-bottom: var(--spacing-s);
|
37
|
+
}
|
38
|
+
:host([mb="m"]) {
|
39
|
+
margin-bottom: var(--spacing-m);
|
40
|
+
}
|
41
|
+
:host([mb="l"]) {
|
42
|
+
margin-bottom: var(--spacing-l);
|
43
|
+
}
|
44
|
+
:host([mb="xl"]) {
|
45
|
+
margin-bottom: var(--spacing-xl);
|
46
|
+
}
|
47
|
+
:host([ml="xs"]) {
|
48
|
+
margin-left: var(--spacing-xs);
|
49
|
+
}
|
50
|
+
:host([ml="s"]) {
|
51
|
+
margin-left: var(--spacing-s);
|
52
|
+
}
|
53
|
+
:host([ml="m"]) {
|
54
|
+
margin-left: var(--spacing-m);
|
55
|
+
}
|
56
|
+
:host([ml="l"]) {
|
57
|
+
margin-left: var(--spacing-l);
|
58
|
+
}
|
59
|
+
:host([ml="xl"]) {
|
60
|
+
margin-left: var(--spacing-xl);
|
61
|
+
}
|
62
|
+
:host([m="xs"]) {
|
63
|
+
margin: var(--spacing-xs);
|
64
|
+
}
|
65
|
+
:host([m="s"]) {
|
66
|
+
margin: var(--spacing-s);
|
67
|
+
}
|
68
|
+
:host([m="m"]) {
|
69
|
+
margin: var(--spacing-m);
|
70
|
+
}
|
71
|
+
:host([m="l"]) {
|
72
|
+
margin: var(--spacing-l);
|
73
|
+
}
|
74
|
+
:host([m="xl"]) {
|
75
|
+
margin: var(--spacing-xl);
|
76
|
+
}
|
77
|
+
:host([mh="xs"]) {
|
78
|
+
margin-left: var(--spacing-xs);
|
79
|
+
margin-right: var(--spacing-xs);
|
80
|
+
}
|
81
|
+
:host([mh="s"]) {
|
82
|
+
margin-left: var(--spacing-s);
|
83
|
+
margin-right: var(--spacing-s);
|
84
|
+
}
|
85
|
+
:host([mh="m"]) {
|
86
|
+
margin-left: var(--spacing-m);
|
87
|
+
margin-right: var(--spacing-m);
|
88
|
+
}
|
89
|
+
:host([mh="l"]) {
|
90
|
+
margin-left: var(--spacing-l);
|
91
|
+
margin-right: var(--spacing-l);
|
92
|
+
}
|
93
|
+
:host([mh="xl"]) {
|
94
|
+
margin-left: var(--spacing-xl);
|
95
|
+
margin-right: var(--spacing-xl);
|
96
|
+
}
|
97
|
+
:host([mv="xs"]) {
|
98
|
+
margin-top: var(--spacing-xs);
|
99
|
+
margin-bottom: var(--spacing-xs);
|
100
|
+
}
|
101
|
+
:host([mv="s"]) {
|
102
|
+
margin-top: var(--spacing-s);
|
103
|
+
margin-bottom: var(--spacing-s);
|
104
|
+
}
|
105
|
+
:host([mv="m"]) {
|
106
|
+
margin-top: var(--spacing-m);
|
107
|
+
margin-bottom: var(--spacing-m);
|
108
|
+
}
|
109
|
+
:host([mv="l"]) {
|
110
|
+
margin-top: var(--spacing-l);
|
111
|
+
margin-bottom: var(--spacing-l);
|
112
|
+
}
|
113
|
+
:host([mv="xl"]) {
|
114
|
+
margin-top: var(--spacing-xl);
|
115
|
+
margin-bottom: var(--spacing-xl);
|
116
|
+
}
|
117
|
+
`;var y=g`
|
118
|
+
:host([flex="0"]) {
|
119
|
+
flex: 0;
|
120
|
+
}
|
121
|
+
:host([flex="1"]) {
|
122
|
+
flex: 1;
|
123
|
+
}
|
124
|
+
:host([flex="2"]) {
|
125
|
+
flex: 2;
|
126
|
+
}
|
127
|
+
:host([flex="3"]) {
|
128
|
+
flex: 3;
|
129
|
+
}
|
130
|
+
:host([flex="4"]) {
|
131
|
+
flex: 4;
|
132
|
+
}
|
133
|
+
:host([flex="5"]) {
|
134
|
+
flex: 5;
|
135
|
+
}
|
136
|
+
:host([flex="6"]) {
|
137
|
+
flex: 6;
|
138
|
+
}
|
139
|
+
:host([flex="7"]) {
|
140
|
+
flex: 7;
|
141
|
+
}
|
142
|
+
:host([flex="8"]) {
|
143
|
+
flex: 8;
|
144
|
+
}
|
145
|
+
:host([flex="9"]) {
|
146
|
+
flex: 9;
|
147
|
+
}
|
148
|
+
:host([flex="10"]) {
|
149
|
+
flex: 10;
|
150
|
+
}
|
151
|
+
:host([flex="11"]) {
|
152
|
+
flex: 11;
|
153
|
+
}
|
154
|
+
:host([flex="12"]) {
|
155
|
+
flex: 12;
|
156
|
+
}
|
157
|
+
|
158
|
+
:host([as="sch"]) {
|
159
|
+
align-self: stretch;
|
160
|
+
}
|
161
|
+
|
162
|
+
/*
|
163
|
+
:host([sha="s"]) {
|
164
|
+
margin-right: auto;
|
165
|
+
}
|
166
|
+
:host([sha="c"]) {
|
167
|
+
margin-left: auto;
|
168
|
+
margin-right: auto;
|
169
|
+
}
|
170
|
+
:host([sha="e"]) {
|
171
|
+
margin-left: auto;
|
172
|
+
}
|
173
|
+
|
174
|
+
:host([sva="s"]) {
|
175
|
+
margin-bottom: auto;
|
176
|
+
}
|
177
|
+
:host([sva="c"]) {
|
178
|
+
margin-top: auto;
|
179
|
+
margin-bottom: auto;
|
180
|
+
}
|
181
|
+
:host([sva="e"]) {
|
182
|
+
margin-top: auto;
|
183
|
+
} */
|
184
|
+
|
185
|
+
|
186
|
+
/*
|
187
|
+
:host([d="h"][sha="s"]) {
|
188
|
+
align-self: start;
|
189
|
+
}
|
190
|
+
:host([d="h"][sha="c"]) {
|
191
|
+
align-self: center;
|
192
|
+
}
|
193
|
+
:host([d="h"][sha="e"]) {
|
194
|
+
align-self: flex-end;
|
195
|
+
}
|
196
|
+
:host([d="v"][sha="s"]) {
|
197
|
+
}
|
198
|
+
:host([d="v"][sha="c"]) {
|
199
|
+
}
|
200
|
+
:host([d="v"][sha="e"]) {
|
201
|
+
}
|
202
|
+
|
203
|
+
:host([d="h"][sva="s"]) {
|
204
|
+
}
|
205
|
+
:host([d="h"][sva="c"]) {
|
206
|
+
}
|
207
|
+
:host([d="h"][sva="e"]) {
|
208
|
+
}
|
209
|
+
:host([d="v"][sva="s"]) {
|
210
|
+
}
|
211
|
+
:host([d="v"][sva="c"]) {
|
212
|
+
}
|
213
|
+
:host([d="v"][sva="e"]) {
|
214
|
+
}
|
215
|
+
*/
|
216
|
+
`;var mt=new CSSStyleSheet;mt.replaceSync(g`
|
217
|
+
:host {
|
218
|
+
display: flex;
|
219
|
+
}
|
220
|
+
|
221
|
+
slot {
|
222
|
+
display: flex;
|
223
|
+
flex: 1;
|
224
|
+
justify-content: center;
|
225
|
+
}
|
226
|
+
|
227
|
+
button {
|
228
|
+
flex: 1;
|
229
|
+
border-style: solid;
|
230
|
+
}
|
231
|
+
|
232
|
+
button:hover {
|
233
|
+
cursor: pointer;
|
234
|
+
}
|
235
|
+
|
236
|
+
:host([t="ps"]) button,
|
237
|
+
:host([t="p"]) button,
|
238
|
+
:host([t="pl"]) button {
|
239
|
+
color: var(--color-on-primary);
|
240
|
+
border-color: var(--color-primary);
|
241
|
+
background-color: var(--color-primary);
|
242
|
+
}
|
243
|
+
|
244
|
+
:host([t="ps"]) button:hover,
|
245
|
+
:host([t="p"]) button:hover,
|
246
|
+
:host([t="pl"]) button:hover {
|
247
|
+
border-color: var(--color-primary-hover);
|
248
|
+
background-color: var(--color-primary-hover);
|
249
|
+
}
|
250
|
+
|
251
|
+
:host([t="ps"]) button:active,
|
252
|
+
:host([t="p"]) button:active,
|
253
|
+
:host([t="pl"]) button:active {
|
254
|
+
border-color: var(--color-primary-active);
|
255
|
+
background-color: var(--color-primary-active);
|
256
|
+
}
|
257
|
+
|
258
|
+
:host([t="ss"]) button,
|
259
|
+
:host([t="s"]) button,
|
260
|
+
:host([t="sl"]) button {
|
261
|
+
color: var(--color-on-secondary);
|
262
|
+
border-color: var(--color-secondary);
|
263
|
+
background-color: var(--color-secondary);
|
264
|
+
}
|
265
|
+
|
266
|
+
:host([t="ss"]) button:hover,
|
267
|
+
:host([t="s"]) button:hover,
|
268
|
+
:host([t="sl"]) button:hover {
|
269
|
+
background-color: var(--color-secondary-hover);
|
270
|
+
border-color: var(--color-secondary-hover);
|
271
|
+
}
|
272
|
+
|
273
|
+
:host([t="ss"]) button:active,
|
274
|
+
:host([t="s"]) button:active,
|
275
|
+
:host([t="sl"]) button:active {
|
276
|
+
background-color: var(--color-secondary-active);
|
277
|
+
border-color: var(--color-secondary-active);
|
278
|
+
}
|
279
|
+
|
280
|
+
:host([t="es"]) button,
|
281
|
+
:host([t="e"]) button,
|
282
|
+
:host([t="el"]) button {
|
283
|
+
color: var(--color-on-error);
|
284
|
+
border-color: var(--color-error);
|
285
|
+
background-color: var(--color-error);
|
286
|
+
}
|
287
|
+
|
288
|
+
:host([t="es"]) button:hover,
|
289
|
+
:host([t="e"]) button:hover,
|
290
|
+
:host([t="el"]) button:hover {
|
291
|
+
background-color: var(--color-error-hover);
|
292
|
+
border-color: var(--color-error-hover);
|
293
|
+
}
|
294
|
+
|
295
|
+
:host([t="es"]) button:active,
|
296
|
+
:host([t="e"]) button:active,
|
297
|
+
:host([t="el"]) button:active {
|
298
|
+
background-color: var(--color-error-active);
|
299
|
+
border-color: var(--color-error-active);
|
300
|
+
}
|
301
|
+
|
302
|
+
:host([t="ps"]) button,
|
303
|
+
:host([t="ss"]) button,
|
304
|
+
:host([t="es"]) button {
|
305
|
+
padding-top: 4px;
|
306
|
+
padding-bottom: 4px;
|
307
|
+
padding-left: 6px;
|
308
|
+
padding-right: 6px;
|
309
|
+
border-width: 2px;
|
310
|
+
border-radius: 1px;
|
311
|
+
}
|
312
|
+
|
313
|
+
:host([t="p"]) button,
|
314
|
+
:host([t="s"]) button,
|
315
|
+
:host([t="e"]) button {
|
316
|
+
padding-top: 3px;
|
317
|
+
padding-bottom: 3px;
|
318
|
+
padding-left: 12px;
|
319
|
+
padding-right: 12px;
|
320
|
+
border-width: 4px;
|
321
|
+
border-radius: 2px;
|
322
|
+
}
|
323
|
+
|
324
|
+
:host([t="pl"]) button,
|
325
|
+
:host([t="sl"]) button,
|
326
|
+
:host([t="el"]) button {
|
327
|
+
padding-top: 5px;
|
328
|
+
padding-bottom: 5px;
|
329
|
+
padding-left: 16px;
|
330
|
+
padding-right: 16px;
|
331
|
+
border-width: 6px;
|
332
|
+
border-radius: 3px;
|
333
|
+
font-size: 16px;
|
334
|
+
}
|
335
|
+
|
336
|
+
${b}
|
337
|
+
${y}
|
338
|
+
`);var Z=class extends HTMLElement{constructor(){super();let t=this.attachShadow({mode:"closed"});t.adoptedStyleSheets=[mt],x(t,this.render)}render=()=>f`
|
339
|
+
<button>
|
340
|
+
<slot></slot>
|
341
|
+
</button>
|
342
|
+
`},vt=Z;var ft=g`
|
343
|
+
:host([g="xs"]) slot {
|
344
|
+
gap: var(--spacing-xs);
|
345
|
+
}
|
346
|
+
:host([g="s"]) slot {
|
347
|
+
gap: var(--spacing-s);
|
348
|
+
}
|
349
|
+
:host([g="m"]) slot {
|
350
|
+
gap: var(--spacing-m);
|
351
|
+
}
|
352
|
+
:host([g="l"]) slot {
|
353
|
+
gap: var(--spacing-l);
|
354
|
+
}
|
355
|
+
:host([g="xl"]) slot {
|
356
|
+
gap: var(--spacing-xl);
|
357
|
+
}
|
358
|
+
:host([gv="xs"]) slot {
|
359
|
+
row-gap: var(--spacing-xs);
|
360
|
+
}
|
361
|
+
:host([gv="s"]) slot {
|
362
|
+
row-gap: var(--spacing-s);
|
363
|
+
}
|
364
|
+
:host([gv="m"]) slot {
|
365
|
+
row-gap: var(--spacing-m);
|
366
|
+
}
|
367
|
+
:host([gv="l"]) slot {
|
368
|
+
row-gap: var(--spacing-l);
|
369
|
+
}
|
370
|
+
:host([gv="xl"]) slot {
|
371
|
+
row-gap: var(--spacing-xl);
|
372
|
+
}
|
373
|
+
:host([gh="xs"]) slot {
|
374
|
+
column-gap: var(--spacing-xs);
|
375
|
+
}
|
376
|
+
:host([gh="s"]) slot {
|
377
|
+
column-gap: var(--spacing-s);
|
378
|
+
}
|
379
|
+
:host([gh="m"]) slot {
|
380
|
+
column-gap: var(--spacing-m);
|
381
|
+
}
|
382
|
+
:host([gh="l"]) slot {
|
383
|
+
column-gap: var(--spacing-l);
|
384
|
+
}
|
385
|
+
:host([gh="xl"]) slot {
|
386
|
+
column-gap: var(--spacing-xl);
|
387
|
+
}
|
388
|
+
`;var ut=g`
|
389
|
+
:host([pt="xs"]) slot {
|
390
|
+
padding-top: var(--spacing-xs);
|
391
|
+
}
|
392
|
+
:host([pt="s"]) slot {
|
393
|
+
padding-top: var(--spacing-s);
|
394
|
+
}
|
395
|
+
:host([pt="m"]) slot {
|
396
|
+
padding-top: var(--spacing-m);
|
397
|
+
}
|
398
|
+
:host([pt="l"]) slot {
|
399
|
+
padding-top: var(--spacing-l);
|
400
|
+
}
|
401
|
+
:host([pt="xl"]) slot {
|
402
|
+
padding-top: var(--spacing-xl);
|
403
|
+
}
|
404
|
+
:host([pr="xs"]) slot {
|
405
|
+
padding-right: var(--spacing-xs);
|
406
|
+
}
|
407
|
+
:host([pr="s"]) slot {
|
408
|
+
padding-right: var(--spacing-s);
|
409
|
+
}
|
410
|
+
:host([pr="m"]) slot {
|
411
|
+
padding-right: var(--spacing-m);
|
412
|
+
}
|
413
|
+
:host([pr="l"]) slot {
|
414
|
+
padding-right: var(--spacing-l);
|
415
|
+
}
|
416
|
+
:host([pr="xl"]) slot {
|
417
|
+
padding-right: var(--spacing-xl);
|
418
|
+
}
|
419
|
+
:host([pb="xs"]) slot {
|
420
|
+
padding-bottom: var(--spacing-xs);
|
421
|
+
}
|
422
|
+
:host([pb="s"]) slot {
|
423
|
+
padding-bottom: var(--spacing-s);
|
424
|
+
}
|
425
|
+
:host([pb="m"]) slot {
|
426
|
+
padding-bottom: var(--spacing-m);
|
427
|
+
}
|
428
|
+
:host([pb="l"]) slot {
|
429
|
+
padding-bottom: var(--spacing-l);
|
430
|
+
}
|
431
|
+
:host([pb="xl"]) slot {
|
432
|
+
padding-bottom: var(--spacing-xl);
|
433
|
+
}
|
434
|
+
:host([pl="xs"]) slot {
|
435
|
+
padding-left: var(--spacing-xs);
|
436
|
+
}
|
437
|
+
:host([pl="s"]) slot {
|
438
|
+
padding-left: var(--spacing-s);
|
439
|
+
}
|
440
|
+
:host([pl="m"]) slot {
|
441
|
+
padding-left: var(--spacing-m);
|
442
|
+
}
|
443
|
+
:host([pl="l"]) slot {
|
444
|
+
padding-left: var(--spacing-l);
|
445
|
+
}
|
446
|
+
:host([pl="xl"]) slot {
|
447
|
+
padding-left: var(--spacing-xl);
|
448
|
+
}
|
449
|
+
:host([p="xs"]) slot {
|
450
|
+
padding: var(--spacing-xs);
|
451
|
+
}
|
452
|
+
:host([p="s"]) slot {
|
453
|
+
padding: var(--spacing-s);
|
454
|
+
}
|
455
|
+
:host([p="m"]) slot {
|
456
|
+
padding: var(--spacing-m);
|
457
|
+
}
|
458
|
+
:host([p="l"]) slot {
|
459
|
+
padding: var(--spacing-l);
|
460
|
+
}
|
461
|
+
:host([p="xl"]) slot {
|
462
|
+
padding: var(--spacing-xl);
|
463
|
+
}
|
464
|
+
:host([ph="xs"]) slot {
|
465
|
+
padding-left: var(--spacing-xs);
|
466
|
+
padding-right: var(--spacing-xs);
|
467
|
+
}
|
468
|
+
:host([ph="s"]) slot {
|
469
|
+
padding-left: var(--spacing-s);
|
470
|
+
padding-right: var(--spacing-s);
|
471
|
+
}
|
472
|
+
:host([ph="m"]) slot {
|
473
|
+
padding-left: var(--spacing-m);
|
474
|
+
padding-right: var(--spacing-m);
|
475
|
+
}
|
476
|
+
:host([ph="l"]) slot {
|
477
|
+
padding-left: var(--spacing-l);
|
478
|
+
padding-right: var(--spacing-l);
|
479
|
+
}
|
480
|
+
:host([ph="xl"]) slot {
|
481
|
+
padding-left: var(--spacing-xl);
|
482
|
+
padding-right: var(--spacing-xl);
|
483
|
+
}
|
484
|
+
:host([pv="xs"]) slot {
|
485
|
+
padding-top: var(--spacing-xs);
|
486
|
+
padding-bottom: var(--spacing-xs);
|
487
|
+
}
|
488
|
+
:host([pv="s"]) slot {
|
489
|
+
padding-top: var(--spacing-s);
|
490
|
+
padding-bottom: var(--spacing-s);
|
491
|
+
}
|
492
|
+
:host([pv="m"]) slot {
|
493
|
+
padding-top: var(--spacing-m);
|
494
|
+
padding-bottom: var(--spacing-m);
|
495
|
+
}
|
496
|
+
:host([pv="l"]) slot {
|
497
|
+
padding-top: var(--spacing-l);
|
498
|
+
padding-bottom: var(--spacing-l);
|
499
|
+
}
|
500
|
+
:host([pv="xl"]) slot {
|
501
|
+
padding-top: var(--spacing-xl);
|
502
|
+
padding-bottom: var(--spacing-xl);
|
503
|
+
}
|
504
|
+
`;var xt=g`
|
505
|
+
:host([d="h"]) slot {
|
506
|
+
flex-direction: row;
|
507
|
+
}
|
508
|
+
:host([d="v"]) slot {
|
509
|
+
flex-direction: column;
|
510
|
+
}
|
511
|
+
:host([d="h"][ah="s"]) slot {
|
512
|
+
justify-content: flex-start;
|
513
|
+
}
|
514
|
+
:host([d="h"][ah="c"]) slot {
|
515
|
+
justify-content: center;
|
516
|
+
}
|
517
|
+
:host([d="h"][ah="e"]) slot {
|
518
|
+
justify-content: flex-end;
|
519
|
+
}
|
520
|
+
:host([d="h"][av="s"]) slot {
|
521
|
+
align-items: flex-start;
|
522
|
+
}
|
523
|
+
:host([d="h"][av="c"]) slot {
|
524
|
+
align-items: center;
|
525
|
+
}
|
526
|
+
:host([d="h"][av="e"]) slot {
|
527
|
+
align-items: flex-end;
|
528
|
+
}
|
529
|
+
:host([d="v"][ah="s"]) slot {
|
530
|
+
align-items: flex-start;
|
531
|
+
}
|
532
|
+
:host([d="v"][ah="c"]) slot {
|
533
|
+
align-items: center;
|
534
|
+
}
|
535
|
+
:host([d="v"][ah="e"]) slot {
|
536
|
+
align-items: flex-end;
|
537
|
+
}
|
538
|
+
:host([d="v"][av="s"]) slot {
|
539
|
+
justify-content: flex-start;
|
540
|
+
}
|
541
|
+
:host([d="v"][av="c"]) slot {
|
542
|
+
justify-content: center;
|
543
|
+
}
|
544
|
+
:host([d="v"][av="e"]) slot {
|
545
|
+
justify-content: flex-end;
|
546
|
+
}
|
547
|
+
`;var D=g`
|
548
|
+
:host([bgc="p"]) {
|
549
|
+
background-color: var(--color-primary);
|
550
|
+
}
|
551
|
+
:host([bgc="pc"]) {
|
552
|
+
background-color: var(--color-primary-container);
|
553
|
+
}
|
554
|
+
:host([bgc="s"]) {
|
555
|
+
background-color: var(--color-secondary);
|
556
|
+
}
|
557
|
+
:host([bgc="sc"]) {
|
558
|
+
background-color: var(--color-secondary-container);
|
559
|
+
}
|
560
|
+
:host([bgc="e"]) {
|
561
|
+
background-color: var(--color-error);
|
562
|
+
}
|
563
|
+
:host([bgc="ec"]) {
|
564
|
+
background-color: var(--color-error-container);
|
565
|
+
}
|
566
|
+
:host([bgc="su"]) {
|
567
|
+
background-color: var(--color-surface);
|
568
|
+
}
|
569
|
+
:host([bgc="sucl"]) {
|
570
|
+
background-color: var(--color-surface-container-low);
|
571
|
+
}
|
572
|
+
:host([bgc="suc"]) {
|
573
|
+
background-color: var(--color-surface-container);
|
574
|
+
}
|
575
|
+
:host([bgc="such"]) {
|
576
|
+
background-color: var(--color-surface-container-high);
|
577
|
+
}
|
578
|
+
:host([bgc="isu"]) {
|
579
|
+
background-color: var(--color-inverse-surface);
|
580
|
+
}
|
581
|
+
`;var yt=new CSSStyleSheet;yt.replaceSync(g`
|
582
|
+
:host {
|
583
|
+
display: flex;
|
584
|
+
}
|
585
|
+
slot {
|
586
|
+
display: flex;
|
587
|
+
flex: 1;
|
588
|
+
}
|
589
|
+
:host([fw="w"]) slot {
|
590
|
+
flex-wrap: wrap;
|
591
|
+
}
|
592
|
+
${y}
|
593
|
+
${xt}
|
594
|
+
${ft}
|
595
|
+
${D}
|
596
|
+
${ut}
|
597
|
+
${b}
|
598
|
+
`);function to(o){let t=String(o);return/[0-9]$/.test(t)}var bt=o=>{if(o!==void 0)return to(o)?`${o}px`:o},q=class extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[yt],x(this.shadow,this.render)}static get observedAttributes(){return["wh","w","h","hidden"]}attributeChangedCallback(t,s,e){let r=this.getAttribute("wh"),a=bt(r===null?this.getAttribute("w"):r),i=bt(r===null?this.getAttribute("h"):r),n=a?`width: ${a}; min-width: ${a}; max-width: ${a};`:"",d=i?`height: ${i}; min-height: ${i}; max-height: ${i};`:"",u=this.hasAttribute("hidden")?"display: none;":"",p=`${n} ${d} ${u}`;this.style=p,x(this.shadow,this.render)}render=()=>f`
|
599
|
+
<slot></slot>
|
600
|
+
`},wt=q;var St=new CSSStyleSheet;St.replaceSync(g`
|
601
|
+
:host([c="on-p"]) slot {
|
602
|
+
color: var(--color-on-primary);
|
603
|
+
}
|
604
|
+
:host([c="on-pc"]) slot {
|
605
|
+
color: var(--color-on-primary-container);
|
606
|
+
}
|
607
|
+
:host([c="on-s"]) slot {
|
608
|
+
color: var(--color-on-secondary);
|
609
|
+
}
|
610
|
+
:host([c="on-sc"]) slot {
|
611
|
+
color: var(--color-on-secondary-container);
|
612
|
+
}
|
613
|
+
:host([c="on-su"]) slot {
|
614
|
+
color: var(--color-on-surface);
|
615
|
+
}
|
616
|
+
:host([c="on-suv"]) slot {
|
617
|
+
color: var(--color-on-surface-variant);
|
618
|
+
}
|
619
|
+
:host([c="i-on-su"]) slot {
|
620
|
+
color: var(--color-inverse-on-surface);
|
621
|
+
}
|
622
|
+
:host([c="on-e"]) slot {
|
623
|
+
color: var(--color-on-error);
|
624
|
+
}
|
625
|
+
:host([c="on-ec"]) slot {
|
626
|
+
color: var(--color-on-error-container);
|
627
|
+
}
|
628
|
+
|
629
|
+
:host([s="dm"]) slot {
|
630
|
+
font-size: var(--typography-display-m-font-size);
|
631
|
+
font-weight: var(--typography-display-m-font-weight);
|
632
|
+
line-height: var(--typography-display-m-line-height);
|
633
|
+
letter-spacing: var(--typography-display-m-letter-spacing);
|
634
|
+
}
|
635
|
+
|
636
|
+
:host([s="hm"]) slot {
|
637
|
+
font-size: var(--typography-headline-m-font-size);
|
638
|
+
font-weight: var(--typography-headline-m-font-weight);
|
639
|
+
line-height: var(--typography-headline-m-line-height);
|
640
|
+
letter-spacing: var(--typography-headline-m-letter-spacing);
|
641
|
+
}
|
642
|
+
|
643
|
+
:host([s="tl"]) slot {
|
644
|
+
font-size: var(--typography-title-l-font-size);
|
645
|
+
font-weight: var(--typography-title-l-font-weight);
|
646
|
+
line-height: var(--typography-title-l-line-height);
|
647
|
+
letter-spacing: var(--typography-title-l-letter-spacing);
|
648
|
+
}
|
649
|
+
|
650
|
+
:host([s="tm"]) slot {
|
651
|
+
font-size: var(--typography-title-m-font-size);
|
652
|
+
font-weight: var(--typography-title-m-font-weight);
|
653
|
+
line-height: var(--typography-title-m-line-height);
|
654
|
+
letter-spacing: var(--typography-title-m-letter-spacing);
|
655
|
+
}
|
656
|
+
|
657
|
+
:host([s="ts"]) slot {
|
658
|
+
font-size: var(--typography-title-s-font-size);
|
659
|
+
font-weight: var(--typography-title-s-font-weight);
|
660
|
+
line-height: var(--typography-title-s-line-height);
|
661
|
+
letter-spacing: var(--typography-title-s-letter-spacing);
|
662
|
+
}
|
663
|
+
|
664
|
+
:host([s="bl"]) slot {
|
665
|
+
font-size: var(--typography-body-l-font-size);
|
666
|
+
font-weight: var(--typography-body-l-font-weight);
|
667
|
+
line-height: var(--typography-body-l-line-height);
|
668
|
+
letter-spacing: var(--typography-body-l-letter-spacing);
|
669
|
+
}
|
670
|
+
|
671
|
+
:host([s="bm"]) slot {
|
672
|
+
font-size: var(--typography-body-m-font-size);
|
673
|
+
font-weight: var(--typography-body-m-font-weight);
|
674
|
+
line-height: var(--typography-body-m-line-height);
|
675
|
+
letter-spacing: var(--typography-body-m-letter-spacing);
|
676
|
+
}
|
677
|
+
|
678
|
+
:host([s="bs"]) slot {
|
679
|
+
font-size: var(--typography-body-s-font-size);
|
680
|
+
font-weight: var(--typography-body-s-font-weight);
|
681
|
+
line-height: var(--typography-body-s-line-height);
|
682
|
+
letter-spacing: var(--typography-body-s-letter-spacing);
|
683
|
+
}
|
684
|
+
|
685
|
+
:host([s="ll"]) slot {
|
686
|
+
font-size: var(--typography-label-l-font-size);
|
687
|
+
font-weight: var(--typography-label-l-font-weight);
|
688
|
+
line-height: var(--typography-label-l-line-height);
|
689
|
+
letter-spacing: var(--typography-label-l-letter-spacing);
|
690
|
+
}
|
691
|
+
|
692
|
+
:host([s="lm"]) slot {
|
693
|
+
font-size: var(--typography-label-m-font-size);
|
694
|
+
font-weight: var(--typography-label-m-font-weight);
|
695
|
+
line-height: var(--typography-label-m-line-height);
|
696
|
+
letter-spacing: var(--typography-label-m-letter-spacing);
|
697
|
+
}
|
698
|
+
|
699
|
+
${b}
|
700
|
+
${y}
|
701
|
+
`);var J=class extends HTMLElement{constructor(){super();let t=this.attachShadow({mode:"closed"});t.adoptedStyleSheets=[St],x(t,this.render)}render(){return f`
|
702
|
+
<slot></slot>
|
703
|
+
`}},$t=J;var kt=new CSSStyleSheet;kt.replaceSync(g`
|
704
|
+
:host {
|
705
|
+
display: flex;
|
706
|
+
}
|
707
|
+
:host([of="contain"]) img {
|
708
|
+
object-fit: contain;
|
709
|
+
}
|
710
|
+
:host([of="cover"]) img {
|
711
|
+
object-fit: cover;
|
712
|
+
}
|
713
|
+
img {
|
714
|
+
flex: 1;
|
715
|
+
}
|
716
|
+
${b}
|
717
|
+
${y}
|
718
|
+
`);function oo(o){let t=String(o);return/[0-9]$/.test(t)}var Ct=o=>{if(o!==void 0)return oo(o)?`${o}px`:o},K=class extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[kt],setTimeout(()=>{x(this.shadow,this.render)})}static get observedAttributes(){return["src","wh","w","h","of"]}attributeChangedCallback(t,s,e){let r=this.getAttribute("wh"),a=Ct(r===null?this.getAttribute("w"):r),i=Ct(r===null?this.getAttribute("h"):r),n=a?`width: ${a}; min-width: ${a}; max-width: ${a};`:"",d=i?`height: ${i}; min-height: ${i}; max-height: ${i};`:"",u=this.hasAttribute("hidden")?"display: none;":"",p=`${n} ${d} ${u}`;this.style=p,x(this.shadow,this.render)}render=()=>f`
|
719
|
+
<img
|
720
|
+
src="${this.getAttribute("src")}"
|
721
|
+
width="${this.getAttribute("w")}"
|
722
|
+
height="${this.getAttribute("h")}"
|
723
|
+
>
|
724
|
+
`},At=K;var zt=new CSSStyleSheet;zt.replaceSync(g`
|
725
|
+
input[type="text"] {
|
726
|
+
height: 32px;
|
727
|
+
}
|
728
|
+
|
729
|
+
input[type="text"],
|
730
|
+
textarea {
|
731
|
+
padding: 8px 8px;
|
732
|
+
box-sizing: border-box;
|
733
|
+
border: 1px solid var(--color-outline-variant);
|
734
|
+
-webkit-transition: 0.3s;
|
735
|
+
transition: 0.3s;
|
736
|
+
outline: none;
|
737
|
+
|
738
|
+
font-family: Roboto, -apple-system, "Helvetica Neue", sans-serif;
|
739
|
+
font-size: var(--typography-body-m-font-size);
|
740
|
+
font-weight: var(--typography-body-m-font-weight);
|
741
|
+
line-height: var(--typography-body-m-line-height);
|
742
|
+
letter-spacing: var(--typography-body-m-letter-spacing);
|
743
|
+
}
|
744
|
+
|
745
|
+
input[type="text"]:focus,
|
746
|
+
textarea:focus {
|
747
|
+
border: 1px solid var(--color-primary);
|
748
|
+
}
|
749
|
+
textarea {
|
750
|
+
resize: none;
|
751
|
+
}
|
752
|
+
${y}
|
753
|
+
${D}
|
754
|
+
${b}
|
755
|
+
`);var Q=class extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[zt],this._formRef={},setTimeout(()=>{x(this.shadow,this.render)})}_handleRawSubmit=()=>{let t=new FormData(this._formRef.current),s={};for(let[e,r]of t.entries())s[e]=r;this.onClickSubmit&&this.onClickSubmit(s)};_renderTitles=()=>f`
|
756
|
+
${this.formSchema.title?f`<rtgl-text s="tl" c="on-su">${this.formSchema.title}</rtgl-text>`:null}
|
757
|
+
${this.formSchema.subtitle?f`<rtgl-text s="bm" color="on-su"
|
758
|
+
>${this.formSchema.subtitle}</rtgl-text
|
759
|
+
>`:null}
|
760
|
+
`;_renderFields=()=>this.formSchema.fields.map(t=>{let s=null;return t.type==="text"?s=f`<input
|
761
|
+
type="${t.type}"
|
762
|
+
name="${t.name}"
|
763
|
+
value="${t.value}"
|
764
|
+
placeholder="${t.options?.placeholder}"
|
765
|
+
/>`:t.type==="textarea"&&(s=f`<textarea
|
766
|
+
name="${t.name}"
|
767
|
+
value="${t.value}"
|
768
|
+
rows="${t.options?.rows}"
|
769
|
+
placeholder="${t.options?.placeholder}"
|
770
|
+
></textarea>`),f`
|
771
|
+
<rtgl-view d="v" g="s">
|
772
|
+
<rtgl-view d="v">
|
773
|
+
<rtgl-text s="ll" c="on-su">${t.label}</rtgl-text>
|
774
|
+
${t.subLabel?f`<rtgl-text s="lm" c="on-su">${t.subLabel}</rtgl-text>`:null}
|
775
|
+
</rtgl-view>
|
776
|
+
${s}
|
777
|
+
</rtgl-view>
|
778
|
+
`});render=()=>{let t={};return f`
|
779
|
+
<rtgl-view d="v" g="m" w="${this.getAttribute("width")}">
|
780
|
+
<rtgl-view d="v"> ${this._renderTitles()} </rtgl-view>
|
781
|
+
<form
|
782
|
+
ref=${this._formRef}
|
783
|
+
style="display: flex; flex-direction: column;"
|
784
|
+
>
|
785
|
+
<rtgl-view d="v" g="m">
|
786
|
+
${this._renderFields()}
|
787
|
+
<rtgl-button t="p" onclick=${this._handleRawSubmit}>
|
788
|
+
${this.formSchema.submit.label}
|
789
|
+
</rtgl-button>
|
790
|
+
</rtgl-view>
|
791
|
+
</form>
|
792
|
+
</rtgl-view>
|
793
|
+
`}},Nt=Q;var Et=g`
|
794
|
+
:host([pt="xs"]) svg {
|
795
|
+
padding-top: var(--spacing-xs);
|
796
|
+
}
|
797
|
+
:host([pt="s"]) svg {
|
798
|
+
padding-top: var(--spacing-s);
|
799
|
+
}
|
800
|
+
:host([pt="m"]) svg {
|
801
|
+
padding-top: var(--spacing-m);
|
802
|
+
}
|
803
|
+
:host([pt="l"]) svg {
|
804
|
+
padding-top: var(--spacing-l);
|
805
|
+
}
|
806
|
+
:host([pt="xl"]) svg {
|
807
|
+
padding-top: var(--spacing-xl);
|
808
|
+
}
|
809
|
+
:host([pr="xs"]) svg {
|
810
|
+
padding-right: var(--spacing-xs);
|
811
|
+
}
|
812
|
+
:host([pr="s"]) svg {
|
813
|
+
padding-right: var(--spacing-s);
|
814
|
+
}
|
815
|
+
:host([pr="m"]) svg {
|
816
|
+
padding-right: var(--spacing-m);
|
817
|
+
}
|
818
|
+
:host([pr="l"]) svg {
|
819
|
+
padding-right: var(--spacing-l);
|
820
|
+
}
|
821
|
+
:host([pr="xl"]) svg {
|
822
|
+
padding-right: var(--spacing-xl);
|
823
|
+
}
|
824
|
+
:host([pb="xs"]) svg {
|
825
|
+
padding-bottom: var(--spacing-xs);
|
826
|
+
}
|
827
|
+
:host([pb="s"]) svg {
|
828
|
+
padding-bottom: var(--spacing-s);
|
829
|
+
}
|
830
|
+
:host([pb="m"]) svg {
|
831
|
+
padding-bottom: var(--spacing-m);
|
832
|
+
}
|
833
|
+
:host([pb="l"]) svg {
|
834
|
+
padding-bottom: var(--spacing-l);
|
835
|
+
}
|
836
|
+
:host([pb="xl"]) svg {
|
837
|
+
padding-bottom: var(--spacing-xl);
|
838
|
+
}
|
839
|
+
:host([pl="xs"]) svg {
|
840
|
+
padding-left: var(--spacing-xs);
|
841
|
+
}
|
842
|
+
:host([pl="s"]) svg {
|
843
|
+
padding-left: var(--spacing-s);
|
844
|
+
}
|
845
|
+
:host([pl="m"]) svg {
|
846
|
+
padding-left: var(--spacing-m);
|
847
|
+
}
|
848
|
+
:host([pl="l"]) svg {
|
849
|
+
padding-left: var(--spacing-l);
|
850
|
+
}
|
851
|
+
:host([pl="xl"]) svg {
|
852
|
+
padding-left: var(--spacing-xl);
|
853
|
+
}
|
854
|
+
:host([p="xs"]) svg {
|
855
|
+
padding: var(--spacing-xs);
|
856
|
+
}
|
857
|
+
:host([p="s"]) svg {
|
858
|
+
padding: var(--spacing-s);
|
859
|
+
}
|
860
|
+
:host([p="m"]) svg {
|
861
|
+
padding: var(--spacing-m);
|
862
|
+
}
|
863
|
+
:host([p="l"]) svg {
|
864
|
+
padding: var(--spacing-l);
|
865
|
+
}
|
866
|
+
:host([p="xl"]) svg {
|
867
|
+
padding: var(--spacing-xl);
|
868
|
+
}
|
869
|
+
:host([ph="xs"]) svg {
|
870
|
+
padding-left: var(--spacing-xs);
|
871
|
+
padding-right: var(--spacing-xs);
|
872
|
+
}
|
873
|
+
:host([ph="s"]) svg {
|
874
|
+
padding-left: var(--spacing-s);
|
875
|
+
padding-right: var(--spacing-s);
|
876
|
+
}
|
877
|
+
:host([ph="m"]) svg {
|
878
|
+
padding-left: var(--spacing-m);
|
879
|
+
padding-right: var(--spacing-m);
|
880
|
+
}
|
881
|
+
:host([ph="l"]) svg {
|
882
|
+
padding-left: var(--spacing-l);
|
883
|
+
padding-right: var(--spacing-l);
|
884
|
+
}
|
885
|
+
:host([ph="xl"]) svg {
|
886
|
+
padding-left: var(--spacing-xl);
|
887
|
+
padding-right: var(--spacing-xl);
|
888
|
+
}
|
889
|
+
:host([pv="xs"]) svg {
|
890
|
+
padding-top: var(--spacing-xs);
|
891
|
+
padding-bottom: var(--spacing-xs);
|
892
|
+
}
|
893
|
+
:host([pv="s"]) svg {
|
894
|
+
padding-top: var(--spacing-s);
|
895
|
+
padding-bottom: var(--spacing-s);
|
896
|
+
}
|
897
|
+
:host([pv="m"]) svg {
|
898
|
+
padding-top: var(--spacing-m);
|
899
|
+
padding-bottom: var(--spacing-m);
|
900
|
+
}
|
901
|
+
:host([pv="l"]) svg {
|
902
|
+
padding-top: var(--spacing-l);
|
903
|
+
padding-bottom: var(--spacing-l);
|
904
|
+
}
|
905
|
+
:host([pv="xl"]) svg {
|
906
|
+
padding-top: var(--spacing-xl);
|
907
|
+
padding-bottom: var(--spacing-xl);
|
908
|
+
}
|
909
|
+
`;var Mt=new CSSStyleSheet;Mt.replaceSync(g`
|
910
|
+
|
911
|
+
:host([f="p"]) path {
|
912
|
+
fill: var(--color-primary);
|
913
|
+
}
|
914
|
+
:host([f="s"]) path {
|
915
|
+
fill: var(--color-secondary);
|
916
|
+
}
|
917
|
+
:host([f="e"]) path {
|
918
|
+
fill: var(--color-error);
|
919
|
+
}
|
920
|
+
:host([f="on-p"]) path {
|
921
|
+
fill: var(--color-on-primary);
|
922
|
+
}
|
923
|
+
:host([f="on-pc"]) path {
|
924
|
+
fill: var(--color-on-primary-container);
|
925
|
+
}
|
926
|
+
:host([f="on-s"]) path {
|
927
|
+
fill: var(--color-on-secondary);
|
928
|
+
}
|
929
|
+
:host([f="on-sc"]) path {
|
930
|
+
fill: var(--color-on-secondary-container);
|
931
|
+
}
|
932
|
+
:host([f="on-su"]) path {
|
933
|
+
fill: var(--color-on-surface);
|
934
|
+
}
|
935
|
+
:host([f="on-suv"]) path {
|
936
|
+
fill: var(--color-on-surface-variant);
|
937
|
+
}
|
938
|
+
:host([f="i-on-su"]) path {
|
939
|
+
fill: var(--color-inverse-on-surface);
|
940
|
+
}
|
941
|
+
:host([f="on-e"]) path {
|
942
|
+
fill: var(--color-on-error);
|
943
|
+
}
|
944
|
+
:host([f="on-ec"]) path {
|
945
|
+
fill: var(--color-on-error-container);
|
946
|
+
}
|
947
|
+
|
948
|
+
${Et}
|
949
|
+
${b}
|
950
|
+
${y}
|
951
|
+
`);function so(o){let t=String(o);return/[0-9]$/.test(t)}var Tt=o=>{if(o!==void 0)return so(o)?`${o}px`:o},X=class o extends HTMLElement{constructor(){super(),this.shadow=this.attachShadow({mode:"closed"}),this.shadow.adoptedStyleSheets=[Mt],setTimeout(()=>{this.render()})}static _icons={};static get observedAttributes(){return["src","w","h","of","wh"]}static get icons(){return o._icons}static addIcon(t,s){o._icons[t]=s}attributeChangedCallback(t,s,e){let r=this.getAttribute("wh"),a=Tt(r===null?this.getAttribute("w"):r),i=Tt(r===null?this.getAttribute("h"):r),n=a?`width: ${a}; min-width: ${a}; max-width: ${a};`:"",d=i?`height: ${i}; min-height: ${i}; max-height: ${i};`:"",u=this.hasAttribute("hidden")?"display: none;":"",p=`${n} ${d} ${u}`;this.style=p,this.render()}render=()=>{try{let t=this.getAttribute("svg"),s=o._icons[t]||(window.rtglIcons||{})[t];if(s){this.shadow.innerHTML=s;return}}catch(t){console.log("error in rtgl-svg render",t)}this.shadow.innerHTML=""}},Wt=X;customElements.define("rtgl-button",vt);customElements.define("rtgl-view",wt);customElements.define("rtgl-text",$t);customElements.define("rtgl-image",At);customElements.define("rtgl-form",Nt);customElements.define("rtgl-svg",Wt);})();
|
952
|
+
/*! (c) Andrea Giammarchi - MIT */
|
953
|
+
//# sourceMappingURL=rettangoli-ui.min.js.map
|