@delon/abc 16.2.0 → 16.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (187) hide show
  1. package/avatar-list/avatar-list.component.d.ts +3 -4
  2. package/cell/cell-host.directive.d.ts +13 -0
  3. package/cell/cell.component.d.ts +45 -0
  4. package/cell/cell.module.d.ts +17 -0
  5. package/cell/cell.service.d.ts +23 -0
  6. package/cell/cell.types.d.ts +238 -0
  7. package/cell/index.d.ts +5 -0
  8. package/cell/style/index.less +63 -0
  9. package/error-collect/error-collect.component.d.ts +2 -3
  10. package/esm2022/auto-focus/auto-focus.directive.mjs +3 -3
  11. package/esm2022/auto-focus/auto-focus.module.mjs +4 -4
  12. package/esm2022/avatar-list/avatar-list-item.component.mjs +5 -5
  13. package/esm2022/avatar-list/avatar-list.component.mjs +9 -12
  14. package/esm2022/avatar-list/avatar-list.module.mjs +4 -4
  15. package/esm2022/cell/cell-host.directive.mjs +34 -0
  16. package/esm2022/cell/cell.component.mjs +270 -0
  17. package/esm2022/cell/cell.mjs +5 -0
  18. package/esm2022/cell/cell.module.mjs +54 -0
  19. package/esm2022/cell/cell.service.mjs +168 -0
  20. package/esm2022/cell/cell.types.mjs +2 -0
  21. package/esm2022/cell/index.mjs +6 -0
  22. package/esm2022/count-down/count-down.component.mjs +5 -5
  23. package/esm2022/count-down/count-down.module.mjs +4 -4
  24. package/esm2022/date-picker/date-picker.module.mjs +4 -4
  25. package/esm2022/date-picker/range-shortcut.component.mjs +3 -3
  26. package/esm2022/date-picker/range.directive.mjs +3 -3
  27. package/esm2022/down-file/down-file.directive.mjs +3 -3
  28. package/esm2022/down-file/down-file.module.mjs +4 -4
  29. package/esm2022/ellipsis/ellipsis.component.mjs +5 -5
  30. package/esm2022/ellipsis/ellipsis.module.mjs +4 -4
  31. package/esm2022/error-collect/error-collect.component.mjs +11 -13
  32. package/esm2022/error-collect/error-collect.module.mjs +4 -4
  33. package/esm2022/exception/exception.component.mjs +14 -14
  34. package/esm2022/exception/exception.module.mjs +4 -4
  35. package/esm2022/footer-toolbar/footer-toolbar.component.mjs +5 -5
  36. package/esm2022/footer-toolbar/footer-toolbar.module.mjs +4 -4
  37. package/esm2022/full-content/full-content-toggle.directive.mjs +3 -3
  38. package/esm2022/full-content/full-content.component.mjs +12 -14
  39. package/esm2022/full-content/full-content.module.mjs +4 -4
  40. package/esm2022/full-content/full-content.service.mjs +3 -3
  41. package/esm2022/global-footer/global-footer-item.component.mjs +5 -5
  42. package/esm2022/global-footer/global-footer.component.mjs +12 -14
  43. package/esm2022/global-footer/global-footer.module.mjs +4 -4
  44. package/esm2022/hotkey/hotkey.directive.mjs +3 -3
  45. package/esm2022/hotkey/hotkey.module.mjs +4 -4
  46. package/esm2022/let/let.directive.mjs +3 -3
  47. package/esm2022/let/let.module.mjs +4 -4
  48. package/esm2022/loading/loading.component.mjs +5 -5
  49. package/esm2022/loading/loading.module.mjs +4 -4
  50. package/esm2022/loading/loading.service.mjs +3 -3
  51. package/esm2022/lodop/lodop.module.mjs +4 -4
  52. package/esm2022/lodop/lodop.service.mjs +3 -3
  53. package/esm2022/media/media.component.mjs +11 -13
  54. package/esm2022/media/media.module.mjs +4 -4
  55. package/esm2022/media/media.service.mjs +3 -3
  56. package/esm2022/notice-icon/notice-icon-tab.component.mjs +5 -5
  57. package/esm2022/notice-icon/notice-icon.component.mjs +5 -5
  58. package/esm2022/notice-icon/notice-icon.module.mjs +4 -4
  59. package/esm2022/observers/observer-size.mjs +10 -10
  60. package/esm2022/onboarding/onboarding.component.mjs +3 -3
  61. package/esm2022/onboarding/onboarding.module.mjs +4 -4
  62. package/esm2022/onboarding/onboarding.service.mjs +3 -3
  63. package/esm2022/page-header/page-header.component.mjs +16 -16
  64. package/esm2022/page-header/page-header.module.mjs +27 -6
  65. package/esm2022/pdf/pdf.component.mjs +14 -16
  66. package/esm2022/pdf/pdf.module.mjs +4 -4
  67. package/esm2022/pdf/pdf.types.mjs +2 -1
  68. package/esm2022/qr/qr.component.mjs +3 -3
  69. package/esm2022/qr/qr.module.mjs +4 -4
  70. package/esm2022/quick-menu/quick-menu.component.mjs +5 -5
  71. package/esm2022/quick-menu/quick-menu.module.mjs +4 -4
  72. package/esm2022/result/result.component.mjs +12 -14
  73. package/esm2022/result/result.module.mjs +4 -4
  74. package/esm2022/reuse-tab/public_api.mjs +2 -1
  75. package/esm2022/reuse-tab/reuse-tab-context-menu.component.mjs +3 -3
  76. package/esm2022/reuse-tab/reuse-tab-context.component.mjs +3 -3
  77. package/esm2022/reuse-tab/reuse-tab-context.directive.mjs +3 -3
  78. package/esm2022/reuse-tab/reuse-tab-context.service.mjs +3 -3
  79. package/esm2022/reuse-tab/reuse-tab.component.mjs +12 -16
  80. package/esm2022/reuse-tab/reuse-tab.module.mjs +4 -4
  81. package/esm2022/reuse-tab/reuse-tab.service.mjs +3 -3
  82. package/esm2022/se/se-container.component.mjs +10 -10
  83. package/esm2022/se/se.component.mjs +13 -15
  84. package/esm2022/se/se.module.mjs +4 -4
  85. package/esm2022/sg/sg-container.component.mjs +5 -5
  86. package/esm2022/sg/sg.component.mjs +5 -5
  87. package/esm2022/sg/sg.module.mjs +4 -4
  88. package/esm2022/st/st-column-source.mjs +8 -4
  89. package/esm2022/st/st-data-source.mjs +14 -7
  90. package/esm2022/st/st-export.mjs +3 -3
  91. package/esm2022/st/st-filter.component.mjs +12 -12
  92. package/esm2022/st/st-row.directive.mjs +6 -6
  93. package/esm2022/st/st-widget-host.directive.mjs +3 -3
  94. package/esm2022/st/st-widget.mjs +3 -3
  95. package/esm2022/st/st.component.mjs +83 -97
  96. package/esm2022/st/st.interfaces.mjs +1 -1
  97. package/esm2022/st/st.module.mjs +9 -5
  98. package/esm2022/st/st.types.mjs +1 -1
  99. package/esm2022/sv/sv-container.component.mjs +22 -12
  100. package/esm2022/sv/sv-value.component.mjs +6 -6
  101. package/esm2022/sv/sv.component.mjs +12 -9
  102. package/esm2022/sv/sv.module.mjs +4 -4
  103. package/esm2022/tag-select/tag-select.component.mjs +10 -14
  104. package/esm2022/tag-select/tag-select.module.mjs +4 -4
  105. package/esm2022/xlsx/xlsx.directive.mjs +3 -3
  106. package/esm2022/xlsx/xlsx.module.mjs +4 -4
  107. package/esm2022/xlsx/xlsx.service.mjs +3 -3
  108. package/esm2022/zip/zip.module.mjs +4 -4
  109. package/esm2022/zip/zip.service.mjs +3 -3
  110. package/exception/exception.component.d.ts +2 -3
  111. package/fesm2022/auto-focus.mjs +7 -7
  112. package/fesm2022/avatar-list.mjs +16 -19
  113. package/fesm2022/avatar-list.mjs.map +1 -1
  114. package/fesm2022/cell.mjs +521 -0
  115. package/fesm2022/cell.mjs.map +1 -0
  116. package/fesm2022/chart-observer-size.mjs +10 -10
  117. package/fesm2022/count-down.mjs +8 -8
  118. package/fesm2022/count-down.mjs.map +1 -1
  119. package/fesm2022/date-picker.mjs +10 -10
  120. package/fesm2022/down-file.mjs +7 -7
  121. package/fesm2022/ellipsis.mjs +8 -8
  122. package/fesm2022/ellipsis.mjs.map +1 -1
  123. package/fesm2022/error-collect.mjs +14 -16
  124. package/fesm2022/error-collect.mjs.map +1 -1
  125. package/fesm2022/exception.mjs +17 -17
  126. package/fesm2022/exception.mjs.map +1 -1
  127. package/fesm2022/footer-toolbar.mjs +8 -8
  128. package/fesm2022/footer-toolbar.mjs.map +1 -1
  129. package/fesm2022/full-content.mjs +21 -23
  130. package/fesm2022/full-content.mjs.map +1 -1
  131. package/fesm2022/global-footer.mjs +19 -21
  132. package/fesm2022/global-footer.mjs.map +1 -1
  133. package/fesm2022/hotkey.mjs +7 -7
  134. package/fesm2022/let.mjs +7 -7
  135. package/fesm2022/loading.mjs +11 -11
  136. package/fesm2022/loading.mjs.map +1 -1
  137. package/fesm2022/lodop.mjs +7 -7
  138. package/fesm2022/media.mjs +17 -19
  139. package/fesm2022/media.mjs.map +1 -1
  140. package/fesm2022/notice-icon.mjs +12 -12
  141. package/fesm2022/notice-icon.mjs.map +1 -1
  142. package/fesm2022/onboarding.mjs +10 -10
  143. package/fesm2022/page-header.mjs +41 -20
  144. package/fesm2022/page-header.mjs.map +1 -1
  145. package/fesm2022/pdf.mjs +18 -19
  146. package/fesm2022/pdf.mjs.map +1 -1
  147. package/fesm2022/qr.mjs +7 -7
  148. package/fesm2022/quick-menu.mjs +8 -8
  149. package/fesm2022/quick-menu.mjs.map +1 -1
  150. package/fesm2022/result.mjs +15 -17
  151. package/fesm2022/result.mjs.map +1 -1
  152. package/fesm2022/reuse-tab.mjs +31 -35
  153. package/fesm2022/reuse-tab.mjs.map +1 -1
  154. package/fesm2022/se.mjs +25 -27
  155. package/fesm2022/se.mjs.map +1 -1
  156. package/fesm2022/sg.mjs +12 -12
  157. package/fesm2022/sg.mjs.map +1 -1
  158. package/fesm2022/st.mjs +134 -133
  159. package/fesm2022/st.mjs.map +1 -1
  160. package/fesm2022/sv.mjs +41 -28
  161. package/fesm2022/sv.mjs.map +1 -1
  162. package/fesm2022/tag-select.mjs +13 -17
  163. package/fesm2022/tag-select.mjs.map +1 -1
  164. package/fesm2022/xlsx.mjs +10 -10
  165. package/fesm2022/zip.mjs +7 -7
  166. package/global-footer/global-footer.component.d.ts +6 -6
  167. package/index.less +1 -0
  168. package/package.json +10 -5
  169. package/page-header/page-header.component.d.ts +5 -5
  170. package/page-header/page-header.module.d.ts +2 -1
  171. package/page-header/style/index.less +1 -0
  172. package/pdf/pdf.component.d.ts +6 -5
  173. package/pdf/pdf.types.d.ts +2 -1
  174. package/result/result.component.d.ts +6 -6
  175. package/reuse-tab/public_api.d.ts +1 -0
  176. package/reuse-tab/reuse-tab.component.d.ts +2 -3
  177. package/se/se.component.d.ts +2 -3
  178. package/st/st-data-source.d.ts +1 -1
  179. package/st/st.component.d.ts +7 -7
  180. package/st/st.interfaces.d.ts +22 -2
  181. package/st/st.module.d.ts +17 -16
  182. package/st/st.types.d.ts +3 -0
  183. package/sv/style/index.less +36 -0
  184. package/sv/sv-container.component.d.ts +7 -2
  185. package/sv/sv.component.d.ts +3 -3
  186. package/tag-select/tag-select.component.d.ts +2 -3
  187. package/theme-default.less +11 -0
@@ -22,15 +22,15 @@ class CountDownComponent {
22
22
  handleEvent(e) {
23
23
  this.event.emit(e);
24
24
  }
25
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: CountDownComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
26
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.6", type: CountDownComponent, selector: "count-down", inputs: { config: "config", target: "target" }, outputs: { event: "event" }, viewQueries: [{ propertyName: "instance", first: true, predicate: ["cd"], descendants: true }], exportAs: ["countDown"], ngImport: i0, template: ` <countdown #cd *ngIf="config" [config]="config" (event)="handleEvent($event)"></countdown> `, isInline: true, dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2.CountdownComponent, selector: "countdown", inputs: ["config", "render"], outputs: ["event"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
25
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: CountDownComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
26
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.3", type: CountDownComponent, selector: "count-down", inputs: { config: "config", target: "target" }, outputs: { event: "event" }, viewQueries: [{ propertyName: "instance", first: true, predicate: ["cd"], descendants: true }], exportAs: ["countDown"], ngImport: i0, template: `<countdown #cd *ngIf="config" [config]="config" (event)="handleEvent($event)" />`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2.CountdownComponent, selector: "countdown", inputs: ["config", "render"], outputs: ["event"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
27
27
  }
28
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: CountDownComponent, decorators: [{
28
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: CountDownComponent, decorators: [{
29
29
  type: Component,
30
30
  args: [{
31
31
  selector: 'count-down',
32
32
  exportAs: 'countDown',
33
- template: ` <countdown #cd *ngIf="config" [config]="config" (event)="handleEvent($event)"></countdown> `,
33
+ template: `<countdown #cd *ngIf="config" [config]="config" (event)="handleEvent($event)" />`,
34
34
  preserveWhitespaces: false,
35
35
  changeDetection: ChangeDetectionStrategy.OnPush,
36
36
  encapsulation: ViewEncapsulation.None
@@ -48,11 +48,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImpor
48
48
 
49
49
  const COMPONENTS = [CountDownComponent];
50
50
  class CountDownModule {
51
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: CountDownModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
52
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.6", ngImport: i0, type: CountDownModule, declarations: [CountDownComponent], imports: [CommonModule, CountdownModule], exports: [CountDownComponent] }); }
53
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: CountDownModule, imports: [CommonModule, CountdownModule] }); }
51
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: CountDownModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
52
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.3", ngImport: i0, type: CountDownModule, declarations: [CountDownComponent], imports: [CommonModule, CountdownModule], exports: [CountDownComponent] }); }
53
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: CountDownModule, imports: [CommonModule, CountdownModule] }); }
54
54
  }
55
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: CountDownModule, decorators: [{
55
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: CountDownModule, decorators: [{
56
56
  type: NgModule,
57
57
  args: [{
58
58
  imports: [CommonModule, CountdownModule],
@@ -1 +1 @@
1
- {"version":3,"file":"count-down.mjs","sources":["../../../../packages/abc/count-down/count-down.component.ts","../../../../packages/abc/count-down/count-down.module.ts","../../../../packages/abc/count-down/count-down.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Input,\n Output,\n ViewChild,\n ViewEncapsulation\n} from '@angular/core';\n\nimport { addSeconds, format } from 'date-fns';\nimport { CountdownComponent, CountdownConfig, CountdownEvent } from 'ngx-countdown';\n\n@Component({\n selector: 'count-down',\n exportAs: 'countDown',\n template: ` <countdown #cd *ngIf=\"config\" [config]=\"config\" (event)=\"handleEvent($event)\"></countdown> `,\n preserveWhitespaces: false,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class CountDownComponent {\n @ViewChild('cd', { static: false }) readonly instance!: CountdownComponent;\n\n @Input() config?: CountdownConfig;\n\n /**\n * 目标时间\n */\n @Input()\n set target(value: number | Date) {\n this.config = {\n format: `HH:mm:ss`,\n stopTime: typeof value === 'number' ? addSeconds(new Date(), value).valueOf() : +format(value, 't')\n };\n }\n\n @Output() readonly event = new EventEmitter<CountdownEvent>();\n\n handleEvent(e: CountdownEvent): void {\n this.event.emit(e);\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { CountdownModule } from 'ngx-countdown';\n\nimport { CountDownComponent } from './count-down.component';\n\nconst COMPONENTS = [CountDownComponent];\n\n@NgModule({\n imports: [CommonModule, CountdownModule],\n declarations: COMPONENTS,\n exports: COMPONENTS\n})\nexport class CountDownModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;MAqBa,kBAAkB,CAAA;AAR/B,IAAA,WAAA,GAAA;AAwBqB,QAAA,IAAA,CAAA,KAAK,GAAG,IAAI,YAAY,EAAkB,CAAC;AAK/D,KAAA;AAhBC;;AAEG;IACH,IACI,MAAM,CAAC,KAAoB,EAAA;QAC7B,IAAI,CAAC,MAAM,GAAG;AACZ,YAAA,MAAM,EAAE,CAAU,QAAA,CAAA;AAClB,YAAA,QAAQ,EAAE,OAAO,KAAK,KAAK,QAAQ,GAAG,UAAU,CAAC,IAAI,IAAI,EAAE,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE,GAAG,CAAC,MAAM,CAAC,KAAK,EAAE,GAAG,CAAC;SACpG,CAAC;KACH;AAID,IAAA,WAAW,CAAC,CAAiB,EAAA;AAC3B,QAAA,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACpB;8GApBU,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,kBAAkB,wPALnB,CAA8F,4FAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,EAAA,CAAA,IAAA,EAAA,QAAA,EAAA,QAAA,EAAA,MAAA,EAAA,CAAA,MAAA,EAAA,UAAA,EAAA,UAAA,CAAA,EAAA,EAAA,EAAA,I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A,EAAA,OAAA,EAAA,CAG1B,YAAY,EAAE,eAAe,aAHrB,kBAAkB,CAAA,EAAA,CAAA,CAAA,EAAA;+GAOzB,eAAe,EAAA,OAAA,EAAA,CAJhB,YAAY,EAAE,eAAe,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAI5B,eAAe,EAAA,UAAA,EAAA,CAAA;kBAL3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC;AACxC,oBAAA,YAAY,EAAE,UAAU;AACxB,oBAAA,OAAO,EAAE,UAAU;AACpB,iBAAA,CAAA;;;ACbD;;AAEG;;;;"}
1
+ {"version":3,"file":"count-down.mjs","sources":["../../../../packages/abc/count-down/count-down.component.ts","../../../../packages/abc/count-down/count-down.module.ts","../../../../packages/abc/count-down/count-down.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Input,\n Output,\n ViewChild,\n ViewEncapsulation\n} from '@angular/core';\n\nimport { addSeconds, format } from 'date-fns';\nimport { CountdownComponent, CountdownConfig, CountdownEvent } from 'ngx-countdown';\n\n@Component({\n selector: 'count-down',\n exportAs: 'countDown',\n template: `<countdown #cd *ngIf=\"config\" [config]=\"config\" (event)=\"handleEvent($event)\" />`,\n preserveWhitespaces: false,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class CountDownComponent {\n @ViewChild('cd', { static: false }) readonly instance!: CountdownComponent;\n\n @Input() config?: CountdownConfig;\n\n /**\n * 目标时间\n */\n @Input()\n set target(value: number | Date) {\n this.config = {\n format: `HH:mm:ss`,\n stopTime: typeof value === 'number' ? addSeconds(new Date(), value).valueOf() : +format(value, 't')\n };\n }\n\n @Output() readonly event = new EventEmitter<CountdownEvent>();\n\n handleEvent(e: CountdownEvent): void {\n this.event.emit(e);\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { CountdownModule } from 'ngx-countdown';\n\nimport { CountDownComponent } from './count-down.component';\n\nconst COMPONENTS = [CountDownComponent];\n\n@NgModule({\n imports: [CommonModule, CountdownModule],\n declarations: COMPONENTS,\n exports: COMPONENTS\n})\nexport class CountDownModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;MAqBa,kBAAkB,CAAA;AAR/B,IAAA,WAAA,GAAA;AAwBqB,QAAA,IAAA,CAAA,KAAK,GAAG,IAAI,YAAY,EAAkB,CAAC;AAK/D,KAAA;AAhBC;;AAEG;IACH,IACI,MAAM,CAAC,KAAoB,EAAA;QAC7B,IAAI,CAAC,MAAM,GAAG;AACZ,YAAA,MAAM,EAAE,CAAU,QAAA,CAAA;AAClB,YAAA,QAAQ,EAAE,OAAO,KAAK,KAAK,QAAQ,GAAG,UAAU,CAAC,IAAI,IAAI,EAAE,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE,GAAG,CAAC,MAAM,CAAC,KAAK,EAAE,GAAG,CAAC;SACpG,CAAC;KACH;AAID,IAAA,WAAW,CAAC,CAAiB,EAAA;AAC3B,QAAA,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACpB;8GApBU,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,kBAAkB,wPALnB,CAAkF,gFAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,EAAA,CAAA,IAAA,EAAA,QAAA,EAAA,QAAA,EAAA,MAAA,EAAA,CAAA,MAAA,EAAA,UAAA,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,IAAA,EAAA,eAAe,iBAPR,kBAAkB,CAAA,EAAA,OAAA,EAAA,CAG1B,YAAY,EAAE,eAAe,aAHrB,kBAAkB,CAAA,EAAA,CAAA,CAAA,EAAA;+GAOzB,eAAe,EAAA,OAAA,EAAA,CAJhB,YAAY,EAAE,eAAe,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAI5B,eAAe,EAAA,UAAA,EAAA,CAAA;kBAL3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC;AACxC,oBAAA,YAAY,EAAE,UAAU;AACxB,oBAAA,OAAO,EAAE,UAAU;AACpB,iBAAA,CAAA;;;ACbD;;AAEG;;;;"}
@@ -15,8 +15,8 @@ class RangePickerShortcutTplComponent {
15
15
  this.list = [];
16
16
  }
17
17
  click(_) { }
18
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: RangePickerShortcutTplComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
19
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.6", type: RangePickerShortcutTplComponent, selector: "ng-component", viewQueries: [{ propertyName: "tpl", first: true, predicate: ["tpl"], descendants: true, static: true }], ngImport: i0, template: `
18
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: RangePickerShortcutTplComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
19
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.3", type: RangePickerShortcutTplComponent, selector: "ng-component", viewQueries: [{ propertyName: "tpl", first: true, predicate: ["tpl"], descendants: true, static: true }], ngImport: i0, template: `
20
20
  <ng-template #tpl>
21
21
  <a
22
22
  *ngFor="let i of list; let first = first"
@@ -27,7 +27,7 @@ class RangePickerShortcutTplComponent {
27
27
  </ng-template>
28
28
  `, isInline: true, dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] }); }
29
29
  }
30
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: RangePickerShortcutTplComponent, decorators: [{
30
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: RangePickerShortcutTplComponent, decorators: [{
31
31
  type: Component,
32
32
  args: [{
33
33
  selector: '',
@@ -186,10 +186,10 @@ class RangePickerDirective {
186
186
  ngOnDestroy() {
187
187
  this.destoryShortcut();
188
188
  }
189
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: RangePickerDirective, deps: [{ token: i1$1.DomSanitizer }, { token: i2.AlainConfigService }, { token: i3.NzRangePickerComponent, host: true, optional: true }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive }); }
190
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.6", type: RangePickerDirective, selector: "nz-range-picker[extend]", inputs: { shortcut: "shortcut", ngModelEnd: "ngModelEnd" }, outputs: { ngModelEndChange: "ngModelEndChange" }, exportAs: ["extendRangePicker"], ngImport: i0 }); }
189
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: RangePickerDirective, deps: [{ token: i1$1.DomSanitizer }, { token: i2.AlainConfigService }, { token: i3.NzRangePickerComponent, host: true, optional: true }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive }); }
190
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.3", type: RangePickerDirective, selector: "nz-range-picker[extend]", inputs: { shortcut: "shortcut", ngModelEnd: "ngModelEnd" }, outputs: { ngModelEndChange: "ngModelEndChange" }, exportAs: ["extendRangePicker"], ngImport: i0 }); }
191
191
  }
192
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: RangePickerDirective, decorators: [{
192
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: RangePickerDirective, decorators: [{
193
193
  type: Directive,
194
194
  args: [{
195
195
  selector: 'nz-range-picker[extend]',
@@ -210,11 +210,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImpor
210
210
 
211
211
  const COMPONENTS = [RangePickerDirective, RangePickerShortcutTplComponent];
212
212
  class DatePickerModule {
213
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DatePickerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
214
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.6", ngImport: i0, type: DatePickerModule, declarations: [RangePickerDirective, RangePickerShortcutTplComponent], imports: [CommonModule, FormsModule, NzDatePickerModule], exports: [RangePickerDirective, RangePickerShortcutTplComponent] }); }
215
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DatePickerModule, imports: [CommonModule, FormsModule, NzDatePickerModule] }); }
213
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: DatePickerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
214
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.3", ngImport: i0, type: DatePickerModule, declarations: [RangePickerDirective, RangePickerShortcutTplComponent], imports: [CommonModule, FormsModule, NzDatePickerModule], exports: [RangePickerDirective, RangePickerShortcutTplComponent] }); }
215
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: DatePickerModule, imports: [CommonModule, FormsModule, NzDatePickerModule] }); }
216
216
  }
217
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DatePickerModule, decorators: [{
217
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: DatePickerModule, decorators: [{
218
218
  type: NgModule,
219
219
  args: [{
220
220
  imports: [CommonModule, FormsModule, NzDatePickerModule],
@@ -80,10 +80,10 @@ class DownFileDirective {
80
80
  error: err => this.error.emit(err)
81
81
  });
82
82
  }
83
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DownFileDirective, deps: [{ token: i0.ElementRef }, { token: i1._HttpClient }], target: i0.ɵɵFactoryTarget.Directive }); }
84
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.6", type: DownFileDirective, selector: "[down-file]", inputs: { httpData: ["http-data", "httpData"], httpBody: ["http-body", "httpBody"], httpMethod: ["http-method", "httpMethod"], httpUrl: ["http-url", "httpUrl"], fileName: ["file-name", "fileName"], pre: "pre" }, outputs: { success: "success", error: "error" }, host: { listeners: { "click": "_click($event)" } }, exportAs: ["downFile"], ngImport: i0 }); }
83
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: DownFileDirective, deps: [{ token: i0.ElementRef }, { token: i1._HttpClient }], target: i0.ɵɵFactoryTarget.Directive }); }
84
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.3", type: DownFileDirective, selector: "[down-file]", inputs: { httpData: ["http-data", "httpData"], httpBody: ["http-body", "httpBody"], httpMethod: ["http-method", "httpMethod"], httpUrl: ["http-url", "httpUrl"], fileName: ["file-name", "fileName"], pre: "pre" }, outputs: { success: "success", error: "error" }, host: { listeners: { "click": "_click($event)" } }, exportAs: ["downFile"], ngImport: i0 }); }
85
85
  }
86
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DownFileDirective, decorators: [{
86
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: DownFileDirective, decorators: [{
87
87
  type: Directive,
88
88
  args: [{
89
89
  selector: '[down-file]',
@@ -117,11 +117,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImpor
117
117
 
118
118
  const DIRECTIVES = [DownFileDirective];
119
119
  class DownFileModule {
120
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DownFileModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
121
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.6", ngImport: i0, type: DownFileModule, declarations: [DownFileDirective], imports: [CommonModule, AlainThemeModule], exports: [DownFileDirective] }); }
122
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DownFileModule, imports: [CommonModule, AlainThemeModule] }); }
120
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: DownFileModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
121
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.3", ngImport: i0, type: DownFileModule, declarations: [DownFileDirective], imports: [CommonModule, AlainThemeModule], exports: [DownFileDirective] }); }
122
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: DownFileModule, imports: [CommonModule, AlainThemeModule] }); }
123
123
  }
124
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DownFileModule, decorators: [{
124
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: DownFileModule, decorators: [{
125
125
  type: NgModule,
126
126
  args: [{
127
127
  imports: [CommonModule, AlainThemeModule],
@@ -191,8 +191,8 @@ class EllipsisComponent {
191
191
  this.refresh();
192
192
  }
193
193
  }
194
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: EllipsisComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: i1.DomSanitizer }, { token: DOCUMENT }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
195
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.6", type: EllipsisComponent, selector: "ellipsis", inputs: { tooltip: "tooltip", length: "length", lines: "lines", fullWidthRecognition: "fullWidthRecognition", tail: "tail" }, viewQueries: [{ propertyName: "orgEl", first: true, predicate: ["orgEl"], descendants: true }, { propertyName: "shadowOrgEl", first: true, predicate: ["shadowOrgEl"], descendants: true }, { propertyName: "shadowTextEl", first: true, predicate: ["shadowTextEl"], descendants: true }], exportAs: ["ellipsis"], usesOnChanges: true, ngImport: i0, template: "<div (cdkObserveContent)=\"refresh()\" #orgEl style=\"display: none\"><ng-content></ng-content></div>\n<ng-template #tooltipTpl let-con>\n <span\n *ngIf=\"tooltip; else con\"\n nz-tooltip\n [nzTooltipTitle]=\"titleTpl\"\n [nzTooltipOverlayStyle]=\"{ 'overflow-wrap': 'break-word', 'word-wrap': 'break-word' }\"\n >\n <ng-container *ngTemplateOutlet=\"con\"></ng-container>\n <ng-template #titleTpl><div [innerHTML]=\"orgHtml\"></div></ng-template>\n </span>\n</ng-template>\n<ng-container [ngSwitch]=\"type\">\n <span *ngSwitchCase=\"'default'\" [ngClass]=\"cls\"></span>\n <ng-container *ngSwitchCase=\"'length'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lengthTpl }\"></ng-template>\n <ng-template #lengthTpl>{{ text }}</ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"'line-clamp'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineClampTpl }\"></ng-template>\n <ng-template #lineClampTpl>\n <div [ngClass]=\"cls\" [ngStyle]=\"{ '-webkit-line-clamp': lines, '-webkit-box-orient': 'vertical' }\"></div>\n </ng-template>\n </ng-container>\n <div *ngSwitchCase=\"'line'\" [ngClass]=\"cls\">\n <div class=\"ellipsis__handle\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineTpl }\"></ng-template>\n <ng-template #lineTpl>{{ linsWord }}</ng-template>\n <div class=\"ellipsis__shadow\" #shadowOrgEl [innerHTML]=\"orgHtml\"></div>\n <div class=\"ellipsis__shadow\" #shadowTextEl>\n <span>{{ text }}</span>\n </div>\n </div>\n </div>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i3.CdkObserveContent, selector: "[cdkObserveContent]", inputs: ["cdkObserveContentDisabled", "debounce"], outputs: ["cdkObserveContent"], exportAs: ["cdkObserveContent"] }, { kind: "directive", type: i4.NzTooltipDirective, selector: "[nz-tooltip]", inputs: ["nzTooltipTitle", "nzTooltipTitleContext", "nz-tooltip", "nzTooltipTrigger", "nzTooltipPlacement", "nzTooltipOrigin", "nzTooltipVisible", "nzTooltipMouseEnterDelay", "nzTooltipMouseLeaveDelay", "nzTooltipOverlayClassName", "nzTooltipOverlayStyle", "nzTooltipArrowPointAtCenter", "nzTooltipColor"], outputs: ["nzTooltipVisibleChange"], exportAs: ["nzTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
194
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: EllipsisComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: i1.DomSanitizer }, { token: DOCUMENT }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
195
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.3", type: EllipsisComponent, selector: "ellipsis", inputs: { tooltip: "tooltip", length: "length", lines: "lines", fullWidthRecognition: "fullWidthRecognition", tail: "tail" }, viewQueries: [{ propertyName: "orgEl", first: true, predicate: ["orgEl"], descendants: true }, { propertyName: "shadowOrgEl", first: true, predicate: ["shadowOrgEl"], descendants: true }, { propertyName: "shadowTextEl", first: true, predicate: ["shadowTextEl"], descendants: true }], exportAs: ["ellipsis"], usesOnChanges: true, ngImport: i0, template: "<div (cdkObserveContent)=\"refresh()\" #orgEl style=\"display: none\"><ng-content /></div>\n<ng-template #tooltipTpl let-con>\n <span\n *ngIf=\"tooltip; else con\"\n nz-tooltip\n [nzTooltipTitle]=\"titleTpl\"\n [nzTooltipOverlayStyle]=\"{ 'overflow-wrap': 'break-word', 'word-wrap': 'break-word' }\"\n >\n <ng-container *ngTemplateOutlet=\"con\" />\n <ng-template #titleTpl><div [innerHTML]=\"orgHtml\"></div></ng-template>\n </span>\n</ng-template>\n<ng-container [ngSwitch]=\"type\">\n <span *ngSwitchCase=\"'default'\" [ngClass]=\"cls\"></span>\n <ng-container *ngSwitchCase=\"'length'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lengthTpl }\"></ng-template>\n <ng-template #lengthTpl>{{ text }}</ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"'line-clamp'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineClampTpl }\"></ng-template>\n <ng-template #lineClampTpl>\n <div [ngClass]=\"cls\" [ngStyle]=\"{ '-webkit-line-clamp': lines, '-webkit-box-orient': 'vertical' }\"></div>\n </ng-template>\n </ng-container>\n <div *ngSwitchCase=\"'line'\" [ngClass]=\"cls\">\n <div class=\"ellipsis__handle\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineTpl }\"></ng-template>\n <ng-template #lineTpl>{{ linsWord }}</ng-template>\n <div class=\"ellipsis__shadow\" #shadowOrgEl [innerHTML]=\"orgHtml\"></div>\n <div class=\"ellipsis__shadow\" #shadowTextEl>\n <span>{{ text }}</span>\n </div>\n </div>\n </div>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i3.CdkObserveContent, selector: "[cdkObserveContent]", inputs: ["cdkObserveContentDisabled", "debounce"], outputs: ["cdkObserveContent"], exportAs: ["cdkObserveContent"] }, { kind: "directive", type: i4.NzTooltipDirective, selector: "[nz-tooltip]", inputs: ["nzTooltipTitle", "nzTooltipTitleContext", "nz-tooltip", "nzTooltipTrigger", "nzTooltipPlacement", "nzTooltipOrigin", "nzTooltipVisible", "nzTooltipMouseEnterDelay", "nzTooltipMouseLeaveDelay", "nzTooltipOverlayClassName", "nzTooltipOverlayStyle", "nzTooltipArrowPointAtCenter", "nzTooltipColor"], outputs: ["nzTooltipVisibleChange"], exportAs: ["nzTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
196
196
  }
197
197
  __decorate([
198
198
  InputBoolean()
@@ -206,9 +206,9 @@ __decorate([
206
206
  __decorate([
207
207
  InputBoolean()
208
208
  ], EllipsisComponent.prototype, "fullWidthRecognition", void 0);
209
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: EllipsisComponent, decorators: [{
209
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: EllipsisComponent, decorators: [{
210
210
  type: Component,
211
- args: [{ selector: 'ellipsis', exportAs: 'ellipsis', preserveWhitespaces: false, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div (cdkObserveContent)=\"refresh()\" #orgEl style=\"display: none\"><ng-content></ng-content></div>\n<ng-template #tooltipTpl let-con>\n <span\n *ngIf=\"tooltip; else con\"\n nz-tooltip\n [nzTooltipTitle]=\"titleTpl\"\n [nzTooltipOverlayStyle]=\"{ 'overflow-wrap': 'break-word', 'word-wrap': 'break-word' }\"\n >\n <ng-container *ngTemplateOutlet=\"con\"></ng-container>\n <ng-template #titleTpl><div [innerHTML]=\"orgHtml\"></div></ng-template>\n </span>\n</ng-template>\n<ng-container [ngSwitch]=\"type\">\n <span *ngSwitchCase=\"'default'\" [ngClass]=\"cls\"></span>\n <ng-container *ngSwitchCase=\"'length'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lengthTpl }\"></ng-template>\n <ng-template #lengthTpl>{{ text }}</ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"'line-clamp'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineClampTpl }\"></ng-template>\n <ng-template #lineClampTpl>\n <div [ngClass]=\"cls\" [ngStyle]=\"{ '-webkit-line-clamp': lines, '-webkit-box-orient': 'vertical' }\"></div>\n </ng-template>\n </ng-container>\n <div *ngSwitchCase=\"'line'\" [ngClass]=\"cls\">\n <div class=\"ellipsis__handle\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineTpl }\"></ng-template>\n <ng-template #lineTpl>{{ linsWord }}</ng-template>\n <div class=\"ellipsis__shadow\" #shadowOrgEl [innerHTML]=\"orgHtml\"></div>\n <div class=\"ellipsis__shadow\" #shadowTextEl>\n <span>{{ text }}</span>\n </div>\n </div>\n </div>\n</ng-container>\n" }]
211
+ args: [{ selector: 'ellipsis', exportAs: 'ellipsis', preserveWhitespaces: false, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div (cdkObserveContent)=\"refresh()\" #orgEl style=\"display: none\"><ng-content /></div>\n<ng-template #tooltipTpl let-con>\n <span\n *ngIf=\"tooltip; else con\"\n nz-tooltip\n [nzTooltipTitle]=\"titleTpl\"\n [nzTooltipOverlayStyle]=\"{ 'overflow-wrap': 'break-word', 'word-wrap': 'break-word' }\"\n >\n <ng-container *ngTemplateOutlet=\"con\" />\n <ng-template #titleTpl><div [innerHTML]=\"orgHtml\"></div></ng-template>\n </span>\n</ng-template>\n<ng-container [ngSwitch]=\"type\">\n <span *ngSwitchCase=\"'default'\" [ngClass]=\"cls\"></span>\n <ng-container *ngSwitchCase=\"'length'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lengthTpl }\"></ng-template>\n <ng-template #lengthTpl>{{ text }}</ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"'line-clamp'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineClampTpl }\"></ng-template>\n <ng-template #lineClampTpl>\n <div [ngClass]=\"cls\" [ngStyle]=\"{ '-webkit-line-clamp': lines, '-webkit-box-orient': 'vertical' }\"></div>\n </ng-template>\n </ng-container>\n <div *ngSwitchCase=\"'line'\" [ngClass]=\"cls\">\n <div class=\"ellipsis__handle\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineTpl }\"></ng-template>\n <ng-template #lineTpl>{{ linsWord }}</ng-template>\n <div class=\"ellipsis__shadow\" #shadowOrgEl [innerHTML]=\"orgHtml\"></div>\n <div class=\"ellipsis__shadow\" #shadowTextEl>\n <span>{{ text }}</span>\n </div>\n </div>\n </div>\n</ng-container>\n" }]
212
212
  }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }, { type: i1.DomSanitizer }, { type: undefined, decorators: [{
213
213
  type: Inject,
214
214
  args: [DOCUMENT]
@@ -235,11 +235,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImpor
235
235
 
236
236
  const COMPONENTS = [EllipsisComponent];
237
237
  class EllipsisModule {
238
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: EllipsisModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
239
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.6", ngImport: i0, type: EllipsisModule, declarations: [EllipsisComponent], imports: [CommonModule, ObserversModule, NzToolTipModule], exports: [EllipsisComponent] }); }
240
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: EllipsisModule, imports: [CommonModule, ObserversModule, NzToolTipModule] }); }
238
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: EllipsisModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
239
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.3", ngImport: i0, type: EllipsisModule, declarations: [EllipsisComponent], imports: [CommonModule, ObserversModule, NzToolTipModule], exports: [EllipsisComponent] }); }
240
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: EllipsisModule, imports: [CommonModule, ObserversModule, NzToolTipModule] }); }
241
241
  }
242
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: EllipsisModule, decorators: [{
242
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: EllipsisModule, decorators: [{
243
243
  type: NgModule,
244
244
  args: [{
245
245
  imports: [CommonModule, ObserversModule, NzToolTipModule],
@@ -1 +1 @@
1
- {"version":3,"file":"ellipsis.mjs","sources":["../../../../packages/abc/ellipsis/ellipsis.component.ts","../../../../packages/abc/ellipsis/ellipsis.component.html","../../../../packages/abc/ellipsis/ellipsis.module.ts","../../../../packages/abc/ellipsis/ellipsis.ts"],"sourcesContent":["import { DOCUMENT } from '@angular/common';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n Inject,\n Input,\n NgZone,\n OnChanges,\n ViewChild,\n ViewEncapsulation\n} from '@angular/core';\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\nimport { take } from 'rxjs';\n\nimport { BooleanInput, InputBoolean, InputNumber, NumberInput } from '@delon/util/decorator';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n@Component({\n selector: 'ellipsis',\n exportAs: 'ellipsis',\n templateUrl: './ellipsis.component.html',\n preserveWhitespaces: false,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class EllipsisComponent implements AfterViewInit, OnChanges {\n static ngAcceptInputType_tooltip: BooleanInput;\n static ngAcceptInputType_length: NumberInput;\n static ngAcceptInputType_lines: NumberInput;\n static ngAcceptInputType_fullWidthRecognition: BooleanInput;\n\n private isSupportLineClamp = this.doc.body.style['webkitLineClamp'] !== undefined;\n @ViewChild('orgEl', { static: false }) private orgEl!: ElementRef;\n @ViewChild('shadowOrgEl', { static: false }) private shadowOrgEl!: ElementRef;\n @ViewChild('shadowTextEl', { static: false }) private shadowTextEl!: ElementRef;\n private inited = false;\n orgHtml!: SafeHtml;\n type = 'default';\n cls = {};\n text = '';\n targetCount = 0;\n\n @Input() @InputBoolean() tooltip = false;\n @Input() @InputNumber(null) length?: number;\n @Input() @InputNumber(null) lines?: number;\n @Input() @InputBoolean() fullWidthRecognition = false;\n @Input() tail = '...';\n\n get linsWord(): string {\n const { targetCount, text, tail } = this;\n return (\n (targetCount > 0 ? text.substring(0, targetCount) : '') +\n (targetCount > 0 && targetCount < text.length ? tail : '')\n );\n }\n\n private get win(): NzSafeAny {\n return this.doc.defaultView || window;\n }\n\n constructor(\n private el: ElementRef,\n private ngZone: NgZone,\n private dom: DomSanitizer,\n @Inject(DOCUMENT) private doc: NzSafeAny,\n private cdr: ChangeDetectorRef\n ) {}\n\n private getStrFullLength(str: string): number {\n return str.split('').reduce((pre, cur) => {\n const charCode = cur.charCodeAt(0);\n if (charCode >= 0 && charCode <= 128) {\n return pre + 1;\n }\n return pre + 2;\n }, 0);\n }\n\n private cutStrByFullLength(str: string, maxLength: number): string {\n let showLength = 0;\n return str.split('').reduce((pre, cur) => {\n const charCode = cur.charCodeAt(0);\n if (charCode >= 0 && charCode <= 128) {\n showLength += 1;\n } else {\n showLength += 2;\n }\n if (showLength <= maxLength) {\n return pre + cur;\n }\n return pre;\n }, '');\n }\n\n private bisection(\n targetHeight: number,\n mid: number,\n begin: number,\n end: number,\n text: string,\n node: HTMLElement\n ): number {\n const suffix = this.tail;\n node.innerHTML = text.substring(0, mid) + suffix;\n let sh = node.offsetHeight;\n\n if (sh <= targetHeight) {\n node.innerHTML = text.substring(0, mid + 1) + suffix;\n sh = node.offsetHeight;\n if (sh > targetHeight || mid === begin) {\n return mid;\n }\n begin = mid;\n mid = end - begin === 1 ? begin + 1 : Math.floor((end - begin) / 2) + begin;\n return this.bisection(targetHeight, mid, begin, end, text, node);\n }\n if (mid - 1 < 0) {\n return mid;\n }\n node.innerHTML = text.substring(0, mid - 1) + suffix;\n sh = node.offsetHeight;\n if (sh <= targetHeight) {\n return mid - 1;\n }\n end = mid;\n mid = Math.floor((end - begin) / 2) + begin;\n return this.bisection(targetHeight, mid, begin, end, text, node);\n }\n\n private genType(): void {\n const { lines, length, isSupportLineClamp } = this;\n this.cls = {\n ellipsis: true,\n ellipsis__lines: lines && !isSupportLineClamp,\n 'ellipsis__line-clamp': lines && isSupportLineClamp\n };\n if (!lines && !length) {\n this.type = 'default';\n } else if (!lines) {\n this.type = 'length';\n } else if (isSupportLineClamp) {\n this.type = 'line-clamp';\n } else {\n this.type = 'line';\n }\n }\n\n private gen(): void {\n const { type, lines, length, fullWidthRecognition, tail, orgEl, cdr, ngZone } = this;\n if (type === 'length') {\n const el = orgEl.nativeElement as HTMLElement;\n if (el.children.length > 0) {\n throw new Error('Ellipsis content must be string.');\n }\n const lengthText = el.textContent!;\n const textLength = fullWidthRecognition ? this.getStrFullLength(lengthText) : lengthText.length;\n if (textLength <= length! || length! < 0) {\n this.text = lengthText;\n } else {\n let displayText: string;\n if (length! - tail.length <= 0) {\n displayText = '';\n } else {\n displayText = fullWidthRecognition\n ? this.cutStrByFullLength(lengthText, length!)\n : lengthText.slice(0, length);\n }\n this.text = displayText + tail;\n }\n ngZone.run(() => cdr.detectChanges());\n } else if (type === 'line') {\n const { shadowOrgEl, shadowTextEl } = this;\n const orgNode = shadowOrgEl.nativeElement as HTMLElement;\n const lineText = orgNode.innerText || orgNode.textContent!;\n const lineHeight = parseInt(this.win.getComputedStyle(this.getEl('.ellipsis')).lineHeight!, 10);\n const targetHeight = lines! * lineHeight;\n this.getEl('.ellipsis__handle').style.height = `${targetHeight}px`;\n\n if (orgNode.offsetHeight <= targetHeight) {\n this.text = lineText;\n this.targetCount = lineText.length;\n } else {\n // bisection\n const len = lineText.length;\n const mid = Math.ceil(len / 2);\n\n const count = this.bisection(targetHeight, mid, 0, len, lineText, shadowTextEl.nativeElement.firstChild);\n this.text = lineText;\n this.targetCount = count;\n }\n ngZone.run(() => cdr.detectChanges());\n }\n }\n\n private getEl(cls: string): HTMLElement {\n return this.el.nativeElement.querySelector(cls);\n }\n\n private executeOnStable(fn: () => void): void {\n if (this.ngZone.isStable) {\n fn();\n } else {\n this.ngZone.onStable.asObservable().pipe(take(1)).subscribe(fn);\n }\n }\n\n refresh(): void {\n this.genType();\n const { type, dom, orgEl, cdr } = this;\n const html = orgEl.nativeElement.innerHTML;\n this.orgHtml = dom.bypassSecurityTrustHtml(html);\n cdr.detectChanges();\n this.executeOnStable(() => {\n this.gen();\n if (type !== 'line') {\n const el = this.getEl('.ellipsis');\n if (el) {\n el.innerHTML = html;\n }\n }\n });\n }\n\n ngAfterViewInit(): void {\n this.inited = true;\n this.refresh();\n }\n\n ngOnChanges(): void {\n if (this.inited) {\n this.refresh();\n }\n }\n}\n","<div (cdkObserveContent)=\"refresh()\" #orgEl style=\"display: none\"><ng-content></ng-content></div>\n<ng-template #tooltipTpl let-con>\n <span\n *ngIf=\"tooltip; else con\"\n nz-tooltip\n [nzTooltipTitle]=\"titleTpl\"\n [nzTooltipOverlayStyle]=\"{ 'overflow-wrap': 'break-word', 'word-wrap': 'break-word' }\"\n >\n <ng-container *ngTemplateOutlet=\"con\"></ng-container>\n <ng-template #titleTpl><div [innerHTML]=\"orgHtml\"></div></ng-template>\n </span>\n</ng-template>\n<ng-container [ngSwitch]=\"type\">\n <span *ngSwitchCase=\"'default'\" [ngClass]=\"cls\"></span>\n <ng-container *ngSwitchCase=\"'length'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lengthTpl }\"></ng-template>\n <ng-template #lengthTpl>{{ text }}</ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"'line-clamp'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineClampTpl }\"></ng-template>\n <ng-template #lineClampTpl>\n <div [ngClass]=\"cls\" [ngStyle]=\"{ '-webkit-line-clamp': lines, '-webkit-box-orient': 'vertical' }\"></div>\n </ng-template>\n </ng-container>\n <div *ngSwitchCase=\"'line'\" [ngClass]=\"cls\">\n <div class=\"ellipsis__handle\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineTpl }\"></ng-template>\n <ng-template #lineTpl>{{ linsWord }}</ng-template>\n <div class=\"ellipsis__shadow\" #shadowOrgEl [innerHTML]=\"orgHtml\"></div>\n <div class=\"ellipsis__shadow\" #shadowTextEl>\n <span>{{ text }}</span>\n </div>\n </div>\n </div>\n</ng-container>\n","import { ObserversModule } from '@angular/cdk/observers';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { NzToolTipModule } from 'ng-zorro-antd/tooltip';\n\nimport { EllipsisComponent } from './ellipsis.component';\n\nconst COMPONENTS = [EllipsisComponent];\n\n@NgModule({\n imports: [CommonModule, ObserversModule, NzToolTipModule],\n declarations: COMPONENTS,\n exports: COMPONENTS\n})\nexport class EllipsisModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;MA4Ba,iBAAiB,CAAA;AAuB5B,IAAA,IAAI,QAAQ,GAAA;QACV,MAAM,EAAE,WAAW,EAAE,IA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E,MAAM,EAAE,KAAK,EAAE,CAAA;gBAQnB,OAAO,EAAA,CAAA;sBAA/B,KAAK;gBACsB,MAAM,EAAA,CAAA;sBAAjC,KAAK;gBACsB,KAAK,EAAA,CAAA;sBAAhC,KAAK;gBACmB,oBAAoB,EAAA,CAAA;sBAA5C,KAAK;gBACG,IAAI,EAAA,CAAA;sBAAZ,KAAK;;;AEzCR,MAAM,UAAU,GAAG,CAAC,iBAAiB,CAAC,CAAC;MAO1B,cAAc,CAAA;8GAAd,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;+GAAd,cAAc,EAAA,YAAA,EAAA,CAPP,iBAAiB,CAGzB,EAAA,OAAA,EAAA,CAAA,YAAY,EAAE,eAAe,EAAE,eAAe,CAAA,EAAA,OAAA,EAAA,CAHtC,iBAAiB,CAAA,EAAA,CAAA,CAAA,EAAA;AAOxB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,EAJf,OAAA,EAAA,CAAA,YAAY,EAAE,eAAe,EAAE,eAAe,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAI7C,cAAc,EAAA,UAAA,EAAA,CAAA;kBAL1B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,EAAE,eAAe,CAAC;AACzD,oBAAA,YAAY,EAAE,UAAU;AACxB,oBAAA,OAAO,EAAE,UAAU;AACpB,iBAAA,CAAA;;;ACdD;;AAEG;;;;"}
1
+ {"version":3,"file":"ellipsis.mjs","sources":["../../../../packages/abc/ellipsis/ellipsis.component.ts","../../../../packages/abc/ellipsis/ellipsis.component.html","../../../../packages/abc/ellipsis/ellipsis.module.ts","../../../../packages/abc/ellipsis/ellipsis.ts"],"sourcesContent":["import { DOCUMENT } from '@angular/common';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n Inject,\n Input,\n NgZone,\n OnChanges,\n ViewChild,\n ViewEncapsulation\n} from '@angular/core';\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\nimport { take } from 'rxjs';\n\nimport { BooleanInput, InputBoolean, InputNumber, NumberInput } from '@delon/util/decorator';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n@Component({\n selector: 'ellipsis',\n exportAs: 'ellipsis',\n templateUrl: './ellipsis.component.html',\n preserveWhitespaces: false,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class EllipsisComponent implements AfterViewInit, OnChanges {\n static ngAcceptInputType_tooltip: BooleanInput;\n static ngAcceptInputType_length: NumberInput;\n static ngAcceptInputType_lines: NumberInput;\n static ngAcceptInputType_fullWidthRecognition: BooleanInput;\n\n private isSupportLineClamp = this.doc.body.style['webkitLineClamp'] !== undefined;\n @ViewChild('orgEl', { static: false }) private orgEl!: ElementRef;\n @ViewChild('shadowOrgEl', { static: false }) private shadowOrgEl!: ElementRef;\n @ViewChild('shadowTextEl', { static: false }) private shadowTextEl!: ElementRef;\n private inited = false;\n orgHtml!: SafeHtml;\n type = 'default';\n cls = {};\n text = '';\n targetCount = 0;\n\n @Input() @InputBoolean() tooltip = false;\n @Input() @InputNumber(null) length?: number;\n @Input() @InputNumber(null) lines?: number;\n @Input() @InputBoolean() fullWidthRecognition = false;\n @Input() tail = '...';\n\n get linsWord(): string {\n const { targetCount, text, tail } = this;\n return (\n (targetCount > 0 ? text.substring(0, targetCount) : '') +\n (targetCount > 0 && targetCount < text.length ? tail : '')\n );\n }\n\n private get win(): NzSafeAny {\n return this.doc.defaultView || window;\n }\n\n constructor(\n private el: ElementRef,\n private ngZone: NgZone,\n private dom: DomSanitizer,\n @Inject(DOCUMENT) private doc: NzSafeAny,\n private cdr: ChangeDetectorRef\n ) {}\n\n private getStrFullLength(str: string): number {\n return str.split('').reduce((pre, cur) => {\n const charCode = cur.charCodeAt(0);\n if (charCode >= 0 && charCode <= 128) {\n return pre + 1;\n }\n return pre + 2;\n }, 0);\n }\n\n private cutStrByFullLength(str: string, maxLength: number): string {\n let showLength = 0;\n return str.split('').reduce((pre, cur) => {\n const charCode = cur.charCodeAt(0);\n if (charCode >= 0 && charCode <= 128) {\n showLength += 1;\n } else {\n showLength += 2;\n }\n if (showLength <= maxLength) {\n return pre + cur;\n }\n return pre;\n }, '');\n }\n\n private bisection(\n targetHeight: number,\n mid: number,\n begin: number,\n end: number,\n text: string,\n node: HTMLElement\n ): number {\n const suffix = this.tail;\n node.innerHTML = text.substring(0, mid) + suffix;\n let sh = node.offsetHeight;\n\n if (sh <= targetHeight) {\n node.innerHTML = text.substring(0, mid + 1) + suffix;\n sh = node.offsetHeight;\n if (sh > targetHeight || mid === begin) {\n return mid;\n }\n begin = mid;\n mid = end - begin === 1 ? begin + 1 : Math.floor((end - begin) / 2) + begin;\n return this.bisection(targetHeight, mid, begin, end, text, node);\n }\n if (mid - 1 < 0) {\n return mid;\n }\n node.innerHTML = text.substring(0, mid - 1) + suffix;\n sh = node.offsetHeight;\n if (sh <= targetHeight) {\n return mid - 1;\n }\n end = mid;\n mid = Math.floor((end - begin) / 2) + begin;\n return this.bisection(targetHeight, mid, begin, end, text, node);\n }\n\n private genType(): void {\n const { lines, length, isSupportLineClamp } = this;\n this.cls = {\n ellipsis: true,\n ellipsis__lines: lines && !isSupportLineClamp,\n 'ellipsis__line-clamp': lines && isSupportLineClamp\n };\n if (!lines && !length) {\n this.type = 'default';\n } else if (!lines) {\n this.type = 'length';\n } else if (isSupportLineClamp) {\n this.type = 'line-clamp';\n } else {\n this.type = 'line';\n }\n }\n\n private gen(): void {\n const { type, lines, length, fullWidthRecognition, tail, orgEl, cdr, ngZone } = this;\n if (type === 'length') {\n const el = orgEl.nativeElement as HTMLElement;\n if (el.children.length > 0) {\n throw new Error('Ellipsis content must be string.');\n }\n const lengthText = el.textContent!;\n const textLength = fullWidthRecognition ? this.getStrFullLength(lengthText) : lengthText.length;\n if (textLength <= length! || length! < 0) {\n this.text = lengthText;\n } else {\n let displayText: string;\n if (length! - tail.length <= 0) {\n displayText = '';\n } else {\n displayText = fullWidthRecognition\n ? this.cutStrByFullLength(lengthText, length!)\n : lengthText.slice(0, length);\n }\n this.text = displayText + tail;\n }\n ngZone.run(() => cdr.detectChanges());\n } else if (type === 'line') {\n const { shadowOrgEl, shadowTextEl } = this;\n const orgNode = shadowOrgEl.nativeElement as HTMLElement;\n const lineText = orgNode.innerText || orgNode.textContent!;\n const lineHeight = parseInt(this.win.getComputedStyle(this.getEl('.ellipsis')).lineHeight!, 10);\n const targetHeight = lines! * lineHeight;\n this.getEl('.ellipsis__handle').style.height = `${targetHeight}px`;\n\n if (orgNode.offsetHeight <= targetHeight) {\n this.text = lineText;\n this.targetCount = lineText.length;\n } else {\n // bisection\n const len = lineText.length;\n const mid = Math.ceil(len / 2);\n\n const count = this.bisection(targetHeight, mid, 0, len, lineText, shadowTextEl.nativeElement.firstChild);\n this.text = lineText;\n this.targetCount = count;\n }\n ngZone.run(() => cdr.detectChanges());\n }\n }\n\n private getEl(cls: string): HTMLElement {\n return this.el.nativeElement.querySelector(cls);\n }\n\n private executeOnStable(fn: () => void): void {\n if (this.ngZone.isStable) {\n fn();\n } else {\n this.ngZone.onStable.asObservable().pipe(take(1)).subscribe(fn);\n }\n }\n\n refresh(): void {\n this.genType();\n const { type, dom, orgEl, cdr } = this;\n const html = orgEl.nativeElement.innerHTML;\n this.orgHtml = dom.bypassSecurityTrustHtml(html);\n cdr.detectChanges();\n this.executeOnStable(() => {\n this.gen();\n if (type !== 'line') {\n const el = this.getEl('.ellipsis');\n if (el) {\n el.innerHTML = html;\n }\n }\n });\n }\n\n ngAfterViewInit(): void {\n this.inited = true;\n this.refresh();\n }\n\n ngOnChanges(): void {\n if (this.inited) {\n this.refresh();\n }\n }\n}\n","<div (cdkObserveContent)=\"refresh()\" #orgEl style=\"display: none\"><ng-content /></div>\n<ng-template #tooltipTpl let-con>\n <span\n *ngIf=\"tooltip; else con\"\n nz-tooltip\n [nzTooltipTitle]=\"titleTpl\"\n [nzTooltipOverlayStyle]=\"{ 'overflow-wrap': 'break-word', 'word-wrap': 'break-word' }\"\n >\n <ng-container *ngTemplateOutlet=\"con\" />\n <ng-template #titleTpl><div [innerHTML]=\"orgHtml\"></div></ng-template>\n </span>\n</ng-template>\n<ng-container [ngSwitch]=\"type\">\n <span *ngSwitchCase=\"'default'\" [ngClass]=\"cls\"></span>\n <ng-container *ngSwitchCase=\"'length'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lengthTpl }\"></ng-template>\n <ng-template #lengthTpl>{{ text }}</ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"'line-clamp'\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineClampTpl }\"></ng-template>\n <ng-template #lineClampTpl>\n <div [ngClass]=\"cls\" [ngStyle]=\"{ '-webkit-line-clamp': lines, '-webkit-box-orient': 'vertical' }\"></div>\n </ng-template>\n </ng-container>\n <div *ngSwitchCase=\"'line'\" [ngClass]=\"cls\">\n <div class=\"ellipsis__handle\">\n <ng-template [ngTemplateOutlet]=\"tooltipTpl\" [ngTemplateOutletContext]=\"{ $implicit: lineTpl }\"></ng-template>\n <ng-template #lineTpl>{{ linsWord }}</ng-template>\n <div class=\"ellipsis__shadow\" #shadowOrgEl [innerHTML]=\"orgHtml\"></div>\n <div class=\"ellipsis__shadow\" #shadowTextEl>\n <span>{{ text }}</span>\n </div>\n </div>\n </div>\n</ng-container>\n","import { ObserversModule } from '@angular/cdk/observers';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { NzToolTipModule } from 'ng-zorro-antd/tooltip';\n\nimport { EllipsisComponent } from './ellipsis.component';\n\nconst COMPONENTS = [EllipsisComponent];\n\n@NgModule({\n imports: [CommonModule, ObserversModule, NzToolTipModule],\n declarations: COMPONENTS,\n exports: COMPONENTS\n})\nexport class EllipsisModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;MA4Ba,iBAAiB,CAAA;AAuB5B,IAAA,IAAI,QAAQ,GAAA;QACV,MAAM,EAAE,WAAW,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,IAAI,CAAC;QACzC,QACE,CAAC,WAAW,GAAG,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC,EAAE,WAAW,CAAC,GAAG,EAAE;AACtD,aAAC,WAAW,GAAG,CAAC,IAAI,WAAW,GAAG,IAAI,CAAC,MAAM,GAAG,IAAI,GAAG,EAAE,CAAC,EAC1D;KACH;AAED,IAAA,IAAY,GAAG,GAAA;AACb,QAAA,OAAO,IAAI,CAAC,GAAG,CAAC,WAAW,IAAI,MAAM,CAAC;KACvC;IAED,WACU,CAAA,EAAc,EACd,MAAc,EACd,GAAiB,EACC,GAAc,EAChC,GAAsB,EAAA;QAJtB,IAAE,CAAA,EAAA,GAAF,EAAE,CAAY;QACd,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;QACd,IAAG,CAAA,GAAA,GAAH,GAAG,CAAc;QACC,IAAG,CAAA,GAAA,GAAH,GAAG,CAAW;QAChC,IAAG,CAAA,GAAA,GAAH,GAAG,CAAmB;AAlCxB,QAAA,IAAA,CAAA,kBAAkB,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,iBAAiB,CAAC,KAAK,SAAS,CAAC;QAI1E,IAAM,CAAA,MAAA,GAAG,KAAK,CAAC;QAEvB,IAAI,CAAA,IAAA,GAAG,SAAS,CAAC;QACjB,IAAG,CAAA,GAAA,GAAG,EAAE,CAAC;QACT,IAAI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Q;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,EAAE,eAAe,CAAC;AACzD,oBAAA,YAAY,EAAE,UAAU;AACxB,oBAAA,OAAO,EAAE,UAAU;AACpB,iBAAA,CAAA;;;ACdD;;AAEG;;;;"}
@@ -1,8 +1,9 @@
1
1
  import { __decorate } from 'tslib';
2
2
  import { DOCUMENT, CommonModule } from '@angular/common';
3
3
  import * as i0 from '@angular/core';
4
- import { Component, ChangeDetectionStrategy, ViewEncapsulation, Inject, Optional, Input, NgModule } from '@angular/core';
5
- import { Subject, takeUntil, interval } from 'rxjs';
4
+ import { inject, DestroyRef, Component, ChangeDetectionStrategy, ViewEncapsulation, Inject, Optional, Input, NgModule } from '@angular/core';
5
+ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
6
+ import { interval } from 'rxjs';
6
7
  import { InputNumber } from '@delon/util/decorator';
7
8
  import * as i1 from '@delon/util/config';
8
9
  import * as i2 from '@angular/cdk/bidi';
@@ -18,7 +19,7 @@ class ErrorCollectComponent {
18
19
  this.directionality = directionality;
19
20
  this.platform = platform;
20
21
  this.formEl = null;
21
- this.destroy$ = new Subject();
22
+ this.destroy$ = inject(DestroyRef);
22
23
  this._hiden = true;
23
24
  this.count = 0;
24
25
  this.dir = 'ltr';
@@ -48,11 +49,12 @@ class ErrorCollectComponent {
48
49
  }
49
50
  install() {
50
51
  this.dir = this.directionality.value;
51
- this.directionality.change?.pipe(takeUntil(this.destroy$)).subscribe((direction) => {
52
+ this.directionality.change?.pipe(takeUntilDestroyed(this.destroy$)).subscribe((direction) => {
52
53
  this.dir = direction;
54
+ this.cdr.detectChanges();
53
55
  });
54
56
  interval(this.freq)
55
- .pipe(takeUntil(this.destroy$))
57
+ .pipe(takeUntilDestroyed(this.destroy$))
56
58
  .subscribe(() => this.update());
57
59
  this.update();
58
60
  }
@@ -75,12 +77,8 @@ class ErrorCollectComponent {
75
77
  throw new Error('No found form element');
76
78
  this.install();
77
79
  }
78
- ngOnDestroy() {
79
- this.destroy$.next();
80
- this.destroy$.complete();
81
- }
82
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ErrorCollectComponent, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: DOCUMENT }, { token: i1.AlainConfigService }, { token: i2.Directionality, optional: true }, { token: i3.Platform }], target: i0.ɵɵFactoryTarget.Component }); }
83
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.6", type: ErrorCollectComponent, selector: "error-collect, [error-collect]", inputs: { freq: "freq", offsetTop: "offsetTop" }, host: { listeners: { "click": "_click()" }, properties: { "class.error-collect": "true", "class.error-collect-rtl": "dir === 'rtl'", "class.d-none": "_hiden" } }, exportAs: ["errorCollect"], ngImport: i0, template: `
80
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ErrorCollectComponent, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: DOCUMENT }, { token: i1.AlainConfigService }, { token: i2.Directionality, optional: true }, { token: i3.Platform }], target: i0.ɵɵFactoryTarget.Component }); }
81
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.3", type: ErrorCollectComponent, selector: "error-collect, [error-collect]", inputs: { freq: "freq", offsetTop: "offsetTop" }, host: { listeners: { "click": "_click()" }, properties: { "class.error-collect": "true", "class.error-collect-rtl": "dir === 'rtl'", "class.d-none": "_hiden" } }, exportAs: ["errorCollect"], ngImport: i0, template: `
84
82
  <i nz-icon nzType="exclamation-circle"></i>
85
83
  <span class="error-collect__count">{{ count }}</span>
86
84
  `, isInline: true, dependencies: [{ kind: "directive", type: i4.NzIconDirective, selector: "[nz-icon]", inputs: ["nzSpin", "nzRotate", "nzType", "nzTheme", "nzTwotoneColor", "nzIconfont"], exportAs: ["nzIcon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
@@ -91,7 +89,7 @@ __decorate([
91
89
  __decorate([
92
90
  InputNumber()
93
91
  ], ErrorCollectComponent.prototype, "offsetTop", void 0);
94
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ErrorCollectComponent, decorators: [{
92
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ErrorCollectComponent, decorators: [{
95
93
  type: Component,
96
94
  args: [{
97
95
  selector: 'error-collect, [error-collect]',
@@ -123,11 +121,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImpor
123
121
 
124
122
  const COMPONENTS = [ErrorCollectComponent];
125
123
  class ErrorCollectModule {
126
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ErrorCollectModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
127
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.6", ngImport: i0, type: ErrorCollectModule, declarations: [ErrorCollectComponent], imports: [CommonModule, NzIconModule], exports: [ErrorCollectComponent] }); }
128
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ErrorCollectModule, imports: [CommonModule, NzIconModule] }); }
124
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ErrorCollectModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
125
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.3", ngImport: i0, type: ErrorCollectModule, declarations: [ErrorCollectComponent], imports: [CommonModule, NzIconModule], exports: [ErrorCollectComponent] }); }
126
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ErrorCollectModule, imports: [CommonModule, NzIconModule] }); }
129
127
  }
130
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ErrorCollectModule, decorators: [{
128
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ErrorCollectModule, decorators: [{
131
129
  type: NgModule,
132
130
  args: [{
133
131
  imports: [CommonModule, NzIconModule],
@@ -1 +1 @@
1
- {"version":3,"file":"error-collect.mjs","sources":["../../../../packages/abc/error-collect/error-collect.component.ts","../../../../packages/abc/error-collect/error-collect.module.ts","../../../../packages/abc/error-collect/error-collect.ts"],"sourcesContent":["import { Direction, Directionality } from '@angular/cdk/bidi';\nimport { Platform } from '@angular/cdk/platform';\nimport { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional,\n ViewEncapsulation\n} from '@angular/core';\nimport { interval, Subject, takeUntil } from 'rxjs';\n\nimport { AlainConfigService } from '@delon/util/config';\nimport { InputNumber } from '@delon/util/decorator';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n@Component({\n selector: 'error-collect, [error-collect]',\n exportAs: 'errorCollect',\n template: `\n <i nz-icon nzType=\"exclamation-circle\"></i>\n <span class=\"error-collect__count\">{{ count }}</span>\n `,\n host: {\n '[class.error-collect]': 'true',\n '[class.error-collect-rtl]': `dir === 'rtl'`,\n '[class.d-none]': '_hiden',\n '(click)': '_click()'\n },\n preserveWhitespaces: false,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class ErrorCollectComponent implements OnInit, OnDestroy {\n private formEl: HTMLFormElement | null = null;\n private destroy$ = new Subject<void>();\n\n _hiden = true;\n count = 0;\n dir: Direction = 'ltr';\n\n @Input() @InputNumber() freq!: number;\n @Input() @InputNumber() offsetTop!: number;\n\n constructor(\n private el: ElementRef,\n private cdr: ChangeDetectorRef,\n @Inject(DOCUMENT) private doc: NzSafeAny,\n configSrv: AlainConfigService,\n @Optional() private directionality: Directionality,\n private platform: Platform\n ) {\n configSrv.attach(this, 'errorCollect', { freq: 500, offsetTop: 65 + 64 + 8 * 2 });\n }\n\n private get errEls(): NodeListOf<HTMLElement> {\n return this.formEl!.querySelectorAll('.ant-form-item-has-error');\n }\n\n private update(): void {\n const count = this.errEls.length;\n if (count === this.count) return;\n this.count = count;\n this._hiden = count === 0;\n this.cdr.markForCheck();\n }\n\n _click(): boolean {\n if (this.count === 0) return false;\n // nz-form-control\n const els = this.errEls;\n const formItemEl = this.findParent(els[0], '[nz-form-control]') || els[0];\n formItemEl.scrollIntoView(true);\n // fix header height\n this.doc.documentElement.scrollTop -= this.offsetTop;\n return true;\n }\n\n private install(): void {\n this.dir = this.directionality.value;\n this.directionality.change?.pipe(takeUntil(this.destroy$)).subscribe((direction: Direction) => {\n this.dir = direction;\n });\n interval(this.freq)\n .pipe(takeUntil(this.destroy$))\n .subscribe(() => this.update());\n this.update();\n }\n\n private findParent(el: Element, selector: string): HTMLFormElement | null {\n let retEl: HTMLFormElement | null = null;\n while (el) {\n if (el.querySelector(selector)) {\n retEl = el as HTMLFormElement;\n break;\n }\n el = el.parentElement as HTMLFormElement;\n }\n return retEl;\n }\n\n ngOnInit(): void {\n if (!this.platform.isBrowser) return;\n\n this.formEl = this.findParent(this.el.nativeElement, 'form');\n if (this.formEl === null) throw new Error('No found form element');\n this.install();\n }\n\n ngOnDestroy(): void {\n this.destroy$.next();\n this.destroy$.complete();\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { NzIconModule } from 'ng-zorro-antd/icon';\n\nimport { ErrorCollectComponent } from './error-collect.component';\n\nconst COMPONENTS = [ErrorCollectComponent];\n\n@NgModule({\n imports: [CommonModule, NzIconModule],\n declarations: COMPONENTS,\n exports: CO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-collect/error-collect.module.ts","../../../../packages/abc/error-collect/error-collect.ts"],"sourcesContent":["import { Direction, Directionality } from '@angular/cdk/bidi';\nimport { Platform } from '@angular/cdk/platform';\nimport { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n DestroyRef,\n ElementRef,\n Inject,\n Input,\n OnInit,\n Optional,\n ViewEncapsulation,\n inject\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { interval } from 'rxjs';\n\nimport { AlainConfigService } from '@delon/util/config';\nimport { InputNumber } from '@delon/util/decorator';\nimport type { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n@Component({\n selector: 'error-collect, [error-collect]',\n exportAs: 'errorCollect',\n template: `\n <i nz-icon nzType=\"exclamation-circle\"></i>\n <span class=\"error-collect__count\">{{ count }}</span>\n `,\n host: {\n '[class.error-collect]': 'true',\n '[class.error-collect-rtl]': `dir === 'rtl'`,\n '[class.d-none]': '_hiden',\n '(click)': '_click()'\n },\n preserveWhitespaces: false,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class ErrorCollectComponent implements OnInit {\n private formEl: HTMLFormElement | null = null;\n private destroy$ = inject(DestroyRef);\n\n _hiden = true;\n count = 0;\n dir: Direction = 'ltr';\n\n @Input() @InputNumber() freq!: number;\n @Input() @InputNumber() offsetTop!: number;\n\n constructor(\n private el: ElementRef,\n private cdr: ChangeDetectorRef,\n @Inject(DOCUMENT) private doc: NzSafeAny,\n configSrv: AlainConfigService,\n @Optional() private directionality: Directionality,\n private platform: Platform\n ) {\n configSrv.attach(this, 'errorCollect', { freq: 500, offsetTop: 65 + 64 + 8 * 2 });\n }\n\n private get errEls(): NodeListOf<HTMLElement> {\n return this.formEl!.querySelectorAll('.ant-form-item-has-error');\n }\n\n private update(): void {\n const count = this.errEls.length;\n if (count === this.count) return;\n this.count = count;\n this._hiden = count === 0;\n this.cdr.markForCheck();\n }\n\n _click(): boolean {\n if (this.count === 0) return false;\n // nz-form-control\n const els = this.errEls;\n const formItemEl = this.findParent(els[0], '[nz-form-control]') || els[0];\n formItemEl.scrollIntoView(true);\n // fix header height\n this.doc.documentElement.scrollTop -= this.offsetTop;\n return true;\n }\n\n private install(): void {\n this.dir = this.directionality.value;\n this.directionality.change?.pipe(takeUntilDestroyed(this.destroy$)).subscribe((direction: Direction) => {\n this.dir = direction;\n this.cdr.detectChanges();\n });\n interval(this.freq)\n .pipe(takeUntilDestroyed(this.destroy$))\n .subscribe(() => this.update());\n this.update();\n }\n\n private findParent(el: Element, selector: string): HTMLFormElement | null {\n let retEl: HTMLFormElement | null = null;\n while (el) {\n if (el.querySelector(selector)) {\n retEl = el as HTMLFormElement;\n break;\n }\n el = el.parentElement as HTMLFormElement;\n }\n return retEl;\n }\n\n ngOnInit(): void {\n if (!this.platform.isBrowser) return;\n\n this.formEl = this.findParent(this.el.nativeElement, 'form');\n if (this.formEl === null) throw new Error('No found form element');\n this.install();\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { NzIconModule } from 'ng-zorro-antd/icon';\n\nimport { ErrorCollectComponent } from './error-collect.component';\n\nconst COMPONENTS = [ErrorCollectComponent];\n\n@NgModule({\n imports: [CommonModule, NzIconModule],\n declarations: COMPONENTS,\n exports: COMPONENTS\n})\nexport class ErrorCollectModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAwCa,qBAAqB,CAAA;IAWhC,WACU,CAAA,EAAc,EACd,GAAsB,EACJ,GAAc,EACxC,SAA6B,EACT,cAA8B,EAC1C,QAAkB,EAAA;QALlB,IAAE,CAAA,EAAA,GAAF,EAAE,CAAY;QACd,IAAG,CAAA,GAAA,GAAH,GAAG,CAAmB;QACJ,IAAG,CAAA,GAAA,GAAH,GAAG,CAAW;QAEpB,IAAc,CAAA,cAAA,GAAd,cAAc,CAAgB;Q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A,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,kBAAkB,iBAPX,qBAAqB,CAAA,EAAA,OAAA,EAAA,CAG7B,YAAY,EAAE,YAAY,aAHlB,qBAAqB,CAAA,EAAA,CAAA,CAAA,EAAA;+GAO5B,kBAAkB,EAAA,OAAA,EAAA,CAJnB,YAAY,EAAE,YAAY,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAIzB,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAL9B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,YAAY,CAAC;AACrC,oBAAA,YAAY,EAAE,UAAU;AACxB,oBAAA,OAAO,EAAE,UAAU;AACpB,iBAAA,CAAA;;;ACbD;;AAEG;;;;"}
@@ -1,6 +1,6 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Component, ChangeDetectionStrategy, ViewEncapsulation, Optional, ViewChild, Input, NgModule } from '@angular/core';
3
- import { Subject, takeUntil } from 'rxjs';
2
+ import { inject, DestroyRef, Component, ChangeDetectionStrategy, ViewEncapsulation, Optional, ViewChild, Input, NgModule } from '@angular/core';
3
+ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
4
4
  import { isEmpty } from '@delon/util/browser';
5
5
  import * as i1 from '@delon/theme';
6
6
  import { DelonLocaleModule } from '@delon/theme';
@@ -49,7 +49,7 @@ class ExceptionComponent {
49
49
  this.dom = dom;
50
50
  this.directionality = directionality;
51
51
  this.cdr = cdr;
52
- this.destroy$ = new Subject();
52
+ this.destroy$ = inject(DestroyRef);
53
53
  this.locale = {};
54
54
  this.hasCon = false;
55
55
  this.dir = 'ltr';
@@ -76,25 +76,25 @@ class ExceptionComponent {
76
76
  }
77
77
  ngOnInit() {
78
78
  this.dir = this.directionality.value;
79
- this.directionality.change?.pipe(takeUntil(this.destroy$)).subscribe((direction) => {
79
+ this.directionality.change?.pipe(takeUntilDestroyed(this.destroy$)).subscribe((direction) => {
80
80
  this.dir = direction;
81
+ this.cdr.detectChanges();
82
+ });
83
+ this.i18n.change.pipe(takeUntilDestroyed(this.destroy$)).subscribe(() => {
84
+ this.locale = this.i18n.getData('exception');
85
+ this.cdr.detectChanges();
81
86
  });
82
- this.i18n.change.pipe(takeUntil(this.destroy$)).subscribe(() => (this.locale = this.i18n.getData('exception')));
83
87
  this.checkContent();
84
88
  }
85
- ngOnDestroy() {
86
- this.destroy$.next();
87
- this.destroy$.complete();
88
- }
89
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ExceptionComponent, deps: [{ token: i1.DelonLocaleService }, { token: i2.DomSanitizer }, { token: i3.AlainConfigService }, { token: i4.Directionality, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
90
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.6", type: ExceptionComponent, selector: "exception", inputs: { type: "type", img: "img", title: "title", desc: "desc", backRouterLink: "backRouterLink" }, host: { properties: { "class.exception": "true", "class.exception-rtl": "dir === 'rtl'" } }, viewQueries: [{ propertyName: "conTpl", first: true, predicate: ["conTpl"], descendants: true, static: true }], exportAs: ["exception"], ngImport: i0, template: "<div class=\"exception__img-block\">\n <div class=\"exception__img\" [style.backgroundImage]=\"_img\"></div>\n</div>\n<div class=\"exception__cont\">\n <h1 class=\"exception__cont-title\" [innerHTML]=\"_title\"></h1>\n <div class=\"exception__cont-desc\" [innerHTML]=\"_desc || locale[_type]\"></div>\n <div class=\"exception__cont-actions\">\n <div (cdkObserveContent)=\"checkContent()\" #conTpl>\n <ng-content></ng-content>\n </div>\n <button *ngIf=\"!hasCon\" nz-button [routerLink]=\"backRouterLink\" [nzType]=\"'primary'\">\n {{ locale.backToHome }}\n </button>\n </div>\n</div>\n", dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i6.CdkObserveContent, selector: "[cdkObserveContent]", inputs: ["cdkObserveContentDisabled", "debounce"], outputs: ["cdkObserveContent"], exportAs: ["cdkObserveContent"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.NzButtonComponent, selector: "button[nz-button], a[nz-button]", inputs: ["nzBlock", "nzGhost", "nzSearch", "nzLoading", "nzDanger", "disabled", "tabIndex", "nzType", "nzShape", "nzSize"], exportAs: ["nzButton"] }, { kind: "directive", type: i9.ɵNzTransitionPatchDirective, selector: "[nz-button], nz-button-group, [nz-icon], [nz-menu-item], [nz-submenu], nz-select-top-control, nz-select-placeholder, nz-input-group", inputs: ["hidden"] }, { kind: "directive", type: i10.NzWaveDirective, selector: "[nz-wave],button[nz-button]:not([nzType=\"link\"]):not([nzType=\"text\"])", inputs: ["nzWaveExtraNode"], exportAs: ["nzWave"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
89
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ExceptionComponent, deps: [{ token: i1.DelonLocaleService }, { token: i2.DomSanitizer }, { token: i3.AlainConfigService }, { token: i4.Directionality, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
90
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.3", type: ExceptionComponent, selector: "exception", inputs: { type: "type", img: "img", title: "title", desc: "desc", backRouterLink: "backRouterLink" }, host: { properties: { "class.exception": "true", "class.exception-rtl": "dir === 'rtl'" } }, viewQueries: [{ propertyName: "conTpl", first: true, predicate: ["conTpl"], descendants: true, static: true }], exportAs: ["exception"], ngImport: i0, template: "<div class=\"exception__img-block\">\n <div class=\"exception__img\" [style.backgroundImage]=\"_img\"></div>\n</div>\n<div class=\"exception__cont\">\n <h1 class=\"exception__cont-title\" [innerHTML]=\"_title\"></h1>\n <div class=\"exception__cont-desc\" [innerHTML]=\"_desc || locale[_type]\"></div>\n <div class=\"exception__cont-actions\">\n <div (cdkObserveContent)=\"checkContent()\" #conTpl>\n <ng-content />\n </div>\n <button *ngIf=\"!hasCon\" nz-button [routerLink]=\"backRouterLink\" [nzType]=\"'primary'\">\n {{ locale.backToHome }}\n </button>\n </div>\n</div>\n", dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i6.CdkObserveContent, selector: "[cdkObserveContent]", inputs: ["cdkObserveContentDisabled", "debounce"], outputs: ["cdkObserveContent"], exportAs: ["cdkObserveContent"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.NzButtonComponent, selector: "button[nz-button], a[nz-button]", inputs: ["nzBlock", "nzGhost", "nzSearch", "nzLoading", "nzDanger", "disabled", "tabIndex", "nzType", "nzShape", "nzSize"], exportAs: ["nzButton"] }, { kind: "directive", type: i9.ɵNzTransitionPatchDirective, selector: "[nz-button], nz-button-group, [nz-icon], [nz-menu-item], [nz-submenu], nz-select-top-control, nz-select-placeholder, nz-input-group", inputs: ["hidden"] }, { kind: "directive", type: i10.NzWaveDirective, selector: "[nz-wave],button[nz-button]:not([nzType=\"link\"]):not([nzType=\"text\"])", inputs: ["nzWaveExtraNode"], exportAs: ["nzWave"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
91
91
  }
92
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ExceptionComponent, decorators: [{
92
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ExceptionComponent, decorators: [{
93
93
  type: Component,
94
94
  args: [{ selector: 'exception', exportAs: 'exception', host: {
95
95
  '[class.exception]': 'true',
96
96
  '[class.exception-rtl]': `dir === 'rtl'`
97
- }, preserveWhitespaces: false, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div class=\"exception__img-block\">\n <div class=\"exception__img\" [style.backgroundImage]=\"_img\"></div>\n</div>\n<div class=\"exception__cont\">\n <h1 class=\"exception__cont-title\" [innerHTML]=\"_title\"></h1>\n <div class=\"exception__cont-desc\" [innerHTML]=\"_desc || locale[_type]\"></div>\n <div class=\"exception__cont-actions\">\n <div (cdkObserveContent)=\"checkContent()\" #conTpl>\n <ng-content></ng-content>\n </div>\n <button *ngIf=\"!hasCon\" nz-button [routerLink]=\"backRouterLink\" [nzType]=\"'primary'\">\n {{ locale.backToHome }}\n </button>\n </div>\n</div>\n" }]
97
+ }, preserveWhitespaces: false, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div class=\"exception__img-block\">\n <div class=\"exception__img\" [style.backgroundImage]=\"_img\"></div>\n</div>\n<div class=\"exception__cont\">\n <h1 class=\"exception__cont-title\" [innerHTML]=\"_title\"></h1>\n <div class=\"exception__cont-desc\" [innerHTML]=\"_desc || locale[_type]\"></div>\n <div class=\"exception__cont-actions\">\n <div (cdkObserveContent)=\"checkContent()\" #conTpl>\n <ng-content />\n </div>\n <button *ngIf=\"!hasCon\" nz-button [routerLink]=\"backRouterLink\" [nzType]=\"'primary'\">\n {{ locale.backToHome }}\n </button>\n </div>\n</div>\n" }]
98
98
  }], ctorParameters: function () { return [{ type: i1.DelonLocaleService }, { type: i2.DomSanitizer }, { type: i3.AlainConfigService }, { type: i4.Directionality, decorators: [{
99
99
  type: Optional
100
100
  }] }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { conTpl: [{
@@ -114,11 +114,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImpor
114
114
 
115
115
  const COMPONENTS = [ExceptionComponent];
116
116
  class ExceptionModule {
117
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ExceptionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
118
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.6", ngImport: i0, type: ExceptionModule, declarations: [ExceptionComponent], imports: [CommonModule, ObserversModule, RouterModule, DelonLocaleModule, NzButtonModule], exports: [ExceptionComponent] }); }
119
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ExceptionModule, imports: [CommonModule, ObserversModule, RouterModule, DelonLocaleModule, NzButtonModule] }); }
117
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ExceptionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
118
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.3", ngImport: i0, type: ExceptionModule, declarations: [ExceptionComponent], imports: [CommonModule, ObserversModule, RouterModule, DelonLocaleModule, NzButtonModule], exports: [ExceptionComponent] }); }
119
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ExceptionModule, imports: [CommonModule, ObserversModule, RouterModule, DelonLocaleModule, NzButtonModule] }); }
120
120
  }
121
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: ExceptionModule, decorators: [{
121
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.3", ngImport: i0, type: ExceptionModule, decorators: [{
122
122
  type: NgModule,
123
123
  args: [{
124
124
  imports: [CommonModule, ObserversModule, RouterModule, DelonLocaleModule, NzButtonModule],