@stacksjs/stx 0.2.761 → 0.2.762
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/dist/{chunk-jzajpmke.js → chunk-02c46de1.js} +19 -2
- package/dist/{chunk-64pdwfef.js → chunk-05jdq9tw.js} +4 -4
- package/dist/chunk-0cajfv7y.js +2 -0
- package/dist/{chunk-45g1w1ct.js → chunk-0sd4td6z.js} +1 -1
- package/dist/{chunk-yh5658q8.js → chunk-18chz0q4.js} +1 -1
- package/dist/{chunk-jacb7aw1.js → chunk-28vtqwxh.js} +1 -1
- package/dist/{chunk-aa1y9j3p.js → chunk-2eamszdq.js} +1 -1
- package/dist/{chunk-cgh0k52q.js → chunk-2gn6smrq.js} +1 -1
- package/dist/{chunk-yp80rx17.js → chunk-528cn6qm.js} +1 -1
- package/dist/{chunk-61qh74q1.js → chunk-59k4xb92.js} +1 -1
- package/dist/{chunk-803qm5tk.js → chunk-633a53wg.js} +1 -1
- package/dist/chunk-6b737vch.js +2 -0
- package/dist/{chunk-2wnfqrv5.js → chunk-736ex6r5.js} +1 -1
- package/dist/{chunk-ctdw7fh4.js → chunk-8czxtjwm.js} +1 -1
- package/dist/{chunk-frybxj35.js → chunk-932zx5q4.js} +4 -4
- package/dist/chunk-9fh4ah7t.js +2 -0
- package/dist/{chunk-r6yb0540.js → chunk-a222bwpc.js} +2 -2
- package/dist/chunk-a81rt2t4.js +3 -0
- package/dist/{chunk-x7q4tp3f.js → chunk-ben8bjnk.js} +1 -1
- package/dist/{chunk-wmxsaxt0.js → chunk-cenvzm5q.js} +1 -1
- package/dist/{chunk-z5xermzg.js → chunk-d49pst1m.js} +1 -1
- package/dist/{chunk-8vs5y4h7.js → chunk-d96xddt9.js} +1 -1
- package/dist/chunk-dj0qy19b.js +2 -0
- package/dist/{chunk-wghtdgwj.js → chunk-dvpk4c1y.js} +1 -1
- package/dist/{chunk-fys1patf.js → chunk-ebxncrd8.js} +1 -1
- package/dist/{chunk-vv8dn70r.js → chunk-edhxg3rz.js} +2 -2
- package/dist/{chunk-qx0np0hy.js → chunk-epa73jvs.js} +1 -1
- package/dist/{chunk-yjzk7rwt.js → chunk-fhpsf4z7.js} +3 -3
- package/dist/chunk-fht1zs1r.js +2 -0
- package/dist/chunk-fmk9hjht.js +2 -0
- package/dist/{chunk-yhbsvf65.js → chunk-gwjh981q.js} +4 -4
- package/dist/{chunk-jn78c13y.js → chunk-j1tsda22.js} +1 -1
- package/dist/{chunk-emhbj3xd.js → chunk-j1z7tgdp.js} +1 -1
- package/dist/{chunk-7z2mebp5.js → chunk-k469ym7a.js} +1 -1
- package/dist/{chunk-wycrtkw4.js → chunk-k9wr8xf5.js} +1 -1
- package/dist/{chunk-wk8y89q2.js → chunk-m3z13f59.js} +1 -1
- package/dist/{chunk-0q5dm9r2.js → chunk-m6rzsbas.js} +2 -2
- package/dist/{chunk-p88yh4wt.js → chunk-mbe4gqd3.js} +1 -1
- package/dist/{chunk-1a9h6r9f.js → chunk-mdw96yhg.js} +1 -1
- package/dist/{chunk-qyzjkvme.js → chunk-nm9tnxnw.js} +2 -2
- package/dist/{chunk-wq1vs94k.js → chunk-p2se8s6r.js} +1 -1
- package/dist/{chunk-18gazs55.js → chunk-p7zrz0wb.js} +1 -1
- package/dist/chunk-pdnyfk2v.js +2 -0
- package/dist/{chunk-nm2r4se1.js → chunk-qfhjtz2q.js} +1 -1
- package/dist/{chunk-fke4s0kk.js → chunk-qjbcp3tc.js} +1 -1
- package/dist/{chunk-7y1rpd4g.js → chunk-rd33qkfs.js} +2 -2
- package/dist/{chunk-9nhyq39s.js → chunk-rj3p5fdy.js} +1 -1
- package/dist/{chunk-6fz2n9w6.js → chunk-rmk8efc3.js} +5 -5
- package/dist/{chunk-qm3jbse5.js → chunk-rnvrtcz6.js} +1 -1
- package/dist/{chunk-kj9m0vc6.js → chunk-rqd6b2nc.js} +1 -1
- package/dist/{chunk-4c0qcjac.js → chunk-rxm1mjkb.js} +1 -1
- package/dist/{chunk-g9efdc5v.js → chunk-s36cpnxa.js} +1 -1
- package/dist/{chunk-23t9anc0.js → chunk-t1shvfhm.js} +4 -4
- package/dist/{chunk-x1q7b7jg.js → chunk-vttx66q0.js} +1 -1
- package/dist/chunk-vxs07119.js +2 -0
- package/dist/chunk-x8hz5gzb.js +2 -0
- package/dist/{chunk-8jh2b5k2.js → chunk-xfdtym3s.js} +1 -1
- package/dist/{chunk-bjhesw78.js → chunk-xgnmgjpv.js} +1 -1
- package/dist/{chunk-98t1cv8x.js → chunk-xtwc2dbk.js} +1 -1
- package/dist/{chunk-2cbd1ew6.js → chunk-y4mp1rra.js} +6 -6
- package/dist/chunk-y8pftjg8.js +12 -0
- package/dist/{chunk-4rxmxc1p.js → chunk-yb71b2d6.js} +1 -1
- package/dist/{chunk-w512gnft.js → chunk-ycttwgpg.js} +1 -1
- package/dist/chunk-yd6x9226.js +2 -0
- package/dist/{chunk-vvs28yqw.js → chunk-yk456jp4.js} +2 -2
- package/dist/{chunk-r13fwtas.js → chunk-zpjdp0he.js} +1 -1
- package/dist/cli.js +8 -8
- package/dist/client/signals-hydration-audit-runtime.js +2 -0
- package/dist/client/signals-process-element-runtime.js +17 -2
- package/dist/composables/index.d.ts +3 -0
- package/dist/composables/index.js +1 -0
- package/dist/composables/use-completion.d.ts +29 -0
- package/dist/composables/use-completion.js +125 -0
- package/dist/craft-entry.js +1 -1
- package/dist/craft.js +1 -1
- package/dist/pwa.js +1 -1
- package/dist/ssg.js +2 -2
- package/dist/unresolved-identifiers.js +1 -0
- package/package.json +5 -5
- package/dist/chunk-0nynnmya.js +0 -2
- package/dist/chunk-5fg8hqq0.js +0 -2
- package/dist/chunk-7fwcnech.js +0 -2
- package/dist/chunk-927ta2dn.js +0 -2
- package/dist/chunk-c5tkxjb0.js +0 -2
- package/dist/chunk-e5vn76f5.js +0 -2
- package/dist/chunk-gpvfswgj.js +0 -2
- package/dist/chunk-kdqnest3.js +0 -2
- package/dist/chunk-krsg6dgz.js +0 -3
- package/dist/chunk-p2j38381.js +0 -2
- package/dist/chunk-ttqs99jj.js +0 -12
- package/dist/chunk-y5emxzbt.js +0 -2
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import"./chunk-tpfxvw4q.js";import{Ks,Ei,pl}from"./chunk-b51p56k5.js";import"./chunk-4833k99b.js";import"./chunk-2cbd1ew6.js";import"./chunk-x5seqmrv.js";import"./chunk-wghtdgwj.js";import"./chunk-8rk79ha1.js";import"./chunk-f8p8ggvw.js";import{a}from"./chunk-vv8dn70r.js";import"./chunk-evxp3wmv.js";import"./chunk-q3azy64b.js";import"./chunk-4rxmxc1p.js";import{yt,Ke,ye,on,Ae,tr,nr,Ge}from"./chunk-7y1rpd4g.js";import{i}from"./chunk-23t9anc0.js";import"./chunk-bjhesw78.js";import"./chunk-yhbsvf65.js";import{ps}from"./chunk-vvs28yqw.js";import"./chunk-wk8y89q2.js";import"./chunk-b0z2n941.js";import{mt}from"./chunk-jzajpmke.js";import"./chunk-wmnzapn8.js";import"./chunk-61qh74q1.js";import{es}from"./chunk-x7q4tp3f.js";import{Mr}from"./chunk-v1ff2dfp.js";import{Dr,Qs,eo}from"./chunk-qyzjkvme.js";import"./chunk-krsg6dgz.js";import"./chunk-9k8ztdcc.js";import"./chunk-frybxj35.js";import"./chunk-k2ex94n8.js";import"./chunk-kj9m0vc6.js";import{existsSync as _e,mkdirSync as Di,readFileSync as Li}from"fs";import G from"path";import{existsSync as En,mkdirSync as Rn,realpathSync as Ti,rmSync as _n}from"fs";import H from"path";import{existsSync as ui}from"fs";import Z from"path";var Cn="data-stx-b",ft=new Set(Ei),Pn=new Set(Ks);function Oe(e){if(e==="ref"||e==="data-stx-ref")return"ref";if(e.startsWith("::"))return null;if(e.startsWith("@bind:")||e.startsWith("x-bind:"))return"attr";if(e.startsWith("@")||e.startsWith(":")){let t=e.slice(1).split(".")[0];if(ft.has(t))return t==="if"?"if":t;if(t==="for"||t==="else"||t==="else-if"||t==="elseif")return"for";if(pl(t))return"event";if(e.startsWith("@"))return"event";return"attr"}if(e.startsWith("x-")){let t=e.split(".")[0];if(!Pn.has(t))return"attr";let n=t.slice(2);if(n==="cloak"||n==="data"||n==="bind")return null;if(n==="tooltip"||n==="tooltip-position")return null;return ft.has(n)?n==="if"?"if":n:"attr"}return null}function Mn(e){let t=[];for(let[n,r]of e){let s=Oe(n);if(s)t.push({name:n,value:r,kind:s})}return t}var Bn=/<([a-z][\w-]*)((?:\s+[^\s"'=<>/]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s"'=<>`]+))?)*)\s*\/?>/gi,Ee=/([^\s"'=<>/]+)(?:\s*=\s*(?:"([^"]*)"|'([^']*)'|([^\s"'=<>`]+)))?/g;function pt(e){let t=[],n=0;return{html:e.replace(Bn,(s,o,c)=>{if(!c||!/[:@]|x-/.test(c))return s;let l=[];Ee.lastIndex=0;for(let m=Ee.exec(c);m;m=Ee.exec(c))l.push([m[1],m[2]??m[3]??m[4]??""]);let d=Mn(l);if(!d.length)return s;let p={id:n++,bindings:d};if(d.some((m)=>m.kind==="for"))p.template=!0;t.push(p);let h=s.endsWith("/>");return`${s.slice(0,h?-2:-1).trimEnd()} ${Cn}="${p.id}"${h?"/>":">"}`}),manifest:{entries:t}}}import xr from"path";function fe(e){let t=e&&/^(\d+(?:\.\d+)?|\.\d+)(px|rem)?$/.exec(e.trim());if(!t)return;let n=Number(t[1])*(t[2]==="rem"?16:1);return Number.isFinite(n)?n:void 0}function Ie(e,t){if(!ye[e])return;return fe(t?.get(on(e))??ye[e].value)}function Ce(e,t){let n=tr[e];if(!n)return;return fe(t?.get(Ge(n))??Ae[n]?.value)}function Pe(e,t){let n=nr[e];if(!n)return;let r=fe(t?.get(Ge(n.size))??Ae[n.size]?.value),s=fe(t?.get(Ge(n.leading))??Ae[n.leading]?.value);if(r===void 0||s===void 0)return;return{fontSize:r,lineHeight:s}}var Dn={sm:640,md:768,lg:1024,xl:1280,"2xl":1536},vt=Be({}),gt,ht=null;function pe(){let e=globalThis.__stxNativeStyleConfig;if(!e)return vt;if(e!==gt)gt=e,ht=Be(e);return ht}function St(e,t=new Map,n=""){for(let[r,s]of Object.entries(e??{})){let o=r==="DEFAULT"?n.replace(/-$/,""):`${n}${r}`;if(typeof s==="string")t.set(o,s);else if(s&&typeof s==="object")St(s,t,`${o}-`)}return t}function wt(e){let t={};for(let[n,r]of Object.entries(e??{})){let s=typeof r==="number"?r:Number.parseFloat(String(r));if(Number.isFinite(s))t[n]=s}return t}function Be(e){return{shortcuts:new Map(Object.entries(e.shortcuts??{}).filter(([,t])=>typeof t==="string")),colors:St(e.colors),fontFamily:new Map(Object.entries(e.fontFamily??{}).map(([t,n])=>[t,Array.isArray(n)?n.join(", "):n])),breakpoints:new Map(Object.entries({...Dn,...wt(e.breakpoints)}))}}var Me={};function bt(e){Me=e??{},vt=Be(Me)}async function xt(e,t){let n=Me;bt(e);try{return await t()}finally{bt(n)}}function Nt(e){if(!e)return{};let t=e.theme??{},n=Object.fromEntries(Object.entries(e.shortcuts??{}).filter(([,r])=>typeof r==="string"));return{...Object.keys(n).length?{shortcuts:n}:{},...t.fontFamily?{fontFamily:JSON.parse(JSON.stringify(t.fontFamily))}:{},...t.colors?{colors:JSON.parse(JSON.stringify(t.colors))}:{},...t.screens?{breakpoints:wt(t.screens)}:{}}}function kt(e){return pe().shortcuts.get(e)}function Tt(e){return pe().colors.get(e)}function De(e){return pe().breakpoints.get(e)}function ge(e){return pe().fontFamily.get(e)}var _t=/^--[\w\u0080-\uFFFF-]+$/u;function Rt(e,t){if(!/var\(/i.test(e))return e;let n="",r="",s=!1;for(let o=0;o<e.length;o++){let c=e[o];if(c==="\\"){n+=e.slice(o,o+2),o++;continue}if(r){if(n+=c,c===r)r="";continue}if(c==='"'||c==="'"){r=c,n+=c;continue}if(e.slice(o,o+4).toLowerCase()!=="var("||o>0&&/[\w-]/.test(e[o-1])){n+=c;continue}let l=1,d=-1,p="",h=o+4;for(;h<e.length;h++){let y=e[h];if(y==="\\"){h++;continue}if(p){if(y===p)p="";continue}if(y==='"'||y==="'"){p=y;continue}if(y==="(")l++;if(y===")"&&--l===0)break;if(y===","&&l===1&&d===-1)d=h}if(l!==0)return;let f=e.slice(o+4,d===-1?h:d).trim();if(!_t.test(f))return;let m=t(f,d===-1?void 0:e.slice(d+1,h).trim());if(m===void 0||n.length+m.length>65536)return;n+=m,s=!0,o=h}return s&&n.length>65536?void 0:n}function ae(e,t){let n=new Map,r=new Set;for(let[g,u]of e){let w=g.trim();if(!_t.test(w))continue;if(typeof u==="string"||typeof u==="number"&&Number.isFinite(u))n.set(w,String(u).trim())}let s=new Map,o=new Set;for(let[g,u]of n){let w=new Set,b=(N,S=0)=>S>64?void 0:Rt(N,(k,x)=>(w.add(k),x===void 0?"":b(x,S+1)));if(b(u)===void 0)o.add(g);s.set(g,w)}let c=new Map,l=new Map,d=[],p=new Set,h=0;function f(g,u=0){if(u>64){o.add(g);return}c.set(g,h),l.set(g,h++),d.push(g),p.add(g);for(let N of s.get(g)??[]){if(!n.has(N))continue;if(!c.has(N)){if(f(N,u+1),l.has(N))l.set(g,Math.min(l.get(g),l.get(N)))}else if(p.has(N))l.set(g,Math.min(l.get(g),c.get(N)))}if(l.get(g)!==c.get(g))return;let w=[],b;do b=d.pop(),p.delete(b),w.push(b);while(b!==g);if(w.length>1||s.get(g)?.has(g))w.forEach((N)=>o.add(N))}for(let g of n.keys())if(!c.has(g))f(g);let m=new Map;function y(g,u){if(r.add(g),m.has(g))return m.get(g);let w=n.get(g),b=w===void 0||/^(?:inherit|unset)$/i.test(w)?t?.get(g):o.has(g)||/^(?:initial|revert|revert-layer)$/i.test(w)?void 0:v(w,u+1);return m.set(g,b),b}function v(g,u=0){if(u>64)return;return Rt(g,(w,b)=>y(w,u)??(b===void 0?void 0:v(b,u+1)))}return{resolve:v,used:r,computed(){let g=new Map(t);for(let u of n.keys())g.set(u,y(u,0));return g}}}function Le(e){if(e.display==="flex"&&e.flexDirection==null)return{...e,flexDirection:"row"};return e}var At=new Set(["display","gridColumns","gridTemplateColumns","gridTemplateRows","gridAutoRows","flex","flexGrow","flexShrink","flexBasis","flexDirection","flexWrap","order","justifyContent","alignItems","alignSelf","alignContent","position","top","right","bottom","left","zIndex","width","height","minWidth","maxWidth","minHeight","maxHeight","aspectRatio","margin","marginTop","marginRight","marginBottom","marginLeft","marginHorizontal","marginVertical","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingHorizontal","paddingVertical","gap","rowGap","columnGap","borderWidth","borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","borderRadius","borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius","borderStyle","backgroundColor","backgroundImage","opacity","shadowColor","shadowOffset","shadowOpacity","shadowRadius","elevation","color","fontSize","fontWeight","fontStyle","fontFamily","lineHeight","letterSpacing","textAlign","textDecorationLine","textDecorationColor","textTransform","resizeMode","objectFit","objectPosition","tintColor","transform","overflow","pointerEvents","fill","stroke","strokeWidth","gradientDirection","gradientFrom","gradientVia","gradientTo"]),Ln=new Set(["gridColumns","gridAutoRows","flex","flexGrow","flexShrink","order","zIndex","aspectRatio","gap","rowGap","columnGap","borderWidth","borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth","borderRadius","borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius","opacity","shadowOpacity","shadowRadius","elevation","fontSize","lineHeight","letterSpacing","strokeWidth"]),Et=new Set(["top","right","bottom","left","width","height","minWidth","maxWidth","minHeight","maxHeight","flexBasis","margin","marginTop","marginRight","marginBottom","marginLeft","marginHorizontal","marginVertical","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingHorizontal","paddingVertical"]),Ot=/^[+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?$/i,$n=/^([+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?)(px|rem|em)?$/i,jn=new Set(["rotate","rotateX","rotateY","rotateZ","skewX","skewY"]),Vn=new Set(["perspective","scale","scaleX","scaleY","translateX","translateY"]);function Wn(e){if(typeof e!=="string")return e;let t=$n.exec(e);return t?Number(t[1])*(/^r?em$/i.test(t[2]||"")?16:1):e}function ie(e){return typeof e==="number"&&Number.isFinite(e)}function Fn(e,t){if(e==="shadowOffset"&&t&&typeof t==="object"&&!Array.isArray(t)){let{width:n,height:r}=t;return ie(n)&&ie(r)?{width:n,height:r}:void 0}if(e==="transform"&&Array.isArray(t)){let n=[];for(let r of t){if(!r||typeof r!=="object"||Array.isArray(r)||Object.keys(r).length!==1)return;let[s,o]=Object.entries(r)[0];if(Vn.has(s)&&ie(o))n.push({[s]:o});else if(jn.has(s)&&typeof o==="string"&&/^[+-]?(?:\d+\.?\d*|\.\d+)(?:deg|rad)$/.test(o))n.push({[s]:o});else return}return n}return}function Xn(e){let t=[],n=0,r=0,s="";for(let o=0;o<=e.length;o++){let c=e[o];if(c==="\\"){o++;continue}if(s){if(c===s)s="";continue}if(c==='"'||c==="'"){s=c;continue}if(c==="(")r++;if(c===")")r=Math.max(0,r-1);if(o!==e.length&&(c!==";"||r))continue;let l=e.slice(n,o),d=l.indexOf(":");if(d!==-1)t.push([l.slice(0,d).trim(),l.slice(d+1).trim()]);n=o+1}return t}function zn(e,t){let n;if(typeof e==="string"){if(e=e.trim(),!e)return[];try{e=JSON.parse(e)}catch{}}if(typeof e==="string")n=Xn(e);else if(e&&typeof e==="object"&&!Array.isArray(e))n=Object.entries(e);else{if(e!=null&&e!==!1)t({kind:"non-numeric-style",name:"style"});return[]}return n}function he(e,t=()=>{},n={}){let r=zn(e,t),s=ae(r,n.inheritedVariables);return n.onVariables?.(s.computed()),Un(r,s,t)}function Un(e,t,n){let r={},s=[];for(let[o,c]of e){if(o.trim().startsWith("--")){s.push(o.trim());continue}let l=At.has(o)||o.trim().startsWith("--")?o:o.trim().toLowerCase().replace(/-([a-z])/g,(h,f)=>f.toUpperCase());if(!At.has(l)){n({kind:"unknown-style",name:l});continue}if(c==null||c==="")continue;let d=typeof c==="string"?t.resolve(c.trim()):c;if(d===void 0){n({kind:"non-numeric-style",name:l});continue}if(d==="")continue;if(l==="pointerEvents"){if(typeof d==="string"&&["auto","none","box-none","box-only"].includes(d))r.pointerEvents=d;else n({kind:"unknown-style",name:`pointerEvents:${String(d)}`});continue}if(l==="objectFit"){let h=typeof d==="string"?d.trim().toLowerCase():"";if(["fill","contain","cover","none","scale-down"].includes(h))r.objectFit=h;else n({kind:"unknown-style",name:`objectFit:${String(d)}`});continue}if(l==="objectPosition"){let h=typeof d==="string"?d.trim().toLowerCase().replace(/\s+/g," "):"",f=h.split(" ");if(f.length===1)f.push("center");if(["top","bottom"].includes(f[0])||["left","right"].includes(f[1]))f.reverse();let m=(y)=>y.endsWith("%")&&Ot.test(y.slice(0,-1))&&Number.isFinite(Number(y.slice(0,-1)));if(f.length===2&&(["left","center","right"].includes(f[0])||m(f[0]))&&(["top","center","bottom"].includes(f[1])||m(f[1])))r.objectPosition=h;else n({kind:"unknown-style",name:`objectPosition:${String(d)}`});continue}let p;if(Ln.has(l)||Et.has(l)){if(p=Wn(d),!ie(p)&&!(Et.has(l)&&typeof p==="string"&&p.endsWith("%")&&Ot.test(p.slice(0,-1))&&Number.isFinite(Number(p.slice(0,-1)))))p=void 0}else if(l==="display"&&d==="inline-flex")p="flex";else if(l==="shadowOffset"||l==="transform")p=Fn(l,d);else if(l==="gridTemplateColumns"||l==="gridTemplateRows")p=ie(d)||typeof d==="string"?d:void 0;else if(l==="fontWeight"&&ie(d))p=String(d);else if(typeof d==="string")p=d;if(p===void 0)n({kind:"non-numeric-style",name:l});else r[l]=p}for(let o of s)if(!t.used.has(o))n({kind:"unknown-style",name:o});return r}var Hn={transparent:"transparent",current:"currentColor",black:"#000000",white:"#ffffff",slate:{50:"#f8fafc",100:"#f1f5f9",200:"#e2e8f0",300:"#cbd5e1",400:"#94a3b8",500:"#64748b",600:"#475569",700:"#334155",800:"#1e293b",900:"#0f172a",950:"#020617"},gray:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#1f2937",900:"#111827",950:"#030712"},zinc:{50:"#fafafa",100:"#f4f4f5",200:"#e4e4e7",300:"#d4d4d8",400:"#a1a1aa",500:"#71717a",600:"#52525b",700:"#3f3f46",800:"#27272a",900:"#18181b",950:"#09090b"},red:{50:"#fef2f2",100:"#fee2e2",200:"#fecaca",300:"#fca5a5",400:"#f87171",500:"#ef4444",600:"#dc2626",700:"#b91c1c",800:"#991b1b",900:"#7f1d1d",950:"#450a0a"},orange:{50:"#fff7ed",100:"#ffedd5",200:"#fed7aa",300:"#fdba74",400:"#fb923c",500:"#f97316",600:"#ea580c",700:"#c2410c",800:"#9a3412",900:"#7c2d12",950:"#431407"},amber:{50:"#fffbeb",100:"#fef3c7",200:"#fde68a",300:"#fcd34d",400:"#fbbf24",500:"#f59e0b",600:"#d97706",700:"#b45309",800:"#92400e",900:"#78350f",950:"#451a03"},yellow:{50:"#fefce8",100:"#fef9c3",200:"#fef08a",300:"#fde047",400:"#facc15",500:"#eab308",600:"#ca8a04",700:"#a16207",800:"#854d0e",900:"#713f12",950:"#422006"},green:{50:"#f0fdf4",100:"#dcfce7",200:"#bbf7d0",300:"#86efac",400:"#4ade80",500:"#22c55e",600:"#16a34a",700:"#15803d",800:"#166534",900:"#14532d",950:"#052e16"},emerald:{50:"#ecfdf5",100:"#d1fae5",200:"#a7f3d0",300:"#6ee7b7",400:"#34d399",500:"#10b981",600:"#059669",700:"#047857",800:"#065f46",900:"#064e3b",950:"#022c22"},teal:{50:"#f0fdfa",100:"#ccfbf1",200:"#99f6e4",300:"#5eead4",400:"#2dd4bf",500:"#14b8a6",600:"#0d9488",700:"#0f766e",800:"#115e59",900:"#134e4a",950:"#042f2e"},cyan:{50:"#ecfeff",100:"#cffafe",200:"#a5f3fc",300:"#67e8f9",400:"#22d3ee",500:"#06b6d4",600:"#0891b2",700:"#0e7490",800:"#155e75",900:"#164e63",950:"#083344"},sky:{50:"#f0f9ff",100:"#e0f2fe",200:"#bae6fd",300:"#7dd3fc",400:"#38bdf8",500:"#0ea5e9",600:"#0284c7",700:"#0369a1",800:"#075985",900:"#0c4a6e",950:"#082f49"},lime:{50:"#f7fee7",100:"#ecfccb",200:"#d9f99d",300:"#bef264",400:"#a3e635",500:"#84cc16",600:"#65a30d",700:"#4d7c0f",800:"#3f6212",900:"#365314",950:"#1a2e05"},fuchsia:{50:"#fdf4ff",100:"#fae8ff",200:"#f5d0fe",300:"#f0abfc",400:"#e879f9",500:"#d946ef",600:"#c026d3",700:"#a21caf",800:"#86198f",900:"#701a75",950:"#4a044e"},neutral:{50:"#fafafa",100:"#f5f5f5",200:"#e5e5e5",300:"#d4d4d4",400:"#a3a3a3",500:"#737373",600:"#525252",700:"#404040",800:"#262626",900:"#171717",950:"#0a0a0a"},stone:{50:"#fafaf9",100:"#f5f5f4",200:"#e7e5e4",300:"#d6d3d1",400:"#a8a29e",500:"#78716c",600:"#57534e",700:"#44403c",800:"#292524",900:"#1c1917",950:"#0c0a09"},blue:{50:"#eff6ff",100:"#dbeafe",200:"#bfdbfe",300:"#93c5fd",400:"#60a5fa",500:"#3b82f6",600:"#2563eb",700:"#1d4ed8",800:"#1e40af",900:"#1e3a8a",950:"#172554"},indigo:{50:"#eef2ff",100:"#e0e7ff",200:"#c7d2fe",300:"#a5b4fc",400:"#818cf8",500:"#6366f1",600:"#4f46e5",700:"#4338ca",800:"#3730a3",900:"#312e81",950:"#1e1b4b"},violet:{50:"#f5f3ff",100:"#ede9fe",200:"#ddd6fe",300:"#c4b5fd",400:"#a78bfa",500:"#8b5cf6",600:"#7c3aed",700:"#6d28d9",800:"#5b21b6",900:"#4c1d95",950:"#2e1065"},purple:{50:"#faf5ff",100:"#f3e8ff",200:"#e9d5ff",300:"#d8b4fe",400:"#c084fc",500:"#a855f7",600:"#9333ea",700:"#7e22ce",800:"#6b21a8",900:"#581c87",950:"#3b0764"},pink:{50:"#fdf2f8",100:"#fce7f3",200:"#fbcfe8",300:"#f9a8d4",400:"#f472b6",500:"#ec4899",600:"#db2777",700:"#be185d",800:"#9d174d",900:"#831843",950:"#500724"},rose:{50:"#fff1f2",100:"#ffe4e6",200:"#fecdd3",300:"#fda4af",400:"#fb7185",500:"#f43f5e",600:"#e11d48",700:"#be123c",800:"#9f1239",900:"#881337",950:"#4c0519"}},je={px:1,0:0,0.5:2,1:4,1.5:6,2:8,2.5:10,3:12,3.5:14,4:16,5:20,6:24,7:28,8:32,9:36,10:40,11:44,12:48,14:56,16:64,20:80,24:96,28:112,32:128,36:144,40:160,44:176,48:192,52:208,56:224,60:240,64:256,72:288,80:320,96:384},It={xs:12,sm:14,base:16,lg:18,xl:20,"2xl":24,"3xl":30,"4xl":36,"5xl":48,"6xl":60,"7xl":72,"8xl":96,"9xl":128},Ct={none:0,sm:2,DEFAULT:4,md:6,lg:8,xl:12,"2xl":16,"3xl":24,full:9999};function ne(e){let t=e.lastIndexOf("/");if(t>0&&(!e.endsWith("]")||/\/\[[\d.]+%?\]$/.test(e))){let r=ne(e.slice(0,t)),s=e.slice(t+1),o=/^\[(.+)\]$/.test(s)?Number.parseFloat(s.slice(1,-1))*(s.includes("%")?1:100):Number.parseFloat(s);if(!r||!Number.isFinite(o))return;return qn(r,o/100)}if(e==="transparent")return"transparent";if(e==="current")return"currentColor";if(e==="black")return"#000000";if(e==="white")return"#ffffff";let n=e.split("-");if(n.length===2){let[r,s]=n,o=Hn[r];if(o&&typeof o==="object")return o[s]}if(e.startsWith("[")&&e.endsWith("]")){let r=e.slice(1,-1);return/^(#|rgba?\(|hsla?\(|[a-z]+$)/i.test(r)?r:void 0}return}function Ve(e){return ne(e.trim())}function qn(e,t){if(e==="transparent")return e;let n=e.startsWith("#")?e.slice(1):"";if(n.length===3)n=n.split("").map((s)=>s+s).join("");if(n.length===8)n=n.slice(0,6);if(n.length!==6)return;let r=Math.round(Math.min(1,Math.max(0,t))*255);return`#${n}${r.toString(16).padStart(2,"0")}`}function $e(e,t=16){if(!e.startsWith("[")||!e.endsWith("]"))return;let n=e.slice(1,-1),r=Number.parseFloat(n);if(!Number.isFinite(r))return;if(n.endsWith("rem"))return r*16;if(n.endsWith("em"))return r*t;return r}function X(e){if(e.startsWith("[")&&e.endsWith("]")){let t=e.slice(1,-1);if(t.endsWith("%"))return;let n=t.endsWith("rem")?Number.parseFloat(t)*16:Number.parseFloat(t);return Number.isFinite(n)?n:void 0}return je[e]??Ce(e)}function be(e){let t=/^\[(-?\d*\.?\d+)%\]$/.exec(e);if(t)return`${Number.parseFloat(t[1])}%`;return X(e)}var Gn={flex:(e,t)=>(t.display="flex",!0),block:(e,t)=>(t.display="flex",!0),hidden:(e,t)=>(t.display="none",!0),grid:(e,t)=>(t.display="grid",!0),"flex-row":(e,t)=>(t.flexDirection="row",!0),"flex-col":(e,t)=>(t.flexDirection="column",!0),"flex-row-reverse":(e,t)=>(t.flexDirection="row-reverse",!0),"flex-col-reverse":(e,t)=>(t.flexDirection="column-reverse",!0),"flex-wrap":(e,t)=>(t.flexWrap="wrap",!0),"flex-nowrap":(e,t)=>(t.flexWrap="nowrap",!0),"flex-wrap-reverse":(e,t)=>(t.flexWrap="wrap-reverse",!0),"flex-1":(e,t)=>(t.flex=1,t.flexGrow=1,t.flexShrink=1,t.flexBasis=0,!0),"flex-auto":(e,t)=>(t.flexGrow=1,t.flexShrink=1,!0),"flex-initial":(e,t)=>(t.flexGrow=0,t.flexShrink=1,!0),"flex-none":(e,t)=>(t.flexGrow=0,t.flexShrink=0,!0),grow:(e,t)=>(t.flexGrow=1,!0),"grow-0":(e,t)=>(t.flexGrow=0,!0),shrink:(e,t)=>(t.flexShrink=1,!0),"shrink-0":(e,t)=>(t.flexShrink=0,!0),"order-first":(e,t)=>(t.order=-9999,!0),"order-last":(e,t)=>(t.order=9999,!0),"order-none":(e,t)=>(t.order=0,!0),"justify-start":(e,t)=>(t.justifyContent="flex-start",!0),"justify-center":(e,t)=>(t.justifyContent="center",!0),"justify-end":(e,t)=>(t.justifyContent="flex-end",!0),"justify-between":(e,t)=>(t.justifyContent="space-between",!0),"justify-around":(e,t)=>(t.justifyContent="space-around",!0),"justify-evenly":(e,t)=>(t.justifyContent="space-evenly",!0),"items-start":(e,t)=>(t.alignItems="flex-start",!0),"items-center":(e,t)=>(t.alignItems="center",!0),"items-end":(e,t)=>(t.alignItems="flex-end",!0),"items-stretch":(e,t)=>(t.alignItems="stretch",!0),"items-baseline":(e,t)=>(t.alignItems="baseline",!0),"self-auto":(e,t)=>(t.alignSelf="auto",!0),"self-start":(e,t)=>(t.alignSelf="flex-start",!0),"self-center":(e,t)=>(t.alignSelf="center",!0),"self-end":(e,t)=>(t.alignSelf="flex-end",!0),"self-stretch":(e,t)=>(t.alignSelf="stretch",!0),"self-baseline":(e,t)=>(t.alignSelf="baseline",!0),"min-w-0":(e,t)=>(t.minWidth=0,!0),"aspect-square":(e,t)=>(t.aspectRatio=1,!0),"aspect-video":(e,t)=>(t.aspectRatio=1.7777777777777777,!0),"border-solid":(e,t)=>(t.borderStyle="solid",!0),"border-dashed":(e,t)=>(t.borderStyle="dashed",!0),"border-dotted":(e,t)=>(t.borderStyle="dotted",!0),group:()=>!0,peer:()=>!0,"inset-0":(e,t)=>(t.top=0,t.right=0,t.bottom=0,t.left=0,!0),"mx-auto":(e,t)=>(t.alignSelf="center",!0),fixed:(e,t)=>(t.position="absolute",!0),sticky:()=>!0,"sr-only":(e,t)=>(t.position="absolute",t.width=1,t.height=1,t.overflow="hidden",!0),inline:()=>!0,"inline-block":()=>!0,contents:()=>!0,"align-top":()=>!0,"align-middle":()=>!0,"align-bottom":()=>!0,"align-baseline":()=>!0,"align-text-top":()=>!0,"whitespace-normal":()=>!0,"whitespace-pre":()=>!0,"whitespace-pre-line":()=>!0,"whitespace-pre-wrap":()=>!0,"whitespace-nowrap":()=>!0,"break-words":()=>!0,"break-all":()=>!0,"break-normal":()=>!0,"object-cover":()=>!0,"object-contain":()=>!0,"object-fill":()=>!0,"object-center":()=>!0,"tracking-tighter":(e,t)=>(t.letterSpacing=-0.8,!0),"tracking-tight":(e,t)=>(t.letterSpacing=-0.4,!0),"tracking-normal":(e,t)=>(t.letterSpacing=0,!0),"tracking-wide":(e,t)=>(t.letterSpacing=0.4,!0),"tracking-wider":(e,t)=>(t.letterSpacing=0.8,!0),"tracking-widest":(e,t)=>(t.letterSpacing=1.6,!0),"tabular-nums":()=>!0,"inline-flex":(e,t)=>(t.display="flex",!0),truncate:()=>!0,relative:(e,t)=>(t.position="relative",!0),absolute:(e,t)=>(t.position="absolute",!0),"pointer-events-none":(e,t)=>(t.pointerEvents="none",!0),"pointer-events-auto":(e,t)=>(t.pointerEvents="auto",!0),"overflow-visible":(e,t)=>(t.overflow="visible",!0),"overflow-hidden":(e,t)=>(t.overflow="hidden",!0),"overflow-scroll":(e,t)=>(t.overflow="scroll",!0),"overflow-x-auto":()=>!0,"overflow-x-scroll":()=>!0,"overflow-y-auto":()=>!0,"overflow-y-scroll":()=>!0,"font-sans":(e,t)=>(t.fontFamily=ge("sans")??"sans-serif",!0),"font-serif":(e,t)=>(t.fontFamily=ge("serif")??"serif",!0),"font-mono":(e,t)=>(t.fontFamily=ge("mono")??"monospace",!0),"font-thin":(e,t)=>(t.fontWeight="100",!0),"font-extralight":(e,t)=>(t.fontWeight="200",!0),"font-light":(e,t)=>(t.fontWeight="300",!0),"font-normal":(e,t)=>(t.fontWeight="400",!0),"font-medium":(e,t)=>(t.fontWeight="500",!0),"font-semibold":(e,t)=>(t.fontWeight="600",!0),"font-bold":(e,t)=>(t.fontWeight="bold",!0),"font-extrabold":(e,t)=>(t.fontWeight="800",!0),"font-black":(e,t)=>(t.fontWeight="900",!0),italic:(e,t)=>(t.fontStyle="italic",!0),"not-italic":(e,t)=>(t.fontStyle="normal",!0),"text-left":(e,t)=>(t.textAlign="left",!0),"text-center":(e,t)=>(t.textAlign="center",!0),"text-right":(e,t)=>(t.textAlign="right",!0),"text-justify":(e,t)=>(t.textAlign="justify",!0),uppercase:(e,t)=>(t.textTransform="uppercase",!0),lowercase:(e,t)=>(t.textTransform="lowercase",!0),capitalize:(e,t)=>(t.textTransform="capitalize",!0),"normal-case":(e,t)=>(t.textTransform="none",!0),underline:(e,t)=>(t.textDecorationLine="underline",!0),"line-through":(e,t)=>(t.textDecorationLine="line-through",!0),"no-underline":(e,t)=>(t.textDecorationLine="none",!0)};function Jn(e,t){if(!e.startsWith("bg-"))return!1;let n=e.slice(3),r=ne(n);if(r)return t.backgroundColor=r,!0;return!1}function Pt(e,t){if(!e.startsWith("text-"))return!1;let n=e.slice(5),r=Pe(n);if(r)return Object.assign(t,r),!0;if(It[n])return t.fontSize=It[n],!0;if(n.startsWith("[")&&n.endsWith("]")){let o=n.slice(1,-1);if(/^-?[\d.]+(?:px|r?em)?$/.test(o)){let c=o.endsWith("rem")||o.endsWith("em")?Number.parseFloat(o)*16:Number.parseFloat(o);if(Number.isFinite(c))return t.fontSize=c,!0}}let s=ne(n);if(s)return t.color=s,!0;return!1}var Kn=new Set(["t","tr","r","br","b","bl","l","tl"]);function Yn(e,t){let n=/^bg-(?:gradient|linear)-to-([a-z]+)$/.exec(e);if(n&&Kn.has(n[1]))return t.gradientDirection=`to-${n[1]}`,!0;let r=/^(from|via|to)-(.+)$/.exec(e);if(!r)return!1;let s=ne(r[2]);if(!s)return!1;if(r[1]==="from")t.gradientFrom=s;else if(r[1]==="via")t.gradientVia=s;else t.gradientTo=s;return!0}function Qn(e,t){for(let n of["fill","stroke"]){let r=`${n}-`;if(!e.startsWith(r))continue;let s=e.slice(r.length);if(s==="none")return t[n]="none",!0;if(n==="stroke"&&/^\d+(?:\.\d+)?$/.test(s))return t.strokeWidth=Number.parseFloat(s),!0;if(n==="stroke"&&/^\[\d+(?:\.\d+)?(?:px)?\]$/.test(s))return t.strokeWidth=Number.parseFloat(s.slice(1)),!0;let o=ne(s);if(o)return t[n]=o,!0}return!1}function Zn(e,t){if(e.startsWith("p-")){let n=X(e.slice(2));if(n!==void 0)return t.padding=n,!0}if(e.startsWith("px-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingHorizontal=n,!0}if(e.startsWith("py-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingVertical=n,!0}if(e.startsWith("pt-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingTop=n,!0}if(e.startsWith("pr-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingRight=n,!0}if(e.startsWith("pb-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingBottom=n,!0}if(e.startsWith("pl-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingLeft=n,!0}return!1}function Bt(e,t){if(/^-(?:m|mx|my|mt|mr|mb|ml)-/.test(e)){let n={};if(!Bt(e.slice(1),n))return!1;let r=Object.entries(n);if(r.some(([,s])=>typeof s!=="number"))return!1;for(let[s,o]of r)t[s]=-o;return!0}if(e.startsWith("m-")){let n=X(e.slice(2));if(n!==void 0)return t.margin=n,!0}if(e.startsWith("mx-")){let n=X(e.slice(3));if(n!==void 0)return t.marginHorizontal=n,!0}if(e.startsWith("my-")){let n=X(e.slice(3));if(n!==void 0)return t.marginVertical=n,!0}if(e.startsWith("mt-")){let n=X(e.slice(3));if(n!==void 0)return t.marginTop=n,!0}if(e.startsWith("mr-")){let n=X(e.slice(3));if(n!==void 0)return t.marginRight=n,!0}if(e.startsWith("mb-")){let n=X(e.slice(3));if(n!==void 0)return t.marginBottom=n,!0}if(e.startsWith("ml-")){let n=X(e.slice(3));if(n!==void 0)return t.marginLeft=n,!0}return!1}function er(e,t){if(!e.startsWith("w-"))return!1;let n=e.slice(2);if(n==="full")return t.width="100%",!0;if(n==="screen")return t.width="100%",!0;if(n==="auto")return t.width="auto",!0;if(n.includes("/")){let[s,o]=n.split("/"),c=Number.parseInt(s)/Number.parseInt(o)*100;return t.width=`${c}%`,!0}let r=be(n);if(r!==void 0)return t.width=r,!0;return!1}function rr(e,t){if(!e.startsWith("h-"))return!1;let n=e.slice(2);if(n==="full")return t.height="100%",!0;if(n==="screen")return t.height="100%",!0;if(n==="auto")return t.height="auto",!0;let r=be(n);if(r!==void 0)return t.height=r,!0;return!1}function ir(e,t){if(e==="rounded")return t.borderRadius=Ct.DEFAULT,!0;if(!e.startsWith("rounded-"))return!1;let n=e.slice(8);if(n==="")return!1;let r=/^(?:(tl|tr|bl|br|t|b|l|r)-)?(.+)$/.exec(n),s=Ct[r[2]]??Ie(r[2])??$e(r[2]);if(s===void 0)return!1;let o={t:["borderTopLeftRadius","borderTopRightRadius"],b:["borderBottomLeftRadius","borderBottomRightRadius"],l:["borderTopLeftRadius","borderBottomLeftRadius"],r:["borderTopRightRadius","borderBottomRightRadius"],tl:["borderTopLeftRadius"],tr:["borderTopRightRadius"],bl:["borderBottomLeftRadius"],br:["borderBottomRightRadius"]};for(let c of r[1]?o[r[1]]:["borderRadius"])t[c]=s;return!0}function sr(e,t){let n=/^border(?:-([trblxy]))?(?:-(\d+|\[[^\]]+\]))?$/.exec(e);if(!n)return!1;let[,r="",s]=n,o=s===void 0?1:Number(s);if(s?.startsWith("[")){let l=/^\[(\d+(?:\.\d+)?|\.\d+)(px|rem)?\]$/.exec(s);if(!l)return!1;o=Number(l[1])*(l[2]==="rem"?16:1)}if(!Number.isFinite(o)||o<0)return!1;let c={"":["borderWidth"],t:["borderTopWidth"],r:["borderRightWidth"],b:["borderBottomWidth"],l:["borderLeftWidth"],x:["borderLeftWidth","borderRightWidth"],y:["borderTopWidth","borderBottomWidth"]};for(let l of c[r])t[l]=o;return!0}function or(e,t){if(!e.startsWith("border-"))return!1;let n=e.slice(7),r=ne(n);if(r)return t.borderColor=r,!0;return!1}function ar(e,t){if(!e.startsWith("opacity-"))return!1;let n=Number.parseInt(e.slice(8));if(!Number.isNaN(n))return t.opacity=n/100,!0;return!1}function cr(e,t,n){if(e.startsWith("tracking-[")){let r=$e(e.slice(9),n);if(r===void 0)return!1;return t.letterSpacing=r,!0}if(e.startsWith("leading-")){let r=e.slice(8),s=n,o={none:1,tight:1.25,snug:1.375,normal:1.5,relaxed:1.625,loose:2},c=r.startsWith("[")?/^\[[\d.]+\]$/.test(r)?Number.parseFloat(r.slice(1,-1))*s:$e(r,s):o[r]!==void 0?o[r]*s:je[r];if(c===void 0||!Number.isFinite(c))return!1;return t.lineHeight=c,!0}return!1}function lr(e,t){let n=/^(-?)(inset-x|inset-y|inset|top|right|bottom|left)-(.+)$/.exec(e);if(!n)return!1;let r=n[3],s=/^\[(-?[\d.]+)px\]$/.exec(r),o=s?Number(s[1]):je[r];if(o===void 0||!Number.isFinite(o))return!1;let c=n[1]?-o:o,l=n[2]==="inset"?["top","right","bottom","left"]:n[2]==="inset-x"?["left","right"]:n[2]==="inset-y"?["top","bottom"]:[n[2]];for(let d of l)t[d]=c;return!0}function ur(e,t){let n=/^grid-cols-\[(.+)\]$/.exec(e);if(n)return t.gridColumns=n[1].split("_").filter(Boolean).length,!0;let r=/^grid-cols-(\d+)$/.exec(e);if(!r)return!1;return t.gridColumns=Number(r[1]),!0}function dr(e,t){if(!e.startsWith("size-"))return!1;let n=e.slice(5),r=n==="full"?"100%":be(n);if(r===void 0)return!1;return t.width=r,t.height=r,!0}var fr={xs:320,sm:384,md:448,lg:512,xl:576,"2xl":672,"3xl":768,"4xl":896,"5xl":1024,"6xl":1152,"7xl":1280};function pr(e,t){let n=/^(min|max)-(w|h)-(.+)$/.exec(e);if(!n)return!1;let[,r,s,o]=n,c=o==="full"||o==="screen"?"100%":o==="none"?void 0:s==="w"&&r==="max"&&fr[o]||be(o);if(c===void 0&&o!=="none")return!1;let l=`${r}${s==="w"?"Width":"Height"}`;if(c===void 0)delete t[l];else t[l]=c;return!0}function gr(e,t){let n=/^(-?)(top|right|bottom|left)-(.+)$/.exec(e);if(!n)return!1;let r=n[3]==="full"?"100%":X(n[3]);if(r===void 0)return!1;return t[n[2]]=typeof r==="number"&&n[1]?-r:r,!0}function hr(e,t){let n=/^(-?)translate-(x|y)-(.+)$/.exec(e);if(!n)return!1;let r=n[3],s;if(r.startsWith("[")){let l=/^\[([+-]?(?:\d+\.?\d*|\.\d+))(px|rem|em)?\]$/.exec(r);if(!l)return!1;s=Number(l[1])*(l[2]?.endsWith("em")?16:1)}else s=X(r);if(s===void 0||!Number.isFinite(s))return!1;if(n[1])s=-s;let o=n[2]==="x"?"translateX":"translateY",c=o==="translateX"?{translateX:s}:{translateY:s};return t.transform=[...(t.transform??[]).filter((l)=>!(o in l)),c],!0}function mr(e,t){let n=/^space-(x|y)-(.+)$/.exec(e);if(!n)return!1;let r=X(n[2]);if(r===void 0)return!1;return t.gap=r,!0}function yr(e,t){if(e.startsWith("gap-")){let n=X(e.slice(4));if(n!==void 0)return t.gap=n,!0}if(e.startsWith("gap-x-")){let n=X(e.slice(6));if(n!==void 0)return t.columnGap=n,!0}if(e.startsWith("gap-y-")){let n=X(e.slice(6));if(n!==void 0)return t.rowGap=n,!0}return!1}function br(e,t){let r={"shadow-none":[0,0,0,0],"shadow-xs":[1,1,0.05,1],"shadow-sm":[2,1,0.1,2],shadow:[3,2,0.12,3],"shadow-md":[6,4,0.15,4],"shadow-lg":[10,6,0.18,8],"shadow-xl":[16,10,0.2,12],"shadow-2xl":[24,16,0.25,18]}[e];if(!r)return!1;let[s,o,c,l]=r;return Object.assign(t,{shadowColor:"#000000",shadowOpacity:c,shadowRadius:s,shadowOffset:{width:0,height:o},elevation:l}),!0}function vr(e){let t=/^divide-(?:(y|x)(?:-(.+))?|(.+))$/.exec(e);if(!t)return null;if(t[2]==="reverse")return"";if(t[1])return`border-${t[1]==="y"?"t":"l"}${t[2]?`-${t[2]}`:""}`;return`border-${t[3]}`}var Dt=new Set(["aria-selected","aria-pressed","aria-checked","aria-expanded"]),Sr=new Set(["hover","group-hover","peer-hover","active","group-active","visited","placeholder","selection","print","motion-safe"]),wr=/^(?:transition(?:-[a-z]+)?|animate-\S+|scroll-[mp][trblxyse]?-\S+|snap-\S+|overscroll-\S+|duration-\S+|ease-\S+|delay-\S+|will-change-\S+|cursor-\S+|select-(?:none|text|all|auto)|outline-none|outline-0|appearance-none|scroll-smooth|scroll-auto|antialiased|subpixel-antialiased|touch-\S+|resize(?:-\S+)?|backdrop-blur(?:-\S+)?|isolate|contain-\S+)$/;function Lt(e){let t=[],n=0,r=0;for(let s=0;s<e.length;s++){let o=e[s];if(o==="[")n++;else if(o==="]")n=Math.max(0,n-1);else if(o===":"&&n===0)t.push(e.slice(r,s)),r=s+1}return t.push(e.slice(r)),t}function $t(e,t=new Set){let n=Lt(e),r=n[n.length-1],s=t.has(r)?void 0:kt(r);if(s===void 0)return[e];let o=n.slice(0,-1).map((l)=>`${l}:`).join(""),c=new Set(t).add(r);return s.split(/\s+/).filter(Boolean).flatMap((l)=>$t(`${o}${l}`,c))}function ve(e,t,n={}){let r=new Map,s=(v,g)=>{if(!r.has(v))r.set(v,{...g,classes:[],authored:new Map});return r.get(v)};s("base",{});let o=[],c=[],l=e.split(/\s+/).filter(Boolean);if(n.rules){let v=new Set(l);for(let g of Object.keys(n.rules))if(g.includes(".")&&g.split(".").every((u)=>v.has(u)))c.push(g);c.sort((g,u)=>g.split(".").length-u.split(".").length)}for(let v of l){if(n.rules&&Object.hasOwn(n.rules,v)){o.push(v);continue}for(let g of $t(v)){let u=Lt(g),w=u.pop(),b=u.some((C)=>C.startsWith("focus"));if(u.some((C)=>/^(?:group-|peer-)?focus(?:-visible|-within)?$/.test(C))&&/^(?:ring|outline)(?:-|$)/.test(w))continue;if(wr.test(w)||!b&&u.some((C)=>Sr.has(C)))continue;let N,S,k=!1,x,A=[];for(let C of u){let E=De(C),O=C.startsWith("max-")?De(C.slice(4)):void 0;if(E!==void 0&&N===void 0)N=E;else if(O!==void 0&&S===void 0)S=O-0.02;else if(C==="disabled"&&!k)k=!0;else if(Dt.has(C)&&x===void 0)x=C;else A.push(C)}let M=[...A,w].join(":"),j=N!==void 0||S!==void 0,_=k?s("disabled",{disabled:!0}):x?s(`state:${x}`,{state:x}):j?s(`range:${N??0}:${S??""}`,{min:N??0,max:S}):r.get("base");if((k||x)&&(j||k&&x)){r.get("base").authored.set(g,v),r.get("base").classes.push(g);continue}if(_.classes.push(M),!_.authored.has(M))_.authored.set(M,v===g?g:`${v} (${g})`)}}let d=[...o,...c],p=(v,g)=>g.map((u)=>v.authored.get(u)??u),h=r.get("base"),f=me(h.classes.join(" "),t,n),m=new Map;if(d.length){let v=(w)=>w?he(w,()=>{},{inheritedVariables:t}):{},g={},u={};for(let w of d){let b=n.rules[w];g={...g,...v(b.light)},u={...u,...v(b.dark)};for(let N of b.responsive??[]){let S=`${N.min}:${N.max??""}`,k=m.get(S)??{min:N.min,...N.max===void 0?{}:{max:N.max},style:{}};if(k.style={...k.style,...v(N.light)},N.dark)k.dark={...k.dark,...v(N.dark)};m.set(S,k)}}if(f.style={...g,...f.style},Object.keys(u).length)f.dark={...u,...f.dark}}f.unknown=p(h,f.unknown);let y=[];for(let v of r.values()){if(v===h)continue;let g=me(v.classes.join(" "),t,{appearance:n.appearance});f.unknown=[...new Set([...f.unknown,...p(v,g.unknown)])];let u={style:g.style,...g.dark?{dark:g.dark}:{}};if(v.disabled)f.disabled=u;else if(v.state)(f.states??={})[v.state]=u;else y.push({min:v.min??0,...v.max===void 0?{}:{max:v.max},...u})}for(let v of m.values()){let g=y.find((u)=>u.min===v.min&&u.max===v.max);if(g){if(g.style={...v.style,...g.style},v.dark||g.dark)g.dark={...v.dark,...g.dark}}else y.push(v)}if(y.length)f.responsive=y.sort((v,g)=>v.min-g.min||(v.max??1/0)-(g.max??1/0));return f}function me(e,t,n={}){let r=[],s=[],o=[],c=[],l={focus:{classes:[],originals:new Map},focusWithin:{classes:[],originals:new Map}},d=new Map;function p(b,N){let S=/^(bg|text|border(?:-[trblxy])?|from|via|to|fill|stroke|divide|decoration|caret|accent)-(.+?)(\/[^\s]+)?$/.exec(b),k=S&&Tt(S[2]);if(S&&k){let _=/^var\(\s*(--[\w-]+)\s*(?:,\s*(.+?)\s*)?\)$/.exec(k),C=_?t?.get(_[1])??_[2]:k;if(C&&/^(?:#[0-9a-f]{3,8}|rgba?\(.+\)|hsla?\(.+\))$/i.test(C))return[`${S[1]}-[${C.replace(/\s+/g,"")}]${S[3]||""}`]}let x=/^(text|bg|border|ring)-([a-z-]+)(\/[^\s]+)?$/.exec(b),A=x&&yt[x[2]];if(A){let _=t?.get(Ke(x[2]));return[`${x[1]}-${_===void 0?A[N]:`[${_}]`}${x[3]||""}`]}let M=/^rounded-(?:(tl|tr|bl|br|t|b|l|r)-)?(.+)$/.exec(b);if(M&&ye[M[2]]){let _=Ie(M[2],t);return _===void 0?void 0:[`rounded-${M[1]?`${M[1]}-`:""}[${_}px]`]}let j=b.startsWith("text-")?b.slice(5):"";if(nr[j]){let _=Pe(j,t);return _&&[`text-[${_.fontSize}px]`,`leading-[${_.lineHeight}px]`]}for(let _ of Object.keys(tr)){if(!b.endsWith(`-${_}`))continue;let C=Ce(_,t);return C===void 0?void 0:[`${b.slice(0,-_.length)}[${C}px]`]}return[b]}function h(b,N){if(!d.has(b))d.set(b,new Set);return d.get(b).add(N),b}let f=[],m=new Map;for(let b of e.split(/\s+/).filter(Boolean)){let N=b.startsWith("dark:")?b.slice(5):b,S=vr(N);if(S!==null){let A=S&&`${b===N?"":"dark:"}${S}`;if(A)f.push(A),m.set(A,b);continue}let k=/^(dark:)?(focus|focus-within):(dark:)?(.+)$/.exec(b),x=k?.[2]==="focus"?"focus":"focusWithin";if(k&&n[x]&&!(k[1]&&k[3])){let A=`${k[1]||k[3]?"dark:":""}${k[4]}`,M=l[x];M.classes.push(A),M.originals.set(A,[...M.originals.get(A)??[],b]);continue}if(b.startsWith("dark:")){let A=p(b.slice(5),"dark");if(!A)c.push(b);else s.push(...A.map((M)=>h(M,b)))}else if(!b.includes(":")||b.startsWith("[")){let A=p(b,n.appearance??"light"),M=p(b,"dark");if(!A||!M){c.push(b);continue}if(r.push(...A.map((j)=>h(j,b))),M.join(" ")!==A.join(" "))o.push(...M.map((j)=>h(j,b)))}else c.push(b)}let y=[],v=Mt(r,y),g={style:v,unknown:y},u=[...n.appearance===void 0?o:[],...s];if(u.length)g.dark=Mt(u,y);if(v.transform&&g.dark?.transform){let b=new Set(g.dark.transform.flatMap((N)=>Object.keys(N)));g.dark.transform=[...v.transform.filter((N)=>!Object.keys(N).some((S)=>b.has(S))),...g.dark.transform]}for(let b of r){if(b==="truncate"||b==="whitespace-nowrap")g.numberOfLines=1;let N=/^object-(cover|contain|fill)$/.exec(b);if(N)g.resizeMode=N[1]==="fill"?"stretch":N[1];let S=/^line-clamp-(\d+)$/.exec(b);if(S)g.numberOfLines=Number(S[1]);if(!g.icon&&/^i-[a-z0-9]+-[a-z0-9-]+$/.test(b))g.icon=b}let w=y.flatMap((b)=>[...d.get(b)??[b]]);if(g.unknown=[...new Set([...w.filter((b)=>!/^line-clamp-\d+$/.test(b)),...c])],f.length){let b=me(f.join(" "),t,{appearance:n.appearance});g.divide={style:b.style,...b.dark?{dark:b.dark}:{}},g.unknown=[...new Set([...g.unknown,...b.unknown.map((N)=>m.get(N)??N)])]}for(let b of["focus","focusWithin"]){let N=l[b];if(!N.classes.length)continue;let S=me(N.classes.join(" "),t,{appearance:n.appearance});g[b]={style:S.style,dark:S.dark},g.unknown=[...new Set([...g.unknown,...S.unknown.flatMap((k)=>N.originals.get(k)??[k])])];for(let k of N.classes)if(/^(?:dark:)?(?:truncate|line-clamp-\d+|i-[a-z0-9]+-.+)$/.test(k))g.unknown.push(...N.originals.get(k))}return g}function Mt(e,t){let n={},r=Array.isArray(e)?e:e.split(/\s+/).filter(Boolean),s={};for(let c of r)if(c.startsWith("text-"))Pt(c,s);let o=typeof s.fontSize==="number"?s.fontSize:16;for(let c of r){if(/^i-[a-z0-9]+-/.test(c))continue;let l=Gn[c];if(l){l("",n);continue}if(br(c,n))continue;if(Yn(c,n))continue;if(Jn(c,n))continue;if(Qn(c,n))continue;if(Pt(c,n))continue;if(Zn(c,n))continue;if(Bt(c,n))continue;if(er(c,n))continue;if(rr(c,n))continue;if(ir(c,n))continue;if(sr(c,n))continue;if(or(c,n))continue;if(ar(c,n))continue;if(yr(c,n))continue;if(cr(c,n,o))continue;if(dr(c,n))continue;if(pr(c,n))continue;if(ur(c,n))continue;let d=/^aspect-\[(\d+(?:\.\d+)?)\/(\d+(?:\.\d+)?)\]$/.exec(c);if(d&&Number(d[2])>0){n.aspectRatio=Number(d[1])/Number(d[2]);continue}let p=/^z-\[(-?\d+)\]$/.exec(c)??/^z-(\d+)$/.exec(c);if(p){n.zIndex=Number(p[1]);continue}if(c==="z-auto")continue;if(lr(c,n))continue;let h=/^order-\[(-?\d+)\]$/.exec(c)??/^order-(-?\d+)$/.exec(c);if(h){n.order=Number(h[1]);continue}if(gr(c,n))continue;if(hr(c,n))continue;if(mr(c,n))continue;if(t?.push(c),typeof process<"u"&&process.env?.NODE_ENV==="development")console.warn(`[STX Native] Unknown Headwind class: ${c}`)}return n}var jt=new Map;function Vt(e,t){if(!e)return;let n=e.trim(),r=n.lastIndexOf("-"),s=r===-1?t[n]:t[n.slice(0,r)],o=r===-1?s:s?.[n.slice(r+1)];if(typeof o==="string"&&/^#[\da-f]{3,8}$/i.test(o))return o;return Ve(n)??Ve(`[${n}]`)}function Nr(e){let t=e.roles??{},n=e.shapes??{},r=e.density??{},s={...e.theme?.colors,...e.theme?.extend?.colors},o=[],c=[];for(let[l,d]of Object.entries(t)){if(!yt[l])continue;let p=Vt(typeof d==="string"?d:d?.light,s),h=Vt(typeof d==="string"?d:d?.dark,s);if(p)o.push(`${Ke(l)}: ${p};`);if(h)c.push(`${Ke(l)}: ${h};`)}for(let[l,d]of Object.entries(n))if(ye[l])o.push(`${on(l)}: ${d};`);for(let[l,d]of Object.entries(r))if(Ae[l])o.push(`${Ge(l)}: ${d};`);return[o.length?`:root { ${o.join(" ")} }`:"",c.length?`.dark { ${c.join(" ")} }`:""].filter(Boolean).join(`
|
|
3
|
-
`)}async function kr(e){let{resolveUserCssConfig:t}=await import("./chunk-wq1vs94k.js"),n=await t(e);return n?Nr(n):""}function Wt(e){let t=xr.resolve(e),n=jt.get(t);if(!n)n=kr(t).catch(()=>""),jt.set(t,n);return n}var Xt={"aria-pressed":"selected","aria-selected":"selected","aria-checked":"checked","aria-disabled":"disabled","aria-expanded":"expanded","aria-busy":"busy"},Ft={alert:"alert",button:"button",checkbox:"checkbox",combobox:"combobox",header:"header",heading:"header",image:"image",img:"image",link:"link",menu:"menu",menubar:"menubar",menuitem:"menuitem",none:"none",presentation:"none",progressbar:"progressbar",radio:"radio",scrollbar:"scrollbar",search:"search",searchbox:"search",slider:"adjustable",spinbutton:"spinbutton",switch:"switch",tab:"tab",tablist:"tablist",timer:"timer",toolbar:"toolbar"};function Tr(e){return e==="role"||e==="aria-label"||e==="aria-valuetext"||e in Xt}function Rr(e,t){if(t===void 0||t===null)return;let n=String(t).trim().toLowerCase();if(n==="mixed")return e==="aria-checked"?"mixed":!0;if(n==="undefined")return;return n===""||n==="true"}function _r(e){if(e===void 0||e===null)return null;for(let t of String(e).trim().toLowerCase().split(/\s+/))if(Ft[t])return Ft[t];return null}function Ar(e,t,n){if(e==="aria-label")return{accessibilityLabel:t===void 0||t===null||t===""?null:String(t)};if(e==="aria-valuetext")return{accessibilityValue:t===void 0||t===null||t===""?null:String(t)};if(e==="role")return{accessibilityRole:_r(t)};let r=Xt[e];if(!r)return;let s=n.accessibilityState,o=s&&typeof s==="object"?{...s}:{},c=Rr(e,t);if(c===void 0)delete o[r];else o[r]=c;return{accessibilityState:Object.keys(o).length?o:null}}function Er(e){let t=e.accessibilityState&&typeof e.accessibilityState==="object"?e.accessibilityState:void 0,n={};for(let[s,o]of Object.entries(e)){if(!Tr(s))continue;let c=Ar(s,o,n);if(c)Object.assign(n,c)}for(let s of["accessibilityLabel","accessibilityRole","accessibilityValue"])if(e[s]===void 0&&n[s]!==void 0&&n[s]!==null)e[s]=n[s];let r=n.accessibilityState;if(r)e.accessibilityState={...r,...t}}var We=["accessibilityLabel","accessibilityRole","accessibilityState","accessibilityValue"];function Fe(e,t){let n={...e};if(Er(n),t==="Image"&&n.accessibilityLabel===void 0&&e.alt!=null&&e.alt!=="")n.accessibilityLabel=String(e.alt);return Object.fromEntries(We.filter((r)=>(r in n)).map((r)=>[r,n[r]]))}var Ut=["keyboardType","secureTextEntry","returnKeyType","autoCapitalize","autoCorrect","editable","autoComplete"],Or=new Set(["type","inputmode","inputMode","enterkeyhint","enterKeyHint","autoCapitalize","autoCorrect","spellcheck","readonly","readOnly","disabled",...Ut]),Ir={numeric:"number-pad",decimal:"decimal-pad",tel:"phone-pad",email:"email-address",url:"url",search:"web-search",text:"default"},Cr={email:{keyboardType:"email-address",verbatim:!0,autoComplete:"email"},tel:{keyboardType:"phone-pad",autoComplete:"tel"},url:{keyboardType:"url",verbatim:!0,autoComplete:"url"},number:{keyboardType:"decimal-pad"},search:{keyboardType:"web-search",returnKeyType:"search"},password:{secure:!0,verbatim:!0}},Pr={enter:"default",done:"done",go:"go",next:"next",previous:"default",search:"search",send:"send"};function se(e){return e===void 0||e===null?"":String(e).trim().toLowerCase()}function zt(e){if(e===void 0||e===null||e===!1)return!1;return se(e)!=="false"}function Xe(e,...t){for(let n of t)if(e[n]!==void 0&&e[n]!==null)return e[n];return}function Ht(e,t){if(e!=="TextInput")return{};let n={},r=se(t.type),s=Cr[r]??{},o=se(Xe(t,"inputmode","inputMode")),c=Ir[o]??s.keyboardType;if(c&&c!=="default")n.keyboardType=c;if(s.secure)n.secureTextEntry=!0;let l=se(Xe(t,"enterkeyhint","enterKeyHint")),d=Pr[l]??s.returnKeyType;if(d&&d!=="default")n.returnKeyType=d;let p=se(t.autoCapitalize);if(p==="off"||p==="none")n.autoCapitalize="none";else if(p==="on")n.autoCapitalize="sentences";else if(!p&&s.verbatim)n.autoCapitalize="none";let h=t.autoCorrect;if(h==="off"||h==="false"||se(t.spellcheck)==="false"||h===void 0&&s.verbatim)n.autoCorrect=!1;else if(h==="on"||h==="true")n.autoCorrect=!0;if(zt(Xe(t,"readonly","readOnly"))||zt(t.disabled))n.editable=!1;if(s.autoComplete)n.autoComplete=s.autoComplete;return Object.fromEntries(Object.entries(n).filter(([f])=>t[f]===void 0||Br(f,t[f])))}function Br(e,t){if(e==="autoCapitalize")return t==="off"||t==="on";if(e==="autoCorrect")return typeof t==="string";return!1}function qt(e){let t=Ht(e.type,e.props);if(!Object.keys(t).length)return;e._textEntrySource=Object.fromEntries(Ut.filter((n)=>(n in e.props)).map((n)=>[n,e.props[n]])),Object.assign(e.props,t)}var ze={"region-change-complete":"onRegionChangeComplete",regionchangecomplete:"onRegionChangeComplete",click:"onPress",press:"onPress","press-in":"onPressIn",pressin:"onPressIn","press-out":"onPressOut",pressout:"onPressOut",longpress:"onLongPress",contextmenu:"onLongPress",input:"onChangeText",onchange:"onChange",change:"onValueChange","value-change":"onValueChange",valuechange:"onValueChange",focus:"onFocus",focusin:"onFocus",blur:"onBlur",focusout:"onBlur",submit:"onSubmitEditing","submit-editing":"onSubmitEditing",submitediting:"onSubmitEditing","end-editing":"onEndEditing",endediting:"onEndEditing",scroll:"onScroll","scroll-begin-drag":"onScrollBeginDrag",scrollbegindrag:"onScrollBeginDrag","scroll-end-drag":"onScrollEndDrag",scrollenddrag:"onScrollEndDrag","momentum-scroll-begin":"onMomentumScrollBegin",momentumscrollbegin:"onMomentumScrollBegin","momentum-scroll-end":"onMomentumScrollEnd",momentumscrollend:"onMomentumScrollEnd","page-selected":"onPageSelected",pageselected:"onPageSelected",refresh:"onRefresh",layout:"onLayout","end-reached":"onEndReached",endreached:"onEndReached",close:"onRequestClose","request-close":"onRequestClose",requestclose:"onRequestClose",show:"onShow",dismiss:"onDismiss","sliding-complete":"onSlidingComplete",slidingcomplete:"onSlidingComplete","load-start":"onLoadStart",loadstart:"onLoadStart",load:"onLoad","load-end":"onLoadEnd",loadend:"onLoadEnd",error:"onError",play:"onPlay",playing:"onPlay",pause:"onPause",ended:"onEnd",end:"onEnd",timeupdate:"onProgress",progress:"onProgress",loadedmetadata:"onLoad",enterpictureinpicture:"onPictureInPictureStart",leavepictureinpicture:"onPictureInPictureStop"};var He={svg:"Svg",g:"G",path:"Path",line:"Line",rect:"Rect",circle:"Circle",ellipse:"Ellipse",polyline:"Polyline",polygon:"Polygon",text:"SvgText",tspan:"SvgText",animate:"Animate"},qe=new Set(Object.values(He));var Kt=new Set(["defs","title","desc","metadata","style","symbol","use","clippath","mask","lineargradient","radialgradient","stop","pattern","marker","filter","foreignobject"]),Yt=["viewBox","preserveAspectRatio","strokeWidth","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","fillOpacity","fillRule","vectorEffect","textAnchor","dominantBaseline","fontSize","fontWeight","attributeName","keyTimes","repeatCount"];function z(e){let t=typeof e==="number"?e:Number.parseFloat(String(e??""));return Number.isFinite(t)?t:0}function ee(e){return Math.round(e*1000)/1000}function Je(e){if(Array.isArray(e)&&e.length===4&&e.every((n)=>Number.isFinite(Number(n))))return e.map(Number);let t=String(e??"").trim().split(/[\s,]+/).map(Number);if(t.length!==4||t.some((n)=>!Number.isFinite(n))||t[2]<=0||t[3]<=0)return null;return t}function Lr(e){let t=String(e??"").trim().split(/[\s,]+/).filter(Boolean).map(Number).filter(Number.isFinite);return t.length%2?t.slice(0,-1):t}var Gt=/[MLHVCSQTAZ]/i,Ue=/[+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?/gi;function $r(e){let t=[],n=e,r=Gt.exec(n);while(r){let s=r.index;n=n.slice(s);let o=n[0];n=n.slice(1);let c=Gt.exec(n),l=c?n.slice(0,c.index):n,d;if(o==="A"||o==="a"){d=[];let p=0,h=l.trim(),f=0;while(f<h.length){let m=p%7,y=h.slice(f).replace(/^[\s,]+/,"");if(f=h.length-y.length,!y)break;if(m===3||m===4)d.push(y[0]==="1"?1:0),f+=1;else{Ue.lastIndex=0;let v=Ue.exec(y);if(!v||v.index!==0)break;d.push(Number.parseFloat(v[0])),f+=v[0].length}p++}}else d=(l.match(Ue)||[]).map(Number.parseFloat);t.push({command:o,args:d}),r=c}return t}function jr(e,t,n,r,s,o,c,l,d){if(e===l&&t===d)return[];let p=Math.abs(n),h=Math.abs(r);if(!p||!h)return[1,l,d];let f=s*Math.PI/180,m=Math.cos(f),y=Math.sin(f),v=(e-l)/2,g=(t-d)/2,u=m*v+y*g,w=-y*v+m*g,b=u*u/(p*p)+w*w/(h*h);if(b>1)p*=Math.sqrt(b),h*=Math.sqrt(b);let N=p*p*h*h-p*p*w*w-h*h*u*u,S=p*p*w*w+h*h*u*u,k=Math.sqrt(Math.max(0,N/S));if(o===c)k=-k;let x=k*(p*w)/h,A=k*-(h*u)/p,M=m*x-y*A+(e+l)/2,j=y*x+m*A+(t+d)/2,_=(B,W,P,L)=>{let Y=B*L-W*P<0?-1:1,Q=(B*P+W*L)/(Math.hypot(B,W)*Math.hypot(P,L));return Y*Math.acos(Math.min(1,Math.max(-1,Q)))},C=_(1,0,(u-x)/p,(w-A)/h),E=_((u-x)/p,(w-A)/h,(-u-x)/p,(-w-A)/h);if(!c&&E>0)E-=2*Math.PI;if(c&&E<0)E+=2*Math.PI;let O=Math.max(1,Math.ceil(Math.abs(E)/(Math.PI/2))),V=E/O,T=1.3333333333333333*Math.tan(V/4),R=[],I=(B)=>{let W=p*Math.cos(B),P=h*Math.sin(B);return[m*W-y*P+M,y*W+m*P+j]},D=(B)=>{let W=-p*Math.sin(B),P=h*Math.cos(B);return[m*W-y*P,y*W+m*P]},F=C;for(let B=0;B<O;B++){let W=F+V,[P,L]=I(F),[Y,Q]=D(F),[U,J]=I(W),[te,q]=D(W);R.push(2,P+T*Y,L+T*Q,U-T*te,J-T*q,B===O-1?l:U,B===O-1?d:J),F=W}return R}function Qt(e){let t=[],n=0,r=0,s=0,o=0,c=0,l=0,d=0,p=0,h="";for(let{command:f,args:m}of $r(String(e??""))){let y=f===f.toLowerCase(),v=f.toUpperCase(),g=()=>y?n:0,u=()=>y?r:0,w=0,b=(S)=>{if(w+S>m.length)return null;let k=m.slice(w,w+S);return w+=S,k};if(v==="Z"){t.push(4),n=s,r=o,h="Z";continue}let N=!0;while(w<m.length||N&&v==="Z"){switch(v){case"M":{let S=b(2);if(!S)return t;if(n=S[0]+g(),r=S[1]+u(),N)t.push(0,n,r),s=n,o=r;else t.push(1,n,r);h=N?"M":"L";break}case"L":{let S=b(2);if(!S)return t;n=S[0]+g(),r=S[1]+u(),t.push(1,n,r),h="L";break}case"H":{let S=b(1);if(!S)return t;n=S[0]+g(),t.push(1,n,r),h="L";break}case"V":{let S=b(1);if(!S)return t;r=S[0]+u(),t.push(1,n,r),h="L";break}case"C":{let S=b(6);if(!S)return t;let k=S[0]+g(),x=S[1]+u();c=S[2]+g(),l=S[3]+u(),n=S[4]+g(),r=S[5]+u(),t.push(2,k,x,c,l,n,r),h="C";break}case"S":{let S=b(4);if(!S)return t;let k=h==="C"?2*n-c:n,x=h==="C"?2*r-l:r;c=S[0]+g(),l=S[1]+u(),n=S[2]+g(),r=S[3]+u(),t.push(2,k,x,c,l,n,r),h="C";break}case"Q":{let S=b(4);if(!S)return t;d=S[0]+g(),p=S[1]+u(),n=S[2]+g(),r=S[3]+u(),t.push(3,d,p,n,r),h="Q";break}case"T":{let S=b(2);if(!S)return t;d=h==="Q"?2*n-d:n,p=h==="Q"?2*r-p:r,n=S[0]+g(),r=S[1]+u(),t.push(3,d,p,n,r),h="Q";break}case"A":{let S=b(7);if(!S)return t;let k=S[5]+g(),x=S[6]+u();t.push(...jr(n,r,S[0],S[1],S[2],S[3],S[4],k,x)),n=k,r=x,h="A";break}default:return t}N=!1}}return t.map((f)=>ee(f))}function Jt(e,t,n,r){if(n<=0||r<=0)return[];let s=0.5522847498;return[0,e+n,t,2,e+n,t+s*r,e+s*n,t+r,e,t+r,2,e-s*n,t+r,e-n,t+s*r,e-n,t,2,e-n,t-s*r,e-s*n,t-r,e,t-r,2,e+s*n,t-r,e+n,t-s*r,e+n,t,4].map(ee)}function Ye(e,t){switch(e){case"Path":return Qt(String(t.d??""));case"Line":return[0,z(t.x1),z(t.y1),1,z(t.x2),z(t.y2)].map(ee);case"Rect":{let n=z(t.x),r=z(t.y),s=z(t.width),o=z(t.height);if(s<=0||o<=0)return[];let c=t.rx===void 0?z(t.ry):z(t.rx),l=t.ry===void 0?c:z(t.ry);if(c=Math.min(Math.max(0,c),s/2),l=Math.min(Math.max(0,l),o/2),!c||!l)return[0,n,r,1,n+s,r,1,n+s,r+o,1,n,r+o,4].map(ee);let d=0.5522847498;return[0,n+c,r,1,n+s-c,r,2,n+s-c+d*c,r,n+s,r+l-d*l,n+s,r+l,1,n+s,r+o-l,2,n+s,r+o-l+d*l,n+s-c+d*c,r+o,n+s-c,r+o,1,n+c,r+o,2,n+c-d*c,r+o,n,r+o-l+d*l,n,r+o-l,1,n,r+l,2,n,r+l-d*l,n+c-d*c,r,n+c,r,4].map(ee)}case"Circle":return Jt(z(t.cx),z(t.cy),z(t.r),z(t.r));case"Ellipse":return Jt(z(t.cx),z(t.cy),z(t.rx),z(t.ry));case"Polyline":case"Polygon":{let n=Lr(t.points);if(n.length<4)return[];let r=[0,n[0],n[1]];for(let s=2;s<n.length;s+=2)r.push(1,n[s],n[s+1]);if(e==="Polygon")r.push(4);return r.map(ee)}default:return null}}function Vr(e){let t=/^\s*(\d+(?:\.\d+)?|\.\d+)\s*(ms|s)?\s*$/.exec(String(e??""));if(!t)return null;let n=Number(t[1])/(t[2]==="ms"?1000:1);return n>0?n:null}function Wr(e){if(e.attributeName!=="d")return null;let t=Vr(e.dur),n=String(e.values??"").split(";").map((l)=>l.trim()).filter(Boolean);if(t===null||n.length<2)return null;let r=n.map(Qt);if(r.some((l)=>!l.length))return null;let s=String(e.keyTimes??"").split(";").map((l)=>l.trim()).filter(Boolean).map(Number),c=s.length===r.length&&s[0]===0&&s[s.length-1]===1&&s.every((l,d)=>Number.isFinite(l)&&(d===0||l>=s[d-1]))?s.map(ee):r.map((l,d)=>ee(d/(r.length-1)));return{frames:r,frameTimes:c,duration:t}}function Qe(e){let t=Wr(e),n={frames:t?.frames??null,frameTimes:t?.frameTimes??null,duration:t?.duration??null};for(let[r,s]of Object.entries(n))if(s===null)delete e[r];else e[r]=s;return n}var Fr=[...Yt,"accessibilityHint","accessibilityLabel","accessibilityRole","accessibilityState","accessibilityValue","barStyle","activeOpacity","alwaysBounceHorizontal","alwaysBounceVertical","animationType","autoCapitalize","autoComplete","autoCorrect","autoFocus","contentContainerStyle","currentTime","defaultSource","defaultValue","ellipsizeMode","hidesWhenStopped","hitSlop","imageStyle","initialNumToRender","ios_backgroundColor","keyboardDismissMode","keyboardShouldPersistTaps","keyboardType","keyboardVerticalOffset","keyExtractor","listRole","maxLength","mostRecentEventCount","maximumDate","maximumTrackTintColor","maximumValue","maxToRenderPerBatch","minimumDate","minimumTrackTintColor","minimumValue","minuteInterval","numberOfLines","numColumns","objectFit","objectPosition","onEndReachedThreshold","pageIndex","pagingEnabled","passwordRules","placeholderTextColor","pointerEvents","presentationStyle","sheetDetents","selectedDetent","grabberVisible","tintColor","clearButtonMode","nonModal","dismissOnOutsideTap","pressRetentionOffset","progressBackgroundColor","progressViewOffset","refreshControl","resizeMode","returnKeyType","scrollEnabled","scrollTarget","secureTextEntry","selectedValue","selectionColor","showsHorizontalScrollIndicator","showsVerticalScrollIndicator","stickyHeaderIndices","testID","textContentType","thumbColor","thumbTintColor","titleColor","trackColor","underlayColor","windowSize","initialRegion","tileOverlay","edgePadding","fitToBounds","showsUserLocation","zoomEnabled","rotateEnabled","pitchEnabled","mapType","fillColor","strokeColor","pinColor","showsCompass","showsScale","cameraPitch","cameraHeading","autoScrollBottom","scrollKey","pictureInPicture","transitionID"],Zt=new Set(["alwaysBounceHorizontal","alwaysBounceVertical","animating","autoCorrect","autoFocus","autoplay","autoPlay","bounces","controls","disabled","editable","hidesWhenStopped","horizontal","loop","multiline","muted","pagingEnabled","paused","refreshing","scrollEnabled","secureTextEntry","selectTextOnFocus","showsHorizontalScrollIndicator","showsVerticalScrollIndicator","transparent","visible","nonModal","dismissOnOutsideTap","fitToBounds","showsUserLocation","zoomEnabled","rotateEnabled","pitchEnabled","showsCompass","showsScale","pictureInPicture","grabberVisible"]),Xr=new Map(Fr.map((e)=>[en(e),e]));function en(e){return e.replace(/[-_]/g,"").toLowerCase()}function Ze(e,t){if((t==="Image"||t==="Video")&&e.toLowerCase()==="src")return"source";return Xr.get(en(e))??e}var zr={view:"View",sidebar:"Sidebar",splitview:"SplitView",textinput:"TextInput",pressable:"Pressable",icon:"Icon",text:"Text",button:"Button",image:"Image",img:"Image",video:"Video",map:"Map",mappolyline:"MapPolyline",mappolygon:"MapPolygon",mapmarker:"MapMarker",input:"TextInput",textarea:"TextInput",scroll:"ScrollView",scrollview:"ScrollView",list:"FlatList",flatlist:"FlatList",modal:"Modal",switch:"Switch",checkbox:"Checkbox",slider:"Slider",picker:"Picker",segmentedcontrol:"SegmentedControl",nativesegmentedcontrol:"SegmentedControl",select:"Picker",loading:"ActivityIndicator",spinner:"ActivityIndicator",div:"View",span:"Text",p:"Text",h1:"Text",h2:"Text",h3:"Text",h4:"Text",h5:"Text",h6:"Text",a:"TouchableOpacity",section:"View",article:"View",header:"SafeAreaView",footer:"View",main:"View",nav:"View",aside:"View",form:"View",label:"Text",fieldset:"View",legend:"Text",option:"Text",dialog:"Modal",figure:"View",figcaption:"Text",picture:"View",hr:"View",ul:"View",ol:"View",li:"View",dl:"View",dt:"Text",dd:"Text",table:"View",thead:"View",tbody:"View",tfoot:"View",tr:"View",th:"Text",td:"Text",caption:"Text",strong:"Text",b:"Text",em:"Text",i:"Text",u:"Text",s:"Text",small:"Text",mark:"Text",abbr:"Text",time:"Text",code:"Text",kbd:"Text",samp:"Text",pre:"Text",blockquote:"Text",cite:"Text",q:"Text",sub:"Text",sup:"Text"};function tn(e){return zr[e.toLowerCase()]||e}var Ur={"circle-pause":"pause.circle","cloud-alert":"exclamationmark.icloud","key-round":"key",paperclip:"paperclip","rotate-cw":"arrow.clockwise","route-off":"location.slash",syringe:"syringe","volume-1":"speaker.wave.1",activity:"waveform.path.ecg","alarm-clock":"alarm","alert-circle":"exclamationmark.circle","alert-triangle":"exclamationmark.triangle",apple:"leaf",archive:"archivebox",armchair:"sofa","arrow-down":"arrow.down","arrow-left":"arrow.left","arrow-right":"arrow.right","arrow-up":"arrow.up","arrow-up-right":"arrow.up.right","at-sign":"at","audio-lines":"waveform",award:"rosette",backpack:"backpack","badge-check":"checkmark.seal","badge-x":"xmark.seal",ban:"nosign","bar-chart":"chart.bar","bar-chart-2":"chart.bar","bar-chart-3":"chart.bar",battery:"battery.100","battery-charging":"battery.100.bolt",bean:"leaf",bed:"bed.double",beef:"fork.knife",bell:"bell","bell-off":"bell.slash","bell-ring":"bell.and.waves.left.and.right",bike:"figure.outdoor.cycle",blocks:"square.grid.2x2",bluetooth:"antenna.radiowaves.left.and.right",book:"book","book-open":"book",bookmark:"bookmark",box:"shippingbox",brain:"brain",building:"building","building-2":"building.2",cable:"cable.connector","cake-slice":"birthday.cake",calendar:"calendar","calendar-check":"calendar.badge.checkmark","calendar-clock":"calendar.badge.clock","calendar-days":"calendar","calendar-minus":"calendar.badge.minus","calendar-minus-2":"calendar.badge.minus","calendar-off":"calendar.badge.exclamationmark","calendar-plus":"calendar.badge.plus","calendar-range":"calendar","calendar-sync":"arrow.triangle.2.circlepath","calendar-x":"calendar.badge.exclamationmark","calendar-x-2":"calendar.badge.exclamationmark",camera:"camera",carrot:"carrot","chart-bar":"chart.bar","chart-column":"chart.bar","chart-line":"chart.xyaxis.line","chart-no-axes-gantt":"chart.bar.doc.horizontal",check:"checkmark","check-circle":"checkmark.circle","check-circle-2":"checkmark.circle","chevron-down":"chevron.down","chevron-left":"chevron.left","chevron-right":"chevron.right","chevron-up":"chevron.up",circle:"circle","circle-alert":"exclamationmark.circle","circle-arrow-out-up-left":"arrow.uturn.backward.circle","circle-minus":"minus.circle","circle-arrow-down":"arrow.down.circle","circle-check":"checkmark.circle","circle-check-big":"checkmark.circle","circle-dot":"smallcircle.filled.circle","circle-help":"questionmark.circle","circle-question-mark":"questionmark.circle","circle-play":"play.circle","circle-plus":"plus.circle","circle-user":"person.crop.circle","circle-x":"xmark.circle",clapperboard:"film",clipboard:"clipboard","clipboard-list":"list.clipboard",clock:"clock","clock-12":"clock","clock-2":"clock","clock-3":"clock","clock-4":"clock","clock-8":"clock","clock-alert":"clock.badge.exclamationmark",cloud:"cloud","cloud-off":"icloud.slash",coffee:"cup.and.saucer",cookie:"birthday.cake",copy:"doc.on.doc","credit-card":"creditcard","cup-soda":"takeoutbag.and.cup.and.straw",cylinder:"cylinder",disc:"opticaldisc",download:"arrow.down.circle",droplet:"drop",droplets:"drop",drumstick:"fork.knife",dumbbell:"dumbbell",edit:"pencil",egg:"frying.pan","external-link":"arrow.up.right.square",eye:"eye","eye-off":"eye.slash",file:"doc","file-text":"doc.text",filter:"line.3.horizontal.decrease",fish:"fish",flag:"flag",flame:"flame","flower-2":"camera.macro",footprints:"figure.run",gauge:"gauge",gift:"gift","glass-water":"waterbottle",globe:"globe","graduation-cap":"graduationcap","grip-vertical":"line.3.horizontal",hamburger:"takeoutbag.and.cup.and.straw","hand-fist":"hand.raised",heart:"heart","heart-off":"heart.slash","heart-pulse":"heart.text.square","help-circle":"questionmark.circle",history:"clock.arrow.circlepath",home:"house",hourglass:"hourglass",house:"house","id-card":"person.text.rectangle",image:"photo",inbox:"tray",info:"info.circle",layers:"square.3.layers.3d","layout-dashboard":"rectangle.3.group","layout-grid":"square.grid.2x2",leaf:"leaf",library:"books.vertical",link:"link",list:"list.bullet","list-checks":"checklist",loader:"arrow.triangle.2.circlepath","loader-2":"arrow.triangle.2.circlepath","loader-circle":"arrow.triangle.2.circlepath",lock:"lock","log-in":"arrow.right.to.line","log-out":"rectangle.portrait.and.arrow.right",mail:"envelope",map:"map","map-pin":"mappin.and.ellipse",medal:"medal",megaphone:"megaphone",menu:"line.3.horizontal","message-circle":"bubble.left","message-square":"text.bubble","message-square-quote":"quote.bubble","messages-square":"bubble.left.and.bubble.right",mic:"mic",milk:"waterbottle",minus:"minus",moon:"moon","more-horizontal":"ellipsis","more-vertical":"ellipsis",mountain:"mountain.2",music:"music.note","music-2":"music.note",nut:"leaf",package:"shippingbox",pause:"pause","pause-circle":"pause.circle",pencil:"pencil","person-standing":"figure.walk",phone:"phone",play:"play.fill",plug:"powerplug",plus:"plus","plus-circle":"plus.circle","rectangle-horizontal":"rectangle","refresh-cw":"arrow.clockwise",repeat:"repeat","rotate-ccw":"arrow.counterclockwise",route:"point.topleft.down.to.point.bottomright.curvepath",ruler:"ruler",sailboat:"sailboat",salad:"leaf",satellite:"antenna.radiowaves.left.and.right",save:"square.and.arrow.down",scale:"scalemass","scan-line":"barcode.viewfinder",search:"magnifyingglass",send:"paperplane",settings:"gearshape","settings-2":"slider.horizontal.3",share:"square.and.arrow.up","share-2":"square.and.arrow.up",shield:"shield","shield-check":"checkmark.shield","shopping-bag":"bag","shopping-cart":"cart",shuffle:"shuffle","skip-back":"backward.end","skip-forward":"forward.end",sliders:"slider.horizontal.3","sliders-horizontal":"slider.horizontal.3",smartphone:"iphone",snowflake:"snowflake",soup:"mug",sparkles:"sparkles",sprout:"leaf",square:"square",star:"star",stopwatch:"stopwatch",store:"storefront","stretch-horizontal":"rectangle.split.1x2",sun:"sun.max",sunrise:"sunrise",sunset:"sunset",tag:"tag",target:"scope",thermometer:"thermometer.medium","thumbs-up":"hand.thumbsup",timer:"timer",trash:"trash","trash-2":"trash","trending-down":"chart.line.downtrend.xyaxis","trending-up":"chart.line.uptrend.xyaxis","triangle-alert":"exclamationmark.triangle",trophy:"trophy",unlink:"personalhotspot.slash",upload:"arrow.up.circle",user:"person","user-check":"person.crop.circle.badge.checkmark","user-minus":"person.badge.minus","user-plus":"person.badge.plus","user-round":"person","user-round-check":"person.crop.circle.badge.checkmark","user-round-minus":"person.crop.circle.badge.minus","user-round-plus":"person.crop.circle.badge.plus","user-round-x":"person.crop.circle.badge.xmark","user-x":"person.crop.circle.badge.xmark",users:"person.2","users-round":"person.2",utensils:"fork.knife",video:"video","volume-2":"speaker.wave.2",warehouse:"building.2",watch:"applewatch",waves:"figure.pool.swim",weight:"scalemass",wheat:"laurel.leading",wifi:"wifi","wifi-off":"wifi.slash",wind:"wind",wine:"wineglass",x:"xmark","x-circle":"xmark.circle",zap:"bolt"},nn={lucide:Ur,hugeicons:{"workout-run":"figure.run"}};function ce(e,t=!1){let n=String(e??"").trim();if(!n)return{symbol:"questionmark.square.dashed",known:!1};if(t)return{symbol:n,known:!0};let r=/^i-([a-z0-9]+)-(.+)$/.exec(n)??/^([a-z0-9]+):(.+)$/.exec(n),s=r?r[1]:"lucide",o=r?r[2]:n,c=Object.hasOwn(nn,s)?nn[s]:void 0;if(c&&Object.hasOwn(c,o))return{symbol:c[o],iconify:`i-${s}-${o}`,known:!0};if(!r&&n.includes("."))return{symbol:n,known:!0};return{symbol:"questionmark.square.dashed",iconify:r?n:`i-lucide-${o}`,known:!1}}function et(e){return e.split(/\s+/).find((t)=>/^i-[a-z0-9]+-[a-z0-9-]+$/.test(t))}import{generate as Se,parse as Hr}from"@stacksjs/ts-css/parse";var qr=/^(?::hover|:active|:visited|:focus|:focus-visible|:focus-within)$/;function Gr(e){let t=e.replace(/\s+/g,"").toLowerCase();if(!t||t==="all"||t==="screen")return{};if(/^(?:screenand)?\(prefers-color-scheme:dark\)$/.test(t))return{dark:!0};if(/^(?:screenand)?\(prefers-color-scheme:light\)$/.test(t))return{};if(/prefers-reduced-motion|\(hover|\(pointer|print|forced-colors|prefers-contrast/.test(t))return"skip";let n=t.replace(/^screenand/,"").split("and"),r={};for(let s of n){let o=/^\((min|max)-width:([\d.]+)(px|rem|em)\)$/.exec(s);if(!o)return;r[o[1]]=Number(o[2])*(o[3]==="px"?1:16)}return r}async function rn(e,t){let n={},r=new Set,s=(p)=>{if(r.has(p))return;r.add(p),t(p,[...p.matchAll(/\.(-?[a-z_][\w-]*)/gi)].map((h)=>h[1]))},o=(p,h,f)=>{if(!h.trim())return;let m=n[p]??={},y=f.dark?"dark":"light";if(f.min===void 0&&f.max===void 0){m[y]=m[y]?`${m[y]};${h}`:h;return}let v=m.responsive??=[],g=f.min??0,u=v.find((w)=>w.min===g&&w.max===f.max);if(!u)v.push(u={min:g,...f.max===void 0?{}:{max:f.max}});u[y]=u[y]?`${u[y]};${h}`:h};function c(p,h){for(let f of p){if(f.type==="Atrule"){let v=f.name.toLowerCase();if(["font-face","keyframes","-webkit-keyframes","import","charset","property","page","layer"].includes(v)){if(v==="layer"&&f.block)c(f.block.children,h);continue}if(v!=="media"||!f.block){s(`@${v}`);continue}let g=f.prelude?Se(f.prelude):"",u=Gr(g);if(u==="skip")continue;if(!u){s(`@media ${g}`);continue}c(f.block.children,{dark:h.dark||u.dark,min:u.min??h.min,max:u.max??h.max});continue}if(f.type!=="Rule"||f.block.type!=="Block")continue;let m=[...f.block.children].filter((v)=>v.type==="Declaration").map((v)=>Se(v)).join(";"),y=f.prelude.type==="SelectorList"?[...f.prelude.children].map(Se):[Se(f.prelude)];for(let v of y){let g=/^(?:(?:html|:root)?\.dark\s+)?((?:\.-?[a-z_][\w-]*)+)((?::{1,2}[a-z-]+)*)$/i.exec(v.trim());if(!g){if(!/^(?:html|:root|body|\*|::?[a-z-]+)/i.test(v.trim()))s(v.trim());continue}let u=g[2];if(u){if(!qr.test(u))s(v.trim());continue}let w=h.dark||/^(?:(?:html|:root)?\.dark\s+)/i.test(v.trim());o(g[1].slice(1),m,{dark:w,min:h.min,max:h.max})}}}let l="",d=!0;await new HTMLRewriter().on("style",{element(p){l="";let h=p.getAttribute("type");d=!h||h.toLowerCase()==="text/css",p.onEndTag(()=>{if(!d)return;try{let f=Hr(l);if(f.type==="StyleSheet")c(f.children,{})}catch{s("invalid stylesheet")}})},text(p){l+=p.text}}).transform(new Response(e)).text();for(let p of Object.values(n))p.responsive?.sort((h,f)=>h.min-f.min||(h.max??1/0)-(f.max??1/0));return n}import{generate as le,parse as sn}from"@stacksjs/ts-css/parse";async function an(e,t){let n={light:new Map,dark:new Map},r=new Set,s=(f)=>{if(!r.has(f))r.add(f),t(f)},o=(f,m,y)=>{for(let v of y){let g=n[v].get(f);if(!g||Number(m.important)>Number(g.important)||m.important===g.important&&m.specificity>=g.specificity)n[v].set(f,m)}},c=(f)=>{if(f.type==="Declaration")return f.property.startsWith("--");if(f.type==="Rule"||f.type==="Atrule")return!!f.block&&[...f.block.children].some(c);return!1},l=(f)=>{let m=f.replace(/\s+/g,"").toLowerCase();if(!m||m==="all"||m==="screen")return["light","dark"];let y=/^(?:screenand)?\(prefers-color-scheme:(light|dark)\)$/.exec(m);return y?[y[1]]:void 0};function d(f,m){for(let y of f){if(!c(y))continue;if(y.type==="Atrule"){let g=y.prelude?le(y.prelude):"",u=y.name.toLowerCase()==="media"?l(g):void 0;if(!u){s(`@${y.name} ${g}`.trim());continue}d(y.block.children,m.filter((w)=>u.includes(w)));continue}if(y.type!=="Rule")continue;let v=y.prelude.type==="SelectorList"?[...y.prelude.children].map(le):[le(y.prelude)];for(let g of v){let u=/^(html|:root)?(?:\.(dark|light))?$/.exec(g.trim());if(!u||!u[1]&&!u[2]){s(g);continue}let w=(u[1]===":root"?10:u[1]?1:0)+(u[2]?10:0);for(let b of y.block.children){if(b.type!=="Declaration"){if(c(b))s(`nested rule in ${g}`);continue}if(!b.property.startsWith("--"))continue;let N={value:le(b.value),important:!!b.important,specificity:w};o(b.property,N,m.filter((S)=>!u[2]||u[2]===S))}}}}let p="",h;return await new HTMLRewriter().on("html",{element(f){let m=f.getAttribute("style");if(!m)return;try{let y=sn(m,{context:"declarationList"});if(y.type!=="DeclarationList")return;for(let v of y.children)if(v.type==="Declaration"&&v.property.startsWith("--"))o(v.property,{value:le(v.value),important:!!v.important,specificity:1000},["light","dark"])}catch{s("invalid document inline theme")}}}).on("style",{element(f){p="";let m=f.getAttribute("type");h=!m||m.toLowerCase()==="text/css"?l(f.getAttribute("media")??""):void 0,f.onEndTag(()=>{try{let y=sn(p);if(y.type!=="StyleSheet")return;if(!h){if([...y.children].some(c))s("style type/media");return}d(y.children,h)}catch{s("invalid stylesheet")}})},text(f){p+=f.text}}).transform(new Response(e)).text(),{light:[...n.light].map(([f,m])=>[f,m.value]),dark:[...n.dark].map(([f,m])=>[f,m.value])}}function K(e,t={},n={},r={},s=[]){return{type:e,props:t,style:n,events:r,children:s}}function cn(e,t,n={}){return{version:"1.0.0",root:e,script:t,meta:{source:n.source||"unknown",compiledAt:n.compiledAt||Date.now(),headwindConfig:n.headwindConfig}}}var Jr=/^(?:key(?:down|up|press)|mouse[a-z]+|pointer[a-z]+|dbl(?:click)?|contextmenu|wheel|drag[a-z]*|drop|copy|cut|paste|beforeinput|compositionstart|compositionupdate|compositionend|animation[a-z]+|transition[a-z]+|resize|hashchange|popstate|beforeunload|unload|visibilitychange|selectionchange|selectstart|auxclick)$/,ln=new Set(["script","style","head","meta","link","title","base","noscript"]),un=new Set(["template","body","html","main","fragment"]),we=new Set,Kr=new Set(["onBlur","onChange","onChangeText","onDismiss","onEnd","onEndEditing","onEndReached","onError","onFocus","onPageSelected","onLayout","onLoad","onLoadEnd","onLoadStart","onLongPress","onMomentumScrollBegin","onMomentumScrollEnd","onPause","onPictureInPictureStart","onPictureInPictureStop","onPlay","onPress","onPressIn","onPressOut","onProgress","onRequestClose","onRegionChangeComplete","onRefresh","onScroll","onScrollBeginDrag","onScrollEndDrag","onShow","onSlidingComplete","onSubmitEditing","onValueChange"]),xe=new Set(["Sidebar","SplitView","View","ScrollView","SafeAreaView","KeyboardAvoidingView","Text","TextInput","Button","Link","TouchableOpacity","TouchableHighlight","Pressable","Icon","Image","ImageBackground","Video","Map","MapPolyline","MapPolygon","MapMarker","FlatList","SectionList","Switch","Checkbox","Slider","Picker","SegmentedControl","DatePicker","Modal","ActivityIndicator","StatusBar","RefreshControl",...qe]),Yr=new Map([["data","data"],["sections","sections"],["renderitem","renderItem"],["rendersectionheader","renderSectionHeader"],["keyextractor","keyExtractor"]]),dn=new Set(["View","SafeAreaView","ScrollView","KeyboardAvoidingView"]),Qr={amp:"&",lt:"<",gt:">",quot:'"',apos:"'",nbsp:" ","#39":"'","#x27":"'"};function re(e){return e.replace(/&(#x?[0-9a-f]+|\w+);/gi,(t,n)=>{let r=Qr[n.toLowerCase()];if(r!==void 0)return r;if(n[0]==="#"){let s=n[1]==="x"||n[1]==="X"?Number.parseInt(n.slice(2),16):Number.parseInt(n.slice(1),10);return Number.isFinite(s)?String.fromCodePoint(s):t}return t})}function tt(e){if(!e.includes("{{"))return null;let t=[],n=0;for(let r of e.matchAll(/\{\{([\s\S]+?)\}\}/g)){if(r.index>n)t.push(JSON.stringify(e.slice(n,r.index)));t.push(`(${r[1].trim()})`),n=r.index+r[0].length}if(!t.some((r)=>r.startsWith("(")))return null;if(n<e.length)t.push(JSON.stringify(e.slice(n)));if(t.length===1)return t[0].slice(1,-1);return`[${t.join(", ")}].map(__stxPart => __stxPart == null ? '' : __stxPart).join('')`}function fn(e,t,n,r={}){let s=r.inheritedVariables,o={},c={},l={},d=[],p="",h={};for(let[v,g]of t){let u=v.toLowerCase();if(u==="class"||u==="classname"){p=p?`${p} ${g}`:g;continue}if(u==="style"){h={...h,...Zr(e,g,n,{...r,onVariables(S){s=S,r.onVariables?.(S)}})};continue}if(u.startsWith(":")||u.startsWith("x-")&&u!=="x-cloak"){l[u.startsWith(":")?u.slice(1):u.slice(2)]=re(g);continue}if(u==="x-cloak")continue;if(u.startsWith("@")||u.startsWith("v-on:")){let S=u.startsWith("@")?u.slice(1):u.slice(5),[k]=S.split("."),x=ze[k]??(k.startsWith("on")?k:"");if(!x||!Kr.has(x)){if(Jr.test(k)||/\./.test(S))n.push({kind:"unread-event",tag:e,name:v});continue}c[x]=re(g);continue}if(u==="key"){o.key=g;continue}let w=re(g),b=tt(w);if(b){l[u]=b,d.push(u);continue}let N=Ze(v);if(w===""&&Zt.has(N)){o[N]=!0;continue}try{o[N]=JSON.parse(w)}catch{o[N]=w}}let f=o["data-native"]?o["data-native"]==="TextInput":e==="textarea"||e==="input"&&!["checkbox","radio","hidden"].includes(String(o.type??"text").toLowerCase()),m=p?ve(p,s,{focus:f,focusWithin:!0,rules:r.rules}):void 0;for(let v of new Set(m?.unknown??[]))n.push({kind:"unknown-class",tag:e,name:v});let y=Le({...m?.style,...h});return{props:o,style:y,events:c,bindings:l,classes:p,inline:h,templated:d}}function Zr(e,t,n,r){return he(re(t),(s)=>n.push({...s,tag:e}),r)}function nt(e){return e.children.map((t)=>typeof t==="string"?t:nt(t)).join("").replace(/\s+/g," ").trim()}function ei(e,t){let n=e.node;if(n.props["data-stx-native-template"])return n.children=n.children.map((o)=>typeof o==="string"?K("Text",{},{},{},[o]):o),n;let r=n.children.filter((o)=>typeof o!=="string"),s=n.children.filter((o)=>typeof o==="string").join("").trim();if(e.tag==="button"&&n.type==="Button"&&!e.declaredNative&&r.length>0)return n.type="Pressable",n.props.role??="button",n.children=n.children.flatMap((o)=>typeof o==="string"?o.trim()?[K("Text",{},{},{},[o.trim()])]:[]:[o]),n;if(n.type==="Button"&&r.length===0)return n.children=s?[s]:[],n;if(n.type==="Svg"||n.type==="G")return n.children=r,n;if(n.type==="SvgText"){let o=nt(n);return n.children=o?[o]:[],n}if(dn.has(n.type)&&r.length===0&&s)return n.type="Text",n.children=[s],n;if(n.type==="Text"&&!s&&r.length===0&&typeof n.props.text==="string")return n.children=n.props.text?[n.props.text]:[],delete n.props.text,n;if(n.type==="Text"&&r.length>0){if(/(?:^|\s)(?:inline-)?(?:flex|grid)(?:\s|$)/.test(n._classes??"")||r.some((l)=>l.type!=="Text"))return n.type="View",n.children=n.children.map((l)=>typeof l==="string"?K("Text",{},{},{},[l]):l),n;let c=nt(n);return t.push({kind:"flattened-text",tag:e.tag}),n.children=c?[c]:[],n}if(dn.has(n.type)&&r.length>0)n.children=r;return n}async function ti(e,t={}){e=await ue(e);let n=[],r=await an(e,(u)=>n.push({kind:"unsupported-theme-rule",tag:"style",name:u})),s=ae(r.light).computed(),o=new Set([...e.matchAll(/\sclass(?:name)?\s*=\s*"([^"]*)"/gi)].flatMap((u)=>u[1].split(/\s+/))),c=await rn(e,(u,w)=>{if(!w.length||w.some((b)=>o.has(b)))n.push({kind:"unsupported-style-rule",tag:"style",name:u})}),l=[],d=[],p=new Set;function h(u){let w=d[d.length-1];if(!w)l.push(u);else if(!w.dropped)w.node.children.push(u)}function f(u){let w=u.node.style.fontFamily,b=(S)=>{if(u.tag!=="html"&&u.node._styleSource)S._styleAncestors=[u.node._styleSource,...S._styleAncestors??[]];if(w&&S.style.fontFamily===void 0)S._layoutDefaults={...S._layoutDefaults,fontFamily:w},S.style={fontFamily:w,...S.style}};if(u.node.bindings&&Object.keys(u.node.bindings).length>0){let S=u.node.children,k=S.filter((A)=>typeof A!=="string"),x=k.length===1&&k.length===S.length?k[0]:K("View",{},{},{},S);if(x.bindings={...u.node.bindings,...x.bindings},x.bindingId===void 0&&u.node.bindingId!==void 0)x.bindingId=u.node.bindingId;b(x),h(x);return}let N=d[d.length-1];for(let S of u.node.children){if(typeof S==="string"){if(N&&!N.dropped)N.node.children.push(S);continue}if(b(S),!N)l.push(S);else if(!N.dropped)N.node.children.push(S)}}function m(u,w){let b=d[d.length-1];if(u==="svg"||b?.svg)return y(u,w,b);let N=ln.has(u)&&!we.has(u),S=d[d.length-1]?.dropped??!1,k=b?.variables??s,{props:x,style:A,events:M,bindings:j,classes:_,inline:C,templated:E}=N||S?{props:{},style:{},events:{},bindings:{},classes:"",inline:{},templated:[]}:fn(u,w,n,{inheritedVariables:k,onVariables:(D)=>{k=D},rules:c});if(u==="html")k=s;let O=x["data-native"],V=u==="template"&&w.some(([D])=>[":for","x-for","@for"].includes(D)),T;if(V)T="View",x["data-stx-native-template"]=!0;else if(typeof O==="string"&&xe.has(O))T=O,delete x["data-native"];else{if(T=we.has(u)?"View":tn(u),(u==="i"||u==="span")&&/(?:^|\s)i-[a-z0-9]+-[a-z0-9-]+(?:\s|$)/.test(_))T="Icon";else if(u==="i"&&w.some(([D])=>/^(?::|x-)class$/i.test(D)))T="Icon";if(u==="input"){let D=String(x.type??"text").toLowerCase();if(D==="checkbox")T="Checkbox",x.formValue=x.value??"on",x.checked=x.checked===""||x.checked===!0||x.checked==="true",x.value=x.checked;else if(D==="hidden")T="View",A.display="none",C.display="none";else if(D==="radio")T="View",x.accessibilityRole="radio",n.push({kind:"unsupported-control",tag:u,name:"input:radio"})}}if(!S&&T===u&&!xe.has(T)&&!ln.has(u)&&!un.has(u)&&!p.has(u))p.add(u),n.push({kind:"unmapped-tag",tag:u});if((N||we.has(u))&&!p.has(`drop:${u}`))p.add(`drop:${u}`),n.push({kind:"dropped-subtree",tag:u});if(T==="View"&&/(?:^|\s)overflow-x-(?:auto|scroll)(?:\s|$)/.test(_))T="ScrollView",x.horizontal=!0,x.showsHorizontalScrollIndicator??=!1;else if(T==="View"&&/(?:^|\s)overflow-y-(?:auto|scroll)(?:\s|$)/.test(_))T="ScrollView";if(u==="form")x["data-stx-form"]=!0;if(u==="button"&&x.type===void 0)x.type="submit";if(u==="textarea"&&T==="TextInput")x.multiline??=!0;if((T==="Video"||T==="Image")&&x.source===void 0&&x.src!==void 0)x.source=x.src,delete x.src;if(T==="Icon"){let D=ve(_).icon,F=String(x.symbol||x.name||D||""),B=ce(F,Boolean(x.symbol));if(F.trim()&&!B.known)n.push({kind:"unknown-icon",tag:u,name:F});if(x.symbol=B.symbol,B.iconify)x.iconify=B.iconify}if(T==="FlatList"||T==="SectionList"){let D=new Set([...Object.keys(x),...Object.keys(j)].map((F)=>F.toLowerCase()));for(let[F,B]of Yr)if(D.has(F))n.push({kind:"unsupported-list-prop",tag:T,name:B})}let R=K(T,x,A,M);R._inlineStyle=C,R._styleSource=re(w.find(([D])=>D==="style")?.[1]??"");let I=x["data-stx-b"];if(typeof I==="number"&&Number.isInteger(I))R.bindingId=I;if(delete x["data-stx-b"],_)R._classes=_;if(Object.keys(j).length>0)R.bindings=j;if(E.length>0)R._templated=E;if(typeof x.key==="string")R.key=x.key,delete x.key;return{tag:u,node:R,variables:k,declaredNative:typeof O==="string"&&xe.has(O),dropped:N||S||we.has(u)||T==="Video",discard:N||S,unwrap:un.has(u)&&!V&&T!=="ScrollView"&&!(typeof O==="string"&&xe.has(O))}}function y(u,w,b){let N=b?.dropped??!1,S=He[u];if(N||!S){if(!N&&!p.has(`drop:${u}`))p.add(`drop:${u}`),n.push({kind:Kt.has(u)?"dropped-subtree":"unmapped-tag",tag:u});return{tag:u,node:K("G",{},{},{}),svg:!0,dropped:!0,discard:!0,unwrap:!1}}let k=b?.variables??s,{props:x,style:A,events:M,bindings:j,classes:_,inline:C,templated:E}=fn(u,w,n,{inheritedVariables:k,onVariables:(R)=>{k=R},rules:c});if(S==="Svg"){let R=Je(x.viewBox);if(R)x.viewBox=R;else delete x.viewBox;for(let I of["width","height"]){if(typeof x[I]==="number"&&A[I]===void 0)A[I]=x[I];delete x[I]}}if(typeof x.strokeDasharray==="string"||typeof x.strokeDasharray==="number"){let R=String(x.strokeDasharray).split(/[\s,]+/).map(Number).filter(Number.isFinite);x.strokeDasharray=R}let O=Ye(S,x);if(O)x.geometry=O;if(S==="Animate")Qe(x);let V=K(S,x,A,M);V._inlineStyle=C,V._styleSource=re(w.find(([R])=>R==="style")?.[1]??"");let T=x["data-stx-b"];if(typeof T==="number"&&Number.isInteger(T))V.bindingId=T;if(delete x["data-stx-b"],_)V._classes=_;if(Object.keys(j).length>0)V.bindings=j;if(E.length>0)V._templated=E;if(typeof x.key==="string")V.key=x.key,delete x.key;return{tag:u,node:V,variables:k,svg:!0,dropped:!1,discard:!1,unwrap:!1}}if(await new HTMLRewriter().on("*",{element(u){let w=u.tagName.toLowerCase(),b=m(w,[...u.attributes]),N=!0;try{u.onEndTag(()=>{if(d.pop(),b.discard)return;if(b.unwrap)f(b);else h(ei(b,n))})}catch{N=!1}if(N)d.push(b);else if(!b.discard)h(b.node)},text(u){let w=d[d.length-1];if(!w||w.dropped)return;let b=ni(re(u.text),w.inMustache===!0);w.inMustache=b.inside;let N=b.text;if(!N.trim())return;w.node.children.push(N)}}).transform(new Response(e)).text(),l.length===0)throw Error(`No element to translate in the rendered output of ${t.source??"unknown"}`);let v=l.length===1?l[0]:K("View",{},{},{},l);if(r.light.length||r.dark.length)v._stylesheetTheme=r;if(Object.keys(c).length)v._stylesheetRules=c;let g=(u)=>{ri(u);let w=Fe(u.props,u.type);if(Object.keys(w).length)u._accessibilitySource=Object.fromEntries(We.filter((b)=>(b in u.props)).map((b)=>[b,u.props[b]])),Object.assign(u.props,w);qt(u);for(let b of u.children)if(typeof b!=="string")g(b)};return g(v),pn(v),{root:v,diagnostics:n}}function pn(e){if(["ScrollView","FlatList","SectionList"].includes(e.type))return!e.props.horizontal&&(Number(e.style.flex)>0||Number(e.style.flexGrow)>0);if(!e.children.map((n)=>typeof n==="string"?!1:pn(n)).some(Boolean)||!["View","SafeAreaView","KeyboardAvoidingView"].includes(e.type))return!1;if(e.style.height!==void 0||e.style.maxHeight!==void 0)return!1;if(e.style.flex===0||e.style.flexGrow===0||e.style.flexShrink===0)return!1;if(e.style.flex===void 0&&e.style.flexGrow===void 0)e._layoutDefaults={flex:1,flexGrow:1,flexShrink:1,flexBasis:0},e.style={...e._layoutDefaults,...e.style};return!0}function ni(e,t){let n="",r=0;while(r<e.length){if(!t&&e.startsWith("{{",r)){t=!0,n+="{{",r+=2;continue}if(t&&e.startsWith("}}",r)){t=!1,n+="}}",r+=2;continue}let s=e[r];if(!t&&/\s/.test(s)){if(!n.endsWith(" "))n+=" ";while(r<e.length&&/\s/.test(e[r]))r++;continue}n+=s,r++}return{text:n,inside:t}}function ri(e){if(e.props["data-stx-native-template"])return;if(e.bindings?.text||e.children.length===0)return;let t=e.children.filter((r)=>typeof r==="string");if(t.length<e.children.length){let r=e.type==="Button"||e.type==="Text"?null:tt(t.join(""));if(!r)return;e.bindings={...e.bindings,text:r},e._templated=[...e._templated??[],"text"],e.children=e.children.filter((s)=>typeof s!=="string");return}let n=tt(e.children.join(""));if(!n)return;if(e.type!=="Button")e.bindings={...e.bindings,text:n},e._templated=[...e._templated??[],"text"],e.children=[];else{e.type="Pressable",e.props.role??="button";let r=K("Text",{},{},{},[]);r.bindings={text:n},r._templated=["text"],e.children=[r]}}async function gn(e,t={}){let{root:n,diagnostics:r}=await ti(e,t),s=t.script??{exports:{},functions:[],code:""};return{document:cn(n,s,{source:t.source??"unknown"}),diagnostics:r}}function ii(e){let t="",n=0;for(let r=e.indexOf("<");r!==-1;r=e.indexOf("<",r+1)){if(!/[a-z]/i.test(e[r+1]??""))continue;let s=r+1,o="";for(;s<e.length;s++){let l=e[s];if(o){if(l===o)o="";continue}if(l==='"'||l==="'")o=l;else if(l===">"||l==="<")break}if(e[s]!==">"||e[s-1]!=="/")continue;let c=e.slice(r,s+1).replace(/"[^"]*"|'[^']*'/g,'""');if(!/\sdata-native-exclude(?=[\s=/>])/i.test(c))continue;t+=e.slice(n,r),n=s+1,r=s}return n?t+e.slice(n):e}async function ue(e){if(!/\bdata-native-exclude\b/i.test(e))return e;if(e=ii(e),!/\bdata-native-exclude\b/i.test(e))return e;return new HTMLRewriter().on("[data-native-exclude]",{element(t){t.remove()}}).transform(new Response(e)).text()}var hn=/<script\b([^>]*)>([\s\S]*?)<\/script>/gi,si=/(?:^|\n)\s*(?:export\s+)?(?:async\s+)?function\s*\*?\s*([$\w]+)\s*\(/g,oi=/(?:^|\n)\s*(?:export\s+)?(?:const|let|var)\s+([$\w]+)\s*=\s*(?:async\s*)?(?:\([^)]*\)|[$\w]+)\s*=>/g,mn=/(?:^|\n)\s*(?:export\s+)?const\s+([$\w]+)\s*=\s*(-?[\d.]+|true|false|'[^']*'|"[^"]*")\s*(?=;|\n|$)/g;function rt(e){let t=[];hn.lastIndex=0;for(let o of e.matchAll(hn)){let c=o[1]??"";if(/\bserver\b/.test(c))continue;t.push(o[2].trim())}let n=t.filter(Boolean).join(`
|
|
2
|
+
import"./chunk-tpfxvw4q.js";import{Ks,Ei,pl}from"./chunk-b51p56k5.js";import"./chunk-4833k99b.js";import"./chunk-y4mp1rra.js";import"./chunk-x5seqmrv.js";import"./chunk-dvpk4c1y.js";import"./chunk-8rk79ha1.js";import"./chunk-f8p8ggvw.js";import{a}from"./chunk-edhxg3rz.js";import"./chunk-evxp3wmv.js";import"./chunk-q3azy64b.js";import"./chunk-yb71b2d6.js";import{yt,Ke,ye,on,Ae,tr,nr,Ge}from"./chunk-rd33qkfs.js";import{i}from"./chunk-t1shvfhm.js";import"./chunk-xgnmgjpv.js";import"./chunk-gwjh981q.js";import{ps}from"./chunk-yk456jp4.js";import"./chunk-m3z13f59.js";import"./chunk-b0z2n941.js";import{mt}from"./chunk-02c46de1.js";import"./chunk-wmnzapn8.js";import"./chunk-59k4xb92.js";import{es}from"./chunk-ben8bjnk.js";import{Mr}from"./chunk-v1ff2dfp.js";import{Dr,Qs,eo}from"./chunk-nm9tnxnw.js";import"./chunk-a81rt2t4.js";import"./chunk-9k8ztdcc.js";import"./chunk-932zx5q4.js";import"./chunk-k2ex94n8.js";import"./chunk-rqd6b2nc.js";import{existsSync as _e,mkdirSync as Di,readFileSync as Li}from"fs";import G from"path";import{existsSync as En,mkdirSync as Rn,realpathSync as Ti,rmSync as _n}from"fs";import H from"path";import{existsSync as ui}from"fs";import Z from"path";var Cn="data-stx-b",ft=new Set(Ei),Pn=new Set(Ks);function Oe(e){if(e==="ref"||e==="data-stx-ref")return"ref";if(e.startsWith("::"))return null;if(e.startsWith("@bind:")||e.startsWith("x-bind:"))return"attr";if(e.startsWith("@")||e.startsWith(":")){let t=e.slice(1).split(".")[0];if(ft.has(t))return t==="if"?"if":t;if(t==="for"||t==="else"||t==="else-if"||t==="elseif")return"for";if(pl(t))return"event";if(e.startsWith("@"))return"event";return"attr"}if(e.startsWith("x-")){let t=e.split(".")[0];if(!Pn.has(t))return"attr";let n=t.slice(2);if(n==="cloak"||n==="data"||n==="bind")return null;if(n==="tooltip"||n==="tooltip-position")return null;return ft.has(n)?n==="if"?"if":n:"attr"}return null}function Mn(e){let t=[];for(let[n,r]of e){let s=Oe(n);if(s)t.push({name:n,value:r,kind:s})}return t}var Bn=/<([a-z][\w-]*)((?:\s+[^\s"'=<>/]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s"'=<>`]+))?)*)\s*\/?>/gi,Ee=/([^\s"'=<>/]+)(?:\s*=\s*(?:"([^"]*)"|'([^']*)'|([^\s"'=<>`]+)))?/g;function pt(e){let t=[],n=0;return{html:e.replace(Bn,(s,o,c)=>{if(!c||!/[:@]|x-/.test(c))return s;let l=[];Ee.lastIndex=0;for(let m=Ee.exec(c);m;m=Ee.exec(c))l.push([m[1],m[2]??m[3]??m[4]??""]);let d=Mn(l);if(!d.length)return s;let p={id:n++,bindings:d};if(d.some((m)=>m.kind==="for"))p.template=!0;t.push(p);let h=s.endsWith("/>");return`${s.slice(0,h?-2:-1).trimEnd()} ${Cn}="${p.id}"${h?"/>":">"}`}),manifest:{entries:t}}}import xr from"path";function fe(e){let t=e&&/^(\d+(?:\.\d+)?|\.\d+)(px|rem)?$/.exec(e.trim());if(!t)return;let n=Number(t[1])*(t[2]==="rem"?16:1);return Number.isFinite(n)?n:void 0}function Ie(e,t){if(!ye[e])return;return fe(t?.get(on(e))??ye[e].value)}function Ce(e,t){let n=tr[e];if(!n)return;return fe(t?.get(Ge(n))??Ae[n]?.value)}function Pe(e,t){let n=nr[e];if(!n)return;let r=fe(t?.get(Ge(n.size))??Ae[n.size]?.value),s=fe(t?.get(Ge(n.leading))??Ae[n.leading]?.value);if(r===void 0||s===void 0)return;return{fontSize:r,lineHeight:s}}var Dn={sm:640,md:768,lg:1024,xl:1280,"2xl":1536},vt=Be({}),gt,ht=null;function pe(){let e=globalThis.__stxNativeStyleConfig;if(!e)return vt;if(e!==gt)gt=e,ht=Be(e);return ht}function St(e,t=new Map,n=""){for(let[r,s]of Object.entries(e??{})){let o=r==="DEFAULT"?n.replace(/-$/,""):`${n}${r}`;if(typeof s==="string")t.set(o,s);else if(s&&typeof s==="object")St(s,t,`${o}-`)}return t}function wt(e){let t={};for(let[n,r]of Object.entries(e??{})){let s=typeof r==="number"?r:Number.parseFloat(String(r));if(Number.isFinite(s))t[n]=s}return t}function Be(e){return{shortcuts:new Map(Object.entries(e.shortcuts??{}).filter(([,t])=>typeof t==="string")),colors:St(e.colors),fontFamily:new Map(Object.entries(e.fontFamily??{}).map(([t,n])=>[t,Array.isArray(n)?n.join(", "):n])),breakpoints:new Map(Object.entries({...Dn,...wt(e.breakpoints)}))}}var Me={};function bt(e){Me=e??{},vt=Be(Me)}async function xt(e,t){let n=Me;bt(e);try{return await t()}finally{bt(n)}}function Nt(e){if(!e)return{};let t=e.theme??{},n=Object.fromEntries(Object.entries(e.shortcuts??{}).filter(([,r])=>typeof r==="string"));return{...Object.keys(n).length?{shortcuts:n}:{},...t.fontFamily?{fontFamily:JSON.parse(JSON.stringify(t.fontFamily))}:{},...t.colors?{colors:JSON.parse(JSON.stringify(t.colors))}:{},...t.screens?{breakpoints:wt(t.screens)}:{}}}function kt(e){return pe().shortcuts.get(e)}function Tt(e){return pe().colors.get(e)}function De(e){return pe().breakpoints.get(e)}function ge(e){return pe().fontFamily.get(e)}var _t=/^--[\w\u0080-\uFFFF-]+$/u;function Rt(e,t){if(!/var\(/i.test(e))return e;let n="",r="",s=!1;for(let o=0;o<e.length;o++){let c=e[o];if(c==="\\"){n+=e.slice(o,o+2),o++;continue}if(r){if(n+=c,c===r)r="";continue}if(c==='"'||c==="'"){r=c,n+=c;continue}if(e.slice(o,o+4).toLowerCase()!=="var("||o>0&&/[\w-]/.test(e[o-1])){n+=c;continue}let l=1,d=-1,p="",h=o+4;for(;h<e.length;h++){let y=e[h];if(y==="\\"){h++;continue}if(p){if(y===p)p="";continue}if(y==='"'||y==="'"){p=y;continue}if(y==="(")l++;if(y===")"&&--l===0)break;if(y===","&&l===1&&d===-1)d=h}if(l!==0)return;let f=e.slice(o+4,d===-1?h:d).trim();if(!_t.test(f))return;let m=t(f,d===-1?void 0:e.slice(d+1,h).trim());if(m===void 0||n.length+m.length>65536)return;n+=m,s=!0,o=h}return s&&n.length>65536?void 0:n}function ae(e,t){let n=new Map,r=new Set;for(let[g,u]of e){let w=g.trim();if(!_t.test(w))continue;if(typeof u==="string"||typeof u==="number"&&Number.isFinite(u))n.set(w,String(u).trim())}let s=new Map,o=new Set;for(let[g,u]of n){let w=new Set,b=(N,S=0)=>S>64?void 0:Rt(N,(k,x)=>(w.add(k),x===void 0?"":b(x,S+1)));if(b(u)===void 0)o.add(g);s.set(g,w)}let c=new Map,l=new Map,d=[],p=new Set,h=0;function f(g,u=0){if(u>64){o.add(g);return}c.set(g,h),l.set(g,h++),d.push(g),p.add(g);for(let N of s.get(g)??[]){if(!n.has(N))continue;if(!c.has(N)){if(f(N,u+1),l.has(N))l.set(g,Math.min(l.get(g),l.get(N)))}else if(p.has(N))l.set(g,Math.min(l.get(g),c.get(N)))}if(l.get(g)!==c.get(g))return;let w=[],b;do b=d.pop(),p.delete(b),w.push(b);while(b!==g);if(w.length>1||s.get(g)?.has(g))w.forEach((N)=>o.add(N))}for(let g of n.keys())if(!c.has(g))f(g);let m=new Map;function y(g,u){if(r.add(g),m.has(g))return m.get(g);let w=n.get(g),b=w===void 0||/^(?:inherit|unset)$/i.test(w)?t?.get(g):o.has(g)||/^(?:initial|revert|revert-layer)$/i.test(w)?void 0:v(w,u+1);return m.set(g,b),b}function v(g,u=0){if(u>64)return;return Rt(g,(w,b)=>y(w,u)??(b===void 0?void 0:v(b,u+1)))}return{resolve:v,used:r,computed(){let g=new Map(t);for(let u of n.keys())g.set(u,y(u,0));return g}}}function Le(e){if(e.display==="flex"&&e.flexDirection==null)return{...e,flexDirection:"row"};return e}var At=new Set(["display","gridColumns","gridTemplateColumns","gridTemplateRows","gridAutoRows","flex","flexGrow","flexShrink","flexBasis","flexDirection","flexWrap","order","justifyContent","alignItems","alignSelf","alignContent","position","top","right","bottom","left","zIndex","width","height","minWidth","maxWidth","minHeight","maxHeight","aspectRatio","margin","marginTop","marginRight","marginBottom","marginLeft","marginHorizontal","marginVertical","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingHorizontal","paddingVertical","gap","rowGap","columnGap","borderWidth","borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","borderRadius","borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius","borderStyle","backgroundColor","backgroundImage","opacity","shadowColor","shadowOffset","shadowOpacity","shadowRadius","elevation","color","fontSize","fontWeight","fontStyle","fontFamily","lineHeight","letterSpacing","textAlign","textDecorationLine","textDecorationColor","textTransform","resizeMode","objectFit","objectPosition","tintColor","transform","overflow","pointerEvents","fill","stroke","strokeWidth","gradientDirection","gradientFrom","gradientVia","gradientTo"]),Ln=new Set(["gridColumns","gridAutoRows","flex","flexGrow","flexShrink","order","zIndex","aspectRatio","gap","rowGap","columnGap","borderWidth","borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth","borderRadius","borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius","opacity","shadowOpacity","shadowRadius","elevation","fontSize","lineHeight","letterSpacing","strokeWidth"]),Et=new Set(["top","right","bottom","left","width","height","minWidth","maxWidth","minHeight","maxHeight","flexBasis","margin","marginTop","marginRight","marginBottom","marginLeft","marginHorizontal","marginVertical","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingHorizontal","paddingVertical"]),Ot=/^[+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?$/i,$n=/^([+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?)(px|rem|em)?$/i,jn=new Set(["rotate","rotateX","rotateY","rotateZ","skewX","skewY"]),Vn=new Set(["perspective","scale","scaleX","scaleY","translateX","translateY"]);function Wn(e){if(typeof e!=="string")return e;let t=$n.exec(e);return t?Number(t[1])*(/^r?em$/i.test(t[2]||"")?16:1):e}function ie(e){return typeof e==="number"&&Number.isFinite(e)}function Fn(e,t){if(e==="shadowOffset"&&t&&typeof t==="object"&&!Array.isArray(t)){let{width:n,height:r}=t;return ie(n)&&ie(r)?{width:n,height:r}:void 0}if(e==="transform"&&Array.isArray(t)){let n=[];for(let r of t){if(!r||typeof r!=="object"||Array.isArray(r)||Object.keys(r).length!==1)return;let[s,o]=Object.entries(r)[0];if(Vn.has(s)&&ie(o))n.push({[s]:o});else if(jn.has(s)&&typeof o==="string"&&/^[+-]?(?:\d+\.?\d*|\.\d+)(?:deg|rad)$/.test(o))n.push({[s]:o});else return}return n}return}function Xn(e){let t=[],n=0,r=0,s="";for(let o=0;o<=e.length;o++){let c=e[o];if(c==="\\"){o++;continue}if(s){if(c===s)s="";continue}if(c==='"'||c==="'"){s=c;continue}if(c==="(")r++;if(c===")")r=Math.max(0,r-1);if(o!==e.length&&(c!==";"||r))continue;let l=e.slice(n,o),d=l.indexOf(":");if(d!==-1)t.push([l.slice(0,d).trim(),l.slice(d+1).trim()]);n=o+1}return t}function zn(e,t){let n;if(typeof e==="string"){if(e=e.trim(),!e)return[];try{e=JSON.parse(e)}catch{}}if(typeof e==="string")n=Xn(e);else if(e&&typeof e==="object"&&!Array.isArray(e))n=Object.entries(e);else{if(e!=null&&e!==!1)t({kind:"non-numeric-style",name:"style"});return[]}return n}function he(e,t=()=>{},n={}){let r=zn(e,t),s=ae(r,n.inheritedVariables);return n.onVariables?.(s.computed()),Un(r,s,t)}function Un(e,t,n){let r={},s=[];for(let[o,c]of e){if(o.trim().startsWith("--")){s.push(o.trim());continue}let l=At.has(o)||o.trim().startsWith("--")?o:o.trim().toLowerCase().replace(/-([a-z])/g,(h,f)=>f.toUpperCase());if(!At.has(l)){n({kind:"unknown-style",name:l});continue}if(c==null||c==="")continue;let d=typeof c==="string"?t.resolve(c.trim()):c;if(d===void 0){n({kind:"non-numeric-style",name:l});continue}if(d==="")continue;if(l==="pointerEvents"){if(typeof d==="string"&&["auto","none","box-none","box-only"].includes(d))r.pointerEvents=d;else n({kind:"unknown-style",name:`pointerEvents:${String(d)}`});continue}if(l==="objectFit"){let h=typeof d==="string"?d.trim().toLowerCase():"";if(["fill","contain","cover","none","scale-down"].includes(h))r.objectFit=h;else n({kind:"unknown-style",name:`objectFit:${String(d)}`});continue}if(l==="objectPosition"){let h=typeof d==="string"?d.trim().toLowerCase().replace(/\s+/g," "):"",f=h.split(" ");if(f.length===1)f.push("center");if(["top","bottom"].includes(f[0])||["left","right"].includes(f[1]))f.reverse();let m=(y)=>y.endsWith("%")&&Ot.test(y.slice(0,-1))&&Number.isFinite(Number(y.slice(0,-1)));if(f.length===2&&(["left","center","right"].includes(f[0])||m(f[0]))&&(["top","center","bottom"].includes(f[1])||m(f[1])))r.objectPosition=h;else n({kind:"unknown-style",name:`objectPosition:${String(d)}`});continue}let p;if(Ln.has(l)||Et.has(l)){if(p=Wn(d),!ie(p)&&!(Et.has(l)&&typeof p==="string"&&p.endsWith("%")&&Ot.test(p.slice(0,-1))&&Number.isFinite(Number(p.slice(0,-1)))))p=void 0}else if(l==="display"&&d==="inline-flex")p="flex";else if(l==="shadowOffset"||l==="transform")p=Fn(l,d);else if(l==="gridTemplateColumns"||l==="gridTemplateRows")p=ie(d)||typeof d==="string"?d:void 0;else if(l==="fontWeight"&&ie(d))p=String(d);else if(typeof d==="string")p=d;if(p===void 0)n({kind:"non-numeric-style",name:l});else r[l]=p}for(let o of s)if(!t.used.has(o))n({kind:"unknown-style",name:o});return r}var Hn={transparent:"transparent",current:"currentColor",black:"#000000",white:"#ffffff",slate:{50:"#f8fafc",100:"#f1f5f9",200:"#e2e8f0",300:"#cbd5e1",400:"#94a3b8",500:"#64748b",600:"#475569",700:"#334155",800:"#1e293b",900:"#0f172a",950:"#020617"},gray:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#1f2937",900:"#111827",950:"#030712"},zinc:{50:"#fafafa",100:"#f4f4f5",200:"#e4e4e7",300:"#d4d4d8",400:"#a1a1aa",500:"#71717a",600:"#52525b",700:"#3f3f46",800:"#27272a",900:"#18181b",950:"#09090b"},red:{50:"#fef2f2",100:"#fee2e2",200:"#fecaca",300:"#fca5a5",400:"#f87171",500:"#ef4444",600:"#dc2626",700:"#b91c1c",800:"#991b1b",900:"#7f1d1d",950:"#450a0a"},orange:{50:"#fff7ed",100:"#ffedd5",200:"#fed7aa",300:"#fdba74",400:"#fb923c",500:"#f97316",600:"#ea580c",700:"#c2410c",800:"#9a3412",900:"#7c2d12",950:"#431407"},amber:{50:"#fffbeb",100:"#fef3c7",200:"#fde68a",300:"#fcd34d",400:"#fbbf24",500:"#f59e0b",600:"#d97706",700:"#b45309",800:"#92400e",900:"#78350f",950:"#451a03"},yellow:{50:"#fefce8",100:"#fef9c3",200:"#fef08a",300:"#fde047",400:"#facc15",500:"#eab308",600:"#ca8a04",700:"#a16207",800:"#854d0e",900:"#713f12",950:"#422006"},green:{50:"#f0fdf4",100:"#dcfce7",200:"#bbf7d0",300:"#86efac",400:"#4ade80",500:"#22c55e",600:"#16a34a",700:"#15803d",800:"#166534",900:"#14532d",950:"#052e16"},emerald:{50:"#ecfdf5",100:"#d1fae5",200:"#a7f3d0",300:"#6ee7b7",400:"#34d399",500:"#10b981",600:"#059669",700:"#047857",800:"#065f46",900:"#064e3b",950:"#022c22"},teal:{50:"#f0fdfa",100:"#ccfbf1",200:"#99f6e4",300:"#5eead4",400:"#2dd4bf",500:"#14b8a6",600:"#0d9488",700:"#0f766e",800:"#115e59",900:"#134e4a",950:"#042f2e"},cyan:{50:"#ecfeff",100:"#cffafe",200:"#a5f3fc",300:"#67e8f9",400:"#22d3ee",500:"#06b6d4",600:"#0891b2",700:"#0e7490",800:"#155e75",900:"#164e63",950:"#083344"},sky:{50:"#f0f9ff",100:"#e0f2fe",200:"#bae6fd",300:"#7dd3fc",400:"#38bdf8",500:"#0ea5e9",600:"#0284c7",700:"#0369a1",800:"#075985",900:"#0c4a6e",950:"#082f49"},lime:{50:"#f7fee7",100:"#ecfccb",200:"#d9f99d",300:"#bef264",400:"#a3e635",500:"#84cc16",600:"#65a30d",700:"#4d7c0f",800:"#3f6212",900:"#365314",950:"#1a2e05"},fuchsia:{50:"#fdf4ff",100:"#fae8ff",200:"#f5d0fe",300:"#f0abfc",400:"#e879f9",500:"#d946ef",600:"#c026d3",700:"#a21caf",800:"#86198f",900:"#701a75",950:"#4a044e"},neutral:{50:"#fafafa",100:"#f5f5f5",200:"#e5e5e5",300:"#d4d4d4",400:"#a3a3a3",500:"#737373",600:"#525252",700:"#404040",800:"#262626",900:"#171717",950:"#0a0a0a"},stone:{50:"#fafaf9",100:"#f5f5f4",200:"#e7e5e4",300:"#d6d3d1",400:"#a8a29e",500:"#78716c",600:"#57534e",700:"#44403c",800:"#292524",900:"#1c1917",950:"#0c0a09"},blue:{50:"#eff6ff",100:"#dbeafe",200:"#bfdbfe",300:"#93c5fd",400:"#60a5fa",500:"#3b82f6",600:"#2563eb",700:"#1d4ed8",800:"#1e40af",900:"#1e3a8a",950:"#172554"},indigo:{50:"#eef2ff",100:"#e0e7ff",200:"#c7d2fe",300:"#a5b4fc",400:"#818cf8",500:"#6366f1",600:"#4f46e5",700:"#4338ca",800:"#3730a3",900:"#312e81",950:"#1e1b4b"},violet:{50:"#f5f3ff",100:"#ede9fe",200:"#ddd6fe",300:"#c4b5fd",400:"#a78bfa",500:"#8b5cf6",600:"#7c3aed",700:"#6d28d9",800:"#5b21b6",900:"#4c1d95",950:"#2e1065"},purple:{50:"#faf5ff",100:"#f3e8ff",200:"#e9d5ff",300:"#d8b4fe",400:"#c084fc",500:"#a855f7",600:"#9333ea",700:"#7e22ce",800:"#6b21a8",900:"#581c87",950:"#3b0764"},pink:{50:"#fdf2f8",100:"#fce7f3",200:"#fbcfe8",300:"#f9a8d4",400:"#f472b6",500:"#ec4899",600:"#db2777",700:"#be185d",800:"#9d174d",900:"#831843",950:"#500724"},rose:{50:"#fff1f2",100:"#ffe4e6",200:"#fecdd3",300:"#fda4af",400:"#fb7185",500:"#f43f5e",600:"#e11d48",700:"#be123c",800:"#9f1239",900:"#881337",950:"#4c0519"}},je={px:1,0:0,0.5:2,1:4,1.5:6,2:8,2.5:10,3:12,3.5:14,4:16,5:20,6:24,7:28,8:32,9:36,10:40,11:44,12:48,14:56,16:64,20:80,24:96,28:112,32:128,36:144,40:160,44:176,48:192,52:208,56:224,60:240,64:256,72:288,80:320,96:384},It={xs:12,sm:14,base:16,lg:18,xl:20,"2xl":24,"3xl":30,"4xl":36,"5xl":48,"6xl":60,"7xl":72,"8xl":96,"9xl":128},Ct={none:0,sm:2,DEFAULT:4,md:6,lg:8,xl:12,"2xl":16,"3xl":24,full:9999};function ne(e){let t=e.lastIndexOf("/");if(t>0&&(!e.endsWith("]")||/\/\[[\d.]+%?\]$/.test(e))){let r=ne(e.slice(0,t)),s=e.slice(t+1),o=/^\[(.+)\]$/.test(s)?Number.parseFloat(s.slice(1,-1))*(s.includes("%")?1:100):Number.parseFloat(s);if(!r||!Number.isFinite(o))return;return qn(r,o/100)}if(e==="transparent")return"transparent";if(e==="current")return"currentColor";if(e==="black")return"#000000";if(e==="white")return"#ffffff";let n=e.split("-");if(n.length===2){let[r,s]=n,o=Hn[r];if(o&&typeof o==="object")return o[s]}if(e.startsWith("[")&&e.endsWith("]")){let r=e.slice(1,-1);return/^(#|rgba?\(|hsla?\(|[a-z]+$)/i.test(r)?r:void 0}return}function Ve(e){return ne(e.trim())}function qn(e,t){if(e==="transparent")return e;let n=e.startsWith("#")?e.slice(1):"";if(n.length===3)n=n.split("").map((s)=>s+s).join("");if(n.length===8)n=n.slice(0,6);if(n.length!==6)return;let r=Math.round(Math.min(1,Math.max(0,t))*255);return`#${n}${r.toString(16).padStart(2,"0")}`}function $e(e,t=16){if(!e.startsWith("[")||!e.endsWith("]"))return;let n=e.slice(1,-1),r=Number.parseFloat(n);if(!Number.isFinite(r))return;if(n.endsWith("rem"))return r*16;if(n.endsWith("em"))return r*t;return r}function X(e){if(e.startsWith("[")&&e.endsWith("]")){let t=e.slice(1,-1);if(t.endsWith("%"))return;let n=t.endsWith("rem")?Number.parseFloat(t)*16:Number.parseFloat(t);return Number.isFinite(n)?n:void 0}return je[e]??Ce(e)}function be(e){let t=/^\[(-?\d*\.?\d+)%\]$/.exec(e);if(t)return`${Number.parseFloat(t[1])}%`;return X(e)}var Gn={flex:(e,t)=>(t.display="flex",!0),block:(e,t)=>(t.display="flex",!0),hidden:(e,t)=>(t.display="none",!0),grid:(e,t)=>(t.display="grid",!0),"flex-row":(e,t)=>(t.flexDirection="row",!0),"flex-col":(e,t)=>(t.flexDirection="column",!0),"flex-row-reverse":(e,t)=>(t.flexDirection="row-reverse",!0),"flex-col-reverse":(e,t)=>(t.flexDirection="column-reverse",!0),"flex-wrap":(e,t)=>(t.flexWrap="wrap",!0),"flex-nowrap":(e,t)=>(t.flexWrap="nowrap",!0),"flex-wrap-reverse":(e,t)=>(t.flexWrap="wrap-reverse",!0),"flex-1":(e,t)=>(t.flex=1,t.flexGrow=1,t.flexShrink=1,t.flexBasis=0,!0),"flex-auto":(e,t)=>(t.flexGrow=1,t.flexShrink=1,!0),"flex-initial":(e,t)=>(t.flexGrow=0,t.flexShrink=1,!0),"flex-none":(e,t)=>(t.flexGrow=0,t.flexShrink=0,!0),grow:(e,t)=>(t.flexGrow=1,!0),"grow-0":(e,t)=>(t.flexGrow=0,!0),shrink:(e,t)=>(t.flexShrink=1,!0),"shrink-0":(e,t)=>(t.flexShrink=0,!0),"order-first":(e,t)=>(t.order=-9999,!0),"order-last":(e,t)=>(t.order=9999,!0),"order-none":(e,t)=>(t.order=0,!0),"justify-start":(e,t)=>(t.justifyContent="flex-start",!0),"justify-center":(e,t)=>(t.justifyContent="center",!0),"justify-end":(e,t)=>(t.justifyContent="flex-end",!0),"justify-between":(e,t)=>(t.justifyContent="space-between",!0),"justify-around":(e,t)=>(t.justifyContent="space-around",!0),"justify-evenly":(e,t)=>(t.justifyContent="space-evenly",!0),"items-start":(e,t)=>(t.alignItems="flex-start",!0),"items-center":(e,t)=>(t.alignItems="center",!0),"items-end":(e,t)=>(t.alignItems="flex-end",!0),"items-stretch":(e,t)=>(t.alignItems="stretch",!0),"items-baseline":(e,t)=>(t.alignItems="baseline",!0),"self-auto":(e,t)=>(t.alignSelf="auto",!0),"self-start":(e,t)=>(t.alignSelf="flex-start",!0),"self-center":(e,t)=>(t.alignSelf="center",!0),"self-end":(e,t)=>(t.alignSelf="flex-end",!0),"self-stretch":(e,t)=>(t.alignSelf="stretch",!0),"self-baseline":(e,t)=>(t.alignSelf="baseline",!0),"min-w-0":(e,t)=>(t.minWidth=0,!0),"aspect-square":(e,t)=>(t.aspectRatio=1,!0),"aspect-video":(e,t)=>(t.aspectRatio=1.7777777777777777,!0),"border-solid":(e,t)=>(t.borderStyle="solid",!0),"border-dashed":(e,t)=>(t.borderStyle="dashed",!0),"border-dotted":(e,t)=>(t.borderStyle="dotted",!0),group:()=>!0,peer:()=>!0,"inset-0":(e,t)=>(t.top=0,t.right=0,t.bottom=0,t.left=0,!0),"mx-auto":(e,t)=>(t.alignSelf="center",!0),fixed:(e,t)=>(t.position="absolute",!0),sticky:()=>!0,"sr-only":(e,t)=>(t.position="absolute",t.width=1,t.height=1,t.overflow="hidden",!0),inline:()=>!0,"inline-block":()=>!0,contents:()=>!0,"align-top":()=>!0,"align-middle":()=>!0,"align-bottom":()=>!0,"align-baseline":()=>!0,"align-text-top":()=>!0,"whitespace-normal":()=>!0,"whitespace-pre":()=>!0,"whitespace-pre-line":()=>!0,"whitespace-pre-wrap":()=>!0,"whitespace-nowrap":()=>!0,"break-words":()=>!0,"break-all":()=>!0,"break-normal":()=>!0,"object-cover":()=>!0,"object-contain":()=>!0,"object-fill":()=>!0,"object-center":()=>!0,"tracking-tighter":(e,t)=>(t.letterSpacing=-0.8,!0),"tracking-tight":(e,t)=>(t.letterSpacing=-0.4,!0),"tracking-normal":(e,t)=>(t.letterSpacing=0,!0),"tracking-wide":(e,t)=>(t.letterSpacing=0.4,!0),"tracking-wider":(e,t)=>(t.letterSpacing=0.8,!0),"tracking-widest":(e,t)=>(t.letterSpacing=1.6,!0),"tabular-nums":()=>!0,"inline-flex":(e,t)=>(t.display="flex",!0),truncate:()=>!0,relative:(e,t)=>(t.position="relative",!0),absolute:(e,t)=>(t.position="absolute",!0),"pointer-events-none":(e,t)=>(t.pointerEvents="none",!0),"pointer-events-auto":(e,t)=>(t.pointerEvents="auto",!0),"overflow-visible":(e,t)=>(t.overflow="visible",!0),"overflow-hidden":(e,t)=>(t.overflow="hidden",!0),"overflow-scroll":(e,t)=>(t.overflow="scroll",!0),"overflow-x-auto":()=>!0,"overflow-x-scroll":()=>!0,"overflow-y-auto":()=>!0,"overflow-y-scroll":()=>!0,"font-sans":(e,t)=>(t.fontFamily=ge("sans")??"sans-serif",!0),"font-serif":(e,t)=>(t.fontFamily=ge("serif")??"serif",!0),"font-mono":(e,t)=>(t.fontFamily=ge("mono")??"monospace",!0),"font-thin":(e,t)=>(t.fontWeight="100",!0),"font-extralight":(e,t)=>(t.fontWeight="200",!0),"font-light":(e,t)=>(t.fontWeight="300",!0),"font-normal":(e,t)=>(t.fontWeight="400",!0),"font-medium":(e,t)=>(t.fontWeight="500",!0),"font-semibold":(e,t)=>(t.fontWeight="600",!0),"font-bold":(e,t)=>(t.fontWeight="bold",!0),"font-extrabold":(e,t)=>(t.fontWeight="800",!0),"font-black":(e,t)=>(t.fontWeight="900",!0),italic:(e,t)=>(t.fontStyle="italic",!0),"not-italic":(e,t)=>(t.fontStyle="normal",!0),"text-left":(e,t)=>(t.textAlign="left",!0),"text-center":(e,t)=>(t.textAlign="center",!0),"text-right":(e,t)=>(t.textAlign="right",!0),"text-justify":(e,t)=>(t.textAlign="justify",!0),uppercase:(e,t)=>(t.textTransform="uppercase",!0),lowercase:(e,t)=>(t.textTransform="lowercase",!0),capitalize:(e,t)=>(t.textTransform="capitalize",!0),"normal-case":(e,t)=>(t.textTransform="none",!0),underline:(e,t)=>(t.textDecorationLine="underline",!0),"line-through":(e,t)=>(t.textDecorationLine="line-through",!0),"no-underline":(e,t)=>(t.textDecorationLine="none",!0)};function Jn(e,t){if(!e.startsWith("bg-"))return!1;let n=e.slice(3),r=ne(n);if(r)return t.backgroundColor=r,!0;return!1}function Pt(e,t){if(!e.startsWith("text-"))return!1;let n=e.slice(5),r=Pe(n);if(r)return Object.assign(t,r),!0;if(It[n])return t.fontSize=It[n],!0;if(n.startsWith("[")&&n.endsWith("]")){let o=n.slice(1,-1);if(/^-?[\d.]+(?:px|r?em)?$/.test(o)){let c=o.endsWith("rem")||o.endsWith("em")?Number.parseFloat(o)*16:Number.parseFloat(o);if(Number.isFinite(c))return t.fontSize=c,!0}}let s=ne(n);if(s)return t.color=s,!0;return!1}var Kn=new Set(["t","tr","r","br","b","bl","l","tl"]);function Yn(e,t){let n=/^bg-(?:gradient|linear)-to-([a-z]+)$/.exec(e);if(n&&Kn.has(n[1]))return t.gradientDirection=`to-${n[1]}`,!0;let r=/^(from|via|to)-(.+)$/.exec(e);if(!r)return!1;let s=ne(r[2]);if(!s)return!1;if(r[1]==="from")t.gradientFrom=s;else if(r[1]==="via")t.gradientVia=s;else t.gradientTo=s;return!0}function Qn(e,t){for(let n of["fill","stroke"]){let r=`${n}-`;if(!e.startsWith(r))continue;let s=e.slice(r.length);if(s==="none")return t[n]="none",!0;if(n==="stroke"&&/^\d+(?:\.\d+)?$/.test(s))return t.strokeWidth=Number.parseFloat(s),!0;if(n==="stroke"&&/^\[\d+(?:\.\d+)?(?:px)?\]$/.test(s))return t.strokeWidth=Number.parseFloat(s.slice(1)),!0;let o=ne(s);if(o)return t[n]=o,!0}return!1}function Zn(e,t){if(e.startsWith("p-")){let n=X(e.slice(2));if(n!==void 0)return t.padding=n,!0}if(e.startsWith("px-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingHorizontal=n,!0}if(e.startsWith("py-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingVertical=n,!0}if(e.startsWith("pt-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingTop=n,!0}if(e.startsWith("pr-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingRight=n,!0}if(e.startsWith("pb-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingBottom=n,!0}if(e.startsWith("pl-")){let n=X(e.slice(3));if(n!==void 0)return t.paddingLeft=n,!0}return!1}function Bt(e,t){if(/^-(?:m|mx|my|mt|mr|mb|ml)-/.test(e)){let n={};if(!Bt(e.slice(1),n))return!1;let r=Object.entries(n);if(r.some(([,s])=>typeof s!=="number"))return!1;for(let[s,o]of r)t[s]=-o;return!0}if(e.startsWith("m-")){let n=X(e.slice(2));if(n!==void 0)return t.margin=n,!0}if(e.startsWith("mx-")){let n=X(e.slice(3));if(n!==void 0)return t.marginHorizontal=n,!0}if(e.startsWith("my-")){let n=X(e.slice(3));if(n!==void 0)return t.marginVertical=n,!0}if(e.startsWith("mt-")){let n=X(e.slice(3));if(n!==void 0)return t.marginTop=n,!0}if(e.startsWith("mr-")){let n=X(e.slice(3));if(n!==void 0)return t.marginRight=n,!0}if(e.startsWith("mb-")){let n=X(e.slice(3));if(n!==void 0)return t.marginBottom=n,!0}if(e.startsWith("ml-")){let n=X(e.slice(3));if(n!==void 0)return t.marginLeft=n,!0}return!1}function er(e,t){if(!e.startsWith("w-"))return!1;let n=e.slice(2);if(n==="full")return t.width="100%",!0;if(n==="screen")return t.width="100%",!0;if(n==="auto")return t.width="auto",!0;if(n.includes("/")){let[s,o]=n.split("/"),c=Number.parseInt(s)/Number.parseInt(o)*100;return t.width=`${c}%`,!0}let r=be(n);if(r!==void 0)return t.width=r,!0;return!1}function rr(e,t){if(!e.startsWith("h-"))return!1;let n=e.slice(2);if(n==="full")return t.height="100%",!0;if(n==="screen")return t.height="100%",!0;if(n==="auto")return t.height="auto",!0;let r=be(n);if(r!==void 0)return t.height=r,!0;return!1}function ir(e,t){if(e==="rounded")return t.borderRadius=Ct.DEFAULT,!0;if(!e.startsWith("rounded-"))return!1;let n=e.slice(8);if(n==="")return!1;let r=/^(?:(tl|tr|bl|br|t|b|l|r)-)?(.+)$/.exec(n),s=Ct[r[2]]??Ie(r[2])??$e(r[2]);if(s===void 0)return!1;let o={t:["borderTopLeftRadius","borderTopRightRadius"],b:["borderBottomLeftRadius","borderBottomRightRadius"],l:["borderTopLeftRadius","borderBottomLeftRadius"],r:["borderTopRightRadius","borderBottomRightRadius"],tl:["borderTopLeftRadius"],tr:["borderTopRightRadius"],bl:["borderBottomLeftRadius"],br:["borderBottomRightRadius"]};for(let c of r[1]?o[r[1]]:["borderRadius"])t[c]=s;return!0}function sr(e,t){let n=/^border(?:-([trblxy]))?(?:-(\d+|\[[^\]]+\]))?$/.exec(e);if(!n)return!1;let[,r="",s]=n,o=s===void 0?1:Number(s);if(s?.startsWith("[")){let l=/^\[(\d+(?:\.\d+)?|\.\d+)(px|rem)?\]$/.exec(s);if(!l)return!1;o=Number(l[1])*(l[2]==="rem"?16:1)}if(!Number.isFinite(o)||o<0)return!1;let c={"":["borderWidth"],t:["borderTopWidth"],r:["borderRightWidth"],b:["borderBottomWidth"],l:["borderLeftWidth"],x:["borderLeftWidth","borderRightWidth"],y:["borderTopWidth","borderBottomWidth"]};for(let l of c[r])t[l]=o;return!0}function or(e,t){if(!e.startsWith("border-"))return!1;let n=e.slice(7),r=ne(n);if(r)return t.borderColor=r,!0;return!1}function ar(e,t){if(!e.startsWith("opacity-"))return!1;let n=Number.parseInt(e.slice(8));if(!Number.isNaN(n))return t.opacity=n/100,!0;return!1}function cr(e,t,n){if(e.startsWith("tracking-[")){let r=$e(e.slice(9),n);if(r===void 0)return!1;return t.letterSpacing=r,!0}if(e.startsWith("leading-")){let r=e.slice(8),s=n,o={none:1,tight:1.25,snug:1.375,normal:1.5,relaxed:1.625,loose:2},c=r.startsWith("[")?/^\[[\d.]+\]$/.test(r)?Number.parseFloat(r.slice(1,-1))*s:$e(r,s):o[r]!==void 0?o[r]*s:je[r];if(c===void 0||!Number.isFinite(c))return!1;return t.lineHeight=c,!0}return!1}function lr(e,t){let n=/^(-?)(inset-x|inset-y|inset|top|right|bottom|left)-(.+)$/.exec(e);if(!n)return!1;let r=n[3],s=/^\[(-?[\d.]+)px\]$/.exec(r),o=s?Number(s[1]):je[r];if(o===void 0||!Number.isFinite(o))return!1;let c=n[1]?-o:o,l=n[2]==="inset"?["top","right","bottom","left"]:n[2]==="inset-x"?["left","right"]:n[2]==="inset-y"?["top","bottom"]:[n[2]];for(let d of l)t[d]=c;return!0}function ur(e,t){let n=/^grid-cols-\[(.+)\]$/.exec(e);if(n)return t.gridColumns=n[1].split("_").filter(Boolean).length,!0;let r=/^grid-cols-(\d+)$/.exec(e);if(!r)return!1;return t.gridColumns=Number(r[1]),!0}function dr(e,t){if(!e.startsWith("size-"))return!1;let n=e.slice(5),r=n==="full"?"100%":be(n);if(r===void 0)return!1;return t.width=r,t.height=r,!0}var fr={xs:320,sm:384,md:448,lg:512,xl:576,"2xl":672,"3xl":768,"4xl":896,"5xl":1024,"6xl":1152,"7xl":1280};function pr(e,t){let n=/^(min|max)-(w|h)-(.+)$/.exec(e);if(!n)return!1;let[,r,s,o]=n,c=o==="full"||o==="screen"?"100%":o==="none"?void 0:s==="w"&&r==="max"&&fr[o]||be(o);if(c===void 0&&o!=="none")return!1;let l=`${r}${s==="w"?"Width":"Height"}`;if(c===void 0)delete t[l];else t[l]=c;return!0}function gr(e,t){let n=/^(-?)(top|right|bottom|left)-(.+)$/.exec(e);if(!n)return!1;let r=n[3]==="full"?"100%":X(n[3]);if(r===void 0)return!1;return t[n[2]]=typeof r==="number"&&n[1]?-r:r,!0}function hr(e,t){let n=/^(-?)translate-(x|y)-(.+)$/.exec(e);if(!n)return!1;let r=n[3],s;if(r.startsWith("[")){let l=/^\[([+-]?(?:\d+\.?\d*|\.\d+))(px|rem|em)?\]$/.exec(r);if(!l)return!1;s=Number(l[1])*(l[2]?.endsWith("em")?16:1)}else s=X(r);if(s===void 0||!Number.isFinite(s))return!1;if(n[1])s=-s;let o=n[2]==="x"?"translateX":"translateY",c=o==="translateX"?{translateX:s}:{translateY:s};return t.transform=[...(t.transform??[]).filter((l)=>!(o in l)),c],!0}function mr(e,t){let n=/^space-(x|y)-(.+)$/.exec(e);if(!n)return!1;let r=X(n[2]);if(r===void 0)return!1;return t.gap=r,!0}function yr(e,t){if(e.startsWith("gap-")){let n=X(e.slice(4));if(n!==void 0)return t.gap=n,!0}if(e.startsWith("gap-x-")){let n=X(e.slice(6));if(n!==void 0)return t.columnGap=n,!0}if(e.startsWith("gap-y-")){let n=X(e.slice(6));if(n!==void 0)return t.rowGap=n,!0}return!1}function br(e,t){let r={"shadow-none":[0,0,0,0],"shadow-xs":[1,1,0.05,1],"shadow-sm":[2,1,0.1,2],shadow:[3,2,0.12,3],"shadow-md":[6,4,0.15,4],"shadow-lg":[10,6,0.18,8],"shadow-xl":[16,10,0.2,12],"shadow-2xl":[24,16,0.25,18]}[e];if(!r)return!1;let[s,o,c,l]=r;return Object.assign(t,{shadowColor:"#000000",shadowOpacity:c,shadowRadius:s,shadowOffset:{width:0,height:o},elevation:l}),!0}function vr(e){let t=/^divide-(?:(y|x)(?:-(.+))?|(.+))$/.exec(e);if(!t)return null;if(t[2]==="reverse")return"";if(t[1])return`border-${t[1]==="y"?"t":"l"}${t[2]?`-${t[2]}`:""}`;return`border-${t[3]}`}var Dt=new Set(["aria-selected","aria-pressed","aria-checked","aria-expanded"]),Sr=new Set(["hover","group-hover","peer-hover","active","group-active","visited","placeholder","selection","print","motion-safe"]),wr=/^(?:transition(?:-[a-z]+)?|animate-\S+|scroll-[mp][trblxyse]?-\S+|snap-\S+|overscroll-\S+|duration-\S+|ease-\S+|delay-\S+|will-change-\S+|cursor-\S+|select-(?:none|text|all|auto)|outline-none|outline-0|appearance-none|scroll-smooth|scroll-auto|antialiased|subpixel-antialiased|touch-\S+|resize(?:-\S+)?|backdrop-blur(?:-\S+)?|isolate|contain-\S+)$/;function Lt(e){let t=[],n=0,r=0;for(let s=0;s<e.length;s++){let o=e[s];if(o==="[")n++;else if(o==="]")n=Math.max(0,n-1);else if(o===":"&&n===0)t.push(e.slice(r,s)),r=s+1}return t.push(e.slice(r)),t}function $t(e,t=new Set){let n=Lt(e),r=n[n.length-1],s=t.has(r)?void 0:kt(r);if(s===void 0)return[e];let o=n.slice(0,-1).map((l)=>`${l}:`).join(""),c=new Set(t).add(r);return s.split(/\s+/).filter(Boolean).flatMap((l)=>$t(`${o}${l}`,c))}function ve(e,t,n={}){let r=new Map,s=(v,g)=>{if(!r.has(v))r.set(v,{...g,classes:[],authored:new Map});return r.get(v)};s("base",{});let o=[],c=[],l=e.split(/\s+/).filter(Boolean);if(n.rules){let v=new Set(l);for(let g of Object.keys(n.rules))if(g.includes(".")&&g.split(".").every((u)=>v.has(u)))c.push(g);c.sort((g,u)=>g.split(".").length-u.split(".").length)}for(let v of l){if(n.rules&&Object.hasOwn(n.rules,v)){o.push(v);continue}for(let g of $t(v)){let u=Lt(g),w=u.pop(),b=u.some((C)=>C.startsWith("focus"));if(u.some((C)=>/^(?:group-|peer-)?focus(?:-visible|-within)?$/.test(C))&&/^(?:ring|outline)(?:-|$)/.test(w))continue;if(wr.test(w)||!b&&u.some((C)=>Sr.has(C)))continue;let N,S,k=!1,x,A=[];for(let C of u){let E=De(C),O=C.startsWith("max-")?De(C.slice(4)):void 0;if(E!==void 0&&N===void 0)N=E;else if(O!==void 0&&S===void 0)S=O-0.02;else if(C==="disabled"&&!k)k=!0;else if(Dt.has(C)&&x===void 0)x=C;else A.push(C)}let M=[...A,w].join(":"),j=N!==void 0||S!==void 0,_=k?s("disabled",{disabled:!0}):x?s(`state:${x}`,{state:x}):j?s(`range:${N??0}:${S??""}`,{min:N??0,max:S}):r.get("base");if((k||x)&&(j||k&&x)){r.get("base").authored.set(g,v),r.get("base").classes.push(g);continue}if(_.classes.push(M),!_.authored.has(M))_.authored.set(M,v===g?g:`${v} (${g})`)}}let d=[...o,...c],p=(v,g)=>g.map((u)=>v.authored.get(u)??u),h=r.get("base"),f=me(h.classes.join(" "),t,n),m=new Map;if(d.length){let v=(w)=>w?he(w,()=>{},{inheritedVariables:t}):{},g={},u={};for(let w of d){let b=n.rules[w];g={...g,...v(b.light)},u={...u,...v(b.dark)};for(let N of b.responsive??[]){let S=`${N.min}:${N.max??""}`,k=m.get(S)??{min:N.min,...N.max===void 0?{}:{max:N.max},style:{}};if(k.style={...k.style,...v(N.light)},N.dark)k.dark={...k.dark,...v(N.dark)};m.set(S,k)}}if(f.style={...g,...f.style},Object.keys(u).length)f.dark={...u,...f.dark}}f.unknown=p(h,f.unknown);let y=[];for(let v of r.values()){if(v===h)continue;let g=me(v.classes.join(" "),t,{appearance:n.appearance});f.unknown=[...new Set([...f.unknown,...p(v,g.unknown)])];let u={style:g.style,...g.dark?{dark:g.dark}:{}};if(v.disabled)f.disabled=u;else if(v.state)(f.states??={})[v.state]=u;else y.push({min:v.min??0,...v.max===void 0?{}:{max:v.max},...u})}for(let v of m.values()){let g=y.find((u)=>u.min===v.min&&u.max===v.max);if(g){if(g.style={...v.style,...g.style},v.dark||g.dark)g.dark={...v.dark,...g.dark}}else y.push(v)}if(y.length)f.responsive=y.sort((v,g)=>v.min-g.min||(v.max??1/0)-(g.max??1/0));return f}function me(e,t,n={}){let r=[],s=[],o=[],c=[],l={focus:{classes:[],originals:new Map},focusWithin:{classes:[],originals:new Map}},d=new Map;function p(b,N){let S=/^(bg|text|border(?:-[trblxy])?|from|via|to|fill|stroke|divide|decoration|caret|accent)-(.+?)(\/[^\s]+)?$/.exec(b),k=S&&Tt(S[2]);if(S&&k){let _=/^var\(\s*(--[\w-]+)\s*(?:,\s*(.+?)\s*)?\)$/.exec(k),C=_?t?.get(_[1])??_[2]:k;if(C&&/^(?:#[0-9a-f]{3,8}|rgba?\(.+\)|hsla?\(.+\))$/i.test(C))return[`${S[1]}-[${C.replace(/\s+/g,"")}]${S[3]||""}`]}let x=/^(text|bg|border|ring)-([a-z-]+)(\/[^\s]+)?$/.exec(b),A=x&&yt[x[2]];if(A){let _=t?.get(Ke(x[2]));return[`${x[1]}-${_===void 0?A[N]:`[${_}]`}${x[3]||""}`]}let M=/^rounded-(?:(tl|tr|bl|br|t|b|l|r)-)?(.+)$/.exec(b);if(M&&ye[M[2]]){let _=Ie(M[2],t);return _===void 0?void 0:[`rounded-${M[1]?`${M[1]}-`:""}[${_}px]`]}let j=b.startsWith("text-")?b.slice(5):"";if(nr[j]){let _=Pe(j,t);return _&&[`text-[${_.fontSize}px]`,`leading-[${_.lineHeight}px]`]}for(let _ of Object.keys(tr)){if(!b.endsWith(`-${_}`))continue;let C=Ce(_,t);return C===void 0?void 0:[`${b.slice(0,-_.length)}[${C}px]`]}return[b]}function h(b,N){if(!d.has(b))d.set(b,new Set);return d.get(b).add(N),b}let f=[],m=new Map;for(let b of e.split(/\s+/).filter(Boolean)){let N=b.startsWith("dark:")?b.slice(5):b,S=vr(N);if(S!==null){let A=S&&`${b===N?"":"dark:"}${S}`;if(A)f.push(A),m.set(A,b);continue}let k=/^(dark:)?(focus|focus-within):(dark:)?(.+)$/.exec(b),x=k?.[2]==="focus"?"focus":"focusWithin";if(k&&n[x]&&!(k[1]&&k[3])){let A=`${k[1]||k[3]?"dark:":""}${k[4]}`,M=l[x];M.classes.push(A),M.originals.set(A,[...M.originals.get(A)??[],b]);continue}if(b.startsWith("dark:")){let A=p(b.slice(5),"dark");if(!A)c.push(b);else s.push(...A.map((M)=>h(M,b)))}else if(!b.includes(":")||b.startsWith("[")){let A=p(b,n.appearance??"light"),M=p(b,"dark");if(!A||!M){c.push(b);continue}if(r.push(...A.map((j)=>h(j,b))),M.join(" ")!==A.join(" "))o.push(...M.map((j)=>h(j,b)))}else c.push(b)}let y=[],v=Mt(r,y),g={style:v,unknown:y},u=[...n.appearance===void 0?o:[],...s];if(u.length)g.dark=Mt(u,y);if(v.transform&&g.dark?.transform){let b=new Set(g.dark.transform.flatMap((N)=>Object.keys(N)));g.dark.transform=[...v.transform.filter((N)=>!Object.keys(N).some((S)=>b.has(S))),...g.dark.transform]}for(let b of r){if(b==="truncate"||b==="whitespace-nowrap")g.numberOfLines=1;let N=/^object-(cover|contain|fill)$/.exec(b);if(N)g.resizeMode=N[1]==="fill"?"stretch":N[1];let S=/^line-clamp-(\d+)$/.exec(b);if(S)g.numberOfLines=Number(S[1]);if(!g.icon&&/^i-[a-z0-9]+-[a-z0-9-]+$/.test(b))g.icon=b}let w=y.flatMap((b)=>[...d.get(b)??[b]]);if(g.unknown=[...new Set([...w.filter((b)=>!/^line-clamp-\d+$/.test(b)),...c])],f.length){let b=me(f.join(" "),t,{appearance:n.appearance});g.divide={style:b.style,...b.dark?{dark:b.dark}:{}},g.unknown=[...new Set([...g.unknown,...b.unknown.map((N)=>m.get(N)??N)])]}for(let b of["focus","focusWithin"]){let N=l[b];if(!N.classes.length)continue;let S=me(N.classes.join(" "),t,{appearance:n.appearance});g[b]={style:S.style,dark:S.dark},g.unknown=[...new Set([...g.unknown,...S.unknown.flatMap((k)=>N.originals.get(k)??[k])])];for(let k of N.classes)if(/^(?:dark:)?(?:truncate|line-clamp-\d+|i-[a-z0-9]+-.+)$/.test(k))g.unknown.push(...N.originals.get(k))}return g}function Mt(e,t){let n={},r=Array.isArray(e)?e:e.split(/\s+/).filter(Boolean),s={};for(let c of r)if(c.startsWith("text-"))Pt(c,s);let o=typeof s.fontSize==="number"?s.fontSize:16;for(let c of r){if(/^i-[a-z0-9]+-/.test(c))continue;let l=Gn[c];if(l){l("",n);continue}if(br(c,n))continue;if(Yn(c,n))continue;if(Jn(c,n))continue;if(Qn(c,n))continue;if(Pt(c,n))continue;if(Zn(c,n))continue;if(Bt(c,n))continue;if(er(c,n))continue;if(rr(c,n))continue;if(ir(c,n))continue;if(sr(c,n))continue;if(or(c,n))continue;if(ar(c,n))continue;if(yr(c,n))continue;if(cr(c,n,o))continue;if(dr(c,n))continue;if(pr(c,n))continue;if(ur(c,n))continue;let d=/^aspect-\[(\d+(?:\.\d+)?)\/(\d+(?:\.\d+)?)\]$/.exec(c);if(d&&Number(d[2])>0){n.aspectRatio=Number(d[1])/Number(d[2]);continue}let p=/^z-\[(-?\d+)\]$/.exec(c)??/^z-(\d+)$/.exec(c);if(p){n.zIndex=Number(p[1]);continue}if(c==="z-auto")continue;if(lr(c,n))continue;let h=/^order-\[(-?\d+)\]$/.exec(c)??/^order-(-?\d+)$/.exec(c);if(h){n.order=Number(h[1]);continue}if(gr(c,n))continue;if(hr(c,n))continue;if(mr(c,n))continue;if(t?.push(c),typeof process<"u"&&process.env?.NODE_ENV==="development")console.warn(`[STX Native] Unknown Headwind class: ${c}`)}return n}var jt=new Map;function Vt(e,t){if(!e)return;let n=e.trim(),r=n.lastIndexOf("-"),s=r===-1?t[n]:t[n.slice(0,r)],o=r===-1?s:s?.[n.slice(r+1)];if(typeof o==="string"&&/^#[\da-f]{3,8}$/i.test(o))return o;return Ve(n)??Ve(`[${n}]`)}function Nr(e){let t=e.roles??{},n=e.shapes??{},r=e.density??{},s={...e.theme?.colors,...e.theme?.extend?.colors},o=[],c=[];for(let[l,d]of Object.entries(t)){if(!yt[l])continue;let p=Vt(typeof d==="string"?d:d?.light,s),h=Vt(typeof d==="string"?d:d?.dark,s);if(p)o.push(`${Ke(l)}: ${p};`);if(h)c.push(`${Ke(l)}: ${h};`)}for(let[l,d]of Object.entries(n))if(ye[l])o.push(`${on(l)}: ${d};`);for(let[l,d]of Object.entries(r))if(Ae[l])o.push(`${Ge(l)}: ${d};`);return[o.length?`:root { ${o.join(" ")} }`:"",c.length?`.dark { ${c.join(" ")} }`:""].filter(Boolean).join(`
|
|
3
|
+
`)}async function kr(e){let{resolveUserCssConfig:t}=await import("./chunk-p2se8s6r.js"),n=await t(e);return n?Nr(n):""}function Wt(e){let t=xr.resolve(e),n=jt.get(t);if(!n)n=kr(t).catch(()=>""),jt.set(t,n);return n}var Xt={"aria-pressed":"selected","aria-selected":"selected","aria-checked":"checked","aria-disabled":"disabled","aria-expanded":"expanded","aria-busy":"busy"},Ft={alert:"alert",button:"button",checkbox:"checkbox",combobox:"combobox",header:"header",heading:"header",image:"image",img:"image",link:"link",menu:"menu",menubar:"menubar",menuitem:"menuitem",none:"none",presentation:"none",progressbar:"progressbar",radio:"radio",scrollbar:"scrollbar",search:"search",searchbox:"search",slider:"adjustable",spinbutton:"spinbutton",switch:"switch",tab:"tab",tablist:"tablist",timer:"timer",toolbar:"toolbar"};function Tr(e){return e==="role"||e==="aria-label"||e==="aria-valuetext"||e in Xt}function Rr(e,t){if(t===void 0||t===null)return;let n=String(t).trim().toLowerCase();if(n==="mixed")return e==="aria-checked"?"mixed":!0;if(n==="undefined")return;return n===""||n==="true"}function _r(e){if(e===void 0||e===null)return null;for(let t of String(e).trim().toLowerCase().split(/\s+/))if(Ft[t])return Ft[t];return null}function Ar(e,t,n){if(e==="aria-label")return{accessibilityLabel:t===void 0||t===null||t===""?null:String(t)};if(e==="aria-valuetext")return{accessibilityValue:t===void 0||t===null||t===""?null:String(t)};if(e==="role")return{accessibilityRole:_r(t)};let r=Xt[e];if(!r)return;let s=n.accessibilityState,o=s&&typeof s==="object"?{...s}:{},c=Rr(e,t);if(c===void 0)delete o[r];else o[r]=c;return{accessibilityState:Object.keys(o).length?o:null}}function Er(e){let t=e.accessibilityState&&typeof e.accessibilityState==="object"?e.accessibilityState:void 0,n={};for(let[s,o]of Object.entries(e)){if(!Tr(s))continue;let c=Ar(s,o,n);if(c)Object.assign(n,c)}for(let s of["accessibilityLabel","accessibilityRole","accessibilityValue"])if(e[s]===void 0&&n[s]!==void 0&&n[s]!==null)e[s]=n[s];let r=n.accessibilityState;if(r)e.accessibilityState={...r,...t}}var We=["accessibilityLabel","accessibilityRole","accessibilityState","accessibilityValue"];function Fe(e,t){let n={...e};if(Er(n),t==="Image"&&n.accessibilityLabel===void 0&&e.alt!=null&&e.alt!=="")n.accessibilityLabel=String(e.alt);return Object.fromEntries(We.filter((r)=>(r in n)).map((r)=>[r,n[r]]))}var Ut=["keyboardType","secureTextEntry","returnKeyType","autoCapitalize","autoCorrect","editable","autoComplete"],Or=new Set(["type","inputmode","inputMode","enterkeyhint","enterKeyHint","autoCapitalize","autoCorrect","spellcheck","readonly","readOnly","disabled",...Ut]),Ir={numeric:"number-pad",decimal:"decimal-pad",tel:"phone-pad",email:"email-address",url:"url",search:"web-search",text:"default"},Cr={email:{keyboardType:"email-address",verbatim:!0,autoComplete:"email"},tel:{keyboardType:"phone-pad",autoComplete:"tel"},url:{keyboardType:"url",verbatim:!0,autoComplete:"url"},number:{keyboardType:"decimal-pad"},search:{keyboardType:"web-search",returnKeyType:"search"},password:{secure:!0,verbatim:!0}},Pr={enter:"default",done:"done",go:"go",next:"next",previous:"default",search:"search",send:"send"};function se(e){return e===void 0||e===null?"":String(e).trim().toLowerCase()}function zt(e){if(e===void 0||e===null||e===!1)return!1;return se(e)!=="false"}function Xe(e,...t){for(let n of t)if(e[n]!==void 0&&e[n]!==null)return e[n];return}function Ht(e,t){if(e!=="TextInput")return{};let n={},r=se(t.type),s=Cr[r]??{},o=se(Xe(t,"inputmode","inputMode")),c=Ir[o]??s.keyboardType;if(c&&c!=="default")n.keyboardType=c;if(s.secure)n.secureTextEntry=!0;let l=se(Xe(t,"enterkeyhint","enterKeyHint")),d=Pr[l]??s.returnKeyType;if(d&&d!=="default")n.returnKeyType=d;let p=se(t.autoCapitalize);if(p==="off"||p==="none")n.autoCapitalize="none";else if(p==="on")n.autoCapitalize="sentences";else if(!p&&s.verbatim)n.autoCapitalize="none";let h=t.autoCorrect;if(h==="off"||h==="false"||se(t.spellcheck)==="false"||h===void 0&&s.verbatim)n.autoCorrect=!1;else if(h==="on"||h==="true")n.autoCorrect=!0;if(zt(Xe(t,"readonly","readOnly"))||zt(t.disabled))n.editable=!1;if(s.autoComplete)n.autoComplete=s.autoComplete;return Object.fromEntries(Object.entries(n).filter(([f])=>t[f]===void 0||Br(f,t[f])))}function Br(e,t){if(e==="autoCapitalize")return t==="off"||t==="on";if(e==="autoCorrect")return typeof t==="string";return!1}function qt(e){let t=Ht(e.type,e.props);if(!Object.keys(t).length)return;e._textEntrySource=Object.fromEntries(Ut.filter((n)=>(n in e.props)).map((n)=>[n,e.props[n]])),Object.assign(e.props,t)}var ze={"region-change-complete":"onRegionChangeComplete",regionchangecomplete:"onRegionChangeComplete",click:"onPress",press:"onPress","press-in":"onPressIn",pressin:"onPressIn","press-out":"onPressOut",pressout:"onPressOut",longpress:"onLongPress",contextmenu:"onLongPress",input:"onChangeText",onchange:"onChange",change:"onValueChange","value-change":"onValueChange",valuechange:"onValueChange",focus:"onFocus",focusin:"onFocus",blur:"onBlur",focusout:"onBlur",submit:"onSubmitEditing","submit-editing":"onSubmitEditing",submitediting:"onSubmitEditing","end-editing":"onEndEditing",endediting:"onEndEditing",scroll:"onScroll","scroll-begin-drag":"onScrollBeginDrag",scrollbegindrag:"onScrollBeginDrag","scroll-end-drag":"onScrollEndDrag",scrollenddrag:"onScrollEndDrag","momentum-scroll-begin":"onMomentumScrollBegin",momentumscrollbegin:"onMomentumScrollBegin","momentum-scroll-end":"onMomentumScrollEnd",momentumscrollend:"onMomentumScrollEnd","page-selected":"onPageSelected",pageselected:"onPageSelected",refresh:"onRefresh",layout:"onLayout","end-reached":"onEndReached",endreached:"onEndReached",close:"onRequestClose","request-close":"onRequestClose",requestclose:"onRequestClose",show:"onShow",dismiss:"onDismiss","sliding-complete":"onSlidingComplete",slidingcomplete:"onSlidingComplete","load-start":"onLoadStart",loadstart:"onLoadStart",load:"onLoad","load-end":"onLoadEnd",loadend:"onLoadEnd",error:"onError",play:"onPlay",playing:"onPlay",pause:"onPause",ended:"onEnd",end:"onEnd",timeupdate:"onProgress",progress:"onProgress",loadedmetadata:"onLoad",enterpictureinpicture:"onPictureInPictureStart",leavepictureinpicture:"onPictureInPictureStop"};var He={svg:"Svg",g:"G",path:"Path",line:"Line",rect:"Rect",circle:"Circle",ellipse:"Ellipse",polyline:"Polyline",polygon:"Polygon",text:"SvgText",tspan:"SvgText",animate:"Animate"},qe=new Set(Object.values(He));var Kt=new Set(["defs","title","desc","metadata","style","symbol","use","clippath","mask","lineargradient","radialgradient","stop","pattern","marker","filter","foreignobject"]),Yt=["viewBox","preserveAspectRatio","strokeWidth","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","fillOpacity","fillRule","vectorEffect","textAnchor","dominantBaseline","fontSize","fontWeight","attributeName","keyTimes","repeatCount"];function z(e){let t=typeof e==="number"?e:Number.parseFloat(String(e??""));return Number.isFinite(t)?t:0}function ee(e){return Math.round(e*1000)/1000}function Je(e){if(Array.isArray(e)&&e.length===4&&e.every((n)=>Number.isFinite(Number(n))))return e.map(Number);let t=String(e??"").trim().split(/[\s,]+/).map(Number);if(t.length!==4||t.some((n)=>!Number.isFinite(n))||t[2]<=0||t[3]<=0)return null;return t}function Lr(e){let t=String(e??"").trim().split(/[\s,]+/).filter(Boolean).map(Number).filter(Number.isFinite);return t.length%2?t.slice(0,-1):t}var Gt=/[MLHVCSQTAZ]/i,Ue=/[+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?/gi;function $r(e){let t=[],n=e,r=Gt.exec(n);while(r){let s=r.index;n=n.slice(s);let o=n[0];n=n.slice(1);let c=Gt.exec(n),l=c?n.slice(0,c.index):n,d;if(o==="A"||o==="a"){d=[];let p=0,h=l.trim(),f=0;while(f<h.length){let m=p%7,y=h.slice(f).replace(/^[\s,]+/,"");if(f=h.length-y.length,!y)break;if(m===3||m===4)d.push(y[0]==="1"?1:0),f+=1;else{Ue.lastIndex=0;let v=Ue.exec(y);if(!v||v.index!==0)break;d.push(Number.parseFloat(v[0])),f+=v[0].length}p++}}else d=(l.match(Ue)||[]).map(Number.parseFloat);t.push({command:o,args:d}),r=c}return t}function jr(e,t,n,r,s,o,c,l,d){if(e===l&&t===d)return[];let p=Math.abs(n),h=Math.abs(r);if(!p||!h)return[1,l,d];let f=s*Math.PI/180,m=Math.cos(f),y=Math.sin(f),v=(e-l)/2,g=(t-d)/2,u=m*v+y*g,w=-y*v+m*g,b=u*u/(p*p)+w*w/(h*h);if(b>1)p*=Math.sqrt(b),h*=Math.sqrt(b);let N=p*p*h*h-p*p*w*w-h*h*u*u,S=p*p*w*w+h*h*u*u,k=Math.sqrt(Math.max(0,N/S));if(o===c)k=-k;let x=k*(p*w)/h,A=k*-(h*u)/p,M=m*x-y*A+(e+l)/2,j=y*x+m*A+(t+d)/2,_=(B,W,P,L)=>{let Y=B*L-W*P<0?-1:1,Q=(B*P+W*L)/(Math.hypot(B,W)*Math.hypot(P,L));return Y*Math.acos(Math.min(1,Math.max(-1,Q)))},C=_(1,0,(u-x)/p,(w-A)/h),E=_((u-x)/p,(w-A)/h,(-u-x)/p,(-w-A)/h);if(!c&&E>0)E-=2*Math.PI;if(c&&E<0)E+=2*Math.PI;let O=Math.max(1,Math.ceil(Math.abs(E)/(Math.PI/2))),V=E/O,T=1.3333333333333333*Math.tan(V/4),R=[],I=(B)=>{let W=p*Math.cos(B),P=h*Math.sin(B);return[m*W-y*P+M,y*W+m*P+j]},D=(B)=>{let W=-p*Math.sin(B),P=h*Math.cos(B);return[m*W-y*P,y*W+m*P]},F=C;for(let B=0;B<O;B++){let W=F+V,[P,L]=I(F),[Y,Q]=D(F),[U,J]=I(W),[te,q]=D(W);R.push(2,P+T*Y,L+T*Q,U-T*te,J-T*q,B===O-1?l:U,B===O-1?d:J),F=W}return R}function Qt(e){let t=[],n=0,r=0,s=0,o=0,c=0,l=0,d=0,p=0,h="";for(let{command:f,args:m}of $r(String(e??""))){let y=f===f.toLowerCase(),v=f.toUpperCase(),g=()=>y?n:0,u=()=>y?r:0,w=0,b=(S)=>{if(w+S>m.length)return null;let k=m.slice(w,w+S);return w+=S,k};if(v==="Z"){t.push(4),n=s,r=o,h="Z";continue}let N=!0;while(w<m.length||N&&v==="Z"){switch(v){case"M":{let S=b(2);if(!S)return t;if(n=S[0]+g(),r=S[1]+u(),N)t.push(0,n,r),s=n,o=r;else t.push(1,n,r);h=N?"M":"L";break}case"L":{let S=b(2);if(!S)return t;n=S[0]+g(),r=S[1]+u(),t.push(1,n,r),h="L";break}case"H":{let S=b(1);if(!S)return t;n=S[0]+g(),t.push(1,n,r),h="L";break}case"V":{let S=b(1);if(!S)return t;r=S[0]+u(),t.push(1,n,r),h="L";break}case"C":{let S=b(6);if(!S)return t;let k=S[0]+g(),x=S[1]+u();c=S[2]+g(),l=S[3]+u(),n=S[4]+g(),r=S[5]+u(),t.push(2,k,x,c,l,n,r),h="C";break}case"S":{let S=b(4);if(!S)return t;let k=h==="C"?2*n-c:n,x=h==="C"?2*r-l:r;c=S[0]+g(),l=S[1]+u(),n=S[2]+g(),r=S[3]+u(),t.push(2,k,x,c,l,n,r),h="C";break}case"Q":{let S=b(4);if(!S)return t;d=S[0]+g(),p=S[1]+u(),n=S[2]+g(),r=S[3]+u(),t.push(3,d,p,n,r),h="Q";break}case"T":{let S=b(2);if(!S)return t;d=h==="Q"?2*n-d:n,p=h==="Q"?2*r-p:r,n=S[0]+g(),r=S[1]+u(),t.push(3,d,p,n,r),h="Q";break}case"A":{let S=b(7);if(!S)return t;let k=S[5]+g(),x=S[6]+u();t.push(...jr(n,r,S[0],S[1],S[2],S[3],S[4],k,x)),n=k,r=x,h="A";break}default:return t}N=!1}}return t.map((f)=>ee(f))}function Jt(e,t,n,r){if(n<=0||r<=0)return[];let s=0.5522847498;return[0,e+n,t,2,e+n,t+s*r,e+s*n,t+r,e,t+r,2,e-s*n,t+r,e-n,t+s*r,e-n,t,2,e-n,t-s*r,e-s*n,t-r,e,t-r,2,e+s*n,t-r,e+n,t-s*r,e+n,t,4].map(ee)}function Ye(e,t){switch(e){case"Path":return Qt(String(t.d??""));case"Line":return[0,z(t.x1),z(t.y1),1,z(t.x2),z(t.y2)].map(ee);case"Rect":{let n=z(t.x),r=z(t.y),s=z(t.width),o=z(t.height);if(s<=0||o<=0)return[];let c=t.rx===void 0?z(t.ry):z(t.rx),l=t.ry===void 0?c:z(t.ry);if(c=Math.min(Math.max(0,c),s/2),l=Math.min(Math.max(0,l),o/2),!c||!l)return[0,n,r,1,n+s,r,1,n+s,r+o,1,n,r+o,4].map(ee);let d=0.5522847498;return[0,n+c,r,1,n+s-c,r,2,n+s-c+d*c,r,n+s,r+l-d*l,n+s,r+l,1,n+s,r+o-l,2,n+s,r+o-l+d*l,n+s-c+d*c,r+o,n+s-c,r+o,1,n+c,r+o,2,n+c-d*c,r+o,n,r+o-l+d*l,n,r+o-l,1,n,r+l,2,n,r+l-d*l,n+c-d*c,r,n+c,r,4].map(ee)}case"Circle":return Jt(z(t.cx),z(t.cy),z(t.r),z(t.r));case"Ellipse":return Jt(z(t.cx),z(t.cy),z(t.rx),z(t.ry));case"Polyline":case"Polygon":{let n=Lr(t.points);if(n.length<4)return[];let r=[0,n[0],n[1]];for(let s=2;s<n.length;s+=2)r.push(1,n[s],n[s+1]);if(e==="Polygon")r.push(4);return r.map(ee)}default:return null}}function Vr(e){let t=/^\s*(\d+(?:\.\d+)?|\.\d+)\s*(ms|s)?\s*$/.exec(String(e??""));if(!t)return null;let n=Number(t[1])/(t[2]==="ms"?1000:1);return n>0?n:null}function Wr(e){if(e.attributeName!=="d")return null;let t=Vr(e.dur),n=String(e.values??"").split(";").map((l)=>l.trim()).filter(Boolean);if(t===null||n.length<2)return null;let r=n.map(Qt);if(r.some((l)=>!l.length))return null;let s=String(e.keyTimes??"").split(";").map((l)=>l.trim()).filter(Boolean).map(Number),c=s.length===r.length&&s[0]===0&&s[s.length-1]===1&&s.every((l,d)=>Number.isFinite(l)&&(d===0||l>=s[d-1]))?s.map(ee):r.map((l,d)=>ee(d/(r.length-1)));return{frames:r,frameTimes:c,duration:t}}function Qe(e){let t=Wr(e),n={frames:t?.frames??null,frameTimes:t?.frameTimes??null,duration:t?.duration??null};for(let[r,s]of Object.entries(n))if(s===null)delete e[r];else e[r]=s;return n}var Fr=[...Yt,"accessibilityHint","accessibilityLabel","accessibilityRole","accessibilityState","accessibilityValue","barStyle","activeOpacity","alwaysBounceHorizontal","alwaysBounceVertical","animationType","autoCapitalize","autoComplete","autoCorrect","autoFocus","contentContainerStyle","currentTime","defaultSource","defaultValue","ellipsizeMode","hidesWhenStopped","hitSlop","imageStyle","initialNumToRender","ios_backgroundColor","keyboardDismissMode","keyboardShouldPersistTaps","keyboardType","keyboardVerticalOffset","keyExtractor","listRole","maxLength","mostRecentEventCount","maximumDate","maximumTrackTintColor","maximumValue","maxToRenderPerBatch","minimumDate","minimumTrackTintColor","minimumValue","minuteInterval","numberOfLines","numColumns","objectFit","objectPosition","onEndReachedThreshold","pageIndex","pagingEnabled","passwordRules","placeholderTextColor","pointerEvents","presentationStyle","sheetDetents","selectedDetent","grabberVisible","tintColor","clearButtonMode","nonModal","dismissOnOutsideTap","pressRetentionOffset","progressBackgroundColor","progressViewOffset","refreshControl","resizeMode","returnKeyType","scrollEnabled","scrollTarget","secureTextEntry","selectedValue","selectionColor","showsHorizontalScrollIndicator","showsVerticalScrollIndicator","stickyHeaderIndices","testID","textContentType","thumbColor","thumbTintColor","titleColor","trackColor","underlayColor","windowSize","initialRegion","tileOverlay","edgePadding","fitToBounds","showsUserLocation","zoomEnabled","rotateEnabled","pitchEnabled","mapType","fillColor","strokeColor","pinColor","showsCompass","showsScale","cameraPitch","cameraHeading","autoScrollBottom","scrollKey","pictureInPicture","transitionID"],Zt=new Set(["alwaysBounceHorizontal","alwaysBounceVertical","animating","autoCorrect","autoFocus","autoplay","autoPlay","bounces","controls","disabled","editable","hidesWhenStopped","horizontal","loop","multiline","muted","pagingEnabled","paused","refreshing","scrollEnabled","secureTextEntry","selectTextOnFocus","showsHorizontalScrollIndicator","showsVerticalScrollIndicator","transparent","visible","nonModal","dismissOnOutsideTap","fitToBounds","showsUserLocation","zoomEnabled","rotateEnabled","pitchEnabled","showsCompass","showsScale","pictureInPicture","grabberVisible"]),Xr=new Map(Fr.map((e)=>[en(e),e]));function en(e){return e.replace(/[-_]/g,"").toLowerCase()}function Ze(e,t){if((t==="Image"||t==="Video")&&e.toLowerCase()==="src")return"source";return Xr.get(en(e))??e}var zr={view:"View",sidebar:"Sidebar",splitview:"SplitView",textinput:"TextInput",pressable:"Pressable",icon:"Icon",text:"Text",button:"Button",image:"Image",img:"Image",video:"Video",map:"Map",mappolyline:"MapPolyline",mappolygon:"MapPolygon",mapmarker:"MapMarker",input:"TextInput",textarea:"TextInput",scroll:"ScrollView",scrollview:"ScrollView",list:"FlatList",flatlist:"FlatList",modal:"Modal",switch:"Switch",checkbox:"Checkbox",slider:"Slider",picker:"Picker",segmentedcontrol:"SegmentedControl",nativesegmentedcontrol:"SegmentedControl",select:"Picker",loading:"ActivityIndicator",spinner:"ActivityIndicator",div:"View",span:"Text",p:"Text",h1:"Text",h2:"Text",h3:"Text",h4:"Text",h5:"Text",h6:"Text",a:"TouchableOpacity",section:"View",article:"View",header:"SafeAreaView",footer:"View",main:"View",nav:"View",aside:"View",form:"View",label:"Text",fieldset:"View",legend:"Text",option:"Text",dialog:"Modal",figure:"View",figcaption:"Text",picture:"View",hr:"View",ul:"View",ol:"View",li:"View",dl:"View",dt:"Text",dd:"Text",table:"View",thead:"View",tbody:"View",tfoot:"View",tr:"View",th:"Text",td:"Text",caption:"Text",strong:"Text",b:"Text",em:"Text",i:"Text",u:"Text",s:"Text",small:"Text",mark:"Text",abbr:"Text",time:"Text",code:"Text",kbd:"Text",samp:"Text",pre:"Text",blockquote:"Text",cite:"Text",q:"Text",sub:"Text",sup:"Text"};function tn(e){return zr[e.toLowerCase()]||e}var Ur={"circle-pause":"pause.circle","cloud-alert":"exclamationmark.icloud","key-round":"key",paperclip:"paperclip","rotate-cw":"arrow.clockwise","route-off":"location.slash",syringe:"syringe","volume-1":"speaker.wave.1",activity:"waveform.path.ecg","alarm-clock":"alarm","alert-circle":"exclamationmark.circle","alert-triangle":"exclamationmark.triangle",apple:"leaf",archive:"archivebox",armchair:"sofa","arrow-down":"arrow.down","arrow-left":"arrow.left","arrow-right":"arrow.right","arrow-up":"arrow.up","arrow-up-right":"arrow.up.right","at-sign":"at","audio-lines":"waveform",award:"rosette",backpack:"backpack","badge-check":"checkmark.seal","badge-x":"xmark.seal",ban:"nosign","bar-chart":"chart.bar","bar-chart-2":"chart.bar","bar-chart-3":"chart.bar",battery:"battery.100","battery-charging":"battery.100.bolt",bean:"leaf",bed:"bed.double",beef:"fork.knife",bell:"bell","bell-off":"bell.slash","bell-ring":"bell.and.waves.left.and.right",bike:"figure.outdoor.cycle",blocks:"square.grid.2x2",bluetooth:"antenna.radiowaves.left.and.right",book:"book","book-open":"book",bookmark:"bookmark",box:"shippingbox",brain:"brain",building:"building","building-2":"building.2",cable:"cable.connector","cake-slice":"birthday.cake",calendar:"calendar","calendar-check":"calendar.badge.checkmark","calendar-clock":"calendar.badge.clock","calendar-days":"calendar","calendar-minus":"calendar.badge.minus","calendar-minus-2":"calendar.badge.minus","calendar-off":"calendar.badge.exclamationmark","calendar-plus":"calendar.badge.plus","calendar-range":"calendar","calendar-sync":"arrow.triangle.2.circlepath","calendar-x":"calendar.badge.exclamationmark","calendar-x-2":"calendar.badge.exclamationmark",camera:"camera",carrot:"carrot","chart-bar":"chart.bar","chart-column":"chart.bar","chart-line":"chart.xyaxis.line","chart-no-axes-gantt":"chart.bar.doc.horizontal",check:"checkmark","check-circle":"checkmark.circle","check-circle-2":"checkmark.circle","chevron-down":"chevron.down","chevron-left":"chevron.left","chevron-right":"chevron.right","chevron-up":"chevron.up",circle:"circle","circle-alert":"exclamationmark.circle","circle-arrow-out-up-left":"arrow.uturn.backward.circle","circle-minus":"minus.circle","circle-arrow-down":"arrow.down.circle","circle-check":"checkmark.circle","circle-check-big":"checkmark.circle","circle-dot":"smallcircle.filled.circle","circle-help":"questionmark.circle","circle-question-mark":"questionmark.circle","circle-play":"play.circle","circle-plus":"plus.circle","circle-user":"person.crop.circle","circle-x":"xmark.circle",clapperboard:"film",clipboard:"clipboard","clipboard-list":"list.clipboard",clock:"clock","clock-12":"clock","clock-2":"clock","clock-3":"clock","clock-4":"clock","clock-8":"clock","clock-alert":"clock.badge.exclamationmark",cloud:"cloud","cloud-off":"icloud.slash",coffee:"cup.and.saucer",cookie:"birthday.cake",copy:"doc.on.doc","credit-card":"creditcard","cup-soda":"takeoutbag.and.cup.and.straw",cylinder:"cylinder",disc:"opticaldisc",download:"arrow.down.circle",droplet:"drop",droplets:"drop",drumstick:"fork.knife",dumbbell:"dumbbell",edit:"pencil",egg:"frying.pan","external-link":"arrow.up.right.square",eye:"eye","eye-off":"eye.slash",file:"doc","file-text":"doc.text",filter:"line.3.horizontal.decrease",fish:"fish",flag:"flag",flame:"flame","flower-2":"camera.macro",footprints:"figure.run",gauge:"gauge",gift:"gift","glass-water":"waterbottle",globe:"globe","graduation-cap":"graduationcap","grip-vertical":"line.3.horizontal",hamburger:"takeoutbag.and.cup.and.straw","hand-fist":"hand.raised",heart:"heart","heart-off":"heart.slash","heart-pulse":"heart.text.square","help-circle":"questionmark.circle",history:"clock.arrow.circlepath",home:"house",hourglass:"hourglass",house:"house","id-card":"person.text.rectangle",image:"photo",inbox:"tray",info:"info.circle",layers:"square.3.layers.3d","layout-dashboard":"rectangle.3.group","layout-grid":"square.grid.2x2",leaf:"leaf",library:"books.vertical",link:"link",list:"list.bullet","list-checks":"checklist",loader:"arrow.triangle.2.circlepath","loader-2":"arrow.triangle.2.circlepath","loader-circle":"arrow.triangle.2.circlepath",lock:"lock","log-in":"arrow.right.to.line","log-out":"rectangle.portrait.and.arrow.right",mail:"envelope",map:"map","map-pin":"mappin.and.ellipse",medal:"medal",megaphone:"megaphone",menu:"line.3.horizontal","message-circle":"bubble.left","message-square":"text.bubble","message-square-quote":"quote.bubble","messages-square":"bubble.left.and.bubble.right",mic:"mic",milk:"waterbottle",minus:"minus",moon:"moon","more-horizontal":"ellipsis","more-vertical":"ellipsis",mountain:"mountain.2",music:"music.note","music-2":"music.note",nut:"leaf",package:"shippingbox",pause:"pause","pause-circle":"pause.circle",pencil:"pencil","person-standing":"figure.walk",phone:"phone",play:"play.fill",plug:"powerplug",plus:"plus","plus-circle":"plus.circle","rectangle-horizontal":"rectangle","refresh-cw":"arrow.clockwise",repeat:"repeat","rotate-ccw":"arrow.counterclockwise",route:"point.topleft.down.to.point.bottomright.curvepath",ruler:"ruler",sailboat:"sailboat",salad:"leaf",satellite:"antenna.radiowaves.left.and.right",save:"square.and.arrow.down",scale:"scalemass","scan-line":"barcode.viewfinder",search:"magnifyingglass",send:"paperplane",settings:"gearshape","settings-2":"slider.horizontal.3",share:"square.and.arrow.up","share-2":"square.and.arrow.up",shield:"shield","shield-check":"checkmark.shield","shopping-bag":"bag","shopping-cart":"cart",shuffle:"shuffle","skip-back":"backward.end","skip-forward":"forward.end",sliders:"slider.horizontal.3","sliders-horizontal":"slider.horizontal.3",smartphone:"iphone",snowflake:"snowflake",soup:"mug",sparkles:"sparkles",sprout:"leaf",square:"square",star:"star",stopwatch:"stopwatch",store:"storefront","stretch-horizontal":"rectangle.split.1x2",sun:"sun.max",sunrise:"sunrise",sunset:"sunset",tag:"tag",target:"scope",thermometer:"thermometer.medium","thumbs-up":"hand.thumbsup",timer:"timer",trash:"trash","trash-2":"trash","trending-down":"chart.line.downtrend.xyaxis","trending-up":"chart.line.uptrend.xyaxis","triangle-alert":"exclamationmark.triangle",trophy:"trophy",unlink:"personalhotspot.slash",upload:"arrow.up.circle",user:"person","user-check":"person.crop.circle.badge.checkmark","user-minus":"person.badge.minus","user-plus":"person.badge.plus","user-round":"person","user-round-check":"person.crop.circle.badge.checkmark","user-round-minus":"person.crop.circle.badge.minus","user-round-plus":"person.crop.circle.badge.plus","user-round-x":"person.crop.circle.badge.xmark","user-x":"person.crop.circle.badge.xmark",users:"person.2","users-round":"person.2",utensils:"fork.knife",video:"video","volume-2":"speaker.wave.2",warehouse:"building.2",watch:"applewatch",waves:"figure.pool.swim",weight:"scalemass",wheat:"laurel.leading",wifi:"wifi","wifi-off":"wifi.slash",wind:"wind",wine:"wineglass",x:"xmark","x-circle":"xmark.circle",zap:"bolt"},nn={lucide:Ur,hugeicons:{"workout-run":"figure.run"}};function ce(e,t=!1){let n=String(e??"").trim();if(!n)return{symbol:"questionmark.square.dashed",known:!1};if(t)return{symbol:n,known:!0};let r=/^i-([a-z0-9]+)-(.+)$/.exec(n)??/^([a-z0-9]+):(.+)$/.exec(n),s=r?r[1]:"lucide",o=r?r[2]:n,c=Object.hasOwn(nn,s)?nn[s]:void 0;if(c&&Object.hasOwn(c,o))return{symbol:c[o],iconify:`i-${s}-${o}`,known:!0};if(!r&&n.includes("."))return{symbol:n,known:!0};return{symbol:"questionmark.square.dashed",iconify:r?n:`i-lucide-${o}`,known:!1}}function et(e){return e.split(/\s+/).find((t)=>/^i-[a-z0-9]+-[a-z0-9-]+$/.test(t))}import{generate as Se,parse as Hr}from"@stacksjs/ts-css/parse";var qr=/^(?::hover|:active|:visited|:focus|:focus-visible|:focus-within)$/;function Gr(e){let t=e.replace(/\s+/g,"").toLowerCase();if(!t||t==="all"||t==="screen")return{};if(/^(?:screenand)?\(prefers-color-scheme:dark\)$/.test(t))return{dark:!0};if(/^(?:screenand)?\(prefers-color-scheme:light\)$/.test(t))return{};if(/prefers-reduced-motion|\(hover|\(pointer|print|forced-colors|prefers-contrast/.test(t))return"skip";let n=t.replace(/^screenand/,"").split("and"),r={};for(let s of n){let o=/^\((min|max)-width:([\d.]+)(px|rem|em)\)$/.exec(s);if(!o)return;r[o[1]]=Number(o[2])*(o[3]==="px"?1:16)}return r}async function rn(e,t){let n={},r=new Set,s=(p)=>{if(r.has(p))return;r.add(p),t(p,[...p.matchAll(/\.(-?[a-z_][\w-]*)/gi)].map((h)=>h[1]))},o=(p,h,f)=>{if(!h.trim())return;let m=n[p]??={},y=f.dark?"dark":"light";if(f.min===void 0&&f.max===void 0){m[y]=m[y]?`${m[y]};${h}`:h;return}let v=m.responsive??=[],g=f.min??0,u=v.find((w)=>w.min===g&&w.max===f.max);if(!u)v.push(u={min:g,...f.max===void 0?{}:{max:f.max}});u[y]=u[y]?`${u[y]};${h}`:h};function c(p,h){for(let f of p){if(f.type==="Atrule"){let v=f.name.toLowerCase();if(["font-face","keyframes","-webkit-keyframes","import","charset","property","page","layer"].includes(v)){if(v==="layer"&&f.block)c(f.block.children,h);continue}if(v!=="media"||!f.block){s(`@${v}`);continue}let g=f.prelude?Se(f.prelude):"",u=Gr(g);if(u==="skip")continue;if(!u){s(`@media ${g}`);continue}c(f.block.children,{dark:h.dark||u.dark,min:u.min??h.min,max:u.max??h.max});continue}if(f.type!=="Rule"||f.block.type!=="Block")continue;let m=[...f.block.children].filter((v)=>v.type==="Declaration").map((v)=>Se(v)).join(";"),y=f.prelude.type==="SelectorList"?[...f.prelude.children].map(Se):[Se(f.prelude)];for(let v of y){let g=/^(?:(?:html|:root)?\.dark\s+)?((?:\.-?[a-z_][\w-]*)+)((?::{1,2}[a-z-]+)*)$/i.exec(v.trim());if(!g){if(!/^(?:html|:root|body|\*|::?[a-z-]+)/i.test(v.trim()))s(v.trim());continue}let u=g[2];if(u){if(!qr.test(u))s(v.trim());continue}let w=h.dark||/^(?:(?:html|:root)?\.dark\s+)/i.test(v.trim());o(g[1].slice(1),m,{dark:w,min:h.min,max:h.max})}}}let l="",d=!0;await new HTMLRewriter().on("style",{element(p){l="";let h=p.getAttribute("type");d=!h||h.toLowerCase()==="text/css",p.onEndTag(()=>{if(!d)return;try{let f=Hr(l);if(f.type==="StyleSheet")c(f.children,{})}catch{s("invalid stylesheet")}})},text(p){l+=p.text}}).transform(new Response(e)).text();for(let p of Object.values(n))p.responsive?.sort((h,f)=>h.min-f.min||(h.max??1/0)-(f.max??1/0));return n}import{generate as le,parse as sn}from"@stacksjs/ts-css/parse";async function an(e,t){let n={light:new Map,dark:new Map},r=new Set,s=(f)=>{if(!r.has(f))r.add(f),t(f)},o=(f,m,y)=>{for(let v of y){let g=n[v].get(f);if(!g||Number(m.important)>Number(g.important)||m.important===g.important&&m.specificity>=g.specificity)n[v].set(f,m)}},c=(f)=>{if(f.type==="Declaration")return f.property.startsWith("--");if(f.type==="Rule"||f.type==="Atrule")return!!f.block&&[...f.block.children].some(c);return!1},l=(f)=>{let m=f.replace(/\s+/g,"").toLowerCase();if(!m||m==="all"||m==="screen")return["light","dark"];let y=/^(?:screenand)?\(prefers-color-scheme:(light|dark)\)$/.exec(m);return y?[y[1]]:void 0};function d(f,m){for(let y of f){if(!c(y))continue;if(y.type==="Atrule"){let g=y.prelude?le(y.prelude):"",u=y.name.toLowerCase()==="media"?l(g):void 0;if(!u){s(`@${y.name} ${g}`.trim());continue}d(y.block.children,m.filter((w)=>u.includes(w)));continue}if(y.type!=="Rule")continue;let v=y.prelude.type==="SelectorList"?[...y.prelude.children].map(le):[le(y.prelude)];for(let g of v){let u=/^(html|:root)?(?:\.(dark|light))?$/.exec(g.trim());if(!u||!u[1]&&!u[2]){s(g);continue}let w=(u[1]===":root"?10:u[1]?1:0)+(u[2]?10:0);for(let b of y.block.children){if(b.type!=="Declaration"){if(c(b))s(`nested rule in ${g}`);continue}if(!b.property.startsWith("--"))continue;let N={value:le(b.value),important:!!b.important,specificity:w};o(b.property,N,m.filter((S)=>!u[2]||u[2]===S))}}}}let p="",h;return await new HTMLRewriter().on("html",{element(f){let m=f.getAttribute("style");if(!m)return;try{let y=sn(m,{context:"declarationList"});if(y.type!=="DeclarationList")return;for(let v of y.children)if(v.type==="Declaration"&&v.property.startsWith("--"))o(v.property,{value:le(v.value),important:!!v.important,specificity:1000},["light","dark"])}catch{s("invalid document inline theme")}}}).on("style",{element(f){p="";let m=f.getAttribute("type");h=!m||m.toLowerCase()==="text/css"?l(f.getAttribute("media")??""):void 0,f.onEndTag(()=>{try{let y=sn(p);if(y.type!=="StyleSheet")return;if(!h){if([...y.children].some(c))s("style type/media");return}d(y.children,h)}catch{s("invalid stylesheet")}})},text(f){p+=f.text}}).transform(new Response(e)).text(),{light:[...n.light].map(([f,m])=>[f,m.value]),dark:[...n.dark].map(([f,m])=>[f,m.value])}}function K(e,t={},n={},r={},s=[]){return{type:e,props:t,style:n,events:r,children:s}}function cn(e,t,n={}){return{version:"1.0.0",root:e,script:t,meta:{source:n.source||"unknown",compiledAt:n.compiledAt||Date.now(),headwindConfig:n.headwindConfig}}}var Jr=/^(?:key(?:down|up|press)|mouse[a-z]+|pointer[a-z]+|dbl(?:click)?|contextmenu|wheel|drag[a-z]*|drop|copy|cut|paste|beforeinput|compositionstart|compositionupdate|compositionend|animation[a-z]+|transition[a-z]+|resize|hashchange|popstate|beforeunload|unload|visibilitychange|selectionchange|selectstart|auxclick)$/,ln=new Set(["script","style","head","meta","link","title","base","noscript"]),un=new Set(["template","body","html","main","fragment"]),we=new Set,Kr=new Set(["onBlur","onChange","onChangeText","onDismiss","onEnd","onEndEditing","onEndReached","onError","onFocus","onPageSelected","onLayout","onLoad","onLoadEnd","onLoadStart","onLongPress","onMomentumScrollBegin","onMomentumScrollEnd","onPause","onPictureInPictureStart","onPictureInPictureStop","onPlay","onPress","onPressIn","onPressOut","onProgress","onRequestClose","onRegionChangeComplete","onRefresh","onScroll","onScrollBeginDrag","onScrollEndDrag","onShow","onSlidingComplete","onSubmitEditing","onValueChange"]),xe=new Set(["Sidebar","SplitView","View","ScrollView","SafeAreaView","KeyboardAvoidingView","Text","TextInput","Button","Link","TouchableOpacity","TouchableHighlight","Pressable","Icon","Image","ImageBackground","Video","Map","MapPolyline","MapPolygon","MapMarker","FlatList","SectionList","Switch","Checkbox","Slider","Picker","SegmentedControl","DatePicker","Modal","ActivityIndicator","StatusBar","RefreshControl",...qe]),Yr=new Map([["data","data"],["sections","sections"],["renderitem","renderItem"],["rendersectionheader","renderSectionHeader"],["keyextractor","keyExtractor"]]),dn=new Set(["View","SafeAreaView","ScrollView","KeyboardAvoidingView"]),Qr={amp:"&",lt:"<",gt:">",quot:'"',apos:"'",nbsp:" ","#39":"'","#x27":"'"};function re(e){return e.replace(/&(#x?[0-9a-f]+|\w+);/gi,(t,n)=>{let r=Qr[n.toLowerCase()];if(r!==void 0)return r;if(n[0]==="#"){let s=n[1]==="x"||n[1]==="X"?Number.parseInt(n.slice(2),16):Number.parseInt(n.slice(1),10);return Number.isFinite(s)?String.fromCodePoint(s):t}return t})}function tt(e){if(!e.includes("{{"))return null;let t=[],n=0;for(let r of e.matchAll(/\{\{([\s\S]+?)\}\}/g)){if(r.index>n)t.push(JSON.stringify(e.slice(n,r.index)));t.push(`(${r[1].trim()})`),n=r.index+r[0].length}if(!t.some((r)=>r.startsWith("(")))return null;if(n<e.length)t.push(JSON.stringify(e.slice(n)));if(t.length===1)return t[0].slice(1,-1);return`[${t.join(", ")}].map(__stxPart => __stxPart == null ? '' : __stxPart).join('')`}function fn(e,t,n,r={}){let s=r.inheritedVariables,o={},c={},l={},d=[],p="",h={};for(let[v,g]of t){let u=v.toLowerCase();if(u==="class"||u==="classname"){p=p?`${p} ${g}`:g;continue}if(u==="style"){h={...h,...Zr(e,g,n,{...r,onVariables(S){s=S,r.onVariables?.(S)}})};continue}if(u.startsWith(":")||u.startsWith("x-")&&u!=="x-cloak"){l[u.startsWith(":")?u.slice(1):u.slice(2)]=re(g);continue}if(u==="x-cloak")continue;if(u.startsWith("@")||u.startsWith("v-on:")){let S=u.startsWith("@")?u.slice(1):u.slice(5),[k]=S.split("."),x=ze[k]??(k.startsWith("on")?k:"");if(!x||!Kr.has(x)){if(Jr.test(k)||/\./.test(S))n.push({kind:"unread-event",tag:e,name:v});continue}c[x]=re(g);continue}if(u==="key"){o.key=g;continue}let w=re(g),b=tt(w);if(b){l[u]=b,d.push(u);continue}let N=Ze(v);if(w===""&&Zt.has(N)){o[N]=!0;continue}try{o[N]=JSON.parse(w)}catch{o[N]=w}}let f=o["data-native"]?o["data-native"]==="TextInput":e==="textarea"||e==="input"&&!["checkbox","radio","hidden"].includes(String(o.type??"text").toLowerCase()),m=p?ve(p,s,{focus:f,focusWithin:!0,rules:r.rules}):void 0;for(let v of new Set(m?.unknown??[]))n.push({kind:"unknown-class",tag:e,name:v});let y=Le({...m?.style,...h});return{props:o,style:y,events:c,bindings:l,classes:p,inline:h,templated:d}}function Zr(e,t,n,r){return he(re(t),(s)=>n.push({...s,tag:e}),r)}function nt(e){return e.children.map((t)=>typeof t==="string"?t:nt(t)).join("").replace(/\s+/g," ").trim()}function ei(e,t){let n=e.node;if(n.props["data-stx-native-template"])return n.children=n.children.map((o)=>typeof o==="string"?K("Text",{},{},{},[o]):o),n;let r=n.children.filter((o)=>typeof o!=="string"),s=n.children.filter((o)=>typeof o==="string").join("").trim();if(e.tag==="button"&&n.type==="Button"&&!e.declaredNative&&r.length>0)return n.type="Pressable",n.props.role??="button",n.children=n.children.flatMap((o)=>typeof o==="string"?o.trim()?[K("Text",{},{},{},[o.trim()])]:[]:[o]),n;if(n.type==="Button"&&r.length===0)return n.children=s?[s]:[],n;if(n.type==="Svg"||n.type==="G")return n.children=r,n;if(n.type==="SvgText"){let o=nt(n);return n.children=o?[o]:[],n}if(dn.has(n.type)&&r.length===0&&s)return n.type="Text",n.children=[s],n;if(n.type==="Text"&&!s&&r.length===0&&typeof n.props.text==="string")return n.children=n.props.text?[n.props.text]:[],delete n.props.text,n;if(n.type==="Text"&&r.length>0){if(/(?:^|\s)(?:inline-)?(?:flex|grid)(?:\s|$)/.test(n._classes??"")||r.some((l)=>l.type!=="Text"))return n.type="View",n.children=n.children.map((l)=>typeof l==="string"?K("Text",{},{},{},[l]):l),n;let c=nt(n);return t.push({kind:"flattened-text",tag:e.tag}),n.children=c?[c]:[],n}if(dn.has(n.type)&&r.length>0)n.children=r;return n}async function ti(e,t={}){e=await ue(e);let n=[],r=await an(e,(u)=>n.push({kind:"unsupported-theme-rule",tag:"style",name:u})),s=ae(r.light).computed(),o=new Set([...e.matchAll(/\sclass(?:name)?\s*=\s*"([^"]*)"/gi)].flatMap((u)=>u[1].split(/\s+/))),c=await rn(e,(u,w)=>{if(!w.length||w.some((b)=>o.has(b)))n.push({kind:"unsupported-style-rule",tag:"style",name:u})}),l=[],d=[],p=new Set;function h(u){let w=d[d.length-1];if(!w)l.push(u);else if(!w.dropped)w.node.children.push(u)}function f(u){let w=u.node.style.fontFamily,b=(S)=>{if(u.tag!=="html"&&u.node._styleSource)S._styleAncestors=[u.node._styleSource,...S._styleAncestors??[]];if(w&&S.style.fontFamily===void 0)S._layoutDefaults={...S._layoutDefaults,fontFamily:w},S.style={fontFamily:w,...S.style}};if(u.node.bindings&&Object.keys(u.node.bindings).length>0){let S=u.node.children,k=S.filter((A)=>typeof A!=="string"),x=k.length===1&&k.length===S.length?k[0]:K("View",{},{},{},S);if(x.bindings={...u.node.bindings,...x.bindings},x.bindingId===void 0&&u.node.bindingId!==void 0)x.bindingId=u.node.bindingId;b(x),h(x);return}let N=d[d.length-1];for(let S of u.node.children){if(typeof S==="string"){if(N&&!N.dropped)N.node.children.push(S);continue}if(b(S),!N)l.push(S);else if(!N.dropped)N.node.children.push(S)}}function m(u,w){let b=d[d.length-1];if(u==="svg"||b?.svg)return y(u,w,b);let N=ln.has(u)&&!we.has(u),S=d[d.length-1]?.dropped??!1,k=b?.variables??s,{props:x,style:A,events:M,bindings:j,classes:_,inline:C,templated:E}=N||S?{props:{},style:{},events:{},bindings:{},classes:"",inline:{},templated:[]}:fn(u,w,n,{inheritedVariables:k,onVariables:(D)=>{k=D},rules:c});if(u==="html")k=s;let O=x["data-native"],V=u==="template"&&w.some(([D])=>[":for","x-for","@for"].includes(D)),T;if(V)T="View",x["data-stx-native-template"]=!0;else if(typeof O==="string"&&xe.has(O))T=O,delete x["data-native"];else{if(T=we.has(u)?"View":tn(u),(u==="i"||u==="span")&&/(?:^|\s)i-[a-z0-9]+-[a-z0-9-]+(?:\s|$)/.test(_))T="Icon";else if(u==="i"&&w.some(([D])=>/^(?::|x-)class$/i.test(D)))T="Icon";if(u==="input"){let D=String(x.type??"text").toLowerCase();if(D==="checkbox")T="Checkbox",x.formValue=x.value??"on",x.checked=x.checked===""||x.checked===!0||x.checked==="true",x.value=x.checked;else if(D==="hidden")T="View",A.display="none",C.display="none";else if(D==="radio")T="View",x.accessibilityRole="radio",n.push({kind:"unsupported-control",tag:u,name:"input:radio"})}}if(!S&&T===u&&!xe.has(T)&&!ln.has(u)&&!un.has(u)&&!p.has(u))p.add(u),n.push({kind:"unmapped-tag",tag:u});if((N||we.has(u))&&!p.has(`drop:${u}`))p.add(`drop:${u}`),n.push({kind:"dropped-subtree",tag:u});if(T==="View"&&/(?:^|\s)overflow-x-(?:auto|scroll)(?:\s|$)/.test(_))T="ScrollView",x.horizontal=!0,x.showsHorizontalScrollIndicator??=!1;else if(T==="View"&&/(?:^|\s)overflow-y-(?:auto|scroll)(?:\s|$)/.test(_))T="ScrollView";if(u==="form")x["data-stx-form"]=!0;if(u==="button"&&x.type===void 0)x.type="submit";if(u==="textarea"&&T==="TextInput")x.multiline??=!0;if((T==="Video"||T==="Image")&&x.source===void 0&&x.src!==void 0)x.source=x.src,delete x.src;if(T==="Icon"){let D=ve(_).icon,F=String(x.symbol||x.name||D||""),B=ce(F,Boolean(x.symbol));if(F.trim()&&!B.known)n.push({kind:"unknown-icon",tag:u,name:F});if(x.symbol=B.symbol,B.iconify)x.iconify=B.iconify}if(T==="FlatList"||T==="SectionList"){let D=new Set([...Object.keys(x),...Object.keys(j)].map((F)=>F.toLowerCase()));for(let[F,B]of Yr)if(D.has(F))n.push({kind:"unsupported-list-prop",tag:T,name:B})}let R=K(T,x,A,M);R._inlineStyle=C,R._styleSource=re(w.find(([D])=>D==="style")?.[1]??"");let I=x["data-stx-b"];if(typeof I==="number"&&Number.isInteger(I))R.bindingId=I;if(delete x["data-stx-b"],_)R._classes=_;if(Object.keys(j).length>0)R.bindings=j;if(E.length>0)R._templated=E;if(typeof x.key==="string")R.key=x.key,delete x.key;return{tag:u,node:R,variables:k,declaredNative:typeof O==="string"&&xe.has(O),dropped:N||S||we.has(u)||T==="Video",discard:N||S,unwrap:un.has(u)&&!V&&T!=="ScrollView"&&!(typeof O==="string"&&xe.has(O))}}function y(u,w,b){let N=b?.dropped??!1,S=He[u];if(N||!S){if(!N&&!p.has(`drop:${u}`))p.add(`drop:${u}`),n.push({kind:Kt.has(u)?"dropped-subtree":"unmapped-tag",tag:u});return{tag:u,node:K("G",{},{},{}),svg:!0,dropped:!0,discard:!0,unwrap:!1}}let k=b?.variables??s,{props:x,style:A,events:M,bindings:j,classes:_,inline:C,templated:E}=fn(u,w,n,{inheritedVariables:k,onVariables:(R)=>{k=R},rules:c});if(S==="Svg"){let R=Je(x.viewBox);if(R)x.viewBox=R;else delete x.viewBox;for(let I of["width","height"]){if(typeof x[I]==="number"&&A[I]===void 0)A[I]=x[I];delete x[I]}}if(typeof x.strokeDasharray==="string"||typeof x.strokeDasharray==="number"){let R=String(x.strokeDasharray).split(/[\s,]+/).map(Number).filter(Number.isFinite);x.strokeDasharray=R}let O=Ye(S,x);if(O)x.geometry=O;if(S==="Animate")Qe(x);let V=K(S,x,A,M);V._inlineStyle=C,V._styleSource=re(w.find(([R])=>R==="style")?.[1]??"");let T=x["data-stx-b"];if(typeof T==="number"&&Number.isInteger(T))V.bindingId=T;if(delete x["data-stx-b"],_)V._classes=_;if(Object.keys(j).length>0)V.bindings=j;if(E.length>0)V._templated=E;if(typeof x.key==="string")V.key=x.key,delete x.key;return{tag:u,node:V,variables:k,svg:!0,dropped:!1,discard:!1,unwrap:!1}}if(await new HTMLRewriter().on("*",{element(u){let w=u.tagName.toLowerCase(),b=m(w,[...u.attributes]),N=!0;try{u.onEndTag(()=>{if(d.pop(),b.discard)return;if(b.unwrap)f(b);else h(ei(b,n))})}catch{N=!1}if(N)d.push(b);else if(!b.discard)h(b.node)},text(u){let w=d[d.length-1];if(!w||w.dropped)return;let b=ni(re(u.text),w.inMustache===!0);w.inMustache=b.inside;let N=b.text;if(!N.trim())return;w.node.children.push(N)}}).transform(new Response(e)).text(),l.length===0)throw Error(`No element to translate in the rendered output of ${t.source??"unknown"}`);let v=l.length===1?l[0]:K("View",{},{},{},l);if(r.light.length||r.dark.length)v._stylesheetTheme=r;if(Object.keys(c).length)v._stylesheetRules=c;let g=(u)=>{ri(u);let w=Fe(u.props,u.type);if(Object.keys(w).length)u._accessibilitySource=Object.fromEntries(We.filter((b)=>(b in u.props)).map((b)=>[b,u.props[b]])),Object.assign(u.props,w);qt(u);for(let b of u.children)if(typeof b!=="string")g(b)};return g(v),pn(v),{root:v,diagnostics:n}}function pn(e){if(["ScrollView","FlatList","SectionList"].includes(e.type))return!e.props.horizontal&&(Number(e.style.flex)>0||Number(e.style.flexGrow)>0);if(!e.children.map((n)=>typeof n==="string"?!1:pn(n)).some(Boolean)||!["View","SafeAreaView","KeyboardAvoidingView"].includes(e.type))return!1;if(e.style.height!==void 0||e.style.maxHeight!==void 0)return!1;if(e.style.flex===0||e.style.flexGrow===0||e.style.flexShrink===0)return!1;if(e.style.flex===void 0&&e.style.flexGrow===void 0)e._layoutDefaults={flex:1,flexGrow:1,flexShrink:1,flexBasis:0},e.style={...e._layoutDefaults,...e.style};return!0}function ni(e,t){let n="",r=0;while(r<e.length){if(!t&&e.startsWith("{{",r)){t=!0,n+="{{",r+=2;continue}if(t&&e.startsWith("}}",r)){t=!1,n+="}}",r+=2;continue}let s=e[r];if(!t&&/\s/.test(s)){if(!n.endsWith(" "))n+=" ";while(r<e.length&&/\s/.test(e[r]))r++;continue}n+=s,r++}return{text:n,inside:t}}function ri(e){if(e.props["data-stx-native-template"])return;if(e.bindings?.text||e.children.length===0)return;let t=e.children.filter((r)=>typeof r==="string");if(t.length<e.children.length){let r=e.type==="Button"||e.type==="Text"?null:tt(t.join(""));if(!r)return;e.bindings={...e.bindings,text:r},e._templated=[...e._templated??[],"text"],e.children=e.children.filter((s)=>typeof s!=="string");return}let n=tt(e.children.join(""));if(!n)return;if(e.type!=="Button")e.bindings={...e.bindings,text:n},e._templated=[...e._templated??[],"text"],e.children=[];else{e.type="Pressable",e.props.role??="button";let r=K("Text",{},{},{},[]);r.bindings={text:n},r._templated=["text"],e.children=[r]}}async function gn(e,t={}){let{root:n,diagnostics:r}=await ti(e,t),s=t.script??{exports:{},functions:[],code:""};return{document:cn(n,s,{source:t.source??"unknown"}),diagnostics:r}}function ii(e){let t="",n=0;for(let r=e.indexOf("<");r!==-1;r=e.indexOf("<",r+1)){if(!/[a-z]/i.test(e[r+1]??""))continue;let s=r+1,o="";for(;s<e.length;s++){let l=e[s];if(o){if(l===o)o="";continue}if(l==='"'||l==="'")o=l;else if(l===">"||l==="<")break}if(e[s]!==">"||e[s-1]!=="/")continue;let c=e.slice(r,s+1).replace(/"[^"]*"|'[^']*'/g,'""');if(!/\sdata-native-exclude(?=[\s=/>])/i.test(c))continue;t+=e.slice(n,r),n=s+1,r=s}return n?t+e.slice(n):e}async function ue(e){if(!/\bdata-native-exclude\b/i.test(e))return e;if(e=ii(e),!/\bdata-native-exclude\b/i.test(e))return e;return new HTMLRewriter().on("[data-native-exclude]",{element(t){t.remove()}}).transform(new Response(e)).text()}var hn=/<script\b([^>]*)>([\s\S]*?)<\/script>/gi,si=/(?:^|\n)\s*(?:export\s+)?(?:async\s+)?function\s*\*?\s*([$\w]+)\s*\(/g,oi=/(?:^|\n)\s*(?:export\s+)?(?:const|let|var)\s+([$\w]+)\s*=\s*(?:async\s*)?(?:\([^)]*\)|[$\w]+)\s*=>/g,mn=/(?:^|\n)\s*(?:export\s+)?const\s+([$\w]+)\s*=\s*(-?[\d.]+|true|false|'[^']*'|"[^"]*")\s*(?=;|\n|$)/g;function rt(e){let t=[];hn.lastIndex=0;for(let o of e.matchAll(hn)){let c=o[1]??"";if(/\bserver\b/.test(c))continue;t.push(o[2].trim())}let n=t.filter(Boolean).join(`
|
|
4
4
|
|
|
5
5
|
`),r=[];for(let o of[si,oi]){o.lastIndex=0;for(let c of n.matchAll(o))if(!r.includes(c[1]))r.push(c[1])}let s={};mn.lastIndex=0;for(let o of n.matchAll(mn)){let c=o[2];try{s[o[1]]=JSON.parse(c.replace(/^'(.*)'$/,'"$1"'))}catch{s[o[1]]=c}}return{exports:s,functions:r,code:n}}var oe="[data-native-chrome]";function ai(e){let t=(e??"").trim().toLowerCase();return t==="tabs"||t==="bar"?t:""}function yn(e,t){let n=ce(e);if(!n.known&&/^i-|:/.test(e))t?.(e);return n.known||/^i-|:/.test(e)?n.symbol:e}function ci(e){let t=(e??"").trim();if(!t.startsWith("/")||t.startsWith("//"))return null;return t}function bn(e){return e.replace(/ /g," ").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,'"').replace(/�?39;/g,"'").replace(/\s+/g," ").trim()}async function vn(e,t){if(!/\bdata-native-chrome\b/i.test(e))return{html:e,chrome:null};let n=[],r=[],s=new Set,o=[],c=[],l=null,d=null,p=!1;if(await new HTMLRewriter().on(oe,{element(m){p=!0;let y=m.getAttribute("data-stx-scope");if(y)s.add(y);n.push(ai(m.getAttribute("data-native-chrome"))),m.onEndTag(()=>{n.pop()})}}).on("[data-stx-component-wrapper]",{element(m){let y={scope:m.getAttribute("data-stx-scope")??"",children:0,chrome:0};o.push(y),m.onEndTag(()=>{if(o.pop(),y.scope&&y.children>0&&y.chrome===y.children)s.add(y.scope)})}}).on("[data-stx-component-wrapper] > *",{element(m){let y=o[o.length-1];if(!y)return;if(y.children++,m.hasAttribute("data-native-chrome"))y.chrome++}}).on(`${oe} [data-stx-scope]`,{element(m){let y=m.getAttribute("data-stx-scope");if(y)s.add(y)}}).on(`${oe} script[data-stx-component-factories]`,{element(m){let y=[...m.attributes].map(([v,g])=>g===""?v:`${v}="${g.replace(/"/g,""")}"`).join(" ");l="",m.onEndTag(()=>{c.push(`<script ${y}>${l}</script>`),l=null})},text(m){if(l!==null)l+=m.text}}).on(`${oe} a`,{element(m){let y=ci(m.getAttribute("href")),v=n[n.length-1]??"";if(!y||!v)return;let g=m.getAttribute("data-native-icon")||et(m.getAttribute("class")??""),u={path:y,title:"",region:v,label:m.getAttribute("aria-label")||m.getAttribute("title")||"",...g?{symbol:yn(g,t)}:{}};d=u,m.onEndTag(()=>{if(u.title=bn(u.title)||bn(u.label),r.push(u),d===u)d=null})},text(m){if(d)d.title+=m.text}}).on(`${oe} a *`,{element(m){if(!d||d.symbol)return;let y=m.getAttribute("data-native-icon")||et(m.getAttribute("class")??"");if(y)d.symbol=yn(y,t)}}).transform(new Response(e)).text(),!p)return{html:e,chrome:null};let h=await new HTMLRewriter().on(oe,{element(m){m.remove()}}).on("script[data-stx-owner]",{element(m){if(s.has(m.getAttribute("data-stx-owner")??""))m.remove()}}).transform(new Response(e)).text(),f=(m)=>r.filter((y)=>y.region===m).map(({path:y,title:v,symbol:g})=>({path:y,title:v,...g?{symbol:g}:{}}));return{html:c.join(`
|
|
6
|
-
`)+h,chrome:{tabs:f("tabs"),bar:f("bar")}}}var Ne=/<script\b([^>]*\bdata-stx-scoped\b[^>]*)>([\s\S]*?)<\/script>/gi,Sn=/function\s+(__stx_setup_[\w$]+)\s*\(/,li=/\bdata-stx-owner\s*=\s*["']([^"']+)["']/i;function it(e){Ne.lastIndex=0;for(let t of e.matchAll(Ne)){let n=t[2].trim(),r=Sn.exec(n)?.[1];if(r)return{name:r,code:n}}return null}function wn(e){let t=[];Ne.lastIndex=0;for(let n of e.matchAll(Ne)){let r=n[1],s=n[2].trim(),o=li.exec(r)?.[1],c=/\bdata-stx-component-factories\b/i.test(r);if(!s||!o&&!c&&!Sn.test(s))continue;t.push(o?{code:s,owner:o}:{code:s})}return t}function di(){let e=[Z.join(import.meta.dir,"..","primitives"),Z.join(import.meta.dir,"native","primitives")];for(let t of e)if(ui(Z.join(t,"View.stx")))return t;return e[0]}async function fi(e,t,n={}){e=await ue(e);let r=n.root??Z.dirname(t),s=await a(r),o=typeof s.root==="string"&&s.root?Z.resolve(r,s.root):r,c=(E,O)=>E?Z.isAbsolute(E)?E:Z.resolve(o,E):Z.join(o,O),l={root:r,layoutsDir:c(s.layoutsDir,"layouts"),partialsDir:c(s.partialsDir,"partials"),storesDir:c(s.storesDir,"stores"),componentsDir:n.componentsDir??(s.componentsDir?c(s.componentsDir,"components"):Z.join(o,"components")),buildMode:"serve",cache:!1,_targetComponentDirs:[di()],_targetComponentFallbackNames:["Button","Checkbox","Switch","TextInput","Image","Video"],_nativeHostAttrs:!0,skipEventDirectives:!0,_pluginComponentDirs:s._pluginComponentDirs??[]},d={...n.context??{},__stx_inject_css:!1,__stx_native_screen:!0},p=new Set([t]),h=await i(e,d,t,l,p),f=[],{html:m,chrome:y}=await vn(await ue(h),(E)=>{f.push({kind:"unknown-icon",tag:"data-native-chrome",name:E})}),{html:v,manifest:g}=pt(await ue(m)),u=await Wt(r),{document:w,diagnostics:b}=await gn(u?`<style>${u}</style>${v}`:v,{source:t,script:rt(e)});b.unshift(...f),pi(w.root,g);let N=d.__stx_runtime_head;if(typeof N?.title==="string"&&N.title.trim())w.title=N.title.trim();if(y)w.chrome=y;let S=it(v),k=wn(v);if(rt(e).code.trim()){let E=await ps(e,t,n.context,{forceClientSetup:!0}),O=it(E.setupCode??"");if(S=O??S,O&&!k.some((V)=>V.code===O.code))k.push({code:O.code})}let{buildModuleRegistryScript:x,registeredModuleIdsIn:A,registeredModuleNamesIn:M}=await import("./chunk-
|
|
6
|
+
`)+h,chrome:{tabs:f("tabs"),bar:f("bar")}}}var Ne=/<script\b([^>]*\bdata-stx-scoped\b[^>]*)>([\s\S]*?)<\/script>/gi,Sn=/function\s+(__stx_setup_[\w$]+)\s*\(/,li=/\bdata-stx-owner\s*=\s*["']([^"']+)["']/i;function it(e){Ne.lastIndex=0;for(let t of e.matchAll(Ne)){let n=t[2].trim(),r=Sn.exec(n)?.[1];if(r)return{name:r,code:n}}return null}function wn(e){let t=[];Ne.lastIndex=0;for(let n of e.matchAll(Ne)){let r=n[1],s=n[2].trim(),o=li.exec(r)?.[1],c=/\bdata-stx-component-factories\b/i.test(r);if(!s||!o&&!c&&!Sn.test(s))continue;t.push(o?{code:s,owner:o}:{code:s})}return t}function di(){let e=[Z.join(import.meta.dir,"..","primitives"),Z.join(import.meta.dir,"native","primitives")];for(let t of e)if(ui(Z.join(t,"View.stx")))return t;return e[0]}async function fi(e,t,n={}){e=await ue(e);let r=n.root??Z.dirname(t),s=await a(r),o=typeof s.root==="string"&&s.root?Z.resolve(r,s.root):r,c=(E,O)=>E?Z.isAbsolute(E)?E:Z.resolve(o,E):Z.join(o,O),l={root:r,layoutsDir:c(s.layoutsDir,"layouts"),partialsDir:c(s.partialsDir,"partials"),storesDir:c(s.storesDir,"stores"),componentsDir:n.componentsDir??(s.componentsDir?c(s.componentsDir,"components"):Z.join(o,"components")),buildMode:"serve",cache:!1,_targetComponentDirs:[di()],_targetComponentFallbackNames:["Button","Checkbox","Switch","TextInput","Image","Video"],_nativeHostAttrs:!0,skipEventDirectives:!0,_pluginComponentDirs:s._pluginComponentDirs??[]},d={...n.context??{},__stx_inject_css:!1,__stx_native_screen:!0},p=new Set([t]),h=await i(e,d,t,l,p),f=[],{html:m,chrome:y}=await vn(await ue(h),(E)=>{f.push({kind:"unknown-icon",tag:"data-native-chrome",name:E})}),{html:v,manifest:g}=pt(await ue(m)),u=await Wt(r),{document:w,diagnostics:b}=await gn(u?`<style>${u}</style>${v}`:v,{source:t,script:rt(e)});b.unshift(...f),pi(w.root,g);let N=d.__stx_runtime_head;if(typeof N?.title==="string"&&N.title.trim())w.title=N.title.trim();if(y)w.chrome=y;let S=it(v),k=wn(v);if(rt(e).code.trim()){let E=await ps(e,t,n.context,{forceClientSetup:!0}),O=it(E.setupCode??"");if(S=O??S,O&&!k.some((V)=>V.code===O.code))k.push({code:O.code})}let{buildModuleRegistryScript:x,registeredModuleIdsIn:A,registeredModuleNamesIn:M}=await import("./chunk-633a53wg.js"),j=async()=>{let E=[],O=k.map((T)=>T.code),V=await x(A(...O),{collectInputs:E,names:M(...O)});for(let T of E)p.add(T);return V},_=await j();if([...k.map((E)=>E.code),_??""].some((E)=>/\buseStore\s*\(/.test(E))&&/<script\b[^>]*\bdata-stx-stores\b/i.test(v)){let{getStoreScriptFor:E}=await import("./chunk-fmk9hjht.js"),O=[...k],V="";for(let T=0;T<8;T++){let R=await E(l.storesDir,[...O.map((I)=>I.code),_],{sharedModules:!0});if(!R)break;if(R.stores.join()===V)break;V=R.stores.join(),k.splice(0,k.length,{code:R.code,...R.functions?{stores:R.functions}:{}},...O);for(let I of new Bun.Glob("*.ts").scanSync({cwd:l.storesDir,absolute:!0}))p.add(I);_=await j()}}if(_)k.unshift({code:_,registry:!0});return{document:w,manifest:g,setup:S,scripts:k,diagnostics:b,html:v,dependencies:[...p]}}function pi(e,t){let n=new Map(t.entries.map((o)=>[o.id,o])),r=t.entries.reduce((o,c)=>Math.max(o,c.id),-1)+1,s=(o)=>{if(o._templated?.length&&o.bindings){if(o.bindingId===void 0||!n.has(o.bindingId)){let l={id:o.bindingId??r++,bindings:[]};o.bindingId=l.id,n.set(l.id,l),t.entries.push(l)}let c=n.get(o.bindingId);for(let l of o._templated){let d=`:${l}`,p=Oe(d);if(p&&!c.bindings.some((h)=>h.name===d))c.bindings.push({name:d,value:o.bindings[l],kind:p})}}for(let c of o.children)if(typeof c!=="string")s(c)};s(e)}async function ke(e,t={}){return fi(await Bun.file(e).text(),e,t)}var so=Symbol("stx.nativeWebStorage.raw");var de="__app";var yi=(e)=>Bun.hash(e).toString(36);var bi=/^ {2}try \{ factories\[("[0-9a-f]+")\] = factories\[\1\] \|\| /gm,vi=/^\(function\(__scopeId\) \{([\s\S]*)\}\)\("([^"\\]+)"\);\s*$/;function st(e){if(!e.startsWith(`(function() {
|
|
7
7
|
const factories = window.__stxComponentFactories = window.__stxComponentFactories || {};
|
|
8
8
|
`)||!e.endsWith(`
|
|
9
9
|
})();`))return null;let t=[...e.matchAll(bi)];if(t.length===0)return null;let n=[],r=105;for(let[s,o]of t.entries()){if(o.index!==r)return null;let c=JSON.parse(o[1]),l=o.index+o[0].length,d=`; }
|
|
@@ -16,7 +16,7 @@ ${g.map((w)=>`${w.text}
|
|
|
16
16
|
})();`}}if(f.stores?.some(c)){for(let v of f.stores.filter(c))l.set(n(v),v);return{code:`;(function() {
|
|
17
17
|
${f.stores.map((v)=>c(v)?`runtime.components[${JSON.stringify(n(v))}]();`:`(${v})();`).join(`
|
|
18
18
|
`)}
|
|
19
|
-
})();`}}let y=s(f);if(y&&c(y.body))return l.set(n(y.body),y.body),{...f,code:`runtime.components[${JSON.stringify(n(y.body))}](${JSON.stringify(y.scope)});`};return f}));return{bodies:l,screens:d}}var Si=[["props",()=>({})],["style",()=>({})],["events",()=>({})],["children",()=>[]],["_inlineStyle",()=>({})],["_styleSource",()=>""]];var wi=new Set(["text","html","show","if","for","model","class","style","ref"]);function xi(e){if(e.startsWith("@"))return"event";if(e.startsWith(":")&&wi.has(e.slice(1)))return e.slice(1);return"attr"}function Ni(e,t){if(typeof t==="string")return e==="";if(Array.isArray(t))return Array.isArray(e)&&e.length===0;return!!e&&typeof e==="object"&&!Array.isArray(e)&&Object.getPrototypeOf(e)===Object.prototype&&Object.keys(e).length===0}class ot extends Error{}function Nn(e){let t={...e};if(Object.prototype.hasOwnProperty.call(t,"~"))throw new ot;let n=0;if(Si.forEach(([r,s],o)=>{if(!Object.prototype.hasOwnProperty.call(t,r))n|=1<<o;else if(Ni(t[r],s()))delete t[r]}),Array.isArray(t.children))t.children=t.children.map((r)=>typeof r==="string"?r:Nn(r));if(n)t["~"]=n;return t}function kn(e){try{return{...e,root:Nn(e.root)}}catch(t){if(t instanceof ot)return null;throw t}}var ki=["kind","name","value"].join();function Tn(e){if(Object.keys(e).some((n)=>n!=="entries"))return null;let t=[];for(let n of e.entries){if(Object.keys(n).some((s)=>s!=="id"&&s!=="bindings"&&!(s==="template"&&n.template===!0)))return null;let r=[];for(let s of n.bindings){if(Object.keys(s).sort().join()!==ki||typeof s.value!=="string")return null;r.push(s.kind===xi(s.name)?[s.name,s.value]:[s.name,s.value,s.kind])}t.push(n.template?[n.id,r,1]:[n.id,r])}return t}async function Ri(e){try{let{loadCssEngineConfig:t}=await import("./chunk-
|
|
19
|
+
})();`}}let y=s(f);if(y&&c(y.body))return l.set(n(y.body),y.body),{...f,code:`runtime.components[${JSON.stringify(n(y.body))}](${JSON.stringify(y.scope)});`};return f}));return{bodies:l,screens:d}}var Si=[["props",()=>({})],["style",()=>({})],["events",()=>({})],["children",()=>[]],["_inlineStyle",()=>({})],["_styleSource",()=>""]];var wi=new Set(["text","html","show","if","for","model","class","style","ref"]);function xi(e){if(e.startsWith("@"))return"event";if(e.startsWith(":")&&wi.has(e.slice(1)))return e.slice(1);return"attr"}function Ni(e,t){if(typeof t==="string")return e==="";if(Array.isArray(t))return Array.isArray(e)&&e.length===0;return!!e&&typeof e==="object"&&!Array.isArray(e)&&Object.getPrototypeOf(e)===Object.prototype&&Object.keys(e).length===0}class ot extends Error{}function Nn(e){let t={...e};if(Object.prototype.hasOwnProperty.call(t,"~"))throw new ot;let n=0;if(Si.forEach(([r,s],o)=>{if(!Object.prototype.hasOwnProperty.call(t,r))n|=1<<o;else if(Ni(t[r],s()))delete t[r]}),Array.isArray(t.children))t.children=t.children.map((r)=>typeof r==="string"?r:Nn(r));if(n)t["~"]=n;return t}function kn(e){try{return{...e,root:Nn(e.root)}}catch(t){if(t instanceof ot)return null;throw t}}var ki=["kind","name","value"].join();function Tn(e){if(Object.keys(e).some((n)=>n!=="entries"))return null;let t=[];for(let n of e.entries){if(Object.keys(n).some((s)=>s!=="id"&&s!=="bindings"&&!(s==="template"&&n.template===!0)))return null;let r=[];for(let s of n.bindings){if(Object.keys(s).sort().join()!==ki||typeof s.value!=="string")return null;r.push(s.kind===xi(s.name)?[s.name,s.value]:[s.name,s.value,s.kind])}t.push(n.template?[n.id,r,1]:[n.id,r])}return t}async function Ri(e){try{let{loadCssEngineConfig:t}=await import("./chunk-p2se8s6r.js");return Nt(await t(e))}catch{return{}}}var Te="__runtime",_i="__messages";function Re(e){let n=[H.join(import.meta.dir,"..","runtime",`${e}.ts`),H.join(import.meta.dir,"..","runtime",`${e}.js`),H.join(import.meta.dir,"native","runtime",`${e}.js`)].find((r)=>En(r));if(!n)throw Error(`Native runtime module ${e} is missing`);return n}async function at(e,t,n,r,s){let o={name:"stx-screen-inputs",setup(l){l.onLoad({filter:/.*/,namespace:"file"},({path:d})=>{r.add(d);let p=s?.get(d);return p===void 0?void 0:{contents:p,loader:"js"}})}},c=await Bun.build({entrypoints:[e],target:"browser",format:"iife",minify:n,plugins:[o,...t],define:{"process.env.NODE_ENV":JSON.stringify(n?"production":"development")}});if(!c.success){let l=c.logs.map((d)=>String(d.message??d)).join(`
|
|
20
20
|
`);throw Error(`Could not bundle ${e}:
|
|
21
21
|
${l}`)}return(await c.outputs[0].text()).trim()}function Ai(e,t){return Mr(e,t)}function Oi(e,t){return`export default globalThis.__stxNativeRuntime.messages(${JSON.stringify(e)}, ${JSON.stringify(t)});`}function Ii(e){let t=new Map;for(let[n,{language:r,area:s}]of e.files){let o=Oi(r,s);t.set(n,o),t.set(Ti(n),o)}return t}function An(e){let t=new Set;for(let n of e.matchAll(/__stxNativeRuntime\.messages\(\s*"[\w-]+"\s*,\s*"([\w/-]+)"\s*\)/g))t.add(n[1]);return[...t].sort()}function Ci(e,t){let n=H.isAbsolute(e.meta.source)?H.relative(t,e.meta.source).split(H.sep).join("/"):e.meta.source;return{...e,script:{exports:e.script.exports,functions:[],code:""},meta:{...e.meta,source:n,compiledAt:0}}}function Pi(e){let t=new Map,n=e.flatMap(({name:l,document:d})=>{let{_stylesheetRules:p,_stylesheetTheme:h}=d.root;return p===void 0&&h===void 0?[]:[{name:l,rules:p??{},theme:h}]});for(let{rules:l}of n)for(let[d,p]of Object.entries(l)){let h=JSON.stringify(p),f=t.get(d)??new Map,m=f.get(h);if(m)m.count++;else f.set(h,{value:p,count:1});t.set(d,f)}let r={},s=new Map;for(let[l,d]of t){let[p,h]=[...d].sort(([,f],[,m])=>m.count-f.count)[0];r[l]=h.value,s.set(l,p)}let o={},c=new Map;for(let{name:l,rules:d,theme:p}of n){let h={};for(let[m,y]of Object.entries(d))if(JSON.stringify(y)!==s.get(m))h[m]=y;let f=null;if(p!==void 0)f=Bun.hash(JSON.stringify(p)).toString(36),o[f]=p;c.set(l,{order:Object.keys(d),own:h,theme:f})}return{rules:r,themes:o,screens:c}}function Mi(e){let{_stylesheetRules:t,_stylesheetTheme:n,...r}=e.root;return{...e,root:r}}async function ct(e){let t=Object.keys(e.screens);if(t.length===0)throw Error("screens must name at least one .stx file");let n=e.routed??!0,r=e.initialScreen??t[0];if(!e.screens[r])throw Error(`Initial screen ${r} is not in screens`);let s=H.resolve(e.root??process.cwd());if(e.messages&&!e.routesDir)throw Error("messages ship a language at a time beside route files: they need routesDir");if(e.sharedRuntime&&!e.routesDir)throw Error("sharedRuntime is the route files' runtime: it needs routesDir");if(e.messages&&!e.sharedRuntime)throw Error("messages are read by the shared runtime: they need sharedRuntime");if(e.messages&&e.outFile)throw Error("messages leave the languages out of the screens' code, which the one-file bundle cannot read: build it without messages");let o=e.messages?await Ai(s,e.messages):null,c=e.styleConfig??await Ri(s),l=o?Ii(o):null,d=[],p=async()=>{for(let T of t){let R=H.resolve(s,e.screens[T]);if(!R.endsWith(".stx"))throw Error(`Screen ${T} must name a .stx file`);d.push({name:T,file:R,compiled:await ke(R,{root:s})})}};await xt(c,()=>l?es(l,p):p());let h=Re("jsc-globals"),f=Re("shared-screen"),m=e.app?H.resolve(s,e.app):null;if(m&&!En(m))throw Error(`The app script ${e.app} does not exist`);if(m&&!n)throw Error("An app script needs a routed bundle");if(m&&e.screens[de])throw Error(`${de} is the app script's route, not a screen name`);let y=e.browser;if(e.screens[Te])throw Error(`${Te} is the runtime prelude's file, not a screen name`);let v=mt();if(y&&e.routesDir)throw Error("A browser screen is one route; routesDir is for device hosts");let g=new Set(d.flatMap(({compiled:T})=>T.dependencies)),u=null;if(e.routesDir&&e.sharedRuntime&&e.shareModules!==!1&&process.env.STX_NATIVE_SHARE_MODULES!=="0"){let T=[],R=d.map(({name:D,compiled:F})=>{let B=F.scripts.filter((W)=>!W.registry).map((W)=>W.code);return{name:D,ids:Dr(...B),names:Qs(...B)}}),I=()=>eo(R,{collectInputs:T});if(u=await(l?es(l,I):I()),u)for(let D of T)g.add(D)}let w=u,b=e.routesDir&&e.sharedRuntime&&e.shareModules!==!1&&process.env.STX_NATIVE_SHARE_MODULES!=="0"?xn(d.map(({name:T,compiled:R})=>({name:T,scripts:R.scripts}))):null,N=Pi(d.map(({name:T,compiled:R})=>({name:T,document:R.document}))),S=(T,R,I)=>{let D=n?`var routeName = g.__stxNativeRoute || ${JSON.stringify(r)};
|
|
22
22
|
var isApp = ${m?`routeName === ${JSON.stringify(de)}`:"false"};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
import{va,xa,Sa,ka,fh}from"./chunk-d96xddt9.js";import"./chunk-48g9wez2.js";import"./chunk-m6rzsbas.js";import"./chunk-r8zhed35.js";import"./chunk-t1shvfhm.js";import"./chunk-rd33qkfs.js";import"./chunk-b0z2n941.js";import"./chunk-m3z13f59.js";import"./chunk-gwjh981q.js";import"./chunk-xgnmgjpv.js";import"./chunk-a81rt2t4.js";import"./chunk-9k8ztdcc.js";import"./chunk-yk456jp4.js";import"./chunk-932zx5q4.js";import"./chunk-k2ex94n8.js";import"./chunk-yb71b2d6.js";import"./chunk-edhxg3rz.js";import"./chunk-rqd6b2nc.js";import"./chunk-8rk79ha1.js";import"./chunk-q3azy64b.js";import"./chunk-evxp3wmv.js";import"./chunk-f8p8ggvw.js";import"./chunk-y4mp1rra.js";import"./chunk-dvpk4c1y.js";import"./chunk-x5seqmrv.js";import"./chunk-tpfxvw4q.js";import"./chunk-4833k99b.js";import"./chunk-b51p56k5.js";export{va as buildNative,fh as default,xa as findCraftBinary,ka as getAvailableFormats,Sa as getAvailableTargets};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{_}from"./chunk-
|
|
2
|
+
import{_}from"./chunk-y4mp1rra.js";import{i}from"./chunk-t1shvfhm.js";import p from"fs";import g from"path";import*as y from"readline";var e={reset:"\x1B[0m",bold:"\x1B[1m",dim:"\x1B[2m",red:"\x1B[31m",green:"\x1B[32m",yellow:"\x1B[33m",blue:"\x1B[34m",magenta:"\x1B[35m",cyan:"\x1B[36m"},u={help:{description:"Show available commands",usage:"help [command]",handler:async(t,o)=>{if(t[0]&&u[t[0]]){let n=u[t[0]];console.log(`
|
|
3
3
|
${e.bold}${t[0]}${e.reset} - ${n.description}`),console.log(` Usage: ${e.cyan}${n.usage}${e.reset}
|
|
4
4
|
`)}else{console.log(`
|
|
5
5
|
${e.bold}Available Commands:${e.reset}
|