@fuentis/phoenix-ui 0.0.9-alpha.97 → 0.0.9-alpha.98

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.
@@ -54,7 +54,7 @@ import * as i11 from 'primeng/checkbox';
54
54
  import { CheckboxModule } from 'primeng/checkbox';
55
55
  import * as i12 from 'primeng/select';
56
56
  import { SelectModule } from 'primeng/select';
57
- import * as i1$3 from 'primeng/calendar';
57
+ import * as i1$4 from 'primeng/calendar';
58
58
  import { CalendarModule } from 'primeng/calendar';
59
59
  import * as i3$9 from 'primeng/dropdown';
60
60
  import { DropdownModule } from 'primeng/dropdown';
@@ -63,6 +63,8 @@ import { EditorModule } from 'primeng/editor';
63
63
  import { PanelModule } from 'primeng/panel';
64
64
  import { Subject, BehaviorSubject, combineLatestWith, debounceTime, switchMap, of, distinctUntilChanged, combineLatest } from 'rxjs';
65
65
  import * as i4$2 from '@angular/common/http';
66
+ import * as i1$3 from 'primeng/dynamicdialog';
67
+ import { DialogService } from 'primeng/dynamicdialog';
66
68
  import * as i3$5 from 'primeng/colorpicker';
67
69
  import { ColorPickerModule } from 'primeng/colorpicker';
68
70
  import * as i3$6 from 'primeng/inputnumber';
@@ -77,7 +79,7 @@ import * as i5$1 from 'primeng/image';
77
79
  import { ImageModule } from 'primeng/image';
78
80
  import { TextareaModule } from 'primeng/textarea';
79
81
  import { FileUploadModule } from 'primeng/fileupload';
80
- import * as i1$4 from '@angular/platform-browser';
82
+ import * as i1$5 from '@angular/platform-browser';
81
83
  import { MessagesModule } from 'primeng/messages';
82
84
  import * as i3$b from 'primeng/accordion';
83
85
  import { AccordionModule } from 'primeng/accordion';
@@ -1516,6 +1518,7 @@ class TableComponent {
1516
1518
  isLoading = signal(false);
1517
1519
  lastLoadedIndex = 0; // Tracks the last loaded index to prevent redundant loading
1518
1520
  originalData = []; // Holds origin table data
1521
+ selectionTypeEnum = tableSelectionType;
1519
1522
  hasLoadedInitialData = false; // Prevents multiple initial calls
1520
1523
  // Enum for column types
1521
1524
  columnTypeEnum = tableColumnType;
@@ -1594,12 +1597,13 @@ class TableComponent {
1594
1597
  }
1595
1598
  // **Apply Filters**
1596
1599
  applyFilters(filters) {
1597
- this.allData = this.originalData.filter(item => {
1598
- return Object.keys(filters).every(key => {
1600
+ this.allData = this.originalData.filter((item) => {
1601
+ return Object.keys(filters).every((key) => {
1599
1602
  const filterValue = filters[key]?.key || filters[key];
1600
1603
  const itemValue = item[key]?.key || item[key];
1601
1604
  return filterValue
1602
- ? itemValue?.toString().toLowerCase() === filterValue.toString().toLowerCase()
1605
+ ? itemValue?.toString().toLowerCase() ===
1606
+ filterValue.toString().toLowerCase()
1603
1607
  : true;
1604
1608
  });
1605
1609
  });
@@ -1611,7 +1615,7 @@ class TableComponent {
1611
1615
  }
1612
1616
  // **Apply Column Selection**
1613
1617
  applyColumns(selectedColumns) {
1614
- this.selectedColumns.set(this.columns.filter(col => selectedColumns.includes(col.field)));
1618
+ this.selectedColumns.set(this.columns.filter((col) => selectedColumns.includes(col.field)));
1615
1619
  }
1616
1620
  // **Handle Search Query**
1617
1621
  onSearch(query) {
@@ -1640,11 +1644,11 @@ class TableComponent {
1640
1644
  // **Filter table data on search**
1641
1645
  filterTableData() {
1642
1646
  const query = this.searchQuery();
1643
- const filteredData = this.allData.filter(item => Object.values(item).some(value => value?.toString().toLowerCase().includes(query)));
1647
+ const filteredData = this.allData.filter((item) => Object.values(item).some((value) => value?.toString().toLowerCase().includes(query)));
1644
1648
  this.tableDataSignal.set(filteredData);
1645
1649
  }
1646
1650
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: TableComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1647
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.4", type: TableComponent, isStandalone: true, selector: "phoenix-table", inputs: { data: "data", columns: "columns", tableConfiguration: "tableConfiguration" }, outputs: { actionClick: "actionClick", rowSelection: "rowSelection" }, ngImport: i0, template: "<div class=\"border-1 border-round-sm border-300 border-round-md m-2\">\n @if (selectedItems().length <= 0){\n <table-caption\n [columns]=\"columns\"\n [tableConfiguration]=\"tableConfiguration\"\n [selectedItems]=\"selectedItems()\"\n (applyFiltersEvent)=\"applyFilters($event)\"\n (applyColumnsEvent)=\"applyColumns($event)\"\n (searchChange)=\"onSearch($event)\"\n (actionClick)=\"handleActionClick($event)\"\n >\n </table-caption>\n } @else {\n <div\n style=\"min-height: 40px; padding: 8px\"\n class=\"flex justify-content-between align-items-center border-bottom-1 border-300 pl-5 pr-5 text-sm text-500\"\n >\n <span>{{ selectedItems().length }} items selected</span>\n <div>\n <ng-container *ngFor=\"let action of tableConfiguration.bulkActions\">\n <phoenix-phoenix-data-table-action\n [actionConfig]=\"action\"\n [selectedData]=\"selectedItems\"\n (actionClick)=\"actionClick.emit({ action, selectedItems })\"\n ></phoenix-phoenix-data-table-action>\n </ng-container>\n\n <button\n class=\"p-button p-button-text p-button-plain\"\n (click)=\"selectedItems.set([])\"\n aria-label=\"Clear Selection\"\n >\n <i class=\"pi pi-times\"></i>\n </button>\n </div>\n </div>\n }\n\n <p-table\n [columns]=\"selectedColumns()\"\n [value]=\"tableDataSignal()\"\n [size]=\"'small'\"\n scrollable=\"true\"\n [scrollHeight]=\"tableConfiguration.scrollHeight\"\n [virtualScroll]=\"true\"\n [virtualScrollItemSize]=\"50\"\n [rows]=\"100\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords()\"\n (onLazyLoad)=\"loadLazyData($event)\"\n [selection]=\"selectedItems()\"\n (selectionChange)=\"onSelectionChange($event)\"\n [sortMode]=\"'multiple'\"\n [size]=\"'small'\"\n [resizableColumns]=\"true\"\n columnResizeMode=\"expand\"\n >\n <ng-template #header let-columns>\n <tr style=\"height: 40px\" class=\"dt-header\">\n <th class=\"custom-th\" style=\"width: 4rem\"><p-tableHeaderCheckbox /></th>\n <th\n pResizableColumn\n class=\"custom-th font-bold\"\n *ngFor=\"let col of columns\"\n [pSortableColumn]=\"col.field\"\n >\n {{ col.header | translate }}\n <p-sortIcon [field]=\"col.field\"></p-sortIcon>\n </th>\n <!-- create empty th placeholders for actions -->\n <th class=\"custom-th\"></th>\n </tr>\n </ng-template>\n\n <ng-template\n #body\n let-rowData\n let-columns=\"columns\"\n let-rowIndex=\"rowIndex\"\n >\n <tr>\n <td>\n <p-tableCheckbox [value]=\"rowData\" />\n </td>\n <td\n *ngFor=\"let col of columns; let i = index\"\n (click)=\"\n i < 2 && tableConfiguration.hasCellClick\n ? onRowClick($event, rowData)\n : null\n \"\n [ngClass]=\"{\n 'text-blue-500 underline cursor-pointer':\n i < 2 && tableConfiguration.hasCellClick\n }\"\n >\n <ng-container [ngSwitch]=\"col.columnType\">\n <!-- TAG case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.TAG\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <p-tag\n styleClass=\"custom-tag\"\n [style]=\"{\n 'background-color': rowData[col.field + 'Color'] || '#ccc',\n \n }\"\n [value]=\"rowData[col.field]?.name || rowData[col.field]\"\n >\n </p-tag>\n </ng-container>\n </ng-container>\n\n <!-- PERSON case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.PERSON\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <p-avatar\n [label]=\"(rowData[col.field] | cell : col)?.avatar\"\n class=\"mr-1\"\n [style]=\"{ 'background-color': '#9c27b0', color: '#ffffff' }\"\n shape=\"circle\"\n >\n </p-avatar>\n {{ (rowData[col.field] | cell : col)?.name }}\n </ng-container>\n </ng-container>\n\n <!-- LIST case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.LIST\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <ul\n *ngFor=\"let item of rowData[col.field]\"\n [attr.data-cy]=\"\n 'table-cell-' + (columnTypeEnum.LIST | lowercase)\n \"\n >\n <li>{{ item.name }}</li>\n </ul>\n </ng-container>\n </ng-container>\n\n <!-- DEFAULT case -->\n <ng-container *ngSwitchDefault>\n <span\n [innerHTML]=\"rowData[col.field] | cell : col : dateFormat\"\n ></span>\n </ng-container>\n </ng-container>\n </td>\n\n <td class=\"p-0\">\n <ng-container *ngFor=\"let action of tableConfiguration.rowActions\">\n <phoenix-phoenix-data-table-action\n [actionConfig]=\"action\"\n [rowData]=\"rowData\"\n (actionClick)=\"handleActionClick({ action, rowData })\"\n ></phoenix-phoenix-data-table-action\n ></ng-container>\n </td>\n </tr>\n </ng-template>\n\n <ng-template #emptyCell> -- </ng-template>\n\n <ng-template pTemplate=\"loadingbody\" let-columns>\n <tr style=\"height: 46px\">\n <td *ngFor=\"let col of columns; let even = even\">\n <tr>\n <td *ngFor=\"let col of columns; let even = even\">\n <p-skeleton\n [ngStyle]=\"{\n width: '60%',\n }\"\n ></p-skeleton>\n </td>\n\n <td>\n <p-skeleton\n [ngStyle]=\"{\n width: '20%',\n }\"\n ></p-skeleton>\n </td>\n </tr>\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"emptymessage\">\n <td class=\"p-2\" colspan=\"100\">\n <div class=\"flex align-items-center\">\n <i class=\"pi pi-info-circle mr-2\"></i>\n {{ \"NO_RESULTS_FOUND\" | translate }}\n </div>\n </td>\n </ng-template>\n </p-table>\n <div class=\"border-top-1 border-300 pl-2 p-1 text-sm text-500\">\n Total records: {{ tableDataSignal().length }}\n </div>\n</div>\n", styles: [".custom-th{background-color:var(--surface-100)!important}.dt-header th:not(:last-child){border-right:1px solid #e4e4e4!important}:is() .p-avatar{border-radius:50%!important}::ng-deep .p-paginator button{scale:.7}::ng-deep .p-paginator-rpp-options{scale:.7}::ng-deep .p-datatable .p-datatable-header{border-radius:10px 10px 0 0}::ng-deep .p-tag{font-weight:400!important;font-size:.875rem!important}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1$1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "pipe", type: i1$1.LowerCasePipe, name: "lowercase" }, { kind: "ngmodule", type: TableModule }, { kind: "component", type: i2$3.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "size", "showGridlines", "stripedRows", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "virtualRowHeight", "selectAll"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$4.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$3.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "directive", type: i2$3.ResizableColumn, selector: "[pResizableColumn]", inputs: ["pResizableColumnDisabled"] }, { kind: "component", type: i2$3.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i2$3.TableCheckbox, selector: "p-tableCheckbox", inputs: ["disabled", "value", "index", "inputId", "name", "required", "ariaLabel"] }, { kind: "component", type: i2$3.TableHeaderCheckbox, selector: "p-tableHeaderCheckbox", inputs: ["disabled", "inputId", "name", "ariaLabel"] }, { kind: "component", type: TableCaptionComponent, selector: "table-caption", inputs: ["tableConfiguration", "columns", "searchQuery", "selectedItems"], outputs: ["applyFiltersEvent", "applyColumnsEvent", "searchChange", "actionClick"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "component", type: PhoenixDataTableActionComponent, selector: "phoenix-phoenix-data-table-action", inputs: ["actionConfig", "rowData", "selectedData"], outputs: ["actionClick"] }, { kind: "ngmodule", type: TagModule }, { kind: "component", type: i7.Tag, selector: "p-tag", inputs: ["style", "styleClass", "severity", "value", "icon", "rounded"] }, { kind: "ngmodule", type: AvatarModule }, { kind: "component", type: i6.Avatar, selector: "p-avatar", inputs: ["label", "icon", "image", "size", "shape", "style", "styleClass", "ariaLabel", "ariaLabelledBy"], outputs: ["onImageError"] }, { kind: "ngmodule", type: TooltipModule }, { kind: "pipe", type: TableCellPipe, name: "cell" }, { kind: "ngmodule", type: SkeletonModule }, { kind: "component", type: i9.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }] });
1651
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.4", type: TableComponent, isStandalone: true, selector: "phoenix-table", inputs: { data: "data", columns: "columns", tableConfiguration: "tableConfiguration" }, outputs: { actionClick: "actionClick", rowSelection: "rowSelection" }, ngImport: i0, template: "<div class=\"border-1 border-round-sm border-300 border-round-md m-2\">\n @if (selectedItems().length <= 0){\n <table-caption\n [columns]=\"columns\"\n [tableConfiguration]=\"tableConfiguration\"\n [selectedItems]=\"selectedItems()\"\n (applyFiltersEvent)=\"applyFilters($event)\"\n (applyColumnsEvent)=\"applyColumns($event)\"\n (searchChange)=\"onSearch($event)\"\n (actionClick)=\"handleActionClick($event)\"\n >\n </table-caption>\n } @else {\n <div\n style=\"min-height: 40px; padding: 8px\"\n class=\"flex justify-content-between align-items-center border-bottom-1 border-300 pl-5 pr-5 text-sm text-500\"\n >\n <span>{{ selectedItems().length }} items selected</span>\n <div>\n <ng-container *ngFor=\"let action of tableConfiguration.bulkActions\">\n <phoenix-phoenix-data-table-action\n [actionConfig]=\"action\"\n [selectedData]=\"selectedItems\"\n (actionClick)=\"actionClick.emit({ action, selectedItems })\"\n ></phoenix-phoenix-data-table-action>\n </ng-container>\n\n <button\n class=\"p-button p-button-text p-button-plain\"\n (click)=\"selectedItems.set([])\"\n aria-label=\"Clear Selection\"\n >\n <i class=\"pi pi-times\"></i>\n </button>\n </div>\n </div>\n }\n\n <p-table\n [columns]=\"selectedColumns()\"\n [value]=\"tableDataSignal()\"\n [size]=\"'small'\"\n scrollable=\"true\"\n [scrollHeight]=\"tableConfiguration.scrollHeight\"\n [virtualScroll]=\"true\"\n [virtualScrollItemSize]=\"50\"\n [rows]=\"100\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords()\"\n (onLazyLoad)=\"loadLazyData($event)\"\n [selection]=\"selectedItems()\"\n (selectionChange)=\"onSelectionChange($event)\"\n [sortMode]=\"'multiple'\"\n [size]=\"'small'\"\n [resizableColumns]=\"true\"\n columnResizeMode=\"expand\"\n >\n <ng-template #header let-columns>\n <tr style=\"height: 40px\" class=\"dt-header\">\n <ng-container [ngSwitch]=\"tableConfiguration.selectionType\">\n <th class=\"custom-th\" *ngSwitchCase=\"selectionTypeEnum.CHECKBOX\">\n <p-tableHeaderCheckbox\n [attr.data-cy]=\"'table-header-checkbox'\"\n ></p-tableHeaderCheckbox>\n </th>\n <th\n class=\"custom-th\"\n *ngSwitchCase=\"selectionTypeEnum.RADIO_BTN\"\n ></th>\n </ng-container>\n <th\n pResizableColumn\n class=\"custom-th font-bold\"\n *ngFor=\"let col of columns\"\n [pSortableColumn]=\"col.field\"\n >\n {{ col.header | translate }}\n <p-sortIcon [field]=\"col.field\"></p-sortIcon>\n </th>\n <!-- create empty th placeholders for actions -->\n <th class=\"custom-th\"></th>\n </tr>\n </ng-template>\n\n <ng-template\n #body\n let-rowData\n let-columns=\"columns\"\n let-rowIndex=\"rowIndex\"\n >\n <tr>\n <ng-container [ngSwitch]=\"tableConfiguration.selectionType\">\n <td class=\"w-2rem\" *ngSwitchCase=\"selectionTypeEnum.CHECKBOX\">\n <p-tableCheckbox\n [disabled]=\"\n rowData?.canSelect !== undefined ? !rowData.canSelect : false\n \"\n [value]=\"rowData\"\n ></p-tableCheckbox>\n </td>\n <td *ngSwitchCase=\"selectionTypeEnum.RADIO_BTN\">\n <p-tableRadioButton [value]=\"rowData\"></p-tableRadioButton>\n </td>\n </ng-container>\n <td\n *ngFor=\"let col of columns; let i = index\"\n (click)=\"\n i < 2 && tableConfiguration.hasCellClick\n ? onRowClick($event, rowData)\n : null\n \"\n [ngClass]=\"{\n 'text-blue-500 underline cursor-pointer':\n i < 2 && tableConfiguration.hasCellClick\n }\"\n >\n <ng-container [ngSwitch]=\"col.columnType\">\n <!-- TAG case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.TAG\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <p-tag\n styleClass=\"custom-tag\"\n [style]=\"{\n 'background-color': rowData[col.field + 'Color'] || '#ccc',\n \n }\"\n [value]=\"rowData[col.field]?.name || rowData[col.field]\"\n >\n </p-tag>\n </ng-container>\n </ng-container>\n\n <!-- PERSON case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.PERSON\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <p-avatar\n [label]=\"(rowData[col.field] | cell : col)?.avatar\"\n class=\"mr-1\"\n [style]=\"{ 'background-color': '#9c27b0', color: '#ffffff' }\"\n shape=\"circle\"\n >\n </p-avatar>\n {{ (rowData[col.field] | cell : col)?.name }}\n </ng-container>\n </ng-container>\n\n <!-- LIST case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.LIST\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <ul\n *ngFor=\"let item of rowData[col.field]\"\n [attr.data-cy]=\"\n 'table-cell-' + (columnTypeEnum.LIST | lowercase)\n \"\n >\n <li>{{ item.name }}</li>\n </ul>\n </ng-container>\n </ng-container>\n\n <!-- DEFAULT case -->\n <ng-container *ngSwitchDefault>\n <span\n [innerHTML]=\"rowData[col.field] | cell : col : dateFormat\"\n ></span>\n </ng-container>\n </ng-container>\n </td>\n\n <td class=\"p-0\">\n <ng-container *ngFor=\"let action of tableConfiguration.rowActions\">\n <phoenix-phoenix-data-table-action\n [actionConfig]=\"action\"\n [rowData]=\"rowData\"\n (actionClick)=\"handleActionClick({ action, rowData })\"\n ></phoenix-phoenix-data-table-action\n ></ng-container>\n </td>\n </tr>\n </ng-template>\n\n <ng-template #emptyCell> -- </ng-template>\n\n <ng-template pTemplate=\"loadingbody\" let-columns>\n <tr style=\"height: 46px\">\n <td *ngFor=\"let col of columns; let even = even\">\n <tr>\n <td *ngFor=\"let col of columns; let even = even\">\n <p-skeleton\n [ngStyle]=\"{\n width: '60%',\n }\"\n ></p-skeleton>\n </td>\n\n <td>\n <p-skeleton\n [ngStyle]=\"{\n width: '20%',\n }\"\n ></p-skeleton>\n </td>\n </tr>\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"emptymessage\">\n <td class=\"p-2\" colspan=\"100\">\n <div class=\"flex align-items-center\">\n <i class=\"pi pi-info-circle mr-2\"></i>\n {{ \"NO_RESULTS_FOUND\" | translate }}\n </div>\n </td>\n </ng-template>\n </p-table>\n <div class=\"border-top-1 border-300 pl-2 p-1 text-sm text-500\">\n Total records: {{ tableDataSignal().length }}\n </div>\n</div>\n", styles: [".custom-th{background-color:var(--surface-100)!important}.dt-header th:not(:last-child){border-right:1px solid #e4e4e4!important}:is() .p-avatar{border-radius:50%!important}::ng-deep .p-paginator button{scale:.7}::ng-deep .p-paginator-rpp-options{scale:.7}::ng-deep .p-datatable .p-datatable-header{border-radius:10px 10px 0 0}::ng-deep .p-tag{font-weight:400!important;font-size:.875rem!important}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1$1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "pipe", type: i1$1.LowerCasePipe, name: "lowercase" }, { kind: "ngmodule", type: TableModule }, { kind: "component", type: i2$3.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "size", "showGridlines", "stripedRows", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "virtualRowHeight", "selectAll"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$4.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$3.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "directive", type: i2$3.ResizableColumn, selector: "[pResizableColumn]", inputs: ["pResizableColumnDisabled"] }, { kind: "component", type: i2$3.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i2$3.TableRadioButton, selector: "p-tableRadioButton", inputs: ["disabled", "value", "index", "inputId", "name", "ariaLabel"] }, { kind: "component", type: i2$3.TableCheckbox, selector: "p-tableCheckbox", inputs: ["disabled", "value", "index", "inputId", "name", "required", "ariaLabel"] }, { kind: "component", type: i2$3.TableHeaderCheckbox, selector: "p-tableHeaderCheckbox", inputs: ["disabled", "inputId", "name", "ariaLabel"] }, { kind: "component", type: TableCaptionComponent, selector: "table-caption", inputs: ["tableConfiguration", "columns", "searchQuery", "selectedItems"], outputs: ["applyFiltersEvent", "applyColumnsEvent", "searchChange", "actionClick"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "component", type: PhoenixDataTableActionComponent, selector: "phoenix-phoenix-data-table-action", inputs: ["actionConfig", "rowData", "selectedData"], outputs: ["actionClick"] }, { kind: "ngmodule", type: TagModule }, { kind: "component", type: i7.Tag, selector: "p-tag", inputs: ["style", "styleClass", "severity", "value", "icon", "rounded"] }, { kind: "ngmodule", type: AvatarModule }, { kind: "component", type: i6.Avatar, selector: "p-avatar", inputs: ["label", "icon", "image", "size", "shape", "style", "styleClass", "ariaLabel", "ariaLabelledBy"], outputs: ["onImageError"] }, { kind: "ngmodule", type: TooltipModule }, { kind: "pipe", type: TableCellPipe, name: "cell" }, { kind: "ngmodule", type: SkeletonModule }, { kind: "component", type: i9.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }] });
1648
1652
  }
1649
1653
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: TableComponent, decorators: [{
1650
1654
  type: Component,
@@ -1658,8 +1662,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImpor
1658
1662
  AvatarModule,
1659
1663
  TooltipModule,
1660
1664
  TableCellPipe,
1661
- SkeletonModule
1662
- ], template: "<div class=\"border-1 border-round-sm border-300 border-round-md m-2\">\n @if (selectedItems().length <= 0){\n <table-caption\n [columns]=\"columns\"\n [tableConfiguration]=\"tableConfiguration\"\n [selectedItems]=\"selectedItems()\"\n (applyFiltersEvent)=\"applyFilters($event)\"\n (applyColumnsEvent)=\"applyColumns($event)\"\n (searchChange)=\"onSearch($event)\"\n (actionClick)=\"handleActionClick($event)\"\n >\n </table-caption>\n } @else {\n <div\n style=\"min-height: 40px; padding: 8px\"\n class=\"flex justify-content-between align-items-center border-bottom-1 border-300 pl-5 pr-5 text-sm text-500\"\n >\n <span>{{ selectedItems().length }} items selected</span>\n <div>\n <ng-container *ngFor=\"let action of tableConfiguration.bulkActions\">\n <phoenix-phoenix-data-table-action\n [actionConfig]=\"action\"\n [selectedData]=\"selectedItems\"\n (actionClick)=\"actionClick.emit({ action, selectedItems })\"\n ></phoenix-phoenix-data-table-action>\n </ng-container>\n\n <button\n class=\"p-button p-button-text p-button-plain\"\n (click)=\"selectedItems.set([])\"\n aria-label=\"Clear Selection\"\n >\n <i class=\"pi pi-times\"></i>\n </button>\n </div>\n </div>\n }\n\n <p-table\n [columns]=\"selectedColumns()\"\n [value]=\"tableDataSignal()\"\n [size]=\"'small'\"\n scrollable=\"true\"\n [scrollHeight]=\"tableConfiguration.scrollHeight\"\n [virtualScroll]=\"true\"\n [virtualScrollItemSize]=\"50\"\n [rows]=\"100\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords()\"\n (onLazyLoad)=\"loadLazyData($event)\"\n [selection]=\"selectedItems()\"\n (selectionChange)=\"onSelectionChange($event)\"\n [sortMode]=\"'multiple'\"\n [size]=\"'small'\"\n [resizableColumns]=\"true\"\n columnResizeMode=\"expand\"\n >\n <ng-template #header let-columns>\n <tr style=\"height: 40px\" class=\"dt-header\">\n <th class=\"custom-th\" style=\"width: 4rem\"><p-tableHeaderCheckbox /></th>\n <th\n pResizableColumn\n class=\"custom-th font-bold\"\n *ngFor=\"let col of columns\"\n [pSortableColumn]=\"col.field\"\n >\n {{ col.header | translate }}\n <p-sortIcon [field]=\"col.field\"></p-sortIcon>\n </th>\n <!-- create empty th placeholders for actions -->\n <th class=\"custom-th\"></th>\n </tr>\n </ng-template>\n\n <ng-template\n #body\n let-rowData\n let-columns=\"columns\"\n let-rowIndex=\"rowIndex\"\n >\n <tr>\n <td>\n <p-tableCheckbox [value]=\"rowData\" />\n </td>\n <td\n *ngFor=\"let col of columns; let i = index\"\n (click)=\"\n i < 2 && tableConfiguration.hasCellClick\n ? onRowClick($event, rowData)\n : null\n \"\n [ngClass]=\"{\n 'text-blue-500 underline cursor-pointer':\n i < 2 && tableConfiguration.hasCellClick\n }\"\n >\n <ng-container [ngSwitch]=\"col.columnType\">\n <!-- TAG case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.TAG\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <p-tag\n styleClass=\"custom-tag\"\n [style]=\"{\n 'background-color': rowData[col.field + 'Color'] || '#ccc',\n \n }\"\n [value]=\"rowData[col.field]?.name || rowData[col.field]\"\n >\n </p-tag>\n </ng-container>\n </ng-container>\n\n <!-- PERSON case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.PERSON\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <p-avatar\n [label]=\"(rowData[col.field] | cell : col)?.avatar\"\n class=\"mr-1\"\n [style]=\"{ 'background-color': '#9c27b0', color: '#ffffff' }\"\n shape=\"circle\"\n >\n </p-avatar>\n {{ (rowData[col.field] | cell : col)?.name }}\n </ng-container>\n </ng-container>\n\n <!-- LIST case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.LIST\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <ul\n *ngFor=\"let item of rowData[col.field]\"\n [attr.data-cy]=\"\n 'table-cell-' + (columnTypeEnum.LIST | lowercase)\n \"\n >\n <li>{{ item.name }}</li>\n </ul>\n </ng-container>\n </ng-container>\n\n <!-- DEFAULT case -->\n <ng-container *ngSwitchDefault>\n <span\n [innerHTML]=\"rowData[col.field] | cell : col : dateFormat\"\n ></span>\n </ng-container>\n </ng-container>\n </td>\n\n <td class=\"p-0\">\n <ng-container *ngFor=\"let action of tableConfiguration.rowActions\">\n <phoenix-phoenix-data-table-action\n [actionConfig]=\"action\"\n [rowData]=\"rowData\"\n (actionClick)=\"handleActionClick({ action, rowData })\"\n ></phoenix-phoenix-data-table-action\n ></ng-container>\n </td>\n </tr>\n </ng-template>\n\n <ng-template #emptyCell> -- </ng-template>\n\n <ng-template pTemplate=\"loadingbody\" let-columns>\n <tr style=\"height: 46px\">\n <td *ngFor=\"let col of columns; let even = even\">\n <tr>\n <td *ngFor=\"let col of columns; let even = even\">\n <p-skeleton\n [ngStyle]=\"{\n width: '60%',\n }\"\n ></p-skeleton>\n </td>\n\n <td>\n <p-skeleton\n [ngStyle]=\"{\n width: '20%',\n }\"\n ></p-skeleton>\n </td>\n </tr>\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"emptymessage\">\n <td class=\"p-2\" colspan=\"100\">\n <div class=\"flex align-items-center\">\n <i class=\"pi pi-info-circle mr-2\"></i>\n {{ \"NO_RESULTS_FOUND\" | translate }}\n </div>\n </td>\n </ng-template>\n </p-table>\n <div class=\"border-top-1 border-300 pl-2 p-1 text-sm text-500\">\n Total records: {{ tableDataSignal().length }}\n </div>\n</div>\n", styles: [".custom-th{background-color:var(--surface-100)!important}.dt-header th:not(:last-child){border-right:1px solid #e4e4e4!important}:is() .p-avatar{border-radius:50%!important}::ng-deep .p-paginator button{scale:.7}::ng-deep .p-paginator-rpp-options{scale:.7}::ng-deep .p-datatable .p-datatable-header{border-radius:10px 10px 0 0}::ng-deep .p-tag{font-weight:400!important;font-size:.875rem!important}\n"] }]
1665
+ SkeletonModule,
1666
+ ], template: "<div class=\"border-1 border-round-sm border-300 border-round-md m-2\">\n @if (selectedItems().length <= 0){\n <table-caption\n [columns]=\"columns\"\n [tableConfiguration]=\"tableConfiguration\"\n [selectedItems]=\"selectedItems()\"\n (applyFiltersEvent)=\"applyFilters($event)\"\n (applyColumnsEvent)=\"applyColumns($event)\"\n (searchChange)=\"onSearch($event)\"\n (actionClick)=\"handleActionClick($event)\"\n >\n </table-caption>\n } @else {\n <div\n style=\"min-height: 40px; padding: 8px\"\n class=\"flex justify-content-between align-items-center border-bottom-1 border-300 pl-5 pr-5 text-sm text-500\"\n >\n <span>{{ selectedItems().length }} items selected</span>\n <div>\n <ng-container *ngFor=\"let action of tableConfiguration.bulkActions\">\n <phoenix-phoenix-data-table-action\n [actionConfig]=\"action\"\n [selectedData]=\"selectedItems\"\n (actionClick)=\"actionClick.emit({ action, selectedItems })\"\n ></phoenix-phoenix-data-table-action>\n </ng-container>\n\n <button\n class=\"p-button p-button-text p-button-plain\"\n (click)=\"selectedItems.set([])\"\n aria-label=\"Clear Selection\"\n >\n <i class=\"pi pi-times\"></i>\n </button>\n </div>\n </div>\n }\n\n <p-table\n [columns]=\"selectedColumns()\"\n [value]=\"tableDataSignal()\"\n [size]=\"'small'\"\n scrollable=\"true\"\n [scrollHeight]=\"tableConfiguration.scrollHeight\"\n [virtualScroll]=\"true\"\n [virtualScrollItemSize]=\"50\"\n [rows]=\"100\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords()\"\n (onLazyLoad)=\"loadLazyData($event)\"\n [selection]=\"selectedItems()\"\n (selectionChange)=\"onSelectionChange($event)\"\n [sortMode]=\"'multiple'\"\n [size]=\"'small'\"\n [resizableColumns]=\"true\"\n columnResizeMode=\"expand\"\n >\n <ng-template #header let-columns>\n <tr style=\"height: 40px\" class=\"dt-header\">\n <ng-container [ngSwitch]=\"tableConfiguration.selectionType\">\n <th class=\"custom-th\" *ngSwitchCase=\"selectionTypeEnum.CHECKBOX\">\n <p-tableHeaderCheckbox\n [attr.data-cy]=\"'table-header-checkbox'\"\n ></p-tableHeaderCheckbox>\n </th>\n <th\n class=\"custom-th\"\n *ngSwitchCase=\"selectionTypeEnum.RADIO_BTN\"\n ></th>\n </ng-container>\n <th\n pResizableColumn\n class=\"custom-th font-bold\"\n *ngFor=\"let col of columns\"\n [pSortableColumn]=\"col.field\"\n >\n {{ col.header | translate }}\n <p-sortIcon [field]=\"col.field\"></p-sortIcon>\n </th>\n <!-- create empty th placeholders for actions -->\n <th class=\"custom-th\"></th>\n </tr>\n </ng-template>\n\n <ng-template\n #body\n let-rowData\n let-columns=\"columns\"\n let-rowIndex=\"rowIndex\"\n >\n <tr>\n <ng-container [ngSwitch]=\"tableConfiguration.selectionType\">\n <td class=\"w-2rem\" *ngSwitchCase=\"selectionTypeEnum.CHECKBOX\">\n <p-tableCheckbox\n [disabled]=\"\n rowData?.canSelect !== undefined ? !rowData.canSelect : false\n \"\n [value]=\"rowData\"\n ></p-tableCheckbox>\n </td>\n <td *ngSwitchCase=\"selectionTypeEnum.RADIO_BTN\">\n <p-tableRadioButton [value]=\"rowData\"></p-tableRadioButton>\n </td>\n </ng-container>\n <td\n *ngFor=\"let col of columns; let i = index\"\n (click)=\"\n i < 2 && tableConfiguration.hasCellClick\n ? onRowClick($event, rowData)\n : null\n \"\n [ngClass]=\"{\n 'text-blue-500 underline cursor-pointer':\n i < 2 && tableConfiguration.hasCellClick\n }\"\n >\n <ng-container [ngSwitch]=\"col.columnType\">\n <!-- TAG case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.TAG\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <p-tag\n styleClass=\"custom-tag\"\n [style]=\"{\n 'background-color': rowData[col.field + 'Color'] || '#ccc',\n \n }\"\n [value]=\"rowData[col.field]?.name || rowData[col.field]\"\n >\n </p-tag>\n </ng-container>\n </ng-container>\n\n <!-- PERSON case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.PERSON\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <p-avatar\n [label]=\"(rowData[col.field] | cell : col)?.avatar\"\n class=\"mr-1\"\n [style]=\"{ 'background-color': '#9c27b0', color: '#ffffff' }\"\n shape=\"circle\"\n >\n </p-avatar>\n {{ (rowData[col.field] | cell : col)?.name }}\n </ng-container>\n </ng-container>\n\n <!-- LIST case -->\n <ng-container *ngSwitchCase=\"columnTypeEnum.LIST\">\n <ng-container *ngIf=\"rowData[col.field]; else emptyCell\">\n <ul\n *ngFor=\"let item of rowData[col.field]\"\n [attr.data-cy]=\"\n 'table-cell-' + (columnTypeEnum.LIST | lowercase)\n \"\n >\n <li>{{ item.name }}</li>\n </ul>\n </ng-container>\n </ng-container>\n\n <!-- DEFAULT case -->\n <ng-container *ngSwitchDefault>\n <span\n [innerHTML]=\"rowData[col.field] | cell : col : dateFormat\"\n ></span>\n </ng-container>\n </ng-container>\n </td>\n\n <td class=\"p-0\">\n <ng-container *ngFor=\"let action of tableConfiguration.rowActions\">\n <phoenix-phoenix-data-table-action\n [actionConfig]=\"action\"\n [rowData]=\"rowData\"\n (actionClick)=\"handleActionClick({ action, rowData })\"\n ></phoenix-phoenix-data-table-action\n ></ng-container>\n </td>\n </tr>\n </ng-template>\n\n <ng-template #emptyCell> -- </ng-template>\n\n <ng-template pTemplate=\"loadingbody\" let-columns>\n <tr style=\"height: 46px\">\n <td *ngFor=\"let col of columns; let even = even\">\n <tr>\n <td *ngFor=\"let col of columns; let even = even\">\n <p-skeleton\n [ngStyle]=\"{\n width: '60%',\n }\"\n ></p-skeleton>\n </td>\n\n <td>\n <p-skeleton\n [ngStyle]=\"{\n width: '20%',\n }\"\n ></p-skeleton>\n </td>\n </tr>\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"emptymessage\">\n <td class=\"p-2\" colspan=\"100\">\n <div class=\"flex align-items-center\">\n <i class=\"pi pi-info-circle mr-2\"></i>\n {{ \"NO_RESULTS_FOUND\" | translate }}\n </div>\n </td>\n </ng-template>\n </p-table>\n <div class=\"border-top-1 border-300 pl-2 p-1 text-sm text-500\">\n Total records: {{ tableDataSignal().length }}\n </div>\n</div>\n", styles: [".custom-th{background-color:var(--surface-100)!important}.dt-header th:not(:last-child){border-right:1px solid #e4e4e4!important}:is() .p-avatar{border-radius:50%!important}::ng-deep .p-paginator button{scale:.7}::ng-deep .p-paginator-rpp-options{scale:.7}::ng-deep .p-datatable .p-datatable-header{border-radius:10px 10px 0 0}::ng-deep .p-tag{font-weight:400!important;font-size:.875rem!important}\n"] }]
1663
1667
  }], ctorParameters: () => [], propDecorators: { data: [{
1664
1668
  type: Input
1665
1669
  }], columns: [{
@@ -2051,6 +2055,110 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImpor
2051
2055
  type: Input
2052
2056
  }] } });
2053
2057
 
2058
+ class ActionsComponent {
2059
+ actions;
2060
+ actionClick = new EventEmitter();
2061
+ onActionClick(actionId) {
2062
+ this.actionClick.emit(actionId);
2063
+ }
2064
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ActionsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2065
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.4", type: ActionsComponent, isStandalone: true, selector: "pho-actions", inputs: { actions: "actions" }, outputs: { actionClick: "actionClick" }, ngImport: i0, template: "<div class=\"flex gap-2\">\n <ng-container *ngFor=\"let action of actions\">\n <p-button\n *ngIf=\"action.visible !== false\"\n [label]=\"action.label\"\n [icon]=\"action.icon || ''\"\n [styleClass]=\"action.class || ''\"\n [severity]=\"action.severity || 'primary'\"\n [disabled]=\"action.disabled || false\"\n [loading]=\"action.loading || false\"\n [id]=\"action.id\"\n (onClick)=\"onActionClick(action.actionId)\"\n ></p-button>\n </ng-container>\n</div>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "component", type: i3.Button, selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "raised", "rounded", "text", "plain", "severity", "outlined", "link", "tabindex", "size", "variant", "style", "styleClass", "badgeClass", "badgeSeverity", "ariaLabel", "autofocus", "fluid", "buttonProps"], outputs: ["onClick", "onFocus", "onBlur"] }] });
2066
+ }
2067
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ActionsComponent, decorators: [{
2068
+ type: Component,
2069
+ args: [{ selector: 'pho-actions', imports: [CommonModule, ButtonModule], template: "<div class=\"flex gap-2\">\n <ng-container *ngFor=\"let action of actions\">\n <p-button\n *ngIf=\"action.visible !== false\"\n [label]=\"action.label\"\n [icon]=\"action.icon || ''\"\n [styleClass]=\"action.class || ''\"\n [severity]=\"action.severity || 'primary'\"\n [disabled]=\"action.disabled || false\"\n [loading]=\"action.loading || false\"\n [id]=\"action.id\"\n (onClick)=\"onActionClick(action.actionId)\"\n ></p-button>\n </ng-container>\n</div>\n" }]
2070
+ }], propDecorators: { actions: [{
2071
+ type: Input,
2072
+ args: ['actions']
2073
+ }], actionClick: [{
2074
+ type: Output
2075
+ }] } });
2076
+
2077
+ class ObjectItemDialogComponent {
2078
+ ref;
2079
+ config;
2080
+ table;
2081
+ employee;
2082
+ selectedEmployee;
2083
+ employees;
2084
+ columns;
2085
+ disableButton = true;
2086
+ tableData = [];
2087
+ constructor(ref, config) {
2088
+ this.ref = ref;
2089
+ this.config = config;
2090
+ this.columns = [
2091
+ {
2092
+ field: 'name',
2093
+ header: 'Name',
2094
+ columnType: tableColumnType.TEXT,
2095
+ },
2096
+ {
2097
+ field: 'function',
2098
+ header: 'Function',
2099
+ columnType: tableColumnType.TEXT,
2100
+ },
2101
+ {
2102
+ field: 'phone',
2103
+ header: 'Phone',
2104
+ columnType: tableColumnType.TEXT,
2105
+ },
2106
+ {
2107
+ field: 'email',
2108
+ header: 'Email',
2109
+ columnType: tableColumnType.TEXT,
2110
+ },
2111
+ ];
2112
+ }
2113
+ ngOnInit() {
2114
+ this.tableData = this.config.data.tableData;
2115
+ }
2116
+ actions = [
2117
+ {
2118
+ actionId: 'save',
2119
+ label: 'Assign',
2120
+ icon: 'pi pi-check',
2121
+ severity: 'primary',
2122
+ },
2123
+ {
2124
+ actionId: 'cancel',
2125
+ label: 'Cancel',
2126
+ severity: 'secondary',
2127
+ },
2128
+ ];
2129
+ actionClick(key) {
2130
+ if (key === 'save') {
2131
+ this.ref.close(this.table.selectedItems());
2132
+ }
2133
+ else {
2134
+ this.ref.close();
2135
+ }
2136
+ }
2137
+ tableConfiguration = {
2138
+ lazy: false,
2139
+ scrollHeight: '400px',
2140
+ key: 'asd',
2141
+ rows: 20,
2142
+ selectionType: tableSelectionType.RADIO_BTN,
2143
+ };
2144
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ObjectItemDialogComponent, deps: [{ token: i1$3.DynamicDialogRef }, { token: i1$3.DynamicDialogConfig }], target: i0.ɵɵFactoryTarget.Component });
2145
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.4", type: ObjectItemDialogComponent, isStandalone: true, selector: "phoenix-object-item-dialog", viewQueries: [{ propertyName: "table", first: true, predicate: ["table"], descendants: true }], ngImport: i0, template: "<phoenix-table\n #table\n [data]=\"tableData\"\n [columns]=\"columns\"\n [tableConfiguration]=\"tableConfiguration\"\n>\n</phoenix-table>\n<div class=\"absolute bottom-0 right-0 p-4\">\n <pho-actions\n (actionClick)=\"actionClick($event)\"\n [actions]=\"actions\"\n ></pho-actions>\n</div>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: TranslateModule }, { kind: "ngmodule", type: TableModule }, { kind: "ngmodule", type: TooltipModule }, { kind: "ngmodule", type: CommonModule }, { kind: "component", type: TableComponent, selector: "phoenix-table", inputs: ["data", "columns", "tableConfiguration"], outputs: ["actionClick", "rowSelection"] }, { kind: "component", type: ActionsComponent, selector: "pho-actions", inputs: ["actions"], outputs: ["actionClick"] }] });
2146
+ }
2147
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ObjectItemDialogComponent, decorators: [{
2148
+ type: Component,
2149
+ args: [{ selector: 'phoenix-object-item-dialog', standalone: true, imports: [
2150
+ TranslateModule,
2151
+ TableModule,
2152
+ TooltipModule,
2153
+ CommonModule,
2154
+ TableComponent,
2155
+ ActionsComponent,
2156
+ ], template: "<phoenix-table\n #table\n [data]=\"tableData\"\n [columns]=\"columns\"\n [tableConfiguration]=\"tableConfiguration\"\n>\n</phoenix-table>\n<div class=\"absolute bottom-0 right-0 p-4\">\n <pho-actions\n (actionClick)=\"actionClick($event)\"\n [actions]=\"actions\"\n ></pho-actions>\n</div>\n" }]
2157
+ }], ctorParameters: () => [{ type: i1$3.DynamicDialogRef }, { type: i1$3.DynamicDialogConfig }], propDecorators: { table: [{
2158
+ type: ViewChild,
2159
+ args: ['table']
2160
+ }] } });
2161
+
2054
2162
  class MetaAssignResponsibleComponent {
2055
2163
  control;
2056
2164
  parentForm;
@@ -2070,27 +2178,31 @@ class MetaAssignResponsibleComponent {
2070
2178
  }
2071
2179
  // private phoenixDialog = inject(PhoenixDialogService);
2072
2180
  translateService = inject(TranslateService);
2181
+ dialogService = inject(DialogService);
2073
2182
  person;
2074
2183
  clear() {
2075
2184
  this.parentForm.controls[this.control.configuration.key].setValue(null);
2076
2185
  }
2077
2186
  assignResponsible() {
2078
- // const ref = this.phoenixDialog.initDialog(
2079
- // ObjectItemDialogComponent,
2080
- // { appSource: this.control.configuration.app },
2081
- // this.translateService.instant('COMMON.LIST_OF_RESPONSIBLE_PERSONS'),
2082
- // 'large',
2083
- // '',
2084
- // true
2085
- // );
2086
- // ref.onClose.subscribe((response: Assignee) => {
2087
- // if (response) {
2088
- // this.person = response;
2089
- // this.parentForm.controls[this.control.configuration.key].setValue(
2090
- // response
2091
- // );
2092
- // }
2093
- // });
2187
+ console.log(this.control);
2188
+ const ref = this.dialogService.open(ObjectItemDialogComponent, {
2189
+ header: 'Assign Responsible',
2190
+ width: '700px',
2191
+ height: '400px',
2192
+ modal: true,
2193
+ data: {
2194
+ tableData: this.control.configuration.items,
2195
+ },
2196
+ contentStyle: { overflow: 'auto' },
2197
+ draggable: true,
2198
+ closable: true,
2199
+ });
2200
+ ref.onClose.subscribe((response) => {
2201
+ if (response) {
2202
+ this.person = response;
2203
+ this.parentForm.controls[this.control.configuration.key].setValue(response);
2204
+ }
2205
+ });
2094
2206
  }
2095
2207
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: MetaAssignResponsibleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2096
2208
  static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.4", type: MetaAssignResponsibleComponent, isStandalone: true, selector: "phoenix-meta-assign-responsible", inputs: { control: "control", parentForm: "parentForm", disable: "disable" }, providers: [
@@ -2596,7 +2708,7 @@ class MetaCalendarComponent extends BaseMetaField {
2596
2708
  [appendTo]="'body'"
2597
2709
  ></p-calendar>
2598
2710
  <phoenix-inline-field-error [ctrl]="ctrl"></phoenix-inline-field-error>
2599
- </div>`, isInline: true, styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: CalendarModule }, { kind: "component", type: i1$3.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "fluid", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: MetaLabelComponent, selector: "phoenix-meta-label", inputs: ["control"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: InlineFieldError, selector: "phoenix-inline-field-error", inputs: ["ctrl"] }] });
2711
+ </div>`, isInline: true, styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: CalendarModule }, { kind: "component", type: i1$4.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "fluid", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: MetaLabelComponent, selector: "phoenix-meta-label", inputs: ["control"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: InlineFieldError, selector: "phoenix-inline-field-error", inputs: ["ctrl"] }] });
2600
2712
  }
2601
2713
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: MetaCalendarComponent, decorators: [{
2602
2714
  type: Component,
@@ -3755,7 +3867,7 @@ class MetaStartDueDateComponent {
3755
3867
  </div>
3756
3868
  <phoenix-inline-field-error [ctrl]="ctrl"></phoenix-inline-field-error>
3757
3869
  </div>
3758
- `, isInline: true, styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: CalendarModule }, { kind: "component", type: i1$3.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "fluid", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: InlineFieldError, selector: "phoenix-inline-field-error", inputs: ["ctrl"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: MetaLabelComponent, selector: "phoenix-meta-label", inputs: ["control"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }] });
3870
+ `, isInline: true, styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: CalendarModule }, { kind: "component", type: i1$4.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "fluid", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: InlineFieldError, selector: "phoenix-inline-field-error", inputs: ["ctrl"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: MetaLabelComponent, selector: "phoenix-meta-label", inputs: ["control"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }] });
3759
3871
  }
3760
3872
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: MetaStartDueDateComponent, decorators: [{
3761
3873
  type: Component,
@@ -4514,7 +4626,7 @@ class ReadOnlyInputComponent {
4514
4626
  break;
4515
4627
  }
4516
4628
  }
4517
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ReadOnlyInputComponent, deps: [{ token: i1$4.DomSanitizer }, { token: i3$2.TranslateService }, { token: i0.DestroyRef }], target: i0.ɵɵFactoryTarget.Component });
4629
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ReadOnlyInputComponent, deps: [{ token: i1$5.DomSanitizer }, { token: i3$2.TranslateService }, { token: i0.DestroyRef }], target: i0.ɵɵFactoryTarget.Component });
4518
4630
  static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.4", type: ReadOnlyInputComponent, isStandalone: true, selector: "phoenix-read-only-input", inputs: { control: "control", metaform: "metaform" }, ngImport: i0, template: "<phoenix-meta-label [control]=\"control\"></phoenix-meta-label>\n\n<ng-container [ngSwitch]=\"control.configuration.type\">\n <ng-container *ngSwitchCase=\"ctrlType.TEXT_EDITOR\">\n <p-editor\n [attr.data-cy]=\"'editor-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n [readonly]=\"true\"\n [(ngModel)]=\"value\"\n ></p-editor>\n </ng-container>\n <ng-container *ngSwitchCase=\"ctrlType.SWITCH\">\n <p-inputSwitch\n [attr.data-cy]=\"'switch-' + control?.id\"\n *ngIf=\"value?.isBoolean; else fallBack\"\n styleClass=\"mt-2 ml-1 mr-1\"\n [disabled]=\"true\"\n [(ngModel)]=\"value.res\"\n ></p-inputSwitch>\n </ng-container>\n <ng-container *ngSwitchCase=\"ctrlType.DATE\">\n <div\n [attr.data-cy]=\"'date-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n {{ value | date }}\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"ctrlType.CHECKBOX\">\n <p-checkbox\n [attr.data-cy]=\"'checkbox-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n styleClass=\"mt-3\"\n [(ngModel)]=\"value\"\n [binary]=\"true\"\n inputId=\"binary\"\n [disabled]=\"true\"\n ></p-checkbox>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"ctrlType.LINKS_DATA\">\n <div\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2 overflow-y-auto\"\n [attr.data-cy]=\"'link-' + control?.id\"\n >\n <ng-container *ngFor=\"let item of value\">\n <span class=\"m-2 text-sm font-light\">{{ item?.relationLabel }}</span>\n <!-- <ng-container *ngFor=\"let link of item?.objects\">\n <phoenix-serach-card\n [readOnly]=\"true\"\n [data]=\"link\"\n [deleteButton]=\"false\"\n (selectEvent)=\"selectEvent($event)\"\n />\n </ng-container> -->\n </ng-container>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"ctrlType.ASSIGN\">\n <div\n *ngIf=\"value?.name; else fallBack\"\n [attr.data-cy]=\"'number-' + control?.id\"\n >\n <div>\n <p-button [rounded]=\"true\" [text]=\"true\" (onClick)=\"op.toggle($event)\">\n <div class=\"person-wrap\">\n <div class=\"person-avatar\">\n {{ value?.name?.toUpperCase().charAt(0) }}\n </div>\n <div>\n <p\n class=\"white-space-nowrap overflow-hidden text-overflow-ellipsis\"\n >\n {{ value?.name }}\n </p>\n <p\n class=\"white-space-nowrap overflow-hidden text-overflow-ellipsis\"\n >\n {{ value?.function }}\n </p>\n </div>\n </div></p-button\n >\n <p-overlayPanel #op>\n <div>\n <span class=\"block mb-2\">\n <i class=\"pi pi-envelope mr-1 text-500\"></i>\n\n {{ value.email ?? \" --\" }}\n </span>\n <p>\n <i class=\"pi pi-phone mr-1 text-500\"></i\n >{{ value.phone ?? \" --\" }}\n </p>\n </div></p-overlayPanel\n >\n </div>\n\n <!-- <div class=\"person-wrap\">\n <div class=\"person-avatar\">\n {{ value?.name?.toUpperCase().charAt(0) }}\n </div>\n <div class=\"font-semibold text-500\">\n <p>\n {{ value?.name }}\n </p>\n <p>\n {{ value?.function }}\n </p>\n </div>\n </div> -->\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"ctrlType.PASSWORD\">\n <div\n [attr.data-cy]=\"'password-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n <p-password\n class=\"ng-invalid ng-dirty\"\n [disabled]=\"true\"\n [(ngModel)]=\"value\"\n [feedback]=\"false\"\n ></p-password>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"ctrlType.SS_OPTION_OBJECT_BASED\">\n <div\n [attr.data-cy]=\"'SS-OPTION-OBJECT-BASED-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n {{ value.value }}\n </div>\n </ng-container>\n\n <!-- Remove this if necessary - spaces-overview GENERAL form contol -->\n <ng-container *ngSwitchCase=\"ctrlType.SS_OPTION\">\n <div\n [attr.data-cy]=\"'SS-OPTION-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n {{ value | translate }}\n </div>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <div\n [attr.data-cy]=\"'test-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n {{ value }}\n </div>\n </ng-container>\n</ng-container>\n\n<ng-template #fallBack>\n <div\n [attr.data-cy]=\"'test-' + control?.id\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n --\n </div>\n</ng-template>\n\n<!-- <ng-container *ngFor=\"let link of item?.objects\">\n <phoenix-serach-card\n [data]=\"link\"\n (removeButtonEvent)=\"\n onLinkRemove(link.name, item.relationLabelKey)\n \"\n [deleteButton]=\"true\"\n />\n </ng-container> -->\n", styles: [".person-wrap{display:flex;align-items:center;margin-left:-6px}.person-wrap p{margin:0}.person-wrap .person-avatar{display:flex;justify-content:center;align-items:center;width:28px;height:28px;min-width:28px;min-height:28px;margin-right:5px;background-color:#e94260;color:#fff;border-radius:50%;font-size:1rem}.person-wrap .person-name :first-child{font-size:1rem}.person-details{border-top:1px solid #e0e0e0;padding:5px;margin-left:-6px;width:150px}.person-details p{margin:0;display:flex;align-items:center}.person-details i{color:#d75063;padding-right:5px}.person-details .p-editor-container{padding-left:0!important}:host ::ng-deep .p-password .p-password-input{border:none!important}:host ::ng-deep .p-editor-toolbar{display:none!important}:host ::ng-deep .p-editor-container{background:transparent!important;border:0px!important}:host ::ng-deep .p-editor-content.ql-snow{border:0px!important}:host ::ng-deep .p-editor-container .p-editor-content .ql-editor{background:transparent!important}:host ::ng-deep .ql-editor{padding:0;height:100%}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1$1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "pipe", type: i1$1.DatePipe, name: "date" }, { kind: "component", type: MetaLabelComponent, selector: "phoenix-meta-label", inputs: ["control"] }, { kind: "ngmodule", type: InputSwitchModule }, { kind: "component", type: i3$a.InputSwitch, selector: "p-inputSwitch, p-inputswitch", inputs: ["style", "styleClass", "tabindex", "inputId", "name", "disabled", "readonly", "trueValue", "falseValue", "ariaLabel", "ariaLabelledBy", "autofocus"], outputs: ["onChange"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type:
4519
4631
  // SerachCardComponent,
4520
4632
  CheckboxModule }, { kind: "component", type: i11.Checkbox, selector: "p-checkbox, p-checkBox, p-check-box", inputs: ["value", "name", "disabled", "binary", "ariaLabelledBy", "ariaLabel", "tabindex", "inputId", "style", "inputStyle", "styleClass", "inputClass", "indeterminate", "size", "formControl", "checkboxIcon", "readonly", "required", "autofocus", "trueValue", "falseValue", "variant"], outputs: ["onChange", "onFocus", "onBlur"] }, { kind: "ngmodule", type: PasswordModule }, { kind: "component", type: i3$8.Password, selector: "p-password", inputs: ["ariaLabel", "fluid", "ariaLabelledBy", "label", "disabled", "promptLabel", "mediumRegex", "strongRegex", "weakLabel", "mediumLabel", "maxLength", "strongLabel", "inputId", "feedback", "appendTo", "toggleMask", "size", "inputStyleClass", "styleClass", "style", "inputStyle", "showTransitionOptions", "hideTransitionOptions", "autocomplete", "placeholder", "showClear", "autofocus", "variant", "tabindex"], outputs: ["onFocus", "onBlur", "onClear"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: SelectButtonModule }, { kind: "ngmodule", type: EditorModule }, { kind: "component", type: i2$4.Editor, selector: "p-editor", inputs: ["style", "styleClass", "placeholder", "formats", "modules", "bounds", "scrollingContainer", "debug", "readonly"], outputs: ["onInit", "onTextChange", "onSelectionChange"] }, { kind: "ngmodule", type: OverlayPanelModule }, { kind: "component", type: i4$3.OverlayPanel, selector: "p-overlayPanel, p-overlaypanel", inputs: ["ariaLabel", "ariaLabelledBy", "dismissable", "showCloseIcon", "style", "styleClass", "appendTo", "autoZIndex", "ariaCloseLabel", "baseZIndex", "focusOnShow", "showTransitionOptions", "hideTransitionOptions"], outputs: ["onShow", "onHide"] }, { kind: "ngmodule", type: PanelModule }, { kind: "ngmodule", type: ButtonModule }, { kind: "component", type: i3.Button, selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "raised", "rounded", "text", "plain", "severity", "outlined", "link", "tabindex", "size", "variant", "style", "styleClass", "badgeClass", "badgeSeverity", "ariaLabel", "autofocus", "fluid", "buttonProps"], outputs: ["onClick", "onFocus", "onBlur"] }] });
@@ -4536,7 +4648,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImpor
4536
4648
  PanelModule,
4537
4649
  ButtonModule,
4538
4650
  ], template: "<phoenix-meta-label [control]=\"control\"></phoenix-meta-label>\n\n<ng-container [ngSwitch]=\"control.configuration.type\">\n <ng-container *ngSwitchCase=\"ctrlType.TEXT_EDITOR\">\n <p-editor\n [attr.data-cy]=\"'editor-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n [readonly]=\"true\"\n [(ngModel)]=\"value\"\n ></p-editor>\n </ng-container>\n <ng-container *ngSwitchCase=\"ctrlType.SWITCH\">\n <p-inputSwitch\n [attr.data-cy]=\"'switch-' + control?.id\"\n *ngIf=\"value?.isBoolean; else fallBack\"\n styleClass=\"mt-2 ml-1 mr-1\"\n [disabled]=\"true\"\n [(ngModel)]=\"value.res\"\n ></p-inputSwitch>\n </ng-container>\n <ng-container *ngSwitchCase=\"ctrlType.DATE\">\n <div\n [attr.data-cy]=\"'date-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n {{ value | date }}\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"ctrlType.CHECKBOX\">\n <p-checkbox\n [attr.data-cy]=\"'checkbox-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n styleClass=\"mt-3\"\n [(ngModel)]=\"value\"\n [binary]=\"true\"\n inputId=\"binary\"\n [disabled]=\"true\"\n ></p-checkbox>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"ctrlType.LINKS_DATA\">\n <div\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2 overflow-y-auto\"\n [attr.data-cy]=\"'link-' + control?.id\"\n >\n <ng-container *ngFor=\"let item of value\">\n <span class=\"m-2 text-sm font-light\">{{ item?.relationLabel }}</span>\n <!-- <ng-container *ngFor=\"let link of item?.objects\">\n <phoenix-serach-card\n [readOnly]=\"true\"\n [data]=\"link\"\n [deleteButton]=\"false\"\n (selectEvent)=\"selectEvent($event)\"\n />\n </ng-container> -->\n </ng-container>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"ctrlType.ASSIGN\">\n <div\n *ngIf=\"value?.name; else fallBack\"\n [attr.data-cy]=\"'number-' + control?.id\"\n >\n <div>\n <p-button [rounded]=\"true\" [text]=\"true\" (onClick)=\"op.toggle($event)\">\n <div class=\"person-wrap\">\n <div class=\"person-avatar\">\n {{ value?.name?.toUpperCase().charAt(0) }}\n </div>\n <div>\n <p\n class=\"white-space-nowrap overflow-hidden text-overflow-ellipsis\"\n >\n {{ value?.name }}\n </p>\n <p\n class=\"white-space-nowrap overflow-hidden text-overflow-ellipsis\"\n >\n {{ value?.function }}\n </p>\n </div>\n </div></p-button\n >\n <p-overlayPanel #op>\n <div>\n <span class=\"block mb-2\">\n <i class=\"pi pi-envelope mr-1 text-500\"></i>\n\n {{ value.email ?? \" --\" }}\n </span>\n <p>\n <i class=\"pi pi-phone mr-1 text-500\"></i\n >{{ value.phone ?? \" --\" }}\n </p>\n </div></p-overlayPanel\n >\n </div>\n\n <!-- <div class=\"person-wrap\">\n <div class=\"person-avatar\">\n {{ value?.name?.toUpperCase().charAt(0) }}\n </div>\n <div class=\"font-semibold text-500\">\n <p>\n {{ value?.name }}\n </p>\n <p>\n {{ value?.function }}\n </p>\n </div>\n </div> -->\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"ctrlType.PASSWORD\">\n <div\n [attr.data-cy]=\"'password-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n <p-password\n class=\"ng-invalid ng-dirty\"\n [disabled]=\"true\"\n [(ngModel)]=\"value\"\n [feedback]=\"false\"\n ></p-password>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"ctrlType.SS_OPTION_OBJECT_BASED\">\n <div\n [attr.data-cy]=\"'SS-OPTION-OBJECT-BASED-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n {{ value.value }}\n </div>\n </ng-container>\n\n <!-- Remove this if necessary - spaces-overview GENERAL form contol -->\n <ng-container *ngSwitchCase=\"ctrlType.SS_OPTION\">\n <div\n [attr.data-cy]=\"'SS-OPTION-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n {{ value | translate }}\n </div>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <div\n [attr.data-cy]=\"'test-' + control?.id\"\n *ngIf=\"value; else fallBack\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n {{ value }}\n </div>\n </ng-container>\n</ng-container>\n\n<ng-template #fallBack>\n <div\n [attr.data-cy]=\"'test-' + control?.id\"\n class=\"font-semibold text-500 mt-3 mb-2\"\n >\n --\n </div>\n</ng-template>\n\n<!-- <ng-container *ngFor=\"let link of item?.objects\">\n <phoenix-serach-card\n [data]=\"link\"\n (removeButtonEvent)=\"\n onLinkRemove(link.name, item.relationLabelKey)\n \"\n [deleteButton]=\"true\"\n />\n </ng-container> -->\n", styles: [".person-wrap{display:flex;align-items:center;margin-left:-6px}.person-wrap p{margin:0}.person-wrap .person-avatar{display:flex;justify-content:center;align-items:center;width:28px;height:28px;min-width:28px;min-height:28px;margin-right:5px;background-color:#e94260;color:#fff;border-radius:50%;font-size:1rem}.person-wrap .person-name :first-child{font-size:1rem}.person-details{border-top:1px solid #e0e0e0;padding:5px;margin-left:-6px;width:150px}.person-details p{margin:0;display:flex;align-items:center}.person-details i{color:#d75063;padding-right:5px}.person-details .p-editor-container{padding-left:0!important}:host ::ng-deep .p-password .p-password-input{border:none!important}:host ::ng-deep .p-editor-toolbar{display:none!important}:host ::ng-deep .p-editor-container{background:transparent!important;border:0px!important}:host ::ng-deep .p-editor-content.ql-snow{border:0px!important}:host ::ng-deep .p-editor-container .p-editor-content .ql-editor{background:transparent!important}:host ::ng-deep .ql-editor{padding:0;height:100%}\n"] }]
4539
- }], ctorParameters: () => [{ type: i1$4.DomSanitizer }, { type: i3$2.TranslateService }, { type: i0.DestroyRef }], propDecorators: { control: [{
4651
+ }], ctorParameters: () => [{ type: i1$5.DomSanitizer }, { type: i3$2.TranslateService }, { type: i0.DestroyRef }], propDecorators: { control: [{
4540
4652
  type: Input
4541
4653
  }], metaform: [{
4542
4654
  type: Input