master-components-react 3.6.2 → 3.6.3
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.
|
@@ -35,7 +35,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
35
35
|
${a?br.loading:""}
|
|
36
36
|
${n?br[n]:""}
|
|
37
37
|
${C&&m&&!c&&!r?br.active:""}
|
|
38
|
-
${r?br.disabled:""}`,onMouseDown:()=>b(!0),onMouseUp:()=>b(!1),onMouseLeave:()=>b(!1),onClick:()=>{!r&&i&&typeof i=="function"&&i()},children:I.jsxs("div",{className:br.buttonSlot,style:!r&&p?p:{},children:[u||o&&s?s:"",!u&&I.jsx(I.Fragment,{children:a?I.jsx("div",{style:{display:"grid",placeItems:"center"},children:I.jsx(nB,{})}):I.jsx("span",{style:!r&&h?h:{},className:br.buttonLabel,children:e??"Button"})}),o&&l?l:""]})})},mB="FormInput-module__inputWrapper",gB="FormInput-module__inputLabel",CB="FormInput-module__required",yB="FormInput-module__inputContainer",xB="FormInput-module__inputContent",bB="FormInput-module__inputTags",SB="FormInput-module__focused",EB="FormInput-module__error",wB="FormInput-module__rightIcon",IB="FormInput-module__leftIcon",TB="FormInput-module__inputDropDown",AB="FormInput-module__http",DB="FormInput-module__disabled",OB="FormInput-module__sm",RB="FormInput-module__md",kB="FormInput-module__withCopy",BB="FormInput-module__inputHelperText",LB="FormInput-module__dark",fi={inputWrapper:mB,inputLabel:gB,required:CB,inputContainer:yB,inputContent:xB,inputTags:bB,focused:SB,error:EB,rightIcon:wB,leftIcon:IB,inputDropDown:TB,http:AB,disabled:DB,sm:OB,md:RB,withCopy:kB,inputHelperText:BB,dark:LB},Du=({width:e,height:t,color:i})=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"12",height:t??"8",viewBox:"0 0 12 8",fill:"none",children:I.jsx("path",{d:"M1 1.5L6 6.5L11 1.5",stroke:i??"#A4A7AE",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),PB=({width:e,height:t,color:i})=>I.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"20",height:t??"20",viewBox:"0 0 20 20",fill:"none",children:[I.jsx("g",{clipPath:"url(#clip0_444_26)",children:I.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"})}),I.jsx("defs",{children:I.jsx("clipPath",{id:"clip0_444_26",children:I.jsx("rect",{width:"20",height:"20",fill:"white"})})})]}),Ou=e=>I.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:I.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"})}),FB="Checkbox-module__checkboxWrapper",MB="Checkbox-module__sm",VB="Checkbox-module__md",NB="Checkbox-module__checkMark",$B="Checkbox-module__checked",HB="Checkbox-module__disabled",WB="Checkbox-module__dark",Yo={checkboxWrapper:FB,sm:MB,md:VB,checkMark:NB,checked:$B,disabled:HB,dark:WB},xI=({color:e,width:t,height:i})=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:t??"12",height:i??"12",viewBox:"0 0 12 12",fill:"none",children:I.jsx("path",{d:"M10 3L4.5 8.5L2 6",stroke:e??"white",strokeWidth:"1.6666",strokeLinecap:"round",strokeLinejoin:"round"})}),zB=e=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",...e,width:"10",height:"2",viewBox:"0 0 10 2",fill:"none",children:I.jsx("path",{d:"M1.5 1H8.5",stroke:"white",strokeWidth:"1.66666",strokeLinecap:"round",strokeLinejoin:"round"})}),Ru=({checked:e,change:t,disabled:i=!1,required:n=!1,multipleChecked:r=!1,size:a="md",activeStyle:o,checkBoxStyle:s,withActive:l=!0,theme:u="light"})=>{const d=ue.useRef(null),[c,h]=ue.useState(!1),f=()=>{i||t&&typeof t=="function"&&t(!e)},p=()=>c?!l||i?{boxShadow:"none",...o}:o??{}:s??{};return I.jsxs("div",{style:p(),className:` ${u==="dark"?Yo.dark:""} ${Yo.checkboxWrapper} ${Yo[a]} ${e?Yo.checked:Yo.unChecked} ${i?Yo.disabled:""}`,onMouseDown:()=>h(!0),onMouseUp:()=>h(!1),onMouseLeave:()=>h(!1),onClick:f,children:[I.jsx("input",{ref:d,type:"checkbox",disabled:i,checked:e,hidden:!0,readOnly:!0,required:n??!1}),e?r?I.jsx(zB,{}):I.jsx(xI,{}):""]})},GB="Tag-module__tagContainer",UB="Tag-module__onlyLabel",KB="Tag-module__sm",jB="Tag-module__md",qB="Tag-module__lg",YB="Tag-module__tagLabel",XB="Tag-module__tagNumber",ZB="Tag-module__tagClose",JB="Tag-module__dark",$a={tagContainer:GB,onlyLabel:UB,sm:KB,md:jB,lg:qB,tagLabel:YB,tagNumber:XB,tagClose:ZB,dark:JB},Wm=({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,theme:m})=>{const g=()=>!r&&!i&&!n&&!a,C=()=>i,b=()=>{d&&typeof d=="function"&&d(e??null)};return I.jsxs("div",{style:c??{},className:`${m==="dark"?$a.dark:""} ${$a.tagContainer} ${g()?$a.onlyLabel:""} ${$a[u??"md"]}`,children:[r&&I.jsx(Ru,{...s}),i&&C(),t&&I.jsx("p",{style:h??{},className:$a.tagLabel,children:t??""}),a&&I.jsx("div",{style:f??{},className:$a.tagNumber,children:o??""}),n&&I.jsx("div",{style:p??{},className:$a.tagClose,onClick:b,children:I.jsx(Ou,{width:(p==null?void 0:p.width)??"14",height:(p==null?void 0:p.height)??"14",color:(p==null?void 0:p.color)??"#A4A7AE"})})]})},bc=({value:e,label:t,placeholder:i,required:n,disabled:r,type:a,size:o,onChange:s,onFocus:l,onBlur:u,msg:d,readOnly:c,maxLength:h,onlyText:f,tagValues:p,onRightIconIconClick:m,onRightIconIconMouseEnter:g,onRightIconIconMouseLeave:C,onLeftIconIconClick:b,onLeftIconIconMouseEnter:A,onLeftIconIconMouseLeave:B,onPressEnter:D,rightIcon:U,leftIcon:H,fixedDropdown:W=!0,withDropDown:G,dropdownData:j,dropDownPosition:te="left",onSelectData:N,withTags:Y,tagProps:x,withLink:z,withCopy:ie,onCopy:ne,inputWrapperStyle:pe,inputLabelStyle:le,requiredStyle:J,inputContainerStyle:K,leftIconStyle:y,inputDropDownStyle:T,ulStyle:S,liStyle:O,httpStyle:P,inputStyle:M,rightIconStyle:$,withCopyStyle:Q,inputHelperTextStyle:oe,theme:ge="light"})=>{const[ee,xe]=ue.useState(!1),w=ue.useRef(null),[he,de]=ue.useState(!1),[F,L]=ue.useState(!1),X=ue.useRef(null),ce=ue.useRef(null),_e=ue.useRef(null),[ae,we]=ue.useState(!1),[ke,Ae]=ue.useState(1),Ne=qe=>{let ct=qe.target.value;ct.length===1&&(ct=ct.trim()),s&&typeof s=="function"&&s(f?ct.replace(/\d/g,""):ct)},ut=()=>{de(!0),l&&typeof l=="function"&&l()},et=()=>{de(!1),u&&typeof u=="function"&&u()},Ze=qe=>{const ct=qe.target.value,mi=ct.length===0;a==="number"&&(qe.keyCode===69||!mi&&(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)},li=()=>{ne&&typeof ne=="function"&&ne(e)},jt=qe=>qe,Ht=()=>{let qe={};return ie&&(qe.borderTopRightRadius=0,qe.borderBottomRightRadius=0,qe.borderRight=0),G&&(te==="right"?qe.flexDirection="row-reverse":G&&(qe.paddingLeft=0)),{...qe,...K??{}}},mt=qe=>{!qe.composedPath().includes(ce.current)&&qe.composedPath().includes(X.current)||we(!1)},Bi=qe=>{Ae(qe.id),we(!1),N&&typeof N=="function"&&N(qe)},Li=()=>{const qe=_e.current,ct=ce.current;if(!ct||!qe)return;const mi=qe.getBoundingClientRect(),Pi=window.innerHeight,We=80;W&&(ct.style.position="fixed",ct.style.width=We+"px",te==="right"?ct.style.left=`${mi.right-We/2}px`:ct.style.left=`${mi.left+We/2}px`,mi.bottom+ct.offsetHeight>Pi?(ct.style.top=`${window.scrollY+mi.top-ct.offsetHeight}px`,ct.style.bottom="unset"):(ct.style.top=`${window.scrollY+mi.bottom}px`,ct.style.bottom="unset"))};ue.useEffect(()=>{Li()},[ce,ae]),ue.useEffect(()=>{e&&e.length===0&&calculateWidth()},[e]),ue.useEffect(()=>(document.addEventListener("click",mt),()=>{document.removeEventListener("click",mt)}),[]);const wt=ue.useRef(!1);return ue.useEffect(()=>{wt.current?setTimeout(()=>{xe(qe=>!qe)},0):wt.current=!0},[]),I.jsxs("div",{className:`${ge==="dark"?fi.dark:""} ${fi.inputWrapper}`,style:pe??{},children:[t&&I.jsxs("label",{className:fi.inputLabel,style:le??{},children:[t," ",I.jsx("span",{className:fi.required,style:J??{},children:n&&"*"})]}),I.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[I.jsxs("div",{style:Ht(),ref:_e,className:`${fi.inputContainer} ${he&&!c?fi.focused:""} ${r?fi.disabled:""} ${d!=null&&d.error?fi.error:""} ${fi[o??"sm"]}`,children:[!G&&!z&&H&&I.jsx("div",{className:fi.leftIcon,style:y??{},onClick:()=>{b&&typeof b=="function"&&b()},onMouseEnter:()=>{A&&typeof A=="function"&&A()},onMouseLeave:()=>{B&&typeof B=="function"&&B()},children:jt(H)}),!z&&G&&I.jsxs("div",{className:fi.inputDropDown,style:T??{},onClick:()=>(we(!0),Li()),ref:X,children:[j.find(qe=>qe.id===ke).label,ae&&I.jsx("ul",{ref:ce,style:S??{},children:j&&j.length&&j.map((qe,ct)=>I.jsx("li",{style:O??{},onClick:()=>Bi(qe),children:(qe==null?void 0:qe.label)??"-"},qe.id))}),I.jsx(Du,{})]}),z&&I.jsx("div",{className:`${fi.inputDropDown} ${fi.http}`,style:P??{},onClick:()=>we(!0),ref:X,children:"http://"}),I.jsxs("div",{className:fi.inputContent,children:[Y&&p&&p.length>0&&I.jsx("div",{className:fi.inputTags,children:p.map((qe,ct)=>I.jsx("div",{className:fi.inputSingleTags,children:I.jsx(Wm,{...x,id:qe,label:qe,withClose:!0})},ct))}),I.jsx("input",{ref:w,style:M??{},type:a??"text",value:e,onChange:qe=>Ne(qe),onFocus:ut,onBlur:et,disabled:r,required:n,onKeyDown:Ze,readOnly:c,spellCheck:!1,placeholder:i??"",autoComplete:"off",maxLength:h})]}),U&&I.jsx("div",{className:fi.rightIcon,style:$??{},onClick:()=>{m&&typeof m=="function"&&m()},onMouseEnter:()=>{g&&typeof g=="function"&&g()},onMouseLeave:()=>{C&&typeof C=="function"&&C()},children:jt(U)})]}),ie&&I.jsxs("div",{style:Q??{},onClick:li,className:fi.withCopy,children:[I.jsx(PB,{}),I.jsx("span",{children:"Copy"})]})]}),d&&(d==null?void 0:d.visible)&&I.jsx("div",{style:oe??{},className:`${fi.inputHelperText} ${d!=null&&d.error?fi.error:""}`,children:I.jsx("p",{style:(d==null?void 0:d.style)??{},children:d.text})})]})},QB="Textarea-module__textareaContainer",eL="Textarea-module__textAreaLabel",tL="Textarea-module__required",iL="Textarea-module__wrap",nL="Textarea-module__resize",rL="Textarea-module__textarea",aL="Textarea-module__focused",oL="Textarea-module__disabled",sL="Textarea-module__error",lL="Textarea-module__popupEmojiContainer",uL="Textarea-module__popupEmojiIcon",dL="Textarea-module__popupEmojiList",cL="Textarea-module__popupEmojiItem",hL="Textarea-module__helperTextStyle",fL="Textarea-module__dark",Ai={textareaContainer:QB,textAreaLabel:eL,required:tL,wrap:iL,resize:nL,textarea:rL,focused:aL,disabled:oL,error:sL,popupEmojiContainer:lL,popupEmojiIcon:uL,popupEmojiList:dL,popupEmojiItem:cL,helperTextStyle:hL,dark:fL},pL=()=>I.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",children:[I.jsx("g",{clipPath:"url(#clip0_23326_3835)",children:I.jsx("path",{d:"M6.66699 11.6667C6.66699 11.6667 7.91699 13.3334 10.0003 13.3334C12.0837 13.3334 13.3337 11.6667 13.3337 11.6667M12.5003 7.50008H12.5087M7.50033 7.50008H7.50866M18.3337 10.0001C18.3337 14.6025 14.6027 18.3334 10.0003 18.3334C5.39795 18.3334 1.66699 14.6025 1.66699 10.0001C1.66699 5.39771 5.39795 1.66675 10.0003 1.66675C14.6027 1.66675 18.3337 5.39771 18.3337 10.0001ZM12.917 7.50008C12.917 7.7302 12.7304 7.91675 12.5003 7.91675C12.2702 7.91675 12.0837 7.7302 12.0837 7.50008C12.0837 7.26996 12.2702 7.08341 12.5003 7.08341C12.7304 7.08341 12.917 7.26996 12.917 7.50008ZM7.91699 7.50008C7.91699 7.7302 7.73044 7.91675 7.50033 7.91675C7.27021 7.91675 7.08366 7.7302 7.08366 7.50008C7.08366 7.26996 7.27021 7.08341 7.50033 7.08341C7.73044 7.08341 7.91699 7.26996 7.91699 7.50008Z",stroke:"#535862",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),I.jsx("defs",{children:I.jsx("clipPath",{id:"clip0_23326_3835",children:I.jsx("rect",{width:"20",height:"20",fill:"white"})})})]}),vL=["😀","😃","😄","😁","😆","😅","😂","🤣","😊","😇","🙂","🙃","😉","😌","😍","🥰","😘","😙 ","😚","😋","😛","😎","🥳","😢","😭","😤","😠","😡","🤬","🤯","👋"],_L=({placeholder:e,label:t,msg:i,cols:n,rows:r,value:a,withEmoji:o=!1,maxLength:s,withResize:l=!0,onChange:u,onFocus:d,onBlur:c,disabled:h,required:f,textareaContainerStyle:p,textareaLabelStyle:m,requiredStyle:g,textareaStyle:C,focusStyle:b,textareaHelperTextStyle:A,labelIcon:B,theme:D})=>{const[U,H]=ue.useState(!1),[W,G]=ue.useState(!1),j=ue.useRef(null),te=ue.useRef(null),N=ue.useRef(null),Y=S=>{let O=S.target.value;u&&typeof u=="function"&&u(O)},x=S=>S,z=()=>{H(!0),d&&typeof d=="function"&&d()},ie=()=>{H(!1),c&&typeof c=="function"&&c()},ne=S=>{const O=j.current.querySelector("textarea");if(!O)return;const P=O.selectionStart,M=O.selectionEnd,$=O.scrollTop,Q=a.slice(0,P)+S+a.slice(M);u&&typeof u=="function"&&u(Q),setTimeout(()=>{O.focus(),O.setSelectionRange(P+S.length,P+S.length),O.scrollTop=$},0)},pe=()=>{const S=j.current,O=N.current;if(!O||!S)return;const P=S.getBoundingClientRect(),M=220,$=window.innerHeight-P.bottom;P.top,$>=M?(O.style.top="calc(100% + 8px)",O.style.bottom="unset"):(O.style.bottom="calc(100% + 8px)",O.style.top="unset"),P.right>window.innerWidth?O.style.left=`calc(100% - ${P.width}px)`:P.left<0?O.style.left="0px":O.style.left=""};ue.useEffect(()=>(W&&(pe(),document.addEventListener("mousedown",le)),()=>{document.removeEventListener("mousedown",le)}),[W]);const le=S=>{te.current&&!te.current.contains(S.target)&&G(!1)};ue.useEffect(()=>(W&&document.addEventListener("mousedown",le),()=>{document.removeEventListener("mousedown",le)}),[W]),ue.useEffect(()=>{const S=j.current.querySelector("textarea"),O=j.current;if(!S||!O)return;const P=new ResizeObserver(()=>{O.style.width=`${S.offsetWidth}px`,O.style.height=`${S.offsetHeight}px`});return P.observe(S),()=>P.disconnect()},[]);let J=!1;const K=()=>{const S=j.current.querySelector("textarea");!S||J||(S.style.height="auto",S.style.height=`${S.scrollHeight}px`)};ue.useEffect(()=>{const S=j.current.querySelector("textarea"),O=new ResizeObserver(()=>{J=S.offsetHeight<S.scrollHeight});return O.observe(S),()=>O.disconnect()},[]);const y=S=>{J=!1,u==null||u(S.target.value),K()},T=()=>{let S=C??{};return b&&(S={...S,...b??{}}),S};return I.jsxs("div",{style:p??{},className:`${D==="dark"?Ai.dark:""} ${Ai.textareaContainer} ${i!=null&&i.type&&(i!=null&&i.visible)?Ai[i==null?void 0:i.type]:""} ${h?Ai.disabled:null}`,children:[t&&I.jsxs("div",{style:m,className:Ai.textAreaLabel,children:[I.jsx("p",{children:t}),I.jsx("span",{style:g??{},className:Ai.required,children:f&&"*"}),B&&x(B)]}),I.jsxs("div",{className:`${Ai.wrap} ${Ai.textarea} ${U?Ai.focused:""} ${h?Ai.disabled:""} ${i!=null&&i.error?Ai.error:""} ${l?Ai.resize:""}`,ref:j,children:[I.jsx("textarea",{style:T(),className:"",value:a,placeholder:e??"",cols:n??"30",rows:r??"5",maxLength:s??null,onInput:y,onFocus:z,disabled:h,onBlur:W?()=>{}:ie,onChange:Y,onResize:()=>{console.log("resize")}}),o&&I.jsxs("div",{ref:te,className:Ai.popupEmojiContainer,children:[I.jsx("div",{className:Ai.popupEmojiIcon,onClick:S=>{S.preventDefault(),H(!0),G(O=>!O)},children:I.jsx(pL,{})}),W&&I.jsx("div",{ref:N,className:Ai.popupEmojiList,children:vL.map((S,O)=>I.jsx("div",{onClick:P=>{P.preventDefault(),ne(S)},className:Ai.popupEmojiItem,children:S},O))})]})]}),i&&(i==null?void 0:i.text)&&(i==null?void 0:i.text.length)>0&&I.jsx("div",{style:A??{},className:`${Ai.helperTextStyle} ${i!=null&&i.error?Ai.error:""}`,children:I.jsx("p",{style:(i==null?void 0:i.style)??{},children:i.text})})]})},mL="Toggle-module__toggleWrapper",gL="Toggle-module__toggleState",CL="Toggle-module__checked",yL="Toggle-module__disabled",xL="Toggle-module__dark",al={toggleWrapper:mL,toggleState:gL,checked:CL,disabled:yL,dark:xL},bL=({checked:e,change:t,disabled:i=!1,required:n,withActive:r=!0,activeStyle:a,bgStyle:o,checkedBgStyle:s,disabledBgStyle:l,circleStyle:u,checkedCircleStyle:d,disabledCircleStyle:c,theme:h="light"})=>{const[f,p]=ue.useState(!1),m=()=>{!i&&t&&typeof t=="function"&&t(!e)},g=()=>{if(f)return!r||i?{boxShadow:"none",...a}:a??{};if(e){if(s)return s}else if(e){if(i&&l)return l}else if(o)return o;return{}},C=()=>{if(e){if(d)return d}else if(e){if(i&&c)return c}else if(u)return u;return{}};return I.jsx("div",{style:g(),onMouseDown:()=>p(!0),onMouseUp:()=>p(!1),onMouseLeave:()=>p(!1),onClick:m,className:`${h==="dark"?al.dark:""} ${al.toggleWrapper} ${e?al.checked:""} ${i?al.disabled:""}`,children:I.jsx("div",{style:C(),className:al.toggleState,children:I.jsx("input",{type:"checkbox",checked:e,readOnly:!0,disabled:i??!1,hidden:!0,required:n??!1})})})},SL="Radio-module__radioWrapper",EL="Radio-module__sm",wL="Radio-module__md",IL="Radio-module__checked",TL="Radio-module__innerCircle",AL="Radio-module__radioState",DL="Radio-module__disabled",OL="Radio-module__dark",ea={radioWrapper:SL,sm:EL,md:wL,checked:IL,innerCircle:TL,radioState:AL,disabled:DL,dark:OL},bI=({checked:e,change:t,disabled:i,required:n,withUncheckState:r=!1,size:a,radioWrapperStyle:o,radioStateStyle:s,innerCircleStyle:l,theme:u="light"})=>{const[d,c]=ue.useState(!1),h=()=>{t&&typeof t=="function"&&(console.log(e),t(r?!e:!0))};return I.jsxs("div",{className:`${u==="dark"?ea.dark:""} ${ea.radioWrapper} ${ea[a]??ea.md} ${e?ea.checked:""} ${i?ea.disabled:""}`,style:o??{},onClick:h,children:[I.jsx("input",{type:"radio",checked:!0,readOnly:!0,hidden:!0,disabled:i??!1,required:n}),I.jsx("div",{style:s??{},className:ea.radioState,children:I.jsx("div",{style:l??{},className:ea.innerCircle})})]})},RL="Dropdown-module__dropdownWrapper",kL="Dropdown-module__placeHolder",BL="Dropdown-module__dropdownLabel",LL="Dropdown-module__required",PL="Dropdown-module__dropdownContainer",FL="Dropdown-module__sm",ML="Dropdown-module__md",VL="Dropdown-module__selectedTags",NL="Dropdown-module__selectedList",$L="Dropdown-module__additional",HL="Dropdown-module__dropdownListContainer",WL="Dropdown-module__dropdownList",zL="Dropdown-module__hidden",GL="Dropdown-module__visible",UL="Dropdown-module__checkIcon",KL="Dropdown-module__disabled",jL="Dropdown-module__selected",qL="Dropdown-module__dropdownListFooter",YL="Dropdown-module__focused",XL="Dropdown-module__error",ZL="Dropdown-module__dropdownHelperText",JL="Dropdown-module__dark",ii={dropdownWrapper:RL,placeHolder:kL,dropdownLabel:BL,required:LL,dropdownContainer:PL,sm:FL,md:ML,selectedTags:VL,selectedList:NL,additional:$L,dropdownListContainer:HL,dropdownList:WL,hidden:zL,visible:GL,checkIcon:UL,disabled:KL,selected:jL,dropdownListFooter:qL,focused:YL,error:XL,dropdownHelperText:ZL,dark:JL},QL=()=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1.5rem",height:"1.5rem",fill:"none",viewBox:"0 0 20 20",children:I.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"})}),eP=e=>I.jsx("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:I.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"})}),tP=()=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",children:I.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"})}),v_=({label:e,disabled:t,required:i,size:n="md",placeholder:r,msg:a,readOnly:o,searchValue:s,onClearAll:l,onSelectAll:u,onBottomScroll:d,withSearch:c=!1,withTree:h=!1,defaultCollapsed:f=!0,checkboxProps:p,onCollapse:m,onFocus:g,onBlur:C,withClearAll:b=!0,withSelectAll:A=!0,withPlus:B=!1,searchComponent:D=!1,withFooter:U=!0,data:H,onSelect:W,selectedOptionID:G,withFilter:j=!0,withClose:te=!0,fixedDropdown:N=!1,onSearch:Y,pagination:x,withMultiSelect:z=!1,skipSelected:ie,closeOnSelect:ne=!0,labelIcon:pe,closeIcon:le,dropdownIcon:J,iconDown:K,onLabelIconClick:y,onLabelIconMouseEnter:T,onLabelIconMouseLeave:S,dropdownWrapperStyle:O,dropdownLabelStyle:P,requiredStyle:M,labelIconStyle:$,dropdownContainerStyle:Q,placeHolderStyle:oe,selectedTagsStyle:ge,selectedListStyle:ee,additionalStyle:xe,additionalSpanStyle:w,dropdownListStyle:he,listStyle:de,treeProps:F,theme:L="light"})=>{const[X,ce]=ue.useState(!1),[_e,ae]=ue.useState(!1),[we,ke]=ue.useState([]),[Ae,Ne]=ue.useState(""),[ut,et]=ue.useState(""),Ze=ue.useRef([]),li=ue.useRef(null),jt=ue.useRef(null),Ht=ue.useRef({}),mt=ue.useRef([]),Bi=(q,Te)=>{const Z=new Set;return q.filter(Ee=>Z.has(Ee[Te])?!1:(Z.add(Ee[Te]),!0))},Li=q=>{var Te;Ht.current=q,Ne((Te=Ht.current)==null?void 0:Te.label),W&&typeof W=="function"&&W(Ht.current),ae(!1)},wt=q=>{Ze.current=[...Ze.current,...H.filter(Te=>Te.selected==!0),...H.filter(Te=>Te.id===q.id)],q.selected=!q.selected,Ze.current=Bi(Ze.current,"id").filter(Te=>Te.selected),W&&typeof W=="function"&&W(Ze.current),D||Ne(Ze.current.map(Te=>Te.label).join(", ")),ce(Te=>!Te)},qe=q=>{q.stopPropagation(),z||h?c&&(et(""),mt.current=H,ce(Te=>!Te)):(Ze.current=[],G=null,H&&H.length>0&&H.forEach(Te=>Te.selected=!1),ct(""),Ht.current={},W({}),Ne("")),Y&&typeof Y=="function"&&Y("")},ct=q=>{if(Y&&typeof Y=="function"&&Y(q),z&&c){let Te=H,Z=Te.filter(Ee=>{var Be;return(Be=Ee==null?void 0:Ee.label)==null?void 0:Be.toLowerCase().includes((q==null?void 0:q.toLowerCase())||"")});mt.current=(q==null?void 0:q.length)>0?Z:Te,et(q),ce(Ee=>!Ee)}else et(q),Ne(q)},mi=()=>{if(G||G===0){let q=H.filter(Te=>Number(Te.id)===Number(G));q&&q[0]&&(Ht.current=q[0],ie?(Y&&typeof Y=="function"&&Y(Ht.current.label),Ne(Ht.current.label),ne&&ae(Te=>!1)):Li(q[0]))}},[Pi,We]=ue.useState(!1),ht=q=>{let Te=li.current.querySelector("ul"),Ee=Math.abs(Te.scrollTop+Te.clientHeight-Te.scrollHeight)<=2;x&&Ee&&!Pi&&(d&&typeof d=="function"&&d(!0),We(!0)),Ee||We(!1)},Zt=()=>{H.forEach(q=>{q.selected=!1}),Ze.current=[],W([],!0),Ne(""),l&&typeof l=="function"&&l(),ce(q=>!q)},gt=()=>{H.forEach(q=>{q!=null&&q.id&&(q==null?void 0:q.id)!==null&&(q!=null&&q.label)&&(q==null?void 0:q.label)!==""&&(q==null?void 0:q.label)!=="-"&&!q.disabled&&(q.selected=!0)}),Ze.current=H,Ze.current=Bi(Ze.current,"id").filter(q=>q.selected),Ne(Ze.current.map(q=>q.label).join(", ")),u&&typeof u=="function"&&u(),W(Ze.current,!0),ce(q=>!q)},Wt=ue.useRef(!0);ue.useEffect(()=>{if(Wt.current){Wt.current=!1;return}_e||C&&typeof C=="function"&&C()},[_e]);const yr=()=>{g&&typeof g=="function"&&g()},xr=q=>q,Go=q=>{let Te=!0,Z=Ae;return j&&q&&!q.toLowerCase().split(" ").join("").trim().includes(Z.toLowerCase().split(" ").join("").trim())&&Z.trim()!==""&&(Te=!1),ut.length>0&&q==="-"?"hidden":Te?"visible":"hidden"},Uo=q=>{q.composedPath().includes(li.current)||ae(!1)},Ko=q=>{if(N){if(q.composedPath().includes(li.current))return;ae(!1)}},Ma=()=>{const q=li.current,Te=jt.current;if(!Te||!q)return;const Z=q.getBoundingClientRect(),Ee=window.innerHeight;N?(Te.style.position="fixed",Te.style.width=Z.width+"px",Te.style.left=`${Z.left+window.pageXOffset}px`,Z.bottom+Te.offsetHeight>Ee?(Te.style.top=`${window.scrollY+Z.top-Te.offsetHeight-8}px`,Te.style.bottom="unset"):(Te.style.top=`${window.scrollY+Z.bottom}px`,Te.style.bottom="unset")):Z.bottom>Ee?(Te.style.top="unset",Te.style.bottom="calc(100% + 8px)"):(Te.style.bottom="unset",Te.style.top="calc(100% + 8px)")},jo=q=>{Ze.current=q,W&&typeof W=="function"&&W(q)},il=(q,Te)=>{m&&typeof m=="function"&&m(q,Te)},Va=ue.useRef(null);return ue.useEffect(()=>{_e&&Va.current&&Va.current.focus()},[_e]),ue.useEffect(()=>{z&&(Ze.current=H.filter(q=>q.selected),Ne(H.filter(q=>q.selected).map(q=>q.label).join(", ")))},[]),ue.useEffect(()=>{D&&s&&s.length>0&&et(s),mt.current=H},[]),ue.useEffect(()=>{Ma()},[jt,_e]),ue.useEffect(()=>{z||mi()},[G]),ue.useEffect(()=>(document.addEventListener("click",Uo),document.addEventListener("wheel",Ko),()=>{document.removeEventListener("click",Uo),document.removeEventListener("wheel",Ko)}),[]),I.jsxs("div",{className:`${L==="dark"?ii.dark:""} ${ii.dropdownWrapper}`,style:O??{},children:[e&&I.jsxs("label",{className:ii.dropdownLabel,style:P??{},children:[e," ",I.jsx("span",{className:ii.required,style:M??{},children:i&&"*"}),I.jsxs("span",{style:{...$??{},display:"grid",placeItems:"center"},onClick:()=>{y&&typeof y=="function"&&y()},onMouseEnter:()=>{T&&typeof T=="function"&&T()},onMouseLeave:()=>{S&&typeof S=="function"&&S()},children:[" ",xr(pe)]})]}),I.jsxs("div",{onFocus:yr,ref:li,onClick:()=>(ae(q=>!q),Ma()),className:`${ii.dropdownContainer} ${_e&&!o?ii.focused:""} ${t?ii.disabled:""} ${a!=null&&a.error?ii.error:""} ${ii[n]}`,style:Q??{},children:[D?I.jsxs("div",{children:[" ",I.jsx(tP,{})]}):I.jsx(I.Fragment,{children:J&&I.jsx("div",{style:{display:"grid",alignItems:"center",marginRight:"0.5rem"},children:xr(J)})}),!D&&(h||z)&&r&&!_e&&Ze.current.length===0&&I.jsx("span",{className:ii.placeHolder,style:oe??{},children:r??""}),(z||h)&&I.jsx("div",{className:ii.selectedTags,style:ge??{},children:!D&&!_e?I.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"flex-start",width:"100%"},children:[Ze.current.slice(0,3).map((q,Te)=>{let Z=Ze.current[Ze.current.length-1];return I.jsxs("span",{className:ii.selectedList,style:ee??{},children:[q.label,q.id!==Z.id&&Te!==2?",":""," "]},q==null?void 0:q.id)}),Ze.current.length>3&&I.jsxs("div",{className:ii.additional,style:w??{},children:["+",Ze.current.length-3]})]}):I.jsx("input",{ref:Va,onClick:q=>(q.stopPropagation(),ae(!0)),autoCorrect:"off",placeholder:"Search...",type:"text",...D||c?{value:ut}:{},onChange:q=>ct(q.target.value)},G)}),I.jsx("input",{autoCorrect:"off",hidden:z||h,placeholder:r,readOnly:!j||!_e||z||h,type:"text",value:(z||h)&&!D&&_e?"":Ae,onChange:q=>ct(q.target.value)},G),H&&H.length>0&&_e&&I.jsxs("div",{ref:jt,onClick:q=>q.stopPropagation(),className:ii.dropdownListContainer,children:[h?I.jsx(Zk,{SearchValue:ut,expandedNodes:we,setExpandedNodes:ke,checkboxProps:p,onSelect:jo,withClearAll:b,withSelectAll:A,SelectedData:Ze.current,fromDropdown:!0,onCollapse:il,defaultCollapsed:f,data:H,theme:L,treeProps:F}):I.jsx("ul",{onScroll:q=>ht(),onClick:q=>q.stopPropagation(),className:ii.dropdownList,style:he??{},children:(z&&j?mt.current:H).map(q=>{var Te,Z,Ee,Be;return I.jsxs("li",{style:de??{},className:`${!z&&c?ii[Go((q==null?void 0:q.label)??"-")]:""} ${!(q!=null&&q.label)||q.label===void 0||q!=null&&q.disabled?ii.disabled:""} ${(z?q.selected:(Te=Ht.current)!=null&&Te.id&&((Z=Ht.current)==null?void 0:Z.id)===q.id)?ii.selected:""}`,onClick:()=>{z?wt(q):Li(q)},children:[I.jsxs("p",{children:[" ",q!=null&&q.customLabel?q.customLabel():(q==null?void 0:q.label)??"-"]}),B?I.jsx(I.Fragment,{children:q.selected?I.jsx(eP,{}):I.jsx(QL,{})}):(z?q.selected:((Ee=Ht.current)==null?void 0:Ee.id)&&((Be=Ht.current)==null?void 0:Be.id)===q.id)&&I.jsx("span",{className:ii.checkIcon,children:I.jsx(xI,{color:"#7F56D9",width:20,height:20})})]},q==null?void 0:q.id)})}),z&&U&&I.jsxs("div",{className:ii.dropdownListFooter,children:[b&&I.jsx("span",{onClick:Zt,children:"Clear All"}),A&&ut===""&&I.jsx("span",{onClick:gt,children:"Select All"})]})]}),te&&(!c&&Ae.length>0||ut.length>0)&&I.jsx("div",{onClick:q=>qe(q),style:{display:"grid",placeItems:"center",cursor:"pointer"},children:le?xr(le):I.jsx(Ou,{width:16,height:16})}),K?xr(K):I.jsx("div",{style:{display:"grid",placeItems:"center",transform:_e?"rotate(180deg)":"",transition:"transform 0.2s ease-in-out",cursor:"pointer",marginLeft:"10px"},children:!D&&I.jsx(Du,{})})]}),a&&(a==null?void 0:a.visible)&&I.jsx("div",{className:`${ii.dropdownHelperText} ${a!=null&&a.error?ii.error:""}`,children:!_e&&I.jsx("p",{style:(a==null?void 0:a.style)??{},children:a.text})})]})},iP="Tooltip-module__tooltipContainer",nP="Tooltip-module__tooltipContent",rP="Tooltip-module__withoutPointer",aP="Tooltip-module__top",oP="Tooltip-module__right",sP="Tooltip-module__bottom",lP="Tooltip-module__left",uP="Tooltip-module__tooltipTitle",dP="Tooltip-module__tooltipText",cP="Tooltip-module__dark",Nn={tooltipContainer:iP,tooltipContent:nP,withoutPointer:rP,top:aP,right:oP,bottom:sP,left:lP,tooltipTitle:uP,tooltipText:dP,dark:cP},__=({children:e,tooltipSlot:t,delay:i=400,placement:n="top",trigger:r="hover",title:a,text:o,customText:s,tooltipContentStyle:l,tooltipTitlestyle:u,tooltipTextStyle:d,pointerPosition:c="10%",withPointer:h=!1,theme:f})=>{const p=ue.useRef(null),m=ue.useRef(null);let g;const[C,b]=ue.useState(!1),A=()=>{r==="hover"&&(g=setTimeout(()=>{b(!0)},i))},B=()=>{r==="hover"&&(clearTimeout(g),setTimeout(()=>{b(!1)},i))},D=()=>{r==="click"&&b(G=>!G)},U=()=>{const G=p.current,j=m.current;if(!j||!G)return;const te=G.getBoundingClientRect();switch(j.style.position="fixed",n){case"top":j.style.top=`${te.top-j.offsetHeight-8}px`,j.style.left=`${te.left}px`;break;case"bottom":j.style.top=`${te.bottom+8}px`,j.style.left=`${te.left}px`;break;case"left":j.style.top=`${te.top+te.height/2-j.offsetHeight/2}px`,j.style.left=`${te.left-j.offsetWidth-8}px`;break;case"right":j.style.top=`${te.top+te.height/2-j.offsetHeight/2}px`,j.style.left=`${te.right+8}px`;break}},H=G=>{G.composedPath().includes(p.current)||b(!1)},W=()=>{b(!1)};return ue.useEffect(()=>{U()},[p,C,e,n,t,s,a,o]),ue.useEffect(()=>(document.addEventListener("click",H),window.addEventListener("scroll",W,!0),()=>{window.removeEventListener("scroll",W,!0),document.removeEventListener("click",H)}),[]),ue.useEffect(()=>{const G=m.current;G&&(G.style.setProperty("--pointer-position",`${c}`),h||G.classList.add(Nn.withoutPointer))},[C]),I.jsxs("div",{ref:p,className:`${f==="dark"?Nn.dark:""} ${Nn.tooltipContainer}`,onClick:D,onMouseEnter:A,onMouseLeave:B,children:[e,C&&t?I.jsx("div",{style:l??{},onClick:G=>G.stopPropagation(),ref:m,className:`${Nn.tooltipContent} ${n?Nn[n]:Nn.bottom}`,children:t()}):C&&I.jsxs("div",{style:l??{},onClick:G=>G.stopPropagation(),ref:m,className:`${Nn.tooltipContent} ${n?Nn[n]:Nn.bottom}`,children:[s&&typeof s=="function"&&s(),a&&a.length>0&&I.jsx("h2",{className:Nn.tooltipTitle,style:u??{},children:a}),o&&o.length>0&&I.jsx("p",{className:Nn.tooltipText,style:d??{},children:o})]})]})},hP="Popup-module__modalOverlay",fP="Popup-module__popupDrawerMode",pP="Popup-module__popupContainer",vP="Popup-module__closeButton",_P="Popup-module__withOptions",mP="Popup-module__horizontal",gP="Popup-module__popupHeader",CP="Popup-module__popupTitle",yP="Popup-module__popupDescription",xP="Popup-module__typeIcon",bP="Popup-module__icon",SP="Popup-module__templateWrapper",EP="Popup-module__dark",un={modalOverlay:hP,popupDrawerMode:fP,popupContainer:pP,closeButton:vP,withOptions:_P,horizontal:mP,popupHeader:gP,popupTitle:CP,popupDescription:yP,typeIcon:xP,icon:bP,templateWrapper:SP,dark:EP},wP=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]},IP=e=>e.slice((e.lastIndexOf(".")-1>>>0)+2),TP=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 SI=(e,t)=>{const i=new Set;return e.filter(n=>i.has(n[t])?!1:(i.add(n[t]),!0))},AP=()=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:I.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"})}),DP=()=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:I.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"})}),zm=({width:e,color:t})=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"24",height:e??"24",viewBox:"0 0 24 24",fill:"none",children:I.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"})}),EI=({visible:e,template:t,options:i,children:n,onClickOutside:r,onClose:a,widthType:o,modalOverlayStyle:s,popupContainerStyle:l,templateWrapperStyle:u,popupHeaderStyle:d,popupTitleStyle:c,closeButtonStyle:h,theme:f})=>{const p=()=>{if(!(!i||!(i!=null&&i.type)))switch(String(i==null?void 0:i.type)){case"delete":return I.jsx(zm,{});case"unsaved":return I.jsx(DP,{});case"success":return I.jsx(AP,{})}},m=()=>{a&&typeof a=="function"&&a(!1)},g=ue.useRef(null),C=b=>{b.target===g.current&&r&&typeof r=="function"&&r(!1)};return ue.useEffect(()=>(document.addEventListener("click",C),()=>{document.removeEventListener("click",C)}),[]),e&&I.jsx("div",{ref:g,style:s??{},className:`
|
|
38
|
+
${r?br.disabled:""}`,onMouseDown:()=>b(!0),onMouseUp:()=>b(!1),onMouseLeave:()=>b(!1),onClick:()=>{!r&&i&&typeof i=="function"&&i()},children:I.jsxs("div",{className:br.buttonSlot,style:!r&&p?p:{},children:[u||o&&s?s:"",!u&&I.jsx(I.Fragment,{children:a?I.jsx("div",{style:{display:"grid",placeItems:"center"},children:I.jsx(nB,{})}):I.jsx("span",{style:!r&&h?h:{},className:br.buttonLabel,children:e??"Button"})}),o&&l?l:""]})})},mB="FormInput-module__inputWrapper",gB="FormInput-module__inputLabel",CB="FormInput-module__required",yB="FormInput-module__inputContainer",xB="FormInput-module__inputContent",bB="FormInput-module__inputTags",SB="FormInput-module__focused",EB="FormInput-module__error",wB="FormInput-module__rightIcon",IB="FormInput-module__leftIcon",TB="FormInput-module__inputDropDown",AB="FormInput-module__http",DB="FormInput-module__disabled",OB="FormInput-module__sm",RB="FormInput-module__md",kB="FormInput-module__withCopy",BB="FormInput-module__inputHelperText",LB="FormInput-module__dark",fi={inputWrapper:mB,inputLabel:gB,required:CB,inputContainer:yB,inputContent:xB,inputTags:bB,focused:SB,error:EB,rightIcon:wB,leftIcon:IB,inputDropDown:TB,http:AB,disabled:DB,sm:OB,md:RB,withCopy:kB,inputHelperText:BB,dark:LB},Du=({width:e,height:t,color:i})=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"12",height:t??"8",viewBox:"0 0 12 8",fill:"none",children:I.jsx("path",{d:"M1 1.5L6 6.5L11 1.5",stroke:i??"#A4A7AE",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),PB=({width:e,height:t,color:i})=>I.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"20",height:t??"20",viewBox:"0 0 20 20",fill:"none",children:[I.jsx("g",{clipPath:"url(#clip0_444_26)",children:I.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"})}),I.jsx("defs",{children:I.jsx("clipPath",{id:"clip0_444_26",children:I.jsx("rect",{width:"20",height:"20",fill:"white"})})})]}),Ou=e=>I.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:I.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"})}),FB="Checkbox-module__checkboxWrapper",MB="Checkbox-module__sm",VB="Checkbox-module__md",NB="Checkbox-module__checkMark",$B="Checkbox-module__checked",HB="Checkbox-module__disabled",WB="Checkbox-module__dark",Yo={checkboxWrapper:FB,sm:MB,md:VB,checkMark:NB,checked:$B,disabled:HB,dark:WB},xI=({color:e,width:t,height:i})=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:t??"12",height:i??"12",viewBox:"0 0 12 12",fill:"none",children:I.jsx("path",{d:"M10 3L4.5 8.5L2 6",stroke:e??"white",strokeWidth:"1.6666",strokeLinecap:"round",strokeLinejoin:"round"})}),zB=e=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",...e,width:"10",height:"2",viewBox:"0 0 10 2",fill:"none",children:I.jsx("path",{d:"M1.5 1H8.5",stroke:"white",strokeWidth:"1.66666",strokeLinecap:"round",strokeLinejoin:"round"})}),Ru=({checked:e,change:t,disabled:i=!1,required:n=!1,multipleChecked:r=!1,size:a="md",activeStyle:o,checkBoxStyle:s,withActive:l=!0,theme:u="light"})=>{const d=ue.useRef(null),[c,h]=ue.useState(!1),f=()=>{i||t&&typeof t=="function"&&t(!e)},p=()=>c?!l||i?{boxShadow:"none",...o}:o??{}:s??{};return I.jsxs("div",{style:p(),className:` ${u==="dark"?Yo.dark:""} ${Yo.checkboxWrapper} ${Yo[a]} ${e?Yo.checked:Yo.unChecked} ${i?Yo.disabled:""}`,onMouseDown:()=>h(!0),onMouseUp:()=>h(!1),onMouseLeave:()=>h(!1),onClick:f,children:[I.jsx("input",{ref:d,type:"checkbox",disabled:i,checked:e,hidden:!0,readOnly:!0,required:n??!1}),e?r?I.jsx(zB,{}):I.jsx(xI,{}):""]})},GB="Tag-module__tagContainer",UB="Tag-module__onlyLabel",KB="Tag-module__sm",jB="Tag-module__md",qB="Tag-module__lg",YB="Tag-module__tagLabel",XB="Tag-module__tagNumber",ZB="Tag-module__tagClose",JB="Tag-module__dark",$a={tagContainer:GB,onlyLabel:UB,sm:KB,md:jB,lg:qB,tagLabel:YB,tagNumber:XB,tagClose:ZB,dark:JB},Wm=({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,theme:m})=>{const g=()=>!r&&!i&&!n&&!a,C=()=>i,b=()=>{d&&typeof d=="function"&&d(e??null)};return I.jsxs("div",{style:c??{},className:`${m==="dark"?$a.dark:""} ${$a.tagContainer} ${g()?$a.onlyLabel:""} ${$a[u??"md"]}`,children:[r&&I.jsx(Ru,{...s}),i&&C(),t&&I.jsx("p",{style:h??{},className:$a.tagLabel,children:t??""}),a&&I.jsx("div",{style:f??{},className:$a.tagNumber,children:o??""}),n&&I.jsx("div",{style:p??{},className:$a.tagClose,onClick:b,children:I.jsx(Ou,{width:(p==null?void 0:p.width)??"14",height:(p==null?void 0:p.height)??"14",color:(p==null?void 0:p.color)??"#A4A7AE"})})]})},bc=({value:e,label:t,placeholder:i,required:n,disabled:r,type:a,size:o,onChange:s,onFocus:l,onBlur:u,msg:d,readOnly:c,maxLength:h,onlyText:f,tagValues:p,onRightIconIconClick:m,onRightIconIconMouseEnter:g,onRightIconIconMouseLeave:C,onLeftIconIconClick:b,onLeftIconIconMouseEnter:A,onLeftIconIconMouseLeave:B,onPressEnter:D,rightIcon:U,leftIcon:H,fixedDropdown:W=!0,withDropDown:G,dropdownData:j,dropDownPosition:te="left",onSelectData:N,withTags:Y,tagProps:x,withLink:z,withCopy:ie,onCopy:ne,inputWrapperStyle:pe,inputLabelStyle:le,requiredStyle:J,inputContainerStyle:K,leftIconStyle:y,inputDropDownStyle:T,ulStyle:S,liStyle:O,httpStyle:P,inputStyle:M,rightIconStyle:$,withCopyStyle:Q,inputHelperTextStyle:oe,theme:ge="light"})=>{const[ee,xe]=ue.useState(!1),w=ue.useRef(null),[he,de]=ue.useState(!1),[F,L]=ue.useState(!1),X=ue.useRef(null),ce=ue.useRef(null),_e=ue.useRef(null),[ae,we]=ue.useState(!1),[ke,Ae]=ue.useState(1),Ne=qe=>{let ct=qe.target.value;ct.length===1&&(ct=ct.trim()),s&&typeof s=="function"&&s(f?ct.replace(/\d/g,""):ct)},ut=()=>{de(!0),l&&typeof l=="function"&&l()},et=()=>{de(!1),u&&typeof u=="function"&&u()},Ze=qe=>{const ct=qe.target.value,mi=ct.length===0;a==="number"&&(qe.keyCode===69||!mi&&(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)},li=()=>{ne&&typeof ne=="function"&&ne(e)},jt=qe=>qe,Ht=()=>{let qe={};return ie&&(qe.borderTopRightRadius=0,qe.borderBottomRightRadius=0,qe.borderRight=0),G&&(te==="right"?qe.flexDirection="row-reverse":G&&(qe.paddingLeft=0)),{...qe,...K??{}}},mt=qe=>{!qe.composedPath().includes(ce.current)&&qe.composedPath().includes(X.current)||we(!1)},Bi=qe=>{Ae(qe.id),we(!1),N&&typeof N=="function"&&N(qe)},Li=()=>{const qe=_e.current,ct=ce.current;if(!ct||!qe)return;const mi=qe.getBoundingClientRect(),Pi=window.innerHeight,We=80;W&&(ct.style.position="fixed",ct.style.width=We+"px",te==="right"?ct.style.left=`${mi.right-We/2}px`:ct.style.left=`${mi.left+We/2}px`,mi.bottom+ct.offsetHeight>Pi?(ct.style.top=`${window.scrollY+mi.top-ct.offsetHeight}px`,ct.style.bottom="unset"):(ct.style.top=`${window.scrollY+mi.bottom}px`,ct.style.bottom="unset"))};ue.useEffect(()=>{Li()},[ce,ae]),ue.useEffect(()=>{e&&e.length===0&&calculateWidth()},[e]),ue.useEffect(()=>(document.addEventListener("click",mt),()=>{document.removeEventListener("click",mt)}),[]);const wt=ue.useRef(!1);return ue.useEffect(()=>{wt.current?setTimeout(()=>{xe(qe=>!qe)},0):wt.current=!0},[]),I.jsxs("div",{className:`${ge==="dark"?fi.dark:""} ${fi.inputWrapper}`,style:pe??{},children:[t&&I.jsxs("label",{className:fi.inputLabel,style:le??{},children:[t," ",I.jsx("span",{className:fi.required,style:J??{},children:n&&"*"})]}),I.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[I.jsxs("div",{style:Ht(),ref:_e,className:`${fi.inputContainer} ${he&&!c?fi.focused:""} ${r?fi.disabled:""} ${d!=null&&d.error?fi.error:""} ${fi[o??"sm"]}`,children:[!G&&!z&&H&&I.jsx("div",{className:fi.leftIcon,style:y??{},onClick:()=>{b&&typeof b=="function"&&b()},onMouseEnter:()=>{A&&typeof A=="function"&&A()},onMouseLeave:()=>{B&&typeof B=="function"&&B()},children:jt(H)}),!z&&G&&I.jsxs("div",{className:fi.inputDropDown,style:T??{},onClick:()=>(we(!0),Li()),ref:X,children:[j.find(qe=>qe.id===ke).label,ae&&I.jsx("ul",{ref:ce,style:S??{},children:j&&j.length&&j.map((qe,ct)=>I.jsx("li",{style:O??{},onClick:()=>Bi(qe),children:(qe==null?void 0:qe.label)??"-"},qe.id))}),I.jsx(Du,{})]}),z&&I.jsx("div",{className:`${fi.inputDropDown} ${fi.http}`,style:P??{},onClick:()=>we(!0),ref:X,children:"http://"}),I.jsxs("div",{className:fi.inputContent,children:[Y&&p&&p.length>0&&I.jsx("div",{className:fi.inputTags,children:p.map((qe,ct)=>I.jsx("div",{className:fi.inputSingleTags,children:I.jsx(Wm,{...x,id:qe,label:qe,withClose:!0})},ct))}),I.jsx("input",{ref:w,style:M??{},type:a??"text",value:e,onChange:qe=>Ne(qe),onFocus:ut,onBlur:et,disabled:r,required:n,onKeyDown:Ze,readOnly:c,spellCheck:!1,placeholder:i??"",autoComplete:"off",maxLength:h})]}),U&&I.jsx("div",{className:fi.rightIcon,style:$??{},onClick:()=>{m&&typeof m=="function"&&m()},onMouseEnter:()=>{g&&typeof g=="function"&&g()},onMouseLeave:()=>{C&&typeof C=="function"&&C()},children:jt(U)})]}),ie&&I.jsxs("div",{style:Q??{},onClick:li,className:fi.withCopy,children:[I.jsx(PB,{}),I.jsx("span",{children:"Copy"})]})]}),d&&(d==null?void 0:d.visible)&&I.jsx("div",{style:oe??{},className:`${fi.inputHelperText} ${d!=null&&d.error?fi.error:""}`,children:I.jsx("p",{style:(d==null?void 0:d.style)??{},children:d.text})})]})},QB="Textarea-module__textareaContainer",eL="Textarea-module__textAreaLabel",tL="Textarea-module__required",iL="Textarea-module__wrap",nL="Textarea-module__resize",rL="Textarea-module__textarea",aL="Textarea-module__focused",oL="Textarea-module__disabled",sL="Textarea-module__error",lL="Textarea-module__popupEmojiContainer",uL="Textarea-module__popupEmojiIcon",dL="Textarea-module__popupEmojiList",cL="Textarea-module__popupEmojiItem",hL="Textarea-module__helperTextStyle",fL="Textarea-module__dark",Ai={textareaContainer:QB,textAreaLabel:eL,required:tL,wrap:iL,resize:nL,textarea:rL,focused:aL,disabled:oL,error:sL,popupEmojiContainer:lL,popupEmojiIcon:uL,popupEmojiList:dL,popupEmojiItem:cL,helperTextStyle:hL,dark:fL},pL=()=>I.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",children:[I.jsx("g",{clipPath:"url(#clip0_23326_3835)",children:I.jsx("path",{d:"M6.66699 11.6667C6.66699 11.6667 7.91699 13.3334 10.0003 13.3334C12.0837 13.3334 13.3337 11.6667 13.3337 11.6667M12.5003 7.50008H12.5087M7.50033 7.50008H7.50866M18.3337 10.0001C18.3337 14.6025 14.6027 18.3334 10.0003 18.3334C5.39795 18.3334 1.66699 14.6025 1.66699 10.0001C1.66699 5.39771 5.39795 1.66675 10.0003 1.66675C14.6027 1.66675 18.3337 5.39771 18.3337 10.0001ZM12.917 7.50008C12.917 7.7302 12.7304 7.91675 12.5003 7.91675C12.2702 7.91675 12.0837 7.7302 12.0837 7.50008C12.0837 7.26996 12.2702 7.08341 12.5003 7.08341C12.7304 7.08341 12.917 7.26996 12.917 7.50008ZM7.91699 7.50008C7.91699 7.7302 7.73044 7.91675 7.50033 7.91675C7.27021 7.91675 7.08366 7.7302 7.08366 7.50008C7.08366 7.26996 7.27021 7.08341 7.50033 7.08341C7.73044 7.08341 7.91699 7.26996 7.91699 7.50008Z",stroke:"#535862",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),I.jsx("defs",{children:I.jsx("clipPath",{id:"clip0_23326_3835",children:I.jsx("rect",{width:"20",height:"20",fill:"white"})})})]}),vL=["😀","😃","😄","😁","😆","😅","😂","🤣","😊","😇","🙂","🙃","😉","😌","😍","🥰","😘","😙 ","😚","😋","😛","😎","🥳","😢","😭","😤","😠","😡","🤬","🤯","👋"],_L=({placeholder:e,label:t,msg:i,cols:n,rows:r,value:a,withEmoji:o=!1,maxLength:s,withResize:l=!0,onChange:u,onFocus:d,onBlur:c,disabled:h,required:f,textareaContainerStyle:p,textareaLabelStyle:m,requiredStyle:g,textareaStyle:C,focusStyle:b,textareaHelperTextStyle:A,labelIcon:B,theme:D})=>{const[U,H]=ue.useState(!1),[W,G]=ue.useState(!1),j=ue.useRef(null),te=ue.useRef(null),N=ue.useRef(null),Y=S=>{let O=S.target.value;u&&typeof u=="function"&&u(O)},x=S=>S,z=()=>{H(!0),d&&typeof d=="function"&&d()},ie=()=>{H(!1),c&&typeof c=="function"&&c()},ne=S=>{const O=j.current.querySelector("textarea");if(!O)return;const P=O.selectionStart,M=O.selectionEnd,$=O.scrollTop,Q=a.slice(0,P)+S+a.slice(M);u&&typeof u=="function"&&u(Q),setTimeout(()=>{O.focus(),O.setSelectionRange(P+S.length,P+S.length),O.scrollTop=$},0)},pe=()=>{const S=j.current,O=N.current;if(!O||!S)return;const P=S.getBoundingClientRect(),M=220,$=window.innerHeight-P.bottom;P.top,$>=M?(O.style.top="calc(100% + 8px)",O.style.bottom="unset"):(O.style.bottom="calc(100% + 8px)",O.style.top="unset"),P.right>window.innerWidth?O.style.left=`calc(100% - ${P.width}px)`:P.left<0?O.style.left="0px":O.style.left=""};ue.useEffect(()=>(W&&(pe(),document.addEventListener("mousedown",le)),()=>{document.removeEventListener("mousedown",le)}),[W]);const le=S=>{te.current&&!te.current.contains(S.target)&&G(!1)};ue.useEffect(()=>(W&&document.addEventListener("mousedown",le),()=>{document.removeEventListener("mousedown",le)}),[W]),ue.useEffect(()=>{const S=j.current.querySelector("textarea"),O=j.current;if(!S||!O)return;const P=new ResizeObserver(()=>{O.style.width=`${S.offsetWidth}px`,O.style.height=`${S.offsetHeight}px`});return P.observe(S),()=>P.disconnect()},[]);let J=!1;const K=()=>{const S=j.current.querySelector("textarea");!S||J||(S.style.height="auto",S.style.height=`${S.scrollHeight}px`)};ue.useEffect(()=>{const S=j.current.querySelector("textarea"),O=new ResizeObserver(()=>{J=S.offsetHeight<S.scrollHeight});return O.observe(S),()=>O.disconnect()},[]);const y=S=>{J=!1,u==null||u(S.target.value),K()},T=()=>{let S=C??{};return b&&(S={...S,...b??{}}),S};return I.jsxs("div",{style:p??{},className:`${D==="dark"?Ai.dark:""} ${Ai.textareaContainer} ${i!=null&&i.type&&(i!=null&&i.visible)?Ai[i==null?void 0:i.type]:""} ${h?Ai.disabled:null}`,children:[t&&I.jsxs("div",{style:m,className:Ai.textAreaLabel,children:[I.jsx("p",{children:t}),I.jsx("span",{style:g??{},className:Ai.required,children:f&&"*"}),B&&x(B)]}),I.jsxs("div",{className:`${Ai.wrap} ${l?Ai.resize:""}`,ref:j,children:[I.jsx("textarea",{style:T(),className:`${Ai.textarea} ${U?Ai.focused:""} ${h?Ai.disabled:""} ${i!=null&&i.error?Ai.error:""}`,value:a,placeholder:e??"",cols:n??"30",rows:r??"5",maxLength:s??null,onInput:y,onFocus:z,disabled:h,onBlur:W?()=>{}:ie,onChange:Y,onResize:()=>{console.log("resize")}}),o&&I.jsxs("div",{ref:te,className:Ai.popupEmojiContainer,children:[I.jsx("div",{className:Ai.popupEmojiIcon,onClick:S=>{S.preventDefault(),H(!0),G(O=>!O)},children:I.jsx(pL,{})}),W&&I.jsx("div",{ref:N,className:Ai.popupEmojiList,children:vL.map((S,O)=>I.jsx("div",{onClick:P=>{P.preventDefault(),ne(S)},className:Ai.popupEmojiItem,children:S},O))})]})]}),i&&(i==null?void 0:i.text)&&(i==null?void 0:i.text.length)>0&&I.jsx("div",{style:A??{},className:`${Ai.helperTextStyle} ${i!=null&&i.error?Ai.error:""}`,children:I.jsx("p",{style:(i==null?void 0:i.style)??{},children:i.text})})]})},mL="Toggle-module__toggleWrapper",gL="Toggle-module__toggleState",CL="Toggle-module__checked",yL="Toggle-module__disabled",xL="Toggle-module__dark",al={toggleWrapper:mL,toggleState:gL,checked:CL,disabled:yL,dark:xL},bL=({checked:e,change:t,disabled:i=!1,required:n,withActive:r=!0,activeStyle:a,bgStyle:o,checkedBgStyle:s,disabledBgStyle:l,circleStyle:u,checkedCircleStyle:d,disabledCircleStyle:c,theme:h="light"})=>{const[f,p]=ue.useState(!1),m=()=>{!i&&t&&typeof t=="function"&&t(!e)},g=()=>{if(f)return!r||i?{boxShadow:"none",...a}:a??{};if(e){if(s)return s}else if(e){if(i&&l)return l}else if(o)return o;return{}},C=()=>{if(e){if(d)return d}else if(e){if(i&&c)return c}else if(u)return u;return{}};return I.jsx("div",{style:g(),onMouseDown:()=>p(!0),onMouseUp:()=>p(!1),onMouseLeave:()=>p(!1),onClick:m,className:`${h==="dark"?al.dark:""} ${al.toggleWrapper} ${e?al.checked:""} ${i?al.disabled:""}`,children:I.jsx("div",{style:C(),className:al.toggleState,children:I.jsx("input",{type:"checkbox",checked:e,readOnly:!0,disabled:i??!1,hidden:!0,required:n??!1})})})},SL="Radio-module__radioWrapper",EL="Radio-module__sm",wL="Radio-module__md",IL="Radio-module__checked",TL="Radio-module__innerCircle",AL="Radio-module__radioState",DL="Radio-module__disabled",OL="Radio-module__dark",ea={radioWrapper:SL,sm:EL,md:wL,checked:IL,innerCircle:TL,radioState:AL,disabled:DL,dark:OL},bI=({checked:e,change:t,disabled:i,required:n,withUncheckState:r=!1,size:a,radioWrapperStyle:o,radioStateStyle:s,innerCircleStyle:l,theme:u="light"})=>{const[d,c]=ue.useState(!1),h=()=>{t&&typeof t=="function"&&(console.log(e),t(r?!e:!0))};return I.jsxs("div",{className:`${u==="dark"?ea.dark:""} ${ea.radioWrapper} ${ea[a]??ea.md} ${e?ea.checked:""} ${i?ea.disabled:""}`,style:o??{},onClick:h,children:[I.jsx("input",{type:"radio",checked:!0,readOnly:!0,hidden:!0,disabled:i??!1,required:n}),I.jsx("div",{style:s??{},className:ea.radioState,children:I.jsx("div",{style:l??{},className:ea.innerCircle})})]})},RL="Dropdown-module__dropdownWrapper",kL="Dropdown-module__placeHolder",BL="Dropdown-module__dropdownLabel",LL="Dropdown-module__required",PL="Dropdown-module__dropdownContainer",FL="Dropdown-module__sm",ML="Dropdown-module__md",VL="Dropdown-module__selectedTags",NL="Dropdown-module__selectedList",$L="Dropdown-module__additional",HL="Dropdown-module__dropdownListContainer",WL="Dropdown-module__dropdownList",zL="Dropdown-module__hidden",GL="Dropdown-module__visible",UL="Dropdown-module__checkIcon",KL="Dropdown-module__disabled",jL="Dropdown-module__selected",qL="Dropdown-module__dropdownListFooter",YL="Dropdown-module__focused",XL="Dropdown-module__error",ZL="Dropdown-module__dropdownHelperText",JL="Dropdown-module__dark",ii={dropdownWrapper:RL,placeHolder:kL,dropdownLabel:BL,required:LL,dropdownContainer:PL,sm:FL,md:ML,selectedTags:VL,selectedList:NL,additional:$L,dropdownListContainer:HL,dropdownList:WL,hidden:zL,visible:GL,checkIcon:UL,disabled:KL,selected:jL,dropdownListFooter:qL,focused:YL,error:XL,dropdownHelperText:ZL,dark:JL},QL=()=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1.5rem",height:"1.5rem",fill:"none",viewBox:"0 0 20 20",children:I.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"})}),eP=e=>I.jsx("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:I.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"})}),tP=()=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",children:I.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"})}),v_=({label:e,disabled:t,required:i,size:n="md",placeholder:r,msg:a,readOnly:o,searchValue:s,onClearAll:l,onSelectAll:u,onBottomScroll:d,withSearch:c=!1,withTree:h=!1,defaultCollapsed:f=!0,checkboxProps:p,onCollapse:m,onFocus:g,onBlur:C,withClearAll:b=!0,withSelectAll:A=!0,withPlus:B=!1,searchComponent:D=!1,withFooter:U=!0,data:H,onSelect:W,selectedOptionID:G,withFilter:j=!0,withClose:te=!0,fixedDropdown:N=!1,onSearch:Y,pagination:x,withMultiSelect:z=!1,skipSelected:ie,closeOnSelect:ne=!0,labelIcon:pe,closeIcon:le,dropdownIcon:J,iconDown:K,onLabelIconClick:y,onLabelIconMouseEnter:T,onLabelIconMouseLeave:S,dropdownWrapperStyle:O,dropdownLabelStyle:P,requiredStyle:M,labelIconStyle:$,dropdownContainerStyle:Q,placeHolderStyle:oe,selectedTagsStyle:ge,selectedListStyle:ee,additionalStyle:xe,additionalSpanStyle:w,dropdownListStyle:he,listStyle:de,treeProps:F,theme:L="light"})=>{const[X,ce]=ue.useState(!1),[_e,ae]=ue.useState(!1),[we,ke]=ue.useState([]),[Ae,Ne]=ue.useState(""),[ut,et]=ue.useState(""),Ze=ue.useRef([]),li=ue.useRef(null),jt=ue.useRef(null),Ht=ue.useRef({}),mt=ue.useRef([]),Bi=(q,Te)=>{const Z=new Set;return q.filter(Ee=>Z.has(Ee[Te])?!1:(Z.add(Ee[Te]),!0))},Li=q=>{var Te;Ht.current=q,Ne((Te=Ht.current)==null?void 0:Te.label),W&&typeof W=="function"&&W(Ht.current),ae(!1)},wt=q=>{Ze.current=[...Ze.current,...H.filter(Te=>Te.selected==!0),...H.filter(Te=>Te.id===q.id)],q.selected=!q.selected,Ze.current=Bi(Ze.current,"id").filter(Te=>Te.selected),W&&typeof W=="function"&&W(Ze.current),D||Ne(Ze.current.map(Te=>Te.label).join(", ")),ce(Te=>!Te)},qe=q=>{q.stopPropagation(),z||h?c&&(et(""),mt.current=H,ce(Te=>!Te)):(Ze.current=[],G=null,H&&H.length>0&&H.forEach(Te=>Te.selected=!1),ct(""),Ht.current={},W({}),Ne("")),Y&&typeof Y=="function"&&Y("")},ct=q=>{if(Y&&typeof Y=="function"&&Y(q),z&&c){let Te=H,Z=Te.filter(Ee=>{var Be;return(Be=Ee==null?void 0:Ee.label)==null?void 0:Be.toLowerCase().includes((q==null?void 0:q.toLowerCase())||"")});mt.current=(q==null?void 0:q.length)>0?Z:Te,et(q),ce(Ee=>!Ee)}else et(q),Ne(q)},mi=()=>{if(G||G===0){let q=H.filter(Te=>Number(Te.id)===Number(G));q&&q[0]&&(Ht.current=q[0],ie?(Y&&typeof Y=="function"&&Y(Ht.current.label),Ne(Ht.current.label),ne&&ae(Te=>!1)):Li(q[0]))}},[Pi,We]=ue.useState(!1),ht=q=>{let Te=li.current.querySelector("ul"),Ee=Math.abs(Te.scrollTop+Te.clientHeight-Te.scrollHeight)<=2;x&&Ee&&!Pi&&(d&&typeof d=="function"&&d(!0),We(!0)),Ee||We(!1)},Zt=()=>{H.forEach(q=>{q.selected=!1}),Ze.current=[],W([],!0),Ne(""),l&&typeof l=="function"&&l(),ce(q=>!q)},gt=()=>{H.forEach(q=>{q!=null&&q.id&&(q==null?void 0:q.id)!==null&&(q!=null&&q.label)&&(q==null?void 0:q.label)!==""&&(q==null?void 0:q.label)!=="-"&&!q.disabled&&(q.selected=!0)}),Ze.current=H,Ze.current=Bi(Ze.current,"id").filter(q=>q.selected),Ne(Ze.current.map(q=>q.label).join(", ")),u&&typeof u=="function"&&u(),W(Ze.current,!0),ce(q=>!q)},Wt=ue.useRef(!0);ue.useEffect(()=>{if(Wt.current){Wt.current=!1;return}_e||C&&typeof C=="function"&&C()},[_e]);const yr=()=>{g&&typeof g=="function"&&g()},xr=q=>q,Go=q=>{let Te=!0,Z=Ae;return j&&q&&!q.toLowerCase().split(" ").join("").trim().includes(Z.toLowerCase().split(" ").join("").trim())&&Z.trim()!==""&&(Te=!1),ut.length>0&&q==="-"?"hidden":Te?"visible":"hidden"},Uo=q=>{q.composedPath().includes(li.current)||ae(!1)},Ko=q=>{if(N){if(q.composedPath().includes(li.current))return;ae(!1)}},Ma=()=>{const q=li.current,Te=jt.current;if(!Te||!q)return;const Z=q.getBoundingClientRect(),Ee=window.innerHeight;N?(Te.style.position="fixed",Te.style.width=Z.width+"px",Te.style.left=`${Z.left+window.pageXOffset}px`,Z.bottom+Te.offsetHeight>Ee?(Te.style.top=`${window.scrollY+Z.top-Te.offsetHeight-8}px`,Te.style.bottom="unset"):(Te.style.top=`${window.scrollY+Z.bottom}px`,Te.style.bottom="unset")):Z.bottom>Ee?(Te.style.top="unset",Te.style.bottom="calc(100% + 8px)"):(Te.style.bottom="unset",Te.style.top="calc(100% + 8px)")},jo=q=>{Ze.current=q,W&&typeof W=="function"&&W(q)},il=(q,Te)=>{m&&typeof m=="function"&&m(q,Te)},Va=ue.useRef(null);return ue.useEffect(()=>{_e&&Va.current&&Va.current.focus()},[_e]),ue.useEffect(()=>{z&&(Ze.current=H.filter(q=>q.selected),Ne(H.filter(q=>q.selected).map(q=>q.label).join(", ")))},[]),ue.useEffect(()=>{D&&s&&s.length>0&&et(s),mt.current=H},[]),ue.useEffect(()=>{Ma()},[jt,_e]),ue.useEffect(()=>{z||mi()},[G]),ue.useEffect(()=>(document.addEventListener("click",Uo),document.addEventListener("wheel",Ko),()=>{document.removeEventListener("click",Uo),document.removeEventListener("wheel",Ko)}),[]),I.jsxs("div",{className:`${L==="dark"?ii.dark:""} ${ii.dropdownWrapper}`,style:O??{},children:[e&&I.jsxs("label",{className:ii.dropdownLabel,style:P??{},children:[e," ",I.jsx("span",{className:ii.required,style:M??{},children:i&&"*"}),I.jsxs("span",{style:{...$??{},display:"grid",placeItems:"center"},onClick:()=>{y&&typeof y=="function"&&y()},onMouseEnter:()=>{T&&typeof T=="function"&&T()},onMouseLeave:()=>{S&&typeof S=="function"&&S()},children:[" ",xr(pe)]})]}),I.jsxs("div",{onFocus:yr,ref:li,onClick:()=>(ae(q=>!q),Ma()),className:`${ii.dropdownContainer} ${_e&&!o?ii.focused:""} ${t?ii.disabled:""} ${a!=null&&a.error?ii.error:""} ${ii[n]}`,style:Q??{},children:[D?I.jsxs("div",{children:[" ",I.jsx(tP,{})]}):I.jsx(I.Fragment,{children:J&&I.jsx("div",{style:{display:"grid",alignItems:"center",marginRight:"0.5rem"},children:xr(J)})}),!D&&(h||z)&&r&&!_e&&Ze.current.length===0&&I.jsx("span",{className:ii.placeHolder,style:oe??{},children:r??""}),(z||h)&&I.jsx("div",{className:ii.selectedTags,style:ge??{},children:!D&&!_e?I.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"flex-start",width:"100%"},children:[Ze.current.slice(0,3).map((q,Te)=>{let Z=Ze.current[Ze.current.length-1];return I.jsxs("span",{className:ii.selectedList,style:ee??{},children:[q.label,q.id!==Z.id&&Te!==2?",":""," "]},q==null?void 0:q.id)}),Ze.current.length>3&&I.jsxs("div",{className:ii.additional,style:w??{},children:["+",Ze.current.length-3]})]}):I.jsx("input",{ref:Va,onClick:q=>(q.stopPropagation(),ae(!0)),autoCorrect:"off",placeholder:"Search...",type:"text",...D||c?{value:ut}:{},onChange:q=>ct(q.target.value)},G)}),I.jsx("input",{autoCorrect:"off",hidden:z||h,placeholder:r,readOnly:!j||!_e||z||h,type:"text",value:(z||h)&&!D&&_e?"":Ae,onChange:q=>ct(q.target.value)},G),H&&H.length>0&&_e&&I.jsxs("div",{ref:jt,onClick:q=>q.stopPropagation(),className:ii.dropdownListContainer,children:[h?I.jsx(Zk,{SearchValue:ut,expandedNodes:we,setExpandedNodes:ke,checkboxProps:p,onSelect:jo,withClearAll:b,withSelectAll:A,SelectedData:Ze.current,fromDropdown:!0,onCollapse:il,defaultCollapsed:f,data:H,theme:L,treeProps:F}):I.jsx("ul",{onScroll:q=>ht(),onClick:q=>q.stopPropagation(),className:ii.dropdownList,style:he??{},children:(z&&j?mt.current:H).map(q=>{var Te,Z,Ee,Be;return I.jsxs("li",{style:de??{},className:`${!z&&c?ii[Go((q==null?void 0:q.label)??"-")]:""} ${!(q!=null&&q.label)||q.label===void 0||q!=null&&q.disabled?ii.disabled:""} ${(z?q.selected:(Te=Ht.current)!=null&&Te.id&&((Z=Ht.current)==null?void 0:Z.id)===q.id)?ii.selected:""}`,onClick:()=>{z?wt(q):Li(q)},children:[I.jsxs("p",{children:[" ",q!=null&&q.customLabel?q.customLabel():(q==null?void 0:q.label)??"-"]}),B?I.jsx(I.Fragment,{children:q.selected?I.jsx(eP,{}):I.jsx(QL,{})}):(z?q.selected:((Ee=Ht.current)==null?void 0:Ee.id)&&((Be=Ht.current)==null?void 0:Be.id)===q.id)&&I.jsx("span",{className:ii.checkIcon,children:I.jsx(xI,{color:"#7F56D9",width:20,height:20})})]},q==null?void 0:q.id)})}),z&&U&&I.jsxs("div",{className:ii.dropdownListFooter,children:[b&&I.jsx("span",{onClick:Zt,children:"Clear All"}),A&&ut===""&&I.jsx("span",{onClick:gt,children:"Select All"})]})]}),te&&(!c&&Ae.length>0||ut.length>0)&&I.jsx("div",{onClick:q=>qe(q),style:{display:"grid",placeItems:"center",cursor:"pointer"},children:le?xr(le):I.jsx(Ou,{width:16,height:16})}),K?xr(K):I.jsx("div",{style:{display:"grid",placeItems:"center",transform:_e?"rotate(180deg)":"",transition:"transform 0.2s ease-in-out",cursor:"pointer",marginLeft:"10px"},children:!D&&I.jsx(Du,{})})]}),a&&(a==null?void 0:a.visible)&&I.jsx("div",{className:`${ii.dropdownHelperText} ${a!=null&&a.error?ii.error:""}`,children:!_e&&I.jsx("p",{style:(a==null?void 0:a.style)??{},children:a.text})})]})},iP="Tooltip-module__tooltipContainer",nP="Tooltip-module__tooltipContent",rP="Tooltip-module__withoutPointer",aP="Tooltip-module__top",oP="Tooltip-module__right",sP="Tooltip-module__bottom",lP="Tooltip-module__left",uP="Tooltip-module__tooltipTitle",dP="Tooltip-module__tooltipText",cP="Tooltip-module__dark",Nn={tooltipContainer:iP,tooltipContent:nP,withoutPointer:rP,top:aP,right:oP,bottom:sP,left:lP,tooltipTitle:uP,tooltipText:dP,dark:cP},__=({children:e,tooltipSlot:t,delay:i=400,placement:n="top",trigger:r="hover",title:a,text:o,customText:s,tooltipContentStyle:l,tooltipTitlestyle:u,tooltipTextStyle:d,pointerPosition:c="10%",withPointer:h=!1,theme:f})=>{const p=ue.useRef(null),m=ue.useRef(null);let g;const[C,b]=ue.useState(!1),A=()=>{r==="hover"&&(g=setTimeout(()=>{b(!0)},i))},B=()=>{r==="hover"&&(clearTimeout(g),setTimeout(()=>{b(!1)},i))},D=()=>{r==="click"&&b(G=>!G)},U=()=>{const G=p.current,j=m.current;if(!j||!G)return;const te=G.getBoundingClientRect();switch(j.style.position="fixed",n){case"top":j.style.top=`${te.top-j.offsetHeight-8}px`,j.style.left=`${te.left}px`;break;case"bottom":j.style.top=`${te.bottom+8}px`,j.style.left=`${te.left}px`;break;case"left":j.style.top=`${te.top+te.height/2-j.offsetHeight/2}px`,j.style.left=`${te.left-j.offsetWidth-8}px`;break;case"right":j.style.top=`${te.top+te.height/2-j.offsetHeight/2}px`,j.style.left=`${te.right+8}px`;break}},H=G=>{G.composedPath().includes(p.current)||b(!1)},W=()=>{b(!1)};return ue.useEffect(()=>{U()},[p,C,e,n,t,s,a,o]),ue.useEffect(()=>(document.addEventListener("click",H),window.addEventListener("scroll",W,!0),()=>{window.removeEventListener("scroll",W,!0),document.removeEventListener("click",H)}),[]),ue.useEffect(()=>{const G=m.current;G&&(G.style.setProperty("--pointer-position",`${c}`),h||G.classList.add(Nn.withoutPointer))},[C]),I.jsxs("div",{ref:p,className:`${f==="dark"?Nn.dark:""} ${Nn.tooltipContainer}`,onClick:D,onMouseEnter:A,onMouseLeave:B,children:[e,C&&t?I.jsx("div",{style:l??{},onClick:G=>G.stopPropagation(),ref:m,className:`${Nn.tooltipContent} ${n?Nn[n]:Nn.bottom}`,children:t()}):C&&I.jsxs("div",{style:l??{},onClick:G=>G.stopPropagation(),ref:m,className:`${Nn.tooltipContent} ${n?Nn[n]:Nn.bottom}`,children:[s&&typeof s=="function"&&s(),a&&a.length>0&&I.jsx("h2",{className:Nn.tooltipTitle,style:u??{},children:a}),o&&o.length>0&&I.jsx("p",{className:Nn.tooltipText,style:d??{},children:o})]})]})},hP="Popup-module__modalOverlay",fP="Popup-module__popupDrawerMode",pP="Popup-module__popupContainer",vP="Popup-module__closeButton",_P="Popup-module__withOptions",mP="Popup-module__horizontal",gP="Popup-module__popupHeader",CP="Popup-module__popupTitle",yP="Popup-module__popupDescription",xP="Popup-module__typeIcon",bP="Popup-module__icon",SP="Popup-module__templateWrapper",EP="Popup-module__dark",un={modalOverlay:hP,popupDrawerMode:fP,popupContainer:pP,closeButton:vP,withOptions:_P,horizontal:mP,popupHeader:gP,popupTitle:CP,popupDescription:yP,typeIcon:xP,icon:bP,templateWrapper:SP,dark:EP},wP=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]},IP=e=>e.slice((e.lastIndexOf(".")-1>>>0)+2),TP=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 SI=(e,t)=>{const i=new Set;return e.filter(n=>i.has(n[t])?!1:(i.add(n[t]),!0))},AP=()=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:I.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"})}),DP=()=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:I.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"})}),zm=({width:e,color:t})=>I.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:e??"24",height:e??"24",viewBox:"0 0 24 24",fill:"none",children:I.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"})}),EI=({visible:e,template:t,options:i,children:n,onClickOutside:r,onClose:a,widthType:o,modalOverlayStyle:s,popupContainerStyle:l,templateWrapperStyle:u,popupHeaderStyle:d,popupTitleStyle:c,closeButtonStyle:h,theme:f})=>{const p=()=>{if(!(!i||!(i!=null&&i.type)))switch(String(i==null?void 0:i.type)){case"delete":return I.jsx(zm,{});case"unsaved":return I.jsx(DP,{});case"success":return I.jsx(AP,{})}},m=()=>{a&&typeof a=="function"&&a(!1)},g=ue.useRef(null),C=b=>{b.target===g.current&&r&&typeof r=="function"&&r(!1)};return ue.useEffect(()=>(document.addEventListener("click",C),()=>{document.removeEventListener("click",C)}),[]),e&&I.jsx("div",{ref:g,style:s??{},className:`
|
|
39
39
|
${f==="dark"?un.dark:""}
|
|
40
40
|
${un.modalOverlay}
|
|
41
41
|
${i&&(i==null?void 0:i.mode)==="drawer"?un.popupDrawerMode:""}
|
|
@@ -1197,59 +1197,52 @@ const rB = ({ loadingColor: e }) => /* @__PURE__ */ I.jsxs(
|
|
|
1197
1197
|
/* @__PURE__ */ I.jsx("span", { style: g ?? {}, className: Oi.required, children: f && "*" }),
|
|
1198
1198
|
B && x(B)
|
|
1199
1199
|
] }),
|
|
1200
|
-
/* @__PURE__ */ I.jsxs(
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
},
|
|
1247
|
-
O
|
|
1248
|
-
)) })
|
|
1249
|
-
] })
|
|
1250
|
-
]
|
|
1251
|
-
}
|
|
1252
|
-
),
|
|
1200
|
+
/* @__PURE__ */ I.jsxs("div", { className: `${Oi.wrap} ${l ? Oi.resize : ""}`, ref: j, children: [
|
|
1201
|
+
/* @__PURE__ */ I.jsx(
|
|
1202
|
+
"textarea",
|
|
1203
|
+
{
|
|
1204
|
+
style: T(),
|
|
1205
|
+
className: `${Oi.textarea} ${U ? Oi.focused : ""} ${h ? Oi.disabled : ""} ${i != null && i.error ? Oi.error : ""}`,
|
|
1206
|
+
value: a,
|
|
1207
|
+
placeholder: e ?? "",
|
|
1208
|
+
cols: n ?? "30",
|
|
1209
|
+
rows: r ?? "5",
|
|
1210
|
+
maxLength: s ?? null,
|
|
1211
|
+
onInput: y,
|
|
1212
|
+
onFocus: z,
|
|
1213
|
+
disabled: h,
|
|
1214
|
+
onBlur: W ? () => {
|
|
1215
|
+
} : ie,
|
|
1216
|
+
onChange: Y,
|
|
1217
|
+
onResize: () => {
|
|
1218
|
+
console.log("resize");
|
|
1219
|
+
}
|
|
1220
|
+
}
|
|
1221
|
+
),
|
|
1222
|
+
o && /* @__PURE__ */ I.jsxs("div", { ref: te, className: Oi.popupEmojiContainer, children: [
|
|
1223
|
+
/* @__PURE__ */ I.jsx(
|
|
1224
|
+
"div",
|
|
1225
|
+
{
|
|
1226
|
+
className: Oi.popupEmojiIcon,
|
|
1227
|
+
onClick: (S) => {
|
|
1228
|
+
S.preventDefault(), H(!0), G((O) => !O);
|
|
1229
|
+
},
|
|
1230
|
+
children: /* @__PURE__ */ I.jsx(vL, {})
|
|
1231
|
+
}
|
|
1232
|
+
),
|
|
1233
|
+
W && /* @__PURE__ */ I.jsx("div", { ref: N, className: Oi.popupEmojiList, children: _L.map((S, O) => /* @__PURE__ */ I.jsx(
|
|
1234
|
+
"div",
|
|
1235
|
+
{
|
|
1236
|
+
onClick: (P) => {
|
|
1237
|
+
P.preventDefault(), ne(S);
|
|
1238
|
+
},
|
|
1239
|
+
className: Oi.popupEmojiItem,
|
|
1240
|
+
children: S
|
|
1241
|
+
},
|
|
1242
|
+
O
|
|
1243
|
+
)) })
|
|
1244
|
+
] })
|
|
1245
|
+
] }),
|
|
1253
1246
|
i && (i == null ? void 0 : i.text) && (i == null ? void 0 : i.text.length) > 0 && /* @__PURE__ */ I.jsx("div", { style: A ?? {}, className: `${Oi.helperTextStyle} ${i != null && i.error ? Oi.error : ""}`, children: /* @__PURE__ */ I.jsx("p", { style: (i == null ? void 0 : i.style) ?? {}, children: i.text }) })
|
|
1254
1247
|
]
|
|
1255
1248
|
}
|