sass-cms-template-common 0.0.34 → 0.0.36

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/dist/index.d.ts CHANGED
@@ -24,6 +24,9 @@ import { Theme } from '@mui/material/styles';
24
24
  */
25
25
  export declare const ACCOUNT_NAV_BLOCKS: NavBlock[];
26
26
 
27
+ /** Módulo del Authenticator que guarda los pines del menú de cmsmedios. */
28
+ export declare const ADMIN_ANGULAR_MODULE = "admin-angular";
29
+
27
30
  /**
28
31
  * Catálogo de mensajes del gestor por idioma. Cada gestor declara su propio
29
32
  * `en` como fuente de la forma y valida `es`/`pt` con `satisfies typeof enTree`
@@ -43,7 +46,7 @@ export declare type AppMessageNode = string | {
43
46
  /** Árbol de mensajes del gestor (namespaces → claves → string anidable). */
44
47
  export declare type AppMessages = Record<string, AppMessageNode>;
45
48
 
46
- export declare function AppShell({ pathname, sites, children, notificationUnreadCount, notificationsData, copilotSuggestionsHref, onEditorialSeeMore, onEditorialRemindLater, onNotificationsOpen, notificationsLoading, profile, primaryLogo, brandLogo, selectedPublicationId, getPublicationHref, resolvePublicationImageUrl, profileAvatarOptions, legacyBaseUrl, cmsBaseUrl, legacySession, previewFormats, operationPermissions, isAdmin, onPreviewSelect, showAppearanceMenu, LinkComponent, permissions, navHrefOverrides, locale, language, messages, appMessages, baseUrl, profileServices, }: AppShellProps): JSX.Element;
49
+ export declare function AppShell({ pathname, sites, children, notificationUnreadCount, notificationsData, copilotSuggestionsHref, onEditorialSeeMore, onEditorialRemindLater, onNotificationsOpen, notificationsLoading, profile, primaryLogo, brandLogo, selectedPublicationId, getPublicationHref, resolvePublicationImageUrl, profileAvatarOptions, legacyBaseUrl, cmsBaseUrl, legacySession, previewFormats, operationPermissions, isAdmin, onPreviewSelect, showAppearanceMenu, LinkComponent, permissions, navHrefOverrides, locale, language, messages, appMessages, baseUrl, profileServices, sidebarAuthService, }: AppShellProps): JSX.Element;
47
50
 
48
51
  export declare type AppShellProps = {
49
52
  pathname: string;
@@ -111,6 +114,11 @@ export declare type AppShellProps = {
111
114
  * accesos es solo visual y no persiste entre sesiones.
112
115
  */
113
116
  profileServices?: SidebarRailPinService;
117
+ /**
118
+ * Pines y módulos hermanos del Authenticator (como cmsmedios). Si se pasa, el
119
+ * menú lateral lo usa en vez de los pines de `profileServices`.
120
+ */
121
+ sidebarAuthService?: SidebarRailAuthService;
114
122
  };
115
123
 
116
124
  /** Traductor genérico de claves del gestor por ruta con puntos (`ns.clave`). */
@@ -264,6 +272,13 @@ export declare interface AuthPermissionsResponse extends CmsResponse {
264
272
  [key: string]: unknown;
265
273
  }
266
274
 
275
+ /** Identidad del pin en el Authenticator. */
276
+ declare type AuthPinRef = {
277
+ moduleName: string;
278
+ itemKey: string;
279
+ pinned: boolean;
280
+ };
281
+
267
282
  /** Cuerpo de la respuesta de POST /auth/relogin. */
268
283
  export declare interface AuthReloginResponse extends CmsResponse, AuthSessionData {
269
284
  }
@@ -296,6 +311,30 @@ export declare interface AuthSessionResult extends CmsResponse {
296
311
  /** Respuesta de POST /auth/setNewPassword. */
297
312
  export declare type AuthSetNewPasswordResponse = AuthSessionResult;
298
313
 
314
+ /** Ítem de `GET /api/v1/auth/sidebar` (lo que el menú usa). */
315
+ export declare type AuthSidebarItem = {
316
+ itemKey: string;
317
+ translations?: Record<string, string>;
318
+ icon?: string | null;
319
+ href?: string | null;
320
+ pinned?: boolean;
321
+ };
322
+
323
+ export declare type AuthSidebarResponse = {
324
+ sections?: AuthSidebarSection[];
325
+ };
326
+
327
+ /** Módulo (webapp) de `GET /api/v1/auth/sidebar`. */
328
+ export declare type AuthSidebarSection = {
329
+ moduleName: string;
330
+ translations?: Record<string, string>;
331
+ icon?: string | null;
332
+ url?: string | null;
333
+ /** `false` = solo aporta ítems; no es una webapp a la que saltar. */
334
+ sidebarHost?: boolean;
335
+ items?: AuthSidebarItem[];
336
+ };
337
+
299
338
  /** Propiedades comunes a todos los campos de la configuración. */
300
339
  declare type BaseFieldConfig = {
301
340
  /** Identificador único del campo (clave en `FieldValues`). */
@@ -351,6 +390,17 @@ export declare type BtnDropdownProps = {
351
390
  testId?: string;
352
391
  };
353
392
 
393
+ /**
394
+ * Aplica sobre el menú lo mismo que cmsmedios toma del Authenticator:
395
+ * 1. Pines de `admin-angular` (su `itemKey` en mayúsculas = `module` del ítem).
396
+ * Van arriba en el orden de cmsmedios: sección por sección, de atrás hacia
397
+ * adelante (primero los hijos anclados de un ítem con submenú). Salen de su
398
+ * lugar original.
399
+ * 2. Pines de otras apps: también arriba, como links a esa app.
400
+ * 3. Módulos hermanos (`sidebarHost !== false`): al final de la primera sección.
401
+ */
402
+ export declare function buildCmsmediosMenu(groups: NavLinkItem[][], permissions: Array<NavItemPermissions>, sidebar: AuthSidebarResponse | null, locale: string, selectedPublicationId?: string): CmsmediosMenuLayout;
403
+
354
404
  /**
355
405
  * Construye el catálogo estándar de campos de "Búsqueda avanzada" del CMS con
356
406
  * los textos por defecto de la librería (resueltos al idioma activo). Es lo que
@@ -532,6 +582,23 @@ export declare interface ClassifiedNetworkError {
532
582
  */
533
583
  export declare function classifyNetworkError(error: unknown): ClassifiedNetworkError | null;
534
584
 
585
+ /**
586
+ * Menú lateral igual al de cmsmedios y al del gestor de noticias (NAA-5415):
587
+ * copia del `CMS_MENU_CATALOG` de `bluestack-cms-news`
588
+ * (`src/components/sidebar/cmsMenuCatalog.ts`), que a su vez copia el
589
+ * `defaultMenuSections` de `cmsmedios-ux` (`menu.service.ts`). Si cambia allá,
590
+ * se replica acá: entre gestores de React el menú tiene que ser el mismo.
591
+ *
592
+ * Tres secciones separadas por una línea. Dentro de cada una, el orden es el
593
+ * de cmsmedios (alfabético por el texto fijo en español, igual en todos los
594
+ * idiomas) con "Otros" al final de la primera. Ya viene ordenado: el filtro por
595
+ * módulos/permisos solo quita ítems, no reordena.
596
+ *
597
+ * Los ítems de otros gestores React (Noticias, CoPilot, Usuarios) los resuelve
598
+ * cada gestor con `navHrefOverrides`; el href de acá es el de respaldo.
599
+ */
600
+ export declare const CMS_MENU_SECTIONS: NavLinkItem[][];
601
+
535
602
  /**
536
603
  * Contenedor de "Búsqueda avanzada" reutilizable y declarativo. Recibe una lista
537
604
  * de `fields` y los renderiza en una grilla, manejando el estado del formulario
@@ -1154,17 +1221,17 @@ export declare type CmsEmptyStateProps = {
1154
1221
 
1155
1222
  /**
1156
1223
  * Página de error compartida por todos los gestores (mecanismo en la lib).
1157
- * Replica la de cmsmedios: ilustración + título + subtítulo + botón HOME, y en
1158
- * el 404 la línea "Error 404. Copiar detalle." que copia la URL al portapapeles.
1159
- * Los textos salen del i18n de la lib (namespace `errorPage`, es/en/pt), así que
1160
- * ningún gestor los duplica.
1224
+ * Header propio (logo + Apariencia) + ilustración/texto centrados + footer,
1225
+ * con la tarjeta "Detalle del error" copiable (Código, Usuario en el 403,
1226
+ * Dirección y Fecha). Los textos salen del i18n de la lib (namespace
1227
+ * `errorPage`, es/en/pt), así que ningún gestor los duplica.
1161
1228
  */
1162
- export declare function CmsErrorPage({ variant, homeHref, LinkComponent, illustrationSrc, }: CmsErrorPageProps): JSX.Element;
1229
+ export declare function CmsErrorPage({ variant, homeHref, LinkComponent, illustrationSrc, logo, userEmail, changeAccountHref, supportEmail, }: CmsErrorPageProps): JSX.Element;
1163
1230
 
1164
1231
  export declare type CmsErrorPageProps = {
1165
1232
  /** Tipo de error a mostrar. */
1166
1233
  variant: CmsErrorPageVariant;
1167
- /** Destino del botón HOME. Por defecto la raíz del gestor (`/`). */
1234
+ /** Destino del botón "Ir al gestor". Por defecto la raíz del gestor (`/`). */
1168
1235
  homeHref?: string;
1169
1236
  /** Componente de enlace del host (p. ej. `next/link`). Por defecto un `<a>`. */
1170
1237
  LinkComponent?: CmsLinkComponent;
@@ -1173,6 +1240,18 @@ export declare type CmsErrorPageProps = {
1173
1240
  * `/errors/notfound.png` o `/errors/not-allowed.png` según la variante.
1174
1241
  */
1175
1242
  illustrationSrc?: string;
1243
+ /** Logo de marca del gestor, mostrado en el header propio de la página. */
1244
+ logo?: ReactNode;
1245
+ /**
1246
+ * Email del usuario logueado. Solo se usa en `variant="not-allowed"`: alimenta
1247
+ * la fila "Usuario" de la tarjeta de detalle y el pie "Sesión iniciada como…".
1248
+ * Sin este dato esas dos piezas no se muestran.
1249
+ */
1250
+ userEmail?: string;
1251
+ /** Destino de "Cambiar de cuenta" (403). Por defecto `/logout`. */
1252
+ changeAccountHref?: string;
1253
+ /** Email de soporte para el hint del 404. Por defecto `soporte@bluestack.la`. */
1254
+ supportEmail?: string;
1176
1255
  };
1177
1256
 
1178
1257
  /** Variante de error a mostrar: 404 (no encontrado) o sin permisos. */
@@ -1380,6 +1459,13 @@ export declare type CmsLinkProps = AnchorHTMLAttributes<HTMLAnchorElement> & {
1380
1459
  children?: ReactNode;
1381
1460
  };
1382
1461
 
1462
+ /** Menú ya resuelto: anclados arriba, secciones y la identidad de pin de cada ítem. */
1463
+ declare type CmsmediosMenuLayout = {
1464
+ pinned: NavLinkItem[];
1465
+ groups: NavLinkItem[][];
1466
+ pinRefs: Map<NavLinkItem, AuthPinRef>;
1467
+ };
1468
+
1383
1469
  /** Message tree shape; values are strings, keys are inferred from `enMessages`. */
1384
1470
  export declare type CmsMessages = DeepStringMap<typeof enMessages>;
1385
1471
 
@@ -3413,29 +3499,29 @@ export declare const enMessages: {
3413
3499
  readonly COMMENTS: "Comments";
3414
3500
  readonly POLLS: "Polls";
3415
3501
  readonly MEDIA: "Media";
3416
- readonly AUDIOS: "Audio";
3502
+ readonly AUDIOS: "Audios";
3417
3503
  readonly IMAGES: "Images";
3418
3504
  readonly PLAYLISTS: "Playlist";
3419
3505
  readonly VIDEOS: "Videos";
3420
- readonly NEWS: "News";
3506
+ readonly NEWS: "Posts";
3421
3507
  readonly PLANNING: "Planning";
3422
3508
  readonly ANALYTICS: "Analytics";
3423
3509
  readonly TAGS: "Tags";
3424
- readonly TRIVIAS: "Trivia";
3425
- readonly OTHERS: "Other";
3510
+ readonly TRIVIAS: "Trivias";
3511
+ readonly OTHERS: "Others";
3426
3512
  readonly NEWSWIRES: "News Wires";
3427
3513
  readonly EVENTS: "Events";
3428
- readonly PAGES: "Pages";
3514
+ readonly PAGES: "Explorer";
3429
3515
  readonly FEEDS: "Feed";
3430
3516
  readonly PERSONS: "People";
3431
3517
  readonly CONTRIBUTIONS: "Contributions";
3432
3518
  readonly RECIPES: "Recipes";
3433
- readonly POSTS: "Posts";
3519
+ readonly POSTS: "UGC";
3434
3520
  readonly BANNERS: "Banners";
3435
3521
  readonly BLOCKS: "Blocks";
3436
3522
  readonly MENUS: "Menu";
3437
- readonly TOPICS: "Topics";
3438
- readonly ADVANCEDQUERYS: "Advanced search";
3523
+ readonly TOPICS: "Themes";
3524
+ readonly ADVANCEDQUERYS: "Search";
3439
3525
  readonly IMPORTS: "Imports";
3440
3526
  readonly NEWSLETTERS: "Newsletters";
3441
3527
  readonly NOTIFICATIONS: "Notifications";
@@ -3448,6 +3534,12 @@ export declare const enMessages: {
3448
3534
  readonly COPILOT: "CoPilot";
3449
3535
  readonly ZONES: "Zones";
3450
3536
  readonly IA: "IA";
3537
+ readonly PRODUCTION: "Production";
3538
+ readonly FREQUENCY: "Frequency";
3539
+ readonly VODS: "Videos OnDemand";
3540
+ readonly SUBSCRIPTIONS: "Subscriptions";
3541
+ readonly MYPLAN: "Production";
3542
+ readonly USERS_MANAGER: "Users";
3451
3543
  };
3452
3544
  readonly sidebar: {
3453
3545
  readonly navAriaLabel: "Main navigation";
@@ -3611,7 +3703,7 @@ export declare const enMessages: {
3611
3703
  readonly defaultInfo: "Information";
3612
3704
  };
3613
3705
  readonly network: {
3614
- readonly disconnected: "No connection. Check your network or Wi-Fi status. We will retry when the connection is restored.";
3706
+ readonly disconnected: "No connection.\nPlease check your Internet connection status.\nThe system will automatically retry pending actions once the connection is restored.";
3615
3707
  readonly retrying: "Retrying requests.";
3616
3708
  };
3617
3709
  readonly userAvatar: {
@@ -3619,16 +3711,28 @@ export declare const enMessages: {
3619
3711
  readonly unknownUser: "Unknown user";
3620
3712
  };
3621
3713
  readonly errorPage: {
3622
- readonly homeButton: "Home";
3623
- readonly notFoundTitle: "Sorry an error occurred.";
3624
- readonly notFoundSubtitle: "This website is no longer available. Keep browsing!";
3714
+ readonly homeButton: "Go to manager";
3715
+ readonly notFoundTitle: "We couldn't find this page";
3716
+ readonly notFoundSubtitle: "This content may have been moved, unpublished, or the link may be mistyped.";
3625
3717
  readonly notFoundCode: "404";
3718
+ readonly notFoundCodeLabel: "404 — Page not found";
3626
3719
  readonly errorLabel: "Error";
3627
- readonly copyDetail: "Copy detail.";
3628
- readonly copyDetailText: "The route {url} you are trying to access is no longer available.";
3629
- readonly copied: "Text copied to clipboard!";
3630
- readonly notAllowedTitle: "Sorry.\nYou do not have access.";
3631
- readonly notAllowedSubtitle: "What you want to see is restricted by permissions. Keep browsing!";
3720
+ readonly notAllowedTitle: "You don't have permission to access this";
3721
+ readonly notAllowedSubtitle: "Your account does not have the permissions needed to view this page. If you think this is a mistake, request access from the site administrator.";
3722
+ readonly notAllowedCode: "403";
3723
+ readonly notAllowedCodeLabel: "403 — Access denied";
3724
+ readonly detailTitle: "Error detail";
3725
+ readonly detailFieldCode: "Code";
3726
+ readonly detailFieldAddress: "Address";
3727
+ readonly detailFieldUser: "User";
3728
+ readonly detailFieldDate: "Date";
3729
+ readonly copyDetail: "Copy";
3730
+ readonly copied: "Copied";
3731
+ readonly helpHintPrefix: "Need help? Copy the detail and write to";
3732
+ readonly loggedInAsPrefix: "Signed in as";
3733
+ readonly changeAccount: "Change account";
3734
+ readonly footerBrand: "Bluestack CMS";
3735
+ readonly footerCodeLabel: "Error code";
3632
3736
  };
3633
3737
  };
3634
3738
 
@@ -3674,6 +3778,12 @@ export declare const esMessages: {
3674
3778
  COPILOT: string;
3675
3779
  ZONES: string;
3676
3780
  IA: string;
3781
+ PRODUCTION: string;
3782
+ FREQUENCY: string;
3783
+ VODS: string;
3784
+ SUBSCRIPTIONS: string;
3785
+ MYPLAN: string;
3786
+ USERS_MANAGER: string;
3677
3787
  };
3678
3788
  sidebar: {
3679
3789
  navAriaLabel: string;
@@ -3849,12 +3959,24 @@ export declare const esMessages: {
3849
3959
  notFoundTitle: string;
3850
3960
  notFoundSubtitle: string;
3851
3961
  notFoundCode: string;
3962
+ notFoundCodeLabel: string;
3852
3963
  errorLabel: string;
3853
- copyDetail: string;
3854
- copyDetailText: string;
3855
- copied: string;
3856
3964
  notAllowedTitle: string;
3857
3965
  notAllowedSubtitle: string;
3966
+ notAllowedCode: string;
3967
+ notAllowedCodeLabel: string;
3968
+ detailTitle: string;
3969
+ detailFieldCode: string;
3970
+ detailFieldAddress: string;
3971
+ detailFieldUser: string;
3972
+ detailFieldDate: string;
3973
+ copyDetail: string;
3974
+ copied: string;
3975
+ helpHintPrefix: string;
3976
+ loggedInAsPrefix: string;
3977
+ changeAccount: string;
3978
+ footerBrand: string;
3979
+ footerCodeLabel: string;
3858
3980
  };
3859
3981
  };
3860
3982
 
@@ -4157,7 +4279,7 @@ export declare function findPublicationLabel(sites: SiteSection[], publicationId
4157
4279
  * que la carga vive en `theme/fonts.ts` y se inyecta vía el provider MUI.
4158
4280
  */
4159
4281
  export declare const fontFamilies: {
4160
- readonly googleSans: "\"Google Sans\",\"Helvetica\",\"Arial\",sans-serif";
4282
+ readonly googleSans: "\"Google Sans\",\"Roboto\",\"Helvetica\",\"Arial\",sans-serif";
4161
4283
  /** Monoespaciada (url del toast de error, fragmentos de código). No es de marca. */
4162
4284
  readonly mono: "ui-monospace, SFMono-Regular, Menlo, Consolas, monospace";
4163
4285
  };
@@ -4194,6 +4316,13 @@ export declare function formatSiteDateTime(epochMs: number, gmtRedaction: string
4194
4316
 
4195
4317
  export declare function getAllPublications(sites: SiteSection[]): Publication[];
4196
4318
 
4319
+ /**
4320
+ * Ícono a partir del nombre que guarda el Authenticator (`"PollIcon"`), en su
4321
+ * variante Outlined. El barrel de íconos se baja aparte y solo para estos
4322
+ * ítems; mientras llega (o si el nombre no existe) se ve el genérico.
4323
+ */
4324
+ export declare function getAuthSidebarIcon(name?: string | null): ElementType;
4325
+
4197
4326
  /**
4198
4327
  * Resuelve el mensaje legible de un código de error en el idioma indicado.
4199
4328
  * Aplica el fallback legacy `código → código+'a'` (p. ej. `999.002` → `999.002a`)
@@ -4836,6 +4965,16 @@ export declare type NavLinkItem = {
4836
4965
  module: string;
4837
4966
  /** Override opcional del label traducido vía i18n (`navigation.{module}`). */
4838
4967
  label?: string;
4968
+ /**
4969
+ * Clave i18n de `navigation` cuando no coincide con `module` (p. ej. PLANS y
4970
+ * MYPLAN se leen los dos como `PRODUCTION`). Si falta, se usa `module`.
4971
+ */
4972
+ labelKey?: string;
4973
+ /**
4974
+ * Se dibuja aunque su `module` no venga en `modulesAvailable` (ítems que manda
4975
+ * el Authenticator: pines de otras apps y módulos hermanos).
4976
+ */
4977
+ alwaysVisible?: boolean;
4839
4978
  badge?: string;
4840
4979
  children?: NavLinkItem[];
4841
4980
  defaultOpen?: boolean;
@@ -6474,6 +6613,12 @@ export declare const ptMessages: {
6474
6613
  COPILOT: string;
6475
6614
  ZONES: string;
6476
6615
  IA: string;
6616
+ PRODUCTION: string;
6617
+ FREQUENCY: string;
6618
+ VODS: string;
6619
+ SUBSCRIPTIONS: string;
6620
+ MYPLAN: string;
6621
+ USERS_MANAGER: string;
6477
6622
  };
6478
6623
  sidebar: {
6479
6624
  navAriaLabel: string;
@@ -6649,12 +6794,24 @@ export declare const ptMessages: {
6649
6794
  notFoundTitle: string;
6650
6795
  notFoundSubtitle: string;
6651
6796
  notFoundCode: string;
6797
+ notFoundCodeLabel: string;
6652
6798
  errorLabel: string;
6653
- copyDetail: string;
6654
- copyDetailText: string;
6655
- copied: string;
6656
6799
  notAllowedTitle: string;
6657
6800
  notAllowedSubtitle: string;
6801
+ notAllowedCode: string;
6802
+ notAllowedCodeLabel: string;
6803
+ detailTitle: string;
6804
+ detailFieldCode: string;
6805
+ detailFieldAddress: string;
6806
+ detailFieldUser: string;
6807
+ detailFieldDate: string;
6808
+ copyDetail: string;
6809
+ copied: string;
6810
+ helpHintPrefix: string;
6811
+ loggedInAsPrefix: string;
6812
+ changeAccount: string;
6813
+ footerBrand: string;
6814
+ footerCodeLabel: string;
6658
6815
  };
6659
6816
  };
6660
6817
 
@@ -6968,6 +7125,19 @@ export declare interface ResilientRunOptions {
6968
7125
  maxRetries?: number;
6969
7126
  /** Mostrar el toast "reintentando" al reanudar tras una desconexión. Default true. */
6970
7127
  notifyRetry?: boolean;
7128
+ /**
7129
+ * Clave para **deduplicar** llamados idénticos en vuelo (p. ej. el usuario le
7130
+ * dio clic varias veces al mismo botón mientras esperaba reconexión). Si ya
7131
+ * hay un `run` con la misma clave esperando conexión/reintentando, este NO
7132
+ * vuelve a invocar `fn`: se engancha a esa misma promesa y ambos llamantes
7133
+ * reciben el mismo resultado (un solo request real, no uno por clic).
7134
+ *
7135
+ * Sin esta opción no hay dedupe (comportamiento previo, sin cambios). El
7136
+ * gestor arma la clave con lo que identifica **esa** acción de negocio, p. ej.
7137
+ * `` `users/setStatus:${userId}` ``: no la deriva la lib porque es una
7138
+ * decisión del caller (no todo llamado conviene deduplicar).
7139
+ */
7140
+ dedupeKey?: string;
6971
7141
  }
6972
7142
 
6973
7143
  export declare function resolveCmsAssetUrl(path: string, cmsOrigin?: string): string;
@@ -7210,7 +7380,20 @@ export declare type SidebarProps = {
7210
7380
  * todo. El anclado se identifica por `item.module` y persiste vía
7211
7381
  * `profileServices.addPins`/`deletePins`/`getPins` (recurso de perfil).
7212
7382
  */
7213
- export declare function SidebarRail({ pathname, permissions, LinkComponent, legacyBaseUrl, cmsBaseUrl, legacySession, selectedPublicationId, navHrefOverrides, items, profileServices, }: SidebarRailProps): JSX.Element;
7383
+ export declare function SidebarRail({ pathname, permissions, LinkComponent, legacyBaseUrl, cmsBaseUrl, legacySession, selectedPublicationId, navHrefOverrides, items, sections, profileServices, authService, }: SidebarRailProps): JSX.Element;
7384
+
7385
+ /**
7386
+ * Pines y módulos hermanos del Authenticator, igual que cmsmedios
7387
+ * (`MenuService.mergeWithAuthenticatorSidebar` + `PinesService`). El gestor lo
7388
+ * arma con su token y la publicación actual:
7389
+ * - `getSidebar` → `GET /api/v1/auth/sidebar?publicationId=N`
7390
+ * - `pin` / `unpin` → `POST` / `DELETE /api/v1/auth/sidebar/pin`
7391
+ */
7392
+ export declare type SidebarRailAuthService = {
7393
+ getSidebar: () => Promise<AuthSidebarResponse>;
7394
+ pin: (moduleName: string, itemKey: string) => Promise<void>;
7395
+ unpin: (moduleName: string, itemKey: string) => Promise<void>;
7396
+ };
7214
7397
 
7215
7398
  /** Servicio de pines usado por el rail: solo necesita estos tres métodos. */
7216
7399
  export declare type SidebarRailPinService = Pick<CmsProfileServices, 'addPins' | 'deletePins' | 'getPins'>;
@@ -7232,14 +7415,28 @@ export declare type SidebarRailProps = {
7232
7415
  * gestor hermano para el ajeno). Misma pestaña. Ver `resolveNavHrefOverride`.
7233
7416
  */
7234
7417
  navHrefOverrides?: Record<string, string>;
7235
- /** Ítems de navegación. Por defecto, `ACCOUNT_NAV_BLOCKS`. */
7418
+ /**
7419
+ * Ítems en una sola lista, sin separadores. Si se pasa, gana sobre `sections`
7420
+ * (compatibilidad con los gestores que mandaban su propia lista).
7421
+ */
7236
7422
  items?: NavLinkItem[];
7423
+ /**
7424
+ * Ítems agrupados en secciones separadas por una línea. Por defecto,
7425
+ * `CMS_MENU_SECTIONS`: el mismo menú que cmsmedios y el gestor de noticias.
7426
+ */
7427
+ sections?: NavLinkItem[][];
7237
7428
  /**
7238
7429
  * Servicio de pines (`CmsProfileServices`, construido por el host con su
7239
7430
  * `axiosApi`/`authentication`). Si se omite, el anclado es solo visual y no
7240
7431
  * persiste entre sesiones.
7241
7432
  */
7242
7433
  profileServices?: SidebarRailPinService;
7434
+ /**
7435
+ * Pines y módulos hermanos del Authenticator, como cmsmedios. Si se pasa,
7436
+ * reemplaza a `profileServices` (pines viejos del perfil del CMS) y el orden
7437
+ * de los anclados es el de cmsmedios. Ver `buildCmsmediosMenu`.
7438
+ */
7439
+ authService?: SidebarRailAuthService;
7243
7440
  };
7244
7441
 
7245
7442
  /**
@@ -8095,6 +8292,11 @@ export declare type UserAvatarProps = {
8095
8292
  * resultado de error para que el caller muestre el toast.
8096
8293
  * - **Error de negocio (4xx / `status:'fail'`):** no reintenta; devuelve el
8097
8294
  * resultado tal cual para que el caller decida (toast/update optimista).
8295
+ * - **Clics repetidos a la misma acción** (con `dedupeKey`): mientras el
8296
+ * primer llamado siga esperando reconexión o reintentando, los siguientes
8297
+ * con la misma clave no disparan `fn` de nuevo — se enganchan a la misma
8298
+ * promesa, así solo sale un request real aunque el usuario haya hecho clic
8299
+ * varias veces.
8098
8300
  *
8099
8301
  * El toast global de "sin conexión" / "conexión restablecida" lo dispara
8100
8302
  * `CmsNetworkToaster`; este hook solo añade el "reintentando…" por acción.
@@ -8102,8 +8304,11 @@ export declare type UserAvatarProps = {
8102
8304
  * Uso en el gestor:
8103
8305
  * ```ts
8104
8306
  * const run = useResilientAction();
8105
- * const res = await run(() => setUserStatus(slug, id, action),
8106
- * { service: '/users/actions/setStatus', params: { id, action } });
8307
+ * const res = await run(() => setUserStatus(slug, id, action), {
8308
+ * service: '/users/actions/setStatus',
8309
+ * params: { id, action },
8310
+ * dedupeKey: `users/setStatus:${id}`,
8311
+ * });
8107
8312
  * ```
8108
8313
  */
8109
8314
  export declare function useResilientAction(): ResilientRunner;