@elasticias/core 1.0.27 → 1.0.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.
@@ -252,28 +252,133 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
252
252
  args: [{ providedIn: 'root' }]
253
253
  }] });
254
254
 
255
+ /** Built-in fallbacks, used only when a translation is missing, so a
256
+ * consuming app that has not yet added the keys still gets a readable
257
+ * dialog instead of a raw key (or worse, an empty message under an
258
+ * irreversible action). */
259
+ const FALLBACKS = {
260
+ ef_confirm_header: 'Confirmation',
261
+ ef_confirm_message_generic: 'Are you sure you want to continue?',
262
+ ef_confirm_accept: 'Confirm',
263
+ ef_confirm_cancel: 'Cancel',
264
+ ef_confirm_delete_header: 'Confirm deletion',
265
+ ef_confirm_delete_accept: 'Delete',
266
+ ef_confirm_delete_message: 'Are you sure you want to delete "{{name}}"? This action cannot be undone.',
267
+ ef_confirm_delete_message_generic: 'Are you sure you want to delete this item? This action cannot be undone.',
268
+ };
269
+ /** Per-intent defaults. `confirm()` merges the caller's options over these. */
270
+ const INTENT_DEFAULTS = {
271
+ generic: {
272
+ headerKey: 'ef_confirm_header',
273
+ acceptLabelKey: 'ef_confirm_accept',
274
+ rejectLabelKey: 'ef_confirm_cancel',
275
+ icon: 'pi pi-exclamation-triangle',
276
+ messageKey: 'ef_confirm_message_generic',
277
+ },
278
+ delete: {
279
+ headerKey: 'ef_confirm_delete_header',
280
+ acceptLabelKey: 'ef_confirm_delete_accept',
281
+ rejectLabelKey: 'ef_confirm_cancel',
282
+ icon: 'pi pi-exclamation-triangle',
283
+ messageKey: 'ef_confirm_delete_message_generic',
284
+ namedMessageKey: 'ef_confirm_delete_message',
285
+ },
286
+ };
287
+ /**
288
+ * The app-wide confirmation modal, driven through PrimeNG's
289
+ * `ConfirmationService` and rendered by `<ef-confirm-dialog>`.
290
+ *
291
+ * Two call shapes:
292
+ *
293
+ * ```ts
294
+ * // Options — the one to reach for.
295
+ * confirmDialogService.confirm({
296
+ * intent: 'delete',
297
+ * name: client.name, // "Delete ANDALOCY PARFUMS?"
298
+ * accept: () => this.remove(),
299
+ * });
300
+ *
301
+ * // Legacy positional form, kept so existing callers keep compiling.
302
+ * confirmDialogService.confirm('Already-translated question?', onYes, onNo);
303
+ * ```
304
+ */
255
305
  class ConfirmDialogService {
256
306
  confirmationService = inject(ConfirmationService);
257
- confirm(message, acceptCallback, rejectCallback, event) {
307
+ /**
308
+ * Lazy holder. Resolving `TranslateService` at construction time pulls
309
+ * in HttpClient and, through the interceptor chain, services that
310
+ * inject this one — the same cycle `EfToastService` documents. Defer
311
+ * to the first actual `confirm()` call, which is always well after
312
+ * bootstrap.
313
+ */
314
+ injector = inject(Injector);
315
+ _translate;
316
+ confirm(messageOrOptions, acceptCallback, rejectCallback, event) {
317
+ const options = typeof messageOrOptions === 'string'
318
+ ? { message: messageOrOptions, accept: acceptCallback, reject: rejectCallback, event }
319
+ : messageOrOptions;
320
+ const defaults = INTENT_DEFAULTS[options.intent ?? 'generic'];
321
+ const name = options.name?.toString().trim() || undefined;
258
322
  this.confirmationService.confirm({
259
- target: event ? event.target : undefined,
260
- message,
261
- header: 'Confirmation',
323
+ target: options.event?.target ?? undefined,
324
+ message: this.resolveMessage(options, defaults, name),
325
+ header: options.header ?? this.t(options.headerKey ?? defaults.headerKey),
262
326
  closable: true,
263
327
  closeOnEscape: true,
264
- icon: 'pi pi-exclamation-triangle',
328
+ icon: options.icon ?? defaults.icon,
265
329
  rejectButtonProps: {
266
- label: 'Annuler',
330
+ label: this.t(options.rejectLabelKey ?? defaults.rejectLabelKey),
267
331
  severity: 'secondary',
268
332
  outlined: true,
269
333
  },
270
334
  acceptButtonProps: {
271
- label: 'Confirmer',
335
+ label: this.t(options.acceptLabelKey ?? defaults.acceptLabelKey),
336
+ // Semantics. The visual weight comes from the style class
337
+ // below, because `.es-confirm .p-confirmdialog-accept-button`
338
+ // in `_patterns.scss` paints the button at a specificity a
339
+ // severity class cannot reach.
340
+ severity: options.intent === 'delete' ? 'danger' : undefined,
272
341
  },
273
- accept: () => acceptCallback?.(),
274
- reject: () => rejectCallback?.(),
342
+ // `.btn.btn-danger` is declared after the `.es-confirm` accept
343
+ // rule at equal specificity, so it is what finally colours a
344
+ // destructive confirm red instead of ordinary primary ink.
345
+ acceptButtonStyleClass: options.intent === 'delete' ? 'btn btn-danger' : undefined,
346
+ accept: () => options.accept?.(),
347
+ reject: () => options.reject?.(),
275
348
  });
276
349
  }
350
+ /**
351
+ * Sugar for `confirm({ intent: 'delete', ... })`.
352
+ *
353
+ * ```ts
354
+ * confirmDialogService.confirmDelete({ name: row.label, accept: () => … });
355
+ * ```
356
+ */
357
+ confirmDelete(options = {}) {
358
+ this.confirm({ ...options, intent: 'delete' });
359
+ }
360
+ /* ── Internals ─────────────────────────────────────────────── */
361
+ resolveMessage(options, defaults, name) {
362
+ if (options.messageKey) {
363
+ return this.t(options.messageKey, { ...options.messageParams, name: escapeHtml(name ?? '') });
364
+ }
365
+ if (options.message != null)
366
+ return options.message;
367
+ // A named message when we know what is being acted on, the generic
368
+ // one otherwise — so a caller with no name still reads correctly.
369
+ const key = name && defaults.namedMessageKey ? defaults.namedMessageKey : defaults.messageKey;
370
+ return this.t(key, { ...options.messageParams, name: escapeHtml(name ?? '') });
371
+ }
372
+ t(key, params) {
373
+ this._translate ??= this.injector.get(TranslateService);
374
+ const value = this._translate.instant(key, params);
375
+ // `instant()` hands back the key when nothing is loaded for it.
376
+ // Never show that to a user who is about to destroy something.
377
+ if (value !== key)
378
+ return value;
379
+ const fallback = FALLBACKS[key];
380
+ return fallback ? interpolate(fallback, params) : '';
381
+ }
277
382
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.11", ngImport: i0, type: ConfirmDialogService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
278
383
  static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.11", ngImport: i0, type: ConfirmDialogService, providedIn: 'root' });
279
384
  }
@@ -281,6 +386,27 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
281
386
  type: Injectable,
282
387
  args: [{ providedIn: 'root' }]
283
388
  }] });
389
+ /**
390
+ * PrimeNG renders the confirm message through `[innerHTML]`. Angular
391
+ * sanitizes it, so this is not about script execution — it is about an
392
+ * entity name containing `<`, `>` or `&` rendering as markup or being
393
+ * silently swallowed. "Renault < Dacia" must read as itself.
394
+ */
395
+ function escapeHtml(value) {
396
+ return value
397
+ .replace(/&/g, '&amp;')
398
+ .replace(/</g, '&lt;')
399
+ .replace(/>/g, '&gt;')
400
+ .replace(/"/g, '&quot;')
401
+ .replace(/'/g, '&#39;');
402
+ }
403
+ /** Minimal `{{param}}` substitution for the built-in fallbacks, which
404
+ * never reach ngx-translate's own interpolator. */
405
+ function interpolate(template, params) {
406
+ if (!params)
407
+ return template;
408
+ return template.replace(/\{\{\s*(\w+)\s*\}\}/g, (match, key) => params[key] == null ? match : String(params[key]));
409
+ }
284
410
 
285
411
  /**
286
412
  * Creates a reusable Angular route guard that checks screen-level permissions.
@@ -717,19 +843,51 @@ const ComptoirPreset = definePreset(Lara, {
717
843
  hoverColor: '{primary.300}',
718
844
  activeColor: '{primary.200}'
719
845
  },
846
+ /* The ramp runs in the SAME direction as the light one, and
847
+ * that is deliberate — it used to be inverted here (0 = black
848
+ * … 950 = near-white) and that single flip was the cause of
849
+ * dark mode being unreadable product-wide.
850
+ *
851
+ * PrimeNG's surface ramp is not "light values for light mode,
852
+ * dark values for dark mode". It is a fixed light→dark scale
853
+ * that the *semantic* block indexes differently per scheme:
854
+ * light reads `{surface.0}` as the page and `{surface.700}` as
855
+ * body text, dark reads `{surface.900}` as the page and
856
+ * `{surface.0}` as body text. Every component preset inherits
857
+ * those conventions. Inverting the ramp therefore inverted
858
+ * every inherited value at once — dark `text.color` resolved
859
+ * to #000000, `content.background` to #f1f3f6, and
860
+ * `button.text.secondary.color` to #2f3239 on a #1d1f24 card
861
+ * (1.28:1, the reported bug).
862
+ *
863
+ * Keeping the ramp upright makes the ink scale land exactly on
864
+ * the Comptoir dark aliases from `_comptoir.scss`:
865
+ * surface.900 → --paper (#0f1115)
866
+ * surface.800 → --paper-alt (#1d1f24)
867
+ * surface.400 → --text-mute (#9ca5b3)
868
+ * surface.50 → --text (#f8f9fb)
869
+ * so inherited PrimeNG values agree with the design system
870
+ * instead of fighting it. */
720
871
  surface: {
721
- 0: '#000000',
722
- 50: '#06070a',
723
- 100: '#0f1115',
724
- 200: '#1d1f24',
725
- 300: '#2f3239',
726
- 400: '#4a4f5a',
872
+ 0: '#ffffff',
873
+ 50: '#f8f9fb',
874
+ 100: '#f1f3f6',
875
+ 200: '#e4e8ee',
876
+ 300: '#cdd3dd',
877
+ 400: '#9ca5b3',
727
878
  500: '#6c7280',
728
- 600: '#9ca5b3',
729
- 700: '#cdd3dd',
730
- 800: '#e4e8ee',
731
- 900: '#f1f3f6',
732
- 950: '#f8f9fb'
879
+ 600: '#4a4f5a',
880
+ 700: '#2f3239',
881
+ 800: '#1d1f24',
882
+ 900: '#0f1115',
883
+ 950: '#06070a'
884
+ },
885
+ /* Lara's dark body text is `{surface.0}` = pure white; Comptoir's
886
+ * --text is --ink-50. Pin it so the two agree. 17.94:1 on
887
+ * --paper, 15.65:1 on --paper-alt. */
888
+ text: {
889
+ color: '{surface.50}',
890
+ hoverColor: '{surface.50}'
733
891
  },
734
892
  highlight: {
735
893
  background: '{primary.400}',
@@ -739,6 +897,79 @@ const ComptoirPreset = definePreset(Lara, {
739
897
  }
740
898
  }
741
899
  }
900
+ },
901
+ /* ──────────────────────────────────────────────────────────────
902
+ * Button: the low-emphasis variants.
903
+ *
904
+ * An upright surface ramp (above) fixes everything Lara expresses
905
+ * through `{surface.N}`. It cannot fix the variants Lara expresses
906
+ * through the accent and through raw Tailwind reds, because those
907
+ * were tuned against Lara's own indigo/zinc, not against the
908
+ * Comptoir tenant ramp. Measured on the default parfumerie accent,
909
+ * against --paper (#0f1115) / --paper-alt (#1d1f24) in dark and
910
+ * #ffffff / --paper (#f8f9fb) in light, resting state:
911
+ *
912
+ * dark text.primary {primary.400} #934e74 → 3.22 / 2.81 ✗
913
+ * dark outlined.primary.border {primary.700} #401a30 → 1.27 / 1.11 ✗
914
+ * dark outlined.secondary.border {surface.700} → 1.47 / 1.28 ✗
915
+ * dark outlined.danger.border {red.700} → 2.92 / 2.55 ✗
916
+ * light text.danger {red.500} #ef4444 → 3.76 / 3.57 ✗
917
+ * light outlined.primary.border {primary.200} → 1.87 / 1.77 ✗
918
+ * light outlined.secondary.border {surface.200} → 1.19 / 1.13 ✗
919
+ *
920
+ * Text colours below clear 4.5:1 in every state (resting, hover
921
+ * tint and the 16% active tint); border colours clear the 3:1
922
+ * WCAG 1.4.11 bar for a component boundary without brightening
923
+ * into something that reads as a fill.
924
+ *
925
+ * The severities Comptoir actually ships on `<ef-button>` are
926
+ * primary / secondary / danger; success, info, warn, help and
927
+ * contrast are left on stock, which the upright ramp already
928
+ * makes legible.
929
+ *
930
+ * Caveat: `{primary.N}` tracks the tenant accent through
931
+ * `EfThemeConfigService.setTenantAccent()`, so these ratios hold
932
+ * for the default ramp. A very dark or very light tenant accent
933
+ * would need a lightness clamp in the ramp generator — noted, not
934
+ * built. */
935
+ components: {
936
+ button: {
937
+ colorScheme: {
938
+ light: {
939
+ text: {
940
+ /* {primary.color} (= {primary.500}) already reads
941
+ * 9.25 / 8.78 — left on stock so it keeps tracking
942
+ * the tenant accent. */
943
+ danger: { color: '{red.700}' } /* 6.47 / 6.14 */
944
+ },
945
+ outlined: {
946
+ primary: { borderColor: '{primary.300}' }, /* 3.34 / 3.17 */
947
+ secondary: { color: '{surface.600}', borderColor: '{surface.500}' }, /* 8.21 / 7.80 · border 4.82 / 4.58 */
948
+ danger: { color: '{red.700}', borderColor: '{red.500}' } /* 6.47 / 6.14 · border 3.76 / 3.57 */
949
+ }
950
+ },
951
+ dark: {
952
+ text: {
953
+ primary: { color: '{primary.200}' }, /* 10.13 / 8.84 */
954
+ secondary: { color: '{surface.300}' }, /* 12.56 / 10.96 — the reported 1.28 pair */
955
+ danger: { color: '{red.400}' } /* 6.83 / 5.96 */
956
+ },
957
+ outlined: {
958
+ primary: { color: '{primary.200}', borderColor: '{primary.300}' }, /* 10.13 / 8.84 · border 5.65 / 4.93 */
959
+ secondary: { color: '{surface.300}', borderColor: '{surface.500}' }, /* 12.56 / 10.96 · border 3.92 / 3.42 */
960
+ danger: { color: '{red.400}', borderColor: '{red.500}' } /* 6.83 / 5.96 · border 5.02 / 4.38 */
961
+ },
962
+ /* `[link]="true"` carries no ground of its own, so it sits
963
+ * straight on --paper / --paper-alt: {primary.color} reads
964
+ * 3.22 / 2.81 there. Same lift as the text variant. */
965
+ link: {
966
+ color: '{primary.200}', /* 10.13 / 8.84 */
967
+ hoverColor: '{primary.100}',
968
+ activeColor: '{primary.100}'
969
+ }
970
+ }
971
+ }
972
+ }
742
973
  }
743
974
  });
744
975
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"elasticias-core.mjs","sources":["../../../../libs/core/src/lib/services/loader.service.ts","../../../../libs/core/src/lib/services/cache.service.ts","../../../../libs/core/src/lib/services/toast.service.ts","../../../../libs/core/src/lib/services/confirm-dialog.service.ts","../../../../libs/core/src/lib/guards/screen.guard.ts","../../../../libs/core/src/lib/theme/app-state.ts","../../../../libs/core/src/lib/theme/ef-theme-config.service.ts","../../../../libs/core/src/lib/theme/ef-theme.ts","../../../../libs/core/src/lib/theme/locales/primeng-en.ts","../../../../libs/core/src/lib/theme/locales/primeng-fr.ts","../../../../libs/core/src/lib/theme/locales/primeng-ar.ts","../../../../libs/core/src/lib/modules/ef-module-registry.ts","../../../../libs/core/src/lib/modules/ef-active-module.service.ts","../../../../libs/core/src/lib/responsive/ef-viewport.service.ts","../../../../libs/core/src/lib/auth/ef-permission.service.ts","../../../../libs/core/src/lib/auth/ef-session.token.ts","../../../../libs/core/src/lib/build/ef-build-info.token.ts","../../../../libs/core/src/lib/i18n/ef-versioned-translate-loader.ts","../../../../libs/core/src/lib/shortcuts/shortcut-keys.ts","../../../../libs/core/src/lib/shortcuts/format-shortcut.ts","../../../../libs/core/src/lib/shortcuts/ef-shortcut.service.ts","../../../../libs/core/src/elasticias-core.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { BehaviorSubject } from 'rxjs';\n\n@Injectable({ providedIn: 'root' })\nexport class LoaderService {\n private loadingSubject = new BehaviorSubject<boolean>(false);\n isLoading$ = this.loadingSubject.asObservable();\n\n show(): void {\n this.loadingSubject.next(true);\n }\n\n hide(): void {\n this.loadingSubject.next(false);\n }\n}\n","import { Injectable } from '@angular/core';\nimport { StorageUtils } from '@elasticias/utils';\n\n@Injectable({ providedIn: 'root' })\nexport class CacheService {\n private cache: Record<string, unknown> = {};\n private useLocalStorage = false;\n\n configure(useLocalStorage = false): void {\n this.useLocalStorage = useLocalStorage;\n }\n\n getCache<T>(key: string): T | null {\n return this.useLocalStorage ? StorageUtils.getLocal<T>(key) : (this.cache[key] as T) ?? null;\n }\n\n setCache(key: string, value: unknown): void {\n if (this.useLocalStorage) {\n StorageUtils.setLocal(key, value);\n } else {\n this.cache[key] = value;\n }\n }\n\n updateCache(key: string, newValue: unknown): void {\n if (this.useLocalStorage) {\n const current = StorageUtils.getLocal(key);\n if (current && typeof current === 'object' && typeof newValue === 'object') {\n StorageUtils.setLocal(key, { ...(current as object), ...(newValue as object) });\n } else {\n StorageUtils.setLocal(key, newValue);\n }\n } else {\n const current = this.cache[key];\n if (current && typeof current === 'object' && typeof newValue === 'object') {\n this.cache[key] = { ...(current as object), ...(newValue as object) };\n } else {\n this.cache[key] = newValue;\n }\n }\n }\n\n removeCache(key: string): void {\n if (this.useLocalStorage) {\n StorageUtils.removeLocal(key);\n } else {\n delete this.cache[key];\n }\n }\n\n clearAllCache(): void {\n if (this.useLocalStorage) {\n StorageUtils.clearLocal();\n } else {\n this.cache = {};\n }\n }\n\n hasCache(key: string): boolean {\n return this.useLocalStorage ? StorageUtils.existsLocal(key) : key in this.cache;\n }\n}\n","import { Injectable, Injector, inject, signal } from '@angular/core';\nimport { TranslateService } from '@ngx-translate/core';\nimport { MessageService } from 'primeng/api';\n\n/**\n * Toast severities — mapped 1:1 to the Comptoir status spectrum:\n * `info` → processing, `success` → delivered, `warn` → pending,\n * `error` → cancelled.\n */\nexport type EfToastSeverity = 'info' | 'success' | 'warn' | 'error';\n\n/** Optional inline action button rendered at the end of a toast. */\nexport interface EfToastAction {\n /** Translation key for the button label — preferred. */\n labelKey?: string;\n /** Direct label fallback when `labelKey` is empty. */\n label?: string;\n\n /** Visual tone — `'ghost'` (default) or `'primary'` for the\n * destructive / confirm action. */\n severity?: 'ghost' | 'primary';\n\n /** Click handler. */\n command?: () => void;\n\n /** Auto-close the toast after the click runs (default `true`). */\n dismissOnClick?: boolean;\n}\n\n/**\n * Toast options accepted by `EfToastService.show()`. Either a literal\n * `title` / `text` or their `*Key` translation variants — keys win\n * unless empty.\n */\nexport interface EfToastOptions {\n severity?: EfToastSeverity;\n title?: string;\n titleKey?: string;\n text?: string;\n textKey?: string;\n /** Auto-dismiss in ms; `0` = sticky (no auto-dismiss). */\n life?: number;\n actions?: EfToastAction[];\n}\n\n/** Active toast — instance held in `EfToastService.toasts`. */\nexport interface EfToast {\n id: number;\n severity: EfToastSeverity;\n title: string;\n text: string;\n life: number;\n actions?: EfToastAction[];\n}\n\n/**\n * Comptoir toast service — V2 successor to the legacy `ToastService`.\n *\n * Owns a signal-based queue (`toasts`) consumed by\n * `<ef-toast-region>`, AND forwards every toast to PrimeNG's\n * `MessageService` for back-compat with `<p-toast>` (still used by\n * ClientApp v1). Either renderer picks the toasts up; both work.\n *\n * Default i18n keys (override per-call via `titleKey` / `textKey`):\n * - `ef_toast_info_title`, `ef_toast_info_default`\n * - `ef_toast_success_title`, `ef_toast_success_default`\n * - `ef_toast_warn_title`, `ef_toast_warn_default`\n * - `ef_toast_error_title`, `ef_toast_error_default`\n *\n * Default lifespans: info 5s, success 4s, warn 6s, error 8s.\n */\n@Injectable({ providedIn: 'root' })\nexport class EfToastService {\n private static readonly LIFE_INFO = 5000;\n private static readonly LIFE_SUCCESS = 4000;\n private static readonly LIFE_WARN = 6000;\n private static readonly LIFE_ERROR = 8000;\n\n /**\n * Lazy holders. Resolving TranslateService eagerly at construction\n * time pulls in HttpClient → HTTP_INTERCEPTORS → AuthorizeInterceptor\n * → AuthorizeService → ToastService → cycle. We defer to the first\n * actual translate / message-publish call.\n */\n private readonly injector = inject(Injector);\n private _translate?: TranslateService;\n private _messageService?: MessageService | null;\n private _messageServiceResolved = false;\n\n private nextId = 1;\n\n /** Live queue — `<ef-toast-region>` renders this. */\n readonly toasts = signal<ReadonlyArray<EfToast>>([]);\n\n /* ── Convenience methods (back-compat with the legacy\n ToastService signature: `(message?, title?, life?)`). ── */\n\n showInfo(message?: string, title?: string, life: number = EfToastService.LIFE_INFO): void {\n this.show({\n severity: 'info',\n title: title ?? this.t('ef_toast_info_title'),\n text: message ?? this.t('ef_toast_info_default'),\n life,\n });\n }\n\n showSuccess(message?: string, title?: string, life: number = EfToastService.LIFE_SUCCESS): void {\n this.show({\n severity: 'success',\n title: title ?? this.t('ef_toast_success_title'),\n text: message ?? this.t('ef_toast_success_default'),\n life,\n });\n }\n\n showWarn(message?: string, title?: string, life: number = EfToastService.LIFE_WARN): void {\n this.show({\n severity: 'warn',\n title: title ?? this.t('ef_toast_warn_title'),\n text: message ?? this.t('ef_toast_warn_default'),\n life,\n });\n }\n\n showError(message?: string, title?: string, life: number = EfToastService.LIFE_ERROR): void {\n this.show({\n severity: 'error',\n title: title ?? this.t('ef_toast_error_title'),\n text: message ?? this.t('ef_toast_error_default'),\n life,\n });\n }\n\n /** Generic show — opts can mix `title`/`titleKey`, `text`/`textKey`. */\n show(opts: EfToastOptions): EfToast {\n const severity = opts.severity ?? 'info';\n const toast: EfToast = {\n id: this.nextId++,\n severity,\n title: this.resolve(opts.title, opts.titleKey, this.defaultTitleKey(severity)),\n text: this.resolve(opts.text, opts.textKey, undefined),\n life: opts.life ?? this.defaultLife(severity),\n actions: opts.actions,\n };\n\n // Collapse a burst of identical toasts into one. A dashboard fans\n // out to many independent queries, so one rejected filter used to\n // stack the same message once per widget -- seven copies of \"a\n // validation error occurred\", burying the screen. Only toasts that\n // are still on screen dedupe, so the same message shown again later\n // still appears.\n const duplicate = this.toasts().find(\n t =>\n t.severity === toast.severity &&\n t.title === toast.title &&\n t.text === toast.text,\n );\n if (duplicate) return duplicate;\n\n this.toasts.update(list => [...list, toast]);\n\n // Forward to PrimeNG MessageService so v1's <p-toast> still\n // catches the toast. Sticky in PrimeNG is `life: 0`.\n this.messageService?.add({\n severity: toast.severity,\n summary: toast.title,\n detail: toast.text,\n life: toast.life || undefined,\n sticky: toast.life === 0,\n });\n\n return toast;\n }\n\n private get messageService(): MessageService | null {\n if (!this._messageServiceResolved) {\n this._messageServiceResolved = true;\n this._messageService = this.injector.get(MessageService, null, { optional: true });\n }\n return this._messageService ?? null;\n }\n\n dismiss(id: number): void {\n this.toasts.update(list => list.filter(t => t.id !== id));\n }\n\n clear(): void {\n this.toasts.set([]);\n this.messageService?.clear();\n }\n\n /* (messageService getter is defined just below `show` to keep it\n close to where it's consumed.) */\n\n /* ── Internals ─────────────────────────────────────────────── */\n\n private resolve(\n literal: string | undefined,\n key: string | undefined,\n fallbackKey: string | undefined,\n ): string {\n if (literal != null) return literal;\n if (key) return this.t(key);\n if (fallbackKey) return this.t(fallbackKey);\n return '';\n }\n\n private t(key: string): string {\n // Lazy-resolve TranslateService — see the field comment above\n // for the AuthorizeService cycle this avoids.\n this._translate ??= this.injector.get(TranslateService);\n const value = this._translate.instant(key);\n // `instant()` returns the key when no translation is loaded;\n // fall through to empty string so untranslated toasts don't\n // surface internal keys to end users.\n return value === key ? '' : value;\n }\n\n private defaultLife(severity: EfToastSeverity): number {\n switch (severity) {\n case 'info': return EfToastService.LIFE_INFO;\n case 'success': return EfToastService.LIFE_SUCCESS;\n case 'warn': return EfToastService.LIFE_WARN;\n case 'error': return EfToastService.LIFE_ERROR;\n }\n }\n\n private defaultTitleKey(severity: EfToastSeverity): string {\n return `ef_toast_${severity}_title`;\n }\n}\n\n/**\n * @deprecated Use `EfToastService` — same instance, new name. The\n * alias keeps existing imports compiling during the v1 → V2\n * migration.\n */\nexport { EfToastService as ToastService };\n","import { inject, Injectable } from '@angular/core';\nimport { ConfirmationService } from 'primeng/api';\n\n@Injectable({ providedIn: 'root' })\nexport class ConfirmDialogService {\n private readonly confirmationService = inject(ConfirmationService);\n\n confirm(\n message: string,\n acceptCallback?: () => void,\n rejectCallback?: () => void,\n event?: Event\n ): void {\n this.confirmationService.confirm({\n target: event ? (event.target as EventTarget) : undefined,\n message,\n header: 'Confirmation',\n closable: true,\n closeOnEscape: true,\n icon: 'pi pi-exclamation-triangle',\n rejectButtonProps: {\n label: 'Annuler',\n severity: 'secondary',\n outlined: true,\n },\n acceptButtonProps: {\n label: 'Confirmer',\n },\n accept: () => acceptCallback?.(),\n reject: () => rejectCallback?.(),\n });\n }\n}\n","import { inject } from '@angular/core';\nimport { CanActivateFn, ActivatedRouteSnapshot, Router } from '@angular/router';\nimport { StorageUtils } from '@elasticias/utils';\nimport { Permissions } from '@elasticias/types';\n\n/**\n * Configuration for the screen guard factory.\n */\nexport interface ScreenGuardConfig {\n /** Storage key where screen grants are stored (default: 'CURRENT_USER_GRANTS') */\n grantsStorageKey?: string;\n /** Route to redirect to when access is denied (default: '/') */\n deniedRedirect?: string;\n /** Minimum required permission to access the screen (default: Permissions.Read) */\n requiredPermission?: Permissions;\n /** Storage type to read grants from (default: 'session') */\n storageType?: 'local' | 'session';\n}\n\n/**\n * Creates a reusable Angular route guard that checks screen-level permissions.\n *\n * Usage in route definitions:\n * ```typescript\n * {\n * path: 'countries',\n * data: { screenCode: 'Countries' },\n * canActivate: [screenGuard()],\n * children: [\n * { path: '', component: CountriesComponent },\n * { path: 'details/:id', component: CountriesDetailsComponent },\n * ]\n * }\n * ```\n *\n * The guard reads the `screenCode` from route data (traversing parent routes)\n * and checks if the current user has at least the required permission (default: Read).\n */\nexport function screenGuard(config?: ScreenGuardConfig): CanActivateFn {\n return (route: ActivatedRouteSnapshot) => {\n const router = inject(Router);\n const grantsKey = config?.grantsStorageKey ?? 'CURRENT_USER_GRANTS';\n const deniedRedirect = config?.deniedRedirect ?? '/';\n const requiredPermission = config?.requiredPermission ?? Permissions.Read;\n const storageType = config?.storageType ?? 'local';\n\n const screenCode = getScreenCode(route);\n\n // If no screenCode found on this route or any parent, allow access\n if (!screenCode) {\n return true;\n }\n\n const screenGrants = storageType === 'session'\n ? StorageUtils.getSession<Record<string, { permissions?: string[] }>>(grantsKey)\n : StorageUtils.getLocal<Record<string, { permissions?: string[] }>>(grantsKey);\n\n if (!screenGrants) {\n router.navigate([deniedRedirect]);\n return false;\n }\n\n const grant = screenGrants[screenCode];\n if (!grant?.permissions?.includes(requiredPermission)) {\n router.navigate([deniedRedirect]);\n return false;\n }\n\n return true;\n };\n}\n\n/**\n * Walks up the route tree to find the nearest screenCode in route data.\n */\nfunction getScreenCode(route: ActivatedRouteSnapshot): string | undefined {\n let current: ActivatedRouteSnapshot | null = route;\n while (current) {\n const code = current.data?.['screenCode'] as string | undefined;\n if (code) return code;\n current = current.parent;\n }\n return undefined;\n}\n\n/**\n * Utility function to check if the current user has a specific permission on a screen.\n * Can be used in components/services outside of route guards.\n */\nexport function hasScreenPermission(\n screenCode: string,\n permission: Permissions,\n grantsStorageKey = 'CURRENT_USER_GRANTS',\n storageType: 'local' | 'session' = 'local'\n): boolean {\n const screenGrants = storageType === 'session'\n ? StorageUtils.getSession<Record<string, { permissions?: string[] }>>(grantsStorageKey)\n : StorageUtils.getLocal<Record<string, { permissions?: string[] }>>(grantsStorageKey);\n if (!screenGrants) return false;\n\n const grant = screenGrants[screenCode];\n return grant?.permissions?.includes(permission) ?? false;\n}\n","export interface AppState {\n preset?: string;\n primary?: string;\n surface?: string;\n darkTheme?: boolean;\n menuActive?: boolean;\n mobileMenuVisible?: boolean;\n designerKey?: string;\n RTL?: boolean;\n}\n\nexport const DEFAULT_APP_STATE: AppState = {\n preset: 'Lara',\n primary: 'noir',\n surface: null as any,\n darkTheme: false,\n menuActive: true,\n mobileMenuVisible: false,\n designerKey: 'primeng-designer-theme',\n RTL: false\n};\n","import { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { computed, effect, inject, Injectable, PLATFORM_ID, signal } from '@angular/core';\nimport { palette, updatePrimaryPalette } from '@primeng/themes';\nimport { StorageUtils } from '@elasticias/utils';\nimport { AppState, DEFAULT_APP_STATE } from './app-state';\n\n/**\n * Service that manages theme state: preset, primary color, surface, dark mode, RTL.\n * State is persisted to localStorage so user preferences survive page reloads.\n *\n * Apps can extend this service or use it directly.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class EfThemeConfigService {\n private readonly STORAGE_KEY = 'APP_CONFIG_STATE';\n\n appState = signal<AppState>(null as any);\n\n designerActive = signal(false);\n\n newsActive = signal(false);\n\n document = inject(DOCUMENT);\n\n platformId = inject(PLATFORM_ID);\n\n theme = computed(() => (this.appState()?.darkTheme ? 'dark' : 'light'));\n\n transitionComplete = signal<boolean>(false);\n\n constructor() {\n const initialState = this.loadAppState();\n this.appState.set({ ...initialState });\n\n // Apply preset class + RTL synchronously so the first paint has\n // the right theme — the effect below picks up subsequent changes\n // (including any subclass `appState.update()` issued before its\n // first run).\n this.updatePresetClass(initialState);\n if (isPlatformBrowser(this.platformId) && initialState?.RTL) {\n this.document.documentElement.setAttribute('dir', 'rtl');\n }\n\n effect(() => {\n const state = this.appState();\n if (!state) return;\n this.saveAppState(state);\n this.updatePresetClass(state);\n this.handleDarkModeTransition(state);\n this.applyRTL(state);\n });\n }\n\n private static readonly PRESET_CLASS_MAP: Record<string, string> = {\n Aura: 'theme-compact',\n Lara: 'theme-modern',\n Material: 'theme-material',\n Nora: 'theme-classic',\n Comptoir: 'theme-comptoir',\n };\n\n private static readonly TENANT_RAMP_STOPS = [50, 100, 200, 300, 400, 500, 600, 700, 800, 900] as const;\n\n private static readonly ALL_THEME_CLASSES = Object.values(EfThemeConfigService.PRESET_CLASS_MAP);\n\n private updatePresetClass(state: AppState): void {\n if (isPlatformBrowser(this.platformId)) {\n const body = this.document.body;\n body.classList.remove(...EfThemeConfigService.ALL_THEME_CLASSES);\n if (state.preset) {\n const cls = EfThemeConfigService.PRESET_CLASS_MAP[state.preset];\n if (cls) {\n body.classList.add(cls);\n }\n }\n }\n }\n\n private handleDarkModeTransition(state: AppState): void {\n if (isPlatformBrowser(this.platformId)) {\n if ((document as any).startViewTransition) {\n this.startViewTransition(state);\n } else {\n this.toggleDarkMode(state);\n this.onTransitionEnd();\n }\n }\n }\n\n private startViewTransition(state: AppState): void {\n const transition = (document as any).startViewTransition(() => {\n this.toggleDarkMode(state);\n });\n\n transition.ready\n .then(() => this.onTransitionEnd())\n .catch(() => { /* view transition aborted */ });\n }\n\n private toggleDarkMode(state: AppState): void {\n if (state.darkTheme) {\n this.document.documentElement.classList.add('p-dark');\n } else {\n this.document.documentElement.classList.remove('p-dark');\n }\n }\n\n private onTransitionEnd() {\n this.transitionComplete.set(true);\n setTimeout(() => {\n this.transitionComplete.set(false);\n });\n }\n\n private applyRTL(state: AppState): void {\n if (isPlatformBrowser(this.platformId)) {\n const setDir = () => {\n if (state.RTL) {\n this.document.documentElement.setAttribute('dir', 'rtl');\n } else {\n this.document.documentElement.removeAttribute('dir');\n }\n };\n\n if ((document as any).startViewTransition) {\n const t = (document as any).startViewTransition(() => setDir());\n t.ready.catch(() => { /* view transition aborted */ });\n } else {\n setDir();\n }\n }\n }\n\n hideMenu() {\n this.appState.update((state) => ({ ...state, menuActive: false }));\n }\n\n showMenu() {\n this.appState.update((state) => ({ ...state, menuActive: true }));\n }\n\n toggleMobileMenu() {\n this.appState.update((state) => ({\n ...state,\n mobileMenuVisible: !state.mobileMenuVisible\n }));\n }\n\n closeMobileMenu() {\n this.appState.update((state) => ({\n ...state,\n mobileMenuVisible: false\n }));\n }\n\n openMobileMenu() {\n this.appState.update((state) => ({\n ...state,\n mobileMenuVisible: true\n }));\n }\n\n hideNews() {\n this.newsActive.set(false);\n }\n\n showNews() {\n this.newsActive.set(true);\n }\n\n showDesigner() {\n this.designerActive.set(true);\n }\n\n hideDesigner() {\n this.designerActive.set(false);\n }\n\n private loadAppState(): AppState {\n if (isPlatformBrowser(this.platformId)) {\n const storedState = StorageUtils.getLocal<AppState>(this.STORAGE_KEY);\n if (storedState) {\n return storedState;\n }\n }\n return { ...DEFAULT_APP_STATE };\n }\n\n private saveAppState(state: AppState): void {\n if (isPlatformBrowser(this.platformId)) {\n StorageUtils.setLocal(this.STORAGE_KEY, state);\n }\n }\n\n /**\n * Applies a tenant's brand color across both PrimeNG's primary palette\n * and the Comptoir `--tenant-*` CSS variables.\n *\n * Generates a 50–950 ramp from the input hex via PrimeNG's `palette()`\n * helper, hands the full ramp to `updatePrimaryPalette()`, and writes\n * stops 50–900 onto `documentElement.style` so the SCSS layer's\n * `var(--tenant-*)` references resolve to the tenant's color.\n *\n * Call this whenever the active tenant changes (e.g., from an effect\n * watching `tenantService.storeConfig().primaryColor`).\n */\n setTenantAccent(hex: string): void {\n if (!hex) return;\n\n const ramp = palette(hex) as Record<string, string>;\n if (!ramp) return;\n\n updatePrimaryPalette(ramp);\n\n if (isPlatformBrowser(this.platformId)) {\n const root = this.document.documentElement;\n for (const stop of EfThemeConfigService.TENANT_RAMP_STOPS) {\n const value = ramp[String(stop)];\n if (value) {\n root.style.setProperty(`--tenant-${stop}`, value);\n }\n }\n }\n }\n}\n","import { definePreset } from '@primeng/themes';\nimport Aura from '@primeng/themes/aura';\nimport Lara from '@primeng/themes/lara';\n\n/* ──────────────────────────────────────────────────────────────────\n * LEGACY: Noir preset (Aura base, monochrome surface palette).\n * Kept for backward-compat with apps that haven't migrated to\n * Comptoir. Phase 5 of the design-system plan retrofits consumers\n * to EfComptoirTheme; once that lands, Noir + EfTheme can be\n * deleted.\n * ────────────────────────────────────────────────────────────── */\n\nconst Noir = definePreset(Aura, {\n semantic: {\n primary: {\n 50: '{surface.50}',\n 100: '{surface.100}',\n 200: '{surface.200}',\n 300: '{surface.300}',\n 400: '{surface.400}',\n 500: '{surface.500}',\n 600: '{surface.600}',\n 700: '{surface.700}',\n 800: '{surface.800}',\n 900: '{surface.900}',\n 950: '{surface.950}'\n },\n colorScheme: {\n light: {\n primary: {\n color: '{primary.950}',\n contrastColor: '#ffffff',\n hoverColor: '{primary.800}',\n activeColor: '{primary.700}'\n },\n highlight: {\n background: '{primary.950}',\n focusBackground: '{primary.700}',\n color: '#ffffff',\n focusColor: '#ffffff'\n }\n },\n dark: {\n primary: {\n color: '{primary.50}',\n contrastColor: '{primary.950}',\n hoverColor: '{primary.200}',\n activeColor: '{primary.300}'\n },\n highlight: {\n background: '{primary.50}',\n focusBackground: '{primary.300}',\n color: '{primary.950}',\n focusColor: '{primary.950}'\n }\n }\n }\n }\n});\n\n/**\n * Default Elasticias theme configuration for PrimeNG.\n * Uses the Noir preset (surface-based primary colors) with dark mode support.\n *\n * @deprecated Migrate to {@link EfComptoirTheme} as part of Phase 5 of the\n * design-system plan. Will be removed once all consumers have moved.\n */\nexport const EfTheme = {\n preset: Noir,\n options: {\n darkModeSelector: '.p-dark',\n }\n};\n\nexport default EfTheme;\n\n/* ──────────────────────────────────────────────────────────────────\n * COMPTOIR: ink surface + tenant primary (Lara base).\n * Surface palette is the ink ramp from libs/tokens/colors.json.\n * Primary palette defaults to the parfumerie sample tenant; it is\n * runtime-replaced by EfThemeConfigService.setTenantAccent(hex)\n * via PrimeNG's updatePrimaryPalette() API.\n * ────────────────────────────────────────────────────────────── */\n\nconst ComptoirPreset = definePreset(Lara, {\n semantic: {\n primary: {\n 50: '#f7f0f4',\n 100: '#ecdce5',\n 200: '#d8b4c5',\n 300: '#b87a99',\n 400: '#934e74',\n 500: '#6f3257',\n 600: '#54243f',\n 700: '#401a30',\n 800: '#2c1221',\n 900: '#1a0913',\n 950: '#0d040a'\n },\n /* ──────────────────────────────────────────────────────────────\n * Control sizing (ADR-009). The native \"comptoir\" variant is the\n * default render path and is pinned to --hit-base (40px) in CSS;\n * these tokens align the OPT-IN PrimeNG variant (p-select filter,\n * p-multiselect, p-inputnumber stepper, etc.) to the same canonical\n * heights so the two paths agree:\n * base → 40px (--hit-base) sm → 32px (--hit) lg → 48px (--hit-touch, POS/mobile)\n * Lara form-field height ≈ paddingY*2 + lineHeight(1.5)*fontSize(14px) + 2px border.\n * base: 8px*2 + 21 + 2 ≈ 40px · sm: 5px*2 + ~18 + 2 ≈ 32px · lg: 12px*2 + 21 + 2 ≈ 48px\n * NOTE: exact pixel height depends on the app's root font-size; the\n * native default path is the verified one — confirm the PrimeNG\n * opt-in controls visually in the running app and nudge paddingY if\n * they read 1-2px off. Border radius matches --r-md (12px). */\n formField: {\n paddingX: '0.75rem',\n paddingY: '0.5rem',\n borderRadius: '12px',\n sm: {\n fontSize: '0.78rem',\n paddingX: '0.625rem',\n paddingY: '0.3125rem'\n },\n lg: {\n fontSize: '0.9375rem',\n paddingX: '0.875rem',\n paddingY: '0.75rem'\n }\n },\n colorScheme: {\n light: {\n primary: {\n color: '{primary.500}',\n contrastColor: '#ffffff',\n hoverColor: '{primary.600}',\n activeColor: '{primary.700}'\n },\n surface: {\n 0: '#ffffff',\n 50: '#f8f9fb',\n 100: '#f1f3f6',\n 200: '#e4e8ee',\n 300: '#cdd3dd',\n 400: '#9ca5b3',\n 500: '#6c7280',\n 600: '#4a4f5a',\n 700: '#2f3239',\n 800: '#1d1f24',\n 900: '#0f1115',\n 950: '#06070a'\n },\n highlight: {\n background: '{primary.500}',\n focusBackground: '{primary.600}',\n color: '#ffffff',\n focusColor: '#ffffff'\n }\n },\n dark: {\n primary: {\n color: '{primary.400}',\n contrastColor: '{primary.950}',\n hoverColor: '{primary.300}',\n activeColor: '{primary.200}'\n },\n surface: {\n 0: '#000000',\n 50: '#06070a',\n 100: '#0f1115',\n 200: '#1d1f24',\n 300: '#2f3239',\n 400: '#4a4f5a',\n 500: '#6c7280',\n 600: '#9ca5b3',\n 700: '#cdd3dd',\n 800: '#e4e8ee',\n 900: '#f1f3f6',\n 950: '#f8f9fb'\n },\n highlight: {\n background: '{primary.400}',\n focusBackground: '{primary.300}',\n color: '{primary.950}',\n focusColor: '{primary.950}'\n }\n }\n }\n }\n});\n\n/**\n * Comptoir theme configuration for PrimeNG (Phase 1 / design-system v0.2).\n * Surface palette = ink ramp; primary palette = tenant accent\n * (runtime-driven via `EfThemeConfigService.setTenantAccent(hex)`).\n *\n * Usage with providePrimeNG:\n * ```ts\n * providePrimeNG({ theme: EfComptoirTheme, ripple: true })\n * ```\n *\n * Pair with `state.preset = 'Comptoir'` so the body class becomes\n * `theme-comptoir` (avoids legacy `theme-modern` radius overrides).\n */\nexport const EfComptoirTheme = {\n preset: ComptoirPreset,\n options: {\n darkModeSelector: '.p-dark',\n }\n};\n","import { Translation } from 'primeng/api';\n\n/**\n * English locale for PrimeNG components.\n *\n * Usage:\n * ```ts\n * import { PRIMENG_EN_LOCALE } from '@elasticias/core';\n * this.primeng.translation = PRIMENG_EN_LOCALE;\n * ```\n */\nexport const PRIMENG_EN_LOCALE: Translation = {\n startsWith: 'Starts with',\n contains: 'Contains',\n notContains: 'Not contains',\n endsWith: 'Ends with',\n equals: 'Equals',\n notEquals: 'Not equals',\n noFilter: 'No Filter',\n lt: 'Less than',\n lte: 'Less than or equal to',\n gt: 'Greater than',\n gte: 'Greater than or equal to',\n dateIs: 'Date is',\n dateIsNot: 'Date is not',\n dateBefore: 'Date is before',\n dateAfter: 'Date is after',\n clear: 'Clear',\n apply: 'Apply',\n matchAll: 'Match All',\n matchAny: 'Match Any',\n addRule: 'Add Rule',\n removeRule: 'Remove Rule',\n accept: 'Yes',\n reject: 'No',\n choose: 'Choose',\n upload: 'Upload',\n cancel: 'Cancel',\n completed: 'Completed',\n pending: 'Pending',\n fileSizeTypes: ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],\n dayNames: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'],\n dayNamesShort: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],\n dayNamesMin: ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'],\n monthNames: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'],\n monthNamesShort: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],\n chooseYear: 'Choose Year',\n chooseMonth: 'Choose Month',\n chooseDate: 'Choose Date',\n prevDecade: 'Previous Decade',\n nextDecade: 'Next Decade',\n prevYear: 'Previous Year',\n nextYear: 'Next Year',\n prevMonth: 'Previous Month',\n nextMonth: 'Next Month',\n prevHour: 'Previous Hour',\n nextHour: 'Next Hour',\n prevMinute: 'Previous Minute',\n nextMinute: 'Next Minute',\n prevSecond: 'Previous Second',\n nextSecond: 'Next Second',\n am: 'AM',\n pm: 'PM',\n today: 'Today',\n weekHeader: 'Wk',\n firstDayOfWeek: 0,\n showMonthAfterYear: false,\n dateFormat: 'mm/dd/yy',\n weak: 'Weak',\n medium: 'Medium',\n strong: 'Strong',\n passwordPrompt: 'Enter a password',\n emptyFilterMessage: 'No results found',\n searchMessage: '{0} results are available',\n selectionMessage: '{0} items selected',\n emptySelectionMessage: 'No selected item',\n emptySearchMessage: 'No results found',\n emptyMessage: 'No available options',\n aria: {\n trueLabel: 'True',\n falseLabel: 'False',\n nullLabel: 'Not Selected',\n star: '1 star',\n stars: '{star} stars',\n selectAll: 'All items selected',\n unselectAll: 'All items unselected',\n close: 'Close',\n previous: 'Previous',\n next: 'Next',\n navigation: 'Navigation',\n scrollTop: 'Scroll Top',\n moveTop: 'Move Top',\n moveUp: 'Move Up',\n moveDown: 'Move Down',\n moveBottom: 'Move Bottom',\n moveToTarget: 'Move to Target',\n moveToSource: 'Move to Source',\n moveAllToTarget: 'Move All to Target',\n moveAllToSource: 'Move All to Source',\n pageLabel: 'Page {page}',\n firstPageLabel: 'First Page',\n lastPageLabel: 'Last Page',\n nextPageLabel: 'Next Page',\n prevPageLabel: 'Previous Page',\n rowsPerPageLabel: 'Rows per page',\n jumpToPageDropdownLabel: 'Jump to Page Dropdown',\n jumpToPageInputLabel: 'Jump to Page Input',\n selectRow: 'Row Selected',\n unselectRow: 'Row Unselected',\n expandRow: 'Row Expanded',\n collapseRow: 'Row Collapsed',\n showFilterMenu: 'Show Filter Menu',\n hideFilterMenu: 'Hide Filter Menu',\n filterOperator: 'Filter Operator',\n filterConstraint: 'Filter Constraint',\n editRow: 'Row Edit',\n saveEdit: 'Save Edit',\n cancelEdit: 'Cancel Edit',\n listView: 'List View',\n gridView: 'Grid View',\n slide: 'Slide',\n slideNumber: '{slideNumber}',\n zoomImage: 'Zoom Image',\n zoomIn: 'Zoom In',\n zoomOut: 'Zoom Out',\n rotateRight: 'Rotate Right',\n rotateLeft: 'Rotate Left',\n listLabel: 'Option List',\n },\n} as Translation;\n","import { Translation } from 'primeng/api';\n\n/**\n * French locale for PrimeNG components.\n *\n * Usage:\n * ```ts\n * import { PRIMENG_FR_LOCALE } from '@elasticias/core';\n * this.primeng.translation = PRIMENG_FR_LOCALE;\n * ```\n */\nexport const PRIMENG_FR_LOCALE: Translation = {\n startsWith: 'Commence par',\n contains: 'Contient',\n notContains: 'Ne contient pas',\n endsWith: 'Se termine par',\n equals: 'Égal à',\n notEquals: 'Différent de',\n noFilter: 'Aucun filtre',\n lt: 'Inférieur à',\n lte: 'Inférieur ou égal à',\n gt: 'Supérieur à',\n gte: 'Supérieur ou égal à',\n dateIs: 'La date est',\n dateIsNot: \"La date n'est pas\",\n dateBefore: 'La date est avant',\n dateAfter: 'La date est après',\n clear: 'Effacer',\n apply: 'Appliquer',\n matchAll: 'Correspond à tous',\n matchAny: \"Correspond à n'importe quel\",\n addRule: 'Ajouter une règle',\n removeRule: 'Supprimer la règle',\n accept: 'Oui',\n reject: 'Non',\n choose: 'Choisir',\n upload: 'Télécharger',\n cancel: 'Annuler',\n completed: 'Terminé',\n pending: 'En attente',\n fileSizeTypes: ['o', 'Ko', 'Mo', 'Go', 'To', 'Po', 'Eo', 'Zo', 'Yo'],\n dayNames: ['Dimanche', 'Lundi', 'Mardi', 'Mercredi', 'Jeudi', 'Vendredi', 'Samedi'],\n dayNamesShort: ['Dim', 'Lun', 'Mar', 'Mer', 'Jeu', 'Ven', 'Sam'],\n dayNamesMin: ['Di', 'Lu', 'Ma', 'Me', 'Je', 'Ve', 'Sa'],\n monthNames: ['Janvier', 'Février', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Août', 'Septembre', 'Octobre', 'Novembre', 'Décembre'],\n monthNamesShort: ['Jan', 'Fév', 'Mar', 'Avr', 'Mai', 'Jun', 'Jul', 'Aoû', 'Sep', 'Oct', 'Nov', 'Déc'],\n chooseYear: \"Choisir l'année\",\n chooseMonth: 'Choisir le mois',\n chooseDate: 'Choisir la date',\n prevDecade: 'Décennie précédente',\n nextDecade: 'Décennie suivante',\n prevYear: 'Année précédente',\n nextYear: 'Année suivante',\n prevMonth: 'Mois précédent',\n nextMonth: 'Mois suivant',\n prevHour: 'Heure précédente',\n nextHour: 'Heure suivante',\n prevMinute: 'Minute précédente',\n nextMinute: 'Minute suivante',\n prevSecond: 'Seconde précédente',\n nextSecond: 'Seconde suivante',\n am: 'AM',\n pm: 'PM',\n today: \"Aujourd'hui\",\n weekHeader: 'Sem',\n firstDayOfWeek: 1,\n showMonthAfterYear: false,\n dateFormat: 'dd/mm/yy',\n weak: 'Faible',\n medium: 'Moyen',\n strong: 'Fort',\n passwordPrompt: 'Entrez un mot de passe',\n emptyFilterMessage: 'Aucun résultat trouvé',\n searchMessage: '{0} résultats sont disponibles',\n selectionMessage: '{0} éléments sélectionnés',\n emptySelectionMessage: 'Aucun élément sélectionné',\n emptySearchMessage: 'Aucun résultat trouvé',\n emptyMessage: 'Aucune option disponible',\n aria: {\n trueLabel: 'Vrai',\n falseLabel: 'Faux',\n nullLabel: 'Non sélectionné',\n star: '1 étoile',\n stars: '{star} étoiles',\n selectAll: 'Tous les éléments sélectionnés',\n unselectAll: 'Tous les éléments désélectionnés',\n close: 'Fermer',\n previous: 'Précédent',\n next: 'Suivant',\n navigation: 'Navigation',\n scrollTop: 'Défiler vers le haut',\n moveTop: 'Déplacer vers le haut',\n moveUp: 'Déplacer vers le haut',\n moveDown: 'Déplacer vers le bas',\n moveBottom: 'Déplacer vers le bas',\n moveToTarget: 'Déplacer vers la cible',\n moveToSource: 'Déplacer vers la source',\n moveAllToTarget: 'Tout déplacer vers la cible',\n moveAllToSource: 'Tout déplacer vers la source',\n pageLabel: 'Page {page}',\n firstPageLabel: 'Première page',\n lastPageLabel: 'Dernière page',\n nextPageLabel: 'Page suivante',\n prevPageLabel: 'Page précédente',\n rowsPerPageLabel: 'Lignes par page',\n jumpToPageDropdownLabel: 'Aller à la page',\n jumpToPageInputLabel: 'Aller à la page',\n selectRow: 'Ligne sélectionnée',\n unselectRow: 'Ligne désélectionnée',\n expandRow: 'Ligne développée',\n collapseRow: 'Ligne réduite',\n showFilterMenu: 'Afficher le menu de filtrage',\n hideFilterMenu: 'Masquer le menu de filtrage',\n filterOperator: 'Opérateur de filtrage',\n filterConstraint: 'Contrainte de filtrage',\n editRow: 'Modifier la ligne',\n saveEdit: 'Enregistrer la modification',\n cancelEdit: 'Annuler la modification',\n listView: 'Vue en liste',\n gridView: 'Vue en grille',\n slide: 'Glisser',\n slideNumber: '{slideNumber}',\n zoomImage: \"Agrandir l'image\",\n zoomIn: 'Zoomer',\n zoomOut: 'Dézoomer',\n rotateRight: 'Faire pivoter à droite',\n rotateLeft: 'Faire pivoter à gauche',\n listLabel: 'Liste',\n },\n} as Translation;\n","import { Translation } from 'primeng/api';\n\n/**\n * Arabic locale for PrimeNG components (Moroccan month names).\n *\n * Usage:\n * ```ts\n * import { PRIMENG_AR_LOCALE } from '@elasticias/core';\n * this.primeng.translation = PRIMENG_AR_LOCALE;\n * ```\n */\nexport const PRIMENG_AR_LOCALE: Translation = {\n startsWith: 'يبدأ بـ',\n contains: 'يحتوي على',\n notContains: 'لا يحتوي على',\n endsWith: 'ينتهي بـ',\n equals: 'يساوي',\n notEquals: 'لا يساوي',\n noFilter: 'بدون فلتر',\n lt: 'أقل من',\n lte: 'أقل من أو يساوي',\n gt: 'أكبر من',\n gte: 'أكبر من أو يساوي',\n dateIs: 'التاريخ هو',\n dateIsNot: 'التاريخ ليس',\n dateBefore: 'التاريخ قبل',\n dateAfter: 'التاريخ بعد',\n clear: 'مسح',\n apply: 'تطبيق',\n matchAll: 'تطابق الكل',\n matchAny: 'تطابق أي',\n addRule: 'إضافة قاعدة',\n removeRule: 'حذف القاعدة',\n accept: 'نعم',\n reject: 'لا',\n choose: 'اختيار',\n upload: 'رفع',\n cancel: 'إلغاء',\n completed: 'مكتمل',\n pending: 'قيد الانتظار',\n fileSizeTypes: ['بايت', 'ك.ب', 'م.ب', 'ج.ب', 'ت.ب', 'ب.ب', 'إ.ب', 'ز.ب', 'ي.ب'],\n dayNames: ['الأحد', 'الاثنين', 'الثلاثاء', 'الأربعاء', 'الخميس', 'الجمعة', 'السبت'],\n dayNamesShort: ['أحد', 'اثن', 'ثلا', 'أرب', 'خمي', 'جمع', 'سبت'],\n dayNamesMin: ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],\n monthNames: ['يناير', 'فبراير', 'مارس', 'أبريل', 'ماي', 'يونيو', 'يوليوز', 'غشت', 'شتنبر', 'أكتوبر', 'نونبر', 'دجنبر'],\n monthNamesShort: ['ينا', 'فبر', 'مار', 'أبر', 'ماي', 'يون', 'يول', 'غشت', 'شتن', 'أكت', 'نون', 'دجن'],\n chooseYear: 'اختر السنة',\n chooseMonth: 'اختر الشهر',\n chooseDate: 'اختر التاريخ',\n prevDecade: 'العقد السابق',\n nextDecade: 'العقد التالي',\n prevYear: 'السنة السابقة',\n nextYear: 'السنة التالية',\n prevMonth: 'الشهر السابق',\n nextMonth: 'الشهر التالي',\n prevHour: 'الساعة السابقة',\n nextHour: 'الساعة التالية',\n prevMinute: 'الدقيقة السابقة',\n nextMinute: 'الدقيقة التالية',\n prevSecond: 'الثانية السابقة',\n nextSecond: 'الثانية التالية',\n am: 'ص',\n pm: 'م',\n today: 'اليوم',\n weekHeader: 'أس',\n firstDayOfWeek: 1,\n showMonthAfterYear: false,\n dateFormat: 'dd/mm/yy',\n weak: 'ضعيف',\n medium: 'متوسط',\n strong: 'قوي',\n passwordPrompt: 'أدخل كلمة المرور',\n emptyFilterMessage: 'لم يتم العثور على نتائج',\n searchMessage: '{0} نتائج متاحة',\n selectionMessage: '{0} عناصر محددة',\n emptySelectionMessage: 'لا يوجد عنصر محدد',\n emptySearchMessage: 'لم يتم العثور على نتائج',\n emptyMessage: 'لا توجد خيارات متاحة',\n aria: {\n trueLabel: 'صحيح',\n falseLabel: 'خاطئ',\n nullLabel: 'غير محدد',\n star: 'نجمة واحدة',\n stars: '{star} نجوم',\n selectAll: 'تم تحديد جميع العناصر',\n unselectAll: 'تم إلغاء تحديد جميع العناصر',\n close: 'إغلاق',\n previous: 'السابق',\n next: 'التالي',\n navigation: 'التنقل',\n scrollTop: 'التمرير للأعلى',\n moveTop: 'نقل للأعلى',\n moveUp: 'نقل للأعلى',\n moveDown: 'نقل للأسفل',\n moveBottom: 'نقل للأسفل',\n moveToTarget: 'نقل إلى الهدف',\n moveToSource: 'نقل إلى المصدر',\n moveAllToTarget: 'نقل الكل إلى الهدف',\n moveAllToSource: 'نقل الكل إلى المصدر',\n pageLabel: 'صفحة {page}',\n firstPageLabel: 'الصفحة الأولى',\n lastPageLabel: 'الصفحة الأخيرة',\n nextPageLabel: 'الصفحة التالية',\n prevPageLabel: 'الصفحة السابقة',\n rowsPerPageLabel: 'سطور في الصفحة',\n jumpToPageDropdownLabel: 'الانتقال إلى الصفحة',\n jumpToPageInputLabel: 'الانتقال إلى الصفحة',\n selectRow: 'تم تحديد السطر',\n unselectRow: 'تم إلغاء تحديد السطر',\n expandRow: 'تم توسيع السطر',\n collapseRow: 'تم طي السطر',\n showFilterMenu: 'إظهار قائمة الفلتر',\n hideFilterMenu: 'إخفاء قائمة الفلتر',\n filterOperator: 'عامل الفلتر',\n filterConstraint: 'قيد الفلتر',\n editRow: 'تعديل السطر',\n saveEdit: 'حفظ التعديل',\n cancelEdit: 'إلغاء التعديل',\n listView: 'عرض قائمة',\n gridView: 'عرض شبكة',\n slide: 'تمرير',\n slideNumber: '{slideNumber}',\n zoomImage: 'تكبير الصورة',\n zoomIn: 'تكبير',\n zoomOut: 'تصغير',\n rotateRight: 'تدوير لليمين',\n rotateLeft: 'تدوير لليسار',\n listLabel: 'قائمة',\n },\n} as Translation;\n","import { InjectionToken } from '@angular/core';\n\n/**\n * The eight ERP modules surfaced by Comptoir. New modules require\n * a matching `--m-{id}` token in the SCSS layer (libs/ui/src/lib/_comptoir.scss)\n * and a labelKey in the consuming app's i18n bundles.\n */\nexport type EfModuleId =\n | 'sales'\n | 'purchase'\n | 'stock'\n | 'pos'\n | 'marketing'\n | 'store'\n | 'finance'\n | 'admin';\n\nexport type EfNavAction = 'read' | 'write' | 'admin';\n\nexport interface EfNavItem {\n /** Stable identifier — usually matches the screen code (e.g. `Users`, `SalesOrders`). */\n id: string;\n labelKey: string;\n icon?: string;\n route: string;\n /** Minimum permission level required to render this item. Defaults to `read`. */\n requiredAction?: EfNavAction;\n /**\n * Optional count chip rendered after the label (e.g. `Commandes ⟨14⟩`).\n * Apps typically derive this from a service signal and patch the\n * registry — it can be number, string, or anything stringifiable.\n */\n badge?: string | number;\n}\n\nexport interface EfNavSection {\n id: string;\n labelKey?: string;\n items: EfNavItem[];\n}\n\nexport interface EfModule {\n id: EfModuleId;\n labelKey: string;\n /** PrimeNG icon class used by `ef-module-rail`, e.g. `pi pi-shopping-bag`. */\n icon: string;\n /**\n * CSS custom-property name (without the leading `--`) that the rail\n * applies to the module-current accent. Always `m-{id}` and resolves\n * via the SCSS layer's `[data-module]` selectors at runtime.\n */\n accent: `m-${EfModuleId}`;\n defaultRoute: string;\n navSections: EfNavSection[];\n /**\n * Logical grouping for rail divider placement. `ef-module-rail` renders\n * a 1px divider between two consecutive visible modules whose `group`\n * differs. Free string — `'operations' | 'commerce' | 'admin'` is the\n * conventional set but apps can use anything stable.\n */\n group?: string;\n}\n\n/**\n * Default skeleton for the eight ERP modules. Apps either consume this\n * directly via `EF_MODULES_TOKEN` or extend it with their own `navSections`.\n *\n * Phase 1 ships the metadata only — `ef-module-rail` (Phase 2) uses\n * `id` / `labelKey` / `icon` / `accent` / `defaultRoute`. `navSections`\n * are populated per-app as each module's screens land in Phase 4-5.\n */\nexport const EF_MODULES: ReadonlyArray<EfModule> = [\n {\n id: 'sales',\n labelKey: 'modules.sales',\n icon: 'pi pi-shopping-bag',\n accent: 'm-sales',\n defaultRoute: '/operations/sales',\n navSections: [],\n group: 'operations',\n },\n {\n id: 'purchase',\n labelKey: 'modules.purchase',\n icon: 'pi pi-truck',\n accent: 'm-purchase',\n defaultRoute: '/operations/purchase',\n navSections: [],\n group: 'operations',\n },\n {\n id: 'stock',\n labelKey: 'modules.stock',\n icon: 'pi pi-warehouse',\n accent: 'm-stock',\n defaultRoute: '/operations/stock',\n navSections: [],\n group: 'operations',\n },\n {\n id: 'pos',\n labelKey: 'modules.pos',\n icon: 'pi pi-shop',\n accent: 'm-pos',\n defaultRoute: '/pos',\n navSections: [],\n group: 'operations',\n },\n {\n id: 'marketing',\n labelKey: 'modules.marketing',\n icon: 'pi pi-megaphone',\n accent: 'm-marketing',\n defaultRoute: '/marketing',\n navSections: [],\n group: 'commerce',\n },\n {\n id: 'store',\n labelKey: 'modules.store',\n icon: 'pi pi-globe',\n accent: 'm-store',\n defaultRoute: '/store',\n navSections: [],\n group: 'commerce',\n },\n {\n id: 'finance',\n labelKey: 'modules.finance',\n icon: 'pi pi-chart-line',\n accent: 'm-finance',\n defaultRoute: '/finance',\n navSections: [],\n group: 'commerce',\n },\n {\n id: 'admin',\n labelKey: 'modules.admin',\n icon: 'pi pi-shield',\n accent: 'm-admin',\n defaultRoute: '/admin',\n navSections: [],\n group: 'admin',\n },\n];\n\n/**\n * DI token that the shell components (`ef-module-rail`, `ef-module-side`)\n * read from. Apps provide their own definition (typically extending\n * `EF_MODULES` with populated `navSections`):\n *\n * ```ts\n * providers: [\n * { provide: EF_MODULES_TOKEN, useValue: APP_MODULES }\n * ]\n * ```\n */\nexport const EF_MODULES_TOKEN = new InjectionToken<ReadonlyArray<EfModule>>(\n 'EF_MODULES',\n { providedIn: 'root', factory: () => EF_MODULES }\n);\n","import { computed, DestroyRef, inject, Injectable, signal } from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { NavigationEnd, Router } from '@angular/router';\nimport { filter } from 'rxjs/operators';\nimport { EF_MODULES_TOKEN, EfModule, EfModuleId, EfNavItem } from './ef-module-registry';\n\n/**\n * Single source of truth for \"which ERP module is active right now.\"\n *\n * Watches the Router and matches the current URL against each module's\n * `defaultRoute`. The longest matching prefix wins, so `/operations/sales`\n * resolves to `sales` even though `/operations` could in theory match\n * something shorter.\n *\n * Consumers — `ef-module-rail`, `ef-module-side`, `ef-app-main`,\n * `ef-page-head` — read `activeModule()` and derive their state from it.\n *\n * Apps that navigate programmatically without a URL change (rare) can\n * call `setActiveModule(id)` to override.\n */\n@Injectable({ providedIn: 'root' })\nexport class EfActiveModuleService {\n private readonly router = inject(Router);\n private readonly modules = inject(EF_MODULES_TOKEN);\n private readonly destroyRef = inject(DestroyRef);\n\n private readonly _activeModule = signal<EfModule | null>(null);\n private readonly _activeNavItem = signal<EfNavItem | null>(null);\n\n readonly activeModule = this._activeModule.asReadonly();\n readonly activeModuleId = computed(() => this._activeModule()?.id ?? null);\n readonly activeNavItem = this._activeNavItem.asReadonly();\n\n constructor() {\n this.resolveFromUrl(this.router.url);\n\n this.router.events\n .pipe(\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\n takeUntilDestroyed(this.destroyRef),\n )\n .subscribe(e => this.resolveFromUrl(e.urlAfterRedirects));\n }\n\n /**\n * Force the active module. Most apps don't need this — the router\n * subscription keeps `activeModule()` in sync automatically.\n */\n setActiveModule(id: EfModuleId | null): void {\n if (id === null) {\n this._activeModule.set(null);\n return;\n }\n const match = this.modules.find(m => m.id === id);\n if (match) this._activeModule.set(match);\n }\n\n private resolveFromUrl(url: string): void {\n const path = url.split('?')[0].split('#')[0];\n\n let bestModule: EfModule | null = null;\n let bestNavItem: EfNavItem | null = null;\n let bestLen = 0;\n for (const m of this.modules) {\n for (const route of this.routesFor(m)) {\n if (path === route || path.startsWith(route + '/')) {\n if (route.length > bestLen) {\n bestModule = m;\n bestNavItem = this.findNavItem(m, route);\n bestLen = route.length;\n }\n }\n }\n }\n this._activeModule.set(bestModule);\n this._activeNavItem.set(bestNavItem);\n }\n\n private findNavItem(m: EfModule, route: string): EfNavItem | null {\n for (const section of m.navSections) {\n for (const item of section.items) {\n if (item.route === route) return item;\n }\n }\n return null;\n }\n\n /**\n * Every URL prefix that should resolve back to this module: the\n * `defaultRoute` plus every nav item route. Modules whose nav items\n * span multiple URL prefixes (e.g. sales spread across `/operations/sales`\n * and `/parameters/sales`) need this to stay active across all of them.\n */\n private routesFor(m: EfModule): string[] {\n const routes: string[] = [m.defaultRoute];\n for (const section of m.navSections) {\n for (const item of section.items) {\n routes.push(item.route);\n }\n }\n return routes;\n }\n}\n","import { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { computed, DestroyRef, inject, Injectable, PLATFORM_ID, signal } from '@angular/core';\n\nexport type EfViewport = 'mobile' | 'tablet' | 'desktop';\n\ninterface ViewportQuery {\n viewport: EfViewport;\n query: string;\n}\n\nconst QUERIES: ViewportQuery[] = [\n { viewport: 'mobile', query: '(max-width: 767px)' },\n { viewport: 'tablet', query: '(min-width: 768px) and (max-width: 1279px)' },\n { viewport: 'desktop', query: '(min-width: 1280px)' },\n];\n\n/**\n * Emits the current viewport tier based on `window.matchMedia` breakpoints.\n *\n * Breakpoints come from `libs/tokens/targets.json`:\n * - mobile: ≤ 767px\n * - tablet: 768 – 1279px\n * - desktop: ≥ 1280px\n *\n * SSR-safe: returns `'desktop'` when `window` is unavailable.\n *\n * Usage:\n * ```ts\n * private viewport = inject(EfViewportService);\n *\n * isMobile = computed(() => this.viewport.current() === 'mobile');\n * ```\n */\n@Injectable({ providedIn: 'root' })\nexport class EfViewportService {\n private readonly document = inject(DOCUMENT);\n private readonly platformId = inject(PLATFORM_ID);\n private readonly destroyRef = inject(DestroyRef);\n\n private readonly _current = signal<EfViewport>('desktop');\n\n readonly current = this._current.asReadonly();\n readonly isMobile = computed(() => this._current() === 'mobile');\n readonly isTablet = computed(() => this._current() === 'tablet');\n readonly isDesktop = computed(() => this._current() === 'desktop');\n\n constructor() {\n if (!isPlatformBrowser(this.platformId)) return;\n\n const win = this.document.defaultView;\n if (!win || typeof win.matchMedia !== 'function') return;\n\n const lists = QUERIES.map(({ viewport, query }) => {\n const mql = win.matchMedia(query);\n const handler = (e: MediaQueryListEvent | MediaQueryList) => {\n if (e.matches) this._current.set(viewport);\n };\n handler(mql);\n mql.addEventListener('change', handler as (e: MediaQueryListEvent) => void);\n return { mql, handler };\n });\n\n this.destroyRef.onDestroy(() => {\n for (const { mql, handler } of lists) {\n mql.removeEventListener('change', handler as (e: MediaQueryListEvent) => void);\n }\n });\n }\n}\n","import { computed, inject, Injectable, Signal, signal } from '@angular/core';\nimport { EF_MODULES_TOKEN, EfModule, EfModuleId } from '../modules/ef-module-registry';\n\nexport type EfPermissionLevel = 'none' | 'read' | 'write' | 'admin';\n\nexport interface EfModulePermission {\n module: EfModuleId;\n level: EfPermissionLevel;\n}\n\nconst LEVEL_ORDER: Record<EfPermissionLevel, number> = {\n none: 0,\n read: 1,\n write: 2,\n admin: 3,\n};\n\nconst ACTION_REQUIRED: Record<Exclude<EfPermissionLevel, 'none'>, EfPermissionLevel> = {\n read: 'read',\n write: 'write',\n admin: 'admin',\n};\n\n/**\n * Module-scoped permission service.\n *\n * Apps populate it from their auth bootstrap once the user's profile is\n * loaded — typically via `setPermissions()` or by providing a custom\n * source signal:\n *\n * ```ts\n * // bootstrap.ts\n * const perms = inject(EfPermissionService);\n * perms.setPermissions(profile.permissions);\n * ```\n *\n * The service is the single source of truth for shell components\n * (`ef-module-rail`, `ef-module-side`, `*efCan` directive) and routing\n * defaults. Once the screens/menus → Mongo migration lands, the\n * permissions list will be served denormalized on the user/profile\n * document and consumed here without a join.\n */\n@Injectable({ providedIn: 'root' })\nexport class EfPermissionService {\n private readonly modules = inject(EF_MODULES_TOKEN);\n\n private readonly _permissions = signal<ReadonlyArray<EfModulePermission>>([]);\n\n readonly permissions = this._permissions.asReadonly();\n\n /**\n * Replace the current permission set. Pass `[]` to clear (e.g., on logout).\n */\n setPermissions(perms: ReadonlyArray<EfModulePermission>): void {\n this._permissions.set(perms);\n }\n\n /**\n * The level granted to the current user for a given module.\n * Returns `'none'` if the module is not in the permission set.\n */\n level(module: EfModuleId): EfPermissionLevel {\n return this._permissions().find(p => p.module === module)?.level ?? 'none';\n }\n\n /**\n * Whether the current user can perform `action` on `module`.\n * Levels are hierarchical: `admin` > `write` > `read` > `none`.\n */\n can(module: EfModuleId, action: Exclude<EfPermissionLevel, 'none'> = 'read'): boolean {\n return LEVEL_ORDER[this.level(module)] >= LEVEL_ORDER[ACTION_REQUIRED[action]];\n }\n\n /**\n * The list of modules the user can read, in registry order.\n * Used by `ef-module-rail` to decide which icons render.\n */\n readonly visibleModules: Signal<ReadonlyArray<EfModule>> = computed(() => {\n const perms = this._permissions();\n const granted = new Set(\n perms.filter(p => p.level !== 'none').map(p => p.module)\n );\n return this.modules.filter(m => granted.has(m.id));\n });\n\n /**\n * The first visible module — the default landing module after login.\n * Returns `null` when the user has no modules.\n */\n readonly defaultModule: Signal<EfModule | null> = computed(() => {\n return this.visibleModules()[0] ?? null;\n });\n}\n","import { InjectionToken } from '@angular/core';\n\n/**\n * The bit of an app's session that shared chrome needs to act on.\n *\n * Signing out belongs to the app — it owns the auth client, the grant\n * refresh timer and where to land afterwards — but the control that\n * triggers it belongs to the shell. This token is the seam between them,\n * the same shape as `SCREEN_REF_DATA_SERVICE`.\n *\n * Components inject it optionally and hide their affordance when nothing\n * provides it, so an app that has not opted in shows no dead button.\n *\n * ```ts\n * // app.config.ts\n * { provide: EF_SESSION, useExisting: AuthorizeService }\n * ```\n */\nexport interface EfSession {\n /** End the session and send the user wherever the app decides. */\n logout(): void;\n}\n\nexport const EF_SESSION = new InjectionToken<EfSession>('EF_SESSION');\n","import { InjectionToken } from '@angular/core';\n\n/**\n * Which build of the app is running.\n *\n * Apps generate this at build time — the framework cannot know it — and\n * provide it here so shared chrome can show it without importing anything\n * app-specific. `EfBuildStampComponent` is the intended consumer.\n *\n * ```ts\n * // app.config.ts\n * { provide: EF_BUILD_INFO, useValue: BUILD_INFO }\n * ```\n */\nexport interface EfBuildInfo {\n /** Release version. Empty when the app maintains none — consumers should\n * omit it rather than print a placeholder. */\n version: string;\n\n /** Short commit hash the build came from. */\n commit: string;\n\n /** Commit date as `YYYY-MM-DD` — what a reader actually recognises. */\n date: string;\n\n /** Branch the build came from, useful for telling develop from a release. */\n branch: string;\n\n /**\n * Which deployment this build was made for: `production`, `staging`,\n * `develop`, or `local`. Decided at build time from the ref, because a\n * production build is made from a tag rather than a branch.\n */\n environment: string;\n\n /**\n * The shared `@elasticias/*` packages this build was compiled against,\n * in the order the app wants them listed.\n *\n * Optional: an app that ships no shared packages, or generates its stamp\n * without resolving them, simply omits the key and consumers render\n * nothing rather than an empty group.\n */\n packages?: EfBuildPackage[];\n}\n\n/** One shared package and the version that went into the build. */\nexport interface EfBuildPackage {\n /** Package name as it appears in `package.json`, e.g. `@elasticias/ui`. */\n name: string;\n\n /** The version actually installed, not the range the app declared. */\n version: string;\n}\n\nexport const EF_BUILD_INFO = new InjectionToken<EfBuildInfo>('EF_BUILD_INFO');\n","import { HttpBackend, HttpClient } from '@angular/common/http';\nimport { inject, InjectionToken, Provider } from '@angular/core';\nimport { TranslateLoader, TranslationObject } from '@ngx-translate/core';\nimport { Observable } from 'rxjs';\nimport { EF_BUILD_INFO } from '../build/ef-build-info.token';\n\n/**\n * Where the translation files live, and how their URL is stamped.\n */\nexport interface EfVersionedTranslateLoaderConfig {\n /** Path the language file sits under. Defaults to `/assets/i18n/`. */\n prefix?: string;\n\n /** File extension. Defaults to `.json`. */\n suffix?: string;\n\n /**\n * Build identifier appended as `?v=`. Defaults to `EF_BUILD_INFO.commit`,\n * which the app already regenerates on every build, so a release changes\n * every translation URL without anyone maintaining a second number.\n */\n version?: string;\n\n /**\n * Bypass the HTTP interceptor chain. On by default: a translation file is\n * a static asset, and putting it through the app's auth interceptor means\n * a 401 handler can fire before the app knows how to say anything.\n */\n useHttpBackend?: boolean;\n}\n\nexport const EF_TRANSLATE_LOADER_CONFIG = new InjectionToken<EfVersionedTranslateLoaderConfig>(\n 'EF_TRANSLATE_LOADER_CONFIG',\n);\n\n/**\n * Translation loader that puts the build id in the URL.\n *\n * Angular content-hashes its JS and CSS but copies `/assets` verbatim, so a\n * translation file ships new content at a URL that never changes — the one\n * case HTTP caching handles worst. Two things follow from that.\n *\n * The first is ordinary staleness: a device holding yesterday's copy has no\n * reason to ask for today's, so a newly added key renders as its raw key.\n *\n * The second is worse and is why this exists rather than a cache header. A\n * device that cached the file while the server was still sending\n * `max-age=31536000, immutable` will not re-request it for up to a year, and\n * therefore never sees whatever header we send next. Headers only reach\n * browsers that ask. A URL they have never seen has no cache entry at all, so\n * changing the URL is the only thing that reaches them.\n *\n * Stamping the build id also means the URL is stable *within* a release, so\n * the file can go back to being cached hard instead of revalidated on every\n * single page load.\n */\nexport class EfVersionedTranslateLoader implements TranslateLoader {\n private readonly cfg = inject(EF_TRANSLATE_LOADER_CONFIG, { optional: true }) ?? {};\n private readonly buildInfo = inject(EF_BUILD_INFO, { optional: true });\n\n /**\n * Built from `HttpBackend` rather than injecting `HttpClient`, so the\n * request skips interceptors. See `useHttpBackend`.\n */\n private readonly http =\n this.cfg.useHttpBackend === false\n ? inject(HttpClient)\n : new HttpClient(inject(HttpBackend));\n\n getTranslation(lang: string): Observable<TranslationObject> {\n const prefix = this.cfg.prefix ?? '/assets/i18n/';\n const suffix = this.cfg.suffix ?? '.json';\n const version = this.cfg.version ?? this.buildInfo?.commit ?? '';\n\n // No build id (a bare `ng serve`, or an app that ships no stamp) means\n // no query string at all, rather than `?v=` — a URL that changes shape\n // between environments is harder to reason about than one that doesn't.\n const url = `${prefix}${lang}${suffix}${version ? `?v=${encodeURIComponent(version)}` : ''}`;\n return this.http.get<TranslationObject>(url);\n }\n}\n\n/**\n * Provide the versioned loader in place of `provideTranslateHttpLoader`.\n *\n * ```ts\n * provideTranslateService({ fallbackLang: 'fr', lang }),\n * provideEfTranslateLoader({ prefix: '/assets/i18n/' }),\n * ```\n *\n * Pair it with a long-lived cache header on the translation files: the URL now\n * carries the release, so there is nothing left to revalidate against.\n */\nexport function provideEfTranslateLoader(\n config: EfVersionedTranslateLoaderConfig = {},\n): Provider[] {\n return [\n { provide: EF_TRANSLATE_LOADER_CONFIG, useValue: config },\n { provide: TranslateLoader, useClass: EfVersionedTranslateLoader },\n ];\n}\n","/**\n * Key-combo parsing shared by `EfShortcutService` (matching a keydown event\n * against the registry) and `formatShortcut` (rendering a registration for\n * display). Kept internal to the shortcuts folder: neither export is part\n * of the public `@elasticias/core` surface.\n */\n\n/** Fixed order modifiers are stored and compared in, so `'shift+mod+x'`\n * and `'mod+shift+x'` normalise to the same string. */\nconst MODIFIER_ORDER = ['mod', 'shift', 'alt'] as const;\n\n/**\n * Physical-key `KeyboardEvent.code` values mapped to the token used in a\n * `keys` string. `code` identifies the physical key regardless of what\n * Shift makes it print, which is what lets `'shift+/'` match the key next\n * to Right Shift on a US layout even though pressing it actually produces\n * `'?'`.\n */\nconst CODE_KEYS: Record<string, string> = {\n Enter: 'enter',\n Escape: 'escape',\n Space: 'space',\n Backspace: 'backspace',\n Tab: 'tab',\n Slash: '/',\n};\n\n/** Normalises a `keys` registration string into a canonical, comparable\n * form: lowercase tokens, modifiers first in a fixed order. */\nexport function normaliseKeys(raw: string): string {\n const tokens = raw\n .toLowerCase()\n .split('+')\n .map(token => token.trim())\n .filter(Boolean);\n const modifierTokens = MODIFIER_ORDER.filter(modifier => tokens.includes(modifier));\n const rest = tokens.filter(token => !(MODIFIER_ORDER as readonly string[]).includes(token));\n return [...modifierTokens, ...rest].join('+');\n}\n\ninterface KeyEventLike {\n code: string;\n key: string;\n metaKey: boolean;\n ctrlKey: boolean;\n shiftKey: boolean;\n altKey: boolean;\n}\n\n/** The canonical key token for an event, independent of Shift. `KeyD`\n * is `'d'` whether or not Shift was held. */\nfunction keyToken(event: KeyEventLike): string {\n if (CODE_KEYS[event.code]) return CODE_KEYS[event.code];\n if (event.code?.startsWith('Key')) return event.code.slice(3).toLowerCase();\n if (event.code?.startsWith('Digit')) return event.code.slice(5);\n return event.key.toLowerCase();\n}\n\n/**\n * Builds the normalised combo a keydown event represents, e.g. `'mod+d'`.\n * `isMac` decides which physical modifier counts as `mod`: Meta on macOS,\n * Control everywhere else.\n */\nexport function comboFromEvent(event: KeyEventLike, isMac: boolean): string {\n const tokens: string[] = [];\n if (isMac ? event.metaKey : event.ctrlKey) tokens.push('mod');\n if (event.shiftKey) tokens.push('shift');\n if (event.altKey) tokens.push('alt');\n tokens.push(keyToken(event));\n return normaliseKeys(tokens.join('+'));\n}\n\n/**\n * True while the event target is a place the user is typing: an input, a\n * textarea, a select, or anything `contenteditable`. The dispatcher checks\n * this before anything else. Without it every shortcut key is a reserved\n * word in every text field in the app.\n */\nexport function isTypingTarget(target: EventTarget | null): boolean {\n if (!(target instanceof HTMLElement)) return false;\n const tag = target.tagName;\n if (tag === 'INPUT' || tag === 'TEXTAREA' || tag === 'SELECT') return true;\n return target.isContentEditable;\n}\n","import { normaliseKeys } from './shortcut-keys';\n\n/** Reads the platform once. `userAgentData` is the current standard; the\n * `platform` string fallback covers browsers that don't expose it yet.\n *\n * The test is \"Apple\", not \"Mac\". An iPhone reports `iPhone` and an iPad\n * reports either `iPad` or, since iPadOS 13, the same `MacIntel` a desktop\n * does. A narrower `/mac/i` told every iOS device with a keyboard that the\n * modifier was Ctrl, which is the one thing it is not. */\nfunction detectApplePlatform(): boolean {\n if (typeof navigator === 'undefined') return false;\n const uaData = (navigator as Navigator & { userAgentData?: { platform?: string } })\n .userAgentData;\n const platform = uaData?.platform ?? navigator.platform ?? '';\n return /mac|iphone|ipad|ipod/i.test(platform);\n}\n\n/**\n * Detected once, at module load. `formatShortcut` uses it to choose between\n * the Command glyphs and the Ctrl words. True for every Apple platform, not\n * just the desktop: an iPad with a keyboard sends Command like a Mac does.\n */\nexport const isMacPlatform: boolean = detectApplePlatform();\n\nconst MAC_MODIFIER_GLYPHS: Record<string, string> = {\n mod: '⌘',\n shift: '⇧',\n alt: '⌥',\n};\n\nconst OTHER_MODIFIER_WORDS: Record<string, string> = {\n mod: 'Ctrl',\n shift: 'Shift',\n alt: 'Alt',\n};\n\n/** Named keys with a glyph of their own, distinct from their letter. */\nconst KEY_GLYPHS: Record<string, string> = {\n enter: '↵',\n escape: 'Esc',\n backspace: '⌫',\n space: 'Space',\n tab: 'Tab',\n};\n\n/**\n * A produced character that stands in for the whole combo. Shift plus the\n * physical `/` key always reads as the question mark it prints. Showing\n * it as `'Shift' + '/'` would describe the keys pressed rather than the\n * shortcut a person recognises.\n */\nconst SHIFTED_SYMBOL_GLYPHS: Record<string, string> = {\n '/': '?',\n};\n\n/**\n * Formats a `keys` registration for display. One registration, correct on\n * both platforms:\n *\n * - `'mod+d'` → `⌘D` on macOS, `Ctrl+D` elsewhere\n * - `'enter'` → `↵`\n * - `'e'` → `E`\n * - `'shift+/'` → `?`\n *\n * `mac` defaults to the platform this code is actually running on. Pass it\n * explicitly only to render for a platform other than the current one.\n */\nexport function formatShortcut(keys: string, mac: boolean = isMacPlatform): string {\n const tokens = normaliseKeys(keys).split('+');\n const key = tokens[tokens.length - 1];\n const modifiers = tokens.slice(0, -1);\n\n if (modifiers.length === 1 && modifiers[0] === 'shift' && SHIFTED_SYMBOL_GLYPHS[key]) {\n return SHIFTED_SYMBOL_GLYPHS[key];\n }\n\n const displayKey = KEY_GLYPHS[key] ?? key.toUpperCase();\n\n if (mac) {\n return modifiers.map(modifier => MAC_MODIFIER_GLYPHS[modifier] ?? modifier).join('') + displayKey;\n }\n\n const words = modifiers.map(modifier => OTHER_MODIFIER_WORDS[modifier] ?? modifier);\n return [...words, displayKey].join('+');\n}\n","import { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { computed, DestroyRef, inject, Injectable, PLATFORM_ID, signal } from '@angular/core';\nimport { isMacPlatform } from './format-shortcut';\nimport { comboFromEvent, isTypingTarget, normaliseKeys } from './shortcut-keys';\nimport { EfShortcut, EfShortcutGroup } from './ef-shortcut.types';\n\n/**\n * App-wide keyboard-shortcut registry, plus the single `document:keydown`\n * dispatcher that acts on it.\n *\n * ```ts\n * private readonly shortcuts = inject(EfShortcutService);\n *\n * constructor() {\n * // Auto-unregisters on this component's DestroyRef, called from a\n * // constructor / field initializer, an active injection context.\n * this.shortcuts.register({\n * id: 'sales-order.save',\n * keys: 'mod+s',\n * labelKey: 'sales_order_save',\n * group: 'shortcut_group_sales_order',\n * handler: () => this.save(),\n * });\n * }\n * ```\n *\n * Two things make this safe to leave switched on everywhere:\n * - The dispatcher ignores keydown while the target is an input, textarea,\n * select, or anything `contenteditable`, unless the combo includes\n * `mod`. A bare key or a Shift/Alt combo could be real typing (Alt and\n * AltGr both produce characters on several layouts this app ships), but\n * `mod` never does, and a save/search shortcut is normally pressed from\n * inside the very field it acts on. See `isTypingTarget`.\n * - `preventDefault` is only called once a registration actually matches,\n * so an unmapped key never loses its browser default.\n *\n * `list()` exposes the registry grouped for `ef-shortcuts-dialog`, as a\n * signal so the dialog reflects registrations and disposals live.\n */\n@Injectable({ providedIn: 'root' })\nexport class EfShortcutService {\n private readonly document = inject(DOCUMENT);\n private readonly platformId = inject(PLATFORM_ID);\n private readonly destroyRef = inject(DestroyRef);\n\n private readonly registry = signal<ReadonlyMap<string, EfShortcut>>(new Map());\n\n /**\n * The registry, grouped for display and deduplicated by\n * (group, label, keys): several instances of the same conceptual\n * shortcut (one row-actions component per row, say) collapse to a\n * single line rather than repeating once per instance.\n */\n readonly list = computed<EfShortcutGroup[]>(() => {\n const deduped = new Map<string, EfShortcut>();\n for (const shortcut of this.registry().values()) {\n const key = `${shortcut.group}::${shortcut.labelKey}::${shortcut.keys}`;\n if (!deduped.has(key)) deduped.set(key, shortcut);\n }\n\n const byGroup = new Map<string, EfShortcut[]>();\n for (const shortcut of deduped.values()) {\n const group = byGroup.get(shortcut.group) ?? [];\n group.push(shortcut);\n byGroup.set(shortcut.group, group);\n }\n\n return Array.from(byGroup.entries()).map(([group, shortcuts]) => ({ group, shortcuts }));\n });\n\n constructor() {\n if (!isPlatformBrowser(this.platformId)) return;\n this.document.addEventListener('keydown', this.onKeydown);\n this.destroyRef.onDestroy(() => this.document.removeEventListener('keydown', this.onKeydown));\n }\n\n /**\n * Registers a shortcut and returns a disposer. When `register` is\n * called from an active injection context (a component constructor or\n * field initializer), the shortcut also auto-unregisters when that\n * context is destroyed. Call it explicitly elsewhere (a plain method,\n * a route resolver already outside construction) and dispose it\n * yourself.\n */\n register(shortcut: EfShortcut): () => void {\n const entry: EfShortcut = { ...shortcut, keys: normaliseKeys(shortcut.keys) };\n\n this.registry.update(map => {\n const next = new Map(map);\n next.set(entry.id, entry);\n return next;\n });\n\n const dispose = (): void => this.unregister(entry.id);\n this.tryGetCallerDestroyRef()?.onDestroy(dispose);\n return dispose;\n }\n\n /** Removes a registration by id. Safe to call twice: the disposer\n * returned by `register` calls this. */\n unregister(id: string): void {\n this.registry.update(map => {\n if (!map.has(id)) return map;\n const next = new Map(map);\n next.delete(id);\n return next;\n });\n }\n\n /** `inject()` throws outside an active injection context; that is how\n * a call from a plain method (as opposed to a constructor) is told\n * apart from one worth auto-disposing. */\n private tryGetCallerDestroyRef(): DestroyRef | null {\n try {\n return inject(DestroyRef, { optional: true });\n } catch {\n return null;\n }\n }\n\n private readonly onKeydown = (event: KeyboardEvent): void => {\n const combo = comboFromEvent(event, isMacPlatform);\n\n // A bare key, or one held with only Shift or Alt, is something the\n // user could plausibly be typing (Alt/AltGr produces real\n // characters on several layouts this app ships, French and\n // Moroccan included), so those stay inert in a field. `mod` never\n // types a character: Ctrl+S saves from inside a form field in\n // every application there is, and a form field is the only place\n // a save shortcut is ever actually pressed from.\n const isModCombo = combo.split('+').includes('mod');\n if (!isModCombo && isTypingTarget(event.target)) return;\n\n for (const shortcut of this.registry().values()) {\n if (shortcut.keys !== combo) continue;\n if (shortcut.when && !shortcut.when()) continue;\n event.preventDefault();\n shortcut.handler();\n return;\n }\n };\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;MAIa,aAAa,CAAA;AAChB,IAAA,cAAc,GAAG,IAAI,eAAe,CAAU,KAAK,CAAC;AAC5D,IAAA,UAAU,GAAG,IAAI,CAAC,cAAc,CAAC,YAAY,EAAE;IAE/C,IAAI,GAAA;AACF,QAAA,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC;IAChC;IAEA,IAAI,GAAA;AACF,QAAA,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,KAAK,CAAC;IACjC;wGAVW,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA;AAAb,IAAA,OAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,aAAa,cADA,MAAM,EAAA,CAAA;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cADJ,MAAM,EAAA,CAAA;;4FACnB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAD7B,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE;;;ACvClC;;AAEG;;;;"}
1
+ {"version":3,"file":"elasticias-core.mjs","sources":["../../../../libs/core/src/lib/services/loader.service.ts","../../../../libs/core/src/lib/services/cache.service.ts","../../../../libs/core/src/lib/services/toast.service.ts","../../../../libs/core/src/lib/services/confirm-dialog.service.ts","../../../../libs/core/src/lib/guards/screen.guard.ts","../../../../libs/core/src/lib/theme/app-state.ts","../../../../libs/core/src/lib/theme/ef-theme-config.service.ts","../../../../libs/core/src/lib/theme/ef-theme.ts","../../../../libs/core/src/lib/theme/locales/primeng-en.ts","../../../../libs/core/src/lib/theme/locales/primeng-fr.ts","../../../../libs/core/src/lib/theme/locales/primeng-ar.ts","../../../../libs/core/src/lib/modules/ef-module-registry.ts","../../../../libs/core/src/lib/modules/ef-active-module.service.ts","../../../../libs/core/src/lib/responsive/ef-viewport.service.ts","../../../../libs/core/src/lib/auth/ef-permission.service.ts","../../../../libs/core/src/lib/auth/ef-session.token.ts","../../../../libs/core/src/lib/build/ef-build-info.token.ts","../../../../libs/core/src/lib/i18n/ef-versioned-translate-loader.ts","../../../../libs/core/src/lib/shortcuts/shortcut-keys.ts","../../../../libs/core/src/lib/shortcuts/format-shortcut.ts","../../../../libs/core/src/lib/shortcuts/ef-shortcut.service.ts","../../../../libs/core/src/elasticias-core.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { BehaviorSubject } from 'rxjs';\n\n@Injectable({ providedIn: 'root' })\nexport class LoaderService {\n private loadingSubject = new BehaviorSubject<boolean>(false);\n isLoading$ = this.loadingSubject.asObservable();\n\n show(): void {\n this.loadingSubject.next(true);\n }\n\n hide(): void {\n this.loadingSubject.next(false);\n }\n}\n","import { Injectable } from '@angular/core';\nimport { StorageUtils } from '@elasticias/utils';\n\n@Injectable({ providedIn: 'root' })\nexport class CacheService {\n private cache: Record<string, unknown> = {};\n private useLocalStorage = false;\n\n configure(useLocalStorage = false): void {\n this.useLocalStorage = useLocalStorage;\n }\n\n getCache<T>(key: string): T | null {\n return this.useLocalStorage ? StorageUtils.getLocal<T>(key) : (this.cache[key] as T) ?? null;\n }\n\n setCache(key: string, value: unknown): void {\n if (this.useLocalStorage) {\n StorageUtils.setLocal(key, value);\n } else {\n this.cache[key] = value;\n }\n }\n\n updateCache(key: string, newValue: unknown): void {\n if (this.useLocalStorage) {\n const current = StorageUtils.getLocal(key);\n if (current && typeof current === 'object' && typeof newValue === 'object') {\n StorageUtils.setLocal(key, { ...(current as object), ...(newValue as object) });\n } else {\n StorageUtils.setLocal(key, newValue);\n }\n } else {\n const current = this.cache[key];\n if (current && typeof current === 'object' && typeof newValue === 'object') {\n this.cache[key] = { ...(current as object), ...(newValue as object) };\n } else {\n this.cache[key] = newValue;\n }\n }\n }\n\n removeCache(key: string): void {\n if (this.useLocalStorage) {\n StorageUtils.removeLocal(key);\n } else {\n delete this.cache[key];\n }\n }\n\n clearAllCache(): void {\n if (this.useLocalStorage) {\n StorageUtils.clearLocal();\n } else {\n this.cache = {};\n }\n }\n\n hasCache(key: string): boolean {\n return this.useLocalStorage ? StorageUtils.existsLocal(key) : key in this.cache;\n }\n}\n","import { Injectable, Injector, inject, signal } from '@angular/core';\nimport { TranslateService } from '@ngx-translate/core';\nimport { MessageService } from 'primeng/api';\n\n/**\n * Toast severities — mapped 1:1 to the Comptoir status spectrum:\n * `info` → processing, `success` → delivered, `warn` → pending,\n * `error` → cancelled.\n */\nexport type EfToastSeverity = 'info' | 'success' | 'warn' | 'error';\n\n/** Optional inline action button rendered at the end of a toast. */\nexport interface EfToastAction {\n /** Translation key for the button label — preferred. */\n labelKey?: string;\n /** Direct label fallback when `labelKey` is empty. */\n label?: string;\n\n /** Visual tone — `'ghost'` (default) or `'primary'` for the\n * destructive / confirm action. */\n severity?: 'ghost' | 'primary';\n\n /** Click handler. */\n command?: () => void;\n\n /** Auto-close the toast after the click runs (default `true`). */\n dismissOnClick?: boolean;\n}\n\n/**\n * Toast options accepted by `EfToastService.show()`. Either a literal\n * `title` / `text` or their `*Key` translation variants — keys win\n * unless empty.\n */\nexport interface EfToastOptions {\n severity?: EfToastSeverity;\n title?: string;\n titleKey?: string;\n text?: string;\n textKey?: string;\n /** Auto-dismiss in ms; `0` = sticky (no auto-dismiss). */\n life?: number;\n actions?: EfToastAction[];\n}\n\n/** Active toast — instance held in `EfToastService.toasts`. */\nexport interface EfToast {\n id: number;\n severity: EfToastSeverity;\n title: string;\n text: string;\n life: number;\n actions?: EfToastAction[];\n}\n\n/**\n * Comptoir toast service — V2 successor to the legacy `ToastService`.\n *\n * Owns a signal-based queue (`toasts`) consumed by\n * `<ef-toast-region>`, AND forwards every toast to PrimeNG's\n * `MessageService` for back-compat with `<p-toast>` (still used by\n * ClientApp v1). Either renderer picks the toasts up; both work.\n *\n * Default i18n keys (override per-call via `titleKey` / `textKey`):\n * - `ef_toast_info_title`, `ef_toast_info_default`\n * - `ef_toast_success_title`, `ef_toast_success_default`\n * - `ef_toast_warn_title`, `ef_toast_warn_default`\n * - `ef_toast_error_title`, `ef_toast_error_default`\n *\n * Default lifespans: info 5s, success 4s, warn 6s, error 8s.\n */\n@Injectable({ providedIn: 'root' })\nexport class EfToastService {\n private static readonly LIFE_INFO = 5000;\n private static readonly LIFE_SUCCESS = 4000;\n private static readonly LIFE_WARN = 6000;\n private static readonly LIFE_ERROR = 8000;\n\n /**\n * Lazy holders. Resolving TranslateService eagerly at construction\n * time pulls in HttpClient → HTTP_INTERCEPTORS → AuthorizeInterceptor\n * → AuthorizeService → ToastService → cycle. We defer to the first\n * actual translate / message-publish call.\n */\n private readonly injector = inject(Injector);\n private _translate?: TranslateService;\n private _messageService?: MessageService | null;\n private _messageServiceResolved = false;\n\n private nextId = 1;\n\n /** Live queue — `<ef-toast-region>` renders this. */\n readonly toasts = signal<ReadonlyArray<EfToast>>([]);\n\n /* ── Convenience methods (back-compat with the legacy\n ToastService signature: `(message?, title?, life?)`). ── */\n\n showInfo(message?: string, title?: string, life: number = EfToastService.LIFE_INFO): void {\n this.show({\n severity: 'info',\n title: title ?? this.t('ef_toast_info_title'),\n text: message ?? this.t('ef_toast_info_default'),\n life,\n });\n }\n\n showSuccess(message?: string, title?: string, life: number = EfToastService.LIFE_SUCCESS): void {\n this.show({\n severity: 'success',\n title: title ?? this.t('ef_toast_success_title'),\n text: message ?? this.t('ef_toast_success_default'),\n life,\n });\n }\n\n showWarn(message?: string, title?: string, life: number = EfToastService.LIFE_WARN): void {\n this.show({\n severity: 'warn',\n title: title ?? this.t('ef_toast_warn_title'),\n text: message ?? this.t('ef_toast_warn_default'),\n life,\n });\n }\n\n showError(message?: string, title?: string, life: number = EfToastService.LIFE_ERROR): void {\n this.show({\n severity: 'error',\n title: title ?? this.t('ef_toast_error_title'),\n text: message ?? this.t('ef_toast_error_default'),\n life,\n });\n }\n\n /** Generic show — opts can mix `title`/`titleKey`, `text`/`textKey`. */\n show(opts: EfToastOptions): EfToast {\n const severity = opts.severity ?? 'info';\n const toast: EfToast = {\n id: this.nextId++,\n severity,\n title: this.resolve(opts.title, opts.titleKey, this.defaultTitleKey(severity)),\n text: this.resolve(opts.text, opts.textKey, undefined),\n life: opts.life ?? this.defaultLife(severity),\n actions: opts.actions,\n };\n\n // Collapse a burst of identical toasts into one. A dashboard fans\n // out to many independent queries, so one rejected filter used to\n // stack the same message once per widget -- seven copies of \"a\n // validation error occurred\", burying the screen. Only toasts that\n // are still on screen dedupe, so the same message shown again later\n // still appears.\n const duplicate = this.toasts().find(\n t =>\n t.severity === toast.severity &&\n t.title === toast.title &&\n t.text === toast.text,\n );\n if (duplicate) return duplicate;\n\n this.toasts.update(list => [...list, toast]);\n\n // Forward to PrimeNG MessageService so v1's <p-toast> still\n // catches the toast. Sticky in PrimeNG is `life: 0`.\n this.messageService?.add({\n severity: toast.severity,\n summary: toast.title,\n detail: toast.text,\n life: toast.life || undefined,\n sticky: toast.life === 0,\n });\n\n return toast;\n }\n\n private get messageService(): MessageService | null {\n if (!this._messageServiceResolved) {\n this._messageServiceResolved = true;\n this._messageService = this.injector.get(MessageService, null, { optional: true });\n }\n return this._messageService ?? null;\n }\n\n dismiss(id: number): void {\n this.toasts.update(list => list.filter(t => t.id !== id));\n }\n\n clear(): void {\n this.toasts.set([]);\n this.messageService?.clear();\n }\n\n /* (messageService getter is defined just below `show` to keep it\n close to where it's consumed.) */\n\n /* ── Internals ─────────────────────────────────────────────── */\n\n private resolve(\n literal: string | undefined,\n key: string | undefined,\n fallbackKey: string | undefined,\n ): string {\n if (literal != null) return literal;\n if (key) return this.t(key);\n if (fallbackKey) return this.t(fallbackKey);\n return '';\n }\n\n private t(key: string): string {\n // Lazy-resolve TranslateService — see the field comment above\n // for the AuthorizeService cycle this avoids.\n this._translate ??= this.injector.get(TranslateService);\n const value = this._translate.instant(key);\n // `instant()` returns the key when no translation is loaded;\n // fall through to empty string so untranslated toasts don't\n // surface internal keys to end users.\n return value === key ? '' : value;\n }\n\n private defaultLife(severity: EfToastSeverity): number {\n switch (severity) {\n case 'info': return EfToastService.LIFE_INFO;\n case 'success': return EfToastService.LIFE_SUCCESS;\n case 'warn': return EfToastService.LIFE_WARN;\n case 'error': return EfToastService.LIFE_ERROR;\n }\n }\n\n private defaultTitleKey(severity: EfToastSeverity): string {\n return `ef_toast_${severity}_title`;\n }\n}\n\n/**\n * @deprecated Use `EfToastService` — same instance, new name. The\n * alias keeps existing imports compiling during the v1 → V2\n * migration.\n */\nexport { EfToastService as ToastService };\n","import { Injectable, Injector, inject } from '@angular/core';\nimport { TranslateService } from '@ngx-translate/core';\nimport { ConfirmationService } from 'primeng/api';\n\n/** What the user is being asked to approve. Drives the copy, the icon\n * and the weight of the accept button. */\nexport type EfConfirmIntent = 'generic' | 'delete';\n\n/**\n * Options accepted by `ConfirmDialogService.confirm()`.\n *\n * Every piece of text is a translation key, per the framework's i18n\n * convention — the service resolves them through `TranslateService` so\n * the dialog speaks the user's language rather than the author's. The\n * literal `message` / `header` escape hatches exist for text that is\n * already translated (a server message, say); a key always wins.\n */\nexport interface EfConfirmOptions {\n /** Kind of confirmation — `'delete'` supplies destructive defaults. */\n intent?: EfConfirmIntent;\n\n /**\n * Name of the thing being acted on, so the dialog can say *what* it\n * is about to destroy: \"Delete client ANDALOCY PARFUMS?\" rather than\n * \"Delete?\". Omit it and the generic message is used instead.\n */\n name?: string | null;\n\n /** Translation key for the message — preferred over `message`. */\n messageKey?: string;\n /** Already-translated message. Used when `messageKey` is empty. */\n message?: string;\n /** Extra interpolation params for `messageKey` (`name` is added). */\n messageParams?: Record<string, unknown>;\n\n /** Translation key for the dialog title. */\n headerKey?: string;\n /** Already-translated dialog title. */\n header?: string;\n\n /** Translation key for the accept button label. */\n acceptLabelKey?: string;\n /** Translation key for the reject button label. */\n rejectLabelKey?: string;\n\n /** PrimeNG icon class shown in the body tile. */\n icon?: string;\n\n /** Run when the user accepts. */\n accept?: () => void;\n /** Run when the user cancels or dismisses. */\n reject?: () => void;\n\n /** Originating event, so PrimeNG can anchor the dialog. */\n event?: Event;\n}\n\n/** Built-in fallbacks, used only when a translation is missing, so a\n * consuming app that has not yet added the keys still gets a readable\n * dialog instead of a raw key (or worse, an empty message under an\n * irreversible action). */\nconst FALLBACKS: Record<string, string> = {\n ef_confirm_header: 'Confirmation',\n ef_confirm_message_generic: 'Are you sure you want to continue?',\n ef_confirm_accept: 'Confirm',\n ef_confirm_cancel: 'Cancel',\n ef_confirm_delete_header: 'Confirm deletion',\n ef_confirm_delete_accept: 'Delete',\n ef_confirm_delete_message: 'Are you sure you want to delete \"{{name}}\"? This action cannot be undone.',\n ef_confirm_delete_message_generic: 'Are you sure you want to delete this item? This action cannot be undone.',\n};\n\n/** Per-intent defaults. `confirm()` merges the caller's options over these. */\nconst INTENT_DEFAULTS: Record<EfConfirmIntent, Required<Pick<EfConfirmOptions,\n 'headerKey' | 'acceptLabelKey' | 'rejectLabelKey' | 'icon'>> & { messageKey: string; namedMessageKey?: string }> = {\n generic: {\n headerKey: 'ef_confirm_header',\n acceptLabelKey: 'ef_confirm_accept',\n rejectLabelKey: 'ef_confirm_cancel',\n icon: 'pi pi-exclamation-triangle',\n messageKey: 'ef_confirm_message_generic',\n },\n delete: {\n headerKey: 'ef_confirm_delete_header',\n acceptLabelKey: 'ef_confirm_delete_accept',\n rejectLabelKey: 'ef_confirm_cancel',\n icon: 'pi pi-exclamation-triangle',\n messageKey: 'ef_confirm_delete_message_generic',\n namedMessageKey: 'ef_confirm_delete_message',\n },\n};\n\n/**\n * The app-wide confirmation modal, driven through PrimeNG's\n * `ConfirmationService` and rendered by `<ef-confirm-dialog>`.\n *\n * Two call shapes:\n *\n * ```ts\n * // Options — the one to reach for.\n * confirmDialogService.confirm({\n * intent: 'delete',\n * name: client.name, // \"Delete ANDALOCY PARFUMS?\"\n * accept: () => this.remove(),\n * });\n *\n * // Legacy positional form, kept so existing callers keep compiling.\n * confirmDialogService.confirm('Already-translated question?', onYes, onNo);\n * ```\n */\n@Injectable({ providedIn: 'root' })\nexport class ConfirmDialogService {\n private readonly confirmationService = inject(ConfirmationService);\n\n /**\n * Lazy holder. Resolving `TranslateService` at construction time pulls\n * in HttpClient and, through the interceptor chain, services that\n * inject this one — the same cycle `EfToastService` documents. Defer\n * to the first actual `confirm()` call, which is always well after\n * bootstrap.\n */\n private readonly injector = inject(Injector);\n private _translate?: TranslateService;\n\n confirm(options: EfConfirmOptions): void;\n /** @deprecated Pass `EfConfirmOptions` — a literal message cannot be translated. */\n confirm(message: string, acceptCallback?: () => void, rejectCallback?: () => void, event?: Event): void;\n confirm(\n messageOrOptions: string | EfConfirmOptions,\n acceptCallback?: () => void,\n rejectCallback?: () => void,\n event?: Event,\n ): void {\n const options: EfConfirmOptions =\n typeof messageOrOptions === 'string'\n ? { message: messageOrOptions, accept: acceptCallback, reject: rejectCallback, event }\n : messageOrOptions;\n\n const defaults = INTENT_DEFAULTS[options.intent ?? 'generic'];\n const name = options.name?.toString().trim() || undefined;\n\n this.confirmationService.confirm({\n target: options.event?.target ?? undefined,\n message: this.resolveMessage(options, defaults, name),\n header: options.header ?? this.t(options.headerKey ?? defaults.headerKey),\n closable: true,\n closeOnEscape: true,\n icon: options.icon ?? defaults.icon,\n rejectButtonProps: {\n label: this.t(options.rejectLabelKey ?? defaults.rejectLabelKey),\n severity: 'secondary',\n outlined: true,\n },\n acceptButtonProps: {\n label: this.t(options.acceptLabelKey ?? defaults.acceptLabelKey),\n // Semantics. The visual weight comes from the style class\n // below, because `.es-confirm .p-confirmdialog-accept-button`\n // in `_patterns.scss` paints the button at a specificity a\n // severity class cannot reach.\n severity: options.intent === 'delete' ? 'danger' : undefined,\n },\n // `.btn.btn-danger` is declared after the `.es-confirm` accept\n // rule at equal specificity, so it is what finally colours a\n // destructive confirm red instead of ordinary primary ink.\n acceptButtonStyleClass: options.intent === 'delete' ? 'btn btn-danger' : undefined,\n accept: () => options.accept?.(),\n reject: () => options.reject?.(),\n });\n }\n\n /**\n * Sugar for `confirm({ intent: 'delete', ... })`.\n *\n * ```ts\n * confirmDialogService.confirmDelete({ name: row.label, accept: () => … });\n * ```\n */\n confirmDelete(options: Omit<EfConfirmOptions, 'intent'> = {}): void {\n this.confirm({ ...options, intent: 'delete' });\n }\n\n /* ── Internals ─────────────────────────────────────────────── */\n\n private resolveMessage(\n options: EfConfirmOptions,\n defaults: (typeof INTENT_DEFAULTS)[EfConfirmIntent],\n name: string | undefined,\n ): string {\n if (options.messageKey) {\n return this.t(options.messageKey, { ...options.messageParams, name: escapeHtml(name ?? '') });\n }\n if (options.message != null) return options.message;\n\n // A named message when we know what is being acted on, the generic\n // one otherwise — so a caller with no name still reads correctly.\n const key = name && defaults.namedMessageKey ? defaults.namedMessageKey : defaults.messageKey;\n return this.t(key, { ...options.messageParams, name: escapeHtml(name ?? '') });\n }\n\n private t(key: string, params?: Record<string, unknown>): string {\n this._translate ??= this.injector.get(TranslateService);\n const value = this._translate.instant(key, params);\n // `instant()` hands back the key when nothing is loaded for it.\n // Never show that to a user who is about to destroy something.\n if (value !== key) return value;\n const fallback = FALLBACKS[key];\n return fallback ? interpolate(fallback, params) : '';\n }\n}\n\n/**\n * PrimeNG renders the confirm message through `[innerHTML]`. Angular\n * sanitizes it, so this is not about script execution — it is about an\n * entity name containing `<`, `>` or `&` rendering as markup or being\n * silently swallowed. \"Renault < Dacia\" must read as itself.\n */\nfunction escapeHtml(value: string): string {\n return value\n .replace(/&/g, '&amp;')\n .replace(/</g, '&lt;')\n .replace(/>/g, '&gt;')\n .replace(/\"/g, '&quot;')\n .replace(/'/g, '&#39;');\n}\n\n/** Minimal `{{param}}` substitution for the built-in fallbacks, which\n * never reach ngx-translate's own interpolator. */\nfunction interpolate(template: string, params?: Record<string, unknown>): string {\n if (!params) return template;\n return template.replace(/\\{\\{\\s*(\\w+)\\s*\\}\\}/g, (match: string, key: string) =>\n params[key] == null ? match : String(params[key]),\n );\n}\n","import { inject } from '@angular/core';\nimport { CanActivateFn, ActivatedRouteSnapshot, Router } from '@angular/router';\nimport { StorageUtils } from '@elasticias/utils';\nimport { Permissions } from '@elasticias/types';\n\n/**\n * Configuration for the screen guard factory.\n */\nexport interface ScreenGuardConfig {\n /** Storage key where screen grants are stored (default: 'CURRENT_USER_GRANTS') */\n grantsStorageKey?: string;\n /** Route to redirect to when access is denied (default: '/') */\n deniedRedirect?: string;\n /** Minimum required permission to access the screen (default: Permissions.Read) */\n requiredPermission?: Permissions;\n /** Storage type to read grants from (default: 'session') */\n storageType?: 'local' | 'session';\n}\n\n/**\n * Creates a reusable Angular route guard that checks screen-level permissions.\n *\n * Usage in route definitions:\n * ```typescript\n * {\n * path: 'countries',\n * data: { screenCode: 'Countries' },\n * canActivate: [screenGuard()],\n * children: [\n * { path: '', component: CountriesComponent },\n * { path: 'details/:id', component: CountriesDetailsComponent },\n * ]\n * }\n * ```\n *\n * The guard reads the `screenCode` from route data (traversing parent routes)\n * and checks if the current user has at least the required permission (default: Read).\n */\nexport function screenGuard(config?: ScreenGuardConfig): CanActivateFn {\n return (route: ActivatedRouteSnapshot) => {\n const router = inject(Router);\n const grantsKey = config?.grantsStorageKey ?? 'CURRENT_USER_GRANTS';\n const deniedRedirect = config?.deniedRedirect ?? '/';\n const requiredPermission = config?.requiredPermission ?? Permissions.Read;\n const storageType = config?.storageType ?? 'local';\n\n const screenCode = getScreenCode(route);\n\n // If no screenCode found on this route or any parent, allow access\n if (!screenCode) {\n return true;\n }\n\n const screenGrants = storageType === 'session'\n ? StorageUtils.getSession<Record<string, { permissions?: string[] }>>(grantsKey)\n : StorageUtils.getLocal<Record<string, { permissions?: string[] }>>(grantsKey);\n\n if (!screenGrants) {\n router.navigate([deniedRedirect]);\n return false;\n }\n\n const grant = screenGrants[screenCode];\n if (!grant?.permissions?.includes(requiredPermission)) {\n router.navigate([deniedRedirect]);\n return false;\n }\n\n return true;\n };\n}\n\n/**\n * Walks up the route tree to find the nearest screenCode in route data.\n */\nfunction getScreenCode(route: ActivatedRouteSnapshot): string | undefined {\n let current: ActivatedRouteSnapshot | null = route;\n while (current) {\n const code = current.data?.['screenCode'] as string | undefined;\n if (code) return code;\n current = current.parent;\n }\n return undefined;\n}\n\n/**\n * Utility function to check if the current user has a specific permission on a screen.\n * Can be used in components/services outside of route guards.\n */\nexport function hasScreenPermission(\n screenCode: string,\n permission: Permissions,\n grantsStorageKey = 'CURRENT_USER_GRANTS',\n storageType: 'local' | 'session' = 'local'\n): boolean {\n const screenGrants = storageType === 'session'\n ? StorageUtils.getSession<Record<string, { permissions?: string[] }>>(grantsStorageKey)\n : StorageUtils.getLocal<Record<string, { permissions?: string[] }>>(grantsStorageKey);\n if (!screenGrants) return false;\n\n const grant = screenGrants[screenCode];\n return grant?.permissions?.includes(permission) ?? false;\n}\n","export interface AppState {\n preset?: string;\n primary?: string;\n surface?: string;\n darkTheme?: boolean;\n menuActive?: boolean;\n mobileMenuVisible?: boolean;\n designerKey?: string;\n RTL?: boolean;\n}\n\nexport const DEFAULT_APP_STATE: AppState = {\n preset: 'Lara',\n primary: 'noir',\n surface: null as any,\n darkTheme: false,\n menuActive: true,\n mobileMenuVisible: false,\n designerKey: 'primeng-designer-theme',\n RTL: false\n};\n","import { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { computed, effect, inject, Injectable, PLATFORM_ID, signal } from '@angular/core';\nimport { palette, updatePrimaryPalette } from '@primeng/themes';\nimport { StorageUtils } from '@elasticias/utils';\nimport { AppState, DEFAULT_APP_STATE } from './app-state';\n\n/**\n * Service that manages theme state: preset, primary color, surface, dark mode, RTL.\n * State is persisted to localStorage so user preferences survive page reloads.\n *\n * Apps can extend this service or use it directly.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class EfThemeConfigService {\n private readonly STORAGE_KEY = 'APP_CONFIG_STATE';\n\n appState = signal<AppState>(null as any);\n\n designerActive = signal(false);\n\n newsActive = signal(false);\n\n document = inject(DOCUMENT);\n\n platformId = inject(PLATFORM_ID);\n\n theme = computed(() => (this.appState()?.darkTheme ? 'dark' : 'light'));\n\n transitionComplete = signal<boolean>(false);\n\n constructor() {\n const initialState = this.loadAppState();\n this.appState.set({ ...initialState });\n\n // Apply preset class + RTL synchronously so the first paint has\n // the right theme — the effect below picks up subsequent changes\n // (including any subclass `appState.update()` issued before its\n // first run).\n this.updatePresetClass(initialState);\n if (isPlatformBrowser(this.platformId) && initialState?.RTL) {\n this.document.documentElement.setAttribute('dir', 'rtl');\n }\n\n effect(() => {\n const state = this.appState();\n if (!state) return;\n this.saveAppState(state);\n this.updatePresetClass(state);\n this.handleDarkModeTransition(state);\n this.applyRTL(state);\n });\n }\n\n private static readonly PRESET_CLASS_MAP: Record<string, string> = {\n Aura: 'theme-compact',\n Lara: 'theme-modern',\n Material: 'theme-material',\n Nora: 'theme-classic',\n Comptoir: 'theme-comptoir',\n };\n\n private static readonly TENANT_RAMP_STOPS = [50, 100, 200, 300, 400, 500, 600, 700, 800, 900] as const;\n\n private static readonly ALL_THEME_CLASSES = Object.values(EfThemeConfigService.PRESET_CLASS_MAP);\n\n private updatePresetClass(state: AppState): void {\n if (isPlatformBrowser(this.platformId)) {\n const body = this.document.body;\n body.classList.remove(...EfThemeConfigService.ALL_THEME_CLASSES);\n if (state.preset) {\n const cls = EfThemeConfigService.PRESET_CLASS_MAP[state.preset];\n if (cls) {\n body.classList.add(cls);\n }\n }\n }\n }\n\n private handleDarkModeTransition(state: AppState): void {\n if (isPlatformBrowser(this.platformId)) {\n if ((document as any).startViewTransition) {\n this.startViewTransition(state);\n } else {\n this.toggleDarkMode(state);\n this.onTransitionEnd();\n }\n }\n }\n\n private startViewTransition(state: AppState): void {\n const transition = (document as any).startViewTransition(() => {\n this.toggleDarkMode(state);\n });\n\n transition.ready\n .then(() => this.onTransitionEnd())\n .catch(() => { /* view transition aborted */ });\n }\n\n private toggleDarkMode(state: AppState): void {\n if (state.darkTheme) {\n this.document.documentElement.classList.add('p-dark');\n } else {\n this.document.documentElement.classList.remove('p-dark');\n }\n }\n\n private onTransitionEnd() {\n this.transitionComplete.set(true);\n setTimeout(() => {\n this.transitionComplete.set(false);\n });\n }\n\n private applyRTL(state: AppState): void {\n if (isPlatformBrowser(this.platformId)) {\n const setDir = () => {\n if (state.RTL) {\n this.document.documentElement.setAttribute('dir', 'rtl');\n } else {\n this.document.documentElement.removeAttribute('dir');\n }\n };\n\n if ((document as any).startViewTransition) {\n const t = (document as any).startViewTransition(() => setDir());\n t.ready.catch(() => { /* view transition aborted */ });\n } else {\n setDir();\n }\n }\n }\n\n hideMenu() {\n this.appState.update((state) => ({ ...state, menuActive: false }));\n }\n\n showMenu() {\n this.appState.update((state) => ({ ...state, menuActive: true }));\n }\n\n toggleMobileMenu() {\n this.appState.update((state) => ({\n ...state,\n mobileMenuVisible: !state.mobileMenuVisible\n }));\n }\n\n closeMobileMenu() {\n this.appState.update((state) => ({\n ...state,\n mobileMenuVisible: false\n }));\n }\n\n openMobileMenu() {\n this.appState.update((state) => ({\n ...state,\n mobileMenuVisible: true\n }));\n }\n\n hideNews() {\n this.newsActive.set(false);\n }\n\n showNews() {\n this.newsActive.set(true);\n }\n\n showDesigner() {\n this.designerActive.set(true);\n }\n\n hideDesigner() {\n this.designerActive.set(false);\n }\n\n private loadAppState(): AppState {\n if (isPlatformBrowser(this.platformId)) {\n const storedState = StorageUtils.getLocal<AppState>(this.STORAGE_KEY);\n if (storedState) {\n return storedState;\n }\n }\n return { ...DEFAULT_APP_STATE };\n }\n\n private saveAppState(state: AppState): void {\n if (isPlatformBrowser(this.platformId)) {\n StorageUtils.setLocal(this.STORAGE_KEY, state);\n }\n }\n\n /**\n * Applies a tenant's brand color across both PrimeNG's primary palette\n * and the Comptoir `--tenant-*` CSS variables.\n *\n * Generates a 50–950 ramp from the input hex via PrimeNG's `palette()`\n * helper, hands the full ramp to `updatePrimaryPalette()`, and writes\n * stops 50–900 onto `documentElement.style` so the SCSS layer's\n * `var(--tenant-*)` references resolve to the tenant's color.\n *\n * Call this whenever the active tenant changes (e.g., from an effect\n * watching `tenantService.storeConfig().primaryColor`).\n */\n setTenantAccent(hex: string): void {\n if (!hex) return;\n\n const ramp = palette(hex) as Record<string, string>;\n if (!ramp) return;\n\n updatePrimaryPalette(ramp);\n\n if (isPlatformBrowser(this.platformId)) {\n const root = this.document.documentElement;\n for (const stop of EfThemeConfigService.TENANT_RAMP_STOPS) {\n const value = ramp[String(stop)];\n if (value) {\n root.style.setProperty(`--tenant-${stop}`, value);\n }\n }\n }\n }\n}\n","import { definePreset } from '@primeng/themes';\nimport Aura from '@primeng/themes/aura';\nimport Lara from '@primeng/themes/lara';\n\n/* ──────────────────────────────────────────────────────────────────\n * LEGACY: Noir preset (Aura base, monochrome surface palette).\n * Kept for backward-compat with apps that haven't migrated to\n * Comptoir. Phase 5 of the design-system plan retrofits consumers\n * to EfComptoirTheme; once that lands, Noir + EfTheme can be\n * deleted.\n * ────────────────────────────────────────────────────────────── */\n\nconst Noir = definePreset(Aura, {\n semantic: {\n primary: {\n 50: '{surface.50}',\n 100: '{surface.100}',\n 200: '{surface.200}',\n 300: '{surface.300}',\n 400: '{surface.400}',\n 500: '{surface.500}',\n 600: '{surface.600}',\n 700: '{surface.700}',\n 800: '{surface.800}',\n 900: '{surface.900}',\n 950: '{surface.950}'\n },\n colorScheme: {\n light: {\n primary: {\n color: '{primary.950}',\n contrastColor: '#ffffff',\n hoverColor: '{primary.800}',\n activeColor: '{primary.700}'\n },\n highlight: {\n background: '{primary.950}',\n focusBackground: '{primary.700}',\n color: '#ffffff',\n focusColor: '#ffffff'\n }\n },\n dark: {\n primary: {\n color: '{primary.50}',\n contrastColor: '{primary.950}',\n hoverColor: '{primary.200}',\n activeColor: '{primary.300}'\n },\n highlight: {\n background: '{primary.50}',\n focusBackground: '{primary.300}',\n color: '{primary.950}',\n focusColor: '{primary.950}'\n }\n }\n }\n }\n});\n\n/**\n * Default Elasticias theme configuration for PrimeNG.\n * Uses the Noir preset (surface-based primary colors) with dark mode support.\n *\n * @deprecated Migrate to {@link EfComptoirTheme} as part of Phase 5 of the\n * design-system plan. Will be removed once all consumers have moved.\n */\nexport const EfTheme = {\n preset: Noir,\n options: {\n darkModeSelector: '.p-dark',\n }\n};\n\nexport default EfTheme;\n\n/* ──────────────────────────────────────────────────────────────────\n * COMPTOIR: ink surface + tenant primary (Lara base).\n * Surface palette is the ink ramp from libs/tokens/colors.json.\n * Primary palette defaults to the parfumerie sample tenant; it is\n * runtime-replaced by EfThemeConfigService.setTenantAccent(hex)\n * via PrimeNG's updatePrimaryPalette() API.\n * ────────────────────────────────────────────────────────────── */\n\nconst ComptoirPreset = definePreset(Lara, {\n semantic: {\n primary: {\n 50: '#f7f0f4',\n 100: '#ecdce5',\n 200: '#d8b4c5',\n 300: '#b87a99',\n 400: '#934e74',\n 500: '#6f3257',\n 600: '#54243f',\n 700: '#401a30',\n 800: '#2c1221',\n 900: '#1a0913',\n 950: '#0d040a'\n },\n /* ──────────────────────────────────────────────────────────────\n * Control sizing (ADR-009). The native \"comptoir\" variant is the\n * default render path and is pinned to --hit-base (40px) in CSS;\n * these tokens align the OPT-IN PrimeNG variant (p-select filter,\n * p-multiselect, p-inputnumber stepper, etc.) to the same canonical\n * heights so the two paths agree:\n * base → 40px (--hit-base) sm → 32px (--hit) lg → 48px (--hit-touch, POS/mobile)\n * Lara form-field height ≈ paddingY*2 + lineHeight(1.5)*fontSize(14px) + 2px border.\n * base: 8px*2 + 21 + 2 ≈ 40px · sm: 5px*2 + ~18 + 2 ≈ 32px · lg: 12px*2 + 21 + 2 ≈ 48px\n * NOTE: exact pixel height depends on the app's root font-size; the\n * native default path is the verified one — confirm the PrimeNG\n * opt-in controls visually in the running app and nudge paddingY if\n * they read 1-2px off. Border radius matches --r-md (12px). */\n formField: {\n paddingX: '0.75rem',\n paddingY: '0.5rem',\n borderRadius: '12px',\n sm: {\n fontSize: '0.78rem',\n paddingX: '0.625rem',\n paddingY: '0.3125rem'\n },\n lg: {\n fontSize: '0.9375rem',\n paddingX: '0.875rem',\n paddingY: '0.75rem'\n }\n },\n colorScheme: {\n light: {\n primary: {\n color: '{primary.500}',\n contrastColor: '#ffffff',\n hoverColor: '{primary.600}',\n activeColor: '{primary.700}'\n },\n surface: {\n 0: '#ffffff',\n 50: '#f8f9fb',\n 100: '#f1f3f6',\n 200: '#e4e8ee',\n 300: '#cdd3dd',\n 400: '#9ca5b3',\n 500: '#6c7280',\n 600: '#4a4f5a',\n 700: '#2f3239',\n 800: '#1d1f24',\n 900: '#0f1115',\n 950: '#06070a'\n },\n highlight: {\n background: '{primary.500}',\n focusBackground: '{primary.600}',\n color: '#ffffff',\n focusColor: '#ffffff'\n }\n },\n dark: {\n primary: {\n color: '{primary.400}',\n contrastColor: '{primary.950}',\n hoverColor: '{primary.300}',\n activeColor: '{primary.200}'\n },\n /* The ramp runs in the SAME direction as the light one, and\n * that is deliberate — it used to be inverted here (0 = black\n * … 950 = near-white) and that single flip was the cause of\n * dark mode being unreadable product-wide.\n *\n * PrimeNG's surface ramp is not \"light values for light mode,\n * dark values for dark mode\". It is a fixed light→dark scale\n * that the *semantic* block indexes differently per scheme:\n * light reads `{surface.0}` as the page and `{surface.700}` as\n * body text, dark reads `{surface.900}` as the page and\n * `{surface.0}` as body text. Every component preset inherits\n * those conventions. Inverting the ramp therefore inverted\n * every inherited value at once — dark `text.color` resolved\n * to #000000, `content.background` to #f1f3f6, and\n * `button.text.secondary.color` to #2f3239 on a #1d1f24 card\n * (1.28:1, the reported bug).\n *\n * Keeping the ramp upright makes the ink scale land exactly on\n * the Comptoir dark aliases from `_comptoir.scss`:\n * surface.900 → --paper (#0f1115)\n * surface.800 → --paper-alt (#1d1f24)\n * surface.400 → --text-mute (#9ca5b3)\n * surface.50 → --text (#f8f9fb)\n * so inherited PrimeNG values agree with the design system\n * instead of fighting it. */\n surface: {\n 0: '#ffffff',\n 50: '#f8f9fb',\n 100: '#f1f3f6',\n 200: '#e4e8ee',\n 300: '#cdd3dd',\n 400: '#9ca5b3',\n 500: '#6c7280',\n 600: '#4a4f5a',\n 700: '#2f3239',\n 800: '#1d1f24',\n 900: '#0f1115',\n 950: '#06070a'\n },\n /* Lara's dark body text is `{surface.0}` = pure white; Comptoir's\n * --text is --ink-50. Pin it so the two agree. 17.94:1 on\n * --paper, 15.65:1 on --paper-alt. */\n text: {\n color: '{surface.50}',\n hoverColor: '{surface.50}'\n },\n highlight: {\n background: '{primary.400}',\n focusBackground: '{primary.300}',\n color: '{primary.950}',\n focusColor: '{primary.950}'\n }\n }\n }\n },\n /* ──────────────────────────────────────────────────────────────\n * Button: the low-emphasis variants.\n *\n * An upright surface ramp (above) fixes everything Lara expresses\n * through `{surface.N}`. It cannot fix the variants Lara expresses\n * through the accent and through raw Tailwind reds, because those\n * were tuned against Lara's own indigo/zinc, not against the\n * Comptoir tenant ramp. Measured on the default parfumerie accent,\n * against --paper (#0f1115) / --paper-alt (#1d1f24) in dark and\n * #ffffff / --paper (#f8f9fb) in light, resting state:\n *\n * dark text.primary {primary.400} #934e74 → 3.22 / 2.81 ✗\n * dark outlined.primary.border {primary.700} #401a30 → 1.27 / 1.11 ✗\n * dark outlined.secondary.border {surface.700} → 1.47 / 1.28 ✗\n * dark outlined.danger.border {red.700} → 2.92 / 2.55 ✗\n * light text.danger {red.500} #ef4444 → 3.76 / 3.57 ✗\n * light outlined.primary.border {primary.200} → 1.87 / 1.77 ✗\n * light outlined.secondary.border {surface.200} → 1.19 / 1.13 ✗\n *\n * Text colours below clear 4.5:1 in every state (resting, hover\n * tint and the 16% active tint); border colours clear the 3:1\n * WCAG 1.4.11 bar for a component boundary without brightening\n * into something that reads as a fill.\n *\n * The severities Comptoir actually ships on `<ef-button>` are\n * primary / secondary / danger; success, info, warn, help and\n * contrast are left on stock, which the upright ramp already\n * makes legible.\n *\n * Caveat: `{primary.N}` tracks the tenant accent through\n * `EfThemeConfigService.setTenantAccent()`, so these ratios hold\n * for the default ramp. A very dark or very light tenant accent\n * would need a lightness clamp in the ramp generator — noted, not\n * built. */\n components: {\n button: {\n colorScheme: {\n light: {\n text: {\n /* {primary.color} (= {primary.500}) already reads\n * 9.25 / 8.78 — left on stock so it keeps tracking\n * the tenant accent. */\n danger: { color: '{red.700}' } /* 6.47 / 6.14 */\n },\n outlined: {\n primary: { borderColor: '{primary.300}' }, /* 3.34 / 3.17 */\n secondary: { color: '{surface.600}', borderColor: '{surface.500}' }, /* 8.21 / 7.80 · border 4.82 / 4.58 */\n danger: { color: '{red.700}', borderColor: '{red.500}' } /* 6.47 / 6.14 · border 3.76 / 3.57 */\n }\n },\n dark: {\n text: {\n primary: { color: '{primary.200}' }, /* 10.13 / 8.84 */\n secondary: { color: '{surface.300}' }, /* 12.56 / 10.96 — the reported 1.28 pair */\n danger: { color: '{red.400}' } /* 6.83 / 5.96 */\n },\n outlined: {\n primary: { color: '{primary.200}', borderColor: '{primary.300}' }, /* 10.13 / 8.84 · border 5.65 / 4.93 */\n secondary: { color: '{surface.300}', borderColor: '{surface.500}' }, /* 12.56 / 10.96 · border 3.92 / 3.42 */\n danger: { color: '{red.400}', borderColor: '{red.500}' } /* 6.83 / 5.96 · border 5.02 / 4.38 */\n },\n /* `[link]=\"true\"` carries no ground of its own, so it sits\n * straight on --paper / --paper-alt: {primary.color} reads\n * 3.22 / 2.81 there. Same lift as the text variant. */\n link: {\n color: '{primary.200}', /* 10.13 / 8.84 */\n hoverColor: '{primary.100}',\n activeColor: '{primary.100}'\n }\n }\n }\n }\n }\n});\n\n/**\n * Comptoir theme configuration for PrimeNG (Phase 1 / design-system v0.2).\n * Surface palette = ink ramp; primary palette = tenant accent\n * (runtime-driven via `EfThemeConfigService.setTenantAccent(hex)`).\n *\n * Usage with providePrimeNG:\n * ```ts\n * providePrimeNG({ theme: EfComptoirTheme, ripple: true })\n * ```\n *\n * Pair with `state.preset = 'Comptoir'` so the body class becomes\n * `theme-comptoir` (avoids legacy `theme-modern` radius overrides).\n */\nexport const EfComptoirTheme = {\n preset: ComptoirPreset,\n options: {\n darkModeSelector: '.p-dark',\n }\n};\n","import { Translation } from 'primeng/api';\n\n/**\n * English locale for PrimeNG components.\n *\n * Usage:\n * ```ts\n * import { PRIMENG_EN_LOCALE } from '@elasticias/core';\n * this.primeng.translation = PRIMENG_EN_LOCALE;\n * ```\n */\nexport const PRIMENG_EN_LOCALE: Translation = {\n startsWith: 'Starts with',\n contains: 'Contains',\n notContains: 'Not contains',\n endsWith: 'Ends with',\n equals: 'Equals',\n notEquals: 'Not equals',\n noFilter: 'No Filter',\n lt: 'Less than',\n lte: 'Less than or equal to',\n gt: 'Greater than',\n gte: 'Greater than or equal to',\n dateIs: 'Date is',\n dateIsNot: 'Date is not',\n dateBefore: 'Date is before',\n dateAfter: 'Date is after',\n clear: 'Clear',\n apply: 'Apply',\n matchAll: 'Match All',\n matchAny: 'Match Any',\n addRule: 'Add Rule',\n removeRule: 'Remove Rule',\n accept: 'Yes',\n reject: 'No',\n choose: 'Choose',\n upload: 'Upload',\n cancel: 'Cancel',\n completed: 'Completed',\n pending: 'Pending',\n fileSizeTypes: ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],\n dayNames: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'],\n dayNamesShort: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],\n dayNamesMin: ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'],\n monthNames: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'],\n monthNamesShort: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],\n chooseYear: 'Choose Year',\n chooseMonth: 'Choose Month',\n chooseDate: 'Choose Date',\n prevDecade: 'Previous Decade',\n nextDecade: 'Next Decade',\n prevYear: 'Previous Year',\n nextYear: 'Next Year',\n prevMonth: 'Previous Month',\n nextMonth: 'Next Month',\n prevHour: 'Previous Hour',\n nextHour: 'Next Hour',\n prevMinute: 'Previous Minute',\n nextMinute: 'Next Minute',\n prevSecond: 'Previous Second',\n nextSecond: 'Next Second',\n am: 'AM',\n pm: 'PM',\n today: 'Today',\n weekHeader: 'Wk',\n firstDayOfWeek: 0,\n showMonthAfterYear: false,\n dateFormat: 'mm/dd/yy',\n weak: 'Weak',\n medium: 'Medium',\n strong: 'Strong',\n passwordPrompt: 'Enter a password',\n emptyFilterMessage: 'No results found',\n searchMessage: '{0} results are available',\n selectionMessage: '{0} items selected',\n emptySelectionMessage: 'No selected item',\n emptySearchMessage: 'No results found',\n emptyMessage: 'No available options',\n aria: {\n trueLabel: 'True',\n falseLabel: 'False',\n nullLabel: 'Not Selected',\n star: '1 star',\n stars: '{star} stars',\n selectAll: 'All items selected',\n unselectAll: 'All items unselected',\n close: 'Close',\n previous: 'Previous',\n next: 'Next',\n navigation: 'Navigation',\n scrollTop: 'Scroll Top',\n moveTop: 'Move Top',\n moveUp: 'Move Up',\n moveDown: 'Move Down',\n moveBottom: 'Move Bottom',\n moveToTarget: 'Move to Target',\n moveToSource: 'Move to Source',\n moveAllToTarget: 'Move All to Target',\n moveAllToSource: 'Move All to Source',\n pageLabel: 'Page {page}',\n firstPageLabel: 'First Page',\n lastPageLabel: 'Last Page',\n nextPageLabel: 'Next Page',\n prevPageLabel: 'Previous Page',\n rowsPerPageLabel: 'Rows per page',\n jumpToPageDropdownLabel: 'Jump to Page Dropdown',\n jumpToPageInputLabel: 'Jump to Page Input',\n selectRow: 'Row Selected',\n unselectRow: 'Row Unselected',\n expandRow: 'Row Expanded',\n collapseRow: 'Row Collapsed',\n showFilterMenu: 'Show Filter Menu',\n hideFilterMenu: 'Hide Filter Menu',\n filterOperator: 'Filter Operator',\n filterConstraint: 'Filter Constraint',\n editRow: 'Row Edit',\n saveEdit: 'Save Edit',\n cancelEdit: 'Cancel Edit',\n listView: 'List View',\n gridView: 'Grid View',\n slide: 'Slide',\n slideNumber: '{slideNumber}',\n zoomImage: 'Zoom Image',\n zoomIn: 'Zoom In',\n zoomOut: 'Zoom Out',\n rotateRight: 'Rotate Right',\n rotateLeft: 'Rotate Left',\n listLabel: 'Option List',\n },\n} as Translation;\n","import { Translation } from 'primeng/api';\n\n/**\n * French locale for PrimeNG components.\n *\n * Usage:\n * ```ts\n * import { PRIMENG_FR_LOCALE } from '@elasticias/core';\n * this.primeng.translation = PRIMENG_FR_LOCALE;\n * ```\n */\nexport const PRIMENG_FR_LOCALE: Translation = {\n startsWith: 'Commence par',\n contains: 'Contient',\n notContains: 'Ne contient pas',\n endsWith: 'Se termine par',\n equals: 'Égal à',\n notEquals: 'Différent de',\n noFilter: 'Aucun filtre',\n lt: 'Inférieur à',\n lte: 'Inférieur ou égal à',\n gt: 'Supérieur à',\n gte: 'Supérieur ou égal à',\n dateIs: 'La date est',\n dateIsNot: \"La date n'est pas\",\n dateBefore: 'La date est avant',\n dateAfter: 'La date est après',\n clear: 'Effacer',\n apply: 'Appliquer',\n matchAll: 'Correspond à tous',\n matchAny: \"Correspond à n'importe quel\",\n addRule: 'Ajouter une règle',\n removeRule: 'Supprimer la règle',\n accept: 'Oui',\n reject: 'Non',\n choose: 'Choisir',\n upload: 'Télécharger',\n cancel: 'Annuler',\n completed: 'Terminé',\n pending: 'En attente',\n fileSizeTypes: ['o', 'Ko', 'Mo', 'Go', 'To', 'Po', 'Eo', 'Zo', 'Yo'],\n dayNames: ['Dimanche', 'Lundi', 'Mardi', 'Mercredi', 'Jeudi', 'Vendredi', 'Samedi'],\n dayNamesShort: ['Dim', 'Lun', 'Mar', 'Mer', 'Jeu', 'Ven', 'Sam'],\n dayNamesMin: ['Di', 'Lu', 'Ma', 'Me', 'Je', 'Ve', 'Sa'],\n monthNames: ['Janvier', 'Février', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Août', 'Septembre', 'Octobre', 'Novembre', 'Décembre'],\n monthNamesShort: ['Jan', 'Fév', 'Mar', 'Avr', 'Mai', 'Jun', 'Jul', 'Aoû', 'Sep', 'Oct', 'Nov', 'Déc'],\n chooseYear: \"Choisir l'année\",\n chooseMonth: 'Choisir le mois',\n chooseDate: 'Choisir la date',\n prevDecade: 'Décennie précédente',\n nextDecade: 'Décennie suivante',\n prevYear: 'Année précédente',\n nextYear: 'Année suivante',\n prevMonth: 'Mois précédent',\n nextMonth: 'Mois suivant',\n prevHour: 'Heure précédente',\n nextHour: 'Heure suivante',\n prevMinute: 'Minute précédente',\n nextMinute: 'Minute suivante',\n prevSecond: 'Seconde précédente',\n nextSecond: 'Seconde suivante',\n am: 'AM',\n pm: 'PM',\n today: \"Aujourd'hui\",\n weekHeader: 'Sem',\n firstDayOfWeek: 1,\n showMonthAfterYear: false,\n dateFormat: 'dd/mm/yy',\n weak: 'Faible',\n medium: 'Moyen',\n strong: 'Fort',\n passwordPrompt: 'Entrez un mot de passe',\n emptyFilterMessage: 'Aucun résultat trouvé',\n searchMessage: '{0} résultats sont disponibles',\n selectionMessage: '{0} éléments sélectionnés',\n emptySelectionMessage: 'Aucun élément sélectionné',\n emptySearchMessage: 'Aucun résultat trouvé',\n emptyMessage: 'Aucune option disponible',\n aria: {\n trueLabel: 'Vrai',\n falseLabel: 'Faux',\n nullLabel: 'Non sélectionné',\n star: '1 étoile',\n stars: '{star} étoiles',\n selectAll: 'Tous les éléments sélectionnés',\n unselectAll: 'Tous les éléments désélectionnés',\n close: 'Fermer',\n previous: 'Précédent',\n next: 'Suivant',\n navigation: 'Navigation',\n scrollTop: 'Défiler vers le haut',\n moveTop: 'Déplacer vers le haut',\n moveUp: 'Déplacer vers le haut',\n moveDown: 'Déplacer vers le bas',\n moveBottom: 'Déplacer vers le bas',\n moveToTarget: 'Déplacer vers la cible',\n moveToSource: 'Déplacer vers la source',\n moveAllToTarget: 'Tout déplacer vers la cible',\n moveAllToSource: 'Tout déplacer vers la source',\n pageLabel: 'Page {page}',\n firstPageLabel: 'Première page',\n lastPageLabel: 'Dernière page',\n nextPageLabel: 'Page suivante',\n prevPageLabel: 'Page précédente',\n rowsPerPageLabel: 'Lignes par page',\n jumpToPageDropdownLabel: 'Aller à la page',\n jumpToPageInputLabel: 'Aller à la page',\n selectRow: 'Ligne sélectionnée',\n unselectRow: 'Ligne désélectionnée',\n expandRow: 'Ligne développée',\n collapseRow: 'Ligne réduite',\n showFilterMenu: 'Afficher le menu de filtrage',\n hideFilterMenu: 'Masquer le menu de filtrage',\n filterOperator: 'Opérateur de filtrage',\n filterConstraint: 'Contrainte de filtrage',\n editRow: 'Modifier la ligne',\n saveEdit: 'Enregistrer la modification',\n cancelEdit: 'Annuler la modification',\n listView: 'Vue en liste',\n gridView: 'Vue en grille',\n slide: 'Glisser',\n slideNumber: '{slideNumber}',\n zoomImage: \"Agrandir l'image\",\n zoomIn: 'Zoomer',\n zoomOut: 'Dézoomer',\n rotateRight: 'Faire pivoter à droite',\n rotateLeft: 'Faire pivoter à gauche',\n listLabel: 'Liste',\n },\n} as Translation;\n","import { Translation } from 'primeng/api';\n\n/**\n * Arabic locale for PrimeNG components (Moroccan month names).\n *\n * Usage:\n * ```ts\n * import { PRIMENG_AR_LOCALE } from '@elasticias/core';\n * this.primeng.translation = PRIMENG_AR_LOCALE;\n * ```\n */\nexport const PRIMENG_AR_LOCALE: Translation = {\n startsWith: 'يبدأ بـ',\n contains: 'يحتوي على',\n notContains: 'لا يحتوي على',\n endsWith: 'ينتهي بـ',\n equals: 'يساوي',\n notEquals: 'لا يساوي',\n noFilter: 'بدون فلتر',\n lt: 'أقل من',\n lte: 'أقل من أو يساوي',\n gt: 'أكبر من',\n gte: 'أكبر من أو يساوي',\n dateIs: 'التاريخ هو',\n dateIsNot: 'التاريخ ليس',\n dateBefore: 'التاريخ قبل',\n dateAfter: 'التاريخ بعد',\n clear: 'مسح',\n apply: 'تطبيق',\n matchAll: 'تطابق الكل',\n matchAny: 'تطابق أي',\n addRule: 'إضافة قاعدة',\n removeRule: 'حذف القاعدة',\n accept: 'نعم',\n reject: 'لا',\n choose: 'اختيار',\n upload: 'رفع',\n cancel: 'إلغاء',\n completed: 'مكتمل',\n pending: 'قيد الانتظار',\n fileSizeTypes: ['بايت', 'ك.ب', 'م.ب', 'ج.ب', 'ت.ب', 'ب.ب', 'إ.ب', 'ز.ب', 'ي.ب'],\n dayNames: ['الأحد', 'الاثنين', 'الثلاثاء', 'الأربعاء', 'الخميس', 'الجمعة', 'السبت'],\n dayNamesShort: ['أحد', 'اثن', 'ثلا', 'أرب', 'خمي', 'جمع', 'سبت'],\n dayNamesMin: ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],\n monthNames: ['يناير', 'فبراير', 'مارس', 'أبريل', 'ماي', 'يونيو', 'يوليوز', 'غشت', 'شتنبر', 'أكتوبر', 'نونبر', 'دجنبر'],\n monthNamesShort: ['ينا', 'فبر', 'مار', 'أبر', 'ماي', 'يون', 'يول', 'غشت', 'شتن', 'أكت', 'نون', 'دجن'],\n chooseYear: 'اختر السنة',\n chooseMonth: 'اختر الشهر',\n chooseDate: 'اختر التاريخ',\n prevDecade: 'العقد السابق',\n nextDecade: 'العقد التالي',\n prevYear: 'السنة السابقة',\n nextYear: 'السنة التالية',\n prevMonth: 'الشهر السابق',\n nextMonth: 'الشهر التالي',\n prevHour: 'الساعة السابقة',\n nextHour: 'الساعة التالية',\n prevMinute: 'الدقيقة السابقة',\n nextMinute: 'الدقيقة التالية',\n prevSecond: 'الثانية السابقة',\n nextSecond: 'الثانية التالية',\n am: 'ص',\n pm: 'م',\n today: 'اليوم',\n weekHeader: 'أس',\n firstDayOfWeek: 1,\n showMonthAfterYear: false,\n dateFormat: 'dd/mm/yy',\n weak: 'ضعيف',\n medium: 'متوسط',\n strong: 'قوي',\n passwordPrompt: 'أدخل كلمة المرور',\n emptyFilterMessage: 'لم يتم العثور على نتائج',\n searchMessage: '{0} نتائج متاحة',\n selectionMessage: '{0} عناصر محددة',\n emptySelectionMessage: 'لا يوجد عنصر محدد',\n emptySearchMessage: 'لم يتم العثور على نتائج',\n emptyMessage: 'لا توجد خيارات متاحة',\n aria: {\n trueLabel: 'صحيح',\n falseLabel: 'خاطئ',\n nullLabel: 'غير محدد',\n star: 'نجمة واحدة',\n stars: '{star} نجوم',\n selectAll: 'تم تحديد جميع العناصر',\n unselectAll: 'تم إلغاء تحديد جميع العناصر',\n close: 'إغلاق',\n previous: 'السابق',\n next: 'التالي',\n navigation: 'التنقل',\n scrollTop: 'التمرير للأعلى',\n moveTop: 'نقل للأعلى',\n moveUp: 'نقل للأعلى',\n moveDown: 'نقل للأسفل',\n moveBottom: 'نقل للأسفل',\n moveToTarget: 'نقل إلى الهدف',\n moveToSource: 'نقل إلى المصدر',\n moveAllToTarget: 'نقل الكل إلى الهدف',\n moveAllToSource: 'نقل الكل إلى المصدر',\n pageLabel: 'صفحة {page}',\n firstPageLabel: 'الصفحة الأولى',\n lastPageLabel: 'الصفحة الأخيرة',\n nextPageLabel: 'الصفحة التالية',\n prevPageLabel: 'الصفحة السابقة',\n rowsPerPageLabel: 'سطور في الصفحة',\n jumpToPageDropdownLabel: 'الانتقال إلى الصفحة',\n jumpToPageInputLabel: 'الانتقال إلى الصفحة',\n selectRow: 'تم تحديد السطر',\n unselectRow: 'تم إلغاء تحديد السطر',\n expandRow: 'تم توسيع السطر',\n collapseRow: 'تم طي السطر',\n showFilterMenu: 'إظهار قائمة الفلتر',\n hideFilterMenu: 'إخفاء قائمة الفلتر',\n filterOperator: 'عامل الفلتر',\n filterConstraint: 'قيد الفلتر',\n editRow: 'تعديل السطر',\n saveEdit: 'حفظ التعديل',\n cancelEdit: 'إلغاء التعديل',\n listView: 'عرض قائمة',\n gridView: 'عرض شبكة',\n slide: 'تمرير',\n slideNumber: '{slideNumber}',\n zoomImage: 'تكبير الصورة',\n zoomIn: 'تكبير',\n zoomOut: 'تصغير',\n rotateRight: 'تدوير لليمين',\n rotateLeft: 'تدوير لليسار',\n listLabel: 'قائمة',\n },\n} as Translation;\n","import { InjectionToken } from '@angular/core';\n\n/**\n * The eight ERP modules surfaced by Comptoir. New modules require\n * a matching `--m-{id}` token in the SCSS layer (libs/ui/src/lib/_comptoir.scss)\n * and a labelKey in the consuming app's i18n bundles.\n */\nexport type EfModuleId =\n | 'sales'\n | 'purchase'\n | 'stock'\n | 'pos'\n | 'marketing'\n | 'store'\n | 'finance'\n | 'admin';\n\nexport type EfNavAction = 'read' | 'write' | 'admin';\n\nexport interface EfNavItem {\n /** Stable identifier — usually matches the screen code (e.g. `Users`, `SalesOrders`). */\n id: string;\n labelKey: string;\n icon?: string;\n route: string;\n /** Minimum permission level required to render this item. Defaults to `read`. */\n requiredAction?: EfNavAction;\n /**\n * Optional count chip rendered after the label (e.g. `Commandes ⟨14⟩`).\n * Apps typically derive this from a service signal and patch the\n * registry — it can be number, string, or anything stringifiable.\n */\n badge?: string | number;\n}\n\nexport interface EfNavSection {\n id: string;\n labelKey?: string;\n items: EfNavItem[];\n}\n\nexport interface EfModule {\n id: EfModuleId;\n labelKey: string;\n /** PrimeNG icon class used by `ef-module-rail`, e.g. `pi pi-shopping-bag`. */\n icon: string;\n /**\n * CSS custom-property name (without the leading `--`) that the rail\n * applies to the module-current accent. Always `m-{id}` and resolves\n * via the SCSS layer's `[data-module]` selectors at runtime.\n */\n accent: `m-${EfModuleId}`;\n defaultRoute: string;\n navSections: EfNavSection[];\n /**\n * Logical grouping for rail divider placement. `ef-module-rail` renders\n * a 1px divider between two consecutive visible modules whose `group`\n * differs. Free string — `'operations' | 'commerce' | 'admin'` is the\n * conventional set but apps can use anything stable.\n */\n group?: string;\n}\n\n/**\n * Default skeleton for the eight ERP modules. Apps either consume this\n * directly via `EF_MODULES_TOKEN` or extend it with their own `navSections`.\n *\n * Phase 1 ships the metadata only — `ef-module-rail` (Phase 2) uses\n * `id` / `labelKey` / `icon` / `accent` / `defaultRoute`. `navSections`\n * are populated per-app as each module's screens land in Phase 4-5.\n */\nexport const EF_MODULES: ReadonlyArray<EfModule> = [\n {\n id: 'sales',\n labelKey: 'modules.sales',\n icon: 'pi pi-shopping-bag',\n accent: 'm-sales',\n defaultRoute: '/operations/sales',\n navSections: [],\n group: 'operations',\n },\n {\n id: 'purchase',\n labelKey: 'modules.purchase',\n icon: 'pi pi-truck',\n accent: 'm-purchase',\n defaultRoute: '/operations/purchase',\n navSections: [],\n group: 'operations',\n },\n {\n id: 'stock',\n labelKey: 'modules.stock',\n icon: 'pi pi-warehouse',\n accent: 'm-stock',\n defaultRoute: '/operations/stock',\n navSections: [],\n group: 'operations',\n },\n {\n id: 'pos',\n labelKey: 'modules.pos',\n icon: 'pi pi-shop',\n accent: 'm-pos',\n defaultRoute: '/pos',\n navSections: [],\n group: 'operations',\n },\n {\n id: 'marketing',\n labelKey: 'modules.marketing',\n icon: 'pi pi-megaphone',\n accent: 'm-marketing',\n defaultRoute: '/marketing',\n navSections: [],\n group: 'commerce',\n },\n {\n id: 'store',\n labelKey: 'modules.store',\n icon: 'pi pi-globe',\n accent: 'm-store',\n defaultRoute: '/store',\n navSections: [],\n group: 'commerce',\n },\n {\n id: 'finance',\n labelKey: 'modules.finance',\n icon: 'pi pi-chart-line',\n accent: 'm-finance',\n defaultRoute: '/finance',\n navSections: [],\n group: 'commerce',\n },\n {\n id: 'admin',\n labelKey: 'modules.admin',\n icon: 'pi pi-shield',\n accent: 'm-admin',\n defaultRoute: '/admin',\n navSections: [],\n group: 'admin',\n },\n];\n\n/**\n * DI token that the shell components (`ef-module-rail`, `ef-module-side`)\n * read from. Apps provide their own definition (typically extending\n * `EF_MODULES` with populated `navSections`):\n *\n * ```ts\n * providers: [\n * { provide: EF_MODULES_TOKEN, useValue: APP_MODULES }\n * ]\n * ```\n */\nexport const EF_MODULES_TOKEN = new InjectionToken<ReadonlyArray<EfModule>>(\n 'EF_MODULES',\n { providedIn: 'root', factory: () => EF_MODULES }\n);\n","import { computed, DestroyRef, inject, Injectable, signal } from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { NavigationEnd, Router } from '@angular/router';\nimport { filter } from 'rxjs/operators';\nimport { EF_MODULES_TOKEN, EfModule, EfModuleId, EfNavItem } from './ef-module-registry';\n\n/**\n * Single source of truth for \"which ERP module is active right now.\"\n *\n * Watches the Router and matches the current URL against each module's\n * `defaultRoute`. The longest matching prefix wins, so `/operations/sales`\n * resolves to `sales` even though `/operations` could in theory match\n * something shorter.\n *\n * Consumers — `ef-module-rail`, `ef-module-side`, `ef-app-main`,\n * `ef-page-head` — read `activeModule()` and derive their state from it.\n *\n * Apps that navigate programmatically without a URL change (rare) can\n * call `setActiveModule(id)` to override.\n */\n@Injectable({ providedIn: 'root' })\nexport class EfActiveModuleService {\n private readonly router = inject(Router);\n private readonly modules = inject(EF_MODULES_TOKEN);\n private readonly destroyRef = inject(DestroyRef);\n\n private readonly _activeModule = signal<EfModule | null>(null);\n private readonly _activeNavItem = signal<EfNavItem | null>(null);\n\n readonly activeModule = this._activeModule.asReadonly();\n readonly activeModuleId = computed(() => this._activeModule()?.id ?? null);\n readonly activeNavItem = this._activeNavItem.asReadonly();\n\n constructor() {\n this.resolveFromUrl(this.router.url);\n\n this.router.events\n .pipe(\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\n takeUntilDestroyed(this.destroyRef),\n )\n .subscribe(e => this.resolveFromUrl(e.urlAfterRedirects));\n }\n\n /**\n * Force the active module. Most apps don't need this — the router\n * subscription keeps `activeModule()` in sync automatically.\n */\n setActiveModule(id: EfModuleId | null): void {\n if (id === null) {\n this._activeModule.set(null);\n return;\n }\n const match = this.modules.find(m => m.id === id);\n if (match) this._activeModule.set(match);\n }\n\n private resolveFromUrl(url: string): void {\n const path = url.split('?')[0].split('#')[0];\n\n let bestModule: EfModule | null = null;\n let bestNavItem: EfNavItem | null = null;\n let bestLen = 0;\n for (const m of this.modules) {\n for (const route of this.routesFor(m)) {\n if (path === route || path.startsWith(route + '/')) {\n if (route.length > bestLen) {\n bestModule = m;\n bestNavItem = this.findNavItem(m, route);\n bestLen = route.length;\n }\n }\n }\n }\n this._activeModule.set(bestModule);\n this._activeNavItem.set(bestNavItem);\n }\n\n private findNavItem(m: EfModule, route: string): EfNavItem | null {\n for (const section of m.navSections) {\n for (const item of section.items) {\n if (item.route === route) return item;\n }\n }\n return null;\n }\n\n /**\n * Every URL prefix that should resolve back to this module: the\n * `defaultRoute` plus every nav item route. Modules whose nav items\n * span multiple URL prefixes (e.g. sales spread across `/operations/sales`\n * and `/parameters/sales`) need this to stay active across all of them.\n */\n private routesFor(m: EfModule): string[] {\n const routes: string[] = [m.defaultRoute];\n for (const section of m.navSections) {\n for (const item of section.items) {\n routes.push(item.route);\n }\n }\n return routes;\n }\n}\n","import { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { computed, DestroyRef, inject, Injectable, PLATFORM_ID, signal } from '@angular/core';\n\nexport type EfViewport = 'mobile' | 'tablet' | 'desktop';\n\ninterface ViewportQuery {\n viewport: EfViewport;\n query: string;\n}\n\nconst QUERIES: ViewportQuery[] = [\n { viewport: 'mobile', query: '(max-width: 767px)' },\n { viewport: 'tablet', query: '(min-width: 768px) and (max-width: 1279px)' },\n { viewport: 'desktop', query: '(min-width: 1280px)' },\n];\n\n/**\n * Emits the current viewport tier based on `window.matchMedia` breakpoints.\n *\n * Breakpoints come from `libs/tokens/targets.json`:\n * - mobile: ≤ 767px\n * - tablet: 768 – 1279px\n * - desktop: ≥ 1280px\n *\n * SSR-safe: returns `'desktop'` when `window` is unavailable.\n *\n * Usage:\n * ```ts\n * private viewport = inject(EfViewportService);\n *\n * isMobile = computed(() => this.viewport.current() === 'mobile');\n * ```\n */\n@Injectable({ providedIn: 'root' })\nexport class EfViewportService {\n private readonly document = inject(DOCUMENT);\n private readonly platformId = inject(PLATFORM_ID);\n private readonly destroyRef = inject(DestroyRef);\n\n private readonly _current = signal<EfViewport>('desktop');\n\n readonly current = this._current.asReadonly();\n readonly isMobile = computed(() => this._current() === 'mobile');\n readonly isTablet = computed(() => this._current() === 'tablet');\n readonly isDesktop = computed(() => this._current() === 'desktop');\n\n constructor() {\n if (!isPlatformBrowser(this.platformId)) return;\n\n const win = this.document.defaultView;\n if (!win || typeof win.matchMedia !== 'function') return;\n\n const lists = QUERIES.map(({ viewport, query }) => {\n const mql = win.matchMedia(query);\n const handler = (e: MediaQueryListEvent | MediaQueryList) => {\n if (e.matches) this._current.set(viewport);\n };\n handler(mql);\n mql.addEventListener('change', handler as (e: MediaQueryListEvent) => void);\n return { mql, handler };\n });\n\n this.destroyRef.onDestroy(() => {\n for (const { mql, handler } of lists) {\n mql.removeEventListener('change', handler as (e: MediaQueryListEvent) => void);\n }\n });\n }\n}\n","import { computed, inject, Injectable, Signal, signal } from '@angular/core';\nimport { EF_MODULES_TOKEN, EfModule, EfModuleId } from '../modules/ef-module-registry';\n\nexport type EfPermissionLevel = 'none' | 'read' | 'write' | 'admin';\n\nexport interface EfModulePermission {\n module: EfModuleId;\n level: EfPermissionLevel;\n}\n\nconst LEVEL_ORDER: Record<EfPermissionLevel, number> = {\n none: 0,\n read: 1,\n write: 2,\n admin: 3,\n};\n\nconst ACTION_REQUIRED: Record<Exclude<EfPermissionLevel, 'none'>, EfPermissionLevel> = {\n read: 'read',\n write: 'write',\n admin: 'admin',\n};\n\n/**\n * Module-scoped permission service.\n *\n * Apps populate it from their auth bootstrap once the user's profile is\n * loaded — typically via `setPermissions()` or by providing a custom\n * source signal:\n *\n * ```ts\n * // bootstrap.ts\n * const perms = inject(EfPermissionService);\n * perms.setPermissions(profile.permissions);\n * ```\n *\n * The service is the single source of truth for shell components\n * (`ef-module-rail`, `ef-module-side`, `*efCan` directive) and routing\n * defaults. Once the screens/menus → Mongo migration lands, the\n * permissions list will be served denormalized on the user/profile\n * document and consumed here without a join.\n */\n@Injectable({ providedIn: 'root' })\nexport class EfPermissionService {\n private readonly modules = inject(EF_MODULES_TOKEN);\n\n private readonly _permissions = signal<ReadonlyArray<EfModulePermission>>([]);\n\n readonly permissions = this._permissions.asReadonly();\n\n /**\n * Replace the current permission set. Pass `[]` to clear (e.g., on logout).\n */\n setPermissions(perms: ReadonlyArray<EfModulePermission>): void {\n this._permissions.set(perms);\n }\n\n /**\n * The level granted to the current user for a given module.\n * Returns `'none'` if the module is not in the permission set.\n */\n level(module: EfModuleId): EfPermissionLevel {\n return this._permissions().find(p => p.module === module)?.level ?? 'none';\n }\n\n /**\n * Whether the current user can perform `action` on `module`.\n * Levels are hierarchical: `admin` > `write` > `read` > `none`.\n */\n can(module: EfModuleId, action: Exclude<EfPermissionLevel, 'none'> = 'read'): boolean {\n return LEVEL_ORDER[this.level(module)] >= LEVEL_ORDER[ACTION_REQUIRED[action]];\n }\n\n /**\n * The list of modules the user can read, in registry order.\n * Used by `ef-module-rail` to decide which icons render.\n */\n readonly visibleModules: Signal<ReadonlyArray<EfModule>> = computed(() => {\n const perms = this._permissions();\n const granted = new Set(\n perms.filter(p => p.level !== 'none').map(p => p.module)\n );\n return this.modules.filter(m => granted.has(m.id));\n });\n\n /**\n * The first visible module — the default landing module after login.\n * Returns `null` when the user has no modules.\n */\n readonly defaultModule: Signal<EfModule | null> = computed(() => {\n return this.visibleModules()[0] ?? null;\n });\n}\n","import { InjectionToken } from '@angular/core';\n\n/**\n * The bit of an app's session that shared chrome needs to act on.\n *\n * Signing out belongs to the app — it owns the auth client, the grant\n * refresh timer and where to land afterwards — but the control that\n * triggers it belongs to the shell. This token is the seam between them,\n * the same shape as `SCREEN_REF_DATA_SERVICE`.\n *\n * Components inject it optionally and hide their affordance when nothing\n * provides it, so an app that has not opted in shows no dead button.\n *\n * ```ts\n * // app.config.ts\n * { provide: EF_SESSION, useExisting: AuthorizeService }\n * ```\n */\nexport interface EfSession {\n /** End the session and send the user wherever the app decides. */\n logout(): void;\n}\n\nexport const EF_SESSION = new InjectionToken<EfSession>('EF_SESSION');\n","import { InjectionToken } from '@angular/core';\n\n/**\n * Which build of the app is running.\n *\n * Apps generate this at build time — the framework cannot know it — and\n * provide it here so shared chrome can show it without importing anything\n * app-specific. `EfBuildStampComponent` is the intended consumer.\n *\n * ```ts\n * // app.config.ts\n * { provide: EF_BUILD_INFO, useValue: BUILD_INFO }\n * ```\n */\nexport interface EfBuildInfo {\n /** Release version. Empty when the app maintains none — consumers should\n * omit it rather than print a placeholder. */\n version: string;\n\n /** Short commit hash the build came from. */\n commit: string;\n\n /** Commit date as `YYYY-MM-DD` — what a reader actually recognises. */\n date: string;\n\n /** Branch the build came from, useful for telling develop from a release. */\n branch: string;\n\n /**\n * Which deployment this build was made for: `production`, `staging`,\n * `develop`, or `local`. Decided at build time from the ref, because a\n * production build is made from a tag rather than a branch.\n */\n environment: string;\n\n /**\n * The shared `@elasticias/*` packages this build was compiled against,\n * in the order the app wants them listed.\n *\n * Optional: an app that ships no shared packages, or generates its stamp\n * without resolving them, simply omits the key and consumers render\n * nothing rather than an empty group.\n */\n packages?: EfBuildPackage[];\n}\n\n/** One shared package and the version that went into the build. */\nexport interface EfBuildPackage {\n /** Package name as it appears in `package.json`, e.g. `@elasticias/ui`. */\n name: string;\n\n /** The version actually installed, not the range the app declared. */\n version: string;\n}\n\nexport const EF_BUILD_INFO = new InjectionToken<EfBuildInfo>('EF_BUILD_INFO');\n","import { HttpBackend, HttpClient } from '@angular/common/http';\nimport { inject, InjectionToken, Provider } from '@angular/core';\nimport { TranslateLoader, TranslationObject } from '@ngx-translate/core';\nimport { Observable } from 'rxjs';\nimport { EF_BUILD_INFO } from '../build/ef-build-info.token';\n\n/**\n * Where the translation files live, and how their URL is stamped.\n */\nexport interface EfVersionedTranslateLoaderConfig {\n /** Path the language file sits under. Defaults to `/assets/i18n/`. */\n prefix?: string;\n\n /** File extension. Defaults to `.json`. */\n suffix?: string;\n\n /**\n * Build identifier appended as `?v=`. Defaults to `EF_BUILD_INFO.commit`,\n * which the app already regenerates on every build, so a release changes\n * every translation URL without anyone maintaining a second number.\n */\n version?: string;\n\n /**\n * Bypass the HTTP interceptor chain. On by default: a translation file is\n * a static asset, and putting it through the app's auth interceptor means\n * a 401 handler can fire before the app knows how to say anything.\n */\n useHttpBackend?: boolean;\n}\n\nexport const EF_TRANSLATE_LOADER_CONFIG = new InjectionToken<EfVersionedTranslateLoaderConfig>(\n 'EF_TRANSLATE_LOADER_CONFIG',\n);\n\n/**\n * Translation loader that puts the build id in the URL.\n *\n * Angular content-hashes its JS and CSS but copies `/assets` verbatim, so a\n * translation file ships new content at a URL that never changes — the one\n * case HTTP caching handles worst. Two things follow from that.\n *\n * The first is ordinary staleness: a device holding yesterday's copy has no\n * reason to ask for today's, so a newly added key renders as its raw key.\n *\n * The second is worse and is why this exists rather than a cache header. A\n * device that cached the file while the server was still sending\n * `max-age=31536000, immutable` will not re-request it for up to a year, and\n * therefore never sees whatever header we send next. Headers only reach\n * browsers that ask. A URL they have never seen has no cache entry at all, so\n * changing the URL is the only thing that reaches them.\n *\n * Stamping the build id also means the URL is stable *within* a release, so\n * the file can go back to being cached hard instead of revalidated on every\n * single page load.\n */\nexport class EfVersionedTranslateLoader implements TranslateLoader {\n private readonly cfg = inject(EF_TRANSLATE_LOADER_CONFIG, { optional: true }) ?? {};\n private readonly buildInfo = inject(EF_BUILD_INFO, { optional: true });\n\n /**\n * Built from `HttpBackend` rather than injecting `HttpClient`, so the\n * request skips interceptors. See `useHttpBackend`.\n */\n private readonly http =\n this.cfg.useHttpBackend === false\n ? inject(HttpClient)\n : new HttpClient(inject(HttpBackend));\n\n getTranslation(lang: string): Observable<TranslationObject> {\n const prefix = this.cfg.prefix ?? '/assets/i18n/';\n const suffix = this.cfg.suffix ?? '.json';\n const version = this.cfg.version ?? this.buildInfo?.commit ?? '';\n\n // No build id (a bare `ng serve`, or an app that ships no stamp) means\n // no query string at all, rather than `?v=` — a URL that changes shape\n // between environments is harder to reason about than one that doesn't.\n const url = `${prefix}${lang}${suffix}${version ? `?v=${encodeURIComponent(version)}` : ''}`;\n return this.http.get<TranslationObject>(url);\n }\n}\n\n/**\n * Provide the versioned loader in place of `provideTranslateHttpLoader`.\n *\n * ```ts\n * provideTranslateService({ fallbackLang: 'fr', lang }),\n * provideEfTranslateLoader({ prefix: '/assets/i18n/' }),\n * ```\n *\n * Pair it with a long-lived cache header on the translation files: the URL now\n * carries the release, so there is nothing left to revalidate against.\n */\nexport function provideEfTranslateLoader(\n config: EfVersionedTranslateLoaderConfig = {},\n): Provider[] {\n return [\n { provide: EF_TRANSLATE_LOADER_CONFIG, useValue: config },\n { provide: TranslateLoader, useClass: EfVersionedTranslateLoader },\n ];\n}\n","/**\n * Key-combo parsing shared by `EfShortcutService` (matching a keydown event\n * against the registry) and `formatShortcut` (rendering a registration for\n * display). Kept internal to the shortcuts folder: neither export is part\n * of the public `@elasticias/core` surface.\n */\n\n/** Fixed order modifiers are stored and compared in, so `'shift+mod+x'`\n * and `'mod+shift+x'` normalise to the same string. */\nconst MODIFIER_ORDER = ['mod', 'shift', 'alt'] as const;\n\n/**\n * Physical-key `KeyboardEvent.code` values mapped to the token used in a\n * `keys` string. `code` identifies the physical key regardless of what\n * Shift makes it print, which is what lets `'shift+/'` match the key next\n * to Right Shift on a US layout even though pressing it actually produces\n * `'?'`.\n */\nconst CODE_KEYS: Record<string, string> = {\n Enter: 'enter',\n Escape: 'escape',\n Space: 'space',\n Backspace: 'backspace',\n Tab: 'tab',\n Slash: '/',\n};\n\n/** Normalises a `keys` registration string into a canonical, comparable\n * form: lowercase tokens, modifiers first in a fixed order. */\nexport function normaliseKeys(raw: string): string {\n const tokens = raw\n .toLowerCase()\n .split('+')\n .map(token => token.trim())\n .filter(Boolean);\n const modifierTokens = MODIFIER_ORDER.filter(modifier => tokens.includes(modifier));\n const rest = tokens.filter(token => !(MODIFIER_ORDER as readonly string[]).includes(token));\n return [...modifierTokens, ...rest].join('+');\n}\n\ninterface KeyEventLike {\n code: string;\n key: string;\n metaKey: boolean;\n ctrlKey: boolean;\n shiftKey: boolean;\n altKey: boolean;\n}\n\n/** The canonical key token for an event, independent of Shift. `KeyD`\n * is `'d'` whether or not Shift was held. */\nfunction keyToken(event: KeyEventLike): string {\n if (CODE_KEYS[event.code]) return CODE_KEYS[event.code];\n if (event.code?.startsWith('Key')) return event.code.slice(3).toLowerCase();\n if (event.code?.startsWith('Digit')) return event.code.slice(5);\n return event.key.toLowerCase();\n}\n\n/**\n * Builds the normalised combo a keydown event represents, e.g. `'mod+d'`.\n * `isMac` decides which physical modifier counts as `mod`: Meta on macOS,\n * Control everywhere else.\n */\nexport function comboFromEvent(event: KeyEventLike, isMac: boolean): string {\n const tokens: string[] = [];\n if (isMac ? event.metaKey : event.ctrlKey) tokens.push('mod');\n if (event.shiftKey) tokens.push('shift');\n if (event.altKey) tokens.push('alt');\n tokens.push(keyToken(event));\n return normaliseKeys(tokens.join('+'));\n}\n\n/**\n * True while the event target is a place the user is typing: an input, a\n * textarea, a select, or anything `contenteditable`. The dispatcher checks\n * this before anything else. Without it every shortcut key is a reserved\n * word in every text field in the app.\n */\nexport function isTypingTarget(target: EventTarget | null): boolean {\n if (!(target instanceof HTMLElement)) return false;\n const tag = target.tagName;\n if (tag === 'INPUT' || tag === 'TEXTAREA' || tag === 'SELECT') return true;\n return target.isContentEditable;\n}\n","import { normaliseKeys } from './shortcut-keys';\n\n/** Reads the platform once. `userAgentData` is the current standard; the\n * `platform` string fallback covers browsers that don't expose it yet.\n *\n * The test is \"Apple\", not \"Mac\". An iPhone reports `iPhone` and an iPad\n * reports either `iPad` or, since iPadOS 13, the same `MacIntel` a desktop\n * does. A narrower `/mac/i` told every iOS device with a keyboard that the\n * modifier was Ctrl, which is the one thing it is not. */\nfunction detectApplePlatform(): boolean {\n if (typeof navigator === 'undefined') return false;\n const uaData = (navigator as Navigator & { userAgentData?: { platform?: string } })\n .userAgentData;\n const platform = uaData?.platform ?? navigator.platform ?? '';\n return /mac|iphone|ipad|ipod/i.test(platform);\n}\n\n/**\n * Detected once, at module load. `formatShortcut` uses it to choose between\n * the Command glyphs and the Ctrl words. True for every Apple platform, not\n * just the desktop: an iPad with a keyboard sends Command like a Mac does.\n */\nexport const isMacPlatform: boolean = detectApplePlatform();\n\nconst MAC_MODIFIER_GLYPHS: Record<string, string> = {\n mod: '⌘',\n shift: '⇧',\n alt: '⌥',\n};\n\nconst OTHER_MODIFIER_WORDS: Record<string, string> = {\n mod: 'Ctrl',\n shift: 'Shift',\n alt: 'Alt',\n};\n\n/** Named keys with a glyph of their own, distinct from their letter. */\nconst KEY_GLYPHS: Record<string, string> = {\n enter: '↵',\n escape: 'Esc',\n backspace: '⌫',\n space: 'Space',\n tab: 'Tab',\n};\n\n/**\n * A produced character that stands in for the whole combo. Shift plus the\n * physical `/` key always reads as the question mark it prints. Showing\n * it as `'Shift' + '/'` would describe the keys pressed rather than the\n * shortcut a person recognises.\n */\nconst SHIFTED_SYMBOL_GLYPHS: Record<string, string> = {\n '/': '?',\n};\n\n/**\n * Formats a `keys` registration for display. One registration, correct on\n * both platforms:\n *\n * - `'mod+d'` → `⌘D` on macOS, `Ctrl+D` elsewhere\n * - `'enter'` → `↵`\n * - `'e'` → `E`\n * - `'shift+/'` → `?`\n *\n * `mac` defaults to the platform this code is actually running on. Pass it\n * explicitly only to render for a platform other than the current one.\n */\nexport function formatShortcut(keys: string, mac: boolean = isMacPlatform): string {\n const tokens = normaliseKeys(keys).split('+');\n const key = tokens[tokens.length - 1];\n const modifiers = tokens.slice(0, -1);\n\n if (modifiers.length === 1 && modifiers[0] === 'shift' && SHIFTED_SYMBOL_GLYPHS[key]) {\n return SHIFTED_SYMBOL_GLYPHS[key];\n }\n\n const displayKey = KEY_GLYPHS[key] ?? key.toUpperCase();\n\n if (mac) {\n return modifiers.map(modifier => MAC_MODIFIER_GLYPHS[modifier] ?? modifier).join('') + displayKey;\n }\n\n const words = modifiers.map(modifier => OTHER_MODIFIER_WORDS[modifier] ?? modifier);\n return [...words, displayKey].join('+');\n}\n","import { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { computed, DestroyRef, inject, Injectable, PLATFORM_ID, signal } from '@angular/core';\nimport { isMacPlatform } from './format-shortcut';\nimport { comboFromEvent, isTypingTarget, normaliseKeys } from './shortcut-keys';\nimport { EfShortcut, EfShortcutGroup } from './ef-shortcut.types';\n\n/**\n * App-wide keyboard-shortcut registry, plus the single `document:keydown`\n * dispatcher that acts on it.\n *\n * ```ts\n * private readonly shortcuts = inject(EfShortcutService);\n *\n * constructor() {\n * // Auto-unregisters on this component's DestroyRef, called from a\n * // constructor / field initializer, an active injection context.\n * this.shortcuts.register({\n * id: 'sales-order.save',\n * keys: 'mod+s',\n * labelKey: 'sales_order_save',\n * group: 'shortcut_group_sales_order',\n * handler: () => this.save(),\n * });\n * }\n * ```\n *\n * Two things make this safe to leave switched on everywhere:\n * - The dispatcher ignores keydown while the target is an input, textarea,\n * select, or anything `contenteditable`, unless the combo includes\n * `mod`. A bare key or a Shift/Alt combo could be real typing (Alt and\n * AltGr both produce characters on several layouts this app ships), but\n * `mod` never does, and a save/search shortcut is normally pressed from\n * inside the very field it acts on. See `isTypingTarget`.\n * - `preventDefault` is only called once a registration actually matches,\n * so an unmapped key never loses its browser default.\n *\n * `list()` exposes the registry grouped for `ef-shortcuts-dialog`, as a\n * signal so the dialog reflects registrations and disposals live.\n */\n@Injectable({ providedIn: 'root' })\nexport class EfShortcutService {\n private readonly document = inject(DOCUMENT);\n private readonly platformId = inject(PLATFORM_ID);\n private readonly destroyRef = inject(DestroyRef);\n\n private readonly registry = signal<ReadonlyMap<string, EfShortcut>>(new Map());\n\n /**\n * The registry, grouped for display and deduplicated by\n * (group, label, keys): several instances of the same conceptual\n * shortcut (one row-actions component per row, say) collapse to a\n * single line rather than repeating once per instance.\n */\n readonly list = computed<EfShortcutGroup[]>(() => {\n const deduped = new Map<string, EfShortcut>();\n for (const shortcut of this.registry().values()) {\n const key = `${shortcut.group}::${shortcut.labelKey}::${shortcut.keys}`;\n if (!deduped.has(key)) deduped.set(key, shortcut);\n }\n\n const byGroup = new Map<string, EfShortcut[]>();\n for (const shortcut of deduped.values()) {\n const group = byGroup.get(shortcut.group) ?? [];\n group.push(shortcut);\n byGroup.set(shortcut.group, group);\n }\n\n return Array.from(byGroup.entries()).map(([group, shortcuts]) => ({ group, shortcuts }));\n });\n\n constructor() {\n if (!isPlatformBrowser(this.platformId)) return;\n this.document.addEventListener('keydown', this.onKeydown);\n this.destroyRef.onDestroy(() => this.document.removeEventListener('keydown', this.onKeydown));\n }\n\n /**\n * Registers a shortcut and returns a disposer. When `register` is\n * called from an active injection context (a component constructor or\n * field initializer), the shortcut also auto-unregisters when that\n * context is destroyed. Call it explicitly elsewhere (a plain method,\n * a route resolver already outside construction) and dispose it\n * yourself.\n */\n register(shortcut: EfShortcut): () => void {\n const entry: EfShortcut = { ...shortcut, keys: normaliseKeys(shortcut.keys) };\n\n this.registry.update(map => {\n const next = new Map(map);\n next.set(entry.id, entry);\n return next;\n });\n\n const dispose = (): void => this.unregister(entry.id);\n this.tryGetCallerDestroyRef()?.onDestroy(dispose);\n return dispose;\n }\n\n /** Removes a registration by id. Safe to call twice: the disposer\n * returned by `register` calls this. */\n unregister(id: string): void {\n this.registry.update(map => {\n if (!map.has(id)) return map;\n const next = new Map(map);\n next.delete(id);\n return next;\n });\n }\n\n /** `inject()` throws outside an active injection context; that is how\n * a call from a plain method (as opposed to a constructor) is told\n * apart from one worth auto-disposing. */\n private tryGetCallerDestroyRef(): DestroyRef | null {\n try {\n return inject(DestroyRef, { optional: true });\n } catch {\n return null;\n }\n }\n\n private readonly onKeydown = (event: KeyboardEvent): void => {\n const combo = comboFromEvent(event, isMacPlatform);\n\n // A bare key, or one held with only Shift or Alt, is something the\n // user could plausibly be typing (Alt/AltGr produces real\n // characters on several layouts this app ships, French and\n // Moroccan included), so those stay inert in a field. `mod` never\n // types a character: Ctrl+S saves from inside a form field in\n // every application there is, and a form field is the only place\n // a save shortcut is ever actually pressed from.\n const isModCombo = combo.split('+').includes('mod');\n if (!isModCombo && isTypingTarget(event.target)) return;\n\n for (const shortcut of this.registry().values()) {\n if (shortcut.keys !== combo) continue;\n if (shortcut.when && !shortcut.when()) continue;\n event.preventDefault();\n shortcut.handler();\n return;\n }\n };\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;MAIa,aAAa,CAAA;AAChB,IAAA,cAAc,GAAG,IAAI,eAAe,CAAU,KAAK,CAAC;AAC5D,IAAA,UAAU,GAAG,IAAI,CAAC,cAAc,CAAC,YAAY,EAAE;IAE/C,IAAI,GAAA;AACF,QAAA,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC;IAChC;IAEA,IAAI,GAAA;AACF,QAAA,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,KAAK,CAAC;IACjC;wGAVW,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA;AAAb,IAAA,OAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,aAAa,cADA,MAAM,EAAA,CAAA;;4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,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE;;;ACvClC;;AAEG;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elasticias/core",
3
- "version": "1.0.27",
3
+ "version": "1.0.29",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^21.0.0",
6
6
  "@angular/core": "^21.0.0",
@@ -128,9 +128,92 @@ declare class EfToastService {
128
128
  static ɵprov: i0.ɵɵInjectableDeclaration<EfToastService>;
129
129
  }
130
130
 
131
+ /** What the user is being asked to approve. Drives the copy, the icon
132
+ * and the weight of the accept button. */
133
+ type EfConfirmIntent = 'generic' | 'delete';
134
+ /**
135
+ * Options accepted by `ConfirmDialogService.confirm()`.
136
+ *
137
+ * Every piece of text is a translation key, per the framework's i18n
138
+ * convention — the service resolves them through `TranslateService` so
139
+ * the dialog speaks the user's language rather than the author's. The
140
+ * literal `message` / `header` escape hatches exist for text that is
141
+ * already translated (a server message, say); a key always wins.
142
+ */
143
+ interface EfConfirmOptions {
144
+ /** Kind of confirmation — `'delete'` supplies destructive defaults. */
145
+ intent?: EfConfirmIntent;
146
+ /**
147
+ * Name of the thing being acted on, so the dialog can say *what* it
148
+ * is about to destroy: "Delete client ANDALOCY PARFUMS?" rather than
149
+ * "Delete?". Omit it and the generic message is used instead.
150
+ */
151
+ name?: string | null;
152
+ /** Translation key for the message — preferred over `message`. */
153
+ messageKey?: string;
154
+ /** Already-translated message. Used when `messageKey` is empty. */
155
+ message?: string;
156
+ /** Extra interpolation params for `messageKey` (`name` is added). */
157
+ messageParams?: Record<string, unknown>;
158
+ /** Translation key for the dialog title. */
159
+ headerKey?: string;
160
+ /** Already-translated dialog title. */
161
+ header?: string;
162
+ /** Translation key for the accept button label. */
163
+ acceptLabelKey?: string;
164
+ /** Translation key for the reject button label. */
165
+ rejectLabelKey?: string;
166
+ /** PrimeNG icon class shown in the body tile. */
167
+ icon?: string;
168
+ /** Run when the user accepts. */
169
+ accept?: () => void;
170
+ /** Run when the user cancels or dismisses. */
171
+ reject?: () => void;
172
+ /** Originating event, so PrimeNG can anchor the dialog. */
173
+ event?: Event;
174
+ }
175
+ /**
176
+ * The app-wide confirmation modal, driven through PrimeNG's
177
+ * `ConfirmationService` and rendered by `<ef-confirm-dialog>`.
178
+ *
179
+ * Two call shapes:
180
+ *
181
+ * ```ts
182
+ * // Options — the one to reach for.
183
+ * confirmDialogService.confirm({
184
+ * intent: 'delete',
185
+ * name: client.name, // "Delete ANDALOCY PARFUMS?"
186
+ * accept: () => this.remove(),
187
+ * });
188
+ *
189
+ * // Legacy positional form, kept so existing callers keep compiling.
190
+ * confirmDialogService.confirm('Already-translated question?', onYes, onNo);
191
+ * ```
192
+ */
131
193
  declare class ConfirmDialogService {
132
194
  private readonly confirmationService;
195
+ /**
196
+ * Lazy holder. Resolving `TranslateService` at construction time pulls
197
+ * in HttpClient and, through the interceptor chain, services that
198
+ * inject this one — the same cycle `EfToastService` documents. Defer
199
+ * to the first actual `confirm()` call, which is always well after
200
+ * bootstrap.
201
+ */
202
+ private readonly injector;
203
+ private _translate?;
204
+ confirm(options: EfConfirmOptions): void;
205
+ /** @deprecated Pass `EfConfirmOptions` — a literal message cannot be translated. */
133
206
  confirm(message: string, acceptCallback?: () => void, rejectCallback?: () => void, event?: Event): void;
207
+ /**
208
+ * Sugar for `confirm({ intent: 'delete', ... })`.
209
+ *
210
+ * ```ts
211
+ * confirmDialogService.confirmDelete({ name: row.label, accept: () => … });
212
+ * ```
213
+ */
214
+ confirmDelete(options?: Omit<EfConfirmOptions, 'intent'>): void;
215
+ private resolveMessage;
216
+ private t;
134
217
  static ɵfac: i0.ɵɵFactoryDeclaration<ConfirmDialogService, never>;
135
218
  static ɵprov: i0.ɵɵInjectableDeclaration<ConfirmDialogService>;
136
219
  }
@@ -770,4 +853,4 @@ declare const isMacPlatform: boolean;
770
853
  declare function formatShortcut(keys: string, mac?: boolean): string;
771
854
 
772
855
  export { CacheService, ConfirmDialogService, DEFAULT_APP_STATE, EF_BUILD_INFO, EF_MODULES, EF_MODULES_TOKEN, EF_SESSION, EF_TRANSLATE_LOADER_CONFIG, EfActiveModuleService, EfComptoirTheme, EfPermissionService, EfShortcutService, EfTheme, EfThemeConfigService, EfToastService, EfVersionedTranslateLoader, EfViewportService, LoaderService, PRIMENG_AR_LOCALE, PRIMENG_EN_LOCALE, PRIMENG_FR_LOCALE, EfToastService as ToastService, formatShortcut, hasScreenPermission, isMacPlatform, provideEfTranslateLoader, screenGuard };
773
- export type { AppState, EfBuildInfo, EfBuildPackage, EfModule, EfModuleId, EfModulePermission, EfNavAction, EfNavItem, EfNavSection, EfPermissionLevel, EfSession, EfShortcut, EfShortcutGroup, EfToast, EfToastAction, EfToastOptions, EfToastSeverity, EfVersionedTranslateLoaderConfig, EfViewport, ScreenGuardConfig };
856
+ export type { AppState, EfBuildInfo, EfBuildPackage, EfConfirmIntent, EfConfirmOptions, EfModule, EfModuleId, EfModulePermission, EfNavAction, EfNavItem, EfNavSection, EfPermissionLevel, EfSession, EfShortcut, EfShortcutGroup, EfToast, EfToastAction, EfToastOptions, EfToastSeverity, EfVersionedTranslateLoaderConfig, EfViewport, ScreenGuardConfig };