@6thbridge/hexa 0.0.106 → 0.0.107-pr92-204
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/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +16 -16
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";"use client";var Us=Object.create;var Yt=Object.defineProperty;var Zs=Object.getOwnPropertyDescriptor;var Ks=Object.getOwnPropertyNames;var js=Object.getPrototypeOf,Ys=Object.prototype.hasOwnProperty;var Xs=(e,t,r)=>t in e?Yt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var qs=(e,t)=>{for(var r in t)Yt(e,r,{get:t[r],enumerable:!0})},wn=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Ks(t))!Ys.call(e,n)&&n!==r&&Yt(e,n,{get:()=>t[n],enumerable:!(o=Zs(t,n))||o.enumerable});return e};var T=(e,t,r)=>(r=e!=null?Us(js(e)):{},wn(t||!e||!e.__esModule?Yt(r,"default",{value:e,enumerable:!0}):r,e)),Js=e=>wn(Yt({},"__esModule",{value:!0}),e);var Fr=(e,t,r)=>Xs(e,typeof t!="symbol"?t+"":t,r);var lc={};qs(lc,{Accordion:()=>va,AmountAction:()=>xo,Banner:()=>ba,Button:()=>ce,CalendarInput:()=>io,CopyableLabel:()=>xa,Country:()=>ua,CurrencySymbolMap:()=>Co,DateAction:()=>No,DebouncedInput:()=>Zr,DevBanner:()=>Pa,Dialog:()=>Br,Drawer:()=>ei,DrawerClose:()=>Ka,DrawerRoot:()=>Xr,FeatureBanner:()=>cs,FilterPopover:()=>po,FlagComponent:()=>tt,FormLabel:()=>Y,HasResourcePermission:()=>os,Input:()=>de,Loader:()=>Ve,LocaleSelector:()=>ii,MultiSelect:()=>_r,MultiSelectTrigger:()=>$r,OTPInput:()=>ga,PageDataToolbar:()=>mo,Pagination:()=>no,PasswordInput:()=>Ao,PermissionsContext:()=>wr,PermissionsProvider:()=>bi,PhoneInput:()=>Ho,Popover:()=>Me,PopoverContent:()=>ge,PopoverRoot:()=>Ne,PopoverTrigger:()=>ee,RadioGroup:()=>Rr,RadioGroupItem:()=>Pr,RichTextEditor:()=>Ds,ScrollArea:()=>Ie,Select:()=>it,Sidebar:()=>Ri,SplitButton:()=>ko,Status:()=>Pi,StringAction:()=>Ar,Table:()=>rs,Tabs:()=>ns,TagsInput:()=>Ts,TextOverflow:()=>Lt,Textarea:()=>Mo,Tooltip:()=>qt,TooltipContent:()=>Mr,TooltipProvider:()=>Ro,TooltipRoot:()=>Po,TooltipTrigger:()=>Do,buttonVariants:()=>me,cn:()=>s,useFilterStore:()=>co,useHasPermission:()=>$t,usePermissions:()=>Jo});module.exports=Js(lc);var Co={USD:"$",CAD:"CA$",EUR:"\u20AC",AED:"AED",AFN:"Af",ALL:"ALL",AMD:"AMD",ARS:"AR$",AUD:"AU$",AZN:"man.",BAM:"KM",BDT:"Tk",BGN:"BGN",BHD:"BD",BIF:"FBu",BND:"BN$",BOB:"Bs",BRL:"R$",BWP:"BWP",BYN:"Br",BZD:"BZ$",CDF:"CDF",CHF:"CHF",CLP:"CL$",CNY:"CN\xA5",COP:"CO$",CRC:"\u20A1",CVE:"CV$",CZK:"K\u010D",DJF:"Fdj",DKK:"Dkr",DOP:"RD$",DZD:"DA",EEK:"Ekr",EGP:"EGP",ERN:"Nfk",ETB:"Br",GBP:"\xA3",GEL:"GEL",GHS:"GH\u20B5",GNF:"FG",GTQ:"GTQ",HKD:"HK$",HNL:"HNL",HRK:"kn",HUF:"Ft",IDR:"Rp",ILS:"\u20AA",INR:"\u20B9",IQD:"IQD",IRR:"IRR",ISK:"Ikr",JMD:"J$",JOD:"JD",JPY:"\xA5",KES:"Ksh",KHR:"KHR",KMF:"CF",KRW:"\u20A9",KWD:"KD",KZT:"KZT",LBP:"L.L.",LKR:"SLRs",LTL:"Lt",LVL:"Ls",LYD:"LD",MAD:"MAD",MDL:"MDL",MGA:"MGA",MKD:"MKD",MMK:"MMK",MOP:"MOP$",MUR:"MURs",MXN:"MX$",MYR:"RM",MZN:"MTn",NAD:"N$",NGN:"\u20A6",NIO:"C$",NOK:"Nkr",NPR:"NPRs",NZD:"NZ$",OMR:"OMR",PAB:"B/.",PEN:"S/.",PHP:"\u20B1",PKR:"PKRs",PLN:"z\u0142",PYG:"\u20B2",QAR:"QR",RON:"RON",RSD:"din.",RUB:"RUB",RWF:"RWF",SAR:"SR",SDG:"SDG",SEK:"Skr",SGD:"S$",SOS:"Ssh",SYP:"SY\xA3",THB:"\u0E3F",TND:"DT",TOP:"T$",TRY:"TL",TTD:"TT$",TWD:"NT$",TZS:"TSh",UAH:"\u20B4",UGX:"USh",UYU:"$U",UZS:"UZS",VEF:"Bs.F.",VND:"\u20AB",XAF:"F CFA",XOF:"CFA",YER:"YR",ZAR:"R",ZMK:"ZK",ZWL:"ZWL$"},Xt=class Xt{static getCurrencyLocaleMap(t){return{XOF:"fr",XAF:"fr"}[t]||"en"}static koboToNaira(t){return+t/100}static nairaToKobo(t){return+t*100}static getCurrencySymbol(t){return Co[t]||t}};Fr(Xt,"formatAmountAndCurrency",(t,r,o)=>{let n=new Intl.NumberFormat(o?.locale||Xt.getCurrencyLocaleMap(t),{maximumFractionDigits:3,style:"currency",currency:t,currencyDisplay:"symbol"}).format(o?.convertToMajorCurrency?Xt.koboToNaira(Number(r)):Number(r)).replace(/^(\D+)/,"$1 ").replace("\u202F"," ").replace(/\s+/,""),a=Co[t]||t;return n.replace(t,a)});var xo=Xt;var Er=T(require("dayjs")),No=class{static getDateLibrary(){return(0,Er.default)()}static formatTimestampToDate(t,r){return Er.default.unix(t).format(r||"ddd, MMM, YYYY | HH:mm:ss")}static formatDateToTimestamp(t){return(0,Er.default)(t).unix()}};var Ar=class{static capitalizeFirstWord(t){return t.charAt(0).toUpperCase()+t.slice(1)}static capitalizeEachWord(t){return t.split(" ").map(r=>r.charAt(0).toUpperCase()+r.slice(1)).join(" ")}};Fr(Ar,"sanitizeString",({str:t,allowedChars:r})=>{if(!r)return t.replace(/[^a-zA-Z0-9\s]/g,"");let o=r.map(a=>["^","$",".","*","+","?","(",")","[","]","{","}","|","\\","-"].includes(a)?"\\"+a:a),n=new RegExp(`[^a-zA-Z0-9${o.join("")}]`,"g");return t.replace(n,"")});var Nn=T(require("react")),Ee=T(require("@radix-ui/react-tooltip"));var Cn=require("clsx"),xn=require("tailwind-merge");function s(...e){return(0,xn.twMerge)((0,Cn.clsx)(e))}var et=require("react/jsx-runtime"),Ro=Ee.Provider,Po=Ee.Root,Do=Ee.Trigger,Mr=Nn.forwardRef(({className:e,sideOffset:t=2,...r},o)=>(0,et.jsx)(Ee.Portal,{children:(0,et.jsx)(Ee.Content,{ref:o,sideOffset:t,className:s("z-50 rounded-md border border-transparent bg-gray-50 px-3 py-1.5 text-base font-semibold text-bold text-black/40 shadow-xl- animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-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 [box-shadow:3px_4px_11px_0px_#0000001A,13px_16px_21px_0px_#00000017,29px_36px_28px_0px_#0000000D,52px_65px_33px_0px_#00000003,82px_101px_36px_0px_#00000000]",e),...r,children:r.children})}));Mr.displayName=Ee.Content.displayName;var qt=({trigger:e,children:t,contentClassName:r,triggerClassName:o,asChild:n=!0,side:a,sideOffset:i,align:l,alignOffset:u,delayDuration:d=100,hasArrow:p=!0,arrowClassName:m,...c})=>(0,et.jsx)(Ro,{children:(0,et.jsx)(Po,{delayDuration:d,...c,children:(0,et.jsxs)("div",{className:"flex justify-center items-center",children:[(0,et.jsx)(Do,{asChild:n,className:o,children:e}),(0,et.jsxs)(Mr,{side:a,sideOffset:i,align:l,alignOffset:u,className:r,children:[t,p&&(0,et.jsx)(Ee.Arrow,{className:s("fill-white",m)})]})]})})});qt.displayName="Tooltip";var Sn=T(require("react"));var Rn=T(require("react")),So=T(require("@radix-ui/react-label")),Pn=require("class-variance-authority");var Dn=require("react/jsx-runtime"),Qs=(0,Pn.cva)("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Lo=Rn.forwardRef(({className:e,...t},r)=>(0,Dn.jsx)(So.Root,{ref:r,className:s(Qs(),e),...t}));Lo.displayName=So.Root.displayName;var Jt=require("react/jsx-runtime"),Y=Sn.default.forwardRef(({className:e,children:t,showAsterisk:r,error:o,...n},a)=>(0,Jt.jsx)(Lo,{ref:a,className:s(o&&"text-red-500",e),...n,children:r?(0,Jt.jsxs)("p",{children:[t,(0,Jt.jsx)("span",{className:"text-red-500",children:"*"})]}):t}));Y.displayName="FormLabel";var Qt=require("react/jsx-runtime"),Ve=({size:e=16,colour:t="primary"})=>(0,Qt.jsxs)("svg",{className:"animate-spin",width:e,height:e,viewBox:"0 0 20 20",fill:"none",children:[(0,Qt.jsx)("circle",{cx:"10",cy:"10",r:"9.25",stroke:"transparent",strokeWidth:"1.5"}),(0,Qt.jsx)("path",{d:"M10 0.595792C10 0.266746 10.267 -0.00185055 10.5954 0.0177417C11.9786 0.100242 13.3318 0.469461 14.5682 1.1044C15.9816 1.83021 17.2016 2.88235 18.1273 4.17366C19.0531 5.46496 19.6578 6.95826 19.8913 8.52984C20.1249 10.1014 19.9807 11.706 19.4705 13.2108C18.9604 14.7155 18.0991 16.077 16.9579 17.1825C15.8167 18.288 14.4285 19.1056 12.9084 19.5677C11.3882 20.0298 9.77982 20.123 8.21646 19.8397C6.84883 19.5918 5.55009 19.0619 4.40196 18.2863C4.12931 18.1021 4.08072 17.7265 4.28083 17.4653C4.48094 17.2041 4.85388 17.1564 5.12801 17.3384C6.12474 18.0001 7.24768 18.4531 8.42898 18.6672C9.80606 18.9168 11.2228 18.8347 12.5618 18.4276C13.9008 18.0206 15.1236 17.3004 16.1288 16.3266C17.134 15.3528 17.8927 14.1536 18.342 12.8282C18.7914 11.5027 18.9185 10.0893 18.7127 8.70502C18.507 7.32071 17.9743 6.00535 17.1589 4.86792C16.3435 3.73048 15.2688 2.80371 14.0238 2.16439C12.9559 1.61596 11.789 1.29259 10.5954 1.21173C10.2671 1.18949 10 0.92484 10 0.595792Z",fill:t==="primary"?"#ffffff":"currentColor",className:"rounded"})]});var Ln=T(require("react")),kn=require("@radix-ui/react-slot"),Tn=require("class-variance-authority");var He=require("react/jsx-runtime"),me=(0,Tn.cva)("overflow-hidden isolate inline-flex h-fit items-center justify-center whitespace-nowrap text-sm font-medium ring-offset-background dark:ring-offset-transparent transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:!pointer-events-none",{variants:{variant:{primary:"border-primary-main bg-primary-main hover:bg-primary-main/70 disabled:bg-primary-main/70 text-white font-bold",danger:"border-red-600 bg-red-600 hover:bg-red-600/70 disabled:bg-red-600/70 text-white font-bold",neutral:"!border-0 bg-transparent text-primary-main hover:opacity-80 disabled:opacity-60",outlined:"border border-primary-main text-primary-main hover:opacity-80 disabled:opacity-60","danger-outlined":"border border-red-600 text-red-600 hover:opacity-80 disabled:opacity-60","light-outlined":"border-white text-white hover:opacity-80 disabled:opacity-60","dark-text":"border-transparent bg-transparent hover:bg-opacity-70 disabled:bg-opacity-70 text-black font-medium",light:"border-white bg-white hover:bg-opacity-70 disabled:bg-opacity-70 text-primary-main font-semibold"},size:{default:"py-[0.625rem] px-[1.5rem] text-[0.875rem] leading-[1.25rem] font-medium rounded-lg",sm:"py-[0.375rem] px-[1rem] leading-[1rem] font-normal text-sm rounded-lg",lg:"py-[0.75rem] px-[1.5rem] text-[1rem] leading-[1.5rem] font-medium rounded-lg",md:"py-[0.625rem] px-[1.5rem] text-[0.875rem] leading-[1.25rem] font-medium rounded-lg","icon-sm":"h-[1.75rem] w-[1.75rem] flex justify-center items-center font-medium rounded-lg",icon:"h-[2.5rem] w-[2.75rem] flex justify-center items-center font-medium rounded-lg","icon-lg":"h-[3rem] w-[3rem] flex justify-center items-center font-medium rounded-lg"}},defaultVariants:{variant:"primary",size:"default"}}),ce=Ln.forwardRef(({className:e,variant:t="primary",size:r,asChild:o=!1,isLoading:n=!1,leftNode:a,rightNode:i,LoaderSize:l,children:u,disabled:d,...p},m)=>(0,He.jsx)(o?kn.Slot:"button",{className:s(me({variant:t,size:r,className:e})),ref:m,disabled:d||n,...p,children:(0,He.jsx)("div",{className:"flex font-medium justify-center items-center gap-2 pointer-events-none",children:n?(0,He.jsx)("span",{className:"mx-auto",children:(0,He.jsx)(Ve,{size:l,colour:"secondary"})}):(0,He.jsxs)(He.Fragment,{children:[a&&(0,He.jsx)("span",{children:a}),u&&(0,He.jsx)("span",{children:u}),i&&(0,He.jsx)("span",{children:i})]})})}));ce.displayName="Button";var $e=T(require("@radix-ui/react-dropdown-menu")),Fn=require("lucide-react"),En=T(require("react"));var Ce=require("react/jsx-runtime"),el=me,ko=({items:e,variant:t="primary",size:r,isLoading:o=!1,leftNode:n,children:a,disabled:i,className:l,buttonClassName:u,triggerClassName:d,contentClassName:p,itemClassName:m,menuAlign:c="end",menuSide:g="bottom",menuTriggerLabel:x="More options",open:h,onOpenChange:v,modal:f=!1,id:N="split-button",...P})=>(0,Ce.jsxs)("div",{className:s("inline-flex",l),id:N,children:[(0,Ce.jsx)(ce,{type:"button",variant:t,size:r,isLoading:o,leftNode:n,disabled:i,className:s("!rounded-r-none",u),id:`${N}-action`,...P,children:a}),(0,Ce.jsxs)($e.Root,{open:h,onOpenChange:v,modal:f,children:[(0,Ce.jsx)($e.Trigger,{asChild:!0,disabled:i,className:"!h-full",children:(0,Ce.jsx)(ce,{type:"button",variant:t,size:r,disabled:i,className:s("!px-2 !rounded-l-none !h-auto",el({variant:t,size:r}),d,{"!border-l-white border-l-[0.5px]":t==="primary"||t==="danger"}),id:`${N}-trigger`,"aria-label":x,children:(0,Ce.jsx)(Fn.ChevronDown,{className:"h-full w-4"})})}),(0,Ce.jsx)($e.Portal,{children:(0,Ce.jsx)($e.Content,{align:c,side:g,sideOffset:4,className:s("z-50 min-w-[10rem] overflow-hidden rounded-md border border-gray-100 bg-white p-1 text-[#191919] shadow-md outline-none 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",p),id:`${N}-content`,children:e.map((w,L)=>(0,Ce.jsxs)(En.Fragment,{children:[w.separatorBefore&&(0,Ce.jsx)($e.Separator,{className:"-mx-1 my-1 h-px bg-gray-100"}),(0,Ce.jsxs)($e.Item,{disabled:w.disabled,onSelect:()=>w.onSelect?.(),className:s("flex cursor-pointer select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors hover:bg-primary-accent focus:bg-primary-accent data-[highlighted]:bg-primary-accent data-[disabled]:pointer-events-none data-[disabled]:opacity-50",w.destructive&&"text-red-600 hover:bg-red-50 focus:bg-red-50 data-[highlighted]:bg-red-50",m,w.className),id:`${N}-item-${w.value??L}`,children:[w.icon&&(0,Ce.jsx)("span",{className:"shrink-0",children:w.icon}),(0,Ce.jsx)("span",{children:w.label})]})]},w.value??L))})})]})]});ko.displayName="SplitButton";var To=T(require("react"));var Ir=require("class-variance-authority");var An=T(require("react")),Mn=require("react/jsx-runtime"),Pe=An.default.forwardRef(({className:e,children:t,error:r,...o},n)=>{let a=r??t;return a?(0,Mn.jsx)("p",{ref:n,className:s("text-xs font-normal text-[#F04248]",e),...o,children:a}):null});Pe.displayName="ErrorMessage";var In=T(require("react")),Bn=require("react/jsx-runtime"),_e=In.default.forwardRef(({className:e,...t},r)=>(0,Bn.jsx)("div",{ref:r,className:s("text-sm text-[#8E98A8",e),...t}));_e.displayName="FormDescription";var Xe=require("react/jsx-runtime"),tl=(0,Ir.cva)("!p-0 flex h-full w-full !border-transparent !bg-transparent text-base focus-visible:bg-transparent focus-visible:outline-none focus-visible:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50",{variants:{status:{default:"placeholder:text-[#C4C4C4] dark:placeholder:text-[#9299A2]",error:"placeholder:text-red-500 text-red-500",loading:"placeholder:text-[#C4C4C4] dark:placeholder:text-[#9299A2]",prefilled:"",neutral:""}},defaultVariants:{status:"default"}}),Vn=To.forwardRef(({className:e,status:t,type:r,...o},n)=>(0,Xe.jsx)("input",{type:r,className:s(tl({status:t}),e),ref:n,...o}));Vn.displayName="BaseInnerInput";var fe=(0,Ir.cva)("flex relative h-10 w-full rounded-[4px] dark:!bg-transparent border transition px-3 py-2 text-base placeholder:text-[#79818C] focus-within:outline-0 focus-within:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50 dark:disabled:!border-[#9299A2]",{variants:{status:{default:"border-[#DEDEDE] bg-white text-[#191919] dark:!bg-transparent caret-text-primary focus-within:bg-white dark:focus-within:!bg-transparent dark:text-white focus-within:border-primary-main dark:focus-within:border-[#9299A2] dark:disabled:!border-[#9299A2]",error:"placeholder:text-red-500 bg-red-50 border-red-500 dark:!bg-status-error-bg-dark text-red-500 focus-within:bg-red-50 focus-within:border-red-500",loading:"",prefilled:"bg-[#F6F6F6] border-[#DEDEDE] dark:!bg-transparent caret-[#DEDEDE] focus-within:bg-[#F6F6F6] focus-within:border-[#DEDEDE] dark:!border-[#9299A2] dark:focus-within:border-[#9299A2]",neutral:"bg-[#F6F6F6] border-[#DEDEDE] dark:!bg-transparent caret-[#DEDEDE] focus-within:bg-[#F6F6F6] focus-within:border-[#DEDEDE] dark:!border-[#9299A2] dark:focus-within:border-[#9299A2]"}},defaultVariants:{status:"default"}}),On=(0,Ir.cva)("top-0 flex justify-center items-center h-full min-w-[50px] max-w-[100px] dark:!bg-transparent transition px-3 py-2 text-base placeholder:text-[#79818C] focus-within:outline-0 focus-within:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50 dark:disabled:!border-[#9299A2]",{variants:{side:{left:"left-0 rounded-l-[8px] border-r",right:"right-0 rounded-r-[8px] border-l"},status:{default:"border-[#DEDEDE] bg-white text-[#191919] dark:!bg-transparent caret-primary-main focus-within:bg-white dark:focus-within:!bg-transparent dark:text-white focus-within:border-primary-main dark:focus-within:border-[#9299A2] dark:disabled:!border-[#9299A2]",error:"placeholder:text-red-500 bg-red-50 border-red-500 dark:!bg-red-50 text-red-500 focus-within:bg-red-50 focus-within:border-red-500",loading:"",prefilled:"bg-[#F6F6F6] border-[#DEDEDE] dark:!bg-transparent caret-[#DEDEDE] focus-within:bg-[#F6F6F6] focus-within:border-[#DEDEDE] dark:!border-[#9299A2] dark:focus-within:border-[#9299A2]",neutral:"bg-transparent border-0 caret-[#DEDEDE] !px-0"}},defaultVariants:{status:"default",side:"left"}}),de=To.forwardRef(({className:e,status:t="default",disabled:r,error:o,isLoading:n,sideNodeClassName:a,showAsterisk:i,label:l,description:u,...d},p)=>{let m=t;return o&&(m="error"),n&&(m="loading"),r&&(m="prefilled"),(0,Xe.jsxs)("div",{className:"relative space-y-1 w-full",children:[l&&(0,Xe.jsx)(Y,{showAsterisk:i,error:o,children:l}),(0,Xe.jsxs)("div",{className:s(fe({status:m}),d.leftNode?"pl-0":"",d.rightNode?"pr-0":"",e),children:[d.leftNode?(0,Xe.jsx)("div",{className:s(On({status:m,side:"left"}),a),children:d.leftNode}):null,(0,Xe.jsx)(Vn,{ref:p,disabled:n||r,className:s({"!pl-3":d.leftNode&&t!=="neutral","!pr-3":d.rightNode&&t!=="neutral","sentry-mask":!!d?.isContentSensitive}),...d}),d.rightNode?(0,Xe.jsx)("div",{className:s(On({status:m,side:"right"}),a),children:d.rightNode}):null]}),u&&(0,Xe.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:u}),(0,Xe.jsx)(Pe,{error:o})]})});de.displayName="Input";var rr=require("react");var Fo=require("react/jsx-runtime"),Hn=()=>(0,Fo.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,Fo.jsx)("path",{d:"M8.89802 2.93408L9.70202 3.49808L6.21602 8.52608H5.41202L3.46802 5.80208L4.27202 5.05208L5.81402 6.49208L8.89802 2.93408Z",fill:"currentColor"})});var er=require("react/jsx-runtime"),$n=()=>(0,er.jsxs)("svg",{width:"18",height:"14",viewBox:"0 0 18 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,er.jsx)("path",{d:"M1.54639 7.26103C1.48389 7.09264 1.48389 6.90741 1.54639 6.73903C2.15517 5.26292 3.18853 4.00081 4.51547 3.1127C5.84241 2.22459 7.40317 1.75049 8.99989 1.75049C10.5966 1.75049 12.1574 2.22459 13.4843 3.1127C14.8113 4.00081 15.8446 5.26292 16.4534 6.73903C16.5159 6.90741 16.5159 7.09264 16.4534 7.26103C15.8446 8.73713 14.8113 9.99925 13.4843 10.8874C12.1574 11.7755 10.5966 12.2496 8.99989 12.2496C7.40317 12.2496 5.84241 11.7755 4.51547 10.8874C3.18853 9.99925 2.15517 8.73713 1.54639 7.26103Z",stroke:"#8E98A8",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),(0,er.jsx)("path",{d:"M9 9.25C10.2426 9.25 11.25 8.24264 11.25 7C11.25 5.75736 10.2426 4.75 9 4.75C7.75736 4.75 6.75 5.75736 6.75 7C6.75 8.24264 7.75736 9.25 9 9.25Z",stroke:"#8E98A8",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]});var tr=require("react/jsx-runtime"),_n=()=>(0,tr.jsxs)("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,tr.jsx)("path",{d:"M4.08759 12.69C3.26171 11.9072 2.61006 10.9591 2.17509 9.90752C2.10081 9.73454 2.0625 9.54826 2.0625 9.36001C2.0625 9.17177 2.10081 8.98549 2.17509 8.81252C2.75274 7.4073 3.72095 6.19704 4.96509 5.32502C6.14597 4.4998 7.55989 4.07405 9.00009 4.11002C10.0363 4.084 11.064 4.30239 12.0001 4.74752M13.9201 6.03752C14.7415 6.81964 15.3904 7.76486 15.8251 8.81252C15.8994 8.98549 15.9377 9.17177 15.9377 9.36001C15.9377 9.54826 15.8994 9.73454 15.8251 9.90752C15.2474 11.3127 14.2792 12.523 13.0351 13.395C11.8542 14.2202 10.4403 14.646 9.00009 14.61C7.9639 14.636 6.93616 14.4176 6.00009 13.9725",stroke:"#8E98A8",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,tr.jsx)("path",{d:"M6.5325 10.2375C6.42732 9.95694 6.37395 9.65962 6.375 9.36C6.375 8.66381 6.65156 7.99613 7.14384 7.50384C7.63613 7.01156 8.30381 6.735 9 6.735C9.3 6.7335 9.597 6.7875 9.8775 6.8925M11.4675 8.4825C11.5725 8.763 11.6265 9.06 11.625 9.36C11.625 10.0562 11.3484 10.7239 10.8562 11.2162C10.3639 11.7084 9.69619 11.985 9 11.985C8.70038 11.986 8.40306 11.9327 8.1225 11.8275M2.25 15L14.25 3",stroke:"#8E98A8",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]});var Eo=require("react/jsx-runtime"),zn=()=>(0,Eo.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,Eo.jsx)("path",{d:"M3.37891 8.62142L6.00041 5.99992L8.62191 8.62142M8.62191 3.37842L5.99991 5.99992L3.37891 3.37842",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});var Ae=require("react/jsx-runtime"),Wn=[{label:"Uppercase",key:"uppercase",RegExp:/[A-Z]/,validated:!1},{label:"Lowercase",key:"lowercase",RegExp:/[a-z]/,validated:!1},{label:"Number",key:"number",RegExp:/\d/,validated:!1},{label:"12 Characters",key:"twelve-chars",RegExp:/.{12}/,validated:!1}],Ao=({onValidate:e,onChange:t,disableValidation:r,...o})=>{let[n,a]=(0,rr.useState)(!1),[i,l]=(0,rr.useState)(Wn),u=c=>Wn.map(g=>({...g,validated:g.RegExp.test(c)})),d=c=>{let g=u(c),x=g.every(h=>h.validated);return l(g),x},p=c=>{if(t&&t(c),r)return;let g=c?.target?.value,x=d(g);e&&e(x,g)},m=(0,rr.useMemo)(()=>(0,Ae.jsx)("div",{className:"flex items-center gap-2",children:i?.map(c=>(0,Ae.jsxs)("div",{className:s("text-xs flex items-center gap-0.5",{"text-[#62C554]":c?.validated,"text-[#8E98A8]":!c?.validated}),children:[(0,Ae.jsx)("span",{className:"",children:c?.validated?(0,Ae.jsx)(Hn,{}):(0,Ae.jsx)(zn,{})}),(0,Ae.jsx)("span",{className:"",children:c?.label})]},c?.key))}),[i]);return(0,Ae.jsx)(de,{sideNodeClassName:"!border-l-0",rightNode:n?(0,Ae.jsx)("button",{type:"button",onClick:()=>a(c=>!c),children:(0,Ae.jsx)($n,{})}):(0,Ae.jsx)("button",{type:"button",onClick:()=>a(c=>!c),children:(0,Ae.jsx)(_n,{})}),type:n?"text":"password",onChange:p,description:!r&&m,isContentSensitive:!0,...o})};Ao.displayName="PasswordInput";var Gn=require("class-variance-authority");var Dt=require("react/jsx-runtime"),rd=(0,Gn.cva)("flex relative min-h-[80px] w-full rounded-[8px] border transition px-3 py-2 text-base placeholder:text-[#79818C] focus-within:outline-0 focus-within:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50",{variants:{status:{default:"border-[#D7D7D7] dark:border-[#676767] bg-white text-[#191919] dark:!bg-transparent caret-primary-main focus-within:bg-white dark:focus-within:!bg-transparent dark:text-white focus-within:border-primary-main dark:focus-within:border-[#9299A2] dark:border-[#9299A2] dark:disabled:!border-[#9299A2]",error:"placeholder:text-status-error-fill bg-status-error-bg border-status-error-fill dark:!bg-status-error-bg-dark text-status-error-fill focus-within:bg-status-error-bg focus-within:border-status-error-fill",loading:"placeholder:text-[#C4C4C4]",prefilled:"resize-none bg-[#F6F6F6] border-[#D7D7D7] dark:!bg-transparent caret-[#D7D7D7] focus-within:bg-[#F6F6F6] focus-within:border-[#D7D7D7] dark:!border-[#9299A2] dark:focus-within:border-[#9299A2]",neutral:""}},defaultVariants:{status:"default"}}),Mo=({className:e,status:t="default",disabled:r,error:o,isLoading:n,showAsterisk:a,label:i,description:l,...u})=>{let d=t;return o&&(d="error"),n&&(d="loading"),r&&(d="prefilled"),(0,Dt.jsxs)("div",{className:"relative space-y-1",children:[(0,Dt.jsx)(Y,{showAsterisk:a,error:o,children:i}),(0,Dt.jsx)("textarea",{className:s("min-h-[80px]",fe({status:d}),e),disabled:n||r,...u}),(0,Dt.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:l}),(0,Dt.jsx)(Pe,{error:o})]})};Mo.displayName="Textarea";var la=T(require("react")),ca=require("lucide-react");var St=T(require("react"));var ft=T(require("react")),xe=require("cmdk"),qn=require("lucide-react");var X=T(require("@radix-ui/react-dialog")),mt=T(require("react"));var or=require("react/jsx-runtime"),Un=()=>(0,or.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"lucide lucide-x",children:[(0,or.jsx)("path",{d:"M18 6 6 18"}),(0,or.jsx)("path",{d:"m6 6 12 12"})]});var Z=require("react/jsx-runtime"),rl=X.Root,ol=X.Trigger,nl=X.Portal,Zn=mt.forwardRef(({className:e,...t},r)=>(0,Z.jsx)(X.Overlay,{ref:r,className:s("fixed inset-0 z-50 bg-black/60 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));Zn.displayName=X.Overlay.displayName;var Io=mt.forwardRef(({className:e,hideCloseButton:t,children:r,...o},n)=>(0,Z.jsxs)(nl,{children:[(0,Z.jsx)(Zn,{}),(0,Z.jsxs)(X.Content,{ref:n,className:s("fixed left-[50%] top-[50%] z-50 grid sm:w-full w-[95%] max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border border-transparent bg-white p-6 shadow-lg duration-200 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-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] rounded-lg max-h-[95%] overflow-y-auto",e),...o,children:[r,!t&&(0,Z.jsxs)(X.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground z-20",children:[(0,Z.jsx)(Un,{}),(0,Z.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));Io.displayName=X.Content.displayName;var Kn=({className:e,...t})=>(0,Z.jsx)("div",{className:s("flex flex-col space-y-1.5 text-left",e),...t});Kn.displayName="DialogHeader";var jn=({className:e,...t})=>(0,Z.jsx)("div",{className:s("flex flex-row justify-end sm:space-x-2",e),...t});jn.displayName="DialogFooter";var Yn=mt.forwardRef(({className:e,...t},r)=>(0,Z.jsx)(X.Title,{ref:r,className:s("text-xl font-semibold leading-none tracking-tight",e),...t}));Yn.displayName=X.Title.displayName;var Xn=mt.forwardRef(({className:e,...t},r)=>(0,Z.jsx)(X.Description,{ref:r,className:s("text-sm text-gray-500",e),...t}));Xn.displayName=X.Description.displayName;var Br=({trigger:e=void 0,children:t,open:r,onOpenChange:o,hideCloseButton:n,footer:a,title:i,description:l,contentClassName:u,headerClassName:d,titleClassName:p,descriptionClassName:m,footerClassName:c,asChild:g=!0,onOpenAutoFocus:x,onCloseAutoFocus:h,onEscapeKeyDown:v,onInteractOutside:f,onPointerDownOutside:N,closeOnOutsideClick:P=!0,...w})=>{let L=mt.useCallback(b=>{P||b.preventDefault(),N?.(b)},[P,N]),F=mt.useCallback(b=>{P||b.preventDefault(),f?.(b)},[P,f]);return(0,Z.jsxs)(rl,{...w,...r!==void 0?{open:r,onOpenChange:o}:{},children:[(0,Z.jsx)(ol,{asChild:g,children:e}),(0,Z.jsxs)(Io,{className:u,hideCloseButton:n,onOpenAutoFocus:x,onCloseAutoFocus:h,onEscapeKeyDown:v,onPointerDownOutside:L,onInteractOutside:F,children:[i||l?(0,Z.jsxs)(Kn,{className:d,children:[i&&(0,Z.jsx)(Yn,{className:p,children:i}),l&&(0,Z.jsx)(Xn,{className:m,children:l})]}):(0,Z.jsx)(Z.Fragment,{}),t,a&&(0,Z.jsx)(jn,{className:c,children:a})]})]})};Br.displayName=X.Dialog.displayName;var De=require("react/jsx-runtime"),nr=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command,{ref:r,className:s("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t}));nr.displayName=xe.Command.displayName;var ar=ft.forwardRef(({className:e,CommandInputContainerClassName:t,loading:r,...o},n)=>(0,De.jsxs)("div",{className:s("flex items-center border-0 px-3 gap-2",t),"cmdk-input-wrapper":"",children:[r?(0,De.jsx)(Ve,{size:16,colour:"secondary"}):(0,De.jsx)(qn.Search,{className:"mr-2 h-4 w-4 shrink-0 opacity-50"}),(0,De.jsx)(xe.Command.Input,{ref:n,className:s("flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",e),disabled:r,...o})]}));ar.displayName=xe.Command.Input.displayName;var ir=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command.List,{ref:r,className:s("overflow-y-auto overflow-x-hidden",e),...t}));ir.displayName=xe.Command.List.displayName;var sr=ft.forwardRef((e,t)=>(0,De.jsx)(xe.Command.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));sr.displayName=xe.Command.Empty.displayName;var lr=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command.Group,{ref:r,className:s("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t}));lr.displayName=xe.Command.Group.displayName;var al=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command.Separator,{ref:r,className:s("-mx-1 h-px bg-border",e),...t}));al.displayName=xe.Command.Separator.displayName;var cr=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command.Item,{ref:r,className:s("relative text=[#222222] flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-primary-accent data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",e),...t}));cr.displayName=xe.Command.Item.displayName;var il=({className:e,...t})=>(0,De.jsx)("span",{className:s("ml-auto text-xs tracking-widest text-muted-foreground",e),...t});il.displayName="CommandShortcut";var Bo=T(require("react")),ze=T(require("@radix-ui/react-popover"));var at=require("react/jsx-runtime"),Ne=ze.Root,ee=Bo.forwardRef((e,t)=>(0,at.jsx)(ze.Trigger,{ref:t,...e,onPointerDown:r=>{e.onPointerDown?.(r)}}));ee.displayName=ze.Trigger.displayName;var ge=Bo.forwardRef(({className:e,align:t="center",sideOffset:r=4,portal:o=!0,...n},a)=>o?(0,at.jsx)(ze.Portal,{children:(0,at.jsx)(ze.Content,{ref:a,align:t,sideOffset:r,className:s("pointer-events-auto z-50 w-72 rounded-md border border-transparent bg-white p-4 text-[#191919] shadow-md outline-none 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",e),onOpenAutoFocus:n.onOpenAutoFocus,onCloseAutoFocus:n.onCloseAutoFocus,...n})}):(0,at.jsx)(ze.Content,{ref:a,align:t,sideOffset:r,className:s("pointer-events-auto z-50 w-72 rounded-md border border-transparent bg-white p-4 text-[#191919] shadow-md outline-none 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",e),onOpenAutoFocus:n.onOpenAutoFocus,onCloseAutoFocus:n.onCloseAutoFocus,...n}));ge.displayName=ze.Content.displayName;var Me=({trigger:e,children:t,open:r,onOpenChange:o,contentClassName:n,asChild:a=!0,align:i,side:l,alignOffset:u,triggerClassName:d,sideOffset:p,onOpenAutoFocus:m,onCloseAutoFocus:c,portal:g=!0,id:x="popover",...h})=>(0,at.jsxs)(Ne,{...h,...r!==void 0?{open:r,onOpenChange:o}:{},children:[(0,at.jsx)(ee,{asChild:a,className:d,id:`${x}-trigger`,children:e}),(0,at.jsx)(ge,{alignOffset:u,sideOffset:p,side:l,align:i,className:n,onOpenAutoFocus:m,onCloseAutoFocus:c,portal:g,id:`${x}-content`,children:t})]});Me.displayName=ze.Root.displayName;var Oo=T(require("react")),We=T(require("@radix-ui/react-scroll-area"));var gt=require("react/jsx-runtime"),Ie=Oo.forwardRef(({className:e,viewPortClassName:t,children:r,...o},n)=>(0,gt.jsxs)(We.Root,{ref:n,className:s("relative overflow-hidden",e),...o,children:[(0,gt.jsx)(We.Viewport,{className:s("h-full w-full rounded-[inherit]",t),children:r}),(0,gt.jsx)(Or,{}),(0,gt.jsx)(We.Corner,{})]}));Ie.displayName=We.Root.displayName;var Or=Oo.forwardRef(({className:e,orientation:t="vertical",...r},o)=>(0,gt.jsx)(We.ScrollAreaScrollbar,{ref:o,orientation:t,className:s("flex touch-none select-none transition-colors",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...r,children:(0,gt.jsx)(We.ScrollAreaThumb,{className:"relative flex-1 rounded-full bg-[#959595] transition hover:bg-[#808080]"})}));Or.displayName=We.ScrollAreaScrollbar.displayName;var ie=require("react/jsx-runtime"),Jn=({className:e,value:t,placeholder:r="",status:o,disabled:n,id:a})=>(0,ie.jsx)(ee,{asChild:!0,disabled:n,id:a??"searchable-trigger",children:(0,ie.jsxs)("button",{disabled:n,className:s(fe({status:o}),"[&>span]:justify-start [&>span]:items-center gap-2 flex h-12 w-full items-center justify-between goup",t?"":"text-[#79818C]",e),children:[(0,ie.jsx)("span",{children:t??r??"Select options..."}),(0,ie.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",className:" data-[state=open]:goup-rotate-180",children:(0,ie.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"currentColor",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}),Vr=({options:e=[],value:t,onChange:r,containerClassName:o,placeholder:n,disabled:a,loading:i,optionComponent:l,children:u,modal:d=!1,hideSearch:p,className:m,inputValue:c,onValueChange:g,onInputValueChange:x})=>{let[h,v]=St.useState(!1),[f,N]=St.useState(void 0),P=St.useRef(null),w=St.useCallback(L=>{if(P.current&&(P.current.disconnect(),P.current=null),L){let F=()=>{N(L.getBoundingClientRect().width)};F();let b=new ResizeObserver(()=>{F()});b.observe(L),P.current=b}},[]);return(0,ie.jsxs)(Ne,{modal:d,open:h,onOpenChange:v,children:[(0,ie.jsx)("div",{className:s("w-full",m),ref:w,children:u}),(0,ie.jsx)(ge,{portal:!d,className:"p-0 min-w-[200px]",style:{width:f?`${f}px`:void 0},children:(0,ie.jsxs)(nr,{className:s("relative max-h-[270px]",{"mt-2":!p}),children:[!p&&(0,ie.jsx)(ar,{loading:i,placeholder:n??"Search options...",onValueChange:x,value:c,CommandInputContainerClassName:"mx-2 border rounded-md border-[#DEDEDE]"}),(0,ie.jsx)(Ie,{viewPortClassName:"max-h-[225px]",className:s("w-full px-0 h-full overflow-y-auto",o),children:(0,ie.jsxs)(ir,{children:[!p&&(0,ie.jsx)(sr,{children:"No result found."}),(0,ie.jsx)(lr,{className:"w-full",children:e?.map((L,F)=>(0,ie.jsx)(cr,{defaultValue:t?.label,value:L.label,disabled:a,onSelect:()=>{r(L),v(!1),g?.(L?.value)},id:L.value,children:l?l(L):(0,ie.jsx)("span",{children:L.label})},`${L.value}-${F}`))})]})})]})})]})};var ea=require("lucide-react"),te=T(require("react")),Vo=require("uuid");var Hr=require("framer-motion"),Qn=T(require("react")),Be=require("react/jsx-runtime"),dr=({size:e="md",semi:t=!1,className:r,id:o,label:n,labelClassName:a,labelWrapperClassName:i,disabled:l,subtitle:u,subtitleClassName:d,bodyClassName:p,checked:m,defaultChecked:c,onCheckedChange:g,name:x,value:h,onClick:v})=>{let f=Qn.useId(),N=o??f,P=l?"#B0B0B0":"#00D488";return(0,Be.jsxs)("div",{className:s("flex justify-start items-start gap-1",p),children:[(0,Be.jsxs)("div",{className:"relative flex items-center justify-center",children:[(0,Be.jsx)("input",{type:"checkbox",id:N,name:x,value:h,checked:m,defaultChecked:c,disabled:l,onClick:v,onChange:w=>g?.(w.target.checked),className:s("appearance-none shrink-0 rounded-[3px] border border-solid border-base-500","bg-base-100 dark:bg-transparent cursor-pointer transition","hover:bg-status-success-bg hover:border-status-success-fill","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-status-success-fill focus-visible:ring-offset-2","checked:bg-status-success-bg checked:border-status-success-fill","disabled:cursor-not-allowed disabled:opacity-50",e==="md"?"h-5 w-5":"h-6 w-6",r)}),(0,Be.jsx)(Hr.AnimatePresence,{children:m&&(0,Be.jsx)(Hr.motion.svg,{className:"absolute pointer-events-none",initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.1},...t?{width:12,height:2,viewBox:"0 0 12 2"}:{width:10,height:8,viewBox:"0 0 10 8"},fill:"none",children:t?(0,Be.jsx)("path",{d:"M1.9165 1H10.0832",stroke:P,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}):(0,Be.jsx)("path",{d:"M1 3.99996L3.66353 6.66349L9 1.33643",stroke:P,strokeWidth:"1.06667",strokeLinecap:"round",strokeLinejoin:"round"})},t?"semi":"check")})]}),(n||u)&&(0,Be.jsxs)("div",{className:s("flex flex-col justify-start items-start",i),children:[(0,Be.jsx)("label",{htmlFor:N,children:(0,Be.jsx)("span",{className:s("text-sm font-normal cursor-pointer transition-colors text-base-700 dark:text-white",l&&"cursor-not-allowed opacity-50",a),onClick:()=>!l&&g?.(!m),children:n})}),u&&(0,Be.jsx)("p",{className:s("text-sm text-base-500",l&&"opacity-50",d),children:u})]})]})};dr.displayName="Checkbox";var E=require("react/jsx-runtime"),ta=te.memo(({item:e,onDelete:t})=>(0,E.jsxs)("p",{className:"text-xs p-1.5 py-1 bg-gray-100 rounded-md flex items-center",children:[(0,E.jsx)("span",{children:e.label}),(0,E.jsx)("button",{type:"button",className:"pl-2",onClick:r=>{r.stopPropagation(),t(e)},children:(0,E.jsx)(ea.X,{size:12})})]}));ta.displayName="SelectedChip";var $r=te.memo(({disabled:e,className:t,values:r,placeholder:o="",status:n,onDelete:a})=>(0,E.jsx)(ee,{asChild:!0,disabled:e,children:(0,E.jsxs)("div",{className:s(fe({status:n}),"cursor-pointer [&>svg]:shrink-0 h-auto min-h-12 flex items-center justify-between w-full gap-2",t),children:[(0,E.jsx)("div",{className:"w-full flex flex-row items-center gap-2 flex-wrap",children:r.length?r.map(i=>(0,E.jsx)(ta,{item:i,onDelete:a},i.value)):(0,E.jsx)("span",{className:"text-[#79818C] dark:text-[#959BA4]",children:o})}),(0,E.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",children:(0,E.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"currentColor",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}));$r.displayName="MultiSelectTrigger";var ra=te.memo(({option:e,isChecked:t,onSelect:r,optionComponent:o})=>(0,E.jsx)("article",{className:"cursor-pointer relative hover:bg-status-success-bg transition flex w-[calc(100%-0.375rem)] mx-auto rounded-md items-center focus:dark:!text-[#DDDFE0] py-1.5 px-2 text-sm outline-none focus:bg-status-success-bg dark:!text-[#DDDFE0] focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 focus-visible:ring-1 focus-visible:ring-status-success-fill focus-visible:ring-offset-1 focus-visible:ring-offset-status-success-fill",onClick:()=>r(e),children:(0,E.jsx)("div",{className:"w-full h-[30px] flex flex-row items-center dark:!text-white",children:(0,E.jsx)(dr,{onCheckedChange:()=>r(e),value:e.value,label:o?o(e):(0,E.jsx)("span",{children:e.label}),bodyClassName:"w-full",labelWrapperClassName:"w-full",labelClassName:s(o&&"w-full"),checked:t})})}));ra.displayName="OptionItem";var _r=({options:e,children:t,onChange:r,optionComponent:o,values:n,hideSearch:a,modal:i,placeholder:l,isLoading:u,showSelectedValues:d=!1,error:p,label:m,showAsterisk:c})=>{let[g,x]=te.useState(""),h=n,v=te.useMemo(()=>new Set(h.map(y=>y.value)),[h]),f=te.useMemo(()=>{if(!g)return e;let y=g.trim().toLowerCase();return e.filter(A=>A.label?.trim()?.toLowerCase()?.includes(y))},[e,g]),N=te.useCallback(y=>{let A=v.has(y.value);r(A?h.filter(G=>G.value!==y.value):[...h,y])},[h,v,r]),P=te.useRef(null),[w,L]=te.useState(void 0);te.useLayoutEffect(()=>{if(!P.current)return;let y=P.current,A=()=>{L(y.getBoundingClientRect().width)};A();let G=new ResizeObserver(()=>{A()});return G.observe(y),()=>G.disconnect()},[]);let F=te.useCallback(y=>{let A=h.filter(G=>G.value!==y.value);r(A)},[h,r]),b=te.useCallback(()=>{h.length===e.length?r([]):r(e)},[h.length,e,r]),D=te.useCallback(y=>{x(y.target.value)},[]);return(0,E.jsxs)("div",{className:"relative space-y-1",children:[(0,E.jsx)(Y,{showAsterisk:c,error:p,children:m}),(0,E.jsxs)(Ne,{modal:i,children:[(0,E.jsx)("div",{ref:P,children:t??(0,E.jsx)($r,{values:h,placeholder:l??"Select",onDelete:F,className:"h-auto"})}),d&&(0,E.jsx)("div",{className:"flex py-2 gap-2 flex-wrap",children:h.map(y=>(0,E.jsx)("div",{className:"bg-gray-100 border text-black rounded-xl text-[10px] font-medium px-2 py-1",children:(0,E.jsx)("span",{children:y.label})},(0,Vo.v4)()))}),(0,E.jsxs)(ge,{portal:!i,align:"start",className:"min-w-[200px] p-0",style:{width:w?`${w}px`:void 0},onInteractOutside:y=>{y.target?.closest("[data-radix-popper-content-wrapper]")&&y.preventDefault()},onOpenAutoFocus:y=>y.preventDefault(),children:[!a&&(0,E.jsx)("div",{className:"w-full px-4",children:(0,E.jsxs)("div",{className:"w-full h-[36px] px-1 flex items-center justify-start border-[0.5px] rounded-md border-[#D7D7D7] mb-[5px]",children:[u?(0,E.jsx)(Ve,{}):(0,E.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,E.jsx)("path",{d:"M11.5 21C16.7467 21 21 16.7467 21 11.5C21 6.25329 16.7467 2 11.5 2C6.25329 2 2 6.25329 2 11.5C2 16.7467 6.25329 21 11.5 21Z",stroke:"#959595",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,E.jsx)("path",{d:"M22 22L20 20",stroke:"#959595",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}),(0,E.jsx)("input",{value:g,placeholder:"Search",type:"text",disabled:u,className:"oultine-0 focus-visible:outline-0 focus-visible:ring-0 ml-1 w-full !border-transparent placeholder:text-sm placeholder:font-normal dark:bg-transparent placeholder:text-[#959595] dark:placeholder:text-[#DDDFE0] focus:ring-0 focus:ring-offset-0 focus:bg-white dark:focus:bg-transparent dark:text-[#DDDFE0]",onChange:D})]})}),(0,E.jsxs)("div",{className:s("w-full h-[44px] px-2.5 flex items-center justify-between mb-[5px] border-[#D7D7D7] dark:border-[#5C636B]",a?"border-b-[0.5px]":"border-y-[0.5px]"),children:[(0,E.jsx)("button",{className:"text-sm text-primary-main font-normal",onClick:b,disabled:f.length<1||u,children:(0,E.jsxs)("span",{children:[h.length===e.length?"Unselect":"Select"," all"]})}),(0,E.jsxs)("p",{className:"text-sm text-[#959595] font-normal dark:text-[#DDDFE0]",children:[h.length," selected"]})]}),(0,E.jsxs)(Ie,{viewPortClassName:"max-h-[225px]",className:"pb-1",children:[u&&(0,E.jsx)("div",{className:"py-7 flex justify-center",children:(0,E.jsx)(Ve,{})}),!u&&f.map(y=>(0,E.jsx)(ra,{option:y,isChecked:v.has(y.value),onSelect:N,optionComponent:o},(0,Vo.v4)()))]})]})]})]})};var sl=[{countryCode:"GLOBAL",countryName:"Global",currency:"Dollars",currencyCode:"USD",internetCountryCode:"GLOBAL"},{countryName:"Benin",countryCode:"+229",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"BJ"},{countryName:"Burkina Faso",countryCode:"+226",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"BF"},{countryName:"Cameroon",countryCode:"+237",currency:"Central African CFA franc",currencyCode:"XAF",currencyIcon:"Fr",internetCountryCode:"CM"},{countryName:"Chad",countryCode:"+235",currency:"Central African CFA franc",currencyCode:"XAF",currencyIcon:"Fr",internetCountryCode:"TD"},{countryName:"DR Congo",countryCode:"+243",currency:"Congolese franc",currencyCode:"CDF",currencyIcon:"FC",internetCountryCode:"CD"},{countryName:"Eswatini",countryCode:"+268",currency:"Swazi lilangeni",currencyCode:"SZL",currencyIcon:"L",internetCountryCode:"SZ"},{countryName:"Gabon",countryCode:"+241",currency:"Central African CFA franc",currencyCode:"XAF",currencyIcon:"Fr",internetCountryCode:"GA"},{countryName:"Ghana",countryCode:"+233",currency:"Ghanaian cedi",currencyCode:"GHS",currencyIcon:"\u20B5",internetCountryCode:"GH"},{countryName:"Guinea",countryCode:"+224",currency:"Guinean franc",currencyCode:"GNF",currencyIcon:"Fr",internetCountryCode:"GN"},{countryName:"Ivory Coast",countryCode:"+225",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"CI"},{countryName:"Kenya",countryCode:"+254",currency:"Kenyan shilling",currencyCode:"KES",currencyIcon:"Sh",internetCountryCode:"KE"},{countryName:"Lesotho",countryCode:"+266",currency:"Lesotho loti",currencyCode:"LSL",currencyIcon:"L",internetCountryCode:"LS"},{countryName:"Liberia",countryCode:"+231",currency:"Liberian dollar",currencyCode:"LRD",currencyIcon:"$",internetCountryCode:"LR"},{countryName:"Madagascar",countryCode:"+261",currency:"Malagasy ariary",currencyCode:"MGA",currencyIcon:"Ar",internetCountryCode:"MG"},{countryName:"Malawi",countryCode:"+265",currency:"Malawian kwacha",currencyCode:"MWK",currencyIcon:"MK",internetCountryCode:"MW"},{countryName:"Mali",countryCode:"+223",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"ML"},{countryName:"Mozambique",countryCode:"+258",currency:"Mozambican metical",currencyCode:"MZN",currencyIcon:"MT",internetCountryCode:"MZ"},{countryName:"Namibia",countryCode:"+264",currency:"Namibian dollar",currencyCode:"NAD",currencyIcon:"$",internetCountryCode:"NA"},{countryName:"Niger",countryCode:"+227",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"NE"},{countryName:"Nigeria",countryCode:"+234",currency:"Nigerian naira",currencyCode:"NGN",currencyIcon:"\u20A6",internetCountryCode:"NG"},{countryName:"Republic of the Congo",countryCode:"+242",currency:"Central African CFA franc",currencyCode:"XAF",currencyIcon:"Fr",internetCountryCode:"CG"},{countryName:"Rwanda",countryCode:"+250",currency:"Rwandan franc",currencyCode:"RWF",currencyIcon:"Fr",internetCountryCode:"RW"},{countryName:"Senegal",countryCode:"+221",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"SN"},{countryName:"Seychelles",countryCode:"+248",currency:"Seychellois rupee",currencyCode:"SCR",currencyIcon:"\u20A8",internetCountryCode:"SC"},{countryName:"South Africa",countryCode:"+27",currency:"South African rand",currencyCode:"ZAR",currencyIcon:"R",internetCountryCode:"ZA"},{countryName:"South Sudan",countryCode:"+211",currency:"South Sudanese pound",currencyCode:"SSP",currencyIcon:"\xA3",internetCountryCode:"SS"},{countryName:"Tanzania",countryCode:"+255",currency:"Tanzanian shilling",currencyCode:"TZS",currencyIcon:"Sh",internetCountryCode:"TZ"},{countryName:"Togo",countryCode:"+228",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"TG"},{countryName:"Uganda",countryCode:"+256",currency:"Ugandan shilling",currencyCode:"UGX",currencyIcon:"Sh",internetCountryCode:"UG"},{countryName:"Zambia",countryCode:"+260",currency:"Zambian kwacha",currencyCode:"ZMW",currencyIcon:"ZK",internetCountryCode:"ZM"}],oa=e=>{if(!e)return sl?.map(r=>({value:r?.internetCountryCode,label:r?.countryName,...r}));if(!e?.length)return[];let t=new Set;return e.reduce((r,o)=>(t.has(o.value)||(t.add(o.value),r.push(o)),r),[])};var ur=T(require("react")),zr=T(require("react-phone-number-input")),aa=T(require("react-phone-number-input/flags"));var ht=require("react/jsx-runtime"),ll=e=>(0,ht.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"none",...e,children:[(0,ht.jsx)("rect",{width:"32",height:"32",fill:"#60A5FA"})," ",(0,ht.jsx)("path",{d:"M3 10L7 8L10 9L13 8L16 10L19 9L22 11L25 10L28 12V15L26 17L28 19L27 22L29 24L27 26L24 25L21 26L18 24L15 25L12 23L9 24L6 22L4 23L2 21V18L4 16L3 13L5 11L3 10Z",fill:"#34D399"}),(0,ht.jsx)("rect",{x:"2",y:"28",width:"28",height:"3",fill:"#D1D5DB"}),(0,ht.jsx)("path",{d:"M0 16H32M8 0V32M16 0V32M24 0V32",stroke:"#2563EB",strokeWidth:"0.5",vectorEffect:"non-scaling-stroke"}),(0,ht.jsx)("path",{d:"M0 16H32",stroke:"#2563EB",strokeWidth:"1",vectorEffect:"non-scaling-stroke"})]}),na=ll;var O=require("react/jsx-runtime"),Ho=ur.forwardRef(({className:e,onChange:t,defaultCountry:r="NG",disableCountrySelect:o=!1,modal:n,showAsterisk:a,label:i,description:l,error:u,countryOptions:d,...p},m)=>{let c=g=>(0,O.jsx)(cl,{...g,status:p.status,modal:n,options:d||g?.options});return(0,O.jsxs)("div",{className:"relative space-y-1",children:[(0,O.jsx)(Y,{showAsterisk:a,error:u,children:i}),(0,O.jsx)(zr.default,{ref:m,className:s("flex sentry-mask",e),flagComponent:tt,countrySelectComponent:g=>(0,O.jsx)(c,{...g,disabled:g?.disabled||o}),inputComponent:ia,defaultCountry:r,onChange:g=>{t&&t?.(g)},...p}),(0,O.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:l}),(0,O.jsx)(Pe,{error:u})]})});Ho.displayName="PhoneInput";var ia=ur.forwardRef(({className:e,...t},r)=>(0,O.jsx)(de,{className:s("!rounded-s-none h-10",e),...t,ref:r}));ia.displayName="InputComponent";var cl=({disabled:e,value:t,onChange:r,options:o,status:n,modal:a})=>{let i=ur.useCallback(l=>{r(l)},[r]);return(0,O.jsxs)(Ne,{modal:a,children:[(0,O.jsx)(ee,{disabled:e,children:(0,O.jsxs)("div",{className:s(fe({status:n}),"transition justify-center items-center disabled:text-base-500 flex gap-3 h-10 rounded-e-none border-e-0 pl-2 pr-2"),children:[(0,O.jsx)(tt,{country:t,countryName:t}),(0,O.jsx)("svg",{className:s("mr-0.5 h-4 w-4 opacity-50",e?"hidden":"opacity-100"),width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",children:(0,O.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"#959595",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}),(0,O.jsx)(ge,{portal:!a,className:"w-[200px] md:w-[300px] p-0",children:(0,O.jsx)(nr,{children:(0,O.jsx)(ir,{children:(0,O.jsxs)(Ie,{className:"h-72",children:[(0,O.jsx)(ar,{placeholder:"Search country..."}),(0,O.jsx)(sr,{children:"No country found."}),(0,O.jsx)(lr,{children:o.filter(l=>l.value).map(l=>(0,O.jsxs)(cr,{className:"gap-2",onSelect:()=>i(l.value),children:[(0,O.jsx)(tt,{country:l.value,countryName:l.label}),(0,O.jsx)("span",{className:"flex-1 text-sm",children:l.label}),l.value&&(0,O.jsx)("span",{className:"text-[#191919]/50 text-sm dark:text-white",children:`+${zr.getCountryCallingCode(l.value)}`}),(0,O.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",className:s("ml-auto",l.value===t?"opacity-100":"opacity-0"),children:(0,O.jsx)("path",{d:"M4 8.00008L6.66353 10.6636L12 5.33655",stroke:"#959595",strokeWidth:"1.06667",strokeLinecap:"round",strokeLinejoin:"round"})})]},`${l.value}-${l.label}`))})]})})})})]})},tt=({country:e,countryName:t,className:r})=>{let o=aa.default[e];return e==="GLOBAL"?(0,O.jsx)("span",{className:s("bg-white/20 flex h-4 w-6 overflow-hidden rounded-sm",r),children:(0,O.jsx)(na,{className:"w-full h-[90%]"})}):(0,O.jsx)("span",{className:s("bg-white/20 flex h-4 w-6 overflow-hidden rounded-sm",r),children:o&&(0,O.jsx)(o,{title:t})})};tt.displayName="FlagComponent";var I=require("react/jsx-runtime"),dl=({className:e,value:t,placeholder:r="",status:o,disabled:n})=>(0,I.jsx)(ee,{asChild:!0,disabled:n,id:"country-dropdown",children:(0,I.jsxs)("button",{disabled:n,className:s(fe({status:o}),"[&>span]:justify-start [&>span]:items-center gap-2 flex w-full items-center justify-between goup",t?"":"text-[#79818C]",e),children:[t?(0,I.jsxs)("div",{className:"flex gap-2 items-center",children:[(0,I.jsx)(tt,{country:t?.value,countryName:t?.value,className:"ml-1 !w-6 h-5"}),(0,I.jsx)("span",{className:"",children:t?.label}),"-",(0,I.jsx)("span",{className:"",children:t?.value})]}):(0,I.jsx)("span",{children:r??"Select options..."}),(0,I.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",className:" data-[state=open]:goup-rotate-180",children:(0,I.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"currentColor",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}),da=la.memo(({item:e,onDelete:t})=>(0,I.jsxs)("p",{className:"text-xs pl-1.5 pr-1 py-1 bg-gray-100 rounded-md flex items-center gap-1",children:[(0,I.jsx)(tt,{country:e?.internetCountryCode||e?.value,countryName:e?.value,className:"!w-5 h-4"}),(0,I.jsx)("span",{children:e.label}),(0,I.jsx)("button",{type:"button",className:"pl-1",onClick:r=>{r.stopPropagation(),t(e)},children:(0,I.jsx)(ca.X,{size:12})})]}));da.displayName="CountryChip";var ul=({className:e,values:t,placeholder:r="",status:o,disabled:n,onDelete:a})=>(0,I.jsx)(ee,{asChild:!0,disabled:n,id:"country-dropdown",children:(0,I.jsxs)("div",{className:s(fe({status:o}),"cursor-pointer h-auto min-h-12 flex items-center justify-between w-full gap-2",e),children:[(0,I.jsx)("div",{className:"w-full flex flex-row items-center gap-2 flex-wrap",children:t.length?t.map(i=>(0,I.jsx)(da,{item:i,onDelete:a},i.value)):(0,I.jsx)("span",{className:"text-[#79818C]",children:r})}),(0,I.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",children:(0,I.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"currentColor",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}),sa=e=>(0,I.jsxs)("div",{className:"w-full flex items-center gap-2",children:[(0,I.jsx)(tt,{country:e?.internetCountryCode||e?.value,countryName:e?.label,className:"ml-2 !w-6 !h-5"}),(0,I.jsxs)("div",{className:"flex-1 flex items-center gap-2",children:[(0,I.jsx)("span",{className:"flex text-sm",children:e?.label}),"-",(0,I.jsx)("span",{className:"text-sm",children:e?.internetCountryCode})]})]}),ua=e=>{let{hideSearch:t=!0,showAsterisk:r,label:o,description:n,error:a,countryOptions:i=void 0}=e,l=oa(i);if(e.multiSelect){let{value:c,onChange:g,placeholder:x,status:h,disabled:v,loading:f,modal:N,className:P,optionComponent:w}=e,L=c??[];return(0,I.jsxs)("div",{className:"relative space-y-1",children:[(0,I.jsx)(Y,{showAsterisk:r,error:a,children:o}),(0,I.jsx)(_r,{options:l,values:L,onChange:b=>g(b),hideSearch:t,modal:N,isLoading:f,placeholder:x??"Select Country",optionComponent:w??sa,children:(0,I.jsx)(ul,{values:L,status:h,disabled:v,className:P,placeholder:x??"Select Country",onDelete:b=>{g(L.filter(D=>D.value!==b.value))}})}),(0,I.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:n}),(0,I.jsx)(Pe,{error:a})]})}let{value:u,onChange:d,...p}=e,m=l?.find(c=>(c?.value||c?.internetCountryCode)===u?.value);return(0,I.jsxs)("div",{className:"relative space-y-1",children:[(0,I.jsx)(Y,{showAsterisk:r,error:a,children:o}),(0,I.jsx)(Vr,{options:l,hideSearch:t,optionComponent:sa,value:u,onChange:d,...p,children:(0,I.jsx)(dl,{value:m,status:p?.status,placeholder:p?.placeholder??" Select Country"})}),(0,I.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:n}),(0,I.jsx)(Pe,{error:a})]})};var vt=require("react/jsx-runtime"),it=({showAsterisk:e,label:t,description:r,error:o,hideSearch:n=!1,status:a,...i})=>(0,vt.jsxs)("div",{className:"relative space-y-1",children:[(0,vt.jsx)(Y,{showAsterisk:e,error:o,children:t}),(0,vt.jsx)(Vr,{hideSearch:n,...i,containerClassName:"h-full",children:(0,vt.jsx)(Jn,{disabled:i?.disabled,placeholder:i?.placeholder??"Select",status:a,value:i?.value?.label??i?.value?.value,className:i?.className,id:i?.id})}),(0,vt.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:r}),(0,vt.jsx)(Pe,{error:o})]});var pa=require("class-variance-authority"),ma=require("react"),fa=T(require("react-otp-input")),$o=require("react/jsx-runtime"),pl=(0,pa.cva)("transition cursor-default placeholder:text-black dark:placeholder:text-white rounded-lg !h-14 !w-14 border aspect-square text-base font-semibold tracking-normal outline-none placeholder:text-sm placeholder:font-normal text-black focus:bg-white flex-shrink-0",{variants:{status:{default:"border-gray-300 dark:border-[#d4d4d4] focus:border-gray-400 focus-visible:!ring-offset-gray-200 focus:ring-offset-gray-200 !ring-gray-200 !focus-visible:ring-1 bg-white dark:!bg-transparent dark:focus-visible:!ring-0 dark:focus-within:!bg-transparent dark:text-white dark:focus-within:border-[#9299A2] dark:border-[#676767] dark:disabled:!border-[#9299A2]",error:"placeholder:text-red-600 bg-red-50 border-red-600 text-red-600 focus-within:bg-red-50 focus-within:border-red-600",loading:"placeholder:text-[#C4C4C4]"}},defaultVariants:{status:"default"}}),ga=({numInputs:e=4,inputStyle:t,containerStyle:r,placeholder:o="-",status:n,inputMode:a="numeric",inputType:i="number",...l})=>{let u=(0,ma.useMemo)(()=>o||new Array(e).fill("").reduce((m,c)=>m+=c,""),[e,o]);return(0,$o.jsx)(fa.default,{numInputs:e,placeholder:u,containerStyle:s("w-fit sentry-mask flex justify-between",r),inputStyle:s(pl({status:n}),t,"sentry-mask"),renderInput:d=>(0,$o.jsx)("input",{...d,inputMode:a,type:i}),inputType:i,...l})};var rt=T(require("@radix-ui/react-accordion")),ha=require("lucide-react");var st=require("react/jsx-runtime");function va({items:e,type:t="single",defaultValue:r,onChange:o,className:n}){return(0,st.jsx)(rt.Root,{...t==="single"?{type:"single",collapsible:!0,defaultValue:r,onValueChange:o}:{type:"multiple",defaultValue:r,onValueChange:o},className:s("w-full flex flex-col gap-2.5",n),children:e.map(i=>(0,st.jsxs)(rt.Item,{value:i.key,className:"border border-gray-300 rounded-md overflow-hidden",children:[(0,st.jsx)(rt.Header,{className:"flex",children:(0,st.jsxs)(rt.Trigger,{className:"group flex flex-1 items-center justify-between px-4 py-3 text-sm font-medium text-gray-800 hover:bg-gray-200/50 transition-all data-[state=open]:bg-gray-200/50",children:[i.title,(0,st.jsx)(ha.ChevronDown,{className:"h-4 w-4 shrink-0 text-gray-500 transition-transform duration-200 group-data-[state=open]:rotate-180"})]})}),(0,st.jsx)(rt.Content,{className:"overflow-hidden data-[state=open]:animate-accordion-down data-[state=closed]:animate-accordion-up",children:(0,st.jsx)("div",{className:"px-4 py-3 border-t border-gray-300",children:i.content})})]},i.key))})}var Wr=require("react"),z=require("react/jsx-runtime"),ml=({type:e})=>e==="gray"?(0,z.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M10 0C4.49 0 0 4.49 0 10C0 15.51 4.49 20 10 20C15.51 20 20 15.51 20 10C20 4.49 15.51 0 10 0ZM14.78 7.7L9.11 13.37C8.97 13.51 8.78 13.59 8.58 13.59C8.38 13.59 8.19 13.51 8.05 13.37L5.22 10.54C4.93 10.25 4.93 9.77 5.22 9.48C5.51 9.19 5.99 9.19 6.28 9.48L8.58 11.78L13.72 6.64C14.01 6.35 14.49 6.35 14.78 6.64C15.07 6.93 15.07 7.4 14.78 7.7Z",fill:"#79818C"})}):e==="info"?(0,z.jsx)("svg",{stroke:"#70B6F6",fill:"#70B6F6",strokeWidth:"0",viewBox:"0 0 16 16",height:"24",width:"24",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16m.93-9.412-1 4.705c-.07.34.029.533.304.533.194 0 .487-.07.686-.246l-.088.416c-.287.346-.92.598-1.465.598-.703 0-1.002-.422-.808-1.319l.738-3.468c.064-.293.006-.399-.287-.47l-.451-.081.082-.381 2.29-.287zM8 5.5a1 1 0 1 1 0-2 1 1 0 0 1 0 2"})}):e==="warning"?(0,z.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M9.99984 1.66663C5.40817 1.66663 1.6665 5.40829 1.6665 9.99996C1.6665 14.5916 5.40817 18.3333 9.99984 18.3333C14.5915 18.3333 18.3332 14.5916 18.3332 9.99996C18.3332 5.40829 14.5915 1.66663 9.99984 1.66663ZM9.37484 6.66663C9.37484 6.32496 9.65817 6.04163 9.99984 6.04163C10.3415 6.04163 10.6248 6.32496 10.6248 6.66663V10.8333C10.6248 11.175 10.3415 11.4583 9.99984 11.4583C9.65817 11.4583 9.37484 11.175 9.37484 10.8333V6.66663ZM10.7665 13.65C10.7248 13.7583 10.6665 13.8416 10.5915 13.925C10.5082 14 10.4165 14.0583 10.3165 14.1C10.2165 14.1416 10.1082 14.1666 9.99984 14.1666C9.8915 14.1666 9.78317 14.1416 9.68317 14.1C9.58317 14.0583 9.4915 14 9.40817 13.925C9.33317 13.8416 9.27484 13.7583 9.23317 13.65C9.1915 13.55 9.1665 13.4416 9.1665 13.3333C9.1665 13.225 9.1915 13.1166 9.23317 13.0166C9.27484 12.9166 9.33317 12.825 9.40817 12.7416C9.4915 12.6666 9.58317 12.6083 9.68317 12.5666C9.88317 12.4833 10.1165 12.4833 10.3165 12.5666C10.4165 12.6083 10.5082 12.6666 10.5915 12.7416C10.6665 12.825 10.7248 12.9166 10.7665 13.0166C10.8082 13.1166 10.8332 13.225 10.8332 13.3333C10.8332 13.4416 10.8082 13.55 10.7665 13.65Z",fill:"#FFC700"})}):e==="success"?(0,z.jsx)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M12 2C6.49 2 2 6.49 2 12C2 17.51 6.49 22 12 22C17.51 22 22 17.51 22 12C22 6.49 17.51 2 12 2ZM16.78 9.7L11.11 15.37C10.97 15.51 10.78 15.59 10.58 15.59C10.38 15.59 10.19 15.51 10.05 15.37L7.22 12.54C6.93 12.25 6.93 11.77 7.22 11.48C7.51 11.19 7.99 11.19 8.28 11.48L10.58 13.78L15.72 8.64C16.01 8.35 16.49 8.35 16.78 8.64C17.07 8.93 17.07 9.4 16.78 9.7Z",fill:"#00D488"})}):(0,z.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M9.99984 1.66663C5.40817 1.66663 1.6665 5.40829 1.6665 9.99996C1.6665 14.5916 5.40817 18.3333 9.99984 18.3333C14.5915 18.3333 18.3332 14.5916 18.3332 9.99996C18.3332 5.40829 14.5915 1.66663 9.99984 1.66663ZM9.37484 6.66663C9.37484 6.32496 9.65817 6.04163 9.99984 6.04163C10.3415 6.04163 10.6248 6.32496 10.6248 6.66663V10.8333C10.6248 11.175 10.3415 11.4583 9.99984 11.4583C9.65817 11.4583 9.37484 11.175 9.37484 10.8333V6.66663ZM10.7665 13.65C10.7248 13.7583 10.6665 13.8416 10.5915 13.925C10.5082 14 10.4165 14.0583 10.3165 14.1C10.2165 14.1416 10.1082 14.1666 9.99984 14.1666C9.8915 14.1666 9.78317 14.1416 9.68317 14.1C9.58317 14.0583 9.4915 14 9.40817 13.925C9.33317 13.8416 9.27484 13.7583 9.23317 13.65C9.1915 13.55 9.1665 13.4416 9.1665 13.3333C9.1665 13.225 9.1915 13.1166 9.23317 13.0166C9.27484 12.9166 9.33317 12.825 9.40817 12.7416C9.4915 12.6666 9.58317 12.6083 9.68317 12.5666C9.88317 12.4833 10.1165 12.4833 10.3165 12.5666C10.4165 12.6083 10.5082 12.6666 10.5915 12.7416C10.6665 12.825 10.7248 12.9166 10.7665 13.0166C10.8082 13.1166 10.8332 13.225 10.8332 13.3333C10.8332 13.4416 10.8082 13.55 10.7665 13.65Z",fill:"#F04248"})}),ba=({type:e="info",title:t,description:r,open:o,showCloseButton:n,bottomNode:a,sideNode:i,onClose:l,showIcon:u=!0})=>{let[d,p]=(0,Wr.useState)(o);(0,Wr.useEffect)(()=>{p(o)},[o]);let m="",c="";switch(e){case"gray":m="#eeeef0",c="#79818c";break;case"info":m="#ebf5fd",c="#70B6F6";break;case"warning":m="#fff8df",c="#ffc700";break;case"success":m="#e0f9f0",c="#49e0aa";break;case"danger":m="#fde8e9",c="#f3777c";break;default:m="#eeeef0",c="#79818c";break}function g(){p(!1),l&&l()}return d?(0,z.jsxs)("div",{className:"w-full shadow-lg transform flex items-center rounded-md",style:{background:m||"#ebf5fd"},children:[(0,z.jsx)("div",{className:"flex-none absolute rounded-l-[2px] rounded-l-4px h-[4px] w-full top-0",style:{background:c||"#70B6F6"}}),(0,z.jsxs)("div",{className:"w-full gap-3 h-full flex flex-row justify-between px-4 md:px-4 py-3 md:py-4",children:[(0,z.jsxs)("div",{className:"flex flex-row gap-2.5 items-start w-full h-full",children:[u&&(0,z.jsx)("div",{className:"h-full flex justify-end",children:(0,z.jsx)(ml,{type:e})}),(0,z.jsxs)("div",{className:"w-full gap-3 h-full flex flex-col md:flex-row items-start justify-between",children:[(0,z.jsxs)("div",{className:"flex-1 gap-3 h-full flex flex-col items-start justify-between",children:[(t||r)&&(0,z.jsxs)("div",{children:[t&&(0,z.jsx)("div",{className:"text-sm font-bold text-[#191919]",children:t}),r&&(0,z.jsx)("div",{className:"text-sm font-normal text-[#5D5D5D] mt-1",children:r})]}),a]}),i]})]}),n&&(0,z.jsx)("div",{className:"w-1/10 h-full flex flex-col justify-start items-center",children:(0,z.jsx)("button",{onClick:g,children:(0,z.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,z.jsx)("path",{d:"M3.3335 3.33337L12.6662 12.6661",stroke:"#191919",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,z.jsx)("path",{d:"M3.33429 12.6661L12.667 3.33337",stroke:"#191919",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]})})})]})]}):null};var Ca=require("react"),Gr=require("lucide-react"),Ur=require("framer-motion");var ya=require("react/jsx-runtime"),Lt=({children:e,mode:t="truncate",className:r,as:o="div",...n})=>(0,ya.jsx)(o,{className:s({"text-ellipsis overflow-hidden whitespace-nowrap":t==="truncate","whitespace-normal break-words":t==="wrap","":t==="overflow"},r),target:n?.href?"_blank":void 0,...n,children:e});var lt=require("react/jsx-runtime"),xa=({text:e,textToCopy:t,onCopy:r,iconsPosition:o="right",clampText:n=!0,clampMode:a="truncate",isLink:i=!1,textClassName:l})=>{let[u,d]=(0,Ca.useState)(!1),p=()=>{navigator.clipboard.writeText(t??e).then(()=>{d(!0),r?.(),setTimeout(()=>d(!1),2e3)})},m=u?Gr.CheckIcon:Gr.Copy;return(0,lt.jsxs)("div",{className:"flex items-center space-x-2 cursor-pointer text-[#717171] bg-gray-100 w-fit max-w-full rounded-md p-1 px-2",children:[o==="left"&&(0,lt.jsx)(wa,{Icon:m,onClick:p,copied:u}),(0,lt.jsx)(Lt,{as:i?"a":"span",mode:n?a:"overflow",className:s({underline:i},l),href:i?e:void 0,children:e}),o==="right"&&(0,lt.jsx)(wa,{Icon:m,onClick:p,copied:u})]})},wa=({Icon:e,onClick:t,copied:r})=>(0,lt.jsx)(Ur.AnimatePresence,{mode:"wait",children:(0,lt.jsx)(Ur.motion.div,{initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2},onClick:t,children:(0,lt.jsx)(e,{className:`w-5 h-5 ${r?"text-green-500":"text-gray-500 hover:text-gray-700 transition"}`})},r?"check":"copy")});var pr=require("react");var Na=require("lucide-react"),_o=require("react/jsx-runtime"),Zr=({value:e,onChange:t,debounce:r=500,addon:o,...n})=>{let[a,i]=(0,pr.useState)(e??""),l=u=>i(u.target.value);return(0,pr.useEffect)(()=>{e&&i(e)},[e]),(0,pr.useEffect)(()=>{let u=setTimeout(()=>{t(a)},r);return()=>clearTimeout(u)},[a,r,t]),(0,_o.jsx)(de,{leftNode:o??(0,_o.jsx)(Na.Search,{className:" w-4 h-4 text-gray-400"}),sideNodeClassName:"bg-transparent !pr-0 !w-4 border-0 !min-w-[40px]",...n,className:s("!pl-0 py-1 border-[.5px] border-[#E9EBF8] rounded-xl text-sm w-full h-8 focus:outline-none focus:placeholder:hidden focus:!ring-2 !focus:ring-primary-main bg-[#F5F8FF] focus-within:!bg-transparent placeholder:text-xs",n?.className),onChange:l,value:a})};var zo=require("react"),Ra=require("lucide-react"),se=require("react/jsx-runtime"),Pa=e=>{let{environment:t,branch:r,version:o,deployTime:n,showBanner:a,onClose:i,initDefault:l,removeFromStorage:u,syncLocalStorageToState:d}=e,p=t||process.env.NEXT_PUBLIC_NODE_ENV;return p!=="staging"&&p!=="sandbox"||((0,zo.useEffect)(()=>{d()},[d]),(0,zo.useEffect)(()=>{let m;return(p==="staging"||p==="sandbox")&&(m=setInterval(()=>{u(),l()},300*1e3)),()=>{m&&clearInterval(m)}},[a,t,i,u,l,p]),!a)?null:(0,se.jsxs)("div",{className:"w-fit p-4 border shadow-md bg-white rounded-md z-[99999] absolute top-2 right-2 min-w-96",children:[(0,se.jsx)("button",{onClick:i,className:"absolute top-2 right-2",children:(0,se.jsx)(Ra.X,{})}),(0,se.jsxs)("div",{className:"space-y-2 text-sm",children:[(0,se.jsxs)("div",{className:"flex gap-2",children:[(0,se.jsx)("span",{className:"font-medium",children:"Environment:"}),(0,se.jsx)("span",{className:"text-blue-600 capitalize",children:p})]}),(0,se.jsxs)("div",{className:"flex gap-2",children:[(0,se.jsx)("span",{className:"font-medium",children:"Branch:"}),(0,se.jsx)("span",{className:"text-green-600 capitalize",children:r||process.env.NEXT_PUBLIC_DEPLOY_BRANCH})]}),(0,se.jsxs)("div",{className:"flex gap-2",children:[(0,se.jsx)("span",{className:"font-medium",children:"Version:"}),(0,se.jsx)("span",{className:"text-purple-600",children:o||process.env.NEXT_PUBLIC_DEPLOY_VERSION})]}),(0,se.jsxs)("div",{className:"flex gap-2",children:[(0,se.jsx)("span",{className:"font-medium",children:"Deploy Time:"}),(0,se.jsx)("span",{className:"text-orange-600",children:n||process.env.NEXT_PUBLIC_DEPLOY_TIME})]})]})]})};var Za=require("class-variance-authority"),hr=T(require("react"));var he=T(require("@radix-ui/react-dialog"),1),Ta=T(require("react"),1),C=T(require("react"),1);function fl(e){if(!e||typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}var Fa=C.default.createContext({drawerRef:{current:null},overlayRef:{current:null},onPress:()=>{},onRelease:()=>{},onDrag:()=>{},onNestedDrag:()=>{},onNestedOpenChange:()=>{},onNestedRelease:()=>{},openProp:void 0,dismissible:!1,isOpen:!1,isDragging:!1,keyboardIsOpen:{current:!1},snapPointsOffset:null,snapPoints:null,handleOnly:!1,modal:!1,shouldFade:!1,activeSnapPoint:null,onOpenChange:()=>{},setActiveSnapPoint:()=>{},closeDrawer:()=>{},direction:"bottom",shouldAnimate:{current:!0},shouldScaleBackground:!1,setBackgroundColorOnScale:!0,noBodyStyles:!1,container:null,autoFocus:!1}),Bt=()=>{let e=C.default.useContext(Fa);if(!e)throw new Error("useDrawerContext must be used within a Drawer.Root");return e};fl(`[data-vaul-drawer]{touch-action:none;will-change:transform;transition:transform .5s cubic-bezier(.32, .72, 0, 1);animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=open]{animation-name:slideFromBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=closed]{animation-name:slideToBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=open]{animation-name:slideFromTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=closed]{animation-name:slideToTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=open]{animation-name:slideFromLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=closed]{animation-name:slideToLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=open]{animation-name:slideFromRight}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=closed]{animation-name:slideToRight}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--initial-transform,100%),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--initial-transform,100%),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-overlay][data-vaul-snap-points=false]{animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=false][data-state=open]{animation-name:fadeIn}[data-vaul-overlay][data-state=closed]{animation-name:fadeOut}[data-vaul-animate=false]{animation:none!important}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:0;transition:opacity .5s cubic-bezier(.32, .72, 0, 1)}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:1}[data-vaul-drawer]:not([data-vaul-custom-container=true])::after{content:'';position:absolute;background:inherit;background-color:inherit}[data-vaul-drawer][data-vaul-drawer-direction=top]::after{top:initial;bottom:100%;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=bottom]::after{top:100%;bottom:initial;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=left]::after{left:initial;right:100%;top:0;bottom:0;width:200%}[data-vaul-drawer][data-vaul-drawer-direction=right]::after{left:100%;right:initial;top:0;bottom:0;width:200%}[data-vaul-overlay][data-vaul-snap-points=true]:not([data-vaul-snap-points-overlay=true]):not(
|
|
1
|
+
"use strict";"use client";var Us=Object.create;var Yt=Object.defineProperty;var Zs=Object.getOwnPropertyDescriptor;var Ks=Object.getOwnPropertyNames;var js=Object.getPrototypeOf,Ys=Object.prototype.hasOwnProperty;var Xs=(e,t,r)=>t in e?Yt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var qs=(e,t)=>{for(var r in t)Yt(e,r,{get:t[r],enumerable:!0})},wn=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Ks(t))!Ys.call(e,n)&&n!==r&&Yt(e,n,{get:()=>t[n],enumerable:!(o=Zs(t,n))||o.enumerable});return e};var T=(e,t,r)=>(r=e!=null?Us(js(e)):{},wn(t||!e||!e.__esModule?Yt(r,"default",{value:e,enumerable:!0}):r,e)),Js=e=>wn(Yt({},"__esModule",{value:!0}),e);var Fr=(e,t,r)=>Xs(e,typeof t!="symbol"?t+"":t,r);var lc={};qs(lc,{Accordion:()=>va,AmountAction:()=>xo,Banner:()=>ba,Button:()=>ce,CalendarInput:()=>io,CopyableLabel:()=>xa,Country:()=>ua,CurrencySymbolMap:()=>Co,DateAction:()=>No,DebouncedInput:()=>Zr,DevBanner:()=>Pa,Dialog:()=>Br,Drawer:()=>ei,DrawerClose:()=>Ka,DrawerRoot:()=>Xr,FeatureBanner:()=>cs,FilterPopover:()=>po,FlagComponent:()=>tt,FormLabel:()=>Y,HasResourcePermission:()=>os,Input:()=>de,Loader:()=>Ve,LocaleSelector:()=>ii,MultiSelect:()=>_r,MultiSelectTrigger:()=>$r,OTPInput:()=>ga,PageDataToolbar:()=>mo,Pagination:()=>no,PasswordInput:()=>Ao,PermissionsContext:()=>wr,PermissionsProvider:()=>bi,PhoneInput:()=>Ho,Popover:()=>Me,PopoverContent:()=>ge,PopoverRoot:()=>Ne,PopoverTrigger:()=>ee,RadioGroup:()=>Rr,RadioGroupItem:()=>Pr,RichTextEditor:()=>Ds,ScrollArea:()=>Ie,Select:()=>it,Sidebar:()=>Ri,SplitButton:()=>ko,Status:()=>Pi,StringAction:()=>Ar,Table:()=>rs,Tabs:()=>ns,TagsInput:()=>Ts,TextOverflow:()=>Lt,Textarea:()=>Mo,Tooltip:()=>qt,TooltipContent:()=>Mr,TooltipProvider:()=>Ro,TooltipRoot:()=>Po,TooltipTrigger:()=>Do,buttonVariants:()=>me,cn:()=>s,useFilterStore:()=>co,useHasPermission:()=>$t,usePermissions:()=>Jo});module.exports=Js(lc);var Co={USD:"$",CAD:"CA$",EUR:"\u20AC",AED:"AED",AFN:"Af",ALL:"ALL",AMD:"AMD",ARS:"AR$",AUD:"AU$",AZN:"man.",BAM:"KM",BDT:"Tk",BGN:"BGN",BHD:"BD",BIF:"FBu",BND:"BN$",BOB:"Bs",BRL:"R$",BWP:"BWP",BYN:"Br",BZD:"BZ$",CDF:"CDF",CHF:"CHF",CLP:"CL$",CNY:"CN\xA5",COP:"CO$",CRC:"\u20A1",CVE:"CV$",CZK:"K\u010D",DJF:"Fdj",DKK:"Dkr",DOP:"RD$",DZD:"DA",EEK:"Ekr",EGP:"EGP",ERN:"Nfk",ETB:"Br",GBP:"\xA3",GEL:"GEL",GHS:"GH\u20B5",GNF:"FG",GTQ:"GTQ",HKD:"HK$",HNL:"HNL",HRK:"kn",HUF:"Ft",IDR:"Rp",ILS:"\u20AA",INR:"\u20B9",IQD:"IQD",IRR:"IRR",ISK:"Ikr",JMD:"J$",JOD:"JD",JPY:"\xA5",KES:"Ksh",KHR:"KHR",KMF:"CF",KRW:"\u20A9",KWD:"KD",KZT:"KZT",LBP:"L.L.",LKR:"SLRs",LTL:"Lt",LVL:"Ls",LYD:"LD",MAD:"MAD",MDL:"MDL",MGA:"MGA",MKD:"MKD",MMK:"MMK",MOP:"MOP$",MUR:"MURs",MXN:"MX$",MYR:"RM",MZN:"MTn",NAD:"N$",NGN:"\u20A6",NIO:"C$",NOK:"Nkr",NPR:"NPRs",NZD:"NZ$",OMR:"OMR",PAB:"B/.",PEN:"S/.",PHP:"\u20B1",PKR:"PKRs",PLN:"z\u0142",PYG:"\u20B2",QAR:"QR",RON:"RON",RSD:"din.",RUB:"RUB",RWF:"RWF",SAR:"SR",SDG:"SDG",SEK:"Skr",SGD:"S$",SOS:"Ssh",SYP:"SY\xA3",THB:"\u0E3F",TND:"DT",TOP:"T$",TRY:"TL",TTD:"TT$",TWD:"NT$",TZS:"TSh",UAH:"\u20B4",UGX:"USh",UYU:"$U",UZS:"UZS",VEF:"Bs.F.",VND:"\u20AB",XAF:"F CFA",XOF:"CFA",YER:"YR",ZAR:"R",ZMK:"ZK",ZWL:"ZWL$"},Xt=class Xt{static getCurrencyLocaleMap(t){return{XOF:"fr",XAF:"fr"}[t]||"en"}static koboToNaira(t){return+t/100}static nairaToKobo(t){return+t*100}static getCurrencySymbol(t){return Co[t]||t}};Fr(Xt,"formatAmountAndCurrency",(t,r,o)=>{let n=new Intl.NumberFormat(o?.locale||Xt.getCurrencyLocaleMap(t),{maximumFractionDigits:2,style:"currency",currency:t,currencyDisplay:"symbol"}).format(o?.convertToMajorCurrency?Xt.koboToNaira(Number(r)):Number(r)).replace(/^(\D+)/,"$1 ").replace("\u202F"," ").replace(/\s+/,""),a=Co[t]||t;return n.replace(t,a)});var xo=Xt;var Er=T(require("dayjs")),No=class{static getDateLibrary(){return(0,Er.default)()}static formatTimestampToDate(t,r){return Er.default.unix(t).format(r||"ddd, MMM, YYYY | HH:mm:ss")}static formatDateToTimestamp(t){return(0,Er.default)(t).unix()}};var Ar=class{static capitalizeFirstWord(t){return t.charAt(0).toUpperCase()+t.slice(1)}static capitalizeEachWord(t){return t.split(" ").map(r=>r.charAt(0).toUpperCase()+r.slice(1)).join(" ")}};Fr(Ar,"sanitizeString",({str:t,allowedChars:r})=>{if(!r)return t.replace(/[^a-zA-Z0-9\s]/g,"");let o=r.map(a=>["^","$",".","*","+","?","(",")","[","]","{","}","|","\\","-"].includes(a)?"\\"+a:a),n=new RegExp(`[^a-zA-Z0-9${o.join("")}]`,"g");return t.replace(n,"")});var Nn=T(require("react")),Ee=T(require("@radix-ui/react-tooltip"));var Cn=require("clsx"),xn=require("tailwind-merge");function s(...e){return(0,xn.twMerge)((0,Cn.clsx)(e))}var et=require("react/jsx-runtime"),Ro=Ee.Provider,Po=Ee.Root,Do=Ee.Trigger,Mr=Nn.forwardRef(({className:e,sideOffset:t=2,...r},o)=>(0,et.jsx)(Ee.Portal,{children:(0,et.jsx)(Ee.Content,{ref:o,sideOffset:t,className:s("z-50 rounded-md border border-transparent bg-gray-50 px-3 py-1.5 text-base font-semibold text-bold text-black/40 shadow-xl- animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-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 [box-shadow:3px_4px_11px_0px_#0000001A,13px_16px_21px_0px_#00000017,29px_36px_28px_0px_#0000000D,52px_65px_33px_0px_#00000003,82px_101px_36px_0px_#00000000]",e),...r,children:r.children})}));Mr.displayName=Ee.Content.displayName;var qt=({trigger:e,children:t,contentClassName:r,triggerClassName:o,asChild:n=!0,side:a,sideOffset:i,align:l,alignOffset:u,delayDuration:d=100,hasArrow:p=!0,arrowClassName:m,...c})=>(0,et.jsx)(Ro,{children:(0,et.jsx)(Po,{delayDuration:d,...c,children:(0,et.jsxs)("div",{className:"flex justify-center items-center",children:[(0,et.jsx)(Do,{asChild:n,className:o,children:e}),(0,et.jsxs)(Mr,{side:a,sideOffset:i,align:l,alignOffset:u,className:r,children:[t,p&&(0,et.jsx)(Ee.Arrow,{className:s("fill-white",m)})]})]})})});qt.displayName="Tooltip";var Sn=T(require("react"));var Rn=T(require("react")),So=T(require("@radix-ui/react-label")),Pn=require("class-variance-authority");var Dn=require("react/jsx-runtime"),Qs=(0,Pn.cva)("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Lo=Rn.forwardRef(({className:e,...t},r)=>(0,Dn.jsx)(So.Root,{ref:r,className:s(Qs(),e),...t}));Lo.displayName=So.Root.displayName;var Jt=require("react/jsx-runtime"),Y=Sn.default.forwardRef(({className:e,children:t,showAsterisk:r,error:o,...n},a)=>(0,Jt.jsx)(Lo,{ref:a,className:s(o&&"text-red-500",e),...n,children:r?(0,Jt.jsxs)("p",{children:[t,(0,Jt.jsx)("span",{className:"text-red-500",children:"*"})]}):t}));Y.displayName="FormLabel";var Qt=require("react/jsx-runtime"),Ve=({size:e=16,colour:t="primary"})=>(0,Qt.jsxs)("svg",{className:"animate-spin",width:e,height:e,viewBox:"0 0 20 20",fill:"none",children:[(0,Qt.jsx)("circle",{cx:"10",cy:"10",r:"9.25",stroke:"transparent",strokeWidth:"1.5"}),(0,Qt.jsx)("path",{d:"M10 0.595792C10 0.266746 10.267 -0.00185055 10.5954 0.0177417C11.9786 0.100242 13.3318 0.469461 14.5682 1.1044C15.9816 1.83021 17.2016 2.88235 18.1273 4.17366C19.0531 5.46496 19.6578 6.95826 19.8913 8.52984C20.1249 10.1014 19.9807 11.706 19.4705 13.2108C18.9604 14.7155 18.0991 16.077 16.9579 17.1825C15.8167 18.288 14.4285 19.1056 12.9084 19.5677C11.3882 20.0298 9.77982 20.123 8.21646 19.8397C6.84883 19.5918 5.55009 19.0619 4.40196 18.2863C4.12931 18.1021 4.08072 17.7265 4.28083 17.4653C4.48094 17.2041 4.85388 17.1564 5.12801 17.3384C6.12474 18.0001 7.24768 18.4531 8.42898 18.6672C9.80606 18.9168 11.2228 18.8347 12.5618 18.4276C13.9008 18.0206 15.1236 17.3004 16.1288 16.3266C17.134 15.3528 17.8927 14.1536 18.342 12.8282C18.7914 11.5027 18.9185 10.0893 18.7127 8.70502C18.507 7.32071 17.9743 6.00535 17.1589 4.86792C16.3435 3.73048 15.2688 2.80371 14.0238 2.16439C12.9559 1.61596 11.789 1.29259 10.5954 1.21173C10.2671 1.18949 10 0.92484 10 0.595792Z",fill:t==="primary"?"#ffffff":"currentColor",className:"rounded"})]});var Ln=T(require("react")),kn=require("@radix-ui/react-slot"),Tn=require("class-variance-authority");var He=require("react/jsx-runtime"),me=(0,Tn.cva)("overflow-hidden isolate inline-flex h-fit items-center justify-center whitespace-nowrap text-sm font-medium ring-offset-background dark:ring-offset-transparent transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:!pointer-events-none",{variants:{variant:{primary:"border-primary-main bg-primary-main hover:bg-primary-main/70 disabled:bg-primary-main/70 text-white font-bold",danger:"border-red-600 bg-red-600 hover:bg-red-600/70 disabled:bg-red-600/70 text-white font-bold",neutral:"!border-0 bg-transparent text-primary-main hover:opacity-80 disabled:opacity-60",outlined:"border border-primary-main text-primary-main hover:opacity-80 disabled:opacity-60","danger-outlined":"border border-red-600 text-red-600 hover:opacity-80 disabled:opacity-60","light-outlined":"border-white text-white hover:opacity-80 disabled:opacity-60","dark-text":"border-transparent bg-transparent hover:bg-opacity-70 disabled:bg-opacity-70 text-black font-medium",light:"border-white bg-white hover:bg-opacity-70 disabled:bg-opacity-70 text-primary-main font-semibold"},size:{default:"py-[0.625rem] px-[1.5rem] text-[0.875rem] leading-[1.25rem] font-medium rounded-lg",sm:"py-[0.375rem] px-[1rem] leading-[1rem] font-normal text-sm rounded-lg",lg:"py-[0.75rem] px-[1.5rem] text-[1rem] leading-[1.5rem] font-medium rounded-lg",md:"py-[0.625rem] px-[1.5rem] text-[0.875rem] leading-[1.25rem] font-medium rounded-lg","icon-sm":"h-[1.75rem] w-[1.75rem] flex justify-center items-center font-medium rounded-lg",icon:"h-[2.5rem] w-[2.75rem] flex justify-center items-center font-medium rounded-lg","icon-lg":"h-[3rem] w-[3rem] flex justify-center items-center font-medium rounded-lg"}},defaultVariants:{variant:"primary",size:"default"}}),ce=Ln.forwardRef(({className:e,variant:t="primary",size:r,asChild:o=!1,isLoading:n=!1,leftNode:a,rightNode:i,LoaderSize:l,children:u,disabled:d,...p},m)=>(0,He.jsx)(o?kn.Slot:"button",{className:s(me({variant:t,size:r,className:e})),ref:m,disabled:d||n,...p,children:(0,He.jsx)("div",{className:"flex font-medium justify-center items-center gap-2 pointer-events-none",children:n?(0,He.jsx)("span",{className:"mx-auto",children:(0,He.jsx)(Ve,{size:l,colour:"secondary"})}):(0,He.jsxs)(He.Fragment,{children:[a&&(0,He.jsx)("span",{children:a}),u&&(0,He.jsx)("span",{children:u}),i&&(0,He.jsx)("span",{children:i})]})})}));ce.displayName="Button";var $e=T(require("@radix-ui/react-dropdown-menu")),Fn=require("lucide-react"),En=T(require("react"));var Ce=require("react/jsx-runtime"),el=me,ko=({items:e,variant:t="primary",size:r,isLoading:o=!1,leftNode:n,children:a,disabled:i,className:l,buttonClassName:u,triggerClassName:d,contentClassName:p,itemClassName:m,menuAlign:c="end",menuSide:g="bottom",menuTriggerLabel:x="More options",open:h,onOpenChange:v,modal:f=!1,id:N="split-button",...P})=>(0,Ce.jsxs)("div",{className:s("inline-flex",l),id:N,children:[(0,Ce.jsx)(ce,{type:"button",variant:t,size:r,isLoading:o,leftNode:n,disabled:i,className:s("!rounded-r-none",u),id:`${N}-action`,...P,children:a}),(0,Ce.jsxs)($e.Root,{open:h,onOpenChange:v,modal:f,children:[(0,Ce.jsx)($e.Trigger,{asChild:!0,disabled:i,className:"!h-full",children:(0,Ce.jsx)(ce,{type:"button",variant:t,size:r,disabled:i,className:s("!px-2 !rounded-l-none !h-auto",el({variant:t,size:r}),d,{"!border-l-white border-l-[0.5px]":t==="primary"||t==="danger"}),id:`${N}-trigger`,"aria-label":x,children:(0,Ce.jsx)(Fn.ChevronDown,{className:"h-full w-4"})})}),(0,Ce.jsx)($e.Portal,{children:(0,Ce.jsx)($e.Content,{align:c,side:g,sideOffset:4,className:s("z-50 min-w-[10rem] overflow-hidden rounded-md border border-gray-100 bg-white p-1 text-[#191919] shadow-md outline-none 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",p),id:`${N}-content`,children:e.map((w,L)=>(0,Ce.jsxs)(En.Fragment,{children:[w.separatorBefore&&(0,Ce.jsx)($e.Separator,{className:"-mx-1 my-1 h-px bg-gray-100"}),(0,Ce.jsxs)($e.Item,{disabled:w.disabled,onSelect:()=>w.onSelect?.(),className:s("flex cursor-pointer select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors hover:bg-primary-accent focus:bg-primary-accent data-[highlighted]:bg-primary-accent data-[disabled]:pointer-events-none data-[disabled]:opacity-50",w.destructive&&"text-red-600 hover:bg-red-50 focus:bg-red-50 data-[highlighted]:bg-red-50",m,w.className),id:`${N}-item-${w.value??L}`,children:[w.icon&&(0,Ce.jsx)("span",{className:"shrink-0",children:w.icon}),(0,Ce.jsx)("span",{children:w.label})]})]},w.value??L))})})]})]});ko.displayName="SplitButton";var To=T(require("react"));var Ir=require("class-variance-authority");var An=T(require("react")),Mn=require("react/jsx-runtime"),Pe=An.default.forwardRef(({className:e,children:t,error:r,...o},n)=>{let a=r??t;return a?(0,Mn.jsx)("p",{ref:n,className:s("text-xs font-normal text-[#F04248]",e),...o,children:a}):null});Pe.displayName="ErrorMessage";var In=T(require("react")),Bn=require("react/jsx-runtime"),_e=In.default.forwardRef(({className:e,...t},r)=>(0,Bn.jsx)("div",{ref:r,className:s("text-sm text-[#8E98A8",e),...t}));_e.displayName="FormDescription";var Xe=require("react/jsx-runtime"),tl=(0,Ir.cva)("!p-0 flex h-full w-full !border-transparent !bg-transparent text-base focus-visible:bg-transparent focus-visible:outline-none focus-visible:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50",{variants:{status:{default:"placeholder:text-[#C4C4C4] dark:placeholder:text-[#9299A2]",error:"placeholder:text-red-500 text-red-500",loading:"placeholder:text-[#C4C4C4] dark:placeholder:text-[#9299A2]",prefilled:"",neutral:""}},defaultVariants:{status:"default"}}),Vn=To.forwardRef(({className:e,status:t,type:r,...o},n)=>(0,Xe.jsx)("input",{type:r,className:s(tl({status:t}),e),ref:n,...o}));Vn.displayName="BaseInnerInput";var fe=(0,Ir.cva)("flex relative h-10 w-full rounded-[4px] dark:!bg-transparent border transition px-3 py-2 text-base placeholder:text-[#79818C] focus-within:outline-0 focus-within:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50 dark:disabled:!border-[#9299A2]",{variants:{status:{default:"border-[#DEDEDE] bg-white text-[#191919] dark:!bg-transparent caret-text-primary focus-within:bg-white dark:focus-within:!bg-transparent dark:text-white focus-within:border-primary-main dark:focus-within:border-[#9299A2] dark:disabled:!border-[#9299A2]",error:"placeholder:text-red-500 bg-red-50 border-red-500 dark:!bg-status-error-bg-dark text-red-500 focus-within:bg-red-50 focus-within:border-red-500",loading:"",prefilled:"bg-[#F6F6F6] border-[#DEDEDE] dark:!bg-transparent caret-[#DEDEDE] focus-within:bg-[#F6F6F6] focus-within:border-[#DEDEDE] dark:!border-[#9299A2] dark:focus-within:border-[#9299A2]",neutral:"bg-[#F6F6F6] border-[#DEDEDE] dark:!bg-transparent caret-[#DEDEDE] focus-within:bg-[#F6F6F6] focus-within:border-[#DEDEDE] dark:!border-[#9299A2] dark:focus-within:border-[#9299A2]"}},defaultVariants:{status:"default"}}),On=(0,Ir.cva)("top-0 flex justify-center items-center h-full min-w-[50px] max-w-[100px] dark:!bg-transparent transition px-3 py-2 text-base placeholder:text-[#79818C] focus-within:outline-0 focus-within:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50 dark:disabled:!border-[#9299A2]",{variants:{side:{left:"left-0 rounded-l-[8px] border-r",right:"right-0 rounded-r-[8px] border-l"},status:{default:"border-[#DEDEDE] bg-white text-[#191919] dark:!bg-transparent caret-primary-main focus-within:bg-white dark:focus-within:!bg-transparent dark:text-white focus-within:border-primary-main dark:focus-within:border-[#9299A2] dark:disabled:!border-[#9299A2]",error:"placeholder:text-red-500 bg-red-50 border-red-500 dark:!bg-red-50 text-red-500 focus-within:bg-red-50 focus-within:border-red-500",loading:"",prefilled:"bg-[#F6F6F6] border-[#DEDEDE] dark:!bg-transparent caret-[#DEDEDE] focus-within:bg-[#F6F6F6] focus-within:border-[#DEDEDE] dark:!border-[#9299A2] dark:focus-within:border-[#9299A2]",neutral:"bg-transparent border-0 caret-[#DEDEDE] !px-0"}},defaultVariants:{status:"default",side:"left"}}),de=To.forwardRef(({className:e,status:t="default",disabled:r,error:o,isLoading:n,sideNodeClassName:a,showAsterisk:i,label:l,description:u,...d},p)=>{let m=t;return o&&(m="error"),n&&(m="loading"),r&&(m="prefilled"),(0,Xe.jsxs)("div",{className:"relative space-y-1 w-full",children:[l&&(0,Xe.jsx)(Y,{showAsterisk:i,error:o,children:l}),(0,Xe.jsxs)("div",{className:s(fe({status:m}),d.leftNode?"pl-0":"",d.rightNode?"pr-0":"",e),children:[d.leftNode?(0,Xe.jsx)("div",{className:s(On({status:m,side:"left"}),a),children:d.leftNode}):null,(0,Xe.jsx)(Vn,{ref:p,disabled:n||r,className:s({"!pl-3":d.leftNode&&t!=="neutral","!pr-3":d.rightNode&&t!=="neutral","sentry-mask":!!d?.isContentSensitive}),...d}),d.rightNode?(0,Xe.jsx)("div",{className:s(On({status:m,side:"right"}),a),children:d.rightNode}):null]}),u&&(0,Xe.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:u}),(0,Xe.jsx)(Pe,{error:o})]})});de.displayName="Input";var rr=require("react");var Fo=require("react/jsx-runtime"),Hn=()=>(0,Fo.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,Fo.jsx)("path",{d:"M8.89802 2.93408L9.70202 3.49808L6.21602 8.52608H5.41202L3.46802 5.80208L4.27202 5.05208L5.81402 6.49208L8.89802 2.93408Z",fill:"currentColor"})});var er=require("react/jsx-runtime"),$n=()=>(0,er.jsxs)("svg",{width:"18",height:"14",viewBox:"0 0 18 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,er.jsx)("path",{d:"M1.54639 7.26103C1.48389 7.09264 1.48389 6.90741 1.54639 6.73903C2.15517 5.26292 3.18853 4.00081 4.51547 3.1127C5.84241 2.22459 7.40317 1.75049 8.99989 1.75049C10.5966 1.75049 12.1574 2.22459 13.4843 3.1127C14.8113 4.00081 15.8446 5.26292 16.4534 6.73903C16.5159 6.90741 16.5159 7.09264 16.4534 7.26103C15.8446 8.73713 14.8113 9.99925 13.4843 10.8874C12.1574 11.7755 10.5966 12.2496 8.99989 12.2496C7.40317 12.2496 5.84241 11.7755 4.51547 10.8874C3.18853 9.99925 2.15517 8.73713 1.54639 7.26103Z",stroke:"#8E98A8",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),(0,er.jsx)("path",{d:"M9 9.25C10.2426 9.25 11.25 8.24264 11.25 7C11.25 5.75736 10.2426 4.75 9 4.75C7.75736 4.75 6.75 5.75736 6.75 7C6.75 8.24264 7.75736 9.25 9 9.25Z",stroke:"#8E98A8",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]});var tr=require("react/jsx-runtime"),_n=()=>(0,tr.jsxs)("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,tr.jsx)("path",{d:"M4.08759 12.69C3.26171 11.9072 2.61006 10.9591 2.17509 9.90752C2.10081 9.73454 2.0625 9.54826 2.0625 9.36001C2.0625 9.17177 2.10081 8.98549 2.17509 8.81252C2.75274 7.4073 3.72095 6.19704 4.96509 5.32502C6.14597 4.4998 7.55989 4.07405 9.00009 4.11002C10.0363 4.084 11.064 4.30239 12.0001 4.74752M13.9201 6.03752C14.7415 6.81964 15.3904 7.76486 15.8251 8.81252C15.8994 8.98549 15.9377 9.17177 15.9377 9.36001C15.9377 9.54826 15.8994 9.73454 15.8251 9.90752C15.2474 11.3127 14.2792 12.523 13.0351 13.395C11.8542 14.2202 10.4403 14.646 9.00009 14.61C7.9639 14.636 6.93616 14.4176 6.00009 13.9725",stroke:"#8E98A8",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,tr.jsx)("path",{d:"M6.5325 10.2375C6.42732 9.95694 6.37395 9.65962 6.375 9.36C6.375 8.66381 6.65156 7.99613 7.14384 7.50384C7.63613 7.01156 8.30381 6.735 9 6.735C9.3 6.7335 9.597 6.7875 9.8775 6.8925M11.4675 8.4825C11.5725 8.763 11.6265 9.06 11.625 9.36C11.625 10.0562 11.3484 10.7239 10.8562 11.2162C10.3639 11.7084 9.69619 11.985 9 11.985C8.70038 11.986 8.40306 11.9327 8.1225 11.8275M2.25 15L14.25 3",stroke:"#8E98A8",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]});var Eo=require("react/jsx-runtime"),zn=()=>(0,Eo.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,Eo.jsx)("path",{d:"M3.37891 8.62142L6.00041 5.99992L8.62191 8.62142M8.62191 3.37842L5.99991 5.99992L3.37891 3.37842",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});var Ae=require("react/jsx-runtime"),Wn=[{label:"Uppercase",key:"uppercase",RegExp:/[A-Z]/,validated:!1},{label:"Lowercase",key:"lowercase",RegExp:/[a-z]/,validated:!1},{label:"Number",key:"number",RegExp:/\d/,validated:!1},{label:"12 Characters",key:"twelve-chars",RegExp:/.{12}/,validated:!1}],Ao=({onValidate:e,onChange:t,disableValidation:r,...o})=>{let[n,a]=(0,rr.useState)(!1),[i,l]=(0,rr.useState)(Wn),u=c=>Wn.map(g=>({...g,validated:g.RegExp.test(c)})),d=c=>{let g=u(c),x=g.every(h=>h.validated);return l(g),x},p=c=>{if(t&&t(c),r)return;let g=c?.target?.value,x=d(g);e&&e(x,g)},m=(0,rr.useMemo)(()=>(0,Ae.jsx)("div",{className:"flex items-center gap-2",children:i?.map(c=>(0,Ae.jsxs)("div",{className:s("text-xs flex items-center gap-0.5",{"text-[#62C554]":c?.validated,"text-[#8E98A8]":!c?.validated}),children:[(0,Ae.jsx)("span",{className:"",children:c?.validated?(0,Ae.jsx)(Hn,{}):(0,Ae.jsx)(zn,{})}),(0,Ae.jsx)("span",{className:"",children:c?.label})]},c?.key))}),[i]);return(0,Ae.jsx)(de,{sideNodeClassName:"!border-l-0",rightNode:n?(0,Ae.jsx)("button",{type:"button",onClick:()=>a(c=>!c),children:(0,Ae.jsx)($n,{})}):(0,Ae.jsx)("button",{type:"button",onClick:()=>a(c=>!c),children:(0,Ae.jsx)(_n,{})}),type:n?"text":"password",onChange:p,description:!r&&m,isContentSensitive:!0,...o})};Ao.displayName="PasswordInput";var Gn=require("class-variance-authority");var Dt=require("react/jsx-runtime"),rd=(0,Gn.cva)("flex relative min-h-[80px] w-full rounded-[8px] border transition px-3 py-2 text-base placeholder:text-[#79818C] focus-within:outline-0 focus-within:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50",{variants:{status:{default:"border-[#D7D7D7] dark:border-[#676767] bg-white text-[#191919] dark:!bg-transparent caret-primary-main focus-within:bg-white dark:focus-within:!bg-transparent dark:text-white focus-within:border-primary-main dark:focus-within:border-[#9299A2] dark:border-[#9299A2] dark:disabled:!border-[#9299A2]",error:"placeholder:text-status-error-fill bg-status-error-bg border-status-error-fill dark:!bg-status-error-bg-dark text-status-error-fill focus-within:bg-status-error-bg focus-within:border-status-error-fill",loading:"placeholder:text-[#C4C4C4]",prefilled:"resize-none bg-[#F6F6F6] border-[#D7D7D7] dark:!bg-transparent caret-[#D7D7D7] focus-within:bg-[#F6F6F6] focus-within:border-[#D7D7D7] dark:!border-[#9299A2] dark:focus-within:border-[#9299A2]",neutral:""}},defaultVariants:{status:"default"}}),Mo=({className:e,status:t="default",disabled:r,error:o,isLoading:n,showAsterisk:a,label:i,description:l,...u})=>{let d=t;return o&&(d="error"),n&&(d="loading"),r&&(d="prefilled"),(0,Dt.jsxs)("div",{className:"relative space-y-1",children:[(0,Dt.jsx)(Y,{showAsterisk:a,error:o,children:i}),(0,Dt.jsx)("textarea",{className:s("min-h-[80px]",fe({status:d}),e),disabled:n||r,...u}),(0,Dt.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:l}),(0,Dt.jsx)(Pe,{error:o})]})};Mo.displayName="Textarea";var la=T(require("react")),ca=require("lucide-react");var St=T(require("react"));var ft=T(require("react")),xe=require("cmdk"),qn=require("lucide-react");var X=T(require("@radix-ui/react-dialog")),mt=T(require("react"));var or=require("react/jsx-runtime"),Un=()=>(0,or.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"lucide lucide-x",children:[(0,or.jsx)("path",{d:"M18 6 6 18"}),(0,or.jsx)("path",{d:"m6 6 12 12"})]});var Z=require("react/jsx-runtime"),rl=X.Root,ol=X.Trigger,nl=X.Portal,Zn=mt.forwardRef(({className:e,...t},r)=>(0,Z.jsx)(X.Overlay,{ref:r,className:s("fixed inset-0 z-50 bg-black/60 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));Zn.displayName=X.Overlay.displayName;var Io=mt.forwardRef(({className:e,hideCloseButton:t,children:r,...o},n)=>(0,Z.jsxs)(nl,{children:[(0,Z.jsx)(Zn,{}),(0,Z.jsxs)(X.Content,{ref:n,className:s("fixed left-[50%] top-[50%] z-50 grid sm:w-full w-[95%] max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border border-transparent bg-white p-6 shadow-lg duration-200 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-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] rounded-lg max-h-[95%] overflow-y-auto",e),...o,children:[r,!t&&(0,Z.jsxs)(X.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground z-20",children:[(0,Z.jsx)(Un,{}),(0,Z.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));Io.displayName=X.Content.displayName;var Kn=({className:e,...t})=>(0,Z.jsx)("div",{className:s("flex flex-col space-y-1.5 text-left",e),...t});Kn.displayName="DialogHeader";var jn=({className:e,...t})=>(0,Z.jsx)("div",{className:s("flex flex-row justify-end sm:space-x-2",e),...t});jn.displayName="DialogFooter";var Yn=mt.forwardRef(({className:e,...t},r)=>(0,Z.jsx)(X.Title,{ref:r,className:s("text-xl font-semibold leading-none tracking-tight",e),...t}));Yn.displayName=X.Title.displayName;var Xn=mt.forwardRef(({className:e,...t},r)=>(0,Z.jsx)(X.Description,{ref:r,className:s("text-sm text-gray-500",e),...t}));Xn.displayName=X.Description.displayName;var Br=({trigger:e=void 0,children:t,open:r,onOpenChange:o,hideCloseButton:n,footer:a,title:i,description:l,contentClassName:u,headerClassName:d,titleClassName:p,descriptionClassName:m,footerClassName:c,asChild:g=!0,onOpenAutoFocus:x,onCloseAutoFocus:h,onEscapeKeyDown:v,onInteractOutside:f,onPointerDownOutside:N,closeOnOutsideClick:P=!0,...w})=>{let L=mt.useCallback(b=>{P||b.preventDefault(),N?.(b)},[P,N]),F=mt.useCallback(b=>{P||b.preventDefault(),f?.(b)},[P,f]);return(0,Z.jsxs)(rl,{...w,...r!==void 0?{open:r,onOpenChange:o}:{},children:[(0,Z.jsx)(ol,{asChild:g,children:e}),(0,Z.jsxs)(Io,{className:u,hideCloseButton:n,onOpenAutoFocus:x,onCloseAutoFocus:h,onEscapeKeyDown:v,onPointerDownOutside:L,onInteractOutside:F,children:[i||l?(0,Z.jsxs)(Kn,{className:d,children:[i&&(0,Z.jsx)(Yn,{className:p,children:i}),l&&(0,Z.jsx)(Xn,{className:m,children:l})]}):(0,Z.jsx)(Z.Fragment,{}),t,a&&(0,Z.jsx)(jn,{className:c,children:a})]})]})};Br.displayName=X.Dialog.displayName;var De=require("react/jsx-runtime"),nr=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command,{ref:r,className:s("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t}));nr.displayName=xe.Command.displayName;var ar=ft.forwardRef(({className:e,CommandInputContainerClassName:t,loading:r,...o},n)=>(0,De.jsxs)("div",{className:s("flex items-center border-0 px-3 gap-2",t),"cmdk-input-wrapper":"",children:[r?(0,De.jsx)(Ve,{size:16,colour:"secondary"}):(0,De.jsx)(qn.Search,{className:"mr-2 h-4 w-4 shrink-0 opacity-50"}),(0,De.jsx)(xe.Command.Input,{ref:n,className:s("flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",e),disabled:r,...o})]}));ar.displayName=xe.Command.Input.displayName;var ir=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command.List,{ref:r,className:s("overflow-y-auto overflow-x-hidden",e),...t}));ir.displayName=xe.Command.List.displayName;var sr=ft.forwardRef((e,t)=>(0,De.jsx)(xe.Command.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));sr.displayName=xe.Command.Empty.displayName;var lr=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command.Group,{ref:r,className:s("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t}));lr.displayName=xe.Command.Group.displayName;var al=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command.Separator,{ref:r,className:s("-mx-1 h-px bg-border",e),...t}));al.displayName=xe.Command.Separator.displayName;var cr=ft.forwardRef(({className:e,...t},r)=>(0,De.jsx)(xe.Command.Item,{ref:r,className:s("relative text=[#222222] flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-primary-accent data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",e),...t}));cr.displayName=xe.Command.Item.displayName;var il=({className:e,...t})=>(0,De.jsx)("span",{className:s("ml-auto text-xs tracking-widest text-muted-foreground",e),...t});il.displayName="CommandShortcut";var Bo=T(require("react")),ze=T(require("@radix-ui/react-popover"));var at=require("react/jsx-runtime"),Ne=ze.Root,ee=Bo.forwardRef((e,t)=>(0,at.jsx)(ze.Trigger,{ref:t,...e,onPointerDown:r=>{e.onPointerDown?.(r)}}));ee.displayName=ze.Trigger.displayName;var ge=Bo.forwardRef(({className:e,align:t="center",sideOffset:r=4,portal:o=!0,...n},a)=>o?(0,at.jsx)(ze.Portal,{children:(0,at.jsx)(ze.Content,{ref:a,align:t,sideOffset:r,className:s("pointer-events-auto z-50 w-72 rounded-md border border-transparent bg-white p-4 text-[#191919] shadow-md outline-none 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",e),onOpenAutoFocus:n.onOpenAutoFocus,onCloseAutoFocus:n.onCloseAutoFocus,...n})}):(0,at.jsx)(ze.Content,{ref:a,align:t,sideOffset:r,className:s("pointer-events-auto z-50 w-72 rounded-md border border-transparent bg-white p-4 text-[#191919] shadow-md outline-none 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",e),onOpenAutoFocus:n.onOpenAutoFocus,onCloseAutoFocus:n.onCloseAutoFocus,...n}));ge.displayName=ze.Content.displayName;var Me=({trigger:e,children:t,open:r,onOpenChange:o,contentClassName:n,asChild:a=!0,align:i,side:l,alignOffset:u,triggerClassName:d,sideOffset:p,onOpenAutoFocus:m,onCloseAutoFocus:c,portal:g=!0,id:x="popover",...h})=>(0,at.jsxs)(Ne,{...h,...r!==void 0?{open:r,onOpenChange:o}:{},children:[(0,at.jsx)(ee,{asChild:a,className:d,id:`${x}-trigger`,children:e}),(0,at.jsx)(ge,{alignOffset:u,sideOffset:p,side:l,align:i,className:n,onOpenAutoFocus:m,onCloseAutoFocus:c,portal:g,id:`${x}-content`,children:t})]});Me.displayName=ze.Root.displayName;var Oo=T(require("react")),We=T(require("@radix-ui/react-scroll-area"));var gt=require("react/jsx-runtime"),Ie=Oo.forwardRef(({className:e,viewPortClassName:t,children:r,...o},n)=>(0,gt.jsxs)(We.Root,{ref:n,className:s("relative overflow-hidden",e),...o,children:[(0,gt.jsx)(We.Viewport,{className:s("h-full w-full rounded-[inherit]",t),children:r}),(0,gt.jsx)(Or,{}),(0,gt.jsx)(We.Corner,{})]}));Ie.displayName=We.Root.displayName;var Or=Oo.forwardRef(({className:e,orientation:t="vertical",...r},o)=>(0,gt.jsx)(We.ScrollAreaScrollbar,{ref:o,orientation:t,className:s("flex touch-none select-none transition-colors",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...r,children:(0,gt.jsx)(We.ScrollAreaThumb,{className:"relative flex-1 rounded-full bg-[#959595] transition hover:bg-[#808080]"})}));Or.displayName=We.ScrollAreaScrollbar.displayName;var ie=require("react/jsx-runtime"),Jn=({className:e,value:t,placeholder:r="",status:o,disabled:n,id:a})=>(0,ie.jsx)(ee,{asChild:!0,disabled:n,id:a??"searchable-trigger",children:(0,ie.jsxs)("button",{disabled:n,className:s(fe({status:o}),"[&>span]:justify-start [&>span]:items-center gap-2 flex h-12 w-full items-center justify-between goup",t?"":"text-[#79818C]",e),children:[(0,ie.jsx)("span",{children:t??r??"Select options..."}),(0,ie.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",className:" data-[state=open]:goup-rotate-180",children:(0,ie.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"currentColor",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}),Vr=({options:e=[],value:t,onChange:r,containerClassName:o,placeholder:n,disabled:a,loading:i,optionComponent:l,children:u,modal:d=!1,hideSearch:p,className:m,inputValue:c,onValueChange:g,onInputValueChange:x})=>{let[h,v]=St.useState(!1),[f,N]=St.useState(void 0),P=St.useRef(null),w=St.useCallback(L=>{if(P.current&&(P.current.disconnect(),P.current=null),L){let F=()=>{N(L.getBoundingClientRect().width)};F();let b=new ResizeObserver(()=>{F()});b.observe(L),P.current=b}},[]);return(0,ie.jsxs)(Ne,{modal:d,open:h,onOpenChange:v,children:[(0,ie.jsx)("div",{className:s("w-full",m),ref:w,children:u}),(0,ie.jsx)(ge,{portal:!d,className:"p-0 min-w-[200px]",style:{width:f?`${f}px`:void 0},children:(0,ie.jsxs)(nr,{className:s("relative max-h-[270px]",{"mt-2":!p}),children:[!p&&(0,ie.jsx)(ar,{loading:i,placeholder:n??"Search options...",onValueChange:x,value:c,CommandInputContainerClassName:"mx-2 border rounded-md border-[#DEDEDE]"}),(0,ie.jsx)(Ie,{viewPortClassName:"max-h-[225px]",className:s("w-full px-0 h-full overflow-y-auto",o),children:(0,ie.jsxs)(ir,{children:[!p&&(0,ie.jsx)(sr,{children:"No result found."}),(0,ie.jsx)(lr,{className:"w-full",children:e?.map((L,F)=>(0,ie.jsx)(cr,{defaultValue:t?.label,value:L.label,disabled:a,onSelect:()=>{r(L),v(!1),g?.(L?.value)},id:L.value,children:l?l(L):(0,ie.jsx)("span",{children:L.label})},`${L.value}-${F}`))})]})})]})})]})};var ea=require("lucide-react"),te=T(require("react")),Vo=require("uuid");var Hr=require("framer-motion"),Qn=T(require("react")),Be=require("react/jsx-runtime"),dr=({size:e="md",semi:t=!1,className:r,id:o,label:n,labelClassName:a,labelWrapperClassName:i,disabled:l,subtitle:u,subtitleClassName:d,bodyClassName:p,checked:m,defaultChecked:c,onCheckedChange:g,name:x,value:h,onClick:v})=>{let f=Qn.useId(),N=o??f,P=l?"#B0B0B0":"#00D488";return(0,Be.jsxs)("div",{className:s("flex justify-start items-start gap-1",p),children:[(0,Be.jsxs)("div",{className:"relative flex items-center justify-center",children:[(0,Be.jsx)("input",{type:"checkbox",id:N,name:x,value:h,checked:m,defaultChecked:c,disabled:l,onClick:v,onChange:w=>g?.(w.target.checked),className:s("appearance-none shrink-0 rounded-[3px] border border-solid border-base-500","bg-base-100 dark:bg-transparent cursor-pointer transition","hover:bg-status-success-bg hover:border-status-success-fill","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-status-success-fill focus-visible:ring-offset-2","checked:bg-status-success-bg checked:border-status-success-fill","disabled:cursor-not-allowed disabled:opacity-50",e==="md"?"h-5 w-5":"h-6 w-6",r)}),(0,Be.jsx)(Hr.AnimatePresence,{children:m&&(0,Be.jsx)(Hr.motion.svg,{className:"absolute pointer-events-none",initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.1},...t?{width:12,height:2,viewBox:"0 0 12 2"}:{width:10,height:8,viewBox:"0 0 10 8"},fill:"none",children:t?(0,Be.jsx)("path",{d:"M1.9165 1H10.0832",stroke:P,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}):(0,Be.jsx)("path",{d:"M1 3.99996L3.66353 6.66349L9 1.33643",stroke:P,strokeWidth:"1.06667",strokeLinecap:"round",strokeLinejoin:"round"})},t?"semi":"check")})]}),(n||u)&&(0,Be.jsxs)("div",{className:s("flex flex-col justify-start items-start",i),children:[(0,Be.jsx)("label",{htmlFor:N,children:(0,Be.jsx)("span",{className:s("text-sm font-normal cursor-pointer transition-colors text-base-700 dark:text-white",l&&"cursor-not-allowed opacity-50",a),onClick:()=>!l&&g?.(!m),children:n})}),u&&(0,Be.jsx)("p",{className:s("text-sm text-base-500",l&&"opacity-50",d),children:u})]})]})};dr.displayName="Checkbox";var E=require("react/jsx-runtime"),ta=te.memo(({item:e,onDelete:t})=>(0,E.jsxs)("p",{className:"text-xs p-1.5 py-1 bg-gray-100 rounded-md flex items-center",children:[(0,E.jsx)("span",{children:e.label}),(0,E.jsx)("button",{type:"button",className:"pl-2",onClick:r=>{r.stopPropagation(),t(e)},children:(0,E.jsx)(ea.X,{size:12})})]}));ta.displayName="SelectedChip";var $r=te.memo(({disabled:e,className:t,values:r,placeholder:o="",status:n,onDelete:a})=>(0,E.jsx)(ee,{asChild:!0,disabled:e,children:(0,E.jsxs)("div",{className:s(fe({status:n}),"cursor-pointer [&>svg]:shrink-0 h-auto min-h-12 flex items-center justify-between w-full gap-2",t),children:[(0,E.jsx)("div",{className:"w-full flex flex-row items-center gap-2 flex-wrap",children:r.length?r.map(i=>(0,E.jsx)(ta,{item:i,onDelete:a},i.value)):(0,E.jsx)("span",{className:"text-[#79818C] dark:text-[#959BA4]",children:o})}),(0,E.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",children:(0,E.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"currentColor",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}));$r.displayName="MultiSelectTrigger";var ra=te.memo(({option:e,isChecked:t,onSelect:r,optionComponent:o})=>(0,E.jsx)("article",{className:"cursor-pointer relative hover:bg-status-success-bg transition flex w-[calc(100%-0.375rem)] mx-auto rounded-md items-center focus:dark:!text-[#DDDFE0] py-1.5 px-2 text-sm outline-none focus:bg-status-success-bg dark:!text-[#DDDFE0] focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 focus-visible:ring-1 focus-visible:ring-status-success-fill focus-visible:ring-offset-1 focus-visible:ring-offset-status-success-fill",onClick:()=>r(e),children:(0,E.jsx)("div",{className:"w-full h-[30px] flex flex-row items-center dark:!text-white",children:(0,E.jsx)(dr,{onCheckedChange:()=>r(e),value:e.value,label:o?o(e):(0,E.jsx)("span",{children:e.label}),bodyClassName:"w-full",labelWrapperClassName:"w-full",labelClassName:s(o&&"w-full"),checked:t})})}));ra.displayName="OptionItem";var _r=({options:e,children:t,onChange:r,optionComponent:o,values:n,hideSearch:a,modal:i,placeholder:l,isLoading:u,showSelectedValues:d=!1,error:p,label:m,showAsterisk:c})=>{let[g,x]=te.useState(""),h=n,v=te.useMemo(()=>new Set(h.map(y=>y.value)),[h]),f=te.useMemo(()=>{if(!g)return e;let y=g.trim().toLowerCase();return e.filter(A=>A.label?.trim()?.toLowerCase()?.includes(y))},[e,g]),N=te.useCallback(y=>{let A=v.has(y.value);r(A?h.filter(G=>G.value!==y.value):[...h,y])},[h,v,r]),P=te.useRef(null),[w,L]=te.useState(void 0);te.useLayoutEffect(()=>{if(!P.current)return;let y=P.current,A=()=>{L(y.getBoundingClientRect().width)};A();let G=new ResizeObserver(()=>{A()});return G.observe(y),()=>G.disconnect()},[]);let F=te.useCallback(y=>{let A=h.filter(G=>G.value!==y.value);r(A)},[h,r]),b=te.useCallback(()=>{h.length===e.length?r([]):r(e)},[h.length,e,r]),D=te.useCallback(y=>{x(y.target.value)},[]);return(0,E.jsxs)("div",{className:"relative space-y-1",children:[(0,E.jsx)(Y,{showAsterisk:c,error:p,children:m}),(0,E.jsxs)(Ne,{modal:i,children:[(0,E.jsx)("div",{ref:P,children:t??(0,E.jsx)($r,{values:h,placeholder:l??"Select",onDelete:F,className:"h-auto"})}),d&&(0,E.jsx)("div",{className:"flex py-2 gap-2 flex-wrap",children:h.map(y=>(0,E.jsx)("div",{className:"bg-gray-100 border text-black rounded-xl text-[10px] font-medium px-2 py-1",children:(0,E.jsx)("span",{children:y.label})},(0,Vo.v4)()))}),(0,E.jsxs)(ge,{portal:!i,align:"start",className:"min-w-[200px] p-0",style:{width:w?`${w}px`:void 0},onInteractOutside:y=>{y.target?.closest("[data-radix-popper-content-wrapper]")&&y.preventDefault()},onOpenAutoFocus:y=>y.preventDefault(),children:[!a&&(0,E.jsx)("div",{className:"w-full px-4",children:(0,E.jsxs)("div",{className:"w-full h-[36px] px-1 flex items-center justify-start border-[0.5px] rounded-md border-[#D7D7D7] mb-[5px]",children:[u?(0,E.jsx)(Ve,{}):(0,E.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,E.jsx)("path",{d:"M11.5 21C16.7467 21 21 16.7467 21 11.5C21 6.25329 16.7467 2 11.5 2C6.25329 2 2 6.25329 2 11.5C2 16.7467 6.25329 21 11.5 21Z",stroke:"#959595",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,E.jsx)("path",{d:"M22 22L20 20",stroke:"#959595",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}),(0,E.jsx)("input",{value:g,placeholder:"Search",type:"text",disabled:u,className:"oultine-0 focus-visible:outline-0 focus-visible:ring-0 ml-1 w-full !border-transparent placeholder:text-sm placeholder:font-normal dark:bg-transparent placeholder:text-[#959595] dark:placeholder:text-[#DDDFE0] focus:ring-0 focus:ring-offset-0 focus:bg-white dark:focus:bg-transparent dark:text-[#DDDFE0]",onChange:D})]})}),(0,E.jsxs)("div",{className:s("w-full h-[44px] px-2.5 flex items-center justify-between mb-[5px] border-[#D7D7D7] dark:border-[#5C636B]",a?"border-b-[0.5px]":"border-y-[0.5px]"),children:[(0,E.jsx)("button",{className:"text-sm text-primary-main font-normal",onClick:b,disabled:f.length<1||u,children:(0,E.jsxs)("span",{children:[h.length===e.length?"Unselect":"Select"," all"]})}),(0,E.jsxs)("p",{className:"text-sm text-[#959595] font-normal dark:text-[#DDDFE0]",children:[h.length," selected"]})]}),(0,E.jsxs)(Ie,{viewPortClassName:"max-h-[225px]",className:"pb-1",children:[u&&(0,E.jsx)("div",{className:"py-7 flex justify-center",children:(0,E.jsx)(Ve,{})}),!u&&f.map(y=>(0,E.jsx)(ra,{option:y,isChecked:v.has(y.value),onSelect:N,optionComponent:o},(0,Vo.v4)()))]})]})]})]})};var sl=[{countryCode:"GLOBAL",countryName:"Global",currency:"Dollars",currencyCode:"USD",internetCountryCode:"GLOBAL"},{countryName:"Benin",countryCode:"+229",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"BJ"},{countryName:"Burkina Faso",countryCode:"+226",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"BF"},{countryName:"Cameroon",countryCode:"+237",currency:"Central African CFA franc",currencyCode:"XAF",currencyIcon:"Fr",internetCountryCode:"CM"},{countryName:"Chad",countryCode:"+235",currency:"Central African CFA franc",currencyCode:"XAF",currencyIcon:"Fr",internetCountryCode:"TD"},{countryName:"DR Congo",countryCode:"+243",currency:"Congolese franc",currencyCode:"CDF",currencyIcon:"FC",internetCountryCode:"CD"},{countryName:"Eswatini",countryCode:"+268",currency:"Swazi lilangeni",currencyCode:"SZL",currencyIcon:"L",internetCountryCode:"SZ"},{countryName:"Gabon",countryCode:"+241",currency:"Central African CFA franc",currencyCode:"XAF",currencyIcon:"Fr",internetCountryCode:"GA"},{countryName:"Ghana",countryCode:"+233",currency:"Ghanaian cedi",currencyCode:"GHS",currencyIcon:"\u20B5",internetCountryCode:"GH"},{countryName:"Guinea",countryCode:"+224",currency:"Guinean franc",currencyCode:"GNF",currencyIcon:"Fr",internetCountryCode:"GN"},{countryName:"Ivory Coast",countryCode:"+225",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"CI"},{countryName:"Kenya",countryCode:"+254",currency:"Kenyan shilling",currencyCode:"KES",currencyIcon:"Sh",internetCountryCode:"KE"},{countryName:"Lesotho",countryCode:"+266",currency:"Lesotho loti",currencyCode:"LSL",currencyIcon:"L",internetCountryCode:"LS"},{countryName:"Liberia",countryCode:"+231",currency:"Liberian dollar",currencyCode:"LRD",currencyIcon:"$",internetCountryCode:"LR"},{countryName:"Madagascar",countryCode:"+261",currency:"Malagasy ariary",currencyCode:"MGA",currencyIcon:"Ar",internetCountryCode:"MG"},{countryName:"Malawi",countryCode:"+265",currency:"Malawian kwacha",currencyCode:"MWK",currencyIcon:"MK",internetCountryCode:"MW"},{countryName:"Mali",countryCode:"+223",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"ML"},{countryName:"Mozambique",countryCode:"+258",currency:"Mozambican metical",currencyCode:"MZN",currencyIcon:"MT",internetCountryCode:"MZ"},{countryName:"Namibia",countryCode:"+264",currency:"Namibian dollar",currencyCode:"NAD",currencyIcon:"$",internetCountryCode:"NA"},{countryName:"Niger",countryCode:"+227",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"NE"},{countryName:"Nigeria",countryCode:"+234",currency:"Nigerian naira",currencyCode:"NGN",currencyIcon:"\u20A6",internetCountryCode:"NG"},{countryName:"Republic of the Congo",countryCode:"+242",currency:"Central African CFA franc",currencyCode:"XAF",currencyIcon:"Fr",internetCountryCode:"CG"},{countryName:"Rwanda",countryCode:"+250",currency:"Rwandan franc",currencyCode:"RWF",currencyIcon:"Fr",internetCountryCode:"RW"},{countryName:"Senegal",countryCode:"+221",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"SN"},{countryName:"Seychelles",countryCode:"+248",currency:"Seychellois rupee",currencyCode:"SCR",currencyIcon:"\u20A8",internetCountryCode:"SC"},{countryName:"South Africa",countryCode:"+27",currency:"South African rand",currencyCode:"ZAR",currencyIcon:"R",internetCountryCode:"ZA"},{countryName:"South Sudan",countryCode:"+211",currency:"South Sudanese pound",currencyCode:"SSP",currencyIcon:"\xA3",internetCountryCode:"SS"},{countryName:"Tanzania",countryCode:"+255",currency:"Tanzanian shilling",currencyCode:"TZS",currencyIcon:"Sh",internetCountryCode:"TZ"},{countryName:"Togo",countryCode:"+228",currency:"West African CFA franc",currencyCode:"XOF",currencyIcon:"Fr",internetCountryCode:"TG"},{countryName:"Uganda",countryCode:"+256",currency:"Ugandan shilling",currencyCode:"UGX",currencyIcon:"Sh",internetCountryCode:"UG"},{countryName:"Zambia",countryCode:"+260",currency:"Zambian kwacha",currencyCode:"ZMW",currencyIcon:"ZK",internetCountryCode:"ZM"}],oa=e=>{if(!e)return sl?.map(r=>({value:r?.internetCountryCode,label:r?.countryName,...r}));if(!e?.length)return[];let t=new Set;return e.reduce((r,o)=>(t.has(o.value)||(t.add(o.value),r.push(o)),r),[])};var ur=T(require("react")),zr=T(require("react-phone-number-input")),aa=T(require("react-phone-number-input/flags"));var ht=require("react/jsx-runtime"),ll=e=>(0,ht.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"none",...e,children:[(0,ht.jsx)("rect",{width:"32",height:"32",fill:"#60A5FA"})," ",(0,ht.jsx)("path",{d:"M3 10L7 8L10 9L13 8L16 10L19 9L22 11L25 10L28 12V15L26 17L28 19L27 22L29 24L27 26L24 25L21 26L18 24L15 25L12 23L9 24L6 22L4 23L2 21V18L4 16L3 13L5 11L3 10Z",fill:"#34D399"}),(0,ht.jsx)("rect",{x:"2",y:"28",width:"28",height:"3",fill:"#D1D5DB"}),(0,ht.jsx)("path",{d:"M0 16H32M8 0V32M16 0V32M24 0V32",stroke:"#2563EB",strokeWidth:"0.5",vectorEffect:"non-scaling-stroke"}),(0,ht.jsx)("path",{d:"M0 16H32",stroke:"#2563EB",strokeWidth:"1",vectorEffect:"non-scaling-stroke"})]}),na=ll;var O=require("react/jsx-runtime"),Ho=ur.forwardRef(({className:e,onChange:t,defaultCountry:r="NG",disableCountrySelect:o=!1,modal:n,showAsterisk:a,label:i,description:l,error:u,countryOptions:d,...p},m)=>{let c=g=>(0,O.jsx)(cl,{...g,status:p.status,modal:n,options:d||g?.options});return(0,O.jsxs)("div",{className:"relative space-y-1",children:[(0,O.jsx)(Y,{showAsterisk:a,error:u,children:i}),(0,O.jsx)(zr.default,{ref:m,className:s("flex sentry-mask",e),flagComponent:tt,countrySelectComponent:g=>(0,O.jsx)(c,{...g,disabled:g?.disabled||o}),inputComponent:ia,defaultCountry:r,onChange:g=>{t&&t?.(g)},...p}),(0,O.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:l}),(0,O.jsx)(Pe,{error:u})]})});Ho.displayName="PhoneInput";var ia=ur.forwardRef(({className:e,...t},r)=>(0,O.jsx)(de,{className:s("!rounded-s-none h-10",e),...t,ref:r}));ia.displayName="InputComponent";var cl=({disabled:e,value:t,onChange:r,options:o,status:n,modal:a})=>{let i=ur.useCallback(l=>{r(l)},[r]);return(0,O.jsxs)(Ne,{modal:a,children:[(0,O.jsx)(ee,{disabled:e,children:(0,O.jsxs)("div",{className:s(fe({status:n}),"transition justify-center items-center disabled:text-base-500 flex gap-3 h-10 rounded-e-none border-e-0 pl-2 pr-2"),children:[(0,O.jsx)(tt,{country:t,countryName:t}),(0,O.jsx)("svg",{className:s("mr-0.5 h-4 w-4 opacity-50",e?"hidden":"opacity-100"),width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",children:(0,O.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"#959595",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}),(0,O.jsx)(ge,{portal:!a,className:"w-[200px] md:w-[300px] p-0",children:(0,O.jsx)(nr,{children:(0,O.jsx)(ir,{children:(0,O.jsxs)(Ie,{className:"h-72",children:[(0,O.jsx)(ar,{placeholder:"Search country..."}),(0,O.jsx)(sr,{children:"No country found."}),(0,O.jsx)(lr,{children:o.filter(l=>l.value).map(l=>(0,O.jsxs)(cr,{className:"gap-2",onSelect:()=>i(l.value),children:[(0,O.jsx)(tt,{country:l.value,countryName:l.label}),(0,O.jsx)("span",{className:"flex-1 text-sm",children:l.label}),l.value&&(0,O.jsx)("span",{className:"text-[#191919]/50 text-sm dark:text-white",children:`+${zr.getCountryCallingCode(l.value)}`}),(0,O.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",className:s("ml-auto",l.value===t?"opacity-100":"opacity-0"),children:(0,O.jsx)("path",{d:"M4 8.00008L6.66353 10.6636L12 5.33655",stroke:"#959595",strokeWidth:"1.06667",strokeLinecap:"round",strokeLinejoin:"round"})})]},`${l.value}-${l.label}`))})]})})})})]})},tt=({country:e,countryName:t,className:r})=>{let o=aa.default[e];return e==="GLOBAL"?(0,O.jsx)("span",{className:s("bg-white/20 flex h-4 w-6 overflow-hidden rounded-sm",r),children:(0,O.jsx)(na,{className:"w-full h-[90%]"})}):(0,O.jsx)("span",{className:s("bg-white/20 flex h-4 w-6 overflow-hidden rounded-sm",r),children:o&&(0,O.jsx)(o,{title:t})})};tt.displayName="FlagComponent";var I=require("react/jsx-runtime"),dl=({className:e,value:t,placeholder:r="",status:o,disabled:n})=>(0,I.jsx)(ee,{asChild:!0,disabled:n,id:"country-dropdown",children:(0,I.jsxs)("button",{disabled:n,className:s(fe({status:o}),"[&>span]:justify-start [&>span]:items-center gap-2 flex w-full items-center justify-between goup",t?"":"text-[#79818C]",e),children:[t?(0,I.jsxs)("div",{className:"flex gap-2 items-center",children:[(0,I.jsx)(tt,{country:t?.value,countryName:t?.value,className:"ml-1 !w-6 h-5"}),(0,I.jsx)("span",{className:"",children:t?.label}),"-",(0,I.jsx)("span",{className:"",children:t?.value})]}):(0,I.jsx)("span",{children:r??"Select options..."}),(0,I.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",className:" data-[state=open]:goup-rotate-180",children:(0,I.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"currentColor",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}),da=la.memo(({item:e,onDelete:t})=>(0,I.jsxs)("p",{className:"text-xs pl-1.5 pr-1 py-1 bg-gray-100 rounded-md flex items-center gap-1",children:[(0,I.jsx)(tt,{country:e?.internetCountryCode||e?.value,countryName:e?.value,className:"!w-5 h-4"}),(0,I.jsx)("span",{children:e.label}),(0,I.jsx)("button",{type:"button",className:"pl-1",onClick:r=>{r.stopPropagation(),t(e)},children:(0,I.jsx)(ca.X,{size:12})})]}));da.displayName="CountryChip";var ul=({className:e,values:t,placeholder:r="",status:o,disabled:n,onDelete:a})=>(0,I.jsx)(ee,{asChild:!0,disabled:n,id:"country-dropdown",children:(0,I.jsxs)("div",{className:s(fe({status:o}),"cursor-pointer h-auto min-h-12 flex items-center justify-between w-full gap-2",e),children:[(0,I.jsx)("div",{className:"w-full flex flex-row items-center gap-2 flex-wrap",children:t.length?t.map(i=>(0,I.jsx)(da,{item:i,onDelete:a},i.value)):(0,I.jsx)("span",{className:"text-[#79818C]",children:r})}),(0,I.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",children:(0,I.jsx)("path",{d:"M16.5999 7.45825L11.1666 12.8916C10.5249 13.5333 9.4749 13.5333 8.83324 12.8916L3.3999 7.45825",stroke:"currentColor",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})})]})}),sa=e=>(0,I.jsxs)("div",{className:"w-full flex items-center gap-2",children:[(0,I.jsx)(tt,{country:e?.internetCountryCode||e?.value,countryName:e?.label,className:"ml-2 !w-6 !h-5"}),(0,I.jsxs)("div",{className:"flex-1 flex items-center gap-2",children:[(0,I.jsx)("span",{className:"flex text-sm",children:e?.label}),"-",(0,I.jsx)("span",{className:"text-sm",children:e?.internetCountryCode})]})]}),ua=e=>{let{hideSearch:t=!0,showAsterisk:r,label:o,description:n,error:a,countryOptions:i=void 0}=e,l=oa(i);if(e.multiSelect){let{value:c,onChange:g,placeholder:x,status:h,disabled:v,loading:f,modal:N,className:P,optionComponent:w}=e,L=c??[];return(0,I.jsxs)("div",{className:"relative space-y-1",children:[(0,I.jsx)(Y,{showAsterisk:r,error:a,children:o}),(0,I.jsx)(_r,{options:l,values:L,onChange:b=>g(b),hideSearch:t,modal:N,isLoading:f,placeholder:x??"Select Country",optionComponent:w??sa,children:(0,I.jsx)(ul,{values:L,status:h,disabled:v,className:P,placeholder:x??"Select Country",onDelete:b=>{g(L.filter(D=>D.value!==b.value))}})}),(0,I.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:n}),(0,I.jsx)(Pe,{error:a})]})}let{value:u,onChange:d,...p}=e,m=l?.find(c=>(c?.value||c?.internetCountryCode)===u?.value);return(0,I.jsxs)("div",{className:"relative space-y-1",children:[(0,I.jsx)(Y,{showAsterisk:r,error:a,children:o}),(0,I.jsx)(Vr,{options:l,hideSearch:t,optionComponent:sa,value:u,onChange:d,...p,children:(0,I.jsx)(dl,{value:m,status:p?.status,placeholder:p?.placeholder??" Select Country"})}),(0,I.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:n}),(0,I.jsx)(Pe,{error:a})]})};var vt=require("react/jsx-runtime"),it=({showAsterisk:e,label:t,description:r,error:o,hideSearch:n=!1,status:a,...i})=>(0,vt.jsxs)("div",{className:"relative space-y-1",children:[(0,vt.jsx)(Y,{showAsterisk:e,error:o,children:t}),(0,vt.jsx)(Vr,{hideSearch:n,...i,containerClassName:"h-full",children:(0,vt.jsx)(Jn,{disabled:i?.disabled,placeholder:i?.placeholder??"Select",status:a,value:i?.value?.label??i?.value?.value,className:i?.className,id:i?.id})}),(0,vt.jsx)(_e,{className:"text-gray-400 text-sm !font-normal",children:r}),(0,vt.jsx)(Pe,{error:o})]});var pa=require("class-variance-authority"),ma=require("react"),fa=T(require("react-otp-input")),$o=require("react/jsx-runtime"),pl=(0,pa.cva)("transition cursor-default placeholder:text-black dark:placeholder:text-white rounded-lg !h-14 !w-14 border aspect-square text-base font-semibold tracking-normal outline-none placeholder:text-sm placeholder:font-normal text-black focus:bg-white flex-shrink-0",{variants:{status:{default:"border-gray-300 dark:border-[#d4d4d4] focus:border-gray-400 focus-visible:!ring-offset-gray-200 focus:ring-offset-gray-200 !ring-gray-200 !focus-visible:ring-1 bg-white dark:!bg-transparent dark:focus-visible:!ring-0 dark:focus-within:!bg-transparent dark:text-white dark:focus-within:border-[#9299A2] dark:border-[#676767] dark:disabled:!border-[#9299A2]",error:"placeholder:text-red-600 bg-red-50 border-red-600 text-red-600 focus-within:bg-red-50 focus-within:border-red-600",loading:"placeholder:text-[#C4C4C4]"}},defaultVariants:{status:"default"}}),ga=({numInputs:e=4,inputStyle:t,containerStyle:r,placeholder:o="-",status:n,inputMode:a="numeric",inputType:i="number",...l})=>{let u=(0,ma.useMemo)(()=>o||new Array(e).fill("").reduce((m,c)=>m+=c,""),[e,o]);return(0,$o.jsx)(fa.default,{numInputs:e,placeholder:u,containerStyle:s("w-fit sentry-mask flex justify-between",r),inputStyle:s(pl({status:n}),t,"sentry-mask"),renderInput:d=>(0,$o.jsx)("input",{...d,inputMode:a,type:i}),inputType:i,...l})};var rt=T(require("@radix-ui/react-accordion")),ha=require("lucide-react");var st=require("react/jsx-runtime");function va({items:e,type:t="single",defaultValue:r,onChange:o,className:n}){return(0,st.jsx)(rt.Root,{...t==="single"?{type:"single",collapsible:!0,defaultValue:r,onValueChange:o}:{type:"multiple",defaultValue:r,onValueChange:o},className:s("w-full flex flex-col gap-2.5",n),children:e.map(i=>(0,st.jsxs)(rt.Item,{value:i.key,className:"border border-gray-300 rounded-md overflow-hidden",children:[(0,st.jsx)(rt.Header,{className:"flex",children:(0,st.jsxs)(rt.Trigger,{className:"group flex flex-1 items-center justify-between px-4 py-3 text-sm font-medium text-gray-800 hover:bg-gray-200/50 transition-all data-[state=open]:bg-gray-200/50",children:[i.title,(0,st.jsx)(ha.ChevronDown,{className:"h-4 w-4 shrink-0 text-gray-500 transition-transform duration-200 group-data-[state=open]:rotate-180"})]})}),(0,st.jsx)(rt.Content,{className:"overflow-hidden data-[state=open]:animate-accordion-down data-[state=closed]:animate-accordion-up",children:(0,st.jsx)("div",{className:"px-4 py-3 border-t border-gray-300",children:i.content})})]},i.key))})}var Wr=require("react"),z=require("react/jsx-runtime"),ml=({type:e})=>e==="gray"?(0,z.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M10 0C4.49 0 0 4.49 0 10C0 15.51 4.49 20 10 20C15.51 20 20 15.51 20 10C20 4.49 15.51 0 10 0ZM14.78 7.7L9.11 13.37C8.97 13.51 8.78 13.59 8.58 13.59C8.38 13.59 8.19 13.51 8.05 13.37L5.22 10.54C4.93 10.25 4.93 9.77 5.22 9.48C5.51 9.19 5.99 9.19 6.28 9.48L8.58 11.78L13.72 6.64C14.01 6.35 14.49 6.35 14.78 6.64C15.07 6.93 15.07 7.4 14.78 7.7Z",fill:"#79818C"})}):e==="info"?(0,z.jsx)("svg",{stroke:"#70B6F6",fill:"#70B6F6",strokeWidth:"0",viewBox:"0 0 16 16",height:"24",width:"24",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16m.93-9.412-1 4.705c-.07.34.029.533.304.533.194 0 .487-.07.686-.246l-.088.416c-.287.346-.92.598-1.465.598-.703 0-1.002-.422-.808-1.319l.738-3.468c.064-.293.006-.399-.287-.47l-.451-.081.082-.381 2.29-.287zM8 5.5a1 1 0 1 1 0-2 1 1 0 0 1 0 2"})}):e==="warning"?(0,z.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M9.99984 1.66663C5.40817 1.66663 1.6665 5.40829 1.6665 9.99996C1.6665 14.5916 5.40817 18.3333 9.99984 18.3333C14.5915 18.3333 18.3332 14.5916 18.3332 9.99996C18.3332 5.40829 14.5915 1.66663 9.99984 1.66663ZM9.37484 6.66663C9.37484 6.32496 9.65817 6.04163 9.99984 6.04163C10.3415 6.04163 10.6248 6.32496 10.6248 6.66663V10.8333C10.6248 11.175 10.3415 11.4583 9.99984 11.4583C9.65817 11.4583 9.37484 11.175 9.37484 10.8333V6.66663ZM10.7665 13.65C10.7248 13.7583 10.6665 13.8416 10.5915 13.925C10.5082 14 10.4165 14.0583 10.3165 14.1C10.2165 14.1416 10.1082 14.1666 9.99984 14.1666C9.8915 14.1666 9.78317 14.1416 9.68317 14.1C9.58317 14.0583 9.4915 14 9.40817 13.925C9.33317 13.8416 9.27484 13.7583 9.23317 13.65C9.1915 13.55 9.1665 13.4416 9.1665 13.3333C9.1665 13.225 9.1915 13.1166 9.23317 13.0166C9.27484 12.9166 9.33317 12.825 9.40817 12.7416C9.4915 12.6666 9.58317 12.6083 9.68317 12.5666C9.88317 12.4833 10.1165 12.4833 10.3165 12.5666C10.4165 12.6083 10.5082 12.6666 10.5915 12.7416C10.6665 12.825 10.7248 12.9166 10.7665 13.0166C10.8082 13.1166 10.8332 13.225 10.8332 13.3333C10.8332 13.4416 10.8082 13.55 10.7665 13.65Z",fill:"#FFC700"})}):e==="success"?(0,z.jsx)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M12 2C6.49 2 2 6.49 2 12C2 17.51 6.49 22 12 22C17.51 22 22 17.51 22 12C22 6.49 17.51 2 12 2ZM16.78 9.7L11.11 15.37C10.97 15.51 10.78 15.59 10.58 15.59C10.38 15.59 10.19 15.51 10.05 15.37L7.22 12.54C6.93 12.25 6.93 11.77 7.22 11.48C7.51 11.19 7.99 11.19 8.28 11.48L10.58 13.78L15.72 8.64C16.01 8.35 16.49 8.35 16.78 8.64C17.07 8.93 17.07 9.4 16.78 9.7Z",fill:"#00D488"})}):(0,z.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,z.jsx)("path",{d:"M9.99984 1.66663C5.40817 1.66663 1.6665 5.40829 1.6665 9.99996C1.6665 14.5916 5.40817 18.3333 9.99984 18.3333C14.5915 18.3333 18.3332 14.5916 18.3332 9.99996C18.3332 5.40829 14.5915 1.66663 9.99984 1.66663ZM9.37484 6.66663C9.37484 6.32496 9.65817 6.04163 9.99984 6.04163C10.3415 6.04163 10.6248 6.32496 10.6248 6.66663V10.8333C10.6248 11.175 10.3415 11.4583 9.99984 11.4583C9.65817 11.4583 9.37484 11.175 9.37484 10.8333V6.66663ZM10.7665 13.65C10.7248 13.7583 10.6665 13.8416 10.5915 13.925C10.5082 14 10.4165 14.0583 10.3165 14.1C10.2165 14.1416 10.1082 14.1666 9.99984 14.1666C9.8915 14.1666 9.78317 14.1416 9.68317 14.1C9.58317 14.0583 9.4915 14 9.40817 13.925C9.33317 13.8416 9.27484 13.7583 9.23317 13.65C9.1915 13.55 9.1665 13.4416 9.1665 13.3333C9.1665 13.225 9.1915 13.1166 9.23317 13.0166C9.27484 12.9166 9.33317 12.825 9.40817 12.7416C9.4915 12.6666 9.58317 12.6083 9.68317 12.5666C9.88317 12.4833 10.1165 12.4833 10.3165 12.5666C10.4165 12.6083 10.5082 12.6666 10.5915 12.7416C10.6665 12.825 10.7248 12.9166 10.7665 13.0166C10.8082 13.1166 10.8332 13.225 10.8332 13.3333C10.8332 13.4416 10.8082 13.55 10.7665 13.65Z",fill:"#F04248"})}),ba=({type:e="info",title:t,description:r,open:o,showCloseButton:n,bottomNode:a,sideNode:i,onClose:l,showIcon:u=!0})=>{let[d,p]=(0,Wr.useState)(o);(0,Wr.useEffect)(()=>{p(o)},[o]);let m="",c="";switch(e){case"gray":m="#eeeef0",c="#79818c";break;case"info":m="#ebf5fd",c="#70B6F6";break;case"warning":m="#fff8df",c="#ffc700";break;case"success":m="#e0f9f0",c="#49e0aa";break;case"danger":m="#fde8e9",c="#f3777c";break;default:m="#eeeef0",c="#79818c";break}function g(){p(!1),l&&l()}return d?(0,z.jsxs)("div",{className:"w-full shadow-lg transform flex items-center rounded-md",style:{background:m||"#ebf5fd"},children:[(0,z.jsx)("div",{className:"flex-none absolute rounded-l-[2px] rounded-l-4px h-[4px] w-full top-0",style:{background:c||"#70B6F6"}}),(0,z.jsxs)("div",{className:"w-full gap-3 h-full flex flex-row justify-between px-4 md:px-4 py-3 md:py-4",children:[(0,z.jsxs)("div",{className:"flex flex-row gap-2.5 items-start w-full h-full",children:[u&&(0,z.jsx)("div",{className:"h-full flex justify-end",children:(0,z.jsx)(ml,{type:e})}),(0,z.jsxs)("div",{className:"w-full gap-3 h-full flex flex-col md:flex-row items-start justify-between",children:[(0,z.jsxs)("div",{className:"flex-1 gap-3 h-full flex flex-col items-start justify-between",children:[(t||r)&&(0,z.jsxs)("div",{children:[t&&(0,z.jsx)("div",{className:"text-sm font-bold text-[#191919]",children:t}),r&&(0,z.jsx)("div",{className:"text-sm font-normal text-[#5D5D5D] mt-1",children:r})]}),a]}),i]})]}),n&&(0,z.jsx)("div",{className:"w-1/10 h-full flex flex-col justify-start items-center",children:(0,z.jsx)("button",{onClick:g,children:(0,z.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,z.jsx)("path",{d:"M3.3335 3.33337L12.6662 12.6661",stroke:"#191919",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,z.jsx)("path",{d:"M3.33429 12.6661L12.667 3.33337",stroke:"#191919",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]})})})]})]}):null};var Ca=require("react"),Gr=require("lucide-react"),Ur=require("framer-motion");var ya=require("react/jsx-runtime"),Lt=({children:e,mode:t="truncate",className:r,as:o="div",...n})=>(0,ya.jsx)(o,{className:s({"text-ellipsis overflow-hidden whitespace-nowrap":t==="truncate","whitespace-normal break-words":t==="wrap","":t==="overflow"},r),target:n?.href?"_blank":void 0,...n,children:e});var lt=require("react/jsx-runtime"),xa=({text:e,textToCopy:t,onCopy:r,iconsPosition:o="right",clampText:n=!0,clampMode:a="truncate",isLink:i=!1,textClassName:l})=>{let[u,d]=(0,Ca.useState)(!1),p=()=>{navigator.clipboard.writeText(t??e).then(()=>{d(!0),r?.(),setTimeout(()=>d(!1),2e3)})},m=u?Gr.CheckIcon:Gr.Copy;return(0,lt.jsxs)("div",{className:"flex items-center space-x-2 cursor-pointer text-[#717171] bg-gray-100 w-fit max-w-full rounded-md p-1 px-2",children:[o==="left"&&(0,lt.jsx)(wa,{Icon:m,onClick:p,copied:u}),(0,lt.jsx)(Lt,{as:i?"a":"span",mode:n?a:"overflow",className:s({underline:i},l),href:i?e:void 0,children:e}),o==="right"&&(0,lt.jsx)(wa,{Icon:m,onClick:p,copied:u})]})},wa=({Icon:e,onClick:t,copied:r})=>(0,lt.jsx)(Ur.AnimatePresence,{mode:"wait",children:(0,lt.jsx)(Ur.motion.div,{initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2},onClick:t,children:(0,lt.jsx)(e,{className:`w-5 h-5 ${r?"text-green-500":"text-gray-500 hover:text-gray-700 transition"}`})},r?"check":"copy")});var pr=require("react");var Na=require("lucide-react"),_o=require("react/jsx-runtime"),Zr=({value:e,onChange:t,debounce:r=500,addon:o,...n})=>{let[a,i]=(0,pr.useState)(e??""),l=u=>i(u.target.value);return(0,pr.useEffect)(()=>{e&&i(e)},[e]),(0,pr.useEffect)(()=>{let u=setTimeout(()=>{t(a)},r);return()=>clearTimeout(u)},[a,r,t]),(0,_o.jsx)(de,{leftNode:o??(0,_o.jsx)(Na.Search,{className:" w-4 h-4 text-gray-400"}),sideNodeClassName:"bg-transparent !pr-0 !w-4 border-0 !min-w-[40px]",...n,className:s("!pl-0 py-1 border-[.5px] border-[#E9EBF8] rounded-xl text-sm w-full h-8 focus:outline-none focus:placeholder:hidden focus:!ring-2 !focus:ring-primary-main bg-[#F5F8FF] focus-within:!bg-transparent placeholder:text-xs",n?.className),onChange:l,value:a})};var zo=require("react"),Ra=require("lucide-react"),se=require("react/jsx-runtime"),Pa=e=>{let{environment:t,branch:r,version:o,deployTime:n,showBanner:a,onClose:i,initDefault:l,removeFromStorage:u,syncLocalStorageToState:d}=e,p=t||process.env.NEXT_PUBLIC_NODE_ENV;return p!=="staging"&&p!=="sandbox"||((0,zo.useEffect)(()=>{d()},[d]),(0,zo.useEffect)(()=>{let m;return(p==="staging"||p==="sandbox")&&(m=setInterval(()=>{u(),l()},300*1e3)),()=>{m&&clearInterval(m)}},[a,t,i,u,l,p]),!a)?null:(0,se.jsxs)("div",{className:"w-fit p-4 border shadow-md bg-white rounded-md z-[99999] absolute top-2 right-2 min-w-96",children:[(0,se.jsx)("button",{onClick:i,className:"absolute top-2 right-2",children:(0,se.jsx)(Ra.X,{})}),(0,se.jsxs)("div",{className:"space-y-2 text-sm",children:[(0,se.jsxs)("div",{className:"flex gap-2",children:[(0,se.jsx)("span",{className:"font-medium",children:"Environment:"}),(0,se.jsx)("span",{className:"text-blue-600 capitalize",children:p})]}),(0,se.jsxs)("div",{className:"flex gap-2",children:[(0,se.jsx)("span",{className:"font-medium",children:"Branch:"}),(0,se.jsx)("span",{className:"text-green-600 capitalize",children:r||process.env.NEXT_PUBLIC_DEPLOY_BRANCH})]}),(0,se.jsxs)("div",{className:"flex gap-2",children:[(0,se.jsx)("span",{className:"font-medium",children:"Version:"}),(0,se.jsx)("span",{className:"text-purple-600",children:o||process.env.NEXT_PUBLIC_DEPLOY_VERSION})]}),(0,se.jsxs)("div",{className:"flex gap-2",children:[(0,se.jsx)("span",{className:"font-medium",children:"Deploy Time:"}),(0,se.jsx)("span",{className:"text-orange-600",children:n||process.env.NEXT_PUBLIC_DEPLOY_TIME})]})]})]})};var Za=require("class-variance-authority"),hr=T(require("react"));var he=T(require("@radix-ui/react-dialog"),1),Ta=T(require("react"),1),C=T(require("react"),1);function fl(e){if(!e||typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}var Fa=C.default.createContext({drawerRef:{current:null},overlayRef:{current:null},onPress:()=>{},onRelease:()=>{},onDrag:()=>{},onNestedDrag:()=>{},onNestedOpenChange:()=>{},onNestedRelease:()=>{},openProp:void 0,dismissible:!1,isOpen:!1,isDragging:!1,keyboardIsOpen:{current:!1},snapPointsOffset:null,snapPoints:null,handleOnly:!1,modal:!1,shouldFade:!1,activeSnapPoint:null,onOpenChange:()=>{},setActiveSnapPoint:()=>{},closeDrawer:()=>{},direction:"bottom",shouldAnimate:{current:!0},shouldScaleBackground:!1,setBackgroundColorOnScale:!0,noBodyStyles:!1,container:null,autoFocus:!1}),Bt=()=>{let e=C.default.useContext(Fa);if(!e)throw new Error("useDrawerContext must be used within a Drawer.Root");return e};fl(`[data-vaul-drawer]{touch-action:none;will-change:transform;transition:transform .5s cubic-bezier(.32, .72, 0, 1);animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=open]{animation-name:slideFromBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=closed]{animation-name:slideToBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=open]{animation-name:slideFromTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=closed]{animation-name:slideToTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=open]{animation-name:slideFromLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=closed]{animation-name:slideToLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=open]{animation-name:slideFromRight}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=closed]{animation-name:slideToRight}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--initial-transform,100%),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--initial-transform,100%),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-overlay][data-vaul-snap-points=false]{animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=false][data-state=open]{animation-name:fadeIn}[data-vaul-overlay][data-state=closed]{animation-name:fadeOut}[data-vaul-animate=false]{animation:none!important}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:0;transition:opacity .5s cubic-bezier(.32, .72, 0, 1)}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:1}[data-vaul-drawer]:not([data-vaul-custom-container=true])::after{content:'';position:absolute;background:inherit;background-color:inherit}[data-vaul-drawer][data-vaul-drawer-direction=top]::after{top:initial;bottom:100%;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=bottom]::after{top:100%;bottom:initial;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=left]::after{left:initial;right:100%;top:0;bottom:0;width:200%}[data-vaul-drawer][data-vaul-drawer-direction=right]::after{left:100%;right:initial;top:0;bottom:0;width:200%}[data-vaul-overlay][data-vaul-snap-points=true]:not([data-vaul-snap-points-overlay=true]):not(
|
|
2
2
|
[data-state=closed]
|
|
3
3
|
){opacity:0}[data-vaul-overlay][data-vaul-snap-points-overlay=true]{opacity:1}[data-vaul-handle]{display:block;position:relative;opacity:.7;background:#e2e2e4;margin-left:auto;margin-right:auto;height:5px;width:32px;border-radius:1rem;touch-action:pan-y}[data-vaul-handle]:active,[data-vaul-handle]:hover{opacity:1}[data-vaul-handle-hitarea]{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:max(100%,2.75rem);height:max(100%,2.75rem);touch-action:inherit}@media (hover:hover) and (pointer:fine){[data-vaul-drawer]{user-select:none}}@media (pointer:fine){[data-vaul-handle-hitarea]:{width:100%;height:100%}}@keyframes fadeIn{from{opacity:0}to{opacity:1}}@keyframes fadeOut{to{opacity:0}}@keyframes slideFromBottom{from{transform:translate3d(0,var(--initial-transform,100%),0)}to{transform:translate3d(0,0,0)}}@keyframes slideToBottom{to{transform:translate3d(0,var(--initial-transform,100%),0)}}@keyframes slideFromTop{from{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}to{transform:translate3d(0,0,0)}}@keyframes slideToTop{to{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}}@keyframes slideFromLeft{from{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToLeft{to{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}}@keyframes slideFromRight{from{transform:translate3d(var(--initial-transform,100%),0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToRight{to{transform:translate3d(var(--initial-transform,100%),0,0)}}`);function gl(){let e=navigator.userAgent;return typeof window<"u"&&(/Firefox/.test(e)&&/Mobile/.test(e)||/FxiOS/.test(e))}function hl(){return Yo(/^Mac/)}function vl(){return Yo(/^iPhone/)}function Da(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}function bl(){return Yo(/^iPad/)||hl()&&navigator.maxTouchPoints>1}function Ea(){return vl()||bl()}function Yo(e){return typeof window<"u"&&window.navigator!=null?e.test(window.navigator.platform):void 0}var yl=24,wl=typeof window<"u"?C.useLayoutEffect:C.useEffect;function Sa(...e){return(...t)=>{for(let r of e)typeof r=="function"&&r(...t)}}var Wo=typeof document<"u"&&window.visualViewport;function La(e){let t=window.getComputedStyle(e);return/(auto|scroll)/.test(t.overflow+t.overflowX+t.overflowY)}function Aa(e){for(La(e)&&(e=e.parentElement);e&&!La(e);)e=e.parentElement;return e||document.scrollingElement||document.documentElement}var Cl=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]),Kr=0,Go;function xl(e={}){let{isDisabled:t}=e;wl(()=>{if(!t)return Kr++,Kr===1&&Ea()&&(Go=Nl()),()=>{Kr--,Kr===0&&Go?.()}},[t])}function Nl(){let e,t=0,r=m=>{e=Aa(m.target),!(e===document.documentElement&&e===document.body)&&(t=m.changedTouches[0].pageY)},o=m=>{if(!e||e===document.documentElement||e===document.body){m.preventDefault();return}let c=m.changedTouches[0].pageY,g=e.scrollTop,x=e.scrollHeight-e.clientHeight;x!==0&&((g<=0&&c>t||g>=x&&c<t)&&m.preventDefault(),t=c)},n=m=>{let c=m.target;Ko(c)&&c!==document.activeElement&&(m.preventDefault(),c.style.transform="translateY(-2000px)",c.focus(),requestAnimationFrame(()=>{c.style.transform=""}))},a=m=>{let c=m.target;Ko(c)&&(c.style.transform="translateY(-2000px)",requestAnimationFrame(()=>{c.style.transform="",Wo&&(Wo.height<window.innerHeight?requestAnimationFrame(()=>{ka(c)}):Wo.addEventListener("resize",()=>ka(c),{once:!0}))}))},i=()=>{window.scrollTo(0,0)},l=window.pageXOffset,u=window.pageYOffset,d=Sa(Rl(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`));window.scrollTo(0,0);let p=Sa(mr(document,"touchstart",r,{passive:!1,capture:!0}),mr(document,"touchmove",o,{passive:!1,capture:!0}),mr(document,"touchend",n,{passive:!1,capture:!0}),mr(document,"focus",a,!0),mr(window,"scroll",i));return()=>{d(),p(),window.scrollTo(l,u)}}function Rl(e,t,r){let o=e.style[t];return e.style[t]=r,()=>{e.style[t]=o}}function mr(e,t,r,o){return e.addEventListener(t,r,o),()=>{e.removeEventListener(t,r,o)}}function ka(e){let t=document.scrollingElement||document.documentElement;for(;e&&e!==t;){let r=Aa(e);if(r!==document.documentElement&&r!==document.body&&r!==e){let o=r.getBoundingClientRect().top,n=e.getBoundingClientRect().top,a=e.getBoundingClientRect().bottom,i=r.getBoundingClientRect().bottom+yl;a>i&&(r.scrollTop+=n-o)}e=r.parentElement}}function Ko(e){return e instanceof HTMLInputElement&&!Cl.has(e.type)||e instanceof HTMLTextAreaElement||e instanceof HTMLElement&&e.isContentEditable}function Pl(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Dl(...e){return t=>e.forEach(r=>Pl(r,t))}function Ma(...e){return Ta.useCallback(Dl(...e),e)}var Ia=new WeakMap;function re(e,t,r=!1){if(!e||!(e instanceof HTMLElement))return;let o={};Object.entries(t).forEach(([n,a])=>{if(n.startsWith("--")){e.style.setProperty(n,a);return}o[n]=e.style[n],e.style[n]=a}),!r&&Ia.set(e,o)}function Sl(e,t){if(!e||!(e instanceof HTMLElement))return;let r=Ia.get(e);r&&(e.style[t]=r[t])}var J=e=>{switch(e){case"top":case"bottom":return!0;case"left":case"right":return!1;default:return e}};function jr(e,t){if(!e)return null;let r=window.getComputedStyle(e),o=r.transform||r.webkitTransform||r.mozTransform,n=o.match(/^matrix3d\((.+)\)$/);return n?parseFloat(n[1].split(", ")[J(t)?13:12]):(n=o.match(/^matrix\((.+)\)$/),n?parseFloat(n[1].split(", ")[J(t)?5:4]):null)}function Ll(e){return 8*(Math.log(e+1)-2)}function Uo(e,t){if(!e)return()=>{};let r=e.style.cssText;return Object.assign(e.style,t),()=>{e.style.cssText=r}}function kl(...e){return(...t)=>{for(let r of e)typeof r=="function"&&r(...t)}}var K={DURATION:.5,EASE:[.32,.72,0,1]},Ba=.4,Tl=.25,Fl=100,Oa=8,kt=16,jo=26,Zo="vaul-dragging";function Va(e){let t=C.default.useRef(e);return C.default.useEffect(()=>{t.current=e}),C.default.useMemo(()=>(...r)=>t.current==null?void 0:t.current.call(t,...r),[])}function El({defaultProp:e,onChange:t}){let r=C.default.useState(e),[o]=r,n=C.default.useRef(o),a=Va(t);return C.default.useEffect(()=>{n.current!==o&&(a(o),n.current=o)},[o,n,a]),r}function Ha({prop:e,defaultProp:t,onChange:r=()=>{}}){let[o,n]=El({defaultProp:t,onChange:r}),a=e!==void 0,i=a?e:o,l=Va(r),u=C.default.useCallback(d=>{if(a){let m=typeof d=="function"?d(e):d;m!==e&&l(m)}else n(d)},[a,e,n,l]);return[i,u]}function Al({activeSnapPointProp:e,setActiveSnapPointProp:t,snapPoints:r,drawerRef:o,overlayRef:n,fadeFromIndex:a,onSnapPointChange:i,direction:l="bottom",container:u,snapToSequentialPoint:d}){let[p,m]=Ha({prop:e,defaultProp:r?.[0],onChange:t}),[c,g]=C.default.useState(typeof window<"u"?{innerWidth:window.innerWidth,innerHeight:window.innerHeight}:void 0);C.default.useEffect(()=>{function b(){g({innerWidth:window.innerWidth,innerHeight:window.innerHeight})}return window.addEventListener("resize",b),()=>window.removeEventListener("resize",b)},[]);let x=C.default.useMemo(()=>p===r?.[r.length-1]||null,[r,p]),h=C.default.useMemo(()=>{var b;return(b=r?.findIndex(D=>D===p))!=null?b:null},[r,p]),v=r&&r.length>0&&(a||a===0)&&!Number.isNaN(a)&&r[a]===p||!r,f=C.default.useMemo(()=>{let b=u?{width:u.getBoundingClientRect().width,height:u.getBoundingClientRect().height}:typeof window<"u"?{width:window.innerWidth,height:window.innerHeight}:{width:0,height:0};var D;return(D=r?.map(y=>{let A=typeof y=="string",G=0;if(A&&(G=parseInt(y,10)),J(l)){let R=A?G:c?y*b.height:0;return c?l==="bottom"?b.height-R:-b.height+R:R}let S=A?G:c?y*b.width:0;return c?l==="right"?b.width-S:-b.width+S:S}))!=null?D:[]},[r,c,u]),N=C.default.useMemo(()=>h!==null?f?.[h]:null,[f,h]),P=C.default.useCallback(b=>{var D;let y=(D=f?.findIndex(A=>A===b))!=null?D:null;i(y),re(o.current,{transition:`transform ${K.DURATION}s cubic-bezier(${K.EASE.join(",")})`,transform:J(l)?`translate3d(0, ${b}px, 0)`:`translate3d(${b}px, 0, 0)`}),f&&y!==f.length-1&&a!==void 0&&y!==a&&y<a?re(n.current,{transition:`opacity ${K.DURATION}s cubic-bezier(${K.EASE.join(",")})`,opacity:"0"}):re(n.current,{transition:`opacity ${K.DURATION}s cubic-bezier(${K.EASE.join(",")})`,opacity:"1"}),m(r?.[Math.max(y,0)])},[o.current,r,f,a,n,m]);C.default.useEffect(()=>{if(p||e){var b;let D=(b=r?.findIndex(y=>y===e||y===p))!=null?b:-1;f&&D!==-1&&typeof f[D]=="number"&&P(f[D])}},[p,e,r,f,P]);function w({draggedDistance:b,closeDrawer:D,velocity:y,dismissible:A}){if(a===void 0)return;let G=l==="bottom"||l==="right"?(N??0)-b:(N??0)+b,S=h===a-1,R=h===0,ue=b>0;if(S&&re(n.current,{transition:`opacity ${K.DURATION}s cubic-bezier(${K.EASE.join(",")})`}),!d&&y>2&&!ue){A?D():P(f[0]);return}if(!d&&y>2&&ue&&f&&r){P(f[r.length-1]);return}let ae=f?.reduce((pe,nt)=>typeof pe!="number"||typeof nt!="number"?pe:Math.abs(nt-G)<Math.abs(pe-G)?nt:pe),ye=J(l)?window.innerHeight:window.innerWidth;if(y>Ba&&Math.abs(b)<ye*.4){let pe=ue?1:-1;if(pe>0&&x&&r){P(f[r.length-1]);return}if(R&&pe<0&&A&&D(),h===null)return;P(f[h+pe]);return}P(ae)}function L({draggedDistance:b}){if(N===null)return;let D=l==="bottom"||l==="right"?N-b:N+b;(l==="bottom"||l==="right")&&D<f[f.length-1]||(l==="top"||l==="left")&&D>f[f.length-1]||re(o.current,{transform:J(l)?`translate3d(0, ${D}px, 0)`:`translate3d(${D}px, 0, 0)`})}function F(b,D){if(!r||typeof h!="number"||!f||a===void 0)return null;let y=h===a-1;if(h>=a&&D)return 0;if(y&&!D)return 1;if(!v&&!y)return null;let G=y?h+1:h-1,S=y?f[G]-f[G-1]:f[G+1]-f[G],R=b/Math.abs(S);return y?1-R:R}return{isLastSnapPoint:x,activeSnapPoint:p,shouldFade:v,getPercentageDragged:F,setActiveSnapPoint:m,activeSnapPointIndex:h,onRelease:w,onDrag:L,snapPointsOffset:f}}var Ml=()=>()=>{};function Il(){let{direction:e,isOpen:t,shouldScaleBackground:r,setBackgroundColorOnScale:o,noBodyStyles:n}=Bt(),a=C.default.useRef(null),i=(0,C.useMemo)(()=>document.body.style.backgroundColor,[]);function l(){return(window.innerWidth-jo)/window.innerWidth}C.default.useEffect(()=>{if(t&&r){a.current&&clearTimeout(a.current);let u=document.querySelector("[data-vaul-drawer-wrapper]")||document.querySelector("[vaul-drawer-wrapper]");if(!u)return;kl(o&&!n?Uo(document.body,{background:"black"}):Ml,Uo(u,{transformOrigin:J(e)?"top":"left",transitionProperty:"transform, border-radius",transitionDuration:`${K.DURATION}s`,transitionTimingFunction:`cubic-bezier(${K.EASE.join(",")})`}));let d=Uo(u,{borderRadius:`${Oa}px`,overflow:"hidden",...J(e)?{transform:`scale(${l()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`}:{transform:`scale(${l()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`}});return()=>{d(),a.current=window.setTimeout(()=>{i?document.body.style.background=i:document.body.style.removeProperty("background")},K.DURATION*1e3)}}},[t,r,i])}var fr=null;function Bl({isOpen:e,modal:t,nested:r,hasBeenOpened:o,preventScrollRestoration:n,noBodyStyles:a}){let[i,l]=C.default.useState(()=>typeof window<"u"?window.location.href:""),u=C.default.useRef(0),d=C.default.useCallback(()=>{if(Da()&&fr===null&&e&&!a){fr={position:document.body.style.position,top:document.body.style.top,left:document.body.style.left,height:document.body.style.height,right:"unset"};let{scrollX:m,innerHeight:c}=window;document.body.style.setProperty("position","fixed","important"),Object.assign(document.body.style,{top:`${-u.current}px`,left:`${-m}px`,right:"0px",height:"auto"}),window.setTimeout(()=>window.requestAnimationFrame(()=>{let g=c-window.innerHeight;g&&u.current>=c&&(document.body.style.top=`${-(u.current+g)}px`)}),300)}},[e]),p=C.default.useCallback(()=>{if(Da()&&fr!==null&&!a){let m=-parseInt(document.body.style.top,10),c=-parseInt(document.body.style.left,10);Object.assign(document.body.style,fr),window.requestAnimationFrame(()=>{if(n&&i!==window.location.href){l(window.location.href);return}window.scrollTo(c,m)}),fr=null}},[i]);return C.default.useEffect(()=>{function m(){u.current=window.scrollY}return m(),window.addEventListener("scroll",m),()=>{window.removeEventListener("scroll",m)}},[]),C.default.useEffect(()=>{if(t)return()=>{typeof document>"u"||document.querySelector("[data-vaul-drawer]")||p()}},[t,p]),C.default.useEffect(()=>{r||!o||(e?(!window.matchMedia("(display-mode: standalone)").matches&&d(),t||window.setTimeout(()=>{p()},500)):p())},[e,o,i,t,r,d,p]),{restorePositionSetting:p}}function $a({open:e,onOpenChange:t,children:r,onDrag:o,onRelease:n,snapPoints:a,shouldScaleBackground:i=!1,setBackgroundColorOnScale:l=!0,closeThreshold:u=Tl,scrollLockTimeout:d=Fl,dismissible:p=!0,handleOnly:m=!1,fadeFromIndex:c=a&&a.length-1,activeSnapPoint:g,setActiveSnapPoint:x,fixed:h,modal:v=!0,onClose:f,nested:N,noBodyStyles:P=!1,direction:w="bottom",defaultOpen:L=!1,disablePreventScroll:F=!0,snapToSequentialPoint:b=!1,preventScrollRestoration:D=!1,repositionInputs:y=!0,onAnimationEnd:A,container:G,autoFocus:S=!1}){var R,ue;let[ae=!1,ye]=Ha({defaultProp:L,prop:e,onChange:k=>{t?.(k),!k&&!N&&Os(),setTimeout(()=>{A?.(k)},K.DURATION*1e3),k&&!v&&typeof window<"u"&&window.requestAnimationFrame(()=>{document.body.style.pointerEvents="auto"}),k||(document.body.style.pointerEvents="auto")}}),[pe,nt]=C.default.useState(!1),[dt,Gt]=C.default.useState(!1),[Fs,dn]=C.default.useState(!1),At=C.default.useRef(null),Lr=C.default.useRef(null),ho=C.default.useRef(null),vo=C.default.useRef(null),Ut=C.default.useRef(null),Zt=C.default.useRef(!1),bo=C.default.useRef(null),yo=C.default.useRef(0),Mt=C.default.useRef(!1),un=C.default.useRef(!L),pn=C.default.useRef(0),M=C.default.useRef(null),mn=C.default.useRef(((R=M.current)==null?void 0:R.getBoundingClientRect().height)||0),fn=C.default.useRef(((ue=M.current)==null?void 0:ue.getBoundingClientRect().width)||0),wo=C.default.useRef(0),Es=C.default.useCallback(k=>{a&&k===Kt.length-1&&(Lr.current=new Date)},[]),{activeSnapPoint:As,activeSnapPointIndex:It,setActiveSnapPoint:gn,onRelease:Ms,snapPointsOffset:Kt,onDrag:Is,shouldFade:hn,getPercentageDragged:Bs}=Al({snapPoints:a,activeSnapPointProp:g,setActiveSnapPointProp:x,drawerRef:M,fadeFromIndex:c,overlayRef:At,onSnapPointChange:Es,direction:w,container:G,snapToSequentialPoint:b});xl({isDisabled:!ae||dt||!v||Fs||!pe||!y||!F});let{restorePositionSetting:Os}=Bl({isOpen:ae,modal:v,nested:N??!1,hasBeenOpened:pe,preventScrollRestoration:D,noBodyStyles:P});function kr(){return(window.innerWidth-jo)/window.innerWidth}function Vs(k){var $,W;!p&&!a||M.current&&!M.current.contains(k.target)||(mn.current=(($=M.current)==null?void 0:$.getBoundingClientRect().height)||0,fn.current=((W=M.current)==null?void 0:W.getBoundingClientRect().width)||0,Gt(!0),ho.current=new Date,Ea()&&window.addEventListener("touchend",()=>Zt.current=!1,{once:!0}),k.target.setPointerCapture(k.pointerId),yo.current=J(w)?k.pageY:k.pageX)}function vn(k,$){var W;let V=k,q=(W=window.getSelection())==null?void 0:W.toString(),Re=M.current?jr(M.current,w):null,we=new Date;if(V.tagName==="SELECT"||V.hasAttribute("data-vaul-no-drag")||V.closest("[data-vaul-no-drag]"))return!1;if(w==="right"||w==="left")return!0;if(Lr.current&&we.getTime()-Lr.current.getTime()<500)return!1;if(Re!==null&&(w==="bottom"?Re>0:Re<0))return!0;if(q&&q.length>0)return!1;if(Ut.current&&we.getTime()-Ut.current.getTime()<d&&Re===0||$)return Ut.current=we,!1;for(;V;){if(V.scrollHeight>V.clientHeight){if(V.scrollTop!==0)return Ut.current=new Date,!1;if(V.getAttribute("role")==="dialog")return!0}V=V.parentNode}return!0}function Hs(k){if(M.current&&dt){let $=w==="bottom"||w==="right"?1:-1,W=(yo.current-(J(w)?k.pageY:k.pageX))*$,V=W>0,q=a&&!p&&!V;if(q&&It===0)return;let Re=Math.abs(W),we=document.querySelector("[data-vaul-drawer-wrapper]"),ut=w==="bottom"||w==="top"?mn.current:fn.current,Ye=Re/ut,Pt=Bs(Re,V);if(Pt!==null&&(Ye=Pt),q&&Ye>=1||!Zt.current&&!vn(k.target,V))return;if(M.current.classList.add(Zo),Zt.current=!0,re(M.current,{transition:"none"}),re(At.current,{transition:"none"}),a&&Is({draggedDistance:W}),V&&!a){let Qe=Ll(W),Tr=Math.min(Qe*-1,0)*$;re(M.current,{transform:J(w)?`translate3d(0, ${Tr}px, 0)`:`translate3d(${Tr}px, 0, 0)`});return}let pt=1-Ye;if((hn||c&&It===c-1)&&(o?.(k,Ye),re(At.current,{opacity:`${pt}`,transition:"none"},!0)),we&&At.current&&i){let Qe=Math.min(kr()+Ye*(1-kr()),1),Tr=8-Ye*8,yn=Math.max(0,14-Ye*14);re(we,{borderRadius:`${Tr}px`,transform:J(w)?`scale(${Qe}) translate3d(0, ${yn}px, 0)`:`scale(${Qe}) translate3d(${yn}px, 0, 0)`,transition:"none"},!0)}if(!a){let Qe=Re*$;re(M.current,{transform:J(w)?`translate3d(0, ${Qe}px, 0)`:`translate3d(${Qe}px, 0, 0)`})}}}C.default.useEffect(()=>{window.requestAnimationFrame(()=>{un.current=!0})},[]),C.default.useEffect(()=>{var k;function $(){if(!M.current||!y)return;let W=document.activeElement;if(Ko(W)||Mt.current){var V;let q=((V=window.visualViewport)==null?void 0:V.height)||0,Re=window.innerHeight,we=Re-q,ut=M.current.getBoundingClientRect().height||0,Ye=ut>Re*.8;wo.current||(wo.current=ut);let Pt=M.current.getBoundingClientRect().top;if(Math.abs(pn.current-we)>60&&(Mt.current=!Mt.current),a&&a.length>0&&Kt&&It){let pt=Kt[It]||0;we+=pt}if(pn.current=we,ut>q||Mt.current){let pt=M.current.getBoundingClientRect().height,Qe=pt;pt>q&&(Qe=q-(Ye?Pt:jo)),h?M.current.style.height=`${pt-Math.max(we,0)}px`:M.current.style.height=`${Math.max(Qe,q-Pt)}px`}else gl()||(M.current.style.height=`${wo.current}px`);a&&a.length>0&&!Mt.current?M.current.style.bottom="0px":M.current.style.bottom=`${Math.max(we,0)}px`}}return(k=window.visualViewport)==null||k.addEventListener("resize",$),()=>{var W;return(W=window.visualViewport)==null?void 0:W.removeEventListener("resize",$)}},[It,a,Kt]);function jt(k){$s(),f?.(),k||ye(!1),setTimeout(()=>{a&&gn(a[0])},K.DURATION*1e3)}function bn(){if(!M.current)return;let k=document.querySelector("[data-vaul-drawer-wrapper]"),$=jr(M.current,w);re(M.current,{transform:"translate3d(0, 0, 0)",transition:`transform ${K.DURATION}s cubic-bezier(${K.EASE.join(",")})`}),re(At.current,{transition:`opacity ${K.DURATION}s cubic-bezier(${K.EASE.join(",")})`,opacity:"1"}),i&&$&&$>0&&ae&&re(k,{borderRadius:`${Oa}px`,overflow:"hidden",...J(w)?{transform:`scale(${kr()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`,transformOrigin:"top"}:{transform:`scale(${kr()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`,transformOrigin:"left"},transitionProperty:"transform, border-radius",transitionDuration:`${K.DURATION}s`,transitionTimingFunction:`cubic-bezier(${K.EASE.join(",")})`},!0)}function $s(){!dt||!M.current||(M.current.classList.remove(Zo),Zt.current=!1,Gt(!1),vo.current=new Date)}function _s(k){if(!dt||!M.current)return;M.current.classList.remove(Zo),Zt.current=!1,Gt(!1),vo.current=new Date;let $=jr(M.current,w);if(!k||!vn(k.target,!1)||!$||Number.isNaN($)||ho.current===null)return;let W=vo.current.getTime()-ho.current.getTime(),V=yo.current-(J(w)?k.pageY:k.pageX),q=Math.abs(V)/W;if(q>.05&&(dn(!0),setTimeout(()=>{dn(!1)},200)),a){Ms({draggedDistance:V*(w==="bottom"||w==="right"?1:-1),closeDrawer:jt,velocity:q,dismissible:p}),n?.(k,!0);return}if(w==="bottom"||w==="right"?V>0:V<0){bn(),n?.(k,!0);return}if(q>Ba){jt(),n?.(k,!1);return}var Re;let we=Math.min((Re=M.current.getBoundingClientRect().height)!=null?Re:0,window.innerHeight);var ut;let Ye=Math.min((ut=M.current.getBoundingClientRect().width)!=null?ut:0,window.innerWidth),Pt=w==="left"||w==="right";if(Math.abs($)>=(Pt?Ye:we)*u){jt(),n?.(k,!1);return}n?.(k,!0),bn()}C.default.useEffect(()=>(ae&&(re(document.documentElement,{scrollBehavior:"auto"}),Lr.current=new Date),()=>{Sl(document.documentElement,"scrollBehavior")}),[ae]);function zs(k){let $=k?(window.innerWidth-kt)/window.innerWidth:1,W=k?-kt:0;bo.current&&window.clearTimeout(bo.current),re(M.current,{transition:`transform ${K.DURATION}s cubic-bezier(${K.EASE.join(",")})`,transform:J(w)?`scale(${$}) translate3d(0, ${W}px, 0)`:`scale(${$}) translate3d(${W}px, 0, 0)`}),!k&&M.current&&(bo.current=setTimeout(()=>{let V=jr(M.current,w);re(M.current,{transition:"none",transform:J(w)?`translate3d(0, ${V}px, 0)`:`translate3d(${V}px, 0, 0)`})},500))}function Ws(k,$){if($<0)return;let W=(window.innerWidth-kt)/window.innerWidth,V=W+$*(1-W),q=-kt+$*kt;re(M.current,{transform:J(w)?`scale(${V}) translate3d(0, ${q}px, 0)`:`scale(${V}) translate3d(${q}px, 0, 0)`,transition:"none"})}function Gs(k,$){let W=J(w)?window.innerHeight:window.innerWidth,V=$?(W-kt)/W:1,q=$?-kt:0;$&&re(M.current,{transition:`transform ${K.DURATION}s cubic-bezier(${K.EASE.join(",")})`,transform:J(w)?`scale(${V}) translate3d(0, ${q}px, 0)`:`scale(${V}) translate3d(${q}px, 0, 0)`})}return C.default.useEffect(()=>{v||window.requestAnimationFrame(()=>{document.body.style.pointerEvents="auto"})},[v]),C.default.createElement(he.Root,{modal:v,defaultOpen:L,onOpenChange:k=>{!p&&!k||(k?nt(!0):jt(!0),ye(k))},open:ae},C.default.createElement(Fa.Provider,{value:{activeSnapPoint:As,snapPoints:a,setActiveSnapPoint:gn,drawerRef:M,overlayRef:At,onOpenChange:t,onPress:Vs,onRelease:_s,onDrag:Hs,dismissible:p,shouldAnimate:un,handleOnly:m,isOpen:ae,isDragging:dt,shouldFade:hn,closeDrawer:jt,onNestedDrag:Ws,onNestedOpenChange:zs,onNestedRelease:Gs,keyboardIsOpen:Mt,modal:v,snapPointsOffset:Kt,activeSnapPointIndex:It,direction:w,shouldScaleBackground:i,setBackgroundColorOnScale:l,noBodyStyles:P,container:G,autoFocus:S}},r))}var _a=C.default.forwardRef(function({...e},t){let{overlayRef:r,snapPoints:o,onRelease:n,shouldFade:a,isOpen:i,modal:l,shouldAnimate:u}=Bt(),d=Ma(t,r),p=o&&o.length>0;if(!l)return null;let m=C.default.useCallback(c=>n(c),[n]);return C.default.createElement(he.Overlay,{onMouseUp:m,ref:d,"data-vaul-overlay":"","data-vaul-snap-points":i&&p?"true":"false","data-vaul-snap-points-overlay":i&&a?"true":"false","data-vaul-animate":u?.current?"true":"false",...e})});_a.displayName="Drawer.Overlay";var za=C.default.forwardRef(function({onPointerDownOutside:e,style:t,onOpenAutoFocus:r,...o},n){let{drawerRef:a,onPress:i,onRelease:l,onDrag:u,keyboardIsOpen:d,snapPointsOffset:p,activeSnapPointIndex:m,modal:c,isOpen:g,direction:x,snapPoints:h,container:v,handleOnly:f,shouldAnimate:N,autoFocus:P}=Bt(),[w,L]=C.default.useState(!1),F=Ma(n,a),b=C.default.useRef(null),D=C.default.useRef(null),y=C.default.useRef(!1),A=h&&h.length>0;Il();let G=(R,ue,ae=0)=>{if(y.current)return!0;let ye=Math.abs(R.y),pe=Math.abs(R.x),nt=pe>ye,dt=["bottom","right"].includes(ue)?1:-1;if(ue==="left"||ue==="right"){if(!(R.x*dt<0)&&pe>=0&&pe<=ae)return nt}else if(!(R.y*dt<0)&&ye>=0&&ye<=ae)return!nt;return y.current=!0,!0};C.default.useEffect(()=>{A&&window.requestAnimationFrame(()=>{L(!0)})},[]);function S(R){b.current=null,y.current=!1,l(R)}return C.default.createElement(he.Content,{"data-vaul-drawer-direction":x,"data-vaul-drawer":"","data-vaul-delayed-snap-points":w?"true":"false","data-vaul-snap-points":g&&A?"true":"false","data-vaul-custom-container":v?"true":"false","data-vaul-animate":N?.current?"true":"false",...o,ref:F,style:p&&p.length>0?{"--snap-point-height":`${p[m??0]}px`,...t}:t,onPointerDown:R=>{f||(o.onPointerDown==null||o.onPointerDown.call(o,R),b.current={x:R.pageX,y:R.pageY},i(R))},onOpenAutoFocus:R=>{r?.(R),P||R.preventDefault()},onPointerDownOutside:R=>{if(e?.(R),!c||R.defaultPrevented){R.preventDefault();return}d.current&&(d.current=!1)},onFocusOutside:R=>{if(!c){R.preventDefault();return}},onPointerMove:R=>{if(D.current=R,f||(o.onPointerMove==null||o.onPointerMove.call(o,R),!b.current))return;let ue=R.pageY-b.current.y,ae=R.pageX-b.current.x,ye=R.pointerType==="touch"?10:2;G({x:ae,y:ue},x,ye)?u(R):(Math.abs(ae)>ye||Math.abs(ue)>ye)&&(b.current=null)},onPointerUp:R=>{o.onPointerUp==null||o.onPointerUp.call(o,R),b.current=null,y.current=!1,l(R)},onPointerOut:R=>{o.onPointerOut==null||o.onPointerOut.call(o,R),S(D.current)},onContextMenu:R=>{o.onContextMenu==null||o.onContextMenu.call(o,R),D.current&&S(D.current)}})});za.displayName="Drawer.Content";var Ol=250,Vl=120,Wa=C.default.forwardRef(function({preventCycle:e=!1,children:t,...r},o){let{closeDrawer:n,isDragging:a,snapPoints:i,activeSnapPoint:l,setActiveSnapPoint:u,dismissible:d,handleOnly:p,isOpen:m,onPress:c,onDrag:g}=Bt(),x=C.default.useRef(null),h=C.default.useRef(!1);function v(){if(h.current){P();return}window.setTimeout(()=>{f()},Vl)}function f(){if(a||e||h.current){P();return}if(P(),!i||i.length===0){d||n();return}if(l===i[i.length-1]&&d){n();return}let L=i.findIndex(b=>b===l);if(L===-1)return;let F=i[L+1];u(F)}function N(){x.current=window.setTimeout(()=>{h.current=!0},Ol)}function P(){x.current&&window.clearTimeout(x.current),h.current=!1}return C.default.createElement("div",{onClick:v,onPointerCancel:P,onPointerDown:w=>{p&&c(w),N()},onPointerMove:w=>{p&&g(w)},ref:o,"data-vaul-drawer-visible":m?"true":"false","data-vaul-handle":"","aria-hidden":"true",...r},C.default.createElement("span",{"data-vaul-handle-hitarea":"","aria-hidden":"true"},t))});Wa.displayName="Drawer.Handle";function Hl({onDrag:e,onOpenChange:t,open:r,...o}){let{onNestedDrag:n,onNestedOpenChange:a,onNestedRelease:i}=Bt();if(!n)throw new Error("Drawer.NestedRoot must be placed in another drawer");return C.default.createElement($a,{nested:!0,open:r,onClose:()=>{a(!1)},onDrag:(l,u)=>{n(l,u),e?.(l,u)},onOpenChange:l=>{l&&a(l),t?.(l)},onRelease:i,...o})}function $l(e){let t=Bt(),{container:r=t.container,...o}=e;return C.default.createElement(he.Portal,{container:r,...o})}var Se={Root:$a,NestedRoot:Hl,Content:za,Overlay:_a,Trigger:he.Trigger,Portal:$l,Handle:Wa,Close:he.Close,Title:he.Title,Description:he.Description};var Yr=require("react");function Ga(){let[e,t]=(0,Yr.useState)({width:100,height:100});return(0,Yr.useEffect)(()=>{function r(){t({width:window.innerWidth,height:window.innerHeight})}return window.addEventListener("resize",r),r(),()=>window.removeEventListener("resize",r)},[]),e}var gr=require("react/jsx-runtime"),Ua=()=>(0,gr.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"lucide lucide-x",children:[(0,gr.jsx)("path",{d:"M18 6 6 18"}),(0,gr.jsx)("path",{d:"m6 6 12 12"})]});var _=require("react/jsx-runtime"),Xr=({shouldScaleBackground:e=!1,...t})=>(0,_.jsx)(Se.Root,{direction:"right",shouldScaleBackground:e,...t});Xr.displayName="Drawer";var _l=Se.Trigger,Ka=Se.Close,zl=Se.Portal,ja=hr.forwardRef(({className:e,...t},r)=>(0,_.jsx)(Se.Overlay,{className:s("fixed inset-0 z-40 bg-black/75 !m-0 !p-0 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:r}));ja.displayName=Se.Overlay.displayName;var Wl=(0,Za.cva)("fixed focus-visible:outline-0 z-50 gap-4 bg-white shadow-lg dark:bg-[#2B2B2B] dark:text-white transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500 dark:border-none !select-text",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top rounded-b-lg",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom rounded-t-lg",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right"},size:{default:"sm:max-w-[512px]",full:"!max-w-full w-full"}},defaultVariants:{side:"right",size:"default"}}),Ya=hr.forwardRef(({side:e="right",size:t="default",hideCloseButton:r,usePortal:o=!0,showOverlay:n=!0,className:a,children:i,id:l,...u},d)=>{let p=(0,_.jsxs)(_.Fragment,{children:[n&&(0,_.jsx)(ja,{}),(0,_.jsxs)(Se.Content,{ref:d,className:s(Wl({side:e,size:t}),a),...u,children:[(0,_.jsx)("button",{className:"bg-gray-300 block md:!hidden mx-auto mt-4 md:!mt-0 h-1.5 w-[80px] rounded-full opacity-70 transition-opacity hover:opacity-100 relative"}),t==="full"&&(0,_.jsx)("style",{children:`
|
|
4
4
|
body { pointer-events: auto !important; }
|