rd-outer-component 0.0.1

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 (94) hide show
  1. package/README.md +24 -0
  2. package/esm2020/lib/constants/common.constant.mjs +21 -0
  3. package/esm2020/lib/modules/custom-checkbox/custom-checkbox.component.mjs +72 -0
  4. package/esm2020/lib/modules/custom-checkbox/custom-checkbox.module.mjs +20 -0
  5. package/esm2020/lib/modules/custom-checkbox/index.mjs +3 -0
  6. package/esm2020/lib/modules/custom-date/custom-date.component.mjs +77 -0
  7. package/esm2020/lib/modules/custom-date/custom-date.module.mjs +20 -0
  8. package/esm2020/lib/modules/custom-date/index.mjs +3 -0
  9. package/esm2020/lib/modules/custom-filter/custom-filter-date/custom-filter-date.component.mjs +58 -0
  10. package/esm2020/lib/modules/custom-filter/custom-filter-input/custom-filter-input.component.mjs +38 -0
  11. package/esm2020/lib/modules/custom-filter/custom-filter-select/custom-filter-select.component.mjs +58 -0
  12. package/esm2020/lib/modules/custom-filter/custom-filter.component.mjs +40 -0
  13. package/esm2020/lib/modules/custom-filter/custom-filter.module.mjs +59 -0
  14. package/esm2020/lib/modules/custom-filter/custom-filter.types.mjs +7 -0
  15. package/esm2020/lib/modules/custom-filter/index.mjs +3 -0
  16. package/esm2020/lib/modules/custom-input/custom-input.component.mjs +227 -0
  17. package/esm2020/lib/modules/custom-input/custom-input.module.mjs +35 -0
  18. package/esm2020/lib/modules/custom-input/index.mjs +3 -0
  19. package/esm2020/lib/modules/custom-input-amount/custom-input-amount.component.mjs +176 -0
  20. package/esm2020/lib/modules/custom-input-amount/custom-input-amount.module.mjs +35 -0
  21. package/esm2020/lib/modules/custom-input-amount/index.mjs +3 -0
  22. package/esm2020/lib/modules/custom-radio/custom-radio.component.mjs +75 -0
  23. package/esm2020/lib/modules/custom-radio/custom-radio.module.mjs +35 -0
  24. package/esm2020/lib/modules/custom-radio/index.mjs +3 -0
  25. package/esm2020/lib/modules/custom-select/custom-select.component.mjs +130 -0
  26. package/esm2020/lib/modules/custom-select/custom-select.module.mjs +35 -0
  27. package/esm2020/lib/modules/custom-select/index.mjs +3 -0
  28. package/esm2020/lib/modules/status-field/index.mjs +3 -0
  29. package/esm2020/lib/modules/status-field/status-field.component.mjs +28 -0
  30. package/esm2020/lib/modules/status-field/status-field.module.mjs +18 -0
  31. package/esm2020/lib/pipes/big-number.pipe.mjs +19 -0
  32. package/esm2020/lib/pipes/index.mjs +3 -0
  33. package/esm2020/lib/pipes/pipes.module.mjs +17 -0
  34. package/esm2020/lib/types/common.enum.mjs +24 -0
  35. package/esm2020/lib/types/common.type.mjs +2 -0
  36. package/esm2020/lib/utils/big-number.mjs +42 -0
  37. package/esm2020/lib/utils/debounce.mjs +15 -0
  38. package/esm2020/public-api.mjs +15 -0
  39. package/esm2020/rd-outer-component.mjs +5 -0
  40. package/fesm2015/rd-outer-component.mjs +1287 -0
  41. package/fesm2015/rd-outer-component.mjs.map +1 -0
  42. package/fesm2020/rd-outer-component.mjs +1277 -0
  43. package/fesm2020/rd-outer-component.mjs.map +1 -0
  44. package/index.d.ts +5 -0
  45. package/lib/constants/common.constant.d.ts +19 -0
  46. package/lib/modules/custom-checkbox/custom-checkbox.component.d.ts +26 -0
  47. package/lib/modules/custom-checkbox/custom-checkbox.module.d.ts +10 -0
  48. package/lib/modules/custom-checkbox/index.d.ts +2 -0
  49. package/lib/modules/custom-date/custom-date.component.d.ts +26 -0
  50. package/lib/modules/custom-date/custom-date.module.d.ts +10 -0
  51. package/lib/modules/custom-date/index.d.ts +2 -0
  52. package/lib/modules/custom-filter/custom-filter-date/custom-filter-date.component.d.ts +20 -0
  53. package/lib/modules/custom-filter/custom-filter-input/custom-filter-input.component.d.ts +13 -0
  54. package/lib/modules/custom-filter/custom-filter-select/custom-filter-select.component.d.ts +14 -0
  55. package/lib/modules/custom-filter/custom-filter.component.d.ts +16 -0
  56. package/lib/modules/custom-filter/custom-filter.module.d.ts +18 -0
  57. package/lib/modules/custom-filter/custom-filter.types.d.ts +19 -0
  58. package/lib/modules/custom-filter/index.d.ts +2 -0
  59. package/lib/modules/custom-input/custom-input.component.d.ts +46 -0
  60. package/lib/modules/custom-input/custom-input.module.d.ts +11 -0
  61. package/lib/modules/custom-input/index.d.ts +2 -0
  62. package/lib/modules/custom-input-amount/custom-input-amount.component.d.ts +39 -0
  63. package/lib/modules/custom-input-amount/custom-input-amount.module.d.ts +11 -0
  64. package/lib/modules/custom-input-amount/index.d.ts +2 -0
  65. package/lib/modules/custom-radio/custom-radio.component.d.ts +26 -0
  66. package/lib/modules/custom-radio/custom-radio.module.d.ts +11 -0
  67. package/lib/modules/custom-radio/index.d.ts +2 -0
  68. package/lib/modules/custom-select/custom-select.component.d.ts +41 -0
  69. package/lib/modules/custom-select/custom-select.module.d.ts +11 -0
  70. package/lib/modules/custom-select/index.d.ts +2 -0
  71. package/lib/modules/status-field/index.d.ts +2 -0
  72. package/lib/modules/status-field/status-field.component.d.ts +30 -0
  73. package/lib/modules/status-field/status-field.module.d.ts +8 -0
  74. package/lib/pipes/big-number.pipe.d.ts +7 -0
  75. package/lib/pipes/index.d.ts +2 -0
  76. package/lib/pipes/pipes.module.d.ts +7 -0
  77. package/lib/types/common.enum.d.ts +19 -0
  78. package/lib/types/common.type.d.ts +6 -0
  79. package/lib/utils/big-number.d.ts +2 -0
  80. package/lib/utils/debounce.d.ts +1 -0
  81. package/package.json +34 -0
  82. package/public-api.d.ts +10 -0
  83. package/src/lib/assets/img/icon/checkbox.svg +6 -0
  84. package/src/lib/assets/img/icon/icon-error.svg +5 -0
  85. package/src/lib/assets/img/status/cancel.svg +4 -0
  86. package/src/lib/assets/img/status/failed.svg +4 -0
  87. package/src/lib/assets/img/status/pending.svg +4 -0
  88. package/src/lib/assets/img/status/returned.svg +4 -0
  89. package/src/lib/assets/img/status/returning.svg +4 -0
  90. package/src/lib/assets/img/status/settling.svg +5 -0
  91. package/src/lib/assets/img/status/submitted.svg +3 -0
  92. package/src/lib/assets/img/status/success.svg +4 -0
  93. package/src/lib/assets/img/status/warning.svg +4 -0
  94. package/src/lib/assets/scss/form-item.scss +200 -0
@@ -0,0 +1,1287 @@
1
+ import * as i0 from '@angular/core';
2
+ import { EventEmitter, forwardRef, Component, Input, Output, NgModule, ViewChild, Pipe } from '@angular/core';
3
+ import * as i2 from '@angular/forms';
4
+ import { NG_VALUE_ACCESSOR, ReactiveFormsModule, FormsModule, NG_VALIDATORS } from '@angular/forms';
5
+ import * as i1 from '@angular/common';
6
+ import { CommonModule, formatDate } from '@angular/common';
7
+ import * as i3$1 from 'ng-zorro-antd/radio';
8
+ import { NzRadioModule } from 'ng-zorro-antd/radio';
9
+ import * as i3 from 'ng-zorro-antd/date-picker';
10
+ import { NzDatePickerModule } from 'ng-zorro-antd/date-picker';
11
+ import * as i2$1 from 'ng-zorro-antd/input';
12
+ import { NzInputModule } from 'ng-zorro-antd/input';
13
+ import * as i4 from 'ngx-mask';
14
+ import { NgxMaskModule } from 'ngx-mask';
15
+ import Big from 'big.js';
16
+ import * as i3$2 from 'ng-zorro-antd/spin';
17
+ import { NzSpinModule } from 'ng-zorro-antd/spin';
18
+ import * as i4$1 from 'ng-zorro-antd/select';
19
+ import { NzSelectModule } from 'ng-zorro-antd/select';
20
+ import * as i2$2 from 'ng-zorro-antd/button';
21
+ import { NzButtonModule } from 'ng-zorro-antd/button';
22
+ import * as i1$1 from 'ng-zorro-antd/core/transition-patch';
23
+ import { differenceInCalendarDays } from 'date-fns';
24
+ import { __decorate } from 'tslib';
25
+ import { NzDropDownModule } from 'ng-zorro-antd/dropdown';
26
+
27
+ class CustomCheckboxComponent {
28
+ set options(val) {
29
+ this._rawOptions = val;
30
+ }
31
+ get options() {
32
+ return this._rawOptions;
33
+ }
34
+ constructor(cdr) {
35
+ this.cdr = cdr;
36
+ this.label = '';
37
+ this.name = '';
38
+ this.disabled = false;
39
+ this.valueChange = new EventEmitter();
40
+ this._rawOptions = [];
41
+ this.value = undefined;
42
+ this.nativeValue = undefined;
43
+ this.onChange = () => { };
44
+ this.onTouched = () => { };
45
+ }
46
+ setDisabledState(isDisabled) {
47
+ this.disabled = isDisabled;
48
+ this.cdr.markForCheck();
49
+ }
50
+ writeValue(value) {
51
+ this.value = value;
52
+ this.nativeValue = value === null || value === void 0 ? void 0 : value.value;
53
+ }
54
+ registerOnChange(fn) {
55
+ this.onChange = fn;
56
+ }
57
+ registerOnTouched(fn) {
58
+ this.onTouched = fn;
59
+ }
60
+ handleValueChange(value) {
61
+ this.onChange(value);
62
+ this.valueChange.emit(value);
63
+ }
64
+ }
65
+ CustomCheckboxComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomCheckboxComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
66
+ CustomCheckboxComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CustomCheckboxComponent, selector: "app-rd-checkbox", inputs: { label: "label", name: "name", disabled: "disabled", options: "options" }, outputs: { valueChange: "valueChange" }, providers: [
67
+ {
68
+ provide: NG_VALUE_ACCESSOR,
69
+ useExisting: forwardRef(() => CustomCheckboxComponent),
70
+ multi: true,
71
+ },
72
+ ], ngImport: i0, template: "<div>\n <div\n class=\"form-item-check\"\n [ngClass]=\"{\n disabled: disabled\n }\"\n >\n <div class=\"desc-14 m-b-8\">{{ label }}</div>\n <nz-checkbox-group\n [(ngModel)]=\"options\"\n (ngModelChange)=\"handleValueChange($event)\"\n ></nz-checkbox-group>\n </div>\n</div>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}::ng-deep .ant-checkbox-group{display:flex}::ng-deep .ant-checkbox-group label{flex:1}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] });
73
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomCheckboxComponent, decorators: [{
74
+ type: Component,
75
+ args: [{ selector: 'app-rd-checkbox', providers: [
76
+ {
77
+ provide: NG_VALUE_ACCESSOR,
78
+ useExisting: forwardRef(() => CustomCheckboxComponent),
79
+ multi: true,
80
+ },
81
+ ], template: "<div>\n <div\n class=\"form-item-check\"\n [ngClass]=\"{\n disabled: disabled\n }\"\n >\n <div class=\"desc-14 m-b-8\">{{ label }}</div>\n <nz-checkbox-group\n [(ngModel)]=\"options\"\n (ngModelChange)=\"handleValueChange($event)\"\n ></nz-checkbox-group>\n </div>\n</div>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}::ng-deep .ant-checkbox-group{display:flex}::ng-deep .ant-checkbox-group label{flex:1}\n"] }]
82
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { label: [{
83
+ type: Input
84
+ }], name: [{
85
+ type: Input
86
+ }], disabled: [{
87
+ type: Input
88
+ }], options: [{
89
+ type: Input
90
+ }], valueChange: [{
91
+ type: Output
92
+ }] } });
93
+
94
+ class RdCheckboxModule {
95
+ }
96
+ RdCheckboxModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdCheckboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
97
+ RdCheckboxModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: RdCheckboxModule, declarations: [CustomCheckboxComponent], imports: [CommonModule, ReactiveFormsModule, FormsModule, NzRadioModule], exports: [CustomCheckboxComponent] });
98
+ RdCheckboxModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdCheckboxModule, imports: [CommonModule, ReactiveFormsModule, FormsModule, NzRadioModule] });
99
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdCheckboxModule, decorators: [{
100
+ type: NgModule,
101
+ args: [{
102
+ declarations: [CustomCheckboxComponent],
103
+ imports: [CommonModule, ReactiveFormsModule, FormsModule, NzRadioModule],
104
+ exports: [CustomCheckboxComponent],
105
+ }]
106
+ }] });
107
+
108
+ class CustomDateComponent {
109
+ constructor() {
110
+ this.disabled = false;
111
+ this.inputValue = null;
112
+ this.isPickerOpen = false;
113
+ this.showError = false;
114
+ this.currentErrorMessage = '';
115
+ this.onChange = () => { };
116
+ this.onTouched = () => { };
117
+ }
118
+ ngOnInit() { }
119
+ writeValue(value) {
120
+ this.inputValue = value;
121
+ }
122
+ registerOnChange(fn) {
123
+ this.onChange = fn;
124
+ }
125
+ registerOnTouched(fn) {
126
+ this.onTouched = fn;
127
+ }
128
+ setDisabledState(isDisabled) {
129
+ this.disabled = isDisabled;
130
+ }
131
+ validate(control) {
132
+ return null;
133
+ }
134
+ onDateChange(value) {
135
+ this.inputValue = value;
136
+ this.onChange(value);
137
+ }
138
+ onOpenChange(open) {
139
+ setTimeout(() => {
140
+ this.isPickerOpen = open;
141
+ }, 0);
142
+ }
143
+ openPicker() {
144
+ var _a;
145
+ if (this.isPickerOpen) {
146
+ return;
147
+ }
148
+ this.isPickerOpen = true;
149
+ (_a = this.datePicker) === null || _a === void 0 ? void 0 : _a.open();
150
+ }
151
+ }
152
+ CustomDateComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomDateComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
153
+ CustomDateComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CustomDateComponent, selector: "app-rd-date", inputs: { disabled: "disabled", disabledDate: "disabledDate", label: "label" }, providers: [
154
+ {
155
+ provide: NG_VALUE_ACCESSOR,
156
+ useExisting: forwardRef(() => CustomDateComponent),
157
+ multi: true,
158
+ },
159
+ ], viewQueries: [{ propertyName: "datePicker", first: true, predicate: ["datePicker"], descendants: true }], ngImport: i0, template: "<div\n class=\"form-item\"\n [ngClass]=\"{\n disabled: disabled,\n error: showError,\n 'form-item-date-focus': (isPickerOpen || inputValue) && !disabled\n }\"\n (click)=\"openPicker()\"\n>\n <nz-range-picker\n [(ngModel)]=\"inputValue\"\n (ngModelChange)=\"onDateChange($event)\"\n (nzOnOpenChange)=\"onOpenChange($event)\"\n [nzFormat]=\"'yyyy-MM-dd'\"\n [nzShowTime]=\"false\"\n [nzAllowClear]=\"false\"\n [nzPlaceHolder]=\"['From', 'To']\"\n class=\"form-item-date\"\n [nzDisabledDate]=\"disabledDate\"\n [nzDropdownClassName]=\"'form-item-date-popup'\"\n [nzSeparator]=\"'-'\"\n [nzDisabled]=\"disabled\"\n nzSuffixIcon=\"\"\n #datePicker\n nzBorderless\n nzPlacement=\"bottomRight\"\n [nzInputReadOnly]=\"true\"\n [ngClass]=\"{ 'form-item-date-hide': !inputValue?.length }\"\n ></nz-range-picker>\n\n <div class=\"form-item-label\">{{ label }}</div>\n\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n class=\"form-item-date-suffix-icon\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.60136 4.90777C2.83639 4.68743 3.20555 4.69934 3.42589 4.93437L8.00033 9.81377L12.5748 4.93437C12.7951 4.69934 13.1643 4.68743 13.3993 4.90777C13.6343 5.12812 13.6462 5.49727 13.4259 5.7323L8.42589 11.0656C8.31561 11.1833 8.16157 11.25 8.00033 11.25C7.83909 11.25 7.68504 11.1833 7.57476 11.0656L2.57476 5.7323C2.35442 5.49727 2.36633 5.12811 2.60136 4.90777Z\"\n fill=\"#030712\"\n />\n </svg>\n</div>\n<div *ngIf=\"showError\" class=\"form-item-error\">\n <img src=\"/assets/img/icon/icon-error.svg\" />\n {{ currentErrorMessage }}\n</div>\n", styles: ["@charset \"UTF-8\";.form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}.form-item.form-item-date-focus{cursor:text}.form-item.form-item-date-focus .form-item-label{top:16px;font-size:12px}.form-item .form-item-date{width:auto;padding:24px 16px 0}.form-item .form-item-date-hide{position:absolute;top:0;left:0;width:234px;height:100%;opacity:0}.form-item .form-item-label{cursor:text;pointer-events:none}.form-item .form-item-date-suffix-icon{position:absolute;top:50%;right:16px;transform:translateY(-50%)}::ng-deep .form-item-date .ant-picker-suffix svg{transition:transform .2s ease;cursor:pointer;pointer-events:initial}::ng-deep .form-item-date.ant-picker:hover,::ng-deep .form-item-date.ant-picker-focused{box-shadow:none;border-color:#367af6}::ng-deep .form-item-date .ant-picker-active-bar{display:none}::ng-deep .form-item-date .ant-picker-input input{field-sizing:content;font-weight:500}::ng-deep .form-item-date .ant-picker-separator{width:-moz-fit-content;width:fit-content}::ng-deep .date-picker-focus .ant-picker-suffix svg{pointer-events:none;transform:rotate(-180deg)}::ng-deep .form-item-date-popup.ant-picker-dropdown-range{padding:0}::ng-deep .form-item-date-popup .ant-picker-range-arrow{display:none}::ng-deep .form-item-date-popup .ant-picker-super-next-icon,::ng-deep .form-item-date-popup .ant-picker-header-next-btn,::ng-deep .form-item-date-popup .ant-picker-super-prev-icon,::ng-deep .form-item-date-popup .ant-picker-header-prev-btn{color:#030712}::ng-deep .form-item-date-popup .ant-picker-super-prev-icon:after,::ng-deep .form-item-date-popup .ant-picker-super-next-icon:after{top:2px;left:2px}::ng-deep .form-item-date-popup .ant-picker-header-view button{color:#030712;font-weight:500}::ng-deep .form-item-date-popup .ant-picker-panel-container{border-radius:4px}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-header{border-bottom:none}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-header-view{display:flex;flex-direction:row-reverse;justify-content:center;gap:8px}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-header .ant-picker-header-month-btn{order:2}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-header .ant-picker-header-year-btn{order:1}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-panel+.ant-picker-panel .ant-picker-body{border-left:1px solid #e5e7eb}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-body .ant-picker-cell{color:#9ca3af;font-weight:500}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-body .ant-picker-cell-in-view{color:#030712;font-weight:500}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-body th{color:#6b7280;font-weight:500}::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-in-range:before{background-color:#e9f0fd}::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-selected .ant-picker-cell-inner,::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-range-start .ant-picker-cell-inner,::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-range-end .ant-picker-cell-inner{border-radius:4px!important;background-color:#367af6}::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-today .ant-picker-cell-inner:before{border-radius:4px!important}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i3.NzDatePickerComponent, selector: "nz-date-picker,nz-week-picker,nz-month-picker,nz-year-picker,nz-range-picker", inputs: ["nzAllowClear", "nzAutoFocus", "nzDisabled", "nzBorderless", "nzInputReadOnly", "nzInline", "nzOpen", "nzDisabledDate", "nzLocale", "nzPlaceHolder", "nzPopupStyle", "nzDropdownClassName", "nzSize", "nzStatus", "nzFormat", "nzDateRender", "nzDisabledTime", "nzRenderExtraFooter", "nzShowToday", "nzMode", "nzShowNow", "nzRanges", "nzDefaultPickerValue", "nzSeparator", "nzSuffixIcon", "nzBackdrop", "nzId", "nzPlacement", "nzShowWeekNumber", "nzShowTime"], outputs: ["nzOnPanelChange", "nzOnCalendarChange", "nzOnOk", "nzOnOpenChange"], exportAs: ["nzDatePicker"] }, { kind: "directive", type: i3.NzRangePickerComponent, selector: "nz-range-picker", exportAs: ["nzRangePicker"] }] });
160
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomDateComponent, decorators: [{
161
+ type: Component,
162
+ args: [{ selector: 'app-rd-date', providers: [
163
+ {
164
+ provide: NG_VALUE_ACCESSOR,
165
+ useExisting: forwardRef(() => CustomDateComponent),
166
+ multi: true,
167
+ },
168
+ ], template: "<div\n class=\"form-item\"\n [ngClass]=\"{\n disabled: disabled,\n error: showError,\n 'form-item-date-focus': (isPickerOpen || inputValue) && !disabled\n }\"\n (click)=\"openPicker()\"\n>\n <nz-range-picker\n [(ngModel)]=\"inputValue\"\n (ngModelChange)=\"onDateChange($event)\"\n (nzOnOpenChange)=\"onOpenChange($event)\"\n [nzFormat]=\"'yyyy-MM-dd'\"\n [nzShowTime]=\"false\"\n [nzAllowClear]=\"false\"\n [nzPlaceHolder]=\"['From', 'To']\"\n class=\"form-item-date\"\n [nzDisabledDate]=\"disabledDate\"\n [nzDropdownClassName]=\"'form-item-date-popup'\"\n [nzSeparator]=\"'-'\"\n [nzDisabled]=\"disabled\"\n nzSuffixIcon=\"\"\n #datePicker\n nzBorderless\n nzPlacement=\"bottomRight\"\n [nzInputReadOnly]=\"true\"\n [ngClass]=\"{ 'form-item-date-hide': !inputValue?.length }\"\n ></nz-range-picker>\n\n <div class=\"form-item-label\">{{ label }}</div>\n\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n class=\"form-item-date-suffix-icon\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.60136 4.90777C2.83639 4.68743 3.20555 4.69934 3.42589 4.93437L8.00033 9.81377L12.5748 4.93437C12.7951 4.69934 13.1643 4.68743 13.3993 4.90777C13.6343 5.12812 13.6462 5.49727 13.4259 5.7323L8.42589 11.0656C8.31561 11.1833 8.16157 11.25 8.00033 11.25C7.83909 11.25 7.68504 11.1833 7.57476 11.0656L2.57476 5.7323C2.35442 5.49727 2.36633 5.12811 2.60136 4.90777Z\"\n fill=\"#030712\"\n />\n </svg>\n</div>\n<div *ngIf=\"showError\" class=\"form-item-error\">\n <img src=\"/assets/img/icon/icon-error.svg\" />\n {{ currentErrorMessage }}\n</div>\n", styles: ["@charset \"UTF-8\";.form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}.form-item.form-item-date-focus{cursor:text}.form-item.form-item-date-focus .form-item-label{top:16px;font-size:12px}.form-item .form-item-date{width:auto;padding:24px 16px 0}.form-item .form-item-date-hide{position:absolute;top:0;left:0;width:234px;height:100%;opacity:0}.form-item .form-item-label{cursor:text;pointer-events:none}.form-item .form-item-date-suffix-icon{position:absolute;top:50%;right:16px;transform:translateY(-50%)}::ng-deep .form-item-date .ant-picker-suffix svg{transition:transform .2s ease;cursor:pointer;pointer-events:initial}::ng-deep .form-item-date.ant-picker:hover,::ng-deep .form-item-date.ant-picker-focused{box-shadow:none;border-color:#367af6}::ng-deep .form-item-date .ant-picker-active-bar{display:none}::ng-deep .form-item-date .ant-picker-input input{field-sizing:content;font-weight:500}::ng-deep .form-item-date .ant-picker-separator{width:-moz-fit-content;width:fit-content}::ng-deep .date-picker-focus .ant-picker-suffix svg{pointer-events:none;transform:rotate(-180deg)}::ng-deep .form-item-date-popup.ant-picker-dropdown-range{padding:0}::ng-deep .form-item-date-popup .ant-picker-range-arrow{display:none}::ng-deep .form-item-date-popup .ant-picker-super-next-icon,::ng-deep .form-item-date-popup .ant-picker-header-next-btn,::ng-deep .form-item-date-popup .ant-picker-super-prev-icon,::ng-deep .form-item-date-popup .ant-picker-header-prev-btn{color:#030712}::ng-deep .form-item-date-popup .ant-picker-super-prev-icon:after,::ng-deep .form-item-date-popup .ant-picker-super-next-icon:after{top:2px;left:2px}::ng-deep .form-item-date-popup .ant-picker-header-view button{color:#030712;font-weight:500}::ng-deep .form-item-date-popup .ant-picker-panel-container{border-radius:4px}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-header{border-bottom:none}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-header-view{display:flex;flex-direction:row-reverse;justify-content:center;gap:8px}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-header .ant-picker-header-month-btn{order:2}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-header .ant-picker-header-year-btn{order:1}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-panel+.ant-picker-panel .ant-picker-body{border-left:1px solid #e5e7eb}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-body .ant-picker-cell{color:#9ca3af;font-weight:500}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-body .ant-picker-cell-in-view{color:#030712;font-weight:500}::ng-deep .form-item-date-popup .ant-picker-panel-container .ant-picker-body th{color:#6b7280;font-weight:500}::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-in-range:before{background-color:#e9f0fd}::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-selected .ant-picker-cell-inner,::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-range-start .ant-picker-cell-inner,::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-range-end .ant-picker-cell-inner{border-radius:4px!important;background-color:#367af6}::ng-deep .form-item-date-popup .ant-picker-cell-in-view.ant-picker-cell-today .ant-picker-cell-inner:before{border-radius:4px!important}\n"] }]
169
+ }], propDecorators: { disabled: [{
170
+ type: Input
171
+ }], disabledDate: [{
172
+ type: Input
173
+ }], label: [{
174
+ type: Input
175
+ }], datePicker: [{
176
+ type: ViewChild,
177
+ args: ['datePicker']
178
+ }] } });
179
+
180
+ class RdDateModule {
181
+ }
182
+ RdDateModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdDateModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
183
+ RdDateModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: RdDateModule, declarations: [CustomDateComponent], imports: [CommonModule, FormsModule, ReactiveFormsModule, NzDatePickerModule], exports: [CustomDateComponent] });
184
+ RdDateModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdDateModule, imports: [CommonModule, FormsModule, ReactiveFormsModule, NzDatePickerModule] });
185
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdDateModule, decorators: [{
186
+ type: NgModule,
187
+ args: [{
188
+ declarations: [CustomDateComponent],
189
+ imports: [CommonModule, FormsModule, ReactiveFormsModule, NzDatePickerModule],
190
+ exports: [CustomDateComponent],
191
+ }]
192
+ }] });
193
+
194
+ class CustomInputComponent {
195
+ get currentErrorMessage() {
196
+ var _a, _b, _c;
197
+ if (!this.errors)
198
+ return '';
199
+ const firstError = Object.keys(this.errors)[0];
200
+ if (firstError === 'required' && !((_a = this.errorMessages) === null || _a === void 0 ? void 0 : _a['required'])) {
201
+ return `Please enter ${this.label.toLowerCase()}`;
202
+ }
203
+ if (firstError === 'minLength' && !((_b = this.errorMessages) === null || _b === void 0 ? void 0 : _b['minLength'])) {
204
+ return `Length cannot be less than the minimum length ${this.minLength}`;
205
+ }
206
+ if (firstError === 'maxLength' && !((_c = this.errorMessages) === null || _c === void 0 ? void 0 : _c['maxLength'])) {
207
+ return `Length cannot exceed the maximum length ${this.maxLength}`;
208
+ }
209
+ return this.errorMessages[firstError] || 'Validation failed';
210
+ }
211
+ get showError() {
212
+ return this.touched && !!this.errors;
213
+ }
214
+ constructor(cdr) {
215
+ this.cdr = cdr;
216
+ this.label = '';
217
+ this.symbol = '';
218
+ this.name = '';
219
+ this.disabled = true;
220
+ this.maskNumber = 6;
221
+ this.maskType = 'text';
222
+ this.required = false;
223
+ this.type = 'text';
224
+ this.errorMessages = {
225
+ pattern: 'Invalid format',
226
+ custom: 'Validation failed',
227
+ };
228
+ this.valueChange = new EventEmitter();
229
+ this.focus = new EventEmitter();
230
+ this.blur = new EventEmitter();
231
+ this.value = '';
232
+ this.isFocused = false;
233
+ this.touched = false;
234
+ this.onChange = () => { };
235
+ this.onTouched = () => { };
236
+ this.control = null;
237
+ this.onValidatorChange = () => { };
238
+ this.errors = null;
239
+ }
240
+ writeValue(value) {
241
+ this.value = value;
242
+ this.validate(null);
243
+ }
244
+ registerOnChange(fn) {
245
+ this.onChange = fn;
246
+ }
247
+ registerOnTouched(fn) {
248
+ this.onTouched = fn;
249
+ }
250
+ setDisabledState(isDisabled) {
251
+ this.disabled = isDisabled;
252
+ this.cdr.markForCheck();
253
+ }
254
+ onBlur() {
255
+ this.isFocused = false;
256
+ this.touched = true;
257
+ this.onTouched();
258
+ this.blur.emit();
259
+ // 在失焦时重新验证
260
+ if (this.control) {
261
+ const errors = this.validate(this.control);
262
+ this.control.setErrors(errors);
263
+ if (this.onValidatorChange) {
264
+ this.onValidatorChange();
265
+ }
266
+ }
267
+ this.cdr.markForCheck();
268
+ }
269
+ handleValueChange(value) {
270
+ let currValue;
271
+ if (this.maskType === 'amount') {
272
+ currValue = value.replace(/,/g, '');
273
+ }
274
+ else {
275
+ currValue = (value === null || value === void 0 ? void 0 : value.trim()) || value;
276
+ }
277
+ this.value = currValue;
278
+ this.onChange(currValue);
279
+ this.valueChange.emit(currValue);
280
+ // 标记为已触摸
281
+ this.touched = true;
282
+ this.onTouched();
283
+ // 手动触发验证
284
+ if (this.control) {
285
+ // 设置错误状态
286
+ const errors = this.validate(this.control);
287
+ this.control.setErrors(errors);
288
+ // 通知验证器变化
289
+ if (this.onValidatorChange) {
290
+ this.onValidatorChange();
291
+ }
292
+ }
293
+ this.cdr.markForCheck();
294
+ }
295
+ // TODO: QX兼容angular原生校验
296
+ validate(control) {
297
+ var _a, _b;
298
+ if (!control)
299
+ return null;
300
+ const errors = {};
301
+ let value;
302
+ if (this.maskType === 'amount') {
303
+ value = (_a = control === null || control === void 0 ? void 0 : control.value) === null || _a === void 0 ? void 0 : _a.replace(/,/g, '');
304
+ }
305
+ else {
306
+ value = (_b = control === null || control === void 0 ? void 0 : control.value) === null || _b === void 0 ? void 0 : _b.trim();
307
+ }
308
+ // 必填验证
309
+ if (this.required && !value) {
310
+ errors['required'] = true;
311
+ }
312
+ // 长度验证
313
+ if (value && typeof value === 'string') {
314
+ if (this.minLength && value.length < this.minLength) {
315
+ errors['minLength'] = {
316
+ requiredLength: this.minLength,
317
+ actualLength: value.length,
318
+ };
319
+ }
320
+ if (this.maxLength && value.length > this.maxLength) {
321
+ errors['maxLength'] = {
322
+ requiredLength: this.maxLength,
323
+ actualLength: value.length,
324
+ };
325
+ }
326
+ }
327
+ // 正则验证
328
+ if (this.pattern && value) {
329
+ const pattern = this.pattern instanceof RegExp
330
+ ? this.pattern
331
+ : new RegExp(this.pattern);
332
+ if (!pattern.test(value)) {
333
+ errors['pattern'] = { requiredPattern: pattern, actualValue: value };
334
+ }
335
+ }
336
+ // 自定义验证
337
+ if (this.customValidator) {
338
+ const customErrors = this.customValidator(control);
339
+ if (customErrors) {
340
+ Object.assign(errors, customErrors);
341
+ }
342
+ }
343
+ this.errors = Object.keys(errors).length > 0 ? errors : null;
344
+ // 手动设置控件错误
345
+ if (this.errors) {
346
+ control.setErrors(this.errors);
347
+ }
348
+ return this.errors;
349
+ }
350
+ }
351
+ CustomInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomInputComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
352
+ CustomInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CustomInputComponent, selector: "app-rd-input", inputs: { label: "label", symbol: "symbol", name: "name", disabled: "disabled", maskNumber: "maskNumber", maskType: "maskType", required: "required", min: "min", max: "max", minLength: "minLength", maxLength: "maxLength", pattern: "pattern", customValidator: "customValidator", type: "type", errorMessages: "errorMessages" }, outputs: { valueChange: "valueChange", focus: "focus", blur: "blur" }, providers: [
353
+ {
354
+ provide: NG_VALUE_ACCESSOR,
355
+ useExisting: forwardRef(() => CustomInputComponent),
356
+ multi: true,
357
+ },
358
+ {
359
+ provide: NG_VALIDATORS,
360
+ useExisting: forwardRef(() => CustomInputComponent),
361
+ multi: true,
362
+ },
363
+ ], ngImport: i0, template: "<div>\n <div class=\"form-item\" [ngClass]=\"{ disabled: disabled, error: showError }\">\n <input\n nz-input\n nzBorderless\n placeholder=\" \"\n [name]=\"name\"\n [type]=\"type\"\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n (ngModelChange)=\"handleValueChange($event)\"\n (blur)=\"onBlur()\"\n [allowNegativeNumbers]=\"true\"\n [dropSpecialCharacters]=\"false\"\n [mask]=\"maskType === 'amount' ? 'separator.' + maskNumber : ''\"\n [thousandSeparator]=\"maskType === 'amount' ? ',' : ''\"\n class=\"form-item-input\"\n />\n <div class=\"form-item-label\">{{ label }}</div>\n </div>\n <div *ngIf=\"showError\" class=\"form-item-error\">\n <img src=\"/assets/img/icon/icon-error.svg\" />\n {{ currentErrorMessage }}\n </div>\n</div>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2$1.NzInputDirective, selector: "input[nz-input],textarea[nz-input]", inputs: ["nzBorderless", "nzSize", "nzStatus", "disabled"], exportAs: ["nzInput"] }, { kind: "directive", type: i4.NgxMaskDirective, selector: "input[mask], textarea[mask]", inputs: ["mask", "specialCharacters", "patterns", "prefix", "suffix", "thousandSeparator", "decimalMarker", "dropSpecialCharacters", "hiddenInput", "showMaskTyped", "placeHolderCharacter", "shownMaskExpression", "showTemplate", "clearIfNotMatch", "validation", "separatorLimit", "allowNegativeNumbers", "leadZeroDateTime", "leadZero", "triggerOnMaskChange", "apm", "inputTransformFn", "outputTransformFn", "keepCharacterPositions"], outputs: ["maskFilled"], exportAs: ["mask", "ngxMask"] }] });
364
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomInputComponent, decorators: [{
365
+ type: Component,
366
+ args: [{ selector: 'app-rd-input', providers: [
367
+ {
368
+ provide: NG_VALUE_ACCESSOR,
369
+ useExisting: forwardRef(() => CustomInputComponent),
370
+ multi: true,
371
+ },
372
+ {
373
+ provide: NG_VALIDATORS,
374
+ useExisting: forwardRef(() => CustomInputComponent),
375
+ multi: true,
376
+ },
377
+ ], template: "<div>\n <div class=\"form-item\" [ngClass]=\"{ disabled: disabled, error: showError }\">\n <input\n nz-input\n nzBorderless\n placeholder=\" \"\n [name]=\"name\"\n [type]=\"type\"\n [(ngModel)]=\"value\"\n [disabled]=\"disabled\"\n (ngModelChange)=\"handleValueChange($event)\"\n (blur)=\"onBlur()\"\n [allowNegativeNumbers]=\"true\"\n [dropSpecialCharacters]=\"false\"\n [mask]=\"maskType === 'amount' ? 'separator.' + maskNumber : ''\"\n [thousandSeparator]=\"maskType === 'amount' ? ',' : ''\"\n class=\"form-item-input\"\n />\n <div class=\"form-item-label\">{{ label }}</div>\n </div>\n <div *ngIf=\"showError\" class=\"form-item-error\">\n <img src=\"/assets/img/icon/icon-error.svg\" />\n {{ currentErrorMessage }}\n </div>\n</div>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}\n"] }]
378
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { label: [{
379
+ type: Input
380
+ }], symbol: [{
381
+ type: Input
382
+ }], name: [{
383
+ type: Input
384
+ }], disabled: [{
385
+ type: Input
386
+ }], maskNumber: [{
387
+ type: Input
388
+ }], maskType: [{
389
+ type: Input
390
+ }], required: [{
391
+ type: Input
392
+ }], min: [{
393
+ type: Input
394
+ }], max: [{
395
+ type: Input
396
+ }], minLength: [{
397
+ type: Input
398
+ }], maxLength: [{
399
+ type: Input
400
+ }], pattern: [{
401
+ type: Input
402
+ }], customValidator: [{
403
+ type: Input
404
+ }], type: [{
405
+ type: Input
406
+ }], errorMessages: [{
407
+ type: Input
408
+ }], valueChange: [{
409
+ type: Output
410
+ }], focus: [{
411
+ type: Output
412
+ }], blur: [{
413
+ type: Output
414
+ }] } });
415
+
416
+ class RdInputModule {
417
+ }
418
+ RdInputModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdInputModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
419
+ RdInputModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: RdInputModule, declarations: [CustomInputComponent], imports: [CommonModule,
420
+ ReactiveFormsModule,
421
+ FormsModule,
422
+ NzInputModule,
423
+ NgxMaskModule], exports: [CustomInputComponent] });
424
+ RdInputModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdInputModule, imports: [CommonModule,
425
+ ReactiveFormsModule,
426
+ FormsModule,
427
+ NzInputModule,
428
+ NgxMaskModule] });
429
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdInputModule, decorators: [{
430
+ type: NgModule,
431
+ args: [{
432
+ declarations: [CustomInputComponent],
433
+ imports: [
434
+ CommonModule,
435
+ ReactiveFormsModule,
436
+ FormsModule,
437
+ NzInputModule,
438
+ NgxMaskModule,
439
+ ],
440
+ exports: [CustomInputComponent],
441
+ }]
442
+ }] });
443
+
444
+ function formatBigNumber(value, precision = 6, mode = 'cut') {
445
+ if (!value)
446
+ return '';
447
+ try {
448
+ const bigValue = new Big(value);
449
+ let fixedValue = '';
450
+ switch (mode) {
451
+ case 'keepAll':
452
+ fixedValue = bigValue.toString();
453
+ break;
454
+ default:
455
+ // 如果 precision 是 null,则转为 undefined
456
+ const roundPrecision = precision === null ? undefined : precision;
457
+ fixedValue = bigValue
458
+ .round(roundPrecision, 0)
459
+ .toFixed(precision === null ? 0 : precision);
460
+ if (mode === 'cut') {
461
+ fixedValue = fixedValue.replace(/\.?0+$/, '');
462
+ }
463
+ break;
464
+ }
465
+ const parts = fixedValue.split('.');
466
+ const integerPart = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, ',');
467
+ const decimalPart = parts[1] ? '.' + parts[1] : '';
468
+ return integerPart + decimalPart;
469
+ }
470
+ catch (error) {
471
+ console.error('Invalid number format:', value);
472
+ return `${value}`;
473
+ }
474
+ }
475
+ function numberToBig(value, precision = 6, mode = 'cut') {
476
+ if (!value)
477
+ return '';
478
+ const fixedValue = new Big(value).round(precision, 0).toFixed(precision);
479
+ if (mode === 'toFixed') {
480
+ return fixedValue;
481
+ }
482
+ return fixedValue.replace(/\.?0+$/, '');
483
+ }
484
+
485
+ class CustomInputAmountComponent {
486
+ constructor(cdr) {
487
+ this.cdr = cdr;
488
+ this.label = '';
489
+ this.symbol = '';
490
+ this.name = '';
491
+ this.disabled = false;
492
+ this.nzPrecision = 6;
493
+ this.required = true;
494
+ this.errorMessages = {
495
+ invalid: 'Please enter a valid number',
496
+ };
497
+ this.valueChange = new EventEmitter();
498
+ this.inputValue = ''; // 绑定到输入框
499
+ this.value = ''; // 内部值,始终以 string 形式存储
500
+ this.touched = false;
501
+ this.control = null;
502
+ this.errors = null;
503
+ this.onChange = () => { };
504
+ this.onTouched = () => { };
505
+ this.onValidatorChange = () => { };
506
+ }
507
+ get currentErrorMessage() {
508
+ var _a, _b, _c, _d;
509
+ if (!this.errors)
510
+ return '';
511
+ const firstError = Object.keys(this.errors)[0];
512
+ switch (firstError) {
513
+ case 'required':
514
+ return (((_a = this.errorMessages) === null || _a === void 0 ? void 0 : _a['required']) ||
515
+ `Please enter ${this.label.toLowerCase()}`);
516
+ case 'min':
517
+ return (((_b = this.errorMessages) === null || _b === void 0 ? void 0 : _b['min']) ||
518
+ `${this.label} cannot be less than the minimum value ${formatBigNumber(this.min)}`);
519
+ case 'max':
520
+ return (((_c = this.errorMessages) === null || _c === void 0 ? void 0 : _c['max']) ||
521
+ `${this.label} cannot exceed the maximum value ${formatBigNumber(this.max)}`);
522
+ case 'precision':
523
+ return (((_d = this.errorMessages) === null || _d === void 0 ? void 0 : _d['precision']) ||
524
+ `The maximum number of decimal places is ${this.nzPrecision}`);
525
+ default:
526
+ return this.errorMessages[firstError] || 'Validation failed';
527
+ }
528
+ }
529
+ get showError() {
530
+ return this.touched && !!this.errors;
531
+ }
532
+ handleValueChange(value) {
533
+ const rawValue = value.replace(/,/g, '');
534
+ // 处理输入的值,转换成 Big.js 格式
535
+ this.value = numberToBig(rawValue, this.nzPrecision);
536
+ // 更新绑定值
537
+ this.onChange(this.value);
538
+ this.valueChange.emit(this.value);
539
+ this.touched = true;
540
+ this.onTouched();
541
+ if (this.control) {
542
+ const errors = this.validate(this.control);
543
+ this.control.setErrors(errors);
544
+ this.onValidatorChange();
545
+ }
546
+ this.cdr.markForCheck();
547
+ }
548
+ onBlur() {
549
+ this.touched = true;
550
+ this.onTouched();
551
+ if (this.control) {
552
+ const errors = this.validate(this.control);
553
+ this.control.setErrors(errors);
554
+ this.onValidatorChange();
555
+ }
556
+ this.cdr.markForCheck();
557
+ }
558
+ registerOnChange(fn) {
559
+ this.onChange = fn;
560
+ }
561
+ registerOnTouched(fn) {
562
+ this.onTouched = fn;
563
+ }
564
+ setDisabledState(isDisabled) {
565
+ this.disabled = isDisabled;
566
+ this.cdr.markForCheck();
567
+ }
568
+ registerOnValidatorChange(fn) {
569
+ this.onValidatorChange = fn;
570
+ }
571
+ validate(control) {
572
+ this.control = control;
573
+ const errors = {};
574
+ const value = this.value;
575
+ if (this.required && !value) {
576
+ errors['required'] = true;
577
+ }
578
+ if (value) {
579
+ try {
580
+ const bigValue = new Big(value);
581
+ if (this.min && !Number.isNaN(this.min) && bigValue.lt(this.min)) {
582
+ errors['min'] = { min: this.min, actual: value };
583
+ }
584
+ if (this.max && !Number.isNaN(this.max) && bigValue.gt(this.max)) {
585
+ errors['max'] = { max: this.max, actual: value };
586
+ }
587
+ }
588
+ catch (error) {
589
+ errors['invalid'] = true;
590
+ }
591
+ }
592
+ this.errors = Object.keys(errors).length > 0 ? errors : null;
593
+ if (this.errors) {
594
+ control.setErrors(this.errors);
595
+ }
596
+ return this.errors;
597
+ }
598
+ writeValue(value) {
599
+ this.value = value;
600
+ this.inputValue = this.value;
601
+ this.cdr.markForCheck();
602
+ }
603
+ }
604
+ CustomInputAmountComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomInputAmountComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
605
+ CustomInputAmountComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CustomInputAmountComponent, selector: "app-rd-input-amount", inputs: { label: "label", symbol: "symbol", name: "name", disabled: "disabled", min: "min", max: "max", nzPrecision: "nzPrecision", required: "required", errorMessages: "errorMessages" }, outputs: { valueChange: "valueChange" }, providers: [
606
+ {
607
+ provide: NG_VALUE_ACCESSOR,
608
+ useExisting: forwardRef(() => CustomInputAmountComponent),
609
+ multi: true,
610
+ },
611
+ {
612
+ provide: NG_VALIDATORS,
613
+ useExisting: forwardRef(() => CustomInputAmountComponent),
614
+ multi: true,
615
+ },
616
+ ], ngImport: i0, template: "<div>\n <div\n class=\"form-number-item\"\n [ngClass]=\"{ disabled: disabled, error: showError }\"\n >\n <div class=\"item-label\">{{ label }}</div>\n <div class=\"item-content\">\n <input\n nz-input\n [name]=\"name\"\n type=\"text\"\n [placeholder]=\"'0'\"\n [mask]=\"'separator.' + nzPrecision\"\n [thousandSeparator]=\"','\"\n [allowNegativeNumbers]=\"true\"\n [dropSpecialCharacters]=\"false\"\n [(ngModel)]=\"inputValue\"\n [disabled]=\"disabled\"\n (ngModelChange)=\"handleValueChange($event)\"\n (blur)=\"onBlur()\"\n class=\"item-content-value\"\n />\n <div class=\"item-content-symbol\">{{ symbol }}</div>\n </div>\n <ng-content></ng-content>\n </div>\n <div *ngIf=\"showError\" class=\"form-item-error\">\n <img src=\"/assets/img/icon/icon-error.svg\" />\n {{ currentErrorMessage }}\n </div>\n</div>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2$1.NzInputDirective, selector: "input[nz-input],textarea[nz-input]", inputs: ["nzBorderless", "nzSize", "nzStatus", "disabled"], exportAs: ["nzInput"] }, { kind: "directive", type: i4.NgxMaskDirective, selector: "input[mask], textarea[mask]", inputs: ["mask", "specialCharacters", "patterns", "prefix", "suffix", "thousandSeparator", "decimalMarker", "dropSpecialCharacters", "hiddenInput", "showMaskTyped", "placeHolderCharacter", "shownMaskExpression", "showTemplate", "clearIfNotMatch", "validation", "separatorLimit", "allowNegativeNumbers", "leadZeroDateTime", "leadZero", "triggerOnMaskChange", "apm", "inputTransformFn", "outputTransformFn", "keepCharacterPositions"], outputs: ["maskFilled"], exportAs: ["mask", "ngxMask"] }] });
617
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomInputAmountComponent, decorators: [{
618
+ type: Component,
619
+ args: [{ selector: 'app-rd-input-amount', providers: [
620
+ {
621
+ provide: NG_VALUE_ACCESSOR,
622
+ useExisting: forwardRef(() => CustomInputAmountComponent),
623
+ multi: true,
624
+ },
625
+ {
626
+ provide: NG_VALIDATORS,
627
+ useExisting: forwardRef(() => CustomInputAmountComponent),
628
+ multi: true,
629
+ },
630
+ ], template: "<div>\n <div\n class=\"form-number-item\"\n [ngClass]=\"{ disabled: disabled, error: showError }\"\n >\n <div class=\"item-label\">{{ label }}</div>\n <div class=\"item-content\">\n <input\n nz-input\n [name]=\"name\"\n type=\"text\"\n [placeholder]=\"'0'\"\n [mask]=\"'separator.' + nzPrecision\"\n [thousandSeparator]=\"','\"\n [allowNegativeNumbers]=\"true\"\n [dropSpecialCharacters]=\"false\"\n [(ngModel)]=\"inputValue\"\n [disabled]=\"disabled\"\n (ngModelChange)=\"handleValueChange($event)\"\n (blur)=\"onBlur()\"\n class=\"item-content-value\"\n />\n <div class=\"item-content-symbol\">{{ symbol }}</div>\n </div>\n <ng-content></ng-content>\n </div>\n <div *ngIf=\"showError\" class=\"form-item-error\">\n <img src=\"/assets/img/icon/icon-error.svg\" />\n {{ currentErrorMessage }}\n </div>\n</div>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}\n"] }]
631
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { label: [{
632
+ type: Input
633
+ }], symbol: [{
634
+ type: Input
635
+ }], name: [{
636
+ type: Input
637
+ }], disabled: [{
638
+ type: Input
639
+ }], min: [{
640
+ type: Input
641
+ }], max: [{
642
+ type: Input
643
+ }], nzPrecision: [{
644
+ type: Input
645
+ }], required: [{
646
+ type: Input
647
+ }], errorMessages: [{
648
+ type: Input
649
+ }], valueChange: [{
650
+ type: Output
651
+ }] } });
652
+
653
+ class RdInputAmountModule {
654
+ }
655
+ RdInputAmountModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdInputAmountModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
656
+ RdInputAmountModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: RdInputAmountModule, declarations: [CustomInputAmountComponent], imports: [CommonModule,
657
+ ReactiveFormsModule,
658
+ FormsModule,
659
+ NzInputModule,
660
+ NgxMaskModule], exports: [CustomInputAmountComponent] });
661
+ RdInputAmountModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdInputAmountModule, imports: [CommonModule,
662
+ ReactiveFormsModule,
663
+ FormsModule,
664
+ NzInputModule,
665
+ NgxMaskModule] });
666
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdInputAmountModule, decorators: [{
667
+ type: NgModule,
668
+ args: [{
669
+ declarations: [CustomInputAmountComponent],
670
+ imports: [
671
+ CommonModule,
672
+ ReactiveFormsModule,
673
+ FormsModule,
674
+ NzInputModule,
675
+ NgxMaskModule,
676
+ ],
677
+ exports: [CustomInputAmountComponent],
678
+ }]
679
+ }] });
680
+
681
+ class CustomRadioComponent {
682
+ set options(val) {
683
+ this._rawOptions = val;
684
+ }
685
+ get options() {
686
+ return this._rawOptions;
687
+ }
688
+ constructor(cdr) {
689
+ this.cdr = cdr;
690
+ this.label = '';
691
+ this.name = '';
692
+ this.disabled = false;
693
+ this.valueChange = new EventEmitter();
694
+ this._rawOptions = [];
695
+ this.value = undefined;
696
+ this.nativeValue = undefined;
697
+ this.onChange = () => { };
698
+ this.onTouched = () => { };
699
+ }
700
+ setDisabledState(isDisabled) {
701
+ this.disabled = isDisabled;
702
+ this.cdr.markForCheck();
703
+ }
704
+ writeValue(value) {
705
+ this.value = value;
706
+ this.nativeValue = value === null || value === void 0 ? void 0 : value.value;
707
+ }
708
+ registerOnChange(fn) {
709
+ this.onChange = fn;
710
+ }
711
+ registerOnTouched(fn) {
712
+ this.onTouched = fn;
713
+ }
714
+ handleValueChange(value) {
715
+ this.nativeValue = value;
716
+ this.value = this.options.find((item) => item.value === value);
717
+ this.onChange(this.value);
718
+ this.valueChange.emit(this.value);
719
+ }
720
+ }
721
+ CustomRadioComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomRadioComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
722
+ CustomRadioComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CustomRadioComponent, selector: "app-rd-radio", inputs: { label: "label", name: "name", disabled: "disabled", options: "options" }, outputs: { valueChange: "valueChange" }, providers: [
723
+ {
724
+ provide: NG_VALUE_ACCESSOR,
725
+ useExisting: forwardRef(() => CustomRadioComponent),
726
+ multi: true,
727
+ },
728
+ ], ngImport: i0, template: "<div>\n <div\n class=\"form-item-check\"\n [ngClass]=\"{\n disabled: disabled\n }\"\n >\n <div class=\"desc-14 m-b-8\">{{ label }}</div>\n <nz-radio-group\n [(ngModel)]=\"nativeValue\"\n (ngModelChange)=\"handleValueChange($event)\"\n >\n <label *ngFor=\"let option of options\" nz-radio [nzValue]=\"option.value\">\n {{ option.label }}\n </label>\n </nz-radio-group>\n </div>\n</div>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}::ng-deep .ant-radio-group{display:flex}::ng-deep .ant-radio-group label{flex:1}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i3$1.NzRadioComponent, selector: "[nz-radio],[nz-radio-button]", inputs: ["nzValue", "nzDisabled", "nzAutoFocus"], exportAs: ["nzRadio"] }, { kind: "component", type: i3$1.NzRadioGroupComponent, selector: "nz-radio-group", inputs: ["nzDisabled", "nzButtonStyle", "nzSize", "nzName"], exportAs: ["nzRadioGroup"] }] });
729
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomRadioComponent, decorators: [{
730
+ type: Component,
731
+ args: [{ selector: 'app-rd-radio', providers: [
732
+ {
733
+ provide: NG_VALUE_ACCESSOR,
734
+ useExisting: forwardRef(() => CustomRadioComponent),
735
+ multi: true,
736
+ },
737
+ ], template: "<div>\n <div\n class=\"form-item-check\"\n [ngClass]=\"{\n disabled: disabled\n }\"\n >\n <div class=\"desc-14 m-b-8\">{{ label }}</div>\n <nz-radio-group\n [(ngModel)]=\"nativeValue\"\n (ngModelChange)=\"handleValueChange($event)\"\n >\n <label *ngFor=\"let option of options\" nz-radio [nzValue]=\"option.value\">\n {{ option.label }}\n </label>\n </nz-radio-group>\n </div>\n</div>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}::ng-deep .ant-radio-group{display:flex}::ng-deep .ant-radio-group label{flex:1}\n"] }]
738
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { label: [{
739
+ type: Input
740
+ }], name: [{
741
+ type: Input
742
+ }], disabled: [{
743
+ type: Input
744
+ }], options: [{
745
+ type: Input
746
+ }], valueChange: [{
747
+ type: Output
748
+ }] } });
749
+
750
+ class RdRadioModule {
751
+ }
752
+ RdRadioModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdRadioModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
753
+ RdRadioModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: RdRadioModule, declarations: [CustomRadioComponent], imports: [CommonModule,
754
+ FormsModule,
755
+ ReactiveFormsModule,
756
+ NzSpinModule,
757
+ NzRadioModule], exports: [CustomRadioComponent] });
758
+ RdRadioModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdRadioModule, imports: [CommonModule,
759
+ FormsModule,
760
+ ReactiveFormsModule,
761
+ NzSpinModule,
762
+ NzRadioModule] });
763
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdRadioModule, decorators: [{
764
+ type: NgModule,
765
+ args: [{
766
+ declarations: [CustomRadioComponent],
767
+ imports: [
768
+ CommonModule,
769
+ FormsModule,
770
+ ReactiveFormsModule,
771
+ NzSpinModule,
772
+ NzRadioModule,
773
+ ],
774
+ exports: [CustomRadioComponent],
775
+ }]
776
+ }] });
777
+
778
+ class CustomSelectComponent {
779
+ set options(val) {
780
+ this._rawOptions = val;
781
+ this.filteredOptions = val;
782
+ }
783
+ get options() {
784
+ return this._rawOptions;
785
+ }
786
+ constructor(cdr) {
787
+ this.cdr = cdr;
788
+ this.label = '';
789
+ this.name = '';
790
+ this.disabled = false;
791
+ this.nzMode = 'default';
792
+ this.isLoading = false;
793
+ this.isShowSearch = false;
794
+ this.isRemoteSearch = false;
795
+ this.searchChange = new EventEmitter();
796
+ this.valueChange = new EventEmitter();
797
+ this.scrollToBottomEmit = new EventEmitter();
798
+ this._rawOptions = [];
799
+ this.filteredOptions = [];
800
+ this.value = undefined;
801
+ this.nativeValue = undefined;
802
+ this.searchInput = '';
803
+ this.onChange = () => { };
804
+ this.onTouched = () => { };
805
+ this.isFocus = false;
806
+ }
807
+ setDisabledState(isDisabled) {
808
+ this.disabled = isDisabled;
809
+ this.cdr.markForCheck();
810
+ }
811
+ writeValue(value) {
812
+ if (Array.isArray(value)) {
813
+ this.value = value;
814
+ this.nativeValue = value.map((item) => item.value);
815
+ return;
816
+ }
817
+ this.value = value;
818
+ this.nativeValue = value === null || value === void 0 ? void 0 : value.value;
819
+ }
820
+ registerOnChange(fn) {
821
+ this.onChange = fn;
822
+ }
823
+ registerOnTouched(fn) {
824
+ this.onTouched = fn;
825
+ }
826
+ handleValueChange(value) {
827
+ this.nativeValue = value;
828
+ if (Array.isArray(value)) {
829
+ this.value = this.options.filter((item) => value.includes(item.value));
830
+ }
831
+ else {
832
+ this.value = this.options.find((item) => item.value === value);
833
+ }
834
+ this.onChange(this.value);
835
+ this.valueChange.emit(this.value);
836
+ }
837
+ onScrollToBottom() {
838
+ if (!this.isLoading) {
839
+ this.scrollToBottomEmit.emit();
840
+ }
841
+ }
842
+ onSearch(searchValue) {
843
+ this.searchInput = searchValue;
844
+ if (this.isRemoteSearch) {
845
+ this.searchChange.emit(searchValue);
846
+ return;
847
+ }
848
+ const lower = searchValue.toLowerCase();
849
+ this.filteredOptions = this._rawOptions.filter((item) => { var _a; return (_a = item.name) === null || _a === void 0 ? void 0 : _a.toLowerCase().includes(lower); });
850
+ }
851
+ }
852
+ CustomSelectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomSelectComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
853
+ CustomSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CustomSelectComponent, selector: "app-rd-select", inputs: { label: "label", customTpl: "customTpl", optionTpl: "optionTpl", name: "name", disabled: "disabled", nzMode: "nzMode", isCurrency: "isCurrency", currencyUrlMap: "currencyUrlMap", isLoading: "isLoading", isShowSearch: "isShowSearch", isRemoteSearch: "isRemoteSearch", options: "options" }, outputs: { searchChange: "searchChange", valueChange: "valueChange", scrollToBottomEmit: "scrollToBottomEmit" }, providers: [
854
+ {
855
+ provide: NG_VALUE_ACCESSOR,
856
+ useExisting: forwardRef(() => CustomSelectComponent),
857
+ multi: true,
858
+ },
859
+ ], ngImport: i0, template: "<div\n class=\"form-item\"\n [ngClass]=\"{\n selected: !!nativeValue || !!searchInput || isFocus,\n disabled: disabled\n }\"\n>\n <nz-select\n class=\"form-item-select\"\n nzBorderless\n [nzMode]=\"nzMode\"\n [nzShowArrow]=\"false\"\n [(ngModel)]=\"nativeValue\"\n [nzCustomTemplate]=\"\n customTpl\n ? customTpl\n : isCurrency\n ? currencySelectedTpl\n : defaultSelectedTpl\n \"\n (nzScrollToBottom)=\"onScrollToBottom()\"\n (ngModelChange)=\"handleValueChange($event)\"\n [disabled]=\"disabled\"\n (nzFocus)=\"isFocus = true\"\n (nzBlur)=\"isFocus = false\"\n [nzDropdownClassName]=\"\n nzMode === 'multiple'\n ? 'form-item-multiple-select-dropdown'\n : 'form-item-select-dropdown'\n \"\n [nzOptionOverflowSize]=\"5\"\n [nzOptionHeightPx]=\"40\"\n [nzSuffixIcon]=\"customIcon\"\n [nzRemoveIcon]=\"removeIcon\"\n [nzMaxTagCount]=\"3\"\n [nzShowSearch]=\"isShowSearch\"\n (nzOnSearch)=\"onSearch($event)\"\n >\n <nz-option\n *ngFor=\"let option of filteredOptions\"\n [nzValue]=\"option.value\"\n [nzLabel]=\"option.name || ''\"\n [nzCustomContent]=\"true\"\n >\n <ng-container *ngIf=\"optionTpl || isCurrency\">\n <ng-container\n *ngTemplateOutlet=\"\n isCurrency ? currencyOptionTpl : optionTpl;\n context: { $implicit: option }\n \"\n ></ng-container>\n </ng-container>\n <ng-container *ngIf=\"!(optionTpl || isCurrency)\">\n {{ option.name }}\n </ng-container>\n </nz-option>\n <nz-option *ngIf=\"isLoading\" nzDisabled nzCustomContent>\n <nz-spin style=\"padding: 16px 0\"></nz-spin>\n </nz-option>\n </nz-select>\n\n <div class=\"form-item-label\">{{ label }}</div>\n <svg\n class=\"form-item-select-icon\"\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"17\"\n viewBox=\"0 0 16 17\"\n fill=\"none\"\n >\n <path\n d=\"M3 5.83337L8 11.1667L13 5.83337\"\n [attr.stroke]=\"disabled ? '#9CA3AF' : '#030712'\"\n stroke-width=\"1.16667\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n</div>\n\n<ng-template #defaultSelectedTpl let-selected>\n {{ selected?.nzLabel }}\n</ng-template>\n\n<ng-template #currencyOptionTpl let-option>\n <div class=\"form-item-option-content\">\n <img [src]=\"option.iconUrl\" class=\"currency-icon\" alt=\"icon\" />\n <span>{{ option.name }}</span>\n </div>\n</ng-template>\n\n<ng-template #currencySelectedTpl let-selected let-extra>\n <div class=\"form-item-option-content\">\n <img\n [src]=\"currencyUrlMap?.[selected.nzValue]\"\n class=\"currency-icon\"\n alt=\"icon\"\n />\n <span>{{ selected.nzLabel }}</span>\n </div>\n</ng-template>\n\n<ng-template #removeIcon>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 12 12\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.39645 2.39645C2.59171 2.20118 2.90829 2.20118 3.10355 2.39645L6 5.29289L8.89645 2.39645C9.09171 2.20118 9.40829 2.20118 9.60355 2.39645C9.79882 2.59171 9.79882 2.90829 9.60355 3.10355L6.70711 6L9.60355 8.89645C9.79882 9.09171 9.79882 9.40829 9.60355 9.60355C9.40829 9.79882 9.09171 9.79882 8.89645 9.60355L6 6.70711L3.10355 9.60355C2.90829 9.79882 2.59171 9.79882 2.39645 9.60355C2.20118 9.40829 2.20118 9.09171 2.39645 8.89645L5.29289 6L2.39645 3.10355C2.20118 2.90829 2.20118 2.59171 2.39645 2.39645Z\"\n fill=\"#030712\"\n />\n </svg>\n</ng-template>\n\n<ng-template #customIcon>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.60136 4.90777C2.83639 4.68743 3.20555 4.69934 3.42589 4.93437L8.00033 9.81377L12.5748 4.93437C12.7951 4.69934 13.1643 4.68743 13.3993 4.90777C13.6343 5.12812 13.6462 5.49727 13.4259 5.7323L8.42589 11.0656C8.31561 11.1833 8.16157 11.25 8.00033 11.25C7.83909 11.25 7.68504 11.1833 7.57476 11.0656L2.57476 5.7323C2.35442 5.49727 2.36633 5.12811 2.60136 4.90777Z\"\n fill=\"#030712\"\n />\n </svg>\n</ng-template>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}.form-item-select{min-width:113px;min-height:32px}.form-item-select.ant-select-multiple .ant-select-selection-search{margin-inline-start:0}.form-item-select .ant-select-selection-search .ant-select-selection-search-input{padding:12px 4px 0}.form-item-select.ant-select-single:not(.ant-select-customize-input) .ant-select-selector{padding:12px 16px 0;height:48px}.form-item-select.ant-select .ant-select-selection-item{color:#030712;font-weight:500;font-size:14px}.form-item-select .ant-select-selector{padding:12px 16px}.form-item-select.ant-select-multiple .ant-select-selection-item{border-radius:4px;background:#f3f4f6;font-size:14px;font-weight:500;color:#030712;display:flex;align-items:center;gap:4px}.form-item-select.ant-select-multiple .ant-select-selection-item .ant-select-selection-item-remove{line-height:1}.form-item-select:not(.ant-select-customize-input) .ant-select-selector{border-radius:4px}.form-item-select.ant-select-focused:not(.ant-select-disabled).ant-select:not(.ant-select-customize-input) .ant-select-selector{border-radius:4px;border:1px solid #367af6;background:#fff;box-shadow:0 0 0 2px #367af61a}.form-item-select .ant-select-selection-placeholder{color:#030712;font-weight:500;font-size:14px}.form-item-select .ant-select-selection-item-content{color:#030712;font-weight:500}.form-item-select .ant-select-arrow{transition:ease-in-out .2s all;cursor:pointer;pointer-events:initial}.form-item-select:hover:has(.ant-select-clear) .ant-select-arrow{opacity:0}.form-item-select.ant-select-focused .ant-select-arrow,.form-item-select .ant-select-selector:focus-within .ant-select-arrow{transform:rotate(-180deg);transition:transform .2s ease}.form-item-select-dropdown .ant-select-dropdown,.form-item-multiple-select-dropdown .ant-select-dropdown{border-radius:4px;background:#fff;min-width:113px}.form-item-select-dropdown .ant-select-item-option,.form-item-multiple-select-dropdown .ant-select-item-option{background-color:transparent;padding:0 6px}.form-item-select-dropdown .ant-select-item-option-content,.form-item-multiple-select-dropdown .ant-select-item-option-content{border-radius:4px;padding:0 6px;display:flex;align-items:center;color:#030712;font-size:14px;min-height:40px}.form-item-select-dropdown .ant-select-item-option-active .ant-select-item-option-content,.form-item-multiple-select-dropdown .ant-select-item-option-active .ant-select-item-option-content{background:rgba(54,122,246,.1)}.form-item-multiple-select-dropdown .ant-select-item-option-content{border-radius:4px;font-weight:500;color:#030712;font-size:14px;padding:0 6px 0 32px;position:relative}.form-item-multiple-select-dropdown .ant-select-item-option-content:before{content:\"\";position:absolute;top:50%;left:6px;width:16px;height:16px;transform:translateY(-50%);border-radius:4px;border:1px solid #9ca3af}.form-item-multiple-select-dropdown .ant-select-item-option-selected .ant-select-item-option-content:before{background-image:url(/assets/img/icon/checkbox.svg);background-size:contain;background-position:center;background-repeat:no-repeat;border:none}.form-item-multiple-select-dropdown .ant-select-item-option-state{display:none}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i3$2.NzSpinComponent, selector: "nz-spin", inputs: ["nzIndicator", "nzSize", "nzTip", "nzDelay", "nzSimple", "nzSpinning"], exportAs: ["nzSpin"] }, { kind: "component", type: i4$1.NzOptionComponent, selector: "nz-option", inputs: ["nzLabel", "nzValue", "nzDisabled", "nzHide", "nzCustomContent"], exportAs: ["nzOption"] }, { kind: "component", type: i4$1.NzSelectComponent, selector: "nz-select", inputs: ["nzId", "nzSize", "nzStatus", "nzOptionHeightPx", "nzOptionOverflowSize", "nzDropdownClassName", "nzDropdownMatchSelectWidth", "nzDropdownStyle", "nzNotFoundContent", "nzPlaceHolder", "nzPlacement", "nzMaxTagCount", "nzDropdownRender", "nzCustomTemplate", "nzSuffixIcon", "nzClearIcon", "nzRemoveIcon", "nzMenuItemSelectedIcon", "nzTokenSeparators", "nzMaxTagPlaceholder", "nzMaxMultipleCount", "nzMode", "nzFilterOption", "compareWith", "nzAllowClear", "nzBorderless", "nzShowSearch", "nzLoading", "nzAutoFocus", "nzAutoClearSearchValue", "nzServerSearch", "nzDisabled", "nzOpen", "nzSelectOnTab", "nzBackdrop", "nzOptions", "nzShowArrow"], outputs: ["nzOnSearch", "nzScrollToBottom", "nzOpenChange", "nzBlur", "nzFocus"], exportAs: ["nzSelect"] }] });
860
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CustomSelectComponent, decorators: [{
861
+ type: Component,
862
+ args: [{ selector: 'app-rd-select', providers: [
863
+ {
864
+ provide: NG_VALUE_ACCESSOR,
865
+ useExisting: forwardRef(() => CustomSelectComponent),
866
+ multi: true,
867
+ },
868
+ ], template: "<div\n class=\"form-item\"\n [ngClass]=\"{\n selected: !!nativeValue || !!searchInput || isFocus,\n disabled: disabled\n }\"\n>\n <nz-select\n class=\"form-item-select\"\n nzBorderless\n [nzMode]=\"nzMode\"\n [nzShowArrow]=\"false\"\n [(ngModel)]=\"nativeValue\"\n [nzCustomTemplate]=\"\n customTpl\n ? customTpl\n : isCurrency\n ? currencySelectedTpl\n : defaultSelectedTpl\n \"\n (nzScrollToBottom)=\"onScrollToBottom()\"\n (ngModelChange)=\"handleValueChange($event)\"\n [disabled]=\"disabled\"\n (nzFocus)=\"isFocus = true\"\n (nzBlur)=\"isFocus = false\"\n [nzDropdownClassName]=\"\n nzMode === 'multiple'\n ? 'form-item-multiple-select-dropdown'\n : 'form-item-select-dropdown'\n \"\n [nzOptionOverflowSize]=\"5\"\n [nzOptionHeightPx]=\"40\"\n [nzSuffixIcon]=\"customIcon\"\n [nzRemoveIcon]=\"removeIcon\"\n [nzMaxTagCount]=\"3\"\n [nzShowSearch]=\"isShowSearch\"\n (nzOnSearch)=\"onSearch($event)\"\n >\n <nz-option\n *ngFor=\"let option of filteredOptions\"\n [nzValue]=\"option.value\"\n [nzLabel]=\"option.name || ''\"\n [nzCustomContent]=\"true\"\n >\n <ng-container *ngIf=\"optionTpl || isCurrency\">\n <ng-container\n *ngTemplateOutlet=\"\n isCurrency ? currencyOptionTpl : optionTpl;\n context: { $implicit: option }\n \"\n ></ng-container>\n </ng-container>\n <ng-container *ngIf=\"!(optionTpl || isCurrency)\">\n {{ option.name }}\n </ng-container>\n </nz-option>\n <nz-option *ngIf=\"isLoading\" nzDisabled nzCustomContent>\n <nz-spin style=\"padding: 16px 0\"></nz-spin>\n </nz-option>\n </nz-select>\n\n <div class=\"form-item-label\">{{ label }}</div>\n <svg\n class=\"form-item-select-icon\"\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"17\"\n viewBox=\"0 0 16 17\"\n fill=\"none\"\n >\n <path\n d=\"M3 5.83337L8 11.1667L13 5.83337\"\n [attr.stroke]=\"disabled ? '#9CA3AF' : '#030712'\"\n stroke-width=\"1.16667\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n</div>\n\n<ng-template #defaultSelectedTpl let-selected>\n {{ selected?.nzLabel }}\n</ng-template>\n\n<ng-template #currencyOptionTpl let-option>\n <div class=\"form-item-option-content\">\n <img [src]=\"option.iconUrl\" class=\"currency-icon\" alt=\"icon\" />\n <span>{{ option.name }}</span>\n </div>\n</ng-template>\n\n<ng-template #currencySelectedTpl let-selected let-extra>\n <div class=\"form-item-option-content\">\n <img\n [src]=\"currencyUrlMap?.[selected.nzValue]\"\n class=\"currency-icon\"\n alt=\"icon\"\n />\n <span>{{ selected.nzLabel }}</span>\n </div>\n</ng-template>\n\n<ng-template #removeIcon>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 12 12\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.39645 2.39645C2.59171 2.20118 2.90829 2.20118 3.10355 2.39645L6 5.29289L8.89645 2.39645C9.09171 2.20118 9.40829 2.20118 9.60355 2.39645C9.79882 2.59171 9.79882 2.90829 9.60355 3.10355L6.70711 6L9.60355 8.89645C9.79882 9.09171 9.79882 9.40829 9.60355 9.60355C9.40829 9.79882 9.09171 9.79882 8.89645 9.60355L6 6.70711L3.10355 9.60355C2.90829 9.79882 2.59171 9.79882 2.39645 9.60355C2.20118 9.40829 2.20118 9.09171 2.39645 8.89645L5.29289 6L2.39645 3.10355C2.20118 2.90829 2.20118 2.59171 2.39645 2.39645Z\"\n fill=\"#030712\"\n />\n </svg>\n</ng-template>\n\n<ng-template #customIcon>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.60136 4.90777C2.83639 4.68743 3.20555 4.69934 3.42589 4.93437L8.00033 9.81377L12.5748 4.93437C12.7951 4.69934 13.1643 4.68743 13.3993 4.90777C13.6343 5.12812 13.6462 5.49727 13.4259 5.7323L8.42589 11.0656C8.31561 11.1833 8.16157 11.25 8.00033 11.25C7.83909 11.25 7.68504 11.1833 7.57476 11.0656L2.57476 5.7323C2.35442 5.49727 2.36633 5.12811 2.60136 4.90777Z\"\n fill=\"#030712\"\n />\n </svg>\n</ng-template>\n", styles: [".form-item{position:relative;border-radius:4px;border:1px solid #e5e7eb;background-color:#fff;width:100%;margin-top:16px;min-height:64px}.form-item .form-item-select-icon{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;pointer-events:none}.form-item-label{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#6b7280;transition:all .3s ease;pointer-events:none;z-index:1;font-size:14px;font-weight:500}.form-item-input{color:#030712;font-size:14px;width:100%;font-weight:500;padding:18px 16px}.form-item-input:focus,.form-item-input:not(:placeholder-shown){top:10px}.form-item .form-item-input:focus~.form-item-label,.form-item .form-item-input:not(:placeholder-shown)~.form-item-label{top:16px;font-size:12px}.form-item-select{width:100%}.form-item-select ::ng-deep .ant-select-selection-item{color:#030712;font-size:14px;font-weight:500}.form-item.selected .form-item-label{top:16px;font-size:12px}.form-item.selected .form-item-select{top:10px}.form-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-item.disabled .form-item-label,.form-item.disabled .form-item-input{color:#9ca3af}.form-item.disabled ::ng-deep .ant-select-selection-item{color:#9ca3af}.form-item.error{border-color:#e51c36}.form-item-check{position:relative;background-color:#fff;width:100%;margin-top:16px}.form-item-error{color:#d2152e;font-size:12px;font-weight:500;display:flex;align-items:center;gap:4px;margin-top:4px}.form-item-error img{width:16px}.form-number-item{position:relative;border-radius:12px;padding:12px 6px;background-color:#fff;border:1px solid #e5e7eb;width:100%;margin-top:16px}.form-number-item .item-label{color:#6b7280;font-size:12px;padding:0 12px;font-weight:500}.form-number-item .item-content{display:flex;align-items:center;font-size:32px;font-weight:600;line-height:48px;color:#9ca3af}.form-number-item .item-content-value{flex:1;font-size:32px;font-weight:600;line-height:48px;color:#030712;border:none}.form-number-item .item-content-value:focus,.form-number-item .item-content-value:active,.form-number-item .item-content-value:hover{outline:none;box-shadow:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-handler-wrap{display:none}.form-number-item .item-content-value ::ng-deep .ant-input-number-input{font-size:32px;font-weight:600;line-height:48px}.form-number-item .item-content-value ::ng-deep .ant-input-number-input::placeholder{color:#9ca3af}.form-number-item .item-content-symbol{flex-shrink:0}.form-number-item ::ng-deep .item-warning{font-weight:500;font-size:12px;color:#6b7280;margin-top:4px;padding:0 12px}.form-number-item.disabled{background-color:#f3f4f6;border-color:#d1d5db}.form-number-item.disabled .item-label,.form-number-item.disabled .item-content-value{color:#9ca3af}.form-number-item.error{border-color:#e51c36}.form-item-select{min-width:113px;min-height:32px}.form-item-select.ant-select-multiple .ant-select-selection-search{margin-inline-start:0}.form-item-select .ant-select-selection-search .ant-select-selection-search-input{padding:12px 4px 0}.form-item-select.ant-select-single:not(.ant-select-customize-input) .ant-select-selector{padding:12px 16px 0;height:48px}.form-item-select.ant-select .ant-select-selection-item{color:#030712;font-weight:500;font-size:14px}.form-item-select .ant-select-selector{padding:12px 16px}.form-item-select.ant-select-multiple .ant-select-selection-item{border-radius:4px;background:#f3f4f6;font-size:14px;font-weight:500;color:#030712;display:flex;align-items:center;gap:4px}.form-item-select.ant-select-multiple .ant-select-selection-item .ant-select-selection-item-remove{line-height:1}.form-item-select:not(.ant-select-customize-input) .ant-select-selector{border-radius:4px}.form-item-select.ant-select-focused:not(.ant-select-disabled).ant-select:not(.ant-select-customize-input) .ant-select-selector{border-radius:4px;border:1px solid #367af6;background:#fff;box-shadow:0 0 0 2px #367af61a}.form-item-select .ant-select-selection-placeholder{color:#030712;font-weight:500;font-size:14px}.form-item-select .ant-select-selection-item-content{color:#030712;font-weight:500}.form-item-select .ant-select-arrow{transition:ease-in-out .2s all;cursor:pointer;pointer-events:initial}.form-item-select:hover:has(.ant-select-clear) .ant-select-arrow{opacity:0}.form-item-select.ant-select-focused .ant-select-arrow,.form-item-select .ant-select-selector:focus-within .ant-select-arrow{transform:rotate(-180deg);transition:transform .2s ease}.form-item-select-dropdown .ant-select-dropdown,.form-item-multiple-select-dropdown .ant-select-dropdown{border-radius:4px;background:#fff;min-width:113px}.form-item-select-dropdown .ant-select-item-option,.form-item-multiple-select-dropdown .ant-select-item-option{background-color:transparent;padding:0 6px}.form-item-select-dropdown .ant-select-item-option-content,.form-item-multiple-select-dropdown .ant-select-item-option-content{border-radius:4px;padding:0 6px;display:flex;align-items:center;color:#030712;font-size:14px;min-height:40px}.form-item-select-dropdown .ant-select-item-option-active .ant-select-item-option-content,.form-item-multiple-select-dropdown .ant-select-item-option-active .ant-select-item-option-content{background:rgba(54,122,246,.1)}.form-item-multiple-select-dropdown .ant-select-item-option-content{border-radius:4px;font-weight:500;color:#030712;font-size:14px;padding:0 6px 0 32px;position:relative}.form-item-multiple-select-dropdown .ant-select-item-option-content:before{content:\"\";position:absolute;top:50%;left:6px;width:16px;height:16px;transform:translateY(-50%);border-radius:4px;border:1px solid #9ca3af}.form-item-multiple-select-dropdown .ant-select-item-option-selected .ant-select-item-option-content:before{background-image:url(/assets/img/icon/checkbox.svg);background-size:contain;background-position:center;background-repeat:no-repeat;border:none}.form-item-multiple-select-dropdown .ant-select-item-option-state{display:none}\n"] }]
869
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { label: [{
870
+ type: Input
871
+ }], customTpl: [{
872
+ type: Input
873
+ }], optionTpl: [{
874
+ type: Input
875
+ }], name: [{
876
+ type: Input
877
+ }], disabled: [{
878
+ type: Input
879
+ }], nzMode: [{
880
+ type: Input
881
+ }], isCurrency: [{
882
+ type: Input
883
+ }], currencyUrlMap: [{
884
+ type: Input
885
+ }], isLoading: [{
886
+ type: Input
887
+ }], isShowSearch: [{
888
+ type: Input
889
+ }], isRemoteSearch: [{
890
+ type: Input
891
+ }], options: [{
892
+ type: Input
893
+ }], searchChange: [{
894
+ type: Output
895
+ }], valueChange: [{
896
+ type: Output
897
+ }], scrollToBottomEmit: [{
898
+ type: Output
899
+ }] } });
900
+
901
+ class RdSelectModule {
902
+ }
903
+ RdSelectModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdSelectModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
904
+ RdSelectModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: RdSelectModule, declarations: [CustomSelectComponent], imports: [CommonModule,
905
+ FormsModule,
906
+ ReactiveFormsModule,
907
+ NzSpinModule,
908
+ NzSelectModule], exports: [CustomSelectComponent] });
909
+ RdSelectModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdSelectModule, imports: [CommonModule,
910
+ FormsModule,
911
+ ReactiveFormsModule,
912
+ NzSpinModule,
913
+ NzSelectModule] });
914
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdSelectModule, decorators: [{
915
+ type: NgModule,
916
+ args: [{
917
+ declarations: [CustomSelectComponent],
918
+ imports: [
919
+ CommonModule,
920
+ FormsModule,
921
+ ReactiveFormsModule,
922
+ NzSpinModule,
923
+ NzSelectModule,
924
+ ],
925
+ exports: [CustomSelectComponent],
926
+ }]
927
+ }] });
928
+
929
+ var FilterTypeEnum;
930
+ (function (FilterTypeEnum) {
931
+ FilterTypeEnum[FilterTypeEnum["input"] = 1] = "input";
932
+ FilterTypeEnum[FilterTypeEnum["select"] = 2] = "select";
933
+ FilterTypeEnum[FilterTypeEnum["date"] = 3] = "date";
934
+ })(FilterTypeEnum || (FilterTypeEnum = {}));
935
+
936
+ class RdFilterDateComponent {
937
+ constructor() {
938
+ this.handleChangeValue = new EventEmitter();
939
+ this.isPickerOpen = false;
940
+ this.inputValue = [];
941
+ this.disabledDate = (current) => differenceInCalendarDays(current, new Date()) > 0;
942
+ }
943
+ ngOnChanges(changes) {
944
+ var _a, _b, _c;
945
+ if ((_a = changes['item']) === null || _a === void 0 ? void 0 : _a.currentValue) {
946
+ this.inputValue = ((_b = this.item) === null || _b === void 0 ? void 0 : _b.value) ? (_c = this.item) === null || _c === void 0 ? void 0 : _c.value.split(',') : [];
947
+ }
948
+ }
949
+ openPicker() {
950
+ var _a;
951
+ if (this.isPickerOpen) {
952
+ return;
953
+ }
954
+ this.isPickerOpen = true;
955
+ (_a = this.datePicker) === null || _a === void 0 ? void 0 : _a.open();
956
+ }
957
+ onDateChange(dates) {
958
+ if (!(dates === null || dates === void 0 ? void 0 : dates.length) && this.item) {
959
+ this.item.value = '';
960
+ return;
961
+ }
962
+ const startDate = formatDate(dates[0], 'yyyy-MM-dd', 'en');
963
+ const endDate = formatDate(dates[1], 'yyyy-MM-dd', 'en');
964
+ if (this.item) {
965
+ this.item.value = `${startDate},${endDate}`;
966
+ }
967
+ this.handleChangeValue.emit(this.inputValue);
968
+ }
969
+ onOpenChange(open) {
970
+ setTimeout(() => {
971
+ this.isPickerOpen = open;
972
+ }, 0);
973
+ }
974
+ }
975
+ RdFilterDateComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterDateComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
976
+ RdFilterDateComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: RdFilterDateComponent, selector: "app-rd-filter-date", inputs: { item: "item" }, outputs: { handleChangeValue: "handleChangeValue" }, viewQueries: [{ propertyName: "datePicker", first: true, predicate: ["datePicker"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"date-picker-container\"\n [ngClass]=\"{ 'date-picker-focus': isPickerOpen }\"\n *ngIf=\"item\"\n>\n <nz-range-picker\n [(ngModel)]=\"inputValue\"\n (ngModelChange)=\"onDateChange($event)\"\n (nzOnOpenChange)=\"onOpenChange($event)\"\n [nzFormat]=\"'yyyy-MM-dd'\"\n [nzShowTime]=\"false\"\n [nzAllowClear]=\"false\"\n [nzPlaceHolder]=\"['From', 'To']\"\n class=\"range-picker\"\n [nzDisabledDate]=\"disabledDate\"\n [nzSuffixIcon]=\"customIcon\"\n [nzDropdownClassName]=\"'date-picker-popup'\"\n [nzSeparator]=\"'-'\"\n nzSuffixIcon=\"\"\n #datePicker\n [ngClass]=\"{ 'hidden-range-picker': !item.value?.length }\"\n ></nz-range-picker>\n\n <div\n *ngIf=\"!item?.value?.length\"\n class=\"placeholder-box\"\n [ngClass]=\"{ 'placeholder-box-focus': isPickerOpen }\"\n (click)=\"openPicker()\"\n >\n {{ item.title }}\n <ng-container *ngTemplateOutlet=\"customIcon\"></ng-container>\n </div>\n\n <ng-template #customIcon>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.60136 4.90777C2.83639 4.68743 3.20555 4.69934 3.42589 4.93437L8.00033 9.81377L12.5748 4.93437C12.7951 4.69934 13.1643 4.68743 13.3993 4.90777C13.6343 5.12812 13.6462 5.49727 13.4259 5.7323L8.42589 11.0656C8.31561 11.1833 8.16157 11.25 8.00033 11.25C7.83909 11.25 7.68504 11.1833 7.57476 11.0656L2.57476 5.7323C2.35442 5.49727 2.36633 5.12811 2.60136 4.90777Z\"\n fill=\"#030712\"\n />\n </svg>\n </ng-template>\n</div>\n", styles: ["@charset \"UTF-8\";.date-picker-container{position:relative}.range-picker{width:auto;border:1px solid #e5e7eb;border-radius:4px}.hidden-range-picker{position:absolute;top:0;left:0;width:100%;height:100%}.placeholder-box{height:32px;padding:0 12px;background:#fff;border:1px solid #e5e7eb;border-radius:4px;cursor:pointer;display:flex;align-items:center;gap:12px;width:-moz-fit-content;width:fit-content;white-space:nowrap;position:relative;top:0;transition:ease-in-out .2s all;font-weight:500}.placeholder-box svg{transition:transform .2s ease;cursor:pointer}.placeholder-box-focus{border-color:#1890ff}.placeholder-box-focus ::ng-deep svg{transform:rotate(-180deg)}.placeholder-box:hover{border-color:#1890ff}.hidden-range-picker{opacity:0;width:132px}::ng-deep .range-picker .ant-picker-suffix svg{transition:transform .2s ease;cursor:pointer;pointer-events:initial}::ng-deep .range-picker.ant-picker:hover,::ng-deep .range-picker.ant-picker-focused{box-shadow:none;border-color:#367af6}::ng-deep .range-picker .ant-picker-active-bar{display:none}::ng-deep .range-picker .ant-picker-input input{field-sizing:content;font-weight:500}::ng-deep .range-picker .ant-picker-separator{width:-moz-fit-content;width:fit-content}::ng-deep .date-picker-focus .ant-picker-suffix svg{pointer-events:none;transform:rotate(-180deg)}::ng-deep .date-picker-popup.ant-picker-dropdown-range{padding:0}::ng-deep .date-picker-popup .ant-picker-range-arrow{display:none}::ng-deep .date-picker-popup .ant-picker-super-next-icon,::ng-deep .date-picker-popup .ant-picker-header-next-btn,::ng-deep .date-picker-popup .ant-picker-super-prev-icon,::ng-deep .date-picker-popup .ant-picker-header-prev-btn{color:#030712}::ng-deep .date-picker-popup .ant-picker-super-prev-icon:after,::ng-deep .date-picker-popup .ant-picker-super-next-icon:after{top:2px;left:2px}::ng-deep .date-picker-popup .ant-picker-header-view button{color:#030712;font-weight:500}::ng-deep .date-picker-popup .ant-picker-panel-container{border-radius:4px}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-header{border-bottom:none}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-header-view{display:flex;flex-direction:row-reverse;justify-content:center;gap:8px}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-header .ant-picker-header-month-btn{order:2}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-header .ant-picker-header-year-btn{order:1}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-panel+.ant-picker-panel .ant-picker-body{border-left:1px solid #e5e7eb}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-body .ant-picker-cell{color:#9ca3af;font-weight:500}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-body .ant-picker-cell-in-view{color:#030712;font-weight:500}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-body th{color:#6b7280;font-weight:500}::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-in-range:before{background-color:#e9f0fd}::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-selected .ant-picker-cell-inner,::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-range-start .ant-picker-cell-inner,::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-range-end .ant-picker-cell-inner{border-radius:4px!important;background-color:#367af6}::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-today .ant-picker-cell-inner:before{border-radius:4px!important}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i3.NzDatePickerComponent, selector: "nz-date-picker,nz-week-picker,nz-month-picker,nz-year-picker,nz-range-picker", inputs: ["nzAllowClear", "nzAutoFocus", "nzDisabled", "nzBorderless", "nzInputReadOnly", "nzInline", "nzOpen", "nzDisabledDate", "nzLocale", "nzPlaceHolder", "nzPopupStyle", "nzDropdownClassName", "nzSize", "nzStatus", "nzFormat", "nzDateRender", "nzDisabledTime", "nzRenderExtraFooter", "nzShowToday", "nzMode", "nzShowNow", "nzRanges", "nzDefaultPickerValue", "nzSeparator", "nzSuffixIcon", "nzBackdrop", "nzId", "nzPlacement", "nzShowWeekNumber", "nzShowTime"], outputs: ["nzOnPanelChange", "nzOnCalendarChange", "nzOnOk", "nzOnOpenChange"], exportAs: ["nzDatePicker"] }, { kind: "directive", type: i3.NzRangePickerComponent, selector: "nz-range-picker", exportAs: ["nzRangePicker"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] });
977
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterDateComponent, decorators: [{
978
+ type: Component,
979
+ args: [{ selector: 'app-rd-filter-date', template: "<div\n class=\"date-picker-container\"\n [ngClass]=\"{ 'date-picker-focus': isPickerOpen }\"\n *ngIf=\"item\"\n>\n <nz-range-picker\n [(ngModel)]=\"inputValue\"\n (ngModelChange)=\"onDateChange($event)\"\n (nzOnOpenChange)=\"onOpenChange($event)\"\n [nzFormat]=\"'yyyy-MM-dd'\"\n [nzShowTime]=\"false\"\n [nzAllowClear]=\"false\"\n [nzPlaceHolder]=\"['From', 'To']\"\n class=\"range-picker\"\n [nzDisabledDate]=\"disabledDate\"\n [nzSuffixIcon]=\"customIcon\"\n [nzDropdownClassName]=\"'date-picker-popup'\"\n [nzSeparator]=\"'-'\"\n nzSuffixIcon=\"\"\n #datePicker\n [ngClass]=\"{ 'hidden-range-picker': !item.value?.length }\"\n ></nz-range-picker>\n\n <div\n *ngIf=\"!item?.value?.length\"\n class=\"placeholder-box\"\n [ngClass]=\"{ 'placeholder-box-focus': isPickerOpen }\"\n (click)=\"openPicker()\"\n >\n {{ item.title }}\n <ng-container *ngTemplateOutlet=\"customIcon\"></ng-container>\n </div>\n\n <ng-template #customIcon>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.60136 4.90777C2.83639 4.68743 3.20555 4.69934 3.42589 4.93437L8.00033 9.81377L12.5748 4.93437C12.7951 4.69934 13.1643 4.68743 13.3993 4.90777C13.6343 5.12812 13.6462 5.49727 13.4259 5.7323L8.42589 11.0656C8.31561 11.1833 8.16157 11.25 8.00033 11.25C7.83909 11.25 7.68504 11.1833 7.57476 11.0656L2.57476 5.7323C2.35442 5.49727 2.36633 5.12811 2.60136 4.90777Z\"\n fill=\"#030712\"\n />\n </svg>\n </ng-template>\n</div>\n", styles: ["@charset \"UTF-8\";.date-picker-container{position:relative}.range-picker{width:auto;border:1px solid #e5e7eb;border-radius:4px}.hidden-range-picker{position:absolute;top:0;left:0;width:100%;height:100%}.placeholder-box{height:32px;padding:0 12px;background:#fff;border:1px solid #e5e7eb;border-radius:4px;cursor:pointer;display:flex;align-items:center;gap:12px;width:-moz-fit-content;width:fit-content;white-space:nowrap;position:relative;top:0;transition:ease-in-out .2s all;font-weight:500}.placeholder-box svg{transition:transform .2s ease;cursor:pointer}.placeholder-box-focus{border-color:#1890ff}.placeholder-box-focus ::ng-deep svg{transform:rotate(-180deg)}.placeholder-box:hover{border-color:#1890ff}.hidden-range-picker{opacity:0;width:132px}::ng-deep .range-picker .ant-picker-suffix svg{transition:transform .2s ease;cursor:pointer;pointer-events:initial}::ng-deep .range-picker.ant-picker:hover,::ng-deep .range-picker.ant-picker-focused{box-shadow:none;border-color:#367af6}::ng-deep .range-picker .ant-picker-active-bar{display:none}::ng-deep .range-picker .ant-picker-input input{field-sizing:content;font-weight:500}::ng-deep .range-picker .ant-picker-separator{width:-moz-fit-content;width:fit-content}::ng-deep .date-picker-focus .ant-picker-suffix svg{pointer-events:none;transform:rotate(-180deg)}::ng-deep .date-picker-popup.ant-picker-dropdown-range{padding:0}::ng-deep .date-picker-popup .ant-picker-range-arrow{display:none}::ng-deep .date-picker-popup .ant-picker-super-next-icon,::ng-deep .date-picker-popup .ant-picker-header-next-btn,::ng-deep .date-picker-popup .ant-picker-super-prev-icon,::ng-deep .date-picker-popup .ant-picker-header-prev-btn{color:#030712}::ng-deep .date-picker-popup .ant-picker-super-prev-icon:after,::ng-deep .date-picker-popup .ant-picker-super-next-icon:after{top:2px;left:2px}::ng-deep .date-picker-popup .ant-picker-header-view button{color:#030712;font-weight:500}::ng-deep .date-picker-popup .ant-picker-panel-container{border-radius:4px}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-header{border-bottom:none}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-header-view{display:flex;flex-direction:row-reverse;justify-content:center;gap:8px}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-header .ant-picker-header-month-btn{order:2}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-header .ant-picker-header-year-btn{order:1}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-panel+.ant-picker-panel .ant-picker-body{border-left:1px solid #e5e7eb}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-body .ant-picker-cell{color:#9ca3af;font-weight:500}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-body .ant-picker-cell-in-view{color:#030712;font-weight:500}::ng-deep .date-picker-popup .ant-picker-panel-container .ant-picker-body th{color:#6b7280;font-weight:500}::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-in-range:before{background-color:#e9f0fd}::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-selected .ant-picker-cell-inner,::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-range-start .ant-picker-cell-inner,::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-range-end .ant-picker-cell-inner{border-radius:4px!important;background-color:#367af6}::ng-deep .date-picker-popup .ant-picker-cell-in-view.ant-picker-cell-today .ant-picker-cell-inner:before{border-radius:4px!important}\n"] }]
980
+ }], propDecorators: { item: [{
981
+ type: Input
982
+ }], datePicker: [{
983
+ type: ViewChild,
984
+ args: ['datePicker']
985
+ }], handleChangeValue: [{
986
+ type: Output
987
+ }] } });
988
+
989
+ var ONOFFStatusEnum;
990
+ (function (ONOFFStatusEnum) {
991
+ ONOFFStatusEnum["PENDING"] = "PENDING";
992
+ ONOFFStatusEnum["SUCCESSFUL"] = "SUCCESSFUL";
993
+ ONOFFStatusEnum["SUBMITTED"] = "SUBMITTED";
994
+ ONOFFStatusEnum["FAILED"] = "FAILED";
995
+ // only for Deposit Payment status
996
+ ONOFFStatusEnum["RETURNING"] = "RETURNING";
997
+ ONOFFStatusEnum["RETURNED"] = "RETURNED";
998
+ ONOFFStatusEnum["VERIFYING"] = "VERIFYING";
999
+ ONOFFStatusEnum["AWAIT_FOR_RECEIVE"] = "AWAIT_FOR_RECEIVE";
1000
+ ONOFFStatusEnum["PAYMENT_VERIFYING"] = "PAYMENT_VERIFYING";
1001
+ ONOFFStatusEnum["AWAIT_FOR_DECLARATION"] = "AWAIT_FOR_DECLARATION";
1002
+ ONOFFStatusEnum["DECLARATION_REVIEW"] = "DECLARATION_REVIEW";
1003
+ ONOFFStatusEnum["CLOSED"] = "CLOSED";
1004
+ // only for On/off ramp status
1005
+ ONOFFStatusEnum["CONVERTING"] = "CONVERTING";
1006
+ ONOFFStatusEnum["SETTLING"] = "SETTLING";
1007
+ // only for whitelist status
1008
+ ONOFFStatusEnum["WAITING"] = "WAITING";
1009
+ ONOFFStatusEnum["PENDING_DEPOSIT"] = "PENDING_DEPOSIT";
1010
+ ONOFFStatusEnum["SUCCESS"] = "SUCCESS";
1011
+ })(ONOFFStatusEnum || (ONOFFStatusEnum = {}));
1012
+
1013
+ const ONOFFStatusEnumTextMap = {
1014
+ [ONOFFStatusEnum.PENDING]: 'In progress',
1015
+ [ONOFFStatusEnum.SUCCESSFUL]: 'Success',
1016
+ [ONOFFStatusEnum.SUBMITTED]: 'Submitted',
1017
+ [ONOFFStatusEnum.FAILED]: 'Failed',
1018
+ [ONOFFStatusEnum.RETURNING]: 'Returning',
1019
+ [ONOFFStatusEnum.RETURNED]: 'Returned',
1020
+ [ONOFFStatusEnum.CONVERTING]: 'Converting',
1021
+ [ONOFFStatusEnum.SETTLING]: 'Settling',
1022
+ [ONOFFStatusEnum.WAITING]: 'Waiting',
1023
+ [ONOFFStatusEnum.PENDING_DEPOSIT]: 'Await for deposit',
1024
+ [ONOFFStatusEnum.SUCCESS]: 'Verified',
1025
+ [ONOFFStatusEnum.VERIFYING]: 'Verifying',
1026
+ [ONOFFStatusEnum.AWAIT_FOR_RECEIVE]: 'Await for Receive',
1027
+ [ONOFFStatusEnum.PAYMENT_VERIFYING]: 'Payment Verifying',
1028
+ [ONOFFStatusEnum.AWAIT_FOR_DECLARATION]: 'Await for Declaration',
1029
+ [ONOFFStatusEnum.DECLARATION_REVIEW]: 'Declaration Review',
1030
+ [ONOFFStatusEnum.CLOSED]: 'Closed',
1031
+ };
1032
+
1033
+ class StatusFieldComponent {
1034
+ constructor() {
1035
+ this.size = 'default';
1036
+ this.statusEnum = ONOFFStatusEnum;
1037
+ this.textEnum = ONOFFStatusEnumTextMap;
1038
+ }
1039
+ get defaultText() {
1040
+ return (this.text || this.textEnum[this.status] || this.status);
1041
+ }
1042
+ }
1043
+ StatusFieldComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: StatusFieldComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1044
+ StatusFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: StatusFieldComponent, selector: "app-rd-status-field", inputs: { status: "status", text: "text", size: "size" }, ngImport: i0, template: "<div class=\"status-field\" [ngClass]=\"size\">\n <ng-container [ngSwitch]=\"status\">\n <ng-container\n *ngSwitchCase=\"\n [\n statusEnum.PENDING_DEPOSIT,\n statusEnum.WAITING,\n statusEnum.VERIFYING,\n statusEnum.PAYMENT_VERIFYING,\n statusEnum.DECLARATION_REVIEW\n ].includes(status)\n ? status\n : ''\n \"\n >\n <img src=\"/assets/img/status/pending.svg\" alt=\"\" />\n </ng-container>\n <ng-container\n *ngSwitchCase=\"\n [\n statusEnum.AWAIT_FOR_RECEIVE,\n statusEnum.AWAIT_FOR_DECLARATION\n ].includes(status)\n ? status\n : ''\n \"\n >\n <img src=\"/assets/img/status/warning.svg\" alt=\"\" />\n </ng-container>\n <ng-container\n *ngSwitchCase=\"\n status == statusEnum.SUBMITTED ||\n status == statusEnum.PENDING ||\n status == statusEnum.CONVERTING\n ? status\n : ''\n \"\n >\n <img src=\"/assets/img/status/submitted.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"statusEnum.SETTLING\">\n <img src=\"/assets/img/status/settling.svg\" alt=\"\" />\n </ng-container>\n <ng-container\n *ngSwitchCase=\"\n status == statusEnum.SUCCESSFUL || status == statusEnum.SUCCESS\n ? status\n : ''\n \"\n >\n <img src=\"/assets/img/status/success.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"status == statusEnum.CLOSED ? status : ''\">\n <img src=\"/assets/img/status/cancel.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"statusEnum.FAILED\">\n <img src=\"/assets/img/status/failed.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"statusEnum.RETURNING\">\n <img src=\"/assets/img/status/returning.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"statusEnum.RETURNED\">\n <img src=\"/assets/img/status/returned.svg\" alt=\"\" />\n </ng-container>\n\n {{ defaultText }}\n </ng-container>\n</div>\n", styles: [":host .status-field{display:flex;align-items:center;gap:8px;font-weight:500}:host .status-field img{width:12px;height:12px;flex-shrink:0}:host .status-field.large img{width:16px;height:16px}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }] });
1045
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: StatusFieldComponent, decorators: [{
1046
+ type: Component,
1047
+ args: [{ selector: 'app-rd-status-field', template: "<div class=\"status-field\" [ngClass]=\"size\">\n <ng-container [ngSwitch]=\"status\">\n <ng-container\n *ngSwitchCase=\"\n [\n statusEnum.PENDING_DEPOSIT,\n statusEnum.WAITING,\n statusEnum.VERIFYING,\n statusEnum.PAYMENT_VERIFYING,\n statusEnum.DECLARATION_REVIEW\n ].includes(status)\n ? status\n : ''\n \"\n >\n <img src=\"/assets/img/status/pending.svg\" alt=\"\" />\n </ng-container>\n <ng-container\n *ngSwitchCase=\"\n [\n statusEnum.AWAIT_FOR_RECEIVE,\n statusEnum.AWAIT_FOR_DECLARATION\n ].includes(status)\n ? status\n : ''\n \"\n >\n <img src=\"/assets/img/status/warning.svg\" alt=\"\" />\n </ng-container>\n <ng-container\n *ngSwitchCase=\"\n status == statusEnum.SUBMITTED ||\n status == statusEnum.PENDING ||\n status == statusEnum.CONVERTING\n ? status\n : ''\n \"\n >\n <img src=\"/assets/img/status/submitted.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"statusEnum.SETTLING\">\n <img src=\"/assets/img/status/settling.svg\" alt=\"\" />\n </ng-container>\n <ng-container\n *ngSwitchCase=\"\n status == statusEnum.SUCCESSFUL || status == statusEnum.SUCCESS\n ? status\n : ''\n \"\n >\n <img src=\"/assets/img/status/success.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"status == statusEnum.CLOSED ? status : ''\">\n <img src=\"/assets/img/status/cancel.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"statusEnum.FAILED\">\n <img src=\"/assets/img/status/failed.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"statusEnum.RETURNING\">\n <img src=\"/assets/img/status/returning.svg\" alt=\"\" />\n </ng-container>\n <ng-container *ngSwitchCase=\"statusEnum.RETURNED\">\n <img src=\"/assets/img/status/returned.svg\" alt=\"\" />\n </ng-container>\n\n {{ defaultText }}\n </ng-container>\n</div>\n", styles: [":host .status-field{display:flex;align-items:center;gap:8px;font-weight:500}:host .status-field img{width:12px;height:12px;flex-shrink:0}:host .status-field.large img{width:16px;height:16px}\n"] }]
1048
+ }], propDecorators: { status: [{
1049
+ type: Input
1050
+ }], text: [{
1051
+ type: Input
1052
+ }], size: [{
1053
+ type: Input
1054
+ }] } });
1055
+
1056
+ class RdFilterSelectComponent {
1057
+ constructor() {
1058
+ this.handleChangeValue = new EventEmitter();
1059
+ this.selectValue = null;
1060
+ }
1061
+ get mode() {
1062
+ var _a;
1063
+ return ((_a = this.item) === null || _a === void 0 ? void 0 : _a.selectMode) || 'multiple';
1064
+ }
1065
+ ngOnChanges(changes) {
1066
+ var _a, _b;
1067
+ if (changes['item'].currentValue) {
1068
+ if (!this.item.value) {
1069
+ this.selectValue = null;
1070
+ }
1071
+ else {
1072
+ this.selectValue =
1073
+ this.mode === 'multiple'
1074
+ ? (_b = (_a = this.item) === null || _a === void 0 ? void 0 : _a.value) === null || _b === void 0 ? void 0 : _b.split(',')
1075
+ : this.item.value;
1076
+ }
1077
+ }
1078
+ }
1079
+ ngOnInit() {
1080
+ var _a;
1081
+ if (!this.item.value)
1082
+ return;
1083
+ if (this.mode === 'multiple') {
1084
+ this.selectValue = (_a = this.item) === null || _a === void 0 ? void 0 : _a.value.split(',');
1085
+ }
1086
+ else {
1087
+ this.selectValue = this.item.value;
1088
+ }
1089
+ }
1090
+ modelChange(event) {
1091
+ if (this.mode === 'multiple') {
1092
+ this.item.value = event.join(',');
1093
+ }
1094
+ else {
1095
+ this.item.value = event;
1096
+ }
1097
+ this.handleChangeValue.emit(event);
1098
+ }
1099
+ }
1100
+ RdFilterSelectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterSelectComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1101
+ RdFilterSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: RdFilterSelectComponent, selector: "app-rd-filter-select", inputs: { item: "item" }, outputs: { handleChangeValue: "handleChangeValue" }, usesOnChanges: true, ngImport: i0, template: "<nz-select\n class=\"custom-filter-select\"\n [nzPlaceHolder]=\"'All ' + item.title.toLowerCase()\"\n [nzShowArrow]=\"true\"\n [nzMode]=\"mode\"\n [nzAllowClear]=\"false\"\n [nzDropdownClassName]=\"\n mode === 'multiple'\n ? 'custom-multiple-filter-select-dropdown'\n : 'custom-filter-select-dropdown'\n \"\n [(ngModel)]=\"selectValue\"\n [nzSuffixIcon]=\"customIcon\"\n [nzRemoveIcon]=\"removeIcon\"\n [nzOptionOverflowSize]=\"5\"\n [nzOptionHeightPx]=\"40\"\n [nzDropdownMatchSelectWidth]=\"false\"\n (ngModelChange)=\"modelChange($event)\"\n [nzCustomTemplate]=\"customTpl\"\n [nzMaxTagCount]=\"3\"\n>\n <nz-option\n *ngFor=\"let option of item.options\"\n [nzValue]=\"option.value\"\n [nzLabel]=\"option.label\"\n nzCustomContent\n >\n <app-rd-status-field\n *ngIf=\"item.isStatusField; else defaultTpl\"\n [status]=\"option.value\"\n ></app-rd-status-field>\n <ng-template #defaultTpl> {{ option.label }}</ng-template>\n </nz-option>\n</nz-select>\n\n<ng-template #customIcon>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.60136 4.90777C2.83639 4.68743 3.20555 4.69934 3.42589 4.93437L8.00033 9.81377L12.5748 4.93437C12.7951 4.69934 13.1643 4.68743 13.3993 4.90777C13.6343 5.12812 13.6462 5.49727 13.4259 5.7323L8.42589 11.0656C8.31561 11.1833 8.16157 11.25 8.00033 11.25C7.83909 11.25 7.68504 11.1833 7.57476 11.0656L2.57476 5.7323C2.35442 5.49727 2.36633 5.12811 2.60136 4.90777Z\"\n fill=\"#030712\"\n />\n </svg>\n</ng-template>\n\n<ng-template #removeIcon>\n <!-- <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 12 12\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.39645 2.39645C2.59171 2.20118 2.90829 2.20118 3.10355 2.39645L6 5.29289L8.89645 2.39645C9.09171 2.20118 9.40829 2.20118 9.60355 2.39645C9.79882 2.59171 9.79882 2.90829 9.60355 3.10355L6.70711 6L9.60355 8.89645C9.79882 9.09171 9.79882 9.40829 9.60355 9.60355C9.40829 9.79882 9.09171 9.79882 8.89645 9.60355L6 6.70711L3.10355 9.60355C2.90829 9.79882 2.59171 9.79882 2.39645 9.60355C2.20118 9.40829 2.20118 9.09171 2.39645 8.89645L5.29289 6L2.39645 3.10355C2.20118 2.90829 2.20118 2.59171 2.39645 2.39645Z\"\n fill=\"#030712\"\n />\n </svg> -->\n</ng-template>\n\n<ng-template #customTpl let-selected>\n <!-- <app-status-field\n *ngIf=\"item.isStatusField\"\n [status]=\"selected.nzValue\"\n ></app-status-field> -->\n <ng-container>\n {{ selected.nzLabel }}\n </ng-container>\n</ng-template>\n", styles: ["::ng-deep .custom-filter-select{min-width:113px;min-height:32px}::ng-deep .custom-filter-select.ant-select .ant-select-selection-item{color:#030712;font-weight:500;font-size:14px}::ng-deep .custom-filter-select.ant-select-multiple .ant-select-selection-item{border-radius:4px;background:#f3f4f6;font-size:14px;font-weight:500;color:#030712;display:flex;align-items:center;gap:4px}::ng-deep .custom-filter-select.ant-select-multiple .ant-select-selection-item .ant-select-selection-item-remove{line-height:1}::ng-deep .custom-filter-select:not(.ant-select-customize-input) .ant-select-selector{border-radius:4px}::ng-deep .custom-filter-select.ant-select-focused:not(.ant-select-disabled).ant-select:not(.ant-select-customize-input) .ant-select-selector{border-radius:4px;border:1px solid #367af6;background:#fff;box-shadow:0 0 0 2px #367af61a}::ng-deep .custom-filter-select .ant-select-selection-placeholder{color:#030712;font-weight:500;font-size:14px}::ng-deep .custom-filter-select .ant-select-selection-item-content{color:#030712;font-weight:500}::ng-deep .custom-filter-select .ant-select-arrow{transition:ease-in-out .2s all;cursor:pointer;pointer-events:initial}::ng-deep .custom-filter-select:hover:has(.ant-select-clear) .ant-select-arrow{opacity:0}::ng-deep .custom-filter-select.ant-select-focused .ant-select-arrow,::ng-deep .custom-filter-select .ant-select-selector:focus-within .ant-select-arrow{transform:rotate(-180deg);transition:transform .2s ease}::ng-deep .custom-filter-select-dropdown .ant-select-dropdown,::ng-deep .custom-multiple-filter-select-dropdown .ant-select-dropdown{border-radius:4px;background:#fff;width:-moz-fit-content;width:fit-content;min-width:113px}::ng-deep .custom-filter-select-dropdown .ant-select-item-option,::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option{background-color:transparent;padding:0 6px}::ng-deep .custom-filter-select-dropdown .ant-select-item-option-content,::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-content{border-radius:4px;padding:0 6px;display:flex;align-items:center;color:#030712;font-size:14px;min-height:40px}::ng-deep .custom-filter-select-dropdown .ant-select-item-option-active .ant-select-item-option-content,::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-active .ant-select-item-option-content{background:rgba(54,122,246,.1)}::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-content{border-radius:4px;font-weight:500;color:#030712;font-size:14px;padding:0 6px 0 32px;position:relative}::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-content:before{content:\"\";position:absolute;top:50%;left:6px;width:16px;height:16px;transform:translateY(-50%);border-radius:4px;border:1px solid #9ca3af}::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-selected .ant-select-item-option-content:before{background-image:url(/assets/img/icon/checkbox.svg);background-size:contain;background-position:center;background-repeat:no-repeat;border:none}::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-state{display:none}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i4$1.NzOptionComponent, selector: "nz-option", inputs: ["nzLabel", "nzValue", "nzDisabled", "nzHide", "nzCustomContent"], exportAs: ["nzOption"] }, { kind: "component", type: i4$1.NzSelectComponent, selector: "nz-select", inputs: ["nzId", "nzSize", "nzStatus", "nzOptionHeightPx", "nzOptionOverflowSize", "nzDropdownClassName", "nzDropdownMatchSelectWidth", "nzDropdownStyle", "nzNotFoundContent", "nzPlaceHolder", "nzPlacement", "nzMaxTagCount", "nzDropdownRender", "nzCustomTemplate", "nzSuffixIcon", "nzClearIcon", "nzRemoveIcon", "nzMenuItemSelectedIcon", "nzTokenSeparators", "nzMaxTagPlaceholder", "nzMaxMultipleCount", "nzMode", "nzFilterOption", "compareWith", "nzAllowClear", "nzBorderless", "nzShowSearch", "nzLoading", "nzAutoFocus", "nzAutoClearSearchValue", "nzServerSearch", "nzDisabled", "nzOpen", "nzSelectOnTab", "nzBackdrop", "nzOptions", "nzShowArrow"], outputs: ["nzOnSearch", "nzScrollToBottom", "nzOpenChange", "nzBlur", "nzFocus"], exportAs: ["nzSelect"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: StatusFieldComponent, selector: "app-rd-status-field", inputs: ["status", "text", "size"] }] });
1102
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterSelectComponent, decorators: [{
1103
+ type: Component,
1104
+ args: [{ selector: 'app-rd-filter-select', template: "<nz-select\n class=\"custom-filter-select\"\n [nzPlaceHolder]=\"'All ' + item.title.toLowerCase()\"\n [nzShowArrow]=\"true\"\n [nzMode]=\"mode\"\n [nzAllowClear]=\"false\"\n [nzDropdownClassName]=\"\n mode === 'multiple'\n ? 'custom-multiple-filter-select-dropdown'\n : 'custom-filter-select-dropdown'\n \"\n [(ngModel)]=\"selectValue\"\n [nzSuffixIcon]=\"customIcon\"\n [nzRemoveIcon]=\"removeIcon\"\n [nzOptionOverflowSize]=\"5\"\n [nzOptionHeightPx]=\"40\"\n [nzDropdownMatchSelectWidth]=\"false\"\n (ngModelChange)=\"modelChange($event)\"\n [nzCustomTemplate]=\"customTpl\"\n [nzMaxTagCount]=\"3\"\n>\n <nz-option\n *ngFor=\"let option of item.options\"\n [nzValue]=\"option.value\"\n [nzLabel]=\"option.label\"\n nzCustomContent\n >\n <app-rd-status-field\n *ngIf=\"item.isStatusField; else defaultTpl\"\n [status]=\"option.value\"\n ></app-rd-status-field>\n <ng-template #defaultTpl> {{ option.label }}</ng-template>\n </nz-option>\n</nz-select>\n\n<ng-template #customIcon>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.60136 4.90777C2.83639 4.68743 3.20555 4.69934 3.42589 4.93437L8.00033 9.81377L12.5748 4.93437C12.7951 4.69934 13.1643 4.68743 13.3993 4.90777C13.6343 5.12812 13.6462 5.49727 13.4259 5.7323L8.42589 11.0656C8.31561 11.1833 8.16157 11.25 8.00033 11.25C7.83909 11.25 7.68504 11.1833 7.57476 11.0656L2.57476 5.7323C2.35442 5.49727 2.36633 5.12811 2.60136 4.90777Z\"\n fill=\"#030712\"\n />\n </svg>\n</ng-template>\n\n<ng-template #removeIcon>\n <!-- <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 12 12\"\n fill=\"none\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M2.39645 2.39645C2.59171 2.20118 2.90829 2.20118 3.10355 2.39645L6 5.29289L8.89645 2.39645C9.09171 2.20118 9.40829 2.20118 9.60355 2.39645C9.79882 2.59171 9.79882 2.90829 9.60355 3.10355L6.70711 6L9.60355 8.89645C9.79882 9.09171 9.79882 9.40829 9.60355 9.60355C9.40829 9.79882 9.09171 9.79882 8.89645 9.60355L6 6.70711L3.10355 9.60355C2.90829 9.79882 2.59171 9.79882 2.39645 9.60355C2.20118 9.40829 2.20118 9.09171 2.39645 8.89645L5.29289 6L2.39645 3.10355C2.20118 2.90829 2.20118 2.59171 2.39645 2.39645Z\"\n fill=\"#030712\"\n />\n </svg> -->\n</ng-template>\n\n<ng-template #customTpl let-selected>\n <!-- <app-status-field\n *ngIf=\"item.isStatusField\"\n [status]=\"selected.nzValue\"\n ></app-status-field> -->\n <ng-container>\n {{ selected.nzLabel }}\n </ng-container>\n</ng-template>\n", styles: ["::ng-deep .custom-filter-select{min-width:113px;min-height:32px}::ng-deep .custom-filter-select.ant-select .ant-select-selection-item{color:#030712;font-weight:500;font-size:14px}::ng-deep .custom-filter-select.ant-select-multiple .ant-select-selection-item{border-radius:4px;background:#f3f4f6;font-size:14px;font-weight:500;color:#030712;display:flex;align-items:center;gap:4px}::ng-deep .custom-filter-select.ant-select-multiple .ant-select-selection-item .ant-select-selection-item-remove{line-height:1}::ng-deep .custom-filter-select:not(.ant-select-customize-input) .ant-select-selector{border-radius:4px}::ng-deep .custom-filter-select.ant-select-focused:not(.ant-select-disabled).ant-select:not(.ant-select-customize-input) .ant-select-selector{border-radius:4px;border:1px solid #367af6;background:#fff;box-shadow:0 0 0 2px #367af61a}::ng-deep .custom-filter-select .ant-select-selection-placeholder{color:#030712;font-weight:500;font-size:14px}::ng-deep .custom-filter-select .ant-select-selection-item-content{color:#030712;font-weight:500}::ng-deep .custom-filter-select .ant-select-arrow{transition:ease-in-out .2s all;cursor:pointer;pointer-events:initial}::ng-deep .custom-filter-select:hover:has(.ant-select-clear) .ant-select-arrow{opacity:0}::ng-deep .custom-filter-select.ant-select-focused .ant-select-arrow,::ng-deep .custom-filter-select .ant-select-selector:focus-within .ant-select-arrow{transform:rotate(-180deg);transition:transform .2s ease}::ng-deep .custom-filter-select-dropdown .ant-select-dropdown,::ng-deep .custom-multiple-filter-select-dropdown .ant-select-dropdown{border-radius:4px;background:#fff;width:-moz-fit-content;width:fit-content;min-width:113px}::ng-deep .custom-filter-select-dropdown .ant-select-item-option,::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option{background-color:transparent;padding:0 6px}::ng-deep .custom-filter-select-dropdown .ant-select-item-option-content,::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-content{border-radius:4px;padding:0 6px;display:flex;align-items:center;color:#030712;font-size:14px;min-height:40px}::ng-deep .custom-filter-select-dropdown .ant-select-item-option-active .ant-select-item-option-content,::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-active .ant-select-item-option-content{background:rgba(54,122,246,.1)}::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-content{border-radius:4px;font-weight:500;color:#030712;font-size:14px;padding:0 6px 0 32px;position:relative}::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-content:before{content:\"\";position:absolute;top:50%;left:6px;width:16px;height:16px;transform:translateY(-50%);border-radius:4px;border:1px solid #9ca3af}::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-selected .ant-select-item-option-content:before{background-image:url(/assets/img/icon/checkbox.svg);background-size:contain;background-position:center;background-repeat:no-repeat;border:none}::ng-deep .custom-multiple-filter-select-dropdown .ant-select-item-option-state{display:none}\n"] }]
1105
+ }], propDecorators: { item: [{
1106
+ type: Input
1107
+ }], handleChangeValue: [{
1108
+ type: Output
1109
+ }] } });
1110
+
1111
+ function debounce(delay = 300) {
1112
+ // @ts-ignore
1113
+ return function (_target, _propertyKey, descriptor) {
1114
+ const timeoutKey = Symbol();
1115
+ const original = descriptor.value;
1116
+ descriptor.value = function (...args) {
1117
+ // @ts-ignore
1118
+ clearTimeout(this[timeoutKey]);
1119
+ // @ts-ignore
1120
+ this[timeoutKey] = setTimeout(() => original.apply(this, args), delay);
1121
+ };
1122
+ return descriptor;
1123
+ };
1124
+ }
1125
+
1126
+ class RdFilterInputComponent {
1127
+ constructor() {
1128
+ this.handleChangeValue = new EventEmitter();
1129
+ this.inputValue = '';
1130
+ }
1131
+ ngOnInit() {
1132
+ this.inputValue = this.item.value;
1133
+ }
1134
+ ngOnChanges(changes) {
1135
+ var _a;
1136
+ if ((_a = changes['item']) === null || _a === void 0 ? void 0 : _a.currentValue) {
1137
+ this.inputValue = this.item.value;
1138
+ }
1139
+ }
1140
+ handleValueChange(e) {
1141
+ this.handleChangeValue.emit(e);
1142
+ }
1143
+ }
1144
+ RdFilterInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1145
+ RdFilterInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: RdFilterInputComponent, selector: "app-rd-filter-input", inputs: { item: "item" }, outputs: { handleChangeValue: "handleChangeValue" }, usesOnChanges: true, ngImport: i0, template: "<div class=\"input-container\">\n <nz-input-group [nzPrefix]=\"prefixIconSearch\">\n <input\n type=\"text\"\n nz-input\n [placeholder]=\"item.title\"\n [(ngModel)]=\"item.value\"\n (ngModelChange)=\"handleValueChange($event)\"\n />\n </nz-input-group>\n</div>\n\n<ng-template #prefixIconSearch>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path\n d=\"M14.4951 13.6938L11.3962 10.5949C12.3175 9.46805 12.7704 8.03024 12.6613 6.57885C12.5522 5.12746 11.8894 3.77353 10.81 2.7971C9.73066 1.82066 8.3173 1.29643 6.86227 1.33283C5.40723 1.36923 4.02185 1.96348 2.99266 2.99266C1.96348 4.02184 1.36923 5.40722 1.33283 6.86225C1.29643 8.31728 1.82066 9.73064 2.7971 10.81C3.77354 11.8894 5.12747 12.5521 6.57887 12.6612C8.03026 12.7703 9.46807 12.3174 10.5949 11.3962L13.6938 14.5022C13.8027 14.6063 13.9474 14.6647 14.098 14.6653C14.2105 14.6651 14.3204 14.6315 14.4138 14.5687C14.5071 14.5059 14.5796 14.4168 14.6222 14.3126C14.6648 14.2085 14.6754 14.0941 14.6528 13.9839C14.6302 13.8737 14.5753 13.7727 14.4951 13.6938ZM7.00667 11.5451C6.10905 11.5451 5.23158 11.2789 4.48523 10.7802C3.73889 10.2816 3.15718 9.57274 2.81367 8.74345C2.47017 7.91416 2.38029 7.00162 2.55541 6.12125C2.73053 5.24087 3.16277 4.4322 3.79749 3.79748C4.43221 3.16277 5.24088 2.73052 6.12126 2.55541C7.00164 2.38029 7.91417 2.47017 8.74347 2.81367C9.57277 3.15718 10.2816 3.73888 10.7803 4.48523C11.279 5.23157 11.5451 6.10904 11.5451 7.00666C11.5433 8.20976 11.0645 9.36304 10.2138 10.2138C9.36306 11.0645 8.20977 11.5432 7.00667 11.5451Z\"\n fill=\"#030712\"\n />\n </svg>\n</ng-template>\n", styles: ["::ng-deep .ant-input-affix-wrapper{border-radius:6px}::ng-deep .ant-input-affix-wrapper:focus,::ng-deep .ant-input-affix-wrapper-focused{border-radius:4px;border:1px solid #367af6;background:#fff;box-shadow:0 0 0 2px #367af61a}.ant-input::placeholder{color:#6b7280}\n"], dependencies: [{ kind: "directive", type: i1$1.ɵNzTransitionPatchDirective, selector: "[nz-button], nz-button-group, [nz-icon], [nz-menu-item], [nz-submenu], nz-select-top-control, nz-select-placeholder, nz-input-group", inputs: ["hidden"] }, { kind: "directive", type: i2$1.NzInputDirective, selector: "input[nz-input],textarea[nz-input]", inputs: ["nzBorderless", "nzSize", "nzStatus", "disabled"], exportAs: ["nzInput"] }, { kind: "component", type: i2$1.NzInputGroupComponent, selector: "nz-input-group", inputs: ["nzAddOnBeforeIcon", "nzAddOnAfterIcon", "nzPrefixIcon", "nzSuffixIcon", "nzAddOnBefore", "nzAddOnAfter", "nzPrefix", "nzStatus", "nzSuffix", "nzSize", "nzSearch", "nzCompact"], exportAs: ["nzInputGroup"] }, { kind: "directive", type: i2$1.NzInputGroupWhitSuffixOrPrefixDirective, selector: "nz-input-group[nzSuffix], nz-input-group[nzPrefix]" }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] });
1146
+ __decorate([
1147
+ debounce()
1148
+ ], RdFilterInputComponent.prototype, "handleValueChange", null);
1149
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterInputComponent, decorators: [{
1150
+ type: Component,
1151
+ args: [{ selector: 'app-rd-filter-input', template: "<div class=\"input-container\">\n <nz-input-group [nzPrefix]=\"prefixIconSearch\">\n <input\n type=\"text\"\n nz-input\n [placeholder]=\"item.title\"\n [(ngModel)]=\"item.value\"\n (ngModelChange)=\"handleValueChange($event)\"\n />\n </nz-input-group>\n</div>\n\n<ng-template #prefixIconSearch>\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path\n d=\"M14.4951 13.6938L11.3962 10.5949C12.3175 9.46805 12.7704 8.03024 12.6613 6.57885C12.5522 5.12746 11.8894 3.77353 10.81 2.7971C9.73066 1.82066 8.3173 1.29643 6.86227 1.33283C5.40723 1.36923 4.02185 1.96348 2.99266 2.99266C1.96348 4.02184 1.36923 5.40722 1.33283 6.86225C1.29643 8.31728 1.82066 9.73064 2.7971 10.81C3.77354 11.8894 5.12747 12.5521 6.57887 12.6612C8.03026 12.7703 9.46807 12.3174 10.5949 11.3962L13.6938 14.5022C13.8027 14.6063 13.9474 14.6647 14.098 14.6653C14.2105 14.6651 14.3204 14.6315 14.4138 14.5687C14.5071 14.5059 14.5796 14.4168 14.6222 14.3126C14.6648 14.2085 14.6754 14.0941 14.6528 13.9839C14.6302 13.8737 14.5753 13.7727 14.4951 13.6938ZM7.00667 11.5451C6.10905 11.5451 5.23158 11.2789 4.48523 10.7802C3.73889 10.2816 3.15718 9.57274 2.81367 8.74345C2.47017 7.91416 2.38029 7.00162 2.55541 6.12125C2.73053 5.24087 3.16277 4.4322 3.79749 3.79748C4.43221 3.16277 5.24088 2.73052 6.12126 2.55541C7.00164 2.38029 7.91417 2.47017 8.74347 2.81367C9.57277 3.15718 10.2816 3.73888 10.7803 4.48523C11.279 5.23157 11.5451 6.10904 11.5451 7.00666C11.5433 8.20976 11.0645 9.36304 10.2138 10.2138C9.36306 11.0645 8.20977 11.5432 7.00667 11.5451Z\"\n fill=\"#030712\"\n />\n </svg>\n</ng-template>\n", styles: ["::ng-deep .ant-input-affix-wrapper{border-radius:6px}::ng-deep .ant-input-affix-wrapper:focus,::ng-deep .ant-input-affix-wrapper-focused{border-radius:4px;border:1px solid #367af6;background:#fff;box-shadow:0 0 0 2px #367af61a}.ant-input::placeholder{color:#6b7280}\n"] }]
1152
+ }], propDecorators: { item: [{
1153
+ type: Input
1154
+ }], handleChangeValue: [{
1155
+ type: Output
1156
+ }], handleValueChange: [] } });
1157
+
1158
+ class RdFilterComponent {
1159
+ get isClearAble() {
1160
+ return this.filterArr.findIndex((item) => !!item.value) > -1;
1161
+ }
1162
+ constructor(cdf) {
1163
+ this.cdf = cdf;
1164
+ this.filterArr = [];
1165
+ this.defSearchChange = new EventEmitter();
1166
+ this.clearFilter = new EventEmitter();
1167
+ this.filterTypeEnum = FilterTypeEnum;
1168
+ }
1169
+ handleChangeValue(value) {
1170
+ this.defSearchChange.emit();
1171
+ }
1172
+ clear() {
1173
+ this.clearFilter.emit();
1174
+ }
1175
+ }
1176
+ RdFilterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
1177
+ RdFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: RdFilterComponent, selector: "app-rd-filter", inputs: { filterArr: "filterArr" }, outputs: { defSearchChange: "defSearchChange", clearFilter: "clearFilter" }, ngImport: i0, template: "<div class=\"custom-filter-wrap\" *ngIf=\"filterArr?.length\">\n <ng-container *ngFor=\"let item of filterArr\">\n <ng-container [ngSwitch]=\"item.formType\">\n <app-rd-filter-date\n *ngSwitchCase=\"filterTypeEnum.date\"\n [item]=\"item\"\n (handleChangeValue)=\"handleChangeValue($event)\"\n >\n </app-rd-filter-date>\n <app-rd-filter-select\n *ngSwitchCase=\"filterTypeEnum.select\"\n [item]=\"item\"\n (handleChangeValue)=\"handleChangeValue($event)\"\n ></app-rd-filter-select>\n <app-rd-filter-input\n *ngSwitchCase=\"filterTypeEnum.input\"\n [item]=\"item\"\n (handleChangeValue)=\"handleChangeValue($event)\"\n ></app-rd-filter-input>\n </ng-container>\n </ng-container>\n <button\n [disabled]=\"!isClearAble\"\n (click)=\"clear()\"\n class=\"custom-filter-clear\"\n nz-button\n nzType=\"link\"\n >\n Clear filter\n </button>\n</div>\n", styles: [".custom-filter-wrap{display:flex;align-items:center;gap:8px;padding-top:12px}.custom-filter-clear{font-size:13px;font-weight:600;color:#367af6;padding:0}.custom-filter-clear:disabled{color:#9ca3af}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "component", type: i2$2.NzButtonComponent, selector: "button[nz-button], a[nz-button]", inputs: ["nzBlock", "nzGhost", "nzSearch", "nzLoading", "nzDanger", "disabled", "tabIndex", "nzType", "nzShape", "nzSize"], exportAs: ["nzButton"] }, { kind: "directive", type: i1$1.ɵNzTransitionPatchDirective, selector: "[nz-button], nz-button-group, [nz-icon], [nz-menu-item], [nz-submenu], nz-select-top-control, nz-select-placeholder, nz-input-group", inputs: ["hidden"] }, { kind: "component", type: RdFilterDateComponent, selector: "app-rd-filter-date", inputs: ["item"], outputs: ["handleChangeValue"] }, { kind: "component", type: RdFilterSelectComponent, selector: "app-rd-filter-select", inputs: ["item"], outputs: ["handleChangeValue"] }, { kind: "component", type: RdFilterInputComponent, selector: "app-rd-filter-input", inputs: ["item"], outputs: ["handleChangeValue"] }] });
1178
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterComponent, decorators: [{
1179
+ type: Component,
1180
+ args: [{ selector: 'app-rd-filter', template: "<div class=\"custom-filter-wrap\" *ngIf=\"filterArr?.length\">\n <ng-container *ngFor=\"let item of filterArr\">\n <ng-container [ngSwitch]=\"item.formType\">\n <app-rd-filter-date\n *ngSwitchCase=\"filterTypeEnum.date\"\n [item]=\"item\"\n (handleChangeValue)=\"handleChangeValue($event)\"\n >\n </app-rd-filter-date>\n <app-rd-filter-select\n *ngSwitchCase=\"filterTypeEnum.select\"\n [item]=\"item\"\n (handleChangeValue)=\"handleChangeValue($event)\"\n ></app-rd-filter-select>\n <app-rd-filter-input\n *ngSwitchCase=\"filterTypeEnum.input\"\n [item]=\"item\"\n (handleChangeValue)=\"handleChangeValue($event)\"\n ></app-rd-filter-input>\n </ng-container>\n </ng-container>\n <button\n [disabled]=\"!isClearAble\"\n (click)=\"clear()\"\n class=\"custom-filter-clear\"\n nz-button\n nzType=\"link\"\n >\n Clear filter\n </button>\n</div>\n", styles: [".custom-filter-wrap{display:flex;align-items:center;gap:8px;padding-top:12px}.custom-filter-clear{font-size:13px;font-weight:600;color:#367af6;padding:0}.custom-filter-clear:disabled{color:#9ca3af}\n"] }]
1181
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { filterArr: [{
1182
+ type: Input
1183
+ }], defSearchChange: [{
1184
+ type: Output
1185
+ }], clearFilter: [{
1186
+ type: Output
1187
+ }] } });
1188
+
1189
+ class RdStatusFieldModule {
1190
+ }
1191
+ RdStatusFieldModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdStatusFieldModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1192
+ RdStatusFieldModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: RdStatusFieldModule, declarations: [StatusFieldComponent], imports: [CommonModule], exports: [StatusFieldComponent] });
1193
+ RdStatusFieldModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdStatusFieldModule, imports: [CommonModule] });
1194
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdStatusFieldModule, decorators: [{
1195
+ type: NgModule,
1196
+ args: [{
1197
+ declarations: [StatusFieldComponent],
1198
+ imports: [CommonModule],
1199
+ exports: [StatusFieldComponent],
1200
+ }]
1201
+ }] });
1202
+
1203
+ class RdFilterModule {
1204
+ }
1205
+ RdFilterModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1206
+ RdFilterModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: RdFilterModule, declarations: [RdFilterComponent,
1207
+ RdFilterDateComponent,
1208
+ RdFilterSelectComponent,
1209
+ RdFilterInputComponent], imports: [CommonModule,
1210
+ NzDatePickerModule,
1211
+ NzDropDownModule,
1212
+ NzSelectModule,
1213
+ NzButtonModule,
1214
+ NzInputModule,
1215
+ FormsModule,
1216
+ RdStatusFieldModule], exports: [RdFilterComponent] });
1217
+ RdFilterModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterModule, imports: [CommonModule,
1218
+ NzDatePickerModule,
1219
+ NzDropDownModule,
1220
+ NzSelectModule,
1221
+ NzButtonModule,
1222
+ NzInputModule,
1223
+ FormsModule,
1224
+ RdStatusFieldModule] });
1225
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RdFilterModule, decorators: [{
1226
+ type: NgModule,
1227
+ args: [{
1228
+ declarations: [
1229
+ RdFilterComponent,
1230
+ RdFilterDateComponent,
1231
+ RdFilterSelectComponent,
1232
+ RdFilterInputComponent,
1233
+ ],
1234
+ imports: [
1235
+ CommonModule,
1236
+ NzDatePickerModule,
1237
+ NzDropDownModule,
1238
+ NzSelectModule,
1239
+ NzButtonModule,
1240
+ NzInputModule,
1241
+ FormsModule,
1242
+ RdStatusFieldModule,
1243
+ ],
1244
+ exports: [RdFilterComponent],
1245
+ }]
1246
+ }] });
1247
+
1248
+ class BigNumberPipe {
1249
+ transform(value, precision = 6, mode = 'cut') {
1250
+ if (!value)
1251
+ return '';
1252
+ return formatBigNumber(value, precision, mode);
1253
+ }
1254
+ }
1255
+ BigNumberPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: BigNumberPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
1256
+ BigNumberPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: BigNumberPipe, name: "bigNumber" });
1257
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: BigNumberPipe, decorators: [{
1258
+ type: Pipe,
1259
+ args: [{
1260
+ name: 'bigNumber',
1261
+ }]
1262
+ }] });
1263
+
1264
+ class PipesModule {
1265
+ }
1266
+ PipesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PipesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1267
+ PipesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: PipesModule, declarations: [BigNumberPipe], exports: [BigNumberPipe] });
1268
+ PipesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PipesModule });
1269
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PipesModule, decorators: [{
1270
+ type: NgModule,
1271
+ args: [{
1272
+ imports: [],
1273
+ exports: [BigNumberPipe],
1274
+ declarations: [BigNumberPipe],
1275
+ }]
1276
+ }] });
1277
+
1278
+ /*
1279
+ * Public API Surface of shared-lib
1280
+ */
1281
+
1282
+ /**
1283
+ * Generated bundle index. Do not edit.
1284
+ */
1285
+
1286
+ export { BigNumberPipe, CustomCheckboxComponent, CustomDateComponent, CustomInputAmountComponent, CustomInputComponent, CustomRadioComponent, CustomSelectComponent, PipesModule, RdCheckboxModule, RdDateModule, RdFilterComponent, RdFilterModule, RdInputAmountModule, RdInputModule, RdRadioModule, RdSelectModule, RdStatusFieldModule, StatusFieldComponent };
1287
+ //# sourceMappingURL=rd-outer-component.mjs.map