valtech-components 2.0.1002 → 2.0.1003
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.
- package/esm2022/lib/components/molecules/comment/comment.component.mjs +3 -3
- package/esm2022/lib/components/organisms/permissions-view/permissions-view.component.mjs +6 -9
- package/esm2022/lib/components/organisms/profile-view/profile-view.component.mjs +6 -16
- package/esm2022/lib/components/organisms/settings-hub/settings.routes.mjs +26 -8
- package/esm2022/lib/services/preferences/preferences.service.mjs +19 -4
- package/esm2022/lib/version.mjs +2 -2
- package/fesm2022/valtech-components.mjs +2039 -2021
- package/fesm2022/valtech-components.mjs.map +1 -1
- package/lib/components/organisms/settings-hub/settings.routes.d.ts +31 -6
- package/lib/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -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`)
|
|
47
|
-
*
|
|
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
|
-
*
|
|
50
|
-
*
|
|
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