master-components-react 1.1.1 → 1.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
(function(){"use strict";try{if(typeof document<"u"){var o=document.createElement("style");o.appendChild(document.createTextNode(".FormInput-module__inputWrapper{width:100%}.FormInput-module__inputWrapper .FormInput-module__inputLabel{color:#414651;font-family:Inter;font-size:14px;font-style:normal;font-weight:500;line-height:20px}.FormInput-module__inputWrapper .FormInput-module__inputLabel .FormInput-module__required{color:#7f56d9;font-family:Inter;font-size:14px;font-style:normal;font-weight:500;line-height:20px}.FormInput-module__inputWrapper .FormInput-module__inputContainer{position:relative;margin:6px 0;width:100%;border-radius:8px;border:1px solid #d5d7da;background:#fff;box-shadow:0 1px 2px #0a0d120d;display:flex;padding-left:12px}.FormInput-module__inputWrapper .FormInput-module__inputContainer input{background-color:transparent;width:100%;border:none;padding:8px 0;color:#181d27;font-family:Inter;font-size:16px;font-style:normal;font-weight:400;line-height:24px;outline:none}.FormInput-module__inputWrapper .FormInput-module__inputContainer input::placeholder{color:#717680}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__focused{border-radius:8px;outline-color:#9e77ed;outline-width:2px;outline-style:solid;background:#fff;box-shadow:0 1px 2px #0a0d120d}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__error{border-radius:8px;outline-color:#fda29b;outline-width:1px;outline-style:solid;background:#fff;box-shadow:0 1px 2px #0a0d120d}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__error.FormInput-module__focused{outline-width:2px;outline-color:#f04438}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__rightIcon,.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__leftIcon{display:flex;justify-content:center;align-items:center}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__rightIcon{margin:0 8px}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__leftIcon{margin-right:6px}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown{padding:8px 12px;display:grid;place-items:center;position:relative;color:#414651;font-family:Inter;font-size:16px;font-style:normal;font-weight:400;line-height:24px;cursor:pointer;display:flex;align-items:center;gap:8px}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown ul{width:100%;position:absolute;left:50%;top:100%;transform:translate(-50%);max-height:150px;overflow:hidden;background-color:#fff;border:1px solid #d5d7da;border-radius:8px}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown ul li{padding:6px 12px;width:100%;display:flex;flex-direction:column;font-size:14px;line-height:initial;cursor:pointer}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown ul li:hover{background-color:#d5d7da}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown.FormInput-module__http{cursor:initial;border-right:1px solid #d5d7da;margin-right:12px}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__disabled{border-radius:8px;border:1px solid #d5d7da;background:#fafafa;box-shadow:0 1px 2px #0a0d120d;cursor:no-drop}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__disabled input{background:#fafafa;box-shadow:0 1px 2px #0a0d120d;cursor:no-drop}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__sm{height:40px}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__md{height:44px}.FormInput-module__inputWrapper .FormInput-module__withCopy{display:flex;align-items:center;gap:4px;border-radius:0 8px 8px 0;border:1px solid #d5d7da;background:#fff;padding:10px 14px;color:#414651;font-family:Inter;font-size:14px;font-style:normal;font-weight:600;line-height:20px;cursor:pointer;-webkit-user-select:none;user-select:none}.FormInput-module__inputWrapper .FormInput-module__withCopy:hover{background:#f0f0f0}.FormInput-module__inputWrapper .FormInput-module__withCopy:active{background:#ececec}.FormInput-module__inputWrapper .FormInput-module__inputHelperText p{color:#535862;font-family:Inter;font-size:14px;font-style:normal;font-weight:400;line-height:20px}.FormInput-module__inputWrapper .FormInput-module__inputHelperText.FormInput-module__error p{color:#d92d20}")),document.head.appendChild(o)}}catch(n){console.error("vite-plugin-css-injected-by-js",n)}})();
|
|
2
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const w=require("react");var Ie={exports:{}},se={};/**
|
|
2
3
|
* @license React
|
|
3
4
|
* react-jsx-runtime.production.min.js
|
|
4
5
|
*
|
|
@@ -6,7 +7,7 @@
|
|
|
6
7
|
*
|
|
7
8
|
* This source code is licensed under the MIT license found in the
|
|
8
9
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
10
|
+
*/var Ke;function pr(){if(Ke)return se;Ke=1;var C=w,_=Symbol.for("react.element"),R=Symbol.for("react.fragment"),x=Object.prototype.hasOwnProperty,F=C.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,S={key:!0,ref:!0,__self:!0,__source:!0};function P(y,f,b){var s,g={},D=null,B=null;b!==void 0&&(D=""+b),f.key!==void 0&&(D=""+f.key),f.ref!==void 0&&(B=f.ref);for(s in f)x.call(f,s)&&!S.hasOwnProperty(s)&&(g[s]=f[s]);if(y&&y.defaultProps)for(s in f=y.defaultProps,f)g[s]===void 0&&(g[s]=f[s]);return{$$typeof:_,type:y,key:D,ref:B,props:g,_owner:F.current}}return se.Fragment=R,se.jsx=P,se.jsxs=P,se}var ue={};/**
|
|
10
11
|
* @license React
|
|
11
12
|
* react-jsx-runtime.development.js
|
|
12
13
|
*
|
|
@@ -14,17 +15,17 @@
|
|
|
14
15
|
*
|
|
15
16
|
* This source code is licensed under the MIT license found in the
|
|
16
17
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
18
|
-
`+oe+e}}var
|
|
19
|
-
`),
|
|
20
|
-
`),d=i.length-1,
|
|
21
|
-
`+i[d].replace(" at new "," at ");return e.displayName&&T.includes("<anonymous>")&&(T=T.replace("<anonymous>",e.displayName)),typeof e=="function"&&
|
|
18
|
+
*/var Je;function vr(){return Je||(Je=1,process.env.NODE_ENV!=="production"&&function(){var C=w,_=Symbol.for("react.element"),R=Symbol.for("react.portal"),x=Symbol.for("react.fragment"),F=Symbol.for("react.strict_mode"),S=Symbol.for("react.profiler"),P=Symbol.for("react.provider"),y=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),b=Symbol.for("react.suspense"),s=Symbol.for("react.suspense_list"),g=Symbol.for("react.memo"),D=Symbol.for("react.lazy"),B=Symbol.for("react.offscreen"),U=Symbol.iterator,Q="@@iterator";function ee(e){if(e===null||typeof e!="object")return null;var r=U&&e[U]||e[Q];return typeof r=="function"?r:null}var O=C.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function p(e){{for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];re("error",e,t)}}function re(e,r,t){{var n=O.ReactDebugCurrentFrame,u=n.getStackAddendum();u!==""&&(r+="%s",t=t.concat([u]));var c=t.map(function(o){return String(o)});c.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,c)}}var le=!1,ce=!1,te=!1,q=!1,ne=!1,H;H=Symbol.for("react.module.reference");function fe(e){return!!(typeof e=="string"||typeof e=="function"||e===x||e===S||ne||e===F||e===b||e===s||q||e===B||le||ce||te||typeof e=="object"&&e!==null&&(e.$$typeof===D||e.$$typeof===g||e.$$typeof===P||e.$$typeof===y||e.$$typeof===f||e.$$typeof===H||e.getModuleId!==void 0))}function ae(e,r,t){var n=e.displayName;if(n)return n;var u=r.displayName||r.name||"";return u!==""?t+"("+u+")":t}function de(e){return e.displayName||"Context"}function j(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 x:return"Fragment";case R:return"Portal";case S:return"Profiler";case F:return"StrictMode";case b:return"Suspense";case s:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case y:var r=e;return de(r)+".Consumer";case P:var t=e;return de(t._context)+".Provider";case f:return ae(e,e.render,"ForwardRef");case g:var n=e.displayName||null;return n!==null?n:j(e.type)||"Memo";case D:{var u=e,c=u._payload,o=u._init;try{return j(o(c))}catch{return null}}}return null}var $=Object.assign,A=0,pe,ve,he,ye,me,_e,be;function ge(){}ge.__reactDisabledLog=!0;function je(){{if(A===0){pe=console.log,ve=console.info,he=console.warn,ye=console.error,me=console.group,_e=console.groupCollapsed,be=console.groupEnd;var e={configurable:!0,enumerable:!0,value:ge,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}A++}}function We(){{if(A--,A===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:$({},e,{value:pe}),info:$({},e,{value:ve}),warn:$({},e,{value:he}),error:$({},e,{value:ye}),group:$({},e,{value:me}),groupCollapsed:$({},e,{value:_e}),groupEnd:$({},e,{value:be})})}A<0&&p("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var ie=O.ReactCurrentDispatcher,oe;function I(e,r,t){{if(oe===void 0)try{throw Error()}catch(u){var n=u.stack.trim().match(/\n( *(at )?)/);oe=n&&n[1]||""}return`
|
|
19
|
+
`+oe+e}}var W=!1,N;{var Te=typeof WeakMap=="function"?WeakMap:Map;N=new Te}function L(e,r){if(!e||W)return"";{var t=N.get(e);if(t!==void 0)return t}var n;W=!0;var u=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var c;c=ie.current,ie.current=null,je();try{if(r){var o=function(){throw Error()};if(Object.defineProperty(o.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(o,[])}catch(E){n=E}Reflect.construct(e,[],o)}else{try{o.call()}catch(E){n=E}e.call(o.prototype)}}else{try{throw Error()}catch(E){n=E}e()}}catch(E){if(E&&n&&typeof E.stack=="string"){for(var i=E.stack.split(`
|
|
20
|
+
`),m=n.stack.split(`
|
|
21
|
+
`),d=i.length-1,v=m.length-1;d>=1&&v>=0&&i[d]!==m[v];)v--;for(;d>=1&&v>=0;d--,v--)if(i[d]!==m[v]){if(d!==1||v!==1)do if(d--,v--,v<0||i[d]!==m[v]){var T=`
|
|
22
|
+
`+i[d].replace(" at new "," at ");return e.displayName&&T.includes("<anonymous>")&&(T=T.replace("<anonymous>",e.displayName)),typeof e=="function"&&N.set(e,T),T}while(d>=1&&v>=0);break}}}finally{W=!1,ie.current=c,We(),Error.prepareStackTrace=u}var z=e?e.displayName||e.name:"",M=z?I(z):"";return typeof e=="function"&&N.set(e,M),M}function we(e,r,t){return L(e,!1)}function Se(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function K(e,r,t){if(e==null)return"";if(typeof e=="function")return L(e,Se(e));if(typeof e=="string")return I(e);switch(e){case b:return I("Suspense");case s:return I("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case f:return we(e.render);case g:return K(e.type,r,t);case D:{var n=e,u=n._payload,c=n._init;try{return K(c(u),r,t)}catch{}}}return""}var Y=Object.prototype.hasOwnProperty,Ee={},Re=O.ReactDebugCurrentFrame;function J(e){if(e){var r=e._owner,t=K(e.type,e._source,r?r.type:null);Re.setExtraStackFrame(t)}else Re.setExtraStackFrame(null)}function Ce(e,r,t,n,u){{var c=Function.call.bind(Y);for(var o in e)if(c(e,o)){var i=void 0;try{if(typeof e[o]!="function"){var m=Error((n||"React class")+": "+t+" type `"+o+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[o]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw m.name="Invariant Violation",m}i=e[o](r,o,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(d){i=d}i&&!(i instanceof Error)&&(J(u),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).",n||"React class",t,o,typeof i),J(null)),i instanceof Error&&!(i.message in Ee)&&(Ee[i.message]=!0,J(u),p("Failed %s type: %s",t,i.message),J(null))}}}var Pe=Array.isArray;function G(e){return Pe(e)}function Oe(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,t=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return t}}function xe(e){try{return a(e),!1}catch{return!0}}function a(e){return""+e}function k(e){if(xe(e))return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Oe(e)),a(e)}var V=O.ReactCurrentOwner,Ge={key:!0,ref:!0,__self:!0,__source:!0},Ne,Le,ke;ke={};function Xe(e){if(Y.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function ze(e){if(Y.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function Ze(e,r){if(typeof e.ref=="string"&&V.current&&r&&V.current.stateNode!==r){var t=j(V.current.type);ke[t]||(p('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',j(V.current.type),e.ref),ke[t]=!0)}}function Qe(e,r){{var t=function(){Ne||(Ne=!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)",r))};t.isReactWarning=!0,Object.defineProperty(e,"key",{get:t,configurable:!0})}}function er(e,r){{var t=function(){Le||(Le=!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)",r))};t.isReactWarning=!0,Object.defineProperty(e,"ref",{get:t,configurable:!0})}}var rr=function(e,r,t,n,u,c,o){var i={$$typeof:_,type:e,key:r,ref:t,props:o,_owner:c};return i._store={},Object.defineProperty(i._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(i,"_self",{configurable:!1,enumerable:!1,writable:!1,value:n}),Object.defineProperty(i,"_source",{configurable:!1,enumerable:!1,writable:!1,value:u}),Object.freeze&&(Object.freeze(i.props),Object.freeze(i)),i};function tr(e,r,t,n,u){{var c,o={},i=null,m=null;t!==void 0&&(k(t),i=""+t),ze(r)&&(k(r.key),i=""+r.key),Xe(r)&&(m=r.ref,Ze(r,u));for(c in r)Y.call(r,c)&&!Ge.hasOwnProperty(c)&&(o[c]=r[c]);if(e&&e.defaultProps){var d=e.defaultProps;for(c in d)o[c]===void 0&&(o[c]=d[c])}if(i||m){var v=typeof e=="function"?e.displayName||e.name||"Unknown":e;i&&Qe(o,v),m&&er(o,v)}return rr(e,i,m,u,n,V.current,o)}}var Fe=O.ReactCurrentOwner,Ye=O.ReactDebugCurrentFrame;function X(e){if(e){var r=e._owner,t=K(e.type,e._source,r?r.type:null);Ye.setExtraStackFrame(t)}else Ye.setExtraStackFrame(null)}var De;De=!1;function $e(e){return typeof e=="object"&&e!==null&&e.$$typeof===_}function Ve(){{if(Fe.current){var e=j(Fe.current.type);if(e)return`
|
|
22
23
|
|
|
23
|
-
Check the render method of \``+e+"`."}return""}}function nr(e){return""}var
|
|
24
|
+
Check the render method of \``+e+"`."}return""}}function nr(e){return""}var Me={};function ar(e){{var r=Ve();if(!r){var t=typeof e=="string"?e:e.displayName||e.name;t&&(r=`
|
|
24
25
|
|
|
25
|
-
Check the top-level render call using <`+t+">.")}return r}}function
|
|
26
|
+
Check the top-level render call using <`+t+">.")}return r}}function Be(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var t=ar(r);if(Me[t])return;Me[t]=!0;var n="";e&&e._owner&&e._owner!==Fe.current&&(n=" It was passed a child from "+j(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.',t,n),X(null)}}function Ue(e,r){{if(typeof e!="object")return;if(G(e))for(var t=0;t<e.length;t++){var n=e[t];$e(n)&&Be(n,r)}else if($e(e))e._store&&(e._store.validated=!0);else if(e){var u=ee(e);if(typeof u=="function"&&u!==e.entries)for(var c=u.call(e),o;!(o=c.next()).done;)$e(o.value)&&Be(o.value,r)}}}function ir(e){{var r=e.type;if(r==null||typeof r=="string")return;var t;if(typeof r=="function")t=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===f||r.$$typeof===g))t=r.propTypes;else return;if(t){var n=j(r);Ce(t,e.props,"prop",n,e)}else if(r.PropTypes!==void 0&&!De){De=!0;var u=j(r);p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",u||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function or(e){{for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if(n!=="children"&&n!=="key"){X(e),p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),X(null);break}}e.ref!==null&&(X(e),p("Invalid attribute `ref` supplied to `React.Fragment`."),X(null))}}var qe={};function He(e,r,t,n,u,c){{var o=fe(e);if(!o){var i="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(i+=" 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 m=nr();m?i+=m:i+=Ve();var d;e===null?d="null":G(e)?d="array":e!==void 0&&e.$$typeof===_?(d="<"+(j(e.type)||"Unknown")+" />",i=" Did you accidentally export a JSX literal instead of a component?"):d=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",d,i)}var v=tr(e,r,t,u,c);if(v==null)return v;if(o){var T=r.children;if(T!==void 0)if(n)if(G(T)){for(var z=0;z<T.length;z++)Ue(T[z],e);Object.freeze&&Object.freeze(T)}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 Ue(T,e)}if(Y.call(r,"key")){var M=j(e),E=Object.keys(r).filter(function(dr){return dr!=="key"}),Ae=E.length>0?"{key: someKey, "+E.join(": ..., ")+": ...}":"{key: someKey}";if(!qe[M+Ae]){var fr=E.length>0?"{"+E.join(": ..., ")+": ...}":"{}";p(`A props object containing a "key" prop is being spread into JSX:
|
|
26
27
|
let props = %s;
|
|
27
28
|
<%s {...props} />
|
|
28
29
|
React keys must be passed directly to JSX without using spread:
|
|
29
30
|
let props = %s;
|
|
30
|
-
<%s key={someKey} {...props} />`,
|
|
31
|
+
<%s key={someKey} {...props} />`,Ae,M,fr,M),qe[M+Ae]=!0}}return e===x?or(v):ir(v),v}}function sr(e,r,t){return He(e,r,t,!0)}function ur(e,r,t){return He(e,r,t,!1)}var lr=ur,cr=sr;ue.Fragment=x,ue.jsx=lr,ue.jsxs=cr}()),ue}process.env.NODE_ENV==="production"?Ie.exports=pr():Ie.exports=vr();var l=Ie.exports;const Z={},hr=({label:C,buttonType:_="button",onClick:R,size:x="md",disabled:F,withIcons:S,iconOne:P,iconTwo:y,onlyIcon:f,buttonStyle:b,labelStyle:s,buttonSlotStyle:g})=>l.jsx("button",{type:_,style:b&&typeof b=="object"?b:{},className:`${Z.mainButton} ${f?Z.onlyIcon:""} ${x?Z[x]:""} ${F?Z.disabled:""}`,onClick:()=>{R&&typeof R=="function"&&R()},children:l.jsxs("div",{className:Z.buttonSlot,style:g??{},children:[f||S&&P?P:"",!f&&l.jsx("span",{style:s??{},className:Z.buttonLabel,children:C??"Button"}),S&&y?y:""]})}),yr="FormInput-module__inputWrapper",mr="FormInput-module__inputLabel",_r="FormInput-module__required",br="FormInput-module__inputContainer",gr="FormInput-module__focused",Er="FormInput-module__error",Rr="FormInput-module__rightIcon",Cr="FormInput-module__leftIcon",xr="FormInput-module__inputDropDown",jr="FormInput-module__http",Tr="FormInput-module__disabled",wr="FormInput-module__sm",Sr="FormInput-module__md",Pr="FormInput-module__withCopy",Or="FormInput-module__inputHelperText",h={inputWrapper:yr,inputLabel:mr,required:_r,inputContainer:br,focused:gr,error:Er,rightIcon:Rr,leftIcon:Cr,inputDropDown:xr,http:jr,disabled:Tr,sm:wr,md:Sr,withCopy:Pr,inputHelperText:Or},kr=({width:C,height:_,color:R})=>l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:C??"12",height:_??"8",viewBox:"0 0 12 8",fill:"none",children:l.jsx("path",{d:"M1 1.5L6 6.5L11 1.5",stroke:R??"#A4A7AE",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),Fr=({width:C,height:_,color:R})=>l.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:C??"20",height:_??"20",viewBox:"0 0 20 20",fill:"none",children:[l.jsx("g",{clipPath:"url(#clip0_444_26)",children:l.jsx("path",{d:"M4.1665 12.5C3.38993 12.5 3.00165 12.5 2.69536 12.3732C2.28698 12.204 1.96253 11.8795 1.79337 11.4712C1.6665 11.1649 1.6665 10.7766 1.6665 10V4.33335C1.6665 3.39993 1.6665 2.93322 1.84816 2.5767C2.00795 2.2631 2.26292 2.00813 2.57652 1.84834C2.93304 1.66669 3.39975 1.66669 4.33317 1.66669H9.99984C10.7764 1.66669 11.1647 1.66669 11.471 1.79355C11.8794 1.96271 12.2038 2.28717 12.373 2.69555C12.4998 3.00183 12.4998 3.39012 12.4998 4.16669M10.1665 18.3334H15.6665C16.5999 18.3334 17.0666 18.3334 17.4232 18.1517C17.7368 17.9919 17.9917 17.7369 18.1515 17.4233C18.3332 17.0668 18.3332 16.6001 18.3332 15.6667V10.1667C18.3332 9.23327 18.3332 8.76656 18.1515 8.41004C17.9917 8.09643 17.7368 7.84147 17.4232 7.68168C17.0666 7.50002 16.5999 7.50002 15.6665 7.50002H10.1665C9.23308 7.50002 8.76637 7.50002 8.40985 7.68168C8.09625 7.84147 7.84128 8.09643 7.68149 8.41004C7.49984 8.76656 7.49984 9.23327 7.49984 10.1667V15.6667C7.49984 16.6001 7.49984 17.0668 7.68149 17.4233C7.84128 17.7369 8.09625 17.9919 8.40985 18.1517C8.76637 18.3334 9.23308 18.3334 10.1665 18.3334Z",stroke:R??"#414651",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})}),l.jsx("defs",{children:l.jsx("clipPath",{id:"clip0_444_26",children:l.jsx("rect",{width:"20",height:"20",fill:"white"})})})]}),Dr=({value:C,label:_,placeholder:R,required:x,disabled:F,type:S,size:P,onChange:y,onFouce:f,onBlur:b,msg:s,readOnly:g,maxLength:D,onlyText:B,onRightIconIconClick:U,onRightIconIconMouseEnter:Q,onRightIconIconMouseLeave:ee,onLeftIconIconClick:O,onLeftIconIconMouseEnter:p,onLeftIconIconMouseLeave:re,rightIcon:le,leftIcon:ce,withDropDown:te,dropdownData:q,onSelectData:ne,withLink:H,withCopy:fe,onCopy:ae,inputWrapperStyle:de,inputLabelStyle:j,requiredStyle:$,inputContainerStyle:A,leftIconStyle:pe,inputDropDownStyle:ve,ulStyle:he,liStyle:ye,httpStyle:me,inputStyle:_e,rightIconStyle:be,withCopyStyle:ge,inputHelperTextStyle:je})=>{const[We,ie]=w.useState(!1),[oe,I]=w.useState(!1);w.useState(!1);const W=w.useRef(null),N=w.useRef(null),[Te,L]=w.useState(!1),[we,Se]=w.useState(1),K=a=>{let k=a.target.value;k.length===1&&(k=k.trim()),y&&typeof y=="function"&&y(B?k.replace(/\d/g,""):k)},Y=()=>{I(!0),f&&typeof f=="function"&&f()},Ee=()=>{I(!1),b&&typeof b=="function"&&b()},Re=a=>{const V=a.target.value.length===0;S==="number"&&(a.keyCode===69||!V&&(a.keyCode===187||a.keyCode===107||a.keyCode===189||a.keyCode===109))&&a.preventDefault()},J=()=>{ae&&typeof ae=="function"&&ae(C)},Ce=a=>a,Pe=()=>{let a={};return fe&&(a.borderTopRightRadius=0,a.borderBottomRightRadius=0,a.borderRight=0),te&&(a.paddingLeft=0),{...a,...A??{}}},G=a=>{!a.composedPath().includes(N.current)&&a.composedPath().includes(W.current)||L(!1)},Oe=a=>{Se(a.id),L(!1),ne&&typeof ne=="function"&&ne(a)};w.useEffect(()=>(document.addEventListener("click",G),()=>{document.removeEventListener("click",G)}),[]);const xe=w.useRef(!1);return w.useEffect(()=>{xe.current?setTimeout(()=>{ie(a=>!a)},0):xe.current=!0},[]),l.jsxs("div",{className:h.inputWrapper,style:de??{},children:[_&&l.jsxs("label",{className:h.inputLabel,style:j??{},children:[_," ",l.jsx("span",{className:h.required,style:$??{},children:x&&"*"})]}),l.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[l.jsxs("div",{style:Pe(),className:`${h.inputContainer} ${oe&&!g?h.focused:""} ${F?h.disabled:""} ${s!=null&&s.error?h.error:""} ${h[P??"sm"]}`,children:[!te&&!H&&ce&&l.jsx("div",{className:h.leftIcon,style:pe??{},onClick:()=>{O&&typeof O=="function"&&O()},onMouseEnter:()=>{p&&typeof p=="function"&&p()},onMouseLeave:()=>{re&&typeof re=="function"&&re()},children:Ce(ce)}),!H&&te&&l.jsxs("div",{className:h.inputDropDown,style:ve??{},onClick:()=>L(!0),ref:W,children:[q.find(a=>a.id===we).label,Te&&l.jsx("ul",{ref:N,style:he??{},children:q&&q.length&&q.map((a,k)=>l.jsx("li",{style:ye??{},onClick:()=>Oe(a),children:(a==null?void 0:a.label)??"-"},a.id))}),l.jsx(kr,{})]}),H&&l.jsx("div",{className:`${h.inputDropDown} ${h.http}`,style:me??{},onClick:()=>L(!0),ref:W,children:"http://"}),l.jsx("input",{style:_e??{},type:S??"text",value:C,onChange:a=>K(a),onFocus:Y,onBlur:Ee,disabled:F,required:x,onKeyDown:Re,readOnly:g,spellCheck:!1,placeholder:R??"",autoComplete:"off",maxLength:D}),le&&l.jsx("div",{className:h.rightIcon,style:be??{},onClick:()=>{U&&typeof U=="function"&&U()},onMouseEnter:()=>{Q&&typeof Q=="function"&&Q()},onMouseLeave:()=>{ee&&typeof ee=="function"&&ee()},children:Ce(le)})]}),fe&&l.jsxs("div",{style:ge??{},onClick:J,className:h.withCopy,children:[l.jsx(Fr,{}),"Copy"]})]}),s&&(s==null?void 0:s.visigle)&&l.jsx("div",{style:je??{},className:`${h.inputHelperText} ${s!=null&&s.error?h.error:""}`,children:l.jsx("p",{style:(s==null?void 0:s.style)??{},children:s.text})})]})};exports.FormInput=Dr;exports.MainButton=hr;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
(function(){"use strict";try{if(typeof document<"u"){var o=document.createElement("style");o.appendChild(document.createTextNode(".FormInput-module__inputWrapper{width:100%}.FormInput-module__inputWrapper .FormInput-module__inputLabel{color:#414651;font-family:Inter;font-size:14px;font-style:normal;font-weight:500;line-height:20px}.FormInput-module__inputWrapper .FormInput-module__inputLabel .FormInput-module__required{color:#7f56d9;font-family:Inter;font-size:14px;font-style:normal;font-weight:500;line-height:20px}.FormInput-module__inputWrapper .FormInput-module__inputContainer{position:relative;margin:6px 0;width:100%;border-radius:8px;border:1px solid #d5d7da;background:#fff;box-shadow:0 1px 2px #0a0d120d;display:flex;padding-left:12px}.FormInput-module__inputWrapper .FormInput-module__inputContainer input{background-color:transparent;width:100%;border:none;padding:8px 0;color:#181d27;font-family:Inter;font-size:16px;font-style:normal;font-weight:400;line-height:24px;outline:none}.FormInput-module__inputWrapper .FormInput-module__inputContainer input::placeholder{color:#717680}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__focused{border-radius:8px;outline-color:#9e77ed;outline-width:2px;outline-style:solid;background:#fff;box-shadow:0 1px 2px #0a0d120d}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__error{border-radius:8px;outline-color:#fda29b;outline-width:1px;outline-style:solid;background:#fff;box-shadow:0 1px 2px #0a0d120d}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__error.FormInput-module__focused{outline-width:2px;outline-color:#f04438}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__rightIcon,.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__leftIcon{display:flex;justify-content:center;align-items:center}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__rightIcon{margin:0 8px}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__leftIcon{margin-right:6px}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown{padding:8px 12px;display:grid;place-items:center;position:relative;color:#414651;font-family:Inter;font-size:16px;font-style:normal;font-weight:400;line-height:24px;cursor:pointer;display:flex;align-items:center;gap:8px}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown ul{width:100%;position:absolute;left:50%;top:100%;transform:translate(-50%);max-height:150px;overflow:hidden;background-color:#fff;border:1px solid #d5d7da;border-radius:8px}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown ul li{padding:6px 12px;width:100%;display:flex;flex-direction:column;font-size:14px;line-height:initial;cursor:pointer}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown ul li:hover{background-color:#d5d7da}.FormInput-module__inputWrapper .FormInput-module__inputContainer .FormInput-module__inputDropDown.FormInput-module__http{cursor:initial;border-right:1px solid #d5d7da;margin-right:12px}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__disabled{border-radius:8px;border:1px solid #d5d7da;background:#fafafa;box-shadow:0 1px 2px #0a0d120d;cursor:no-drop}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__disabled input{background:#fafafa;box-shadow:0 1px 2px #0a0d120d;cursor:no-drop}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__sm{height:40px}.FormInput-module__inputWrapper .FormInput-module__inputContainer.FormInput-module__md{height:44px}.FormInput-module__inputWrapper .FormInput-module__withCopy{display:flex;align-items:center;gap:4px;border-radius:0 8px 8px 0;border:1px solid #d5d7da;background:#fff;padding:10px 14px;color:#414651;font-family:Inter;font-size:14px;font-style:normal;font-weight:600;line-height:20px;cursor:pointer;-webkit-user-select:none;user-select:none}.FormInput-module__inputWrapper .FormInput-module__withCopy:hover{background:#f0f0f0}.FormInput-module__inputWrapper .FormInput-module__withCopy:active{background:#ececec}.FormInput-module__inputWrapper .FormInput-module__inputHelperText p{color:#535862;font-family:Inter;font-size:14px;font-style:normal;font-weight:400;line-height:20px}.FormInput-module__inputWrapper .FormInput-module__inputHelperText.FormInput-module__error p{color:#d92d20}")),document.head.appendChild(o)}}catch(n){console.error("vite-plugin-css-injected-by-js",n)}})();
|
|
2
|
+
import ze, { useState as oe, useRef as Ie, useEffect as Je } from "react";
|
|
3
|
+
var We = { exports: {} }, se = {};
|
|
3
4
|
/**
|
|
4
5
|
* @license React
|
|
5
6
|
* react-jsx-runtime.production.min.js
|
|
@@ -10,16 +11,16 @@ var Ne = { exports: {} }, se = {};
|
|
|
10
11
|
* LICENSE file in the root directory of this source tree.
|
|
11
12
|
*/
|
|
12
13
|
var Ge;
|
|
13
|
-
function
|
|
14
|
+
function yr() {
|
|
14
15
|
if (Ge) return se;
|
|
15
16
|
Ge = 1;
|
|
16
|
-
var C = ze,
|
|
17
|
-
function S(
|
|
18
|
-
var s,
|
|
19
|
-
|
|
20
|
-
for (s in
|
|
21
|
-
if (
|
|
22
|
-
return { $$typeof:
|
|
17
|
+
var C = ze, _ = Symbol.for("react.element"), R = Symbol.for("react.fragment"), x = Object.prototype.hasOwnProperty, O = C.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, w = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
18
|
+
function S(y, f, b) {
|
|
19
|
+
var s, g = {}, F = null, M = null;
|
|
20
|
+
b !== void 0 && (F = "" + b), f.key !== void 0 && (F = "" + f.key), f.ref !== void 0 && (M = f.ref);
|
|
21
|
+
for (s in f) x.call(f, s) && !w.hasOwnProperty(s) && (g[s] = f[s]);
|
|
22
|
+
if (y && y.defaultProps) for (s in f = y.defaultProps, f) g[s] === void 0 && (g[s] = f[s]);
|
|
23
|
+
return { $$typeof: _, type: y, key: F, ref: M, props: g, _owner: O.current };
|
|
23
24
|
}
|
|
24
25
|
return se.Fragment = R, se.jsx = S, se.jsxs = S, se;
|
|
25
26
|
}
|
|
@@ -34,17 +35,17 @@ var ue = {};
|
|
|
34
35
|
* LICENSE file in the root directory of this source tree.
|
|
35
36
|
*/
|
|
36
37
|
var Xe;
|
|
37
|
-
function
|
|
38
|
+
function mr() {
|
|
38
39
|
return Xe || (Xe = 1, process.env.NODE_ENV !== "production" && function() {
|
|
39
|
-
var C = ze,
|
|
40
|
+
var C = ze, _ = Symbol.for("react.element"), R = Symbol.for("react.portal"), x = Symbol.for("react.fragment"), O = Symbol.for("react.strict_mode"), w = Symbol.for("react.profiler"), S = Symbol.for("react.provider"), y = Symbol.for("react.context"), f = Symbol.for("react.forward_ref"), b = Symbol.for("react.suspense"), s = Symbol.for("react.suspense_list"), g = Symbol.for("react.memo"), F = Symbol.for("react.lazy"), M = Symbol.for("react.offscreen"), U = Symbol.iterator, Z = "@@iterator";
|
|
40
41
|
function Q(e) {
|
|
41
42
|
if (e === null || typeof e != "object")
|
|
42
43
|
return null;
|
|
43
|
-
var r =
|
|
44
|
+
var r = U && e[U] || e[Z];
|
|
44
45
|
return typeof r == "function" ? r : null;
|
|
45
46
|
}
|
|
46
47
|
var P = C.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
47
|
-
function
|
|
48
|
+
function p(e) {
|
|
48
49
|
{
|
|
49
50
|
for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), n = 1; n < r; n++)
|
|
50
51
|
t[n - 1] = arguments[n];
|
|
@@ -55,20 +56,20 @@ function br() {
|
|
|
55
56
|
{
|
|
56
57
|
var n = P.ReactDebugCurrentFrame, u = n.getStackAddendum();
|
|
57
58
|
u !== "" && (r += "%s", t = t.concat([u]));
|
|
58
|
-
var
|
|
59
|
+
var c = t.map(function(o) {
|
|
59
60
|
return String(o);
|
|
60
61
|
});
|
|
61
|
-
|
|
62
|
+
c.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, c);
|
|
62
63
|
}
|
|
63
64
|
}
|
|
64
|
-
var le = !1,
|
|
65
|
-
|
|
66
|
-
function
|
|
67
|
-
return !!(typeof e == "string" || typeof e == "function" || e === x || e === w || te || e === O || e ===
|
|
65
|
+
var le = !1, ce = !1, re = !1, B = !1, te = !1, q;
|
|
66
|
+
q = Symbol.for("react.module.reference");
|
|
67
|
+
function fe(e) {
|
|
68
|
+
return !!(typeof e == "string" || typeof e == "function" || e === x || e === w || te || e === O || e === b || e === s || B || e === M || le || ce || re || typeof e == "object" && e !== null && (e.$$typeof === F || e.$$typeof === g || e.$$typeof === S || e.$$typeof === y || e.$$typeof === f || // This needs to include all possible module reference object
|
|
68
69
|
// types supported by any Flight configuration anywhere since
|
|
69
70
|
// we don't know which Flight build this will end up being used
|
|
70
71
|
// with.
|
|
71
|
-
e.$$typeof ===
|
|
72
|
+
e.$$typeof === q || e.getModuleId !== void 0));
|
|
72
73
|
}
|
|
73
74
|
function ne(e, r, t) {
|
|
74
75
|
var n = e.displayName;
|
|
@@ -83,7 +84,7 @@ function br() {
|
|
|
83
84
|
function j(e) {
|
|
84
85
|
if (e == null)
|
|
85
86
|
return null;
|
|
86
|
-
if (typeof e.tag == "number" &&
|
|
87
|
+
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")
|
|
87
88
|
return e.displayName || e.name || null;
|
|
88
89
|
if (typeof e == "string")
|
|
89
90
|
return e;
|
|
@@ -96,28 +97,28 @@ function br() {
|
|
|
96
97
|
return "Profiler";
|
|
97
98
|
case O:
|
|
98
99
|
return "StrictMode";
|
|
99
|
-
case
|
|
100
|
+
case b:
|
|
100
101
|
return "Suspense";
|
|
101
102
|
case s:
|
|
102
103
|
return "SuspenseList";
|
|
103
104
|
}
|
|
104
105
|
if (typeof e == "object")
|
|
105
106
|
switch (e.$$typeof) {
|
|
106
|
-
case
|
|
107
|
+
case y:
|
|
107
108
|
var r = e;
|
|
108
109
|
return de(r) + ".Consumer";
|
|
109
110
|
case S:
|
|
110
111
|
var t = e;
|
|
111
112
|
return de(t._context) + ".Provider";
|
|
112
|
-
case
|
|
113
|
+
case f:
|
|
113
114
|
return ne(e, e.render, "ForwardRef");
|
|
114
|
-
case
|
|
115
|
+
case g:
|
|
115
116
|
var n = e.displayName || null;
|
|
116
117
|
return n !== null ? n : j(e.type) || "Memo";
|
|
117
118
|
case F: {
|
|
118
|
-
var u = e,
|
|
119
|
+
var u = e, c = u._payload, o = u._init;
|
|
119
120
|
try {
|
|
120
|
-
return j(o(
|
|
121
|
+
return j(o(c));
|
|
121
122
|
} catch {
|
|
122
123
|
return null;
|
|
123
124
|
}
|
|
@@ -125,18 +126,18 @@ function br() {
|
|
|
125
126
|
}
|
|
126
127
|
return null;
|
|
127
128
|
}
|
|
128
|
-
var
|
|
129
|
-
function
|
|
129
|
+
var D = Object.assign, $ = 0, pe, ve, he, ye, me, _e, be;
|
|
130
|
+
function ge() {
|
|
130
131
|
}
|
|
131
|
-
|
|
132
|
+
ge.__reactDisabledLog = !0;
|
|
132
133
|
function je() {
|
|
133
134
|
{
|
|
134
|
-
if (
|
|
135
|
-
|
|
135
|
+
if ($ === 0) {
|
|
136
|
+
pe = console.log, ve = console.info, he = console.warn, ye = console.error, me = console.group, _e = console.groupCollapsed, be = console.groupEnd;
|
|
136
137
|
var e = {
|
|
137
138
|
configurable: !0,
|
|
138
139
|
enumerable: !0,
|
|
139
|
-
value:
|
|
140
|
+
value: ge,
|
|
140
141
|
writable: !0
|
|
141
142
|
};
|
|
142
143
|
Object.defineProperties(console, {
|
|
@@ -149,46 +150,46 @@ function br() {
|
|
|
149
150
|
groupEnd: e
|
|
150
151
|
});
|
|
151
152
|
}
|
|
152
|
-
|
|
153
|
+
$++;
|
|
153
154
|
}
|
|
154
155
|
}
|
|
155
|
-
function
|
|
156
|
+
function Ne() {
|
|
156
157
|
{
|
|
157
|
-
if (
|
|
158
|
+
if ($--, $ === 0) {
|
|
158
159
|
var e = {
|
|
159
160
|
configurable: !0,
|
|
160
161
|
enumerable: !0,
|
|
161
162
|
writable: !0
|
|
162
163
|
};
|
|
163
164
|
Object.defineProperties(console, {
|
|
164
|
-
log:
|
|
165
|
-
value: ve
|
|
166
|
-
}),
|
|
167
|
-
info: $({}, e, {
|
|
165
|
+
log: D({}, e, {
|
|
168
166
|
value: pe
|
|
169
167
|
}),
|
|
170
|
-
|
|
171
|
-
value:
|
|
168
|
+
info: D({}, e, {
|
|
169
|
+
value: ve
|
|
172
170
|
}),
|
|
173
|
-
|
|
171
|
+
warn: D({}, e, {
|
|
174
172
|
value: he
|
|
175
173
|
}),
|
|
176
|
-
|
|
177
|
-
value:
|
|
174
|
+
error: D({}, e, {
|
|
175
|
+
value: ye
|
|
178
176
|
}),
|
|
179
|
-
|
|
180
|
-
value:
|
|
177
|
+
group: D({}, e, {
|
|
178
|
+
value: me
|
|
181
179
|
}),
|
|
182
|
-
|
|
180
|
+
groupCollapsed: D({}, e, {
|
|
183
181
|
value: _e
|
|
182
|
+
}),
|
|
183
|
+
groupEnd: D({}, e, {
|
|
184
|
+
value: be
|
|
184
185
|
})
|
|
185
186
|
});
|
|
186
187
|
}
|
|
187
|
-
|
|
188
|
+
$ < 0 && p("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
188
189
|
}
|
|
189
190
|
}
|
|
190
191
|
var ae = P.ReactCurrentDispatcher, ie;
|
|
191
|
-
function
|
|
192
|
+
function A(e, r, t) {
|
|
192
193
|
{
|
|
193
194
|
if (ie === void 0)
|
|
194
195
|
try {
|
|
@@ -201,25 +202,25 @@ function br() {
|
|
|
201
202
|
` + ie + e;
|
|
202
203
|
}
|
|
203
204
|
}
|
|
204
|
-
var
|
|
205
|
+
var I = !1, W;
|
|
205
206
|
{
|
|
206
207
|
var Te = typeof WeakMap == "function" ? WeakMap : Map;
|
|
207
|
-
|
|
208
|
+
W = new Te();
|
|
208
209
|
}
|
|
209
|
-
function
|
|
210
|
-
if (!e ||
|
|
210
|
+
function N(e, r) {
|
|
211
|
+
if (!e || I)
|
|
211
212
|
return "";
|
|
212
213
|
{
|
|
213
|
-
var t =
|
|
214
|
+
var t = W.get(e);
|
|
214
215
|
if (t !== void 0)
|
|
215
216
|
return t;
|
|
216
217
|
}
|
|
217
218
|
var n;
|
|
218
|
-
|
|
219
|
+
I = !0;
|
|
219
220
|
var u = Error.prepareStackTrace;
|
|
220
221
|
Error.prepareStackTrace = void 0;
|
|
221
|
-
var
|
|
222
|
-
|
|
222
|
+
var c;
|
|
223
|
+
c = ae.current, ae.current = null, je();
|
|
223
224
|
try {
|
|
224
225
|
if (r) {
|
|
225
226
|
var o = function() {
|
|
@@ -255,93 +256,93 @@ function br() {
|
|
|
255
256
|
} catch (E) {
|
|
256
257
|
if (E && n && typeof E.stack == "string") {
|
|
257
258
|
for (var i = E.stack.split(`
|
|
258
|
-
`),
|
|
259
|
-
`), d = i.length - 1,
|
|
260
|
-
|
|
261
|
-
for (; d >= 1 &&
|
|
262
|
-
if (i[d] !==
|
|
263
|
-
if (d !== 1 ||
|
|
259
|
+
`), m = n.stack.split(`
|
|
260
|
+
`), d = i.length - 1, v = m.length - 1; d >= 1 && v >= 0 && i[d] !== m[v]; )
|
|
261
|
+
v--;
|
|
262
|
+
for (; d >= 1 && v >= 0; d--, v--)
|
|
263
|
+
if (i[d] !== m[v]) {
|
|
264
|
+
if (d !== 1 || v !== 1)
|
|
264
265
|
do
|
|
265
|
-
if (d--,
|
|
266
|
+
if (d--, v--, v < 0 || i[d] !== m[v]) {
|
|
266
267
|
var T = `
|
|
267
268
|
` + i[d].replace(" at new ", " at ");
|
|
268
|
-
return e.displayName && T.includes("<anonymous>") && (T = T.replace("<anonymous>", e.displayName)), typeof e == "function" &&
|
|
269
|
+
return e.displayName && T.includes("<anonymous>") && (T = T.replace("<anonymous>", e.displayName)), typeof e == "function" && W.set(e, T), T;
|
|
269
270
|
}
|
|
270
|
-
while (d >= 1 &&
|
|
271
|
+
while (d >= 1 && v >= 0);
|
|
271
272
|
break;
|
|
272
273
|
}
|
|
273
274
|
}
|
|
274
275
|
} finally {
|
|
275
|
-
|
|
276
|
+
I = !1, ae.current = c, Ne(), Error.prepareStackTrace = u;
|
|
276
277
|
}
|
|
277
|
-
var X = e ? e.displayName || e.name : "",
|
|
278
|
-
return typeof e == "function" &&
|
|
278
|
+
var X = e ? e.displayName || e.name : "", V = X ? A(X) : "";
|
|
279
|
+
return typeof e == "function" && W.set(e, V), V;
|
|
279
280
|
}
|
|
280
281
|
function we(e, r, t) {
|
|
281
|
-
return
|
|
282
|
+
return N(e, !1);
|
|
282
283
|
}
|
|
283
284
|
function Se(e) {
|
|
284
285
|
var r = e.prototype;
|
|
285
286
|
return !!(r && r.isReactComponent);
|
|
286
287
|
}
|
|
287
|
-
function
|
|
288
|
+
function H(e, r, t) {
|
|
288
289
|
if (e == null)
|
|
289
290
|
return "";
|
|
290
291
|
if (typeof e == "function")
|
|
291
|
-
return
|
|
292
|
+
return N(e, Se(e));
|
|
292
293
|
if (typeof e == "string")
|
|
293
|
-
return
|
|
294
|
+
return A(e);
|
|
294
295
|
switch (e) {
|
|
295
|
-
case
|
|
296
|
-
return
|
|
296
|
+
case b:
|
|
297
|
+
return A("Suspense");
|
|
297
298
|
case s:
|
|
298
|
-
return
|
|
299
|
+
return A("SuspenseList");
|
|
299
300
|
}
|
|
300
301
|
if (typeof e == "object")
|
|
301
302
|
switch (e.$$typeof) {
|
|
302
|
-
case
|
|
303
|
+
case f:
|
|
303
304
|
return we(e.render);
|
|
304
|
-
case
|
|
305
|
-
return
|
|
305
|
+
case g:
|
|
306
|
+
return H(e.type, r, t);
|
|
306
307
|
case F: {
|
|
307
|
-
var n = e, u = n._payload,
|
|
308
|
+
var n = e, u = n._payload, c = n._init;
|
|
308
309
|
try {
|
|
309
|
-
return
|
|
310
|
+
return H(c(u), r, t);
|
|
310
311
|
} catch {
|
|
311
312
|
}
|
|
312
313
|
}
|
|
313
314
|
}
|
|
314
315
|
return "";
|
|
315
316
|
}
|
|
316
|
-
var
|
|
317
|
-
function
|
|
317
|
+
var L = Object.prototype.hasOwnProperty, Ee = {}, Re = P.ReactDebugCurrentFrame;
|
|
318
|
+
function K(e) {
|
|
318
319
|
if (e) {
|
|
319
|
-
var r = e._owner, t =
|
|
320
|
+
var r = e._owner, t = H(e.type, e._source, r ? r.type : null);
|
|
320
321
|
Re.setExtraStackFrame(t);
|
|
321
322
|
} else
|
|
322
323
|
Re.setExtraStackFrame(null);
|
|
323
324
|
}
|
|
324
325
|
function Ce(e, r, t, n, u) {
|
|
325
326
|
{
|
|
326
|
-
var
|
|
327
|
+
var c = Function.call.bind(L);
|
|
327
328
|
for (var o in e)
|
|
328
|
-
if (
|
|
329
|
+
if (c(e, o)) {
|
|
329
330
|
var i = void 0;
|
|
330
331
|
try {
|
|
331
332
|
if (typeof e[o] != "function") {
|
|
332
|
-
var
|
|
333
|
-
throw
|
|
333
|
+
var m = Error((n || "React class") + ": " + t + " type `" + o + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[o] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
334
|
+
throw m.name = "Invariant Violation", m;
|
|
334
335
|
}
|
|
335
336
|
i = e[o](r, o, n, t, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
336
337
|
} catch (d) {
|
|
337
338
|
i = d;
|
|
338
339
|
}
|
|
339
|
-
i && !(i instanceof Error) && (
|
|
340
|
+
i && !(i instanceof Error) && (K(u), 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).", n || "React class", t, o, typeof i), K(null)), i instanceof Error && !(i.message in Ee) && (Ee[i.message] = !0, K(u), p("Failed %s type: %s", t, i.message), K(null));
|
|
340
341
|
}
|
|
341
342
|
}
|
|
342
343
|
}
|
|
343
344
|
var Pe = Array.isArray;
|
|
344
|
-
function
|
|
345
|
+
function J(e) {
|
|
345
346
|
return Pe(e);
|
|
346
347
|
}
|
|
347
348
|
function ke(e) {
|
|
@@ -362,17 +363,17 @@ function br() {
|
|
|
362
363
|
}
|
|
363
364
|
function k(e) {
|
|
364
365
|
if (xe(e))
|
|
365
|
-
return
|
|
366
|
+
return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", ke(e)), a(e);
|
|
366
367
|
}
|
|
367
|
-
var
|
|
368
|
+
var Y = P.ReactCurrentOwner, Ze = {
|
|
368
369
|
key: !0,
|
|
369
370
|
ref: !0,
|
|
370
371
|
__self: !0,
|
|
371
372
|
__source: !0
|
|
372
|
-
},
|
|
373
|
+
}, Le, Ye, Oe;
|
|
373
374
|
Oe = {};
|
|
374
375
|
function Qe(e) {
|
|
375
|
-
if (
|
|
376
|
+
if (L.call(e, "ref")) {
|
|
376
377
|
var r = Object.getOwnPropertyDescriptor(e, "ref").get;
|
|
377
378
|
if (r && r.isReactWarning)
|
|
378
379
|
return !1;
|
|
@@ -380,7 +381,7 @@ function br() {
|
|
|
380
381
|
return e.ref !== void 0;
|
|
381
382
|
}
|
|
382
383
|
function er(e) {
|
|
383
|
-
if (
|
|
384
|
+
if (L.call(e, "key")) {
|
|
384
385
|
var r = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
385
386
|
if (r && r.isReactWarning)
|
|
386
387
|
return !1;
|
|
@@ -388,15 +389,15 @@ function br() {
|
|
|
388
389
|
return e.key !== void 0;
|
|
389
390
|
}
|
|
390
391
|
function rr(e, r) {
|
|
391
|
-
if (typeof e.ref == "string" &&
|
|
392
|
-
var t = j(
|
|
393
|
-
Oe[t] || (
|
|
392
|
+
if (typeof e.ref == "string" && Y.current && r && Y.current.stateNode !== r) {
|
|
393
|
+
var t = j(Y.current.type);
|
|
394
|
+
Oe[t] || (p('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', j(Y.current.type), e.ref), Oe[t] = !0);
|
|
394
395
|
}
|
|
395
396
|
}
|
|
396
397
|
function tr(e, r) {
|
|
397
398
|
{
|
|
398
399
|
var t = function() {
|
|
399
|
-
|
|
400
|
+
Le || (Le = !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)", r));
|
|
400
401
|
};
|
|
401
402
|
t.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
402
403
|
get: t,
|
|
@@ -407,7 +408,7 @@ function br() {
|
|
|
407
408
|
function nr(e, r) {
|
|
408
409
|
{
|
|
409
410
|
var t = function() {
|
|
410
|
-
|
|
411
|
+
Ye || (Ye = !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)", r));
|
|
411
412
|
};
|
|
412
413
|
t.isReactWarning = !0, Object.defineProperty(e, "ref", {
|
|
413
414
|
get: t,
|
|
@@ -415,17 +416,17 @@ function br() {
|
|
|
415
416
|
});
|
|
416
417
|
}
|
|
417
418
|
}
|
|
418
|
-
var ar = function(e, r, t, n, u,
|
|
419
|
+
var ar = function(e, r, t, n, u, c, o) {
|
|
419
420
|
var i = {
|
|
420
421
|
// This tag allows us to uniquely identify this as a React Element
|
|
421
|
-
$$typeof:
|
|
422
|
+
$$typeof: _,
|
|
422
423
|
// Built-in properties that belong on the element
|
|
423
424
|
type: e,
|
|
424
425
|
key: r,
|
|
425
426
|
ref: t,
|
|
426
427
|
props: o,
|
|
427
428
|
// Record the component responsible for creating this element.
|
|
428
|
-
_owner:
|
|
429
|
+
_owner: c
|
|
429
430
|
};
|
|
430
431
|
return i._store = {}, Object.defineProperty(i._store, "validated", {
|
|
431
432
|
configurable: !1,
|
|
@@ -446,36 +447,36 @@ function br() {
|
|
|
446
447
|
};
|
|
447
448
|
function ir(e, r, t, n, u) {
|
|
448
449
|
{
|
|
449
|
-
var
|
|
450
|
-
t !== void 0 && (k(t), i = "" + t), er(r) && (k(r.key), i = "" + r.key), Qe(r) && (
|
|
451
|
-
for (
|
|
452
|
-
|
|
450
|
+
var c, o = {}, i = null, m = null;
|
|
451
|
+
t !== void 0 && (k(t), i = "" + t), er(r) && (k(r.key), i = "" + r.key), Qe(r) && (m = r.ref, rr(r, u));
|
|
452
|
+
for (c in r)
|
|
453
|
+
L.call(r, c) && !Ze.hasOwnProperty(c) && (o[c] = r[c]);
|
|
453
454
|
if (e && e.defaultProps) {
|
|
454
455
|
var d = e.defaultProps;
|
|
455
|
-
for (
|
|
456
|
-
o[
|
|
456
|
+
for (c in d)
|
|
457
|
+
o[c] === void 0 && (o[c] = d[c]);
|
|
457
458
|
}
|
|
458
|
-
if (i ||
|
|
459
|
-
var
|
|
460
|
-
i && tr(o,
|
|
459
|
+
if (i || m) {
|
|
460
|
+
var v = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
|
|
461
|
+
i && tr(o, v), m && nr(o, v);
|
|
461
462
|
}
|
|
462
|
-
return ar(e, i,
|
|
463
|
+
return ar(e, i, m, u, n, Y.current, o);
|
|
463
464
|
}
|
|
464
465
|
}
|
|
465
|
-
var Fe = P.ReactCurrentOwner,
|
|
466
|
+
var Fe = P.ReactCurrentOwner, Ve = P.ReactDebugCurrentFrame;
|
|
466
467
|
function G(e) {
|
|
467
468
|
if (e) {
|
|
468
|
-
var r = e._owner, t =
|
|
469
|
-
|
|
469
|
+
var r = e._owner, t = H(e.type, e._source, r ? r.type : null);
|
|
470
|
+
Ve.setExtraStackFrame(t);
|
|
470
471
|
} else
|
|
471
|
-
|
|
472
|
+
Ve.setExtraStackFrame(null);
|
|
472
473
|
}
|
|
473
|
-
var
|
|
474
|
-
|
|
475
|
-
function
|
|
476
|
-
return typeof e == "object" && e !== null && e.$$typeof ===
|
|
474
|
+
var De;
|
|
475
|
+
De = !1;
|
|
476
|
+
function $e(e) {
|
|
477
|
+
return typeof e == "object" && e !== null && e.$$typeof === _;
|
|
477
478
|
}
|
|
478
|
-
function
|
|
479
|
+
function Me() {
|
|
479
480
|
{
|
|
480
481
|
if (Fe.current) {
|
|
481
482
|
var e = j(Fe.current.type);
|
|
@@ -490,10 +491,10 @@ Check the render method of \`` + e + "`.";
|
|
|
490
491
|
function or(e) {
|
|
491
492
|
return "";
|
|
492
493
|
}
|
|
493
|
-
var
|
|
494
|
+
var Ue = {};
|
|
494
495
|
function sr(e) {
|
|
495
496
|
{
|
|
496
|
-
var r =
|
|
497
|
+
var r = Me();
|
|
497
498
|
if (!r) {
|
|
498
499
|
var t = typeof e == "string" ? e : e.displayName || e.name;
|
|
499
500
|
t && (r = `
|
|
@@ -503,35 +504,35 @@ Check the top-level render call using <` + t + ">.");
|
|
|
503
504
|
return r;
|
|
504
505
|
}
|
|
505
506
|
}
|
|
506
|
-
function
|
|
507
|
+
function Be(e, r) {
|
|
507
508
|
{
|
|
508
509
|
if (!e._store || e._store.validated || e.key != null)
|
|
509
510
|
return;
|
|
510
511
|
e._store.validated = !0;
|
|
511
512
|
var t = sr(r);
|
|
512
|
-
if (
|
|
513
|
+
if (Ue[t])
|
|
513
514
|
return;
|
|
514
|
-
|
|
515
|
+
Ue[t] = !0;
|
|
515
516
|
var n = "";
|
|
516
|
-
e && e._owner && e._owner !== Fe.current && (n = " It was passed a child from " + j(e._owner.type) + "."), G(e),
|
|
517
|
+
e && e._owner && e._owner !== Fe.current && (n = " It was passed a child from " + j(e._owner.type) + "."), G(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.', t, n), G(null);
|
|
517
518
|
}
|
|
518
519
|
}
|
|
519
|
-
function
|
|
520
|
+
function qe(e, r) {
|
|
520
521
|
{
|
|
521
522
|
if (typeof e != "object")
|
|
522
523
|
return;
|
|
523
|
-
if (
|
|
524
|
+
if (J(e))
|
|
524
525
|
for (var t = 0; t < e.length; t++) {
|
|
525
526
|
var n = e[t];
|
|
526
|
-
|
|
527
|
+
$e(n) && Be(n, r);
|
|
527
528
|
}
|
|
528
|
-
else if (
|
|
529
|
+
else if ($e(e))
|
|
529
530
|
e._store && (e._store.validated = !0);
|
|
530
531
|
else if (e) {
|
|
531
532
|
var u = Q(e);
|
|
532
533
|
if (typeof u == "function" && u !== e.entries)
|
|
533
|
-
for (var
|
|
534
|
-
|
|
534
|
+
for (var c = u.call(e), o; !(o = c.next()).done; )
|
|
535
|
+
$e(o.value) && Be(o.value, r);
|
|
535
536
|
}
|
|
536
537
|
}
|
|
537
538
|
}
|
|
@@ -543,21 +544,21 @@ Check the top-level render call using <` + t + ">.");
|
|
|
543
544
|
var t;
|
|
544
545
|
if (typeof r == "function")
|
|
545
546
|
t = r.propTypes;
|
|
546
|
-
else if (typeof r == "object" && (r.$$typeof ===
|
|
547
|
+
else if (typeof r == "object" && (r.$$typeof === f || // Note: Memo only checks outer props here.
|
|
547
548
|
// Inner props are checked in the reconciler.
|
|
548
|
-
r.$$typeof ===
|
|
549
|
+
r.$$typeof === g))
|
|
549
550
|
t = r.propTypes;
|
|
550
551
|
else
|
|
551
552
|
return;
|
|
552
553
|
if (t) {
|
|
553
554
|
var n = j(r);
|
|
554
555
|
Ce(t, e.props, "prop", n, e);
|
|
555
|
-
} else if (r.PropTypes !== void 0 &&
|
|
556
|
-
|
|
556
|
+
} else if (r.PropTypes !== void 0 && !De) {
|
|
557
|
+
De = !0;
|
|
557
558
|
var u = j(r);
|
|
558
|
-
|
|
559
|
+
p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", u || "Unknown");
|
|
559
560
|
}
|
|
560
|
-
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved &&
|
|
561
|
+
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
561
562
|
}
|
|
562
563
|
}
|
|
563
564
|
function lr(e) {
|
|
@@ -565,99 +566,115 @@ Check the top-level render call using <` + t + ">.");
|
|
|
565
566
|
for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {
|
|
566
567
|
var n = r[t];
|
|
567
568
|
if (n !== "children" && n !== "key") {
|
|
568
|
-
G(e),
|
|
569
|
+
G(e), p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", n), G(null);
|
|
569
570
|
break;
|
|
570
571
|
}
|
|
571
572
|
}
|
|
572
|
-
e.ref !== null && (G(e),
|
|
573
|
+
e.ref !== null && (G(e), p("Invalid attribute `ref` supplied to `React.Fragment`."), G(null));
|
|
573
574
|
}
|
|
574
575
|
}
|
|
575
|
-
var
|
|
576
|
-
function
|
|
576
|
+
var He = {};
|
|
577
|
+
function Ke(e, r, t, n, u, c) {
|
|
577
578
|
{
|
|
578
|
-
var o =
|
|
579
|
+
var o = fe(e);
|
|
579
580
|
if (!o) {
|
|
580
581
|
var i = "";
|
|
581
582
|
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (i += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
582
|
-
var
|
|
583
|
-
|
|
583
|
+
var m = or();
|
|
584
|
+
m ? i += m : i += Me();
|
|
584
585
|
var d;
|
|
585
|
-
e === null ? d = "null" :
|
|
586
|
+
e === null ? d = "null" : J(e) ? d = "array" : e !== void 0 && e.$$typeof === _ ? (d = "<" + (j(e.type) || "Unknown") + " />", i = " Did you accidentally export a JSX literal instead of a component?") : d = 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", d, i);
|
|
586
587
|
}
|
|
587
|
-
var
|
|
588
|
-
if (
|
|
589
|
-
return
|
|
588
|
+
var v = ir(e, r, t, u, c);
|
|
589
|
+
if (v == null)
|
|
590
|
+
return v;
|
|
590
591
|
if (o) {
|
|
591
592
|
var T = r.children;
|
|
592
593
|
if (T !== void 0)
|
|
593
594
|
if (n)
|
|
594
|
-
if (
|
|
595
|
+
if (J(T)) {
|
|
595
596
|
for (var X = 0; X < T.length; X++)
|
|
596
|
-
|
|
597
|
+
qe(T[X], e);
|
|
597
598
|
Object.freeze && Object.freeze(T);
|
|
598
599
|
} else
|
|
599
|
-
|
|
600
|
+
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.");
|
|
600
601
|
else
|
|
601
|
-
|
|
602
|
+
qe(T, e);
|
|
602
603
|
}
|
|
603
|
-
if (
|
|
604
|
-
var
|
|
605
|
-
return
|
|
606
|
-
}),
|
|
607
|
-
if (!
|
|
608
|
-
var
|
|
609
|
-
|
|
604
|
+
if (L.call(r, "key")) {
|
|
605
|
+
var V = j(e), E = Object.keys(r).filter(function(hr) {
|
|
606
|
+
return hr !== "key";
|
|
607
|
+
}), Ae = E.length > 0 ? "{key: someKey, " + E.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
608
|
+
if (!He[V + Ae]) {
|
|
609
|
+
var vr = E.length > 0 ? "{" + E.join(": ..., ") + ": ...}" : "{}";
|
|
610
|
+
p(`A props object containing a "key" prop is being spread into JSX:
|
|
610
611
|
let props = %s;
|
|
611
612
|
<%s {...props} />
|
|
612
613
|
React keys must be passed directly to JSX without using spread:
|
|
613
614
|
let props = %s;
|
|
614
|
-
<%s key={someKey} {...props} />`,
|
|
615
|
+
<%s key={someKey} {...props} />`, Ae, V, vr, V), He[V + Ae] = !0;
|
|
615
616
|
}
|
|
616
617
|
}
|
|
617
|
-
return e === x ? lr(
|
|
618
|
+
return e === x ? lr(v) : ur(v), v;
|
|
618
619
|
}
|
|
619
620
|
}
|
|
620
|
-
function fr(e, r, t) {
|
|
621
|
-
return qe(e, r, t, !0);
|
|
622
|
-
}
|
|
623
621
|
function cr(e, r, t) {
|
|
624
|
-
return
|
|
622
|
+
return Ke(e, r, t, !0);
|
|
625
623
|
}
|
|
626
|
-
|
|
627
|
-
|
|
624
|
+
function fr(e, r, t) {
|
|
625
|
+
return Ke(e, r, t, !1);
|
|
626
|
+
}
|
|
627
|
+
var dr = fr, pr = cr;
|
|
628
|
+
ue.Fragment = x, ue.jsx = dr, ue.jsxs = pr;
|
|
628
629
|
}()), ue;
|
|
629
630
|
}
|
|
630
|
-
process.env.NODE_ENV === "production" ?
|
|
631
|
-
var l =
|
|
632
|
-
const z = {},
|
|
631
|
+
process.env.NODE_ENV === "production" ? We.exports = yr() : We.exports = mr();
|
|
632
|
+
var l = We.exports;
|
|
633
|
+
const z = {}, Ir = ({
|
|
633
634
|
label: C,
|
|
634
|
-
buttonType:
|
|
635
|
+
buttonType: _ = "button",
|
|
635
636
|
onClick: R,
|
|
636
637
|
size: x = "md",
|
|
637
638
|
disabled: O,
|
|
638
639
|
withIcons: w,
|
|
639
640
|
iconOne: S,
|
|
640
|
-
iconTwo:
|
|
641
|
-
onlyIcon:
|
|
642
|
-
buttonStyle:
|
|
641
|
+
iconTwo: y,
|
|
642
|
+
onlyIcon: f,
|
|
643
|
+
buttonStyle: b,
|
|
643
644
|
labelStyle: s,
|
|
644
|
-
buttonSlotStyle:
|
|
645
|
+
buttonSlotStyle: g
|
|
645
646
|
}) => /* @__PURE__ */ l.jsx(
|
|
646
647
|
"button",
|
|
647
648
|
{
|
|
648
|
-
type:
|
|
649
|
-
style:
|
|
650
|
-
className: `${z.mainButton} ${
|
|
649
|
+
type: _,
|
|
650
|
+
style: b && typeof b == "object" ? b : {},
|
|
651
|
+
className: `${z.mainButton} ${f ? z.onlyIcon : ""} ${x ? z[x] : ""} ${O ? z.disabled : ""}`,
|
|
651
652
|
onClick: () => {
|
|
652
653
|
R && typeof R == "function" && R();
|
|
653
654
|
},
|
|
654
|
-
children: /* @__PURE__ */ l.jsxs("div", { className: z.buttonSlot, style:
|
|
655
|
-
|
|
656
|
-
!
|
|
657
|
-
w &&
|
|
655
|
+
children: /* @__PURE__ */ l.jsxs("div", { className: z.buttonSlot, style: g ?? {}, children: [
|
|
656
|
+
f || w && S ? S : "",
|
|
657
|
+
!f && /* @__PURE__ */ l.jsx("span", { style: s ?? {}, className: z.buttonLabel, children: C ?? "Button" }),
|
|
658
|
+
w && y ? y : ""
|
|
658
659
|
] })
|
|
659
660
|
}
|
|
660
|
-
),
|
|
661
|
+
), _r = "FormInput-module__inputWrapper", br = "FormInput-module__inputLabel", gr = "FormInput-module__required", Er = "FormInput-module__inputContainer", Rr = "FormInput-module__focused", Cr = "FormInput-module__error", xr = "FormInput-module__rightIcon", jr = "FormInput-module__leftIcon", Tr = "FormInput-module__inputDropDown", wr = "FormInput-module__http", Sr = "FormInput-module__disabled", Pr = "FormInput-module__sm", kr = "FormInput-module__md", Or = "FormInput-module__withCopy", Fr = "FormInput-module__inputHelperText", h = {
|
|
662
|
+
inputWrapper: _r,
|
|
663
|
+
inputLabel: br,
|
|
664
|
+
required: gr,
|
|
665
|
+
inputContainer: Er,
|
|
666
|
+
focused: Rr,
|
|
667
|
+
error: Cr,
|
|
668
|
+
rightIcon: xr,
|
|
669
|
+
leftIcon: jr,
|
|
670
|
+
inputDropDown: Tr,
|
|
671
|
+
http: wr,
|
|
672
|
+
disabled: Sr,
|
|
673
|
+
sm: Pr,
|
|
674
|
+
md: kr,
|
|
675
|
+
withCopy: Or,
|
|
676
|
+
inputHelperText: Fr
|
|
677
|
+
}, Dr = ({ width: C, height: _, color: R }) => /* @__PURE__ */ l.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: C ?? "12", height: _ ?? "8", viewBox: "0 0 12 8", fill: "none", children: /* @__PURE__ */ l.jsx("path", { d: "M1 1.5L6 6.5L11 1.5", stroke: R ?? "#A4A7AE", strokeWidth: "1.66667", strokeLinecap: "round", strokeLinejoin: "round" }) }), $r = ({ width: C, height: _, color: R }) => /* @__PURE__ */ l.jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: C ?? "20", height: _ ?? "20", viewBox: "0 0 20 20", fill: "none", children: [
|
|
661
678
|
/* @__PURE__ */ l.jsx("g", { clipPath: "url(#clip0_444_26)", children: /* @__PURE__ */ l.jsx(
|
|
662
679
|
"path",
|
|
663
680
|
{
|
|
@@ -669,128 +686,128 @@ const z = {}, Er = ({
|
|
|
669
686
|
}
|
|
670
687
|
) }),
|
|
671
688
|
/* @__PURE__ */ l.jsx("defs", { children: /* @__PURE__ */ l.jsx("clipPath", { id: "clip0_444_26", children: /* @__PURE__ */ l.jsx("rect", { width: "20", height: "20", fill: "white" }) }) })
|
|
672
|
-
] }),
|
|
689
|
+
] }), Wr = ({
|
|
673
690
|
value: C,
|
|
674
|
-
label:
|
|
691
|
+
label: _,
|
|
675
692
|
placeholder: R,
|
|
676
693
|
required: x,
|
|
677
694
|
disabled: O,
|
|
678
695
|
type: w,
|
|
679
696
|
size: S,
|
|
680
|
-
onChange:
|
|
681
|
-
onFouce:
|
|
682
|
-
onBlur:
|
|
697
|
+
onChange: y,
|
|
698
|
+
onFouce: f,
|
|
699
|
+
onBlur: b,
|
|
683
700
|
msg: s,
|
|
684
|
-
readOnly:
|
|
701
|
+
readOnly: g,
|
|
685
702
|
maxLength: F,
|
|
686
|
-
onlyText:
|
|
687
|
-
onRightIconIconClick:
|
|
703
|
+
onlyText: M,
|
|
704
|
+
onRightIconIconClick: U,
|
|
688
705
|
onRightIconIconMouseEnter: Z,
|
|
689
706
|
onRightIconIconMouseLeave: Q,
|
|
690
707
|
onLeftIconIconClick: P,
|
|
691
|
-
onLeftIconIconMouseEnter:
|
|
708
|
+
onLeftIconIconMouseEnter: p,
|
|
692
709
|
onLeftIconIconMouseLeave: ee,
|
|
693
710
|
rightIcon: le,
|
|
694
|
-
leftIcon:
|
|
711
|
+
leftIcon: ce,
|
|
695
712
|
withDropDown: re,
|
|
696
|
-
dropdownData:
|
|
713
|
+
dropdownData: B,
|
|
697
714
|
onSelectData: te,
|
|
698
|
-
withLink:
|
|
699
|
-
withCopy:
|
|
715
|
+
withLink: q,
|
|
716
|
+
withCopy: fe,
|
|
700
717
|
onCopy: ne,
|
|
701
718
|
inputWrapperStyle: de,
|
|
702
719
|
inputLabelStyle: j,
|
|
703
|
-
requiredStyle:
|
|
704
|
-
inputContainerStyle:
|
|
705
|
-
leftIconStyle:
|
|
706
|
-
inputDropDownStyle:
|
|
707
|
-
ulStyle:
|
|
708
|
-
liStyle:
|
|
709
|
-
httpStyle:
|
|
710
|
-
inputStyle:
|
|
711
|
-
rightIconStyle:
|
|
712
|
-
withCopyStyle:
|
|
720
|
+
requiredStyle: D,
|
|
721
|
+
inputContainerStyle: $,
|
|
722
|
+
leftIconStyle: pe,
|
|
723
|
+
inputDropDownStyle: ve,
|
|
724
|
+
ulStyle: he,
|
|
725
|
+
liStyle: ye,
|
|
726
|
+
httpStyle: me,
|
|
727
|
+
inputStyle: _e,
|
|
728
|
+
rightIconStyle: be,
|
|
729
|
+
withCopyStyle: ge,
|
|
713
730
|
inputHelperTextStyle: je
|
|
714
731
|
}) => {
|
|
715
|
-
const [
|
|
732
|
+
const [Ne, ae] = oe(!1), [ie, A] = oe(!1);
|
|
716
733
|
oe(!1);
|
|
717
|
-
const
|
|
734
|
+
const I = Ie(null), W = Ie(null), [Te, N] = oe(!1), [we, Se] = oe(1), H = (a) => {
|
|
718
735
|
let k = a.target.value;
|
|
719
|
-
k.length === 1 && (k = k.trim()),
|
|
720
|
-
},
|
|
721
|
-
|
|
736
|
+
k.length === 1 && (k = k.trim()), y && typeof y == "function" && y(M ? k.replace(/\d/g, "") : k);
|
|
737
|
+
}, L = () => {
|
|
738
|
+
A(!0), f && typeof f == "function" && f();
|
|
722
739
|
}, Ee = () => {
|
|
723
|
-
|
|
740
|
+
A(!1), b && typeof b == "function" && b();
|
|
724
741
|
}, Re = (a) => {
|
|
725
|
-
const
|
|
726
|
-
w === "number" && (a.keyCode === 69 || !
|
|
727
|
-
},
|
|
742
|
+
const Y = a.target.value.length === 0;
|
|
743
|
+
w === "number" && (a.keyCode === 69 || !Y && (a.keyCode === 187 || a.keyCode === 107 || a.keyCode === 189 || a.keyCode === 109)) && a.preventDefault();
|
|
744
|
+
}, K = () => {
|
|
728
745
|
ne && typeof ne == "function" && ne(C);
|
|
729
746
|
}, Ce = (a) => a, Pe = () => {
|
|
730
747
|
let a = {};
|
|
731
|
-
return
|
|
732
|
-
},
|
|
733
|
-
!a.composedPath().includes(
|
|
748
|
+
return fe && (a.borderTopRightRadius = 0, a.borderBottomRightRadius = 0, a.borderRight = 0), re && (a.paddingLeft = 0), { ...a, ...$ ?? {} };
|
|
749
|
+
}, J = (a) => {
|
|
750
|
+
!a.composedPath().includes(W.current) && a.composedPath().includes(I.current) || N(!1);
|
|
734
751
|
}, ke = (a) => {
|
|
735
|
-
Se(a.id),
|
|
752
|
+
Se(a.id), N(!1), te && typeof te == "function" && te(a);
|
|
736
753
|
};
|
|
737
|
-
|
|
738
|
-
document.removeEventListener("click",
|
|
754
|
+
Je(() => (document.addEventListener("click", J), () => {
|
|
755
|
+
document.removeEventListener("click", J);
|
|
739
756
|
}), []);
|
|
740
|
-
const xe =
|
|
741
|
-
return
|
|
757
|
+
const xe = Ie(!1);
|
|
758
|
+
return Je(() => {
|
|
742
759
|
xe.current ? setTimeout(() => {
|
|
743
760
|
ae((a) => !a);
|
|
744
761
|
}, 0) : xe.current = !0;
|
|
745
|
-
}, []), /* @__PURE__ */ l.jsxs("div", { className:
|
|
746
|
-
|
|
747
|
-
|
|
762
|
+
}, []), /* @__PURE__ */ l.jsxs("div", { className: h.inputWrapper, style: de ?? {}, children: [
|
|
763
|
+
_ && /* @__PURE__ */ l.jsxs("label", { className: h.inputLabel, style: j ?? {}, children: [
|
|
764
|
+
_,
|
|
748
765
|
" ",
|
|
749
|
-
/* @__PURE__ */ l.jsx("span", { className:
|
|
766
|
+
/* @__PURE__ */ l.jsx("span", { className: h.required, style: D ?? {}, children: x && "*" })
|
|
750
767
|
] }),
|
|
751
768
|
/* @__PURE__ */ l.jsxs("div", { style: { display: "flex", alignItems: "center" }, children: [
|
|
752
769
|
/* @__PURE__ */ l.jsxs(
|
|
753
770
|
"div",
|
|
754
771
|
{
|
|
755
772
|
style: Pe(),
|
|
756
|
-
className: `${
|
|
773
|
+
className: `${h.inputContainer} ${ie && !g ? h.focused : ""} ${O ? h.disabled : ""} ${s != null && s.error ? h.error : ""} ${h[S ?? "sm"]}`,
|
|
757
774
|
children: [
|
|
758
|
-
!re && !
|
|
775
|
+
!re && !q && ce && /* @__PURE__ */ l.jsx(
|
|
759
776
|
"div",
|
|
760
777
|
{
|
|
761
|
-
className:
|
|
762
|
-
style:
|
|
778
|
+
className: h.leftIcon,
|
|
779
|
+
style: pe ?? {},
|
|
763
780
|
onClick: () => {
|
|
764
781
|
P && typeof P == "function" && P();
|
|
765
782
|
},
|
|
766
783
|
onMouseEnter: () => {
|
|
767
|
-
|
|
784
|
+
p && typeof p == "function" && p();
|
|
768
785
|
},
|
|
769
786
|
onMouseLeave: () => {
|
|
770
787
|
ee && typeof ee == "function" && ee();
|
|
771
788
|
},
|
|
772
|
-
children: Ce(
|
|
789
|
+
children: Ce(ce)
|
|
773
790
|
}
|
|
774
791
|
),
|
|
775
|
-
!
|
|
776
|
-
|
|
777
|
-
Te && /* @__PURE__ */ l.jsx("ul", { ref:
|
|
778
|
-
/* @__PURE__ */ l.jsx(
|
|
792
|
+
!q && re && /* @__PURE__ */ l.jsxs("div", { className: h.inputDropDown, style: ve ?? {}, onClick: () => N(!0), ref: I, children: [
|
|
793
|
+
B.find((a) => a.id === we).label,
|
|
794
|
+
Te && /* @__PURE__ */ l.jsx("ul", { ref: W, style: he ?? {}, children: B && B.length && B.map((a, k) => /* @__PURE__ */ l.jsx("li", { style: ye ?? {}, onClick: () => ke(a), children: (a == null ? void 0 : a.label) ?? "-" }, a.id)) }),
|
|
795
|
+
/* @__PURE__ */ l.jsx(Dr, {})
|
|
779
796
|
] }),
|
|
780
|
-
|
|
797
|
+
q && /* @__PURE__ */ l.jsx("div", { className: `${h.inputDropDown} ${h.http}`, style: me ?? {}, onClick: () => N(!0), ref: I, children: "http://" }),
|
|
781
798
|
/* @__PURE__ */ l.jsx(
|
|
782
799
|
"input",
|
|
783
800
|
{
|
|
784
|
-
style:
|
|
801
|
+
style: _e ?? {},
|
|
785
802
|
type: w ?? "text",
|
|
786
803
|
value: C,
|
|
787
|
-
onChange: (a) =>
|
|
788
|
-
onFocus:
|
|
804
|
+
onChange: (a) => H(a),
|
|
805
|
+
onFocus: L,
|
|
789
806
|
onBlur: Ee,
|
|
790
807
|
disabled: O,
|
|
791
808
|
required: x,
|
|
792
809
|
onKeyDown: Re,
|
|
793
|
-
readOnly:
|
|
810
|
+
readOnly: g,
|
|
794
811
|
spellCheck: !1,
|
|
795
812
|
placeholder: R ?? "",
|
|
796
813
|
autoComplete: "off",
|
|
@@ -800,10 +817,10 @@ const z = {}, Er = ({
|
|
|
800
817
|
le && /* @__PURE__ */ l.jsx(
|
|
801
818
|
"div",
|
|
802
819
|
{
|
|
803
|
-
className:
|
|
804
|
-
style:
|
|
820
|
+
className: h.rightIcon,
|
|
821
|
+
style: be ?? {},
|
|
805
822
|
onClick: () => {
|
|
806
|
-
|
|
823
|
+
U && typeof U == "function" && U();
|
|
807
824
|
},
|
|
808
825
|
onMouseEnter: () => {
|
|
809
826
|
Z && typeof Z == "function" && Z();
|
|
@@ -817,15 +834,15 @@ const z = {}, Er = ({
|
|
|
817
834
|
]
|
|
818
835
|
}
|
|
819
836
|
),
|
|
820
|
-
|
|
821
|
-
/* @__PURE__ */ l.jsx(
|
|
837
|
+
fe && /* @__PURE__ */ l.jsxs("div", { style: ge ?? {}, onClick: K, className: h.withCopy, children: [
|
|
838
|
+
/* @__PURE__ */ l.jsx($r, {}),
|
|
822
839
|
"Copy"
|
|
823
840
|
] })
|
|
824
841
|
] }),
|
|
825
|
-
s && (s == null ? void 0 : s.visigle) && /* @__PURE__ */ l.jsx("div", { style: je ?? {}, className: `${
|
|
842
|
+
s && (s == null ? void 0 : s.visigle) && /* @__PURE__ */ l.jsx("div", { style: je ?? {}, className: `${h.inputHelperText} ${s != null && s.error ? h.error : ""}`, children: /* @__PURE__ */ l.jsx("p", { style: (s == null ? void 0 : s.style) ?? {}, children: s.text }) })
|
|
826
843
|
] });
|
|
827
844
|
};
|
|
828
845
|
export {
|
|
829
|
-
|
|
830
|
-
|
|
846
|
+
Wr as FormInput,
|
|
847
|
+
Ir as MainButton
|
|
831
848
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "master-components-react",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.3",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/master-components-react.cjs.js",
|
|
7
7
|
"module": "dist/master-components-react.es.js",
|
|
@@ -12,7 +12,8 @@
|
|
|
12
12
|
"exports": {
|
|
13
13
|
".": {
|
|
14
14
|
"import": "./dist/master-components-react.es.js",
|
|
15
|
-
"require": "./dist/master-components-react.cjs.js"
|
|
15
|
+
"require": "./dist/master-components-react.cjs.js",
|
|
16
|
+
"css": "./dist/style.css"
|
|
16
17
|
}
|
|
17
18
|
},
|
|
18
19
|
"scripts": {
|
|
@@ -24,9 +25,7 @@
|
|
|
24
25
|
"dependencies": {
|
|
25
26
|
"dayjs": "^1.11.13",
|
|
26
27
|
"master-components-react": "file:",
|
|
27
|
-
"react-router-dom": "^6.28.0"
|
|
28
|
-
"rollup-plugin-visualizer": "^5.12.0",
|
|
29
|
-
"vite-plugin-css-injected-by-js": "^3.5.2"
|
|
28
|
+
"react-router-dom": "^6.28.0"
|
|
30
29
|
},
|
|
31
30
|
"devDependencies": {
|
|
32
31
|
"@eslint/js": "^9.13.0",
|
|
@@ -39,7 +38,8 @@
|
|
|
39
38
|
"eslint-plugin-react-refresh": "^0.4.14",
|
|
40
39
|
"globals": "^15.11.0",
|
|
41
40
|
"sass": "^1.81.0",
|
|
42
|
-
"vite": "^5.4.11"
|
|
41
|
+
"vite": "^5.4.11",
|
|
42
|
+
"vite-plugin-css-injected-by-js": "^3.5.2"
|
|
43
43
|
},
|
|
44
44
|
"peerDependencies": {
|
|
45
45
|
"react": "^18.3.1",
|