@6thbridge/hexa 0.0.55 → 0.0.57

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.
@@ -1,5 +1,5 @@
1
1
   WARN  Issue while reading "/Users/joachim/.nvm/versions/node/v20.17.0/lib/node_modules/npmrc". EISDIR: illegal operation on a directory, read
2
2
 
3
- > @6thbridge/hexa@0.0.55 lint /Users/joachim/Documents/dev/payfusion/payfusion-component-library/packages/6thbridge-hexa
3
+ > @6thbridge/hexa@0.0.57 lint /Users/joachim/Documents/dev/payfusion/ev-payfusion-component-library/packages/6thbridge-hexa
4
4
  > eslint . --max-warnings 0
5
5
 
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";var Er=Object.create;var Re=Object.defineProperty;var Ar=Object.getOwnPropertyDescriptor;var Ir=Object.getOwnPropertyNames;var Br=Object.getPrototypeOf,Mr=Object.prototype.hasOwnProperty;var Vr=(e,t,o)=>t in e?Re(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o;var Hr=(e,t)=>{for(var o in t)Re(e,o,{get:t[o],enumerable:!0})},Xt=(e,t,o,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Ir(t))!Mr.call(e,n)&&n!==o&&Re(e,n,{get:()=>t[n],enumerable:!(r=Ar(t,n))||r.enumerable});return e};var w=(e,t,o)=>(o=e!=null?Er(Br(e)):{},Xt(t||!e||!e.__esModule?Re(o,"default",{value:e,enumerable:!0}):o,e)),Or=e=>Xt(Re({},"__esModule",{value:!0}),e);var Yt=(e,t,o)=>Vr(e,typeof t!="symbol"?t+"":t,o);var ca={};Hr(ca,{AmountAction:()=>_t,Banner:()=>Oo,Button:()=>fe,CopyableLabel:()=>zo,Country:()=>Ao,CurrencySymbolMap:()=>Zt,DateAction:()=>Kt,DebouncedInput:()=>st,DevBanner:()=>Ko,Dialog:()=>tt,Drawer:()=>or,DrawerClose:()=>Yo,DrawerRoot:()=>ct,FlagComponent:()=>ae,FormLabel:()=>H,HasResourcePermission:()=>kr,Input:()=>X,Loader:()=>be,LocaleSelector:()=>lr,OTPInput:()=>Ho,PageDataToolbar:()=>yt,Pagination:()=>ht,PasswordInput:()=>Ft,PermissionsContext:()=>je,PermissionsProvider:()=>Dr,PhoneInput:()=>Mt,Popover:()=>Ce,PopoverContent:()=>ee,PopoverRoot:()=>re,PopoverTrigger:()=>j,Select:()=>Io,Sidebar:()=>xr,Status:()=>wr,Table:()=>Rr,Textarea:()=>Et,Tooltip:()=>De,TooltipContent:()=>qe,TooltipProvider:()=>Nt,TooltipRoot:()=>Pt,TooltipTrigger:()=>Lt,buttonVariants:()=>Se,cn:()=>a,useHasPermission:()=>bt,usePermissions:()=>zt});module.exports=Or(ca);var qt=w(require("react")),Z=w(require("@radix-ui/react-tooltip"));var jt=require("clsx"),Jt=require("tailwind-merge");function a(...e){return(0,Jt.twMerge)((0,jt.clsx)(e))}var te=require("react/jsx-runtime"),Nt=Z.Provider,Pt=Z.Root,Lt=Z.Trigger,qe=qt.forwardRef(({className:e,sideOffset:t=2,...o},r)=>(0,te.jsx)(Z.Content,{ref:r,sideOffset:t,className:a("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),...o,children:o.children}));qe.displayName=Z.Content.displayName;var De=({trigger:e,children:t,contentClassName:o,triggerClassName:r,asChild:n=!0,side:i,sideOffset:l,align:s,alignOffset:d,delayDuration:c=100,hasArrow:p=!0,arrowClassName:u,...m})=>(0,te.jsx)(Nt,{children:(0,te.jsx)(Pt,{delayDuration:c,...m,children:(0,te.jsxs)("div",{className:"flex justify-center items-center",children:[(0,te.jsx)(Lt,{asChild:n,className:r,children:e}),(0,te.jsxs)(qe,{side:i,sideOffset:l,align:s,alignOffset:d,className:o,children:[t,p&&(0,te.jsx)(Z.Arrow,{className:a("fill-white",u)})]})]})})});De.displayName="Tooltip";var oo=w(require("react"));var Qt=w(require("react")),Rt=w(require("@radix-ui/react-label")),eo=require("class-variance-authority");var to=require("react/jsx-runtime"),Wr=(0,eo.cva)("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Dt=Qt.forwardRef(({className:e,...t},o)=>(0,to.jsx)(Rt.Root,{ref:o,className:a(Wr(),e),...t}));Dt.displayName=Rt.Root.displayName;var Te=require("react/jsx-runtime"),H=oo.default.forwardRef(({className:e,children:t,showAsterisk:o,error:r,...n},i)=>(0,Te.jsx)(Dt,{ref:i,className:a(r&&"text-red-500",e),...n,children:o?(0,Te.jsxs)("p",{children:[t,(0,Te.jsx)("span",{className:"text-red-500",children:"*"})]}):t}));H.displayName="FormLabel";var ke=require("react/jsx-runtime"),be=({size:e=16,colour:t="primary"})=>(0,ke.jsxs)("svg",{className:"animate-spin",width:e,height:e,viewBox:"0 0 20 20",fill:"none",children:[(0,ke.jsx)("circle",{cx:"10",cy:"10",r:"9.25",stroke:"transparent",strokeWidth:"1.5"}),(0,ke.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 Qe=w(require("react")),ro=require("@radix-ui/react-slot"),ao=require("class-variance-authority");var _=require("react/jsx-runtime"),Se=(0,ao.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"}}),fe=Qe.forwardRef(({className:e,variant:t="primary",size:o,asChild:r=!1,isLoading:n=!1,leftNode:i,rightNode:l,LoaderSize:s,...d},c)=>{let p=r?ro.Slot:"button",{children:u,disabled:m,...g}=d,f=Qe.useRef(null);return(0,_.jsx)(p,{className:a(Se({variant:t,size:o,className:e})),ref:f||c,disabled:m||n,...g,children:(0,_.jsx)("div",{className:"flex font-medium justify-center items-center gap-2",children:n?(0,_.jsx)(_.Fragment,{children:(0,_.jsx)("span",{className:"mx-auto",children:(0,_.jsx)(be,{size:s,colour:"secondary"})})}):(0,_.jsxs)(_.Fragment,{children:[i,u,l]})})})});fe.displayName="Button";var Tt=w(require("react"));var et=require("class-variance-authority");var no=w(require("react")),io=require("react/jsx-runtime"),K=no.default.forwardRef(({className:e,children:t,error:o,...r},n)=>{let i=o??t;return i?(0,io.jsx)("p",{ref:n,className:a("text-xs font-normal text-[#F04248]",e),...r,children:i}):null});K.displayName="ErrorMessage";var so=w(require("react")),lo=require("react/jsx-runtime"),$=so.default.forwardRef(({className:e,...t},o)=>(0,lo.jsx)("div",{ref:o,className:a("text-sm text-[#8E98A8",e),...t}));$.displayName="FormDescription";var U=require("react/jsx-runtime"),Gr=(0,et.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"}}),po=Tt.forwardRef(({className:e,status:t,type:o,...r},n)=>(0,U.jsx)("input",{type:o,className:a(Gr({status:t}),e),ref:n,...r}));po.displayName="BaseInnerInput";var oe=(0,et.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"}}),co=(0,et.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"}}),X=Tt.forwardRef(({className:e,status:t="default",disabled:o,error:r,isLoading:n,sideNodeClassName:i,showAsterisk:l,label:s,description:d,...c},p)=>{let u=t;return r&&(u="error"),n&&(u="loading"),o&&(u="prefilled"),(0,U.jsxs)("div",{className:"relative space-y-1 w-full",children:[s&&(0,U.jsx)(H,{showAsterisk:l,error:r,children:s}),(0,U.jsxs)("div",{className:a(oe({status:u}),c.leftNode?"pl-0":"",c.rightNode?"pr-0":"",e),children:[c.leftNode?(0,U.jsx)("div",{className:a(co({status:u,side:"left"}),i),children:c.leftNode}):null,(0,U.jsx)(po,{ref:p,disabled:n||o,className:a({"!pl-3":c.leftNode&&t!=="neutral","!pr-3":c.rightNode&&t!=="neutral"}),...c}),c.rightNode?(0,U.jsx)("div",{className:a(co({status:u,side:"right"}),i),children:c.rightNode}):null]}),d&&(0,U.jsx)($,{className:"text-gray-400 text-sm !font-normal",children:d}),(0,U.jsx)(K,{error:r})]})});X.displayName="Input";var Ae=require("react");var Fe=require("react/jsx-runtime"),mo=()=>(0,Fe.jsxs)("svg",{width:"18",height:"14",viewBox:"0 0 18 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,Fe.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,Fe.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 Ee=require("react/jsx-runtime"),uo=()=>(0,Ee.jsxs)("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,Ee.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,Ee.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 kt=require("react/jsx-runtime"),fo=()=>(0,kt.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,kt.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 St=require("react/jsx-runtime"),go=()=>(0,St.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,St.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 O=require("react/jsx-runtime"),Co=[{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:"8 Characters",key:"eight-chars",RegExp:/.{8}/,validated:!1}],Ft=({onValidate:e,onChange:t,disableValidation:o,...r})=>{let[n,i]=(0,Ae.useState)(!1),[l,s]=(0,Ae.useState)(Co),d=m=>Co.map(g=>({...g,validated:g.RegExp.test(m)})),c=m=>{let g=d(m),f=g.every(b=>b.validated);return s(g),f},p=m=>{if(t&&t(m),o)return;let g=m?.target?.value,f=c(g);e&&e(f,g)},u=(0,Ae.useMemo)(()=>(0,O.jsx)("div",{className:"flex items-center gap-2",children:l?.map(m=>(0,O.jsxs)("div",{className:a("text-xs flex items-center gap-0.5",{"text-[#62C554]":m?.validated,"text-[#8E98A8]":!m?.validated}),children:[(0,O.jsx)("span",{className:"",children:m?.validated?(0,O.jsx)(fo,{}):(0,O.jsx)(go,{})}),(0,O.jsx)("span",{className:"",children:m?.label})]},m?.key))}),[l]);return(0,O.jsx)(X,{sideNodeClassName:"!border-l-0",rightNode:n?(0,O.jsx)("button",{type:"button",onClick:()=>i(m=>!m),children:(0,O.jsx)(mo,{})}):(0,O.jsx)("button",{type:"button",onClick:()=>i(m=>!m),children:(0,O.jsx)(uo,{})}),type:n?"text":"password",onChange:p,description:!o&&u,...r})};Ft.displayName="PasswordInput";var ho=require("class-variance-authority");var ge=require("react/jsx-runtime"),Ya=(0,ho.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"}}),Et=({className:e,status:t="default",disabled:o,error:r,isLoading:n,showAsterisk:i,label:l,description:s,...d})=>{let c=t;return r&&(c="error"),n&&(c="loading"),o&&(c="prefilled"),(0,ge.jsxs)("div",{className:"relative space-y-1",children:[(0,ge.jsx)(H,{showAsterisk:i,error:r,children:l}),(0,ge.jsx)("textarea",{className:a("min-h-[80px]",oe({status:c}),e),disabled:n||o,...d}),(0,ge.jsx)($,{className:"text-gray-400 text-sm !font-normal",children:s}),(0,ge.jsx)(K,{error:r})]})};Et.displayName="Textarea";var he=w(require("react"));var se=w(require("react")),A=require("cmdk"),Lo=require("lucide-react");var Be=w(require("react")),N=w(require("@radix-ui/react-dialog"));var Ie=require("react/jsx-runtime"),yo=()=>(0,Ie.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,Ie.jsx)("path",{d:"M18 6 6 18"}),(0,Ie.jsx)("path",{d:"m6 6 12 12"})]});var x=require("react/jsx-runtime"),zr=N.Root,Zr=N.Trigger,vo=N.Portal,bo=Be.forwardRef(({className:e,...t},o)=>(0,x.jsx)(N.Overlay,{ref:o,className:a("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}));bo.displayName=N.Overlay.displayName;var At=Be.forwardRef(({className:e,hideCloseButton:t,children:o,...r},n)=>(0,x.jsxs)(vo,{children:[(0,x.jsx)(bo,{}),(0,x.jsxs)(N.Content,{ref:n,className:a("fixed left-[50%] top-[50%] z-50 grid w-full 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),...r,children:[o,!t&&(0,x.jsxs)(N.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",children:[(0,x.jsx)(yo,{}),(0,x.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));At.displayName=N.Content.displayName;var xo=({className:e,...t})=>(0,x.jsx)("div",{className:a("flex flex-col space-y-1.5 text-left",e),...t});xo.displayName="DialogHeader";var wo=({className:e,...t})=>(0,x.jsx)("div",{className:a("flex flex-row justify-end sm:space-x-2",e),...t});wo.displayName="DialogFooter";var No=Be.forwardRef(({className:e,...t},o)=>(0,x.jsx)(N.Title,{ref:o,className:a("text-xl font-semibold leading-none tracking-tight",e),...t}));No.displayName=N.Title.displayName;var Po=Be.forwardRef(({className:e,...t},o)=>(0,x.jsx)(N.Description,{ref:o,className:a("text-sm text-gray-500",e),...t}));Po.displayName=N.Description.displayName;var tt=({trigger:e=void 0,children:t,open:o,onOpenChange:r,hideCloseButton:n,footer:i,title:l,description:s,contentClassName:d,headerClassName:c,titleClassName:p,descriptionClassName:u,footerClassName:m,asChild:g=!0,onOpenAutoFocus:f,onCloseAutoFocus:b,onEscapeKeyDown:L,onInteractOutside:E,onPointerDownOutside:Q,...ve})=>(0,x.jsxs)(zr,{...ve,open:o,onOpenChange:r,children:[(0,x.jsx)(Zr,{asChild:g,children:e}),(0,x.jsx)(vo,{children:(0,x.jsxs)(At,{className:d,hideCloseButton:n,onOpenAutoFocus:f,onCloseAutoFocus:b,onEscapeKeyDown:L,onPointerDownOutside:Q,onInteractOutside:E,children:[l||s?(0,x.jsxs)(xo,{className:c,children:[l&&(0,x.jsx)(No,{className:p,children:l}),s&&(0,x.jsx)(Po,{className:u,children:s})]}):(0,x.jsx)(x.Fragment,{}),t,i&&(0,x.jsx)(wo,{className:m,children:i})]})})]});tt.displayName=N.Dialog.displayName;var B=require("react/jsx-runtime"),Me=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command,{ref:o,className:a("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t}));Me.displayName=A.Command.displayName;var Ve=se.forwardRef(({className:e,CommandInputContainerClassName:t,loading:o,...r},n)=>(0,B.jsxs)("div",{className:a("flex items-center border-0 px-3 gap-2",t),"cmdk-input-wrapper":"",children:[o?(0,B.jsx)(be,{size:16,colour:"secondary"}):(0,B.jsx)(Lo.Search,{className:"mr-2 h-4 w-4 shrink-0 opacity-50"}),(0,B.jsx)(A.Command.Input,{ref:n,className:a("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:o,...r})]}));Ve.displayName=A.Command.Input.displayName;var He=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command.List,{ref:o,className:a("overflow-y-auto overflow-x-hidden",e),...t}));He.displayName=A.Command.List.displayName;var Oe=se.forwardRef((e,t)=>(0,B.jsx)(A.Command.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));Oe.displayName=A.Command.Empty.displayName;var We=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command.Group,{ref:o,className:a("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}));We.displayName=A.Command.Group.displayName;var _r=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command.Separator,{ref:o,className:a("-mx-1 h-px bg-border",e),...t}));_r.displayName=A.Command.Separator.displayName;var Ge=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command.Item,{ref:o,className:a("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}));Ge.displayName=A.Command.Item.displayName;var Kr=({className:e,...t})=>(0,B.jsx)("span",{className:a("ml-auto text-xs tracking-widest text-muted-foreground",e),...t});Kr.displayName="CommandShortcut";var Ro=w(require("react")),Y=w(require("@radix-ui/react-popover"));var le=require("react/jsx-runtime"),re=Y.Root,j=Y.Trigger,ee=Ro.forwardRef(({className:e,align:t="center",sideOffset:o=4,portal:r=!0,...n},i)=>r?(0,le.jsx)(Y.Portal,{children:(0,le.jsx)(Y.Content,{ref:i,align:t,sideOffset:o,className:a("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,le.jsx)(Y.Content,{ref:i,align:t,sideOffset:o,className:a("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}));ee.displayName=Y.Content.displayName;var Ce=({trigger:e,children:t,open:o,onOpenChange:r,contentClassName:n,asChild:i=!0,align:l,side:s,alignOffset:d,triggerClassName:c,sideOffset:p,onOpenAutoFocus:u,onCloseAutoFocus:m,portal:g=!0,...f})=>(0,le.jsxs)(re,{...f,open:o,onOpenChange:r,children:[(0,le.jsx)(j,{asChild:i,className:c,children:e}),(0,le.jsx)(ee,{alignOffset:d,sideOffset:p,side:s,align:l,className:n,onOpenAutoFocus:u,onCloseAutoFocus:m,portal:g,children:t})]});Ce.displayName=Y.Root.displayName;var It=w(require("react")),G=w(require("@radix-ui/react-scroll-area"));var ce=require("react/jsx-runtime"),ze=It.forwardRef(({className:e,viewPortClassName:t,children:o,...r},n)=>(0,ce.jsxs)(G.Root,{ref:n,className:a("relative overflow-hidden",e),...r,children:[(0,ce.jsx)(G.Viewport,{className:a("h-full w-full rounded-[inherit]",t),children:o}),(0,ce.jsx)(Do,{}),(0,ce.jsx)(G.Corner,{})]}));ze.displayName=G.Root.displayName;var Do=It.forwardRef(({className:e,orientation:t="vertical",...o},r)=>(0,ce.jsx)(G.ScrollAreaScrollbar,{ref:r,orientation:t,className:a("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),...o,children:(0,ce.jsx)(G.ScrollAreaThumb,{className:"relative flex-1 rounded-full bg-[#959595] transition hover:bg-[#808080]"})}));Do.displayName=G.ScrollAreaScrollbar.displayName;var F=require("react/jsx-runtime"),To=({className:e,value:t,placeholder:o="",status:r,disabled:n})=>(0,F.jsx)(j,{asChild:!0,disabled:n,children:(0,F.jsxs)("button",{disabled:n,className:a(oe({status:r}),"[&>span]:justify-start [&>span]:items-center gap-2 flex h-12 w-full items-center justify-between goup",t?"":"text-[#79818C]",e),children:[t??o??"Select options...",(0,F.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",className:" data-[state=open]:goup-rotate-180",children:(0,F.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"})})]})}),ot=({options:e=[],value:t,onChange:o,containerClassName:r,placeholder:n,disabled:i,loading:l,optionComponent:s,children:d,modal:c=!1,hideSearch:p,className:u,inputValue:m,onValueChange:g,onInputValueChange:f})=>{let[b,L]=he.useState(!1),E=he.useRef(null),[Q,ve]=he.useState(void 0);return he.useLayoutEffect(()=>{E.current&&ve(E.current.clientWidth)},[E.current]),(0,F.jsxs)(re,{modal:c,open:b,onOpenChange:L,children:[(0,F.jsx)("div",{className:a("w-full",u),ref:E,children:d}),(0,F.jsx)(ee,{portal:!c,className:"p-0 min-w-[200px]",style:{width:Q},children:(0,F.jsxs)(Me,{className:a("relative max-h-[270px]",{"mt-2":!p}),children:[!p&&(0,F.jsx)(Ve,{loading:l,placeholder:n??"Search options...",onValueChange:f,value:m,CommandInputContainerClassName:"mx-2 border rounded-md border-[#DEDEDE]"}),(0,F.jsx)(ze,{viewPortClassName:"max-h-[225px]",className:a("w-full px-0 h-full overflow-y-auto",r),children:(0,F.jsxs)(He,{children:[!p&&(0,F.jsx)(Oe,{children:"No result found."}),(0,F.jsx)(We,{className:"w-full",children:e?.map(I=>(0,F.jsx)(Ge,{defaultValue:t?.label,value:I.label,disabled:i,onSelect:()=>{o(I),L(!1),g?.(I?.value)},children:s?s(I):I.label},I.value))})]})})]})})]})};var Bt=[{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"}],ko=()=>{let e={};return Bt?.forEach(t=>{e[t?.internetCountryCode]=t?.countryName}),e};var Ze=w(require("react")),rt=w(require("react-phone-number-input")),Fo=w(require("react-phone-number-input/flags"));var de=require("react/jsx-runtime"),$r=e=>(0,de.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"none",...e,children:[(0,de.jsx)("rect",{width:"32",height:"32",fill:"#60A5FA"})," ",(0,de.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,de.jsx)("rect",{x:"2",y:"28",width:"28",height:"3",fill:"#D1D5DB"}),(0,de.jsx)("path",{d:"M0 16H32M8 0V32M16 0V32M24 0V32",stroke:"#2563EB",strokeWidth:"0.5",vectorEffect:"non-scaling-stroke"}),(0,de.jsx)("path",{d:"M0 16H32",stroke:"#2563EB",strokeWidth:"1",vectorEffect:"non-scaling-stroke"})]}),So=$r;var C=require("react/jsx-runtime"),Mt=Ze.forwardRef(({className:e,onChange:t,defaultCountry:o="NG",modal:r,showAsterisk:n,label:i,description:l,error:s,...d},c)=>{let p=u=>(0,C.jsx)(Ur,{...u,status:d.status,modal:r});return(0,C.jsxs)("div",{className:"relative space-y-1",children:[(0,C.jsx)(H,{showAsterisk:n,error:s,children:i}),(0,C.jsx)(rt.default,{ref:c,className:a("flex",e),flagComponent:ae,countrySelectComponent:p,inputComponent:Eo,defaultCountry:o,onChange:u=>{t&&t?.(u)},...d}),(0,C.jsx)($,{className:"text-gray-400 text-sm !font-normal",children:l}),(0,C.jsx)(K,{error:s})]})});Mt.displayName="PhoneInput";var Eo=Ze.forwardRef(({className:e,...t},o)=>(0,C.jsx)(X,{className:a("!rounded-s-none h-10",e),...t,ref:o}));Eo.displayName="InputComponent";var Ur=({disabled:e,value:t,onChange:o,options:r,status:n,modal:i})=>{let l=Ze.useCallback(s=>{o(s)},[o]);return(0,C.jsxs)(re,{modal:i,children:[(0,C.jsx)(j,{disabled:e,children:(0,C.jsxs)("div",{className:a(oe({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,C.jsx)(ae,{country:t,countryName:t}),(0,C.jsx)("svg",{className:a("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,C.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,C.jsx)(ee,{portal:!i,className:"w-[200px] md:w-[300px] p-0",children:(0,C.jsx)(Me,{children:(0,C.jsx)(He,{children:(0,C.jsxs)(ze,{className:"h-72",children:[(0,C.jsx)(Ve,{placeholder:"Search country..."}),(0,C.jsx)(Oe,{children:"No country found."}),(0,C.jsx)(We,{children:r.filter(s=>s.value).map(s=>(0,C.jsxs)(Ge,{className:"gap-2",onSelect:()=>l(s.value),children:[(0,C.jsx)(ae,{country:s.value,countryName:s.label}),(0,C.jsx)("span",{className:"flex-1 text-sm",children:s.label}),s.value&&(0,C.jsx)("span",{className:"text-[#191919]/50 text-sm dark:text-white",children:`+${rt.getCountryCallingCode(s.value)}`}),(0,C.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",className:a("ml-auto",s.value===t?"opacity-100":"opacity-0"),children:(0,C.jsx)("path",{d:"M4 8.00008L6.66353 10.6636L12 5.33655",stroke:"#959595",strokeWidth:"1.06667",strokeLinecap:"round",strokeLinejoin:"round"})})]},`${s.value}-${s.label}`))})]})})})})]})},ae=({country:e,countryName:t,className:o})=>{let r=Fo.default[e];return e==="GLOBAL"?(0,C.jsx)("span",{className:a("bg-white/20 flex h-4 w-6 overflow-hidden rounded-sm",o),children:(0,C.jsx)(So,{className:"w-full h-[90%]"})}):(0,C.jsx)("span",{className:a("bg-white/20 flex h-4 w-6 overflow-hidden rounded-sm",o),children:r&&(0,C.jsx)(r,{title:t})})};ae.displayName="FlagComponent";var D=require("react/jsx-runtime"),Xr=ko(),Yr=({className:e,value:t,placeholder:o="",status:r,disabled:n})=>(0,D.jsx)(j,{asChild:!0,disabled:n,children:(0,D.jsxs)("button",{disabled:n,className:a(oe({status:r}),"[&>span]:justify-start [&>span]:items-center gap-2 flex w-full items-center justify-between goup",t?"":"text-[#79818C]",e),children:[t?(0,D.jsxs)("div",{className:"flex gap-2 items-center",children:[(0,D.jsx)(ae,{country:t,countryName:t,className:"ml-1 !w-6 h-5"}),(0,D.jsxs)("span",{className:"",children:[" ",Xr[t]]})]}):o??"Select options...",(0,D.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",className:" data-[state=open]:goup-rotate-180",children:(0,D.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"})})]})}),Ao=({hideSearch:e=!0,showAsterisk:t,label:o,description:r,error:n,...i})=>{let l=Bt?.map(s=>({value:s?.internetCountryCode,label:s?.countryName,...s}));return(0,D.jsxs)("div",{className:"relative space-y-1",children:[(0,D.jsx)(H,{showAsterisk:t,error:n,children:o}),(0,D.jsx)(ot,{options:l,hideSearch:e,optionComponent:s=>(0,D.jsxs)("div",{className:"w-full flex items-center gap-2",children:[(0,D.jsx)(ae,{country:s?.internetCountryCode,countryName:s?.label,className:"ml-2 !w-6 !h-5"}),(0,D.jsx)("span",{className:"flex-1 text-sm",children:s?.label})]}),...i,children:(0,D.jsx)(Yr,{value:i?.value?.value,status:i?.status,placeholder:i?.placeholder??" Select Country"})}),(0,D.jsx)($,{className:"text-gray-400 text-sm !font-normal",children:r}),(0,D.jsx)(K,{error:n})]})};var pe=require("react/jsx-runtime"),Io=({showAsterisk:e,label:t,description:o,error:r,hideSearch:n=!0,status:i,...l})=>(0,pe.jsxs)("div",{className:"relative space-y-1",children:[(0,pe.jsx)(H,{showAsterisk:e,error:r,children:t}),(0,pe.jsx)(ot,{hideSearch:n,...l,containerClassName:"h-full",children:(0,pe.jsx)(To,{disabled:l?.disabled,placeholder:l?.placeholder??"Select",status:i,value:l?.value?.label??l?.value?.value})}),(0,pe.jsx)($,{className:"text-gray-400 text-sm !font-normal",children:o}),(0,pe.jsx)(K,{error:r})]});var Bo=w(require("react-otp-input"));var Mo=require("class-variance-authority"),Vo=require("react"),Vt=require("react/jsx-runtime"),jr=(0,Mo.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",{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"}}),Ho=({numInputs:e=4,inputStyle:t,containerStyle:o,placeholder:r="-",status:n,...i})=>{let l=(0,Vo.useMemo)(()=>r||new Array(e).fill("").reduce((c,p)=>c+=p,""),[e,r]);return(0,Vt.jsx)(Bo.default,{numInputs:e,placeholder:l,containerStyle:a("w-full",o),inputStyle:a(jr({status:n}),t),renderInput:s=>(0,Vt.jsx)("input",{...s}),...i})};var at=require("react"),h=require("react/jsx-runtime"),Jr=({type:e})=>e==="gray"?(0,h.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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,h.jsx)("svg",{stroke:"#70B6F6",fill:"#70B6F6","stroke-width":"0",viewBox:"0 0 16 16",height:"24",width:"24",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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,h.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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,h.jsx)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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,h.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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"})}),Oo=({type:e="info",title:t,description:o,open:r,showCloseButton:n,bottomNode:i,sideNode:l,onClose:s,showIcon:d=!0})=>{let[c,p]=(0,at.useState)(r);(0,at.useEffect)(()=>{p(r)},[r]);let u="",m="";switch(e){case"gray":u="#eeeef0",m="#79818c";break;case"info":u="#ebf5fd",m="#70B6F6";break;case"warning":u="#fff8df",m="#ffc700";break;case"success":u="#e0f9f0",m="#49e0aa";break;case"danger":u="#fde8e9",m="#f3777c";break;default:u="#eeeef0",m="#79818c";break}function g(){p(!1),s&&s()}return c?(0,h.jsxs)("div",{className:"w-full shadow-lg transform flex items-center rounded-md",style:{background:u||"#ebf5fd"},children:[(0,h.jsx)("div",{className:"flex-none absolute rounded-l-[2px] rounded-l-4px h-[4px] w-full top-0",style:{background:m||"#70B6F6"}}),(0,h.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,h.jsxs)("div",{className:"flex flex-row gap-2.5 items-start w-full h-full",children:[d&&(0,h.jsx)("div",{className:"h-full flex justify-end",children:(0,h.jsx)(Jr,{type:e})}),(0,h.jsxs)("div",{className:"w-full gap-3 h-full flex flex-col md:flex-row items-start justify-between",children:[(0,h.jsxs)("div",{className:"flex-1 gap-3 h-full flex flex-col items-start justify-between",children:[(t||o)&&(0,h.jsxs)("div",{children:[t&&(0,h.jsx)("div",{className:"text-sm font-bold text-[#191919]",children:t}),o&&(0,h.jsx)("div",{className:"text-sm font-normal text-[#5D5D5D] mt-1",children:o})]}),i]}),l]})]}),n&&(0,h.jsx)("div",{className:"w-1/10 h-full flex flex-col justify-start items-center",children:(0,h.jsx)("button",{onClick:g,children:(0,h.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,h.jsx)("path",{d:"M3.3335 3.33337L12.6662 12.6661",stroke:"#191919",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,h.jsx)("path",{d:"M3.33429 12.6661L12.667 3.33337",stroke:"#191919",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]})})})]})]}):null};var Go=require("react"),nt=require("lucide-react"),it=require("framer-motion");var ne=require("react/jsx-runtime"),zo=({text:e,textToCopy:t,onCopy:o,iconsPosition:r="right",clampText:n=!0,textClassName:i})=>{let[l,s]=(0,Go.useState)(!1),d=()=>{navigator.clipboard.writeText(t??e).then(()=>{s(!0),o?.(),setTimeout(()=>s(!1),2e3)})},c=l?nt.CheckIcon:nt.Copy;return(0,ne.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:[r==="left"&&(0,ne.jsx)(Wo,{Icon:c,onClick:d,copied:l}),(0,ne.jsx)("span",{className:a({"truncate max-w-[100px]":n},i),children:e}),r==="right"&&(0,ne.jsx)(Wo,{Icon:c,onClick:d,copied:l})]})},Wo=({Icon:e,onClick:t,copied:o})=>(0,ne.jsx)(it.AnimatePresence,{mode:"wait",children:(0,ne.jsx)(it.motion.div,{initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2},onClick:t,children:(0,ne.jsx)(e,{className:`w-5 h-5 ${o?"text-green-500":"text-gray-500 hover:text-gray-700 transition"}`})},o?"check":"copy")});var _e=require("react");var Zo=require("lucide-react"),Ht=require("react/jsx-runtime"),st=({value:e,onChange:t,debounce:o=500,addon:r,...n})=>{let[i,l]=(0,_e.useState)(e??""),s=d=>l(d.target.value);return(0,_e.useEffect)(()=>{e&&l(e)},[e]),(0,_e.useEffect)(()=>{let d=setTimeout(()=>{t(i)},o);return()=>clearTimeout(d)},[i,o,t]),(0,Ht.jsx)(X,{leftNode:r??(0,Ht.jsx)(Zo.Search,{className:" w-4 h-4 text-gray-400"}),sideNodeClassName:"bg-transparent !pr-0 !w-4 border-0 !min-w-[40px]",...n,className:a("!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:s,value:i})};var Ot=require("react"),_o=require("lucide-react"),T=require("react/jsx-runtime"),Ko=e=>{let{environment:t,branch:o,version:r,deployTime:n,showBanner:i,onClose:l,initDefault:s,removeFromStorage:d,syncLocalStorageToState:c}=e,p=t||process.env.NEXT_PUBLIC_NODE_ENV;return p!=="staging"&&p!=="sandbox"||((0,Ot.useEffect)(()=>{c()},[c]),(0,Ot.useEffect)(()=>{let u;return(p==="staging"||p==="sandbox")&&(u=setInterval(()=>{d(),s()},5*60*1e3)),()=>{u&&clearInterval(u)}},[i,t,l,d,s,p]),!i)?null:(0,T.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,T.jsx)("button",{onClick:l,className:"absolute top-2 right-2",children:(0,T.jsx)(_o.X,{})}),(0,T.jsxs)("div",{className:"space-y-2 text-sm",children:[(0,T.jsxs)("div",{className:"flex gap-2",children:[(0,T.jsx)("span",{className:"font-medium",children:"Environment:"}),(0,T.jsx)("span",{className:"text-blue-600 capitalize",children:p})]}),(0,T.jsxs)("div",{className:"flex gap-2",children:[(0,T.jsx)("span",{className:"font-medium",children:"Branch:"}),(0,T.jsx)("span",{className:"text-green-600 capitalize",children:o||process.env.NEXT_PUBLIC_DEPLOY_BRANCH})]}),(0,T.jsxs)("div",{className:"flex gap-2",children:[(0,T.jsx)("span",{className:"font-medium",children:"Version:"}),(0,T.jsx)("span",{className:"text-purple-600",children:r||process.env.NEXT_PUBLIC_DEPLOY_VERSION})]}),(0,T.jsxs)("div",{className:"flex gap-2",children:[(0,T.jsx)("span",{className:"font-medium",children:"Deploy Time:"}),(0,T.jsx)("span",{className:"text-orange-600",children:n||process.env.NEXT_PUBLIC_DEPLOY_TIME})]})]})]})};var $e=w(require("react")),M=require("vaul"),Xo=require("class-variance-authority");var Ke=require("react/jsx-runtime"),$o=()=>(0,Ke.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,Ke.jsx)("path",{d:"M18 6 6 18"}),(0,Ke.jsx)("path",{d:"m6 6 12 12"})]});var lt=require("react");function Uo(){let[e,t]=(0,lt.useState)({width:window.innerWidth,height:window.innerHeight});return(0,lt.useEffect)(()=>{function o(){t({width:window.innerWidth,height:window.innerHeight})}return window.addEventListener("resize",o),o(),()=>window.removeEventListener("resize",o)},[]),e}var y=require("react/jsx-runtime"),ct=({shouldScaleBackground:e=!0,...t})=>(0,y.jsx)(M.Drawer.Root,{direction:"right",shouldScaleBackground:e,...t});ct.displayName="Drawer";var qr=M.Drawer.Trigger,Yo=M.Drawer.Close,Qr=M.Drawer.Portal,jo=$e.forwardRef(({className:e,...t},o)=>(0,y.jsx)(M.Drawer.Overlay,{className:a("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:o}));jo.displayName=M.Drawer.Overlay.displayName;var ea=(0,Xo.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",{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 sm:max-w-[512px] ",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 sm:max-w-[512px]"}},defaultVariants:{side:"right"}}),Jo=$e.forwardRef(({side:e="right",hideCloseButton:t,className:o,children:r,...n},i)=>(0,y.jsxs)(Qr,{children:[(0,y.jsx)(jo,{}),(0,y.jsxs)(M.Drawer.Content,{ref:i,className:a(ea({side:e}),o),...n,children:[(0,y.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"}),r,!t&&(0,y.jsxs)(M.Drawer.Close,{className:"absolute right-2 top-3 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-secondary",children:[(0,y.jsx)($o,{}),(0,y.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));Jo.displayName=M.Drawer.Content.displayName;var qo=({className:e,...t})=>(0,y.jsx)("div",{className:a("text-lg flex flex-col border-b border-b-gray-200 space-y-1 text-left w-full p-3",e),...t});qo.displayName="DrawerHeader";var Qo=({className:e,...t})=>(0,y.jsx)("div",{className:a("flex flex-col-reverse sm:flex-row m-auto right-0 left-0 p-3 sm:space-x-2 border-t border-t-[#EDEDED] dark:border-t-[#242424] w-full",e),...t});Qo.displayName="DrawerFooter";var er=$e.forwardRef(({className:e,...t},o)=>(0,y.jsx)(M.Drawer.Title,{ref:o,className:a("text-xl font-semibold text-[#191919] dark:text-white",e),...t}));er.displayName=M.Drawer.Title.displayName;var tr=$e.forwardRef(({className:e,...t},o)=>(0,y.jsx)(M.Drawer.Description,{ref:o,className:a("text-xs text-[#5d5c5c] dark:text-white",e),...t}));tr.displayName=M.Drawer.Description.displayName;var or=({trigger:e=void 0,children:t,open:o=void 0,onOpenChange:r=void 0,hideCloseButton:n,footer:i,title:l,description:s,contentClassName:d,headerClassName:c,titleClassName:p,descriptionClassName:u,footerClassName:m,asChild:g=!0,onOpenAutoFocus:f,onCloseAutoFocus:b})=>{let{width:L}=Uo(),E=L<768?"bottom":"right";return(0,y.jsxs)(ct,{open:o,onOpenChange:r,direction:E,children:[(0,y.jsx)(qr,{className:"cursor-pointer",asChild:g,children:e}),(0,y.jsxs)(Jo,{className:a("flex flex-col gap-0 justify-start items-start max-h-[90vh] md:max-h-full w-full !max-w-md",d),side:E,hideCloseButton:n,onOpenAutoFocus:f,onCloseAutoFocus:b,children:[l||s?(0,y.jsxs)(qo,{className:c,children:[l&&(0,y.jsx)(er,{className:p,children:l}),s&&(0,y.jsx)(tr,{className:u,children:s})]}):(0,y.jsx)(y.Fragment,{}),(0,y.jsx)("div",{className:a("flex w-full overflow-y-auto flex-col justify-start items-start p-4 flex-1 h-[30px]"),children:t}),i&&(0,y.jsx)(Qo,{className:m,children:i})]})]})};var Wt=require("react/jsx-runtime"),rr=()=>(0,Wt.jsx)("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 20 20","aria-hidden":"true",className:"h-5 w-5",height:"1em",width:"1em",xmlns:"http://www.w3.org/2000/svg",children:(0,Wt.jsx)("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})});var me=require("react/jsx-runtime"),ar=e=>(0,me.jsxs)("svg",{viewBox:"0 0 60 30",className:"w-full max-w-md h-auto","aria-label":"Union Jack - Flag of the United Kingdom",...e,children:[(0,me.jsx)("rect",{width:"60",height:"30",fill:"#00247D"}),(0,me.jsx)("path",{d:"M0,0 L60,30 M60,0 L0,30",stroke:"#FFFFFF",strokeWidth:"6"}),(0,me.jsx)("path",{d:"M0,0 L60,30 M60,0 L0,30",stroke:"#CF142B",strokeWidth:"4"}),(0,me.jsx)("path",{d:"M30,0 L30,30 M0,15 L60,15",stroke:"#FFFFFF",strokeWidth:"10"}),(0,me.jsx)("path",{d:"M30,0 L30,30 M0,15 L60,15",stroke:"#CF142B",strokeWidth:"6"})]});var xe=require("react/jsx-runtime"),nr=e=>(0,xe.jsxs)("svg",{viewBox:"0 0 60 40",className:"w-full max-w-md h-auto","aria-label":"Tricolore - Flag of France",...e,children:[(0,xe.jsx)("rect",{x:"0",y:"0",width:"20",height:"40",fill:"#002395"}),(0,xe.jsx)("rect",{x:"20",y:"0",width:"20",height:"40",fill:"#FFFFFF"}),(0,xe.jsx)("rect",{x:"40",y:"0",width:"20",height:"40",fill:"#ED2939"})]});var Ue=require("react/jsx-runtime"),ir=()=>(0,Ue.jsxs)("svg",{width:"20",height:"18",viewBox:"0 0 8 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,Ue.jsx)("path",{d:"M5.50257 12.9395L3.68439 14.7576L1.86621 12.9395",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),(0,Ue.jsx)("path",{d:"M5.50257 5.06055L3.68439 3.24237L1.86621 5.06055",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"})]});var sr=require("@radix-ui/react-popover"),S=require("react/jsx-runtime"),ta=[{key:"en",label:"English"},{key:"fr",label:"French"}],oa=({locale:e})=>e==="fr"?(0,S.jsx)(nr,{width:10}):(0,S.jsx)(ar,{width:10}),ra=({locale:e})=>(0,S.jsx)("div",{className:"px-2 py-1 ",children:(0,S.jsxs)("div",{className:"flex items-center gap-2.5",children:[(0,S.jsx)(oa,{locale:e})," ",(0,S.jsx)("span",{className:"uppercase",children:e}),(0,S.jsx)(ir,{})]})}),lr=({locale:e="en",onChange:t,locales:o=ta})=>(0,S.jsxs)(re,{children:[(0,S.jsx)("div",{className:"flex items-center gap-2 px-2 py-1 rounded-lg shadow border-[0.5px] border-gray-50/50 text-current bg-white/10 ",children:(0,S.jsx)(j,{className:"!p-0 !bg-transparent ",children:(0,S.jsx)(ra,{locale:e})})}),(0,S.jsx)(ee,{side:"bottom",className:"p-0 max-w-max rounded-md overflow-hidden mx-auto mt-2",children:(0,S.jsx)("div",{children:o?.map(r=>(0,S.jsxs)(sr.PopoverClose,{type:"button",className:a("flex items-center gap-3 px-3 py-1 text-sm hover:bg-blue-50 w-full transition-all",{"bg-blue-100":e&&e===r?.key}),onClick:()=>t?.(r?.key),children:[r?.label," ",e&&e===r?.key&&(0,S.jsx)(rr,{})]},r?.key))})})]});var ye=require("react");var dt=require("framer-motion"),pt=require("react"),cr=require("react-icons/hi"),dr=require("react-icons/fi"),pr=require("react-icons/bs");var ue=require("react/jsx-runtime"),Xe=({activeBusiness:e,onTriggerClick:t,iconOnly:o=!1,className:r,rightNode:n})=>(0,ue.jsxs)("div",{id:"sidemenu_business_bar",role:"button",onClick:t||void 0,className:a("relative flex w-full items-center rounded-lg text-black bg-white",{"border-[.5px] border-[#E9EBF8] py-1 px-2":!o,"hover:bg-primary-accent transition-all duration-150 cursor-pointer ":!!t},r),children:[(0,ue.jsx)("section",{className:a("flex items-center justify-center bg-[#E9EBF8] text-primary-main rounded-md mr-3 text-xl font-medium",{"w-10 h-10":!o,"w-full h-10 mr-0":o}),children:e?.name?.charAt(0)||"M"}),!o&&(0,ue.jsxs)("section",{className:" flex-1 flex justify-between items-center relative text-black truncate w-full -space-y-1 tracking-wide",children:[(0,ue.jsxs)("div",{className:"flex-1",children:[(0,ue.jsx)("h2",{className:"text-base truncate capitalize font-medium",children:e?.name}),(0,ue.jsx)("p",{className:"text-sm text-[#A5A5A5] flex items-center",children:e?.email})]}),n]})]});var mr=require("lucide-react"),R=require("react/jsx-runtime"),aa={hidden:{y:"-12px",opacity:0},visible:{y:"0",opacity:1,transition:{type:"spring",damping:25,stiffness:500}},exit:{y:"-12px",opacity:0,transition:{type:"spring",damping:25,stiffness:500}}},ur=({activeBusiness:e,toggleAddBusinessDrawer:t,businesses:o=[],handleSwitchBusiness:r,onLogoutClick:n})=>{let[i,l]=(0,pt.useState)(""),s=(0,pt.useMemo)(()=>{let c=i.toLowerCase();return(o||[]).filter(p=>p.name?.toLowerCase().startsWith(c))},[o,i]),d=c=>l(c.target.value);return(0,R.jsx)(dt.AnimatePresence,{initial:!1,children:(0,R.jsx)(dt.motion.div,{initial:"hidden",animate:"visible",exit:"exit",variants:aa,children:(0,R.jsxs)("div",{className:"w-72 bg-white border rounded-xl shadow-md overflow-hidden p-3",children:[(0,R.jsx)(Xe,{activeBusiness:e,rightNode:(0,R.jsx)("div",{className:"h-3 w-3 bg-[#62C554] rounded-full"}),className:"bg-[#FAFAFA] border-none p-3"}),(0,R.jsx)("div",{className:"mt-3",children:(0,R.jsx)(X,{label:"Search Account",leftNode:(0,R.jsx)(mr.ChevronUp,{className:"h-4 w-4 text-gray-500"}),value:i,onChange:d,placeholder:"Search Account",className:"text-sm"})}),(0,R.jsx)("ul",{className:"max-h-48 overflow-y-auto mt-2 px-1 space-y-2",children:s.map(c=>(0,R.jsx)(Xe,{onTriggerClick:()=>r(c?.clientId||""),activeBusiness:c,rightNode:e.clientId===c.clientId?(0,R.jsx)(cr.HiCheck,{className:"text-primary-600",size:18}):void 0,className:a("bg-white border-none ",{"bg-[#FAFAFA]":e.clientId===c.clientId})},c.clientId))}),(0,R.jsx)("div",{className:"py-2 ",children:(0,R.jsxs)("button",{onClick:t,className:"w-full flex items-center justify-start gap-2 text-sm text-[#0033C7] border-[#BECFFF] border-[0.5px] rounded-lg py-2 px-3 hover:bg-primary-accent transition ",children:[(0,R.jsx)(pr.BsPlus,{size:18,className:"text-primary-main"})," Add Account"]})}),(0,R.jsx)("div",{className:"bg-[#FAFAFA] px-3 py-2 -m-3 mt-4",children:(0,R.jsxs)("button",{className:"w-full flex items-center gap-2 text-sm text-black hover:text-gray-700 transition p-2 hover:bg-primary-accent",onClick:()=>n?.(),children:[(0,R.jsx)(dr.FiLogOut,{size:16})," Log Out"]})})]})})})};var J=require("react/jsx-runtime"),fr=({activeBusiness:e,toggleAddBusinessDrawer:t,toggleShowBusiness:o,businesses:r=[],handleSwitchBusiness:n,iconOnly:i=!1,onLogoutClick:l,isMobile:s})=>(0,J.jsx)("div",{className:"px-4 relative mb-0 ",children:(0,J.jsx)(Ce,{side:s?"top":"right",align:"end",contentClassName:"!bg-transparent !shadow-none !p-0",trigger:(0,J.jsx)("div",{className:"flex items-center w-full",children:(0,J.jsx)(Xe,{activeBusiness:e,onTriggerClick:o,iconOnly:i,rightNode:(0,J.jsx)(na,{className:"stroke-gray-500"})})}),children:(0,J.jsx)(ur,{activeBusiness:e,handleSwitchBusiness:n,toggleAddBusinessDrawer:t,businesses:r,onLogoutClick:l})})}),na=({className:e})=>(0,J.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",className:a("lucide lucide-chevrons-up-down-icon lucide-chevrons-up-down",e),children:[(0,J.jsx)("path",{d:"M7 22l5 5 5-5"}),(0,J.jsx)("path",{d:"M7 4l5-5 5 5"})]});var mt=require("framer-motion"),ut=require("react"),gr=require("react-icons/fi");var v=require("react/jsx-runtime"),ia={hidden:{opacity:0,height:0},visible:{opacity:1,height:"auto",transition:{duration:.3}}},Cr=({isIconsOnly:e,isSidebarCollapsed:t,onToggleSideBar:o,currentPath:r,onNavigate:n,collapseType:i,links:l,appConfig:s,isMobile:d})=>{let[c,p]=(0,ut.useState)({}),u=f=>{p(b=>({...b,[f]:!b[f]}))},m=f=>{if(!!f?.children?.length){e?(o(!t),p(L=>({...L,[f.id]:!0}))):u(f.id);return}n(`/${f.to}`)},g=f=>f?.children?.length?(f.children||[]).some(L=>r===L.to):r===f.to;return(0,ut.useEffect)(()=>{if(t){let f={};l.forEach(b=>{b.children&&b.children.length>0&&b.children.some(L=>r===L.to)&&(f[b.id]=!0)}),p(b=>({...b,...f}))}},[t,l,r]),(0,v.jsx)("ul",{className:"w-[90%] space-y-2.5",children:l.map((f,b)=>{if(f.isHidden||s?.hiddenRoutes?.includes(f.key??""))return null;let L=g(f),E=!!f?.children?.length,Q=c[f.id];return(0,v.jsxs)("div",{className:"mb-1 relative flex flex-col justify-center items-center",onClick:()=>m(f),children:[L&&!d&&(e||!E||!Q)&&(0,v.jsx)("div",{className:"absolute bg-primary-main w-2 h-4 rounded-r-full -translate-y-1/2 top-1/2 left-0"}),(0,v.jsx)("li",{id:f.id,className:a("cursor-pointer transition text-base duration-300 w-full text-[#00000066] font-medium rounded-md mx-auto max-w-full ml-4 p-2",{"bg-[#F6F8FF] text-primary-main":L&&(!Q||!t)},{"hover:bg-gray-100":!L&&(i!=="icons"||!t)},{"bg-white text-primary-main":L},{"flex justify-center text-primary-main":e&&L,"flex justify-center":e&&!L}),children:(0,v.jsxs)("div",{className:a("flex items-center w-full",{"justify-center":e}),children:[(0,v.jsx)(De,{trigger:(0,v.jsx)("span",{className:"w-6",onClick:()=>m(f),children:f.icon}),side:"right",hasArrow:!0,open:e?void 0:!1,children:f.name},b),(i!=="icons"||!t)&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("span",{className:"px-3",children:f.name}),E&&(0,v.jsx)("span",{className:"ml-auto transition-transform duration-300",style:{transform:Q?"rotate(90deg)":"rotate(0deg)"},children:(0,v.jsx)(gr.FiChevronRight,{size:18})})]})]})},f.to),E&&(i!=="icons"||!t)&&(0,v.jsx)(mt.AnimatePresence,{children:Q&&(0,v.jsx)(mt.motion.div,{initial:"hidden",animate:"visible",exit:"hidden",variants:ia,className:"overflow-hidden w-full",children:(0,v.jsxs)("ul",{className:" mt-1 relative ",children:[f.children?.map(I=>{if(I.isHidden)return null;let Le=r===I.to;return(0,v.jsx)("div",{id:I.id,className:a("relative pl-12 bg-blue-100- mt-4"),children:(0,v.jsxs)("li",{className:a("cursor-pointer transition text-base duration-300 px-3 w-full text-black font-medium opacity-40 rounded-md",{"bg-transparent opacity-100 text-primary-main":Le},{"hover:text-primary-main":!Le}),onClick:()=>n(`/${I.to}`),children:[I.name,Le&&(0,v.jsxs)(v.Fragment,{children:[!d&&(0,v.jsx)("div",{className:"absolute bg-primary-main w-2 h-4 rounded-r-full -translate-y-1/2 top-1/2 left-0"}),(0,v.jsx)("div",{id:"vertical-bar-child",className:"h-4 w-0.5 bg-primary-main absolute left-[30px] z-10 -translate-y-1/2 top-1/2 rounded-t-full rounded-b-full "})]})]})})}),(0,v.jsx)("div",{id:"vertical-bar",className:"bg-white rounded-t-full rounded-b-full h-full w-[4px] absolute left-[29px] top-0"})]})})})]},b)})})};var br=require("lucide-react");var V=require("react/jsx-runtime"),hr=()=>(0,V.jsxs)("svg",{width:"100%",height:40,xmlns:"http://www.w3.org/2000/svg",id:"Layer_1","data-name":"Layer 1",viewBox:"0 0 1565.51 377.21",children:[(0,V.jsxs)("g",{children:[(0,V.jsx)("path",{fill:"#0231C5",d:"m277.49,86.74v85.18l-.41,6.31v.21c-.72,5.8-2.38,11.28-4.86,16.35-1.45,3-3.21,5.9-5.28,8.49-1.55,2.07-3.42,4.04-5.28,5.9-1.66,1.55-3.42,3.11-5.28,4.45-1.66,1.24-3.42,2.38-5.28,3.42-1.76.93-3.52,1.76-5.28,2.59-1.24.52-2.48.93-3.83,1.35l-1.45.52-5.28,1.76-5.28,1.76-5.28,1.76-5.28,1.76-10.56,3.52-.52.21v19.15l-.41.1-3.62,1.14-.83.21-2.79.93-2.48.83-1.14.31-3.62,1.14-.62.21-3,.93-2.28.72-1.35.41-3.62,1.14-.41.1-.52.21h-.21v-37.26c0-1.55.31-3,.72-4.45.1-.31.21-.62.41-.93.83-1.86,2.07-3.52,3.62-4.86.41-.31.83-.72,1.35-1.04.72-.52,1.45-.83,2.28-1.24.21-.1.52-.21.72-.31l.21-.1,2.17-.72.62-.21,3.62-1.14,1.14-.41,5.28-1.76.83-.31,3.62-1.14.93-.31,5.28-1.76,5.28-1.76,5.28-1.76,5.28-1.76,3.83-1.24c.52-.1.93-.31,1.45-.52,1.97-.72,3.73-1.76,5.28-2.9,2.07-1.45,3.83-3.21,5.28-5.18,3.21-4.14,5.07-9.42,5.07-14.9v-85.08c0-5.59-1.76-10.76-5.07-15.01-1.45-1.86-3.11-3.52-5.07-4.97q-.1-.1-.21-.1c-1.66-1.24-3.42-2.17-5.28-2.9-1.76-.72-3.52-1.14-5.28-1.45-1.76-.31-3.52-.31-5.28-.21-1.76.1-3.52.41-5.28.93-.21.1-.52.1-.72.21l-4.55,1.45-5.28,1.66-5.28,1.76-5.69,1.55-5.28,1.76-5.28,1.66-5.28,1.76-5.28,1.66-5.28,1.66-5.28,1.76-5.28,1.66-5.28,1.66-5.28,1.76-5.28,1.66-5.28,1.76-5.28,1.66-5.28,1.76-5.69,1.66-5.28,1.76-3.83,1.24c-.52.21-1.04.31-1.55.52-1.86.72-3.73,1.76-5.28,2.9-2.07,1.45-3.83,3.21-5.28,5.18-3.21,4.24-5.07,9.42-5.07,15.01v33.33c0,3.93.83,7.25,2.07,10.04.1.31.21.52.41.83-.1.1-.31.1-.41.21-.83.41-1.55.72-2.28,1.24-.41.21-.83.52-1.35.72-1.24.72-2.48,1.55-3.62,2.38-.1.1-.31.21-.41.31-1.14.83-2.17,1.66-3.21,2.48-.72.62-1.45,1.24-2.07,1.97-.52.52-1.04.93-1.55,1.45-1.24,1.35-2.48,2.69-3.62,4.14-.1.1-.1.21-.21.31-.72.93-1.35,1.76-1.97,2.69-.52-.72-1.04-1.55-1.45-2.28-.72-1.14-1.35-2.28-1.86-3.52-.62-1.24-1.14-2.59-1.66-3.83-2.38-6-3.62-12.42-3.62-18.94v-33.64c0-8.07,1.86-15.94,5.28-22.77,1.45-3,3.21-5.9,5.28-8.49,1.55-2.07,3.42-4.04,5.28-5.9,1.66-1.55,3.42-3.11,5.28-4.45,1.66-1.24,3.42-2.38,5.28-3.42,1.66-.93,3.42-1.76,5.28-2.59,1.35-.52,2.59-1.04,3.93-1.45l1.35-.41,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.8-1.66,5.28-1.76,5.28-1.66,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,1.76-.52c1.14-.41,2.38-.72,3.62-1.04,1.76-.41,3.52-.83,5.28-1.04,1.76-.21,3.52-.41,5.28-.41,1.76-.1,3.52,0,5.28.1,1.76.1,3.52.31,5.28.62,1.76.31,3.52.72,5.28,1.24,1.76.52,3.62,1.14,5.28,1.86,1.76.72,3.62,1.66,5.28,2.59,1.86,1.04,3.62,2.17,5.28,3.42h.1c1.86,1.35,3.62,2.79,5.28,4.45,1.97,1.76,3.73,3.73,5.28,5.8,2.07,2.69,3.83,5.49,5.28,8.49,3.73,7.14,5.59,14.9,5.59,23.08Z"}),(0,V.jsx)("path",{fill:"#0231C5",d:"m184.03,136.63v28.05l-.72.21-1.97.62-3.31,1.04-.21.1-3.62,1.14-1.45.52-2.17.72-.52.1h0l-2.17.72-1.86.62-1.76.52-3.52,1.14h-.1l-3.62,1.14-1.66.52-1.97.62-3.31,1.04-.21.1-3.62,1.14-1.45.52-2.17.72-.52.1-2.69.83-.41.1-3.62,1.14-1.24.41-2.38.72-2.9.93-.62.21-3.62,1.14-1.04.31-1.97.62-.62.21-2.79.93-.83.31-3,.93c-.21.1-.41.1-.62.21-.31.1-.62.21-.83.31-.93.41-1.86.83-2.79,1.35-.83.41-1.76.93-2.59,1.55-.31.21-.72.52-1.04.83-1.35,1.04-2.48,2.17-3.62,3.52-.21.21-.41.52-.62.83-1.14,1.55-2.17,3.21-3,5.07-1.35,3.11-2.07,6.42-2.07,9.94v82.39c0,2.59.72,5.07,2.07,7.14.83,1.35,2.07,2.59,3.42,3.62q.1.1.21.1c1.14.83,2.28,1.45,3.62,1.76,1.14.41,2.38.62,3.62.62,1.14,0,2.38-.1,3.62-.41.31-.1.62-.21.93-.31l2.59-.83,3.62-1.14,3.62-1.14,3.62-1.14,3.62-1.14,1.66-.52c.62-.21,1.24-.52,1.86-.83,1.35-.52,2.48-1.24,3.62-2.17,1.35-1.04,2.59-2.28,3.62-3.73,2.07-2.9,3.21-6.52,3.21-10.25v-58.48l.31-.1,3.62-1.14.21-.1,3.31-1.04,1.97-.62,1.66-.52,3.62-1.14h.1l3.52-1.14,1.76-.52,1.86-.62,3.42-1.14.21-.1,1.14-.41v67.07c0,2.48-.21,5.07-.62,7.45-.21.93-.31,1.76-.52,2.69-.83,3.52-1.97,6.83-3.62,9.94-1.04,2.07-2.28,4.04-3.62,6-1.14,1.55-2.28,3-3.62,4.45-1.14,1.24-2.38,2.38-3.62,3.42-1.14,1.04-2.38,1.86-3.62,2.79-1.14.83-2.38,1.55-3.62,2.28-1.14.62-2.38,1.24-3.62,1.76-.1,0-.21.1-.31.21-1.04.41-2.17.83-3.21,1.24-.31.1-.62.21-.93.31l-2.69.83-7.25,2.28-3.62,1.14-3.62,1.14-1.66.52c-.62.21-1.24.41-1.86.52-1.24.31-2.38.62-3.62.83-1.24.21-2.38.41-3.62.41-1.14.1-2.17.1-3.21.1h-.31c-1.24,0-2.38-.1-3.62-.21-1.24-.1-2.38-.31-3.62-.52s-2.38-.52-3.62-.93c-.72-.21-1.35-.41-2.07-.62-.52-.21-1.04-.41-1.55-.62-1.24-.52-2.38-1.04-3.62-1.66s-2.48-1.35-3.62-2.17c-.52-.31-1.04-.72-1.55-1.04-.72-.52-1.35-1.04-2.07-1.66-1.24-1.04-2.48-2.17-3.62-3.42-1.35-1.35-2.59-2.9-3.62-4.45-1.45-1.97-2.59-4.04-3.62-6.21-2.38-5.18-3.62-10.87-3.62-16.77v-82.39c0-6.62,1.24-13.04,3.62-18.94.52-1.35,1.04-2.59,1.66-3.83s1.24-2.38,1.86-3.52c.41-.83.93-1.55,1.45-2.28.62-.93,1.24-1.86,1.97-2.69,0-.1.1-.21.21-.21,1.14-1.45,2.28-2.79,3.62-4.14.52-.52.93-1.04,1.55-1.45.72-.72,1.35-1.24,2.07-1.86,1.04-.83,2.07-1.76,3.21-2.48.1-.1.31-.21.41-.31,1.14-.83,2.38-1.66,3.62-2.28.41-.21.83-.52,1.35-.72.72-.41,1.55-.83,2.28-1.24.1-.1.21-.1.41-.21.83-.41,1.76-.83,2.59-1.14.21-.1.41-.21.62-.21,1.04-.41,2.17-.83,3.21-1.14l.31-.1,1.04-.31,2.59-.83,2.79-.93.83-.31,3.62-1.14.83-.31,2.79-.83.62-.21,1.97-.62,1.04-.31,3.62-1.14.62-.21,2.9-.93,2.38-.72,1.24-.41,3.62-1.14.41-.1,2.69-.83.52-.1,2.17-.72,1.45-.41,3.62-1.14.21-.1,3.31-1.04,1.97-.62,1.66-.52,3.62-1.14h.1l3.52-1.14,1.76-.52,1.86-.62,2.17-.72h0l.52-.1,2.17-.72,1.45-.52,3.62-1.14.21-.1,3.31-1.04,1.97-.62,1.04-.41Z"})]}),(0,V.jsx)("path",{fill:"#000000",d:"m433.57,86.41c18.92,0,34.54,6.21,46.87,18.62,12.32,12.41,18.49,28.16,18.49,47.26s-6.16,34.85-18.49,47.26c-12.33,12.41-27.95,18.62-46.87,18.62h-35.41v50.51h-42.18V86.41h77.59Zm-6.51,97.38c8.5,0,15.49-2.95,20.96-8.85,5.47-5.9,8.2-13.45,8.2-22.65s-2.73-16.75-8.2-22.65c-5.47-5.9-12.46-8.85-20.96-8.85h-28.9v63.01h28.9Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m568.18,272.05c-18.23,0-32.63-6.16-43.22-18.49-10.59-12.32-15.88-28.21-15.88-47.65s5.47-34.89,16.4-47.39c10.94-12.5,25.34-18.75,43.22-18.75,8.85,0,16.75,1.91,23.69,5.73,6.94,3.82,12.15,9.03,15.62,15.62v-17.96h39.58v125.5h-39.58v-17.7c-3.47,6.25-8.81,11.33-16.01,15.23-7.2,3.91-15.15,5.86-23.82,5.86Zm11.46-33.07c9.54,0,16.92-3.12,22.13-9.37,5.21-6.25,7.81-14.15,7.81-23.69s-2.6-17.18-7.81-23.43c-5.21-6.25-12.59-9.37-22.13-9.37-9.03,0-16.27,3.04-21.74,9.11-5.47,6.08-8.2,13.97-8.2,23.69s2.73,17.66,8.2,23.82c5.47,6.16,12.71,9.24,21.74,9.24Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m765.53,143.17h39.84v121.59c0,19.44-5.99,34.54-17.97,45.3-11.29,9.72-26.65,14.58-46.08,14.58s-35.76-4.34-46.34-13.02c-10.24-8.68-15.45-19.7-15.62-33.07h40.1c.87,11.28,8.16,16.92,21.87,16.92,16.14,0,24.21-9.37,24.21-28.12v-19.53c-7.29,13.89-20.57,20.83-39.84,20.83-15.45,0-27.04-4.69-34.76-14.06-7.73-9.37-11.59-22.22-11.59-38.53v-72.9h39.83v66.91c0,18.05,7.38,27.08,22.13,27.08,7.81,0,13.8-2.82,17.97-8.46,4.17-5.64,6.25-13.41,6.25-23.3v-62.23Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m839.47,268.66V86.41h111.44v35.41h-69.26v49.21h69.26v34.63h-69.26v63.01h-42.18Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m1090.07,253.82c-12.59,12.5-29.47,18.75-50.64,18.75s-38.1-6.25-50.77-18.75c-12.67-12.5-19.01-28.47-19.01-47.91s6.33-35.36,19.01-47.78c12.67-12.41,29.59-18.62,50.77-18.62s38.05,6.21,50.64,18.62c12.58,12.41,18.88,28.34,18.88,47.78s-6.29,35.41-18.88,47.91Zm-50.64-15.1c9.2,0,16.49-3.03,21.87-9.11,5.38-6.07,8.07-13.97,8.07-23.69s-2.69-17.61-8.07-23.69c-5.38-6.07-12.67-9.11-21.87-9.11s-16.71,3.04-22,9.11c-5.3,6.08-7.94,13.97-7.94,23.69s2.64,17.62,7.94,23.69c5.29,6.08,12.63,9.11,22,9.11Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m1131.86,268.66v-125.5h39.84v18.23c7.46-14.41,21-21.61,40.62-21.61,30.55,0,45.82,17.1,45.82,51.29v77.59h-40.1v-64.57c0-10.76-1.69-18.57-5.08-23.43-3.39-4.86-9.07-7.29-17.05-7.29-16.14,0-24.21,9.89-24.21,29.68v65.61h-39.84Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m1353.43,237.68c5.55,0,10.15-.26,13.8-.78v31.76c-7.64,1.39-16.49,2.08-26.56,2.08-4.52,0-8.51-.26-11.98-.78-3.47-.52-7.38-1.69-11.72-3.52-4.34-1.82-7.9-4.3-10.68-7.42-2.78-3.13-5.17-7.64-7.16-13.54-2-5.9-2.99-12.84-2.99-20.83v-49.99h-19.79v-31.5h19.79v-37.23h39.84v37.23h28.38v31.5h-28.38v41.66c0,8.51,1.47,14.19,4.43,17.05,2.95,2.86,7.29,4.3,13.02,4.3Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m1513.55,199.4c0,5.21-.35,11.02-1.04,17.44h-92.69c.35,8.16,3.12,14.49,8.33,19.01,5.21,4.52,12.24,6.77,21.09,6.77,12.15,0,19.96-3.91,23.43-11.72h39.05c-1.91,12.33-8.64,22.35-20.18,30.07-11.55,7.72-25.65,11.59-42.31,11.59-21.35,0-38.19-5.9-50.51-17.7-12.33-11.8-18.49-28.12-18.49-48.95s6.16-36.67,18.49-48.56c12.32-11.89,28.73-17.83,49.21-17.83s35.23,5.56,47.39,16.66c12.15,11.11,18.23,25.52,18.23,43.22Zm-93.73-7.29h54.42c-.18-8.33-2.52-14.75-7.03-19.27-4.52-4.51-11.02-6.77-19.53-6.77s-15.23,2.39-20.18,7.16c-4.95,4.78-7.51,11.07-7.68,18.88Z"})]});var Ye=require("react/jsx-runtime"),yr=()=>(0,Ye.jsxs)("svg",{width:"100%",height:"32",viewBox:"0 0 20 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"pl-5",children:[(0,Ye.jsx)("path",{d:"M19.686 5.71949V15.1448L19.6467 15.8434V15.8548V15.8663C19.5779 16.5076 19.4207 17.1146 19.1848 17.6758C19.0472 18.0079 18.8801 18.3286 18.6836 18.6149C18.5361 18.8439 18.3592 19.0615 18.1823 19.2677C18.025 19.4394 17.858 19.6112 17.6811 19.7601C17.5238 19.8975 17.3567 20.0235 17.1798 20.138C17.0127 20.2411 16.8456 20.3327 16.6786 20.4243C16.5606 20.4816 16.4427 20.5274 16.3149 20.5732L16.1773 20.6305L15.6761 20.8252L15.1748 21.0199L14.6736 21.2146L14.1723 21.4093L13.1698 21.7986L13.1207 21.8215V23.9402L13.0814 23.9517L12.7374 24.0777L12.6587 24.1006L12.3934 24.2036L12.1575 24.2953L12.0494 24.3296L11.7054 24.4556L11.6464 24.4785L11.3614 24.5816L11.1452 24.6617L11.0174 24.7075L10.6734 24.8335L10.6341 24.845L10.5849 24.8679H10.5653V20.745C10.5653 20.5732 10.5948 20.4129 10.6341 20.2526C10.6439 20.2182 10.6537 20.1838 10.6734 20.1495C10.752 19.9433 10.87 19.7601 11.0174 19.6112C11.0567 19.5769 11.096 19.5311 11.1452 19.4967C11.214 19.4394 11.2828 19.4051 11.3614 19.3593C11.381 19.3478 11.4105 19.3364 11.4302 19.3249L11.4498 19.3135L11.6562 19.2333L11.7152 19.2104L12.0592 19.0844L12.1673 19.0386L12.6686 18.8439L12.7472 18.8096L13.0912 18.6836L13.1796 18.6492L13.6809 18.4545L14.1821 18.2598L14.6834 18.0652L15.1846 17.8705L15.5483 17.733C15.5974 17.7216 15.6367 17.6987 15.6859 17.6758C15.8726 17.5956 16.0397 17.4811 16.1871 17.3551C16.3837 17.1948 16.5508 17.0001 16.6884 16.7825C16.9931 16.3244 17.17 15.7403 17.17 15.1333V5.71949C17.17 5.10106 17.0029 4.52844 16.6884 4.05889C16.5508 3.85275 16.3935 3.66951 16.2068 3.50917C16.197 3.49772 16.197 3.49772 16.1871 3.49772C16.0299 3.36029 15.8628 3.25722 15.6859 3.17705C15.5188 3.09689 15.3517 3.05108 15.1846 3.01672C15.0176 2.98236 14.8505 2.98236 14.6834 2.99382C14.5163 3.00527 14.3492 3.03963 14.1821 3.09689C14.1625 3.10834 14.133 3.10834 14.1133 3.11979L13.6809 3.28013L13.1796 3.46336L12.6784 3.65806L12.1378 3.82984L11.6366 4.02453L11.1353 4.20777L10.6341 4.40246L10.1328 4.5857L9.63159 4.76894L9.13034 4.96363L8.62909 5.14687L8.12784 5.3301L7.62659 5.52479L7.12534 5.70803L6.6241 5.90272L6.12285 6.08596L5.6216 6.28065L5.08103 6.46389L4.57979 6.65858L4.21614 6.79601C4.16699 6.81891 4.11785 6.83037 4.06871 6.85327C3.8918 6.93344 3.71489 7.04796 3.56746 7.17394C3.37089 7.33427 3.20381 7.52896 3.06621 7.74656C2.76153 8.2161 2.58462 8.78872 2.58462 9.40715V13.0948C2.58462 13.53 2.66325 13.8965 2.78119 14.2057C2.79102 14.2401 2.80085 14.263 2.8205 14.2973C2.81067 14.3088 2.79102 14.3088 2.78119 14.3202C2.70256 14.366 2.63376 14.4004 2.56496 14.4577C2.52565 14.4806 2.48634 14.5149 2.43719 14.5378C2.31925 14.618 2.20131 14.7096 2.0932 14.8012C2.08337 14.8127 2.06371 14.8241 2.05389 14.8356C1.94577 14.9272 1.84749 15.0188 1.74921 15.1104C1.68041 15.1792 1.61161 15.2479 1.55264 15.328C1.5035 15.3853 1.45435 15.4311 1.40521 15.4884C1.28727 15.6373 1.16933 15.7861 1.06122 15.9465C1.05139 15.9579 1.05139 15.9694 1.04156 15.9808C0.972761 16.0839 0.913791 16.1755 0.85482 16.2786C0.805678 16.1984 0.756536 16.1068 0.717223 16.0266C0.648424 15.9007 0.589453 15.7747 0.540311 15.6373C0.481341 15.4998 0.432199 15.3509 0.383057 15.2135C0.157004 14.5493 0.0390625 13.8392 0.0390625 13.1177V9.3957C0.0390625 8.50241 0.215974 7.63203 0.540311 6.87618C0.677909 6.54406 0.844992 6.22339 1.04156 5.93708C1.18899 5.70803 1.3659 5.49044 1.54281 5.28429C1.70006 5.11251 1.86715 4.94072 2.04406 4.79184C2.20131 4.65441 2.3684 4.52844 2.54531 4.41391C2.70256 4.31084 2.86964 4.21922 3.04656 4.1276C3.17432 4.07034 3.29227 4.01308 3.42003 3.96727L3.5478 3.92146L4.04905 3.73822L4.5503 3.54353L5.05155 3.36029L5.5528 3.1656L6.05405 2.98236L6.5553 2.78767L7.05654 2.60444L7.55779 2.40974L8.10818 2.22651L8.60943 2.03182L9.11068 1.84858L9.61193 1.66534L10.1132 1.47065L10.6144 1.28741L11.1157 1.09272L11.6169 0.909482L12.1182 0.714792L12.6194 0.531554L13.1207 0.336863L13.2878 0.279601C13.3959 0.233791 13.5138 0.199434 13.6317 0.165077C13.7988 0.119268 13.9659 0.073458 14.133 0.0505533C14.3001 0.0276485 14.4672 0.00474375 14.6342 0.00474375C14.8013 -0.00670864 14.9684 0.00474368 15.1355 0.0161961C15.3026 0.0276485 15.4697 0.0505533 15.6367 0.0849104C15.8038 0.119268 15.9709 0.165077 16.138 0.222339C16.3051 0.279601 16.482 0.348315 16.6392 0.428482C16.8063 0.508649 16.9832 0.61172 17.1405 0.714792C17.3174 0.829315 17.4845 0.955292 17.6417 1.09272C17.6417 1.09272 17.6417 1.09272 17.6516 1.09272C17.8285 1.2416 17.9956 1.40193 18.1528 1.58517C18.3396 1.77986 18.5066 1.99746 18.6541 2.22651C18.8506 2.52427 19.0177 2.83348 19.1553 3.1656C19.5091 3.95582 19.686 4.81475 19.686 5.71949Z",fill:"#0231C5"}),(0,Ye.jsx)("path",{d:"M10.8112 9.92822V13.0846L10.7425 13.1079L10.5557 13.1778L10.2412 13.2943L10.2215 13.3059L9.87755 13.434L9.73995 13.4923L9.53356 13.5738L9.48441 13.5855L9.27802 13.667L9.10111 13.7369L8.93402 13.7951L8.59986 13.9232H8.59003L8.24604 14.0514L8.08878 14.1096L7.90204 14.1795L7.58753 14.2959L7.56787 14.3076L7.22388 14.4357L7.08628 14.4939L6.87989 14.5755L6.83074 14.5871L6.57521 14.6803L6.53589 14.692L6.1919 14.8201L6.07396 14.8667L5.8479 14.9482L5.57271 15.053L5.51374 15.0763L5.16974 15.2044L5.07146 15.2394L4.88472 15.3093L4.82575 15.3326L4.56038 15.4374L4.48175 15.4723L4.19673 15.5771C4.17707 15.5888 4.15742 15.5888 4.13776 15.6004C4.10827 15.6121 4.07879 15.6237 4.05913 15.6354C3.97068 15.682 3.88222 15.7286 3.79377 15.7868C3.71514 15.8334 3.62668 15.8916 3.54806 15.9615C3.51857 15.9848 3.47926 16.0197 3.44977 16.0547C3.322 16.1712 3.21389 16.2993 3.10578 16.4507C3.08612 16.474 3.06646 16.5089 3.04681 16.5439C2.93869 16.7186 2.84041 16.9049 2.76178 17.1146C2.63401 17.464 2.56521 17.8367 2.56521 18.2327V27.5039C2.56521 27.7951 2.63401 28.0747 2.76178 28.3076C2.84041 28.459 2.95835 28.5988 3.08612 28.7153C3.09595 28.7269 3.09595 28.7269 3.10578 28.7269C3.21389 28.8201 3.322 28.89 3.44977 28.9249C3.55788 28.9715 3.67582 28.9948 3.79377 28.9948C3.90188 28.9948 4.01982 28.9831 4.13776 28.9482C4.16725 28.9366 4.19673 28.9249 4.22622 28.9133L4.47193 28.8201L4.81592 28.692L5.15991 28.5638L5.50391 28.4357L5.8479 28.3076L6.00516 28.2494C6.06413 28.2261 6.1231 28.1911 6.18207 28.1562C6.30984 28.098 6.41795 28.0164 6.52606 27.9116C6.65383 27.7951 6.77177 27.6554 6.87006 27.4923C7.06663 27.1662 7.17474 26.7585 7.17474 26.3392V19.7585L7.20422 19.7469L7.54822 19.6187L7.56787 19.6071L7.88238 19.4906L8.06912 19.4207L8.22638 19.3625L8.57037 19.2344H8.5802L8.91437 19.1063L9.08145 19.048L9.25836 18.9781L9.5827 18.85L9.60236 18.8384L9.71047 18.7918V26.3392C9.71047 26.6188 9.69081 26.9099 9.6515 27.1778C9.63184 27.2826 9.62201 27.3758 9.60236 27.4806C9.52373 27.8767 9.41562 28.2494 9.25836 28.5988C9.16008 28.8317 9.04214 29.053 8.91437 29.2743C8.80625 29.449 8.69814 29.6121 8.57037 29.7752C8.46226 29.9149 8.34432 30.043 8.22638 30.1595C8.11827 30.276 8.00032 30.3692 7.88238 30.474C7.77427 30.5672 7.65633 30.6487 7.53839 30.7302C7.43028 30.8001 7.31234 30.87 7.19439 30.9282C7.18457 30.9282 7.17474 30.9399 7.16491 30.9515C7.06663 30.9981 6.95851 31.0447 6.86023 31.0913C6.83074 31.1029 6.80126 31.1146 6.77177 31.1262L6.51624 31.2194L5.82825 31.4757L5.48425 31.6038L5.14026 31.7319L4.983 31.7901C4.92403 31.8134 4.86506 31.8367 4.80609 31.8484C4.68815 31.8833 4.58004 31.9183 4.4621 31.9415C4.34416 31.9648 4.23604 31.9881 4.1181 31.9881C4.00999 31.9998 3.91171 31.9998 3.81342 31.9998H3.78394C3.666 31.9998 3.55788 31.9881 3.43994 31.9765C3.322 31.9648 3.21389 31.9415 3.09595 31.9183C2.97801 31.895 2.8699 31.86 2.75195 31.8134C2.68316 31.7901 2.62419 31.7668 2.55539 31.7435C2.50624 31.7203 2.4571 31.697 2.40796 31.6737C2.29002 31.6154 2.18191 31.5572 2.06397 31.4873C1.94602 31.4174 1.82808 31.3359 1.71997 31.2427C1.67083 31.2078 1.62169 31.1612 1.57255 31.1262C1.50375 31.068 1.44478 31.0098 1.37598 30.9399C1.25804 30.8234 1.1401 30.6953 1.03198 30.5555C0.904214 30.4041 0.786273 30.2294 0.687989 30.0547C0.550391 29.8334 0.442278 29.6004 0.343994 29.3559C0.117941 28.7735 0 28.1329 0 27.469V18.1978C0 17.4524 0.117941 16.7302 0.343994 16.0663C0.393136 15.9149 0.442278 15.7751 0.501249 15.6354C0.560219 15.4956 0.61919 15.3675 0.67816 15.2394C0.717474 15.1462 0.766616 15.0647 0.815758 14.9831C0.874728 14.8783 0.933699 14.7735 1.0025 14.6803C1.0025 14.6687 1.01233 14.657 1.02215 14.657C1.13027 14.494 1.23838 14.3425 1.36615 14.1911C1.41529 14.1329 1.4546 14.0746 1.51358 14.0281C1.58237 13.9465 1.64134 13.8883 1.71014 13.8184C1.80843 13.7252 1.90671 13.6204 2.01482 13.5389C2.02465 13.5272 2.04431 13.5156 2.05414 13.5039C2.16225 13.4108 2.28019 13.3176 2.39813 13.2477C2.43745 13.2244 2.47676 13.1895 2.5259 13.1662C2.5947 13.1196 2.67333 13.073 2.74213 13.0264C2.75195 13.0147 2.76178 13.0147 2.78144 13.0031C2.86007 12.9565 2.94852 12.9099 3.02715 12.875C3.04681 12.8633 3.06646 12.8517 3.08612 12.8517C3.1844 12.8051 3.29252 12.7585 3.3908 12.7236L3.42029 12.7119L3.51857 12.677L3.76428 12.5838L4.02965 12.479L4.10828 12.444L4.45227 12.3159L4.5309 12.281L4.79626 12.1878L4.85523 12.1645L5.04197 12.0946L5.14026 12.0597L5.48425 11.9316L5.54322 11.9083L5.81842 11.8034L6.04447 11.7219L6.16241 11.6753L6.50641 11.5472L6.54572 11.5355L6.80126 11.4424L6.8504 11.4307L7.0568 11.3492L7.19439 11.3026L7.53839 11.1745L7.55805 11.1628L7.87256 11.0464L8.0593 10.9765L8.21655 10.9182L8.56054 10.7901H8.57037L8.90454 10.662L9.07162 10.6038L9.24853 10.5339L9.45493 10.4523L9.50407 10.4407L9.71047 10.3592L9.84807 10.3009L10.1921 10.1728L10.2117 10.1612L10.5262 10.0447L10.713 9.97481L10.8112 9.92822Z",fill:"#0231C5"})]});var ie=require("react/jsx-runtime"),vr=({onToggleSideBar:e,isSidebarCollapsed:t})=>(0,ie.jsx)("button",{onClick:()=>e(!t),className:"w-6 h-12 bg-[#EEF2FF] rounded-tr-md [clip-path:polygon(0%_0%,100%_0%,100%_60%,0%_100%,0%_100%)] mt-5 flex justify-center items-center",children:(0,ie.jsx)(sa,{className:"mb-3"})}),sa=e=>(0,ie.jsxs)("svg",{width:"20",height:"15",viewBox:"0 0 20 20",fill:"none",color:"currentColor",xmlns:"http://www.w3.org/2000/svg",...e,children:[(0,ie.jsx)("path",{d:"M4.52669 6.50008C4.25055 6.50008 4.02669 6.72394 4.02669 7.00008C4.02669 7.27622 4.25055 7.50008 4.52669 7.50008H5.48958C5.76573 7.50008 5.98958 7.27622 5.98958 7.00008C5.98958 6.72394 5.76573 6.50008 5.48958 6.50008H4.52669Z",fill:"#878989"}),(0,ie.jsx)("path",{d:"M4.02669 8.66675C4.02669 8.39061 4.25055 8.16675 4.52669 8.16675H5.48958C5.76573 8.16675 5.98958 8.39061 5.98958 8.66675C5.98958 8.94289 5.76573 9.16675 5.48958 9.16675H4.52669C4.25055 9.16675 4.02669 8.94289 4.02669 8.66675Z",fill:"#878989"}),(0,ie.jsx)("path",{d:"M4.52669 9.83342C4.25055 9.83342 4.02669 10.0573 4.02669 10.3334C4.02669 10.6096 4.25055 10.8334 4.52669 10.8334H5.48958C5.76573 10.8334 5.98958 10.6096 5.98958 10.3334C5.98958 10.0573 5.76573 9.83342 5.48958 9.83342H4.52669Z",fill:"#878989"}),(0,ie.jsx)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M2.68166 5.07676C2.5 5.43328 2.5 5.89999 2.5 6.83341V13.1667C2.5 14.1002 2.5 14.5669 2.68166 14.9234C2.84144 15.237 3.09641 15.492 3.41002 15.6518C3.76654 15.8334 4.23325 15.8334 5.16667 15.8334H14.8333C15.7668 15.8334 16.2335 15.8334 16.59 15.6518C16.9036 15.492 17.1586 15.237 17.3183 14.9234C17.5 14.5669 17.5 14.1002 17.5 13.1667V6.83341C17.5 5.89999 17.5 5.43328 17.3183 5.07676C17.1586 4.76316 16.9036 4.50819 16.59 4.3484C16.2335 4.16675 15.7668 4.16675 14.8333 4.16675H5.16667C4.23325 4.16675 3.76654 4.16675 3.41002 4.3484C3.09641 4.50819 2.84144 4.76316 2.68166 5.07676ZM14.8333 5.16675H7.66667L7.66667 14.8334H14.8333C15.3165 14.8334 15.6188 14.8326 15.8466 14.814C16.0626 14.7964 16.1222 14.7678 16.136 14.7608C16.2614 14.6968 16.3634 14.5949 16.4273 14.4694C16.4344 14.4556 16.463 14.3961 16.4806 14.18C16.4992 13.9522 16.5 13.65 16.5 13.1667V6.83341C16.5 6.3502 16.4992 6.04794 16.4806 5.82018C16.463 5.6041 16.4344 5.54455 16.4273 5.53075C16.3634 5.40531 16.2614 5.30333 16.136 5.23941C16.1222 5.23238 16.0626 5.20379 15.8466 5.18613C15.6188 5.16753 15.3165 5.16675 14.8333 5.16675ZM5.16667 5.16675H6.66667L6.66667 14.8334H5.16667C4.68346 14.8334 4.38119 14.8326 4.15344 14.814C3.93736 14.7964 3.8778 14.7678 3.86401 14.7608C3.73856 14.6968 3.63658 14.5949 3.57266 14.4694C3.56564 14.4556 3.53704 14.3961 3.51939 14.18C3.50078 13.9522 3.5 13.65 3.5 13.1667V6.83341C3.5 6.3502 3.50078 6.04794 3.51939 5.82018C3.53704 5.6041 3.56563 5.54455 3.57266 5.53075C3.63658 5.40531 3.73856 5.30333 3.86401 5.23941C3.8778 5.23238 3.93736 5.20379 4.15344 5.18613C4.38119 5.16753 4.68346 5.16675 5.16667 5.16675Z",fill:"#878989"})]});var k=require("react/jsx-runtime"),xr=({isSidebarCollapsed:e,onToggleSideBar:t,isMobile:o,links:r,businessProps:n,currentPath:i,onNavigate:l,appConfig:s,collapseType:d,onLogoutClick:c,openSidebarIcon:p=(0,k.jsx)(hr,{}),closedSidebarIcon:u=(0,k.jsx)(yr,{}),nodeAfterSideBarLogo:m})=>{let g=(0,ye.useMemo)(()=>o?"hidden":d||(o?"hidden":"icons"),[o,d]),[f,b]=(0,ye.useState)(!1),L=g==="icons"&&e,E=(0,ye.useRef)(null),{businessList:Q,activeBusiness:ve,toggleAddBusinessDrawer:I,handleSetActiveBusiness:Le}=n,$t=()=>b(wt=>!wt),Sr=wt=>{Le?.(wt),$t()},Fr=(0,ye.useMemo)(()=>g==="hidden"?p:e?u:p,[e,p,u,g]),Ut=o&&g==="hidden"&&e;return(0,k.jsxs)(k.Fragment,{children:[Ut&&(0,k.jsx)("div",{className:"fixed inset-0 z-40 bg-black bg-opacity-40 transition-all animate-in fade-in-15",onClick:()=>t(!1)}),(0,k.jsxs)("div",{className:a("relative flex flex-row-reverse h-full",{"fixed inset-0 z-50 pointer-events-none":Ut}),children:[g==="icons"&&(0,k.jsx)(vr,{isSidebarCollapsed:e,onToggleSideBar:t}),(0,k.jsxs)("aside",{id:"sidebar_menu",ref:E,className:a("relative pt-4 h-full max-h-screen bg-[#FBFBFB] overflow-hidden flex-col flex transition-all duration-300 w-64 gap-y-14",{"!fixed":g==="hidden","w-[311px]":e&&g!=="icons","w-[75px]":e&&g==="icons","w-0 lg:w-0 pointer-events-none":!e&&g==="hidden","pointer-events-auto":e&&g==="hidden","left-0 top-0":o&&g==="hidden","-translate-x-full":!e&&o&&g!=="hidden","translate-x-0":e&&o&&g==="hidden"}),children:[(0,k.jsxs)("div",{className:a("flex items-center -ml-2 py-2 justify-center w-full",{"justify-between px-2":o}),children:[Fr,g==="hidden"&&(0,k.jsx)("div",{onClick:()=>t(!1),className:"flex items-center gap-2 text-3xl cursor-pointer",children:(0,k.jsx)(br.X,{size:24,className:"text-black hover:opacity-60"})})]}),m,(0,k.jsx)("div",{className:"flex-1 overflow-y-auto px-3 h-full max-h-[calc(100vh-200px)]",children:(0,k.jsx)(Cr,{isIconsOnly:L,collapseType:g,currentPath:i,isSidebarCollapsed:e,links:r,onNavigate:l,onToggleSideBar:t,appConfig:s,isMobile:o})}),(0,k.jsx)("div",{className:"absolute bottom-5 w-full",children:(0,k.jsx)(fr,{activeBusiness:ve,handleSwitchBusiness:Sr,showBusiness:f,toggleAddBusinessDrawer:I,toggleShowBusiness:$t,businesses:Q||[],iconOnly:g==="icons"?e:!1,onLogoutClick:c,isMobile:o})})]})]})]})};var ft=require("react/jsx-runtime"),wr=({status:e,variant:t,className:o})=>(0,ft.jsx)("div",{children:(0,ft.jsx)("div",{className:a("order-first max-w-max flex-none rounded-full px-2 py-1 text-xs font-medium ring-1 ring-inset ring-current sm:order-none text-[14px] capitalize",{"bg-green-500/20 text-green-500":t==="success"},{"bg-gray-500/20 text-white":t==="abandoned"},{"bg-red-500/20 text-red-500":t==="failed"},{"bg-yellow-500/20 text-yellow-500":t==="pending"},o),children:(0,ft.jsx)("p",{children:e.replace("-"," ")})})});var Lr=require("lucide-react");var Ct=require("lucide-react");var gt=require("react/jsx-runtime"),la=({page:e,currentPage:t,onClick:o})=>typeof e=="string"?(0,gt.jsx)("span",{className:"px-3 py-1 sm:px-4 sm:py-2 text-xs sm:text-sm font-semibold text-gray-500",children:e}):(0,gt.jsx)("button",{onClick:o,className:`p-1 w-8 h-8 text-xs sm:text-sm rounded-full ${e===t?"bg-primary-main text-white":"text-[#717171] hover:bg-primary-main/10"}`,children:e}),Nr=({totalPages:e,currentPage:t,handlePageClick:o})=>{let n=()=>{let d=Math.floor(1.5),c=Math.max(1,t-d),p=Math.min(e,c+3-1);return p>e&&(c=Math.max(1,e-3+1),p=e),{start:c,end:p}},{start:i,end:l}=n(),s=[];return i>1&&s.push(1),i>2&&s.push("..."),s.push(...Array.from({length:l-i+1},(d,c)=>i+c)),l<e-1&&s.push("..."),l<e&&s.push(e),s.map((d,c)=>(0,gt.jsx)(la,{page:d,currentPage:t,onClick:typeof d=="number"?()=>o(d):void 0},c))};var q=require("react/jsx-runtime"),ht=({currentPage:e=1,totalPages:t=1,onPageChange:o,itemsPerPage:r=0,totalItems:n=0})=>{let i=d=>{d>=1&&d<=t&&o?.(d)},l=r===0?1:r*(e-1)+1,s=e===t?n:Math.min(l+r-1,n);return(0,q.jsxs)("div",{className:"flex items-center justify-between border-t border-gray-200 px-4 py-3 sm:px-6 w-full flex-wrap gap-y-10 sm:gap-y-0",children:[n&&(0,q.jsx)("section",{className:"text-[#717171] text-[12px]",children:(0,q.jsxs)("p",{className:"",children:["Showing ",l," - ",s," of ",n]})}),(0,q.jsx)("div",{className:"flex items-center justify-center sm:justify-end ",children:(0,q.jsxs)("nav",{className:" inline-flex gap-x-1 sm:gap-x-[10px] items-center",children:[(0,q.jsx)("button",{onClick:()=>i(e-1),disabled:e===1,className:"text-xs text-[#222222] hover:bg-primary-main/10 disabled:text-[#D9D9D9] disabled:cursor-not-allowed sm:flex hidden",children:(0,q.jsx)(Ct.ChevronLeftIcon,{className:"size-5"})}),Nr({currentPage:e,totalPages:t,handlePageClick:i}),(0,q.jsx)("button",{onClick:()=>i(e+1),disabled:e===t,className:"text-xs text-[#222222] hover:bg-primary-main/10 disabled:text-[#D9D9D9] disabled:cursor-not-allowed sm:flex hidden",children:(0,q.jsx)(Ct.ChevronRightIcon,{className:"size-5"})})]})})]})};var Gt=require("@tanstack/react-table");var z=require("react/jsx-runtime"),Pr=({table:e,isMobile:t,onRowClick:o,id:r})=>(0,z.jsx)("div",{className:a("relative w-full rounded-b border-0",{}),children:(0,z.jsxs)("table",{id:r??"table",className:"w-full overflow-x-scroll",children:[(0,z.jsx)("thead",{children:e.getHeaderGroups().map(n=>(0,z.jsx)("tr",{className:a(" rounded text-[#717171] border-b- bg-[#FCFCFC]",{}),children:n.headers.map(i=>(0,z.jsx)("th",{className:"relative py-3 text-base whitespace-nowrap pl-2.5 text-left font-normal capitalize",colSpan:i.colSpan,style:{width:i.getSize()},children:i.isPlaceholder?null:(0,z.jsx)("div",{className:a("flex items-center",{"cursor-pointer select-none":i.column.getCanSort()}),onClick:i.column.getToggleSortingHandler(),children:i.isPlaceholder?null:(0,Gt.flexRender)(i.column.columnDef.header,i.getContext())})},i.id))},n.id))}),(0,z.jsx)("tbody",{className:" pl-2.5",children:e?.getFilteredRowModel().rows.map(n=>(0,z.jsx)("tr",{className:a("first-letter border-b border-zinc-100",{"hover:bg-gray-50":!t},{"hover:bg-gray-50 hover:cursor-pointer":o}),onClick:()=>o?o(n):{},children:n.getVisibleCells().map(i=>(0,z.jsx)("td",{className:a("",{}),children:(0,z.jsx)("div",{className:a("",{"w-max p-4 pl-2.5 text-black text-sm":!0}),children:(0,Gt.flexRender)(i.column.columnDef.cell,i.getContext())})},i.id))},n.id))})]})});var we=require("lucide-react");var P=require("react/jsx-runtime"),yt=({onRefetch:e,search:t,FilterMenu:o,ExtraNode:r,onExport:n,download:i,isRefetching:l})=>{let s=c=>{t?.onSearch?.(c)},d=()=>{try{e?.()}catch(c){console.error("Error while refetching data",c)}};return(0,P.jsx)(P.Fragment,{children:(e||t?.enabled||o||r||n)&&(0,P.jsxs)("div",{className:"w-full flex flex-col sm:!flex-row justify-between items-start sm:items-center bg-white p-2 gap-2",children:[(0,P.jsx)("div",{className:"flex flex-1 flex-col sm:flex-row items-center gap-2 justify-start",children:(0,P.jsxs)("div",{className:" w-full flex gap-x-3",children:[t?.enabled&&(0,P.jsx)("section",{className:"sm:w-56",children:(0,P.jsx)(st,{type:"text",placeholder:"Enter search here...",className:"h-9",onChange:s,debounce:t?.debounceRate})}),(0,P.jsxs)("div",{className:" flex gap-2",children:[e&&(0,P.jsx)(fe,{onClick:d,title:"Refetch Data",disabled:l,variant:"outlined",className:"!border-[#DEDEDE] !text-gray-800 !px-[10px] !py-[8px] ",size:"sm",children:(0,P.jsx)(we.RotateCw,{className:a("w-4 h-4",{"animate-spin":l}),size:5})}),o&&(0,P.jsx)(Ce,{trigger:(0,P.jsx)("button",{title:"Filter",className:a("!border-[#DEDEDE] !text-gray-800 !px-[10px] !py-[8px]",Se({variant:"outlined",size:"sm"})),children:(0,P.jsx)(we.ListFilter,{className:"w-4 h-4",size:5})}),children:o})]})]})}),(0,P.jsx)("div",{className:"flex items-start flex-col gap-2 justify-center",children:(0,P.jsx)("section",{className:"flex flex-col-reverse sm:flex-row gap-2",children:(0,P.jsxs)("div",{className:"flex gap-2",children:[r&&r,n&&(0,P.jsx)(fe,{variant:"primary",onClick:n,size:"sm",children:"Export"}),i?.enabled&&(0,P.jsx)(fe,{variant:"primary",leftNode:(0,P.jsx)(we.Download,{className:"w-4 h-5",size:5}),onClick:i?.onDownload,id:i.buttonId,size:"sm",children:i?.buttonText})]})})})]})})};var W=require("react/jsx-runtime"),Rr=({table:e,isMobile:t=!1,onRowClick:o,id:r,onRefetch:n,isRefetching:i,FilterMenu:l,ExtraNode:s,onExport:d,search:c={enabled:!1,debounceRate:700},download:p={enabled:!1,buttonId:"download_button",buttonText:"Export"},isLoading:u,pagination:m})=>(0,W.jsxs)("div",{className:a("relative w-full rounded-b border-0 overflow-x-auto"),children:[(0,W.jsx)(yt,{onRefetch:n,search:c,FilterMenu:l,ExtraNode:s,onExport:d,download:p,isRefetching:i}),(0,W.jsx)("main",{className:"w-full overflow-x-auto mt-5",children:u?(0,W.jsxs)("div",{className:"py-10 flex flex-col justify-center w-full items-center space-x-2",children:[(0,W.jsx)(Lr.Loader,{size:20,className:"animate-spin"}),(0,W.jsx)("p",{className:"mt-3 text-center text-gray-600 text-sm opacity-70 animate-pulse",children:"Loading..."})]}):e.getRowModel().rows.length<1?(0,W.jsx)("div",{className:"py-10 flex flex-col justify-center w-full items-center",children:(0,W.jsx)("p",{className:"text-center text-gray-600 text-sm opacity-70",children:"No data available"})}):(0,W.jsx)("div",{className:"flex flex-col gap-2",children:(0,W.jsx)(Pr,{table:e,isMobile:t,onRowClick:o,id:r})})}),!u&&m?.enabled&&e.getRowModel().rows.length>0&&(0,W.jsx)(ht,{...m,currentPage:m?.currentPage??1,totalPages:m?.totalPages??Math.ceil((m?.totalItems??0)/Math.max(m?.itemsPerPage??1,1))??1,onPageChange:g=>m?.onPageChange?.(g)})]});var vt=require("react"),Tr=require("react/jsx-runtime"),je=(0,vt.createContext)(void 0),Dr=({permissions:e,children:t})=>{let o=(0,vt.useMemo)(()=>e,[e]);return(0,Tr.jsx)(je.Provider,{value:o,children:t})};var Ne=require("react");var zt=()=>(0,Ne.useContext)(je),bt=e=>{let t=zt(),o=(0,Ne.useCallback)(n=>{if(!t||!n||t.some(p=>p.resource==="all"&&p.action==="administrator"))return!0;let{resource:l,action:s}=n,d=t.filter(p=>p.resource===l);return d.some(p=>p.action===s)?!0:s==="read"?d.some(p=>p.action==="write"):!1},[e]);return{hasPermission:(0,Ne.useMemo)(()=>o(e),[t,e]),validatePermission:o}};var Pe=require("react/jsx-runtime"),kr=({permission:e,children:t})=>{let{hasPermission:o}=bt(e||{});return e?(0,Pe.jsx)(Pe.Fragment,{children:o?t:null}):(0,Pe.jsx)(Pe.Fragment,{children:t})};var Zt={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$"},Je=class Je{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 Zt[t]||t}};Yt(Je,"formatAmountAndCurrency",(t,o,r)=>{let n=new Intl.NumberFormat(r?.locale||Je.getCurrencyLocaleMap(t),{maximumFractionDigits:3,style:"currency",currency:t,currencyDisplay:"symbol"}).format(r?.convertToMajorCurrency?Je.koboToNaira(Number(o)):Number(o)).replace(/^(\D+)/,"$1 ").replace("\u202F"," ").replace(/\s+/,""),i=Zt[t]||t;return n.replace(t,i)});var _t=Je;var xt=w(require("dayjs")),Kt=class{static getDateLibrary(){return(0,xt.default)()}static formatTimestampToDate(t,o){return xt.default.unix(t).format(o||"ddd, MMM, YYYY | HH:mm:ss")}static formatDateToTimestamp(t){return(0,xt.default)(t).unix()}};0&&(module.exports={AmountAction,Banner,Button,CopyableLabel,Country,CurrencySymbolMap,DateAction,DebouncedInput,DevBanner,Dialog,Drawer,DrawerClose,DrawerRoot,FlagComponent,FormLabel,HasResourcePermission,Input,Loader,LocaleSelector,OTPInput,PageDataToolbar,Pagination,PasswordInput,PermissionsContext,PermissionsProvider,PhoneInput,Popover,PopoverContent,PopoverRoot,PopoverTrigger,Select,Sidebar,Status,Table,Textarea,Tooltip,TooltipContent,TooltipProvider,TooltipRoot,TooltipTrigger,buttonVariants,cn,useHasPermission,usePermissions});
1
+ "use strict";var Er=Object.create;var Re=Object.defineProperty;var Ar=Object.getOwnPropertyDescriptor;var Ir=Object.getOwnPropertyNames;var Br=Object.getPrototypeOf,Mr=Object.prototype.hasOwnProperty;var Vr=(e,t,o)=>t in e?Re(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o;var Hr=(e,t)=>{for(var o in t)Re(e,o,{get:t[o],enumerable:!0})},Xt=(e,t,o,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Ir(t))!Mr.call(e,n)&&n!==o&&Re(e,n,{get:()=>t[n],enumerable:!(r=Ar(t,n))||r.enumerable});return e};var P=(e,t,o)=>(o=e!=null?Er(Br(e)):{},Xt(t||!e||!e.__esModule?Re(o,"default",{value:e,enumerable:!0}):o,e)),Or=e=>Xt(Re({},"__esModule",{value:!0}),e);var Yt=(e,t,o)=>Vr(e,typeof t!="symbol"?t+"":t,o);var ca={};Hr(ca,{AmountAction:()=>_t,Banner:()=>Oo,Button:()=>fe,CopyableLabel:()=>zo,Country:()=>Ao,CurrencySymbolMap:()=>Zt,DateAction:()=>Kt,DebouncedInput:()=>st,DevBanner:()=>Ko,Dialog:()=>tt,Drawer:()=>or,DrawerClose:()=>Yo,DrawerRoot:()=>ct,FlagComponent:()=>ae,FormLabel:()=>H,HasResourcePermission:()=>kr,Input:()=>Y,Loader:()=>be,LocaleSelector:()=>lr,OTPInput:()=>Ho,PageDataToolbar:()=>yt,Pagination:()=>ht,PasswordInput:()=>Ft,PermissionsContext:()=>je,PermissionsProvider:()=>Dr,PhoneInput:()=>Mt,Popover:()=>Ce,PopoverContent:()=>ee,PopoverRoot:()=>re,PopoverTrigger:()=>J,Select:()=>Io,Sidebar:()=>xr,Status:()=>wr,Table:()=>Rr,Textarea:()=>Et,Tooltip:()=>De,TooltipContent:()=>qe,TooltipProvider:()=>Nt,TooltipRoot:()=>Pt,TooltipTrigger:()=>Lt,buttonVariants:()=>Se,cn:()=>a,useHasPermission:()=>bt,usePermissions:()=>zt});module.exports=Or(ca);var qt=P(require("react")),_=P(require("@radix-ui/react-tooltip"));var jt=require("clsx"),Jt=require("tailwind-merge");function a(...e){return(0,Jt.twMerge)((0,jt.clsx)(e))}var te=require("react/jsx-runtime"),Nt=_.Provider,Pt=_.Root,Lt=_.Trigger,qe=qt.forwardRef(({className:e,sideOffset:t=2,...o},r)=>(0,te.jsx)(_.Content,{ref:r,sideOffset:t,className:a("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),...o,children:o.children}));qe.displayName=_.Content.displayName;var De=({trigger:e,children:t,contentClassName:o,triggerClassName:r,asChild:n=!0,side:i,sideOffset:l,align:s,alignOffset:d,delayDuration:c=100,hasArrow:p=!0,arrowClassName:u,...m})=>(0,te.jsx)(Nt,{children:(0,te.jsx)(Pt,{delayDuration:c,...m,children:(0,te.jsxs)("div",{className:"flex justify-center items-center",children:[(0,te.jsx)(Lt,{asChild:n,className:r,children:e}),(0,te.jsxs)(qe,{side:i,sideOffset:l,align:s,alignOffset:d,className:o,children:[t,p&&(0,te.jsx)(_.Arrow,{className:a("fill-white",u)})]})]})})});De.displayName="Tooltip";var oo=P(require("react"));var Qt=P(require("react")),Rt=P(require("@radix-ui/react-label")),eo=require("class-variance-authority");var to=require("react/jsx-runtime"),Wr=(0,eo.cva)("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Dt=Qt.forwardRef(({className:e,...t},o)=>(0,to.jsx)(Rt.Root,{ref:o,className:a(Wr(),e),...t}));Dt.displayName=Rt.Root.displayName;var Te=require("react/jsx-runtime"),H=oo.default.forwardRef(({className:e,children:t,showAsterisk:o,error:r,...n},i)=>(0,Te.jsx)(Dt,{ref:i,className:a(r&&"text-red-500",e),...n,children:o?(0,Te.jsxs)("p",{children:[t,(0,Te.jsx)("span",{className:"text-red-500",children:"*"})]}):t}));H.displayName="FormLabel";var ke=require("react/jsx-runtime"),be=({size:e=16,colour:t="primary"})=>(0,ke.jsxs)("svg",{className:"animate-spin",width:e,height:e,viewBox:"0 0 20 20",fill:"none",children:[(0,ke.jsx)("circle",{cx:"10",cy:"10",r:"9.25",stroke:"transparent",strokeWidth:"1.5"}),(0,ke.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 Qe=P(require("react")),ro=require("@radix-ui/react-slot"),ao=require("class-variance-authority");var K=require("react/jsx-runtime"),Se=(0,ao.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"}}),fe=Qe.forwardRef(({className:e,variant:t="primary",size:o,asChild:r=!1,isLoading:n=!1,leftNode:i,rightNode:l,LoaderSize:s,...d},c)=>{let p=r?ro.Slot:"button",{children:u,disabled:m,...g}=d,f=Qe.useRef(null);return(0,K.jsx)(p,{className:a(Se({variant:t,size:o,className:e})),ref:f||c,disabled:m||n,...g,children:(0,K.jsx)("div",{className:"flex font-medium justify-center items-center gap-2",children:n?(0,K.jsx)(K.Fragment,{children:(0,K.jsx)("span",{className:"mx-auto",children:(0,K.jsx)(be,{size:s,colour:"secondary"})})}):(0,K.jsxs)(K.Fragment,{children:[i,u,l]})})})});fe.displayName="Button";var Tt=P(require("react"));var et=require("class-variance-authority");var no=P(require("react")),io=require("react/jsx-runtime"),$=no.default.forwardRef(({className:e,children:t,error:o,...r},n)=>{let i=o??t;return i?(0,io.jsx)("p",{ref:n,className:a("text-xs font-normal text-[#F04248]",e),...r,children:i}):null});$.displayName="ErrorMessage";var so=P(require("react")),lo=require("react/jsx-runtime"),U=so.default.forwardRef(({className:e,...t},o)=>(0,lo.jsx)("div",{ref:o,className:a("text-sm text-[#8E98A8",e),...t}));U.displayName="FormDescription";var X=require("react/jsx-runtime"),Gr=(0,et.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"}}),po=Tt.forwardRef(({className:e,status:t,type:o,...r},n)=>(0,X.jsx)("input",{type:o,className:a(Gr({status:t}),e),ref:n,...r}));po.displayName="BaseInnerInput";var oe=(0,et.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"}}),co=(0,et.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"}}),Y=Tt.forwardRef(({className:e,status:t="default",disabled:o,error:r,isLoading:n,sideNodeClassName:i,showAsterisk:l,label:s,description:d,...c},p)=>{let u=t;return r&&(u="error"),n&&(u="loading"),o&&(u="prefilled"),(0,X.jsxs)("div",{className:"relative space-y-1 w-full",children:[s&&(0,X.jsx)(H,{showAsterisk:l,error:r,children:s}),(0,X.jsxs)("div",{className:a(oe({status:u}),c.leftNode?"pl-0":"",c.rightNode?"pr-0":"",e),children:[c.leftNode?(0,X.jsx)("div",{className:a(co({status:u,side:"left"}),i),children:c.leftNode}):null,(0,X.jsx)(po,{ref:p,disabled:n||o,className:a({"!pl-3":c.leftNode&&t!=="neutral","!pr-3":c.rightNode&&t!=="neutral"}),...c}),c.rightNode?(0,X.jsx)("div",{className:a(co({status:u,side:"right"}),i),children:c.rightNode}):null]}),d&&(0,X.jsx)(U,{className:"text-gray-400 text-sm !font-normal",children:d}),(0,X.jsx)($,{error:r})]})});Y.displayName="Input";var Ae=require("react");var Fe=require("react/jsx-runtime"),mo=()=>(0,Fe.jsxs)("svg",{width:"18",height:"14",viewBox:"0 0 18 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,Fe.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,Fe.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 Ee=require("react/jsx-runtime"),uo=()=>(0,Ee.jsxs)("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,Ee.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,Ee.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 kt=require("react/jsx-runtime"),fo=()=>(0,kt.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,kt.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 St=require("react/jsx-runtime"),go=()=>(0,St.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,St.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 O=require("react/jsx-runtime"),Co=[{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:"8 Characters",key:"eight-chars",RegExp:/.{8}/,validated:!1}],Ft=({onValidate:e,onChange:t,disableValidation:o,...r})=>{let[n,i]=(0,Ae.useState)(!1),[l,s]=(0,Ae.useState)(Co),d=m=>Co.map(g=>({...g,validated:g.RegExp.test(m)})),c=m=>{let g=d(m),f=g.every(v=>v.validated);return s(g),f},p=m=>{if(t&&t(m),o)return;let g=m?.target?.value,f=c(g);e&&e(f,g)},u=(0,Ae.useMemo)(()=>(0,O.jsx)("div",{className:"flex items-center gap-2",children:l?.map(m=>(0,O.jsxs)("div",{className:a("text-xs flex items-center gap-0.5",{"text-[#62C554]":m?.validated,"text-[#8E98A8]":!m?.validated}),children:[(0,O.jsx)("span",{className:"",children:m?.validated?(0,O.jsx)(fo,{}):(0,O.jsx)(go,{})}),(0,O.jsx)("span",{className:"",children:m?.label})]},m?.key))}),[l]);return(0,O.jsx)(Y,{sideNodeClassName:"!border-l-0",rightNode:n?(0,O.jsx)("button",{type:"button",onClick:()=>i(m=>!m),children:(0,O.jsx)(mo,{})}):(0,O.jsx)("button",{type:"button",onClick:()=>i(m=>!m),children:(0,O.jsx)(uo,{})}),type:n?"text":"password",onChange:p,description:!o&&u,...r})};Ft.displayName="PasswordInput";var ho=require("class-variance-authority");var ge=require("react/jsx-runtime"),Ya=(0,ho.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"}}),Et=({className:e,status:t="default",disabled:o,error:r,isLoading:n,showAsterisk:i,label:l,description:s,...d})=>{let c=t;return r&&(c="error"),n&&(c="loading"),o&&(c="prefilled"),(0,ge.jsxs)("div",{className:"relative space-y-1",children:[(0,ge.jsx)(H,{showAsterisk:i,error:r,children:l}),(0,ge.jsx)("textarea",{className:a("min-h-[80px]",oe({status:c}),e),disabled:n||o,...d}),(0,ge.jsx)(U,{className:"text-gray-400 text-sm !font-normal",children:s}),(0,ge.jsx)($,{error:r})]})};Et.displayName="Textarea";var he=P(require("react"));var se=P(require("react")),A=require("cmdk"),Lo=require("lucide-react");var Be=P(require("react")),L=P(require("@radix-ui/react-dialog"));var Ie=require("react/jsx-runtime"),yo=()=>(0,Ie.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,Ie.jsx)("path",{d:"M18 6 6 18"}),(0,Ie.jsx)("path",{d:"m6 6 12 12"})]});var w=require("react/jsx-runtime"),zr=L.Root,Zr=L.Trigger,vo=L.Portal,bo=Be.forwardRef(({className:e,...t},o)=>(0,w.jsx)(L.Overlay,{ref:o,className:a("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}));bo.displayName=L.Overlay.displayName;var At=Be.forwardRef(({className:e,hideCloseButton:t,children:o,...r},n)=>(0,w.jsxs)(vo,{children:[(0,w.jsx)(bo,{}),(0,w.jsxs)(L.Content,{ref:n,className:a("fixed left-[50%] top-[50%] z-50 grid w-full 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),...r,children:[o,!t&&(0,w.jsxs)(L.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",children:[(0,w.jsx)(yo,{}),(0,w.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));At.displayName=L.Content.displayName;var xo=({className:e,...t})=>(0,w.jsx)("div",{className:a("flex flex-col space-y-1.5 text-left",e),...t});xo.displayName="DialogHeader";var wo=({className:e,...t})=>(0,w.jsx)("div",{className:a("flex flex-row justify-end sm:space-x-2",e),...t});wo.displayName="DialogFooter";var No=Be.forwardRef(({className:e,...t},o)=>(0,w.jsx)(L.Title,{ref:o,className:a("text-xl font-semibold leading-none tracking-tight",e),...t}));No.displayName=L.Title.displayName;var Po=Be.forwardRef(({className:e,...t},o)=>(0,w.jsx)(L.Description,{ref:o,className:a("text-sm text-gray-500",e),...t}));Po.displayName=L.Description.displayName;var tt=({trigger:e=void 0,children:t,open:o,onOpenChange:r,hideCloseButton:n,footer:i,title:l,description:s,contentClassName:d,headerClassName:c,titleClassName:p,descriptionClassName:u,footerClassName:m,asChild:g=!0,onOpenAutoFocus:f,onCloseAutoFocus:v,onEscapeKeyDown:N,onInteractOutside:y,onPointerDownOutside:G,...ve})=>(0,w.jsxs)(zr,{...ve,open:o,onOpenChange:r,children:[(0,w.jsx)(Zr,{asChild:g,children:e}),(0,w.jsx)(vo,{children:(0,w.jsxs)(At,{className:d,hideCloseButton:n,onOpenAutoFocus:f,onCloseAutoFocus:v,onEscapeKeyDown:N,onPointerDownOutside:G,onInteractOutside:y,children:[l||s?(0,w.jsxs)(xo,{className:c,children:[l&&(0,w.jsx)(No,{className:p,children:l}),s&&(0,w.jsx)(Po,{className:u,children:s})]}):(0,w.jsx)(w.Fragment,{}),t,i&&(0,w.jsx)(wo,{className:m,children:i})]})})]});tt.displayName=L.Dialog.displayName;var B=require("react/jsx-runtime"),Me=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command,{ref:o,className:a("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t}));Me.displayName=A.Command.displayName;var Ve=se.forwardRef(({className:e,CommandInputContainerClassName:t,loading:o,...r},n)=>(0,B.jsxs)("div",{className:a("flex items-center border-0 px-3 gap-2",t),"cmdk-input-wrapper":"",children:[o?(0,B.jsx)(be,{size:16,colour:"secondary"}):(0,B.jsx)(Lo.Search,{className:"mr-2 h-4 w-4 shrink-0 opacity-50"}),(0,B.jsx)(A.Command.Input,{ref:n,className:a("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:o,...r})]}));Ve.displayName=A.Command.Input.displayName;var He=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command.List,{ref:o,className:a("overflow-y-auto overflow-x-hidden",e),...t}));He.displayName=A.Command.List.displayName;var Oe=se.forwardRef((e,t)=>(0,B.jsx)(A.Command.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));Oe.displayName=A.Command.Empty.displayName;var We=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command.Group,{ref:o,className:a("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}));We.displayName=A.Command.Group.displayName;var _r=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command.Separator,{ref:o,className:a("-mx-1 h-px bg-border",e),...t}));_r.displayName=A.Command.Separator.displayName;var Ge=se.forwardRef(({className:e,...t},o)=>(0,B.jsx)(A.Command.Item,{ref:o,className:a("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}));Ge.displayName=A.Command.Item.displayName;var Kr=({className:e,...t})=>(0,B.jsx)("span",{className:a("ml-auto text-xs tracking-widest text-muted-foreground",e),...t});Kr.displayName="CommandShortcut";var Ro=P(require("react")),j=P(require("@radix-ui/react-popover"));var le=require("react/jsx-runtime"),re=j.Root,J=j.Trigger,ee=Ro.forwardRef(({className:e,align:t="center",sideOffset:o=4,portal:r=!0,...n},i)=>r?(0,le.jsx)(j.Portal,{children:(0,le.jsx)(j.Content,{ref:i,align:t,sideOffset:o,className:a("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,le.jsx)(j.Content,{ref:i,align:t,sideOffset:o,className:a("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}));ee.displayName=j.Content.displayName;var Ce=({trigger:e,children:t,open:o,onOpenChange:r,contentClassName:n,asChild:i=!0,align:l,side:s,alignOffset:d,triggerClassName:c,sideOffset:p,onOpenAutoFocus:u,onCloseAutoFocus:m,portal:g=!0,...f})=>(0,le.jsxs)(re,{...f,open:o,onOpenChange:r,children:[(0,le.jsx)(J,{asChild:i,className:c,children:e}),(0,le.jsx)(ee,{alignOffset:d,sideOffset:p,side:s,align:l,className:n,onOpenAutoFocus:u,onCloseAutoFocus:m,portal:g,children:t})]});Ce.displayName=j.Root.displayName;var It=P(require("react")),z=P(require("@radix-ui/react-scroll-area"));var ce=require("react/jsx-runtime"),ze=It.forwardRef(({className:e,viewPortClassName:t,children:o,...r},n)=>(0,ce.jsxs)(z.Root,{ref:n,className:a("relative overflow-hidden",e),...r,children:[(0,ce.jsx)(z.Viewport,{className:a("h-full w-full rounded-[inherit]",t),children:o}),(0,ce.jsx)(Do,{}),(0,ce.jsx)(z.Corner,{})]}));ze.displayName=z.Root.displayName;var Do=It.forwardRef(({className:e,orientation:t="vertical",...o},r)=>(0,ce.jsx)(z.ScrollAreaScrollbar,{ref:r,orientation:t,className:a("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),...o,children:(0,ce.jsx)(z.ScrollAreaThumb,{className:"relative flex-1 rounded-full bg-[#959595] transition hover:bg-[#808080]"})}));Do.displayName=z.ScrollAreaScrollbar.displayName;var E=require("react/jsx-runtime"),To=({className:e,value:t,placeholder:o="",status:r,disabled:n})=>(0,E.jsx)(J,{asChild:!0,disabled:n,children:(0,E.jsxs)("button",{disabled:n,className:a(oe({status:r}),"[&>span]:justify-start [&>span]:items-center gap-2 flex h-12 w-full items-center justify-between goup",t?"":"text-[#79818C]",e),children:[t??o??"Select options...",(0,E.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",className:" data-[state=open]:goup-rotate-180",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"})})]})}),ot=({options:e=[],value:t,onChange:o,containerClassName:r,placeholder:n,disabled:i,loading:l,optionComponent:s,children:d,modal:c=!1,hideSearch:p,className:u,inputValue:m,onValueChange:g,onInputValueChange:f})=>{let[v,N]=he.useState(!1),y=he.useRef(null),[G,ve]=he.useState(void 0);return he.useLayoutEffect(()=>{y.current&&ve(y.current.clientWidth)},[y.current]),(0,E.jsxs)(re,{modal:c,open:v,onOpenChange:N,children:[(0,E.jsx)("div",{className:a("w-full",u),ref:y,children:d}),(0,E.jsx)(ee,{portal:!c,className:"p-0 min-w-[200px]",style:{width:G},children:(0,E.jsxs)(Me,{className:a("relative max-h-[270px]",{"mt-2":!p}),children:[!p&&(0,E.jsx)(Ve,{loading:l,placeholder:n??"Search options...",onValueChange:f,value:m,CommandInputContainerClassName:"mx-2 border rounded-md border-[#DEDEDE]"}),(0,E.jsx)(ze,{viewPortClassName:"max-h-[225px]",className:a("w-full px-0 h-full overflow-y-auto",r),children:(0,E.jsxs)(He,{children:[!p&&(0,E.jsx)(Oe,{children:"No result found."}),(0,E.jsx)(We,{className:"w-full",children:e?.map(I=>(0,E.jsx)(Ge,{defaultValue:t?.label,value:I.label,disabled:i,onSelect:()=>{o(I),N(!1),g?.(I?.value)},children:s?s(I):I.label},I.value))})]})})]})})]})};var Bt=[{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"}],ko=()=>{let e={};return Bt?.forEach(t=>{e[t?.internetCountryCode]=t?.countryName}),e};var Ze=P(require("react")),rt=P(require("react-phone-number-input")),Fo=P(require("react-phone-number-input/flags"));var de=require("react/jsx-runtime"),$r=e=>(0,de.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"none",...e,children:[(0,de.jsx)("rect",{width:"32",height:"32",fill:"#60A5FA"})," ",(0,de.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,de.jsx)("rect",{x:"2",y:"28",width:"28",height:"3",fill:"#D1D5DB"}),(0,de.jsx)("path",{d:"M0 16H32M8 0V32M16 0V32M24 0V32",stroke:"#2563EB",strokeWidth:"0.5",vectorEffect:"non-scaling-stroke"}),(0,de.jsx)("path",{d:"M0 16H32",stroke:"#2563EB",strokeWidth:"1",vectorEffect:"non-scaling-stroke"})]}),So=$r;var C=require("react/jsx-runtime"),Mt=Ze.forwardRef(({className:e,onChange:t,defaultCountry:o="NG",modal:r,showAsterisk:n,label:i,description:l,error:s,...d},c)=>{let p=u=>(0,C.jsx)(Ur,{...u,status:d.status,modal:r});return(0,C.jsxs)("div",{className:"relative space-y-1",children:[(0,C.jsx)(H,{showAsterisk:n,error:s,children:i}),(0,C.jsx)(rt.default,{ref:c,className:a("flex",e),flagComponent:ae,countrySelectComponent:p,inputComponent:Eo,defaultCountry:o,onChange:u=>{t&&t?.(u)},...d}),(0,C.jsx)(U,{className:"text-gray-400 text-sm !font-normal",children:l}),(0,C.jsx)($,{error:s})]})});Mt.displayName="PhoneInput";var Eo=Ze.forwardRef(({className:e,...t},o)=>(0,C.jsx)(Y,{className:a("!rounded-s-none h-10",e),...t,ref:o}));Eo.displayName="InputComponent";var Ur=({disabled:e,value:t,onChange:o,options:r,status:n,modal:i})=>{let l=Ze.useCallback(s=>{o(s)},[o]);return(0,C.jsxs)(re,{modal:i,children:[(0,C.jsx)(J,{disabled:e,children:(0,C.jsxs)("div",{className:a(oe({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,C.jsx)(ae,{country:t,countryName:t}),(0,C.jsx)("svg",{className:a("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,C.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,C.jsx)(ee,{portal:!i,className:"w-[200px] md:w-[300px] p-0",children:(0,C.jsx)(Me,{children:(0,C.jsx)(He,{children:(0,C.jsxs)(ze,{className:"h-72",children:[(0,C.jsx)(Ve,{placeholder:"Search country..."}),(0,C.jsx)(Oe,{children:"No country found."}),(0,C.jsx)(We,{children:r.filter(s=>s.value).map(s=>(0,C.jsxs)(Ge,{className:"gap-2",onSelect:()=>l(s.value),children:[(0,C.jsx)(ae,{country:s.value,countryName:s.label}),(0,C.jsx)("span",{className:"flex-1 text-sm",children:s.label}),s.value&&(0,C.jsx)("span",{className:"text-[#191919]/50 text-sm dark:text-white",children:`+${rt.getCountryCallingCode(s.value)}`}),(0,C.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",className:a("ml-auto",s.value===t?"opacity-100":"opacity-0"),children:(0,C.jsx)("path",{d:"M4 8.00008L6.66353 10.6636L12 5.33655",stroke:"#959595",strokeWidth:"1.06667",strokeLinecap:"round",strokeLinejoin:"round"})})]},`${s.value}-${s.label}`))})]})})})})]})},ae=({country:e,countryName:t,className:o})=>{let r=Fo.default[e];return e==="GLOBAL"?(0,C.jsx)("span",{className:a("bg-white/20 flex h-4 w-6 overflow-hidden rounded-sm",o),children:(0,C.jsx)(So,{className:"w-full h-[90%]"})}):(0,C.jsx)("span",{className:a("bg-white/20 flex h-4 w-6 overflow-hidden rounded-sm",o),children:r&&(0,C.jsx)(r,{title:t})})};ae.displayName="FlagComponent";var k=require("react/jsx-runtime"),Xr=ko(),Yr=({className:e,value:t,placeholder:o="",status:r,disabled:n})=>(0,k.jsx)(J,{asChild:!0,disabled:n,children:(0,k.jsxs)("button",{disabled:n,className:a(oe({status:r}),"[&>span]:justify-start [&>span]:items-center gap-2 flex w-full items-center justify-between goup",t?"":"text-[#79818C]",e),children:[t?(0,k.jsxs)("div",{className:"flex gap-2 items-center",children:[(0,k.jsx)(ae,{country:t,countryName:t,className:"ml-1 !w-6 h-5"}),(0,k.jsxs)("span",{className:"",children:[" ",Xr[t]]})]}):o??"Select options...",(0,k.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",className:" data-[state=open]:goup-rotate-180",children:(0,k.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"})})]})}),Ao=({hideSearch:e=!0,showAsterisk:t,label:o,description:r,error:n,...i})=>{let l=Bt?.map(s=>({value:s?.internetCountryCode,label:s?.countryName,...s}));return(0,k.jsxs)("div",{className:"relative space-y-1",children:[(0,k.jsx)(H,{showAsterisk:t,error:n,children:o}),(0,k.jsx)(ot,{options:l,hideSearch:e,optionComponent:s=>(0,k.jsxs)("div",{className:"w-full flex items-center gap-2",children:[(0,k.jsx)(ae,{country:s?.internetCountryCode,countryName:s?.label,className:"ml-2 !w-6 !h-5"}),(0,k.jsx)("span",{className:"flex-1 text-sm",children:s?.label})]}),...i,children:(0,k.jsx)(Yr,{value:i?.value?.value,status:i?.status,placeholder:i?.placeholder??" Select Country"})}),(0,k.jsx)(U,{className:"text-gray-400 text-sm !font-normal",children:r}),(0,k.jsx)($,{error:n})]})};var pe=require("react/jsx-runtime"),Io=({showAsterisk:e,label:t,description:o,error:r,hideSearch:n=!0,status:i,...l})=>(0,pe.jsxs)("div",{className:"relative space-y-1",children:[(0,pe.jsx)(H,{showAsterisk:e,error:r,children:t}),(0,pe.jsx)(ot,{hideSearch:n,...l,containerClassName:"h-full",children:(0,pe.jsx)(To,{disabled:l?.disabled,placeholder:l?.placeholder??"Select",status:i,value:l?.value?.label??l?.value?.value})}),(0,pe.jsx)(U,{className:"text-gray-400 text-sm !font-normal",children:o}),(0,pe.jsx)($,{error:r})]});var Bo=P(require("react-otp-input"));var Mo=require("class-variance-authority"),Vo=require("react"),Vt=require("react/jsx-runtime"),jr=(0,Mo.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",{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"}}),Ho=({numInputs:e=4,inputStyle:t,containerStyle:o,placeholder:r="-",status:n,...i})=>{let l=(0,Vo.useMemo)(()=>r||new Array(e).fill("").reduce((c,p)=>c+=p,""),[e,r]);return(0,Vt.jsx)(Bo.default,{numInputs:e,placeholder:l,containerStyle:a("w-full",o),inputStyle:a(jr({status:n}),t),renderInput:s=>(0,Vt.jsx)("input",{...s}),...i})};var at=require("react"),h=require("react/jsx-runtime"),Jr=({type:e})=>e==="gray"?(0,h.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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,h.jsx)("svg",{stroke:"#70B6F6",fill:"#70B6F6","stroke-width":"0",viewBox:"0 0 16 16",height:"24",width:"24",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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,h.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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,h.jsx)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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,h.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,h.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"})}),Oo=({type:e="info",title:t,description:o,open:r,showCloseButton:n,bottomNode:i,sideNode:l,onClose:s,showIcon:d=!0})=>{let[c,p]=(0,at.useState)(r);(0,at.useEffect)(()=>{p(r)},[r]);let u="",m="";switch(e){case"gray":u="#eeeef0",m="#79818c";break;case"info":u="#ebf5fd",m="#70B6F6";break;case"warning":u="#fff8df",m="#ffc700";break;case"success":u="#e0f9f0",m="#49e0aa";break;case"danger":u="#fde8e9",m="#f3777c";break;default:u="#eeeef0",m="#79818c";break}function g(){p(!1),s&&s()}return c?(0,h.jsxs)("div",{className:"w-full shadow-lg transform flex items-center rounded-md",style:{background:u||"#ebf5fd"},children:[(0,h.jsx)("div",{className:"flex-none absolute rounded-l-[2px] rounded-l-4px h-[4px] w-full top-0",style:{background:m||"#70B6F6"}}),(0,h.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,h.jsxs)("div",{className:"flex flex-row gap-2.5 items-start w-full h-full",children:[d&&(0,h.jsx)("div",{className:"h-full flex justify-end",children:(0,h.jsx)(Jr,{type:e})}),(0,h.jsxs)("div",{className:"w-full gap-3 h-full flex flex-col md:flex-row items-start justify-between",children:[(0,h.jsxs)("div",{className:"flex-1 gap-3 h-full flex flex-col items-start justify-between",children:[(t||o)&&(0,h.jsxs)("div",{children:[t&&(0,h.jsx)("div",{className:"text-sm font-bold text-[#191919]",children:t}),o&&(0,h.jsx)("div",{className:"text-sm font-normal text-[#5D5D5D] mt-1",children:o})]}),i]}),l]})]}),n&&(0,h.jsx)("div",{className:"w-1/10 h-full flex flex-col justify-start items-center",children:(0,h.jsx)("button",{onClick:g,children:(0,h.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,h.jsx)("path",{d:"M3.3335 3.33337L12.6662 12.6661",stroke:"#191919",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,h.jsx)("path",{d:"M3.33429 12.6661L12.667 3.33337",stroke:"#191919",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]})})})]})]}):null};var Go=require("react"),nt=require("lucide-react"),it=require("framer-motion");var ne=require("react/jsx-runtime"),zo=({text:e,textToCopy:t,onCopy:o,iconsPosition:r="right",clampText:n=!0,textClassName:i})=>{let[l,s]=(0,Go.useState)(!1),d=()=>{navigator.clipboard.writeText(t??e).then(()=>{s(!0),o?.(),setTimeout(()=>s(!1),2e3)})},c=l?nt.CheckIcon:nt.Copy;return(0,ne.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:[r==="left"&&(0,ne.jsx)(Wo,{Icon:c,onClick:d,copied:l}),(0,ne.jsx)("span",{className:a({"truncate max-w-[100px]":n},i),children:e}),r==="right"&&(0,ne.jsx)(Wo,{Icon:c,onClick:d,copied:l})]})},Wo=({Icon:e,onClick:t,copied:o})=>(0,ne.jsx)(it.AnimatePresence,{mode:"wait",children:(0,ne.jsx)(it.motion.div,{initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2},onClick:t,children:(0,ne.jsx)(e,{className:`w-5 h-5 ${o?"text-green-500":"text-gray-500 hover:text-gray-700 transition"}`})},o?"check":"copy")});var _e=require("react");var Zo=require("lucide-react"),Ht=require("react/jsx-runtime"),st=({value:e,onChange:t,debounce:o=500,addon:r,...n})=>{let[i,l]=(0,_e.useState)(e??""),s=d=>l(d.target.value);return(0,_e.useEffect)(()=>{e&&l(e)},[e]),(0,_e.useEffect)(()=>{let d=setTimeout(()=>{t(i)},o);return()=>clearTimeout(d)},[i,o,t]),(0,Ht.jsx)(Y,{leftNode:r??(0,Ht.jsx)(Zo.Search,{className:" w-4 h-4 text-gray-400"}),sideNodeClassName:"bg-transparent !pr-0 !w-4 border-0 !min-w-[40px]",...n,className:a("!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:s,value:i})};var Ot=require("react"),_o=require("lucide-react"),S=require("react/jsx-runtime"),Ko=e=>{let{environment:t,branch:o,version:r,deployTime:n,showBanner:i,onClose:l,initDefault:s,removeFromStorage:d,syncLocalStorageToState:c}=e,p=t||process.env.NEXT_PUBLIC_NODE_ENV;return p!=="staging"&&p!=="sandbox"||((0,Ot.useEffect)(()=>{c()},[c]),(0,Ot.useEffect)(()=>{let u;return(p==="staging"||p==="sandbox")&&(u=setInterval(()=>{d(),s()},5*60*1e3)),()=>{u&&clearInterval(u)}},[i,t,l,d,s,p]),!i)?null:(0,S.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,S.jsx)("button",{onClick:l,className:"absolute top-2 right-2",children:(0,S.jsx)(_o.X,{})}),(0,S.jsxs)("div",{className:"space-y-2 text-sm",children:[(0,S.jsxs)("div",{className:"flex gap-2",children:[(0,S.jsx)("span",{className:"font-medium",children:"Environment:"}),(0,S.jsx)("span",{className:"text-blue-600 capitalize",children:p})]}),(0,S.jsxs)("div",{className:"flex gap-2",children:[(0,S.jsx)("span",{className:"font-medium",children:"Branch:"}),(0,S.jsx)("span",{className:"text-green-600 capitalize",children:o||process.env.NEXT_PUBLIC_DEPLOY_BRANCH})]}),(0,S.jsxs)("div",{className:"flex gap-2",children:[(0,S.jsx)("span",{className:"font-medium",children:"Version:"}),(0,S.jsx)("span",{className:"text-purple-600",children:r||process.env.NEXT_PUBLIC_DEPLOY_VERSION})]}),(0,S.jsxs)("div",{className:"flex gap-2",children:[(0,S.jsx)("span",{className:"font-medium",children:"Deploy Time:"}),(0,S.jsx)("span",{className:"text-orange-600",children:n||process.env.NEXT_PUBLIC_DEPLOY_TIME})]})]})]})};var $e=P(require("react")),M=require("vaul"),Xo=require("class-variance-authority");var Ke=require("react/jsx-runtime"),$o=()=>(0,Ke.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,Ke.jsx)("path",{d:"M18 6 6 18"}),(0,Ke.jsx)("path",{d:"m6 6 12 12"})]});var lt=require("react");function Uo(){let[e,t]=(0,lt.useState)({width:window.innerWidth,height:window.innerHeight});return(0,lt.useEffect)(()=>{function o(){t({width:window.innerWidth,height:window.innerHeight})}return window.addEventListener("resize",o),o(),()=>window.removeEventListener("resize",o)},[]),e}var b=require("react/jsx-runtime"),ct=({shouldScaleBackground:e=!0,...t})=>(0,b.jsx)(M.Drawer.Root,{direction:"right",shouldScaleBackground:e,...t});ct.displayName="Drawer";var qr=M.Drawer.Trigger,Yo=M.Drawer.Close,Qr=M.Drawer.Portal,jo=$e.forwardRef(({className:e,...t},o)=>(0,b.jsx)(M.Drawer.Overlay,{className:a("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:o}));jo.displayName=M.Drawer.Overlay.displayName;var ea=(0,Xo.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 sm:max-w-[512px] ",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 sm:max-w-[512px]"}},defaultVariants:{side:"right"}}),Jo=$e.forwardRef(({side:e="right",hideCloseButton:t,className:o,children:r,...n},i)=>(0,b.jsxs)(Qr,{children:[(0,b.jsx)(jo,{}),(0,b.jsxs)(M.Drawer.Content,{ref:i,className:a(ea({side:e}),o),...n,children:[(0,b.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"}),r,!t&&(0,b.jsxs)(M.Drawer.Close,{className:"absolute right-2 top-3 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-secondary",children:[(0,b.jsx)($o,{}),(0,b.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));Jo.displayName=M.Drawer.Content.displayName;var qo=({className:e,...t})=>(0,b.jsx)("div",{className:a("text-lg flex flex-col border-b border-b-gray-200 space-y-1 text-left w-full p-3",e),...t});qo.displayName="DrawerHeader";var Qo=({className:e,...t})=>(0,b.jsx)("div",{className:a("flex flex-col-reverse sm:flex-row m-auto right-0 left-0 p-3 sm:space-x-2 border-t border-t-[#EDEDED] dark:border-t-[#242424] w-full",e),...t});Qo.displayName="DrawerFooter";var er=$e.forwardRef(({className:e,...t},o)=>(0,b.jsx)(M.Drawer.Title,{ref:o,className:a("text-xl font-semibold text-[#191919] dark:text-white",e),...t}));er.displayName=M.Drawer.Title.displayName;var tr=$e.forwardRef(({className:e,...t},o)=>(0,b.jsx)(M.Drawer.Description,{ref:o,className:a("text-xs text-[#5d5c5c] dark:text-white",e),...t}));tr.displayName=M.Drawer.Description.displayName;var or=({trigger:e=void 0,children:t,open:o=void 0,onOpenChange:r=void 0,hideCloseButton:n,footer:i,title:l,description:s,contentClassName:d,headerClassName:c,titleClassName:p,descriptionClassName:u,footerClassName:m,asChild:g=!0,onOpenAutoFocus:f,onCloseAutoFocus:v})=>{let{width:N}=Uo(),y=N<768?"bottom":"right";return(0,b.jsxs)(ct,{open:o,onOpenChange:r,direction:y,children:[(0,b.jsx)(qr,{className:"cursor-pointer",asChild:g,children:e}),(0,b.jsxs)(Jo,{className:a("flex flex-col gap-0 justify-start items-start max-h-[90vh] md:max-h-full w-full !max-w-md",d),side:y,hideCloseButton:n,onOpenAutoFocus:f,onCloseAutoFocus:v,children:[l||s?(0,b.jsxs)(qo,{className:c,children:[l&&(0,b.jsx)(er,{className:p,children:l}),s&&(0,b.jsx)(tr,{className:u,children:s})]}):(0,b.jsx)(b.Fragment,{}),(0,b.jsx)("div",{className:a("flex w-full overflow-y-auto flex-col justify-start items-start p-4 flex-1 h-[30px]"),children:t}),i&&(0,b.jsx)(Qo,{className:m,children:i})]})]})};var Wt=require("react/jsx-runtime"),rr=()=>(0,Wt.jsx)("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 20 20","aria-hidden":"true",className:"h-5 w-5",height:"1em",width:"1em",xmlns:"http://www.w3.org/2000/svg",children:(0,Wt.jsx)("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})});var me=require("react/jsx-runtime"),ar=e=>(0,me.jsxs)("svg",{viewBox:"0 0 60 30",className:"w-full max-w-md h-auto","aria-label":"Union Jack - Flag of the United Kingdom",...e,children:[(0,me.jsx)("rect",{width:"60",height:"30",fill:"#00247D"}),(0,me.jsx)("path",{d:"M0,0 L60,30 M60,0 L0,30",stroke:"#FFFFFF",strokeWidth:"6"}),(0,me.jsx)("path",{d:"M0,0 L60,30 M60,0 L0,30",stroke:"#CF142B",strokeWidth:"4"}),(0,me.jsx)("path",{d:"M30,0 L30,30 M0,15 L60,15",stroke:"#FFFFFF",strokeWidth:"10"}),(0,me.jsx)("path",{d:"M30,0 L30,30 M0,15 L60,15",stroke:"#CF142B",strokeWidth:"6"})]});var xe=require("react/jsx-runtime"),nr=e=>(0,xe.jsxs)("svg",{viewBox:"0 0 60 40",className:"w-full max-w-md h-auto","aria-label":"Tricolore - Flag of France",...e,children:[(0,xe.jsx)("rect",{x:"0",y:"0",width:"20",height:"40",fill:"#002395"}),(0,xe.jsx)("rect",{x:"20",y:"0",width:"20",height:"40",fill:"#FFFFFF"}),(0,xe.jsx)("rect",{x:"40",y:"0",width:"20",height:"40",fill:"#ED2939"})]});var Ue=require("react/jsx-runtime"),ir=()=>(0,Ue.jsxs)("svg",{width:"20",height:"18",viewBox:"0 0 8 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,Ue.jsx)("path",{d:"M5.50257 12.9395L3.68439 14.7576L1.86621 12.9395",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),(0,Ue.jsx)("path",{d:"M5.50257 5.06055L3.68439 3.24237L1.86621 5.06055",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"})]});var sr=require("@radix-ui/react-popover"),F=require("react/jsx-runtime"),ta=[{key:"en",label:"English"},{key:"fr",label:"French"}],oa=({locale:e})=>e==="fr"?(0,F.jsx)(nr,{width:10}):(0,F.jsx)(ar,{width:10}),ra=({locale:e})=>(0,F.jsx)("div",{className:"px-2 py-1 ",children:(0,F.jsxs)("div",{className:"flex items-center gap-2.5",children:[(0,F.jsx)(oa,{locale:e})," ",(0,F.jsx)("span",{className:"uppercase",children:e}),(0,F.jsx)(ir,{})]})}),lr=({locale:e="en",onChange:t,locales:o=ta})=>(0,F.jsxs)(re,{children:[(0,F.jsx)("div",{className:"flex items-center gap-2 px-2 py-1 rounded-lg shadow border-[0.5px] border-gray-50/50 text-current bg-white/10 ",children:(0,F.jsx)(J,{className:"!p-0 !bg-transparent ",children:(0,F.jsx)(ra,{locale:e})})}),(0,F.jsx)(ee,{side:"bottom",className:"p-0 max-w-max rounded-md overflow-hidden mx-auto mt-2",children:(0,F.jsx)("div",{children:o?.map(r=>(0,F.jsxs)(sr.PopoverClose,{type:"button",className:a("flex items-center gap-3 px-3 py-1 text-sm hover:bg-blue-50 w-full transition-all",{"bg-blue-100":e&&e===r?.key}),onClick:()=>t?.(r?.key),children:[r?.label," ",e&&e===r?.key&&(0,F.jsx)(rr,{})]},r?.key))})})]});var ye=require("react");var dt=require("framer-motion"),pt=require("react"),cr=require("react-icons/hi"),dr=require("react-icons/fi"),pr=require("react-icons/bs");var ue=require("react/jsx-runtime"),Xe=({activeBusiness:e,onTriggerClick:t,iconOnly:o=!1,className:r,rightNode:n})=>(0,ue.jsxs)("div",{id:"sidemenu_business_bar",role:"button",onClick:t||void 0,className:a("relative flex w-full items-center rounded-lg text-black bg-white",{"border-[.5px] border-[#E9EBF8] py-1 px-2":!o,"hover:bg-primary-accent transition-all duration-150 cursor-pointer ":!!t},r),children:[(0,ue.jsx)("section",{className:a("flex items-center justify-center bg-[#E9EBF8] text-primary-main rounded-md mr-3 text-xl font-medium",{"w-10 h-10":!o,"w-full h-10 mr-0":o}),children:e?.name?.charAt(0)||"M"}),!o&&(0,ue.jsxs)("section",{className:" flex-1 flex justify-between items-center relative text-black w-full -space-y-1 tracking-wide",children:[(0,ue.jsxs)("div",{className:"flex-1",children:[(0,ue.jsx)("h2",{className:"text-base truncate capitalize font-medium w-full max-w-[150px]",children:e?.name}),(0,ue.jsx)("p",{className:"text-sm text-[#A5A5A5] flex items-center truncate w-full max-w-[150px]",children:e?.email})]}),n]})]});var mr=require("lucide-react"),D=require("react/jsx-runtime"),aa={hidden:{y:"-12px",opacity:0},visible:{y:"0",opacity:1,transition:{type:"spring",damping:25,stiffness:500}},exit:{y:"-12px",opacity:0,transition:{type:"spring",damping:25,stiffness:500}}},ur=({activeBusiness:e,toggleAddBusinessDrawer:t,businesses:o=[],handleSwitchBusiness:r,onLogoutClick:n,onToggleSideBar:i,toggleShowBusiness:l,isMobile:s,collapseType:d})=>{let[c,p]=(0,pt.useState)(""),u=(0,pt.useMemo)(()=>{let y=c.toLowerCase();return(o||[]).filter(G=>G.name?.toLowerCase().startsWith(y))},[o,c]),m=d==="hidden"||s,g=y=>p(y.target.value),f=y=>{r(y||""),m&&i(!1),p("")},v=()=>{t(),l(!1),m&&i(!1),p("")},N=()=>{n?.(),l(!1),m&&i(!1),p("")};return(0,D.jsx)(dt.AnimatePresence,{initial:!1,children:(0,D.jsx)(dt.motion.div,{initial:"hidden",animate:"visible",exit:"exit",variants:aa,children:(0,D.jsxs)("div",{className:"w-72 bg-white border rounded-xl shadow-md overflow-hidden p-3",children:[(0,D.jsx)(Xe,{activeBusiness:e,rightNode:(0,D.jsx)("div",{className:"h-3 w-3 bg-[#62C554] rounded-full"}),className:"bg-[#FAFAFA] border-none p-3"}),(0,D.jsx)("div",{className:"mt-3",children:(0,D.jsx)(Y,{label:"Search Account",leftNode:(0,D.jsx)(mr.ChevronUp,{className:"h-4 w-4 text-gray-500"}),value:c,onChange:g,placeholder:"Search Account",className:"text-sm"})}),(0,D.jsx)("ul",{className:"max-h-48 overflow-y-auto mt-2 px-1 space-y-2",children:u.map(y=>(0,D.jsx)(Xe,{onTriggerClick:()=>f(y?.clientId),activeBusiness:y,rightNode:e.clientId===y.clientId?(0,D.jsx)(cr.HiCheck,{className:"text-primary-600",size:18}):void 0,className:a("bg-white border-none ",{"bg-[#FAFAFA]":e.clientId===y.clientId})},y.clientId))}),(0,D.jsx)("div",{className:"py-2 ",children:(0,D.jsxs)("button",{onClick:v,className:"w-full flex items-center justify-start gap-2 text-sm text-[#0033C7] border-[#BECFFF] border-[0.5px] rounded-lg py-2 px-3 hover:bg-primary-accent transition ",children:[(0,D.jsx)(pr.BsPlus,{size:18,className:"text-primary-main"})," Add Account"]})}),(0,D.jsx)("div",{className:"bg-[#FAFAFA] px-3 py-2 -m-3 mt-4",children:(0,D.jsxs)("button",{className:"w-full flex items-center gap-2 text-sm text-black hover:text-gray-700 transition p-2 hover:bg-primary-accent",onClick:N,children:[(0,D.jsx)(dr.FiLogOut,{size:16})," Log Out"]})})]})})})};var q=require("react/jsx-runtime"),fr=({activeBusiness:e,toggleAddBusinessDrawer:t,toggleShowBusiness:o,businesses:r=[],handleSwitchBusiness:n,iconOnly:i=!1,onLogoutClick:l,isMobile:s,onToggleSideBar:d,isBusinessShown:c,collapseType:p})=>(0,q.jsx)("div",{className:"px-4 relative mb-0 ",children:(0,q.jsx)(Ce,{side:s?"top":"right",open:c,onOpenChange:o,align:"end",contentClassName:"!bg-transparent !shadow-none !p-0",trigger:(0,q.jsx)("div",{className:"flex items-center w-full",children:(0,q.jsx)(Xe,{activeBusiness:e,onTriggerClick:()=>o(!0),iconOnly:i,rightNode:(0,q.jsx)(na,{className:"stroke-gray-500"})})}),children:(0,q.jsx)(ur,{activeBusiness:e,handleSwitchBusiness:n,toggleAddBusinessDrawer:t,businesses:r,onLogoutClick:l,onToggleSideBar:d,toggleShowBusiness:o,collapseType:p,isMobile:s})})}),na=({className:e})=>(0,q.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",className:a("lucide lucide-chevrons-up-down-icon lucide-chevrons-up-down",e),children:[(0,q.jsx)("path",{d:"M7 22l5 5 5-5"}),(0,q.jsx)("path",{d:"M7 4l5-5 5 5"})]});var mt=require("framer-motion"),ut=require("react"),gr=require("react-icons/fi");var x=require("react/jsx-runtime"),ia={hidden:{opacity:0,height:0},visible:{opacity:1,height:"auto",transition:{duration:.3}}},Cr=({isIconsOnly:e,isSidebarCollapsed:t,onToggleSideBar:o,currentPath:r,onNavigate:n,collapseType:i,links:l,appConfig:s,isMobile:d})=>{let[c,p]=(0,ut.useState)({}),u=f=>{p(v=>({...v,[f]:!v[f]}))},m=f=>{if(!!f?.children?.length){e?(o(!t),p(N=>({...N,[f.id]:!0}))):u(f.id);return}n(`/${f.to}`)},g=f=>f?.children?.length?(f.children||[]).some(N=>r===N.to):r===f.to;return(0,ut.useEffect)(()=>{if(t){let f={};l.forEach(v=>{v.children&&v.children.length>0&&v.children.some(N=>r===N.to)&&(f[v.id]=!0)}),p(v=>({...v,...f}))}},[t,l,r]),(0,x.jsx)("ul",{className:"w-[90%] space-y-2.5",children:l.map((f,v)=>{if(f.isHidden||s?.hiddenRoutes?.includes(f.key??""))return null;let N=g(f),y=!!f?.children?.length,G=c[f.id];return(0,x.jsxs)("div",{className:"mb-1 relative flex flex-col justify-center items-center",onClick:()=>m(f),children:[N&&!d&&(e||!y||!G)&&(0,x.jsx)("div",{className:"absolute bg-primary-main w-2 h-4 rounded-r-full -translate-y-1/2 top-1/2 left-0"}),(0,x.jsx)("li",{id:f.id,className:a("cursor-pointer transition text-base duration-300 w-full text-[#00000066] font-medium rounded-md mx-auto max-w-full ml-4 p-2",{"bg-[#F6F8FF] text-primary-main ":N&&(!G||!t)},{"hover:bg-gray-100":!N&&(i!=="icons"||!t)},{"bg-white text-primary-main":N},{"flex justify-center text-primary-main !px-0 max-w-[70%]":e&&N,"flex justify-center !px-0 max-w-[70%]":e&&!N}),children:(0,x.jsxs)("div",{className:a("flex items-center w-full",{"justify-center":e}),children:[(0,x.jsx)(De,{trigger:(0,x.jsx)("span",{className:"w-6",onClick:()=>m(f),children:f.icon}),side:"right",hasArrow:!0,open:e?void 0:!1,children:f.name},v),(i!=="icons"||!t)&&(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)("span",{className:"px-3 text-nowrap",children:f.name}),y&&(0,x.jsx)("span",{className:"ml-auto transition-transform duration-300",style:{transform:G?"rotate(90deg)":"rotate(0deg)"},children:(0,x.jsx)(gr.FiChevronRight,{size:18})})]})]})},f.to),y&&(i!=="icons"||!t)&&(0,x.jsx)(mt.AnimatePresence,{children:G&&(0,x.jsx)(mt.motion.div,{initial:"hidden",animate:"visible",exit:"hidden",variants:ia,className:"overflow-hidden w-full",children:(0,x.jsxs)("ul",{className:" mt-1 relative ",children:[f.children?.map(I=>{if(I.isHidden)return null;let Le=r===I.to;return(0,x.jsx)("div",{id:I.id,className:a("relative pl-12 bg-blue-100- mt-4"),children:(0,x.jsxs)("li",{className:a("cursor-pointer transition text-base duration-300 px-3 w-full text-black font-medium opacity-40 rounded-md text-nowrap",{"bg-transparent opacity-100 text-primary-main":Le},{"hover:text-primary-main":!Le}),onClick:()=>n(`/${I.to}`),children:[I.name,Le&&(0,x.jsxs)(x.Fragment,{children:[!d&&(0,x.jsx)("div",{className:"absolute bg-primary-main w-2 h-4 rounded-r-full -translate-y-1/2 top-1/2 left-0"}),(0,x.jsx)("div",{id:"vertical-bar-child",className:"h-4 w-0.5 bg-primary-main absolute left-[30px] z-10 -translate-y-1/2 top-1/2 rounded-t-full rounded-b-full "})]})]})})}),(0,x.jsx)("div",{id:"vertical-bar",className:"bg-white rounded-t-full rounded-b-full h-full w-[4px] absolute left-[29px] top-0"})]})})})]},v)})})};var br=require("lucide-react");var V=require("react/jsx-runtime"),hr=()=>(0,V.jsxs)("svg",{width:"100%",height:40,xmlns:"http://www.w3.org/2000/svg",id:"Layer_1","data-name":"Layer 1",viewBox:"0 0 1565.51 377.21",children:[(0,V.jsxs)("g",{children:[(0,V.jsx)("path",{fill:"#0231C5",d:"m277.49,86.74v85.18l-.41,6.31v.21c-.72,5.8-2.38,11.28-4.86,16.35-1.45,3-3.21,5.9-5.28,8.49-1.55,2.07-3.42,4.04-5.28,5.9-1.66,1.55-3.42,3.11-5.28,4.45-1.66,1.24-3.42,2.38-5.28,3.42-1.76.93-3.52,1.76-5.28,2.59-1.24.52-2.48.93-3.83,1.35l-1.45.52-5.28,1.76-5.28,1.76-5.28,1.76-5.28,1.76-10.56,3.52-.52.21v19.15l-.41.1-3.62,1.14-.83.21-2.79.93-2.48.83-1.14.31-3.62,1.14-.62.21-3,.93-2.28.72-1.35.41-3.62,1.14-.41.1-.52.21h-.21v-37.26c0-1.55.31-3,.72-4.45.1-.31.21-.62.41-.93.83-1.86,2.07-3.52,3.62-4.86.41-.31.83-.72,1.35-1.04.72-.52,1.45-.83,2.28-1.24.21-.1.52-.21.72-.31l.21-.1,2.17-.72.62-.21,3.62-1.14,1.14-.41,5.28-1.76.83-.31,3.62-1.14.93-.31,5.28-1.76,5.28-1.76,5.28-1.76,5.28-1.76,3.83-1.24c.52-.1.93-.31,1.45-.52,1.97-.72,3.73-1.76,5.28-2.9,2.07-1.45,3.83-3.21,5.28-5.18,3.21-4.14,5.07-9.42,5.07-14.9v-85.08c0-5.59-1.76-10.76-5.07-15.01-1.45-1.86-3.11-3.52-5.07-4.97q-.1-.1-.21-.1c-1.66-1.24-3.42-2.17-5.28-2.9-1.76-.72-3.52-1.14-5.28-1.45-1.76-.31-3.52-.31-5.28-.21-1.76.1-3.52.41-5.28.93-.21.1-.52.1-.72.21l-4.55,1.45-5.28,1.66-5.28,1.76-5.69,1.55-5.28,1.76-5.28,1.66-5.28,1.76-5.28,1.66-5.28,1.66-5.28,1.76-5.28,1.66-5.28,1.66-5.28,1.76-5.28,1.66-5.28,1.76-5.28,1.66-5.28,1.76-5.69,1.66-5.28,1.76-3.83,1.24c-.52.21-1.04.31-1.55.52-1.86.72-3.73,1.76-5.28,2.9-2.07,1.45-3.83,3.21-5.28,5.18-3.21,4.24-5.07,9.42-5.07,15.01v33.33c0,3.93.83,7.25,2.07,10.04.1.31.21.52.41.83-.1.1-.31.1-.41.21-.83.41-1.55.72-2.28,1.24-.41.21-.83.52-1.35.72-1.24.72-2.48,1.55-3.62,2.38-.1.1-.31.21-.41.31-1.14.83-2.17,1.66-3.21,2.48-.72.62-1.45,1.24-2.07,1.97-.52.52-1.04.93-1.55,1.45-1.24,1.35-2.48,2.69-3.62,4.14-.1.1-.1.21-.21.31-.72.93-1.35,1.76-1.97,2.69-.52-.72-1.04-1.55-1.45-2.28-.72-1.14-1.35-2.28-1.86-3.52-.62-1.24-1.14-2.59-1.66-3.83-2.38-6-3.62-12.42-3.62-18.94v-33.64c0-8.07,1.86-15.94,5.28-22.77,1.45-3,3.21-5.9,5.28-8.49,1.55-2.07,3.42-4.04,5.28-5.9,1.66-1.55,3.42-3.11,5.28-4.45,1.66-1.24,3.42-2.38,5.28-3.42,1.66-.93,3.42-1.76,5.28-2.59,1.35-.52,2.59-1.04,3.93-1.45l1.35-.41,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.8-1.66,5.28-1.76,5.28-1.66,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,5.28-1.66,5.28-1.76,1.76-.52c1.14-.41,2.38-.72,3.62-1.04,1.76-.41,3.52-.83,5.28-1.04,1.76-.21,3.52-.41,5.28-.41,1.76-.1,3.52,0,5.28.1,1.76.1,3.52.31,5.28.62,1.76.31,3.52.72,5.28,1.24,1.76.52,3.62,1.14,5.28,1.86,1.76.72,3.62,1.66,5.28,2.59,1.86,1.04,3.62,2.17,5.28,3.42h.1c1.86,1.35,3.62,2.79,5.28,4.45,1.97,1.76,3.73,3.73,5.28,5.8,2.07,2.69,3.83,5.49,5.28,8.49,3.73,7.14,5.59,14.9,5.59,23.08Z"}),(0,V.jsx)("path",{fill:"#0231C5",d:"m184.03,136.63v28.05l-.72.21-1.97.62-3.31,1.04-.21.1-3.62,1.14-1.45.52-2.17.72-.52.1h0l-2.17.72-1.86.62-1.76.52-3.52,1.14h-.1l-3.62,1.14-1.66.52-1.97.62-3.31,1.04-.21.1-3.62,1.14-1.45.52-2.17.72-.52.1-2.69.83-.41.1-3.62,1.14-1.24.41-2.38.72-2.9.93-.62.21-3.62,1.14-1.04.31-1.97.62-.62.21-2.79.93-.83.31-3,.93c-.21.1-.41.1-.62.21-.31.1-.62.21-.83.31-.93.41-1.86.83-2.79,1.35-.83.41-1.76.93-2.59,1.55-.31.21-.72.52-1.04.83-1.35,1.04-2.48,2.17-3.62,3.52-.21.21-.41.52-.62.83-1.14,1.55-2.17,3.21-3,5.07-1.35,3.11-2.07,6.42-2.07,9.94v82.39c0,2.59.72,5.07,2.07,7.14.83,1.35,2.07,2.59,3.42,3.62q.1.1.21.1c1.14.83,2.28,1.45,3.62,1.76,1.14.41,2.38.62,3.62.62,1.14,0,2.38-.1,3.62-.41.31-.1.62-.21.93-.31l2.59-.83,3.62-1.14,3.62-1.14,3.62-1.14,3.62-1.14,1.66-.52c.62-.21,1.24-.52,1.86-.83,1.35-.52,2.48-1.24,3.62-2.17,1.35-1.04,2.59-2.28,3.62-3.73,2.07-2.9,3.21-6.52,3.21-10.25v-58.48l.31-.1,3.62-1.14.21-.1,3.31-1.04,1.97-.62,1.66-.52,3.62-1.14h.1l3.52-1.14,1.76-.52,1.86-.62,3.42-1.14.21-.1,1.14-.41v67.07c0,2.48-.21,5.07-.62,7.45-.21.93-.31,1.76-.52,2.69-.83,3.52-1.97,6.83-3.62,9.94-1.04,2.07-2.28,4.04-3.62,6-1.14,1.55-2.28,3-3.62,4.45-1.14,1.24-2.38,2.38-3.62,3.42-1.14,1.04-2.38,1.86-3.62,2.79-1.14.83-2.38,1.55-3.62,2.28-1.14.62-2.38,1.24-3.62,1.76-.1,0-.21.1-.31.21-1.04.41-2.17.83-3.21,1.24-.31.1-.62.21-.93.31l-2.69.83-7.25,2.28-3.62,1.14-3.62,1.14-1.66.52c-.62.21-1.24.41-1.86.52-1.24.31-2.38.62-3.62.83-1.24.21-2.38.41-3.62.41-1.14.1-2.17.1-3.21.1h-.31c-1.24,0-2.38-.1-3.62-.21-1.24-.1-2.38-.31-3.62-.52s-2.38-.52-3.62-.93c-.72-.21-1.35-.41-2.07-.62-.52-.21-1.04-.41-1.55-.62-1.24-.52-2.38-1.04-3.62-1.66s-2.48-1.35-3.62-2.17c-.52-.31-1.04-.72-1.55-1.04-.72-.52-1.35-1.04-2.07-1.66-1.24-1.04-2.48-2.17-3.62-3.42-1.35-1.35-2.59-2.9-3.62-4.45-1.45-1.97-2.59-4.04-3.62-6.21-2.38-5.18-3.62-10.87-3.62-16.77v-82.39c0-6.62,1.24-13.04,3.62-18.94.52-1.35,1.04-2.59,1.66-3.83s1.24-2.38,1.86-3.52c.41-.83.93-1.55,1.45-2.28.62-.93,1.24-1.86,1.97-2.69,0-.1.1-.21.21-.21,1.14-1.45,2.28-2.79,3.62-4.14.52-.52.93-1.04,1.55-1.45.72-.72,1.35-1.24,2.07-1.86,1.04-.83,2.07-1.76,3.21-2.48.1-.1.31-.21.41-.31,1.14-.83,2.38-1.66,3.62-2.28.41-.21.83-.52,1.35-.72.72-.41,1.55-.83,2.28-1.24.1-.1.21-.1.41-.21.83-.41,1.76-.83,2.59-1.14.21-.1.41-.21.62-.21,1.04-.41,2.17-.83,3.21-1.14l.31-.1,1.04-.31,2.59-.83,2.79-.93.83-.31,3.62-1.14.83-.31,2.79-.83.62-.21,1.97-.62,1.04-.31,3.62-1.14.62-.21,2.9-.93,2.38-.72,1.24-.41,3.62-1.14.41-.1,2.69-.83.52-.1,2.17-.72,1.45-.41,3.62-1.14.21-.1,3.31-1.04,1.97-.62,1.66-.52,3.62-1.14h.1l3.52-1.14,1.76-.52,1.86-.62,2.17-.72h0l.52-.1,2.17-.72,1.45-.52,3.62-1.14.21-.1,3.31-1.04,1.97-.62,1.04-.41Z"})]}),(0,V.jsx)("path",{fill:"#000000",d:"m433.57,86.41c18.92,0,34.54,6.21,46.87,18.62,12.32,12.41,18.49,28.16,18.49,47.26s-6.16,34.85-18.49,47.26c-12.33,12.41-27.95,18.62-46.87,18.62h-35.41v50.51h-42.18V86.41h77.59Zm-6.51,97.38c8.5,0,15.49-2.95,20.96-8.85,5.47-5.9,8.2-13.45,8.2-22.65s-2.73-16.75-8.2-22.65c-5.47-5.9-12.46-8.85-20.96-8.85h-28.9v63.01h28.9Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m568.18,272.05c-18.23,0-32.63-6.16-43.22-18.49-10.59-12.32-15.88-28.21-15.88-47.65s5.47-34.89,16.4-47.39c10.94-12.5,25.34-18.75,43.22-18.75,8.85,0,16.75,1.91,23.69,5.73,6.94,3.82,12.15,9.03,15.62,15.62v-17.96h39.58v125.5h-39.58v-17.7c-3.47,6.25-8.81,11.33-16.01,15.23-7.2,3.91-15.15,5.86-23.82,5.86Zm11.46-33.07c9.54,0,16.92-3.12,22.13-9.37,5.21-6.25,7.81-14.15,7.81-23.69s-2.6-17.18-7.81-23.43c-5.21-6.25-12.59-9.37-22.13-9.37-9.03,0-16.27,3.04-21.74,9.11-5.47,6.08-8.2,13.97-8.2,23.69s2.73,17.66,8.2,23.82c5.47,6.16,12.71,9.24,21.74,9.24Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m765.53,143.17h39.84v121.59c0,19.44-5.99,34.54-17.97,45.3-11.29,9.72-26.65,14.58-46.08,14.58s-35.76-4.34-46.34-13.02c-10.24-8.68-15.45-19.7-15.62-33.07h40.1c.87,11.28,8.16,16.92,21.87,16.92,16.14,0,24.21-9.37,24.21-28.12v-19.53c-7.29,13.89-20.57,20.83-39.84,20.83-15.45,0-27.04-4.69-34.76-14.06-7.73-9.37-11.59-22.22-11.59-38.53v-72.9h39.83v66.91c0,18.05,7.38,27.08,22.13,27.08,7.81,0,13.8-2.82,17.97-8.46,4.17-5.64,6.25-13.41,6.25-23.3v-62.23Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m839.47,268.66V86.41h111.44v35.41h-69.26v49.21h69.26v34.63h-69.26v63.01h-42.18Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m1090.07,253.82c-12.59,12.5-29.47,18.75-50.64,18.75s-38.1-6.25-50.77-18.75c-12.67-12.5-19.01-28.47-19.01-47.91s6.33-35.36,19.01-47.78c12.67-12.41,29.59-18.62,50.77-18.62s38.05,6.21,50.64,18.62c12.58,12.41,18.88,28.34,18.88,47.78s-6.29,35.41-18.88,47.91Zm-50.64-15.1c9.2,0,16.49-3.03,21.87-9.11,5.38-6.07,8.07-13.97,8.07-23.69s-2.69-17.61-8.07-23.69c-5.38-6.07-12.67-9.11-21.87-9.11s-16.71,3.04-22,9.11c-5.3,6.08-7.94,13.97-7.94,23.69s2.64,17.62,7.94,23.69c5.29,6.08,12.63,9.11,22,9.11Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m1131.86,268.66v-125.5h39.84v18.23c7.46-14.41,21-21.61,40.62-21.61,30.55,0,45.82,17.1,45.82,51.29v77.59h-40.1v-64.57c0-10.76-1.69-18.57-5.08-23.43-3.39-4.86-9.07-7.29-17.05-7.29-16.14,0-24.21,9.89-24.21,29.68v65.61h-39.84Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m1353.43,237.68c5.55,0,10.15-.26,13.8-.78v31.76c-7.64,1.39-16.49,2.08-26.56,2.08-4.52,0-8.51-.26-11.98-.78-3.47-.52-7.38-1.69-11.72-3.52-4.34-1.82-7.9-4.3-10.68-7.42-2.78-3.13-5.17-7.64-7.16-13.54-2-5.9-2.99-12.84-2.99-20.83v-49.99h-19.79v-31.5h19.79v-37.23h39.84v37.23h28.38v31.5h-28.38v41.66c0,8.51,1.47,14.19,4.43,17.05,2.95,2.86,7.29,4.3,13.02,4.3Z"}),(0,V.jsx)("path",{fill:"#000000",d:"m1513.55,199.4c0,5.21-.35,11.02-1.04,17.44h-92.69c.35,8.16,3.12,14.49,8.33,19.01,5.21,4.52,12.24,6.77,21.09,6.77,12.15,0,19.96-3.91,23.43-11.72h39.05c-1.91,12.33-8.64,22.35-20.18,30.07-11.55,7.72-25.65,11.59-42.31,11.59-21.35,0-38.19-5.9-50.51-17.7-12.33-11.8-18.49-28.12-18.49-48.95s6.16-36.67,18.49-48.56c12.32-11.89,28.73-17.83,49.21-17.83s35.23,5.56,47.39,16.66c12.15,11.11,18.23,25.52,18.23,43.22Zm-93.73-7.29h54.42c-.18-8.33-2.52-14.75-7.03-19.27-4.52-4.51-11.02-6.77-19.53-6.77s-15.23,2.39-20.18,7.16c-4.95,4.78-7.51,11.07-7.68,18.88Z"})]});var Ye=require("react/jsx-runtime"),yr=()=>(0,Ye.jsxs)("svg",{width:"100%",height:"32",viewBox:"0 0 20 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"pl-5",children:[(0,Ye.jsx)("path",{d:"M19.686 5.71949V15.1448L19.6467 15.8434V15.8548V15.8663C19.5779 16.5076 19.4207 17.1146 19.1848 17.6758C19.0472 18.0079 18.8801 18.3286 18.6836 18.6149C18.5361 18.8439 18.3592 19.0615 18.1823 19.2677C18.025 19.4394 17.858 19.6112 17.6811 19.7601C17.5238 19.8975 17.3567 20.0235 17.1798 20.138C17.0127 20.2411 16.8456 20.3327 16.6786 20.4243C16.5606 20.4816 16.4427 20.5274 16.3149 20.5732L16.1773 20.6305L15.6761 20.8252L15.1748 21.0199L14.6736 21.2146L14.1723 21.4093L13.1698 21.7986L13.1207 21.8215V23.9402L13.0814 23.9517L12.7374 24.0777L12.6587 24.1006L12.3934 24.2036L12.1575 24.2953L12.0494 24.3296L11.7054 24.4556L11.6464 24.4785L11.3614 24.5816L11.1452 24.6617L11.0174 24.7075L10.6734 24.8335L10.6341 24.845L10.5849 24.8679H10.5653V20.745C10.5653 20.5732 10.5948 20.4129 10.6341 20.2526C10.6439 20.2182 10.6537 20.1838 10.6734 20.1495C10.752 19.9433 10.87 19.7601 11.0174 19.6112C11.0567 19.5769 11.096 19.5311 11.1452 19.4967C11.214 19.4394 11.2828 19.4051 11.3614 19.3593C11.381 19.3478 11.4105 19.3364 11.4302 19.3249L11.4498 19.3135L11.6562 19.2333L11.7152 19.2104L12.0592 19.0844L12.1673 19.0386L12.6686 18.8439L12.7472 18.8096L13.0912 18.6836L13.1796 18.6492L13.6809 18.4545L14.1821 18.2598L14.6834 18.0652L15.1846 17.8705L15.5483 17.733C15.5974 17.7216 15.6367 17.6987 15.6859 17.6758C15.8726 17.5956 16.0397 17.4811 16.1871 17.3551C16.3837 17.1948 16.5508 17.0001 16.6884 16.7825C16.9931 16.3244 17.17 15.7403 17.17 15.1333V5.71949C17.17 5.10106 17.0029 4.52844 16.6884 4.05889C16.5508 3.85275 16.3935 3.66951 16.2068 3.50917C16.197 3.49772 16.197 3.49772 16.1871 3.49772C16.0299 3.36029 15.8628 3.25722 15.6859 3.17705C15.5188 3.09689 15.3517 3.05108 15.1846 3.01672C15.0176 2.98236 14.8505 2.98236 14.6834 2.99382C14.5163 3.00527 14.3492 3.03963 14.1821 3.09689C14.1625 3.10834 14.133 3.10834 14.1133 3.11979L13.6809 3.28013L13.1796 3.46336L12.6784 3.65806L12.1378 3.82984L11.6366 4.02453L11.1353 4.20777L10.6341 4.40246L10.1328 4.5857L9.63159 4.76894L9.13034 4.96363L8.62909 5.14687L8.12784 5.3301L7.62659 5.52479L7.12534 5.70803L6.6241 5.90272L6.12285 6.08596L5.6216 6.28065L5.08103 6.46389L4.57979 6.65858L4.21614 6.79601C4.16699 6.81891 4.11785 6.83037 4.06871 6.85327C3.8918 6.93344 3.71489 7.04796 3.56746 7.17394C3.37089 7.33427 3.20381 7.52896 3.06621 7.74656C2.76153 8.2161 2.58462 8.78872 2.58462 9.40715V13.0948C2.58462 13.53 2.66325 13.8965 2.78119 14.2057C2.79102 14.2401 2.80085 14.263 2.8205 14.2973C2.81067 14.3088 2.79102 14.3088 2.78119 14.3202C2.70256 14.366 2.63376 14.4004 2.56496 14.4577C2.52565 14.4806 2.48634 14.5149 2.43719 14.5378C2.31925 14.618 2.20131 14.7096 2.0932 14.8012C2.08337 14.8127 2.06371 14.8241 2.05389 14.8356C1.94577 14.9272 1.84749 15.0188 1.74921 15.1104C1.68041 15.1792 1.61161 15.2479 1.55264 15.328C1.5035 15.3853 1.45435 15.4311 1.40521 15.4884C1.28727 15.6373 1.16933 15.7861 1.06122 15.9465C1.05139 15.9579 1.05139 15.9694 1.04156 15.9808C0.972761 16.0839 0.913791 16.1755 0.85482 16.2786C0.805678 16.1984 0.756536 16.1068 0.717223 16.0266C0.648424 15.9007 0.589453 15.7747 0.540311 15.6373C0.481341 15.4998 0.432199 15.3509 0.383057 15.2135C0.157004 14.5493 0.0390625 13.8392 0.0390625 13.1177V9.3957C0.0390625 8.50241 0.215974 7.63203 0.540311 6.87618C0.677909 6.54406 0.844992 6.22339 1.04156 5.93708C1.18899 5.70803 1.3659 5.49044 1.54281 5.28429C1.70006 5.11251 1.86715 4.94072 2.04406 4.79184C2.20131 4.65441 2.3684 4.52844 2.54531 4.41391C2.70256 4.31084 2.86964 4.21922 3.04656 4.1276C3.17432 4.07034 3.29227 4.01308 3.42003 3.96727L3.5478 3.92146L4.04905 3.73822L4.5503 3.54353L5.05155 3.36029L5.5528 3.1656L6.05405 2.98236L6.5553 2.78767L7.05654 2.60444L7.55779 2.40974L8.10818 2.22651L8.60943 2.03182L9.11068 1.84858L9.61193 1.66534L10.1132 1.47065L10.6144 1.28741L11.1157 1.09272L11.6169 0.909482L12.1182 0.714792L12.6194 0.531554L13.1207 0.336863L13.2878 0.279601C13.3959 0.233791 13.5138 0.199434 13.6317 0.165077C13.7988 0.119268 13.9659 0.073458 14.133 0.0505533C14.3001 0.0276485 14.4672 0.00474375 14.6342 0.00474375C14.8013 -0.00670864 14.9684 0.00474368 15.1355 0.0161961C15.3026 0.0276485 15.4697 0.0505533 15.6367 0.0849104C15.8038 0.119268 15.9709 0.165077 16.138 0.222339C16.3051 0.279601 16.482 0.348315 16.6392 0.428482C16.8063 0.508649 16.9832 0.61172 17.1405 0.714792C17.3174 0.829315 17.4845 0.955292 17.6417 1.09272C17.6417 1.09272 17.6417 1.09272 17.6516 1.09272C17.8285 1.2416 17.9956 1.40193 18.1528 1.58517C18.3396 1.77986 18.5066 1.99746 18.6541 2.22651C18.8506 2.52427 19.0177 2.83348 19.1553 3.1656C19.5091 3.95582 19.686 4.81475 19.686 5.71949Z",fill:"#0231C5"}),(0,Ye.jsx)("path",{d:"M10.8112 9.92822V13.0846L10.7425 13.1079L10.5557 13.1778L10.2412 13.2943L10.2215 13.3059L9.87755 13.434L9.73995 13.4923L9.53356 13.5738L9.48441 13.5855L9.27802 13.667L9.10111 13.7369L8.93402 13.7951L8.59986 13.9232H8.59003L8.24604 14.0514L8.08878 14.1096L7.90204 14.1795L7.58753 14.2959L7.56787 14.3076L7.22388 14.4357L7.08628 14.4939L6.87989 14.5755L6.83074 14.5871L6.57521 14.6803L6.53589 14.692L6.1919 14.8201L6.07396 14.8667L5.8479 14.9482L5.57271 15.053L5.51374 15.0763L5.16974 15.2044L5.07146 15.2394L4.88472 15.3093L4.82575 15.3326L4.56038 15.4374L4.48175 15.4723L4.19673 15.5771C4.17707 15.5888 4.15742 15.5888 4.13776 15.6004C4.10827 15.6121 4.07879 15.6237 4.05913 15.6354C3.97068 15.682 3.88222 15.7286 3.79377 15.7868C3.71514 15.8334 3.62668 15.8916 3.54806 15.9615C3.51857 15.9848 3.47926 16.0197 3.44977 16.0547C3.322 16.1712 3.21389 16.2993 3.10578 16.4507C3.08612 16.474 3.06646 16.5089 3.04681 16.5439C2.93869 16.7186 2.84041 16.9049 2.76178 17.1146C2.63401 17.464 2.56521 17.8367 2.56521 18.2327V27.5039C2.56521 27.7951 2.63401 28.0747 2.76178 28.3076C2.84041 28.459 2.95835 28.5988 3.08612 28.7153C3.09595 28.7269 3.09595 28.7269 3.10578 28.7269C3.21389 28.8201 3.322 28.89 3.44977 28.9249C3.55788 28.9715 3.67582 28.9948 3.79377 28.9948C3.90188 28.9948 4.01982 28.9831 4.13776 28.9482C4.16725 28.9366 4.19673 28.9249 4.22622 28.9133L4.47193 28.8201L4.81592 28.692L5.15991 28.5638L5.50391 28.4357L5.8479 28.3076L6.00516 28.2494C6.06413 28.2261 6.1231 28.1911 6.18207 28.1562C6.30984 28.098 6.41795 28.0164 6.52606 27.9116C6.65383 27.7951 6.77177 27.6554 6.87006 27.4923C7.06663 27.1662 7.17474 26.7585 7.17474 26.3392V19.7585L7.20422 19.7469L7.54822 19.6187L7.56787 19.6071L7.88238 19.4906L8.06912 19.4207L8.22638 19.3625L8.57037 19.2344H8.5802L8.91437 19.1063L9.08145 19.048L9.25836 18.9781L9.5827 18.85L9.60236 18.8384L9.71047 18.7918V26.3392C9.71047 26.6188 9.69081 26.9099 9.6515 27.1778C9.63184 27.2826 9.62201 27.3758 9.60236 27.4806C9.52373 27.8767 9.41562 28.2494 9.25836 28.5988C9.16008 28.8317 9.04214 29.053 8.91437 29.2743C8.80625 29.449 8.69814 29.6121 8.57037 29.7752C8.46226 29.9149 8.34432 30.043 8.22638 30.1595C8.11827 30.276 8.00032 30.3692 7.88238 30.474C7.77427 30.5672 7.65633 30.6487 7.53839 30.7302C7.43028 30.8001 7.31234 30.87 7.19439 30.9282C7.18457 30.9282 7.17474 30.9399 7.16491 30.9515C7.06663 30.9981 6.95851 31.0447 6.86023 31.0913C6.83074 31.1029 6.80126 31.1146 6.77177 31.1262L6.51624 31.2194L5.82825 31.4757L5.48425 31.6038L5.14026 31.7319L4.983 31.7901C4.92403 31.8134 4.86506 31.8367 4.80609 31.8484C4.68815 31.8833 4.58004 31.9183 4.4621 31.9415C4.34416 31.9648 4.23604 31.9881 4.1181 31.9881C4.00999 31.9998 3.91171 31.9998 3.81342 31.9998H3.78394C3.666 31.9998 3.55788 31.9881 3.43994 31.9765C3.322 31.9648 3.21389 31.9415 3.09595 31.9183C2.97801 31.895 2.8699 31.86 2.75195 31.8134C2.68316 31.7901 2.62419 31.7668 2.55539 31.7435C2.50624 31.7203 2.4571 31.697 2.40796 31.6737C2.29002 31.6154 2.18191 31.5572 2.06397 31.4873C1.94602 31.4174 1.82808 31.3359 1.71997 31.2427C1.67083 31.2078 1.62169 31.1612 1.57255 31.1262C1.50375 31.068 1.44478 31.0098 1.37598 30.9399C1.25804 30.8234 1.1401 30.6953 1.03198 30.5555C0.904214 30.4041 0.786273 30.2294 0.687989 30.0547C0.550391 29.8334 0.442278 29.6004 0.343994 29.3559C0.117941 28.7735 0 28.1329 0 27.469V18.1978C0 17.4524 0.117941 16.7302 0.343994 16.0663C0.393136 15.9149 0.442278 15.7751 0.501249 15.6354C0.560219 15.4956 0.61919 15.3675 0.67816 15.2394C0.717474 15.1462 0.766616 15.0647 0.815758 14.9831C0.874728 14.8783 0.933699 14.7735 1.0025 14.6803C1.0025 14.6687 1.01233 14.657 1.02215 14.657C1.13027 14.494 1.23838 14.3425 1.36615 14.1911C1.41529 14.1329 1.4546 14.0746 1.51358 14.0281C1.58237 13.9465 1.64134 13.8883 1.71014 13.8184C1.80843 13.7252 1.90671 13.6204 2.01482 13.5389C2.02465 13.5272 2.04431 13.5156 2.05414 13.5039C2.16225 13.4108 2.28019 13.3176 2.39813 13.2477C2.43745 13.2244 2.47676 13.1895 2.5259 13.1662C2.5947 13.1196 2.67333 13.073 2.74213 13.0264C2.75195 13.0147 2.76178 13.0147 2.78144 13.0031C2.86007 12.9565 2.94852 12.9099 3.02715 12.875C3.04681 12.8633 3.06646 12.8517 3.08612 12.8517C3.1844 12.8051 3.29252 12.7585 3.3908 12.7236L3.42029 12.7119L3.51857 12.677L3.76428 12.5838L4.02965 12.479L4.10828 12.444L4.45227 12.3159L4.5309 12.281L4.79626 12.1878L4.85523 12.1645L5.04197 12.0946L5.14026 12.0597L5.48425 11.9316L5.54322 11.9083L5.81842 11.8034L6.04447 11.7219L6.16241 11.6753L6.50641 11.5472L6.54572 11.5355L6.80126 11.4424L6.8504 11.4307L7.0568 11.3492L7.19439 11.3026L7.53839 11.1745L7.55805 11.1628L7.87256 11.0464L8.0593 10.9765L8.21655 10.9182L8.56054 10.7901H8.57037L8.90454 10.662L9.07162 10.6038L9.24853 10.5339L9.45493 10.4523L9.50407 10.4407L9.71047 10.3592L9.84807 10.3009L10.1921 10.1728L10.2117 10.1612L10.5262 10.0447L10.713 9.97481L10.8112 9.92822Z",fill:"#0231C5"})]});var ie=require("react/jsx-runtime"),vr=({onToggleSideBar:e,isSidebarCollapsed:t})=>(0,ie.jsx)("button",{onClick:()=>e(!t),className:"w-6 h-12 bg-[#EEF2FF] rounded-tr-md [clip-path:polygon(0%_0%,100%_0%,100%_60%,0%_100%,0%_100%)] mt-5 flex justify-center items-center",children:(0,ie.jsx)(sa,{className:"mb-3"})}),sa=e=>(0,ie.jsxs)("svg",{width:"20",height:"15",viewBox:"0 0 20 20",fill:"none",color:"currentColor",xmlns:"http://www.w3.org/2000/svg",...e,children:[(0,ie.jsx)("path",{d:"M4.52669 6.50008C4.25055 6.50008 4.02669 6.72394 4.02669 7.00008C4.02669 7.27622 4.25055 7.50008 4.52669 7.50008H5.48958C5.76573 7.50008 5.98958 7.27622 5.98958 7.00008C5.98958 6.72394 5.76573 6.50008 5.48958 6.50008H4.52669Z",fill:"#878989"}),(0,ie.jsx)("path",{d:"M4.02669 8.66675C4.02669 8.39061 4.25055 8.16675 4.52669 8.16675H5.48958C5.76573 8.16675 5.98958 8.39061 5.98958 8.66675C5.98958 8.94289 5.76573 9.16675 5.48958 9.16675H4.52669C4.25055 9.16675 4.02669 8.94289 4.02669 8.66675Z",fill:"#878989"}),(0,ie.jsx)("path",{d:"M4.52669 9.83342C4.25055 9.83342 4.02669 10.0573 4.02669 10.3334C4.02669 10.6096 4.25055 10.8334 4.52669 10.8334H5.48958C5.76573 10.8334 5.98958 10.6096 5.98958 10.3334C5.98958 10.0573 5.76573 9.83342 5.48958 9.83342H4.52669Z",fill:"#878989"}),(0,ie.jsx)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M2.68166 5.07676C2.5 5.43328 2.5 5.89999 2.5 6.83341V13.1667C2.5 14.1002 2.5 14.5669 2.68166 14.9234C2.84144 15.237 3.09641 15.492 3.41002 15.6518C3.76654 15.8334 4.23325 15.8334 5.16667 15.8334H14.8333C15.7668 15.8334 16.2335 15.8334 16.59 15.6518C16.9036 15.492 17.1586 15.237 17.3183 14.9234C17.5 14.5669 17.5 14.1002 17.5 13.1667V6.83341C17.5 5.89999 17.5 5.43328 17.3183 5.07676C17.1586 4.76316 16.9036 4.50819 16.59 4.3484C16.2335 4.16675 15.7668 4.16675 14.8333 4.16675H5.16667C4.23325 4.16675 3.76654 4.16675 3.41002 4.3484C3.09641 4.50819 2.84144 4.76316 2.68166 5.07676ZM14.8333 5.16675H7.66667L7.66667 14.8334H14.8333C15.3165 14.8334 15.6188 14.8326 15.8466 14.814C16.0626 14.7964 16.1222 14.7678 16.136 14.7608C16.2614 14.6968 16.3634 14.5949 16.4273 14.4694C16.4344 14.4556 16.463 14.3961 16.4806 14.18C16.4992 13.9522 16.5 13.65 16.5 13.1667V6.83341C16.5 6.3502 16.4992 6.04794 16.4806 5.82018C16.463 5.6041 16.4344 5.54455 16.4273 5.53075C16.3634 5.40531 16.2614 5.30333 16.136 5.23941C16.1222 5.23238 16.0626 5.20379 15.8466 5.18613C15.6188 5.16753 15.3165 5.16675 14.8333 5.16675ZM5.16667 5.16675H6.66667L6.66667 14.8334H5.16667C4.68346 14.8334 4.38119 14.8326 4.15344 14.814C3.93736 14.7964 3.8778 14.7678 3.86401 14.7608C3.73856 14.6968 3.63658 14.5949 3.57266 14.4694C3.56564 14.4556 3.53704 14.3961 3.51939 14.18C3.50078 13.9522 3.5 13.65 3.5 13.1667V6.83341C3.5 6.3502 3.50078 6.04794 3.51939 5.82018C3.53704 5.6041 3.56563 5.54455 3.57266 5.53075C3.63658 5.40531 3.73856 5.30333 3.86401 5.23941C3.8778 5.23238 3.93736 5.20379 4.15344 5.18613C4.38119 5.16753 4.68346 5.16675 5.16667 5.16675Z",fill:"#878989"})]});var T=require("react/jsx-runtime"),xr=({isSidebarCollapsed:e,onToggleSideBar:t,isMobile:o,links:r,businessProps:n,currentPath:i,onNavigate:l,appConfig:s,collapseType:d,onLogoutClick:c,openSidebarIcon:p=(0,T.jsx)(hr,{}),closedSidebarIcon:u=(0,T.jsx)(yr,{}),nodeAfterSideBarLogo:m})=>{let g=(0,ye.useMemo)(()=>o?"hidden":d||(o?"hidden":"icons"),[o,d]),[f,v]=(0,ye.useState)(!1),N=g==="icons"&&e,y=(0,ye.useRef)(null),{businessList:G,activeBusiness:ve,toggleAddBusinessDrawer:I,handleSetActiveBusiness:Le}=n,$t=wt=>v(wt),Sr=wt=>{Le?.(wt),$t(!1)},Fr=(0,ye.useMemo)(()=>g==="hidden"?p:e?u:p,[e,p,u,g]),Ut=o&&g==="hidden"&&e;return(0,T.jsxs)(T.Fragment,{children:[Ut&&(0,T.jsx)("div",{className:"fixed inset-0 z-40 bg-black bg-opacity-40 transition-all animate-in fade-in-15",onClick:()=>t(!1)}),(0,T.jsxs)("div",{className:a("relative flex flex-row-reverse h-full",{"fixed inset-0 z-50 pointer-events-none":Ut}),children:[g==="icons"&&(0,T.jsx)(vr,{isSidebarCollapsed:e,onToggleSideBar:t}),(0,T.jsxs)("aside",{id:"sidebar_menu",ref:y,className:a("relative pt-4 h-full max-h-screen bg-[#FBFBFB] overflow-hidden flex-col flex transition-all duration-300 w-64 gap-y-14",{"!fixed":g==="hidden","w-[311px]":e&&g!=="icons","w-[75px]":e&&g==="icons","w-[270px]":!e&&g==="icons","w-0 lg:w-0 pointer-events-none":!e&&g==="hidden","pointer-events-auto":e&&g==="hidden","left-0 top-0":o&&g==="hidden","-translate-x-full":!e&&o&&g!=="hidden","translate-x-0":e&&o&&g==="hidden"}),children:[(0,T.jsxs)("div",{className:a("flex items-center py-2 justify-center w-full",{"justify-between px-2":o}),children:[(0,T.jsx)("section",{className:a({"ml-2":o,"-ml-16":!e}),children:Fr}),g==="hidden"&&(0,T.jsx)("div",{onClick:()=>t(!1),className:"flex items-center gap-2 text-3xl cursor-pointer",children:(0,T.jsx)(br.X,{size:24,className:"text-black hover:opacity-60"})})]}),m,(0,T.jsx)("div",{className:"flex-1 overflow-y-auto px-0 h-full max-h-[calc(100vh-200px)]",children:(0,T.jsx)(Cr,{isIconsOnly:N,collapseType:g,currentPath:i,isSidebarCollapsed:e,links:r,onNavigate:l,onToggleSideBar:t,appConfig:s,isMobile:o})}),(0,T.jsx)("div",{className:"absolute bottom-5 w-full",children:(0,T.jsx)(fr,{activeBusiness:ve,handleSwitchBusiness:Sr,isBusinessShown:f,toggleAddBusinessDrawer:I,toggleShowBusiness:$t,businesses:G||[],iconOnly:g==="icons"?e:!1,onLogoutClick:c,isMobile:o,onToggleSideBar:t,collapseType:g})})]})]})]})};var ft=require("react/jsx-runtime"),wr=({status:e,variant:t,className:o})=>(0,ft.jsx)("div",{children:(0,ft.jsx)("div",{className:a("order-first max-w-max flex-none rounded-full px-2 py-1 text-xs font-medium ring-1 ring-inset ring-current sm:order-none text-[14px] capitalize",{"bg-green-500/20 text-green-500":t==="success"},{"bg-gray-500/20 text-white":t==="abandoned"},{"bg-red-500/20 text-red-500":t==="failed"},{"bg-yellow-500/20 text-yellow-500":t==="pending"},o),children:(0,ft.jsx)("p",{children:e.replace("-"," ")})})});var Lr=require("lucide-react");var Ct=require("lucide-react");var gt=require("react/jsx-runtime"),la=({page:e,currentPage:t,onClick:o})=>typeof e=="string"?(0,gt.jsx)("span",{className:"px-3 py-1 sm:px-4 sm:py-2 text-xs sm:text-sm font-semibold text-gray-500",children:e}):(0,gt.jsx)("button",{onClick:o,className:`p-1 w-8 h-8 text-xs sm:text-sm rounded-full ${e===t?"bg-primary-main text-white":"text-[#717171] hover:bg-primary-main/10"}`,children:e}),Nr=({totalPages:e,currentPage:t,handlePageClick:o})=>{let n=()=>{let d=Math.floor(1.5),c=Math.max(1,t-d),p=Math.min(e,c+3-1);return p>e&&(c=Math.max(1,e-3+1),p=e),{start:c,end:p}},{start:i,end:l}=n(),s=[];return i>1&&s.push(1),i>2&&s.push("..."),s.push(...Array.from({length:l-i+1},(d,c)=>i+c)),l<e-1&&s.push("..."),l<e&&s.push(e),s.map((d,c)=>(0,gt.jsx)(la,{page:d,currentPage:t,onClick:typeof d=="number"?()=>o(d):void 0},c))};var Q=require("react/jsx-runtime"),ht=({currentPage:e=1,totalPages:t=1,onPageChange:o,itemsPerPage:r=0,totalItems:n=0})=>{let i=d=>{d>=1&&d<=t&&o?.(d)},l=r===0?1:r*(e-1)+1,s=e===t?n:Math.min(l+r-1,n);return(0,Q.jsxs)("div",{className:"flex items-center justify-between border-t border-gray-200 px-4 py-3 sm:px-6 w-full flex-wrap gap-y-10 sm:gap-y-0",children:[n&&(0,Q.jsx)("section",{className:"text-[#717171] text-[12px]",children:(0,Q.jsxs)("p",{className:"",children:["Showing ",l," - ",s," of ",n]})}),(0,Q.jsx)("div",{className:"flex items-center justify-center sm:justify-end ",children:(0,Q.jsxs)("nav",{className:" inline-flex gap-x-1 sm:gap-x-[10px] items-center",children:[(0,Q.jsx)("button",{onClick:()=>i(e-1),disabled:e===1,className:"text-xs text-[#222222] hover:bg-primary-main/10 disabled:text-[#D9D9D9] disabled:cursor-not-allowed sm:flex hidden",children:(0,Q.jsx)(Ct.ChevronLeftIcon,{className:"size-5"})}),Nr({currentPage:e,totalPages:t,handlePageClick:i}),(0,Q.jsx)("button",{onClick:()=>i(e+1),disabled:e===t,className:"text-xs text-[#222222] hover:bg-primary-main/10 disabled:text-[#D9D9D9] disabled:cursor-not-allowed sm:flex hidden",children:(0,Q.jsx)(Ct.ChevronRightIcon,{className:"size-5"})})]})})]})};var Gt=require("@tanstack/react-table");var Z=require("react/jsx-runtime"),Pr=({table:e,isMobile:t,onRowClick:o,id:r})=>(0,Z.jsx)("div",{className:a("relative w-full rounded-b border-0",{}),children:(0,Z.jsxs)("table",{id:r??"table",className:"w-full overflow-x-scroll",children:[(0,Z.jsx)("thead",{children:e.getHeaderGroups().map(n=>(0,Z.jsx)("tr",{className:a(" rounded text-[#717171] border-b- bg-[#FCFCFC]",{}),children:n.headers.map(i=>(0,Z.jsx)("th",{className:"relative py-3 text-base whitespace-nowrap pl-2.5 text-left font-normal capitalize",colSpan:i.colSpan,style:{width:i.getSize()},children:i.isPlaceholder?null:(0,Z.jsx)("div",{className:a("flex items-center",{"cursor-pointer select-none":i.column.getCanSort()}),onClick:i.column.getToggleSortingHandler(),children:i.isPlaceholder?null:(0,Gt.flexRender)(i.column.columnDef.header,i.getContext())})},i.id))},n.id))}),(0,Z.jsx)("tbody",{className:" pl-2.5",children:e?.getFilteredRowModel().rows.map(n=>(0,Z.jsx)("tr",{className:a("first-letter border-b border-zinc-100",{"hover:bg-gray-50":!t},{"hover:bg-gray-50 hover:cursor-pointer":o}),onClick:()=>o?o(n):{},children:n.getVisibleCells().map(i=>(0,Z.jsx)("td",{className:a("",{}),children:(0,Z.jsx)("div",{className:a("",{"w-max p-4 pl-2.5 text-black text-sm":!0}),children:(0,Gt.flexRender)(i.column.columnDef.cell,i.getContext())})},i.id))},n.id))})]})});var we=require("lucide-react");var R=require("react/jsx-runtime"),yt=({onRefetch:e,search:t,FilterMenu:o,ExtraNode:r,onExport:n,download:i,isRefetching:l})=>{let s=c=>{t?.onSearch?.(c)},d=()=>{try{e?.()}catch(c){console.error("Error while refetching data",c)}};return(0,R.jsx)(R.Fragment,{children:(e||t?.enabled||o||r||n)&&(0,R.jsxs)("div",{className:"w-full flex flex-col sm:!flex-row justify-between items-start sm:items-center bg-white p-2 gap-2",children:[(0,R.jsx)("div",{className:"flex flex-1 flex-col sm:flex-row items-center gap-2 justify-start",children:(0,R.jsxs)("div",{className:" w-full flex gap-x-3",children:[t?.enabled&&(0,R.jsx)("section",{className:"sm:w-56",children:(0,R.jsx)(st,{type:"text",placeholder:"Enter search here...",className:"h-9",onChange:s,debounce:t?.debounceRate})}),(0,R.jsxs)("div",{className:" flex gap-2",children:[e&&(0,R.jsx)(fe,{onClick:d,title:"Refetch Data",disabled:l,variant:"outlined",className:"!border-[#DEDEDE] !text-gray-800 !px-[10px] !py-[8px] ",size:"sm",children:(0,R.jsx)(we.RotateCw,{className:a("w-4 h-4",{"animate-spin":l}),size:5})}),o&&(0,R.jsx)(Ce,{trigger:(0,R.jsx)("button",{title:"Filter",className:a("!border-[#DEDEDE] !text-gray-800 !px-[10px] !py-[8px]",Se({variant:"outlined",size:"sm"})),children:(0,R.jsx)(we.ListFilter,{className:"w-4 h-4",size:5})}),children:o})]})]})}),(0,R.jsx)("div",{className:"flex items-start flex-col gap-2 justify-center",children:(0,R.jsx)("section",{className:"flex flex-col-reverse sm:flex-row gap-2",children:(0,R.jsxs)("div",{className:"flex gap-2",children:[r&&r,n&&(0,R.jsx)(fe,{variant:"primary",onClick:n,size:"sm",children:"Export"}),i?.enabled&&(0,R.jsx)(fe,{variant:"primary",leftNode:(0,R.jsx)(we.Download,{className:"w-4 h-5",size:5}),onClick:i?.onDownload,id:i.buttonId,size:"sm",children:i?.buttonText})]})})})]})})};var W=require("react/jsx-runtime"),Rr=({table:e,isMobile:t=!1,onRowClick:o,id:r,onRefetch:n,isRefetching:i,FilterMenu:l,ExtraNode:s,onExport:d,search:c={enabled:!1,debounceRate:700},download:p={enabled:!1,buttonId:"download_button",buttonText:"Export"},isLoading:u,pagination:m})=>(0,W.jsxs)("div",{className:a("relative w-full rounded-b border-0 overflow-x-auto"),children:[(0,W.jsx)(yt,{onRefetch:n,search:c,FilterMenu:l,ExtraNode:s,onExport:d,download:p,isRefetching:i}),(0,W.jsx)("main",{className:"w-full overflow-x-auto mt-5",children:u?(0,W.jsxs)("div",{className:"py-10 flex flex-col justify-center w-full items-center space-x-2",children:[(0,W.jsx)(Lr.Loader,{size:20,className:"animate-spin"}),(0,W.jsx)("p",{className:"mt-3 text-center text-gray-600 text-sm opacity-70 animate-pulse",children:"Loading..."})]}):e.getRowModel().rows.length<1?(0,W.jsx)("div",{className:"py-10 flex flex-col justify-center w-full items-center",children:(0,W.jsx)("p",{className:"text-center text-gray-600 text-sm opacity-70",children:"No data available"})}):(0,W.jsx)("div",{className:"flex flex-col gap-2",children:(0,W.jsx)(Pr,{table:e,isMobile:t,onRowClick:o,id:r})})}),!u&&m?.enabled&&e.getRowModel().rows.length>0&&(0,W.jsx)(ht,{...m,currentPage:m?.currentPage??1,totalPages:m?.totalPages??Math.ceil((m?.totalItems??0)/Math.max(m?.itemsPerPage??1,1))??1,onPageChange:g=>m?.onPageChange?.(g)})]});var vt=require("react"),Tr=require("react/jsx-runtime"),je=(0,vt.createContext)(void 0),Dr=({permissions:e,children:t})=>{let o=(0,vt.useMemo)(()=>e,[e]);return(0,Tr.jsx)(je.Provider,{value:o,children:t})};var Ne=require("react");var zt=()=>(0,Ne.useContext)(je),bt=e=>{let t=zt(),o=(0,Ne.useCallback)(n=>{if(!t||!n||t.some(p=>p.resource==="all"&&p.action==="administrator"))return!0;let{resource:l,action:s}=n,d=t.filter(p=>p.resource===l);return d.some(p=>p.action===s)?!0:s==="read"?d.some(p=>p.action==="write"):!1},[e]);return{hasPermission:(0,Ne.useMemo)(()=>o(e),[t,e]),validatePermission:o}};var Pe=require("react/jsx-runtime"),kr=({permission:e,children:t})=>{let{hasPermission:o}=bt(e||{});return e?(0,Pe.jsx)(Pe.Fragment,{children:o?t:null}):(0,Pe.jsx)(Pe.Fragment,{children:t})};var Zt={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$"},Je=class Je{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 Zt[t]||t}};Yt(Je,"formatAmountAndCurrency",(t,o,r)=>{let n=new Intl.NumberFormat(r?.locale||Je.getCurrencyLocaleMap(t),{maximumFractionDigits:3,style:"currency",currency:t,currencyDisplay:"symbol"}).format(r?.convertToMajorCurrency?Je.koboToNaira(Number(o)):Number(o)).replace(/^(\D+)/,"$1 ").replace("\u202F"," ").replace(/\s+/,""),i=Zt[t]||t;return n.replace(t,i)});var _t=Je;var xt=P(require("dayjs")),Kt=class{static getDateLibrary(){return(0,xt.default)()}static formatTimestampToDate(t,o){return xt.default.unix(t).format(o||"ddd, MMM, YYYY | HH:mm:ss")}static formatDateToTimestamp(t){return(0,xt.default)(t).unix()}};0&&(module.exports={AmountAction,Banner,Button,CopyableLabel,Country,CurrencySymbolMap,DateAction,DebouncedInput,DevBanner,Dialog,Drawer,DrawerClose,DrawerRoot,FlagComponent,FormLabel,HasResourcePermission,Input,Loader,LocaleSelector,OTPInput,PageDataToolbar,Pagination,PasswordInput,PermissionsContext,PermissionsProvider,PhoneInput,Popover,PopoverContent,PopoverRoot,PopoverTrigger,Select,Sidebar,Status,Table,Textarea,Tooltip,TooltipContent,TooltipProvider,TooltipRoot,TooltipTrigger,buttonVariants,cn,useHasPermission,usePermissions});
2
2
  //# sourceMappingURL=index.js.map