@yelon/util 18.0.1 → 18.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (36) hide show
  1. package/config/abc/lodop.type.d.ts +2 -2
  2. package/config/theme/index.d.ts +1 -0
  3. package/config/theme/pipe.type.d.ts +4 -0
  4. package/date-time/time.d.ts +5 -1
  5. package/esm2022/array/array.service.mjs +3 -3
  6. package/esm2022/browser/cookie.service.mjs +3 -3
  7. package/esm2022/browser/scroll.service.mjs +3 -3
  8. package/esm2022/config/abc/lodop.type.mjs +1 -1
  9. package/esm2022/config/config.service.mjs +3 -3
  10. package/esm2022/config/theme/index.mjs +2 -1
  11. package/esm2022/config/theme/pipe.type.mjs +1 -1
  12. package/esm2022/date-time/time.mjs +6 -4
  13. package/esm2022/format/currency.service.mjs +3 -3
  14. package/esm2022/other/lazy.service.mjs +3 -3
  15. package/esm2022/other/path-to-regexp.service.mjs +3 -3
  16. package/esm2022/pipes/currency/cny.pipe.mjs +3 -3
  17. package/esm2022/pipes/currency/mega.pipe.mjs +3 -3
  18. package/esm2022/pipes/currency/module.mjs +4 -4
  19. package/esm2022/pipes/currency/price.pipe.mjs +3 -3
  20. package/esm2022/pipes/filter/filter.pipe.mjs +3 -3
  21. package/esm2022/pipes/filter/module.mjs +4 -4
  22. package/esm2022/pipes/format/mask.pipe.mjs +3 -3
  23. package/esm2022/pipes/format/module.mjs +4 -4
  24. package/fesm2022/array.mjs +3 -3
  25. package/fesm2022/browser.mjs +6 -6
  26. package/fesm2022/config.mjs +3 -3
  27. package/fesm2022/date-time.mjs +5 -3
  28. package/fesm2022/date-time.mjs.map +1 -1
  29. package/fesm2022/format.mjs +3 -3
  30. package/fesm2022/format.mjs.map +1 -1
  31. package/fesm2022/other.mjs +6 -6
  32. package/fesm2022/pipe-currency.mjs +13 -13
  33. package/fesm2022/pipe-filter.mjs +7 -7
  34. package/fesm2022/pipe-format.mjs +7 -7
  35. package/other/path-to-regexp.service.d.ts +1 -1
  36. package/package.json +1 -1
@@ -18,8 +18,8 @@ export interface YunzaiLodopConfig {
18
18
  /**
19
19
  * Lodop 远程脚本URL地址,**注意**务必使用 `name` 属性指定变量值
20
20
  *
21
- * - http://localhost:18000/CLodopfuncs.js
22
- * - https://localhost:8443/CLodopfuncs.js [默认]
21
+ * - http://localhost:18000/CLodopfuncs.js [默认]
22
+ * - https://localhost:8443/CLodopfuncs.js
23
23
  */
24
24
  url?: string;
25
25
  /**
@@ -1,3 +1,4 @@
1
1
  export * from './http.type';
2
2
  export * from './responsive.type';
3
3
  export * from './i18n.type';
4
+ export * from './pipe.type';
@@ -1,3 +1,7 @@
1
1
  export interface YunzaiThemePipeConfig {
2
2
  dateFormat?: string;
3
+ dateFormatCustom?: YunzaiThemePipeDateFormatCustom;
3
4
  }
5
+ export type YunzaiThemePipeDateFormatCustom = (value: Date, formatString?: string | null, options?: {
6
+ locale?: Locale;
7
+ }) => string;
@@ -1,3 +1,4 @@
1
+ import type { YunzaiThemePipeDateFormatCustom } from '@yelon/util/config';
1
2
  import type { NzSafeAny } from 'ng-zorro-antd/core/types';
2
3
  import { DateLocale } from 'ng-zorro-antd/i18n';
3
4
  /**
@@ -36,4 +37,7 @@ export declare function toDate(value?: Date | string | number | null, options?:
36
37
  * @param formatString Please refer to [date-fnd format](https://date-fns.org/v2.30.0/docs/format) for string format
37
38
  * @param dateLocale Recommended to be consistent with NG-ZORRO by using `inject(NZ_DATE_LOCALE)`
38
39
  */
39
- export declare function formatDate(value: Date | string | number, formatString: string, dateLocale?: DateLocale): string;
40
+ export declare function formatDate(value: Date | string | number, formatString: string, options?: {
41
+ locale?: DateLocale;
42
+ customFormat?: YunzaiThemePipeDateFormatCustom;
43
+ }): string;
@@ -268,10 +268,10 @@ export class ArrayService {
268
268
  }, new Map())
269
269
  .values());
270
270
  }
271
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ArrayService, deps: [{ token: i1.YunzaiConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
272
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ArrayService, providedIn: 'root' }); }
271
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ArrayService, deps: [{ token: i1.YunzaiConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
272
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ArrayService, providedIn: 'root' }); }
273
273
  }
274
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ArrayService, decorators: [{
274
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ArrayService, decorators: [{
275
275
  type: Injectable,
276
276
  args: [{ providedIn: 'root' }]
277
277
  }], ctorParameters: () => [{ type: i1.YunzaiConfigService }] });
@@ -90,10 +90,10 @@ export class CookieService {
90
90
  removeAll() {
91
91
  this.doc.cookie = '';
92
92
  }
93
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CookieService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
94
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CookieService, providedIn: 'root' }); }
93
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CookieService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
94
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CookieService, providedIn: 'root' }); }
95
95
  }
96
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CookieService, decorators: [{
96
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CookieService, decorators: [{
97
97
  type: Injectable,
98
98
  args: [{ providedIn: 'root' }]
99
99
  }] });
@@ -75,10 +75,10 @@ export class ScrollService {
75
75
  }
76
76
  this.scrollToElement(this._getDoc().body, topOffset);
77
77
  }
78
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ScrollService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
79
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ScrollService, providedIn: 'root' }); }
78
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ScrollService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
79
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ScrollService, providedIn: 'root' }); }
80
80
  }
81
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ScrollService, decorators: [{
81
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ScrollService, decorators: [{
82
82
  type: Injectable,
83
83
  args: [{ providedIn: 'root' }]
84
84
  }] });
@@ -1,2 +1,2 @@
1
1
  export {};
2
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9kb3AudHlwZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL3V0aWwvY29uZmlnL2FiYy9sb2RvcC50eXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgaW50ZXJmYWNlIFl1bnphaUxvZG9wQ29uZmlnIHtcbiAgLyoqXG4gICAqIOazqOWGjOS/oeaBr++8muS4u+azqOWGjOWPt1xuICAgKi9cbiAgbGljZW5zZT86IHN0cmluZztcbiAgLyoqXG4gICAqIOazqOWGjOS/oeaBr++8mumZhOWKoOazqOWGjOWPt0FcbiAgICovXG4gIGxpY2Vuc2VBPzogc3RyaW5nO1xuICAvKipcbiAgICog5rOo5YaM5L+h5oGv77ya6ZmE5Yqg5rOo5YaM5Y+3QlxuICAgKi9cbiAgbGljZW5zZUI/OiBzdHJpbmc7XG4gIC8qKlxuICAgKiDms6jlhozkv6Hmga/vvJrms6jlhozljZXkvY3lkI3np7BcbiAgICovXG4gIGNvbXBhbnlOYW1lPzogc3RyaW5nO1xuICAvKipcbiAgICogTG9kb3Ag6L+c56iL6ISa5pysVVJM5Zyw5Z2A77yMKirms6jmhI8qKuWKoeW/heS9v+eUqCBgbmFtZWAg5bGe5oCn5oyH5a6a5Y+Y6YeP5YC8XG4gICAqXG4gICAqIC0gaHR0cDovL2xvY2FsaG9zdDoxODAwMC9DTG9kb3BmdW5jcy5qc1xuICAgKiAtIGh0dHBzOi8vbG9jYWxob3N0Ojg0NDMvQ0xvZG9wZnVuY3MuanMgW+m7mOiupF1cbiAgICovXG4gIHVybD86IHN0cmluZztcbiAgLyoqXG4gICAqIExvZG9wIOWPmOmHj+WQje+8jOm7mOiupO+8mmBDTE9ET1BgXG4gICAqL1xuICBuYW1lPzogc3RyaW5nO1xuICAvKipcbiAgICog5qOA5p+l5qyh5pWw77yM6buY6K6kIGAxMDBg77yM5b2T5qOA5p+l6LaF6L+H5pe26KeG5Li65byC5bi477yM6L+Z5piv5Zug5Li6IExvZG9wIOmcgOimgei/nuaOpSBXZWJTb2NrZXRcbiAgICovXG4gIGNoZWNrTWF4Q291bnQ/OiBudW1iZXI7XG59XG4iXX0=
2
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9kb3AudHlwZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbI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6IExvZG9wIOmcgOimgei/nuaOpSBXZWJTb2NrZXRcbiAgICovXG4gIGNoZWNrTWF4Q291bnQ/OiBudW1iZXI7XG59XG4iXX0=
@@ -23,10 +23,10 @@ export class YunzaiConfigService {
23
23
  set(componentName, value) {
24
24
  this.config[componentName] = { ...this.config[componentName], ...value };
25
25
  }
26
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: YunzaiConfigService, deps: [{ token: YUNZAI_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
27
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: YunzaiConfigService, providedIn: 'root' }); }
26
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: YunzaiConfigService, deps: [{ token: YUNZAI_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
27
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: YunzaiConfigService, providedIn: 'root' }); }
28
28
  }
29
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: YunzaiConfigService, decorators: [{
29
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: YunzaiConfigService, decorators: [{
30
30
  type: Injectable,
31
31
  args: [{ providedIn: 'root' }]
32
32
  }], ctorParameters: () => [{ type: undefined, decorators: [{
@@ -1,4 +1,5 @@
1
1
  export * from './http.type';
2
2
  export * from './responsive.type';
3
3
  export * from './i18n.type';
4
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy91dGlsL2NvbmZpZy90aGVtZS9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxjQUFjLGFBQWEsQ0FBQztBQUM1QixjQUFjLG1CQUFtQixDQUFDO0FBQ2xDLGNBQWMsYUFBYSxDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0ICogZnJvbSAnLi9odHRwLnR5cGUnO1xuZXhwb3J0ICogZnJvbSAnLi9yZXNwb25zaXZlLnR5cGUnO1xuZXhwb3J0ICogZnJvbSAnLi9pMThuLnR5cGUnO1xuIl19
4
+ export * from './pipe.type';
5
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy91dGlsL2NvbmZpZy90aGVtZS9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxjQUFjLGFBQWEsQ0FBQztBQUM1QixjQUFjLG1CQUFtQixDQUFDO0FBQ2xDLGNBQWMsYUFBYSxDQUFDO0FBQzVCLGNBQWMsYUFBYSxDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0ICogZnJvbSAnLi9odHRwLnR5cGUnO1xuZXhwb3J0ICogZnJvbSAnLi9yZXNwb25zaXZlLnR5cGUnO1xuZXhwb3J0ICogZnJvbSAnLi9pMThuLnR5cGUnO1xuZXhwb3J0ICogZnJvbSAnLi9waXBlLnR5cGUnO1xuIl19
@@ -1,2 +1,2 @@
1
1
  export {};
2
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGlwZS50eXBlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcGFja2FnZXMvdXRpbC9jb25maWcvdGhlbWUvcGlwZS50eXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgaW50ZXJmYWNlIFl1bnphaVRoZW1lUGlwZUNvbmZpZyB7XG4gIGRhdGVGb3JtYXQ/OiBzdHJpbmc7XG59XG4iXX0=
2
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGlwZS50eXBlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcGFja2FnZXMvdXRpbC9jb25maWcvdGhlbWUvcGlwZS50eXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgaW50ZXJmYWNlIFl1bnphaVRoZW1lUGlwZUNvbmZpZyB7XG4gIGRhdGVGb3JtYXQ/OiBzdHJpbmc7XG4gIGRhdGVGb3JtYXRDdXN0b20/OiBZdW56YWlUaGVtZVBpcGVEYXRlRm9ybWF0Q3VzdG9tO1xufVxuXG5leHBvcnQgdHlwZSBZdW56YWlUaGVtZVBpcGVEYXRlRm9ybWF0Q3VzdG9tID0gKFxuICB2YWx1ZTogRGF0ZSxcbiAgZm9ybWF0U3RyaW5nPzogc3RyaW5nIHwgbnVsbCxcbiAgb3B0aW9ucz86IHsgbG9jYWxlPzogTG9jYWxlIH1cbikgPT4gc3RyaW5nO1xuIl19
@@ -91,11 +91,13 @@ export function toDate(value, options) {
91
91
  * @param formatString Please refer to [date-fnd format](https://date-fns.org/v2.30.0/docs/format) for string format
92
92
  * @param dateLocale Recommended to be consistent with NG-ZORRO by using `inject(NZ_DATE_LOCALE)`
93
93
  */
94
- export function formatDate(value, formatString, dateLocale) {
94
+ export function formatDate(value, formatString, options) {
95
95
  value = toDate(value);
96
96
  if (isNaN(value))
97
97
  return '';
98
- const langOpt = { locale: dateLocale };
99
- return formatString === 'fn' ? formatDistanceToNow(value, langOpt) : format(value, formatString, langOpt);
98
+ const langOpt = { locale: options?.locale };
99
+ return formatString === 'fn'
100
+ ? formatDistanceToNow(value, langOpt)
101
+ : (options?.customFormat ?? format)(value, formatString, langOpt);
100
102
  }
101
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGltZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL3V0aWwvZGF0ZS10aW1lL3RpbWUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUNMLE9BQU8sRUFDUCxRQUFRLEVBQ1IsVUFBVSxFQUNWLFNBQVMsRUFDVCxTQUFTLEVBQ1QsS0FBSyxFQUNMLFFBQVEsRUFDUixVQUFVLEVBQ1YsWUFBWSxFQUNaLFdBQVcsRUFDWCxXQUFXLEVBQ1gsU0FBUyxFQUNULFFBQVEsRUFDUixRQUFRLEVBQ1IsTUFBTSxFQUNOLG1CQUFtQixFQUNwQixNQUFNLFVBQVUsQ0FBQztBQUtsQjs7Ozs7Ozs7R0FRRztBQUNILE1BQU0sVUFBVSxlQUFlLENBQzdCLElBQTBHLEVBQzFHLElBQTZCLEVBQzdCLE9BQXFDO0lBRXJDLElBQUksR0FBRyxJQUFJO1FBQ1QsQ0FBQyxDQUFDLE9BQU8sSUFBSSxLQUFLLFFBQVE7WUFDeEIsQ0FBQyxDQUFDLEtBQUssQ0FBQyxJQUFJLEVBQUUscUJBQXFCLEVBQUUsSUFBSSxJQUFJLEVBQUUsQ0FBQztZQUNoRCxDQUFDLENBQUMsSUFBSSxJQUFJLENBQUMsSUFBSSxDQUFDO1FBQ2xCLENBQUMsQ0FBQyxJQUFJLElBQUksRUFBRSxDQUFDO0lBQ2YsTUFBTSxHQUFHLEdBQXdCLEVBQUUsWUFBWSxFQUFFLENBQUMsRUFBRSxDQUFDO0lBRXJELElBQUksR0FBaUIsQ0FBQztJQUN0QixRQUFRLElBQUksRUFBRSxDQUFDO1FBQ2IsS0F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NhbGU/OiBEYXRlTG9jYWxlOyBjdXN0b21Gb3JtYXQ/OiBZdW56YWlUaGVtZVBpcGVEYXRlRm9ybWF0Q3VzdG9tIH1cbik6IHN0cmluZyB7XG4gIHZhbHVlID0gdG9EYXRlKHZhbHVlKTtcbiAgaWYgKGlzTmFOKHZhbHVlIGFzIE56U2FmZUFueSkpIHJldHVybiAnJztcblxuICBjb25zdCBsYW5nT3B0ID0geyBsb2NhbGU6IG9wdGlvbnM/LmxvY2FsZSB9O1xuICByZXR1cm4gZm9ybWF0U3RyaW5nID09PSAnZm4nXG4gICAgPyBmb3JtYXREaXN0YW5jZVRvTm93KHZhbHVlLCBsYW5nT3B0KVxuICAgIDogKG9wdGlvbnM/LmN1c3RvbUZvcm1hdCA/PyBmb3JtYXQpKHZhbHVlLCBmb3JtYXRTdHJpbmcsIGxhbmdPcHQpO1xufVxuIl19
@@ -223,10 +223,10 @@ export class CurrencyService {
223
223
  : integerRes + (decimalRes === '' ? '' : `点${decimalRes}`));
224
224
  return ret;
225
225
  }
226
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyService, deps: [{ token: i1.YunzaiConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
227
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyService, providedIn: 'root' }); }
226
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyService, deps: [{ token: i1.YunzaiConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
227
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyService, providedIn: 'root' }); }
228
228
  }
229
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyService, decorators: [{
229
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyService, decorators: [{
230
230
  type: Injectable,
231
231
  args: [{ providedIn: 'root' }]
232
232
  }], ctorParameters: () => [{ type: i1.YunzaiConfigService }] });
@@ -119,10 +119,10 @@ export class LazyService {
119
119
  resolve(item);
120
120
  });
121
121
  }
122
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: LazyService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
123
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: LazyService, providedIn: 'root' }); }
122
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: LazyService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
123
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: LazyService, providedIn: 'root' }); }
124
124
  }
125
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: LazyService, decorators: [{
125
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: LazyService, decorators: [{
126
126
  type: Injectable,
127
127
  args: [{ providedIn: 'root' }]
128
128
  }] });
@@ -227,10 +227,10 @@ export class PathToRegexpService {
227
227
  }
228
228
  return this.stringToRegexp(/** @type {string} */ path, keys, options);
229
229
  }
230
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: PathToRegexpService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
231
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: PathToRegexpService, providedIn: 'root' }); }
230
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: PathToRegexpService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
231
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: PathToRegexpService, providedIn: 'root' }); }
232
232
  }
233
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: PathToRegexpService, decorators: [{
233
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: PathToRegexpService, decorators: [{
234
234
  type: Injectable,
235
235
  args: [{
236
236
  providedIn: 'root'
@@ -13,10 +13,10 @@ export class CurrencyCNYPipe {
13
13
  transform(value, options) {
14
14
  return this.srv.cny(value, options);
15
15
  }
16
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyCNYPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
17
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: CurrencyCNYPipe, isStandalone: true, name: "cny" }); }
16
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyCNYPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
17
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: CurrencyCNYPipe, isStandalone: true, name: "cny" }); }
18
18
  }
19
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyCNYPipe, decorators: [{
19
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyCNYPipe, decorators: [{
20
20
  type: Pipe,
21
21
  args: [{ name: 'cny', standalone: true }]
22
22
  }] });
@@ -15,10 +15,10 @@ export class CurrencyMegaPipe {
15
15
  const res = this.srv.mega(value, options);
16
16
  return res.value + (this.isCN ? res.unitI18n : res.unit);
17
17
  }
18
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyMegaPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
19
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: CurrencyMegaPipe, isStandalone: true, name: "mega" }); }
18
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyMegaPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
19
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: CurrencyMegaPipe, isStandalone: true, name: "mega" }); }
20
20
  }
21
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyMegaPipe, decorators: [{
21
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyMegaPipe, decorators: [{
22
22
  type: Pipe,
23
23
  args: [{ name: 'mega', standalone: true }]
24
24
  }] });
@@ -5,11 +5,11 @@ import { CurrencyPricePipe } from './price.pipe';
5
5
  import * as i0 from "@angular/core";
6
6
  const PIPES = [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe];
7
7
  export class CurrencyPipeModule {
8
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
9
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPipeModule, imports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe], exports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe] }); }
10
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPipeModule }); }
8
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
9
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPipeModule, imports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe], exports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe] }); }
10
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPipeModule }); }
11
11
  }
12
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPipeModule, decorators: [{
12
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPipeModule, decorators: [{
13
13
  type: NgModule,
14
14
  args: [{
15
15
  imports: PIPES,
@@ -17,10 +17,10 @@ export class CurrencyPricePipe {
17
17
  transform(value, options) {
18
18
  return this.srv.format(value, options);
19
19
  }
20
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPricePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
21
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPricePipe, isStandalone: true, name: "price" }); }
20
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPricePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
21
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPricePipe, isStandalone: true, name: "price" }); }
22
22
  }
23
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPricePipe, decorators: [{
23
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPricePipe, decorators: [{
24
24
  type: Pipe,
25
25
  args: [{ name: 'price', standalone: true }]
26
26
  }] });
@@ -10,10 +10,10 @@ export class FilterPipe {
10
10
  transform(array, matcher, ...args) {
11
11
  return array.filter(i => matcher(i, ...args));
12
12
  }
13
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
14
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: FilterPipe, isStandalone: true, name: "filter", pure: false }); }
13
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
14
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: FilterPipe, isStandalone: true, name: "filter", pure: false }); }
15
15
  }
16
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipe, decorators: [{
16
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipe, decorators: [{
17
17
  type: Pipe,
18
18
  args: [{ name: 'filter', standalone: true, pure: false }]
19
19
  }] });
@@ -3,11 +3,11 @@ import { FilterPipe } from './filter.pipe';
3
3
  import * as i0 from "@angular/core";
4
4
  const PIPES = [FilterPipe];
5
5
  export class FilterPipeModule {
6
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
7
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: FilterPipeModule, imports: [FilterPipe], exports: [FilterPipe] }); }
8
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipeModule }); }
6
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
7
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: FilterPipeModule, imports: [FilterPipe], exports: [FilterPipe] }); }
8
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipeModule }); }
9
9
  }
10
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipeModule, decorators: [{
10
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipeModule, decorators: [{
11
11
  type: NgModule,
12
12
  args: [{
13
13
  imports: PIPES,
@@ -24,10 +24,10 @@ export class FormatMaskPipe {
24
24
  transform(value, mask) {
25
25
  return formatMask(value, mask);
26
26
  }
27
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatMaskPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
28
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: FormatMaskPipe, isStandalone: true, name: "mask" }); }
27
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatMaskPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
28
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: FormatMaskPipe, isStandalone: true, name: "mask" }); }
29
29
  }
30
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatMaskPipe, decorators: [{
30
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatMaskPipe, decorators: [{
31
31
  type: Pipe,
32
32
  args: [{ name: 'mask', standalone: true }]
33
33
  }] });
@@ -3,11 +3,11 @@ import { FormatMaskPipe } from './mask.pipe';
3
3
  import * as i0 from "@angular/core";
4
4
  const PIPES = [FormatMaskPipe];
5
5
  export class FormatPipeModule {
6
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
7
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: FormatPipeModule, imports: [FormatMaskPipe], exports: [FormatMaskPipe] }); }
8
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatPipeModule }); }
6
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
7
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: FormatPipeModule, imports: [FormatMaskPipe], exports: [FormatMaskPipe] }); }
8
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatPipeModule }); }
9
9
  }
10
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatPipeModule, decorators: [{
10
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatPipeModule, decorators: [{
11
11
  type: NgModule,
12
12
  args: [{
13
13
  imports: PIPES,
@@ -269,10 +269,10 @@ class ArrayService {
269
269
  }, new Map())
270
270
  .values());
271
271
  }
272
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ArrayService, deps: [{ token: i1.YunzaiConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
273
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ArrayService, providedIn: 'root' }); }
272
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ArrayService, deps: [{ token: i1.YunzaiConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
273
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ArrayService, providedIn: 'root' }); }
274
274
  }
275
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ArrayService, decorators: [{
275
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ArrayService, decorators: [{
276
276
  type: Injectable,
277
277
  args: [{ providedIn: 'root' }]
278
278
  }], ctorParameters: () => [{ type: i1.YunzaiConfigService }] });
@@ -91,10 +91,10 @@ class CookieService {
91
91
  removeAll() {
92
92
  this.doc.cookie = '';
93
93
  }
94
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CookieService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
95
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CookieService, providedIn: 'root' }); }
94
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CookieService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
95
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CookieService, providedIn: 'root' }); }
96
96
  }
97
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CookieService, decorators: [{
97
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CookieService, decorators: [{
98
98
  type: Injectable,
99
99
  args: [{ providedIn: 'root' }]
100
100
  }] });
@@ -219,10 +219,10 @@ class ScrollService {
219
219
  }
220
220
  this.scrollToElement(this._getDoc().body, topOffset);
221
221
  }
222
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ScrollService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
223
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ScrollService, providedIn: 'root' }); }
222
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ScrollService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
223
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ScrollService, providedIn: 'root' }); }
224
224
  }
225
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: ScrollService, decorators: [{
225
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ScrollService, decorators: [{
226
226
  type: Injectable,
227
227
  args: [{ providedIn: 'root' }]
228
228
  }] });
@@ -37,10 +37,10 @@ class YunzaiConfigService {
37
37
  set(componentName, value) {
38
38
  this.config[componentName] = { ...this.config[componentName], ...value };
39
39
  }
40
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: YunzaiConfigService, deps: [{ token: YUNZAI_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
41
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: YunzaiConfigService, providedIn: 'root' }); }
40
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: YunzaiConfigService, deps: [{ token: YUNZAI_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
41
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: YunzaiConfigService, providedIn: 'root' }); }
42
42
  }
43
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: YunzaiConfigService, decorators: [{
43
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: YunzaiConfigService, decorators: [{
44
44
  type: Injectable,
45
45
  args: [{ providedIn: 'root' }]
46
46
  }], ctorParameters: () => [{ type: undefined, decorators: [{
@@ -92,12 +92,14 @@ function toDate(value, options) {
92
92
  * @param formatString Please refer to [date-fnd format](https://date-fns.org/v2.30.0/docs/format) for string format
93
93
  * @param dateLocale Recommended to be consistent with NG-ZORRO by using `inject(NZ_DATE_LOCALE)`
94
94
  */
95
- function formatDate(value, formatString, dateLocale) {
95
+ function formatDate(value, formatString, options) {
96
96
  value = toDate(value);
97
97
  if (isNaN(value))
98
98
  return '';
99
- const langOpt = { locale: dateLocale };
100
- return formatString === 'fn' ? formatDistanceToNow(value, langOpt) : format(value, formatString, langOpt);
99
+ const langOpt = { locale: options?.locale };
100
+ return formatString === 'fn'
101
+ ? formatDistanceToNow(value, langOpt)
102
+ : (options?.customFormat ?? format)(value, formatString, langOpt);
101
103
  }
102
104
 
103
105
  // TODO: timezone process
@@ -1 +1 @@
1
- {"version":3,"file":"date-time.mjs","sources":["../../../../packages/util/date-time/time.ts","../../../../packages/util/date-time/picker.ts","../../../../packages/util/date-time/date-time.ts"],"sourcesContent":["import {\n addDays,\n endOfDay,\n endOfMonth,\n endOfWeek,\n endOfYear,\n parse,\n parseISO,\n startOfDay,\n startOfMonth,\n startOfWeek,\n startOfYear,\n subMonths,\n subWeeks,\n subYears,\n format,\n formatDistanceToNow\n} from 'date-fns';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\nimport { DateLocale } from 'ng-zorro-antd/i18n';\n\n/**\n * Get the time range, return `[ Date, Date]` for the start and end dates\n *\n * 获取时间范围\n *\n * @param type 类型,带 `-` 表示过去一个时间,若指定 `number` 表示天数\n * @param time 开始时间\n * @param ignoreMaxTime 忽略追加结束日期的最大时间值\n */\nexport function getTimeDistance(\n type: 'today' | '-today' | 'yesterday' | 'week' | '-week' | 'month' | '-month' | 'year' | '-year' | number,\n time?: Date | string | number,\n options?: { ignoreMaxTime?: boolean }\n): [Date, Date] {\n time = time\n ? typeof time === 'string'\n ? parse(time, 'yyyy-MM-dd HH:mm:ss', new Date())\n : new Date(time)\n : new Date();\n const opt: { weekStartsOn: 1 } = { weekStartsOn: 1 };\n\n let res: [Date, Date];\n switch (type) {\n case 'today':\n res = [time, time];\n break;\n case '-today':\n res = [addDays(time, -1), time];\n break;\n case 'yesterday':\n res = [addDays(time, -1), addDays(time, -1)];\n break;\n case 'week':\n res = [startOfWeek(time, opt), endOfWeek(time, opt)];\n break;\n case '-week':\n res = [startOfWeek(subWeeks(time, 1), opt), endOfWeek(subWeeks(time, 1), opt)];\n break;\n case 'month':\n res = [startOfMonth(time), endOfMonth(time)];\n break;\n case '-month':\n res = [startOfMonth(subMonths(time, 1)), endOfMonth(subMonths(time, 1))];\n break;\n case 'year':\n res = [startOfYear(time), endOfYear(time)];\n break;\n case '-year':\n res = [startOfYear(subYears(time, 1)), endOfYear(subYears(time, 1))];\n break;\n default:\n res = type > 0 ? [time, addDays(time, type)] : [addDays(time, type), time];\n break;\n }\n return options?.ignoreMaxTime ? res : fixEndTimeOfRange(res);\n}\n\n/**\n * fix time is the most, big value\n */\nexport function fixEndTimeOfRange(dates: [Date, Date]): [Date, Date] {\n return [startOfDay(dates[0]), endOfDay(dates[1])];\n}\n\nexport interface ToDateOptions {\n /** If parsing fails try to parse the date by pressing `formatString` */\n formatString?: string;\n /** If parsing fails returned default value, default: `new Date(NaN)` */\n defaultValue?: NzSafeAny;\n timestampSecond?: boolean;\n}\n\n/**\n * Convert to `Date` format\n *\n * @param value When is a number, it's treated as a timestamp; If it's seconds, you need to provide the `options.timestampSecond` parameter.\n */\nexport function toDate(value?: Date | string | number | null, options?: string | ToDateOptions): Date {\n const { formatString, defaultValue, timestampSecond } = {\n formatString: 'yyyy-MM-dd HH:mm:ss',\n defaultValue: new Date(NaN),\n timestampSecond: false,\n ...(typeof options === 'string' ? { formatString: options } : options)\n };\n if (value == null) {\n return defaultValue;\n }\n if (value instanceof Date) {\n return value;\n }\n if (typeof value === 'number' || (typeof value === 'string' && /^[0-9]+$/.test(value))) {\n const valueNumber = +value;\n return new Date(timestampSecond ? valueNumber * 1000 : valueNumber);\n }\n let tryDate = parseISO(value);\n if (isNaN(tryDate as NzSafeAny)) {\n tryDate = parse(value, formatString!, new Date());\n }\n\n return isNaN(tryDate as NzSafeAny) ? defaultValue : tryDate;\n}\n\n/**\n * Format date, supports `Date, number, string` types\n *\n * @param value When is a number, it is treated as a timestamp (Support seconds and milliseconds timestamp).\n * @param formatString Please refer to [date-fnd format](https://date-fns.org/v2.30.0/docs/format) for string format\n * @param dateLocale Recommended to be consistent with NG-ZORRO by using `inject(NZ_DATE_LOCALE)`\n */\nexport function formatDate(value: Date | string | number, formatString: string, dateLocale?: DateLocale): string {\n value = toDate(value);\n if (isNaN(value as NzSafeAny)) return '';\n\n const langOpt = { locale: dateLocale };\n return formatString === 'fn' ? formatDistanceToNow(value, langOpt) : format(value, formatString, langOpt);\n}\n","import { addDays, addSeconds, differenceInCalendarDays, format } from 'date-fns';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\nimport type { DisabledDateFn, DisabledTimeConfig, DisabledTimeFn } from 'ng-zorro-antd/date-picker';\n\n// TODO: timezone process\nexport class DateTimePickerUtil {\n /**\n * Current local time\n *\n * 当前本地时间\n */\n get now(): Date {\n return new Date();\n }\n /**\n * Current local date (not including time part)\n *\n * 当前本地日期(不包含时间部分)\n */\n get date(): Date {\n return this.removeTime(this.now);\n }\n /**\n * Remove the time part of the date\n *\n * 移除日期的时间部分\n */\n removeTime(d: Date): Date {\n return new Date(d.toDateString());\n }\n /**\n * Format date-time\n *\n * 格式化日期\n */\n format(d: number | Date, formatString: string = 'yyyy-MM-dd HH:mm:ss'): string {\n return format(d, formatString);\n }\n private genTick(count: number): number[] {\n return new Array(count).fill(0).map((_, idx) => idx);\n }\n /**\n * Calculate the number of days between two dates, `0` means the same day\n *\n * 计算两个日期相差天数,`0` 表示同一天\n */\n getDiffDays(dateLeft: Date | number, dateRight?: Date | number): number {\n return differenceInCalendarDays(\n dateLeft,\n typeof dateRight === 'number' ? addDays(this.date, dateRight) : dateRight || this.date\n );\n }\n /**\n * Disabled Before date (Default: today), Generally serves `nzDisabledDate`\n *\n * 禁用之前日期(默认:今天),一般服务于 `nzDisabledDate`\n */\n disabledBeforeDate(options?: { offsetDays?: Date | number }): DisabledDateFn {\n return (d): boolean => this.getDiffDays(d, options?.offsetDays) < 0;\n }\n /**\n * Disabled After date (Default: today), Generally serves `nzDisabledDate`\n *\n * 禁用之后日期(默认:今天),一般服务于 `nzDisabledDate`\n */\n disabledAfterDate(options?: { offsetDays?: Date | number }): DisabledDateFn {\n return (d): boolean => this.getDiffDays(d, options?.offsetDays) > 0;\n }\n private baseDisabledTime(type: 'before' | 'after', offsetSeconds?: number): DisabledTimeFn {\n const tick24 = this.genTick(24);\n const tick60 = this.genTick(60);\n return (current): DisabledTimeConfig => {\n const cur = current as Date;\n if (cur == null) {\n return {} as NzSafeAny;\n }\n const now = addSeconds(this.now, offsetSeconds || 0);\n const nowHours = now.getHours();\n const nowMinutes = now.getMinutes();\n const curHours = cur.getHours();\n const isToday = this.getDiffDays(this.removeTime(cur)) === 0;\n return {\n nzDisabledHours: () => {\n if (!isToday) return [];\n return type === 'before' ? tick24.slice(0, nowHours) : tick24.slice(nowHours + 1);\n },\n nzDisabledMinutes: () => {\n if (isToday && curHours === nowHours) {\n return type === 'before' ? tick60.slice(0, nowMinutes) : tick60.slice(nowMinutes + 1);\n }\n return [];\n },\n nzDisabledSeconds: () => {\n if (isToday && curHours === nowHours && cur.getMinutes() === nowMinutes) {\n const nowSeconds = now.getSeconds();\n return type === 'before' ? tick60.slice(0, nowSeconds) : tick60.slice(nowSeconds + 1);\n }\n return [];\n }\n };\n };\n }\n /**\n * Disabled Before time (Default: now), Generally serves `nzDisabledTime`\n *\n * 禁用之前时间(默认:现在),一般服务于 `nzDisabledTime`\n */\n disabledBeforeTime(options?: { offsetSeconds?: number }): DisabledTimeFn {\n return this.baseDisabledTime('before', options?.offsetSeconds);\n }\n /**\n * Disabled After time (Default: now), Generally serves `nzDisabledTime`\n *\n * 禁用之后时间(默认:现在),一般服务于 `nzDisabledTime`\n */\n disabledAfterTime(options?: { offsetSeconds?: number }): DisabledTimeFn {\n return this.baseDisabledTime('after', options?.offsetSeconds);\n }\n}\n\nexport const dateTimePickerUtil = new DateTimePickerUtil();\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAsBA;;;;;;;;AAQG;SACa,eAAe,CAC7B,IAA0G,EAC1G,IAA6B,EAC7B,OAAqC,EAAA;AAErC,IAAA,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A,OAAO,EAAE,CAAC;iBACX;gBACD,iBAAiB,EAAE,MAAK;AACtB,oBAAA,IAAI,OAAO,IAAI,QAAQ,KAAK,QAAQ,IAAI,GAAG,CAAC,UAAU,EAAE,KAAK,UAAU,EAAE;AACvE,wBAAA,MAAM,UAAU,GAAG,GAAG,CAAC,UAAU,EAAE,CAAC;wBACpC,OAAO,IAAI,KAAK,QAAQ,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,UAAU,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,UAAU,GAAG,CAAC,CAAC,CAAC;qBACvF;AACD,oBAAA,OAAO,EAAE,CAAC;iBACX;aACF,CAAC;AACJ,SAAC,CAAC;KACH;AACD;;;;AAIG;AACH,IAAA,kBAAkB,CAAC,OAAoC,EAAA;QACrD,OAAO,IAAI,CAAC,gBAAgB,CAAC,QAAQ,EAAE,OAAO,EAAE,aAAa,CAAC,CAAC;KAChE;AACD;;;;AAIG;AACH,IAAA,iBAAiB,CAAC,OAAoC,EAAA;QACpD,OAAO,IAAI,CAAC,gBAAgB,CAAC,OAAO,EAAE,OAAO,EAAE,aAAa,CAAC,CAAC;KAC/D;AACF,CAAA;AAEY,MAAA,kBAAkB,GAAG,IAAI,kBAAkB;;ACzHxD;;AAEG;;;;"}
1
+ {"version":3,"file":"date-time.mjs","sources":["../../../../packages/util/date-time/time.ts","../../../../packages/util/date-time/picker.ts","../../../../packages/util/date-time/date-time.ts"],"sourcesContent":["import {\n addDays,\n endOfDay,\n endOfMonth,\n endOfWeek,\n endOfYear,\n parse,\n parseISO,\n startOfDay,\n startOfMonth,\n startOfWeek,\n startOfYear,\n subMonths,\n subWeeks,\n subYears,\n format,\n formatDistanceToNow\n} from 'date-fns';\n\nimport type { YunzaiThemePipeDateFormatCustom } from '@yelon/util/config';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\nimport { DateLocale } from 'ng-zorro-antd/i18n';\n\n/**\n * Get the time range, return `[ Date, Date]` for the start and end dates\n *\n * 获取时间范围\n *\n * @param type 类型,带 `-` 表示过去一个时间,若指定 `number` 表示天数\n * @param time 开始时间\n * @param ignoreMaxTime 忽略追加结束日期的最大时间值\n */\nexport function getTimeDistance(\n type: 'today' | '-today' | 'yesterday' | 'week' | '-week' | 'month' | '-month' | 'year' | '-year' | number,\n time?: Date | string | number,\n options?: { ignoreMaxTime?: boolean }\n): [Date, Date] {\n time = time\n ? typeof time === 'string'\n ? parse(time, 'yyyy-MM-dd HH:mm:ss', new Date())\n : new Date(time)\n : new Date();\n const opt: { weekStartsOn: 1 } = { weekStartsOn: 1 };\n\n let res: [Date, Date];\n switch (type) {\n case 'today':\n res = [time, time];\n break;\n case '-today':\n res = [addDays(time, -1), time];\n break;\n case 'yesterday':\n res = [addDays(time, -1), addDays(time, -1)];\n break;\n case 'week':\n res = [startOfWeek(time, opt), endOfWeek(time, opt)];\n break;\n case '-week':\n res = [startOfWeek(subWeeks(time, 1), opt), endOfWeek(subWeeks(time, 1), opt)];\n break;\n case 'month':\n res = [startOfMonth(time), endOfMonth(time)];\n break;\n case '-month':\n res = [startOfMonth(subMonths(time, 1)), endOfMonth(subMonths(time, 1))];\n break;\n case 'year':\n res = [startOfYear(time), endOfYear(time)];\n break;\n case '-year':\n res = [startOfYear(subYears(time, 1)), endOfYear(subYears(time, 1))];\n break;\n default:\n res = type > 0 ? [time, addDays(time, type)] : [addDays(time, type), time];\n break;\n }\n return options?.ignoreMaxTime ? res : fixEndTimeOfRange(res);\n}\n\n/**\n * fix time is the most, big value\n */\nexport function fixEndTimeOfRange(dates: [Date, Date]): [Date, Date] {\n return [startOfDay(dates[0]), endOfDay(dates[1])];\n}\n\nexport interface ToDateOptions {\n /** If parsing fails try to parse the date by pressing `formatString` */\n formatString?: string;\n /** If parsing fails returned default value, default: `new Date(NaN)` */\n defaultValue?: NzSafeAny;\n timestampSecond?: boolean;\n}\n\n/**\n * Convert to `Date` format\n *\n * @param value When is a number, it's treated as a timestamp; If it's seconds, you need to provide the `options.timestampSecond` parameter.\n */\nexport function toDate(value?: Date | string | number | null, options?: string | ToDateOptions): Date {\n const { formatString, defaultValue, timestampSecond } = {\n formatString: 'yyyy-MM-dd HH:mm:ss',\n defaultValue: new Date(NaN),\n timestampSecond: false,\n ...(typeof options === 'string' ? { formatString: options } : options)\n };\n if (value == null) {\n return defaultValue;\n }\n if (value instanceof Date) {\n return value;\n }\n if (typeof value === 'number' || (typeof value === 'string' && /^[0-9]+$/.test(value))) {\n const valueNumber = +value;\n return new Date(timestampSecond ? valueNumber * 1000 : valueNumber);\n }\n let tryDate = parseISO(value);\n if (isNaN(tryDate as NzSafeAny)) {\n tryDate = parse(value, formatString!, new Date());\n }\n\n return isNaN(tryDate as NzSafeAny) ? defaultValue : tryDate;\n}\n\n/**\n * Format date, supports `Date, number, string` types\n *\n * @param value When is a number, it is treated as a timestamp (Support seconds and milliseconds timestamp).\n * @param formatString Please refer to [date-fnd format](https://date-fns.org/v2.30.0/docs/format) for string format\n * @param dateLocale Recommended to be consistent with NG-ZORRO by using `inject(NZ_DATE_LOCALE)`\n */\nexport function formatDate(\n value: Date | string | number,\n formatString: string,\n options?: { locale?: DateLocale; customFormat?: YunzaiThemePipeDateFormatCustom }\n): string {\n value = toDate(value);\n if (isNaN(value as NzSafeAny)) return '';\n\n const langOpt = { locale: options?.locale };\n return formatString === 'fn'\n ? formatDistanceToNow(value, langOpt)\n : (options?.customFormat ?? format)(value, formatString, langOpt);\n}\n","import { addDays, addSeconds, differenceInCalendarDays, format } from 'date-fns';\n\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\nimport type { DisabledDateFn, DisabledTimeConfig, DisabledTimeFn } from 'ng-zorro-antd/date-picker';\n\n// TODO: timezone process\nexport class DateTimePickerUtil {\n /**\n * Current local time\n *\n * 当前本地时间\n */\n get now(): Date {\n return new Date();\n }\n /**\n * Current local date (not including time part)\n *\n * 当前本地日期(不包含时间部分)\n */\n get date(): Date {\n return this.removeTime(this.now);\n }\n /**\n * Remove the time part of the date\n *\n * 移除日期的时间部分\n */\n removeTime(d: Date): Date {\n return new Date(d.toDateString());\n }\n /**\n * Format date-time\n *\n * 格式化日期\n */\n format(d: number | Date, formatString: string = 'yyyy-MM-dd HH:mm:ss'): string {\n return format(d, formatString);\n }\n private genTick(count: number): number[] {\n return new Array(count).fill(0).map((_, idx) => idx);\n }\n /**\n * Calculate the number of days between two dates, `0` means the same day\n *\n * 计算两个日期相差天数,`0` 表示同一天\n */\n getDiffDays(dateLeft: Date | number, dateRight?: Date | number): number {\n return differenceInCalendarDays(\n dateLeft,\n typeof dateRight === 'number' ? addDays(this.date, dateRight) : dateRight || this.date\n );\n }\n /**\n * Disabled Before date (Default: today), Generally serves `nzDisabledDate`\n *\n * 禁用之前日期(默认:今天),一般服务于 `nzDisabledDate`\n */\n disabledBeforeDate(options?: { offsetDays?: Date | number }): DisabledDateFn {\n return (d): boolean => this.getDiffDays(d, options?.offsetDays) < 0;\n }\n /**\n * Disabled After date (Default: today), Generally serves `nzDisabledDate`\n *\n * 禁用之后日期(默认:今天),一般服务于 `nzDisabledDate`\n */\n disabledAfterDate(options?: { offsetDays?: Date | number }): DisabledDateFn {\n return (d): boolean => this.getDiffDays(d, options?.offsetDays) > 0;\n }\n private baseDisabledTime(type: 'before' | 'after', offsetSeconds?: number): DisabledTimeFn {\n const tick24 = this.genTick(24);\n const tick60 = this.genTick(60);\n return (current): DisabledTimeConfig => {\n const cur = current as Date;\n if (cur == null) {\n return {} as NzSafeAny;\n }\n const now = addSeconds(this.now, offsetSeconds || 0);\n const nowHours = now.getHours();\n const nowMinutes = now.getMinutes();\n const curHours = cur.getHours();\n const isToday = this.getDiffDays(this.removeTime(cur)) === 0;\n return {\n nzDisabledHours: () => {\n if (!isToday) return [];\n return type === 'before' ? tick24.slice(0, nowHours) : tick24.slice(nowHours + 1);\n },\n nzDisabledMinutes: () => {\n if (isToday && curHours === nowHours) {\n return type === 'before' ? tick60.slice(0, nowMinutes) : tick60.slice(nowMinutes + 1);\n }\n return [];\n },\n nzDisabledSeconds: () => {\n if (isToday && curHours === nowHours && cur.getMinutes() === nowMinutes) {\n const nowSeconds = now.getSeconds();\n return type === 'before' ? tick60.slice(0, nowSeconds) : tick60.slice(nowSeconds + 1);\n }\n return [];\n }\n };\n };\n }\n /**\n * Disabled Before time (Default: now), Generally serves `nzDisabledTime`\n *\n * 禁用之前时间(默认:现在),一般服务于 `nzDisabledTime`\n */\n disabledBeforeTime(options?: { offsetSeconds?: number }): DisabledTimeFn {\n return this.baseDisabledTime('before', options?.offsetSeconds);\n }\n /**\n * Disabled After time (Default: now), Generally serves `nzDisabledTime`\n *\n * 禁用之后时间(默认:现在),一般服务于 `nzDisabledTime`\n */\n disabledAfterTime(options?: { offsetSeconds?: number }): DisabledTimeFn {\n return this.baseDisabledTime('after', options?.offsetSeconds);\n }\n}\n\nexport const dateTimePickerUtil = new DateTimePickerUtil();\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAuBA;;;;;;;;AAQG;SACa,eAAe,CAC7B,IAA0G,EAC1G,IAA6B,EAC7B,OAAqC,EAAA;AAErC,IAAA,IAAI,GAAG,IAAI;AACT,UAAE,OAAO,IAAI,KAAK,QAAQ;cACtB,KAAK,CAAC,IAAI,EAAE,qBAAqB,EAAE,IAAI,IAAI,EAAE,CAAC;AAChD,cAAE,IAAI,IAAI,CAAC,IAAI,CAAC;AAClB,UAAE,IAAI,IAAI,EAAE,CAAC;AACf,IAAA,MAAM,GAAG,GAAwB,EAAE,YAAY,EAAE,CAAC,EAAE,CAAC;AAErD,IAAA,IAAI,GAAiB,CAAC;IACtB,QAAQ,IAAI;AACV,QAAA,KAAK,OAAO;AACV,YAAA,GAAG,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;YACnB,MAAM;AACR,QAAA,KAAK,QAAQ;AACX,YAAA,GAAG,GAAG,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,IAAI,CAAC,CAA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,CAAC,OAAoC,EAAA;QACrD,OAAO,IAAI,CAAC,gBAAgB,CAAC,QAAQ,EAAE,OAAO,EAAE,aAAa,CAAC,CAAC;KAChE;AACD;;;;AAIG;AACH,IAAA,iBAAiB,CAAC,OAAoC,EAAA;QACpD,OAAO,IAAI,CAAC,gBAAgB,CAAC,OAAO,EAAE,OAAO,EAAE,aAAa,CAAC,CAAC;KAC/D;AACF,CAAA;AAEY,MAAA,kBAAkB,GAAG,IAAI,kBAAkB;;ACzHxD;;AAEG;;;;"}
@@ -410,10 +410,10 @@ class CurrencyService {
410
410
  : integerRes + (decimalRes === '' ? '' : `点${decimalRes}`));
411
411
  return ret;
412
412
  }
413
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyService, deps: [{ token: i1.YunzaiConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
414
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyService, providedIn: 'root' }); }
413
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyService, deps: [{ token: i1.YunzaiConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
414
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyService, providedIn: 'root' }); }
415
415
  }
416
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyService, decorators: [{
416
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyService, decorators: [{
417
417
  type: Injectable,
418
418
  args: [{ providedIn: 'root' }]
419
419
  }], ctorParameters: () => [{ type: i1.YunzaiConfigService }] });
@@ -1 +1 @@
1
- {"version":3,"file":"format.mjs","sources":["../../../../packages/util/format/string.ts","../../../../packages/util/format/validate.ts","../../../../packages/util/format/currency.types.ts","../../../../packages/util/format/currency.service.ts","../../../../packages/util/format/format.ts"],"sourcesContent":["import { deepGet } from '@yelon/util/other';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n/**\n * String formatting\n *\n * 字符串格式化\n * ```\n * format('this is ${name}', { name: 'asdf' })\n * // output: this is asdf\n * format('this is ${user.name}', { user: { name: 'asdf' } }, true)\n * // output: this is asdf\n * ```\n */\nexport function format(\n str: string | null | undefined,\n obj: NzSafeAny | null | undefined,\n needDeepGet: boolean = false\n): string {\n return (str || '').replace(/\\${([^}]+)}/g, (_work: string, key: string) =>\n needDeepGet ? deepGet(obj, key.split('.'), '') : (obj || {})[key] || ''\n );\n}\n\nexport interface FormatMaskOption {\n mask: string;\n tokens?: { [key: string]: FormatMaskToken };\n}\n\nexport interface FormatMaskToken {\n pattern: RegExp;\n default?: NzSafeAny;\n transform?: (char: string) => string;\n}\n\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 */\nexport function formatMask(value: string, option: string | FormatMaskOption): string {\n if (!value) {\n return '';\n }\n const opt: FormatMaskOption = {\n ...(typeof option === 'string' ? { mask: option } : option)\n };\n const tokens: { [key: string]: FormatMaskToken } = {\n '0': { pattern: /\\d/, default: '0' },\n '9': { pattern: /\\d/ },\n '#': { pattern: /[a-zA-Z0-9]/ },\n U: {\n pattern: /[a-zA-Z]/,\n transform: char => char.toLocaleUpperCase()\n },\n L: {\n pattern: /[a-zA-Z]/,\n transform: char => char.toLocaleLowerCase()\n },\n '*': {\n pattern: /.*/,\n transform: _ => `*`\n },\n ...opt.tokens\n };\n\n const splitValue = value.split('');\n return opt.mask\n .split('')\n .reduce((res, cur) => {\n const token = tokens[cur];\n if (!token) {\n res.push(cur);\n return res;\n }\n\n const value = splitValue.shift() ?? '';\n if (!token.pattern.test(value)) {\n if (token.default) res.push(token.default);\n return res;\n }\n\n if (typeof token.transform === 'function') {\n res.push(token.transform(value));\n } else {\n res.push(value);\n }\n return res;\n }, [] as string[])\n .join('');\n}\n","export const REGEX_STR = {\n num: `(([-+]?\\\\d+\\\\.\\\\d+)|([-+]?\\\\d+)|([-+]?\\\\.\\\\d+))(?:[eE]([-+]?\\\\d+))?`,\n idCard: `(^\\\\d{15}$)|(^\\\\d{17}(?:[0-9]|X)$)`,\n mobile: `^(0|\\\\+?86|17951)?1[0-9]{10}$`,\n url: `(((^https?:(?:\\/\\/)?)(?:[-;:&=\\\\+\\\\$,\\\\w]+@)?[A-Za-z0-9.-]+(?::\\\\d+)?|(?:www.|[-;:&=\\\\+\\\\$,\\\\w]+@)[A-Za-z0-9.-]+)((?:\\/[\\\\+~%\\\\/.\\\\w-_]*)?\\\\??(?:[-\\\\+=&;%@.\\\\w_]*)#?(?:[\\\\w]*))?)`,\n ip: `(?:^(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)(?:\\\\.(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)){3}$)|(?:^(?:(?:[a-fA-F\\\\d]{1,4}:){7}(?:[a-fA-F\\\\d]{1,4}|:)|(?:[a-fA-F\\\\d]{1,4}:){6}(?:(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)(?:\\\\.(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)){3}|:[a-fA-F\\\\d]{1,4}|:)|(?:[a-fA-F\\\\d]{1,4}:){5}(?::(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\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[1-9]\\\\d|\\\\d)){3}|(?::[a-fA-F\\\\d]{1,4}){1,7}|:)))(?:%[0-9a-zA-Z]{1,})?$)`,\n color: `(?:#|0x)(?:[a-f0-9]{3}|[a-f0-9]{6})\\\\b|(?:rgb|hsl)a?\\\\([^\\\\)]*\\\\)`,\n chinese: `[\\u4e00-\\u9fa5]+`\n};\n\nfunction genRegex(str: string, flags?: string): RegExp {\n return new RegExp(`^${str}$`, flags);\n}\n\nexport const REGEX = {\n num: genRegex(REGEX_STR.num),\n idCard: genRegex(REGEX_STR.idCard, 'i'),\n mobile: genRegex(REGEX_STR.mobile),\n url: genRegex(REGEX_STR.url),\n ip: genRegex(REGEX_STR.ip),\n color: genRegex(REGEX_STR.color),\n chinese: genRegex(REGEX_STR.chinese)\n};\n\n/**\n * Wheter is number\n *\n * 是否为数字\n */\nexport function isNum(value: string | number): boolean {\n return REGEX.num.test(value.toString());\n}\n\n/**\n * Wheter is integer\n *\n * 是否为整数\n */\nexport function isInt(value: string | number): boolean {\n return isNum(value) && parseInt(value.toString(), 10).toString() === value.toString();\n}\n\n/**\n * Wheter is decimal\n *\n * 是否为小数点数值\n */\nexport function isDecimal(value: string | number): boolean {\n return isNum(value) && !isInt(value);\n}\n\n/**\n * Wheter is People's Republic of China identity card\n *\n * 是否为中华人民共和国居民身份证\n */\nexport function isIdCard(value: string): boolean {\n return REGEX.idCard.test(value);\n}\n\n/**\n * Wheter is china mobile (China)\n *\n * 是否为手机号(中国)\n */\nexport function isMobile(value: string): boolean {\n return REGEX.mobile.test(value);\n}\n\n/**\n * Wheter is url address\n *\n * 是否URL地址\n */\nexport function isUrl(url: string): boolean {\n return REGEX.url.test(url);\n}\n\n/**\n * Wheter is IPv4 address (Support v4, v6)\n *\n * 是否IP4地址(支持v4、v6)\n */\nexport function isIp(ip: string): boolean {\n return REGEX.ip.test(ip);\n}\n\n/**\n * Wheter is color\n *\n * 是否颜色代码值\n */\nexport function isColor(color: string): boolean {\n return REGEX.color.test(color);\n}\n\n/**\n * Wheter is chinese\n *\n * 是否中文\n */\nexport function isChinese(value: string): boolean {\n return REGEX.chinese.test(value);\n}\n","export type CurrencyStartingUnit = 'yuan' | 'cent';\n\nexport interface CurrencyStartingUnitOptions {\n /**\n * The starting unit of the value, `yuan` means 元, `cent` means 分, default: `yuan`\n *\n * 值的起始单位,`yuan` 元,`cent` 分,默认:`yuan`\n */\n startingUnit?: CurrencyStartingUnit;\n}\n\nexport interface CurrencyFormatOptions extends CurrencyStartingUnitOptions {\n /**\n * Using `DEFAULT_CURRENCY_CODE` when value is `true\n *\n * 是否使用 `CurrencyPipe` 来替代\n */\n useAngular?: boolean;\n /**\n * 精度,默认:`2`\n */\n precision?: number;\n /**\n * 是否忽略精度 `.0` 或 `.00` 结尾的字符,默认:`true`\n */\n ignoreZeroPrecision?: boolean;\n\n /**\n * Use anguar `currency` pipe parse when is set, pls refer to [document](https://angular.io/api/common/CurrencyPipe)\n *\n * 若指定则表示使用 Angular 自带的 `currency` 管道来解析,见[文档](https://angular.cn/api/common/CurrencyPipe)\n */\n ngCurrency?: {\n display: 'code' | 'symbol' | 'symbol-narrow';\n currencyCode?: string;\n digitsInfo?: string;\n locale?: string;\n };\n}\n\n/**\n * Large number format filter, [Document](https://ng.yunzainfo.com/util/format/en#mega)\n *\n * 大数据格式化,[文档](https://ng.yunzainfo.com/util/format/en#mega)\n */\nexport interface CurrencyMegaOptions extends CurrencyStartingUnitOptions {\n /**\n * 精度,默认:`2`\n */\n precision?: number;\n\n /**\n * 单位国际化,默认:`{Q: '京', T: '兆', B: '亿', M: '万', K: '千',}`\n */\n unitI18n?: CurrencyMegaUnitI18n;\n}\n\nexport interface CurrencyMegaResult {\n raw: number | string;\n value: string;\n unit: string;\n unitI18n: string;\n}\n\nexport const CurrencyMega_Powers = [\n { unit: 'Q', value: Math.pow(10, 15) },\n { unit: 'T', value: Math.pow(10, 12) },\n { unit: 'B', value: Math.pow(10, 9) },\n { unit: 'M', value: Math.pow(10, 6) },\n { unit: 'K', value: 1000 }\n];\n\nexport interface CurrencyMegaUnitI18n {\n Q: string;\n T: string;\n B: string;\n M: string;\n K: string;\n}\n\nexport interface CurrencyCNYOptions extends CurrencyStartingUnitOptions {\n /**\n * Whether to return to uppercase notation, default: `true`\n *\n * 是否返回大写表示法,默认:`true`\n */\n inWords?: boolean;\n /**\n * Specify negative sign, default: `negative`\n *\n * 指定负数符号,默认:`负`\n */\n minusSymbol?: string;\n}\n","import { CurrencyPipe, formatNumber } from '@angular/common';\nimport { DEFAULT_CURRENCY_CODE, Injectable, LOCALE_ID, inject } from '@angular/core';\n\nimport { YunzaiConfigService, YunzaiUtilCurrencyConfig } from '@yelon/util/config';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nimport {\n CurrencyCNYOptions,\n CurrencyFormatOptions,\n CurrencyMegaOptions,\n CurrencyMegaResult,\n CurrencyMega_Powers\n} from './currency.types';\n\n@Injectable({ providedIn: 'root' })\nexport class CurrencyService {\n private readonly locale = inject(LOCALE_ID);\n private readonly defCurrencyCode = inject(DEFAULT_CURRENCY_CODE, { optional: true }) ?? 'USD';\n\n private c: YunzaiUtilCurrencyConfig;\n private readonly currencyPipe: CurrencyPipe;\n\n constructor(cog: YunzaiConfigService) {\n this.currencyPipe = new CurrencyPipe(this.locale, this.defCurrencyCode);\n this.c = cog.merge('utilCurrency', {\n startingUnit: 'yuan',\n megaUnit: { Q: '京', T: '兆', B: '亿', M: '万', K: '千' },\n precision: 2,\n ignoreZeroPrecision: true\n })!;\n }\n\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 format(value: number | string, options?: CurrencyFormatOptions): string {\n options = {\n startingUnit: this.c.startingUnit,\n precision: this.c.precision,\n ignoreZeroPrecision: this.c.ignoreZeroPrecision,\n ngCurrency: this.c.ngCurrency,\n ...options\n };\n let truthValue = Number(value);\n if (value == null || isNaN(truthValue)) {\n return '';\n }\n if (options.startingUnit === 'cent') {\n truthValue = truthValue / 100;\n }\n if (options.ngCurrency != null) {\n const cur = options.ngCurrency!;\n return this.currencyPipe.transform(\n truthValue,\n cur.currencyCode,\n cur.display,\n cur.digitsInfo,\n cur.locale || this.locale\n )!;\n }\n const res = formatNumber(\n truthValue,\n this.locale,\n `.${options.ignoreZeroPrecision ? 1 : options.precision}-${options.precision}`\n );\n return options.ignoreZeroPrecision ? res.replace(/(?:\\.[0]+)$/g, '') : res;\n }\n\n /**\n * Large number format filter\n *\n * 大数据格式化\n * ```ts\n * 1000 => { value: '1', unit: 'K', unitI18n: '千' }\n * 12456 => { value: '12.46', unit: 'K', unitI18n: '千' }\n * ```\n */\n mega(value: number | string, options?: CurrencyMegaOptions): CurrencyMegaResult {\n options = { precision: this.c.precision, unitI18n: this.c.megaUnit, startingUnit: this.c.startingUnit, ...options };\n let num = Number(value);\n const res: CurrencyMegaResult = { raw: value, value: '', unit: '', unitI18n: '' };\n if (isNaN(num) || num === 0) {\n res.value = value.toString();\n return res;\n }\n if (options.startingUnit === 'cent') {\n num = num / 100;\n }\n let abs = Math.abs(+num);\n const rounder = Math.pow(10, options.precision!);\n const isNegative = num < 0;\n for (const p of CurrencyMega_Powers) {\n let reduced = abs / p.value;\n\n reduced = Math.round(reduced * rounder) / rounder;\n\n if (reduced >= 1) {\n abs = reduced;\n res.unit = p.unit;\n break;\n }\n }\n\n res.value = (isNegative ? '-' : '') + abs;\n res.unitI18n = (options.unitI18n as { [key: string]: NzSafeAny })[res.unit];\n return res;\n }\n\n /**\n * Converted into RMB notation.\n *\n * 转化成人民币表示法\n */\n cny(value: number | string, options?: CurrencyCNYOptions): string {\n options = {\n inWords: true,\n minusSymbol: '负',\n startingUnit: this.c.startingUnit,\n ...options\n };\n\n value = Number(value);\n if (isNaN(value)) {\n return '';\n }\n if (options.startingUnit === 'cent') {\n value = value / 100;\n }\n value = value.toString();\n let integer: number | string;\n let decimal: number | string | null;\n [integer, decimal] = value.split('.');\n let symbol = '';\n if (integer.startsWith('-')) {\n symbol = options.minusSymbol!;\n integer = integer.substring(1);\n }\n if (/^-?\\d+$/.test(value)) {\n decimal = null;\n }\n integer = (+integer).toString();\n const inWords = options.inWords;\n const unit: { [key: string]: string[] } = {\n num: inWords\n ? ['', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖', '点']\n : ['', '一', '二', '三', '四', '五', '六', '七', '八', '九', '点'],\n radice: inWords\n ? [\n '',\n '拾',\n '佰',\n '仟',\n '万',\n '拾',\n '佰',\n '仟',\n '亿',\n '拾',\n '佰',\n '仟',\n '万亿',\n '拾',\n '佰',\n '仟',\n '兆',\n '拾',\n '佰',\n '仟'\n ]\n : [\n '',\n '十',\n '百',\n '千',\n '万',\n '十',\n '百',\n '千',\n '亿',\n '十',\n '百',\n '千',\n '万亿',\n '十',\n '百',\n '千',\n '兆',\n '十',\n '百',\n '千'\n ],\n dec: ['角', '分', '厘', '毫']\n };\n if (inWords) {\n value = (+value).toFixed(5).toString();\n }\n let integerRes = '';\n const integerCount = integer.length;\n if (integer === '0' || integerCount === 0) {\n integerRes = '零';\n } else {\n let cnDesc = '';\n for (let i = 0; i < integerCount; i++) {\n const n = +integer[i];\n const j = integerCount - i - 1;\n const isZero = i > 1 && n !== 0 && integer[i - 1] === '0';\n const cnZero = isZero ? '零' : '';\n const isEmpptyUnit = (n === 0 && j % 4 !== 0) || integer.substring(i - 3, i - 3 + 4) === '0000';\n const descMark = cnDesc;\n let cnNum = unit.num[n];\n\n cnDesc = isEmpptyUnit ? '' : unit.radice[j];\n // 第一位是一十\n if (i === 0 && cnNum === '一' && cnDesc === '十') cnNum = '';\n const isChangeEr =\n n > 1 &&\n cnNum === '二' && // 去除首位\n ['', '十', '百'].indexOf(cnDesc) === -1 && // 不读两\\两十\\两百\n descMark !== '十'; // 不读十两\n if (isChangeEr) cnNum = '两';\n integerRes += cnZero + cnNum + cnDesc;\n }\n }\n\n // 小数部分拼接\n let decimalRes = '';\n const decimalCount = decimal ? decimal.toString().length : 0;\n if (decimal === null) {\n decimalRes = inWords ? '整' : '';\n } else if (decimal === '0') {\n decimalRes = '零';\n } else {\n for (let i = 0; i < decimalCount; i++) {\n if (inWords && i > unit.dec.length - 1) break;\n const n = decimal[i];\n const cnZero = n === '0' ? '零' : '';\n const cnNum = unit.num[+n];\n const cnDesc = inWords ? unit.dec[i] : '';\n decimalRes += cnZero + cnNum + cnDesc;\n }\n }\n const ret =\n symbol +\n (inWords\n ? integerRes + (decimalRes === '零' ? '元整' : `元${decimalRes}`)\n : integerRes + (decimalRes === '' ? '' : `点${decimalRes}`));\n return ret;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AAGA;;;;;;;;;;AAUG;AACG,SAAU,MAAM,CACpB,GAA8B,EAC9B,GAAiC,EACjC,cAAuB,KAAK,EAAA;IAE5B,OAAO,CAAC,GAAG,IAAI,EAAE,EAAE,OAAO,CAAC,cAAc,EAAE,CAAC,KAAa,EAAE,GAAW,KACpE,WAAW,GAAG,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC,GAAG,CAAC,GAAG,IAAI,EAAE,EAAE,GAAG,CAAC,IAAI,EAAE,CACxE,CAAC;AACJ,CAAC;AAaD;;;;;;;;;;;;;;;;;;AAkBG;AACa,SAAA,UAAU,CAAC,KAAa,EAAE,MAAiC,EAAA;IACzE,IAAI,CAAC,KAAK,EAAE;AACV,QAAA,OAAO,EAAE,CAAC;KACX;AACD,IAAA,MAAM,GAAG,GAAqB;AAC5B,QAAA,IAAI,OAAO,MAAM,KAAK,QAAQ,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,MAAM;KAC3D,CAAC;AACF,IAAA,MAAM,MAAM,GAAuC;QACjD,GAAG,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,GAAG,EAAE;AACpC,QAAA,GA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,MAAM,GAAG,GACP,MAAM;AACN,aAAC,OAAO;AACN,kBAAE,UAAU,IAAI,UAAU,KAAK,GAAG,GAAG,IAAI,GAAG,CAAI,CAAA,EAAA,UAAU,EAAE,CAAC;AAC7D,kBAAE,UAAU,IAAI,UAAU,KAAK,EAAE,GAAG,EAAE,GAAG,CAAA,CAAA,EAAI,UAAU,CAAE,CAAA,CAAC,CAAC,CAAC;AAChE,QAAA,OAAO,GAAG,CAAC;KACZ;8GA9OU,eAAe,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,EAAA,CAAA,mBAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA,EAAA;AAAf,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,cADF,MAAM,EAAA,CAAA,CAAA,EAAA;;2FACnB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAD3B,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE,CAAA;;;ACdlC;;AAEG;;;;"}
1
+ {"version":3,"file":"format.mjs","sources":["../../../../packages/util/format/string.ts","../../../../packages/util/format/validate.ts","../../../../packages/util/format/currency.types.ts","../../../../packages/util/format/currency.service.ts","../../../../packages/util/format/format.ts"],"sourcesContent":["import { deepGet } from '@yelon/util/other';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n/**\n * String formatting\n *\n * 字符串格式化\n * ```\n * format('this is ${name}', { name: 'asdf' })\n * // output: this is asdf\n * format('this is ${user.name}', { user: { name: 'asdf' } }, true)\n * // output: this is asdf\n * ```\n */\nexport function format(\n str: string | null | undefined,\n obj: NzSafeAny | null | undefined,\n needDeepGet: boolean = false\n): string {\n return (str || '').replace(/\\${([^}]+)}/g, (_work: string, key: string) =>\n needDeepGet ? deepGet(obj, key.split('.'), '') : (obj || {})[key] || ''\n );\n}\n\nexport interface FormatMaskOption {\n mask: string;\n tokens?: { [key: string]: FormatMaskToken };\n}\n\nexport interface FormatMaskToken {\n pattern: RegExp;\n default?: NzSafeAny;\n transform?: (char: string) => string;\n}\n\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 */\nexport function formatMask(value: string, option: string | FormatMaskOption): string {\n if (!value) {\n return '';\n }\n const opt: FormatMaskOption = {\n ...(typeof option === 'string' ? { mask: option } : option)\n };\n const tokens: { [key: string]: FormatMaskToken } = {\n '0': { pattern: /\\d/, default: '0' },\n '9': { pattern: /\\d/ },\n '#': { pattern: /[a-zA-Z0-9]/ },\n U: {\n pattern: /[a-zA-Z]/,\n transform: char => char.toLocaleUpperCase()\n },\n L: {\n pattern: /[a-zA-Z]/,\n transform: char => char.toLocaleLowerCase()\n },\n '*': {\n pattern: /.*/,\n transform: _ => `*`\n },\n ...opt.tokens\n };\n\n const splitValue = value.split('');\n return opt.mask\n .split('')\n .reduce((res, cur) => {\n const token = tokens[cur];\n if (!token) {\n res.push(cur);\n return res;\n }\n\n const value = splitValue.shift() ?? '';\n if (!token.pattern.test(value)) {\n if (token.default) res.push(token.default);\n return res;\n }\n\n if (typeof token.transform === 'function') {\n res.push(token.transform(value));\n } else {\n res.push(value);\n }\n return res;\n }, [] as string[])\n .join('');\n}\n","export const REGEX_STR = {\n num: `(([-+]?\\\\d+\\\\.\\\\d+)|([-+]?\\\\d+)|([-+]?\\\\.\\\\d+))(?:[eE]([-+]?\\\\d+))?`,\n idCard: `(^\\\\d{15}$)|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\\d]{1,4}){0,2}:(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)(?:\\\\.(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)){3}|(?::[a-fA-F\\\\d]{1,4}){1,4}|:)|(?:[a-fA-F\\\\d]{1,4}:){2}(?:(?::[a-fA-F\\\\d]{1,4}){0,3}:(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)(?:\\\\.(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)){3}|(?::[a-fA-F\\\\d]{1,4}){1,5}|:)|(?:[a-fA-F\\\\d]{1,4}:){1}(?:(?::[a-fA-F\\\\d]{1,4}){0,4}:(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)(?:\\\\.(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)){3}|(?::[a-fA-F\\\\d]{1,4}){1,6}|:)|(?::(?:(?::[a-fA-F\\\\d]{1,4}){0,5}:(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)(?:\\\\.(?:25[0-5]|2[0-4]\\\\d|1\\\\d\\\\d|[1-9]\\\\d|\\\\d)){3}|(?::[a-fA-F\\\\d]{1,4}){1,7}|:)))(?:%[0-9a-zA-Z]{1,})?$)`,\n color: `(?:#|0x)(?:[a-f0-9]{3}|[a-f0-9]{6})\\\\b|(?:rgb|hsl)a?\\\\([^\\\\)]*\\\\)`,\n chinese: `[\\u4e00-\\u9fa5]+`\n};\n\nfunction genRegex(str: string, flags?: string): RegExp {\n return new RegExp(`^${str}$`, flags);\n}\n\nexport const REGEX = {\n num: genRegex(REGEX_STR.num),\n idCard: genRegex(REGEX_STR.idCard, 'i'),\n mobile: genRegex(REGEX_STR.mobile),\n url: genRegex(REGEX_STR.url),\n ip: genRegex(REGEX_STR.ip),\n color: genRegex(REGEX_STR.color),\n chinese: genRegex(REGEX_STR.chinese)\n};\n\n/**\n * Wheter is number\n *\n * 是否为数字\n */\nexport function isNum(value: string | number): boolean {\n return REGEX.num.test(value.toString());\n}\n\n/**\n * Wheter is integer\n *\n * 是否为整数\n */\nexport function isInt(value: string | number): boolean {\n return isNum(value) && parseInt(value.toString(), 10).toString() === value.toString();\n}\n\n/**\n * Wheter is decimal\n *\n * 是否为小数点数值\n */\nexport function isDecimal(value: string | number): boolean {\n return isNum(value) && !isInt(value);\n}\n\n/**\n * Wheter is People's Republic of China identity card\n *\n * 是否为中华人民共和国居民身份证\n */\nexport function isIdCard(value: string): boolean {\n return REGEX.idCard.test(value);\n}\n\n/**\n * Wheter is china mobile (China)\n *\n * 是否为手机号(中国)\n */\nexport function isMobile(value: string): boolean {\n return REGEX.mobile.test(value);\n}\n\n/**\n * Wheter is url address\n *\n * 是否URL地址\n */\nexport function isUrl(url: string): boolean {\n return REGEX.url.test(url);\n}\n\n/**\n * Wheter is IPv4 address (Support v4, v6)\n *\n * 是否IP4地址(支持v4、v6)\n */\nexport function isIp(ip: string): boolean {\n return REGEX.ip.test(ip);\n}\n\n/**\n * Wheter is color\n *\n * 是否颜色代码值\n */\nexport function isColor(color: string): boolean {\n return REGEX.color.test(color);\n}\n\n/**\n * Wheter is chinese\n *\n * 是否中文\n */\nexport function isChinese(value: string): boolean {\n return REGEX.chinese.test(value);\n}\n","export type CurrencyStartingUnit = 'yuan' | 'cent';\n\nexport interface CurrencyStartingUnitOptions {\n /**\n * The starting unit of the value, `yuan` means 元, `cent` means 分, default: `yuan`\n *\n * 值的起始单位,`yuan` 元,`cent` 分,默认:`yuan`\n */\n startingUnit?: CurrencyStartingUnit;\n}\n\nexport interface CurrencyFormatOptions extends CurrencyStartingUnitOptions {\n /**\n * Using `DEFAULT_CURRENCY_CODE` when value is `true\n *\n * 是否使用 `CurrencyPipe` 来替代\n */\n useAngular?: boolean;\n /**\n * 精度,默认:`2`\n */\n precision?: number;\n /**\n * 是否忽略精度 `.0` 或 `.00` 结尾的字符,默认:`true`\n */\n ignoreZeroPrecision?: boolean;\n\n /**\n * Use anguar `currency` pipe parse when is set, pls refer to [document](https://angular.io/api/common/CurrencyPipe)\n *\n * 若指定则表示使用 Angular 自带的 `currency` 管道来解析,见[文档](https://angular.cn/api/common/CurrencyPipe)\n */\n ngCurrency?: {\n display: 'code' | 'symbol' | 'symbol-narrow';\n currencyCode?: string;\n digitsInfo?: string;\n locale?: string;\n };\n}\n\n/**\n * Large number format filter, [Document](https://ng.yunzainfo.com/util/format/en#mega)\n *\n * 大数据格式化,[文档](https://ng.yunzainfo.com/util/format/en#mega)\n */\nexport interface CurrencyMegaOptions extends CurrencyStartingUnitOptions {\n /**\n * 精度,默认:`2`\n */\n precision?: number;\n\n /**\n * 单位国际化,默认:`{Q: '京', T: '兆', B: '亿', M: '万', K: '千',}`\n */\n unitI18n?: CurrencyMegaUnitI18n;\n}\n\nexport interface CurrencyMegaResult {\n raw: number | string;\n value: string;\n unit: string;\n unitI18n: string;\n}\n\nexport const CurrencyMega_Powers = [\n { unit: 'Q', value: Math.pow(10, 15) },\n { unit: 'T', value: Math.pow(10, 12) },\n { unit: 'B', value: Math.pow(10, 9) },\n { unit: 'M', value: Math.pow(10, 6) },\n { unit: 'K', value: 1000 }\n];\n\nexport interface CurrencyMegaUnitI18n {\n Q: string;\n T: string;\n B: string;\n M: string;\n K: string;\n}\n\nexport interface CurrencyCNYOptions extends CurrencyStartingUnitOptions {\n /**\n * Whether to return to uppercase notation, default: `true`\n *\n * 是否返回大写表示法,默认:`true`\n */\n inWords?: boolean;\n /**\n * Specify negative sign, default: `negative`\n *\n * 指定负数符号,默认:`负`\n */\n minusSymbol?: string;\n}\n","import { CurrencyPipe, formatNumber } from '@angular/common';\nimport { DEFAULT_CURRENCY_CODE, Injectable, LOCALE_ID, inject } from '@angular/core';\n\nimport { YunzaiConfigService, YunzaiUtilCurrencyConfig } from '@yelon/util/config';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nimport {\n CurrencyCNYOptions,\n CurrencyFormatOptions,\n CurrencyMegaOptions,\n CurrencyMegaResult,\n CurrencyMega_Powers\n} from './currency.types';\n\n@Injectable({ providedIn: 'root' })\nexport class CurrencyService {\n private readonly locale = inject(LOCALE_ID);\n private readonly defCurrencyCode = inject(DEFAULT_CURRENCY_CODE, { optional: true }) ?? 'USD';\n\n private c: YunzaiUtilCurrencyConfig;\n private readonly currencyPipe: CurrencyPipe;\n\n constructor(cog: YunzaiConfigService) {\n this.currencyPipe = new CurrencyPipe(this.locale, this.defCurrencyCode);\n this.c = cog.merge('utilCurrency', {\n startingUnit: 'yuan',\n megaUnit: { Q: '京', T: '兆', B: '亿', M: '万', K: '千' },\n precision: 2,\n ignoreZeroPrecision: true\n })!;\n }\n\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 format(value: number | string, options?: CurrencyFormatOptions): string {\n options = {\n startingUnit: this.c.startingUnit,\n precision: this.c.precision,\n ignoreZeroPrecision: this.c.ignoreZeroPrecision,\n ngCurrency: this.c.ngCurrency,\n ...options\n };\n let truthValue = Number(value);\n if (value == null || isNaN(truthValue)) {\n return '';\n }\n if (options.startingUnit === 'cent') {\n truthValue = truthValue / 100;\n }\n if (options.ngCurrency != null) {\n const cur = options.ngCurrency!;\n return this.currencyPipe.transform(\n truthValue,\n cur.currencyCode,\n cur.display,\n cur.digitsInfo,\n cur.locale || this.locale\n )!;\n }\n const res = formatNumber(\n truthValue,\n this.locale,\n `.${options.ignoreZeroPrecision ? 1 : options.precision}-${options.precision}`\n );\n return options.ignoreZeroPrecision ? res.replace(/(?:\\.[0]+)$/g, '') : res;\n }\n\n /**\n * Large number format filter\n *\n * 大数据格式化\n * ```ts\n * 1000 => { value: '1', unit: 'K', unitI18n: '千' }\n * 12456 => { value: '12.46', unit: 'K', unitI18n: '千' }\n * ```\n */\n mega(value: number | string, options?: CurrencyMegaOptions): CurrencyMegaResult {\n options = { precision: this.c.precision, unitI18n: this.c.megaUnit, startingUnit: this.c.startingUnit, ...options };\n let num = Number(value);\n const res: CurrencyMegaResult = { raw: value, value: '', unit: '', unitI18n: '' };\n if (isNaN(num) || num === 0) {\n res.value = value.toString();\n return res;\n }\n if (options.startingUnit === 'cent') {\n num = num / 100;\n }\n let abs = Math.abs(+num);\n const rounder = Math.pow(10, options.precision!);\n const isNegative = num < 0;\n for (const p of CurrencyMega_Powers) {\n let reduced = abs / p.value;\n\n reduced = Math.round(reduced * rounder) / rounder;\n\n if (reduced >= 1) {\n abs = reduced;\n res.unit = p.unit;\n break;\n }\n }\n\n res.value = (isNegative ? '-' : '') + abs;\n res.unitI18n = (options.unitI18n as { [key: string]: NzSafeAny })[res.unit];\n return res;\n }\n\n /**\n * Converted into RMB notation.\n *\n * 转化成人民币表示法\n */\n cny(value: number | string, options?: CurrencyCNYOptions): string {\n options = {\n inWords: true,\n minusSymbol: '负',\n startingUnit: this.c.startingUnit,\n ...options\n };\n\n value = Number(value);\n if (isNaN(value)) {\n return '';\n }\n if (options.startingUnit === 'cent') {\n value = value / 100;\n }\n value = value.toString();\n let integer: number | string;\n let decimal: number | string | null;\n [integer, decimal] = value.split('.');\n let symbol = '';\n if (integer.startsWith('-')) {\n symbol = options.minusSymbol!;\n integer = integer.substring(1);\n }\n if (/^-?\\d+$/.test(value)) {\n decimal = null;\n }\n integer = (+integer).toString();\n const inWords = options.inWords;\n const unit: { [key: string]: string[] } = {\n num: inWords\n ? ['', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖', '点']\n : ['', '一', '二', '三', '四', '五', '六', '七', '八', '九', '点'],\n radice: inWords\n ? [\n '',\n '拾',\n '佰',\n '仟',\n '万',\n '拾',\n '佰',\n '仟',\n '亿',\n '拾',\n '佰',\n '仟',\n '万亿',\n '拾',\n '佰',\n '仟',\n '兆',\n '拾',\n '佰',\n '仟'\n ]\n : [\n '',\n '十',\n '百',\n '千',\n '万',\n '十',\n '百',\n '千',\n '亿',\n '十',\n '百',\n '千',\n '万亿',\n '十',\n '百',\n '千',\n '兆',\n '十',\n '百',\n '千'\n ],\n dec: ['角', '分', '厘', '毫']\n };\n if (inWords) {\n value = (+value).toFixed(5).toString();\n }\n let integerRes = '';\n const integerCount = integer.length;\n if (integer === '0' || integerCount === 0) {\n integerRes = '零';\n } else {\n let cnDesc = '';\n for (let i = 0; i < integerCount; i++) {\n const n = +integer[i];\n const j = integerCount - i - 1;\n const isZero = i > 1 && n !== 0 && integer[i - 1] === '0';\n const cnZero = isZero ? '零' : '';\n const isEmpptyUnit = (n === 0 && j % 4 !== 0) || integer.substring(i - 3, i - 3 + 4) === '0000';\n const descMark = cnDesc;\n let cnNum = unit.num[n];\n\n cnDesc = isEmpptyUnit ? '' : unit.radice[j];\n // 第一位是一十\n if (i === 0 && cnNum === '一' && cnDesc === '十') cnNum = '';\n const isChangeEr =\n n > 1 &&\n cnNum === '二' && // 去除首位\n ['', '十', '百'].indexOf(cnDesc) === -1 && // 不读两\\两十\\两百\n descMark !== '十'; // 不读十两\n if (isChangeEr) cnNum = '两';\n integerRes += cnZero + cnNum + cnDesc;\n }\n }\n\n // 小数部分拼接\n let decimalRes = '';\n const decimalCount = decimal ? decimal.toString().length : 0;\n if (decimal === null) {\n decimalRes = inWords ? '整' : '';\n } else if (decimal === '0') {\n decimalRes = '零';\n } else {\n for (let i = 0; i < decimalCount; i++) {\n if (inWords && i > unit.dec.length - 1) break;\n const n = decimal[i];\n const cnZero = n === '0' ? '零' : '';\n const cnNum = unit.num[+n];\n const cnDesc = inWords ? unit.dec[i] : '';\n decimalRes += cnZero + cnNum + cnDesc;\n }\n }\n const ret =\n symbol +\n (inWords\n ? integerRes + (decimalRes === '零' ? '元整' : `元${decimalRes}`)\n : integerRes + (decimalRes === '' ? '' : `点${decimalRes}`));\n return ret;\n }\n}\n","/**\n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AA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA,EAAA;AAAf,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,cADF,MAAM,EAAA,CAAA,CAAA,EAAA;;2FACnB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAD3B,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE,CAAA;;;ACdlC;;AAEG;;;;"}
@@ -231,10 +231,10 @@ class LazyService {
231
231
  resolve(item);
232
232
  });
233
233
  }
234
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: LazyService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
235
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: LazyService, providedIn: 'root' }); }
234
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: LazyService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
235
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: LazyService, providedIn: 'root' }); }
236
236
  }
237
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: LazyService, decorators: [{
237
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: LazyService, decorators: [{
238
238
  type: Injectable,
239
239
  args: [{ providedIn: 'root' }]
240
240
  }] });
@@ -532,10 +532,10 @@ class PathToRegexpService {
532
532
  }
533
533
  return this.stringToRegexp(/** @type {string} */ path, keys, options);
534
534
  }
535
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: PathToRegexpService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
536
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: PathToRegexpService, providedIn: 'root' }); }
535
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: PathToRegexpService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
536
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: PathToRegexpService, providedIn: 'root' }); }
537
537
  }
538
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: PathToRegexpService, decorators: [{
538
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: PathToRegexpService, decorators: [{
539
539
  type: Injectable,
540
540
  args: [{
541
541
  providedIn: 'root'
@@ -16,10 +16,10 @@ class CurrencyMegaPipe {
16
16
  const res = this.srv.mega(value, options);
17
17
  return res.value + (this.isCN ? res.unitI18n : res.unit);
18
18
  }
19
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyMegaPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
20
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: CurrencyMegaPipe, isStandalone: true, name: "mega" }); }
19
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyMegaPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
20
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: CurrencyMegaPipe, isStandalone: true, name: "mega" }); }
21
21
  }
22
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyMegaPipe, decorators: [{
22
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyMegaPipe, decorators: [{
23
23
  type: Pipe,
24
24
  args: [{ name: 'mega', standalone: true }]
25
25
  }] });
@@ -40,10 +40,10 @@ class CurrencyPricePipe {
40
40
  transform(value, options) {
41
41
  return this.srv.format(value, options);
42
42
  }
43
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPricePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
44
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPricePipe, isStandalone: true, name: "price" }); }
43
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPricePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
44
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPricePipe, isStandalone: true, name: "price" }); }
45
45
  }
46
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPricePipe, decorators: [{
46
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPricePipe, decorators: [{
47
47
  type: Pipe,
48
48
  args: [{ name: 'price', standalone: true }]
49
49
  }] });
@@ -60,21 +60,21 @@ class CurrencyCNYPipe {
60
60
  transform(value, options) {
61
61
  return this.srv.cny(value, options);
62
62
  }
63
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyCNYPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
64
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: CurrencyCNYPipe, isStandalone: true, name: "cny" }); }
63
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyCNYPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
64
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: CurrencyCNYPipe, isStandalone: true, name: "cny" }); }
65
65
  }
66
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyCNYPipe, decorators: [{
66
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyCNYPipe, decorators: [{
67
67
  type: Pipe,
68
68
  args: [{ name: 'cny', standalone: true }]
69
69
  }] });
70
70
 
71
71
  const PIPES = [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe];
72
72
  class CurrencyPipeModule {
73
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
74
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPipeModule, imports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe], exports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe] }); }
75
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPipeModule }); }
73
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
74
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPipeModule, imports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe], exports: [CurrencyMegaPipe, CurrencyPricePipe, CurrencyCNYPipe] }); }
75
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPipeModule }); }
76
76
  }
77
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: CurrencyPipeModule, decorators: [{
77
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: CurrencyPipeModule, decorators: [{
78
78
  type: NgModule,
79
79
  args: [{
80
80
  imports: PIPES,
@@ -11,21 +11,21 @@ class FilterPipe {
11
11
  transform(array, matcher, ...args) {
12
12
  return array.filter(i => matcher(i, ...args));
13
13
  }
14
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
15
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: FilterPipe, isStandalone: true, name: "filter", pure: false }); }
14
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
15
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: FilterPipe, isStandalone: true, name: "filter", pure: false }); }
16
16
  }
17
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipe, decorators: [{
17
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipe, decorators: [{
18
18
  type: Pipe,
19
19
  args: [{ name: 'filter', standalone: true, pure: false }]
20
20
  }] });
21
21
 
22
22
  const PIPES = [FilterPipe];
23
23
  class FilterPipeModule {
24
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
25
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: FilterPipeModule, imports: [FilterPipe], exports: [FilterPipe] }); }
26
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipeModule }); }
24
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
25
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: FilterPipeModule, imports: [FilterPipe], exports: [FilterPipe] }); }
26
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipeModule }); }
27
27
  }
28
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FilterPipeModule, decorators: [{
28
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FilterPipeModule, decorators: [{
29
29
  type: NgModule,
30
30
  args: [{
31
31
  imports: PIPES,
@@ -25,21 +25,21 @@ class FormatMaskPipe {
25
25
  transform(value, mask) {
26
26
  return formatMask(value, mask);
27
27
  }
28
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatMaskPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
29
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: FormatMaskPipe, isStandalone: true, name: "mask" }); }
28
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatMaskPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
29
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: FormatMaskPipe, isStandalone: true, name: "mask" }); }
30
30
  }
31
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatMaskPipe, decorators: [{
31
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatMaskPipe, decorators: [{
32
32
  type: Pipe,
33
33
  args: [{ name: 'mask', standalone: true }]
34
34
  }] });
35
35
 
36
36
  const PIPES = [FormatMaskPipe];
37
37
  class FormatPipeModule {
38
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
39
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.6", ngImport: i0, type: FormatPipeModule, imports: [FormatMaskPipe], exports: [FormatMaskPipe] }); }
40
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatPipeModule }); }
38
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatPipeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
39
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: FormatPipeModule, imports: [FormatMaskPipe], exports: [FormatMaskPipe] }); }
40
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatPipeModule }); }
41
41
  }
42
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.6", ngImport: i0, type: FormatPipeModule, decorators: [{
42
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: FormatPipeModule, decorators: [{
43
43
  type: NgModule,
44
44
  args: [{
45
45
  imports: PIPES,
@@ -12,7 +12,7 @@ export declare class PathToRegexpService {
12
12
  repeat: boolean;
13
13
  pattern: any;
14
14
  })[];
15
- compile(str: NzSafeAny, options: NzSafeAny): (data: any, options: any) => string;
15
+ compile(str: NzSafeAny, options: NzSafeAny): (data: NzSafeAny, options: NzSafeAny) => string;
16
16
  tokensToFunction(tokens: NzSafeAny, options: NzSafeAny): (data: NzSafeAny, options: NzSafeAny) => string;
17
17
  escapeString(str: NzSafeAny): any;
18
18
  escapeGroup(group: NzSafeAny): any;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yelon/util",
3
- "version": "18.0.1",
3
+ "version": "18.1.0",
4
4
  "author": "yunzai-bot<yunzai-bot@outlook.com>",
5
5
  "license": "MIT",
6
6
  "repository": {