cmat 0.0.95 → 0.0.97

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 (93) hide show
  1. package/fesm2022/cmat-components-adapter.mjs +9 -9
  2. package/fesm2022/cmat-components-breadcrumb.mjs +9 -9
  3. package/fesm2022/cmat-components-card.mjs +3 -3
  4. package/fesm2022/cmat-components-carousel.mjs +12 -12
  5. package/fesm2022/cmat-components-cascade.mjs +9 -9
  6. package/fesm2022/cmat-components-chip-input.mjs +3 -3
  7. package/fesm2022/cmat-components-code-editor.mjs +3 -3
  8. package/fesm2022/cmat-components-color-picker.mjs +27 -27
  9. package/fesm2022/cmat-components-custom-formly.mjs +150 -121
  10. package/fesm2022/cmat-components-custom-formly.mjs.map +1 -1
  11. package/fesm2022/cmat-components-data-picker.mjs +15 -15
  12. package/fesm2022/cmat-components-date-range.mjs +5 -5
  13. package/fesm2022/cmat-components-date-range.mjs.map +1 -1
  14. package/fesm2022/cmat-components-date-time-display.mjs +3 -3
  15. package/fesm2022/cmat-components-drawer.mjs +6 -6
  16. package/fesm2022/cmat-components-empty-state.mjs +3 -3
  17. package/fesm2022/cmat-components-file-preview.mjs +3 -3
  18. package/fesm2022/cmat-components-filter-toolbar.mjs +3 -3
  19. package/fesm2022/cmat-components-form-actions.mjs +3 -3
  20. package/fesm2022/cmat-components-fullscreen.mjs +3 -3
  21. package/fesm2022/cmat-components-highlight.mjs +6 -6
  22. package/fesm2022/cmat-components-image-viewer.mjs +3 -3
  23. package/fesm2022/cmat-components-inline-loading.mjs +3 -3
  24. package/fesm2022/cmat-components-json-editor.mjs +3 -3
  25. package/fesm2022/cmat-components-knob-input.mjs +3 -3
  26. package/fesm2022/cmat-components-loading-overlay.mjs +26 -0
  27. package/fesm2022/cmat-components-loading-overlay.mjs.map +1 -0
  28. package/fesm2022/cmat-components-masonry.mjs +4 -4
  29. package/fesm2022/cmat-components-masonry.mjs.map +1 -1
  30. package/fesm2022/cmat-components-material-color-picker.mjs +3 -3
  31. package/fesm2022/cmat-components-material-datetimepicker.mjs +42 -42
  32. package/fesm2022/cmat-components-navigation.mjs +226 -51
  33. package/fesm2022/cmat-components-navigation.mjs.map +1 -1
  34. package/fesm2022/cmat-components-opt-input.mjs +3 -3
  35. package/fesm2022/cmat-components-org-chart.mjs +9 -9
  36. package/fesm2022/cmat-components-page-header.mjs +3 -3
  37. package/fesm2022/cmat-components-pagination.mjs +13 -13
  38. package/fesm2022/cmat-components-pagination.mjs.map +1 -1
  39. package/fesm2022/cmat-components-password-strength.mjs +9 -9
  40. package/fesm2022/cmat-components-popover.mjs +9 -9
  41. package/fesm2022/cmat-components-progress-bar.mjs +3 -3
  42. package/fesm2022/cmat-components-qrcode.mjs +3 -3
  43. package/fesm2022/cmat-components-rating.mjs +3 -3
  44. package/fesm2022/cmat-components-rich-text-editor.mjs +3 -3
  45. package/fesm2022/cmat-components-select-search.mjs +9 -9
  46. package/fesm2022/cmat-components-select-table.mjs +3 -3
  47. package/fesm2022/cmat-components-select-tree.mjs +3 -3
  48. package/fesm2022/cmat-components-skeleton.mjs +3 -3
  49. package/fesm2022/cmat-components-speed-dial.mjs +9 -9
  50. package/fesm2022/cmat-components-status-tag.mjs +3 -3
  51. package/fesm2022/cmat-components-table-toolbar.mjs +3 -3
  52. package/fesm2022/cmat-components-timeline.mjs +12 -12
  53. package/fesm2022/cmat-components-toast.mjs +9 -9
  54. package/fesm2022/cmat-components-transfer-picker.mjs +18 -18
  55. package/fesm2022/cmat-components-treetable.mjs +6 -6
  56. package/fesm2022/cmat-components-upload.mjs +9 -9
  57. package/fesm2022/cmat-directives-animate-on-scroll.mjs +6 -6
  58. package/fesm2022/cmat-directives-arrow-cursor.mjs +3 -3
  59. package/fesm2022/cmat-directives-autofocus.mjs +3 -3
  60. package/fesm2022/cmat-directives-data-exporter.mjs +21 -21
  61. package/fesm2022/cmat-directives-debounce.mjs +9 -9
  62. package/fesm2022/cmat-directives-digit-only.mjs +6 -6
  63. package/fesm2022/cmat-directives-equal-validator.mjs +3 -3
  64. package/fesm2022/cmat-directives-seamless-auto-scroll.mjs +3 -3
  65. package/fesm2022/cmat-lib-mock-api.mjs +6 -6
  66. package/fesm2022/cmat-pipes-bytes.mjs +3 -3
  67. package/fesm2022/cmat-pipes-date-format.mjs +3 -3
  68. package/fesm2022/cmat-pipes-find-by-key.mjs +3 -3
  69. package/fesm2022/cmat-pipes-group-by.mjs +3 -3
  70. package/fesm2022/cmat-pipes-keys.mjs +3 -3
  71. package/fesm2022/cmat-pipes-secure.mjs +3 -3
  72. package/fesm2022/cmat-pipes-uppercase.mjs +3 -3
  73. package/fesm2022/cmat-services-alert.mjs +60 -3
  74. package/fesm2022/cmat-services-alert.mjs.map +1 -1
  75. package/fesm2022/cmat-services-config.mjs +6 -6
  76. package/fesm2022/cmat-services-confirmation.mjs +6 -6
  77. package/fesm2022/cmat-services-data.mjs +3 -3
  78. package/fesm2022/cmat-services-export-as.mjs +3 -3
  79. package/fesm2022/cmat-services-loading.mjs +6 -6
  80. package/fesm2022/cmat-services-local-storage.mjs +3 -3
  81. package/fesm2022/cmat-services-media-watcher.mjs +3 -3
  82. package/fesm2022/cmat-services-platform.mjs +3 -3
  83. package/fesm2022/cmat-services-splash-screen.mjs +3 -3
  84. package/fesm2022/cmat-services-title.mjs +3 -3
  85. package/fesm2022/cmat-services-translation.mjs +3 -3
  86. package/fesm2022/cmat-services-utils.mjs +3 -3
  87. package/fesm2022/cmat.mjs +853 -592
  88. package/fesm2022/cmat.mjs.map +1 -1
  89. package/package.json +5 -1
  90. package/types/cmat-components-loading-overlay.d.ts +11 -0
  91. package/types/cmat-components-navigation.d.ts +36 -0
  92. package/types/cmat-services-alert.d.ts +11 -0
  93. package/types/cmat.d.ts +48 -1
@@ -441,10 +441,10 @@ class CmatOtpInputComponent {
441
441
  });
442
442
  });
443
443
  }
444
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatOtpInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
445
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.3", type: CmatOtpInputComponent, isStandalone: true, selector: "cmat-otp-input", inputs: { config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: false, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: false, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: false, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: false, isRequired: false, transformFunction: null } }, outputs: { onBlur: "onBlur", onInputChange: "onInputChange" }, host: { properties: { "attr.id": "id" } }, providers: [{ provide: MatFormFieldControl, useExisting: CmatOtpInputComponent }], exportAs: ["cmatOtpInput"], ngImport: i0, template: "@if(otpForm.controls){\r\n<div class=\"cmat-otp-input-wrapper wrapper {{config().containerClass}}\" id=\"c_{{componentKey}}\"\r\n [attr.tabindex]=\"disabled ? -1 : 0\" [ngStyle]=\"config().containerStyles\" (focusin)=\"onFocusIn()\" (focusout)=\"onFocusOut()\">\r\n <div class=\"n-o-c\">\r\n @for (item of controlKeys(); track item) {\r\n <input #inp class=\"cmat-otp-input {{config().inputClass}}\" autocomplete=\"one-time-code\" [pattern]=\"config().allowNumbersOnly ? '\\\\d*' : ''\"\r\n [type]=\"inputType()\" [placeholder]=\"config().placeholder || ''\"\r\n [ngStyle]=\"config().inputStyles\" [id]=\"getBoxId($index)\"\r\n [ngClass]=\"{'error-input': (config().showError && errorState)}\"\r\n [formControl]=\"getFormControl(item)\" (paste)=\"handlePaste($event)\" (keyup)=\"onKeyUp($event,$index)\"\r\n (input)=\"onInput($event,$index)\" (keydown)=\"onKeyDown($event,$index)\">\r\n @if(config().separator && !$last){\r\n {{config().separator}}\r\n }\r\n }\r\n </div>\r\n</div>\r\n}", styles: [".cmat-otp-input{width:50px;height:50px;border-radius:4px;border:solid 1px;border-color:rgba(var(--cmat-text-hint-rgb),.5);text-align:center;font-size:32px}.cmat-otp-input:focus{background-color:var(--cmat-divider);border:solid 2px var(--cmat-primary)}.cmat-otp-input-wrapper .cmat-otp-input{margin:0 .51rem}.cmat-otp-input-wrapper .cmat-otp-input:first-child{margin-left:0}.cmat-otp-input-wrapper .cmat-otp-input:last-child{margin-right:0}.n-o-c{display:flex;align-items:center}.error-input{border-color:var(--cmat-warn)}@media screen and (max-width:767px){.cmat-otp-input{width:40px;font-size:24px;height:40px}}@media screen and (max-width:420px){.cmat-otp-input{width:30px;font-size:18px;height:30px}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
444
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatOtpInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
445
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: CmatOtpInputComponent, isStandalone: true, selector: "cmat-otp-input", inputs: { config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: false, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: false, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: false, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: false, isRequired: false, transformFunction: null } }, outputs: { onBlur: "onBlur", onInputChange: "onInputChange" }, host: { properties: { "attr.id": "id" } }, providers: [{ provide: MatFormFieldControl, useExisting: CmatOtpInputComponent }], exportAs: ["cmatOtpInput"], ngImport: i0, template: "@if(otpForm.controls){\r\n<div class=\"cmat-otp-input-wrapper wrapper {{config().containerClass}}\" id=\"c_{{componentKey}}\"\r\n [attr.tabindex]=\"disabled ? -1 : 0\" [ngStyle]=\"config().containerStyles\" (focusin)=\"onFocusIn()\" (focusout)=\"onFocusOut()\">\r\n <div class=\"n-o-c\">\r\n @for (item of controlKeys(); track item) {\r\n <input #inp class=\"cmat-otp-input {{config().inputClass}}\" autocomplete=\"one-time-code\" [pattern]=\"config().allowNumbersOnly ? '\\\\d*' : ''\"\r\n [type]=\"inputType()\" [placeholder]=\"config().placeholder || ''\"\r\n [ngStyle]=\"config().inputStyles\" [id]=\"getBoxId($index)\"\r\n [ngClass]=\"{'error-input': (config().showError && errorState)}\"\r\n [formControl]=\"getFormControl(item)\" (paste)=\"handlePaste($event)\" (keyup)=\"onKeyUp($event,$index)\"\r\n (input)=\"onInput($event,$index)\" (keydown)=\"onKeyDown($event,$index)\">\r\n @if(config().separator && !$last){\r\n {{config().separator}}\r\n }\r\n }\r\n </div>\r\n</div>\r\n}", styles: [".cmat-otp-input{width:50px;height:50px;border-radius:4px;border:solid 1px;border-color:rgba(var(--cmat-text-hint-rgb),.5);text-align:center;font-size:32px}.cmat-otp-input:focus{background-color:var(--cmat-divider);border:solid 2px var(--cmat-primary)}.cmat-otp-input-wrapper .cmat-otp-input{margin:0 .51rem}.cmat-otp-input-wrapper .cmat-otp-input:first-child{margin-left:0}.cmat-otp-input-wrapper .cmat-otp-input:last-child{margin-right:0}.n-o-c{display:flex;align-items:center}.error-input{border-color:var(--cmat-warn)}@media screen and (max-width:767px){.cmat-otp-input{width:40px;font-size:24px;height:40px}}@media screen and (max-width:420px){.cmat-otp-input{width:30px;font-size:18px;height:30px}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
446
446
  }
447
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatOtpInputComponent, decorators: [{
447
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatOtpInputComponent, decorators: [{
448
448
  type: Component,
449
449
  args: [{ selector: 'cmat-otp-input', exportAs: 'cmatOtpInput', imports: [CommonModule, ReactiveFormsModule], providers: [{ provide: MatFormFieldControl, useExisting: CmatOtpInputComponent }], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: {
450
450
  // eslint-disable-next-line @typescript-eslint/naming-convention
@@ -35,10 +35,10 @@ class CmatChartNodeComponent {
35
35
  }, /* @ts-ignore */
36
36
  ...(ngDevMode ? [{ debugName: "connectorToParentHeight" }] : /* istanbul ignore next */ []));
37
37
  }
38
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatChartNodeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
39
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.3", type: CmatChartNodeComponent, isStandalone: true, selector: "cmat-org-chart-node", inputs: { node: { classPropertyName: "node", publicName: "node", isSignal: true, isRequired: true, transformFunction: null }, hasParent: { classPropertyName: "hasParent", publicName: "hasParent", isSignal: true, isRequired: false, transformFunction: null }, enableControlHeight: { classPropertyName: "enableControlHeight", publicName: "enableControlHeight", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, detailsBtnTitle: { classPropertyName: "detailsBtnTitle", publicName: "detailsBtnTitle", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { detailsBtnClick: "detailsBtnClick" }, exportAs: ["cmatOrgChartNode"], ngImport: i0, template: "<!-- eslint-disable @angular-eslint/template/no-inline-styles -->\r\n@if(hasParent()){\r\n<div class=\"cmat-org-border\" [ngClass]=\"containerClass()\" [style.height]=\"connectorToParentHeight()\"></div>\r\n}\r\n<div class=\"cmat-org-box cmat-org-border cmat-org-background\" [ngClass]=\"node().cssClass\">\r\n @if(node().image!==''){\r\n <div class=\"cmat-org-image\" [style]=\"{ 'background-image': 'url(\\'' + node().image + '\\')' }\"\r\n [style.border-color]=\"node().color\"></div>\r\n }@else {\r\n <div class=\"text-center\">\r\n <mat-icon class=\"icon-size-16\" [svgIcon]=\"'heroicons_outline:user-circle'\">\r\n </mat-icon>\r\n </div>\r\n }\r\n\r\n <div class=\"cmat-org-container\">\r\n <div class=\"cmat-org-title\" [innerHTML]=\"node().title\" [style.color]=\"node().color\"></div>\r\n <div class=\"cmat-org-name\" [innerHTML]=\"node().name\"></div>\r\n \r\n @if(node().showDetail){\r\n <div class=\"button-container\">\r\n <button matButton=\"filled\" class=\"cmat-org-btn cmat-org-btn-details\" color=\"primary\"\r\n (click)=\"detailsBtnClick.emit(node())\">\r\n {{ detailsBtnTitle() }}\r\n </button>\r\n </div>\r\n }\r\n </div>\r\n<!-- eslint-enable @angular-eslint/template/no-inline-styles -->\r\n</div>\r\n@if(node().children.length){\r\n<div class=\"cmat-org-border\" [ngClass]=\"containerClass()\"></div>\r\n}", styles: ["cmat-org-chart-node{display:flex;align-items:center}.cmat-org-box{width:16em;height:16em;box-sizing:border-box;overflow:overlay;position:relative}.cmat-org-container{display:flex;flex-direction:column;align-items:center}.cmat-org-title,.cmat-org-name,.button-container{flex:1}.cmat-org-title{margin-top:.5em}.cmat-org-name{margin:.3em 0}.button-container{display:flex;flex-direction:row;justify-content:center;align-items:center;position:absolute;bottom:1em;width:100%}.cmat-org-image{background-repeat:round;width:4em;height:4em;background-color:transparent!important;border-radius:50%;padding:.25em;border:3px solid var(--cmat-text-hint);margin:4px auto auto}.cmat-org-title{font-size:1.1rem;font-weight:700;text-align:center}.cmat-org-name{text-align:center;margin-bottom:8px!important}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
38
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatChartNodeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
39
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: CmatChartNodeComponent, isStandalone: true, selector: "cmat-org-chart-node", inputs: { node: { classPropertyName: "node", publicName: "node", isSignal: true, isRequired: true, transformFunction: null }, hasParent: { classPropertyName: "hasParent", publicName: "hasParent", isSignal: true, isRequired: false, transformFunction: null }, enableControlHeight: { classPropertyName: "enableControlHeight", publicName: "enableControlHeight", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, detailsBtnTitle: { classPropertyName: "detailsBtnTitle", publicName: "detailsBtnTitle", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { detailsBtnClick: "detailsBtnClick" }, exportAs: ["cmatOrgChartNode"], ngImport: i0, template: "<!-- eslint-disable @angular-eslint/template/no-inline-styles -->\r\n@if(hasParent()){\r\n<div class=\"cmat-org-border\" [ngClass]=\"containerClass()\" [style.height]=\"connectorToParentHeight()\"></div>\r\n}\r\n<div class=\"cmat-org-box cmat-org-border cmat-org-background\" [ngClass]=\"node().cssClass\">\r\n @if(node().image!==''){\r\n <div class=\"cmat-org-image\" [style]=\"{ 'background-image': 'url(\\'' + node().image + '\\')' }\"\r\n [style.border-color]=\"node().color\"></div>\r\n }@else {\r\n <div class=\"text-center\">\r\n <mat-icon class=\"icon-size-16\" [svgIcon]=\"'heroicons_outline:user-circle'\">\r\n </mat-icon>\r\n </div>\r\n }\r\n\r\n <div class=\"cmat-org-container\">\r\n <div class=\"cmat-org-title\" [innerHTML]=\"node().title\" [style.color]=\"node().color\"></div>\r\n <div class=\"cmat-org-name\" [innerHTML]=\"node().name\"></div>\r\n \r\n @if(node().showDetail){\r\n <div class=\"button-container\">\r\n <button matButton=\"filled\" class=\"cmat-org-btn cmat-org-btn-details\" color=\"primary\"\r\n (click)=\"detailsBtnClick.emit(node())\">\r\n {{ detailsBtnTitle() }}\r\n </button>\r\n </div>\r\n }\r\n </div>\r\n<!-- eslint-enable @angular-eslint/template/no-inline-styles -->\r\n</div>\r\n@if(node().children.length){\r\n<div class=\"cmat-org-border\" [ngClass]=\"containerClass()\"></div>\r\n}", styles: ["cmat-org-chart-node{display:flex;align-items:center}.cmat-org-box{width:16em;height:16em;box-sizing:border-box;overflow:overlay;position:relative}.cmat-org-container{display:flex;flex-direction:column;align-items:center}.cmat-org-title,.cmat-org-name,.button-container{flex:1}.cmat-org-title{margin-top:.5em}.cmat-org-name{margin:.3em 0}.button-container{display:flex;flex-direction:row;justify-content:center;align-items:center;position:absolute;bottom:1em;width:100%}.cmat-org-image{background-repeat:round;width:4em;height:4em;background-color:transparent!important;border-radius:50%;padding:.25em;border:3px solid var(--cmat-text-hint);margin:4px auto auto}.cmat-org-title{font-size:1.1rem;font-weight:700;text-align:center}.cmat-org-name{text-align:center;margin-bottom:8px!important}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
40
40
  }
41
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatChartNodeComponent, decorators: [{
41
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatChartNodeComponent, decorators: [{
42
42
  type: Component,
43
43
  args: [{ selector: 'cmat-org-chart-node', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, exportAs: 'cmatOrgChartNode', imports: [NgClass, MatIconModule, MatButtonModule], template: "<!-- eslint-disable @angular-eslint/template/no-inline-styles -->\r\n@if(hasParent()){\r\n<div class=\"cmat-org-border\" [ngClass]=\"containerClass()\" [style.height]=\"connectorToParentHeight()\"></div>\r\n}\r\n<div class=\"cmat-org-box cmat-org-border cmat-org-background\" [ngClass]=\"node().cssClass\">\r\n @if(node().image!==''){\r\n <div class=\"cmat-org-image\" [style]=\"{ 'background-image': 'url(\\'' + node().image + '\\')' }\"\r\n [style.border-color]=\"node().color\"></div>\r\n }@else {\r\n <div class=\"text-center\">\r\n <mat-icon class=\"icon-size-16\" [svgIcon]=\"'heroicons_outline:user-circle'\">\r\n </mat-icon>\r\n </div>\r\n }\r\n\r\n <div class=\"cmat-org-container\">\r\n <div class=\"cmat-org-title\" [innerHTML]=\"node().title\" [style.color]=\"node().color\"></div>\r\n <div class=\"cmat-org-name\" [innerHTML]=\"node().name\"></div>\r\n \r\n @if(node().showDetail){\r\n <div class=\"button-container\">\r\n <button matButton=\"filled\" class=\"cmat-org-btn cmat-org-btn-details\" color=\"primary\"\r\n (click)=\"detailsBtnClick.emit(node())\">\r\n {{ detailsBtnTitle() }}\r\n </button>\r\n </div>\r\n }\r\n </div>\r\n<!-- eslint-enable @angular-eslint/template/no-inline-styles -->\r\n</div>\r\n@if(node().children.length){\r\n<div class=\"cmat-org-border\" [ngClass]=\"containerClass()\"></div>\r\n}", styles: ["cmat-org-chart-node{display:flex;align-items:center}.cmat-org-box{width:16em;height:16em;box-sizing:border-box;overflow:overlay;position:relative}.cmat-org-container{display:flex;flex-direction:column;align-items:center}.cmat-org-title,.cmat-org-name,.button-container{flex:1}.cmat-org-title{margin-top:.5em}.cmat-org-name{margin:.3em 0}.button-container{display:flex;flex-direction:row;justify-content:center;align-items:center;position:absolute;bottom:1em;width:100%}.cmat-org-image{background-repeat:round;width:4em;height:4em;background-color:transparent!important;border-radius:50%;padding:.25em;border:3px solid var(--cmat-text-hint);margin:4px auto auto}.cmat-org-title{font-size:1.1rem;font-weight:700;text-align:center}.cmat-org-name{text-align:center;margin-bottom:8px!important}\n"] }]
44
44
  }], propDecorators: { node: [{ type: i0.Input, args: [{ isSignal: true, alias: "node", required: true }] }], hasParent: [{ type: i0.Input, args: [{ isSignal: true, alias: "hasParent", required: false }] }], enableControlHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "enableControlHeight", required: false }] }], direction: [{ type: i0.Input, args: [{ isSignal: true, alias: "direction", required: false }] }], detailsBtnTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "detailsBtnTitle", required: false }] }], detailsBtnClick: [{ type: i0.Output, args: ["detailsBtnClick"] }] } });
@@ -65,10 +65,10 @@ class CmatChartDesignerComponent {
65
65
  get hostWidth() {
66
66
  return this.direction() === 'vertical' ? 'fit-content' : '';
67
67
  }
68
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatChartDesignerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
69
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.3", type: CmatChartDesignerComponent, isStandalone: true, selector: "cmat-org-chart-designer", inputs: { node: { classPropertyName: "node", publicName: "node", isSignal: true, isRequired: true, transformFunction: null }, hasParent: { classPropertyName: "hasParent", publicName: "hasParent", isSignal: true, isRequired: false, transformFunction: null }, enableControlHeight: { classPropertyName: "enableControlHeight", publicName: "enableControlHeight", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, detailsBtnTitle: { classPropertyName: "detailsBtnTitle", publicName: "detailsBtnTitle", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { detailsBtnClick: "detailsBtnClick" }, host: { properties: { "style.flex-direction": "this.hostFlexDirection", "style.width": "this.hostWidth" } }, exportAs: ["cmatOrgChartDesigner"], ngImport: i0, template: "<!-- eslint-disable @angular-eslint/template/no-inline-styles -->\r\n<cmat-org-chart-node [class]=\"chartNodeClass()\" [node]=\"node()\" [hasParent]=\"hasParent()\"\r\n [enableControlHeight]=\"enableControlHeight()\" [direction]=\"direction()\" [detailsBtnTitle]=\"detailsBtnTitle()\"\r\n (detailsBtnClick)=\"detailsBtnClick.emit($event)\">\r\n</cmat-org-chart-node>\r\n\r\n<div class=\"cmat-org-reports-{{ direction() }} cmat-org-reports\">\r\n @for (childNode of node().children; track $index) {\r\n <div class=\"cmat-org-org-container cmat-org-org-container-{{ direction() }}\">\r\n <div class=\"cmat-org-connector-container cmat-org-connector-container-{{ direction() }}\">\r\n <div class=\"cmat-org-connector cmat-org-border\" [style.border-color]=\"$first ? 'transparent' : ''\"></div>\r\n <div class=\"cmat-org-border\"></div>\r\n <div class=\"cmat-org-connector cmat-org-border\" [style.border-color]=\"$last ? 'transparent' : ''\"></div>\r\n </div>\r\n <cmat-org-chart-designer [node]=\"childNode\" [hasParent]=\"true\" [enableControlHeight]=\"enableControlHeight()\"\r\n [direction]=\"direction()\" [detailsBtnTitle]=\"detailsBtnTitle()\" (detailsBtnClick)=\"detailsBtnClick.emit($event)\">\r\n </cmat-org-chart-designer>\r\n </div>\r\n }\r\n<!-- eslint-enable @angular-eslint/template/no-inline-styles -->\r\n</div>", styles: ["cmat-org-chart-designer{display:flex;align-items:center;flex:1}.cmat-org-vertical{flex-direction:column}.cmat-org-org-container{display:flex}.cmat-org-org-container-vertical{flex-direction:column}.cmat-org-connector{flex:1}.cmat-org-connector-container{display:flex}.cmat-org-connector-container-horizontal{flex-direction:column}.cmat-org-reports{display:flex;flex:1}.cmat-org-reports-horizontal{flex-direction:column}.cmat-org-reports-vertical{width:100%}\n"], dependencies: [{ kind: "component", type: i0.forwardRef(() => CmatChartDesignerComponent), selector: "cmat-org-chart-designer", inputs: ["node", "hasParent", "enableControlHeight", "direction", "detailsBtnTitle"], outputs: ["detailsBtnClick"], exportAs: ["cmatOrgChartDesigner"] }, { kind: "component", type: i0.forwardRef(() => CmatChartNodeComponent), selector: "cmat-org-chart-node", inputs: ["node", "hasParent", "enableControlHeight", "direction", "detailsBtnTitle"], outputs: ["detailsBtnClick"], exportAs: ["cmatOrgChartNode"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
68
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatChartDesignerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
69
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: CmatChartDesignerComponent, isStandalone: true, selector: "cmat-org-chart-designer", inputs: { node: { classPropertyName: "node", publicName: "node", isSignal: true, isRequired: true, transformFunction: null }, hasParent: { classPropertyName: "hasParent", publicName: "hasParent", isSignal: true, isRequired: false, transformFunction: null }, enableControlHeight: { classPropertyName: "enableControlHeight", publicName: "enableControlHeight", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, detailsBtnTitle: { classPropertyName: "detailsBtnTitle", publicName: "detailsBtnTitle", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { detailsBtnClick: "detailsBtnClick" }, host: { properties: { "style.flex-direction": "this.hostFlexDirection", "style.width": "this.hostWidth" } }, exportAs: ["cmatOrgChartDesigner"], ngImport: i0, template: "<!-- eslint-disable @angular-eslint/template/no-inline-styles -->\r\n<cmat-org-chart-node [class]=\"chartNodeClass()\" [node]=\"node()\" [hasParent]=\"hasParent()\"\r\n [enableControlHeight]=\"enableControlHeight()\" [direction]=\"direction()\" [detailsBtnTitle]=\"detailsBtnTitle()\"\r\n (detailsBtnClick)=\"detailsBtnClick.emit($event)\">\r\n</cmat-org-chart-node>\r\n\r\n<div class=\"cmat-org-reports-{{ direction() }} cmat-org-reports\">\r\n @for (childNode of node().children; track $index) {\r\n <div class=\"cmat-org-org-container cmat-org-org-container-{{ direction() }}\">\r\n <div class=\"cmat-org-connector-container cmat-org-connector-container-{{ direction() }}\">\r\n <div class=\"cmat-org-connector cmat-org-border\" [style.border-color]=\"$first ? 'transparent' : ''\"></div>\r\n <div class=\"cmat-org-border\"></div>\r\n <div class=\"cmat-org-connector cmat-org-border\" [style.border-color]=\"$last ? 'transparent' : ''\"></div>\r\n </div>\r\n <cmat-org-chart-designer [node]=\"childNode\" [hasParent]=\"true\" [enableControlHeight]=\"enableControlHeight()\"\r\n [direction]=\"direction()\" [detailsBtnTitle]=\"detailsBtnTitle()\" (detailsBtnClick)=\"detailsBtnClick.emit($event)\">\r\n </cmat-org-chart-designer>\r\n </div>\r\n }\r\n<!-- eslint-enable @angular-eslint/template/no-inline-styles -->\r\n</div>", styles: ["cmat-org-chart-designer{display:flex;align-items:center;flex:1}.cmat-org-vertical{flex-direction:column}.cmat-org-org-container{display:flex}.cmat-org-org-container-vertical{flex-direction:column}.cmat-org-connector{flex:1}.cmat-org-connector-container{display:flex}.cmat-org-connector-container-horizontal{flex-direction:column}.cmat-org-reports{display:flex;flex:1}.cmat-org-reports-horizontal{flex-direction:column}.cmat-org-reports-vertical{width:100%}\n"], dependencies: [{ kind: "component", type: i0.forwardRef(() => CmatChartDesignerComponent), selector: "cmat-org-chart-designer", inputs: ["node", "hasParent", "enableControlHeight", "direction", "detailsBtnTitle"], outputs: ["detailsBtnClick"], exportAs: ["cmatOrgChartDesigner"] }, { kind: "component", type: i0.forwardRef(() => CmatChartNodeComponent), selector: "cmat-org-chart-node", inputs: ["node", "hasParent", "enableControlHeight", "direction", "detailsBtnTitle"], outputs: ["detailsBtnClick"], exportAs: ["cmatOrgChartNode"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
70
70
  }
71
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatChartDesignerComponent, decorators: [{
71
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatChartDesignerComponent, decorators: [{
72
72
  type: Component,
73
73
  args: [{ selector: 'cmat-org-chart-designer', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, exportAs: 'cmatOrgChartDesigner', imports: [CmatChartNodeComponent, forwardRef(() => CmatChartDesignerComponent)], template: "<!-- eslint-disable @angular-eslint/template/no-inline-styles -->\r\n<cmat-org-chart-node [class]=\"chartNodeClass()\" [node]=\"node()\" [hasParent]=\"hasParent()\"\r\n [enableControlHeight]=\"enableControlHeight()\" [direction]=\"direction()\" [detailsBtnTitle]=\"detailsBtnTitle()\"\r\n (detailsBtnClick)=\"detailsBtnClick.emit($event)\">\r\n</cmat-org-chart-node>\r\n\r\n<div class=\"cmat-org-reports-{{ direction() }} cmat-org-reports\">\r\n @for (childNode of node().children; track $index) {\r\n <div class=\"cmat-org-org-container cmat-org-org-container-{{ direction() }}\">\r\n <div class=\"cmat-org-connector-container cmat-org-connector-container-{{ direction() }}\">\r\n <div class=\"cmat-org-connector cmat-org-border\" [style.border-color]=\"$first ? 'transparent' : ''\"></div>\r\n <div class=\"cmat-org-border\"></div>\r\n <div class=\"cmat-org-connector cmat-org-border\" [style.border-color]=\"$last ? 'transparent' : ''\"></div>\r\n </div>\r\n <cmat-org-chart-designer [node]=\"childNode\" [hasParent]=\"true\" [enableControlHeight]=\"enableControlHeight()\"\r\n [direction]=\"direction()\" [detailsBtnTitle]=\"detailsBtnTitle()\" (detailsBtnClick)=\"detailsBtnClick.emit($event)\">\r\n </cmat-org-chart-designer>\r\n </div>\r\n }\r\n<!-- eslint-enable @angular-eslint/template/no-inline-styles -->\r\n</div>", styles: ["cmat-org-chart-designer{display:flex;align-items:center;flex:1}.cmat-org-vertical{flex-direction:column}.cmat-org-org-container{display:flex}.cmat-org-org-container-vertical{flex-direction:column}.cmat-org-connector{flex:1}.cmat-org-connector-container{display:flex}.cmat-org-connector-container-horizontal{flex-direction:column}.cmat-org-reports{display:flex;flex:1}.cmat-org-reports-horizontal{flex-direction:column}.cmat-org-reports-vertical{width:100%}\n"] }]
74
74
  }], propDecorators: { node: [{ type: i0.Input, args: [{ isSignal: true, alias: "node", required: true }] }], hasParent: [{ type: i0.Input, args: [{ isSignal: true, alias: "hasParent", required: false }] }], enableControlHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "enableControlHeight", required: false }] }], direction: [{ type: i0.Input, args: [{ isSignal: true, alias: "direction", required: false }] }], detailsBtnTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "detailsBtnTitle", required: false }] }], detailsBtnClick: [{ type: i0.Output, args: ["detailsBtnClick"] }], hostFlexDirection: [{
@@ -91,10 +91,10 @@ class CmatOrgChartComponent {
91
91
  ...(ngDevMode ? [{ debugName: "detailsBtnTitle" }] : /* istanbul ignore next */ []));
92
92
  this.detailsBtnClick = output();
93
93
  }
94
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatOrgChartComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
95
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.3", type: CmatOrgChartComponent, isStandalone: true, selector: "cmat-org-chart", inputs: { nodes: { classPropertyName: "nodes", publicName: "nodes", isSignal: true, isRequired: true, transformFunction: null }, enableControlHeight: { classPropertyName: "enableControlHeight", publicName: "enableControlHeight", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, detailsBtnTitle: { classPropertyName: "detailsBtnTitle", publicName: "detailsBtnTitle", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { detailsBtnClick: "detailsBtnClick" }, exportAs: ["cmatOrgChart"], ngImport: i0, template: "<div class=\"cmat-org\">\r\n @for (node of nodes(); track $index) {\r\n <div class=\"cmat-org-self-{{ direction() }}\">\r\n <cmat-org-chart-designer [node]=\"node\" [direction]=\"direction()\" [enableControlHeight]=\"enableControlHeight()\"\r\n [detailsBtnTitle]=\"detailsBtnTitle()\" (detailsBtnClick)=\"detailsBtnClick.emit($event)\"></cmat-org-chart-designer>\r\n </div>\r\n }\r\n</div>", styles: [".cmat-org-horizontal{padding:1em 0}.cmat-org-vertical{padding:0 1em}.cmat-org-border{border:.1em solid var(--cmat-divider);box-sizing:border-box}.cmat-org-box{padding:.5em 1em;border-radius:.2em;box-shadow:0 2px 8px #00000059}.cmat-org-connector-horizontal{width:1em!important;height:0!important}.cmat-org-connector-vertical{width:0!important;height:1em!important}.cmat-org .cmat-org-self-vertical{margin-bottom:2%}\n"], dependencies: [{ kind: "component", type: CmatChartDesignerComponent, selector: "cmat-org-chart-designer", inputs: ["node", "hasParent", "enableControlHeight", "direction", "detailsBtnTitle"], outputs: ["detailsBtnClick"], exportAs: ["cmatOrgChartDesigner"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
94
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatOrgChartComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
95
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: CmatOrgChartComponent, isStandalone: true, selector: "cmat-org-chart", inputs: { nodes: { classPropertyName: "nodes", publicName: "nodes", isSignal: true, isRequired: true, transformFunction: null }, enableControlHeight: { classPropertyName: "enableControlHeight", publicName: "enableControlHeight", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, detailsBtnTitle: { classPropertyName: "detailsBtnTitle", publicName: "detailsBtnTitle", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { detailsBtnClick: "detailsBtnClick" }, exportAs: ["cmatOrgChart"], ngImport: i0, template: "<div class=\"cmat-org\">\r\n @for (node of nodes(); track $index) {\r\n <div class=\"cmat-org-self-{{ direction() }}\">\r\n <cmat-org-chart-designer [node]=\"node\" [direction]=\"direction()\" [enableControlHeight]=\"enableControlHeight()\"\r\n [detailsBtnTitle]=\"detailsBtnTitle()\" (detailsBtnClick)=\"detailsBtnClick.emit($event)\"></cmat-org-chart-designer>\r\n </div>\r\n }\r\n</div>", styles: [".cmat-org-horizontal{padding:1em 0}.cmat-org-vertical{padding:0 1em}.cmat-org-border{border:.1em solid var(--cmat-divider);box-sizing:border-box}.cmat-org-box{padding:.5em 1em;border-radius:.2em;box-shadow:0 2px 8px #00000059}.cmat-org-connector-horizontal{width:1em!important;height:0!important}.cmat-org-connector-vertical{width:0!important;height:1em!important}.cmat-org .cmat-org-self-vertical{margin-bottom:2%}\n"], dependencies: [{ kind: "component", type: CmatChartDesignerComponent, selector: "cmat-org-chart-designer", inputs: ["node", "hasParent", "enableControlHeight", "direction", "detailsBtnTitle"], outputs: ["detailsBtnClick"], exportAs: ["cmatOrgChartDesigner"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
96
96
  }
97
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatOrgChartComponent, decorators: [{
97
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatOrgChartComponent, decorators: [{
98
98
  type: Component,
99
99
  args: [{ selector: 'cmat-org-chart', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, exportAs: 'cmatOrgChart', imports: [CmatChartDesignerComponent], template: "<div class=\"cmat-org\">\r\n @for (node of nodes(); track $index) {\r\n <div class=\"cmat-org-self-{{ direction() }}\">\r\n <cmat-org-chart-designer [node]=\"node\" [direction]=\"direction()\" [enableControlHeight]=\"enableControlHeight()\"\r\n [detailsBtnTitle]=\"detailsBtnTitle()\" (detailsBtnClick)=\"detailsBtnClick.emit($event)\"></cmat-org-chart-designer>\r\n </div>\r\n }\r\n</div>", styles: [".cmat-org-horizontal{padding:1em 0}.cmat-org-vertical{padding:0 1em}.cmat-org-border{border:.1em solid var(--cmat-divider);box-sizing:border-box}.cmat-org-box{padding:.5em 1em;border-radius:.2em;box-shadow:0 2px 8px #00000059}.cmat-org-connector-horizontal{width:1em!important;height:0!important}.cmat-org-connector-vertical{width:0!important;height:1em!important}.cmat-org .cmat-org-self-vertical{margin-bottom:2%}\n"] }]
100
100
  }], propDecorators: { nodes: [{ type: i0.Input, args: [{ isSignal: true, alias: "nodes", required: true }] }], enableControlHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "enableControlHeight", required: false }] }], direction: [{ type: i0.Input, args: [{ isSignal: true, alias: "direction", required: false }] }], detailsBtnTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "detailsBtnTitle", required: false }] }], detailsBtnClick: [{ type: i0.Output, args: ["detailsBtnClick"] }] } });
@@ -17,10 +17,10 @@ class CmatPageHeaderComponent {
17
17
  this.isCentered = computed(() => this.align() === 'center', /* @ts-ignore */
18
18
  ...(ngDevMode ? [{ debugName: "isCentered" }] : /* istanbul ignore next */ []));
19
19
  }
20
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPageHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
21
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.3", type: CmatPageHeaderComponent, isStandalone: true, selector: "cmat-page-header", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, eyebrow: { classPropertyName: "eyebrow", publicName: "eyebrow", isSignal: true, isRequired: false, transformFunction: null }, divider: { classPropertyName: "divider", publicName: "divider", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<section\r\n class=\"border-b border-default pb-4\"\r\n [ngClass]=\"isCentered() ? 'flex flex-col items-center gap-4 text-center' : 'flex flex-col gap-4 md:flex-row md:items-end md:justify-between'\"\r\n>\r\n <div class=\"min-w-0\">\r\n @if (eyebrow()) {\r\n <p class=\"text-xs font-semibold uppercase tracking-[0.2em] text-primary\">{{ eyebrow() }}</p>\r\n }\r\n\r\n <h1 class=\"mt-1 text-2xl font-semibold text-default\">{{ title() }}</h1>\r\n\r\n @if (description()) {\r\n <p class=\"mt-2 max-w-3xl text-sm leading-6 text-secondary\">{{ description() }}</p>\r\n }\r\n </div>\r\n\r\n <div [ngClass]=\"isCentered() ? 'flex items-center justify-center gap-2' : 'flex items-center gap-2 md:ml-auto'\">\r\n <ng-content select=\"[cmatPageHeaderActions]\"></ng-content>\r\n </div>\r\n</section>\r\n", styles: [":host{display:block}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
20
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPageHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
21
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: CmatPageHeaderComponent, isStandalone: true, selector: "cmat-page-header", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, eyebrow: { classPropertyName: "eyebrow", publicName: "eyebrow", isSignal: true, isRequired: false, transformFunction: null }, divider: { classPropertyName: "divider", publicName: "divider", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<section\r\n class=\"border-b border-default pb-4\"\r\n [ngClass]=\"isCentered() ? 'flex flex-col items-center gap-4 text-center' : 'flex flex-col gap-4 md:flex-row md:items-end md:justify-between'\"\r\n>\r\n <div class=\"min-w-0\">\r\n @if (eyebrow()) {\r\n <p class=\"text-xs font-semibold uppercase tracking-[0.2em] text-primary\">{{ eyebrow() }}</p>\r\n }\r\n\r\n <h1 class=\"mt-1 text-2xl font-semibold text-default\">{{ title() }}</h1>\r\n\r\n @if (description()) {\r\n <p class=\"mt-2 max-w-3xl text-sm leading-6 text-secondary\">{{ description() }}</p>\r\n }\r\n </div>\r\n\r\n <div [ngClass]=\"isCentered() ? 'flex items-center justify-center gap-2' : 'flex items-center gap-2 md:ml-auto'\">\r\n <ng-content select=\"[cmatPageHeaderActions]\"></ng-content>\r\n </div>\r\n</section>\r\n", styles: [":host{display:block}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
22
22
  }
23
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPageHeaderComponent, decorators: [{
23
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPageHeaderComponent, decorators: [{
24
24
  type: Component,
25
25
  args: [{ selector: 'cmat-page-header', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, imports: [NgClass], template: "<section\r\n class=\"border-b border-default pb-4\"\r\n [ngClass]=\"isCentered() ? 'flex flex-col items-center gap-4 text-center' : 'flex flex-col gap-4 md:flex-row md:items-end md:justify-between'\"\r\n>\r\n <div class=\"min-w-0\">\r\n @if (eyebrow()) {\r\n <p class=\"text-xs font-semibold uppercase tracking-[0.2em] text-primary\">{{ eyebrow() }}</p>\r\n }\r\n\r\n <h1 class=\"mt-1 text-2xl font-semibold text-default\">{{ title() }}</h1>\r\n\r\n @if (description()) {\r\n <p class=\"mt-2 max-w-3xl text-sm leading-6 text-secondary\">{{ description() }}</p>\r\n }\r\n </div>\r\n\r\n <div [ngClass]=\"isCentered() ? 'flex items-center justify-center gap-2' : 'flex items-center gap-2 md:ml-auto'\">\r\n <ng-content select=\"[cmatPageHeaderActions]\"></ng-content>\r\n </div>\r\n</section>\r\n", styles: [":host{display:block}\n"] }]
26
26
  }], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }], eyebrow: [{ type: i0.Input, args: [{ isSignal: true, alias: "eyebrow", required: false }] }], divider: [{ type: i0.Input, args: [{ isSignal: true, alias: "divider", required: false }] }], align: [{ type: i0.Input, args: [{ isSignal: true, alias: "align", required: false }] }] } });
@@ -155,10 +155,10 @@ class CmatPaginationService {
155
155
  _clone(obj) {
156
156
  return structuredClone(obj);
157
157
  }
158
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
159
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginationService, providedIn: 'root' }); }
158
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
159
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginationService, providedIn: 'root' }); }
160
160
  }
161
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginationService, decorators: [{
161
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginationService, decorators: [{
162
162
  type: Injectable,
163
163
  args: [{
164
164
  providedIn: 'root'
@@ -351,10 +351,10 @@ class CmatPaginationDirective {
351
351
  return i;
352
352
  }
353
353
  }
354
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginationDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
355
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.1.3", type: CmatPaginationDirective, isStandalone: true, selector: "pagination-template,[pagination-template]", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, maxSize: { classPropertyName: "maxSize", publicName: "maxSize", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { pageChange: "pageChange", pageBoundsCorrection: "pageBoundsCorrection", perPageCountChange: "perPageCountChange" }, exportAs: ["paginationApi"], ngImport: i0 }); }
354
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginationDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
355
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.1.4", type: CmatPaginationDirective, isStandalone: true, selector: "pagination-template,[pagination-template]", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, maxSize: { classPropertyName: "maxSize", publicName: "maxSize", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { pageChange: "pageChange", pageBoundsCorrection: "pageBoundsCorrection", perPageCountChange: "perPageCountChange" }, exportAs: ["paginationApi"], ngImport: i0 }); }
356
356
  }
357
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginationDirective, decorators: [{
357
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginationDirective, decorators: [{
358
358
  type: Directive,
359
359
  args: [{
360
360
  // eslint-disable-next-line @angular-eslint/directive-selector
@@ -420,10 +420,10 @@ class CmatPaginationComponent {
420
420
  });
421
421
  });
422
422
  }
423
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
424
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.3", type: CmatPaginationComponent, isStandalone: true, selector: "cmat-pagination", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, maxSize: { classPropertyName: "maxSize", publicName: "maxSize", isSignal: true, isRequired: false, transformFunction: null }, itemsPerPages: { classPropertyName: "itemsPerPages", publicName: "itemsPerPages", isSignal: true, isRequired: false, transformFunction: null }, initPerPage: { classPropertyName: "initPerPage", publicName: "initPerPage", isSignal: true, isRequired: false, transformFunction: null }, autoHide: { classPropertyName: "autoHide", publicName: "autoHide", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { pageChange: "pageChange", pageBoundsCorrection: "pageBoundsCorrection", perPageCountChange: "perPageCountChange" }, exportAs: ["cmatPagination"], ngImport: i0, template: "<pagination-template #p=\"paginationApi\" class=\"w-full px-4 py-2 flex items-center\" [id]=\"id()\"\r\n [maxSize]=\"isScreenSmall() && maxSize() > 5 ? 5 : maxSize()\" (pageChange)=\"pageChange.emit($event)\"\r\n (pageBoundsCorrection)=\"pageBoundsCorrection.emit($event)\" (perPageCountChange)=\"perPageCountChange.emit($event)\">\r\n @if (!(autoHide() && p.pages().length <= 1)) {\r\n <!-- \u5DE6\uFF1A\u603B\u8BA1 -->\r\n <div class=\"flex-auto\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <span class=\"text-sm text-secondary whitespace-nowrap\">\u5171 {{ p.getTotalItems() }} \u6761</span>\r\n </div>\r\n\r\n <!-- \u53F3\uFF1A\u5BFC\u822A + \u9875\u7801\u8DF3\u8F6C + \u6BCF\u9875\u6761\u6570 -->\r\n <nav role=\"navigation\" class=\"flex\" [ngClass]=\"{'w-full':isScreenSmall()}\">\r\n <ul class=\"flex items-center\"\r\n [ngClass]=\"{'justify-center w-full gap-0':isScreenSmall(),'flex-row gap-0.5':!isScreenSmall()}\">\r\n\r\n <!-- \u9996\u9875 -->\r\n <li [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.goFirstPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:first_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u4E0A\u4E00\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.previous()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-left\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u9875\u7801 -->\r\n @if (isScreenSmall()) {\r\n <li>\r\n <span class=\"px-3 text-sm tabular-nums whitespace-nowrap\">{{ p.getCurrent() }} / {{ p.getLastPage() }}</span>\r\n </li>\r\n } @else {\r\n <li>\r\n <div class=\"flex items-center gap-0.5\">\r\n @for (page of p.pages(); track $index) {\r\n @if (page.label === \"...\") {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary\">...</span>\r\n } @else if (p.getCurrent() === page.value) {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full bg-primary-500 text-white text-sm font-medium\">\r\n {{ page.label | number: \"\" }}\r\n </span>\r\n } @else {\r\n <a tabindex=\"0\" role=\"presentation\"\r\n class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary cursor-pointer hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors\"\r\n (click)=\"p.setCurrent(page.value)\">\r\n {{ page.label | number: \"\" }}\r\n </a>\r\n }\r\n }\r\n </div>\r\n </li>\r\n }\r\n\r\n <!-- \u4E0B\u4E00\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.next()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-right\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u672B\u9875 -->\r\n <li [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.goLastPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:last_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u9875\u7801\u8DF3\u8F6C\uFF08\u684C\u9762\u7AEF\uFF09 -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field appearance=\"outline\" [ngStyle]=\"{\r\n width: (p.getLastPage()?.toString()?.length || 0) * 8 + 64 + 'px',\r\n }\">\r\n <input #current matInput type=\"text\" cmatDigitOnly class=\"text-end\" [value]=\"p.getCurrent()\"\r\n [autocomplete]=\"'off'\" [min]=\"0\" [max]=\"p.getLastPage() || 0\" (keyup.enter)=\"p.setCurrent(current.value)\" />\r\n <span matSuffix>/\r\n <div class=\"px-1\">{{ p.getLastPage() }}</div>\r\n </span>\r\n </mat-form-field>\r\n </li>\r\n\r\n <!-- \u6BCF\u9875\u6761\u6570\uFF08\u684C\u9762\u7AEF\uFF09 -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field class=\"w-20\" appearance=\"outline\">\r\n <mat-select #pageCount [value]=\"initPerPage()\" (selectionChange)=\"p.setItemsPerPage(pageCount.value)\">\r\n @for (perPage of itemsPerPages(); track perPage) {\r\n <mat-option [value]=\"perPage\">{{ perPage }}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n </li>\r\n </ul>\r\n </nav>\r\n }\r\n</pagination-template>\r\n", dependencies: [{ kind: "directive", type: CmatPaginationDirective, selector: "pagination-template,[pagination-template]", inputs: ["id", "maxSize"], outputs: ["pageChange", "pageBoundsCorrection", "perPageCountChange"], exportAs: ["paginationApi"] }, { kind: "directive", type: CmatDigitOnlyDirective, selector: "[cmatDigitOnly]", inputs: ["decimal", "decimalSeparator", "allowNegatives", "allowPaste", "negativeSign", "min", "max", "pattern"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i2.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i2.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "ngmodule", type: MatSelectModule }, { kind: "component", type: i4.MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: i4.MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i5.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "pipe", type: DecimalPipe, name: "number" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
423
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
424
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: CmatPaginationComponent, isStandalone: true, selector: "cmat-pagination", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, maxSize: { classPropertyName: "maxSize", publicName: "maxSize", isSignal: true, isRequired: false, transformFunction: null }, itemsPerPages: { classPropertyName: "itemsPerPages", publicName: "itemsPerPages", isSignal: true, isRequired: false, transformFunction: null }, initPerPage: { classPropertyName: "initPerPage", publicName: "initPerPage", isSignal: true, isRequired: false, transformFunction: null }, autoHide: { classPropertyName: "autoHide", publicName: "autoHide", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { pageChange: "pageChange", pageBoundsCorrection: "pageBoundsCorrection", perPageCountChange: "perPageCountChange" }, exportAs: ["cmatPagination"], ngImport: i0, template: "<pagination-template #p=\"paginationApi\" class=\"w-full px-4 py-2 flex items-center\" [id]=\"id()\"\r\n [maxSize]=\"isScreenSmall() && maxSize() > 5 ? 5 : maxSize()\"\r\n (pageChange)=\"pageChange.emit($event)\"\r\n (pageBoundsCorrection)=\"pageBoundsCorrection.emit($event)\" (perPageCountChange)=\"perPageCountChange.emit($event)\">\r\n @if (!(autoHide() && p.pages().length <= 1)) {\r\n <!-- \u5DE6\uFF1A\u603B\u8BA1 -->\r\n <div class=\"flex-auto\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <span class=\"text-sm text-secondary whitespace-nowrap\">\u5171 {{ p.getTotalItems() }} \u6761</span>\r\n </div>\r\n\r\n <!-- \u53F3\uFF1A\u5BFC\u822A -->\r\n <nav role=\"navigation\" class=\"flex\" [ngClass]=\"{'w-full':isScreenSmall()}\">\r\n <ul class=\"flex items-center\"\r\n [ngClass]=\"{'justify-center w-full gap-0':isScreenSmall(),'flex-row gap-0.5':!isScreenSmall()}\">\r\n\r\n <!-- \u9996\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.goFirstPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:first_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u4E0A\u4E00\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.previous()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-left\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u9875\u7801 -->\r\n <li class=\"mx-1\">\r\n <div class=\"flex items-center gap-0.5\">\r\n @for (page of p.pages(); track $index) {\r\n @if (page.label === \"...\") {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary\">...</span>\r\n } @else if (p.getCurrent() === page.value) {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full bg-primary-500 text-white text-sm font-medium\">\r\n {{ page.label | number: \"\" }}\r\n </span>\r\n } @else {\r\n <a tabindex=\"0\" role=\"presentation\"\r\n class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary cursor-pointer hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors\"\r\n (click)=\"p.setCurrent(page.value)\">\r\n {{ page.label | number: \"\" }}\r\n </a>\r\n }\r\n }\r\n </div>\r\n </li>\r\n\r\n <!-- \u4E0B\u4E00\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.next()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-right\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u672B\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.goLastPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:last_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u9875\u7801\u8DF3\u8F6C\uFF08\u684C\u9762\u7AEF\uFF09 -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field appearance=\"outline\" [ngStyle]=\"{\r\n width: (p.getLastPage()?.toString()?.length || 0) * 8 + 64 + 'px',\r\n }\">\r\n <input #current matInput type=\"text\" cmatDigitOnly class=\"text-end\" [value]=\"p.getCurrent()\"\r\n [autocomplete]=\"'off'\" [min]=\"0\" [max]=\"p.getLastPage() || 0\" (keyup.enter)=\"p.setCurrent(current.value)\" />\r\n <span matSuffix>/\r\n <div class=\"px-2\">{{ p.getLastPage() }}</div>\r\n </span>\r\n </mat-form-field>\r\n </li>\r\n\r\n <!-- \u6BCF\u9875\u6761\u6570\uFF08\u684C\u9762\u7AEF\uFF09 -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field class=\"w-20\" appearance=\"outline\">\r\n <mat-select #pageCount [value]=\"initPerPage()\" (selectionChange)=\"p.setItemsPerPage(pageCount.value)\">\r\n @for (perPage of itemsPerPages(); track perPage) {\r\n <mat-option [value]=\"perPage\">{{ perPage }}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n </li>\r\n </ul>\r\n </nav>\r\n }\r\n</pagination-template>\r\n\r\n<style>\r\n @media (hover: none) and (pointer: coarse) {\r\n cmat-pagination button[matIconButton] {\r\n transition: transform 150ms ease;\r\n }\r\n cmat-pagination button[matIconButton]:active:not([disabled]) {\r\n transform: scale(0.88);\r\n }\r\n }\r\n</style>\r\n", styles: ["@media(hover:none)and (pointer:coarse){cmat-pagination button[matIconButton]{transition:transform .15s ease}cmat-pagination button[matIconButton]:active:not([disabled]){transform:scale(.88)}}\n"], dependencies: [{ kind: "directive", type: CmatPaginationDirective, selector: "pagination-template,[pagination-template]", inputs: ["id", "maxSize"], outputs: ["pageChange", "pageBoundsCorrection", "perPageCountChange"], exportAs: ["paginationApi"] }, { kind: "directive", type: CmatDigitOnlyDirective, selector: "[cmatDigitOnly]", inputs: ["decimal", "decimalSeparator", "allowNegatives", "allowPaste", "negativeSign", "min", "max", "pattern"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i2.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i2.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "ngmodule", type: MatSelectModule }, { kind: "component", type: i4.MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: i4.MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i5.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "pipe", type: DecimalPipe, name: "number" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
425
425
  }
426
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginationComponent, decorators: [{
426
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginationComponent, decorators: [{
427
427
  type: Component,
428
428
  args: [{ selector: 'cmat-pagination', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, exportAs: 'cmatPagination', imports: [
429
429
  CmatPaginationDirective,
@@ -436,7 +436,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImpor
436
436
  MatButtonModule,
437
437
  NgClass,
438
438
  NgStyle,
439
- ], template: "<pagination-template #p=\"paginationApi\" class=\"w-full px-4 py-2 flex items-center\" [id]=\"id()\"\r\n [maxSize]=\"isScreenSmall() && maxSize() > 5 ? 5 : maxSize()\" (pageChange)=\"pageChange.emit($event)\"\r\n (pageBoundsCorrection)=\"pageBoundsCorrection.emit($event)\" (perPageCountChange)=\"perPageCountChange.emit($event)\">\r\n @if (!(autoHide() && p.pages().length <= 1)) {\r\n <!-- \u5DE6\uFF1A\u603B\u8BA1 -->\r\n <div class=\"flex-auto\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <span class=\"text-sm text-secondary whitespace-nowrap\">\u5171 {{ p.getTotalItems() }} \u6761</span>\r\n </div>\r\n\r\n <!-- \u53F3\uFF1A\u5BFC\u822A + \u9875\u7801\u8DF3\u8F6C + \u6BCF\u9875\u6761\u6570 -->\r\n <nav role=\"navigation\" class=\"flex\" [ngClass]=\"{'w-full':isScreenSmall()}\">\r\n <ul class=\"flex items-center\"\r\n [ngClass]=\"{'justify-center w-full gap-0':isScreenSmall(),'flex-row gap-0.5':!isScreenSmall()}\">\r\n\r\n <!-- \u9996\u9875 -->\r\n <li [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.goFirstPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:first_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u4E0A\u4E00\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.previous()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-left\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u9875\u7801 -->\r\n @if (isScreenSmall()) {\r\n <li>\r\n <span class=\"px-3 text-sm tabular-nums whitespace-nowrap\">{{ p.getCurrent() }} / {{ p.getLastPage() }}</span>\r\n </li>\r\n } @else {\r\n <li>\r\n <div class=\"flex items-center gap-0.5\">\r\n @for (page of p.pages(); track $index) {\r\n @if (page.label === \"...\") {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary\">...</span>\r\n } @else if (p.getCurrent() === page.value) {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full bg-primary-500 text-white text-sm font-medium\">\r\n {{ page.label | number: \"\" }}\r\n </span>\r\n } @else {\r\n <a tabindex=\"0\" role=\"presentation\"\r\n class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary cursor-pointer hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors\"\r\n (click)=\"p.setCurrent(page.value)\">\r\n {{ page.label | number: \"\" }}\r\n </a>\r\n }\r\n }\r\n </div>\r\n </li>\r\n }\r\n\r\n <!-- \u4E0B\u4E00\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.next()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-right\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u672B\u9875 -->\r\n <li [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.goLastPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:last_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u9875\u7801\u8DF3\u8F6C\uFF08\u684C\u9762\u7AEF\uFF09 -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field appearance=\"outline\" [ngStyle]=\"{\r\n width: (p.getLastPage()?.toString()?.length || 0) * 8 + 64 + 'px',\r\n }\">\r\n <input #current matInput type=\"text\" cmatDigitOnly class=\"text-end\" [value]=\"p.getCurrent()\"\r\n [autocomplete]=\"'off'\" [min]=\"0\" [max]=\"p.getLastPage() || 0\" (keyup.enter)=\"p.setCurrent(current.value)\" />\r\n <span matSuffix>/\r\n <div class=\"px-1\">{{ p.getLastPage() }}</div>\r\n </span>\r\n </mat-form-field>\r\n </li>\r\n\r\n <!-- \u6BCF\u9875\u6761\u6570\uFF08\u684C\u9762\u7AEF\uFF09 -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field class=\"w-20\" appearance=\"outline\">\r\n <mat-select #pageCount [value]=\"initPerPage()\" (selectionChange)=\"p.setItemsPerPage(pageCount.value)\">\r\n @for (perPage of itemsPerPages(); track perPage) {\r\n <mat-option [value]=\"perPage\">{{ perPage }}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n </li>\r\n </ul>\r\n </nav>\r\n }\r\n</pagination-template>\r\n" }]
439
+ ], template: "<pagination-template #p=\"paginationApi\" class=\"w-full px-4 py-2 flex items-center\" [id]=\"id()\"\r\n [maxSize]=\"isScreenSmall() && maxSize() > 5 ? 5 : maxSize()\"\r\n (pageChange)=\"pageChange.emit($event)\"\r\n (pageBoundsCorrection)=\"pageBoundsCorrection.emit($event)\" (perPageCountChange)=\"perPageCountChange.emit($event)\">\r\n @if (!(autoHide() && p.pages().length <= 1)) {\r\n <!-- \u5DE6\uFF1A\u603B\u8BA1 -->\r\n <div class=\"flex-auto\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <span class=\"text-sm text-secondary whitespace-nowrap\">\u5171 {{ p.getTotalItems() }} \u6761</span>\r\n </div>\r\n\r\n <!-- \u53F3\uFF1A\u5BFC\u822A -->\r\n <nav role=\"navigation\" class=\"flex\" [ngClass]=\"{'w-full':isScreenSmall()}\">\r\n <ul class=\"flex items-center\"\r\n [ngClass]=\"{'justify-center w-full gap-0':isScreenSmall(),'flex-row gap-0.5':!isScreenSmall()}\">\r\n\r\n <!-- \u9996\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.goFirstPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:first_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u4E0A\u4E00\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.previous()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-left\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u9875\u7801 -->\r\n <li class=\"mx-1\">\r\n <div class=\"flex items-center gap-0.5\">\r\n @for (page of p.pages(); track $index) {\r\n @if (page.label === \"...\") {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary\">...</span>\r\n } @else if (p.getCurrent() === page.value) {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full bg-primary-500 text-white text-sm font-medium\">\r\n {{ page.label | number: \"\" }}\r\n </span>\r\n } @else {\r\n <a tabindex=\"0\" role=\"presentation\"\r\n class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary cursor-pointer hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors\"\r\n (click)=\"p.setCurrent(page.value)\">\r\n {{ page.label | number: \"\" }}\r\n </a>\r\n }\r\n }\r\n </div>\r\n </li>\r\n\r\n <!-- \u4E0B\u4E00\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.next()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-right\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u672B\u9875 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.goLastPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:last_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- \u9875\u7801\u8DF3\u8F6C\uFF08\u684C\u9762\u7AEF\uFF09 -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field appearance=\"outline\" [ngStyle]=\"{\r\n width: (p.getLastPage()?.toString()?.length || 0) * 8 + 64 + 'px',\r\n }\">\r\n <input #current matInput type=\"text\" cmatDigitOnly class=\"text-end\" [value]=\"p.getCurrent()\"\r\n [autocomplete]=\"'off'\" [min]=\"0\" [max]=\"p.getLastPage() || 0\" (keyup.enter)=\"p.setCurrent(current.value)\" />\r\n <span matSuffix>/\r\n <div class=\"px-2\">{{ p.getLastPage() }}</div>\r\n </span>\r\n </mat-form-field>\r\n </li>\r\n\r\n <!-- \u6BCF\u9875\u6761\u6570\uFF08\u684C\u9762\u7AEF\uFF09 -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field class=\"w-20\" appearance=\"outline\">\r\n <mat-select #pageCount [value]=\"initPerPage()\" (selectionChange)=\"p.setItemsPerPage(pageCount.value)\">\r\n @for (perPage of itemsPerPages(); track perPage) {\r\n <mat-option [value]=\"perPage\">{{ perPage }}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n </li>\r\n </ul>\r\n </nav>\r\n }\r\n</pagination-template>\r\n\r\n<style>\r\n @media (hover: none) and (pointer: coarse) {\r\n cmat-pagination button[matIconButton] {\r\n transition: transform 150ms ease;\r\n }\r\n cmat-pagination button[matIconButton]:active:not([disabled]) {\r\n transform: scale(0.88);\r\n }\r\n }\r\n</style>\r\n" }]
440
440
  }], ctorParameters: () => [], propDecorators: { id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], maxSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxSize", required: false }] }], itemsPerPages: [{ type: i0.Input, args: [{ isSignal: true, alias: "itemsPerPages", required: false }] }], initPerPage: [{ type: i0.Input, args: [{ isSignal: true, alias: "initPerPage", required: false }] }], autoHide: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoHide", required: false }] }], pageChange: [{ type: i0.Output, args: ["pageChange"] }], pageBoundsCorrection: [{ type: i0.Output, args: ["pageBoundsCorrection"] }], perPageCountChange: [{ type: i0.Output, args: ["perPageCountChange"] }] } });
441
441
 
442
442
  const LARGE_NUMBER = Number.MAX_SAFE_INTEGER;
@@ -517,10 +517,10 @@ class CmatPaginatePipe {
517
517
  _toNumber(value) {
518
518
  return Number(value);
519
519
  }
520
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginatePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
521
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginatePipe, isStandalone: true, name: "paginate" }); }
520
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginatePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
521
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginatePipe, isStandalone: true, name: "paginate" }); }
522
522
  }
523
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: CmatPaginatePipe, decorators: [{
523
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: CmatPaginatePipe, decorators: [{
524
524
  type: Pipe,
525
525
  args: [{
526
526
  name: 'paginate',
@@ -1 +1 @@
1
- {"version":3,"file":"cmat-components-pagination.mjs","sources":["../../../projects/cmat/components/pagination/pagination.service.ts","../../../projects/cmat/components/pagination/pagination.directive.ts","../../../projects/cmat/components/pagination/pagination.component.ts","../../../projects/cmat/components/pagination/pagination.component.html","../../../projects/cmat/components/pagination/pagination.pipe.ts","../../../projects/cmat/components/pagination/cmat-components-pagination.ts"],"sourcesContent":["import { Injectable, signal, untracked } from '@angular/core';\r\nimport { CmatPaginationInstance } from './pagination.instance';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CmatPaginationService {\r\n private readonly _instances = signal<Record<string, CmatPaginationInstance>>({});\r\n\r\n // eslint-disable-next-line @typescript-eslint/member-ordering\r\n readonly instances = this._instances.asReadonly();\r\n\r\n private readonly _defaultPaginationId = 'DEFAULT_PAGINATION_ID';\r\n\r\n public defaultId(): string { return this._defaultPaginationId; }\r\n\r\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\r\n public notifyChange(_id: string): void {\r\n // 使用 requestAnimationFrame 延迟 Signal 更新,避免在模板渲染周期中写入\r\n requestAnimationFrame(() => {\r\n this._instances.update(current => ({ ...current }));\r\n });\r\n }\r\n\r\n public register(instance: CmatPaginationInstance, fromPipe: boolean = false): boolean {\r\n const normalizedInstance: CmatPaginationInstance = {\r\n ...structuredClone(instance),\r\n id: instance.id ?? this._defaultPaginationId\r\n };\r\n const id = normalizedInstance.id!;\r\n\r\n let changed = false;\r\n const currentInstances = untracked(() => this._instances());\r\n\r\n if (!currentInstances[id]) {\r\n changed = true;\r\n } else {\r\n const needsUpdate = this._needsUpdate(currentInstances[id], normalizedInstance);\r\n if (needsUpdate) {\r\n changed = true;\r\n }\r\n }\r\n\r\n if (changed) {\r\n if (fromPipe) {\r\n requestAnimationFrame(() => {\r\n this._instances.update((current) => {\r\n if (!current[id]) {\r\n return { ...current, [id]: normalizedInstance };\r\n } else {\r\n this._updateInstance(current[id], normalizedInstance);\r\n return { ...current };\r\n }\r\n });\r\n });\r\n }\r\n else {\r\n this._instances.update((current) => {\r\n if (!current[id]) {\r\n return { ...current, [id]: normalizedInstance };\r\n } else {\r\n this._updateInstance(current[id], normalizedInstance);\r\n return { ...current };\r\n }\r\n });\r\n }\r\n }\r\n\r\n return changed;\r\n }\r\n\r\n public getCurrentPage(id: string): number | undefined {\r\n return this._instances()[id]?.currentPage;\r\n }\r\n\r\n public getItemsPerPage(id: string): number | undefined {\r\n return this._instances()[id]?.itemsPerPage;\r\n }\r\n\r\n public setCurrentPage(id: string, page: number): void {\r\n this._instances.update((current) => {\r\n const instance = current[id];\r\n if (instance) {\r\n const maxPage = Math.ceil(instance.totalItems / instance.itemsPerPage);\r\n if (page <= maxPage && 1 <= page) {\r\n // 创建新引用以确保 Signal 检测到变化\r\n current[id] = { ...instance, currentPage: page };\r\n return { ...current };\r\n }\r\n }\r\n return current;\r\n });\r\n\r\n // 通知分页器更新显示\r\n this.notifyChange(id);\r\n }\r\n\r\n public setTotalItems(id: string, totalItems: number): void {\r\n this._instances.update((current) => {\r\n const instance = current[id];\r\n if (instance && 0 <= totalItems) {\r\n current[id] = { ...instance, totalItems };\r\n return { ...current };\r\n }\r\n return current;\r\n });\r\n\r\n // 通知分页器更新显示\r\n this.notifyChange(id);\r\n }\r\n\r\n public setItemsPerPage(id: string, itemsPerPage: number): void {\r\n this._instances.update((current) => {\r\n const instance = current[id];\r\n if (instance) {\r\n current[id] = { ...instance, itemsPerPage };\r\n return { ...current };\r\n }\r\n return current;\r\n });\r\n\r\n // 通知分页器更新显示\r\n this.notifyChange(id);\r\n }\r\n\r\n public getInstance(id: string = this._defaultPaginationId): CmatPaginationInstance | undefined {\r\n const instance = this._instances()[id];\r\n if (instance) {\r\n return this._clone(instance);\r\n }\r\n\r\n return undefined;\r\n }\r\n\r\n private _updateInstance(current: CmatPaginationInstance, incoming: CmatPaginationInstance): boolean {\r\n let changed = false;\r\n if (incoming.id) {\r\n const keys = new Set([...Object.keys(current), ...Object.keys(incoming)]);\r\n\r\n for (const prop of keys) {\r\n const key = prop as keyof CmatPaginationInstance;\r\n\r\n if (incoming[key] !== current[key]) {\r\n current[key] = incoming[key];\r\n changed = true;\r\n }\r\n }\r\n }\r\n return changed;\r\n }\r\n\r\n private _needsUpdate(current: CmatPaginationInstance, incoming: CmatPaginationInstance): boolean {\r\n // 检查是否有任何属性发生变化\r\n const keys = new Set([...Object.keys(current), ...Object.keys(incoming)]);\r\n for (const prop of keys) {\r\n const key = prop as keyof CmatPaginationInstance;\r\n if (incoming[key] !== current[key]) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n }\r\n\r\n private _clone<T extends Record<string, unknown>>(obj: T): T {\r\n return structuredClone(obj);\r\n }\r\n}\r\n","import {\r\n afterNextRender,\r\n Directive,\r\n inject,\r\n Injector,\r\n signal,\r\n input,\r\n output,\r\n effect,\r\n untracked,\r\n} from '@angular/core';\r\nimport { CmatPaginationInstance } from './pagination.instance';\r\nimport { CmatPaginationService } from './pagination.service';\r\n\r\nexport interface Page {\r\n label: string | number;\r\n value: number;\r\n}\r\n@Directive({\r\n // eslint-disable-next-line @angular-eslint/directive-selector\r\n selector: 'pagination-template,[pagination-template]',\r\n exportAs: 'paginationApi',\r\n})\r\nexport class CmatPaginationDirective {\r\n readonly id = input<string>();\r\n readonly maxSize = input<number>(7);\r\n\r\n readonly pageChange = output<number>();\r\n readonly pageBoundsCorrection = output<number>();\r\n readonly perPageCountChange = output<number>();\r\n\r\n readonly pages = signal<Page[]>([]);\r\n\r\n private readonly service = inject(CmatPaginationService);\r\n private readonly _injector = inject(Injector);\r\n private _pageLinksUpdateQueued = false;\r\n\r\n constructor() {\r\n effect(() => {\r\n const instances = this.service.instances();\r\n\r\n if (this._getId() === instances[this._getId()]?.id) {\r\n untracked(() => {\r\n this._schedulePageLinksUpdate();\r\n });\r\n }\r\n });\r\n\r\n this._schedulePageLinksUpdate();\r\n }\r\n\r\n previous(): void {\r\n if (!this.isFirstPage()) {\r\n this._checkValidId();\r\n\r\n const current = this.getCurrent();\r\n if (current) this.setCurrent(current - 1);\r\n }\r\n }\r\n\r\n next(): void {\r\n if (!this.isLastPage()) {\r\n this._checkValidId();\r\n\r\n const current = this.getCurrent();\r\n if (current) this.setCurrent(current + 1);\r\n }\r\n }\r\n\r\n goFirstPage(): void {\r\n if (!this.isFirstPage()) {\r\n this._checkValidId();\r\n\r\n this.setCurrent(1);\r\n }\r\n }\r\n\r\n goLastPage(): void {\r\n if (!this.isLastPage()) {\r\n this._checkValidId();\r\n\r\n const lastPage = this.getLastPage();\r\n if (lastPage) this.setCurrent(lastPage);\r\n }\r\n }\r\n\r\n isFirstPage(): boolean {\r\n return this.getCurrent() === 1;\r\n }\r\n\r\n isLastPage(): boolean {\r\n return this.getLastPage() === this.getCurrent();\r\n }\r\n\r\n setCurrent(page: number | string): void {\r\n const nextPage = Number(page);\r\n\r\n if (!Number.isNaN(nextPage)) {\r\n this.pageChange.emit(nextPage);\r\n }\r\n }\r\n\r\n getCurrent(): number | void {\r\n return this.service.getCurrentPage(this._getId());\r\n }\r\n\r\n getLastPage(): number | void {\r\n const inst = this.service.getInstance(this._getId());\r\n if (!inst) {\r\n return;\r\n }\r\n\r\n if (inst.totalItems < 1) {\r\n return 1;\r\n }\r\n return Math.ceil(inst.totalItems / inst.itemsPerPage);\r\n }\r\n\r\n getTotalItems(): number | void {\r\n return this.service.getInstance(this._getId())?.totalItems;\r\n }\r\n\r\n setItemsPerPage(count: number): void {\r\n const id = this._getId();\r\n this.service.setItemsPerPage(id, count);\r\n\r\n this.perPageCountChange.emit(count);\r\n const inst = this.service.getInstance(id);\r\n if (!inst) {\r\n return;\r\n }\r\n\r\n this.setCurrent(this._outOfBoundCorrection(inst));\r\n }\r\n\r\n private _getId(): string {\r\n return this.id() ?? this.service.defaultId();\r\n }\r\n\r\n private _checkValidId(): void {\r\n const id = this._getId();\r\n if (this.service.getInstance(id)?.id == null) {\r\n console.warn(\r\n `PaginationControlsDirective: the specified id \"${id}\" does not match any registered PaginationInstance`,\r\n );\r\n }\r\n }\r\n\r\n private _updatePageLinks(): void {\r\n const inst = this.service.getInstance(this._getId());\r\n if (!inst) {\r\n this.pages.set([]);\r\n return;\r\n }\r\n\r\n const correctedCurrentPage = this._outOfBoundCorrection(inst);\r\n const pageForRender =\r\n correctedCurrentPage !== inst.currentPage\r\n ? correctedCurrentPage\r\n : inst.currentPage;\r\n\r\n this.pageBoundsCorrection.emit(correctedCurrentPage);\r\n this.pages.set(\r\n this._createPageArray(\r\n pageForRender,\r\n inst.itemsPerPage,\r\n inst.totalItems,\r\n this.maxSize(),\r\n ),\r\n );\r\n }\r\n\r\n private _schedulePageLinksUpdate(): void {\r\n if (this._pageLinksUpdateQueued) {\r\n return;\r\n }\r\n\r\n this._pageLinksUpdateQueued = true;\r\n afterNextRender(\r\n () => {\r\n this._pageLinksUpdateQueued = false;\r\n this._updatePageLinks();\r\n },\r\n { injector: this._injector },\r\n );\r\n }\r\n\r\n private _outOfBoundCorrection(instance: CmatPaginationInstance): number {\r\n const totalPages = Math.ceil(instance.totalItems / instance.itemsPerPage);\r\n if (totalPages < instance.currentPage && 0 < totalPages) {\r\n return totalPages;\r\n } else if (instance.currentPage < 1) {\r\n return 1;\r\n }\r\n\r\n return instance.currentPage;\r\n }\r\n\r\n private _createPageArray(\r\n currentPage: number,\r\n itemsPerPage: number,\r\n totalItems: number,\r\n paginationRange: number,\r\n ): Page[] {\r\n paginationRange = +paginationRange;\r\n const pages: Page[] = [];\r\n\r\n const totalPages = Math.max(Math.ceil(totalItems / itemsPerPage), 1);\r\n const halfWay = Math.ceil(paginationRange / 2);\r\n\r\n const isStart = currentPage <= halfWay;\r\n const isEnd = totalPages - halfWay < currentPage;\r\n const isMiddle = !isStart && !isEnd;\r\n\r\n const ellipsesNeeded = paginationRange < totalPages;\r\n let i = 1;\r\n\r\n while (i <= totalPages && i <= paginationRange) {\r\n let label: string | number;\r\n const pageNumber = this._calculatePageNumber(\r\n i,\r\n currentPage,\r\n paginationRange,\r\n totalPages,\r\n );\r\n const openingEllipsesNeeded = i === 2 && (isMiddle || isEnd);\r\n const closingEllipsesNeeded =\r\n i === paginationRange - 1 && (isMiddle || isStart);\r\n if (ellipsesNeeded && (openingEllipsesNeeded || closingEllipsesNeeded)) {\r\n label = '...';\r\n } else {\r\n label = pageNumber;\r\n }\r\n pages.push({\r\n label: label,\r\n value: pageNumber,\r\n });\r\n i++;\r\n }\r\n\r\n return pages;\r\n }\r\n\r\n private _calculatePageNumber(\r\n i: number,\r\n currentPage: number,\r\n paginationRange: number,\r\n totalPages: number,\r\n ): number {\r\n const halfWay = Math.ceil(paginationRange / 2);\r\n if (i === paginationRange) {\r\n return totalPages;\r\n } else if (i === 1) {\r\n return i;\r\n } else if (paginationRange < totalPages) {\r\n if (totalPages - halfWay < currentPage) {\r\n return totalPages - paginationRange + i;\r\n } else if (halfWay < currentPage) {\r\n return currentPage - halfWay + i;\r\n } else {\r\n return i;\r\n }\r\n } else {\r\n return i;\r\n }\r\n }\r\n}\r\n","import { DecimalPipe, NgClass, NgStyle } from '@angular/common';\r\nimport {\r\n ChangeDetectionStrategy,\r\n Component,\r\n ViewEncapsulation,\r\n inject,\r\n input,\r\n output,\r\n computed,\r\n ElementRef,\r\n afterNextRender,\r\n signal,\r\n DestroyRef,\r\n} from '@angular/core';\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { MatFormFieldModule } from '@angular/material/form-field';\r\nimport { MatIconModule } from '@angular/material/icon';\r\nimport { MatInputModule } from '@angular/material/input';\r\nimport { MatSelectModule } from '@angular/material/select';\r\nimport { CmatDigitOnlyDirective } from 'cmat/directives/digit-only';\r\nimport { CmatPaginationDirective } from './pagination.directive';\r\n\r\n@Component({\r\n selector: 'cmat-pagination',\r\n templateUrl: './pagination.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n encapsulation: ViewEncapsulation.None,\r\n exportAs: 'cmatPagination',\r\n imports: [\r\n CmatPaginationDirective,\r\n CmatDigitOnlyDirective,\r\n MatIconModule,\r\n MatFormFieldModule,\r\n MatInputModule,\r\n MatSelectModule,\r\n DecimalPipe,\r\n MatButtonModule,\r\n NgClass,\r\n NgStyle,\r\n ],\r\n})\r\nexport class CmatPaginationComponent {\r\n readonly id = input<string>();\r\n readonly maxSize = input<number>(7);\r\n readonly itemsPerPages = input<number[]>([10, 20, 30]);\r\n readonly initPerPage = input<number>(10);\r\n readonly autoHide = input<boolean>(false);\r\n\r\n readonly pageChange = output<number>();\r\n readonly pageBoundsCorrection = output<number>();\r\n readonly perPageCountChange = output<number>();\r\n\r\n private _elementRef = inject(ElementRef);\r\n private _destroyRef = inject(DestroyRef);\r\n\r\n // 组件宽度信号,初始化为一个合理默认值\r\n private _componentWidth = signal<number>(1024);\r\n \r\n // 根据组件自身宽度判断是否使用移动端样式(阈值:768px)\r\n // eslint-disable-next-line @typescript-eslint/member-ordering\r\n readonly isScreenSmall = computed(() => {\r\n return this._componentWidth() < 768;\r\n });\r\n\r\n constructor() {\r\n // 使用 ResizeObserver 监听组件自身宽度变化\r\n afterNextRender(() => {\r\n const element = this._elementRef.nativeElement as HTMLElement;\r\n \r\n // 确保元素是块级或行内块级,可以正确测量宽度\r\n if (getComputedStyle(element).display === 'inline') {\r\n element.style.display = 'inline-block';\r\n element.style.width = '100%';\r\n }\r\n \r\n // 立即获取一次初始宽度\r\n const initialWidth = element.getBoundingClientRect().width;\r\n if (initialWidth > 0) {\r\n this._componentWidth.set(initialWidth);\r\n }\r\n \r\n // 创建 ResizeObserver\r\n const resizeObserver = new ResizeObserver((entries) => {\r\n for (const entry of entries) {\r\n const width = entry.contentRect.width;\r\n // 只有当宽度大于0时才更新,避免无效值\r\n if (width > 0) {\r\n this._componentWidth.set(width);\r\n }\r\n }\r\n });\r\n \r\n // 开始观察\r\n resizeObserver.observe(element);\r\n \r\n // 组件销毁时清理观察者\r\n this._destroyRef.onDestroy(() => {\r\n resizeObserver.disconnect();\r\n });\r\n });\r\n }\r\n}\r\n","<pagination-template #p=\"paginationApi\" class=\"w-full px-4 py-2 flex items-center\" [id]=\"id()\"\r\n [maxSize]=\"isScreenSmall() && maxSize() > 5 ? 5 : maxSize()\" (pageChange)=\"pageChange.emit($event)\"\r\n (pageBoundsCorrection)=\"pageBoundsCorrection.emit($event)\" (perPageCountChange)=\"perPageCountChange.emit($event)\">\r\n @if (!(autoHide() && p.pages().length <= 1)) {\r\n <!-- 左:总计 -->\r\n <div class=\"flex-auto\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <span class=\"text-sm text-secondary whitespace-nowrap\">共 {{ p.getTotalItems() }} 条</span>\r\n </div>\r\n\r\n <!-- 右:导航 + 页码跳转 + 每页条数 -->\r\n <nav role=\"navigation\" class=\"flex\" [ngClass]=\"{'w-full':isScreenSmall()}\">\r\n <ul class=\"flex items-center\"\r\n [ngClass]=\"{'justify-center w-full gap-0':isScreenSmall(),'flex-row gap-0.5':!isScreenSmall()}\">\r\n\r\n <!-- 首页 -->\r\n <li [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.goFirstPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:first_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- 上一页 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.previous()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-left\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- 页码 -->\r\n @if (isScreenSmall()) {\r\n <li>\r\n <span class=\"px-3 text-sm tabular-nums whitespace-nowrap\">{{ p.getCurrent() }} / {{ p.getLastPage() }}</span>\r\n </li>\r\n } @else {\r\n <li>\r\n <div class=\"flex items-center gap-0.5\">\r\n @for (page of p.pages(); track $index) {\r\n @if (page.label === \"...\") {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary\">...</span>\r\n } @else if (p.getCurrent() === page.value) {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full bg-primary-500 text-white text-sm font-medium\">\r\n {{ page.label | number: \"\" }}\r\n </span>\r\n } @else {\r\n <a tabindex=\"0\" role=\"presentation\"\r\n class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary cursor-pointer hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors\"\r\n (click)=\"p.setCurrent(page.value)\">\r\n {{ page.label | number: \"\" }}\r\n </a>\r\n }\r\n }\r\n </div>\r\n </li>\r\n }\r\n\r\n <!-- 下一页 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.next()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-right\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- 末页 -->\r\n <li [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.goLastPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:last_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- 页码跳转(桌面端) -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field appearance=\"outline\" [ngStyle]=\"{\r\n width: (p.getLastPage()?.toString()?.length || 0) * 8 + 64 + 'px',\r\n }\">\r\n <input #current matInput type=\"text\" cmatDigitOnly class=\"text-end\" [value]=\"p.getCurrent()\"\r\n [autocomplete]=\"'off'\" [min]=\"0\" [max]=\"p.getLastPage() || 0\" (keyup.enter)=\"p.setCurrent(current.value)\" />\r\n <span matSuffix>/\r\n <div class=\"px-1\">{{ p.getLastPage() }}</div>\r\n </span>\r\n </mat-form-field>\r\n </li>\r\n\r\n <!-- 每页条数(桌面端) -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field class=\"w-20\" appearance=\"outline\">\r\n <mat-select #pageCount [value]=\"initPerPage()\" (selectionChange)=\"p.setItemsPerPage(pageCount.value)\">\r\n @for (perPage of itemsPerPages(); track perPage) {\r\n <mat-option [value]=\"perPage\">{{ perPage }}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n </li>\r\n </ul>\r\n </nav>\r\n }\r\n</pagination-template>\r\n","import { Pipe, PipeTransform, inject } from '@angular/core';\r\nimport { CmatPaginationInstance } from './pagination.instance';\r\nimport { CmatPaginationService } from './pagination.service';\r\n\r\nconst LARGE_NUMBER = Number.MAX_SAFE_INTEGER;\r\n\r\nexport type Collection<T> = readonly T[];\r\n\r\nexport interface CmatPaginatePipeArgs {\r\n id?: string;\r\n currentPage: string | number;\r\n itemsPerPage: string | number;\r\n totalItems: string | number;\r\n}\r\n\r\nexport interface CmatPipeState {\r\n size: number;\r\n start?: number;\r\n end?: number;\r\n slice: readonly unknown[];\r\n}\r\n\r\n@Pipe({\r\n name: 'paginate',\r\n pure: true\r\n})\r\nexport class CmatPaginatePipe implements PipeTransform {\r\n private service = inject(CmatPaginationService);\r\n\r\n private readonly state: Record<string, CmatPipeState> = {};\r\n\r\n public transform<T, U extends Collection<T>>(collection: U, args: CmatPaginatePipeArgs): U {\r\n if (!Array.isArray(collection)) {\r\n const _id = args.id ?? this.service.defaultId();\r\n const cachedSlice = this.state[_id]?.slice as unknown as U | undefined;\r\n\r\n return cachedSlice ?? collection;\r\n }\r\n\r\n const totalItems = this._toNumber(args.totalItems) || collection.length;\r\n const serverSideMode = totalItems !== collection.length;\r\n const instance = this.createInstance(collection, { ...args, totalItems });\r\n\r\n const id = instance.id ?? this.service.defaultId();\r\n let start: number | undefined;\r\n let end: number | undefined;\r\n const perPage = this._toNumber(args.itemsPerPage);\r\n\r\n const emitChange = this.service.register(instance,true);\r\n\r\n if (!serverSideMode) {\r\n const pageSize = perPage || LARGE_NUMBER;\r\n start = (instance.currentPage - 1) * pageSize;\r\n end = start + pageSize;\r\n\r\n const isIdentical = this._stateIsIdentical(id, collection, start, end);\r\n if (isIdentical) {\r\n return this.state[id].slice as unknown as U;\r\n }\r\n\r\n const slice = collection.slice(start, end);\r\n this._saveState(id, collection, slice, start, end);\r\n this.service.notifyChange(id);\r\n return slice as unknown as U;\r\n }\r\n\r\n if (emitChange) {\r\n this.service.notifyChange(id);\r\n }\r\n\r\n this._saveState(id, collection, collection, start, end);\r\n\r\n return collection;\r\n\r\n }\r\n\r\n private createInstance(collection: readonly unknown[], config: CmatPaginatePipeArgs): CmatPaginationInstance {\r\n this.checkConfig(config);\r\n\r\n return {\r\n id: config.id ?? this.service.defaultId(),\r\n itemsPerPage: this._toNumber(config.itemsPerPage) || 10,\r\n currentPage: this._toNumber(config.currentPage) || 1,\r\n totalItems: this._toNumber(config.totalItems) || collection.length\r\n };\r\n }\r\n\r\n private checkConfig(config: CmatPaginatePipeArgs): void {\r\n const missing = ['itemsPerPage', 'currentPage'].filter(prop => !(prop in config));\r\n\r\n if (missing.length > 0) {\r\n throw new Error(`PaginatePipe: Argument is missing the following required properties: ${missing.join(', ')}`);\r\n }\r\n }\r\n\r\n private _saveState(id: string, collection: readonly unknown[], slice: readonly unknown[], start?: number, end?: number): void {\r\n this.state[id] = {\r\n size: collection.length,\r\n slice,\r\n start,\r\n end\r\n };\r\n }\r\n\r\n private _stateIsIdentical(id: string, collection: readonly unknown[], start: number, end: number): boolean {\r\n const state = this.state[id];\r\n if (!state) {\r\n return false;\r\n }\r\n const isMetaDataIdentical = state.size === collection.length &&\r\n state.start === start &&\r\n state.end === end;\r\n\r\n if (!isMetaDataIdentical) {\r\n return false;\r\n }\r\n\r\n return state.slice.every((element, index) => element === collection[start + index]);\r\n }\r\n\r\n private _toNumber(value: string | number): number {\r\n return Number(value);\r\n }\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;MAMa,qB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ACT,iBAAA;;;ACzBD;;AAEG;;;;"}
1
+ {"version":3,"file":"cmat-components-pagination.mjs","sources":["../../../projects/cmat/components/pagination/pagination.service.ts","../../../projects/cmat/components/pagination/pagination.directive.ts","../../../projects/cmat/components/pagination/pagination.component.ts","../../../projects/cmat/components/pagination/pagination.component.html","../../../projects/cmat/components/pagination/pagination.pipe.ts","../../../projects/cmat/components/pagination/cmat-components-pagination.ts"],"sourcesContent":["import { Injectable, signal, untracked } from '@angular/core';\r\nimport { CmatPaginationInstance } from './pagination.instance';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CmatPaginationService {\r\n private readonly _instances = signal<Record<string, CmatPaginationInstance>>({});\r\n\r\n // eslint-disable-next-line @typescript-eslint/member-ordering\r\n readonly instances = this._instances.asReadonly();\r\n\r\n private readonly _defaultPaginationId = 'DEFAULT_PAGINATION_ID';\r\n\r\n public defaultId(): string { return this._defaultPaginationId; }\r\n\r\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\r\n public notifyChange(_id: string): void {\r\n // 使用 requestAnimationFrame 延迟 Signal 更新,避免在模板渲染周期中写入\r\n requestAnimationFrame(() => {\r\n this._instances.update(current => ({ ...current }));\r\n });\r\n }\r\n\r\n public register(instance: CmatPaginationInstance, fromPipe: boolean = false): boolean {\r\n const normalizedInstance: CmatPaginationInstance = {\r\n ...structuredClone(instance),\r\n id: instance.id ?? this._defaultPaginationId\r\n };\r\n const id = normalizedInstance.id!;\r\n\r\n let changed = false;\r\n const currentInstances = untracked(() => this._instances());\r\n\r\n if (!currentInstances[id]) {\r\n changed = true;\r\n } else {\r\n const needsUpdate = this._needsUpdate(currentInstances[id], normalizedInstance);\r\n if (needsUpdate) {\r\n changed = true;\r\n }\r\n }\r\n\r\n if (changed) {\r\n if (fromPipe) {\r\n requestAnimationFrame(() => {\r\n this._instances.update((current) => {\r\n if (!current[id]) {\r\n return { ...current, [id]: normalizedInstance };\r\n } else {\r\n this._updateInstance(current[id], normalizedInstance);\r\n return { ...current };\r\n }\r\n });\r\n });\r\n }\r\n else {\r\n this._instances.update((current) => {\r\n if (!current[id]) {\r\n return { ...current, [id]: normalizedInstance };\r\n } else {\r\n this._updateInstance(current[id], normalizedInstance);\r\n return { ...current };\r\n }\r\n });\r\n }\r\n }\r\n\r\n return changed;\r\n }\r\n\r\n public getCurrentPage(id: string): number | undefined {\r\n return this._instances()[id]?.currentPage;\r\n }\r\n\r\n public getItemsPerPage(id: string): number | undefined {\r\n return this._instances()[id]?.itemsPerPage;\r\n }\r\n\r\n public setCurrentPage(id: string, page: number): void {\r\n this._instances.update((current) => {\r\n const instance = current[id];\r\n if (instance) {\r\n const maxPage = Math.ceil(instance.totalItems / instance.itemsPerPage);\r\n if (page <= maxPage && 1 <= page) {\r\n // 创建新引用以确保 Signal 检测到变化\r\n current[id] = { ...instance, currentPage: page };\r\n return { ...current };\r\n }\r\n }\r\n return current;\r\n });\r\n\r\n // 通知分页器更新显示\r\n this.notifyChange(id);\r\n }\r\n\r\n public setTotalItems(id: string, totalItems: number): void {\r\n this._instances.update((current) => {\r\n const instance = current[id];\r\n if (instance && 0 <= totalItems) {\r\n current[id] = { ...instance, totalItems };\r\n return { ...current };\r\n }\r\n return current;\r\n });\r\n\r\n // 通知分页器更新显示\r\n this.notifyChange(id);\r\n }\r\n\r\n public setItemsPerPage(id: string, itemsPerPage: number): void {\r\n this._instances.update((current) => {\r\n const instance = current[id];\r\n if (instance) {\r\n current[id] = { ...instance, itemsPerPage };\r\n return { ...current };\r\n }\r\n return current;\r\n });\r\n\r\n // 通知分页器更新显示\r\n this.notifyChange(id);\r\n }\r\n\r\n public getInstance(id: string = this._defaultPaginationId): CmatPaginationInstance | undefined {\r\n const instance = this._instances()[id];\r\n if (instance) {\r\n return this._clone(instance);\r\n }\r\n\r\n return undefined;\r\n }\r\n\r\n private _updateInstance(current: CmatPaginationInstance, incoming: CmatPaginationInstance): boolean {\r\n let changed = false;\r\n if (incoming.id) {\r\n const keys = new Set([...Object.keys(current), ...Object.keys(incoming)]);\r\n\r\n for (const prop of keys) {\r\n const key = prop as keyof CmatPaginationInstance;\r\n\r\n if (incoming[key] !== current[key]) {\r\n current[key] = incoming[key];\r\n changed = true;\r\n }\r\n }\r\n }\r\n return changed;\r\n }\r\n\r\n private _needsUpdate(current: CmatPaginationInstance, incoming: CmatPaginationInstance): boolean {\r\n // 检查是否有任何属性发生变化\r\n const keys = new Set([...Object.keys(current), ...Object.keys(incoming)]);\r\n for (const prop of keys) {\r\n const key = prop as keyof CmatPaginationInstance;\r\n if (incoming[key] !== current[key]) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n }\r\n\r\n private _clone<T extends Record<string, unknown>>(obj: T): T {\r\n return structuredClone(obj);\r\n }\r\n}\r\n","import {\r\n afterNextRender,\r\n Directive,\r\n inject,\r\n Injector,\r\n signal,\r\n input,\r\n output,\r\n effect,\r\n untracked,\r\n} from '@angular/core';\r\nimport { CmatPaginationInstance } from './pagination.instance';\r\nimport { CmatPaginationService } from './pagination.service';\r\n\r\nexport interface Page {\r\n label: string | number;\r\n value: number;\r\n}\r\n@Directive({\r\n // eslint-disable-next-line @angular-eslint/directive-selector\r\n selector: 'pagination-template,[pagination-template]',\r\n exportAs: 'paginationApi',\r\n})\r\nexport class CmatPaginationDirective {\r\n readonly id = input<string>();\r\n readonly maxSize = input<number>(7);\r\n\r\n readonly pageChange = output<number>();\r\n readonly pageBoundsCorrection = output<number>();\r\n readonly perPageCountChange = output<number>();\r\n\r\n readonly pages = signal<Page[]>([]);\r\n\r\n private readonly service = inject(CmatPaginationService);\r\n private readonly _injector = inject(Injector);\r\n private _pageLinksUpdateQueued = false;\r\n\r\n constructor() {\r\n effect(() => {\r\n const instances = this.service.instances();\r\n\r\n if (this._getId() === instances[this._getId()]?.id) {\r\n untracked(() => {\r\n this._schedulePageLinksUpdate();\r\n });\r\n }\r\n });\r\n\r\n this._schedulePageLinksUpdate();\r\n }\r\n\r\n previous(): void {\r\n if (!this.isFirstPage()) {\r\n this._checkValidId();\r\n\r\n const current = this.getCurrent();\r\n if (current) this.setCurrent(current - 1);\r\n }\r\n }\r\n\r\n next(): void {\r\n if (!this.isLastPage()) {\r\n this._checkValidId();\r\n\r\n const current = this.getCurrent();\r\n if (current) this.setCurrent(current + 1);\r\n }\r\n }\r\n\r\n goFirstPage(): void {\r\n if (!this.isFirstPage()) {\r\n this._checkValidId();\r\n\r\n this.setCurrent(1);\r\n }\r\n }\r\n\r\n goLastPage(): void {\r\n if (!this.isLastPage()) {\r\n this._checkValidId();\r\n\r\n const lastPage = this.getLastPage();\r\n if (lastPage) this.setCurrent(lastPage);\r\n }\r\n }\r\n\r\n isFirstPage(): boolean {\r\n return this.getCurrent() === 1;\r\n }\r\n\r\n isLastPage(): boolean {\r\n return this.getLastPage() === this.getCurrent();\r\n }\r\n\r\n setCurrent(page: number | string): void {\r\n const nextPage = Number(page);\r\n\r\n if (!Number.isNaN(nextPage)) {\r\n this.pageChange.emit(nextPage);\r\n }\r\n }\r\n\r\n getCurrent(): number | void {\r\n return this.service.getCurrentPage(this._getId());\r\n }\r\n\r\n getLastPage(): number | void {\r\n const inst = this.service.getInstance(this._getId());\r\n if (!inst) {\r\n return;\r\n }\r\n\r\n if (inst.totalItems < 1) {\r\n return 1;\r\n }\r\n return Math.ceil(inst.totalItems / inst.itemsPerPage);\r\n }\r\n\r\n getTotalItems(): number | void {\r\n return this.service.getInstance(this._getId())?.totalItems;\r\n }\r\n\r\n setItemsPerPage(count: number): void {\r\n const id = this._getId();\r\n this.service.setItemsPerPage(id, count);\r\n\r\n this.perPageCountChange.emit(count);\r\n const inst = this.service.getInstance(id);\r\n if (!inst) {\r\n return;\r\n }\r\n\r\n this.setCurrent(this._outOfBoundCorrection(inst));\r\n }\r\n\r\n private _getId(): string {\r\n return this.id() ?? this.service.defaultId();\r\n }\r\n\r\n private _checkValidId(): void {\r\n const id = this._getId();\r\n if (this.service.getInstance(id)?.id == null) {\r\n console.warn(\r\n `PaginationControlsDirective: the specified id \"${id}\" does not match any registered PaginationInstance`,\r\n );\r\n }\r\n }\r\n\r\n private _updatePageLinks(): void {\r\n const inst = this.service.getInstance(this._getId());\r\n if (!inst) {\r\n this.pages.set([]);\r\n return;\r\n }\r\n\r\n const correctedCurrentPage = this._outOfBoundCorrection(inst);\r\n const pageForRender =\r\n correctedCurrentPage !== inst.currentPage\r\n ? correctedCurrentPage\r\n : inst.currentPage;\r\n\r\n this.pageBoundsCorrection.emit(correctedCurrentPage);\r\n this.pages.set(\r\n this._createPageArray(\r\n pageForRender,\r\n inst.itemsPerPage,\r\n inst.totalItems,\r\n this.maxSize(),\r\n ),\r\n );\r\n }\r\n\r\n private _schedulePageLinksUpdate(): void {\r\n if (this._pageLinksUpdateQueued) {\r\n return;\r\n }\r\n\r\n this._pageLinksUpdateQueued = true;\r\n afterNextRender(\r\n () => {\r\n this._pageLinksUpdateQueued = false;\r\n this._updatePageLinks();\r\n },\r\n { injector: this._injector },\r\n );\r\n }\r\n\r\n private _outOfBoundCorrection(instance: CmatPaginationInstance): number {\r\n const totalPages = Math.ceil(instance.totalItems / instance.itemsPerPage);\r\n if (totalPages < instance.currentPage && 0 < totalPages) {\r\n return totalPages;\r\n } else if (instance.currentPage < 1) {\r\n return 1;\r\n }\r\n\r\n return instance.currentPage;\r\n }\r\n\r\n private _createPageArray(\r\n currentPage: number,\r\n itemsPerPage: number,\r\n totalItems: number,\r\n paginationRange: number,\r\n ): Page[] {\r\n paginationRange = +paginationRange;\r\n const pages: Page[] = [];\r\n\r\n const totalPages = Math.max(Math.ceil(totalItems / itemsPerPage), 1);\r\n const halfWay = Math.ceil(paginationRange / 2);\r\n\r\n const isStart = currentPage <= halfWay;\r\n const isEnd = totalPages - halfWay < currentPage;\r\n const isMiddle = !isStart && !isEnd;\r\n\r\n const ellipsesNeeded = paginationRange < totalPages;\r\n let i = 1;\r\n\r\n while (i <= totalPages && i <= paginationRange) {\r\n let label: string | number;\r\n const pageNumber = this._calculatePageNumber(\r\n i,\r\n currentPage,\r\n paginationRange,\r\n totalPages,\r\n );\r\n const openingEllipsesNeeded = i === 2 && (isMiddle || isEnd);\r\n const closingEllipsesNeeded =\r\n i === paginationRange - 1 && (isMiddle || isStart);\r\n if (ellipsesNeeded && (openingEllipsesNeeded || closingEllipsesNeeded)) {\r\n label = '...';\r\n } else {\r\n label = pageNumber;\r\n }\r\n pages.push({\r\n label: label,\r\n value: pageNumber,\r\n });\r\n i++;\r\n }\r\n\r\n return pages;\r\n }\r\n\r\n private _calculatePageNumber(\r\n i: number,\r\n currentPage: number,\r\n paginationRange: number,\r\n totalPages: number,\r\n ): number {\r\n const halfWay = Math.ceil(paginationRange / 2);\r\n if (i === paginationRange) {\r\n return totalPages;\r\n } else if (i === 1) {\r\n return i;\r\n } else if (paginationRange < totalPages) {\r\n if (totalPages - halfWay < currentPage) {\r\n return totalPages - paginationRange + i;\r\n } else if (halfWay < currentPage) {\r\n return currentPage - halfWay + i;\r\n } else {\r\n return i;\r\n }\r\n } else {\r\n return i;\r\n }\r\n }\r\n}\r\n","import { DecimalPipe, NgClass, NgStyle } from '@angular/common';\r\nimport {\r\n ChangeDetectionStrategy,\r\n Component,\r\n ViewEncapsulation,\r\n inject,\r\n input,\r\n output,\r\n computed,\r\n ElementRef,\r\n afterNextRender,\r\n signal,\r\n DestroyRef,\r\n} from '@angular/core';\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { MatFormFieldModule } from '@angular/material/form-field';\r\nimport { MatIconModule } from '@angular/material/icon';\r\nimport { MatInputModule } from '@angular/material/input';\r\nimport { MatSelectModule } from '@angular/material/select';\r\nimport { CmatDigitOnlyDirective } from 'cmat/directives/digit-only';\r\nimport { CmatPaginationDirective } from './pagination.directive';\r\n\r\n@Component({\r\n selector: 'cmat-pagination',\r\n templateUrl: './pagination.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n encapsulation: ViewEncapsulation.None,\r\n exportAs: 'cmatPagination',\r\n imports: [\r\n CmatPaginationDirective,\r\n CmatDigitOnlyDirective,\r\n MatIconModule,\r\n MatFormFieldModule,\r\n MatInputModule,\r\n MatSelectModule,\r\n DecimalPipe,\r\n MatButtonModule,\r\n NgClass,\r\n NgStyle,\r\n ],\r\n})\r\nexport class CmatPaginationComponent {\r\n readonly id = input<string>();\r\n readonly maxSize = input<number>(7);\r\n readonly itemsPerPages = input<number[]>([10, 20, 30]);\r\n readonly initPerPage = input<number>(10);\r\n readonly autoHide = input<boolean>(false);\r\n\r\n readonly pageChange = output<number>();\r\n readonly pageBoundsCorrection = output<number>();\r\n readonly perPageCountChange = output<number>();\r\n\r\n private _elementRef = inject<ElementRef<HTMLElement>>(ElementRef);\r\n private _destroyRef = inject(DestroyRef);\r\n\r\n // 组件宽度信号,初始化为一个合理默认值\r\n private _componentWidth = signal<number>(1024);\r\n\r\n // 根据组件自身宽度判断是否使用移动端样式(阈值:768px)\r\n // eslint-disable-next-line @typescript-eslint/member-ordering\r\n readonly isScreenSmall = computed(() => {\r\n return this._componentWidth() < 768;\r\n });\r\n\r\n constructor() {\r\n // 使用 ResizeObserver 监听组件自身宽度变化\r\n afterNextRender(() => {\r\n const element = this._elementRef.nativeElement;\r\n\r\n // 确保元素是块级或行内块级,可以正确测量宽度\r\n if (getComputedStyle(element).display === 'inline') {\r\n element.style.display = 'inline-block';\r\n element.style.width = '100%';\r\n }\r\n\r\n // 立即获取一次初始宽度\r\n const initialWidth = element.getBoundingClientRect().width;\r\n if (initialWidth > 0) {\r\n this._componentWidth.set(initialWidth);\r\n }\r\n\r\n // 创建 ResizeObserver\r\n const resizeObserver = new ResizeObserver((entries) => {\r\n for (const entry of entries) {\r\n const width = entry.contentRect.width;\r\n // 只有当宽度大于0时才更新,避免无效值\r\n if (width > 0) {\r\n this._componentWidth.set(width);\r\n }\r\n }\r\n });\r\n\r\n // 开始观察\r\n resizeObserver.observe(element);\r\n\r\n // 组件销毁时清理观察者\r\n this._destroyRef.onDestroy(() => {\r\n resizeObserver.disconnect();\r\n });\r\n });\r\n }\r\n}\r\n","<pagination-template #p=\"paginationApi\" class=\"w-full px-4 py-2 flex items-center\" [id]=\"id()\"\r\n [maxSize]=\"isScreenSmall() && maxSize() > 5 ? 5 : maxSize()\"\r\n (pageChange)=\"pageChange.emit($event)\"\r\n (pageBoundsCorrection)=\"pageBoundsCorrection.emit($event)\" (perPageCountChange)=\"perPageCountChange.emit($event)\">\r\n @if (!(autoHide() && p.pages().length <= 1)) {\r\n <!-- 左:总计 -->\r\n <div class=\"flex-auto\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <span class=\"text-sm text-secondary whitespace-nowrap\">共 {{ p.getTotalItems() }} 条</span>\r\n </div>\r\n\r\n <!-- 右:导航 -->\r\n <nav role=\"navigation\" class=\"flex\" [ngClass]=\"{'w-full':isScreenSmall()}\">\r\n <ul class=\"flex items-center\"\r\n [ngClass]=\"{'justify-center w-full gap-0':isScreenSmall(),'flex-row gap-0.5':!isScreenSmall()}\">\r\n\r\n <!-- 首页 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.goFirstPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:first_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- 上一页 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === 1\" (click)=\"p.previous()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-left\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- 页码 -->\r\n <li class=\"mx-1\">\r\n <div class=\"flex items-center gap-0.5\">\r\n @for (page of p.pages(); track $index) {\r\n @if (page.label === \"...\") {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary\">...</span>\r\n } @else if (p.getCurrent() === page.value) {\r\n <span class=\"flex items-center justify-center w-8 h-8 rounded-full bg-primary-500 text-white text-sm font-medium\">\r\n {{ page.label | number: \"\" }}\r\n </span>\r\n } @else {\r\n <a tabindex=\"0\" role=\"presentation\"\r\n class=\"flex items-center justify-center w-8 h-8 rounded-full text-sm text-secondary cursor-pointer hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors\"\r\n (click)=\"p.setCurrent(page.value)\">\r\n {{ page.label | number: \"\" }}\r\n </a>\r\n }\r\n }\r\n </div>\r\n </li>\r\n\r\n <!-- 下一页 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.next()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"heroicons_outline:chevron-right\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- 末页 -->\r\n <li>\r\n <button type=\"button\" matIconButton [disabled]=\"p.getCurrent() === p.getLastPage()\" (click)=\"p.goLastPage()\">\r\n <mat-icon class=\"icon-size-5\" svgIcon=\"mat_outline:last_page\"></mat-icon>\r\n </button>\r\n </li>\r\n\r\n <!-- 页码跳转(桌面端) -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field appearance=\"outline\" [ngStyle]=\"{\r\n width: (p.getLastPage()?.toString()?.length || 0) * 8 + 64 + 'px',\r\n }\">\r\n <input #current matInput type=\"text\" cmatDigitOnly class=\"text-end\" [value]=\"p.getCurrent()\"\r\n [autocomplete]=\"'off'\" [min]=\"0\" [max]=\"p.getLastPage() || 0\" (keyup.enter)=\"p.setCurrent(current.value)\" />\r\n <span matSuffix>/\r\n <div class=\"px-2\">{{ p.getLastPage() }}</div>\r\n </span>\r\n </mat-form-field>\r\n </li>\r\n\r\n <!-- 每页条数(桌面端) -->\r\n <li class=\"px-1\" [ngClass]=\"{'hidden':isScreenSmall(),'block':!isScreenSmall()}\">\r\n <mat-form-field class=\"w-20\" appearance=\"outline\">\r\n <mat-select #pageCount [value]=\"initPerPage()\" (selectionChange)=\"p.setItemsPerPage(pageCount.value)\">\r\n @for (perPage of itemsPerPages(); track perPage) {\r\n <mat-option [value]=\"perPage\">{{ perPage }}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n </li>\r\n </ul>\r\n </nav>\r\n }\r\n</pagination-template>\r\n\r\n<style>\r\n @media (hover: none) and (pointer: coarse) {\r\n cmat-pagination button[matIconButton] {\r\n transition: transform 150ms ease;\r\n }\r\n cmat-pagination button[matIconButton]:active:not([disabled]) {\r\n transform: scale(0.88);\r\n }\r\n }\r\n</style>\r\n","import { Pipe, PipeTransform, inject } from '@angular/core';\r\nimport { CmatPaginationInstance } from './pagination.instance';\r\nimport { CmatPaginationService } from './pagination.service';\r\n\r\nconst LARGE_NUMBER = Number.MAX_SAFE_INTEGER;\r\n\r\nexport type Collection<T> = readonly T[];\r\n\r\nexport interface CmatPaginatePipeArgs {\r\n id?: string;\r\n currentPage: string | number;\r\n itemsPerPage: string | number;\r\n totalItems: string | number;\r\n}\r\n\r\nexport interface CmatPipeState {\r\n size: number;\r\n start?: number;\r\n end?: number;\r\n slice: readonly unknown[];\r\n}\r\n\r\n@Pipe({\r\n name: 'paginate',\r\n pure: true\r\n})\r\nexport class CmatPaginatePipe implements PipeTransform {\r\n private service = inject(CmatPaginationService);\r\n\r\n private readonly state: Record<string, CmatPipeState> = {};\r\n\r\n public transform<T, U extends Collection<T>>(collection: U, args: CmatPaginatePipeArgs): U {\r\n if (!Array.isArray(collection)) {\r\n const _id = args.id ?? this.service.defaultId();\r\n const cachedSlice = this.state[_id]?.slice as unknown as U | undefined;\r\n\r\n return cachedSlice ?? collection;\r\n }\r\n\r\n const totalItems = this._toNumber(args.totalItems) || collection.length;\r\n const serverSideMode = totalItems !== collection.length;\r\n const instance = this.createInstance(collection, { ...args, totalItems });\r\n\r\n const id = instance.id ?? this.service.defaultId();\r\n let start: number | undefined;\r\n let end: number | undefined;\r\n const perPage = this._toNumber(args.itemsPerPage);\r\n\r\n const emitChange = this.service.register(instance,true);\r\n\r\n if (!serverSideMode) {\r\n const pageSize = perPage || LARGE_NUMBER;\r\n start = (instance.currentPage - 1) * pageSize;\r\n end = start + pageSize;\r\n\r\n const isIdentical = this._stateIsIdentical(id, collection, start, end);\r\n if (isIdentical) {\r\n return this.state[id].slice as unknown as U;\r\n }\r\n\r\n const slice = collection.slice(start, end);\r\n this._saveState(id, collection, slice, start, end);\r\n this.service.notifyChange(id);\r\n return slice as unknown as U;\r\n }\r\n\r\n if (emitChange) {\r\n this.service.notifyChange(id);\r\n }\r\n\r\n this._saveState(id, collection, collection, start, end);\r\n\r\n return collection;\r\n\r\n }\r\n\r\n private createInstance(collection: readonly unknown[], config: CmatPaginatePipeArgs): CmatPaginationInstance {\r\n this.checkConfig(config);\r\n\r\n return {\r\n id: config.id ?? this.service.defaultId(),\r\n itemsPerPage: this._toNumber(config.itemsPerPage) || 10,\r\n currentPage: this._toNumber(config.currentPage) || 1,\r\n totalItems: this._toNumber(config.totalItems) || collection.length\r\n };\r\n }\r\n\r\n private checkConfig(config: CmatPaginatePipeArgs): void {\r\n const missing = ['itemsPerPage', 'currentPage'].filter(prop => !(prop in config));\r\n\r\n if (missing.length > 0) {\r\n throw new Error(`PaginatePipe: Argument is missing the following required properties: ${missing.join(', ')}`);\r\n }\r\n }\r\n\r\n private _saveState(id: string, collection: readonly unknown[], slice: readonly unknown[], start?: number, end?: number): void {\r\n this.state[id] = {\r\n size: collection.length,\r\n slice,\r\n start,\r\n end\r\n };\r\n }\r\n\r\n private _stateIsIdentical(id: string, collection: readonly unknown[], start: number, end: number): boolean {\r\n const state = this.state[id];\r\n if (!state) {\r\n return false;\r\n }\r\n const isMetaDataIdentical = state.size === collection.length &&\r\n state.start === start &&\r\n state.end === end;\r\n\r\n if (!isMetaDataIdentical) {\r\n return false;\r\n }\r\n\r\n return state.slice.every((element, index) => element === collection[start + index]);\r\n }\r\n\r\n private _toNumber(value: string | number): number {\r\n return Number(value);\r\n }\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;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