@colijnit/corecomponents_v12 259.1.23 → 259.1.25
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/bundles/colijnit-corecomponents_v12.umd.js +22 -8
- package/bundles/colijnit-corecomponents_v12.umd.js.map +1 -1
- package/colijnit-corecomponents_v12.metadata.json +1 -1
- package/esm2015/lib/components/hour-scheduling-expandable/hour-scheduling-expandable.component.js +5 -3
- package/esm2015/lib/components/list-of-values/list-of-values.component.js +58 -55
- package/esm2015/lib/components/simple-grid/simple-grid.component.js +22 -14
- package/esm2015/lib/directives/screen-configuration/screen-configuration.directive.js +2 -2
- package/fesm2015/colijnit-corecomponents_v12.js +83 -70
- package/fesm2015/colijnit-corecomponents_v12.js.map +1 -1
- package/lib/components/list-of-values/list-of-values.component.d.ts +1 -1
- package/lib/components/simple-grid/simple-grid.component.d.ts +2 -1
- package/lib/components/simple-grid/style/_layout.scss +7 -25
- package/package.json +1 -1
- package/colijnit-corecomponents_v12-259.1.23.tgz +0 -0
|
@@ -10395,7 +10395,16 @@
|
|
|
10395
10395
|
this._resetEdit();
|
|
10396
10396
|
this._detectChanges();
|
|
10397
10397
|
};
|
|
10398
|
-
SimpleGridComponent.prototype.removeRow = function () {
|
|
10398
|
+
SimpleGridComponent.prototype.removeRow = function (row) {
|
|
10399
|
+
this.deleteRow.next(row);
|
|
10400
|
+
if (this.currentPage !== 1) {
|
|
10401
|
+
this.currentPage = 1;
|
|
10402
|
+
this.selectedRowIndex = -1;
|
|
10403
|
+
window.scrollTo({ top: 0, behavior: 'smooth' });
|
|
10404
|
+
}
|
|
10405
|
+
this._detectChanges();
|
|
10406
|
+
};
|
|
10407
|
+
SimpleGridComponent.prototype.removeSelectedRow = function () {
|
|
10399
10408
|
var absoluteIndex = this.selectedRowIndex;
|
|
10400
10409
|
if (this.rowsPerPage) {
|
|
10401
10410
|
absoluteIndex = (this.currentPage - 1) * this.rowsPerPage + this.selectedRowIndex;
|
|
@@ -10841,7 +10850,7 @@
|
|
|
10841
10850
|
SimpleGridComponent.decorators = [
|
|
10842
10851
|
{ type: i0.Component, args: [{
|
|
10843
10852
|
selector: 'co-simple-grid',
|
|
10844
|
-
template: "\n <co-grid-toolbar\n *ngIf=\"showToolbar\" [class.right]=\"rightToolbar\"\n [showEdit]=\"showEdit\"\n [showAdd]=\"showAdd\"\n [showDelete]=\"showDelete\"\n [deleteEnabled]=\"selectedRowIndex > -1\"\n (addClick)=\"addNewRow()\"\n (editClick)=\"editRow($event)\"\n (saveClick)=\"validateAndSave()\"\n (cancelClick)=\"cancelEditRow()\"\n (deleteClick)=\"
|
|
10853
|
+
template: "\n <co-grid-toolbar\n *ngIf=\"showToolbar\" [class.right]=\"rightToolbar\"\n [showEdit]=\"showEdit\"\n [showAdd]=\"showAdd\"\n [showDelete]=\"showDelete\"\n [deleteEnabled]=\"selectedRowIndex > -1\"\n (addClick)=\"addNewRow()\"\n (editClick)=\"editRow($event)\"\n (saveClick)=\"validateAndSave()\"\n (cancelClick)=\"cancelEditRow()\"\n (deleteClick)=\"removeSelectedRow()\">\n </co-grid-toolbar>\n\n <table\n id=\"simple-grid-table\"\n class=\"simple-grid-table\"\n [clickOutside]=\"editing\"\n (clickOutside)=\"handleClickOutsideRow()\">\n <colgroup>\n <col\n *ngFor=\"let column of headerColumnsCopy; let index = index\"\n [class.simple-grid-column-auto-fit]=\"column.autoFit\"\n [style.width.px]=\"column.width\"\n [style.min-width.px]=\"MIN_COLUMN_WIDTH\">\n <col\n *ngIf=\"showRowButtons\"\n [class.simple-grid-column-auto-fit]=\"true\"\n [style.min-width.px]=\"MIN_COLUMN_WIDTH\">\n >\n </colgroup>\n <thead>\n <tr>\n <th\n scope=\"col\"\n #headerCell\n class=\"simple-grid-column-header\"\n *ngFor=\"let column of headerColumnsCopy; let index = index\">\n <div\n class=\"simple-grid-column-header-wrapper\"\n [class.resizable]=\"resizable\"\n [class.selected]=\"column.isSelected\"\n [ngClass]=\"column.textAlign ? column.textAlign : defaultTextAlign\">\n <ng-container *ngIf=\"column.headerTemplate; else noHeaderTemplate\">\n <ng-container [ngTemplateOutlet]=\"column.headerTemplate\"></ng-container>\n </ng-container>\n <ng-template #noHeaderTemplate>\n <div\n class=\"simple-grid-column-header-label\"\n [ngClass]=\"column.textAlign ? column.textAlign : defaultTextAlign\"\n [class.with-menu]=\"showGridSettings\"\n [class.with-sort]=\"showColumnSort\"\n [textContent]=\"column.headerText || ' '\" [title]=\"column.headerText\"\n (click)=\"showColumnSort ? sortColumn(column, column.field) : toggleColumnMenu(column)\">\n </div>\n\n <div class=\"sort-column\" *ngIf=\"showColumnSort\">\n <co-button\n (click)=\"sortColumn(column, column?.field)\"\n [iconData]=\"icons.getIcon(Icons.ArrowUpArrowDown)\">\n </co-button>\n </div>\n\n <div class=\"column-menu\" *ngIf=\"column.isSelected\">\n <h3 [textContent]=\"'COLUMN_OPTIONS' | coreLocalize\"></h3>\n <ul>\n <li (click)=\"hideColumn(column)\">Hide Column</li>\n <li (click)=\"sortColumn(column, column.field)\">Sort Column</li>\n </ul>\n </div>\n </ng-template>\n <div\n *ngIf=\"resizable && column.resizable\"\n class=\"simple-grid-column-sizer\"\n (mousedown)=\"handleSizerMouseDown($event, column)\">\n </div>\n </div>\n </th>\n </tr>\n\n <div *ngIf=\"showGridSettings\" class=\"grid-settings\">\n <co-button\n [class.selected]=\"isSettingsMenuOpen\"\n [iconData]=\"icons.getIcon(Icons.CogWheels)\"\n (click)=\"toggleSettingsMenu()\">\n </co-button>\n\n <div class=\"settings-menu\" *ngIf=\"isSettingsMenuOpen\">\n <h3 [textContent]=\"'GRID_OPTIONS' | coreLocalize\"></h3>\n <ul>\n <li (click)=\"exportToExcel()\">Export to Excel</li>\n <li *ngIf=\"headerColumnsCopy.length !== headerColumns.length\" (click)=\"showAllColumns()\">\n Show All Columns\n </li>\n </ul>\n </div>\n </div>\n </thead>\n <tbody\n #dropList cdkDropList cdkDropListOrientation=\"vertical\"\n class=\"simple-grid-drag-drop-list\"\n [cdkDropListDisabled]=\"!dragDropEnabled || editing\"\n [cdkDropListData]=\"data\"\n [cdkDropListEnterPredicate]=\"handleCanDragDrop\"\n (cdkDropListDropped)=\"handleDrop($event)\">\n <co-form class=\"simple-grid-row-form\">\n <tr\n #rowElement\n class=\"simple-grid-row\"\n [class.selected]=\"rowIndex === selectedRowIndex && !editing\" observeVisibility\n [class.disabled]=\"getIsRowDisabled(rowIndex)\"\n [class.editing]=\"rowIndex === editRowIndex\"\n *ngFor=\"let row of (!!rowsPerPage ? (data | paginate: {itemsPerPage: rowsPerPage, currentPage: currentPage}) : data); last as last; let rowIndex = index\"\n cdkDrag\n (click)=\"handleClickRow($event, rowIndex)\" (dblclick)=\"handleDblClickRow($event, rowIndex, row)\"\n (visibilityChange)=\"rowVisible.next(row)\"\n (mouseenter)=\"hoveredRowIndex = rowIndex\"\n (mouseleave)=\"hoveredRowIndex = -1\"\n >\n <ng-container *ngIf=\"isSingleColumnRow(row)\">\n <td class=\"simple-grid-single-column-cell\" [attr.colspan]=\"headerColumnsCopy.length\">\n <co-simple-grid-cell\n [column]=\"columns[singleColumnIndex(row)]\"\n [row]=\"row\"\n [editMode]=\"false\">\n </co-simple-grid-cell>\n </td>\n </ng-container>\n <ng-container *ngIf=\"!isSingleColumnRow(row)\">\n <ng-container *ngFor=\"let column of headerColumnsCopy; let columnIndex = index\">\n <td class=\"simple-grid-column-cell\" *ngIf=\"columnIndex !== singleColumnIndex(row)\">\n <co-simple-grid-cell\n [column]=\"column\"\n [row]=\"row\"\n [editMode]=\"inlineEdit && editing && rowIndex === editRowIndex\"\n [fieldEditMode]=\"editCellIndex === columnIndex && rowIndex === editRowIndex\"\n (cellClick)=\"handleCellClick($event, row, rowIndex, columnIndex)\">\n </co-simple-grid-cell>\n <div *ngIf=\"column.resizable\" class=\"simple-grid-column-sizer-placeholder\"></div>\n </td>\n </ng-container>\n <ng-container *ngIf=\"showRowButtons\">\n <td class=\"icons-container\" [class.show-content]=\"selectedRowIndex === rowIndex || hoveredRowIndex === rowIndex\">\n <ng-container>\n <co-icon class=\"icon-item icon-edit\"\n *ngIf=\"editRowIndex !== rowIndex && inlineEdit\"\n [iconData]=\"icons.getIcon(Icons.PenToSquareSolid)\"\n (click)=\"editRow($event, true, rowIndex); $event.stopPropagation()\"></co-icon>\n <co-icon class=\"icon-item icon-delete\"\n [iconData]=\"icons.getIcon(Icons.TrashBin)\"\n *ngIf=\"(editRowIndex !== rowIndex && showDelete)\"\n (click)=\"removeRow(data[rowIndex])\"></co-icon>\n </ng-container>\n <ng-container *ngIf=\"editing && inlineEdit && (selectedRowIndex === rowIndex || isNewRow) && editRowIndex === rowIndex\">\n <co-button class=\"save-button\"\n [iconData]=\"icons.getIcon(Icons.CheckDuotone)\"\n (click)=\"validateAndSave(); $event.stopPropagation()\"></co-button>\n <co-button class=\"close-button\"\n [iconData]=\"icons.getIcon(Icons.CrossSkinny)\"\n (click)=\"cancelEditRow(); $event.stopPropagation() \"></co-button>\n </ng-container>\n </td>\n </ng-container>\n </ng-container>\n </tr>\n </co-form>\n </tbody>\n </table>\n <co-pagination-bar\n *ngIf=\"data?.length > rowsPerPage\" class=\"pagination-bar\"\n [itemsPerPage]=\"rowsPerPage\"\n [currentPage]=\"currentPage\"\n [totalItems]=\"data.length\"\n [autoHide]=\"true\"\n (previousClick)=\"goToPreviousPage()\"\n (nextClick)=\"goToNextPage()\"\n (pageClick)=\"setCurrentPage($event)\">\n </co-pagination-bar>\n ",
|
|
10845
10854
|
providers: [FormMasterService],
|
|
10846
10855
|
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
10847
10856
|
encapsulation: i0.ViewEncapsulation.None
|
|
@@ -12040,12 +12049,12 @@
|
|
|
12040
12049
|
}
|
|
12041
12050
|
this.selectedModel = model;
|
|
12042
12051
|
};
|
|
12043
|
-
ListOfValuesComponent.prototype.onModelChange = function (
|
|
12052
|
+
ListOfValuesComponent.prototype.onModelChange = function (model) {
|
|
12044
12053
|
var _this = this;
|
|
12045
12054
|
this.isLoading = true;
|
|
12046
12055
|
clearTimeout(this.debounceTimeout);
|
|
12047
12056
|
this.debounceTimeout = setTimeout(function () {
|
|
12048
|
-
_this.applyFilter(
|
|
12057
|
+
_this.applyFilter(model);
|
|
12049
12058
|
}, 300);
|
|
12050
12059
|
};
|
|
12051
12060
|
ListOfValuesComponent.prototype.applyFilter = function (text) {
|
|
@@ -12088,6 +12097,9 @@
|
|
|
12088
12097
|
(((_b = this.filteredCollection) === null || _b === void 0 ? void 0 : _b.length) > 0 && ((_c = this.filterText) === null || _c === void 0 ? void 0 : _c.length) > 2) ? this.openPopup() : this.closePopup();
|
|
12089
12098
|
this.isLoading = false;
|
|
12090
12099
|
this.changeDetector.detectChanges();
|
|
12100
|
+
if (this._lovPopupComponentRef) {
|
|
12101
|
+
this._lovPopupComponentRef.instance.searchTerm = text;
|
|
12102
|
+
}
|
|
12091
12103
|
return [2 /*return*/];
|
|
12092
12104
|
}
|
|
12093
12105
|
});
|
|
@@ -12230,7 +12242,7 @@
|
|
|
12230
12242
|
ListOfValuesComponent.decorators = [
|
|
12231
12243
|
{ type: i0.Component, args: [{
|
|
12232
12244
|
selector: 'co-list-of-values',
|
|
12233
|
-
template: "\n <co-input-text\n *ngIf=\"!largeCollection\"\n aria-haspopup=\"listbox\"\n [attr.aria-expanded]=\"isSelectOpen\"\n aria-controls=\"lov-popup\"\n role=\"combobox\"\n class=\"no-focus-line\"\n overlayParent\n #parentForOverlay=\"overlayParent\"\n type=\"text\"\n [id]=\"label\"\n [model]=\"multiselect ? selectedModels : selectedModel\"\n [placeholder]=\"label\"\n [myFormInputInstance]=\"this\"\n [readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [required]=\"required\"\n [noClickFocus]=\"false\"\n [leftIconData]=\" model && model[optionIcon] ? iconCacheService.getIcon(model[optionIcon]) : leftIconData\"\n [rightIcon]=\"isSelectOpen ? icons.ChevronUpRegular : icons.ChevronDownRegular\"\n [showClearButton]=\"true\"\n [useContent]=\"multiselect\"\n [customHeight]=\"multiselect\"\n [keepFocussed]=\"keepFocussed\"\n (modelChange)=\"handleInputModelChange($event)\"\n (click)=\"openPopup()\"\n (rightIconClick)=\"toggleSelect()\"\n (keydown)=\"handleInputKeyDown($event)\"\n (clearIconClick)=\"clearModel($event)\"\n (blur)=\"checkModel()\">\n <ng-container *ngIf=\"multiselect && showChips\">\n <div class=\"multiselect-chips-wrapper\">\n <div class=\"chips\" *ngFor=\"let chip of model\">\n <span class=\"chips-description\" [textContent]=\"chip[displayField]\"></span>\n <co-icon class=\"remove-chip-icon\" [icon]=\"icons.CrossSkinny\" (click)=\"removeOptionFromModel(chip)\"></co-icon>\n </div>\n </div>\n </ng-container>\n </co-input-text>\n\n <co-input-text\n *ngIf=\"largeCollection\"\n [model]=\"filterText\"\n [placeholder]=\"label\"\n [required]=\"required\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n (modelChange)=\"onModelChange($event)\">\n </co-input-text>\n <div *ngIf=\"isLoading\" class=\"filter-loader\"><span></span></div>\n <input type=\"hidden\" [ngModel]=\"model\">\n ",
|
|
12245
|
+
template: "\n <co-input-text\n *ngIf=\"!largeCollection\"\n aria-haspopup=\"listbox\"\n [attr.aria-expanded]=\"isSelectOpen\"\n aria-controls=\"lov-popup\"\n role=\"combobox\"\n class=\"no-focus-line\"\n overlayParent\n #parentForOverlay=\"overlayParent\"\n type=\"text\"\n [id]=\"label\"\n [model]=\"multiselect ? ((!selectedModels || selectedModels.length === 0) ? null : selectedModels ) : selectedModel\"\n [placeholder]=\"label\"\n [myFormInputInstance]=\"this\"\n [readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [required]=\"required\"\n [noClickFocus]=\"false\"\n [leftIconData]=\" model && model[optionIcon] ? iconCacheService.getIcon(model[optionIcon]) : leftIconData\"\n [rightIcon]=\"isSelectOpen ? icons.ChevronUpRegular : icons.ChevronDownRegular\"\n [showClearButton]=\"true\"\n [useContent]=\"multiselect\"\n [customHeight]=\"multiselect\"\n [keepFocussed]=\"keepFocussed\"\n (modelChange)=\"handleInputModelChange($event)\"\n (click)=\"openPopup()\"\n (rightIconClick)=\"toggleSelect()\"\n (keydown)=\"handleInputKeyDown($event)\"\n (clearIconClick)=\"clearModel($event)\"\n (blur)=\"checkModel()\">\n <ng-container *ngIf=\"multiselect && showChips\">\n <div class=\"multiselect-chips-wrapper\">\n <div class=\"chips\" *ngFor=\"let chip of model\">\n <span class=\"chips-description\" [textContent]=\"chip[displayField]\"></span>\n <co-icon class=\"remove-chip-icon\" [icon]=\"icons.CrossSkinny\" (click)=\"removeOptionFromModel(chip)\"></co-icon>\n </div>\n </div>\n </ng-container>\n </co-input-text>\n\n <co-input-text\n *ngIf=\"largeCollection\"\n [model]=\"filterText\"\n [placeholder]=\"label\"\n [required]=\"required\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n (modelChange)=\"onModelChange($event)\">\n </co-input-text>\n <div *ngIf=\"isLoading\" class=\"filter-loader\"><span></span></div>\n <input type=\"hidden\" [ngModel]=\"(selectedModels && selectedModels.length) || selectedModel ? model : null\">\n ",
|
|
12234
12246
|
providers: [
|
|
12235
12247
|
OverlayService,
|
|
12236
12248
|
{
|
|
@@ -14599,7 +14611,7 @@
|
|
|
14599
14611
|
if (myCfgObj) {
|
|
14600
14612
|
this._setHostVisible(myCfgObj.immediatelyVisible());
|
|
14601
14613
|
if (!this.screenConfigNativeElement) {
|
|
14602
|
-
this.hostComponent.required = myCfgObj.isRequired();
|
|
14614
|
+
this.hostComponent.required = this.hostComponent.required || myCfgObj.isRequired();
|
|
14603
14615
|
this.hostComponent.readonly = this.hostComponent.forceReadonly || this._moduleInReadonlyMode() || myCfgObj.isReadonly();
|
|
14604
14616
|
this.hostComponent.decimals = myCfgObj.scale;
|
|
14605
14617
|
this.hostComponent.maxLength = myCfgObj.maxLength;
|
|
@@ -15320,13 +15332,15 @@
|
|
|
15320
15332
|
return split.join(':');
|
|
15321
15333
|
};
|
|
15322
15334
|
HourSchedulingExpandableComponent.prototype.convertTZ = function (date, tzString) {
|
|
15323
|
-
|
|
15335
|
+
var _a;
|
|
15336
|
+
return new Date((_a = (typeof date === "string" ? new Date(date) : date)) === null || _a === void 0 ? void 0 : _a.toLocaleString("en-US", { timeZone: tzString }));
|
|
15324
15337
|
};
|
|
15325
15338
|
HourSchedulingExpandableComponent.prototype.convertDateToEuropean = function (date) {
|
|
15326
15339
|
return this.convertTZ(date, 'Europe/Amsterdam');
|
|
15327
15340
|
};
|
|
15328
15341
|
HourSchedulingExpandableComponent.prototype.handleDeselectAll = function () {
|
|
15329
|
-
|
|
15342
|
+
var _a;
|
|
15343
|
+
(_a = this.scheduledObjects) === null || _a === void 0 ? void 0 : _a.forEach(function (scheduledObject) {
|
|
15330
15344
|
if (scheduledObject.selected) {
|
|
15331
15345
|
scheduledObject.selected = false;
|
|
15332
15346
|
}
|