@yelon/util 16.3.9 → 16.4.4
Sign up to get free protection for your applications and to get access to all the features.
@@ -1,2 +1,2 @@
|
|
1
1
|
export {};
|
2
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmlzLnR5cGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy91dGlsL2NvbmZpZy9iaXMvYmlzLnR5cGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgWXVuemFpQnVzaW5lc3NDb25maWcge1xuICBiYXNlVXJsPzogc3RyaW5nO1xuICBzeXN0ZW1Db2RlPzogc3RyaW5nO1xuICBsb2dpbkZvcm0/OiBGb3JtRGF0YSB8IG51bGw7XG4gIHJlZnJlc2hUb2tlbkVuYWJsZWQ/
|
2
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmlzLnR5cGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy91dGlsL2NvbmZpZy9iaXMvYmlzLnR5cGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgWXVuemFpQnVzaW5lc3NDb25maWcge1xuICBiYXNlVXJsPzogc3RyaW5nO1xuICBzeXN0ZW1Db2RlPzogc3RyaW5nO1xuICBsb2dpbkZvcm0/OiBGb3JtRGF0YSB8IG51bGw7XG4gIHJlZnJlc2hUb2tlbkVuYWJsZWQ/OiBib29sZWFuO1xuICByZWZyZXNoVG9rZW5UeXBlPzogJ3JlLXJlcXVlc3QnIHwgJ2F1dGgtcmVmcmVzaCc7XG4gIG5hdj86IHtcbiAgICBtaW5lPzogYm9vbGVhbjtcbiAgICBhbGw/OiBib29sZWFuO1xuICB9O1xufVxuIl19
|
@@ -56,4 +56,4 @@ export function useLocalStorageTenant() {
|
|
56
56
|
const getFn = () => get(YZ_TENANT_KEY);
|
57
57
|
return [setFn, getFn];
|
58
58
|
}
|
59
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9jYWxTdG9yYWdlVXRpbHMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy91dGlsL21jYWNoZS9sb2NhbFN0b3JhZ2VVdGlscy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFFQSxNQUFNLENBQUMsTUFBTSxXQUFXLEdBQUcsVUFBVSxDQUFDO0FBQ3RDLE1BQU0sQ0FBQyxNQUFNLG1CQUFtQixHQUFHLGtCQUFrQixDQUFDO0FBQ3RELE1BQU0sQ0FBQyxNQUFNLGNBQWMsR0FBRyxhQUFhLENBQUM7QUFDNUMsTUFBTSxDQUFDLE1BQU0sYUFBYSxHQUFHLFlBQVksQ0FBQztBQUMxQyxNQUFNLENBQUMsTUFBTSxrQkFBa0IsR0FBRyxpQkFBaUIsQ0FBQztBQUNwRCxNQUFNLENBQUMsTUFBTSxvQkFBb0IsR0FBRyxtQkFBbUIsQ0FBQztBQUN4RCxNQUFNLENBQUMsTUFBTSxhQUFhLEdBQUcsWUFBWSxDQUFDO0FBQzFDLDJDQUEyQztBQUMzQyx5Q0FBeUM7QUFFekMsU0FBUyxHQUFHLENBQUksR0FBVztJQUN6QixJQUFJLEdBQUcsS0FBSyxrQkFBa0IsRUFBRTtRQUM5QixPQUFPLFlBQVksQ0FBQyxPQUFPLENBQUMsR0FBRyxDQUFRLENBQUM7S0FDekM7SUFDRCxNQUFNLElBQUksR0FBRyxZQUFZLENBQUMsT0FBTyxDQUFDLEdBQUcsQ0FBQyxDQUFDO0lBQ3ZDLE9BQU8sSUFBSSxDQUFDLENBQUMs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ldDxzdHJpbmc+ID0gKCkgPT4gZ2V0PHN0cmluZz4oWVpfVEVOQU5UX0tFWSk7XG4gIHJldHVybiBbc2V0Rm4sIGdldEZuXTtcbn1cbiJdfQ==
|
@@ -4,4 +4,4 @@ export var NavType;
|
|
4
4
|
NavType["GROUP"] = "group";
|
5
5
|
NavType["TILE"] = "tile";
|
6
6
|
})(NavType || (NavType = {}));
|
7
|
-
//# sourceMappingURL=data:application/json;base64,
|
7
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibmF2LnR5cGVzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcGFja2FnZXMvdXRpbC9tdHlwZXMvbmF2LnR5cGVzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUVBLE1BQU0sQ0FBTixJQUFZLE9BSVg7QUFKRCxXQUFZLE9BQU87SUFDakIsc0NBQTJCLENBQUE7SUFDM0IsMEJBQWUsQ0FBQTtJQUNmLHdCQUFhLENBQUE7QUFDZixDQUFDLEVBSlcsT0FBTyxLQUFQLE9BQU8sUUFJbEIiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBZdW56YWlOYXZUb3BpYyB9IGZyb20gJy4vaGVhZGVyLW1lbnUudHlwZSc7XG5cbmV4cG9ydCBlbnVtIE5hdlR5cGUge1xuICBBUFBMSUNBVElPTiA9ICdhcHBsaWNhdGlvbicsXG4gIEdST1VQID0gJ2dyb3VwJyxcbiAgVElMRSA9ICd0aWxlJ1xufVxuXG5leHBvcnQgaW50ZXJmYWNlIExheW91dEJhc2ljQXNpZGUge1xuICBuYW1lOiBzdHJpbmc7XG4gIGludHJvOiBzdHJpbmc7XG4gIGljb246IHN0cmluZztcbn1cblxuZXhwb3J0IGludGVyZmFjZSBMYXlvdXRCYXNpY0Rpc3BsYXkge1xuICBuYXY6IGJvb2xlYW47XG4gIHJldXNldGFiOiBib29sZWFuO1xuICBhc2lkZTogYm9vbGVhbjtcbn1cblxuZXhwb3J0IGludGVyZmFjZSBMYXlvdXROYXZBcHBsaWNhdGlvblN0YXRlIHtcbiAgYWN0aXZlOiBib29sZWFuO1xuICB0eXBlOiAnYWxsJyB8ICdtaW5lJyB8ICdvdGhlcic7XG4gIHRvcGljPzogWXVuemFpTmF2VG9waWM7XG4gIHRvcGljczogWXVuemFpTmF2VG9waWNbXTtcbiAgbGlzdDogWXVuemFpTmF2VG9waWNbXTtcbiAgc2VhcmNoOiBzdHJpbmcgfCBudWxsO1xufVxuXG5leHBvcnQgaW50ZXJmYWNlIExheW91dE5hdkdyb3VwU3RhdGUge1xuICB0b3BpY3M6IFl1bnphaU5hdlRvcGljW107XG59XG4iXX0=
|
package/fesm2022/mcache.mjs.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"mcache.mjs","sources":["../../../../packages/util/mcache/localStorageUtils.ts","../../../../packages/util/mcache/mcache.ts"],"sourcesContent":["import { LayoutBasicAside, NavType, YunzaiNavTopic, YunzaiProjectInfo, YunzaiUser } from '@yelon/util/mtypes';\n\nexport const YZ_USER_KEY = '_yz_user';\nexport const YZ_PROJECT_INFO_KEY = '_yz_project_info';\nexport const YZ_CURRENT_KEY = '_yz_current';\nexport const YZ_HEADER_KEY = '_yz_header';\nexport const YZ_HEADER_TYPE_KEY = '_yz_header_type';\nexport const YZ_DEFAULT_ROUTE_KEY = '_yz_default_route';\nexport const YZ_TENANT_KEY = '_yz_tenant';\n// export const YZ_LANGS_KEY = '_yz_langs';\n// export const YZ_LANG_KEY = '_yz_lang';\n\nfunction get<T>(key: string): T | null {\n if (key === YZ_HEADER_TYPE_KEY) {\n return localStorage.getItem(key) as any;\n }\n const item = localStorage.getItem(key);\n return item ? JSON.parse(item) : null;\n}\n\nfunction set<T>(key: string, data: T): void {\n if (key === YZ_HEADER_TYPE_KEY) {\n localStorage.setItem(YZ_HEADER_TYPE_KEY, data as string);\n return;\n }\n localStorage.setItem(key, JSON.stringify(data));\n}\n\ntype returnSet<T> = (data: T) => void;\ntype returnGet<T> = () => T | null;\n\nexport function useLocalStorageUser(): [returnSet<YunzaiUser>, returnGet<YunzaiUser>] {\n const setFn: returnSet<YunzaiUser> = user => set(YZ_USER_KEY, user);\n const getFn: returnGet<YunzaiUser> = () => get<YunzaiUser>(YZ_USER_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageProjectInfo(): [returnSet<YunzaiProjectInfo>, returnGet<YunzaiProjectInfo>] {\n const setFn: returnSet<YunzaiProjectInfo> = data => set(YZ_PROJECT_INFO_KEY, data);\n const getFn: returnGet<YunzaiProjectInfo> = () => get<YunzaiProjectInfo>(YZ_PROJECT_INFO_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageCurrent(): [returnSet<LayoutBasicAside>, returnGet<LayoutBasicAside>] {\n const setFn: returnSet<LayoutBasicAside> = data => set(YZ_CURRENT_KEY, data);\n const getFn: returnGet<LayoutBasicAside> = () => get<LayoutBasicAside>(YZ_CURRENT_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageHeaderType(): [returnSet<NavType>, returnGet<NavType>] {\n const setFn: returnSet<NavType> = data => set(YZ_HEADER_TYPE_KEY, data);\n const getFn: returnGet<NavType> = () => get<NavType>(YZ_HEADER_TYPE_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageHeader(): [returnSet<YunzaiNavTopic[]>, returnGet<YunzaiNavTopic[]>] {\n const setFn: returnSet<YunzaiNavTopic[]> = data => set(YZ_HEADER_KEY, data);\n const getFn: returnGet<YunzaiNavTopic[]> = () => get<YunzaiNavTopic[]>(YZ_HEADER_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageDefaultRoute(): [returnSet<string>, returnGet<string>] {\n const setFn: returnSet<string> = data => set(YZ_DEFAULT_ROUTE_KEY, data);\n const getFn: returnGet<string> = () => get<string>(YZ_DEFAULT_ROUTE_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageTenant(): [returnSet<string>, returnGet<string>] {\n const setFn: returnSet<string> = data => set(YZ_TENANT_KEY, data);\n const getFn: returnGet<string> = () => get<string>(YZ_TENANT_KEY);\n return [setFn, getFn];\n}\n
|
1
|
+
{"version":3,"file":"mcache.mjs","sources":["../../../../packages/util/mcache/localStorageUtils.ts","../../../../packages/util/mcache/mcache.ts"],"sourcesContent":["import { LayoutBasicAside, NavType, YunzaiNavTopic, YunzaiProjectInfo, YunzaiUser } from '@yelon/util/mtypes';\n\nexport const YZ_USER_KEY = '_yz_user';\nexport const YZ_PROJECT_INFO_KEY = '_yz_project_info';\nexport const YZ_CURRENT_KEY = '_yz_current';\nexport const YZ_HEADER_KEY = '_yz_header';\nexport const YZ_HEADER_TYPE_KEY = '_yz_header_type';\nexport const YZ_DEFAULT_ROUTE_KEY = '_yz_default_route';\nexport const YZ_TENANT_KEY = '_yz_tenant';\n// export const YZ_LANGS_KEY = '_yz_langs';\n// export const YZ_LANG_KEY = '_yz_lang';\n\nfunction get<T>(key: string): T | null {\n if (key === YZ_HEADER_TYPE_KEY) {\n return localStorage.getItem(key) as any;\n }\n const item = localStorage.getItem(key);\n return item ? JSON.parse(item) : null;\n}\n\nfunction set<T>(key: string, data: T): void {\n if (key === YZ_HEADER_TYPE_KEY) {\n localStorage.setItem(YZ_HEADER_TYPE_KEY, data as string);\n return;\n }\n localStorage.setItem(key, JSON.stringify(data));\n}\n\ntype returnSet<T> = (data: T) => void;\ntype returnGet<T> = () => T | null;\n\nexport function useLocalStorageUser(): [returnSet<YunzaiUser>, returnGet<YunzaiUser>] {\n const setFn: returnSet<YunzaiUser> = user => set(YZ_USER_KEY, user);\n const getFn: returnGet<YunzaiUser> = () => get<YunzaiUser>(YZ_USER_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageProjectInfo(): [returnSet<YunzaiProjectInfo>, returnGet<YunzaiProjectInfo>] {\n const setFn: returnSet<YunzaiProjectInfo> = data => set(YZ_PROJECT_INFO_KEY, data);\n const getFn: returnGet<YunzaiProjectInfo> = () => get<YunzaiProjectInfo>(YZ_PROJECT_INFO_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageCurrent(): [returnSet<LayoutBasicAside>, returnGet<LayoutBasicAside>] {\n const setFn: returnSet<LayoutBasicAside> = data => set(YZ_CURRENT_KEY, data);\n const getFn: returnGet<LayoutBasicAside> = () => get<LayoutBasicAside>(YZ_CURRENT_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageHeaderType(): [returnSet<NavType>, returnGet<NavType>] {\n const setFn: returnSet<NavType> = data => set(YZ_HEADER_TYPE_KEY, data);\n const getFn: returnGet<NavType> = () => get<NavType>(YZ_HEADER_TYPE_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageHeader(): [returnSet<YunzaiNavTopic[]>, returnGet<YunzaiNavTopic[]>] {\n const setFn: returnSet<YunzaiNavTopic[]> = data => set(YZ_HEADER_KEY, data);\n const getFn: returnGet<YunzaiNavTopic[]> = () => get<YunzaiNavTopic[]>(YZ_HEADER_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageDefaultRoute(): [returnSet<string>, returnGet<string>] {\n const setFn: returnSet<string> = data => set(YZ_DEFAULT_ROUTE_KEY, data);\n const getFn: returnGet<string> = () => get<string>(YZ_DEFAULT_ROUTE_KEY);\n return [setFn, getFn];\n}\n\nexport function useLocalStorageTenant(): [returnSet<string>, returnGet<string>] {\n const setFn: returnSet<string> = data => set(YZ_TENANT_KEY, data);\n const getFn: returnGet<string> = () => get<string>(YZ_TENANT_KEY);\n return [setFn, getFn];\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":"AAEO,MAAM,WAAW,GAAG,WAAW;AAC/B,MAAM,mBAAmB,GAAG,mBAAmB;AAC/C,MAAM,cAAc,GAAG,cAAc;AACrC,MAAM,aAAa,GAAG,aAAa;AACnC,MAAM,kBAAkB,GAAG,kBAAkB;AAC7C,MAAM,oBAAoB,GAA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7E,MAAM,KAAK,GAAgC,MAAM,GAAG,CAAmB,cAAc,CAAC,CAAC;AACvF,IAAA,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;AACxB,CAAC;SAEe,yBAAyB,GAAA;AACvC,IAAA,MAAM,KAAK,GAAuB,IAAI,IAAI,GAAG,CAAC,kBAAkB,EAAE,IAAI,CAAC,CAAC;IACxE,MAAM,KAAK,GAAuB,MAAM,GAAG,CAAU,kBAAkB,CAAC,CAAC;AACzE,IAAA,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;AACxB,CAAC;SAEe,qBAAqB,GAAA;AACnC,IAAA,MAAM,KAAK,GAAgC,IAAI,IAAI,GAAG,CAAC,aAAa,EAAE,IAAI,CAAC,CAAC;IAC5E,MAAM,KAAK,GAAgC,MAAM,GAAG,CAAmB,aAAa,CAAC,CAAC;AACtF,IAAA,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;AACxB,CAAC;SAEe,2BAA2B,GAAA;AACzC,IAAA,MAAM,KAAK,GAAsB,IAAI,IAAI,GAAG,CAAC,oBAAoB,EAAE,IAAI,CAAC,CAAC;IACzE,MAAM,KAAK,GAAsB,MAAM,GAAG,CAAS,oBAAoB,CAAC,CAAC;AACzE,IAAA,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;AACxB,CAAC;SAEe,qBAAqB,GAAA;AACnC,IAAA,MAAM,KAAK,GAAsB,IAAI,IAAI,GAAG,CAAC,aAAa,EAAE,IAAI,CAAC,CAAC;IAClE,MAAM,KAAK,GAAsB,MAAM,GAAG,CAAS,aAAa,CAAC,CAAC;AAClE,IAAA,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;AACxB;;ACvEA;;AAEG;;;;"}
|
package/fesm2022/mtypes.mjs.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"mtypes.mjs","sources":["../../../../packages/util/mtypes/nav.types.ts","../../../../packages/util/mtypes/page.ts","../../../../packages/util/mtypes/mtypes.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"file":"mtypes.mjs","sources":["../../../../packages/util/mtypes/nav.types.ts","../../../../packages/util/mtypes/page.ts","../../../../packages/util/mtypes/mtypes.ts"],"sourcesContent":["import { YunzaiNavTopic } from './header-menu.type';\n\nexport enum NavType {\n APPLICATION = 'application',\n GROUP = 'group',\n TILE = 'tile'\n}\n\nexport interface LayoutBasicAside {\n name: string;\n intro: string;\n icon: string;\n}\n\nexport interface LayoutBasicDisplay {\n nav: boolean;\n reusetab: boolean;\n aside: boolean;\n}\n\nexport interface LayoutNavApplicationState {\n active: boolean;\n type: 'all' | 'mine' | 'other';\n topic?: YunzaiNavTopic;\n topics: YunzaiNavTopic[];\n list: YunzaiNavTopic[];\n search: string | null;\n}\n\nexport interface LayoutNavGroupState {\n topics: YunzaiNavTopic[];\n}\n","export interface YunzaiPageParam<T> {\n pageNum?: number;\n pageSize?: number;\n pageParam?: T;\n}\n\nconst YUNZAI_PAGE = {\n PAGE_NUM: 1,\n PAGE_SIZE: 1000\n};\n\nexport interface Pageable {\n offset: number;\n pageNumber: number;\n pageSize: number;\n paged: boolean;\n sort: PageableSort;\n unpaged: boolean;\n}\n\nexport interface PageableSort {\n empty: boolean;\n sorted: boolean;\n unsorted: boolean;\n}\n\nexport interface YunzaiPageResult<T> {\n content: T[];\n empty: boolean;\n first: boolean;\n last: boolean;\n number: number;\n numberOfElements: number;\n pageable: Pageable;\n size: number;\n sort: PageableSort;\n totalElements: number;\n totalPages: number;\n}\n\nexport class YunzaiPageBuilder<T extends any | unknown> {\n private page: YunzaiPageParam<T> = {};\n\n public pageNum(pageNum: number): this {\n this.page.pageNum = pageNum;\n return this;\n }\n\n public pageSize(pageSize: number): this {\n this.page.pageSize = pageSize;\n return this;\n }\n\n public pageParam(param: T): this {\n this.page.pageParam = param;\n return this;\n }\n\n public default(): this {\n this.page.pageNum = YUNZAI_PAGE.PAGE_NUM;\n this.page.pageSize = YUNZAI_PAGE.PAGE_SIZE;\n return this;\n }\n\n public build(): YunzaiPageParam<T> {\n return this.page;\n }\n}\n\nexport class Page<T> {\n pageNum = 1;\n pageSize = 30;\n param?: Partial<T>;\n\n private constructor(pageNum: number, pageSize: number, param?: Partial<T>) {\n this.pageNum = pageNum;\n this.pageSize = pageSize;\n this.param = param;\n }\n\n static create<T>(): Page<T> {\n return new Page<T>(1, 30);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":"IAEY,QAIX;AAJD,CAAA,UAAY,OAAO,EAAA;AACjB,IAAA,OAAA,CAAA,aAAA,CAAA,GAAA,aAA2B,CAAA;AAC3B,IAAA,OAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACf,IAAA,OAAA,CAAA,MAAA,CAAA,GAAA,MAAa,CAAA;AACf,CAAC,EAJW,OAAO,KAAP,OAAO,GAIlB,EAAA,CAAA,CAAA;;ACAD,MAAM,WAAW,GAAG;AAClB,IAAA,QAAQ,EAAE,CAAC;AACX,IAAA,SAAS,EAAE,IAAI;CAChB,CAAC;MA+BW,iBAAiB,CAAA;AAA9B,IAAA,WAAA,GAAA;QACU,IAAI,CAAA,IAAA,GAAuB,EAAE,CAAC;KA0BvC;AAxBQ,IAAA,OAAO,CAAC,OAAe,EAAA;AAC5B,QAAA,IAAI,CAAC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;AAC5B,QAAA,OAAO,IAAI,CAAC;KACb;AAEM,IAAA,QAAQ,CAAC,QAAgB,EAAA;AAC9B,QAAA,IAAI,CAAC,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;AAC9B,QAAA,OAAO,IAAI,CAAC;KACb;AAEM,IAAA,SAAS,CAAC,KAAQ,EAAA;AACvB,QAAA,IAAI,CAAC,IAAI,CAAC,SAAS,GAAG,KAAK,CAAC;AAC5B,QAAA,OAAO,IAAI,CAAC;KACb;IAEM,OAAO,GAAA;QACZ,IAAI,CAAC,IAAI,CAAC,OAAO,GAAG,WAAW,CAAC,QAAQ,CAAC;QACzC,IAAI,CAAC,IAAI,CAAC,QAAQ,GAAG,WAAW,CAAC,SAAS,CAAC;AAC3C,QAAA,OAAO,IAAI,CAAC;KACb;IAEM,KAAK,GAAA;QACV,OAAO,IAAI,CAAC,IAAI,CAAC;KAClB;AACF,CAAA;MAEY,IAAI,CAAA;AAKf,IAAA,WAAA,CAAoB,OAAe,EAAE,QAAgB,EAAE,KAAkB,EAAA;QAJzE,IAAO,CAAA,OAAA,GAAG,CAAC,CAAC;QACZ,IAAQ,CAAA,QAAA,GAAG,EAAE,CAAC;AAIZ,QAAA,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;AACvB,QAAA,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;AACzB,QAAA,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;KACpB;AAED,IAAA,OAAO,MAAM,GAAA;AACX,QAAA,OAAO,IAAI,IAAI,CAAI,CAAC,EAAE,EAAE,CAAC,CAAC;KAC3B;AACF;;ACnFD;;AAEG;;;;"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@yelon/util",
|
3
|
-
"version": "16.
|
3
|
+
"version": "16.4.4",
|
4
4
|
"author": "devcui<devcui@outlook.com>",
|
5
5
|
"license": "MIT",
|
6
6
|
"repository": {
|
@@ -53,6 +53,12 @@
|
|
53
53
|
"esm": "./esm2022/browser/browser.mjs",
|
54
54
|
"default": "./fesm2022/browser.mjs"
|
55
55
|
},
|
56
|
+
"./decorator": {
|
57
|
+
"types": "./decorator/index.d.ts",
|
58
|
+
"esm2022": "./esm2022/decorator/decorator.mjs",
|
59
|
+
"esm": "./esm2022/decorator/decorator.mjs",
|
60
|
+
"default": "./fesm2022/decorator.mjs"
|
61
|
+
},
|
56
62
|
"./config": {
|
57
63
|
"types": "./config/index.d.ts",
|
58
64
|
"esm2022": "./esm2022/config/config.mjs",
|
@@ -65,12 +71,6 @@
|
|
65
71
|
"esm": "./esm2022/date-time/date-time.mjs",
|
66
72
|
"default": "./fesm2022/date-time.mjs"
|
67
73
|
},
|
68
|
-
"./decorator": {
|
69
|
-
"types": "./decorator/index.d.ts",
|
70
|
-
"esm2022": "./esm2022/decorator/decorator.mjs",
|
71
|
-
"esm": "./esm2022/decorator/decorator.mjs",
|
72
|
-
"default": "./fesm2022/decorator.mjs"
|
73
|
-
},
|
74
74
|
"./form": {
|
75
75
|
"types": "./form/index.d.ts",
|
76
76
|
"esm2022": "./esm2022/form/form.mjs",
|