@ekidpro/ui.button
Advanced tools
Comparing version 0.0.26 to 0.0.27
@@ -1,2 +0,16 @@ | ||
import e from"react";var r={exports:{}},t={},n=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,a=Object.prototype.propertyIsEnumerable;function i(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var c=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var r={},t=0;t<10;t++)r["_"+String.fromCharCode(t)]=t;if("0123456789"!==Object.getOwnPropertyNames(r).map((function(e){return r[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,r){for(var t,c,s=i(e),u=1;u<arguments.length;u++){for(var f in t=Object(arguments[u]))o.call(t,f)&&(s[f]=t[f]);if(n){c=n(t);for(var l=0;l<c.length;l++)a.call(t,c[l])&&(s[c[l]]=t[c[l]])}}return s},s=e,u=60103; | ||
import e,{memo as r,forwardRef as t,createContext as n,useState as o,useContext as a,useCallback as i}from"react";import s from"react-fast-compare"; | ||
/*! ***************************************************************************** | ||
Copyright (c) Microsoft Corporation. | ||
Permission to use, copy, modify, and/or distribute this software for any | ||
purpose with or without fee is hereby granted. | ||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH | ||
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY | ||
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, | ||
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM | ||
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR | ||
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | ||
PERFORMANCE OF THIS SOFTWARE. | ||
***************************************************************************** */function c(e,r){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)r.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(t[n[o]]=e[n[o]])}return t}var l={exports:{}},u={},f=Object.getOwnPropertySymbols,p=Object.prototype.hasOwnProperty,d=Object.prototype.propertyIsEnumerable;function y(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var v=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var r={},t=0;t<10;t++)r["_"+String.fromCharCode(t)]=t;if("0123456789"!==Object.getOwnPropertyNames(r).map((function(e){return r[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,r){for(var t,n,o=y(e),a=1;a<arguments.length;a++){for(var i in t=Object(arguments[a]))p.call(t,i)&&(o[i]=t[i]);if(f){n=f(t);for(var s=0;s<n.length;s++)d.call(t,n[s])&&(o[n[s]]=t[n[s]])}}return o},g=e,b=60103; | ||
/** @license React v17.0.2 | ||
@@ -9,3 +23,3 @@ * react-jsx-runtime.production.min.js | ||
* LICENSE file in the root directory of this source tree. | ||
*/if(t.Fragment=60107,"function"==typeof Symbol&&Symbol.for){var f=Symbol.for;u=f("react.element"),t.Fragment=f("react.fragment")}var l=s.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p=Object.prototype.hasOwnProperty,y={key:!0,ref:!0,__self:!0,__source:!0};function d(e,r,t){var n,o={},a=null,i=null;for(n in void 0!==t&&(a=""+t),void 0!==r.key&&(a=""+r.key),void 0!==r.ref&&(i=r.ref),r)p.call(r,n)&&!y.hasOwnProperty(n)&&(o[n]=r[n]);if(e&&e.defaultProps)for(n in r=e.defaultProps)void 0===o[n]&&(o[n]=r[n]);return{$$typeof:u,type:e,key:a,ref:i,props:o,_owner:l.current}}t.jsx=d,t.jsxs=d;var v,m={}; | ||
*/if(u.Fragment=60107,"function"==typeof Symbol&&Symbol.for){var m=Symbol.for;b=m("react.element"),u.Fragment=m("react.fragment")}var h=g.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,j=Object.prototype.hasOwnProperty,O={key:!0,ref:!0,__self:!0,__source:!0};function w(e,r,t){var n,o={},a=null,i=null;for(n in void 0!==t&&(a=""+t),void 0!==r.key&&(a=""+r.key),void 0!==r.ref&&(i=r.ref),r)j.call(r,n)&&!O.hasOwnProperty(n)&&(o[n]=r[n]);if(e&&e.defaultProps)for(n in r=e.defaultProps)void 0===o[n]&&(o[n]=r[n]);return{$$typeof:b,type:e,key:a,ref:i,props:o,_owner:h.current}}u.jsx=w,u.jsxs=w;var x,_={}; | ||
/** @license React v17.0.2 | ||
@@ -18,3 +32,3 @@ * react-jsx-runtime.development.js | ||
* LICENSE file in the root directory of this source tree. | ||
*/function g(){return r.exports.jsx("div",{children:"Default Component"},void 0)}v=m,"production"!==process.env.NODE_ENV&&function(){var r=e,t=c,n=60103,o=60106;v.Fragment=60107;var a=60108,i=60114,s=60109,u=60110,f=60112,l=60113,p=60120,y=60115,d=60116,m=60121,g=60122,b=60117,h=60129,_=60131;if("function"==typeof Symbol&&Symbol.for){var O=Symbol.for;n=O("react.element"),o=O("react.portal"),v.Fragment=O("react.fragment"),a=O("react.strict_mode"),i=O("react.profiler"),s=O("react.provider"),u=O("react.context"),f=O("react.forward_ref"),l=O("react.suspense"),p=O("react.suspense_list"),y=O("react.memo"),d=O("react.lazy"),m=O("react.block"),g=O("react.server.block"),b=O("react.fundamental"),O("react.scope"),O("react.opaque.id"),h=O("react.debug_trace_mode"),O("react.offscreen"),_=O("react.legacy_hidden")}var j="function"==typeof Symbol&&Symbol.iterator,w=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function k(e){for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];R("error",e,t)}function R(e,r,t){var n=w.ReactDebugCurrentFrame.getStackAddendum();""!==n&&(r+="%s",t=t.concat([n]));var o=t.map((function(e){return""+e}));o.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,o)}function E(e){return e.displayName||"Context"}function S(e){if(null==e)return null;if("number"==typeof e.tag&&k("Received an unexpected object in getComponentName(). This is likely a bug in React. Please file an issue."),"function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case v.Fragment:return"Fragment";case o:return"Portal";case i:return"Profiler";case a:return"StrictMode";case l:return"Suspense";case p:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case u:return E(e)+".Consumer";case s:return E(e._context)+".Provider";case f:return c=e,g=e.render,b="ForwardRef",h=g.displayName||g.name||"",c.displayName||(""!==h?b+"("+h+")":b);case y:return S(e.type);case m:return S(e._render);case d:var r=e,t=r._payload,n=r._init;try{return S(n(t))}catch(e){return null}}var c,g,b,h;return null}var P,$,x,C,T,F,N,D=0;function I(){}I.__reactDisabledLog=!0;var A,L=w.ReactCurrentDispatcher;function W(e,r,t){if(void 0===A)try{throw Error()}catch(e){var n=e.stack.trim().match(/\n( *(at )?)/);A=n&&n[1]||""}return"\n"+A+e}var U,z=!1,Y="function"==typeof WeakMap?WeakMap:Map;function q(e,r){if(!e||z)return"";var n,o=U.get(e);if(void 0!==o)return o;z=!0;var a,i=Error.prepareStackTrace;Error.prepareStackTrace=void 0,a=L.current,L.current=null,function(){if(0===D){P=console.log,$=console.info,x=console.warn,C=console.error,T=console.group,F=console.groupCollapsed,N=console.groupEnd;var e={configurable:!0,enumerable:!0,value:I,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}D++}();try{if(r){var c=function(){throw Error()};if(Object.defineProperty(c.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(c,[])}catch(e){n=e}Reflect.construct(e,[],c)}else{try{c.call()}catch(e){n=e}e.call(c.prototype)}}else{try{throw Error()}catch(e){n=e}e()}}catch(r){if(r&&n&&"string"==typeof r.stack){for(var s=r.stack.split("\n"),u=n.stack.split("\n"),f=s.length-1,l=u.length-1;f>=1&&l>=0&&s[f]!==u[l];)l--;for(;f>=1&&l>=0;f--,l--)if(s[f]!==u[l]){if(1!==f||1!==l)do{if(f--,--l<0||s[f]!==u[l]){var p="\n"+s[f].replace(" at new "," at ");return"function"==typeof e&&U.set(e,p),p}}while(f>=1&&l>=0);break}}}finally{z=!1,L.current=a,function(){if(0==--D){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:t({},e,{value:P}),info:t({},e,{value:$}),warn:t({},e,{value:x}),error:t({},e,{value:C}),group:t({},e,{value:T}),groupCollapsed:t({},e,{value:F}),groupEnd:t({},e,{value:N})})}D<0&&k("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}(),Error.prepareStackTrace=i}var y=e?e.displayName||e.name:"",d=y?W(y):"";return"function"==typeof e&&U.set(e,d),d}function B(e,r,t){return q(e,!1)}function M(e,r,t){if(null==e)return"";if("function"==typeof e)return q(e,!(!(n=e.prototype)||!n.isReactComponent));var n;if("string"==typeof e)return W(e);switch(e){case l:return W("Suspense");case p:return W("SuspenseList")}if("object"==typeof e)switch(e.$$typeof){case f:return B(e.render);case y:return M(e.type,r,t);case m:return B(e._render);case d:var o=e,a=o._payload,i=o._init;try{return M(i(a),r,t)}catch(e){}}return""}U=new Y;var V={},H=w.ReactDebugCurrentFrame;function J(e){if(e){var r=e._owner,t=M(e.type,e._source,r?r.type:null);H.setExtraStackFrame(t)}else H.setExtraStackFrame(null)}var X,G,K,Q=w.ReactCurrentOwner,Z=Object.prototype.hasOwnProperty,ee={key:!0,ref:!0,__self:!0,__source:!0};function re(e,r,t,o,a){var i,c={},s=null,u=null;for(i in void 0!==t&&(s=""+t),function(e){if(Z.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return void 0!==e.key}(r)&&(s=""+r.key),function(e){if(Z.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return void 0!==e.ref}(r)&&(u=r.ref,function(e,r){if("string"==typeof e.ref&&Q.current&&r&&Q.current.stateNode!==r){var t=S(Q.current.type);K[t]||(k('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',S(Q.current.type),e.ref),K[t]=!0)}}(r,a)),r)Z.call(r,i)&&!ee.hasOwnProperty(i)&&(c[i]=r[i]);if(e&&e.defaultProps){var f=e.defaultProps;for(i in f)void 0===c[i]&&(c[i]=f[i])}if(s||u){var l="function"==typeof e?e.displayName||e.name||"Unknown":e;s&&function(e,r){var t=function(){X||(X=!0,k("%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})}(c,l),u&&function(e,r){var t=function(){G||(G=!0,k("%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})}(c,l)}return function(e,r,t,o,a,i,c){var s={$$typeof:n,type:e,key:r,ref:t,props:c,_owner:i,_store:{}};return Object.defineProperty(s._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(s,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(s,"_source",{configurable:!1,enumerable:!1,writable:!1,value:a}),Object.freeze&&(Object.freeze(s.props),Object.freeze(s)),s}(e,s,u,a,o,Q.current,c)}K={};var te,ne=w.ReactCurrentOwner,oe=w.ReactDebugCurrentFrame;function ae(e){if(e){var r=e._owner,t=M(e.type,e._source,r?r.type:null);oe.setExtraStackFrame(t)}else oe.setExtraStackFrame(null)}function ie(e){return"object"==typeof e&&null!==e&&e.$$typeof===n}function ce(){if(ne.current){var e=S(ne.current.type);if(e)return"\n\nCheck the render method of `"+e+"`."}return""}te=!1;var se={};function ue(e,r){if(e._store&&!e._store.validated&&null==e.key){e._store.validated=!0;var t=function(e){var r=ce();if(!r){var t="string"==typeof e?e:e.displayName||e.name;t&&(r="\n\nCheck the top-level render call using <"+t+">.")}return r}(r);if(!se[t]){se[t]=!0;var n="";e&&e._owner&&e._owner!==ne.current&&(n=" It was passed a child from "+S(e._owner.type)+"."),ae(e),k('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),ae(null)}}}function fe(e,r){if("object"==typeof e)if(Array.isArray(e))for(var t=0;t<e.length;t++){var n=e[t];ie(n)&&ue(n,r)}else if(ie(e))e._store&&(e._store.validated=!0);else if(e){var o=function(e){if(null===e||"object"!=typeof e)return null;var r=j&&e[j]||e["@@iterator"];return"function"==typeof r?r:null}(e);if("function"==typeof o&&o!==e.entries)for(var a,i=o.call(e);!(a=i.next()).done;)ie(a.value)&&ue(a.value,r)}}function le(e){var r,t=e.type;if(null!=t&&"string"!=typeof t){if("function"==typeof t)r=t.propTypes;else{if("object"!=typeof t||t.$$typeof!==f&&t.$$typeof!==y)return;r=t.propTypes}if(r){var n=S(t);!function(e,r,t,n,o){var a=Function.call.bind(Object.prototype.hasOwnProperty);for(var i in e)if(a(e,i)){var c=void 0;try{if("function"!=typeof e[i]){var s=Error((n||"React class")+": "+t+" type `"+i+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[i]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw s.name="Invariant Violation",s}c=e[i](r,i,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(e){c=e}!c||c instanceof Error||(J(o),k("%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,i,typeof c),J(null)),c instanceof Error&&!(c.message in V)&&(V[c.message]=!0,J(o),k("Failed %s type: %s",t,c.message),J(null))}}(r,e.props,"prop",n,e)}else void 0===t.PropTypes||te||(te=!0,k("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",S(t)||"Unknown"));"function"!=typeof t.getDefaultProps||t.getDefaultProps.isReactClassApproved||k("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pe(e,r,t,o,c,O){var j=function(e){return"string"==typeof e||"function"==typeof e||e===v.Fragment||e===i||e===h||e===a||e===l||e===p||e===_||"object"==typeof e&&null!==e&&(e.$$typeof===d||e.$$typeof===y||e.$$typeof===s||e.$$typeof===u||e.$$typeof===f||e.$$typeof===b||e.$$typeof===m||e[0]===g)}(e);if(!j){var w="";(void 0===e||"object"==typeof e&&null!==e&&0===Object.keys(e).length)&&(w+=" 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 R,E=function(e){return void 0!==e?"\n\nCheck your code at "+e.fileName.replace(/^.*[\\\/]/,"")+":"+e.lineNumber+".":""}(c);w+=E||ce(),null===e?R="null":Array.isArray(e)?R="array":void 0!==e&&e.$$typeof===n?(R="<"+(S(e.type)||"Unknown")+" />",w=" Did you accidentally export a JSX literal instead of a component?"):R=typeof e,k("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",R,w)}var P=re(e,r,t,c,O);if(null==P)return P;if(j){var $=r.children;if(void 0!==$)if(o)if(Array.isArray($)){for(var x=0;x<$.length;x++)fe($[x],e);Object.freeze&&Object.freeze($)}else k("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 fe($,e)}return e===v.Fragment?function(e){for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if("children"!==n&&"key"!==n){ae(e),k("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),ae(null);break}}null!==e.ref&&(ae(e),k("Invalid attribute `ref` supplied to `React.Fragment`."),ae(null))}(P):le(P),P}var ye=function(e,r,t){return pe(e,r,t,!1)},de=function(e,r,t){return pe(e,r,t,!0)};v.jsx=ye,v.jsxs=de}(),"production"===process.env.NODE_ENV?r.exports=t:r.exports=m;export{g as Button}; | ||
*/function k(e){var r,t,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(r=0;r<e.length;r++)e[r]&&(t=k(e[r]))&&(n&&(n+=" "),n+=t);else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function E(){for(var e,r,t=0,n="";t<arguments.length;)(e=arguments[t++])&&(r=k(e))&&(n&&(n+=" "),n+=r);return n}x=_,"production"!==process.env.NODE_ENV&&function(){var r=e,t=v,n=60103,o=60106;x.Fragment=60107;var a=60108,i=60114,s=60109,c=60110,l=60112,u=60113,f=60120,p=60115,d=60116,y=60121,g=60122,b=60117,m=60129,h=60131;if("function"==typeof Symbol&&Symbol.for){var j=Symbol.for;n=j("react.element"),o=j("react.portal"),x.Fragment=j("react.fragment"),a=j("react.strict_mode"),i=j("react.profiler"),s=j("react.provider"),c=j("react.context"),l=j("react.forward_ref"),u=j("react.suspense"),f=j("react.suspense_list"),p=j("react.memo"),d=j("react.lazy"),y=j("react.block"),g=j("react.server.block"),b=j("react.fundamental"),j("react.scope"),j("react.opaque.id"),m=j("react.debug_trace_mode"),j("react.offscreen"),h=j("react.legacy_hidden")}var O="function"==typeof Symbol&&Symbol.iterator,w=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function _(e){for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];k("error",e,t)}function k(e,r,t){var n=w.ReactDebugCurrentFrame.getStackAddendum();""!==n&&(r+="%s",t=t.concat([n]));var o=t.map((function(e){return""+e}));o.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,o)}function E(e){return e.displayName||"Context"}function R(e){if(null==e)return null;if("number"==typeof e.tag&&_("Received an unexpected object in getComponentName(). This is likely a bug in React. Please file an issue."),"function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case x.Fragment:return"Fragment";case o:return"Portal";case i:return"Profiler";case a:return"StrictMode";case u:return"Suspense";case f:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case c:return E(e)+".Consumer";case s:return E(e._context)+".Provider";case l:return v=e,g=e.render,b="ForwardRef",m=g.displayName||g.name||"",v.displayName||(""!==m?b+"("+m+")":b);case p:return R(e.type);case y:return R(e._render);case d:var r=e,t=r._payload,n=r._init;try{return R(n(t))}catch(e){return null}}var v,g,b,m;return null}var S,P,C,N,$,T,F,D=0;function I(){}I.__reactDisabledLog=!0;var A,L=w.ReactCurrentDispatcher;function W(e,r,t){if(void 0===A)try{throw Error()}catch(e){var n=e.stack.trim().match(/\n( *(at )?)/);A=n&&n[1]||""}return"\n"+A+e}var U,z=!1,Y="function"==typeof WeakMap?WeakMap:Map;function q(e,r){if(!e||z)return"";var n,o=U.get(e);if(void 0!==o)return o;z=!0;var a,i=Error.prepareStackTrace;Error.prepareStackTrace=void 0,a=L.current,L.current=null,function(){if(0===D){S=console.log,P=console.info,C=console.warn,N=console.error,$=console.group,T=console.groupCollapsed,F=console.groupEnd;var e={configurable:!0,enumerable:!0,value:I,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}D++}();try{if(r){var s=function(){throw Error()};if(Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(s,[])}catch(e){n=e}Reflect.construct(e,[],s)}else{try{s.call()}catch(e){n=e}e.call(s.prototype)}}else{try{throw Error()}catch(e){n=e}e()}}catch(r){if(r&&n&&"string"==typeof r.stack){for(var c=r.stack.split("\n"),l=n.stack.split("\n"),u=c.length-1,f=l.length-1;u>=1&&f>=0&&c[u]!==l[f];)f--;for(;u>=1&&f>=0;u--,f--)if(c[u]!==l[f]){if(1!==u||1!==f)do{if(u--,--f<0||c[u]!==l[f]){var p="\n"+c[u].replace(" at new "," at ");return"function"==typeof e&&U.set(e,p),p}}while(u>=1&&f>=0);break}}}finally{z=!1,L.current=a,function(){if(0==--D){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:t({},e,{value:S}),info:t({},e,{value:P}),warn:t({},e,{value:C}),error:t({},e,{value:N}),group:t({},e,{value:$}),groupCollapsed:t({},e,{value:T}),groupEnd:t({},e,{value:F})})}D<0&&_("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}(),Error.prepareStackTrace=i}var d=e?e.displayName||e.name:"",y=d?W(d):"";return"function"==typeof e&&U.set(e,y),y}function B(e,r,t){return q(e,!1)}function M(e,r,t){if(null==e)return"";if("function"==typeof e)return q(e,!(!(n=e.prototype)||!n.isReactComponent));var n;if("string"==typeof e)return W(e);switch(e){case u:return W("Suspense");case f:return W("SuspenseList")}if("object"==typeof e)switch(e.$$typeof){case l:return B(e.render);case p:return M(e.type,r,t);case y:return B(e._render);case d:var o=e,a=o._payload,i=o._init;try{return M(i(a),r,t)}catch(e){}}return""}U=new Y;var V={},H=w.ReactDebugCurrentFrame;function J(e){if(e){var r=e._owner,t=M(e.type,e._source,r?r.type:null);H.setExtraStackFrame(t)}else H.setExtraStackFrame(null)}var X,G,K,Q=w.ReactCurrentOwner,Z=Object.prototype.hasOwnProperty,ee={key:!0,ref:!0,__self:!0,__source:!0};function re(e,r,t,o,a){var i,s={},c=null,l=null;for(i in void 0!==t&&(c=""+t),function(e){if(Z.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return void 0!==e.key}(r)&&(c=""+r.key),function(e){if(Z.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return void 0!==e.ref}(r)&&(l=r.ref,function(e,r){if("string"==typeof e.ref&&Q.current&&r&&Q.current.stateNode!==r){var t=R(Q.current.type);K[t]||(_('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',R(Q.current.type),e.ref),K[t]=!0)}}(r,a)),r)Z.call(r,i)&&!ee.hasOwnProperty(i)&&(s[i]=r[i]);if(e&&e.defaultProps){var u=e.defaultProps;for(i in u)void 0===s[i]&&(s[i]=u[i])}if(c||l){var f="function"==typeof e?e.displayName||e.name||"Unknown":e;c&&function(e,r){var t=function(){X||(X=!0,_("%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})}(s,f),l&&function(e,r){var t=function(){G||(G=!0,_("%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})}(s,f)}return function(e,r,t,o,a,i,s){var c={$$typeof:n,type:e,key:r,ref:t,props:s,_owner:i,_store:{}};return Object.defineProperty(c._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(c,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(c,"_source",{configurable:!1,enumerable:!1,writable:!1,value:a}),Object.freeze&&(Object.freeze(c.props),Object.freeze(c)),c}(e,c,l,a,o,Q.current,s)}K={};var te,ne=w.ReactCurrentOwner,oe=w.ReactDebugCurrentFrame;function ae(e){if(e){var r=e._owner,t=M(e.type,e._source,r?r.type:null);oe.setExtraStackFrame(t)}else oe.setExtraStackFrame(null)}function ie(e){return"object"==typeof e&&null!==e&&e.$$typeof===n}function se(){if(ne.current){var e=R(ne.current.type);if(e)return"\n\nCheck the render method of `"+e+"`."}return""}te=!1;var ce={};function le(e,r){if(e._store&&!e._store.validated&&null==e.key){e._store.validated=!0;var t=function(e){var r=se();if(!r){var t="string"==typeof e?e:e.displayName||e.name;t&&(r="\n\nCheck the top-level render call using <"+t+">.")}return r}(r);if(!ce[t]){ce[t]=!0;var n="";e&&e._owner&&e._owner!==ne.current&&(n=" It was passed a child from "+R(e._owner.type)+"."),ae(e),_('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),ae(null)}}}function ue(e,r){if("object"==typeof e)if(Array.isArray(e))for(var t=0;t<e.length;t++){var n=e[t];ie(n)&&le(n,r)}else if(ie(e))e._store&&(e._store.validated=!0);else if(e){var o=function(e){if(null===e||"object"!=typeof e)return null;var r=O&&e[O]||e["@@iterator"];return"function"==typeof r?r:null}(e);if("function"==typeof o&&o!==e.entries)for(var a,i=o.call(e);!(a=i.next()).done;)ie(a.value)&&le(a.value,r)}}function fe(e){var r,t=e.type;if(null!=t&&"string"!=typeof t){if("function"==typeof t)r=t.propTypes;else{if("object"!=typeof t||t.$$typeof!==l&&t.$$typeof!==p)return;r=t.propTypes}if(r){var n=R(t);!function(e,r,t,n,o){var a=Function.call.bind(Object.prototype.hasOwnProperty);for(var i in e)if(a(e,i)){var s=void 0;try{if("function"!=typeof e[i]){var c=Error((n||"React class")+": "+t+" type `"+i+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[i]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw c.name="Invariant Violation",c}s=e[i](r,i,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(e){s=e}!s||s instanceof Error||(J(o),_("%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,i,typeof s),J(null)),s instanceof Error&&!(s.message in V)&&(V[s.message]=!0,J(o),_("Failed %s type: %s",t,s.message),J(null))}}(r,e.props,"prop",n,e)}else void 0===t.PropTypes||te||(te=!0,_("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",R(t)||"Unknown"));"function"!=typeof t.getDefaultProps||t.getDefaultProps.isReactClassApproved||_("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pe(e,r,t,o,v,j){var O=function(e){return"string"==typeof e||"function"==typeof e||e===x.Fragment||e===i||e===m||e===a||e===u||e===f||e===h||"object"==typeof e&&null!==e&&(e.$$typeof===d||e.$$typeof===p||e.$$typeof===s||e.$$typeof===c||e.$$typeof===l||e.$$typeof===b||e.$$typeof===y||e[0]===g)}(e);if(!O){var w="";(void 0===e||"object"==typeof e&&null!==e&&0===Object.keys(e).length)&&(w+=" 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 k,E=function(e){return void 0!==e?"\n\nCheck your code at "+e.fileName.replace(/^.*[\\\/]/,"")+":"+e.lineNumber+".":""}(v);w+=E||se(),null===e?k="null":Array.isArray(e)?k="array":void 0!==e&&e.$$typeof===n?(k="<"+(R(e.type)||"Unknown")+" />",w=" Did you accidentally export a JSX literal instead of a component?"):k=typeof e,_("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",k,w)}var S=re(e,r,t,v,j);if(null==S)return S;if(O){var P=r.children;if(void 0!==P)if(o)if(Array.isArray(P)){for(var C=0;C<P.length;C++)ue(P[C],e);Object.freeze&&Object.freeze(P)}else _("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(P,e)}return e===x.Fragment?function(e){for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if("children"!==n&&"key"!==n){ae(e),_("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),ae(null);break}}null!==e.ref&&(ae(e),_("Invalid attribute `ref` supplied to `React.Fragment`."),ae(null))}(S):fe(S),S}var de=function(e,r,t){return pe(e,r,t,!1)},ye=function(e,r,t){return pe(e,r,t,!0)};x.jsx=de,x.jsxs=ye}(),"production"===process.env.NODE_ENV?l.exports=u:l.exports=_;const R={primary:{bgColor:"bg-indigo-600",hover:"hover:bg-indigo-700",focus:"focus:ring-indigo-500 focus:ring-offset-indigo-200 focus:outline-none focus:ring-2 focus:ring-offset-2",text:"text-white text-center text-base font-semibold",border:void 0},secondary:{bgColor:"bg-white",hover:"hover:bg-gray-100",focus:void 0,text:"text-gray-900 text-center text-base font-medium",border:"border"},warn:{bgColor:"bg-yellow-400",hover:"hover:bg-yellow-500",focus:void 0,text:"text-white text-center text-base font-medium",border:void 0},error:{bgColor:"bg-red-500",hover:"hover:bg-red-600",focus:void 0,text:"text-white text-center text-base font-medium",border:void 0}};function S(e){if(null!=e)return Object.values(e).filter((e=>"string"==typeof e&&""!==e)).join(" ")}const P=r(t(((e,r)=>{const{variant:t="primary",colorScheme:n,rounded:o="normal"}=e,a=c(e,["variant","colorScheme","rounded"]),i=S(n)||function(e){const r=R[e.toString()];if(null==r)throw new Error("Invalid color scheme");return S(r)}(t)||"";return l.exports.jsx("button",Object.assign({},a,{ref:r,type:"button",className:E("py-2 px-4 transition ease-in duration-200 rounded",i,e.className,{rounded:"normal"===o,"rounded-md":"md"===o,"rounded-lg":"lg"===o,"rounded-sm":"sm"===o,"rounded-none":"none"===o,"rounded-full":"full"===o})},{children:e.children}),void 0)})),s),C=n(null),N=n(null),$=({children:e})=>{const[r,t]=o(null);return l.exports.jsx(N.Provider,Object.assign({value:t},{children:l.exports.jsx(C.Provider,Object.assign({value:r},{children:e}),void 0)}),void 0)},T=t(((e,r)=>{const{title:t,className:n}=e,o=c(e,["title","className"]),i=a(C)===e.id,s=a(N);let u="w-5 h-5 mr-2 inline-block rounded-full border border-grey flex-no-shrink transition ";return u+=i?"bg-blue-500":"bg-white",l.exports.jsxs("div",Object.assign({ref:r,className:`flex items-center ${n}`},o,{children:[l.exports.jsx("input",{id:"ekp-radio",type:"radio",className:"hidden"},void 0),l.exports.jsxs("label",Object.assign({htmlFor:"ekp-radio",className:"flex items-center cursor-pointer",onClick:()=>{var r;s&&s(i?null:null!==(r=e.id)&&void 0!==r?r:null)}},{children:[l.exports.jsx("span",{className:u,style:{boxShadow:"0px 0px 0px 2px white inset"}},void 0),t]}),void 0)]}),void 0)})),F=t(((e,r)=>{var{Label:t,defaultChecked:n,onChange:a,className:s,style:u}=e,f=c(e,["Label","defaultChecked","onChange","className","style"]);const[p,d]=o(null!=n&&n),y=i((()=>{d((e=>(a&&a(!e),!e)))}),[a,d]);let v="toggle-indicator bg-white w-6 h-6 rounded-full shadow-md transform duration-300";p&&(v+=" translate-x-6");let g="w-14 h-8 flex items-center rounded-full p-1 duration-300 cursor-pointe";g+=p?" bg-blue-500":" bg-gray-300";const b=l.exports.jsx("div",Object.assign({className:`toggle ${g} ${s}`,onClick:y,ref:r,style:u},f,{children:l.exports.jsx("div",{className:v},void 0)}),void 0);return null==t?b:l.exports.jsx(t,Object.assign({checked:p},{children:b}),void 0)}));export{P as Button,T as Radio,$ as RadioGroup,F as Toggle}; | ||
//# sourceMappingURL=index.es.js.map |
@@ -1,2 +0,17 @@ | ||
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}Object.defineProperty(exports,"__esModule",{value:!0});var r=e(require("react")),t={exports:{}},n={},o=Object.getOwnPropertySymbols,a=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function c(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var s=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var r={},t=0;t<10;t++)r["_"+String.fromCharCode(t)]=t;if("0123456789"!==Object.getOwnPropertyNames(r).map((function(e){return r[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,r){for(var t,n,s=c(e),u=1;u<arguments.length;u++){for(var f in t=Object(arguments[u]))a.call(t,f)&&(s[f]=t[f]);if(o){n=o(t);for(var l=0;l<n.length;l++)i.call(t,n[l])&&(s[n[l]]=t[n[l]])}}return s},u=r.default,f=60103; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),r=require("react-fast-compare");function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=t(e),o=t(r); | ||
/*! ***************************************************************************** | ||
Copyright (c) Microsoft Corporation. | ||
Permission to use, copy, modify, and/or distribute this software for any | ||
purpose with or without fee is hereby granted. | ||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH | ||
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY | ||
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, | ||
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM | ||
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR | ||
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | ||
PERFORMANCE OF THIS SOFTWARE. | ||
***************************************************************************** */ | ||
function a(e,r){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)r.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(t[n[o]]=e[n[o]])}return t}var i={exports:{}},s={},c=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable;function f(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var p=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var r={},t=0;t<10;t++)r["_"+String.fromCharCode(t)]=t;if("0123456789"!==Object.getOwnPropertyNames(r).map((function(e){return r[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,r){for(var t,n,o=f(e),a=1;a<arguments.length;a++){for(var i in t=Object(arguments[a]))l.call(t,i)&&(o[i]=t[i]);if(c){n=c(t);for(var s=0;s<n.length;s++)u.call(t,n[s])&&(o[n[s]]=t[n[s]])}}return o},d=n.default,y=60103; | ||
/** @license React v17.0.2 | ||
@@ -9,3 +24,3 @@ * react-jsx-runtime.production.min.js | ||
* LICENSE file in the root directory of this source tree. | ||
*/if(n.Fragment=60107,"function"==typeof Symbol&&Symbol.for){var l=Symbol.for;f=l("react.element"),n.Fragment=l("react.fragment")}var p=u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,y=Object.prototype.hasOwnProperty,d={key:!0,ref:!0,__self:!0,__source:!0};function v(e,r,t){var n,o={},a=null,i=null;for(n in void 0!==t&&(a=""+t),void 0!==r.key&&(a=""+r.key),void 0!==r.ref&&(i=r.ref),r)y.call(r,n)&&!d.hasOwnProperty(n)&&(o[n]=r[n]);if(e&&e.defaultProps)for(n in r=e.defaultProps)void 0===o[n]&&(o[n]=r[n]);return{$$typeof:f,type:e,key:a,ref:i,props:o,_owner:p.current}}n.jsx=v,n.jsxs=v;var g={}; | ||
*/if(s.Fragment=60107,"function"==typeof Symbol&&Symbol.for){var v=Symbol.for;y=v("react.element"),s.Fragment=v("react.fragment")}var g=d.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,b=Object.prototype.hasOwnProperty,m={key:!0,ref:!0,__self:!0,__source:!0};function h(e,r,t){var n,o={},a=null,i=null;for(n in void 0!==t&&(a=""+t),void 0!==r.key&&(a=""+r.key),void 0!==r.ref&&(i=r.ref),r)b.call(r,n)&&!m.hasOwnProperty(n)&&(o[n]=r[n]);if(e&&e.defaultProps)for(n in r=e.defaultProps)void 0===o[n]&&(o[n]=r[n]);return{$$typeof:y,type:e,key:a,ref:i,props:o,_owner:g.current}}s.jsx=h,s.jsxs=h;var j={}; | ||
/** @license React v17.0.2 | ||
@@ -18,3 +33,3 @@ * react-jsx-runtime.development.js | ||
* LICENSE file in the root directory of this source tree. | ||
*/!function(e){"production"!==process.env.NODE_ENV&&function(){var t=r.default,n=s,o=60103,a=60106;e.Fragment=60107;var i=60108,c=60114,u=60109,f=60110,l=60112,p=60113,y=60120,d=60115,v=60116,g=60121,m=60122,b=60117,h=60129,_=60131;if("function"==typeof Symbol&&Symbol.for){var O=Symbol.for;o=O("react.element"),a=O("react.portal"),e.Fragment=O("react.fragment"),i=O("react.strict_mode"),c=O("react.profiler"),u=O("react.provider"),f=O("react.context"),l=O("react.forward_ref"),p=O("react.suspense"),y=O("react.suspense_list"),d=O("react.memo"),v=O("react.lazy"),g=O("react.block"),m=O("react.server.block"),b=O("react.fundamental"),O("react.scope"),O("react.opaque.id"),h=O("react.debug_trace_mode"),O("react.offscreen"),_=O("react.legacy_hidden")}var j="function"==typeof Symbol&&Symbol.iterator;var w=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function k(e){for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];R("error",e,t)}function R(e,r,t){var n=w.ReactDebugCurrentFrame.getStackAddendum();""!==n&&(r+="%s",t=t.concat([n]));var o=t.map((function(e){return""+e}));o.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,o)}function E(e){return e.displayName||"Context"}function P(r){if(null==r)return null;if("number"==typeof r.tag&&k("Received an unexpected object in getComponentName(). This is likely a bug in React. Please file an issue."),"function"==typeof r)return r.displayName||r.name||null;if("string"==typeof r)return r;switch(r){case e.Fragment:return"Fragment";case a:return"Portal";case c:return"Profiler";case i:return"StrictMode";case p:return"Suspense";case y:return"SuspenseList"}if("object"==typeof r)switch(r.$$typeof){case f:return E(r)+".Consumer";case u:return E(r._context)+".Provider";case l:return s=r,m=r.render,b="ForwardRef",h=m.displayName||m.name||"",s.displayName||(""!==h?b+"("+h+")":b);case d:return P(r.type);case g:return P(r._render);case v:var t=r,n=t._payload,o=t._init;try{return P(o(n))}catch(e){return null}}var s,m,b,h;return null}var S,x,$,C,T,F,N,D=0;function I(){}I.__reactDisabledLog=!0;var A,L=w.ReactCurrentDispatcher;function W(e,r,t){if(void 0===A)try{throw Error()}catch(e){var n=e.stack.trim().match(/\n( *(at )?)/);A=n&&n[1]||""}return"\n"+A+e}var U,z=!1,q="function"==typeof WeakMap?WeakMap:Map;function Y(e,r){if(!e||z)return"";var t,o=U.get(e);if(void 0!==o)return o;z=!0;var a,i=Error.prepareStackTrace;Error.prepareStackTrace=void 0,a=L.current,L.current=null,function(){if(0===D){S=console.log,x=console.info,$=console.warn,C=console.error,T=console.group,F=console.groupCollapsed,N=console.groupEnd;var e={configurable:!0,enumerable:!0,value:I,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}D++}();try{if(r){var c=function(){throw Error()};if(Object.defineProperty(c.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(c,[])}catch(e){t=e}Reflect.construct(e,[],c)}else{try{c.call()}catch(e){t=e}e.call(c.prototype)}}else{try{throw Error()}catch(e){t=e}e()}}catch(r){if(r&&t&&"string"==typeof r.stack){for(var s=r.stack.split("\n"),u=t.stack.split("\n"),f=s.length-1,l=u.length-1;f>=1&&l>=0&&s[f]!==u[l];)l--;for(;f>=1&&l>=0;f--,l--)if(s[f]!==u[l]){if(1!==f||1!==l)do{if(f--,--l<0||s[f]!==u[l]){var p="\n"+s[f].replace(" at new "," at ");return"function"==typeof e&&U.set(e,p),p}}while(f>=1&&l>=0);break}}}finally{z=!1,L.current=a,function(){if(0==--D){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:n({},e,{value:S}),info:n({},e,{value:x}),warn:n({},e,{value:$}),error:n({},e,{value:C}),group:n({},e,{value:T}),groupCollapsed:n({},e,{value:F}),groupEnd:n({},e,{value:N})})}D<0&&k("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}(),Error.prepareStackTrace=i}var y=e?e.displayName||e.name:"",d=y?W(y):"";return"function"==typeof e&&U.set(e,d),d}function B(e,r,t){return Y(e,!1)}function M(e,r,t){if(null==e)return"";if("function"==typeof e)return Y(e,!(!(n=e.prototype)||!n.isReactComponent));var n;if("string"==typeof e)return W(e);switch(e){case p:return W("Suspense");case y:return W("SuspenseList")}if("object"==typeof e)switch(e.$$typeof){case l:return B(e.render);case d:return M(e.type,r,t);case g:return B(e._render);case v:var o=e,a=o._payload,i=o._init;try{return M(i(a),r,t)}catch(e){}}return""}U=new q;var V={},H=w.ReactDebugCurrentFrame;function J(e){if(e){var r=e._owner,t=M(e.type,e._source,r?r.type:null);H.setExtraStackFrame(t)}else H.setExtraStackFrame(null)}var X,G,K,Q=w.ReactCurrentOwner,Z=Object.prototype.hasOwnProperty,ee={key:!0,ref:!0,__self:!0,__source:!0};K={};function re(e,r,t,n,a){var i,c={},s=null,u=null;for(i in void 0!==t&&(s=""+t),function(e){if(Z.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return void 0!==e.key}(r)&&(s=""+r.key),function(e){if(Z.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return void 0!==e.ref}(r)&&(u=r.ref,function(e,r){if("string"==typeof e.ref&&Q.current&&r&&Q.current.stateNode!==r){var t=P(Q.current.type);K[t]||(k('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',P(Q.current.type),e.ref),K[t]=!0)}}(r,a)),r)Z.call(r,i)&&!ee.hasOwnProperty(i)&&(c[i]=r[i]);if(e&&e.defaultProps){var f=e.defaultProps;for(i in f)void 0===c[i]&&(c[i]=f[i])}if(s||u){var l="function"==typeof e?e.displayName||e.name||"Unknown":e;s&&function(e,r){var t=function(){X||(X=!0,k("%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})}(c,l),u&&function(e,r){var t=function(){G||(G=!0,k("%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})}(c,l)}return function(e,r,t,n,a,i,c){var s={$$typeof:o,type:e,key:r,ref:t,props:c,_owner:i,_store:{}};return Object.defineProperty(s._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(s,"_self",{configurable:!1,enumerable:!1,writable:!1,value:n}),Object.defineProperty(s,"_source",{configurable:!1,enumerable:!1,writable:!1,value:a}),Object.freeze&&(Object.freeze(s.props),Object.freeze(s)),s}(e,s,u,a,n,Q.current,c)}var te,ne=w.ReactCurrentOwner,oe=w.ReactDebugCurrentFrame;function ae(e){if(e){var r=e._owner,t=M(e.type,e._source,r?r.type:null);oe.setExtraStackFrame(t)}else oe.setExtraStackFrame(null)}function ie(e){return"object"==typeof e&&null!==e&&e.$$typeof===o}function ce(){if(ne.current){var e=P(ne.current.type);if(e)return"\n\nCheck the render method of `"+e+"`."}return""}te=!1;var se={};function ue(e,r){if(e._store&&!e._store.validated&&null==e.key){e._store.validated=!0;var t=function(e){var r=ce();if(!r){var t="string"==typeof e?e:e.displayName||e.name;t&&(r="\n\nCheck the top-level render call using <"+t+">.")}return r}(r);if(!se[t]){se[t]=!0;var n="";e&&e._owner&&e._owner!==ne.current&&(n=" It was passed a child from "+P(e._owner.type)+"."),ae(e),k('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),ae(null)}}}function fe(e,r){if("object"==typeof e)if(Array.isArray(e))for(var t=0;t<e.length;t++){var n=e[t];ie(n)&&ue(n,r)}else if(ie(e))e._store&&(e._store.validated=!0);else if(e){var o=function(e){if(null===e||"object"!=typeof e)return null;var r=j&&e[j]||e["@@iterator"];return"function"==typeof r?r:null}(e);if("function"==typeof o&&o!==e.entries)for(var a,i=o.call(e);!(a=i.next()).done;)ie(a.value)&&ue(a.value,r)}}function le(e){var r,t=e.type;if(null!=t&&"string"!=typeof t){if("function"==typeof t)r=t.propTypes;else{if("object"!=typeof t||t.$$typeof!==l&&t.$$typeof!==d)return;r=t.propTypes}if(r){var n=P(t);!function(e,r,t,n,o){var a=Function.call.bind(Object.prototype.hasOwnProperty);for(var i in e)if(a(e,i)){var c=void 0;try{if("function"!=typeof e[i]){var s=Error((n||"React class")+": "+t+" type `"+i+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[i]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw s.name="Invariant Violation",s}c=e[i](r,i,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(e){c=e}!c||c instanceof Error||(J(o),k("%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,i,typeof c),J(null)),c instanceof Error&&!(c.message in V)&&(V[c.message]=!0,J(o),k("Failed %s type: %s",t,c.message),J(null))}}(r,e.props,"prop",n,e)}else if(void 0!==t.PropTypes&&!te){te=!0,k("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",P(t)||"Unknown")}"function"!=typeof t.getDefaultProps||t.getDefaultProps.isReactClassApproved||k("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pe(r,t,n,a,s,O){var j=function(r){return"string"==typeof r||"function"==typeof r||r===e.Fragment||r===c||r===h||r===i||r===p||r===y||r===_||"object"==typeof r&&null!==r&&(r.$$typeof===v||r.$$typeof===d||r.$$typeof===u||r.$$typeof===f||r.$$typeof===l||r.$$typeof===b||r.$$typeof===g||r[0]===m)}(r);if(!j){var w="";(void 0===r||"object"==typeof r&&null!==r&&0===Object.keys(r).length)&&(w+=" 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 R,E=function(e){return void 0!==e?"\n\nCheck your code at "+e.fileName.replace(/^.*[\\\/]/,"")+":"+e.lineNumber+".":""}(s);w+=E||ce(),null===r?R="null":Array.isArray(r)?R="array":void 0!==r&&r.$$typeof===o?(R="<"+(P(r.type)||"Unknown")+" />",w=" Did you accidentally export a JSX literal instead of a component?"):R=typeof r,k("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",R,w)}var S=re(r,t,n,s,O);if(null==S)return S;if(j){var x=t.children;if(void 0!==x)if(a)if(Array.isArray(x)){for(var $=0;$<x.length;$++)fe(x[$],r);Object.freeze&&Object.freeze(x)}else k("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 fe(x,r)}return r===e.Fragment?function(e){for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if("children"!==n&&"key"!==n){ae(e),k("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),ae(null);break}}null!==e.ref&&(ae(e),k("Invalid attribute `ref` supplied to `React.Fragment`."),ae(null))}(S):le(S),S}var ye=function(e,r,t){return pe(e,r,t,!1)},de=function(e,r,t){return pe(e,r,t,!0)};e.jsx=ye,e.jsxs=de}()}(g),"production"===process.env.NODE_ENV?t.exports=n:t.exports=g,exports.Button=function(){return t.exports.jsx("div",{children:"Default Component"},void 0)}; | ||
*/function w(e){var r,t,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(r=0;r<e.length;r++)e[r]&&(t=w(e[r]))&&(n&&(n+=" "),n+=t);else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function x(){for(var e,r,t=0,n="";t<arguments.length;)(e=arguments[t++])&&(r=w(e))&&(n&&(n+=" "),n+=r);return n}!function(e){"production"!==process.env.NODE_ENV&&function(){var r=n.default,t=p,o=60103,a=60106;e.Fragment=60107;var i=60108,s=60114,c=60109,l=60110,u=60112,f=60113,d=60120,y=60115,v=60116,g=60121,b=60122,m=60117,h=60129,j=60131;if("function"==typeof Symbol&&Symbol.for){var w=Symbol.for;o=w("react.element"),a=w("react.portal"),e.Fragment=w("react.fragment"),i=w("react.strict_mode"),s=w("react.profiler"),c=w("react.provider"),l=w("react.context"),u=w("react.forward_ref"),f=w("react.suspense"),d=w("react.suspense_list"),y=w("react.memo"),v=w("react.lazy"),g=w("react.block"),b=w("react.server.block"),m=w("react.fundamental"),w("react.scope"),w("react.opaque.id"),h=w("react.debug_trace_mode"),w("react.offscreen"),j=w("react.legacy_hidden")}var x="function"==typeof Symbol&&Symbol.iterator;var O=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function _(e){for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];k("error",e,t)}function k(e,r,t){var n=O.ReactDebugCurrentFrame.getStackAddendum();""!==n&&(r+="%s",t=t.concat([n]));var o=t.map((function(e){return""+e}));o.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,o)}function R(e){return e.displayName||"Context"}function S(r){if(null==r)return null;if("number"==typeof r.tag&&_("Received an unexpected object in getComponentName(). This is likely a bug in React. Please file an issue."),"function"==typeof r)return r.displayName||r.name||null;if("string"==typeof r)return r;switch(r){case e.Fragment:return"Fragment";case a:return"Portal";case s:return"Profiler";case i:return"StrictMode";case f:return"Suspense";case d:return"SuspenseList"}if("object"==typeof r)switch(r.$$typeof){case l:return R(r)+".Consumer";case c:return R(r._context)+".Provider";case u:return p=r,b=r.render,m="ForwardRef",h=b.displayName||b.name||"",p.displayName||(""!==h?m+"("+h+")":m);case y:return S(r.type);case g:return S(r._render);case v:var t=r,n=t._payload,o=t._init;try{return S(o(n))}catch(e){return null}}var p,b,m,h;return null}var E,P,C,N,$,T,F,D=0;function I(){}I.__reactDisabledLog=!0;var A,L=O.ReactCurrentDispatcher;function W(e,r,t){if(void 0===A)try{throw Error()}catch(e){var n=e.stack.trim().match(/\n( *(at )?)/);A=n&&n[1]||""}return"\n"+A+e}var U,q=!1,z="function"==typeof WeakMap?WeakMap:Map;function Y(e,r){if(!e||q)return"";var n,o=U.get(e);if(void 0!==o)return o;q=!0;var a,i=Error.prepareStackTrace;Error.prepareStackTrace=void 0,a=L.current,L.current=null,function(){if(0===D){E=console.log,P=console.info,C=console.warn,N=console.error,$=console.group,T=console.groupCollapsed,F=console.groupEnd;var e={configurable:!0,enumerable:!0,value:I,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}D++}();try{if(r){var s=function(){throw Error()};if(Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(s,[])}catch(e){n=e}Reflect.construct(e,[],s)}else{try{s.call()}catch(e){n=e}e.call(s.prototype)}}else{try{throw Error()}catch(e){n=e}e()}}catch(r){if(r&&n&&"string"==typeof r.stack){for(var c=r.stack.split("\n"),l=n.stack.split("\n"),u=c.length-1,f=l.length-1;u>=1&&f>=0&&c[u]!==l[f];)f--;for(;u>=1&&f>=0;u--,f--)if(c[u]!==l[f]){if(1!==u||1!==f)do{if(u--,--f<0||c[u]!==l[f]){var p="\n"+c[u].replace(" at new "," at ");return"function"==typeof e&&U.set(e,p),p}}while(u>=1&&f>=0);break}}}finally{q=!1,L.current=a,function(){if(0==--D){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:t({},e,{value:E}),info:t({},e,{value:P}),warn:t({},e,{value:C}),error:t({},e,{value:N}),group:t({},e,{value:$}),groupCollapsed:t({},e,{value:T}),groupEnd:t({},e,{value:F})})}D<0&&_("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}(),Error.prepareStackTrace=i}var d=e?e.displayName||e.name:"",y=d?W(d):"";return"function"==typeof e&&U.set(e,y),y}function B(e,r,t){return Y(e,!1)}function M(e,r,t){if(null==e)return"";if("function"==typeof e)return Y(e,!(!(n=e.prototype)||!n.isReactComponent));var n;if("string"==typeof e)return W(e);switch(e){case f:return W("Suspense");case d:return W("SuspenseList")}if("object"==typeof e)switch(e.$$typeof){case u:return B(e.render);case y:return M(e.type,r,t);case g:return B(e._render);case v:var o=e,a=o._payload,i=o._init;try{return M(i(a),r,t)}catch(e){}}return""}U=new z;var V={},G=O.ReactDebugCurrentFrame;function H(e){if(e){var r=e._owner,t=M(e.type,e._source,r?r.type:null);G.setExtraStackFrame(t)}else G.setExtraStackFrame(null)}var J,X,K,Q=O.ReactCurrentOwner,Z=Object.prototype.hasOwnProperty,ee={key:!0,ref:!0,__self:!0,__source:!0};K={};function re(e,r,t,n,a){var i,s={},c=null,l=null;for(i in void 0!==t&&(c=""+t),function(e){if(Z.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return void 0!==e.key}(r)&&(c=""+r.key),function(e){if(Z.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return void 0!==e.ref}(r)&&(l=r.ref,function(e,r){if("string"==typeof e.ref&&Q.current&&r&&Q.current.stateNode!==r){var t=S(Q.current.type);K[t]||(_('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',S(Q.current.type),e.ref),K[t]=!0)}}(r,a)),r)Z.call(r,i)&&!ee.hasOwnProperty(i)&&(s[i]=r[i]);if(e&&e.defaultProps){var u=e.defaultProps;for(i in u)void 0===s[i]&&(s[i]=u[i])}if(c||l){var f="function"==typeof e?e.displayName||e.name||"Unknown":e;c&&function(e,r){var t=function(){J||(J=!0,_("%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})}(s,f),l&&function(e,r){var t=function(){X||(X=!0,_("%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})}(s,f)}return function(e,r,t,n,a,i,s){var c={$$typeof:o,type:e,key:r,ref:t,props:s,_owner:i,_store:{}};return Object.defineProperty(c._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(c,"_self",{configurable:!1,enumerable:!1,writable:!1,value:n}),Object.defineProperty(c,"_source",{configurable:!1,enumerable:!1,writable:!1,value:a}),Object.freeze&&(Object.freeze(c.props),Object.freeze(c)),c}(e,c,l,a,n,Q.current,s)}var te,ne=O.ReactCurrentOwner,oe=O.ReactDebugCurrentFrame;function ae(e){if(e){var r=e._owner,t=M(e.type,e._source,r?r.type:null);oe.setExtraStackFrame(t)}else oe.setExtraStackFrame(null)}function ie(e){return"object"==typeof e&&null!==e&&e.$$typeof===o}function se(){if(ne.current){var e=S(ne.current.type);if(e)return"\n\nCheck the render method of `"+e+"`."}return""}te=!1;var ce={};function le(e,r){if(e._store&&!e._store.validated&&null==e.key){e._store.validated=!0;var t=function(e){var r=se();if(!r){var t="string"==typeof e?e:e.displayName||e.name;t&&(r="\n\nCheck the top-level render call using <"+t+">.")}return r}(r);if(!ce[t]){ce[t]=!0;var n="";e&&e._owner&&e._owner!==ne.current&&(n=" It was passed a child from "+S(e._owner.type)+"."),ae(e),_('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),ae(null)}}}function ue(e,r){if("object"==typeof e)if(Array.isArray(e))for(var t=0;t<e.length;t++){var n=e[t];ie(n)&&le(n,r)}else if(ie(e))e._store&&(e._store.validated=!0);else if(e){var o=function(e){if(null===e||"object"!=typeof e)return null;var r=x&&e[x]||e["@@iterator"];return"function"==typeof r?r:null}(e);if("function"==typeof o&&o!==e.entries)for(var a,i=o.call(e);!(a=i.next()).done;)ie(a.value)&&le(a.value,r)}}function fe(e){var r,t=e.type;if(null!=t&&"string"!=typeof t){if("function"==typeof t)r=t.propTypes;else{if("object"!=typeof t||t.$$typeof!==u&&t.$$typeof!==y)return;r=t.propTypes}if(r){var n=S(t);!function(e,r,t,n,o){var a=Function.call.bind(Object.prototype.hasOwnProperty);for(var i in e)if(a(e,i)){var s=void 0;try{if("function"!=typeof e[i]){var c=Error((n||"React class")+": "+t+" type `"+i+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[i]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw c.name="Invariant Violation",c}s=e[i](r,i,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(e){s=e}!s||s instanceof Error||(H(o),_("%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,i,typeof s),H(null)),s instanceof Error&&!(s.message in V)&&(V[s.message]=!0,H(o),_("Failed %s type: %s",t,s.message),H(null))}}(r,e.props,"prop",n,e)}else if(void 0!==t.PropTypes&&!te){te=!0,_("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",S(t)||"Unknown")}"function"!=typeof t.getDefaultProps||t.getDefaultProps.isReactClassApproved||_("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pe(r,t,n,a,p,w){var x=function(r){return"string"==typeof r||"function"==typeof r||r===e.Fragment||r===s||r===h||r===i||r===f||r===d||r===j||"object"==typeof r&&null!==r&&(r.$$typeof===v||r.$$typeof===y||r.$$typeof===c||r.$$typeof===l||r.$$typeof===u||r.$$typeof===m||r.$$typeof===g||r[0]===b)}(r);if(!x){var O="";(void 0===r||"object"==typeof r&&null!==r&&0===Object.keys(r).length)&&(O+=" 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 k,R=function(e){return void 0!==e?"\n\nCheck your code at "+e.fileName.replace(/^.*[\\\/]/,"")+":"+e.lineNumber+".":""}(p);O+=R||se(),null===r?k="null":Array.isArray(r)?k="array":void 0!==r&&r.$$typeof===o?(k="<"+(S(r.type)||"Unknown")+" />",O=" Did you accidentally export a JSX literal instead of a component?"):k=typeof r,_("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",k,O)}var E=re(r,t,n,p,w);if(null==E)return E;if(x){var P=t.children;if(void 0!==P)if(a)if(Array.isArray(P)){for(var C=0;C<P.length;C++)ue(P[C],r);Object.freeze&&Object.freeze(P)}else _("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(P,r)}return r===e.Fragment?function(e){for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if("children"!==n&&"key"!==n){ae(e),_("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),ae(null);break}}null!==e.ref&&(ae(e),_("Invalid attribute `ref` supplied to `React.Fragment`."),ae(null))}(E):fe(E),E}var de=function(e,r,t){return pe(e,r,t,!1)},ye=function(e,r,t){return pe(e,r,t,!0)};e.jsx=de,e.jsxs=ye}()}(j),"production"===process.env.NODE_ENV?i.exports=s:i.exports=j;const O={primary:{bgColor:"bg-indigo-600",hover:"hover:bg-indigo-700",focus:"focus:ring-indigo-500 focus:ring-offset-indigo-200 focus:outline-none focus:ring-2 focus:ring-offset-2",text:"text-white text-center text-base font-semibold",border:void 0},secondary:{bgColor:"bg-white",hover:"hover:bg-gray-100",focus:void 0,text:"text-gray-900 text-center text-base font-medium",border:"border"},warn:{bgColor:"bg-yellow-400",hover:"hover:bg-yellow-500",focus:void 0,text:"text-white text-center text-base font-medium",border:void 0},error:{bgColor:"bg-red-500",hover:"hover:bg-red-600",focus:void 0,text:"text-white text-center text-base font-medium",border:void 0}};function _(e){if(null!=e)return Object.values(e).filter((e=>"string"==typeof e&&""!==e)).join(" ")}const k=e.memo(e.forwardRef(((e,r)=>{const{variant:t="primary",colorScheme:n,rounded:o="normal"}=e,s=a(e,["variant","colorScheme","rounded"]),c=_(n)||function(e){const r=O[e.toString()];if(null==r)throw new Error("Invalid color scheme");return _(r)}(t)||"";return i.exports.jsx("button",Object.assign({},s,{ref:r,type:"button",className:x("py-2 px-4 transition ease-in duration-200 rounded",c,e.className,{rounded:"normal"===o,"rounded-md":"md"===o,"rounded-lg":"lg"===o,"rounded-sm":"sm"===o,"rounded-none":"none"===o,"rounded-full":"full"===o})},{children:e.children}),void 0)})),o.default),R=e.createContext(null),S=e.createContext(null),E=e.forwardRef(((r,t)=>{const{title:n,className:o}=r,s=a(r,["title","className"]),c=e.useContext(R)===r.id,l=e.useContext(S);let u="w-5 h-5 mr-2 inline-block rounded-full border border-grey flex-no-shrink transition ";return u+=c?"bg-blue-500":"bg-white",i.exports.jsxs("div",Object.assign({ref:t,className:`flex items-center ${o}`},s,{children:[i.exports.jsx("input",{id:"ekp-radio",type:"radio",className:"hidden"},void 0),i.exports.jsxs("label",Object.assign({htmlFor:"ekp-radio",className:"flex items-center cursor-pointer",onClick:()=>{var e;l&&l(c?null:null!==(e=r.id)&&void 0!==e?e:null)}},{children:[i.exports.jsx("span",{className:u,style:{boxShadow:"0px 0px 0px 2px white inset"}},void 0),n]}),void 0)]}),void 0)})),P=e.forwardRef(((r,t)=>{var{Label:n,defaultChecked:o,onChange:s,className:c,style:l}=r,u=a(r,["Label","defaultChecked","onChange","className","style"]);const[f,p]=e.useState(null!=o&&o),d=e.useCallback((()=>{p((e=>(s&&s(!e),!e)))}),[s,p]);let y="toggle-indicator bg-white w-6 h-6 rounded-full shadow-md transform duration-300";f&&(y+=" translate-x-6");let v="w-14 h-8 flex items-center rounded-full p-1 duration-300 cursor-pointe";v+=f?" bg-blue-500":" bg-gray-300";const g=i.exports.jsx("div",Object.assign({className:`toggle ${v} ${c}`,onClick:d,ref:t,style:l},u,{children:i.exports.jsx("div",{className:y},void 0)}),void 0);return null==n?g:i.exports.jsx(n,Object.assign({checked:f},{children:g}),void 0)}));exports.Button=k,exports.Radio=E,exports.RadioGroup=({children:r})=>{const[t,n]=e.useState(null);return i.exports.jsx(S.Provider,Object.assign({value:n},{children:i.exports.jsx(R.Provider,Object.assign({value:t},{children:r}),void 0)}),void 0)},exports.Toggle=P; | ||
//# sourceMappingURL=index.js.map |
@@ -1,3 +0,4 @@ | ||
/// <reference types="react" /> | ||
export declare function Button(): JSX.Element; | ||
export * from './button'; | ||
export * from './radio'; | ||
export * from './toggle'; | ||
//# sourceMappingURL=index.d.ts.map |
{ | ||
"name": "@ekidpro/ui.button", | ||
"version": "0.0.26", | ||
"version": "0.0.27", | ||
"description": "> TODO: description", | ||
@@ -30,3 +30,3 @@ "author": "lamlv <lam.luongvan2305@gmail.com>", | ||
}, | ||
"gitHead": "e6292856dee2d0c1e6d4ca263103eb06b8126691" | ||
"gitHead": "0cacf8efed7520484fb32bf2ac341503fe053c80" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
217199
18
242
1