master-components-react 1.17.19 → 1.17.21
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,Gk,Da),Aa[Da+mf]=!0}}return Z===n?gf(si):_f(si),si}}function Hk(Z,Te,Ve){return hr(Z,Te,Ve,!0)}function $k(Z,Te,Ve){return hr(Z,Te,Ve,!1)}var Wk=$k,zk=Hk;zs.Fragment=n,zs.jsx=Wk,zs.jsxs=zk}()),zs}process.env.NODE_ENV==="production"?n_.exports=Kk():n_.exports=jk();var R=n_.exports;const qk="MainButton-module__mainButton",Yk="MainButton-module__sm",Xk="MainButton-module__onlyIcon",Zk="MainButton-module__buttonSlot",Qk="MainButton-module__buttonLabel",Jk="MainButton-module__md",eB="MainButton-module__lg",tB="MainButton-module__xl",iB="MainButton-module__xl2",nB="MainButton-module__disabled",Bo={mainButton:qk,sm:Yk,onlyIcon:Xk,buttonSlot:Zk,buttonLabel:Qk,md:Jk,lg:eB,xl:tB,xl2:iB,disabled:nB},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:""]})}),rB="FormInput-module__inputWrapper",aB="FormInput-module__inputLabel",oB="FormInput-module__required",sB="FormInput-module__inputContainer",lB="FormInput-module__inputContent",uB="FormInput-module__inputTags",dB="FormInput-module__focused",cB="FormInput-module__error",hB="FormInput-module__rightIcon",fB="FormInput-module__leftIcon",pB="FormInput-module__inputDropDown",vB="FormInput-module__http",_B="FormInput-module__disabled",gB="FormInput-module__sm",mB="FormInput-module__md",CB="FormInput-module__withCopy",yB="FormInput-module__inputHelperText",ci={inputWrapper:rB,inputLabel:aB,required:oB,inputContainer:sB,inputContent:lB,inputTags:uB,focused:dB,error:cB,rightIcon:hB,leftIcon:fB,inputDropDown:pB,http:vB,disabled:_B,sm:gB,md:mB,withCopy:CB,inputHelperText:yB},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"})}),xB=({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"})}),bB="Checkbox-module__checkboxWrapper",SB="Checkbox-module__sm",EB="Checkbox-module__md",wB="Checkbox-module__checkMark",IB="Checkbox-module__checked",TB="Checkbox-module__disabled",Lo={checkboxWrapper:bB,sm:SB,md:EB,checkMark:wB,checked:IB,disabled:TB},pI=({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"})}),vI=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=_e.useRef(null),[u,d]=_e.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(vI,{}):R.jsx(pI,{}):""]})},AB="Tag-module__tagContainer",DB="Tag-module__onlyLabel",OB="Tag-module__sm",RB="Tag-module__md",kB="Tag-module__lg",BB="Tag-module__tagLabel",LB="Tag-module__tagNumber",PB="Tag-module__tagClose",Po={tagContainer:AB,onlyLabel:DB,sm:OB,md:RB,lg:kB,tagLabel:BB,tagNumber:LB,tagClose:PB},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"})})]})},_I=({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:b,onLeftIconIconMouseEnter:T,onLeftIconIconMouseLeave:k,onPressEnter:D,rightIcon:W,leftIcon:z,withDropDown:U,dropdownData:H,onSelectData:j,withTags:K,tagProps:F,withLink:Q,withCopy:E,onCopy:X,inputWrapperStyle:oe,inputLabelStyle:te,requiredStyle:me,inputContainerStyle:ne,leftIconStyle:q,inputDropDownStyle:V,ulStyle:y,liStyle:w,httpStyle:I,inputStyle:B,rightIconStyle:$,withCopyStyle:G,inputHelperTextStyle:N})=>{const[J,ae]=_e.useState(!1),ve=_e.useRef(null),[se,De]=_e.useState(!1);_e.useState(!1);const S=_e.useRef(null),ce=_e.useRef(null),[le,L]=_e.useState(!1),[P,Y]=_e.useState(1),he=je=>{let gt=je.target.value;gt.length===1&&(gt=gt.trim()),s&&typeof s=="function"&&s(f?gt.replace(/\d/g,""):gt)},ye=()=>{De(!0),l&&typeof l=="function"&&l()},re=()=>{De(!1),u&&typeof u=="function"&&u()},we=je=>{const gt=je.target.value,Ai=gt.length===0;a==="number"&&(je.keyCode===69||!Ai&&(je.keyCode===187||je.keyCode===107||je.keyCode===189||je.keyCode===109))&&je.preventDefault(),je.key==="Enter"&>&>.length>0&&D&&typeof D=="function"&&D(gt)},Le=()=>{X&&typeof X=="function"&&X(e)},Ie=je=>je,$e=()=>{let je={};return E&&(je.borderTopRightRadius=0,je.borderBottomRightRadius=0,je.borderRight=0),U&&(je.paddingLeft=0),{...je,...ne??{}}},Xe=je=>{!je.composedPath().includes(ce.current)&&je.composedPath().includes(S.current)||L(!1)},it=je=>{Y(je.id),L(!1),j&&typeof j=="function"&&j(je)};_e.useEffect(()=>{e&&e.length===0&&calculateWidth()},[e]),_e.useEffect(()=>(document.addEventListener("click",Xe),()=>{document.removeEventListener("click",Xe)}),[]);const Ft=_e.useRef(!1);return _e.useEffect(()=>{Ft.current?setTimeout(()=>{ae(je=>!je)},0):Ft.current=!0},[]),R.jsxs("div",{className:ci.inputWrapper,style:oe??{},children:[t&&R.jsxs("label",{className:ci.inputLabel,style:te??{},children:[t," ",R.jsx("span",{className:ci.required,style:me??{},children:n&&"*"})]}),R.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[R.jsxs("div",{style:$e(),className:`${ci.inputContainer} ${se&&!c?ci.focused:""} ${r?ci.disabled:""} ${d!=null&&d.error?ci.error:""} ${ci[o??"sm"]}`,children:[!U&&!Q&&z&&R.jsx("div",{className:ci.leftIcon,style:q??{},onClick:()=>{b&&typeof b=="function"&&b()},onMouseEnter:()=>{T&&typeof T=="function"&&T()},onMouseLeave:()=>{k&&typeof k=="function"&&k()},children:Ie(z)}),!Q&&U&&R.jsxs("div",{className:ci.inputDropDown,style:V??{},onClick:()=>L(!0),ref:S,children:[H.find(je=>je.id===P).label,le&&R.jsx("ul",{ref:ce,style:y??{},children:H&&H.length&&H.map((je,gt)=>R.jsx("li",{style:w??{},onClick:()=>it(je),children:(je==null?void 0:je.label)??"-"},je.id))}),R.jsx(Sh,{})]}),Q&&R.jsx("div",{className:`${ci.inputDropDown} ${ci.http}`,style:I??{},onClick:()=>L(!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((je,gt)=>R.jsx("div",{className:ci.inputSingleTags,children:R.jsx(Dg,{...F,id:je,label:je,withClose:!0})},gt))}),R.jsx("input",{ref:ve,style:B??{},type:a??"text",value:e,onChange:je=>he(je),onFocus:ye,onBlur:re,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:G??{},onClick:Le,className:ci.withCopy,children:[R.jsx(xB,{}),"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})})]})},FB="Textarea-module__textareaContainer",MB="Textarea-module__textAreaLabel",VB="Textarea-module__required",NB="Textarea-module__wrap",HB="Textarea-module__textarea",$B="Textarea-module__focused",WB="Textarea-module__disabled",zB="Textarea-module__error",GB="Textarea-module__helperTextStyle",fn={textareaContainer:FB,textAreaLabel:MB,required:VB,wrap:NB,textarea:HB,focused:$B,disabled:WB,error:zB,helperTextStyle:GB},UB=({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"})})})]}),KB=({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,b]=_e.useState(!1),T=W=>{let z=W.target.value;s&&typeof s=="function"&&s(z)},k=()=>{b(!0),l&&typeof l=="function"&&l()},D=()=>{b(!1),u&&typeof u=="function"&&u()};return R.jsxs("div",{style:h??{},className:`${fn.textareaContainer} ${i!=null&&i.type&&(i!=null&&i.visible)?fn[i==null?void 0:i.type]:""} ${d?fn.disabled:null}`,children:[t&&R.jsxs("div",{style:f,className:fn.textAreaLabel,children:[R.jsx("p",{children:t}),R.jsx("span",{style:p??{},className:fn.required,children:c&&"*"}),R.jsx(UB,{})]}),R.jsx("div",{className:fn.wrap,children:R.jsx("textarea",{style:g??{},className:`${fn.textarea} ${m?fn.focused:""} ${d?fn.disabled:""} ${i!=null&&i.error?fn.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:`${fn.helperTextStyle} ${i!=null&&i.error?fn.error:""}`,children:R.jsx("p",{style:(i==null?void 0:i.style)??{},children:i.text})})]})},jB="Toggle-module__toggleWrapper",qB="Toggle-module__toggleState",YB="Toggle-module__checked",XB="Toggle-module__disabled",id={toggleWrapper:jB,toggleState:qB,checked:YB,disabled:XB},ZB=({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]=_e.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})})})},QB="Radio-module__radioWrapper",JB="Radio-module__sm",eL="Radio-module__md",tL="Radio-module__checked",iL="Radio-module__innerCircle",nL="Radio-module__radioState",rL="Radio-module__disabled",Oa={radioWrapper:QB,sm:JB,md:eL,checked:tL,innerCircle:iL,radioState:nL,disabled:rL},gI=({checked:e,change:t,disabled:i,isRequired:n,withUncheckState:r,size:a})=>{_e.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})})]})},aL="Dropdown-module__dropdownWrapper",oL="Dropdown-module__placeHolder",sL="Dropdown-module__dropdownLabel",lL="Dropdown-module__required",uL="Dropdown-module__dropdownContainer",dL="Dropdown-module__sm",cL="Dropdown-module__md",hL="Dropdown-module__selectedTags",fL="Dropdown-module__selectedList",pL="Dropdown-module__additional",vL="Dropdown-module__dropdownListContainer",_L="Dropdown-module__dropdownList",gL="Dropdown-module__checkIcon",mL="Dropdown-module__disabled",CL="Dropdown-module__selected",yL="Dropdown-module__dropdownListFooter",xL="Dropdown-module__focused",bL="Dropdown-module__error",SL="Dropdown-module__dropdownHelperText",li={dropdownWrapper:aL,placeHolder:oL,dropdownLabel:sL,required:lL,dropdownContainer:uL,sm:dL,md:cL,selectedTags:hL,selectedList:fL,additional:pL,dropdownListContainer:vL,dropdownList:_L,checkIcon:gL,disabled:mL,selected:CL,dropdownListFooter:yL,focused:xL,error:bL,dropdownHelperText:SL},EL=()=>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"})}),wL=()=>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,onClearAll:s,onSelectAll:l,onBottomScroll:u,withClearAll:d=!0,withSelectAll:c=!0,withPlus:h=!1,searchComponent:f=!1,withFooter:p=!0,data:g,onSelect:C,selectedOptionID:m,withFilter:b=!0,withClose:T=!0,fixedDropdown:k=!1,onSearch:D,pagination:W,withMultiSelect:z=!1,skipSelected:U,labelIcon:H,closeIcon:j,dropdownIcon:K,iconDown:F,onLabelIconClick:Q,onLabelIconMouseEnter:E,onLabelIconMouseLeave:X,dropdownWrapperStyle:oe,dropdownLabelStyle:te,requiredStyle:me,labelIconStyle:ne,dropdownContainerStyle:q,placeHolderStyle:V,selectedTagsStyle:y,selectedListStyle:w,additionalStyle:I,dropdownListStyle:B,listStyle:$})=>{const[G,N]=_e.useState(!1),[J,ae]=_e.useState(!1),ve=_e.useRef(g),[se,De]=_e.useState("");_e.useState(null);const S=_e.useRef([]),ce=_e.useRef(null),le=_e.useRef(null),L=_e.useRef({}),P=(Se,dt)=>{const Et=new Set;return Se.filter(bi=>Et.has(bi[dt])?!1:(Et.add(bi[dt]),!0))},Y=Se=>{var dt;ve.current.forEach(Et=>{Se.id===Et.id?Et.selected=!0:Et.selected=!1}),L.current=Se,De((dt=L.current)==null?void 0:dt.label),C&&typeof C=="function"&&C(L.current),ae(!1)},he=Se=>{S.current=[...S.current,...ve.current.filter(dt=>dt.id===Se.id)],Se.selected=!Se.selected,S.current=P(S.current,"id").filter(dt=>dt.selected),C&&typeof C=="function"&&C(S.current),f||De(S.current.map(dt=>dt.label).join(", ")),N(dt=>!dt)},ye=Se=>{Se.stopPropagation(),S.current=[],m=null,ve.current&&ve.current.length>0&&g.forEach(dt=>dt.selected=!1),re(""),C(z?[]:{}),De("")},re=Se=>{if(b&&!W)if(Se&&Se.length>0){let dt=g.filter(Et=>{var bi;return(bi=Et==null?void 0:Et.label)==null?void 0:bi.toLowerCase().includes(Se.toLowerCase())});ve.current=dt}else ve.current=g;D&&typeof D=="function"&&D(Se),De(Se)},we=()=>{if(m||m===0){let Se=g.filter(dt=>Number(dt.id)===Number(m));Se&&Se[0]&&(L.current=Se[0],U?(D&&typeof D=="function"&&D(L.current.label),De(L.current.label),closeOnSelect&&setCollapsed(dt=>!1),withDropdownSearch&&DropdownSearchValue&&SetDropdownSearchValue("")):Y(Se[0]))}},[Le,Ie]=_e.useState(!1),$e=Se=>{let dt=ce.current.querySelector("ul"),bi=Math.abs(dt.scrollTop+dt.clientHeight-dt.scrollHeight)<=2;W&&bi&&!Le&&(u&&typeof u=="function"&&u(!0),Ie(!0)),bi||Ie(!1)},Xe=()=>{g.forEach(Se=>{Se.selected=!1}),S.current=[],C([]),De(""),s&&typeof s=="function"&&s(),N(Se=>!Se)},it=()=>{g.forEach(Se=>{Se.selected=!0}),S.current=g,S.current=P(S.current,"id").filter(Se=>Se.selected),De(S.current.map(Se=>Se.label).join(", ")),l&&typeof l=="function"&&l(),C(S.current),N(Se=>!Se)},Ft=Se=>Se,je=Se=>{Se.composedPath().includes(ce.current)||ae(!1)},gt=Se=>{if(k){if(Se.composedPath().includes(ce.current))return;ae(!1)}},Ai=()=>{const Se=le.current;if(!Se)return;const dt=Se.getBoundingClientRect(),Et=window.innerHeight;dt.bottom>Et?(Se.style.top="unset",Se.style.bottom="calc(100% + 8px)"):(Se.style.bottom="unset",Se.style.top="calc(100% + 8px)")},St=_e.useRef(null);return _e.useEffect(()=>{J&&St.current&&St.current.focus()},[J]),_e.useEffect(()=>{z&&(S.current=ve.current.filter(Se=>Se.selected),De(ve.current.filter(Se=>Se.selected).map(Se=>Se.label).join(", ")))},[]),_e.useEffect(()=>{J||(ve.current=g)},[J]),_e.useEffect(()=>{Ai()},[le,J]),_e.useEffect(()=>{z||we()},[m]),_e.useEffect(()=>{W&&J&&f&&re(se)},[J]),_e.useEffect(()=>(document.addEventListener("click",je),document.addEventListener("wheel",gt),()=>{document.removeEventListener("click",je),document.removeEventListener("wheel",gt)}),[]),_e.useEffect(()=>{ve.current=g},[g]),R.jsxs("div",{className:li.dropdownWrapper,style:oe??{},children:[e&&R.jsxs("label",{className:li.dropdownLabel,style:te??{},children:[e," ",R.jsx("span",{className:li.required,style:me??{},children:i&&"*"}),R.jsxs("span",{style:{...ne??{},display:"grid",placeItems:"center"},onClick:()=>{Q&&typeof Q=="function"&&Q()},onMouseEnter:()=>{E&&typeof E=="function"&&E()},onMouseLeave:()=>{X&&typeof X=="function"&&X()},children:[" ",Ft(H)]})]}),R.jsxs("div",{ref:ce,onClick:()=>(ae(Se=>!Se),Ai()),className:`${li.dropdownContainer} ${J&&!o?li.focused:""} ${t?li.disabled:""} ${a!=null&&a.error?li.error:""} ${li[n]}`,style:q??{},children:[f?R.jsxs("div",{children:[" ",R.jsx(wL,{})]}):R.jsx(R.Fragment,{children:K&&R.jsx("div",{style:{display:"grid",alignItems:"center",marginRight:"0.5rem"},children:Ft(K)})}),!f&&z&&r&&!J&&S.current.length===0&&R.jsx("span",{className:li.placeHolder,style:V??{},children:r??""}),z&&R.jsx("div",{className:li.selectedTags,style:y??{},children:!f&&!J?R.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"flex-start"},children:[S.current.slice(0,3).map((Se,dt)=>{let Et=S.current[S.current.length-1];return R.jsxs("span",{className:li.selectedList,style:w??{},children:[!h&&Se.label,!h&&Se.id!==Et.id&&dt!==2?", ":""]},Se==null?void 0:Se.id)}),!h&&S.current.length>3&&R.jsxs("span",{className:li.additional,style:I??{},children:[" ","+(",S.current.length-3,")"]})]}):R.jsx("input",{ref:St,onClick:Se=>(Se.stopPropagation(),ae(!0)),autoCorrect:"off",placeholder:"Search...",type:"text",...f?{value:se}:{},onChange:Se=>re(Se.target.value)},m)}),R.jsx("input",{autoCorrect:"off",hidden:z,placeholder:r,readOnly:!b||!J||z,type:"text",value:z&&!f&&J?"":se,onChange:Se=>re(Se.target.value)},m),J&&ve.current&&ve.current.length>0&&R.jsxs("div",{ref:le,onClick:Se=>Se.stopPropagation(),className:li.dropdownListContainer,children:[R.jsx("ul",{onScroll:Se=>$e(),onClick:Se=>Se.stopPropagation(),className:li.dropdownList,style:B??{},children:ve.current.map(Se=>R.jsxs("li",{style:$??{},className:`${!(Se!=null&&Se.label)||Se.label===void 0||Se!=null&&Se.disabled?li.disabled:""} ${Se!=null&&Se.selected?li.selected:""}`,onClick:()=>{z?he(Se):Y(Se)},children:[R.jsxs("p",{children:[" ",Se!=null&&Se.customLabel?Se.customLabel():(Se==null?void 0:Se.label)??"-"]}),h?R.jsx(R.Fragment,{children:Se.selected?R.jsx(vI,{}):R.jsx(EL,{})}):(Se==null?void 0:Se.selected)&&R.jsx("span",{className:li.checkIcon,children:R.jsx(pI,{color:"#7F56D9",width:20,height:20})})]},Se==null?void 0:Se.id))}),z&&p&&R.jsxs("div",{className:li.dropdownListFooter,children:[d&&R.jsx("span",{onClick:Xe,children:"Clear All"}),c&&R.jsx("span",{onClick:it,children:"Select All"})]})]}),!z&&T&&(S.current.length>0||se.length)>0&&R.jsx("div",{onClick:Se=>ye(Se),style:{display:"grid",placeItems:"center",cursor:"pointer"},children:j?Ft(j):R.jsx(gu,{width:16,height:16})}),F?Ft(F):R.jsx("div",{style:{display:"grid",placeItems:"center",transform:J?"rotate(180deg)":"",transition:"transform 0.2s ease-in-out",cursor:"pointer",marginLeft:"10px"},children:!f&&R.jsx(Sh,{})})]}),a&&(a==null?void 0:a.visible)&&R.jsx("div",{className:`${li.dropdownHelperText} ${a!=null&&a.error?li.error:""}`,children:!J&&R.jsx("p",{style:(a==null?void 0:a.style)??{},children:a.text})})]})},IL="Tooltip-module__tooltipContainer",TL="Tooltip-module__tooltipContent",AL="Tooltip-module__top",DL="Tooltip-module__right",OL="Tooltip-module__bottom",RL="Tooltip-module__left",kL="Tooltip-module__tooltipTitle",BL="Tooltip-module__tooltipText",Fo={tooltipContainer:IL,tooltipContent:TL,top:AL,right:DL,bottom:OL,left:RL,tooltipTitle:kL,tooltipText:BL},LL=({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=_e.useRef(null),f=_e.useRef(null),p=_e.useRef({top:0,left:0});let g;const[C,m]=_e.useState(!1),b=()=>{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 _e.useEffect(()=>(document.addEventListener("click",D),()=>{document.removeEventListener("click",D)}),[]),_e.useEffect(()=>{const W=f.current;W&&W.style.setProperty("--pointer-position",`${d}`)},[C]),R.jsxs("div",{ref:h,className:Fo.tooltipContainer,onClick:k,onMouseEnter:b,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})]})]})},PL="Popup-module__modalOverlay",FL="Popup-module__popupDrawerMode",ML="Popup-module__popupContainer",VL="Popup-module__EnterFromLeft",NL="Popup-module__fadeIn",HL="Popup-module__withOptions",$L="Popup-module__horizontal",WL="Popup-module__popupHeader",zL="Popup-module__popupTitle",GL="Popup-module__popupDescription",UL="Popup-module__typeIcon",KL="Popup-module__icon",jL="Popup-module__templateWrapper",On={modalOverlay:PL,popupDrawerMode:FL,popupContainer:ML,enterFromLeft:VL,fadeIn:NL,withOptions:HL,horizontal:$L,popupHeader:WL,popupTitle:zL,popupDescription:GL,typeIcon:UL,icon:KL,templateWrapper:jL},qL=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]},YL=e=>e.slice((e.lastIndexOf(".")-1>>>0)+2),XL=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 ZL=(e,t)=>{const i=new Set;return e.filter(n=>i.has(n[t])?!1:(i.add(n[t]),!0))},QL=()=>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"})}),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 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"})}),mI=({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(mI,{});case"unsaved":return R.jsx(JL,{});case"success":return R.jsx(QL,{})}},f=()=>{a&&typeof a=="function"&&a(!1)},p=_e.useRef(null),g=C=>{C.target===p.current&&r&&typeof r=="function"&&r(!1)};return _e.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,Gk,Da),Aa[Da+mf]=!0}}return Z===n?gf(si):_f(si),si}}function Hk(Z,Te,Ve){return hr(Z,Te,Ve,!0)}function $k(Z,Te,Ve){return hr(Z,Te,Ve,!1)}var Wk=$k,zk=Hk;zs.Fragment=n,zs.jsx=Wk,zs.jsxs=zk}()),zs}process.env.NODE_ENV==="production"?n_.exports=Kk():n_.exports=jk();var R=n_.exports;const qk="MainButton-module__mainButton",Yk="MainButton-module__sm",Xk="MainButton-module__onlyIcon",Zk="MainButton-module__buttonSlot",Qk="MainButton-module__buttonLabel",Jk="MainButton-module__md",eB="MainButton-module__lg",tB="MainButton-module__xl",iB="MainButton-module__xl2",nB="MainButton-module__disabled",Bo={mainButton:qk,sm:Yk,onlyIcon:Xk,buttonSlot:Zk,buttonLabel:Qk,md:Jk,lg:eB,xl:tB,xl2:iB,disabled:nB},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:""]})}),rB="FormInput-module__inputWrapper",aB="FormInput-module__inputLabel",oB="FormInput-module__required",sB="FormInput-module__inputContainer",lB="FormInput-module__inputContent",uB="FormInput-module__inputTags",dB="FormInput-module__focused",cB="FormInput-module__error",hB="FormInput-module__rightIcon",fB="FormInput-module__leftIcon",pB="FormInput-module__inputDropDown",vB="FormInput-module__http",_B="FormInput-module__disabled",gB="FormInput-module__sm",mB="FormInput-module__md",CB="FormInput-module__withCopy",yB="FormInput-module__inputHelperText",ci={inputWrapper:rB,inputLabel:aB,required:oB,inputContainer:sB,inputContent:lB,inputTags:uB,focused:dB,error:cB,rightIcon:hB,leftIcon:fB,inputDropDown:pB,http:vB,disabled:_B,sm:gB,md:mB,withCopy:CB,inputHelperText:yB},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"})}),xB=({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"})}),bB="Checkbox-module__checkboxWrapper",SB="Checkbox-module__sm",EB="Checkbox-module__md",wB="Checkbox-module__checkMark",IB="Checkbox-module__checked",TB="Checkbox-module__disabled",Lo={checkboxWrapper:bB,sm:SB,md:EB,checkMark:wB,checked:IB,disabled:TB},pI=({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"})}),vI=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=_e.useRef(null),[u,d]=_e.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(vI,{}):R.jsx(pI,{}):""]})},AB="Tag-module__tagContainer",DB="Tag-module__onlyLabel",OB="Tag-module__sm",RB="Tag-module__md",kB="Tag-module__lg",BB="Tag-module__tagLabel",LB="Tag-module__tagNumber",PB="Tag-module__tagClose",Po={tagContainer:AB,onlyLabel:DB,sm:OB,md:RB,lg:kB,tagLabel:BB,tagNumber:LB,tagClose:PB},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"})})]})},_I=({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:b,onLeftIconIconMouseEnter:T,onLeftIconIconMouseLeave:k,onPressEnter:D,rightIcon:W,leftIcon:z,withDropDown:U,dropdownData:H,onSelectData:j,withTags:K,tagProps:F,withLink:Q,withCopy:E,onCopy:X,inputWrapperStyle:oe,inputLabelStyle:te,requiredStyle:me,inputContainerStyle:ne,leftIconStyle:q,inputDropDownStyle:V,ulStyle:y,liStyle:w,httpStyle:I,inputStyle:B,rightIconStyle:$,withCopyStyle:G,inputHelperTextStyle:N})=>{const[J,ae]=_e.useState(!1),ve=_e.useRef(null),[se,De]=_e.useState(!1);_e.useState(!1);const S=_e.useRef(null),ce=_e.useRef(null),[le,L]=_e.useState(!1),[P,Y]=_e.useState(1),he=je=>{let gt=je.target.value;gt.length===1&&(gt=gt.trim()),s&&typeof s=="function"&&s(f?gt.replace(/\d/g,""):gt)},ye=()=>{De(!0),l&&typeof l=="function"&&l()},re=()=>{De(!1),u&&typeof u=="function"&&u()},we=je=>{const gt=je.target.value,Ai=gt.length===0;a==="number"&&(je.keyCode===69||!Ai&&(je.keyCode===187||je.keyCode===107||je.keyCode===189||je.keyCode===109))&&je.preventDefault(),je.key==="Enter"&>&>.length>0&&D&&typeof D=="function"&&D(gt)},Le=()=>{X&&typeof X=="function"&&X(e)},Ie=je=>je,$e=()=>{let je={};return E&&(je.borderTopRightRadius=0,je.borderBottomRightRadius=0,je.borderRight=0),U&&(je.paddingLeft=0),{...je,...ne??{}}},Xe=je=>{!je.composedPath().includes(ce.current)&&je.composedPath().includes(S.current)||L(!1)},it=je=>{Y(je.id),L(!1),j&&typeof j=="function"&&j(je)};_e.useEffect(()=>{e&&e.length===0&&calculateWidth()},[e]),_e.useEffect(()=>(document.addEventListener("click",Xe),()=>{document.removeEventListener("click",Xe)}),[]);const Ft=_e.useRef(!1);return _e.useEffect(()=>{Ft.current?setTimeout(()=>{ae(je=>!je)},0):Ft.current=!0},[]),R.jsxs("div",{className:ci.inputWrapper,style:oe??{},children:[t&&R.jsxs("label",{className:ci.inputLabel,style:te??{},children:[t," ",R.jsx("span",{className:ci.required,style:me??{},children:n&&"*"})]}),R.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[R.jsxs("div",{style:$e(),className:`${ci.inputContainer} ${se&&!c?ci.focused:""} ${r?ci.disabled:""} ${d!=null&&d.error?ci.error:""} ${ci[o??"sm"]}`,children:[!U&&!Q&&z&&R.jsx("div",{className:ci.leftIcon,style:q??{},onClick:()=>{b&&typeof b=="function"&&b()},onMouseEnter:()=>{T&&typeof T=="function"&&T()},onMouseLeave:()=>{k&&typeof k=="function"&&k()},children:Ie(z)}),!Q&&U&&R.jsxs("div",{className:ci.inputDropDown,style:V??{},onClick:()=>L(!0),ref:S,children:[H.find(je=>je.id===P).label,le&&R.jsx("ul",{ref:ce,style:y??{},children:H&&H.length&&H.map((je,gt)=>R.jsx("li",{style:w??{},onClick:()=>it(je),children:(je==null?void 0:je.label)??"-"},je.id))}),R.jsx(Sh,{})]}),Q&&R.jsx("div",{className:`${ci.inputDropDown} ${ci.http}`,style:I??{},onClick:()=>L(!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((je,gt)=>R.jsx("div",{className:ci.inputSingleTags,children:R.jsx(Dg,{...F,id:je,label:je,withClose:!0})},gt))}),R.jsx("input",{ref:ve,style:B??{},type:a??"text",value:e,onChange:je=>he(je),onFocus:ye,onBlur:re,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:G??{},onClick:Le,className:ci.withCopy,children:[R.jsx(xB,{}),"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})})]})},FB="Textarea-module__textareaContainer",MB="Textarea-module__textAreaLabel",VB="Textarea-module__required",NB="Textarea-module__wrap",HB="Textarea-module__textarea",$B="Textarea-module__focused",WB="Textarea-module__disabled",zB="Textarea-module__error",GB="Textarea-module__helperTextStyle",fn={textareaContainer:FB,textAreaLabel:MB,required:VB,wrap:NB,textarea:HB,focused:$B,disabled:WB,error:zB,helperTextStyle:GB},UB=({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"})})})]}),KB=({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,b]=_e.useState(!1),T=W=>{let z=W.target.value;s&&typeof s=="function"&&s(z)},k=()=>{b(!0),l&&typeof l=="function"&&l()},D=()=>{b(!1),u&&typeof u=="function"&&u()};return R.jsxs("div",{style:h??{},className:`${fn.textareaContainer} ${i!=null&&i.type&&(i!=null&&i.visible)?fn[i==null?void 0:i.type]:""} ${d?fn.disabled:null}`,children:[t&&R.jsxs("div",{style:f,className:fn.textAreaLabel,children:[R.jsx("p",{children:t}),R.jsx("span",{style:p??{},className:fn.required,children:c&&"*"}),R.jsx(UB,{})]}),R.jsx("div",{className:fn.wrap,children:R.jsx("textarea",{style:g??{},className:`${fn.textarea} ${m?fn.focused:""} ${d?fn.disabled:""} ${i!=null&&i.error?fn.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:`${fn.helperTextStyle} ${i!=null&&i.error?fn.error:""}`,children:R.jsx("p",{style:(i==null?void 0:i.style)??{},children:i.text})})]})},jB="Toggle-module__toggleWrapper",qB="Toggle-module__toggleState",YB="Toggle-module__checked",XB="Toggle-module__disabled",id={toggleWrapper:jB,toggleState:qB,checked:YB,disabled:XB},ZB=({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]=_e.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})})})},QB="Radio-module__radioWrapper",JB="Radio-module__sm",eL="Radio-module__md",tL="Radio-module__checked",iL="Radio-module__innerCircle",nL="Radio-module__radioState",rL="Radio-module__disabled",Oa={radioWrapper:QB,sm:JB,md:eL,checked:tL,innerCircle:iL,radioState:nL,disabled:rL},gI=({checked:e,change:t,disabled:i,isRequired:n,withUncheckState:r,size:a})=>{_e.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})})]})},aL="Dropdown-module__dropdownWrapper",oL="Dropdown-module__placeHolder",sL="Dropdown-module__dropdownLabel",lL="Dropdown-module__required",uL="Dropdown-module__dropdownContainer",dL="Dropdown-module__sm",cL="Dropdown-module__md",hL="Dropdown-module__selectedTags",fL="Dropdown-module__selectedList",pL="Dropdown-module__additional",vL="Dropdown-module__dropdownListContainer",_L="Dropdown-module__dropdownList",gL="Dropdown-module__checkIcon",mL="Dropdown-module__disabled",CL="Dropdown-module__selected",yL="Dropdown-module__dropdownListFooter",xL="Dropdown-module__focused",bL="Dropdown-module__error",SL="Dropdown-module__dropdownHelperText",li={dropdownWrapper:aL,placeHolder:oL,dropdownLabel:sL,required:lL,dropdownContainer:uL,sm:dL,md:cL,selectedTags:hL,selectedList:fL,additional:pL,dropdownListContainer:vL,dropdownList:_L,checkIcon:gL,disabled:mL,selected:CL,dropdownListFooter:yL,focused:xL,error:bL,dropdownHelperText:SL},EL=()=>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"})}),wL=()=>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,onClearAll:s,onSelectAll:l,onBottomScroll:u,withClearAll:d=!0,withSelectAll:c=!0,withPlus:h=!1,searchComponent:f=!1,withFooter:p=!0,data:g,onSelect:C,selectedOptionID:m,withFilter:b=!0,withClose:T=!0,fixedDropdown:k=!1,onSearch:D,pagination:W,withMultiSelect:z=!1,skipSelected:U,labelIcon:H,closeIcon:j,dropdownIcon:K,iconDown:F,onLabelIconClick:Q,onLabelIconMouseEnter:E,onLabelIconMouseLeave:X,dropdownWrapperStyle:oe,dropdownLabelStyle:te,requiredStyle:me,labelIconStyle:ne,dropdownContainerStyle:q,placeHolderStyle:V,selectedTagsStyle:y,selectedListStyle:w,additionalStyle:I,dropdownListStyle:B,listStyle:$})=>{const[G,N]=_e.useState(!1),[J,ae]=_e.useState(!1),ve=_e.useRef(g),[se,De]=_e.useState("");_e.useState(null);const S=_e.useRef([]),ce=_e.useRef(null),le=_e.useRef(null),L=_e.useRef({}),P=(Se,dt)=>{const Et=new Set;return Se.filter(bi=>Et.has(bi[dt])?!1:(Et.add(bi[dt]),!0))},Y=Se=>{var dt;ve.current.forEach(Et=>{Se.id===Et.id?Et.selected=!0:Et.selected=!1}),L.current=Se,De((dt=L.current)==null?void 0:dt.label),C&&typeof C=="function"&&C(L.current),ae(!1)},he=Se=>{S.current=[...S.current,...ve.current.filter(dt=>dt.id===Se.id)],Se.selected=!Se.selected,S.current=P(S.current,"id").filter(dt=>dt.selected),C&&typeof C=="function"&&C(S.current),f||De(S.current.map(dt=>dt.label).join(", ")),N(dt=>!dt)},ye=Se=>{Se.stopPropagation(),S.current=[],m=null,ve.current&&ve.current.length>0&&g.forEach(dt=>dt.selected=!1),re(""),C(z?[]:{}),De("")},re=Se=>{if(b&&!W)if(Se&&Se.length>0){let dt=g.filter(Et=>{var bi;return(bi=Et==null?void 0:Et.label)==null?void 0:bi.toLowerCase().includes(Se.toLowerCase())});ve.current=dt}else ve.current=g;D&&typeof D=="function"&&(D(Se),ve.current=g),De(Se)},we=()=>{if(m||m===0){let Se=g.filter(dt=>Number(dt.id)===Number(m));Se&&Se[0]&&(L.current=Se[0],U?(D&&typeof D=="function"&&D(L.current.label),De(L.current.label),closeOnSelect&&setCollapsed(dt=>!1),withDropdownSearch&&DropdownSearchValue&&SetDropdownSearchValue("")):Y(Se[0]))}},[Le,Ie]=_e.useState(!1),$e=Se=>{let dt=ce.current.querySelector("ul"),bi=Math.abs(dt.scrollTop+dt.clientHeight-dt.scrollHeight)<=2;W&&bi&&!Le&&(u&&typeof u=="function"&&u(!0),Ie(!0)),bi||Ie(!1)},Xe=()=>{g.forEach(Se=>{Se.selected=!1}),S.current=[],C([]),De(""),s&&typeof s=="function"&&s(),N(Se=>!Se)},it=()=>{g.forEach(Se=>{Se.selected=!0}),S.current=g,S.current=P(S.current,"id").filter(Se=>Se.selected),De(S.current.map(Se=>Se.label).join(", ")),l&&typeof l=="function"&&l(),C(S.current),N(Se=>!Se)},Ft=Se=>Se,je=Se=>{Se.composedPath().includes(ce.current)||ae(!1)},gt=Se=>{if(k){if(Se.composedPath().includes(ce.current))return;ae(!1)}},Ai=()=>{const Se=le.current;if(!Se)return;const dt=Se.getBoundingClientRect(),Et=window.innerHeight;dt.bottom>Et?(Se.style.top="unset",Se.style.bottom="calc(100% + 8px)"):(Se.style.bottom="unset",Se.style.top="calc(100% + 8px)")},St=_e.useRef(null);return _e.useEffect(()=>{J&&St.current&&St.current.focus()},[J]),_e.useEffect(()=>{z&&(S.current=ve.current.filter(Se=>Se.selected),De(ve.current.filter(Se=>Se.selected).map(Se=>Se.label).join(", ")))},[]),_e.useEffect(()=>{J||(ve.current=g)},[J]),_e.useEffect(()=>{Ai()},[le,J]),_e.useEffect(()=>{z||we()},[m]),_e.useEffect(()=>(document.addEventListener("click",je),document.addEventListener("wheel",gt),()=>{document.removeEventListener("click",je),document.removeEventListener("wheel",gt)}),[]),_e.useEffect(()=>{ve.current=g},[g]),R.jsxs("div",{className:li.dropdownWrapper,style:oe??{},children:[e&&R.jsxs("label",{className:li.dropdownLabel,style:te??{},children:[e," ",R.jsx("span",{className:li.required,style:me??{},children:i&&"*"}),R.jsxs("span",{style:{...ne??{},display:"grid",placeItems:"center"},onClick:()=>{Q&&typeof Q=="function"&&Q()},onMouseEnter:()=>{E&&typeof E=="function"&&E()},onMouseLeave:()=>{X&&typeof X=="function"&&X()},children:[" ",Ft(H)]})]}),R.jsxs("div",{ref:ce,onClick:()=>(ae(Se=>!Se),Ai()),className:`${li.dropdownContainer} ${J&&!o?li.focused:""} ${t?li.disabled:""} ${a!=null&&a.error?li.error:""} ${li[n]}`,style:q??{},children:[f?R.jsxs("div",{children:[" ",R.jsx(wL,{})]}):R.jsx(R.Fragment,{children:K&&R.jsx("div",{style:{display:"grid",alignItems:"center",marginRight:"0.5rem"},children:Ft(K)})}),!f&&z&&r&&!J&&S.current.length===0&&R.jsx("span",{className:li.placeHolder,style:V??{},children:r??""}),z&&R.jsx("div",{className:li.selectedTags,style:y??{},children:!f&&!J?R.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"flex-start"},children:[S.current.slice(0,3).map((Se,dt)=>{let Et=S.current[S.current.length-1];return R.jsxs("span",{className:li.selectedList,style:w??{},children:[!h&&Se.label,!h&&Se.id!==Et.id&&dt!==2?", ":""]},Se==null?void 0:Se.id)}),!h&&S.current.length>3&&R.jsxs("span",{className:li.additional,style:I??{},children:[" ","+(",S.current.length-3,")"]})]}):R.jsx("input",{ref:St,onClick:Se=>(Se.stopPropagation(),ae(!0)),autoCorrect:"off",placeholder:"Search...",type:"text",...f?{value:se}:{},onChange:Se=>re(Se.target.value)},m)}),R.jsx("input",{autoCorrect:"off",hidden:z,placeholder:r,readOnly:!b||!J||z,type:"text",value:z&&!f&&J?"":se,onChange:Se=>re(Se.target.value)},m),J&&ve.current&&ve.current.length>0&&R.jsxs("div",{ref:le,onClick:Se=>Se.stopPropagation(),className:li.dropdownListContainer,children:[R.jsx("ul",{onScroll:Se=>$e(),onClick:Se=>Se.stopPropagation(),className:li.dropdownList,style:B??{},children:ve.current.map(Se=>R.jsxs("li",{style:$??{},className:`${!(Se!=null&&Se.label)||Se.label===void 0||Se!=null&&Se.disabled?li.disabled:""} ${Se!=null&&Se.selected?li.selected:""}`,onClick:()=>{z?he(Se):Y(Se)},children:[R.jsxs("p",{children:[" ",Se!=null&&Se.customLabel?Se.customLabel():(Se==null?void 0:Se.label)??"-"]}),h?R.jsx(R.Fragment,{children:Se.selected?R.jsx(vI,{}):R.jsx(EL,{})}):(Se==null?void 0:Se.selected)&&R.jsx("span",{className:li.checkIcon,children:R.jsx(pI,{color:"#7F56D9",width:20,height:20})})]},Se==null?void 0:Se.id))}),z&&p&&R.jsxs("div",{className:li.dropdownListFooter,children:[d&&R.jsx("span",{onClick:Xe,children:"Clear All"}),c&&R.jsx("span",{onClick:it,children:"Select All"})]})]}),!z&&T&&(S.current.length>0||se.length)>0&&R.jsx("div",{onClick:Se=>ye(Se),style:{display:"grid",placeItems:"center",cursor:"pointer"},children:j?Ft(j):R.jsx(gu,{width:16,height:16})}),F?Ft(F):R.jsx("div",{style:{display:"grid",placeItems:"center",transform:J?"rotate(180deg)":"",transition:"transform 0.2s ease-in-out",cursor:"pointer",marginLeft:"10px"},children:!f&&R.jsx(Sh,{})})]}),a&&(a==null?void 0:a.visible)&&R.jsx("div",{className:`${li.dropdownHelperText} ${a!=null&&a.error?li.error:""}`,children:!J&&R.jsx("p",{style:(a==null?void 0:a.style)??{},children:a.text})})]})},IL="Tooltip-module__tooltipContainer",TL="Tooltip-module__tooltipContent",AL="Tooltip-module__top",DL="Tooltip-module__right",OL="Tooltip-module__bottom",RL="Tooltip-module__left",kL="Tooltip-module__tooltipTitle",BL="Tooltip-module__tooltipText",Fo={tooltipContainer:IL,tooltipContent:TL,top:AL,right:DL,bottom:OL,left:RL,tooltipTitle:kL,tooltipText:BL},LL=({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=_e.useRef(null),f=_e.useRef(null),p=_e.useRef({top:0,left:0});let g;const[C,m]=_e.useState(!1),b=()=>{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 _e.useEffect(()=>(document.addEventListener("click",D),()=>{document.removeEventListener("click",D)}),[]),_e.useEffect(()=>{const W=f.current;W&&W.style.setProperty("--pointer-position",`${d}`)},[C]),R.jsxs("div",{ref:h,className:Fo.tooltipContainer,onClick:k,onMouseEnter:b,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})]})]})},PL="Popup-module__modalOverlay",FL="Popup-module__popupDrawerMode",ML="Popup-module__popupContainer",VL="Popup-module__EnterFromLeft",NL="Popup-module__fadeIn",HL="Popup-module__withOptions",$L="Popup-module__horizontal",WL="Popup-module__popupHeader",zL="Popup-module__popupTitle",GL="Popup-module__popupDescription",UL="Popup-module__typeIcon",KL="Popup-module__icon",jL="Popup-module__templateWrapper",On={modalOverlay:PL,popupDrawerMode:FL,popupContainer:ML,enterFromLeft:VL,fadeIn:NL,withOptions:HL,horizontal:$L,popupHeader:WL,popupTitle:zL,popupDescription:GL,typeIcon:UL,icon:KL,templateWrapper:jL},qL=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]},YL=e=>e.slice((e.lastIndexOf(".")-1>>>0)+2),XL=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 ZL=(e,t)=>{const i=new Set;return e.filter(n=>i.has(n[t])?!1:(i.add(n[t]),!0))},QL=()=>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"})}),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 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"})}),mI=({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(mI,{});case"unsaved":return R.jsx(JL,{});case"success":return R.jsx(QL,{})}},f=()=>{a&&typeof a=="function"&&a(!1)},p=_e.useRef(null),g=C=>{C.target===p.current&&r&&typeof r=="function"&&r(!1)};return _e.useEffect(()=>(document.addEventListener("click",g),()=>{document.removeEventListener("click",g)}),[]),e&&R.jsx("div",{ref:p,style:s??{},className:`
|
|
32
32
|
mcModal_global
|
|
33
33
|
${On.modalOverlay}
|
|
34
34
|
${i&&i.mode==="drawer"?On.popupDrawerMode:""}
|