@porscheinformatik/clr-addons 15.8.2 → 15.8.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/fesm2020/clr-addons.mjs
CHANGED
|
@@ -3615,32 +3615,29 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
|
|
|
3615
3615
|
}] } });
|
|
3616
3616
|
|
|
3617
3617
|
/*
|
|
3618
|
-
* Copyright (c) 2018-
|
|
3618
|
+
* Copyright (c) 2018-2024 Porsche Informatik. All Rights Reserved.
|
|
3619
3619
|
* This software is released under MIT license.
|
|
3620
3620
|
* The full license information can be found in LICENSE in the root directory of this project.
|
|
3621
3621
|
*/
|
|
3622
3622
|
ClarityIcons.addIcons(angleIcon);
|
|
3623
3623
|
class ClrTreetableRow {
|
|
3624
|
-
set clrExpandable(expandable) {
|
|
3625
|
-
setTimeout(() => {
|
|
3626
|
-
this.expandable = expandable;
|
|
3627
|
-
this.changeDetectorRef.markForCheck();
|
|
3628
|
-
});
|
|
3629
|
-
}
|
|
3630
3624
|
set actionOverflow(actionOverflow) {
|
|
3631
3625
|
this.showActionOverflow = !!actionOverflow;
|
|
3632
3626
|
this.showEmptyActionOverflow = !this.showActionOverflow;
|
|
3633
3627
|
this.hasActionOverflow.emit(this.showActionOverflow);
|
|
3634
3628
|
}
|
|
3635
|
-
constructor(
|
|
3636
|
-
this.changeDetectorRef = changeDetectorRef;
|
|
3629
|
+
constructor() {
|
|
3637
3630
|
this.expanded = false;
|
|
3638
3631
|
this.clickable = true;
|
|
3632
|
+
this.expandable = false;
|
|
3639
3633
|
this.hasActionOverflow = new EventEmitter();
|
|
3640
3634
|
this.expandedChange = new EventEmitter();
|
|
3641
3635
|
this.showActionOverflow = false;
|
|
3642
3636
|
this.showEmptyActionOverflow = false;
|
|
3643
|
-
this.
|
|
3637
|
+
this.showClickClass = false;
|
|
3638
|
+
}
|
|
3639
|
+
ngOnInit() {
|
|
3640
|
+
this.showClickClass = this.expandable && this.clickable;
|
|
3644
3641
|
}
|
|
3645
3642
|
toggleExpand() {
|
|
3646
3643
|
if (this.expandable) {
|
|
@@ -3658,12 +3655,9 @@ class ClrTreetableRow {
|
|
|
3658
3655
|
this.toggleExpand();
|
|
3659
3656
|
}
|
|
3660
3657
|
}
|
|
3661
|
-
isExpandable() {
|
|
3662
|
-
return this.expandable;
|
|
3663
|
-
}
|
|
3664
3658
|
}
|
|
3665
|
-
ClrTreetableRow.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: ClrTreetableRow, deps: [
|
|
3666
|
-
ClrTreetableRow.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.1", type: ClrTreetableRow, selector: "clr-tt-row", inputs: { expanded: ["clrExpanded", "expanded"], clickable: ["clrClickable", "clickable"],
|
|
3659
|
+
ClrTreetableRow.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: ClrTreetableRow, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3660
|
+
ClrTreetableRow.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.1", type: ClrTreetableRow, selector: "clr-tt-row", inputs: { expanded: ["clrExpanded", "expanded"], clickable: ["clrClickable", "clickable"], expandable: ["clrExpandable", "expandable"] }, outputs: { hasActionOverflow: "hasActionOverflow", expandedChange: "clrExpandedChange" }, host: { properties: { "class.treetable-row-wrapper": "true" } }, queries: [{ propertyName: "actionOverflow", first: true, predicate: ClrTreetableActionOverflow, descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2018-2024 Porsche Informatik. All Rights Reserved.\n ~ This software is released under MIT license.\n ~ The full license information can be found in LICENSE in the root directory of this project.\n -->\n\n<div\n [ngClass]=\"{'clr-row-clickable': showClickClass}\"\n class=\"clr-tt-node-content treetable-row\"\n (click)=\"onRowClick($event)\"\n>\n <ng-content select=\"clr-tt-action-overflow\"></ng-content>\n <clr-tt-action-overflow *ngIf=\"showActionOverflow && showEmptyActionOverflow\" [empty]=\"true\"></clr-tt-action-overflow>\n <div class=\"treetable-scrolling-cells\">\n <div class=\"treetable-expandable-caret\" *ngIf=\"expandable\">\n <button type=\"button\" class=\"treetable-expandable-caret-button\" (click)=\"onCaretClick()\">\n <cds-icon\n shape=\"angle\"\n [attr.direction]=\"expanded ? 'down' : 'right'\"\n class=\"treetable-expandable-caret-icon\"\n ></cds-icon>\n </button>\n </div>\n\n <ng-content select=\"clr-tt-cell\"></ng-content>\n </div>\n</div>\n<div [@collapseExpandAnimation]=\"expanded\">\n <ng-content select=\"clr-tt-row\"></ng-content>\n</div>\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$1.CdsIconCustomTag, selector: "cds-icon" }, { kind: "component", type: ClrTreetableActionOverflow, selector: "clr-tt-action-overflow", inputs: ["empty"] }], animations: [
|
|
3667
3661
|
trigger('collapseExpandAnimation', [
|
|
3668
3662
|
state('false', style({ display: 'none' })),
|
|
3669
3663
|
state('true', style({ display: 'block' })),
|
|
@@ -3692,14 +3686,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
|
|
|
3692
3686
|
animate('300ms', style({ opacity: 0, height: 0 })),
|
|
3693
3687
|
]),
|
|
3694
3688
|
]),
|
|
3695
|
-
], template: "<!--\n ~ Copyright (c) 2018-
|
|
3696
|
-
}], ctorParameters: function () { return [
|
|
3689
|
+
], template: "<!--\n ~ Copyright (c) 2018-2024 Porsche Informatik. All Rights Reserved.\n ~ This software is released under MIT license.\n ~ The full license information can be found in LICENSE in the root directory of this project.\n -->\n\n<div\n [ngClass]=\"{'clr-row-clickable': showClickClass}\"\n class=\"clr-tt-node-content treetable-row\"\n (click)=\"onRowClick($event)\"\n>\n <ng-content select=\"clr-tt-action-overflow\"></ng-content>\n <clr-tt-action-overflow *ngIf=\"showActionOverflow && showEmptyActionOverflow\" [empty]=\"true\"></clr-tt-action-overflow>\n <div class=\"treetable-scrolling-cells\">\n <div class=\"treetable-expandable-caret\" *ngIf=\"expandable\">\n <button type=\"button\" class=\"treetable-expandable-caret-button\" (click)=\"onCaretClick()\">\n <cds-icon\n shape=\"angle\"\n [attr.direction]=\"expanded ? 'down' : 'right'\"\n class=\"treetable-expandable-caret-icon\"\n ></cds-icon>\n </button>\n </div>\n\n <ng-content select=\"clr-tt-cell\"></ng-content>\n </div>\n</div>\n<div [@collapseExpandAnimation]=\"expanded\">\n <ng-content select=\"clr-tt-row\"></ng-content>\n</div>\n" }]
|
|
3690
|
+
}], ctorParameters: function () { return []; }, propDecorators: { expanded: [{
|
|
3697
3691
|
type: Input,
|
|
3698
3692
|
args: ['clrExpanded']
|
|
3699
3693
|
}], clickable: [{
|
|
3700
3694
|
type: Input,
|
|
3701
3695
|
args: ['clrClickable']
|
|
3702
|
-
}],
|
|
3696
|
+
}], expandable: [{
|
|
3703
3697
|
type: Input,
|
|
3704
3698
|
args: ['clrExpandable']
|
|
3705
3699
|
}], hasActionOverflow: [{
|