@elcrm/form 0.0.62 → 0.0.64
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.
- package/README.md +113 -0
- package/dist/Form.d.ts +20 -0
- package/dist/Form.js +11 -0
- package/dist/FormInitContext.d.ts +25 -0
- package/dist/FormInitContext.js +20 -0
- package/dist/assets/styles/Field.module.css +1 -0
- package/dist/assets/styles/Form.module.css +1 -0
- package/dist/assets/styles/Select.module.css +1 -0
- package/dist/core/Field.d.ts +18 -0
- package/dist/core/Field.js +33 -0
- package/dist/events/onEvent.d.ts +55 -0
- package/dist/events/onEvent.js +67 -0
- package/dist/{src/lib/fields → fields}/Date.d.ts +7 -3
- package/dist/fields/Date.js +345 -0
- package/dist/{src/lib/fields → fields}/Input.d.ts +2 -2
- package/dist/fields/Input.js +55 -0
- package/dist/fields/Mask.d.ts +9 -0
- package/dist/fields/Mask.js +95 -0
- package/dist/fields/Modal.d.ts +25 -0
- package/dist/fields/Modal.js +55 -0
- package/dist/fields/Money.d.ts +35 -0
- package/dist/fields/Money.js +93 -0
- package/dist/fields/Numeric.d.ts +9 -0
- package/dist/fields/Numeric.js +69 -0
- package/dist/fields/Options.d.ts +30 -0
- package/dist/fields/Options.js +63 -0
- package/dist/fields/Password.d.ts +6 -0
- package/dist/fields/Password.js +100 -0
- package/dist/{src/lib/fields → fields}/Phone.d.ts +5 -1
- package/dist/fields/Phone.js +109 -0
- package/dist/fields/Range.d.ts +16 -0
- package/dist/fields/Range.js +101 -0
- package/dist/fields/Select.d.ts +21 -0
- package/dist/fields/Select.js +143 -0
- package/dist/{src/lib/fields → fields}/Textarea.d.ts +5 -1
- package/dist/fields/Textarea.js +47 -0
- package/dist/fields/Time.d.ts +26 -0
- package/dist/fields/Time.js +252 -0
- package/dist/fields/type.d.ts +42 -0
- package/dist/hooks/use.d.ts +42 -0
- package/dist/hooks/use.js +57 -0
- package/dist/index.d.ts +26 -2
- package/dist/index.js +26 -0
- package/dist/index.umd.js +2 -89
- package/dist/mask/MaskPhone.d.ts +8 -0
- package/dist/mask/MaskPhone.js +1384 -0
- package/dist/package.js +96 -0
- package/dist/style.css +5 -0
- package/dist/styles/Field.module.js +22 -0
- package/dist/styles/Form.module.js +12 -0
- package/dist/styles/Select.module.js +8 -0
- package/package.json +72 -11
- package/src/lib/styles/Field.module.scss +315 -0
- package/src/lib/styles/Form.module.scss +313 -0
- package/src/lib/styles/Select.module.scss +90 -0
- package/src/lib/styles/dark.css +47 -0
- package/src/lib/styles/light.css +51 -0
- package/dist/index.css +0 -1
- package/dist/index.es.js +0 -5045
- package/dist/src/lib/Captcha.d.ts +0 -1
- package/dist/src/lib/Check.d.ts +0 -13
- package/dist/src/lib/Code.d.ts +0 -22
- package/dist/src/lib/Color.d.ts +0 -22
- package/dist/src/lib/Field.d.ts +0 -13
- package/dist/src/lib/Files.d.ts +0 -20
- package/dist/src/lib/Generator.d.ts +0 -1
- package/dist/src/lib/Group.d.ts +0 -21
- package/dist/src/lib/Image.d.ts +0 -22
- package/dist/src/lib/Init.d.ts +0 -1
- package/dist/src/lib/MaskPhone.d.ts +0 -2
- package/dist/src/lib/Message.d.ts +0 -15
- package/dist/src/lib/Money.d.ts +0 -22
- package/dist/src/lib/Month.d.ts +0 -18
- package/dist/src/lib/Palette.d.ts +0 -9
- package/dist/src/lib/Progress.d.ts +0 -9
- package/dist/src/lib/Toogle.d.ts +0 -8
- package/dist/src/lib/Users.d.ts +0 -1
- package/dist/src/lib/_Time.d.ts +0 -0
- package/dist/src/lib/fields/Mask.d.ts +0 -19
- package/dist/src/lib/fields/Modal.d.ts +0 -19
- package/dist/src/lib/fields/Numeric.d.ts +0 -6
- package/dist/src/lib/fields/Options.d.ts +0 -22
- package/dist/src/lib/fields/Password.d.ts +0 -23
- package/dist/src/lib/fields/Select copy.d.ts +0 -23
- package/dist/src/lib/fields/Select.d.ts +0 -28
- package/dist/src/lib/fields/type.d.ts +0 -30
- package/dist/src/lib/index.d.ts +0 -16
- package/dist/src/lib/onEvent.d.ts +0 -2
- package/dist/src/lib/use.d.ts +0 -10
package/dist/index.umd.js
CHANGED
|
@@ -1,89 +1,2 @@
|
|
|
1
|
-
(function(H,j){typeof exports=="object"&&typeof module<"u"?j(exports,require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","react-dom"],j):(H=typeof globalThis<"u"?globalThis:H||self,j((H.elCRM=H.elCRM||{},H.elCRM.form={}),H.React,H.ReactDOM))})(this,function(H,j,Et){"use strict";var Mt=document.createElement("style");Mt.textContent=`@charset "UTF-8";._o_1c9e1_1{position:fixed;z-index:98;top:0;left:0;right:0;bottom:0;background:#0000}._c_1c9e1_11{box-shadow:5px 7px 18px #000000a8;padding:10px;margin:0;display:block;position:absolute;background:var(--select-background);z-index:99;border-radius:10px;overflow:hidden;max-height:315px;color:#fff}._c_1c9e1_11 [grid-calendar]{display:grid;grid-template-columns:35px 35px 35px 35px 35px 35px 35px}._c_1c9e1_11 [grid-month]{display:grid;grid-template-columns:1fr 1fr 1fr 1fr;width:250px}._c_1c9e1_11 b{font-weight:400;display:block;padding:8px 5px;border-radius:5px;cursor:pointer;text-align:center}._c_1c9e1_11 b.__active_1c9e1_41{background:var(--bg-select-active)}._c_1c9e1_11 b:hover{background:var(--bg-select-hover)}._c_1c9e1_11 p{color:var(--color-placeholder);text-align:center;padding:0;cursor:default;pointer-events:none}._c_1c9e1_11 i{flex:0 30px;padding:9px;text-align:center;cursor:pointer;border-radius:5px}._c_1c9e1_11 i:hover{background:var(--bg-select-hover)}._c_1c9e1_11 i:before{cursor:pointer;display:block}._c_1c9e1_11 s{display:flex;font-style:normal;text-decoration:none;padding-bottom:5px;align-items:center}._c_1c9e1_11 s h2{flex:1 1;padding:0;margin:0;font-size:18px;text-align:center;font-weight:400;line-height:35px;color:#fff;cursor:default}._c_1c9e1_11 span{padding:2px;text-align:center}._c_1c9e1_11 span p{padding:8px 5px;color:var(--color-placeholder)}._c_1c9e1_11 ._as_1c9e1_94{cursor:ns-resize}._c_1c9e1_11 ._ap_1c9e1_97{cursor:pointer}[field=password] dd{white-space:nowrap;font-style:unset;-webkit-text-security:disc;user-select:none;-webkit-user-select:text}[field=password][show] dd{-webkit-text-security:none}[field=password] dd:before{-webkit-text-security:none}[field=code] div{display:flex;gap:8px}[field=select] dd{cursor:pointer}[field] dd:before{pointer-events:none}[field=check] dd{max-width:35px;padding:0;cursor:pointer}[field=check] [active]:after{content:"";background:#394264;width:15px;height:15px;display:block;border-radius:5px}[field=file] input{display:none}[field=file] dd{aspect-ratio:16/9;position:relative;cursor:pointer}[field=file] img{aspect-ratio:16/9;display:block;width:-webkit-fill-available;object-fit:contain;cursor:pointer}[field=file] label{aspect-ratio:16/9;display:block;width:-webkit-fill-available;object-fit:contain;position:absolute;cursor:pointer}[field=color] dd{display:flex;border:0;padding:0;gap:3px}[field=color] dd s{border:1px solid #dde2e4;border-radius:6px;flex:1;cursor:pointer;opacity:.6}[field=color] dd s:hover{opacity:.9}[field=color] dd s[active=true]{opacity:1}._l_r5ldz_1{display:flex;flex-direction:column;position:relative;min-width:var(--field-width)}._l_r5ldz_1[data-field=group] div{cursor:pointer;border-bottom:var(--field-border);margin:0;padding:var(--field-padding)}._l_r5ldz_1[data-field=group] div:last-child{border-bottom:0}._l_r5ldz_1 [placeholder]:empty:before{content:attr(placeholder);display:block;color:var(--field-placeholder)}._l_r5ldz_1 [placeholder]:focus:before{display:none}._f_r5ldz_25{box-sizing:border-box;display:flex;border:var(--field-border);border-radius:var(--field-radius);background:var(--field-background);color:var(--field-color);padding:0}._f_r5ldz_25>div{outline:0;flex:1;margin:var(--field-padding);min-height:var(--field-height);line-height:var(--field-height);text-wrap:pretty}._n_r5ldz_43 div{min-height:var(--field-note-height);line-height:var(--field-note-line-height);padding-top:var(--field-note-padding-top)}._w_r5ldz_49>div{text-wrap:nowrap;overflow:hidden;overflow-x:scroll}._w_r5ldz_49>div::-webkit-scrollbar{width:0;height:0}._t_r5ldz_59{color:var(--field-label-color);font-size:var(--field-label-size);padding-bottom:8px}._g_r5ldz_65{flex-direction:column}._h_r5ldz_69{--field-border: 0}._h_r5ldz_69 div{border:var(--field-check-box-border, --field-border);width:var(--field-height);height:var(--field-height);border-radius:var(--field-radius);background:var(--field-background);margin:0;flex:none;cursor:pointer;position:relative;gap:10px}._h_r5ldz_69 div[aria-checked=true]{background:var(--field-background-active)}._h_r5ldz_69 div:after{content:"";width:9px;height:5px;position:absolute;top:5px;left:4px;border:3px solid #fcfff4;border-top:none;border-right:none;background:transparent;transform:rotate(-45deg);margin:4px}._e_r5ldz_102{border-color:var(--field-error-border);background:var(--field-error-background);color:var(--field-error-color)}._n_1ery1_2{position:absolute;inset:var(--notice-inset);font-family:var(--notice-family);z-index:1111}._n_1ery1_2 ._e_1ery1_8{color:var(--notice-error, #bb2014)}._n_1ery1_2 ._s_1ery1_11{color:var(--notice-success, #367738)}._n_1ery1_2 ._r_1ery1_14{color:var(--notice-remark, #b77513)}._n_1ery1_2 ._с_1ery1_17{color:var(--notice-copy, #3f51b5)}._n_1ery1_2 li{-webkit-backdrop-filter:var(--notice-filter, blur(5px));backdrop-filter:var(--notice-filter, blur(5px));display:block;width:var(--notice-width, 300px);height:var(--notice-height, 70px);border-radius:var(--notice-radius, 5px);box-shadow:0 0 0 1px var(--notice-border),0 2px 2px #00000008,0 4px 4px #0000000a,0 10px 8px #0000000d,0 15px 15px #0000000f,0 30px 30px #00000012,0 70px 65px #00000017;background:var(--notice-background);overflow:hidden;cursor:pointer;margin:10px 0;transition:all 3s ease 0s;opacity:0}._n_1ery1_2 svg{float:left;width:50px;height:50px;margin:10px;font-size:40px;line-height:51px;text-align:center}._n_1ery1_2 b{width:222px;font-size:17px;font-weight:700;position:absolute;left:70px;display:block;margin-top:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._n_1ery1_2 p{color:var(--notice-color);font-size:14px;width:222px;position:absolute;left:70px;display:block;margin-top:37px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._n_1ery1_2 [data-status=show]{opacity:1;transition:1s;animation:_show-notice_1ery1_1 1s 1;animation-fill-mode:forwards}._n_1ery1_2 [data-status=hide]{opacity:1;transition:1s;animation:_hide-notice_1ery1_1 1s 1;animation-fill-mode:forwards}@keyframes _show-notice_1ery1_1{0%{opacity:0}to{opacity:1}}@keyframes _hide-notice_1ery1_1{0%{opacity:1}to{opacity:0}}:root{--primary-light: #8abdff;--primary: #6d5dfc;--primary-dark: #5b0eeb;--white: #fff;--greyLight-1: #e4ebf5;--greyLight-2: #abb6d2;--greyLight-3: #bec8e4;--greyDark: #9baacf;--inset: inset 2px 2px 2px var(--shadow), inset -1px -1px 1px var(--shade);--modal-radius: 10px}[shake=true]{-webkit-animation-name:_shake_oqfdb_1;animation-name:_shake_oqfdb_1;-webkit-animation-duration:1s;animation-duration:1s;-webkit-animation-fill-mode:both;animation-fill-mode:both}@keyframes _shake_oqfdb_1{0%,to{transform:translateZ(0)}10%,30%,50%,70%,90%{transform:translate3d(-10px,0,0)}20%,40%,60%,80%{transform:translate3d(10px,0,0)}}._modal_oqfdb_79{position:fixed;top:0;left:0;right:0;bottom:0;z-index:10;display:flex}._modal_oqfdb_79 ._sa_oqfdb_89{width:auto;margin:auto 20px}._modal_oqfdb_79 ._ss_oqfdb_94{width:400px}._modal_oqfdb_79 ._sm_oqfdb_98{width:500px}._modal_oqfdb_79 ._sl_oqfdb_102{width:800px}._modal_oqfdb_79 ._sx_oqfdb_106{width:1000px}._modal_oqfdb_79 ._sf_oqfdb_110{width:100%;max-width:1200px;min-width:910px}._o_oqfdb_116{position:fixed;top:0;left:0;right:0;bottom:0;background-color:var(--modal-background-overflow, rgba(0, 0, 0, .7215686275))}._b_oqfdb_28{padding:15px 30px 30px;margin:auto}._w_oqfdb_15{box-shadow:5px 7px 18px 0 var(--modal-background-overflow, rgba(0, 0, 0, .7215686275));background-image:var(--modal-background-image);background-color:var(--modal-background-color);border-radius:var(--modal-radius);position:relative;min-width:300px;margin:auto;border-radius:10px;width:400px;max-height:90%;display:flex;flex-flow:column nowrap;overflow:hidden}._h_oqfdb_146{flex:1;font-size:15px;line-height:35px;font-weight:700;text-align:left;color:var(--modal-color);padding:10px 15px 5px 30px;user-select:none;-webkit-user-select:none;display:flex;z-index:1}._l_oqfdb_160{border-radius:10px;font-size:15px;box-shadow:var(--inset);color:var(--modal-color);margin:10px;overflow:hidden;overflow-y:scroll;padding:5px 0}._l_oqfdb_160 li{display:flex;margin:0 5px;padding:10px;position:relative}._l_oqfdb_160 li:after{content:"";border-bottom:1px solid #ddd;position:absolute;bottom:0;left:5px;right:5px}._l_oqfdb_160 li:last-child{border-bottom:0}._l_oqfdb_160 li:hover{background:#00000012;cursor:pointer;border-radius:5px}._t_oqfdb_197{padding-right:10px}._x_oqfdb_201{cursor:pointer;color:var(--modal-exit);opacity:.5;display:flex}._x_oqfdb_201 svg{width:20px}._x_oqfdb_201:hover{opacity:1}._s_oqfdb_89{flex:1;overflow-y:scroll}._c_oqfdb_219{text-align:center;margin:20px}._f_oqfdb_224{display:flex;padding:15px 30px 30px}._f_oqfdb_224 p{margin:auto;width:300px;padding:20px 0 5px;color:#1f253dc7;font-size:15px}._f_oqfdb_224._r__oqfdb_235{flex-direction:row}._f_oqfdb_224._r__oqfdb_235 dl{margin:7px 0;flex:1 1;flex-direction:row;display:flex}._f_oqfdb_224._r__oqfdb_235 dt{padding:7px 10px;color:var(--text);margin-left:7px;flex:0 1 150px}._f_oqfdb_224._c__oqfdb_250{flex-direction:column;gap:15px}._f_oqfdb_224._c__oqfdb_250 dt{padding-bottom:8px;margin-left:7px}._g_oqfdb_259{display:flex;gap:10px;overflow:hidden}._c_oqfdb_219{margin:10px 7px 20px;opacity:.8;box-shadow:var(--outset);border-radius:10px;padding:20px;flex:1;text-align:center;cursor:pointer}._c_oqfdb_219:first-child{margin-left:20px}._c_oqfdb_219:last-child{margin-right:20px}._c_oqfdb_219:hover{opacity:1;background:var(--tinge)}._c_oqfdb_219 i{font-size:70px;margin-bottom:20px;text-align:center;display:block;color:var(--disabled)}._c_oqfdb_219 b{text-align:center;display:block;color:var(--color)}._c_oqfdb_219 p{text-align:center;font-size:15px;color:var(--text)}._m_oqfdb_79{flex:1}._btn_1k1b3_1{opacity:.7;padding:7px 25px;border-radius:5px;box-shadow:var(--outset);display:flex;justify-content:center;cursor:pointer;transition:.3s ease}._btn_1k1b3_1:hover{opacity:1}._confirm_1k1b3_15{background:var(--button-confirm-bg, #4caf50);color:var(--button-confirm-color, #fff)}._cancel_1k1b3_20{background:var(--button-cancel-bg, #f44336);color:var(--button-cancel-color, #fff)}._action_1k1b3_25{background:var(--button-action-bg, #4094f7);color:var(--button-action-color, #fff)}._disabled_1k1b3_30{background:var(--button-disabled-bg, #efefef);color:var(--button-disabled-color, #000);opacity:1;cursor:default}._await_1k1b3_37{background:var(--button-await-bg, #efefef);color:var(--button-await-color, #000);opacity:1;cursor:default}._m_1k1b3_44{min-width:200px}._l_1k1b3_48{flex:1}:root{--select-overlay: #0000;--select-height: 35px;--select-separator: 1px solid #999;--select-color: #fff;--select-background: #28292d;--select-icon: calc(--select-height / 1.5);--select-icon-padding: calc((--select-height - --select-icon)/2) ;--select-font-size: 13px}._o_1wehm_12{position:fixed;z-index:98;top:0;left:0;right:0;bottom:0;background:var(--select-overlay)}._l_1wehm_22{padding:0;margin:0;display:block;position:absolute;background:var(--select-background);z-index:99;border-radius:10px;overflow:scroll;max-height:300px}._l_1wehm_22::-webkit-scrollbar{width:0;height:0}._l_1wehm_22 ul{overflow-y:auto;width:100%;max-height:300px;display:block;overflow-x:hidden}._l_1wehm_22 li{border-bottom:var(--select-separator);cursor:pointer;display:block;padding:0 15px;color:var(--select-color);border-left:0!important;text-align:left!important;height:var(--select-height);line-height:var(--select-height);font-size:var(--select-font-size);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;opacity:.9}._l_1wehm_22 li:hover{opacity:1}._l_1wehm_22 li:last-child{border-bottom:0}._i_1wehm_72{position:absolute;width:var(--select-icon);height:var(--select-icon);color:var(--field-color);right:var(--select-icon-padding);top:var(--select-icon-padding)}._f_1wehm_81{cursor:pointer}
|
|
2
|
-
/*$vite$:1*/`,document.head.appendChild(Mt);const Gt={version:"0.0.62"};var St={exports:{}},Ue={};/**
|
|
3
|
-
* @license React
|
|
4
|
-
* react-jsx-runtime.production.min.js
|
|
5
|
-
*
|
|
6
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
7
|
-
*
|
|
8
|
-
* This source code is licensed under the MIT license found in the
|
|
9
|
-
* LICENSE file in the root directory of this source tree.
|
|
10
|
-
*/var It;function $t(){if(It)return Ue;It=1;var a=j,_=Symbol.for("react.element"),i=Symbol.for("react.fragment"),s=Object.prototype.hasOwnProperty,f=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,h={key:!0,ref:!0,__self:!0,__source:!0};function C(v,c,y){var n,l={},k=null,E=null;y!==void 0&&(k=""+y),c.key!==void 0&&(k=""+c.key),c.ref!==void 0&&(E=c.ref);for(n in c)s.call(c,n)&&!h.hasOwnProperty(n)&&(l[n]=c[n]);if(v&&v.defaultProps)for(n in c=v.defaultProps,c)l[n]===void 0&&(l[n]=c[n]);return{$$typeof:_,type:v,key:k,ref:E,props:l,_owner:f.current}}return Ue.Fragment=i,Ue.jsx=C,Ue.jsxs=C,Ue}var Ke={};/**
|
|
11
|
-
* @license React
|
|
12
|
-
* react-jsx-runtime.development.js
|
|
13
|
-
*
|
|
14
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
15
|
-
*
|
|
16
|
-
* This source code is licensed under the MIT license found in the
|
|
17
|
-
* LICENSE file in the root directory of this source tree.
|
|
18
|
-
*/var At;function Yt(){return At||(At=1,process.env.NODE_ENV!=="production"&&function(){var a=j,_=Symbol.for("react.element"),i=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),f=Symbol.for("react.strict_mode"),h=Symbol.for("react.profiler"),C=Symbol.for("react.provider"),v=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),n=Symbol.for("react.suspense_list"),l=Symbol.for("react.memo"),k=Symbol.for("react.lazy"),E=Symbol.for("react.offscreen"),I=Symbol.iterator,U="@@iterator";function P(e){if(e===null||typeof e!="object")return null;var t=I&&e[I]||e[U];return typeof t=="function"?t:null}var T=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function p(e){{for(var t=arguments.length,r=new Array(t>1?t-1:0),o=1;o<t;o++)r[o-1]=arguments[o];N("error",e,r)}}function N(e,t,r){{var o=T.ReactDebugCurrentFrame,b=o.getStackAddendum();b!==""&&(t+="%s",r=r.concat([b]));var x=r.map(function(m){return String(m)});x.unshift("Warning: "+t),Function.prototype.apply.call(console[e],console,x)}}var K=!1,A=!1,O=!1,q=!1,L=!1,F;F=Symbol.for("react.module.reference");function S(e){return!!(typeof e=="string"||typeof e=="function"||e===s||e===h||L||e===f||e===y||e===n||q||e===E||K||A||O||typeof e=="object"&&e!==null&&(e.$$typeof===k||e.$$typeof===l||e.$$typeof===C||e.$$typeof===v||e.$$typeof===c||e.$$typeof===F||e.getModuleId!==void 0))}function B(e,t,r){var o=e.displayName;if(o)return o;var b=t.displayName||t.name||"";return b!==""?r+"("+b+")":r}function g(e){return e.displayName||"Context"}function w(e){if(e==null)return null;if(typeof e.tag=="number"&&p("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case s:return"Fragment";case i:return"Portal";case h:return"Profiler";case f:return"StrictMode";case y:return"Suspense";case n:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case v:var t=e;return g(t)+".Consumer";case C:var r=e;return g(r._context)+".Provider";case c:return B(e,e.render,"ForwardRef");case l:var o=e.displayName||null;return o!==null?o:w(e.type)||"Memo";case k:{var b=e,x=b._payload,m=b._init;try{return w(m(x))}catch{return null}}}return null}var M=Object.assign,$=0,te,J,ce,ue,xe,we,Ce;function je(){}je.__reactDisabledLog=!0;function He(){{if($===0){te=console.log,J=console.info,ce=console.warn,ue=console.error,xe=console.group,we=console.groupCollapsed,Ce=console.groupEnd;var e={configurable:!0,enumerable:!0,value:je,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}$++}}function Je(){{if($--,$===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:M({},e,{value:te}),info:M({},e,{value:J}),warn:M({},e,{value:ce}),error:M({},e,{value:ue}),group:M({},e,{value:xe}),groupCollapsed:M({},e,{value:we}),groupEnd:M({},e,{value:Ce})})}$<0&&p("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var fe=T.ReactCurrentDispatcher,pe;function ne(e,t,r){{if(pe===void 0)try{throw Error()}catch(b){var o=b.stack.trim().match(/\n( *(at )?)/);pe=o&&o[1]||""}return`
|
|
19
|
-
`+pe+e}}var me=!1,oe;{var Ve=typeof WeakMap=="function"?WeakMap:Map;oe=new Ve}function Ee(e,t){if(!e||me)return"";{var r=oe.get(e);if(r!==void 0)return r}var o;me=!0;var b=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var x;x=fe.current,fe.current=null,He();try{if(t){var m=function(){throw Error()};if(Object.defineProperty(m.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(m,[])}catch(W){o=W}Reflect.construct(e,[],m)}else{try{m.call()}catch(W){o=W}e.call(m.prototype)}}else{try{throw Error()}catch(W){o=W}e()}}catch(W){if(W&&o&&typeof W.stack=="string"){for(var d=W.stack.split(`
|
|
20
|
-
`),z=o.stack.split(`
|
|
21
|
-
`),R=d.length-1,D=z.length-1;R>=1&&D>=0&&d[R]!==z[D];)D--;for(;R>=1&&D>=0;R--,D--)if(d[R]!==z[D]){if(R!==1||D!==1)do if(R--,D--,D<0||d[R]!==z[D]){var G=`
|
|
22
|
-
`+d[R].replace(" at new "," at ");return e.displayName&&G.includes("<anonymous>")&&(G=G.replace("<anonymous>",e.displayName)),typeof e=="function"&&oe.set(e,G),G}while(R>=1&&D>=0);break}}}finally{me=!1,fe.current=x,Je(),Error.prepareStackTrace=b}var Q=e?e.displayName||e.name:"",V=Q?ne(Q):"";return typeof e=="function"&&oe.set(e,V),V}function Ze(e,t,r){return Ee(e,!1)}function Xe(e){var t=e.prototype;return!!(t&&t.isReactComponent)}function _e(e,t,r){if(e==null)return"";if(typeof e=="function")return Ee(e,Xe(e));if(typeof e=="string")return ne(e);switch(e){case y:return ne("Suspense");case n:return ne("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case c:return Ze(e.render);case l:return _e(e.type,t,r);case k:{var o=e,b=o._payload,x=o._init;try{return _e(x(b),t,r)}catch{}}}return""}var re=Object.prototype.hasOwnProperty,Se={},Re=T.ReactDebugCurrentFrame;function ie(e){if(e){var t=e._owner,r=_e(e.type,e._source,t?t.type:null);Re.setExtraStackFrame(r)}else Re.setExtraStackFrame(null)}function Qe(e,t,r,o,b){{var x=Function.call.bind(re);for(var m in e)if(x(e,m)){var d=void 0;try{if(typeof e[m]!="function"){var z=Error((o||"React class")+": "+r+" type `"+m+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[m]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw z.name="Invariant Violation",z}d=e[m](t,m,o,r,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(R){d=R}d&&!(d instanceof Error)&&(ie(b),p("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",o||"React class",r,m,typeof d),ie(null)),d instanceof Error&&!(d.message in Se)&&(Se[d.message]=!0,ie(b),p("Failed %s type: %s",r,d.message),ie(null))}}}var et=Array.isArray;function ye(e){return et(e)}function tt(e){{var t=typeof Symbol=="function"&&Symbol.toStringTag,r=t&&e[Symbol.toStringTag]||e.constructor.name||"Object";return r}}function rt(e){try{return Te(e),!1}catch{return!0}}function Te(e){return""+e}function Oe(e){if(rt(e))return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",tt(e)),Te(e)}var De=T.ReactCurrentOwner,at={key:!0,ref:!0,__self:!0,__source:!0},Pe,Ne;function nt(e){if(re.call(e,"ref")){var t=Object.getOwnPropertyDescriptor(e,"ref").get;if(t&&t.isReactWarning)return!1}return e.ref!==void 0}function ot(e){if(re.call(e,"key")){var t=Object.getOwnPropertyDescriptor(e,"key").get;if(t&&t.isReactWarning)return!1}return e.key!==void 0}function _t(e,t){typeof e.ref=="string"&&De.current}function it(e,t){{var r=function(){Pe||(Pe=!0,p("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"key",{get:r,configurable:!0})}}function lt(e,t){{var r=function(){Ne||(Ne=!0,p("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"ref",{get:r,configurable:!0})}}var ct=function(e,t,r,o,b,x,m){var d={$$typeof:_,type:e,key:t,ref:r,props:m,_owner:x};return d._store={},Object.defineProperty(d._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(d,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(d,"_source",{configurable:!1,enumerable:!1,writable:!1,value:b}),Object.freeze&&(Object.freeze(d.props),Object.freeze(d)),d};function st(e,t,r,o,b){{var x,m={},d=null,z=null;r!==void 0&&(Oe(r),d=""+r),ot(t)&&(Oe(t.key),d=""+t.key),nt(t)&&(z=t.ref,_t(t,b));for(x in t)re.call(t,x)&&!at.hasOwnProperty(x)&&(m[x]=t[x]);if(e&&e.defaultProps){var R=e.defaultProps;for(x in R)m[x]===void 0&&(m[x]=R[x])}if(d||z){var D=typeof e=="function"?e.displayName||e.name||"Unknown":e;d&&it(m,D),z&<(m,D)}return ct(e,d,z,b,o,De.current,m)}}var ge=T.ReactCurrentOwner,Fe=T.ReactDebugCurrentFrame;function X(e){if(e){var t=e._owner,r=_e(e.type,e._source,t?t.type:null);Fe.setExtraStackFrame(r)}else Fe.setExtraStackFrame(null)}var be;be=!1;function he(e){return typeof e=="object"&&e!==null&&e.$$typeof===_}function Me(){{if(ge.current){var e=w(ge.current.type);if(e)return`
|
|
23
|
-
|
|
24
|
-
Check the render method of \``+e+"`."}return""}}function dt(e){return""}var Ie={};function ut(e){{var t=Me();if(!t){var r=typeof e=="string"?e:e.displayName||e.name;r&&(t=`
|
|
25
|
-
|
|
26
|
-
Check the top-level render call using <`+r+">.")}return t}}function Ae(e,t){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var r=ut(t);if(Ie[r])return;Ie[r]=!0;var o="";e&&e._owner&&e._owner!==ge.current&&(o=" It was passed a child from "+w(e._owner.type)+"."),X(e),p('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',r,o),X(null)}}function qe(e,t){{if(typeof e!="object")return;if(ye(e))for(var r=0;r<e.length;r++){var o=e[r];he(o)&&Ae(o,t)}else if(he(e))e._store&&(e._store.validated=!0);else if(e){var b=P(e);if(typeof b=="function"&&b!==e.entries)for(var x=b.call(e),m;!(m=x.next()).done;)he(m.value)&&Ae(m.value,t)}}}function ft(e){{var t=e.type;if(t==null||typeof t=="string")return;var r;if(typeof t=="function")r=t.propTypes;else if(typeof t=="object"&&(t.$$typeof===c||t.$$typeof===l))r=t.propTypes;else return;if(r){var o=w(t);Qe(r,e.props,"prop",o,e)}else if(t.PropTypes!==void 0&&!be){be=!0;var b=w(t);p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",b||"Unknown")}typeof t.getDefaultProps=="function"&&!t.getDefaultProps.isReactClassApproved&&p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pt(e){{for(var t=Object.keys(e.props),r=0;r<t.length;r++){var o=t[r];if(o!=="children"&&o!=="key"){X(e),p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",o),X(null);break}}e.ref!==null&&(X(e),p("Invalid attribute `ref` supplied to `React.Fragment`."),X(null))}}var Be={};function ze(e,t,r,o,b,x){{var m=S(e);if(!m){var d="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(d+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var z=dt();z?d+=z:d+=Me();var R;e===null?R="null":ye(e)?R="array":e!==void 0&&e.$$typeof===_?(R="<"+(w(e.type)||"Unknown")+" />",d=" Did you accidentally export a JSX literal instead of a component?"):R=typeof e,p("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",R,d)}var D=st(e,t,r,b,x);if(D==null)return D;if(m){var G=t.children;if(G!==void 0)if(o)if(ye(G)){for(var Q=0;Q<G.length;Q++)qe(G[Q],e);Object.freeze&&Object.freeze(G)}else p("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else qe(G,e)}if(re.call(t,"key")){var V=w(e),W=Object.keys(t).filter(function(vt){return vt!=="key"}),ve=W.length>0?"{key: someKey, "+W.join(": ..., ")+": ...}":"{key: someKey}";if(!Be[V+ve]){var ht=W.length>0?"{"+W.join(": ..., ")+": ...}":"{}";p(`A props object containing a "key" prop is being spread into JSX:
|
|
27
|
-
let props = %s;
|
|
28
|
-
<%s {...props} />
|
|
29
|
-
React keys must be passed directly to JSX without using spread:
|
|
30
|
-
let props = %s;
|
|
31
|
-
<%s key={someKey} {...props} />`,ve,V,ht,V),Be[V+ve]=!0}}return e===s?pt(D):ft(D),D}}function mt(e,t,r){return ze(e,t,r,!0)}function yt(e,t,r){return ze(e,t,r,!1)}var gt=yt,bt=mt;Ke.Fragment=s,Ke.jsx=gt,Ke.jsxs=bt}()),Ke}process.env.NODE_ENV==="production"?St.exports=$t():St.exports=Yt();var u=St.exports;function Ht({name:a,value:_,title:i,style:s,className:f}){let h={field:"progress"};return s&&(h.style=s),f&&(h.className=f),u.jsxs("dl",{...h,children:[i&&u.jsx("dt",{children:i}),u.jsx("dd",{})]})}const kt={o:"_o_1c9e1_1",c:"_c_1c9e1_11"},ee={l:"_l_r5ldz_1",f:"_f_r5ldz_25",n:"_n_r5ldz_43",w:"_w_r5ldz_49",t:"_t_r5ldz_59",g:"_g_r5ldz_65",h:"_h_r5ldz_69",e:"_e_r5ldz_102"},se=j.forwardRef(({element_blok:a,element_input:_,type:i="input",title:s,error:f,before:h,after:C,children:v},c)=>u.jsxs("dl",{"data-field":i,className:[ee.l,...a.className].filter(y=>y!==void 0).join(" "),children:[s?u.jsx("dt",{className:ee.t,children:s}):"",h,u.jsx("dd",{ref:c,className:[ee.f,..._.className,f&&f.length>0?ee.e:""].join(" "),..._.props,children:v}),C]}));function Jt({value:a,onValue:_,name:i,error:s,icon:f,edit:h=!0,active:C=!0,title:v,placeholder:c="",className:y}){let[n,l]=j.useState(a);const k=j.useRef(null),[E,I]=j.useState(!1);j.useEffect(()=>{l(a)},[a]);let U=p=>{l(p),_&&_({value:p,name:i})},P=p=>{if(!h||!C)return;const N=p.target.getBoundingClientRect(),K=N.left,A=N.top;k.position={x:K,y:A},I(!0)};const T={};return c&&(T.placeholder=c),f||u.jsxs(u.Fragment,{children:[u.jsx(se,{type:"date",title:v,element_blok:{className:[y]},element_input:{className:[ee.w]},children:u.jsx("div",{onClick:P,...T,children:Zt(n,"mm.yyyy")})}),E&&Et.createPortal(u.jsx(Vt,{position:k.position,onValue:U,date:n,onOpen:I},new Date().getTime()),document.body)]})}const Vt=({onOpen:a,date:_,onValue:i,position:s})=>{let f=new Date,h=new Date(_),C={y:parseInt(f.getFullYear()),m:parseInt(f.getMonth())+1},v={y:parseInt(h.getFullYear()),m:parseInt(h.getMonth())+1},[c,y]=j.useState(v.y),n=()=>{a(!1)},l=()=>{y(c+1)},k=()=>{y(c-1)},E=p=>{i(c+"-"+Xt(2,p)),n()},I=p=>C.y===v.y&&C.m===p?"_FFEB3B":"",U=Array(12).fill("").map((p,N)=>N+1),P=window.innerHeight-s.y+33<320?s.y-312:s.y+33,T=window.innerWidth-s.x<265?s.x-235:s.x;return u.jsxs(u.Fragment,{children:[u.jsx("div",{className:kt.o,onClick:n}),u.jsxs("div",{className:kt.c,style:{top:P+"px",left:T+"px"},children:[u.jsxs("s",{children:[u.jsx("i",{onClick:k,children:u.jsx("svg",{width:"16",height:"16",fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"m15.09 4.594-7.646 6.553a1.126 1.126 0 0 0 0 1.708l7.647 6.552c.73.625 1.857.107 1.857-.854V5.447c0-.961-1.127-1.48-1.857-.853Z"})})}),u.jsx("h2",{children:c}),u.jsx("i",{onClick:l,children:u.jsx("svg",{width:"16",height:"16",fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"m8.91 19.406 7.646-6.552a1.125 1.125 0 0 0 0-1.709L8.91 4.593c-.73-.625-1.857-.107-1.857.854v13.107c0 .96 1.127 1.479 1.857.852Z"})})})]}),u.jsx("div",{"grid-month":"",children:U.map((p,N)=>u.jsx("span",{onClick:()=>{E(p)},color:I(p),children:u.jsx("b",{children:Qt(p).abc})},N))})]})]})};function Zt(a,_){_===void 0?(_=a,a=new Date):a=new Date(a);let i={yyyy:a.getFullYear(),yy:(""+a.getFullYear()).slice(-2),mm:("0"+(a.getMonth()+1)).slice(-2),dd:("0"+a.getDate()).slice(-2),HH:("0"+a.getHours()).slice(-2),MM:("0"+a.getMinutes()).slice(-2),SS:("0"+a.getSeconds()).slice(-2),__:" ",_:" "};for(const s in i)_=_.replace(s,i[s]);return _}function Xt(a,_){let i=_+"";for(;i.length<a;)i="0"+i;return i}function Qt(a){return a=typeof a=="number"?a:new Date(a).getMonth()+1,{1:{val:"01",name:"Январь",names:"Января",abc:"Янв"},2:{val:"02",name:"Февраль",names:"Февраля",abc:"Февр"},3:{val:"03",name:"Март",names:"Марта",abc:"Март"},4:{val:"04",name:"Апрель",names:"Апреля",abc:"Апр"},5:{val:"05",name:"Май",names:"Мая",abc:"Май"},6:{val:"06",name:"Июнь",names:"Июня",abc:"Июнь"},7:{val:"07",name:"Июль",names:"Июля",abc:"Июль"},8:{val:"08",name:"Август",names:"Августа",abc:"Авг"},9:{val:"09",name:"Сентябрь",names:"Сентября",abc:"Сент"},10:{val:"10",name:"Октябрь",names:"Октября",abc:"Окт"},11:{val:"11",name:"Ноябрь",names:"Ноября",abc:"Нояб"},12:{val:"12",name:"Декабрь",names:"Декабря",abc:"Дек"}}[a]}let Z={};Z.KeyDown=a=>{a.key==="Enter"&&a.preventDefault()},Z.PasteOne=a=>{a.preventDefault(),navigator.clipboard.readText().then(_=>{_=_.replace(/^\s*/,"").replace(/\s*$/,""),window.document.execCommand("insertText",!1,_)}).catch(_=>{})},Z.Paste=(a,_)=>{_.preventDefault(),navigator.clipboard.readText().then(i=>{if(a){let s=_.target.textContent.length;if(s>=a)return;a-=s,i=i.slice(0,a)}window.document.execCommand("insertText",!1,i.replace(/(\r\n|\n|\r)/gm," "))}).catch(i=>{})},Z.Focus=a=>{a.target.textContent.length===0&&(a.target.innerHTML="<br>")},Z.Blur=a=>{a.target.scrollLeft=0,a.target.querySelector("br")!==null&&a.target.querySelector("br").remove()},Z.ContentEditable="plaintext-only";function er({value:a,onValue:_,name:i,placeholder:s="",title:f="",error:h="",hide:C=!1,edit:v=!0,active:c=!0,after:y="",show:n=!0,course:l=100,view:k,type:E,onSave:I,className:U="",isClear:P=!1}){let T=!!(C&&(a===""||a===void 0)),p=S=>E==="multi"?S.replace(/[^+\d.+-]/g,""):S.replace(/[^+\d.]/g,""),N=(S,B)=>{let g=document.createRange(),w=window.getSelection();g.setStart(B.childNodes[0],S),g.collapse(!0),w.removeAllRanges(),w.addRange(g),B.focus()},K=S=>{_==null||_({value:p(S.target.textContent)*l,name:i}),S.target.textContent=p(S.target.textContent),S.target.textContent.length>0&&N(S.target.textContent.length,S.target)},A=S=>{Z.Blur(S),S.target.textContent===""&&(S.target.textContent=0),I==null||I({value:p(S.target.textContent)*l,name:i}),_==null||_({value:p(S.target.textContent)*l,name:i}),S.target.textContent=qt(S.target.textContent)},O=S=>{S.target.textContent=p(S.target.textContent)},q=S=>{S.key==="Enter"&&S.preventDefault()},L=S=>{S.preventDefault(),navigator.clipboard.readText().then(B=>{B=B.replace(/^\s*/,"").replace(/\s*$/,""),window.document.execCommand("insertText",!1,B)}).catch(B=>{})};if(!(v&&c)&&!n||!(v&&c)&&T)return"";const F={};return F.inputMode="decimal",s&&(F.placeholder=s),v&&c&&(F.edit=""),u.jsx(se,{type:"input",title:f,element_blok:{className:[U]},element_input:{className:[ee.w]},children:u.jsx("div",{...F,onInput:K,onPaste:L,onBlur:A,onKeyDown:q,onFocus:O,contentEditable:v&&c?Z.ContentEditable:"false",suppressContentEditableWarning:!0,"data-after":y,children:!s||a?qt(a):""})})}function qt(a,_){return parseFloat(a).toFixed(2).replace(/(\d)(?=(\d{3})+\.)/g,"$1 ")}function tr({value:a="",onValue:_,onSave:i,name:s,format:f="+_(___) ___-__-__",placeholder:h="",title:C="",error:v="",hide:c=!1,edit:y=!0,active:n=!0,after:l="",show:k=!0,view:E,className:I=""}){y=y!==void 0?y:!0,n=n!==void 0?n:!0,c=!!(c&&(a===""||a===void 0))&&!(y&&n),j.useRef(null);let P=f,T=!0,p=0,N=(B,g)=>{let w=document.createRange(),M=window.getSelection();w.setStart(g.childNodes[0],B),w.collapse(!0),M.removeAllRanges(),M.addRange(w),g.focus()},K=B=>{B.preventDefault(),navigator.clipboard.readText().then(g=>{window.document.execCommand("insertText",!1,g)}).catch(g=>{})},A=B=>{let g=0,w="",M=B.replace(/\D/g,"");M===""&&(T=!0);let $=M.split(""),te="";$.forEach(ue=>{T&&(te+=ue,T&&(p=(""+te).length,P=f.replace(new RegExp("[0-9]","g"),"_"),w=""),p>(""+te).length&&(T=!0,P=f.replace(new RegExp("[0-9]","g"),"_"),w=""))});let J=P.replace(/\D/g,"");return J.length>=M.length&&(M=J),{q:P.replace(/[_\d]/g,function(){return M.charAt(g++)||"_"}),i:g,v:M,f:w}},O=A(a),q=B=>{let g=A(B.target.textContent);B.target.textContent=g.q,g.i=g.q.lastIndexOf(g.v.substr(-1)),g.i<g.q.length&&g.q!==P?g.i++:g.i=g.q.indexOf("_"),N(g.i,B.target),_&&_({value:g.q.replace(/\D/g,""),name:s})},L=B=>{B.key==="Enter"&&B.preventDefault()};const F=B=>{Z.Blur(B),i&&i({value:B.target.textContent.replace(/\D/g,""),name:s})};let S={};return y&&n?(S.edit="true",S.contentEditable=Z.ContentEditable):S.contentEditable="false",h&&(S.placeholder=h),l&&(S.after=l),c?u.jsx(u.Fragment,{}):u.jsx(se,{type:"input",title:C,element_blok:{className:[I]},element_input:{className:[ee.w]},children:u.jsx("div",{onPaste:K,onInput:q,onKeyDown:L,onBlur:F,suppressContentEditableWarning:!0,...S,children:O.q})})}function rr({title:a,error:_,edit:i=!0,active:s=!0,className:f,placeholder:h,max:C,min:v,onValue:c,icon:y,name:n="",value:l,after:k}){let[E,I]=j.useState(l===void 0?new Date:l);const U=j.useRef(null),[P,T]=j.useState(!1);let p=!i&&s;j.useEffect(()=>{I(l===void 0?new Date:l)},[l]);let N=O=>{I(O),c==null||c({value:O,name:n})},K=O=>{const q=O.target.getBoundingClientRect(),L=q.left,F=q.bottom,S=q.top;U.position={x:L,b:F,y:S},T(!0)};const A={};return h&&(A.placeholder=h),p?u.jsx(u.Fragment,{}):u.jsxs(u.Fragment,{children:[y?y():u.jsxs("dl",{"data-field":"date",className:[ee.l,f].filter(O=>O!==void 0).join(" "),children:[a?u.jsx("dt",{className:ee.t,children:a}):"",u.jsxs("dd",{onClick:K,className:[ee.f,ee.w].join(" "),...A,"data-edit":(i&&s)+"",children:[or(E,"dd.mm.yyyy"),k]}),_&&u.jsx("em",{children:_})]}),P&&Et.createPortal(u.jsx(ar,{position:U.position,onValue:N,date:E,max:C,min:v,onOpen:T,className:f},new Date().getTime()),document.body)]})}const ar=({date:a,onValue:_,position:i,max:s,min:f,className:h,onOpen:C})=>{let v=new Date,c=new Date(a),y={y:parseInt(v.getFullYear()),d:parseInt(v.getDate()),m:parseInt(v.getMonth())+1},n={y:parseInt(c.getFullYear()),d:parseInt(c.getDate()),m:parseInt(c.getMonth())+1},[l,k]=j.useState({y:n.y,m:n.m}),E=g=>{let w=g.getDay();return w===0&&(w=7),w-1},I=["пн","вт","ср","чт","пт","сб","вс"],U=l.m-1,P=new Date(l.y,U),T=[];for(let g=0;g<E(P);g++)T.push(0);for(;P.getMonth()===U;)T.push(P.getDate()),P.setDate(P.getDate()+1);let p=()=>{C(!1)},N=()=>{O(l.m+1,l.y)},K=()=>{O(l.m-1,l.y)},A=g=>{_(l.y+"-"+Bt(2,l.m)+"-"+Bt(2,g)),p()},O=(g,w)=>{w=g>12?w+1:g<1?w-1:w,g=g>12?1:g<1?12:g,k({y:w,m:g})};const q=g=>y.y===l.y&&y.m===l.m&&y.d===g?{"data-active":"true"}:{},L=g=>n.y===l.y&&n.m===l.m&&n.d===g?{"data-current":"true"}:{},F=g=>{let w=!0;if(s){let M=s.getTime(),$=new Date(l.y,l.m-1,g).getTime();M<$&&(w=!1)}if(f){let M=f.getTime(),$=new Date(l.y,l.m-1,g).getTime();M>$&&(w=!1)}return w};let S=window.innerHeight-i.y<320?i.y-312:i.b,B=window.innerWidth-i.x<265?i.x-235:i.x;return u.jsxs(u.Fragment,{children:[u.jsx("div",{className:kt.o,onClick:()=>p()}),u.jsxs("div",{className:[kt.c,h&&h+"-backdrop"].join(" "),style:{top:S+"px",left:B+"px"},children:[u.jsxs("s",{children:[u.jsx("i",{onClick:K,children:u.jsx("svg",{width:"16",height:"16",fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"m15.09 4.594-7.646 6.553a1.126 1.126 0 0 0 0 1.708l7.647 6.552c.73.625 1.857.107 1.857-.854V5.447c0-.961-1.127-1.48-1.857-.853Z"})})}),u.jsxs("h2",{children:[nr(l.m).name," ",l.y]}),u.jsx("i",{onClick:N,children:u.jsx("svg",{width:"16",height:"16",fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"m8.91 19.406 7.646-6.552a1.125 1.125 0 0 0 0-1.709L8.91 4.593c-.73-.625-1.857-.107-1.857.854v13.107c0 .96 1.127 1.479 1.857.852Z"})})})]}),u.jsxs("div",{"grid-calendar":"",children:[I.map((g,w)=>u.jsx("p",{children:g},"v"+w)),T.map((g,w)=>u.jsx("span",{children:g!==0&&F(g)?u.jsx("b",{...q(g),...L(g),onClick:()=>A(g),children:g}):u.jsx("p",{...q(g),...L(g),children:g!==0?g:""})},w))]})]})]})};function nr(a){return a=typeof a=="number"?a:new Date(a).getMonth()+1,{1:{val:"01",name:"Январь",names:"Января",abc:"Янв"},2:{val:"02",name:"Февраль",names:"Февраля",abc:"Февр"},3:{val:"03",name:"Март",names:"Марта",abc:"Март"},4:{val:"04",name:"Апрель",names:"Апреля",abc:"Апр"},5:{val:"05",name:"Май",names:"Мая",abc:"Май"},6:{val:"06",name:"Июнь",names:"Июня",abc:"Июнь"},7:{val:"07",name:"Июль",names:"Июля",abc:"Июль"},8:{val:"08",name:"Август",names:"Августа",abc:"Авг"},9:{val:"09",name:"Сентябрь",names:"Сентября",abc:"Сент"},10:{val:"10",name:"Октябрь",names:"Октября",abc:"Окт"},11:{val:"11",name:"Ноябрь",names:"Ноября",abc:"Нояб"},12:{val:"12",name:"Декабрь",names:"Декабря",abc:"Дек"}}[a]}function Bt(a,_){let i=_+"";for(;i.length<a;)i="0"+i;return i}function or(a,_){_===void 0?(_=a,a=new Date):a=new Date(a);let i={yyyy:a.getFullYear(),yy:(""+a.getFullYear()).slice(-2),mm:("0"+(a.getMonth()+1)).slice(-2),dd:("0"+a.getDate()).slice(-2),HH:("0"+a.getHours()).slice(-2),MM:("0"+a.getMinutes()).slice(-2),SS:("0"+a.getSeconds()).slice(-2),__:" ",_:" "};for(const s in i)_=_.replace(s,i[s]);return _}function _r({value:a,onValue:_,name:i,placeholder:s="",title:f="",label:h="",hide:C=!1,edit:v=!0,active:c=!0,after:y="",show:n=!0,maxLength:l,error:k="",onSave:E,className:I="",isCopy:U=!0}){const P=A=>{_==null||_({value:A.target.innerText,name:i||""})},T=A=>{l&&A.target.textContent.trim().length>=l&&A.key!=="Backspace"&&A.preventDefault(),A.key==="Enter"&&A.preventDefault()},p=A=>{A.preventDefault(),navigator.clipboard.readText().then(O=>{if(l){let q=A.target.textContent.length;if(q>=l)return;l-=q,O=O.slice(0,l)}window.document.execCommand("insertText",!1,O.replace(/(\r\n|\n|\r)/gm," "))}).catch(O=>{})};if(C)return u.jsx(u.Fragment,{});if(!(v&&c)&&!n)return"";const N={};s&&(N.placeholder=s),v&&c&&(N.edit="");const K=A=>{Z.Blur(A),E==null||E({value:A.target.textContent.trim(),name:i||""})};return u.jsx(se,{type:"note",title:f||h,error:k,element_blok:{className:[I]},element_input:{className:[ee.n]},children:u.jsx("div",{onPaste:p,onInput:P,onBlur:K,onKeyDown:T,contentEditable:v&&c?Z.ContentEditable:"false",suppressContentEditableWarning:!0,...N,children:a})})}const Rt={0:{name:"Heard Island and Mcdonald Islands",dial_code:"+0",code:"HM",mask:"+0(___) ___-__-__"},1:{name:"United States",dial_code:"+1",code:"US",mask:"+1(___) ___-__-__"},7:{name:"Russia",dial_code:"+7",code:"RU",mask:"+7(___) ___-__-__"},20:{name:"Egypt",dial_code:"+20",code:"EG",mask:"+20(___) ___-__-__"},27:{name:"South Africa",dial_code:"+27",code:"ZA",mask:"+27(___) __-__-__"},30:{name:"Greece",dial_code:"+30",code:"GR",mask:"+30(___) ___-__-__"},31:{name:"Netherlands",dial_code:"+31",code:"NL",mask:"+31(___) __-__-__"},32:{name:"Belgium",dial_code:"+32",code:"BE",mask:"+32(___) __-__-__"},33:{name:"France",dial_code:"+33",code:"FR",mask:"+33(___) __-__-__"},34:{name:"Spain",dial_code:"+34",code:"ES",mask:"+34(___) __-__-__"},36:{name:"Hungary",dial_code:"+36",code:"HU",mask:"+36(___) __-__-__"},39:{name:"Italy",dial_code:"+39",code:"IT",mask:"+39(___) ___-__-__"},40:{name:"Romania",dial_code:"+40",code:"RO",mask:"+40(___) __-__-__"},41:{name:"Switzerland",dial_code:"+41",code:"CH",mask:"+41(___) __-__-__"},43:{name:"Austria",dial_code:"+43",code:"AT",mask:"+43(__) ___-__-__"},44:{name:"United Kingdom",dial_code:"+44",code:"GB",mask:"+44(___) ___-__-__"},45:{name:"Denmark",dial_code:"+45",code:"DK",mask:"+45(__) __-__-__"},46:{name:"Sweden",dial_code:"+46",code:"SE",mask:"+46(___) __-__-__"},47:{name:"Svalbard and Jan Mayen",dial_code:"+47",code:"SJ",mask:"+47(__) __-__-__"},48:{name:"Poland",dial_code:"+48",code:"PL",mask:"+48(__) __-__-__"},49:{name:"Germany",dial_code:"+49",code:"DE",mask:"+49(___) ___-__-__"},51:{name:"Peru",dial_code:"+51",code:"PE",mask:"+51(___) __-__-__"},52:{name:"Mexico",dial_code:"+52",code:"MX",mask:"+52(__-__) ___-__-__"},53:{name:"Cuba",dial_code:"+53",code:"CU",mask:"+53(__) __-__-__"},54:{name:"Argentina",dial_code:"+54",code:"AR",mask:"+54(__-__) ___-__-__"},55:{name:"Brazil",dial_code:"+55",code:"BR",mask:"+55(___) ___-__-__"},56:{name:"Chile",dial_code:"+56",code:"CL",mask:"+56(___) __-__-__"},57:{name:"Colombia",dial_code:"+57",code:"CO",mask:"+57(___) ___-__-__"},58:{name:"Venezuela, Bolivarian Republic of Venezuela",dial_code:"+58",code:"VE",mask:"+58(___) ___-__-__"},60:{name:"Malaysia",dial_code:"+60",code:"MY",mask:"+60(___) __-__-__"},61:{name:"Cocos (Keeling) Islands",dial_code:"+61",code:"CC",mask:"+61(___) ___-__-__"},62:{name:"Indonesia",dial_code:"+62",code:"ID",mask:"+62(___) __-__-__"},63:{name:"Philippines",dial_code:"+63",code:"PH",mask:"+63(___) ___-__-__"},64:{name:"Pitcairn",dial_code:"+64",code:"PN",mask:"+64(___) __-__-__"},65:{name:"Singapore",dial_code:"+65",code:"SG",mask:"+65(__) __-__-__"},66:{name:"Thailand",dial_code:"+66",code:"TH",mask:"+66(___) __-__-__"},77:{name:"Kazakhstan",dial_code:"+77",code:"KZ",mask:"+77(__) ___-__-__"},81:{name:"Japan",dial_code:"+81",code:"JP",mask:"+81(___) ___-__-__"},82:{name:"Korea, Republic of South Korea",dial_code:"+82",code:"KR",mask:"+82(___) ___-__-__"},84:{name:"Vietnam",dial_code:"+84",code:"VN",mask:"+84(___) __-__-__"},86:{name:"China",dial_code:"+86",code:"CN",mask:"+86(__-__) ___-__-__"},90:{name:"Turkey",dial_code:"+90",code:"TR",mask:"+90(___) ___-__-__"},91:{name:"India",dial_code:"+91",code:"IN",mask:"+91(___) ___-__-__"},92:{name:"Pakistan",dial_code:"+92",code:"PK",mask:"+92(___) ___-__-__"},93:{name:"Afghanistan",dial_code:"+93",code:"AF",mask:"+93(__) ___-__-__"},94:{name:"Sri Lanka",dial_code:"+94",code:"LK",mask:"+94(___) __-__-__"},95:{name:"Myanmar",dial_code:"+95",code:"MM",mask:"+95(___) ___-__-__"},98:{name:"Iran, Islamic Republic of Persian Gulf",dial_code:"+98",code:"IR",mask:"+98(___) ___-__-__"},211:{name:"South Sudan",dial_code:"+211",code:"SS",mask:"+211(___) ___-__-__"},212:{name:"Morocco",dial_code:"+212",code:"MA",mask:"+212(___) __-__-__"},213:{name:"Algeria",dial_code:"+213",code:"DZ",mask:"+213(__) ___-__-__"},216:{name:"Tunisia",dial_code:"+216",code:"TN",mask:"+216(__) __-__-__"},218:{name:"Libyan Arab Jamahiriya",dial_code:"+218",code:"LY",mask:"+218(___) ___-__-__"},220:{name:"Gambia",dial_code:"+220",code:"GM",mask:"+220(___) __-__"},221:{name:"Senegal",dial_code:"+221",code:"SN",mask:"+221(___) __-__-__"},222:{name:"Mauritania",dial_code:"+222",code:"MR",mask:"+222(__) __-__-__"},223:{name:"Mali",dial_code:"+223",code:"ML",mask:"+223(__) __-__-__"},224:{name:"Guinea",dial_code:"+224",code:"GN",mask:"+224(__) __-__-__"},225:{name:"Cote d'Ivoire",dial_code:"+225",code:"CI",mask:"+225(__) __-__-__"},226:{name:"Burkina Faso",dial_code:"+226",code:"BF",mask:"+226(__) __-__-__"},227:{name:"Niger",dial_code:"+227",code:"NE",mask:"+227(__) __-__-__"},228:{name:"Togo",dial_code:"+228",code:"TG",mask:"+228(__) __-__-__"},229:{name:"Benin",dial_code:"+229",code:"BJ",mask:"+229(__) __-__-__"},230:{name:"Mauritius",dial_code:"+230",code:"MU",mask:"+230(___) __-__"},231:{name:"Liberia",dial_code:"+231",code:"LR",mask:"+231(___) __-__"},232:{name:"Sierra Leone",dial_code:"+232",code:"SL",mask:"+232(__) __-__-__"},233:{name:"Ghana",dial_code:"+233",code:"GH",mask:"+233(___) __-__-__"},234:{name:"Nigeria",dial_code:"+234",code:"NG",mask:"+234(___) ___-__-__"},235:{name:"Chad",dial_code:"+235",code:"TD",mask:"+235(__) __-__-__"},236:{name:"Central African Republic",dial_code:"+236",code:"CF",mask:"+236(__) __-__-__"},237:{name:"Cameroon",dial_code:"+237",code:"CM",mask:"+237(__) __-__-__"},238:{name:"Cape Verde",dial_code:"+238",code:"CV",mask:"+238(___) __-__"},239:{name:"Sao Tome and Principe",dial_code:"+239",code:"ST",mask:"+239(___) ___-__-__"},240:{name:"Equatorial Guinea",dial_code:"+240",code:"GQ",mask:"+240(___) __-__-__"},241:{name:"Gabon",dial_code:"+241",code:"GA",mask:"+241(__) __-__-__"},242:{name:"Congo",dial_code:"+242",code:"CG",mask:"+242(___) __-__-__"},243:{name:"Congo, The Democratic Republic of the Congo",dial_code:"+243",code:"CD",mask:"+243(___) ___-__-__"},244:{name:"Angola",dial_code:"+244",code:"AO",mask:"+244(__) ___-__-__"},245:{name:"Guinea-Bissau",dial_code:"+245",code:"GW",mask:"+245(___) __-__"},246:{name:"British Indian Ocean Territory",dial_code:"+246",code:"IO",mask:"+246(___) ___-__-__"},248:{name:"Seychelles",dial_code:"+248",code:"SC",mask:"+248(___) ___-__-__"},249:{name:"Sudan",dial_code:"+249",code:"SD",mask:"+249(___) __-__-__"},250:{name:"Rwanda",dial_code:"+250",code:"RW",mask:"+250(___) __-__-__"},251:{name:"Ethiopia",dial_code:"+251",code:"ET",mask:"+251(___) __-__-__"},252:{name:"Somalia",dial_code:"+252",code:"SO",mask:"+252(___) ___-__-__"},253:{name:"Djibouti",dial_code:"+253",code:"DJ",mask:"+253(___) ___-__-__"},254:{name:"Kenya",dial_code:"+254",code:"KE",mask:"+254(___) __-__-__"},255:{name:"Tanzania, United Republic of Tanzania",dial_code:"+255",code:"TZ",mask:"+255(___) __-__-__"},256:{name:"Uganda",dial_code:"+256",code:"UG",mask:"+256(___) __-__-__"},257:{name:"Burundi",dial_code:"+257",code:"BI",mask:"+257(__) __-__-__"},258:{name:"Mozambique",dial_code:"+258",code:"MZ",mask:"+258(___) __-__-__"},260:{name:"Zambia",dial_code:"+260",code:"ZM",mask:"+260(___) __-__-__"},261:{name:"Madagascar",dial_code:"+261",code:"MG",mask:"+261(___) __-__-__"},262:{name:"Reunion",dial_code:"+262",code:"RE",mask:"+262(___) __-__-__"},263:{name:"Zimbabwe",dial_code:"+263",code:"ZW",mask:"+263(___) __-__-__"},264:{name:"Namibia",dial_code:"+264",code:"NA",mask:"+264(___) __-__-__"},265:{name:"Malawi",dial_code:"+265",code:"MW",mask:"+265(___) __-__-__"},266:{name:"Lesotho",dial_code:"+266",code:"LS",mask:"+266(__) __-__-__"},267:{name:"Botswana",dial_code:"+267",code:"BW",mask:"+267(__) __-__-__"},268:{name:"Swaziland",dial_code:"+268",code:"SZ",mask:"+268(___) ___-__-__"},269:{name:"Comoros",dial_code:"+269",code:"KM",mask:"+269(___) __-__"},290:{name:"Saint Helena, Ascension and Tristan Da Cunha",dial_code:"+290",code:"SH",mask:"+290(___) ___-__-__"},291:{name:"Eritrea",dial_code:"+291",code:"ER",mask:"+291(___) ___-__-__"},297:{name:"Aruba",dial_code:"+297",code:"AW",mask:"+297(_) __-__-__"},298:{name:"Faroe Islands",dial_code:"+298",code:"FO",mask:"+298(__) __-__"},299:{name:"Greenland",dial_code:"+299",code:"GL",mask:"+299(__) __-__"},345:{name:"Cayman Islands",dial_code:"+ 345",code:"KY",mask:"+345(___) ___-__-__"},350:{name:"Gibraltar",dial_code:"+350",code:"GI",mask:"+350(__) __-__-__"},351:{name:"Portugal",dial_code:"+351",code:"PT",mask:"+351(___) __-__-__"},352:{name:"Luxembourg",dial_code:"+352",code:"LU",mask:"+352(___) __-__-__"},353:{name:"Ireland",dial_code:"+353",code:"IE",mask:"+353(___) __-__-__"},354:{name:"Iceland",dial_code:"+354",code:"IS",mask:"+354(___) __-__"},355:{name:"Albania",dial_code:"+355",code:"AL",mask:"+355(__) ___-__-__"},356:{name:"Malta",dial_code:"+356",code:"MT",mask:"+356(__) __-__-__"},357:{name:"Cyprus",dial_code:"+357",code:"CY",mask:"+357(__) __-__-__"},358:{name:"Finland",dial_code:"+358",code:"FI",mask:"+358(___) __-__-__"},359:{name:"Bulgaria",dial_code:"+359",code:"BG",mask:"+359(___) __-__-__"},370:{name:"Lithuania",dial_code:"+370",code:"LT",mask:"+370(_) ___-__-__"},371:{name:"Latvia",dial_code:"+371",code:"LV",mask:"+371(__) __-__-__"},372:{name:"Estonia",dial_code:"+372",code:"EE",mask:"+372(__) __-__-__"},373:{name:"Moldova",dial_code:"+373",code:"MD",mask:"+373(__) __-__-__"},374:{name:"Armenia",dial_code:"+374",code:"AM",mask:"+374(_) ___-__-__"},375:{name:"Belarus",dial_code:"+375",code:"BY",mask:"+375(__) ___-__-__"},376:{name:"Andorra",dial_code:"+376",code:"AD",mask:"+376(_) _-__-__"},377:{name:"Monaco",dial_code:"+377",code:"MC",mask:"+377(___) __-__-__"},378:{name:"San Marino",dial_code:"+378",code:"SM",mask:"+378(__) __-__-__"},379:{name:"Holy See (Vatican City State)",dial_code:"+379",code:"VA",mask:"+379(___) ___-__-__"},380:{name:"Ukraine",dial_code:"+380",code:"UA",mask:"+380(__) ___-__-__"},381:{name:"Serbia",dial_code:"+381",code:"RS",mask:"+381(__) __-__-__"},382:{name:"Montenegro",dial_code:"+382",code:"ME",mask:"+382(___) ___-__-__"},383:{name:"Kosovo",dial_code:"+383",code:"XK",mask:"+383(___) __-__"},385:{name:"Croatia",dial_code:"+385",code:"HR",mask:"+385(__) __-__-__"},386:{name:"Slovenia",dial_code:"+386",code:"SI",mask:"+386(__) __-__-__"},387:{name:"Bosnia and Herzegovina",dial_code:"+387",code:"BA",mask:"+387(__) __-__-__"},389:{name:"Macedonia",dial_code:"+389",code:"MK",mask:"+389(__) __-__-__"},420:{name:"Czech Republic",dial_code:"+420",code:"CZ",mask:"+420(___) __-__-__"},421:{name:"Slovakia",dial_code:"+421",code:"SK",mask:"+421(___) __-__-__"},423:{name:"Liechtenstein",dial_code:"+423",code:"LI",mask:"+423(___) __-__-__"},500:{name:"South Georgia and the South Sandwich Islands",dial_code:"+500",code:"GS",mask:"+500(___) ___-__-__"},501:{name:"Belize",dial_code:"+501",code:"BZ",mask:"+501(___) __-__"},502:{name:"Guatemala",dial_code:"+502",code:"GT",mask:"+502(__) __-__-__"},503:{name:"El Salvador",dial_code:"+503",code:"SV",mask:"+503(__) __-__-__"},504:{name:"Honduras",dial_code:"+504",code:"HN",mask:"+504(__) __-__-__"},505:{name:"Nicaragua",dial_code:"+505",code:"NI",mask:"+505(__) __-__-__"},506:{name:"Costa Rica",dial_code:"+506",code:"CR",mask:"+506(__) __-__-__"},507:{name:"Panama",dial_code:"+507",code:"PA",mask:"+507(__) __-__-__"},508:{name:"Saint Pierre and Miquelon",dial_code:"+508",code:"PM",mask:"+508(___) ___-__-__"},509:{name:"Haiti",dial_code:"+509",code:"HT",mask:"+509(__) __-__-__"},590:{name:"Saint Martin",dial_code:"+590",code:"MF",mask:"+590(___) __-__-__"},591:{name:"Bolivia, Plurinational State of bolivia",dial_code:"+591",code:"BO",mask:"+591(__) __-__-__"},592:{name:"Guyana",dial_code:"+592",code:"GY",mask:"+592(___) ___-__-__"},593:{name:"Ecuador",dial_code:"+593",code:"EC",mask:"+593(___) __-__-__"},594:{name:"French Guiana",dial_code:"+594",code:"GF",mask:"+594(___) __-__-__"},595:{name:"Paraguay",dial_code:"+595",code:"PY",mask:"+595(___) __-__-__"},596:{name:"Martinique",dial_code:"+596",code:"MQ",mask:"+596(___) __-__-__"},597:{name:"Suriname",dial_code:"+597",code:"SR",mask:"+597(___) __-__"},598:{name:"Uruguay",dial_code:"+598",code:"UY",mask:"+598(__) __-__-__"},599:{name:"Netherlands Antilles",dial_code:"+599",code:"AN",mask:"+599(__) __-__-__"},670:{name:"Timor-Leste",dial_code:"+670",code:"TL",mask:"+670(__) __-__-__"},672:{name:"Norfolk Island",dial_code:"+672",code:"NF",mask:"+672(___) ___-__-__"},673:{name:"Brunei Darussalam",dial_code:"+673",code:"BN",mask:"+673(___) __-__"},674:{name:"Nauru",dial_code:"+674",code:"NR",mask:"+674(___) __-__"},675:{name:"Papua New Guinea",dial_code:"+675",code:"PG",mask:"+675(___) __-__"},676:{name:"Tonga",dial_code:"+676",code:"TO",mask:"+676(___) __-__"},677:{name:"Solomon Islands",dial_code:"+677",code:"SB",mask:"+677(___) __-__"},678:{name:"Vanuatu",dial_code:"+678",code:"VU",mask:"+678(___) __-__"},679:{name:"Fiji",dial_code:"+679",code:"FJ",mask:"+679(___) __-__"},680:{name:"Palau",dial_code:"+680",code:"PW",mask:"+680(___) ___-__-__"},681:{name:"Wallis and Futuna",dial_code:"+681",code:"WF",mask:"+681(___) ___-__-__"},682:{name:"Cook Islands",dial_code:"+682",code:"CK",mask:"+682(_) __-__"},683:{name:"Niue",dial_code:"+683",code:"NU",mask:"+683(___) ___-__-__"},685:{name:"Samoa",dial_code:"+685",code:"WS",mask:"+685(__) __-__"},686:{name:"Kiribati",dial_code:"+686",code:"KI",mask:"+686(___) ___-__-__"},687:{name:"New Caledonia",dial_code:"+687",code:"NC",mask:"+687(__) __-__"},688:{name:"Tuvalu",dial_code:"+688",code:"TV",mask:"+688(___) ___-__-__"},689:{name:"French Polynesia",dial_code:"+689",code:"PF",mask:"+689(__) __-__"},690:{name:"Tokelau",dial_code:"+690",code:"TK",mask:"+690(___) ___-__-__"},691:{name:"Micronesia, Federated States of Micronesia",dial_code:"+691",code:"FM",mask:"+691(___) ___-__-__"},692:{name:"Marshall Islands",dial_code:"+692",code:"MH",mask:"+692(___) ___-__-__"},850:{name:"Korea, Democratic People's Republic of Korea",dial_code:"+850",code:"KP",mask:"+850(___) ___-__-__"},852:{name:"Hong Kong",dial_code:"+852",code:"HK",mask:"+852(__) __-__-__"},853:{name:"Macao",dial_code:"+853",code:"MO",mask:"+853(__) __-__-__"},855:{name:"Cambodia",dial_code:"+855",code:"KH",mask:"+855(__) __-__-__"},856:{name:"Laos",dial_code:"+856",code:"LA",mask:"+856(___) ___-__-__"},880:{name:"Bangladesh",dial_code:"+880",code:"BD",mask:"+880(___) ___-__-__"},886:{name:"Taiwan",dial_code:"+886",code:"TW",mask:"+886(___) __-__-__"},960:{name:"Maldives",dial_code:"+960",code:"MV",mask:"+960(___) __-__"},961:{name:"Lebanon",dial_code:"+961",code:"LB",mask:"+961(__) __-__-__"},962:{name:"Jordan",dial_code:"+962",code:"JO",mask:"+962(___) __-__-__"},963:{name:"Syrian Arab Republic",dial_code:"+963",code:"SY",mask:"+963(___) __-__-__"},964:{name:"Iraq",dial_code:"+964",code:"IQ",mask:"+964(___) ___-__-__"},965:{name:"Kuwait",dial_code:"+965",code:"KW",mask:"+965(__) __-__-__"},966:{name:"Saudi Arabia",dial_code:"+966",code:"SA",mask:"+966(___) __-__-__"},967:{name:"Yemen",dial_code:"+967",code:"YE",mask:"+967(___) __-__-__"},968:{name:"Oman",dial_code:"+968",code:"OM",mask:"+968(__) __-__-__"},970:{name:"Palestinian Territory, Occupied",dial_code:"+970",code:"PS",mask:"+970(___) __-__-__"},971:{name:"United Arab Emirates",dial_code:"+971",code:"AE",mask:"+971(___) __-__-__"},972:{name:"Israel",dial_code:"+972",code:"IL",mask:"+972(___) __-__-__"},973:{name:"Bahrain",dial_code:"+973",code:"BH",mask:"+973(__) __-__-__"},974:{name:"Qatar",dial_code:"+974",code:"QA",mask:"+974(__) __-__-__"},975:{name:"Bhutan",dial_code:"+975",code:"BT",mask:"+975(__) __-__-__"},976:{name:"Mongolia",dial_code:"+976",code:"MN",mask:"+976(__) __-__-__"},977:{name:"Nepal",dial_code:"+977",code:"NP",mask:"+977(___) ___-__-__"},992:{name:"Tajikistan",dial_code:"+992",code:"TJ",mask:"+992(___) __-__-__"},993:{name:"Turkmenistan",dial_code:"+993",code:"TM",mask:"+993(__) __-__-__"},994:{name:"Azerbaijan",dial_code:"+994",code:"AZ",mask:"+994(__) ___-__-__"},995:{name:"Georgia",dial_code:"+995",code:"GE",mask:"+995(___) __-__-__"},996:{name:"Kyrgyzstan",dial_code:"+996",code:"KG",mask:"+996(___) __-__-__"},998:{name:"Uzbekistan",dial_code:"+998",code:"UZ",mask:"+998(___) __-__-__"},1242:{name:"Bahamas",dial_code:"+1242",code:"BS",mask:"+1242(___) __-__"},1246:{name:"Barbados",dial_code:"+1246",code:"BB",mask:"+1246(___) __-__"},1264:{name:"Anguilla",dial_code:"+1264",code:"AI",mask:"+1264(___) ___-__-__"},1268:{name:"Antigua and Barbuda",dial_code:"+1268",code:"AG",mask:"+1268(_) __-__"},1284:{name:"Virgin Islands, British",dial_code:"+1284",code:"VG",mask:"+1284(___) __-__"},1340:{name:"Virgin Islands, U.S.",dial_code:"+1340",code:"VI",mask:"+1340(___) ___-__-__"},1441:{name:"Bermuda",dial_code:"+1441",code:"BM",mask:"+1441(___) __-__"},1473:{name:"Grenada",dial_code:"+1473",code:"GD",mask:"+1473(___) __-__"},1649:{name:"Turks and Caicos Islands",dial_code:"+1649",code:"TC",mask:"+1649(___) ___-__-__"},1664:{name:"Montserrat",dial_code:"+1664",code:"MS",mask:"+1664(___) ___-__-__"},1670:{name:"Northern Mariana Islands",dial_code:"+1670",code:"MP",mask:"+1670(___) ___-__-__"},1671:{name:"Guam",dial_code:"+1671",code:"GU",mask:"+1671(___) ___-__-__"},1684:{name:"American Samoa",dial_code:"+1684",code:"AS",mask:"+1684(___) ___-__-__"},1758:{name:"Saint Lucia",dial_code:"+1758",code:"LC",mask:"+1758(___) __-__"},1767:{name:"Dominica",dial_code:"+1767",code:"DM",mask:"+1767(___) __-__"},1784:{name:"Saint Vincent and the Grenadines",dial_code:"+1784",code:"VC",mask:"+1784(___) __-__"},1849:{name:"Dominican Republic",dial_code:"+1849",code:"DO",mask:"+1849(___) ___-__-__"},1868:{name:"Trinidad and Tobago",dial_code:"+1868",code:"TT",mask:"+1868(___) __-__"},1869:{name:"Saint Kitts and Nevis",dial_code:"+1869",code:"KN",mask:"+1869(___) __-__"},1876:{name:"Jamaica",dial_code:"+1876",code:"JM",mask:"+1876(___) __-__"},1939:{name:"Puerto Rico",dial_code:"+1939",code:"PR",mask:"+1939(___) ___-__-__"}},ir="_n_1ery1_2",lr="_e_1ery1_8",cr="_s_1ery1_11",sr="_r_1ery1_14",We={n:ir,e:lr,s:cr,r:sr,с:"_с_1ery1_17"};let ke={};function Ge({data:a}){let[_,i]=j.useState("show");j.useEffect(()=>{a.hide&&(setTimeout(function(){i("hide")},1800),setTimeout(function(){ke.del(a.key)},2500))},[a.key]);let s,f,h;switch(a.type){case"error":s=j.createElement(Le.error,null),f="Ошибка:",h=We.e;break;case"success":s=j.createElement(Le.success,null),f="Информация:",h=We.s;break;case"copy":s=j.createElement(Le.success,null),f="Копирование:",h=We.с;break;case"remark":s=j.createElement(Le.success,null),f="Подсказка:",h=We.r;break;default:s=j.createElement(Le.success,null),f="Предупреждение:",h=We.с;break}return j.createElement("li",{className:h,"data-status":_},s,j.createElement("b",null,f),j.createElement("p",null,a.text))}function dr({data:a}){let[_,i]=j.useState("show");return j.useEffect(()=>{a.hide&&(setTimeout(function(){i("hide")},1800),setTimeout(function(){ke.del(a.key)},2500))},[a.key]),j.createElement("li",{className:"item","data-status":_},a.text)}const Le={};Le.error=()=>j.createElement("svg",{viewBox:"0 0 24 24",fill:"none"},j.createElement("path",{d:"M12 22C7.28595 22 4.92893 22 3.46447 20.5355C2 19.0711 2 16.714 2 12C2 7.28595 2 4.92893 3.46447 3.46447C4.92893 2 7.28595 2 12 2C16.714 2 19.0711 2 20.5355 3.46447C22 4.92893 22 7.28595 22 12C22 16.714 22 19.0711 20.5355 20.5355C19.0711 22 16.714 22 12 22Z",fill:"#bb2014"}),j.createElement("path",{d:"M8.96967 8.96967C9.26256 8.67678 9.73744 8.67678 10.0303 8.96967L12 10.9394L13.9697 8.96969C14.2626 8.6768 14.7374 8.6768 15.0303 8.96969C15.3232 9.26258 15.3232 9.73746 15.0303 10.0303L13.0607 12L15.0303 13.9697C15.3232 14.2625 15.3232 14.7374 15.0303 15.0303C14.7374 15.3232 14.2625 15.3232 13.9696 15.0303L12 13.0607L10.0304 15.0303C9.73746 15.3232 9.26258 15.3232 8.96969 15.0303C8.6768 14.7374 8.6768 14.2626 8.96969 13.9697L10.9394 12L8.96967 10.0303C8.67678 9.73744 8.67678 9.26256 8.96967 8.96967Z",fill:"#fff"})),Le.success=()=>j.createElement("svg",{viewBox:"0 0 24 24",fill:"none"},j.createElement("path",{d:"M12 22C7.28595 22 4.92893 22 3.46447 20.5355C2 19.0711 2 16.714 2 12C2 7.28595 2 4.92893 3.46447 3.46447C4.92893 2 7.28595 2 12 2C16.714 2 19.0711 2 20.5355 3.46447C22 4.92893 22 7.28595 22 12C22 16.714 22 19.0711 20.5355 20.5355C19.0711 22 16.714 22 12 22Z",fill:"#367738"}),j.createElement("path",{d:"M16.0303 8.96967C16.3232 9.26256 16.3232 9.73744 16.0303 10.0303L11.0303 15.0303C10.7374 15.3232 10.2626 15.3232 9.96967 15.0303L7.96967 13.0303C7.67678 12.7374 7.67678 12.2626 7.96967 11.9697C8.26256 11.6768 8.73744 11.6768 9.03033 11.9697L10.5 13.4393L14.9697 8.96967C15.2626 8.67678 15.7374 8.67678 16.0303 8.96967Z",fill:"#fff"}));var Tt;(a=>{function _({className:c}){let[y,n]=j.useState([]);return ke.set=l=>{n([...y,l])},ke.del=l=>{n(y.filter(k=>k.key!==l))},y.length===0?"":j.createElement("ul",{className:[We.n,c].filter(l=>l).join(" ")},y.map(l=>l.item))}a.Init=_;function i(c,y=!0){let n=Date.now(),l={key:n,text:c,hide:y,type:"error"};ke.set({item:j.createElement(Ge,{key:n,data:l}),key:n})}a.Error=i;function s(c,y=!0){let n=Date.now(),l={key:n,text:c,hide:y,type:"success"};ke.set({item:j.createElement(Ge,{key:n,data:l}),key:n})}a.Success=s;function f(c,y=!0){let n=Date.now(),l={key:n,hide:y,text:c};ke.set({item:j.createElement(dr,{key:n,data:l}),key:n})}a.Custom=f;function h(c){let y=Date.now(),n={key:y,hide:!0,...c};ke.set({item:j.createElement(Ge,{key:y,data:n}),key:y})}a.Send=h;function C(c,y=!0){let n=Date.now(),l={key:n,text:c,hide:y,type:"remark"};ke.set({item:j.createElement(Ge,{key:n,data:l}),key:n})}a.Remark=C;function v(c,y=!0){let n=Date.now(),l={key:n,text:c,hide:y,type:"copy"};ke.set({item:j.createElement(Ge,{key:n,data:l}),key:n})}a.Copy=v})(Tt||(Tt={}));function ur({value:a,onValue:_,onSave:i,name:s="",placeholder:f="",title:h="",label:C="",error:v="",hide:c=!1,edit:y=!0,active:n=!0,after:l="",show:k=!0,view:E,className:I=""}){y=y!==void 0?y:!0,n=n!==void 0?n:!0,c=!!(c&&(a===""||a===void 0))&&!(y&&n),j.useRef(null);let P="+_(___) ___-__-__",T=!0,p=0,N=(g,w)=>{let M=document.createRange(),$=window.getSelection();M.setStart(w.childNodes[0],g),M.collapse(!0),$.removeAllRanges(),$.addRange(M),w.focus()},K=g=>{let w=O(g.target.textContent);g.target.textContent=w.q,w.i=w.q.lastIndexOf(w.v.substr(-1)),w.i<w.q.length&&w.q!==P?w.i++:w.i=w.q.indexOf("_"),N(w.i,g.target),_&&_({value:w.q.replace(/\D/g,""),name:s||""})},A=g=>{g.preventDefault(),navigator.clipboard.readText().then(w=>{window.document.execCommand("insertText",!1,w)}).catch(w=>{})},O=g=>{let w=0,M="",$=g.replace(/\D/g,"");$===""&&(T=!0);let te=$.split(""),J="";te.forEach(xe=>{T&&(J+=xe,Rt[J]!==void 0&&T?(T=!1,P=Rt[J].mask.replace(new RegExp("[0-9]","g"),"_"),M=Rt[J].code):(T&&(p=(""+J).length,P=`+${J}_(___) ___-__-__`.replace(new RegExp("[0-9]","g"),"_"),M=""),p>(""+J).length&&(T=!0,P=`+${J}_(___) ___-__-__`.replace(new RegExp("[0-9]","g"),"_"),M="")))});let ce=P.replace(/\D/g,"");return ce.length>=$.length&&($=ce),{q:P.replace(/[_\d]/g,function(){return $.charAt(w++)||"_"}),i:w,v:$,f:M}},q=g=>{g.preventDefault(),navigator.clipboard.writeText(g.target.textContent.replace(/\D/g,"")).then(function(){Tt.Copy("Данные в буфер обмене")},function(w){})},L=O(a),F=g=>{g.key==="Enter"&&g.preventDefault()};const S=g=>{Z.Blur(g),i&&i({value:g.target.textContent.replace(/\D/g,""),name:s||""})};let B={};return y&&n?(B.edit="true",B.contentEditable=Z.ContentEditable):B.contentEditable="false",f&&(B.placeholder=f),c?u.jsx(u.Fragment,{}):u.jsx(se,{type:"input",title:h||C,error:v,element_blok:{className:I},element_input:{className:[ee.w]},children:u.jsx("div",{onPaste:A,onInput:K,onKeyDown:F,onContextMenu:q,onBlur:S,inputMode:"tel",suppressContentEditableWarning:!0,...B,children:L.q})})}function fr({value:a,onValue:_,name:i="",inputmode:s="text",placeholder:f="",title:h="",label:C="",show:v=!0,hide:c=!1,edit:y=!0,active:n=!0,maxLength:l,onSave:k,className:E="",spellCheck:I=!0,isCopy:U=!0,isReload:P=!1,after:T="",before:p="",error:N=""}){const K=!!(c&&(a===""||a===void 0)),A=S=>{_&&_({value:S.target.textContent.trim(),name:i,reload:P})},O=S=>{l&&S.target.textContent.trim().length>=l&&S.key!=="Backspace"&&S.preventDefault(),S.key==="Enter"&&S.preventDefault()},q=S=>{S.preventDefault(),navigator.clipboard.readText().then(B=>{if(l){let g=S.target.textContent.length;if(g>=l)return;l-=g,B=B.slice(0,l)}window.document.execCommand("insertText",!1,B.replace(/(\r\n|\n|\r)/gm," "))}).catch(B=>{})};if(!(y&&n)&&!v||!(y&&n)&&K)return"";const L={};f&&(L.placeholder=f),y&&n&&(L.edit="");const F=S=>{Z.Blur(S),k==null||k({value:S.target.textContent.trim(),name:i})};return u.jsxs(se,{type:"input",title:h||C,error:N,element_blok:{className:[E]},element_input:{className:[ee.w]},children:[p,u.jsx("div",{onBlur:F,onPaste:q,onInput:A,onKeyDown:O,spellCheck:I,inputMode:s||"text",contentEditable:y&&n?Z.ContentEditable:"false",suppressContentEditableWarning:!0,...L,children:a}),T]})}function pr({onValue:a,onSave:_,active:i,max:s,edit:f,title:h,error:C,show:v,hide:c,value:y,placeholder:n,className:l,maxLength:k,name:E="",after:I="",before:U="",view:P}){f=f!==void 0?f:!0,i=i!==void 0?i:!0,c=!!(c&&(y===""||y===void 0))&&!(f&&i),n=n!==void 0?n:"",s=s!==void 0?s:99;let p=!1,N=F=>{a==null||a({value:F.target.textContent,name:E})},K=F=>{if(!(p&&F.which===86)){if(F.which===17||F.which===91)return p=!0;F.key!=="Backspace"&&(F.target.textContent.length===s&&F.preventDefault(),F.key==="Enter"&&F.preventDefault(),isNaN(F.key)&&F.preventDefault())}},A=F=>{if(F.which===17||F.which===91)return p=!1},O=F=>{F.preventDefault(),navigator.clipboard.readText().then(S=>{if(S=S.replace(/(?!^\+|\d)./g,""),k){let B=F.target.textContent.length;if(B>=k)return;k-=B,S=S.slice(0,k)}window.document.execCommand("insertText",!1,""+S)}).catch(S=>{})};const q=F=>{Z.Blur(F),_==null||_({value:F.target.textContent,name:E})};let L={};return f&&i?(L.edit="true",L.contentEditable=Z.ContentEditable):L.contentEditable="false",L.inputMode="decimal",n&&(L.placeholder=n),c?u.jsx(u.Fragment,{}):u.jsx(se,{type:"numeric",title:h,error:C,element_blok:{className:[l]},element_input:{className:[ee.w]},children:u.jsx("div",{onPaste:O,onInput:N,onBlur:q,onKeyDown:K,onKeyUp:A,spellCheck:"true",contentEditable:f&&i?Z.ContentEditable:"false",suppressContentEditableWarning:!0,...L,children:y})})}var Ot={exports:{}},$e={};/**
|
|
32
|
-
* @license React
|
|
33
|
-
* react-jsx-runtime.production.min.js
|
|
34
|
-
*
|
|
35
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
36
|
-
*
|
|
37
|
-
* This source code is licensed under the MIT license found in the
|
|
38
|
-
* LICENSE file in the root directory of this source tree.
|
|
39
|
-
*/var zt;function mr(){if(zt)return $e;zt=1;var a=j,_=Symbol.for("react.element"),i=Symbol.for("react.fragment"),s=Object.prototype.hasOwnProperty,f=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,h={key:!0,ref:!0,__self:!0,__source:!0};function C(v,c,y){var n,l={},k=null,E=null;y!==void 0&&(k=""+y),c.key!==void 0&&(k=""+c.key),c.ref!==void 0&&(E=c.ref);for(n in c)s.call(c,n)&&!h.hasOwnProperty(n)&&(l[n]=c[n]);if(v&&v.defaultProps)for(n in c=v.defaultProps,c)l[n]===void 0&&(l[n]=c[n]);return{$$typeof:_,type:v,key:k,ref:E,props:l,_owner:f.current}}return $e.Fragment=i,$e.jsx=C,$e.jsxs=C,$e}var xt={};/**
|
|
40
|
-
* @license React
|
|
41
|
-
* react-jsx-runtime.development.js
|
|
42
|
-
*
|
|
43
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
44
|
-
*
|
|
45
|
-
* This source code is licensed under the MIT license found in the
|
|
46
|
-
* LICENSE file in the root directory of this source tree.
|
|
47
|
-
*/var Lt;function yr(){return Lt||(Lt=1,process.env.NODE_ENV!=="production"&&function(){var a=j,_=Symbol.for("react.element"),i=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),f=Symbol.for("react.strict_mode"),h=Symbol.for("react.profiler"),C=Symbol.for("react.provider"),v=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),n=Symbol.for("react.suspense_list"),l=Symbol.for("react.memo"),k=Symbol.for("react.lazy"),E=Symbol.for("react.offscreen"),I=Symbol.iterator,U="@@iterator";function P(e){if(e===null||typeof e!="object")return null;var t=I&&e[I]||e[U];return typeof t=="function"?t:null}var T=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function p(e){{for(var t=arguments.length,r=new Array(t>1?t-1:0),o=1;o<t;o++)r[o-1]=arguments[o];N("error",e,r)}}function N(e,t,r){{var o=T.ReactDebugCurrentFrame,b=o.getStackAddendum();b!==""&&(t+="%s",r=r.concat([b]));var x=r.map(function(m){return String(m)});x.unshift("Warning: "+t),Function.prototype.apply.call(console[e],console,x)}}var K=!1,A=!1,O=!1,q=!1,L=!1,F;F=Symbol.for("react.module.reference");function S(e){return!!(typeof e=="string"||typeof e=="function"||e===s||e===h||L||e===f||e===y||e===n||q||e===E||K||A||O||typeof e=="object"&&e!==null&&(e.$$typeof===k||e.$$typeof===l||e.$$typeof===C||e.$$typeof===v||e.$$typeof===c||e.$$typeof===F||e.getModuleId!==void 0))}function B(e,t,r){var o=e.displayName;if(o)return o;var b=t.displayName||t.name||"";return b!==""?r+"("+b+")":r}function g(e){return e.displayName||"Context"}function w(e){if(e==null)return null;if(typeof e.tag=="number"&&p("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case s:return"Fragment";case i:return"Portal";case h:return"Profiler";case f:return"StrictMode";case y:return"Suspense";case n:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case v:var t=e;return g(t)+".Consumer";case C:var r=e;return g(r._context)+".Provider";case c:return B(e,e.render,"ForwardRef");case l:var o=e.displayName||null;return o!==null?o:w(e.type)||"Memo";case k:{var b=e,x=b._payload,m=b._init;try{return w(m(x))}catch{return null}}}return null}var M=Object.assign,$=0,te,J,ce,ue,xe,we,Ce;function je(){}je.__reactDisabledLog=!0;function He(){{if($===0){te=console.log,J=console.info,ce=console.warn,ue=console.error,xe=console.group,we=console.groupCollapsed,Ce=console.groupEnd;var e={configurable:!0,enumerable:!0,value:je,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}$++}}function Je(){{if($--,$===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:M({},e,{value:te}),info:M({},e,{value:J}),warn:M({},e,{value:ce}),error:M({},e,{value:ue}),group:M({},e,{value:xe}),groupCollapsed:M({},e,{value:we}),groupEnd:M({},e,{value:Ce})})}$<0&&p("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var fe=T.ReactCurrentDispatcher,pe;function ne(e,t,r){{if(pe===void 0)try{throw Error()}catch(b){var o=b.stack.trim().match(/\n( *(at )?)/);pe=o&&o[1]||""}return`
|
|
48
|
-
`+pe+e}}var me=!1,oe;{var Ve=typeof WeakMap=="function"?WeakMap:Map;oe=new Ve}function Ee(e,t){if(!e||me)return"";{var r=oe.get(e);if(r!==void 0)return r}var o;me=!0;var b=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var x;x=fe.current,fe.current=null,He();try{if(t){var m=function(){throw Error()};if(Object.defineProperty(m.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(m,[])}catch(W){o=W}Reflect.construct(e,[],m)}else{try{m.call()}catch(W){o=W}e.call(m.prototype)}}else{try{throw Error()}catch(W){o=W}e()}}catch(W){if(W&&o&&typeof W.stack=="string"){for(var d=W.stack.split(`
|
|
49
|
-
`),z=o.stack.split(`
|
|
50
|
-
`),R=d.length-1,D=z.length-1;R>=1&&D>=0&&d[R]!==z[D];)D--;for(;R>=1&&D>=0;R--,D--)if(d[R]!==z[D]){if(R!==1||D!==1)do if(R--,D--,D<0||d[R]!==z[D]){var G=`
|
|
51
|
-
`+d[R].replace(" at new "," at ");return e.displayName&&G.includes("<anonymous>")&&(G=G.replace("<anonymous>",e.displayName)),typeof e=="function"&&oe.set(e,G),G}while(R>=1&&D>=0);break}}}finally{me=!1,fe.current=x,Je(),Error.prepareStackTrace=b}var Q=e?e.displayName||e.name:"",V=Q?ne(Q):"";return typeof e=="function"&&oe.set(e,V),V}function Ze(e,t,r){return Ee(e,!1)}function Xe(e){var t=e.prototype;return!!(t&&t.isReactComponent)}function _e(e,t,r){if(e==null)return"";if(typeof e=="function")return Ee(e,Xe(e));if(typeof e=="string")return ne(e);switch(e){case y:return ne("Suspense");case n:return ne("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case c:return Ze(e.render);case l:return _e(e.type,t,r);case k:{var o=e,b=o._payload,x=o._init;try{return _e(x(b),t,r)}catch{}}}return""}var re=Object.prototype.hasOwnProperty,Se={},Re=T.ReactDebugCurrentFrame;function ie(e){if(e){var t=e._owner,r=_e(e.type,e._source,t?t.type:null);Re.setExtraStackFrame(r)}else Re.setExtraStackFrame(null)}function Qe(e,t,r,o,b){{var x=Function.call.bind(re);for(var m in e)if(x(e,m)){var d=void 0;try{if(typeof e[m]!="function"){var z=Error((o||"React class")+": "+r+" type `"+m+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[m]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw z.name="Invariant Violation",z}d=e[m](t,m,o,r,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(R){d=R}d&&!(d instanceof Error)&&(ie(b),p("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",o||"React class",r,m,typeof d),ie(null)),d instanceof Error&&!(d.message in Se)&&(Se[d.message]=!0,ie(b),p("Failed %s type: %s",r,d.message),ie(null))}}}var et=Array.isArray;function ye(e){return et(e)}function tt(e){{var t=typeof Symbol=="function"&&Symbol.toStringTag,r=t&&e[Symbol.toStringTag]||e.constructor.name||"Object";return r}}function rt(e){try{return Te(e),!1}catch{return!0}}function Te(e){return""+e}function Oe(e){if(rt(e))return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",tt(e)),Te(e)}var De=T.ReactCurrentOwner,at={key:!0,ref:!0,__self:!0,__source:!0},Pe,Ne;function nt(e){if(re.call(e,"ref")){var t=Object.getOwnPropertyDescriptor(e,"ref").get;if(t&&t.isReactWarning)return!1}return e.ref!==void 0}function ot(e){if(re.call(e,"key")){var t=Object.getOwnPropertyDescriptor(e,"key").get;if(t&&t.isReactWarning)return!1}return e.key!==void 0}function _t(e,t){typeof e.ref=="string"&&De.current}function it(e,t){{var r=function(){Pe||(Pe=!0,p("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"key",{get:r,configurable:!0})}}function lt(e,t){{var r=function(){Ne||(Ne=!0,p("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"ref",{get:r,configurable:!0})}}var ct=function(e,t,r,o,b,x,m){var d={$$typeof:_,type:e,key:t,ref:r,props:m,_owner:x};return d._store={},Object.defineProperty(d._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(d,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(d,"_source",{configurable:!1,enumerable:!1,writable:!1,value:b}),Object.freeze&&(Object.freeze(d.props),Object.freeze(d)),d};function st(e,t,r,o,b){{var x,m={},d=null,z=null;r!==void 0&&(Oe(r),d=""+r),ot(t)&&(Oe(t.key),d=""+t.key),nt(t)&&(z=t.ref,_t(t));for(x in t)re.call(t,x)&&!at.hasOwnProperty(x)&&(m[x]=t[x]);if(e&&e.defaultProps){var R=e.defaultProps;for(x in R)m[x]===void 0&&(m[x]=R[x])}if(d||z){var D=typeof e=="function"?e.displayName||e.name||"Unknown":e;d&&it(m,D),z&<(m,D)}return ct(e,d,z,b,o,De.current,m)}}var ge=T.ReactCurrentOwner,Fe=T.ReactDebugCurrentFrame;function X(e){if(e){var t=e._owner,r=_e(e.type,e._source,t?t.type:null);Fe.setExtraStackFrame(r)}else Fe.setExtraStackFrame(null)}var be;be=!1;function he(e){return typeof e=="object"&&e!==null&&e.$$typeof===_}function Me(){{if(ge.current){var e=w(ge.current.type);if(e)return`
|
|
52
|
-
|
|
53
|
-
Check the render method of \``+e+"`."}return""}}function dt(e){return""}var Ie={};function ut(e){{var t=Me();if(!t){var r=typeof e=="string"?e:e.displayName||e.name;r&&(t=`
|
|
54
|
-
|
|
55
|
-
Check the top-level render call using <`+r+">.")}return t}}function Ae(e,t){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var r=ut(t);if(Ie[r])return;Ie[r]=!0;var o="";e&&e._owner&&e._owner!==ge.current&&(o=" It was passed a child from "+w(e._owner.type)+"."),X(e),p('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',r,o),X(null)}}function qe(e,t){{if(typeof e!="object")return;if(ye(e))for(var r=0;r<e.length;r++){var o=e[r];he(o)&&Ae(o,t)}else if(he(e))e._store&&(e._store.validated=!0);else if(e){var b=P(e);if(typeof b=="function"&&b!==e.entries)for(var x=b.call(e),m;!(m=x.next()).done;)he(m.value)&&Ae(m.value,t)}}}function ft(e){{var t=e.type;if(t==null||typeof t=="string")return;var r;if(typeof t=="function")r=t.propTypes;else if(typeof t=="object"&&(t.$$typeof===c||t.$$typeof===l))r=t.propTypes;else return;if(r){var o=w(t);Qe(r,e.props,"prop",o,e)}else if(t.PropTypes!==void 0&&!be){be=!0;var b=w(t);p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",b||"Unknown")}typeof t.getDefaultProps=="function"&&!t.getDefaultProps.isReactClassApproved&&p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pt(e){{for(var t=Object.keys(e.props),r=0;r<t.length;r++){var o=t[r];if(o!=="children"&&o!=="key"){X(e),p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",o),X(null);break}}e.ref!==null&&(X(e),p("Invalid attribute `ref` supplied to `React.Fragment`."),X(null))}}var Be={};function ze(e,t,r,o,b,x){{var m=S(e);if(!m){var d="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(d+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var z=dt();z?d+=z:d+=Me();var R;e===null?R="null":ye(e)?R="array":e!==void 0&&e.$$typeof===_?(R="<"+(w(e.type)||"Unknown")+" />",d=" Did you accidentally export a JSX literal instead of a component?"):R=typeof e,p("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",R,d)}var D=st(e,t,r,b,x);if(D==null)return D;if(m){var G=t.children;if(G!==void 0)if(o)if(ye(G)){for(var Q=0;Q<G.length;Q++)qe(G[Q],e);Object.freeze&&Object.freeze(G)}else p("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else qe(G,e)}if(re.call(t,"key")){var V=w(e),W=Object.keys(t).filter(function(vt){return vt!=="key"}),ve=W.length>0?"{key: someKey, "+W.join(": ..., ")+": ...}":"{key: someKey}";if(!Be[V+ve]){var ht=W.length>0?"{"+W.join(": ..., ")+": ...}":"{}";p(`A props object containing a "key" prop is being spread into JSX:
|
|
56
|
-
let props = %s;
|
|
57
|
-
<%s {...props} />
|
|
58
|
-
React keys must be passed directly to JSX without using spread:
|
|
59
|
-
let props = %s;
|
|
60
|
-
<%s key={someKey} {...props} />`,ve,V,ht,V),Be[V+ve]=!0}}return e===s?pt(D):ft(D),D}}function mt(e,t,r){return ze(e,t,r,!0)}function yt(e,t,r){return ze(e,t,r,!1)}var gt=yt,bt=mt;xt.Fragment=s,xt.jsx=gt,xt.jsxs=bt}()),xt}process.env.NODE_ENV==="production"?Ot.exports=mr():Ot.exports=yr();var Y=Ot.exports;const gr="_shake_oqfdb_1",br="_modal_oqfdb_79",hr="_sa_oqfdb_89",vr="_ss_oqfdb_94",kr="_sm_oqfdb_98",xr="_sl_oqfdb_102",wr="_sx_oqfdb_106",Cr="_sf_oqfdb_110",jr="_o_oqfdb_116",Er="_b_oqfdb_28",Sr="_w_oqfdb_15",Rr="_h_oqfdb_146",Tr="_l_oqfdb_160",Or="_t_oqfdb_197",Dr="_x_oqfdb_201",Pr="_s_oqfdb_89",Nr="_c_oqfdb_219",Fr="_f_oqfdb_224",Mr="_r__oqfdb_235",Ir="_c__oqfdb_250",Ar="_g_oqfdb_259",qr="_m_oqfdb_79",ae={shake:gr,modal:br,sa:hr,ss:vr,sm:kr,sl:xr,sx:wr,sf:Cr,o:jr,b:Er,w:Sr,h:Rr,l:Tr,t:Or,x:Dr,s:Pr,c:Nr,f:Fr,r_:Mr,c_:Ir,g:Ar,m:qr};function Br({children:a,className:_}){return Y.jsx("div",{className:[ae.l,_].filter(i=>i!==void 0).join(" "),children:Y.jsx("ul",{children:a})})}function zr({children:a,className:_}){return Y.jsx("div",{className:[ae.s,_].filter(i=>i!==void 0).join(" "),children:a})}function Lr({children:a,direction:_="column",className:i}){return Y.jsx("ul",{className:[ae.f,ae[_==="row"?"r_":"c_"],i].filter(s=>s!==void 0).join(" "),children:a})}function Wr({children:a,className:_}){return Y.jsx("div",{className:[ae.c,_].filter(i=>i!==void 0).join(" "),children:a})}function Ur({children:a,className:_}){return Y.jsx("div",{className:[ae.g,_].filter(i=>i!==void 0).join(" "),children:a})}function Kr(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof self<"u"?self:typeof global<"u"?global:{}}function Wt(a){return Kr().IMPORT_MODULES}var Dt={exports:{}},Ye={};/**
|
|
61
|
-
* @license React
|
|
62
|
-
* react-jsx-runtime.production.min.js
|
|
63
|
-
*
|
|
64
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
65
|
-
*
|
|
66
|
-
* This source code is licensed under the MIT license found in the
|
|
67
|
-
* LICENSE file in the root directory of this source tree.
|
|
68
|
-
*/var Ut;function Gr(){if(Ut)return Ye;Ut=1;var a=j,_=Symbol.for("react.element"),i=Symbol.for("react.fragment"),s=Object.prototype.hasOwnProperty,f=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,h={key:!0,ref:!0,__self:!0,__source:!0};function C(v,c,y){var n,l={},k=null,E=null;y!==void 0&&(k=""+y),c.key!==void 0&&(k=""+c.key),c.ref!==void 0&&(E=c.ref);for(n in c)s.call(c,n)&&!h.hasOwnProperty(n)&&(l[n]=c[n]);if(v&&v.defaultProps)for(n in c=v.defaultProps,c)l[n]===void 0&&(l[n]=c[n]);return{$$typeof:_,type:v,key:k,ref:E,props:l,_owner:f.current}}return Ye.Fragment=i,Ye.jsx=C,Ye.jsxs=C,Ye}var wt={};/**
|
|
69
|
-
* @license React
|
|
70
|
-
* react-jsx-runtime.development.js
|
|
71
|
-
*
|
|
72
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
73
|
-
*
|
|
74
|
-
* This source code is licensed under the MIT license found in the
|
|
75
|
-
* LICENSE file in the root directory of this source tree.
|
|
76
|
-
*/var Kt;function $r(){return Kt||(Kt=1,process.env.NODE_ENV!=="production"&&function(){var a=j,_=Symbol.for("react.element"),i=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),f=Symbol.for("react.strict_mode"),h=Symbol.for("react.profiler"),C=Symbol.for("react.provider"),v=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),n=Symbol.for("react.suspense_list"),l=Symbol.for("react.memo"),k=Symbol.for("react.lazy"),E=Symbol.for("react.offscreen"),I=Symbol.iterator,U="@@iterator";function P(e){if(e===null||typeof e!="object")return null;var t=I&&e[I]||e[U];return typeof t=="function"?t:null}var T=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function p(e){{for(var t=arguments.length,r=new Array(t>1?t-1:0),o=1;o<t;o++)r[o-1]=arguments[o];N("error",e,r)}}function N(e,t,r){{var o=T.ReactDebugCurrentFrame,b=o.getStackAddendum();b!==""&&(t+="%s",r=r.concat([b]));var x=r.map(function(m){return String(m)});x.unshift("Warning: "+t),Function.prototype.apply.call(console[e],console,x)}}var K=!1,A=!1,O=!1,q=!1,L=!1,F;F=Symbol.for("react.module.reference");function S(e){return!!(typeof e=="string"||typeof e=="function"||e===s||e===h||L||e===f||e===y||e===n||q||e===E||K||A||O||typeof e=="object"&&e!==null&&(e.$$typeof===k||e.$$typeof===l||e.$$typeof===C||e.$$typeof===v||e.$$typeof===c||e.$$typeof===F||e.getModuleId!==void 0))}function B(e,t,r){var o=e.displayName;if(o)return o;var b=t.displayName||t.name||"";return b!==""?r+"("+b+")":r}function g(e){return e.displayName||"Context"}function w(e){if(e==null)return null;if(typeof e.tag=="number"&&p("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case s:return"Fragment";case i:return"Portal";case h:return"Profiler";case f:return"StrictMode";case y:return"Suspense";case n:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case v:var t=e;return g(t)+".Consumer";case C:var r=e;return g(r._context)+".Provider";case c:return B(e,e.render,"ForwardRef");case l:var o=e.displayName||null;return o!==null?o:w(e.type)||"Memo";case k:{var b=e,x=b._payload,m=b._init;try{return w(m(x))}catch{return null}}}return null}var M=Object.assign,$=0,te,J,ce,ue,xe,we,Ce;function je(){}je.__reactDisabledLog=!0;function He(){{if($===0){te=console.log,J=console.info,ce=console.warn,ue=console.error,xe=console.group,we=console.groupCollapsed,Ce=console.groupEnd;var e={configurable:!0,enumerable:!0,value:je,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}$++}}function Je(){{if($--,$===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:M({},e,{value:te}),info:M({},e,{value:J}),warn:M({},e,{value:ce}),error:M({},e,{value:ue}),group:M({},e,{value:xe}),groupCollapsed:M({},e,{value:we}),groupEnd:M({},e,{value:Ce})})}$<0&&p("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var fe=T.ReactCurrentDispatcher,pe;function ne(e,t,r){{if(pe===void 0)try{throw Error()}catch(b){var o=b.stack.trim().match(/\n( *(at )?)/);pe=o&&o[1]||""}return`
|
|
77
|
-
`+pe+e}}var me=!1,oe;{var Ve=typeof WeakMap=="function"?WeakMap:Map;oe=new Ve}function Ee(e,t){if(!e||me)return"";{var r=oe.get(e);if(r!==void 0)return r}var o;me=!0;var b=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var x;x=fe.current,fe.current=null,He();try{if(t){var m=function(){throw Error()};if(Object.defineProperty(m.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(m,[])}catch(W){o=W}Reflect.construct(e,[],m)}else{try{m.call()}catch(W){o=W}e.call(m.prototype)}}else{try{throw Error()}catch(W){o=W}e()}}catch(W){if(W&&o&&typeof W.stack=="string"){for(var d=W.stack.split(`
|
|
78
|
-
`),z=o.stack.split(`
|
|
79
|
-
`),R=d.length-1,D=z.length-1;R>=1&&D>=0&&d[R]!==z[D];)D--;for(;R>=1&&D>=0;R--,D--)if(d[R]!==z[D]){if(R!==1||D!==1)do if(R--,D--,D<0||d[R]!==z[D]){var G=`
|
|
80
|
-
`+d[R].replace(" at new "," at ");return e.displayName&&G.includes("<anonymous>")&&(G=G.replace("<anonymous>",e.displayName)),typeof e=="function"&&oe.set(e,G),G}while(R>=1&&D>=0);break}}}finally{me=!1,fe.current=x,Je(),Error.prepareStackTrace=b}var Q=e?e.displayName||e.name:"",V=Q?ne(Q):"";return typeof e=="function"&&oe.set(e,V),V}function Ze(e,t,r){return Ee(e,!1)}function Xe(e){var t=e.prototype;return!!(t&&t.isReactComponent)}function _e(e,t,r){if(e==null)return"";if(typeof e=="function")return Ee(e,Xe(e));if(typeof e=="string")return ne(e);switch(e){case y:return ne("Suspense");case n:return ne("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case c:return Ze(e.render);case l:return _e(e.type,t,r);case k:{var o=e,b=o._payload,x=o._init;try{return _e(x(b),t,r)}catch{}}}return""}var re=Object.prototype.hasOwnProperty,Se={},Re=T.ReactDebugCurrentFrame;function ie(e){if(e){var t=e._owner,r=_e(e.type,e._source,t?t.type:null);Re.setExtraStackFrame(r)}else Re.setExtraStackFrame(null)}function Qe(e,t,r,o,b){{var x=Function.call.bind(re);for(var m in e)if(x(e,m)){var d=void 0;try{if(typeof e[m]!="function"){var z=Error((o||"React class")+": "+r+" type `"+m+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[m]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw z.name="Invariant Violation",z}d=e[m](t,m,o,r,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(R){d=R}d&&!(d instanceof Error)&&(ie(b),p("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",o||"React class",r,m,typeof d),ie(null)),d instanceof Error&&!(d.message in Se)&&(Se[d.message]=!0,ie(b),p("Failed %s type: %s",r,d.message),ie(null))}}}var et=Array.isArray;function ye(e){return et(e)}function tt(e){{var t=typeof Symbol=="function"&&Symbol.toStringTag,r=t&&e[Symbol.toStringTag]||e.constructor.name||"Object";return r}}function rt(e){try{return Te(e),!1}catch{return!0}}function Te(e){return""+e}function Oe(e){if(rt(e))return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",tt(e)),Te(e)}var De=T.ReactCurrentOwner,at={key:!0,ref:!0,__self:!0,__source:!0},Pe,Ne;function nt(e){if(re.call(e,"ref")){var t=Object.getOwnPropertyDescriptor(e,"ref").get;if(t&&t.isReactWarning)return!1}return e.ref!==void 0}function ot(e){if(re.call(e,"key")){var t=Object.getOwnPropertyDescriptor(e,"key").get;if(t&&t.isReactWarning)return!1}return e.key!==void 0}function _t(e,t){typeof e.ref=="string"&&De.current}function it(e,t){{var r=function(){Pe||(Pe=!0,p("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"key",{get:r,configurable:!0})}}function lt(e,t){{var r=function(){Ne||(Ne=!0,p("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"ref",{get:r,configurable:!0})}}var ct=function(e,t,r,o,b,x,m){var d={$$typeof:_,type:e,key:t,ref:r,props:m,_owner:x};return d._store={},Object.defineProperty(d._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(d,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(d,"_source",{configurable:!1,enumerable:!1,writable:!1,value:b}),Object.freeze&&(Object.freeze(d.props),Object.freeze(d)),d};function st(e,t,r,o,b){{var x,m={},d=null,z=null;r!==void 0&&(Oe(r),d=""+r),ot(t)&&(Oe(t.key),d=""+t.key),nt(t)&&(z=t.ref,_t(t));for(x in t)re.call(t,x)&&!at.hasOwnProperty(x)&&(m[x]=t[x]);if(e&&e.defaultProps){var R=e.defaultProps;for(x in R)m[x]===void 0&&(m[x]=R[x])}if(d||z){var D=typeof e=="function"?e.displayName||e.name||"Unknown":e;d&&it(m,D),z&<(m,D)}return ct(e,d,z,b,o,De.current,m)}}var ge=T.ReactCurrentOwner,Fe=T.ReactDebugCurrentFrame;function X(e){if(e){var t=e._owner,r=_e(e.type,e._source,t?t.type:null);Fe.setExtraStackFrame(r)}else Fe.setExtraStackFrame(null)}var be;be=!1;function he(e){return typeof e=="object"&&e!==null&&e.$$typeof===_}function Me(){{if(ge.current){var e=w(ge.current.type);if(e)return`
|
|
81
|
-
|
|
82
|
-
Check the render method of \``+e+"`."}return""}}function dt(e){return""}var Ie={};function ut(e){{var t=Me();if(!t){var r=typeof e=="string"?e:e.displayName||e.name;r&&(t=`
|
|
83
|
-
|
|
84
|
-
Check the top-level render call using <`+r+">.")}return t}}function Ae(e,t){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var r=ut(t);if(Ie[r])return;Ie[r]=!0;var o="";e&&e._owner&&e._owner!==ge.current&&(o=" It was passed a child from "+w(e._owner.type)+"."),X(e),p('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',r,o),X(null)}}function qe(e,t){{if(typeof e!="object")return;if(ye(e))for(var r=0;r<e.length;r++){var o=e[r];he(o)&&Ae(o,t)}else if(he(e))e._store&&(e._store.validated=!0);else if(e){var b=P(e);if(typeof b=="function"&&b!==e.entries)for(var x=b.call(e),m;!(m=x.next()).done;)he(m.value)&&Ae(m.value,t)}}}function ft(e){{var t=e.type;if(t==null||typeof t=="string")return;var r;if(typeof t=="function")r=t.propTypes;else if(typeof t=="object"&&(t.$$typeof===c||t.$$typeof===l))r=t.propTypes;else return;if(r){var o=w(t);Qe(r,e.props,"prop",o,e)}else if(t.PropTypes!==void 0&&!be){be=!0;var b=w(t);p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",b||"Unknown")}typeof t.getDefaultProps=="function"&&!t.getDefaultProps.isReactClassApproved&&p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pt(e){{for(var t=Object.keys(e.props),r=0;r<t.length;r++){var o=t[r];if(o!=="children"&&o!=="key"){X(e),p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",o),X(null);break}}e.ref!==null&&(X(e),p("Invalid attribute `ref` supplied to `React.Fragment`."),X(null))}}var Be={};function ze(e,t,r,o,b,x){{var m=S(e);if(!m){var d="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(d+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var z=dt();z?d+=z:d+=Me();var R;e===null?R="null":ye(e)?R="array":e!==void 0&&e.$$typeof===_?(R="<"+(w(e.type)||"Unknown")+" />",d=" Did you accidentally export a JSX literal instead of a component?"):R=typeof e,p("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",R,d)}var D=st(e,t,r,b,x);if(D==null)return D;if(m){var G=t.children;if(G!==void 0)if(o)if(ye(G)){for(var Q=0;Q<G.length;Q++)qe(G[Q],e);Object.freeze&&Object.freeze(G)}else p("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else qe(G,e)}if(re.call(t,"key")){var V=w(e),W=Object.keys(t).filter(function(vt){return vt!=="key"}),ve=W.length>0?"{key: someKey, "+W.join(": ..., ")+": ...}":"{key: someKey}";if(!Be[V+ve]){var ht=W.length>0?"{"+W.join(": ..., ")+": ...}":"{}";p(`A props object containing a "key" prop is being spread into JSX:
|
|
85
|
-
let props = %s;
|
|
86
|
-
<%s {...props} />
|
|
87
|
-
React keys must be passed directly to JSX without using spread:
|
|
88
|
-
let props = %s;
|
|
89
|
-
<%s key={someKey} {...props} />`,ve,V,ht,V),Be[V+ve]=!0}}return e===s?pt(D):ft(D),D}}function mt(e,t,r){return ze(e,t,r,!0)}function yt(e,t,r){return ze(e,t,r,!1)}var gt=yt,bt=mt;wt.Fragment=s,wt.jsx=gt,wt.jsxs=bt}()),wt}process.env.NODE_ENV==="production"?Dt.exports=Gr():Dt.exports=$r();var Pt=Dt.exports;const Yr="_btn_1k1b3_1",Hr="_confirm_1k1b3_15",Jr="_cancel_1k1b3_20",Vr="_action_1k1b3_25",Zr="_disabled_1k1b3_30",Xr="_m_1k1b3_44",Qr="_l_1k1b3_48",Ct={btn:Yr,confirm:Hr,cancel:Jr,action:Vr,disabled:Zr,await:"_await_1k1b3_37",m:Xr,l:Qr},ea=({onClick:a,onSend:_,size:i="m",view:s="confirm",children:f,isDisabled:h=!1,className:C,after:v,before:c,label:y,onRef:n,awaitText:l="Ожидайте"})=>{let[k,E]=j.useState(!1);const I=P=>{if(a)return a();k||(_?(E(!0),_(E)):P.preventDefault())};let U={};return(h||k)&&(U.disabled=!0),Pt.jsx("button",{...U,ref:n,className:[Ct.btn,k?Ct.disabled:Ct[s],i&&Ct[i],C].filter(P=>P!="").join(" "),onClick:I,children:k?l:Pt.jsxs(Pt.Fragment,{children:[c||""," ",y," ",v||""]})||f})};let de={};function ta({children:a}){return Y.jsx(Y.Fragment,{children:a})}var jt;(a=>{function _({import_modules:n}){let[l,k]=j.useState([]);return de.x=E=>{k(E?l.filter(I=>I.key!==E):[])},j.useEffect(()=>{n&&(de.i=n)},[]),de.add=(E,I=Date.now())=>{k([...l,{key:I,item:E}])},Y.jsx(Y.Fragment,{children:l.map(E=>E.item)})}a.Init=_;function i(n){return n&&(de.i=n),de.i}a.Import=i,a.List=Br,a.Scroll=zr,a.Form=Lr,a.Center=Wr,a.Column=Ur;function s(n,l,k){de.i?de.i(`${n}/modal/${l}.tsx`).then(E=>{E.default.Open(k)}):Wt()(`${n}/modal/${l}.tsx`).then(E=>{E.default.Open(k)})}a.Open=s;function f({type:n,name:l,params:k}){let[E,I]=j.useState(null);return j.useEffect(()=>{de.i?de.i(`${n}/modal/${l}.tsx`).then(U=>{I(U.default.Icon(k))}):Wt()(`${n}/modal/${l}.tsx`).then(U=>{I(U.default.Icon(k))})},[k.id]),Y.jsx(Y.Fragment,{children:E})}a.Icon=f;function h(n,l){de.add(Y.jsx(ta,{children:n},String(Date.now())),l)}a.Add=h;function C(n){de.x(n)}a.Close=C;function v(n){if(n.target.classList[0]!=="modal")return;let l=n.target.children[0];l.setAttribute("shake",!0),setTimeout(()=>{l.setAttribute("shake",!1)},1e3)}a.Shake=v;function c(n,l){const k=E=>{a.Add(Y.jsx(n,{...E},new Date().getTime()))};return{Icon:E=>Y.jsx("i",{onClick:()=>k(E),children:l&&Y.jsx(l,{})}),Open:k}}a.Create=c;function y({title:n,children:l,button:k,tabs:E,size:I="m",className:U="",shake:P=!0,menu:T}){const[p,N]=j.useState(!0),K=j.useRef(),A=q=>{if(k){if(k.onClick)return q(!1),k.onClick({setOpen:N});if(k.onSend)return k.onSend({setOpen:N,disabled:q})}},O=()=>{if(!P)return N(!1);K.current.setAttribute("shake",!0),setTimeout(()=>{K.current.setAttribute("shake",!1)},1e3)};return p?Y.jsxs("div",{className:`${ae.modal}`,children:[Y.jsx("div",{className:ae.o,onClick:O}),Y.jsxs("div",{className:[ae.w,ae[`s${I}`],U].filter(q=>q!="").join(" "),ref:K,children:[Y.jsxs("div",{className:ae.h,children:[Y.jsx("div",{className:ae.t,children:n}),Y.jsxs("div",{className:ae.m,children:[E&&Y.jsx("nav",{children:E.map((q,L)=>Y.jsx("span",{onClick:q.onClick,className:q.active?"active":"",children:q.name},L))}),T]}),Y.jsx("div",{className:ae.x,onClick:()=>{N(!1)},children:Y.jsx("svg",{viewBox:"0 0 24 24",fill:"none",children:Y.jsx("path",{d:"M20 5L5 20M5 5L20 20",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),l,k&&Y.jsx("div",{className:ae.b,children:Y.jsx(ea,{label:k.label,onSend:A,className:ae.btn,size:k.size})})]})]}):""}a.Main=y})(jt||(jt={}));const ra=(a,_=",")=>(a=a!==void 0&&a!==""?a.split(_):[],a.filter(i=>i!=="").reduce((i,s)=>(i[s]=!0,i),{}));function aa({value:a,onValue:_,name:i,placeholder:s="",separator:f=",",title:h,error:C,hide:v=!1,edit:c=!0,active:y=!0,outFormat:n="object",after:l="",modal:k,options:E,className:I}){const[U,P]=j.useState(ra(a,f)),T=p=>{if(!(c&&y)||!k)return;let N=k.split(".");jt.Open(N[0],N[1],{callback:K=>{if(_)switch(n){case"array":_({value:Object.keys(K),name:i});break;case"string":_({value:Object.keys(K).filter(A=>K[A]).join(f),name:i});break;default:_({value:K,name:i})}P(Object.fromEntries(Object.entries(K).filter(([A,O])=>O!==!1)))},onValue:_,options:E,name:i,value:U})};return v?u.jsx(u.Fragment,{}):u.jsx(se,{type:"group",title:h,error:C,element_blok:{className:[I]},element_input:{className:[ee.g],props:{onClick:T}},children:Object.keys(U).map(p=>{var N;return u.jsx("div",{children:(N=E[p])==null?void 0:N.label},p)})})}const Nt={o:"_o_1wehm_12",l:"_l_1wehm_22",f:"_f_1wehm_81"};function na({title:a,error:_,edit:i=!0,active:s=!0,hide:f,value:h=0,onValue:C,options:v,placeholder:c="",className:y,isIcon:n=!0,name:l,after:k,view:E,order:I,isReload:U=!1}){const P=j.useRef(null),[T,p]=j.useState(h),[N,K]=j.useState(v),[A,O]=j.useState(!1);j.useEffect(()=>{p(h),K(v)},[h,v]);const q=Array.isArray(N),L=q?N.length:Object.keys(N||{}).length,F=M=>{var $;if(q){const te=N.find(J=>(J.id||J.i)===M);return te==null?void 0:te.n}else return($=N==null?void 0:N[M])==null?void 0:$.n};f=!!(f&&(h===0||F(h)===void 0))&&!(i&&s);const B=M=>{p(M),C&&C({value:M,name:l,reload:U})},g=M=>{L!==0&&i&&s&&(P.position=P.current.getBoundingClientRect(),O(!0))},w={};return c&&(w.placeholder=c),f?"":u.jsxs(u.Fragment,{children:[u.jsx(se,{type:"select",title:a,element_blok:{className:[y]},error:_,element_input:{className:[Nt.f],props:{onClick:g}},ref:P,children:u.jsx("div",{...w,children:F(T)||c||""})}),A&&Et.createPortal(u.jsx(oa,{parent:P.position,onValue:B,view:E,className:y,options:N,order:I,setOpen:O},new Date().getTime()),document.body)]})}const oa=({onValue:a,parent:_,className:i,options:s,order:f,setOpen:h})=>{let C=()=>{h(!1)},v=n=>{h(!1),a(n)},c=window.innerHeight-_.y+_.height<320?_.y-312:_.y+33,y=window.innerWidth-_.x<265?_.x-235:_.x;return u.jsxs(u.Fragment,{children:[u.jsx("div",{className:Nt.o,onClick:C},new Date().getTime()),u.jsx("div",{className:[Nt.l,i].filter(n=>n!==void 0).join(" "),style:{top:c+"px",left:y+"px",width:_.width},children:u.jsx(_a,{order:f,options:s,link:v})})]})},_a=({order:a,options:_,link:i})=>{if(Array.isArray(_)){const f=_;return a?u.jsx("ul",{children:a.map((h,C)=>{const v=f.find(y=>(y.id||y.i)===h);if(!v||v.s===0||!v.n)return null;const c=v.id||v.i;return c===void 0?null:u.jsx("li",{onClick:()=>{i(c)},children:v.n},`${c}-${C}`)})}):u.jsx("ul",{children:f.map((h,C)=>{if(h.s===0||!h.n)return null;const v=h.id||h.i;return v===void 0?null:u.jsx("li",{onClick:()=>{i(v)},children:h.n},`${v}-${C}`)})})}return a?u.jsx("ul",{children:a.map((f,h)=>{const C=_[f];return!C||C.s===0||!C.n?null:u.jsx("li",{onClick:()=>{i(f)},children:C.n},`${f}-${h}`)})}):u.jsx("ul",{children:Object.keys(_||{}).map((f,h)=>{const C=Number(f),v=_[C];return!v||v.s===0||!v.n?null:u.jsx("li",{onClick:()=>{i(C)},children:v.n},`${C}-${h}`)})})};function ia({value:a,onValue:_,name:i,placeholder:s="",title:f,error:h,hide:C=!1,edit:v=!0,show:c=!0,active:y=!0,after:n="",view:l,modal:k,options:E,className:I}){const U=O=>O?Array.isArray(O)?O[1]||"":O:"",P=O=>Array.isArray(O)&&O.length>=2?[O[0],O[1]]:typeof O=="object"&&O.id!==void 0&&O.name!==void 0?[O.id,O.name]:O,T=O=>{const q=P(O);_&&_({value:q,name:i}),N(q)},[p,N]=j.useState(a);j.useEffect(()=>{N(a)},[a]);const K=O=>{if(!(v&&y)||!k)return;let q=k.split(".");if(q.length<2)return;const L=Array.isArray(p)?p[0]:p;jt.Open(q[0],q[1],{callback:T,onValue:T,options:E,name:i,value:L})},A={};return s&&(A.placeholder=s),C?u.jsx(u.Fragment,{}):u.jsx(se,{type:"input",title:f,element_blok:{className:[I]},error:h,element_input:{className:[ee.w],props:{onClick:K}},children:u.jsx("div",{...A,children:U(p)})})}function la({value:a,onValue:_,onSave:i,name:s,placeholder:f="",className:h,title:C,error:v,edit:c=!0,active:y=!0,reload:n=!1,native:l=!1,isShow:k=!1,maxLength:E,eyes:I=[],after:U=""}){const[P,T]=j.useState(k);let p=L=>{_&&_({value:L.target.textContent,name:s,reload:n})},N=L=>{L.key==="Enter"&&L.preventDefault()},K=L=>{L.preventDefault(),navigator.clipboard.readText().then(F=>{if(E){let S=L.target.textContent.length;if(S>=E)return;E-=S,F=F.slice(0,E)}window.document.execCommand("insertText",!1,F.replace(/(\r\n|\n|\r)/gm," "))}).catch(F=>{})},A=L=>{Z.Blur(L),i==null||i({value:L.target.textContent.trim(),name:s})};const O={};O.field="password",P&&(O.show=""),h&&(O.className=h);const q={};return f&&(q.placeholder=f),l?"":u.jsxs("dl",{...O,children:[C?u.jsx("dt",{children:C}):"",u.jsx("dd",{onPaste:K,onInput:p,onKeyDown:N,onBlur:A,contentEditable:c&&y?Z.ContentEditable:"false",...q,suppressContentEditableWarning:!0,children:a}),I[0]&&u.jsx("i",{onClick:()=>T(!P),children:P?I[1]:I[0]}),U,v?u.jsx("em",{children:v}):""]})}function ca({onValue:a,label:_,value:i,title:s,className:f,name:h,text:C,id:v,reload:c}){const[y,n]=j.useState(!!i);j.useEffect(()=>{n(!!i)},[i]);let l=()=>{a&&a({value:y?0:1,name:h,id:v,reload:c}),n(!y)};return u.jsxs(se,{type:"check",title:_||s,element_blok:{className:[f]},element_input:{className:[ee.h],props:{onClick:l}},children:[u.jsx("div",{"aria-checked":`${y?"true":"false"}`}),u.jsx("span",{children:C})]})}const le={};function sa(a){const[_,i]=j.useState({}),s=j.useRef(a);return le.u=f=>{s.current={...s.current,[f.name]:f.value}},le.n=f=>{s.current=f,i(Date.now())},le.r=f=>{f&&f(s.current),i(Date.now())},[s.current,le.n]}function da(a){le.u(a),a.reload&&le.r()}function ua(a){le.r&&le.r(a)}function fa(a){const[_,i]=j.useState({}),s=j.useRef(a);return le.u=f=>{s.current={...s.current,[f.name]:f.value}},le.n=f=>{Object.keys(f).length>0?Object.keys(f).forEach(h=>{s.current[h]=f[h]}):s.current={},i(Date.now())},le.r=()=>{i(Date.now())},[s.current,le.n]}function Ft(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof self<"u"?self:typeof global<"u"?global:{}}Ft().elcrm||(Ft().elcrm={}),Object.assign(Ft().elcrm,{form:Gt.version}),H.Check=ca,H.DateField=rr,H.MaskField=tr,H.ModalField=ia,H.Money=er,H.Month=Jt,H.NumberField=pr,H.OptionsField=aa,H.PasswordField=la,H.PhoneField=ur,H.Progress=Ht,H.SelectField=na,H.StringField=fr,H.TextareaField=_r,H.runReload=ua,H.setValue=da,H.useData=sa,H.useError=fa,Object.defineProperty(H,Symbol.toStringTag,{value:"Module"})});
|
|
1
|
+
(function(e,t){typeof exports==`object`&&typeof module<`u`?t(exports,require(`react`),require(`react/jsx-runtime`),require(`react-dom`)):typeof define==`function`&&define.amd?define([`exports`,`react`,`react/jsx-runtime`,`react-dom`],t):(e=typeof globalThis<`u`?globalThis:e||self,t((e.elCRM=e.elCRM||{},e.elCRM.form={}),e.React,e[`react/jsx-runtime`],e.ReactDOM))})(this,function(e,t,n,r){var i=document.createElement(`style`);i.textContent=`._l_zzcgd_2{min-width:var(--field-width);gap:var(--field-block-gap,0);flex-direction:column;margin:0;padding:0;display:flex;position:relative}._l_zzcgd_2>dt,._l_zzcgd_2>dd{margin:0;padding:0}._l_zzcgd_2[data-field=group] div{cursor:pointer;border-bottom:var(--field-border);padding:var(--field-padding);margin:0}._l_zzcgd_2[data-field=group] div:last-child{border-bottom:0}._l_zzcgd_2 [placeholder]:empty:before{content:attr(placeholder);color:var(--field-placeholder);display:block}._l_zzcgd_2 [placeholder]:focus:before{display:none}._f_zzcgd_33{box-sizing:border-box;align-items:center;gap:var(--field-icon-gap,10px);border:var(--field-border);border-radius:var(--field-radius);background:var(--field-background);color:var(--field-color);padding:0 var(--field-side-padding,14px);transition:border-color .16s,box-shadow .16s,background-color .16s,opacity .16s;display:flex;overflow:hidden}._f_zzcgd_33:hover{border-color:var(--field-border-hover,var(--field-border))}._f_zzcgd_33:focus-within{border-color:var(--field-border-focus,var(--field-border));box-shadow:0 0 0 3px var(--field-focus-ring,#0000);background:var(--field-background-focus,var(--field-background))}._f_zzcgd_33._e_zzcgd_57:focus-within{background:var(--field-error-background);color:var(--field-error-color)}._f_zzcgd_33[data-disabled=true]{background:var(--field-background-disabled,var(--field-background));border-color:var(--field-border-disabled,var(--field-border));color:var(--field-color-disabled,var(--field-placeholder));cursor:not-allowed;opacity:.85}._f_zzcgd_33[data-disabled=true]>*{cursor:not-allowed}._f_zzcgd_33>div{min-height:var(--field-height);line-height:calc(var(--field-height) - 2px);padding:var(--field-inner-padding,0 2px);font-size:var(--control-font-size,14px);text-wrap:pretty;outline:0;flex:1;margin:0}._f_zzcgd_33>div::selection{background:var(--field-selection-bg,#b3d4fc);color:var(--field-selection-color,inherit)}._f_zzcgd_33>:not(div){color:var(--field-icon-color,var(--field-placeholder));flex:none;justify-content:center;align-items:center;display:inline-flex}._f_zzcgd_33>:not(div) svg{width:20px;height:20px}._n_zzcgd_97 div{min-height:var(--field-note-height);line-height:var(--field-note-line-height);padding-top:var(--field-note-padding,var(--field-note-padding-top,8px));padding-bottom:var(--field-note-padding,var(--field-note-padding-top,8px))}._w_zzcgd_104>div{text-wrap:nowrap;overflow:scroll hidden}._w_zzcgd_104>div::-webkit-scrollbar{width:0;height:0}._time_zzcgd_114>div{text-wrap:nowrap;align-items:center;min-width:0;display:flex;overflow:visible}._time_zzcgd_114 ._timeInner_zzcgd_121{justify-content:flex-start;align-items:center;gap:4px;width:100%;min-width:0;display:flex}._time_zzcgd_114._timeAlignCenter_zzcgd_132 ._timeInner_zzcgd_121{justify-content:center}._time_zzcgd_114 ._timeSep_zzcgd_135{opacity:.65;-webkit-user-select:none;user-select:none;flex:none;padding:0 2px;font-weight:500;transform:translateY(-1px)}._time_zzcgd_114 ._timePart_zzcgd_146{box-sizing:border-box;width:1em;min-width:0;color:inherit;font:inherit;line-height:inherit;text-align:left;min-height:var(--field-height);cursor:text;background:0 0;border:0;border-radius:6px;outline:none;flex:none;margin:0;padding:0}._time_zzcgd_114 ._timePart_zzcgd_146[contenteditable=false]{cursor:not-allowed;opacity:.7}._time_zzcgd_114 ._timePart_zzcgd_146:empty:before{content:attr(placeholder);color:var(--field-placeholder);opacity:.6}._time_zzcgd_114 ._timePart_zzcgd_146:focus:empty:before{content:none}._time_zzcgd_114 ._timePart_zzcgd_146:focus-visible{background:0 0}._time_zzcgd_114._timeAlignCenter_zzcgd_132 ._timePart_zzcgd_146{text-align:center}._t_zzcgd_114{color:var(--field-label-color);font-size:var(--field-label-size);padding-bottom:10px}._g_zzcgd_192{flex-direction:column}._range_zzcgd_196>div{box-sizing:border-box;min-width:0;min-height:var(--field-height);flex:1;align-items:center;line-height:normal;display:flex}._range_zzcgd_196 ._rangeTrack_zzcgd_205{box-sizing:border-box;width:100%;height:var(--field-range-bar-height,14px);background:var(--field-range-track,#e0e0e0);cursor:pointer;touch-action:none;border-radius:999px;outline:none;flex-shrink:0;position:relative;overflow:hidden}._range_zzcgd_196 ._rangeTrack_zzcgd_205:focus-visible{box-shadow:0 0 0 3px var(--field-focus-ring,#0000)}._range_zzcgd_196 ._rangeTrack_zzcgd_205[data-disabled=true]{cursor:not-allowed;opacity:.55;pointer-events:none}._range_zzcgd_196 ._rangeFill_zzcgd_226{background:var(--field-range-fill,#00b5ad);pointer-events:none;border-radius:999px 0 0 999px;width:0;min-width:0;height:100%}._range_zzcgd_196 ._rangeFillFull_zzcgd_237{border-radius:999px}._h_zzcgd_241{--field-border:0}._h_zzcgd_241 div{border:var(--field-check-box-border,--field-border);width:var(--field-height);height:var(--field-height);border-radius:var(--field-radius);background:var(--field-background);cursor:pointer;flex:none;gap:10px;margin:0;position:relative}._h_zzcgd_241 div[aria-checked=true]{background:var(--field-background-active)}._h_zzcgd_241 div:after{content:"";background:0 0;border-top:none;border-bottom:3px solid #fcfff4;border-left:3px solid #fcfff4;border-right:none;width:9px;height:5px;margin:4px;position:absolute;top:5px;left:4px;transform:rotate(-45deg)}._e_zzcgd_57{border-color:var(--field-error-border);background:var(--field-error-background);color:var(--field-error-color)}._m_zzcgd_280{color:var(--field-error-color);margin-top:6px;font-size:12px;font-style:normal}._o_j48yg_2{z-index:98;background:0 0;position:fixed;inset:0}._c_j48yg_13{background:var(--select-background);z-index:99;color:#fff;box-sizing:border-box;border-radius:10px;min-width:259px;max-height:min(92vh,480px);margin:0;padding:10px 12px 12px;display:block;position:absolute;overflow:hidden auto;box-shadow:5px 7px 18px #000000a8}._c_j48yg_13 [grid-calendar]{grid-template-columns:repeat(7,1fr);grid-auto-rows:34px;gap:2px;display:grid}._c_j48yg_13 [grid-calendar]>p{color:var(--color-placeholder);box-sizing:border-box;justify-content:center;align-items:center;margin:0;padding:0;font-size:.75rem;font-weight:500;line-height:1;display:flex}._c_j48yg_13 [grid-month]{grid-template-columns:1fr 1fr 1fr 1fr;width:250px;display:grid}._c_j48yg_13 b{cursor:pointer;text-align:center;border-radius:5px;padding:8px 5px;font-weight:400;display:block}._c_j48yg_13 b.__active_j48yg_64{background:var(--bg-select-active)}._c_j48yg_13 b:hover{background:var(--bg-select-hover)}._c_j48yg_13 p{color:var(--color-placeholder);text-align:center;cursor:default;pointer-events:none;padding:0}._c_j48yg_13 i{text-align:center;cursor:pointer;border-radius:5px;flex:0 30px;padding:9px}._c_j48yg_13 i:hover{background:var(--bg-select-hover)}._c_j48yg_13 i:before{cursor:pointer;display:block}._c_j48yg_13 s{align-items:center;gap:4px;padding-bottom:6px;font-style:normal;text-decoration:none;display:flex}._c_j48yg_13 s h2{text-align:center;color:#fff;cursor:default;flex-wrap:nowrap;flex:auto;justify-content:center;align-items:center;gap:8px;min-width:0;margin:0;padding:0;font-size:16px;font-weight:400;line-height:1.25;display:flex}._c_j48yg_13 ._dateHeaderMonth_j48yg_119,._c_j48yg_13 ._dateHeaderYear_j48yg_119{cursor:pointer;-webkit-user-select:none;user-select:none;white-space:nowrap;border-radius:6px;padding:2px 8px}._c_j48yg_13 ._dateHeaderMonth_j48yg_119:hover,._c_j48yg_13 ._dateHeaderYear_j48yg_119:hover{background:var(--bg-select-hover)}._c_j48yg_13 ._dateHeaderDisabled_j48yg_129{cursor:not-allowed;opacity:.45;pointer-events:none}._c_j48yg_13 ._dateHeaderDisabled_j48yg_129[data-active=true],._c_j48yg_13 ._dateHeaderDisabled_j48yg_129[data-current=true]{opacity:.45}._c_j48yg_13 [grid-calendar] b[data-current=true],._c_j48yg_13 [grid-month] b[data-current=true]{background:color-mix(in srgb, var(--field-background-active) 52%, transparent);font-weight:600}._c_j48yg_13 [grid-calendar] b[data-active=true]:not([data-current=true]),._c_j48yg_13 [grid-month] b[data-active=true]:not([data-current=true]){outline:2px solid var(--field-background-active);outline-offset:-2px}._c_j48yg_13 [grid-calendar] b[data-active=true][data-current=true],._c_j48yg_13 [grid-month] b[data-active=true][data-current=true]{box-shadow:inset 0 0 0 2px var(--field-background-active)}._c_j48yg_13 [grid-calendar] p[data-current=true]{background:color-mix(in srgb, var(--field-background-active) 52%, transparent);color:inherit;border-radius:5px;font-weight:600}._c_j48yg_13 [grid-calendar] p[data-active=true]:not([data-current=true]){outline:2px solid var(--field-background-active);outline-offset:-2px;opacity:.85}._c_j48yg_13 [grid-calendar] p[data-active=true][data-current=true]{box-shadow:inset 0 0 0 2px var(--field-background-active)}._c_j48yg_13 span{text-align:center;padding:2px}._c_j48yg_13 span p{color:var(--color-placeholder);padding:8px 5px}._c_j48yg_13 [grid-calendar]>span{box-sizing:border-box;justify-content:stretch;align-items:stretch;min-height:0;padding:0;display:flex}._c_j48yg_13 [grid-calendar]>span>b,._c_j48yg_13 [grid-calendar]>span>p{box-sizing:border-box;border-radius:5px;flex:auto;justify-content:center;align-items:center;width:100%;min-height:0;margin:0;padding:0;display:flex}._c_j48yg_13 ._as_j48yg_196{cursor:ns-resize}._c_j48yg_13 ._ap_j48yg_199{cursor:pointer}[field=password] dd{white-space:nowrap;font-style:unset;-webkit-text-security:disc;-webkit-user-select:text;user-select:text}[field=password][show] dd,[field=password] dd:before{-webkit-text-security:none}[field=code] div{gap:8px;display:flex}[field=select] dd{cursor:pointer}[field] dd:before{pointer-events:none}[field=check] dd{cursor:pointer;max-width:35px;padding:0}[field=check] [active]:after{content:"";background:#394264;border-radius:5px;width:15px;height:15px;display:block}[field=file] input{display:none}[field=file] dd{aspect-ratio:16/9;cursor:pointer;position:relative}[field=file] img{aspect-ratio:16/9;object-fit:contain;cursor:pointer;width:-webkit-fill-available;display:block}[field=file] label{aspect-ratio:16/9;object-fit:contain;cursor:pointer;width:-webkit-fill-available;display:block;position:absolute}[field=color] dd{border:0;gap:3px;padding:0;display:flex}[field=color] dd s{cursor:pointer;opacity:.6;border:1px solid #dde2e4;border-radius:6px;flex:1}[field=color] dd s:hover{opacity:.9}[field=color] dd s[active=true]{opacity:1}:root{--select-overlay:#0000;--select-height:52px;--select-separator:1px solid #40434c;--select-color:#e8e8eb;--select-background:#26282e;--select-icon:calc(--select-height / 1.5);--select-icon-padding:calc((--select-height - --select-icon) / 2);--select-font-size:13px}._o_1q26w_12{z-index:98;background:var(--select-overlay);position:fixed;inset:0}._l_1q26w_22{background:var(--select-background);z-index:99;border-radius:20px;max-height:300px;margin:0;padding:0;display:block;position:fixed;overflow:scroll}._l_1q26w_22::-webkit-scrollbar{width:0;height:0}._l_1q26w_22 ul{width:100%;max-height:300px;margin:0;padding:0;list-style:none;display:block;overflow:hidden auto}._l_1q26w_22 li{border-bottom:var(--select-separator);cursor:pointer;color:var(--select-color);height:var(--select-height);line-height:var(--select-height);font-size:var(--select-font-size);white-space:nowrap;text-overflow:ellipsis;opacity:1;margin:0;padding:0 14px;display:block;overflow:hidden;text-align:left!important;border-left:0!important}._l_1q26w_22 li:hover,._l_1q26w_22 li[data-focus=true]{background:#2f323a}._l_1q26w_22 li:last-child{border-bottom:0}._i_1q26w_80{width:var(--select-icon);height:var(--select-icon);color:var(--field-color);right:var(--select-icon-padding);top:var(--select-icon-padding);position:absolute}._f_1q26w_89{cursor:pointer}._f_1q26w_89[aria-disabled=true]{cursor:not-allowed}
|
|
2
|
+
/*$vite$:1*/`,document.head.appendChild(i),Object.defineProperty(e,Symbol.toStringTag,{value:`Module`});var a=Object.create,o=Object.defineProperty,s=Object.getOwnPropertyDescriptor,c=Object.getOwnPropertyNames,l=Object.getPrototypeOf,u=Object.prototype.hasOwnProperty,d=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=c(t),a=0,l=i.length,d;a<l;a++)d=i[a],!u.call(e,d)&&d!==n&&o(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(r=s(t,d))||r.enumerable});return e};t=((e,t,n)=>(n=e==null?{}:a(l(e)),d(t||!e||!e.__esModule?o(n,`default`,{value:e,enumerable:!0}):n,e)))(t);var f={name:`@elcrm/form`,version:`0.0.64`,description:`React-компоненты полей формы и хук useForm для elCRM: текст, даты, маски, деньги, селект, связка с формой по имени поля (tree-shakeable ESM).`,type:`module`,author:`MaSkal <dev@elcrm.online>`,license:`MIT`,files:[`dist`,`src/lib/styles`],keywords:[`elcrm`,`form`,`react`],main:`./dist/index.umd.js`,module:`./dist/index.js`,types:`./dist/index.d.ts`,exports:{".":{types:`./dist/index.d.ts`,import:`./dist/index.js`,require:`./dist/index.umd.js`},"./fields/*":{types:`./dist/fields/*.d.ts`,import:`./dist/fields/*.js`},"./hooks/*":{types:`./dist/hooks/*.d.ts`,import:`./dist/hooks/*.js`},"./events/*":{types:`./dist/events/*.d.ts`,import:`./dist/events/*.js`},"./core/*":{types:`./dist/core/*.d.ts`,import:`./dist/core/*.js`},"./mask/*":{types:`./dist/mask/*.d.ts`,import:`./dist/mask/*.js`},"./Form":{types:`./dist/Form.d.ts`,import:`./dist/Form.js`},"./FormInitContext":{types:`./dist/FormInitContext.d.ts`,import:`./dist/FormInitContext.js`},"./style.css":{import:`./dist/style.css`,require:`./dist/style.css`},"./light.css":{import:`./src/lib/styles/light.css`,require:`./src/lib/styles/light.css`},"./dark.css":{import:`./src/lib/styles/dark.css`,require:`./src/lib/styles/dark.css`},"./dist/style.css":{import:`./dist/style.css`,require:`./dist/style.css`}},scripts:{dev:`vite --config test/vite.config.ts`,build:`vite build && node scripts/merge-dist-css.mjs && vite build --config vite.umd.config.ts`,test:`vitest run`,"test:watch":`vitest`,"test:build":`vite build --config test/vite.config.ts`,"test:preview":`vite preview --config test/vite.config.ts`},peerDependencies:{react:`>=18`,"react-dom":`>=18`},devDependencies:{"@elcrm/storybook":`^0.0.3`,"@testing-library/dom":`^10.4.1`,"@testing-library/react":`^16.3.2`,"@types/react":`^19.2.14`,"@types/react-dom":`^19.2.3`,"@vitejs/plugin-react":`^6.0.1`,jsdom:`^29.0.1`,react:`^19.2.4`,"react-dom":`^19.2.4`,"sass-embedded":`^1.98.0`,vite:`^8.0.1`,vitest:`^4.1.0`}},p={l:`_l_zzcgd_2`,f:`_f_zzcgd_33`,e:`_e_zzcgd_57`,n:`_n_zzcgd_97`,w:`_w_zzcgd_104`,time:`_time_zzcgd_114`,timeInner:`_timeInner_zzcgd_121`,timeAlignCenter:`_timeAlignCenter_zzcgd_132`,timeSep:`_timeSep_zzcgd_135`,timePart:`_timePart_zzcgd_146`,t:`_t_zzcgd_114`,g:`_g_zzcgd_192`,range:`_range_zzcgd_196`,rangeTrack:`_rangeTrack_zzcgd_205`,rangeFill:`_rangeFill_zzcgd_226`,rangeFillFull:`_rangeFillFull_zzcgd_237`,h:`_h_zzcgd_241`,m:`_m_zzcgd_280`},m=({element_blok:e={className:[]},element_input:t={className:[],props:{}},type:r=`input`,title:i,error:a,before:o,after:s,children:c})=>(0,n.jsxs)(`dl`,{"data-field":r,className:[p.l,...e.className||[]].filter(e=>e!==void 0).join(` `),children:[i?(0,n.jsx)(`dt`,{className:p.t,children:i}):``,o,(0,n.jsx)(`dd`,{className:[p.f,...t.className||[],a&&a.length>0?p.e:``].join(` `),...t.props||{},children:c}),a&&a.length>0?(0,n.jsx)(`em`,{className:p.m,children:a}):``,s]}),h=(e,t)=>Object.is(e,t);function g(e={}){let n=t.default.useRef({...e}),r=t.default.useRef({}),i=t.default.useRef({}),a=t.default.useCallback(e=>{let t=r.current[e];t&&t.forEach(e=>e())},[]),o=t.default.useCallback(e=>{i.current[e]=(i.current[e]||0)+1},[]),s=t.default.useCallback(e=>{!e||!e.name||(n.current[e.name]=e.value)},[]),c=t.default.useCallback(e=>{let t=n.current,r=new Set([...Object.keys(t),...Object.keys(e)]),i={...e};n.current=i,r.forEach(e=>{let n=t[e],r=i[e];h(n,r)||(o(e),a(e))})},[o,a]),l=t.default.useCallback(e=>{!e||!e.name||(n.current[e.name]=e.value,o(e.name),a(e.name))},[o,a]),u=t.default.useCallback((t=e)=>{let r=n.current,i=new Set([...Object.keys(r),...Object.keys(t)]);n.current={...t},i.forEach(e=>{let t=r[e],i=n.current[e];h(t,i)||(o(e),a(e))})},[e,o,a]),d=t.default.useCallback(()=>({...n.current}),[]),f=t.default.useCallback((e,t)=>n.current[e]??t,[]),p=t.default.useCallback(e=>i.current[e]||0,[]),m=t.default.useCallback((e,t)=>(r.current[e]||(r.current[e]=new Set),r.current[e].add(t),()=>{r.current[e]?.delete(t),r.current[e]?.size===0&&delete r.current[e]}),[]),g=t.default.useRef(null);return g.current||={},Object.assign(g.current,{valuesRef:n,getValues:d,setValues:c,setValue:l,onValue:s,reset:u,getValue:f,getVersion:p,subscribe:m}),g.current}function _(e,n,r){let i=t.default.useCallback(t=>!e||!n?()=>{}:e.subscribe(n,t),[e,n]),a=t.default.useCallback(()=>!e||!n?0:e.getVersion(n),[e,n]),o=t.default.useSyncExternalStore(i,a,a);return{value:e&&n?e.getValue(n,r):r,version:o}}function v(e,t,n=``){let{value:r}=_(e,t,n);return r}function y(e,t,n){let r=e;return Number.isFinite(r)||(r=t),Math.min(n,Math.max(t,r))}function b(e,t,n,r){return y(!Number.isFinite(r)||r<=0?e:t+Math.round((e-t)/r)*r,t,n)}function x({value:e=0,form:r,onValue:i,onSave:a,name:o=``,title:s=``,label:c=``,error:l=``,min:u=0,max:d=100,step:f=1,edit:h=!0,active:g=!0,disabled:v=!1,className:x=``,isReload:S=!1}){let{value:C}=_(r,o,e),w=y(Number(C),u,d),T=d===u?0:(w-u)/(d-u)*100,E=T>=99.999,D=h&&g&&!v,O=t.default.useRef(null),k=t.default.useCallback(e=>{let t={value:b(e,u,d,f),name:o||``,reload:S};r&&o&&r.setValue(t),i&&i!==r?.onValue&&i(t)},[r,o,S,i,u,d,f]),A=t.default.useCallback(e=>{let t=O.current;if(!t)return u;let n=t.getBoundingClientRect(),r=n.width||1;return b(u+(e-n.left)/r*(d-u),u,d,f)},[u,d,f]),j=e=>{D&&(e.preventDefault(),e.currentTarget.setPointerCapture(e.pointerId),k(A(e.clientX)))},M=e=>{D&&e.currentTarget.hasPointerCapture(e.pointerId)&&k(A(e.clientX))},N=e=>{try{e.currentTarget.releasePointerCapture(e.pointerId)}catch{}},P=e=>{if(!D)return;let t=w;if(e.key===`ArrowRight`||e.key===`ArrowUp`)t=w+f;else if(e.key===`ArrowLeft`||e.key===`ArrowDown`)t=w-f;else if(e.key===`Home`)t=u;else if(e.key===`End`)t=d;else if(e.key===`PageUp`)t=w+f*10;else if(e.key===`PageDown`)t=w-f*10;else return;e.preventDefault(),k(b(t,u,d,f))},F=()=>{if(!a||!o)return;let t=r&&o?r.getValue(o,e):w;a({value:y(Number(t),u,d),name:o})};return(0,n.jsx)(m,{type:`range`,title:s||c,error:l,element_blok:{className:[x||``]},element_input:{className:[p.w,p.range],props:{"data-disabled":v||!D?`true`:void 0}},children:(0,n.jsx)(`div`,{children:(0,n.jsx)(`div`,{ref:O,className:p.rangeTrack,role:`slider`,tabIndex:D?0:-1,"aria-label":s||c||`Диапазон`,"aria-valuemin":u,"aria-valuemax":d,"aria-valuenow":w,"data-disabled":v||!D?`true`:void 0,onPointerDown:j,onPointerMove:M,onPointerUp:N,onPointerCancel:N,onKeyDown:P,onBlur:F,children:(0,n.jsx)(`div`,{className:E?`${p.rangeFill} ${p.rangeFillFull}`:p.rangeFill,style:{width:`${T}%`},"aria-hidden":!0})})})})}x.displayName=`RangeField`;var S=e=>{let t=window.getSelection();if(!t||t.rangeCount===0)return;let n=t.getRangeAt(0);n.deleteContents(),n.insertNode(document.createTextNode(e)),n.collapse(!1),t.removeAllRanges(),t.addRange(n)};function C(e,t){S(e),t.dispatchEvent(new Event(`input`,{bubbles:!0}))}var w=e=>{let t=window.getSelection();if(!t)return;let n=document.createRange();n.selectNodeContents(e),n.collapse(!1),t.removeAllRanges(),t.addRange(n)},T=(e,t,n)=>{if(!t)return e;let r=window.getSelection(),i=0;if(r&&r.rangeCount>0){let e=r.getRangeAt(0);n.contains(e.commonAncestorContainer)&&(i=e.toString().length)}let a=t-((n.textContent||``).length-i);return a<=0?``:e.slice(0,a)};function E(e){queueMicrotask(()=>{e.dispatchEvent(new Event(`input`,{bubbles:!0}))})}var D={KeyDown(e){e.key===`Enter`&&e.preventDefault()},PasteOne(e){e.preventDefault(),S(e.clipboardText.replace(/\D/g,``)),E(e.target)},Paste(e,t){t.preventDefault();let n=T(t.clipboardText,e,t.target);n&&(S(n.replace(/(\r\n|\n|\r)/gm,` `)),E(t.target))},PasteDigits(e,t){t.preventDefault();let n=T(t.clipboardText.replace(/\D/g,``),e,t.target);n&&(S(n),E(t.target))},Focus(e){(e.target.textContent||``).length||(e.target.innerHTML=`<br>`),w(e.target)},Blur(e){e.target.scrollLeft=0,e.target.querySelector(`br`)!==null&&e.target.querySelector(`br`)?.remove()}},O=`plaintext-only`;function k(e){return{preventDefault:()=>e.preventDefault(),target:e.currentTarget,clipboardText:e.clipboardData?.getData(`text/plain`)??``}}var A={...D,ContentEditable:O};function j(e){let t=window.getSelection();if(!t||t.rangeCount===0)return 0;let n=t.getRangeAt(0);if(!e.contains(n.startContainer))return 0;let r=document.createRange();return r.selectNodeContents(e),r.setEnd(n.startContainer,n.startOffset),r.toString().length}function M(e,t,n){let r=Math.max(0,Math.min(t,e.length));return n(e.slice(0,r)).length}function N({value:e,form:t,onValue:r,name:i,placeholder:a=``,title:o=``,error:s=``,hide:c=!1,edit:l=!0,active:u=!0,after:d=``,show:f=!0,course:h=100,view:g,type:v,onSave:y,className:b=``,isClear:x=!1,disabled:S=!1}){let{value:w,version:T}=_(t,i||``,e),E=t&&i?w:e,D=!!(c&&(E===``||E==null)),O=e=>v===`multi`?e.replace(/[^+\d.+-]/g,``):e.replace(/[^+\d.]/g,``),k=(e,t)=>{let n=t.firstChild;if(!n||n.nodeType!==Node.TEXT_NODE)return;let r=n.textContent?.length??0,i=Math.max(0,Math.min(e,r)),a=document.createRange(),o=window.getSelection();o&&(a.setStart(n,i),a.collapse(!0),o.removeAllRanges(),o.addRange(a),t.focus())},N=e=>{let n=e.target,a=n.textContent||``,o=j(n),s=O(a),c=M(a,o,O),l={value:Number(s||0)*h,name:i};t&&i&&t.onValue(l),r&&r!==t?.onValue&&r(l),n.textContent=s,s.length>0&&queueMicrotask(()=>{k(Math.min(c,s.length),n)})},F=e=>{let n=e.target;A.Blur(e),(n.textContent||``)===``&&(n.textContent=`0`);let a={value:Number(O(n.textContent||``))*h,name:i};y?.(a),t&&i&&t.setValue(a),r&&r!==t?.onValue&&r(a),n.textContent=P(n.textContent||``)},I=e=>{let t=e.target;t.textContent=O(t.textContent||``),A.Focus({target:e.currentTarget})},L=e=>{let n=e.currentTarget.previousElementSibling;n&&(n.textContent=``);let a={value:0,name:i};t&&i&&t.setValue(a),r&&r!==t?.onValue&&r(a)},R=e=>{e.key===`Enter`&&e.preventDefault()},z=e=>{e.preventDefault(),C(O(e.clipboardData?.getData(`text/plain`)??``),e.currentTarget)};if(!(l&&u)&&!f||!(l&&u)&&D)return``;let B={};return B.inputMode=`decimal`,a&&(B.placeholder=a),l&&u&&(B.edit=``),(0,n.jsxs)(m,{type:`input`,title:o,element_blok:{className:[b]},element_input:{className:[p.w]},children:[(0,n.jsx)(`div`,{...B,onInput:N,onPaste:z,onBlur:F,onKeyDown:R,onFocus:I,role:`textbox`,"aria-label":o||a||`Сумма`,"aria-disabled":S||!(l&&u),tabIndex:S?-1:0,contentEditable:l&&u&&!S?`plaintext-only`:!1,suppressContentEditableWarning:!0,"data-after":d,children:!a||E?P(E??``):``},T),x&&(0,n.jsx)(`button`,{type:`button`,onClick:L,"aria-label":`Очистить поле`,children:`x`})]})}N.displayName=`MoneyField`;function P(e,t){return t&&(e=Number(e)/t),parseFloat(String(e||0)).toFixed(2).replace(/(\d)(?=(\d{3})+\.)/g,`$1 `)}function F(e){let t=window.getSelection();if(!t||t.rangeCount===0)return 0;let n=t.getRangeAt(0);if(!e.contains(n.startContainer))return 0;let r=document.createRange();return r.selectNodeContents(e),r.setEnd(n.startContainer,n.startOffset),r.toString().length}function I(e,t){if(t<=0)return 0;let n=0;for(let r=0;r<e.length;r++)if(/\d/.test(e[r])&&(n++,n===t))return r+1;return e.length}function L({value:e=``,form:t,onValue:r,onSave:i,name:a=``,format:o=`+_(___) ___-__-__`,placeholder:s=``,title:c=``,error:l=``,hide:u=!1,edit:d=!0,active:f=!0,after:h=``,show:g=!0,view:v,className:y=``,disabled:b=!1}){d=d===void 0?!0:d,f=f===void 0?!0:f;let{value:x,version:S}=_(t,a,e);u=!!(u&&(x===``||x===void 0))&&!(d&&f);let C=o,w=!0,T=0,E=(e,t)=>{let n=t.firstChild;if(!n||n.nodeType!==Node.TEXT_NODE)return;let r=n.textContent?.length??0,i=Math.max(0,Math.min(e,r)),a=document.createRange(),o=window.getSelection();o&&(a.setStart(n,i),a.collapse(!0),o.removeAllRanges(),o.addRange(a),t.focus())},D=e=>A.PasteOne(k(e)),O=e=>{C=o,w=!0,T=0;let t=0,n=``,r=e.replace(/\D/g,``);r===``&&(w=!0);let i=r.split(``),a=``;i.forEach(e=>{w&&(a+=e,w&&(T=(``+a).length,C=o.replace(RegExp(`[0-9]`,`g`),`_`),n=``),T>(``+a).length&&(w=!0,C=o.replace(RegExp(`[0-9]`,`g`),`_`),n=``))});let s=C.replace(/\D/g,``);return s.length>=r.length&&(r=s),{q:C.replace(/[_\d]/g,function(){return r.charAt(t++)||`_`}),i:t,v:r,f:n}},j=O(String(x||``)),M=e=>{let n=e.target,i=n.textContent||``,o=F(n),s=i.slice(0,o).replace(/\D/g,``).length,c=O(i);n.textContent=c.q;let l=I(c.q,s);c.q.length>0&&queueMicrotask(()=>{E(Math.min(l,c.q.length),n)});let u={value:c.q.replace(/\D/g,``),name:a};t&&a&&t.onValue(u),r&&r!==t?.onValue&&r(u)},N=e=>{e.key===`Enter`&&e.preventDefault()},P=e=>{A.Blur(e),i&&i({value:(e.target.textContent??``).replace(/\D/g,``),name:a})},L=e=>{A.Focus({target:e.currentTarget})},R={};return s&&(R.placeholder=s),u?(0,n.jsx)(n.Fragment,{}):(0,n.jsx)(m,{type:`input`,title:c,element_blok:{className:[y]},element_input:{className:[p.w]},children:(0,n.jsx)(`div`,{onPaste:D,onInput:M,onKeyDown:N,onBlur:P,onFocus:L,role:`textbox`,"aria-label":c||s||a||`Маска`,"aria-disabled":b||!(d&&f),tabIndex:b?-1:0,"data-disabled":b||!(d&&f),contentEditable:d&&f&&!b?`plaintext-only`:!1,suppressContentEditableWarning:!0,...R,children:j.q},S)})}L.displayName=`MaskField`;var R={o:`_o_j48yg_2`,c:`_c_j48yg_13`,_active:`__active_j48yg_64`,dateHeaderMonth:`_dateHeaderMonth_j48yg_119`,dateHeaderYear:`_dateHeaderYear_j48yg_119`,dateHeaderDisabled:`_dateHeaderDisabled_j48yg_129`,as:`_as_j48yg_196`,ap:`_ap_j48yg_199`};function z(e,t,n,r){let i=new Date(e,t-1,1);return!(n&&new Date(e,t,0)<n||r&&i>r)}function B(e,t,n){return!(t&&e<t.getFullYear()||n&&e>n.getFullYear())}function V(e,t,n){let r=e;if(t){let e=t.getFullYear();r+11<e&&(r=e-11),r<e&&(r=e)}if(n){let e=n.getFullYear();r>e&&(r=e-11),r+11>e&&(r=e-11)}return r}function H({title:e,label:i=``,error:a,edit:o=!0,active:s=!0,className:c,placeholder:l,max:u,min:d,onValue:f,form:h,icon:g,name:v=``,value:y,after:b,disabled:x=!1}){let S=t.default.useCallback(e=>e==null?new Date:e instanceof Date||typeof e==`string`||typeof e==`number`?e:new Date,[]),{value:C,version:w}=_(h,v,y),[T,E]=t.default.useState(S(C)),D=t.default.useRef({x:0,y:0,b:0}),[O,k]=t.default.useState(!1),A=!o&&s;t.default.useEffect(()=>{E(S(C))},[C,w,S]);let j=e=>{let t={value:e,name:v};h&&v?h.setValue(t):E(e),f&&f!==h?.onValue&&f(t)},M=e=>{if(x||!(o&&s))return;let t=e.currentTarget.getBoundingClientRect();D.current={x:t.left,b:t.bottom,y:t.top},k(!0)},N={};return l&&(N.placeholder=l),A?(0,n.jsx)(n.Fragment,{}):(0,n.jsxs)(n.Fragment,{children:[g?g():(0,n.jsxs)(m,{type:`date`,title:e||i,error:a,element_blok:{className:[c||``]},element_input:{className:[p.w],props:{"data-disabled":x||!(o&&s)?`true`:void 0}},children:[(0,n.jsx)(`div`,{onClick:M,onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),M(e))},tabIndex:x||!(o&&s)?-1:0,role:`button`,"aria-haspopup":`dialog`,"aria-expanded":O,"aria-label":e||i||l||`Дата`,"data-edit":o&&s?`true`:void 0,...N,style:{cursor:x||!(o&&s)?`not-allowed`:`pointer`},children:ee(T,`dd.mm.yyyy`)},w),b]}),O&&(0,r.createPortal)((0,n.jsx)(U,{position:D.current,onValue:j,date:T,max:u,min:d,onOpen:k,className:c},new Date().getTime()),document.body)]})}H.displayName=`DateField`;var U=({date:e,onValue:r,position:i,max:a,min:o,className:s,onOpen:c})=>{let l=new Date,u=new Date(e),d={y:l.getFullYear(),d:l.getDate(),m:l.getMonth()+1},f={y:u.getFullYear(),d:u.getDate(),m:u.getMonth()+1},[p,m]=t.default.useState({y:f.y,m:f.m}),[h,g]=t.default.useState(`days`),[_,v]=t.default.useState(()=>V(f.y-5,o,a)),y=e=>{let t=e.getDay();return t===0&&(t=7),t-1},b=[`пн`,`вт`,`ср`,`чт`,`пт`,`сб`,`вс`],x=p.m-1,S=new Date(p.y,x),C=[];for(let e=0;e<y(S);e++)C.push(0);for(;S.getMonth()===x;)C.push(S.getDate()),S.setDate(S.getDate()+1);let w=()=>{c(!1)},T=()=>{N(p.m+1,p.y)},E=()=>{N(p.m-1,p.y)},D=()=>{h===`days`?E():h===`months`?N(p.m,p.y-1):v(e=>V(e-12,o,a))},O=()=>{h===`days`?T():h===`months`?N(p.m,p.y+1):v(e=>V(e+12,o,a))},k=e=>{e.stopPropagation(),v(V(p.y-5,o,a)),g(`years`)},A=e=>{z(p.y,e,o,a)&&(m({y:p.y,m:e}),g(`days`))},j=e=>{B(e,o,a)&&(m({y:e,m:p.m}),g(`days`))},M=e=>{r(p.y+`-`+G(2,p.m)+`-`+G(2,e)),w()},N=(e,t)=>{t=e>12?t+1:e<1?t-1:t,e=e>12?1:e<1?12:e,m({y:t,m:e})},P=e=>d.y===p.y&&d.m===p.m&&d.d===e?{"data-active":`true`}:{},F=e=>f.y===p.y&&f.m===p.m&&f.d===e?{"data-current":`true`}:{},I=e=>{let t=!0;return a&&a.getTime()<new Date(p.y,p.m-1,e).getTime()&&(t=!1),o&&o.getTime()>new Date(p.y,p.m-1,e).getTime()&&(t=!1),t},L=window.innerHeight-i.b<360?Math.max(8,i.y-360):i.b,H=window.innerWidth-i.x<270?i.x-246:i.x;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(`div`,{className:R.o,onClick:()=>w()}),(0,n.jsxs)(`div`,{className:[R.c,s&&s+`-backdrop`].join(` `),style:{top:L+`px`,left:H+`px`},onClick:e=>e.stopPropagation(),children:[(0,n.jsxs)(`s`,{children:[(0,n.jsx)(`i`,{onClick:e=>{e.stopPropagation(),D()},children:(0,n.jsx)(`svg`,{width:`16`,height:`16`,fill:`currentColor`,viewBox:`0 0 24 24`,xmlns:`http://www.w3.org/2000/svg`,children:(0,n.jsx)(`path`,{d:`m15.09 4.594-7.646 6.553a1.126 1.126 0 0 0 0 1.708l7.647 6.552c.73.625 1.857.107 1.857-.854V5.447c0-.961-1.127-1.48-1.857-.853Z`})})}),(0,n.jsxs)(`h2`,{children:[(0,n.jsx)(`span`,{className:R.dateHeaderMonth,onClick:e=>{e.stopPropagation(),g(h===`years`?`months`:h===`months`?`days`:`months`)},title:h===`years`?`К списку месяцев`:h===`months`?`К календарю`:`Выбрать месяц`,children:W(p.m).name}),(0,n.jsx)(`span`,{className:R.dateHeaderYear,onClick:e=>{e.stopPropagation(),h===`years`?g(`days`):k(e)},title:h===`years`?`К календарю`:`Выбрать год`,children:p.y})]}),(0,n.jsx)(`i`,{onClick:e=>{e.stopPropagation(),O()},children:(0,n.jsx)(`svg`,{width:`16`,height:`16`,fill:`currentColor`,viewBox:`0 0 24 24`,xmlns:`http://www.w3.org/2000/svg`,children:(0,n.jsx)(`path`,{d:`m8.91 19.406 7.646-6.552a1.125 1.125 0 0 0 0-1.709L8.91 4.593c-.73-.625-1.857-.107-1.857.854v13.107c0 .96 1.127 1.479 1.857.852Z`})})})]}),h===`days`&&(0,n.jsxs)(`div`,{"grid-calendar":``,children:[b.map((e,t)=>(0,n.jsx)(`p`,{children:e},`v`+t)),C.map((e,t)=>(0,n.jsx)(`span`,{children:e!==0&&I(e)?(0,n.jsx)(`b`,{...P(e),...F(e),onClick:()=>M(e),children:e}):(0,n.jsx)(`p`,{...P(e),...F(e),children:e===0?``:e})},t))]}),h===`months`&&(0,n.jsx)(`div`,{"grid-month":``,children:Array.from({length:12},(e,t)=>{let r=t+1,i=z(p.y,r,o,a),s=d.y===p.y&&d.m===r?{"data-active":`true`}:{},c=f.y===p.y&&f.m===r?{"data-current":`true`}:{};return(0,n.jsx)(`b`,{className:i?``:R.dateHeaderDisabled,...s,...c,onClick:()=>i&&A(r),children:W(r).abc},r)})}),h===`years`&&(0,n.jsx)(`div`,{"grid-month":``,children:Array.from({length:12},(e,t)=>{let r=_+t,i=B(r,o,a),s=d.y===r?{"data-active":`true`}:{},c=f.y===r?{"data-current":`true`}:{};return(0,n.jsx)(`b`,{className:i?``:R.dateHeaderDisabled,...s,...c,onClick:()=>i&&j(r),children:r},r)})})]})]})};function W(e){return e=typeof e==`number`?e:new Date(e).getMonth()+1,{1:{val:`01`,name:`Январь`,names:`Января`,abc:`Янв`},2:{val:`02`,name:`Февраль`,names:`Февраля`,abc:`Февр`},3:{val:`03`,name:`Март`,names:`Марта`,abc:`Март`},4:{val:`04`,name:`Апрель`,names:`Апреля`,abc:`Апр`},5:{val:`05`,name:`Май`,names:`Мая`,abc:`Май`},6:{val:`06`,name:`Июнь`,names:`Июня`,abc:`Июнь`},7:{val:`07`,name:`Июль`,names:`Июля`,abc:`Июль`},8:{val:`08`,name:`Август`,names:`Августа`,abc:`Авг`},9:{val:`09`,name:`Сентябрь`,names:`Сентября`,abc:`Сент`},10:{val:`10`,name:`Октябрь`,names:`Октября`,abc:`Окт`},11:{val:`11`,name:`Ноябрь`,names:`Ноября`,abc:`Нояб`},12:{val:`12`,name:`Декабрь`,names:`Декабря`,abc:`Дек`}}[e]}function G(e,t){let n=t+``;for(;n.length<e;)n=`0`+n;return n}function ee(e,t){let n,r;t===void 0?(r=String(e),n=new Date):(r=t,n=new Date(e));let i=r,a={yyyy:n.getFullYear(),yy:(``+n.getFullYear()).slice(-2),mm:(`0`+(n.getMonth()+1)).slice(-2),dd:(`0`+n.getDate()).slice(-2),HH:(`0`+n.getHours()).slice(-2),MM:(`0`+n.getMinutes()).slice(-2),SS:(`0`+n.getSeconds()).slice(-2),__:` \xA0\xA0\xA0\xA0 `,_:` \xA0\xA0 `};for(let e in a)i=i.replace(e,String(a[e]));return i}function te(e){let t=window.getSelection();if(!t||t.rangeCount===0)return 0;let n=t.getRangeAt(0);if(!e.contains(n.startContainer))return 0;let r=document.createRange();return r.selectNodeContents(e),r.setEnd(n.startContainer,n.startOffset),r.toString().length}function K(e,t){let n=t.firstChild;if(!n||n.nodeType!==Node.TEXT_NODE)return;let r=n.textContent?.length??0,i=Math.max(0,Math.min(e,r)),a=document.createRange(),o=window.getSelection();o&&(a.setStart(n,i),a.collapse(!0),o.removeAllRanges(),o.addRange(a),t.focus())}function q(e){return String(e).padStart(2,`0`)}function J(e){return(e||``).replace(/\D/g,``)}function Y(e){if(e==null||e===``||typeof e!=`string`)return``;let t=e.trim(),n=/^(\d{1,2}):(\d{2})(?::(\d{2}))?$/.exec(t);if(!n)return``;let r=Math.min(23,Math.max(0,parseInt(n[1],10))),i=Math.min(59,Math.max(0,parseInt(n[2],10)));return`${q(r)}:${q(i)}`}function X(e){let t=Y(e);if(!t)return{h:null,m:null};let[n,r]=t.split(`:`).map(e=>parseInt(e,10));return{h:n,m:r}}function ne(e,t){if(e===null&&t===null)return``;let n=e??0,r=t??0;return`${q(n)}:${q(r)}`}function re(e,t){let n=J(e).slice(0,2);if(n===``)return null;let r=parseInt(n,10);return Number.isNaN(r)?null:Math.min(t,Math.max(0,r))}function ie(e){let t=Y(e);if(!t)return null;let[n,r]=t.split(`:`).map(e=>parseInt(e,10));return n*60+r}function ae(e,t){let n=Math.max(1,Math.round(t/60));if(n<=1)return e;let r=Math.round(e/n)*n;return Math.min(59,Math.max(0,r))}function oe(e,t,n){let r=Y(e);if(!r)return``;let i=ie(r);if(i===null)return``;if(t){let e=ie(t);e!==null&&(i=Math.max(i,e))}if(n){let e=ie(n);e!==null&&(i=Math.min(i,e))}return ne(Math.floor(i/60),i%60)}function se({value:e=``,form:r,onValue:i,onSave:a,name:o=``,title:s=``,label:c=``,error:l=``,placeholder:u=``,step:d=60,min:f,max:h,edit:g=!0,active:v=!0,disabled:y=!1,className:b=``,isReload:x=!1,id:S,spellCheck:C=!1,align:w=`start`}){let{value:T,version:E}=_(r,o,e),D=Y(T),O=g&&v&&!y,k=t.default.useRef(null),j=t.default.useRef(null),M=t.default.useRef(null),[N,P]=t.default.useState(!1);t.default.useLayoutEffect(()=>{if(!N||!O)return;let{h:e,m:t}=X(D),n=(e,t)=>{e&&(t===null?e.innerHTML=`<br>`:e.textContent=String(t))};n(k.current,e),n(j.current,t)},[N,D,E,O]);let F=t.default.useCallback(()=>{let e=re(k.current?.textContent||``,23),t=re(j.current?.textContent||``,59);if(e===null&&t===null)return``;let n=ne(e,t);if(!n)return``;let{h:r,m:i}=X(n);return i!==null&&(n=ne(r,ae(i,d))),n&&=oe(n,f,h),n||``},[f,h,d]),I=e=>t=>{if(t.preventDefault(),!O)return;let n=J(t.clipboardData?.getData(`text/plain`)??``),r=e===`hour`?23:59;if(n.length>=4){let e=Math.min(23,Math.max(0,parseInt(n.slice(0,2),10))),t=Math.min(59,Math.max(0,parseInt(n.slice(2,4),10))),r=k.current,i=j.current;r&&(r.textContent=String(e),queueMicrotask(()=>K(String(e).length,r))),i&&(i.textContent=String(t),queueMicrotask(()=>K(String(t).length,i)));return}let i=n.slice(0,2),a=t.currentTarget;if(i===``){a.innerHTML=`<br>`,queueMicrotask(()=>K(0,a));return}let o=parseInt(i,10);if(Number.isNaN(o))return;let s=String(Math.min(r,Math.max(0,o)));a.textContent=s,queueMicrotask(()=>K(s.length,a))},L=e=>{let t=e.target,n=t.textContent||``,r=te(t),i=n.slice(0,r).replace(/\D/g,``).length,a=J(n).slice(0,2);if(a===``){t.innerHTML=`<br>`,queueMicrotask(()=>K(0,t));return}let o=parseInt(a,10);if(Number.isNaN(o))return;let s=String(Math.min(23,Math.max(0,o)));t.textContent=s;let c=Math.min(i,s.length);queueMicrotask(()=>K(c,t))},R=e=>{let t=e.target,n=t.textContent||``,r=te(t),i=n.slice(0,r).replace(/\D/g,``).length,a=J(n).slice(0,2);if(a===``){t.innerHTML=`<br>`,queueMicrotask(()=>K(0,t));return}let o=parseInt(a,10);if(Number.isNaN(o))return;let s=String(Math.min(59,Math.max(0,o)));t.textContent=s;let c=Math.min(i,s.length);queueMicrotask(()=>K(c,t))},z=e=>{(e.key===`Enter`||e.key===`:`)&&(e.preventDefault(),j.current?.focus())},B=e=>{e.key===`Enter`&&e.preventDefault()},V=e=>{let t=e.currentTarget;(t.textContent||``).trim().length||(t.innerHTML=`<br>`),O&&P(!0)},H=e=>{A.Blur(e)};t.default.useEffect(()=>{let e=M.current;if(!e)return;let t=t=>{let n=t.relatedTarget;if(n&&e.contains(n))return;let i=F();r&&o&&r.setValue({name:o,value:i,reload:x}),a&&o&&a({value:i,name:o}),P(!1)};return e.addEventListener(`focusout`,t),()=>e.removeEventListener(`focusout`,t)},[r,o,a,f,h,d,x,F]);let{h:U,m:W}=X(D),G={};return u&&(G.placeholder=u),O&&(G.edit=``),(0,n.jsx)(m,{type:`time`,title:s||c,error:l,element_blok:{className:[b||``]},element_input:{className:[p.w,p.time,w===`center`?p.timeAlignCenter:``].filter(Boolean),props:{"data-disabled":y||!O?`true`:void 0}},children:(0,n.jsxs)(`div`,{ref:M,className:p.timeInner,role:`group`,"aria-label":s||c||`Время`,children:[(0,n.jsx)(`div`,{id:S,ref:k,className:p.timePart,contentEditable:O?`plaintext-only`:!1,suppressContentEditableWarning:!0,spellCheck:C,inputMode:`numeric`,onPaste:I(`hour`),onInput:L,onKeyDown:z,onFocus:V,onBlur:H,"aria-label":`Часы, 0–23`,...G,children:!O||!N?U===null?``:q(U):null}),(0,n.jsx)(`span`,{className:p.timeSep,"aria-hidden":`true`,children:`:`}),(0,n.jsx)(`div`,{ref:j,className:p.timePart,contentEditable:O?`plaintext-only`:!1,suppressContentEditableWarning:!0,spellCheck:C,inputMode:`numeric`,onPaste:I(`minute`),onInput:R,onKeyDown:B,onFocus:V,onBlur:H,"aria-label":`Минуты, 0–59`,...G,children:!O||!N?W===null?``:q(W):null})]},E)})}se.displayName=`TimeField`;function ce({value:e,form:t,onValue:r,name:i,placeholder:a=``,title:o=``,label:s=``,hide:c=!1,edit:l=!0,active:u=!0,after:d=``,show:f=!0,maxLength:h,error:g=``,onSave:v,className:y=``,isCopy:b=!0}){let{value:x,version:S}=_(t,i||``,e),C=e=>{let n={value:e.currentTarget.innerText,name:i||``};t&&i&&t.onValue(n),r&&r!==t?.onValue&&r(n)},w=e=>{let t=(e.currentTarget.textContent??``).trim();h&&t.length>=h&&e.key!==`Backspace`&&e.preventDefault(),e.key===`Enter`&&!e.shiftKey&&e.preventDefault()},T=e=>A.Paste(h||0,k(e));if(c)return(0,n.jsx)(n.Fragment,{});if(!(l&&u)&&!f)return``;let E={};return a&&(E.placeholder=a),l&&u&&(E.edit=``),(0,n.jsx)(m,{type:`note`,title:o||s,error:g,element_blok:{className:[y||``]},element_input:{className:[p.n]},children:(0,n.jsx)(`div`,{onPaste:T,onInput:C,onBlur:e=>{A.Blur(e),v?.({value:(e.currentTarget.textContent??``).trim(),name:i||``})},onKeyDown:w,contentEditable:l&&u?`plaintext-only`:!1,suppressContentEditableWarning:!0,...E,children:x},S)})}ce.displayName=`TextareaField`;var le=Object.freeze({0:{name:`Heard Island and Mcdonald Islands`,dial_code:`+0`,code:`HM`,mask:`+0(___) ___-__-__`},1:{name:`United States`,dial_code:`+1`,code:`US`,mask:`+1(___) ___-__-__`},7:{name:`Russia`,dial_code:`+7`,code:`RU`,mask:`+7(___) ___-__-__`},20:{name:`Egypt`,dial_code:`+20`,code:`EG`,mask:`+20(___) ___-__-__`},27:{name:`South Africa`,dial_code:`+27`,code:`ZA`,mask:`+27(___) __-__-__`},30:{name:`Greece`,dial_code:`+30`,code:`GR`,mask:`+30(___) ___-__-__`},31:{name:`Netherlands`,dial_code:`+31`,code:`NL`,mask:`+31(___) __-__-__`},32:{name:`Belgium`,dial_code:`+32`,code:`BE`,mask:`+32(___) __-__-__`},33:{name:`France`,dial_code:`+33`,code:`FR`,mask:`+33(___) __-__-__`},34:{name:`Spain`,dial_code:`+34`,code:`ES`,mask:`+34(___) __-__-__`},36:{name:`Hungary`,dial_code:`+36`,code:`HU`,mask:`+36(___) __-__-__`},39:{name:`Italy`,dial_code:`+39`,code:`IT`,mask:`+39(___) ___-__-__`},40:{name:`Romania`,dial_code:`+40`,code:`RO`,mask:`+40(___) __-__-__`},41:{name:`Switzerland`,dial_code:`+41`,code:`CH`,mask:`+41(___) __-__-__`},43:{name:`Austria`,dial_code:`+43`,code:`AT`,mask:`+43(__) ___-__-__`},44:{name:`United Kingdom`,dial_code:`+44`,code:`GB`,mask:`+44(___) ___-__-__`},45:{name:`Denmark`,dial_code:`+45`,code:`DK`,mask:`+45(__) __-__-__`},46:{name:`Sweden`,dial_code:`+46`,code:`SE`,mask:`+46(___) __-__-__`},47:{name:`Svalbard and Jan Mayen`,dial_code:`+47`,code:`SJ`,mask:`+47(__) __-__-__`},48:{name:`Poland`,dial_code:`+48`,code:`PL`,mask:`+48(__) __-__-__`},49:{name:`Germany`,dial_code:`+49`,code:`DE`,mask:`+49(___) ___-__-__`},51:{name:`Peru`,dial_code:`+51`,code:`PE`,mask:`+51(___) __-__-__`},52:{name:`Mexico`,dial_code:`+52`,code:`MX`,mask:`+52(__-__) ___-__-__`},53:{name:`Cuba`,dial_code:`+53`,code:`CU`,mask:`+53(__) __-__-__`},54:{name:`Argentina`,dial_code:`+54`,code:`AR`,mask:`+54(__-__) ___-__-__`},55:{name:`Brazil`,dial_code:`+55`,code:`BR`,mask:`+55(___) ___-__-__`},56:{name:`Chile`,dial_code:`+56`,code:`CL`,mask:`+56(___) __-__-__`},57:{name:`Colombia`,dial_code:`+57`,code:`CO`,mask:`+57(___) ___-__-__`},58:{name:`Venezuela, Bolivarian Republic of Venezuela`,dial_code:`+58`,code:`VE`,mask:`+58(___) ___-__-__`},60:{name:`Malaysia`,dial_code:`+60`,code:`MY`,mask:`+60(___) __-__-__`},61:{name:`Cocos (Keeling) Islands`,dial_code:`+61`,code:`CC`,mask:`+61(___) ___-__-__`},62:{name:`Indonesia`,dial_code:`+62`,code:`ID`,mask:`+62(___) __-__-__`},63:{name:`Philippines`,dial_code:`+63`,code:`PH`,mask:`+63(___) ___-__-__`},64:{name:`Pitcairn`,dial_code:`+64`,code:`PN`,mask:`+64(___) __-__-__`},65:{name:`Singapore`,dial_code:`+65`,code:`SG`,mask:`+65(__) __-__-__`},66:{name:`Thailand`,dial_code:`+66`,code:`TH`,mask:`+66(___) __-__-__`},77:{name:`Kazakhstan`,dial_code:`+77`,code:`KZ`,mask:`+77(__) ___-__-__`},81:{name:`Japan`,dial_code:`+81`,code:`JP`,mask:`+81(___) ___-__-__`},82:{name:`Korea, Republic of South Korea`,dial_code:`+82`,code:`KR`,mask:`+82(___) ___-__-__`},84:{name:`Vietnam`,dial_code:`+84`,code:`VN`,mask:`+84(___) __-__-__`},86:{name:`China`,dial_code:`+86`,code:`CN`,mask:`+86(__-__) ___-__-__`},90:{name:`Turkey`,dial_code:`+90`,code:`TR`,mask:`+90(___) ___-__-__`},91:{name:`India`,dial_code:`+91`,code:`IN`,mask:`+91(___) ___-__-__`},92:{name:`Pakistan`,dial_code:`+92`,code:`PK`,mask:`+92(___) ___-__-__`},93:{name:`Afghanistan`,dial_code:`+93`,code:`AF`,mask:`+93(__) ___-__-__`},94:{name:`Sri Lanka`,dial_code:`+94`,code:`LK`,mask:`+94(___) __-__-__`},95:{name:`Myanmar`,dial_code:`+95`,code:`MM`,mask:`+95(___) ___-__-__`},98:{name:`Iran, Islamic Republic of Persian Gulf`,dial_code:`+98`,code:`IR`,mask:`+98(___) ___-__-__`},211:{name:`South Sudan`,dial_code:`+211`,code:`SS`,mask:`+211(___) ___-__-__`},212:{name:`Morocco`,dial_code:`+212`,code:`MA`,mask:`+212(___) __-__-__`},213:{name:`Algeria`,dial_code:`+213`,code:`DZ`,mask:`+213(__) ___-__-__`},216:{name:`Tunisia`,dial_code:`+216`,code:`TN`,mask:`+216(__) __-__-__`},218:{name:`Libyan Arab Jamahiriya`,dial_code:`+218`,code:`LY`,mask:`+218(___) ___-__-__`},220:{name:`Gambia`,dial_code:`+220`,code:`GM`,mask:`+220(___) __-__`},221:{name:`Senegal`,dial_code:`+221`,code:`SN`,mask:`+221(___) __-__-__`},222:{name:`Mauritania`,dial_code:`+222`,code:`MR`,mask:`+222(__) __-__-__`},223:{name:`Mali`,dial_code:`+223`,code:`ML`,mask:`+223(__) __-__-__`},224:{name:`Guinea`,dial_code:`+224`,code:`GN`,mask:`+224(__) __-__-__`},225:{name:`Cote d'Ivoire`,dial_code:`+225`,code:`CI`,mask:`+225(__) __-__-__`},226:{name:`Burkina Faso`,dial_code:`+226`,code:`BF`,mask:`+226(__) __-__-__`},227:{name:`Niger`,dial_code:`+227`,code:`NE`,mask:`+227(__) __-__-__`},228:{name:`Togo`,dial_code:`+228`,code:`TG`,mask:`+228(__) __-__-__`},229:{name:`Benin`,dial_code:`+229`,code:`BJ`,mask:`+229(__) __-__-__`},230:{name:`Mauritius`,dial_code:`+230`,code:`MU`,mask:`+230(___) __-__`},231:{name:`Liberia`,dial_code:`+231`,code:`LR`,mask:`+231(___) __-__`},232:{name:`Sierra Leone`,dial_code:`+232`,code:`SL`,mask:`+232(__) __-__-__`},233:{name:`Ghana`,dial_code:`+233`,code:`GH`,mask:`+233(___) __-__-__`},234:{name:`Nigeria`,dial_code:`+234`,code:`NG`,mask:`+234(___) ___-__-__`},235:{name:`Chad`,dial_code:`+235`,code:`TD`,mask:`+235(__) __-__-__`},236:{name:`Central African Republic`,dial_code:`+236`,code:`CF`,mask:`+236(__) __-__-__`},237:{name:`Cameroon`,dial_code:`+237`,code:`CM`,mask:`+237(__) __-__-__`},238:{name:`Cape Verde`,dial_code:`+238`,code:`CV`,mask:`+238(___) __-__`},239:{name:`Sao Tome and Principe`,dial_code:`+239`,code:`ST`,mask:`+239(___) ___-__-__`},240:{name:`Equatorial Guinea`,dial_code:`+240`,code:`GQ`,mask:`+240(___) __-__-__`},241:{name:`Gabon`,dial_code:`+241`,code:`GA`,mask:`+241(__) __-__-__`},242:{name:`Congo`,dial_code:`+242`,code:`CG`,mask:`+242(___) __-__-__`},243:{name:`Congo, The Democratic Republic of the Congo`,dial_code:`+243`,code:`CD`,mask:`+243(___) ___-__-__`},244:{name:`Angola`,dial_code:`+244`,code:`AO`,mask:`+244(__) ___-__-__`},245:{name:`Guinea-Bissau`,dial_code:`+245`,code:`GW`,mask:`+245(___) __-__`},246:{name:`British Indian Ocean Territory`,dial_code:`+246`,code:`IO`,mask:`+246(___) ___-__-__`},248:{name:`Seychelles`,dial_code:`+248`,code:`SC`,mask:`+248(___) ___-__-__`},249:{name:`Sudan`,dial_code:`+249`,code:`SD`,mask:`+249(___) __-__-__`},250:{name:`Rwanda`,dial_code:`+250`,code:`RW`,mask:`+250(___) __-__-__`},251:{name:`Ethiopia`,dial_code:`+251`,code:`ET`,mask:`+251(___) __-__-__`},252:{name:`Somalia`,dial_code:`+252`,code:`SO`,mask:`+252(___) ___-__-__`},253:{name:`Djibouti`,dial_code:`+253`,code:`DJ`,mask:`+253(___) ___-__-__`},254:{name:`Kenya`,dial_code:`+254`,code:`KE`,mask:`+254(___) __-__-__`},255:{name:`Tanzania, United Republic of Tanzania`,dial_code:`+255`,code:`TZ`,mask:`+255(___) __-__-__`},256:{name:`Uganda`,dial_code:`+256`,code:`UG`,mask:`+256(___) __-__-__`},257:{name:`Burundi`,dial_code:`+257`,code:`BI`,mask:`+257(__) __-__-__`},258:{name:`Mozambique`,dial_code:`+258`,code:`MZ`,mask:`+258(___) __-__-__`},260:{name:`Zambia`,dial_code:`+260`,code:`ZM`,mask:`+260(___) __-__-__`},261:{name:`Madagascar`,dial_code:`+261`,code:`MG`,mask:`+261(___) __-__-__`},262:{name:`Reunion`,dial_code:`+262`,code:`RE`,mask:`+262(___) __-__-__`},263:{name:`Zimbabwe`,dial_code:`+263`,code:`ZW`,mask:`+263(___) __-__-__`},264:{name:`Namibia`,dial_code:`+264`,code:`NA`,mask:`+264(___) __-__-__`},265:{name:`Malawi`,dial_code:`+265`,code:`MW`,mask:`+265(___) __-__-__`},266:{name:`Lesotho`,dial_code:`+266`,code:`LS`,mask:`+266(__) __-__-__`},267:{name:`Botswana`,dial_code:`+267`,code:`BW`,mask:`+267(__) __-__-__`},268:{name:`Swaziland`,dial_code:`+268`,code:`SZ`,mask:`+268(___) ___-__-__`},269:{name:`Comoros`,dial_code:`+269`,code:`KM`,mask:`+269(___) __-__`},290:{name:`Saint Helena, Ascension and Tristan Da Cunha`,dial_code:`+290`,code:`SH`,mask:`+290(___) ___-__-__`},291:{name:`Eritrea`,dial_code:`+291`,code:`ER`,mask:`+291(___) ___-__-__`},297:{name:`Aruba`,dial_code:`+297`,code:`AW`,mask:`+297(_) __-__-__`},298:{name:`Faroe Islands`,dial_code:`+298`,code:`FO`,mask:`+298(__) __-__`},299:{name:`Greenland`,dial_code:`+299`,code:`GL`,mask:`+299(__) __-__`},345:{name:`Cayman Islands`,dial_code:`+ 345`,code:`KY`,mask:`+345(___) ___-__-__`},350:{name:`Gibraltar`,dial_code:`+350`,code:`GI`,mask:`+350(__) __-__-__`},351:{name:`Portugal`,dial_code:`+351`,code:`PT`,mask:`+351(___) __-__-__`},352:{name:`Luxembourg`,dial_code:`+352`,code:`LU`,mask:`+352(___) __-__-__`},353:{name:`Ireland`,dial_code:`+353`,code:`IE`,mask:`+353(___) __-__-__`},354:{name:`Iceland`,dial_code:`+354`,code:`IS`,mask:`+354(___) __-__`},355:{name:`Albania`,dial_code:`+355`,code:`AL`,mask:`+355(__) ___-__-__`},356:{name:`Malta`,dial_code:`+356`,code:`MT`,mask:`+356(__) __-__-__`},357:{name:`Cyprus`,dial_code:`+357`,code:`CY`,mask:`+357(__) __-__-__`},358:{name:`Finland`,dial_code:`+358`,code:`FI`,mask:`+358(___) __-__-__`},359:{name:`Bulgaria`,dial_code:`+359`,code:`BG`,mask:`+359(___) __-__-__`},370:{name:`Lithuania`,dial_code:`+370`,code:`LT`,mask:`+370(_) ___-__-__`},371:{name:`Latvia`,dial_code:`+371`,code:`LV`,mask:`+371(__) __-__-__`},372:{name:`Estonia`,dial_code:`+372`,code:`EE`,mask:`+372(__) __-__-__`},373:{name:`Moldova`,dial_code:`+373`,code:`MD`,mask:`+373(__) __-__-__`},374:{name:`Armenia`,dial_code:`+374`,code:`AM`,mask:`+374(_) ___-__-__`},375:{name:`Belarus`,dial_code:`+375`,code:`BY`,mask:`+375(__) ___-__-__`},376:{name:`Andorra`,dial_code:`+376`,code:`AD`,mask:`+376(_) _-__-__`},377:{name:`Monaco`,dial_code:`+377`,code:`MC`,mask:`+377(___) __-__-__`},378:{name:`San Marino`,dial_code:`+378`,code:`SM`,mask:`+378(__) __-__-__`},379:{name:`Holy See (Vatican City State)`,dial_code:`+379`,code:`VA`,mask:`+379(___) ___-__-__`},380:{name:`Ukraine`,dial_code:`+380`,code:`UA`,mask:`+380(__) ___-__-__`},381:{name:`Serbia`,dial_code:`+381`,code:`RS`,mask:`+381(__) __-__-__`},382:{name:`Montenegro`,dial_code:`+382`,code:`ME`,mask:`+382(___) ___-__-__`},383:{name:`Kosovo`,dial_code:`+383`,code:`XK`,mask:`+383(___) __-__`},385:{name:`Croatia`,dial_code:`+385`,code:`HR`,mask:`+385(__) __-__-__`},386:{name:`Slovenia`,dial_code:`+386`,code:`SI`,mask:`+386(__) __-__-__`},387:{name:`Bosnia and Herzegovina`,dial_code:`+387`,code:`BA`,mask:`+387(__) __-__-__`},389:{name:`Macedonia`,dial_code:`+389`,code:`MK`,mask:`+389(__) __-__-__`},420:{name:`Czech Republic`,dial_code:`+420`,code:`CZ`,mask:`+420(___) __-__-__`},421:{name:`Slovakia`,dial_code:`+421`,code:`SK`,mask:`+421(___) __-__-__`},423:{name:`Liechtenstein`,dial_code:`+423`,code:`LI`,mask:`+423(___) __-__-__`},500:{name:`South Georgia and the South Sandwich Islands`,dial_code:`+500`,code:`GS`,mask:`+500(___) ___-__-__`},501:{name:`Belize`,dial_code:`+501`,code:`BZ`,mask:`+501(___) __-__`},502:{name:`Guatemala`,dial_code:`+502`,code:`GT`,mask:`+502(__) __-__-__`},503:{name:`El Salvador`,dial_code:`+503`,code:`SV`,mask:`+503(__) __-__-__`},504:{name:`Honduras`,dial_code:`+504`,code:`HN`,mask:`+504(__) __-__-__`},505:{name:`Nicaragua`,dial_code:`+505`,code:`NI`,mask:`+505(__) __-__-__`},506:{name:`Costa Rica`,dial_code:`+506`,code:`CR`,mask:`+506(__) __-__-__`},507:{name:`Panama`,dial_code:`+507`,code:`PA`,mask:`+507(__) __-__-__`},508:{name:`Saint Pierre and Miquelon`,dial_code:`+508`,code:`PM`,mask:`+508(___) ___-__-__`},509:{name:`Haiti`,dial_code:`+509`,code:`HT`,mask:`+509(__) __-__-__`},590:{name:`Saint Martin`,dial_code:`+590`,code:`MF`,mask:`+590(___) __-__-__`},591:{name:`Bolivia, Plurinational State of bolivia`,dial_code:`+591`,code:`BO`,mask:`+591(__) __-__-__`},592:{name:`Guyana`,dial_code:`+592`,code:`GY`,mask:`+592(___) ___-__-__`},593:{name:`Ecuador`,dial_code:`+593`,code:`EC`,mask:`+593(___) __-__-__`},594:{name:`French Guiana`,dial_code:`+594`,code:`GF`,mask:`+594(___) __-__-__`},595:{name:`Paraguay`,dial_code:`+595`,code:`PY`,mask:`+595(___) __-__-__`},596:{name:`Martinique`,dial_code:`+596`,code:`MQ`,mask:`+596(___) __-__-__`},597:{name:`Suriname`,dial_code:`+597`,code:`SR`,mask:`+597(___) __-__`},598:{name:`Uruguay`,dial_code:`+598`,code:`UY`,mask:`+598(__) __-__-__`},599:{name:`Netherlands Antilles`,dial_code:`+599`,code:`AN`,mask:`+599(__) __-__-__`},670:{name:`Timor-Leste`,dial_code:`+670`,code:`TL`,mask:`+670(__) __-__-__`},672:{name:`Norfolk Island`,dial_code:`+672`,code:`NF`,mask:`+672(___) ___-__-__`},673:{name:`Brunei Darussalam`,dial_code:`+673`,code:`BN`,mask:`+673(___) __-__`},674:{name:`Nauru`,dial_code:`+674`,code:`NR`,mask:`+674(___) __-__`},675:{name:`Papua New Guinea`,dial_code:`+675`,code:`PG`,mask:`+675(___) __-__`},676:{name:`Tonga`,dial_code:`+676`,code:`TO`,mask:`+676(___) __-__`},677:{name:`Solomon Islands`,dial_code:`+677`,code:`SB`,mask:`+677(___) __-__`},678:{name:`Vanuatu`,dial_code:`+678`,code:`VU`,mask:`+678(___) __-__`},679:{name:`Fiji`,dial_code:`+679`,code:`FJ`,mask:`+679(___) __-__`},680:{name:`Palau`,dial_code:`+680`,code:`PW`,mask:`+680(___) ___-__-__`},681:{name:`Wallis and Futuna`,dial_code:`+681`,code:`WF`,mask:`+681(___) ___-__-__`},682:{name:`Cook Islands`,dial_code:`+682`,code:`CK`,mask:`+682(_) __-__`},683:{name:`Niue`,dial_code:`+683`,code:`NU`,mask:`+683(___) ___-__-__`},685:{name:`Samoa`,dial_code:`+685`,code:`WS`,mask:`+685(__) __-__`},686:{name:`Kiribati`,dial_code:`+686`,code:`KI`,mask:`+686(___) ___-__-__`},687:{name:`New Caledonia`,dial_code:`+687`,code:`NC`,mask:`+687(__) __-__`},688:{name:`Tuvalu`,dial_code:`+688`,code:`TV`,mask:`+688(___) ___-__-__`},689:{name:`French Polynesia`,dial_code:`+689`,code:`PF`,mask:`+689(__) __-__`},690:{name:`Tokelau`,dial_code:`+690`,code:`TK`,mask:`+690(___) ___-__-__`},691:{name:`Micronesia, Federated States of Micronesia`,dial_code:`+691`,code:`FM`,mask:`+691(___) ___-__-__`},692:{name:`Marshall Islands`,dial_code:`+692`,code:`MH`,mask:`+692(___) ___-__-__`},850:{name:`Korea, Democratic People's Republic of Korea`,dial_code:`+850`,code:`KP`,mask:`+850(___) ___-__-__`},852:{name:`Hong Kong`,dial_code:`+852`,code:`HK`,mask:`+852(__) __-__-__`},853:{name:`Macao`,dial_code:`+853`,code:`MO`,mask:`+853(__) __-__-__`},855:{name:`Cambodia`,dial_code:`+855`,code:`KH`,mask:`+855(__) __-__-__`},856:{name:`Laos`,dial_code:`+856`,code:`LA`,mask:`+856(___) ___-__-__`},880:{name:`Bangladesh`,dial_code:`+880`,code:`BD`,mask:`+880(___) ___-__-__`},886:{name:`Taiwan`,dial_code:`+886`,code:`TW`,mask:`+886(___) __-__-__`},960:{name:`Maldives`,dial_code:`+960`,code:`MV`,mask:`+960(___) __-__`},961:{name:`Lebanon`,dial_code:`+961`,code:`LB`,mask:`+961(__) __-__-__`},962:{name:`Jordan`,dial_code:`+962`,code:`JO`,mask:`+962(___) __-__-__`},963:{name:`Syrian Arab Republic`,dial_code:`+963`,code:`SY`,mask:`+963(___) __-__-__`},964:{name:`Iraq`,dial_code:`+964`,code:`IQ`,mask:`+964(___) ___-__-__`},965:{name:`Kuwait`,dial_code:`+965`,code:`KW`,mask:`+965(__) __-__-__`},966:{name:`Saudi Arabia`,dial_code:`+966`,code:`SA`,mask:`+966(___) __-__-__`},967:{name:`Yemen`,dial_code:`+967`,code:`YE`,mask:`+967(___) __-__-__`},968:{name:`Oman`,dial_code:`+968`,code:`OM`,mask:`+968(__) __-__-__`},970:{name:`Palestinian Territory, Occupied`,dial_code:`+970`,code:`PS`,mask:`+970(___) __-__-__`},971:{name:`United Arab Emirates`,dial_code:`+971`,code:`AE`,mask:`+971(___) __-__-__`},972:{name:`Israel`,dial_code:`+972`,code:`IL`,mask:`+972(___) __-__-__`},973:{name:`Bahrain`,dial_code:`+973`,code:`BH`,mask:`+973(__) __-__-__`},974:{name:`Qatar`,dial_code:`+974`,code:`QA`,mask:`+974(__) __-__-__`},975:{name:`Bhutan`,dial_code:`+975`,code:`BT`,mask:`+975(__) __-__-__`},976:{name:`Mongolia`,dial_code:`+976`,code:`MN`,mask:`+976(__) __-__-__`},977:{name:`Nepal`,dial_code:`+977`,code:`NP`,mask:`+977(___) ___-__-__`},992:{name:`Tajikistan`,dial_code:`+992`,code:`TJ`,mask:`+992(___) __-__-__`},993:{name:`Turkmenistan`,dial_code:`+993`,code:`TM`,mask:`+993(__) __-__-__`},994:{name:`Azerbaijan`,dial_code:`+994`,code:`AZ`,mask:`+994(__) ___-__-__`},995:{name:`Georgia`,dial_code:`+995`,code:`GE`,mask:`+995(___) __-__-__`},996:{name:`Kyrgyzstan`,dial_code:`+996`,code:`KG`,mask:`+996(___) __-__-__`},998:{name:`Uzbekistan`,dial_code:`+998`,code:`UZ`,mask:`+998(___) __-__-__`},1242:{name:`Bahamas`,dial_code:`+1242`,code:`BS`,mask:`+1242(___) __-__`},1246:{name:`Barbados`,dial_code:`+1246`,code:`BB`,mask:`+1246(___) __-__`},1264:{name:`Anguilla`,dial_code:`+1264`,code:`AI`,mask:`+1264(___) ___-__-__`},1268:{name:`Antigua and Barbuda`,dial_code:`+1268`,code:`AG`,mask:`+1268(_) __-__`},1284:{name:`Virgin Islands, British`,dial_code:`+1284`,code:`VG`,mask:`+1284(___) __-__`},1340:{name:`Virgin Islands, U.S.`,dial_code:`+1340`,code:`VI`,mask:`+1340(___) ___-__-__`},1441:{name:`Bermuda`,dial_code:`+1441`,code:`BM`,mask:`+1441(___) __-__`},1473:{name:`Grenada`,dial_code:`+1473`,code:`GD`,mask:`+1473(___) __-__`},1649:{name:`Turks and Caicos Islands`,dial_code:`+1649`,code:`TC`,mask:`+1649(___) ___-__-__`},1664:{name:`Montserrat`,dial_code:`+1664`,code:`MS`,mask:`+1664(___) ___-__-__`},1670:{name:`Northern Mariana Islands`,dial_code:`+1670`,code:`MP`,mask:`+1670(___) ___-__-__`},1671:{name:`Guam`,dial_code:`+1671`,code:`GU`,mask:`+1671(___) ___-__-__`},1684:{name:`American Samoa`,dial_code:`+1684`,code:`AS`,mask:`+1684(___) ___-__-__`},1758:{name:`Saint Lucia`,dial_code:`+1758`,code:`LC`,mask:`+1758(___) __-__`},1767:{name:`Dominica`,dial_code:`+1767`,code:`DM`,mask:`+1767(___) __-__`},1784:{name:`Saint Vincent and the Grenadines`,dial_code:`+1784`,code:`VC`,mask:`+1784(___) __-__`},1849:{name:`Dominican Republic`,dial_code:`+1849`,code:`DO`,mask:`+1849(___) ___-__-__`},1868:{name:`Trinidad and Tobago`,dial_code:`+1868`,code:`TT`,mask:`+1868(___) __-__`},1869:{name:`Saint Kitts and Nevis`,dial_code:`+1869`,code:`KN`,mask:`+1869(___) __-__`},1876:{name:`Jamaica`,dial_code:`+1876`,code:`JM`,mask:`+1876(___) __-__`},1939:{name:`Puerto Rico`,dial_code:`+1939`,code:`PR`,mask:`+1939(___) ___-__-__`}}),ue={onNotice:()=>{},onModal:e=>{}},Z={current:ue},de={onNotice:e=>Z.current.onNotice(e),onModal:e=>Z.current.onModal(e)};function fe(e,t){return Z.current={onNotice:e,onModal:t},()=>{Z.current=ue}}function Q(){return de}function pe(e){let t=window.getSelection();if(!t||t.rangeCount===0)return 0;let n=t.getRangeAt(0);if(!e.contains(n.startContainer))return 0;let r=document.createRange();return r.selectNodeContents(e),r.setEnd(n.startContainer,n.startOffset),r.toString().length}function me(e,t){if(t<=0)return 0;let n=0;for(let r=0;r<e.length;r++)if(/\d/.test(e[r])&&(n++,n===t))return r+1;return e.length}function he({value:e,form:t,onValue:r,onSave:i,name:a=``,placeholder:o=``,title:s=``,label:c=``,error:l=``,hide:u=!1,edit:d=!0,active:f=!0,after:h=``,show:g=!0,view:v,className:y=``,disabled:b=!1}){let{onNotice:x}=Q();d=d===void 0?!0:d,f=f===void 0?!0:f;let{value:S,version:C}=_(t,a,e);u=!!(u&&(S===``||S===void 0))&&!(d&&f);let w=`+_(___) ___-__-__`,T=!0,E=0,D=(e,t)=>{let n=t.firstChild;if(!n||n.nodeType!==Node.TEXT_NODE)return;let r=n.textContent?.length??0,i=Math.max(0,Math.min(e,r)),a=document.createRange(),o=window.getSelection();o&&(a.setStart(n,i),a.collapse(!0),o.removeAllRanges(),o.addRange(a),t.focus())},O=e=>{let n=e.target,i=n.textContent||``,o=pe(n),s=i.slice(0,o).replace(/\D/g,``).length,c=M(i);n.textContent=c.q;let l=me(c.q,s);c.q.length>0&&queueMicrotask(()=>{D(Math.min(l,c.q.length),n)});let u={value:c.q.replace(/\D/g,``),name:a||``};t&&a&&t.onValue(u),r&&r!==t?.onValue&&r(u)},j=e=>A.PasteOne(k(e)),M=e=>{w=`+_(___) ___-__-__`,T=!0,E=0;let t=0,n=``,r=e.replace(/\D/g,``);r===``&&(T=!0);let i=r.split(``),a=``;i.forEach(e=>{T&&(a+=e,le[a]!==void 0&&T?(T=!1,w=le[a].mask.replace(RegExp(`[0-9]`,`g`),`_`),n=le[a].code):(T&&(E=(``+a).length,w=`+${a}_(___) ___-__-__`.replace(RegExp(`[0-9]`,`g`),`_`),n=``),E>(``+a).length&&(T=!0,w=`+${a}_(___) ___-__-__`.replace(RegExp(`[0-9]`,`g`),`_`),n=``)))});let o=w.replace(/\D/g,``);return o.length>=r.length&&(r=o),{q:w.replace(/[_\d]/g,function(){return r.charAt(t++)||`_`}),i:t,v:r,f:n}},N=e=>{e.preventDefault();let t=e.target;navigator.clipboard.writeText((t.textContent||``).replace(/\D/g,``)).then(function(){x(`Данные в буфер обмене`)},function(e){console.error(`Async: Could not copy text: `,e)})},P=M(String(S||``)),F=e=>{e.key===`Enter`&&e.preventDefault()},I=e=>{A.Blur(e),i&&i({value:(e.target.textContent||``).replace(/\D/g,``),name:a||``})},L=e=>{A.Focus({target:e.currentTarget})},R={};return o&&(R.placeholder=o),u?(0,n.jsx)(n.Fragment,{}):(0,n.jsx)(m,{type:`input`,title:s||c,error:l,element_blok:{className:[y]},element_input:{className:[p.w]},children:(0,n.jsx)(`div`,{onPaste:j,onInput:O,onKeyDown:F,onContextMenu:N,onBlur:I,onFocus:L,inputMode:`tel`,role:`textbox`,"aria-label":s||c||o||`Телефон`,"aria-disabled":b||!(d&&f),tabIndex:b?-1:0,"data-disabled":b||!(d&&f),contentEditable:d&&f&&!b?`plaintext-only`:!1,suppressContentEditableWarning:!0,...R,children:P.q},C)})}he.displayName=`PhoneField`;function ge({value:e,form:t,onValue:r,name:i=``,inputmode:a=`text`,placeholder:o=``,title:s=``,label:c=``,show:l=!0,hide:u=!1,edit:d=!0,active:f=!0,maxLength:h,onSave:g,className:v=``,spellCheck:y=!0,isReload:b=!1,after:x=``,before:S=``,error:C=``}){let{value:w,version:T}=_(t,i,e),E=!!(u&&(w===``||w===void 0)),D=e=>{let n={value:(e.target.textContent||``).trim(),name:i,reload:b};t&&i&&t.onValue(n),r&&r!==t?.onValue&&r(n)},O=e=>{let t=e.target;h&&(t.textContent||``).trim().length>=h&&e.key!==`Backspace`&&e.preventDefault(),e.key===`Enter`&&e.preventDefault()},j=e=>A.Paste(h||0,k(e));if(!(d&&f)&&!l||!(d&&f)&&E)return``;let M={};return o&&(M.placeholder=o),d&&f&&(M.edit=``),(0,n.jsxs)(m,{type:`input`,title:s||c,error:C,element_blok:{className:[v]},element_input:{className:[p.w]},children:[S,(0,n.jsx)(`div`,{onBlur:e=>{A.Blur(e),g?.({value:(e.target.textContent||``).trim(),name:i})},onFocus:e=>{A.Focus({target:e.currentTarget})},onPaste:j,onInput:D,onKeyDown:O,spellCheck:y,inputMode:a||`text`,contentEditable:d&&f?`plaintext-only`:!1,suppressContentEditableWarning:!0,...M,children:typeof w==`string`||typeof w==`number`?String(w):``},T),x]})}function _e({form:e,onValue:t,onSave:r,active:i,max:a,edit:o,title:s,error:c,show:l,hide:u,value:d,placeholder:f,className:h,maxLength:g,name:v=``,after:y=``,before:b=``,view:x}){o=o===void 0?!0:o,i=i===void 0?!0:i;let{value:S,version:C}=_(e,v,d);u=!!(u&&(S===``||S===void 0))&&!(o&&i),f=f===void 0?``:f,a=a===void 0?99:a;let w=g??a,T=!1,E=n=>{let r=n.currentTarget,i=(r.textContent||``).replace(/\D/g,``);i.length>w&&(i=i.slice(0,w),r.textContent=i,queueMicrotask(()=>{let e=r.firstChild;if(e&&e.nodeType===Node.TEXT_NODE){let t=i.length,n=window.getSelection(),r=document.createRange();r.setStart(e,t),r.collapse(!0),n?.removeAllRanges(),n?.addRange(r)}}));let a={value:i,name:v};e&&v&&e.onValue(a),t&&t!==e?.onValue&&t(a)},D=e=>{let t=e.currentTarget;t.textContent=(t.textContent||``).replace(/\D/g,``),A.Focus({target:e.currentTarget})},O=e=>{if(T&&e.which===86)return;if(e.which===17||e.which===91)return T=!0;if(e.key===`Backspace`)return;let t=(e.currentTarget.textContent??``).replace(/\D/g,``).length;w>0&&t>=w&&e.key.length===1&&/\d/.test(e.key)&&e.preventDefault(),e.key===`Enter`&&e.preventDefault(),e.key.length===1&&!/\d/.test(e.key)&&e.preventDefault()},j=e=>{if(e.which===17||e.which===91)return T=!1},M=e=>A.PasteDigits(w,k(e)),N=e=>{A.Blur(e),r?.({value:e.currentTarget.textContent,name:v})},P={};return o&&i&&(P.edit=``),P.inputMode=`decimal`,f&&(P.placeholder=f),u?(0,n.jsx)(n.Fragment,{}):(0,n.jsx)(m,{type:`numeric`,title:s,error:c,element_blok:{className:[h||``]},element_input:{className:[p.w]},children:(0,n.jsx)(`div`,{onPaste:M,onInput:E,onFocus:D,onBlur:N,onKeyDown:O,onKeyUp:j,spellCheck:!0,role:`textbox`,tabIndex:o&&i?0:-1,"aria-label":s||f||`Число`,contentEditable:o&&i?`plaintext-only`:!1,suppressContentEditableWarning:!0,...P,children:S},C)})}_e.displayName=`NumberField`;var ve=(e,t=`,`)=>(e!==void 0&&e!==``?e.split(t):[]).filter(e=>e!==``).reduce((e,t)=>(e[t]=!0,e),{});function ye({value:e,form:t,onValue:r,name:i,placeholder:a=``,separator:o=`,`,title:s,error:c,hide:l=!1,edit:u=!0,active:d=!0,outFormat:f=`object`,after:h=``,modal:g,options:v,className:y}){let{onModal:b}=Q(),{value:x}=_(t,i,e),S=x,C=typeof S==`string`?ve(S,o):S&&typeof S==`object`?S:{},w=()=>{if(!(u&&d))return;if(!g)return console.error(`modal - empty`);let e=g.split(`.`);b({module:e[0],modalName:e[1],callback:e=>{let n=e;if(r){let e={value:f===`array`?Object.keys(n):f===`string`?Object.keys(n).filter(e=>n[e]).join(o):n,name:i};switch(t&&i&&t.setValue(e),f){case`array`:r!==t?.onValue&&r({value:Object.keys(n),name:i});break;case`string`:r!==t?.onValue&&r({value:Object.keys(n).filter(e=>n[e]).join(o),name:i});break;default:r!==t?.onValue&&r({value:n,name:i})}}},onValue:r,options:v,fieldName:i,value:C})},T={};return a&&(T.placeholder=a),l?(0,n.jsx)(n.Fragment,{}):(0,n.jsx)(m,{type:`group`,title:s,error:c,element_blok:{className:[y||``]},element_input:{className:[p.g],props:{onClick:w}},children:Object.keys(C).map(e=>(0,n.jsx)(`div`,{children:v?.[e]?.label},e))})}ye.displayName=`OptionsField`;var $={o:`_o_1q26w_12`,l:`_l_1q26w_22`,i:`_i_1q26w_80`,f:`_f_1q26w_89`};function be({form:e,title:i,error:a,edit:o=!0,active:s=!0,hide:c,value:l=0,onValue:u,options:d,placeholder:f=``,className:p,name:h=``,order:g,isReload:v=!1,disabled:y=!1}){let[b,x]=t.default.useState(!1),[S,C]=t.default.useState(0),[w,T]=t.default.useState(null),E=t.default.useId(),{value:D}=_(e,h,l??0),O=Number(D),k=[];d&&(k=Array.isArray(d)?d.map(e=>({id:e.id??e.i??0,label:e.n||``,hidden:e.s===0})).filter(e=>e.id!==0&&e.label.length>0):Object.keys(d).map(e=>{let t=Number(e),n=d[t];return{id:t,label:n?.n||``,hidden:n?.s===0}}).filter(e=>e.label.length>0));let A=(()=>{if(!g||g.length===0)return k;let e=new Map(k.map(e=>[e.id,e]));return g.map(t=>e.get(t)).filter(e=>!!e)})().filter(e=>!e.hidden),j=e=>A.find(t=>t.id===e)?.label;c=!!(c&&(O===0||j(O)===void 0))&&!(o&&s);let M=b&&A.length>0?`${E}-opt-${S}`:void 0,N=t=>{let n={value:t,name:h,reload:v};e&&h&&e.onValue(n),u&&u!==e?.onValue&&u(n)},P=e=>{if(A.length===0||!(o&&s)||y)return;let t=A.findIndex(e=>e.id===O);T(e.getBoundingClientRect()),C(t>=0?t:0),x(!0)},F=e=>{P(e.currentTarget)},I=e=>{if(!(!(o&&s)||y)&&A.length!==0){if(!b&&(e.key===`ArrowDown`||e.key===`Enter`||e.key===` `)){e.preventDefault(),P(e.currentTarget);return}if(b){if(e.key===`Escape`){e.preventDefault(),x(!1);return}if(e.key===`ArrowDown`){e.preventDefault(),C(e=>(e+1)%A.length);return}if(e.key===`ArrowUp`){e.preventDefault(),C(e=>e-1<0?A.length-1:e-1);return}if(e.key===`Enter`){e.preventDefault();let t=A[S];t&&N(t.id),x(!1)}}}},L={};return f&&(L.placeholder=f),c?``:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(m,{type:`select`,title:i,element_blok:{className:[p||``]},error:a,element_input:{className:[$.f],props:{onClick:F,onKeyDown:I,tabIndex:o&&s&&!y?0:-1,role:`combobox`,"aria-expanded":b,"aria-haspopup":`listbox`,"aria-controls":E,...M?{"aria-activedescendant":M}:{},"aria-disabled":y||!(o&&s),"data-disabled":y||!(o&&s)}},children:(0,n.jsx)(`div`,{...L,children:j(O)||f||``})}),b&&(0,r.createPortal)((0,n.jsx)(xe,{parent:w||void 0,onValue:N,className:p,items:A,setOpen:x,listId:E,activeIndex:S,currentValue:O}),document.body)]})}be.displayName=`SelectField`;var xe=({onValue:e,parent:t,className:r,items:i,setOpen:a,listId:o,activeIndex:s,currentValue:c})=>{if(!t)return null;let l=()=>{a(!1)},u=t=>{a(!1),e(t)},d=window.innerHeight-t.bottom<306?Math.max(6,t.top-300-6):Math.min(window.innerHeight-300-6,t.bottom+6),f=Math.max(t.width,260),p=Math.min(Math.max(6,t.left),window.innerWidth-f-6);return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(`div`,{className:$.o,onClick:l,"aria-hidden":!0}),(0,n.jsx)(`div`,{className:[$.l,r].filter(e=>e!==void 0).join(` `),style:{top:d+`px`,left:p+`px`,width:f},children:(0,n.jsx)(Se,{listId:o,items:i,link:u,activeIndex:s,currentValue:c})})]})},Se=({listId:e,items:t,link:r,activeIndex:i,currentValue:a})=>(0,n.jsx)(`ul`,{id:e,role:`listbox`,children:t.map((t,o)=>(0,n.jsx)(`li`,{id:`${e}-opt-${o}`,role:`option`,"aria-selected":a===t.id,"data-focus":i===o?`true`:`false`,onClick:()=>r(t.id),children:t.label},t.id))});function Ce({value:e,form:t,onValue:r,name:i,placeholder:a=``,title:o,error:s,hide:c=!1,edit:l=!0,show:u=!0,active:d=!0,after:f=``,view:h,modal:g,options:v,className:y}){let{onModal:b}=Q(),{value:x}=_(t,i,e),S=x,C=e=>e?Array.isArray(e)?e[1]||``:e:``,w=e=>{if(Array.isArray(e)&&e.length>=2)return[e[0],String(e[1]??``)];if(typeof e==`object`&&e){let t=e;if(t.id!==void 0&&t.name!==void 0)return[t.id,t.name]}return String(e??``)},T=e=>{let n={value:w(e),name:i};t&&i&&t.setValue(n),r&&r!==t?.onValue&&r(n)},E=()=>{if(!(l&&d))return;if(!g)return console.error(`modal - empty`);let e=g.split(`.`);if(e.length<2)return console.error(`modal должен быть в формате 'module.name'`);let t=Array.isArray(S)?S[0]:S;b({module:e[0],modalName:e[1],callback:T,onValue:T,options:v,fieldName:i,value:t})},D={};return a&&(D.placeholder=a),c?(0,n.jsx)(n.Fragment,{}):(0,n.jsx)(m,{type:`input`,title:o,element_blok:{className:[y||``]},error:s,element_input:{className:[p.w],props:{onClick:E}},children:(0,n.jsx)(`div`,{...D,children:C(S)})})}Ce.displayName=`ModalField`;function we({value:e,form:r,onValue:i,onSave:a,name:o=``,placeholder:s=``,className:c,title:l,label:u,error:d,edit:f=!0,active:h=!0,isReload:g=!1,native:v=!1,isShow:y=!1,maxLength:b,eyes:x=[],after:S=``,disabled:C=!1}){let[w,T]=t.default.useState(y),{value:E}=_(r,o,e),D=t.default.useRef(null),O=typeof E==`string`?E:E==null?``:String(E);t.default.useEffect(()=>{let e=D.current;e&&e.value!==O&&(e.value=O)},[O]);let k=e=>{let t={value:e,name:o,reload:g};r&&o&&r.onValue(t),i&&i!==r?.onValue&&i(t)},j=e=>{k(e.target.value)},M=e=>{e.key===`Enter`&&e.preventDefault()},N=e=>{A.Blur(e),a?.({value:(e.target.value||``).trim(),name:o||``})};if(v)return``;let P=f&&h&&!C;return(0,n.jsxs)(m,{type:`input`,title:l||u,error:d,element_blok:{className:[c||``]},element_input:{className:[p.w],props:{"data-disabled":C||!P?`true`:void 0}},children:[(0,n.jsx)(`div`,{style:{flex:1,minWidth:0,display:`flex`,alignItems:`center`},children:(0,n.jsx)(`input`,{type:w?`text`:`password`,defaultValue:O,ref:D,onChange:j,onKeyDown:M,onBlur:N,disabled:C,readOnly:!f||!h,maxLength:b,spellCheck:!1,autoComplete:`current-password`,"aria-label":l||u||s||`Пароль`,"aria-disabled":C||!P,tabIndex:C?-1:0,placeholder:s,style:{width:`100%`,border:`none`,outline:`none`,background:`transparent`,font:`inherit`,color:`inherit`,padding:0,margin:0,boxSizing:`border-box`}})}),x[0]?(0,n.jsx)(`i`,{role:`button`,tabIndex:C?-1:0,"aria-label":w?`Скрыть пароль`:`Показать пароль`,"aria-pressed":w,onClick:()=>!C&&T(!w),onKeyDown:e=>{C||(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),T(!w))},style:{cursor:C?`not-allowed`:`pointer`,alignSelf:`center`},children:w?x[1]:x[0]}):null,S]})}we.displayName=`PasswordField`;var Te=()=>{},Ee=e=>{};function De({onNotice:e,onModal:n}){return t.default.useLayoutEffect(()=>fe(e??Te,n??Ee),[e,n]),null}De.displayName=`Form.Init`;var Oe={Init:De};function ke(){return typeof globalThis<`u`?globalThis:typeof window<`u`?window:typeof self<`u`?self:{}}var Ae=ke();Ae.elcrm||={},Object.assign(Ae.elcrm,{form:f.version}),e.DateField=H,e.Form=Oe,e.MaskField=L,e.ModalField=Ce,e.MoneyField=N,e.NumberField=_e,e.OptionsField=ye,e.PasswordField=we,e.PhoneField=he,e.ProgressField=x,e.RangeField=x,e.SelectField=be,e.StringField=ge,e.TextareaField=ce,e.TimeField=se,e.asEditableClipboard=k,e.useForm=g,e.useFormField=v,e.useFormFieldState=_,e.useFormInit=Q});
|