@yelon/util 16.4.5 → 17.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (111) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +6 -2
  3. package/browser/cookie.service.d.ts +2 -5
  4. package/browser/is-empty.d.ts +2 -2
  5. package/browser/scroll.service.d.ts +3 -6
  6. package/config/auth/auth.type.d.ts +2 -10
  7. package/config/cache/cache.type.d.ts +26 -0
  8. package/config/config.types.d.ts +5 -2
  9. package/config/index.d.ts +2 -2
  10. package/config/mock/mock.type.d.ts +0 -4
  11. package/config/theme/http.type.d.ts +3 -2
  12. package/config/theme/pipe.type.d.ts +3 -0
  13. package/date-time/time.d.ts +16 -8
  14. package/decorator/convert.d.ts +8 -0
  15. package/decorator/zone-outside.d.ts +2 -2
  16. package/esm2022/array/array-type.service.mjs +1 -1
  17. package/esm2022/array/array.service.mjs +6 -5
  18. package/esm2022/browser/cookie.service.mjs +11 -14
  19. package/esm2022/browser/copy.mjs +1 -1
  20. package/esm2022/browser/is-empty.mjs +3 -3
  21. package/esm2022/browser/scroll.service.mjs +11 -14
  22. package/esm2022/browser/style.mjs +1 -1
  23. package/esm2022/config/auth/auth.type.mjs +1 -1
  24. package/esm2022/config/cache/cache.type.mjs +1 -1
  25. package/esm2022/config/config.service.mjs +7 -6
  26. package/esm2022/config/config.types.mjs +5 -2
  27. package/esm2022/config/index.mjs +3 -3
  28. package/esm2022/config/mock/mock.type.mjs +1 -1
  29. package/esm2022/config/theme/http.type.mjs +1 -1
  30. package/esm2022/config/theme/pipe.type.mjs +2 -0
  31. package/esm2022/date-time/picker.mjs +1 -1
  32. package/esm2022/date-time/time.mjs +16 -11
  33. package/esm2022/decorator/convert.mjs +9 -1
  34. package/esm2022/decorator/zone-outside.mjs +3 -3
  35. package/esm2022/form/match-control.mjs +1 -1
  36. package/esm2022/format/currency.service.mjs +10 -15
  37. package/esm2022/format/string.mjs +1 -1
  38. package/esm2022/index.mjs +1 -2
  39. package/esm2022/math/in-range.mjs +1 -1
  40. package/esm2022/math/round.mjs +1 -1
  41. package/esm2022/mcache/localStorageUtils.mjs +1 -1
  42. package/esm2022/mtypes/header-menu.type.mjs +1 -1
  43. package/esm2022/mtypes/menu.type.mjs +1 -1
  44. package/esm2022/mtypes/page.mjs +1 -1
  45. package/esm2022/other/assert.mjs +2 -2
  46. package/esm2022/other/deep.mjs +1 -1
  47. package/esm2022/other/favicon.mjs +1 -1
  48. package/esm2022/other/index.mjs +2 -2
  49. package/esm2022/other/lazy.service.mjs +8 -11
  50. package/esm2022/other/logger.mjs +1 -1
  51. package/esm2022/other/path-to-regexp.service.mjs +6 -6
  52. package/esm2022/pipes/currency/cny.pipe.mjs +15 -15
  53. package/esm2022/pipes/currency/mega.pipe.mjs +16 -20
  54. package/esm2022/pipes/currency/module.mjs +6 -6
  55. package/esm2022/pipes/currency/price.pipe.mjs +19 -19
  56. package/esm2022/pipes/filter/filter.pipe.mjs +11 -10
  57. package/esm2022/pipes/filter/module.mjs +6 -6
  58. package/esm2022/pipes/format/mask.pipe.mjs +24 -24
  59. package/esm2022/pipes/format/module.mjs +6 -6
  60. package/esm2022/token/window.mjs +1 -1
  61. package/fesm2022/array.mjs +5 -4
  62. package/fesm2022/array.mjs.map +1 -1
  63. package/fesm2022/browser.mjs +20 -26
  64. package/fesm2022/browser.mjs.map +1 -1
  65. package/fesm2022/config.mjs +11 -7
  66. package/fesm2022/config.mjs.map +1 -1
  67. package/fesm2022/date-time.mjs +15 -10
  68. package/fesm2022/date-time.mjs.map +1 -1
  69. package/fesm2022/decorator.mjs +10 -2
  70. package/fesm2022/decorator.mjs.map +1 -1
  71. package/fesm2022/form.mjs.map +1 -1
  72. package/fesm2022/format.mjs +9 -14
  73. package/fesm2022/format.mjs.map +1 -1
  74. package/fesm2022/math.mjs.map +1 -1
  75. package/fesm2022/mcache.mjs.map +1 -1
  76. package/fesm2022/mtypes.mjs.map +1 -1
  77. package/fesm2022/other.mjs +17 -20
  78. package/fesm2022/other.mjs.map +1 -1
  79. package/fesm2022/pipe-currency.mjs +48 -52
  80. package/fesm2022/pipe-currency.mjs.map +1 -1
  81. package/fesm2022/pipe-filter.mjs +15 -14
  82. package/fesm2022/pipe-filter.mjs.map +1 -1
  83. package/fesm2022/pipe-format.mjs +28 -28
  84. package/fesm2022/pipe-format.mjs.map +1 -1
  85. package/fesm2022/token.mjs.map +1 -1
  86. package/fesm2022/yelon-util.mjs +0 -1
  87. package/fesm2022/yelon-util.mjs.map +1 -1
  88. package/format/currency.service.d.ts +3 -2
  89. package/index.d.ts +0 -1
  90. package/mtypes/header-menu.type.d.ts +3 -2
  91. package/mtypes/menu.type.d.ts +6 -5
  92. package/mtypes/page.d.ts +2 -1
  93. package/other/index.d.ts +1 -1
  94. package/other/lazy.service.d.ts +1 -2
  95. package/other/path-to-regexp.service.d.ts +12 -11
  96. package/package.json +14 -20
  97. package/pipes/currency/cny.pipe.d.ts +8 -9
  98. package/pipes/currency/mega.pipe.d.ts +8 -9
  99. package/pipes/currency/module.d.ts +1 -1
  100. package/pipes/currency/price.pipe.d.ts +12 -13
  101. package/pipes/filter/filter.pipe.d.ts +6 -6
  102. package/pipes/filter/module.d.ts +1 -1
  103. package/pipes/format/mask.pipe.d.ts +20 -20
  104. package/pipes/format/module.d.ts +1 -1
  105. package/analysis/global-event.subject.d.ts +0 -7
  106. package/analysis/index.d.ts +0 -1
  107. package/esm2022/analysis/analysis.mjs +0 -5
  108. package/esm2022/analysis/global-event.subject.mjs +0 -17
  109. package/esm2022/analysis/index.mjs +0 -2
  110. package/fesm2022/analysis.mjs +0 -24
  111. package/fesm2022/analysis.mjs.map +0 -1
@@ -1,19 +1,18 @@
1
1
  import { PipeTransform } from '@angular/core';
2
- import { CurrencyFormatOptions, CurrencyService } from '@yelon/util/format';
2
+ import { CurrencyFormatOptions } from '@yelon/util/format';
3
3
  import * as i0 from "@angular/core";
4
+ /**
5
+ * Format a number with commas as thousands separators
6
+ *
7
+ * 格式化货币,用逗号将数字格式化为千位分隔符
8
+ * ```ts
9
+ * 10000 => `10,000`
10
+ * 10000.567 => `10,000.57`
11
+ * ```
12
+ */
4
13
  export declare class CurrencyPricePipe implements PipeTransform {
5
- private srv;
6
- constructor(srv: CurrencyService);
7
- /**
8
- * Format a number with commas as thousands separators
9
- *
10
- * 格式化货币,用逗号将数字格式化为千位分隔符
11
- * ```ts
12
- * 10000 => `10,000`
13
- * 10000.567 => `10,000.57`
14
- * ```
15
- */
14
+ private readonly srv;
16
15
  transform(value: number | string, options?: CurrencyFormatOptions): string;
17
16
  static ɵfac: i0.ɵɵFactoryDeclaration<CurrencyPricePipe, never>;
18
- static ɵpipe: i0.ɵɵPipeDeclaration<CurrencyPricePipe, "price", false>;
17
+ static ɵpipe: i0.ɵɵPipeDeclaration<CurrencyPricePipe, "price", true>;
19
18
  }
@@ -1,13 +1,13 @@
1
1
  import { PipeTransform } from '@angular/core';
2
2
  import type { NzSafeAny } from 'ng-zorro-antd/core/types';
3
3
  import * as i0 from "@angular/core";
4
+ /**
5
+ * Filter array
6
+ *
7
+ * 过滤数组
8
+ */
4
9
  export declare class FilterPipe implements PipeTransform {
5
- /**
6
- * Filter array
7
- *
8
- * 过滤数组
9
- */
10
10
  transform<T>(array: readonly T[], matcher: (item: T, ...args: NzSafeAny[]) => boolean, ...args: NzSafeAny[]): T[];
11
11
  static ɵfac: i0.ɵɵFactoryDeclaration<FilterPipe, never>;
12
- static ɵpipe: i0.ɵɵPipeDeclaration<FilterPipe, "filter", false>;
12
+ static ɵpipe: i0.ɵɵPipeDeclaration<FilterPipe, "filter", true>;
13
13
  }
@@ -2,6 +2,6 @@ import * as i0 from "@angular/core";
2
2
  import * as i1 from "./filter.pipe";
3
3
  export declare class FilterPipeModule {
4
4
  static ɵfac: i0.ɵɵFactoryDeclaration<FilterPipeModule, never>;
5
- static ɵmod: i0.ɵɵNgModuleDeclaration<FilterPipeModule, [typeof i1.FilterPipe], never, [typeof i1.FilterPipe]>;
5
+ static ɵmod: i0.ɵɵNgModuleDeclaration<FilterPipeModule, never, [typeof i1.FilterPipe], [typeof i1.FilterPipe]>;
6
6
  static ɵinj: i0.ɵɵInjectorDeclaration<FilterPipeModule>;
7
7
  }
@@ -1,27 +1,27 @@
1
1
  import { PipeTransform } from '@angular/core';
2
2
  import { FormatMaskOption } from '@yelon/util/format';
3
3
  import * as i0 from "@angular/core";
4
+ /**
5
+ * Format mask
6
+ *
7
+ * 格式化掩码
8
+ *
9
+ * | 字符 | 描述 |
10
+ * | --- | --- |
11
+ * | `0` | 任意数字,若该位置字符不符合,则默认为 `0` 填充 |
12
+ * | `9` | 任意数字 |
13
+ * | `#` | 任意字符 |
14
+ * | `U` | 转换大写 |
15
+ * | `L` | 转换小写 |
16
+ * | `*` | 转换为 `*` 字符 |
17
+ *
18
+ * ```ts
19
+ * formatMask('123', '(###)') => (123)
20
+ * formatMask('15900000000', '999****9999') => 159****0000
21
+ * ```
22
+ */
4
23
  export declare class FormatMaskPipe implements PipeTransform {
5
- /**
6
- * Format mask
7
- *
8
- * 格式化掩码
9
- *
10
- * | 字符 | 描述 |
11
- * | --- | --- |
12
- * | `0` | 任意数字,若该位置字符不符合,则默认为 `0` 填充 |
13
- * | `9` | 任意数字 |
14
- * | `#` | 任意字符 |
15
- * | `U` | 转换大写 |
16
- * | `L` | 转换小写 |
17
- * | `*` | 转换为 `*` 字符 |
18
- *
19
- * ```ts
20
- * formatMask('123', '(###)') => (123)
21
- * formatMask('15900000000', '999****9999') => 159****0000
22
- * ```
23
- */
24
24
  transform(value: string, mask: string | FormatMaskOption): string;
25
25
  static ɵfac: i0.ɵɵFactoryDeclaration<FormatMaskPipe, never>;
26
- static ɵpipe: i0.ɵɵPipeDeclaration<FormatMaskPipe, "mask", false>;
26
+ static ɵpipe: i0.ɵɵPipeDeclaration<FormatMaskPipe, "mask", true>;
27
27
  }
@@ -2,6 +2,6 @@ import * as i0 from "@angular/core";
2
2
  import * as i1 from "./mask.pipe";
3
3
  export declare class FormatPipeModule {
4
4
  static ɵfac: i0.ɵɵFactoryDeclaration<FormatPipeModule, never>;
5
- static ɵmod: i0.ɵɵNgModuleDeclaration<FormatPipeModule, [typeof i1.FormatMaskPipe], never, [typeof i1.FormatMaskPipe]>;
5
+ static ɵmod: i0.ɵɵNgModuleDeclaration<FormatPipeModule, never, [typeof i1.FormatMaskPipe], [typeof i1.FormatMaskPipe]>;
6
6
  static ɵinj: i0.ɵɵInjectorDeclaration<FormatPipeModule>;
7
7
  }
@@ -1,7 +0,0 @@
1
- import { Subject } from 'rxjs';
2
- import * as i0 from "@angular/core";
3
- export declare class GlobalEventSubjectService {
4
- clickEvents: Subject<Event>;
5
- static ɵfac: i0.ɵɵFactoryDeclaration<GlobalEventSubjectService, never>;
6
- static ɵprov: i0.ɵɵInjectableDeclaration<GlobalEventSubjectService>;
7
- }
@@ -1 +0,0 @@
1
- export * from './global-event.subject';
@@ -1,5 +0,0 @@
1
- /**
2
- * Generated bundle index. Do not edit.
3
- */
4
- export * from './index';
5
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYW5hbHlzaXMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy91dGlsL2FuYWx5c2lzL2FuYWx5c2lzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxTQUFTLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEdlbmVyYXRlZCBidW5kbGUgaW5kZXguIERvIG5vdCBlZGl0LlxuICovXG5cbmV4cG9ydCAqIGZyb20gJy4vaW5kZXgnO1xuIl19
@@ -1,17 +0,0 @@
1
- import { Injectable } from '@angular/core';
2
- import { Subject } from 'rxjs';
3
- import * as i0 from "@angular/core";
4
- export class GlobalEventSubjectService {
5
- constructor() {
6
- this.clickEvents = new Subject();
7
- }
8
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalEventSubjectService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
9
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalEventSubjectService, providedIn: 'root' }); }
10
- }
11
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalEventSubjectService, decorators: [{
12
- type: Injectable,
13
- args: [{
14
- providedIn: 'root'
15
- }]
16
- }] });
17
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2xvYmFsLWV2ZW50LnN1YmplY3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy91dGlsL2FuYWx5c2lzL2dsb2JhbC1ldmVudC5zdWJqZWN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxVQUFVLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDM0MsT0FBTyxFQUFFLE9BQU8sRUFBRSxNQUFNLE1BQU0sQ0FBQzs7QUFLL0IsTUFBTSxPQUFPLHlCQUF5QjtJQUh0QztRQUlTLGdCQUFXLEdBQUcsSUFBSSxPQUFPLEVBQVMsQ0FBQztLQUMzQzsrR0FGWSx5QkFBeUI7bUhBQXpCLHlCQUF5QixjQUZ4QixNQUFNOzs0RkFFUCx5QkFBeUI7a0JBSHJDLFVBQVU7bUJBQUM7b0JBQ1YsVUFBVSxFQUFFLE1BQU07aUJBQ25CIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgSW5qZWN0YWJsZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuaW1wb3J0IHsgU3ViamVjdCB9IGZyb20gJ3J4anMnO1xuXG5ASW5qZWN0YWJsZSh7XG4gIHByb3ZpZGVkSW46ICdyb290J1xufSlcbmV4cG9ydCBjbGFzcyBHbG9iYWxFdmVudFN1YmplY3RTZXJ2aWNlIHtcbiAgcHVibGljIGNsaWNrRXZlbnRzID0gbmV3IFN1YmplY3Q8RXZlbnQ+KCk7XG59XG4iXX0=
@@ -1,2 +0,0 @@
1
- export * from './global-event.subject';
2
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy91dGlsL2FuYWx5c2lzL2luZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGNBQWMsd0JBQXdCLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgKiBmcm9tICcuL2dsb2JhbC1ldmVudC5zdWJqZWN0JztcbiJdfQ==
@@ -1,24 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { Injectable } from '@angular/core';
3
- import { Subject } from 'rxjs';
4
-
5
- class GlobalEventSubjectService {
6
- constructor() {
7
- this.clickEvents = new Subject();
8
- }
9
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalEventSubjectService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
10
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalEventSubjectService, providedIn: 'root' }); }
11
- }
12
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalEventSubjectService, decorators: [{
13
- type: Injectable,
14
- args: [{
15
- providedIn: 'root'
16
- }]
17
- }] });
18
-
19
- /**
20
- * Generated bundle index. Do not edit.
21
- */
22
-
23
- export { GlobalEventSubjectService };
24
- //# sourceMappingURL=analysis.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"analysis.mjs","sources":["../../../../packages/util/analysis/global-event.subject.ts","../../../../packages/util/analysis/analysis.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { Subject } from 'rxjs';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class GlobalEventSubjectService {\n public clickEvents = new Subject<Event>();\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MAMa,yBAAyB,CAAA;AAHtC,IAAA,WAAA,GAAA;AAIS,QAAA,IAAA,CAAA,WAAW,GAAG,IAAI,OAAO,EAAS,CAAC;AAC3C,KAAA;+GAFY,yBAAyB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA,EAAA;AAAzB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,yBAAyB,cAFxB,MAAM,EAAA,CAAA,CAAA,EAAA;;4FAEP,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBAHrC,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA,CAAA;;;ACLD;;AAEG;;;;"}