ymy-components 0.0.44 → 0.0.46

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -13,11 +13,12 @@ interface ListItemProps {
13
13
  textContent?: DynamicLanguage;
14
14
  characterPreference?: CharacterPreference;
15
15
  animate?: boolean;
16
+ maxDelay?: number;
16
17
  actionIcon?: SecondaryIconName;
17
18
  onClick?: () => void;
18
19
  styles?: React.CSSProperties;
19
20
  switchChecked?: boolean;
20
21
  onSwitchChange?: (checked: boolean) => void;
21
22
  }
22
- export declare const ListItem: ({ icon, text, textContent, characterPreference, animate, actionIcon, onClick, styles, switchChecked, onSwitchChange, }: ListItemProps) => ReactElement;
23
+ export declare const ListItem: ({ icon, text, textContent, characterPreference, animate, maxDelay, actionIcon, onClick, styles, switchChecked, onSwitchChange, }: ListItemProps) => ReactElement;
23
24
  export {};
@@ -10,4 +10,4 @@ export declare const ListItemContainer: import('styled-components/dist/types').I
10
10
  export declare const ListItemContent: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
11
11
  export declare const ListItemLeftContent: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
12
12
  export declare const ListItemIcon: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
13
- export declare const ListItemText: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLParagraphElement>, HTMLParagraphElement>, never>> & string;
13
+ export declare const ListItemText: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, never>> & string;
package/dist/index.cjs.js CHANGED
@@ -210,7 +210,7 @@ See https://s-c.sh/2BAXzed for more info.`),window[ir]+=1);const Xu=Ns`
210
210
  display: flex;
211
211
  flex-direction: column;
212
212
  justify-content: center;
213
- `,xl=q.p`
213
+ `,xl=q.span`
214
214
  font-size: 1rem;
215
215
  `;function kl(e){return Me({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"m12.87 15.07-2.54-2.51.03-.03A17.52 17.52 0 0 0 14.07 6H17V4h-7V2H8v2H1v1.99h11.17C11.5 7.92 10.44 9.75 9 11.35 8.07 10.32 7.3 9.19 6.69 8h-2c.73 1.63 1.73 3.17 2.98 4.56l-5.09 5.02L4 19l5-5 3.11 3.11.76-2.04zM18.5 10h-2L12 22h2l1.12-3h4.75L21 22h2l-4.5-12zm-2.62 7 1.62-4.33L19.12 17h-3.24z"},child:[]}]})(e)}function Ol(e){return Me({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"},child:[]}]})(e)}function Pl(e){return Me({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"m6.76 4.84-1.8-1.79-1.41 1.41 1.79 1.79zM1 10.5h3v2H1zM11 .55h2V3.5h-2zm8.04 2.495 1.408 1.407-1.79 1.79-1.407-1.408zm-1.8 15.115 1.79 1.8 1.41-1.41-1.8-1.79zM20 10.5h3v2h-3zm-8-5c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zm0 10c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm-1 4h2v2.95h-2zm-7.45-.96 1.41 1.41 1.79-1.8-1.41-1.41z"},child:[]}]})(e)}const Nl=q.input`
216
216
  opacity: 0;
@@ -266,7 +266,7 @@ See https://s-c.sh/2BAXzed for more info.`),window[ir]+=1);const Xu=Ns`
266
266
  transition: left 150ms cubic-bezier(0.4, 0, 0.2, 1),
267
267
  background-color 150ms cubic-bezier(0.4, 0, 0.2, 1);
268
268
  pointer-events: none;
269
- `,As=({checked:e,defaultChecked:t=!1,onChange:r,disabled:n=!1})=>{const[i,o]=N.useState(t),s=e!==void 0,a=s?e:i,u=l=>{if(n)return;l.target.blur();const f=!a;s||o(f),r==null||r(f)};return j.jsxs(Cl,{$checked:a,onClick:l=>l.stopPropagation(),children:[j.jsx(Nl,{type:"checkbox",checked:a,onChange:u,disabled:n}),j.jsx(Rl,{$checked:a}),j.jsx(Nn,{$checked:a}),j.jsx(Al,{$checked:a})]})},Tl={translate:kl,sunny:Pl,character:()=>j.jsx("p",{style:{fontSize:"1rem",fontWeight:500},children:"字"})},Il=({icon:e,text:t,textContent:r,characterPreference:n,animate:i=!0,actionIcon:o="chevron",onClick:s,styles:a,switchChecked:u,onSwitchChange:l})=>{const f=Tl[e],[d,h]=N.useState(null),p=E=>{const w=E.currentTarget.getBoundingClientRect(),y=E.clientX-w.left,b=E.clientY-w.top;h({x:y,y:b,key:Date.now()}),o==="switch"&&l?l(!u):s&&s()},v=()=>o==="switch"?j.jsx(As,{checked:u,onChange:l}):j.jsx(Ol,{});return j.jsxs(_l,{onClick:p,style:a,children:[d&&j.jsx(bl,{$x:d.x,$y:d.y},d.key),j.jsxs(El,{children:[j.jsxs(Sl,{children:[j.jsx(ao,{children:j.jsx(f,{size:"1rem"})}),j.jsx(xl,{children:r?j.jsx(Xn,{content:r,characterPreference:n,animate:i}):t})]}),j.jsx(ao,{children:v()})]})]})};function Q(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var Dl=typeof Symbol=="function"&&Symbol.observable||"@@observable",co=Dl,an=()=>Math.random().toString(36).substring(7).split("").join("."),jl={INIT:`@@redux/INIT${an()}`,REPLACE:`@@redux/REPLACE${an()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${an()}`},Ye=jl;function Kt(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function Vl(e){if(e===void 0)return"undefined";if(e===null)return"null";const t=typeof e;switch(t){case"boolean":case"string":case"number":case"symbol":case"function":return t}if(Array.isArray(e))return"array";if(zl(e))return"date";if(Ml(e))return"error";const r=$l(e);switch(r){case"Symbol":case"Promise":case"WeakMap":case"WeakSet":case"Map":case"Set":return r}return Object.prototype.toString.call(e).slice(8,-1).toLowerCase().replace(/\s/g,"")}function $l(e){return typeof e.constructor=="function"?e.constructor.name:null}function Ml(e){return e instanceof Error||typeof e.message=="string"&&e.constructor&&typeof e.constructor.stackTraceLimit=="number"}function zl(e){return e instanceof Date?!0:typeof e.toDateString=="function"&&typeof e.getDate=="function"&&typeof e.setDate=="function"}function De(e){let t=typeof e;return process.env.NODE_ENV!=="production"&&(t=Vl(e)),t}function Ts(e,t,r){if(typeof e!="function")throw new Error(process.env.NODE_ENV==="production"?Q(2):`Expected the root reducer to be a function. Instead, received: '${De(e)}'`);if(typeof t=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(process.env.NODE_ENV==="production"?Q(0):"It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function. See https://redux.js.org/tutorials/fundamentals/part-4-store#creating-a-store-with-enhancers for an example.");if(typeof t=="function"&&typeof r>"u"&&(r=t,t=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(process.env.NODE_ENV==="production"?Q(1):`Expected the enhancer to be a function. Instead, received: '${De(r)}'`);return r(Ts)(e,t)}let n=e,i=t,o=new Map,s=o,a=0,u=!1;function l(){s===o&&(s=new Map,o.forEach((w,y)=>{s.set(y,w)}))}function f(){if(u)throw new Error(process.env.NODE_ENV==="production"?Q(3):"You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return i}function d(w){if(typeof w!="function")throw new Error(process.env.NODE_ENV==="production"?Q(4):`Expected the listener to be a function. Instead, received: '${De(w)}'`);if(u)throw new Error(process.env.NODE_ENV==="production"?Q(5):"You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api/store#subscribelistener for more details.");let y=!0;l();const b=a++;return s.set(b,w),function(){if(y){if(u)throw new Error(process.env.NODE_ENV==="production"?Q(6):"You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api/store#subscribelistener for more details.");y=!1,l(),s.delete(b),o=null}}}function h(w){if(!Kt(w))throw new Error(process.env.NODE_ENV==="production"?Q(7):`Actions must be plain objects. Instead, the actual type was: '${De(w)}'. You may need to add middleware to your store setup to handle dispatching other values, such as 'redux-thunk' to handle dispatching functions. See https://redux.js.org/tutorials/fundamentals/part-4-store#middleware and https://redux.js.org/tutorials/fundamentals/part-6-async-logic#using-the-redux-thunk-middleware for examples.`);if(typeof w.type>"u")throw new Error(process.env.NODE_ENV==="production"?Q(8):'Actions may not have an undefined "type" property. You may have misspelled an action type string constant.');if(typeof w.type!="string")throw new Error(process.env.NODE_ENV==="production"?Q(17):`Action "type" property must be a string. Instead, the actual type was: '${De(w.type)}'. Value was: '${w.type}' (stringified)`);if(u)throw new Error(process.env.NODE_ENV==="production"?Q(9):"Reducers may not dispatch actions.");try{u=!0,i=n(i,w)}finally{u=!1}return(o=s).forEach(b=>{b()}),w}function p(w){if(typeof w!="function")throw new Error(process.env.NODE_ENV==="production"?Q(10):`Expected the nextReducer to be a function. Instead, received: '${De(w)}`);n=w,h({type:Ye.REPLACE})}function v(){const w=d;return{subscribe(y){if(typeof y!="object"||y===null)throw new Error(process.env.NODE_ENV==="production"?Q(11):`Expected the observer to be an object. Instead, received: '${De(y)}'`);function b(){const S=y;S.next&&S.next(f())}return b(),{unsubscribe:w(b)}},[co](){return this}}}return h({type:Ye.INIT}),{dispatch:h,subscribe:d,getState:f,replaceReducer:p,[co]:v}}function uo(e){typeof console<"u"&&typeof console.error=="function"&&console.error(e);try{throw new Error(e)}catch{}}function Fl(e,t,r,n){const i=Object.keys(t),o=r&&r.type===Ye.INIT?"preloadedState argument passed to createStore":"previous state received by the reducer";if(i.length===0)return"Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";if(!Kt(e))return`The ${o} has unexpected type of "${De(e)}". Expected argument to be an object with the following keys: "${i.join('", "')}"`;const s=Object.keys(e).filter(a=>!t.hasOwnProperty(a)&&!n[a]);if(s.forEach(a=>{n[a]=!0}),!(r&&r.type===Ye.REPLACE)&&s.length>0)return`Unexpected ${s.length>1?"keys":"key"} "${s.join('", "')}" found in ${o}. Expected to find one of the known reducer keys instead: "${i.join('", "')}". Unexpected keys will be ignored.`}function Ll(e){Object.keys(e).forEach(t=>{const r=e[t];if(typeof r(void 0,{type:Ye.INIT})>"u")throw new Error(process.env.NODE_ENV==="production"?Q(12):`The slice reducer for key "${t}" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined.`);if(typeof r(void 0,{type:Ye.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(process.env.NODE_ENV==="production"?Q(13):`The slice reducer for key "${t}" returned undefined when probed with a random type. Don't try to handle '${Ye.INIT}' or other actions in "redux/*" namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined, but can be null.`)})}function Is(e){const t=Object.keys(e),r={};for(let s=0;s<t.length;s++){const a=t[s];process.env.NODE_ENV!=="production"&&typeof e[a]>"u"&&uo(`No reducer provided for key "${a}"`),typeof e[a]=="function"&&(r[a]=e[a])}const n=Object.keys(r);let i;process.env.NODE_ENV!=="production"&&(i={});let o;try{Ll(r)}catch(s){o=s}return function(a={},u){if(o)throw o;if(process.env.NODE_ENV!=="production"){const d=Fl(a,r,u,i);d&&uo(d)}let l=!1;const f={};for(let d=0;d<n.length;d++){const h=n[d],p=r[h],v=a[h],E=p(v,u);if(typeof E>"u"){const w=u&&u.type;throw new Error(process.env.NODE_ENV==="production"?Q(14):`When called with an action of type ${w?`"${String(w)}"`:"(unknown type)"}, the slice reducer for key "${h}" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.`)}f[h]=E,l=l||E!==v}return l=l||n.length!==Object.keys(a).length,l?f:a}}function Sr(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,r)=>(...n)=>t(r(...n)))}function Bl(...e){return t=>(r,n)=>{const i=t(r,n);let o=()=>{throw new Error(process.env.NODE_ENV==="production"?Q(15):"Dispatching while constructing your middleware is not allowed. Other middleware would not be applied to this dispatch.")};const s={getState:i.getState,dispatch:(u,...l)=>o(u,...l)},a=e.map(u=>u(s));return o=Sr(...a)(i.dispatch),{...i,dispatch:o}}}function Ds(e){return Kt(e)&&"type"in e&&typeof e.type=="string"}var js=Symbol.for("immer-nothing"),lo=Symbol.for("immer-draftable"),se=Symbol.for("immer-state"),Ul=process.env.NODE_ENV!=="production"?[function(e){return`The plugin for '${e}' has not been loaded into Immer. To enable the plugin, import and call \`enable${e}()\` when initializing your application.`},function(e){return`produce can only be called on things that are draftable: plain objects, arrays, Map, Set or classes that are marked with '[immerable]: true'. Got '${e}'`},"This object has been frozen and should not be mutated",function(e){return"Cannot use a proxy that has been revoked. Did you pass an object from inside an immer function to an async process? "+e},"An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.","Immer forbids circular references","The first or second argument to `produce` must be a function","The third argument to `produce` must be a function or undefined","First argument to `createDraft` must be a plain object, an array, or an immerable object","First argument to `finishDraft` must be a draft returned by `createDraft`",function(e){return`'current' expects a draft, got: ${e}`},"Object.defineProperty() cannot be used on an Immer draft","Object.setPrototypeOf() cannot be used on an Immer draft","Immer only supports deleting array indices","Immer only supports setting array indices and the 'length' property",function(e){return`'original' expects a draft, got: ${e}`}]:[];function te(e,...t){if(process.env.NODE_ENV!=="production"){const r=Ul[e],n=typeof r=="function"?r.apply(null,t):r;throw new Error(`[Immer] ${n}`)}throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var mt=Object.getPrototypeOf;function Xe(e){return!!e&&!!e[se]}function Pe(e){var t;return e?Vs(e)||Array.isArray(e)||!!e[lo]||!!((t=e.constructor)!=null&&t[lo])||Br(e)||Ur(e):!1}var ql=Object.prototype.constructor.toString();function Vs(e){if(!e||typeof e!="object")return!1;const t=mt(e);if(t===null)return!0;const r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return r===Object?!0:typeof r=="function"&&Function.toString.call(r)===ql}function xr(e,t){Lr(e)===0?Reflect.ownKeys(e).forEach(r=>{t(r,e[r],e)}):e.forEach((r,n)=>t(n,r,e))}function Lr(e){const t=e[se];return t?t.type_:Array.isArray(e)?1:Br(e)?2:Ur(e)?3:0}function Cn(e,t){return Lr(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function $s(e,t,r){const n=Lr(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function Wl(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Br(e){return e instanceof Map}function Ur(e){return e instanceof Set}function Le(e){return e.copy_||e.base_}function Rn(e,t){if(Br(e))return new Map(e);if(Ur(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const r=Vs(e);if(t===!0||t==="class_only"&&!r){const n=Object.getOwnPropertyDescriptors(e);delete n[se];let i=Reflect.ownKeys(n);for(let o=0;o<i.length;o++){const s=i[o],a=n[s];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(n[s]={configurable:!0,writable:!0,enumerable:a.enumerable,value:e[s]})}return Object.create(mt(e),n)}else{const n=mt(e);if(n!==null&&r)return{...e};const i=Object.create(n);return Object.assign(i,e)}}function ni(e,t=!1){return qr(e)||Xe(e)||!Pe(e)||(Lr(e)>1&&(e.set=e.add=e.clear=e.delete=Hl),Object.freeze(e),t&&Object.entries(e).forEach(([r,n])=>ni(n,!0))),e}function Hl(){te(2)}function qr(e){return Object.isFrozen(e)}var Yl={};function Je(e){const t=Yl[e];return t||te(0,e),t}var qt;function Ms(){return qt}function Gl(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function fo(e,t){t&&(Je("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function An(e){Tn(e),e.drafts_.forEach(Kl),e.drafts_=null}function Tn(e){e===qt&&(qt=e.parent_)}function ho(e){return qt=Gl(qt,e)}function Kl(e){const t=e[se];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function po(e,t){t.unfinalizedDrafts_=t.drafts_.length;const r=t.drafts_[0];return e!==void 0&&e!==r?(r[se].modified_&&(An(t),te(4)),Pe(e)&&(e=kr(t,e),t.parent_||Or(t,e)),t.patches_&&Je("Patches").generateReplacementPatches_(r[se].base_,e,t.patches_,t.inversePatches_)):e=kr(t,r,[]),An(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==js?e:void 0}function kr(e,t,r){if(qr(t))return t;const n=t[se];if(!n)return xr(t,(i,o)=>mo(e,n,t,i,o,r)),t;if(n.scope_!==e)return t;if(!n.modified_)return Or(e,n.base_,!0),n.base_;if(!n.finalized_){n.finalized_=!0,n.scope_.unfinalizedDrafts_--;const i=n.copy_;let o=i,s=!1;n.type_===3&&(o=new Set(i),i.clear(),s=!0),xr(o,(a,u)=>mo(e,n,i,a,u,r,s)),Or(e,i,!1),r&&e.patches_&&Je("Patches").generatePatches_(n,r,e.patches_,e.inversePatches_)}return n.copy_}function mo(e,t,r,n,i,o,s){if(process.env.NODE_ENV!=="production"&&i===r&&te(5),Xe(i)){const a=o&&t&&t.type_!==3&&!Cn(t.assigned_,n)?o.concat(n):void 0,u=kr(e,i,a);if($s(r,n,u),Xe(u))e.canAutoFreeze_=!1;else return}else s&&r.add(i);if(Pe(i)&&!qr(i)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;kr(e,i),(!t||!t.scope_.parent_)&&typeof n!="symbol"&&Object.prototype.propertyIsEnumerable.call(r,n)&&Or(e,i)}}function Or(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&ni(t,r)}function Ql(e,t){const r=Array.isArray(e),n={type_:r?1:0,scope_:t?t.scope_:Ms(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=n,o=ii;r&&(i=[n],o=Wt);const{revoke:s,proxy:a}=Proxy.revocable(i,o);return n.draft_=a,n.revoke_=s,a}var ii={get(e,t){if(t===se)return e;const r=Le(e);if(!Cn(r,t))return Xl(e,r,t);const n=r[t];return e.finalized_||!Pe(n)?n:n===cn(e.base_,t)?(un(e),e.copy_[t]=Dn(n,e)):n},has(e,t){return t in Le(e)},ownKeys(e){return Reflect.ownKeys(Le(e))},set(e,t,r){const n=zs(Le(e),t);if(n!=null&&n.set)return n.set.call(e.draft_,r),!0;if(!e.modified_){const i=cn(Le(e),t),o=i==null?void 0:i[se];if(o&&o.base_===r)return e.copy_[t]=r,e.assigned_[t]=!1,!0;if(Wl(r,i)&&(r!==void 0||Cn(e.base_,t)))return!0;un(e),In(e)}return e.copy_[t]===r&&(r!==void 0||t in e.copy_)||Number.isNaN(r)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=r,e.assigned_[t]=!0),!0},deleteProperty(e,t){return cn(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,un(e),In(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const r=Le(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty(){te(11)},getPrototypeOf(e){return mt(e.base_)},setPrototypeOf(){te(12)}},Wt={};xr(ii,(e,t)=>{Wt[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});Wt.deleteProperty=function(e,t){return process.env.NODE_ENV!=="production"&&isNaN(parseInt(t))&&te(13),Wt.set.call(this,e,t,void 0)};Wt.set=function(e,t,r){return process.env.NODE_ENV!=="production"&&t!=="length"&&isNaN(parseInt(t))&&te(14),ii.set.call(this,e[0],t,r,e[0])};function cn(e,t){const r=e[se];return(r?Le(r):e)[t]}function Xl(e,t,r){var i;const n=zs(t,r);return n?"value"in n?n.value:(i=n.get)==null?void 0:i.call(e.draft_):void 0}function zs(e,t){if(!(t in e))return;let r=mt(e);for(;r;){const n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=mt(r)}}function In(e){e.modified_||(e.modified_=!0,e.parent_&&In(e.parent_))}function un(e){e.copy_||(e.copy_=Rn(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var Jl=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,r,n)=>{if(typeof t=="function"&&typeof r!="function"){const o=r;r=t;const s=this;return function(u=o,...l){return s.produce(u,f=>r.call(this,f,...l))}}typeof r!="function"&&te(6),n!==void 0&&typeof n!="function"&&te(7);let i;if(Pe(t)){const o=ho(this),s=Dn(t,void 0);let a=!0;try{i=r(s),a=!1}finally{a?An(o):Tn(o)}return fo(o,n),po(i,o)}else if(!t||typeof t!="object"){if(i=r(t),i===void 0&&(i=t),i===js&&(i=void 0),this.autoFreeze_&&ni(i,!0),n){const o=[],s=[];Je("Patches").generateReplacementPatches_(t,i,o,s),n(o,s)}return i}else te(1,t)},this.produceWithPatches=(t,r)=>{if(typeof t=="function")return(s,...a)=>this.produceWithPatches(s,u=>t(u,...a));let n,i;return[this.produce(t,r,(s,a)=>{n=s,i=a}),n,i]},typeof(e==null?void 0:e.autoFreeze)=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof(e==null?void 0:e.useStrictShallowCopy)=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){Pe(e)||te(8),Xe(e)&&(e=Zl(e));const t=ho(this),r=Dn(e,void 0);return r[se].isManual_=!0,Tn(t),r}finishDraft(e,t){const r=e&&e[se];(!r||!r.isManual_)&&te(9);const{scope_:n}=r;return fo(n,t),po(void 0,n)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let r;for(r=t.length-1;r>=0;r--){const i=t[r];if(i.path.length===0&&i.op==="replace"){e=i.value;break}}r>-1&&(t=t.slice(r+1));const n=Je("Patches").applyPatches_;return Xe(e)?n(e,t):this.produce(e,i=>n(i,t))}};function Dn(e,t){const r=Br(e)?Je("MapSet").proxyMap_(e,t):Ur(e)?Je("MapSet").proxySet_(e,t):Ql(e,t);return(t?t.scope_:Ms()).drafts_.push(r),r}function Zl(e){return Xe(e)||te(10,e),Fs(e)}function Fs(e){if(!Pe(e)||qr(e))return e;const t=e[se];let r;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=Rn(e,t.scope_.immer_.useStrictShallowCopy_)}else r=Rn(e,!0);return xr(r,(n,i)=>{$s(r,n,Fs(i))}),t&&(t.finalized_=!1),r}var ae=new Jl,Ls=ae.produce;ae.produceWithPatches.bind(ae);ae.setAutoFreeze.bind(ae);ae.setUseStrictShallowCopy.bind(ae);ae.applyPatches.bind(ae);ae.createDraft.bind(ae);ae.finishDraft.bind(ae);function Bs(e){return({dispatch:r,getState:n})=>i=>o=>typeof o=="function"?o(r,n,e):i(o)}var ef=Bs(),tf=Bs,rf=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Sr:Sr.apply(null,arguments)},nf=e=>e&&typeof e.match=="function";function yo(e,t){function r(...n){if(t){let i=t(...n);if(!i)throw new Error(process.env.NODE_ENV==="production"?B(0):"prepareAction did not return an object");return{type:e,payload:i.payload,..."meta"in i&&{meta:i.meta},..."error"in i&&{error:i.error}}}return{type:e,payload:n[0]}}return r.toString=()=>`${e}`,r.type=e,r.match=n=>Ds(n)&&n.type===e,r}function of(e){return typeof e=="function"&&"type"in e&&nf(e)}function sf(e){const t=e?`${e}`.split("/"):[],r=t[t.length-1]||"actionCreator";return`Detected an action creator with type "${e||"unknown"}" being dispatched.
269
+ `,As=({checked:e,defaultChecked:t=!1,onChange:r,disabled:n=!1})=>{const[i,o]=N.useState(t),s=e!==void 0,a=s?e:i,u=l=>{if(n)return;l.target.blur();const f=!a;s||o(f),r==null||r(f)};return j.jsxs(Cl,{$checked:a,onClick:l=>l.stopPropagation(),children:[j.jsx(Nl,{type:"checkbox",checked:a,onChange:u,disabled:n}),j.jsx(Rl,{$checked:a}),j.jsx(Nn,{$checked:a}),j.jsx(Al,{$checked:a})]})},Tl={translate:kl,sunny:Pl,character:()=>j.jsx("p",{style:{fontSize:"1rem",fontWeight:500},children:"字"})},Il=({icon:e,text:t,textContent:r,characterPreference:n,animate:i=!0,maxDelay:o,actionIcon:s="chevron",onClick:a,styles:u,switchChecked:l,onSwitchChange:f})=>{const d=Tl[e],[h,p]=N.useState(null),v=w=>{const y=w.currentTarget.getBoundingClientRect(),b=w.clientX-y.left,m=w.clientY-y.top;p({x:b,y:m,key:Date.now()}),s==="switch"&&f?f(!l):a&&a()},E=()=>s==="switch"?j.jsx(As,{checked:l,onChange:f}):j.jsx(Ol,{});return j.jsxs(_l,{onClick:v,style:u,children:[h&&j.jsx(bl,{$x:h.x,$y:h.y},h.key),j.jsxs(El,{children:[j.jsxs(Sl,{children:[j.jsx(ao,{children:j.jsx(d,{size:"1rem"})}),j.jsx(xl,{children:r?j.jsx(Xn,{content:r,characterPreference:n,animate:i,maxDelay:o}):t})]}),j.jsx(ao,{children:E()})]})]})};function Q(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var Dl=typeof Symbol=="function"&&Symbol.observable||"@@observable",co=Dl,an=()=>Math.random().toString(36).substring(7).split("").join("."),jl={INIT:`@@redux/INIT${an()}`,REPLACE:`@@redux/REPLACE${an()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${an()}`},Ye=jl;function Kt(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function Vl(e){if(e===void 0)return"undefined";if(e===null)return"null";const t=typeof e;switch(t){case"boolean":case"string":case"number":case"symbol":case"function":return t}if(Array.isArray(e))return"array";if(zl(e))return"date";if(Ml(e))return"error";const r=$l(e);switch(r){case"Symbol":case"Promise":case"WeakMap":case"WeakSet":case"Map":case"Set":return r}return Object.prototype.toString.call(e).slice(8,-1).toLowerCase().replace(/\s/g,"")}function $l(e){return typeof e.constructor=="function"?e.constructor.name:null}function Ml(e){return e instanceof Error||typeof e.message=="string"&&e.constructor&&typeof e.constructor.stackTraceLimit=="number"}function zl(e){return e instanceof Date?!0:typeof e.toDateString=="function"&&typeof e.getDate=="function"&&typeof e.setDate=="function"}function De(e){let t=typeof e;return process.env.NODE_ENV!=="production"&&(t=Vl(e)),t}function Ts(e,t,r){if(typeof e!="function")throw new Error(process.env.NODE_ENV==="production"?Q(2):`Expected the root reducer to be a function. Instead, received: '${De(e)}'`);if(typeof t=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(process.env.NODE_ENV==="production"?Q(0):"It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function. See https://redux.js.org/tutorials/fundamentals/part-4-store#creating-a-store-with-enhancers for an example.");if(typeof t=="function"&&typeof r>"u"&&(r=t,t=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(process.env.NODE_ENV==="production"?Q(1):`Expected the enhancer to be a function. Instead, received: '${De(r)}'`);return r(Ts)(e,t)}let n=e,i=t,o=new Map,s=o,a=0,u=!1;function l(){s===o&&(s=new Map,o.forEach((w,y)=>{s.set(y,w)}))}function f(){if(u)throw new Error(process.env.NODE_ENV==="production"?Q(3):"You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return i}function d(w){if(typeof w!="function")throw new Error(process.env.NODE_ENV==="production"?Q(4):`Expected the listener to be a function. Instead, received: '${De(w)}'`);if(u)throw new Error(process.env.NODE_ENV==="production"?Q(5):"You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api/store#subscribelistener for more details.");let y=!0;l();const b=a++;return s.set(b,w),function(){if(y){if(u)throw new Error(process.env.NODE_ENV==="production"?Q(6):"You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api/store#subscribelistener for more details.");y=!1,l(),s.delete(b),o=null}}}function h(w){if(!Kt(w))throw new Error(process.env.NODE_ENV==="production"?Q(7):`Actions must be plain objects. Instead, the actual type was: '${De(w)}'. You may need to add middleware to your store setup to handle dispatching other values, such as 'redux-thunk' to handle dispatching functions. See https://redux.js.org/tutorials/fundamentals/part-4-store#middleware and https://redux.js.org/tutorials/fundamentals/part-6-async-logic#using-the-redux-thunk-middleware for examples.`);if(typeof w.type>"u")throw new Error(process.env.NODE_ENV==="production"?Q(8):'Actions may not have an undefined "type" property. You may have misspelled an action type string constant.');if(typeof w.type!="string")throw new Error(process.env.NODE_ENV==="production"?Q(17):`Action "type" property must be a string. Instead, the actual type was: '${De(w.type)}'. Value was: '${w.type}' (stringified)`);if(u)throw new Error(process.env.NODE_ENV==="production"?Q(9):"Reducers may not dispatch actions.");try{u=!0,i=n(i,w)}finally{u=!1}return(o=s).forEach(b=>{b()}),w}function p(w){if(typeof w!="function")throw new Error(process.env.NODE_ENV==="production"?Q(10):`Expected the nextReducer to be a function. Instead, received: '${De(w)}`);n=w,h({type:Ye.REPLACE})}function v(){const w=d;return{subscribe(y){if(typeof y!="object"||y===null)throw new Error(process.env.NODE_ENV==="production"?Q(11):`Expected the observer to be an object. Instead, received: '${De(y)}'`);function b(){const S=y;S.next&&S.next(f())}return b(),{unsubscribe:w(b)}},[co](){return this}}}return h({type:Ye.INIT}),{dispatch:h,subscribe:d,getState:f,replaceReducer:p,[co]:v}}function uo(e){typeof console<"u"&&typeof console.error=="function"&&console.error(e);try{throw new Error(e)}catch{}}function Fl(e,t,r,n){const i=Object.keys(t),o=r&&r.type===Ye.INIT?"preloadedState argument passed to createStore":"previous state received by the reducer";if(i.length===0)return"Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";if(!Kt(e))return`The ${o} has unexpected type of "${De(e)}". Expected argument to be an object with the following keys: "${i.join('", "')}"`;const s=Object.keys(e).filter(a=>!t.hasOwnProperty(a)&&!n[a]);if(s.forEach(a=>{n[a]=!0}),!(r&&r.type===Ye.REPLACE)&&s.length>0)return`Unexpected ${s.length>1?"keys":"key"} "${s.join('", "')}" found in ${o}. Expected to find one of the known reducer keys instead: "${i.join('", "')}". Unexpected keys will be ignored.`}function Ll(e){Object.keys(e).forEach(t=>{const r=e[t];if(typeof r(void 0,{type:Ye.INIT})>"u")throw new Error(process.env.NODE_ENV==="production"?Q(12):`The slice reducer for key "${t}" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined.`);if(typeof r(void 0,{type:Ye.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(process.env.NODE_ENV==="production"?Q(13):`The slice reducer for key "${t}" returned undefined when probed with a random type. Don't try to handle '${Ye.INIT}' or other actions in "redux/*" namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined, but can be null.`)})}function Is(e){const t=Object.keys(e),r={};for(let s=0;s<t.length;s++){const a=t[s];process.env.NODE_ENV!=="production"&&typeof e[a]>"u"&&uo(`No reducer provided for key "${a}"`),typeof e[a]=="function"&&(r[a]=e[a])}const n=Object.keys(r);let i;process.env.NODE_ENV!=="production"&&(i={});let o;try{Ll(r)}catch(s){o=s}return function(a={},u){if(o)throw o;if(process.env.NODE_ENV!=="production"){const d=Fl(a,r,u,i);d&&uo(d)}let l=!1;const f={};for(let d=0;d<n.length;d++){const h=n[d],p=r[h],v=a[h],E=p(v,u);if(typeof E>"u"){const w=u&&u.type;throw new Error(process.env.NODE_ENV==="production"?Q(14):`When called with an action of type ${w?`"${String(w)}"`:"(unknown type)"}, the slice reducer for key "${h}" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.`)}f[h]=E,l=l||E!==v}return l=l||n.length!==Object.keys(a).length,l?f:a}}function Sr(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,r)=>(...n)=>t(r(...n)))}function Bl(...e){return t=>(r,n)=>{const i=t(r,n);let o=()=>{throw new Error(process.env.NODE_ENV==="production"?Q(15):"Dispatching while constructing your middleware is not allowed. Other middleware would not be applied to this dispatch.")};const s={getState:i.getState,dispatch:(u,...l)=>o(u,...l)},a=e.map(u=>u(s));return o=Sr(...a)(i.dispatch),{...i,dispatch:o}}}function Ds(e){return Kt(e)&&"type"in e&&typeof e.type=="string"}var js=Symbol.for("immer-nothing"),lo=Symbol.for("immer-draftable"),se=Symbol.for("immer-state"),Ul=process.env.NODE_ENV!=="production"?[function(e){return`The plugin for '${e}' has not been loaded into Immer. To enable the plugin, import and call \`enable${e}()\` when initializing your application.`},function(e){return`produce can only be called on things that are draftable: plain objects, arrays, Map, Set or classes that are marked with '[immerable]: true'. Got '${e}'`},"This object has been frozen and should not be mutated",function(e){return"Cannot use a proxy that has been revoked. Did you pass an object from inside an immer function to an async process? "+e},"An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.","Immer forbids circular references","The first or second argument to `produce` must be a function","The third argument to `produce` must be a function or undefined","First argument to `createDraft` must be a plain object, an array, or an immerable object","First argument to `finishDraft` must be a draft returned by `createDraft`",function(e){return`'current' expects a draft, got: ${e}`},"Object.defineProperty() cannot be used on an Immer draft","Object.setPrototypeOf() cannot be used on an Immer draft","Immer only supports deleting array indices","Immer only supports setting array indices and the 'length' property",function(e){return`'original' expects a draft, got: ${e}`}]:[];function te(e,...t){if(process.env.NODE_ENV!=="production"){const r=Ul[e],n=typeof r=="function"?r.apply(null,t):r;throw new Error(`[Immer] ${n}`)}throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var mt=Object.getPrototypeOf;function Xe(e){return!!e&&!!e[se]}function Pe(e){var t;return e?Vs(e)||Array.isArray(e)||!!e[lo]||!!((t=e.constructor)!=null&&t[lo])||Br(e)||Ur(e):!1}var ql=Object.prototype.constructor.toString();function Vs(e){if(!e||typeof e!="object")return!1;const t=mt(e);if(t===null)return!0;const r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return r===Object?!0:typeof r=="function"&&Function.toString.call(r)===ql}function xr(e,t){Lr(e)===0?Reflect.ownKeys(e).forEach(r=>{t(r,e[r],e)}):e.forEach((r,n)=>t(n,r,e))}function Lr(e){const t=e[se];return t?t.type_:Array.isArray(e)?1:Br(e)?2:Ur(e)?3:0}function Cn(e,t){return Lr(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function $s(e,t,r){const n=Lr(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function Wl(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Br(e){return e instanceof Map}function Ur(e){return e instanceof Set}function Le(e){return e.copy_||e.base_}function Rn(e,t){if(Br(e))return new Map(e);if(Ur(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const r=Vs(e);if(t===!0||t==="class_only"&&!r){const n=Object.getOwnPropertyDescriptors(e);delete n[se];let i=Reflect.ownKeys(n);for(let o=0;o<i.length;o++){const s=i[o],a=n[s];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(n[s]={configurable:!0,writable:!0,enumerable:a.enumerable,value:e[s]})}return Object.create(mt(e),n)}else{const n=mt(e);if(n!==null&&r)return{...e};const i=Object.create(n);return Object.assign(i,e)}}function ni(e,t=!1){return qr(e)||Xe(e)||!Pe(e)||(Lr(e)>1&&(e.set=e.add=e.clear=e.delete=Hl),Object.freeze(e),t&&Object.entries(e).forEach(([r,n])=>ni(n,!0))),e}function Hl(){te(2)}function qr(e){return Object.isFrozen(e)}var Yl={};function Je(e){const t=Yl[e];return t||te(0,e),t}var qt;function Ms(){return qt}function Gl(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function fo(e,t){t&&(Je("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function An(e){Tn(e),e.drafts_.forEach(Kl),e.drafts_=null}function Tn(e){e===qt&&(qt=e.parent_)}function ho(e){return qt=Gl(qt,e)}function Kl(e){const t=e[se];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function po(e,t){t.unfinalizedDrafts_=t.drafts_.length;const r=t.drafts_[0];return e!==void 0&&e!==r?(r[se].modified_&&(An(t),te(4)),Pe(e)&&(e=kr(t,e),t.parent_||Or(t,e)),t.patches_&&Je("Patches").generateReplacementPatches_(r[se].base_,e,t.patches_,t.inversePatches_)):e=kr(t,r,[]),An(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==js?e:void 0}function kr(e,t,r){if(qr(t))return t;const n=t[se];if(!n)return xr(t,(i,o)=>mo(e,n,t,i,o,r)),t;if(n.scope_!==e)return t;if(!n.modified_)return Or(e,n.base_,!0),n.base_;if(!n.finalized_){n.finalized_=!0,n.scope_.unfinalizedDrafts_--;const i=n.copy_;let o=i,s=!1;n.type_===3&&(o=new Set(i),i.clear(),s=!0),xr(o,(a,u)=>mo(e,n,i,a,u,r,s)),Or(e,i,!1),r&&e.patches_&&Je("Patches").generatePatches_(n,r,e.patches_,e.inversePatches_)}return n.copy_}function mo(e,t,r,n,i,o,s){if(process.env.NODE_ENV!=="production"&&i===r&&te(5),Xe(i)){const a=o&&t&&t.type_!==3&&!Cn(t.assigned_,n)?o.concat(n):void 0,u=kr(e,i,a);if($s(r,n,u),Xe(u))e.canAutoFreeze_=!1;else return}else s&&r.add(i);if(Pe(i)&&!qr(i)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;kr(e,i),(!t||!t.scope_.parent_)&&typeof n!="symbol"&&Object.prototype.propertyIsEnumerable.call(r,n)&&Or(e,i)}}function Or(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&ni(t,r)}function Ql(e,t){const r=Array.isArray(e),n={type_:r?1:0,scope_:t?t.scope_:Ms(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=n,o=ii;r&&(i=[n],o=Wt);const{revoke:s,proxy:a}=Proxy.revocable(i,o);return n.draft_=a,n.revoke_=s,a}var ii={get(e,t){if(t===se)return e;const r=Le(e);if(!Cn(r,t))return Xl(e,r,t);const n=r[t];return e.finalized_||!Pe(n)?n:n===cn(e.base_,t)?(un(e),e.copy_[t]=Dn(n,e)):n},has(e,t){return t in Le(e)},ownKeys(e){return Reflect.ownKeys(Le(e))},set(e,t,r){const n=zs(Le(e),t);if(n!=null&&n.set)return n.set.call(e.draft_,r),!0;if(!e.modified_){const i=cn(Le(e),t),o=i==null?void 0:i[se];if(o&&o.base_===r)return e.copy_[t]=r,e.assigned_[t]=!1,!0;if(Wl(r,i)&&(r!==void 0||Cn(e.base_,t)))return!0;un(e),In(e)}return e.copy_[t]===r&&(r!==void 0||t in e.copy_)||Number.isNaN(r)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=r,e.assigned_[t]=!0),!0},deleteProperty(e,t){return cn(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,un(e),In(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const r=Le(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty(){te(11)},getPrototypeOf(e){return mt(e.base_)},setPrototypeOf(){te(12)}},Wt={};xr(ii,(e,t)=>{Wt[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});Wt.deleteProperty=function(e,t){return process.env.NODE_ENV!=="production"&&isNaN(parseInt(t))&&te(13),Wt.set.call(this,e,t,void 0)};Wt.set=function(e,t,r){return process.env.NODE_ENV!=="production"&&t!=="length"&&isNaN(parseInt(t))&&te(14),ii.set.call(this,e[0],t,r,e[0])};function cn(e,t){const r=e[se];return(r?Le(r):e)[t]}function Xl(e,t,r){var i;const n=zs(t,r);return n?"value"in n?n.value:(i=n.get)==null?void 0:i.call(e.draft_):void 0}function zs(e,t){if(!(t in e))return;let r=mt(e);for(;r;){const n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=mt(r)}}function In(e){e.modified_||(e.modified_=!0,e.parent_&&In(e.parent_))}function un(e){e.copy_||(e.copy_=Rn(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var Jl=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,r,n)=>{if(typeof t=="function"&&typeof r!="function"){const o=r;r=t;const s=this;return function(u=o,...l){return s.produce(u,f=>r.call(this,f,...l))}}typeof r!="function"&&te(6),n!==void 0&&typeof n!="function"&&te(7);let i;if(Pe(t)){const o=ho(this),s=Dn(t,void 0);let a=!0;try{i=r(s),a=!1}finally{a?An(o):Tn(o)}return fo(o,n),po(i,o)}else if(!t||typeof t!="object"){if(i=r(t),i===void 0&&(i=t),i===js&&(i=void 0),this.autoFreeze_&&ni(i,!0),n){const o=[],s=[];Je("Patches").generateReplacementPatches_(t,i,o,s),n(o,s)}return i}else te(1,t)},this.produceWithPatches=(t,r)=>{if(typeof t=="function")return(s,...a)=>this.produceWithPatches(s,u=>t(u,...a));let n,i;return[this.produce(t,r,(s,a)=>{n=s,i=a}),n,i]},typeof(e==null?void 0:e.autoFreeze)=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof(e==null?void 0:e.useStrictShallowCopy)=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){Pe(e)||te(8),Xe(e)&&(e=Zl(e));const t=ho(this),r=Dn(e,void 0);return r[se].isManual_=!0,Tn(t),r}finishDraft(e,t){const r=e&&e[se];(!r||!r.isManual_)&&te(9);const{scope_:n}=r;return fo(n,t),po(void 0,n)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let r;for(r=t.length-1;r>=0;r--){const i=t[r];if(i.path.length===0&&i.op==="replace"){e=i.value;break}}r>-1&&(t=t.slice(r+1));const n=Je("Patches").applyPatches_;return Xe(e)?n(e,t):this.produce(e,i=>n(i,t))}};function Dn(e,t){const r=Br(e)?Je("MapSet").proxyMap_(e,t):Ur(e)?Je("MapSet").proxySet_(e,t):Ql(e,t);return(t?t.scope_:Ms()).drafts_.push(r),r}function Zl(e){return Xe(e)||te(10,e),Fs(e)}function Fs(e){if(!Pe(e)||qr(e))return e;const t=e[se];let r;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=Rn(e,t.scope_.immer_.useStrictShallowCopy_)}else r=Rn(e,!0);return xr(r,(n,i)=>{$s(r,n,Fs(i))}),t&&(t.finalized_=!1),r}var ae=new Jl,Ls=ae.produce;ae.produceWithPatches.bind(ae);ae.setAutoFreeze.bind(ae);ae.setUseStrictShallowCopy.bind(ae);ae.applyPatches.bind(ae);ae.createDraft.bind(ae);ae.finishDraft.bind(ae);function Bs(e){return({dispatch:r,getState:n})=>i=>o=>typeof o=="function"?o(r,n,e):i(o)}var ef=Bs(),tf=Bs,rf=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Sr:Sr.apply(null,arguments)},nf=e=>e&&typeof e.match=="function";function yo(e,t){function r(...n){if(t){let i=t(...n);if(!i)throw new Error(process.env.NODE_ENV==="production"?B(0):"prepareAction did not return an object");return{type:e,payload:i.payload,..."meta"in i&&{meta:i.meta},..."error"in i&&{error:i.error}}}return{type:e,payload:n[0]}}return r.toString=()=>`${e}`,r.type=e,r.match=n=>Ds(n)&&n.type===e,r}function of(e){return typeof e=="function"&&"type"in e&&nf(e)}function sf(e){const t=e?`${e}`.split("/"):[],r=t[t.length-1]||"actionCreator";return`Detected an action creator with type "${e||"unknown"}" being dispatched.
270
270
  Make sure you're calling the action creator before dispatching, i.e. \`dispatch(${r}())\` instead of \`dispatch(${r})\`. This is necessary even if the action has no payload.`}function af(e={}){if(process.env.NODE_ENV==="production")return()=>r=>n=>r(n);const{isActionCreator:t=of}=e;return()=>r=>n=>(t(n)&&console.warn(sf(n.type)),r(n))}function Us(e,t){let r=0;return{measureTime(n){const i=Date.now();try{return n()}finally{const o=Date.now();r+=o-i}},warnIfExceeded(){r>e&&console.warn(`${t} took ${r}ms, which is more than the warning threshold of ${e}ms.
271
271
  If your state or actions are very large, you may want to disable the middleware as it might cause too much of a slowdown in development mode. See https://redux-toolkit.js.org/api/getDefaultMiddleware for instructions.
272
272
  It is disabled in production builds, so you don't need to worry about that.`)}}}var qs=class Ct extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,Ct.prototype)}static get[Symbol.species](){return Ct}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new Ct(...t[0].concat(this)):new Ct(...t.concat(this))}};function go(e){return Pe(e)?Ls(e,()=>{}):e}function vo(e,t,r){return e.has(t)?e.get(t):e.set(t,r(t)).get(t)}function cf(e){return typeof e!="object"||e==null||Object.isFrozen(e)}function uf(e,t,r){const n=Ws(e,t,r);return{detectMutations(){return Hs(e,t,n,r)}}}function Ws(e,t=[],r,n="",i=new Set){const o={value:r};if(!e(r)&&!i.has(r)){i.add(r),o.children={};for(const s in r){const a=n?n+"."+s:s;t.length&&t.indexOf(a)!==-1||(o.children[s]=Ws(e,t,r[s],a))}}return o}function Hs(e,t=[],r,n,i=!1,o=""){const s=r?r.value:void 0,a=s===n;if(i&&!a&&!Number.isNaN(n))return{wasMutated:!0,path:o};if(e(s)||e(n))return{wasMutated:!1};const u={};for(let f in r.children)u[f]=!0;for(let f in n)u[f]=!0;const l=t.length>0;for(let f in u){const d=o?o+"."+f:f;if(l&&t.some(v=>v instanceof RegExp?v.test(d):d===v))continue;const h=Hs(e,t,r.children[f],n[f],a,d);if(h.wasMutated)return h}return{wasMutated:!1}}function lf(e={}){if(process.env.NODE_ENV==="production")return()=>t=>r=>t(r);{let t=function(a,u,l,f){return JSON.stringify(a,r(u,f),l)},r=function(a,u){let l=[],f=[];return u||(u=function(d,h){return l[0]===h?"[Circular ~]":"[Circular ~."+f.slice(0,l.indexOf(h)).join(".")+"]"}),function(d,h){if(l.length>0){var p=l.indexOf(this);~p?l.splice(p+1):l.push(this),~p?f.splice(p,1/0,d):f.push(d),~l.indexOf(h)&&(h=u.call(this,d,h))}else l.push(h);return a==null?h:a.call(this,d,h)}},{isImmutable:n=cf,ignoredPaths:i,warnAfter:o=32}=e;const s=uf.bind(null,n,i);return({getState:a})=>{let u=a(),l=s(u),f;return d=>h=>{const p=Us(o,"ImmutableStateInvariantMiddleware");p.measureTime(()=>{if(u=a(),f=l.detectMutations(),l=s(u),f.wasMutated)throw new Error(process.env.NODE_ENV==="production"?B(19):`A state mutation was detected between dispatches, in the path '${f.path||""}'. This may cause incorrect behavior. (https://redux.js.org/style-guide/style-guide#do-not-mutate-state)`)});const v=d(h);return p.measureTime(()=>{if(u=a(),f=l.detectMutations(),l=s(u),f.wasMutated)throw new Error(process.env.NODE_ENV==="production"?B(20):`A state mutation was detected inside a dispatch, in the path: ${f.path||""}. Take a look at the reducer(s) handling the action ${t(h)}. (https://redux.js.org/style-guide/style-guide#do-not-mutate-state)`)}),p.warnIfExceeded(),v}}}}function Ys(e){const t=typeof e;return e==null||t==="string"||t==="boolean"||t==="number"||Array.isArray(e)||Kt(e)}function jn(e,t="",r=Ys,n,i=[],o){let s;if(!r(e))return{keyPath:t||"<root>",value:e};if(typeof e!="object"||e===null||o!=null&&o.has(e))return!1;const a=n!=null?n(e):Object.entries(e),u=i.length>0;for(const[l,f]of a){const d=t?t+"."+l:l;if(!(u&&i.some(p=>p instanceof RegExp?p.test(d):d===p))){if(!r(f))return{keyPath:d,value:f};if(typeof f=="object"&&(s=jn(f,d,r,n,i,o),s))return s}}return o&&Gs(e)&&o.add(e),!1}function Gs(e){if(!Object.isFrozen(e))return!1;for(const t of Object.values(e))if(!(typeof t!="object"||t===null)&&!Gs(t))return!1;return!0}function ff(e={}){if(process.env.NODE_ENV==="production")return()=>t=>r=>t(r);{const{isSerializable:t=Ys,getEntries:r,ignoredActions:n=[],ignoredActionPaths:i=["meta.arg","meta.baseQueryMeta"],ignoredPaths:o=[],warnAfter:s=32,ignoreState:a=!1,ignoreActions:u=!1,disableCache:l=!1}=e,f=!l&&WeakSet?new WeakSet:void 0;return d=>h=>p=>{if(!Ds(p))return h(p);const v=h(p),E=Us(s,"SerializableStateInvariantMiddleware");return!u&&!(n.length&&n.indexOf(p.type)!==-1)&&E.measureTime(()=>{const w=jn(p,"",t,r,i,f);if(w){const{keyPath:y,value:b}=w;console.error(`A non-serializable value was detected in an action, in the path: \`${y}\`. Value:`,b,`
package/dist/index.es.js CHANGED
@@ -4330,7 +4330,7 @@ const Ff = U.ul`
4330
4330
  display: flex;
4331
4331
  flex-direction: column;
4332
4332
  justify-content: center;
4333
- `, Nl = U.p`
4333
+ `, Nl = U.span`
4334
4334
  font-size: 1rem;
4335
4335
  `;
4336
4336
  function Cl(e) {
@@ -4432,37 +4432,39 @@ const Tl = U.input`
4432
4432
  textContent: r,
4433
4433
  characterPreference: n,
4434
4434
  animate: i = !0,
4435
- actionIcon: o = "chevron",
4436
- onClick: s,
4437
- styles: a,
4438
- switchChecked: u,
4439
- onSwitchChange: l
4435
+ maxDelay: o,
4436
+ actionIcon: s = "chevron",
4437
+ onClick: a,
4438
+ styles: u,
4439
+ switchChecked: l,
4440
+ onSwitchChange: f
4440
4441
  }) => {
4441
- const f = $l[e], [d, h] = Gt(null), p = (E) => {
4442
- const w = E.currentTarget.getBoundingClientRect(), y = E.clientX - w.left, b = E.clientY - w.top;
4443
- h({ x: y, y: b, key: Date.now() }), o === "switch" && l ? l(!u) : s && s();
4444
- }, v = () => o === "switch" ? /* @__PURE__ */ D.jsx(
4442
+ const d = $l[e], [h, p] = Gt(null), v = (w) => {
4443
+ const y = w.currentTarget.getBoundingClientRect(), b = w.clientX - y.left, m = w.clientY - y.top;
4444
+ p({ x: b, y: m, key: Date.now() }), s === "switch" && f ? f(!l) : a && a();
4445
+ }, E = () => s === "switch" ? /* @__PURE__ */ D.jsx(
4445
4446
  Vl,
4446
4447
  {
4447
- checked: u,
4448
- onChange: l
4448
+ checked: l,
4449
+ onChange: f
4449
4450
  }
4450
4451
  ) : /* @__PURE__ */ D.jsx(Rl, {});
4451
- return /* @__PURE__ */ D.jsxs(kl, { onClick: p, style: a, children: [
4452
- d && /* @__PURE__ */ D.jsx(xl, { $x: d.x, $y: d.y }, d.key),
4452
+ return /* @__PURE__ */ D.jsxs(kl, { onClick: v, style: u, children: [
4453
+ h && /* @__PURE__ */ D.jsx(xl, { $x: h.x, $y: h.y }, h.key),
4453
4454
  /* @__PURE__ */ D.jsxs(Ol, { children: [
4454
4455
  /* @__PURE__ */ D.jsxs(Pl, { children: [
4455
- /* @__PURE__ */ D.jsx(ho, { children: /* @__PURE__ */ D.jsx(f, { size: "1rem" }) }),
4456
+ /* @__PURE__ */ D.jsx(ho, { children: /* @__PURE__ */ D.jsx(d, { size: "1rem" }) }),
4456
4457
  /* @__PURE__ */ D.jsx(Nl, { children: r ? /* @__PURE__ */ D.jsx(
4457
4458
  as,
4458
4459
  {
4459
4460
  content: r,
4460
4461
  characterPreference: n,
4461
- animate: i
4462
+ animate: i,
4463
+ maxDelay: o
4462
4464
  }
4463
4465
  ) : t })
4464
4466
  ] }),
4465
- /* @__PURE__ */ D.jsx(ho, { children: v() })
4467
+ /* @__PURE__ */ D.jsx(ho, { children: E() })
4466
4468
  ] })
4467
4469
  ] });
4468
4470
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ymy-components",
3
3
  "private": false,
4
- "version": "0.0.44",
4
+ "version": "0.0.46",
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs.js",
7
7
  "module": "dist/index.es.js",