Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ekidpro/ui.button

Package Overview
Dependencies
Maintainers
3
Versions
52
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ekidpro/ui.button - npm Package Compare versions

Comparing version 0.0.27 to 0.0.28

6

lib/index.es.js

@@ -15,3 +15,3 @@ 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";

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;
***************************************************************************** */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},b=e,g=60103;
/** @license React v17.0.2

@@ -24,3 +24,3 @@ * react-jsx-runtime.production.min.js

* LICENSE file in the root directory of this source tree.
*/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,_={};
*/if(u.Fragment=60107,"function"==typeof Symbol&&Symbol.for){var m=Symbol.for;g=m("react.element"),u.Fragment=m("react.fragment")}var h=b.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,j=Object.prototype.hasOwnProperty,w={key:!0,ref:!0,__self:!0,__source:!0};function O(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)&&!w.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:g,type:e,key:a,ref:i,props:o,_owner:h.current}}u.jsx=O,u.jsxs=O;var x,_={};
/** @license React v17.0.2

@@ -33,3 +33,3 @@ * react-jsx-runtime.development.js

* LICENSE file in the root directory of this source tree.
*/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};
*/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,b=60122,g=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"),b=j("react.server.block"),g=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 w="function"==typeof Symbol&&Symbol.iterator,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 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,b=e.render,g="ForwardRef",m=b.displayName||b.name||"",v.displayName||(""!==m?g+"("+m+")":g);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,b,g,m;return null}var S,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,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=O.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=O.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=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===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=w&&e[w]||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 w=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===g||e.$$typeof===y||e[0]===b)}(e);if(!w){var O="";(void 0===e||"object"==typeof e&&null!==e&&0===Object.keys(e).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,E=function(e){return void 0!==e?"\n\nCheck your code at "+e.fileName.replace(/^.*[\\\/]/,"")+":"+e.lineNumber+".":""}(v);O+=E||se(),null===e?k="null":Array.isArray(e)?k="array":void 0!==e&&e.$$typeof===n?(k="<"+(R(e.type)||"Unknown")+" />",O=" 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,O)}var S=re(e,r,t,v,j);if(null==S)return S;if(w){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},disabled:{bgColor:"bg-gray-400",hover:void 0,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)=>{var t;const{colorScheme:n,rounded:o="normal"}=e,a=c(e,["colorScheme","rounded"]);let i=null!==(t=e.variant)&&void 0!==t?t:"primary";e.disabled&&(i="disabled");const s=S(n)||function(e){const r=R[e.toString()];if(null==r)throw new Error("Invalid color scheme");return S(r)}(i)||"";return l.exports.jsx("button",Object.assign({},a,{ref:r,type:"button",className:E("py-2 px-4 transition ease-in duration-200 rounded",s,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,"cursor-not-allowed":e.disabled})},{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 b="w-14 h-8 flex items-center rounded-full p-1 duration-300 cursor-pointe";b+=p?" bg-blue-500":" bg-gray-300";const g=l.exports.jsx("div",Object.assign({className:`toggle ${b} ${s}`,onClick:y,ref:r,style:u},f,{children:l.exports.jsx("div",{className:v},void 0)}),void 0);return null==t?g:l.exports.jsx(t,Object.assign({checked:p},{children:g}),void 0)}));export{P as Button,T as Radio,$ as RadioGroup,F as Toggle};
//# sourceMappingURL=index.es.js.map

@@ -24,3 +24,3 @@ "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);

* LICENSE file in the root directory of this source tree.
*/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={};
*/if(s.Fragment=60107,"function"==typeof Symbol&&Symbol.for){var v=Symbol.for;y=v("react.element"),s.Fragment=v("react.fragment")}var b=d.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,g=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)g.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:b.current}}s.jsx=h,s.jsxs=h;var x={};
/** @license React v17.0.2

@@ -33,3 +33,3 @@ * react-jsx-runtime.development.js

* LICENSE file in the root directory of this source tree.
*/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;
*/function j(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=j(e[r]))&&(n&&(n+=" "),n+=t);else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function w(){for(var e,r,t=0,n="";t<arguments.length;)(e=arguments[t++])&&(r=j(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,b=60121,g=60122,m=60117,h=60129,x=60131;if("function"==typeof Symbol&&Symbol.for){var j=Symbol.for;o=j("react.element"),a=j("react.portal"),e.Fragment=j("react.fragment"),i=j("react.strict_mode"),s=j("react.profiler"),c=j("react.provider"),l=j("react.context"),u=j("react.forward_ref"),f=j("react.suspense"),d=j("react.suspense_list"),y=j("react.memo"),v=j("react.lazy"),b=j("react.block"),g=j("react.server.block"),m=j("react.fundamental"),j("react.scope"),j("react.opaque.id"),h=j("react.debug_trace_mode"),j("react.offscreen"),x=j("react.legacy_hidden")}var w="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,g=r.render,m="ForwardRef",h=g.displayName||g.name||"",p.displayName||(""!==h?m+"("+h+")":m);case y:return S(r.type);case b: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,g,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 b: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=w&&e[w]||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,j){var w=function(r){return"string"==typeof r||"function"==typeof r||r===e.Fragment||r===s||r===h||r===i||r===f||r===d||r===x||"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===b||r[0]===g)}(r);if(!w){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,j);if(null==E)return E;if(w){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}()}(x),"production"===process.env.NODE_ENV?i.exports=s:i.exports=x;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},disabled:{bgColor:"bg-gray-400",hover:void 0,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)=>{var t;const{colorScheme:n,rounded:o="normal"}=e,s=a(e,["colorScheme","rounded"]);let c=null!==(t=e.variant)&&void 0!==t?t:"primary";e.disabled&&(c="disabled");const l=_(n)||function(e){const r=O[e.toString()];if(null==r)throw new Error("Invalid color scheme");return _(r)}(c)||"";return i.exports.jsx("button",Object.assign({},s,{ref:r,type:"button",className:w("py-2 px-4 transition ease-in duration-200 rounded",l,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,"cursor-not-allowed":e.disabled})},{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 b=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?b:i.exports.jsx(n,Object.assign({checked:f},{children:b}),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
import { ButtonHTMLAttributes } from 'react';
export declare type ButtonType = 'primary' | 'secondary' | 'warn' | 'error';
export declare type ButtonType = 'primary' | 'secondary' | 'warn' | 'error' | 'disabled';
export declare type ButtonColorScheme = {

@@ -4,0 +4,0 @@ bgColor?: string;

{
"name": "@ekidpro/ui.button",
"version": "0.0.27",
"version": "0.0.28",
"description": "> TODO: description",

@@ -30,3 +30,3 @@ "author": "lamlv <lam.luongvan2305@gmail.com>",

},
"gitHead": "0cacf8efed7520484fb32bf2ac341503fe053c80"
"gitHead": "0b7a642e352008a69927d72a79a4689621918f48"
}

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

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc