@tap-payments/os-micro-frontend-shared 0.1.472 → 0.1.475

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (202) hide show
  1. package/build/{chunk-26YGUUXY.js → chunk-3RB7SOD6.js} +1 -1
  2. package/build/{chunk-PAOJKU5D.js → chunk-4Q2P3FSI.js} +1 -1
  3. package/build/{chunk-7BZ3EITU.js → chunk-4V53CG4R.js} +1 -1
  4. package/build/{chunk-QIRLSWFA.js → chunk-5DNHU7PK.js} +1 -1
  5. package/build/{chunk-ZENVX7NO.js → chunk-5TZ7ULEI.js} +1 -1
  6. package/build/{chunk-IQD7WEXN.js → chunk-6L4MABJY.js} +1 -1
  7. package/build/{chunk-2JJSGK7T.js → chunk-6MDDTWPF.js} +1 -1
  8. package/build/{chunk-77UTB7YN.js → chunk-73XZ7PNL.js} +1 -1
  9. package/build/{chunk-BZPQ5ZFC.js → chunk-7DADB2HO.js} +1 -1
  10. package/build/{chunk-JAXERZJ3.js → chunk-APIJ4QLV.js} +1 -1
  11. package/build/{chunk-R43YILB3.js → chunk-ARP7EMGQ.js} +1 -1
  12. package/build/{chunk-B6Y77OY7.js → chunk-AZQFHZX2.js} +1 -1
  13. package/build/{chunk-5SRHIQCO.js → chunk-B2RQJXU4.js} +1 -1
  14. package/build/{chunk-7KR6YG54.js → chunk-BCCTNMMH.js} +1 -1
  15. package/build/{chunk-EIHUP5HB.js → chunk-BCRVZBC2.js} +1 -1
  16. package/build/{chunk-XQMAEJWD.js → chunk-CAOMTYOH.js} +1 -1
  17. package/build/{chunk-JLWZKJAL.js → chunk-CKKISQHJ.js} +2 -2
  18. package/build/{chunk-WDKFWEWI.js → chunk-COZF3FS7.js} +1 -1
  19. package/build/{chunk-EYL6U6ME.js → chunk-DHDB2BWN.js} +1 -1
  20. package/build/{chunk-5ATIK4B3.js → chunk-E2CLXIAM.js} +1 -1
  21. package/build/{chunk-OPS2H7Q5.js → chunk-ELLASN4E.js} +1 -1
  22. package/build/{chunk-OTX46VG3.js → chunk-EOMM6XCF.js} +1 -1
  23. package/build/{chunk-GVBVAEZP.js → chunk-F3V7FDUX.js} +1 -1
  24. package/build/chunk-FG2Z2C5R.js +1 -0
  25. package/build/{chunk-NQL2MIVA.js → chunk-FIOHVAAY.js} +1 -1
  26. package/build/{chunk-6PUXOAWY.js → chunk-FKHCHDZT.js} +1 -1
  27. package/build/{chunk-QC4O6BNP.js → chunk-G7YNX2UW.js} +1 -1
  28. package/build/{chunk-O3ZTYI26.js → chunk-GEGX54AG.js} +1 -1
  29. package/build/{chunk-KI7RBLTV.js → chunk-GH3KMMFT.js} +1 -1
  30. package/build/{chunk-MTYAUX2G.js → chunk-GKIGJ23N.js} +1 -1
  31. package/build/{chunk-J4YYI4VU.js → chunk-GS2X4BJY.js} +1 -1
  32. package/build/{chunk-DSZ3EA4L.js → chunk-ICOEWMSH.js} +1 -1
  33. package/build/{chunk-OFYB4SEK.js → chunk-IK52PLCA.js} +1 -1
  34. package/build/{chunk-3NIYEWF3.js → chunk-IKTHVN4T.js} +1 -1
  35. package/build/{chunk-IVWVU7DE.js → chunk-JDGPSV7G.js} +1 -1
  36. package/build/{chunk-NLW2POZA.js → chunk-KL2AZ2HL.js} +1 -1
  37. package/build/{chunk-URBKISJQ.js → chunk-KWX3JZJF.js} +1 -1
  38. package/build/{chunk-A25S3DYQ.js → chunk-KYBMM3GI.js} +1 -1
  39. package/build/{chunk-X7NZ32SR.js → chunk-L55ILJ72.js} +1 -1
  40. package/build/{chunk-EJYI3XZI.js → chunk-LSHA44HR.js} +1 -1
  41. package/build/{chunk-JE4VIAIA.js → chunk-M6WLN3OC.js} +1 -1
  42. package/build/{chunk-YNUHIAZP.js → chunk-M7EZXHXI.js} +1 -1
  43. package/build/chunk-MRFF7D7J.js +2 -0
  44. package/build/chunk-NK266ZWT.js +2 -0
  45. package/build/{chunk-3T2EOLSI.js → chunk-OAYY5RGV.js} +1 -1
  46. package/build/{chunk-SYWPSROW.js → chunk-OSJA6643.js} +1 -1
  47. package/build/{chunk-OXADOLDW.js → chunk-PN65X6R7.js} +1 -1
  48. package/build/{chunk-GSQWF6IJ.js → chunk-PVEIIX2J.js} +1 -1
  49. package/build/{chunk-BRKIJ4GN.js → chunk-QNXJUX7P.js} +1 -1
  50. package/build/{chunk-E3R6C6V5.js → chunk-QQNUNWEU.js} +1 -1
  51. package/build/{chunk-ECXZUB3Y.js → chunk-R3DYVCA4.js} +1 -1
  52. package/build/{chunk-W7TX7ZNP.js → chunk-REVY6BKK.js} +1 -1
  53. package/build/{chunk-BJJBLWBN.js → chunk-RHEH7EAE.js} +1 -1
  54. package/build/{chunk-3LLO5WTA.js → chunk-RLQYKZGG.js} +1 -1
  55. package/build/{chunk-D4OMLLKG.js → chunk-RP2UIZAV.js} +1 -1
  56. package/build/{chunk-YD3HDRHE.js → chunk-S6RFPF3E.js} +1 -1
  57. package/build/{chunk-7673FIZM.js → chunk-TDRIWSNP.js} +1 -1
  58. package/build/{chunk-OKQTYPM5.js → chunk-TF4KUC77.js} +1 -1
  59. package/build/{chunk-WTXA5NG3.js → chunk-TT7DYANM.js} +1 -1
  60. package/build/chunk-TZWXCSB4.js +1 -0
  61. package/build/{chunk-JQQJDM4E.js → chunk-UJX4TDKD.js} +1 -1
  62. package/build/{chunk-PNQKPYZL.js → chunk-V42VTMSG.js} +1 -1
  63. package/build/{chunk-H3WM2II4.js → chunk-V4SLRQPK.js} +1 -1
  64. package/build/{chunk-Y7PYIT57.js → chunk-VJWLLAT4.js} +1 -1
  65. package/build/{chunk-WQ6G6GA3.js → chunk-VR2CIW5E.js} +1 -1
  66. package/build/{chunk-GCUGZON2.js → chunk-W5YSBRNJ.js} +1 -1
  67. package/build/{chunk-YCTRDTXT.js → chunk-WI37VPEY.js} +1 -1
  68. package/build/chunk-WRMULCMZ.js +2 -0
  69. package/build/{chunk-GDNSLZ6T.js → chunk-XAWNPPH7.js} +1 -1
  70. package/build/chunk-XUSUPNMX.js +1 -0
  71. package/build/{chunk-RCNWJ5D2.js → chunk-XW7LUPFA.js} +1 -1
  72. package/build/{chunk-WPEMOXYM.js → chunk-Z4FHHHC4.js} +1 -1
  73. package/build/{chunk-VQ6MS7BN.js → chunk-ZQ6VMOQ7.js} +1 -1
  74. package/build/components/AccordionAdapter/index.js +1 -1
  75. package/build/components/AccountDropdown/index.js +1 -1
  76. package/build/components/ActivityAreaChart/index.js +1 -1
  77. package/build/components/Amount/index.js +1 -1
  78. package/build/components/AmountConversionFilter/index.js +1 -1
  79. package/build/components/AmountInput/index.js +1 -1
  80. package/build/components/AmountStatusChip/index.js +1 -1
  81. package/build/components/AnimatedSpinnerIcon/index.js +1 -1
  82. package/build/components/AppServices/index.js +1 -1
  83. package/build/components/AppServicesActionMenu/index.js +1 -1
  84. package/build/components/AppServicesBar/index.js +1 -1
  85. package/build/components/AppWindowWrapper/index.js +1 -1
  86. package/build/components/AuthenticationTypeChip/index.js +1 -1
  87. package/build/components/Autocomplete/index.js +1 -1
  88. package/build/components/BrandLogo/index.js +1 -1
  89. package/build/components/Button/index.js +1 -1
  90. package/build/components/Calender/index.js +1 -1
  91. package/build/components/CardEmptyState/index.js +1 -1
  92. package/build/components/Checkbox/index.js +1 -1
  93. package/build/components/ColorPicker/index.js +1 -1
  94. package/build/components/CopyImage/index.js +1 -1
  95. package/build/components/CountBadge/index.js +1 -1
  96. package/build/components/CountryFilter/index.js +1 -1
  97. package/build/components/CountryFlag/index.js +1 -1
  98. package/build/components/CurrencyFilter/index.js +1 -1
  99. package/build/components/CurrencySymbol/index.js +1 -1
  100. package/build/components/Customer/index.js +1 -1
  101. package/build/components/DateButton/index.js +1 -1
  102. package/build/components/DateFilter/index.js +1 -1
  103. package/build/components/DeviceIcon/index.js +1 -1
  104. package/build/components/Dialog/index.js +1 -1
  105. package/build/components/Discount/index.js +1 -1
  106. package/build/components/DisplayAmount/index.js +1 -1
  107. package/build/components/Dropdown2/index.js +1 -1
  108. package/build/components/DropdownButton/index.js +1 -1
  109. package/build/components/Error/index.js +1 -1
  110. package/build/components/ErrorToast/index.js +1 -1
  111. package/build/components/ExpandableSideBar/index.js +1 -1
  112. package/build/components/FileInputPreview/index.js +1 -1
  113. package/build/components/FilePreview/index.js +1 -1
  114. package/build/components/FileUpload/index.js +1 -1
  115. package/build/components/FileUploader/index.js +1 -1
  116. package/build/components/FilterDropdown/index.js +1 -1
  117. package/build/components/FilteredIds/index.js +1 -1
  118. package/build/components/Filters/index.js +1 -1
  119. package/build/components/FlagDetails/index.js +1 -1
  120. package/build/components/IconGallery/index.js +1 -1
  121. package/build/components/IconWithBadge/index.js +1 -1
  122. package/build/components/IconWithLabel/index.js +1 -1
  123. package/build/components/IconsDropdown/index.js +1 -1
  124. package/build/components/InputBase/index.js +1 -1
  125. package/build/components/InputNumber/index.js +1 -1
  126. package/build/components/Inputs/index.js +1 -1
  127. package/build/components/JSONViewer/index.js +1 -1
  128. package/build/components/LabeledIconDropdown/index.js +1 -1
  129. package/build/components/LanguageDropdown/index.js +1 -1
  130. package/build/components/ListColumnFilter/index.js +1 -1
  131. package/build/components/MFWidgetLoader/index.js +1 -1
  132. package/build/components/MaskedText/index.js +1 -1
  133. package/build/components/MenuItem/index.js +1 -1
  134. package/build/components/MerchantCurrencyDropdown/index.js +1 -1
  135. package/build/components/MerchantLogo/index.js +1 -1
  136. package/build/components/MerchantsDropdown/index.js +1 -1
  137. package/build/components/MultiSelectDropdownButton/index.js +1 -1
  138. package/build/components/MultiSelectStatusButton/index.js +1 -1
  139. package/build/components/MultiSelectWithSearch/index.js +1 -1
  140. package/build/components/NestedDropdown/index.js +1 -1
  141. package/build/components/PartnersFilter/index.js +1 -1
  142. package/build/components/PaymentSourceFilter/index.js +1 -1
  143. package/build/components/PhoneFilter/index.js +1 -1
  144. package/build/components/ProgressRing/index.js +1 -1
  145. package/build/components/RFH/index.js +1 -1
  146. package/build/components/RangeCalender/index.js +1 -1
  147. package/build/components/ReceiptsViewer/index.js +1 -1
  148. package/build/components/ReferenceTypeFilter/index.js +1 -1
  149. package/build/components/SalesChannelFilter/index.js +1 -1
  150. package/build/components/Sandbox/index.js +1 -1
  151. package/build/components/SearchButton/index.js +1 -1
  152. package/build/components/SearchListInput/index.js +1 -1
  153. package/build/components/SelectDropdown/index.js +1 -1
  154. package/build/components/SelectWithSearch/index.js +1 -1
  155. package/build/components/StatusBar/index.js +1 -1
  156. package/build/components/StatusButton/index.js +1 -1
  157. package/build/components/StatusChip/index.js +1 -1
  158. package/build/components/StatusChipWithCopy/index.js +1 -1
  159. package/build/components/StatusFilter/index.js +1 -1
  160. package/build/components/StatusGroupChips/index.js +1 -1
  161. package/build/components/StatusIcons/index.js +1 -1
  162. package/build/components/StatusLabel/index.js +1 -1
  163. package/build/components/TableCells/index.js +1 -1
  164. package/build/components/TableHeader/TableView/ViewsMenu.d.ts +1 -1
  165. package/build/components/TableHeader/TableView/hooks/useCustomTableViews.d.ts +1 -1
  166. package/build/components/TableHeader/TableView/hooks/useViewsManager.d.ts +1 -1
  167. package/build/components/TableHeader/TableView/types.d.ts +9 -3
  168. package/build/components/TableHeader/index.js +1 -1
  169. package/build/components/TableHeader/type.d.ts +2 -1
  170. package/build/components/TableReports/index.js +1 -1
  171. package/build/components/TableView/index.js +1 -1
  172. package/build/components/Timepicker/index.js +1 -1
  173. package/build/components/Toaster/index.js +1 -1
  174. package/build/components/ToggleView/index.js +1 -1
  175. package/build/components/Toolbar/index.js +1 -1
  176. package/build/components/ToolbarIcon/index.js +1 -1
  177. package/build/components/TreeDropdown/index.js +1 -1
  178. package/build/components/VAT/index.js +1 -1
  179. package/build/components/VerificationIcon/index.js +1 -1
  180. package/build/components/ViewColumnRadioFilter/index.js +1 -1
  181. package/build/components/VirtualTables/index.js +1 -1
  182. package/build/components/Widget/index.js +1 -1
  183. package/build/components/Window/index.js +1 -1
  184. package/build/components/WindowSideBar/index.js +1 -1
  185. package/build/components/index.js +1 -1
  186. package/build/constants/assets.d.ts +2 -0
  187. package/build/constants/index.js +1 -1
  188. package/build/hooks/index.js +1 -1
  189. package/build/index.js +1 -1
  190. package/build/types/index.d.ts +1 -0
  191. package/build/types/index.js +1 -1
  192. package/build/types/views.d.ts +10 -0
  193. package/build/utils/index.js +1 -1
  194. package/build/utils/localStorage.d.ts +3 -1
  195. package/package.json +1 -1
  196. package/build/chunk-3NCT7EIJ.js +0 -2
  197. package/build/chunk-IYZWNIGG.js +0 -2
  198. package/build/chunk-KW7XUEXS.js +0 -1
  199. package/build/chunk-N3WMUGVO.js +0 -2
  200. package/build/chunk-NKA62XLB.js +0 -1
  201. package/build/chunk-OCSFMAY5.js +0 -1
  202. /package/build/{chunk-LQSDB47Q.js → chunk-D7UBYLOL.js} +0 -0
@@ -1 +1 @@
1
- import {Yl,Xl}from'./chunk-N3WMUGVO.js';import {memo}from'react';import {Checkbox}from'@mui/material';import {jsx}from'react/jsx-runtime';function i(o){return jsx(Checkbox,{disableRipple:true,sx:r=>({'[data-testid="IndeterminateCheckBoxIcon"]':{fill:r.palette.info.dark,width:"16px !important",height:"16px !important"}}),checkedIcon:o.disabled?Yl:Xl,...o})}i.displayName="CheckboxInput";var p=memo(i);var l=p;export{l as a};
1
+ import {_l,Zl}from'./chunk-NK266ZWT.js';import {memo}from'react';import {Checkbox}from'@mui/material';import {jsx}from'react/jsx-runtime';function i(o){return jsx(Checkbox,{disableRipple:true,sx:r=>({'[data-testid="IndeterminateCheckBoxIcon"]':{fill:r.palette.info.dark,width:"16px !important",height:"16px !important"}}),checkedIcon:o.disabled?_l:Zl,...o})}i.displayName="CheckboxInput";var p=memo(i);var l=p;export{l as a};
@@ -1 +1 @@
1
- import {a}from'./chunk-EYL6U6ME.js';import {a as a$1}from'./chunk-S7OMWEM6.js';import {ub,w}from'./chunk-N3WMUGVO.js';import je,{memo,forwardRef,useMemo,useState,useEffect}from'react';import Q from'@mui/material/Box';import {styled}from'@mui/material/styles';import Ve from'@mui/material/TextField';import {jsxs,jsx,Fragment}from'react/jsx-runtime';import {styled as styled$1,Popper,Box,CircularProgress,ClickAwayListener}from'@mui/material';import pt from'@mui/material/InputLabel';import lt from'@mui/material/MenuItem';import nt from'@mui/material/FormControl';import re from'@mui/material/Select';import bt from'@mui/material/Skeleton';import Rt from'@mui/material/Input';var Z=styled(Q)(()=>({display:"flex",flexDirection:"column",gap:"4px",width:"100%",height:40,"& *":{flex:1,margin:"0 !important"}})),V=styled(Ve,{shouldForwardProp:e=>e!=="hideArrows"})(({theme:e,error:t,hideArrows:n,disabled:o})=>({border:`1px solid ${e.palette.divider}`,...o&&{backgroundColor:e.palette.grey[400]},borderRadius:"4px",...!!t&&{border:`1px solid ${e.palette.error.main}`},...n&&{"& input[type=number]":{MozAppearance:"textfield"},"& input[type=number]::-webkit-outer-spin-button":{WebkitAppearance:"none",margin:0},"& input[type=number]::-webkit-inner-spin-button":{WebkitAppearance:"none",margin:0}},"& .MuiFormLabel-asterisk":{color:"red"},"& .MuiInputBase-root":{maxHeight:"40px !important",alignItems:"flex-end !important",fontSize:"11px",height:"40px",padding:"8px",borderRadius:"4px"},"& .MuiInputBase-input":{margin:0,padding:0,color:e.palette.text.primary},"& .MuiFormLabel-root":{fontSize:"10px",fontWeight:500,lineHeight:"100%",transform:"translate(0, 8px) scale(1)",color:e.palette.grey[700],padding:"8px","&.MuiFormLabel-filled, &.Mui-focused":{transform:"translate(0, -1.5px) scale(0.75) "},"&.Mui-focused":{fontSize:"10px",fontWeight:500,lineHeight:"100%"}}})),j=styled("small")(({theme:e})=>({color:e.palette.error.main,fontSize:"10px",lineHeight:"10px",marginTop:"4px",display:"block"}));var ee=je.forwardRef(({name:e,onChange:t,hasError:n,helperText:o,hideArrows:f,...i},p)=>{let l=d=>{t?.(d.target.value??"");};return jsxs(Q,{children:[jsx(Z,{"data-testid":"InputBase",children:jsx(V,{rows:1,error:n,fullWidth:true,size:"small",variant:"standard",ref:p,name:e,type:i.type??"text",label:i.placeholder||i.label,onChange:l,InputProps:{disableUnderline:true},hideArrows:f,...i})}),jsx(j,{children:o})]})});ee.displayName="InputBase";var te=ee;var rt=te;var H=styled(nt)(({theme:e})=>({minWidth:52,height:"40px !important",maxHeight:"40px !important",backgroundColor:"transparent",width:"100%","& .MuiFormLabel-asterisk":{color:"red"},"& .MuiFormLabel-root":{fontSize:"10px",fontStyle:"normal",fontWeight:500,lineHeight:"100%",transform:"translate(8px, 15px) scale(1)",color:`${e.palette.grey[700]} !important`},".MuiFormLabel-root.MuiFormLabel-filled":{transform:"translate(8px, 8px) scale(0.75) "},".MuiFormLabel-root.Mui-focused":{transform:"translate(8px, 8px) scale(0.75)",fontSize:"10px",fontStyle:"normal",fontWeight:500,lineHeight:"100%"}}));styled(re)(({theme:e})=>({fontSize:"11px",lineHeight:"11px",color:e.palette.common.black,borderRadius:"4px",boxShadow:e.shadows[17],border:"none",outline:"none","&:focus":{border:"1px solid #1F88D0"},"& .MuiOutlinedInput-root":{"& fieldset":{borderColor:"rgba(0, 0, 0, 0.23)"},"&.Mui-focused fieldset":{border:"2px solid red"}},minWidth:52,height:"40px !important",maxHeight:"40px !important",width:"100%","& .MuiFormLabel-asterisk":{color:"red"},"& .MuiFormLabel-root":{fontSize:"10px",fontStyle:"normal",fontWeight:500,lineHeight:"100%",transform:"translate(8px, 15px) scale(1)"},".MuiFormLabel-root.MuiFormLabel-filled":{transform:"translate(8px, 8px) scale(0.75) "},".MuiFormLabel-root.Mui-focused":{transform:"translate(8px, 8px) scale(0.75)",fontSize:"10px",fontStyle:"normal",fontWeight:500,lineHeight:"100%"}}));var N=styled("small")(({theme:e})=>({color:e.palette.error.main,fontSize:"10px",lineHeight:"10px",marginTop:"4px",display:"block"})),z=styled(re)(({theme:e,error:t})=>({width:"100%",height:"40px !important",maxHeight:"40px !important",borderRadius:"4px",overflow:"hidden",backgroundColor:e.palette.grey[400],"&.Mui-disabled":{backgroundColor:e.palette.grey[400]},".MuiSelect-select":{padding:"0 8px !important",height:"40px !important",maxHeight:"40px !important",display:"flex",alignItems:"flex-end !important",backgroundColor:`${e.palette.grey[400]} !important`,borderRadius:"4px",fontSize:"11px"},".MuiSelect-filled":{padding:"0 8px !important"},"&.MuiInputBase-adornedStart > div:nth-of-type(1)":{backgroundColor:"red"},...t&&{border:`1px solid ${e.palette.error.main}`}})),$=styled(Q)(()=>({display:"flex",alignItems:"stretch",height:"100%",flexDirection:"column",flex:1}));function st({required:e,hasError:t,label:n,value:o,helperText:f,onChange:i,options:p,isOptionEqualToValue:l,renderOption:d,getOptionValue:s,isLoading:g,children:u,getOptionLabel:y,...h},C){let a=m=>{i?.(m);},S=()=>d?d(o):y?y(o):o.label;return jsxs($,{children:[jsxs(H,{variant:"filled","data-testid":"SelectBase",required:e,children:[jsx(pt,{sx:{height:"100%"},id:`select-label-${n.trim()}`,"data-testid":"SelectBase_InputLabel",children:n}),jsx(z,{"data-testid":"SelectBase_Select",ref:C,value:(s?s(o):o?.id)??"",error:t,disableUnderline:true,required:e,labelId:`select-label-${n.trim()}`,id:`select-label-${n.trim()}`,renderValue:S,...h,disabled:h.disabled||g,endAdornment:g?jsx(CircularProgress,{size:20,sx:{backgroundColor:"transparent",color:m=>m.palette.grey.A400}}):null,children:u||p?.map((m,B)=>{let r=l?l(m,o):m?.id===o?.id;return jsx(lt,{disabled:!!m.disabled,value:(s?s(m):m?.id)??"",onClick:()=>{a(m);},sx:{fontSize:"12px",backgroundColor:c=>r?c.palette.action.hover:c.palette.common.white},children:d?d(m):m.label},`country-item-${B}`)})})]}),jsx(N,{children:f})]})}var ne=je.forwardRef(st);function gt({required:e,hasError:t,label:n,value:o,helperText:f,onChange:i,options:p,isOptionEqualToValue:l,renderOption:d,getOptionValue:s,isLoading:g,children:u,getOptionLabel:y,...h},C){let a=r=>{i?.(r);},S=()=>s?o?.map(s):o?.map(r=>r?.id),m=useMemo(()=>p?.filter(r=>o?.some(c=>l?l(r,c):r.id===c?.id)),[p,o,l]),B=()=>m?.map(r=>y?y(r):r.label)?.join(", ");return jsxs($,{children:[jsxs(H,{variant:"filled","data-testid":"SelectBase",required:e,children:[jsx(pt,{id:`select-label-${n.trim()}`,"data-testid":"SelectBase_InputLabel",children:n}),jsx(z,{multiple:true,"data-testid":"SelectBase_Select",ref:C,value:S()??"",error:t,disableUnderline:true,required:e,labelId:`select-label-${n.trim()}`,id:`select-label-${n.trim()}`,renderValue:B,...h,disabled:h.disabled||g,endAdornment:g?jsx(CircularProgress,{size:20,sx:{backgroundColor:"transparent",color:r=>r.palette.grey.A400}}):null,onChange:r=>{let L=r.target.value?.map(I=>p?.find(X=>s?s(X)===I:X.id===I));i?.([...L]);},children:u||p?.map((r,c)=>{let L=l?l(r,o):r?.id===o?.id;return jsx(lt,{value:(s?s(r):r?.id)??"",onClick:()=>{a(r);},sx:{fontSize:"12px",backgroundColor:I=>L?I.palette.action.hover:I.palette.common.white},children:d?d(r):r.label},`country-item-${c}`)})})]}),jsx(N,{children:f})]})}var ie=je.forwardRef(gt);var xt=ne;var pe=styled$1("button")(({theme:e,disabled:t})=>({display:"flex",gap:"4px",alignItems:"center",".logo":{width:"15.568px",height:"10.889px",borderRadius:"3px"},".arrow":{width:14},span:{color:e.palette.text.primary,fontWeight:500,fontSize:"11px"},height:24,cursor:t?"default":"pointer",opacity:t?.5:1})),le=styled$1(Popper)(({theme:e})=>({zIndex:9999,backgroundColor:e.palette.common.white,padding:"4px 8px",borderRadius:"4px",border:`1px solid ${e.palette.divider}`,width:100})),se=styled$1("ul")(()=>({listStyle:"none",padding:0,margin:0,maxHeight:100,overflow:"auto"})),de=styled$1("li")(({theme:e})=>({display:"flex",gap:"4px",alignItems:"center",".logo":{width:"15.568px",height:"10.889px",borderRadius:"3px"},".arrow":{width:14},span:{color:e.palette.text.primary,fontWeight:500,fontSize:"11px"},height:24,cursor:"pointer"})),ue=styled$1(a)(()=>({height:24,padding:"4px",marginBottom:"4px"})),me=styled$1(Box)(()=>({color:"red !important"}));function xe({isLoading:e,countries:t,value:n,onCountryChange:o,required:f,disabled:i}){let[p,l]=useState(),[d,s]=useState(null),[g,u]=useState([]),[y,h]=useState(""),C=!!d&&!i,a=r=>{r.stopPropagation(),s(r.currentTarget);},S=()=>{s(null);},m=r=>{o?.(r),l(r),S(),u(t);},B=r=>{let c=r.target.value.toString()??"";if(h(c),!c){u(t);return}let L=t.filter(I=>I.idd_prefix.toString().startsWith(c)||I.iso2.toLowerCase().startsWith(c.toLowerCase()));u(L);};return useEffect(()=>{n&&l(n);},[n?.countryId]),useEffect(()=>{t.length&&u(t);},[t.length]),jsxs(Q,{"data-testid":"CountriesList",sx:{position:"relative"},children:[jsx(pe,{type:"button","aria-describedby":"CountriesList_CountriesWrapper",onClick:a,disabled:e||i,sx:{backgroundColor:"transparent",border:"none",height:34,paddingInlineStart:"8px"},children:e?jsx(bt,{variant:"rectangular",width:56.5,height:20,sx:{borderRadius:"4px"}}):jsxs(Fragment,{children:[p&&jsxs(Fragment,{children:[jsx("img",{src:p.logo,alt:"c",className:"logo"}),jsx("span",{children:`+${p?.idd_prefix}`})]}),f&&jsx(me,{component:"span",children:"*"}),jsx(Q,{component:"img",src:ub,alt:"d",className:"arrow",sx:{...C&&{transform:"rotate(180deg)"}}})]})}),C&&jsx(a$1,{onClick:S,sx:{zIndex:9999}}),C&&jsx(ClickAwayListener,{onClickAway:S,children:jsxs(le,{id:"CountriesList_CountriesWrapper",open:C,anchorEl:d,"data-testid":"CountriesList_CountriesWrapper",placement:"bottom-start",children:[jsx(ue,{endAdornment:jsx("img",{src:w,alt:"arrow"}),onChange:B,hideArrows:true,"data-testid":"CountriesList_InputStyled",value:y}),jsx(se,{"data-testid":"CountriesList_CountriesListStyled",children:g.map(r=>{let c=p?.countryId===r.countryId;return jsxs(de,{onClick:()=>{m(r);},sx:{backgroundColor:c?"#F9F9F9":"transparent",color:c?"#000":"#8D8D94"},children:[jsx("img",{src:r.logo,alt:"c",className:"logo"}),jsx("span",{children:`+${r.idd_prefix}`})]},`country-code-${r.countryId}`)})})]})})]})}xe.displayName="CountriesList";var ye=memo(xe);var _=ye;var Ce=styled(Q,{shouldForwardProp:e=>e!=="hasError"})(({theme:e,hasError:t})=>({border:`1px solid ${e.palette.divider}`,display:"flex",position:"relative",paddingInline:"8px",paddingInlineStart:"0px",alignItems:"center",borderRadius:"4px",height:"40px",...t&&{border:`1px solid ${e.palette.error.main}`}})),be=styled(a)(({error:e})=>({border:"none",paddingInlineEnd:0,img:{cursor:"pointer"},...e&&{borderBottomLeftRadius:0,borderBottomRightRadius:0,borderBottom:"none"}})),Se=styled("small")(({theme:e})=>({color:e.palette.error.main,fontSize:"10px",lineHeight:"10px",marginTop:"4px",display:"block"})),Ie=styled(Q)(()=>({flex:1}));function Be({phoneValue:e,hasError:t,countries:n,isCountriesLoading:o,countryValue:f,onCountryChange:i,onPhoneChange:p,helperText:l,countryError:d,required:s,disabled:g,...u},y){return jsxs(Ie,{"data-testid":"PhoneInput",children:[jsxs(Ce,{"data-testid":"PhoneInput_MobileWrapper",hasError:t,children:[jsx(_,{isLoading:o,countries:n,value:f,onCountryChange:a=>{i?.(a);},required:s,disabled:g}),jsx(be,{value:e,"data-testid":"PhoneInput_InputNumberStyled",ref:y,inputProps:{autoComplete:"off"},error:t,disabled:g,...u,onChange:a=>{p?.(a.target.value);},hideArrows:true})]}),jsx(Se,{children:l})]})}Be.displayName="PhoneInputBase";var Le=je.forwardRef(Be);var Mt=Le;var we=styled$1("button")(({theme:e})=>({display:"flex",gap:"4px",alignItems:"center",".logo":{width:"15.568px",height:"10.889px",borderRadius:"3px"},".arrow":{width:14},span:{color:e.palette.text.primary,fontWeight:500,fontSize:"11px"},height:24,cursor:"pointer"})),ve=styled$1(Popper)(({theme:e})=>({zIndex:99,backgroundColor:e.palette.common.white,padding:"4px 8px",borderRadius:"4px",border:`1px solid ${e.palette.divider}`,width:100})),Pe=styled$1("ul")(()=>({listStyle:"none",padding:0,margin:0,maxHeight:100,overflow:"auto"})),Re=styled$1("li")(({theme:e})=>({display:"flex",gap:"4px",alignItems:"center",".logo":{width:"15.568px",height:"10.889px",borderRadius:"3px"},".arrow":{width:14},span:{color:e.palette.text.primary,fontWeight:500,fontSize:"11px"},height:24,cursor:"pointer"})),Ee=styled$1(Box)(()=>({color:"red !important"}));function Fe({isLoading:e,currencies:t,value:n,onCurrencyChange:o,required:f}){let[i,p]=useState(),[l,d]=useState(null),[s,g]=useState([]),u=!!l,y=a=>{a.stopPropagation(),d(a.currentTarget);},h=()=>{d(null);},C=a=>{o?.(a),p(a),h(),g(t);};return useEffect(()=>{n&&p(n);},[n?.currencyId]),useEffect(()=>{t.length&&g(t);},[t.length]),jsxs(Q,{"data-testid":"currenciesList",sx:{position:"relative"},children:[jsx(we,{type:"button","aria-describedby":"currenciesList_currenciesWrapper",onClick:y,disabled:e,sx:{backgroundColor:"transparent",border:"none",height:34,paddingInlineStart:"8px"},children:e?jsx(bt,{variant:"rectangular",width:56.5,height:20,sx:{borderRadius:"4px"}}):jsxs(Fragment,{children:[i&&jsxs(Fragment,{children:[jsx("img",{src:i.logo,alt:"c",className:"logo"}),jsx("span",{children:i?.code.english})]}),f&&jsx(Ee,{component:"span",children:"*"}),jsx(Q,{component:"img",src:ub,alt:"d",className:"arrow",sx:{...u&&{transform:"rotate(180deg)"}}})]})}),u&&jsx(a$1,{onClick:h}),u&&jsx(ve,{id:"currenciesList_currenciesWrapper",open:u,anchorEl:l,"data-testid":"currenciesList_currenciesWrapper",placement:"bottom-start",children:jsx(Pe,{"data-testid":"currenciesList_currenciesListStyled",children:s.map(a=>{let S=i?.currencyId===a.currencyId;return jsxs(Re,{onClick:()=>{C(a);},sx:{backgroundColor:S?"#F9F9F9":"transparent",color:S?"#000":"#8D8D94"},children:[jsx("img",{src:a.logo,alt:"c",className:"logo"}),jsx("span",{children:a?.code.english})]},`currency-code-${a.currencyId}`)})})})]})}Fe.displayName="CurrenciesList";var He=memo(Fe);var Ne=He;var $e=styled(Rt,{shouldForwardProp:e=>!["hasError","hideArrows"].includes(e)})(({theme:e,hideArrows:t})=>({padding:"8px",border:`1px solid ${e.palette.divider}`,borderRadius:"4px",height:32,color:e.palette.text.primary,fontSize:"11px",outline:0,maxWidth:"100%",display:"flex",flexGrow:1,"::placeholder":{color:e.palette.grey[700],fontWeight:400},...t&&{"& input[type=number]":{MozAppearance:"textfield"},"& input[type=number]::-webkit-outer-spin-button":{WebkitAppearance:"none",margin:0},"& input[type=number]::-webkit-inner-spin-button":{WebkitAppearance:"none",margin:0}}})),Te=styled(Q)(()=>({flex:1}));function Wt({hasError:e,hideArrows:t,inputProps:n,...o},f){return jsx(Te,{onClick:i=>{i.stopPropagation();},children:jsx($e,{ref:f,placeholder:o.placeholder,hideArrows:true,hasError:e,disableUnderline:true,inputProps:{...n,type:"number"},onKeyDown:i=>{["e","E","+","-"].includes(i.key)&&i.preventDefault();},...o})})}var De=forwardRef(Wt);var qe=De;var Oe=styled(Q,{shouldForwardProp:e=>e!=="hasError"})(({theme:e,hasError:t})=>({border:`1px solid ${e.palette.divider}`,display:"flex",justifyContent:"space-between",position:"relative",paddingInline:"8px",paddingInlineStart:"0px",alignItems:"center",borderRadius:"4px",height:"40px",...t&&{border:`1px solid ${e.palette.error.main}`}})),Ue=styled(Q)(()=>({width:"50px"})),Ge=styled(qe)(({error:e})=>({border:"none",paddingInlineEnd:0,img:{cursor:"pointer"},...e&&{borderBottomLeftRadius:0,borderBottomRightRadius:0,borderBottom:"none"}})),Ke=styled("small")(({theme:e})=>({color:e.palette.error.main,fontSize:"10px",lineHeight:"10px",marginTop:"4px",display:"block"})),Je=styled(Q)(()=>({flex:1}));function Xe({amountValue:e,hasError:t,currencies:n,isCurrenciesLoading:o,currencyValue:f,onCurrencyChange:i,onAmountChange:p,onAmountBlur:l,helperText:d,required:s,...g},u){return jsxs(Je,{"data-testid":"AmountInput",children:[jsxs(Oe,{"data-testid":"AmountInput_MobileWrapper",hasError:t,children:[jsx(Ne,{isLoading:o,currencies:n,value:f,onCurrencyChange:a=>{i?.(a);},required:s}),jsx(Ue,{children:jsx(Ge,{value:e,"data-testid":"AmountInput_InputNumberStyled",ref:u,inputProps:{autoComplete:"off"},error:t,...g,onChange:a=>{p?.(a.target.value);},onBlur:a=>{l?.(a.target.value);},hideArrows:true})})]}),jsx(Ke,{children:d})]})}Xe.displayName="AmountInputBase";var Ye=je.forwardRef(Xe);var At=Ye;export{rt as a,ie as b,xt as c,_ as d,Mt as e,At as f};
1
+ import {a}from'./chunk-DHDB2BWN.js';import {a as a$1}from'./chunk-S7OMWEM6.js';import {ub,w}from'./chunk-NK266ZWT.js';import je,{memo,forwardRef,useMemo,useState,useEffect}from'react';import Q from'@mui/material/Box';import {styled}from'@mui/material/styles';import Ve from'@mui/material/TextField';import {jsxs,jsx,Fragment}from'react/jsx-runtime';import {styled as styled$1,Popper,Box,CircularProgress,ClickAwayListener}from'@mui/material';import pt from'@mui/material/InputLabel';import lt from'@mui/material/MenuItem';import nt from'@mui/material/FormControl';import re from'@mui/material/Select';import bt from'@mui/material/Skeleton';import Rt from'@mui/material/Input';var Z=styled(Q)(()=>({display:"flex",flexDirection:"column",gap:"4px",width:"100%",height:40,"& *":{flex:1,margin:"0 !important"}})),V=styled(Ve,{shouldForwardProp:e=>e!=="hideArrows"})(({theme:e,error:t,hideArrows:n,disabled:o})=>({border:`1px solid ${e.palette.divider}`,...o&&{backgroundColor:e.palette.grey[400]},borderRadius:"4px",...!!t&&{border:`1px solid ${e.palette.error.main}`},...n&&{"& input[type=number]":{MozAppearance:"textfield"},"& input[type=number]::-webkit-outer-spin-button":{WebkitAppearance:"none",margin:0},"& input[type=number]::-webkit-inner-spin-button":{WebkitAppearance:"none",margin:0}},"& .MuiFormLabel-asterisk":{color:"red"},"& .MuiInputBase-root":{maxHeight:"40px !important",alignItems:"flex-end !important",fontSize:"11px",height:"40px",padding:"8px",borderRadius:"4px"},"& .MuiInputBase-input":{margin:0,padding:0,color:e.palette.text.primary},"& .MuiFormLabel-root":{fontSize:"10px",fontWeight:500,lineHeight:"100%",transform:"translate(0, 8px) scale(1)",color:e.palette.grey[700],padding:"8px","&.MuiFormLabel-filled, &.Mui-focused":{transform:"translate(0, -1.5px) scale(0.75) "},"&.Mui-focused":{fontSize:"10px",fontWeight:500,lineHeight:"100%"}}})),j=styled("small")(({theme:e})=>({color:e.palette.error.main,fontSize:"10px",lineHeight:"10px",marginTop:"4px",display:"block"}));var ee=je.forwardRef(({name:e,onChange:t,hasError:n,helperText:o,hideArrows:f,...i},p)=>{let l=d=>{t?.(d.target.value??"");};return jsxs(Q,{children:[jsx(Z,{"data-testid":"InputBase",children:jsx(V,{rows:1,error:n,fullWidth:true,size:"small",variant:"standard",ref:p,name:e,type:i.type??"text",label:i.placeholder||i.label,onChange:l,InputProps:{disableUnderline:true},hideArrows:f,...i})}),jsx(j,{children:o})]})});ee.displayName="InputBase";var te=ee;var rt=te;var H=styled(nt)(({theme:e})=>({minWidth:52,height:"40px !important",maxHeight:"40px !important",backgroundColor:"transparent",width:"100%","& .MuiFormLabel-asterisk":{color:"red"},"& .MuiFormLabel-root":{fontSize:"10px",fontStyle:"normal",fontWeight:500,lineHeight:"100%",transform:"translate(8px, 15px) scale(1)",color:`${e.palette.grey[700]} !important`},".MuiFormLabel-root.MuiFormLabel-filled":{transform:"translate(8px, 8px) scale(0.75) "},".MuiFormLabel-root.Mui-focused":{transform:"translate(8px, 8px) scale(0.75)",fontSize:"10px",fontStyle:"normal",fontWeight:500,lineHeight:"100%"}}));styled(re)(({theme:e})=>({fontSize:"11px",lineHeight:"11px",color:e.palette.common.black,borderRadius:"4px",boxShadow:e.shadows[17],border:"none",outline:"none","&:focus":{border:"1px solid #1F88D0"},"& .MuiOutlinedInput-root":{"& fieldset":{borderColor:"rgba(0, 0, 0, 0.23)"},"&.Mui-focused fieldset":{border:"2px solid red"}},minWidth:52,height:"40px !important",maxHeight:"40px !important",width:"100%","& .MuiFormLabel-asterisk":{color:"red"},"& .MuiFormLabel-root":{fontSize:"10px",fontStyle:"normal",fontWeight:500,lineHeight:"100%",transform:"translate(8px, 15px) scale(1)"},".MuiFormLabel-root.MuiFormLabel-filled":{transform:"translate(8px, 8px) scale(0.75) "},".MuiFormLabel-root.Mui-focused":{transform:"translate(8px, 8px) scale(0.75)",fontSize:"10px",fontStyle:"normal",fontWeight:500,lineHeight:"100%"}}));var N=styled("small")(({theme:e})=>({color:e.palette.error.main,fontSize:"10px",lineHeight:"10px",marginTop:"4px",display:"block"})),z=styled(re)(({theme:e,error:t})=>({width:"100%",height:"40px !important",maxHeight:"40px !important",borderRadius:"4px",overflow:"hidden",backgroundColor:e.palette.grey[400],"&.Mui-disabled":{backgroundColor:e.palette.grey[400]},".MuiSelect-select":{padding:"0 8px !important",height:"40px !important",maxHeight:"40px !important",display:"flex",alignItems:"flex-end !important",backgroundColor:`${e.palette.grey[400]} !important`,borderRadius:"4px",fontSize:"11px"},".MuiSelect-filled":{padding:"0 8px !important"},"&.MuiInputBase-adornedStart > div:nth-of-type(1)":{backgroundColor:"red"},...t&&{border:`1px solid ${e.palette.error.main}`}})),$=styled(Q)(()=>({display:"flex",alignItems:"stretch",height:"100%",flexDirection:"column",flex:1}));function st({required:e,hasError:t,label:n,value:o,helperText:f,onChange:i,options:p,isOptionEqualToValue:l,renderOption:d,getOptionValue:s,isLoading:g,children:u,getOptionLabel:y,...h},C){let a=m=>{i?.(m);},S=()=>d?d(o):y?y(o):o.label;return jsxs($,{children:[jsxs(H,{variant:"filled","data-testid":"SelectBase",required:e,children:[jsx(pt,{sx:{height:"100%"},id:`select-label-${n.trim()}`,"data-testid":"SelectBase_InputLabel",children:n}),jsx(z,{"data-testid":"SelectBase_Select",ref:C,value:(s?s(o):o?.id)??"",error:t,disableUnderline:true,required:e,labelId:`select-label-${n.trim()}`,id:`select-label-${n.trim()}`,renderValue:S,...h,disabled:h.disabled||g,endAdornment:g?jsx(CircularProgress,{size:20,sx:{backgroundColor:"transparent",color:m=>m.palette.grey.A400}}):null,children:u||p?.map((m,B)=>{let r=l?l(m,o):m?.id===o?.id;return jsx(lt,{disabled:!!m.disabled,value:(s?s(m):m?.id)??"",onClick:()=>{a(m);},sx:{fontSize:"12px",backgroundColor:c=>r?c.palette.action.hover:c.palette.common.white},children:d?d(m):m.label},`country-item-${B}`)})})]}),jsx(N,{children:f})]})}var ne=je.forwardRef(st);function gt({required:e,hasError:t,label:n,value:o,helperText:f,onChange:i,options:p,isOptionEqualToValue:l,renderOption:d,getOptionValue:s,isLoading:g,children:u,getOptionLabel:y,...h},C){let a=r=>{i?.(r);},S=()=>s?o?.map(s):o?.map(r=>r?.id),m=useMemo(()=>p?.filter(r=>o?.some(c=>l?l(r,c):r.id===c?.id)),[p,o,l]),B=()=>m?.map(r=>y?y(r):r.label)?.join(", ");return jsxs($,{children:[jsxs(H,{variant:"filled","data-testid":"SelectBase",required:e,children:[jsx(pt,{id:`select-label-${n.trim()}`,"data-testid":"SelectBase_InputLabel",children:n}),jsx(z,{multiple:true,"data-testid":"SelectBase_Select",ref:C,value:S()??"",error:t,disableUnderline:true,required:e,labelId:`select-label-${n.trim()}`,id:`select-label-${n.trim()}`,renderValue:B,...h,disabled:h.disabled||g,endAdornment:g?jsx(CircularProgress,{size:20,sx:{backgroundColor:"transparent",color:r=>r.palette.grey.A400}}):null,onChange:r=>{let L=r.target.value?.map(I=>p?.find(X=>s?s(X)===I:X.id===I));i?.([...L]);},children:u||p?.map((r,c)=>{let L=l?l(r,o):r?.id===o?.id;return jsx(lt,{value:(s?s(r):r?.id)??"",onClick:()=>{a(r);},sx:{fontSize:"12px",backgroundColor:I=>L?I.palette.action.hover:I.palette.common.white},children:d?d(r):r.label},`country-item-${c}`)})})]}),jsx(N,{children:f})]})}var ie=je.forwardRef(gt);var xt=ne;var pe=styled$1("button")(({theme:e,disabled:t})=>({display:"flex",gap:"4px",alignItems:"center",".logo":{width:"15.568px",height:"10.889px",borderRadius:"3px"},".arrow":{width:14},span:{color:e.palette.text.primary,fontWeight:500,fontSize:"11px"},height:24,cursor:t?"default":"pointer",opacity:t?.5:1})),le=styled$1(Popper)(({theme:e})=>({zIndex:9999,backgroundColor:e.palette.common.white,padding:"4px 8px",borderRadius:"4px",border:`1px solid ${e.palette.divider}`,width:100})),se=styled$1("ul")(()=>({listStyle:"none",padding:0,margin:0,maxHeight:100,overflow:"auto"})),de=styled$1("li")(({theme:e})=>({display:"flex",gap:"4px",alignItems:"center",".logo":{width:"15.568px",height:"10.889px",borderRadius:"3px"},".arrow":{width:14},span:{color:e.palette.text.primary,fontWeight:500,fontSize:"11px"},height:24,cursor:"pointer"})),ue=styled$1(a)(()=>({height:24,padding:"4px",marginBottom:"4px"})),me=styled$1(Box)(()=>({color:"red !important"}));function xe({isLoading:e,countries:t,value:n,onCountryChange:o,required:f,disabled:i}){let[p,l]=useState(),[d,s]=useState(null),[g,u]=useState([]),[y,h]=useState(""),C=!!d&&!i,a=r=>{r.stopPropagation(),s(r.currentTarget);},S=()=>{s(null);},m=r=>{o?.(r),l(r),S(),u(t);},B=r=>{let c=r.target.value.toString()??"";if(h(c),!c){u(t);return}let L=t.filter(I=>I.idd_prefix.toString().startsWith(c)||I.iso2.toLowerCase().startsWith(c.toLowerCase()));u(L);};return useEffect(()=>{n&&l(n);},[n?.countryId]),useEffect(()=>{t.length&&u(t);},[t.length]),jsxs(Q,{"data-testid":"CountriesList",sx:{position:"relative"},children:[jsx(pe,{type:"button","aria-describedby":"CountriesList_CountriesWrapper",onClick:a,disabled:e||i,sx:{backgroundColor:"transparent",border:"none",height:34,paddingInlineStart:"8px"},children:e?jsx(bt,{variant:"rectangular",width:56.5,height:20,sx:{borderRadius:"4px"}}):jsxs(Fragment,{children:[p&&jsxs(Fragment,{children:[jsx("img",{src:p.logo,alt:"c",className:"logo"}),jsx("span",{children:`+${p?.idd_prefix}`})]}),f&&jsx(me,{component:"span",children:"*"}),jsx(Q,{component:"img",src:ub,alt:"d",className:"arrow",sx:{...C&&{transform:"rotate(180deg)"}}})]})}),C&&jsx(a$1,{onClick:S,sx:{zIndex:9999}}),C&&jsx(ClickAwayListener,{onClickAway:S,children:jsxs(le,{id:"CountriesList_CountriesWrapper",open:C,anchorEl:d,"data-testid":"CountriesList_CountriesWrapper",placement:"bottom-start",children:[jsx(ue,{endAdornment:jsx("img",{src:w,alt:"arrow"}),onChange:B,hideArrows:true,"data-testid":"CountriesList_InputStyled",value:y}),jsx(se,{"data-testid":"CountriesList_CountriesListStyled",children:g.map(r=>{let c=p?.countryId===r.countryId;return jsxs(de,{onClick:()=>{m(r);},sx:{backgroundColor:c?"#F9F9F9":"transparent",color:c?"#000":"#8D8D94"},children:[jsx("img",{src:r.logo,alt:"c",className:"logo"}),jsx("span",{children:`+${r.idd_prefix}`})]},`country-code-${r.countryId}`)})})]})})]})}xe.displayName="CountriesList";var ye=memo(xe);var _=ye;var Ce=styled(Q,{shouldForwardProp:e=>e!=="hasError"})(({theme:e,hasError:t})=>({border:`1px solid ${e.palette.divider}`,display:"flex",position:"relative",paddingInline:"8px",paddingInlineStart:"0px",alignItems:"center",borderRadius:"4px",height:"40px",...t&&{border:`1px solid ${e.palette.error.main}`}})),be=styled(a)(({error:e})=>({border:"none",paddingInlineEnd:0,img:{cursor:"pointer"},...e&&{borderBottomLeftRadius:0,borderBottomRightRadius:0,borderBottom:"none"}})),Se=styled("small")(({theme:e})=>({color:e.palette.error.main,fontSize:"10px",lineHeight:"10px",marginTop:"4px",display:"block"})),Ie=styled(Q)(()=>({flex:1}));function Be({phoneValue:e,hasError:t,countries:n,isCountriesLoading:o,countryValue:f,onCountryChange:i,onPhoneChange:p,helperText:l,countryError:d,required:s,disabled:g,...u},y){return jsxs(Ie,{"data-testid":"PhoneInput",children:[jsxs(Ce,{"data-testid":"PhoneInput_MobileWrapper",hasError:t,children:[jsx(_,{isLoading:o,countries:n,value:f,onCountryChange:a=>{i?.(a);},required:s,disabled:g}),jsx(be,{value:e,"data-testid":"PhoneInput_InputNumberStyled",ref:y,inputProps:{autoComplete:"off"},error:t,disabled:g,...u,onChange:a=>{p?.(a.target.value);},hideArrows:true})]}),jsx(Se,{children:l})]})}Be.displayName="PhoneInputBase";var Le=je.forwardRef(Be);var Mt=Le;var we=styled$1("button")(({theme:e})=>({display:"flex",gap:"4px",alignItems:"center",".logo":{width:"15.568px",height:"10.889px",borderRadius:"3px"},".arrow":{width:14},span:{color:e.palette.text.primary,fontWeight:500,fontSize:"11px"},height:24,cursor:"pointer"})),ve=styled$1(Popper)(({theme:e})=>({zIndex:99,backgroundColor:e.palette.common.white,padding:"4px 8px",borderRadius:"4px",border:`1px solid ${e.palette.divider}`,width:100})),Pe=styled$1("ul")(()=>({listStyle:"none",padding:0,margin:0,maxHeight:100,overflow:"auto"})),Re=styled$1("li")(({theme:e})=>({display:"flex",gap:"4px",alignItems:"center",".logo":{width:"15.568px",height:"10.889px",borderRadius:"3px"},".arrow":{width:14},span:{color:e.palette.text.primary,fontWeight:500,fontSize:"11px"},height:24,cursor:"pointer"})),Ee=styled$1(Box)(()=>({color:"red !important"}));function Fe({isLoading:e,currencies:t,value:n,onCurrencyChange:o,required:f}){let[i,p]=useState(),[l,d]=useState(null),[s,g]=useState([]),u=!!l,y=a=>{a.stopPropagation(),d(a.currentTarget);},h=()=>{d(null);},C=a=>{o?.(a),p(a),h(),g(t);};return useEffect(()=>{n&&p(n);},[n?.currencyId]),useEffect(()=>{t.length&&g(t);},[t.length]),jsxs(Q,{"data-testid":"currenciesList",sx:{position:"relative"},children:[jsx(we,{type:"button","aria-describedby":"currenciesList_currenciesWrapper",onClick:y,disabled:e,sx:{backgroundColor:"transparent",border:"none",height:34,paddingInlineStart:"8px"},children:e?jsx(bt,{variant:"rectangular",width:56.5,height:20,sx:{borderRadius:"4px"}}):jsxs(Fragment,{children:[i&&jsxs(Fragment,{children:[jsx("img",{src:i.logo,alt:"c",className:"logo"}),jsx("span",{children:i?.code.english})]}),f&&jsx(Ee,{component:"span",children:"*"}),jsx(Q,{component:"img",src:ub,alt:"d",className:"arrow",sx:{...u&&{transform:"rotate(180deg)"}}})]})}),u&&jsx(a$1,{onClick:h}),u&&jsx(ve,{id:"currenciesList_currenciesWrapper",open:u,anchorEl:l,"data-testid":"currenciesList_currenciesWrapper",placement:"bottom-start",children:jsx(Pe,{"data-testid":"currenciesList_currenciesListStyled",children:s.map(a=>{let S=i?.currencyId===a.currencyId;return jsxs(Re,{onClick:()=>{C(a);},sx:{backgroundColor:S?"#F9F9F9":"transparent",color:S?"#000":"#8D8D94"},children:[jsx("img",{src:a.logo,alt:"c",className:"logo"}),jsx("span",{children:a?.code.english})]},`currency-code-${a.currencyId}`)})})})]})}Fe.displayName="CurrenciesList";var He=memo(Fe);var Ne=He;var $e=styled(Rt,{shouldForwardProp:e=>!["hasError","hideArrows"].includes(e)})(({theme:e,hideArrows:t})=>({padding:"8px",border:`1px solid ${e.palette.divider}`,borderRadius:"4px",height:32,color:e.palette.text.primary,fontSize:"11px",outline:0,maxWidth:"100%",display:"flex",flexGrow:1,"::placeholder":{color:e.palette.grey[700],fontWeight:400},...t&&{"& input[type=number]":{MozAppearance:"textfield"},"& input[type=number]::-webkit-outer-spin-button":{WebkitAppearance:"none",margin:0},"& input[type=number]::-webkit-inner-spin-button":{WebkitAppearance:"none",margin:0}}})),Te=styled(Q)(()=>({flex:1}));function Wt({hasError:e,hideArrows:t,inputProps:n,...o},f){return jsx(Te,{onClick:i=>{i.stopPropagation();},children:jsx($e,{ref:f,placeholder:o.placeholder,hideArrows:true,hasError:e,disableUnderline:true,inputProps:{...n,type:"number"},onKeyDown:i=>{["e","E","+","-"].includes(i.key)&&i.preventDefault();},...o})})}var De=forwardRef(Wt);var qe=De;var Oe=styled(Q,{shouldForwardProp:e=>e!=="hasError"})(({theme:e,hasError:t})=>({border:`1px solid ${e.palette.divider}`,display:"flex",justifyContent:"space-between",position:"relative",paddingInline:"8px",paddingInlineStart:"0px",alignItems:"center",borderRadius:"4px",height:"40px",...t&&{border:`1px solid ${e.palette.error.main}`}})),Ue=styled(Q)(()=>({width:"50px"})),Ge=styled(qe)(({error:e})=>({border:"none",paddingInlineEnd:0,img:{cursor:"pointer"},...e&&{borderBottomLeftRadius:0,borderBottomRightRadius:0,borderBottom:"none"}})),Ke=styled("small")(({theme:e})=>({color:e.palette.error.main,fontSize:"10px",lineHeight:"10px",marginTop:"4px",display:"block"})),Je=styled(Q)(()=>({flex:1}));function Xe({amountValue:e,hasError:t,currencies:n,isCurrenciesLoading:o,currencyValue:f,onCurrencyChange:i,onAmountChange:p,onAmountBlur:l,helperText:d,required:s,...g},u){return jsxs(Je,{"data-testid":"AmountInput",children:[jsxs(Oe,{"data-testid":"AmountInput_MobileWrapper",hasError:t,children:[jsx(Ne,{isLoading:o,currencies:n,value:f,onCurrencyChange:a=>{i?.(a);},required:s}),jsx(Ue,{children:jsx(Ge,{value:e,"data-testid":"AmountInput_InputNumberStyled",ref:u,inputProps:{autoComplete:"off"},error:t,...g,onChange:a=>{p?.(a.target.value);},onBlur:a=>{l?.(a.target.value);},hideArrows:true})})]}),jsx(Ke,{children:d})]})}Xe.displayName="AmountInputBase";var Ye=je.forwardRef(Xe);var At=Ye;export{rt as a,ie as b,xt as c,_ as d,Mt as e,At as f};
@@ -1 +1 @@
1
- import {a as a$1}from'./chunk-3QA32K6H.js';import {a as a$2}from'./chunk-NKNRVF6Q.js';import {a}from'./chunk-CNIYZZCP.js';import {Ni,Li,Ji,Gi,wi,yi,Oi,vi,ui,Mi,bg,kb,zi,ib,Ai,Ci,Di,Ii,Hi,Bi}from'./chunk-N3WMUGVO.js';import h from'@mui/material/Box';import {styled}from'@mui/material/styles';import {jsx,jsxs}from'react/jsx-runtime';var k={ABANDONED:bg,IN_PROGRESS:Oi,VOID:Mi,CANCELLED:ui,CAPTURED:vi,INITIATED:Oi,FAILED:yi,DECLINED:wi,RESTRICTED:Gi,TIMEDOUT:Ji,UNKNOWN:Li,AUTHORIZED:Ni},R={UNKNOWN:{gatewayIcon:zi,acquirerIcon:kb,color:"#FF7A00",background:"#FF7A001A"},TIMEDOUT:{gatewayIcon:zi,acquirerIcon:kb,color:"#FF7A00",background:"#FFF3E5"},FAILED:{gatewayIcon:zi,acquirerIcon:kb,color:"#FF7A00",background:"#FFF3E5"},DECLINED:{gatewayIcon:Ai,acquirerIcon:ib,color:"#FF3D00",background:"#FFEAE5"},RESTRICTED:{gatewayIcon:Ai,acquirerIcon:ib,color:"#FF3D00",background:"#FFEAE5"},ABANDONED:{gatewayIcon:zi,acquirerIcon:kb,color:"#FFD600",background:"#FFFBE5"},CANCELLED:{gatewayIcon:zi,acquirerIcon:kb,color:"#FFD600",background:"#FFFBE5"},INITIATED:{color:"#8D8D94",background:"transparent",gatewayIcon:zi,acquirerIcon:kb}},z={PENDING:Di,REFUNDED:Ci},H={PENDING:{color:"#FF7A00",backgroundColor:"#FF7A000D"},REFUNDED:{color:"#4E1FD0",backgroundColor:"#4E1FD00D"}},K={PAID_OUT:Bi,SETTLED:Hi,PENDING:Ii},M={AUTHORIZED:Ni},O={CAPTURED:{color:"#1F88D0",background:"#1F88D00D"}};var L=styled(h)(()=>({display:"flex",gap:"4px",alignItems:"center",justifyContent:"center",borderRadius:"56px",padding:"2px 4px",cursor:"default"})),q=styled(a)(({theme:r})=>({color:r.palette.common.white,fontWeight:600,fontSize:"8px",padding:"3px 2.57px",borderRadius:"4px",lineHeight:"100%"}));function I({tooltip:r,status:e,statusCode:U}){let d=R[e]??O[e]??null;return jsx(a$1,{title:r,children:jsxs(L,{sx:{backgroundColor:d?.background||"transparent"},children:[jsx(a$2,{src:k[e]}),jsx(q,{sx:P=>({backgroundColor:d?.color||P.palette.info.dark}),children:U})]})})}var ro=I;export{k as a,R as b,z as c,H as d,K as e,M as f,O as g,ro as h};
1
+ import {a as a$1}from'./chunk-3QA32K6H.js';import {a as a$2}from'./chunk-NKNRVF6Q.js';import {a}from'./chunk-CNIYZZCP.js';import {Oi,Mi,Ki,Hi,xi,zi,Pi,wi,vi,Ni,bg,kb,Ai,ib,Bi,Di,Ei,Ji,Ii,Ci}from'./chunk-NK266ZWT.js';import h from'@mui/material/Box';import {styled}from'@mui/material/styles';import {jsx,jsxs}from'react/jsx-runtime';var k={ABANDONED:bg,IN_PROGRESS:Pi,VOID:Ni,CANCELLED:vi,CAPTURED:wi,INITIATED:Pi,FAILED:zi,DECLINED:xi,RESTRICTED:Hi,TIMEDOUT:Ki,UNKNOWN:Mi,AUTHORIZED:Oi},R={UNKNOWN:{gatewayIcon:Ai,acquirerIcon:kb,color:"#FF7A00",background:"#FF7A001A"},TIMEDOUT:{gatewayIcon:Ai,acquirerIcon:kb,color:"#FF7A00",background:"#FFF3E5"},FAILED:{gatewayIcon:Ai,acquirerIcon:kb,color:"#FF7A00",background:"#FFF3E5"},DECLINED:{gatewayIcon:Bi,acquirerIcon:ib,color:"#FF3D00",background:"#FFEAE5"},RESTRICTED:{gatewayIcon:Bi,acquirerIcon:ib,color:"#FF3D00",background:"#FFEAE5"},ABANDONED:{gatewayIcon:Ai,acquirerIcon:kb,color:"#FFD600",background:"#FFFBE5"},CANCELLED:{gatewayIcon:Ai,acquirerIcon:kb,color:"#FFD600",background:"#FFFBE5"},INITIATED:{color:"#8D8D94",background:"transparent",gatewayIcon:Ai,acquirerIcon:kb}},z={PENDING:Ei,REFUNDED:Di},H={PENDING:{color:"#FF7A00",backgroundColor:"#FF7A000D"},REFUNDED:{color:"#4E1FD0",backgroundColor:"#4E1FD00D"}},K={PAID_OUT:Ci,SETTLED:Ii,PENDING:Ji},M={AUTHORIZED:Oi},O={CAPTURED:{color:"#1F88D0",background:"#1F88D00D"}};var L=styled(h)(()=>({display:"flex",gap:"4px",alignItems:"center",justifyContent:"center",borderRadius:"56px",padding:"2px 4px",cursor:"default"})),q=styled(a)(({theme:r})=>({color:r.palette.common.white,fontWeight:600,fontSize:"8px",padding:"3px 2.57px",borderRadius:"4px",lineHeight:"100%"}));function I({tooltip:r,status:e,statusCode:U}){let d=R[e]??O[e]??null;return jsx(a$1,{title:r,children:jsxs(L,{sx:{backgroundColor:d?.background||"transparent"},children:[jsx(a$2,{src:k[e]}),jsx(q,{sx:P=>({backgroundColor:d?.color||P.palette.info.dark}),children:U})]})})}var ro=I;export{k as a,R as b,z as c,H as d,K as e,M as f,O as g,ro as h};
@@ -1 +1 @@
1
- import {a as a$4}from'./chunk-JAXERZJ3.js';import {a,c,e,f,b}from'./chunk-PAOJKU5D.js';import {a as a$3}from'./chunk-237EA4BW.js';import {a as a$2}from'./chunk-26YGUUXY.js';import {a as a$5}from'./chunk-R43YILB3.js';import {a as a$6}from'./chunk-NKNRVF6Q.js';import {a as a$1}from'./chunk-CNIYZZCP.js';import {Hc,w as w$1}from'./chunk-N3WMUGVO.js';import*as w from'react';import w__default,{useState,useMemo}from'react';import {useFormContext,Controller,FormProvider,useForm}from'react-hook-form';import {jsx,jsxs}from'react/jsx-runtime';import P from'@mui/material/Box';import Le from'@mui/material/Input';import {styled}from'@mui/material/styles';import {ListSubheader,Box,MenuItem}from'@mui/material';import Ke from'@mui/material/MenuItem';function Pe({onSubmit:e,methods:n,children:o}){return jsx(FormProvider,{...n,children:jsx("form",{onSubmit:e,noValidate:true,children:o})})}var Fe=w__default.memo(Pe);var J=w.forwardRef(({name:e,helperText:n,hideArrows:o,...t},l)=>{let{control:i}=useFormContext();return jsx(Controller,{name:e,control:i,defaultValue:t.defaultValue,render:({field:c,fieldState:a$1})=>jsx(a,{...t,...c,ref:l,hasError:!!a$1.error,helperText:n??a$1.error?.message,hideArrows:o,onChange:p=>{c.onChange(p),t.onChange?.(p);},onWheel:p=>{p.target instanceof HTMLElement&&p.target.blur();}})})});J.displayName="RFHFormInput";var Q=w.memo(J);var Ae=Q;function Y({phoneName:e$1,countries:n,countryName:o,helperText:t,isCountriesLoading:l,disabled:i,...c}){let{control:a,watch:p,setValue:x}=useFormContext(),h=p(o),b=u=>{x(o,u);};return jsx(Controller,{name:e$1,control:a,render:({field:{onChange:u,value:s},fieldState:f})=>jsx(e,{...c,phoneValue:s,countries:n,hasError:!!f.error,helperText:t??f.error?.message,onPhoneChange:d=>{u(d);},disabled:i,countryValue:h,onCountryChange:b,isCountriesLoading:l})})}Y.displayName="RFHPhoneInput";var Z=Y;var Ee=Z;var B=(e,n)=>e.toFixed(n);function j({amountName:e,currencies:n,currencyName:o,helperText:t,isCurrenciesLoading:l,...i}){let{control:c,watch:a,setValue:p}=useFormContext(),x=a(o),h=a(e),b=u=>{p(o,u),p(e,B(Number(h),u?.decimals||2));};return jsx(Controller,{name:e,control:c,render:({field:{onChange:u,value:s},fieldState:f$1})=>jsx(f,{...i,amountValue:s??"",currencies:n,hasError:!!f$1.error,helperText:t??f$1.error?.message,onAmountChange:d=>{u(d);},onAmountBlur:d=>{u(B(Number(d),x?.decimals||2));},currencyValue:x,onCurrencyChange:b,isCurrenciesLoading:l})})}j.displayName="RFHAmountInput";var ee=j;var We=ee;function te({name:e,helperText:n,...o}){let{control:t}=useFormContext();return jsx(Controller,{name:e,control:t,render:({field:l,fieldState:i})=>jsx(c,{...o,...l,hasError:!!i.error,helperText:n??i.error?.message})})}te.displayName="RFHSelect";var ne=w.memo(te);var k=ne;function le({name:e,disabled:n,...o}){let{control:t}=useFormContext();return jsx(Controller,{name:e,control:t,render:({field:{name:l,onBlur:i,onChange:c,value:a,disabled:p}})=>jsx(a$3,{...o,onChange:c,onBlur:i,name:l,disabled:p||n,checked:a??false})})}le.displayName="RFHSWitch";var ie=w.memo(le);var Te=ie;var me=styled(a$1)(({theme:e})=>({fontSize:"10px",color:e.palette.grey[700],fontWeight:600,lineHeight:"10px"}));styled(a$1)(({theme:e})=>({fontSize:"11px",color:e.palette.text.primary,fontWeight:600,lineHeight:"14.3px",width:200}));var se=styled(P)(()=>({display:"flex",flexDirection:"column",maxHeight:180,overflow:"auto",scrollbarWidth:"thin",scrollbarColor:"#E5E5E5 #E5E5E5"}));styled(Le)(({theme:e})=>({width:"inherit",height:32,padding:"11px 12px",fontSize:"10px",borderRadius:"5px",backgroundColor:"#F9F9F9",border:"1px solid transparent","&.Mui-focused":{borderColor:e.palette.info.dark}}));var ce=styled(P)(()=>({display:"flex",flexDirection:"column",gap:"8px"}));styled(P)(()=>({display:"flex",gap:"8px",padding:"4px",flexWrap:"wrap",paddingInlineEnd:"20px"}));styled(P)(({theme:e,maxWidth:n})=>({display:"flex",padding:"4px 8px 4px 6px",alignItems:"center",gap:"4px",borderRadius:"13px",backgroundColor:`${e.palette.info.dark}1a`,fontSize:"10px",fontWeight:500,cursor:"pointer",...n&&{maxWidth:`${n}%`}}));var ue=styled(a$1)(({theme:e})=>({display:"flex",gap:"8px",alignItems:"center",justifyContent:"space-between",fontSize:"10px",fontWeight:500,color:e.palette.common.black,cursor:"pointer",padding:"8px 20px"}));styled(P)(({theme:e})=>({width:"100%",flexDirection:"column",border:`1px solid ${e.palette.grey[100]}`,borderRadius:"4px",backgroundColor:e.palette.grey[400]}));function $e({name:e,options:n,...o}){let[t,l]=useState(null),[i,c]=useState(0),a=!!t,p=s=>{l(a?null:s.currentTarget);},x=()=>{l(null);},{watch:h,setValue:b}=useFormContext(),u=h(e);return jsx(a$4,{open:a,anchorEl:t,onOpen:p,onClose:x,trigger:jsx(k,{name:e,options:[],...o,open:false}),hideArrow:true,listWrapperSx:{padding:0,margin:0},children:jsx(ce,{children:jsx(se,{"data-testid":"AccordionWrapper",children:n.map?.((s,f)=>{let d=i===f;return jsx(a$5,{Header:jsx(me,{variant:"caption",children:s.group}),defaultExpanded:true,sx:{flexShrink:0,border:0,...d&&{borderBottom:"1px solid #0000001A",borderTop:"1px solid #0000001A"}},summarySx:{backgroundColor:d?"#F8F8F8":"#ffffff",borderBottom:"1px solid #0000001A",minHeight:28},expanded:d,onChange:(m,g)=>{m.stopPropagation(),m.preventDefault(),c(g?f:null);},children:(s?.options||[]).map((m,g)=>{let r=o?.isOptionEqualToValue?.(m,u);return jsxs(ue,{onClick:()=>{b(e,m,{shouldDirty:true,shouldTouch:true,shouldValidate:true}),x();},children:[o.renderOption?.(m)||m.label,r&&jsx(a$6,{src:Hc,alt:"blue-check",sx:{width:14,height:10}})]},`${m.value}-${m.label}-${g}`)})},`${s.group}-group-${f}`)})})})})}var fe=$e;var Ue=fe;var xe=styled(a$2)(()=>({padding:0,".MuiSvgIcon-root":{width:12,height:12}})),he=styled(Le)(({theme:e})=>({width:"100%",height:36,padding:"8px 8px 8px 12px",borderRadius:4,backgroundColor:e.palette.common.white,border:"1px solid #F2F2F2",boxSizing:"border-box","&:hover":{borderColor:"#F2F2F2"},"&.Mui-focused":{borderColor:"#F2F2F2",backgroundColor:e.palette.common.white},"&:before, &:after":{display:"none"},"& input":{padding:0,fontSize:10},"& .MuiInputBase-input":{paddingRight:4}}));styled(Ke)(({theme:e})=>({opacity:1,paddingTop:0,paddingBottom:0,marginBottom:8,minHeight:"auto",pointerEvents:"none",backgroundColor:e.palette.common.white,"&:hover":{backgroundColor:e.palette.common.white},"&.Mui-focusVisible":{backgroundColor:e.palette.common.white},"&.Mui-disabled":{backgroundColor:e.palette.common.white,opacity:1}}));function M({name:e,helperText:n,getOptionValue:o,getOptionLabel:t,renderOption:l,isOptionEqualToValue:i,getOptionDisabled:c,showSearchInput:a=false,searchPlaceholder:p="Search",showCheckbox:x=true,options:h,...b$1}){let{control:u}=useFormContext(),[s,f]=useState(""),d=useMemo(()=>{if(!a||!s.trim())return h??[];let m=s.toLowerCase().trim();return (h??[]).filter(g=>{let r=(t?t(g):g?.label)??"";return String(r).toLowerCase().includes(m)})},[h,a,s,t]);return jsx(Controller,{name:e,control:u,defaultValue:[],render:({field:m,fieldState:g})=>jsxs(b,{...b$1,...m,options:d,getOptionLabel:t,hasError:!!g.error,helperText:n??g.error?.message,onChange:r=>m.onChange(r),MenuProps:{...b$1.MenuProps,autoFocus:false,disableEnforceFocus:true},children:[a&&jsx(ListSubheader,{disableSticky:true,sx:{backgroundColor:"#fff",pt:1,pb:1},children:jsx(he,{placeholder:p,value:s,onChange:r=>f(r.target.value),onKeyDown:r=>r.stopPropagation(),onKeyUp:r=>r.stopPropagation(),disableUnderline:true,fullWidth:true,inputProps:{"aria-label":p},endAdornment:jsx(Box,{component:"img",src:w$1,alt:"search",sx:{width:14,height:14,flexShrink:0}})})}),d?.map(r=>{let A=m.value?.some(F=>i?i(F,r):F?.id===r?.id),R=c?c(r):false,be=t?t(r):r.label,W=l?l(r):be;return jsx(MenuItem,{value:(o?o(r):r?.id)??"",disabled:R,sx:{fontSize:"12px",backgroundColor:F=>A?"#F8F8F8 !important":F.palette.common.white,"&.Mui-disabled":{opacity:1}},children:x?jsxs(Box,{sx:{display:"flex",alignItems:"center",width:"100%",gap:"8px"},children:[jsx(xe,{checked:A,sx:{...A&&R&&{"& svg rect":{fill:"#BDC1CC"}}}}),W]}):W},(o?o(r):r?.id)??"")})]})})}var Ze=M;var je=useForm;export{Fe as a,Ae as b,Ee as c,We as d,k as e,Te as f,Ue as g,Ze as h,je as i};
1
+ import {a as a$4}from'./chunk-APIJ4QLV.js';import {a,c,e,f,b}from'./chunk-4Q2P3FSI.js';import {a as a$3}from'./chunk-237EA4BW.js';import {a as a$2}from'./chunk-3RB7SOD6.js';import {a as a$5}from'./chunk-ARP7EMGQ.js';import {a as a$6}from'./chunk-NKNRVF6Q.js';import {a as a$1}from'./chunk-CNIYZZCP.js';import {Hc,w as w$1}from'./chunk-NK266ZWT.js';import*as w from'react';import w__default,{useState,useMemo}from'react';import {useFormContext,Controller,FormProvider,useForm}from'react-hook-form';import {jsx,jsxs}from'react/jsx-runtime';import P from'@mui/material/Box';import Le from'@mui/material/Input';import {styled}from'@mui/material/styles';import {ListSubheader,Box,MenuItem}from'@mui/material';import Ke from'@mui/material/MenuItem';function Pe({onSubmit:e,methods:n,children:o}){return jsx(FormProvider,{...n,children:jsx("form",{onSubmit:e,noValidate:true,children:o})})}var Fe=w__default.memo(Pe);var J=w.forwardRef(({name:e,helperText:n,hideArrows:o,...t},l)=>{let{control:i}=useFormContext();return jsx(Controller,{name:e,control:i,defaultValue:t.defaultValue,render:({field:c,fieldState:a$1})=>jsx(a,{...t,...c,ref:l,hasError:!!a$1.error,helperText:n??a$1.error?.message,hideArrows:o,onChange:p=>{c.onChange(p),t.onChange?.(p);},onWheel:p=>{p.target instanceof HTMLElement&&p.target.blur();}})})});J.displayName="RFHFormInput";var Q=w.memo(J);var Ae=Q;function Y({phoneName:e$1,countries:n,countryName:o,helperText:t,isCountriesLoading:l,disabled:i,...c}){let{control:a,watch:p,setValue:x}=useFormContext(),h=p(o),b=u=>{x(o,u);};return jsx(Controller,{name:e$1,control:a,render:({field:{onChange:u,value:s},fieldState:f})=>jsx(e,{...c,phoneValue:s,countries:n,hasError:!!f.error,helperText:t??f.error?.message,onPhoneChange:d=>{u(d);},disabled:i,countryValue:h,onCountryChange:b,isCountriesLoading:l})})}Y.displayName="RFHPhoneInput";var Z=Y;var Ee=Z;var B=(e,n)=>e.toFixed(n);function j({amountName:e,currencies:n,currencyName:o,helperText:t,isCurrenciesLoading:l,...i}){let{control:c,watch:a,setValue:p}=useFormContext(),x=a(o),h=a(e),b=u=>{p(o,u),p(e,B(Number(h),u?.decimals||2));};return jsx(Controller,{name:e,control:c,render:({field:{onChange:u,value:s},fieldState:f$1})=>jsx(f,{...i,amountValue:s??"",currencies:n,hasError:!!f$1.error,helperText:t??f$1.error?.message,onAmountChange:d=>{u(d);},onAmountBlur:d=>{u(B(Number(d),x?.decimals||2));},currencyValue:x,onCurrencyChange:b,isCurrenciesLoading:l})})}j.displayName="RFHAmountInput";var ee=j;var We=ee;function te({name:e,helperText:n,...o}){let{control:t}=useFormContext();return jsx(Controller,{name:e,control:t,render:({field:l,fieldState:i})=>jsx(c,{...o,...l,hasError:!!i.error,helperText:n??i.error?.message})})}te.displayName="RFHSelect";var ne=w.memo(te);var k=ne;function le({name:e,disabled:n,...o}){let{control:t}=useFormContext();return jsx(Controller,{name:e,control:t,render:({field:{name:l,onBlur:i,onChange:c,value:a,disabled:p}})=>jsx(a$3,{...o,onChange:c,onBlur:i,name:l,disabled:p||n,checked:a??false})})}le.displayName="RFHSWitch";var ie=w.memo(le);var Te=ie;var me=styled(a$1)(({theme:e})=>({fontSize:"10px",color:e.palette.grey[700],fontWeight:600,lineHeight:"10px"}));styled(a$1)(({theme:e})=>({fontSize:"11px",color:e.palette.text.primary,fontWeight:600,lineHeight:"14.3px",width:200}));var se=styled(P)(()=>({display:"flex",flexDirection:"column",maxHeight:180,overflow:"auto",scrollbarWidth:"thin",scrollbarColor:"#E5E5E5 #E5E5E5"}));styled(Le)(({theme:e})=>({width:"inherit",height:32,padding:"11px 12px",fontSize:"10px",borderRadius:"5px",backgroundColor:"#F9F9F9",border:"1px solid transparent","&.Mui-focused":{borderColor:e.palette.info.dark}}));var ce=styled(P)(()=>({display:"flex",flexDirection:"column",gap:"8px"}));styled(P)(()=>({display:"flex",gap:"8px",padding:"4px",flexWrap:"wrap",paddingInlineEnd:"20px"}));styled(P)(({theme:e,maxWidth:n})=>({display:"flex",padding:"4px 8px 4px 6px",alignItems:"center",gap:"4px",borderRadius:"13px",backgroundColor:`${e.palette.info.dark}1a`,fontSize:"10px",fontWeight:500,cursor:"pointer",...n&&{maxWidth:`${n}%`}}));var ue=styled(a$1)(({theme:e})=>({display:"flex",gap:"8px",alignItems:"center",justifyContent:"space-between",fontSize:"10px",fontWeight:500,color:e.palette.common.black,cursor:"pointer",padding:"8px 20px"}));styled(P)(({theme:e})=>({width:"100%",flexDirection:"column",border:`1px solid ${e.palette.grey[100]}`,borderRadius:"4px",backgroundColor:e.palette.grey[400]}));function $e({name:e,options:n,...o}){let[t,l]=useState(null),[i,c]=useState(0),a=!!t,p=s=>{l(a?null:s.currentTarget);},x=()=>{l(null);},{watch:h,setValue:b}=useFormContext(),u=h(e);return jsx(a$4,{open:a,anchorEl:t,onOpen:p,onClose:x,trigger:jsx(k,{name:e,options:[],...o,open:false}),hideArrow:true,listWrapperSx:{padding:0,margin:0},children:jsx(ce,{children:jsx(se,{"data-testid":"AccordionWrapper",children:n.map?.((s,f)=>{let d=i===f;return jsx(a$5,{Header:jsx(me,{variant:"caption",children:s.group}),defaultExpanded:true,sx:{flexShrink:0,border:0,...d&&{borderBottom:"1px solid #0000001A",borderTop:"1px solid #0000001A"}},summarySx:{backgroundColor:d?"#F8F8F8":"#ffffff",borderBottom:"1px solid #0000001A",minHeight:28},expanded:d,onChange:(m,g)=>{m.stopPropagation(),m.preventDefault(),c(g?f:null);},children:(s?.options||[]).map((m,g)=>{let r=o?.isOptionEqualToValue?.(m,u);return jsxs(ue,{onClick:()=>{b(e,m,{shouldDirty:true,shouldTouch:true,shouldValidate:true}),x();},children:[o.renderOption?.(m)||m.label,r&&jsx(a$6,{src:Hc,alt:"blue-check",sx:{width:14,height:10}})]},`${m.value}-${m.label}-${g}`)})},`${s.group}-group-${f}`)})})})})}var fe=$e;var Ue=fe;var xe=styled(a$2)(()=>({padding:0,".MuiSvgIcon-root":{width:12,height:12}})),he=styled(Le)(({theme:e})=>({width:"100%",height:36,padding:"8px 8px 8px 12px",borderRadius:4,backgroundColor:e.palette.common.white,border:"1px solid #F2F2F2",boxSizing:"border-box","&:hover":{borderColor:"#F2F2F2"},"&.Mui-focused":{borderColor:"#F2F2F2",backgroundColor:e.palette.common.white},"&:before, &:after":{display:"none"},"& input":{padding:0,fontSize:10},"& .MuiInputBase-input":{paddingRight:4}}));styled(Ke)(({theme:e})=>({opacity:1,paddingTop:0,paddingBottom:0,marginBottom:8,minHeight:"auto",pointerEvents:"none",backgroundColor:e.palette.common.white,"&:hover":{backgroundColor:e.palette.common.white},"&.Mui-focusVisible":{backgroundColor:e.palette.common.white},"&.Mui-disabled":{backgroundColor:e.palette.common.white,opacity:1}}));function M({name:e,helperText:n,getOptionValue:o,getOptionLabel:t,renderOption:l,isOptionEqualToValue:i,getOptionDisabled:c,showSearchInput:a=false,searchPlaceholder:p="Search",showCheckbox:x=true,options:h,...b$1}){let{control:u}=useFormContext(),[s,f]=useState(""),d=useMemo(()=>{if(!a||!s.trim())return h??[];let m=s.toLowerCase().trim();return (h??[]).filter(g=>{let r=(t?t(g):g?.label)??"";return String(r).toLowerCase().includes(m)})},[h,a,s,t]);return jsx(Controller,{name:e,control:u,defaultValue:[],render:({field:m,fieldState:g})=>jsxs(b,{...b$1,...m,options:d,getOptionLabel:t,hasError:!!g.error,helperText:n??g.error?.message,onChange:r=>m.onChange(r),MenuProps:{...b$1.MenuProps,autoFocus:false,disableEnforceFocus:true},children:[a&&jsx(ListSubheader,{disableSticky:true,sx:{backgroundColor:"#fff",pt:1,pb:1},children:jsx(he,{placeholder:p,value:s,onChange:r=>f(r.target.value),onKeyDown:r=>r.stopPropagation(),onKeyUp:r=>r.stopPropagation(),disableUnderline:true,fullWidth:true,inputProps:{"aria-label":p},endAdornment:jsx(Box,{component:"img",src:w$1,alt:"search",sx:{width:14,height:14,flexShrink:0}})})}),d?.map(r=>{let A=m.value?.some(F=>i?i(F,r):F?.id===r?.id),R=c?c(r):false,be=t?t(r):r.label,W=l?l(r):be;return jsx(MenuItem,{value:(o?o(r):r?.id)??"",disabled:R,sx:{fontSize:"12px",backgroundColor:F=>A?"#F8F8F8 !important":F.palette.common.white,"&.Mui-disabled":{opacity:1}},children:x?jsxs(Box,{sx:{display:"flex",alignItems:"center",width:"100%",gap:"8px"},children:[jsx(xe,{checked:A,sx:{...A&&R&&{"& svg rect":{fill:"#BDC1CC"}}}}),W]}):W},(o?o(r):r?.id)??"")})]})})}var Ze=M;var je=useForm;export{Fe as a,Ae as b,Ee as c,We as d,k as e,Te as f,Ue as g,Ze as h,je as i};
@@ -1 +1 @@
1
- import {a}from'./chunk-KW7XUEXS.js';import {Bc,J,ab}from'./chunk-IYZWNIGG.js';import {yl}from'./chunk-N3WMUGVO.js';import {useState,useMemo}from'react';import {ResponsiveContainer,AreaChart,Area,Tooltip}from'recharts';import {useTheme}from'@mui/material/styles';import {useTranslation}from'react-i18next';import S from'dayjs';import U from'@mui/material/Box';import {styled,Box,Typography}from'@mui/material';import {jsxs,jsx}from'react/jsx-runtime';var M=styled(Box)(()=>({width:"auto",display:"inline-block",whiteSpace:"nowrap",backgroundColor:"white",padding:"6px",border:"1.5px solid #E6E6E6",borderRadius:"7.5px",backdropFilter:"blur(23.280000686645508px)",boxShadow:"0px 0px 15.52px 0px #4B484729"})),b=styled(Typography)({width:"auto",marginBottom:"4px",fontWeight:500,color:"#4B4847ED",fontSize:"9px",whiteSpace:"nowrap",overflow:"visible"}),w=styled(Typography)({display:"flex",alignItems:"center",gap:"5px",fontWeight:600,color:"#4B4847",fontSize:11,whiteSpace:"nowrap",overflow:"visible",width:"auto"}),K=styled(Box)({display:"flex",alignItems:"center",height:"100%",gap:"2.6px",maxHeight:"19px"}),B=styled(Typography)({fontWeight:500,fontSize:11,lineHeight:"130%",color:"#4B4847",letterSpacing:"-0.14px"});var L=(t,i,r)=>t?.value===void 0||t?.value===null?"":t?.dataKey===yl.AMOUNT?`${ab(t.value,r).fullAmount}`.trim():`${t.value.toLocaleString()} ${i}`.trim(),W=(t,i,r=0)=>{let a=S(t).add(r,"hour").format(),n=new Date,o=S(a).isSame(n,"year");return J(a,i?void 0:{sameDay:`[Today] ${o?"":"YYYY"}`,nextDay:`[Tomorrow] ${o?"":"YYYY"}`,lastDay:`[Yesterday] ${o?"":"YYYY"}`,sameElse:`MMM DD ${o?"":", YYYY"}`,lastWeek:`MMM DD ${o?"":", YYYY"}`,nextWeek:`MMM DD ${o?"":", YYYY"}`},void 0,void 0,r!==void 0)};var V=({active:t,payload:i,dateRange:r,selectedCurrency:a$1})=>{let{t:n}=useTranslation(),o=S(r?.[0]),u=S(r?.[1]),d=o?.isSame(u,"day");if(t&&i?.length){let e=i[0],f=Bc(e?.dataKey,e?.value),y=e?.payload?.date&&W(e?.payload?.date,d,e?.payload?.hour);return jsxs(M,{className:"chart-tooltip",children:[jsx(b,{children:y??e?.payload?.date}),jsxs(w,{children:[e?.dataKey===yl.AMOUNT&&jsxs(K,{children:[jsx(a,{currencyCode:a$1,width:12}),jsx(B,{children:a$1})]}),jsx(U,{children:`${L(e,n(f),a$1)}`})]})]})}return null},x=V;var N=[{dataKey:30},{dataKey:32.9941},{dataKey:39.0471},{dataKey:56.3412},{dataKey:69.3118},{dataKey:87.4706},{dataKey:94.3882},{dataKey:110.406}],j=()=>jsx(ResponsiveContainer,{children:jsxs(AreaChart,{margin:{top:40},data:N,children:[jsx("defs",{children:jsxs("linearGradient",{id:"loadingGradient",x1:"0",y1:"0",x2:"0",y2:"1",gradientUnits:"objectBoundingBox",children:[jsx("stop",{offset:"0.54",stopColor:"rgba(67, 67, 67, 0.035)"}),jsx("stop",{offset:"1",stopColor:"rgba(255, 255, 255, 0)"})]})}),jsx(Area,{dataKey:"dataKey",type:"linear",fill:"url(#loadingGradient)",fillOpacity:1,stroke:"#C2C2C2",strokeWidth:1,strokeLinecap:"round",strokeDasharray:"4 4",activeDot:false})]})}),T=j;var tt=({data:t,dataKey:i,isLoading:r,dateRange:a,selectedCurrency:n})=>{let o=useTheme(),[u,d]=useState(false),[e,f]=useState({x:0,y:0}),y=t?.length===0,P=h=>{h.activeCoordinate&&h.isTooltipActive&&f(h.activeCoordinate);},O=useMemo(()=>jsx(x,{position:e,dateRange:a,selectedCurrency:n}),[e,a,n]);return r||y?jsx(T,{}):jsx(ResponsiveContainer,{children:jsxs(AreaChart,{margin:{top:20},data:t,onMouseMove:P,children:[t.length>0&&jsx(Tooltip,{content:O,cursor:{fill:"#A5A8A3",stroke:"#A5A8A3",strokeWidth:1,strokeOpacity:1,stopOpacity:.3,strokeDasharray:"5 5",strokeLinecap:"round",strokeLinejoin:"round"}}),jsx(Area,{dataKey:i,type:"monotone",fill:"#76BB4012",stroke:o.palette.success.dark,activeDot:{r:5,fill:o.palette.success.dark,strokeWidth:2,stroke:"white",cursor:u?"pointer":"default",onMouseOver:()=>d(true),onMouseLeave:()=>d(false)}})]})})},E=tt;var St=E;export{x as a,T as b,St as c};
1
+ import {a}from'./chunk-TZWXCSB4.js';import {Dc,J,cb}from'./chunk-MRFF7D7J.js';import {Al}from'./chunk-NK266ZWT.js';import {useState,useMemo}from'react';import {ResponsiveContainer,AreaChart,Area,Tooltip}from'recharts';import {useTheme}from'@mui/material/styles';import {useTranslation}from'react-i18next';import S from'dayjs';import U from'@mui/material/Box';import {styled,Box,Typography}from'@mui/material';import {jsxs,jsx}from'react/jsx-runtime';var M=styled(Box)(()=>({width:"auto",display:"inline-block",whiteSpace:"nowrap",backgroundColor:"white",padding:"6px",border:"1.5px solid #E6E6E6",borderRadius:"7.5px",backdropFilter:"blur(23.280000686645508px)",boxShadow:"0px 0px 15.52px 0px #4B484729"})),b=styled(Typography)({width:"auto",marginBottom:"4px",fontWeight:500,color:"#4B4847ED",fontSize:"9px",whiteSpace:"nowrap",overflow:"visible"}),w=styled(Typography)({display:"flex",alignItems:"center",gap:"5px",fontWeight:600,color:"#4B4847",fontSize:11,whiteSpace:"nowrap",overflow:"visible",width:"auto"}),K=styled(Box)({display:"flex",alignItems:"center",height:"100%",gap:"2.6px",maxHeight:"19px"}),B=styled(Typography)({fontWeight:500,fontSize:11,lineHeight:"130%",color:"#4B4847",letterSpacing:"-0.14px"});var L=(t,i,r)=>t?.value===void 0||t?.value===null?"":t?.dataKey===Al.AMOUNT?`${cb(t.value,r).fullAmount}`.trim():`${t.value.toLocaleString()} ${i}`.trim(),W=(t,i,r=0)=>{let a=S(t).add(r,"hour").format(),n=new Date,o=S(a).isSame(n,"year");return J(a,i?void 0:{sameDay:`[Today] ${o?"":"YYYY"}`,nextDay:`[Tomorrow] ${o?"":"YYYY"}`,lastDay:`[Yesterday] ${o?"":"YYYY"}`,sameElse:`MMM DD ${o?"":", YYYY"}`,lastWeek:`MMM DD ${o?"":", YYYY"}`,nextWeek:`MMM DD ${o?"":", YYYY"}`},void 0,void 0,r!==void 0)};var V=({active:t,payload:i,dateRange:r,selectedCurrency:a$1})=>{let{t:n}=useTranslation(),o=S(r?.[0]),u=S(r?.[1]),d=o?.isSame(u,"day");if(t&&i?.length){let e=i[0],f=Dc(e?.dataKey,e?.value),y=e?.payload?.date&&W(e?.payload?.date,d,e?.payload?.hour);return jsxs(M,{className:"chart-tooltip",children:[jsx(b,{children:y??e?.payload?.date}),jsxs(w,{children:[e?.dataKey===Al.AMOUNT&&jsxs(K,{children:[jsx(a,{currencyCode:a$1,width:12}),jsx(B,{children:a$1})]}),jsx(U,{children:`${L(e,n(f),a$1)}`})]})]})}return null},x=V;var N=[{dataKey:30},{dataKey:32.9941},{dataKey:39.0471},{dataKey:56.3412},{dataKey:69.3118},{dataKey:87.4706},{dataKey:94.3882},{dataKey:110.406}],j=()=>jsx(ResponsiveContainer,{children:jsxs(AreaChart,{margin:{top:40},data:N,children:[jsx("defs",{children:jsxs("linearGradient",{id:"loadingGradient",x1:"0",y1:"0",x2:"0",y2:"1",gradientUnits:"objectBoundingBox",children:[jsx("stop",{offset:"0.54",stopColor:"rgba(67, 67, 67, 0.035)"}),jsx("stop",{offset:"1",stopColor:"rgba(255, 255, 255, 0)"})]})}),jsx(Area,{dataKey:"dataKey",type:"linear",fill:"url(#loadingGradient)",fillOpacity:1,stroke:"#C2C2C2",strokeWidth:1,strokeLinecap:"round",strokeDasharray:"4 4",activeDot:false})]})}),T=j;var tt=({data:t,dataKey:i,isLoading:r,dateRange:a,selectedCurrency:n})=>{let o=useTheme(),[u,d]=useState(false),[e,f]=useState({x:0,y:0}),y=t?.length===0,P=h=>{h.activeCoordinate&&h.isTooltipActive&&f(h.activeCoordinate);},O=useMemo(()=>jsx(x,{position:e,dateRange:a,selectedCurrency:n}),[e,a,n]);return r||y?jsx(T,{}):jsx(ResponsiveContainer,{children:jsxs(AreaChart,{margin:{top:20},data:t,onMouseMove:P,children:[t.length>0&&jsx(Tooltip,{content:O,cursor:{fill:"#A5A8A3",stroke:"#A5A8A3",strokeWidth:1,strokeOpacity:1,stopOpacity:.3,strokeDasharray:"5 5",strokeLinecap:"round",strokeLinejoin:"round"}}),jsx(Area,{dataKey:i,type:"monotone",fill:"#76BB4012",stroke:o.palette.success.dark,activeDot:{r:5,fill:o.palette.success.dark,strokeWidth:2,stroke:"white",cursor:u?"pointer":"default",onMouseOver:()=>d(true),onMouseLeave:()=>d(false)}})]})})},E=tt;var St=E;export{x as a,T as b,St as c};
@@ -1 +1 @@
1
- import {Eg,Fg}from'./chunk-N3WMUGVO.js';import {styled,Box}from'@mui/material';import v,{useMemo}from'react';import {jsx,jsxs}from'react/jsx-runtime';var c=styled(Box)(({theme:e})=>({height:"32px",borderRadius:"4px",backgroundColor:e.palette.action.hover,padding:"2px",display:"flex",alignItems:"center",position:"relative",cursor:"pointer"})),d=styled(Box,{shouldForwardProp:e=>e!=="isActive"})(({isActive:e})=>({flex:1,display:"flex",justifyContent:"center",alignItems:"center",position:"relative",zIndex:2,opacity:e?1:.5})),u=styled(Box,{shouldForwardProp:e=>e!=="activeIndex"})(({theme:e,activeIndex:o})=>({position:"absolute",top:2,left:o*30+2,transition:"all 0.25s ease-in-out",width:"28px",height:"28px",backgroundColor:e.palette.common.white,borderRadius:"2px",boxShadow:"0px 0px 4px 0px rgba(0, 0, 0, 0.20)"}));var x=(t=>(t.LIST="LIST",t.CARDS="CARDS",t.MAP="MAP",t))(x||{});var h=e=>{let o=v.Children.count(e.children)-1;return jsx(c,{...e,sx:{width:o*30+2}})},m=h;var V=[{icon:jsx("img",{src:Eg,alt:"card"}),value:"CARDS"},{icon:jsx("img",{src:Fg,alt:"LIST"}),value:"LIST"}],y=e=>{let{currentView:o,onToggleClick:a,getOverrideViews:t}=e,l=useMemo(()=>t?t(V):V,[t]),f=useMemo(()=>l.findIndex(r=>r.value===o),[l,o]);return a?jsxs(m,{children:[l.map(r=>jsx(d,{onClick:()=>a(r.value),sx:{height:"11.6px",width:"11.6px"},isActive:o===r.value,children:r.icon},r.value)),jsx(u,{activeIndex:f})]}):null},T=y;var M=T;export{x as a,M as b};
1
+ import {Eg,Fg}from'./chunk-NK266ZWT.js';import {styled,Box}from'@mui/material';import v,{useMemo}from'react';import {jsx,jsxs}from'react/jsx-runtime';var c=styled(Box)(({theme:e})=>({height:"32px",borderRadius:"4px",backgroundColor:e.palette.action.hover,padding:"2px",display:"flex",alignItems:"center",position:"relative",cursor:"pointer"})),d=styled(Box,{shouldForwardProp:e=>e!=="isActive"})(({isActive:e})=>({flex:1,display:"flex",justifyContent:"center",alignItems:"center",position:"relative",zIndex:2,opacity:e?1:.5})),u=styled(Box,{shouldForwardProp:e=>e!=="activeIndex"})(({theme:e,activeIndex:o})=>({position:"absolute",top:2,left:o*30+2,transition:"all 0.25s ease-in-out",width:"28px",height:"28px",backgroundColor:e.palette.common.white,borderRadius:"2px",boxShadow:"0px 0px 4px 0px rgba(0, 0, 0, 0.20)"}));var x=(t=>(t.LIST="LIST",t.CARDS="CARDS",t.MAP="MAP",t))(x||{});var h=e=>{let o=v.Children.count(e.children)-1;return jsx(c,{...e,sx:{width:o*30+2}})},m=h;var V=[{icon:jsx("img",{src:Eg,alt:"card"}),value:"CARDS"},{icon:jsx("img",{src:Fg,alt:"LIST"}),value:"LIST"}],y=e=>{let{currentView:o,onToggleClick:a,getOverrideViews:t}=e,l=useMemo(()=>t?t(V):V,[t]),f=useMemo(()=>l.findIndex(r=>r.value===o),[l,o]);return a?jsxs(m,{children:[l.map(r=>jsx(d,{onClick:()=>a(r.value),sx:{height:"11.6px",width:"11.6px"},isActive:o===r.value,children:r.icon},r.value)),jsx(u,{activeIndex:f})]}):null},T=y;var M=T;export{x as a,M as b};