@ts-core/angular 13.1.0 → 13.1.3
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/component/cdk-table/cell/CdkTableCellValuePipe.d.ts +9 -4
- package/component/cdk-table/column/ICdkTableColumn.d.ts +2 -1
- package/esm2020/component/cdk-table/cell/CdkTableCellValuePipe.mjs +40 -7
- package/esm2020/component/cdk-table/column/ICdkTableColumn.mjs +1 -1
- package/fesm2015/ts-core-angular.mjs +38 -7
- package/fesm2015/ts-core-angular.mjs.map +1 -1
- package/fesm2020/ts-core-angular.mjs +38 -7
- package/fesm2020/ts-core-angular.mjs.map +1 -1
- package/package.json +2 -2
|
@@ -10,7 +10,7 @@ import numeral from 'numeral';
|
|
|
10
10
|
import * as i1 from '@angular/material/dialog';
|
|
11
11
|
import { MatDialogConfig, MatDialogModule, MatDialog } from '@angular/material/dialog';
|
|
12
12
|
import * as i4 from '@angular/common';
|
|
13
|
-
import { CommonModule, DatePipe } from '@angular/common';
|
|
13
|
+
import { CommonModule, AsyncPipe, DatePipe } from '@angular/common';
|
|
14
14
|
import * as i5 from '@angular/forms';
|
|
15
15
|
import { FormsModule, Validators } from '@angular/forms';
|
|
16
16
|
import * as Cookie from 'ngx-cookie';
|
|
@@ -7719,24 +7719,55 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
7719
7719
|
}]
|
|
7720
7720
|
}] });
|
|
7721
7721
|
|
|
7722
|
-
class CdkTableCellValuePipe {
|
|
7722
|
+
class CdkTableCellValuePipe extends DestroyableContainer {
|
|
7723
|
+
// --------------------------------------------------------------------------
|
|
7724
|
+
//
|
|
7725
|
+
// Constructor
|
|
7726
|
+
//
|
|
7727
|
+
// --------------------------------------------------------------------------
|
|
7728
|
+
constructor(detection) {
|
|
7729
|
+
super();
|
|
7730
|
+
this.detection = detection;
|
|
7731
|
+
}
|
|
7723
7732
|
// --------------------------------------------------------------------------
|
|
7724
7733
|
//
|
|
7725
7734
|
// Public Methods
|
|
7726
7735
|
//
|
|
7727
7736
|
// --------------------------------------------------------------------------
|
|
7728
7737
|
transform(item, column) {
|
|
7729
|
-
|
|
7738
|
+
if (_.isNil(column.format)) {
|
|
7739
|
+
return item[column.name];
|
|
7740
|
+
}
|
|
7741
|
+
let result = column.format(item, column);
|
|
7742
|
+
if (!(result instanceof Promise)) {
|
|
7743
|
+
return result;
|
|
7744
|
+
}
|
|
7745
|
+
if (_.isNil(this.asyncPipe)) {
|
|
7746
|
+
this.asyncPipe = new AsyncPipe(this.detection);
|
|
7747
|
+
}
|
|
7748
|
+
return this.asyncPipe.transform(result);
|
|
7749
|
+
}
|
|
7750
|
+
destroy() {
|
|
7751
|
+
if (this.isDestroyed) {
|
|
7752
|
+
return;
|
|
7753
|
+
}
|
|
7754
|
+
super.destroy();
|
|
7755
|
+
if (!_.isNil(this.asyncPipe)) {
|
|
7756
|
+
this.asyncPipe.ngOnDestroy();
|
|
7757
|
+
this.asyncPipe = null;
|
|
7758
|
+
}
|
|
7759
|
+
this.detection = null;
|
|
7730
7760
|
}
|
|
7731
7761
|
}
|
|
7732
|
-
CdkTableCellValuePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: CdkTableCellValuePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
7733
|
-
CdkTableCellValuePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: CdkTableCellValuePipe, name: "viCdkTableCellValue" });
|
|
7762
|
+
CdkTableCellValuePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: CdkTableCellValuePipe, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Pipe });
|
|
7763
|
+
CdkTableCellValuePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: CdkTableCellValuePipe, name: "viCdkTableCellValue", pure: false });
|
|
7734
7764
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: CdkTableCellValuePipe, decorators: [{
|
|
7735
7765
|
type: Pipe,
|
|
7736
7766
|
args: [{
|
|
7737
|
-
name: 'viCdkTableCellValue'
|
|
7767
|
+
name: 'viCdkTableCellValue',
|
|
7768
|
+
pure: false
|
|
7738
7769
|
}]
|
|
7739
|
-
}] });
|
|
7770
|
+
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; } });
|
|
7740
7771
|
|
|
7741
7772
|
class CdkTableRowClassNamePipe {
|
|
7742
7773
|
// --------------------------------------------------------------------------
|