@reformer/builder 3.0.0-beta.4 → 3.0.0-beta.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/dist/assets/{App-BzMuBv1U.js → App-BupMDG_t.js} +6 -6
  2. package/dist/assets/{BootError-CH4BoW__.js → BootError-CWnToysV.js} +1 -1
  3. package/dist/assets/{ChatPanel-9qHpjmLO.js → ChatPanel-B4wt7hBH.js} +3 -3
  4. package/dist/assets/{CodeEditor-CuHAtGtB.js → CodeEditor-Cca8j3Z3.js} +1 -1
  5. package/dist/assets/{MarkdownPreview-DwyxNTbn.js → MarkdownPreview-CmqjlfzE.js} +3 -3
  6. package/dist/assets/{RawJsonEditor-jYY7XCW2.js → RawJsonEditor-D5mwkIJa.js} +1 -1
  7. package/dist/assets/{boot-DTWnczkO.js → boot-BCJd6Ujw.js} +1 -1
  8. package/dist/assets/{byok-BM21dMSQ.js → byok-B9mwOrn0.js} +1 -1
  9. package/dist/assets/{editor.api-B4g2PJYj.js → editor.api-BWDeQ8t4.js} +1 -1
  10. package/dist/assets/{freemarker2-BlPZHoyx.js → freemarker2-DQaxDgne.js} +1 -1
  11. package/dist/assets/{handlebars-Dd8yor3z.js → handlebars-e1hbsCFi.js} +1 -1
  12. package/dist/assets/{html-C3wl1HPz.js → html-QXilGQ4Y.js} +1 -1
  13. package/dist/assets/index-BwhW-Atz.js +3 -0
  14. package/dist/assets/{index-OZOUDUGD.js → index-CF7RI8Bt.js} +1 -1
  15. package/dist/assets/{index-CU07HM8S.js → index-CLTXPf4k.js} +1 -1
  16. package/dist/assets/{index-CY45QPm-.js → index-DhcNqNgT.js} +2 -2
  17. package/dist/assets/{index-DCa3wFwm.js → index-U9gpmElw.js} +3 -3
  18. package/dist/assets/{index-BmJVVkA_.js → index-eRs9yupj.js} +1 -1
  19. package/dist/assets/{javascript-BF-EEvQI.js → javascript-C7cOj8ds.js} +1 -1
  20. package/dist/assets/{jsonMode-DGlgsS1d.js → jsonMode-DEqS3I0B.js} +1 -1
  21. package/dist/assets/{liquid-C0Gfg9TY.js → liquid-grdNDW6i.js} +1 -1
  22. package/dist/assets/{load-FrEYc91y.js → load-QsSQTL2T.js} +3 -3
  23. package/dist/assets/{mdx-bIG0iFaA.js → mdx-BGpbXlZS.js} +1 -1
  24. package/dist/assets/{monaco-languages-D5Bh48hh.js → monaco-languages-BZWxuU3F.js} +2 -2
  25. package/dist/assets/{monaco-setup-CAOrXrMd.js → monaco-setup-1PbjxubL.js} +3 -3
  26. package/dist/assets/{python-CciOb-4N.js → python-D5X7CY5Y.js} +1 -1
  27. package/dist/assets/{razor-cbEBt-Vr.js → razor-B2pbhZKy.js} +1 -1
  28. package/dist/assets/{reformer-ui-kit-11-BhXMU01R.js → reformer-ui-kit-11-bLtlFFvp.js} +1 -1
  29. package/dist/assets/{reformer-ui-kit-D8fAdwPH.js → reformer-ui-kit-tUqYBSLv.js} +1 -1
  30. package/dist/assets/{typescript-4hiO_obL.js → typescript-Ccn-IGn9.js} +1 -1
  31. package/dist/assets/{typescript-CNVC9ZHk.js → typescript-DL3gRsAd.js} +1 -1
  32. package/dist/assets/useFormField-BLbvmpme-Dwz_jyMW.js +1 -0
  33. package/dist/assets/{xml-RU_PX54U.js → xml-NgTjWpvZ.js} +1 -1
  34. package/dist/assets/{yaml-DsXE0ah6.js → yaml-CboCRslW.js} +1 -1
  35. package/dist/index.html +1 -1
  36. package/package.json +1 -1
  37. package/dist/assets/index-BC3M-FCZ.js +0 -3
  38. package/dist/assets/useFormField-BLbvmpme-BASGgtAT.js +0 -1
@@ -1 +1 @@
1
- import{r,j as h}from"./index-CY45QPm-.js";import{F as x}from"./monaco-setup-CAOrXrMd.js";import"./editor.api-B4g2PJYj.js";import"./App-BzMuBv1U.js";import"./reformer-ui-kit-D8fAdwPH.js";import"./index-OZOUDUGD.js";import"./useFormField-BLbvmpme-BASGgtAT.js";import"./index-BmJVVkA_.js";import"./load-FrEYc91y.js";import"./boot-DTWnczkO.js";function v({value:c,theme:m,onChange:f,onFocusChange:a,revealLine:n,revealNonce:d}){const s=r.useRef(null),l=r.useRef(null),[u,p]=r.useState(!1),g=(t,e)=>{s.current=t,l.current=e,t.onDidFocusEditorText(()=>a(!0)),t.onDidBlurEditorText(()=>a(!1)),p(!0)};return r.useEffect(()=>{const t=s.current,e=l.current;if(!u||!t||!e||!n)return;const i=t.getModel();if(!i)return;const o=Math.min(Math.max(n,1),i.getLineCount());t.revealLineInCenter(o),t.setSelection(new e.Range(o,1,o,i.getLineMaxColumn(o))),t.focus()},[d,u,n]),h.jsx(x,{height:"100%",language:"json",theme:m==="dark"?"vs-dark":"light",value:c,onChange:t=>f(t??""),onMount:g,options:{minimap:{enabled:!1},fontSize:11,lineNumbers:"on",folding:!0,scrollBeyondLastLine:!1,tabSize:2,wordWrap:"off",automaticLayout:!0,renderLineHighlight:"line",overviewRulerLanes:0,scrollbar:{verticalScrollbarSize:9,horizontalScrollbarSize:9},padding:{top:8,bottom:8}}})}export{v as default};
1
+ import{r,j as h}from"./index-DhcNqNgT.js";import{F as x}from"./monaco-setup-1PbjxubL.js";import"./editor.api-BWDeQ8t4.js";import"./App-BupMDG_t.js";import"./reformer-ui-kit-tUqYBSLv.js";import"./index-CF7RI8Bt.js";import"./useFormField-BLbvmpme-Dwz_jyMW.js";import"./index-eRs9yupj.js";import"./load-QsSQTL2T.js";import"./boot-BCJd6Ujw.js";function v({value:c,theme:m,onChange:f,onFocusChange:a,revealLine:n,revealNonce:d}){const s=r.useRef(null),l=r.useRef(null),[u,p]=r.useState(!1),g=(t,e)=>{s.current=t,l.current=e,t.onDidFocusEditorText(()=>a(!0)),t.onDidBlurEditorText(()=>a(!1)),p(!0)};return r.useEffect(()=>{const t=s.current,e=l.current;if(!u||!t||!e||!n)return;const i=t.getModel();if(!i)return;const o=Math.min(Math.max(n,1),i.getLineCount());t.revealLineInCenter(o),t.setSelection(new e.Range(o,1,o,i.getLineMaxColumn(o))),t.focus()},[d,u,n]),h.jsx(x,{height:"100%",language:"json",theme:m==="dark"?"vs-dark":"light",value:c,onChange:t=>f(t??""),onMount:g,options:{minimap:{enabled:!1},fontSize:11,lineNumbers:"on",folding:!0,scrollBeyondLastLine:!1,tabSize:2,wordWrap:"off",automaticLayout:!0,renderLineHighlight:"line",overviewRulerLanes:0,scrollbar:{verticalScrollbarSize:9,horizontalScrollbarSize:9},padding:{top:8,bottom:8}}})}export{v as default};
@@ -1,2 +1,2 @@
1
- import{l as u,g as m,a as g,b as d,t as r,c as p,d as b,D as k}from"./load-FrEYc91y.js";import{R as I}from"./reformer-ui-kit-D8fAdwPH.js";function R(a){const e=a instanceof Error?a.message:String(a),t=/does not provide an export named '([^']+)'/.exec(e),i=/module '([^']+)'/.exec(e);return t?i?`рантайм билдера не экспортирует «${t[1]}» из ${i[1]} — кит собран против более новой версии`:`рантайм билдера не экспортирует «${t[1]}» — кит собран против более новой версии`:e.split(`
1
+ import{l as u,g as m,a as g,b as d,t as r,c as p,d as b,D as k}from"./load-QsSQTL2T.js";import{R as I}from"./reformer-ui-kit-tUqYBSLv.js";function R(a){const e=a instanceof Error?a.message:String(a),t=/does not provide an export named '([^']+)'/.exec(e),i=/module '([^']+)'/.exec(e);return t?i?`рантайм билдера не экспортирует «${t[1]}» из ${i[1]} — кит собран против более новой версии`:`рантайм билдера не экспортирует «${t[1]}» — кит собран против более новой версии`:e.split(`
2
2
  `)[0]}async function c(a,e){let t;try{t=await a.loadNamespace()}catch(n){return{ok:!1,reason:R(n)}}if(!(e.infra.fieldWrapper in t))return{ok:!1,reason:`кит не поставляет враппер поля «${e.infra.fieldWrapper}» — поля формы рендерить нечем`};const i=[e.infra.asyncBoundary,e.infra.list].filter(n=>!(n in t));return{ok:!0,namespace:t,missingInfra:i}}let f=null;function E(){return f??I}function l(a){f=a}let s=null;function y(){return s}async function K(){const a=g(),e=d(a),t=await c(e,r(e.catalog));if(t.ok)return l(t.namespace),{kit:e,missingInfra:t.missingInfra};p();const i=`${e.label} ${e.version}: ${t.reason}`,n=b(k);if(e.id!==n.id){const o=await c(n,r(n.catalog));if(o.ok)return l(o.namespace),{kit:n,fallbackReason:i,missingInfra:o.missingInfra}}return{kit:n,fallbackReason:i,missingInfra:[]}}async function _(){await u(),s=await K(),s.fallbackReason&&console.error(`[reformer-builder] кит не активирован — ${s.fallbackReason}`);const a=m().branding?.title;a&&(document.title=a)}const S=Object.freeze(Object.defineProperty({__proto__:null,bootRuntime:_,getKitBootResult:y},Symbol.toStringTag,{value:"Module"}));export{y as a,S as b,E as g};
@@ -1,4 +1,4 @@
1
- import{P as Rb,a as Pb,D as Nb}from"./ChatPanel-9qHpjmLO.js";import"./index-CY45QPm-.js";import"./reformer-ui-kit-D8fAdwPH.js";import"./index-OZOUDUGD.js";import"./useFormField-BLbvmpme-BASGgtAT.js";import"./App-BzMuBv1U.js";import"./index-BmJVVkA_.js";import"./load-FrEYc91y.js";import"./boot-DTWnczkO.js";var _f="vercel.ai.error",jb=Symbol.for(_f),Ol,Al,tt=class bf extends(Al=Error,Ol=jb,Al){constructor({name:t,message:n,cause:r}){super(n),this[Ol]=!0,this.name=t,this.cause=r}static isInstance(t){return bf.hasMarker(t,_f)}static hasMarker(t,n){const r=Symbol.for(n);return t!=null&&typeof t=="object"&&r in t&&typeof t[r]=="boolean"&&t[r]===!0}},wf="AI_APICallError",xf=`vercel.ai.error.${wf}`,Db=Symbol.for(xf),Ml,Rl,Pt=class extends(Rl=tt,Ml=Db,Rl){constructor({message:t,url:n,requestBodyValues:r,statusCode:o,responseHeaders:a,responseBody:i,cause:s,isRetryable:c=o!=null&&(o===408||o===409||o===429||o>=500),data:u}){super({name:wf,message:t,cause:s}),this[Ml]=!0,this.url=n,this.requestBodyValues=r,this.statusCode=o,this.responseHeaders=a,this.responseBody=i,this.isRetryable=c,this.data=u}static isInstance(t){return tt.hasMarker(t,xf)}},If="AI_EmptyResponseBodyError",kf=`vercel.ai.error.${If}`,Ub=Symbol.for(kf),Pl,Nl,Tf=class extends(Nl=tt,Pl=Ub,Nl){constructor({message:t="Empty response body"}={}){super({name:If,message:t}),this[Pl]=!0}static isInstance(t){return tt.hasMarker(t,kf)}};function Sf(e){return e==null?"unknown error":typeof e=="string"?e:e instanceof Error?e.toString():JSON.stringify(e)}var $f="AI_InvalidArgumentError",Ef=`vercel.ai.error.${$f}`,zb=Symbol.for(Ef),jl,Dl,An=class extends(Dl=tt,jl=zb,Dl){constructor({message:t,cause:n,argument:r}){super({name:$f,message:t,cause:n}),this[jl]=!0,this.argument=r}static isInstance(t){return tt.hasMarker(t,Ef)}},Cf="AI_InvalidResponseDataError",Of=`vercel.ai.error.${Cf}`,qb=Symbol.for(Of),Ul,zl,Fb=class extends(zl=tt,Ul=qb,zl){constructor({data:t,message:n=`Invalid response data: ${JSON.stringify(t)}.`}){super({name:Cf,message:n}),this[Ul]=!0,this.data=t}static isInstance(t){return tt.hasMarker(t,Of)}},Af="AI_JSONParseError",Mf=`vercel.ai.error.${Af}`,Lb=Symbol.for(Mf),ql,Fl,Jo=class extends(Fl=tt,ql=Lb,Fl){constructor({text:t,cause:n}){super({name:Af,message:`JSON parsing failed: Text: ${t}.
1
+ import{P as Rb,a as Pb,D as Nb}from"./ChatPanel-B4wt7hBH.js";import"./index-DhcNqNgT.js";import"./reformer-ui-kit-tUqYBSLv.js";import"./index-CF7RI8Bt.js";import"./useFormField-BLbvmpme-Dwz_jyMW.js";import"./App-BupMDG_t.js";import"./index-eRs9yupj.js";import"./load-QsSQTL2T.js";import"./boot-BCJd6Ujw.js";var _f="vercel.ai.error",jb=Symbol.for(_f),Ol,Al,tt=class bf extends(Al=Error,Ol=jb,Al){constructor({name:t,message:n,cause:r}){super(n),this[Ol]=!0,this.name=t,this.cause=r}static isInstance(t){return bf.hasMarker(t,_f)}static hasMarker(t,n){const r=Symbol.for(n);return t!=null&&typeof t=="object"&&r in t&&typeof t[r]=="boolean"&&t[r]===!0}},wf="AI_APICallError",xf=`vercel.ai.error.${wf}`,Db=Symbol.for(xf),Ml,Rl,Pt=class extends(Rl=tt,Ml=Db,Rl){constructor({message:t,url:n,requestBodyValues:r,statusCode:o,responseHeaders:a,responseBody:i,cause:s,isRetryable:c=o!=null&&(o===408||o===409||o===429||o>=500),data:u}){super({name:wf,message:t,cause:s}),this[Ml]=!0,this.url=n,this.requestBodyValues=r,this.statusCode=o,this.responseHeaders=a,this.responseBody=i,this.isRetryable=c,this.data=u}static isInstance(t){return tt.hasMarker(t,xf)}},If="AI_EmptyResponseBodyError",kf=`vercel.ai.error.${If}`,Ub=Symbol.for(kf),Pl,Nl,Tf=class extends(Nl=tt,Pl=Ub,Nl){constructor({message:t="Empty response body"}={}){super({name:If,message:t}),this[Pl]=!0}static isInstance(t){return tt.hasMarker(t,kf)}};function Sf(e){return e==null?"unknown error":typeof e=="string"?e:e instanceof Error?e.toString():JSON.stringify(e)}var $f="AI_InvalidArgumentError",Ef=`vercel.ai.error.${$f}`,zb=Symbol.for(Ef),jl,Dl,An=class extends(Dl=tt,jl=zb,Dl){constructor({message:t,cause:n,argument:r}){super({name:$f,message:t,cause:n}),this[jl]=!0,this.argument=r}static isInstance(t){return tt.hasMarker(t,Ef)}},Cf="AI_InvalidResponseDataError",Of=`vercel.ai.error.${Cf}`,qb=Symbol.for(Of),Ul,zl,Fb=class extends(zl=tt,Ul=qb,zl){constructor({data:t,message:n=`Invalid response data: ${JSON.stringify(t)}.`}){super({name:Cf,message:n}),this[Ul]=!0,this.data=t}static isInstance(t){return tt.hasMarker(t,Of)}},Af="AI_JSONParseError",Mf=`vercel.ai.error.${Af}`,Lb=Symbol.for(Mf),ql,Fl,Jo=class extends(Fl=tt,ql=Lb,Fl){constructor({text:t,cause:n}){super({name:Af,message:`JSON parsing failed: Text: ${t}.
2
2
  Error message: ${Sf(n)}`,cause:n}),this[ql]=!0,this.text=t}static isInstance(t){return tt.hasMarker(t,Mf)}},Rf="AI_LoadAPIKeyError",Pf=`vercel.ai.error.${Rf}`,Zb=Symbol.for(Pf),Ll,Zl,Co=class extends(Zl=tt,Ll=Zb,Zl){constructor({message:t}){super({name:Rf,message:t}),this[Ll]=!0}static isInstance(t){return tt.hasMarker(t,Pf)}},Nf="AI_NoSuchModelError",jf=`vercel.ai.error.${Nf}`,Bb=Symbol.for(jf),Bl,Vl,Hl=class extends(Vl=tt,Bl=Bb,Vl){constructor({errorName:e=Nf,modelId:t,modelType:n,message:r=`No such ${n}: ${t}`}){super({name:e,message:r}),this[Bl]=!0,this.modelId=t,this.modelType=n}static isInstance(e){return tt.hasMarker(e,jf)}},Df="AI_NoSuchProviderReferenceError",Uf=`vercel.ai.error.${Df}`,Vb=Symbol.for(Uf),Jl,Gl,Hb=class extends(Gl=tt,Jl=Vb,Gl){constructor({provider:t,reference:n,message:r=`No provider reference found for provider '${t}'. Available providers: ${Object.keys(n).join(", ")}`}){super({name:Df,message:r}),this[Jl]=!0,this.provider=t,this.reference=n}static isInstance(t){return tt.hasMarker(t,Uf)}},zf="AI_TypeValidationError",qf=`vercel.ai.error.${zf}`,Jb=Symbol.for(qf),Wl,Kl,Xr=class Ri extends(Kl=tt,Wl=Jb,Kl){constructor({value:t,cause:n,context:r}){let o="Type validation failed";if(r?.field&&(o+=` for ${r.field}`),r?.entityName||r?.entityId){o+=" (";const a=[];r.entityName&&a.push(r.entityName),r.entityId&&a.push(`id: "${r.entityId}"`),o+=a.join(", "),o+=")"}super({name:zf,message:`${o}: Value: ${JSON.stringify(t)}.
3
3
  Error message: ${Sf(n)}`,cause:n}),this[Wl]=!0,this.value=t,this.context=r}static isInstance(t){return tt.hasMarker(t,qf)}static wrap({value:t,cause:n,context:r}){var o,a,i;return Ri.isInstance(n)&&n.value===t&&((o=n.context)==null?void 0:o.field)===r?.field&&((a=n.context)==null?void 0:a.entityName)===r?.entityName&&((i=n.context)==null?void 0:i.entityId)===r?.entityId?n:new Ri({value:t,cause:n,context:r})}},Ff="AI_UnsupportedFunctionalityError",Lf=`vercel.ai.error.${Ff}`,Gb=Symbol.for(Lf),Yl,Xl,lr=class extends(Xl=tt,Yl=Gb,Xl){constructor({functionality:t,message:n=`'${t}' functionality not supported.`}){super({name:Ff,message:n}),this[Yl]=!0,this.functionality=t}static isInstance(t){return tt.hasMarker(t,Lf)}};function B(e,t,n){function r(s,c){if(s._zod||Object.defineProperty(s,"_zod",{value:{def:c,constr:i,traits:new Set},enumerable:!1}),s._zod.traits.has(e))return;s._zod.traits.add(e),t(s,c);const u=i.prototype,d=Object.keys(u);for(let p=0;p<d.length;p++){const m=d[p];m in s||(s[m]=u[m].bind(s))}}const o=n?.Parent??Object;class a extends o{}Object.defineProperty(a,"name",{value:e});function i(s){var c;const u=n?.Parent?new a:this;r(u,s),(c=u._zod).deferred??(c.deferred=[]);for(const d of u._zod.deferred)d();return u}return Object.defineProperty(i,"init",{value:r}),Object.defineProperty(i,Symbol.hasInstance,{value:s=>n?.Parent&&s instanceof n.Parent?!0:s?._zod?.traits?.has(e)}),Object.defineProperty(i,"name",{value:e}),i}class Or extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class Zf extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}}const Bf={};function qn(e){return Bf}function Vf(e){const t=Object.values(e).filter(r=>typeof r=="number");return Object.entries(e).filter(([r,o])=>t.indexOf(+r)===-1).map(([r,o])=>o)}function Pi(e,t){return typeof t=="bigint"?t.toString():t}function pa(e){return{get value(){{const t=e();return Object.defineProperty(this,"value",{value:t}),t}}}}function Ts(e){return e==null}function Ss(e){const t=e.startsWith("^")?1:0,n=e.endsWith("$")?e.length-1:e.length;return e.slice(t,n)}function Wb(e,t){const n=(e.toString().split(".")[1]||"").length,r=t.toString();let o=(r.split(".")[1]||"").length;if(o===0&&/\d?e-\d?/.test(r)){const c=r.match(/\d?e-(\d?)/);c?.[1]&&(o=Number.parseInt(c[1]))}const a=n>o?n:o,i=Number.parseInt(e.toFixed(a).replace(".","")),s=Number.parseInt(t.toFixed(a).replace(".",""));return i%s/10**a}const Ql=Symbol("evaluating");function je(e,t,n){let r;Object.defineProperty(e,t,{get(){if(r!==Ql)return r===void 0&&(r=Ql,r=n()),r},set(o){Object.defineProperty(e,t,{value:o})},configurable:!0})}function hr(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function yr(...e){const t={};for(const n of e){const r=Object.getOwnPropertyDescriptors(n);Object.assign(t,r)}return Object.defineProperties({},t)}function eu(e){return JSON.stringify(e)}function Kb(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}const Hf="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Qr(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const Yb=pa(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{const e=Function;return new e(""),!0}catch{return!1}});function Mr(e){if(Qr(e)===!1)return!1;const t=e.constructor;if(t===void 0||typeof t!="function")return!0;const n=t.prototype;return!(Qr(n)===!1||Object.prototype.hasOwnProperty.call(n,"isPrototypeOf")===!1)}function Jf(e){return Mr(e)?{...e}:Array.isArray(e)?[...e]:e}const Xb=new Set(["string","number","symbol"]);function Rr(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Ln(e,t,n){const r=new e._zod.constr(t??e._zod.def);return(!t||n?.parent)&&(r._zod.parent=e),r}function le(e){const t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function Qb(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}const e0={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]};function t0(e,t){const n=e._zod.def,r=yr(e._zod.def,{get shape(){const o={};for(const a in t){if(!(a in n.shape))throw new Error(`Unrecognized key: "${a}"`);t[a]&&(o[a]=n.shape[a])}return hr(this,"shape",o),o},checks:[]});return Ln(e,r)}function n0(e,t){const n=e._zod.def,r=yr(e._zod.def,{get shape(){const o={...e._zod.def.shape};for(const a in t){if(!(a in n.shape))throw new Error(`Unrecognized key: "${a}"`);t[a]&&delete o[a]}return hr(this,"shape",o),o},checks:[]});return Ln(e,r)}function r0(e,t){if(!Mr(t))throw new Error("Invalid input to extend: expected a plain object");const n=e._zod.def.checks;if(n&&n.length>0)throw new Error("Object schemas containing refinements cannot be extended. Use `.safeExtend()` instead.");const o=yr(e._zod.def,{get shape(){const a={...e._zod.def.shape,...t};return hr(this,"shape",a),a},checks:[]});return Ln(e,o)}function o0(e,t){if(!Mr(t))throw new Error("Invalid input to safeExtend: expected a plain object");const n={...e._zod.def,get shape(){const r={...e._zod.def.shape,...t};return hr(this,"shape",r),r},checks:e._zod.def.checks};return Ln(e,n)}function a0(e,t){const n=yr(e._zod.def,{get shape(){const r={...e._zod.def.shape,...t._zod.def.shape};return hr(this,"shape",r),r},get catchall(){return t._zod.def.catchall},checks:[]});return Ln(e,n)}function i0(e,t,n){const r=yr(t._zod.def,{get shape(){const o=t._zod.def.shape,a={...o};if(n)for(const i in n){if(!(i in o))throw new Error(`Unrecognized key: "${i}"`);n[i]&&(a[i]=e?new e({type:"optional",innerType:o[i]}):o[i])}else for(const i in o)a[i]=e?new e({type:"optional",innerType:o[i]}):o[i];return hr(this,"shape",a),a},checks:[]});return Ln(t,r)}function s0(e,t,n){const r=yr(t._zod.def,{get shape(){const o=t._zod.def.shape,a={...o};if(n)for(const i in n){if(!(i in a))throw new Error(`Unrecognized key: "${i}"`);n[i]&&(a[i]=new e({type:"nonoptional",innerType:o[i]}))}else for(const i in o)a[i]=new e({type:"nonoptional",innerType:o[i]});return hr(this,"shape",a),a},checks:[]});return Ln(t,r)}function $r(e,t=0){if(e.aborted===!0)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue!==!0)return!0;return!1}function ir(e,t){return t.map(n=>{var r;return(r=n).path??(r.path=[]),n.path.unshift(e),n})}function Oo(e){return typeof e=="string"?e:e?.message}function Fn(e,t,n){const r={...e,path:e.path??[]};if(!e.message){const o=Oo(e.inst?._zod.def?.error?.(e))??Oo(t?.error?.(e))??Oo(n.customError?.(e))??Oo(n.localeError?.(e))??"Invalid input";r.message=o}return delete r.inst,delete r.continue,t?.reportInput||delete r.input,r}function $s(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function eo(...e){const[t,n,r]=e;return typeof t=="string"?{message:t,code:"custom",input:n,inst:r}:{...t}}const Gf=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),e.message=JSON.stringify(t,Pi,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},Wf=B("$ZodError",Gf),Kf=B("$ZodError",Gf,{Parent:Error});function l0(e,t=n=>n.message){const n={},r=[];for(const o of e.issues)o.path.length>0?(n[o.path[0]]=n[o.path[0]]||[],n[o.path[0]].push(t(o))):r.push(t(o));return{formErrors:r,fieldErrors:n}}function u0(e,t=n=>n.message){const n={_errors:[]},r=o=>{for(const a of o.issues)if(a.code==="invalid_union"&&a.errors.length)a.errors.map(i=>r({issues:i}));else if(a.code==="invalid_key")r({issues:a.issues});else if(a.code==="invalid_element")r({issues:a.issues});else if(a.path.length===0)n._errors.push(t(a));else{let i=n,s=0;for(;s<a.path.length;){const c=a.path[s];s===a.path.length-1?(i[c]=i[c]||{_errors:[]},i[c]._errors.push(t(a))):i[c]=i[c]||{_errors:[]},i=i[c],s++}}};return r(e),n}const Es=e=>(t,n,r,o)=>{const a=r?Object.assign(r,{async:!1}):{async:!1},i=t._zod.run({value:n,issues:[]},a);if(i instanceof Promise)throw new Or;if(i.issues.length){const s=new(o?.Err??e)(i.issues.map(c=>Fn(c,a,qn())));throw Hf(s,o?.callee),s}return i.value},Cs=e=>async(t,n,r,o)=>{const a=r?Object.assign(r,{async:!0}):{async:!0};let i=t._zod.run({value:n,issues:[]},a);if(i instanceof Promise&&(i=await i),i.issues.length){const s=new(o?.Err??e)(i.issues.map(c=>Fn(c,a,qn())));throw Hf(s,o?.callee),s}return i.value},fa=e=>(t,n,r)=>{const o=r?{...r,async:!1}:{async:!1},a=t._zod.run({value:n,issues:[]},o);if(a instanceof Promise)throw new Or;return a.issues.length?{success:!1,error:new(e??Wf)(a.issues.map(i=>Fn(i,o,qn())))}:{success:!0,data:a.value}},c0=fa(Kf),ma=e=>async(t,n,r)=>{const o=r?Object.assign(r,{async:!0}):{async:!0};let a=t._zod.run({value:n,issues:[]},o);return a instanceof Promise&&(a=await a),a.issues.length?{success:!1,error:new e(a.issues.map(i=>Fn(i,o,qn())))}:{success:!0,data:a.value}},d0=ma(Kf),p0=e=>(t,n,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Es(e)(t,n,o)},f0=e=>(t,n,r)=>Es(e)(t,n,r),m0=e=>async(t,n,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Cs(e)(t,n,o)},h0=e=>async(t,n,r)=>Cs(e)(t,n,r),y0=e=>(t,n,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return fa(e)(t,n,o)},v0=e=>(t,n,r)=>fa(e)(t,n,r),g0=e=>async(t,n,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return ma(e)(t,n,o)},_0=e=>async(t,n,r)=>ma(e)(t,n,r),b0=/^[cC][^\s-]{8,}$/,w0=/^[0-9a-z]+$/,x0=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,I0=/^[0-9a-vA-V]{20}$/,k0=/^[A-Za-z0-9]{27}$/,T0=/^[a-zA-Z0-9_-]{21}$/,S0=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,$0=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,tu=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,E0=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,C0="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function O0(){return new RegExp(C0,"u")}const A0=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,M0=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,R0=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,P0=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,N0=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Yf=/^[A-Za-z0-9_-]*$/,j0=/^\+(?:[0-9]){6,14}[0-9]$/,Xf="(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))",D0=new RegExp(`^${Xf}$`);function Qf(e){const t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function U0(e){return new RegExp(`^${Qf(e)}$`)}function z0(e){const t=Qf({precision:e.precision}),n=["Z"];e.local&&n.push(""),e.offset&&n.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");const r=`${t}(?:${n.join("|")})`;return new RegExp(`^${Xf}T(?:${r})$`)}const q0=e=>{const t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},F0=/^-?\d+$/,L0=/^-?\d+(?:\.\d+)?/,Z0=/^(?:true|false)$/i,B0=/^null$/i,V0=/^[^A-Z]*$/,H0=/^[^a-z]*$/,Ft=B("$ZodCheck",(e,t)=>{var n;e._zod??(e._zod={}),e._zod.def=t,(n=e._zod).onattach??(n.onattach=[])}),em={number:"number",bigint:"bigint",object:"date"},tm=B("$ZodCheckLessThan",(e,t)=>{Ft.init(e,t);const n=em[typeof t.value];e._zod.onattach.push(r=>{const o=r._zod.bag,a=(t.inclusive?o.maximum:o.exclusiveMaximum)??Number.POSITIVE_INFINITY;t.value<a&&(t.inclusive?o.maximum=t.value:o.exclusiveMaximum=t.value)}),e._zod.check=r=>{(t.inclusive?r.value<=t.value:r.value<t.value)||r.issues.push({origin:n,code:"too_big",maximum:t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),nm=B("$ZodCheckGreaterThan",(e,t)=>{Ft.init(e,t);const n=em[typeof t.value];e._zod.onattach.push(r=>{const o=r._zod.bag,a=(t.inclusive?o.minimum:o.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>a&&(t.inclusive?o.minimum=t.value:o.exclusiveMinimum=t.value)}),e._zod.check=r=>{(t.inclusive?r.value>=t.value:r.value>t.value)||r.issues.push({origin:n,code:"too_small",minimum:t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),J0=B("$ZodCheckMultipleOf",(e,t)=>{Ft.init(e,t),e._zod.onattach.push(n=>{var r;(r=n._zod.bag).multipleOf??(r.multipleOf=t.value)}),e._zod.check=n=>{if(typeof n.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof n.value=="bigint"?n.value%t.value===BigInt(0):Wb(n.value,t.value)===0)||n.issues.push({origin:typeof n.value,code:"not_multiple_of",divisor:t.value,input:n.value,inst:e,continue:!t.abort})}}),G0=B("$ZodCheckNumberFormat",(e,t)=>{Ft.init(e,t),t.format=t.format||"float64";const n=t.format?.includes("int"),r=n?"int":"number",[o,a]=e0[t.format];e._zod.onattach.push(i=>{const s=i._zod.bag;s.format=t.format,s.minimum=o,s.maximum=a,n&&(s.pattern=F0)}),e._zod.check=i=>{const s=i.value;if(n){if(!Number.isInteger(s)){i.issues.push({expected:r,format:t.format,code:"invalid_type",continue:!1,input:s,inst:e});return}if(!Number.isSafeInteger(s)){s>0?i.issues.push({input:s,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,continue:!t.abort}):i.issues.push({input:s,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,continue:!t.abort});return}}s<o&&i.issues.push({origin:"number",input:s,code:"too_small",minimum:o,inclusive:!0,inst:e,continue:!t.abort}),s>a&&i.issues.push({origin:"number",input:s,code:"too_big",maximum:a,inst:e})}}),W0=B("$ZodCheckMaxLength",(e,t)=>{var n;Ft.init(e,t),(n=e._zod.def).when??(n.when=r=>{const o=r.value;return!Ts(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<o&&(r._zod.bag.maximum=t.maximum)}),e._zod.check=r=>{const o=r.value;if(o.length<=t.maximum)return;const i=$s(o);r.issues.push({origin:i,code:"too_big",maximum:t.maximum,inclusive:!0,input:o,inst:e,continue:!t.abort})}}),K0=B("$ZodCheckMinLength",(e,t)=>{var n;Ft.init(e,t),(n=e._zod.def).when??(n.when=r=>{const o=r.value;return!Ts(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>o&&(r._zod.bag.minimum=t.minimum)}),e._zod.check=r=>{const o=r.value;if(o.length>=t.minimum)return;const i=$s(o);r.issues.push({origin:i,code:"too_small",minimum:t.minimum,inclusive:!0,input:o,inst:e,continue:!t.abort})}}),Y0=B("$ZodCheckLengthEquals",(e,t)=>{var n;Ft.init(e,t),(n=e._zod.def).when??(n.when=r=>{const o=r.value;return!Ts(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag;o.minimum=t.length,o.maximum=t.length,o.length=t.length}),e._zod.check=r=>{const o=r.value,a=o.length;if(a===t.length)return;const i=$s(o),s=a>t.length;r.issues.push({origin:i,...s?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:r.value,inst:e,continue:!t.abort})}}),ha=B("$ZodCheckStringFormat",(e,t)=>{var n,r;Ft.init(e,t),e._zod.onattach.push(o=>{const a=o._zod.bag;a.format=t.format,t.pattern&&(a.patterns??(a.patterns=new Set),a.patterns.add(t.pattern))}),t.pattern?(n=e._zod).check??(n.check=o=>{t.pattern.lastIndex=0,!t.pattern.test(o.value)&&o.issues.push({origin:"string",code:"invalid_format",format:t.format,input:o.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(r=e._zod).check??(r.check=()=>{})}),X0=B("$ZodCheckRegex",(e,t)=>{ha.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:"regex",input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),Q0=B("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=V0),ha.init(e,t)}),ew=B("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=H0),ha.init(e,t)}),tw=B("$ZodCheckIncludes",(e,t)=>{Ft.init(e,t);const n=Rr(t.includes),r=new RegExp(typeof t.position=="number"?`^.{${t.position}}${n}`:n);t.pattern=r,e._zod.onattach.push(o=>{const a=o._zod.bag;a.patterns??(a.patterns=new Set),a.patterns.add(r)}),e._zod.check=o=>{o.value.includes(t.includes,t.position)||o.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:o.value,inst:e,continue:!t.abort})}}),nw=B("$ZodCheckStartsWith",(e,t)=>{Ft.init(e,t);const n=new RegExp(`^${Rr(t.prefix)}.*`);t.pattern??(t.pattern=n),e._zod.onattach.push(r=>{const o=r._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(n)}),e._zod.check=r=>{r.value.startsWith(t.prefix)||r.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:r.value,inst:e,continue:!t.abort})}}),rw=B("$ZodCheckEndsWith",(e,t)=>{Ft.init(e,t);const n=new RegExp(`.*${Rr(t.suffix)}$`);t.pattern??(t.pattern=n),e._zod.onattach.push(r=>{const o=r._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(n)}),e._zod.check=r=>{r.value.endsWith(t.suffix)||r.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:r.value,inst:e,continue:!t.abort})}}),ow=B("$ZodCheckOverwrite",(e,t)=>{Ft.init(e,t),e._zod.check=n=>{n.value=t.tx(n.value)}});class aw{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}const r=t.split(`
4
4
  `).filter(i=>i),o=Math.min(...r.map(i=>i.length-i.trimStart().length)),a=r.map(i=>i.slice(o)).map(i=>" ".repeat(this.indent*2)+i);for(const i of a)this.content.push(i)}compile(){const t=Function,n=this?.args,o=[...(this?.content??[""]).map(a=>` ${a}`)];return new t(...n,o.join(`
@@ -1,4 +1,4 @@
1
- import{_ as XF}from"./index-CY45QPm-.js";function JF(s){if(s.length===0)throw new Error("Invalid tail call");return[s.slice(0,s.length-1),s[s.length-1]]}function jt(s,e,t=(i,n)=>i===n){if(s===e)return!0;if(!s||!e||s.length!==e.length)return!1;for(let i=0,n=s.length;i<n;i++)if(!t(s[i],e[i]))return!1;return!0}function e8(s,e){const t=s.length-1;e<t&&(s[e]=s[t]),s.pop()}function t8(s,e,t){return W1(s.length,i=>t(s[i],e))}function W1(s,e){let t=0,i=s-1;for(;t<=i;){const n=(t+i)/2|0,o=e(n);if(o<0)t=n+1;else if(o>0)i=n-1;else return n}return-(t+1)}function vT(s,e,t){if(s=s|0,s>=e.length)throw new TypeError("invalid index");const i=e[Math.floor(e.length*Math.random())],n=[],o=[],r=[];for(const a of e){const l=t(a,i);l<0?n.push(a):l>0?o.push(a):r.push(a)}return s<n.length?vT(s,n,t):s<n.length+r.length?r[0]:vT(s-(n.length+r.length),o,t)}function _de(s,e){const t=[];let i;for(const n of s.slice(0).sort(e))!i||e(i[0],n)!==0?(i=[n],t.push(i)):i.push(n);return t}function*QD(s,e){let t,i;for(const n of s)i!==void 0&&e(i,n)?t.push(n):(t&&(yield t),t=[n]),i=n;t&&(yield t)}function OP(s,e){for(let t=0;t<=s.length;t++)e(t===0?void 0:s[t-1],t===s.length?void 0:s[t])}function i8(s,e){for(let t=0;t<s.length;t++)e(t===0?void 0:s[t-1],s[t],t+1===s.length?void 0:s[t+1])}function XD(s){return s.filter(e=>!!e)}function yT(s){let e=0;for(let t=0;t<s.length;t++)s[t]&&(s[e]=s[t],e+=1);s.length=e}function n8(s){return!Array.isArray(s)||s.length===0}function HC(s){return Array.isArray(s)&&s.length>0}function pl(s,e=t=>t){const t=new Set;return s.filter(i=>{const n=e(i);return t.has(n)?!1:(t.add(n),!0)})}function sn(s,e){let t=typeof e=="number"?s:0;typeof e=="number"?t=s:(t=0,e=s);const i=[];if(t<=e)for(let n=t;n<e;n++)i.push(n);else for(let n=t;n>e;n--)i.push(n);return i}function zC(s,e,t){const i=s.slice(0,e),n=s.slice(e);return i.concat(t,n)}function lv(s,e){const t=s.indexOf(e);t>-1&&(s.splice(t,1),s.unshift(e))}function l_(s,e){const t=s.indexOf(e);t>-1&&(s.splice(t,1),s.push(e))}function Kl(s,e){for(const t of e)s.push(t)}function bde(s,e){const t=[];for(const i of s){const n=e(i);n!==void 0&&t.push(n)}return t}function s8(s){return Array.isArray(s)?s:[s]}function o8(s,e,t){const i=FP(s,e),n=s.length,o=t.length;s.length=n+o;for(let r=n-1;r>=i;r--)s[r+o]=s[r];for(let r=0;r<o;r++)s[r+i]=t[r]}function V1(s,e,t,i){const n=FP(s,e);let o=s.splice(n,t);return o===void 0&&(o=[]),o8(s,n,i),o}function FP(s,e){return e<0?Math.max(e+s.length,0):Math.min(e,s.length)}var al;(function(s){function e(o){return o<0}s.isLessThan=e;function t(o){return o<=0}s.isLessThanOrEqual=t;function i(o){return o>0}s.isGreaterThan=i;function n(o){return o===0}s.isNeitherLessOrGreaterThan=n,s.greaterThan=1,s.lessThan=-1,s.neitherLessOrGreaterThan=0})(al||(al={}));function ds(s,e){return(t,i)=>e(s(t),s(i))}function r8(...s){return(e,t)=>{for(const i of s){const n=i(e,t);if(!al.isNeitherLessOrGreaterThan(n))return n}return al.neitherLessOrGreaterThan}}const ga=(s,e)=>s-e,a8=(s,e)=>ga(s?1:0,e?1:0);function l8(s){return(e,t)=>-s(e,t)}function Cde(s){return(e,t)=>e===void 0?t===void 0?al.neitherLessOrGreaterThan:al.lessThan:t===void 0?al.greaterThan:s(e,t)}class Tu{constructor(e){this.firstIdx=0,this.items=e,this.lastIdx=this.items.length-1}get length(){return this.lastIdx-this.firstIdx+1}takeWhile(e){let t=this.firstIdx;for(;t<this.items.length&&e(this.items[t]);)t++;const i=t===this.firstIdx?null:this.items.slice(this.firstIdx,t);return this.firstIdx=t,i}peek(){if(this.length!==0)return this.items[this.firstIdx]}dequeue(){const e=this.items[this.firstIdx];return this.firstIdx++,e}takeCount(e){const t=this.items.slice(this.firstIdx,this.firstIdx+e);return this.firstIdx+=e,t}}const $d=class $d{constructor(e){this.iterate=e}toArray(){const e=[];return this.iterate(t=>(e.push(t),!0)),e}filter(e){return new $d(t=>this.iterate(i=>e(i)?t(i):!0))}map(e){return new $d(t=>this.iterate(i=>t(e(i))))}findLast(e){let t;return this.iterate(i=>(e(i)&&(t=i),!0)),t}findLastMaxBy(e){let t,i=!0;return this.iterate(n=>((i||al.isGreaterThan(e(n,t)))&&(i=!1,t=n),!0)),t}};$d.empty=new $d(e=>{});let Vc=$d;class Wy{constructor(e){this._indexMap=e}static createSortPermutation(e,t){const i=Array.from(e.keys()).sort((n,o)=>t(e[n],e[o]));return new Wy(i)}apply(e){return e.map((t,i)=>e[this._indexMap[i]])}inverse(){const e=this._indexMap.slice();for(let t=0;t<this._indexMap.length;t++)e[this._indexMap[t]]=t;return new Wy(e)}}function wde(s){return s.reduce((e,t)=>e+t,0)}class c8{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(e){setTimeout(()=>{throw e.stack?Nu.isErrorNoTelemetry(e)?new Nu(e.message+`
1
+ import{_ as XF}from"./index-DhcNqNgT.js";function JF(s){if(s.length===0)throw new Error("Invalid tail call");return[s.slice(0,s.length-1),s[s.length-1]]}function jt(s,e,t=(i,n)=>i===n){if(s===e)return!0;if(!s||!e||s.length!==e.length)return!1;for(let i=0,n=s.length;i<n;i++)if(!t(s[i],e[i]))return!1;return!0}function e8(s,e){const t=s.length-1;e<t&&(s[e]=s[t]),s.pop()}function t8(s,e,t){return W1(s.length,i=>t(s[i],e))}function W1(s,e){let t=0,i=s-1;for(;t<=i;){const n=(t+i)/2|0,o=e(n);if(o<0)t=n+1;else if(o>0)i=n-1;else return n}return-(t+1)}function vT(s,e,t){if(s=s|0,s>=e.length)throw new TypeError("invalid index");const i=e[Math.floor(e.length*Math.random())],n=[],o=[],r=[];for(const a of e){const l=t(a,i);l<0?n.push(a):l>0?o.push(a):r.push(a)}return s<n.length?vT(s,n,t):s<n.length+r.length?r[0]:vT(s-(n.length+r.length),o,t)}function _de(s,e){const t=[];let i;for(const n of s.slice(0).sort(e))!i||e(i[0],n)!==0?(i=[n],t.push(i)):i.push(n);return t}function*QD(s,e){let t,i;for(const n of s)i!==void 0&&e(i,n)?t.push(n):(t&&(yield t),t=[n]),i=n;t&&(yield t)}function OP(s,e){for(let t=0;t<=s.length;t++)e(t===0?void 0:s[t-1],t===s.length?void 0:s[t])}function i8(s,e){for(let t=0;t<s.length;t++)e(t===0?void 0:s[t-1],s[t],t+1===s.length?void 0:s[t+1])}function XD(s){return s.filter(e=>!!e)}function yT(s){let e=0;for(let t=0;t<s.length;t++)s[t]&&(s[e]=s[t],e+=1);s.length=e}function n8(s){return!Array.isArray(s)||s.length===0}function HC(s){return Array.isArray(s)&&s.length>0}function pl(s,e=t=>t){const t=new Set;return s.filter(i=>{const n=e(i);return t.has(n)?!1:(t.add(n),!0)})}function sn(s,e){let t=typeof e=="number"?s:0;typeof e=="number"?t=s:(t=0,e=s);const i=[];if(t<=e)for(let n=t;n<e;n++)i.push(n);else for(let n=t;n>e;n--)i.push(n);return i}function zC(s,e,t){const i=s.slice(0,e),n=s.slice(e);return i.concat(t,n)}function lv(s,e){const t=s.indexOf(e);t>-1&&(s.splice(t,1),s.unshift(e))}function l_(s,e){const t=s.indexOf(e);t>-1&&(s.splice(t,1),s.push(e))}function Kl(s,e){for(const t of e)s.push(t)}function bde(s,e){const t=[];for(const i of s){const n=e(i);n!==void 0&&t.push(n)}return t}function s8(s){return Array.isArray(s)?s:[s]}function o8(s,e,t){const i=FP(s,e),n=s.length,o=t.length;s.length=n+o;for(let r=n-1;r>=i;r--)s[r+o]=s[r];for(let r=0;r<o;r++)s[r+i]=t[r]}function V1(s,e,t,i){const n=FP(s,e);let o=s.splice(n,t);return o===void 0&&(o=[]),o8(s,n,i),o}function FP(s,e){return e<0?Math.max(e+s.length,0):Math.min(e,s.length)}var al;(function(s){function e(o){return o<0}s.isLessThan=e;function t(o){return o<=0}s.isLessThanOrEqual=t;function i(o){return o>0}s.isGreaterThan=i;function n(o){return o===0}s.isNeitherLessOrGreaterThan=n,s.greaterThan=1,s.lessThan=-1,s.neitherLessOrGreaterThan=0})(al||(al={}));function ds(s,e){return(t,i)=>e(s(t),s(i))}function r8(...s){return(e,t)=>{for(const i of s){const n=i(e,t);if(!al.isNeitherLessOrGreaterThan(n))return n}return al.neitherLessOrGreaterThan}}const ga=(s,e)=>s-e,a8=(s,e)=>ga(s?1:0,e?1:0);function l8(s){return(e,t)=>-s(e,t)}function Cde(s){return(e,t)=>e===void 0?t===void 0?al.neitherLessOrGreaterThan:al.lessThan:t===void 0?al.greaterThan:s(e,t)}class Tu{constructor(e){this.firstIdx=0,this.items=e,this.lastIdx=this.items.length-1}get length(){return this.lastIdx-this.firstIdx+1}takeWhile(e){let t=this.firstIdx;for(;t<this.items.length&&e(this.items[t]);)t++;const i=t===this.firstIdx?null:this.items.slice(this.firstIdx,t);return this.firstIdx=t,i}peek(){if(this.length!==0)return this.items[this.firstIdx]}dequeue(){const e=this.items[this.firstIdx];return this.firstIdx++,e}takeCount(e){const t=this.items.slice(this.firstIdx,this.firstIdx+e);return this.firstIdx+=e,t}}const $d=class $d{constructor(e){this.iterate=e}toArray(){const e=[];return this.iterate(t=>(e.push(t),!0)),e}filter(e){return new $d(t=>this.iterate(i=>e(i)?t(i):!0))}map(e){return new $d(t=>this.iterate(i=>t(e(i))))}findLast(e){let t;return this.iterate(i=>(e(i)&&(t=i),!0)),t}findLastMaxBy(e){let t,i=!0;return this.iterate(n=>((i||al.isGreaterThan(e(n,t)))&&(i=!1,t=n),!0)),t}};$d.empty=new $d(e=>{});let Vc=$d;class Wy{constructor(e){this._indexMap=e}static createSortPermutation(e,t){const i=Array.from(e.keys()).sort((n,o)=>t(e[n],e[o]));return new Wy(i)}apply(e){return e.map((t,i)=>e[this._indexMap[i]])}inverse(){const e=this._indexMap.slice();for(let t=0;t<this._indexMap.length;t++)e[this._indexMap[t]]=t;return new Wy(e)}}function wde(s){return s.reduce((e,t)=>e+t,0)}class c8{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(e){setTimeout(()=>{throw e.stack?Nu.isErrorNoTelemetry(e)?new Nu(e.message+`
2
2
 
3
3
  `+e.stack):new Error(e.message+`
4
4
 
@@ -1,3 +1,3 @@
1
- import{l as c}from"./editor.api-B4g2PJYj.js";import"./index-CY45QPm-.js";const s=["assign","flush","ftl","return","global","import","include","break","continue","local","nested","nt","setting","stop","t","lt","rt","fallback"],d=["attempt","autoesc","autoEsc","compress","comment","escape","noescape","function","if","list","items","sep","macro","noparse","noParse","noautoesc","noAutoEsc","outputformat","switch","visit","recurse"],r={close:">",id:"angle",open:"<"},a={close:"\\]",id:"bracket",open:"\\["},F={close:"[>\\]]",id:"auto",open:"[<\\[]"},k={close:"\\}",id:"dollar",open1:"\\$",open2:"\\{"},p={close:"\\]",id:"bracket",open1:"\\[",open2:"="};function l(t){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],comments:{blockComment:[`${t.open}--`,`--${t.close}`]},autoCloseBefore:`
1
+ import{l as c}from"./editor.api-BWDeQ8t4.js";import"./index-DhcNqNgT.js";const s=["assign","flush","ftl","return","global","import","include","break","continue","local","nested","nt","setting","stop","t","lt","rt","fallback"],d=["attempt","autoesc","autoEsc","compress","comment","escape","noescape","function","if","list","items","sep","macro","noparse","noParse","noautoesc","noAutoEsc","outputformat","switch","visit","recurse"],r={close:">",id:"angle",open:"<"},a={close:"\\]",id:"bracket",open:"\\["},F={close:"[>\\]]",id:"auto",open:"[<\\[]"},k={close:"\\}",id:"dollar",open1:"\\$",open2:"\\{"},p={close:"\\]",id:"bracket",open1:"\\[",open2:"="};function l(t){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],comments:{blockComment:[`${t.open}--`,`--${t.close}`]},autoCloseBefore:`
2
2
  \r }]),.:;=`,autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],folding:{markers:{start:new RegExp(`${t.open}#(?:${d.join("|")})([^/${t.close}]*(?!/)${t.close})[^${t.open}]*$`),end:new RegExp(`${t.open}/#(?:${d.join("|")})[\\r\\n\\t ]*>`)}},onEnterRules:[{beforeText:new RegExp(`${t.open}#(?!(?:${s.join("|")}))([a-zA-Z_]+)([^/${t.close}]*(?!/)${t.close})[^${t.open}]*$`),afterText:new RegExp(`^${t.open}/#([a-zA-Z_]+)[\\r\\n\\t ]*${t.close}$`),action:{indentAction:c.IndentAction.IndentOutdent}},{beforeText:new RegExp(`${t.open}#(?!(?:${s.join("|")}))([a-zA-Z_]+)([^/${t.close}]*(?!/)${t.close})[^${t.open}]*$`),action:{indentAction:c.IndentAction.Indent}}]}}function g(){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],autoCloseBefore:`
3
3
  \r }]),.:;=`,autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],folding:{markers:{start:new RegExp(`[<\\[]#(?:${d.join("|")})([^/>\\]]*(?!/)[>\\]])[^<\\[]*$`),end:new RegExp(`[<\\[]/#(?:${d.join("|")})[\\r\\n\\t ]*>`)}},onEnterRules:[{beforeText:new RegExp(`[<\\[]#(?!(?:${s.join("|")}))([a-zA-Z_]+)([^/>\\]]*(?!/)[>\\]])[^[<\\[]]*$`),afterText:new RegExp("^[<\\[]/#([a-zA-Z_]+)[\\r\\n\\t ]*[>\\]]$"),action:{indentAction:c.IndentAction.IndentOutdent}},{beforeText:new RegExp(`[<\\[]#(?!(?:${s.join("|")}))([a-zA-Z_]+)([^/>\\]]*(?!/)[>\\]])[^[<\\[]]*$`),action:{indentAction:c.IndentAction.Indent}}]}}function _(t,n){const i=`_${t.id}_${n.id}`,e=u=>u.replace(/__id__/g,i),o=u=>{const m=u.source.replace(/__id__/g,i);return new RegExp(m,u.flags)};return{unicode:!0,includeLF:!1,start:e("default__id__"),ignoreCase:!1,defaultToken:"invalid",tokenPostfix:".freemarker2",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],[e("open__id__")]:new RegExp(t.open),[e("close__id__")]:new RegExp(t.close),[e("iOpen1__id__")]:new RegExp(n.open1),[e("iOpen2__id__")]:new RegExp(n.open2),[e("iClose__id__")]:new RegExp(n.close),[e("startTag__id__")]:o(/(@open__id__)(#)/),[e("endTag__id__")]:o(/(@open__id__)(\/#)/),[e("startOrEndTag__id__")]:o(/(@open__id__)(\/?#)/),[e("closeTag1__id__")]:o(/((?:@blank)*)(@close__id__)/),[e("closeTag2__id__")]:o(/((?:@blank)*\/?)(@close__id__)/),blank:/[ \t\n\r]/,keywords:["false","true","in","as","using"],directiveStartCloseTag1:/attempt|recover|sep|auto[eE]sc|no(?:autoe|AutoE)sc|compress|default|no[eE]scape|comment|no[pP]arse/,directiveStartCloseTag2:/else|break|continue|return|stop|flush|t|lt|rt|nt|nested|recurse|fallback|ftl/,directiveStartBlank:/if|else[iI]f|list|for[eE]ach|switch|case|assign|global|local|include|import|function|macro|transform|visit|stop|return|call|setting|output[fF]ormat|nested|recurse|escape|ftl|items/,directiveEndCloseTag1:/if|list|items|sep|recover|attempt|for[eE]ach|local|global|assign|function|macro|output[fF]ormat|auto[eE]sc|no(?:autoe|AutoE)sc|compress|transform|switch|escape|no[eE]scape/,escapedChar:/\\(?:[ntrfbgla\\'"\{=]|(?:x[0-9A-Fa-f]{1,4}))/,asciiDigit:/[0-9]/,integer:/[0-9]+/,nonEscapedIdStartChar:/[\$@-Z_a-z\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u1FFF\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183-\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3006\u3031-\u3035\u303B-\u303C\u3040-\u318F\u31A0-\u31BA\u31F0-\u31FF\u3300-\u337F\u3400-\u4DB5\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8D0-\uA8D9\uA8F2-\uA8F7\uA8FB\uA900-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF-\uA9D9\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA50-\uAA59\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5-\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uABC0-\uABE2\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40-\uFB41\uFB43-\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,escapedIdChar:/\\[\-\.:#]/,idStartChar:/(?:@nonEscapedIdStartChar)|(?:@escapedIdChar)/,id:/(?:@idStartChar)(?:(?:@idStartChar)|(?:@asciiDigit))*/,specialHashKeys:/\*\*|\*|false|true|in|as|using/,namedSymbols:/&lt;=|&gt;=|\\lte|\\lt|&lt;|\\gte|\\gt|&gt;|&amp;&amp;|\\and|-&gt;|->|==|!=|\+=|-=|\*=|\/=|%=|\+\+|--|<=|&&|\|\||:|\.\.\.|\.\.\*|\.\.<|\.\.!|\?\?|=|<|\+|-|\*|\/|%|\||\.\.|\?|!|&|\.|,|;/,arrows:["->","-&gt;"],delimiters:[";",":",",","."],stringOperators:["lte","lt","gte","gt"],noParseTags:["noparse","noParse","comment"],tokenizer:{[e("default__id__")]:[{include:e("@directive_token__id__")},{include:e("@interpolation_and_text_token__id__")}],[e("fmExpression__id__.directive")]:[{include:e("@blank_and_expression_comment_token__id__")},{include:e("@directive_end_token__id__")},{include:e("@expression_token__id__")}],[e("fmExpression__id__.interpolation")]:[{include:e("@blank_and_expression_comment_token__id__")},{include:e("@expression_token__id__")},{include:e("@greater_operators_token__id__")}],[e("inParen__id__.plain")]:[{include:e("@blank_and_expression_comment_token__id__")},{include:e("@directive_end_token__id__")},{include:e("@expression_token__id__")}],[e("inParen__id__.gt")]:[{include:e("@blank_and_expression_comment_token__id__")},{include:e("@expression_token__id__")},{include:e("@greater_operators_token__id__")}],[e("noSpaceExpression__id__")]:[{include:e("@no_space_expression_end_token__id__")},{include:e("@directive_end_token__id__")},{include:e("@expression_token__id__")}],[e("unifiedCall__id__")]:[{include:e("@unified_call_token__id__")}],[e("singleString__id__")]:[{include:e("@string_single_token__id__")}],[e("doubleString__id__")]:[{include:e("@string_double_token__id__")}],[e("rawSingleString__id__")]:[{include:e("@string_single_raw_token__id__")}],[e("rawDoubleString__id__")]:[{include:e("@string_double_raw_token__id__")}],[e("expressionComment__id__")]:[{include:e("@expression_comment_token__id__")}],[e("noParse__id__")]:[{include:e("@no_parse_token__id__")}],[e("terseComment__id__")]:[{include:e("@terse_comment_token__id__")}],[e("directive_token__id__")]:[[o(/(?:@startTag__id__)(@directiveStartCloseTag1)(?:@closeTag1__id__)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{cases:{"@noParseTags":{token:"tag",next:e("@noParse__id__.$3")},"@default":{token:"tag"}}},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(?:@startTag__id__)(@directiveStartCloseTag2)(?:@closeTag2__id__)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(?:@startTag__id__)(@directiveStartBlank)(@blank)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"",next:e("@fmExpression__id__.directive")}]],[o(/(?:@endTag__id__)(@directiveEndCloseTag1)(?:@closeTag1__id__)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(@open__id__)(@)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive",next:e("@unifiedCall__id__")}]],[o(/(@open__id__)(\/@)((?:(?:@id)(?:\.(?:@id))*)?)(?:@closeTag1__id__)/),[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(@open__id__)#--/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:{token:"comment",next:e("@terseComment__id__")}],[o(/(?:@startOrEndTag__id__)([a-zA-Z_]+)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag.invalid",next:e("@fmExpression__id__.directive")}]]],[e("interpolation_and_text_token__id__")]:[[o(/(@iOpen1__id__)(@iOpen2__id__)/),[{token:n.id==="bracket"?"@brackets.interpolation":"delimiter.interpolation"},{token:n.id==="bracket"?"delimiter.interpolation":"@brackets.interpolation",next:e("@fmExpression__id__.interpolation")}]],[/[\$#<\[\{]|(?:@blank)+|[^\$<#\[\{\n\r\t ]+/,{token:"source"}]],[e("string_single_token__id__")]:[[/[^'\\]/,{token:"string"}],[/@escapedChar/,{token:"string.escape"}],[/'/,{token:"string",next:"@pop"}]],[e("string_double_token__id__")]:[[/[^"\\]/,{token:"string"}],[/@escapedChar/,{token:"string.escape"}],[/"/,{token:"string",next:"@pop"}]],[e("string_single_raw_token__id__")]:[[/[^']+/,{token:"string.raw"}],[/'/,{token:"string.raw",next:"@pop"}]],[e("string_double_raw_token__id__")]:[[/[^"]+/,{token:"string.raw"}],[/"/,{token:"string.raw",next:"@pop"}]],[e("expression_token__id__")]:[[/(r?)(['"])/,{cases:{"r'":[{token:"keyword"},{token:"string.raw",next:e("@rawSingleString__id__")}],'r"':[{token:"keyword"},{token:"string.raw",next:e("@rawDoubleString__id__")}],"'":[{token:"source"},{token:"string",next:e("@singleString__id__")}],'"':[{token:"source"},{token:"string",next:e("@doubleString__id__")}]}}],[/(?:@integer)(?:\.(?:@integer))?/,{cases:{"(?:@integer)":{token:"number"},"@default":{token:"number.float"}}}],[/(\.)(@blank*)(@specialHashKeys)/,[{token:"delimiter"},{token:""},{token:"identifier"}]],[/(?:@namedSymbols)/,{cases:{"@arrows":{token:"meta.arrow"},"@delimiters":{token:"delimiter"},"@default":{token:"operators"}}}],[/@id/,{cases:{"@keywords":{token:"keyword.$0"},"@stringOperators":{token:"operators"},"@default":{token:"identifier"}}}],[/[\[\]\(\)\{\}]/,{cases:{"\\[":{cases:{"$S2==gt":{token:"@brackets",next:e("@inParen__id__.gt")},"@default":{token:"@brackets",next:e("@inParen__id__.plain")}}},"\\]":{cases:{...n.id==="bracket"?{"$S2==interpolation":{token:"@brackets.interpolation",next:"@popall"}}:{},...t.id==="bracket"?{"$S2==directive":{token:"@brackets.directive",next:"@popall"}}:{},[e("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}},"\\(":{token:"@brackets",next:e("@inParen__id__.gt")},"\\)":{cases:{[e("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}},"\\{":{cases:{"$S2==gt":{token:"@brackets",next:e("@inParen__id__.gt")},"@default":{token:"@brackets",next:e("@inParen__id__.plain")}}},"\\}":{cases:{...n.id==="bracket"?{}:{"$S2==interpolation":{token:"@brackets.interpolation",next:"@popall"}},[e("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}}}}],[/\$\{/,{token:"delimiter.invalid"}]],[e("blank_and_expression_comment_token__id__")]:[[/(?:@blank)+/,{token:""}],[/[<\[][#!]--/,{token:"comment",next:e("@expressionComment__id__")}]],[e("directive_end_token__id__")]:[[/>/,t.id==="bracket"?{token:"operators"}:{token:"@brackets.directive",next:"@popall"}],[o(/(\/)(@close__id__)/),[{token:"delimiter.directive"},{token:"@brackets.directive",next:"@popall"}]]],[e("greater_operators_token__id__")]:[[/>/,{token:"operators"}],[/>=/,{token:"operators"}]],[e("no_space_expression_end_token__id__")]:[[/(?:@blank)+/,{token:"",switchTo:e("@fmExpression__id__.directive")}]],[e("unified_call_token__id__")]:[[/(@id)((?:@blank)+)/,[{token:"tag"},{token:"",next:e("@fmExpression__id__.directive")}]],[o(/(@id)(\/?)(@close__id__)/),[{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive",next:"@popall"}]],[/./,{token:"@rematch",next:e("@noSpaceExpression__id__")}]],[e("no_parse_token__id__")]:[[o(/(@open__id__)(\/#?)([a-zA-Z]+)((?:@blank)*)(@close__id__)/),{cases:{"$S2==$3":[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:""},{token:"@brackets.directive",next:"@popall"}],"$S2==comment":[{token:"comment"},{token:"comment"},{token:"comment"},{token:"comment"},{token:"comment"}],"@default":[{token:"source"},{token:"source"},{token:"source"},{token:"source"},{token:"source"}]}}],[/[^<\[\-]+|[<\[\-]/,{cases:{"$S2==comment":{token:"comment"},"@default":{token:"source"}}}]],[e("expression_comment_token__id__")]:[[/--[>\]]/,{token:"comment",next:"@pop"}],[/[^\->\]]+|[>\]\-]/,{token:"comment"}]],[e("terse_comment_token__id__")]:[[o(/--(?:@close__id__)/),{token:"comment",next:"@popall"}],[/[^<\[\-]+|[<\[\-]/,{token:"comment"}]]}}}function A(t){const n=_(r,t),i=_(a,t),e=_(F,t);return{...n,...i,...e,unicode:!0,includeLF:!1,start:`default_auto_${t.id}`,ignoreCase:!1,defaultToken:"invalid",tokenPostfix:".freemarker2",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{...n.tokenizer,...i.tokenizer,...e.tokenizer}}}const x={conf:l(r),language:_(r,k)},$={conf:l(a),language:_(a,k)},E={conf:l(r),language:_(r,p)},B={conf:l(a),language:_(a,p)},D={conf:g(),language:A(k)},C={conf:g(),language:A(p)};export{E as TagAngleInterpolationBracket,x as TagAngleInterpolationDollar,C as TagAutoInterpolationBracket,D as TagAutoInterpolationDollar,B as TagBracketInterpolationBracket,$ as TagBracketInterpolationDollar};
@@ -1 +1 @@
1
- import{l as e}from"./editor.api-B4g2PJYj.js";import"./index-CY45QPm-.js";const t=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],m={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["{{!--","--}}"]},brackets:[["<!--","-->"],["<",">"],["{{","}}"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${t.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/(\w[\w\d]*)\s*>$/i,action:{indentAction:e.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${t.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:e.IndentAction.Indent}}]},r={defaultToken:"",tokenPostfix:"",tokenizer:{root:[[/\{\{!--/,"comment.block.start.handlebars","@commentBlock"],[/\{\{!/,"comment.start.handlebars","@comment"],[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.root"}],[/<!DOCTYPE/,"metatag.html","@doctype"],[/<!--/,"comment.html","@commentHtml"],[/(<)(\w+)(\/>)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)(script)/,["delimiter.html",{token:"tag.html",next:"@script"}]],[/(<)(style)/,["delimiter.html",{token:"tag.html",next:"@style"}]],[/(<)([:\w]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)(\w+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/</,"delimiter.html"],[/\{/,"delimiter.html"],[/[^<{]+/]],doctype:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.comment"}],[/[^>]+/,"metatag.content.html"],[/>/,"metatag.html","@pop"]],comment:[[/\}\}/,"comment.end.handlebars","@pop"],[/./,"comment.content.handlebars"]],commentBlock:[[/--\}\}/,"comment.block.end.handlebars","@pop"],[/./,"comment.content.handlebars"]],commentHtml:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.comment"}],[/-->/,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.otherTag"}],[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.script"}],[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptAfterType"}],[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInEmbeddedState.scriptEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],style:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.style"}],[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleAfterType"}],[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInEmbeddedState.styleEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],handlebarsInSimpleState:[[/\{\{\{?/,"delimiter.handlebars"],[/\}\}\}?/,{token:"delimiter.handlebars",switchTo:"@$S2.$S3"}],{include:"handlebarsRoot"}],handlebarsInEmbeddedState:[[/\{\{\{?/,"delimiter.handlebars"],[/\}\}\}?/,{token:"delimiter.handlebars",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}],{include:"handlebarsRoot"}],handlebarsRoot:[[/"[^"]*"/,"string.handlebars"],[/[#/][^\s}]+/,"keyword.helper.handlebars"],[/else\b/,"keyword.helper.handlebars"],[/[\s]+/],[/[^}]/,"variable.parameter.handlebars"]]}};export{m as conf,r as language};
1
+ import{l as e}from"./editor.api-BWDeQ8t4.js";import"./index-DhcNqNgT.js";const t=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],m={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["{{!--","--}}"]},brackets:[["<!--","-->"],["<",">"],["{{","}}"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${t.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/(\w[\w\d]*)\s*>$/i,action:{indentAction:e.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${t.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:e.IndentAction.Indent}}]},r={defaultToken:"",tokenPostfix:"",tokenizer:{root:[[/\{\{!--/,"comment.block.start.handlebars","@commentBlock"],[/\{\{!/,"comment.start.handlebars","@comment"],[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.root"}],[/<!DOCTYPE/,"metatag.html","@doctype"],[/<!--/,"comment.html","@commentHtml"],[/(<)(\w+)(\/>)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)(script)/,["delimiter.html",{token:"tag.html",next:"@script"}]],[/(<)(style)/,["delimiter.html",{token:"tag.html",next:"@style"}]],[/(<)([:\w]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)(\w+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/</,"delimiter.html"],[/\{/,"delimiter.html"],[/[^<{]+/]],doctype:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.comment"}],[/[^>]+/,"metatag.content.html"],[/>/,"metatag.html","@pop"]],comment:[[/\}\}/,"comment.end.handlebars","@pop"],[/./,"comment.content.handlebars"]],commentBlock:[[/--\}\}/,"comment.block.end.handlebars","@pop"],[/./,"comment.content.handlebars"]],commentHtml:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.comment"}],[/-->/,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.otherTag"}],[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.script"}],[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptAfterType"}],[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInEmbeddedState.scriptEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],style:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.style"}],[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleAfterType"}],[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInEmbeddedState.styleEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],handlebarsInSimpleState:[[/\{\{\{?/,"delimiter.handlebars"],[/\}\}\}?/,{token:"delimiter.handlebars",switchTo:"@$S2.$S3"}],{include:"handlebarsRoot"}],handlebarsInEmbeddedState:[[/\{\{\{?/,"delimiter.handlebars"],[/\}\}\}?/,{token:"delimiter.handlebars",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}],{include:"handlebarsRoot"}],handlebarsRoot:[[/"[^"]*"/,"string.handlebars"],[/[#/][^\s}]+/,"keyword.helper.handlebars"],[/else\b/,"keyword.helper.handlebars"],[/[\s]+/],[/[^}]/,"variable.parameter.handlebars"]]}};export{m as conf,r as language};
@@ -1 +1 @@
1
- import{l as e}from"./editor.api-B4g2PJYj.js";import"./index-CY45QPm-.js";const t=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],r={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["<!--","-->"]},brackets:[["<!--","-->"],["<",">"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${t.join("|")}))([_:\\w][_:\\w-.\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/([_:\w][_:\w-.\d]*)\s*>$/i,action:{indentAction:e.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${t.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:e.IndentAction.Indent}}],folding:{markers:{start:new RegExp("^\\s*<!--\\s*#region\\b.*-->"),end:new RegExp("^\\s*<!--\\s*#endregion\\b.*-->")}}},o={defaultToken:"",tokenPostfix:".html",ignoreCase:!0,tokenizer:{root:[[/<!DOCTYPE/,"metatag","@doctype"],[/<!--/,"comment","@comment"],[/(<)((?:[\w\-]+:)?[\w\-]+)(\s*)(\/>)/,["delimiter","tag","","delimiter"]],[/(<)(script)/,["delimiter",{token:"tag",next:"@script"}]],[/(<)(style)/,["delimiter",{token:"tag",next:"@style"}]],[/(<)((?:[\w\-]+:)?[\w\-]+)/,["delimiter",{token:"tag",next:"@otherTag"}]],[/(<\/)((?:[\w\-]+:)?[\w\-]+)/,["delimiter",{token:"tag",next:"@otherTag"}]],[/</,"delimiter"],[/[^<]+/]],doctype:[[/[^>]+/,"metatag.content"],[/>/,"metatag","@pop"]],comment:[[/-->/,"comment","@pop"],[/[^-]+/,"comment.content"],[/./,"comment.content"]],otherTag:[[/\/?>/,"delimiter","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter","tag",{token:"delimiter",next:"@pop"}]]],scriptAfterType:[[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/"module"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.text/javascript"}],[/'module'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.text/javascript"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/>/,{token:"delimiter",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]],style:[[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter","tag",{token:"delimiter",next:"@pop"}]]],styleAfterType:[[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/>/,{token:"delimiter",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]]}};export{r as conf,o as language};
1
+ import{l as e}from"./editor.api-BWDeQ8t4.js";import"./index-DhcNqNgT.js";const t=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],r={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["<!--","-->"]},brackets:[["<!--","-->"],["<",">"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${t.join("|")}))([_:\\w][_:\\w-.\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/([_:\w][_:\w-.\d]*)\s*>$/i,action:{indentAction:e.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${t.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:e.IndentAction.Indent}}],folding:{markers:{start:new RegExp("^\\s*<!--\\s*#region\\b.*-->"),end:new RegExp("^\\s*<!--\\s*#endregion\\b.*-->")}}},o={defaultToken:"",tokenPostfix:".html",ignoreCase:!0,tokenizer:{root:[[/<!DOCTYPE/,"metatag","@doctype"],[/<!--/,"comment","@comment"],[/(<)((?:[\w\-]+:)?[\w\-]+)(\s*)(\/>)/,["delimiter","tag","","delimiter"]],[/(<)(script)/,["delimiter",{token:"tag",next:"@script"}]],[/(<)(style)/,["delimiter",{token:"tag",next:"@style"}]],[/(<)((?:[\w\-]+:)?[\w\-]+)/,["delimiter",{token:"tag",next:"@otherTag"}]],[/(<\/)((?:[\w\-]+:)?[\w\-]+)/,["delimiter",{token:"tag",next:"@otherTag"}]],[/</,"delimiter"],[/[^<]+/]],doctype:[[/[^>]+/,"metatag.content"],[/>/,"metatag","@pop"]],comment:[[/-->/,"comment","@pop"],[/[^-]+/,"comment.content"],[/./,"comment.content"]],otherTag:[[/\/?>/,"delimiter","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter","tag",{token:"delimiter",next:"@pop"}]]],scriptAfterType:[[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/"module"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.text/javascript"}],[/'module'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.text/javascript"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/>/,{token:"delimiter",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]],style:[[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter","tag",{token:"delimiter",next:"@pop"}]]],styleAfterType:[[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/>/,{token:"delimiter",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]]}};export{r as conf,o as language};
@@ -0,0 +1,3 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/typescript-DL3gRsAd.js","assets/index-DhcNqNgT.js","assets/index-BxUg93Np.css"])))=>i.map(i=>d[i]);
2
+ import{d as he,G as q,e as ve,z as ge,$ as ye,D as be,N as _e,C as Se,R as xe,l as Ee,n as $e,c as je,j as H,a as we,o as Fe,_ as U,f as P,E as X,h as C,i as Oe,w as k,k as Y,x as G,F as K,m as Q,p as Z,S as M,q as Re,A as ke,r as Ae,s as De,t as Te,u as Pe,v as Ce}from"./useFormField-BLbvmpme-Dwz_jyMW.js";import{i as F,Q as Me,p as A,X as Be,a as Ie,b as Ve,H as Le,c as We,r as Ne,s as ee,d as Je,l as ze,e as qe,f as He}from"./App-BupMDG_t.js";import{a as Ue,d as Xe,e as Ye,_ as Ge}from"./index-DhcNqNgT.js";import{c as te}from"./reformer-ui-kit-tUqYBSLv.js";import{r as Ke}from"./index-eRs9yupj.js";import{g as Qe}from"./boot-BCJd6Ujw.js";import"./load-QsSQTL2T.js";import"./index-CF7RI8Bt.js";function Ze(e,t){for(var r=0;r<t.length;r++){const o=t[r];if(typeof o!="string"&&!Array.isArray(o)){for(const n in o)if(n!=="default"&&!(n in e)){const i=Object.getOwnPropertyDescriptor(o,n);i&&Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:()=>o[n]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}const et=Object.freeze(Object.defineProperty({__proto__:null,apply:he,createFormValidation:q,cross:ve,defineValidationSchema:ge,each:ye,validate:be,validateAsync:_e,validateModel:Se,validateWhen:xe},Symbol.toStringTag,{value:"Module"})),tt=Object.freeze(Object.defineProperty({__proto__:null,Signal:Ee,batch:$e,computed:je,effect:H,signal:we,untracked:Fe},Symbol.toStringTag,{value:"Module"}));function rt(e){const t=A(e.component)?.arg;if(t==="FileUpload"||t==="FileUploadAvatar"||t==="Attachment")return null;if(t==="Checkbox"||t==="Switch"||t==="Toggle")return!1;if(t==="Slider"){const r=e.componentProps?.min;return typeof r=="number"?r:0}return e.componentProps?.type==="number"?null:""}function ot(e){const t=[],r=o=>{if(Me(o)){const n=A(o.array);n?.op==="model"&&t.push({path:n.arg,value:[]});return}if(Be(o)){const n=A(o.value);n?.op==="model"&&t.push({path:n.arg,value:rt(o)});return}if(Ie(o)){const n=o;n.children?.forEach(a=>F(a)&&r(a));const i=n.componentProps?.steps;Array.isArray(i)&&i.forEach(a=>F(a)&&r(a))}};return F(e.root)&&r(e.root),t}function nt(e){const t={};for(const{path:r,value:o}of e)it(t,r.split("."),o);return t}function it(e,t,r){let o=e;for(let i=0;i<t.length-1;i++){const a=t[i];(typeof o[a]!="object"||o[a]===null)&&(o[a]={}),o=o[a]}const n=t[t.length-1];n in o||(o[n]=r)}function v(e,t,r){for(const o of t){const n=e[o]?.[r];if(n!==void 0)return n}}const at=["model.ts","model.tsx"],O=["validation.ts"],st=["form.behavior.ts","form-behavior.ts","behavior.ts"],V=["renderer.behavior.ts","render-behavior.ts","ui.ts"],ct=["registry.ts","registry.tsx"],E=e=>typeof e=="function";function lt(e){const t={},r=v(e,at,"initialFormModel");r&&typeof r=="object"&&(t.initial=r);const o=v(e,O,"formValidation");o&&(t.validation=o);const n=v(e,O,"validationOptions");n&&typeof n=="object"&&(t.validationOptions=n);const i=v(e,O,"makeValidationConfig");!t.validation&&E(i)&&(t.makeValidationConfig=i);const a=v(e,st,"formBehavior");a&&(t.behavior=a);const l=v(e,V,"formRenderBehavior");E(l)&&(t.renderBehavior=l);const s=v(e,V,"createRenderBehavior");E(s)&&(t.renderBehaviorFactory=s);const c=v(e,ct,"createRegistry");return E(c)&&(t.createRegistry=c),t}function ft(e){const t=[];return e.initial&&t.push("model"),(e.validation||e.makeValidationConfig)&&t.push("validation"),e.behavior&&t.push("behavior"),(e.renderBehavior||e.renderBehaviorFactory)&&t.push("renderBehavior"),e.createRegistry&&t.push("registry"),t}function L(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function D(e,t){const r={...e};for(const[o,n]of Object.entries(t)){const i=r[o];r[o]=L(i)&&L(n)?D(i,n):n}return r}function Gt(e){const{schema:t,compiled:r,dataSources:o,modelOverride:n}=e,i=lt(r.modules),a=[...r.errors];let l=nt(ot(t));i.initial&&(l=D(l,i.initial)),n&&(l=D(l,n));const s=U(l);let c=Ve(t,o);if(i.createRegistry)try{c=Le(c,i.createRegistry())}catch(d){a.push({file:"registry.ts",phase:"evaluate",message:d instanceof Error?d.message:String(d)})}const{form:f}=We({schema:t,registry:c,model:s,behavior:i.behavior});let u=null,p=null,h=null;if(i.validation)try{u=q(s,i.validation,i.validationOptions),p=i.validationOptions?.strategy??"submit",h=()=>u.validate()}catch(d){a.push({file:"validation.ts",phase:"evaluate",message:d instanceof Error?d.message:String(d)})}else if(i.makeValidationConfig)try{const d=i.makeValidationConfig(s);h=()=>d.validateAll?.()??Promise.resolve(!0),a.push({file:"validation.ts",phase:"evaluate",message:"Экспортирован makeValidationConfig вместо formValidation — реактивная стратегия недоступна, валидацию можно запустить только вручную."})}catch(d){a.push({file:"validation.ts",phase:"evaluate",message:d instanceof Error?d.message:String(d)})}let w=i.renderBehavior;if(!w&&i.renderBehaviorFactory)try{w=i.renderBehaviorFactory(f,s)}catch(d){a.push({file:"renderer.behavior.ts",phase:"evaluate",message:d instanceof Error?d.message:String(d)})}return{registry:c,model:s,form:f,validation:u,strategy:p,validateAll:h,renderBehavior:w,applied:ft(i),errors:a}}function ut(e,t,r){const o={exports:{}},n=`${e}
3
+ //# sourceURL=reformer-builder:///${r}`;return new Function("exports","require","module","__filename",n)(o.exports,t,o,r),o.exports}var R={exports:{}},$={};var W;function dt(){if(W)return $;W=1;var e=Symbol.for("react.fragment");return $.Fragment=e,$.jsxDEV=void 0,$}var N;function mt(){return N||(N=1,R.exports=dt()),R.exports}var re=mt();const pt=Ue(re),ht=Ze({__proto__:null,default:pt},[re]);let S=null;function oe(e){if(!S)throw new Error(`[@reformer/core/behaviors] "${e}" вызван вне defineFormBehavior(...) — операторы поведения можно вызывать только внутри схемы.`);return S}function m(e){oe("onDispose").cleanups.push(e)}function _(){const e=oe("getScope");return{model:e.model,form:e.form}}function ne(e){return{__run(t,r){const o={cleanups:[],model:t,form:r},n=S;S=o;try{e({model:t,form:r})}finally{S=n}return()=>{for(const i of o.cleanups)i()}}}}function g(e){m(H(e))}function j(e){C(e)}const b=e=>typeof e=="object"&&e!==null&&typeof e.peek=="function"&&!Z(e),ie=e=>Array.isArray(e)?e:[e];function ae(e){const t={};for(const r of Object.keys(e)){const o=e[r];t[r]=b(o)?o.value:ae(o)}return t}function se(e,t){for(const r of Object.keys(e)){const o=e[r];b(o)?o.value=t?.[r]:se(o,t?.[r]??{})}}function ce(e){return t=>{try{t()}catch(r){if(r instanceof Error&&/cycle detected/i.test(r.message)){const o=e.__path??"?";throw new Error(`[@reformer/core/behaviors] compute("${o}"): расходящийся цикл пересчёта — взаимные compute/computeFrom без стабилизации. Проверьте зависимости или добавьте стабилизирующее условие (when) / разорвите цикл через peek.`)}throw r}}}function B(e,t){return t.split(".").reduce((r,o)=>r?.[o],e)}function vt(e){if(!e)return;const{form:t}=_();return t.getFieldByPath(e)}function gt(e,t,r){P(e),m(()=>M(e));const o=ce(e);g(()=>{if(r?.when&&!r.when())return;const n=t();e.peek()!==n&&o(()=>{e.value=n})})}function yt(e,t,r,o){P(t),m(()=>M(t));const n=ce(t);g(()=>{const i=e.map(l=>l.value);if(o?.when&&!o.when(...i))return;const a=r(...i);t.peek()!==a&&n(()=>{t.value=a})})}function bt(e,t,r){if(b(e)&&b(t)){m(X(e,t,r));return}const o=e,n=t;g(()=>{const i=ae(o);r?.when&&!r.when()||j(()=>se(n,i))})}function le(e,t,r){let o;const n=i=>{o?.abort(),o=new AbortController;const{signal:a}=o;C(()=>t(i,{signal:a}))};if(!r?.debounce)m(k(e,n,{immediate:r?.immediate}));else{let i;const a=k(e,l=>{i&&clearTimeout(i),i=setTimeout(()=>n(l),r.debounce)},{immediate:r?.immediate});m(()=>{i&&clearTimeout(i),a()})}m(()=>o?.abort())}function fe(e,t,r){for(const o of ie(e))b(o)?m(Oe(o,t,r)):St(o,t,r)}function _t(e,t,r){fe(e,()=>!t(),r)}function St(e,t,r){const o=vt(e.__path);o&&g(()=>{const n=t();j(()=>{n?o.enable():(o.disable(),r?.resetOnDisable&&o.reset())})})}function xt(e,t){m(Q(e,t))}function Et(e,t,r){m(Y(e,t,r))}function $t(e,t,r){m(K(e,t,r))}function jt(e,t){m(G(e,t))}function ue(e){return new Proxy({},{get:(t,r)=>{if(r==="$")return e;if(typeof r!="string")return;const o=e[r];if(o!=null)return b(o)?o.value:ue(o)}})}function wt(e){return new Proxy({},{get(t,r){if(!(typeof r=="symbol"||r==="then"))throw new Error(`[@reformer/core/behaviors] applyEach: форма строки массива "${e}" недоступна (form.${String(r)}) — массив не материализован в схеме формы. Per-row node-операции (enableWhen/updateComponentProps/reset) требуют узла { array, item } в схеме; value-операции (row.$.*: compute/copyFrom/transformValue) работают и без материализации.`)}})}function de(e,t){const{model:r,form:o}=_(),n=e.__path;if(!n)return;const i=B(r,n);if(!i)return;const a=o.getFieldByPath(n),l=a?.length,s=new Map;g(()=>{const c=l?l.value:i.length,f=new Set;for(let u=0;u<c;u++){const p=i.at(u);if(p!=null&&(f.add(p),!s.has(p))){const h=a?.at?.(u)??wt(n);s.set(p,t.__run(p,h))}}for(const[u,p]of s)f.has(u)||(p(),s.delete(u))}),m(()=>{for(const c of s.values())c();s.clear()})}function T(e){if(e==null||typeof e!="object")return;const t=e;if(typeof t.at=="function"&&typeof t.length=="number"){const r=t.length;for(let o=0;o<r;o++)T(t.at(o));return}for(const r of Object.keys(e))T(e[r])}function Ft(e,t){const{model:r}=_(),o=e.__path;if(!o)return;const n=B(r,o);n&&de(e,ne(({model:i})=>{le(t(i),a=>{if(a)for(let l=0;l<n.length;l++){const s=n.at(l);if(s&&s!==i){const c=t(s);c.peek()&&(c.value=!1)}}})}))}function Ot(e,t){const{model:r}=_(),o=e.__path;if(!o)return;const n=B(r,o);if(!n)return;let i=!1,a=0;g(()=>{T(n),!i&&(i=!0,j(()=>{i=!1;const l=t(n.toArray());let s=!1;for(const{index:c,patch:f}of l){const u=n.at(c);if(u)for(const[p,h]of Object.entries(f))u[p]!==h&&(u[p]=h,s=!0)}if(a=s?a+1:0,a>50)throw a=0,new Error(`[@reformer/core/behaviors] aggregateInto("${o}"): запись не сходится (>50 проходов) — derive должна быть идемпотентной на фикспоинте.`)}))})}function Rt(e,t){const{form:r}=_();for(const o of ie(e)){const n=o,i=n.__path;if(!i)continue;const a=r?r.getFieldByPath(i):void 0,l=a?a.getProxy?.()??a:void 0;m(t.__run(ue(n),l))}}const kt=Object.freeze(Object.defineProperty({__proto__:null,aggregateInto:Ot,apply:Rt,applyEach:de,compute:gt,computeFrom:yt,copyFrom:bt,defer:j,defineFormBehavior:ne,disableWhen:_t,effect:g,enableWhen:fe,exclusiveFlag:Ft,getScope:_,onChange:le,onDispose:m,resetWhen:Et,revalidateWhen:jt,syncFields:$t,transformValue:xt},Symbol.toStringTag,{value:"Module"})),At=Object.freeze(Object.defineProperty({__proto__:null,computeFrom:Re,copyFrom:X,createModel:U,eachLeafSignal:ke,isDerived:Ae,isModelContainerSignal:Z,markDerived:P,resetWhen:Y,revalidateWhen:G,runOutsideEffect:C,safeCallback:De,safeDebouncedCallback:Te,syncFields:K,transformValue:Q,unmarkDerived:M,watchField:k},Symbol.toStringTag,{value:"Module"})),I={react:Ye,"react/jsx-runtime":Xe,"react/jsx-dev-runtime":ht,"@preact/signals-core":Ce,"@reformer/core":Pe,"@reformer/core/behaviors":kt,"@reformer/core/model":At,"@reformer/core/signals":tt,"@reformer/core/validation":et,"@reformer/core/validators":te,"@reformer/renderer-json":Ne,"@reformer/renderer-react":Ke},x="@reformer/ui-kit",me="@reformer/core/validators/";function Dt(e){const t=I[e];if(t)return t;if(e.startsWith(me))return te;if(e===x||e.startsWith(`${x}/`))return Qe();throw new Error(`Импорт «${e}» недоступен в превью. Разрешены react, @preact/signals-core, @reformer/core (+ /behaviors, /validation, /validators, /signals, /model), @reformer/renderer-json, @reformer/renderer-react, @reformer/ui-kit и файлы каталога формы.`)}function Kt(e){return e in I||e.startsWith(me)?!0:e===x||e.startsWith(`${x}/`)}function Qt(){return[...Object.keys(I),x]}let J=null;async function Tt(){return J??=Ge(()=>import("./typescript-DL3gRsAd.js").then(e=>e.t),__vite__mapDeps([0,1,2])).then(e=>e.default??e),J}const y=new Map,Pt=64;function Ct(e,t){return`${e}\0${t}`}function Mt(e,t){if(y.size>=Pt){const r=y.keys().next().value;r!==void 0&&y.delete(r)}return y.set(e,t),t}async function Bt(e,t){const r=Ct(t,e),o=y.get(r);if(o!==void 0)return o;const n=await Tt(),i=n.transpileModule(e,{fileName:t,reportDiagnostics:!0,compilerOptions:{module:n.ModuleKind.CommonJS,target:n.ScriptTarget.ES2022,jsx:n.JsxEmit.ReactJSX,esModuleInterop:!0,allowJs:!0,isolatedModules:!0,useDefineForClassFields:!0}}),a=i.diagnostics?.[0];if(a){const l=n.flattenDiagnosticMessageText(a.messageText," "),s=a.file&&a.start!==void 0?(()=>{const{line:c,character:f}=a.file.getLineAndCharacterOfPosition(a.start);return`:${c+1}:${f+1}`})():"";throw new Error(`${t}${s} — ${l}`)}return Mt(r,i.outputText)}function Zt(){y.clear()}const It=[".ts",".tsx",""],Vt=["model.ts","validation.ts","form.behavior.ts","renderer.behavior.ts","registry.ts","form-behavior.ts","render-behavior.ts","behavior.ts","ui.ts"],z=e=>e instanceof Error?e.message:String(e);function Lt(e,t){const r=e.replace(/^\.\//,"");if(r.includes("/"))return null;for(const o of It){const n=`${r}${o}`;if(t.has(n))return n}return null}async function er(e){const t=[],r={};for(const[s,c]of Object.entries(e.files))try{r[s]=await Bt(c,s)}catch(f){t.push({file:s,phase:"transpile",message:z(f)})}const o=new Set(Object.keys(r)),n={},i=new Set,a=(s,c)=>{if(!c.startsWith("."))return Dt(c);const f=Lt(c,o);if(!f)throw new Error(`${s}: импорт «${c}» не найден среди файлов каталога формы`+(Object.keys(e.files).length?` (есть: ${Object.keys(e.files).join(", ")})`:""));return l(f)},l=s=>{const c=n[s];if(c)return c;if(i.has(s))throw new Error(`Циклический импорт: ${[...i,s].join(" → ")}`);i.add(s);try{const f=ut(r[s],u=>a(s,u),s);return n[s]=f,f}finally{i.delete(s)}};for(const s of Vt)if(!(!o.has(s)||n[s]))try{l(s)}catch(c){t.push({file:s,phase:"evaluate",message:z(c)})}return{modules:n,errors:t}}function pe(e){return!/\.tsx?$/.test(e)||e==="index.ts"||e==="index.tsx"?!1:!/\.(test|spec)\.tsx?$/.test(e)}function Wt(e){const t={};for(const r of Object.values(He.getState().tabs)){const o=r.source.path;if(r.kind!=="code"||typeof r.text!="string"||!o)continue;const{dirPath:n,base:i}=ee(o);n!==e||!pe(i)||(t[i]=r.text)}return t}async function tr(e){const t=ee(e).dirPath,r=Je.getState().dirHandle,o={};if(r){const i=(await ze(r,t)).filter(a=>!a.includes("/")&&pe(a));for(const a of i)try{o[a]=await qe(r,t?`${t}/${a}`:a)}catch{}}const n=Wt(t);return Object.assign(o,n),{dir:t,files:o,fromEditor:Object.keys(n)}}export{ft as appliedArtifacts,Gt as buildLivePreview,Kt as canResolveModule,er as compileForm,ut as evalCjsModule,lt as extractContract,Qt as knownModuleSpecifiers,tr as readFormSources,Zt as resetTranspileCache,Dt as resolveModule,Bt as transpileTs};
@@ -1,4 +1,4 @@
1
- import{r as c,e as tr,j as g,W as V}from"./index-CY45QPm-.js";import{v as yn,$ as Ks,z as Cn,A as Rm}from"./useFormField-BLbvmpme-BASGgtAT.js";const Mm=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Em=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,o)=>o?o.toUpperCase():n.toLowerCase()),Di=e=>{const t=Em(e);return t.charAt(0).toUpperCase()+t.slice(1)},Ol=(...e)=>e.filter((t,n,o)=>!!t&&t.trim()!==""&&o.indexOf(t)===n).join(" ").trim(),Pm=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};var _m={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const Dm=c.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:o,className:r="",children:s,iconNode:a,...i},l)=>c.createElement("svg",{ref:l,..._m,width:t,height:t,stroke:e,strokeWidth:o?Number(n)*24/Number(t):n,className:Ol("lucide",r),...!s&&!Pm(i)&&{"aria-hidden":"true"},...i},[...a.map(([u,d])=>c.createElement(u,d)),...Array.isArray(s)?s:[s]]));const Me=(e,t)=>{const n=c.forwardRef(({className:o,...r},s)=>c.createElement(Dm,{ref:s,iconNode:t,className:Ol(`lucide-${Mm(Di(e))}`,`lucide-${e}`,o),...r}));return n.displayName=Di(e),n};const Im=[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]],F_=Me("arrow-down",Im);const Tm=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],$_=Me("arrow-up",Tm);const Om=[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]],j_=Me("calendar",Om);const Am=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],L_=Me("check",Am);const Nm=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],W_=Me("chevron-down",Nm);const km=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],V_=Me("chevron-left",km);const Fm=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],B_=Me("chevron-right",Fm);const $m=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],H_=Me("chevron-up",$m);const jm=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],G_=Me("chevrons-up-down",jm);const Lm=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],z_=Me("circle",Lm);const Wm=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],Y_=Me("ellipsis",Wm);const Vm=[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],U_=Me("eye-off",Vm);const Bm=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],K_=Me("eye",Bm);const Hm=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],q_=Me("loader-circle",Hm);const Gm=[["path",{d:"M5 12h14",key:"1ays0h"}]],X_=Me("minus",Gm);const zm=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],Z_=Me("search",zm);const Ym=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Q_=Me("x",Ym);function Ii(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function dn(...e){return t=>{let n=!1;const o=e.map(r=>{const s=Ii(r,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let r=0;r<o.length;r++){const s=o[r];typeof s=="function"?s():Ii(e[r],null)}}}}function H(...e){return c.useCallback(dn(...e),e)}function _t(e){const t=c.forwardRef((n,o)=>{let{children:r,...s}=n,a=null,i=!1;const l=[];Ti(r)&&typeof wo=="function"&&(r=wo(r._payload)),c.Children.forEach(r,p=>{if(Zm(p)){i=!0;const m=p;let h="child"in m.props?m.props.child:m.props.children;Ti(h)&&typeof wo=="function"&&(h=wo(h._payload)),a=Km(m,h),l.push(a?.props?.children)}else l.push(p)}),a?a=c.cloneElement(a,void 0,l):!i&&c.Children.count(r)===1&&c.isValidElement(r)&&(a=r);const u=a?Xm(a):void 0,d=H(o,u);if(!a){if(r||r===0)throw new Error(i?th(e):eh(e));return r}const f=qm(s,a.props??{});return a.type!==c.Fragment&&(f.ref=o?d:u),c.cloneElement(a,f)});return t.displayName=`${e}.Slot`,t}var J_=_t("Slot"),Al=Symbol.for("radix.slottable");function Um(e){const t=n=>"child"in n?n.children(n.child):n.children;return t.displayName=`${e}.Slottable`,t.__radixId=Al,t}var Km=(e,t)=>{if("child"in e.props){const n=e.props.child;return c.isValidElement(n)?c.cloneElement(n,void 0,e.props.children(n.props.children)):null}return c.isValidElement(t)?t:null};function qm(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const l=s(...i);return r(...i),l}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Xm(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Zm(e){return c.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Al}var Qm=Symbol.for("react.lazy");function Ti(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===Qm&&"_payload"in e&&Jm(e._payload)}function Jm(e){return typeof e=="object"&&e!==null&&"then"in e}var eh=e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,th=e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,wo=tr[" use ".trim().toString()],nh=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],O=nh.reduce((e,t)=>{const n=_t(`Primitive.${t}`),o=c.forwardRef((r,s)=>{const{asChild:a,...i}=r,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),g.jsx(l,{...i,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function ko(e,t){e&&yn.flushSync(()=>e.dispatchEvent(t))}var Nl=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),oh="VisuallyHidden",kl=c.forwardRef((e,t)=>g.jsx(O.span,{...e,ref:t,style:{...Nl,...e.style}}));kl.displayName=oh;var Fl=kl;function ve(e,t=[]){let n=[];function o(s,a){const i=c.createContext(a);i.displayName=s+"Context";const l=n.length;n=[...n,a];const u=f=>{const{scope:p,children:m,...h}=f,v=p?.[e]?.[l]||i,y=c.useMemo(()=>h,Object.values(h));return g.jsx(v.Provider,{value:y,children:m})};u.displayName=s+"Provider";function d(f,p,m={}){const{optional:h=!1}=m,v=p?.[e]?.[l]||i,y=c.useContext(v);if(y)return y;if(a!==void 0)return a;if(!h)throw new Error(`\`${f}\` must be used within \`${s}\``)}return[u,d]}const r=()=>{const s=n.map(a=>c.createContext(a));return function(i){const l=i?.[e]||s;return c.useMemo(()=>({[`__scope${e}`]:{...i,[e]:l}}),[i,l])}};return r.scopeName=e,[o,rh(r,...t)]}function rh(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(s){const a=o.reduce((i,{useScope:l,scopeName:u})=>{const f=l(s)[`__scope${u}`];return{...i,...f}},{});return c.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Nt(e){const t=e+"CollectionProvider",[n,o]=ve(t),[r,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=v=>{const{scope:y,children:w}=v,S=c.useRef(null),C=c.useRef(new Map).current;return g.jsx(r,{scope:y,itemMap:C,collectionRef:S,children:w})};a.displayName=t;const i=e+"CollectionSlot",l=_t(i),u=c.forwardRef((v,y)=>{const{scope:w,children:S}=v,C=s(i,w),b=H(y,C.collectionRef);return g.jsx(l,{ref:b,children:S})});u.displayName=i;const d=e+"CollectionItemSlot",f="data-radix-collection-item",p=_t(d),m=c.forwardRef((v,y)=>{const{scope:w,children:S,...C}=v,b=c.useRef(null),x=H(y,b),R=s(d,w);return c.useEffect(()=>(R.itemMap.set(b,{ref:b,...C}),()=>void R.itemMap.delete(b))),g.jsx(p,{[f]:"",ref:x,children:S})});m.displayName=d;function h(v){const y=s(e+"CollectionConsumer",v);return c.useCallback(()=>{const S=y.collectionRef.current;if(!S)return[];const C=Array.from(S.querySelectorAll(`[${f}]`));return Array.from(y.itemMap.values()).sort((R,M)=>C.indexOf(R.ref.current)-C.indexOf(M.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:a,Slot:u,ItemSlot:m},h,o]}function E(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),n===!1||!r||!r.defaultPrevented)return t?.(r)}}var ye=globalThis?.document?c.useLayoutEffect:()=>{},sh=tr[" useInsertionEffect ".trim().toString()]||ye;function he({prop:e,defaultProp:t,onChange:n=()=>{},caller:o}){const[r,s,a]=ah({defaultProp:t,onChange:n}),i=e!==void 0,l=i?e:r;{const d=c.useRef(e!==void 0);c.useEffect(()=>{const f=d.current;f!==i&&console.warn(`${o} is changing from ${f?"controlled":"uncontrolled"} to ${i?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=i},[i,o])}const u=c.useCallback(d=>{if(i){const f=ih(d)?d(e):d;f!==e&&a.current?.(f)}else s(d)},[i,e,s,a]);return[l,u]}function ah({defaultProp:e,onChange:t}){const[n,o]=c.useState(e),r=c.useRef(n),s=c.useRef(t);return sh(()=>{s.current=t},[t]),c.useEffect(()=>{r.current!==n&&(s.current?.(n),r.current=n)},[n,r]),[n,o,s]}function ih(e){return typeof e=="function"}function lh(e,t){return c.useReducer((n,o)=>t[n][o]??n,e)}var ge=e=>{const{present:t,children:n}=e,o=ch(t),r=typeof n=="function"?n({present:o.isPresent}):c.Children.only(n),s=uh(o.ref,dh(r));return typeof n=="function"||o.isPresent?c.cloneElement(r,{ref:s}):null};ge.displayName="Presence";function ch(e){const[t,n]=c.useState(),o=c.useRef(null),r=c.useRef(e),s=c.useRef("none"),a=c.useRef(void 0),i=e?"mounted":"unmounted",[l,u]=lh(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return c.useEffect(()=>{l==="mounted"?(s.current=a.current??Dn(o.current),a.current=void 0):s.current="none"},[l]),ye(()=>{const d=o.current,f=r.current;if(f!==e){const m=s.current,h=Dn(d);e?(a.current=h,u("MOUNT")):h==="none"||d?.display==="none"?u("UNMOUNT"):u(f&&m!==h?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,u]),ye(()=>{if(t){let d;const f=t.ownerDocument.defaultView??window,p=h=>{const y=Dn(o.current).includes(CSS.escape(h.animationName));if(h.target===t&&y&&(u("ANIMATION_END"),!r.current)){const w=t.style.animationFillMode;t.style.animationFillMode="forwards",d=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=w)})}},m=h=>{h.target===t&&(s.current=Dn(o.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{f.clearTimeout(d),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(l),ref:c.useCallback(d=>{if(d){const f=getComputedStyle(d);o.current=f,a.current=Dn(f)}else o.current=null;n(d)},[])}}function Oi(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function uh(...e){const t=c.useRef(e);return t.current=e,c.useCallback(n=>{const o=t.current;let r=!1;const s=o.map(a=>{const i=Oi(a,n);return!r&&typeof i=="function"&&(r=!0),i});if(r)return()=>{for(let a=0;a<s.length;a++){const i=s[a];typeof i=="function"?i():Oi(o[a],null)}}},[])}function Dn(e){return e?.animationName||"none"}function dh(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var fh=tr[" useId ".trim().toString()]||(()=>{}),ph=0;function pe(e){const[t,n]=c.useState(fh());return ye(()=>{n(o=>o??String(ph++))},[e]),e||(t?`radix-${t}`:"")}var nr="Collapsible",[gh,$l]=ve(nr),[mh,qs]=gh(nr),jl=c.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:o,defaultOpen:r,disabled:s,onOpenChange:a,...i}=e,[l,u]=he({prop:o,defaultProp:r??!1,onChange:a,caller:nr});return g.jsx(mh,{scope:n,disabled:s,contentId:pe(),open:l,onOpenToggle:c.useCallback(()=>u(d=>!d),[u]),children:g.jsx(O.div,{"data-state":Zs(l),"data-disabled":s?"":void 0,...i,ref:t})})});jl.displayName=nr;var Ll="CollapsibleTrigger",Wl=c.forwardRef((e,t)=>{const{__scopeCollapsible:n,...o}=e,r=qs(Ll,n);return g.jsx(O.button,{type:"button","aria-controls":r.open?r.contentId:void 0,"aria-expanded":r.open||!1,"data-state":Zs(r.open),"data-disabled":r.disabled?"":void 0,disabled:r.disabled,...o,ref:t,onClick:E(e.onClick,r.onOpenToggle)})});Wl.displayName=Ll;var Xs="CollapsibleContent",Vl=c.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=qs(Xs,e.__scopeCollapsible);return g.jsx(ge,{present:n||r.open,children:({present:s})=>g.jsx(hh,{...o,ref:t,present:s})})});Vl.displayName=Xs;var hh=c.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:o,children:r,...s}=e,a=qs(Xs,n),[i,l]=c.useState(o),u=c.useRef(null),d=H(t,u),f=c.useRef(0),p=f.current,m=c.useRef(0),h=m.current,v=a.open||i,y=c.useRef(v),w=c.useRef(void 0);return c.useEffect(()=>{const S=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(S)},[]),ye(()=>{const S=u.current;if(S){w.current=w.current||{transitionDuration:S.style.transitionDuration,animationName:S.style.animationName},S.style.transitionDuration="0s",S.style.animationName="none";const C=S.getBoundingClientRect();f.current=C.height,m.current=C.width,y.current||(S.style.transitionDuration=w.current.transitionDuration,S.style.animationName=w.current.animationName),l(o)}},[a.open,o]),g.jsx(O.div,{"data-state":Zs(a.open),"data-disabled":a.disabled?"":void 0,id:a.contentId,hidden:!v,...s,ref:d,style:{"--radix-collapsible-content-height":p?`${p}px`:void 0,"--radix-collapsible-content-width":h?`${h}px`:void 0,...e.style},children:v&&r})});function Zs(e){return e?"open":"closed"}var vh=jl,wh=Wl,yh=Vl,Bl=c.createContext(void 0),e0=e=>{const{dir:t,children:n}=e;return g.jsx(Bl.Provider,{value:t,children:n})};function Qe(e){const t=c.useContext(Bl);return e||t||"ltr"}var Je="Accordion",Ch=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[Qs,Sh,bh]=Nt(Je),[or]=ve(Je,[bh,$l]),Js=$l(),Hl=c.forwardRef((e,t)=>{const{type:n,...o}=e,r=o,s=o;return g.jsx(Qs.Provider,{scope:e.__scopeAccordion,children:n==="multiple"?g.jsx(Eh,{...s,ref:t}):g.jsx(Mh,{...r,ref:t})})});Hl.displayName=Je;var[Gl,xh]=or(Je),[zl,Rh]=or(Je,{collapsible:!1}),Mh=c.forwardRef((e,t)=>{const{value:n,defaultValue:o,onValueChange:r=()=>{},collapsible:s=!1,...a}=e,[i,l]=he({prop:n,defaultProp:o??"",onChange:r,caller:Je});return g.jsx(Gl,{scope:e.__scopeAccordion,value:c.useMemo(()=>i?[i]:[],[i]),onItemOpen:l,onItemClose:c.useCallback(()=>s&&l(""),[s,l]),children:g.jsx(zl,{scope:e.__scopeAccordion,collapsible:s,children:g.jsx(Yl,{...a,ref:t})})})}),Eh=c.forwardRef((e,t)=>{const{value:n,defaultValue:o,onValueChange:r=()=>{},...s}=e,[a,i]=he({prop:n,defaultProp:o??[],onChange:r,caller:Je}),l=c.useCallback(d=>i((f=[])=>[...f,d]),[i]),u=c.useCallback(d=>i((f=[])=>f.filter(p=>p!==d)),[i]);return g.jsx(Gl,{scope:e.__scopeAccordion,value:a,onItemOpen:l,onItemClose:u,children:g.jsx(zl,{scope:e.__scopeAccordion,collapsible:!0,children:g.jsx(Yl,{...s,ref:t})})})}),[Ph,rr]=or(Je),Yl=c.forwardRef((e,t)=>{const{__scopeAccordion:n,disabled:o,dir:r,orientation:s="vertical",...a}=e,i=c.useRef(null),l=H(i,t),u=Sh(n),f=Qe(r)==="ltr",p=E(e.onKeyDown,m=>{if(!Ch.includes(m.key))return;const h=m.target,v=u().filter(I=>!I.ref.current?.disabled),y=v.findIndex(I=>I.ref.current===h),w=v.length;if(y===-1)return;m.preventDefault();let S=y;const C=0,b=w-1,x=()=>{S=y+1,S>b&&(S=C)},R=()=>{S=y-1,S<C&&(S=b)};switch(m.key){case"Home":S=C;break;case"End":S=b;break;case"ArrowRight":s==="horizontal"&&(f?x():R());break;case"ArrowDown":s==="vertical"&&x();break;case"ArrowLeft":s==="horizontal"&&(f?R():x());break;case"ArrowUp":s==="vertical"&&R();break}const M=S%w;v[M].ref.current?.focus()});return g.jsx(Ph,{scope:n,disabled:o,direction:r,orientation:s,children:g.jsx(Qs.Slot,{scope:n,children:g.jsx(O.div,{...a,"data-orientation":s,ref:l,onKeyDown:o?void 0:p})})})}),Fo="AccordionItem",[_h,ea]=or(Fo),Ul=c.forwardRef((e,t)=>{const{__scopeAccordion:n,value:o,...r}=e,s=rr(Fo,n),a=xh(Fo,n),i=Js(n),l=pe(),u=o&&a.value.includes(o)||!1,d=s.disabled||e.disabled;return g.jsx(_h,{scope:n,open:u,disabled:d,triggerId:l,children:g.jsx(vh,{"data-orientation":s.orientation,"data-state":Jl(u),...i,...r,ref:t,disabled:d,open:u,onOpenChange:f=>{f?a.onItemOpen(o):a.onItemClose(o)}})})});Ul.displayName=Fo;var Kl="AccordionHeader",ql=c.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=rr(Je,n),s=ea(Kl,n);return g.jsx(O.h3,{"data-orientation":r.orientation,"data-state":Jl(s.open),"data-disabled":s.disabled?"":void 0,...o,ref:t})});ql.displayName=Kl;var vs="AccordionTrigger",Xl=c.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=rr(Je,n),s=ea(vs,n),a=Rh(vs,n),i=Js(n);return g.jsx(Qs.ItemSlot,{scope:n,children:g.jsx(wh,{"aria-disabled":s.open&&!a.collapsible||void 0,"data-orientation":r.orientation,id:s.triggerId,...i,...o,ref:t})})});Xl.displayName=vs;var Zl="AccordionContent",Ql=c.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=rr(Je,n),s=ea(Zl,n),a=Js(n);return g.jsx(yh,{role:"region","aria-labelledby":s.triggerId,"data-orientation":r.orientation,...a,...o,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});Ql.displayName=Zl;function Jl(e){return e?"open":"closed"}var t0=Hl,n0=Ul,o0=ql,r0=Xl,s0=Ql;function de(e){const t=c.useRef(e);return c.useEffect(()=>{t.current=e}),c.useMemo(()=>((...n)=>t.current?.(...n)),[])}var Dh="DismissableLayer",ws="dismissableLayer.update",Ih="dismissableLayer.pointerDownOutside",Th="dismissableLayer.focusOutside",Ai,ta=c.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),kt=c.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,deferPointerDownOutside:o=!1,onEscapeKeyDown:r,onPointerDownOutside:s,onFocusOutside:a,onInteractOutside:i,onDismiss:l,...u}=e,d=c.useContext(ta),[f,p]=c.useState(null),m=f?.ownerDocument??globalThis?.document,[,h]=c.useState({}),v=H(t,p),y=Array.from(d.layers),[w]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),S=w?y.indexOf(w):-1,C=f?y.indexOf(f):-1,b=d.layersWithOutsidePointerEventsDisabled.size>0,x=C>=S,R=c.useRef(!1),M=Fh(D=>{s?.(D),i?.(D),D.defaultPrevented||l?.()},{ownerDocument:m,deferPointerDownOutside:o,isDeferredPointerDownOutsideRef:R,dismissableSurfaces:d.dismissableSurfaces,shouldHandlePointerDownOutside:c.useCallback(D=>{if(!(D instanceof Node))return!1;const N=[...d.branches].some(k=>k.contains(D));return x&&!N},[d.branches,x])}),I=$h(D=>{if(o&&R.current)return;const N=D.target;[...d.branches].some(B=>B.contains(N))||(a?.(D),i?.(D),D.defaultPrevented||l?.())},m),_=f?C===y.length-1:!1,T=de(D=>{D.key==="Escape"&&(r?.(D),!D.defaultPrevented&&l&&(D.preventDefault(),l()))});return c.useEffect(()=>{if(_)return m.addEventListener("keydown",T,{capture:!0}),()=>m.removeEventListener("keydown",T,{capture:!0})},[m,_,T]),c.useEffect(()=>{if(f)return n&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(Ai=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),Ni(),()=>{n&&(d.layersWithOutsidePointerEventsDisabled.delete(f),d.layersWithOutsidePointerEventsDisabled.size===0&&(m.body.style.pointerEvents=Ai))}},[f,m,n,d]),c.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),Ni())},[f,d]),c.useEffect(()=>{const D=()=>h({});return document.addEventListener(ws,D),()=>document.removeEventListener(ws,D)},[]),g.jsx(O.div,{...u,ref:v,style:{pointerEvents:b?x?"auto":"none":void 0,...e.style},onFocusCapture:E(e.onFocusCapture,I.onFocusCapture),onBlurCapture:E(e.onBlurCapture,I.onBlurCapture),onPointerDownCapture:E(e.onPointerDownCapture,M.onPointerDownCapture)})});kt.displayName=Dh;var Oh="DismissableLayerBranch",Ah=c.forwardRef((e,t)=>{const n=c.useContext(ta),o=c.useRef(null),r=H(t,o);return c.useEffect(()=>{const s=o.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),g.jsx(O.div,{...e,ref:r})});Ah.displayName=Oh;function Nh(){const e=c.useContext(ta),[t,n]=c.useState(null);return c.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),n}var kh=()=>!0;function Fh(e,t){const{ownerDocument:n=globalThis?.document,deferPointerDownOutside:o=!1,isDeferredPointerDownOutsideRef:r,dismissableSurfaces:s,shouldHandlePointerDownOutside:a=kh}=t,i=de(e),l=c.useRef(!1),u=c.useRef(!1),d=c.useRef(new Map),f=c.useRef(()=>{});return c.useEffect(()=>{function p(){u.current=!1,r.current=!1,d.current.clear()}function m(){return Array.from(d.current.values()).some(Boolean)}function h(C){if(!u.current)return;const b=C.target;b instanceof Node&&[...s].some(R=>R.contains(b))||d.current.set(C.type,!0),C.type==="click"&&window.setTimeout(()=>{u.current&&f.current()},0)}function v(C){u.current&&d.current.set(C.type,!1)}const y=C=>{if(C.target&&!l.current){let b=function(){n.removeEventListener("click",f.current);const R=m();p(),R||ec(Ih,i,x,{discrete:!0})};if(!a(C.target)){n.removeEventListener("click",f.current),p(),l.current=!1;return}const x={originalEvent:C};u.current=!0,r.current=o&&C.button===0,d.current.clear(),!o||C.button!==0?b():(n.removeEventListener("click",f.current),f.current=b,n.addEventListener("click",f.current,{once:!0}))}else n.removeEventListener("click",f.current),p();l.current=!1},w=["pointerup","mousedown","mouseup","touchstart","touchend","click"];for(const C of w)n.addEventListener(C,h,!0),n.addEventListener(C,v);const S=window.setTimeout(()=>{n.addEventListener("pointerdown",y)},0);return()=>{window.clearTimeout(S),n.removeEventListener("pointerdown",y),n.removeEventListener("click",f.current);for(const C of w)n.removeEventListener(C,h,!0),n.removeEventListener(C,v)}},[n,i,o,r,s,a]),{onPointerDownCapture:()=>l.current=!0}}function $h(e,t=globalThis?.document){const n=de(e),o=c.useRef(!1);return c.useEffect(()=>{const r=s=>{s.target&&!o.current&&ec(Th,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",r),()=>t.removeEventListener("focusin",r)},[t,n]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}function Ni(){const e=new CustomEvent(ws);document.dispatchEvent(e)}function ec(e,t,n,{discrete:o}){const r=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&r.addEventListener(e,t,{once:!0}),o?ko(r,s):r.dispatchEvent(s)}var zr="focusScope.autoFocusOnMount",Yr="focusScope.autoFocusOnUnmount",ki={bubbles:!1,cancelable:!0},jh="FocusScope",Kn=c.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:s,...a}=e,[i,l]=c.useState(null),u=de(r),d=de(s),f=c.useRef(null),p=H(t,l),m=c.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;c.useEffect(()=>{if(o){let v=function(C){if(m.paused||!i)return;const b=C.target;i.contains(b)?f.current=b:Mt(f.current,{select:!0})},y=function(C){if(m.paused||!i)return;const b=C.relatedTarget;b!==null&&(i.contains(b)||Mt(f.current,{select:!0}))},w=function(C){if(document.activeElement===document.body)for(const x of C)x.removedNodes.length>0&&Mt(i)};document.addEventListener("focusin",v),document.addEventListener("focusout",y);const S=new MutationObserver(w);return i&&S.observe(i,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",v),document.removeEventListener("focusout",y),S.disconnect()}}},[o,i,m.paused]),c.useEffect(()=>{if(i){$i.add(m);const v=document.activeElement;if(!i.contains(v)){const w=new CustomEvent(zr,ki);i.addEventListener(zr,u),i.dispatchEvent(w),w.defaultPrevented||(Lh(Gh(tc(i)),{select:!0}),document.activeElement===v&&Mt(i))}return()=>{i.removeEventListener(zr,u),setTimeout(()=>{const w=new CustomEvent(Yr,ki);i.addEventListener(Yr,d),i.dispatchEvent(w),w.defaultPrevented||Mt(v??document.body,{select:!0}),i.removeEventListener(Yr,d),$i.remove(m)},0)}}},[i,u,d,m]);const h=c.useCallback(v=>{if(!n&&!o||m.paused)return;const y=v.key==="Tab"&&!v.altKey&&!v.ctrlKey&&!v.metaKey,w=document.activeElement;if(y&&w){const S=v.currentTarget,[C,b]=Wh(S);C&&b?!v.shiftKey&&w===b?(v.preventDefault(),n&&Mt(C,{select:!0})):v.shiftKey&&w===C&&(v.preventDefault(),n&&Mt(b,{select:!0})):w===S&&v.preventDefault()}},[n,o,m.paused]);return g.jsx(O.div,{tabIndex:-1,...a,ref:p,onKeyDown:h})});Kn.displayName=jh;function Lh(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if(Mt(o,{select:t}),document.activeElement!==n)return}function Wh(e){const t=tc(e),n=Fi(t,e),o=Fi(t.reverse(),e);return[n,o]}function tc(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:o=>{const r=o.tagName==="INPUT"&&o.type==="hidden";return o.disabled||o.hidden||r?NodeFilter.FILTER_SKIP:o.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Fi(e,t){const n=typeof t.checkVisibility=="function"&&t.checkVisibility({checkVisibilityCSS:!0});for(const o of e)if(!(n?!o.checkVisibility({checkVisibilityCSS:!0}):Vh(o,{upTo:t})))return o}function Vh(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Bh(e){return e instanceof HTMLInputElement&&"select"in e}function Mt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Bh(e)&&t&&e.select()}}var $i=Hh();function Hh(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=ji(e,t),e.unshift(t)},remove(t){e=ji(e,t),e[0]?.resume()}}}function ji(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function Gh(e){return e.filter(t=>t.tagName!=="A")}var zh="Portal",Yt=c.forwardRef((e,t)=>{const{container:n,...o}=e,[r,s]=c.useState(!1);ye(()=>s(!0),[]);const a=n||r&&globalThis?.document?.body;return a?yn.createPortal(g.jsx(O.div,{...o,ref:t}),a):null});Yt.displayName=zh;var yo=0,Jt=null;function sr(){c.useEffect(()=>{Jt||(Jt={start:Li(),end:Li()});const{start:e,end:t}=Jt;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement("afterbegin",e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement("beforeend",t),yo++,()=>{yo===1&&(Jt?.start.remove(),Jt?.end.remove(),Jt=null),yo=Math.max(0,yo-1)}},[])}function Li(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var st=function(){return st=Object.assign||function(t){for(var n,o=1,r=arguments.length;o<r;o++){n=arguments[o];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},st.apply(this,arguments)};function nc(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var r=0,o=Object.getOwnPropertySymbols(e);r<o.length;r++)t.indexOf(o[r])<0&&Object.prototype.propertyIsEnumerable.call(e,o[r])&&(n[o[r]]=e[o[r]]);return n}function Yh(e,t,n){if(n||arguments.length===2)for(var o=0,r=t.length,s;o<r;o++)(s||!(o in t))&&(s||(s=Array.prototype.slice.call(t,0,o)),s[o]=t[o]);return e.concat(s||Array.prototype.slice.call(t))}var Do="right-scroll-bar-position",Io="width-before-scroll-bar",Uh="with-scroll-bars-hidden",Kh="--removed-body-scroll-bar-size";function Ur(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function qh(e,t){var n=c.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(o){var r=n.value;r!==o&&(n.value=o,n.callback(o,r))}}}})[0];return n.callback=t,n.facade}var Xh=typeof window<"u"?c.useLayoutEffect:c.useEffect,Wi=new WeakMap;function Zh(e,t){var n=qh(null,function(o){return e.forEach(function(r){return Ur(r,o)})});return Xh(function(){var o=Wi.get(n);if(o){var r=new Set(o),s=new Set(e),a=n.current;r.forEach(function(i){s.has(i)||Ur(i,null)}),s.forEach(function(i){r.has(i)||Ur(i,a)})}Wi.set(n,e)},[e]),n}function Qh(e){return e}function Jh(e,t){t===void 0&&(t=Qh);var n=[],o=!1,r={read:function(){if(o)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var a=t(s,o);return n.push(a),function(){n=n.filter(function(i){return i!==a})}},assignSyncMedium:function(s){for(o=!0;n.length;){var a=n;n=[],a.forEach(s)}n={push:function(i){return s(i)},filter:function(){return n}}},assignMedium:function(s){o=!0;var a=[];if(n.length){var i=n;n=[],i.forEach(s),a=n}var l=function(){var d=a;a=[],d.forEach(s)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(d){a.push(d),u()},filter:function(d){return a=a.filter(d),n}}}};return r}function ev(e){e===void 0&&(e={});var t=Jh(null);return t.options=st({async:!0,ssr:!1},e),t}var oc=function(e){var t=e.sideCar,n=nc(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var o=t.read();if(!o)throw new Error("Sidecar medium not found");return c.createElement(o,st({},n))};oc.isSideCarExport=!0;function tv(e,t){return e.useMedium(t),oc}var rc=ev(),Kr=function(){},ar=c.forwardRef(function(e,t){var n=c.useRef(null),o=c.useState({onScrollCapture:Kr,onWheelCapture:Kr,onTouchMoveCapture:Kr}),r=o[0],s=o[1],a=e.forwardProps,i=e.children,l=e.className,u=e.removeScrollBar,d=e.enabled,f=e.shards,p=e.sideCar,m=e.noRelative,h=e.noIsolation,v=e.inert,y=e.allowPinchZoom,w=e.as,S=w===void 0?"div":w,C=e.gapMode,b=nc(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),x=p,R=Zh([n,t]),M=st(st({},b),r);return c.createElement(c.Fragment,null,d&&c.createElement(x,{sideCar:rc,removeScrollBar:u,shards:f,noRelative:m,noIsolation:h,inert:v,setCallbacks:s,allowPinchZoom:!!y,lockRef:n,gapMode:C}),a?c.cloneElement(c.Children.only(i),st(st({},M),{ref:R})):c.createElement(S,st({},M,{className:l,ref:R}),i))});ar.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};ar.classNames={fullWidth:Io,zeroRight:Do};var nv=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function ov(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=nv();return t&&e.setAttribute("nonce",t),e}function rv(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function sv(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var av=function(){var e=0,t=null;return{add:function(n){e==0&&(t=ov())&&(rv(t,n),sv(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},iv=function(){var e=av();return function(t,n){c.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},sc=function(){var e=iv(),t=function(n){var o=n.styles,r=n.dynamic;return e(o,r),null};return t},lv={left:0,top:0,right:0,gap:0},qr=function(e){return parseInt(e||"",10)||0},cv=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],o=t[e==="padding"?"paddingTop":"marginTop"],r=t[e==="padding"?"paddingRight":"marginRight"];return[qr(n),qr(o),qr(r)]},uv=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return lv;var t=cv(e),n=document.documentElement.clientWidth,o=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,o-n+t[2]-t[0])}},dv=sc(),cn="data-scroll-locked",fv=function(e,t,n,o){var r=e.left,s=e.top,a=e.right,i=e.gap;return n===void 0&&(n="margin"),`
1
+ import{r as c,e as tr,j as g,W as V}from"./index-DhcNqNgT.js";import{L as yn,H as Ks,M as Cn,O as Rm}from"./useFormField-BLbvmpme-Dwz_jyMW.js";const Mm=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Em=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,o)=>o?o.toUpperCase():n.toLowerCase()),Di=e=>{const t=Em(e);return t.charAt(0).toUpperCase()+t.slice(1)},Ol=(...e)=>e.filter((t,n,o)=>!!t&&t.trim()!==""&&o.indexOf(t)===n).join(" ").trim(),Pm=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};var _m={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const Dm=c.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:o,className:r="",children:s,iconNode:a,...i},l)=>c.createElement("svg",{ref:l,..._m,width:t,height:t,stroke:e,strokeWidth:o?Number(n)*24/Number(t):n,className:Ol("lucide",r),...!s&&!Pm(i)&&{"aria-hidden":"true"},...i},[...a.map(([u,d])=>c.createElement(u,d)),...Array.isArray(s)?s:[s]]));const Me=(e,t)=>{const n=c.forwardRef(({className:o,...r},s)=>c.createElement(Dm,{ref:s,iconNode:t,className:Ol(`lucide-${Mm(Di(e))}`,`lucide-${e}`,o),...r}));return n.displayName=Di(e),n};const Im=[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]],F_=Me("arrow-down",Im);const Tm=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],$_=Me("arrow-up",Tm);const Om=[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]],j_=Me("calendar",Om);const Am=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],L_=Me("check",Am);const Nm=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],W_=Me("chevron-down",Nm);const km=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],V_=Me("chevron-left",km);const Fm=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],B_=Me("chevron-right",Fm);const $m=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],H_=Me("chevron-up",$m);const jm=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],G_=Me("chevrons-up-down",jm);const Lm=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],z_=Me("circle",Lm);const Wm=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],Y_=Me("ellipsis",Wm);const Vm=[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],U_=Me("eye-off",Vm);const Bm=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],K_=Me("eye",Bm);const Hm=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],q_=Me("loader-circle",Hm);const Gm=[["path",{d:"M5 12h14",key:"1ays0h"}]],X_=Me("minus",Gm);const zm=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],Z_=Me("search",zm);const Ym=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Q_=Me("x",Ym);function Ii(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function dn(...e){return t=>{let n=!1;const o=e.map(r=>{const s=Ii(r,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let r=0;r<o.length;r++){const s=o[r];typeof s=="function"?s():Ii(e[r],null)}}}}function H(...e){return c.useCallback(dn(...e),e)}function _t(e){const t=c.forwardRef((n,o)=>{let{children:r,...s}=n,a=null,i=!1;const l=[];Ti(r)&&typeof wo=="function"&&(r=wo(r._payload)),c.Children.forEach(r,p=>{if(Zm(p)){i=!0;const m=p;let h="child"in m.props?m.props.child:m.props.children;Ti(h)&&typeof wo=="function"&&(h=wo(h._payload)),a=Km(m,h),l.push(a?.props?.children)}else l.push(p)}),a?a=c.cloneElement(a,void 0,l):!i&&c.Children.count(r)===1&&c.isValidElement(r)&&(a=r);const u=a?Xm(a):void 0,d=H(o,u);if(!a){if(r||r===0)throw new Error(i?th(e):eh(e));return r}const f=qm(s,a.props??{});return a.type!==c.Fragment&&(f.ref=o?d:u),c.cloneElement(a,f)});return t.displayName=`${e}.Slot`,t}var J_=_t("Slot"),Al=Symbol.for("radix.slottable");function Um(e){const t=n=>"child"in n?n.children(n.child):n.children;return t.displayName=`${e}.Slottable`,t.__radixId=Al,t}var Km=(e,t)=>{if("child"in e.props){const n=e.props.child;return c.isValidElement(n)?c.cloneElement(n,void 0,e.props.children(n.props.children)):null}return c.isValidElement(t)?t:null};function qm(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const l=s(...i);return r(...i),l}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Xm(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Zm(e){return c.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Al}var Qm=Symbol.for("react.lazy");function Ti(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===Qm&&"_payload"in e&&Jm(e._payload)}function Jm(e){return typeof e=="object"&&e!==null&&"then"in e}var eh=e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,th=e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,wo=tr[" use ".trim().toString()],nh=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],O=nh.reduce((e,t)=>{const n=_t(`Primitive.${t}`),o=c.forwardRef((r,s)=>{const{asChild:a,...i}=r,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),g.jsx(l,{...i,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function ko(e,t){e&&yn.flushSync(()=>e.dispatchEvent(t))}var Nl=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),oh="VisuallyHidden",kl=c.forwardRef((e,t)=>g.jsx(O.span,{...e,ref:t,style:{...Nl,...e.style}}));kl.displayName=oh;var Fl=kl;function ve(e,t=[]){let n=[];function o(s,a){const i=c.createContext(a);i.displayName=s+"Context";const l=n.length;n=[...n,a];const u=f=>{const{scope:p,children:m,...h}=f,v=p?.[e]?.[l]||i,y=c.useMemo(()=>h,Object.values(h));return g.jsx(v.Provider,{value:y,children:m})};u.displayName=s+"Provider";function d(f,p,m={}){const{optional:h=!1}=m,v=p?.[e]?.[l]||i,y=c.useContext(v);if(y)return y;if(a!==void 0)return a;if(!h)throw new Error(`\`${f}\` must be used within \`${s}\``)}return[u,d]}const r=()=>{const s=n.map(a=>c.createContext(a));return function(i){const l=i?.[e]||s;return c.useMemo(()=>({[`__scope${e}`]:{...i,[e]:l}}),[i,l])}};return r.scopeName=e,[o,rh(r,...t)]}function rh(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(s){const a=o.reduce((i,{useScope:l,scopeName:u})=>{const f=l(s)[`__scope${u}`];return{...i,...f}},{});return c.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Nt(e){const t=e+"CollectionProvider",[n,o]=ve(t),[r,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=v=>{const{scope:y,children:w}=v,S=c.useRef(null),C=c.useRef(new Map).current;return g.jsx(r,{scope:y,itemMap:C,collectionRef:S,children:w})};a.displayName=t;const i=e+"CollectionSlot",l=_t(i),u=c.forwardRef((v,y)=>{const{scope:w,children:S}=v,C=s(i,w),b=H(y,C.collectionRef);return g.jsx(l,{ref:b,children:S})});u.displayName=i;const d=e+"CollectionItemSlot",f="data-radix-collection-item",p=_t(d),m=c.forwardRef((v,y)=>{const{scope:w,children:S,...C}=v,b=c.useRef(null),x=H(y,b),R=s(d,w);return c.useEffect(()=>(R.itemMap.set(b,{ref:b,...C}),()=>void R.itemMap.delete(b))),g.jsx(p,{[f]:"",ref:x,children:S})});m.displayName=d;function h(v){const y=s(e+"CollectionConsumer",v);return c.useCallback(()=>{const S=y.collectionRef.current;if(!S)return[];const C=Array.from(S.querySelectorAll(`[${f}]`));return Array.from(y.itemMap.values()).sort((R,M)=>C.indexOf(R.ref.current)-C.indexOf(M.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:a,Slot:u,ItemSlot:m},h,o]}function E(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),n===!1||!r||!r.defaultPrevented)return t?.(r)}}var ye=globalThis?.document?c.useLayoutEffect:()=>{},sh=tr[" useInsertionEffect ".trim().toString()]||ye;function he({prop:e,defaultProp:t,onChange:n=()=>{},caller:o}){const[r,s,a]=ah({defaultProp:t,onChange:n}),i=e!==void 0,l=i?e:r;{const d=c.useRef(e!==void 0);c.useEffect(()=>{const f=d.current;f!==i&&console.warn(`${o} is changing from ${f?"controlled":"uncontrolled"} to ${i?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=i},[i,o])}const u=c.useCallback(d=>{if(i){const f=ih(d)?d(e):d;f!==e&&a.current?.(f)}else s(d)},[i,e,s,a]);return[l,u]}function ah({defaultProp:e,onChange:t}){const[n,o]=c.useState(e),r=c.useRef(n),s=c.useRef(t);return sh(()=>{s.current=t},[t]),c.useEffect(()=>{r.current!==n&&(s.current?.(n),r.current=n)},[n,r]),[n,o,s]}function ih(e){return typeof e=="function"}function lh(e,t){return c.useReducer((n,o)=>t[n][o]??n,e)}var ge=e=>{const{present:t,children:n}=e,o=ch(t),r=typeof n=="function"?n({present:o.isPresent}):c.Children.only(n),s=uh(o.ref,dh(r));return typeof n=="function"||o.isPresent?c.cloneElement(r,{ref:s}):null};ge.displayName="Presence";function ch(e){const[t,n]=c.useState(),o=c.useRef(null),r=c.useRef(e),s=c.useRef("none"),a=c.useRef(void 0),i=e?"mounted":"unmounted",[l,u]=lh(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return c.useEffect(()=>{l==="mounted"?(s.current=a.current??Dn(o.current),a.current=void 0):s.current="none"},[l]),ye(()=>{const d=o.current,f=r.current;if(f!==e){const m=s.current,h=Dn(d);e?(a.current=h,u("MOUNT")):h==="none"||d?.display==="none"?u("UNMOUNT"):u(f&&m!==h?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,u]),ye(()=>{if(t){let d;const f=t.ownerDocument.defaultView??window,p=h=>{const y=Dn(o.current).includes(CSS.escape(h.animationName));if(h.target===t&&y&&(u("ANIMATION_END"),!r.current)){const w=t.style.animationFillMode;t.style.animationFillMode="forwards",d=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=w)})}},m=h=>{h.target===t&&(s.current=Dn(o.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{f.clearTimeout(d),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(l),ref:c.useCallback(d=>{if(d){const f=getComputedStyle(d);o.current=f,a.current=Dn(f)}else o.current=null;n(d)},[])}}function Oi(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function uh(...e){const t=c.useRef(e);return t.current=e,c.useCallback(n=>{const o=t.current;let r=!1;const s=o.map(a=>{const i=Oi(a,n);return!r&&typeof i=="function"&&(r=!0),i});if(r)return()=>{for(let a=0;a<s.length;a++){const i=s[a];typeof i=="function"?i():Oi(o[a],null)}}},[])}function Dn(e){return e?.animationName||"none"}function dh(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var fh=tr[" useId ".trim().toString()]||(()=>{}),ph=0;function pe(e){const[t,n]=c.useState(fh());return ye(()=>{n(o=>o??String(ph++))},[e]),e||(t?`radix-${t}`:"")}var nr="Collapsible",[gh,$l]=ve(nr),[mh,qs]=gh(nr),jl=c.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:o,defaultOpen:r,disabled:s,onOpenChange:a,...i}=e,[l,u]=he({prop:o,defaultProp:r??!1,onChange:a,caller:nr});return g.jsx(mh,{scope:n,disabled:s,contentId:pe(),open:l,onOpenToggle:c.useCallback(()=>u(d=>!d),[u]),children:g.jsx(O.div,{"data-state":Zs(l),"data-disabled":s?"":void 0,...i,ref:t})})});jl.displayName=nr;var Ll="CollapsibleTrigger",Wl=c.forwardRef((e,t)=>{const{__scopeCollapsible:n,...o}=e,r=qs(Ll,n);return g.jsx(O.button,{type:"button","aria-controls":r.open?r.contentId:void 0,"aria-expanded":r.open||!1,"data-state":Zs(r.open),"data-disabled":r.disabled?"":void 0,disabled:r.disabled,...o,ref:t,onClick:E(e.onClick,r.onOpenToggle)})});Wl.displayName=Ll;var Xs="CollapsibleContent",Vl=c.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=qs(Xs,e.__scopeCollapsible);return g.jsx(ge,{present:n||r.open,children:({present:s})=>g.jsx(hh,{...o,ref:t,present:s})})});Vl.displayName=Xs;var hh=c.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:o,children:r,...s}=e,a=qs(Xs,n),[i,l]=c.useState(o),u=c.useRef(null),d=H(t,u),f=c.useRef(0),p=f.current,m=c.useRef(0),h=m.current,v=a.open||i,y=c.useRef(v),w=c.useRef(void 0);return c.useEffect(()=>{const S=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(S)},[]),ye(()=>{const S=u.current;if(S){w.current=w.current||{transitionDuration:S.style.transitionDuration,animationName:S.style.animationName},S.style.transitionDuration="0s",S.style.animationName="none";const C=S.getBoundingClientRect();f.current=C.height,m.current=C.width,y.current||(S.style.transitionDuration=w.current.transitionDuration,S.style.animationName=w.current.animationName),l(o)}},[a.open,o]),g.jsx(O.div,{"data-state":Zs(a.open),"data-disabled":a.disabled?"":void 0,id:a.contentId,hidden:!v,...s,ref:d,style:{"--radix-collapsible-content-height":p?`${p}px`:void 0,"--radix-collapsible-content-width":h?`${h}px`:void 0,...e.style},children:v&&r})});function Zs(e){return e?"open":"closed"}var vh=jl,wh=Wl,yh=Vl,Bl=c.createContext(void 0),e0=e=>{const{dir:t,children:n}=e;return g.jsx(Bl.Provider,{value:t,children:n})};function Qe(e){const t=c.useContext(Bl);return e||t||"ltr"}var Je="Accordion",Ch=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[Qs,Sh,bh]=Nt(Je),[or]=ve(Je,[bh,$l]),Js=$l(),Hl=c.forwardRef((e,t)=>{const{type:n,...o}=e,r=o,s=o;return g.jsx(Qs.Provider,{scope:e.__scopeAccordion,children:n==="multiple"?g.jsx(Eh,{...s,ref:t}):g.jsx(Mh,{...r,ref:t})})});Hl.displayName=Je;var[Gl,xh]=or(Je),[zl,Rh]=or(Je,{collapsible:!1}),Mh=c.forwardRef((e,t)=>{const{value:n,defaultValue:o,onValueChange:r=()=>{},collapsible:s=!1,...a}=e,[i,l]=he({prop:n,defaultProp:o??"",onChange:r,caller:Je});return g.jsx(Gl,{scope:e.__scopeAccordion,value:c.useMemo(()=>i?[i]:[],[i]),onItemOpen:l,onItemClose:c.useCallback(()=>s&&l(""),[s,l]),children:g.jsx(zl,{scope:e.__scopeAccordion,collapsible:s,children:g.jsx(Yl,{...a,ref:t})})})}),Eh=c.forwardRef((e,t)=>{const{value:n,defaultValue:o,onValueChange:r=()=>{},...s}=e,[a,i]=he({prop:n,defaultProp:o??[],onChange:r,caller:Je}),l=c.useCallback(d=>i((f=[])=>[...f,d]),[i]),u=c.useCallback(d=>i((f=[])=>f.filter(p=>p!==d)),[i]);return g.jsx(Gl,{scope:e.__scopeAccordion,value:a,onItemOpen:l,onItemClose:u,children:g.jsx(zl,{scope:e.__scopeAccordion,collapsible:!0,children:g.jsx(Yl,{...s,ref:t})})})}),[Ph,rr]=or(Je),Yl=c.forwardRef((e,t)=>{const{__scopeAccordion:n,disabled:o,dir:r,orientation:s="vertical",...a}=e,i=c.useRef(null),l=H(i,t),u=Sh(n),f=Qe(r)==="ltr",p=E(e.onKeyDown,m=>{if(!Ch.includes(m.key))return;const h=m.target,v=u().filter(I=>!I.ref.current?.disabled),y=v.findIndex(I=>I.ref.current===h),w=v.length;if(y===-1)return;m.preventDefault();let S=y;const C=0,b=w-1,x=()=>{S=y+1,S>b&&(S=C)},R=()=>{S=y-1,S<C&&(S=b)};switch(m.key){case"Home":S=C;break;case"End":S=b;break;case"ArrowRight":s==="horizontal"&&(f?x():R());break;case"ArrowDown":s==="vertical"&&x();break;case"ArrowLeft":s==="horizontal"&&(f?R():x());break;case"ArrowUp":s==="vertical"&&R();break}const M=S%w;v[M].ref.current?.focus()});return g.jsx(Ph,{scope:n,disabled:o,direction:r,orientation:s,children:g.jsx(Qs.Slot,{scope:n,children:g.jsx(O.div,{...a,"data-orientation":s,ref:l,onKeyDown:o?void 0:p})})})}),Fo="AccordionItem",[_h,ea]=or(Fo),Ul=c.forwardRef((e,t)=>{const{__scopeAccordion:n,value:o,...r}=e,s=rr(Fo,n),a=xh(Fo,n),i=Js(n),l=pe(),u=o&&a.value.includes(o)||!1,d=s.disabled||e.disabled;return g.jsx(_h,{scope:n,open:u,disabled:d,triggerId:l,children:g.jsx(vh,{"data-orientation":s.orientation,"data-state":Jl(u),...i,...r,ref:t,disabled:d,open:u,onOpenChange:f=>{f?a.onItemOpen(o):a.onItemClose(o)}})})});Ul.displayName=Fo;var Kl="AccordionHeader",ql=c.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=rr(Je,n),s=ea(Kl,n);return g.jsx(O.h3,{"data-orientation":r.orientation,"data-state":Jl(s.open),"data-disabled":s.disabled?"":void 0,...o,ref:t})});ql.displayName=Kl;var vs="AccordionTrigger",Xl=c.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=rr(Je,n),s=ea(vs,n),a=Rh(vs,n),i=Js(n);return g.jsx(Qs.ItemSlot,{scope:n,children:g.jsx(wh,{"aria-disabled":s.open&&!a.collapsible||void 0,"data-orientation":r.orientation,id:s.triggerId,...i,...o,ref:t})})});Xl.displayName=vs;var Zl="AccordionContent",Ql=c.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=rr(Je,n),s=ea(Zl,n),a=Js(n);return g.jsx(yh,{role:"region","aria-labelledby":s.triggerId,"data-orientation":r.orientation,...a,...o,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});Ql.displayName=Zl;function Jl(e){return e?"open":"closed"}var t0=Hl,n0=Ul,o0=ql,r0=Xl,s0=Ql;function de(e){const t=c.useRef(e);return c.useEffect(()=>{t.current=e}),c.useMemo(()=>((...n)=>t.current?.(...n)),[])}var Dh="DismissableLayer",ws="dismissableLayer.update",Ih="dismissableLayer.pointerDownOutside",Th="dismissableLayer.focusOutside",Ai,ta=c.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),kt=c.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,deferPointerDownOutside:o=!1,onEscapeKeyDown:r,onPointerDownOutside:s,onFocusOutside:a,onInteractOutside:i,onDismiss:l,...u}=e,d=c.useContext(ta),[f,p]=c.useState(null),m=f?.ownerDocument??globalThis?.document,[,h]=c.useState({}),v=H(t,p),y=Array.from(d.layers),[w]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),S=w?y.indexOf(w):-1,C=f?y.indexOf(f):-1,b=d.layersWithOutsidePointerEventsDisabled.size>0,x=C>=S,R=c.useRef(!1),M=Fh(D=>{s?.(D),i?.(D),D.defaultPrevented||l?.()},{ownerDocument:m,deferPointerDownOutside:o,isDeferredPointerDownOutsideRef:R,dismissableSurfaces:d.dismissableSurfaces,shouldHandlePointerDownOutside:c.useCallback(D=>{if(!(D instanceof Node))return!1;const N=[...d.branches].some(k=>k.contains(D));return x&&!N},[d.branches,x])}),I=$h(D=>{if(o&&R.current)return;const N=D.target;[...d.branches].some(B=>B.contains(N))||(a?.(D),i?.(D),D.defaultPrevented||l?.())},m),_=f?C===y.length-1:!1,T=de(D=>{D.key==="Escape"&&(r?.(D),!D.defaultPrevented&&l&&(D.preventDefault(),l()))});return c.useEffect(()=>{if(_)return m.addEventListener("keydown",T,{capture:!0}),()=>m.removeEventListener("keydown",T,{capture:!0})},[m,_,T]),c.useEffect(()=>{if(f)return n&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(Ai=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),Ni(),()=>{n&&(d.layersWithOutsidePointerEventsDisabled.delete(f),d.layersWithOutsidePointerEventsDisabled.size===0&&(m.body.style.pointerEvents=Ai))}},[f,m,n,d]),c.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),Ni())},[f,d]),c.useEffect(()=>{const D=()=>h({});return document.addEventListener(ws,D),()=>document.removeEventListener(ws,D)},[]),g.jsx(O.div,{...u,ref:v,style:{pointerEvents:b?x?"auto":"none":void 0,...e.style},onFocusCapture:E(e.onFocusCapture,I.onFocusCapture),onBlurCapture:E(e.onBlurCapture,I.onBlurCapture),onPointerDownCapture:E(e.onPointerDownCapture,M.onPointerDownCapture)})});kt.displayName=Dh;var Oh="DismissableLayerBranch",Ah=c.forwardRef((e,t)=>{const n=c.useContext(ta),o=c.useRef(null),r=H(t,o);return c.useEffect(()=>{const s=o.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),g.jsx(O.div,{...e,ref:r})});Ah.displayName=Oh;function Nh(){const e=c.useContext(ta),[t,n]=c.useState(null);return c.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),n}var kh=()=>!0;function Fh(e,t){const{ownerDocument:n=globalThis?.document,deferPointerDownOutside:o=!1,isDeferredPointerDownOutsideRef:r,dismissableSurfaces:s,shouldHandlePointerDownOutside:a=kh}=t,i=de(e),l=c.useRef(!1),u=c.useRef(!1),d=c.useRef(new Map),f=c.useRef(()=>{});return c.useEffect(()=>{function p(){u.current=!1,r.current=!1,d.current.clear()}function m(){return Array.from(d.current.values()).some(Boolean)}function h(C){if(!u.current)return;const b=C.target;b instanceof Node&&[...s].some(R=>R.contains(b))||d.current.set(C.type,!0),C.type==="click"&&window.setTimeout(()=>{u.current&&f.current()},0)}function v(C){u.current&&d.current.set(C.type,!1)}const y=C=>{if(C.target&&!l.current){let b=function(){n.removeEventListener("click",f.current);const R=m();p(),R||ec(Ih,i,x,{discrete:!0})};if(!a(C.target)){n.removeEventListener("click",f.current),p(),l.current=!1;return}const x={originalEvent:C};u.current=!0,r.current=o&&C.button===0,d.current.clear(),!o||C.button!==0?b():(n.removeEventListener("click",f.current),f.current=b,n.addEventListener("click",f.current,{once:!0}))}else n.removeEventListener("click",f.current),p();l.current=!1},w=["pointerup","mousedown","mouseup","touchstart","touchend","click"];for(const C of w)n.addEventListener(C,h,!0),n.addEventListener(C,v);const S=window.setTimeout(()=>{n.addEventListener("pointerdown",y)},0);return()=>{window.clearTimeout(S),n.removeEventListener("pointerdown",y),n.removeEventListener("click",f.current);for(const C of w)n.removeEventListener(C,h,!0),n.removeEventListener(C,v)}},[n,i,o,r,s,a]),{onPointerDownCapture:()=>l.current=!0}}function $h(e,t=globalThis?.document){const n=de(e),o=c.useRef(!1);return c.useEffect(()=>{const r=s=>{s.target&&!o.current&&ec(Th,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",r),()=>t.removeEventListener("focusin",r)},[t,n]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}function Ni(){const e=new CustomEvent(ws);document.dispatchEvent(e)}function ec(e,t,n,{discrete:o}){const r=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&r.addEventListener(e,t,{once:!0}),o?ko(r,s):r.dispatchEvent(s)}var zr="focusScope.autoFocusOnMount",Yr="focusScope.autoFocusOnUnmount",ki={bubbles:!1,cancelable:!0},jh="FocusScope",Kn=c.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:s,...a}=e,[i,l]=c.useState(null),u=de(r),d=de(s),f=c.useRef(null),p=H(t,l),m=c.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;c.useEffect(()=>{if(o){let v=function(C){if(m.paused||!i)return;const b=C.target;i.contains(b)?f.current=b:Mt(f.current,{select:!0})},y=function(C){if(m.paused||!i)return;const b=C.relatedTarget;b!==null&&(i.contains(b)||Mt(f.current,{select:!0}))},w=function(C){if(document.activeElement===document.body)for(const x of C)x.removedNodes.length>0&&Mt(i)};document.addEventListener("focusin",v),document.addEventListener("focusout",y);const S=new MutationObserver(w);return i&&S.observe(i,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",v),document.removeEventListener("focusout",y),S.disconnect()}}},[o,i,m.paused]),c.useEffect(()=>{if(i){$i.add(m);const v=document.activeElement;if(!i.contains(v)){const w=new CustomEvent(zr,ki);i.addEventListener(zr,u),i.dispatchEvent(w),w.defaultPrevented||(Lh(Gh(tc(i)),{select:!0}),document.activeElement===v&&Mt(i))}return()=>{i.removeEventListener(zr,u),setTimeout(()=>{const w=new CustomEvent(Yr,ki);i.addEventListener(Yr,d),i.dispatchEvent(w),w.defaultPrevented||Mt(v??document.body,{select:!0}),i.removeEventListener(Yr,d),$i.remove(m)},0)}}},[i,u,d,m]);const h=c.useCallback(v=>{if(!n&&!o||m.paused)return;const y=v.key==="Tab"&&!v.altKey&&!v.ctrlKey&&!v.metaKey,w=document.activeElement;if(y&&w){const S=v.currentTarget,[C,b]=Wh(S);C&&b?!v.shiftKey&&w===b?(v.preventDefault(),n&&Mt(C,{select:!0})):v.shiftKey&&w===C&&(v.preventDefault(),n&&Mt(b,{select:!0})):w===S&&v.preventDefault()}},[n,o,m.paused]);return g.jsx(O.div,{tabIndex:-1,...a,ref:p,onKeyDown:h})});Kn.displayName=jh;function Lh(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if(Mt(o,{select:t}),document.activeElement!==n)return}function Wh(e){const t=tc(e),n=Fi(t,e),o=Fi(t.reverse(),e);return[n,o]}function tc(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:o=>{const r=o.tagName==="INPUT"&&o.type==="hidden";return o.disabled||o.hidden||r?NodeFilter.FILTER_SKIP:o.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Fi(e,t){const n=typeof t.checkVisibility=="function"&&t.checkVisibility({checkVisibilityCSS:!0});for(const o of e)if(!(n?!o.checkVisibility({checkVisibilityCSS:!0}):Vh(o,{upTo:t})))return o}function Vh(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Bh(e){return e instanceof HTMLInputElement&&"select"in e}function Mt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Bh(e)&&t&&e.select()}}var $i=Hh();function Hh(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=ji(e,t),e.unshift(t)},remove(t){e=ji(e,t),e[0]?.resume()}}}function ji(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function Gh(e){return e.filter(t=>t.tagName!=="A")}var zh="Portal",Yt=c.forwardRef((e,t)=>{const{container:n,...o}=e,[r,s]=c.useState(!1);ye(()=>s(!0),[]);const a=n||r&&globalThis?.document?.body;return a?yn.createPortal(g.jsx(O.div,{...o,ref:t}),a):null});Yt.displayName=zh;var yo=0,Jt=null;function sr(){c.useEffect(()=>{Jt||(Jt={start:Li(),end:Li()});const{start:e,end:t}=Jt;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement("afterbegin",e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement("beforeend",t),yo++,()=>{yo===1&&(Jt?.start.remove(),Jt?.end.remove(),Jt=null),yo=Math.max(0,yo-1)}},[])}function Li(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var st=function(){return st=Object.assign||function(t){for(var n,o=1,r=arguments.length;o<r;o++){n=arguments[o];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},st.apply(this,arguments)};function nc(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var r=0,o=Object.getOwnPropertySymbols(e);r<o.length;r++)t.indexOf(o[r])<0&&Object.prototype.propertyIsEnumerable.call(e,o[r])&&(n[o[r]]=e[o[r]]);return n}function Yh(e,t,n){if(n||arguments.length===2)for(var o=0,r=t.length,s;o<r;o++)(s||!(o in t))&&(s||(s=Array.prototype.slice.call(t,0,o)),s[o]=t[o]);return e.concat(s||Array.prototype.slice.call(t))}var Do="right-scroll-bar-position",Io="width-before-scroll-bar",Uh="with-scroll-bars-hidden",Kh="--removed-body-scroll-bar-size";function Ur(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function qh(e,t){var n=c.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(o){var r=n.value;r!==o&&(n.value=o,n.callback(o,r))}}}})[0];return n.callback=t,n.facade}var Xh=typeof window<"u"?c.useLayoutEffect:c.useEffect,Wi=new WeakMap;function Zh(e,t){var n=qh(null,function(o){return e.forEach(function(r){return Ur(r,o)})});return Xh(function(){var o=Wi.get(n);if(o){var r=new Set(o),s=new Set(e),a=n.current;r.forEach(function(i){s.has(i)||Ur(i,null)}),s.forEach(function(i){r.has(i)||Ur(i,a)})}Wi.set(n,e)},[e]),n}function Qh(e){return e}function Jh(e,t){t===void 0&&(t=Qh);var n=[],o=!1,r={read:function(){if(o)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var a=t(s,o);return n.push(a),function(){n=n.filter(function(i){return i!==a})}},assignSyncMedium:function(s){for(o=!0;n.length;){var a=n;n=[],a.forEach(s)}n={push:function(i){return s(i)},filter:function(){return n}}},assignMedium:function(s){o=!0;var a=[];if(n.length){var i=n;n=[],i.forEach(s),a=n}var l=function(){var d=a;a=[],d.forEach(s)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(d){a.push(d),u()},filter:function(d){return a=a.filter(d),n}}}};return r}function ev(e){e===void 0&&(e={});var t=Jh(null);return t.options=st({async:!0,ssr:!1},e),t}var oc=function(e){var t=e.sideCar,n=nc(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var o=t.read();if(!o)throw new Error("Sidecar medium not found");return c.createElement(o,st({},n))};oc.isSideCarExport=!0;function tv(e,t){return e.useMedium(t),oc}var rc=ev(),Kr=function(){},ar=c.forwardRef(function(e,t){var n=c.useRef(null),o=c.useState({onScrollCapture:Kr,onWheelCapture:Kr,onTouchMoveCapture:Kr}),r=o[0],s=o[1],a=e.forwardProps,i=e.children,l=e.className,u=e.removeScrollBar,d=e.enabled,f=e.shards,p=e.sideCar,m=e.noRelative,h=e.noIsolation,v=e.inert,y=e.allowPinchZoom,w=e.as,S=w===void 0?"div":w,C=e.gapMode,b=nc(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),x=p,R=Zh([n,t]),M=st(st({},b),r);return c.createElement(c.Fragment,null,d&&c.createElement(x,{sideCar:rc,removeScrollBar:u,shards:f,noRelative:m,noIsolation:h,inert:v,setCallbacks:s,allowPinchZoom:!!y,lockRef:n,gapMode:C}),a?c.cloneElement(c.Children.only(i),st(st({},M),{ref:R})):c.createElement(S,st({},M,{className:l,ref:R}),i))});ar.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};ar.classNames={fullWidth:Io,zeroRight:Do};var nv=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function ov(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=nv();return t&&e.setAttribute("nonce",t),e}function rv(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function sv(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var av=function(){var e=0,t=null;return{add:function(n){e==0&&(t=ov())&&(rv(t,n),sv(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},iv=function(){var e=av();return function(t,n){c.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},sc=function(){var e=iv(),t=function(n){var o=n.styles,r=n.dynamic;return e(o,r),null};return t},lv={left:0,top:0,right:0,gap:0},qr=function(e){return parseInt(e||"",10)||0},cv=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],o=t[e==="padding"?"paddingTop":"marginTop"],r=t[e==="padding"?"paddingRight":"marginRight"];return[qr(n),qr(o),qr(r)]},uv=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return lv;var t=cv(e),n=document.documentElement.clientWidth,o=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,o-n+t[2]-t[0])}},dv=sc(),cn="data-scroll-locked",fv=function(e,t,n,o){var r=e.left,s=e.top,a=e.right,i=e.gap;return n===void 0&&(n="margin"),`
2
2
  .`.concat(Uh,` {
3
3
  overflow: hidden `).concat(o,`;
4
4
  padding-right: `).concat(i,"px ").concat(o,`;