@yelon/util 13.5.2 → 14.0.0-beta.0
Sign up to get free protection for your applications and to get access to all the features.
- package/array/array-type.service.d.ts +1 -1
- package/config/abc/date-picker.type.d.ts +1 -1
- package/config/abc/image.type.d.ts +1 -1
- package/config/abc/st.type.d.ts +17 -4
- package/config/auth/auth.type.d.ts +2 -0
- package/date-time/picker.d.ts +1 -1
- package/esm2020/array/array-type.service.mjs +1 -1
- package/esm2020/array/array.service.mjs +4 -4
- package/esm2020/browser/cookie.service.mjs +4 -4
- package/esm2020/browser/scroll.service.mjs +4 -4
- package/esm2020/config/abc/date-picker.type.mjs +1 -1
- package/esm2020/config/abc/image.type.mjs +1 -1
- package/esm2020/config/abc/st.type.mjs +1 -1
- package/esm2020/config/auth/auth.type.mjs +1 -1
- package/esm2020/config/config.service.mjs +5 -4
- package/esm2020/date-time/picker.mjs +1 -1
- package/esm2020/format/currency.service.mjs +4 -4
- package/esm2020/other/lazy.service.mjs +4 -4
- package/esm2020/pipes/currency/cny.pipe.mjs +4 -4
- package/esm2020/pipes/currency/mega.pipe.mjs +4 -4
- package/esm2020/pipes/currency/module.mjs +5 -5
- package/esm2020/pipes/currency/price.pipe.mjs +4 -4
- package/esm2020/pipes/filter/filter.pipe.mjs +4 -4
- package/esm2020/pipes/filter/module.mjs +5 -5
- package/esm2020/pipes/format/mask.pipe.mjs +4 -4
- package/esm2020/pipes/format/module.mjs +5 -5
- package/fesm2015/array.mjs +3 -3
- package/fesm2015/array.mjs.map +1 -1
- package/fesm2015/browser.mjs +6 -6
- package/fesm2015/browser.mjs.map +1 -1
- package/fesm2015/config.mjs +4 -3
- package/fesm2015/config.mjs.map +1 -1
- package/fesm2015/date-time.mjs.map +1 -1
- package/fesm2015/format.mjs +3 -3
- package/fesm2015/format.mjs.map +1 -1
- package/fesm2015/other.mjs +3 -3
- package/fesm2015/other.mjs.map +1 -1
- package/fesm2015/pipe-currency.mjs +13 -13
- package/fesm2015/pipe-currency.mjs.map +1 -1
- package/fesm2015/pipe-filter.mjs +7 -7
- package/fesm2015/pipe-filter.mjs.map +1 -1
- package/fesm2015/pipe-format.mjs +7 -7
- package/fesm2015/pipe-format.mjs.map +1 -1
- package/fesm2020/array.mjs +3 -3
- package/fesm2020/array.mjs.map +1 -1
- package/fesm2020/browser.mjs +6 -6
- package/fesm2020/browser.mjs.map +1 -1
- package/fesm2020/config.mjs +4 -3
- package/fesm2020/config.mjs.map +1 -1
- package/fesm2020/date-time.mjs.map +1 -1
- package/fesm2020/format.mjs +3 -3
- package/fesm2020/format.mjs.map +1 -1
- package/fesm2020/other.mjs +3 -3
- package/fesm2020/other.mjs.map +1 -1
- package/fesm2020/pipe-currency.mjs +13 -13
- package/fesm2020/pipe-currency.mjs.map +1 -1
- package/fesm2020/pipe-filter.mjs +7 -7
- package/fesm2020/pipe-filter.mjs.map +1 -1
- package/fesm2020/pipe-format.mjs +7 -7
- package/fesm2020/pipe-format.mjs.map +1 -1
- package/package.json +17 -17
- package/pipes/currency/cny.pipe.d.ts +1 -1
- package/pipes/currency/mega.pipe.d.ts +1 -1
- package/pipes/currency/price.pipe.d.ts +1 -1
- package/pipes/filter/filter.pipe.d.ts +1 -1
- package/pipes/format/mask.pipe.d.ts +1 -1
- package/array/array.d.ts +0 -5
- package/array/package.json +0 -10
- package/browser/browser.d.ts +0 -5
- package/browser/package.json +0 -10
- package/config/config.d.ts +0 -5
- package/config/package.json +0 -10
- package/date-time/date-time.d.ts +0 -5
- package/date-time/package.json +0 -10
- package/decorator/decorator.d.ts +0 -5
- package/decorator/package.json +0 -10
- package/form/form.d.ts +0 -5
- package/form/package.json +0 -10
- package/format/format.d.ts +0 -5
- package/format/package.json +0 -10
- package/math/math.d.ts +0 -5
- package/math/package.json +0 -10
- package/other/other.d.ts +0 -5
- package/other/package.json +0 -10
- package/pipes/currency/package.json +0 -10
- package/pipes/currency/pipe-currency.d.ts +0 -5
- package/pipes/filter/package.json +0 -10
- package/pipes/filter/pipe-filter.d.ts +0 -5
- package/pipes/format/package.json +0 -10
- package/pipes/format/pipe-format.d.ts +0 -5
- package/pipes/package.json +0 -10
- package/pipes/pipes.d.ts +0 -5
- package/token/package.json +0 -10
- package/token/token.d.ts +0 -5
- package/yelon-util.d.ts +0 -5
package/fesm2020/other.mjs.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"other.mjs","sources":["../../../../packages/util/other/deep.ts","../../../../packages/util/other/logger.ts","../../../../packages/util/other/lazy.service.ts","../../../../packages/util/other/assert.ts","../../../../packages/util/other/url.ts","../../../../packages/util/other/resize.ts","../../../../packages/util/other/other.ts"],"sourcesContent":["import extend from 'extend';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n/**\n * Gets the value at `path` of `object`, like `_.get` in lodash.\n *\n * 类似 `_.get`,根据 `path` 获取安全值\n */\nexport function deepGet(obj: NzSafeAny, path: string | string[] | null | undefined, defaultValue?: unknown): NzSafeAny {\n if (!obj || path == null || path.length === 0) return defaultValue;\n if (!Array.isArray(path)) {\n path = ~path.indexOf('.') ? path.split('.') : [path];\n }\n if (path.length === 1) {\n const checkObj = obj[path[0]];\n return typeof checkObj === 'undefined' ? defaultValue : checkObj;\n }\n const res = path.reduce((o, k) => (o || {})[k], obj);\n return typeof res === 'undefined' ? defaultValue : res;\n}\n\n/**\n * Base on [extend](https://github.com/justmoon/node-extend) deep copy.\n *\n * 基于 [extend](https://github.com/justmoon/node-extend) 的深度拷贝\n */\nexport function deepCopy<T extends { [key: string]: NzSafeAny } = NzSafeAny>(obj: T | null | undefined): T {\n const result = extend(true, {}, { _: obj });\n return result._ as T;\n}\n\n/**\n * Deep merge object.\n *\n * 深度合并对象\n *\n * @param original 原始对象\n * @param arrayProcessMethod 数组处理方式\n * - `true` 表示替换新值,不管新值为哪种类型\n * - `false` 表示会合并整个数组(将旧数据与新数据合并成新数组)\n * @param objects 要合并的对象\n */\nexport function deepMergeKey(original: unknown, arrayProcessMethod: boolean, ...objects: NzSafeAny[]): NzSafeAny {\n if (Array.isArray(original) || typeof original !== 'object') return original;\n\n const isObject = (v: unknown): boolean => typeof v === 'object';\n\n const merge = (target: NzSafeAny, obj: NzSafeAny): NzSafeAny => {\n Object.keys(obj)\n .filter(key => key !== '__proto__' && Object.prototype.hasOwnProperty.call(obj, key))\n .forEach(key => {\n const fromValue = obj[key];\n const toValue = target[key];\n if (Array.isArray(toValue)) {\n target[key] = arrayProcessMethod ? fromValue : [...toValue, ...fromValue];\n } else if (typeof fromValue === 'function') {\n target[key] = fromValue;\n } else if (fromValue != null && isObject(fromValue) && toValue != null && isObject(toValue)) {\n target[key] = merge(toValue, fromValue);\n } else {\n target[key] = deepCopy(fromValue);\n }\n });\n return target;\n };\n\n objects.filter(v => v != null && isObject(v)).forEach(v => merge(original, v));\n\n return original;\n}\n\n/**\n * Deep merge object.\n *\n * 深度合并对象\n */\nexport function deepMerge(original: unknown, ...objects: unknown[]): NzSafeAny {\n return deepMergeKey(original, false, ...objects);\n}\n","import type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\ndeclare const ngDevMode: boolean;\n\nconst record: Record<string, boolean> = {};\n\nexport const PREFIX = '[@YELON]:';\n\nfunction notRecorded(...args: NzSafeAny[]): boolean {\n const asRecord = args.reduce((acc, c) => acc + c.toString(), '');\n\n if (record[asRecord]) {\n return false;\n } else {\n record[asRecord] = true;\n return true;\n }\n}\n\nfunction consoleCommonBehavior(consoleFunc: (...args: NzSafeAny) => void, ...args: NzSafeAny[]): void {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && notRecorded(...args)) {\n consoleFunc(...args);\n }\n}\n\n// Warning should only be printed in dev mode and only once.\nexport const warn = (...args: NzSafeAny[]): void =>\n consoleCommonBehavior((...arg: NzSafeAny[]) => console.warn(PREFIX, ...arg), ...args);\n\nexport const warnDeprecation = (...args: NzSafeAny[]): NzSafeAny => {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n return () => {};\n }\n const stack = new Error().stack;\n return consoleCommonBehavior((...arg: NzSafeAny[]) => console.warn(PREFIX, 'deprecated:', ...arg, stack), ...args);\n};\n\n// Log should only be printed in dev mode.\nexport const log = (...args: NzSafeAny[]): void => {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n console.log(PREFIX, ...args);\n }\n};\n","import { DOCUMENT } from '@angular/common';\nimport { Inject, Injectable } from '@angular/core';\nimport { BehaviorSubject, Observable, filter, share } from 'rxjs';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport interface LazyResult {\n path: string;\n status: 'ok' | 'error' | 'loading';\n error?: NzSafeAny;\n}\n\n/**\n * 延迟加载资源(js 或 css)服务\n */\n@Injectable({ providedIn: 'root' })\nexport class LazyService {\n private list: { [key: string]: boolean } = {};\n private cached: { [key: string]: LazyResult } = {};\n private _notify: BehaviorSubject<LazyResult[]> = new BehaviorSubject<LazyResult[]>([]);\n\n constructor(@Inject(DOCUMENT) private doc: NzSafeAny) {}\n\n get change(): Observable<LazyResult[]> {\n return this._notify.asObservable().pipe(\n share(),\n filter(ls => ls.length !== 0)\n );\n }\n\n clear(): void {\n this.list = {};\n this.cached = {};\n }\n\n load(paths: string | string[]): Promise<LazyResult[]> {\n if (!Array.isArray(paths)) {\n paths = [paths];\n }\n\n const promises: Array<Promise<LazyResult>> = [];\n paths.forEach(path => {\n if (path.endsWith('.js')) {\n promises.push(this.loadScript(path));\n } else {\n promises.push(this.loadStyle(path));\n }\n });\n\n return Promise.all(promises).then(res => {\n this._notify.next(res);\n return Promise.resolve(res);\n });\n }\n\n loadScript(path: string, innerContent?: string): Promise<LazyResult> {\n return new Promise(resolve => {\n if (this.list[path] === true) {\n resolve({ ...this.cached[path], status: 'loading' });\n return;\n }\n\n this.list[path] = true;\n const onSuccess = (item: LazyResult): void => {\n this.cached[path] = item;\n resolve(item);\n this._notify.next([item]);\n };\n\n const node = this.doc.createElement('script') as HTMLScriptElement;\n node.type = 'text/javascript';\n node.src = path;\n if (innerContent) {\n node.innerHTML = innerContent;\n }\n node.onload = () =>\n onSuccess({\n path,\n status: 'ok'\n });\n node.onerror = error =>\n onSuccess({\n path,\n status: 'error',\n error\n });\n this.doc.getElementsByTagName('head')[0].appendChild(node);\n });\n }\n\n loadStyle(path: string, rel: string = 'stylesheet', innerContent?: string): Promise<LazyResult> {\n return new Promise(resolve => {\n if (this.list[path] === true) {\n resolve(this.cached[path]);\n return;\n }\n\n this.list[path] = true;\n\n const node = this.doc.createElement('link') as HTMLLinkElement;\n node.rel = rel;\n node.type = 'text/css';\n node.href = path;\n if (innerContent) {\n node.innerHTML = innerContent;\n }\n this.doc.getElementsByTagName('head')[0].appendChild(node);\n const item: LazyResult = {\n path,\n status: 'ok'\n };\n this.cached[path] = item;\n resolve(item);\n });\n }\n}\n","import { isObservable } from 'rxjs';\n\ndeclare const ngDevMode: boolean;\n\nfunction throwError(msg: string | null | undefined): void;\nfunction throwError(msg: string | null | undefined, actual: unknown, expected: unknown, comparison: string): void;\nfunction throwError(msg: string | null | undefined, actual?: unknown, expected?: unknown, comparison?: string): void {\n if (ngDevMode) {\n throw new Error(\n `ASSERTION ERROR: ${msg}${comparison == null ? '' : ` [Expected=> ${expected} ${comparison} ${actual} <=Actual]`}`\n );\n }\n}\n\n/**\n * Assert whether the expression and throw an error into console in dev mode\n *\n * 断言表达式是否符合预期,并在开发模式下会在控制台抛出一个错误\n */\nexport function assert(expression: boolean, msg?: string): void {\n if (!expression) {\n throwError(msg);\n }\n}\n\n/**\n * Assert whether empty (`null` or `undefined`)\n *\n * 断言是否空值(`null` 或 `undefined`)\n */\nexport function assertEmpty(actual: unknown, msg?: string): void {\n if (actual == null) {\n throwError(msg, typeof actual, 'NULL', '==');\n }\n}\n\n/**\n * Assert whether `number` type\n *\n * 断言是否 `number` 类型\n */\nexport function assertNumber(actual: unknown, msg?: string): void {\n if (!(typeof actual === 'number')) {\n throwError(msg, typeof actual, 'number', '===');\n }\n}\n\n/**\n * Assert whether `string` type\n *\n * 断言是否 `string` 类型\n */\nexport function assertString(actual: unknown, msg?: string): void {\n if (!(typeof actual === 'string')) {\n throwError(msg, actual === null ? 'null' : typeof actual, 'string', '===');\n }\n}\n\n/**\n * Assert whether `array` type\n *\n * 断言是否 `array` 类型\n */\nexport function assertArray(actual: unknown, msg?: string): void {\n if (!Array.isArray(actual)) {\n throwError(msg, actual === null ? 'null' : typeof actual, 'array', '===');\n }\n}\n\n/**\n * Assert whether `Observable` type\n *\n * 断言是否 `Observable` 类型\n */\nexport function assertObservable(obj: unknown, msg?: string): void {\n if (!isObservable(obj)) {\n throwError(msg, obj === null ? 'null' : typeof obj, 'Observable', '===');\n }\n}\n","import { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport function getUrlParam(url: NzSafeAny, name: string): string | null {\n try {\n var reg = new RegExp(`(^|&)${name}=([^&]*)(&|$)`);\n var r = url.split('?')[1].match(reg);\n if (r != null) return unescape(r[2]);\n } catch (e) {\n return null;\n }\n return null;\n}\n","export const resizeWindow = (): void => {\n window.dispatchEvent(new Event('resize'));\n};\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AAIA;;;;AAIG;SACa,OAAO,CAAC,GAAc,EAAE,IAA0C,EAAE,YAAsB,EAAA;IACxG,IAAI,CAAC,GAAG,IAAI,IAAI,IAAI,IAAI,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC;AAAE,QAAA,OAAO,YAAY,CAAC;AACnE,IAAA,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE;QACxB,IAAI,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;AACtD,KAAA;AACD,IAAA,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;QACrB,MAAM,QAAQ,GAAG,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;AAC9B,QAAA,OAAO,OAAO,QAAQ,KAAK,WAAW,GAAG,Y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AAC,IAAI,IAAI;AAAE,YAAA,OAAO,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACtC,KAAA;AAAC,IAAA,OAAO,CAAC,EAAE;AACV,QAAA,OAAO,IAAI,CAAC;AACb,KAAA;AACD,IAAA,OAAO,IAAI,CAAC;AACd;;ACXO,MAAM,YAAY,GAAG,MAAW;IACrC,MAAM,CAAC,aAAa,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC;AAC5C;;ACFA;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"other.mjs","sources":["../../../../packages/util/other/deep.ts","../../../../packages/util/other/logger.ts","../../../../packages/util/other/lazy.service.ts","../../../../packages/util/other/assert.ts","../../../../packages/util/other/url.ts","../../../../packages/util/other/resize.ts","../../../../packages/util/other/other.ts"],"sourcesContent":["import extend from 'extend';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n/**\n * Gets the value at `path` of `object`, like `_.get` in lodash.\n *\n * 类似 `_.get`,根据 `path` 获取安全值\n */\nexport function deepGet(obj: NzSafeAny, path: string | string[] | null | undefined, defaultValue?: unknown): NzSafeAny {\n if (!obj || path == null || path.length === 0) return defaultValue;\n if (!Array.isArray(path)) {\n path = ~path.indexOf('.') ? path.split('.') : [path];\n }\n if (path.length === 1) {\n const checkObj = obj[path[0]];\n return typeof checkObj === 'undefined' ? defaultValue : checkObj;\n }\n const res = path.reduce((o, k) => (o || {})[k], obj);\n return typeof res === 'undefined' ? defaultValue : res;\n}\n\n/**\n * Base on [extend](https://github.com/justmoon/node-extend) deep copy.\n *\n * 基于 [extend](https://github.com/justmoon/node-extend) 的深度拷贝\n */\nexport function deepCopy<T extends { [key: string]: NzSafeAny } = NzSafeAny>(obj: T | null | undefined): T {\n const result = extend(true, {}, { _: obj });\n return result._ as T;\n}\n\n/**\n * Deep merge object.\n *\n * 深度合并对象\n *\n * @param original 原始对象\n * @param arrayProcessMethod 数组处理方式\n * - `true` 表示替换新值,不管新值为哪种类型\n * - `false` 表示会合并整个数组(将旧数据与新数据合并成新数组)\n * @param objects 要合并的对象\n */\nexport function deepMergeKey(original: unknown, arrayProcessMethod: boolean, ...objects: NzSafeAny[]): NzSafeAny {\n if (Array.isArray(original) || typeof original !== 'object') return original;\n\n const isObject = (v: unknown): boolean => typeof v === 'object';\n\n const merge = (target: NzSafeAny, obj: NzSafeAny): NzSafeAny => {\n Object.keys(obj)\n .filter(key => key !== '__proto__' && Object.prototype.hasOwnProperty.call(obj, key))\n .forEach(key => {\n const fromValue = obj[key];\n const toValue = target[key];\n if (Array.isArray(toValue)) {\n target[key] = arrayProcessMethod ? fromValue : [...toValue, ...fromValue];\n } else if (typeof fromValue === 'function') {\n target[key] = fromValue;\n } else if (fromValue != null && isObject(fromValue) && toValue != null && isObject(toValue)) {\n target[key] = merge(toValue, fromValue);\n } else {\n target[key] = deepCopy(fromValue);\n }\n });\n return target;\n };\n\n objects.filter(v => v != null && isObject(v)).forEach(v => merge(original, v));\n\n return original;\n}\n\n/**\n * Deep merge object.\n *\n * 深度合并对象\n */\nexport function deepMerge(original: unknown, ...objects: unknown[]): NzSafeAny {\n return deepMergeKey(original, false, ...objects);\n}\n","import type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\ndeclare const ngDevMode: boolean;\n\nconst record: Record<string, boolean> = {};\n\nexport const PREFIX = '[@YELON]:';\n\nfunction notRecorded(...args: NzSafeAny[]): boolean {\n const asRecord = args.reduce((acc, c) => acc + c.toString(), '');\n\n if (record[asRecord]) {\n return false;\n } else {\n record[asRecord] = true;\n return true;\n }\n}\n\nfunction consoleCommonBehavior(consoleFunc: (...args: NzSafeAny) => void, ...args: NzSafeAny[]): void {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && notRecorded(...args)) {\n consoleFunc(...args);\n }\n}\n\n// Warning should only be printed in dev mode and only once.\nexport const warn = (...args: NzSafeAny[]): void =>\n consoleCommonBehavior((...arg: NzSafeAny[]) => console.warn(PREFIX, ...arg), ...args);\n\nexport const warnDeprecation = (...args: NzSafeAny[]): NzSafeAny => {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n return () => {};\n }\n const stack = new Error().stack;\n return consoleCommonBehavior((...arg: NzSafeAny[]) => console.warn(PREFIX, 'deprecated:', ...arg, stack), ...args);\n};\n\n// Log should only be printed in dev mode.\nexport const log = (...args: NzSafeAny[]): void => {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n console.log(PREFIX, ...args);\n }\n};\n","import { DOCUMENT } from '@angular/common';\nimport { Inject, Injectable } from '@angular/core';\nimport { BehaviorSubject, Observable, filter, share } from 'rxjs';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport interface LazyResult {\n path: string;\n status: 'ok' | 'error' | 'loading';\n error?: NzSafeAny;\n}\n\n/**\n * 延迟加载资源(js 或 css)服务\n */\n@Injectable({ providedIn: 'root' })\nexport class LazyService {\n private list: { [key: string]: boolean } = {};\n private cached: { [key: string]: LazyResult } = {};\n private _notify: BehaviorSubject<LazyResult[]> = new BehaviorSubject<LazyResult[]>([]);\n\n constructor(@Inject(DOCUMENT) private doc: NzSafeAny) {}\n\n get change(): Observable<LazyResult[]> {\n return this._notify.asObservable().pipe(\n share(),\n filter(ls => ls.length !== 0)\n );\n }\n\n clear(): void {\n this.list = {};\n this.cached = {};\n }\n\n load(paths: string | string[]): Promise<LazyResult[]> {\n if (!Array.isArray(paths)) {\n paths = [paths];\n }\n\n const promises: Array<Promise<LazyResult>> = [];\n paths.forEach(path => {\n if (path.endsWith('.js')) {\n promises.push(this.loadScript(path));\n } else {\n promises.push(this.loadStyle(path));\n }\n });\n\n return Promise.all(promises).then(res => {\n this._notify.next(res);\n return Promise.resolve(res);\n });\n }\n\n loadScript(path: string, innerContent?: string): Promise<LazyResult> {\n return new Promise(resolve => {\n if (this.list[path] === true) {\n resolve({ ...this.cached[path], status: 'loading' });\n return;\n }\n\n this.list[path] = true;\n const onSuccess = (item: LazyResult): void => {\n this.cached[path] = item;\n resolve(item);\n this._notify.next([item]);\n };\n\n const node = this.doc.createElement('script') as HTMLScriptElement;\n node.type = 'text/javascript';\n node.src = path;\n if (innerContent) {\n node.innerHTML = innerContent;\n }\n node.onload = () =>\n onSuccess({\n path,\n status: 'ok'\n });\n node.onerror = error =>\n onSuccess({\n path,\n status: 'error',\n error\n });\n this.doc.getElementsByTagName('head')[0].appendChild(node);\n });\n }\n\n loadStyle(path: string, rel: string = 'stylesheet', innerContent?: string): Promise<LazyResult> {\n return new Promise(resolve => {\n if (this.list[path] === true) {\n resolve(this.cached[path]);\n return;\n }\n\n this.list[path] = true;\n\n const node = this.doc.createElement('link') as HTMLLinkElement;\n node.rel = rel;\n node.type = 'text/css';\n node.href = path;\n if (innerContent) {\n node.innerHTML = innerContent;\n }\n this.doc.getElementsByTagName('head')[0].appendChild(node);\n const item: LazyResult = {\n path,\n status: 'ok'\n };\n this.cached[path] = item;\n resolve(item);\n });\n }\n}\n","import { isObservable } from 'rxjs';\n\ndeclare const ngDevMode: boolean;\n\nfunction throwError(msg: string | null | undefined): void;\nfunction throwError(msg: string | null | undefined, actual: unknown, expected: unknown, comparison: string): void;\nfunction throwError(msg: string | null | undefined, actual?: unknown, expected?: unknown, comparison?: string): void {\n if (ngDevMode) {\n throw new Error(\n `ASSERTION ERROR: ${msg}${comparison == null ? '' : ` [Expected=> ${expected} ${comparison} ${actual} <=Actual]`}`\n );\n }\n}\n\n/**\n * Assert whether the expression and throw an error into console in dev mode\n *\n * 断言表达式是否符合预期,并在开发模式下会在控制台抛出一个错误\n */\nexport function assert(expression: boolean, msg?: string): void {\n if (!expression) {\n throwError(msg);\n }\n}\n\n/**\n * Assert whether empty (`null` or `undefined`)\n *\n * 断言是否空值(`null` 或 `undefined`)\n */\nexport function assertEmpty(actual: unknown, msg?: string): void {\n if (actual == null) {\n throwError(msg, typeof actual, 'NULL', '==');\n }\n}\n\n/**\n * Assert whether `number` type\n *\n * 断言是否 `number` 类型\n */\nexport function assertNumber(actual: unknown, msg?: string): void {\n if (!(typeof actual === 'number')) {\n throwError(msg, typeof actual, 'number', '===');\n }\n}\n\n/**\n * Assert whether `string` type\n *\n * 断言是否 `string` 类型\n */\nexport function assertString(actual: unknown, msg?: string): void {\n if (!(typeof actual === 'string')) {\n throwError(msg, actual === null ? 'null' : typeof actual, 'string', '===');\n }\n}\n\n/**\n * Assert whether `array` type\n *\n * 断言是否 `array` 类型\n */\nexport function assertArray(actual: unknown, msg?: string): void {\n if (!Array.isArray(actual)) {\n throwError(msg, actual === null ? 'null' : typeof actual, 'array', '===');\n }\n}\n\n/**\n * Assert whether `Observable` type\n *\n * 断言是否 `Observable` 类型\n */\nexport function assertObservable(obj: unknown, msg?: string): void {\n if (!isObservable(obj)) {\n throwError(msg, obj === null ? 'null' : typeof obj, 'Observable', '===');\n }\n}\n","import { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport function getUrlParam(url: NzSafeAny, name: string): string | null {\n try {\n var reg = new RegExp(`(^|&)${name}=([^&]*)(&|$)`);\n var r = url.split('?')[1].match(reg);\n if (r != null) return unescape(r[2]);\n } catch (e) {\n return null;\n }\n return null;\n}\n","export const resizeWindow = (): void => {\n window.dispatchEvent(new Event('resize'));\n};\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AAIA;;;;AAIG;SACa,OAAO,CAAC,GAAc,EAAE,IAA0C,EAAE,YAAsB,EAAA;IACxG,IAAI,CAAC,GAAG,IAAI,IAAI,IAAI,IAAI,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC;AAAE,QAAA,OAAO,YAAY,CAAC;AACnE,IAAA,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE;QACxB,IAAI,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;AACtD,KAAA;AACD,IAAA,IAAI,IA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,aAAA,CAAA,CAAC,CAAC;AAClD,QAAA,IAAI,CAAC,GAAG,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACrC,IAAI,CAAC,IAAI,IAAI;AAAE,YAAA,OAAO,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACtC,KAAA;AAAC,IAAA,OAAO,CAAC,EAAE;AACV,QAAA,OAAO,IAAI,CAAC;AACb,KAAA;AACD,IAAA,OAAO,IAAI,CAAC;AACd;;ACXO,MAAM,YAAY,GAAG,MAAW;IACrC,MAAM,CAAC,aAAa,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC;AAC5C;;ACFA;;AAEG;;;;"}
|
@@ -18,9 +18,9 @@ class CurrencyMegaPipe {
|
|
18
18
|
return res.value + (this.isCN ? res.unitI18n : res.unit);
|
19
19
|
}
|
20
20
|
}
|
21
|
-
CurrencyMegaPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
22
|
-
CurrencyMegaPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "
|
23
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
21
|
+
CurrencyMegaPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyMegaPipe, deps: [{ token: i1.CurrencyService }, { token: LOCALE_ID }], target: i0.ɵɵFactoryTarget.Pipe });
|
22
|
+
CurrencyMegaPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: CurrencyMegaPipe, name: "mega" });
|
23
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyMegaPipe, decorators: [{
|
24
24
|
type: Pipe,
|
25
25
|
args: [{ name: 'mega' }]
|
26
26
|
}], ctorParameters: function () { return [{ type: i1.CurrencyService }, { type: undefined, decorators: [{
|
@@ -45,9 +45,9 @@ class CurrencyPricePipe {
|
|
45
45
|
return this.srv.format(value, options);
|
46
46
|
}
|
47
47
|
}
|
48
|
-
CurrencyPricePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
49
|
-
CurrencyPricePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "
|
50
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
48
|
+
CurrencyPricePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyPricePipe, deps: [{ token: i1.CurrencyService }], target: i0.ɵɵFactoryTarget.Pipe });
|
49
|
+
CurrencyPricePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: CurrencyPricePipe, name: "price" });
|
50
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyPricePipe, decorators: [{
|
51
51
|
type: Pipe,
|
52
52
|
args: [{ name: 'price' }]
|
53
53
|
}], ctorParameters: function () { return [{ type: i1.CurrencyService }]; } });
|
@@ -65,9 +65,9 @@ class CurrencyCNYPipe {
|
|
65
65
|
return this.srv.cny(value, options);
|
66
66
|
}
|
67
67
|
}
|
68
|
-
CurrencyCNYPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
69
|
-
CurrencyCNYPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "
|
70
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
68
|
+
CurrencyCNYPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyCNYPipe, deps: [{ token: i1.CurrencyService }], target: i0.ɵɵFactoryTarget.Pipe });
|
69
|
+
CurrencyCNYPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: CurrencyCNYPipe, name: "cny" });
|
70
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyCNYPipe, decorators: [{
|
71
71
|
type: Pipe,
|
72
72
|
args: [{ name: 'cny' }]
|
73
73
|
}], ctorParameters: function () { return [{ type: i1.CurrencyService }]; } });
|
@@ -75,10 +75,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
75
75
|
const PIPES = [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe];
|
76
76
|
class CurrencyPipeModule {
|
77
77
|
}
|
78
|
-
CurrencyPipeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
79
|
-
CurrencyPipeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "
|
80
|
-
CurrencyPipeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
81
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
78
|
+
CurrencyPipeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
79
|
+
CurrencyPipeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: CurrencyPipeModule, declarations: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe], exports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe] });
|
80
|
+
CurrencyPipeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyPipeModule });
|
81
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: CurrencyPipeModule, decorators: [{
|
82
82
|
type: NgModule,
|
83
83
|
args: [{
|
84
84
|
declarations: PIPES,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"pipe-currency.mjs","sources":["../../../../packages/util/pipes/currency/mega.pipe.ts","../../../../packages/util/pipes/currency/price.pipe.ts","../../../../packages/util/pipes/currency/cny.pipe.ts","../../../../packages/util/pipes/currency/module.ts","../../../../packages/util/pipes/currency/pipe-currency.ts"],"sourcesContent":["import { Inject, LOCALE_ID, Pipe, PipeTransform } from '@angular/core';\n\nimport { CurrencyMegaOptions, CurrencyService } from '@yelon/util/format';\n\n@Pipe({ name: 'mega' })\nexport class CurrencyMegaPipe implements PipeTransform {\n private isCN = false;\n constructor(private srv: CurrencyService, @Inject(LOCALE_ID) locale: string) {\n this.isCN = locale.startsWith('zh');\n }\n\n /**\n * Large number format filter\n *\n * 大数据格式化\n */\n transform(value: number | string, options?: CurrencyMegaOptions): string {\n const res = this.srv.mega(value, options);\n return res.value + (this.isCN ? res.unitI18n : res.unit);\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n\nimport { CurrencyFormatOptions, CurrencyService } from '@yelon/util/format';\n\n@Pipe({ name: 'price' })\nexport class CurrencyPricePipe implements PipeTransform {\n constructor(private srv: CurrencyService) {}\n /**\n * Format a number with commas as thousands separators\n *\n * 格式化货币,用逗号将数字格式化为千位分隔符\n * ```ts\n * 10000 => `10,000`\n * 10000.567 => `10,000.57`\n * ```\n */\n transform(value: number | string, options?: CurrencyFormatOptions): string {\n return this.srv.format(value, options);\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n\nimport { CurrencyCNYOptions, CurrencyService } from '@yelon/util/format';\n\n@Pipe({ name: 'cny' })\nexport class CurrencyCNYPipe implements PipeTransform {\n constructor(private srv: CurrencyService) {}\n\n /**\n * Converted into RMB notation.\n *\n * 转化成人民币表示法\n */\n transform(value: number | string, options?: CurrencyCNYOptions): string {\n return this.srv.cny(value, options);\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { CurrencyCNYPipe } from './cny.pipe';\nimport { CurrencyMegaPipe } from './mega.pipe';\nimport { CurrencyPricePipe } from './price.pipe';\n\nconst PIPES = [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe];\n\n@NgModule({\n declarations: PIPES,\n exports: PIPES\n})\nexport class CurrencyPipeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MAKa,gBAAgB,CAAA;IAE3B,WAAoB,CAAA,GAAoB,EAAqB,MAAc,EAAA;QAAvD,IAAG,CAAA,GAAA,GAAH,GAAG,CAAiB;QADhC,IAAI,CAAA,IAAA,GAAG,KAAK,CAAC;QAEnB,IAAI,CAAC,IAAI,GAAG,MAAM,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;KACrC;AAED;;;;AAIG;IACH,SAAS,CAAC,KAAsB,EAAE,OAA6B,EAAA;AAC7D,QAAA,MAAM,GAAG,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;QAC1C,OAAO,GAAG,CAAC,KAAK,IAAI,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC,QAAQ,GAAG,GAAG,CAAC,IAAI,CAAC,CAAC;KAC1D;;AAdU,gBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,
|
1
|
+
{"version":3,"file":"pipe-currency.mjs","sources":["../../../../packages/util/pipes/currency/mega.pipe.ts","../../../../packages/util/pipes/currency/price.pipe.ts","../../../../packages/util/pipes/currency/cny.pipe.ts","../../../../packages/util/pipes/currency/module.ts","../../../../packages/util/pipes/currency/pipe-currency.ts"],"sourcesContent":["import { Inject, LOCALE_ID, Pipe, PipeTransform } from '@angular/core';\n\nimport { CurrencyMegaOptions, CurrencyService } from '@yelon/util/format';\n\n@Pipe({ name: 'mega' })\nexport class CurrencyMegaPipe implements PipeTransform {\n private isCN = false;\n constructor(private srv: CurrencyService, @Inject(LOCALE_ID) locale: string) {\n this.isCN = locale.startsWith('zh');\n }\n\n /**\n * Large number format filter\n *\n * 大数据格式化\n */\n transform(value: number | string, options?: CurrencyMegaOptions): string {\n const res = this.srv.mega(value, options);\n return res.value + (this.isCN ? res.unitI18n : res.unit);\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n\nimport { CurrencyFormatOptions, CurrencyService } from '@yelon/util/format';\n\n@Pipe({ name: 'price' })\nexport class CurrencyPricePipe implements PipeTransform {\n constructor(private srv: CurrencyService) {}\n /**\n * Format a number with commas as thousands separators\n *\n * 格式化货币,用逗号将数字格式化为千位分隔符\n * ```ts\n * 10000 => `10,000`\n * 10000.567 => `10,000.57`\n * ```\n */\n transform(value: number | string, options?: CurrencyFormatOptions): string {\n return this.srv.format(value, options);\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n\nimport { CurrencyCNYOptions, CurrencyService } from '@yelon/util/format';\n\n@Pipe({ name: 'cny' })\nexport class CurrencyCNYPipe implements PipeTransform {\n constructor(private srv: CurrencyService) {}\n\n /**\n * Converted into RMB notation.\n *\n * 转化成人民币表示法\n */\n transform(value: number | string, options?: CurrencyCNYOptions): string {\n return this.srv.cny(value, options);\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { CurrencyCNYPipe } from './cny.pipe';\nimport { CurrencyMegaPipe } from './mega.pipe';\nimport { CurrencyPricePipe } from './price.pipe';\n\nconst PIPES = [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe];\n\n@NgModule({\n declarations: PIPES,\n exports: PIPES\n})\nexport class CurrencyPipeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MAKa,gBAAgB,CAAA;IAE3B,WAAoB,CAAA,GAAoB,EAAqB,MAAc,EAAA;QAAvD,IAAG,CAAA,GAAA,GAAH,GAAG,CAAiB;QADhC,IAAI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ACR,oBAAA,YAAY,EAAE,KAAK;AACnB,oBAAA,OAAO,EAAE,KAAK;AACf,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
|
package/fesm2020/pipe-filter.mjs
CHANGED
@@ -11,9 +11,9 @@ class FilterPipe {
|
|
11
11
|
return array.filter(i => matcher(i, ...args));
|
12
12
|
}
|
13
13
|
}
|
14
|
-
FilterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
15
|
-
FilterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "
|
16
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
14
|
+
FilterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FilterPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
15
|
+
FilterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: FilterPipe, name: "filter" });
|
16
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FilterPipe, decorators: [{
|
17
17
|
type: Pipe,
|
18
18
|
args: [{ name: 'filter' }]
|
19
19
|
}] });
|
@@ -21,10 +21,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
21
21
|
const PIPES = [FilterPipe];
|
22
22
|
class FilterPipeModule {
|
23
23
|
}
|
24
|
-
FilterPipeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
25
|
-
FilterPipeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "
|
26
|
-
FilterPipeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
27
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
24
|
+
FilterPipeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FilterPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
25
|
+
FilterPipeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: FilterPipeModule, declarations: [FilterPipe], exports: [FilterPipe] });
|
26
|
+
FilterPipeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FilterPipeModule });
|
27
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FilterPipeModule, decorators: [{
|
28
28
|
type: NgModule,
|
29
29
|
args: [{
|
30
30
|
declarations: PIPES,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"pipe-filter.mjs","sources":["../../../../packages/util/pipes/filter/filter.pipe.ts","../../../../packages/util/pipes/filter/module.ts","../../../../packages/util/pipes/filter/pipe-filter.ts"],"sourcesContent":["import { Pipe, PipeTransform } from '@angular/core';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n@Pipe({ name: 'filter' })\nexport class FilterPipe implements PipeTransform {\n /**\n * Filter array\n *\n * 过滤数组\n */\n transform<T>(array: readonly T[], matcher: (item: T, ...args: NzSafeAny[]) => boolean, ...args: NzSafeAny[]): T[] {\n return array.filter(i => matcher(i, ...args));\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { FilterPipe } from './filter.pipe';\n\nconst PIPES = [FilterPipe];\n\n@NgModule({\n declarations: PIPES,\n exports: PIPES\n})\nexport class FilterPipeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAKa,UAAU,CAAA;AACrB;;;;AAIG;AACH,IAAA,SAAS,CAAI,KAAmB,EAAE,OAAmD,EAAE,GAAG,IAAiB,EAAA;AACzG,QAAA,OAAO,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,OAAO,CAAC,CAAC,EAAE,GAAG,IAAI,CAAC,CAAC,CAAC;KAC/C;;
|
1
|
+
{"version":3,"file":"pipe-filter.mjs","sources":["../../../../packages/util/pipes/filter/filter.pipe.ts","../../../../packages/util/pipes/filter/module.ts","../../../../packages/util/pipes/filter/pipe-filter.ts"],"sourcesContent":["import { Pipe, PipeTransform } from '@angular/core';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n@Pipe({ name: 'filter' })\nexport class FilterPipe implements PipeTransform {\n /**\n * Filter array\n *\n * 过滤数组\n */\n transform<T>(array: readonly T[], matcher: (item: T, ...args: NzSafeAny[]) => boolean, ...args: NzSafeAny[]): T[] {\n return array.filter(i => matcher(i, ...args));\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { FilterPipe } from './filter.pipe';\n\nconst PIPES = [FilterPipe];\n\n@NgModule({\n declarations: PIPES,\n exports: PIPES\n})\nexport class FilterPipeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAKa,UAAU,CAAA;AACrB;;;;AAIG;AACH,IAAA,SAAS,CAAI,KAAmB,EAAE,OAAmD,EAAE,GAAG,IAAiB,EAAA;AACzG,QAAA,OAAO,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,OAAO,CAAC,CAAC,EAAE,GAAG,IAAI,CAAC,CAAC,CAAC;KAC/C;;uGARU,UAAU,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,IAAA,EAAA,CAAA,CAAA;qGAAV,UAAU,EAAA,IAAA,EAAA,QAAA,EAAA,CAAA,CAAA;2FAAV,UAAU,EAAA,UAAA,EAAA,CAAA;kBADtB,IAAI;mBAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAA;;;ACAxB,MAAM,KAAK,GAAG,CAAC,UAAU,CAAC,CAAC;MAMd,gBAAgB,CAAA;;6GAAhB,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;8GAAhB,gBAAgB,EAAA,YAAA,EAAA,CANd,UAAU,CAAA,EAAA,OAAA,EAAA,CAAV,UAAU,CAAA,EAAA,CAAA,CAAA;8GAMZ,gBAAgB,EAAA,CAAA,CAAA;2FAAhB,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAJ5B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,KAAK;AACnB,oBAAA,OAAO,EAAE,KAAK;AACf,iBAAA,CAAA;;;ACTD;;AAEG;;;;"}
|
package/fesm2020/pipe-format.mjs
CHANGED
@@ -26,9 +26,9 @@ class FormatMaskPipe {
|
|
26
26
|
return formatMask(value, mask);
|
27
27
|
}
|
28
28
|
}
|
29
|
-
FormatMaskPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
30
|
-
FormatMaskPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
29
|
+
FormatMaskPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FormatMaskPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
30
|
+
FormatMaskPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: FormatMaskPipe, name: "mask" });
|
31
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FormatMaskPipe, decorators: [{
|
32
32
|
type: Pipe,
|
33
33
|
args: [{ name: 'mask' }]
|
34
34
|
}] });
|
@@ -36,10 +36,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
36
36
|
const PIPES = [FormatMaskPipe];
|
37
37
|
class FormatPipeModule {
|
38
38
|
}
|
39
|
-
FormatPipeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
40
|
-
FormatPipeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "
|
41
|
-
FormatPipeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
42
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
39
|
+
FormatPipeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FormatPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
40
|
+
FormatPipeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: FormatPipeModule, declarations: [FormatMaskPipe], exports: [FormatMaskPipe] });
|
41
|
+
FormatPipeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FormatPipeModule });
|
42
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FormatPipeModule, decorators: [{
|
43
43
|
type: NgModule,
|
44
44
|
args: [{
|
45
45
|
declarations: PIPES,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"pipe-format.mjs","sources":["../../../../packages/util/pipes/format/mask.pipe.ts","../../../../packages/util/pipes/format/module.ts","../../../../packages/util/pipes/format/pipe-format.ts"],"sourcesContent":["import { Pipe, PipeTransform } from '@angular/core';\n\nimport { formatMask, FormatMaskOption } from '@yelon/util/format';\n\n@Pipe({ name: 'mask' })\nexport class FormatMaskPipe implements PipeTransform {\n /**\n * Format mask\n *\n * 格式化掩码\n *\n * | 字符 | 描述 |\n * | --- | --- |\n * | `0` | 任意数字,若该位置字符不符合,则默认为 `0` 填充 |\n * | `9` | 任意数字 |\n * | `#` | 任意字符 |\n * | `U` | 转换大写 |\n * | `L` | 转换小写 |\n * | `*` | 转换为 `*` 字符 |\n *\n * ```ts\n * formatMask('123', '(###)') => (123)\n * formatMask('15900000000', '999****9999') => 159****0000\n * ```\n */\n transform(value: string, mask: string | FormatMaskOption): string {\n return formatMask(value, mask);\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { FormatMaskPipe } from './mask.pipe';\n\nconst PIPES = [FormatMaskPipe];\n\n@NgModule({\n declarations: PIPES,\n exports: PIPES\n})\nexport class FormatPipeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MAKa,cAAc,CAAA;AACzB;;;;;;;;;;;;;;;;;;AAkBG;IACH,SAAS,CAAC,KAAa,EAAE,IAA+B,EAAA;AACtD,QAAA,OAAO,UAAU,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;KAChC;;
|
1
|
+
{"version":3,"file":"pipe-format.mjs","sources":["../../../../packages/util/pipes/format/mask.pipe.ts","../../../../packages/util/pipes/format/module.ts","../../../../packages/util/pipes/format/pipe-format.ts"],"sourcesContent":["import { Pipe, PipeTransform } from '@angular/core';\n\nimport { formatMask, FormatMaskOption } from '@yelon/util/format';\n\n@Pipe({ name: 'mask' })\nexport class FormatMaskPipe implements PipeTransform {\n /**\n * Format mask\n *\n * 格式化掩码\n *\n * | 字符 | 描述 |\n * | --- | --- |\n * | `0` | 任意数字,若该位置字符不符合,则默认为 `0` 填充 |\n * | `9` | 任意数字 |\n * | `#` | 任意字符 |\n * | `U` | 转换大写 |\n * | `L` | 转换小写 |\n * | `*` | 转换为 `*` 字符 |\n *\n * ```ts\n * formatMask('123', '(###)') => (123)\n * formatMask('15900000000', '999****9999') => 159****0000\n * ```\n */\n transform(value: string, mask: string | FormatMaskOption): string {\n return formatMask(value, mask);\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { FormatMaskPipe } from './mask.pipe';\n\nconst PIPES = [FormatMaskPipe];\n\n@NgModule({\n declarations: PIPES,\n exports: PIPES\n})\nexport class FormatPipeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MAKa,cAAc,CAAA;AACzB;;;;;;;;;;;;;;;;;;AAkBG;IACH,SAAS,CAAC,KAAa,EAAE,IAA+B,EAAA;AACtD,QAAA,OAAO,UAAU,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;KAChC;;2GAtBU,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,IAAA,EAAA,CAAA,CAAA;yGAAd,cAAc,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,CAAA;2FAAd,cAAc,EAAA,UAAA,EAAA,CAAA;kBAD1B,IAAI;mBAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAA;;;ACAtB,MAAM,KAAK,GAAG,CAAC,cAAc,CAAC,CAAC;MAMlB,gBAAgB,CAAA;;6GAAhB,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;8GAAhB,gBAAgB,EAAA,YAAA,EAAA,CANd,cAAc,CAAA,EAAA,OAAA,EAAA,CAAd,cAAc,CAAA,EAAA,CAAA,CAAA;8GAMhB,gBAAgB,EAAA,CAAA,CAAA;2FAAhB,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAJ5B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,KAAK;AACnB,oBAAA,OAAO,EAAE,KAAK;AACf,iBAAA,CAAA;;;ACTD;;AAEG;;;;"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@yelon/util",
|
3
|
-
"version": "
|
3
|
+
"version": "14.0.0-beta.0",
|
4
4
|
"author": "devcui<devcui@outlook.com>",
|
5
5
|
"license": "MIT",
|
6
6
|
"dependencies": {
|
@@ -12,13 +12,13 @@
|
|
12
12
|
"esm2020": "esm2020/yelon-util.mjs",
|
13
13
|
"fesm2020": "fesm2020/yelon-util.mjs",
|
14
14
|
"fesm2015": "fesm2015/yelon-util.mjs",
|
15
|
-
"typings": "
|
15
|
+
"typings": "index.d.ts",
|
16
16
|
"exports": {
|
17
17
|
"./package.json": {
|
18
18
|
"default": "./package.json"
|
19
19
|
},
|
20
20
|
".": {
|
21
|
-
"types": "./
|
21
|
+
"types": "./index.d.ts",
|
22
22
|
"esm2020": "./esm2020/yelon-util.mjs",
|
23
23
|
"es2020": "./fesm2020/yelon-util.mjs",
|
24
24
|
"es2015": "./fesm2015/yelon-util.mjs",
|
@@ -26,7 +26,7 @@
|
|
26
26
|
"default": "./fesm2020/yelon-util.mjs"
|
27
27
|
},
|
28
28
|
"./array": {
|
29
|
-
"types": "./array/
|
29
|
+
"types": "./array/index.d.ts",
|
30
30
|
"esm2020": "./esm2020/array/array.mjs",
|
31
31
|
"es2020": "./fesm2020/array.mjs",
|
32
32
|
"es2015": "./fesm2015/array.mjs",
|
@@ -34,7 +34,7 @@
|
|
34
34
|
"default": "./fesm2020/array.mjs"
|
35
35
|
},
|
36
36
|
"./browser": {
|
37
|
-
"types": "./browser/
|
37
|
+
"types": "./browser/index.d.ts",
|
38
38
|
"esm2020": "./esm2020/browser/browser.mjs",
|
39
39
|
"es2020": "./fesm2020/browser.mjs",
|
40
40
|
"es2015": "./fesm2015/browser.mjs",
|
@@ -42,7 +42,7 @@
|
|
42
42
|
"default": "./fesm2020/browser.mjs"
|
43
43
|
},
|
44
44
|
"./config": {
|
45
|
-
"types": "./config/
|
45
|
+
"types": "./config/index.d.ts",
|
46
46
|
"esm2020": "./esm2020/config/config.mjs",
|
47
47
|
"es2020": "./fesm2020/config.mjs",
|
48
48
|
"es2015": "./fesm2015/config.mjs",
|
@@ -50,7 +50,7 @@
|
|
50
50
|
"default": "./fesm2020/config.mjs"
|
51
51
|
},
|
52
52
|
"./date-time": {
|
53
|
-
"types": "./date-time/
|
53
|
+
"types": "./date-time/index.d.ts",
|
54
54
|
"esm2020": "./esm2020/date-time/date-time.mjs",
|
55
55
|
"es2020": "./fesm2020/date-time.mjs",
|
56
56
|
"es2015": "./fesm2015/date-time.mjs",
|
@@ -58,7 +58,7 @@
|
|
58
58
|
"default": "./fesm2020/date-time.mjs"
|
59
59
|
},
|
60
60
|
"./decorator": {
|
61
|
-
"types": "./decorator/
|
61
|
+
"types": "./decorator/index.d.ts",
|
62
62
|
"esm2020": "./esm2020/decorator/decorator.mjs",
|
63
63
|
"es2020": "./fesm2020/decorator.mjs",
|
64
64
|
"es2015": "./fesm2015/decorator.mjs",
|
@@ -66,7 +66,7 @@
|
|
66
66
|
"default": "./fesm2020/decorator.mjs"
|
67
67
|
},
|
68
68
|
"./form": {
|
69
|
-
"types": "./form/
|
69
|
+
"types": "./form/index.d.ts",
|
70
70
|
"esm2020": "./esm2020/form/form.mjs",
|
71
71
|
"es2020": "./fesm2020/form.mjs",
|
72
72
|
"es2015": "./fesm2015/form.mjs",
|
@@ -74,7 +74,7 @@
|
|
74
74
|
"default": "./fesm2020/form.mjs"
|
75
75
|
},
|
76
76
|
"./format": {
|
77
|
-
"types": "./format/
|
77
|
+
"types": "./format/index.d.ts",
|
78
78
|
"esm2020": "./esm2020/format/format.mjs",
|
79
79
|
"es2020": "./fesm2020/format.mjs",
|
80
80
|
"es2015": "./fesm2015/format.mjs",
|
@@ -82,7 +82,7 @@
|
|
82
82
|
"default": "./fesm2020/format.mjs"
|
83
83
|
},
|
84
84
|
"./math": {
|
85
|
-
"types": "./math/
|
85
|
+
"types": "./math/index.d.ts",
|
86
86
|
"esm2020": "./esm2020/math/math.mjs",
|
87
87
|
"es2020": "./fesm2020/math.mjs",
|
88
88
|
"es2015": "./fesm2015/math.mjs",
|
@@ -90,7 +90,7 @@
|
|
90
90
|
"default": "./fesm2020/math.mjs"
|
91
91
|
},
|
92
92
|
"./other": {
|
93
|
-
"types": "./other/
|
93
|
+
"types": "./other/index.d.ts",
|
94
94
|
"esm2020": "./esm2020/other/other.mjs",
|
95
95
|
"es2020": "./fesm2020/other.mjs",
|
96
96
|
"es2015": "./fesm2015/other.mjs",
|
@@ -98,7 +98,7 @@
|
|
98
98
|
"default": "./fesm2020/other.mjs"
|
99
99
|
},
|
100
100
|
"./pipes/currency": {
|
101
|
-
"types": "./pipes/currency/
|
101
|
+
"types": "./pipes/currency/index.d.ts",
|
102
102
|
"esm2020": "./esm2020/pipes/currency/pipe-currency.mjs",
|
103
103
|
"es2020": "./fesm2020/pipe-currency.mjs",
|
104
104
|
"es2015": "./fesm2015/pipe-currency.mjs",
|
@@ -106,7 +106,7 @@
|
|
106
106
|
"default": "./fesm2020/pipe-currency.mjs"
|
107
107
|
},
|
108
108
|
"./pipes/filter": {
|
109
|
-
"types": "./pipes/filter/
|
109
|
+
"types": "./pipes/filter/index.d.ts",
|
110
110
|
"esm2020": "./esm2020/pipes/filter/pipe-filter.mjs",
|
111
111
|
"es2020": "./fesm2020/pipe-filter.mjs",
|
112
112
|
"es2015": "./fesm2015/pipe-filter.mjs",
|
@@ -114,7 +114,7 @@
|
|
114
114
|
"default": "./fesm2020/pipe-filter.mjs"
|
115
115
|
},
|
116
116
|
"./pipes/format": {
|
117
|
-
"types": "./pipes/format/
|
117
|
+
"types": "./pipes/format/index.d.ts",
|
118
118
|
"esm2020": "./esm2020/pipes/format/pipe-format.mjs",
|
119
119
|
"es2020": "./fesm2020/pipe-format.mjs",
|
120
120
|
"es2015": "./fesm2015/pipe-format.mjs",
|
@@ -122,7 +122,7 @@
|
|
122
122
|
"default": "./fesm2020/pipe-format.mjs"
|
123
123
|
},
|
124
124
|
"./pipes": {
|
125
|
-
"types": "./pipes/
|
125
|
+
"types": "./pipes/index.d.ts",
|
126
126
|
"esm2020": "./esm2020/pipes/pipes.mjs",
|
127
127
|
"es2020": "./fesm2020/pipes.mjs",
|
128
128
|
"es2015": "./fesm2015/pipes.mjs",
|
@@ -130,7 +130,7 @@
|
|
130
130
|
"default": "./fesm2020/pipes.mjs"
|
131
131
|
},
|
132
132
|
"./token": {
|
133
|
-
"types": "./token/
|
133
|
+
"types": "./token/index.d.ts",
|
134
134
|
"esm2020": "./esm2020/token/token.mjs",
|
135
135
|
"es2020": "./fesm2020/token.mjs",
|
136
136
|
"es2015": "./fesm2015/token.mjs",
|
@@ -11,5 +11,5 @@ export declare class CurrencyCNYPipe implements PipeTransform {
|
|
11
11
|
*/
|
12
12
|
transform(value: number | string, options?: CurrencyCNYOptions): string;
|
13
13
|
static ɵfac: i0.ɵɵFactoryDeclaration<CurrencyCNYPipe, never>;
|
14
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<CurrencyCNYPipe, "cny">;
|
14
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<CurrencyCNYPipe, "cny", false>;
|
15
15
|
}
|
@@ -12,5 +12,5 @@ export declare class CurrencyMegaPipe implements PipeTransform {
|
|
12
12
|
*/
|
13
13
|
transform(value: number | string, options?: CurrencyMegaOptions): string;
|
14
14
|
static ɵfac: i0.ɵɵFactoryDeclaration<CurrencyMegaPipe, never>;
|
15
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<CurrencyMegaPipe, "mega">;
|
15
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<CurrencyMegaPipe, "mega", false>;
|
16
16
|
}
|
@@ -15,5 +15,5 @@ export declare class CurrencyPricePipe implements PipeTransform {
|
|
15
15
|
*/
|
16
16
|
transform(value: number | string, options?: CurrencyFormatOptions): string;
|
17
17
|
static ɵfac: i0.ɵɵFactoryDeclaration<CurrencyPricePipe, never>;
|
18
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<CurrencyPricePipe, "price">;
|
18
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<CurrencyPricePipe, "price", false>;
|
19
19
|
}
|
@@ -9,5 +9,5 @@ export declare class FilterPipe implements PipeTransform {
|
|
9
9
|
*/
|
10
10
|
transform<T>(array: readonly T[], matcher: (item: T, ...args: NzSafeAny[]) => boolean, ...args: NzSafeAny[]): T[];
|
11
11
|
static ɵfac: i0.ɵɵFactoryDeclaration<FilterPipe, never>;
|
12
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<FilterPipe, "filter">;
|
12
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<FilterPipe, "filter", false>;
|
13
13
|
}
|
@@ -23,5 +23,5 @@ export declare class FormatMaskPipe implements PipeTransform {
|
|
23
23
|
*/
|
24
24
|
transform(value: string, mask: string | FormatMaskOption): string;
|
25
25
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormatMaskPipe, never>;
|
26
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<FormatMaskPipe, "mask">;
|
26
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<FormatMaskPipe, "mask", false>;
|
27
27
|
}
|
package/array/array.d.ts
DELETED
package/array/package.json
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"module": "../fesm2015/array.mjs",
|
3
|
-
"es2020": "../fesm2020/array.mjs",
|
4
|
-
"esm2020": "../esm2020/array/array.mjs",
|
5
|
-
"fesm2020": "../fesm2020/array.mjs",
|
6
|
-
"fesm2015": "../fesm2015/array.mjs",
|
7
|
-
"typings": "array.d.ts",
|
8
|
-
"sideEffects": false,
|
9
|
-
"name": "@yelon/util/array"
|
10
|
-
}
|
package/browser/browser.d.ts
DELETED
package/browser/package.json
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"module": "../fesm2015/browser.mjs",
|
3
|
-
"es2020": "../fesm2020/browser.mjs",
|
4
|
-
"esm2020": "../esm2020/browser/browser.mjs",
|
5
|
-
"fesm2020": "../fesm2020/browser.mjs",
|
6
|
-
"fesm2015": "../fesm2015/browser.mjs",
|
7
|
-
"typings": "browser.d.ts",
|
8
|
-
"sideEffects": false,
|
9
|
-
"name": "@yelon/util/browser"
|
10
|
-
}
|
package/config/config.d.ts
DELETED
package/config/package.json
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"module": "../fesm2015/config.mjs",
|
3
|
-
"es2020": "../fesm2020/config.mjs",
|
4
|
-
"esm2020": "../esm2020/config/config.mjs",
|
5
|
-
"fesm2020": "../fesm2020/config.mjs",
|
6
|
-
"fesm2015": "../fesm2015/config.mjs",
|
7
|
-
"typings": "config.d.ts",
|
8
|
-
"sideEffects": false,
|
9
|
-
"name": "@yelon/util/config"
|
10
|
-
}
|
package/date-time/date-time.d.ts
DELETED
package/date-time/package.json
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"module": "../fesm2015/date-time.mjs",
|
3
|
-
"es2020": "../fesm2020/date-time.mjs",
|
4
|
-
"esm2020": "../esm2020/date-time/date-time.mjs",
|
5
|
-
"fesm2020": "../fesm2020/date-time.mjs",
|
6
|
-
"fesm2015": "../fesm2015/date-time.mjs",
|
7
|
-
"typings": "date-time.d.ts",
|
8
|
-
"sideEffects": false,
|
9
|
-
"name": "@yelon/util/date-time"
|
10
|
-
}
|
package/decorator/decorator.d.ts
DELETED
package/decorator/package.json
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"module": "../fesm2015/decorator.mjs",
|
3
|
-
"es2020": "../fesm2020/decorator.mjs",
|
4
|
-
"esm2020": "../esm2020/decorator/decorator.mjs",
|
5
|
-
"fesm2020": "../fesm2020/decorator.mjs",
|
6
|
-
"fesm2015": "../fesm2015/decorator.mjs",
|
7
|
-
"typings": "decorator.d.ts",
|
8
|
-
"sideEffects": false,
|
9
|
-
"name": "@yelon/util/decorator"
|
10
|
-
}
|
package/form/form.d.ts
DELETED
package/form/package.json
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"module": "../fesm2015/form.mjs",
|
3
|
-
"es2020": "../fesm2020/form.mjs",
|
4
|
-
"esm2020": "../esm2020/form/form.mjs",
|
5
|
-
"fesm2020": "../fesm2020/form.mjs",
|
6
|
-
"fesm2015": "../fesm2015/form.mjs",
|
7
|
-
"typings": "form.d.ts",
|
8
|
-
"sideEffects": false,
|
9
|
-
"name": "@yelon/util/form"
|
10
|
-
}
|
package/format/format.d.ts
DELETED
package/format/package.json
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"module": "../fesm2015/format.mjs",
|
3
|
-
"es2020": "../fesm2020/format.mjs",
|
4
|
-
"esm2020": "../esm2020/format/format.mjs",
|
5
|
-
"fesm2020": "../fesm2020/format.mjs",
|
6
|
-
"fesm2015": "../fesm2015/format.mjs",
|
7
|
-
"typings": "format.d.ts",
|
8
|
-
"sideEffects": false,
|
9
|
-
"name": "@yelon/util/format"
|
10
|
-
}
|
package/math/math.d.ts
DELETED
package/math/package.json
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"module": "../fesm2015/math.mjs",
|
3
|
-
"es2020": "../fesm2020/math.mjs",
|
4
|
-
"esm2020": "../esm2020/math/math.mjs",
|
5
|
-
"fesm2020": "../fesm2020/math.mjs",
|
6
|
-
"fesm2015": "../fesm2015/math.mjs",
|
7
|
-
"typings": "math.d.ts",
|
8
|
-
"sideEffects": false,
|
9
|
-
"name": "@yelon/util/math"
|
10
|
-
}
|