boottent-design 0.1.201 → 0.1.203
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components.cjs.js +1 -1
- package/dist/components.es.js +3 -3
- package/dist/{index-DYCVXWdb.cjs → index-CAXvbMVF.cjs} +1 -1
- package/dist/{index-DPK1cI4n.js → index-DZmnb6ih.js} +9 -4
- package/dist/provider.cjs.js +1 -1
- package/dist/provider.es.js +2 -2
- package/dist/{toast-form-BWLiyc9J.js → toast-form-Ck6Wlh-K.js} +1 -1
- package/dist/{toast-form-BwWhSe5T.cjs → toast-form-DlQ2uN7i.cjs} +1 -1
- package/dist/ui.cjs.js +1 -1
- package/dist/ui.es.js +2 -2
- package/package.json +1 -1
package/dist/components.cjs.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("react/jsx-runtime"),Ce=require("./index-z9hRvvSX.cjs"),v=require("./index-DYCVXWdb.cjs"),T=require("./index-Cjpdd7RE.cjs"),O=require("react"),ne=require("./index-CSwq9AvE.cjs"),_u=require("./index-DKCqkplO.cjs"),Eu=require("./use-metadata-CZiZDN9j.cjs"),wn=require("./toast-form-BwWhSe5T.cjs");function Cu(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,i.get?i:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const te=Cu(O),Tu=(e,t)=>e.length===0?f.jsx("span",{children:t}):e.length===1?f.jsx("span",{children:e[0].label}):f.jsxs("span",{children:[e[0].label," ","외"," ",e.length-1,"개"]}),Ru=({children:e})=>f.jsx("div",{className:"purple-wrapper py-2",children:e}),Rn=({children:e})=>f.jsx("div",{className:"h1-wrapper py-2",children:e}),Nn=({children:e})=>f.jsx("div",{className:"h2-wrapper py-2",children:e}),Mn=({children:e})=>f.jsx("div",{className:"h3-wrapper py-2",children:e}),Nu=({children:e})=>f.jsx(O.Fragment,{children:e}),Be=()=>!0,Mu=e=>{var t,n;return e.type==="paragraph"&&((n=(t=e.paragraph)==null?void 0:t.rich_text)==null?void 0:n.every(i=>i.annotations.color==="purple"))},li={default:{heading_1:{priority:3,condition:Be,wrapper:Rn},heading_2:{priority:2,condition:Be,wrapper:Nn},heading_3:{priority:1,condition:Be,wrapper:Mn}},curriculum:{heading_1:{priority:4,condition:Be,wrapper:Rn},heading_2:{priority:3,condition:Be,wrapper:Nn},paragraph:{priority:2,condition:Mu,wrapper:Ru,className:"text-main-600 text-lg md:text-xl font-medium"},heading_3:{priority:1,condition:Be,wrapper:Mn}},article:{heading_1:{priority:3,condition:Be,wrapper:Rn},heading_2:{priority:2,condition:Be,wrapper:Nn},heading_3:{priority:1,condition:Be,wrapper:Mn}},event:{heading_1:{priority:3,condition:Be,wrapper:Rn},heading_2:{priority:2,condition:Be,wrapper:Nn},heading_3:{priority:1,condition:Be,wrapper:Mn}}},Pu={container:"flex flex-col gap-4",heading1:"mb-4 text-xl font-bold text-grey-900 md:text-2xl lg:text-3xl",heading2:"mb-3 text-lg font-semibold text-grey-800 md:text-xl lg:text-2xl",heading3:"mb-2 text-base font-medium text-grey-800 md:text-lg lg:text-xl",paragraph:"mb-2 text-base text-grey-800 leading-relaxed md:text-lg whitespace-pre-wrap",quote:"mb-4 border-l-4 border-grey-400 pl-4 text-lg italic text-grey-600",callout:"mb-4 flex gap-2 rounded-lg bg-grey-100 p-4 text-grey-600",list:"pl-5 space-y-2",listItem:"ml-1 text-base md:text-lg text-grey-800",code:"mb-4 rounded-md bg-grey-100 p-4 font-mono text-sm",image:"rounded-lg overflow-hidden",divider:"my-6 border-t border-grey-300",table:"w-full border-collapse border border-grey-200",tableRow:"border-b border-grey-200",tableCell:"border border-grey-200 p-4 md:text-base text-sm",loading:"flex h-14 w-full animate-pulse items-center rounded-lg bg-slate-100 p-4 text-muted"},Au={container:"flex flex-col gap-4",heading1:"mb-4 text-xl font-bold text-blue-800 md:text-2xl lg:text-3xl",heading2:"mb-3 text-lg font-semibold text-blue-700 md:text-xl lg:text-2xl",heading3:"mb-2 text-base font-medium text-grey-800 md:text-lg lg:text-xl",paragraph:"mb-4 text-sm text-grey-800 md:text-base lg:text-lg whitespace-pre-wrap",quote:"mb-4 border-l-4 border-blue-500 pl-4 text-sm italic text-grey-600 md:text-base",callout:"mb-4 flex gap-2 rounded-lg bg-grey-100 p-4 text-grey-600",list:"pl-5 space-y-2",listItem:"text-sm text-grey-800 md:text-base",code:"mb-4 rounded-md bg-grey-800 p-4 font-mono text-sm text-white",image:"w-full rounded-lg object-cover",divider:"my-6 border-t border-border",table:"w-full border-collapse border border-blue-200",tableRow:"border-b border-blue-200",tableCell:"border border-grey-200 p-4 md:text-base text-sm",loading:"flex h-14 w-full animate-pulse items-center rounded-lg bg-slate-100 p-4 text-muted"},Ou={container:"flex flex-col w-full",heading1:"mb-4 text-2xl font-bold text-grey-900 md:text-3xl lg:text-4xl",heading2:"mb-3 text-xl font-semibold text-grey-800 md:text-2xl lg:text-3xl",heading3:"mb-2 text-lg font-semibold text-grey-800 md:text-xl lg:text-2xl",paragraph:"mb-2 text-base leading-relaxed md:text-lg whitespace-pre-wrap",quote:"mb-4 border-l-4 border-grey-400 pl-4 text-lg italic text-grey-600",callout:"mb-4 flex gap-2 rounded-lg bg-main-50 p-4 text-grey-600",list:"pl-5 space-y-1",listItem:"ml-1 text-base md:text-lg",code:"mb-4 rounded-md bg-grey-100 p-4 font-mono text-sm",image:"rounded-lg overflow-hidden mb-2",divider:"my-6 border-t border-grey-300",table:"w-full border-collapse border border-grey-200",tableRow:"border-b border-grey-200",tableCell:"border border-grey-200 p-4 md:text-base text-sm",loading:"flex h-14 w-full animate-pulse items-center rounded-lg bg-slate-100 p-4 text-muted"},Du={container:"flex flex-col gap-0",heading1:"mb-4 text-xl font-bold text-grey-900 md:text-2xl lg:text-3xl",heading2:"mb-3 text-xl font-semibold text-grey-800 md:text-2xl lg:text-3xl",heading3:"mb-2 text-lg font-medium text-grey-800 md:text-xl lg:text-2xl",paragraph:"mb-4 text-base text-grey-800 leading-relaxed md:text-lg whitespace-pre-wrap",quote:"mb-4 border-l-4 border-grey-400 pl-4 text-lg italic text-grey-600",callout:"mb-4 flex gap-2 rounded-lg bg-grey-100 p-4 text-grey-600",list:"pl-5 space-y-2",listItem:"text-base md:text-lg text-grey-700 marker:text-main-600",code:"mb-4 rounded-md bg-grey-100 p-4 font-mono text-sm",image:"rounded-lg overflow-hidden w-full",divider:"my-6 border-t border-grey-300",table:"w-full border-collapse border border-grey-200",tableRow:"border-b border-grey-200",tableCell:"border border-grey-200 p-4 md:text-base text-sm",loading:"flex h-14 w-full animate-pulse items-center rounded-lg bg-slate-100 p-4 text-muted"},xr=e=>{switch(e){case"curriculum":return Au;case"article":return Ou;case"event":return Du;default:return Pu}},Iu={default:"",gray:"text-grey-500",brown:"text-yellow-900",orange:"text-orange-500",yellow:"text-yellow-500",green:"text-green-500",blue:"text-blue-500",purple:"text-purple-500",pink:"text-pink-500",red:"text-red-500"},bs={default:"",gray:"bg-grey-100",brown:"bg-yellow-100",orange:"bg-orange-100",yellow:"bg-yellow-100",green:"bg-green-100",blue:"bg-blue-100",purple:"bg-purple-100",pink:"bg-pink-100",red:"bg-red-100"},Fu=(e,t="default")=>{const n={id:"root",type:"root",children:[],parent:{},has_children:!0},i={root:n};e.forEach(a=>{a.children=[],i[a.id]=a});const r={};e.forEach(a=>{var c;const l=(c=a.parent)==null?void 0:c.block_id;l&&(r[l]||(r[l]=[]),r[l].push(a))});const s=new Set,o=[{block:n,priority:0}];return e.forEach(a=>{var h;if(s.has(a.id))return;const l=sa(a,t),c=(h=a.parent)==null?void 0:h.block_id,d=c?i[c]:null;if(l>0){for(;o.length>1&&o[o.length-1].priority<=l;)o.pop();const g={...a,children:[]};o[o.length-1].block.children.push(g),o.push({block:g,priority:l}),s.add(a.id)}else if(c&&d)d.children.push(a),s.add(a.id);else{const g={...a,children:[]};o[o.length-1].block.children.push(g),s.add(a.id);const u=r[a.id];u&&u.length>0&&(g.children=u,u.forEach(p=>s.add(p.id)))}}),n.children||[]},ra=["bulleted_list_item","numbered_list_item"],sa=(e,t="default")=>{var i;const n=(i=li[t])==null?void 0:i[e.type];return n!=null&&n.condition(e)?n.priority:0},Lu=(e,t="default")=>{var i;const n=(i=li[t])==null?void 0:i[e.type];return n!=null&&n.condition(e)?n.wrapper:Nu},oa=(e,t="default")=>{var i;const n=(i=li[t])==null?void 0:i[e.type];return!!(n!=null&&n.priority&&n.condition(e))};function Sr(e){const t=[];let n=[],i=null;const r=()=>{!i||n.length===0||(i==="block"?n.forEach(s=>t.push({type:"block",block:s})):i==="bulleted_list"?t.push({type:"bulleted_list",blocks:n}):i==="numbered_list"&&t.push({type:"numbered_list",blocks:n}),n=[],i=null)};for(const s of e){const o=s.type==="bulleted_list_item",a=s.type==="numbered_list_item",l=o?"bulleted_list":a?"numbered_list":"block";i===l?n.push(s):(r(),i=l,n=[s])}return r(),t}const ju=e=>e.includes("youtu.be")?"https://www.youtube.com/embed/"+e.split("/").pop():e.includes("youtube.com/watch")?"https://www.youtube.com/embed/"+e.split("v=")[1].split("&")[0]:e;function ku(e,t,n){const[i,r]=v.normalizeDates(n==null?void 0:n.in,e,t),s=ws(i,r),o=Math.abs(v.differenceInCalendarDays(i,r));i.setDate(i.getDate()-s*o);const a=+(ws(i,r)===-s),l=s*(o-a);return l===0?0:l}function ws(e,t){const n=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return n<0?-1:n>0?1:n}function Vu(e,t){const n=()=>v.constructFrom(t==null?void 0:t.in,NaN),r=Gu(e);let s;if(r.date){const c=zu(r.date,2);s=Hu(c.restDateString,c.year)}if(!s||isNaN(+s))return n();const o=+s;let a=0,l;if(r.time&&(a=Wu(r.time),isNaN(a)))return n();if(r.timezone){if(l=Ku(r.timezone),isNaN(l))return n()}else{const c=new Date(o+a),d=v.toDate(0,t==null?void 0:t.in);return d.setFullYear(c.getUTCFullYear(),c.getUTCMonth(),c.getUTCDate()),d.setHours(c.getUTCHours(),c.getUTCMinutes(),c.getUTCSeconds(),c.getUTCMilliseconds()),d}return v.toDate(o+a+l,t==null?void 0:t.in)}const Pn={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},Bu=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,$u=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,Uu=/^([+-])(\d{2})(?::?(\d{2}))?$/;function Gu(e){const t={},n=e.split(Pn.dateTimeDelimiter);let i;if(n.length>2)return t;if(/:/.test(n[0])?i=n[0]:(t.date=n[0],i=n[1],Pn.timeZoneDelimiter.test(t.date)&&(t.date=e.split(Pn.timeZoneDelimiter)[0],i=e.substr(t.date.length,e.length))),i){const r=Pn.timezone.exec(i);r?(t.time=i.replace(r[1],""),t.timezone=r[1]):t.time=i}return t}function zu(e,t){const n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),i=e.match(n);if(!i)return{year:NaN,restDateString:""};const r=i[1]?parseInt(i[1]):null,s=i[2]?parseInt(i[2]):null;return{year:s===null?r:s*100,restDateString:e.slice((i[1]||i[2]).length)}}function Hu(e,t){if(t===null)return new Date(NaN);const n=e.match(Bu);if(!n)return new Date(NaN);const i=!!n[4],r=Zt(n[1]),s=Zt(n[2])-1,o=Zt(n[3]),a=Zt(n[4]),l=Zt(n[5])-1;if(i)return Qu(t,a,l)?qu(t,a,l):new Date(NaN);{const c=new Date(0);return!Xu(t,s,o)||!Zu(t,r)?new Date(NaN):(c.setUTCFullYear(t,s,Math.max(r,o)),c)}}function Zt(e){return e?parseInt(e):1}function Wu(e){const t=e.match($u);if(!t)return NaN;const n=vi(t[1]),i=vi(t[2]),r=vi(t[3]);return Ju(n,i,r)?n*v.millisecondsInHour+i*v.millisecondsInMinute+r*1e3:NaN}function vi(e){return e&&parseFloat(e.replace(",","."))||0}function Ku(e){if(e==="Z")return 0;const t=e.match(Uu);if(!t)return 0;const n=t[1]==="+"?-1:1,i=parseInt(t[2]),r=t[3]&&parseInt(t[3])||0;return ed(i,r)?n*(i*v.millisecondsInHour+r*v.millisecondsInMinute):NaN}function qu(e,t,n){const i=new Date(0);i.setUTCFullYear(e,0,4);const r=i.getUTCDay()||7,s=(t-1)*7+n+1-r;return i.setUTCDate(i.getUTCDate()+s),i}const Yu=[31,null,31,30,31,30,31,31,30,31,30,31];function aa(e){return e%400===0||e%4===0&&e%100!==0}function Xu(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(Yu[t]||(aa(e)?29:28))}function Zu(e,t){return t>=1&&t<=(aa(e)?366:365)}function Qu(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}function Ju(e,t,n){return e===24?t===0&&n===0:n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}function ed(e,t){return t>=0&&t<=59}const qn=({src:e,alt:t,object:n="cover",lazy:i=!0,size:r="auto",className:s,...o})=>{const a={contain:"object-contain h-full",cover:"object-cover h-full",fill:"object-fill h-full","scale-down":"object-scale-down",none:"object-none"},l={full:"w-full",fit:"w-fit",auto:"w-auto"};let c="",d={};return typeof r=="string"?c=l[r]:typeof r=="number"&&(d={width:`${r}px`}),f.jsx("img",{src:e,alt:t?`${t} 이미지`:"이미지",loading:i?"lazy":"eager",className:T.cn(a[n],c,s),style:d,...o})};function td({adProduct:e,logo:t,title:n,batchName:i="",adTitle:r,startDate:s,tuition:o,nbCardRequired:a,isLoading:l=!1,regEndDate:c,className:d}){if(l)return f.jsx(ca,{className:d});const h=`${nd(s)} · ${id(o,a)}`;return f.jsx(la,{logo:t,title:`${n} ${i}`,adTitle:r,footerText:h,regEndDate:c,className:d,adProduct:e})}function la({adProduct:e,logo:t,title:n,adTitle:i,footerText:r,regEndDate:s,className:o}){return f.jsxs(v.FlexBox.Col,{className:T.cn("relative z-10 h-full w-full items-start justify-between gap-2 overflow-hidden rounded-xl border border-grey-200 bg-white p-4 text-grey-800 md:p-5 lg:p-6",o),children:[f.jsx(v.Tag,{variant:"ad",style:{background:Ce.adProducts.event.background,color:Ce.adProducts.event.color},children:e===Ce.adProducts.dDay.value&&s?sd(s):Ce.adProducts.event.value.toUpperCase()}),f.jsx(qn,{src:t,alt:`${n} 로고`,className:"h-4 object-contain"}),f.jsxs(v.FlexBox.Col,{className:"w-full gap-2",children:[f.jsx("h3",{className:"line-clamp-2 h-auto text-sm font-normal md:text-base lg:h-12",title:n,children:n}),f.jsx("p",{className:"line-clamp-2 h-auto w-full break-keep rounded bg-grey-100 px-2 py-1 text-[13px] font-semibold text-grey-600 md:h-[54px] md:text-[15px] md:text-grey-800",children:i}),f.jsx(v.Box,{className:"text-[13px] leading-[19px] text-grey-600",children:r})]})]})}function ca({className:e}){return f.jsxs(ne.Skeleton,{type:"background",className:T.cn("relative z-10 flex h-full w-full flex-col justify-between gap-2 overflow-hidden rounded-xl p-4 md:p-5 lg:p-6",e),children:[f.jsx(v.Tag,{variant:"ad",style:{background:Ce.adProducts.event.background,color:Ce.adProducts.event.color},className:T.cn("h-7 w-20 animate-pulse rounded-bl-lg rounded-br-none rounded-tl-none rounded-tr-lg px-2 py-1 text-sm"),children:""}),f.jsx(ne.Skeleton,{className:"h-4 w-1/2"}),f.jsxs(v.FlexBox.Col,{className:"gap-2",children:[f.jsx(v.Box,{className:"h-10 w-full",children:f.jsx(ne.Skeleton,{className:"h-5 w-4/5"})}),f.jsx(ne.Skeleton,{className:"h-14 w-full"})]}),f.jsx(ne.Skeleton,{className:"mt-2 h-[19px] w-2/3"})]})}const nd=e=>{if(!e)return"";const n=e.split(" ")[0].split("-"),i=Number(n[1]),r=`${i}/${Number(n.slice(2).join("."))}`;switch(n[2]){case"98":return`${i}월중 개강`;case"99":return`${i}월중(예상) 개강`;default:return`${r} 개강`}},id=(e,t)=>{const n=t?"(내배카💳)":"";return e===0||e===void 0?`무료 ${n}`:`유료 ${n}`},rd=e=>{const n=e.split(" ")[0].split("-"),i=Number(n[0]),r=Number(n[1]);let s=n[2];const o=new Date(i,r,0).getDate();return(isNaN(Number(s))||Number(s)>o)&&(s=o.toString()),`${i}-${String(r).padStart(2,"0")}-${String(s).padStart(2,"0")}`},sd=e=>{const t=ku(Vu(rd(e)),new Date);return t<=0?"마감임박":`D-${t}`},od={homepage:{label:"홈페이지",value:"homepage",query:!1},boottent:{label:"자세히보기",value:"boottent",query:!1},curriculum:{label:"커리큘럼 보기",value:"curriculum",query:"curriculum"},event:{label:"이벤트",value:"event",query:"event"},reviews:{label:"후기보기",value:"reviews",query:"reviews"}};var D={},zi={exports:{}};(function(e,t){(function(n,i){var r="1.0.40",s="",o="?",a="function",l="undefined",c="object",d="string",h="major",g="model",u="name",p="type",m="vendor",y="version",b="architecture",x="console",w="mobile",S="tablet",_="smarttv",C="wearable",k="embedded",F=500,Y="Amazon",Z="Apple",le="ASUS",fe="BlackBerry",me="Browser",ye="Chrome",de="Edge",be="Firefox",Q="Google",se="Huawei",ge="LG",ce="Microsoft",Ve="Motorola",Ae="Opera",E="Samsung",A="Sharp",H="Sony",q="Xiaomi",J="Zebra",Pe="Facebook",pe="Chromium OS",we="Mac OS",xe=" Browser",Fe=function(V,G){var j={};for(var X in V)G[X]&&G[X].length%2===0?j[X]=G[X].concat(V[X]):j[X]=V[X];return j},it=function(V){for(var G={},j=0;j<V.length;j++)G[V[j].toUpperCase()]=V[j];return G},_t=function(V,G){return typeof V===d?He(G).indexOf(He(V))!==-1:!1},He=function(V){return V.toLowerCase()},Ot=function(V){return typeof V===d?V.replace(/[^\d\.]/g,s).split(".")[0]:i},We=function(V,G){if(typeof V===d)return V=V.replace(/^\s\s*/,s),typeof G===l?V:V.substring(0,F)},Ke=function(V,G){for(var j=0,X,M,I,P,R,ee;j<G.length&&!R;){var Xe=G[j],It=G[j+1];for(X=M=0;X<Xe.length&&!R&&Xe[X];)if(R=Xe[X++].exec(V),R)for(I=0;I<It.length;I++)ee=R[++M],P=It[I],typeof P===c&&P.length>0?P.length===2?typeof P[1]==a?this[P[0]]=P[1].call(this,ee):this[P[0]]=P[1]:P.length===3?typeof P[1]===a&&!(P[1].exec&&P[1].test)?this[P[0]]=ee?P[1].call(this,ee,P[2]):i:this[P[0]]=ee?ee.replace(P[1],P[2]):i:P.length===4&&(this[P[0]]=ee?P[3].call(this,ee.replace(P[1],P[2])):i):this[P]=ee||i;j+=2}},Oe=function(V,G){for(var j in G)if(typeof G[j]===c&&G[j].length>0){for(var X=0;X<G[j].length;X++)if(_t(G[j][X],V))return j===o?i:j}else if(_t(G[j],V))return j===o?i:j;return G.hasOwnProperty("*")?G["*"]:V},Dt={"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"},rt={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2",8.1:"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},W={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[y,[u,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[y,[u,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[u,y],[/opios[\/ ]+([\w\.]+)/i],[y,[u,Ae+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[y,[u,Ae+" GX"]],[/\bopr\/([\w\.]+)/i],[y,[u,Ae]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[y,[u,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[y,[u,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[u,y],[/quark(?:pc)?\/([-\w\.]+)/i],[y,[u,"Quark"]],[/\bddg\/([\w\.]+)/i],[y,[u,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[y,[u,"UC"+me]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[y,[u,"WeChat"]],[/konqueror\/([\w\.]+)/i],[y,[u,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[y,[u,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[y,[u,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[y,[u,"Smart Lenovo "+me]],[/(avast|avg)\/([\w\.]+)/i],[[u,/(.+)/,"$1 Secure "+me],y],[/\bfocus\/([\w\.]+)/i],[y,[u,be+" Focus"]],[/\bopt\/([\w\.]+)/i],[y,[u,Ae+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[y,[u,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[y,[u,"Dolphin"]],[/coast\/([\w\.]+)/i],[y,[u,Ae+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[y,[u,"MIUI"+xe]],[/fxios\/([\w\.-]+)/i],[y,[u,be]],[/\bqihoobrowser\/?([\w\.]*)/i],[y,[u,"360"]],[/\b(qq)\/([\w\.]+)/i],[[u,/(.+)/,"$1Browser"],y],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[u,/(.+)/,"$1"+xe],y],[/samsungbrowser\/([\w\.]+)/i],[y,[u,E+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[y,[u,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[u,"Sogou Mobile"],y],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[u,y],[/(lbbrowser|rekonq)/i,/\[(linkedin)app\]/i],[u],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[y,u],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[u,Pe],y],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[u,y],[/\bgsa\/([\w\.]+) .*safari\//i],[y,[u,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[y,[u,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[y,[u,ye+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[u,ye+" WebView"],y],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[y,[u,"Android "+me]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[u,y],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[y,[u,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[y,u],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[u,[y,Oe,Dt]],[/(webkit|khtml)\/([\w\.]+)/i],[u,y],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[u,"Netscape"],y],[/(wolvic|librewolf)\/([\w\.]+)/i],[u,y],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[y,[u,be+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i],[u,[y,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[u,[y,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[b,"amd64"]],[/(ia32(?=;))/i],[[b,He]],[/((?:i[346]|x)86)[;\)]/i],[[b,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[b,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[b,"armhf"]],[/windows (ce|mobile); ppc;/i],[[b,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[b,/ower/,s,He]],[/(sun4\w)[;\)]/i],[[b,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[b,He]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[g,[m,E],[p,S]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[g,[m,E],[p,w]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[g,[m,Z],[p,w]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[g,[m,Z],[p,S]],[/(macintosh);/i],[g,[m,Z]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[g,[m,A],[p,w]],[/(?:honor)([-\w ]+)[;\)]/i],[g,[m,"Honor"],[p,w]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[g,[m,se],[p,S]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[g,[m,se],[p,w]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i],[[g,/_/g," "],[m,q],[p,w]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[g,/_/g," "],[m,q],[p,S]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[g,[m,"OPPO"],[p,w]],[/\b(opd2\d{3}a?) bui/i],[g,[m,"OPPO"],[p,S]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[g,[m,"Vivo"],[p,w]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[g,[m,"Realme"],[p,w]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[g,[m,Ve],[p,w]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[g,[m,Ve],[p,S]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[g,[m,ge],[p,S]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[g,[m,ge],[p,w]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[g,[m,"Lenovo"],[p,S]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[g,/_/g," "],[m,"Nokia"],[p,w]],[/(pixel c)\b/i],[g,[m,Q],[p,S]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[g,[m,Q],[p,w]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[g,[m,H],[p,w]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[g,"Xperia Tablet"],[m,H],[p,S]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[g,[m,"OnePlus"],[p,w]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[g,[m,Y],[p,S]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[g,/(.+)/g,"Fire Phone $1"],[m,Y],[p,w]],[/(playbook);[-\w\),; ]+(rim)/i],[g,m,[p,S]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[g,[m,fe],[p,w]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[g,[m,le],[p,S]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[g,[m,le],[p,w]],[/(nexus 9)/i],[g,[m,"HTC"],[p,S]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[m,[g,/_/g," "],[p,w]],[/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])\w*(\)| bui)/i],[g,[m,"TCL"],[p,S]],[/(itel) ((\w+))/i],[[m,He],g,[p,Oe,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[g,[m,"Acer"],[p,S]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[g,[m,"Meizu"],[p,w]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[g,[m,"Ulefone"],[p,w]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[g,[m,"Energizer"],[p,w]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[g,[m,"Cat"],[p,w]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[g,[m,"Smartfren"],[p,w]],[/droid.+; (a(?:015|06[35]|142p?))/i],[g,[m,"Nothing"],[p,w]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (imo) ((?!tab)[\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[m,g,[p,w]],[/(imo) (tab \w+)/i,/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[m,g,[p,S]],[/(surface duo)/i],[g,[m,ce],[p,S]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[g,[m,"Fairphone"],[p,w]],[/(u304aa)/i],[g,[m,"AT&T"],[p,w]],[/\bsie-(\w*)/i],[g,[m,"Siemens"],[p,w]],[/\b(rct\w+) b/i],[g,[m,"RCA"],[p,S]],[/\b(venue[\d ]{2,7}) b/i],[g,[m,"Dell"],[p,S]],[/\b(q(?:mv|ta)\w+) b/i],[g,[m,"Verizon"],[p,S]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[g,[m,"Barnes & Noble"],[p,S]],[/\b(tm\d{3}\w+) b/i],[g,[m,"NuVision"],[p,S]],[/\b(k88) b/i],[g,[m,"ZTE"],[p,S]],[/\b(nx\d{3}j) b/i],[g,[m,"ZTE"],[p,w]],[/\b(gen\d{3}) b.+49h/i],[g,[m,"Swiss"],[p,w]],[/\b(zur\d{3}) b/i],[g,[m,"Swiss"],[p,S]],[/\b((zeki)?tb.*\b) b/i],[g,[m,"Zeki"],[p,S]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[m,"Dragon Touch"],g,[p,S]],[/\b(ns-?\w{0,9}) b/i],[g,[m,"Insignia"],[p,S]],[/\b((nxa|next)-?\w{0,9}) b/i],[g,[m,"NextBook"],[p,S]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[m,"Voice"],g,[p,w]],[/\b(lvtel\-)?(v1[12]) b/i],[[m,"LvTel"],g,[p,w]],[/\b(ph-1) /i],[g,[m,"Essential"],[p,w]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[g,[m,"Envizen"],[p,S]],[/\b(trio[-\w\. ]+) b/i],[g,[m,"MachSpeed"],[p,S]],[/\btu_(1491) b/i],[g,[m,"Rotor"],[p,S]],[/(shield[\w ]+) b/i],[g,[m,"Nvidia"],[p,S]],[/(sprint) (\w+)/i],[m,g,[p,w]],[/(kin\.[onetw]{3})/i],[[g,/\./g," "],[m,ce],[p,w]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[g,[m,J],[p,S]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[g,[m,J],[p,w]],[/smart-tv.+(samsung)/i],[m,[p,_]],[/hbbtv.+maple;(\d+)/i],[[g,/^/,"SmartTV"],[m,E],[p,_]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[m,ge],[p,_]],[/(apple) ?tv/i],[m,[g,Z+" TV"],[p,_]],[/crkey/i],[[g,ye+"cast"],[m,Q],[p,_]],[/droid.+aft(\w+)( bui|\))/i],[g,[m,Y],[p,_]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[g,[m,A],[p,_]],[/(bravia[\w ]+)( bui|\))/i],[g,[m,H],[p,_]],[/(mitv-\w{5}) bui/i],[g,[m,q],[p,_]],[/Hbbtv.*(technisat) (.*);/i],[m,g,[p,_]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[m,We],[g,We],[p,_]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[p,_]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[m,g,[p,x]],[/droid.+; (shield) bui/i],[g,[m,"Nvidia"],[p,x]],[/(playstation [345portablevi]+)/i],[g,[m,H],[p,x]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[g,[m,ce],[p,x]],[/\b(sm-[lr]\d\d[05][fnuw]?s?)\b/i],[g,[m,E],[p,C]],[/((pebble))app/i],[m,g,[p,C]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[g,[m,Z],[p,C]],[/droid.+; (glass) \d/i],[g,[m,Q],[p,C]],[/droid.+; (wt63?0{2,3})\)/i],[g,[m,J],[p,C]],[/droid.+; (glass) \d/i],[g,[m,Q],[p,C]],[/(pico) (4|neo3(?: link|pro)?)/i],[m,g,[p,C]],[/; (quest( \d| pro)?)/i],[g,[m,Pe],[p,C]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[m,[p,k]],[/(aeobc)\b/i],[g,[m,Y],[p,k]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[g,[p,w]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[g,[p,S]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[p,S]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[p,w]],[/(android[-\w\. ]{0,9});.+buil/i],[g,[m,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[y,[u,de+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[u,y],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[y,[u,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[u,y],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[y,u]],os:[[/microsoft (windows) (vista|xp)/i],[u,y],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[u,[y,Oe,rt]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[y,Oe,rt],[u,"Windows"]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[y,/_/g,"."],[u,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[u,we],[y,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[y,u],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish|openharmony)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[u,y],[/\(bb(10);/i],[y,[u,fe]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[y,[u,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[y,[u,be+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[y,[u,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[y,[u,"watchOS"]],[/crkey\/([\d\.]+)/i],[y,[u,ye+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[u,pe],y],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[u,y],[/(sunos) ?([\w\.\d]*)/i],[[u,"Solaris"],y],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[u,y]]},N=function(V,G){if(typeof V===c&&(G=V,V=i),!(this instanceof N))return new N(V,G).getResult();var j=typeof n!==l&&n.navigator?n.navigator:i,X=V||(j&&j.userAgent?j.userAgent:s),M=j&&j.userAgentData?j.userAgentData:i,I=G?Fe(W,G):W,P=j&&j.userAgent==X;return this.getBrowser=function(){var R={};return R[u]=i,R[y]=i,Ke.call(R,X,I.browser),R[h]=Ot(R[y]),P&&j&&j.brave&&typeof j.brave.isBrave==a&&(R[u]="Brave"),R},this.getCPU=function(){var R={};return R[b]=i,Ke.call(R,X,I.cpu),R},this.getDevice=function(){var R={};return R[m]=i,R[g]=i,R[p]=i,Ke.call(R,X,I.device),P&&!R[p]&&M&&M.mobile&&(R[p]=w),P&&R[g]=="Macintosh"&&j&&typeof j.standalone!==l&&j.maxTouchPoints&&j.maxTouchPoints>2&&(R[g]="iPad",R[p]=S),R},this.getEngine=function(){var R={};return R[u]=i,R[y]=i,Ke.call(R,X,I.engine),R},this.getOS=function(){var R={};return R[u]=i,R[y]=i,Ke.call(R,X,I.os),P&&!R[u]&&M&&M.platform&&M.platform!="Unknown"&&(R[u]=M.platform.replace(/chrome os/i,pe).replace(/macos/i,we)),R},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return X},this.setUA=function(R){return X=typeof R===d&&R.length>F?We(R,F):R,this},this.setUA(X),this};N.VERSION=r,N.BROWSER=it([u,y,h]),N.CPU=it([b]),N.DEVICE=it([g,m,p,x,w,_,S,C,k]),N.ENGINE=N.OS=it([u,y]),e.exports&&(t=e.exports=N),t.UAParser=N;var L=typeof n!==l&&(n.jQuery||n.Zepto);if(L&&!L.ua){var K=new N;L.ua=K.getResult(),L.ua.get=function(){return K.getUA()},L.ua.set=function(V){K.setUA(V);var G=K.getResult();for(var j in G)L.ua[j]=G[j]}}})(typeof window=="object"?window:v.commonjsGlobal)})(zi,zi.exports);var ad=zi.exports;Object.defineProperty(D,"__esModule",{value:!0});function ld(e){return e&&typeof e=="object"&&"default"in e?e.default:e}var Re=O,ie=ld(Re),ua=ad,vt=new ua,Ne=vt.getBrowser(),cd=vt.getCPU(),ke=vt.getDevice(),_r=vt.getEngine(),bt=vt.getOS(),xn=vt.getUA(),da=function(t){return vt.setUA(t)},Sn=function(t){if(!t){console.error("No userAgent string was provided");return}var n=new ua(t);return{UA:n,browser:n.getBrowser(),cpu:n.getCPU(),device:n.getDevice(),engine:n.getEngine(),os:n.getOS(),ua:n.getUA(),setUserAgent:function(r){return n.setUA(r)}}},ga=Object.freeze({ClientUAInstance:vt,browser:Ne,cpu:cd,device:ke,engine:_r,os:bt,ua:xn,setUa:da,parseUserAgent:Sn});function xs(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),n.push.apply(n,i)}return n}function ud(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?xs(Object(n),!0).forEach(function(i){pd(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xs(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}function sn(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?sn=function(t){return typeof t}:sn=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sn(e)}function dd(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function gd(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function fd(e,t,n){return t&&gd(e.prototype,t),e}function pd(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hi(){return Hi=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Hi.apply(this,arguments)}function hd(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ki(e,t)}function Wi(e){return Wi=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Wi(e)}function Ki(e,t){return Ki=Object.setPrototypeOf||function(i,r){return i.__proto__=r,i},Ki(e,t)}function md(e,t){if(e==null)return{};var n={},i=Object.keys(e),r,s;for(s=0;s<i.length;s++)r=i[s],!(t.indexOf(r)>=0)&&(n[r]=e[r]);return n}function ze(e,t){if(e==null)return{};var n=md(e,t),i,r;if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(r=0;r<s.length;r++)i=s[r],!(t.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(e,i)&&(n[i]=e[i])}return n}function Un(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yd(e,t){if(t&&(typeof t=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Un(e)}function vd(e,t){return bd(e)||wd(e,t)||xd(e,t)||Sd()}function bd(e){if(Array.isArray(e))return e}function wd(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var i=[],r=!0,s=!1,o,a;try{for(n=n.call(e);!(r=(o=n.next()).done)&&(i.push(o.value),!(t&&i.length===t));r=!0);}catch(l){s=!0,a=l}finally{try{!r&&n.return!=null&&n.return()}finally{if(s)throw a}}return i}}function xd(e,t){if(e){if(typeof e=="string")return Ss(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ss(e,t)}}function Ss(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function Sd(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("react/jsx-runtime"),Ce=require("./index-z9hRvvSX.cjs"),v=require("./index-CAXvbMVF.cjs"),T=require("./index-Cjpdd7RE.cjs"),O=require("react"),ne=require("./index-CSwq9AvE.cjs"),_u=require("./index-DKCqkplO.cjs"),Eu=require("./use-metadata-CZiZDN9j.cjs"),wn=require("./toast-form-DlQ2uN7i.cjs");function Cu(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,i.get?i:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const te=Cu(O),Tu=(e,t)=>e.length===0?f.jsx("span",{children:t}):e.length===1?f.jsx("span",{children:e[0].label}):f.jsxs("span",{children:[e[0].label," ","외"," ",e.length-1,"개"]}),Ru=({children:e})=>f.jsx("div",{className:"purple-wrapper py-2",children:e}),Rn=({children:e})=>f.jsx("div",{className:"h1-wrapper py-2",children:e}),Nn=({children:e})=>f.jsx("div",{className:"h2-wrapper py-2",children:e}),Mn=({children:e})=>f.jsx("div",{className:"h3-wrapper py-2",children:e}),Nu=({children:e})=>f.jsx(O.Fragment,{children:e}),Be=()=>!0,Mu=e=>{var t,n;return e.type==="paragraph"&&((n=(t=e.paragraph)==null?void 0:t.rich_text)==null?void 0:n.every(i=>i.annotations.color==="purple"))},li={default:{heading_1:{priority:3,condition:Be,wrapper:Rn},heading_2:{priority:2,condition:Be,wrapper:Nn},heading_3:{priority:1,condition:Be,wrapper:Mn}},curriculum:{heading_1:{priority:4,condition:Be,wrapper:Rn},heading_2:{priority:3,condition:Be,wrapper:Nn},paragraph:{priority:2,condition:Mu,wrapper:Ru,className:"text-main-600 text-lg md:text-xl font-medium"},heading_3:{priority:1,condition:Be,wrapper:Mn}},article:{heading_1:{priority:3,condition:Be,wrapper:Rn},heading_2:{priority:2,condition:Be,wrapper:Nn},heading_3:{priority:1,condition:Be,wrapper:Mn}},event:{heading_1:{priority:3,condition:Be,wrapper:Rn},heading_2:{priority:2,condition:Be,wrapper:Nn},heading_3:{priority:1,condition:Be,wrapper:Mn}}},Pu={container:"flex flex-col gap-4",heading1:"mb-4 text-xl font-bold text-grey-900 md:text-2xl lg:text-3xl",heading2:"mb-3 text-lg font-semibold text-grey-800 md:text-xl lg:text-2xl",heading3:"mb-2 text-base font-medium text-grey-800 md:text-lg lg:text-xl",paragraph:"mb-2 text-base text-grey-800 leading-relaxed md:text-lg whitespace-pre-wrap",quote:"mb-4 border-l-4 border-grey-400 pl-4 text-lg italic text-grey-600",callout:"mb-4 flex gap-2 rounded-lg bg-grey-100 p-4 text-grey-600",list:"pl-5 space-y-2",listItem:"ml-1 text-base md:text-lg text-grey-800",code:"mb-4 rounded-md bg-grey-100 p-4 font-mono text-sm",image:"rounded-lg overflow-hidden",divider:"my-6 border-t border-grey-300",table:"w-full border-collapse border border-grey-200",tableRow:"border-b border-grey-200",tableCell:"border border-grey-200 p-4 md:text-base text-sm",loading:"flex h-14 w-full animate-pulse items-center rounded-lg bg-slate-100 p-4 text-muted"},Au={container:"flex flex-col gap-4",heading1:"mb-4 text-xl font-bold text-blue-800 md:text-2xl lg:text-3xl",heading2:"mb-3 text-lg font-semibold text-blue-700 md:text-xl lg:text-2xl",heading3:"mb-2 text-base font-medium text-grey-800 md:text-lg lg:text-xl",paragraph:"mb-4 text-sm text-grey-800 md:text-base lg:text-lg whitespace-pre-wrap",quote:"mb-4 border-l-4 border-blue-500 pl-4 text-sm italic text-grey-600 md:text-base",callout:"mb-4 flex gap-2 rounded-lg bg-grey-100 p-4 text-grey-600",list:"pl-5 space-y-2",listItem:"text-sm text-grey-800 md:text-base",code:"mb-4 rounded-md bg-grey-800 p-4 font-mono text-sm text-white",image:"w-full rounded-lg object-cover",divider:"my-6 border-t border-border",table:"w-full border-collapse border border-blue-200",tableRow:"border-b border-blue-200",tableCell:"border border-grey-200 p-4 md:text-base text-sm",loading:"flex h-14 w-full animate-pulse items-center rounded-lg bg-slate-100 p-4 text-muted"},Ou={container:"flex flex-col w-full",heading1:"mb-4 text-2xl font-bold text-grey-900 md:text-3xl lg:text-4xl",heading2:"mb-3 text-xl font-semibold text-grey-800 md:text-2xl lg:text-3xl",heading3:"mb-2 text-lg font-semibold text-grey-800 md:text-xl lg:text-2xl",paragraph:"mb-2 text-base leading-relaxed md:text-lg whitespace-pre-wrap",quote:"mb-4 border-l-4 border-grey-400 pl-4 text-lg italic text-grey-600",callout:"mb-4 flex gap-2 rounded-lg bg-main-50 p-4 text-grey-600",list:"pl-5 space-y-1",listItem:"ml-1 text-base md:text-lg",code:"mb-4 rounded-md bg-grey-100 p-4 font-mono text-sm",image:"rounded-lg overflow-hidden mb-2",divider:"my-6 border-t border-grey-300",table:"w-full border-collapse border border-grey-200",tableRow:"border-b border-grey-200",tableCell:"border border-grey-200 p-4 md:text-base text-sm",loading:"flex h-14 w-full animate-pulse items-center rounded-lg bg-slate-100 p-4 text-muted"},Du={container:"flex flex-col gap-0",heading1:"mb-4 text-xl font-bold text-grey-900 md:text-2xl lg:text-3xl",heading2:"mb-3 text-xl font-semibold text-grey-800 md:text-2xl lg:text-3xl",heading3:"mb-2 text-lg font-medium text-grey-800 md:text-xl lg:text-2xl",paragraph:"mb-4 text-base text-grey-800 leading-relaxed md:text-lg whitespace-pre-wrap",quote:"mb-4 border-l-4 border-grey-400 pl-4 text-lg italic text-grey-600",callout:"mb-4 flex gap-2 rounded-lg bg-grey-100 p-4 text-grey-600",list:"pl-5 space-y-2",listItem:"text-base md:text-lg text-grey-700 marker:text-main-600",code:"mb-4 rounded-md bg-grey-100 p-4 font-mono text-sm",image:"rounded-lg overflow-hidden w-full",divider:"my-6 border-t border-grey-300",table:"w-full border-collapse border border-grey-200",tableRow:"border-b border-grey-200",tableCell:"border border-grey-200 p-4 md:text-base text-sm",loading:"flex h-14 w-full animate-pulse items-center rounded-lg bg-slate-100 p-4 text-muted"},xr=e=>{switch(e){case"curriculum":return Au;case"article":return Ou;case"event":return Du;default:return Pu}},Iu={default:"",gray:"text-grey-500",brown:"text-yellow-900",orange:"text-orange-500",yellow:"text-yellow-500",green:"text-green-500",blue:"text-blue-500",purple:"text-purple-500",pink:"text-pink-500",red:"text-red-500"},bs={default:"",gray:"bg-grey-100",brown:"bg-yellow-100",orange:"bg-orange-100",yellow:"bg-yellow-100",green:"bg-green-100",blue:"bg-blue-100",purple:"bg-purple-100",pink:"bg-pink-100",red:"bg-red-100"},Fu=(e,t="default")=>{const n={id:"root",type:"root",children:[],parent:{},has_children:!0},i={root:n};e.forEach(a=>{a.children=[],i[a.id]=a});const r={};e.forEach(a=>{var c;const l=(c=a.parent)==null?void 0:c.block_id;l&&(r[l]||(r[l]=[]),r[l].push(a))});const s=new Set,o=[{block:n,priority:0}];return e.forEach(a=>{var h;if(s.has(a.id))return;const l=sa(a,t),c=(h=a.parent)==null?void 0:h.block_id,d=c?i[c]:null;if(l>0){for(;o.length>1&&o[o.length-1].priority<=l;)o.pop();const g={...a,children:[]};o[o.length-1].block.children.push(g),o.push({block:g,priority:l}),s.add(a.id)}else if(c&&d)d.children.push(a),s.add(a.id);else{const g={...a,children:[]};o[o.length-1].block.children.push(g),s.add(a.id);const u=r[a.id];u&&u.length>0&&(g.children=u,u.forEach(p=>s.add(p.id)))}}),n.children||[]},ra=["bulleted_list_item","numbered_list_item"],sa=(e,t="default")=>{var i;const n=(i=li[t])==null?void 0:i[e.type];return n!=null&&n.condition(e)?n.priority:0},Lu=(e,t="default")=>{var i;const n=(i=li[t])==null?void 0:i[e.type];return n!=null&&n.condition(e)?n.wrapper:Nu},oa=(e,t="default")=>{var i;const n=(i=li[t])==null?void 0:i[e.type];return!!(n!=null&&n.priority&&n.condition(e))};function Sr(e){const t=[];let n=[],i=null;const r=()=>{!i||n.length===0||(i==="block"?n.forEach(s=>t.push({type:"block",block:s})):i==="bulleted_list"?t.push({type:"bulleted_list",blocks:n}):i==="numbered_list"&&t.push({type:"numbered_list",blocks:n}),n=[],i=null)};for(const s of e){const o=s.type==="bulleted_list_item",a=s.type==="numbered_list_item",l=o?"bulleted_list":a?"numbered_list":"block";i===l?n.push(s):(r(),i=l,n=[s])}return r(),t}const ju=e=>e.includes("youtu.be")?"https://www.youtube.com/embed/"+e.split("/").pop():e.includes("youtube.com/watch")?"https://www.youtube.com/embed/"+e.split("v=")[1].split("&")[0]:e;function ku(e,t,n){const[i,r]=v.normalizeDates(n==null?void 0:n.in,e,t),s=ws(i,r),o=Math.abs(v.differenceInCalendarDays(i,r));i.setDate(i.getDate()-s*o);const a=+(ws(i,r)===-s),l=s*(o-a);return l===0?0:l}function ws(e,t){const n=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return n<0?-1:n>0?1:n}function Vu(e,t){const n=()=>v.constructFrom(t==null?void 0:t.in,NaN),r=Gu(e);let s;if(r.date){const c=zu(r.date,2);s=Hu(c.restDateString,c.year)}if(!s||isNaN(+s))return n();const o=+s;let a=0,l;if(r.time&&(a=Wu(r.time),isNaN(a)))return n();if(r.timezone){if(l=Ku(r.timezone),isNaN(l))return n()}else{const c=new Date(o+a),d=v.toDate(0,t==null?void 0:t.in);return d.setFullYear(c.getUTCFullYear(),c.getUTCMonth(),c.getUTCDate()),d.setHours(c.getUTCHours(),c.getUTCMinutes(),c.getUTCSeconds(),c.getUTCMilliseconds()),d}return v.toDate(o+a+l,t==null?void 0:t.in)}const Pn={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},Bu=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,$u=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,Uu=/^([+-])(\d{2})(?::?(\d{2}))?$/;function Gu(e){const t={},n=e.split(Pn.dateTimeDelimiter);let i;if(n.length>2)return t;if(/:/.test(n[0])?i=n[0]:(t.date=n[0],i=n[1],Pn.timeZoneDelimiter.test(t.date)&&(t.date=e.split(Pn.timeZoneDelimiter)[0],i=e.substr(t.date.length,e.length))),i){const r=Pn.timezone.exec(i);r?(t.time=i.replace(r[1],""),t.timezone=r[1]):t.time=i}return t}function zu(e,t){const n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),i=e.match(n);if(!i)return{year:NaN,restDateString:""};const r=i[1]?parseInt(i[1]):null,s=i[2]?parseInt(i[2]):null;return{year:s===null?r:s*100,restDateString:e.slice((i[1]||i[2]).length)}}function Hu(e,t){if(t===null)return new Date(NaN);const n=e.match(Bu);if(!n)return new Date(NaN);const i=!!n[4],r=Zt(n[1]),s=Zt(n[2])-1,o=Zt(n[3]),a=Zt(n[4]),l=Zt(n[5])-1;if(i)return Qu(t,a,l)?qu(t,a,l):new Date(NaN);{const c=new Date(0);return!Xu(t,s,o)||!Zu(t,r)?new Date(NaN):(c.setUTCFullYear(t,s,Math.max(r,o)),c)}}function Zt(e){return e?parseInt(e):1}function Wu(e){const t=e.match($u);if(!t)return NaN;const n=vi(t[1]),i=vi(t[2]),r=vi(t[3]);return Ju(n,i,r)?n*v.millisecondsInHour+i*v.millisecondsInMinute+r*1e3:NaN}function vi(e){return e&&parseFloat(e.replace(",","."))||0}function Ku(e){if(e==="Z")return 0;const t=e.match(Uu);if(!t)return 0;const n=t[1]==="+"?-1:1,i=parseInt(t[2]),r=t[3]&&parseInt(t[3])||0;return ed(i,r)?n*(i*v.millisecondsInHour+r*v.millisecondsInMinute):NaN}function qu(e,t,n){const i=new Date(0);i.setUTCFullYear(e,0,4);const r=i.getUTCDay()||7,s=(t-1)*7+n+1-r;return i.setUTCDate(i.getUTCDate()+s),i}const Yu=[31,null,31,30,31,30,31,31,30,31,30,31];function aa(e){return e%400===0||e%4===0&&e%100!==0}function Xu(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(Yu[t]||(aa(e)?29:28))}function Zu(e,t){return t>=1&&t<=(aa(e)?366:365)}function Qu(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}function Ju(e,t,n){return e===24?t===0&&n===0:n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}function ed(e,t){return t>=0&&t<=59}const qn=({src:e,alt:t,object:n="cover",lazy:i=!0,size:r="auto",className:s,...o})=>{const a={contain:"object-contain h-full",cover:"object-cover h-full",fill:"object-fill h-full","scale-down":"object-scale-down",none:"object-none"},l={full:"w-full",fit:"w-fit",auto:"w-auto"};let c="",d={};return typeof r=="string"?c=l[r]:typeof r=="number"&&(d={width:`${r}px`}),f.jsx("img",{src:e,alt:t?`${t} 이미지`:"이미지",loading:i?"lazy":"eager",className:T.cn(a[n],c,s),style:d,...o})};function td({adProduct:e,logo:t,title:n,batchName:i="",adTitle:r,startDate:s,tuition:o,nbCardRequired:a,isLoading:l=!1,regEndDate:c,className:d}){if(l)return f.jsx(ca,{className:d});const h=`${nd(s)} · ${id(o,a)}`;return f.jsx(la,{logo:t,title:`${n} ${i}`,adTitle:r,footerText:h,regEndDate:c,className:d,adProduct:e})}function la({adProduct:e,logo:t,title:n,adTitle:i,footerText:r,regEndDate:s,className:o}){return f.jsxs(v.FlexBox.Col,{className:T.cn("relative z-10 h-full w-full items-start justify-between gap-2 overflow-hidden rounded-xl border border-grey-200 bg-white p-4 text-grey-800 md:p-5 lg:p-6",o),children:[f.jsx(v.Tag,{variant:"ad",style:{background:Ce.adProducts.event.background,color:Ce.adProducts.event.color},children:e===Ce.adProducts.dDay.value&&s?sd(s):Ce.adProducts.event.value.toUpperCase()}),f.jsx(qn,{src:t,alt:`${n} 로고`,className:"h-4 object-contain"}),f.jsxs(v.FlexBox.Col,{className:"w-full gap-2",children:[f.jsx("h3",{className:"line-clamp-2 h-auto text-sm font-normal md:text-base lg:h-12",title:n,children:n}),f.jsx("p",{className:"line-clamp-2 h-auto w-full break-keep rounded bg-grey-100 px-2 py-1 text-[13px] font-semibold text-grey-600 md:h-[54px] md:text-[15px] md:text-grey-800",children:i}),f.jsx(v.Box,{className:"text-[13px] leading-[19px] text-grey-600",children:r})]})]})}function ca({className:e}){return f.jsxs(ne.Skeleton,{type:"background",className:T.cn("relative z-10 flex h-full w-full flex-col justify-between gap-2 overflow-hidden rounded-xl p-4 md:p-5 lg:p-6",e),children:[f.jsx(v.Tag,{variant:"ad",style:{background:Ce.adProducts.event.background,color:Ce.adProducts.event.color},className:T.cn("h-7 w-20 animate-pulse rounded-bl-lg rounded-br-none rounded-tl-none rounded-tr-lg px-2 py-1 text-sm"),children:""}),f.jsx(ne.Skeleton,{className:"h-4 w-1/2"}),f.jsxs(v.FlexBox.Col,{className:"gap-2",children:[f.jsx(v.Box,{className:"h-10 w-full",children:f.jsx(ne.Skeleton,{className:"h-5 w-4/5"})}),f.jsx(ne.Skeleton,{className:"h-14 w-full"})]}),f.jsx(ne.Skeleton,{className:"mt-2 h-[19px] w-2/3"})]})}const nd=e=>{if(!e)return"";const n=e.split(" ")[0].split("-"),i=Number(n[1]),r=`${i}/${Number(n.slice(2).join("."))}`;switch(n[2]){case"98":return`${i}월중 개강`;case"99":return`${i}월중(예상) 개강`;default:return`${r} 개강`}},id=(e,t)=>{const n=t?"(내배카💳)":"";return e===0||e===void 0?`무료 ${n}`:`유료 ${n}`},rd=e=>{const n=e.split(" ")[0].split("-"),i=Number(n[0]),r=Number(n[1]);let s=n[2];const o=new Date(i,r,0).getDate();return(isNaN(Number(s))||Number(s)>o)&&(s=o.toString()),`${i}-${String(r).padStart(2,"0")}-${String(s).padStart(2,"0")}`},sd=e=>{const t=ku(Vu(rd(e)),new Date);return t<=0?"마감임박":`D-${t}`},od={homepage:{label:"홈페이지",value:"homepage",query:!1},boottent:{label:"자세히보기",value:"boottent",query:!1},curriculum:{label:"커리큘럼 보기",value:"curriculum",query:"curriculum"},event:{label:"이벤트",value:"event",query:"event"},reviews:{label:"후기보기",value:"reviews",query:"reviews"}};var D={},zi={exports:{}};(function(e,t){(function(n,i){var r="1.0.40",s="",o="?",a="function",l="undefined",c="object",d="string",h="major",g="model",u="name",p="type",m="vendor",y="version",b="architecture",x="console",w="mobile",S="tablet",_="smarttv",C="wearable",k="embedded",F=500,Y="Amazon",Z="Apple",le="ASUS",fe="BlackBerry",me="Browser",ye="Chrome",de="Edge",be="Firefox",Q="Google",se="Huawei",ge="LG",ce="Microsoft",Ve="Motorola",Ae="Opera",E="Samsung",A="Sharp",H="Sony",q="Xiaomi",J="Zebra",Pe="Facebook",pe="Chromium OS",we="Mac OS",xe=" Browser",Fe=function(V,G){var j={};for(var X in V)G[X]&&G[X].length%2===0?j[X]=G[X].concat(V[X]):j[X]=V[X];return j},it=function(V){for(var G={},j=0;j<V.length;j++)G[V[j].toUpperCase()]=V[j];return G},_t=function(V,G){return typeof V===d?He(G).indexOf(He(V))!==-1:!1},He=function(V){return V.toLowerCase()},Ot=function(V){return typeof V===d?V.replace(/[^\d\.]/g,s).split(".")[0]:i},We=function(V,G){if(typeof V===d)return V=V.replace(/^\s\s*/,s),typeof G===l?V:V.substring(0,F)},Ke=function(V,G){for(var j=0,X,M,I,P,R,ee;j<G.length&&!R;){var Xe=G[j],It=G[j+1];for(X=M=0;X<Xe.length&&!R&&Xe[X];)if(R=Xe[X++].exec(V),R)for(I=0;I<It.length;I++)ee=R[++M],P=It[I],typeof P===c&&P.length>0?P.length===2?typeof P[1]==a?this[P[0]]=P[1].call(this,ee):this[P[0]]=P[1]:P.length===3?typeof P[1]===a&&!(P[1].exec&&P[1].test)?this[P[0]]=ee?P[1].call(this,ee,P[2]):i:this[P[0]]=ee?ee.replace(P[1],P[2]):i:P.length===4&&(this[P[0]]=ee?P[3].call(this,ee.replace(P[1],P[2])):i):this[P]=ee||i;j+=2}},Oe=function(V,G){for(var j in G)if(typeof G[j]===c&&G[j].length>0){for(var X=0;X<G[j].length;X++)if(_t(G[j][X],V))return j===o?i:j}else if(_t(G[j],V))return j===o?i:j;return G.hasOwnProperty("*")?G["*"]:V},Dt={"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"},rt={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2",8.1:"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},W={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[y,[u,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[y,[u,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[u,y],[/opios[\/ ]+([\w\.]+)/i],[y,[u,Ae+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[y,[u,Ae+" GX"]],[/\bopr\/([\w\.]+)/i],[y,[u,Ae]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[y,[u,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[y,[u,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[u,y],[/quark(?:pc)?\/([-\w\.]+)/i],[y,[u,"Quark"]],[/\bddg\/([\w\.]+)/i],[y,[u,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[y,[u,"UC"+me]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[y,[u,"WeChat"]],[/konqueror\/([\w\.]+)/i],[y,[u,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[y,[u,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[y,[u,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[y,[u,"Smart Lenovo "+me]],[/(avast|avg)\/([\w\.]+)/i],[[u,/(.+)/,"$1 Secure "+me],y],[/\bfocus\/([\w\.]+)/i],[y,[u,be+" Focus"]],[/\bopt\/([\w\.]+)/i],[y,[u,Ae+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[y,[u,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[y,[u,"Dolphin"]],[/coast\/([\w\.]+)/i],[y,[u,Ae+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[y,[u,"MIUI"+xe]],[/fxios\/([\w\.-]+)/i],[y,[u,be]],[/\bqihoobrowser\/?([\w\.]*)/i],[y,[u,"360"]],[/\b(qq)\/([\w\.]+)/i],[[u,/(.+)/,"$1Browser"],y],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[u,/(.+)/,"$1"+xe],y],[/samsungbrowser\/([\w\.]+)/i],[y,[u,E+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[y,[u,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[u,"Sogou Mobile"],y],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[u,y],[/(lbbrowser|rekonq)/i,/\[(linkedin)app\]/i],[u],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[y,u],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[u,Pe],y],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[u,y],[/\bgsa\/([\w\.]+) .*safari\//i],[y,[u,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[y,[u,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[y,[u,ye+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[u,ye+" WebView"],y],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[y,[u,"Android "+me]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[u,y],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[y,[u,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[y,u],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[u,[y,Oe,Dt]],[/(webkit|khtml)\/([\w\.]+)/i],[u,y],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[u,"Netscape"],y],[/(wolvic|librewolf)\/([\w\.]+)/i],[u,y],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[y,[u,be+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i],[u,[y,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[u,[y,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[b,"amd64"]],[/(ia32(?=;))/i],[[b,He]],[/((?:i[346]|x)86)[;\)]/i],[[b,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[b,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[b,"armhf"]],[/windows (ce|mobile); ppc;/i],[[b,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[b,/ower/,s,He]],[/(sun4\w)[;\)]/i],[[b,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[b,He]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[g,[m,E],[p,S]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[g,[m,E],[p,w]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[g,[m,Z],[p,w]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[g,[m,Z],[p,S]],[/(macintosh);/i],[g,[m,Z]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[g,[m,A],[p,w]],[/(?:honor)([-\w ]+)[;\)]/i],[g,[m,"Honor"],[p,w]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[g,[m,se],[p,S]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[g,[m,se],[p,w]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i],[[g,/_/g," "],[m,q],[p,w]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[g,/_/g," "],[m,q],[p,S]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[g,[m,"OPPO"],[p,w]],[/\b(opd2\d{3}a?) bui/i],[g,[m,"OPPO"],[p,S]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[g,[m,"Vivo"],[p,w]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[g,[m,"Realme"],[p,w]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[g,[m,Ve],[p,w]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[g,[m,Ve],[p,S]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[g,[m,ge],[p,S]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[g,[m,ge],[p,w]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[g,[m,"Lenovo"],[p,S]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[g,/_/g," "],[m,"Nokia"],[p,w]],[/(pixel c)\b/i],[g,[m,Q],[p,S]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[g,[m,Q],[p,w]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[g,[m,H],[p,w]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[g,"Xperia Tablet"],[m,H],[p,S]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[g,[m,"OnePlus"],[p,w]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[g,[m,Y],[p,S]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[g,/(.+)/g,"Fire Phone $1"],[m,Y],[p,w]],[/(playbook);[-\w\),; ]+(rim)/i],[g,m,[p,S]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[g,[m,fe],[p,w]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[g,[m,le],[p,S]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[g,[m,le],[p,w]],[/(nexus 9)/i],[g,[m,"HTC"],[p,S]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[m,[g,/_/g," "],[p,w]],[/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])\w*(\)| bui)/i],[g,[m,"TCL"],[p,S]],[/(itel) ((\w+))/i],[[m,He],g,[p,Oe,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[g,[m,"Acer"],[p,S]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[g,[m,"Meizu"],[p,w]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[g,[m,"Ulefone"],[p,w]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[g,[m,"Energizer"],[p,w]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[g,[m,"Cat"],[p,w]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[g,[m,"Smartfren"],[p,w]],[/droid.+; (a(?:015|06[35]|142p?))/i],[g,[m,"Nothing"],[p,w]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (imo) ((?!tab)[\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[m,g,[p,w]],[/(imo) (tab \w+)/i,/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[m,g,[p,S]],[/(surface duo)/i],[g,[m,ce],[p,S]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[g,[m,"Fairphone"],[p,w]],[/(u304aa)/i],[g,[m,"AT&T"],[p,w]],[/\bsie-(\w*)/i],[g,[m,"Siemens"],[p,w]],[/\b(rct\w+) b/i],[g,[m,"RCA"],[p,S]],[/\b(venue[\d ]{2,7}) b/i],[g,[m,"Dell"],[p,S]],[/\b(q(?:mv|ta)\w+) b/i],[g,[m,"Verizon"],[p,S]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[g,[m,"Barnes & Noble"],[p,S]],[/\b(tm\d{3}\w+) b/i],[g,[m,"NuVision"],[p,S]],[/\b(k88) b/i],[g,[m,"ZTE"],[p,S]],[/\b(nx\d{3}j) b/i],[g,[m,"ZTE"],[p,w]],[/\b(gen\d{3}) b.+49h/i],[g,[m,"Swiss"],[p,w]],[/\b(zur\d{3}) b/i],[g,[m,"Swiss"],[p,S]],[/\b((zeki)?tb.*\b) b/i],[g,[m,"Zeki"],[p,S]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[m,"Dragon Touch"],g,[p,S]],[/\b(ns-?\w{0,9}) b/i],[g,[m,"Insignia"],[p,S]],[/\b((nxa|next)-?\w{0,9}) b/i],[g,[m,"NextBook"],[p,S]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[m,"Voice"],g,[p,w]],[/\b(lvtel\-)?(v1[12]) b/i],[[m,"LvTel"],g,[p,w]],[/\b(ph-1) /i],[g,[m,"Essential"],[p,w]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[g,[m,"Envizen"],[p,S]],[/\b(trio[-\w\. ]+) b/i],[g,[m,"MachSpeed"],[p,S]],[/\btu_(1491) b/i],[g,[m,"Rotor"],[p,S]],[/(shield[\w ]+) b/i],[g,[m,"Nvidia"],[p,S]],[/(sprint) (\w+)/i],[m,g,[p,w]],[/(kin\.[onetw]{3})/i],[[g,/\./g," "],[m,ce],[p,w]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[g,[m,J],[p,S]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[g,[m,J],[p,w]],[/smart-tv.+(samsung)/i],[m,[p,_]],[/hbbtv.+maple;(\d+)/i],[[g,/^/,"SmartTV"],[m,E],[p,_]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[m,ge],[p,_]],[/(apple) ?tv/i],[m,[g,Z+" TV"],[p,_]],[/crkey/i],[[g,ye+"cast"],[m,Q],[p,_]],[/droid.+aft(\w+)( bui|\))/i],[g,[m,Y],[p,_]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[g,[m,A],[p,_]],[/(bravia[\w ]+)( bui|\))/i],[g,[m,H],[p,_]],[/(mitv-\w{5}) bui/i],[g,[m,q],[p,_]],[/Hbbtv.*(technisat) (.*);/i],[m,g,[p,_]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[m,We],[g,We],[p,_]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[p,_]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[m,g,[p,x]],[/droid.+; (shield) bui/i],[g,[m,"Nvidia"],[p,x]],[/(playstation [345portablevi]+)/i],[g,[m,H],[p,x]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[g,[m,ce],[p,x]],[/\b(sm-[lr]\d\d[05][fnuw]?s?)\b/i],[g,[m,E],[p,C]],[/((pebble))app/i],[m,g,[p,C]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[g,[m,Z],[p,C]],[/droid.+; (glass) \d/i],[g,[m,Q],[p,C]],[/droid.+; (wt63?0{2,3})\)/i],[g,[m,J],[p,C]],[/droid.+; (glass) \d/i],[g,[m,Q],[p,C]],[/(pico) (4|neo3(?: link|pro)?)/i],[m,g,[p,C]],[/; (quest( \d| pro)?)/i],[g,[m,Pe],[p,C]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[m,[p,k]],[/(aeobc)\b/i],[g,[m,Y],[p,k]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[g,[p,w]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[g,[p,S]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[p,S]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[p,w]],[/(android[-\w\. ]{0,9});.+buil/i],[g,[m,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[y,[u,de+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[u,y],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[y,[u,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[u,y],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[y,u]],os:[[/microsoft (windows) (vista|xp)/i],[u,y],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[u,[y,Oe,rt]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[y,Oe,rt],[u,"Windows"]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[y,/_/g,"."],[u,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[u,we],[y,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[y,u],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish|openharmony)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[u,y],[/\(bb(10);/i],[y,[u,fe]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[y,[u,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[y,[u,be+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[y,[u,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[y,[u,"watchOS"]],[/crkey\/([\d\.]+)/i],[y,[u,ye+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[u,pe],y],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[u,y],[/(sunos) ?([\w\.\d]*)/i],[[u,"Solaris"],y],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[u,y]]},N=function(V,G){if(typeof V===c&&(G=V,V=i),!(this instanceof N))return new N(V,G).getResult();var j=typeof n!==l&&n.navigator?n.navigator:i,X=V||(j&&j.userAgent?j.userAgent:s),M=j&&j.userAgentData?j.userAgentData:i,I=G?Fe(W,G):W,P=j&&j.userAgent==X;return this.getBrowser=function(){var R={};return R[u]=i,R[y]=i,Ke.call(R,X,I.browser),R[h]=Ot(R[y]),P&&j&&j.brave&&typeof j.brave.isBrave==a&&(R[u]="Brave"),R},this.getCPU=function(){var R={};return R[b]=i,Ke.call(R,X,I.cpu),R},this.getDevice=function(){var R={};return R[m]=i,R[g]=i,R[p]=i,Ke.call(R,X,I.device),P&&!R[p]&&M&&M.mobile&&(R[p]=w),P&&R[g]=="Macintosh"&&j&&typeof j.standalone!==l&&j.maxTouchPoints&&j.maxTouchPoints>2&&(R[g]="iPad",R[p]=S),R},this.getEngine=function(){var R={};return R[u]=i,R[y]=i,Ke.call(R,X,I.engine),R},this.getOS=function(){var R={};return R[u]=i,R[y]=i,Ke.call(R,X,I.os),P&&!R[u]&&M&&M.platform&&M.platform!="Unknown"&&(R[u]=M.platform.replace(/chrome os/i,pe).replace(/macos/i,we)),R},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return X},this.setUA=function(R){return X=typeof R===d&&R.length>F?We(R,F):R,this},this.setUA(X),this};N.VERSION=r,N.BROWSER=it([u,y,h]),N.CPU=it([b]),N.DEVICE=it([g,m,p,x,w,_,S,C,k]),N.ENGINE=N.OS=it([u,y]),e.exports&&(t=e.exports=N),t.UAParser=N;var L=typeof n!==l&&(n.jQuery||n.Zepto);if(L&&!L.ua){var K=new N;L.ua=K.getResult(),L.ua.get=function(){return K.getUA()},L.ua.set=function(V){K.setUA(V);var G=K.getResult();for(var j in G)L.ua[j]=G[j]}}})(typeof window=="object"?window:v.commonjsGlobal)})(zi,zi.exports);var ad=zi.exports;Object.defineProperty(D,"__esModule",{value:!0});function ld(e){return e&&typeof e=="object"&&"default"in e?e.default:e}var Re=O,ie=ld(Re),ua=ad,vt=new ua,Ne=vt.getBrowser(),cd=vt.getCPU(),ke=vt.getDevice(),_r=vt.getEngine(),bt=vt.getOS(),xn=vt.getUA(),da=function(t){return vt.setUA(t)},Sn=function(t){if(!t){console.error("No userAgent string was provided");return}var n=new ua(t);return{UA:n,browser:n.getBrowser(),cpu:n.getCPU(),device:n.getDevice(),engine:n.getEngine(),os:n.getOS(),ua:n.getUA(),setUserAgent:function(r){return n.setUA(r)}}},ga=Object.freeze({ClientUAInstance:vt,browser:Ne,cpu:cd,device:ke,engine:_r,os:bt,ua:xn,setUa:da,parseUserAgent:Sn});function xs(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),n.push.apply(n,i)}return n}function ud(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?xs(Object(n),!0).forEach(function(i){pd(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xs(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}function sn(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?sn=function(t){return typeof t}:sn=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sn(e)}function dd(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function gd(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function fd(e,t,n){return t&&gd(e.prototype,t),e}function pd(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hi(){return Hi=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Hi.apply(this,arguments)}function hd(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ki(e,t)}function Wi(e){return Wi=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Wi(e)}function Ki(e,t){return Ki=Object.setPrototypeOf||function(i,r){return i.__proto__=r,i},Ki(e,t)}function md(e,t){if(e==null)return{};var n={},i=Object.keys(e),r,s;for(s=0;s<i.length;s++)r=i[s],!(t.indexOf(r)>=0)&&(n[r]=e[r]);return n}function ze(e,t){if(e==null)return{};var n=md(e,t),i,r;if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(r=0;r<s.length;r++)i=s[r],!(t.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(e,i)&&(n[i]=e[i])}return n}function Un(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yd(e,t){if(t&&(typeof t=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Un(e)}function vd(e,t){return bd(e)||wd(e,t)||xd(e,t)||Sd()}function bd(e){if(Array.isArray(e))return e}function wd(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var i=[],r=!0,s=!1,o,a;try{for(n=n.call(e);!(r=(o=n.next()).done)&&(i.push(o.value),!(t&&i.length===t));r=!0);}catch(l){s=!0,a=l}finally{try{!r&&n.return!=null&&n.return()}finally{if(s)throw a}}return i}}function xd(e,t){if(e){if(typeof e=="string")return Ss(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ss(e,t)}}function Ss(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function Sd(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
2
2
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Ee={Mobile:"mobile",Tablet:"tablet",SmartTv:"smarttv",Console:"console",Wearable:"wearable",Embedded:"embedded",Browser:void 0},Ie={Chrome:"Chrome",Firefox:"Firefox",Opera:"Opera",Yandex:"Yandex",Safari:"Safari",InternetExplorer:"Internet Explorer",Edge:"Edge",Chromium:"Chromium",Ie:"IE",MobileSafari:"Mobile Safari",EdgeChromium:"Edge Chromium",MIUI:"MIUI Browser",SamsungBrowser:"Samsung Browser"},Kt={IOS:"iOS",Android:"Android",WindowsPhone:"Windows Phone",Windows:"Windows",MAC_OS:"Mac OS"},_d={isMobile:!1,isTablet:!1,isBrowser:!1,isSmartTV:!1,isConsole:!1,isWearable:!1},Ed=function(t){switch(t){case Ee.Mobile:return{isMobile:!0};case Ee.Tablet:return{isTablet:!0};case Ee.SmartTv:return{isSmartTV:!0};case Ee.Console:return{isConsole:!0};case Ee.Wearable:return{isWearable:!0};case Ee.Browser:return{isBrowser:!0};case Ee.Embedded:return{isEmbedded:!0};default:return _d}},Cd=function(t){return da(t)},z=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"none";return t||n},Er=function(){return typeof window<"u"&&(window.navigator||navigator)?window.navigator||navigator:!1},Cr=function(t){var n=Er();return n&&n.platform&&(n.platform.indexOf(t)!==-1||n.platform==="MacIntel"&&n.maxTouchPoints>1&&!window.MSStream)},Td=function(t,n,i,r,s){return{isBrowser:t,browserMajorVersion:z(n.major),browserFullVersion:z(n.version),browserName:z(n.name),engineName:z(i.name),engineVersion:z(i.version),osName:z(r.name),osVersion:z(r.version),userAgent:z(s)}},_s=function(t,n,i,r){return ud({},t,{vendor:z(n.vendor),model:z(n.model),os:z(i.name),osVersion:z(i.version),ua:z(r)})},Rd=function(t,n,i,r){return{isSmartTV:t,engineName:z(n.name),engineVersion:z(n.version),osName:z(i.name),osVersion:z(i.version),userAgent:z(r)}},Nd=function(t,n,i,r){return{isConsole:t,engineName:z(n.name),engineVersion:z(n.version),osName:z(i.name),osVersion:z(i.version),userAgent:z(r)}},Md=function(t,n,i,r){return{isWearable:t,engineName:z(n.name),engineVersion:z(n.version),osName:z(i.name),osVersion:z(i.version),userAgent:z(r)}},Pd=function(t,n,i,r,s){return{isEmbedded:t,vendor:z(n.vendor),model:z(n.model),engineName:z(i.name),engineVersion:z(i.version),osName:z(r.name),osVersion:z(r.version),userAgent:z(s)}};function Ad(e){var t=e?Sn(e):ga,n=t.device,i=t.browser,r=t.engine,s=t.os,o=t.ua,a=Ed(n.type),l=a.isBrowser,c=a.isMobile,d=a.isTablet,h=a.isSmartTV,g=a.isConsole,u=a.isWearable,p=a.isEmbedded;if(l)return Td(l,i,r,s,o);if(h)return Rd(h,r,s,o);if(g)return Nd(g,r,s,o);if(c||d)return _s(a,n,s,o);if(u)return Md(u,r,s,o);if(p)return Pd(p,n,r,s,o)}var fa=function(t){var n=t.type;return n===Ee.Mobile},pa=function(t){var n=t.type;return n===Ee.Tablet},ha=function(t){var n=t.type;return n===Ee.Mobile||n===Ee.Tablet},ma=function(t){var n=t.type;return n===Ee.SmartTv},Yn=function(t){var n=t.type;return n===Ee.Browser},ya=function(t){var n=t.type;return n===Ee.Wearable},va=function(t){var n=t.type;return n===Ee.Console},ba=function(t){var n=t.type;return n===Ee.Embedded},wa=function(t){var n=t.vendor;return z(n)},xa=function(t){var n=t.model;return z(n)},Sa=function(t){var n=t.type;return z(n,"browser")},_a=function(t){var n=t.name;return n===Kt.Android},Ea=function(t){var n=t.name;return n===Kt.Windows},Ca=function(t){var n=t.name;return n===Kt.MAC_OS},Ta=function(t){var n=t.name;return n===Kt.WindowsPhone},Ra=function(t){var n=t.name;return n===Kt.IOS},Na=function(t){var n=t.version;return z(n)},Ma=function(t){var n=t.name;return z(n)},Pa=function(t){var n=t.name;return n===Ie.Chrome},Aa=function(t){var n=t.name;return n===Ie.Firefox},Oa=function(t){var n=t.name;return n===Ie.Chromium},Xn=function(t){var n=t.name;return n===Ie.Edge},Da=function(t){var n=t.name;return n===Ie.Yandex},Ia=function(t){var n=t.name;return n===Ie.Safari||n===Ie.MobileSafari},Fa=function(t){var n=t.name;return n===Ie.MobileSafari},La=function(t){var n=t.name;return n===Ie.Opera},ja=function(t){var n=t.name;return n===Ie.InternetExplorer||n===Ie.Ie},ka=function(t){var n=t.name;return n===Ie.MIUI},Va=function(t){var n=t.name;return n===Ie.SamsungBrowser},Ba=function(t){var n=t.version;return z(n)},$a=function(t){var n=t.major;return z(n)},Ua=function(t){var n=t.name;return z(n)},Ga=function(t){var n=t.name;return z(n)},za=function(t){var n=t.version;return z(n)},Ha=function(){var t=Er(),n=t&&t.userAgent&&t.userAgent.toLowerCase();return typeof n=="string"?/electron/.test(n):!1},Ut=function(t){return typeof t=="string"&&t.indexOf("Edg/")!==-1},Wa=function(){var t=Er();return t&&(/iPad|iPhone|iPod/.test(t.platform)||t.platform==="MacIntel"&&t.maxTouchPoints>1)&&!window.MSStream},Qe=function(){return Cr("iPad")},Ka=function(){return Cr("iPhone")},qa=function(){return Cr("iPod")},Ya=function(t){return z(t)};function Xa(e){var t=e||ga,n=t.device,i=t.browser,r=t.os,s=t.engine,o=t.ua;return{isSmartTV:ma(n),isConsole:va(n),isWearable:ya(n),isEmbedded:ba(n),isMobileSafari:Fa(i)||Qe(),isChromium:Oa(i),isMobile:ha(n)||Qe(),isMobileOnly:fa(n),isTablet:pa(n)||Qe(),isBrowser:Yn(n),isDesktop:Yn(n),isAndroid:_a(r),isWinPhone:Ta(r),isIOS:Ra(r)||Qe(),isChrome:Pa(i),isFirefox:Aa(i),isSafari:Ia(i),isOpera:La(i),isIE:ja(i),osVersion:Na(r),osName:Ma(r),fullBrowserVersion:Ba(i),browserVersion:$a(i),browserName:Ua(i),mobileVendor:wa(n),mobileModel:xa(n),engineName:Ga(s),engineVersion:za(s),getUA:Ya(o),isEdge:Xn(i)||Ut(o),isYandex:Da(i),deviceType:Sa(n),isIOS13:Wa(),isIPad13:Qe(),isIPhone13:Ka(),isIPod13:qa(),isElectron:Ha(),isEdgeChromium:Ut(o),isLegacyEdge:Xn(i)&&!Ut(o),isWindows:Ea(r),isMacOs:Ca(r),isMIUI:ka(i),isSamsungBrowser:Va(i)}}var Za=ma(ke),Qa=va(ke),Ja=ya(ke),Od=ba(ke),Dd=Fa(Ne)||Qe(),Id=Oa(Ne),ci=ha(ke)||Qe(),el=fa(ke),tl=pa(ke)||Qe(),nl=Yn(ke),Fd=Yn(ke),il=_a(bt),rl=Ta(bt),sl=Ra(bt)||Qe(),Ld=Pa(Ne),jd=Aa(Ne),kd=Ia(Ne),Vd=La(Ne),ol=ja(Ne),Bd=Na(bt),$d=Ma(bt),Ud=Ba(Ne),Gd=$a(Ne),zd=Ua(Ne),Hd=wa(ke),Wd=xa(ke),Kd=Ga(_r),qd=za(_r),Yd=Ya(xn),Xd=Xn(Ne)||Ut(xn),Zd=Da(Ne),Qd=Sa(ke),Jd=Wa(),eg=Qe(),tg=Ka(),ng=qa(),ig=Ha(),rg=Ut(xn),sg=Xn(Ne)&&!Ut(xn),og=Ea(bt),ag=Ca(bt),lg=ka(Ne),cg=Va(Ne),ug=function(t){if(!t||typeof t!="string"){console.error("No valid user agent string was provided");return}var n=Sn(t),i=n.device,r=n.browser,s=n.os,o=n.engine,a=n.ua;return Xa({device:i,browser:r,os:s,engine:o,ua:a})},dg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return il?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},gg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return nl?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},fg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return ol?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},pg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return sl?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},hg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return ci?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},mg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return tl?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},yg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return rl?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},vg=function(t){var n=t.renderWithFragment,i=t.children;t.viewClassName,t.style;var r=ze(t,["renderWithFragment","children","viewClassName","style"]);return el?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},bg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return Za?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},wg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return Qa?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},xg=function(t){var n=t.renderWithFragment,i=t.children,r=ze(t,["renderWithFragment","children"]);return Ja?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",r,i):null},Sg=function(t){var n=t.renderWithFragment,i=t.children;t.viewClassName,t.style;var r=t.condition,s=ze(t,["renderWithFragment","children","viewClassName","style","condition"]);return r?n?ie.createElement(Re.Fragment,null,i):ie.createElement("div",s,i):null};function _g(e){return function(t){hd(n,t);function n(i){var r;return dd(this,n),r=yd(this,Wi(n).call(this,i)),r.isEventListenerAdded=!1,r.handleOrientationChange=r.handleOrientationChange.bind(Un(r)),r.onOrientationChange=r.onOrientationChange.bind(Un(r)),r.onPageLoad=r.onPageLoad.bind(Un(r)),r.state={isLandscape:!1,isPortrait:!1},r}return fd(n,[{key:"handleOrientationChange",value:function(){this.isEventListenerAdded||(this.isEventListenerAdded=!0);var r=window.innerWidth>window.innerHeight?90:0;this.setState({isPortrait:r===0,isLandscape:r===90})}},{key:"onOrientationChange",value:function(){this.handleOrientationChange()}},{key:"onPageLoad",value:function(){this.handleOrientationChange()}},{key:"componentDidMount",value:function(){(typeof window>"u"?"undefined":sn(window))!==void 0&&ci&&(this.isEventListenerAdded?window.removeEventListener("load",this.onPageLoad,!1):(this.handleOrientationChange(),window.addEventListener("load",this.onPageLoad,!1)),window.addEventListener("resize",this.onOrientationChange,!1))}},{key:"componentWillUnmount",value:function(){window.removeEventListener("resize",this.onOrientationChange,!1)}},{key:"render",value:function(){return ie.createElement(e,Hi({},this.props,{isLandscape:this.state.isLandscape,isPortrait:this.state.isPortrait}))}}]),n}(ie.Component)}function Eg(){var e=Re.useState(function(){var s=window.innerWidth>window.innerHeight?90:0;return{isPortrait:s===0,isLandscape:s===90,orientation:s===0?"portrait":"landscape"}}),t=vd(e,2),n=t[0],i=t[1],r=Re.useCallback(function(){var s=window.innerWidth>window.innerHeight?90:0,o={isPortrait:s===0,isLandscape:s===90,orientation:s===0?"portrait":"landscape"};n.orientation!==o.orientation&&i(o)},[n.orientation]);return Re.useEffect(function(){return(typeof window>"u"?"undefined":sn(window))!==void 0&&ci&&(r(),window.addEventListener("load",r,!1),window.addEventListener("resize",r,!1)),function(){window.removeEventListener("resize",r,!1),window.removeEventListener("load",r,!1)}},[r]),n}function al(e){var t=e||window.navigator.userAgent;return Sn(t)}function Cg(e){var t=e||window.navigator.userAgent,n=al(t),i=Xa(n);return[i,n]}D.AndroidView=dg;D.BrowserTypes=Ie;D.BrowserView=gg;D.ConsoleView=wg;D.CustomView=Sg;D.IEView=fg;D.IOSView=pg;D.MobileOnlyView=vg;D.MobileView=hg;D.OsTypes=Kt;D.SmartTVView=bg;D.TabletView=mg;D.WearableView=xg;D.WinPhoneView=yg;D.browserName=zd;D.browserVersion=Gd;D.deviceDetect=Ad;D.deviceType=Qd;D.engineName=Kd;D.engineVersion=qd;D.fullBrowserVersion=Ud;D.getSelectorsByUserAgent=ug;D.getUA=Yd;D.isAndroid=il;D.isBrowser=nl;D.isChrome=Ld;D.isChromium=Id;D.isConsole=Qa;D.isDesktop=Fd;D.isEdge=Xd;D.isEdgeChromium=rg;D.isElectron=ig;D.isEmbedded=Od;D.isFirefox=jd;D.isIE=ol;D.isIOS=sl;D.isIOS13=Jd;D.isIPad13=eg;D.isIPhone13=tg;D.isIPod13=ng;D.isLegacyEdge=sg;D.isMIUI=lg;D.isMacOs=ag;var en=D.isMobile=ci;D.isMobileOnly=el;D.isMobileSafari=Dd;D.isOpera=Vd;D.isSafari=kd;D.isSamsungBrowser=cg;D.isSmartTV=Za;D.isTablet=tl;D.isWearable=Ja;D.isWinPhone=rl;D.isWindows=og;D.isYandex=Zd;D.mobileModel=Wd;D.mobileVendor=Hd;D.osName=$d;D.osVersion=Bd;D.parseUserAgent=Sn;D.setUserAgent=Cd;D.useDeviceData=al;D.useDeviceSelectors=Cg;D.useMobileOrientation=Eg;D.withOrientationChange=_g;function Tg({adKey:e,filename:t,title:n,backgroundColor:i,hideButton:r=!1,buttonColors:s,linkType:o="homepage",isLoading:a=!1,className:l}){var u;const c=e&&t,d=`https://cdn.sayun.studio/boottent/images/banners/${e}/${t}`,h={background:s?s.button:Ce.defaultBannerColor.button,color:s?s.buttonText:Ce.defaultBannerColor.buttonText,border:s?s.button:Ce.defaultBannerColor.button},g=a?ne.Skeleton:v.Box;return f.jsx(g,{style:{backgroundColor:a?void 0:i},type:a?"background":void 0,className:T.cn("relative h-40 w-full overflow-hidden md:h-[200px]",a?"bg-white":"border-y border-y-grey-200",l),children:a?f.jsx(ll,{}):f.jsx(f.Fragment,{children:f.jsxs(v.FlexBox.Row,{className:"absolute inset-0 mx-auto h-full w-full max-w-screen-xl px-0 pb-6 pt-0 md:h-auto md:px-6 md:pb-0 md:pt-10 lg:px-10 lg:pt-6",children:[c?f.jsx("div",{className:"mx-auto flex h-full w-full items-center md:items-start",children:f.jsx("img",{loading:"lazy",src:d,alt:`${n} 이미지`,className:"h-auto max-h-[136px] w-full object-contain md:max-h-40 lg:max-h-[176px]"})}):f.jsx(v.Box,{className:"h-full w-full bg-grey-100 text-muted",children:n}),!r&&f.jsx(v.Box,{className:"absolute inset-0 mx-auto max-w-screen-xl px-4 md:px-6 lg:px-10",children:f.jsx(v.Button,{style:h,theme:"etc",variant:"solid",size:en?"sm":"md",className:"absolute bottom-4 right-4 h-9 w-24 md:bottom-6 md:right-6 md:h-11 md:w-32 lg:bottom-4 lg:right-10",children:((u=od[o])==null?void 0:u.label)+" →"||"홈페이지 →"})})]})})})}function ll(){return f.jsxs(v.FlexBox.Col,{className:"relative mx-auto flex h-full w-full max-w-screen-xl items-start gap-5 px-4 pt-4 md:px-6 md:pt-10 lg:px-10",children:[f.jsx(ne.Skeleton,{type:"text",className:"h-6 w-4/5 rounded-xl md:h-10"}),f.jsx(ne.Skeleton,{type:"text",className:"h-10 w-1/2 rounded-xl md:h-16 lg:w-3/5"}),f.jsx(ne.Skeleton,{type:"text",className:"absolute bottom-4 right-4 aspect-[3/1] w-[120px] shrink-0 md:right-6 md:w-[140px] lg:right-10"})]})}const Rg=({logo:e,title:t,subtitle:n,thumbnail:i,batchTitle:r,batchName:s="",brandName:o,tag:a,isLoading:l=!1,className:c})=>{const d=l?ne.Skeleton:v.Box;return f.jsxs(d,{title:t,type:"background",className:T.cn("xs:h-full relative z-10 box-border h-[154px] w-full max-w-[720px] cursor-pointer overflow-hidden rounded-xl bg-white p-4 md:h-[174px] md:max-w-[592px] md:p-5 lg:h-[174px] lg:p-6 xl:h-[174px]",l?"":"border border-grey-200",c),children:[f.jsx(v.Tag,{variant:"ad",style:{background:Ce.adProducts.premiumCard.background,color:Ce.adProducts.premiumCard.color},className:T.cn(l&&"h-7 w-28 animate-pulse"),children:l?"":a}),l?f.jsx(Mg,{}):f.jsx(Ng,{logo:e,brandName:o,batchTitle:r,batchName:s,subtitle:n,thumbnail:i})]})},Ng=({logo:e,brandName:t,batchTitle:n,batchName:i,subtitle:r,thumbnail:s})=>f.jsxs(v.FlexBox.Col,{className:"h-full justify-start gap-2",children:[f.jsx(qn,{src:e,alt:`${t} 로고`,className:"h-4 object-contain"}),f.jsxs(v.FlexBox.Row,{className:"w-full items-start justify-between gap-6",children:[f.jsxs(v.FlexBox.Col,{className:"flex h-full grow flex-col justify-between gap-2 pb-2",children:[f.jsxs("h3",{className:"line-clamp-2 h-auto text-sm font-normal md:h-12 md:text-base",title:`${t} ${n} ${i}`,children:[n," ",i]}),f.jsx("h4",{className:"line-clamp-2 max-h-[56px] w-full break-keep rounded bg-grey-100 px-2 py-1 text-[13px] font-semibold text-grey-600 md:text-[15px] md:text-grey-800",title:r,children:r})]}),f.jsx(qn,{src:s,alt:`${n} 썸네일`,className:"h-[86px] w-[86px] shrink-0 grow-0 rounded-xl border border-grey-200 object-cover md:h-[96px] md:w-[96px]"})]})]}),Mg=()=>f.jsxs(v.FlexBox.Col,{className:"h-full justify-center gap-2",children:[f.jsx(ne.Skeleton,{className:"h-4 w-1/2"}),f.jsxs(v.FlexBox.Row,{className:"w-full items-start justify-between gap-6",children:[f.jsxs(v.FlexBox.Col,{className:"flex h-full w-full flex-col justify-between gap-2 pb-2",children:[f.jsx(ne.Skeleton,{className:"h-5 w-4/5 lg:h-12"}),f.jsx(ne.Skeleton,{className:"h-5 w-4/5"})]}),f.jsx(ne.Skeleton,{className:"h-[86px] w-[86px] shrink-0 grow-0 rounded-xl md:h-[96px] md:w-[96px]"})]})]}),Pg=({tags:e,coverImage:t,brandName:n,title:i,batchName:r="",titleTagType:s,adTitle:o,changedAspect:a="aspect-[8/5]",isLoading:l=!1,className:c})=>l?f.jsx(Ag,{changedAspect:a,className:c,titleTagType:s}):f.jsxs(v.FlexBox.Col,{className:T.cn("shadow-base h-full w-full shrink-0 cursor-pointer overflow-hidden rounded-xl border border-grey-700 bg-white transition-all",c),children:[f.jsxs(v.Box,{style:{background:"linear-gradient(0deg, rgba(24, 25, 25, 0.00) 17.43%, #181919 91.02%)"},className:`relative flex ${a} w-full flex-col items-center justify-center overflow-hidden`,children:[f.jsx(qn,{src:t,alt:`${n} ${i} ${r} 이미지`,className:"h-full w-full object-cover"}),s&&f.jsx(v.Tag,{variant:"ad",style:{background:Ce.adProducts.titleTag.background,color:Ce.adProducts.titleTag.color},children:s}),o&&f.jsxs(f.Fragment,{children:[f.jsx(v.Box,{className:"absolute left-4 top-4 z-10 w-36 whitespace-pre-wrap break-keep text-[18px] font-semibold text-white md:left-5 md:top-7",children:o}),f.jsx(v.Box,{className:"absolute inset-0 opacity-50",style:{background:"linear-gradient(270deg, rgba(24, 25, 25, 0.00) 17.43%, #181919 91.02%)"}})]})]}),f.jsxs(v.FlexBox.Col,{className:"w-full justify-between gap-2 p-4 text-grey-800 md:p-5 lg:p-6",children:[f.jsxs("h4",{className:"flex flex-col gap-2",title:`${n} ${i} ${r}`,children:[f.jsx("p",{className:"text-sm",children:n}),f.jsx("p",{className:"truncate3 break-keep text-base font-semibold",children:`${i} ${r}`})]}),e&&f.jsx("ul",{className:"flex w-full max-w-full flex-wrap gap-1",children:e.map((d,h)=>{var u;const g=Object.values(Ce.campCategoryColors).find(p=>p.tags.some(m=>m.value===d));return g&&f.jsx("li",{children:f.jsx(v.Tag,{size:"sm",style:{background:g.background,color:g.color},children:(u=g.tags.find(p=>p.value===d))==null?void 0:u.text})},h)})})]})]}),Ag=({changedAspect:e,className:t,titleTagType:n})=>f.jsxs(ne.Skeleton,{type:"background",className:T.cn("relative h-full w-full shrink-0 cursor-pointer overflow-hidden rounded-xl bg-grey-50 transition-all",t),children:[n&&f.jsx(v.Tag,{variant:"ad",style:{background:Ce.adProducts.titleTag.background,color:Ce.adProducts.titleTag.color},className:T.cn("h-7 w-28 animate-pulse rounded-bl-lg rounded-br-none rounded-tl-none rounded-tr-lg px-2 py-1 text-sm"),children:""}),f.jsx(v.Box,{style:{background:"linear-gradient(270deg, rgba(24, 25, 25, 0.00) 17.43%, #181919 91.02%)"},className:`relative flex ${e} w-full`,children:f.jsx(ne.Skeleton,{className:"h-full w-full",type:"background"})}),f.jsxs(v.FlexBox.Col,{className:"w-full justify-between gap-2 p-4",children:[f.jsxs(v.FlexBox.Col,{className:"relative w-full gap-2",children:[f.jsx(ne.Skeleton,{className:"h-5 w-1/2",type:"text"}),f.jsx(ne.Skeleton,{className:"h-12 w-full",type:"text"})]}),f.jsxs(v.FlexBox.Row,{className:"w-full gap-1",children:[f.jsx(ne.Skeleton,{className:"h-5 w-1/4",type:"text"}),f.jsx(ne.Skeleton,{className:"h-5 w-2/5",type:"text"}),f.jsx(ne.Skeleton,{className:"h-5 w-1/4",type:"text"})]})]})]});function Og(e,t){if(e==null)return{};var n={};for(var i in e)if({}.hasOwnProperty.call(e,i)){if(t.indexOf(i)!==-1)continue;n[i]=e[i]}return n}function Dg(e,t){if(e==null)return{};var n,i,r=Og(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(i=0;i<s.length;i++)n=s[i],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function qi(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function Ig(e){if(Array.isArray(e))return qi(e)}function Fg(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Lg(e,t){if(e){if(typeof e=="string")return qi(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?qi(e,t):void 0}}function jg(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
3
3
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Yi(e){return Ig(e)||Fg(e)||Lg(e)||jg()}function gn(e){"@babel/helpers - typeof";return gn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},gn(e)}function kg(e,t){if(gn(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var i=n.call(e,t);if(gn(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Vg(e){var t=kg(e,"string");return gn(t)=="symbol"?t:t+""}function cl(e,t,n){return(t=Vg(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Xi(){return Xi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Xi.apply(null,arguments)}function Es(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),n.push.apply(n,i)}return n}function Lt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Es(Object(n),!0).forEach(function(i){cl(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Es(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}function Bg(e){var t=e.length;if(t===0||t===1)return e;if(t===2)return[e[0],e[1],"".concat(e[0],".").concat(e[1]),"".concat(e[1],".").concat(e[0])];if(t===3)return[e[0],e[1],e[2],"".concat(e[0],".").concat(e[1]),"".concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[0]),"".concat(e[1],".").concat(e[2]),"".concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[1],".").concat(e[0])];if(t>=4)return[e[0],e[1],e[2],e[3],"".concat(e[0],".").concat(e[1]),"".concat(e[0],".").concat(e[2]),"".concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[0]),"".concat(e[1],".").concat(e[2]),"".concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[1]),"".concat(e[2],".").concat(e[3]),"".concat(e[3],".").concat(e[0]),"".concat(e[3],".").concat(e[1]),"".concat(e[3],".").concat(e[2]),"".concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[1],".").concat(e[3]),"".concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[2],".").concat(e[3]),"".concat(e[0],".").concat(e[3],".").concat(e[1]),"".concat(e[0],".").concat(e[3],".").concat(e[2]),"".concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[1],".").concat(e[2],".").concat(e[3]),"".concat(e[1],".").concat(e[3],".").concat(e[0]),"".concat(e[1],".").concat(e[3],".").concat(e[2]),"".concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[0],".").concat(e[3]),"".concat(e[2],".").concat(e[1],".").concat(e[0]),"".concat(e[2],".").concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[3],".").concat(e[0]),"".concat(e[2],".").concat(e[3],".").concat(e[1]),"".concat(e[3],".").concat(e[0],".").concat(e[1]),"".concat(e[3],".").concat(e[0],".").concat(e[2]),"".concat(e[3],".").concat(e[1],".").concat(e[0]),"".concat(e[3],".").concat(e[1],".").concat(e[2]),"".concat(e[3],".").concat(e[2],".").concat(e[0]),"".concat(e[3],".").concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[1],".").concat(e[2],".").concat(e[3]),"".concat(e[0],".").concat(e[1],".").concat(e[3],".").concat(e[2]),"".concat(e[0],".").concat(e[2],".").concat(e[1],".").concat(e[3]),"".concat(e[0],".").concat(e[2],".").concat(e[3],".").concat(e[1]),"".concat(e[0],".").concat(e[3],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[3],".").concat(e[2],".").concat(e[1]),"".concat(e[1],".").concat(e[0],".").concat(e[2],".").concat(e[3]),"".concat(e[1],".").concat(e[0],".").concat(e[3],".").concat(e[2]),"".concat(e[1],".").concat(e[2],".").concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[2],".").concat(e[3],".").concat(e[0]),"".concat(e[1],".").concat(e[3],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[3],".").concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[0],".").concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[0],".").concat(e[3],".").concat(e[1]),"".concat(e[2],".").concat(e[1],".").concat(e[0],".").concat(e[3]),"".concat(e[2],".").concat(e[1],".").concat(e[3],".").concat(e[0]),"".concat(e[2],".").concat(e[3],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[3],".").concat(e[1],".").concat(e[0]),"".concat(e[3],".").concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[3],".").concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[3],".").concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[3],".").concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[3],".").concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[3],".").concat(e[2],".").concat(e[1],".").concat(e[0])]}var bi={};function $g(e){if(e.length===0||e.length===1)return e;var t=e.join(".");return bi[t]||(bi[t]=Bg(e)),bi[t]}function Ug(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,i=e.filter(function(s){return s!=="token"}),r=$g(i);return r.reduce(function(s,o){return Lt(Lt({},s),n[o])},t)}function Cs(e){return e.join(" ")}function Gg(e,t){var n=0;return function(i){return n+=1,i.map(function(r,s){return ul({node:r,stylesheet:e,useInlineStyles:t,key:"code-segment-".concat(n,"-").concat(s)})})}}function ul(e){var t=e.node,n=e.stylesheet,i=e.style,r=i===void 0?{}:i,s=e.useInlineStyles,o=e.key,a=t.properties,l=t.type,c=t.tagName,d=t.value;if(l==="text")return d;if(c){var h=Gg(n,s),g;if(!s)g=Lt(Lt({},a),{},{className:Cs(a.className)});else{var u=Object.keys(n).reduce(function(b,x){return x.split(".").forEach(function(w){b.includes(w)||b.push(w)}),b},[]),p=a.className&&a.className.includes("token")?["token"]:[],m=a.className&&p.concat(a.className.filter(function(b){return!u.includes(b)}));g=Lt(Lt({},a),{},{className:Cs(m)||void 0,style:Ug(a.className,Object.assign({},a.style,r),n)})}var y=h(t.children);return O.createElement(c,Xi({key:o},g),y)}}const zg=function(e,t){var n=e.listLanguages();return n.indexOf(t)!==-1};var Hg=["language","children","style","customStyle","codeTagProps","useInlineStyles","showLineNumbers","showInlineLineNumbers","startingLineNumber","lineNumberContainerStyle","lineNumberStyle","wrapLines","wrapLongLines","lineProps","renderer","PreTag","CodeTag","code","astGenerator"];function Ts(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),n.push.apply(n,i)}return n}function ut(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ts(Object(n),!0).forEach(function(i){cl(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ts(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}var Wg=/\n/g;function Kg(e){return e.match(Wg)}function qg(e){var t=e.lines,n=e.startingLineNumber,i=e.style;return t.map(function(r,s){var o=s+n;return O.createElement("span",{key:"line-".concat(s),className:"react-syntax-highlighter-line-number",style:typeof i=="function"?i(o):i},"".concat(o,`
|
|
4
4
|
`))})}function Yg(e){var t=e.codeString,n=e.codeStyle,i=e.containerStyle,r=i===void 0?{float:"left",paddingRight:"10px"}:i,s=e.numberStyle,o=s===void 0?{}:s,a=e.startingLineNumber;return O.createElement("code",{style:Object.assign({},n,r)},qg({lines:t.replace(/\n$/,"").split(`
|
package/dist/components.es.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { jsx as m, jsxs as E, Fragment as Ln } from "react/jsx-runtime";
|
|
2
2
|
import { a as Ke, d as ki, c as od } from "./index-CEwEyzHV.js";
|
|
3
|
-
import { bk as ad, bl as ld, bm as cd, bn as $s, bo as Aa, bp as Pa, F as be, b6 as $t, B as ot, bq as ud, R as Pe, br as $e, aV as Oa, aX as Da, bs as si, bt as Ia, aW as La, S as dd, bu as pn, ab as Va, ap as Fa, ad as ka, ag as Us, ai as fd, aj as gd, am as pd, ao as hd, an as md, ak as js, ac as yd, af as dr, bv as Ut, ay as Ct, az as Qe, aA as Tt, aw as et, $ as Ba, aE as Hr, aB as Rt, b8 as vd, ax as bd, aY as wd, aZ as xd, bw as $a, aD as Ri, b9 as Sd, U as _d, bx as Ed, aF as Cd, J as zn, by as zs, bz as Gs, bA as Td, bB as Rd, bC as Nd, bD as Md, bE as Ad, bF as Pd, bi as Od, bg as Dd, bj as Id, bh as Ld, be as Ua, bf as gi } from "./index-
|
|
4
|
-
import { ae as fS, ah as gS } from "./index-
|
|
3
|
+
import { bk as ad, bl as ld, bm as cd, bn as $s, bo as Aa, bp as Pa, F as be, b6 as $t, B as ot, bq as ud, R as Pe, br as $e, aV as Oa, aX as Da, bs as si, bt as Ia, aW as La, S as dd, bu as pn, ab as Va, ap as Fa, ad as ka, ag as Us, ai as fd, aj as gd, am as pd, ao as hd, an as md, ak as js, ac as yd, af as dr, bv as Ut, ay as Ct, az as Qe, aA as Tt, aw as et, $ as Ba, aE as Hr, aB as Rt, b8 as vd, ax as bd, aY as wd, aZ as xd, bw as $a, aD as Ri, b9 as Sd, U as _d, bx as Ed, aF as Cd, J as zn, by as zs, bz as Gs, bA as Td, bB as Rd, bC as Nd, bD as Md, bE as Ad, bF as Pd, bi as Od, bg as Dd, bj as Id, bh as Ld, be as Ua, bf as gi } from "./index-DZmnb6ih.js";
|
|
4
|
+
import { ae as fS, ah as gS } from "./index-DZmnb6ih.js";
|
|
5
5
|
import { c as A, I as Wr, Y as Vd, S as Fd, s as kd, t as Bd, l as $d, n as Ud } from "./index-BcQaeGBJ.js";
|
|
6
6
|
import * as ee from "react";
|
|
7
7
|
import ge, { useState as fr, useRef as wn, useLayoutEffect as ja, useMemo as Vn, createContext as on, useContext as Ie, useId as jd, useEffect as Kr, useCallback as za, useInsertionEffect as zd, forwardRef as Gd, Fragment as Ga, createElement as Hd, Component as Wd } from "react";
|
|
8
8
|
import { S as ce, A as hn } from "./index-DecP4413.js";
|
|
9
9
|
import { c as Kd } from "./index-BFsbj9HY.js";
|
|
10
10
|
import { u as qd } from "./use-metadata-BrY8rtWx.js";
|
|
11
|
-
import { A as hS, D as mS, F as yS, M as vS, T as bS } from "./toast-form-
|
|
11
|
+
import { A as hS, D as mS, F as yS, M as vS, T as bS } from "./toast-form-Ck6Wlh-K.js";
|
|
12
12
|
const Hx = (e, t) => e.length === 0 ? /* @__PURE__ */ m("span", { children: t }) : e.length === 1 ? /* @__PURE__ */ m("span", { children: e[0].label }) : /* @__PURE__ */ E("span", { children: [
|
|
13
13
|
e[0].label,
|
|
14
14
|
" ",
|
|
@@ -82,4 +82,4 @@ Valid keys: `+JSON.stringify(Object.keys(k),null," "));var L=he(W,Z,M,N,O+"."+Z
|
|
|
82
82
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function $1(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function H1(e){if(Array.isArray(e))return Gr(e)}function fi(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),t.push.apply(t,r)}return t}function mi(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?arguments[n]:{};n%2?fi(Object(t),!0).forEach(function(r){Hd(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):fi(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function Hd(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function Ot(e,n){return Y1(e)||z1(e,n)||Wd(e,n)||W1()}function W1(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
83
83
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Wd(e,n){if(e){if(typeof e=="string")return Gr(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);if(t==="Object"&&e.constructor&&(t=e.constructor.name),t==="Map"||t==="Set")return Array.from(e);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Gr(e,n)}}function Gr(e,n){(n==null||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t<n;t++)r[t]=e[t];return r}function z1(e,n){var t=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(t!=null){var r=[],o=!0,a=!1,i,c;try{for(t=t.call(e);!(o=(i=t.next()).done)&&(r.push(i.value),!(n&&r.length===n));o=!0);}catch(d){a=!0,c=d}finally{try{!o&&t.return!=null&&t.return()}finally{if(a)throw c}}return r}}function Y1(e){if(Array.isArray(e))return e}var V1=typeof Tr=="function"?Tr:Tr.default,G1="file-invalid-type",q1="file-too-large",B1="file-too-small",K1="too-many-files",U1=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",t=n.split(","),r=t.length>1?"one of ".concat(t.join(", ")):t[0];return{code:G1,message:"File type must be ".concat(r)}},vi=function(n){return{code:q1,message:"File is larger than ".concat(n," ").concat(n===1?"byte":"bytes")}},gi=function(n){return{code:B1,message:"File is smaller than ".concat(n," ").concat(n===1?"byte":"bytes")}},X1={code:K1,message:"Too many files"};function zd(e,n){var t=e.type==="application/x-moz-file"||V1(e,n);return[t,t?null:U1(n)]}function Yd(e,n,t){if(it(e.size))if(it(n)&&it(t)){if(e.size>t)return[!1,vi(t)];if(e.size<n)return[!1,gi(n)]}else{if(it(n)&&e.size<n)return[!1,gi(n)];if(it(t)&&e.size>t)return[!1,vi(t)]}return[!0,null]}function it(e){return e!=null}function Q1(e){var n=e.files,t=e.accept,r=e.minSize,o=e.maxSize,a=e.multiple,i=e.maxFiles,c=e.validator;return!a&&n.length>1||a&&i>=1&&n.length>i?!1:n.every(function(d){var p=zd(d,t),f=Ot(p,1),m=f[0],v=Yd(d,r,o),g=Ot(v,1),h=g[0],b=c?c(d):null;return m&&h&&!b})}function hn(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function rn(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(n){return n==="Files"||n==="application/x-moz-file"}):!!e.target&&!!e.target.files}function hi(e){e.preventDefault()}function Z1(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function J1(e){return e.indexOf("Edge/")!==-1}function e0(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return Z1(e)||J1(e)}function $e(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];return function(r){for(var o=arguments.length,a=new Array(o>1?o-1:0),i=1;i<o;i++)a[i-1]=arguments[i];return n.some(function(c){return!hn(r)&&c&&c.apply(void 0,[r].concat(a)),hn(r)})}}function t0(){return"showOpenFilePicker"in window}function n0(e){if(it(e)){var n=Object.entries(e).filter(function(t){var r=Ot(t,2),o=r[0],a=r[1],i=!0;return Vd(o)||(console.warn('Skipped "'.concat(o,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),i=!1),(!Array.isArray(a)||!a.every(Gd))&&(console.warn('Skipped "'.concat(o,'" because an invalid file extension was provided.')),i=!1),i}).reduce(function(t,r){var o=Ot(r,2),a=o[0],i=o[1];return mi(mi({},t),{},Hd({},a,i))},{});return[{description:"Files",accept:n}]}return e}function r0(e){if(it(e))return Object.entries(e).reduce(function(n,t){var r=Ot(t,2),o=r[0],a=r[1];return[].concat(pi(n),[o],pi(a))},[]).filter(function(n){return Vd(n)||Gd(n)}).join(",")}function o0(e){return e instanceof DOMException&&(e.name==="AbortError"||e.code===e.ABORT_ERR)}function a0(e){return e instanceof DOMException&&(e.name==="SecurityError"||e.code===e.SECURITY_ERR)}function Vd(e){return e==="audio/*"||e==="video/*"||e==="image/*"||e==="text/*"||e==="application/*"||/\w+\/[-+.\w]+/g.test(e)}function Gd(e){return/^.*\.[\w]+$/.test(e)}var i0=["children"],s0=["open"],c0=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],l0=["refKey","onChange","onClick"];function d0(e){return f0(e)||p0(e)||qd(e)||u0()}function u0(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
84
84
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function p0(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function f0(e){if(Array.isArray(e))return qr(e)}function Dr(e,n){return g0(e)||v0(e,n)||qd(e,n)||m0()}function m0(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
85
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qd(e,n){if(e){if(typeof e=="string")return qr(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);if(t==="Object"&&e.constructor&&(t=e.constructor.name),t==="Map"||t==="Set")return Array.from(e);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return qr(e,n)}}function qr(e,n){(n==null||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t<n;t++)r[t]=e[t];return r}function v0(e,n){var t=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(t!=null){var r=[],o=!0,a=!1,i,c;try{for(t=t.call(e);!(o=(i=t.next()).done)&&(r.push(i.value),!(n&&r.length===n));o=!0);}catch(d){a=!0,c=d}finally{try{!o&&t.return!=null&&t.return()}finally{if(a)throw c}}return r}}function g0(e){if(Array.isArray(e))return e}function xi(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),t.push.apply(t,r)}return t}function ue(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?arguments[n]:{};n%2?xi(Object(t),!0).forEach(function(r){Br(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):xi(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function Br(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function xn(e,n){if(e==null)return{};var t=h0(e,n),r,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)r=a[o],!(n.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(t[r]=e[r])}return t}function h0(e,n){if(e==null)return{};var t={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(n.indexOf(o)>=0)&&(t[o]=e[o]);return t}var da=C.forwardRef(function(e,n){var t=e.children,r=xn(e,i0),o=Kd(r),a=o.open,i=xn(o,s0);return C.useImperativeHandle(n,function(){return{open:a}},[a]),C.createElement(C.Fragment,null,t(ue(ue({},i),{},{open:a})))});da.displayName="Dropzone";var Bd={disabled:!1,getFilesFromEvent:D1,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};da.defaultProps=Bd;da.propTypes={children:ce.func,accept:ce.objectOf(ce.arrayOf(ce.string)),multiple:ce.bool,preventDropOnDocument:ce.bool,noClick:ce.bool,noKeyboard:ce.bool,noDrag:ce.bool,noDragEventsBubbling:ce.bool,minSize:ce.number,maxSize:ce.number,maxFiles:ce.number,disabled:ce.bool,getFilesFromEvent:ce.func,onFileDialogCancel:ce.func,onFileDialogOpen:ce.func,useFsAccessApi:ce.bool,autoFocus:ce.bool,onDragEnter:ce.func,onDragLeave:ce.func,onDragOver:ce.func,onDrop:ce.func,onDropAccepted:ce.func,onDropRejected:ce.func,onError:ce.func,validator:ce.func};var Kr={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function Kd(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=ue(ue({},Bd),e),t=n.accept,r=n.disabled,o=n.getFilesFromEvent,a=n.maxSize,i=n.minSize,c=n.multiple,d=n.maxFiles,p=n.onDragEnter,f=n.onDragLeave,m=n.onDragOver,v=n.onDrop,g=n.onDropAccepted,h=n.onDropRejected,b=n.onFileDialogCancel,x=n.onFileDialogOpen,E=n.useFsAccessApi,w=n.autoFocus,P=n.preventDropOnDocument,_=n.noClick,y=n.noKeyboard,T=n.noDrag,$=n.noDragEventsBubbling,V=n.onError,A=n.validator,q=C.useMemo(function(){return r0(t)},[t]),K=C.useMemo(function(){return n0(t)},[t]),te=C.useMemo(function(){return typeof x=="function"?x:bi},[x]),re=C.useMemo(function(){return typeof b=="function"?b:bi},[b]),I=C.useRef(null),Q=C.useRef(null),J=C.useReducer(x0,Kr),j=Dr(J,2),F=j[0],H=j[1],k=F.isFocused,S=F.isFileDialogActive,R=C.useRef(typeof window<"u"&&window.isSecureContext&&E&&t0()),D=function(){!R.current&&S&&setTimeout(function(){if(Q.current){var U=Q.current.files;U.length||(H({type:"closeDialog"}),re())}},300)};C.useEffect(function(){return window.addEventListener("focus",D,!1),function(){window.removeEventListener("focus",D,!1)}},[Q,S,re,R]);var M=C.useRef([]),N=function(U){I.current&&I.current.contains(U.target)||(U.preventDefault(),M.current=[])};C.useEffect(function(){return P&&(document.addEventListener("dragover",hi,!1),document.addEventListener("drop",N,!1)),function(){P&&(document.removeEventListener("dragover",hi),document.removeEventListener("drop",N))}},[I,P]),C.useEffect(function(){return!r&&w&&I.current&&I.current.focus(),function(){}},[I,w,r]);var O=C.useCallback(function(z){V?V(z):console.error(z)},[V]),W=C.useCallback(function(z){z.preventDefault(),z.persist(),Jt(z),M.current=[].concat(d0(M.current),[z.target]),rn(z)&&Promise.resolve(o(z)).then(function(U){if(!(hn(z)&&!$)){var ge=U.length,xe=ge>0&&Q1({files:U,accept:q,minSize:i,maxSize:a,multiple:c,maxFiles:d,validator:A}),ke=ge>0&&!xe;H({isDragAccept:xe,isDragReject:ke,isDragActive:!0,type:"setDraggedFiles"}),p&&p(z)}}).catch(function(U){return O(U)})},[o,p,O,$,q,i,a,c,d,A]),B=C.useCallback(function(z){z.preventDefault(),z.persist(),Jt(z);var U=rn(z);if(U&&z.dataTransfer)try{z.dataTransfer.dropEffect="copy"}catch{}return U&&m&&m(z),!1},[m,$]),G=C.useCallback(function(z){z.preventDefault(),z.persist(),Jt(z);var U=M.current.filter(function(xe){return I.current&&I.current.contains(xe)}),ge=U.indexOf(z.target);ge!==-1&&U.splice(ge,1),M.current=U,!(U.length>0)&&(H({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),rn(z)&&f&&f(z))},[I,f,$]),Z=C.useCallback(function(z,U){var ge=[],xe=[];z.forEach(function(ke){var Dt=zd(ke,q),mt=Dr(Dt,2),nr=mt[0],rr=mt[1],or=Yd(ke,i,a),en=Dr(or,2),ar=en[0],ir=en[1],sr=A?A(ke):null;if(nr&&ar&&!sr)ge.push(ke);else{var cr=[rr,ir];sr&&(cr=cr.concat(sr)),xe.push({file:ke,errors:cr.filter(function(nm){return nm})})}}),(!c&&ge.length>1||c&&d>=1&&ge.length>d)&&(ge.forEach(function(ke){xe.push({file:ke,errors:[X1]})}),ge.splice(0)),H({acceptedFiles:ge,fileRejections:xe,isDragReject:xe.length>0,type:"setFiles"}),v&&v(ge,xe,U),xe.length>0&&h&&h(xe,U),ge.length>0&&g&&g(ge,U)},[H,c,q,i,a,d,v,g,h,A]),he=C.useCallback(function(z){z.preventDefault(),z.persist(),Jt(z),M.current=[],rn(z)&&Promise.resolve(o(z)).then(function(U){hn(z)&&!$||Z(U,z)}).catch(function(U){return O(U)}),H({type:"reset"})},[o,Z,O,$]),L=C.useCallback(function(){if(R.current){H({type:"openDialog"}),te();var z={multiple:c,types:K};window.showOpenFilePicker(z).then(function(U){return o(U)}).then(function(U){Z(U,null),H({type:"closeDialog"})}).catch(function(U){o0(U)?(re(U),H({type:"closeDialog"})):a0(U)?(R.current=!1,Q.current?(Q.current.value=null,Q.current.click()):O(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):O(U)});return}Q.current&&(H({type:"openDialog"}),te(),Q.current.value=null,Q.current.click())},[H,te,re,E,Z,O,K,c]),Re=C.useCallback(function(z){!I.current||!I.current.isEqualNode(z.target)||(z.key===" "||z.key==="Enter"||z.keyCode===32||z.keyCode===13)&&(z.preventDefault(),L())},[I,L]),ot=C.useCallback(function(){H({type:"focus"})},[]),Tt=C.useCallback(function(){H({type:"blur"})},[]),Sa=C.useCallback(function(){_||(e0()?setTimeout(L,0):L())},[_,L]),ft=function(U){return r?null:U},tr=function(U){return y?null:ft(U)},Zt=function(U){return T?null:ft(U)},Jt=function(U){$&&U.stopPropagation()},Jf=C.useMemo(function(){return function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},U=z.refKey,ge=U===void 0?"ref":U,xe=z.role,ke=z.onKeyDown,Dt=z.onFocus,mt=z.onBlur,nr=z.onClick,rr=z.onDragEnter,or=z.onDragOver,en=z.onDragLeave,ar=z.onDrop,ir=xn(z,c0);return ue(ue(Br({onKeyDown:tr($e(ke,Re)),onFocus:tr($e(Dt,ot)),onBlur:tr($e(mt,Tt)),onClick:ft($e(nr,Sa)),onDragEnter:Zt($e(rr,W)),onDragOver:Zt($e(or,B)),onDragLeave:Zt($e(en,G)),onDrop:Zt($e(ar,he)),role:typeof xe=="string"&&xe!==""?xe:"presentation"},ge,I),!r&&!y?{tabIndex:0}:{}),ir)}},[I,Re,ot,Tt,Sa,W,B,G,he,y,T,r]),em=C.useCallback(function(z){z.stopPropagation()},[]),tm=C.useMemo(function(){return function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},U=z.refKey,ge=U===void 0?"ref":U,xe=z.onChange,ke=z.onClick,Dt=xn(z,l0),mt=Br({accept:q,multiple:c,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:ft($e(xe,he)),onClick:ft($e(ke,em)),tabIndex:-1},ge,Q);return ue(ue({},mt),Dt)}},[Q,t,c,he,r]);return ue(ue({},F),{},{isFocused:k&&!r,getRootProps:Jf,getInputProps:tm,rootRef:I,inputRef:Q,open:ft(L)})}function x0(e,n){switch(n.type){case"focus":return ue(ue({},e),{},{isFocused:!0});case"blur":return ue(ue({},e),{},{isFocused:!1});case"openDialog":return ue(ue({},Kr),{},{isFileDialogActive:!0});case"closeDialog":return ue(ue({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return ue(ue({},e),{},{isDragActive:n.isDragActive,isDragAccept:n.isDragAccept,isDragReject:n.isDragReject});case"setFiles":return ue(ue({},e),{},{acceptedFiles:n.acceptedFiles,fileRejections:n.fileRejections,isDragReject:n.isDragReject});case"reset":return ue({},Kr);default:return e}}function bi(){}function b0(e){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],t=document.createElement("style");t.type="text/css",n.appendChild(t),t.styleSheet?t.styleSheet.cssText=e:t.appendChild(document.createTextNode(e))}Array(12).fill(0);let Ur=1;class y0{constructor(){this.subscribe=n=>(this.subscribers.push(n),()=>{const t=this.subscribers.indexOf(n);this.subscribers.splice(t,1)}),this.publish=n=>{this.subscribers.forEach(t=>t(n))},this.addToast=n=>{this.publish(n),this.toasts=[...this.toasts,n]},this.create=n=>{var t;const{message:r,...o}=n,a=typeof(n==null?void 0:n.id)=="number"||((t=n.id)==null?void 0:t.length)>0?n.id:Ur++,i=this.toasts.find(d=>d.id===a),c=n.dismissible===void 0?!0:n.dismissible;return this.dismissedToasts.has(a)&&this.dismissedToasts.delete(a),i?this.toasts=this.toasts.map(d=>d.id===a?(this.publish({...d,...n,id:a,title:r}),{...d,...n,id:a,dismissible:c,title:r}):d):this.addToast({title:r,...o,dismissible:c,id:a}),a},this.dismiss=n=>(n?(this.dismissedToasts.add(n),requestAnimationFrame(()=>this.subscribers.forEach(t=>t({id:n,dismiss:!0})))):this.toasts.forEach(t=>{this.subscribers.forEach(r=>r({id:t.id,dismiss:!0}))}),n),this.message=(n,t)=>this.create({...t,message:n}),this.error=(n,t)=>this.create({...t,message:n,type:"error"}),this.success=(n,t)=>this.create({...t,type:"success",message:n}),this.info=(n,t)=>this.create({...t,type:"info",message:n}),this.warning=(n,t)=>this.create({...t,type:"warning",message:n}),this.loading=(n,t)=>this.create({...t,type:"loading",message:n}),this.promise=(n,t)=>{if(!t)return;let r;t.loading!==void 0&&(r=this.create({...t,promise:n,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));const o=Promise.resolve(n instanceof Function?n():n);let a=r!==void 0,i;const c=o.then(async p=>{if(i=["resolve",p],C.isValidElement(p))a=!1,this.create({id:r,type:"default",message:p});else if(C0(p)&&!p.ok){a=!1;const m=typeof t.error=="function"?await t.error(`HTTP error! status: ${p.status}`):t.error,v=typeof t.description=="function"?await t.description(`HTTP error! status: ${p.status}`):t.description,h=typeof m=="object"&&!C.isValidElement(m)?m:{message:m};this.create({id:r,type:"error",description:v,...h})}else if(p instanceof Error){a=!1;const m=typeof t.error=="function"?await t.error(p):t.error,v=typeof t.description=="function"?await t.description(p):t.description,h=typeof m=="object"&&!C.isValidElement(m)?m:{message:m};this.create({id:r,type:"error",description:v,...h})}else if(t.success!==void 0){a=!1;const m=typeof t.success=="function"?await t.success(p):t.success,v=typeof t.description=="function"?await t.description(p):t.description,h=typeof m=="object"&&!C.isValidElement(m)?m:{message:m};this.create({id:r,type:"success",description:v,...h})}}).catch(async p=>{if(i=["reject",p],t.error!==void 0){a=!1;const f=typeof t.error=="function"?await t.error(p):t.error,m=typeof t.description=="function"?await t.description(p):t.description,g=typeof f=="object"&&!C.isValidElement(f)?f:{message:f};this.create({id:r,type:"error",description:m,...g})}}).finally(()=>{a&&(this.dismiss(r),r=void 0),t.finally==null||t.finally.call(t)}),d=()=>new Promise((p,f)=>c.then(()=>i[0]==="reject"?f(i[1]):p(i[1])).catch(f));return typeof r!="string"&&typeof r!="number"?{unwrap:d}:Object.assign(r,{unwrap:d})},this.custom=(n,t)=>{const r=(t==null?void 0:t.id)||Ur++;return this.create({jsx:n(r),id:r,...t}),r},this.getActiveToasts=()=>this.toasts.filter(n=>!this.dismissedToasts.has(n.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const De=new y0,w0=(e,n)=>{const t=(n==null?void 0:n.id)||Ur++;return De.addToast({title:e,...n,id:t}),t},C0=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",E0=w0,_0=()=>De.toasts,P0=()=>De.getActiveToasts(),Nr=Object.assign(E0,{success:De.success,info:De.info,warning:De.warning,error:De.error,custom:De.custom,message:De.message,promise:De.promise,dismiss:De.dismiss,loading:De.loading},{getHistory:_0,getToasts:P0});b0("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");const Ud=C.createContext(null),$n=()=>{const e=C.useContext(Ud);if(!e)throw new Error("useFileUpload must be used within a FileUploaderProvider");return e},Xd=C.forwardRef(({className:e,dropzoneOptions:n,value:t,onValueChange:r,reSelect:o,orientation:a="vertical",children:i,dir:c,...d},p)=>{const[f,m]=C.useState(!1),[v,g]=C.useState(!1),[h,b]=C.useState(-1),{accept:x={"image/*":[".jpg",".jpeg",".png",".gif"]},maxFiles:E=1,maxSize:w=4*1024*1024,multiple:P=!0}=n,_=E===1?!0:o,y=c==="rtl"?"rtl":"ltr",T=C.useCallback(K=>{if(!t)return;const te=t.filter((re,I)=>I!==K);r(te)},[t,r]),$=C.useCallback(K=>{var J;if(K.preventDefault(),K.stopPropagation(),!t)return;const te=()=>{const j=h+1;b(j>t.length-1?0:j)},re=()=>{const j=h-1;b(j<0?t.length-1:j)},I=a==="horizontal"?y==="ltr"?"ArrowLeft":"ArrowRight":"ArrowUp",Q=a==="horizontal"?y==="ltr"?"ArrowRight":"ArrowLeft":"ArrowDown";if(K.key===Q)te();else if(K.key===I)re();else if(K.key==="Enter"||K.key==="Space")h===-1&&((J=q.inputRef.current)==null||J.click());else if(K.key==="Delete"||K.key==="Backspace"){if(h!==-1){if(T(h),t.length-1===0){b(-1);return}re()}}else K.key==="Escape"&&b(-1)},[t,h,T]),V=C.useCallback((K,te)=>{var Q,J;const re=K;if(!re){Nr.error("file error , probably too big");return}const I=t?[...t]:[];if(_&&I.splice(0,I.length),re.forEach(j=>{I.length<E&&I.push(j)}),r(I),te.length>0)for(let j=0;j<te.length;j++){if(((Q=te[j].errors[0])==null?void 0:Q.code)==="file-too-large"){Nr.error(`File is too large. Max size is ${w/1024/1024}MB`);break}if((J=te[j].errors[0])!=null&&J.message){Nr.error(te[j].errors[0].message);break}}},[_,t]);C.useEffect(()=>{if(t){if(t.length===E){g(!0);return}g(!1)}},[t,E]);const q=Kd({...n||{accept:x,maxFiles:E,maxSize:w,multiple:P},onDrop:V,onDropRejected:()=>m(!0),onDropAccepted:()=>m(!1)});return s.jsx(Ud.Provider,{value:{dropzoneState:q,isLOF:v,isFileTooBig:f,removeFileFromSet:T,activeIndex:h,setActiveIndex:b,orientation:a,direction:y},children:s.jsx("div",{ref:p,tabIndex:0,onKeyDownCapture:$,className:l.cn("grid w-full overflow-hidden focus:outline-none",e,{"gap-2":t&&t.length>0}),dir:c,...d,children:i})})});Xd.displayName="FileUploader";const Qd=C.forwardRef(({children:e,className:n,...t},r)=>{const{orientation:o}=$n(),a=C.useRef(null);return s.jsx("div",{className:l.cn("w-full px-1"),ref:a,"aria-description":"content file holder",children:s.jsx("div",{...t,ref:r,className:l.cn("flex gap-1 rounded-xl",o==="horizontal"?"flex-raw flex-wrap":"flex-col",n),children:e})})});Qd.displayName="FileUploaderContent";const Zd=C.forwardRef(({className:e,index:n,children:t,...r},o)=>{const{removeFileFromSet:a,activeIndex:i,direction:c}=$n(),d=n===i;return s.jsxs("div",{ref:o,className:l.cn(Me({variant:"outline"}),"relative h-6 cursor-pointer justify-between p-1",e,d?"bg-muted":""),...r,children:[s.jsx("div",{className:"flex h-full w-full items-center gap-1.5 font-medium leading-none tracking-tight",children:t}),s.jsxs("button",{type:"button",className:l.cn("absolute",c==="rtl"?"left-1 top-1":"right-1 top-1"),onClick:()=>a(n),children:[s.jsxs("span",{className:"sr-only",children:["remove item ",n]}),s.jsx(Sv,{className:"h-4 w-4 duration-200 ease-in-out hover:stroke-destructive"})]})]})});Zd.displayName="FileUploaderItem";const Jd=C.forwardRef(({className:e,children:n,...t},r)=>{const{dropzoneState:o,isFileTooBig:a,isLOF:i}=$n(),c=i?{}:o.getRootProps();return s.jsxs("div",{ref:r,...t,className:`relative w-full ${i?"cursor-not-allowed opacity-50":"cursor-pointer"}`,children:[s.jsx("div",{className:l.cn(`w-full rounded-lg duration-300 ease-in-out ${o.isDragAccept?"border-green-500":o.isDragReject||a?"border-red-500":"border-gray-300"}`,e),...c,children:n}),s.jsx(Ad,{ref:o.inputRef,disabled:i,...o.getInputProps(),className:`${i?"cursor-not-allowed":""}`})]})});Jd.displayName="FileInput";const ua=({className:e,...n})=>s.jsx(Lt,{className:l.cn("flex",e),...n});ua.Col=({className:e,...n})=>s.jsx(Lt,{className:l.cn("flex flex-col items-start",e),...n});ua.Row=({className:e,...n})=>s.jsx(Lt,{className:l.cn("flex flex-row justify-start",e),...n});var R0=e=>e.type==="checkbox",k0=e=>e instanceof Date,eu=e=>e==null;const T0=e=>typeof e=="object";var Bt=e=>!eu(e)&&!Array.isArray(e)&&T0(e)&&!k0(e),D0=e=>Bt(e)&&e.target?R0(e.target)?e.target.checked:e.target.value:e,N0=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,M0=(e,n)=>e.has(N0(n)),S0=e=>{const n=e.constructor&&e.constructor.prototype;return Bt(n)&&n.hasOwnProperty("isPrototypeOf")},j0=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function tu(e){let n;const t=Array.isArray(e),r=typeof FileList<"u"?e instanceof FileList:!1;if(e instanceof Date)n=new Date(e);else if(!(j0&&(e instanceof Blob||r))&&(t||Bt(e)))if(n=t?[]:{},!t&&!S0(e))n=e;else for(const o in e)e.hasOwnProperty(o)&&(n[o]=tu(e[o]));else return e;return n}var nu=e=>/^\w*$/.test(e),Xr=e=>e===void 0,I0=e=>Array.isArray(e)?e.filter(Boolean):[],ru=e=>I0(e.replace(/["|']|\]/g,"").split(/\.|\[/)),Ee=(e,n,t)=>{if(!n||!Bt(e))return t;const r=(nu(n)?[n]:ru(n)).reduce((o,a)=>eu(o)?o:o[a],e);return Xr(r)||r===e?Xr(e[n])?t:e[n]:r},Mr=e=>typeof e=="boolean",yi=(e,n,t)=>{let r=-1;const o=nu(n)?[n]:ru(n),a=o.length,i=a-1;for(;++r<a;){const c=o[r];let d=t;if(r!==i){const p=e[c];d=Bt(p)||Array.isArray(p)?p:isNaN(+o[r+1])?{}:[]}if(c==="__proto__"||c==="constructor"||c==="prototype")return;e[c]=d,e=e[c]}};const wi={BLUR:"blur",CHANGE:"change"},Ci={all:"all"},pa=C.createContext(null);pa.displayName="HookFormContext";const Kt=()=>C.useContext(pa),A0=e=>{const{children:n,...t}=e;return C.createElement(pa.Provider,{value:t},n)};var O0=(e,n,t,r=!0)=>{const o={defaultValues:n._defaultValues};for(const a in e)Object.defineProperty(o,a,{get:()=>{const i=a;return n._proxyFormState[i]!==Ci.all&&(n._proxyFormState[i]=!r||Ci.all),t&&(t[i]=!0),e[i]}});return o};const ou=typeof window<"u"?u.useLayoutEffect:u.useEffect;function F0(e){const n=Kt(),{control:t=n.control,disabled:r,name:o,exact:a}=e||{},[i,c]=C.useState(t._formState),d=C.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return ou(()=>t._subscribe({name:o,formState:d.current,exact:a,callback:p=>{!r&&c({...t._formState,...p})}}),[o,r,a]),C.useEffect(()=>{d.current.isValid&&t._setValid(!0)},[t]),C.useMemo(()=>O0(i,t,d.current,!1),[i,t])}var L0=e=>typeof e=="string",$0=(e,n,t,r,o)=>L0(e)?Ee(t,e,o):Array.isArray(e)?e.map(a=>Ee(t,a)):t;function H0(e){const n=Kt(),{control:t=n.control,name:r,defaultValue:o,disabled:a,exact:i}=e||{},c=C.useRef(o),[d,p]=C.useState(t._getWatch(r,c.current));return ou(()=>t._subscribe({name:r,formState:{values:!0},exact:i,callback:f=>!a&&p($0(r,t._names,f.values||t._formValues,!1,c.current))}),[r,t,a,i]),C.useEffect(()=>t._removeUnmounted()),d}function au(e){const n=Kt(),{name:t,disabled:r,control:o=n.control,shouldUnregister:a}=e,i=M0(o._names.array,t),c=H0({control:o,name:t,defaultValue:Ee(o._formValues,t,Ee(o._defaultValues,t,e.defaultValue)),exact:!0}),d=F0({control:o,name:t,exact:!0}),p=C.useRef(e),f=C.useRef(o.register(t,{...e.rules,value:c,...Mr(e.disabled)?{disabled:e.disabled}:{}})),m=C.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Ee(d.errors,t)},isDirty:{enumerable:!0,get:()=>!!Ee(d.dirtyFields,t)},isTouched:{enumerable:!0,get:()=>!!Ee(d.touchedFields,t)},isValidating:{enumerable:!0,get:()=>!!Ee(d.validatingFields,t)},error:{enumerable:!0,get:()=>Ee(d.errors,t)}}),[d,t]),v=C.useCallback(x=>f.current.onChange({target:{value:D0(x),name:t},type:wi.CHANGE}),[t]),g=C.useCallback(()=>f.current.onBlur({target:{value:Ee(o._formValues,t),name:t},type:wi.BLUR}),[t,o._formValues]),h=C.useCallback(x=>{const E=Ee(o._fields,t);E&&x&&(E._f.ref={focus:()=>x.focus&&x.focus(),select:()=>x.select&&x.select(),setCustomValidity:w=>x.setCustomValidity(w),reportValidity:()=>x.reportValidity()})},[o._fields,t]),b=C.useMemo(()=>({name:t,value:c,...Mr(r)||d.disabled?{disabled:d.disabled||r}:{},onChange:v,onBlur:g,ref:h}),[t,r,d.disabled,v,g,h,c]);return C.useEffect(()=>{const x=o._options.shouldUnregister||a;o.register(t,{...p.current.rules,...Mr(p.current.disabled)?{disabled:p.current.disabled}:{}});const E=(w,P)=>{const _=Ee(o._fields,w);_&&_._f&&(_._f.mount=P)};if(E(t,!0),x){const w=tu(Ee(o._options.defaultValues,t));yi(o._defaultValues,t,w),Xr(Ee(o._formValues,t))&&yi(o._formValues,t,w)}return!i&&o.register(t),()=>{(i?x&&!o._state.action:x)?o.unregister(t):E(t,!1)}},[t,o,i,a]),C.useEffect(()=>{o._setDisabledField({disabled:r,name:t})},[r,t,o]),C.useMemo(()=>({field:b,formState:d,fieldState:m}),[b,d,m])}const W0=e=>e.render(au(e));var z0="Label",iu=u.forwardRef((e,n)=>s.jsx(l.Primitive.label,{...e,ref:n,onMouseDown:t=>{var o;t.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,t),!t.defaultPrevented&&t.detail>1&&t.preventDefault())}}));iu.displayName=z0;var su=iu;const Y0=Ke("text-sm font-normal leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),fa=u.forwardRef(({className:e,...n},t)=>s.jsx(su,{ref:t,className:l.cn(Y0(),e),...n}));fa.displayName=su.displayName;const cu=Ke("inline-flex items-center justify-center whitespace-nowrap gap-1",{variants:{size:{sm:"px-1 py-0.5 text-[13px] font-normal",md:"px-1 py-1 text-[13px] font-normal",lg:"px-2 py-1 text-sm font-medium"},shape:{square:"rounded",round:"rounded-full"},variant:{ad:"rounded-none rounded-bl-xl text-sm font-normal px-2 py-1 absolute top-0 right-0 bg-grey-800 text-white","solid-primary-50":"bg-main-50 text-main-600","solid-primary-100":"bg-main-100 text-main-600","solid-primary-600":"bg-main-600 text-main-50","solid-secondary-100":"bg-grey-100 text-grey-600","solid-secondary-400":"bg-grey-400 text-white","solid-secondary-800":"bg-grey-800 text-white","solid-red-400":"text-red-600 bg-grey-200/50","solid-red-white":"text-red-400 bg-white","outline-primary-600":"bg-main-100 border border-main-600 text-main-600","outline-secondary-200":"bg-white border border-grey-200 text-grey-800",red_white:"border-transparent text-red-400 bg-white",primary:"border-transparent text-main-800 bg-main-100",secondary:"border-transparent bg-grey-100 text-secondary",outline:"text-foreground",white:"border-transparent text-grey-800 bg-white",black:"border-transparent bg-grey-500 text-grey-100",etc:""}},defaultVariants:{variant:"solid-primary-50",size:"sm",shape:"square"}});function lu({className:e,variant:n,size:t,shape:r,icLeft:o,icRight:a,...i}){return s.jsxs("div",{className:l.cn(cu({size:t,shape:r,variant:n}),e),...i,children:[o&&s.jsx("div",{children:o})," ",s.jsx("div",{children:i.children}),a&&s.jsx("div",{children:a})," "]})}const kt=({children:e,className:n,type:t="text"})=>{switch(t){case"accent":return s.jsx(du,{children:e});case"error":return s.jsx(uu,{children:e});case"mute":return s.jsx(pu,{children:e});default:return s.jsx("span",{className:l.cn("text-grey-800",n),children:e})}},du=({children:e,className:n,color:t="text-main-600",tagSize:r="sm",asTag:o=!1})=>o?s.jsx(lu,{className:l.cn(t,n),size:r,variant:"solid-red-400",children:e}):s.jsx("span",{className:l.cn(t,n),children:e}),uu=({children:e,className:n})=>s.jsx("span",{className:l.cn("text-red-600",n),children:e}),pu=({children:e,className:n})=>s.jsx("span",{className:l.cn("text-muted",n),children:e});kt.Accent=du;kt.Error=uu;kt.Mute=pu;const V0=A0,fu=u.createContext({}),G0=({...e})=>s.jsx(fu.Provider,{value:{name:e.name},children:s.jsx(W0,{...e})}),Ut=()=>{const e=u.useContext(fu),n=u.useContext(mu),{getFieldState:t,formState:r}=Kt(),o=t(e.name,r);if(!e)throw new Error("useFormField should be used within <FormField>");const{id:a}=n;return{id:a,name:e.name,formItemId:`${a}-form-item`,formDescriptionId:`${a}-form-item-description`,formMessageId:`${a}-form-item-message`,...o}},mu=u.createContext({}),vu=u.forwardRef(({className:e,...n},t)=>{const r=u.useId();return s.jsx(mu.Provider,{value:{id:r},children:s.jsx("div",{ref:t,className:l.cn("relative flex flex-col gap-2",e),...n})})});vu.displayName="FormItem";const gu=u.forwardRef(({className:e,required:n,heading:t,label:r,description:o,children:a,...i},c)=>{const{error:d,formItemId:p}=Ut();return s.jsxs(fa,{ref:c,className:l.cn("relative",d&&"text-red-400","space-y-1 text-base font-semibold text-grey-800",e),htmlFor:p,...i,children:[n&&s.jsx("div",{className:"absolute right-full top-0 -mt-1 mr-0.5 text-lg text-red-600",children:"*"}),t&&s.jsx(kt,{className:"font-semibold",children:t}),r&&s.jsx(bn,{className:"text-sm font-normal text-grey-800",children:r}),o&&s.jsx(bn,{className:"whitespace-pre-wrap",children:o}),a]})});gu.displayName="FormLabel";const hu=u.forwardRef(({...e},n)=>{const{error:t,formItemId:r,formDescriptionId:o,formMessageId:a}=Ut();return s.jsx(l.Slot,{ref:n,id:r,"aria-describedby":t?`${o} ${a}`:`${o}`,"aria-invalid":!!t,...e})});hu.displayName="FormControl";const bn=u.forwardRef(({className:e,...n},t)=>{const{formDescriptionId:r}=Ut();return s.jsx("div",{ref:t,id:r,className:l.cn("whitespace-pre-wrap text-sm font-normal text-grey-600",e),...n})});bn.displayName="FormDescription";const xu=u.forwardRef(({className:e,children:n,absolute:t,...r},o)=>{var p;const{error:a,formMessageId:i}=Ut(),c=(a==null?void 0:a.message)||((p=a==null?void 0:a.root)==null?void 0:p.message),d=a?c||"":n;return d?s.jsx("div",{ref:o,id:i,className:l.cn("flex h-5 items-center",t&&"absolute top-full mt-2"),...r,children:s.jsx(kt.Error,{className:l.cn("h-5 text-sm",e),children:d})}):null});xu.displayName="FormMessage";function q0(){return we(jc())}const B0=jc();function K0({currentMonth:e=B0,onMonthChange:n,disabled:t}){const[r,o]=u.useState(_e(e,"yyyy")),a=Fh(r,"yyyy",new Date),i=Gv({start:a,end:qv(a)});function c(){const p=Ha(a,{years:-1});o(_e(p,"yyyy"))}function d(){const p=Ha(a,{years:1});o(_e(p,"yyyy"))}return s.jsxs("div",{className:"p-3",children:[s.jsxs("div",{className:"mb-4 flex items-center justify-between",children:[s.jsx("button",{name:"previous-year","aria-label":"Go to previous year",className:l.cn(Me({variant:"outline"}),"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"),type:"button",onClick:c,children:s.jsx(Pv,{className:"h-4 w-4"})}),s.jsx("div",{className:"text-sm font-medium","aria-live":"polite",role:"presentation",id:"month-picker",children:_e(a,"yyyy")}),s.jsx("button",{name:"next-year","aria-label":"Go to next year",className:l.cn(Me({variant:"outline"}),"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"),type:"button",onClick:d,children:s.jsx(kv,{className:"h-4 w-4"})})]}),s.jsx("div",{className:"grid grid-cols-3 gap-2",role:"grid","aria-labelledby":"month-picker",children:i.map(p=>s.jsx("div",{className:"relative text-center",role:"presentation",children:s.jsx("button",{name:"month",className:l.cn("inline-flex h-9 w-16 items-center justify-center rounded-md p-0 text-sm font-normal transition-colors hover:bg-main-100 hover:text-main-600 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-main-400 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",ur(p,e)&&"bg-main-600 text-main-50 hover:bg-main-600 hover:text-main-50 focus:bg-main-600 focus:text-main-50 dark:bg-main-50 dark:text-main-600 dark:hover:bg-main-50 dark:hover:text-main-600 dark:focus:bg-main-50 dark:focus:text-main-600",!ur(p,e)&&ur(p,q0())&&"bg-main-100 text-main-600 dark:bg-main-800 dark:text-main-50"),disabled:t?t(p):void 0,role:"gridcell",type:"button",onClick:()=>n&&n(p),children:s.jsx("time",{dateTime:_e(p,"yyyy-MM"),children:_e(p,"MMM",{locale:Ic})})})},p.toString()))})]})}const bu=C.createContext(null),Hn=()=>{const e=C.useContext(bu);if(!e)throw new Error("useMultiSelect must be used within MultiSelectProvider");return e},U0=({values:e,onValuesChange:n,loop:t=!1,className:r,children:o,dir:a,...i})=>{const[c,d]=C.useState(""),[p,f]=C.useState(!1),[m,v]=C.useState(-1),g=C.useCallback(b=>{e.includes(b)?n(e.filter(x=>x!==b)):n([...e,b])},[e]),h=C.useCallback(b=>{const x=()=>{const w=m+1;v(w>e.length-1?t?0:-1:w)},E=()=>{const w=m-1;v(w<0?e.length-1:w)};if((b.key==="Backspace"||b.key==="Delete")&&e.length>0){if(c.length===0)if(m!==-1&&m<e.length){n(e.filter(P=>P!==e[m]));const w=m-1<0?0:m-1;v(w)}else n(e.filter(w=>w!==e[e.length-1]))}else b.key==="Enter"?f(!0):b.key==="Escape"?m!==-1?v(-1):f(!1):a==="rtl"?b.key==="ArrowRight"?E():b.key==="ArrowLeft"&&(m!==-1||t)&&x():b.key==="ArrowLeft"?E():b.key==="ArrowRight"&&(m!==-1||t)&&x()},[e,c,m,t]);return s.jsx(bu.Provider,{value:{value:e,onValueChange:g,open:p,setOpen:f,inputValue:c,setInputValue:d,activeIndex:m,setActiveIndex:v},children:s.jsx(In,{onKeyDown:h,className:l.cn("flex flex-col space-y-2 overflow-visible bg-transparent",r),dir:a,...i,children:o})})},yu=C.forwardRef(({className:e,children:n,labels:t,...r},o)=>{const{value:a,onValueChange:i,activeIndex:c}=Hn(),d=C.useCallback(p=>{p.preventDefault(),p.stopPropagation()},[]);return s.jsxs("div",{ref:o,className:l.cn("flex flex-wrap gap-1 rounded-lg border border-grey-200 bg-background p-1 py-2",e),...r,children:[a.map((p,f)=>{const m=t&&t[p]?t[p].label||t[p].text:p;return s.jsxs(oc,{className:l.cn("flex items-center gap-1 rounded-md px-2 py-1",c===f&&"ring-2 ring-muted-foreground"),variant:"secondary",children:[s.jsx("span",{className:"text-sm",children:m}),s.jsxs("button",{"aria-label":`Remove ${p} option`,"aria-roledescription":"button to remove option",type:"button",onMouseDown:d,onClick:()=>i(p),children:[s.jsxs("span",{className:"sr-only",children:["Remove ",p," option"]}),s.jsx(Iv,{className:"h-4 w-4 hover:stroke-destructive"})]})]},p)}),n]})});yu.displayName="MultiSelectorTrigger";const wu=C.forwardRef(({className:e,...n},t)=>{const{setOpen:r,inputValue:o,setInputValue:a,activeIndex:i,setActiveIndex:c}=Hn();return s.jsx(Ce.Input,{...n,ref:t,value:o,onValueChange:i===-1?a:void 0,onBlur:()=>r(!1),onFocus:()=>r(!0),onClick:()=>c(-1),className:l.cn("ml-2 flex-1 bg-transparent outline-none placeholder:text-muted-foreground",e,i!==-1&&"caret-transparent")})});wu.displayName="MultiSelectorInput";const Cu=C.forwardRef(({children:e},n)=>{const{open:t}=Hn();return s.jsx("div",{ref:n,className:"relative",children:t&&e})});Cu.displayName="MultiSelectorContent";const Eu=C.forwardRef(({className:e,children:n},t)=>s.jsxs(Zo,{ref:t,className:l.cn("scrollbar-thin scrollbar-track-transparent scrollbar-thumb-muted-foreground dark:scrollbar-thumb-muted scrollbar-thumb-rounded-lg absolute top-0 z-10 flex w-full flex-col gap-2 rounded-md border border-grey-200 bg-background p-2 shadow-md transition-colors",e),children:[n,s.jsx(Jo,{children:s.jsx("span",{className:"text-muted",children:"No results found"})})]}));Eu.displayName="MultiSelectorList";const _u=C.forwardRef(({className:e,value:n,children:t,...r},o)=>{const{value:a,onValueChange:i,setInputValue:c}=Hn(),d=C.useCallback(f=>{f.preventDefault(),f.stopPropagation()},[]),p=a.includes(n);return s.jsxs(ea,{ref:o,...r,onSelect:()=>{i(n),c("")},className:l.cn("flex cursor-pointer justify-between rounded-md px-2 py-1 transition-colors",e,p&&"cursor-default opacity-50",r.disabled&&"cursor-not-allowed opacity-50"),onMouseDown:d,children:[t,p&&s.jsx(l.Check,{className:"h-4 w-4"})]})});_u.displayName="MultiSelectorItem";var pt="NavigationMenu",[ma,Pu,X0]=l.createCollection(pt),[Qr,Q0,Z0]=l.createCollection(pt),[va,t_]=l.createContextScope(pt,[X0,Z0]),[J0,Ie]=va(pt),[eC,tC]=va(pt),Ru=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,value:r,onValueChange:o,defaultValue:a,delayDuration:i=200,skipDelayDuration:c=300,orientation:d="horizontal",dir:p,...f}=e,[m,v]=u.useState(null),g=l.useComposedRefs(n,A=>v(A)),h=l.useDirection(p),b=u.useRef(0),x=u.useRef(0),E=u.useRef(0),[w,P]=u.useState(!0),[_,y]=l.useControllableState({prop:r,onChange:A=>{const q=A!=="",K=c>0;q?(window.clearTimeout(E.current),K&&P(!1)):(window.clearTimeout(E.current),E.current=window.setTimeout(()=>P(!0),c)),o==null||o(A)},defaultProp:a??"",caller:pt}),T=u.useCallback(()=>{window.clearTimeout(x.current),x.current=window.setTimeout(()=>y(""),150)},[y]),$=u.useCallback(A=>{window.clearTimeout(x.current),y(A)},[y]),V=u.useCallback(A=>{_===A?window.clearTimeout(x.current):b.current=window.setTimeout(()=>{window.clearTimeout(x.current),y(A)},i)},[_,y,i]);return u.useEffect(()=>()=>{window.clearTimeout(b.current),window.clearTimeout(x.current),window.clearTimeout(E.current)},[]),s.jsx(ku,{scope:t,isRootMenu:!0,value:_,dir:h,orientation:d,rootNavigationMenu:m,onTriggerEnter:A=>{window.clearTimeout(b.current),w?V(A):$(A)},onTriggerLeave:()=>{window.clearTimeout(b.current),T()},onContentEnter:()=>window.clearTimeout(x.current),onContentLeave:T,onItemSelect:A=>{y(q=>q===A?"":A)},onItemDismiss:()=>y(""),children:s.jsx(l.Primitive.nav,{"aria-label":"Main","data-orientation":d,dir:h,...f,ref:g})})});Ru.displayName=pt;var Zr="NavigationMenuSub",nC=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,value:r,onValueChange:o,defaultValue:a,orientation:i="horizontal",...c}=e,d=Ie(Zr,t),[p,f]=l.useControllableState({prop:r,onChange:o,defaultProp:a??"",caller:Zr});return s.jsx(ku,{scope:t,isRootMenu:!1,value:p,dir:d.dir,orientation:i,rootNavigationMenu:d.rootNavigationMenu,onTriggerEnter:m=>f(m),onItemSelect:m=>f(m),onItemDismiss:()=>f(""),children:s.jsx(l.Primitive.div,{"data-orientation":i,...c,ref:n})})});nC.displayName=Zr;var ku=e=>{const{scope:n,isRootMenu:t,rootNavigationMenu:r,dir:o,orientation:a,children:i,value:c,onItemSelect:d,onItemDismiss:p,onTriggerEnter:f,onTriggerLeave:m,onContentEnter:v,onContentLeave:g}=e,[h,b]=u.useState(null),[x,E]=u.useState(new Map),[w,P]=u.useState(null);return s.jsx(J0,{scope:n,isRootMenu:t,rootNavigationMenu:r,value:c,previousValue:l.usePrevious(c),baseId:l.useId(),dir:o,orientation:a,viewport:h,onViewportChange:b,indicatorTrack:w,onIndicatorTrackChange:P,onTriggerEnter:l.useCallbackRef(f),onTriggerLeave:l.useCallbackRef(m),onContentEnter:l.useCallbackRef(v),onContentLeave:l.useCallbackRef(g),onItemSelect:l.useCallbackRef(d),onItemDismiss:l.useCallbackRef(p),onViewportContentChange:u.useCallback((_,y)=>{E(T=>(T.set(_,y),new Map(T)))},[]),onViewportContentRemove:u.useCallback(_=>{E(y=>y.has(_)?(y.delete(_),new Map(y)):y)},[]),children:s.jsx(ma.Provider,{scope:n,children:s.jsx(eC,{scope:n,items:x,children:i})})})},Tu="NavigationMenuList",Du=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,...r}=e,o=Ie(Tu,t),a=s.jsx(l.Primitive.ul,{"data-orientation":o.orientation,...r,ref:n});return s.jsx(l.Primitive.div,{style:{position:"relative"},ref:o.onIndicatorTrackChange,children:s.jsx(ma.Slot,{scope:t,children:o.isRootMenu?s.jsx($u,{asChild:!0,children:a}):a})})});Du.displayName=Tu;var Nu="NavigationMenuItem",[rC,Mu]=va(Nu),Su=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,value:r,...o}=e,a=l.useId(),i=r||a||"LEGACY_REACT_AUTO_VALUE",c=u.useRef(null),d=u.useRef(null),p=u.useRef(null),f=u.useRef(()=>{}),m=u.useRef(!1),v=u.useCallback((h="start")=>{if(c.current){f.current();const b=eo(c.current);b.length&&xa(h==="start"?b:b.reverse())}},[]),g=u.useCallback(()=>{if(c.current){const h=eo(c.current);h.length&&(f.current=dC(h))}},[]);return s.jsx(rC,{scope:t,value:i,triggerRef:d,contentRef:c,focusProxyRef:p,wasEscapeCloseRef:m,onEntryKeyDown:v,onFocusProxyEnter:v,onRootContentClose:g,onContentFocusOutside:g,children:s.jsx(l.Primitive.li,{...o,ref:n})})});Su.displayName=Nu;var Jr="NavigationMenuTrigger",ju=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,disabled:r,...o}=e,a=Ie(Jr,e.__scopeNavigationMenu),i=Mu(Jr,e.__scopeNavigationMenu),c=u.useRef(null),d=l.useComposedRefs(c,i.triggerRef,n),p=Wu(a.baseId,i.value),f=zu(a.baseId,i.value),m=u.useRef(!1),v=u.useRef(!1),g=i.value===a.value;return s.jsxs(s.Fragment,{children:[s.jsx(ma.ItemSlot,{scope:t,value:i.value,children:s.jsx(Hu,{asChild:!0,children:s.jsx(l.Primitive.button,{id:p,disabled:r,"data-disabled":r?"":void 0,"data-state":ba(g),"aria-expanded":g,"aria-controls":f,...o,ref:d,onPointerEnter:l.composeEventHandlers(e.onPointerEnter,()=>{v.current=!1,i.wasEscapeCloseRef.current=!1}),onPointerMove:l.composeEventHandlers(e.onPointerMove,yn(()=>{r||v.current||i.wasEscapeCloseRef.current||m.current||(a.onTriggerEnter(i.value),m.current=!0)})),onPointerLeave:l.composeEventHandlers(e.onPointerLeave,yn(()=>{r||(a.onTriggerLeave(),m.current=!1)})),onClick:l.composeEventHandlers(e.onClick,()=>{a.onItemSelect(i.value),v.current=g}),onKeyDown:l.composeEventHandlers(e.onKeyDown,h=>{const x={horizontal:"ArrowDown",vertical:a.dir==="rtl"?"ArrowLeft":"ArrowRight"}[a.orientation];g&&h.key===x&&(i.onEntryKeyDown(),h.preventDefault())})})})}),g&&s.jsxs(s.Fragment,{children:[s.jsx(l.Root,{"aria-hidden":!0,tabIndex:0,ref:i.focusProxyRef,onFocus:h=>{const b=i.contentRef.current,x=h.relatedTarget,E=x===c.current,w=b==null?void 0:b.contains(x);(E||!w)&&i.onFocusProxyEnter(E?"start":"end")}}),a.viewport&&s.jsx("span",{"aria-owns":f})]})]})});ju.displayName=Jr;var oC="NavigationMenuLink",Ei="navigationMenu.linkSelect",Iu=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,active:r,onSelect:o,...a}=e;return s.jsx(Hu,{asChild:!0,children:s.jsx(l.Primitive.a,{"data-active":r?"":void 0,"aria-current":r?"page":void 0,...a,ref:n,onClick:l.composeEventHandlers(e.onClick,i=>{const c=i.target,d=new CustomEvent(Ei,{bubbles:!0,cancelable:!0});if(c.addEventListener(Ei,p=>o==null?void 0:o(p),{once:!0}),l.dispatchDiscreteCustomEvent(c,d),!d.defaultPrevented&&!i.metaKey){const p=new CustomEvent(sn,{bubbles:!0,cancelable:!0});l.dispatchDiscreteCustomEvent(c,p)}},{checkForDefaultPrevented:!1})})})});Iu.displayName=oC;var ga="NavigationMenuIndicator",Au=u.forwardRef((e,n)=>{const{forceMount:t,...r}=e,o=Ie(ga,e.__scopeNavigationMenu),a=!!o.value;return o.indicatorTrack?Di.createPortal(s.jsx(de,{present:t||a,children:s.jsx(aC,{...r,ref:n})}),o.indicatorTrack):null});Au.displayName=ga;var aC=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,...r}=e,o=Ie(ga,t),a=Pu(t),[i,c]=u.useState(null),[d,p]=u.useState(null),f=o.orientation==="horizontal",m=!!o.value;u.useEffect(()=>{var b;const h=(b=a().find(x=>x.value===o.value))==null?void 0:b.ref.current;h&&c(h)},[a,o.value]);const v=()=>{i&&p({size:f?i.offsetWidth:i.offsetHeight,offset:f?i.offsetLeft:i.offsetTop})};return to(i,v),to(o.indicatorTrack,v),d?s.jsx(l.Primitive.div,{"aria-hidden":!0,"data-state":m?"visible":"hidden","data-orientation":o.orientation,...r,ref:n,style:{position:"absolute",...f?{left:0,width:d.size+"px",transform:`translateX(${d.offset}px)`}:{top:0,height:d.size+"px",transform:`translateY(${d.offset}px)`},...r.style}}):null}),_t="NavigationMenuContent",Ou=u.forwardRef((e,n)=>{const{forceMount:t,...r}=e,o=Ie(_t,e.__scopeNavigationMenu),a=Mu(_t,e.__scopeNavigationMenu),i=l.useComposedRefs(a.contentRef,n),c=a.value===o.value,d={value:a.value,triggerRef:a.triggerRef,focusProxyRef:a.focusProxyRef,wasEscapeCloseRef:a.wasEscapeCloseRef,onContentFocusOutside:a.onContentFocusOutside,onRootContentClose:a.onRootContentClose,...r};return o.viewport?s.jsx(iC,{forceMount:t,...d,ref:i}):s.jsx(de,{present:t||c,children:s.jsx(Fu,{"data-state":ba(c),...d,ref:i,onPointerEnter:l.composeEventHandlers(e.onPointerEnter,o.onContentEnter),onPointerLeave:l.composeEventHandlers(e.onPointerLeave,yn(o.onContentLeave)),style:{pointerEvents:!c&&o.isRootMenu?"none":void 0,...d.style}})})});Ou.displayName=_t;var iC=u.forwardRef((e,n)=>{const t=Ie(_t,e.__scopeNavigationMenu),{onViewportContentChange:r,onViewportContentRemove:o}=t;return l.useLayoutEffect2(()=>{r(e.value,{ref:n,...e})},[e,n,r]),l.useLayoutEffect2(()=>()=>o(e.value),[e.value,o]),null}),sn="navigationMenu.rootContentDismiss",Fu=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,value:r,triggerRef:o,focusProxyRef:a,wasEscapeCloseRef:i,onRootContentClose:c,onContentFocusOutside:d,...p}=e,f=Ie(_t,t),m=u.useRef(null),v=l.useComposedRefs(m,n),g=Wu(f.baseId,r),h=zu(f.baseId,r),b=Pu(t),x=u.useRef(null),{onItemDismiss:E}=f;u.useEffect(()=>{const P=m.current;if(f.isRootMenu&&P){const _=()=>{var y;E(),c(),P.contains(document.activeElement)&&((y=o.current)==null||y.focus())};return P.addEventListener(sn,_),()=>P.removeEventListener(sn,_)}},[f.isRootMenu,e.value,o,E,c]);const w=u.useMemo(()=>{const _=b().map(q=>q.value);f.dir==="rtl"&&_.reverse();const y=_.indexOf(f.value),T=_.indexOf(f.previousValue),$=r===f.value,V=T===_.indexOf(r);if(!$&&!V)return x.current;const A=(()=>{if(y!==T){if($&&T!==-1)return y>T?"from-end":"from-start";if(V&&y!==-1)return y>T?"to-start":"to-end"}return null})();return x.current=A,A},[f.previousValue,f.value,f.dir,b,r]);return s.jsx($u,{asChild:!0,children:s.jsx(l.DismissableLayer,{id:h,"aria-labelledby":g,"data-motion":w,"data-orientation":f.orientation,...p,ref:v,disableOutsidePointerEvents:!1,onDismiss:()=>{var _;const P=new Event(sn,{bubbles:!0,cancelable:!0});(_=m.current)==null||_.dispatchEvent(P)},onFocusOutside:l.composeEventHandlers(e.onFocusOutside,P=>{var y;d();const _=P.target;(y=f.rootNavigationMenu)!=null&&y.contains(_)&&P.preventDefault()}),onPointerDownOutside:l.composeEventHandlers(e.onPointerDownOutside,P=>{var $;const _=P.target,y=b().some(V=>{var A;return(A=V.ref.current)==null?void 0:A.contains(_)}),T=f.isRootMenu&&(($=f.viewport)==null?void 0:$.contains(_));(y||T||!f.isRootMenu)&&P.preventDefault()}),onKeyDown:l.composeEventHandlers(e.onKeyDown,P=>{var T;const _=P.altKey||P.ctrlKey||P.metaKey;if(P.key==="Tab"&&!_){const $=eo(P.currentTarget),V=document.activeElement,A=$.findIndex(te=>te===V),K=P.shiftKey?$.slice(0,A).reverse():$.slice(A+1,$.length);xa(K)?P.preventDefault():(T=a.current)==null||T.focus()}}),onEscapeKeyDown:l.composeEventHandlers(e.onEscapeKeyDown,P=>{i.current=!0})})})}),ha="NavigationMenuViewport",Lu=u.forwardRef((e,n)=>{const{forceMount:t,...r}=e,a=!!Ie(ha,e.__scopeNavigationMenu).value;return s.jsx(de,{present:t||a,children:s.jsx(sC,{...r,ref:n})})});Lu.displayName=ha;var sC=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,children:r,...o}=e,a=Ie(ha,t),i=l.useComposedRefs(n,a.onViewportChange),c=tC(_t,e.__scopeNavigationMenu),[d,p]=u.useState(null),[f,m]=u.useState(null),v=d?(d==null?void 0:d.width)+"px":void 0,g=d?(d==null?void 0:d.height)+"px":void 0,h=!!a.value,b=h?a.value:a.previousValue;return to(f,()=>{f&&p({width:f.offsetWidth,height:f.offsetHeight})}),s.jsx(l.Primitive.div,{"data-state":ba(h),"data-orientation":a.orientation,...o,ref:i,style:{pointerEvents:!h&&a.isRootMenu?"none":void 0,"--radix-navigation-menu-viewport-width":v,"--radix-navigation-menu-viewport-height":g,...o.style},onPointerEnter:l.composeEventHandlers(e.onPointerEnter,a.onContentEnter),onPointerLeave:l.composeEventHandlers(e.onPointerLeave,yn(a.onContentLeave)),children:Array.from(c.items).map(([E,{ref:w,forceMount:P,..._}])=>{const y=b===E;return s.jsx(de,{present:P||y,children:s.jsx(Fu,{..._,ref:l.composeRefs(w,T=>{y&&T&&m(T)})})},E)})})}),cC="FocusGroup",$u=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,...r}=e,o=Ie(cC,t);return s.jsx(Qr.Provider,{scope:t,children:s.jsx(Qr.Slot,{scope:t,children:s.jsx(l.Primitive.div,{dir:o.dir,...r,ref:n})})})}),_i=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"],lC="FocusGroupItem",Hu=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,...r}=e,o=Q0(t),a=Ie(lC,t);return s.jsx(Qr.ItemSlot,{scope:t,children:s.jsx(l.Primitive.button,{...r,ref:n,onKeyDown:l.composeEventHandlers(e.onKeyDown,i=>{if(["Home","End",..._i].includes(i.key)){let d=o().map(m=>m.ref.current);if([a.dir==="rtl"?"ArrowRight":"ArrowLeft","ArrowUp","End"].includes(i.key)&&d.reverse(),_i.includes(i.key)){const m=d.indexOf(i.currentTarget);d=d.slice(m+1)}setTimeout(()=>xa(d)),i.preventDefault()}})})})});function eo(e){const n=[],t=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;t.nextNode();)n.push(t.currentNode);return n}function xa(e){const n=document.activeElement;return e.some(t=>t===n?!0:(t.focus(),document.activeElement!==n))}function dC(e){return e.forEach(n=>{n.dataset.tabindex=n.getAttribute("tabindex")||"",n.setAttribute("tabindex","-1")}),()=>{e.forEach(n=>{const t=n.dataset.tabindex;n.setAttribute("tabindex",t)})}}function to(e,n){const t=l.useCallbackRef(n);l.useLayoutEffect2(()=>{let r=0;if(e){const o=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(t)});return o.observe(e),()=>{window.cancelAnimationFrame(r),o.unobserve(e)}}},[e,t])}function ba(e){return e?"open":"closed"}function Wu(e,n){return`${e}-trigger-${n}`}function zu(e,n){return`${e}-content-${n}`}function yn(e){return n=>n.pointerType==="mouse"?e(n):void 0}var Yu=Ru,Vu=Du,uC=Su,Gu=ju,pC=Iu,qu=Au,Bu=Ou,Ku=Lu;const Uu=u.forwardRef(({className:e,children:n,...t},r)=>s.jsxs(Yu,{ref:r,className:l.cn("relative z-10 flex max-w-max flex-1 items-center justify-center",e),...t,children:[n,s.jsx(ya,{})]}));Uu.displayName=Yu.displayName;const Xu=u.forwardRef(({className:e,...n},t)=>s.jsx(Vu,{ref:t,className:l.cn("group flex flex-1 list-none items-center justify-center space-x-1",e),...n}));Xu.displayName=Vu.displayName;const fC=uC,Qu=Ke("group inline-flex h-12 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent/50 data-[state=open]:bg-accent/50"),Zu=u.forwardRef(({className:e,children:n,...t},r)=>s.jsxs(Gu,{ref:r,className:l.cn(Qu(),"group",e),...t,children:[n," ",s.jsx(Ev,{className:"relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180","aria-hidden":"true"})]}));Zu.displayName=Gu.displayName;const Ju=u.forwardRef(({className:e,...n},t)=>s.jsx(Bu,{ref:t,className:l.cn("data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full md:absolute md:w-auto",e),...n}));Ju.displayName=Bu.displayName;const mC=pC,ya=u.forwardRef(({className:e,...n},t)=>s.jsx("div",{className:l.cn("absolute left-0 top-full flex justify-center"),children:s.jsx(Ku,{className:l.cn("origin-top-center data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 relative mt-1 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-lg md:w-[var(--radix-navigation-menu-viewport-width)]",e),ref:t,...n})}));ya.displayName=Ku.displayName;const ep=u.forwardRef(({className:e,...n},t)=>s.jsx(qu,{ref:t,className:l.cn("data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden",e),...n,children:s.jsx("div",{className:"relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md"})}));ep.displayName=qu.displayName;var Wn="Popover",[tp,n_]=l.createContextScope(Wn,[l.createPopperScope]),Xt=l.createPopperScope(),[vC,nt]=tp(Wn),np=e=>{const{__scopePopover:n,children:t,open:r,defaultOpen:o,onOpenChange:a,modal:i=!1}=e,c=Xt(n),d=u.useRef(null),[p,f]=u.useState(!1),[m,v]=l.useControllableState({prop:r,defaultProp:o??!1,onChange:a,caller:Wn});return s.jsx(l.Root2,{...c,children:s.jsx(vC,{scope:n,contentId:l.useId(),triggerRef:d,open:m,onOpenChange:v,onOpenToggle:u.useCallback(()=>v(g=>!g),[v]),hasCustomAnchor:p,onCustomAnchorAdd:u.useCallback(()=>f(!0),[]),onCustomAnchorRemove:u.useCallback(()=>f(!1),[]),modal:i,children:t})})};np.displayName=Wn;var rp="PopoverAnchor",gC=u.forwardRef((e,n)=>{const{__scopePopover:t,...r}=e,o=nt(rp,t),a=Xt(t),{onCustomAnchorAdd:i,onCustomAnchorRemove:c}=o;return u.useEffect(()=>(i(),()=>c()),[i,c]),s.jsx(l.Anchor,{...a,...r,ref:n})});gC.displayName=rp;var op="PopoverTrigger",ap=u.forwardRef((e,n)=>{const{__scopePopover:t,...r}=e,o=nt(op,t),a=Xt(t),i=l.useComposedRefs(n,o.triggerRef),c=s.jsx(l.Primitive.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":dp(o.open),...r,ref:i,onClick:l.composeEventHandlers(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?c:s.jsx(l.Anchor,{asChild:!0,...a,children:c})});ap.displayName=op;var wa="PopoverPortal",[hC,xC]=tp(wa,{forceMount:void 0}),ip=e=>{const{__scopePopover:n,forceMount:t,children:r,container:o}=e,a=nt(wa,n);return s.jsx(hC,{scope:n,forceMount:t,children:s.jsx(de,{present:t||a.open,children:s.jsx(l.Portal,{asChild:!0,container:o,children:r})})})};ip.displayName=wa;var Pt="PopoverContent",sp=u.forwardRef((e,n)=>{const t=xC(Pt,e.__scopePopover),{forceMount:r=t.forceMount,...o}=e,a=nt(Pt,e.__scopePopover);return s.jsx(de,{present:r||a.open,children:a.modal?s.jsx(yC,{...o,ref:n}):s.jsx(wC,{...o,ref:n})})});sp.displayName=Pt;var bC=l.createSlot("PopoverContent.RemoveScroll"),yC=u.forwardRef((e,n)=>{const t=nt(Pt,e.__scopePopover),r=u.useRef(null),o=l.useComposedRefs(n,r),a=u.useRef(!1);return u.useEffect(()=>{const i=r.current;if(i)return l.hideOthers(i)},[]),s.jsx(l.ReactRemoveScroll,{as:bC,allowPinchZoom:!0,children:s.jsx(cp,{...e,ref:o,trapFocus:t.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:l.composeEventHandlers(e.onCloseAutoFocus,i=>{var c;i.preventDefault(),a.current||(c=t.triggerRef.current)==null||c.focus()}),onPointerDownOutside:l.composeEventHandlers(e.onPointerDownOutside,i=>{const c=i.detail.originalEvent,d=c.button===0&&c.ctrlKey===!0,p=c.button===2||d;a.current=p},{checkForDefaultPrevented:!1}),onFocusOutside:l.composeEventHandlers(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),wC=u.forwardRef((e,n)=>{const t=nt(Pt,e.__scopePopover),r=u.useRef(!1),o=u.useRef(!1);return s.jsx(cp,{...e,ref:n,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var i,c;(i=e.onCloseAutoFocus)==null||i.call(e,a),a.defaultPrevented||(r.current||(c=t.triggerRef.current)==null||c.focus(),a.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:a=>{var d,p;(d=e.onInteractOutside)==null||d.call(e,a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=a.target;((p=t.triggerRef.current)==null?void 0:p.contains(i))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),cp=u.forwardRef((e,n)=>{const{__scopePopover:t,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,disableOutsidePointerEvents:i,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:p,onInteractOutside:f,...m}=e,v=nt(Pt,t),g=Xt(t);return l.useFocusGuards(),s.jsx(l.FocusScope,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:s.jsx(l.DismissableLayer,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:f,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:p,onDismiss:()=>v.onOpenChange(!1),children:s.jsx(l.Content,{"data-state":dp(v.open),role:"dialog",id:v.contentId,...g,...m,ref:n,style:{...m.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),lp="PopoverClose",CC=u.forwardRef((e,n)=>{const{__scopePopover:t,...r}=e,o=nt(lp,t);return s.jsx(l.Primitive.button,{type:"button",...r,ref:n,onClick:l.composeEventHandlers(e.onClick,()=>o.onOpenChange(!1))})});CC.displayName=lp;var EC="PopoverArrow",_C=u.forwardRef((e,n)=>{const{__scopePopover:t,...r}=e,o=Xt(t);return s.jsx(l.Arrow,{...o,...r,ref:n})});_C.displayName=EC;function dp(e){return e?"open":"closed"}var PC=np,RC=ap,kC=ip,up=sp;const TC=PC,DC=RC,pp=u.forwardRef(({className:e,align:n="center",sideOffset:t=4,...r},o)=>s.jsx(kC,{children:s.jsx(up,{ref:o,align:n,sideOffset:t,className:l.cn("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 w-80 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none",e),...r})}));pp.displayName=up.displayName;var Ca="Radio",[NC,fp]=l.createContextScope(Ca),[MC,SC]=NC(Ca),mp=u.forwardRef((e,n)=>{const{__scopeRadio:t,name:r,checked:o=!1,required:a,disabled:i,value:c="on",onCheck:d,form:p,...f}=e,[m,v]=u.useState(null),g=l.useComposedRefs(n,x=>v(x)),h=u.useRef(!1),b=m?p||!!m.closest("form"):!0;return s.jsxs(MC,{scope:t,checked:o,disabled:i,children:[s.jsx(l.Primitive.button,{type:"button",role:"radio","aria-checked":o,"data-state":xp(o),"data-disabled":i?"":void 0,disabled:i,value:c,...f,ref:g,onClick:l.composeEventHandlers(e.onClick,x=>{o||d==null||d(),b&&(h.current=x.isPropagationStopped(),h.current||x.stopPropagation())})}),b&&s.jsx(hp,{control:m,bubbles:!h.current,name:r,value:c,checked:o,required:a,disabled:i,form:p,style:{transform:"translateX(-100%)"}})]})});mp.displayName=Ca;var vp="RadioIndicator",gp=u.forwardRef((e,n)=>{const{__scopeRadio:t,forceMount:r,...o}=e,a=SC(vp,t);return s.jsx(de,{present:r||a.checked,children:s.jsx(l.Primitive.span,{"data-state":xp(a.checked),"data-disabled":a.disabled?"":void 0,...o,ref:n})})});gp.displayName=vp;var jC="RadioBubbleInput",hp=u.forwardRef(({__scopeRadio:e,control:n,checked:t,bubbles:r=!0,...o},a)=>{const i=u.useRef(null),c=l.useComposedRefs(i,a),d=l.usePrevious(t),p=l.useSize(n);return u.useEffect(()=>{const f=i.current;if(!f)return;const m=window.HTMLInputElement.prototype,g=Object.getOwnPropertyDescriptor(m,"checked").set;if(d!==t&&g){const h=new Event("click",{bubbles:r});g.call(f,t),f.dispatchEvent(h)}},[d,t,r]),s.jsx(l.Primitive.input,{type:"radio","aria-hidden":!0,defaultChecked:t,...o,tabIndex:-1,ref:c,style:{...o.style,...p,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});hp.displayName=jC;function xp(e){return e?"checked":"unchecked"}var IC=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],zn="RadioGroup",[AC,r_]=l.createContextScope(zn,[et,fp]),bp=et(),yp=fp(),[OC,FC]=AC(zn),wp=u.forwardRef((e,n)=>{const{__scopeRadioGroup:t,name:r,defaultValue:o,value:a,required:i=!1,disabled:c=!1,orientation:d,dir:p,loop:f=!0,onValueChange:m,...v}=e,g=bp(t),h=l.useDirection(p),[b,x]=l.useControllableState({prop:a,defaultProp:o??null,onChange:m,caller:zn});return s.jsx(OC,{scope:t,name:r,required:i,disabled:c,value:b,onValueChange:x,children:s.jsx(An,{asChild:!0,...g,orientation:d,dir:h,loop:f,children:s.jsx(l.Primitive.div,{role:"radiogroup","aria-required":i,"aria-orientation":d,"data-disabled":c?"":void 0,dir:h,...v,ref:n})})})});wp.displayName=zn;var Cp="RadioGroupItem",Ep=u.forwardRef((e,n)=>{const{__scopeRadioGroup:t,disabled:r,...o}=e,a=FC(Cp,t),i=a.disabled||r,c=bp(t),d=yp(t),p=u.useRef(null),f=l.useComposedRefs(n,p),m=a.value===o.value,v=u.useRef(!1);return u.useEffect(()=>{const g=b=>{IC.includes(b.key)&&(v.current=!0)},h=()=>v.current=!1;return document.addEventListener("keydown",g),document.addEventListener("keyup",h),()=>{document.removeEventListener("keydown",g),document.removeEventListener("keyup",h)}},[]),s.jsx(On,{asChild:!0,...c,focusable:!i,active:m,children:s.jsx(mp,{disabled:i,required:a.required,checked:m,...d,...o,name:a.name,ref:f,onCheck:()=>a.onValueChange(o.value),onKeyDown:l.composeEventHandlers(g=>{g.key==="Enter"&&g.preventDefault()}),onFocus:l.composeEventHandlers(o.onFocus,()=>{var g;v.current&&((g=p.current)==null||g.click())})})})});Ep.displayName=Cp;var LC="RadioGroupIndicator",_p=u.forwardRef((e,n)=>{const{__scopeRadioGroup:t,...r}=e,o=yp(t);return s.jsx(gp,{...o,...r,ref:n})});_p.displayName=LC;var Pp=wp,Rp=Ep,$C=_p;const kp=u.forwardRef(({className:e,...n},t)=>s.jsx(Pp,{className:l.cn("grid gap-2",e),...n,ref:t}));kp.displayName=Pp.displayName;const Tp=u.forwardRef(({className:e,checked:n,size:t,...r},o)=>s.jsx(Rp,{ref:o,"data-slot":"radio-group-item",className:l.cn("aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive shadow-xs aspect-square size-4 shrink-0 rounded-full border border-grey-300 text-primary outline-none transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 dark:bg-input/30 md:size-[18px]",e),...r,children:s.jsx($C,{"data-slot":"radio-group-indicator",className:"relative flex items-center justify-center",children:s.jsx(xc,{className:"absolute left-1/2 top-1/2 size-2 -translate-x-1/2 -translate-y-1/2 fill-primary md:size-[10px]"})})}));Tp.displayName=Rp.displayName;var HC="Separator",Pi="horizontal",WC=["horizontal","vertical"],Dp=u.forwardRef((e,n)=>{const{decorative:t,orientation:r=Pi,...o}=e,a=zC(r)?r:Pi,c=t?{role:"none"}:{"aria-orientation":a==="vertical"?a:void 0,role:"separator"};return s.jsx(l.Primitive.div,{"data-orientation":a,...c,...o,ref:n})});Dp.displayName=HC;function zC(e){return WC.includes(e)}var Np=Dp;const Mp=u.forwardRef(({className:e,orientation:n="horizontal",decorative:t=!0,...r},o)=>s.jsx(Np,{ref:o,decorative:t,orientation:n,className:l.cn("shrink-0 bg-border",n==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...r}));Mp.displayName=Np.displayName;var Yn="Switch",[YC,o_]=l.createContextScope(Yn),[VC,GC]=YC(Yn),Sp=u.forwardRef((e,n)=>{const{__scopeSwitch:t,name:r,checked:o,defaultChecked:a,required:i,disabled:c,value:d="on",onCheckedChange:p,form:f,...m}=e,[v,g]=u.useState(null),h=l.useComposedRefs(n,P=>g(P)),b=u.useRef(!1),x=v?f||!!v.closest("form"):!0,[E,w]=l.useControllableState({prop:o,defaultProp:a??!1,onChange:p,caller:Yn});return s.jsxs(VC,{scope:t,checked:E,disabled:c,children:[s.jsx(l.Primitive.button,{type:"button",role:"switch","aria-checked":E,"aria-required":i,"data-state":Op(E),"data-disabled":c?"":void 0,disabled:c,value:d,...m,ref:h,onClick:l.composeEventHandlers(e.onClick,P=>{w(_=>!_),x&&(b.current=P.isPropagationStopped(),b.current||P.stopPropagation())})}),x&&s.jsx(Ap,{control:v,bubbles:!b.current,name:r,value:d,checked:E,required:i,disabled:c,form:f,style:{transform:"translateX(-100%)"}})]})});Sp.displayName=Yn;var jp="SwitchThumb",Ip=u.forwardRef((e,n)=>{const{__scopeSwitch:t,...r}=e,o=GC(jp,t);return s.jsx(l.Primitive.span,{"data-state":Op(o.checked),"data-disabled":o.disabled?"":void 0,...r,ref:n})});Ip.displayName=jp;var qC="SwitchBubbleInput",Ap=u.forwardRef(({__scopeSwitch:e,control:n,checked:t,bubbles:r=!0,...o},a)=>{const i=u.useRef(null),c=l.useComposedRefs(i,a),d=l.usePrevious(t),p=l.useSize(n);return u.useEffect(()=>{const f=i.current;if(!f)return;const m=window.HTMLInputElement.prototype,g=Object.getOwnPropertyDescriptor(m,"checked").set;if(d!==t&&g){const h=new Event("click",{bubbles:r});g.call(f,t),f.dispatchEvent(h)}},[d,t,r]),s.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:t,...o,tabIndex:-1,ref:c,style:{...o.style,...p,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});Ap.displayName=qC;function Op(e){return e?"checked":"unchecked"}var Fp=Sp,BC=Ip;const Lp=u.forwardRef(({className:e,...n},t)=>s.jsx(Fp,{className:l.cn("peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...n,ref:t,children:s.jsx(BC,{className:l.cn("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0")})}));Lp.displayName=Fp.displayName;var Vn="Tabs",[KC,a_]=l.createContextScope(Vn,[et]),$p=et(),[UC,Ea]=KC(Vn),Hp=u.forwardRef((e,n)=>{const{__scopeTabs:t,value:r,onValueChange:o,defaultValue:a,orientation:i="horizontal",dir:c,activationMode:d="automatic",...p}=e,f=l.useDirection(c),[m,v]=l.useControllableState({prop:r,onChange:o,defaultProp:a??"",caller:Vn});return s.jsx(UC,{scope:t,baseId:l.useId(),value:m,onValueChange:v,orientation:i,dir:f,activationMode:d,children:s.jsx(l.Primitive.div,{dir:f,"data-orientation":i,...p,ref:n})})});Hp.displayName=Vn;var Wp="TabsList",zp=u.forwardRef((e,n)=>{const{__scopeTabs:t,loop:r=!0,...o}=e,a=Ea(Wp,t),i=$p(t);return s.jsx(An,{asChild:!0,...i,orientation:a.orientation,dir:a.dir,loop:r,children:s.jsx(l.Primitive.div,{role:"tablist","aria-orientation":a.orientation,...o,ref:n})})});zp.displayName=Wp;var Yp="TabsTrigger",Vp=u.forwardRef((e,n)=>{const{__scopeTabs:t,value:r,disabled:o=!1,...a}=e,i=Ea(Yp,t),c=$p(t),d=Bp(i.baseId,r),p=Kp(i.baseId,r),f=r===i.value;return s.jsx(On,{asChild:!0,...c,focusable:!o,active:f,children:s.jsx(l.Primitive.button,{type:"button",role:"tab","aria-selected":f,"aria-controls":p,"data-state":f?"active":"inactive","data-disabled":o?"":void 0,disabled:o,id:d,...a,ref:n,onMouseDown:l.composeEventHandlers(e.onMouseDown,m=>{!o&&m.button===0&&m.ctrlKey===!1?i.onValueChange(r):m.preventDefault()}),onKeyDown:l.composeEventHandlers(e.onKeyDown,m=>{[" ","Enter"].includes(m.key)&&i.onValueChange(r)}),onFocus:l.composeEventHandlers(e.onFocus,()=>{const m=i.activationMode!=="manual";!f&&!o&&m&&i.onValueChange(r)})})})});Vp.displayName=Yp;var Gp="TabsContent",qp=u.forwardRef((e,n)=>{const{__scopeTabs:t,value:r,forceMount:o,children:a,...i}=e,c=Ea(Gp,t),d=Bp(c.baseId,r),p=Kp(c.baseId,r),f=r===c.value,m=u.useRef(f);return u.useEffect(()=>{const v=requestAnimationFrame(()=>m.current=!1);return()=>cancelAnimationFrame(v)},[]),s.jsx(de,{present:o||f,children:({present:v})=>s.jsx(l.Primitive.div,{"data-state":f?"active":"inactive","data-orientation":c.orientation,role:"tabpanel","aria-labelledby":d,hidden:!v,id:p,tabIndex:0,...i,ref:n,style:{...e.style,animationDuration:m.current?"0s":void 0},children:v&&a})})});qp.displayName=Gp;function Bp(e,n){return`${e}-trigger-${n}`}function Kp(e,n){return`${e}-content-${n}`}var XC=Hp,Up=zp,Xp=Vp,Qp=qp;const QC=XC,Zp=u.forwardRef(({className:e,...n},t)=>s.jsx(Up,{ref:t,className:l.cn("inline-flex items-center justify-center rounded-lg bg-grey-200 p-1 text-grey-600",e),...n}));Zp.displayName=Up.displayName;const Jp=u.forwardRef(({className:e,...n},t)=>s.jsx(Xp,{ref:t,className:l.cn("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",e),...n}));Jp.displayName=Xp.displayName;const ef=u.forwardRef(({className:e,...n},t)=>s.jsx(Qp,{ref:t,className:l.cn("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...n}));ef.displayName=Qp.displayName;const tf=u.forwardRef(({className:e,error:n,...t},r)=>s.jsx("textarea",{className:l.cn("flex min-h-[72px] w-full rounded-md border bg-background px-3 py-2 text-sm font-normal placeholder:text-sm placeholder:text-muted focus-visible:outline-none disabled:cursor-not-allowed disabled:opacity-50 md:px-4 md:py-2.5 md:text-base placeholder:md:text-base",n?"border-red-600 focus:border-red-600":"border-border focus:border-grey-800",e),ref:r,placeholder:"테스트",...t}));tf.displayName="Textarea";var _a="ToastProvider",[Pa,ZC,JC]=l.createCollection("Toast"),[nf,i_]=l.createContextScope("Toast",[JC]),[eE,Gn]=nf(_a),rf=e=>{const{__scopeToast:n,label:t="Notification",duration:r=5e3,swipeDirection:o="right",swipeThreshold:a=50,children:i}=e,[c,d]=u.useState(null),[p,f]=u.useState(0),m=u.useRef(!1),v=u.useRef(!1);return t.trim()||console.error(`Invalid prop \`label\` supplied to \`${_a}\`. Expected non-empty \`string\`.`),s.jsx(Pa.Provider,{scope:n,children:s.jsx(eE,{scope:n,label:t,duration:r,swipeDirection:o,swipeThreshold:a,toastCount:p,viewport:c,onViewportChange:d,onToastAdd:u.useCallback(()=>f(g=>g+1),[]),onToastRemove:u.useCallback(()=>f(g=>g-1),[]),isFocusedToastEscapeKeyDownRef:m,isClosePausedRef:v,children:i})})};rf.displayName=_a;var of="ToastViewport",tE=["F8"],no="toast.viewportPause",ro="toast.viewportResume",af=u.forwardRef((e,n)=>{const{__scopeToast:t,hotkey:r=tE,label:o="Notifications ({hotkey})",...a}=e,i=Gn(of,t),c=ZC(t),d=u.useRef(null),p=u.useRef(null),f=u.useRef(null),m=u.useRef(null),v=l.useComposedRefs(n,m,i.onViewportChange),g=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),h=i.toastCount>0;u.useEffect(()=>{const x=E=>{var P;r.length!==0&&r.every(_=>E[_]||E.code===_)&&((P=m.current)==null||P.focus())};return document.addEventListener("keydown",x),()=>document.removeEventListener("keydown",x)},[r]),u.useEffect(()=>{const x=d.current,E=m.current;if(h&&x&&E){const w=()=>{if(!i.isClosePausedRef.current){const T=new CustomEvent(no);E.dispatchEvent(T),i.isClosePausedRef.current=!0}},P=()=>{if(i.isClosePausedRef.current){const T=new CustomEvent(ro);E.dispatchEvent(T),i.isClosePausedRef.current=!1}},_=T=>{!x.contains(T.relatedTarget)&&P()},y=()=>{x.contains(document.activeElement)||P()};return x.addEventListener("focusin",w),x.addEventListener("focusout",_),x.addEventListener("pointermove",w),x.addEventListener("pointerleave",y),window.addEventListener("blur",w),window.addEventListener("focus",P),()=>{x.removeEventListener("focusin",w),x.removeEventListener("focusout",_),x.removeEventListener("pointermove",w),x.removeEventListener("pointerleave",y),window.removeEventListener("blur",w),window.removeEventListener("focus",P)}}},[h,i.isClosePausedRef]);const b=u.useCallback(({tabbingDirection:x})=>{const w=c().map(P=>{const _=P.ref.current,y=[_,...mE(_)];return x==="forwards"?y:y.reverse()});return(x==="forwards"?w.reverse():w).flat()},[c]);return u.useEffect(()=>{const x=m.current;if(x){const E=w=>{var y,T,$;const P=w.altKey||w.ctrlKey||w.metaKey;if(w.key==="Tab"&&!P){const V=document.activeElement,A=w.shiftKey;if(w.target===x&&A){(y=p.current)==null||y.focus();return}const te=b({tabbingDirection:A?"backwards":"forwards"}),re=te.findIndex(I=>I===V);Sr(te.slice(re+1))?w.preventDefault():A?(T=p.current)==null||T.focus():($=f.current)==null||$.focus()}};return x.addEventListener("keydown",E),()=>x.removeEventListener("keydown",E)}},[c,b]),s.jsxs(l.Branch,{ref:d,role:"region","aria-label":o.replace("{hotkey}",g),tabIndex:-1,style:{pointerEvents:h?void 0:"none"},children:[h&&s.jsx(oo,{ref:p,onFocusFromOutsideViewport:()=>{const x=b({tabbingDirection:"forwards"});Sr(x)}}),s.jsx(Pa.Slot,{scope:t,children:s.jsx(l.Primitive.ol,{tabIndex:-1,...a,ref:v})}),h&&s.jsx(oo,{ref:f,onFocusFromOutsideViewport:()=>{const x=b({tabbingDirection:"backwards"});Sr(x)}})]})});af.displayName=of;var sf="ToastFocusProxy",oo=u.forwardRef((e,n)=>{const{__scopeToast:t,onFocusFromOutsideViewport:r,...o}=e,a=Gn(sf,t);return s.jsx(l.VisuallyHidden,{"aria-hidden":!0,tabIndex:0,...o,ref:n,style:{position:"fixed"},onFocus:i=>{var p;const c=i.relatedTarget;!((p=a.viewport)!=null&&p.contains(c))&&r()}})});oo.displayName=sf;var Qt="Toast",nE="toast.swipeStart",rE="toast.swipeMove",oE="toast.swipeCancel",aE="toast.swipeEnd",cf=u.forwardRef((e,n)=>{const{forceMount:t,open:r,defaultOpen:o,onOpenChange:a,...i}=e,[c,d]=l.useControllableState({prop:r,defaultProp:o??!0,onChange:a,caller:Qt});return s.jsx(de,{present:t||c,children:s.jsx(cE,{open:c,...i,ref:n,onClose:()=>d(!1),onPause:l.useCallbackRef(e.onPause),onResume:l.useCallbackRef(e.onResume),onSwipeStart:l.composeEventHandlers(e.onSwipeStart,p=>{p.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:l.composeEventHandlers(e.onSwipeMove,p=>{const{x:f,y:m}=p.detail.delta;p.currentTarget.setAttribute("data-swipe","move"),p.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${f}px`),p.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${m}px`)}),onSwipeCancel:l.composeEventHandlers(e.onSwipeCancel,p=>{p.currentTarget.setAttribute("data-swipe","cancel"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),p.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:l.composeEventHandlers(e.onSwipeEnd,p=>{const{x:f,y:m}=p.detail.delta;p.currentTarget.setAttribute("data-swipe","end"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),p.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${f}px`),p.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${m}px`),d(!1)})})})});cf.displayName=Qt;var[iE,sE]=nf(Qt,{onClose(){}}),cE=u.forwardRef((e,n)=>{const{__scopeToast:t,type:r="foreground",duration:o,open:a,onClose:i,onEscapeKeyDown:c,onPause:d,onResume:p,onSwipeStart:f,onSwipeMove:m,onSwipeCancel:v,onSwipeEnd:g,...h}=e,b=Gn(Qt,t),[x,E]=u.useState(null),w=l.useComposedRefs(n,I=>E(I)),P=u.useRef(null),_=u.useRef(null),y=o||b.duration,T=u.useRef(0),$=u.useRef(y),V=u.useRef(0),{onToastAdd:A,onToastRemove:q}=b,K=l.useCallbackRef(()=>{var Q;(x==null?void 0:x.contains(document.activeElement))&&((Q=b.viewport)==null||Q.focus()),i()}),te=u.useCallback(I=>{!I||I===1/0||(window.clearTimeout(V.current),T.current=new Date().getTime(),V.current=window.setTimeout(K,I))},[K]);u.useEffect(()=>{const I=b.viewport;if(I){const Q=()=>{te($.current),p==null||p()},J=()=>{const j=new Date().getTime()-T.current;$.current=$.current-j,window.clearTimeout(V.current),d==null||d()};return I.addEventListener(no,J),I.addEventListener(ro,Q),()=>{I.removeEventListener(no,J),I.removeEventListener(ro,Q)}}},[b.viewport,y,d,p,te]),u.useEffect(()=>{a&&!b.isClosePausedRef.current&&te(y)},[a,y,b.isClosePausedRef,te]),u.useEffect(()=>(A(),()=>q()),[A,q]);const re=u.useMemo(()=>x?vf(x):null,[x]);return b.viewport?s.jsxs(s.Fragment,{children:[re&&s.jsx(lE,{__scopeToast:t,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0,children:re}),s.jsx(iE,{scope:t,onClose:K,children:am.createPortal(s.jsx(Pa.ItemSlot,{scope:t,children:s.jsx(l.Root$1,{asChild:!0,onEscapeKeyDown:l.composeEventHandlers(c,()=>{b.isFocusedToastEscapeKeyDownRef.current||K(),b.isFocusedToastEscapeKeyDownRef.current=!1}),children:s.jsx(l.Primitive.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":a?"open":"closed","data-swipe-direction":b.swipeDirection,...h,ref:w,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:l.composeEventHandlers(e.onKeyDown,I=>{I.key==="Escape"&&(c==null||c(I.nativeEvent),I.nativeEvent.defaultPrevented||(b.isFocusedToastEscapeKeyDownRef.current=!0,K()))}),onPointerDown:l.composeEventHandlers(e.onPointerDown,I=>{I.button===0&&(P.current={x:I.clientX,y:I.clientY})}),onPointerMove:l.composeEventHandlers(e.onPointerMove,I=>{if(!P.current)return;const Q=I.clientX-P.current.x,J=I.clientY-P.current.y,j=!!_.current,F=["left","right"].includes(b.swipeDirection),H=["left","up"].includes(b.swipeDirection)?Math.min:Math.max,k=F?H(0,Q):0,S=F?0:H(0,J),R=I.pointerType==="touch"?10:2,D={x:k,y:S},M={originalEvent:I,delta:D};j?(_.current=D,on(rE,m,M,{discrete:!1})):Ri(D,b.swipeDirection,R)?(_.current=D,on(nE,f,M,{discrete:!1}),I.target.setPointerCapture(I.pointerId)):(Math.abs(Q)>R||Math.abs(J)>R)&&(P.current=null)}),onPointerUp:l.composeEventHandlers(e.onPointerUp,I=>{const Q=_.current,J=I.target;if(J.hasPointerCapture(I.pointerId)&&J.releasePointerCapture(I.pointerId),_.current=null,P.current=null,Q){const j=I.currentTarget,F={originalEvent:I,delta:Q};Ri(Q,b.swipeDirection,b.swipeThreshold)?on(aE,g,F,{discrete:!0}):on(oE,v,F,{discrete:!0}),j.addEventListener("click",H=>H.preventDefault(),{once:!0})}})})})}),b.viewport)})]}):null}),lE=e=>{const{__scopeToast:n,children:t,...r}=e,o=Gn(Qt,n),[a,i]=u.useState(!1),[c,d]=u.useState(!1);return pE(()=>i(!0)),u.useEffect(()=>{const p=window.setTimeout(()=>d(!0),1e3);return()=>window.clearTimeout(p)},[]),c?null:s.jsx(l.Portal,{asChild:!0,children:s.jsx(l.VisuallyHidden,{...r,children:a&&s.jsxs(s.Fragment,{children:[o.label," ",t]})})})},dE="ToastTitle",lf=u.forwardRef((e,n)=>{const{__scopeToast:t,...r}=e;return s.jsx(l.Primitive.div,{...r,ref:n})});lf.displayName=dE;var uE="ToastDescription",df=u.forwardRef((e,n)=>{const{__scopeToast:t,...r}=e;return s.jsx(l.Primitive.div,{...r,ref:n})});df.displayName=uE;var uf="ToastAction",pf=u.forwardRef((e,n)=>{const{altText:t,...r}=e;return t.trim()?s.jsx(mf,{altText:t,asChild:!0,children:s.jsx(Ra,{...r,ref:n})}):(console.error(`Invalid prop \`altText\` supplied to \`${uf}\`. Expected non-empty \`string\`.`),null)});pf.displayName=uf;var ff="ToastClose",Ra=u.forwardRef((e,n)=>{const{__scopeToast:t,...r}=e,o=sE(ff,t);return s.jsx(mf,{asChild:!0,children:s.jsx(l.Primitive.button,{type:"button",...r,ref:n,onClick:l.composeEventHandlers(e.onClick,o.onClose)})})});Ra.displayName=ff;var mf=u.forwardRef((e,n)=>{const{__scopeToast:t,altText:r,...o}=e;return s.jsx(l.Primitive.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...o,ref:n})});function vf(e){const n=[];return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&n.push(r.textContent),fE(r)){const o=r.ariaHidden||r.hidden||r.style.display==="none",a=r.dataset.radixToastAnnounceExclude==="";if(!o)if(a){const i=r.dataset.radixToastAnnounceAlt;i&&n.push(i)}else n.push(...vf(r))}}),n}function on(e,n,t,{discrete:r}){const o=t.originalEvent.currentTarget,a=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:t});n&&o.addEventListener(e,n,{once:!0}),r?l.dispatchDiscreteCustomEvent(o,a):o.dispatchEvent(a)}var Ri=(e,n,t=0)=>{const r=Math.abs(e.x),o=Math.abs(e.y),a=r>o;return n==="left"||n==="right"?a&&r>t:!a&&o>t};function pE(e=()=>{}){const n=l.useCallbackRef(e);l.useLayoutEffect2(()=>{let t=0,r=0;return t=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(n)),()=>{window.cancelAnimationFrame(t),window.cancelAnimationFrame(r)}},[n])}function fE(e){return e.nodeType===e.ELEMENT_NODE}function mE(e){const n=[],t=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;t.nextNode();)n.push(t.currentNode);return n}function Sr(e){const n=document.activeElement;return e.some(t=>t===n?!0:(t.focus(),document.activeElement!==n))}var gf=rf,qn=af,Bn=cf,Kn=lf,Un=df,Xn=pf,Qn=Ra;const vE=gf,hf={"top-left":"top-0 left-0 bottom-auto mt-10 items-start","top-center":"top-0 left-1/2 bottom-auto transform -translate-x-1/2 mt-10 items-center","top-right":"top-0 right-0 bottom-auto items-end mt-10","bottom-left":"top-auto bottom-4 left-0 items-start","bottom-center":"top-auto bottom-4 left-1/2 transform -translate-x-1/2 items-center","bottom-right":"top-auto bottom-4 right-0 items-end"},xf=u.forwardRef(({className:e,id:n,position:t="top-center",...r},o)=>s.jsx(qn,{ref:o,id:n,className:l.cn("fixed z-[100] flex flex-col-reverse gap-2 p-4 outline-none ring-transparent md:p-10",hf[t],e),...r}));xf.displayName=qn.displayName;const bf=Ke("group pointer-events-auto bg-opacity-90 overflow-hidden rounded-lg border shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-top-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-top-full",{variants:{variant:{black:"group border bg-grey-800 border-grey-800 text-grey-50",white:"group border bg-grey-50 border-grey-50 text-grey-800"},size:{sm:"w-[300px]",md:"w-[400px]",lg:"w-[600px]",xl:"w-[800px]",full:"w-[90vw]",fit:"w-fit"}},defaultVariants:{variant:"black",size:"fit"}}),yf=u.forwardRef(({className:e,variant:n,size:t,...r},o)=>s.jsx(Bn,{ref:o,className:l.cn(bf({variant:n,size:t}),e),duration:3e3,...r}));yf.displayName=Bn.displayName;const wf=u.forwardRef(({className:e,...n},t)=>s.jsx(Xn,{ref:t,className:l.cn(Me({variant:"outline",size:"sm",theme:"secondary"}),e),...n}));wf.displayName=Xn.displayName;const Cf=u.forwardRef(({className:e,children:n,...t},r)=>s.jsx(Qn,{ref:r,className:l.cn("absolute right-1.5 top-1.5 rounded-md p-1 focus:outline-none",e),"toast-close":"",...t,children:n}));Cf.displayName=Qn.displayName;const Ef=u.forwardRef(({className:e,...n},t)=>s.jsx(Kn,{ref:t,className:l.cn("text-sm font-semibold",e),...n}));Ef.displayName=Kn.displayName;const _f=u.forwardRef(({className:e,...n},t)=>s.jsx(Un,{ref:t,className:l.cn("text-sm font-normal",e),...n}));_f.displayName=Un.displayName;const gE=gf,hE=Ke("fixed inset-0 z-50 flex items-center justify-center p-4",{variants:{isOpen:{close:"",open:"bg-black bg-opacity-50"}},defaultVariants:{isOpen:"close"}}),Pf=u.forwardRef(({className:e,isOpen:n,...t},r)=>s.jsx(qn,{ref:r,className:l.cn(hE({isOpen:n}),e),...t}));Pf.displayName=qn.displayName;const xE=Ke("relative w-full px-6 py-4 rounded-md shadow-lg",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"},width:{xs:"max-w-[330px]",sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",full:"max-w-full w-[90%]",fit:"max-w-fit"},closeType:{force:!0,free:!1}},defaultVariants:{variant:"default",width:"md",closeType:"free"}}),Rf=u.forwardRef(({className:e,variant:n,width:t,closeType:r,...o},a)=>s.jsx(Bn,{ref:a,className:l.cn(xE({variant:n,width:t,closeType:r}),e),...o,duration:1/0,onEscapeKeyDown:i=>{r&&i.preventDefault()}}));Rf.displayName=Bn.displayName;const kf=u.forwardRef(({className:e,size:n,variant:t,children:r,...o},a)=>s.jsx(Xn,{ref:a,className:l.cn(Me({size:n,variant:t}),e),...o,children:r}));kf.displayName=Xn.displayName;const Tf=u.forwardRef(({className:e,size:n,variant:t,children:r,...o},a)=>s.jsx(Qn,{ref:a,className:l.cn(Me({size:n,variant:t}),e),...o,children:r}));Tf.displayName=Qn.displayName;const Df=u.forwardRef(({className:e,...n},t)=>s.jsx(Kn,{ref:t,className:l.cn("break-keep text-lg font-semibold text-foreground",e),...n}));Df.displayName=Kn.displayName;const Nf=u.forwardRef(({className:e,...n},t)=>s.jsx(Un,{ref:t,className:l.cn("whitespace-pre-wrap text-xs font-normal text-grey-600",e),...n}));Nf.displayName=Un.displayName;const bE=({className:e,children:n})=>s.jsx("div",{className:l.cn("flex w-full flex-col gap-4",e),children:n});var Mf="Toggle",ka=u.forwardRef((e,n)=>{const{pressed:t,defaultPressed:r,onPressedChange:o,...a}=e,[i,c]=l.useControllableState({prop:t,onChange:o,defaultProp:r??!1,caller:Mf});return s.jsx(l.Primitive.button,{type:"button","aria-pressed":i,"data-state":i?"on":"off","data-disabled":e.disabled?"":void 0,...a,ref:n,onClick:l.composeEventHandlers(e.onClick,()=>{e.disabled||c(!i)})})});ka.displayName=Mf;var Sf=ka;const Ta=Ke("inline-flex items-center justify-center gap-1 whitespace-nowrap text-sm font-normal ring-offset-background transition-all focus-visible:outline-none disabled:pointer-events-none",{variants:{variant:{solid:"disabled:bg-muted disabled:text-muted-foreground disabled:border-muted",outline:"disabled:bg-white disabled:text-muted disabled:border-border"},theme:{primary:"bg-white border border-main-200 text-primary hover:bg-main-100",secondary:"bg-white border border-grey-200 text-secondary hover:bg-grey-100"},size:{xs:"h-8 py-1 px-2 text-sm",sm:"h-9 py-2 px-3 text-sm",md:"h-11 px-3 py-3 text-sm",lg:"h-[52px] px-12 py-[14px] text-base",icon:"h-auto w-auto"},shape:{square:"rounded-lg",rounded:"rounded-full"},checked:{true:"",false:""}},compoundVariants:[{theme:"primary",checked:!0,className:"bg-main-600 border-main-600 text-white hover:bg-main-700 hover:border-main-700"},{theme:"secondary",checked:!0,className:"bg-grey-800 border-grey-800 text-white hover:bg-grey-900 hover:border-grey-900"}],defaultVariants:{theme:"primary",size:"md",shape:"square",checked:!1}}),jf=u.forwardRef(({className:e,variant:n,size:t,theme:r,checked:o,...a},i)=>s.jsx(Sf,{ref:i,className:l.cn(Ta({variant:n,size:t,className:e,theme:r,checked:o})),...a}));jf.displayName=Sf.displayName;var rt="ToggleGroup",[If,s_]=l.createContextScope(rt,[et]),Af=et(),Da=C.forwardRef((e,n)=>{const{type:t,...r}=e;if(t==="single"){const o=r;return s.jsx(yE,{...o,ref:n})}if(t==="multiple"){const o=r;return s.jsx(wE,{...o,ref:n})}throw new Error(`Missing prop \`type\` expected on \`${rt}\``)});Da.displayName=rt;var[Of,Ff]=If(rt),yE=C.forwardRef((e,n)=>{const{value:t,defaultValue:r,onValueChange:o=()=>{},...a}=e,[i,c]=l.useControllableState({prop:t,defaultProp:r??"",onChange:o,caller:rt});return s.jsx(Of,{scope:e.__scopeToggleGroup,type:"single",value:C.useMemo(()=>i?[i]:[],[i]),onItemActivate:c,onItemDeactivate:C.useCallback(()=>c(""),[c]),children:s.jsx(Lf,{...a,ref:n})})}),wE=C.forwardRef((e,n)=>{const{value:t,defaultValue:r,onValueChange:o=()=>{},...a}=e,[i,c]=l.useControllableState({prop:t,defaultProp:r??[],onChange:o,caller:rt}),d=C.useCallback(f=>c((m=[])=>[...m,f]),[c]),p=C.useCallback(f=>c((m=[])=>m.filter(v=>v!==f)),[c]);return s.jsx(Of,{scope:e.__scopeToggleGroup,type:"multiple",value:i,onItemActivate:d,onItemDeactivate:p,children:s.jsx(Lf,{...a,ref:n})})});Da.displayName=rt;var[CE,EE]=If(rt),Lf=C.forwardRef((e,n)=>{const{__scopeToggleGroup:t,disabled:r=!1,rovingFocus:o=!0,orientation:a,dir:i,loop:c=!0,...d}=e,p=Af(t),f=l.useDirection(i),m={role:"group",dir:f,...d};return s.jsx(CE,{scope:t,rovingFocus:o,disabled:r,children:o?s.jsx(An,{asChild:!0,...p,orientation:a,dir:f,loop:c,children:s.jsx(l.Primitive.div,{...m,ref:n})}):s.jsx(l.Primitive.div,{...m,ref:n})})}),wn="ToggleGroupItem",$f=C.forwardRef((e,n)=>{const t=Ff(wn,e.__scopeToggleGroup),r=EE(wn,e.__scopeToggleGroup),o=Af(e.__scopeToggleGroup),a=t.value.includes(e.value),i=r.disabled||e.disabled,c={...e,pressed:a,disabled:i},d=C.useRef(null);return r.rovingFocus?s.jsx(On,{asChild:!0,...o,focusable:!i,active:a,ref:d,children:s.jsx(ki,{...c,ref:n})}):s.jsx(ki,{...c,ref:n})});$f.displayName=wn;var ki=C.forwardRef((e,n)=>{const{__scopeToggleGroup:t,value:r,...o}=e,a=Ff(wn,t),i={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},c=a.type==="single"?i:void 0;return s.jsx(ka,{...c,...o,ref:n,onPressedChange:d=>{d?a.onItemActivate(r):a.onItemDeactivate(r)}})}),Hf=Da,Wf=$f;const Na=u.createContext({theme:"primary",size:"md",shape:"square"});Na.displayName="ToggleGroupContext";const zf=u.forwardRef(({className:e,variant:n,theme:t,size:r,shape:o,children:a,...i},c)=>s.jsx(Na.Provider,{value:{theme:t,size:r,shape:o},children:s.jsx(Hf,{ref:c,className:l.cn("flex items-center justify-center gap-1",e),...i,children:a})}));zf.displayName=Hf.displayName;const Yf=u.forwardRef(({className:e,checked:n=!1,children:t,...r},o)=>{const a=u.useContext(Na);return s.jsx(Wf,{ref:o,className:l.cn(Ta({theme:r.theme||a.theme||"primary",size:r.size||a.size||"md",shape:r.shape||a.shape||"square",variant:r.variant||"outline",checked:n}),e),...r,children:t})});Yf.displayName=Wf.displayName;var[Zn,c_]=l.createContextScope("Tooltip",[l.createPopperScope]),Jn=l.createPopperScope(),Vf="TooltipProvider",_E=700,ao="tooltip.open",[PE,Ma]=Zn(Vf),Gf=e=>{const{__scopeTooltip:n,delayDuration:t=_E,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:a}=e,i=u.useRef(!0),c=u.useRef(!1),d=u.useRef(0);return u.useEffect(()=>{const p=d.current;return()=>window.clearTimeout(p)},[]),s.jsx(PE,{scope:n,isOpenDelayedRef:i,delayDuration:t,onOpen:u.useCallback(()=>{window.clearTimeout(d.current),i.current=!1},[]),onClose:u.useCallback(()=>{window.clearTimeout(d.current),d.current=window.setTimeout(()=>i.current=!0,r)},[r]),isPointerInTransitRef:c,onPointerInTransitChange:u.useCallback(p=>{c.current=p},[]),disableHoverableContent:o,children:a})};Gf.displayName=Vf;var Ft="Tooltip",[RE,er]=Zn(Ft),qf=e=>{const{__scopeTooltip:n,children:t,open:r,defaultOpen:o,onOpenChange:a,disableHoverableContent:i,delayDuration:c}=e,d=Ma(Ft,e.__scopeTooltip),p=Jn(n),[f,m]=u.useState(null),v=l.useId(),g=u.useRef(0),h=i??d.disableHoverableContent,b=c??d.delayDuration,x=u.useRef(!1),[E,w]=l.useControllableState({prop:r,defaultProp:o??!1,onChange:$=>{$?(d.onOpen(),document.dispatchEvent(new CustomEvent(ao))):d.onClose(),a==null||a($)},caller:Ft}),P=u.useMemo(()=>E?x.current?"delayed-open":"instant-open":"closed",[E]),_=u.useCallback(()=>{window.clearTimeout(g.current),g.current=0,x.current=!1,w(!0)},[w]),y=u.useCallback(()=>{window.clearTimeout(g.current),g.current=0,w(!1)},[w]),T=u.useCallback(()=>{window.clearTimeout(g.current),g.current=window.setTimeout(()=>{x.current=!0,w(!0),g.current=0},b)},[b,w]);return u.useEffect(()=>()=>{g.current&&(window.clearTimeout(g.current),g.current=0)},[]),s.jsx(l.Root2,{...p,children:s.jsx(RE,{scope:n,contentId:v,open:E,stateAttribute:P,trigger:f,onTriggerChange:m,onTriggerEnter:u.useCallback(()=>{d.isOpenDelayedRef.current?T():_()},[d.isOpenDelayedRef,T,_]),onTriggerLeave:u.useCallback(()=>{h?y():(window.clearTimeout(g.current),g.current=0)},[y,h]),onOpen:_,onClose:y,disableHoverableContent:h,children:t})})};qf.displayName=Ft;var io="TooltipTrigger",Bf=u.forwardRef((e,n)=>{const{__scopeTooltip:t,...r}=e,o=er(io,t),a=Ma(io,t),i=Jn(t),c=u.useRef(null),d=l.useComposedRefs(n,c,o.onTriggerChange),p=u.useRef(!1),f=u.useRef(!1),m=u.useCallback(()=>p.current=!1,[]);return u.useEffect(()=>()=>document.removeEventListener("pointerup",m),[m]),s.jsx(l.Anchor,{asChild:!0,...i,children:s.jsx(l.Primitive.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:d,onPointerMove:l.composeEventHandlers(e.onPointerMove,v=>{v.pointerType!=="touch"&&!f.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),f.current=!0)}),onPointerLeave:l.composeEventHandlers(e.onPointerLeave,()=>{o.onTriggerLeave(),f.current=!1}),onPointerDown:l.composeEventHandlers(e.onPointerDown,()=>{o.open&&o.onClose(),p.current=!0,document.addEventListener("pointerup",m,{once:!0})}),onFocus:l.composeEventHandlers(e.onFocus,()=>{p.current||o.onOpen()}),onBlur:l.composeEventHandlers(e.onBlur,o.onClose),onClick:l.composeEventHandlers(e.onClick,o.onClose)})})});Bf.displayName=io;var kE="TooltipPortal",[l_,TE]=Zn(kE,{forceMount:void 0}),Rt="TooltipContent",Kf=u.forwardRef((e,n)=>{const t=TE(Rt,e.__scopeTooltip),{forceMount:r=t.forceMount,side:o="top",...a}=e,i=er(Rt,e.__scopeTooltip);return s.jsx(de,{present:r||i.open,children:i.disableHoverableContent?s.jsx(Uf,{side:o,...a,ref:n}):s.jsx(DE,{side:o,...a,ref:n})})}),DE=u.forwardRef((e,n)=>{const t=er(Rt,e.__scopeTooltip),r=Ma(Rt,e.__scopeTooltip),o=u.useRef(null),a=l.useComposedRefs(n,o),[i,c]=u.useState(null),{trigger:d,onClose:p}=t,f=o.current,{onPointerInTransitChange:m}=r,v=u.useCallback(()=>{c(null),m(!1)},[m]),g=u.useCallback((h,b)=>{const x=h.currentTarget,E={x:h.clientX,y:h.clientY},w=IE(E,x.getBoundingClientRect()),P=AE(E,w),_=OE(b.getBoundingClientRect()),y=LE([...P,..._]);c(y),m(!0)},[m]);return u.useEffect(()=>()=>v(),[v]),u.useEffect(()=>{if(d&&f){const h=x=>g(x,f),b=x=>g(x,d);return d.addEventListener("pointerleave",h),f.addEventListener("pointerleave",b),()=>{d.removeEventListener("pointerleave",h),f.removeEventListener("pointerleave",b)}}},[d,f,g,v]),u.useEffect(()=>{if(i){const h=b=>{const x=b.target,E={x:b.clientX,y:b.clientY},w=(d==null?void 0:d.contains(x))||(f==null?void 0:f.contains(x)),P=!FE(E,i);w?v():P&&(v(),p())};return document.addEventListener("pointermove",h),()=>document.removeEventListener("pointermove",h)}},[d,f,i,p,v]),s.jsx(Uf,{...e,ref:a})}),[NE,ME]=Zn(Ft,{isInside:!1}),SE=l.createSlottable("TooltipContent"),Uf=u.forwardRef((e,n)=>{const{__scopeTooltip:t,children:r,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:i,...c}=e,d=er(Rt,t),p=Jn(t),{onClose:f}=d;return u.useEffect(()=>(document.addEventListener(ao,f),()=>document.removeEventListener(ao,f)),[f]),u.useEffect(()=>{if(d.trigger){const m=v=>{const g=v.target;g!=null&&g.contains(d.trigger)&&f()};return window.addEventListener("scroll",m,{capture:!0}),()=>window.removeEventListener("scroll",m,{capture:!0})}},[d.trigger,f]),s.jsx(l.DismissableLayer,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:m=>m.preventDefault(),onDismiss:f,children:s.jsxs(l.Content,{"data-state":d.stateAttribute,...p,...c,ref:n,style:{...c.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[s.jsx(SE,{children:r}),s.jsx(NE,{scope:t,isInside:!0,children:s.jsx(l.Root,{id:d.contentId,role:"tooltip",children:o||r})})]})})});Kf.displayName=Rt;var Xf="TooltipArrow",jE=u.forwardRef((e,n)=>{const{__scopeTooltip:t,...r}=e,o=Jn(t);return ME(Xf,t).isInside?null:s.jsx(l.Arrow,{...o,...r,ref:n})});jE.displayName=Xf;function IE(e,n){const t=Math.abs(n.top-e.y),r=Math.abs(n.bottom-e.y),o=Math.abs(n.right-e.x),a=Math.abs(n.left-e.x);switch(Math.min(t,r,o,a)){case a:return"left";case o:return"right";case t:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function AE(e,n,t=5){const r=[];switch(n){case"top":r.push({x:e.x-t,y:e.y+t},{x:e.x+t,y:e.y+t});break;case"bottom":r.push({x:e.x-t,y:e.y-t},{x:e.x+t,y:e.y-t});break;case"left":r.push({x:e.x+t,y:e.y-t},{x:e.x+t,y:e.y+t});break;case"right":r.push({x:e.x-t,y:e.y-t},{x:e.x-t,y:e.y+t});break}return r}function OE(e){const{top:n,right:t,bottom:r,left:o}=e;return[{x:o,y:n},{x:t,y:n},{x:t,y:r},{x:o,y:r}]}function FE(e,n){const{x:t,y:r}=e;let o=!1;for(let a=0,i=n.length-1;a<n.length;i=a++){const c=n[a],d=n[i],p=c.x,f=c.y,m=d.x,v=d.y;f>r!=v>r&&t<(m-p)*(r-f)/(v-f)+p&&(o=!o)}return o}function LE(e){const n=e.slice();return n.sort((t,r)=>t.x<r.x?-1:t.x>r.x?1:t.y<r.y?-1:t.y>r.y?1:0),$E(n)}function $E(e){if(e.length<=1)return e.slice();const n=[];for(let r=0;r<e.length;r++){const o=e[r];for(;n.length>=2;){const a=n[n.length-1],i=n[n.length-2];if((a.x-i.x)*(o.y-i.y)>=(a.y-i.y)*(o.x-i.x))n.pop();else break}n.push(o)}n.pop();const t=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;t.length>=2;){const a=t[t.length-1],i=t[t.length-2];if((a.x-i.x)*(o.y-i.y)>=(a.y-i.y)*(o.x-i.x))t.pop();else break}t.push(o)}return t.pop(),n.length===1&&t.length===1&&n[0].x===t[0].x&&n[0].y===t[0].y?n:n.concat(t)}var HE=Gf,WE=qf,zE=Bf,Qf=Kf;const Ti={primary:"bg-main-600 text-white",secondary:"bg-grey-800 text-white",white:"bg-grey-50 text-grey-800"},YE={sm:"p-2 text-[13px] rounded",md:"p-2 text-sm font-normal rounded"},VE=HE,GE=WE,qE=zE,BE=(e,n)=>{const t=n==="primary"?xt.colors.main[600]:n==="secondary"?xt.colors.grey[800]:xt.colors.grey[50],r=n==="white"?xt.colors.grey[200]:t;return{...{width:"12px",height:"12px",backgroundColor:t,border:"1px solid",borderColor:r,opacity:n==="white"?1:.9,transform:"rotate(45deg)",borderRadius:"2px",zIndex:20},...{"top-left":{left:"1.5rem",top:"100%",transform:"translateX(-50%) translateY(-60%) rotate(45deg)"},"top-center":{left:"50%",top:"100%",transform:"translateX(-50%) translateY(-60%) rotate(45deg)"},"top-right":{right:"1.5rem",top:"100%",transform:"translateX(50%) translateY(-60%) rotate(45deg)"},"bottom-left":{left:"1.5rem",bottom:"100%",transform:"translateX(-50%) translateY(60%) rotate(45deg)"},"bottom-center":{left:"50%",bottom:"100%",transform:"translateX(-50%) translateY(60%) rotate(45deg)"},"bottom-right":{right:"1.5rem",bottom:"100%",transform:"translateX(50%) translateY(60%) rotate(45deg)"},right:{right:"100%",top:"50%",transform:"translateX(60%) translateY(-50%) rotate(45deg)"},left:{left:"100%",top:"50%",transform:"translateX(-60%) translateY(-50%) rotate(45deg)"}}[e]}},Zf=u.forwardRef(({className:e,variant:n="primary",size:t="pc",position:r="top-center",sideOffset:o=8,icLeft:a,icRight:i,children:c,bubbleTip:d=!0,...p},f)=>{const m=BE(r,n),v=r.startsWith("top"),g=r==="right"||r==="left"?r:v?"top":"bottom",h=r==="right"||r==="left"?"center":r.includes("left")?"start":r.includes("right")?"end":"center";return s.jsx(Qf,{ref:f,avoidCollisions:!1,sideOffset:d?o:4,side:g,align:h,style:{zIndex:50},...p,children:s.jsxs("div",{className:l.cn("relative z-50 rounded",d&&"m-1",n==="white"&&"border border-border",Ti[n],e),children:[d&&s.jsx("div",{style:m,className:"absolute z-20"}),s.jsx("div",{className:"absolute inset-0 z-30 rounded bg-white"}),s.jsxs("div",{className:l.cn("relative z-40 flex max-w-sm items-center font-normal",n!=="white"&&"bg-opacity-90",Ti[n],YE[t]),children:[a&&s.jsx("span",{className:"mr-1",children:a}),s.jsx("span",{className:"whitespace-pre-wrap break-keep",children:c}),i&&s.jsx("span",{className:"ml-1",children:i})]})]})})});Zf.displayName=Qf.displayName;exports.Accordion=Tm;exports.AlertDialog=Qm;exports.AlertDialogAction=zs;exports.AlertDialogCancel=Ys;exports.AlertDialogContent=Fs;exports.AlertDialogDescription=Ws;exports.AlertDialogFooter=$s;exports.AlertDialogHeader=Ls;exports.AlertDialogOverlay=Co;exports.AlertDialogPortal=Os;exports.AlertDialogTitle=Hs;exports.AlertDialogTrigger=Zm;exports.ArrowDownIcon=Uw;exports.ArrowUpIcon=Qw;exports.Avatar=ec;exports.AvatarFallback=nc;exports.AvatarImage=tc;exports.Badge=oc;exports.Box=Lt;exports.Button=As;exports.Calendar=Gc;exports.CalendarIcon=Jw;exports.Callout=jt;exports.Card=qc;exports.CardContent=Xc;exports.CardDescription=Uc;exports.CardFooter=Qc;exports.CardHeader=Bc;exports.CardTitle=Kc;exports.CaretSortIcon=t1;exports.Checkbox=ol;exports.ChevronLeftIcon=r1;exports.ChevronRightIcon=Pd;exports.Circle=xc;exports.Command=In;exports.CommandDialog=Ry;exports.CommandEmpty=Jo;exports.CommandGroup=yl;exports.CommandInput=bl;exports.CommandItem=ea;exports.CommandList=Zo;exports.CommandSeparator=wl;exports.CommandShortcut=Cl;exports.Cross2Icon=i1;exports.Dialog=fl;exports.DialogClose=Py;exports.DialogContent=Qo;exports.DialogDescription=xl;exports.DialogFooter=gl;exports.DialogHeader=vl;exports.DialogOverlay=Xo;exports.DialogPortal=ml;exports.DialogTitle=hl;exports.DialogTrigger=_y;exports.DoubleArrowLeftIcon=c1;exports.DoubleArrowRightIcon=d1;exports.DropdownMenu=u1;exports.DropdownMenuCheckboxItem=Nd;exports.DropdownMenuContent=Td;exports.DropdownMenuGroup=f1;exports.DropdownMenuItem=Dd;exports.DropdownMenuLabel=Sd;exports.DropdownMenuPortal=m1;exports.DropdownMenuRadioGroup=g1;exports.DropdownMenuRadioItem=Md;exports.DropdownMenuSeparator=jd;exports.DropdownMenuShortcut=Id;exports.DropdownMenuSub=v1;exports.DropdownMenuSubContent=kd;exports.DropdownMenuSubTrigger=Rd;exports.DropdownMenuTrigger=p1;exports.FileInput=Jd;exports.FileUploader=Xd;exports.FileUploaderContent=Qd;exports.FileUploaderItem=Zd;exports.FlexBox=ua;exports.Form=V0;exports.FormControl=hu;exports.FormDescription=bn;exports.FormField=G0;exports.FormItem=vu;exports.FormLabel=gu;exports.FormMessage=xu;exports.Input=Ad;exports.Label=fa;exports.MonthPicker=K0;exports.MultiSelector=U0;exports.MultiSelectorContent=Cu;exports.MultiSelectorInput=wu;exports.MultiSelectorItem=_u;exports.MultiSelectorList=Eu;exports.MultiSelectorTrigger=yu;exports.NavigationMenu=Uu;exports.NavigationMenuContent=Ju;exports.NavigationMenuIndicator=ep;exports.NavigationMenuItem=fC;exports.NavigationMenuLink=mC;exports.NavigationMenuList=Xu;exports.NavigationMenuTrigger=Zu;exports.NavigationMenuViewport=ya;exports.Popover=TC;exports.PopoverContent=pp;exports.PopoverTrigger=DC;exports.RadioGroup=kp;exports.RadioGroupItem=Tp;exports.ScrollArea=To;exports.ScrollBar=Do;exports.Separator=Mp;exports.Switch=Lp;exports.Tabs=QC;exports.TabsContent=ef;exports.TabsList=Zp;exports.TabsTrigger=Jp;exports.Tag=lu;exports.Text=kt;exports.Textarea=tf;exports.Toast=yf;exports.ToastAction=wf;exports.ToastClose=Cf;exports.ToastDescription=_f;exports.ToastModal=Rf;exports.ToastModalAction=kf;exports.ToastModalClose=Tf;exports.ToastModalContents=bE;exports.ToastModalDescription=Nf;exports.ToastModalProvider=gE;exports.ToastModalTitle=Df;exports.ToastModalViewport=Pf;exports.ToastProvider=vE;exports.ToastTitle=Ef;exports.ToastViewport=xf;exports.Toggle=jf;exports.ToggleGroup=zf;exports.ToggleGroupItem=Yf;exports.Tooltip=GE;exports.TooltipContent=Zf;exports.TooltipProvider=VE;exports.TooltipTrigger=qE;exports.badgeVariants=rc;exports.buttonVariants=Me;exports.commonjsGlobal=ev;exports.constructFrom=ie;exports.differenceInCalendarDays=Ae;exports.format=_e;exports.getDefaultExportFromCjs=Vs;exports.isSameMonth=Nn;exports.ko=Ic;exports.millisecondsInHour=yc;exports.millisecondsInMinute=bc;exports.navigationMenuTriggerStyle=Qu;exports.normalizeDates=Je;exports.tagVariants=cu;exports.toDate=ee;exports.toastPositionVariants=hf;exports.toastVariants=bf;exports.toggleVariants=Ta;exports.useController=au;exports.useFileUpload=$n;exports.useFormContext=Kt;exports.useFormField=Ut;
|
|
85
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qd(e,n){if(e){if(typeof e=="string")return qr(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);if(t==="Object"&&e.constructor&&(t=e.constructor.name),t==="Map"||t==="Set")return Array.from(e);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return qr(e,n)}}function qr(e,n){(n==null||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t<n;t++)r[t]=e[t];return r}function v0(e,n){var t=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(t!=null){var r=[],o=!0,a=!1,i,c;try{for(t=t.call(e);!(o=(i=t.next()).done)&&(r.push(i.value),!(n&&r.length===n));o=!0);}catch(d){a=!0,c=d}finally{try{!o&&t.return!=null&&t.return()}finally{if(a)throw c}}return r}}function g0(e){if(Array.isArray(e))return e}function xi(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),t.push.apply(t,r)}return t}function ue(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?arguments[n]:{};n%2?xi(Object(t),!0).forEach(function(r){Br(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):xi(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function Br(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function xn(e,n){if(e==null)return{};var t=h0(e,n),r,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)r=a[o],!(n.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(t[r]=e[r])}return t}function h0(e,n){if(e==null)return{};var t={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(n.indexOf(o)>=0)&&(t[o]=e[o]);return t}var da=C.forwardRef(function(e,n){var t=e.children,r=xn(e,i0),o=Kd(r),a=o.open,i=xn(o,s0);return C.useImperativeHandle(n,function(){return{open:a}},[a]),C.createElement(C.Fragment,null,t(ue(ue({},i),{},{open:a})))});da.displayName="Dropzone";var Bd={disabled:!1,getFilesFromEvent:D1,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};da.defaultProps=Bd;da.propTypes={children:ce.func,accept:ce.objectOf(ce.arrayOf(ce.string)),multiple:ce.bool,preventDropOnDocument:ce.bool,noClick:ce.bool,noKeyboard:ce.bool,noDrag:ce.bool,noDragEventsBubbling:ce.bool,minSize:ce.number,maxSize:ce.number,maxFiles:ce.number,disabled:ce.bool,getFilesFromEvent:ce.func,onFileDialogCancel:ce.func,onFileDialogOpen:ce.func,useFsAccessApi:ce.bool,autoFocus:ce.bool,onDragEnter:ce.func,onDragLeave:ce.func,onDragOver:ce.func,onDrop:ce.func,onDropAccepted:ce.func,onDropRejected:ce.func,onError:ce.func,validator:ce.func};var Kr={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function Kd(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=ue(ue({},Bd),e),t=n.accept,r=n.disabled,o=n.getFilesFromEvent,a=n.maxSize,i=n.minSize,c=n.multiple,d=n.maxFiles,p=n.onDragEnter,f=n.onDragLeave,m=n.onDragOver,v=n.onDrop,g=n.onDropAccepted,h=n.onDropRejected,b=n.onFileDialogCancel,x=n.onFileDialogOpen,E=n.useFsAccessApi,w=n.autoFocus,P=n.preventDropOnDocument,_=n.noClick,y=n.noKeyboard,T=n.noDrag,$=n.noDragEventsBubbling,V=n.onError,A=n.validator,q=C.useMemo(function(){return r0(t)},[t]),K=C.useMemo(function(){return n0(t)},[t]),te=C.useMemo(function(){return typeof x=="function"?x:bi},[x]),re=C.useMemo(function(){return typeof b=="function"?b:bi},[b]),I=C.useRef(null),Q=C.useRef(null),J=C.useReducer(x0,Kr),j=Dr(J,2),F=j[0],H=j[1],k=F.isFocused,S=F.isFileDialogActive,R=C.useRef(typeof window<"u"&&window.isSecureContext&&E&&t0()),D=function(){!R.current&&S&&setTimeout(function(){if(Q.current){var U=Q.current.files;U.length||(H({type:"closeDialog"}),re())}},300)};C.useEffect(function(){return window.addEventListener("focus",D,!1),function(){window.removeEventListener("focus",D,!1)}},[Q,S,re,R]);var M=C.useRef([]),N=function(U){I.current&&I.current.contains(U.target)||(U.preventDefault(),M.current=[])};C.useEffect(function(){return P&&(document.addEventListener("dragover",hi,!1),document.addEventListener("drop",N,!1)),function(){P&&(document.removeEventListener("dragover",hi),document.removeEventListener("drop",N))}},[I,P]),C.useEffect(function(){return!r&&w&&I.current&&I.current.focus(),function(){}},[I,w,r]);var O=C.useCallback(function(z){V?V(z):console.error(z)},[V]),W=C.useCallback(function(z){z.preventDefault(),z.persist(),Jt(z),M.current=[].concat(d0(M.current),[z.target]),rn(z)&&Promise.resolve(o(z)).then(function(U){if(!(hn(z)&&!$)){var ge=U.length,xe=ge>0&&Q1({files:U,accept:q,minSize:i,maxSize:a,multiple:c,maxFiles:d,validator:A}),ke=ge>0&&!xe;H({isDragAccept:xe,isDragReject:ke,isDragActive:!0,type:"setDraggedFiles"}),p&&p(z)}}).catch(function(U){return O(U)})},[o,p,O,$,q,i,a,c,d,A]),B=C.useCallback(function(z){z.preventDefault(),z.persist(),Jt(z);var U=rn(z);if(U&&z.dataTransfer)try{z.dataTransfer.dropEffect="copy"}catch{}return U&&m&&m(z),!1},[m,$]),G=C.useCallback(function(z){z.preventDefault(),z.persist(),Jt(z);var U=M.current.filter(function(xe){return I.current&&I.current.contains(xe)}),ge=U.indexOf(z.target);ge!==-1&&U.splice(ge,1),M.current=U,!(U.length>0)&&(H({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),rn(z)&&f&&f(z))},[I,f,$]),Z=C.useCallback(function(z,U){var ge=[],xe=[];z.forEach(function(ke){var Dt=zd(ke,q),mt=Dr(Dt,2),nr=mt[0],rr=mt[1],or=Yd(ke,i,a),en=Dr(or,2),ar=en[0],ir=en[1],sr=A?A(ke):null;if(nr&&ar&&!sr)ge.push(ke);else{var cr=[rr,ir];sr&&(cr=cr.concat(sr)),xe.push({file:ke,errors:cr.filter(function(nm){return nm})})}}),(!c&&ge.length>1||c&&d>=1&&ge.length>d)&&(ge.forEach(function(ke){xe.push({file:ke,errors:[X1]})}),ge.splice(0)),H({acceptedFiles:ge,fileRejections:xe,isDragReject:xe.length>0,type:"setFiles"}),v&&v(ge,xe,U),xe.length>0&&h&&h(xe,U),ge.length>0&&g&&g(ge,U)},[H,c,q,i,a,d,v,g,h,A]),he=C.useCallback(function(z){z.preventDefault(),z.persist(),Jt(z),M.current=[],rn(z)&&Promise.resolve(o(z)).then(function(U){hn(z)&&!$||Z(U,z)}).catch(function(U){return O(U)}),H({type:"reset"})},[o,Z,O,$]),L=C.useCallback(function(){if(R.current){H({type:"openDialog"}),te();var z={multiple:c,types:K};window.showOpenFilePicker(z).then(function(U){return o(U)}).then(function(U){Z(U,null),H({type:"closeDialog"})}).catch(function(U){o0(U)?(re(U),H({type:"closeDialog"})):a0(U)?(R.current=!1,Q.current?(Q.current.value=null,Q.current.click()):O(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):O(U)});return}Q.current&&(H({type:"openDialog"}),te(),Q.current.value=null,Q.current.click())},[H,te,re,E,Z,O,K,c]),Re=C.useCallback(function(z){!I.current||!I.current.isEqualNode(z.target)||(z.key===" "||z.key==="Enter"||z.keyCode===32||z.keyCode===13)&&(z.preventDefault(),L())},[I,L]),ot=C.useCallback(function(){H({type:"focus"})},[]),Tt=C.useCallback(function(){H({type:"blur"})},[]),Sa=C.useCallback(function(){_||(e0()?setTimeout(L,0):L())},[_,L]),ft=function(U){return r?null:U},tr=function(U){return y?null:ft(U)},Zt=function(U){return T?null:ft(U)},Jt=function(U){$&&U.stopPropagation()},Jf=C.useMemo(function(){return function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},U=z.refKey,ge=U===void 0?"ref":U,xe=z.role,ke=z.onKeyDown,Dt=z.onFocus,mt=z.onBlur,nr=z.onClick,rr=z.onDragEnter,or=z.onDragOver,en=z.onDragLeave,ar=z.onDrop,ir=xn(z,c0);return ue(ue(Br({onKeyDown:tr($e(ke,Re)),onFocus:tr($e(Dt,ot)),onBlur:tr($e(mt,Tt)),onClick:ft($e(nr,Sa)),onDragEnter:Zt($e(rr,W)),onDragOver:Zt($e(or,B)),onDragLeave:Zt($e(en,G)),onDrop:Zt($e(ar,he)),role:typeof xe=="string"&&xe!==""?xe:"presentation"},ge,I),!r&&!y?{tabIndex:0}:{}),ir)}},[I,Re,ot,Tt,Sa,W,B,G,he,y,T,r]),em=C.useCallback(function(z){z.stopPropagation()},[]),tm=C.useMemo(function(){return function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},U=z.refKey,ge=U===void 0?"ref":U,xe=z.onChange,ke=z.onClick,Dt=xn(z,l0),mt=Br({accept:q,multiple:c,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:ft($e(xe,he)),onClick:ft($e(ke,em)),tabIndex:-1},ge,Q);return ue(ue({},mt),Dt)}},[Q,t,c,he,r]);return ue(ue({},F),{},{isFocused:k&&!r,getRootProps:Jf,getInputProps:tm,rootRef:I,inputRef:Q,open:ft(L)})}function x0(e,n){switch(n.type){case"focus":return ue(ue({},e),{},{isFocused:!0});case"blur":return ue(ue({},e),{},{isFocused:!1});case"openDialog":return ue(ue({},Kr),{},{isFileDialogActive:!0});case"closeDialog":return ue(ue({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return ue(ue({},e),{},{isDragActive:n.isDragActive,isDragAccept:n.isDragAccept,isDragReject:n.isDragReject});case"setFiles":return ue(ue({},e),{},{acceptedFiles:n.acceptedFiles,fileRejections:n.fileRejections,isDragReject:n.isDragReject});case"reset":return ue({},Kr);default:return e}}function bi(){}function b0(e){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],t=document.createElement("style");t.type="text/css",n.appendChild(t),t.styleSheet?t.styleSheet.cssText=e:t.appendChild(document.createTextNode(e))}Array(12).fill(0);let Ur=1;class y0{constructor(){this.subscribe=n=>(this.subscribers.push(n),()=>{const t=this.subscribers.indexOf(n);this.subscribers.splice(t,1)}),this.publish=n=>{this.subscribers.forEach(t=>t(n))},this.addToast=n=>{this.publish(n),this.toasts=[...this.toasts,n]},this.create=n=>{var t;const{message:r,...o}=n,a=typeof(n==null?void 0:n.id)=="number"||((t=n.id)==null?void 0:t.length)>0?n.id:Ur++,i=this.toasts.find(d=>d.id===a),c=n.dismissible===void 0?!0:n.dismissible;return this.dismissedToasts.has(a)&&this.dismissedToasts.delete(a),i?this.toasts=this.toasts.map(d=>d.id===a?(this.publish({...d,...n,id:a,title:r}),{...d,...n,id:a,dismissible:c,title:r}):d):this.addToast({title:r,...o,dismissible:c,id:a}),a},this.dismiss=n=>(n?(this.dismissedToasts.add(n),requestAnimationFrame(()=>this.subscribers.forEach(t=>t({id:n,dismiss:!0})))):this.toasts.forEach(t=>{this.subscribers.forEach(r=>r({id:t.id,dismiss:!0}))}),n),this.message=(n,t)=>this.create({...t,message:n}),this.error=(n,t)=>this.create({...t,message:n,type:"error"}),this.success=(n,t)=>this.create({...t,type:"success",message:n}),this.info=(n,t)=>this.create({...t,type:"info",message:n}),this.warning=(n,t)=>this.create({...t,type:"warning",message:n}),this.loading=(n,t)=>this.create({...t,type:"loading",message:n}),this.promise=(n,t)=>{if(!t)return;let r;t.loading!==void 0&&(r=this.create({...t,promise:n,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));const o=Promise.resolve(n instanceof Function?n():n);let a=r!==void 0,i;const c=o.then(async p=>{if(i=["resolve",p],C.isValidElement(p))a=!1,this.create({id:r,type:"default",message:p});else if(C0(p)&&!p.ok){a=!1;const m=typeof t.error=="function"?await t.error(`HTTP error! status: ${p.status}`):t.error,v=typeof t.description=="function"?await t.description(`HTTP error! status: ${p.status}`):t.description,h=typeof m=="object"&&!C.isValidElement(m)?m:{message:m};this.create({id:r,type:"error",description:v,...h})}else if(p instanceof Error){a=!1;const m=typeof t.error=="function"?await t.error(p):t.error,v=typeof t.description=="function"?await t.description(p):t.description,h=typeof m=="object"&&!C.isValidElement(m)?m:{message:m};this.create({id:r,type:"error",description:v,...h})}else if(t.success!==void 0){a=!1;const m=typeof t.success=="function"?await t.success(p):t.success,v=typeof t.description=="function"?await t.description(p):t.description,h=typeof m=="object"&&!C.isValidElement(m)?m:{message:m};this.create({id:r,type:"success",description:v,...h})}}).catch(async p=>{if(i=["reject",p],t.error!==void 0){a=!1;const f=typeof t.error=="function"?await t.error(p):t.error,m=typeof t.description=="function"?await t.description(p):t.description,g=typeof f=="object"&&!C.isValidElement(f)?f:{message:f};this.create({id:r,type:"error",description:m,...g})}}).finally(()=>{a&&(this.dismiss(r),r=void 0),t.finally==null||t.finally.call(t)}),d=()=>new Promise((p,f)=>c.then(()=>i[0]==="reject"?f(i[1]):p(i[1])).catch(f));return typeof r!="string"&&typeof r!="number"?{unwrap:d}:Object.assign(r,{unwrap:d})},this.custom=(n,t)=>{const r=(t==null?void 0:t.id)||Ur++;return this.create({jsx:n(r),id:r,...t}),r},this.getActiveToasts=()=>this.toasts.filter(n=>!this.dismissedToasts.has(n.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const De=new y0,w0=(e,n)=>{const t=(n==null?void 0:n.id)||Ur++;return De.addToast({title:e,...n,id:t}),t},C0=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",E0=w0,_0=()=>De.toasts,P0=()=>De.getActiveToasts(),Nr=Object.assign(E0,{success:De.success,info:De.info,warning:De.warning,error:De.error,custom:De.custom,message:De.message,promise:De.promise,dismiss:De.dismiss,loading:De.loading},{getHistory:_0,getToasts:P0});b0("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");const Ud=C.createContext(null),$n=()=>{const e=C.useContext(Ud);if(!e)throw new Error("useFileUpload must be used within a FileUploaderProvider");return e},Xd=C.forwardRef(({className:e,dropzoneOptions:n,value:t,onValueChange:r,reSelect:o,orientation:a="vertical",children:i,dir:c,...d},p)=>{const[f,m]=C.useState(!1),[v,g]=C.useState(!1),[h,b]=C.useState(-1),{accept:x={"image/*":[".jpg",".jpeg",".png",".gif"]},maxFiles:E=1,maxSize:w=4*1024*1024,multiple:P=!0}=n,_=E===1?!0:o,y=c==="rtl"?"rtl":"ltr",T=C.useCallback(K=>{if(!t)return;const te=t.filter((re,I)=>I!==K);r(te)},[t,r]),$=C.useCallback(K=>{var J;if(K.preventDefault(),K.stopPropagation(),!t)return;const te=()=>{const j=h+1;b(j>t.length-1?0:j)},re=()=>{const j=h-1;b(j<0?t.length-1:j)},I=a==="horizontal"?y==="ltr"?"ArrowLeft":"ArrowRight":"ArrowUp",Q=a==="horizontal"?y==="ltr"?"ArrowRight":"ArrowLeft":"ArrowDown";if(K.key===Q)te();else if(K.key===I)re();else if(K.key==="Enter"||K.key==="Space")h===-1&&((J=q.inputRef.current)==null||J.click());else if(K.key==="Delete"||K.key==="Backspace"){if(h!==-1){if(T(h),t.length-1===0){b(-1);return}re()}}else K.key==="Escape"&&b(-1)},[t,h,T]),V=C.useCallback((K,te)=>{var Q,J;const re=K;if(!re){Nr.error("file error , probably too big");return}const I=t?[...t]:[];if(_&&I.splice(0,I.length),re.forEach(j=>{I.length<E&&I.push(j)}),r(I),te.length>0)for(let j=0;j<te.length;j++){if(((Q=te[j].errors[0])==null?void 0:Q.code)==="file-too-large"){Nr.error(`File is too large. Max size is ${w/1024/1024}MB`);break}if((J=te[j].errors[0])!=null&&J.message){Nr.error(te[j].errors[0].message);break}}},[_,t]);C.useEffect(()=>{if(t){if(t.length===E){g(!0);return}g(!1)}},[t,E]);const q=Kd({...n||{accept:x,maxFiles:E,maxSize:w,multiple:P},onDrop:V,onDropRejected:()=>m(!0),onDropAccepted:()=>m(!1)});return s.jsx(Ud.Provider,{value:{dropzoneState:q,isLOF:v,isFileTooBig:f,removeFileFromSet:T,activeIndex:h,setActiveIndex:b,orientation:a,direction:y},children:s.jsx("div",{ref:p,tabIndex:0,onKeyDownCapture:$,className:l.cn("grid w-full overflow-hidden focus:outline-none",e,{"gap-2":t&&t.length>0}),dir:c,...d,children:i})})});Xd.displayName="FileUploader";const Qd=C.forwardRef(({children:e,className:n,...t},r)=>{const{orientation:o}=$n(),a=C.useRef(null);return s.jsx("div",{className:l.cn("w-full px-1"),ref:a,"aria-description":"content file holder",children:s.jsx("div",{...t,ref:r,className:l.cn("flex gap-1 rounded-xl",o==="horizontal"?"flex-raw flex-wrap":"flex-col",n),children:e})})});Qd.displayName="FileUploaderContent";const Zd=C.forwardRef(({className:e,index:n,children:t,...r},o)=>{const{removeFileFromSet:a,activeIndex:i,direction:c}=$n(),d=n===i;return s.jsxs("div",{ref:o,className:l.cn(Me({variant:"outline"}),"relative h-6 cursor-pointer justify-between p-1",e,d?"bg-muted":""),...r,children:[s.jsx("div",{className:"flex h-full w-full items-center gap-1.5 font-medium leading-none tracking-tight",children:t}),s.jsxs("button",{type:"button",className:l.cn("absolute",c==="rtl"?"left-1 top-1":"right-1 top-1"),onClick:()=>a(n),children:[s.jsxs("span",{className:"sr-only",children:["remove item ",n]}),s.jsx(Sv,{className:"h-4 w-4 duration-200 ease-in-out hover:stroke-destructive"})]})]})});Zd.displayName="FileUploaderItem";const Jd=C.forwardRef(({className:e,children:n,...t},r)=>{const{dropzoneState:o,isFileTooBig:a,isLOF:i}=$n(),c=i?{}:o.getRootProps();return s.jsxs("div",{ref:r,...t,className:`relative w-full ${i?"cursor-not-allowed opacity-50":"cursor-pointer"}`,children:[s.jsx("div",{className:l.cn(`w-full rounded-lg duration-300 ease-in-out ${o.isDragAccept?"border-green-500":o.isDragReject||a?"border-red-500":"border-gray-300"}`,e),...c,children:n}),s.jsx(Ad,{ref:o.inputRef,disabled:i,...o.getInputProps(),className:`${i?"cursor-not-allowed":""}`})]})});Jd.displayName="FileInput";const ua=({className:e,...n})=>s.jsx(Lt,{className:l.cn("flex",e),...n});ua.Col=({className:e,...n})=>s.jsx(Lt,{className:l.cn("flex flex-col items-start",e),...n});ua.Row=({className:e,...n})=>s.jsx(Lt,{className:l.cn("flex flex-row justify-start",e),...n});var R0=e=>e.type==="checkbox",k0=e=>e instanceof Date,eu=e=>e==null;const T0=e=>typeof e=="object";var Bt=e=>!eu(e)&&!Array.isArray(e)&&T0(e)&&!k0(e),D0=e=>Bt(e)&&e.target?R0(e.target)?e.target.checked:e.target.value:e,N0=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,M0=(e,n)=>e.has(N0(n)),S0=e=>{const n=e.constructor&&e.constructor.prototype;return Bt(n)&&n.hasOwnProperty("isPrototypeOf")},j0=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function tu(e){let n;const t=Array.isArray(e),r=typeof FileList<"u"?e instanceof FileList:!1;if(e instanceof Date)n=new Date(e);else if(!(j0&&(e instanceof Blob||r))&&(t||Bt(e)))if(n=t?[]:{},!t&&!S0(e))n=e;else for(const o in e)e.hasOwnProperty(o)&&(n[o]=tu(e[o]));else return e;return n}var nu=e=>/^\w*$/.test(e),Xr=e=>e===void 0,I0=e=>Array.isArray(e)?e.filter(Boolean):[],ru=e=>I0(e.replace(/["|']|\]/g,"").split(/\.|\[/)),Ee=(e,n,t)=>{if(!n||!Bt(e))return t;const r=(nu(n)?[n]:ru(n)).reduce((o,a)=>eu(o)?o:o[a],e);return Xr(r)||r===e?Xr(e[n])?t:e[n]:r},Mr=e=>typeof e=="boolean",yi=(e,n,t)=>{let r=-1;const o=nu(n)?[n]:ru(n),a=o.length,i=a-1;for(;++r<a;){const c=o[r];let d=t;if(r!==i){const p=e[c];d=Bt(p)||Array.isArray(p)?p:isNaN(+o[r+1])?{}:[]}if(c==="__proto__"||c==="constructor"||c==="prototype")return;e[c]=d,e=e[c]}};const wi={BLUR:"blur",CHANGE:"change"},Ci={all:"all"},pa=C.createContext(null);pa.displayName="HookFormContext";const Kt=()=>C.useContext(pa),A0=e=>{const{children:n,...t}=e;return C.createElement(pa.Provider,{value:t},n)};var O0=(e,n,t,r=!0)=>{const o={defaultValues:n._defaultValues};for(const a in e)Object.defineProperty(o,a,{get:()=>{const i=a;return n._proxyFormState[i]!==Ci.all&&(n._proxyFormState[i]=!r||Ci.all),t&&(t[i]=!0),e[i]}});return o};const ou=typeof window<"u"?u.useLayoutEffect:u.useEffect;function F0(e){const n=Kt(),{control:t=n.control,disabled:r,name:o,exact:a}=e||{},[i,c]=C.useState(t._formState),d=C.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return ou(()=>t._subscribe({name:o,formState:d.current,exact:a,callback:p=>{!r&&c({...t._formState,...p})}}),[o,r,a]),C.useEffect(()=>{d.current.isValid&&t._setValid(!0)},[t]),C.useMemo(()=>O0(i,t,d.current,!1),[i,t])}var L0=e=>typeof e=="string",$0=(e,n,t,r,o)=>L0(e)?Ee(t,e,o):Array.isArray(e)?e.map(a=>Ee(t,a)):t;function H0(e){const n=Kt(),{control:t=n.control,name:r,defaultValue:o,disabled:a,exact:i}=e||{},c=C.useRef(o),[d,p]=C.useState(t._getWatch(r,c.current));return ou(()=>t._subscribe({name:r,formState:{values:!0},exact:i,callback:f=>!a&&p($0(r,t._names,f.values||t._formValues,!1,c.current))}),[r,t,a,i]),C.useEffect(()=>t._removeUnmounted()),d}function au(e){const n=Kt(),{name:t,disabled:r,control:o=n.control,shouldUnregister:a}=e,i=M0(o._names.array,t),c=H0({control:o,name:t,defaultValue:Ee(o._formValues,t,Ee(o._defaultValues,t,e.defaultValue)),exact:!0}),d=F0({control:o,name:t,exact:!0}),p=C.useRef(e),f=C.useRef(o.register(t,{...e.rules,value:c,...Mr(e.disabled)?{disabled:e.disabled}:{}})),m=C.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Ee(d.errors,t)},isDirty:{enumerable:!0,get:()=>!!Ee(d.dirtyFields,t)},isTouched:{enumerable:!0,get:()=>!!Ee(d.touchedFields,t)},isValidating:{enumerable:!0,get:()=>!!Ee(d.validatingFields,t)},error:{enumerable:!0,get:()=>Ee(d.errors,t)}}),[d,t]),v=C.useCallback(x=>f.current.onChange({target:{value:D0(x),name:t},type:wi.CHANGE}),[t]),g=C.useCallback(()=>f.current.onBlur({target:{value:Ee(o._formValues,t),name:t},type:wi.BLUR}),[t,o._formValues]),h=C.useCallback(x=>{const E=Ee(o._fields,t);E&&x&&(E._f.ref={focus:()=>x.focus&&x.focus(),select:()=>x.select&&x.select(),setCustomValidity:w=>x.setCustomValidity(w),reportValidity:()=>x.reportValidity()})},[o._fields,t]),b=C.useMemo(()=>({name:t,value:c,...Mr(r)||d.disabled?{disabled:d.disabled||r}:{},onChange:v,onBlur:g,ref:h}),[t,r,d.disabled,v,g,h,c]);return C.useEffect(()=>{const x=o._options.shouldUnregister||a;o.register(t,{...p.current.rules,...Mr(p.current.disabled)?{disabled:p.current.disabled}:{}});const E=(w,P)=>{const _=Ee(o._fields,w);_&&_._f&&(_._f.mount=P)};if(E(t,!0),x){const w=tu(Ee(o._options.defaultValues,t));yi(o._defaultValues,t,w),Xr(Ee(o._formValues,t))&&yi(o._formValues,t,w)}return!i&&o.register(t),()=>{(i?x&&!o._state.action:x)?o.unregister(t):E(t,!1)}},[t,o,i,a]),C.useEffect(()=>{o._setDisabledField({disabled:r,name:t})},[r,t,o]),C.useMemo(()=>({field:b,formState:d,fieldState:m}),[b,d,m])}const W0=e=>e.render(au(e));var z0="Label",iu=u.forwardRef((e,n)=>s.jsx(l.Primitive.label,{...e,ref:n,onMouseDown:t=>{var o;t.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,t),!t.defaultPrevented&&t.detail>1&&t.preventDefault())}}));iu.displayName=z0;var su=iu;const Y0=Ke("text-sm font-normal peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),fa=u.forwardRef(({className:e,...n},t)=>s.jsx(su,{ref:t,className:l.cn(Y0(),e),...n}));fa.displayName=su.displayName;const cu=Ke("inline-flex items-center justify-center whitespace-nowrap gap-1",{variants:{size:{sm:"px-1 py-0.5 text-[13px] font-normal",md:"px-1 py-1 text-[13px] font-normal",lg:"px-2 py-1 text-sm font-medium"},shape:{square:"rounded",round:"rounded-full"},variant:{ad:"rounded-none rounded-bl-xl text-sm font-normal px-2 py-1 absolute top-0 right-0 bg-grey-800 text-white","solid-primary-50":"bg-main-50 text-main-600","solid-primary-100":"bg-main-100 text-main-600","solid-primary-600":"bg-main-600 text-main-50","solid-secondary-100":"bg-grey-100 text-grey-600","solid-secondary-400":"bg-grey-400 text-white","solid-secondary-800":"bg-grey-800 text-white","solid-red-400":"text-red-600 bg-grey-200/50","solid-red-white":"text-red-400 bg-white","outline-primary-600":"bg-main-100 border border-main-600 text-main-600","outline-secondary-200":"bg-white border border-grey-200 text-grey-800",red_white:"border-transparent text-red-400 bg-white",primary:"border-transparent text-main-800 bg-main-100",secondary:"border-transparent bg-grey-100 text-secondary",outline:"text-foreground",white:"border-transparent text-grey-800 bg-white",black:"border-transparent bg-grey-500 text-grey-100",etc:""}},defaultVariants:{variant:"solid-primary-50",size:"sm",shape:"square"}});function lu({className:e,variant:n,size:t,shape:r,icLeft:o,icRight:a,...i}){return s.jsxs("div",{className:l.cn(cu({size:t,shape:r,variant:n}),e),...i,children:[o&&s.jsx("div",{children:o})," ",s.jsx("div",{children:i.children}),a&&s.jsx("div",{children:a})," "]})}const kt=({children:e,className:n,type:t="text"})=>{switch(t){case"accent":return s.jsx(du,{children:e});case"error":return s.jsx(uu,{children:e});case"mute":return s.jsx(pu,{children:e});default:return s.jsx("span",{className:l.cn("text-grey-800",n),children:e})}},du=({children:e,className:n,color:t="text-main-600",tagSize:r="sm",asTag:o=!1})=>o?s.jsx(lu,{className:l.cn(t,n),size:r,variant:"solid-red-400",children:e}):s.jsx("span",{className:l.cn(t,n),children:e}),uu=({children:e,className:n})=>s.jsx("span",{className:l.cn("text-red-600",n),children:e}),pu=({children:e,className:n})=>s.jsx("span",{className:l.cn("text-muted",n),children:e});kt.Accent=du;kt.Error=uu;kt.Mute=pu;const V0=A0,fu=u.createContext({}),G0=({...e})=>s.jsx(fu.Provider,{value:{name:e.name},children:s.jsx(W0,{...e})}),Ut=()=>{const e=u.useContext(fu),n=u.useContext(mu),{getFieldState:t,formState:r}=Kt(),o=t(e.name,r);if(!e)throw new Error("useFormField should be used within <FormField>");const{id:a}=n;return{id:a,name:e.name,formItemId:`${a}-form-item`,formDescriptionId:`${a}-form-item-description`,formMessageId:`${a}-form-item-message`,...o}},mu=u.createContext({}),vu=u.forwardRef(({className:e,...n},t)=>{const r=u.useId();return s.jsx(mu.Provider,{value:{id:r},children:s.jsx("div",{ref:t,className:l.cn("relative flex flex-col gap-2 md:gap-4",e),...n})})});vu.displayName="FormItem";const gu=u.forwardRef(({className:e,required:n,heading:t,label:r,description:o,children:a,...i},c)=>{const{error:d,formItemId:p}=Ut();return s.jsxs(fa,{ref:c,className:l.cn("relative",d&&"text-red-400","space-y-1 text-sm font-semibold text-grey-800 xs:text-base",e),htmlFor:p,...i,children:[n&&s.jsx("div",{className:"absolute right-full top-0 -mt-1 mr-0.5 text-lg text-red-600",children:"*"}),t&&s.jsx(kt,{className:"font-semibold",children:t}),r&&s.jsx(bn,{className:"text-sm font-normal text-grey-800",children:r}),o&&s.jsx(bn,{className:"whitespace-pre-wrap",children:o}),a]})});gu.displayName="FormLabel";const hu=u.forwardRef(({...e},n)=>{const{error:t,formItemId:r,formDescriptionId:o,formMessageId:a}=Ut();return s.jsx(l.Slot,{ref:n,id:r,"aria-describedby":t?`${o} ${a}`:`${o}`,"aria-invalid":!!t,...e})});hu.displayName="FormControl";const bn=u.forwardRef(({className:e,...n},t)=>{const{formDescriptionId:r}=Ut();return s.jsx("div",{ref:t,id:r,className:l.cn("whitespace-pre-wrap text-xs font-normal text-grey-600 xs:text-sm",e),...n})});bn.displayName="FormDescription";const xu=u.forwardRef(({className:e,children:n,absolute:t,...r},o)=>{var p;const{error:a,formMessageId:i}=Ut(),c=(a==null?void 0:a.message)||((p=a==null?void 0:a.root)==null?void 0:p.message),d=a?c||"":n;return d?s.jsx("div",{ref:o,id:i,className:l.cn("flex h-5 items-center",t&&"absolute top-full mt-2"),...r,children:s.jsx(kt.Error,{className:l.cn("h-5 text-sm",e),children:d})}):null});xu.displayName="FormMessage";function q0(){return we(jc())}const B0=jc();function K0({currentMonth:e=B0,onMonthChange:n,disabled:t}){const[r,o]=u.useState(_e(e,"yyyy")),a=Fh(r,"yyyy",new Date),i=Gv({start:a,end:qv(a)});function c(){const p=Ha(a,{years:-1});o(_e(p,"yyyy"))}function d(){const p=Ha(a,{years:1});o(_e(p,"yyyy"))}return s.jsxs("div",{className:"p-3",children:[s.jsxs("div",{className:"mb-4 flex items-center justify-between",children:[s.jsx("button",{name:"previous-year","aria-label":"Go to previous year",className:l.cn(Me({variant:"outline"}),"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"),type:"button",onClick:c,children:s.jsx(Pv,{className:"h-4 w-4"})}),s.jsx("div",{className:"text-sm font-medium","aria-live":"polite",role:"presentation",id:"month-picker",children:_e(a,"yyyy")}),s.jsx("button",{name:"next-year","aria-label":"Go to next year",className:l.cn(Me({variant:"outline"}),"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"),type:"button",onClick:d,children:s.jsx(kv,{className:"h-4 w-4"})})]}),s.jsx("div",{className:"grid grid-cols-3 gap-2",role:"grid","aria-labelledby":"month-picker",children:i.map(p=>s.jsx("div",{className:"relative text-center",role:"presentation",children:s.jsx("button",{name:"month",className:l.cn("inline-flex h-9 w-16 items-center justify-center rounded-md p-0 text-sm font-normal transition-colors hover:bg-main-100 hover:text-main-600 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-main-400 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",ur(p,e)&&"bg-main-600 text-main-50 hover:bg-main-600 hover:text-main-50 focus:bg-main-600 focus:text-main-50 dark:bg-main-50 dark:text-main-600 dark:hover:bg-main-50 dark:hover:text-main-600 dark:focus:bg-main-50 dark:focus:text-main-600",!ur(p,e)&&ur(p,q0())&&"bg-main-100 text-main-600 dark:bg-main-800 dark:text-main-50"),disabled:t?t(p):void 0,role:"gridcell",type:"button",onClick:()=>n&&n(p),children:s.jsx("time",{dateTime:_e(p,"yyyy-MM"),children:_e(p,"MMM",{locale:Ic})})})},p.toString()))})]})}const bu=C.createContext(null),Hn=()=>{const e=C.useContext(bu);if(!e)throw new Error("useMultiSelect must be used within MultiSelectProvider");return e},U0=({values:e,onValuesChange:n,loop:t=!1,className:r,children:o,dir:a,...i})=>{const[c,d]=C.useState(""),[p,f]=C.useState(!1),[m,v]=C.useState(-1),g=C.useCallback(b=>{e.includes(b)?n(e.filter(x=>x!==b)):n([...e,b])},[e]),h=C.useCallback(b=>{const x=()=>{const w=m+1;v(w>e.length-1?t?0:-1:w)},E=()=>{const w=m-1;v(w<0?e.length-1:w)};if((b.key==="Backspace"||b.key==="Delete")&&e.length>0){if(c.length===0)if(m!==-1&&m<e.length){n(e.filter(P=>P!==e[m]));const w=m-1<0?0:m-1;v(w)}else n(e.filter(w=>w!==e[e.length-1]))}else b.key==="Enter"?f(!0):b.key==="Escape"?m!==-1?v(-1):f(!1):a==="rtl"?b.key==="ArrowRight"?E():b.key==="ArrowLeft"&&(m!==-1||t)&&x():b.key==="ArrowLeft"?E():b.key==="ArrowRight"&&(m!==-1||t)&&x()},[e,c,m,t]);return s.jsx(bu.Provider,{value:{value:e,onValueChange:g,open:p,setOpen:f,inputValue:c,setInputValue:d,activeIndex:m,setActiveIndex:v},children:s.jsx(In,{onKeyDown:h,className:l.cn("flex flex-col space-y-2 overflow-visible bg-transparent",r),dir:a,...i,children:o})})},yu=C.forwardRef(({className:e,children:n,labels:t,...r},o)=>{const{value:a,onValueChange:i,activeIndex:c}=Hn(),d=C.useCallback(p=>{p.preventDefault(),p.stopPropagation()},[]);return s.jsxs("div",{ref:o,className:l.cn("flex flex-wrap gap-1 rounded-lg border border-grey-200 bg-background p-1 py-2",e),...r,children:[a.map((p,f)=>{const m=t&&t[p]?t[p].label||t[p].text:p;return s.jsxs(oc,{className:l.cn("flex items-center gap-1 rounded-md px-2 py-1",c===f&&"ring-2 ring-muted-foreground"),variant:"secondary",children:[s.jsx("span",{className:"text-sm",children:m}),s.jsxs("button",{"aria-label":`Remove ${p} option`,"aria-roledescription":"button to remove option",type:"button",onMouseDown:d,onClick:()=>i(p),children:[s.jsxs("span",{className:"sr-only",children:["Remove ",p," option"]}),s.jsx(Iv,{className:"h-4 w-4 hover:stroke-destructive"})]})]},p)}),n]})});yu.displayName="MultiSelectorTrigger";const wu=C.forwardRef(({className:e,...n},t)=>{const{setOpen:r,inputValue:o,setInputValue:a,activeIndex:i,setActiveIndex:c}=Hn();return s.jsx(Ce.Input,{...n,ref:t,value:o,onValueChange:i===-1?a:void 0,onBlur:()=>r(!1),onFocus:()=>r(!0),onClick:()=>c(-1),className:l.cn("ml-2 flex-1 bg-transparent outline-none placeholder:text-muted-foreground",e,i!==-1&&"caret-transparent")})});wu.displayName="MultiSelectorInput";const Cu=C.forwardRef(({children:e},n)=>{const{open:t}=Hn();return s.jsx("div",{ref:n,className:"relative",children:t&&e})});Cu.displayName="MultiSelectorContent";const Eu=C.forwardRef(({className:e,children:n},t)=>s.jsxs(Zo,{ref:t,className:l.cn("scrollbar-thin scrollbar-track-transparent scrollbar-thumb-muted-foreground dark:scrollbar-thumb-muted scrollbar-thumb-rounded-lg absolute top-0 z-10 flex w-full flex-col gap-2 rounded-md border border-grey-200 bg-background p-2 shadow-md transition-colors",e),children:[n,s.jsx(Jo,{children:s.jsx("span",{className:"text-muted",children:"No results found"})})]}));Eu.displayName="MultiSelectorList";const _u=C.forwardRef(({className:e,value:n,children:t,...r},o)=>{const{value:a,onValueChange:i,setInputValue:c}=Hn(),d=C.useCallback(f=>{f.preventDefault(),f.stopPropagation()},[]),p=a.includes(n);return s.jsxs(ea,{ref:o,...r,onSelect:()=>{i(n),c("")},className:l.cn("flex cursor-pointer justify-between rounded-md px-2 py-1 transition-colors",e,p&&"cursor-default opacity-50",r.disabled&&"cursor-not-allowed opacity-50"),onMouseDown:d,children:[t,p&&s.jsx(l.Check,{className:"h-4 w-4"})]})});_u.displayName="MultiSelectorItem";var pt="NavigationMenu",[ma,Pu,X0]=l.createCollection(pt),[Qr,Q0,Z0]=l.createCollection(pt),[va,t_]=l.createContextScope(pt,[X0,Z0]),[J0,Ie]=va(pt),[eC,tC]=va(pt),Ru=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,value:r,onValueChange:o,defaultValue:a,delayDuration:i=200,skipDelayDuration:c=300,orientation:d="horizontal",dir:p,...f}=e,[m,v]=u.useState(null),g=l.useComposedRefs(n,A=>v(A)),h=l.useDirection(p),b=u.useRef(0),x=u.useRef(0),E=u.useRef(0),[w,P]=u.useState(!0),[_,y]=l.useControllableState({prop:r,onChange:A=>{const q=A!=="",K=c>0;q?(window.clearTimeout(E.current),K&&P(!1)):(window.clearTimeout(E.current),E.current=window.setTimeout(()=>P(!0),c)),o==null||o(A)},defaultProp:a??"",caller:pt}),T=u.useCallback(()=>{window.clearTimeout(x.current),x.current=window.setTimeout(()=>y(""),150)},[y]),$=u.useCallback(A=>{window.clearTimeout(x.current),y(A)},[y]),V=u.useCallback(A=>{_===A?window.clearTimeout(x.current):b.current=window.setTimeout(()=>{window.clearTimeout(x.current),y(A)},i)},[_,y,i]);return u.useEffect(()=>()=>{window.clearTimeout(b.current),window.clearTimeout(x.current),window.clearTimeout(E.current)},[]),s.jsx(ku,{scope:t,isRootMenu:!0,value:_,dir:h,orientation:d,rootNavigationMenu:m,onTriggerEnter:A=>{window.clearTimeout(b.current),w?V(A):$(A)},onTriggerLeave:()=>{window.clearTimeout(b.current),T()},onContentEnter:()=>window.clearTimeout(x.current),onContentLeave:T,onItemSelect:A=>{y(q=>q===A?"":A)},onItemDismiss:()=>y(""),children:s.jsx(l.Primitive.nav,{"aria-label":"Main","data-orientation":d,dir:h,...f,ref:g})})});Ru.displayName=pt;var Zr="NavigationMenuSub",nC=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,value:r,onValueChange:o,defaultValue:a,orientation:i="horizontal",...c}=e,d=Ie(Zr,t),[p,f]=l.useControllableState({prop:r,onChange:o,defaultProp:a??"",caller:Zr});return s.jsx(ku,{scope:t,isRootMenu:!1,value:p,dir:d.dir,orientation:i,rootNavigationMenu:d.rootNavigationMenu,onTriggerEnter:m=>f(m),onItemSelect:m=>f(m),onItemDismiss:()=>f(""),children:s.jsx(l.Primitive.div,{"data-orientation":i,...c,ref:n})})});nC.displayName=Zr;var ku=e=>{const{scope:n,isRootMenu:t,rootNavigationMenu:r,dir:o,orientation:a,children:i,value:c,onItemSelect:d,onItemDismiss:p,onTriggerEnter:f,onTriggerLeave:m,onContentEnter:v,onContentLeave:g}=e,[h,b]=u.useState(null),[x,E]=u.useState(new Map),[w,P]=u.useState(null);return s.jsx(J0,{scope:n,isRootMenu:t,rootNavigationMenu:r,value:c,previousValue:l.usePrevious(c),baseId:l.useId(),dir:o,orientation:a,viewport:h,onViewportChange:b,indicatorTrack:w,onIndicatorTrackChange:P,onTriggerEnter:l.useCallbackRef(f),onTriggerLeave:l.useCallbackRef(m),onContentEnter:l.useCallbackRef(v),onContentLeave:l.useCallbackRef(g),onItemSelect:l.useCallbackRef(d),onItemDismiss:l.useCallbackRef(p),onViewportContentChange:u.useCallback((_,y)=>{E(T=>(T.set(_,y),new Map(T)))},[]),onViewportContentRemove:u.useCallback(_=>{E(y=>y.has(_)?(y.delete(_),new Map(y)):y)},[]),children:s.jsx(ma.Provider,{scope:n,children:s.jsx(eC,{scope:n,items:x,children:i})})})},Tu="NavigationMenuList",Du=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,...r}=e,o=Ie(Tu,t),a=s.jsx(l.Primitive.ul,{"data-orientation":o.orientation,...r,ref:n});return s.jsx(l.Primitive.div,{style:{position:"relative"},ref:o.onIndicatorTrackChange,children:s.jsx(ma.Slot,{scope:t,children:o.isRootMenu?s.jsx($u,{asChild:!0,children:a}):a})})});Du.displayName=Tu;var Nu="NavigationMenuItem",[rC,Mu]=va(Nu),Su=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,value:r,...o}=e,a=l.useId(),i=r||a||"LEGACY_REACT_AUTO_VALUE",c=u.useRef(null),d=u.useRef(null),p=u.useRef(null),f=u.useRef(()=>{}),m=u.useRef(!1),v=u.useCallback((h="start")=>{if(c.current){f.current();const b=eo(c.current);b.length&&xa(h==="start"?b:b.reverse())}},[]),g=u.useCallback(()=>{if(c.current){const h=eo(c.current);h.length&&(f.current=dC(h))}},[]);return s.jsx(rC,{scope:t,value:i,triggerRef:d,contentRef:c,focusProxyRef:p,wasEscapeCloseRef:m,onEntryKeyDown:v,onFocusProxyEnter:v,onRootContentClose:g,onContentFocusOutside:g,children:s.jsx(l.Primitive.li,{...o,ref:n})})});Su.displayName=Nu;var Jr="NavigationMenuTrigger",ju=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,disabled:r,...o}=e,a=Ie(Jr,e.__scopeNavigationMenu),i=Mu(Jr,e.__scopeNavigationMenu),c=u.useRef(null),d=l.useComposedRefs(c,i.triggerRef,n),p=Wu(a.baseId,i.value),f=zu(a.baseId,i.value),m=u.useRef(!1),v=u.useRef(!1),g=i.value===a.value;return s.jsxs(s.Fragment,{children:[s.jsx(ma.ItemSlot,{scope:t,value:i.value,children:s.jsx(Hu,{asChild:!0,children:s.jsx(l.Primitive.button,{id:p,disabled:r,"data-disabled":r?"":void 0,"data-state":ba(g),"aria-expanded":g,"aria-controls":f,...o,ref:d,onPointerEnter:l.composeEventHandlers(e.onPointerEnter,()=>{v.current=!1,i.wasEscapeCloseRef.current=!1}),onPointerMove:l.composeEventHandlers(e.onPointerMove,yn(()=>{r||v.current||i.wasEscapeCloseRef.current||m.current||(a.onTriggerEnter(i.value),m.current=!0)})),onPointerLeave:l.composeEventHandlers(e.onPointerLeave,yn(()=>{r||(a.onTriggerLeave(),m.current=!1)})),onClick:l.composeEventHandlers(e.onClick,()=>{a.onItemSelect(i.value),v.current=g}),onKeyDown:l.composeEventHandlers(e.onKeyDown,h=>{const x={horizontal:"ArrowDown",vertical:a.dir==="rtl"?"ArrowLeft":"ArrowRight"}[a.orientation];g&&h.key===x&&(i.onEntryKeyDown(),h.preventDefault())})})})}),g&&s.jsxs(s.Fragment,{children:[s.jsx(l.Root,{"aria-hidden":!0,tabIndex:0,ref:i.focusProxyRef,onFocus:h=>{const b=i.contentRef.current,x=h.relatedTarget,E=x===c.current,w=b==null?void 0:b.contains(x);(E||!w)&&i.onFocusProxyEnter(E?"start":"end")}}),a.viewport&&s.jsx("span",{"aria-owns":f})]})]})});ju.displayName=Jr;var oC="NavigationMenuLink",Ei="navigationMenu.linkSelect",Iu=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,active:r,onSelect:o,...a}=e;return s.jsx(Hu,{asChild:!0,children:s.jsx(l.Primitive.a,{"data-active":r?"":void 0,"aria-current":r?"page":void 0,...a,ref:n,onClick:l.composeEventHandlers(e.onClick,i=>{const c=i.target,d=new CustomEvent(Ei,{bubbles:!0,cancelable:!0});if(c.addEventListener(Ei,p=>o==null?void 0:o(p),{once:!0}),l.dispatchDiscreteCustomEvent(c,d),!d.defaultPrevented&&!i.metaKey){const p=new CustomEvent(sn,{bubbles:!0,cancelable:!0});l.dispatchDiscreteCustomEvent(c,p)}},{checkForDefaultPrevented:!1})})})});Iu.displayName=oC;var ga="NavigationMenuIndicator",Au=u.forwardRef((e,n)=>{const{forceMount:t,...r}=e,o=Ie(ga,e.__scopeNavigationMenu),a=!!o.value;return o.indicatorTrack?Di.createPortal(s.jsx(de,{present:t||a,children:s.jsx(aC,{...r,ref:n})}),o.indicatorTrack):null});Au.displayName=ga;var aC=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,...r}=e,o=Ie(ga,t),a=Pu(t),[i,c]=u.useState(null),[d,p]=u.useState(null),f=o.orientation==="horizontal",m=!!o.value;u.useEffect(()=>{var b;const h=(b=a().find(x=>x.value===o.value))==null?void 0:b.ref.current;h&&c(h)},[a,o.value]);const v=()=>{i&&p({size:f?i.offsetWidth:i.offsetHeight,offset:f?i.offsetLeft:i.offsetTop})};return to(i,v),to(o.indicatorTrack,v),d?s.jsx(l.Primitive.div,{"aria-hidden":!0,"data-state":m?"visible":"hidden","data-orientation":o.orientation,...r,ref:n,style:{position:"absolute",...f?{left:0,width:d.size+"px",transform:`translateX(${d.offset}px)`}:{top:0,height:d.size+"px",transform:`translateY(${d.offset}px)`},...r.style}}):null}),_t="NavigationMenuContent",Ou=u.forwardRef((e,n)=>{const{forceMount:t,...r}=e,o=Ie(_t,e.__scopeNavigationMenu),a=Mu(_t,e.__scopeNavigationMenu),i=l.useComposedRefs(a.contentRef,n),c=a.value===o.value,d={value:a.value,triggerRef:a.triggerRef,focusProxyRef:a.focusProxyRef,wasEscapeCloseRef:a.wasEscapeCloseRef,onContentFocusOutside:a.onContentFocusOutside,onRootContentClose:a.onRootContentClose,...r};return o.viewport?s.jsx(iC,{forceMount:t,...d,ref:i}):s.jsx(de,{present:t||c,children:s.jsx(Fu,{"data-state":ba(c),...d,ref:i,onPointerEnter:l.composeEventHandlers(e.onPointerEnter,o.onContentEnter),onPointerLeave:l.composeEventHandlers(e.onPointerLeave,yn(o.onContentLeave)),style:{pointerEvents:!c&&o.isRootMenu?"none":void 0,...d.style}})})});Ou.displayName=_t;var iC=u.forwardRef((e,n)=>{const t=Ie(_t,e.__scopeNavigationMenu),{onViewportContentChange:r,onViewportContentRemove:o}=t;return l.useLayoutEffect2(()=>{r(e.value,{ref:n,...e})},[e,n,r]),l.useLayoutEffect2(()=>()=>o(e.value),[e.value,o]),null}),sn="navigationMenu.rootContentDismiss",Fu=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,value:r,triggerRef:o,focusProxyRef:a,wasEscapeCloseRef:i,onRootContentClose:c,onContentFocusOutside:d,...p}=e,f=Ie(_t,t),m=u.useRef(null),v=l.useComposedRefs(m,n),g=Wu(f.baseId,r),h=zu(f.baseId,r),b=Pu(t),x=u.useRef(null),{onItemDismiss:E}=f;u.useEffect(()=>{const P=m.current;if(f.isRootMenu&&P){const _=()=>{var y;E(),c(),P.contains(document.activeElement)&&((y=o.current)==null||y.focus())};return P.addEventListener(sn,_),()=>P.removeEventListener(sn,_)}},[f.isRootMenu,e.value,o,E,c]);const w=u.useMemo(()=>{const _=b().map(q=>q.value);f.dir==="rtl"&&_.reverse();const y=_.indexOf(f.value),T=_.indexOf(f.previousValue),$=r===f.value,V=T===_.indexOf(r);if(!$&&!V)return x.current;const A=(()=>{if(y!==T){if($&&T!==-1)return y>T?"from-end":"from-start";if(V&&y!==-1)return y>T?"to-start":"to-end"}return null})();return x.current=A,A},[f.previousValue,f.value,f.dir,b,r]);return s.jsx($u,{asChild:!0,children:s.jsx(l.DismissableLayer,{id:h,"aria-labelledby":g,"data-motion":w,"data-orientation":f.orientation,...p,ref:v,disableOutsidePointerEvents:!1,onDismiss:()=>{var _;const P=new Event(sn,{bubbles:!0,cancelable:!0});(_=m.current)==null||_.dispatchEvent(P)},onFocusOutside:l.composeEventHandlers(e.onFocusOutside,P=>{var y;d();const _=P.target;(y=f.rootNavigationMenu)!=null&&y.contains(_)&&P.preventDefault()}),onPointerDownOutside:l.composeEventHandlers(e.onPointerDownOutside,P=>{var $;const _=P.target,y=b().some(V=>{var A;return(A=V.ref.current)==null?void 0:A.contains(_)}),T=f.isRootMenu&&(($=f.viewport)==null?void 0:$.contains(_));(y||T||!f.isRootMenu)&&P.preventDefault()}),onKeyDown:l.composeEventHandlers(e.onKeyDown,P=>{var T;const _=P.altKey||P.ctrlKey||P.metaKey;if(P.key==="Tab"&&!_){const $=eo(P.currentTarget),V=document.activeElement,A=$.findIndex(te=>te===V),K=P.shiftKey?$.slice(0,A).reverse():$.slice(A+1,$.length);xa(K)?P.preventDefault():(T=a.current)==null||T.focus()}}),onEscapeKeyDown:l.composeEventHandlers(e.onEscapeKeyDown,P=>{i.current=!0})})})}),ha="NavigationMenuViewport",Lu=u.forwardRef((e,n)=>{const{forceMount:t,...r}=e,a=!!Ie(ha,e.__scopeNavigationMenu).value;return s.jsx(de,{present:t||a,children:s.jsx(sC,{...r,ref:n})})});Lu.displayName=ha;var sC=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,children:r,...o}=e,a=Ie(ha,t),i=l.useComposedRefs(n,a.onViewportChange),c=tC(_t,e.__scopeNavigationMenu),[d,p]=u.useState(null),[f,m]=u.useState(null),v=d?(d==null?void 0:d.width)+"px":void 0,g=d?(d==null?void 0:d.height)+"px":void 0,h=!!a.value,b=h?a.value:a.previousValue;return to(f,()=>{f&&p({width:f.offsetWidth,height:f.offsetHeight})}),s.jsx(l.Primitive.div,{"data-state":ba(h),"data-orientation":a.orientation,...o,ref:i,style:{pointerEvents:!h&&a.isRootMenu?"none":void 0,"--radix-navigation-menu-viewport-width":v,"--radix-navigation-menu-viewport-height":g,...o.style},onPointerEnter:l.composeEventHandlers(e.onPointerEnter,a.onContentEnter),onPointerLeave:l.composeEventHandlers(e.onPointerLeave,yn(a.onContentLeave)),children:Array.from(c.items).map(([E,{ref:w,forceMount:P,..._}])=>{const y=b===E;return s.jsx(de,{present:P||y,children:s.jsx(Fu,{..._,ref:l.composeRefs(w,T=>{y&&T&&m(T)})})},E)})})}),cC="FocusGroup",$u=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,...r}=e,o=Ie(cC,t);return s.jsx(Qr.Provider,{scope:t,children:s.jsx(Qr.Slot,{scope:t,children:s.jsx(l.Primitive.div,{dir:o.dir,...r,ref:n})})})}),_i=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"],lC="FocusGroupItem",Hu=u.forwardRef((e,n)=>{const{__scopeNavigationMenu:t,...r}=e,o=Q0(t),a=Ie(lC,t);return s.jsx(Qr.ItemSlot,{scope:t,children:s.jsx(l.Primitive.button,{...r,ref:n,onKeyDown:l.composeEventHandlers(e.onKeyDown,i=>{if(["Home","End",..._i].includes(i.key)){let d=o().map(m=>m.ref.current);if([a.dir==="rtl"?"ArrowRight":"ArrowLeft","ArrowUp","End"].includes(i.key)&&d.reverse(),_i.includes(i.key)){const m=d.indexOf(i.currentTarget);d=d.slice(m+1)}setTimeout(()=>xa(d)),i.preventDefault()}})})})});function eo(e){const n=[],t=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;t.nextNode();)n.push(t.currentNode);return n}function xa(e){const n=document.activeElement;return e.some(t=>t===n?!0:(t.focus(),document.activeElement!==n))}function dC(e){return e.forEach(n=>{n.dataset.tabindex=n.getAttribute("tabindex")||"",n.setAttribute("tabindex","-1")}),()=>{e.forEach(n=>{const t=n.dataset.tabindex;n.setAttribute("tabindex",t)})}}function to(e,n){const t=l.useCallbackRef(n);l.useLayoutEffect2(()=>{let r=0;if(e){const o=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(t)});return o.observe(e),()=>{window.cancelAnimationFrame(r),o.unobserve(e)}}},[e,t])}function ba(e){return e?"open":"closed"}function Wu(e,n){return`${e}-trigger-${n}`}function zu(e,n){return`${e}-content-${n}`}function yn(e){return n=>n.pointerType==="mouse"?e(n):void 0}var Yu=Ru,Vu=Du,uC=Su,Gu=ju,pC=Iu,qu=Au,Bu=Ou,Ku=Lu;const Uu=u.forwardRef(({className:e,children:n,...t},r)=>s.jsxs(Yu,{ref:r,className:l.cn("relative z-10 flex max-w-max flex-1 items-center justify-center",e),...t,children:[n,s.jsx(ya,{})]}));Uu.displayName=Yu.displayName;const Xu=u.forwardRef(({className:e,...n},t)=>s.jsx(Vu,{ref:t,className:l.cn("group flex flex-1 list-none items-center justify-center space-x-1",e),...n}));Xu.displayName=Vu.displayName;const fC=uC,Qu=Ke("group inline-flex h-12 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent/50 data-[state=open]:bg-accent/50"),Zu=u.forwardRef(({className:e,children:n,...t},r)=>s.jsxs(Gu,{ref:r,className:l.cn(Qu(),"group",e),...t,children:[n," ",s.jsx(Ev,{className:"relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180","aria-hidden":"true"})]}));Zu.displayName=Gu.displayName;const Ju=u.forwardRef(({className:e,...n},t)=>s.jsx(Bu,{ref:t,className:l.cn("data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full md:absolute md:w-auto",e),...n}));Ju.displayName=Bu.displayName;const mC=pC,ya=u.forwardRef(({className:e,...n},t)=>s.jsx("div",{className:l.cn("absolute left-0 top-full flex justify-center"),children:s.jsx(Ku,{className:l.cn("origin-top-center data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 relative mt-1 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-lg md:w-[var(--radix-navigation-menu-viewport-width)]",e),ref:t,...n})}));ya.displayName=Ku.displayName;const ep=u.forwardRef(({className:e,...n},t)=>s.jsx(qu,{ref:t,className:l.cn("data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden",e),...n,children:s.jsx("div",{className:"relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md"})}));ep.displayName=qu.displayName;var Wn="Popover",[tp,n_]=l.createContextScope(Wn,[l.createPopperScope]),Xt=l.createPopperScope(),[vC,nt]=tp(Wn),np=e=>{const{__scopePopover:n,children:t,open:r,defaultOpen:o,onOpenChange:a,modal:i=!1}=e,c=Xt(n),d=u.useRef(null),[p,f]=u.useState(!1),[m,v]=l.useControllableState({prop:r,defaultProp:o??!1,onChange:a,caller:Wn});return s.jsx(l.Root2,{...c,children:s.jsx(vC,{scope:n,contentId:l.useId(),triggerRef:d,open:m,onOpenChange:v,onOpenToggle:u.useCallback(()=>v(g=>!g),[v]),hasCustomAnchor:p,onCustomAnchorAdd:u.useCallback(()=>f(!0),[]),onCustomAnchorRemove:u.useCallback(()=>f(!1),[]),modal:i,children:t})})};np.displayName=Wn;var rp="PopoverAnchor",gC=u.forwardRef((e,n)=>{const{__scopePopover:t,...r}=e,o=nt(rp,t),a=Xt(t),{onCustomAnchorAdd:i,onCustomAnchorRemove:c}=o;return u.useEffect(()=>(i(),()=>c()),[i,c]),s.jsx(l.Anchor,{...a,...r,ref:n})});gC.displayName=rp;var op="PopoverTrigger",ap=u.forwardRef((e,n)=>{const{__scopePopover:t,...r}=e,o=nt(op,t),a=Xt(t),i=l.useComposedRefs(n,o.triggerRef),c=s.jsx(l.Primitive.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":dp(o.open),...r,ref:i,onClick:l.composeEventHandlers(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?c:s.jsx(l.Anchor,{asChild:!0,...a,children:c})});ap.displayName=op;var wa="PopoverPortal",[hC,xC]=tp(wa,{forceMount:void 0}),ip=e=>{const{__scopePopover:n,forceMount:t,children:r,container:o}=e,a=nt(wa,n);return s.jsx(hC,{scope:n,forceMount:t,children:s.jsx(de,{present:t||a.open,children:s.jsx(l.Portal,{asChild:!0,container:o,children:r})})})};ip.displayName=wa;var Pt="PopoverContent",sp=u.forwardRef((e,n)=>{const t=xC(Pt,e.__scopePopover),{forceMount:r=t.forceMount,...o}=e,a=nt(Pt,e.__scopePopover);return s.jsx(de,{present:r||a.open,children:a.modal?s.jsx(yC,{...o,ref:n}):s.jsx(wC,{...o,ref:n})})});sp.displayName=Pt;var bC=l.createSlot("PopoverContent.RemoveScroll"),yC=u.forwardRef((e,n)=>{const t=nt(Pt,e.__scopePopover),r=u.useRef(null),o=l.useComposedRefs(n,r),a=u.useRef(!1);return u.useEffect(()=>{const i=r.current;if(i)return l.hideOthers(i)},[]),s.jsx(l.ReactRemoveScroll,{as:bC,allowPinchZoom:!0,children:s.jsx(cp,{...e,ref:o,trapFocus:t.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:l.composeEventHandlers(e.onCloseAutoFocus,i=>{var c;i.preventDefault(),a.current||(c=t.triggerRef.current)==null||c.focus()}),onPointerDownOutside:l.composeEventHandlers(e.onPointerDownOutside,i=>{const c=i.detail.originalEvent,d=c.button===0&&c.ctrlKey===!0,p=c.button===2||d;a.current=p},{checkForDefaultPrevented:!1}),onFocusOutside:l.composeEventHandlers(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),wC=u.forwardRef((e,n)=>{const t=nt(Pt,e.__scopePopover),r=u.useRef(!1),o=u.useRef(!1);return s.jsx(cp,{...e,ref:n,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var i,c;(i=e.onCloseAutoFocus)==null||i.call(e,a),a.defaultPrevented||(r.current||(c=t.triggerRef.current)==null||c.focus(),a.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:a=>{var d,p;(d=e.onInteractOutside)==null||d.call(e,a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=a.target;((p=t.triggerRef.current)==null?void 0:p.contains(i))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),cp=u.forwardRef((e,n)=>{const{__scopePopover:t,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,disableOutsidePointerEvents:i,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:p,onInteractOutside:f,...m}=e,v=nt(Pt,t),g=Xt(t);return l.useFocusGuards(),s.jsx(l.FocusScope,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:s.jsx(l.DismissableLayer,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:f,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:p,onDismiss:()=>v.onOpenChange(!1),children:s.jsx(l.Content,{"data-state":dp(v.open),role:"dialog",id:v.contentId,...g,...m,ref:n,style:{...m.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),lp="PopoverClose",CC=u.forwardRef((e,n)=>{const{__scopePopover:t,...r}=e,o=nt(lp,t);return s.jsx(l.Primitive.button,{type:"button",...r,ref:n,onClick:l.composeEventHandlers(e.onClick,()=>o.onOpenChange(!1))})});CC.displayName=lp;var EC="PopoverArrow",_C=u.forwardRef((e,n)=>{const{__scopePopover:t,...r}=e,o=Xt(t);return s.jsx(l.Arrow,{...o,...r,ref:n})});_C.displayName=EC;function dp(e){return e?"open":"closed"}var PC=np,RC=ap,kC=ip,up=sp;const TC=PC,DC=RC,pp=u.forwardRef(({className:e,align:n="center",sideOffset:t=4,...r},o)=>s.jsx(kC,{children:s.jsx(up,{ref:o,align:n,sideOffset:t,className:l.cn("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 w-80 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none",e),...r})}));pp.displayName=up.displayName;var Ca="Radio",[NC,fp]=l.createContextScope(Ca),[MC,SC]=NC(Ca),mp=u.forwardRef((e,n)=>{const{__scopeRadio:t,name:r,checked:o=!1,required:a,disabled:i,value:c="on",onCheck:d,form:p,...f}=e,[m,v]=u.useState(null),g=l.useComposedRefs(n,x=>v(x)),h=u.useRef(!1),b=m?p||!!m.closest("form"):!0;return s.jsxs(MC,{scope:t,checked:o,disabled:i,children:[s.jsx(l.Primitive.button,{type:"button",role:"radio","aria-checked":o,"data-state":xp(o),"data-disabled":i?"":void 0,disabled:i,value:c,...f,ref:g,onClick:l.composeEventHandlers(e.onClick,x=>{o||d==null||d(),b&&(h.current=x.isPropagationStopped(),h.current||x.stopPropagation())})}),b&&s.jsx(hp,{control:m,bubbles:!h.current,name:r,value:c,checked:o,required:a,disabled:i,form:p,style:{transform:"translateX(-100%)"}})]})});mp.displayName=Ca;var vp="RadioIndicator",gp=u.forwardRef((e,n)=>{const{__scopeRadio:t,forceMount:r,...o}=e,a=SC(vp,t);return s.jsx(de,{present:r||a.checked,children:s.jsx(l.Primitive.span,{"data-state":xp(a.checked),"data-disabled":a.disabled?"":void 0,...o,ref:n})})});gp.displayName=vp;var jC="RadioBubbleInput",hp=u.forwardRef(({__scopeRadio:e,control:n,checked:t,bubbles:r=!0,...o},a)=>{const i=u.useRef(null),c=l.useComposedRefs(i,a),d=l.usePrevious(t),p=l.useSize(n);return u.useEffect(()=>{const f=i.current;if(!f)return;const m=window.HTMLInputElement.prototype,g=Object.getOwnPropertyDescriptor(m,"checked").set;if(d!==t&&g){const h=new Event("click",{bubbles:r});g.call(f,t),f.dispatchEvent(h)}},[d,t,r]),s.jsx(l.Primitive.input,{type:"radio","aria-hidden":!0,defaultChecked:t,...o,tabIndex:-1,ref:c,style:{...o.style,...p,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});hp.displayName=jC;function xp(e){return e?"checked":"unchecked"}var IC=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],zn="RadioGroup",[AC,r_]=l.createContextScope(zn,[et,fp]),bp=et(),yp=fp(),[OC,FC]=AC(zn),wp=u.forwardRef((e,n)=>{const{__scopeRadioGroup:t,name:r,defaultValue:o,value:a,required:i=!1,disabled:c=!1,orientation:d,dir:p,loop:f=!0,onValueChange:m,...v}=e,g=bp(t),h=l.useDirection(p),[b,x]=l.useControllableState({prop:a,defaultProp:o??null,onChange:m,caller:zn});return s.jsx(OC,{scope:t,name:r,required:i,disabled:c,value:b,onValueChange:x,children:s.jsx(An,{asChild:!0,...g,orientation:d,dir:h,loop:f,children:s.jsx(l.Primitive.div,{role:"radiogroup","aria-required":i,"aria-orientation":d,"data-disabled":c?"":void 0,dir:h,...v,ref:n})})})});wp.displayName=zn;var Cp="RadioGroupItem",Ep=u.forwardRef((e,n)=>{const{__scopeRadioGroup:t,disabled:r,...o}=e,a=FC(Cp,t),i=a.disabled||r,c=bp(t),d=yp(t),p=u.useRef(null),f=l.useComposedRefs(n,p),m=a.value===o.value,v=u.useRef(!1);return u.useEffect(()=>{const g=b=>{IC.includes(b.key)&&(v.current=!0)},h=()=>v.current=!1;return document.addEventListener("keydown",g),document.addEventListener("keyup",h),()=>{document.removeEventListener("keydown",g),document.removeEventListener("keyup",h)}},[]),s.jsx(On,{asChild:!0,...c,focusable:!i,active:m,children:s.jsx(mp,{disabled:i,required:a.required,checked:m,...d,...o,name:a.name,ref:f,onCheck:()=>a.onValueChange(o.value),onKeyDown:l.composeEventHandlers(g=>{g.key==="Enter"&&g.preventDefault()}),onFocus:l.composeEventHandlers(o.onFocus,()=>{var g;v.current&&((g=p.current)==null||g.click())})})})});Ep.displayName=Cp;var LC="RadioGroupIndicator",_p=u.forwardRef((e,n)=>{const{__scopeRadioGroup:t,...r}=e,o=yp(t);return s.jsx(gp,{...o,...r,ref:n})});_p.displayName=LC;var Pp=wp,Rp=Ep,$C=_p;const kp=u.forwardRef(({className:e,...n},t)=>s.jsx(Pp,{className:l.cn("grid gap-2",e),...n,ref:t}));kp.displayName=Pp.displayName;const Tp=u.forwardRef(({className:e,checked:n,size:t,...r},o)=>s.jsx(Rp,{ref:o,"data-slot":"radio-group-item",className:l.cn("aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive shadow-xs aspect-square size-4 shrink-0 rounded-full border border-grey-300 text-primary outline-none transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 dark:bg-input/30 md:size-[18px]",e),...r,children:s.jsx($C,{"data-slot":"radio-group-indicator",className:"relative flex items-center justify-center",children:s.jsx(xc,{className:"absolute left-1/2 top-1/2 size-2 -translate-x-1/2 -translate-y-1/2 fill-primary md:size-[10px]"})})}));Tp.displayName=Rp.displayName;var HC="Separator",Pi="horizontal",WC=["horizontal","vertical"],Dp=u.forwardRef((e,n)=>{const{decorative:t,orientation:r=Pi,...o}=e,a=zC(r)?r:Pi,c=t?{role:"none"}:{"aria-orientation":a==="vertical"?a:void 0,role:"separator"};return s.jsx(l.Primitive.div,{"data-orientation":a,...c,...o,ref:n})});Dp.displayName=HC;function zC(e){return WC.includes(e)}var Np=Dp;const Mp=u.forwardRef(({className:e,orientation:n="horizontal",decorative:t=!0,...r},o)=>s.jsx(Np,{ref:o,decorative:t,orientation:n,className:l.cn("shrink-0 bg-border",n==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...r}));Mp.displayName=Np.displayName;var Yn="Switch",[YC,o_]=l.createContextScope(Yn),[VC,GC]=YC(Yn),Sp=u.forwardRef((e,n)=>{const{__scopeSwitch:t,name:r,checked:o,defaultChecked:a,required:i,disabled:c,value:d="on",onCheckedChange:p,form:f,...m}=e,[v,g]=u.useState(null),h=l.useComposedRefs(n,P=>g(P)),b=u.useRef(!1),x=v?f||!!v.closest("form"):!0,[E,w]=l.useControllableState({prop:o,defaultProp:a??!1,onChange:p,caller:Yn});return s.jsxs(VC,{scope:t,checked:E,disabled:c,children:[s.jsx(l.Primitive.button,{type:"button",role:"switch","aria-checked":E,"aria-required":i,"data-state":Op(E),"data-disabled":c?"":void 0,disabled:c,value:d,...m,ref:h,onClick:l.composeEventHandlers(e.onClick,P=>{w(_=>!_),x&&(b.current=P.isPropagationStopped(),b.current||P.stopPropagation())})}),x&&s.jsx(Ap,{control:v,bubbles:!b.current,name:r,value:d,checked:E,required:i,disabled:c,form:f,style:{transform:"translateX(-100%)"}})]})});Sp.displayName=Yn;var jp="SwitchThumb",Ip=u.forwardRef((e,n)=>{const{__scopeSwitch:t,...r}=e,o=GC(jp,t);return s.jsx(l.Primitive.span,{"data-state":Op(o.checked),"data-disabled":o.disabled?"":void 0,...r,ref:n})});Ip.displayName=jp;var qC="SwitchBubbleInput",Ap=u.forwardRef(({__scopeSwitch:e,control:n,checked:t,bubbles:r=!0,...o},a)=>{const i=u.useRef(null),c=l.useComposedRefs(i,a),d=l.usePrevious(t),p=l.useSize(n);return u.useEffect(()=>{const f=i.current;if(!f)return;const m=window.HTMLInputElement.prototype,g=Object.getOwnPropertyDescriptor(m,"checked").set;if(d!==t&&g){const h=new Event("click",{bubbles:r});g.call(f,t),f.dispatchEvent(h)}},[d,t,r]),s.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:t,...o,tabIndex:-1,ref:c,style:{...o.style,...p,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});Ap.displayName=qC;function Op(e){return e?"checked":"unchecked"}var Fp=Sp,BC=Ip;const Lp=u.forwardRef(({className:e,...n},t)=>s.jsx(Fp,{className:l.cn("peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...n,ref:t,children:s.jsx(BC,{className:l.cn("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0")})}));Lp.displayName=Fp.displayName;var Vn="Tabs",[KC,a_]=l.createContextScope(Vn,[et]),$p=et(),[UC,Ea]=KC(Vn),Hp=u.forwardRef((e,n)=>{const{__scopeTabs:t,value:r,onValueChange:o,defaultValue:a,orientation:i="horizontal",dir:c,activationMode:d="automatic",...p}=e,f=l.useDirection(c),[m,v]=l.useControllableState({prop:r,onChange:o,defaultProp:a??"",caller:Vn});return s.jsx(UC,{scope:t,baseId:l.useId(),value:m,onValueChange:v,orientation:i,dir:f,activationMode:d,children:s.jsx(l.Primitive.div,{dir:f,"data-orientation":i,...p,ref:n})})});Hp.displayName=Vn;var Wp="TabsList",zp=u.forwardRef((e,n)=>{const{__scopeTabs:t,loop:r=!0,...o}=e,a=Ea(Wp,t),i=$p(t);return s.jsx(An,{asChild:!0,...i,orientation:a.orientation,dir:a.dir,loop:r,children:s.jsx(l.Primitive.div,{role:"tablist","aria-orientation":a.orientation,...o,ref:n})})});zp.displayName=Wp;var Yp="TabsTrigger",Vp=u.forwardRef((e,n)=>{const{__scopeTabs:t,value:r,disabled:o=!1,...a}=e,i=Ea(Yp,t),c=$p(t),d=Bp(i.baseId,r),p=Kp(i.baseId,r),f=r===i.value;return s.jsx(On,{asChild:!0,...c,focusable:!o,active:f,children:s.jsx(l.Primitive.button,{type:"button",role:"tab","aria-selected":f,"aria-controls":p,"data-state":f?"active":"inactive","data-disabled":o?"":void 0,disabled:o,id:d,...a,ref:n,onMouseDown:l.composeEventHandlers(e.onMouseDown,m=>{!o&&m.button===0&&m.ctrlKey===!1?i.onValueChange(r):m.preventDefault()}),onKeyDown:l.composeEventHandlers(e.onKeyDown,m=>{[" ","Enter"].includes(m.key)&&i.onValueChange(r)}),onFocus:l.composeEventHandlers(e.onFocus,()=>{const m=i.activationMode!=="manual";!f&&!o&&m&&i.onValueChange(r)})})})});Vp.displayName=Yp;var Gp="TabsContent",qp=u.forwardRef((e,n)=>{const{__scopeTabs:t,value:r,forceMount:o,children:a,...i}=e,c=Ea(Gp,t),d=Bp(c.baseId,r),p=Kp(c.baseId,r),f=r===c.value,m=u.useRef(f);return u.useEffect(()=>{const v=requestAnimationFrame(()=>m.current=!1);return()=>cancelAnimationFrame(v)},[]),s.jsx(de,{present:o||f,children:({present:v})=>s.jsx(l.Primitive.div,{"data-state":f?"active":"inactive","data-orientation":c.orientation,role:"tabpanel","aria-labelledby":d,hidden:!v,id:p,tabIndex:0,...i,ref:n,style:{...e.style,animationDuration:m.current?"0s":void 0},children:v&&a})})});qp.displayName=Gp;function Bp(e,n){return`${e}-trigger-${n}`}function Kp(e,n){return`${e}-content-${n}`}var XC=Hp,Up=zp,Xp=Vp,Qp=qp;const QC=XC,Zp=u.forwardRef(({className:e,...n},t)=>s.jsx(Up,{ref:t,className:l.cn("inline-flex items-center justify-center rounded-lg bg-grey-200 p-1 text-grey-600",e),...n}));Zp.displayName=Up.displayName;const Jp=u.forwardRef(({className:e,...n},t)=>s.jsx(Xp,{ref:t,className:l.cn("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",e),...n}));Jp.displayName=Xp.displayName;const ef=u.forwardRef(({className:e,...n},t)=>s.jsx(Qp,{ref:t,className:l.cn("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...n}));ef.displayName=Qp.displayName;const tf=u.forwardRef(({className:e,error:n,...t},r)=>s.jsx("textarea",{className:l.cn("flex min-h-[72px] w-full rounded-md border bg-background px-3 py-2 text-sm font-normal placeholder:text-sm placeholder:text-muted focus-visible:outline-none disabled:cursor-not-allowed disabled:opacity-50 md:px-4 md:py-2.5 md:text-base placeholder:md:text-base",n?"border-red-600 focus:border-red-600":"border-border focus:border-grey-800",e),ref:r,placeholder:"테스트",...t}));tf.displayName="Textarea";var _a="ToastProvider",[Pa,ZC,JC]=l.createCollection("Toast"),[nf,i_]=l.createContextScope("Toast",[JC]),[eE,Gn]=nf(_a),rf=e=>{const{__scopeToast:n,label:t="Notification",duration:r=5e3,swipeDirection:o="right",swipeThreshold:a=50,children:i}=e,[c,d]=u.useState(null),[p,f]=u.useState(0),m=u.useRef(!1),v=u.useRef(!1);return t.trim()||console.error(`Invalid prop \`label\` supplied to \`${_a}\`. Expected non-empty \`string\`.`),s.jsx(Pa.Provider,{scope:n,children:s.jsx(eE,{scope:n,label:t,duration:r,swipeDirection:o,swipeThreshold:a,toastCount:p,viewport:c,onViewportChange:d,onToastAdd:u.useCallback(()=>f(g=>g+1),[]),onToastRemove:u.useCallback(()=>f(g=>g-1),[]),isFocusedToastEscapeKeyDownRef:m,isClosePausedRef:v,children:i})})};rf.displayName=_a;var of="ToastViewport",tE=["F8"],no="toast.viewportPause",ro="toast.viewportResume",af=u.forwardRef((e,n)=>{const{__scopeToast:t,hotkey:r=tE,label:o="Notifications ({hotkey})",...a}=e,i=Gn(of,t),c=ZC(t),d=u.useRef(null),p=u.useRef(null),f=u.useRef(null),m=u.useRef(null),v=l.useComposedRefs(n,m,i.onViewportChange),g=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),h=i.toastCount>0;u.useEffect(()=>{const x=E=>{var P;r.length!==0&&r.every(_=>E[_]||E.code===_)&&((P=m.current)==null||P.focus())};return document.addEventListener("keydown",x),()=>document.removeEventListener("keydown",x)},[r]),u.useEffect(()=>{const x=d.current,E=m.current;if(h&&x&&E){const w=()=>{if(!i.isClosePausedRef.current){const T=new CustomEvent(no);E.dispatchEvent(T),i.isClosePausedRef.current=!0}},P=()=>{if(i.isClosePausedRef.current){const T=new CustomEvent(ro);E.dispatchEvent(T),i.isClosePausedRef.current=!1}},_=T=>{!x.contains(T.relatedTarget)&&P()},y=()=>{x.contains(document.activeElement)||P()};return x.addEventListener("focusin",w),x.addEventListener("focusout",_),x.addEventListener("pointermove",w),x.addEventListener("pointerleave",y),window.addEventListener("blur",w),window.addEventListener("focus",P),()=>{x.removeEventListener("focusin",w),x.removeEventListener("focusout",_),x.removeEventListener("pointermove",w),x.removeEventListener("pointerleave",y),window.removeEventListener("blur",w),window.removeEventListener("focus",P)}}},[h,i.isClosePausedRef]);const b=u.useCallback(({tabbingDirection:x})=>{const w=c().map(P=>{const _=P.ref.current,y=[_,...mE(_)];return x==="forwards"?y:y.reverse()});return(x==="forwards"?w.reverse():w).flat()},[c]);return u.useEffect(()=>{const x=m.current;if(x){const E=w=>{var y,T,$;const P=w.altKey||w.ctrlKey||w.metaKey;if(w.key==="Tab"&&!P){const V=document.activeElement,A=w.shiftKey;if(w.target===x&&A){(y=p.current)==null||y.focus();return}const te=b({tabbingDirection:A?"backwards":"forwards"}),re=te.findIndex(I=>I===V);Sr(te.slice(re+1))?w.preventDefault():A?(T=p.current)==null||T.focus():($=f.current)==null||$.focus()}};return x.addEventListener("keydown",E),()=>x.removeEventListener("keydown",E)}},[c,b]),s.jsxs(l.Branch,{ref:d,role:"region","aria-label":o.replace("{hotkey}",g),tabIndex:-1,style:{pointerEvents:h?void 0:"none"},children:[h&&s.jsx(oo,{ref:p,onFocusFromOutsideViewport:()=>{const x=b({tabbingDirection:"forwards"});Sr(x)}}),s.jsx(Pa.Slot,{scope:t,children:s.jsx(l.Primitive.ol,{tabIndex:-1,...a,ref:v})}),h&&s.jsx(oo,{ref:f,onFocusFromOutsideViewport:()=>{const x=b({tabbingDirection:"backwards"});Sr(x)}})]})});af.displayName=of;var sf="ToastFocusProxy",oo=u.forwardRef((e,n)=>{const{__scopeToast:t,onFocusFromOutsideViewport:r,...o}=e,a=Gn(sf,t);return s.jsx(l.VisuallyHidden,{"aria-hidden":!0,tabIndex:0,...o,ref:n,style:{position:"fixed"},onFocus:i=>{var p;const c=i.relatedTarget;!((p=a.viewport)!=null&&p.contains(c))&&r()}})});oo.displayName=sf;var Qt="Toast",nE="toast.swipeStart",rE="toast.swipeMove",oE="toast.swipeCancel",aE="toast.swipeEnd",cf=u.forwardRef((e,n)=>{const{forceMount:t,open:r,defaultOpen:o,onOpenChange:a,...i}=e,[c,d]=l.useControllableState({prop:r,defaultProp:o??!0,onChange:a,caller:Qt});return s.jsx(de,{present:t||c,children:s.jsx(cE,{open:c,...i,ref:n,onClose:()=>d(!1),onPause:l.useCallbackRef(e.onPause),onResume:l.useCallbackRef(e.onResume),onSwipeStart:l.composeEventHandlers(e.onSwipeStart,p=>{p.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:l.composeEventHandlers(e.onSwipeMove,p=>{const{x:f,y:m}=p.detail.delta;p.currentTarget.setAttribute("data-swipe","move"),p.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${f}px`),p.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${m}px`)}),onSwipeCancel:l.composeEventHandlers(e.onSwipeCancel,p=>{p.currentTarget.setAttribute("data-swipe","cancel"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),p.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:l.composeEventHandlers(e.onSwipeEnd,p=>{const{x:f,y:m}=p.detail.delta;p.currentTarget.setAttribute("data-swipe","end"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),p.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${f}px`),p.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${m}px`),d(!1)})})})});cf.displayName=Qt;var[iE,sE]=nf(Qt,{onClose(){}}),cE=u.forwardRef((e,n)=>{const{__scopeToast:t,type:r="foreground",duration:o,open:a,onClose:i,onEscapeKeyDown:c,onPause:d,onResume:p,onSwipeStart:f,onSwipeMove:m,onSwipeCancel:v,onSwipeEnd:g,...h}=e,b=Gn(Qt,t),[x,E]=u.useState(null),w=l.useComposedRefs(n,I=>E(I)),P=u.useRef(null),_=u.useRef(null),y=o||b.duration,T=u.useRef(0),$=u.useRef(y),V=u.useRef(0),{onToastAdd:A,onToastRemove:q}=b,K=l.useCallbackRef(()=>{var Q;(x==null?void 0:x.contains(document.activeElement))&&((Q=b.viewport)==null||Q.focus()),i()}),te=u.useCallback(I=>{!I||I===1/0||(window.clearTimeout(V.current),T.current=new Date().getTime(),V.current=window.setTimeout(K,I))},[K]);u.useEffect(()=>{const I=b.viewport;if(I){const Q=()=>{te($.current),p==null||p()},J=()=>{const j=new Date().getTime()-T.current;$.current=$.current-j,window.clearTimeout(V.current),d==null||d()};return I.addEventListener(no,J),I.addEventListener(ro,Q),()=>{I.removeEventListener(no,J),I.removeEventListener(ro,Q)}}},[b.viewport,y,d,p,te]),u.useEffect(()=>{a&&!b.isClosePausedRef.current&&te(y)},[a,y,b.isClosePausedRef,te]),u.useEffect(()=>(A(),()=>q()),[A,q]);const re=u.useMemo(()=>x?vf(x):null,[x]);return b.viewport?s.jsxs(s.Fragment,{children:[re&&s.jsx(lE,{__scopeToast:t,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0,children:re}),s.jsx(iE,{scope:t,onClose:K,children:am.createPortal(s.jsx(Pa.ItemSlot,{scope:t,children:s.jsx(l.Root$1,{asChild:!0,onEscapeKeyDown:l.composeEventHandlers(c,()=>{b.isFocusedToastEscapeKeyDownRef.current||K(),b.isFocusedToastEscapeKeyDownRef.current=!1}),children:s.jsx(l.Primitive.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":a?"open":"closed","data-swipe-direction":b.swipeDirection,...h,ref:w,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:l.composeEventHandlers(e.onKeyDown,I=>{I.key==="Escape"&&(c==null||c(I.nativeEvent),I.nativeEvent.defaultPrevented||(b.isFocusedToastEscapeKeyDownRef.current=!0,K()))}),onPointerDown:l.composeEventHandlers(e.onPointerDown,I=>{I.button===0&&(P.current={x:I.clientX,y:I.clientY})}),onPointerMove:l.composeEventHandlers(e.onPointerMove,I=>{if(!P.current)return;const Q=I.clientX-P.current.x,J=I.clientY-P.current.y,j=!!_.current,F=["left","right"].includes(b.swipeDirection),H=["left","up"].includes(b.swipeDirection)?Math.min:Math.max,k=F?H(0,Q):0,S=F?0:H(0,J),R=I.pointerType==="touch"?10:2,D={x:k,y:S},M={originalEvent:I,delta:D};j?(_.current=D,on(rE,m,M,{discrete:!1})):Ri(D,b.swipeDirection,R)?(_.current=D,on(nE,f,M,{discrete:!1}),I.target.setPointerCapture(I.pointerId)):(Math.abs(Q)>R||Math.abs(J)>R)&&(P.current=null)}),onPointerUp:l.composeEventHandlers(e.onPointerUp,I=>{const Q=_.current,J=I.target;if(J.hasPointerCapture(I.pointerId)&&J.releasePointerCapture(I.pointerId),_.current=null,P.current=null,Q){const j=I.currentTarget,F={originalEvent:I,delta:Q};Ri(Q,b.swipeDirection,b.swipeThreshold)?on(aE,g,F,{discrete:!0}):on(oE,v,F,{discrete:!0}),j.addEventListener("click",H=>H.preventDefault(),{once:!0})}})})})}),b.viewport)})]}):null}),lE=e=>{const{__scopeToast:n,children:t,...r}=e,o=Gn(Qt,n),[a,i]=u.useState(!1),[c,d]=u.useState(!1);return pE(()=>i(!0)),u.useEffect(()=>{const p=window.setTimeout(()=>d(!0),1e3);return()=>window.clearTimeout(p)},[]),c?null:s.jsx(l.Portal,{asChild:!0,children:s.jsx(l.VisuallyHidden,{...r,children:a&&s.jsxs(s.Fragment,{children:[o.label," ",t]})})})},dE="ToastTitle",lf=u.forwardRef((e,n)=>{const{__scopeToast:t,...r}=e;return s.jsx(l.Primitive.div,{...r,ref:n})});lf.displayName=dE;var uE="ToastDescription",df=u.forwardRef((e,n)=>{const{__scopeToast:t,...r}=e;return s.jsx(l.Primitive.div,{...r,ref:n})});df.displayName=uE;var uf="ToastAction",pf=u.forwardRef((e,n)=>{const{altText:t,...r}=e;return t.trim()?s.jsx(mf,{altText:t,asChild:!0,children:s.jsx(Ra,{...r,ref:n})}):(console.error(`Invalid prop \`altText\` supplied to \`${uf}\`. Expected non-empty \`string\`.`),null)});pf.displayName=uf;var ff="ToastClose",Ra=u.forwardRef((e,n)=>{const{__scopeToast:t,...r}=e,o=sE(ff,t);return s.jsx(mf,{asChild:!0,children:s.jsx(l.Primitive.button,{type:"button",...r,ref:n,onClick:l.composeEventHandlers(e.onClick,o.onClose)})})});Ra.displayName=ff;var mf=u.forwardRef((e,n)=>{const{__scopeToast:t,altText:r,...o}=e;return s.jsx(l.Primitive.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...o,ref:n})});function vf(e){const n=[];return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&n.push(r.textContent),fE(r)){const o=r.ariaHidden||r.hidden||r.style.display==="none",a=r.dataset.radixToastAnnounceExclude==="";if(!o)if(a){const i=r.dataset.radixToastAnnounceAlt;i&&n.push(i)}else n.push(...vf(r))}}),n}function on(e,n,t,{discrete:r}){const o=t.originalEvent.currentTarget,a=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:t});n&&o.addEventListener(e,n,{once:!0}),r?l.dispatchDiscreteCustomEvent(o,a):o.dispatchEvent(a)}var Ri=(e,n,t=0)=>{const r=Math.abs(e.x),o=Math.abs(e.y),a=r>o;return n==="left"||n==="right"?a&&r>t:!a&&o>t};function pE(e=()=>{}){const n=l.useCallbackRef(e);l.useLayoutEffect2(()=>{let t=0,r=0;return t=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(n)),()=>{window.cancelAnimationFrame(t),window.cancelAnimationFrame(r)}},[n])}function fE(e){return e.nodeType===e.ELEMENT_NODE}function mE(e){const n=[],t=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;t.nextNode();)n.push(t.currentNode);return n}function Sr(e){const n=document.activeElement;return e.some(t=>t===n?!0:(t.focus(),document.activeElement!==n))}var gf=rf,qn=af,Bn=cf,Kn=lf,Un=df,Xn=pf,Qn=Ra;const vE=gf,hf={"top-left":"top-0 left-0 bottom-auto mt-10 items-start","top-center":"top-0 left-1/2 bottom-auto transform -translate-x-1/2 mt-10 items-center","top-right":"top-0 right-0 bottom-auto items-end mt-10","bottom-left":"top-auto bottom-4 left-0 items-start","bottom-center":"top-auto bottom-4 left-1/2 transform -translate-x-1/2 items-center","bottom-right":"top-auto bottom-4 right-0 items-end"},xf=u.forwardRef(({className:e,id:n,position:t="top-center",...r},o)=>s.jsx(qn,{ref:o,id:n,className:l.cn("fixed z-[100] flex flex-col-reverse gap-2 p-4 outline-none ring-transparent md:p-10",hf[t],e),...r}));xf.displayName=qn.displayName;const bf=Ke("group pointer-events-auto bg-opacity-90 overflow-hidden rounded-lg border shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-top-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-top-full",{variants:{variant:{black:"group border bg-grey-800 border-grey-800 text-grey-50",white:"group border bg-grey-50 border-grey-50 text-grey-800"},size:{sm:"w-[300px]",md:"w-[400px]",lg:"w-[600px]",xl:"w-[800px]",full:"w-[90vw]",fit:"w-fit"}},defaultVariants:{variant:"black",size:"fit"}}),yf=u.forwardRef(({className:e,variant:n,size:t,...r},o)=>s.jsx(Bn,{ref:o,className:l.cn(bf({variant:n,size:t}),e),duration:3e3,...r}));yf.displayName=Bn.displayName;const wf=u.forwardRef(({className:e,...n},t)=>s.jsx(Xn,{ref:t,className:l.cn(Me({variant:"outline",size:"sm",theme:"secondary"}),e),...n}));wf.displayName=Xn.displayName;const Cf=u.forwardRef(({className:e,children:n,...t},r)=>s.jsx(Qn,{ref:r,className:l.cn("absolute right-1.5 top-1.5 rounded-md p-1 focus:outline-none",e),"toast-close":"",...t,children:n}));Cf.displayName=Qn.displayName;const Ef=u.forwardRef(({className:e,...n},t)=>s.jsx(Kn,{ref:t,className:l.cn("text-sm font-semibold",e),...n}));Ef.displayName=Kn.displayName;const _f=u.forwardRef(({className:e,...n},t)=>s.jsx(Un,{ref:t,className:l.cn("text-sm font-normal",e),...n}));_f.displayName=Un.displayName;const gE=gf,hE=Ke("fixed inset-0 z-50 flex items-center justify-center p-4",{variants:{isOpen:{close:"",open:"bg-black bg-opacity-50"}},defaultVariants:{isOpen:"close"}}),Pf=u.forwardRef(({className:e,isOpen:n,...t},r)=>s.jsx(qn,{ref:r,className:l.cn(hE({isOpen:n}),e),...t}));Pf.displayName=qn.displayName;const xE=Ke("relative w-full px-6 py-4 rounded-md shadow-lg",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"},width:{xs:"max-w-[330px]",sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",full:"max-w-full w-[90%]",fit:"max-w-fit"},closeType:{force:!0,free:!1}},defaultVariants:{variant:"default",width:"md",closeType:"free"}}),Rf=u.forwardRef(({className:e,variant:n,width:t,closeType:r,...o},a)=>s.jsx(Bn,{ref:a,className:l.cn(xE({variant:n,width:t,closeType:r}),e),...o,duration:1/0,onEscapeKeyDown:i=>{r&&i.preventDefault()}}));Rf.displayName=Bn.displayName;const kf=u.forwardRef(({className:e,size:n,variant:t,children:r,...o},a)=>s.jsx(Xn,{ref:a,className:l.cn(Me({size:n,variant:t}),e),...o,children:r}));kf.displayName=Xn.displayName;const Tf=u.forwardRef(({className:e,size:n,variant:t,children:r,...o},a)=>s.jsx(Qn,{ref:a,className:l.cn(Me({size:n,variant:t}),e),...o,children:r}));Tf.displayName=Qn.displayName;const Df=u.forwardRef(({className:e,...n},t)=>s.jsx(Kn,{ref:t,className:l.cn("break-keep text-lg font-semibold text-foreground",e),...n}));Df.displayName=Kn.displayName;const Nf=u.forwardRef(({className:e,...n},t)=>s.jsx(Un,{ref:t,className:l.cn("whitespace-pre-wrap text-xs font-normal text-grey-600",e),...n}));Nf.displayName=Un.displayName;const bE=({className:e,children:n})=>s.jsx("div",{className:l.cn("flex w-full flex-col gap-4",e),children:n});var Mf="Toggle",ka=u.forwardRef((e,n)=>{const{pressed:t,defaultPressed:r,onPressedChange:o,...a}=e,[i,c]=l.useControllableState({prop:t,onChange:o,defaultProp:r??!1,caller:Mf});return s.jsx(l.Primitive.button,{type:"button","aria-pressed":i,"data-state":i?"on":"off","data-disabled":e.disabled?"":void 0,...a,ref:n,onClick:l.composeEventHandlers(e.onClick,()=>{e.disabled||c(!i)})})});ka.displayName=Mf;var Sf=ka;const Ta=Ke("inline-flex items-center justify-center gap-1 whitespace-nowrap text-sm font-normal ring-offset-background transition-all focus-visible:outline-none disabled:pointer-events-none",{variants:{variant:{solid:"disabled:bg-muted disabled:text-muted-foreground disabled:border-muted",outline:"disabled:bg-white disabled:text-muted disabled:border-border"},theme:{primary:"bg-white border border-main-200 text-primary hover:bg-main-100",secondary:"bg-white border border-grey-200 text-secondary hover:bg-grey-100"},size:{xs:"h-8 py-1 px-2 text-sm",sm:"h-9 py-2 px-3 text-sm",md:"h-11 px-3 py-3 text-sm",lg:"h-[52px] px-12 py-[14px] text-base",icon:"h-auto w-auto"},shape:{square:"rounded-lg",rounded:"rounded-full"},checked:{true:"",false:""}},compoundVariants:[{theme:"primary",checked:!0,className:"bg-main-600 border-main-600 text-white hover:bg-main-700 hover:border-main-700"},{theme:"secondary",checked:!0,className:"bg-grey-800 border-grey-800 text-white hover:bg-grey-900 hover:border-grey-900"}],defaultVariants:{theme:"primary",size:"md",shape:"square",checked:!1}}),jf=u.forwardRef(({className:e,variant:n,size:t,theme:r,checked:o,...a},i)=>s.jsx(Sf,{ref:i,className:l.cn(Ta({variant:n,size:t,className:e,theme:r,checked:o})),...a}));jf.displayName=Sf.displayName;var rt="ToggleGroup",[If,s_]=l.createContextScope(rt,[et]),Af=et(),Da=C.forwardRef((e,n)=>{const{type:t,...r}=e;if(t==="single"){const o=r;return s.jsx(yE,{...o,ref:n})}if(t==="multiple"){const o=r;return s.jsx(wE,{...o,ref:n})}throw new Error(`Missing prop \`type\` expected on \`${rt}\``)});Da.displayName=rt;var[Of,Ff]=If(rt),yE=C.forwardRef((e,n)=>{const{value:t,defaultValue:r,onValueChange:o=()=>{},...a}=e,[i,c]=l.useControllableState({prop:t,defaultProp:r??"",onChange:o,caller:rt});return s.jsx(Of,{scope:e.__scopeToggleGroup,type:"single",value:C.useMemo(()=>i?[i]:[],[i]),onItemActivate:c,onItemDeactivate:C.useCallback(()=>c(""),[c]),children:s.jsx(Lf,{...a,ref:n})})}),wE=C.forwardRef((e,n)=>{const{value:t,defaultValue:r,onValueChange:o=()=>{},...a}=e,[i,c]=l.useControllableState({prop:t,defaultProp:r??[],onChange:o,caller:rt}),d=C.useCallback(f=>c((m=[])=>[...m,f]),[c]),p=C.useCallback(f=>c((m=[])=>m.filter(v=>v!==f)),[c]);return s.jsx(Of,{scope:e.__scopeToggleGroup,type:"multiple",value:i,onItemActivate:d,onItemDeactivate:p,children:s.jsx(Lf,{...a,ref:n})})});Da.displayName=rt;var[CE,EE]=If(rt),Lf=C.forwardRef((e,n)=>{const{__scopeToggleGroup:t,disabled:r=!1,rovingFocus:o=!0,orientation:a,dir:i,loop:c=!0,...d}=e,p=Af(t),f=l.useDirection(i),m={role:"group",dir:f,...d};return s.jsx(CE,{scope:t,rovingFocus:o,disabled:r,children:o?s.jsx(An,{asChild:!0,...p,orientation:a,dir:f,loop:c,children:s.jsx(l.Primitive.div,{...m,ref:n})}):s.jsx(l.Primitive.div,{...m,ref:n})})}),wn="ToggleGroupItem",$f=C.forwardRef((e,n)=>{const t=Ff(wn,e.__scopeToggleGroup),r=EE(wn,e.__scopeToggleGroup),o=Af(e.__scopeToggleGroup),a=t.value.includes(e.value),i=r.disabled||e.disabled,c={...e,pressed:a,disabled:i},d=C.useRef(null);return r.rovingFocus?s.jsx(On,{asChild:!0,...o,focusable:!i,active:a,ref:d,children:s.jsx(ki,{...c,ref:n})}):s.jsx(ki,{...c,ref:n})});$f.displayName=wn;var ki=C.forwardRef((e,n)=>{const{__scopeToggleGroup:t,value:r,...o}=e,a=Ff(wn,t),i={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},c=a.type==="single"?i:void 0;return s.jsx(ka,{...c,...o,ref:n,onPressedChange:d=>{d?a.onItemActivate(r):a.onItemDeactivate(r)}})}),Hf=Da,Wf=$f;const Na=u.createContext({theme:"primary",size:"md",shape:"square"});Na.displayName="ToggleGroupContext";const zf=u.forwardRef(({className:e,variant:n,theme:t,size:r,shape:o,children:a,...i},c)=>s.jsx(Na.Provider,{value:{theme:t,size:r,shape:o},children:s.jsx(Hf,{ref:c,className:l.cn("flex items-center justify-center gap-1",e),...i,children:a})}));zf.displayName=Hf.displayName;const Yf=u.forwardRef(({className:e,checked:n=!1,children:t,...r},o)=>{const a=u.useContext(Na);return s.jsx(Wf,{ref:o,className:l.cn(Ta({theme:r.theme||a.theme||"primary",size:r.size||a.size||"md",shape:r.shape||a.shape||"square",variant:r.variant||"outline",checked:n}),e),...r,children:t})});Yf.displayName=Wf.displayName;var[Zn,c_]=l.createContextScope("Tooltip",[l.createPopperScope]),Jn=l.createPopperScope(),Vf="TooltipProvider",_E=700,ao="tooltip.open",[PE,Ma]=Zn(Vf),Gf=e=>{const{__scopeTooltip:n,delayDuration:t=_E,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:a}=e,i=u.useRef(!0),c=u.useRef(!1),d=u.useRef(0);return u.useEffect(()=>{const p=d.current;return()=>window.clearTimeout(p)},[]),s.jsx(PE,{scope:n,isOpenDelayedRef:i,delayDuration:t,onOpen:u.useCallback(()=>{window.clearTimeout(d.current),i.current=!1},[]),onClose:u.useCallback(()=>{window.clearTimeout(d.current),d.current=window.setTimeout(()=>i.current=!0,r)},[r]),isPointerInTransitRef:c,onPointerInTransitChange:u.useCallback(p=>{c.current=p},[]),disableHoverableContent:o,children:a})};Gf.displayName=Vf;var Ft="Tooltip",[RE,er]=Zn(Ft),qf=e=>{const{__scopeTooltip:n,children:t,open:r,defaultOpen:o,onOpenChange:a,disableHoverableContent:i,delayDuration:c}=e,d=Ma(Ft,e.__scopeTooltip),p=Jn(n),[f,m]=u.useState(null),v=l.useId(),g=u.useRef(0),h=i??d.disableHoverableContent,b=c??d.delayDuration,x=u.useRef(!1),[E,w]=l.useControllableState({prop:r,defaultProp:o??!1,onChange:$=>{$?(d.onOpen(),document.dispatchEvent(new CustomEvent(ao))):d.onClose(),a==null||a($)},caller:Ft}),P=u.useMemo(()=>E?x.current?"delayed-open":"instant-open":"closed",[E]),_=u.useCallback(()=>{window.clearTimeout(g.current),g.current=0,x.current=!1,w(!0)},[w]),y=u.useCallback(()=>{window.clearTimeout(g.current),g.current=0,w(!1)},[w]),T=u.useCallback(()=>{window.clearTimeout(g.current),g.current=window.setTimeout(()=>{x.current=!0,w(!0),g.current=0},b)},[b,w]);return u.useEffect(()=>()=>{g.current&&(window.clearTimeout(g.current),g.current=0)},[]),s.jsx(l.Root2,{...p,children:s.jsx(RE,{scope:n,contentId:v,open:E,stateAttribute:P,trigger:f,onTriggerChange:m,onTriggerEnter:u.useCallback(()=>{d.isOpenDelayedRef.current?T():_()},[d.isOpenDelayedRef,T,_]),onTriggerLeave:u.useCallback(()=>{h?y():(window.clearTimeout(g.current),g.current=0)},[y,h]),onOpen:_,onClose:y,disableHoverableContent:h,children:t})})};qf.displayName=Ft;var io="TooltipTrigger",Bf=u.forwardRef((e,n)=>{const{__scopeTooltip:t,...r}=e,o=er(io,t),a=Ma(io,t),i=Jn(t),c=u.useRef(null),d=l.useComposedRefs(n,c,o.onTriggerChange),p=u.useRef(!1),f=u.useRef(!1),m=u.useCallback(()=>p.current=!1,[]);return u.useEffect(()=>()=>document.removeEventListener("pointerup",m),[m]),s.jsx(l.Anchor,{asChild:!0,...i,children:s.jsx(l.Primitive.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:d,onPointerMove:l.composeEventHandlers(e.onPointerMove,v=>{v.pointerType!=="touch"&&!f.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),f.current=!0)}),onPointerLeave:l.composeEventHandlers(e.onPointerLeave,()=>{o.onTriggerLeave(),f.current=!1}),onPointerDown:l.composeEventHandlers(e.onPointerDown,()=>{o.open&&o.onClose(),p.current=!0,document.addEventListener("pointerup",m,{once:!0})}),onFocus:l.composeEventHandlers(e.onFocus,()=>{p.current||o.onOpen()}),onBlur:l.composeEventHandlers(e.onBlur,o.onClose),onClick:l.composeEventHandlers(e.onClick,o.onClose)})})});Bf.displayName=io;var kE="TooltipPortal",[l_,TE]=Zn(kE,{forceMount:void 0}),Rt="TooltipContent",Kf=u.forwardRef((e,n)=>{const t=TE(Rt,e.__scopeTooltip),{forceMount:r=t.forceMount,side:o="top",...a}=e,i=er(Rt,e.__scopeTooltip);return s.jsx(de,{present:r||i.open,children:i.disableHoverableContent?s.jsx(Uf,{side:o,...a,ref:n}):s.jsx(DE,{side:o,...a,ref:n})})}),DE=u.forwardRef((e,n)=>{const t=er(Rt,e.__scopeTooltip),r=Ma(Rt,e.__scopeTooltip),o=u.useRef(null),a=l.useComposedRefs(n,o),[i,c]=u.useState(null),{trigger:d,onClose:p}=t,f=o.current,{onPointerInTransitChange:m}=r,v=u.useCallback(()=>{c(null),m(!1)},[m]),g=u.useCallback((h,b)=>{const x=h.currentTarget,E={x:h.clientX,y:h.clientY},w=IE(E,x.getBoundingClientRect()),P=AE(E,w),_=OE(b.getBoundingClientRect()),y=LE([...P,..._]);c(y),m(!0)},[m]);return u.useEffect(()=>()=>v(),[v]),u.useEffect(()=>{if(d&&f){const h=x=>g(x,f),b=x=>g(x,d);return d.addEventListener("pointerleave",h),f.addEventListener("pointerleave",b),()=>{d.removeEventListener("pointerleave",h),f.removeEventListener("pointerleave",b)}}},[d,f,g,v]),u.useEffect(()=>{if(i){const h=b=>{const x=b.target,E={x:b.clientX,y:b.clientY},w=(d==null?void 0:d.contains(x))||(f==null?void 0:f.contains(x)),P=!FE(E,i);w?v():P&&(v(),p())};return document.addEventListener("pointermove",h),()=>document.removeEventListener("pointermove",h)}},[d,f,i,p,v]),s.jsx(Uf,{...e,ref:a})}),[NE,ME]=Zn(Ft,{isInside:!1}),SE=l.createSlottable("TooltipContent"),Uf=u.forwardRef((e,n)=>{const{__scopeTooltip:t,children:r,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:i,...c}=e,d=er(Rt,t),p=Jn(t),{onClose:f}=d;return u.useEffect(()=>(document.addEventListener(ao,f),()=>document.removeEventListener(ao,f)),[f]),u.useEffect(()=>{if(d.trigger){const m=v=>{const g=v.target;g!=null&&g.contains(d.trigger)&&f()};return window.addEventListener("scroll",m,{capture:!0}),()=>window.removeEventListener("scroll",m,{capture:!0})}},[d.trigger,f]),s.jsx(l.DismissableLayer,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:m=>m.preventDefault(),onDismiss:f,children:s.jsxs(l.Content,{"data-state":d.stateAttribute,...p,...c,ref:n,style:{...c.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[s.jsx(SE,{children:r}),s.jsx(NE,{scope:t,isInside:!0,children:s.jsx(l.Root,{id:d.contentId,role:"tooltip",children:o||r})})]})})});Kf.displayName=Rt;var Xf="TooltipArrow",jE=u.forwardRef((e,n)=>{const{__scopeTooltip:t,...r}=e,o=Jn(t);return ME(Xf,t).isInside?null:s.jsx(l.Arrow,{...o,...r,ref:n})});jE.displayName=Xf;function IE(e,n){const t=Math.abs(n.top-e.y),r=Math.abs(n.bottom-e.y),o=Math.abs(n.right-e.x),a=Math.abs(n.left-e.x);switch(Math.min(t,r,o,a)){case a:return"left";case o:return"right";case t:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function AE(e,n,t=5){const r=[];switch(n){case"top":r.push({x:e.x-t,y:e.y+t},{x:e.x+t,y:e.y+t});break;case"bottom":r.push({x:e.x-t,y:e.y-t},{x:e.x+t,y:e.y-t});break;case"left":r.push({x:e.x+t,y:e.y-t},{x:e.x+t,y:e.y+t});break;case"right":r.push({x:e.x-t,y:e.y-t},{x:e.x-t,y:e.y+t});break}return r}function OE(e){const{top:n,right:t,bottom:r,left:o}=e;return[{x:o,y:n},{x:t,y:n},{x:t,y:r},{x:o,y:r}]}function FE(e,n){const{x:t,y:r}=e;let o=!1;for(let a=0,i=n.length-1;a<n.length;i=a++){const c=n[a],d=n[i],p=c.x,f=c.y,m=d.x,v=d.y;f>r!=v>r&&t<(m-p)*(r-f)/(v-f)+p&&(o=!o)}return o}function LE(e){const n=e.slice();return n.sort((t,r)=>t.x<r.x?-1:t.x>r.x?1:t.y<r.y?-1:t.y>r.y?1:0),$E(n)}function $E(e){if(e.length<=1)return e.slice();const n=[];for(let r=0;r<e.length;r++){const o=e[r];for(;n.length>=2;){const a=n[n.length-1],i=n[n.length-2];if((a.x-i.x)*(o.y-i.y)>=(a.y-i.y)*(o.x-i.x))n.pop();else break}n.push(o)}n.pop();const t=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;t.length>=2;){const a=t[t.length-1],i=t[t.length-2];if((a.x-i.x)*(o.y-i.y)>=(a.y-i.y)*(o.x-i.x))t.pop();else break}t.push(o)}return t.pop(),n.length===1&&t.length===1&&n[0].x===t[0].x&&n[0].y===t[0].y?n:n.concat(t)}var HE=Gf,WE=qf,zE=Bf,Qf=Kf;const Ti={primary:"bg-main-600 text-white",secondary:"bg-grey-800 text-white",white:"bg-grey-50 text-grey-800"},YE={sm:"p-2 text-[13px] rounded",md:"p-2 text-sm font-normal rounded"},VE=HE,GE=WE,qE=zE,BE=(e,n)=>{const t=n==="primary"?xt.colors.main[600]:n==="secondary"?xt.colors.grey[800]:xt.colors.grey[50],r=n==="white"?xt.colors.grey[200]:t;return{...{width:"12px",height:"12px",backgroundColor:t,border:"1px solid",borderColor:r,opacity:n==="white"?1:.9,transform:"rotate(45deg)",borderRadius:"2px",zIndex:20},...{"top-left":{left:"1.5rem",top:"100%",transform:"translateX(-50%) translateY(-60%) rotate(45deg)"},"top-center":{left:"50%",top:"100%",transform:"translateX(-50%) translateY(-60%) rotate(45deg)"},"top-right":{right:"1.5rem",top:"100%",transform:"translateX(50%) translateY(-60%) rotate(45deg)"},"bottom-left":{left:"1.5rem",bottom:"100%",transform:"translateX(-50%) translateY(60%) rotate(45deg)"},"bottom-center":{left:"50%",bottom:"100%",transform:"translateX(-50%) translateY(60%) rotate(45deg)"},"bottom-right":{right:"1.5rem",bottom:"100%",transform:"translateX(50%) translateY(60%) rotate(45deg)"},right:{right:"100%",top:"50%",transform:"translateX(60%) translateY(-50%) rotate(45deg)"},left:{left:"100%",top:"50%",transform:"translateX(-60%) translateY(-50%) rotate(45deg)"}}[e]}},Zf=u.forwardRef(({className:e,variant:n="primary",size:t="pc",position:r="top-center",sideOffset:o=8,icLeft:a,icRight:i,children:c,bubbleTip:d=!0,...p},f)=>{const m=BE(r,n),v=r.startsWith("top"),g=r==="right"||r==="left"?r:v?"top":"bottom",h=r==="right"||r==="left"?"center":r.includes("left")?"start":r.includes("right")?"end":"center";return s.jsx(Qf,{ref:f,avoidCollisions:!1,sideOffset:d?o:4,side:g,align:h,style:{zIndex:50},...p,children:s.jsxs("div",{className:l.cn("relative z-50 rounded",d&&"m-1",n==="white"&&"border border-border",Ti[n],e),children:[d&&s.jsx("div",{style:m,className:"absolute z-20"}),s.jsx("div",{className:"absolute inset-0 z-30 rounded bg-white"}),s.jsxs("div",{className:l.cn("relative z-40 flex max-w-sm items-center font-normal",n!=="white"&&"bg-opacity-90",Ti[n],YE[t]),children:[a&&s.jsx("span",{className:"mr-1",children:a}),s.jsx("span",{className:"whitespace-pre-wrap break-keep",children:c}),i&&s.jsx("span",{className:"ml-1",children:i})]})]})})});Zf.displayName=Qf.displayName;exports.Accordion=Tm;exports.AlertDialog=Qm;exports.AlertDialogAction=zs;exports.AlertDialogCancel=Ys;exports.AlertDialogContent=Fs;exports.AlertDialogDescription=Ws;exports.AlertDialogFooter=$s;exports.AlertDialogHeader=Ls;exports.AlertDialogOverlay=Co;exports.AlertDialogPortal=Os;exports.AlertDialogTitle=Hs;exports.AlertDialogTrigger=Zm;exports.ArrowDownIcon=Uw;exports.ArrowUpIcon=Qw;exports.Avatar=ec;exports.AvatarFallback=nc;exports.AvatarImage=tc;exports.Badge=oc;exports.Box=Lt;exports.Button=As;exports.Calendar=Gc;exports.CalendarIcon=Jw;exports.Callout=jt;exports.Card=qc;exports.CardContent=Xc;exports.CardDescription=Uc;exports.CardFooter=Qc;exports.CardHeader=Bc;exports.CardTitle=Kc;exports.CaretSortIcon=t1;exports.Checkbox=ol;exports.ChevronLeftIcon=r1;exports.ChevronRightIcon=Pd;exports.Circle=xc;exports.Command=In;exports.CommandDialog=Ry;exports.CommandEmpty=Jo;exports.CommandGroup=yl;exports.CommandInput=bl;exports.CommandItem=ea;exports.CommandList=Zo;exports.CommandSeparator=wl;exports.CommandShortcut=Cl;exports.Cross2Icon=i1;exports.Dialog=fl;exports.DialogClose=Py;exports.DialogContent=Qo;exports.DialogDescription=xl;exports.DialogFooter=gl;exports.DialogHeader=vl;exports.DialogOverlay=Xo;exports.DialogPortal=ml;exports.DialogTitle=hl;exports.DialogTrigger=_y;exports.DoubleArrowLeftIcon=c1;exports.DoubleArrowRightIcon=d1;exports.DropdownMenu=u1;exports.DropdownMenuCheckboxItem=Nd;exports.DropdownMenuContent=Td;exports.DropdownMenuGroup=f1;exports.DropdownMenuItem=Dd;exports.DropdownMenuLabel=Sd;exports.DropdownMenuPortal=m1;exports.DropdownMenuRadioGroup=g1;exports.DropdownMenuRadioItem=Md;exports.DropdownMenuSeparator=jd;exports.DropdownMenuShortcut=Id;exports.DropdownMenuSub=v1;exports.DropdownMenuSubContent=kd;exports.DropdownMenuSubTrigger=Rd;exports.DropdownMenuTrigger=p1;exports.FileInput=Jd;exports.FileUploader=Xd;exports.FileUploaderContent=Qd;exports.FileUploaderItem=Zd;exports.FlexBox=ua;exports.Form=V0;exports.FormControl=hu;exports.FormDescription=bn;exports.FormField=G0;exports.FormItem=vu;exports.FormLabel=gu;exports.FormMessage=xu;exports.Input=Ad;exports.Label=fa;exports.MonthPicker=K0;exports.MultiSelector=U0;exports.MultiSelectorContent=Cu;exports.MultiSelectorInput=wu;exports.MultiSelectorItem=_u;exports.MultiSelectorList=Eu;exports.MultiSelectorTrigger=yu;exports.NavigationMenu=Uu;exports.NavigationMenuContent=Ju;exports.NavigationMenuIndicator=ep;exports.NavigationMenuItem=fC;exports.NavigationMenuLink=mC;exports.NavigationMenuList=Xu;exports.NavigationMenuTrigger=Zu;exports.NavigationMenuViewport=ya;exports.Popover=TC;exports.PopoverContent=pp;exports.PopoverTrigger=DC;exports.RadioGroup=kp;exports.RadioGroupItem=Tp;exports.ScrollArea=To;exports.ScrollBar=Do;exports.Separator=Mp;exports.Switch=Lp;exports.Tabs=QC;exports.TabsContent=ef;exports.TabsList=Zp;exports.TabsTrigger=Jp;exports.Tag=lu;exports.Text=kt;exports.Textarea=tf;exports.Toast=yf;exports.ToastAction=wf;exports.ToastClose=Cf;exports.ToastDescription=_f;exports.ToastModal=Rf;exports.ToastModalAction=kf;exports.ToastModalClose=Tf;exports.ToastModalContents=bE;exports.ToastModalDescription=Nf;exports.ToastModalProvider=gE;exports.ToastModalTitle=Df;exports.ToastModalViewport=Pf;exports.ToastProvider=vE;exports.ToastTitle=Ef;exports.ToastViewport=xf;exports.Toggle=jf;exports.ToggleGroup=zf;exports.ToggleGroupItem=Yf;exports.Tooltip=GE;exports.TooltipContent=Zf;exports.TooltipProvider=VE;exports.TooltipTrigger=qE;exports.badgeVariants=rc;exports.buttonVariants=Me;exports.commonjsGlobal=ev;exports.constructFrom=ie;exports.differenceInCalendarDays=Ae;exports.format=_e;exports.getDefaultExportFromCjs=Vs;exports.isSameMonth=Nn;exports.ko=Ic;exports.millisecondsInHour=yc;exports.millisecondsInMinute=bc;exports.navigationMenuTriggerStyle=Qu;exports.normalizeDates=Je;exports.tagVariants=cu;exports.toDate=ee;exports.toastPositionVariants=hf;exports.toastVariants=bf;exports.toggleVariants=Ta;exports.useController=au;exports.useFileUpload=$n;exports.useFormContext=Kt;exports.useFormField=Ut;
|
|
@@ -11358,7 +11358,7 @@ var I0 = "Label", Bd = d.forwardRef((e, n) => /* @__PURE__ */ c(
|
|
|
11358
11358
|
));
|
|
11359
11359
|
Bd.displayName = I0;
|
|
11360
11360
|
var Gd = Bd;
|
|
11361
|
-
const F0 = dt("text-sm font-normal
|
|
11361
|
+
const F0 = dt("text-sm font-normal peer-disabled:cursor-not-allowed peer-disabled:opacity-70"), Kd = d.forwardRef(({ className: e, ...n }, t) => /* @__PURE__ */ c(Gd, { ref: t, className: k(F0(), e), ...n }));
|
|
11362
11362
|
Kd.displayName = Gd.displayName;
|
|
11363
11363
|
const L0 = dt("inline-flex items-center justify-center whitespace-nowrap gap-1", {
|
|
11364
11364
|
variants: {
|
|
@@ -11449,7 +11449,7 @@ const XE = T0, Zd = d.createContext({}), QE = ({
|
|
|
11449
11449
|
}, Jd = d.createContext({}), j0 = d.forwardRef(
|
|
11450
11450
|
({ className: e, ...n }, t) => {
|
|
11451
11451
|
const r = d.useId();
|
|
11452
|
-
return /* @__PURE__ */ c(Jd.Provider, { value: { id: r }, children: /* @__PURE__ */ c("div", { ref: t, className: k("relative flex flex-col gap-2", e), ...n }) });
|
|
11452
|
+
return /* @__PURE__ */ c(Jd.Provider, { value: { id: r }, children: /* @__PURE__ */ c("div", { ref: t, className: k("relative flex flex-col gap-2 md:gap-4", e), ...n }) });
|
|
11453
11453
|
}
|
|
11454
11454
|
);
|
|
11455
11455
|
j0.displayName = "FormItem";
|
|
@@ -11459,7 +11459,12 @@ const W0 = d.forwardRef(({ className: e, required: n, heading: t, label: r, desc
|
|
|
11459
11459
|
Kd,
|
|
11460
11460
|
{
|
|
11461
11461
|
ref: s,
|
|
11462
|
-
className: k(
|
|
11462
|
+
className: k(
|
|
11463
|
+
"relative",
|
|
11464
|
+
l && "text-red-400",
|
|
11465
|
+
"space-y-1 text-sm font-semibold text-grey-800 xs:text-base",
|
|
11466
|
+
e
|
|
11467
|
+
),
|
|
11463
11468
|
htmlFor: u,
|
|
11464
11469
|
...i,
|
|
11465
11470
|
children: [
|
|
@@ -11497,7 +11502,7 @@ const ka = d.forwardRef(
|
|
|
11497
11502
|
{
|
|
11498
11503
|
ref: t,
|
|
11499
11504
|
id: r,
|
|
11500
|
-
className: k("whitespace-pre-wrap text-
|
|
11505
|
+
className: k("whitespace-pre-wrap text-xs font-normal text-grey-600 xs:text-sm", e),
|
|
11501
11506
|
...n
|
|
11502
11507
|
}
|
|
11503
11508
|
);
|
package/dist/provider.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),f=require("./use-toastmodal-uEmmo-7h.cjs"),t=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),f=require("./use-toastmodal-uEmmo-7h.cjs"),t=require("./index-CAXvbMVF.cjs"),g=require("./index-Cjpdd7RE.cjs"),m=require("./toast-form-DlQ2uN7i.cjs"),d=require("react");require("./index-z9hRvvSX.cjs");const P=require("react-dom");function E(){const{modals:n,dismiss:r}=f.useToastModal(),a=n.some(e=>e.open);return s.jsxs(t.ToastModalProvider,{children:[n.map(function({id:e,title:o,description:l,content:i,onConfirm:u,confirmText:c="확인",onCancel:F,cancelText:M="취소",size:p,contents:j,variant:C,width:T,closeType:x,...h}){return s.jsxs(t.ToastModal,{width:T,...h,className:"flex flex-col gap-4",children:[s.jsx(t.ToastModalTitle,{children:o}),s.jsxs("div",{className:"flex flex-col gap-2",children:[l&&s.jsx(t.ToastModalDescription,{className:"text-sm text-foreground",children:l}),i&&s.jsx(t.ToastModalDescription,{children:i})]}),j&&s.jsx(t.ToastModalContents,{children:j}),s.jsxs("div",{className:g.cn("flex items-center justify-between gap-2",x&&"justify-end"),children:[!x&&s.jsx(t.ToastModalClose,{className:"w-1/2",size:p,variant:"outline",children:M}),s.jsx(t.ToastModalAction,{className:x?"":"w-1/2",altText:"confirm",size:p,variant:C,onClick:u,children:c})]})]},e)}),s.jsx(t.ToastModalViewport,{isOpen:a?"open":"close",onClick:()=>n.forEach(e=>!e.closeType&&r(e.id))})]})}const v=()=>{const[n,r]=d.useState([]);d.useEffect(()=>{const e=f.portalManager.subscribe((o,l)=>{r(i=>{const u=i.find(c=>c.id===o.id);return l?u?i:[...i,{...o,isOpen:l}]:i.map(c=>c.id===o.id?{...c,isOpen:!1}:c)})});return()=>{e()}},[]);const a=d.useCallback(e=>{f.portalManager.setPortalOpen(e,!1)},[]);return d.useEffect(()=>{const e=[];return n.forEach(o=>{if(!o.isOpen){const l=setTimeout(()=>{r(i=>i.filter(u=>u.id!==o.id))},300);e.push(l)}}),()=>{e.forEach(o=>clearTimeout(o))}},[n]),s.jsx(b,{children:n.map(e=>{var o;if(!e.isOpen)return null;switch(e.type){case"modal":return s.jsx(m.ModalForm,{...e.props,onClose:()=>{e.props.onClose&&e.props.onClose(),a(e.id)},description:(o=e.props.description)==null?void 0:o.toString()},e.id);case"alert":return s.jsx(m.AlertForm,{...e.props,onClose:()=>{e.props.onClose&&e.props.onClose(),a(e.id)}},e.id);case"dialog":return s.jsx(m.DialogForm,{...e.props,onClose:()=>{e.props.onClose&&e.props.onClose(),a(e.id)}},e.id);case"custom":return s.jsx(m.FreeForm,{...e.props,onClose:()=>{e.props.onClose&&e.props.onClose(),a(e.id)},contents:e.props.contents},e.id);default:return null}})})},b=({children:n})=>{const[r,a]=d.useState(null);return d.useEffect(()=>{let e=document.getElementById("portal");e||(e=document.createElement("div"),e.id="portal",document.body.appendChild(e)),a(e)},[]),r?P.createPortal(n,r):null};function q(){const{toasts:n}=f.useToast();return s.jsxs(t.ToastProvider,{children:[n.map(function(r){return s.jsx(m.ToastForm,{...r})}),s.jsx(t.ToastViewport,{})]})}exports.ModalManager=E;exports.PortalProvider=v;exports.ToastManager=q;
|
package/dist/provider.es.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as d, jsx as s } from "react/jsx-runtime";
|
|
2
2
|
import { c as E, p as C, u as b } from "./use-toastmodal-D-3bh38k.js";
|
|
3
|
-
import { T as v, a as F, b as w, c as h, d as N, e as O, f as D, g as j, h as y, i as k } from "./index-
|
|
3
|
+
import { T as v, a as F, b as w, c as h, d as N, e as O, f as D, g as j, h as y, i as k } from "./index-DZmnb6ih.js";
|
|
4
4
|
import { c as A } from "./index-BcQaeGBJ.js";
|
|
5
|
-
import { F as S, D as V, A as _, M as B, T as I } from "./toast-form-
|
|
5
|
+
import { F as S, D as V, A as _, M as B, T as I } from "./toast-form-Ck6Wlh-K.js";
|
|
6
6
|
import { useState as T, useEffect as m, useCallback as R } from "react";
|
|
7
7
|
import "./index-CEwEyzHV.js";
|
|
8
8
|
import q from "react-dom";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs as r, jsx as e, Fragment as x } from "react/jsx-runtime";
|
|
2
|
-
import { A as b, j as A, k as C, l as T, m as v, n as u, o as F, p as k, q as y, D as j, r as z, s as B, t as I, u as M, v as V, w as _, x as q, F as E, y as D, z as G, B as N, C as J, E as K, G as L, H as P } from "./index-
|
|
2
|
+
import { A as b, j as A, k as C, l as T, m as v, n as u, o as F, p as k, q as y, D as j, r as z, s as B, t as I, u as M, v as V, w as _, x as q, F as E, y as D, z as G, B as N, C as J, E as K, G as L, H as P } from "./index-DZmnb6ih.js";
|
|
3
3
|
import { c as g, I as w } from "./index-BcQaeGBJ.js";
|
|
4
4
|
import * as Q from "react";
|
|
5
5
|
import S, { forwardRef as U } from "react";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("react/jsx-runtime"),t=require("./index-
|
|
1
|
+
"use strict";const e=require("react/jsx-runtime"),t=require("./index-CAXvbMVF.cjs"),g=require("./index-Cjpdd7RE.cjs"),h=require("react");require("./index-z9hRvvSX.cjs");const y=require("./index-DKCqkplO.cjs");function b(i){const l=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(i){for(const r in i)if(r!=="default"){const s=Object.getOwnPropertyDescriptor(i,r);Object.defineProperty(l,r,s.get?s:{enumerable:!0,get:()=>i[r]})}}return l.default=i,Object.freeze(l)}const A=b(h),w=({title:i="알림",description:l,confirmText:r="확인",onConfirm:s,size:a="sm",onClose:o,theme:n="primary",children:c})=>e.jsxs(t.AlertDialog,{open:c?void 0:!0,onOpenChange:x=>{!x&&o&&o()},children:[c&&e.jsx(t.AlertDialogTrigger,{asChild:!0,children:c}),e.jsxs(t.AlertDialogContent,{size:a,className:"gap-4",children:[e.jsxs(t.AlertDialogHeader,{children:[e.jsx(t.AlertDialogTitle,{children:i}),e.jsx(t.AlertDialogDescription,{className:"text-sm",children:l})]}),e.jsx(t.AlertDialogFooter,{children:e.jsx(t.AlertDialogAction,{className:g.cn(t.buttonVariants({theme:n,size:"sm"}),"w-full font-normal"),onClick:()=>{s&&s()},children:r})})]})]}),N=h.forwardRef(({id:i,title:l,description:r,onClose:s,content:a,className:o,open:n,onOpenChange:c,footer:x,children:d,...j},u)=>e.jsxs(t.Dialog,{open:d?void 0:!0,onOpenChange:m=>{!m&&s&&s()},children:[d&&e.jsx(t.DialogTrigger,{asChild:!0,children:d}),e.jsxs(t.DialogContent,{ref:u,className:g.cn("flex flex-col gap-0 px-0 py-0",o),...j,children:[e.jsxs(t.DialogHeader,{className:"sticky left-0 right-0 top-0 z-50 border-b border-b-border bg-white",children:[e.jsx(t.DialogTitle,{className:"flex w-full items-center justify-start whitespace-pre-wrap p-3 md:justify-center md:p-4",children:l}),e.jsxs(t.DialogClose,{className:"absolute right-2 top-3 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground md:right-3 md:top-4",children:[e.jsx(g.Icon.Cancel,{size:"16"}),e.jsx("span",{className:"sr-only",children:"Close"})]})]}),r&&e.jsx(t.DialogDescription,{children:r}),a&&e.jsx(e.Fragment,{children:a}),x&&e.jsx(t.DialogFooter,{children:x})]})]})),F=h.forwardRef(({open:i,onClose:l,className:r,contents:s,children:a,...o},n)=>e.jsxs(t.Dialog,{open:a?void 0:!0,onOpenChange:c=>{!c&&l&&l()},children:[a&&e.jsx(t.DialogTrigger,{asChild:!0,children:a}),e.jsx(t.DialogContent,{ref:n,className:g.cn("flex flex-col gap-0 px-0 py-0",r),...o,children:s&&e.jsx(e.Fragment,{children:s})})]})),C=A.forwardRef(({title:i,description:l,subDescription:r,contents:s,onConfirm:a,confirmText:o="확인",onCancel:n,cancelText:c="취소",size:x="sm",className:d,onClose:j,theme:u="primary",children:m,...p},f)=>e.jsxs(t.AlertDialog,{open:m?void 0:!0,onOpenChange:D=>{!D&&j&&j()},children:[m&&e.jsx(t.AlertDialogTrigger,{asChild:!0,children:m}),e.jsxs(t.AlertDialogContent,{size:x,className:d,...p,ref:f,children:[e.jsxs(t.AlertDialogHeader,{children:[e.jsxs(t.FlexBox.Row,{className:"items-start justify-between gap-2",children:[e.jsx(t.AlertDialogTitle,{children:i}),e.jsx(t.AlertDialogCancel,{className:"mt-0 h-auto w-auto border-none p-0",children:e.jsx(g.Icon.Cancel,{size:"14",fill:y.colors.grey[600]})})]}),l&&e.jsx(t.AlertDialogDescription,{className:"text-start text-sm text-grey-800",children:l}),r&&e.jsx(t.AlertDialogDescription,{className:"text-start text-xs text-grey-600",children:r})]}),s&&e.jsx(e.Fragment,{children:s}),e.jsxs(t.AlertDialogFooter,{className:"",children:[e.jsx(t.AlertDialogCancel,{onClick:()=>{n&&n()},className:"w-full md:w-1/2",children:c}),e.jsx(t.AlertDialogAction,{className:g.cn(t.buttonVariants({theme:u,size:"sm"}),"w-full md:w-1/2"),onClick:()=>{a&&a()},children:o})]})]})]}));function T(i){const{id:l,variant:r,title:s,closeButton:a,onAction:o,actionBtnText:n,description:c}=i,x=o&&n,d=r==="black"?"solid":"outline";return e.jsx(t.Toast,{variant:r,...i,children:e.jsxs(t.Box,{className:g.cn("relative flex w-full items-center justify-between gap-2 whitespace-pre-wrap p-4",{"items-end":s,"pr-7":a,"justify-center":!x}),children:[e.jsxs(t.Box,{className:"flex flex-col gap-1",children:[s&&s.trim().length>0&&e.jsx(t.ToastTitle,{children:s}),e.jsx(t.ToastDescription,{children:c})]}),x&&e.jsx(t.ToastAction,{altText:l||"toast action",onClick:o,className:g.cn(t.buttonVariants({variant:d,size:"sm",theme:"secondary"}),{"border-grey-800 bg-grey-800 text-grey-50":r==="black","border-grey-50 bg-grey-50 text-grey-800":r==="white"},"px-2 py-1 text-xs"),children:n}),a&&e.jsx(t.ToastClose,{children:e.jsx(g.Icon.Cancel,{size:"10",className:g.cn({"fill-grey-600 hover:fill-grey-800":r==="white","fill-grey-100 hover:fill-white":r==="black"})})})]})},l)}exports.AlertForm=w;exports.DialogForm=N;exports.FreeForm=F;exports.ModalForm=C;exports.ToastForm=T;
|
package/dist/ui.cjs.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-CAXvbMVF.cjs"),O=require("./index-CSwq9AvE.cjs"),d1=require("react"),l=require("./index-Cjpdd7RE.cjs"),r=require("react/jsx-runtime");require("./index-z9hRvvSX.cjs");const U=require("./index-DKCqkplO.cjs");function c1(t){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(o,n,i.get?i:{enumerable:!0,get:()=>t[n]})}}return o.default=t,Object.freeze(o)}const p=c1(d1);var u1="AspectRatio",$=p.forwardRef((t,o)=>{const{ratio:n=1/1,style:i,...s}=t;return r.jsx("div",{style:{position:"relative",width:"100%",paddingBottom:`${100/n}%`},"data-radix-aspect-ratio-wrapper":"",children:r.jsx(l.Primitive.div,{...s,ref:o,style:{...i,position:"absolute",top:0,right:0,bottom:0,left:0}})})});$.displayName=u1;var C1=$;const g1=C1;/**
|
|
2
2
|
* @license lucide-react v0.516.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
package/dist/ui.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { I as C1, B as p1 } from "./index-
|
|
2
|
-
import { J as ve, A as we, p as be, y as Se, k as Me, n as xe, o as Re, l as Ve, K as De, L as He, m as ye, j as Te, M as Ae, N as Pe, O as Le, P as Be, R as Fe, S as Ne, U as Ie, V as Ee, W as Ze, X as _e, Y as ke, Z as Ke, _ as Ge, $ as $e, a0 as Oe, a1 as Ue, a2 as ze, a3 as Ye, a4 as je, a5 as Xe, a6 as We, a7 as qe, a8 as Je, D as Qe, v as e2, s as t2, w as o2, x as a2, t as n2, a9 as r2, aa as i2, u as s2, r as l2, ab as d2, ac as c2, ad as u2, ae as C2, af as p2, ag as g2, ah as f2, ai as h2, aj as m2, ak as v2, al as w2, am as b2, an as S2, ao as M2, ap as x2, au as R2, ar as V2, as as D2, at as H2, F as y2, av as T2, aw as A2, ax as P2, ay as L2, az as B2, aA as F2, aB as N2, aD as I2, aE as E2, aF as Z2, aG as _2, aH as k2, aI as K2, aJ as G2, aK as $2, aL as O2, aM as U2, aN as z2, aO as Y2, aP as j2, aQ as X2, aR as W2, aS as q2, aU as J2, aV as Q2, aW as et, aX as tt, aY as ot, aZ as at, a_ as nt, a$ as rt, b0 as it, b1 as st, b2 as lt, b3 as dt, b4 as ct, b5 as ut, b6 as Ct, b8 as pt, b9 as gt, z as ft, G as ht, H as mt, E as vt, a as wt, f as bt, e as St, d as Mt, c as xt, T as Rt, b as Vt, g as Dt, h as Ht, C as yt, i as Tt, bc as At, be as Pt, bf as Lt, bg as Bt, bh as Ft, bi as Nt, bj as It, Q as Et, q as Zt, aT as _t, b7 as kt, ba as Kt, bb as Gt, bd as $t, aq as Ot, aC as Ut } from "./index-
|
|
1
|
+
import { I as C1, B as p1 } from "./index-DZmnb6ih.js";
|
|
2
|
+
import { J as ve, A as we, p as be, y as Se, k as Me, n as xe, o as Re, l as Ve, K as De, L as He, m as ye, j as Te, M as Ae, N as Pe, O as Le, P as Be, R as Fe, S as Ne, U as Ie, V as Ee, W as Ze, X as _e, Y as ke, Z as Ke, _ as Ge, $ as $e, a0 as Oe, a1 as Ue, a2 as ze, a3 as Ye, a4 as je, a5 as Xe, a6 as We, a7 as qe, a8 as Je, D as Qe, v as e2, s as t2, w as o2, x as a2, t as n2, a9 as r2, aa as i2, u as s2, r as l2, ab as d2, ac as c2, ad as u2, ae as C2, af as p2, ag as g2, ah as f2, ai as h2, aj as m2, ak as v2, al as w2, am as b2, an as S2, ao as M2, ap as x2, au as R2, ar as V2, as as D2, at as H2, F as y2, av as T2, aw as A2, ax as P2, ay as L2, az as B2, aA as F2, aB as N2, aD as I2, aE as E2, aF as Z2, aG as _2, aH as k2, aI as K2, aJ as G2, aK as $2, aL as O2, aM as U2, aN as z2, aO as Y2, aP as j2, aQ as X2, aR as W2, aS as q2, aU as J2, aV as Q2, aW as et, aX as tt, aY as ot, aZ as at, a_ as nt, a$ as rt, b0 as it, b1 as st, b2 as lt, b3 as dt, b4 as ct, b5 as ut, b6 as Ct, b8 as pt, b9 as gt, z as ft, G as ht, H as mt, E as vt, a as wt, f as bt, e as St, d as Mt, c as xt, T as Rt, b as Vt, g as Dt, h as Ht, C as yt, i as Tt, bc as At, be as Pt, bf as Lt, bg as Bt, bh as Ft, bi as Nt, bj as It, Q as Et, q as Zt, aT as _t, b7 as kt, ba as Kt, bb as Gt, bd as $t, aq as Ot, aC as Ut } from "./index-DZmnb6ih.js";
|
|
3
3
|
import { A as Yt, S as jt } from "./index-DecP4413.js";
|
|
4
4
|
import * as C from "react";
|
|
5
5
|
import { P, b as g1, c as D, u as f1, d as h1, e as m1, f as A, g as L, h as v1, i as Y, j as w1, k as b1 } from "./index-BcQaeGBJ.js";
|