verben-ng-ui 1.5.3 → 1.5.4
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/esm2022/src/lib/components/card-data-view/left-card-data/left-card-data.component.mjs +19 -6
- package/esm2022/src/lib/components/data-view/data-view.component.mjs +2 -2
- package/esm2022/src/lib/components/sort-table/sort-table.component.mjs +118 -7
- package/fesm2022/verben-ng-ui-src-lib-components-card-data-view.mjs +18 -5
- package/fesm2022/verben-ng-ui-src-lib-components-card-data-view.mjs.map +1 -1
- package/fesm2022/verben-ng-ui-src-lib-components-data-view.mjs +2 -2
- package/fesm2022/verben-ng-ui-src-lib-components-sort-table.mjs +116 -5
- package/fesm2022/verben-ng-ui-src-lib-components-sort-table.mjs.map +1 -1
- package/package.json +92 -92
- package/src/lib/components/card-data-view/left-card-data/left-card-data.component.d.ts +13 -4
- package/src/lib/components/sort-table/sort-table.component.d.ts +29 -4
package/esm2022/src/lib/components/card-data-view/left-card-data/left-card-data.component.mjs
CHANGED
|
@@ -22,13 +22,24 @@ export class LeftCardDataComponent {
|
|
|
22
22
|
dataId; //what to use to identify each data
|
|
23
23
|
/**
|
|
24
24
|
* Buttons revealed on hover / keyboard focus over each card (the #card
|
|
25
|
-
* template)
|
|
26
|
-
*
|
|
25
|
+
* template) and, unless cardChildActions says otherwise, each child card
|
|
26
|
+
* (#cardChild). When set, every card is wrapped in <verben-card-hover-actions>
|
|
27
|
+
* with its own CardData; empty or unset renders exactly as before (no wrapper).
|
|
27
28
|
* Pass a stable array (a field, not an inline literal).
|
|
28
29
|
*/
|
|
29
30
|
cardActions = [];
|
|
30
|
-
/**
|
|
31
|
+
/**
|
|
32
|
+
* Different buttons for child cards (#cardChild). Unset (undefined): the
|
|
33
|
+
* children use cardActions. [] or null: no buttons on children.
|
|
34
|
+
* canView / onSelect receive the child's CardData.
|
|
35
|
+
*/
|
|
36
|
+
cardChildActions = undefined;
|
|
37
|
+
/** Where those buttons sit on each card (and child card). */
|
|
31
38
|
cardActionsPosition = 'top-right';
|
|
39
|
+
/** The actions for child cards: cardChildActions when set, else cardActions */
|
|
40
|
+
get childActions() {
|
|
41
|
+
return this.cardChildActions === undefined ? this.cardActions : this.cardChildActions;
|
|
42
|
+
}
|
|
32
43
|
// currentItem:any={};
|
|
33
44
|
showToggle(item) {
|
|
34
45
|
// showToggle() && item.children.length>0
|
|
@@ -45,11 +56,11 @@ export class LeftCardDataComponent {
|
|
|
45
56
|
item.isChildrenExpanded = !currToggleState;
|
|
46
57
|
}
|
|
47
58
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.10", ngImport: i0, type: LeftCardDataComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
48
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.10", type: LeftCardDataComponent, selector: "verben-left-card-data", inputs: { pd: "pd", mg: "mg", height: "height", weight: "weight", activeCss: "activeCss", inActiveCss: "inActiveCss", cardDataList: "cardDataList", iconCollapse: "iconCollapse", iconExpanded: "iconExpanded", parent: "parent", useVirtualScroll: "useVirtualScroll", virtualScrollItemSize: "virtualScrollItemSize", dataId: "dataId", cardActions: "cardActions", cardActionsPosition: "cardActionsPosition" }, queries: [{ propertyName: "card", first: true, predicate: ["card"], descendants: true }, { propertyName: "cardChild", first: true, predicate: ["cardChild"], descendants: true }, { propertyName: "cardFooter", first: true, predicate: ["cardFooter"], descendants: true }], ngImport: i0, template: "@for (item of cardDataList; track $index) {\n<div class=\"flex\">\n <div class=\"flex-col full-width\">\n @if (cardActions?.length) {\n <!-- [cardActions]: the card gets the hover buttons -->\n <verben-card-hover-actions\n [item]=\"item\"\n [actions]=\"cardActions!\"\n [position]=\"cardActionsPosition\"\n >\n <ng-container\n *ngTemplateOutlet=\"card; context: { $implicit: item }\"\n ></ng-container>\n </verben-card-hover-actions>\n } @else {\n <ng-content\n *ngTemplateOutlet=\"card; context: { $implicit: item }\"\n ></ng-content>\n }\n <!-- children -->\n <ng-template #childrenList>\n @for (child of item.children; track $index) {\n <ng-container\n *ngTemplateOutlet=\"\n cardChild;\n context: { index: $index, $implicit: child }\n \"\n ></ng-container>\n }\n </ng-template>\n <div\n class=\"childrenPadding flex-col flex\"\n *ngIf=\"item.children.length > 0 && item.isChildrenExpanded\"\n >\n @if (useVirtualScroll) {\n <cdk-virtual-scroll-viewport\n [itemSize]=\"virtualScrollItemSize\"\n class=\"virtual-scroll-viewport\"\n [style.height.px]=\"virtualScrollItemSize * 50\"\n >\n <ng-container *ngTemplateOutlet=\"childrenList\"></ng-container>\n </cdk-virtual-scroll-viewport>\n } @else {\n <ng-container *ngTemplateOutlet=\"childrenList\"></ng-container>\n }\n </div>\n <div *ngIf=\"item.isChildrenExpanded\" class=\"false-padding\">\n <ng-content\n *ngTemplateOutlet=\"\n cardFooter;\n context: { index: $index, $implicit: item }\n \"\n ></ng-content>\n </div>\n </div>\n</div>\n\n}\n", styles: [":host{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,max(220px,(100% - 30px) / 3)),1fr));gap:15px;padding:15px}.pad15{padding:5px}.center-icon{align-items:center}.full-width{width:100%}.childrenPadding{box-sizing:border-box;width:100%;padding:10px 10px 10px 15%;display:flex;gap:10px}.false-padding{padding-left:15%}::ng-deep .childrenPadding .cdk-virtual-scroll-content-wrapper{display:flex;flex-direction:column;gap:10px}\n"], dependencies: [{ 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.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { kind: "component", type: i2.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { kind: "component", type: i3.CardHoverActionsComponent, selector: "verben-card-hover-actions", inputs: ["item", "actions", "position", "alwaysVisible", "disabled", "buttonClass"], outputs: ["action"] }] });
|
|
59
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.10", type: LeftCardDataComponent, selector: "verben-left-card-data", inputs: { pd: "pd", mg: "mg", height: "height", weight: "weight", activeCss: "activeCss", inActiveCss: "inActiveCss", cardDataList: "cardDataList", iconCollapse: "iconCollapse", iconExpanded: "iconExpanded", parent: "parent", useVirtualScroll: "useVirtualScroll", virtualScrollItemSize: "virtualScrollItemSize", dataId: "dataId", cardActions: "cardActions", cardChildActions: "cardChildActions", cardActionsPosition: "cardActionsPosition" }, queries: [{ propertyName: "card", first: true, predicate: ["card"], descendants: true }, { propertyName: "cardChild", first: true, predicate: ["cardChild"], descendants: true }, { propertyName: "cardFooter", first: true, predicate: ["cardFooter"], descendants: true }], ngImport: i0, template: "@for (item of cardDataList; track $index) {\n<div class=\"flex\">\n <div class=\"flex-col full-width\">\n @if (cardActions?.length) {\n <!-- [cardActions]: the card gets the hover buttons -->\n <verben-card-hover-actions\n [item]=\"item\"\n [actions]=\"cardActions!\"\n [position]=\"cardActionsPosition\"\n >\n <ng-container\n *ngTemplateOutlet=\"card; context: { $implicit: item }\"\n ></ng-container>\n </verben-card-hover-actions>\n } @else {\n <ng-content\n *ngTemplateOutlet=\"card; context: { $implicit: item }\"\n ></ng-content>\n }\n <!-- children -->\n <ng-template #childrenList>\n @for (child of item.children; track $index) {\n @if (childActions?.length) {\n <!-- child cards get the hover buttons too (cardChildActions, else cardActions) -->\n <verben-card-hover-actions\n [item]=\"child\"\n [actions]=\"childActions!\"\n [position]=\"cardActionsPosition\"\n >\n <ng-container\n *ngTemplateOutlet=\"\n cardChild;\n context: { index: $index, $implicit: child }\n \"\n ></ng-container>\n </verben-card-hover-actions>\n } @else {\n <ng-container\n *ngTemplateOutlet=\"\n cardChild;\n context: { index: $index, $implicit: child }\n \"\n ></ng-container>\n }\n }\n </ng-template>\n <div\n class=\"childrenPadding flex-col flex\"\n *ngIf=\"item.children.length > 0 && item.isChildrenExpanded\"\n >\n @if (useVirtualScroll) {\n <cdk-virtual-scroll-viewport\n [itemSize]=\"virtualScrollItemSize\"\n class=\"virtual-scroll-viewport\"\n [style.height.px]=\"virtualScrollItemSize * 50\"\n >\n <ng-container *ngTemplateOutlet=\"childrenList\"></ng-container>\n </cdk-virtual-scroll-viewport>\n } @else {\n <ng-container *ngTemplateOutlet=\"childrenList\"></ng-container>\n }\n </div>\n <div *ngIf=\"item.isChildrenExpanded\" class=\"false-padding\">\n <ng-content\n *ngTemplateOutlet=\"\n cardFooter;\n context: { index: $index, $implicit: item }\n \"\n ></ng-content>\n </div>\n </div>\n</div>\n\n}\n", styles: [":host{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,max(220px,(100% - 30px) / 3)),1fr));gap:15px;padding:15px}.pad15{padding:5px}.center-icon{align-items:center}.full-width{width:100%}.childrenPadding{box-sizing:border-box;width:100%;padding:10px 10px 10px 15%;display:flex;gap:10px}.false-padding{padding-left:15%}::ng-deep .childrenPadding .cdk-virtual-scroll-content-wrapper{display:flex;flex-direction:column;gap:10px}\n"], dependencies: [{ 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.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { kind: "component", type: i2.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { kind: "component", type: i3.CardHoverActionsComponent, selector: "verben-card-hover-actions", inputs: ["item", "actions", "position", "alwaysVisible", "disabled", "buttonClass"], outputs: ["action"] }] });
|
|
49
60
|
}
|
|
50
61
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.10", ngImport: i0, type: LeftCardDataComponent, decorators: [{
|
|
51
62
|
type: Component,
|
|
52
|
-
args: [{ selector: 'verben-left-card-data', template: "@for (item of cardDataList; track $index) {\n<div class=\"flex\">\n <div class=\"flex-col full-width\">\n @if (cardActions?.length) {\n <!-- [cardActions]: the card gets the hover buttons -->\n <verben-card-hover-actions\n [item]=\"item\"\n [actions]=\"cardActions!\"\n [position]=\"cardActionsPosition\"\n >\n <ng-container\n *ngTemplateOutlet=\"card; context: { $implicit: item }\"\n ></ng-container>\n </verben-card-hover-actions>\n } @else {\n <ng-content\n *ngTemplateOutlet=\"card; context: { $implicit: item }\"\n ></ng-content>\n }\n <!-- children -->\n <ng-template #childrenList>\n @for (child of item.children; track $index) {\n <ng-container\n *ngTemplateOutlet=\"\n cardChild;\n context: { index: $index, $implicit: child }\n \"\n ></ng-container>\n }\n </ng-template>\n <div\n class=\"childrenPadding flex-col flex\"\n *ngIf=\"item.children.length > 0 && item.isChildrenExpanded\"\n >\n @if (useVirtualScroll) {\n <cdk-virtual-scroll-viewport\n [itemSize]=\"virtualScrollItemSize\"\n class=\"virtual-scroll-viewport\"\n [style.height.px]=\"virtualScrollItemSize * 50\"\n >\n <ng-container *ngTemplateOutlet=\"childrenList\"></ng-container>\n </cdk-virtual-scroll-viewport>\n } @else {\n <ng-container *ngTemplateOutlet=\"childrenList\"></ng-container>\n }\n </div>\n <div *ngIf=\"item.isChildrenExpanded\" class=\"false-padding\">\n <ng-content\n *ngTemplateOutlet=\"\n cardFooter;\n context: { index: $index, $implicit: item }\n \"\n ></ng-content>\n </div>\n </div>\n</div>\n\n}\n", styles: [":host{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,max(220px,(100% - 30px) / 3)),1fr));gap:15px;padding:15px}.pad15{padding:5px}.center-icon{align-items:center}.full-width{width:100%}.childrenPadding{box-sizing:border-box;width:100%;padding:10px 10px 10px 15%;display:flex;gap:10px}.false-padding{padding-left:15%}::ng-deep .childrenPadding .cdk-virtual-scroll-content-wrapper{display:flex;flex-direction:column;gap:10px}\n"] }]
|
|
63
|
+
args: [{ selector: 'verben-left-card-data', template: "@for (item of cardDataList; track $index) {\n<div class=\"flex\">\n <div class=\"flex-col full-width\">\n @if (cardActions?.length) {\n <!-- [cardActions]: the card gets the hover buttons -->\n <verben-card-hover-actions\n [item]=\"item\"\n [actions]=\"cardActions!\"\n [position]=\"cardActionsPosition\"\n >\n <ng-container\n *ngTemplateOutlet=\"card; context: { $implicit: item }\"\n ></ng-container>\n </verben-card-hover-actions>\n } @else {\n <ng-content\n *ngTemplateOutlet=\"card; context: { $implicit: item }\"\n ></ng-content>\n }\n <!-- children -->\n <ng-template #childrenList>\n @for (child of item.children; track $index) {\n @if (childActions?.length) {\n <!-- child cards get the hover buttons too (cardChildActions, else cardActions) -->\n <verben-card-hover-actions\n [item]=\"child\"\n [actions]=\"childActions!\"\n [position]=\"cardActionsPosition\"\n >\n <ng-container\n *ngTemplateOutlet=\"\n cardChild;\n context: { index: $index, $implicit: child }\n \"\n ></ng-container>\n </verben-card-hover-actions>\n } @else {\n <ng-container\n *ngTemplateOutlet=\"\n cardChild;\n context: { index: $index, $implicit: child }\n \"\n ></ng-container>\n }\n }\n </ng-template>\n <div\n class=\"childrenPadding flex-col flex\"\n *ngIf=\"item.children.length > 0 && item.isChildrenExpanded\"\n >\n @if (useVirtualScroll) {\n <cdk-virtual-scroll-viewport\n [itemSize]=\"virtualScrollItemSize\"\n class=\"virtual-scroll-viewport\"\n [style.height.px]=\"virtualScrollItemSize * 50\"\n >\n <ng-container *ngTemplateOutlet=\"childrenList\"></ng-container>\n </cdk-virtual-scroll-viewport>\n } @else {\n <ng-container *ngTemplateOutlet=\"childrenList\"></ng-container>\n }\n </div>\n <div *ngIf=\"item.isChildrenExpanded\" class=\"false-padding\">\n <ng-content\n *ngTemplateOutlet=\"\n cardFooter;\n context: { index: $index, $implicit: item }\n \"\n ></ng-content>\n </div>\n </div>\n</div>\n\n}\n", styles: [":host{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,max(220px,(100% - 30px) / 3)),1fr));gap:15px;padding:15px}.pad15{padding:5px}.center-icon{align-items:center}.full-width{width:100%}.childrenPadding{box-sizing:border-box;width:100%;padding:10px 10px 10px 15%;display:flex;gap:10px}.false-padding{padding-left:15%}::ng-deep .childrenPadding .cdk-virtual-scroll-content-wrapper{display:flex;flex-direction:column;gap:10px}\n"] }]
|
|
53
64
|
}], propDecorators: { pd: [{
|
|
54
65
|
type: Input
|
|
55
66
|
}], mg: [{
|
|
@@ -87,7 +98,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.10", ngImpo
|
|
|
87
98
|
type: Input
|
|
88
99
|
}], cardActions: [{
|
|
89
100
|
type: Input
|
|
101
|
+
}], cardChildActions: [{
|
|
102
|
+
type: Input
|
|
90
103
|
}], cardActionsPosition: [{
|
|
91
104
|
type: Input
|
|
92
105
|
}] } });
|
|
93
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
106
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGVmdC1jYXJkLWRhdGEuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvdmVyYmVuLW5nLXVpL3NyYy9saWIvY29tcG9uZW50cy9jYXJkLWRhdGEtdmlldy9sZWZ0LWNhcmQtZGF0YS9sZWZ0LWNhcmQtZGF0YS5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy92ZXJiZW4tbmctdWkvc3JjL2xpYi9jb21wb25lbnRzL2NhcmQtZGF0YS12aWV3L2xlZnQtY2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widmlydHVhbFNjcm9sbEl0ZW1TaXplXCJcbiAgICAgICAgY2xhc3M9XCJ2aXJ0dWFsLXNjcm9sbC12aWV3cG9ydFwiXG4gICAgICAgIFtzdHlsZS5oZWlnaHQucHhdPVwidmlydHVhbFNjcm9sbEl0ZW1TaXplICogNTBcIlxuICAgICAgPlxuICAgICAgICA8bmctY29udGFpbmVyICpuZ1RlbXBsYXRlT3V0bGV0PVwiY2hpbGRyZW5MaXN0XCI+PC9uZy1jb250YWluZXI+XG4gICAgICA8L2Nkay12aXJ0dWFsLXNjcm9sbC12aWV3cG9ydD5cbiAgICAgIH0gQGVsc2Uge1xuICAgICAgPG5nLWNvbnRhaW5lciAqbmdUZW1wbGF0ZU91dGxldD1cImNoaWxkcmVuTGlzdFwiPjwvbmctY29udGFpbmVyPlxuICAgICAgfVxuICAgIDwvZGl2PlxuICAgIDxkaXYgKm5nSWY9XCJpdGVtLmlzQ2hpbGRyZW5FeHBhbmRlZFwiIGNsYXNzPVwiZmFsc2UtcGFkZGluZ1wiPlxuICAgICAgPG5nLWNvbnRlbnRcbiAgICAgICAgKm5nVGVtcGxhdGVPdXRsZXQ9XCJcbiAgICAgICAgICBjYXJkRm9vdGVyO1xuICAgICAgICAgIGNvbnRleHQ6IHsgaW5kZXg6ICRpbmRleCwgJGltcGxpY2l0OiBpdGVtIH1cbiAgICAgICAgXCJcbiAgICAgID48L25nLWNvbnRlbnQ+XG4gICAgPC9kaXY+XG4gIDwvZGl2PlxuPC9kaXY+XG5cbn1cbiJdfQ==
|
|
@@ -177,11 +177,11 @@ export class DataViewComponent {
|
|
|
177
177
|
this.searchValue = val;
|
|
178
178
|
}
|
|
179
179
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.10", ngImport: i0, type: DataViewComponent, deps: [{ token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component });
|
|
180
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.10", type: DataViewComponent, selector: "verben-data-view", inputs: { buttonClass: "buttonClass", iconClass: "iconClass", activeIconClass: "activeIconClass", columnCustomClass: "columnCustomClass", filterCustomClass: "filterCustomClass", sortCustomClass: "sortCustomClass", extendCustomClass: "extendCustomClass", exportCustomClass: "exportCustomClass", selectCustomClass: "selectCustomClass", importCustomClass: "importCustomClass", zIndex: "zIndex", createCustomClass: "createCustomClass", tableIcon: "tableIcon", cardIcon: "cardIcon", cardClass: "cardClass", tableClass: "tableClass", searchKey: "searchKey", searchValue: "searchValue", viewState: "viewState", searchTemplate: "searchTemplate", importTemplate: "importTemplate", columnTemplate: "columnTemplate", extendTemplate: "extendTemplate", filterTemplate: "filterTemplate", sortTemplate: "sortTemplate", children: "children", exportTemplate: "exportTemplate", createTemplate: "createTemplate", selectedColumnCount: "selectedColumnCount", selectedSortCount: "selectedSortCount", selectedFilterTableCount: "selectedFilterTableCount", inputWidth: "inputWidth", milliseconds: "milliseconds", showColumnChild: "showColumnChild", showSortChild: "showSortChild", showFilterChild: "showFilterChild", showImportChild: "showImportChild", showExportChild: "showExportChild", showExtendChild: "showExtendChild", create: "create", showSelected: "showSelected", useTwoWayBinding: "useTwoWayBinding", isTableView: "isTableView" }, outputs: { viewChange: "viewChange", stateChange: "stateChange", onSearchChange: "onSearchChange" }, viewQueries: [{ propertyName: "filterContentWrapper", first: true, predicate: ["filterContentWrapper"], descendants: true }], ngImport: i0, template: "<div class=\"toolbar\">\n <div class=\"dv-search-group\">\n <div *ngIf=\"viewState.isToggle\" class=\"toggle-button-container\">\n <button type=\"button\" (click)=\"toggleView()\" [ngClass]=\"buttonClass\">\n <verben-svg\n [icon]=\"tableIcon\"\n [class.active]=\"!isTableView\"\n [ngClass]=\"!isTableView ? activeIconClass : iconClass\"\n ></verben-svg>\n <verben-svg\n [icon]=\"cardIcon\"\n [class.active]=\"isTableView\"\n [ngClass]=\"isTableView ? activeIconClass : iconClass\"\n [width]=\"25\"\n [height]=\"25\"\n ></verben-svg>\n </button>\n </div>\n <!-- Search Input -->\n <div\n [style.width]=\"inputWidth\"\n class=\"search-input\"\n *ngIf=\"viewState.isSearch\"\n >\n <verben-svg [icon]=\"'search2'\" [width]=\"20\" [height]=\"20\"></verben-svg>\n <input\n *ngIf=\"!useTwoWayBinding\"\n [type]=\"'text'\"\n [placeholder]=\"'Search'\"\n (input)=\"onSearch($event)\"\n [style.border]=\"'0'\"\n [value]=\"searchValue\"\n />\n <input\n *ngIf=\"useTwoWayBinding\"\n [type]=\"'text'\"\n [placeholder]=\"'Search'\"\n (input)=\"onSearch($event)\"\n [style.border]=\"'0'\"\n [(ngModel)]=\"searchValue\"\n />\n <verben-svg\n *ngIf=\"searchValue.length > 0\"\n [icon]=\"'close'\"\n [width]=\"15\"\n (click)=\"onClearSearch()\"\n class=\"close-icon-class\"\n [height]=\"15\"\n ></verben-svg>\n </div>\n </div>\n <div class=\"relative dv-actions\">\n <!-- Column Section -->\n <ng-container\n [appOutSideClick]=\"showColumnChild\"\n (outSideClick)=\"resetChildViewsExcept('column')\"\n *ngIf=\"viewState.isColumn && isTableView\"\n >\n <ng-container *ngIf=\"columnTemplate; else defaultColumn\"></ng-container>\n <ng-template #defaultColumn>\n <span\n [ngClass]=\"['dv-action', columnCustomClass ? columnCustomClass : '']\"\n [class.is-open]=\"showColumnChild\"\n (click)=\"toggleChildView('column')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'column'\"></verben-svg>\n <span>Columns</span\n ><span class=\"dv-count\">{{ selectedColumnCount }}</span>\n </span>\n <div\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n [style.display]=\"showColumnChild ? 'block' : 'none'\"\n >\n <!-- Kept in the DOM (hidden via display) rather than *ngIf so the\n projected panel stays change-detected and reflects host state\n updates (e.g. restored column arrangement) even while collapsed. -->\n <ng-content select=\"[column-content]\"></ng-content>\n </div>\n </ng-template>\n </ng-container>\n\n <!-- Filter Section -->\n <ng-container\n [appOutSideClick]=\"showFilterChild\"\n (outSideClick)=\"resetChildViewsExcept('filter')\"\n *ngIf=\"viewState.isFilter\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"filterTemplate; else defaultFilter\"></ng-container>\n <ng-template #defaultFilter>\n <span\n [ngClass]=\"['dv-action', filterCustomClass ? filterCustomClass : '']\"\n [class.is-open]=\"showFilterChild\"\n (click)=\"toggleChildView('filter')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'filter'\"></verben-svg>\n <span>Filter</span\n ><span class=\"dv-count\">{{ selectedFilterTableCount }}</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n [style.display]=\"showFilterChild ? 'block' : 'none'\"\n >\n <!-- Kept in the DOM (hidden via display) rather than *ngIf so the\n projected panel stays change-detected and reflects host state\n updates (e.g. restored filters) even while collapsed. -->\n <ng-content select=\"[filter-content]\"></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!--import Section-->\n <ng-container\n [appOutSideClick]=\"showImportChild\"\n (outSideClick)=\"resetChildViewsExcept('import')\"\n *ngIf=\"viewState.isImport\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"importTemplate; else defaultImport\"></ng-container>\n <ng-template #defaultImport>\n <span\n [ngClass]=\"['dv-action', importCustomClass ? importCustomClass : '']\"\n [class.is-open]=\"showImportChild\"\n (click)=\"toggleChildView('import')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'file'\"></verben-svg>\n <span>Import</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n >\n <ng-content\n *ngIf=\"showImportChild\"\n select=\"[import-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!-- Sort Section -->\n <ng-container\n [appOutSideClick]=\"showSortChild\"\n (outSideClick)=\"resetChildViewsExcept('sort')\"\n *ngIf=\"viewState.isSort\"\n >\n <ng-container *ngIf=\"sortTemplate; else defaultSort\"></ng-container>\n <ng-template #defaultSort>\n <span\n [ngClass]=\"['dv-action', sortCustomClass ? sortCustomClass : '']\"\n [class.is-open]=\"showSortChild\"\n (click)=\"toggleChildView('sort')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'sort'\"></verben-svg>\n <span>Sort</span><span class=\"dv-count\">{{ selectedSortCount }}</span>\n </span>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content\n *ngIf=\"showSortChild\"\n select=\"[sort-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!--Extend Section-->\n <ng-container\n [appOutSideClick]=\"showExtendChild\"\n (outSideClick)=\"resetChildViewsExcept('extend')\"\n *ngIf=\"viewState.isExtend\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"extendTemplate; else defaultExtend\"></ng-container>\n <ng-template #defaultExtend>\n <span\n [ngClass]=\"['dv-action', importCustomClass ? extendCustomClass : '']\"\n [class.is-open]=\"showExtendChild\"\n (click)=\"toggleChildView('extend')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'extend'\"></verben-svg>\n <span>Extend</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n >\n <ng-content\n *ngIf=\"showImportChild\"\n select=\"[extend-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!-- Export Section -->\n <ng-container\n [appOutSideClick]=\"showExportChild\"\n (outSideClick)=\"resetChildViewsExcept('export')\"\n *ngIf=\"viewState.isExport\"\n >\n <ng-container *ngIf=\"exportTemplate; else defaultExport\"></ng-container>\n <ng-template #defaultExport>\n <span\n [ngClass]=\"['dv-action', exportCustomClass ? exportCustomClass : '']\"\n [class.is-open]=\"showExportChild\"\n (click)=\"toggleChildView('export')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'export'\"></verben-svg>\n Export\n </span>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content\n *ngIf=\"showExportChild\"\n select=\"[export-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n\n <!-- Select Section -->\n <!-- <div *ngIf=\"viewState.isSelect\">\n <span\n [ngClass]=\"[\n 'flex gap text-xs items-center pd rounded cursor-pointer',\n selectCustomClass ? selectCustomClass : ''\n ]\"\n [style.background-color]=\"'var(--vbn-color-surface-alt)'\"\n (click)=\"toggleChildView('select')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'select'\"></verben-svg>\n <span>Select</span>\n <verben-svg [width]=\"6\" [icon]=\"'chevron-down'\"></verben-svg>\n </span>\n </div> -->\n\n <!-- Create Button jj-->\n\n <div\n [appOutSideClick]=\"create\"\n (outSideClick)=\"resetChildViewsExcept('create')\"\n *ngIf=\"viewState.isCreate\"\n >\n <verbena-button\n [bgColor]=\"'var(--vbn-color-primary)'\"\n [buttonClass]=\"createCustomClass\"\n [textColor]=\"'var(--vbn-color-on-primary)'\"\n [svg]=\"'add'\"\n [svgPosition]=\"'right'\"\n [text]=\"'Create New'\"\n (click)=\"toggleChildView('create')\"\n >\n </verbena-button>\n <ng-container *ngIf=\"createTemplate; else defaultCreate\"></ng-container>\n <ng-template #defaultCreate>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content *ngIf=\"create\" select=\"[create-content]\"></ng-content>\n </div>\n </ng-template>\n </div>\n </div>\n\n <div *ngIf=\"children\">\n <ng-container *ngIf=\"children; else defaultChildren\"></ng-container>\n <ng-template #defaultChildren>\n <div>\n <ng-content select=\"[children]\"></ng-content>\n </div>\n </ng-template>\n </div>\n</div>\n\n<!-- Grid and List View Handling -->\n<div *ngIf=\"isTableView; else listViewTemplate\">\n <div [style.overflow]=\"'auto'\" [class]=\"tableClass\">\n <ng-content select=\"[table-content]\"></ng-content>\n </div>\n</div>\n<ng-template #listViewTemplate>\n <div [class]=\"cardClass\">\n <ng-content select=\"[card-content]\"></ng-content>\n </div>\n</ng-template>\n", styles: [".toggle-button-container button{display:inline-flex;align-items:center;gap:2px;height:36px;padding:3px;box-sizing:border-box;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text-muted);cursor:pointer}.toggle-button-container button:focus-visible{outline:2px solid var(--vbn-color-border-focus);outline-offset:1px}.input-class{border:none;min-width:100%;display:block}.toggle-button-container verben-svg{display:inline-grid;place-items:center;width:28px;height:28px;box-sizing:border-box;padding:4px;border-radius:6px;transition:background-color .15s ease}.toggle-button-container verben-svg.active{background-color:var(--vbn-color-surface-alt);box-shadow:0 1px 2px #0000001a}.justify-end{justify-self:end}.flex{display:flex}.flex-1{flex:1}.justify-between{justify-content:space-between}.items-center{align-items:center}.font-semibold{font-weight:600}.font-normal{font-weight:400}.text-sm{font-size:14px}.text-xs{font-size:12px}.gap{gap:7px}.pd{padding:5px 8px}.rounded-sm{border-radius:10px}.cursor-pointer{cursor:pointer}.search-input{position:relative;display:flex;align-items:center;gap:8px;flex:0 1 auto;min-width:85px;max-width:100%;height:36px;box-sizing:border-box;padding:0 32px 0 10px;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text-muted);transition:border-color .15s ease,box-shadow .15s ease}.search-input:focus-within{border-color:var(--vbn-color-border-focus);box-shadow:0 0 0 3px color-mix(in srgb,var(--vbn-color-border-focus) 18%,transparent)}.search-input input{display:block;width:100%;min-width:0;padding:0;outline:0;background-color:transparent;color:var(--vbn-color-text);font:inherit;font-size:14px}.search-input input::placeholder{color:var(--vbn-color-text-muted);font-size:14px}sup{color:var(--vbn-color-border-focus);font-weight:500}.data-view-element{position:absolute;top:calc(100% + 6px);right:0;max-width:100%;text-align:left}.relative{position:relative}.z-10{z-index:100000000000}.close-icon-class{position:absolute;top:50%;right:8px;display:inline-grid;place-items:center;width:20px;height:20px;border-radius:999px;transform:translateY(-50%);cursor:pointer}.close-icon-class:hover{background-color:var(--vbn-color-surface-alt)}.toolbar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px;margin-bottom:15px}.dv-search-group{display:flex;align-items:center;gap:8px;flex:1 1 150px;min-width:0}.dv-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:6px}.dv-action{display:inline-flex;align-items:center;gap:6px;padding:5px 8px;box-sizing:border-box;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text);font-size:12.5px;font-weight:500;white-space:nowrap;cursor:pointer;-webkit-user-select:none;user-select:none;transition:background-color .15s ease,border-color .15s ease}.dv-action:hover{background-color:var(--vbn-color-surface-alt)}.dv-action.is-open{border-color:var(--vbn-color-text-muted);background-color:var(--vbn-color-surface-alt)}.dv-count{display:inline-grid;place-items:center;min-width:18px;height:18px;padding:0 5px;box-sizing:border-box;border-radius:999px;background-color:var(--vbn-color-surface-alt);box-shadow:inset 0 0 0 1px var(--vbn-color-border);color:var(--vbn-color-text-muted);font-size:11px;font-weight:600}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2.SvgComponent, selector: "verben-svg", inputs: ["icon", "width", "height", "fill", "stroke", "type", "size"] }, { kind: "component", type: i3.VerbenaButtonComponent, selector: "verbena-button", inputs: ["type", "text", "styleType", "size", "block", "disable", "disabled", "isLoading", "spinnerSize", "spinnerColor", "svg", "svgPosition", "svgWidth", "svgHeight", "svgSize", "svgColor", "icon", "useIcon", "iconPosition", "iconColor", "variant", "weight", "bgColor", "textColor", "border", "borderRadius", "pd", "width", "height", "fontSize", "fontWeight", "buttonClass", "buttonTextClass"] }, { kind: "directive", type: i4.OutSideClickDirective, selector: "[appOutSideClick]", inputs: ["appOutSideClick"], outputs: ["outSideClick"] }, { kind: "directive", type: i5.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: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
180
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.10", type: DataViewComponent, selector: "verben-data-view", inputs: { buttonClass: "buttonClass", iconClass: "iconClass", activeIconClass: "activeIconClass", columnCustomClass: "columnCustomClass", filterCustomClass: "filterCustomClass", sortCustomClass: "sortCustomClass", extendCustomClass: "extendCustomClass", exportCustomClass: "exportCustomClass", selectCustomClass: "selectCustomClass", importCustomClass: "importCustomClass", zIndex: "zIndex", createCustomClass: "createCustomClass", tableIcon: "tableIcon", cardIcon: "cardIcon", cardClass: "cardClass", tableClass: "tableClass", searchKey: "searchKey", searchValue: "searchValue", viewState: "viewState", searchTemplate: "searchTemplate", importTemplate: "importTemplate", columnTemplate: "columnTemplate", extendTemplate: "extendTemplate", filterTemplate: "filterTemplate", sortTemplate: "sortTemplate", children: "children", exportTemplate: "exportTemplate", createTemplate: "createTemplate", selectedColumnCount: "selectedColumnCount", selectedSortCount: "selectedSortCount", selectedFilterTableCount: "selectedFilterTableCount", inputWidth: "inputWidth", milliseconds: "milliseconds", showColumnChild: "showColumnChild", showSortChild: "showSortChild", showFilterChild: "showFilterChild", showImportChild: "showImportChild", showExportChild: "showExportChild", showExtendChild: "showExtendChild", create: "create", showSelected: "showSelected", useTwoWayBinding: "useTwoWayBinding", isTableView: "isTableView" }, outputs: { viewChange: "viewChange", stateChange: "stateChange", onSearchChange: "onSearchChange" }, viewQueries: [{ propertyName: "filterContentWrapper", first: true, predicate: ["filterContentWrapper"], descendants: true }], ngImport: i0, template: "<div class=\"toolbar\">\n <div class=\"dv-search-group\">\n <div *ngIf=\"viewState.isToggle\" class=\"toggle-button-container\">\n <button type=\"button\" (click)=\"toggleView()\" [ngClass]=\"buttonClass\">\n <verben-svg\n [icon]=\"tableIcon\"\n [class.active]=\"!isTableView\"\n [ngClass]=\"!isTableView ? activeIconClass : iconClass\"\n ></verben-svg>\n <verben-svg\n [icon]=\"cardIcon\"\n [class.active]=\"isTableView\"\n [ngClass]=\"isTableView ? activeIconClass : iconClass\"\n [width]=\"25\"\n [height]=\"25\"\n ></verben-svg>\n </button>\n </div>\n <!-- Search Input -->\n <div\n [style.width]=\"inputWidth\"\n class=\"search-input\"\n *ngIf=\"viewState.isSearch\"\n >\n <verben-svg [icon]=\"'search2'\" [width]=\"20\" [height]=\"20\"></verben-svg>\n <input\n *ngIf=\"!useTwoWayBinding\"\n [type]=\"'text'\"\n [placeholder]=\"'Search'\"\n (input)=\"onSearch($event)\"\n [style.border]=\"'0'\"\n [value]=\"searchValue\"\n />\n <input\n *ngIf=\"useTwoWayBinding\"\n [type]=\"'text'\"\n [placeholder]=\"'Search'\"\n (input)=\"onSearch($event)\"\n [style.border]=\"'0'\"\n [(ngModel)]=\"searchValue\"\n />\n <verben-svg\n *ngIf=\"searchValue.length > 0\"\n [icon]=\"'close'\"\n [width]=\"15\"\n (click)=\"onClearSearch()\"\n class=\"close-icon-class\"\n [height]=\"15\"\n ></verben-svg>\n </div>\n </div>\n <div class=\"relative dv-actions\">\n <!-- Column Section -->\n <ng-container\n [appOutSideClick]=\"showColumnChild\"\n (outSideClick)=\"resetChildViewsExcept('column')\"\n *ngIf=\"viewState.isColumn && isTableView\"\n >\n <ng-container *ngIf=\"columnTemplate; else defaultColumn\"></ng-container>\n <ng-template #defaultColumn>\n <span\n [ngClass]=\"['dv-action', columnCustomClass ? columnCustomClass : '']\"\n [class.is-open]=\"showColumnChild\"\n (click)=\"toggleChildView('column')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'column'\"></verben-svg>\n <span>Columns</span\n ><span class=\"dv-count\">{{ selectedColumnCount }}</span>\n </span>\n <div\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n [style.display]=\"showColumnChild ? 'block' : 'none'\"\n >\n <!-- Kept in the DOM (hidden via display) rather than *ngIf so the\n projected panel stays change-detected and reflects host state\n updates (e.g. restored column arrangement) even while collapsed. -->\n <ng-content select=\"[column-content]\"></ng-content>\n </div>\n </ng-template>\n </ng-container>\n\n <!-- Filter Section -->\n <ng-container\n [appOutSideClick]=\"showFilterChild\"\n (outSideClick)=\"resetChildViewsExcept('filter')\"\n *ngIf=\"viewState.isFilter\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"filterTemplate; else defaultFilter\"></ng-container>\n <ng-template #defaultFilter>\n <span\n [ngClass]=\"['dv-action', filterCustomClass ? filterCustomClass : '']\"\n [class.is-open]=\"showFilterChild\"\n (click)=\"toggleChildView('filter')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'filter'\"></verben-svg>\n <span>Filter</span\n ><span class=\"dv-count\">{{ selectedFilterTableCount }}</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n [style.display]=\"showFilterChild ? 'block' : 'none'\"\n >\n <!-- Kept in the DOM (hidden via display) rather than *ngIf so the\n projected panel stays change-detected and reflects host state\n updates (e.g. restored filters) even while collapsed. -->\n <ng-content select=\"[filter-content]\"></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!--import Section-->\n <ng-container\n [appOutSideClick]=\"showImportChild\"\n (outSideClick)=\"resetChildViewsExcept('import')\"\n *ngIf=\"viewState.isImport\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"importTemplate; else defaultImport\"></ng-container>\n <ng-template #defaultImport>\n <span\n [ngClass]=\"['dv-action', importCustomClass ? importCustomClass : '']\"\n [class.is-open]=\"showImportChild\"\n (click)=\"toggleChildView('import')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'file'\"></verben-svg>\n <span>Import</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n >\n <ng-content\n *ngIf=\"showImportChild\"\n select=\"[import-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!-- Sort Section -->\n <ng-container\n [appOutSideClick]=\"showSortChild\"\n (outSideClick)=\"resetChildViewsExcept('sort')\"\n *ngIf=\"viewState.isSort\"\n >\n <ng-container *ngIf=\"sortTemplate; else defaultSort\"></ng-container>\n <ng-template #defaultSort>\n <span\n [ngClass]=\"['dv-action', sortCustomClass ? sortCustomClass : '']\"\n [class.is-open]=\"showSortChild\"\n (click)=\"toggleChildView('sort')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'sort'\"></verben-svg>\n <span>Sort</span><span class=\"dv-count\">{{ selectedSortCount }}</span>\n </span>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content\n *ngIf=\"showSortChild\"\n select=\"[sort-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!--Extend Section-->\n <ng-container\n [appOutSideClick]=\"showExtendChild\"\n (outSideClick)=\"resetChildViewsExcept('extend')\"\n *ngIf=\"viewState.isExtend\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"extendTemplate; else defaultExtend\"></ng-container>\n <ng-template #defaultExtend>\n <span\n [ngClass]=\"['dv-action', importCustomClass ? extendCustomClass : '']\"\n [class.is-open]=\"showExtendChild\"\n (click)=\"toggleChildView('extend')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'extend'\"></verben-svg>\n <span>Extend</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n >\n <ng-content\n *ngIf=\"showImportChild\"\n select=\"[extend-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!-- Export Section -->\n <ng-container\n [appOutSideClick]=\"showExportChild\"\n (outSideClick)=\"resetChildViewsExcept('export')\"\n *ngIf=\"viewState.isExport\"\n >\n <ng-container *ngIf=\"exportTemplate; else defaultExport\"></ng-container>\n <ng-template #defaultExport>\n <span\n [ngClass]=\"['dv-action', exportCustomClass ? exportCustomClass : '']\"\n [class.is-open]=\"showExportChild\"\n (click)=\"toggleChildView('export')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'export'\"></verben-svg>\n Export\n </span>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content\n *ngIf=\"showExportChild\"\n select=\"[export-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n\n <!-- Select Section -->\n <!-- <div *ngIf=\"viewState.isSelect\">\n <span\n [ngClass]=\"[\n 'flex gap text-xs items-center pd rounded cursor-pointer',\n selectCustomClass ? selectCustomClass : ''\n ]\"\n [style.background-color]=\"'var(--vbn-color-surface-alt)'\"\n (click)=\"toggleChildView('select')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'select'\"></verben-svg>\n <span>Select</span>\n <verben-svg [width]=\"6\" [icon]=\"'chevron-down'\"></verben-svg>\n </span>\n </div> -->\n\n <!-- Create Button jj-->\n\n <div\n [appOutSideClick]=\"create\"\n (outSideClick)=\"resetChildViewsExcept('create')\"\n *ngIf=\"viewState.isCreate\"\n >\n <verbena-button\n [bgColor]=\"'var(--vbn-color-primary)'\"\n [buttonClass]=\"createCustomClass\"\n [textColor]=\"'var(--vbn-color-on-primary)'\"\n [svg]=\"'add'\"\n [svgPosition]=\"'right'\"\n [text]=\"'Create New'\"\n (click)=\"toggleChildView('create')\"\n >\n </verbena-button>\n <ng-container *ngIf=\"createTemplate; else defaultCreate\"></ng-container>\n <ng-template #defaultCreate>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content *ngIf=\"create\" select=\"[create-content]\"></ng-content>\n </div>\n </ng-template>\n </div>\n </div>\n\n <div *ngIf=\"children\">\n <ng-container *ngIf=\"children; else defaultChildren\"></ng-container>\n <ng-template #defaultChildren>\n <div>\n <ng-content select=\"[children]\"></ng-content>\n </div>\n </ng-template>\n </div>\n</div>\n\n<!-- Grid and List View Handling -->\n<div *ngIf=\"isTableView; else listViewTemplate\">\n <div [style.overflow]=\"'auto'\" [class]=\"tableClass\">\n <ng-content select=\"[table-content]\"></ng-content>\n </div>\n</div>\n<ng-template #listViewTemplate>\n <div [class]=\"cardClass\">\n <ng-content select=\"[card-content]\"></ng-content>\n </div>\n</ng-template>\n", styles: [".toggle-button-container button{display:inline-flex;align-items:center;gap:2px;height:36px;padding:3px;box-sizing:border-box;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text-muted);cursor:pointer}.toggle-button-container button:focus-visible{outline:2px solid var(--vbn-color-border-focus);outline-offset:1px}.input-class{border:none;min-width:100%;display:block}.toggle-button-container verben-svg{display:inline-grid;place-items:center;width:28px;height:28px;box-sizing:border-box;padding:4px;border-radius:6px;transition:background-color .15s ease}.toggle-button-container verben-svg.active{background-color:var(--vbn-color-surface-alt);box-shadow:0 1px 2px #0000001a}.justify-end{justify-self:end}.flex{display:flex}.flex-1{flex:1}.justify-between{justify-content:space-between}.items-center{align-items:center}.font-semibold{font-weight:600}.font-normal{font-weight:400}.text-sm{font-size:14px}.text-xs{font-size:12px}.gap{gap:7px}.pd{padding:5px 8px}.rounded-sm{border-radius:10px}.cursor-pointer{cursor:pointer}.search-input{position:relative;display:flex;align-items:center;gap:8px;flex:0 1 auto;min-width:85px;max-width:100%;height:36px;box-sizing:border-box;padding:0 32px 0 10px;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text-muted);transition:border-color .15s ease,box-shadow .15s ease}.search-input:focus-within{border-color:var(--vbn-color-border-focus);box-shadow:0 0 0 3px color-mix(in srgb,var(--vbn-color-border-focus) 18%,transparent)}.search-input input{display:block;width:100%;min-width:0;padding:0;outline:0;background-color:transparent;color:var(--vbn-color-text);font:inherit;font-size:14px}.search-input input::placeholder{color:var(--vbn-color-text-muted);font-size:14px}sup{color:var(--vbn-color-border-focus);font-weight:500}.data-view-element{position:absolute;top:calc(100% + 6px);right:0;max-width:100%;text-align:left}.relative{position:relative}.z-10{z-index:100000000000}.close-icon-class{position:absolute;top:50%;right:8px;display:inline-grid;place-items:center;width:20px;height:20px;border-radius:999px;transform:translateY(-50%);cursor:pointer}.close-icon-class:hover{background-color:var(--vbn-color-surface-alt)}.toolbar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px;margin-bottom:15px}.dv-search-group{display:flex;align-items:center;gap:8px;flex:1 1 155px;min-width:0}.dv-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:6px}.dv-action{display:inline-flex;align-items:center;gap:6px;padding:5px 8px;box-sizing:border-box;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text);font-size:12.5px;font-weight:500;white-space:nowrap;cursor:pointer;-webkit-user-select:none;user-select:none;transition:background-color .15s ease,border-color .15s ease}.dv-action:hover{background-color:var(--vbn-color-surface-alt)}.dv-action.is-open{border-color:var(--vbn-color-text-muted);background-color:var(--vbn-color-surface-alt)}.dv-count{display:inline-grid;place-items:center;min-width:18px;height:18px;padding:0 5px;box-sizing:border-box;border-radius:999px;background-color:var(--vbn-color-surface-alt);box-shadow:inset 0 0 0 1px var(--vbn-color-border);color:var(--vbn-color-text-muted);font-size:11px;font-weight:600}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2.SvgComponent, selector: "verben-svg", inputs: ["icon", "width", "height", "fill", "stroke", "type", "size"] }, { kind: "component", type: i3.VerbenaButtonComponent, selector: "verbena-button", inputs: ["type", "text", "styleType", "size", "block", "disable", "disabled", "isLoading", "spinnerSize", "spinnerColor", "svg", "svgPosition", "svgWidth", "svgHeight", "svgSize", "svgColor", "icon", "useIcon", "iconPosition", "iconColor", "variant", "weight", "bgColor", "textColor", "border", "borderRadius", "pd", "width", "height", "fontSize", "fontWeight", "buttonClass", "buttonTextClass"] }, { kind: "directive", type: i4.OutSideClickDirective, selector: "[appOutSideClick]", inputs: ["appOutSideClick"], outputs: ["outSideClick"] }, { kind: "directive", type: i5.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: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
181
181
|
}
|
|
182
182
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.10", ngImport: i0, type: DataViewComponent, decorators: [{
|
|
183
183
|
type: Component,
|
|
184
|
-
args: [{ selector: 'verben-data-view', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"toolbar\">\n <div class=\"dv-search-group\">\n <div *ngIf=\"viewState.isToggle\" class=\"toggle-button-container\">\n <button type=\"button\" (click)=\"toggleView()\" [ngClass]=\"buttonClass\">\n <verben-svg\n [icon]=\"tableIcon\"\n [class.active]=\"!isTableView\"\n [ngClass]=\"!isTableView ? activeIconClass : iconClass\"\n ></verben-svg>\n <verben-svg\n [icon]=\"cardIcon\"\n [class.active]=\"isTableView\"\n [ngClass]=\"isTableView ? activeIconClass : iconClass\"\n [width]=\"25\"\n [height]=\"25\"\n ></verben-svg>\n </button>\n </div>\n <!-- Search Input -->\n <div\n [style.width]=\"inputWidth\"\n class=\"search-input\"\n *ngIf=\"viewState.isSearch\"\n >\n <verben-svg [icon]=\"'search2'\" [width]=\"20\" [height]=\"20\"></verben-svg>\n <input\n *ngIf=\"!useTwoWayBinding\"\n [type]=\"'text'\"\n [placeholder]=\"'Search'\"\n (input)=\"onSearch($event)\"\n [style.border]=\"'0'\"\n [value]=\"searchValue\"\n />\n <input\n *ngIf=\"useTwoWayBinding\"\n [type]=\"'text'\"\n [placeholder]=\"'Search'\"\n (input)=\"onSearch($event)\"\n [style.border]=\"'0'\"\n [(ngModel)]=\"searchValue\"\n />\n <verben-svg\n *ngIf=\"searchValue.length > 0\"\n [icon]=\"'close'\"\n [width]=\"15\"\n (click)=\"onClearSearch()\"\n class=\"close-icon-class\"\n [height]=\"15\"\n ></verben-svg>\n </div>\n </div>\n <div class=\"relative dv-actions\">\n <!-- Column Section -->\n <ng-container\n [appOutSideClick]=\"showColumnChild\"\n (outSideClick)=\"resetChildViewsExcept('column')\"\n *ngIf=\"viewState.isColumn && isTableView\"\n >\n <ng-container *ngIf=\"columnTemplate; else defaultColumn\"></ng-container>\n <ng-template #defaultColumn>\n <span\n [ngClass]=\"['dv-action', columnCustomClass ? columnCustomClass : '']\"\n [class.is-open]=\"showColumnChild\"\n (click)=\"toggleChildView('column')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'column'\"></verben-svg>\n <span>Columns</span\n ><span class=\"dv-count\">{{ selectedColumnCount }}</span>\n </span>\n <div\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n [style.display]=\"showColumnChild ? 'block' : 'none'\"\n >\n <!-- Kept in the DOM (hidden via display) rather than *ngIf so the\n projected panel stays change-detected and reflects host state\n updates (e.g. restored column arrangement) even while collapsed. -->\n <ng-content select=\"[column-content]\"></ng-content>\n </div>\n </ng-template>\n </ng-container>\n\n <!-- Filter Section -->\n <ng-container\n [appOutSideClick]=\"showFilterChild\"\n (outSideClick)=\"resetChildViewsExcept('filter')\"\n *ngIf=\"viewState.isFilter\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"filterTemplate; else defaultFilter\"></ng-container>\n <ng-template #defaultFilter>\n <span\n [ngClass]=\"['dv-action', filterCustomClass ? filterCustomClass : '']\"\n [class.is-open]=\"showFilterChild\"\n (click)=\"toggleChildView('filter')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'filter'\"></verben-svg>\n <span>Filter</span\n ><span class=\"dv-count\">{{ selectedFilterTableCount }}</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n [style.display]=\"showFilterChild ? 'block' : 'none'\"\n >\n <!-- Kept in the DOM (hidden via display) rather than *ngIf so the\n projected panel stays change-detected and reflects host state\n updates (e.g. restored filters) even while collapsed. -->\n <ng-content select=\"[filter-content]\"></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!--import Section-->\n <ng-container\n [appOutSideClick]=\"showImportChild\"\n (outSideClick)=\"resetChildViewsExcept('import')\"\n *ngIf=\"viewState.isImport\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"importTemplate; else defaultImport\"></ng-container>\n <ng-template #defaultImport>\n <span\n [ngClass]=\"['dv-action', importCustomClass ? importCustomClass : '']\"\n [class.is-open]=\"showImportChild\"\n (click)=\"toggleChildView('import')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'file'\"></verben-svg>\n <span>Import</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n >\n <ng-content\n *ngIf=\"showImportChild\"\n select=\"[import-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!-- Sort Section -->\n <ng-container\n [appOutSideClick]=\"showSortChild\"\n (outSideClick)=\"resetChildViewsExcept('sort')\"\n *ngIf=\"viewState.isSort\"\n >\n <ng-container *ngIf=\"sortTemplate; else defaultSort\"></ng-container>\n <ng-template #defaultSort>\n <span\n [ngClass]=\"['dv-action', sortCustomClass ? sortCustomClass : '']\"\n [class.is-open]=\"showSortChild\"\n (click)=\"toggleChildView('sort')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'sort'\"></verben-svg>\n <span>Sort</span><span class=\"dv-count\">{{ selectedSortCount }}</span>\n </span>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content\n *ngIf=\"showSortChild\"\n select=\"[sort-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!--Extend Section-->\n <ng-container\n [appOutSideClick]=\"showExtendChild\"\n (outSideClick)=\"resetChildViewsExcept('extend')\"\n *ngIf=\"viewState.isExtend\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"extendTemplate; else defaultExtend\"></ng-container>\n <ng-template #defaultExtend>\n <span\n [ngClass]=\"['dv-action', importCustomClass ? extendCustomClass : '']\"\n [class.is-open]=\"showExtendChild\"\n (click)=\"toggleChildView('extend')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'extend'\"></verben-svg>\n <span>Extend</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n >\n <ng-content\n *ngIf=\"showImportChild\"\n select=\"[extend-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!-- Export Section -->\n <ng-container\n [appOutSideClick]=\"showExportChild\"\n (outSideClick)=\"resetChildViewsExcept('export')\"\n *ngIf=\"viewState.isExport\"\n >\n <ng-container *ngIf=\"exportTemplate; else defaultExport\"></ng-container>\n <ng-template #defaultExport>\n <span\n [ngClass]=\"['dv-action', exportCustomClass ? exportCustomClass : '']\"\n [class.is-open]=\"showExportChild\"\n (click)=\"toggleChildView('export')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'export'\"></verben-svg>\n Export\n </span>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content\n *ngIf=\"showExportChild\"\n select=\"[export-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n\n <!-- Select Section -->\n <!-- <div *ngIf=\"viewState.isSelect\">\n <span\n [ngClass]=\"[\n 'flex gap text-xs items-center pd rounded cursor-pointer',\n selectCustomClass ? selectCustomClass : ''\n ]\"\n [style.background-color]=\"'var(--vbn-color-surface-alt)'\"\n (click)=\"toggleChildView('select')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'select'\"></verben-svg>\n <span>Select</span>\n <verben-svg [width]=\"6\" [icon]=\"'chevron-down'\"></verben-svg>\n </span>\n </div> -->\n\n <!-- Create Button jj-->\n\n <div\n [appOutSideClick]=\"create\"\n (outSideClick)=\"resetChildViewsExcept('create')\"\n *ngIf=\"viewState.isCreate\"\n >\n <verbena-button\n [bgColor]=\"'var(--vbn-color-primary)'\"\n [buttonClass]=\"createCustomClass\"\n [textColor]=\"'var(--vbn-color-on-primary)'\"\n [svg]=\"'add'\"\n [svgPosition]=\"'right'\"\n [text]=\"'Create New'\"\n (click)=\"toggleChildView('create')\"\n >\n </verbena-button>\n <ng-container *ngIf=\"createTemplate; else defaultCreate\"></ng-container>\n <ng-template #defaultCreate>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content *ngIf=\"create\" select=\"[create-content]\"></ng-content>\n </div>\n </ng-template>\n </div>\n </div>\n\n <div *ngIf=\"children\">\n <ng-container *ngIf=\"children; else defaultChildren\"></ng-container>\n <ng-template #defaultChildren>\n <div>\n <ng-content select=\"[children]\"></ng-content>\n </div>\n </ng-template>\n </div>\n</div>\n\n<!-- Grid and List View Handling -->\n<div *ngIf=\"isTableView; else listViewTemplate\">\n <div [style.overflow]=\"'auto'\" [class]=\"tableClass\">\n <ng-content select=\"[table-content]\"></ng-content>\n </div>\n</div>\n<ng-template #listViewTemplate>\n <div [class]=\"cardClass\">\n <ng-content select=\"[card-content]\"></ng-content>\n </div>\n</ng-template>\n", styles: [".toggle-button-container button{display:inline-flex;align-items:center;gap:2px;height:36px;padding:3px;box-sizing:border-box;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text-muted);cursor:pointer}.toggle-button-container button:focus-visible{outline:2px solid var(--vbn-color-border-focus);outline-offset:1px}.input-class{border:none;min-width:100%;display:block}.toggle-button-container verben-svg{display:inline-grid;place-items:center;width:28px;height:28px;box-sizing:border-box;padding:4px;border-radius:6px;transition:background-color .15s ease}.toggle-button-container verben-svg.active{background-color:var(--vbn-color-surface-alt);box-shadow:0 1px 2px #0000001a}.justify-end{justify-self:end}.flex{display:flex}.flex-1{flex:1}.justify-between{justify-content:space-between}.items-center{align-items:center}.font-semibold{font-weight:600}.font-normal{font-weight:400}.text-sm{font-size:14px}.text-xs{font-size:12px}.gap{gap:7px}.pd{padding:5px 8px}.rounded-sm{border-radius:10px}.cursor-pointer{cursor:pointer}.search-input{position:relative;display:flex;align-items:center;gap:8px;flex:0 1 auto;min-width:85px;max-width:100%;height:36px;box-sizing:border-box;padding:0 32px 0 10px;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text-muted);transition:border-color .15s ease,box-shadow .15s ease}.search-input:focus-within{border-color:var(--vbn-color-border-focus);box-shadow:0 0 0 3px color-mix(in srgb,var(--vbn-color-border-focus) 18%,transparent)}.search-input input{display:block;width:100%;min-width:0;padding:0;outline:0;background-color:transparent;color:var(--vbn-color-text);font:inherit;font-size:14px}.search-input input::placeholder{color:var(--vbn-color-text-muted);font-size:14px}sup{color:var(--vbn-color-border-focus);font-weight:500}.data-view-element{position:absolute;top:calc(100% + 6px);right:0;max-width:100%;text-align:left}.relative{position:relative}.z-10{z-index:100000000000}.close-icon-class{position:absolute;top:50%;right:8px;display:inline-grid;place-items:center;width:20px;height:20px;border-radius:999px;transform:translateY(-50%);cursor:pointer}.close-icon-class:hover{background-color:var(--vbn-color-surface-alt)}.toolbar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px;margin-bottom:15px}.dv-search-group{display:flex;align-items:center;gap:8px;flex:1 1 150px;min-width:0}.dv-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:6px}.dv-action{display:inline-flex;align-items:center;gap:6px;padding:5px 8px;box-sizing:border-box;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text);font-size:12.5px;font-weight:500;white-space:nowrap;cursor:pointer;-webkit-user-select:none;user-select:none;transition:background-color .15s ease,border-color .15s ease}.dv-action:hover{background-color:var(--vbn-color-surface-alt)}.dv-action.is-open{border-color:var(--vbn-color-text-muted);background-color:var(--vbn-color-surface-alt)}.dv-count{display:inline-grid;place-items:center;min-width:18px;height:18px;padding:0 5px;box-sizing:border-box;border-radius:999px;background-color:var(--vbn-color-surface-alt);box-shadow:inset 0 0 0 1px var(--vbn-color-border);color:var(--vbn-color-text-muted);font-size:11px;font-weight:600}\n"] }]
|
|
184
|
+
args: [{ selector: 'verben-data-view', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"toolbar\">\n <div class=\"dv-search-group\">\n <div *ngIf=\"viewState.isToggle\" class=\"toggle-button-container\">\n <button type=\"button\" (click)=\"toggleView()\" [ngClass]=\"buttonClass\">\n <verben-svg\n [icon]=\"tableIcon\"\n [class.active]=\"!isTableView\"\n [ngClass]=\"!isTableView ? activeIconClass : iconClass\"\n ></verben-svg>\n <verben-svg\n [icon]=\"cardIcon\"\n [class.active]=\"isTableView\"\n [ngClass]=\"isTableView ? activeIconClass : iconClass\"\n [width]=\"25\"\n [height]=\"25\"\n ></verben-svg>\n </button>\n </div>\n <!-- Search Input -->\n <div\n [style.width]=\"inputWidth\"\n class=\"search-input\"\n *ngIf=\"viewState.isSearch\"\n >\n <verben-svg [icon]=\"'search2'\" [width]=\"20\" [height]=\"20\"></verben-svg>\n <input\n *ngIf=\"!useTwoWayBinding\"\n [type]=\"'text'\"\n [placeholder]=\"'Search'\"\n (input)=\"onSearch($event)\"\n [style.border]=\"'0'\"\n [value]=\"searchValue\"\n />\n <input\n *ngIf=\"useTwoWayBinding\"\n [type]=\"'text'\"\n [placeholder]=\"'Search'\"\n (input)=\"onSearch($event)\"\n [style.border]=\"'0'\"\n [(ngModel)]=\"searchValue\"\n />\n <verben-svg\n *ngIf=\"searchValue.length > 0\"\n [icon]=\"'close'\"\n [width]=\"15\"\n (click)=\"onClearSearch()\"\n class=\"close-icon-class\"\n [height]=\"15\"\n ></verben-svg>\n </div>\n </div>\n <div class=\"relative dv-actions\">\n <!-- Column Section -->\n <ng-container\n [appOutSideClick]=\"showColumnChild\"\n (outSideClick)=\"resetChildViewsExcept('column')\"\n *ngIf=\"viewState.isColumn && isTableView\"\n >\n <ng-container *ngIf=\"columnTemplate; else defaultColumn\"></ng-container>\n <ng-template #defaultColumn>\n <span\n [ngClass]=\"['dv-action', columnCustomClass ? columnCustomClass : '']\"\n [class.is-open]=\"showColumnChild\"\n (click)=\"toggleChildView('column')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'column'\"></verben-svg>\n <span>Columns</span\n ><span class=\"dv-count\">{{ selectedColumnCount }}</span>\n </span>\n <div\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n [style.display]=\"showColumnChild ? 'block' : 'none'\"\n >\n <!-- Kept in the DOM (hidden via display) rather than *ngIf so the\n projected panel stays change-detected and reflects host state\n updates (e.g. restored column arrangement) even while collapsed. -->\n <ng-content select=\"[column-content]\"></ng-content>\n </div>\n </ng-template>\n </ng-container>\n\n <!-- Filter Section -->\n <ng-container\n [appOutSideClick]=\"showFilterChild\"\n (outSideClick)=\"resetChildViewsExcept('filter')\"\n *ngIf=\"viewState.isFilter\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"filterTemplate; else defaultFilter\"></ng-container>\n <ng-template #defaultFilter>\n <span\n [ngClass]=\"['dv-action', filterCustomClass ? filterCustomClass : '']\"\n [class.is-open]=\"showFilterChild\"\n (click)=\"toggleChildView('filter')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'filter'\"></verben-svg>\n <span>Filter</span\n ><span class=\"dv-count\">{{ selectedFilterTableCount }}</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n [style.display]=\"showFilterChild ? 'block' : 'none'\"\n >\n <!-- Kept in the DOM (hidden via display) rather than *ngIf so the\n projected panel stays change-detected and reflects host state\n updates (e.g. restored filters) even while collapsed. -->\n <ng-content select=\"[filter-content]\"></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!--import Section-->\n <ng-container\n [appOutSideClick]=\"showImportChild\"\n (outSideClick)=\"resetChildViewsExcept('import')\"\n *ngIf=\"viewState.isImport\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"importTemplate; else defaultImport\"></ng-container>\n <ng-template #defaultImport>\n <span\n [ngClass]=\"['dv-action', importCustomClass ? importCustomClass : '']\"\n [class.is-open]=\"showImportChild\"\n (click)=\"toggleChildView('import')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'file'\"></verben-svg>\n <span>Import</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n >\n <ng-content\n *ngIf=\"showImportChild\"\n select=\"[import-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!-- Sort Section -->\n <ng-container\n [appOutSideClick]=\"showSortChild\"\n (outSideClick)=\"resetChildViewsExcept('sort')\"\n *ngIf=\"viewState.isSort\"\n >\n <ng-container *ngIf=\"sortTemplate; else defaultSort\"></ng-container>\n <ng-template #defaultSort>\n <span\n [ngClass]=\"['dv-action', sortCustomClass ? sortCustomClass : '']\"\n [class.is-open]=\"showSortChild\"\n (click)=\"toggleChildView('sort')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'sort'\"></verben-svg>\n <span>Sort</span><span class=\"dv-count\">{{ selectedSortCount }}</span>\n </span>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content\n *ngIf=\"showSortChild\"\n select=\"[sort-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!--Extend Section-->\n <ng-container\n [appOutSideClick]=\"showExtendChild\"\n (outSideClick)=\"resetChildViewsExcept('extend')\"\n *ngIf=\"viewState.isExtend\"\n (click)=\"stopPropagation($event)\"\n >\n <ng-container *ngIf=\"extendTemplate; else defaultExtend\"></ng-container>\n <ng-template #defaultExtend>\n <span\n [ngClass]=\"['dv-action', importCustomClass ? extendCustomClass : '']\"\n [class.is-open]=\"showExtendChild\"\n (click)=\"toggleChildView('extend')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'extend'\"></verben-svg>\n <span>Extend</span>\n </span>\n <div\n (click)=\"stopPropagation($event)\"\n [style.z-index]=\"zIndex\"\n class=\"data-view-element\"\n >\n <ng-content\n *ngIf=\"showImportChild\"\n select=\"[extend-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n <!-- Export Section -->\n <ng-container\n [appOutSideClick]=\"showExportChild\"\n (outSideClick)=\"resetChildViewsExcept('export')\"\n *ngIf=\"viewState.isExport\"\n >\n <ng-container *ngIf=\"exportTemplate; else defaultExport\"></ng-container>\n <ng-template #defaultExport>\n <span\n [ngClass]=\"['dv-action', exportCustomClass ? exportCustomClass : '']\"\n [class.is-open]=\"showExportChild\"\n (click)=\"toggleChildView('export')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'export'\"></verben-svg>\n Export\n </span>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content\n *ngIf=\"showExportChild\"\n select=\"[export-content]\"\n ></ng-content>\n </div>\n </ng-template>\n </ng-container>\n\n <!-- Select Section -->\n <!-- <div *ngIf=\"viewState.isSelect\">\n <span\n [ngClass]=\"[\n 'flex gap text-xs items-center pd rounded cursor-pointer',\n selectCustomClass ? selectCustomClass : ''\n ]\"\n [style.background-color]=\"'var(--vbn-color-surface-alt)'\"\n (click)=\"toggleChildView('select')\"\n >\n <verben-svg [width]=\"15\" [icon]=\"'select'\"></verben-svg>\n <span>Select</span>\n <verben-svg [width]=\"6\" [icon]=\"'chevron-down'\"></verben-svg>\n </span>\n </div> -->\n\n <!-- Create Button jj-->\n\n <div\n [appOutSideClick]=\"create\"\n (outSideClick)=\"resetChildViewsExcept('create')\"\n *ngIf=\"viewState.isCreate\"\n >\n <verbena-button\n [bgColor]=\"'var(--vbn-color-primary)'\"\n [buttonClass]=\"createCustomClass\"\n [textColor]=\"'var(--vbn-color-on-primary)'\"\n [svg]=\"'add'\"\n [svgPosition]=\"'right'\"\n [text]=\"'Create New'\"\n (click)=\"toggleChildView('create')\"\n >\n </verbena-button>\n <ng-container *ngIf=\"createTemplate; else defaultCreate\"></ng-container>\n <ng-template #defaultCreate>\n <div [style.z-index]=\"zIndex\" class=\"data-view-element\">\n <ng-content *ngIf=\"create\" select=\"[create-content]\"></ng-content>\n </div>\n </ng-template>\n </div>\n </div>\n\n <div *ngIf=\"children\">\n <ng-container *ngIf=\"children; else defaultChildren\"></ng-container>\n <ng-template #defaultChildren>\n <div>\n <ng-content select=\"[children]\"></ng-content>\n </div>\n </ng-template>\n </div>\n</div>\n\n<!-- Grid and List View Handling -->\n<div *ngIf=\"isTableView; else listViewTemplate\">\n <div [style.overflow]=\"'auto'\" [class]=\"tableClass\">\n <ng-content select=\"[table-content]\"></ng-content>\n </div>\n</div>\n<ng-template #listViewTemplate>\n <div [class]=\"cardClass\">\n <ng-content select=\"[card-content]\"></ng-content>\n </div>\n</ng-template>\n", styles: [".toggle-button-container button{display:inline-flex;align-items:center;gap:2px;height:36px;padding:3px;box-sizing:border-box;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text-muted);cursor:pointer}.toggle-button-container button:focus-visible{outline:2px solid var(--vbn-color-border-focus);outline-offset:1px}.input-class{border:none;min-width:100%;display:block}.toggle-button-container verben-svg{display:inline-grid;place-items:center;width:28px;height:28px;box-sizing:border-box;padding:4px;border-radius:6px;transition:background-color .15s ease}.toggle-button-container verben-svg.active{background-color:var(--vbn-color-surface-alt);box-shadow:0 1px 2px #0000001a}.justify-end{justify-self:end}.flex{display:flex}.flex-1{flex:1}.justify-between{justify-content:space-between}.items-center{align-items:center}.font-semibold{font-weight:600}.font-normal{font-weight:400}.text-sm{font-size:14px}.text-xs{font-size:12px}.gap{gap:7px}.pd{padding:5px 8px}.rounded-sm{border-radius:10px}.cursor-pointer{cursor:pointer}.search-input{position:relative;display:flex;align-items:center;gap:8px;flex:0 1 auto;min-width:85px;max-width:100%;height:36px;box-sizing:border-box;padding:0 32px 0 10px;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text-muted);transition:border-color .15s ease,box-shadow .15s ease}.search-input:focus-within{border-color:var(--vbn-color-border-focus);box-shadow:0 0 0 3px color-mix(in srgb,var(--vbn-color-border-focus) 18%,transparent)}.search-input input{display:block;width:100%;min-width:0;padding:0;outline:0;background-color:transparent;color:var(--vbn-color-text);font:inherit;font-size:14px}.search-input input::placeholder{color:var(--vbn-color-text-muted);font-size:14px}sup{color:var(--vbn-color-border-focus);font-weight:500}.data-view-element{position:absolute;top:calc(100% + 6px);right:0;max-width:100%;text-align:left}.relative{position:relative}.z-10{z-index:100000000000}.close-icon-class{position:absolute;top:50%;right:8px;display:inline-grid;place-items:center;width:20px;height:20px;border-radius:999px;transform:translateY(-50%);cursor:pointer}.close-icon-class:hover{background-color:var(--vbn-color-surface-alt)}.toolbar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px;margin-bottom:15px}.dv-search-group{display:flex;align-items:center;gap:8px;flex:1 1 155px;min-width:0}.dv-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:6px}.dv-action{display:inline-flex;align-items:center;gap:6px;padding:5px 8px;box-sizing:border-box;border:1px solid var(--vbn-color-border);border-radius:8px;background-color:var(--vbn-color-surface);color:var(--vbn-color-text);font-size:12.5px;font-weight:500;white-space:nowrap;cursor:pointer;-webkit-user-select:none;user-select:none;transition:background-color .15s ease,border-color .15s ease}.dv-action:hover{background-color:var(--vbn-color-surface-alt)}.dv-action.is-open{border-color:var(--vbn-color-text-muted);background-color:var(--vbn-color-surface-alt)}.dv-count{display:inline-grid;place-items:center;min-width:18px;height:18px;padding:0 5px;box-sizing:border-box;border-radius:999px;background-color:var(--vbn-color-surface-alt);box-shadow:inset 0 0 0 1px var(--vbn-color-border);color:var(--vbn-color-text-muted);font-size:11px;font-weight:600}\n"] }]
|
|
185
185
|
}], ctorParameters: () => [{ type: i0.Renderer2 }], propDecorators: { buttonClass: [{
|
|
186
186
|
type: Input
|
|
187
187
|
}], iconClass: [{
|