@eherve/angular-material-datatable 19.23.1 → 19.23.2
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.
- package/fesm2022/{eherve-angular-material-datatable-cell-checkbox-value.component-Cs6iRiE5.mjs → eherve-angular-material-datatable-cell-checkbox-value.component-hAqQu_Xe.mjs} +2 -2
- package/fesm2022/{eherve-angular-material-datatable-cell-checkbox-value.component-Cs6iRiE5.mjs.map → eherve-angular-material-datatable-cell-checkbox-value.component-hAqQu_Xe.mjs.map} +1 -1
- package/fesm2022/{eherve-angular-material-datatable-cell-date-value.component-PC25jsQl.mjs → eherve-angular-material-datatable-cell-date-value.component-BAnK6hjI.mjs} +2 -2
- package/fesm2022/{eherve-angular-material-datatable-cell-date-value.component-PC25jsQl.mjs.map → eherve-angular-material-datatable-cell-date-value.component-BAnK6hjI.mjs.map} +1 -1
- package/fesm2022/{eherve-angular-material-datatable-cell-duration-value.component-mCnxk3fO.mjs → eherve-angular-material-datatable-cell-duration-value.component-BgcvN-ds.mjs} +2 -2
- package/fesm2022/{eherve-angular-material-datatable-cell-duration-value.component-mCnxk3fO.mjs.map → eherve-angular-material-datatable-cell-duration-value.component-BgcvN-ds.mjs.map} +1 -1
- package/fesm2022/{eherve-angular-material-datatable-cell-number-value.component-4yOYghkn.mjs → eherve-angular-material-datatable-cell-number-value.component-Q8jdOixn.mjs} +2 -2
- package/fesm2022/{eherve-angular-material-datatable-cell-number-value.component-4yOYghkn.mjs.map → eherve-angular-material-datatable-cell-number-value.component-Q8jdOixn.mjs.map} +1 -1
- package/fesm2022/{eherve-angular-material-datatable-cell-select-value.component-hRxBNr9K.mjs → eherve-angular-material-datatable-cell-select-value.component-DRmVwWuY.mjs} +3 -3
- package/fesm2022/{eherve-angular-material-datatable-cell-select-value.component-hRxBNr9K.mjs.map → eherve-angular-material-datatable-cell-select-value.component-DRmVwWuY.mjs.map} +1 -1
- package/fesm2022/{eherve-angular-material-datatable-eherve-angular-material-datatable-naAMdiRT.mjs → eherve-angular-material-datatable-eherve-angular-material-datatable-CMCXpnhf.mjs} +23 -7
- package/fesm2022/eherve-angular-material-datatable-eherve-angular-material-datatable-CMCXpnhf.mjs.map +1 -0
- package/fesm2022/{eherve-angular-material-datatable-get.pipe-DiH4sy4z.mjs → eherve-angular-material-datatable-get.pipe-DXh2e-6u.mjs} +2 -2
- package/fesm2022/{eherve-angular-material-datatable-get.pipe-DiH4sy4z.mjs.map → eherve-angular-material-datatable-get.pipe-DXh2e-6u.mjs.map} +1 -1
- package/fesm2022/eherve-angular-material-datatable.mjs +1 -1
- package/lib/components/header-text-filter/header-text-filter.component.d.ts +1 -0
- package/lib/types/datatable-column.type.d.ts +1 -2
- package/package.json +1 -1
- package/fesm2022/eherve-angular-material-datatable-eherve-angular-material-datatable-naAMdiRT.mjs.map +0 -1
|
@@ -3,7 +3,7 @@ import * as i0 from '@angular/core';
|
|
|
3
3
|
import { Component, Input } from '@angular/core';
|
|
4
4
|
import * as i5 from '@angular/material/icon';
|
|
5
5
|
import { MatIconModule } from '@angular/material/icon';
|
|
6
|
-
import { GetPipe } from './eherve-angular-material-datatable-get.pipe-
|
|
6
|
+
import { GetPipe } from './eherve-angular-material-datatable-get.pipe-DXh2e-6u.mjs';
|
|
7
7
|
import { TransformPipe } from './eherve-angular-material-datatable-transform.pipe-BOmcXXZU.mjs';
|
|
8
8
|
|
|
9
9
|
/** @format */
|
|
@@ -23,4 +23,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImpor
|
|
|
23
23
|
}] } });
|
|
24
24
|
|
|
25
25
|
export { CellCheckboxValueComponent };
|
|
26
|
-
//# sourceMappingURL=eherve-angular-material-datatable-cell-checkbox-value.component-
|
|
26
|
+
//# sourceMappingURL=eherve-angular-material-datatable-cell-checkbox-value.component-hAqQu_Xe.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eherve-angular-material-datatable-cell-checkbox-value.component-
|
|
1
|
+
{"version":3,"file":"eherve-angular-material-datatable-cell-checkbox-value.component-hAqQu_Xe.mjs","sources":["../../../projects/datatable/src/lib/components/cell-checkbox-value/cell-checkbox-value.component.ts","../../../projects/datatable/src/lib/components/cell-checkbox-value/cell-checkbox-value.component.html"],"sourcesContent":["/** @format */\n\nimport { CommonModule } from '@angular/common';\nimport { Component, Input } from '@angular/core';\nimport { MatIconModule } from '@angular/material/icon';\nimport { GetPipe } from '../../pipes/get.pipe';\nimport { TransformPipe } from '../../pipes/transform.pipe';\nimport { DatatableCheckboxColumn } from '../../types/datatable-column.type';\n\n@Component({\n selector: 'lib-cell-checkbox-value',\n imports: [CommonModule, GetPipe, MatIconModule, TransformPipe],\n templateUrl: './cell-checkbox-value.component.html',\n styleUrl: './cell-checkbox-value.component.scss',\n})\nexport class CellCheckboxValueComponent<Record> {\n @Input()\n column!: DatatableCheckboxColumn<Record>;\n\n @Input()\n row: any;\n}\n","<!-- @format -->\n\n@let value = row | get: column.property | transform: row : column;\n@if (value === false) {\n <mat-icon>check_box_outline_blank</mat-icon>\n} @else if (value === true) {\n <mat-icon>check_box</mat-icon>\n}\n"],"names":["i1"],"mappings":";;;;;;;;AAAA;MAea,0BAA0B,CAAA;AAErC,IAAA,MAAM;AAGN,IAAA,GAAG;uGALQ,0BAA0B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAA1B,0BAA0B,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,yBAAA,EAAA,MAAA,EAAA,EAAA,MAAA,EAAA,QAAA,EAAA,GAAA,EAAA,KAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,ECfvC,uOAQA,EDGY,MAAA,EAAA,CAAA,mEAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,YAAY,0BAAE,OAAO,EAAA,IAAA,EAAA,KAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAE,aAAa,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAAA,EAAA,CAAA,OAAA,EAAA,QAAA,EAAA,UAAA,EAAA,MAAA,EAAA,CAAA,OAAA,EAAA,QAAA,EAAA,SAAA,EAAA,SAAA,EAAA,UAAA,CAAA,EAAA,QAAA,EAAA,CAAA,SAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,MAAA,EAAA,IAAA,EAAE,aAAa,EAAA,IAAA,EAAA,WAAA,EAAA,CAAA,EAAA,CAAA;;2FAIlD,0BAA0B,EAAA,UAAA,EAAA,CAAA;kBANtC,SAAS;+BACE,yBAAyB,EAAA,OAAA,EAC1B,CAAC,YAAY,EAAE,OAAO,EAAE,aAAa,EAAE,aAAa,CAAC,EAAA,QAAA,EAAA,uOAAA,EAAA,MAAA,EAAA,CAAA,mEAAA,CAAA,EAAA;8BAM9D,MAAM,EAAA,CAAA;sBADL;gBAID,GAAG,EAAA,CAAA;sBADF;;;;;"}
|
|
@@ -3,7 +3,7 @@ import * as i0 from '@angular/core';
|
|
|
3
3
|
import { Pipe, inject, ChangeDetectorRef, Component, Input } from '@angular/core';
|
|
4
4
|
import { MatIconModule } from '@angular/material/icon';
|
|
5
5
|
import moment from 'moment';
|
|
6
|
-
import { g as get, d as duration } from './eherve-angular-material-datatable-eherve-angular-material-datatable-
|
|
6
|
+
import { g as get, d as duration } from './eherve-angular-material-datatable-eherve-angular-material-datatable-CMCXpnhf.mjs';
|
|
7
7
|
|
|
8
8
|
/** @format */
|
|
9
9
|
class MomentFormatPipe {
|
|
@@ -80,4 +80,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImpor
|
|
|
80
80
|
}] } });
|
|
81
81
|
|
|
82
82
|
export { CellDateValueComponent };
|
|
83
|
-
//# sourceMappingURL=eherve-angular-material-datatable-cell-date-value.component-
|
|
83
|
+
//# sourceMappingURL=eherve-angular-material-datatable-cell-date-value.component-BAnK6hjI.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eherve-angular-material-datatable-cell-date-value.component-
|
|
1
|
+
{"version":3,"file":"eherve-angular-material-datatable-cell-date-value.component-BAnK6hjI.mjs","sources":["../../../projects/datatable/src/lib/pipes/moment-format.pipe.ts","../../../projects/datatable/src/lib/components/cell-date-value/cell-date-value.component.ts","../../../projects/datatable/src/lib/components/cell-date-value/cell-date-value.component.html"],"sourcesContent":["/** @format */\n\nimport { Pipe, PipeTransform } from '@angular/core';\nimport moment, { Moment } from 'moment';\n\n@Pipe({ name: 'momentFormat' })\nexport class MomentFormatPipe implements PipeTransform {\n transform(data: any, options: { format?: string; locale?: string }): string {\n const date = this.getMoment(data);\n if (!date) return '';\n const format = options?.format || 'LLL';\n return options?.locale ? date.locale(options.locale).format(format) : date.format(format);\n }\n\n private getMoment(data: any): Moment | null {\n if (typeof data === 'string') return moment(data);\n if (typeof data === 'number') return moment(data);\n if (data instanceof Date) return moment(data);\n if (moment.isMoment(data)) return data.clone();\n if (typeof data?.valueOf === 'function') {\n const value = data.valueOf();\n if (typeof value === 'number') return moment(data);\n }\n return null;\n }\n}\n","/** @format */\n\nimport { CommonModule } from '@angular/common';\nimport { ChangeDetectorRef, Component, inject, Input, OnDestroy, OnInit } from '@angular/core';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MomentFormatPipe } from '../../pipes/moment-format.pipe';\nimport { duration } from '../../tools/duration.tool';\nimport { get } from '../../tools/get.tool';\nimport { DatatableDateColumn, DatatableValueColumn } from '../../types/datatable-column.type';\n\n@Component({\n selector: 'lib-cell-date-value',\n imports: [CommonModule, MatIconModule, MomentFormatPipe],\n templateUrl: './cell-date-value.component.html',\n styleUrl: './cell-date-value.component.scss',\n})\nexport class CellDateValueComponent<Record> implements OnInit, OnDestroy {\n private changeDetectorRef = inject(ChangeDetectorRef);\n\n @Input()\n column!: DatatableDateColumn<Record>;\n\n @Input('row')\n set setRow(row: any) {\n this.row = row;\n this.value = get(this.row, this.column.property);\n if (typeof (this.column as DatatableValueColumn<Record>).transform === 'function') {\n this.value = (this.column as DatatableValueColumn<Record>).transform!(this.value, this.row);\n }\n this.duration = duration(this.value, this.column);\n }\n row: any;\n\n value?: any;\n duration?: string | null;\n\n private refreshInterval: any;\n ngOnInit(): void {\n if (this.column.durationRefreshTime) {\n this.refreshInterval = setInterval(() => {\n this.duration = duration(this.value, this.column);\n this.changeDetectorRef.detectChanges();\n }, this.column.durationRefreshTime);\n }\n }\n\n ngOnDestroy(): void {\n if (this.refreshInterval) clearInterval(this.refreshInterval);\n }\n}\n","<!-- @format -->\n\n@if (value) {\n <span class=\"date\"> {{ value | momentFormat: column }} </span>\n @if (column.withDuration) {\n <span class=\"duration\"> ({{ duration }}) </span>\n }\n}\n"],"names":[],"mappings":";;;;;;;AAAA;MAMa,gBAAgB,CAAA;IAC3B,SAAS,CAAC,IAAS,EAAE,OAA6C,EAAA;QAChE,MAAM,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC;AACjC,QAAA,IAAI,CAAC,IAAI;AAAE,YAAA,OAAO,EAAE;AACpB,QAAA,MAAM,MAAM,GAAG,OAAO,EAAE,MAAM,IAAI,KAAK;AACvC,QAAA,OAAO,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC;;AAGnF,IAAA,SAAS,CAAC,IAAS,EAAA;QACzB,IAAI,OAAO,IAAI,KAAK,QAAQ;AAAE,YAAA,OAAO,MAAM,CAAC,IAAI,CAAC;QACjD,IAAI,OAAO,IAAI,KAAK,QAAQ;AAAE,YAAA,OAAO,MAAM,CAAC,IAAI,CAAC;QACjD,IAAI,IAAI,YAAY,IAAI;AAAE,YAAA,OAAO,MAAM,CAAC,IAAI,CA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ADT,KAAK;uBAAC,KAAK;;;;;"}
|
|
@@ -2,7 +2,7 @@ import { CommonModule } from '@angular/common';
|
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
import { Component, Input } from '@angular/core';
|
|
4
4
|
import { MatIconModule } from '@angular/material/icon';
|
|
5
|
-
import { g as get, d as duration } from './eherve-angular-material-datatable-eherve-angular-material-datatable-
|
|
5
|
+
import { g as get, d as duration } from './eherve-angular-material-datatable-eherve-angular-material-datatable-CMCXpnhf.mjs';
|
|
6
6
|
|
|
7
7
|
/** @format */
|
|
8
8
|
class CellDurationValueComponent {
|
|
@@ -32,4 +32,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImpor
|
|
|
32
32
|
}] } });
|
|
33
33
|
|
|
34
34
|
export { CellDurationValueComponent };
|
|
35
|
-
//# sourceMappingURL=eherve-angular-material-datatable-cell-duration-value.component-
|
|
35
|
+
//# sourceMappingURL=eherve-angular-material-datatable-cell-duration-value.component-BgcvN-ds.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eherve-angular-material-datatable-cell-duration-value.component-
|
|
1
|
+
{"version":3,"file":"eherve-angular-material-datatable-cell-duration-value.component-BgcvN-ds.mjs","sources":["../../../projects/datatable/src/lib/components/cell-duration-value/cell-duration-value.component.ts","../../../projects/datatable/src/lib/components/cell-duration-value/cell-duration-value.component.html"],"sourcesContent":["/** @format */\n\nimport { CommonModule } from '@angular/common';\nimport { ChangeDetectorRef, Component, inject, Input } from '@angular/core';\nimport { MatIconModule } from '@angular/material/icon';\nimport { duration } from '../../tools/duration.tool';\nimport { get } from '../../tools/get.tool';\nimport { DatatableDurationColumn, DatatableValueColumn } from '../../types/datatable-column.type';\n\n@Component({\n selector: 'lib-cell-duration-value',\n imports: [CommonModule, MatIconModule],\n templateUrl: './cell-duration-value.component.html',\n styleUrl: './cell-duration-value.component.scss',\n})\nexport class CellDurationValueComponent<Record> {\n @Input()\n column!: DatatableDurationColumn<Record>;\n\n @Input('row')\n set setRow(row: any) {\n this.row = row;\n this.value = get(this.row, this.column.property);\n if (typeof (this.column as DatatableValueColumn<Record>).transform === 'function') {\n this.value = (this.column as DatatableValueColumn<Record>).transform!(this.value, this.row);\n }\n this.duration = duration(this.value, this.column);\n }\n row: any;\n\n value?: any;\n duration?: string | null;\n}\n","<!-- @format -->\n\n@if (duration !== null) {\n {{ duration }}\n}\n"],"names":[],"mappings":";;;;;;AAAA;MAea,0BAA0B,CAAA;AAErC,IAAA,MAAM;IAEN,IACI,MAAM,CAAC,GAAQ,EAAA;AACjB,QAAA,IAAI,CAAC,GAAG,GAAG,GAAG;AACd,QAAA,IAAI,CAAC,KAAK,GAAG,GAAG,CAAC,IAAI,CAAC,GAAG,EAAE,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC;QAChD,IAAI,OAAQ,IAAI,CAAC,MAAuC,CAAC,SAAS,KAAK,UAAU,EAAE;AACjF,YAAA,IAAI,CAAC,KAAK,GAAI,IAAI,CAAC,MAAuC,CAAC,SAAU,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,GAAG,CAAC;;AAE7F,QAAA,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,MAAM,CAAC;;AAEnD,IAAA,GAAG;AAEH,IAAA,KAAK;AACL,IAAA,QAAQ;uGAhBG,0BAA0B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAA1B,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,0BAA0B,ECfvC,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,yBAAA,EAAA,MAAA,EAAA,EAAA,MAAA,EAAA,QAAA,EAAA,MAAA,EAAA,CAAA,KAAA,EAAA,QAAA,CAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAAA,sEAKA,EDMY,MAAA,EAAA,CAAA,EAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,YAAY,8BAAE,aAAa,EAAA,CAAA,EAAA,CAAA;;2FAI1B,0BAA0B,EAAA,UAAA,EAAA,CAAA;kBANtC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,yBAAyB,EAC1B,OAAA,EAAA,CAAC,YAAY,EAAE,aAAa,CAAC,EAAA,QAAA,EAAA,sEAAA,EAAA;8BAMtC,MAAM,EAAA,CAAA;sBADL;gBAIG,MAAM,EAAA,CAAA;sBADT,KAAK;uBAAC,KAAK;;;;;"}
|
|
@@ -3,7 +3,7 @@ import { CommonModule } from '@angular/common';
|
|
|
3
3
|
import * as i0 from '@angular/core';
|
|
4
4
|
import { Component, Input } from '@angular/core';
|
|
5
5
|
import { MatIconModule } from '@angular/material/icon';
|
|
6
|
-
import { GetPipe } from './eherve-angular-material-datatable-get.pipe-
|
|
6
|
+
import { GetPipe } from './eherve-angular-material-datatable-get.pipe-DXh2e-6u.mjs';
|
|
7
7
|
import { TransformPipe } from './eherve-angular-material-datatable-transform.pipe-BOmcXXZU.mjs';
|
|
8
8
|
|
|
9
9
|
/** @format */
|
|
@@ -23,4 +23,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImpor
|
|
|
23
23
|
}] } });
|
|
24
24
|
|
|
25
25
|
export { CellNumberValueComponent };
|
|
26
|
-
//# sourceMappingURL=eherve-angular-material-datatable-cell-number-value.component-
|
|
26
|
+
//# sourceMappingURL=eherve-angular-material-datatable-cell-number-value.component-Q8jdOixn.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eherve-angular-material-datatable-cell-number-value.component-
|
|
1
|
+
{"version":3,"file":"eherve-angular-material-datatable-cell-number-value.component-Q8jdOixn.mjs","sources":["../../../projects/datatable/src/lib/components/cell-number-value/cell-number-value.component.ts","../../../projects/datatable/src/lib/components/cell-number-value/cell-number-value.component.html"],"sourcesContent":["/** @format */\n\nimport { CommonModule } from '@angular/common';\nimport { Component, Input } from '@angular/core';\nimport { MatIconModule } from '@angular/material/icon';\nimport { GetPipe } from '../../pipes/get.pipe';\nimport { TransformPipe } from '../../pipes/transform.pipe';\nimport { DatatableNumberColumn } from '../../types/datatable-column.type';\n\n@Component({\n selector: 'lib-cell-number-value',\n imports: [CommonModule, GetPipe, MatIconModule, TransformPipe],\n templateUrl: './cell-number-value.component.html',\n styleUrl: './cell-number-value.component.scss',\n})\nexport class CellNumberValueComponent<Record> {\n @Input()\n column!: DatatableNumberColumn<Record>;\n\n @Input()\n row: any;\n}\n","<!-- @format -->\n\n@let value = row | get: column.property;\n{{ value | transform: row : column | number: column.format : column.locale }}\n"],"names":[],"mappings":";;;;;;;;AAAA;MAea,wBAAwB,CAAA;AAEnC,IAAA,MAAM;AAGN,IAAA,GAAG;uGALQ,wBAAwB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAxB,wBAAwB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,uBAAA,EAAA,MAAA,EAAA,EAAA,MAAA,EAAA,QAAA,EAAA,GAAA,EAAA,KAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,ECfrC,+IAIA,EDOY,MAAA,EAAA,CAAA,yBAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,YAAY,kFAAE,OAAO,EAAA,IAAA,EAAA,KAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAE,aAAa,EAAA,EAAA,EAAA,IAAA,EAAA,MAAA,EAAA,IAAA,EAAE,aAAa,EAAA,IAAA,EAAA,WAAA,EAAA,CAAA,EAAA,CAAA;;2FAIlD,wBAAwB,EAAA,UAAA,EAAA,CAAA;kBANpC,SAAS;+BACE,uBAAuB,EAAA,OAAA,EACxB,CAAC,YAAY,EAAE,OAAO,EAAE,aAAa,EAAE,aAAa,CAAC,EAAA,QAAA,EAAA,+IAAA,EAAA,MAAA,EAAA,CAAA,yBAAA,CAAA,EAAA;8BAM9D,MAAM,EAAA,CAAA;sBADL;gBAID,GAAG,EAAA,CAAA;sBADF;;;;;"}
|
|
@@ -5,8 +5,8 @@ import { Component, Input } from '@angular/core';
|
|
|
5
5
|
import { MatLabel } from '@angular/material/form-field';
|
|
6
6
|
import * as i5 from '@angular/material/icon';
|
|
7
7
|
import { MatIconModule } from '@angular/material/icon';
|
|
8
|
-
import { GetPipe } from './eherve-angular-material-datatable-get.pipe-
|
|
9
|
-
import { S as SelectOptionPipe, I as IsArrayPipe, a as SafeHtmlPipe } from './eherve-angular-material-datatable-eherve-angular-material-datatable-
|
|
8
|
+
import { GetPipe } from './eherve-angular-material-datatable-get.pipe-DXh2e-6u.mjs';
|
|
9
|
+
import { S as SelectOptionPipe, I as IsArrayPipe, a as SafeHtmlPipe } from './eherve-angular-material-datatable-eherve-angular-material-datatable-CMCXpnhf.mjs';
|
|
10
10
|
import { TransformPipe } from './eherve-angular-material-datatable-transform.pipe-BOmcXXZU.mjs';
|
|
11
11
|
import { Subscription } from 'rxjs';
|
|
12
12
|
|
|
@@ -39,4 +39,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImpor
|
|
|
39
39
|
}] } });
|
|
40
40
|
|
|
41
41
|
export { CellSelectValueComponent };
|
|
42
|
-
//# sourceMappingURL=eherve-angular-material-datatable-cell-select-value.component-
|
|
42
|
+
//# sourceMappingURL=eherve-angular-material-datatable-cell-select-value.component-DRmVwWuY.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eherve-angular-material-datatable-cell-select-value.component-
|
|
1
|
+
{"version":3,"file":"eherve-angular-material-datatable-cell-select-value.component-DRmVwWuY.mjs","sources":["../../../projects/datatable/src/lib/components/cell-select-value/cell-select-value.component.ts","../../../projects/datatable/src/lib/components/cell-select-value/cell-select-value.component.html"],"sourcesContent":["/** @format */\n\nimport { CommonModule } from '@angular/common';\nimport { Component, Input, OnDestroy, OnInit } from '@angular/core';\nimport { MatLabel } from '@angular/material/form-field';\nimport { MatIconModule } from '@angular/material/icon';\nimport { GetPipe } from '../../pipes/get.pipe';\nimport { SafeHtmlPipe } from '../../pipes/safe-html.pipe';\nimport { SelectOptionPipe } from '../../pipes/select-option.pipe';\nimport { TransformPipe } from '../../pipes/transform.pipe';\nimport { DatatableSearchListOption, DatatableSelectColumn } from '../../types/datatable-column.type';\nimport { IsArrayPipe } from '../../pipes/is-array.pipe';\nimport { Subscription } from 'rxjs';\n\n@Component({\n selector: 'lib-cell-select-value',\n imports: [CommonModule, SelectOptionPipe, GetPipe, IsArrayPipe, MatIconModule, MatLabel, TransformPipe, SafeHtmlPipe],\n templateUrl: './cell-select-value.component.html',\n styleUrl: './cell-select-value.component.scss',\n})\nexport class CellSelectValueComponent<Record> implements OnInit, OnDestroy {\n @Input()\n column!: DatatableSelectColumn<Record>;\n\n @Input()\n row: any;\n\n options: DatatableSearchListOption[] = [];\n\n private subsink = new Subscription();\n\n ngOnInit(): void {\n if (Array.isArray(this.column.options)) this.options = this.column.options;\n else {\n this.subsink.add(this.column.options.subscribe(options => (this.options = options)));\n }\n }\n\n ngOnDestroy(): void {\n this.subsink.unsubscribe();\n }\n}\n","<!-- @format -->\n\n@let value = row | get: column.property | transform: row : column;\n\n@if (column.isArrayValue && value | isArray) {\n <div id=\"options\">\n @for (v of value; track v) {\n <ng-container *ngTemplateOutlet=\"optionTmpl; context: { value: v }\"></ng-container>\n }\n </div>\n} @else {\n <ng-container *ngTemplateOutlet=\"optionTmpl; context: { value }\"></ng-container>\n}\n\n<ng-template #optionTmpl let-value=\"value\">\n @let option = value | selectOption: options;\n @if (option) {\n <div class=\"option\">\n @if (option.icon) {\n <mat-icon [style.color]=\"option.iconColor\" [style.margin-right.px]=\"8\">\n {{ option.icon }}\n </mat-icon>\n }\n <mat-label *ngIf=\"!column.iconOnly\" [style.color]=\"option.color\" [innerHTML]=\"option.name | safeHtml\"></mat-label>\n </div>\n } @else {\n {{ value }}\n }\n</ng-template>\n"],"names":["i2"],"mappings":";;;;;;;;;;;;AAAA;MAoBa,wBAAwB,CAAA;AAEnC,IAAA,MAAM;AAGN,IAAA,GAAG;IAEH,OAAO,GAAgC,EAAE;AAEjC,IAAA,OAAO,GAAG,IAAI,YAAY,EAAE;IAEpC,QAAQ,GAAA;QACN,IAAI,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC;YAAE,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,MAAM,CAAC,OAAO;aACrE;YACH,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,OAAO,KAAK,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC,CAAC,CAAC;;;IAIxF,WAAW,GAAA;AACT,QAAA,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE;;uGAnBjB,wBAAwB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAxB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,wBAAwB,2HCpBrC,i5BA6BA,EAAA,MAAA,EAAA,CAAA,4bAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EDbY,YAAY,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,EAAA,CAAA,IAAA,EAAA,QAAA,EAAA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AG,EAAA,CAAA;sBADF;;;;;"}
|
|
@@ -953,8 +953,15 @@ class HeaderTextFilterComponent {
|
|
|
953
953
|
changeDetectorRef = inject(ChangeDetectorRef);
|
|
954
954
|
subsink = new Subscription();
|
|
955
955
|
writeValue = (value) => {
|
|
956
|
-
if (
|
|
957
|
-
this.selectControl.
|
|
956
|
+
if (this.column.regex) {
|
|
957
|
+
if (value?.value !== this.selectControl.value)
|
|
958
|
+
this.selectControl.setValue(value?.value);
|
|
959
|
+
}
|
|
960
|
+
else {
|
|
961
|
+
const val = this.escapeRegExp(this.selectControl.value);
|
|
962
|
+
if (val !== (value?.value ?? ''))
|
|
963
|
+
this.selectControl.setValue(val);
|
|
964
|
+
}
|
|
958
965
|
};
|
|
959
966
|
registerOnChange(onChange) {
|
|
960
967
|
this.onChange = onChange;
|
|
@@ -970,14 +977,23 @@ class HeaderTextFilterComponent {
|
|
|
970
977
|
this.subsink.add(this.selectControl.valueChanges.subscribe((value) => {
|
|
971
978
|
if (!value)
|
|
972
979
|
this.control.setValue(undefined);
|
|
973
|
-
else
|
|
974
|
-
|
|
980
|
+
else {
|
|
981
|
+
if (this.column.regex)
|
|
982
|
+
this.control.setValue({ value, regex: true });
|
|
983
|
+
else
|
|
984
|
+
this.control.setValue({ value: this.escapeRegExp(value), regex: true });
|
|
985
|
+
}
|
|
975
986
|
}));
|
|
976
987
|
this.changeDetectorRef.detectChanges();
|
|
977
988
|
}
|
|
978
989
|
ngOnDestroy() {
|
|
979
990
|
this.subsink.unsubscribe();
|
|
980
991
|
}
|
|
992
|
+
escapeRegExp(value) {
|
|
993
|
+
if (!value)
|
|
994
|
+
return '';
|
|
995
|
+
return value.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
|
996
|
+
}
|
|
981
997
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: HeaderTextFilterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
982
998
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.4", type: HeaderTextFilterComponent, isStandalone: true, selector: "lib-header-text-filter", inputs: { column: "column" }, providers: [
|
|
983
999
|
{
|
|
@@ -1861,9 +1877,9 @@ class NgxMatDatatableComponent {
|
|
|
1861
1877
|
animate('0.2s', style({ opacity: 0 })), // final
|
|
1862
1878
|
]),
|
|
1863
1879
|
]),
|
|
1864
|
-
], deferBlockDependencies: [() => [import('./eherve-angular-material-datatable-cell-checkbox-value.component-
|
|
1880
|
+
], deferBlockDependencies: [() => [import('./eherve-angular-material-datatable-cell-checkbox-value.component-hAqQu_Xe.mjs').then(m => m.CellCheckboxValueComponent), import('./eherve-angular-material-datatable-cell-date-value.component-BAnK6hjI.mjs').then(m => m.CellDateValueComponent), import('./eherve-angular-material-datatable-cell-duration-value.component-BgcvN-ds.mjs').then(m => m.CellDurationValueComponent), import('./eherve-angular-material-datatable-cell-number-value.component-Q8jdOixn.mjs').then(m => m.CellNumberValueComponent), import('./eherve-angular-material-datatable-cell-select-value.component-DRmVwWuY.mjs').then(m => m.CellSelectValueComponent), i1$1.NgComponentOutlet, i1$1.NgTemplateOutlet, import('./eherve-angular-material-datatable-transform.pipe-BOmcXXZU.mjs').then(m => m.TransformPipe), FindContentPipe, import('./eherve-angular-material-datatable-get.pipe-DXh2e-6u.mjs').then(m => m.GetPipe), Promise.resolve().then(function () { return safeHtml_pipe; }).then(m => m.SafeHtmlPipe), import('./eherve-angular-material-datatable-suffix-function.pipe-CQO-ghpR.mjs').then(m => m.ValueFunctionPipe)]] });
|
|
1865
1881
|
}
|
|
1866
|
-
i0.ɵɵngDeclareClassMetadataAsync({ minVersion: "18.0.0", version: "19.0.4", ngImport: i0, type: NgxMatDatatableComponent, resolveDeferredDeps: () => [import('./eherve-angular-material-datatable-cell-checkbox-value.component-
|
|
1882
|
+
i0.ɵɵngDeclareClassMetadataAsync({ minVersion: "18.0.0", version: "19.0.4", ngImport: i0, type: NgxMatDatatableComponent, resolveDeferredDeps: () => [import('./eherve-angular-material-datatable-cell-checkbox-value.component-hAqQu_Xe.mjs').then(m => m.CellCheckboxValueComponent), import('./eherve-angular-material-datatable-cell-date-value.component-BAnK6hjI.mjs').then(m => m.CellDateValueComponent), import('./eherve-angular-material-datatable-cell-duration-value.component-BgcvN-ds.mjs').then(m => m.CellDurationValueComponent), import('./eherve-angular-material-datatable-cell-number-value.component-Q8jdOixn.mjs').then(m => m.CellNumberValueComponent), import('./eherve-angular-material-datatable-cell-select-value.component-DRmVwWuY.mjs').then(m => m.CellSelectValueComponent), import('./eherve-angular-material-datatable-transform.pipe-BOmcXXZU.mjs').then(m => m.TransformPipe), import('./eherve-angular-material-datatable-get.pipe-DXh2e-6u.mjs').then(m => m.GetPipe), Promise.resolve().then(function () { return safeHtml_pipe; }).then(m => m.SafeHtmlPipe), import('./eherve-angular-material-datatable-suffix-function.pipe-CQO-ghpR.mjs').then(m => m.ValueFunctionPipe)], resolveMetadata: (CellCheckboxValueComponent, CellDateValueComponent, CellDurationValueComponent, CellNumberValueComponent, CellSelectValueComponent, TransformPipe, GetPipe, SafeHtmlPipe, ValueFunctionPipe) => ({ decorators: [{
|
|
1867
1883
|
type: Component,
|
|
1868
1884
|
args: [{ imports: [
|
|
1869
1885
|
CellCheckboxValueComponent,
|
|
@@ -1994,4 +2010,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImpor
|
|
|
1994
2010
|
*/
|
|
1995
2011
|
|
|
1996
2012
|
export { IsArrayPipe as I, NgxMatDatatableModule as N, SelectOptionPipe as S, SafeHtmlPipe as a, NgxMatDatatableComponent as b, NgxMatDatatableContentDirective as c, duration as d, NgxMatDatatableIntl as e, get as g };
|
|
1997
|
-
//# sourceMappingURL=eherve-angular-material-datatable-eherve-angular-material-datatable-
|
|
2013
|
+
//# sourceMappingURL=eherve-angular-material-datatable-eherve-angular-material-datatable-CMCXpnhf.mjs.map
|