test-stpr-ui-kit 0.3.0 → 0.3.1

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.
@@ -4195,7 +4195,7 @@ const nb = (o) => `not ${o}`, tb = (o, l) => {
4195
4195
  [Bn.spSelect__error]: !0,
4196
4196
  ...ne && { [ne]: !0 }
4197
4197
  });
4198
- return /* @__PURE__ */ Ce("div", { className: Se, children: [
4198
+ return /* @__PURE__ */ Ce("div", { className: Se, ref: y, children: [
4199
4199
  S && /* @__PURE__ */ I(
4200
4200
  pa,
4201
4201
  {
@@ -4214,7 +4214,6 @@ const nb = (o) => `not ${o}`, tb = (o, l) => {
4214
4214
  title: U ? p : void 0,
4215
4215
  className: sn,
4216
4216
  onClick: ge,
4217
- ref: y,
4218
4217
  children: [
4219
4218
  /* @__PURE__ */ I("div", { className: dn, children: (Y == null ? void 0 : Y.label) || r }),
4220
4219
  /* @__PURE__ */ I(
@@ -21,7 +21,7 @@ Valid keys: `+JSON.stringify(Object.keys(L),null," "));var O=Fe(ue,_e,ne,le,J+"
21
21
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ac(o){if(typeof Symbol<"u"&&o[Symbol.iterator]!=null||o["@@iterator"]!=null)return Array.from(o)}function Lc(o){if(Array.isArray(o))return qi(o)}function Za(o,s){var i=Object.keys(o);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(o);s&&(c=c.filter(function(d){return Object.getOwnPropertyDescriptor(o,d).enumerable})),i.push.apply(i,c)}return i}function Xa(o){for(var s=1;s<arguments.length;s++){var i=arguments[s]!=null?arguments[s]:{};s%2?Za(Object(i),!0).forEach(function(c){Va(o,c,i[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(o,Object.getOwnPropertyDescriptors(i)):Za(Object(i)).forEach(function(c){Object.defineProperty(o,c,Object.getOwnPropertyDescriptor(i,c))})}return o}function Va(o,s,i){return s in o?Object.defineProperty(o,s,{value:i,enumerable:!0,configurable:!0,writable:!0}):o[s]=i,o}function ar(o,s){return Nc(o)||Dc(o,s)||Ja(o,s)||Oc()}function Oc(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
22
22
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ja(o,s){if(o){if(typeof o=="string")return qi(o,s);var i=Object.prototype.toString.call(o).slice(8,-1);if(i==="Object"&&o.constructor&&(i=o.constructor.name),i==="Map"||i==="Set")return Array.from(o);if(i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return qi(o,s)}}function qi(o,s){(s==null||s>o.length)&&(s=o.length);for(var i=0,c=new Array(s);i<s;i++)c[i]=o[i];return c}function Dc(o,s){var i=o==null?null:typeof Symbol<"u"&&o[Symbol.iterator]||o["@@iterator"];if(i!=null){var c=[],d=!0,m=!1,h,b;try{for(i=i.call(o);!(d=(h=i.next()).done)&&(c.push(h.value),!(s&&c.length===s));d=!0);}catch(A){m=!0,b=A}finally{try{!d&&i.return!=null&&i.return()}finally{if(m)throw b}}return c}}function Nc(o){if(Array.isArray(o))return o}var Pc=typeof Ri=="function"?Ri:Ri.default,Fc="file-invalid-type",Bc="file-too-large",Mc="file-too-small",Wc="too-many-files",zc=function(){var s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",i=s.split(","),c=i.length>1?"one of ".concat(i.join(", ")):i[0];return{code:Fc,message:"File type must be ".concat(c)}},Qa=function(s){return{code:Bc,message:"File is larger than ".concat(s," ").concat(s===1?"byte":"bytes")}},es=function(s){return{code:Mc,message:"File is smaller than ".concat(s," ").concat(s===1?"byte":"bytes")}},Rc={code:Wc,message:"Too many files"};function ns(o,s){var i=o.type==="application/x-moz-file"||Pc(o,s);return[i,i?null:zc(s)]}function ts(o,s,i){if(bt(o.size))if(bt(s)&&bt(i)){if(o.size>i)return[!1,Qa(i)];if(o.size<s)return[!1,es(s)]}else{if(bt(s)&&o.size<s)return[!1,es(s)];if(bt(i)&&o.size>i)return[!1,Qa(i)]}return[!0,null]}function bt(o){return o!=null}function qc(o){var s=o.files,i=o.accept,c=o.minSize,d=o.maxSize,m=o.multiple,h=o.maxFiles,b=o.validator;return!m&&s.length>1||m&&h>=1&&s.length>h?!1:s.every(function(A){var S=ns(A,i),E=ar(S,1),k=E[0],j=ts(A,c,d),z=ar(j,1),U=z[0],q=b?b(A):null;return k&&U&&!q})}function Ar(o){return typeof o.isPropagationStopped=="function"?o.isPropagationStopped():typeof o.cancelBubble<"u"?o.cancelBubble:!1}function Lr(o){return o.dataTransfer?Array.prototype.some.call(o.dataTransfer.types,function(s){return s==="Files"||s==="application/x-moz-file"}):!!o.target&&!!o.target.files}function rs(o){o.preventDefault()}function jc(o){return o.indexOf("MSIE")!==-1||o.indexOf("Trident/")!==-1}function $c(o){return o.indexOf("Edge/")!==-1}function Hc(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return jc(o)||$c(o)}function Un(){for(var o=arguments.length,s=new Array(o),i=0;i<o;i++)s[i]=arguments[i];return function(c){for(var d=arguments.length,m=new Array(d>1?d-1:0),h=1;h<d;h++)m[h-1]=arguments[h];return s.some(function(b){return!Ar(c)&&b&&b.apply(void 0,[c].concat(m)),Ar(c)})}}function Uc(){return"showOpenFilePicker"in window}function Gc(o){if(bt(o)){var s=Object.entries(o).filter(function(i){var c=ar(i,2),d=c[0],m=c[1],h=!0;return is(d)||(console.warn('Skipped "'.concat(d,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),h=!1),(!Array.isArray(m)||!m.every(os))&&(console.warn('Skipped "'.concat(d,'" because an invalid file extension was provided.')),h=!1),h}).reduce(function(i,c){var d=ar(c,2),m=d[0],h=d[1];return Xa(Xa({},i),{},Va({},m,h))},{});return[{description:"Files",accept:s}]}return o}function Yc(o){if(bt(o))return Object.entries(o).reduce(function(s,i){var c=ar(i,2),d=c[0],m=c[1];return[].concat(Ka(s),[d],Ka(m))},[]).filter(function(s){return is(s)||os(s)}).join(",")}function Kc(o){return o instanceof DOMException&&(o.name==="AbortError"||o.code===o.ABORT_ERR)}function Zc(o){return o instanceof DOMException&&(o.name==="SecurityError"||o.code===o.SECURITY_ERR)}function is(o){return o==="audio/*"||o==="video/*"||o==="image/*"||o==="text/*"||o==="application/*"||/\w+\/[-+.\w]+/g.test(o)}function os(o){return/^.*\.[\w]+$/.test(o)}var Xc=["children"],Vc=["open"],Jc=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],Qc=["refKey","onChange","onClick"];function eu(o){return ru(o)||tu(o)||as(o)||nu()}function nu(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
23
23
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function tu(o){if(typeof Symbol<"u"&&o[Symbol.iterator]!=null||o["@@iterator"]!=null)return Array.from(o)}function ru(o){if(Array.isArray(o))return $i(o)}function ji(o,s){return au(o)||ou(o,s)||as(o,s)||iu()}function iu(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
24
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function as(o,s){if(o){if(typeof o=="string")return $i(o,s);var i=Object.prototype.toString.call(o).slice(8,-1);if(i==="Object"&&o.constructor&&(i=o.constructor.name),i==="Map"||i==="Set")return Array.from(o);if(i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return $i(o,s)}}function $i(o,s){(s==null||s>o.length)&&(s=o.length);for(var i=0,c=new Array(s);i<s;i++)c[i]=o[i];return c}function ou(o,s){var i=o==null?null:typeof Symbol<"u"&&o[Symbol.iterator]||o["@@iterator"];if(i!=null){var c=[],d=!0,m=!1,h,b;try{for(i=i.call(o);!(d=(h=i.next()).done)&&(c.push(h.value),!(s&&c.length===s));d=!0);}catch(A){m=!0,b=A}finally{try{!d&&i.return!=null&&i.return()}finally{if(m)throw b}}return c}}function au(o){if(Array.isArray(o))return o}function ss(o,s){var i=Object.keys(o);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(o);s&&(c=c.filter(function(d){return Object.getOwnPropertyDescriptor(o,d).enumerable})),i.push.apply(i,c)}return i}function We(o){for(var s=1;s<arguments.length;s++){var i=arguments[s]!=null?arguments[s]:{};s%2?ss(Object(i),!0).forEach(function(c){Hi(o,c,i[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(o,Object.getOwnPropertyDescriptors(i)):ss(Object(i)).forEach(function(c){Object.defineProperty(o,c,Object.getOwnPropertyDescriptor(i,c))})}return o}function Hi(o,s,i){return s in o?Object.defineProperty(o,s,{value:i,enumerable:!0,configurable:!0,writable:!0}):o[s]=i,o}function Or(o,s){if(o==null)return{};var i=su(o,s),c,d;if(Object.getOwnPropertySymbols){var m=Object.getOwnPropertySymbols(o);for(d=0;d<m.length;d++)c=m[d],!(s.indexOf(c)>=0)&&Object.prototype.propertyIsEnumerable.call(o,c)&&(i[c]=o[c])}return i}function su(o,s){if(o==null)return{};var i={},c=Object.keys(o),d,m;for(m=0;m<c.length;m++)d=c[m],!(s.indexOf(d)>=0)&&(i[d]=o[d]);return i}var Dr=F.forwardRef(function(o,s){var i=o.children,c=Or(o,Xc),d=lu(c),m=d.open,h=Or(d,Vc);return F.useImperativeHandle(s,function(){return{open:m}},[m]),F.createElement(F.Fragment,null,i(We(We({},h),{},{open:m})))});Dr.displayName="Dropzone";var ls={disabled:!1,getFilesFromEvent:xc,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};Dr.defaultProps=ls,Dr.propTypes={children:H.func,accept:H.objectOf(H.arrayOf(H.string)),multiple:H.bool,preventDropOnDocument:H.bool,noClick:H.bool,noKeyboard:H.bool,noDrag:H.bool,noDragEventsBubbling:H.bool,minSize:H.number,maxSize:H.number,maxFiles:H.number,disabled:H.bool,getFilesFromEvent:H.func,onFileDialogCancel:H.func,onFileDialogOpen:H.func,useFsAccessApi:H.bool,autoFocus:H.bool,onDragEnter:H.func,onDragLeave:H.func,onDragOver:H.func,onDrop:H.func,onDropAccepted:H.func,onDropRejected:H.func,onError:H.func,validator:H.func};var Ui={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function lu(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},s=We(We({},ls),o),i=s.accept,c=s.disabled,d=s.getFilesFromEvent,m=s.maxSize,h=s.minSize,b=s.multiple,A=s.maxFiles,S=s.onDragEnter,E=s.onDragLeave,k=s.onDragOver,j=s.onDrop,z=s.onDropAccepted,U=s.onDropRejected,q=s.onFileDialogCancel,G=s.onFileDialogOpen,re=s.useFsAccessApi,Te=s.autoFocus,X=s.preventDropOnDocument,M=s.noClick,w=s.noKeyboard,K=s.noDrag,te=s.noDragEventsBubbling,be=s.onError,Le=s.validator,Qe=F.useMemo(function(){return Yc(i)},[i]),ln=F.useMemo(function(){return Gc(i)},[i]),pn=F.useMemo(function(){return typeof G=="function"?G:ps},[G]),Ue=F.useMemo(function(){return typeof q=="function"?q:ps},[q]),W=F.useRef(null),pe=F.useRef(null),ye=F.useReducer(pu,Ui),we=ji(ye,2),Oe=we[0],ze=we[1],L=Oe.isFocused,N=Oe.isFileDialogActive,se=F.useRef(typeof window<"u"&&window.isSecureContext&&re&&Uc()),ce=function(){!se.current&&N&&setTimeout(function(){if(pe.current){var Z=pe.current.files;Z.length||(ze({type:"closeDialog"}),Ue())}},300)};F.useEffect(function(){return window.addEventListener("focus",ce,!1),function(){window.removeEventListener("focus",ce,!1)}},[pe,N,Ue,se]);var ne=F.useRef([]),le=function(Z){W.current&&W.current.contains(Z.target)||(Z.preventDefault(),ne.current=[])};F.useEffect(function(){return X&&(document.addEventListener("dragover",rs,!1),document.addEventListener("drop",le,!1)),function(){X&&(document.removeEventListener("dragover",rs),document.removeEventListener("drop",le))}},[W,X]),F.useEffect(function(){return!c&&Te&&W.current&&W.current.focus(),function(){}},[W,Te,c]);var J=F.useCallback(function(B){be?be(B):console.error(B)},[be]),ue=F.useCallback(function(B){B.preventDefault(),B.persist(),Gn(B),ne.current=[].concat(eu(ne.current),[B.target]),Lr(B)&&Promise.resolve(d(B)).then(function(Z){if(!(Ar(B)&&!te)){var qe=Z.length,Be=qe>0&&qc({files:Z,accept:Qe,minSize:h,maxSize:m,multiple:b,maxFiles:A,validator:Le}),Ge=qe>0&&!Be;ze({isDragAccept:Be,isDragReject:Ge,isDragActive:!0,type:"setDraggedFiles"}),S&&S(B)}}).catch(function(Z){return J(Z)})},[d,S,J,te,Qe,h,m,b,A,Le]),fe=F.useCallback(function(B){B.preventDefault(),B.persist(),Gn(B);var Z=Lr(B);if(Z&&B.dataTransfer)try{B.dataTransfer.dropEffect="copy"}catch{}return Z&&k&&k(B),!1},[k,te]),he=F.useCallback(function(B){B.preventDefault(),B.persist(),Gn(B);var Z=ne.current.filter(function(Be){return W.current&&W.current.contains(Be)}),qe=Z.indexOf(B.target);qe!==-1&&Z.splice(qe,1),ne.current=Z,!(Z.length>0)&&(ze({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),Lr(B)&&E&&E(B))},[W,E,te]),_e=F.useCallback(function(B,Z){var qe=[],Be=[];B.forEach(function(Ge){var Jn=ns(Ge,Qe),Yn=ji(Jn,2),Ct=Yn[0],Tt=Yn[1],kt=ts(Ge,h,m),pt=ji(kt,2),Et=pt[0],It=pt[1],St=Le?Le(Ge):null;if(Ct&&Et&&!St)qe.push(Ge);else{var lr=[Tt,It];St&&(lr=lr.concat(St)),Be.push({file:Ge,errors:lr.filter(function(Xi){return Xi})})}}),(!b&&qe.length>1||b&&A>=1&&qe.length>A)&&(qe.forEach(function(Ge){Be.push({file:Ge,errors:[Rc]})}),qe.splice(0)),ze({acceptedFiles:qe,fileRejections:Be,isDragReject:Be.length>0,type:"setFiles"}),j&&j(qe,Be,Z),Be.length>0&&U&&U(Be,Z),qe.length>0&&z&&z(qe,Z)},[ze,b,Qe,h,m,A,j,z,U,Le]),Fe=F.useCallback(function(B){B.preventDefault(),B.persist(),Gn(B),ne.current=[],Lr(B)&&Promise.resolve(d(B)).then(function(Z){Ar(B)&&!te||_e(Z,B)}).catch(function(Z){return J(Z)}),ze({type:"reset"})},[d,_e,J,te]),O=F.useCallback(function(){if(se.current){ze({type:"openDialog"}),pn();var B={multiple:b,types:ln};window.showOpenFilePicker(B).then(function(Z){return d(Z)}).then(function(Z){_e(Z,null),ze({type:"closeDialog"})}).catch(function(Z){Kc(Z)?(Ue(Z),ze({type:"closeDialog"})):Zc(Z)?(se.current=!1,pe.current?(pe.current.value=null,pe.current.click()):J(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):J(Z)});return}pe.current&&(ze({type:"openDialog"}),pn(),pe.current.value=null,pe.current.click())},[ze,pn,Ue,re,_e,J,ln,b]),tn=F.useCallback(function(B){!W.current||!W.current.isEqualNode(B.target)||(B.key===" "||B.key==="Enter"||B.keyCode===32||B.keyCode===13)&&(B.preventDefault(),O())},[W,O]),Ye=F.useCallback(function(){ze({type:"focus"})},[]),zn=F.useCallback(function(){ze({type:"blur"})},[]),Mr=F.useCallback(function(){M||(Hc()?setTimeout(O,0):O())},[M,O]),rn=function(Z){return c?null:Z},Rt=function(Z){return w?null:rn(Z)},qt=function(Z){return K?null:rn(Z)},Gn=function(Z){te&&Z.stopPropagation()},gn=F.useMemo(function(){return function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=B.refKey,qe=Z===void 0?"ref":Z,Be=B.role,Ge=B.onKeyDown,Jn=B.onFocus,Yn=B.onBlur,Ct=B.onClick,Tt=B.onDragEnter,kt=B.onDragOver,pt=B.onDragLeave,Et=B.onDrop,It=Or(B,Jc);return We(We(Hi({onKeyDown:Rt(Un(Ge,tn)),onFocus:Rt(Un(Jn,Ye)),onBlur:Rt(Un(Yn,zn)),onClick:rn(Un(Ct,Mr)),onDragEnter:qt(Un(Tt,ue)),onDragOver:qt(Un(kt,fe)),onDragLeave:qt(Un(pt,he)),onDrop:qt(Un(Et,Fe)),role:typeof Be=="string"&&Be!==""?Be:"presentation"},qe,W),!c&&!w?{tabIndex:0}:{}),It)}},[W,tn,Ye,zn,Mr,ue,fe,he,Fe,w,K,c]),wt=F.useCallback(function(B){B.stopPropagation()},[]),jt=F.useMemo(function(){return function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=B.refKey,qe=Z===void 0?"ref":Z,Be=B.onChange,Ge=B.onClick,Jn=Or(B,Qc),Yn=Hi({accept:Qe,multiple:b,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:rn(Un(Be,Fe)),onClick:rn(Un(Ge,wt)),tabIndex:-1},qe,pe);return We(We({},Yn),Jn)}},[pe,i,b,Fe,c]);return We(We({},Oe),{},{isFocused:L&&!c,getRootProps:gn,getInputProps:jt,rootRef:W,inputRef:pe,open:rn(O)})}function pu(o,s){switch(s.type){case"focus":return We(We({},o),{},{isFocused:!0});case"blur":return We(We({},o),{},{isFocused:!1});case"openDialog":return We(We({},Ui),{},{isFileDialogActive:!0});case"closeDialog":return We(We({},o),{},{isFileDialogActive:!1});case"setDraggedFiles":return We(We({},o),{},{isDragActive:s.isDragActive,isDragAccept:s.isDragAccept,isDragReject:s.isDragReject});case"setFiles":return We(We({},o),{},{acceptedFiles:s.acceptedFiles,fileRejections:s.fileRejections,isDragReject:s.isDragReject});case"reset":return We({},Ui);default:return o}}function ps(){}const cs=o=>{const{onDropFiles:s,children:i,maxSize:c,accept:d,disabled:m,name:h,multiple:b,maxFiles:A,files:S=[]}=o,E=F.useCallback(k=>{if(!b){s(k,h);return}const j=[...S,...k];if(A&&j.length>A){console.log(`Максимальное возможное количество файлов для загрузки - ${A}`),s(j.slice(0,A),h);return}s(j,h)},[S,A,b,h,s]);return x.jsx(Dr,{multiple:b,onDrop:E,maxSize:c,accept:d,children:({getRootProps:k,getInputProps:j})=>x.jsxs("div",{...k({}),children:[x.jsx("input",{...j({}),disabled:m,name:h}),i]})})},lt={spDropdown:"_spDropdown_lmzju_65",spDropdown__labelText:"_spDropdown__labelText_lmzju_76",spDropdown__tooltipContainer:"_spDropdown__tooltipContainer_lmzju_84",spDropdown__dropdownList:"_spDropdown__dropdownList_lmzju_89",spDropdown__dropdownListHeader:"_spDropdown__dropdownListHeader_lmzju_95",spDropdown__dopdownListItem:"_spDropdown__dopdownListItem_lmzju_102",spDropdown__dopdownListItem_textCenter:"_spDropdown__dopdownListItem_textCenter_lmzju_113",spDropdown__downloadListItemDescription:"_spDropdown__downloadListItemDescription_lmzju_116"},cu=o=>{const{labelText:s="Выпадающий список",listName:i,dropdownList:c=[],dropdownPosition:d=Je.BottomRight,classNameRoot:m}=o,h=D({[lt.spDropdown]:!0,...m&&{[m]:!0}}),b=D({[lt.spDropdown__labelText]:!0}),A=D({[lt.spDropdown__tooltipContainer]:!0}),S=D({[lt.spDropdown__dropdownList]:!0}),E=D({[lt.spDropdown__dropdownListHeader]:!0}),k=D({[lt.spDropdown__downloadListItemDescription]:!0}),[j,z]=F.useState(!1),U=()=>x.jsxs("div",{className:S,children:[i&&x.jsx("div",{className:E,children:i}),c.map((q,G)=>x.jsxs("div",{className:D({[lt.spDropdown__dopdownListItem]:!0,[lt.spDropdown__dopdownListItem_textCenter]:q.textCenter}),onClick:q.onClick,children:[q.name,q.description&&x.jsx("span",{className:k,children:q.description})]},G))]});return x.jsx(kr,{hover:!1,triggerAction:()=>z(!0),actionOnClose:()=>z(!1),text:U(),position:d,noPadding:!0,isToggleClick:!0,trigger:x.jsxs("div",{className:h,children:[x.jsx("div",{className:b,children:s}),x.jsx("div",{className:A,children:x.jsx(dn,{name:Ve.SelectChevronDown,rotate:j?180:void 0})})]})})},us={ellipsisTextWithTooltip:"_ellipsisTextWithTooltip_77a2p_65",ellipsisTextWithTooltip__tooltip:"_ellipsisTextWithTooltip__tooltip_77a2p_68"},uu=o=>{const{text:s,classNameRoot:i,classNameTooltipRoot:c,classNameBaseTooltipContentRoot:d,classNameBaseTooltipRoot:m,...h}=o,b=F.useRef(null),[A,S]=F.useState(!1);F.useEffect(()=>{b.current&&S(b.current.scrollWidth>b.current.clientWidth)},[s]);const E=D({[us.ellipsisTextWithTooltip]:!0,...i&&{[i]:!0}}),k=D({[us.ellipsisTextWithTooltip__tooltip]:!0,...c&&{[c]:!0}});return x.jsx(kr,{classNameTooltip:k,classNameBaseTooltipContentRoot:d,classNameBaseTooltipRoot:m,isVisibleTooltip:A,text:s,trigger:x.jsx(Hn,{...h,classNameRoot:E,isEllipsis:!0,ref:b,children:s})})},sr={spForm:"_spForm_14p1u_65",spForm_fullWidth:"_spForm_fullWidth_14p1u_68",spForm_withSeparator:"_spForm_withSeparator_14p1u_71","spForm_addMargin--size-lg":"_spForm_addMargin--size-lg_14p1u_89","spForm_addMargin--size-md":"_spForm_addMargin--size-md_14p1u_97"},fu=o=>{const{size:s="lg",children:i,onSubmit:c,addMargin:d=!1,withSeparator:m=!1,fullWidth:h=!0,classNameRoot:b,...A}=o,S=D({[sr.spForm]:!0,[sr.spForm_fullWidth]:h,[sr.spForm_addMargin]:d,[sr[`spForm_addMargin--size-${s}`]]:s,[sr.spForm_withSeparator]:m,...b&&{[b]:!0}}),E=k=>{k.preventDefault(),c&&c()};return x.jsx("form",{...A,onSubmit:E,className:S,children:i})},Nr={spLabel:"_spLabel_1drie_65",spLabel__text:"_spLabel__text_1drie_74",spLabel__tooltip:"_spLabel__tooltip_1drie_84",spLabel__required:"_spLabel__required_1drie_89"},Pr=o=>{const{required:s,label:i,infoTooltipText:c,tooltipPosition:d,classNameRoot:m}=o,h=D({[Nr.spLabel]:!0,...m&&{[m]:!0}}),b=D({[Nr.spLabel__text]:!0}),A=D({[Nr.spLabel__required]:s}),S=D({[Nr.spLabel__tooltip]:!0});return x.jsxs("div",{className:h,children:[x.jsx("label",{className:b,children:i}),s&&x.jsx("div",{className:A,children:"*"}),c&&x.jsx("div",{className:S,children:x.jsx(ir,{position:d,text:c})})]})},yt={spInput:"_spInput_1ynu3_65",spInput_error:"_spInput_error_1ynu3_70",spInput__control:"_spInput__control_1ynu3_70",spInput__container:"_spInput__container_1ynu3_77",spInput__control_clearable:"_spInput__control_clearable_1ynu3_97",spInput__clear:"_spInput__clear_1ynu3_117",spInput__error:"_spInput__error_1ynu3_126"},fs=F.forwardRef((o,s)=>{const{value:i,onChange:c,label:d,disabled:m=!1,error:h,required:b,name:A,isClearable:S,pattern:E,onMouseEnter:k,infoTooltipText:j,tooltipPosition:z,isVisibleDefaultTitle:U=!0,placeholder:q="Введите...",classNameRoot:G,classNameError:re,classNameLabel:Te,...X}=o,M=D({[yt.spInput]:!0,[yt.spInput_error]:!!h,...G&&{[G]:!0}}),w=D({[yt.spInput__container]:!0}),K=D({[yt.spInput__control]:!0,[yt.spInput__control_clearable]:S}),te=D({[yt.spInput__clear]:!0}),be=D({[yt.spInput__error]:!0,...re&&{[re]:!0}}),Le=D({...Te&&{[Te]:!0}}),Qe=Ue=>{c(Ue,{name:A,value:""})},ln=Ue=>{const{value:W,name:pe}=Ue.target;E&&W&&!new RegExp(E).test(W)||c(Ue,{value:W,name:pe})},pn=()=>x.jsx("input",{...X,placeholder:q,disabled:m,onChange:ln,title:U?i:void 0,value:i,name:A,className:K,ref:s});return x.jsxs("div",{className:M,children:[d&&x.jsx(Pr,{classNameRoot:Le,tooltipPosition:z,required:b,label:d,infoTooltipText:j}),x.jsxs("div",{className:w,onMouseEnter:k,children:[pn(),S&&i&&!m&&x.jsx(dn,{onClick:Qe,className:te,name:Ve.Trash})]}),h&&x.jsx("div",{className:be,children:h})]})});fs.displayName="Input";const En={spInputFiles:"_spInputFiles_1vz31_65",spInputFiles_error:"_spInputFiles_error_1vz31_70",spInputFiles__control:"_spInputFiles__control_1vz31_70",spInputFiles_fileUploaded:"_spInputFiles_fileUploaded_1vz31_95",spInputFiles_disabled:"_spInputFiles_disabled_1vz31_95",spInputFiles__fileNamesList:"_spInputFiles__fileNamesList_1vz31_105",spInputFiles__fileNamesListItem:"_spInputFiles__fileNamesListItem_1vz31_113",spInputFiles__fileNamesListItemDelete:"_spInputFiles__fileNamesListItemDelete_1vz31_132",spInputFiles__tooltipWrapper:"_spInputFiles__tooltipWrapper_1vz31_147",spInputFiles__tooltip:"_spInputFiles__tooltip_1vz31_147",spInputFiles__delete:"_spInputFiles__delete_1vz31_153",spInputFiles__error:"_spInputFiles__error_1vz31_161"},du=o=>{const{placeholder:s="Загрузите файл",name:i,onDropFiles:c,maxSize:d,accept:m,disabled:h,multiple:b,maxFiles:A,files:S=[],infoTooltipText:E,tooltipPosition:k=Je.TopRight,classNameRoot:j,error:z}=o,U=S.map(w=>w.name),q=(U==null?void 0:U.length)>0,G=D({[En.spInputFiles]:!0,[En.spInputFiles_error]:!!z,[En.spInputFiles_disabled]:h,[En.spInputFiles_fileUploaded]:q,...j&&{[j]:!0}}),re=w=>{const K=[...S],te=K.findIndex(be=>be.name===w);K.splice(te,1),c(K,i)},Te=w=>{w.stopPropagation(),c([],i)},X=()=>b?x.jsx("ul",{className:En.spInputFiles__fileNamesList,children:U.map((w,K)=>x.jsxs("li",{className:En.spInputFiles__fileNamesListItem,onClick:te=>{te.stopPropagation(),re(w)},children:[x.jsx(Hn,{isEllipsis:!0,children:w}),x.jsx("div",{className:En.spInputFiles__fileNamesListItemDelete,children:x.jsx(dn,{name:Ve.Trash})})]},K))}):x.jsx(Hn,{isEllipsis:!0,children:U[0]}),M=()=>x.jsxs(x.Fragment,{children:[q?X():x.jsx(Hn,{children:s}),q?x.jsx("div",{className:En.spInputFiles__delete,onClick:Te,children:x.jsx(dn,{name:Ve.Close})}):E&&x.jsx(ir,{classNameTooltip:En.spInputFiles__tooltipWrapper,position:k,text:E,classNameTriggerTooltip:En.spInputFiles__tooltip})]});return x.jsx(cs,{name:i,files:S,multiple:b,maxSize:d,maxFiles:A,accept:m,onDropFiles:c,disabled:h||q,children:x.jsxs("div",{className:G,children:[x.jsxs("div",{className:En.spInputFiles__control,children:[x.jsx(dn,{name:q?Ve.Check:Ve.Upload}),M()]}),z&&x.jsx("div",{className:En.spInputFiles__error,children:z})]})})},Gi=F.createContext({device:{isDesktop:!1,isMobile:!1,isTablet:!1}});var Yi={};Yi.match=xu,Yi.parse=ds;var mu=/(?:(only|not)?\s*([^\s\(\)]+)(?:\s*and)?\s*)?(.+)?/i,_u=/\(\s*([^\s\:\)]+)\s*(?:\:\s*([^\s\)]+))?\s*\)/,vu=/^(?:(min|max)-)?(.+)/,hu=/(em|rem|px|cm|mm|in|pt|pc)?$/,gu=/(dpi|dpcm|dppx)?$/;function xu(o,s){return ds(o).some(function(i){var c=i.inverse,d=i.type==="all"||s.type===i.type;if(d&&c||!(d||c))return!1;var m=i.expressions.every(function(h){var b=h.feature,A=h.modifier,S=h.value,E=s[b];if(!E)return!1;switch(b){case"orientation":case"scan":return E.toLowerCase()===S.toLowerCase();case"width":case"height":case"device-width":case"device-height":S=vs(S),E=vs(E);break;case"resolution":S=_s(S),E=_s(E);break;case"aspect-ratio":case"device-aspect-ratio":case"device-pixel-ratio":S=ms(S),E=ms(E);break;case"grid":case"color":case"color-index":case"monochrome":S=parseInt(S,10)||1,E=parseInt(E,10)||0;break}switch(A){case"min":return E>=S;case"max":return E<=S;default:return E===S}});return m&&!c||!m&&c})}function ds(o){return o.split(",").map(function(s){s=s.trim();var i=s.match(mu),c=i[1],d=i[2],m=i[3]||"",h={};return h.inverse=!!c&&c.toLowerCase()==="not",h.type=d?d.toLowerCase():"all",m=m.match(/\([^\)]+\)/g)||[],h.expressions=m.map(function(b){var A=b.match(_u),S=A[1].toLowerCase().match(vu);return{modifier:S[1],feature:S[2],value:A[2]}}),h})}function ms(o){var s=Number(o),i;return s||(i=o.match(/^(\d+)\s*\/\s*(\d+)$/),s=i[1]/i[2]),s}function _s(o){var s=parseFloat(o),i=String(o).match(gu)[1];switch(i){case"dpcm":return s/2.54;case"dppx":return s*96;default:return s}}function vs(o){var s=parseFloat(o),i=String(o).match(hu)[1];switch(i){case"em":return s*16;case"rem":return s*16;case"cm":return s*96/2.54;case"mm":return s*96/2.54/10;case"in":return s*96;case"pt":return s*72;case"pc":return s*72/12;default:return s}}var bu=Yi.match,hs=typeof window<"u"?window.matchMedia:null;function yu(o,s,i){var c=this,d;hs&&!i&&(d=hs.call(window,o)),d?(this.matches=d.matches,this.media=d.media,d.addListener(b)):(this.matches=bu(o,s),this.media=o),this.addListener=m,this.removeListener=h,this.dispose=A;function m(S){d&&d.addListener(S)}function h(S){d&&d.removeListener(S)}function b(S){c.matches=S.matches,c.media=S.media}function A(){d&&d.removeListener(b)}}function wu(o,s,i){return new yu(o,s,i)}var Cu=wu;const Tu=Oa(Cu);var ku=/[A-Z]/g,Eu=/^ms-/,Ki={};function Iu(o){return"-"+o.toLowerCase()}function gs(o){if(Ki.hasOwnProperty(o))return Ki[o];var s=o.replace(ku,Iu);return Ki[o]=Eu.test(s)?"-"+s:s}function Su(o,s){if(o===s)return!0;if(!o||!s)return!1;const i=Object.keys(o),c=Object.keys(s),d=i.length;if(c.length!==d)return!1;for(let m=0;m<d;m++){const h=i[m];if(o[h]!==s[h]||!Object.prototype.hasOwnProperty.call(s,h))return!1}return!0}const sn=H.oneOfType([H.string,H.number]),xs={all:H.bool,grid:H.bool,aural:H.bool,braille:H.bool,handheld:H.bool,print:H.bool,projection:H.bool,screen:H.bool,tty:H.bool,tv:H.bool,embossed:H.bool},Au={orientation:H.oneOf(["portrait","landscape"]),scan:H.oneOf(["progressive","interlace"]),aspectRatio:H.string,deviceAspectRatio:H.string,height:sn,deviceHeight:sn,width:sn,deviceWidth:sn,color:H.bool,colorIndex:H.bool,monochrome:H.bool,resolution:sn,type:Object.keys(xs)},{type:v1,...Lu}=Au,Ou={minAspectRatio:H.string,maxAspectRatio:H.string,minDeviceAspectRatio:H.string,maxDeviceAspectRatio:H.string,minHeight:sn,maxHeight:sn,minDeviceHeight:sn,maxDeviceHeight:sn,minWidth:sn,maxWidth:sn,minDeviceWidth:sn,maxDeviceWidth:sn,minColor:H.number,maxColor:H.number,minColorIndex:H.number,maxColorIndex:H.number,minMonochrome:H.number,maxMonochrome:H.number,minResolution:sn,maxResolution:sn,...Lu};var Du={all:{...xs,...Ou}};const Nu=o=>`not ${o}`,Pu=(o,s)=>{const i=gs(o);return typeof s=="number"&&(s=`${s}px`),s===!0?i:s===!1?Nu(i):`(${i}: ${s})`},Fu=o=>o.join(" and "),Bu=o=>{const s=[];return Object.keys(Du.all).forEach(i=>{const c=o[i];c!=null&&s.push(Pu(i,c))}),Fu(s)},Mu=F.createContext(void 0),Wu=o=>o.query||Bu(o),bs=o=>o?Object.keys(o).reduce((i,c)=>(i[gs(c)]=o[c],i),{}):void 0,ys=()=>{const o=F.useRef(!1);return F.useEffect(()=>{o.current=!0},[]),o.current},zu=o=>{const s=F.useContext(Mu),i=()=>bs(o)||bs(s),[c,d]=F.useState(i);return F.useEffect(()=>{const m=i();Su(c,m)||d(m)},[o,s]),c},Ru=o=>{const s=()=>Wu(o),[i,c]=F.useState(s);return F.useEffect(()=>{const d=s();i!==d&&c(d)},[o]),i},qu=(o,s)=>{const i=()=>Tu(o,s||{},!!s),[c,d]=F.useState(i),m=ys();return F.useEffect(()=>{if(m){const h=i();return d(h),()=>{h&&h.dispose()}}},[o,s]),c},ju=o=>{const[s,i]=F.useState(o.matches);return F.useEffect(()=>{const c=d=>{i(d.matches)};return o.addListener(c),i(o.matches),()=>{o.removeListener(c)}},[o]),s},Zi=(o,s,i)=>{const c=zu(s),d=Ru(o);if(!d)throw new Error("Invalid or missing MediaQuery!");const m=qu(d,c),h=ju(m);return ys(),F.useEffect(()=>{},[h]),F.useEffect(()=>()=>{m&&m.dispose()},[]),h},ws=o=>{const{desktop:s,tablet:i,mobile:c}=o,d=Zi(s),m=Zi(i),h=Zi(c);return{device:{isDesktop:d,isTablet:m,isMobile:h}}},$u=o=>{const{breakpoints:s,children:i}=o,{device:c}=ws(s);return x.jsx(Gi.Provider,{value:{device:c},children:i})},Hu=180,In={spSelect:"_spSelect_5qv4w_65",spSelect_error:"_spSelect_error_5qv4w_70",spSelect__control:"_spSelect__control_5qv4w_70",spSelect__value_empty:"_spSelect__value_empty_5qv4w_74",spSelect__icon:"_spSelect__icon_5qv4w_77",spSelect__container:"_spSelect__container_5qv4w_80",spSelect__control_disabled:"_spSelect__control_disabled_5qv4w_115",spSelect__value:"_spSelect__value_5qv4w_74",spSelect__list:"_spSelect__list_5qv4w_148",spSelect__list_scrollable:"_spSelect__list_scrollable_5qv4w_155",spSelect__option:"_spSelect__option_5qv4w_158",spSelect__error:"_spSelect__error_5qv4w_176"},Uu=o=>{const{options:s,placeholder:i="Выберите из списка...",value:c,name:d,onChange:m,onMouseEnter:h,error:b,label:A,infoTooltipText:S,tooltipPosition:E,disabled:k,required:j,maxHeightList:z=Hu,isVisibleDefaultTitle:U=!0,isScrollableList:q=!1,classNameRoot:G,classNameError:re,classNameLabel:Te}=o,[X,M]=F.useState(!1),w=F.useRef(null);Ia([w],()=>{M(!1)},X);const K=s.find(Oe=>Oe.value===c),te=(Oe,ze)=>{m(Oe,{value:ze,name:d}),M(!1)},be=()=>{k||M(!X)},Le=D({[In.spSelect]:!0,[In.spSelect_error]:!!b,...G&&{[G]:!0}}),Qe=D({[In.spSelect__container]:!0}),ln=D({[In.spSelect__control]:!0,[In.spSelect__control_disabled]:k}),pn=D({[In.spSelect__value]:!0,[In.spSelect__value_empty]:!K}),Ue=D({[In.spSelect__icon]:!0}),W=D({[In.spSelect__list]:!0,[In.spSelect__list_scrollable]:q}),pe=D({...Te&&{[Te]:!0}}),ye=D({[In.spSelect__error]:!0,...re&&{[re]:!0}}),we=()=>x.jsxs("div",{tabIndex:0,title:U?c:void 0,className:ln,onClick:be,ref:w,children:[x.jsx("div",{className:pn,children:(K==null?void 0:K.label)||i}),x.jsx(dn,{name:Ve.SelectChevronDown,rotate:X?180:void 0,className:Ue})]});return x.jsxs("div",{className:Le,children:[A&&x.jsx(Pr,{classNameRoot:pe,tooltipPosition:E,required:j,label:A,infoTooltipText:S}),x.jsxs("div",{className:Qe,onMouseEnter:h,children:[we(),X&&x.jsx("div",{className:W,style:q?{maxHeight:`${z}px`}:{},children:s.map(Oe=>{const ze=Oe.value===c;return x.jsxs("div",{className:D({[In.spSelect__option]:!0}),onClick:L=>te(L,Oe.value),children:[Oe.label,ze&&x.jsx(dn,{name:Ve.Check,className:Ue})]},Oe.value)})})]}),b&&x.jsx("div",{className:ye,children:b})]})};var Fr={exports:{}};/**
24
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function as(o,s){if(o){if(typeof o=="string")return $i(o,s);var i=Object.prototype.toString.call(o).slice(8,-1);if(i==="Object"&&o.constructor&&(i=o.constructor.name),i==="Map"||i==="Set")return Array.from(o);if(i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return $i(o,s)}}function $i(o,s){(s==null||s>o.length)&&(s=o.length);for(var i=0,c=new Array(s);i<s;i++)c[i]=o[i];return c}function ou(o,s){var i=o==null?null:typeof Symbol<"u"&&o[Symbol.iterator]||o["@@iterator"];if(i!=null){var c=[],d=!0,m=!1,h,b;try{for(i=i.call(o);!(d=(h=i.next()).done)&&(c.push(h.value),!(s&&c.length===s));d=!0);}catch(A){m=!0,b=A}finally{try{!d&&i.return!=null&&i.return()}finally{if(m)throw b}}return c}}function au(o){if(Array.isArray(o))return o}function ss(o,s){var i=Object.keys(o);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(o);s&&(c=c.filter(function(d){return Object.getOwnPropertyDescriptor(o,d).enumerable})),i.push.apply(i,c)}return i}function We(o){for(var s=1;s<arguments.length;s++){var i=arguments[s]!=null?arguments[s]:{};s%2?ss(Object(i),!0).forEach(function(c){Hi(o,c,i[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(o,Object.getOwnPropertyDescriptors(i)):ss(Object(i)).forEach(function(c){Object.defineProperty(o,c,Object.getOwnPropertyDescriptor(i,c))})}return o}function Hi(o,s,i){return s in o?Object.defineProperty(o,s,{value:i,enumerable:!0,configurable:!0,writable:!0}):o[s]=i,o}function Or(o,s){if(o==null)return{};var i=su(o,s),c,d;if(Object.getOwnPropertySymbols){var m=Object.getOwnPropertySymbols(o);for(d=0;d<m.length;d++)c=m[d],!(s.indexOf(c)>=0)&&Object.prototype.propertyIsEnumerable.call(o,c)&&(i[c]=o[c])}return i}function su(o,s){if(o==null)return{};var i={},c=Object.keys(o),d,m;for(m=0;m<c.length;m++)d=c[m],!(s.indexOf(d)>=0)&&(i[d]=o[d]);return i}var Dr=F.forwardRef(function(o,s){var i=o.children,c=Or(o,Xc),d=lu(c),m=d.open,h=Or(d,Vc);return F.useImperativeHandle(s,function(){return{open:m}},[m]),F.createElement(F.Fragment,null,i(We(We({},h),{},{open:m})))});Dr.displayName="Dropzone";var ls={disabled:!1,getFilesFromEvent:xc,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};Dr.defaultProps=ls,Dr.propTypes={children:H.func,accept:H.objectOf(H.arrayOf(H.string)),multiple:H.bool,preventDropOnDocument:H.bool,noClick:H.bool,noKeyboard:H.bool,noDrag:H.bool,noDragEventsBubbling:H.bool,minSize:H.number,maxSize:H.number,maxFiles:H.number,disabled:H.bool,getFilesFromEvent:H.func,onFileDialogCancel:H.func,onFileDialogOpen:H.func,useFsAccessApi:H.bool,autoFocus:H.bool,onDragEnter:H.func,onDragLeave:H.func,onDragOver:H.func,onDrop:H.func,onDropAccepted:H.func,onDropRejected:H.func,onError:H.func,validator:H.func};var Ui={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function lu(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},s=We(We({},ls),o),i=s.accept,c=s.disabled,d=s.getFilesFromEvent,m=s.maxSize,h=s.minSize,b=s.multiple,A=s.maxFiles,S=s.onDragEnter,E=s.onDragLeave,k=s.onDragOver,j=s.onDrop,z=s.onDropAccepted,U=s.onDropRejected,q=s.onFileDialogCancel,G=s.onFileDialogOpen,re=s.useFsAccessApi,Te=s.autoFocus,X=s.preventDropOnDocument,M=s.noClick,w=s.noKeyboard,K=s.noDrag,te=s.noDragEventsBubbling,be=s.onError,Le=s.validator,Qe=F.useMemo(function(){return Yc(i)},[i]),ln=F.useMemo(function(){return Gc(i)},[i]),pn=F.useMemo(function(){return typeof G=="function"?G:ps},[G]),Ue=F.useMemo(function(){return typeof q=="function"?q:ps},[q]),W=F.useRef(null),pe=F.useRef(null),ye=F.useReducer(pu,Ui),we=ji(ye,2),Oe=we[0],ze=we[1],L=Oe.isFocused,N=Oe.isFileDialogActive,se=F.useRef(typeof window<"u"&&window.isSecureContext&&re&&Uc()),ce=function(){!se.current&&N&&setTimeout(function(){if(pe.current){var Z=pe.current.files;Z.length||(ze({type:"closeDialog"}),Ue())}},300)};F.useEffect(function(){return window.addEventListener("focus",ce,!1),function(){window.removeEventListener("focus",ce,!1)}},[pe,N,Ue,se]);var ne=F.useRef([]),le=function(Z){W.current&&W.current.contains(Z.target)||(Z.preventDefault(),ne.current=[])};F.useEffect(function(){return X&&(document.addEventListener("dragover",rs,!1),document.addEventListener("drop",le,!1)),function(){X&&(document.removeEventListener("dragover",rs),document.removeEventListener("drop",le))}},[W,X]),F.useEffect(function(){return!c&&Te&&W.current&&W.current.focus(),function(){}},[W,Te,c]);var J=F.useCallback(function(B){be?be(B):console.error(B)},[be]),ue=F.useCallback(function(B){B.preventDefault(),B.persist(),Gn(B),ne.current=[].concat(eu(ne.current),[B.target]),Lr(B)&&Promise.resolve(d(B)).then(function(Z){if(!(Ar(B)&&!te)){var qe=Z.length,Be=qe>0&&qc({files:Z,accept:Qe,minSize:h,maxSize:m,multiple:b,maxFiles:A,validator:Le}),Ge=qe>0&&!Be;ze({isDragAccept:Be,isDragReject:Ge,isDragActive:!0,type:"setDraggedFiles"}),S&&S(B)}}).catch(function(Z){return J(Z)})},[d,S,J,te,Qe,h,m,b,A,Le]),fe=F.useCallback(function(B){B.preventDefault(),B.persist(),Gn(B);var Z=Lr(B);if(Z&&B.dataTransfer)try{B.dataTransfer.dropEffect="copy"}catch{}return Z&&k&&k(B),!1},[k,te]),he=F.useCallback(function(B){B.preventDefault(),B.persist(),Gn(B);var Z=ne.current.filter(function(Be){return W.current&&W.current.contains(Be)}),qe=Z.indexOf(B.target);qe!==-1&&Z.splice(qe,1),ne.current=Z,!(Z.length>0)&&(ze({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),Lr(B)&&E&&E(B))},[W,E,te]),_e=F.useCallback(function(B,Z){var qe=[],Be=[];B.forEach(function(Ge){var Jn=ns(Ge,Qe),Yn=ji(Jn,2),Ct=Yn[0],Tt=Yn[1],kt=ts(Ge,h,m),pt=ji(kt,2),Et=pt[0],It=pt[1],St=Le?Le(Ge):null;if(Ct&&Et&&!St)qe.push(Ge);else{var lr=[Tt,It];St&&(lr=lr.concat(St)),Be.push({file:Ge,errors:lr.filter(function(Xi){return Xi})})}}),(!b&&qe.length>1||b&&A>=1&&qe.length>A)&&(qe.forEach(function(Ge){Be.push({file:Ge,errors:[Rc]})}),qe.splice(0)),ze({acceptedFiles:qe,fileRejections:Be,isDragReject:Be.length>0,type:"setFiles"}),j&&j(qe,Be,Z),Be.length>0&&U&&U(Be,Z),qe.length>0&&z&&z(qe,Z)},[ze,b,Qe,h,m,A,j,z,U,Le]),Fe=F.useCallback(function(B){B.preventDefault(),B.persist(),Gn(B),ne.current=[],Lr(B)&&Promise.resolve(d(B)).then(function(Z){Ar(B)&&!te||_e(Z,B)}).catch(function(Z){return J(Z)}),ze({type:"reset"})},[d,_e,J,te]),O=F.useCallback(function(){if(se.current){ze({type:"openDialog"}),pn();var B={multiple:b,types:ln};window.showOpenFilePicker(B).then(function(Z){return d(Z)}).then(function(Z){_e(Z,null),ze({type:"closeDialog"})}).catch(function(Z){Kc(Z)?(Ue(Z),ze({type:"closeDialog"})):Zc(Z)?(se.current=!1,pe.current?(pe.current.value=null,pe.current.click()):J(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):J(Z)});return}pe.current&&(ze({type:"openDialog"}),pn(),pe.current.value=null,pe.current.click())},[ze,pn,Ue,re,_e,J,ln,b]),tn=F.useCallback(function(B){!W.current||!W.current.isEqualNode(B.target)||(B.key===" "||B.key==="Enter"||B.keyCode===32||B.keyCode===13)&&(B.preventDefault(),O())},[W,O]),Ye=F.useCallback(function(){ze({type:"focus"})},[]),zn=F.useCallback(function(){ze({type:"blur"})},[]),Mr=F.useCallback(function(){M||(Hc()?setTimeout(O,0):O())},[M,O]),rn=function(Z){return c?null:Z},Rt=function(Z){return w?null:rn(Z)},qt=function(Z){return K?null:rn(Z)},Gn=function(Z){te&&Z.stopPropagation()},gn=F.useMemo(function(){return function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=B.refKey,qe=Z===void 0?"ref":Z,Be=B.role,Ge=B.onKeyDown,Jn=B.onFocus,Yn=B.onBlur,Ct=B.onClick,Tt=B.onDragEnter,kt=B.onDragOver,pt=B.onDragLeave,Et=B.onDrop,It=Or(B,Jc);return We(We(Hi({onKeyDown:Rt(Un(Ge,tn)),onFocus:Rt(Un(Jn,Ye)),onBlur:Rt(Un(Yn,zn)),onClick:rn(Un(Ct,Mr)),onDragEnter:qt(Un(Tt,ue)),onDragOver:qt(Un(kt,fe)),onDragLeave:qt(Un(pt,he)),onDrop:qt(Un(Et,Fe)),role:typeof Be=="string"&&Be!==""?Be:"presentation"},qe,W),!c&&!w?{tabIndex:0}:{}),It)}},[W,tn,Ye,zn,Mr,ue,fe,he,Fe,w,K,c]),wt=F.useCallback(function(B){B.stopPropagation()},[]),jt=F.useMemo(function(){return function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=B.refKey,qe=Z===void 0?"ref":Z,Be=B.onChange,Ge=B.onClick,Jn=Or(B,Qc),Yn=Hi({accept:Qe,multiple:b,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:rn(Un(Be,Fe)),onClick:rn(Un(Ge,wt)),tabIndex:-1},qe,pe);return We(We({},Yn),Jn)}},[pe,i,b,Fe,c]);return We(We({},Oe),{},{isFocused:L&&!c,getRootProps:gn,getInputProps:jt,rootRef:W,inputRef:pe,open:rn(O)})}function pu(o,s){switch(s.type){case"focus":return We(We({},o),{},{isFocused:!0});case"blur":return We(We({},o),{},{isFocused:!1});case"openDialog":return We(We({},Ui),{},{isFileDialogActive:!0});case"closeDialog":return We(We({},o),{},{isFileDialogActive:!1});case"setDraggedFiles":return We(We({},o),{},{isDragActive:s.isDragActive,isDragAccept:s.isDragAccept,isDragReject:s.isDragReject});case"setFiles":return We(We({},o),{},{acceptedFiles:s.acceptedFiles,fileRejections:s.fileRejections,isDragReject:s.isDragReject});case"reset":return We({},Ui);default:return o}}function ps(){}const cs=o=>{const{onDropFiles:s,children:i,maxSize:c,accept:d,disabled:m,name:h,multiple:b,maxFiles:A,files:S=[]}=o,E=F.useCallback(k=>{if(!b){s(k,h);return}const j=[...S,...k];if(A&&j.length>A){console.log(`Максимальное возможное количество файлов для загрузки - ${A}`),s(j.slice(0,A),h);return}s(j,h)},[S,A,b,h,s]);return x.jsx(Dr,{multiple:b,onDrop:E,maxSize:c,accept:d,children:({getRootProps:k,getInputProps:j})=>x.jsxs("div",{...k({}),children:[x.jsx("input",{...j({}),disabled:m,name:h}),i]})})},lt={spDropdown:"_spDropdown_lmzju_65",spDropdown__labelText:"_spDropdown__labelText_lmzju_76",spDropdown__tooltipContainer:"_spDropdown__tooltipContainer_lmzju_84",spDropdown__dropdownList:"_spDropdown__dropdownList_lmzju_89",spDropdown__dropdownListHeader:"_spDropdown__dropdownListHeader_lmzju_95",spDropdown__dopdownListItem:"_spDropdown__dopdownListItem_lmzju_102",spDropdown__dopdownListItem_textCenter:"_spDropdown__dopdownListItem_textCenter_lmzju_113",spDropdown__downloadListItemDescription:"_spDropdown__downloadListItemDescription_lmzju_116"},cu=o=>{const{labelText:s="Выпадающий список",listName:i,dropdownList:c=[],dropdownPosition:d=Je.BottomRight,classNameRoot:m}=o,h=D({[lt.spDropdown]:!0,...m&&{[m]:!0}}),b=D({[lt.spDropdown__labelText]:!0}),A=D({[lt.spDropdown__tooltipContainer]:!0}),S=D({[lt.spDropdown__dropdownList]:!0}),E=D({[lt.spDropdown__dropdownListHeader]:!0}),k=D({[lt.spDropdown__downloadListItemDescription]:!0}),[j,z]=F.useState(!1),U=()=>x.jsxs("div",{className:S,children:[i&&x.jsx("div",{className:E,children:i}),c.map((q,G)=>x.jsxs("div",{className:D({[lt.spDropdown__dopdownListItem]:!0,[lt.spDropdown__dopdownListItem_textCenter]:q.textCenter}),onClick:q.onClick,children:[q.name,q.description&&x.jsx("span",{className:k,children:q.description})]},G))]});return x.jsx(kr,{hover:!1,triggerAction:()=>z(!0),actionOnClose:()=>z(!1),text:U(),position:d,noPadding:!0,isToggleClick:!0,trigger:x.jsxs("div",{className:h,children:[x.jsx("div",{className:b,children:s}),x.jsx("div",{className:A,children:x.jsx(dn,{name:Ve.SelectChevronDown,rotate:j?180:void 0})})]})})},us={ellipsisTextWithTooltip:"_ellipsisTextWithTooltip_77a2p_65",ellipsisTextWithTooltip__tooltip:"_ellipsisTextWithTooltip__tooltip_77a2p_68"},uu=o=>{const{text:s,classNameRoot:i,classNameTooltipRoot:c,classNameBaseTooltipContentRoot:d,classNameBaseTooltipRoot:m,...h}=o,b=F.useRef(null),[A,S]=F.useState(!1);F.useEffect(()=>{b.current&&S(b.current.scrollWidth>b.current.clientWidth)},[s]);const E=D({[us.ellipsisTextWithTooltip]:!0,...i&&{[i]:!0}}),k=D({[us.ellipsisTextWithTooltip__tooltip]:!0,...c&&{[c]:!0}});return x.jsx(kr,{classNameTooltip:k,classNameBaseTooltipContentRoot:d,classNameBaseTooltipRoot:m,isVisibleTooltip:A,text:s,trigger:x.jsx(Hn,{...h,classNameRoot:E,isEllipsis:!0,ref:b,children:s})})},sr={spForm:"_spForm_14p1u_65",spForm_fullWidth:"_spForm_fullWidth_14p1u_68",spForm_withSeparator:"_spForm_withSeparator_14p1u_71","spForm_addMargin--size-lg":"_spForm_addMargin--size-lg_14p1u_89","spForm_addMargin--size-md":"_spForm_addMargin--size-md_14p1u_97"},fu=o=>{const{size:s="lg",children:i,onSubmit:c,addMargin:d=!1,withSeparator:m=!1,fullWidth:h=!0,classNameRoot:b,...A}=o,S=D({[sr.spForm]:!0,[sr.spForm_fullWidth]:h,[sr.spForm_addMargin]:d,[sr[`spForm_addMargin--size-${s}`]]:s,[sr.spForm_withSeparator]:m,...b&&{[b]:!0}}),E=k=>{k.preventDefault(),c&&c()};return x.jsx("form",{...A,onSubmit:E,className:S,children:i})},Nr={spLabel:"_spLabel_1drie_65",spLabel__text:"_spLabel__text_1drie_74",spLabel__tooltip:"_spLabel__tooltip_1drie_84",spLabel__required:"_spLabel__required_1drie_89"},Pr=o=>{const{required:s,label:i,infoTooltipText:c,tooltipPosition:d,classNameRoot:m}=o,h=D({[Nr.spLabel]:!0,...m&&{[m]:!0}}),b=D({[Nr.spLabel__text]:!0}),A=D({[Nr.spLabel__required]:s}),S=D({[Nr.spLabel__tooltip]:!0});return x.jsxs("div",{className:h,children:[x.jsx("label",{className:b,children:i}),s&&x.jsx("div",{className:A,children:"*"}),c&&x.jsx("div",{className:S,children:x.jsx(ir,{position:d,text:c})})]})},yt={spInput:"_spInput_1ynu3_65",spInput_error:"_spInput_error_1ynu3_70",spInput__control:"_spInput__control_1ynu3_70",spInput__container:"_spInput__container_1ynu3_77",spInput__control_clearable:"_spInput__control_clearable_1ynu3_97",spInput__clear:"_spInput__clear_1ynu3_117",spInput__error:"_spInput__error_1ynu3_126"},fs=F.forwardRef((o,s)=>{const{value:i,onChange:c,label:d,disabled:m=!1,error:h,required:b,name:A,isClearable:S,pattern:E,onMouseEnter:k,infoTooltipText:j,tooltipPosition:z,isVisibleDefaultTitle:U=!0,placeholder:q="Введите...",classNameRoot:G,classNameError:re,classNameLabel:Te,...X}=o,M=D({[yt.spInput]:!0,[yt.spInput_error]:!!h,...G&&{[G]:!0}}),w=D({[yt.spInput__container]:!0}),K=D({[yt.spInput__control]:!0,[yt.spInput__control_clearable]:S}),te=D({[yt.spInput__clear]:!0}),be=D({[yt.spInput__error]:!0,...re&&{[re]:!0}}),Le=D({...Te&&{[Te]:!0}}),Qe=Ue=>{c(Ue,{name:A,value:""})},ln=Ue=>{const{value:W,name:pe}=Ue.target;E&&W&&!new RegExp(E).test(W)||c(Ue,{value:W,name:pe})},pn=()=>x.jsx("input",{...X,placeholder:q,disabled:m,onChange:ln,title:U?i:void 0,value:i,name:A,className:K,ref:s});return x.jsxs("div",{className:M,children:[d&&x.jsx(Pr,{classNameRoot:Le,tooltipPosition:z,required:b,label:d,infoTooltipText:j}),x.jsxs("div",{className:w,onMouseEnter:k,children:[pn(),S&&i&&!m&&x.jsx(dn,{onClick:Qe,className:te,name:Ve.Trash})]}),h&&x.jsx("div",{className:be,children:h})]})});fs.displayName="Input";const En={spInputFiles:"_spInputFiles_1vz31_65",spInputFiles_error:"_spInputFiles_error_1vz31_70",spInputFiles__control:"_spInputFiles__control_1vz31_70",spInputFiles_fileUploaded:"_spInputFiles_fileUploaded_1vz31_95",spInputFiles_disabled:"_spInputFiles_disabled_1vz31_95",spInputFiles__fileNamesList:"_spInputFiles__fileNamesList_1vz31_105",spInputFiles__fileNamesListItem:"_spInputFiles__fileNamesListItem_1vz31_113",spInputFiles__fileNamesListItemDelete:"_spInputFiles__fileNamesListItemDelete_1vz31_132",spInputFiles__tooltipWrapper:"_spInputFiles__tooltipWrapper_1vz31_147",spInputFiles__tooltip:"_spInputFiles__tooltip_1vz31_147",spInputFiles__delete:"_spInputFiles__delete_1vz31_153",spInputFiles__error:"_spInputFiles__error_1vz31_161"},du=o=>{const{placeholder:s="Загрузите файл",name:i,onDropFiles:c,maxSize:d,accept:m,disabled:h,multiple:b,maxFiles:A,files:S=[],infoTooltipText:E,tooltipPosition:k=Je.TopRight,classNameRoot:j,error:z}=o,U=S.map(w=>w.name),q=(U==null?void 0:U.length)>0,G=D({[En.spInputFiles]:!0,[En.spInputFiles_error]:!!z,[En.spInputFiles_disabled]:h,[En.spInputFiles_fileUploaded]:q,...j&&{[j]:!0}}),re=w=>{const K=[...S],te=K.findIndex(be=>be.name===w);K.splice(te,1),c(K,i)},Te=w=>{w.stopPropagation(),c([],i)},X=()=>b?x.jsx("ul",{className:En.spInputFiles__fileNamesList,children:U.map((w,K)=>x.jsxs("li",{className:En.spInputFiles__fileNamesListItem,onClick:te=>{te.stopPropagation(),re(w)},children:[x.jsx(Hn,{isEllipsis:!0,children:w}),x.jsx("div",{className:En.spInputFiles__fileNamesListItemDelete,children:x.jsx(dn,{name:Ve.Trash})})]},K))}):x.jsx(Hn,{isEllipsis:!0,children:U[0]}),M=()=>x.jsxs(x.Fragment,{children:[q?X():x.jsx(Hn,{children:s}),q?x.jsx("div",{className:En.spInputFiles__delete,onClick:Te,children:x.jsx(dn,{name:Ve.Close})}):E&&x.jsx(ir,{classNameTooltip:En.spInputFiles__tooltipWrapper,position:k,text:E,classNameTriggerTooltip:En.spInputFiles__tooltip})]});return x.jsx(cs,{name:i,files:S,multiple:b,maxSize:d,maxFiles:A,accept:m,onDropFiles:c,disabled:h||q,children:x.jsxs("div",{className:G,children:[x.jsxs("div",{className:En.spInputFiles__control,children:[x.jsx(dn,{name:q?Ve.Check:Ve.Upload}),M()]}),z&&x.jsx("div",{className:En.spInputFiles__error,children:z})]})})},Gi=F.createContext({device:{isDesktop:!1,isMobile:!1,isTablet:!1}});var Yi={};Yi.match=xu,Yi.parse=ds;var mu=/(?:(only|not)?\s*([^\s\(\)]+)(?:\s*and)?\s*)?(.+)?/i,_u=/\(\s*([^\s\:\)]+)\s*(?:\:\s*([^\s\)]+))?\s*\)/,vu=/^(?:(min|max)-)?(.+)/,hu=/(em|rem|px|cm|mm|in|pt|pc)?$/,gu=/(dpi|dpcm|dppx)?$/;function xu(o,s){return ds(o).some(function(i){var c=i.inverse,d=i.type==="all"||s.type===i.type;if(d&&c||!(d||c))return!1;var m=i.expressions.every(function(h){var b=h.feature,A=h.modifier,S=h.value,E=s[b];if(!E)return!1;switch(b){case"orientation":case"scan":return E.toLowerCase()===S.toLowerCase();case"width":case"height":case"device-width":case"device-height":S=vs(S),E=vs(E);break;case"resolution":S=_s(S),E=_s(E);break;case"aspect-ratio":case"device-aspect-ratio":case"device-pixel-ratio":S=ms(S),E=ms(E);break;case"grid":case"color":case"color-index":case"monochrome":S=parseInt(S,10)||1,E=parseInt(E,10)||0;break}switch(A){case"min":return E>=S;case"max":return E<=S;default:return E===S}});return m&&!c||!m&&c})}function ds(o){return o.split(",").map(function(s){s=s.trim();var i=s.match(mu),c=i[1],d=i[2],m=i[3]||"",h={};return h.inverse=!!c&&c.toLowerCase()==="not",h.type=d?d.toLowerCase():"all",m=m.match(/\([^\)]+\)/g)||[],h.expressions=m.map(function(b){var A=b.match(_u),S=A[1].toLowerCase().match(vu);return{modifier:S[1],feature:S[2],value:A[2]}}),h})}function ms(o){var s=Number(o),i;return s||(i=o.match(/^(\d+)\s*\/\s*(\d+)$/),s=i[1]/i[2]),s}function _s(o){var s=parseFloat(o),i=String(o).match(gu)[1];switch(i){case"dpcm":return s/2.54;case"dppx":return s*96;default:return s}}function vs(o){var s=parseFloat(o),i=String(o).match(hu)[1];switch(i){case"em":return s*16;case"rem":return s*16;case"cm":return s*96/2.54;case"mm":return s*96/2.54/10;case"in":return s*96;case"pt":return s*72;case"pc":return s*72/12;default:return s}}var bu=Yi.match,hs=typeof window<"u"?window.matchMedia:null;function yu(o,s,i){var c=this,d;hs&&!i&&(d=hs.call(window,o)),d?(this.matches=d.matches,this.media=d.media,d.addListener(b)):(this.matches=bu(o,s),this.media=o),this.addListener=m,this.removeListener=h,this.dispose=A;function m(S){d&&d.addListener(S)}function h(S){d&&d.removeListener(S)}function b(S){c.matches=S.matches,c.media=S.media}function A(){d&&d.removeListener(b)}}function wu(o,s,i){return new yu(o,s,i)}var Cu=wu;const Tu=Oa(Cu);var ku=/[A-Z]/g,Eu=/^ms-/,Ki={};function Iu(o){return"-"+o.toLowerCase()}function gs(o){if(Ki.hasOwnProperty(o))return Ki[o];var s=o.replace(ku,Iu);return Ki[o]=Eu.test(s)?"-"+s:s}function Su(o,s){if(o===s)return!0;if(!o||!s)return!1;const i=Object.keys(o),c=Object.keys(s),d=i.length;if(c.length!==d)return!1;for(let m=0;m<d;m++){const h=i[m];if(o[h]!==s[h]||!Object.prototype.hasOwnProperty.call(s,h))return!1}return!0}const sn=H.oneOfType([H.string,H.number]),xs={all:H.bool,grid:H.bool,aural:H.bool,braille:H.bool,handheld:H.bool,print:H.bool,projection:H.bool,screen:H.bool,tty:H.bool,tv:H.bool,embossed:H.bool},Au={orientation:H.oneOf(["portrait","landscape"]),scan:H.oneOf(["progressive","interlace"]),aspectRatio:H.string,deviceAspectRatio:H.string,height:sn,deviceHeight:sn,width:sn,deviceWidth:sn,color:H.bool,colorIndex:H.bool,monochrome:H.bool,resolution:sn,type:Object.keys(xs)},{type:v1,...Lu}=Au,Ou={minAspectRatio:H.string,maxAspectRatio:H.string,minDeviceAspectRatio:H.string,maxDeviceAspectRatio:H.string,minHeight:sn,maxHeight:sn,minDeviceHeight:sn,maxDeviceHeight:sn,minWidth:sn,maxWidth:sn,minDeviceWidth:sn,maxDeviceWidth:sn,minColor:H.number,maxColor:H.number,minColorIndex:H.number,maxColorIndex:H.number,minMonochrome:H.number,maxMonochrome:H.number,minResolution:sn,maxResolution:sn,...Lu};var Du={all:{...xs,...Ou}};const Nu=o=>`not ${o}`,Pu=(o,s)=>{const i=gs(o);return typeof s=="number"&&(s=`${s}px`),s===!0?i:s===!1?Nu(i):`(${i}: ${s})`},Fu=o=>o.join(" and "),Bu=o=>{const s=[];return Object.keys(Du.all).forEach(i=>{const c=o[i];c!=null&&s.push(Pu(i,c))}),Fu(s)},Mu=F.createContext(void 0),Wu=o=>o.query||Bu(o),bs=o=>o?Object.keys(o).reduce((i,c)=>(i[gs(c)]=o[c],i),{}):void 0,ys=()=>{const o=F.useRef(!1);return F.useEffect(()=>{o.current=!0},[]),o.current},zu=o=>{const s=F.useContext(Mu),i=()=>bs(o)||bs(s),[c,d]=F.useState(i);return F.useEffect(()=>{const m=i();Su(c,m)||d(m)},[o,s]),c},Ru=o=>{const s=()=>Wu(o),[i,c]=F.useState(s);return F.useEffect(()=>{const d=s();i!==d&&c(d)},[o]),i},qu=(o,s)=>{const i=()=>Tu(o,s||{},!!s),[c,d]=F.useState(i),m=ys();return F.useEffect(()=>{if(m){const h=i();return d(h),()=>{h&&h.dispose()}}},[o,s]),c},ju=o=>{const[s,i]=F.useState(o.matches);return F.useEffect(()=>{const c=d=>{i(d.matches)};return o.addListener(c),i(o.matches),()=>{o.removeListener(c)}},[o]),s},Zi=(o,s,i)=>{const c=zu(s),d=Ru(o);if(!d)throw new Error("Invalid or missing MediaQuery!");const m=qu(d,c),h=ju(m);return ys(),F.useEffect(()=>{},[h]),F.useEffect(()=>()=>{m&&m.dispose()},[]),h},ws=o=>{const{desktop:s,tablet:i,mobile:c}=o,d=Zi(s),m=Zi(i),h=Zi(c);return{device:{isDesktop:d,isTablet:m,isMobile:h}}},$u=o=>{const{breakpoints:s,children:i}=o,{device:c}=ws(s);return x.jsx(Gi.Provider,{value:{device:c},children:i})},Hu=180,In={spSelect:"_spSelect_5qv4w_65",spSelect_error:"_spSelect_error_5qv4w_70",spSelect__control:"_spSelect__control_5qv4w_70",spSelect__value_empty:"_spSelect__value_empty_5qv4w_74",spSelect__icon:"_spSelect__icon_5qv4w_77",spSelect__container:"_spSelect__container_5qv4w_80",spSelect__control_disabled:"_spSelect__control_disabled_5qv4w_115",spSelect__value:"_spSelect__value_5qv4w_74",spSelect__list:"_spSelect__list_5qv4w_148",spSelect__list_scrollable:"_spSelect__list_scrollable_5qv4w_155",spSelect__option:"_spSelect__option_5qv4w_158",spSelect__error:"_spSelect__error_5qv4w_176"},Uu=o=>{const{options:s,placeholder:i="Выберите из списка...",value:c,name:d,onChange:m,onMouseEnter:h,error:b,label:A,infoTooltipText:S,tooltipPosition:E,disabled:k,required:j,maxHeightList:z=Hu,isVisibleDefaultTitle:U=!0,isScrollableList:q=!1,classNameRoot:G,classNameError:re,classNameLabel:Te}=o,[X,M]=F.useState(!1),w=F.useRef(null);Ia([w],()=>{M(!1)},X);const K=s.find(Oe=>Oe.value===c),te=(Oe,ze)=>{m(Oe,{value:ze,name:d}),M(!1)},be=()=>{k||M(!X)},Le=D({[In.spSelect]:!0,[In.spSelect_error]:!!b,...G&&{[G]:!0}}),Qe=D({[In.spSelect__container]:!0}),ln=D({[In.spSelect__control]:!0,[In.spSelect__control_disabled]:k}),pn=D({[In.spSelect__value]:!0,[In.spSelect__value_empty]:!K}),Ue=D({[In.spSelect__icon]:!0}),W=D({[In.spSelect__list]:!0,[In.spSelect__list_scrollable]:q}),pe=D({...Te&&{[Te]:!0}}),ye=D({[In.spSelect__error]:!0,...re&&{[re]:!0}}),we=()=>x.jsxs("div",{tabIndex:0,title:U?c:void 0,className:ln,onClick:be,children:[x.jsx("div",{className:pn,children:(K==null?void 0:K.label)||i}),x.jsx(dn,{name:Ve.SelectChevronDown,rotate:X?180:void 0,className:Ue})]});return x.jsxs("div",{className:Le,ref:w,children:[A&&x.jsx(Pr,{classNameRoot:pe,tooltipPosition:E,required:j,label:A,infoTooltipText:S}),x.jsxs("div",{className:Qe,onMouseEnter:h,children:[we(),X&&x.jsx("div",{className:W,style:q?{maxHeight:`${z}px`}:{},children:s.map(Oe=>{const ze=Oe.value===c;return x.jsxs("div",{className:D({[In.spSelect__option]:!0}),onClick:L=>te(L,Oe.value),children:[Oe.label,ze&&x.jsx(dn,{name:Ve.Check,className:Ue})]},Oe.value)})})]}),b&&x.jsx("div",{className:ye,children:b})]})};var Fr={exports:{}};/**
25
25
  * @license
26
26
  * Lodash <https://lodash.com/>
27
27
  * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "UI-kit package",
4
4
  "author": "Mochalov Ivan",
5
5
  "license": "MIT",
6
- "version": "0.3.0",
6
+ "version": "0.3.1",
7
7
  "type": "module",
8
8
  "files": [
9
9
  "dist"