@onemrvapublic/design-system 21.8.1-develop.3 → 22.0.0-develop.10

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.
Files changed (102) hide show
  1. package/README.md +3 -3
  2. package/assets/i18n/de.json +12 -0
  3. package/assets/i18n/en.json +12 -0
  4. package/assets/i18n/fr.json +12 -0
  5. package/assets/i18n/nl.json +12 -0
  6. package/fesm2022/onemrvapublic-design-system-card.mjs +33 -20
  7. package/fesm2022/onemrvapublic-design-system-card.mjs.map +1 -1
  8. package/fesm2022/onemrvapublic-design-system-collapsible-page-divider.mjs +11 -7
  9. package/fesm2022/onemrvapublic-design-system-collapsible-page-divider.mjs.map +1 -1
  10. package/fesm2022/onemrvapublic-design-system-flag-icon.mjs +9 -6
  11. package/fesm2022/onemrvapublic-design-system-flag-icon.mjs.map +1 -1
  12. package/fesm2022/onemrvapublic-design-system-layout.mjs +182 -155
  13. package/fesm2022/onemrvapublic-design-system-layout.mjs.map +1 -1
  14. package/fesm2022/onemrvapublic-design-system-mat-address.mjs +11 -9
  15. package/fesm2022/onemrvapublic-design-system-mat-address.mjs.map +1 -1
  16. package/fesm2022/onemrvapublic-design-system-mat-avatar.mjs +23 -13
  17. package/fesm2022/onemrvapublic-design-system-mat-avatar.mjs.map +1 -1
  18. package/fesm2022/onemrvapublic-design-system-mat-breadcrumb.mjs +14 -12
  19. package/fesm2022/onemrvapublic-design-system-mat-breadcrumb.mjs.map +1 -1
  20. package/fesm2022/onemrvapublic-design-system-mat-carousel.mjs +39 -56
  21. package/fesm2022/onemrvapublic-design-system-mat-carousel.mjs.map +1 -1
  22. package/fesm2022/onemrvapublic-design-system-mat-choice-chip.mjs +13 -8
  23. package/fesm2022/onemrvapublic-design-system-mat-choice-chip.mjs.map +1 -1
  24. package/fesm2022/onemrvapublic-design-system-mat-copy-to-clipboard.mjs +7 -6
  25. package/fesm2022/onemrvapublic-design-system-mat-copy-to-clipboard.mjs.map +1 -1
  26. package/fesm2022/onemrvapublic-design-system-mat-country-item.mjs +8 -7
  27. package/fesm2022/onemrvapublic-design-system-mat-country-item.mjs.map +1 -1
  28. package/fesm2022/onemrvapublic-design-system-mat-datepicker-header.mjs +5 -6
  29. package/fesm2022/onemrvapublic-design-system-mat-datepicker-header.mjs.map +1 -1
  30. package/fesm2022/onemrvapublic-design-system-mat-empty-row.mjs +9 -6
  31. package/fesm2022/onemrvapublic-design-system-mat-empty-row.mjs.map +1 -1
  32. package/fesm2022/onemrvapublic-design-system-mat-file-upload.mjs +83 -98
  33. package/fesm2022/onemrvapublic-design-system-mat-file-upload.mjs.map +1 -1
  34. package/fesm2022/onemrvapublic-design-system-mat-input-address.mjs +24 -17
  35. package/fesm2022/onemrvapublic-design-system-mat-input-address.mjs.map +1 -1
  36. package/fesm2022/onemrvapublic-design-system-mat-input-birthplace.mjs +25 -16
  37. package/fesm2022/onemrvapublic-design-system-mat-input-birthplace.mjs.map +1 -1
  38. package/fesm2022/onemrvapublic-design-system-mat-input-country.mjs +21 -14
  39. package/fesm2022/onemrvapublic-design-system-mat-input-country.mjs.map +1 -1
  40. package/fesm2022/onemrvapublic-design-system-mat-input-enterprise-number.mjs +21 -14
  41. package/fesm2022/onemrvapublic-design-system-mat-input-enterprise-number.mjs.map +1 -1
  42. package/fesm2022/onemrvapublic-design-system-mat-input-iban.mjs +20 -14
  43. package/fesm2022/onemrvapublic-design-system-mat-input-iban.mjs.map +1 -1
  44. package/fesm2022/onemrvapublic-design-system-mat-input-phone.mjs +17 -14
  45. package/fesm2022/onemrvapublic-design-system-mat-input-phone.mjs.map +1 -1
  46. package/fesm2022/onemrvapublic-design-system-mat-message-box.mjs +29 -18
  47. package/fesm2022/onemrvapublic-design-system-mat-message-box.mjs.map +1 -1
  48. package/fesm2022/onemrvapublic-design-system-mat-multi-select.mjs +19 -13
  49. package/fesm2022/onemrvapublic-design-system-mat-multi-select.mjs.map +1 -1
  50. package/fesm2022/onemrvapublic-design-system-mat-navigation.mjs +54 -32
  51. package/fesm2022/onemrvapublic-design-system-mat-navigation.mjs.map +1 -1
  52. package/fesm2022/onemrvapublic-design-system-mat-notification.mjs +15 -11
  53. package/fesm2022/onemrvapublic-design-system-mat-notification.mjs.map +1 -1
  54. package/fesm2022/onemrvapublic-design-system-mat-paginator.mjs +21 -14
  55. package/fesm2022/onemrvapublic-design-system-mat-paginator.mjs.map +1 -1
  56. package/fesm2022/onemrvapublic-design-system-mat-panel.mjs +56 -39
  57. package/fesm2022/onemrvapublic-design-system-mat-panel.mjs.map +1 -1
  58. package/fesm2022/onemrvapublic-design-system-mat-pop-over.mjs +33 -23
  59. package/fesm2022/onemrvapublic-design-system-mat-pop-over.mjs.map +1 -1
  60. package/fesm2022/onemrvapublic-design-system-mat-progress-bar.mjs +19 -11
  61. package/fesm2022/onemrvapublic-design-system-mat-progress-bar.mjs.map +1 -1
  62. package/fesm2022/onemrvapublic-design-system-mat-select-search.mjs +56 -35
  63. package/fesm2022/onemrvapublic-design-system-mat-select-search.mjs.map +1 -1
  64. package/fesm2022/onemrvapublic-design-system-mat-selectable-box.mjs +19 -13
  65. package/fesm2022/onemrvapublic-design-system-mat-selectable-box.mjs.map +1 -1
  66. package/fesm2022/onemrvapublic-design-system-mat-side-menu.mjs +13 -10
  67. package/fesm2022/onemrvapublic-design-system-mat-side-menu.mjs.map +1 -1
  68. package/fesm2022/onemrvapublic-design-system-mat-skeleton.mjs +61 -34
  69. package/fesm2022/onemrvapublic-design-system-mat-skeleton.mjs.map +1 -1
  70. package/fesm2022/onemrvapublic-design-system-mat-spinner.mjs +12 -11
  71. package/fesm2022/onemrvapublic-design-system-mat-spinner.mjs.map +1 -1
  72. package/fesm2022/onemrvapublic-design-system-mat-stepper.mjs +13 -41
  73. package/fesm2022/onemrvapublic-design-system-mat-stepper.mjs.map +1 -1
  74. package/fesm2022/onemrvapublic-design-system-mat-sticker.mjs +7 -7
  75. package/fesm2022/onemrvapublic-design-system-mat-table-of-content.mjs +39 -26
  76. package/fesm2022/onemrvapublic-design-system-mat-table-of-content.mjs.map +1 -1
  77. package/fesm2022/onemrvapublic-design-system-mat-task-list.mjs +44 -30
  78. package/fesm2022/onemrvapublic-design-system-mat-task-list.mjs.map +1 -1
  79. package/fesm2022/onemrvapublic-design-system-mat-toast.mjs +7 -7
  80. package/fesm2022/onemrvapublic-design-system-mat-tooltip.mjs +26 -19
  81. package/fesm2022/onemrvapublic-design-system-mat-tooltip.mjs.map +1 -1
  82. package/fesm2022/onemrvapublic-design-system-page-error.mjs +18 -15
  83. package/fesm2022/onemrvapublic-design-system-page-error.mjs.map +1 -1
  84. package/fesm2022/onemrvapublic-design-system-page-not-found.mjs +24 -20
  85. package/fesm2022/onemrvapublic-design-system-page-not-found.mjs.map +1 -1
  86. package/fesm2022/onemrvapublic-design-system-shared.mjs +126 -104
  87. package/fesm2022/onemrvapublic-design-system-shared.mjs.map +1 -1
  88. package/fesm2022/onemrvapublic-design-system-timeline.mjs +563 -0
  89. package/fesm2022/onemrvapublic-design-system-timeline.mjs.map +1 -0
  90. package/fesm2022/onemrvapublic-design-system.mjs +1 -1
  91. package/fesm2022/onemrvapublic-design-system.mjs.map +1 -1
  92. package/mat-carousel/src/onemrva-mat-carousel.component.scss +18 -0
  93. package/mat-tooltip/src/onemrva-mat-tooltip.component.scss +1 -0
  94. package/package.json +19 -15
  95. package/timeline/src/onemrva-timeline.component.scss +371 -0
  96. package/types/onemrvapublic-design-system-layout.d.ts +1 -1
  97. package/types/onemrvapublic-design-system-mat-carousel.d.ts +0 -3
  98. package/types/onemrvapublic-design-system-mat-file-upload.d.ts +1 -1
  99. package/types/onemrvapublic-design-system-page-error.d.ts +1 -1
  100. package/types/onemrvapublic-design-system-shared.d.ts +1 -1
  101. package/types/onemrvapublic-design-system-timeline.d.ts +195 -0
  102. package/types/onemrvapublic-design-system.d.ts +1 -1
@@ -5,11 +5,10 @@ import * as i1 from '@angular/material/button';
5
5
  import { MatButtonModule } from '@angular/material/button';
6
6
  import { MatIcon, MatIconModule } from '@angular/material/icon';
7
7
  import { MatTooltip, MatTooltipModule } from '@angular/material/tooltip';
8
- import { TranslatePipe, TranslateService, TranslateModule } from '@ngx-translate/core';
8
+ import { TranslatePipe, TranslateService, TranslateDirective } from '@ngx-translate/core';
9
9
  import { MatProgressBar } from '@angular/material/progress-bar';
10
10
  import { MatDialog, MatDialogModule } from '@angular/material/dialog';
11
11
  import { BehaviorSubject, of, interval, take, map, catchError, tap, mergeMap, withLatestFrom, filter, throttle, takeWhile, switchMap, forkJoin, merge, Subject } from 'rxjs';
12
- import { trigger, state, transition, style, animate, keyframes } from '@angular/animations';
13
12
  import { ComponentStore } from '@ngrx/component-store';
14
13
  import { HttpEventType, HttpResponse } from '@angular/common/http';
15
14
  import { OnemRvaCDNMimeService } from '@onemrvapublic/design-system/shared';
@@ -73,30 +72,47 @@ function convertToReferencedProgressFile(id, name, message = undefined, progress
73
72
  let NEXT_ID$1 = 0;
74
73
  class OnemrvaFilePanelComponent {
75
74
  constructor() {
76
- this.id = input(`onemrva-file-panel-${NEXT_ID$1++}`, ...(ngDevMode ? [{ debugName: "id" }] : /* istanbul ignore next */ []));
77
- this.dataCy = input('onemrva-file-panel-' + NEXT_ID$1, ...(ngDevMode ? [{ debugName: "dataCy" }] : /* istanbul ignore next */ []));
78
- this.file = input.required(...(ngDevMode ? [{ debugName: "file" }] : /* istanbul ignore next */ []));
79
- this.actions = input([], ...(ngDevMode ? [{ debugName: "actions" }] : /* istanbul ignore next */ []));
80
- this.showProgress = input(true, ...(ngDevMode ? [{ debugName: "showProgress" }] : /* istanbul ignore next */ []));
81
- this.displayDate = input(undefined, ...(ngDevMode ? [{ debugName: "displayDate" }] : /* istanbul ignore next */ []));
82
- this.maxFileSize = input(0, ...(ngDevMode ? [{ debugName: "maxFileSize" }] : /* istanbul ignore next */ []));
83
- this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
75
+ this.id = input(`onemrva-file-panel-${NEXT_ID$1++}`, /* @ts-ignore */
76
+ ...(ngDevMode ? [{ debugName: "id" }] : /* istanbul ignore next */ []));
77
+ this.dataCy = input('onemrva-file-panel-' + NEXT_ID$1, /* @ts-ignore */
78
+ ...(ngDevMode ? [{ debugName: "dataCy" }] : /* istanbul ignore next */ []));
79
+ this.file = input.required(/* @ts-ignore */
80
+ ...(ngDevMode ? [{ debugName: "file" }] : /* istanbul ignore next */ []));
81
+ this.actions = input([], /* @ts-ignore */
82
+ ...(ngDevMode ? [{ debugName: "actions" }] : /* istanbul ignore next */ []));
83
+ this.showProgress = input(true, /* @ts-ignore */
84
+ ...(ngDevMode ? [{ debugName: "showProgress" }] : /* istanbul ignore next */ []));
85
+ this.displayDate = input(undefined, /* @ts-ignore */
86
+ ...(ngDevMode ? [{ debugName: "displayDate" }] : /* istanbul ignore next */ []));
87
+ this.maxFileSize = input(0, /* @ts-ignore */
88
+ ...(ngDevMode ? [{ debugName: "maxFileSize" }] : /* istanbul ignore next */ []));
89
+ this.disabled = input(false, /* @ts-ignore */
90
+ ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
84
91
  this.panelClick = output();
85
- this.progress = computed(() => this.file().progress, ...(ngDevMode ? [{ debugName: "progress" }] : /* istanbul ignore next */ []));
86
- this.size = computed(() => formattedSize(this.file().size), ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
87
- this.color = computed(() => this.file().color ?? OnemrvaMatColor.NONE, ...(ngDevMode ? [{ debugName: "color" }] : /* istanbul ignore next */ []));
88
- this.isAccent = computed(() => this.color() === OnemrvaMatColor.ACCENT, ...(ngDevMode ? [{ debugName: "isAccent" }] : /* istanbul ignore next */ []));
89
- this.isError = computed(() => this.color() === OnemrvaMatColor.ERROR, ...(ngDevMode ? [{ debugName: "isError" }] : /* istanbul ignore next */ []));
90
- this.isWarn = computed(() => this.color() === OnemrvaMatColor.WARN, ...(ngDevMode ? [{ debugName: "isWarn" }] : /* istanbul ignore next */ []));
91
- this.isSuccess = computed(() => this.color() === OnemrvaMatColor.SUCCESS, ...(ngDevMode ? [{ debugName: "isSuccess" }] : /* istanbul ignore next */ []));
92
- this.isPrimary = computed(() => this.color() === OnemrvaMatColor.PRIMARY, ...(ngDevMode ? [{ debugName: "isPrimary" }] : /* istanbul ignore next */ []));
92
+ this.progress = computed(() => this.file().progress, /* @ts-ignore */
93
+ ...(ngDevMode ? [{ debugName: "progress" }] : /* istanbul ignore next */ []));
94
+ this.size = computed(() => formattedSize(this.file().size), /* @ts-ignore */
95
+ ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
96
+ this.color = computed(() => this.file().color ?? OnemrvaMatColor.NONE, /* @ts-ignore */
97
+ ...(ngDevMode ? [{ debugName: "color" }] : /* istanbul ignore next */ []));
98
+ this.isAccent = computed(() => this.color() === OnemrvaMatColor.ACCENT, /* @ts-ignore */
99
+ ...(ngDevMode ? [{ debugName: "isAccent" }] : /* istanbul ignore next */ []));
100
+ this.isError = computed(() => this.color() === OnemrvaMatColor.ERROR, /* @ts-ignore */
101
+ ...(ngDevMode ? [{ debugName: "isError" }] : /* istanbul ignore next */ []));
102
+ this.isWarn = computed(() => this.color() === OnemrvaMatColor.WARN, /* @ts-ignore */
103
+ ...(ngDevMode ? [{ debugName: "isWarn" }] : /* istanbul ignore next */ []));
104
+ this.isSuccess = computed(() => this.color() === OnemrvaMatColor.SUCCESS, /* @ts-ignore */
105
+ ...(ngDevMode ? [{ debugName: "isSuccess" }] : /* istanbul ignore next */ []));
106
+ this.isPrimary = computed(() => this.color() === OnemrvaMatColor.PRIMARY, /* @ts-ignore */
107
+ ...(ngDevMode ? [{ debugName: "isPrimary" }] : /* istanbul ignore next */ []));
93
108
  this.formattedSize = formattedSize;
94
109
  this.finalActions = computed(() => {
95
110
  if (this.disabled()) {
96
111
  return [];
97
112
  }
98
113
  return this.actions();
99
- }, ...(ngDevMode ? [{ debugName: "finalActions" }] : /* istanbul ignore next */ []));
114
+ }, /* @ts-ignore */
115
+ ...(ngDevMode ? [{ debugName: "finalActions" }] : /* istanbul ignore next */ []));
100
116
  }
101
117
  onActionClick(event, action) {
102
118
  event.stopPropagation();
@@ -108,10 +124,10 @@ class OnemrvaFilePanelComponent {
108
124
  }
109
125
  this.panelClick.emit(this.file());
110
126
  }
111
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaFilePanelComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
112
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.4", type: OnemrvaFilePanelComponent, isStandalone: true, selector: "file-panel", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, dataCy: { classPropertyName: "dataCy", publicName: "dataCy", isSignal: true, isRequired: false, transformFunction: null }, file: { classPropertyName: "file", publicName: "file", isSignal: true, isRequired: true, transformFunction: null }, actions: { classPropertyName: "actions", publicName: "actions", isSignal: true, isRequired: false, transformFunction: null }, showProgress: { classPropertyName: "showProgress", publicName: "showProgress", isSignal: true, isRequired: false, transformFunction: null }, displayDate: { classPropertyName: "displayDate", publicName: "displayDate", isSignal: true, isRequired: false, transformFunction: null }, maxFileSize: { classPropertyName: "maxFileSize", publicName: "maxFileSize", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { panelClick: "panelClick" }, host: { attributes: { "tabindex": "0" }, listeners: { "click": "onPanelClick()", "keydown.enter": "onPanelClick()", "keydown.space": "$event.preventDefault(); onPanelClick()" }, properties: { "attr.id": "id()", "attr.data-cy": "dataCy()", "class.mat-accent": "isAccent()", "class.mat-error": "isError()", "class.mat-warn": "isWarn()", "class.mat-success": "isSuccess()", "class.mat-primary": "isPrimary()", "class.disabled": "disabled()", "class.no-hover": "isError() || isWarn()" } }, ngImport: i0, template: "<div class=\"file-panel-title\" [attr.data-cy]=\"dataCy()\">\n <span class=\"file-name show-icon\">\n {{ file().name }}\n </span>\n <div class=\"file-panel-title-action\">\n @if (finalActions().length > 0) {\n @for (action of finalActions(); track action.dataCy) {\n <button\n mat-icon-button\n color=\"primary\"\n [tabindex]=\"0\"\n [attr.data-cy]=\"action.dataCy\"\n matTooltip=\"{{ action.tooltipCode | translate }}\"\n [attr.aria-label]=\"action.ariaLabel || (action.ariaCode | translate)\"\n (click)=\"onActionClick($event, action)\"\n (keydown.enter)=\"onActionClick($event, action)\"\n (keydown.space)=\"onActionClick($event, action)\"\n >\n <mat-icon>{{ action.iconName }}</mat-icon>\n </button>\n }\n }\n </div>\n</div>\n\n<ng-content>\n @if (displayDate()) {\n <div class=\"fileInfos\">\n <span>{{ displayDate() }}</span>\n\n @if (file().size > 0) {\n <span class=\"float-right\">{{ size() }}</span>\n }\n </div>\n @if (showProgress() && file().enableProgressBar) {\n <mat-progress-bar\n data-cy=\"file-upload-progress\"\n mode=\"determinate\"\n aria-label=\"progress\"\n [value]=\"progress()\"\n />\n }\n } @else if (file().message) {\n <p class=\"message\">\n {{ file().message | translate: { limit: formattedSize(file().maxSize) } }}\n </p>\n }\n</ng-content>\n", styles: [":host{flex:1 1 100%;-webkit-user-select:none;user-select:none;border-radius:var(--border-radius);background-color:var(--mat-sys-primary-container);border:1px solid var(--mat-sys-primary-container);padding:var(--double-spacer);display:flex;flex-direction:column}:host .file-panel-title{font:var(--mat-sys-title-medium);display:flex;flex-direction:row;justify-content:space-between;width:100%}:host .file-panel-title-action{display:flex;align-items:center;max-height:1em}:host .file-panel-title-action button{color:#6e68ae}:host .file-panel-content{padding:0}:host .file-panel-content p:last-child{margin:0}:host .fileInfos{display:inline-block;width:100%;height:1.5rem;font:var(--mat-sys-body-medium)}:host .fileInfos .float-right{margin-right:var(--spacer)}:host .file-panel-title{font:var(--mat-sys-title-medium);margin-bottom:0;color:var(--mat-sys-on-primary-container);display:flex;align-items:center}:host .file-panel-title .file-name{display:flex;align-items:center;gap:0 var(--spacer)}:host .file-panel-title:before{margin-right:var(--spacer);margin-top:var(--quarter-spacer)}:host .file-panel-title .mat-progress-bar-fill:after{background:var(--mat-sys-primary)}:host .file-panel-title .mat-progress-bar-buffer{background-color:var(--mat-sys-primary-container)}:host.disabled{opacity:.4}:host:hover:not(.disabled):not(.no-hover){border:1px solid var(--Surface-Outline-Variant, #d7d5ed);cursor:pointer}:host:hover:not(.disabled):not(.no-hover) .file-name{text-decoration:underline}\n"], dependencies: [{ kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i1.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
127
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaFilePanelComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
128
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.1", type: OnemrvaFilePanelComponent, isStandalone: true, selector: "file-panel", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, dataCy: { classPropertyName: "dataCy", publicName: "dataCy", isSignal: true, isRequired: false, transformFunction: null }, file: { classPropertyName: "file", publicName: "file", isSignal: true, isRequired: true, transformFunction: null }, actions: { classPropertyName: "actions", publicName: "actions", isSignal: true, isRequired: false, transformFunction: null }, showProgress: { classPropertyName: "showProgress", publicName: "showProgress", isSignal: true, isRequired: false, transformFunction: null }, displayDate: { classPropertyName: "displayDate", publicName: "displayDate", isSignal: true, isRequired: false, transformFunction: null }, maxFileSize: { classPropertyName: "maxFileSize", publicName: "maxFileSize", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { panelClick: "panelClick" }, host: { attributes: { "tabindex": "0" }, listeners: { "click": "onPanelClick()", "keydown.enter": "onPanelClick()", "keydown.space": "$event.preventDefault(); onPanelClick()" }, properties: { "attr.id": "id()", "attr.data-cy": "dataCy()", "class.mat-accent": "isAccent()", "class.mat-error": "isError()", "class.mat-warn": "isWarn()", "class.mat-success": "isSuccess()", "class.mat-primary": "isPrimary()", "class.disabled": "disabled()", "class.no-hover": "isError() || isWarn()" } }, ngImport: i0, template: "<div class=\"file-panel-title\" [attr.data-cy]=\"dataCy()\">\n <span class=\"file-name show-icon\">\n {{ file().name }}\n </span>\n <div class=\"file-panel-title-action\">\n @if (finalActions().length > 0) {\n @for (action of finalActions(); track action.dataCy) {\n <button\n mat-icon-button\n color=\"primary\"\n [tabindex]=\"0\"\n [attr.data-cy]=\"action.dataCy\"\n matTooltip=\"{{ action.tooltipCode | translate }}\"\n [attr.aria-label]=\"action.ariaLabel || (action.ariaCode | translate)\"\n (click)=\"onActionClick($event, action)\"\n (keydown.enter)=\"onActionClick($event, action)\"\n (keydown.space)=\"onActionClick($event, action)\"\n >\n <mat-icon>{{ action.iconName }}</mat-icon>\n </button>\n }\n }\n </div>\n</div>\n\n<ng-content>\n @if (displayDate()) {\n <div class=\"fileInfos\">\n <span>{{ displayDate() }}</span>\n\n @if (file().size > 0) {\n <span class=\"float-right\">{{ size() }}</span>\n }\n </div>\n @if (showProgress() && file().enableProgressBar) {\n <mat-progress-bar\n data-cy=\"file-upload-progress\"\n mode=\"determinate\"\n aria-label=\"progress\"\n [value]=\"progress()\"\n />\n }\n } @else if (file().message) {\n <p class=\"message\">\n {{ file().message | translate: { limit: formattedSize(file().maxSize) } }}\n </p>\n }\n</ng-content>\n", styles: [":host{flex:1 1 100%;-webkit-user-select:none;user-select:none;border-radius:var(--border-radius);background-color:var(--mat-sys-primary-container);border:1px solid var(--mat-sys-primary-container);padding:var(--double-spacer);display:flex;flex-direction:column}:host .file-panel-title{font:var(--mat-sys-title-medium);display:flex;flex-direction:row;justify-content:space-between;width:100%}:host .file-panel-title-action{display:flex;align-items:center;max-height:1em}:host .file-panel-title-action button{color:#6e68ae}:host .file-panel-content{padding:0}:host .file-panel-content p:last-child{margin:0}:host .fileInfos{display:inline-block;width:100%;height:1.5rem;font:var(--mat-sys-body-medium)}:host .fileInfos .float-right{margin-right:var(--spacer)}:host .file-panel-title{font:var(--mat-sys-title-medium);margin-bottom:0;color:var(--mat-sys-on-primary-container);display:flex;align-items:center}:host .file-panel-title .file-name{display:flex;align-items:center;gap:0 var(--spacer)}:host .file-panel-title:before{margin-right:var(--spacer);margin-top:var(--quarter-spacer)}:host .file-panel-title .mat-progress-bar-fill:after{background:var(--mat-sys-primary)}:host .file-panel-title .mat-progress-bar-buffer{background-color:var(--mat-sys-primary-container)}:host.disabled{opacity:.4}:host:hover:not(.disabled):not(.no-hover){border:1px solid var(--Surface-Outline-Variant, #d7d5ed);cursor:pointer}:host:hover:not(.disabled):not(.no-hover) .file-name{text-decoration:underline}\n"], dependencies: [{ kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i1.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
113
129
  }
114
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaFilePanelComponent, decorators: [{
130
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaFilePanelComponent, decorators: [{
115
131
  type: Component,
116
132
  args: [{ selector: 'file-panel', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [
117
133
  MatIcon,
@@ -171,10 +187,10 @@ class OnemrvaMatFileUploadService {
171
187
  alert(`Missing download implementation for file ID ${id}`);
172
188
  return of(true);
173
189
  }
174
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
175
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadService, providedIn: 'root' }); }
190
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
191
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadService, providedIn: 'root' }); }
176
192
  }
177
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadService, decorators: [{
193
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadService, decorators: [{
178
194
  type: Injectable,
179
195
  args: [{
180
196
  providedIn: 'root',
@@ -480,16 +496,17 @@ class OnemrvaMatFileUploadStore extends ComponentStore {
480
496
  if (this.customValidationFn)
481
497
  this.fn = this.customValidationFn;
482
498
  }
483
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadStore, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
484
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadStore }); }
499
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadStore, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
500
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadStore }); }
485
501
  }
486
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadStore, decorators: [{
502
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadStore, decorators: [{
487
503
  type: Injectable
488
504
  }], ctorParameters: () => [] });
489
505
 
490
506
  class DndDirective {
491
507
  constructor() {
492
- this.fileOver = signal(false, ...(ngDevMode ? [{ debugName: "fileOver" }] : /* istanbul ignore next */ []));
508
+ this.fileOver = signal(false, /* @ts-ignore */
509
+ ...(ngDevMode ? [{ debugName: "fileOver" }] : /* istanbul ignore next */ []));
493
510
  this.fileDropped = output();
494
511
  }
495
512
  // Dragover listener
@@ -514,10 +531,10 @@ class DndDirective {
514
531
  this.fileDropped.emit(files);
515
532
  }
516
533
  }
517
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: DndDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
518
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.4", type: DndDirective, isStandalone: true, selector: "[appDnd]", outputs: { fileDropped: "fileDropped" }, host: { listeners: { "dragover": "onDragOver($event)", "dragleave": "onDragLeave($event)", "drop": "ondrop($event)" }, properties: { "class.fileover": "fileOver()" } }, ngImport: i0 }); }
534
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: DndDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
535
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.1", type: DndDirective, isStandalone: true, selector: "[appDnd]", outputs: { fileDropped: "fileDropped" }, host: { listeners: { "dragover": "onDragOver($event)", "dragleave": "onDragLeave($event)", "drop": "ondrop($event)" }, properties: { "class.fileover": "fileOver()" } }, ngImport: i0 }); }
519
536
  }
520
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: DndDirective, decorators: [{
537
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: DndDirective, decorators: [{
521
538
  type: Directive,
522
539
  args: [{
523
540
  selector: '[appDnd]',
@@ -538,16 +555,26 @@ let NEXT_ID = 0;
538
555
  // TODO: Multiple customisable error messages (custom validators)
539
556
  class OnemrvaMatFileUploadComponent {
540
557
  constructor() {
541
- this.accept = input([], ...(ngDevMode ? [{ debugName: "accept" }] : /* istanbul ignore next */ []));
542
- this.maxFileSize = input(0, ...(ngDevMode ? [{ debugName: "maxFileSize" }] : /* istanbul ignore next */ []));
543
- this.numberOfFiles = input(0, ...(ngDevMode ? [{ debugName: "numberOfFiles" }] : /* istanbul ignore next */ []));
544
- this.maxTotalFileSize = input(0, ...(ngDevMode ? [{ debugName: "maxTotalFileSize" }] : /* istanbul ignore next */ []));
545
- this.uploadOnDrop = input(true, ...(ngDevMode ? [{ debugName: "uploadOnDrop" }] : /* istanbul ignore next */ []));
546
- this.initialFiles = input([], ...(ngDevMode ? [{ debugName: "initialFiles" }] : /* istanbul ignore next */ []));
547
- this.errorMessage = input('', ...(ngDevMode ? [{ debugName: "errorMessage" }] : /* istanbul ignore next */ []));
548
- this.hideExtensions = input([], ...(ngDevMode ? [{ debugName: "hideExtensions" }] : /* istanbul ignore next */ []));
549
- this.dropFilesHereTextTranslationKey = input('file.upload.drag.and.drop', ...(ngDevMode ? [{ debugName: "dropFilesHereTextTranslationKey" }] : /* istanbul ignore next */ []));
550
- this.filePanelTemplate = input.required(...(ngDevMode ? [{ debugName: "filePanelTemplate" }] : /* istanbul ignore next */ []));
558
+ this.accept = input([], /* @ts-ignore */
559
+ ...(ngDevMode ? [{ debugName: "accept" }] : /* istanbul ignore next */ []));
560
+ this.maxFileSize = input(0, /* @ts-ignore */
561
+ ...(ngDevMode ? [{ debugName: "maxFileSize" }] : /* istanbul ignore next */ []));
562
+ this.numberOfFiles = input(0, /* @ts-ignore */
563
+ ...(ngDevMode ? [{ debugName: "numberOfFiles" }] : /* istanbul ignore next */ []));
564
+ this.maxTotalFileSize = input(0, /* @ts-ignore */
565
+ ...(ngDevMode ? [{ debugName: "maxTotalFileSize" }] : /* istanbul ignore next */ []));
566
+ this.uploadOnDrop = input(true, /* @ts-ignore */
567
+ ...(ngDevMode ? [{ debugName: "uploadOnDrop" }] : /* istanbul ignore next */ []));
568
+ this.initialFiles = input([], /* @ts-ignore */
569
+ ...(ngDevMode ? [{ debugName: "initialFiles" }] : /* istanbul ignore next */ []));
570
+ this.errorMessage = input('', /* @ts-ignore */
571
+ ...(ngDevMode ? [{ debugName: "errorMessage" }] : /* istanbul ignore next */ []));
572
+ this.hideExtensions = input([], /* @ts-ignore */
573
+ ...(ngDevMode ? [{ debugName: "hideExtensions" }] : /* istanbul ignore next */ []));
574
+ this.dropFilesHereTextTranslationKey = input('file.upload.drag.and.drop', /* @ts-ignore */
575
+ ...(ngDevMode ? [{ debugName: "dropFilesHereTextTranslationKey" }] : /* istanbul ignore next */ []));
576
+ this.filePanelTemplate = input.required(/* @ts-ignore */
577
+ ...(ngDevMode ? [{ debugName: "filePanelTemplate" }] : /* istanbul ignore next */ []));
551
578
  this.retryFile = new EventEmitter();
552
579
  /**
553
580
  * Sets the `data-cy` of the element. If not set, the first component instance will have `data-cy` = `"onemrva-mat-multi-select-0"`.
@@ -565,7 +592,8 @@ class OnemrvaMatFileUploadComponent {
565
592
  * <onemrva-mat-multi-select id="my-first-multi-select"></onemrva-mat-multi-select>
566
593
  * ```
567
594
  */
568
- this.dataCy = input(`onemrva-mat-multi-select-${NEXT_ID++}`, ...(ngDevMode ? [{ debugName: "dataCy" }] : /* istanbul ignore next */ []));
595
+ this.dataCy = input(`onemrva-mat-multi-select-${NEXT_ID++}`, /* @ts-ignore */
596
+ ...(ngDevMode ? [{ debugName: "dataCy" }] : /* istanbul ignore next */ []));
569
597
  this.fileDropRef = viewChild.required(`fileDropRef`);
570
598
  this.inputId = `fileDropRef-${NEXT_ID}`;
571
599
  this.maxFileSizeFormatted = '';
@@ -650,56 +678,12 @@ class OnemrvaMatFileUploadComponent {
650
678
  this.fileDropRef().nativeElement.value = null;
651
679
  });
652
680
  }
653
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
654
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.4", type: OnemrvaMatFileUploadComponent, isStandalone: true, selector: "onemrva-mat-file-upload", inputs: { accept: { classPropertyName: "accept", publicName: "accept", isSignal: true, isRequired: false, transformFunction: null }, maxFileSize: { classPropertyName: "maxFileSize", publicName: "maxFileSize", isSignal: true, isRequired: false, transformFunction: null }, numberOfFiles: { classPropertyName: "numberOfFiles", publicName: "numberOfFiles", isSignal: true, isRequired: false, transformFunction: null }, maxTotalFileSize: { classPropertyName: "maxTotalFileSize", publicName: "maxTotalFileSize", isSignal: true, isRequired: false, transformFunction: null }, uploadOnDrop: { classPropertyName: "uploadOnDrop", publicName: "uploadOnDrop", isSignal: true, isRequired: false, transformFunction: null }, initialFiles: { classPropertyName: "initialFiles", publicName: "initialFiles", isSignal: true, isRequired: false, transformFunction: null }, errorMessage: { classPropertyName: "errorMessage", publicName: "errorMessage", isSignal: true, isRequired: false, transformFunction: null }, hideExtensions: { classPropertyName: "hideExtensions", publicName: "hideExtensions", isSignal: true, isRequired: false, transformFunction: null }, dropFilesHereTextTranslationKey: { classPropertyName: "dropFilesHereTextTranslationKey", publicName: "dropFilesHereTextTranslationKey", isSignal: true, isRequired: false, transformFunction: null }, filePanelTemplate: { classPropertyName: "filePanelTemplate", publicName: "filePanelTemplate", isSignal: true, isRequired: true, transformFunction: null }, dataCy: { classPropertyName: "dataCy", publicName: "dataCy", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.data-cy": "dataCy()" } }, viewQueries: [{ propertyName: "fileDropRef", first: true, predicate: ["fileDropRef"], descendants: true, isSignal: true }], ngImport: i0, template: "@if (files$ | async; as files) {\n <div\n class=\"onemrva-mat-file-upload-drop-area\"\n appDnd\n (fileDropped)=\"onFileDropped($event)\"\n [class.filein]=\"files.length > 0\"\n >\n <input\n type=\"file\"\n #fileDropRef\n [attr.id]=\"inputId\"\n role=\"button\"\n multiple\n (change)=\"fileBrowseHandler($event)\"\n accept=\"{{ acceptString$ | async }}\"\n />\n @if (numberOfFiles() === 0 || numberOfFiles() > files.length) {\n <div class=\"download-outer\">\n <div class=\"download-icon\">\n <mat-icon class=\"onemrva-upload xxlarge\">download</mat-icon>\n </div>\n\n <div class=\"download-text\">\n {{ dropFilesHereTextTranslationKey() | translate }}\n {{ 'file.upload.or' | translate }}\n <label for=\"{{ inputId }}\" class=\"content\">\n {{ 'file.upload.browse.for.file' | translate }} </label\n ><br />\n @if (maxFileSize() > 0) {\n <span class=\"restrictions\">\n {{ 'file.upload.maximum' | translate }}\n {{ maxFileSizeFormatted }}\n\n @if (accept().length > 0) {\n <span>{{ '| ' }}</span>\n }\n\n {{ acceptString$ | async }}\n </span>\n }\n </div>\n </div>\n }\n <ul class=\"files-list\">\n @for (file of files; track file.id) {\n <li>\n <ng-container\n *ngTemplateOutlet=\"\n filePanelTemplate();\n context: { file, $implicit: file }\n \"\n />\n </li>\n }\n </ul>\n </div>\n @if (fileUploadErrorMessage$ | async; as fileUploadErrorMessage) {\n <mat-error>\n {{\n fileUploadErrorMessage\n | translate\n : {\n limit: numberOfFiles(),\n maxTotalFileSize: formattedSize(maxTotalFileSize()),\n }\n }}\n @if (errorMessage() !== '') {\n [ {{ errorMessage() }} ]\n }\n </mat-error>\n }\n}\n", styles: [":host .mat-mdc-form-field-error{margin-bottom:var(--spacer);padding:var(--spacer) 1em;background-color:var(--mat-sys-error-container);color:var(--mat-sys-on-error-container);border-bottom:1px solid var(--mat-sys-error);display:flex;line-height:1.125rem}:host .mat-mdc-form-field-error:before{font-family:var(--icon-font);content:\"\\e000\";float:left;font-size:1rem;font-variation-settings:\"FILL\" 1;margin-right:var(--spacer);vertical-align:baseline;flex:0 0 var(--double-spacer)}:host ul{list-style:none;margin-block-start:0;margin-block-end:0;margin-inline-start:0;margin-inline-end:0;padding-inline-start:0}:host ul li{width:100%}:host .onemrva-mat-file-upload-drop-area{padding:var(--triple-spacer);text-align:left;border:dashed 2px var(--mat-sys-outline);position:relative;border-radius:var(--border-radius);transition:background-color .3s ease-in-out,border .3s ease-in-out}:host .onemrva-mat-file-upload-drop-area mat-icon{color:var(--mat-sys-primary)}:host .onemrva-mat-file-upload-drop-area.fu-error{border:dashed 2px var(--mat-sys-error)}:host .onemrva-mat-file-upload-drop-area input[type=file]{display:none}:host .onemrva-mat-file-upload-drop-area .download-outer{display:flex;width:100%;margin:0}:host .onemrva-mat-file-upload-drop-area .download-outer .download-icon{padding-right:var(--double-spacer)}:host .onemrva-mat-file-upload-drop-area .download-outer .download-text label{display:block;color:var(--mat-sys-primary);text-decoration:underline;cursor:pointer;font-weight:700}:host .onemrva-mat-file-upload-drop-area .download-outer .download-text .restrictions{display:block;color:var(--mat-sys-on-surface-variant);margin-bottom:0}:host .onemrva-mat-file-upload-drop-area.filein .download-outer{margin:0 0 var(--triple-spacer) 0}:host .onemrva-mat-file-upload-drop-area.fileover{background:var(--mat-sys-primary-container);border:2px dashed var(--mat-sys-primary)}:host .onemrva-mat-file-upload-drop-area .files-list{display:flex;flex-flow:row wrap;gap:var(--double-spacer)}\n"], dependencies: [{ kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: DndDirective, selector: "[appDnd]", outputs: ["fileDropped"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: TranslatePipe, name: "translate" }], animations: [
655
- trigger('inOutAnimation', [
656
- state('in', style({ opacity: 1 })),
657
- transition(':enter', [
658
- animate(300, keyframes([
659
- style({ opacity: 0, offset: 0 }),
660
- style({ opacity: 0.25, offset: 0.25 }),
661
- style({ opacity: 0.5, offset: 0.5 }),
662
- style({ opacity: 0.75, offset: 0.75 }),
663
- style({ opacity: 1, offset: 1 }),
664
- ])),
665
- ]),
666
- transition(':leave', [
667
- animate(300, keyframes([
668
- style({ opacity: 1, offset: 0 }),
669
- style({ opacity: 0.75, offset: 0.25 }),
670
- style({ opacity: 0.5, offset: 0.5 }),
671
- style({ opacity: 0.25, offset: 0.75 }),
672
- style({ opacity: 0, offset: 1 }),
673
- ])),
674
- ]),
675
- ]),
676
- ] }); }
681
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
682
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.1", type: OnemrvaMatFileUploadComponent, isStandalone: true, selector: "onemrva-mat-file-upload", inputs: { accept: { classPropertyName: "accept", publicName: "accept", isSignal: true, isRequired: false, transformFunction: null }, maxFileSize: { classPropertyName: "maxFileSize", publicName: "maxFileSize", isSignal: true, isRequired: false, transformFunction: null }, numberOfFiles: { classPropertyName: "numberOfFiles", publicName: "numberOfFiles", isSignal: true, isRequired: false, transformFunction: null }, maxTotalFileSize: { classPropertyName: "maxTotalFileSize", publicName: "maxTotalFileSize", isSignal: true, isRequired: false, transformFunction: null }, uploadOnDrop: { classPropertyName: "uploadOnDrop", publicName: "uploadOnDrop", isSignal: true, isRequired: false, transformFunction: null }, initialFiles: { classPropertyName: "initialFiles", publicName: "initialFiles", isSignal: true, isRequired: false, transformFunction: null }, errorMessage: { classPropertyName: "errorMessage", publicName: "errorMessage", isSignal: true, isRequired: false, transformFunction: null }, hideExtensions: { classPropertyName: "hideExtensions", publicName: "hideExtensions", isSignal: true, isRequired: false, transformFunction: null }, dropFilesHereTextTranslationKey: { classPropertyName: "dropFilesHereTextTranslationKey", publicName: "dropFilesHereTextTranslationKey", isSignal: true, isRequired: false, transformFunction: null }, filePanelTemplate: { classPropertyName: "filePanelTemplate", publicName: "filePanelTemplate", isSignal: true, isRequired: true, transformFunction: null }, dataCy: { classPropertyName: "dataCy", publicName: "dataCy", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.data-cy": "dataCy()" } }, viewQueries: [{ propertyName: "fileDropRef", first: true, predicate: ["fileDropRef"], descendants: true, isSignal: true }], ngImport: i0, template: "@if (files$ | async; as files) {\n <div\n class=\"onemrva-mat-file-upload-drop-area\"\n appDnd\n (fileDropped)=\"onFileDropped($event)\"\n [class.filein]=\"files.length > 0\"\n >\n <input\n type=\"file\"\n #fileDropRef\n [attr.id]=\"inputId\"\n role=\"button\"\n multiple\n (change)=\"fileBrowseHandler($event)\"\n accept=\"{{ acceptString$ | async }}\"\n />\n @if (numberOfFiles() === 0 || numberOfFiles() > files.length) {\n <div class=\"download-outer\">\n <div class=\"download-icon\">\n <mat-icon class=\"onemrva-upload xxlarge\">download</mat-icon>\n </div>\n\n <div class=\"download-text\">\n {{ dropFilesHereTextTranslationKey() | translate }}\n {{ 'file.upload.or' | translate }}\n <label for=\"{{ inputId }}\" class=\"content\">\n {{ 'file.upload.browse.for.file' | translate }} </label\n ><br />\n @if (maxFileSize() > 0) {\n <span class=\"restrictions\">\n {{ 'file.upload.maximum' | translate }}\n {{ maxFileSizeFormatted }}\n\n @if (accept().length > 0) {\n <span>{{ '| ' }}</span>\n }\n\n {{ acceptString$ | async }}\n </span>\n }\n </div>\n </div>\n }\n <ul class=\"files-list\">\n @for (file of files; track file.id) {\n <li>\n <ng-container\n *ngTemplateOutlet=\"\n filePanelTemplate();\n context: { file, $implicit: file }\n \"\n />\n </li>\n }\n </ul>\n </div>\n @if (fileUploadErrorMessage$ | async; as fileUploadErrorMessage) {\n <mat-error>\n {{\n fileUploadErrorMessage\n | translate\n : {\n limit: numberOfFiles(),\n maxTotalFileSize: formattedSize(maxTotalFileSize()),\n }\n }}\n @if (errorMessage() !== '') {\n [ {{ errorMessage() }} ]\n }\n </mat-error>\n }\n}\n", styles: [":host .mat-mdc-form-field-error{margin-bottom:var(--spacer);padding:var(--spacer) 1em;background-color:var(--mat-sys-error-container);color:var(--mat-sys-on-error-container);border-bottom:1px solid var(--mat-sys-error);display:flex;line-height:1.125rem}:host .mat-mdc-form-field-error:before{font-family:var(--icon-font);content:\"\\e000\";float:left;font-size:1rem;font-variation-settings:\"FILL\" 1;margin-right:var(--spacer);vertical-align:baseline;flex:0 0 var(--double-spacer)}:host ul{list-style:none;margin-block-start:0;margin-block-end:0;margin-inline-start:0;margin-inline-end:0;padding-inline-start:0}:host ul li{width:100%}:host .onemrva-mat-file-upload-drop-area{padding:var(--triple-spacer);text-align:left;border:dashed 2px var(--mat-sys-outline);position:relative;border-radius:var(--border-radius);transition:background-color .3s ease-in-out,border .3s ease-in-out}:host .onemrva-mat-file-upload-drop-area mat-icon{color:var(--mat-sys-primary)}:host .onemrva-mat-file-upload-drop-area.fu-error{border:dashed 2px var(--mat-sys-error)}:host .onemrva-mat-file-upload-drop-area input[type=file]{display:none}:host .onemrva-mat-file-upload-drop-area .download-outer{display:flex;width:100%;margin:0}:host .onemrva-mat-file-upload-drop-area .download-outer .download-icon{padding-right:var(--double-spacer)}:host .onemrva-mat-file-upload-drop-area .download-outer .download-text label{display:block;color:var(--mat-sys-primary);text-decoration:underline;cursor:pointer;font-weight:700}:host .onemrva-mat-file-upload-drop-area .download-outer .download-text .restrictions{display:block;color:var(--mat-sys-on-surface-variant);margin-bottom:0}:host .onemrva-mat-file-upload-drop-area.filein .download-outer{margin:0 0 var(--triple-spacer) 0}:host .onemrva-mat-file-upload-drop-area.fileover{background:var(--mat-sys-primary-container);border:2px dashed var(--mat-sys-primary)}:host .onemrva-mat-file-upload-drop-area .files-list{display:flex;flex-flow:row wrap;gap:var(--double-spacer)}\n"], dependencies: [{ kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: DndDirective, selector: "[appDnd]", outputs: ["fileDropped"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
677
683
  }
678
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadComponent, decorators: [{
684
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadComponent, decorators: [{
679
685
  type: Component,
680
- args: [{ selector: 'onemrva-mat-file-upload', standalone: true, animations: [
681
- trigger('inOutAnimation', [
682
- state('in', style({ opacity: 1 })),
683
- transition(':enter', [
684
- animate(300, keyframes([
685
- style({ opacity: 0, offset: 0 }),
686
- style({ opacity: 0.25, offset: 0.25 }),
687
- style({ opacity: 0.5, offset: 0.5 }),
688
- style({ opacity: 0.75, offset: 0.75 }),
689
- style({ opacity: 1, offset: 1 }),
690
- ])),
691
- ]),
692
- transition(':leave', [
693
- animate(300, keyframes([
694
- style({ opacity: 1, offset: 0 }),
695
- style({ opacity: 0.75, offset: 0.25 }),
696
- style({ opacity: 0.5, offset: 0.5 }),
697
- style({ opacity: 0.25, offset: 0.75 }),
698
- style({ opacity: 0, offset: 1 }),
699
- ])),
700
- ]),
701
- ]),
702
- ], imports: [
686
+ args: [{ selector: 'onemrva-mat-file-upload', standalone: true, imports: [
703
687
  AsyncPipe,
704
688
  MatIcon,
705
689
  TranslatePipe,
@@ -717,27 +701,27 @@ const components = [
717
701
  ];
718
702
 
719
703
  class OnemrvaMatFileUploadModule {
720
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
721
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadModule, imports: [OnemrvaFilePanelComponent, OnemrvaMatFileUploadComponent, DndDirective,
704
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
705
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadModule, imports: [OnemrvaFilePanelComponent, OnemrvaMatFileUploadComponent, DndDirective,
722
706
  CommonModule,
723
707
  ReactiveFormsModule,
724
708
  MatButtonModule,
725
709
  MatTooltipModule,
726
710
  MatDialogModule,
727
- TranslateModule,
711
+ TranslatePipe,
712
+ TranslateDirective,
728
713
  MatIconModule,
729
714
  MatInputModule], exports: [OnemrvaFilePanelComponent, OnemrvaMatFileUploadComponent, DndDirective] }); }
730
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadModule, providers: [OnemrvaMatFileUploadStore, OnemrvaMatFileUploadService], imports: [components,
715
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadModule, providers: [OnemrvaMatFileUploadStore, OnemrvaMatFileUploadService], imports: [components,
731
716
  CommonModule,
732
717
  ReactiveFormsModule,
733
718
  MatButtonModule,
734
719
  MatTooltipModule,
735
720
  MatDialogModule,
736
- TranslateModule,
737
721
  MatIconModule,
738
722
  MatInputModule] }); }
739
723
  }
740
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OnemrvaMatFileUploadModule, decorators: [{
724
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: OnemrvaMatFileUploadModule, decorators: [{
741
725
  type: NgModule,
742
726
  args: [{
743
727
  declarations: [],
@@ -749,7 +733,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImpor
749
733
  MatButtonModule,
750
734
  MatTooltipModule,
751
735
  MatDialogModule,
752
- TranslateModule,
736
+ TranslatePipe,
737
+ TranslateDirective,
753
738
  MatIconModule,
754
739
  MatInputModule,
755
740
  ],