@dsivd/prestations-ng 19.2.0-beta.28 → 19.2.0-beta.29

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.
@@ -161,29 +161,95 @@ const classDeclarationsOf = (sourceFile, className) =>
161
161
  const isBarrelMiss = (className, classDeclarations) =>
162
162
  Boolean(className) && classDeclarations.length === 0;
163
163
 
164
- const collectFromReExports = (sourceFile, path, className, kinds, visited) => {
164
+ const collectFromReExports = (sourceFile, path, className, members, visited) => {
165
165
  for (const specifier of reExportedModulesOf(sourceFile)) {
166
166
  const target = resolveModule(specifier, path);
167
167
  if (target) {
168
- collect(target, className, kinds, visited);
168
+ collect(target, className, members, visited);
169
169
  }
170
170
  }
171
171
  };
172
172
 
173
- const addMemberKindIfEligible = (member, kinds) => {
173
+ // TypeScript wrappers that leave the value as is: `this.form()!`, `this.form() as Form`...
174
+ const isValueWrapper = (node) =>
175
+ ts.isParenthesizedExpression(node) ||
176
+ ts.isNonNullExpression(node) ||
177
+ ts.isAsExpression(node) ||
178
+ ts.isSatisfiesExpression(node) ||
179
+ ts.isTypeAssertionExpression(node);
180
+
181
+ /**
182
+ * What the expression returned by a getter is rooted at, the property and index reads and
183
+ * the type wrappers stripped away: the read of a member of the class without arguments
184
+ * (`{ call: "form" }` for `this.form()!.step`), or a member read as is (`{ member: "step" }`
185
+ * for `this.step.motif`, another getter maybe). `undefined` for anything else: a
186
+ * computation, a copy or a call with arguments returns a value of its own.
187
+ */
188
+ const returnedRootOf = (expression) => {
189
+ let current = expression;
190
+ for (;;) {
191
+ if (isValueWrapper(current)) {
192
+ current = current.expression;
193
+ } else if (
194
+ ts.isPropertyAccessExpression(current) ||
195
+ ts.isElementAccessExpression(current)
196
+ ) {
197
+ if (current.expression.kind === ts.SyntaxKind.ThisKeyword) {
198
+ return ts.isPropertyAccessExpression(current) &&
199
+ ts.isIdentifier(current.name)
200
+ ? { member: current.name.text }
201
+ : undefined;
202
+ }
203
+ current = current.expression;
204
+ } else {
205
+ break;
206
+ }
207
+ }
208
+ const callee = ts.isCallExpression(current) ? current.expression : undefined;
209
+ return callee &&
210
+ current.arguments.length === 0 &&
211
+ ts.isPropertyAccessExpression(callee) &&
212
+ callee.expression.kind === ts.SyntaxKind.ThisKeyword &&
213
+ ts.isIdentifier(callee.name)
214
+ ? { call: callee.name.text }
215
+ : undefined;
216
+ };
217
+
218
+ // The expression a getter returns, when its body is a single `return` statement.
219
+ const returnedExpressionOf = (getter) => {
220
+ const statements = getter.body?.statements;
221
+ const statement = statements?.length === 1 ? statements[0] : undefined;
222
+ return statement && ts.isReturnStatement(statement)
223
+ ? statement.expression
224
+ : undefined;
225
+ };
226
+
227
+ const addMemberIfEligible = (member, { kinds, getters }) => {
174
228
  if (!member.name || !ts.isIdentifier(member.name)) {
175
229
  return;
176
230
  }
177
- const kind = kindOfMember(member);
231
+ const name = member.name.text;
178
232
  // A subclass overriding a member wins: it is collected first.
179
- if (kind && !kinds.has(member.name.text)) {
180
- kinds.set(member.name.text, kind);
233
+ if (kinds.has(name) || getters.has(name)) {
234
+ return;
235
+ }
236
+ const kind = kindOfMember(member);
237
+ if (kind) {
238
+ kinds.set(name, kind);
239
+ return;
240
+ }
241
+ const returned = ts.isGetAccessor(member)
242
+ ? returnedExpressionOf(member)
243
+ : undefined;
244
+ // Recorded even when it returns something else: it overrides the getter of a base class.
245
+ if (ts.isGetAccessor(member)) {
246
+ getters.set(name, returned ? returnedRootOf(returned) : undefined);
181
247
  }
182
248
  };
183
249
 
184
- const collectMemberKinds = (classDeclaration, kinds) => {
250
+ const collectMembers = (classDeclaration, members) => {
185
251
  for (const member of classDeclaration.members) {
186
- addMemberKindIfEligible(member, kinds);
252
+ addMemberIfEligible(member, members);
187
253
  }
188
254
  };
189
255
 
@@ -207,14 +273,14 @@ const baseTargetOf = (sourceFile, path, classDeclaration) => {
207
273
  return target ? { path: target, className: imported.exportedName } : undefined;
208
274
  };
209
275
 
210
- const collectBase = (sourceFile, path, classDeclaration, kinds, visited) => {
276
+ const collectBase = (sourceFile, path, classDeclaration, members, visited) => {
211
277
  const target = baseTargetOf(sourceFile, path, classDeclaration);
212
278
  if (target) {
213
- collect(target.path, target.className, kinds, visited);
279
+ collect(target.path, target.className, members, visited);
214
280
  }
215
281
  };
216
282
 
217
- const collect = (path, className, kinds, visited) => {
283
+ const collect = (path, className, members, visited) => {
218
284
  const key = `${path}::${className ?? "*"}`;
219
285
  if (visited.has(key)) {
220
286
  return;
@@ -230,27 +296,67 @@ const collect = (path, className, kinds, visited) => {
230
296
 
231
297
  // A barrel: the class is only re-exported from here.
232
298
  if (isBarrelMiss(className, classDeclarations)) {
233
- collectFromReExports(sourceFile, path, className, kinds, visited);
299
+ collectFromReExports(sourceFile, path, className, members, visited);
234
300
  return;
235
301
  }
236
302
 
237
303
  for (const classDeclaration of classDeclarations) {
238
- collectMemberKinds(classDeclaration, kinds);
239
- collectBase(sourceFile, path, classDeclaration, kinds, visited);
304
+ collectMembers(classDeclaration, members);
305
+ collectBase(sourceFile, path, classDeclaration, members, visited);
306
+ }
307
+ };
308
+
309
+ const collectAll = (componentPath) => {
310
+ if (!parseFile(componentPath)) {
311
+ return undefined;
312
+ }
313
+ const members = { kinds: new Map(), getters: new Map() };
314
+ collect(componentPath, undefined, members, new Set());
315
+ return members;
316
+ };
317
+
318
+ /**
319
+ * The getters returning the value of a signal of the class, or a part of it: `get step()
320
+ * { return this.form()!.step; }`, or another such getter read further (`this.step.motif`).
321
+ * Mapped to the signal and its kind. Mutating what they return mutates the value of the
322
+ * signal.
323
+ */
324
+ const resolveAliases = ({ kinds, getters }) => {
325
+ const aliases = new Map();
326
+ let added = true;
327
+ while (added) {
328
+ added = false;
329
+ for (const [name, root] of getters) {
330
+ if (aliases.has(name) || !root) {
331
+ continue;
332
+ }
333
+ const alias = root.call
334
+ ? kinds.has(root.call) && { signal: root.call, kind: kinds.get(root.call) }
335
+ : aliases.get(root.member);
336
+ if (alias) {
337
+ aliases.set(name, alias);
338
+ added = true;
339
+ }
340
+ }
240
341
  }
342
+ return aliases;
241
343
  };
242
344
 
243
345
  /**
244
346
  * Signal members of a component, mapped to their kind. `undefined` when the file
245
347
  * cannot be read: unknown signals must be distinguished from a component that has none.
246
348
  */
247
- export const collectSignalKinds = (componentPath) => {
248
- if (!parseFile(componentPath)) {
249
- return undefined;
250
- }
251
- const kinds = new Map();
252
- collect(componentPath, undefined, kinds, new Set());
253
- return kinds;
349
+ export const collectSignalKinds = (componentPath) =>
350
+ collectAll(componentPath)?.kinds;
351
+
352
+ /**
353
+ * Getters of a component aliasing the value of one of its signals, mapped to
354
+ * `{ signal, kind }`, walking up its inheritance chain. `undefined` when the file cannot be
355
+ * read.
356
+ */
357
+ export const collectSignalAliases = (componentPath) => {
358
+ const members = collectAll(componentPath);
359
+ return members && resolveAliases(members);
254
360
  };
255
361
 
256
362
  export const collectSignalNames = (componentPath) =>
@@ -754,6 +754,48 @@ class ScrollHelper {
754
754
  }
755
755
  }
756
756
 
757
+ const LIST_ITEM_PATH = /^(?<listPath>.+)\[(?<index>\d+)\]$/;
758
+ class FormErrorHelper {
759
+ /**
760
+ * The errors left once the item at `itemPath` (e.g. `exchanges[1]`) is removed from its list: its errors are
761
+ * dropped, and those of the following items take their new index (`exchanges[2].date` becomes `exchanges[1].date`).
762
+ *
763
+ * @returns a new array, the given errors aren't modified
764
+ */
765
+ static withoutListItem(errors, itemPath) {
766
+ const item = LIST_ITEM_PATH.exec(itemPath)?.groups;
767
+ if (!item) {
768
+ const ofObject = FormErrorHelper.pathPattern(itemPath, '');
769
+ return errors.filter((error) => !ofObject.test(error.name));
770
+ }
771
+ const { listPath } = item;
772
+ const removedIndex = Number(item.index);
773
+ const itemOfList = FormErrorHelper.pathPattern(listPath, '\\[(?<index>\\d+)\\]');
774
+ return errors.flatMap((error) => {
775
+ const errorItem = itemOfList.exec(error.name);
776
+ if (!errorItem?.groups) {
777
+ return [error];
778
+ }
779
+ const index = Number(errorItem.groups.index);
780
+ if (index === removedIndex) {
781
+ return [];
782
+ }
783
+ if (index < removedIndex) {
784
+ return [error];
785
+ }
786
+ const fieldPath = error.name.slice(errorItem[0].length);
787
+ return [
788
+ { ...error, name: `${listPath}[${index - 1}]${fieldPath}` },
789
+ ];
790
+ });
791
+ }
792
+ // Followed by nothing, a field or an index: `items` matches `items[0]` and `items.name`, not `itemsTotal`
793
+ static pathPattern(path, suffix) {
794
+ const escaped = path.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
795
+ return new RegExp(`^${escaped}${suffix}(?=$|[.[])`);
796
+ }
797
+ }
798
+
757
799
  class ValidationHandlerService {
758
800
  _validationErrorsSubject = new BehaviorSubject([]);
759
801
  _validationDisplaySubject = new BehaviorSubject(true);
@@ -766,6 +808,15 @@ class ValidationHandlerService {
766
808
  updateErrors(errors) {
767
809
  this._validationErrorsSubject.next(errors);
768
810
  }
811
+ /**
812
+ * Removes the errors of the item at `itemPath` (e.g. `exchanges[1]`) and gives those of the following items their
813
+ * new index, as `FormErrorHelper.withoutListItem()`. For a page keeping the errors of the server until its next
814
+ * save (e.g. a back office) when it removes an item of a list whose fields are named with the index. The errors of
815
+ * `GesdemHandlerService.lastResponse` aren't changed.
816
+ */
817
+ removeListItemErrors(itemPath) {
818
+ this._validationErrorsSubject.next(FormErrorHelper.withoutListItem(this._validationErrorsSubject.value, itemPath));
819
+ }
769
820
  shouldDisplayErrors(display) {
770
821
  this._validationDisplaySubject.next(display);
771
822
  }
@@ -16108,6 +16159,10 @@ class FoehnAgendaTimeslotPanelComponent extends FoehnInputComponent {
16108
16159
  return `${s.charAt(0).toUpperCase()}${s.slice(1)}`;
16109
16160
  }
16110
16161
  handleUserInput(day, date, time, calendar) {
16162
+ // A slot still focused when the panel is disabled can be "clicked" with the keyboard (onKeyDownInner)
16163
+ if (this.disabled()) {
16164
+ return;
16165
+ }
16111
16166
  const validValue = this.getValidValue(day, date, time, calendar);
16112
16167
  if (validValue !== undefined) {
16113
16168
  this.userInput.emit(validValue);
@@ -16237,7 +16292,7 @@ class FoehnAgendaTimeslotPanelComponent extends FoehnInputComponent {
16237
16292
  provide: FoehnInputComponent,
16238
16293
  useExisting: forwardRef(() => FoehnAgendaTimeslotPanelComponent),
16239
16294
  },
16240
- ], viewQueries: [{ propertyName: "timeSlotButtonsElemRef", predicate: ["timeSlotButtonsElemRef"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "@if (calendar() | async; as loadedCalendar) {\n @if (currentWeek(); as week) {\n <section class=\"panel panel-default mb-3\">\n <div\n class=\"panel-heading mt-2 mb-2 py-2 d-flex align-items-baseline\"\n >\n <h3 class=\"h5 ms-3 mt-0 mb-0\">\n {{ capitalCaseFirstLetter(week.day) }}\n @if (!!isSelected(timeInputValue())) {\n <span class=\"visually-hidden\">\n &nbsp;{{\n 'foehn-agenda-timeslot-panel.selected-time'\n | fromDictionary\n : {\n timeSelectedValue:\n timeInputValue(),\n }\n }}\n </span>\n }\n </h3>\n @if (!!week.timeSlots?.length) {\n <small class=\"visually-hidden\">\n {{\n 'foehn-agenda-timeslot-panel.nbr-dispo'\n | fromDictionary\n : {\n nbElements:\n week.timeSlots?.length?.toString(),\n }\n }}\n </small>\n }\n @if (!week.timeSlots?.length) {\n <small class=\"fst-italic align-self-end ms-2\">\n {{\n 'foehn-agenda-timeslot-panel.no-dispo'\n | fromDictionary\n }}\n </small>\n }\n </div>\n @if (!!week.timeSlots?.length) {\n <div\n class=\"panel-body d-flex flex-wrap ms-auto me-auto ps-3 g-0\"\n (focusin)=\"onTimeFocusin()\"\n (focusout)=\"onTimeFocusout()\"\n role=\"application\"\n >\n @for (\n timeSlot of timeSlots();\n track timeSlot;\n let index = $index\n ) {\n <button\n type=\"button\"\n class=\"btn me-2 mb-2\"\n #timeSlotButtonsElemRef\n [attr.id]=\"\n cleanIdForQuerySelector(\n week.day + '-' + timeSlot\n )\n \"\n [tabindex]=\"getTimeSlotTabIndex(timeSlot, index)\"\n [class.btn-info]=\"!isSelected(timeSlot)\"\n [class.btn-primary]=\"isSelected(timeSlot)\"\n (click)=\"\n handleUserInput(\n week.day,\n week.date,\n timeSlot,\n loadedCalendar\n )\n \"\n [attr.aria-label]=\"\n getButtonTimeSlotAriaLabel(week.day, timeSlot)\n \"\n >\n {{ timeSlot }}\n </button>\n }\n @if (\n (week.timeSlots?.length ?? 0) >\n visibleElementsCount() && canClose()\n ) {\n <div class=\"col-12 d-flex justify-content-end mb-1\">\n <button\n type=\"button\"\n class=\"btn btn-link show-more\"\n #timeSlotButtonsElemRef\n (click)=\"togglePanel()\"\n [attr.aria-label]=\"\n (isClosed()\n ? 'foehn-agenda-timeslot-panel.show-more-sr-only'\n : 'foehn-agenda-timeslot-panel.show-less'\n )\n | fromDictionary\n : {\n nbrElementsHidden:\n timeslotRemaining().toString(),\n }\n \"\n >\n {{\n (isClosed()\n ? 'foehn.agenda-timeslot-panel.show-more'\n : 'foehn-agenda-timeslot-panel.show-less'\n )\n | fromDictionary\n : {\n nbrElementsHidden:\n timeslotRemaining().toString(),\n }\n }}\n </button>\n </div>\n }\n </div>\n }\n </section>\n }\n}\n", styles: [".panel-default{border:1px solid #dfdfdf}.panel-heading{position:sticky;background-color:#fff;width:100%;top:0}.panel-heading small{font-size:.9rem}.panel-heading:focus{outline:0;box-shadow:inset 0 1px 1px #00000013,0 0 0 .2rem var(--vd-focus)}.panel-body .btn-info{background-color:var(--vd-neutral-light);border-color:var(--vd-neutral-light)}.panel-body .btn-info:hover{background-color:var(--vd-neutral-lighter);border-color:var(--vd-neutral-lighter)}.panel-body .btn-info,.panel-body .btn-primary{padding-right:.4rem;padding-left:.4rem}.panel-body .btn-info:hover,.panel-body .btn-primary:hover{box-shadow:0 0 0 .2rem var(--vd-focus)}.panel-body .btn.btn-link{padding:0;margin:0 .25rem 0 0}.show-more{cursor:pointer;font-size:.9rem}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: SdkDictionaryPipe, name: "fromDictionary" }] });
16295
+ ], viewQueries: [{ propertyName: "timeSlotButtonsElemRef", predicate: ["timeSlotButtonsElemRef"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "@if (calendar() | async; as loadedCalendar) {\n @if (currentWeek(); as week) {\n <section class=\"panel panel-default mb-3\">\n <div\n class=\"panel-heading mt-2 mb-2 py-2 d-flex align-items-baseline\"\n >\n <h3 class=\"h5 ms-3 mt-0 mb-0\">\n {{ capitalCaseFirstLetter(week.day) }}\n @if (!!isSelected(timeInputValue())) {\n <span class=\"visually-hidden\">\n &nbsp;{{\n 'foehn-agenda-timeslot-panel.selected-time'\n | fromDictionary\n : {\n timeSelectedValue:\n timeInputValue(),\n }\n }}\n </span>\n }\n </h3>\n @if (!!week.timeSlots?.length) {\n <small class=\"visually-hidden\">\n {{\n 'foehn-agenda-timeslot-panel.nbr-dispo'\n | fromDictionary\n : {\n nbElements:\n week.timeSlots?.length?.toString(),\n }\n }}\n </small>\n }\n @if (!week.timeSlots?.length) {\n <small class=\"fst-italic align-self-end ms-2\">\n {{\n 'foehn-agenda-timeslot-panel.no-dispo'\n | fromDictionary\n }}\n </small>\n }\n </div>\n @if (!!week.timeSlots?.length) {\n <div\n class=\"panel-body d-flex flex-wrap ms-auto me-auto ps-3 g-0\"\n (focusin)=\"onTimeFocusin()\"\n (focusout)=\"onTimeFocusout()\"\n role=\"application\"\n >\n @for (\n timeSlot of timeSlots();\n track timeSlot;\n let index = $index\n ) {\n <button\n type=\"button\"\n class=\"btn me-2 mb-2\"\n #timeSlotButtonsElemRef\n [attr.id]=\"\n cleanIdForQuerySelector(\n week.day + '-' + timeSlot\n )\n \"\n [tabindex]=\"getTimeSlotTabIndex(timeSlot, index)\"\n [disabled]=\"disabled()\"\n [class.btn-info]=\"!isSelected(timeSlot)\"\n [class.btn-primary]=\"isSelected(timeSlot)\"\n (click)=\"\n handleUserInput(\n week.day,\n week.date,\n timeSlot,\n loadedCalendar\n )\n \"\n [attr.aria-label]=\"\n getButtonTimeSlotAriaLabel(week.day, timeSlot)\n \"\n >\n {{ timeSlot }}\n </button>\n }\n @if (\n (week.timeSlots?.length ?? 0) >\n visibleElementsCount() && canClose()\n ) {\n <div class=\"col-12 d-flex justify-content-end mb-1\">\n <button\n type=\"button\"\n class=\"btn btn-link show-more\"\n #timeSlotButtonsElemRef\n (click)=\"togglePanel()\"\n [attr.aria-label]=\"\n (isClosed()\n ? 'foehn-agenda-timeslot-panel.show-more-sr-only'\n : 'foehn-agenda-timeslot-panel.show-less'\n )\n | fromDictionary\n : {\n nbrElementsHidden:\n timeslotRemaining().toString(),\n }\n \"\n >\n {{\n (isClosed()\n ? 'foehn.agenda-timeslot-panel.show-more'\n : 'foehn-agenda-timeslot-panel.show-less'\n )\n | fromDictionary\n : {\n nbrElementsHidden:\n timeslotRemaining().toString(),\n }\n }}\n </button>\n </div>\n }\n </div>\n }\n </section>\n }\n}\n", styles: [".panel-default{border:1px solid #dfdfdf}.panel-heading{position:sticky;background-color:#fff;width:100%;top:0}.panel-heading small{font-size:.9rem}.panel-heading:focus{outline:0;box-shadow:inset 0 1px 1px #00000013,0 0 0 .2rem var(--vd-focus)}.panel-body .btn-info{background-color:var(--vd-neutral-light);border-color:var(--vd-neutral-light)}.panel-body .btn-info:hover{background-color:var(--vd-neutral-lighter);border-color:var(--vd-neutral-lighter)}.panel-body .btn-info,.panel-body .btn-primary{padding-right:.4rem;padding-left:.4rem}.panel-body .btn-info:hover,.panel-body .btn-primary:hover{box-shadow:0 0 0 .2rem var(--vd-focus)}.panel-body .btn.btn-link{padding:0;margin:0 .25rem 0 0}.show-more{cursor:pointer;font-size:.9rem}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: SdkDictionaryPipe, name: "fromDictionary" }] });
16241
16296
  }
16242
16297
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.26", ngImport: i0, type: FoehnAgendaTimeslotPanelComponent, decorators: [{
16243
16298
  type: Component,
@@ -16248,7 +16303,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.26", ngImpo
16248
16303
  },
16249
16304
  ], imports: [AsyncPipe, SdkDictionaryPipe], host: {
16250
16305
  '(keydown)': 'handleKeyboardDownEvent($event)',
16251
- }, template: "@if (calendar() | async; as loadedCalendar) {\n @if (currentWeek(); as week) {\n <section class=\"panel panel-default mb-3\">\n <div\n class=\"panel-heading mt-2 mb-2 py-2 d-flex align-items-baseline\"\n >\n <h3 class=\"h5 ms-3 mt-0 mb-0\">\n {{ capitalCaseFirstLetter(week.day) }}\n @if (!!isSelected(timeInputValue())) {\n <span class=\"visually-hidden\">\n &nbsp;{{\n 'foehn-agenda-timeslot-panel.selected-time'\n | fromDictionary\n : {\n timeSelectedValue:\n timeInputValue(),\n }\n }}\n </span>\n }\n </h3>\n @if (!!week.timeSlots?.length) {\n <small class=\"visually-hidden\">\n {{\n 'foehn-agenda-timeslot-panel.nbr-dispo'\n | fromDictionary\n : {\n nbElements:\n week.timeSlots?.length?.toString(),\n }\n }}\n </small>\n }\n @if (!week.timeSlots?.length) {\n <small class=\"fst-italic align-self-end ms-2\">\n {{\n 'foehn-agenda-timeslot-panel.no-dispo'\n | fromDictionary\n }}\n </small>\n }\n </div>\n @if (!!week.timeSlots?.length) {\n <div\n class=\"panel-body d-flex flex-wrap ms-auto me-auto ps-3 g-0\"\n (focusin)=\"onTimeFocusin()\"\n (focusout)=\"onTimeFocusout()\"\n role=\"application\"\n >\n @for (\n timeSlot of timeSlots();\n track timeSlot;\n let index = $index\n ) {\n <button\n type=\"button\"\n class=\"btn me-2 mb-2\"\n #timeSlotButtonsElemRef\n [attr.id]=\"\n cleanIdForQuerySelector(\n week.day + '-' + timeSlot\n )\n \"\n [tabindex]=\"getTimeSlotTabIndex(timeSlot, index)\"\n [class.btn-info]=\"!isSelected(timeSlot)\"\n [class.btn-primary]=\"isSelected(timeSlot)\"\n (click)=\"\n handleUserInput(\n week.day,\n week.date,\n timeSlot,\n loadedCalendar\n )\n \"\n [attr.aria-label]=\"\n getButtonTimeSlotAriaLabel(week.day, timeSlot)\n \"\n >\n {{ timeSlot }}\n </button>\n }\n @if (\n (week.timeSlots?.length ?? 0) >\n visibleElementsCount() && canClose()\n ) {\n <div class=\"col-12 d-flex justify-content-end mb-1\">\n <button\n type=\"button\"\n class=\"btn btn-link show-more\"\n #timeSlotButtonsElemRef\n (click)=\"togglePanel()\"\n [attr.aria-label]=\"\n (isClosed()\n ? 'foehn-agenda-timeslot-panel.show-more-sr-only'\n : 'foehn-agenda-timeslot-panel.show-less'\n )\n | fromDictionary\n : {\n nbrElementsHidden:\n timeslotRemaining().toString(),\n }\n \"\n >\n {{\n (isClosed()\n ? 'foehn.agenda-timeslot-panel.show-more'\n : 'foehn-agenda-timeslot-panel.show-less'\n )\n | fromDictionary\n : {\n nbrElementsHidden:\n timeslotRemaining().toString(),\n }\n }}\n </button>\n </div>\n }\n </div>\n }\n </section>\n }\n}\n", styles: [".panel-default{border:1px solid #dfdfdf}.panel-heading{position:sticky;background-color:#fff;width:100%;top:0}.panel-heading small{font-size:.9rem}.panel-heading:focus{outline:0;box-shadow:inset 0 1px 1px #00000013,0 0 0 .2rem var(--vd-focus)}.panel-body .btn-info{background-color:var(--vd-neutral-light);border-color:var(--vd-neutral-light)}.panel-body .btn-info:hover{background-color:var(--vd-neutral-lighter);border-color:var(--vd-neutral-lighter)}.panel-body .btn-info,.panel-body .btn-primary{padding-right:.4rem;padding-left:.4rem}.panel-body .btn-info:hover,.panel-body .btn-primary:hover{box-shadow:0 0 0 .2rem var(--vd-focus)}.panel-body .btn.btn-link{padding:0;margin:0 .25rem 0 0}.show-more{cursor:pointer;font-size:.9rem}\n"] }]
16306
+ }, template: "@if (calendar() | async; as loadedCalendar) {\n @if (currentWeek(); as week) {\n <section class=\"panel panel-default mb-3\">\n <div\n class=\"panel-heading mt-2 mb-2 py-2 d-flex align-items-baseline\"\n >\n <h3 class=\"h5 ms-3 mt-0 mb-0\">\n {{ capitalCaseFirstLetter(week.day) }}\n @if (!!isSelected(timeInputValue())) {\n <span class=\"visually-hidden\">\n &nbsp;{{\n 'foehn-agenda-timeslot-panel.selected-time'\n | fromDictionary\n : {\n timeSelectedValue:\n timeInputValue(),\n }\n }}\n </span>\n }\n </h3>\n @if (!!week.timeSlots?.length) {\n <small class=\"visually-hidden\">\n {{\n 'foehn-agenda-timeslot-panel.nbr-dispo'\n | fromDictionary\n : {\n nbElements:\n week.timeSlots?.length?.toString(),\n }\n }}\n </small>\n }\n @if (!week.timeSlots?.length) {\n <small class=\"fst-italic align-self-end ms-2\">\n {{\n 'foehn-agenda-timeslot-panel.no-dispo'\n | fromDictionary\n }}\n </small>\n }\n </div>\n @if (!!week.timeSlots?.length) {\n <div\n class=\"panel-body d-flex flex-wrap ms-auto me-auto ps-3 g-0\"\n (focusin)=\"onTimeFocusin()\"\n (focusout)=\"onTimeFocusout()\"\n role=\"application\"\n >\n @for (\n timeSlot of timeSlots();\n track timeSlot;\n let index = $index\n ) {\n <button\n type=\"button\"\n class=\"btn me-2 mb-2\"\n #timeSlotButtonsElemRef\n [attr.id]=\"\n cleanIdForQuerySelector(\n week.day + '-' + timeSlot\n )\n \"\n [tabindex]=\"getTimeSlotTabIndex(timeSlot, index)\"\n [disabled]=\"disabled()\"\n [class.btn-info]=\"!isSelected(timeSlot)\"\n [class.btn-primary]=\"isSelected(timeSlot)\"\n (click)=\"\n handleUserInput(\n week.day,\n week.date,\n timeSlot,\n loadedCalendar\n )\n \"\n [attr.aria-label]=\"\n getButtonTimeSlotAriaLabel(week.day, timeSlot)\n \"\n >\n {{ timeSlot }}\n </button>\n }\n @if (\n (week.timeSlots?.length ?? 0) >\n visibleElementsCount() && canClose()\n ) {\n <div class=\"col-12 d-flex justify-content-end mb-1\">\n <button\n type=\"button\"\n class=\"btn btn-link show-more\"\n #timeSlotButtonsElemRef\n (click)=\"togglePanel()\"\n [attr.aria-label]=\"\n (isClosed()\n ? 'foehn-agenda-timeslot-panel.show-more-sr-only'\n : 'foehn-agenda-timeslot-panel.show-less'\n )\n | fromDictionary\n : {\n nbrElementsHidden:\n timeslotRemaining().toString(),\n }\n \"\n >\n {{\n (isClosed()\n ? 'foehn.agenda-timeslot-panel.show-more'\n : 'foehn-agenda-timeslot-panel.show-less'\n )\n | fromDictionary\n : {\n nbrElementsHidden:\n timeslotRemaining().toString(),\n }\n }}\n </button>\n </div>\n }\n </div>\n }\n </section>\n }\n}\n", styles: [".panel-default{border:1px solid #dfdfdf}.panel-heading{position:sticky;background-color:#fff;width:100%;top:0}.panel-heading small{font-size:.9rem}.panel-heading:focus{outline:0;box-shadow:inset 0 1px 1px #00000013,0 0 0 .2rem var(--vd-focus)}.panel-body .btn-info{background-color:var(--vd-neutral-light);border-color:var(--vd-neutral-light)}.panel-body .btn-info:hover{background-color:var(--vd-neutral-lighter);border-color:var(--vd-neutral-lighter)}.panel-body .btn-info,.panel-body .btn-primary{padding-right:.4rem;padding-left:.4rem}.panel-body .btn-info:hover,.panel-body .btn-primary:hover{box-shadow:0 0 0 .2rem var(--vd-focus)}.panel-body .btn.btn-link{padding:0;margin:0 .25rem 0 0}.show-more{cursor:pointer;font-size:.9rem}\n"] }]
16252
16307
  }], propDecorators: { calendar: [{ type: i0.Input, args: [{ isSignal: true, alias: "calendar", required: false }] }], currentWeek: [{ type: i0.Input, args: [{ isSignal: true, alias: "currentWeek", required: false }] }], nbVisibleElements: [{ type: i0.Input, args: [{ isSignal: true, alias: "nbVisibleElements", required: false }] }], timeSlotButtonsElemRef: [{ type: i0.ViewChildren, args: ['timeSlotButtonsElemRef', { isSignal: true }] }] } });
16253
16308
 
16254
16309
  class FoehnAgendaComponent extends FoehnInputComponent {
@@ -16312,7 +16367,7 @@ class FoehnAgendaComponent extends FoehnInputComponent {
16312
16367
  provide: FoehnInputComponent,
16313
16368
  useExisting: forwardRef(() => FoehnAgendaComponent),
16314
16369
  },
16315
- ], viewQueries: [{ propertyName: "timeSlotPanelsElemRef", predicate: ["timeSlotPanelElemRef"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrors()\"\n [class.vd-form-group-danger]=\"hasErrors()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n @if (label() && type !== 'hidden') {\n <p\n [attr.id]=\"buildChildId('Label')\"\n [attr.for]=\"buildChildId()\"\n [class.visually-hidden]=\"isLabelSrOnly()\"\n [class.vd-p]=\"!isLabelSrOnly()\"\n >\n <span [innerHTML]=\"label()\"></span>\n @if (!required() && !hideNotRequiredExtraLabel()) {\n <span aria-hidden=\"true\">\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n }\n </p>\n }\n\n @if (helpText() && type !== 'hidden') {\n <small\n [attr.id]=\"buildChildId('Help')\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText()\"\n ></small>\n }\n\n @if (!(calendar() | async)) {\n <foehn-validation-alerts [component]=\"this\" />\n <p class=\"alert alert-warning\">\n {{ 'foehn-agenda.calendar-indisponible' | fromDictionary }}\n </p>\n }\n\n <!-- Fake input with NgModel to be registered into Form controls -->\n <input type=\"hidden\" [name]=\"name() || label() || ''\" [ngModel]=\"model()\" />\n\n <p\n [id]=\"buildChildId('srOnlyAnnouncements')\"\n class=\"visually-hidden\"\n aria-live=\"polite\"\n aria-atomic=\"true\"\n >\n {{ srAnnouncements() }}\n </p>\n\n <ng-content />\n\n @if (calendar() | async; as loadedCalendar) {\n <section\n class=\"mb-3\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrors() || null\"\n >\n <h2 class=\"h3 mt-3\">\n <output aria-live=\"polite\" aria-atomic=\"true\">\n {{ loadedCalendar.currentWeek?.label }}\n </output>\n </h2>\n\n <!-- Rappel de l'heure actuellement s\u00E9lectionn\u00E9e -->\n <p\n [id]=\"buildChildId('timeSlotSelectedSrOnly')\"\n class=\"visually-hidden\"\n >\n {{ readableSelectedTimeSlot() }}\n </p>\n\n <!-- Navigation top hidden from screen reader-->\n <foehn-agenda-navigation\n [id]=\"buildChildId('week-pagination-top')\"\n [calendar]=\"loadedCalendar\"\n [minDate]=\"loadedCalendar.minAvailableDate\"\n [maxDate]=\"loadedCalendar.maxAvailableDate\"\n (paginationChange)=\"paginate($event)\"\n aria-hidden=\"true\"\n />\n\n <!-- Link to navigation bottom only for screen reader -->\n <p\n [id]=\"buildChildId('navigationBottomAnchor')\"\n class=\"visually-hidden\"\n >\n {{\n 'foehn-agenda.pagination-anchor.first-part' | fromDictionary\n }}\n <a\n href=\"#\"\n (click)=\"$event.preventDefault(); scrollToNavigation(true)\"\n >\n {{\n 'foehn-agenda.pagination-anchor.top-next-part'\n | fromDictionary\n }}\n </a>\n </p>\n\n <foehn-validation-alerts [component]=\"this\" />\n\n <div\n class=\"row\"\n [tabIndex]=\"hasErrors() ? 0 : -1\"\n [attr.id]=\"buildChildId()\"\n #entryComponent\n >\n @for (\n currentWeek of loadedCalendar.currentWeek?.week;\n track $index;\n let i = $index\n ) {\n <foehn-agenda-timeslot-panel\n class=\"col-12\"\n #timeSlotPanelElemRef\n [name]=\"buildChildName('TimeSlot' + (i + 1))\"\n [currentWeek]=\"currentWeek\"\n [calendar]=\"calendar()\"\n [nbVisibleElements]=\"nbVisibleElements()\"\n [(model)]=\"model\"\n (userInput)=\"handleUserInput($event)\"\n />\n }\n </div>\n </section>\n\n <!-- Navigation bottom used for screen reader only -->\n <foehn-agenda-navigation\n class=\"visually-hidden\"\n [id]=\"buildChildId('week-pagination-bottom')\"\n [calendar]=\"loadedCalendar\"\n [isSrOnly]=\"true\"\n [minDate]=\"loadedCalendar.minAvailableDate\"\n [maxDate]=\"loadedCalendar.maxAvailableDate\"\n (paginationChange)=\"paginate($event)\"\n />\n\n <!-- Link to navigation top hidden from screen reader -->\n <p [id]=\"buildChildId('navigationTopAnchor')\" aria-hidden=\"true\">\n {{ 'foehn-agenda.pagination-anchor.first-part' | fromDictionary }}\n <a\n href=\"#\"\n (click)=\"$event.preventDefault(); scrollToNavigation(false)\"\n >\n {{\n 'foehn-agenda.pagination-anchor.bottom-next-part'\n | fromDictionary\n }}\n </a>\n </p>\n }\n</div>\n", dependencies: [{ kind: "component", type: FoehnValidationAlertsComponent, selector: "foehn-validation-alerts", inputs: ["component", "shouldErrorsBeLive"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: FoehnAgendaNavigationComponent, selector: "foehn-agenda-navigation", inputs: ["id", "calendar", "isSrOnly", "minDate", "maxDate"], outputs: ["paginationChange"] }, { kind: "component", type: FoehnAgendaTimeslotPanelComponent, selector: "foehn-agenda-timeslot-panel", inputs: ["calendar", "currentWeek", "nbVisibleElements"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: SdkDictionaryPipe, name: "fromDictionary" }] });
16370
+ ], viewQueries: [{ propertyName: "timeSlotPanelsElemRef", predicate: ["timeSlotPanelElemRef"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrors()\"\n [class.vd-form-group-danger]=\"hasErrors()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n @if (label() && type !== 'hidden') {\n <p\n [attr.id]=\"buildChildId('Label')\"\n [attr.for]=\"buildChildId()\"\n [class.visually-hidden]=\"isLabelSrOnly()\"\n [class.vd-p]=\"!isLabelSrOnly()\"\n >\n <span [innerHTML]=\"label()\"></span>\n @if (!required() && !hideNotRequiredExtraLabel()) {\n <span aria-hidden=\"true\">\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n }\n </p>\n }\n\n @if (helpText() && type !== 'hidden') {\n <small\n [attr.id]=\"buildChildId('Help')\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText()\"\n ></small>\n }\n\n @if (!(calendar() | async)) {\n <foehn-validation-alerts [component]=\"this\" />\n <p class=\"alert alert-warning\">\n {{ 'foehn-agenda.calendar-indisponible' | fromDictionary }}\n </p>\n }\n\n <!-- Fake input with NgModel to be registered into Form controls -->\n <input type=\"hidden\" [name]=\"name() || label() || ''\" [ngModel]=\"model()\" />\n\n <p\n [id]=\"buildChildId('srOnlyAnnouncements')\"\n class=\"visually-hidden\"\n aria-live=\"polite\"\n aria-atomic=\"true\"\n >\n {{ srAnnouncements() }}\n </p>\n\n <ng-content />\n\n @if (calendar() | async; as loadedCalendar) {\n <section\n class=\"mb-3\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrors() || null\"\n >\n <h2 class=\"h3 mt-3\">\n <output aria-live=\"polite\" aria-atomic=\"true\">\n {{ loadedCalendar.currentWeek?.label }}\n </output>\n </h2>\n\n <!-- Rappel de l'heure actuellement s\u00E9lectionn\u00E9e -->\n <p\n [id]=\"buildChildId('timeSlotSelectedSrOnly')\"\n class=\"visually-hidden\"\n >\n {{ readableSelectedTimeSlot() }}\n </p>\n\n <!-- Navigation top hidden from screen reader-->\n <foehn-agenda-navigation\n [id]=\"buildChildId('week-pagination-top')\"\n [calendar]=\"loadedCalendar\"\n [minDate]=\"loadedCalendar.minAvailableDate\"\n [maxDate]=\"loadedCalendar.maxAvailableDate\"\n (paginationChange)=\"paginate($event)\"\n aria-hidden=\"true\"\n />\n\n <!-- Link to navigation bottom only for screen reader -->\n <p\n [id]=\"buildChildId('navigationBottomAnchor')\"\n class=\"visually-hidden\"\n >\n {{\n 'foehn-agenda.pagination-anchor.first-part' | fromDictionary\n }}\n <a\n href=\"#\"\n (click)=\"$event.preventDefault(); scrollToNavigation(true)\"\n >\n {{\n 'foehn-agenda.pagination-anchor.top-next-part'\n | fromDictionary\n }}\n </a>\n </p>\n\n <foehn-validation-alerts [component]=\"this\" />\n\n <div\n class=\"row\"\n [tabIndex]=\"hasErrors() ? 0 : -1\"\n [attr.id]=\"buildChildId()\"\n #entryComponent\n >\n @for (\n currentWeek of loadedCalendar.currentWeek?.week;\n track $index;\n let i = $index\n ) {\n <foehn-agenda-timeslot-panel\n class=\"col-12\"\n #timeSlotPanelElemRef\n [name]=\"buildChildName('TimeSlot' + (i + 1))\"\n [currentWeek]=\"currentWeek\"\n [calendar]=\"calendar()\"\n [nbVisibleElements]=\"nbVisibleElements()\"\n [disabled]=\"disabled()\"\n [model]=\"model()\"\n (modelChange)=\"updateNgModel($event)\"\n (userInput)=\"handleUserInput($event)\"\n />\n }\n </div>\n </section>\n\n <!-- Navigation bottom used for screen reader only -->\n <foehn-agenda-navigation\n class=\"visually-hidden\"\n [id]=\"buildChildId('week-pagination-bottom')\"\n [calendar]=\"loadedCalendar\"\n [isSrOnly]=\"true\"\n [minDate]=\"loadedCalendar.minAvailableDate\"\n [maxDate]=\"loadedCalendar.maxAvailableDate\"\n (paginationChange)=\"paginate($event)\"\n />\n\n <!-- Link to navigation top hidden from screen reader -->\n <p [id]=\"buildChildId('navigationTopAnchor')\" aria-hidden=\"true\">\n {{ 'foehn-agenda.pagination-anchor.first-part' | fromDictionary }}\n <a\n href=\"#\"\n (click)=\"$event.preventDefault(); scrollToNavigation(false)\"\n >\n {{\n 'foehn-agenda.pagination-anchor.bottom-next-part'\n | fromDictionary\n }}\n </a>\n </p>\n }\n</div>\n", dependencies: [{ kind: "component", type: FoehnValidationAlertsComponent, selector: "foehn-validation-alerts", inputs: ["component", "shouldErrorsBeLive"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: FoehnAgendaNavigationComponent, selector: "foehn-agenda-navigation", inputs: ["id", "calendar", "isSrOnly", "minDate", "maxDate"], outputs: ["paginationChange"] }, { kind: "component", type: FoehnAgendaTimeslotPanelComponent, selector: "foehn-agenda-timeslot-panel", inputs: ["calendar", "currentWeek", "nbVisibleElements"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: SdkDictionaryPipe, name: "fromDictionary" }] });
16316
16371
  }
16317
16372
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.26", ngImport: i0, type: FoehnAgendaComponent, decorators: [{
16318
16373
  type: Component,
@@ -16328,7 +16383,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.26", ngImpo
16328
16383
  FoehnAgendaTimeslotPanelComponent,
16329
16384
  AsyncPipe,
16330
16385
  SdkDictionaryPipe,
16331
- ], template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrors()\"\n [class.vd-form-group-danger]=\"hasErrors()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n @if (label() && type !== 'hidden') {\n <p\n [attr.id]=\"buildChildId('Label')\"\n [attr.for]=\"buildChildId()\"\n [class.visually-hidden]=\"isLabelSrOnly()\"\n [class.vd-p]=\"!isLabelSrOnly()\"\n >\n <span [innerHTML]=\"label()\"></span>\n @if (!required() && !hideNotRequiredExtraLabel()) {\n <span aria-hidden=\"true\">\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n }\n </p>\n }\n\n @if (helpText() && type !== 'hidden') {\n <small\n [attr.id]=\"buildChildId('Help')\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText()\"\n ></small>\n }\n\n @if (!(calendar() | async)) {\n <foehn-validation-alerts [component]=\"this\" />\n <p class=\"alert alert-warning\">\n {{ 'foehn-agenda.calendar-indisponible' | fromDictionary }}\n </p>\n }\n\n <!-- Fake input with NgModel to be registered into Form controls -->\n <input type=\"hidden\" [name]=\"name() || label() || ''\" [ngModel]=\"model()\" />\n\n <p\n [id]=\"buildChildId('srOnlyAnnouncements')\"\n class=\"visually-hidden\"\n aria-live=\"polite\"\n aria-atomic=\"true\"\n >\n {{ srAnnouncements() }}\n </p>\n\n <ng-content />\n\n @if (calendar() | async; as loadedCalendar) {\n <section\n class=\"mb-3\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrors() || null\"\n >\n <h2 class=\"h3 mt-3\">\n <output aria-live=\"polite\" aria-atomic=\"true\">\n {{ loadedCalendar.currentWeek?.label }}\n </output>\n </h2>\n\n <!-- Rappel de l'heure actuellement s\u00E9lectionn\u00E9e -->\n <p\n [id]=\"buildChildId('timeSlotSelectedSrOnly')\"\n class=\"visually-hidden\"\n >\n {{ readableSelectedTimeSlot() }}\n </p>\n\n <!-- Navigation top hidden from screen reader-->\n <foehn-agenda-navigation\n [id]=\"buildChildId('week-pagination-top')\"\n [calendar]=\"loadedCalendar\"\n [minDate]=\"loadedCalendar.minAvailableDate\"\n [maxDate]=\"loadedCalendar.maxAvailableDate\"\n (paginationChange)=\"paginate($event)\"\n aria-hidden=\"true\"\n />\n\n <!-- Link to navigation bottom only for screen reader -->\n <p\n [id]=\"buildChildId('navigationBottomAnchor')\"\n class=\"visually-hidden\"\n >\n {{\n 'foehn-agenda.pagination-anchor.first-part' | fromDictionary\n }}\n <a\n href=\"#\"\n (click)=\"$event.preventDefault(); scrollToNavigation(true)\"\n >\n {{\n 'foehn-agenda.pagination-anchor.top-next-part'\n | fromDictionary\n }}\n </a>\n </p>\n\n <foehn-validation-alerts [component]=\"this\" />\n\n <div\n class=\"row\"\n [tabIndex]=\"hasErrors() ? 0 : -1\"\n [attr.id]=\"buildChildId()\"\n #entryComponent\n >\n @for (\n currentWeek of loadedCalendar.currentWeek?.week;\n track $index;\n let i = $index\n ) {\n <foehn-agenda-timeslot-panel\n class=\"col-12\"\n #timeSlotPanelElemRef\n [name]=\"buildChildName('TimeSlot' + (i + 1))\"\n [currentWeek]=\"currentWeek\"\n [calendar]=\"calendar()\"\n [nbVisibleElements]=\"nbVisibleElements()\"\n [(model)]=\"model\"\n (userInput)=\"handleUserInput($event)\"\n />\n }\n </div>\n </section>\n\n <!-- Navigation bottom used for screen reader only -->\n <foehn-agenda-navigation\n class=\"visually-hidden\"\n [id]=\"buildChildId('week-pagination-bottom')\"\n [calendar]=\"loadedCalendar\"\n [isSrOnly]=\"true\"\n [minDate]=\"loadedCalendar.minAvailableDate\"\n [maxDate]=\"loadedCalendar.maxAvailableDate\"\n (paginationChange)=\"paginate($event)\"\n />\n\n <!-- Link to navigation top hidden from screen reader -->\n <p [id]=\"buildChildId('navigationTopAnchor')\" aria-hidden=\"true\">\n {{ 'foehn-agenda.pagination-anchor.first-part' | fromDictionary }}\n <a\n href=\"#\"\n (click)=\"$event.preventDefault(); scrollToNavigation(false)\"\n >\n {{\n 'foehn-agenda.pagination-anchor.bottom-next-part'\n | fromDictionary\n }}\n </a>\n </p>\n }\n</div>\n" }]
16386
+ ], template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrors()\"\n [class.vd-form-group-danger]=\"hasErrors()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n @if (label() && type !== 'hidden') {\n <p\n [attr.id]=\"buildChildId('Label')\"\n [attr.for]=\"buildChildId()\"\n [class.visually-hidden]=\"isLabelSrOnly()\"\n [class.vd-p]=\"!isLabelSrOnly()\"\n >\n <span [innerHTML]=\"label()\"></span>\n @if (!required() && !hideNotRequiredExtraLabel()) {\n <span aria-hidden=\"true\">\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n }\n </p>\n }\n\n @if (helpText() && type !== 'hidden') {\n <small\n [attr.id]=\"buildChildId('Help')\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText()\"\n ></small>\n }\n\n @if (!(calendar() | async)) {\n <foehn-validation-alerts [component]=\"this\" />\n <p class=\"alert alert-warning\">\n {{ 'foehn-agenda.calendar-indisponible' | fromDictionary }}\n </p>\n }\n\n <!-- Fake input with NgModel to be registered into Form controls -->\n <input type=\"hidden\" [name]=\"name() || label() || ''\" [ngModel]=\"model()\" />\n\n <p\n [id]=\"buildChildId('srOnlyAnnouncements')\"\n class=\"visually-hidden\"\n aria-live=\"polite\"\n aria-atomic=\"true\"\n >\n {{ srAnnouncements() }}\n </p>\n\n <ng-content />\n\n @if (calendar() | async; as loadedCalendar) {\n <section\n class=\"mb-3\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrors() || null\"\n >\n <h2 class=\"h3 mt-3\">\n <output aria-live=\"polite\" aria-atomic=\"true\">\n {{ loadedCalendar.currentWeek?.label }}\n </output>\n </h2>\n\n <!-- Rappel de l'heure actuellement s\u00E9lectionn\u00E9e -->\n <p\n [id]=\"buildChildId('timeSlotSelectedSrOnly')\"\n class=\"visually-hidden\"\n >\n {{ readableSelectedTimeSlot() }}\n </p>\n\n <!-- Navigation top hidden from screen reader-->\n <foehn-agenda-navigation\n [id]=\"buildChildId('week-pagination-top')\"\n [calendar]=\"loadedCalendar\"\n [minDate]=\"loadedCalendar.minAvailableDate\"\n [maxDate]=\"loadedCalendar.maxAvailableDate\"\n (paginationChange)=\"paginate($event)\"\n aria-hidden=\"true\"\n />\n\n <!-- Link to navigation bottom only for screen reader -->\n <p\n [id]=\"buildChildId('navigationBottomAnchor')\"\n class=\"visually-hidden\"\n >\n {{\n 'foehn-agenda.pagination-anchor.first-part' | fromDictionary\n }}\n <a\n href=\"#\"\n (click)=\"$event.preventDefault(); scrollToNavigation(true)\"\n >\n {{\n 'foehn-agenda.pagination-anchor.top-next-part'\n | fromDictionary\n }}\n </a>\n </p>\n\n <foehn-validation-alerts [component]=\"this\" />\n\n <div\n class=\"row\"\n [tabIndex]=\"hasErrors() ? 0 : -1\"\n [attr.id]=\"buildChildId()\"\n #entryComponent\n >\n @for (\n currentWeek of loadedCalendar.currentWeek?.week;\n track $index;\n let i = $index\n ) {\n <foehn-agenda-timeslot-panel\n class=\"col-12\"\n #timeSlotPanelElemRef\n [name]=\"buildChildName('TimeSlot' + (i + 1))\"\n [currentWeek]=\"currentWeek\"\n [calendar]=\"calendar()\"\n [nbVisibleElements]=\"nbVisibleElements()\"\n [disabled]=\"disabled()\"\n [model]=\"model()\"\n (modelChange)=\"updateNgModel($event)\"\n (userInput)=\"handleUserInput($event)\"\n />\n }\n </div>\n </section>\n\n <!-- Navigation bottom used for screen reader only -->\n <foehn-agenda-navigation\n class=\"visually-hidden\"\n [id]=\"buildChildId('week-pagination-bottom')\"\n [calendar]=\"loadedCalendar\"\n [isSrOnly]=\"true\"\n [minDate]=\"loadedCalendar.minAvailableDate\"\n [maxDate]=\"loadedCalendar.maxAvailableDate\"\n (paginationChange)=\"paginate($event)\"\n />\n\n <!-- Link to navigation top hidden from screen reader -->\n <p [id]=\"buildChildId('navigationTopAnchor')\" aria-hidden=\"true\">\n {{ 'foehn-agenda.pagination-anchor.first-part' | fromDictionary }}\n <a\n href=\"#\"\n (click)=\"$event.preventDefault(); scrollToNavigation(false)\"\n >\n {{\n 'foehn-agenda.pagination-anchor.bottom-next-part'\n | fromDictionary\n }}\n </a>\n </p>\n }\n</div>\n" }]
16332
16387
  }], propDecorators: { calendar: [{ type: i0.Input, args: [{ isSignal: true, alias: "calendar", required: false }] }], nbVisibleElements: [{ type: i0.Input, args: [{ isSignal: true, alias: "nbVisibleElements", required: false }] }], paginationChange: [{ type: i0.Output, args: ["paginationChange"] }], timeSlotPanelsElemRef: [{ type: i0.ViewChildren, args: ['timeSlotPanelElemRef', { isSignal: true }] }] } });
16333
16388
 
16334
16389
  class SelectedSlot {
@@ -16367,5 +16422,5 @@ class SdkLog {
16367
16422
  * Generated bundle index. Do not edit.
16368
16423
  */
16369
16424
 
16370
- export { APP_INFO_API_URL, AbstractFoehnUploaderComponent, AbstractListDetailPageComponent, AbstractMenuPageComponent, AbstractPageComponent, AbstractPageFromMenuComponent, ActionStatut, Address, AddressTypeLight, ApplicationInfo, ApplicationInfoService, BAD_PARAMS_HELP_TEXT, BoDocumentError, BoDocumentsWithErrors, BoMultiUploadService, Breadcrumb, BreadcrumbEventService, BreadcrumbItem, CAPTCHA_ERROR_NAME, CURRENCY_REGEXP, Calendar, Canton, Captcha, ChunkLoadErrorHandler, Configuration, Country, CurrencyHelper, CurrentWeek, DECIMALS_SEPARATOR, DEFAULT_INTERNATIONAL_FIX_AND_MOBILE, DEFAULT_INTERNATIONAL_FIX_ONLY, DEFAULT_INTERNATIONAL_MOBILE_ONLY, DEFAULT_PREFIX, DEFAULT_SWISS_FIX_AND_MOBILE, DEFAULT_SWISS_FIX_ONLY, DEFAULT_SWISS_MOBILE_ONLY, DICTIONARY_BASE_URL, DateHelper, DatePickerHelper, DatePickerNavigationHelper, DayMonth, DaySlots, DemandeExpirationService, DemandeHelper, DisplayCurrencyPipe, DisplayDatePipe, District, Document, DocumentError, DocumentReference, DocumentReferenceWithFile, DocumentsWithErrors, DropdownMenuGroup, DropdownMenuItem, EPaymentService, EtapeInfo, FEEDBACK_USAGERS_LOCAL_STORAGE_PREFIX, FORM_SUPPORT_CYBER_TITLE_FALLBACK, FocusedDay, FoehnAbbrComponent, FoehnAgendaComponent, FoehnAgendaNavigationComponent, FoehnAgendaTimeslotPanelComponent, FoehnAutocompleteComponent, FoehnBoMultiUploadComponent, FoehnBooleanCheckboxComponent, FoehnBooleanRadioComponent, FoehnBreadcrumbComponent, FoehnCheckableGroupComponent, FoehnCheckboxComponent, FoehnConfirmModalComponent, FoehnConfirmModalContent, FoehnConfirmModalService, FoehnDateComponent, FoehnDatePickerButtonComponent, FoehnDatePickerComponent, FoehnDateTimeComponent, FoehnDecisionElectroniqueComponent, FoehnDisplayAddressComponent, FoehnDropdownMenuComponent, FoehnErrorPillComponent, FoehnFeedbackNotificationComponent, FoehnFormComponent, FoehnGlobalUploadProgressBarComponent, FoehnHeaderComponent, FoehnHelpModalComponent, FoehnIconCalendarComponent, FoehnIconCheckComponent, FoehnIconCheckSquareOComponent, FoehnIconChevronDownComponent, FoehnIconChevronLeftComponent, FoehnIconChevronRightComponent, FoehnIconChevronUpComponent, FoehnIconClockComponent, FoehnIconCommentDotsComponent, FoehnIconEditComponent, FoehnIconExternalLinkAltComponent, FoehnIconFilePdfComponent, FoehnIconInfoCircleComponent, FoehnIconLockComponent, FoehnIconMapMarkerComponent, FoehnIconMinusCircleComponent, FoehnIconPencilComponent, FoehnIconPlusCircleComponent, FoehnIconPlusSquareComponent, FoehnIconSearchComponent, FoehnIconTimesComponent, FoehnIconTrashAltComponent, FoehnIconUnlockAltComponent, FoehnIconUserComponent, FoehnInputAddressComponent, FoehnInputComponent, FoehnInputEmailComponent, FoehnInputForeignLocalityComponent, FoehnInputForeignStreetComponent, FoehnInputHiddenComponent, FoehnInputNav13Component, FoehnInputNumberComponent, FoehnInputPasswordComponent, FoehnInputPhoneComponent, FoehnInputPrefixedTextComponent, FoehnInputStringComponent, FoehnInputTextComponent, FoehnInputTextareaComponent, FoehnListComponent, FoehnListItem, FoehnListSummaryComponent, FoehnMenuItemComponent, FoehnMenuItemTransmitComponent, FoehnModalComponent, FoehnMultiUploadComponent, FoehnMultiselectAutocompleteComponent, FoehnNavigationComponent, FoehnNavigationService, FoehnNotfoundComponent, FoehnPageComponent, FoehnPageCounterComponent, FoehnPageExpirationTimerComponent, FoehnPageModalComponent, FoehnPageService, FoehnPictureUploadComponent, FoehnRadioComponent, FoehnRecapSectionComponent, FoehnRemainingAlertsSummaryComponent, FoehnSelectComponent, FoehnSimpleNavigationComponent, FoehnSkipLinkComponent, FoehnStatusProgressBarComponent, FoehnTableColumnConfiguration, FoehnTableComponent, FoehnTablePageChangeEvent, FoehnTimeComponent, FoehnTransmitWaitingModalComponent, FoehnTransmitWaitingModalService, FoehnUploadProgressBarComponent, FoehnUserConnectedAsComponent, FoehnValidationAlertSummaryComponent, FoehnValidationAlertsComponent, FooterLink, FormMetadata, FormPostResponse, FormSelectOption, FormatAvsPipe, FormatIdePipe, GESDEM_MAX_DATA_LENGTH, GesdemActionRecoveryLoginComponent, GesdemActionRecoveryRegistrationComponent, GesdemConfirmationComponent, GesdemErrorComponent, GesdemEventService, GesdemHandlerService, GesdemStatutUtils, GlobalUploadProgressService, GrowlBrokerService, GrowlMessage, GrowlType, HTTP_LOADER_FILTERED_URL, I18nForm, IAM_ACV_OIDC_REDIRECT_LOCATION_REGEX, IAM_ACV_REDIRECT_LOCATION_REGEX, IbanFormatterDirective, IdeFormatterDirective, IntervalHelper, LineBreakAsHtmlPipe, Locality, MonthYear, MultiUploadService, Municipality, NDCFormatterDirective, NEVER_CONNECTED, NavigationDirection, NumberCurrencyFormatterDirective, OIDC_ENABLED, ObjectHelper, ObjectPathHelper, PORTAIL_BASE_URL_INT, PORTAIL_BASE_URL_PROD, PORTAIL_BASE_URL_VAL, PageChangeEvent, PageUploadLimitService, PaginationWeek, PendingFiles, PendingPaymentComponent, PendingUploadService, PlaceOfOrigin, Portail, PostalLocality, Preferences, RECAPTCHA_API_URL, RecaptchaService, RedirectComponent, RegisterNgModelService, RowElement, SESSION_INFO_API_URL, SWISS_ISO_ID, ScrollHelper, SdkDictionaryPipe, SdkDictionaryService, SdkEpaymentComponent, SdkEvent, SdkEventType, SdkEventsLoggerService, SdkLog, SdkLogLevel, SdkLogsService, SdkRecaptchaComponent, SdkStatisticsService, SelectedSlot, Session, SessionInfo, SessionInfoData, SessionInfoWithApplicationService, Street, StreetNumber, StringHelper, THOUSANDS_SEPARATOR, TRANSMIT_WAITING_MODAL_DELAY_IN_MILLISECONDS, TableSort, UploadProgress, UploadProgressService, UploaderHelper, ValidationHandlerService, formatDecimalCurrency, formatNonDecimalCurrency, formatNumberAsGiven, gesdemLoaderGuard, getSafeFileNameForErrorMessage, providePrestationsNgCore, replaceAll, splitDocumentChanges };
16425
+ export { APP_INFO_API_URL, AbstractFoehnUploaderComponent, AbstractListDetailPageComponent, AbstractMenuPageComponent, AbstractPageComponent, AbstractPageFromMenuComponent, ActionStatut, Address, AddressTypeLight, ApplicationInfo, ApplicationInfoService, BAD_PARAMS_HELP_TEXT, BoDocumentError, BoDocumentsWithErrors, BoMultiUploadService, Breadcrumb, BreadcrumbEventService, BreadcrumbItem, CAPTCHA_ERROR_NAME, CURRENCY_REGEXP, Calendar, Canton, Captcha, ChunkLoadErrorHandler, Configuration, Country, CurrencyHelper, CurrentWeek, DECIMALS_SEPARATOR, DEFAULT_INTERNATIONAL_FIX_AND_MOBILE, DEFAULT_INTERNATIONAL_FIX_ONLY, DEFAULT_INTERNATIONAL_MOBILE_ONLY, DEFAULT_PREFIX, DEFAULT_SWISS_FIX_AND_MOBILE, DEFAULT_SWISS_FIX_ONLY, DEFAULT_SWISS_MOBILE_ONLY, DICTIONARY_BASE_URL, DateHelper, DatePickerHelper, DatePickerNavigationHelper, DayMonth, DaySlots, DemandeExpirationService, DemandeHelper, DisplayCurrencyPipe, DisplayDatePipe, District, Document, DocumentError, DocumentReference, DocumentReferenceWithFile, DocumentsWithErrors, DropdownMenuGroup, DropdownMenuItem, EPaymentService, EtapeInfo, FEEDBACK_USAGERS_LOCAL_STORAGE_PREFIX, FORM_SUPPORT_CYBER_TITLE_FALLBACK, FocusedDay, FoehnAbbrComponent, FoehnAgendaComponent, FoehnAgendaNavigationComponent, FoehnAgendaTimeslotPanelComponent, FoehnAutocompleteComponent, FoehnBoMultiUploadComponent, FoehnBooleanCheckboxComponent, FoehnBooleanRadioComponent, FoehnBreadcrumbComponent, FoehnCheckableGroupComponent, FoehnCheckboxComponent, FoehnConfirmModalComponent, FoehnConfirmModalContent, FoehnConfirmModalService, FoehnDateComponent, FoehnDatePickerButtonComponent, FoehnDatePickerComponent, FoehnDateTimeComponent, FoehnDecisionElectroniqueComponent, FoehnDisplayAddressComponent, FoehnDropdownMenuComponent, FoehnErrorPillComponent, FoehnFeedbackNotificationComponent, FoehnFormComponent, FoehnGlobalUploadProgressBarComponent, FoehnHeaderComponent, FoehnHelpModalComponent, FoehnIconCalendarComponent, FoehnIconCheckComponent, FoehnIconCheckSquareOComponent, FoehnIconChevronDownComponent, FoehnIconChevronLeftComponent, FoehnIconChevronRightComponent, FoehnIconChevronUpComponent, FoehnIconClockComponent, FoehnIconCommentDotsComponent, FoehnIconEditComponent, FoehnIconExternalLinkAltComponent, FoehnIconFilePdfComponent, FoehnIconInfoCircleComponent, FoehnIconLockComponent, FoehnIconMapMarkerComponent, FoehnIconMinusCircleComponent, FoehnIconPencilComponent, FoehnIconPlusCircleComponent, FoehnIconPlusSquareComponent, FoehnIconSearchComponent, FoehnIconTimesComponent, FoehnIconTrashAltComponent, FoehnIconUnlockAltComponent, FoehnIconUserComponent, FoehnInputAddressComponent, FoehnInputComponent, FoehnInputEmailComponent, FoehnInputForeignLocalityComponent, FoehnInputForeignStreetComponent, FoehnInputHiddenComponent, FoehnInputNav13Component, FoehnInputNumberComponent, FoehnInputPasswordComponent, FoehnInputPhoneComponent, FoehnInputPrefixedTextComponent, FoehnInputStringComponent, FoehnInputTextComponent, FoehnInputTextareaComponent, FoehnListComponent, FoehnListItem, FoehnListSummaryComponent, FoehnMenuItemComponent, FoehnMenuItemTransmitComponent, FoehnModalComponent, FoehnMultiUploadComponent, FoehnMultiselectAutocompleteComponent, FoehnNavigationComponent, FoehnNavigationService, FoehnNotfoundComponent, FoehnPageComponent, FoehnPageCounterComponent, FoehnPageExpirationTimerComponent, FoehnPageModalComponent, FoehnPageService, FoehnPictureUploadComponent, FoehnRadioComponent, FoehnRecapSectionComponent, FoehnRemainingAlertsSummaryComponent, FoehnSelectComponent, FoehnSimpleNavigationComponent, FoehnSkipLinkComponent, FoehnStatusProgressBarComponent, FoehnTableColumnConfiguration, FoehnTableComponent, FoehnTablePageChangeEvent, FoehnTimeComponent, FoehnTransmitWaitingModalComponent, FoehnTransmitWaitingModalService, FoehnUploadProgressBarComponent, FoehnUserConnectedAsComponent, FoehnValidationAlertSummaryComponent, FoehnValidationAlertsComponent, FooterLink, FormErrorHelper, FormMetadata, FormPostResponse, FormSelectOption, FormatAvsPipe, FormatIdePipe, GESDEM_MAX_DATA_LENGTH, GesdemActionRecoveryLoginComponent, GesdemActionRecoveryRegistrationComponent, GesdemConfirmationComponent, GesdemErrorComponent, GesdemEventService, GesdemHandlerService, GesdemStatutUtils, GlobalUploadProgressService, GrowlBrokerService, GrowlMessage, GrowlType, HTTP_LOADER_FILTERED_URL, I18nForm, IAM_ACV_OIDC_REDIRECT_LOCATION_REGEX, IAM_ACV_REDIRECT_LOCATION_REGEX, IbanFormatterDirective, IdeFormatterDirective, IntervalHelper, LineBreakAsHtmlPipe, Locality, MonthYear, MultiUploadService, Municipality, NDCFormatterDirective, NEVER_CONNECTED, NavigationDirection, NumberCurrencyFormatterDirective, OIDC_ENABLED, ObjectHelper, ObjectPathHelper, PORTAIL_BASE_URL_INT, PORTAIL_BASE_URL_PROD, PORTAIL_BASE_URL_VAL, PageChangeEvent, PageUploadLimitService, PaginationWeek, PendingFiles, PendingPaymentComponent, PendingUploadService, PlaceOfOrigin, Portail, PostalLocality, Preferences, RECAPTCHA_API_URL, RecaptchaService, RedirectComponent, RegisterNgModelService, RowElement, SESSION_INFO_API_URL, SWISS_ISO_ID, ScrollHelper, SdkDictionaryPipe, SdkDictionaryService, SdkEpaymentComponent, SdkEvent, SdkEventType, SdkEventsLoggerService, SdkLog, SdkLogLevel, SdkLogsService, SdkRecaptchaComponent, SdkStatisticsService, SelectedSlot, Session, SessionInfo, SessionInfoData, SessionInfoWithApplicationService, Street, StreetNumber, StringHelper, THOUSANDS_SEPARATOR, TRANSMIT_WAITING_MODAL_DELAY_IN_MILLISECONDS, TableSort, UploadProgress, UploadProgressService, UploaderHelper, ValidationHandlerService, formatDecimalCurrency, formatNonDecimalCurrency, formatNumberAsGiven, gesdemLoaderGuard, getSafeFileNameForErrorMessage, providePrestationsNgCore, replaceAll, splitDocumentChanges };
16371
16426
  //# sourceMappingURL=dsivd-prestations-ng.mjs.map