valtech-components 2.0.1002 → 2.0.1004

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.
@@ -4,6 +4,8 @@ import { PreferencesViewConfig } from '../preferences-view/types';
4
4
  import { SecurityViewConfig } from '../security-view/types';
5
5
  import { AccountViewConfig } from '../account-view/types';
6
6
  import { OrganizationViewConfig } from '../organization-view/types';
7
+ import { NotificationPreferencesViewConfig } from '../notification-preferences-view/types';
8
+ import { PermissionsViewConfig } from '../permissions-view/types';
7
9
  import { SettingsHubConfig } from './types';
8
10
  /**
9
11
  * Opciones de `provideValtechSettingsRoutes`. Agrupa el HUB (`val-settings-hub`)
@@ -14,6 +16,18 @@ import { SettingsHubConfig } from './types';
14
16
  export interface ValtechSettingsRoutesOptions {
15
17
  /** Path base del bloque de settings. Default `'settings'`. */
16
18
  basePath?: string;
19
+ /**
20
+ * Path donde se monta el HUB dentro del bloque. Default `''` (índice). Para
21
+ * apps que quieren el hub en una sub-ruta (ej. showcase lo tiene en
22
+ * `preferences`), setear esto + `indexRedirectTo`.
23
+ */
24
+ hubPath?: string;
25
+ /**
26
+ * Si se setea, agrega `{ path: '', redirectTo, pathMatch: 'full' }` al índice.
27
+ * Pensado para cuando `hubPath` NO es `''` (el índice queda libre y se redirige
28
+ * al hub u otra sección). No usar junto con `hubPath: ''` (colisionarían).
29
+ */
30
+ indexRedirectTo?: string;
17
31
  /** Config del HUB (pasada por route data `settingsHubConfig`). */
18
32
  hubConfig?: SettingsHubConfig;
19
33
  /** Config de la vista Perfil (pass-through a `provideValtechProfileRoutes`). */
@@ -26,6 +40,10 @@ export interface ValtechSettingsRoutesOptions {
26
40
  accountConfig?: AccountViewConfig;
27
41
  /** Config de la vista Gestión de organización (pass-through a `provideValtechOrganizationRoutes`). */
28
42
  organizationConfig?: OrganizationViewConfig;
43
+ /** Config de Preferencias de notificaciones push (pass-through). */
44
+ notificationPreferencesConfig?: NotificationPreferencesViewConfig;
45
+ /** Config del visor de Permisos (pass-through). */
46
+ permissionsConfig?: PermissionsViewConfig;
29
47
  /** Monta la ruta `profile`. Default `true`. */
30
48
  includeProfile?: boolean;
31
49
  /** Monta la ruta de preferencias. Default `true`. */
@@ -36,20 +54,27 @@ export interface ValtechSettingsRoutesOptions {
36
54
  includeAccount?: boolean;
37
55
  /** Monta la ruta `organization`. Default `true`. */
38
56
  includeOrganization?: boolean;
57
+ /** Monta la ruta de preferencias de notificaciones push. Default `true`. */
58
+ includeNotificationPreferences?: boolean;
59
+ /** Monta la ruta `permissions`. Default `true`. */
60
+ includePermissions?: boolean;
39
61
  /** Path de la vista Preferencias. Default `'preferences'`. */
40
62
  preferencesPath?: string;
63
+ /** Path de la vista Preferencias de notificaciones push. Default `'notifications'`. */
64
+ notificationPreferencesPath?: string;
41
65
  /** Rutas extra a sumar como hijas (secciones de la app no promovidas). */
42
66
  extraRoutes?: Routes;
43
67
  }
44
68
  /**
45
69
  * Helper para montar el bloque completo de Settings en una app del factory: el
46
- * HUB de navegación (`val-settings-hub`) en el index + las vistas promovidas
47
- * (Perfil, Preferencias) + las rutas propias de la app (`extraRoutes`).
70
+ * HUB de navegación (`val-settings-hub`) + TODAS las vistas promovidas (Perfil,
71
+ * Preferencias, Seguridad, Cuenta, Gestión org, Preferencias de notificaciones,
72
+ * Permisos) + las rutas propias de la app (`extraRoutes`). Cada `include*` permite
73
+ * apagar una sección; `hubPath`/`indexRedirectTo`/`*Path` permiten reubicar el hub
74
+ * y las vistas para preservar URLs existentes.
48
75
  *
49
- * Pensado para apps nuevas (greenfield) que adoptan el set entero. showcase NO
50
- * lo usa hoy (preserva su `settings.routes.ts` por la semántica de sus muchas
51
- * secciones no promovidas — ver guía de promoción), pero el provider debe
52
- * existir y compilar para el resto de apps.
76
+ * showcase lo consume (ver `settings.routes.ts` de showcase): hub en `preferences`,
77
+ * preferences-view en `general`, index→redirect, `organization/new` por `extraRoutes`.
53
78
  *
54
79
  * @example
55
80
  * ```ts
package/lib/version.d.ts CHANGED
@@ -2,4 +2,4 @@
2
2
  * Current version of valtech-components.
3
3
  * This is automatically updated during the publish process.
4
4
  */
5
- export declare const VERSION = "2.0.1002";
5
+ export declare const VERSION = "2.0.1004";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "valtech-components",
3
- "version": "2.0.1002",
3
+ "version": "2.0.1004",
4
4
  "private": false,
5
5
  "bin": {
6
6
  "valtech-firebase-config": "./src/lib/services/firebase/scripts/generate-sw-config.js"