master-components-react 1.18.7 → 1.18.10

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.
@@ -28,7 +28,7 @@ Check the top-level render call using <`+Ve+">.")}return Te}}function td(Z,Te){{
28
28
  <%s {...props} />
29
29
  React keys must be passed directly to JSX without using spread:
30
30
  let props = %s;
31
- <%s key={someKey} {...props} />`,mf,Da,Uk,Da),Aa[Da+mf]=!0}}return Z===n?gf(si):_f(si),si}}function $k(Z,Te,Ve){return fr(Z,Te,Ve,!0)}function Wk(Z,Te,Ve){return fr(Z,Te,Ve,!1)}var zk=Wk,Gk=$k;zs.Fragment=n,zs.jsx=zk,zs.jsxs=Gk}()),zs}process.env.NODE_ENV==="production"?n_.exports=jk():n_.exports=qk();var R=n_.exports;const Yk="MainButton-module__mainButton",Xk="MainButton-module__sm",Zk="MainButton-module__onlyIcon",Qk="MainButton-module__buttonSlot",Jk="MainButton-module__buttonLabel",eB="MainButton-module__md",tB="MainButton-module__lg",iB="MainButton-module__xl",nB="MainButton-module__xl2",rB="MainButton-module__disabled",Bo={mainButton:Yk,sm:Xk,onlyIcon:Zk,buttonSlot:Qk,buttonLabel:Jk,md:eB,lg:tB,xl:iB,xl2:nB,disabled:rB},Jl=({label:e,buttonType:t="button",onClick:i,size:n="md",disabled:r,withIcons:a,iconOne:o,iconTwo:s,onlyIcon:l,buttonStyle:u,labelStyle:d,buttonSlotStyle:c})=>R.jsx("button",{type:t,style:u&&typeof u=="object"?u:{},className:`${Bo.mainButton} ${l?Bo.onlyIcon:""} ${n?Bo[n]:""} ${r?Bo.disabled:""}`,onClick:()=>{i&&typeof i=="function"&&i()},children:R.jsxs("div",{className:Bo.buttonSlot,style:c??{},children:[l||a&&o?o:"",!l&&R.jsx("span",{style:d??{},className:Bo.buttonLabel,children:e??"Button"}),a&&s?s:""]})}),aB="FormInput-module__inputWrapper",oB="FormInput-module__inputLabel",sB="FormInput-module__required",lB="FormInput-module__inputContainer",uB="FormInput-module__inputContent",dB="FormInput-module__inputTags",cB="FormInput-module__focused",hB="FormInput-module__error",fB="FormInput-module__rightIcon",pB="FormInput-module__leftIcon",vB="FormInput-module__inputDropDown",_B="FormInput-module__http",gB="FormInput-module__disabled",mB="FormInput-module__sm",CB="FormInput-module__md",yB="FormInput-module__withCopy",xB="FormInput-module__inputHelperText",ci={inputWrapper:aB,inputLabel:oB,required:sB,inputContainer:lB,inputContent:uB,inputTags:dB,focused:cB,error:hB,rightIcon:fB,leftIcon:pB,inputDropDown:vB,http:_B,disabled:gB,sm:mB,md:CB,withCopy:yB,inputHelperText:xB},Sh=({width:e,height:t,color:i})=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"12",height:t??"8",viewBox:"0 0 12 8",fill:"none",children:R.jsx("path",{d:"M1 1.5L6 6.5L11 1.5",stroke:i??"#A4A7AE",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),bB=({width:e,height:t,color:i})=>R.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"20",height:t??"20",viewBox:"0 0 20 20",fill:"none",children:[R.jsx("g",{clipPath:"url(#clip0_444_26)",children:R.jsx("path",{d:"M4.1665 12.5C3.38993 12.5 3.00165 12.5 2.69536 12.3732C2.28698 12.204 1.96253 11.8795 1.79337 11.4712C1.6665 11.1649 1.6665 10.7766 1.6665 10V4.33335C1.6665 3.39993 1.6665 2.93322 1.84816 2.5767C2.00795 2.2631 2.26292 2.00813 2.57652 1.84834C2.93304 1.66669 3.39975 1.66669 4.33317 1.66669H9.99984C10.7764 1.66669 11.1647 1.66669 11.471 1.79355C11.8794 1.96271 12.2038 2.28717 12.373 2.69555C12.4998 3.00183 12.4998 3.39012 12.4998 4.16669M10.1665 18.3334H15.6665C16.5999 18.3334 17.0666 18.3334 17.4232 18.1517C17.7368 17.9919 17.9917 17.7369 18.1515 17.4233C18.3332 17.0668 18.3332 16.6001 18.3332 15.6667V10.1667C18.3332 9.23327 18.3332 8.76656 18.1515 8.41004C17.9917 8.09643 17.7368 7.84147 17.4232 7.68168C17.0666 7.50002 16.5999 7.50002 15.6665 7.50002H10.1665C9.23308 7.50002 8.76637 7.50002 8.40985 7.68168C8.09625 7.84147 7.84128 8.09643 7.68149 8.41004C7.49984 8.76656 7.49984 9.23327 7.49984 10.1667V15.6667C7.49984 16.6001 7.49984 17.0668 7.68149 17.4233C7.84128 17.7369 8.09625 17.9919 8.40985 18.1517C8.76637 18.3334 9.23308 18.3334 10.1665 18.3334Z",stroke:i??"#414651",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),R.jsx("defs",{children:R.jsx("clipPath",{id:"clip0_444_26",children:R.jsx("rect",{width:"20",height:"20",fill:"white"})})})]}),gu=e=>R.jsx("svg",{xmlns:e.xmlns??"http://www.w3.org/2000/svg",width:e.width??"14",height:e.height??"14",viewBox:e.viewBox??"0 0 14 14",fill:e.fill??"none",children:R.jsx("path",{d:e.d??"M10.5 3.5L3.5 10.5M3.5 3.5L10.5 10.5",stroke:e.stroke??"#A4A7AE",strokeWidth:e.strokeWidth??"1.66667",strokeLinecap:e.strokeLinecap??"round",strokeLinejoin:e.strokeLinejoin??"round"})}),SB="Checkbox-module__checkboxWrapper",EB="Checkbox-module__sm",wB="Checkbox-module__md",IB="Checkbox-module__checkMark",TB="Checkbox-module__checked",AB="Checkbox-module__disabled",Lo={checkboxWrapper:SB,sm:EB,md:wB,checkMark:IB,checked:TB,disabled:AB},vI=({color:e,width:t,height:i})=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:t??"12",height:i??"12",viewBox:"0 0 12 12",fill:"none",children:R.jsx("path",{d:"M10 3L4.5 8.5L2 6",stroke:e??"white",strokeWidth:"1.6666",strokeLinecap:"round",strokeLinejoin:"round"})}),_I=e=>R.jsx("svg",{width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:R.jsx("path",{d:"M12 22C6.48571 22 2 17.5143 2 12C2 6.48571 6.48571 2 12 2C17.5143 2 22 6.48571 22 12C22 17.5143 17.5143 22 12 22ZM12 3.66679C7.405 3.66679 3.66679 7.405 3.66679 12C3.66679 16.595 7.405 20.3332 12 20.3332C16.595 20.3332 20.3332 16.595 20.3332 12C20.3332 7.405 16.595 3.66679 12 3.66679ZM15.3333 12.8332H8.6665C8.20654 12.8332 7.83321 12.4599 7.83321 11.9999C7.83321 11.54 8.20654 11.1666 8.6665 11.1666H15.3333C15.7941 11.1666 16.1666 11.54 16.1666 11.9999C16.1666 12.4599 15.7941 12.8332 15.3333 12.8332Z",fill:e.color?e.color:"#EF4343"})}),Eh=({checked:e,change:t,disabled:i,required:n,multipleChecked:r,size:a,activeStyle:o,checkBoxStyle:s})=>{const l=ve.useRef(null),[u,d]=ve.useState(!1),c=()=>{t&&typeof t=="function"&&t(!e)},h=()=>u?o??{}:s??{};return R.jsxs("div",{style:h(),className:`${Lo.checkboxWrapper} ${Lo[a]??Lo.md} ${e?Lo.checked:Lo.unChecked} ${i?Lo.disabled:""}`,onMouseDown:()=>d(!0),onMouseUp:()=>d(!1),onMouseLeave:()=>d(!1),onClick:c,children:[R.jsx("input",{ref:l,type:"checkbox",disabled:i,checked:e,hidden:!0,readOnly:!0,required:n??!1}),e?r?R.jsx(_I,{}):R.jsx(vI,{}):""]})},DB="Tag-module__tagContainer",OB="Tag-module__onlyLabel",RB="Tag-module__sm",kB="Tag-module__md",BB="Tag-module__lg",LB="Tag-module__tagLabel",PB="Tag-module__tagNumber",FB="Tag-module__tagClose",Po={tagContainer:DB,onlyLabel:OB,sm:RB,md:kB,lg:BB,tagLabel:LB,tagNumber:PB,tagClose:FB},Dg=({id:e,label:t,icon:i,withClose:n,withCheckbox:r,withNumber:a,number:o,checkboxProps:s,disable:l,size:u,onClose:d,tagContainerStyle:c,tagLabelStyle:h,tagNumberStyle:f,tagCloseStlye:p})=>{const g=()=>!r&&!i&&!n&&!a,C=()=>i,m=()=>{d&&typeof d=="function"&&d(e??null)};return R.jsxs("div",{style:c??{},className:`${Po.tagContainer} ${g()?Po.onlyLabel:""} ${Po[u??"md"]}`,children:[r&&R.jsx(Eh,{...s}),i&&C(),t&&R.jsx("p",{style:h??{},className:Po.tagLabel,children:t??""}),a&&R.jsx("div",{style:f??{},className:Po.tagNumber,children:o??""}),n&&R.jsx("div",{style:p??{},className:Po.tagClose,onClick:m,children:R.jsx(gu,{width:(p==null?void 0:p.width)??"14",height:(p==null?void 0:p.height)??"14",color:(p==null?void 0:p.color)??"#A4A7AE"})})]})},gI=({value:e,label:t,placeholder:i,required:n,disabled:r,type:a,size:o,onChange:s,onFouce:l,onBlur:u,msg:d,readOnly:c,maxLength:h,onlyText:f,tagValues:p,onRightIconIconClick:g,onRightIconIconMouseEnter:C,onRightIconIconMouseLeave:m,onLeftIconIconClick:x,onLeftIconIconMouseEnter:T,onLeftIconIconMouseLeave:k,onPressEnter:D,rightIcon:W,leftIcon:U,withDropDown:G,dropdownData:H,onSelectData:j,withTags:K,tagProps:F,withLink:Q,withCopy:E,onCopy:X,inputWrapperStyle:se,inputLabelStyle:te,requiredStyle:ge,inputContainerStyle:ne,leftIconStyle:Y,inputDropDownStyle:V,ulStyle:y,liStyle:w,httpStyle:I,inputStyle:B,rightIconStyle:$,withCopyStyle:z,inputHelperTextStyle:N})=>{const[J,ae]=ve.useState(!1),Ce=ve.useRef(null),[le,De]=ve.useState(!1);ve.useState(!1);const S=ve.useRef(null),ce=ve.useRef(null),[re,P]=ve.useState(!1),[L,q]=ve.useState(1),he=qe=>{let ct=qe.target.value;ct.length===1&&(ct=ct.trim()),s&&typeof s=="function"&&s(f?ct.replace(/\d/g,""):ct)},ye=()=>{De(!0),l&&typeof l=="function"&&l()},oe=()=>{De(!1),u&&typeof u=="function"&&u()},we=qe=>{const ct=qe.target.value,Ti=ct.length===0;a==="number"&&(qe.keyCode===69||!Ti&&(qe.keyCode===187||qe.keyCode===107||qe.keyCode===189||qe.keyCode===109))&&qe.preventDefault(),qe.key==="Enter"&&ct&&ct.length>0&&D&&typeof D=="function"&&D(ct)},Be=()=>{X&&typeof X=="function"&&X(e)},Ie=qe=>qe,$e=()=>{let qe={};return E&&(qe.borderTopRightRadius=0,qe.borderBottomRightRadius=0,qe.borderRight=0),G&&(qe.paddingLeft=0),{...qe,...ne??{}}},Ye=qe=>{!qe.composedPath().includes(ce.current)&&qe.composedPath().includes(S.current)||P(!1)},it=qe=>{q(qe.id),P(!1),j&&typeof j=="function"&&j(qe)};ve.useEffect(()=>{e&&e.length===0&&calculateWidth()},[e]),ve.useEffect(()=>(document.addEventListener("click",Ye),()=>{document.removeEventListener("click",Ye)}),[]);const Gt=ve.useRef(!1);return ve.useEffect(()=>{Gt.current?setTimeout(()=>{ae(qe=>!qe)},0):Gt.current=!0},[]),R.jsxs("div",{className:ci.inputWrapper,style:se??{},children:[t&&R.jsxs("label",{className:ci.inputLabel,style:te??{},children:[t," ",R.jsx("span",{className:ci.required,style:ge??{},children:n&&"*"})]}),R.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[R.jsxs("div",{style:$e(),className:`${ci.inputContainer} ${le&&!c?ci.focused:""} ${r?ci.disabled:""} ${d!=null&&d.error?ci.error:""} ${ci[o??"sm"]}`,children:[!G&&!Q&&U&&R.jsx("div",{className:ci.leftIcon,style:Y??{},onClick:()=>{x&&typeof x=="function"&&x()},onMouseEnter:()=>{T&&typeof T=="function"&&T()},onMouseLeave:()=>{k&&typeof k=="function"&&k()},children:Ie(U)}),!Q&&G&&R.jsxs("div",{className:ci.inputDropDown,style:V??{},onClick:()=>P(!0),ref:S,children:[H.find(qe=>qe.id===L).label,re&&R.jsx("ul",{ref:ce,style:y??{},children:H&&H.length&&H.map((qe,ct)=>R.jsx("li",{style:w??{},onClick:()=>it(qe),children:(qe==null?void 0:qe.label)??"-"},qe.id))}),R.jsx(Sh,{})]}),Q&&R.jsx("div",{className:`${ci.inputDropDown} ${ci.http}`,style:I??{},onClick:()=>P(!0),ref:S,children:"http://"}),R.jsxs("div",{className:ci.inputContent,children:[K&&p&&p.length>0&&R.jsx("div",{className:ci.inputTags,children:p.map((qe,ct)=>R.jsx("div",{className:ci.inputSingleTags,children:R.jsx(Dg,{...F,id:qe,label:qe,withClose:!0})},ct))}),R.jsx("input",{ref:Ce,style:B??{},type:a??"text",value:e,onChange:qe=>he(qe),onFocus:ye,onBlur:oe,disabled:r,required:n,onKeyDown:we,readOnly:c,spellCheck:!1,placeholder:i??"",autoComplete:"off",maxLength:h})]}),W&&R.jsx("div",{className:ci.rightIcon,style:$??{},onClick:()=>{g&&typeof g=="function"&&g()},onMouseEnter:()=>{C&&typeof C=="function"&&C()},onMouseLeave:()=>{m&&typeof m=="function"&&m()},children:Ie(W)})]}),E&&R.jsxs("div",{style:z??{},onClick:Be,className:ci.withCopy,children:[R.jsx(bB,{}),"Copy"]})]}),d&&(d==null?void 0:d.visible)&&R.jsx("div",{style:N??{},className:`${ci.inputHelperText} ${d!=null&&d.error?ci.error:""}`,children:R.jsx("p",{style:(d==null?void 0:d.style)??{},children:d.text})})]})},MB="Textarea-module__textareaContainer",VB="Textarea-module__textAreaLabel",NB="Textarea-module__required",HB="Textarea-module__wrap",$B="Textarea-module__textarea",WB="Textarea-module__focused",zB="Textarea-module__disabled",GB="Textarea-module__error",UB="Textarea-module__helperTextStyle",vn={textareaContainer:MB,textAreaLabel:VB,required:NB,wrap:HB,textarea:$B,focused:WB,disabled:zB,error:GB,helperTextStyle:UB},KB=({width:e,height:t,color:i})=>R.jsxs("svg",{width:e??"16",height:t??"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[R.jsx("g",{id:"help-circle",clipPath:"url(#clip0_433_6293)",children:R.jsx("path",{id:"Icon",d:"M6.05992 5.99998C6.21665 5.55442 6.52602 5.17872 6.93322 4.9394C7.34042 4.70009 7.81918 4.61261 8.2847 4.69245C8.75022 4.7723 9.17246 5.01433 9.47664 5.37567C9.78081 5.737 9.94729 6.19433 9.94659 6.66665C9.94659 7.99998 7.94659 8.66665 7.94659 8.66665M7.99992 11.3333H8.00659M14.6666 7.99998C14.6666 11.6819 11.6818 14.6666 7.99992 14.6666C4.31802 14.6666 1.33325 11.6819 1.33325 7.99998C1.33325 4.31808 4.31802 1.33331 7.99992 1.33331C11.6818 1.33331 14.6666 4.31808 14.6666 7.99998Z",stroke:i??"#A4A7AE",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})}),R.jsx("defs",{children:R.jsx("clipPath",{id:"clip0_433_6293",children:R.jsx("rect",{width:e??"16",height:t??"16",fill:"white"})})})]}),jB=({placeholder:e,label:t,msg:i,cols:n,rows:r,value:a,maxLength:o,onChange:s,onFocus:l,onBlur:u,disabled:d,required:c,textareaContainerStyle:h,textareaLabelStyle:f,requiredStyle:p,textareaStyle:g,textareaHelperTextStyle:C})=>{const[m,x]=ve.useState(!1),T=W=>{let U=W.target.value;s&&typeof s=="function"&&s(U)},k=()=>{x(!0),l&&typeof l=="function"&&l()},D=()=>{x(!1),u&&typeof u=="function"&&u()};return R.jsxs("div",{style:h??{},className:`${vn.textareaContainer} ${i!=null&&i.type&&(i!=null&&i.visible)?vn[i==null?void 0:i.type]:""} ${d?vn.disabled:null}`,children:[t&&R.jsxs("div",{style:f,className:vn.textAreaLabel,children:[R.jsx("p",{children:t}),R.jsx("span",{style:p??{},className:vn.required,children:c&&"*"}),R.jsx(KB,{})]}),R.jsx("div",{className:vn.wrap,children:R.jsx("textarea",{style:g??{},className:`${vn.textarea} ${m?vn.focused:""} ${d?vn.disabled:""} ${i!=null&&i.error?vn.error:""}`,value:a,placeholder:e??"",cols:n??"30",rows:r??"5",maxLength:o??null,onFocus:k,disabled:d,onBlur:D,onChange:T})}),i&&(i==null?void 0:i.text)&&(i==null?void 0:i.text.length)>0&&R.jsx("div",{style:C??{},className:`${vn.helperTextStyle} ${i!=null&&i.error?vn.error:""}`,children:R.jsx("p",{style:(i==null?void 0:i.style)??{},children:i.text})})]})},qB="Toggle-module__toggleWrapper",YB="Toggle-module__toggleState",XB="Toggle-module__checked",ZB="Toggle-module__disabled",id={toggleWrapper:qB,toggleState:YB,checked:XB,disabled:ZB},QB=({checked:e,change:t,disabled:i,required:n,activeStyle:r,bgStyle:a,checkedBgStyle:o,disabledBgStyle:s,circleStyle:l,checkedCircleStyle:u,disabledCircleStyle:d})=>{const[c,h]=ve.useState(!1),f=()=>{t&&typeof t=="function"&&t(!e)},p=()=>{if(c)return r??{};if(e){if(o)return o}else if(e){if(i&&s)return s}else if(a)return a;return{}},g=()=>{if(e){if(u)return u}else if(e){if(i&&d)return d}else if(l)return l;return{}};return R.jsx("div",{style:p(),onMouseDown:()=>h(!0),onMouseUp:()=>h(!1),onMouseLeave:()=>h(!1),onClick:f,className:`${id.toggleWrapper} ${e?id.checked:""} ${i?id.disabled:""}`,children:R.jsx("div",{style:g(),className:id.toggleState,children:R.jsx("input",{type:"checkbox",checked:e,readOnly:!0,disabled:i??!1,hidden:!0,required:n??!1})})})},JB="Radio-module__radioWrapper",eL="Radio-module__sm",tL="Radio-module__md",iL="Radio-module__checked",nL="Radio-module__innerCircle",rL="Radio-module__radioState",aL="Radio-module__disabled",Oa={radioWrapper:JB,sm:eL,md:tL,checked:iL,innerCircle:nL,radioState:rL,disabled:aL},mI=({checked:e,change:t,disabled:i,isRequired:n,withUncheckState:r,size:a})=>{ve.useState(!1);const o=()=>{t&&typeof t=="function"&&(r||!r&&!e)&&t(!0)};return R.jsxs("div",{className:`${Oa.radioWrapper} ${Oa[a]??Oa.md} ${e?Oa.checked:""} ${i?Oa.disabled:""}`,onClick:o,children:[R.jsx("input",{type:"radio",checked:!0,readOnly:!0,hidden:!0,disabled:i??!1,required:n??!1}),R.jsx("div",{className:Oa.radioState,children:R.jsx("div",{className:Oa.innerCircle})})]})},oL="Dropdown-module__dropdownWrapper",sL="Dropdown-module__placeHolder",lL="Dropdown-module__dropdownLabel",uL="Dropdown-module__required",dL="Dropdown-module__dropdownContainer",cL="Dropdown-module__sm",hL="Dropdown-module__md",fL="Dropdown-module__selectedTags",pL="Dropdown-module__selectedList",vL="Dropdown-module__additional",_L="Dropdown-module__dropdownListContainer",gL="Dropdown-module__dropdownList",mL="Dropdown-module__checkIcon",CL="Dropdown-module__disabled",yL="Dropdown-module__selected",xL="Dropdown-module__dropdownListFooter",bL="Dropdown-module__focused",SL="Dropdown-module__error",EL="Dropdown-module__dropdownHelperText",li={dropdownWrapper:oL,placeHolder:sL,dropdownLabel:lL,required:uL,dropdownContainer:dL,sm:cL,md:hL,selectedTags:fL,selectedList:pL,additional:vL,dropdownListContainer:_L,dropdownList:gL,checkIcon:mL,disabled:CL,selected:yL,dropdownListFooter:xL,focused:bL,error:SL,dropdownHelperText:EL},wL=()=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1.5rem",height:"1.5rem",fill:"none",viewBox:"0 0 20 20",children:R.jsx("path",{stroke:"#10B77F",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",d:"M10 18.333c4.584 0 8.334-3.75 8.334-8.334 0-4.583-3.75-8.333-8.334-8.333-4.583 0-8.333 3.75-8.333 8.333 0 4.584 3.75 8.334 8.333 8.334zM6.667 10h6.667M10 13.333V6.666"})}),IL=()=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",children:R.jsx("path",{d:"M16.5 16.5L13.5834 13.5833M15.6667 8.58333C15.6667 12.4954 12.4954 15.6667 8.58333 15.6667C4.67132 15.6667 1.5 12.4954 1.5 8.58333C1.5 4.67132 4.67132 1.5 8.58333 1.5C12.4954 1.5 15.6667 4.67132 15.6667 8.58333Z",stroke:"#717680",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),r_=({label:e,disabled:t,required:i,size:n="md",placeholder:r,msg:a,readOnly:o,searchValue:s,onClearAll:l,onSelectAll:u,onBottomScroll:d,withClearAll:c=!0,withSelectAll:h=!0,withPlus:f=!1,searchComponent:p=!1,withFooter:g=!0,data:C,onSelect:m,selectedOptionID:x,withFilter:T=!0,withClose:k=!0,fixedDropdown:D=!1,onSearch:W,pagination:U,withMultiSelect:G=!1,skipSelected:H,labelIcon:j,closeIcon:K,dropdownIcon:F,iconDown:Q,onLabelIconClick:E,onLabelIconMouseEnter:X,onLabelIconMouseLeave:se,dropdownWrapperStyle:te,dropdownLabelStyle:ge,requiredStyle:ne,labelIconStyle:Y,dropdownContainerStyle:V,placeHolderStyle:y,selectedTagsStyle:w,selectedListStyle:I,additionalStyle:B,dropdownListStyle:$,listStyle:z})=>{const[N,J]=ve.useState(!1),[ae,Ce]=ve.useState(!1),[le,De]=ve.useState(""),[S,ce]=ve.useState("");ve.useState(null);const re=ve.useRef([]),P=ve.useRef(null),L=ve.useRef(null),q=ve.useRef({}),he=(Se,ht)=>{const oi=new Set;return Se.filter(ki=>oi.has(ki[ht])?!1:(oi.add(ki[ht]),!0))},ye=Se=>{var ht;C.forEach(oi=>{Se.id===oi.id?oi.selected=!0:oi.selected=!1}),q.current=Se,De((ht=q.current)==null?void 0:ht.label),m&&typeof m=="function"&&m(q.current),Ce(!1)},oe=Se=>{re.current=[...re.current,...C.filter(ht=>ht.selected==!0),...C.filter(ht=>ht.id===Se.id)],Se.selected=!Se.selected,re.current=he(re.current,"id").filter(ht=>ht.selected),m&&typeof m=="function"&&m(re.current),p||De(re.current.map(ht=>ht.label).join(", ")),J(ht=>!ht)},we=Se=>{Se.stopPropagation(),re.current=[],x=null,C&&C.length>0&&C.forEach(ht=>ht.selected=!1),Be(""),m(G?[]:{}),De("")},Be=Se=>{W&&typeof W=="function"&&W(Se),De(Se),p&&ce(Se)},Ie=()=>{if(x||x===0){let Se=C.filter(ht=>Number(ht.id)===Number(x));Se&&Se[0]&&(q.current=Se[0],H?(W&&typeof W=="function"&&W(q.current.label),De(q.current.label),closeOnSelect&&setCollapsed(ht=>!1),withDropdownSearch&&DropdownSearchValue&&SetDropdownSearchValue("")):ye(Se[0]))}},[$e,Ye]=ve.useState(!1),it=Se=>{let ht=P.current.querySelector("ul"),ki=Math.abs(ht.scrollTop+ht.clientHeight-ht.scrollHeight)<=2;U&&ki&&!$e&&(d&&typeof d=="function"&&d(!0),Ye(!0)),ki||Ye(!1)},Gt=()=>{C.forEach(Se=>{Se.selected=!1}),re.current=[],m([]),De(""),l&&typeof l=="function"&&l(),J(Se=>!Se)},qe=()=>{C.forEach(Se=>{Se.selected=!0}),re.current=C,re.current=he(re.current,"id").filter(Se=>Se.selected),De(re.current.map(Se=>Se.label).join(", ")),u&&typeof u=="function"&&u(),m(re.current),J(Se=>!Se)},ct=Se=>Se,Ti=Se=>{Se.composedPath().includes(P.current)||Ce(!1)},Et=Se=>{if(D){if(Se.composedPath().includes(P.current))return;Ce(!1)}},Ui=()=>{const Se=L.current;if(!Se)return;const ht=Se.getBoundingClientRect(),oi=window.innerHeight;ht.bottom>oi?(Se.style.top="unset",Se.style.bottom="calc(100% + 8px)"):(Se.style.bottom="unset",Se.style.top="calc(100% + 8px)")},Ki=ve.useRef(null);return ve.useEffect(()=>{ae&&Ki.current&&Ki.current.focus()},[ae]),ve.useEffect(()=>{G&&(re.current=C.filter(Se=>Se.selected),De(C.filter(Se=>Se.selected).map(Se=>Se.label).join(", ")))},[]),ve.useEffect(()=>{p&&s&&s.length>0&&ce(s)},[]),ve.useEffect(()=>{Ui()},[L,ae]),ve.useEffect(()=>{G||Ie()},[x,C]),ve.useEffect(()=>(document.addEventListener("click",Ti),document.addEventListener("wheel",Et),()=>{document.removeEventListener("click",Ti),document.removeEventListener("wheel",Et)}),[]),R.jsxs("div",{className:li.dropdownWrapper,style:te??{},children:[e&&R.jsxs("label",{className:li.dropdownLabel,style:ge??{},children:[e," ",R.jsx("span",{className:li.required,style:ne??{},children:i&&"*"}),R.jsxs("span",{style:{...Y??{},display:"grid",placeItems:"center"},onClick:()=>{E&&typeof E=="function"&&E()},onMouseEnter:()=>{X&&typeof X=="function"&&X()},onMouseLeave:()=>{se&&typeof se=="function"&&se()},children:[" ",ct(j)]})]}),R.jsxs("div",{ref:P,onClick:()=>(Ce(Se=>!Se),Ui()),className:`${li.dropdownContainer} ${ae&&!o?li.focused:""} ${t?li.disabled:""} ${a!=null&&a.error?li.error:""} ${li[n]}`,style:V??{},children:[p?R.jsxs("div",{children:[" ",R.jsx(IL,{})]}):R.jsx(R.Fragment,{children:F&&R.jsx("div",{style:{display:"grid",alignItems:"center",marginRight:"0.5rem"},children:ct(F)})}),!p&&G&&r&&!ae&&re.current.length===0&&R.jsx("span",{className:li.placeHolder,style:y??{},children:r??""}),G&&R.jsx("div",{className:li.selectedTags,style:w??{},children:!p&&!ae?R.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"flex-start"},children:[re.current.slice(0,3).map((Se,ht)=>{let oi=re.current[re.current.length-1];return R.jsxs("span",{className:li.selectedList,style:I??{},children:[!f&&Se.label,!f&&Se.id!==oi.id&&ht!==2?", ":""]},Se==null?void 0:Se.id)}),!f&&re.current.length>3&&R.jsxs("span",{className:li.additional,style:B??{},children:[" ","+(",re.current.length-3,")"]})]}):R.jsx("input",{ref:Ki,onClick:Se=>(Se.stopPropagation(),Ce(!0)),autoCorrect:"off",placeholder:"Search...",type:"text",...p?{value:S}:{},onChange:Se=>Be(Se.target.value)},x)}),R.jsx("input",{autoCorrect:"off",hidden:G,placeholder:r,readOnly:!T||!ae||G,type:"text",value:G&&!p&&ae?"":le,onChange:Se=>Be(Se.target.value)},x),C&&C.length>0&&ae&&R.jsxs("div",{ref:L,onClick:Se=>Se.stopPropagation(),className:li.dropdownListContainer,children:[R.jsx("ul",{onScroll:Se=>it(),onClick:Se=>Se.stopPropagation(),className:li.dropdownList,style:$??{},children:C.map(Se=>R.jsxs("li",{style:z??{},className:`${!(Se!=null&&Se.label)||Se.label===void 0||Se!=null&&Se.disabled?li.disabled:""} ${Se!=null&&Se.selected?li.selected:""}`,onClick:()=>{G?oe(Se):ye(Se)},children:[R.jsxs("p",{children:[" ",Se!=null&&Se.customLabel?Se.customLabel():(Se==null?void 0:Se.label)??"-"]}),f?R.jsx(R.Fragment,{children:Se.selected?R.jsx(_I,{}):R.jsx(wL,{})}):(Se==null?void 0:Se.selected)&&R.jsx("span",{className:li.checkIcon,children:R.jsx(vI,{color:"#7F56D9",width:20,height:20})})]},Se==null?void 0:Se.id))}),G&&g&&R.jsxs("div",{className:li.dropdownListFooter,children:[c&&R.jsx("span",{onClick:Gt,children:"Clear All"}),h&&R.jsx("span",{onClick:qe,children:"Select All"})]})]}),!G&&k&&(re.current.length>0||le.length)>0&&R.jsx("div",{onClick:Se=>we(Se),style:{display:"grid",placeItems:"center",cursor:"pointer"},children:K?ct(K):R.jsx(gu,{width:16,height:16})}),Q?ct(Q):R.jsx("div",{style:{display:"grid",placeItems:"center",transform:ae?"rotate(180deg)":"",transition:"transform 0.2s ease-in-out",cursor:"pointer",marginLeft:"10px"},children:!p&&R.jsx(Sh,{})})]}),a&&(a==null?void 0:a.visible)&&R.jsx("div",{className:`${li.dropdownHelperText} ${a!=null&&a.error?li.error:""}`,children:!ae&&R.jsx("p",{style:(a==null?void 0:a.style)??{},children:a.text})})]})},TL="Tooltip-module__tooltipContainer",AL="Tooltip-module__tooltipContent",DL="Tooltip-module__top",OL="Tooltip-module__right",RL="Tooltip-module__bottom",kL="Tooltip-module__left",BL="Tooltip-module__tooltipTitle",LL="Tooltip-module__tooltipText",Fo={tooltipContainer:TL,tooltipContent:AL,top:DL,right:OL,bottom:RL,left:kL,tooltipTitle:BL,tooltipText:LL},PL=({children:e,tooltipSlot:t,delay:i,placement:n="top",trigger:r="click",title:a,text:o,tooltipContentStyle:s,tooltipTitlestyle:l,tooltipTextStyle:u,pointerPosition:d="10%",fixedPosition:c=!1})=>{const h=ve.useRef(null),f=ve.useRef(null),p=ve.useRef({top:0,left:0});let g;const[C,m]=ve.useState(!1),x=()=>{r==="hover"&&(g=setTimeout(()=>{m(!0)},i||400))},T=()=>{r==="hover"&&(clearTimeout(g),setTimeout(()=>{m(!1)},i||400))},k=()=>{r==="click"&&m(W=>!W)},D=W=>{W.composedPath().includes(h.current)||m(!1)};return ve.useEffect(()=>(document.addEventListener("click",D),()=>{document.removeEventListener("click",D)}),[]),ve.useEffect(()=>{const W=f.current;W&&W.style.setProperty("--pointer-position",`${d}`)},[C]),R.jsxs("div",{ref:h,className:Fo.tooltipContainer,onClick:k,onMouseEnter:x,onMouseLeave:T,children:[e,C&&t?t():C&&R.jsxs("div",{style:c?{...s??{},top:p.current.top,left:p.current.left,position:"fixed",zIndex:"150"}:{...s??{}},onClick:W=>W.stopPropagation(),ref:f,className:`${Fo.tooltipContent} ${n?Fo[n]:Fo.bottom}`,children:[a&&a.length>0&&R.jsx("h2",{className:Fo.tooltipTitle,style:l??{},children:a}),o&&o.length>0&&R.jsx("p",{className:Fo.tooltipText,style:u??{},children:o})]})]})},FL="Popup-module__modalOverlay",ML="Popup-module__popupDrawerMode",VL="Popup-module__popupContainer",NL="Popup-module__EnterFromLeft",HL="Popup-module__fadeIn",$L="Popup-module__withOptions",WL="Popup-module__horizontal",zL="Popup-module__popupHeader",GL="Popup-module__popupTitle",UL="Popup-module__popupDescription",KL="Popup-module__typeIcon",jL="Popup-module__icon",qL="Popup-module__templateWrapper",kn={modalOverlay:FL,popupDrawerMode:ML,popupContainer:VL,enterFromLeft:NL,fadeIn:HL,withOptions:$L,horizontal:WL,popupHeader:zL,popupTitle:GL,popupDescription:UL,typeIcon:KL,icon:jL,templateWrapper:qL},YL=e=>{const t=["bytes","KB","MB","GB","TB","PB","EB","ZB","YB"];let i=0,n=parseInt(e,10)||0;for(;n>=1024&&++i;)n=n/1024;return n.toFixed(n<10&&i>0?1:0)+" "+t[i]},XL=e=>e.slice((e.lastIndexOf(".")-1>>>0)+2),ZL=e=>new Promise((t,i)=>{const n=new FileReader;n.readAsDataURL(e),n.onload=()=>t(n.result.split(",")[1]),n.onerror=r=>i(r)});location.href.indexOf(".upgaming.dev")>0||location.href.indexOf(".upgaming.com")>0;const QL=(e,t)=>{const i=new Set;return e.filter(n=>i.has(n[t])?!1:(i.add(n[t]),!0))},JL=()=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:R.jsx("path",{d:"M7.5 12L10.5 15L16.5 9M22 12C22 17.5228 17.5228 22 12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12Z",stroke:"#079455",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})}),eP=()=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:R.jsx("path",{d:"M7 3V6.4C7 6.96005 7 7.24008 7.10899 7.45399C7.20487 7.64215 7.35785 7.79513 7.54601 7.89101C7.75992 8 8.03995 8 8.6 8H15.4C15.9601 8 16.2401 8 16.454 7.89101C16.6422 7.79513 16.7951 7.64215 16.891 7.45399C17 7.24008 17 6.96005 17 6.4V4M17 21V14.6C17 14.0399 17 13.7599 16.891 13.546C16.7951 13.3578 16.6422 13.2049 16.454 13.109C16.2401 13 15.9601 13 15.4 13H8.6C8.03995 13 7.75992 13 7.54601 13.109C7.35785 13.2049 7.20487 13.3578 7.10899 13.546C7 13.7599 7 14.0399 7 14.6V21M21 9.32548V16.2C21 17.8802 21 18.7202 20.673 19.362C20.3854 19.9265 19.9265 20.3854 19.362 20.673C18.7202 21 17.8802 21 16.2 21H7.8C6.11984 21 5.27976 21 4.63803 20.673C4.07354 20.3854 3.6146 19.9265 3.32698 19.362C3 18.7202 3 17.8802 3 16.2V7.8C3 6.11984 3 5.27976 3.32698 4.63803C3.6146 4.07354 4.07354 3.6146 4.63803 3.32698C5.27976 3 6.11984 3 7.8 3H14.6745C15.1637 3 15.4083 3 15.6385 3.05526C15.8425 3.10425 16.0376 3.18506 16.2166 3.29472C16.4184 3.4184 16.5914 3.59135 16.9373 3.93726L20.0627 7.06274C20.4086 7.40865 20.5816 7.5816 20.7053 7.78343C20.8149 7.96237 20.8957 8.15746 20.9447 8.36154C21 8.59171 21 8.8363 21 9.32548Z",stroke:"#DC6803",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})}),CI=({width:e,color:t})=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"24",height:e??"24",viewBox:"0 0 24 24",fill:"none",children:R.jsx("path",{d:"M16 6V5.2C16 4.0799 16 3.51984 15.782 3.09202C15.5903 2.71569 15.2843 2.40973 14.908 2.21799C14.4802 2 13.9201 2 12.8 2H11.2C10.0799 2 9.51984 2 9.09202 2.21799C8.71569 2.40973 8.40973 2.71569 8.21799 3.09202C8 3.51984 8 4.0799 8 5.2V6M10 11.5V16.5M14 11.5V16.5M3 6H21M19 6V17.2C19 18.8802 19 19.7202 18.673 20.362C18.3854 20.9265 17.9265 21.3854 17.362 21.673C16.7202 22 15.8802 22 14.2 22H9.8C8.11984 22 7.27976 22 6.63803 21.673C6.07354 21.3854 5.6146 20.9265 5.32698 20.362C5 19.7202 5 18.8802 5 17.2V6",stroke:t??"#D92D20",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})}),Og=({visible:e,template:t,options:i,children:n,onClickOutside:r,onClose:a,widthType:o,modalOverlayStyle:s,popupContainerStyle:l,templateWrapperStyle:u,popupHeaderStyle:d,popupTitleStyle:c})=>{const h=()=>{if(!(!i||!(i!=null&&i.type)))switch(String(i==null?void 0:i.type)){case"delete":return R.jsx(CI,{});case"unsaved":return R.jsx(eP,{});case"success":return R.jsx(JL,{})}},f=()=>{a&&typeof a=="function"&&a(!1)},p=ve.useRef(null),g=C=>{C.target===p.current&&r&&typeof r=="function"&&r(!1)};return ve.useEffect(()=>(document.addEventListener("click",g),()=>{document.removeEventListener("click",g)}),[]),e&&R.jsx("div",{ref:p,style:s??{},className:`
31
+ <%s key={someKey} {...props} />`,mf,Da,Uk,Da),Aa[Da+mf]=!0}}return Z===n?gf(si):_f(si),si}}function $k(Z,Te,Ve){return fr(Z,Te,Ve,!0)}function Wk(Z,Te,Ve){return fr(Z,Te,Ve,!1)}var zk=Wk,Gk=$k;zs.Fragment=n,zs.jsx=zk,zs.jsxs=Gk}()),zs}process.env.NODE_ENV==="production"?n_.exports=jk():n_.exports=qk();var R=n_.exports;const Yk="MainButton-module__mainButton",Xk="MainButton-module__sm",Zk="MainButton-module__onlyIcon",Qk="MainButton-module__buttonSlot",Jk="MainButton-module__buttonLabel",eB="MainButton-module__md",tB="MainButton-module__lg",iB="MainButton-module__xl",nB="MainButton-module__xl2",rB="MainButton-module__disabled",Bo={mainButton:Yk,sm:Xk,onlyIcon:Zk,buttonSlot:Qk,buttonLabel:Jk,md:eB,lg:tB,xl:iB,xl2:nB,disabled:rB},Jl=({label:e,buttonType:t="button",onClick:i,size:n="md",disabled:r,withIcons:a,iconOne:o,iconTwo:s,onlyIcon:l,buttonStyle:u,labelStyle:d,buttonSlotStyle:c})=>R.jsx("button",{type:t,style:u&&typeof u=="object"?u:{},className:`${Bo.mainButton} ${l?Bo.onlyIcon:""} ${n?Bo[n]:""} ${r?Bo.disabled:""}`,onClick:()=>{i&&typeof i=="function"&&i()},children:R.jsxs("div",{className:Bo.buttonSlot,style:c??{},children:[l||a&&o?o:"",!l&&R.jsx("span",{style:d??{},className:Bo.buttonLabel,children:e??"Button"}),a&&s?s:""]})}),aB="FormInput-module__inputWrapper",oB="FormInput-module__inputLabel",sB="FormInput-module__required",lB="FormInput-module__inputContainer",uB="FormInput-module__inputContent",dB="FormInput-module__inputTags",cB="FormInput-module__focused",hB="FormInput-module__error",fB="FormInput-module__rightIcon",pB="FormInput-module__leftIcon",vB="FormInput-module__inputDropDown",_B="FormInput-module__http",gB="FormInput-module__disabled",mB="FormInput-module__sm",CB="FormInput-module__md",yB="FormInput-module__withCopy",xB="FormInput-module__inputHelperText",ci={inputWrapper:aB,inputLabel:oB,required:sB,inputContainer:lB,inputContent:uB,inputTags:dB,focused:cB,error:hB,rightIcon:fB,leftIcon:pB,inputDropDown:vB,http:_B,disabled:gB,sm:mB,md:CB,withCopy:yB,inputHelperText:xB},Sh=({width:e,height:t,color:i})=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"12",height:t??"8",viewBox:"0 0 12 8",fill:"none",children:R.jsx("path",{d:"M1 1.5L6 6.5L11 1.5",stroke:i??"#A4A7AE",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),bB=({width:e,height:t,color:i})=>R.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"20",height:t??"20",viewBox:"0 0 20 20",fill:"none",children:[R.jsx("g",{clipPath:"url(#clip0_444_26)",children:R.jsx("path",{d:"M4.1665 12.5C3.38993 12.5 3.00165 12.5 2.69536 12.3732C2.28698 12.204 1.96253 11.8795 1.79337 11.4712C1.6665 11.1649 1.6665 10.7766 1.6665 10V4.33335C1.6665 3.39993 1.6665 2.93322 1.84816 2.5767C2.00795 2.2631 2.26292 2.00813 2.57652 1.84834C2.93304 1.66669 3.39975 1.66669 4.33317 1.66669H9.99984C10.7764 1.66669 11.1647 1.66669 11.471 1.79355C11.8794 1.96271 12.2038 2.28717 12.373 2.69555C12.4998 3.00183 12.4998 3.39012 12.4998 4.16669M10.1665 18.3334H15.6665C16.5999 18.3334 17.0666 18.3334 17.4232 18.1517C17.7368 17.9919 17.9917 17.7369 18.1515 17.4233C18.3332 17.0668 18.3332 16.6001 18.3332 15.6667V10.1667C18.3332 9.23327 18.3332 8.76656 18.1515 8.41004C17.9917 8.09643 17.7368 7.84147 17.4232 7.68168C17.0666 7.50002 16.5999 7.50002 15.6665 7.50002H10.1665C9.23308 7.50002 8.76637 7.50002 8.40985 7.68168C8.09625 7.84147 7.84128 8.09643 7.68149 8.41004C7.49984 8.76656 7.49984 9.23327 7.49984 10.1667V15.6667C7.49984 16.6001 7.49984 17.0668 7.68149 17.4233C7.84128 17.7369 8.09625 17.9919 8.40985 18.1517C8.76637 18.3334 9.23308 18.3334 10.1665 18.3334Z",stroke:i??"#414651",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),R.jsx("defs",{children:R.jsx("clipPath",{id:"clip0_444_26",children:R.jsx("rect",{width:"20",height:"20",fill:"white"})})})]}),gu=e=>R.jsx("svg",{xmlns:e.xmlns??"http://www.w3.org/2000/svg",width:e.width??"14",height:e.height??"14",viewBox:e.viewBox??"0 0 14 14",fill:e.fill??"none",children:R.jsx("path",{d:e.d??"M10.5 3.5L3.5 10.5M3.5 3.5L10.5 10.5",stroke:e.stroke??"#A4A7AE",strokeWidth:e.strokeWidth??"1.66667",strokeLinecap:e.strokeLinecap??"round",strokeLinejoin:e.strokeLinejoin??"round"})}),SB="Checkbox-module__checkboxWrapper",EB="Checkbox-module__sm",wB="Checkbox-module__md",IB="Checkbox-module__checkMark",TB="Checkbox-module__checked",AB="Checkbox-module__disabled",Lo={checkboxWrapper:SB,sm:EB,md:wB,checkMark:IB,checked:TB,disabled:AB},vI=({color:e,width:t,height:i})=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:t??"12",height:i??"12",viewBox:"0 0 12 12",fill:"none",children:R.jsx("path",{d:"M10 3L4.5 8.5L2 6",stroke:e??"white",strokeWidth:"1.6666",strokeLinecap:"round",strokeLinejoin:"round"})}),_I=e=>R.jsx("svg",{width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:R.jsx("path",{d:"M12 22C6.48571 22 2 17.5143 2 12C2 6.48571 6.48571 2 12 2C17.5143 2 22 6.48571 22 12C22 17.5143 17.5143 22 12 22ZM12 3.66679C7.405 3.66679 3.66679 7.405 3.66679 12C3.66679 16.595 7.405 20.3332 12 20.3332C16.595 20.3332 20.3332 16.595 20.3332 12C20.3332 7.405 16.595 3.66679 12 3.66679ZM15.3333 12.8332H8.6665C8.20654 12.8332 7.83321 12.4599 7.83321 11.9999C7.83321 11.54 8.20654 11.1666 8.6665 11.1666H15.3333C15.7941 11.1666 16.1666 11.54 16.1666 11.9999C16.1666 12.4599 15.7941 12.8332 15.3333 12.8332Z",fill:e.color?e.color:"#EF4343"})}),Eh=({checked:e,change:t,disabled:i,required:n,multipleChecked:r,size:a,activeStyle:o,checkBoxStyle:s})=>{const l=ve.useRef(null),[u,d]=ve.useState(!1),c=()=>{t&&typeof t=="function"&&t(!e)},h=()=>u?o??{}:s??{};return R.jsxs("div",{style:h(),className:`${Lo.checkboxWrapper} ${Lo[a]??Lo.md} ${e?Lo.checked:Lo.unChecked} ${i?Lo.disabled:""}`,onMouseDown:()=>d(!0),onMouseUp:()=>d(!1),onMouseLeave:()=>d(!1),onClick:c,children:[R.jsx("input",{ref:l,type:"checkbox",disabled:i,checked:e,hidden:!0,readOnly:!0,required:n??!1}),e?r?R.jsx(_I,{}):R.jsx(vI,{}):""]})},DB="Tag-module__tagContainer",OB="Tag-module__onlyLabel",RB="Tag-module__sm",kB="Tag-module__md",BB="Tag-module__lg",LB="Tag-module__tagLabel",PB="Tag-module__tagNumber",FB="Tag-module__tagClose",Po={tagContainer:DB,onlyLabel:OB,sm:RB,md:kB,lg:BB,tagLabel:LB,tagNumber:PB,tagClose:FB},Dg=({id:e,label:t,icon:i,withClose:n,withCheckbox:r,withNumber:a,number:o,checkboxProps:s,disable:l,size:u,onClose:d,tagContainerStyle:c,tagLabelStyle:h,tagNumberStyle:f,tagCloseStlye:p})=>{const g=()=>!r&&!i&&!n&&!a,C=()=>i,m=()=>{d&&typeof d=="function"&&d(e??null)};return R.jsxs("div",{style:c??{},className:`${Po.tagContainer} ${g()?Po.onlyLabel:""} ${Po[u??"md"]}`,children:[r&&R.jsx(Eh,{...s}),i&&C(),t&&R.jsx("p",{style:h??{},className:Po.tagLabel,children:t??""}),a&&R.jsx("div",{style:f??{},className:Po.tagNumber,children:o??""}),n&&R.jsx("div",{style:p??{},className:Po.tagClose,onClick:m,children:R.jsx(gu,{width:(p==null?void 0:p.width)??"14",height:(p==null?void 0:p.height)??"14",color:(p==null?void 0:p.color)??"#A4A7AE"})})]})},gI=({value:e,label:t,placeholder:i,required:n,disabled:r,type:a,size:o,onChange:s,onFouce:l,onBlur:u,msg:d,readOnly:c,maxLength:h,onlyText:f,tagValues:p,onRightIconIconClick:g,onRightIconIconMouseEnter:C,onRightIconIconMouseLeave:m,onLeftIconIconClick:x,onLeftIconIconMouseEnter:T,onLeftIconIconMouseLeave:k,onPressEnter:D,rightIcon:W,leftIcon:U,withDropDown:G,dropdownData:H,onSelectData:j,withTags:K,tagProps:F,withLink:Q,withCopy:E,onCopy:X,inputWrapperStyle:se,inputLabelStyle:te,requiredStyle:ge,inputContainerStyle:ne,leftIconStyle:Y,inputDropDownStyle:V,ulStyle:y,liStyle:w,httpStyle:I,inputStyle:B,rightIconStyle:$,withCopyStyle:z,inputHelperTextStyle:N})=>{const[J,ae]=ve.useState(!1),Ce=ve.useRef(null),[le,De]=ve.useState(!1);ve.useState(!1);const S=ve.useRef(null),ce=ve.useRef(null),[re,P]=ve.useState(!1),[L,q]=ve.useState(1),he=qe=>{let ct=qe.target.value;ct.length===1&&(ct=ct.trim()),s&&typeof s=="function"&&s(f?ct.replace(/\d/g,""):ct)},ye=()=>{De(!0),l&&typeof l=="function"&&l()},oe=()=>{De(!1),u&&typeof u=="function"&&u()},we=qe=>{const ct=qe.target.value,Ti=ct.length===0;a==="number"&&(qe.keyCode===69||!Ti&&(qe.keyCode===187||qe.keyCode===107||qe.keyCode===189||qe.keyCode===109))&&qe.preventDefault(),qe.key==="Enter"&&ct&&ct.length>0&&D&&typeof D=="function"&&D(ct)},Be=()=>{X&&typeof X=="function"&&X(e)},Ie=qe=>qe,$e=()=>{let qe={};return E&&(qe.borderTopRightRadius=0,qe.borderBottomRightRadius=0,qe.borderRight=0),G&&(qe.paddingLeft=0),{...qe,...ne??{}}},Ye=qe=>{!qe.composedPath().includes(ce.current)&&qe.composedPath().includes(S.current)||P(!1)},it=qe=>{q(qe.id),P(!1),j&&typeof j=="function"&&j(qe)};ve.useEffect(()=>{e&&e.length===0&&calculateWidth()},[e]),ve.useEffect(()=>(document.addEventListener("click",Ye),()=>{document.removeEventListener("click",Ye)}),[]);const Gt=ve.useRef(!1);return ve.useEffect(()=>{Gt.current?setTimeout(()=>{ae(qe=>!qe)},0):Gt.current=!0},[]),R.jsxs("div",{className:ci.inputWrapper,style:se??{},children:[t&&R.jsxs("label",{className:ci.inputLabel,style:te??{},children:[t," ",R.jsx("span",{className:ci.required,style:ge??{},children:n&&"*"})]}),R.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[R.jsxs("div",{style:$e(),className:`${ci.inputContainer} ${le&&!c?ci.focused:""} ${r?ci.disabled:""} ${d!=null&&d.error?ci.error:""} ${ci[o??"sm"]}`,children:[!G&&!Q&&U&&R.jsx("div",{className:ci.leftIcon,style:Y??{},onClick:()=>{x&&typeof x=="function"&&x()},onMouseEnter:()=>{T&&typeof T=="function"&&T()},onMouseLeave:()=>{k&&typeof k=="function"&&k()},children:Ie(U)}),!Q&&G&&R.jsxs("div",{className:ci.inputDropDown,style:V??{},onClick:()=>P(!0),ref:S,children:[H.find(qe=>qe.id===L).label,re&&R.jsx("ul",{ref:ce,style:y??{},children:H&&H.length&&H.map((qe,ct)=>R.jsx("li",{style:w??{},onClick:()=>it(qe),children:(qe==null?void 0:qe.label)??"-"},qe.id))}),R.jsx(Sh,{})]}),Q&&R.jsx("div",{className:`${ci.inputDropDown} ${ci.http}`,style:I??{},onClick:()=>P(!0),ref:S,children:"http://"}),R.jsxs("div",{className:ci.inputContent,children:[K&&p&&p.length>0&&R.jsx("div",{className:ci.inputTags,children:p.map((qe,ct)=>R.jsx("div",{className:ci.inputSingleTags,children:R.jsx(Dg,{...F,id:qe,label:qe,withClose:!0})},ct))}),R.jsx("input",{ref:Ce,style:B??{},type:a??"text",value:e,onChange:qe=>he(qe),onFocus:ye,onBlur:oe,disabled:r,required:n,onKeyDown:we,readOnly:c,spellCheck:!1,placeholder:i??"",autoComplete:"off",maxLength:h})]}),W&&R.jsx("div",{className:ci.rightIcon,style:$??{},onClick:()=>{g&&typeof g=="function"&&g()},onMouseEnter:()=>{C&&typeof C=="function"&&C()},onMouseLeave:()=>{m&&typeof m=="function"&&m()},children:Ie(W)})]}),E&&R.jsxs("div",{style:z??{},onClick:Be,className:ci.withCopy,children:[R.jsx(bB,{}),"Copy"]})]}),d&&(d==null?void 0:d.visible)&&R.jsx("div",{style:N??{},className:`${ci.inputHelperText} ${d!=null&&d.error?ci.error:""}`,children:R.jsx("p",{style:(d==null?void 0:d.style)??{},children:d.text})})]})},MB="Textarea-module__textareaContainer",VB="Textarea-module__textAreaLabel",NB="Textarea-module__required",HB="Textarea-module__wrap",$B="Textarea-module__textarea",WB="Textarea-module__focused",zB="Textarea-module__disabled",GB="Textarea-module__error",UB="Textarea-module__helperTextStyle",vn={textareaContainer:MB,textAreaLabel:VB,required:NB,wrap:HB,textarea:$B,focused:WB,disabled:zB,error:GB,helperTextStyle:UB},KB=({width:e,height:t,color:i})=>R.jsxs("svg",{width:e??"16",height:t??"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[R.jsx("g",{id:"help-circle",clipPath:"url(#clip0_433_6293)",children:R.jsx("path",{id:"Icon",d:"M6.05992 5.99998C6.21665 5.55442 6.52602 5.17872 6.93322 4.9394C7.34042 4.70009 7.81918 4.61261 8.2847 4.69245C8.75022 4.7723 9.17246 5.01433 9.47664 5.37567C9.78081 5.737 9.94729 6.19433 9.94659 6.66665C9.94659 7.99998 7.94659 8.66665 7.94659 8.66665M7.99992 11.3333H8.00659M14.6666 7.99998C14.6666 11.6819 11.6818 14.6666 7.99992 14.6666C4.31802 14.6666 1.33325 11.6819 1.33325 7.99998C1.33325 4.31808 4.31802 1.33331 7.99992 1.33331C11.6818 1.33331 14.6666 4.31808 14.6666 7.99998Z",stroke:i??"#A4A7AE",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})}),R.jsx("defs",{children:R.jsx("clipPath",{id:"clip0_433_6293",children:R.jsx("rect",{width:e??"16",height:t??"16",fill:"white"})})})]}),jB=({placeholder:e,label:t,msg:i,cols:n,rows:r,value:a,maxLength:o,onChange:s,onFocus:l,onBlur:u,disabled:d,required:c,textareaContainerStyle:h,textareaLabelStyle:f,requiredStyle:p,textareaStyle:g,textareaHelperTextStyle:C})=>{const[m,x]=ve.useState(!1),T=W=>{let U=W.target.value;s&&typeof s=="function"&&s(U)},k=()=>{x(!0),l&&typeof l=="function"&&l()},D=()=>{x(!1),u&&typeof u=="function"&&u()};return R.jsxs("div",{style:h??{},className:`${vn.textareaContainer} ${i!=null&&i.type&&(i!=null&&i.visible)?vn[i==null?void 0:i.type]:""} ${d?vn.disabled:null}`,children:[t&&R.jsxs("div",{style:f,className:vn.textAreaLabel,children:[R.jsx("p",{children:t}),R.jsx("span",{style:p??{},className:vn.required,children:c&&"*"}),R.jsx(KB,{})]}),R.jsx("div",{className:vn.wrap,children:R.jsx("textarea",{style:g??{},className:`${vn.textarea} ${m?vn.focused:""} ${d?vn.disabled:""} ${i!=null&&i.error?vn.error:""}`,value:a,placeholder:e??"",cols:n??"30",rows:r??"5",maxLength:o??null,onFocus:k,disabled:d,onBlur:D,onChange:T})}),i&&(i==null?void 0:i.text)&&(i==null?void 0:i.text.length)>0&&R.jsx("div",{style:C??{},className:`${vn.helperTextStyle} ${i!=null&&i.error?vn.error:""}`,children:R.jsx("p",{style:(i==null?void 0:i.style)??{},children:i.text})})]})},qB="Toggle-module__toggleWrapper",YB="Toggle-module__toggleState",XB="Toggle-module__checked",ZB="Toggle-module__disabled",id={toggleWrapper:qB,toggleState:YB,checked:XB,disabled:ZB},QB=({checked:e,change:t,disabled:i,required:n,activeStyle:r,bgStyle:a,checkedBgStyle:o,disabledBgStyle:s,circleStyle:l,checkedCircleStyle:u,disabledCircleStyle:d})=>{const[c,h]=ve.useState(!1),f=()=>{t&&typeof t=="function"&&t(!e)},p=()=>{if(c)return r??{};if(e){if(o)return o}else if(e){if(i&&s)return s}else if(a)return a;return{}},g=()=>{if(e){if(u)return u}else if(e){if(i&&d)return d}else if(l)return l;return{}};return R.jsx("div",{style:p(),onMouseDown:()=>h(!0),onMouseUp:()=>h(!1),onMouseLeave:()=>h(!1),onClick:f,className:`${id.toggleWrapper} ${e?id.checked:""} ${i?id.disabled:""}`,children:R.jsx("div",{style:g(),className:id.toggleState,children:R.jsx("input",{type:"checkbox",checked:e,readOnly:!0,disabled:i??!1,hidden:!0,required:n??!1})})})},JB="Radio-module__radioWrapper",eL="Radio-module__sm",tL="Radio-module__md",iL="Radio-module__checked",nL="Radio-module__innerCircle",rL="Radio-module__radioState",aL="Radio-module__disabled",Oa={radioWrapper:JB,sm:eL,md:tL,checked:iL,innerCircle:nL,radioState:rL,disabled:aL},mI=({checked:e,change:t,disabled:i,isRequired:n,withUncheckState:r,size:a})=>{ve.useState(!1);const o=()=>{t&&typeof t=="function"&&(r||!r&&!e)&&t(!0)};return R.jsxs("div",{className:`${Oa.radioWrapper} ${Oa[a]??Oa.md} ${e?Oa.checked:""} ${i?Oa.disabled:""}`,onClick:o,children:[R.jsx("input",{type:"radio",checked:!0,readOnly:!0,hidden:!0,disabled:i??!1,required:n??!1}),R.jsx("div",{className:Oa.radioState,children:R.jsx("div",{className:Oa.innerCircle})})]})},oL="Dropdown-module__dropdownWrapper",sL="Dropdown-module__placeHolder",lL="Dropdown-module__dropdownLabel",uL="Dropdown-module__required",dL="Dropdown-module__dropdownContainer",cL="Dropdown-module__sm",hL="Dropdown-module__md",fL="Dropdown-module__selectedTags",pL="Dropdown-module__selectedList",vL="Dropdown-module__additional",_L="Dropdown-module__dropdownListContainer",gL="Dropdown-module__dropdownList",mL="Dropdown-module__checkIcon",CL="Dropdown-module__disabled",yL="Dropdown-module__selected",xL="Dropdown-module__dropdownListFooter",bL="Dropdown-module__focused",SL="Dropdown-module__error",EL="Dropdown-module__dropdownHelperText",li={dropdownWrapper:oL,placeHolder:sL,dropdownLabel:lL,required:uL,dropdownContainer:dL,sm:cL,md:hL,selectedTags:fL,selectedList:pL,additional:vL,dropdownListContainer:_L,dropdownList:gL,checkIcon:mL,disabled:CL,selected:yL,dropdownListFooter:xL,focused:bL,error:SL,dropdownHelperText:EL},wL=()=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1.5rem",height:"1.5rem",fill:"none",viewBox:"0 0 20 20",children:R.jsx("path",{stroke:"#10B77F",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",d:"M10 18.333c4.584 0 8.334-3.75 8.334-8.334 0-4.583-3.75-8.333-8.334-8.333-4.583 0-8.333 3.75-8.333 8.333 0 4.584 3.75 8.334 8.333 8.334zM6.667 10h6.667M10 13.333V6.666"})}),IL=()=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",children:R.jsx("path",{d:"M16.5 16.5L13.5834 13.5833M15.6667 8.58333C15.6667 12.4954 12.4954 15.6667 8.58333 15.6667C4.67132 15.6667 1.5 12.4954 1.5 8.58333C1.5 4.67132 4.67132 1.5 8.58333 1.5C12.4954 1.5 15.6667 4.67132 15.6667 8.58333Z",stroke:"#717680",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),r_=({label:e,disabled:t,required:i,size:n="md",placeholder:r,msg:a,readOnly:o,searchValue:s,onClearAll:l,onSelectAll:u,onBottomScroll:d,withClearAll:c=!0,withSelectAll:h=!0,withPlus:f=!1,searchComponent:p=!1,withFooter:g=!0,data:C,onSelect:m,selectedOptionID:x,withFilter:T=!0,withClose:k=!0,fixedDropdown:D=!1,onSearch:W,pagination:U,withMultiSelect:G=!1,skipSelected:H,labelIcon:j,closeIcon:K,dropdownIcon:F,iconDown:Q,onLabelIconClick:E,onLabelIconMouseEnter:X,onLabelIconMouseLeave:se,dropdownWrapperStyle:te,dropdownLabelStyle:ge,requiredStyle:ne,labelIconStyle:Y,dropdownContainerStyle:V,placeHolderStyle:y,selectedTagsStyle:w,selectedListStyle:I,additionalStyle:B,dropdownListStyle:$,listStyle:z})=>{const[N,J]=ve.useState(!1),[ae,Ce]=ve.useState(!1),[le,De]=ve.useState(""),[S,ce]=ve.useState("");ve.useState(null);const re=ve.useRef([]),P=ve.useRef(null),L=ve.useRef(null),q=ve.useRef({}),he=(Se,ht)=>{const oi=new Set;return Se.filter(ki=>oi.has(ki[ht])?!1:(oi.add(ki[ht]),!0))},ye=Se=>{var ht;C.forEach(oi=>{Se.id===oi.id?oi.selected=!0:oi.selected=!1}),q.current=Se,De((ht=q.current)==null?void 0:ht.label),m&&typeof m=="function"&&m(q.current),Ce(!1)},oe=Se=>{re.current=[...re.current,...C.filter(ht=>ht.selected==!0),...C.filter(ht=>ht.id===Se.id)],Se.selected=!Se.selected,re.current=he(re.current,"id").filter(ht=>ht.selected),m&&typeof m=="function"&&m(re.current),p||De(re.current.map(ht=>ht.label).join(", ")),J(ht=>!ht)},we=Se=>{Se.stopPropagation(),re.current=[],x=null,C&&C.length>0&&C.forEach(ht=>ht.selected=!1),Be(""),m(G?[]:{}),De("")},Be=Se=>{W&&typeof W=="function"&&W(Se),ce(Se),De(Se)},Ie=()=>{if(x||x===0){let Se=C.filter(ht=>Number(ht.id)===Number(x));Se&&Se[0]&&(q.current=Se[0],H?(W&&typeof W=="function"&&W(q.current.label),De(q.current.label),closeOnSelect&&setCollapsed(ht=>!1),withDropdownSearch&&DropdownSearchValue&&SetDropdownSearchValue("")):ye(Se[0]))}},[$e,Ye]=ve.useState(!1),it=Se=>{let ht=P.current.querySelector("ul"),ki=Math.abs(ht.scrollTop+ht.clientHeight-ht.scrollHeight)<=2;U&&ki&&!$e&&(d&&typeof d=="function"&&d(!0),Ye(!0)),ki||Ye(!1)},Gt=()=>{C.forEach(Se=>{Se.selected=!1}),re.current=[],m([]),De(""),l&&typeof l=="function"&&l(),J(Se=>!Se)},qe=()=>{C.forEach(Se=>{Se.selected=!0}),re.current=C,re.current=he(re.current,"id").filter(Se=>Se.selected),De(re.current.map(Se=>Se.label).join(", ")),u&&typeof u=="function"&&u(),m(re.current),J(Se=>!Se)},ct=Se=>Se,Ti=Se=>{Se.composedPath().includes(P.current)||Ce(!1)},Et=Se=>{if(D){if(Se.composedPath().includes(P.current))return;Ce(!1)}},Ui=()=>{const Se=L.current;if(!Se)return;const ht=Se.getBoundingClientRect(),oi=window.innerHeight;ht.bottom>oi?(Se.style.top="unset",Se.style.bottom="calc(100% + 8px)"):(Se.style.bottom="unset",Se.style.top="calc(100% + 8px)")},Ki=ve.useRef(null);return ve.useEffect(()=>{ae&&Ki.current&&Ki.current.focus()},[ae]),ve.useEffect(()=>{G&&(re.current=C.filter(Se=>Se.selected),De(C.filter(Se=>Se.selected).map(Se=>Se.label).join(", ")))},[]),ve.useEffect(()=>{p&&s&&s.length>0&&ce(s)},[]),ve.useEffect(()=>{Ui()},[L,ae]),ve.useEffect(()=>{G||Ie()},[x]),ve.useEffect(()=>(document.addEventListener("click",Ti),document.addEventListener("wheel",Et),()=>{document.removeEventListener("click",Ti),document.removeEventListener("wheel",Et)}),[]),R.jsxs("div",{className:li.dropdownWrapper,style:te??{},children:[e&&R.jsxs("label",{className:li.dropdownLabel,style:ge??{},children:[e," ",R.jsx("span",{className:li.required,style:ne??{},children:i&&"*"}),R.jsxs("span",{style:{...Y??{},display:"grid",placeItems:"center"},onClick:()=>{E&&typeof E=="function"&&E()},onMouseEnter:()=>{X&&typeof X=="function"&&X()},onMouseLeave:()=>{se&&typeof se=="function"&&se()},children:[" ",ct(j)]})]}),R.jsxs("div",{ref:P,onClick:()=>(Ce(Se=>!Se),Ui()),className:`${li.dropdownContainer} ${ae&&!o?li.focused:""} ${t?li.disabled:""} ${a!=null&&a.error?li.error:""} ${li[n]}`,style:V??{},children:[p?R.jsxs("div",{children:[" ",R.jsx(IL,{})]}):R.jsx(R.Fragment,{children:F&&R.jsx("div",{style:{display:"grid",alignItems:"center",marginRight:"0.5rem"},children:ct(F)})}),!p&&G&&r&&!ae&&re.current.length===0&&R.jsx("span",{className:li.placeHolder,style:y??{},children:r??""}),G&&R.jsx("div",{className:li.selectedTags,style:w??{},children:!p&&!ae?R.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"flex-start"},children:[re.current.slice(0,3).map((Se,ht)=>{let oi=re.current[re.current.length-1];return R.jsxs("span",{className:li.selectedList,style:I??{},children:[!f&&Se.label,!f&&Se.id!==oi.id&&ht!==2?", ":""]},Se==null?void 0:Se.id)}),!f&&re.current.length>3&&R.jsxs("span",{className:li.additional,style:B??{},children:[" ","+(",re.current.length-3,")"]})]}):R.jsx("input",{ref:Ki,onClick:Se=>(Se.stopPropagation(),Ce(!0)),autoCorrect:"off",placeholder:"Search...",type:"text",...p?{value:S}:{},onChange:Se=>Be(Se.target.value)},x)}),R.jsx("input",{autoCorrect:"off",hidden:G,placeholder:r,readOnly:!T||!ae||G,type:"text",value:G&&!p&&ae?"":le,onChange:Se=>Be(Se.target.value)},x),C&&C.length>0&&ae&&R.jsxs("div",{ref:L,onClick:Se=>Se.stopPropagation(),className:li.dropdownListContainer,children:[R.jsx("ul",{onScroll:Se=>it(),onClick:Se=>Se.stopPropagation(),className:li.dropdownList,style:$??{},children:C.map(Se=>R.jsxs("li",{style:z??{},className:`${!(Se!=null&&Se.label)||Se.label===void 0||Se!=null&&Se.disabled?li.disabled:""} ${Se!=null&&Se.selected?li.selected:""}`,onClick:()=>{G?oe(Se):ye(Se)},children:[R.jsxs("p",{children:[" ",Se!=null&&Se.customLabel?Se.customLabel():(Se==null?void 0:Se.label)??"-"]}),f?R.jsx(R.Fragment,{children:Se.selected?R.jsx(_I,{}):R.jsx(wL,{})}):(Se==null?void 0:Se.selected)&&R.jsx("span",{className:li.checkIcon,children:R.jsx(vI,{color:"#7F56D9",width:20,height:20})})]},Se==null?void 0:Se.id))}),G&&g&&R.jsxs("div",{className:li.dropdownListFooter,children:[c&&R.jsx("span",{onClick:Gt,children:"Clear All"}),h&&R.jsx("span",{onClick:qe,children:"Select All"})]})]}),!G&&k&&(re.current.length>0||le.length)>0&&R.jsx("div",{onClick:Se=>we(Se),style:{display:"grid",placeItems:"center",cursor:"pointer"},children:K?ct(K):R.jsx(gu,{width:16,height:16})}),Q?ct(Q):R.jsx("div",{style:{display:"grid",placeItems:"center",transform:ae?"rotate(180deg)":"",transition:"transform 0.2s ease-in-out",cursor:"pointer",marginLeft:"10px"},children:!p&&R.jsx(Sh,{})})]}),a&&(a==null?void 0:a.visible)&&R.jsx("div",{className:`${li.dropdownHelperText} ${a!=null&&a.error?li.error:""}`,children:!ae&&R.jsx("p",{style:(a==null?void 0:a.style)??{},children:a.text})})]})},TL="Tooltip-module__tooltipContainer",AL="Tooltip-module__tooltipContent",DL="Tooltip-module__top",OL="Tooltip-module__right",RL="Tooltip-module__bottom",kL="Tooltip-module__left",BL="Tooltip-module__tooltipTitle",LL="Tooltip-module__tooltipText",Fo={tooltipContainer:TL,tooltipContent:AL,top:DL,right:OL,bottom:RL,left:kL,tooltipTitle:BL,tooltipText:LL},PL=({children:e,tooltipSlot:t,delay:i,placement:n="top",trigger:r="click",title:a,text:o,tooltipContentStyle:s,tooltipTitlestyle:l,tooltipTextStyle:u,pointerPosition:d="10%",fixedPosition:c=!1})=>{const h=ve.useRef(null),f=ve.useRef(null),p=ve.useRef({top:0,left:0});let g;const[C,m]=ve.useState(!1),x=()=>{r==="hover"&&(g=setTimeout(()=>{m(!0)},i||400))},T=()=>{r==="hover"&&(clearTimeout(g),setTimeout(()=>{m(!1)},i||400))},k=()=>{r==="click"&&m(W=>!W)},D=W=>{W.composedPath().includes(h.current)||m(!1)};return ve.useEffect(()=>(document.addEventListener("click",D),()=>{document.removeEventListener("click",D)}),[]),ve.useEffect(()=>{const W=f.current;W&&W.style.setProperty("--pointer-position",`${d}`)},[C]),R.jsxs("div",{ref:h,className:Fo.tooltipContainer,onClick:k,onMouseEnter:x,onMouseLeave:T,children:[e,C&&t?t():C&&R.jsxs("div",{style:c?{...s??{},top:p.current.top,left:p.current.left,position:"fixed",zIndex:"150"}:{...s??{}},onClick:W=>W.stopPropagation(),ref:f,className:`${Fo.tooltipContent} ${n?Fo[n]:Fo.bottom}`,children:[a&&a.length>0&&R.jsx("h2",{className:Fo.tooltipTitle,style:l??{},children:a}),o&&o.length>0&&R.jsx("p",{className:Fo.tooltipText,style:u??{},children:o})]})]})},FL="Popup-module__modalOverlay",ML="Popup-module__popupDrawerMode",VL="Popup-module__popupContainer",NL="Popup-module__EnterFromLeft",HL="Popup-module__fadeIn",$L="Popup-module__withOptions",WL="Popup-module__horizontal",zL="Popup-module__popupHeader",GL="Popup-module__popupTitle",UL="Popup-module__popupDescription",KL="Popup-module__typeIcon",jL="Popup-module__icon",qL="Popup-module__templateWrapper",kn={modalOverlay:FL,popupDrawerMode:ML,popupContainer:VL,enterFromLeft:NL,fadeIn:HL,withOptions:$L,horizontal:WL,popupHeader:zL,popupTitle:GL,popupDescription:UL,typeIcon:KL,icon:jL,templateWrapper:qL},YL=e=>{const t=["bytes","KB","MB","GB","TB","PB","EB","ZB","YB"];let i=0,n=parseInt(e,10)||0;for(;n>=1024&&++i;)n=n/1024;return n.toFixed(n<10&&i>0?1:0)+" "+t[i]},XL=e=>e.slice((e.lastIndexOf(".")-1>>>0)+2),ZL=e=>new Promise((t,i)=>{const n=new FileReader;n.readAsDataURL(e),n.onload=()=>t(n.result.split(",")[1]),n.onerror=r=>i(r)});location.href.indexOf(".upgaming.dev")>0||location.href.indexOf(".upgaming.com")>0;const QL=(e,t)=>{const i=new Set;return e.filter(n=>i.has(n[t])?!1:(i.add(n[t]),!0))},JL=()=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:R.jsx("path",{d:"M7.5 12L10.5 15L16.5 9M22 12C22 17.5228 17.5228 22 12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12Z",stroke:"#079455",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})}),eP=()=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:R.jsx("path",{d:"M7 3V6.4C7 6.96005 7 7.24008 7.10899 7.45399C7.20487 7.64215 7.35785 7.79513 7.54601 7.89101C7.75992 8 8.03995 8 8.6 8H15.4C15.9601 8 16.2401 8 16.454 7.89101C16.6422 7.79513 16.7951 7.64215 16.891 7.45399C17 7.24008 17 6.96005 17 6.4V4M17 21V14.6C17 14.0399 17 13.7599 16.891 13.546C16.7951 13.3578 16.6422 13.2049 16.454 13.109C16.2401 13 15.9601 13 15.4 13H8.6C8.03995 13 7.75992 13 7.54601 13.109C7.35785 13.2049 7.20487 13.3578 7.10899 13.546C7 13.7599 7 14.0399 7 14.6V21M21 9.32548V16.2C21 17.8802 21 18.7202 20.673 19.362C20.3854 19.9265 19.9265 20.3854 19.362 20.673C18.7202 21 17.8802 21 16.2 21H7.8C6.11984 21 5.27976 21 4.63803 20.673C4.07354 20.3854 3.6146 19.9265 3.32698 19.362C3 18.7202 3 17.8802 3 16.2V7.8C3 6.11984 3 5.27976 3.32698 4.63803C3.6146 4.07354 4.07354 3.6146 4.63803 3.32698C5.27976 3 6.11984 3 7.8 3H14.6745C15.1637 3 15.4083 3 15.6385 3.05526C15.8425 3.10425 16.0376 3.18506 16.2166 3.29472C16.4184 3.4184 16.5914 3.59135 16.9373 3.93726L20.0627 7.06274C20.4086 7.40865 20.5816 7.5816 20.7053 7.78343C20.8149 7.96237 20.8957 8.15746 20.9447 8.36154C21 8.59171 21 8.8363 21 9.32548Z",stroke:"#DC6803",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})}),CI=({width:e,color:t})=>R.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"24",height:e??"24",viewBox:"0 0 24 24",fill:"none",children:R.jsx("path",{d:"M16 6V5.2C16 4.0799 16 3.51984 15.782 3.09202C15.5903 2.71569 15.2843 2.40973 14.908 2.21799C14.4802 2 13.9201 2 12.8 2H11.2C10.0799 2 9.51984 2 9.09202 2.21799C8.71569 2.40973 8.40973 2.71569 8.21799 3.09202C8 3.51984 8 4.0799 8 5.2V6M10 11.5V16.5M14 11.5V16.5M3 6H21M19 6V17.2C19 18.8802 19 19.7202 18.673 20.362C18.3854 20.9265 17.9265 21.3854 17.362 21.673C16.7202 22 15.8802 22 14.2 22H9.8C8.11984 22 7.27976 22 6.63803 21.673C6.07354 21.3854 5.6146 20.9265 5.32698 20.362C5 19.7202 5 18.8802 5 17.2V6",stroke:t??"#D92D20",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})}),Og=({visible:e,template:t,options:i,children:n,onClickOutside:r,onClose:a,widthType:o,modalOverlayStyle:s,popupContainerStyle:l,templateWrapperStyle:u,popupHeaderStyle:d,popupTitleStyle:c})=>{const h=()=>{if(!(!i||!(i!=null&&i.type)))switch(String(i==null?void 0:i.type)){case"delete":return R.jsx(CI,{});case"unsaved":return R.jsx(eP,{});case"success":return R.jsx(JL,{})}},f=()=>{a&&typeof a=="function"&&a(!1)},p=ve.useRef(null),g=C=>{C.target===p.current&&r&&typeof r=="function"&&r(!1)};return ve.useEffect(()=>(document.addEventListener("click",g),()=>{document.removeEventListener("click",g)}),[]),e&&R.jsx("div",{ref:p,style:s??{},className:`
32
32
  mcModal_global
33
33
  ${kn.modalOverlay}
34
34
  ${i&&i.mode==="drawer"?kn.popupDrawerMode:""}
@@ -1223,7 +1223,7 @@ const eB = "MainButton-module__mainButton", tB = "MainButton-module__sm", iB = "
1223
1223
  }, Ee = (be) => {
1224
1224
  be.stopPropagation(), re.current = [], x = null, C && C.length > 0 && C.forEach((ft) => ft.selected = !1), ke(""), m(G ? [] : {}), Ae("");
1225
1225
  }, ke = (be) => {
1226
- W && typeof W == "function" && W(be), Ae(be), p && ce(be);
1226
+ W && typeof W == "function" && W(be), ce(be), Ae(be);
1227
1227
  }, we = () => {
1228
1228
  if (x || x === 0) {
1229
1229
  let be = C.filter((ft) => Number(ft.id) === Number(x));
@@ -1265,7 +1265,7 @@ const eB = "MainButton-module__mainButton", tB = "MainButton-module__sm", iB = "
1265
1265
  ji();
1266
1266
  }, [L, ae]), Et(() => {
1267
1267
  G || we();
1268
- }, [x, C]), Et(() => (document.addEventListener("click", Di), document.addEventListener("wheel", It), () => {
1268
+ }, [x]), Et(() => (document.addEventListener("click", Di), document.addEventListener("wheel", It), () => {
1269
1269
  document.removeEventListener("click", Di), document.removeEventListener("wheel", It);
1270
1270
  }), []), /* @__PURE__ */ R.jsxs("div", { className: di.dropdownWrapper, style: te ?? {}, children: [
1271
1271
  e && /* @__PURE__ */ R.jsxs("label", { className: di.dropdownLabel, style: _e ?? {}, children: [
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "master-components-react",
3
3
  "private": false,
4
- "version": "1.18.7",
4
+ "version": "1.18.10",
5
5
  "type": "module",
6
6
  "main": "dist/master-components-react.cjs.js",
7
7
  "module": "dist/master-components-react.es.js",