@colijnit/corecomponents_v12 300.1.1 → 300.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1133,6 +1133,7 @@ var CoreComponentsIcon;
1133
1133
  CoreComponentsIcon["Linechart"] = "linechart";
1134
1134
  CoreComponentsIcon["LinkedProducts"] = "linked_products";
1135
1135
  CoreComponentsIcon["LinkCircle"] = "link_circle";
1136
+ CoreComponentsIcon["ListRegular"] = "list_regular";
1136
1137
  CoreComponentsIcon["ListView"] = "list_view";
1137
1138
  CoreComponentsIcon["Location"] = "location";
1138
1139
  CoreComponentsIcon["Lock"] = "lock";
@@ -1439,6 +1440,7 @@ const CoreComponentsIconSvg = {
1439
1440
  "linechart": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M11,12.17v25H40v1H10v-26Z\" fill=\"#4c5050\" opacity=\"0.75\"/><polygon points=\"11.76 33.18 11 32.53 15.16 26.48 19.66 24.3 24.26 27.19 28.07 22.25 35.3 19.53 37.01 21.7 38.92 17.28 39.84 17.68 37.26 23.64 34.97 20.72 28.69 23.09 24.5 28.52 19.6 25.44 15.7 27.34 11.76 33.18\" fill=\"#4c5050\"/><polygon points=\"39.84 17.68 37.26 23.64 34.97 20.72 28.69 23.09 24.5 28.52 19.6 25.44 15.7 27.34 11.76 33.18 11 32.53 11 37.17 40 37.17 39.84 17.68\" fill=\"#4c5050\" opacity=\"0.25\"/></svg>",
1440
1441
  "linked_products": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><g opacity=\"0.5\"><path d=\"M20.2,14.71h2.15V26.2l.76-.77V14.71H24.4v9.43l.77-.77V14.71h1.29V22.1l.08-.09,1.29-1.3v-6h1.29v4.71l1.68-1.67a6.28,6.28,0,0,1,.54-.49V14.71h1.29v1.77a7.15,7.15,0,0,1,.77-.29V14.71H36V16a6.71,6.71,0,0,1,1,.21V14.71h1.29v2a6,6,0,0,1,1.31,1l.09.08c.11.11.21.23.31.35v-3a2.57,2.57,0,0,0-2.57-2.57H12.57A2.57,2.57,0,0,0,10,15.14V29.72a2.57,2.57,0,0,0,2.57,2.57h5.95a6.13,6.13,0,0,1,1.68-3.93ZM14.29,30.14H12.15V14.71h2.14Zm2,0H15V14.71h1.29Zm1.28,0V14.71h1.29V30.14Z\" fill=\"#484f60\"/><path d=\"M39.68,26.63,38.29,28v2.11H37v-.83l-2.92,2.92v-.1s-.09.1-.13.16h3.48A2.57,2.57,0,0,0,40,29.72V26.28A3.49,3.49,0,0,1,39.68,26.63Z\" fill=\"#484f60\"/></g><path d=\"M38.62,18.89l-.08-.08a4.73,4.73,0,0,0-6.68,0L27.6,23.07a4.73,4.73,0,0,0,0,6.68l.08.08a3.8,3.8,0,0,0,.48.42l1.56-1.56a2.38,2.38,0,0,1-.51-.39l-.08-.08a2.56,2.56,0,0,1,0-3.62l4.26-4.26a2.56,2.56,0,0,1,3.62,0l.08.08a2.56,2.56,0,0,1,0,3.62L35.16,26a6.53,6.53,0,0,1,.48,2.58l3-3A4.73,4.73,0,0,0,38.62,18.89ZM32.33,25a3.77,3.77,0,0,0-.49-.42l-1.56,1.56a2.1,2.1,0,0,1,.51.39l.08.08a2.56,2.56,0,0,1,0,3.62l-4.26,4.26a2.56,2.56,0,0,1-3.62,0l-.08-.08a2.56,2.56,0,0,1,0-3.62l1.93-1.93a6.6,6.6,0,0,1-.48-2.58l-3,3a4.73,4.73,0,0,0,0,6.68l.08.08a4.73,4.73,0,0,0,6.68,0l4.26-4.26a4.74,4.74,0,0,0,0-6.69Z\" fill=\"#484f60\"/></svg>",
1441
1442
  "link_circle": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M25,45A20,20,0,1,1,45,25,20,20,0,0,1,25,45ZM25,6.29A18.71,18.71,0,1,0,43.71,25,18.73,18.73,0,0,0,25,6.29Z\" fill=\"#484f60\"/><path d=\"M34.48,15.6l-.08-.08a5.21,5.21,0,0,0-7.36,0L22.36,20.2a5.21,5.21,0,0,0,0,7.36l.08.08c.17.17.35.32.53.47l1.72-1.72a2.88,2.88,0,0,1-.56-.43L24,25.87a2.81,2.81,0,0,1,0-4l4.69-4.69a2.81,2.81,0,0,1,4,0l.09.09a2.81,2.81,0,0,1,0,4l-2.12,2.12a7.17,7.17,0,0,1,.52,2.85L34.48,23A5.21,5.21,0,0,0,34.48,15.6Zm-6.92,6.76A5.62,5.62,0,0,0,27,21.9l-1.72,1.71a2.88,2.88,0,0,1,.56.43l.09.09a2.81,2.81,0,0,1,0,4L21.27,32.8a2.81,2.81,0,0,1-4,0l-.09-.09a2.81,2.81,0,0,1,0-4l2.12-2.12a7.17,7.17,0,0,1-.52-2.85L15.52,27a5.21,5.21,0,0,0,0,7.36l.08.08a5.21,5.21,0,0,0,7.36,0l4.68-4.68a5.21,5.21,0,0,0,0-7.36Z\" fill=\"#484f60\"/></svg>",
1443
+ "list_regular": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path d=\"M88 48C101.3 48 112 58.75 112 72V120C112 133.3 101.3 144 88 144H40C26.75 144 16 133.3 16 120V72C16 58.75 26.75 48 40 48H88zM488 72C501.3 72 512 82.75 512 96C512 109.3 501.3 120 488 120H184C170.7 120 160 109.3 160 96C160 82.75 170.7 72 184 72H488zM488 232C501.3 232 512 242.7 512 256C512 269.3 501.3 280 488 280H184C170.7 280 160 269.3 160 256C160 242.7 170.7 232 184 232H488zM488 392C501.3 392 512 402.7 512 416C512 429.3 501.3 440 488 440H184C170.7 440 160 429.3 160 416C160 402.7 170.7 392 184 392H488zM16 232C16 218.7 26.75 208 40 208H88C101.3 208 112 218.7 112 232V280C112 293.3 101.3 304 88 304H40C26.75 304 16 293.3 16 280V232zM88 368C101.3 368 112 378.7 112 392V440C112 453.3 101.3 464 88 464H40C26.75 464 16 453.3 16 440V392C16 378.7 26.75 368 40 368H88z\"/></svg>",
1442
1444
  "list_view": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 51 51\"><rect x=\"26.5\" y=\"13\" width=\"14\" height=\"7\" fill=\"#4d5050\"/><rect x=\"10.5\" y=\"13\" width=\"14\" height=\"7\" fill=\"#4d5050\"/><rect x=\"10.5\" y=\"22\" width=\"14\" height=\"7\" fill=\"#4d5050\"/><rect x=\"26.5\" y=\"22\" width=\"14\" height=\"7\" fill=\"#4d5050\"/><rect x=\"10.5\" y=\"31\" width=\"14\" height=\"7\" fill=\"#4d5050\"/><rect x=\"26.5\" y=\"31\" width=\"14\" height=\"7\" fill=\"#4d5050\"/></svg>",
1443
1445
  "location": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M25,12.67A8.33,8.33,0,0,0,16.67,21c0,4.6,8.33,16.67,8.33,16.67S33.33,25.6,33.33,21A8.33,8.33,0,0,0,25,12.67Zm0,10.41A2.08,2.08,0,1,1,27.08,21,2.08,2.08,0,0,1,25,23.08Z\" fill=\"#484f60\"/></svg>",
1444
1446
  "lock": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M32.65,21.67H17.35c-2.81,0-3.06,2.29-3.06,5.12v8.09c0,2.83.25,5.12,3.06,5.12h15.3c2.81,0,3.06-2.29,3.06-5.12V26.79C35.71,24,35.46,21.67,32.65,21.67ZM20.22,37.49l2.61-6.32a3.82,3.82,0,1,1,4.35,0l2.6,6.32Z\" fill=\"#484f60\"/><path d=\"M29.51,16.64c0-3.6-2-4.07-4.51-4.07h0c-2.49,0-4.51.47-4.51,4.07v3h-2.7v-3C17.79,11.62,21,10,25,10h0c4,0,7.21,1.62,7.21,6.64v3h-2.7Z\" fill=\"#484f60\"/></svg>",
@@ -7491,7 +7493,7 @@ class InputTextComponent extends BaseInputComponent {
7491
7493
  this.clearIconClick.emit(event);
7492
7494
  }
7493
7495
  handleKeyDownInput(event) {
7494
- const key = event.key.toLowerCase();
7496
+ const key = event.key ? event.key.toLowerCase() : '';
7495
7497
  if (this.type === 'date') {
7496
7498
  if (key === 'w') {
7497
7499
  event.preventDefault();
@@ -7524,7 +7526,7 @@ class InputTextComponent extends BaseInputComponent {
7524
7526
  }
7525
7527
  if (this.digitsOnly && !this.isWeekInputMode) {
7526
7528
  // the field is a text input (so a locale comma is allowed), so actively permit only numeric characters
7527
- if (event.key.length === 1 && !event.ctrlKey && !event.metaKey && !event.altKey) {
7529
+ if (key.length === 1 && !event.ctrlKey && !event.metaKey && !event.altKey) {
7528
7530
  const isDigit = /\d/.test(event.key);
7529
7531
  const isSeparator = event.key === '.' || event.key === ',';
7530
7532
  const isSign = !this.excludePlusMinus && (event.key === '-' || event.key === '+');
@@ -7538,7 +7540,7 @@ class InputTextComponent extends BaseInputComponent {
7538
7540
  event.preventDefault();
7539
7541
  return;
7540
7542
  }
7541
- if (event.key !== this._numberLocale.decimalSeparator) {
7543
+ if (key !== this._numberLocale.decimalSeparator) {
7542
7544
  event.preventDefault();
7543
7545
  if (this.input) {
7544
7546
  this._numberLocale.insertDecimalSeparator(this.input);
@@ -10718,6 +10720,7 @@ class PopupWindowShellComponent {
10718
10720
  popupWindow;
10719
10721
  hasMobileSizings;
10720
10722
  _viewContainer;
10723
+ _blankViewContainer;
10721
10724
  _appPopupButtons;
10722
10725
  isError;
10723
10726
  isWarning;
@@ -10760,8 +10763,10 @@ class PopupWindowShellComponent {
10760
10763
  ngOnDestroy() {
10761
10764
  this._close();
10762
10765
  this._viewContainer.clear();
10766
+ this._blankViewContainer.clear();
10763
10767
  this._popupCompRef = undefined;
10764
10768
  this._viewContainer = undefined;
10769
+ this._blankViewContainer = undefined;
10765
10770
  this._changeDetector = undefined;
10766
10771
  }
10767
10772
  async close(eventType) {
@@ -10793,7 +10798,12 @@ class PopupWindowShellComponent {
10793
10798
  this.onCloseClick();
10794
10799
  };
10795
10800
  _createPopupComponent() {
10796
- this._popupCompRef = this._viewContainer.createComponent(this.popupWindow.factory);
10801
+ if (this._viewContainer) {
10802
+ this._popupCompRef = this._viewContainer.createComponent(this.popupWindow.factory);
10803
+ }
10804
+ else {
10805
+ this._popupCompRef = this._blankViewContainer.createComponent(this.popupWindow.factory);
10806
+ }
10797
10807
  ObjectUtils.ForOwnProperty(this.popupWindow.inputs, (value, key) => {
10798
10808
  this._popupCompRef.instance[key] = value;
10799
10809
  });
@@ -10838,45 +10848,61 @@ class PopupWindowShellComponent {
10838
10848
  }
10839
10849
  }
10840
10850
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PopupWindowShellComponent, deps: [{ token: IconCacheService }, { token: i0.ChangeDetectorRef }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component });
10841
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: PopupWindowShellComponent, isStandalone: false, selector: "co-popup-window-shell", inputs: { popupWindow: "popupWindow", hasMobileSizings: "hasMobileSizings" }, host: { properties: { "class.mobile-sizings": "this.hasMobileSizings", "class.popup-error": "this.isError", "class.popup-warning": "this.isWarning", "class.popup-notification": "this.isNotification", "class.popup-question": "this.isQuestion", "class.movable": "this.isMovable" } }, viewQueries: [{ propertyName: "_viewContainer", first: true, predicate: ["popupContent"], descendants: true, read: ViewContainerRef }, { propertyName: "_appPopupButtons", first: true, predicate: PopupButtonsComponent, descendants: true }], ngImport: i0, template: `
10842
- <ng-container *ngIf="!isBlank">
10843
- <co-button *ngIf="popupWindow?.settings.downloadable" class="circle shadowed popup-downloadable" [iconData]="downloadIcon"
10844
- iconClass="light"
10845
- (click)="onDownloadClick()"></co-button>
10846
- <co-button *ngIf="!popupWindow?.settings.hideCloseIcon" class="circle shadowed popup-close" [iconData]="closeIcon"
10847
- iconClass="light"
10848
- (click)="onCloseClick()"></co-button>
10849
- <div class="popup-wrapper" *ngIf="!isBlank">
10850
- <div class="popup-title"><h2 [textContent]="popupWindow?.settings.title"></h2></div>
10851
- <div class="popup-content" (mousedown)="$event.stopImmediatePropagation()">
10852
- <ng-template #popupContent></ng-template>
10851
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: PopupWindowShellComponent, isStandalone: false, selector: "co-popup-window-shell", inputs: { popupWindow: "popupWindow", hasMobileSizings: "hasMobileSizings" }, host: { properties: { "class.mobile-sizings": "this.hasMobileSizings", "class.popup-error": "this.isError", "class.popup-warning": "this.isWarning", "class.popup-notification": "this.isNotification", "class.popup-question": "this.isQuestion", "class.movable": "this.isMovable" } }, viewQueries: [{ propertyName: "_viewContainer", first: true, predicate: ["popupContent"], descendants: true, read: ViewContainerRef }, { propertyName: "_blankViewContainer", first: true, predicate: ["blankPopupContent"], descendants: true, read: ViewContainerRef }, { propertyName: "_appPopupButtons", first: true, predicate: PopupButtonsComponent, descendants: true }], ngImport: i0, template: `
10852
+ @if (!isBlank) {
10853
+ @if (popupWindow?.settings.downloadable) {
10854
+ <co-button class="circle shadowed popup-downloadable" [iconData]="downloadIcon"
10855
+ iconClass="light"
10856
+ (click)="onDownloadClick()"></co-button>
10857
+ }
10858
+ @if (!popupWindow?.settings.hideCloseIcon) {
10859
+ <co-button class="circle shadowed popup-close" [iconData]="closeIcon"
10860
+ iconClass="light"
10861
+ (click)="onCloseClick()"></co-button>
10862
+ }
10863
+ @if (!isBlank) {
10864
+ <div class="popup-wrapper">
10865
+ <div class="popup-title"><h2 [textContent]="popupWindow?.settings.title"></h2></div>
10866
+ <div class="popup-content" (mousedown)="$event.stopImmediatePropagation()">
10867
+ <ng-template #popupContent></ng-template>
10868
+ </div>
10869
+ <co-popup-buttons [popupWindow]="popupWindow" (buttonClick)="onButtonClick($event)"></co-popup-buttons>
10853
10870
  </div>
10854
- <co-popup-buttons [popupWindow]="popupWindow" (buttonClick)="onButtonClick($event)"></co-popup-buttons>
10855
- </div>
10856
- </ng-container>
10857
- <ng-template #popupContent *ngIf="isBlank"></ng-template>
10858
- `, isInline: true, styles: [":host{position:fixed;display:flex;top:50%;left:50%;transform:translate(-50%,-50%)}:host.popup-error div.popup-wrapper{background:#cfd0d1}:host.popup-warning .secondary-font{color:#fff}:host.popup-warning div.popup-wrapper{background:#484f60}:host.popup-warning div.popup-title,:host.popup-warning div.popup-content{color:#fff}:host.popup-notification div.popup-wrapper,:host.popup-question div.popup-wrapper{background:#cfd0d1}co-button.popup-close,co-button.popup-downloadable{position:absolute;transform:translateY(-50%)}co-button.popup-close{right:5px}co-button.popup-downloadable{right:45px}.popup-wrapper{padding:30px;border-radius:5px;box-shadow:0 0 13px -2px #0003;background:#cfd0d1;min-width:320px}.popup-wrapper .popup-title{padding-bottom:20px;border-bottom:1px solid #DAD9D9}.popup-wrapper .popup-content{margin-top:20px;margin-bottom:20px;max-height:50vh;max-width:80vw;overflow:auto}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: ButtonComponent, selector: "co-button", inputs: ["label", "iconData", "iconDataRight", "isToggleButton", "isToggled", "hidden", "disabled"], outputs: ["onClick", "clickedWhileDisabled", "isToggledChange"] }, { kind: "component", type: PopupButtonsComponent, selector: "co-popup-buttons", inputs: ["popupWindow"], outputs: ["buttonClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
10871
+ }
10872
+ }
10873
+ @if (isBlank) {
10874
+ <ng-template #blankPopupContent></ng-template>
10875
+ }
10876
+ `, isInline: true, styles: [":host{position:fixed;display:flex;top:50%;left:50%;transform:translate(-50%,-50%)}:host.popup-error div.popup-wrapper{background:#cfd0d1}:host.popup-warning .secondary-font{color:#fff}:host.popup-warning div.popup-wrapper{background:#484f60}:host.popup-warning div.popup-title,:host.popup-warning div.popup-content{color:#fff}:host.popup-notification div.popup-wrapper,:host.popup-question div.popup-wrapper{background:#cfd0d1}co-button.popup-close,co-button.popup-downloadable{position:absolute;transform:translateY(-50%)}co-button.popup-close{right:5px}co-button.popup-downloadable{right:45px}.popup-wrapper{padding:30px;border-radius:5px;box-shadow:0 0 13px -2px #0003;background:#cfd0d1;min-width:320px}.popup-wrapper .popup-title{padding-bottom:20px;border-bottom:1px solid #DAD9D9}.popup-wrapper .popup-content{margin-top:20px;margin-bottom:20px;max-height:50vh;max-width:80vw;overflow:auto}\n"], dependencies: [{ kind: "component", type: ButtonComponent, selector: "co-button", inputs: ["label", "iconData", "iconDataRight", "isToggleButton", "isToggled", "hidden", "disabled"], outputs: ["onClick", "clickedWhileDisabled", "isToggledChange"] }, { kind: "component", type: PopupButtonsComponent, selector: "co-popup-buttons", inputs: ["popupWindow"], outputs: ["buttonClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
10859
10877
  }
10860
10878
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PopupWindowShellComponent, decorators: [{
10861
10879
  type: Component,
10862
10880
  args: [{ selector: "co-popup-window-shell", template: `
10863
- <ng-container *ngIf="!isBlank">
10864
- <co-button *ngIf="popupWindow?.settings.downloadable" class="circle shadowed popup-downloadable" [iconData]="downloadIcon"
10865
- iconClass="light"
10866
- (click)="onDownloadClick()"></co-button>
10867
- <co-button *ngIf="!popupWindow?.settings.hideCloseIcon" class="circle shadowed popup-close" [iconData]="closeIcon"
10868
- iconClass="light"
10869
- (click)="onCloseClick()"></co-button>
10870
- <div class="popup-wrapper" *ngIf="!isBlank">
10871
- <div class="popup-title"><h2 [textContent]="popupWindow?.settings.title"></h2></div>
10872
- <div class="popup-content" (mousedown)="$event.stopImmediatePropagation()">
10873
- <ng-template #popupContent></ng-template>
10881
+ @if (!isBlank) {
10882
+ @if (popupWindow?.settings.downloadable) {
10883
+ <co-button class="circle shadowed popup-downloadable" [iconData]="downloadIcon"
10884
+ iconClass="light"
10885
+ (click)="onDownloadClick()"></co-button>
10886
+ }
10887
+ @if (!popupWindow?.settings.hideCloseIcon) {
10888
+ <co-button class="circle shadowed popup-close" [iconData]="closeIcon"
10889
+ iconClass="light"
10890
+ (click)="onCloseClick()"></co-button>
10891
+ }
10892
+ @if (!isBlank) {
10893
+ <div class="popup-wrapper">
10894
+ <div class="popup-title"><h2 [textContent]="popupWindow?.settings.title"></h2></div>
10895
+ <div class="popup-content" (mousedown)="$event.stopImmediatePropagation()">
10896
+ <ng-template #popupContent></ng-template>
10897
+ </div>
10898
+ <co-popup-buttons [popupWindow]="popupWindow" (buttonClick)="onButtonClick($event)"></co-popup-buttons>
10874
10899
  </div>
10875
- <co-popup-buttons [popupWindow]="popupWindow" (buttonClick)="onButtonClick($event)"></co-popup-buttons>
10876
- </div>
10877
- </ng-container>
10878
- <ng-template #popupContent *ngIf="isBlank"></ng-template>
10879
- `, changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, styles: [":host{position:fixed;display:flex;top:50%;left:50%;transform:translate(-50%,-50%)}:host.popup-error div.popup-wrapper{background:#cfd0d1}:host.popup-warning .secondary-font{color:#fff}:host.popup-warning div.popup-wrapper{background:#484f60}:host.popup-warning div.popup-title,:host.popup-warning div.popup-content{color:#fff}:host.popup-notification div.popup-wrapper,:host.popup-question div.popup-wrapper{background:#cfd0d1}co-button.popup-close,co-button.popup-downloadable{position:absolute;transform:translateY(-50%)}co-button.popup-close{right:5px}co-button.popup-downloadable{right:45px}.popup-wrapper{padding:30px;border-radius:5px;box-shadow:0 0 13px -2px #0003;background:#cfd0d1;min-width:320px}.popup-wrapper .popup-title{padding-bottom:20px;border-bottom:1px solid #DAD9D9}.popup-wrapper .popup-content{margin-top:20px;margin-bottom:20px;max-height:50vh;max-width:80vw;overflow:auto}\n"] }]
10900
+ }
10901
+ }
10902
+ @if (isBlank) {
10903
+ <ng-template #blankPopupContent></ng-template>
10904
+ }
10905
+ `, changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, styles: [":host{position:fixed;display:flex;top:50%;left:50%;transform:translate(-50%,-50%)}:host.popup-error div.popup-wrapper{background:#cfd0d1}:host.popup-warning .secondary-font{color:#fff}:host.popup-warning div.popup-wrapper{background:#484f60}:host.popup-warning div.popup-title,:host.popup-warning div.popup-content{color:#fff}:host.popup-notification div.popup-wrapper,:host.popup-question div.popup-wrapper{background:#cfd0d1}co-button.popup-close,co-button.popup-downloadable{position:absolute;transform:translateY(-50%)}co-button.popup-close{right:5px}co-button.popup-downloadable{right:45px}.popup-wrapper{padding:30px;border-radius:5px;box-shadow:0 0 13px -2px #0003;background:#cfd0d1;min-width:320px}.popup-wrapper .popup-title{padding-bottom:20px;border-bottom:1px solid #DAD9D9}.popup-wrapper .popup-content{margin-top:20px;margin-bottom:20px;max-height:50vh;max-width:80vw;overflow:auto}\n"] }]
10880
10906
  }], ctorParameters: () => [{ type: IconCacheService }, { type: i0.ChangeDetectorRef }, { type: i0.ViewContainerRef }], propDecorators: { popupWindow: [{
10881
10907
  type: Input
10882
10908
  }], hasMobileSizings: [{
@@ -10887,6 +10913,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
10887
10913
  }], _viewContainer: [{
10888
10914
  type: ViewChild,
10889
10915
  args: ["popupContent", { read: ViewContainerRef }]
10916
+ }], _blankViewContainer: [{
10917
+ type: ViewChild,
10918
+ args: ["blankPopupContent", { read: ViewContainerRef }]
10890
10919
  }], _appPopupButtons: [{
10891
10920
  type: ViewChild,
10892
10921
  args: [PopupButtonsComponent]
@@ -12041,38 +12070,36 @@ class SimpleGridCellComponent {
12041
12070
  this._changeDetector.detectChanges();
12042
12071
  }
12043
12072
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: SimpleGridCellComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.Injector }, { token: FormComponent, optional: true }], target: i0.ɵɵFactoryTarget.Component });
12044
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: SimpleGridCellComponent, isStandalone: false, selector: "co-simple-grid-cell", inputs: { editMode: "editMode", column: "column", row: "row", fieldEditMode: "fieldEditMode" }, outputs: { cellClick: "cellClick" }, host: { listeners: { "click": "handleClick($event)" }, properties: { "class.co-simple-grid-cell": "this.showClass" } }, viewQueries: [{ propertyName: "editTemplateContent", first: true, predicate: ["editTemplate"], descendants: true, read: BaseInputComponent }, { propertyName: "noEditTemplateContent", first: true, predicate: ["noEditTemplate"], descendants: true }, { propertyName: "noTemplateContent", first: true, predicate: ["noTemplate"], descendants: true }], ngImport: i0, template: `
12073
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: SimpleGridCellComponent, isStandalone: false, selector: "co-simple-grid-cell", inputs: { editMode: "editMode", column: "column", row: "row", fieldEditMode: "fieldEditMode" }, outputs: { cellClick: "cellClick" }, host: { listeners: { "click": "handleClick($event)" }, properties: { "class.co-simple-grid-cell": "this.showClass" } }, viewQueries: [{ propertyName: "editTemplateContent", first: true, predicate: ["editTemplate"], descendants: true, read: BaseInputComponent }, { propertyName: "noEditTemplateContent", first: true, predicate: ["noEditTemplate"], descendants: true }, { propertyName: "noTemplateContent", first: true, predicate: ["noTemplate"], descendants: true }], ngImport: i0, template: `
12045
12074
  <div class="simple-grid-column-cell-value" [ngClass]="column.textAlign ? column.textAlign : defaultTextAlign">
12046
- <ng-container *ngIf="editMode; else noInlineEdit">
12047
- <div class="simple-grid-column-cell-field">
12048
- <ng-container #editTemplate *ngIf="column.editTemplate; else noEditTemplate"
12049
- [ngTemplateOutlet]="column.editTemplate"
12050
- [ngTemplateOutletInjector]="columnInjector"
12051
- [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12052
- <ng-template #noEditTemplate>
12053
- <ng-container *ngIf="column.template; else noTemplate">
12054
- <ng-container [ngTemplateOutlet]="column.template"
12055
- [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12056
- </ng-container>
12057
- <ng-template #noTemplate>
12058
- <co-input-text [(model)]="row[column.field]" [required]="column.required"></co-input-text>
12059
- </ng-template>
12060
- </ng-template>
12061
- </div>
12062
- </ng-container>
12063
- <ng-template #noInlineEdit>
12064
- <div class="simple-grid-column-cell-field">
12065
- <ng-container *ngIf="column.template; else noTemplate">
12066
- <ng-container [ngTemplateOutlet]="column.template"
12067
- [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12068
- </ng-container>
12069
- <ng-template #noTemplate>
12070
- <span [textContent]="column.getFieldValue(row[column.field])" [title]="row[column.field]"></span>
12071
- </ng-template>
12072
- </div>
12073
- </ng-template>
12075
+ @if (editMode) {
12076
+ <div class="simple-grid-column-cell-field">
12077
+ @if (column.editTemplate) {
12078
+ <ng-container #editTemplate
12079
+ [ngTemplateOutlet]="column.editTemplate"
12080
+ [ngTemplateOutletInjector]="columnInjector"
12081
+ [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12082
+ } @else {
12083
+ @if (column.template) {
12084
+ <ng-container [ngTemplateOutlet]="column.template"
12085
+ [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12086
+ } @else {
12087
+ <co-input-text [(model)]="row[column.field]" [required]="column.required"></co-input-text>
12088
+ }
12089
+ }
12090
+ </div>
12091
+ } @else {
12092
+ <div class="simple-grid-column-cell-field">
12093
+ @if (column.template) {
12094
+ <ng-container [ngTemplateOutlet]="column.template"
12095
+ [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12096
+ } @else {
12097
+ <span [textContent]="column.getFieldValue(row[column.field])" [title]="row[column.field]"></span>
12098
+ }
12099
+ </div>
12100
+ }
12074
12101
  </div>
12075
- `, isInline: true, dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: InputTextComponent, selector: "co-input-text", inputs: ["useContent", "placeholder", "align", "type", "formatPipe", "min", "max", "pattern", "digitsOnly", "excludePlusMinus", "showClearButton", "keyDownWhiteList", "showPlaceholderOnFocus", "leftIcon", "rightIcon", "leftIconData", "rightIconData", "selectOnFocus", "emptyPlace", "firstDayOfWeek", "noStyle", "hideArrowButtons", "model"], outputs: ["leftIconClick", "leftIconMouseDown", "leftIconMouseUp", "rightIconClick", "rightIconMouseDown", "rightIconMouseUp", "clearIconClick", "isFocused"] }], encapsulation: i0.ViewEncapsulation.None });
12102
+ `, isInline: true, dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: InputTextComponent, selector: "co-input-text", inputs: ["useContent", "placeholder", "align", "type", "formatPipe", "min", "max", "pattern", "digitsOnly", "excludePlusMinus", "showClearButton", "keyDownWhiteList", "showPlaceholderOnFocus", "leftIcon", "rightIcon", "leftIconData", "rightIconData", "selectOnFocus", "emptyPlace", "firstDayOfWeek", "noStyle", "hideArrowButtons", "model"], outputs: ["leftIconClick", "leftIconMouseDown", "leftIconMouseUp", "rightIconClick", "rightIconMouseDown", "rightIconMouseUp", "clearIconClick", "isFocused"] }], encapsulation: i0.ViewEncapsulation.None });
12076
12103
  }
12077
12104
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: SimpleGridCellComponent, decorators: [{
12078
12105
  type: Component,
@@ -12080,36 +12107,34 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
12080
12107
  selector: "co-simple-grid-cell",
12081
12108
  template: `
12082
12109
  <div class="simple-grid-column-cell-value" [ngClass]="column.textAlign ? column.textAlign : defaultTextAlign">
12083
- <ng-container *ngIf="editMode; else noInlineEdit">
12084
- <div class="simple-grid-column-cell-field">
12085
- <ng-container #editTemplate *ngIf="column.editTemplate; else noEditTemplate"
12086
- [ngTemplateOutlet]="column.editTemplate"
12087
- [ngTemplateOutletInjector]="columnInjector"
12088
- [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12089
- <ng-template #noEditTemplate>
12090
- <ng-container *ngIf="column.template; else noTemplate">
12091
- <ng-container [ngTemplateOutlet]="column.template"
12092
- [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12093
- </ng-container>
12094
- <ng-template #noTemplate>
12095
- <co-input-text [(model)]="row[column.field]" [required]="column.required"></co-input-text>
12096
- </ng-template>
12097
- </ng-template>
12098
- </div>
12099
- </ng-container>
12100
- <ng-template #noInlineEdit>
12101
- <div class="simple-grid-column-cell-field">
12102
- <ng-container *ngIf="column.template; else noTemplate">
12103
- <ng-container [ngTemplateOutlet]="column.template"
12104
- [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12105
- </ng-container>
12106
- <ng-template #noTemplate>
12107
- <span [textContent]="column.getFieldValue(row[column.field])" [title]="row[column.field]"></span>
12108
- </ng-template>
12109
- </div>
12110
- </ng-template>
12110
+ @if (editMode) {
12111
+ <div class="simple-grid-column-cell-field">
12112
+ @if (column.editTemplate) {
12113
+ <ng-container #editTemplate
12114
+ [ngTemplateOutlet]="column.editTemplate"
12115
+ [ngTemplateOutletInjector]="columnInjector"
12116
+ [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12117
+ } @else {
12118
+ @if (column.template) {
12119
+ <ng-container [ngTemplateOutlet]="column.template"
12120
+ [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12121
+ } @else {
12122
+ <co-input-text [(model)]="row[column.field]" [required]="column.required"></co-input-text>
12123
+ }
12124
+ }
12125
+ </div>
12126
+ } @else {
12127
+ <div class="simple-grid-column-cell-field">
12128
+ @if (column.template) {
12129
+ <ng-container [ngTemplateOutlet]="column.template"
12130
+ [ngTemplateOutletContext]="{value: row[column.field], row: row}"></ng-container>
12131
+ } @else {
12132
+ <span [textContent]="column.getFieldValue(row[column.field])" [title]="row[column.field]"></span>
12133
+ }
12134
+ </div>
12135
+ }
12111
12136
  </div>
12112
- `,
12137
+ `,
12113
12138
  encapsulation: ViewEncapsulation.None,
12114
12139
  standalone: false
12115
12140
  }]
@@ -14317,6 +14342,7 @@ class ListOfValuesComponent extends BaseInputComponent {
14317
14342
  searchPlaceholder = '';
14318
14343
  searchDisabled = false;
14319
14344
  showChips = true;
14345
+ leftIconClick = new EventEmitter();
14320
14346
  showClass() {
14321
14347
  return true;
14322
14348
  }
@@ -14576,7 +14602,7 @@ class ListOfValuesComponent extends BaseInputComponent {
14576
14602
  }
14577
14603
  }
14578
14604
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: ListOfValuesComponent, deps: [{ token: FormComponent, optional: true }, { token: IconCacheService }, { token: i0.ChangeDetectorRef }, { token: OverlayService }, { token: FormInputUserModelChangeListenerService }, { token: NgZoneWrapperService }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
14579
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: ListOfValuesComponent, isStandalone: false, selector: "co-list-of-values", inputs: { model: "model", multiselect: "multiselect", showToggleAll: "showToggleAll", largeCollection: "largeCollection", displayField: "displayField", optionIcon: "optionIcon", collection: "collection", collectionLoadFn: "collectionLoadFn", collectionLoadFnProp: "collectionLoadFnProp", leftIconData: "leftIconData", searchPlaceholder: "searchPlaceholder", searchDisabled: "searchDisabled", showChips: "showChips" }, host: { properties: { "class.custom-height": "this.multiselect", "class.multi-select": "this.multiselect", "class.co-list-of-values": "this.showClass" } }, providers: [
14605
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: ListOfValuesComponent, isStandalone: false, selector: "co-list-of-values", inputs: { model: "model", multiselect: "multiselect", showToggleAll: "showToggleAll", largeCollection: "largeCollection", displayField: "displayField", optionIcon: "optionIcon", collection: "collection", collectionLoadFn: "collectionLoadFn", collectionLoadFnProp: "collectionLoadFnProp", leftIconData: "leftIconData", searchPlaceholder: "searchPlaceholder", searchDisabled: "searchDisabled", showChips: "showChips" }, outputs: { leftIconClick: "leftIconClick" }, host: { properties: { "class.custom-height": "this.multiselect", "class.multi-select": "this.multiselect", "class.co-list-of-values": "this.showClass" } }, providers: [
14580
14606
  OverlayService,
14581
14607
  {
14582
14608
  provide: SCREEN_CONFIG_ADAPTER_COMPONENT_INTERFACE_NAME,
@@ -14611,6 +14637,7 @@ class ListOfValuesComponent extends BaseInputComponent {
14611
14637
  (click)="openPopup()"
14612
14638
  (rightIconClick)="toggleSelect()"
14613
14639
  (keydown)="handleInputKeyDown($event)"
14640
+ (leftIconClick)="leftIconClick.emit()"
14614
14641
  (clearIconClick)="clearModel($event)"
14615
14642
  (blur)="checkModel()">
14616
14643
  @if (multiselect && showChips) {
@@ -14663,6 +14690,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
14663
14690
  (click)="openPopup()"
14664
14691
  (rightIconClick)="toggleSelect()"
14665
14692
  (keydown)="handleInputKeyDown($event)"
14693
+ (leftIconClick)="leftIconClick.emit()"
14666
14694
  (clearIconClick)="clearModel($event)"
14667
14695
  (blur)="checkModel()">
14668
14696
  @if (multiselect && showChips) {
@@ -14728,6 +14756,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
14728
14756
  type: Input
14729
14757
  }], showChips: [{
14730
14758
  type: Input
14759
+ }], leftIconClick: [{
14760
+ type: Output
14731
14761
  }], showClass: [{
14732
14762
  type: HostBinding,
14733
14763
  args: ['class.co-list-of-values']
@@ -19687,8 +19717,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
19687
19717
  class HourSchedulingExpandableComponent {
19688
19718
  cdRef;
19689
19719
  eRef;
19720
+ iconCacheService;
19721
+ icons = CoreComponentsIcon;
19690
19722
  hourLabels = [];
19691
19723
  scheduledObjects = [];
19724
+ selectedHour;
19725
+ layouts = [];
19692
19726
  resizing = false;
19693
19727
  resizeDirection;
19694
19728
  initialY;
@@ -19717,6 +19751,7 @@ class HourSchedulingExpandableComponent {
19717
19751
  idProp; // Input for unique identifier property
19718
19752
  timeChangeEvent = new EventEmitter();
19719
19753
  newObjectPlanEvent = new EventEmitter();
19754
+ taskCreationEvent = new EventEmitter();
19720
19755
  moveBetweenCalendarsEvent = new EventEmitter();
19721
19756
  showClass = true;
19722
19757
  onResize(event) {
@@ -19727,9 +19762,10 @@ class HourSchedulingExpandableComponent {
19727
19762
  this.handleDeselectAll();
19728
19763
  }
19729
19764
  }
19730
- constructor(cdRef, eRef) {
19765
+ constructor(cdRef, eRef, iconCacheService) {
19731
19766
  this.cdRef = cdRef;
19732
19767
  this.eRef = eRef;
19768
+ this.iconCacheService = iconCacheService;
19733
19769
  }
19734
19770
  ngOnInit() {
19735
19771
  this.generateTimeBlocks();
@@ -19777,6 +19813,7 @@ class HourSchedulingExpandableComponent {
19777
19813
  });
19778
19814
  }
19779
19815
  this.scheduledObjects = schedulingObjects;
19816
+ this.layouts = this.calculateLeftAndWidthOfObjects();
19780
19817
  this.cdRef.markForCheck();
19781
19818
  this.cdRef.detectChanges();
19782
19819
  }
@@ -19830,6 +19867,7 @@ class HourSchedulingExpandableComponent {
19830
19867
  this.moveBetweenCalendarsEvent.emit({ hour: hour, data: parsed });
19831
19868
  }
19832
19869
  }
19870
+ this.layouts = this.calculateLeftAndWidthOfObjects();
19833
19871
  }
19834
19872
  allowDrop(event, hour) {
19835
19873
  event.preventDefault();
@@ -19907,6 +19945,7 @@ class HourSchedulingExpandableComponent {
19907
19945
  this.resizing = false;
19908
19946
  this.currentResizingObject.selected = false;
19909
19947
  this.currentResizingObject = null;
19948
+ this.layouts = this.calculateLeftAndWidthOfObjects();
19910
19949
  }
19911
19950
  document.removeEventListener("mousemove", this._onMouseMove);
19912
19951
  document.removeEventListener("mouseup", this._onMouseUp);
@@ -19960,22 +19999,86 @@ class HourSchedulingExpandableComponent {
19960
19999
  }
19961
20000
  });
19962
20001
  }
19963
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: HourSchedulingExpandableComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
19964
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: HourSchedulingExpandableComponent, isStandalone: false, selector: "co-hour-scheduling-expandable", inputs: { schedule: "schedule", startTimeProp: "startTimeProp", endTimeProp: "endTimeProp", objectsProp: "objectsProp", childProp: "childProp", customTemplate: "customTemplate", idProp: "idProp" }, outputs: { timeChangeEvent: "timeChangeEvent", newObjectPlanEvent: "newObjectPlanEvent", moveBetweenCalendarsEvent: "moveBetweenCalendarsEvent" }, host: { listeners: { "window:resize": "onResize($event)", "document:click": "clickOut($event)" }, properties: { "class.co-hour-scheduling-expandable": "this.showClass" } }, ngImport: i0, template: `
20002
+ selectHalfHourBlock(mouseEvent, hour, first = true) {
20003
+ mouseEvent.stopPropagation();
20004
+ if (!first) {
20005
+ hour = this.addHalfHour(hour);
20006
+ }
20007
+ this.selectedHour = hour;
20008
+ }
20009
+ handleHourTaskCreate(mouseEvent, hour, first = true) {
20010
+ mouseEvent.stopPropagation();
20011
+ if (!first) {
20012
+ hour = this.addHalfHour(hour);
20013
+ }
20014
+ this.taskCreationEvent.emit(hour);
20015
+ this.selectedHour = "";
20016
+ }
20017
+ calculateLeftAndWidthOfObjects() {
20018
+ const layoutData = new Array(this.scheduledObjects.length);
20019
+ // Helper: check if two time ranges overlap
20020
+ const isOverlapping = (startA, endA, startB, endB) => {
20021
+ return startA < endB && startB < endA;
20022
+ };
20023
+ // Step 1: build overlap groups
20024
+ const overlapGroups = [];
20025
+ const processed = new Set();
20026
+ for (let i = 0; i < this.scheduledObjects.length; i++) {
20027
+ if (processed.has(i)) {
20028
+ continue;
20029
+ }
20030
+ const group = [i];
20031
+ const objA = this.scheduledObjects[i];
20032
+ const startA = new Date(objA.start);
20033
+ const endA = new Date(objA.end);
20034
+ for (let j = i + 1; j < this.scheduledObjects.length; j++) {
20035
+ const objB = this.scheduledObjects[j];
20036
+ const startB = new Date(objB.start);
20037
+ const endB = new Date(objB.end);
20038
+ if (isOverlapping(startA, endA, startB, endB)) {
20039
+ group.push(j);
20040
+ processed.add(j);
20041
+ }
20042
+ }
20043
+ group.forEach(index => processed.add(index));
20044
+ overlapGroups.push(group);
20045
+ }
20046
+ // Step 2: assign layout per group
20047
+ overlapGroups.forEach(group => {
20048
+ const total = group.length;
20049
+ const width = 100 / total;
20050
+ group.forEach((objectIndex, i) => {
20051
+ layoutData[objectIndex] = {
20052
+ leftPercent: i * width,
20053
+ widthPercent: width
20054
+ };
20055
+ });
20056
+ });
20057
+ return layoutData;
20058
+ }
20059
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: HourSchedulingExpandableComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: IconCacheService }], target: i0.ɵɵFactoryTarget.Component });
20060
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: HourSchedulingExpandableComponent, isStandalone: false, selector: "co-hour-scheduling-expandable", inputs: { schedule: "schedule", startTimeProp: "startTimeProp", endTimeProp: "endTimeProp", objectsProp: "objectsProp", childProp: "childProp", customTemplate: "customTemplate", idProp: "idProp" }, outputs: { timeChangeEvent: "timeChangeEvent", newObjectPlanEvent: "newObjectPlanEvent", taskCreationEvent: "taskCreationEvent", moveBetweenCalendarsEvent: "moveBetweenCalendarsEvent" }, host: { listeners: { "window:resize": "onResize($event)", "document:click": "clickOut($event)" }, properties: { "class.co-hour-scheduling-expandable": "this.showClass" } }, ngImport: i0, template: `
19965
20061
  <div class="wrapper">
19966
20062
  @for (hour of hourLabels; track hour) {
19967
20063
  <div class="time-block">
19968
20064
  <div class="hour-label"><span [textContent]="hour"></span></div>
19969
20065
  <div class="object-display">
19970
20066
  <div class="first-half-hour object-half"
20067
+ [class.selected]="selectedHour === hour"
20068
+ (click)="selectHalfHourBlock($event, hour)"
19971
20069
  (dragover)="allowDrop($event, hour)"
19972
20070
  (dragleave)="handleDragLeave($event)"
19973
20071
  (drop)="handleDrop($event, hour)">
20072
+ <co-icon class="toggle-icon" [class.visible]="selectedHour === hour" [icon]="icons.ListRegular" (click)="handleHourTaskCreate($event, hour)"></co-icon>
19974
20073
  </div>
19975
20074
  <div class="second-half-hour object-half"
20075
+ [class.selected]="selectedHour === this.addHalfHour(hour)"
19976
20076
  (dragover)="allowDrop($event, addHalfHour(hour))"
19977
20077
  (dragleave)="handleDragLeave($event)"
20078
+ (click)="selectHalfHourBlock($event, hour, false)"
19978
20079
  (drop)="handleDrop($event, addHalfHour(hour))">
20080
+ <co-icon class="toggle-icon" [class.visible]="selectedHour === this.addHalfHour(hour)" [icon]="icons.ListRegular" (click)="handleHourTaskCreate($event, hour, false)"></co-icon>
20081
+
19979
20082
  </div>
19980
20083
  </div>
19981
20084
  </div>
@@ -19987,6 +20090,7 @@ class HourSchedulingExpandableComponent {
19987
20090
  [ngTemplateOutlet]="customTemplate"
19988
20091
  [ngTemplateOutletContext]="{
19989
20092
  objects: scheduledObjects,
20093
+ layouts: layouts,
19990
20094
  onSelectBlock: this.onSelectBlock.bind(this),
19991
20095
  onResizeStart: this.onResizeStart.bind(this),
19992
20096
  onResizeEnd: this.onResizeEnd.bind(this),
@@ -20001,7 +20105,7 @@ class HourSchedulingExpandableComponent {
20001
20105
 
20002
20106
  </div>
20003
20107
 
20004
- `, isInline: true, dependencies: [{ kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
20108
+ `, isInline: true, dependencies: [{ kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: IconComponent, selector: "co-icon", inputs: ["icon", "iconData"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
20005
20109
  }
20006
20110
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: HourSchedulingExpandableComponent, decorators: [{
20007
20111
  type: Component,
@@ -20014,14 +20118,21 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
20014
20118
  <div class="hour-label"><span [textContent]="hour"></span></div>
20015
20119
  <div class="object-display">
20016
20120
  <div class="first-half-hour object-half"
20121
+ [class.selected]="selectedHour === hour"
20122
+ (click)="selectHalfHourBlock($event, hour)"
20017
20123
  (dragover)="allowDrop($event, hour)"
20018
20124
  (dragleave)="handleDragLeave($event)"
20019
20125
  (drop)="handleDrop($event, hour)">
20126
+ <co-icon class="toggle-icon" [class.visible]="selectedHour === hour" [icon]="icons.ListRegular" (click)="handleHourTaskCreate($event, hour)"></co-icon>
20020
20127
  </div>
20021
20128
  <div class="second-half-hour object-half"
20129
+ [class.selected]="selectedHour === this.addHalfHour(hour)"
20022
20130
  (dragover)="allowDrop($event, addHalfHour(hour))"
20023
20131
  (dragleave)="handleDragLeave($event)"
20132
+ (click)="selectHalfHourBlock($event, hour, false)"
20024
20133
  (drop)="handleDrop($event, addHalfHour(hour))">
20134
+ <co-icon class="toggle-icon" [class.visible]="selectedHour === this.addHalfHour(hour)" [icon]="icons.ListRegular" (click)="handleHourTaskCreate($event, hour, false)"></co-icon>
20135
+
20025
20136
  </div>
20026
20137
  </div>
20027
20138
  </div>
@@ -20033,6 +20144,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
20033
20144
  [ngTemplateOutlet]="customTemplate"
20034
20145
  [ngTemplateOutletContext]="{
20035
20146
  objects: scheduledObjects,
20147
+ layouts: layouts,
20036
20148
  onSelectBlock: this.onSelectBlock.bind(this),
20037
20149
  onResizeStart: this.onResizeStart.bind(this),
20038
20150
  onResizeEnd: this.onResizeEnd.bind(this),
@@ -20052,7 +20164,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
20052
20164
  encapsulation: ViewEncapsulation.None,
20053
20165
  standalone: false
20054
20166
  }]
20055
- }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }], propDecorators: { schedule: [{
20167
+ }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: IconCacheService }], propDecorators: { schedule: [{
20056
20168
  type: Input
20057
20169
  }], startTimeProp: [{
20058
20170
  type: Input
@@ -20070,6 +20182,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
20070
20182
  type: Output
20071
20183
  }], newObjectPlanEvent: [{
20072
20184
  type: Output
20185
+ }], taskCreationEvent: [{
20186
+ type: Output
20073
20187
  }], moveBetweenCalendarsEvent: [{
20074
20188
  type: Output
20075
20189
  }], showClass: [{
@@ -20089,7 +20203,6 @@ class HourSchedulingExpandableTemplateComponent {
20089
20203
  objectTemplate;
20090
20204
  set objects(objects) {
20091
20205
  this._objects = objects;
20092
- this.layouts = this.calculateLeftAndWidthOfObjects();
20093
20206
  }
20094
20207
  get objects() {
20095
20208
  return this._objects;
@@ -20106,50 +20219,8 @@ class HourSchedulingExpandableTemplateComponent {
20106
20219
  event.dataTransfer?.setData("text", JSON.stringify(obj));
20107
20220
  this.onDragStartCustom?.(obj);
20108
20221
  }
20109
- calculateLeftAndWidthOfObjects() {
20110
- const layoutData = new Array(this._objects.length);
20111
- // Helper: check if two time ranges overlap
20112
- const isOverlapping = (startA, endA, startB, endB) => {
20113
- return startA < endB && startB < endA;
20114
- };
20115
- // Step 1: build overlap groups
20116
- const overlapGroups = [];
20117
- const processed = new Set();
20118
- for (let i = 0; i < this._objects.length; i++) {
20119
- if (processed.has(i)) {
20120
- continue;
20121
- }
20122
- const group = [i];
20123
- const objA = this._objects[i];
20124
- const startA = new Date(objA.start);
20125
- const endA = new Date(objA.end);
20126
- for (let j = i + 1; j < this._objects.length; j++) {
20127
- const objB = this._objects[j];
20128
- const startB = new Date(objB.start);
20129
- const endB = new Date(objB.end);
20130
- if (isOverlapping(startA, endA, startB, endB)) {
20131
- group.push(j);
20132
- processed.add(j);
20133
- }
20134
- }
20135
- group.forEach(index => processed.add(index));
20136
- overlapGroups.push(group);
20137
- }
20138
- // Step 2: assign layout per group
20139
- overlapGroups.forEach(group => {
20140
- const total = group.length;
20141
- const width = 100 / total;
20142
- group.forEach((objectIndex, i) => {
20143
- layoutData[objectIndex] = {
20144
- leftPercent: i * width,
20145
- widthPercent: width
20146
- };
20147
- });
20148
- });
20149
- return layoutData;
20150
- }
20151
20222
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: HourSchedulingExpandableTemplateComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
20152
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: HourSchedulingExpandableTemplateComponent, isStandalone: false, selector: "co-hour-scheduling-expandable-template", inputs: { objectTemplate: "objectTemplate", objects: "objects", onDragStartCustom: "onDragStartCustom", onResizeStart: "onResizeStart", onSelectBlock: "onSelectBlock", startTimeProp: "startTimeProp", endTimeProp: "endTimeProp" }, host: { properties: { "class.co-hour-scheduling-expandable-template": "this.showClass" } }, ngImport: i0, template: `
20223
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: HourSchedulingExpandableTemplateComponent, isStandalone: false, selector: "co-hour-scheduling-expandable-template", inputs: { layouts: "layouts", objectTemplate: "objectTemplate", objects: "objects", onDragStartCustom: "onDragStartCustom", onResizeStart: "onResizeStart", onSelectBlock: "onSelectBlock", startTimeProp: "startTimeProp", endTimeProp: "endTimeProp" }, host: { properties: { "class.co-hour-scheduling-expandable-template": "this.showClass" } }, ngImport: i0, template: `
20153
20224
 
20154
20225
  @for (obj of objects; track obj.id; let i = $index) {
20155
20226
  <div
@@ -20168,7 +20239,7 @@ class HourSchedulingExpandableTemplateComponent {
20168
20239
 
20169
20240
  <ng-template
20170
20241
  [ngTemplateOutlet]="objectTemplate"
20171
- [ngTemplateOutletContext]="{object: obj}">
20242
+ [ngTemplateOutletContext]="{object: obj, layouts: layouts}">
20172
20243
  </ng-template>
20173
20244
 
20174
20245
  @if (obj.selected) {
@@ -20201,7 +20272,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
20201
20272
 
20202
20273
  <ng-template
20203
20274
  [ngTemplateOutlet]="objectTemplate"
20204
- [ngTemplateOutletContext]="{object: obj}">
20275
+ [ngTemplateOutletContext]="{object: obj, layouts: layouts}">
20205
20276
  </ng-template>
20206
20277
 
20207
20278
  @if (obj.selected) {
@@ -20213,7 +20284,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
20213
20284
  encapsulation: ViewEncapsulation.None,
20214
20285
  standalone: false
20215
20286
  }]
20216
- }], propDecorators: { objectTemplate: [{
20287
+ }], propDecorators: { layouts: [{
20288
+ type: Input
20289
+ }], objectTemplate: [{
20217
20290
  type: Input
20218
20291
  }], objects: [{
20219
20292
  type: Input
@@ -20257,10 +20330,12 @@ class HourSchedulingExpandableComponentModule {
20257
20330
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: HourSchedulingExpandableComponentModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
20258
20331
  static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.16", ngImport: i0, type: HourSchedulingExpandableComponentModule, declarations: [HourSchedulingExpandableComponent], imports: [CommonModule,
20259
20332
  HourSchedulingComponentModule,
20260
- HourSchedulingExpandableTemplateModule], exports: [HourSchedulingExpandableComponent] });
20333
+ HourSchedulingExpandableTemplateModule,
20334
+ IconModule], exports: [HourSchedulingExpandableComponent] });
20261
20335
  static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: HourSchedulingExpandableComponentModule, providers: [DatePipe], imports: [CommonModule,
20262
20336
  HourSchedulingComponentModule,
20263
- HourSchedulingExpandableTemplateModule] });
20337
+ HourSchedulingExpandableTemplateModule,
20338
+ IconModule] });
20264
20339
  }
20265
20340
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: HourSchedulingExpandableComponentModule, decorators: [{
20266
20341
  type: NgModule,
@@ -20268,7 +20343,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
20268
20343
  imports: [
20269
20344
  CommonModule,
20270
20345
  HourSchedulingComponentModule,
20271
- HourSchedulingExpandableTemplateModule
20346
+ HourSchedulingExpandableTemplateModule,
20347
+ IconModule
20272
20348
  ],
20273
20349
  declarations: [
20274
20350
  HourSchedulingExpandableComponent,