@e1011/es-kit 1.1.66 → 1.1.70

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("../../../../../_virtual/_rollupPluginBabelHelpers.js"),r=require("../../helpers/other.js");exports.createStore=(t,n,o)=>{let s=t;const l=new Set,c=()=>s,u=function(){var r=e.asyncToGenerator((function*(e){s=e;for(const e of l){const r=e?.selector,t=r?r(s):s;void 0!==e.previousValue&&e.previousValue===t||(e.previousValue=t,yield e(t))}return s}));return function(e){return r.apply(this,arguments)}}(),i={getState:c,setState:u,subscribe:(e,r)=>{if(r&&e.selector&&e.selector!==r)throw new Error("Error, mismatch selector, listener.selector !== selector.");return r&&!e.selector&&(e.selector=r),e.selector&&(e.previousValue=e.selector(c())),l.add(e),()=>l.delete(e)},unsubscribe:e=>{l.delete(e)}},a=n?Object.entries(n)?.reduce(((t,n)=>{let[s,l]=n;return t[s]=e.asyncToGenerator((function*(){const e=r.isFunctionAsync(l);e&&u({...c(),[`${s}Error`]:null,[`${s}Pending`]:!0});try{for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];const r=yield l(c,u,...n);return o&&u(o(c(),s,...n)),e&&u({...c(),[`${s}Pending`]:!1}),r}catch(r){throw e&&u({...c(),[`${s}Pending`]:!1,[`${s}Error`]:r}),r}})),t}),{}):null,d={...i,...a?{actions:{...a}}:{}};return d};
1
+ "use strict";var e=require("../../../../../_virtual/_rollupPluginBabelHelpers.js"),r=require("../../helpers/other.js");let t=!0;exports.canSetStateMerge=e=>{t=!!e},exports.createStore=(n,o,s)=>{let l=n;const c=new Set,u=()=>l,i=function(){var r=e.asyncToGenerator((function*(e){l=t?{...u(),...e}:e;for(const e of c){const r=e?.selector,t=r?r(l):l;void 0!==e.previousValue&&e.previousValue===t||(e.previousValue=t,yield e(t))}return l}));return function(e){return r.apply(this,arguments)}}(),a={getState:u,setState:i,subscribe:(e,r)=>{if(r&&e.selector&&e.selector!==r)throw new Error("Error, mismatch selector, listener.selector !== selector.");return r&&!e.selector&&(e.selector=r),e.selector&&(e.previousValue=e.selector(u())),c.add(e),()=>c.delete(e)},unsubscribe:e=>{c.delete(e)}},p=o?Object.entries(o)?.reduce(((t,n)=>{let[o,l]=n;return t[o]=e.asyncToGenerator((function*(){const e=r.isFunctionAsync(l);e&&i({...u(),[`${o}Error`]:null,[`${o}Pending`]:!0});try{for(var t=arguments.length,n=new Array(t),c=0;c<t;c++)n[c]=arguments[c];const r=yield l(u,i,...n);return s&&i(s(u(),o,...n)),e&&i({...u(),[`${o}Pending`]:!1}),r}catch(r){throw e&&i({...u(),[`${o}Pending`]:!1,[`${o}Error`]:r}),r}})),t}),{}):null,d={...a,...p?{actions:{...p}}:{}};return d},exports.getSetStateMerge=()=>t;
2
2
  //# sourceMappingURL=store.vanillajs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"store.vanillajs.js","sources":["../../../../../../../../src/core/utils/appState/store/store.vanillajs.ts"],"sourcesContent":["\n// TinyStore, inspired by https://github.com/jherr/syncexternalstore/blob/main/csr/src/store.js\n\nimport { isFunctionAsync } from '../../helpers'\n\n/**\n * Represents the callback function for a store listener.\n */\nexport type ListenerCallBack<T> = (state: Partial<T>) => void\n\n/**\n * Represents a selector function that transforms the store state.\n */\n// export type Selector<T> = (state: Partial<T>) => Partial<T>;\nexport type SelectedValueType<T> = Partial<T> | Partial<keyof T>\n| string | number | boolean | undefined | string[] | number[] | boolean[] | undefined[];\nexport type Selector<T> = (state: Partial<T>) => SelectedValueType<T>;\n\n\n/**\n * Represents a listener for the store.\n */\nexport type Listener<T> = {\n selector?: Selector<T>\n previousValue?: SelectedValueType<T>\n} & ListenerCallBack<T>\n\n/**\n * Represents a store.\n */\nexport type Store<T> = {\n /**\n * Get the current state of the store.\n * @returns The current state of the store.\n */\n getState: () => Partial<T>\n /**\n * Set the state of the store.\n * @param state - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n setState: (state: Partial<T>) => Promise<Partial<T>>\n /**\n * Subscribe a listener to the store.\n * @param listener - The listener function to be subscribed.\n * @param selector - Optional selector function to transform the store state.\n * @returns A function to unsubscribe the listener.\n */\n subscribe: (listener: Listener<T>, selector?: Selector<T>) => () => void\n /**\n * Unubscribe a listener from the store.\n * @param listener - The listener function to be unsubscribed.\n */\n unsubscribe: (listener: Listener<T>) => void\n}\n// & { actions?: { [actionName: string]: ActionHandlerCaller } }\n\n// TODO infer actionNames from createStore arguments\n/**\n * Represents a store with additional actions.\n */\nexport type StoreWithActions<T> = Store<T> & { actions: { [actionName: string]: ActionHandlerCaller<T> } }\n\n\n\n\n/**\n * Represents an action handler function.\n */\nexport type ActionHandler<T> = (\n getState: Store<T>['getState'], // Function to get the current state of the store\n setState: Store<T>['setState'], // Function to set the state of the store\n ...rest: unknown[]\n) => void | Partial<T> | Promise<void | Partial<T>>\n\n/**\n * Represents an reducer function.\n */\nexport type Reducer<T> = (\n state: Partial<T>,\n action: string,\n ...rest: unknown[]\n) => Partial<T>\n\n\n/**\n * Represents a function that calls an action handler.\n */\nexport type ActionHandlerCaller<T> = (...args: unknown[]) => void | Partial<T> | Promise<void | Partial<T>>\n\n\ntype Actions<T> = { [key: string]: ActionHandler<T>}\n/**\n * Creates a new store.\n * @param initialState - The initial state of the store.\n * @param actions - Optional actions for the store.\n * @returns The created store.\n */\nexport const createStore = <T>(\n initialState: Partial<T>,\n actions?: Actions<T>,\n reducer?: Reducer<T>,\n): Store<T> | StoreWithActions<T> => {\n let currentState: Partial<T> = initialState\n const listeners = new Set<Listener<T>>()\n\n /**\n * Gets the current state of the store.\n * @returns The current state of the store.\n */\n const getState = (): Partial<T> => currentState\n\n // TODO debounce, batch? what is the meaningful time between setState ofr UI to be rendered and registerd by User?\n /**\n * Sets the state of the store.\n * @param newState - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n const setState = async (newState: Partial<T>): Promise<Partial<T>> => {\n currentState = newState\n\n // eslint-disable-next-line no-restricted-syntax\n for (const listener of listeners) {\n // has Listener selector?\n const selector: Selector<T> | undefined = listener?.selector\n\n // TODO compare selected value to the previous values of that listener/selector pair\n // if listener.previousValue === selector(currentState) no call\n // else listener.previousValue = selector(currentState) and call\n // l1 cache, weak references?\n const newValue: SelectedValueType<T> = selector ? selector(currentState) : currentState\n\n // TODO plugin equality\n if (listener.previousValue === undefined || listener.previousValue !== newValue) {\n listener.previousValue = newValue\n // eslint-disable-next-line no-await-in-loop\n await listener(newValue as Partial<T>)\n }\n }\n return currentState\n }\n\n /**\n * Represents the basic API of the store.\n */\n const storeBaseicApi: Store<T> = {\n /**\n * Get the current state of the store.\n * @returns The current state of the store.\n */\n getState,\n /**\n * Set the state of the store.\n * @param state - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n setState,\n /**\n * Subscribe a listener to the store.\n * @param listener - The listener function to be subscribed.\n * @returns A function to unsubscribe the listener.\n */\n subscribe: (listener: Listener<T>, selector?: Selector<T>) => {\n if (selector && listener.selector && listener.selector !== selector) {\n throw new Error('Error, mismatch selector, listener.selector !== selector.')\n }\n if (selector && !listener.selector) {\n // eslint-disable-next-line no-param-reassign\n listener.selector = selector\n }\n\n if (listener.selector) {\n // setting the previousValue for the next cache/equality check\n // eslint-disable-next-line no-param-reassign\n listener.previousValue = listener.selector(getState())\n }\n\n listeners.add(listener)\n return () => listeners.delete(listener)\n },\n /**\n * Unsubscribe a listener from the store.\n * @param listener - The listener function to be unsubscribed.\n */\n unsubscribe: (listener: Listener<T>) => {\n listeners.delete(listener)\n },\n }\n\n /**\n * Resolves the actions and creates action handlers.\n */\n const resolvedActions: Actions<T> | null | undefined\n = actions ? Object.entries(actions)?.reduce(\n (\n aggregator: Record<string, ActionHandlerCaller<T>>,\n [actionName, actionHandler]: [string, ActionHandler<T>],\n ) => {\n // eslint-disable-next-line no-param-reassign\n aggregator[actionName] = async(...rest: unknown[]): Promise<void | Partial<T>> => {\n // TODO try to not call subscriber too many times becuase of Error and Pending values\n const isAsync = isFunctionAsync(actionHandler as () => unknown)\n\n if (isAsync) {\n setState({\n ...getState(),\n [`${actionName}Error`]: null,\n [`${actionName}Pending`]: true,\n })\n }\n\n try {\n const resultOfAction = await actionHandler(getState, setState, ...rest)\n\n // TODO try to mutate state only once with the results, that means pass custom setState to action,\n // so that it would matk pending and error already inside action\n if (reducer) {\n setState(reducer(getState(), actionName, ...rest))\n }\n\n if (isAsync) {\n setState({ ...getState(), [`${actionName}Pending`]: false })\n }\n\n return resultOfAction\n } catch (error) {\n if (isAsync) {\n setState({\n ...getState(),\n [`${actionName}Pending`]: false,\n [`${actionName}Error`]: error,\n })\n }\n throw error\n }\n }\n\n return aggregator\n },\n {},\n ) : null\n\n /**\n * Represents the store combined with actions.\n */\n const storeCombinedWithActions = {\n ...storeBaseicApi,\n ...(resolvedActions ? { actions: { ...resolvedActions } } : {}),\n }\n\n return resolvedActions\n ? storeCombinedWithActions as StoreWithActions<T>\n // ? storeCombinedWithActions as StoreWithActions<T> & ActionsStateReturnType<A>\n : storeCombinedWithActions as Store<T>\n}\n"],"names":["createStore","initialState","actions","reducer","currentState","listeners","Set","getState","setState","_ref","_asyncToGenerator","newState","listener","selector","newValue","undefined","previousValue","_x","apply","this","arguments","storeBaseicApi","subscribe","Error","add","delete","unsubscribe","resolvedActions","Object","entries","reduce","aggregator","_ref2","actionName","actionHandler","isAsync","isFunctionAsync","_len","length","rest","Array","_key","resultOfAction","error","storeCombinedWithActions"],"mappings":"2IAkG2BA,CACzBC,EACAC,EACAC,KAEA,IAAIC,EAA2BH,EAC/B,MAAMI,EAAY,IAAIC,IAMhBC,EAAWA,IAAkBH,EAQ7BI,EAAQ,WAAA,IAAAC,EAAAC,oBAAG,UAAOC,GACtBP,EAAeO,EAGf,IAAK,MAAMC,KAAYP,EAAW,CAEhC,MAAMQ,EAAoCD,GAAUC,SAM9CC,EAAiCD,EAAWA,EAAST,GAAgBA,OAG5CW,IAA3BH,EAASI,eAA+BJ,EAASI,gBAAkBF,IACrEF,EAASI,cAAgBF,QAEnBF,EAASE,GAEnB,CACA,OAAOV,KACR,OAtBKI,SAAQS,GAAA,OAAAR,EAAAS,MAAAC,KAAAC,UAAA,EAAA,GA2BRC,EAA2B,CAK/Bd,WAMAC,WAMAc,UAAWA,CAACV,EAAuBC,KACjC,GAAIA,GAAYD,EAASC,UAAYD,EAASC,WAAaA,EACzD,MAAM,IAAIU,MAAM,6DAclB,OAZIV,IAAaD,EAASC,WAExBD,EAASC,SAAWA,GAGlBD,EAASC,WAGXD,EAASI,cAAgBJ,EAASC,SAASN,MAG7CF,EAAUmB,IAAIZ,GACP,IAAMP,EAAUoB,OAAOb,EAAS,EAMzCc,YAAcd,IACZP,EAAUoB,OAAOb,EAAS,GAOxBe,EACFzB,EAAU0B,OAAOC,QAAQ3B,IAAU4B,QACnC,CACEC,EAAkDC,KAE/C,IADFC,EAAYC,GAA0CF,EAyCvD,OAtCAD,EAAWE,GAAWvB,EAAAA,kBAAG,YAEvB,MAAMyB,EAAUC,kBAAgBF,GAE5BC,GACF3B,EAAS,IACJD,IACH,CAAC,GAAG0B,UAAoB,KACxB,CAAC,GAAGA,aAAsB,IAI9B,IAAI,IAAA,IAAAI,EAAAjB,UAAAkB,OAZ4BC,EAAIC,IAAAA,MAAAH,GAAAI,EAAA,EAAAA,EAAAJ,EAAAI,IAAJF,EAAIE,GAAArB,UAAAqB,GAalC,MAAMC,QAAuBR,EAAc3B,EAAUC,KAAa+B,GAYlE,OARIpC,GACFK,EAASL,EAAQI,IAAY0B,KAAeM,IAG1CJ,GACF3B,EAAS,IAAKD,IAAY,CAAC,GAAG0B,aAAsB,IAG/CS,CACR,CAAC,MAAOC,GAQP,MAPIR,GACF3B,EAAS,IACJD,IACH,CAAC,GAAG0B,aAAsB,EAC1B,CAAC,GAAGA,UAAoBU,IAGtBA,CACR,KAGKZ,CAAU,GAEnB,CAAA,GACE,KAKAa,EAA2B,IAC5BvB,KACCM,EAAkB,CAAEzB,QAAS,IAAKyB,IAAsB,IAG9D,OACIiB,CAEoC"}
1
+ {"version":3,"file":"store.vanillajs.js","sources":["../../../../../../../../src/core/utils/appState/store/store.vanillajs.ts"],"sourcesContent":["\n// TinyStore, inspired by https://github.com/jherr/syncexternalstore/blob/main/csr/src/store.js\n\nimport { isFunctionAsync } from '../../helpers'\n\n\nlet SET_STATE_MERGE: boolean = true\n\n\nexport const canSetStateMerge = (value: boolean): void => {\n SET_STATE_MERGE = !!value\n}\n\nexport const getSetStateMerge = (): boolean => SET_STATE_MERGE\n\n/**\n * Represents the callback function for a store listener.\n */\nexport type ListenerCallBack<T> = (state: Partial<T>) => void\n\n/**\n * Represents a selector function that transforms the store state.\n */\n// export type Selector<T> = (state: Partial<T>) => Partial<T>;\nexport type SelectedValueType<T> = Partial<T> | Partial<keyof T>\n| string | number | boolean | undefined | string[] | number[] | boolean[] | undefined[];\nexport type Selector<T> = (state: Partial<T>) => SelectedValueType<T>;\n\n\n/**\n * Represents a listener for the store.\n */\nexport type Listener<T> = {\n selector?: Selector<T>\n previousValue?: SelectedValueType<T>\n} & ListenerCallBack<T>\n\n/**\n * Represents a store.\n */\nexport type Store<T> = {\n /**\n * Get the current state of the store.\n * @returns The current state of the store.\n */\n getState: () => Partial<T>\n /**\n * Set the state of the store.\n * @param state - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n setState: (state: Partial<T>) => Promise<Partial<T>>\n /**\n * Subscribe a listener to the store.\n * @param listener - The listener function to be subscribed.\n * @param selector - Optional selector function to transform the store state.\n * @returns A function to unsubscribe the listener.\n */\n subscribe: (listener: Listener<T>, selector?: Selector<T>) => () => void\n /**\n * Unubscribe a listener from the store.\n * @param listener - The listener function to be unsubscribed.\n */\n unsubscribe: (listener: Listener<T>) => void\n}\n// & { actions?: { [actionName: string]: ActionHandlerCaller } }\n\n// TODO infer actionNames from createStore arguments\n/**\n * Represents a store with additional actions.\n */\nexport type StoreWithActions<T> = Store<T> & { actions: { [actionName: string]: ActionHandlerCaller<T> } }\n\n\n\n\n/**\n * Represents an action handler function.\n */\nexport type ActionHandler<T> = (\n getState: Store<T>['getState'], // Function to get the current state of the store\n setState: Store<T>['setState'], // Function to set the state of the store\n ...rest: unknown[]\n) => void | Partial<T> | Promise<void | Partial<T>>\n\n/**\n * Represents an reducer function.\n */\nexport type Reducer<T> = (\n state: Partial<T>,\n action: string,\n ...rest: unknown[]\n) => Partial<T>\n\n\n/**\n * Represents a function that calls an action handler.\n */\nexport type ActionHandlerCaller<T> = (...args: unknown[]) => void | Partial<T> | Promise<void | Partial<T>>\n\n\ntype Actions<T> = { [key: string]: ActionHandler<T>}\n/**\n * Creates a new store.\n * @param initialState - The initial state of the store.\n * @param actions - Optional actions for the store.\n * @returns The created store.\n */\nexport const createStore = <T>(\n initialState: Partial<T>,\n actions?: Actions<T>,\n reducer?: Reducer<T>,\n): Store<T> | StoreWithActions<T> => {\n let currentState: Partial<T> = initialState\n const listeners = new Set<Listener<T>>()\n\n /**\n * Gets the current state of the store.\n * @returns The current state of the store.\n */\n const getState = (): Partial<T> => currentState\n\n // TODO debounce, batch? what is the meaningful time between setState ofr UI to be rendered and registerd by User?\n /**\n * Sets the state of the store.\n * @param newState - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n const setState = async (newState: Partial<T>): Promise<Partial<T>> => {\n currentState = SET_STATE_MERGE ? { ...getState(), ...newState } : newState\n\n // eslint-disable-next-line no-restricted-syntax\n for (const listener of listeners) {\n // has Listener selector?\n const selector: Selector<T> | undefined = listener?.selector\n\n // TODO compare selected value to the previous values of that listener/selector pair\n // if listener.previousValue === selector(currentState) no call\n // else listener.previousValue = selector(currentState) and call\n // l1 cache, weak references?\n const newValue: SelectedValueType<T> = selector ? selector(currentState) : currentState\n\n // TODO plugin equality\n if (listener.previousValue === undefined || listener.previousValue !== newValue) {\n listener.previousValue = newValue\n // eslint-disable-next-line no-await-in-loop\n await listener(newValue as Partial<T>)\n }\n }\n return currentState\n }\n\n /**\n * Represents the basic API of the store.\n */\n const storeBaseicApi: Store<T> = {\n /**\n * Get the current state of the store.\n * @returns The current state of the store.\n */\n getState,\n /**\n * Set the state of the store.\n * @param state - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n setState,\n /**\n * Subscribe a listener to the store.\n * @param listener - The listener function to be subscribed.\n * @returns A function to unsubscribe the listener.\n */\n subscribe: (listener: Listener<T>, selector?: Selector<T>) => {\n if (selector && listener.selector && listener.selector !== selector) {\n throw new Error('Error, mismatch selector, listener.selector !== selector.')\n }\n if (selector && !listener.selector) {\n // eslint-disable-next-line no-param-reassign\n listener.selector = selector\n }\n\n if (listener.selector) {\n // setting the previousValue for the next cache/equality check\n // eslint-disable-next-line no-param-reassign\n listener.previousValue = listener.selector(getState())\n }\n\n listeners.add(listener)\n return () => listeners.delete(listener)\n },\n /**\n * Unsubscribe a listener from the store.\n * @param listener - The listener function to be unsubscribed.\n */\n unsubscribe: (listener: Listener<T>) => {\n listeners.delete(listener)\n },\n }\n\n /**\n * Resolves the actions and creates action handlers.\n */\n const resolvedActions: Actions<T> | null | undefined\n = actions ? Object.entries(actions)?.reduce(\n (\n aggregator: Record<string, ActionHandlerCaller<T>>,\n [actionName, actionHandler]: [string, ActionHandler<T>],\n ) => {\n // eslint-disable-next-line no-param-reassign\n aggregator[actionName] = async(...rest: unknown[]): Promise<void | Partial<T>> => {\n // TODO try to not call subscriber too many times becuase of Error and Pending values\n const isAsync = isFunctionAsync(actionHandler as () => unknown)\n\n if (isAsync) {\n setState({\n ...getState(),\n [`${actionName}Error`]: null,\n [`${actionName}Pending`]: true,\n })\n }\n\n try {\n const resultOfAction = await actionHandler(getState, setState, ...rest)\n\n // TODO try to mutate state only once with the results, that means pass custom setState to action,\n // so that it would matk pending and error already inside action\n if (reducer) {\n setState(reducer(getState(), actionName, ...rest))\n }\n\n if (isAsync) {\n setState({ ...getState(), [`${actionName}Pending`]: false })\n }\n\n return resultOfAction\n } catch (error) {\n if (isAsync) {\n setState({\n ...getState(),\n [`${actionName}Pending`]: false,\n [`${actionName}Error`]: error,\n })\n }\n throw error\n }\n }\n\n return aggregator\n },\n {},\n ) : null\n\n /**\n * Represents the store combined with actions.\n */\n const storeCombinedWithActions = {\n ...storeBaseicApi,\n ...(resolvedActions ? { actions: { ...resolvedActions } } : {}),\n }\n\n return resolvedActions\n ? storeCombinedWithActions as StoreWithActions<T>\n // ? storeCombinedWithActions as StoreWithActions<T> & ActionsStateReturnType<A>\n : storeCombinedWithActions as Store<T>\n}\n"],"names":["SET_STATE_MERGE","value","createStore","initialState","actions","reducer","currentState","listeners","Set","getState","setState","_ref","_asyncToGenerator","newState","listener","selector","newValue","undefined","previousValue","_x","apply","this","arguments","storeBaseicApi","subscribe","Error","add","delete","unsubscribe","resolvedActions","Object","entries","reduce","aggregator","_ref2","actionName","actionHandler","isAsync","isFunctionAsync","_len","length","rest","Array","_key","resultOfAction","error","storeCombinedWithActions","getSetStateMerge"],"mappings":"uHAMA,IAAIA,GAA2B,2BAGEC,IAC/BD,IAAoBC,CAAK,sBAkGAC,CACzBC,EACAC,EACAC,KAEA,IAAIC,EAA2BH,EAC/B,MAAMI,EAAY,IAAIC,IAMhBC,EAAWA,IAAkBH,EAQ7BI,EAAQ,WAAA,IAAAC,EAAAC,oBAAG,UAAOC,GACtBP,EAAeN,EAAkB,IAAKS,OAAeI,GAAaA,EAGlE,IAAK,MAAMC,KAAYP,EAAW,CAEhC,MAAMQ,EAAoCD,GAAUC,SAM9CC,EAAiCD,EAAWA,EAAST,GAAgBA,OAG5CW,IAA3BH,EAASI,eAA+BJ,EAASI,gBAAkBF,IACrEF,EAASI,cAAgBF,QAEnBF,EAASE,GAEnB,CACA,OAAOV,KACR,OAtBKI,SAAQS,GAAA,OAAAR,EAAAS,MAAAC,KAAAC,UAAA,EAAA,GA2BRC,EAA2B,CAK/Bd,WAMAC,WAMAc,UAAWA,CAACV,EAAuBC,KACjC,GAAIA,GAAYD,EAASC,UAAYD,EAASC,WAAaA,EACzD,MAAM,IAAIU,MAAM,6DAclB,OAZIV,IAAaD,EAASC,WAExBD,EAASC,SAAWA,GAGlBD,EAASC,WAGXD,EAASI,cAAgBJ,EAASC,SAASN,MAG7CF,EAAUmB,IAAIZ,GACP,IAAMP,EAAUoB,OAAOb,EAAS,EAMzCc,YAAcd,IACZP,EAAUoB,OAAOb,EAAS,GAOxBe,EACFzB,EAAU0B,OAAOC,QAAQ3B,IAAU4B,QACnC,CACEC,EAAkDC,KAE/C,IADFC,EAAYC,GAA0CF,EAyCvD,OAtCAD,EAAWE,GAAWvB,EAAAA,kBAAG,YAEvB,MAAMyB,EAAUC,kBAAgBF,GAE5BC,GACF3B,EAAS,IACJD,IACH,CAAC,GAAG0B,UAAoB,KACxB,CAAC,GAAGA,aAAsB,IAI9B,IAAI,IAAA,IAAAI,EAAAjB,UAAAkB,OAZ4BC,EAAIC,IAAAA,MAAAH,GAAAI,EAAA,EAAAA,EAAAJ,EAAAI,IAAJF,EAAIE,GAAArB,UAAAqB,GAalC,MAAMC,QAAuBR,EAAc3B,EAAUC,KAAa+B,GAYlE,OARIpC,GACFK,EAASL,EAAQI,IAAY0B,KAAeM,IAG1CJ,GACF3B,EAAS,IAAKD,IAAY,CAAC,GAAG0B,aAAsB,IAG/CS,CACR,CAAC,MAAOC,GAQP,MAPIR,GACF3B,EAAS,IACJD,IACH,CAAC,GAAG0B,aAAsB,EAC1B,CAAC,GAAGA,UAAoBU,IAGtBA,CACR,KAGKZ,CAAU,GAEnB,CAAA,GACE,KAKAa,EAA2B,IAC5BvB,KACCM,EAAkB,CAAEzB,QAAS,IAAKyB,IAAsB,IAG9D,OACIiB,CAEoC,2BA1PVC,IAAe/C"}
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("./core/hooks/useApi.js"),r=require("./core/hooks/useToggle.js"),t=require("./core/hooks/useToggle2.js"),o=require("./core/hooks/useOutsideClick.js"),s=require("./core/hooks/useResize.js"),i=require("./core/hooks/useClassNames.js"),a=require("./core/hooks/useParseProps.js"),n=require("./core/hooks/useThemePreference.js"),p=require("./core/hooks/useAnimation.js"),u=require("./core/hooks/useIntersectionObserver.js"),l=require("./core/hooks/useSetTimeout.js"),c=require("./core/utils/helpers/birthnumber.validator.js"),x=require("./core/utils/helpers/birthnumberCZSKvalidator.js"),m=require("./core/utils/helpers/fileValidator.js"),d=require("./core/utils/helpers/date.js"),T=require("./core/utils/helpers/deviceInfo.js"),g=require("./core/utils/helpers/emailMatcher.js"),h=require("./core/utils/helpers/file.js"),S=require("./core/utils/helpers/objectOperations.js"),j=require("./core/utils/helpers/other.js"),y=require("./core/utils/helpers/textValueOperations.js"),C=require("./core/utils/helpers/valueOperations.js"),q=require("./core/utils/helpers/cancelableDelayedFunction.js"),v=require("./core/utils/helpers/ui.js"),P=require("./core/utils/helpers/text.js"),I=require("./core/utils/keyExtractor.js"),b=require("./core/utils/date.js"),f=require("./core/utils/webComponents/webComponent.utils.js"),A=require("./core/utils/appState/store/store.vanillajs.js"),M=require("./core/utils/appState/store/store.vanillajs.templates.js"),F=require("./core/utils/appState/store/useStore.react.js"),E=require("./core/utils/appState/peregrineMQ/peregrineMQ.js"),D=require("./core/utils/appState/peregrineMQ/peregrineMQ.types.js"),L=require("./core/utils/appState/peregrineMQ/usePeregrineMQ.react.js"),z=require("./core/utils/appState/peregrineMQ/index.js"),k=require("./core/utils/appState/stateMachine/tiny-state-machine.base.js"),B=require("./core/constants/ui.constants.js"),N=require("./core/ui/utils/style.js"),O=require("./core/ui/components/container/layoutBox/LayoutBox.js"),V=require("./core/ui/components/container/layoutBox/layoutBox.types.js"),R=require("./core/ui/components/container/lazyComponent/LazyComponent.js"),H=require("./core/ui/components/container/CollapsibleContainer.js"),w=require("./core/ui/components/container/ResizableContainer.js"),Q=require("./core/ui/components/error/ErrorBoundary.js"),_=require("./core/ui/components/field/Field.js"),W=require("./core/ui/components/dividers/DividerLine.js"),J=require("./core/ui/components/icon/IconBase.js"),K=require("./core/ui/components/icon/Icon.js"),G=require("./core/ui/components/icon/IconWC.js"),U=require("./core/ui/components/atoms/button/Button.js"),X=require("./core/ui/components/atoms/text/Text.js"),Z=require("./core/ui/components/atoms/text/Headline.js"),Y=require("./core/ui/components/atoms/text/Paragraph.js"),$=require("./core/ui/components/atoms/text/Link.js"),ee=require("./core/ui/components/atoms/text/anchor-link/AnchorLink.js"),re=require("./core/ui/components/atoms/textAndContent/TextAndContent.js"),te=require("./core/ui/components/atoms/tag/Tag.js"),oe=require("./core/ui/components/atoms/tag/tag.types.js"),se=require("./core/ui/components/atoms/toggle/Toggle.js"),ie=require("./core/ui/components/molecules/layouts/FlowLayout.js"),ae=require("./core/ui/components/molecules/popover/PopoverLite.js"),ne=require("./core/ui/components/molecules/popover/Tooltip.js"),pe=require("./core/ui/components/molecules/popover/popover.types.js"),ue=require("./core/ui/components/molecules/popup/Popup.js"),le=require("./core/ui/components/molecules/popup/popup.types.js");exports.useApi=e.useApi,exports.useToggle=r.useToggle,exports.useToggle2=t.useToggle2,exports.outsideClickHandler=o.outsideClickHandler,exports.useOutsideClick=o.useOutsideClick,exports.useResize=s.useResize,exports.useClassNames=i.useClassNames,exports.useParseProps=a.useParseProps,exports.getBaseThemes=n.getBaseThemes,exports.observeThemePreference=n.observeThemePreference,exports.setThemeClassNames=n.setThemeClassNames,exports.switchColorTheme=n.switchColorTheme,exports.updateColorTheme=n.updateColorTheme,exports.useThemePreference=n.useThemePreference,exports.useAnimation=p.useAnimation,exports.useIntersectionObserver=u.useIntersectionObserver,exports.useTimeoutFn=l.useTimeoutFn,exports.isBirthNumberValid=c.isBirthNumberValid,exports.getMatch=x.getMatch,exports.isValidFormat=x.isValidFormat,exports.isValidModulo11=x.isValidModulo11,exports.parse=x.parse,exports.regex=x.regex,exports.parseCSVdata=m.parseCSVdata,exports.validateCSVFile=m.validateCSVFile,exports.validateCSVlines=m.validateCSVlines,exports.validateJSONFile=m.validateJSONFile,exports.validateLineCellTrimmed=m.validateLineCellTrimmed,exports.validateLineNumColumns=m.validateLineNumColumns,exports.validateSDFFile=m.validateSDFFile,exports.DATE_FORMAT=d.DATE_FORMAT,exports.DATE_TIME_FORMAT=d.DATE_TIME_FORMAT,exports.formatDate=d.formatDate,exports.formatDateTime=d.formatDateTime,exports.formatDateToTimestamp=d.formatDateToTimestamp,exports.getDate=d.getDate,exports.getDeviceId=T.getDeviceId,exports.emailMatch=g.emailMatch,exports.emailMatcher=g.emailMatcher,exports.regexBuilder=g.regexBuilder,exports.cleanCsvLines=h.cleanCsvLines,exports.formatFilePath=h.formatFilePath,exports.arrayToObjectTree=S.arrayToObjectTree,exports.chunkArray=S.chunkArray,exports.duplicatesInArray=S.duplicatesInArray,exports.formatJsonString=S.formatJsonString,exports.formatObj=S.formatObj,exports.formatObj2=S.formatObj2,exports.AsyncFunctionTemplate=j.AsyncFunctionTemplate,exports.debounce=j.debounce,exports.delay=j.delay,exports.isFunctionAsync=j.isFunctionAsync,exports.memoize=j.memoize,exports.memoizeComplex=j.memoizeComplex,exports.memoizer=j.memoizer,exports.nestedTernary=j.nestedTernary,exports.escapeRegExp=y.escapeRegExp,exports.fileNameExt=y.fileNameExt,exports.findStringInText=y.findStringInText,exports.normalizeString=y.normalizeString,exports.removeWhitespaces=y.removeWhitespaces,exports.sanitizeId=y.sanitizeId,exports.sanitizePathId=y.sanitizePathId,exports.toLowerCase=y.toLowerCase,exports.toUpperCase=y.toUpperCase,exports.truncateText=y.truncateText,exports.Operation=C.Operation,exports.decrementValue=C.decrementValue,exports.incerementValue=C.incerementValue,exports.numberDefined=C.numberDefined,exports.numberOperation=C.numberOperation,exports.restrictNumberInLimits=C.restrictNumberInLimits,exports.setValue=C.setValue,exports.cancelableSetInterval=q.cancelableSetInterval,exports.cancelableSetTimeout=q.cancelableSetTimeout,exports.anchorClick=v.anchorClick,exports.classNames=v.classNames,exports.generateId=v.generateId,exports.mapSerReplacer=v.mapSerReplacer,exports.noop=v.noop,exports.parseProps=v.parseProps,exports.composeId=P.composeId,exports.defaultSanitizeConfig=P.defaultSanitizeConfig,exports.sanitizeHtml=P.sanitizeHtml,exports.keyExtractor=I.keyExtractor,exports.keyExtractorFunction=I.keyExtractorFunction,exports.dateRangeFormat=b.dateRangeFormat,exports.getDateTime=b.getDateTime,exports.getTimeFromNow=b.getTimeFromNow,exports.getTimeFromNowOriginal=b.getTimeFromNowOriginal,exports.getTimeTo=b.getTimeTo,exports.ced=f.ced,exports.createResolveAttribute=f.createResolveAttribute,exports.customElementDefine=f.customElementDefine,exports.resolveAttributes=f.resolveAttributes,exports.createStore=A.createStore,exports.createDataStore=M.createDataStore,exports.useStore=F.useStore,exports.useStoreApi=F.useStoreApi,exports.PeregrineMQ=E.PeregrineMQ,exports.PeregrineMQClearError=E.PeregrineMQClearError,exports.NON_EXISTENT_CHANNEL=D.NON_EXISTENT_CHANNEL,exports.usePeregrineMQ=L.usePeregrineMQ,exports.peregrineMQInstance=z.peregrineMQInstance,exports.TinyStateMachine=k.TinyStateMachine,exports.TinyStateMachineEvent=k.TinyStateMachineEvent,exports.TinyStateMachineEventType=k.TinyStateMachineEventType,exports.TinyStateMachineState=k.TinyStateMachineState,exports.createStates=k.createStates,exports.stateIterator=k.stateIterator,exports.Alerts=B.Alerts,exports.EventName=B.EventName,exports.KeyCode=B.KeyCode,exports.calculateColors=N.calculateColors,exports.calculatePercColor=N.calculatePercColor,exports.convertHex=N.convertHex,exports.convertRGB=N.convertRGB,Object.defineProperty(exports,"defaultFontSize",{enumerable:!0,get:function(){return N.defaultFontSize}}),exports.pxToRem=N.pxToRem,exports.resolveStyleValue=N.resolveStyleValue,exports.setDefaultFontSize=N.setDefaultFontSize,exports.toHex=N.toHex,exports.LayoutBox=O.LayoutBox,exports.LayoutDirection=V.LayoutDirection,exports.LazyComponent=R.LazyComponent,exports.PendingBoundary=R.PendingBoundary,exports.createLazyModule=R.createLazyModule,exports.createLazyModuleWithStore=R.createLazyModuleWithStore,exports.wrapPromise=R.wrapPromise,exports.CollapsibleContainer=H.CollapsibleContainer,exports.ResizableContainer=w.ResizableContainer,exports.DefaultErrorComponent=Q.DefaultErrorComponent,exports.ErrorBoundary=Q.ErrorBoundary,exports.Field=_.Field,exports.Select=_.Select,exports.setIconColor=_.setIconColor,exports.setIconComponent=_.setIconComponent,exports.DividerHorizontal=W.DividerHorizontal,exports.DividerLine=W.DividerLine,exports.DividerVertical=W.DividerVertical,exports.IconBase=J.IconBase,exports.Icon=K.Icon,exports.ESIcon=G.ESIcon,exports.ESIconBase=G.ESIconBase,exports.Button=U.Button,exports.IconButton=U.IconButton,exports.keys=U.keys,exports.Text=X.Text,exports.Headline=Z.Headline,exports.HeadlineSecondary=Z.HeadlineSecondary,exports.HeadlineTertiary=Z.HeadlineTertiary,exports.Paragraph=Y.Paragraph,exports.ParagraphBold=Y.ParagraphBold,exports.ParagraphBoldSmall=Y.ParagraphBoldSmall,exports.ParagraphSmall=Y.ParagraphSmall,exports.Link=$.Link,exports.AnchorLink=ee.AnchorLink,exports.TextAndContent=re.TextAndContent,exports.TextAndIcons=re.TextAndIcons,exports.Tag=te.Tag,exports.TagVariant=oe.TagVariant,exports.Toggle=se.Toggle,exports.FlowLayout=ie.FlowLayout,exports.Popover=ae.Popover,exports.Tooltip=ne.Tooltip,exports.PopoverPlacement=pe.PopoverPlacement,exports.Popup=ue.Popup,exports.PopupAnimateVariant=le.PopupAnimateVariant;
1
+ "use strict";var e=require("./core/hooks/useApi.js"),r=require("./core/hooks/useToggle.js"),t=require("./core/hooks/useToggle2.js"),o=require("./core/hooks/useOutsideClick.js"),s=require("./core/hooks/useResize.js"),a=require("./core/hooks/useClassNames.js"),i=require("./core/hooks/useParseProps.js"),n=require("./core/hooks/useThemePreference.js"),p=require("./core/hooks/useAnimation.js"),u=require("./core/hooks/useIntersectionObserver.js"),l=require("./core/hooks/useSetTimeout.js"),c=require("./core/utils/helpers/birthnumber.validator.js"),x=require("./core/utils/helpers/birthnumberCZSKvalidator.js"),m=require("./core/utils/helpers/fileValidator.js"),d=require("./core/utils/helpers/date.js"),T=require("./core/utils/helpers/deviceInfo.js"),g=require("./core/utils/helpers/emailMatcher.js"),h=require("./core/utils/helpers/file.js"),S=require("./core/utils/helpers/objectOperations.js"),j=require("./core/utils/helpers/other.js"),y=require("./core/utils/helpers/textValueOperations.js"),C=require("./core/utils/helpers/valueOperations.js"),q=require("./core/utils/helpers/cancelableDelayedFunction.js"),v=require("./core/utils/helpers/ui.js"),P=require("./core/utils/helpers/text.js"),I=require("./core/utils/keyExtractor.js"),b=require("./core/utils/date.js"),M=require("./core/utils/webComponents/webComponent.utils.js"),f=require("./core/utils/appState/store/store.vanillajs.js"),A=require("./core/utils/appState/store/store.vanillajs.templates.js"),F=require("./core/utils/appState/store/useStore.react.js"),E=require("./core/utils/appState/peregrineMQ/peregrineMQ.js"),D=require("./core/utils/appState/peregrineMQ/peregrineMQ.types.js"),L=require("./core/utils/appState/peregrineMQ/usePeregrineMQ.react.js"),z=require("./core/utils/appState/peregrineMQ/index.js"),k=require("./core/utils/appState/stateMachine/tiny-state-machine.base.js"),B=require("./core/constants/ui.constants.js"),N=require("./core/ui/utils/style.js"),O=require("./core/ui/components/container/layoutBox/LayoutBox.js"),V=require("./core/ui/components/container/layoutBox/layoutBox.types.js"),R=require("./core/ui/components/container/lazyComponent/LazyComponent.js"),H=require("./core/ui/components/container/CollapsibleContainer.js"),w=require("./core/ui/components/container/ResizableContainer.js"),Q=require("./core/ui/components/error/ErrorBoundary.js"),_=require("./core/ui/components/field/Field.js"),W=require("./core/ui/components/dividers/DividerLine.js"),J=require("./core/ui/components/icon/IconBase.js"),K=require("./core/ui/components/icon/Icon.js"),G=require("./core/ui/components/icon/IconWC.js"),U=require("./core/ui/components/atoms/button/Button.js"),X=require("./core/ui/components/atoms/text/Text.js"),Z=require("./core/ui/components/atoms/text/Headline.js"),Y=require("./core/ui/components/atoms/text/Paragraph.js"),$=require("./core/ui/components/atoms/text/Link.js"),ee=require("./core/ui/components/atoms/text/anchor-link/AnchorLink.js"),re=require("./core/ui/components/atoms/textAndContent/TextAndContent.js"),te=require("./core/ui/components/atoms/tag/Tag.js"),oe=require("./core/ui/components/atoms/tag/tag.types.js"),se=require("./core/ui/components/atoms/toggle/Toggle.js"),ae=require("./core/ui/components/molecules/layouts/FlowLayout.js"),ie=require("./core/ui/components/molecules/popover/PopoverLite.js"),ne=require("./core/ui/components/molecules/popover/Tooltip.js"),pe=require("./core/ui/components/molecules/popover/popover.types.js"),ue=require("./core/ui/components/molecules/popup/Popup.js"),le=require("./core/ui/components/molecules/popup/popup.types.js");exports.useApi=e.useApi,exports.useToggle=r.useToggle,exports.useToggle2=t.useToggle2,exports.outsideClickHandler=o.outsideClickHandler,exports.useOutsideClick=o.useOutsideClick,exports.useResize=s.useResize,exports.useClassNames=a.useClassNames,exports.useParseProps=i.useParseProps,exports.getBaseThemes=n.getBaseThemes,exports.observeThemePreference=n.observeThemePreference,exports.setThemeClassNames=n.setThemeClassNames,exports.switchColorTheme=n.switchColorTheme,exports.updateColorTheme=n.updateColorTheme,exports.useThemePreference=n.useThemePreference,exports.useAnimation=p.useAnimation,exports.useIntersectionObserver=u.useIntersectionObserver,exports.useTimeoutFn=l.useTimeoutFn,exports.isBirthNumberValid=c.isBirthNumberValid,exports.getMatch=x.getMatch,exports.isValidFormat=x.isValidFormat,exports.isValidModulo11=x.isValidModulo11,exports.parse=x.parse,exports.regex=x.regex,exports.parseCSVdata=m.parseCSVdata,exports.validateCSVFile=m.validateCSVFile,exports.validateCSVlines=m.validateCSVlines,exports.validateJSONFile=m.validateJSONFile,exports.validateLineCellTrimmed=m.validateLineCellTrimmed,exports.validateLineNumColumns=m.validateLineNumColumns,exports.validateSDFFile=m.validateSDFFile,exports.DATE_FORMAT=d.DATE_FORMAT,exports.DATE_TIME_FORMAT=d.DATE_TIME_FORMAT,exports.formatDate=d.formatDate,exports.formatDateTime=d.formatDateTime,exports.formatDateToTimestamp=d.formatDateToTimestamp,exports.getDate=d.getDate,exports.getDeviceId=T.getDeviceId,exports.emailMatch=g.emailMatch,exports.emailMatcher=g.emailMatcher,exports.regexBuilder=g.regexBuilder,exports.cleanCsvLines=h.cleanCsvLines,exports.formatFilePath=h.formatFilePath,exports.arrayToObjectTree=S.arrayToObjectTree,exports.chunkArray=S.chunkArray,exports.duplicatesInArray=S.duplicatesInArray,exports.formatJsonString=S.formatJsonString,exports.formatObj=S.formatObj,exports.formatObj2=S.formatObj2,exports.AsyncFunctionTemplate=j.AsyncFunctionTemplate,exports.debounce=j.debounce,exports.delay=j.delay,exports.isFunctionAsync=j.isFunctionAsync,exports.memoize=j.memoize,exports.memoizeComplex=j.memoizeComplex,exports.memoizer=j.memoizer,exports.nestedTernary=j.nestedTernary,exports.escapeRegExp=y.escapeRegExp,exports.fileNameExt=y.fileNameExt,exports.findStringInText=y.findStringInText,exports.normalizeString=y.normalizeString,exports.removeWhitespaces=y.removeWhitespaces,exports.sanitizeId=y.sanitizeId,exports.sanitizePathId=y.sanitizePathId,exports.toLowerCase=y.toLowerCase,exports.toUpperCase=y.toUpperCase,exports.truncateText=y.truncateText,exports.Operation=C.Operation,exports.decrementValue=C.decrementValue,exports.incerementValue=C.incerementValue,exports.numberDefined=C.numberDefined,exports.numberOperation=C.numberOperation,exports.restrictNumberInLimits=C.restrictNumberInLimits,exports.setValue=C.setValue,exports.cancelableSetInterval=q.cancelableSetInterval,exports.cancelableSetTimeout=q.cancelableSetTimeout,exports.anchorClick=v.anchorClick,exports.classNames=v.classNames,exports.generateId=v.generateId,exports.mapSerReplacer=v.mapSerReplacer,exports.noop=v.noop,exports.parseProps=v.parseProps,exports.composeId=P.composeId,exports.defaultSanitizeConfig=P.defaultSanitizeConfig,exports.sanitizeHtml=P.sanitizeHtml,exports.keyExtractor=I.keyExtractor,exports.keyExtractorFunction=I.keyExtractorFunction,exports.dateRangeFormat=b.dateRangeFormat,exports.getDateTime=b.getDateTime,exports.getTimeFromNow=b.getTimeFromNow,exports.getTimeFromNowOriginal=b.getTimeFromNowOriginal,exports.getTimeTo=b.getTimeTo,exports.ced=M.ced,exports.createResolveAttribute=M.createResolveAttribute,exports.customElementDefine=M.customElementDefine,exports.resolveAttributes=M.resolveAttributes,exports.canSetStateMerge=f.canSetStateMerge,exports.createStore=f.createStore,exports.getSetStateMerge=f.getSetStateMerge,exports.createDataStore=A.createDataStore,exports.useStore=F.useStore,exports.useStoreApi=F.useStoreApi,exports.PeregrineMQ=E.PeregrineMQ,exports.PeregrineMQClearError=E.PeregrineMQClearError,exports.NON_EXISTENT_CHANNEL=D.NON_EXISTENT_CHANNEL,exports.usePeregrineMQ=L.usePeregrineMQ,exports.peregrineMQInstance=z.peregrineMQInstance,exports.TinyStateMachine=k.TinyStateMachine,exports.TinyStateMachineEvent=k.TinyStateMachineEvent,exports.TinyStateMachineEventType=k.TinyStateMachineEventType,exports.TinyStateMachineState=k.TinyStateMachineState,exports.createStates=k.createStates,exports.stateIterator=k.stateIterator,exports.Alerts=B.Alerts,exports.EventName=B.EventName,exports.KeyCode=B.KeyCode,exports.calculateColors=N.calculateColors,exports.calculatePercColor=N.calculatePercColor,exports.convertHex=N.convertHex,exports.convertRGB=N.convertRGB,Object.defineProperty(exports,"defaultFontSize",{enumerable:!0,get:function(){return N.defaultFontSize}}),exports.pxToRem=N.pxToRem,exports.resolveStyleValue=N.resolveStyleValue,exports.setDefaultFontSize=N.setDefaultFontSize,exports.toHex=N.toHex,exports.LayoutBox=O.LayoutBox,exports.LayoutDirection=V.LayoutDirection,exports.LazyComponent=R.LazyComponent,exports.PendingBoundary=R.PendingBoundary,exports.createLazyModule=R.createLazyModule,exports.createLazyModuleWithStore=R.createLazyModuleWithStore,exports.wrapPromise=R.wrapPromise,exports.CollapsibleContainer=H.CollapsibleContainer,exports.ResizableContainer=w.ResizableContainer,exports.DefaultErrorComponent=Q.DefaultErrorComponent,exports.ErrorBoundary=Q.ErrorBoundary,exports.Field=_.Field,exports.Select=_.Select,exports.setIconColor=_.setIconColor,exports.setIconComponent=_.setIconComponent,exports.DividerHorizontal=W.DividerHorizontal,exports.DividerLine=W.DividerLine,exports.DividerVertical=W.DividerVertical,exports.IconBase=J.IconBase,exports.Icon=K.Icon,exports.ESIcon=G.ESIcon,exports.ESIconBase=G.ESIconBase,exports.Button=U.Button,exports.IconButton=U.IconButton,exports.keys=U.keys,exports.Text=X.Text,exports.Headline=Z.Headline,exports.HeadlineSecondary=Z.HeadlineSecondary,exports.HeadlineTertiary=Z.HeadlineTertiary,exports.Paragraph=Y.Paragraph,exports.ParagraphBold=Y.ParagraphBold,exports.ParagraphBoldSmall=Y.ParagraphBoldSmall,exports.ParagraphSmall=Y.ParagraphSmall,exports.Link=$.Link,exports.AnchorLink=ee.AnchorLink,exports.TextAndContent=re.TextAndContent,exports.TextAndIcons=re.TextAndIcons,exports.Tag=te.Tag,exports.TagVariant=oe.TagVariant,exports.Toggle=se.Toggle,exports.FlowLayout=ae.FlowLayout,exports.Popover=ie.Popover,exports.Tooltip=ne.Tooltip,exports.PopoverPlacement=pe.PopoverPlacement,exports.Popup=ue.Popup,exports.PopupAnimateVariant=le.PopupAnimateVariant;
2
2
  //# sourceMappingURL=index.js.map
@@ -1,2 +1,2 @@
1
- import{asyncToGenerator as e}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import{isFunctionAsync as r}from"../../helpers/other.js";const t=(t,o,n)=>{let s=t;const l=new Set,c=()=>s,u=function(){var r=e((function*(e){s=e;for(const e of l){const r=e?.selector,t=r?r(s):s;void 0!==e.previousValue&&e.previousValue===t||(e.previousValue=t,yield e(t))}return s}));return function(e){return r.apply(this,arguments)}}(),i={getState:c,setState:u,subscribe:(e,r)=>{if(r&&e.selector&&e.selector!==r)throw new Error("Error, mismatch selector, listener.selector !== selector.");return r&&!e.selector&&(e.selector=r),e.selector&&(e.previousValue=e.selector(c())),l.add(e),()=>l.delete(e)},unsubscribe:e=>{l.delete(e)}},a=o?Object.entries(o)?.reduce(((t,o)=>{let[s,l]=o;return t[s]=e((function*(){const e=r(l);e&&u({...c(),[`${s}Error`]:null,[`${s}Pending`]:!0});try{for(var t=arguments.length,o=new Array(t),i=0;i<t;i++)o[i]=arguments[i];const r=yield l(c,u,...o);return n&&u(n(c(),s,...o)),e&&u({...c(),[`${s}Pending`]:!1}),r}catch(r){throw e&&u({...c(),[`${s}Pending`]:!1,[`${s}Error`]:r}),r}})),t}),{}):null,p={...i,...a?{actions:{...a}}:{}};return p};export{t as createStore};
1
+ import{asyncToGenerator as e}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import{isFunctionAsync as r}from"../../helpers/other.js";let t=!0;const o=e=>{t=!!e},n=()=>t,s=(o,n,s)=>{let l=o;const c=new Set,u=()=>l,i=function(){var r=e((function*(e){l=t?{...u(),...e}:e;for(const e of c){const r=e?.selector,t=r?r(l):l;void 0!==e.previousValue&&e.previousValue===t||(e.previousValue=t,yield e(t))}return l}));return function(e){return r.apply(this,arguments)}}(),a={getState:u,setState:i,subscribe:(e,r)=>{if(r&&e.selector&&e.selector!==r)throw new Error("Error, mismatch selector, listener.selector !== selector.");return r&&!e.selector&&(e.selector=r),e.selector&&(e.previousValue=e.selector(u())),c.add(e),()=>c.delete(e)},unsubscribe:e=>{c.delete(e)}},p=n?Object.entries(n)?.reduce(((t,o)=>{let[n,l]=o;return t[n]=e((function*(){const e=r(l);e&&i({...u(),[`${n}Error`]:null,[`${n}Pending`]:!0});try{for(var t=arguments.length,o=new Array(t),c=0;c<t;c++)o[c]=arguments[c];const r=yield l(u,i,...o);return s&&i(s(u(),n,...o)),e&&i({...u(),[`${n}Pending`]:!1}),r}catch(r){throw e&&i({...u(),[`${n}Pending`]:!1,[`${n}Error`]:r}),r}})),t}),{}):null,d={...a,...p?{actions:{...p}}:{}};return d};export{o as canSetStateMerge,s as createStore,n as getSetStateMerge};
2
2
  //# sourceMappingURL=store.vanillajs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"store.vanillajs.js","sources":["../../../../../../../../src/core/utils/appState/store/store.vanillajs.ts"],"sourcesContent":["\n// TinyStore, inspired by https://github.com/jherr/syncexternalstore/blob/main/csr/src/store.js\n\nimport { isFunctionAsync } from '../../helpers'\n\n/**\n * Represents the callback function for a store listener.\n */\nexport type ListenerCallBack<T> = (state: Partial<T>) => void\n\n/**\n * Represents a selector function that transforms the store state.\n */\n// export type Selector<T> = (state: Partial<T>) => Partial<T>;\nexport type SelectedValueType<T> = Partial<T> | Partial<keyof T>\n| string | number | boolean | undefined | string[] | number[] | boolean[] | undefined[];\nexport type Selector<T> = (state: Partial<T>) => SelectedValueType<T>;\n\n\n/**\n * Represents a listener for the store.\n */\nexport type Listener<T> = {\n selector?: Selector<T>\n previousValue?: SelectedValueType<T>\n} & ListenerCallBack<T>\n\n/**\n * Represents a store.\n */\nexport type Store<T> = {\n /**\n * Get the current state of the store.\n * @returns The current state of the store.\n */\n getState: () => Partial<T>\n /**\n * Set the state of the store.\n * @param state - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n setState: (state: Partial<T>) => Promise<Partial<T>>\n /**\n * Subscribe a listener to the store.\n * @param listener - The listener function to be subscribed.\n * @param selector - Optional selector function to transform the store state.\n * @returns A function to unsubscribe the listener.\n */\n subscribe: (listener: Listener<T>, selector?: Selector<T>) => () => void\n /**\n * Unubscribe a listener from the store.\n * @param listener - The listener function to be unsubscribed.\n */\n unsubscribe: (listener: Listener<T>) => void\n}\n// & { actions?: { [actionName: string]: ActionHandlerCaller } }\n\n// TODO infer actionNames from createStore arguments\n/**\n * Represents a store with additional actions.\n */\nexport type StoreWithActions<T> = Store<T> & { actions: { [actionName: string]: ActionHandlerCaller<T> } }\n\n\n\n\n/**\n * Represents an action handler function.\n */\nexport type ActionHandler<T> = (\n getState: Store<T>['getState'], // Function to get the current state of the store\n setState: Store<T>['setState'], // Function to set the state of the store\n ...rest: unknown[]\n) => void | Partial<T> | Promise<void | Partial<T>>\n\n/**\n * Represents an reducer function.\n */\nexport type Reducer<T> = (\n state: Partial<T>,\n action: string,\n ...rest: unknown[]\n) => Partial<T>\n\n\n/**\n * Represents a function that calls an action handler.\n */\nexport type ActionHandlerCaller<T> = (...args: unknown[]) => void | Partial<T> | Promise<void | Partial<T>>\n\n\ntype Actions<T> = { [key: string]: ActionHandler<T>}\n/**\n * Creates a new store.\n * @param initialState - The initial state of the store.\n * @param actions - Optional actions for the store.\n * @returns The created store.\n */\nexport const createStore = <T>(\n initialState: Partial<T>,\n actions?: Actions<T>,\n reducer?: Reducer<T>,\n): Store<T> | StoreWithActions<T> => {\n let currentState: Partial<T> = initialState\n const listeners = new Set<Listener<T>>()\n\n /**\n * Gets the current state of the store.\n * @returns The current state of the store.\n */\n const getState = (): Partial<T> => currentState\n\n // TODO debounce, batch? what is the meaningful time between setState ofr UI to be rendered and registerd by User?\n /**\n * Sets the state of the store.\n * @param newState - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n const setState = async (newState: Partial<T>): Promise<Partial<T>> => {\n currentState = newState\n\n // eslint-disable-next-line no-restricted-syntax\n for (const listener of listeners) {\n // has Listener selector?\n const selector: Selector<T> | undefined = listener?.selector\n\n // TODO compare selected value to the previous values of that listener/selector pair\n // if listener.previousValue === selector(currentState) no call\n // else listener.previousValue = selector(currentState) and call\n // l1 cache, weak references?\n const newValue: SelectedValueType<T> = selector ? selector(currentState) : currentState\n\n // TODO plugin equality\n if (listener.previousValue === undefined || listener.previousValue !== newValue) {\n listener.previousValue = newValue\n // eslint-disable-next-line no-await-in-loop\n await listener(newValue as Partial<T>)\n }\n }\n return currentState\n }\n\n /**\n * Represents the basic API of the store.\n */\n const storeBaseicApi: Store<T> = {\n /**\n * Get the current state of the store.\n * @returns The current state of the store.\n */\n getState,\n /**\n * Set the state of the store.\n * @param state - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n setState,\n /**\n * Subscribe a listener to the store.\n * @param listener - The listener function to be subscribed.\n * @returns A function to unsubscribe the listener.\n */\n subscribe: (listener: Listener<T>, selector?: Selector<T>) => {\n if (selector && listener.selector && listener.selector !== selector) {\n throw new Error('Error, mismatch selector, listener.selector !== selector.')\n }\n if (selector && !listener.selector) {\n // eslint-disable-next-line no-param-reassign\n listener.selector = selector\n }\n\n if (listener.selector) {\n // setting the previousValue for the next cache/equality check\n // eslint-disable-next-line no-param-reassign\n listener.previousValue = listener.selector(getState())\n }\n\n listeners.add(listener)\n return () => listeners.delete(listener)\n },\n /**\n * Unsubscribe a listener from the store.\n * @param listener - The listener function to be unsubscribed.\n */\n unsubscribe: (listener: Listener<T>) => {\n listeners.delete(listener)\n },\n }\n\n /**\n * Resolves the actions and creates action handlers.\n */\n const resolvedActions: Actions<T> | null | undefined\n = actions ? Object.entries(actions)?.reduce(\n (\n aggregator: Record<string, ActionHandlerCaller<T>>,\n [actionName, actionHandler]: [string, ActionHandler<T>],\n ) => {\n // eslint-disable-next-line no-param-reassign\n aggregator[actionName] = async(...rest: unknown[]): Promise<void | Partial<T>> => {\n // TODO try to not call subscriber too many times becuase of Error and Pending values\n const isAsync = isFunctionAsync(actionHandler as () => unknown)\n\n if (isAsync) {\n setState({\n ...getState(),\n [`${actionName}Error`]: null,\n [`${actionName}Pending`]: true,\n })\n }\n\n try {\n const resultOfAction = await actionHandler(getState, setState, ...rest)\n\n // TODO try to mutate state only once with the results, that means pass custom setState to action,\n // so that it would matk pending and error already inside action\n if (reducer) {\n setState(reducer(getState(), actionName, ...rest))\n }\n\n if (isAsync) {\n setState({ ...getState(), [`${actionName}Pending`]: false })\n }\n\n return resultOfAction\n } catch (error) {\n if (isAsync) {\n setState({\n ...getState(),\n [`${actionName}Pending`]: false,\n [`${actionName}Error`]: error,\n })\n }\n throw error\n }\n }\n\n return aggregator\n },\n {},\n ) : null\n\n /**\n * Represents the store combined with actions.\n */\n const storeCombinedWithActions = {\n ...storeBaseicApi,\n ...(resolvedActions ? { actions: { ...resolvedActions } } : {}),\n }\n\n return resolvedActions\n ? storeCombinedWithActions as StoreWithActions<T>\n // ? storeCombinedWithActions as StoreWithActions<T> & ActionsStateReturnType<A>\n : storeCombinedWithActions as Store<T>\n}\n"],"names":["createStore","initialState","actions","reducer","currentState","listeners","Set","getState","setState","_ref","_asyncToGenerator","newState","listener","selector","newValue","undefined","previousValue","_x","apply","this","arguments","storeBaseicApi","subscribe","Error","add","delete","unsubscribe","resolvedActions","Object","entries","reduce","aggregator","_ref2","actionName","actionHandler","isAsync","isFunctionAsync","_len","length","rest","Array","_key","resultOfAction","error","storeCombinedWithActions"],"mappings":"iJAkGO,MAAMA,EAAcA,CACzBC,EACAC,EACAC,KAEA,IAAIC,EAA2BH,EAC/B,MAAMI,EAAY,IAAIC,IAMhBC,EAAWA,IAAkBH,EAQ7BI,EAAQ,WAAA,IAAAC,EAAAC,GAAG,UAAOC,GACtBP,EAAeO,EAGf,IAAK,MAAMC,KAAYP,EAAW,CAEhC,MAAMQ,EAAoCD,GAAUC,SAM9CC,EAAiCD,EAAWA,EAAST,GAAgBA,OAG5CW,IAA3BH,EAASI,eAA+BJ,EAASI,gBAAkBF,IACrEF,EAASI,cAAgBF,QAEnBF,EAASE,GAEnB,CACA,OAAOV,KACR,OAtBKI,SAAQS,GAAA,OAAAR,EAAAS,MAAAC,KAAAC,UAAA,EAAA,GA2BRC,EAA2B,CAK/Bd,WAMAC,WAMAc,UAAWA,CAACV,EAAuBC,KACjC,GAAIA,GAAYD,EAASC,UAAYD,EAASC,WAAaA,EACzD,MAAM,IAAIU,MAAM,6DAclB,OAZIV,IAAaD,EAASC,WAExBD,EAASC,SAAWA,GAGlBD,EAASC,WAGXD,EAASI,cAAgBJ,EAASC,SAASN,MAG7CF,EAAUmB,IAAIZ,GACP,IAAMP,EAAUoB,OAAOb,EAAS,EAMzCc,YAAcd,IACZP,EAAUoB,OAAOb,EAAS,GAOxBe,EACFzB,EAAU0B,OAAOC,QAAQ3B,IAAU4B,QACnC,CACEC,EAAkDC,KAE/C,IADFC,EAAYC,GAA0CF,EAyCvD,OAtCAD,EAAWE,GAAWvB,GAAG,YAEvB,MAAMyB,EAAUC,EAAgBF,GAE5BC,GACF3B,EAAS,IACJD,IACH,CAAC,GAAG0B,UAAoB,KACxB,CAAC,GAAGA,aAAsB,IAI9B,IAAI,IAAA,IAAAI,EAAAjB,UAAAkB,OAZ4BC,EAAIC,IAAAA,MAAAH,GAAAI,EAAA,EAAAA,EAAAJ,EAAAI,IAAJF,EAAIE,GAAArB,UAAAqB,GAalC,MAAMC,QAAuBR,EAAc3B,EAAUC,KAAa+B,GAYlE,OARIpC,GACFK,EAASL,EAAQI,IAAY0B,KAAeM,IAG1CJ,GACF3B,EAAS,IAAKD,IAAY,CAAC,GAAG0B,aAAsB,IAG/CS,CACR,CAAC,MAAOC,GAQP,MAPIR,GACF3B,EAAS,IACJD,IACH,CAAC,GAAG0B,aAAsB,EAC1B,CAAC,GAAGA,UAAoBU,IAGtBA,CACR,KAGKZ,CAAU,GAEnB,CAAA,GACE,KAKAa,EAA2B,IAC5BvB,KACCM,EAAkB,CAAEzB,QAAS,IAAKyB,IAAsB,IAG9D,OACIiB,CAEoC"}
1
+ {"version":3,"file":"store.vanillajs.js","sources":["../../../../../../../../src/core/utils/appState/store/store.vanillajs.ts"],"sourcesContent":["\n// TinyStore, inspired by https://github.com/jherr/syncexternalstore/blob/main/csr/src/store.js\n\nimport { isFunctionAsync } from '../../helpers'\n\n\nlet SET_STATE_MERGE: boolean = true\n\n\nexport const canSetStateMerge = (value: boolean): void => {\n SET_STATE_MERGE = !!value\n}\n\nexport const getSetStateMerge = (): boolean => SET_STATE_MERGE\n\n/**\n * Represents the callback function for a store listener.\n */\nexport type ListenerCallBack<T> = (state: Partial<T>) => void\n\n/**\n * Represents a selector function that transforms the store state.\n */\n// export type Selector<T> = (state: Partial<T>) => Partial<T>;\nexport type SelectedValueType<T> = Partial<T> | Partial<keyof T>\n| string | number | boolean | undefined | string[] | number[] | boolean[] | undefined[];\nexport type Selector<T> = (state: Partial<T>) => SelectedValueType<T>;\n\n\n/**\n * Represents a listener for the store.\n */\nexport type Listener<T> = {\n selector?: Selector<T>\n previousValue?: SelectedValueType<T>\n} & ListenerCallBack<T>\n\n/**\n * Represents a store.\n */\nexport type Store<T> = {\n /**\n * Get the current state of the store.\n * @returns The current state of the store.\n */\n getState: () => Partial<T>\n /**\n * Set the state of the store.\n * @param state - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n setState: (state: Partial<T>) => Promise<Partial<T>>\n /**\n * Subscribe a listener to the store.\n * @param listener - The listener function to be subscribed.\n * @param selector - Optional selector function to transform the store state.\n * @returns A function to unsubscribe the listener.\n */\n subscribe: (listener: Listener<T>, selector?: Selector<T>) => () => void\n /**\n * Unubscribe a listener from the store.\n * @param listener - The listener function to be unsubscribed.\n */\n unsubscribe: (listener: Listener<T>) => void\n}\n// & { actions?: { [actionName: string]: ActionHandlerCaller } }\n\n// TODO infer actionNames from createStore arguments\n/**\n * Represents a store with additional actions.\n */\nexport type StoreWithActions<T> = Store<T> & { actions: { [actionName: string]: ActionHandlerCaller<T> } }\n\n\n\n\n/**\n * Represents an action handler function.\n */\nexport type ActionHandler<T> = (\n getState: Store<T>['getState'], // Function to get the current state of the store\n setState: Store<T>['setState'], // Function to set the state of the store\n ...rest: unknown[]\n) => void | Partial<T> | Promise<void | Partial<T>>\n\n/**\n * Represents an reducer function.\n */\nexport type Reducer<T> = (\n state: Partial<T>,\n action: string,\n ...rest: unknown[]\n) => Partial<T>\n\n\n/**\n * Represents a function that calls an action handler.\n */\nexport type ActionHandlerCaller<T> = (...args: unknown[]) => void | Partial<T> | Promise<void | Partial<T>>\n\n\ntype Actions<T> = { [key: string]: ActionHandler<T>}\n/**\n * Creates a new store.\n * @param initialState - The initial state of the store.\n * @param actions - Optional actions for the store.\n * @returns The created store.\n */\nexport const createStore = <T>(\n initialState: Partial<T>,\n actions?: Actions<T>,\n reducer?: Reducer<T>,\n): Store<T> | StoreWithActions<T> => {\n let currentState: Partial<T> = initialState\n const listeners = new Set<Listener<T>>()\n\n /**\n * Gets the current state of the store.\n * @returns The current state of the store.\n */\n const getState = (): Partial<T> => currentState\n\n // TODO debounce, batch? what is the meaningful time between setState ofr UI to be rendered and registerd by User?\n /**\n * Sets the state of the store.\n * @param newState - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n const setState = async (newState: Partial<T>): Promise<Partial<T>> => {\n currentState = SET_STATE_MERGE ? { ...getState(), ...newState } : newState\n\n // eslint-disable-next-line no-restricted-syntax\n for (const listener of listeners) {\n // has Listener selector?\n const selector: Selector<T> | undefined = listener?.selector\n\n // TODO compare selected value to the previous values of that listener/selector pair\n // if listener.previousValue === selector(currentState) no call\n // else listener.previousValue = selector(currentState) and call\n // l1 cache, weak references?\n const newValue: SelectedValueType<T> = selector ? selector(currentState) : currentState\n\n // TODO plugin equality\n if (listener.previousValue === undefined || listener.previousValue !== newValue) {\n listener.previousValue = newValue\n // eslint-disable-next-line no-await-in-loop\n await listener(newValue as Partial<T>)\n }\n }\n return currentState\n }\n\n /**\n * Represents the basic API of the store.\n */\n const storeBaseicApi: Store<T> = {\n /**\n * Get the current state of the store.\n * @returns The current state of the store.\n */\n getState,\n /**\n * Set the state of the store.\n * @param state - The new state to set.\n * @returns A promise that resolves to the new state.\n */\n setState,\n /**\n * Subscribe a listener to the store.\n * @param listener - The listener function to be subscribed.\n * @returns A function to unsubscribe the listener.\n */\n subscribe: (listener: Listener<T>, selector?: Selector<T>) => {\n if (selector && listener.selector && listener.selector !== selector) {\n throw new Error('Error, mismatch selector, listener.selector !== selector.')\n }\n if (selector && !listener.selector) {\n // eslint-disable-next-line no-param-reassign\n listener.selector = selector\n }\n\n if (listener.selector) {\n // setting the previousValue for the next cache/equality check\n // eslint-disable-next-line no-param-reassign\n listener.previousValue = listener.selector(getState())\n }\n\n listeners.add(listener)\n return () => listeners.delete(listener)\n },\n /**\n * Unsubscribe a listener from the store.\n * @param listener - The listener function to be unsubscribed.\n */\n unsubscribe: (listener: Listener<T>) => {\n listeners.delete(listener)\n },\n }\n\n /**\n * Resolves the actions and creates action handlers.\n */\n const resolvedActions: Actions<T> | null | undefined\n = actions ? Object.entries(actions)?.reduce(\n (\n aggregator: Record<string, ActionHandlerCaller<T>>,\n [actionName, actionHandler]: [string, ActionHandler<T>],\n ) => {\n // eslint-disable-next-line no-param-reassign\n aggregator[actionName] = async(...rest: unknown[]): Promise<void | Partial<T>> => {\n // TODO try to not call subscriber too many times becuase of Error and Pending values\n const isAsync = isFunctionAsync(actionHandler as () => unknown)\n\n if (isAsync) {\n setState({\n ...getState(),\n [`${actionName}Error`]: null,\n [`${actionName}Pending`]: true,\n })\n }\n\n try {\n const resultOfAction = await actionHandler(getState, setState, ...rest)\n\n // TODO try to mutate state only once with the results, that means pass custom setState to action,\n // so that it would matk pending and error already inside action\n if (reducer) {\n setState(reducer(getState(), actionName, ...rest))\n }\n\n if (isAsync) {\n setState({ ...getState(), [`${actionName}Pending`]: false })\n }\n\n return resultOfAction\n } catch (error) {\n if (isAsync) {\n setState({\n ...getState(),\n [`${actionName}Pending`]: false,\n [`${actionName}Error`]: error,\n })\n }\n throw error\n }\n }\n\n return aggregator\n },\n {},\n ) : null\n\n /**\n * Represents the store combined with actions.\n */\n const storeCombinedWithActions = {\n ...storeBaseicApi,\n ...(resolvedActions ? { actions: { ...resolvedActions } } : {}),\n }\n\n return resolvedActions\n ? storeCombinedWithActions as StoreWithActions<T>\n // ? storeCombinedWithActions as StoreWithActions<T> & ActionsStateReturnType<A>\n : storeCombinedWithActions as Store<T>\n}\n"],"names":["SET_STATE_MERGE","canSetStateMerge","value","getSetStateMerge","createStore","initialState","actions","reducer","currentState","listeners","Set","getState","setState","_ref","_asyncToGenerator","newState","listener","selector","newValue","undefined","previousValue","_x","apply","this","arguments","storeBaseicApi","subscribe","Error","add","delete","unsubscribe","resolvedActions","Object","entries","reduce","aggregator","_ref2","actionName","actionHandler","isAsync","isFunctionAsync","_len","length","rest","Array","_key","resultOfAction","error","storeCombinedWithActions"],"mappings":"iJAMA,IAAIA,GAA2B,EAGlBC,MAAAA,EAAoBC,IAC/BF,IAAoBE,CAAK,EAGdC,EAAmBA,IAAeH,EA+FlCI,EAAcA,CACzBC,EACAC,EACAC,KAEA,IAAIC,EAA2BH,EAC/B,MAAMI,EAAY,IAAIC,IAMhBC,EAAWA,IAAkBH,EAQ7BI,EAAQ,WAAA,IAAAC,EAAAC,GAAG,UAAOC,GACtBP,EAAeR,EAAkB,IAAKW,OAAeI,GAAaA,EAGlE,IAAK,MAAMC,KAAYP,EAAW,CAEhC,MAAMQ,EAAoCD,GAAUC,SAM9CC,EAAiCD,EAAWA,EAAST,GAAgBA,OAG5CW,IAA3BH,EAASI,eAA+BJ,EAASI,gBAAkBF,IACrEF,EAASI,cAAgBF,QAEnBF,EAASE,GAEnB,CACA,OAAOV,KACR,OAtBKI,SAAQS,GAAA,OAAAR,EAAAS,MAAAC,KAAAC,UAAA,EAAA,GA2BRC,EAA2B,CAK/Bd,WAMAC,WAMAc,UAAWA,CAACV,EAAuBC,KACjC,GAAIA,GAAYD,EAASC,UAAYD,EAASC,WAAaA,EACzD,MAAM,IAAIU,MAAM,6DAclB,OAZIV,IAAaD,EAASC,WAExBD,EAASC,SAAWA,GAGlBD,EAASC,WAGXD,EAASI,cAAgBJ,EAASC,SAASN,MAG7CF,EAAUmB,IAAIZ,GACP,IAAMP,EAAUoB,OAAOb,EAAS,EAMzCc,YAAcd,IACZP,EAAUoB,OAAOb,EAAS,GAOxBe,EACFzB,EAAU0B,OAAOC,QAAQ3B,IAAU4B,QACnC,CACEC,EAAkDC,KAE/C,IADFC,EAAYC,GAA0CF,EAyCvD,OAtCAD,EAAWE,GAAWvB,GAAG,YAEvB,MAAMyB,EAAUC,EAAgBF,GAE5BC,GACF3B,EAAS,IACJD,IACH,CAAC,GAAG0B,UAAoB,KACxB,CAAC,GAAGA,aAAsB,IAI9B,IAAI,IAAA,IAAAI,EAAAjB,UAAAkB,OAZ4BC,EAAIC,IAAAA,MAAAH,GAAAI,EAAA,EAAAA,EAAAJ,EAAAI,IAAJF,EAAIE,GAAArB,UAAAqB,GAalC,MAAMC,QAAuBR,EAAc3B,EAAUC,KAAa+B,GAYlE,OARIpC,GACFK,EAASL,EAAQI,IAAY0B,KAAeM,IAG1CJ,GACF3B,EAAS,IAAKD,IAAY,CAAC,GAAG0B,aAAsB,IAG/CS,CACR,CAAC,MAAOC,GAQP,MAPIR,GACF3B,EAAS,IACJD,IACH,CAAC,GAAG0B,aAAsB,EAC1B,CAAC,GAAGA,UAAoBU,IAGtBA,CACR,KAGKZ,CAAU,GAEnB,CAAA,GACE,KAKAa,EAA2B,IAC5BvB,KACCM,EAAkB,CAAEzB,QAAS,IAAKyB,IAAsB,IAG9D,OACIiB,CAEoC"}
@@ -1,2 +1,2 @@
1
- export{useApi}from"./core/hooks/useApi.js";export{useToggle}from"./core/hooks/useToggle.js";export{useToggle2}from"./core/hooks/useToggle2.js";export{outsideClickHandler,useOutsideClick}from"./core/hooks/useOutsideClick.js";export{useResize}from"./core/hooks/useResize.js";export{useClassNames}from"./core/hooks/useClassNames.js";export{useParseProps}from"./core/hooks/useParseProps.js";export{getBaseThemes,observeThemePreference,setThemeClassNames,switchColorTheme,updateColorTheme,useThemePreference}from"./core/hooks/useThemePreference.js";export{useAnimation}from"./core/hooks/useAnimation.js";export{useIntersectionObserver}from"./core/hooks/useIntersectionObserver.js";export{useTimeoutFn}from"./core/hooks/useSetTimeout.js";export{isBirthNumberValid}from"./core/utils/helpers/birthnumber.validator.js";export{getMatch,isValidFormat,isValidModulo11,parse,regex}from"./core/utils/helpers/birthnumberCZSKvalidator.js";export{parseCSVdata,validateCSVFile,validateCSVlines,validateJSONFile,validateLineCellTrimmed,validateLineNumColumns,validateSDFFile}from"./core/utils/helpers/fileValidator.js";export{DATE_FORMAT,DATE_TIME_FORMAT,formatDate,formatDateTime,formatDateToTimestamp,getDate}from"./core/utils/helpers/date.js";export{getDeviceId}from"./core/utils/helpers/deviceInfo.js";export{emailMatch,emailMatcher,regexBuilder}from"./core/utils/helpers/emailMatcher.js";export{cleanCsvLines,formatFilePath}from"./core/utils/helpers/file.js";export{arrayToObjectTree,chunkArray,duplicatesInArray,formatJsonString,formatObj,formatObj2}from"./core/utils/helpers/objectOperations.js";export{AsyncFunctionTemplate,debounce,delay,isFunctionAsync,memoize,memoizeComplex,memoizer,nestedTernary}from"./core/utils/helpers/other.js";export{escapeRegExp,fileNameExt,findStringInText,normalizeString,removeWhitespaces,sanitizeId,sanitizePathId,toLowerCase,toUpperCase,truncateText}from"./core/utils/helpers/textValueOperations.js";export{Operation,decrementValue,incerementValue,numberDefined,numberOperation,restrictNumberInLimits,setValue}from"./core/utils/helpers/valueOperations.js";export{cancelableSetInterval,cancelableSetTimeout}from"./core/utils/helpers/cancelableDelayedFunction.js";export{anchorClick,classNames,generateId,mapSerReplacer,noop,parseProps}from"./core/utils/helpers/ui.js";export{composeId,defaultSanitizeConfig,sanitizeHtml}from"./core/utils/helpers/text.js";export{keyExtractor,keyExtractorFunction}from"./core/utils/keyExtractor.js";export{dateRangeFormat,getDateTime,getTimeFromNow,getTimeFromNowOriginal,getTimeTo}from"./core/utils/date.js";export{ced,createResolveAttribute,customElementDefine,resolveAttributes}from"./core/utils/webComponents/webComponent.utils.js";export{createStore}from"./core/utils/appState/store/store.vanillajs.js";export{createDataStore}from"./core/utils/appState/store/store.vanillajs.templates.js";export{useStore,useStoreApi}from"./core/utils/appState/store/useStore.react.js";export{PeregrineMQ,PeregrineMQClearError}from"./core/utils/appState/peregrineMQ/peregrineMQ.js";export{NON_EXISTENT_CHANNEL}from"./core/utils/appState/peregrineMQ/peregrineMQ.types.js";export{usePeregrineMQ}from"./core/utils/appState/peregrineMQ/usePeregrineMQ.react.js";export{peregrineMQInstance}from"./core/utils/appState/peregrineMQ/index.js";export{TinyStateMachine,TinyStateMachineEvent,TinyStateMachineEventType,TinyStateMachineState,createStates,stateIterator}from"./core/utils/appState/stateMachine/tiny-state-machine.base.js";export{Alerts,EventName,KeyCode}from"./core/constants/ui.constants.js";export{calculateColors,calculatePercColor,convertHex,convertRGB,defaultFontSize,pxToRem,resolveStyleValue,setDefaultFontSize,toHex}from"./core/ui/utils/style.js";export{LayoutBox}from"./core/ui/components/container/layoutBox/LayoutBox.js";export{LayoutDirection}from"./core/ui/components/container/layoutBox/layoutBox.types.js";export{LazyComponent,PendingBoundary,createLazyModule,createLazyModuleWithStore,wrapPromise}from"./core/ui/components/container/lazyComponent/LazyComponent.js";export{CollapsibleContainer}from"./core/ui/components/container/CollapsibleContainer.js";export{ResizableContainer}from"./core/ui/components/container/ResizableContainer.js";export{DefaultErrorComponent,ErrorBoundary}from"./core/ui/components/error/ErrorBoundary.js";export{Field,Select,setIconColor,setIconComponent}from"./core/ui/components/field/Field.js";export{DividerHorizontal,DividerLine,DividerVertical}from"./core/ui/components/dividers/DividerLine.js";export{IconBase}from"./core/ui/components/icon/IconBase.js";export{Icon}from"./core/ui/components/icon/Icon.js";export{ESIcon,ESIconBase}from"./core/ui/components/icon/IconWC.js";export{Button,IconButton,keys}from"./core/ui/components/atoms/button/Button.js";export{Text}from"./core/ui/components/atoms/text/Text.js";export{Headline,HeadlineSecondary,HeadlineTertiary}from"./core/ui/components/atoms/text/Headline.js";export{Paragraph,ParagraphBold,ParagraphBoldSmall,ParagraphSmall}from"./core/ui/components/atoms/text/Paragraph.js";export{Link}from"./core/ui/components/atoms/text/Link.js";export{AnchorLink}from"./core/ui/components/atoms/text/anchor-link/AnchorLink.js";export{TextAndContent,TextAndIcons}from"./core/ui/components/atoms/textAndContent/TextAndContent.js";export{Tag}from"./core/ui/components/atoms/tag/Tag.js";export{TagVariant}from"./core/ui/components/atoms/tag/tag.types.js";export{Toggle}from"./core/ui/components/atoms/toggle/Toggle.js";export{FlowLayout}from"./core/ui/components/molecules/layouts/FlowLayout.js";export{Popover}from"./core/ui/components/molecules/popover/PopoverLite.js";export{Tooltip}from"./core/ui/components/molecules/popover/Tooltip.js";export{PopoverPlacement}from"./core/ui/components/molecules/popover/popover.types.js";export{Popup}from"./core/ui/components/molecules/popup/Popup.js";export{PopupAnimateVariant}from"./core/ui/components/molecules/popup/popup.types.js";
1
+ export{useApi}from"./core/hooks/useApi.js";export{useToggle}from"./core/hooks/useToggle.js";export{useToggle2}from"./core/hooks/useToggle2.js";export{outsideClickHandler,useOutsideClick}from"./core/hooks/useOutsideClick.js";export{useResize}from"./core/hooks/useResize.js";export{useClassNames}from"./core/hooks/useClassNames.js";export{useParseProps}from"./core/hooks/useParseProps.js";export{getBaseThemes,observeThemePreference,setThemeClassNames,switchColorTheme,updateColorTheme,useThemePreference}from"./core/hooks/useThemePreference.js";export{useAnimation}from"./core/hooks/useAnimation.js";export{useIntersectionObserver}from"./core/hooks/useIntersectionObserver.js";export{useTimeoutFn}from"./core/hooks/useSetTimeout.js";export{isBirthNumberValid}from"./core/utils/helpers/birthnumber.validator.js";export{getMatch,isValidFormat,isValidModulo11,parse,regex}from"./core/utils/helpers/birthnumberCZSKvalidator.js";export{parseCSVdata,validateCSVFile,validateCSVlines,validateJSONFile,validateLineCellTrimmed,validateLineNumColumns,validateSDFFile}from"./core/utils/helpers/fileValidator.js";export{DATE_FORMAT,DATE_TIME_FORMAT,formatDate,formatDateTime,formatDateToTimestamp,getDate}from"./core/utils/helpers/date.js";export{getDeviceId}from"./core/utils/helpers/deviceInfo.js";export{emailMatch,emailMatcher,regexBuilder}from"./core/utils/helpers/emailMatcher.js";export{cleanCsvLines,formatFilePath}from"./core/utils/helpers/file.js";export{arrayToObjectTree,chunkArray,duplicatesInArray,formatJsonString,formatObj,formatObj2}from"./core/utils/helpers/objectOperations.js";export{AsyncFunctionTemplate,debounce,delay,isFunctionAsync,memoize,memoizeComplex,memoizer,nestedTernary}from"./core/utils/helpers/other.js";export{escapeRegExp,fileNameExt,findStringInText,normalizeString,removeWhitespaces,sanitizeId,sanitizePathId,toLowerCase,toUpperCase,truncateText}from"./core/utils/helpers/textValueOperations.js";export{Operation,decrementValue,incerementValue,numberDefined,numberOperation,restrictNumberInLimits,setValue}from"./core/utils/helpers/valueOperations.js";export{cancelableSetInterval,cancelableSetTimeout}from"./core/utils/helpers/cancelableDelayedFunction.js";export{anchorClick,classNames,generateId,mapSerReplacer,noop,parseProps}from"./core/utils/helpers/ui.js";export{composeId,defaultSanitizeConfig,sanitizeHtml}from"./core/utils/helpers/text.js";export{keyExtractor,keyExtractorFunction}from"./core/utils/keyExtractor.js";export{dateRangeFormat,getDateTime,getTimeFromNow,getTimeFromNowOriginal,getTimeTo}from"./core/utils/date.js";export{ced,createResolveAttribute,customElementDefine,resolveAttributes}from"./core/utils/webComponents/webComponent.utils.js";export{canSetStateMerge,createStore,getSetStateMerge}from"./core/utils/appState/store/store.vanillajs.js";export{createDataStore}from"./core/utils/appState/store/store.vanillajs.templates.js";export{useStore,useStoreApi}from"./core/utils/appState/store/useStore.react.js";export{PeregrineMQ,PeregrineMQClearError}from"./core/utils/appState/peregrineMQ/peregrineMQ.js";export{NON_EXISTENT_CHANNEL}from"./core/utils/appState/peregrineMQ/peregrineMQ.types.js";export{usePeregrineMQ}from"./core/utils/appState/peregrineMQ/usePeregrineMQ.react.js";export{peregrineMQInstance}from"./core/utils/appState/peregrineMQ/index.js";export{TinyStateMachine,TinyStateMachineEvent,TinyStateMachineEventType,TinyStateMachineState,createStates,stateIterator}from"./core/utils/appState/stateMachine/tiny-state-machine.base.js";export{Alerts,EventName,KeyCode}from"./core/constants/ui.constants.js";export{calculateColors,calculatePercColor,convertHex,convertRGB,defaultFontSize,pxToRem,resolveStyleValue,setDefaultFontSize,toHex}from"./core/ui/utils/style.js";export{LayoutBox}from"./core/ui/components/container/layoutBox/LayoutBox.js";export{LayoutDirection}from"./core/ui/components/container/layoutBox/layoutBox.types.js";export{LazyComponent,PendingBoundary,createLazyModule,createLazyModuleWithStore,wrapPromise}from"./core/ui/components/container/lazyComponent/LazyComponent.js";export{CollapsibleContainer}from"./core/ui/components/container/CollapsibleContainer.js";export{ResizableContainer}from"./core/ui/components/container/ResizableContainer.js";export{DefaultErrorComponent,ErrorBoundary}from"./core/ui/components/error/ErrorBoundary.js";export{Field,Select,setIconColor,setIconComponent}from"./core/ui/components/field/Field.js";export{DividerHorizontal,DividerLine,DividerVertical}from"./core/ui/components/dividers/DividerLine.js";export{IconBase}from"./core/ui/components/icon/IconBase.js";export{Icon}from"./core/ui/components/icon/Icon.js";export{ESIcon,ESIconBase}from"./core/ui/components/icon/IconWC.js";export{Button,IconButton,keys}from"./core/ui/components/atoms/button/Button.js";export{Text}from"./core/ui/components/atoms/text/Text.js";export{Headline,HeadlineSecondary,HeadlineTertiary}from"./core/ui/components/atoms/text/Headline.js";export{Paragraph,ParagraphBold,ParagraphBoldSmall,ParagraphSmall}from"./core/ui/components/atoms/text/Paragraph.js";export{Link}from"./core/ui/components/atoms/text/Link.js";export{AnchorLink}from"./core/ui/components/atoms/text/anchor-link/AnchorLink.js";export{TextAndContent,TextAndIcons}from"./core/ui/components/atoms/textAndContent/TextAndContent.js";export{Tag}from"./core/ui/components/atoms/tag/Tag.js";export{TagVariant}from"./core/ui/components/atoms/tag/tag.types.js";export{Toggle}from"./core/ui/components/atoms/toggle/Toggle.js";export{FlowLayout}from"./core/ui/components/molecules/layouts/FlowLayout.js";export{Popover}from"./core/ui/components/molecules/popover/PopoverLite.js";export{Tooltip}from"./core/ui/components/molecules/popover/Tooltip.js";export{PopoverPlacement}from"./core/ui/components/molecules/popover/popover.types.js";export{Popup}from"./core/ui/components/molecules/popup/Popup.js";export{PopupAnimateVariant}from"./core/ui/components/molecules/popup/popup.types.js";
2
2
  //# sourceMappingURL=index.js.map