react-ecosistema-unp 2.1.0 → 2.3.0
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/{AppList-BshxZhoN.js → AppList-DORGpC4I.js} +84 -84
- package/dist/assets/DocumentoVisorEstado.css +1 -0
- package/dist/assets/EcoDataTable.css +1 -1
- package/dist/assets/EcoDataTableBandejaFooter.css +1 -1
- package/dist/assets/SileoNotifications.css +1 -1
- package/dist/cards/tarjeta/nuevo-elemento/NuevoElemento.js +1 -1
- package/dist/cards/tarjeta-info/TarjetaInfo.js +1 -1
- package/dist/data/tarjeta-datos/TarjetaDatos.js +1 -1
- package/dist/{index-C4MBu_wk.js → index-B96iRUpt.js} +38 -34
- package/dist/{index-h-TtOxhs.js → index-BqaJxgOF.js} +182 -170
- package/dist/lib/shared/menu-lateral/MenuLateral.d.ts +4 -0
- package/dist/lib/shared/menu-lateral/colorUtils.d.ts +4 -0
- package/dist/lib/shared/ventana-lienzo/VentanaLienzo.d.ts +4 -0
- package/dist/lib/shared/ventana-tabs/VentanaTabs.d.ts +4 -0
- package/dist/lib/tables/custom-data-table/CustomDataTable.d.ts +2 -0
- package/dist/lib/tables/custom-data-table-split/CustomDataTableSplit.d.ts +3 -1
- package/dist/lib/tables/eco-data-table/components/EcoDataTable/EcoDataTable.d.ts +1 -1
- package/dist/lib/tables/eco-data-table/components/EcoDataTableBandejaFooter.d.ts +8 -1
- package/dist/lib/tables/eco-data-table/hooks/useEcoTableSelection.d.ts +1 -0
- package/dist/lib/tables/eco-data-table/types.d.ts +7 -0
- package/dist/lib/ui/animacion/Animacion.d.ts +1 -0
- package/dist/lib/ui.d.ts +1 -0
- package/dist/lib/utils/modal-radicados/DocumentoVisorEstado.d.ts +18 -0
- package/dist/lib/utils/modal-radicados/ModalDocumento.d.ts +26 -0
- package/dist/lib/utils/modal-radicados/VisorDocumento.d.ts +8 -0
- package/dist/lib/utils.d.ts +1 -0
- package/dist/shared/app-list/AppList.js +2 -2
- package/dist/shared/iconos-sistema/IconosSistema.js +1 -1
- package/dist/shared/iconos-sistema/logout-button/LogoutButton.js +1 -1
- package/dist/shared/menu-lateral/MenuLateral.js +140 -125
- package/dist/shared/menu-lateral/colorUtils.js +47 -0
- package/dist/shared/notificacion-usuario/NotificacionUsuario.js +6 -5
- package/dist/shared/ventana-lienzo/VentanaLienzo.js +28 -24
- package/dist/shared/ventana-tabs/VentanaTabs.js +93 -89
- package/dist/tables/custom-data-table/CustomDataTable.js +549 -547
- package/dist/tables/custom-data-table-split/CustomDataTableSplit.js +68 -65
- package/dist/tables/custom-table-toolbar/CustomTableToolbar.js +1 -1
- package/dist/tables/eco-data-table/components/EcoDataTable/EcoDataTable.js +190 -149
- package/dist/tables/eco-data-table/components/EcoDataTableBandejaFooter.js +36 -26
- package/dist/tables/eco-data-table/hooks/useEcoTableSelection.js +9 -8
- package/dist/tables/tabla-registros/buscador/Buscador.js +1 -1
- package/dist/tables/tabla-registros/modal-v2/EcoModal.js +11 -11
- package/dist/tables/tabla-registros/tabla/Tabla.js +22 -22
- package/dist/ui/alertas/AlertaFormulario.js +1 -1
- package/dist/ui/card-gestion-lateral/CardGestionLateral.js +1 -1
- package/dist/ui/contenido-modal/ContenidoModal.js +1 -1
- package/dist/ui/contenido-modal/ContenidoModalv0.1.js +1 -1
- package/dist/ui/contenido-modal-v2/ContenidoModalV2.js +1 -1
- package/dist/ui/contenido-modal-v2/ModalV2Menu.js +1 -1
- package/dist/ui/datos-basicos-card/DatosBasicosCard.js +1 -1
- package/dist/ui/icono-tooltip/IconoTooltip.js +10 -10
- package/dist/ui/items-modal/ItemsModal.js +1 -1
- package/dist/ui/nav-formularios-lateral/NavFormulariosLateral.js +1 -1
- package/dist/ui/notificacion-popover-v2/NotificacionPopoverV2.js +50 -50
- package/dist/ui/resumen-evaluacion/ResumenEvaluacion.js +5 -5
- package/dist/ui/status-filter-bar/StatusFilterBar.js +8 -8
- package/dist/ui/status-semaphore/StatusSemaphore.js +1 -1
- package/dist/ui/stepper-v2/StepperV2.js +1 -1
- package/dist/utils/eco-provider/EcoContext.js +4 -3
- package/dist/utils/modal-radicados/AuxRadicadosComponents/TarjetaRadicado.js +12 -12
- package/dist/utils/modal-radicados/DocumentoVisorEstado.js +125 -0
- package/dist/utils/modal-radicados/ModalDocumento.js +155 -170
- package/dist/utils/modal-radicados/ModalRadicado.js +34 -34
- package/dist/utils/modal-radicados/VisorDocumento.js +61 -61
- package/dist/utils/notifications/EcoToaster.js +26 -25
- package/dist/utils/unp-historico/UnpHistorico.js +1 -1
- package/dist/utils.js +29 -27
- package/package.json +1 -1
|
@@ -13,6 +13,10 @@ interface VentanaLienzoProps {
|
|
|
13
13
|
showSideMenu?: boolean;
|
|
14
14
|
/** Ítems adicionales del aplicativo en el menú lateral */
|
|
15
15
|
extraMenuItems?: MenuLateralItem[];
|
|
16
|
+
/** Color primario del menú lateral (hex). Los demás tonos se derivan automáticamente. */
|
|
17
|
+
menuColor?: string;
|
|
18
|
+
/** Si es false, oculta los ítems institucionales del menú lateral, dejando solo `extraMenuItems`. Default: true */
|
|
19
|
+
showBaseMenuItems?: boolean;
|
|
16
20
|
}
|
|
17
21
|
declare const VentanaLienzo: React.FC<VentanaLienzoProps>;
|
|
18
22
|
export { VentanaLienzo };
|
|
@@ -9,6 +9,10 @@ interface VentanaUsuarioProps {
|
|
|
9
9
|
showSideMenu?: boolean;
|
|
10
10
|
/** Ítems adicionales del aplicativo en el menú lateral */
|
|
11
11
|
extraMenuItems?: MenuLateralItem[];
|
|
12
|
+
/** Color primario del menú lateral (hex). Los demás tonos se derivan automáticamente. */
|
|
13
|
+
menuColor?: string;
|
|
14
|
+
/** Si es false, oculta los ítems institucionales del menú lateral, dejando solo `extraMenuItems`. Default: true */
|
|
15
|
+
showBaseMenuItems?: boolean;
|
|
12
16
|
}
|
|
13
17
|
declare const VentanaTabs: React.FC<VentanaUsuarioProps>;
|
|
14
18
|
export { VentanaTabs };
|
|
@@ -37,6 +37,8 @@ interface CustomDataTableProps {
|
|
|
37
37
|
filterTypes?: FilterTypeOption[];
|
|
38
38
|
onServerFilteredSearch?: (tipo: string, filtro: string) => void | Promise<void>;
|
|
39
39
|
externalPage?: number;
|
|
40
|
+
/** Permite controlar si hacer clic fuera del modal primario lo cierra (por defecto true). */
|
|
41
|
+
closeModalOut?: boolean;
|
|
40
42
|
}
|
|
41
43
|
export declare const CustomDataTable: React.FC<CustomDataTableProps>;
|
|
42
44
|
export {};
|
|
@@ -62,5 +62,7 @@ export interface CustomDataTableSplitProps<T extends object = Record<string, unk
|
|
|
62
62
|
toolbar?: TableToolbarConfig;
|
|
63
63
|
/** Función que se ejecuta al hacer clic en cualquier lugar de una fila de la tabla. */
|
|
64
64
|
onRowClick?: (row: T) => void;
|
|
65
|
+
/** Permite controlar si hacer clic fuera del modal primario lo cierra (por defecto true). */
|
|
66
|
+
closeModalOut?: boolean;
|
|
65
67
|
}
|
|
66
|
-
export declare function CustomDataTableSplit<T extends object = Record<string, unknown>>({ columns, data, isShared, splitField, firstSectionValue, sectionLabels, renderModalContent, title, subtitle, isLoading, headerActions, getRowStyle, pageSize, getRowKey, rowSelection, infiniteScroll, enableColumnFilters, stickyHeader, toolbar, onRowClick, }: CustomDataTableSplitProps<T>): ReactElement;
|
|
68
|
+
export declare function CustomDataTableSplit<T extends object = Record<string, unknown>>({ columns, data, isShared, splitField, firstSectionValue, sectionLabels, renderModalContent, title, subtitle, isLoading, headerActions, getRowStyle, pageSize, getRowKey, rowSelection, infiniteScroll, enableColumnFilters, stickyHeader, toolbar, onRowClick, closeModalOut, }: CustomDataTableSplitProps<T>): ReactElement;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { ReactElement } from 'react';
|
|
2
2
|
import { EcoDataTableProps } from '../../types';
|
|
3
|
-
export declare function EcoDataTable<T extends object = Record<string, unknown>>({ columns, data, isLoading, isFetching, stickyHeader, className, pageSize, getRowStyle, getRowKey, pagination, selection, reorder, selectionActions, onRowClick, }: EcoDataTableProps<T>): ReactElement;
|
|
3
|
+
export declare function EcoDataTable<T extends object = Record<string, unknown>>({ columns, data, isLoading, isFetching, stickyHeader, className, pageSize, getRowStyle, getRowKey, pagination, selection, reorder, selectionActions, onRowClick, footerOrgLines, footerMetaShort, }: EcoDataTableProps<T>): ReactElement;
|
|
@@ -8,5 +8,12 @@ export interface EcoDataTableBandejaFooterProps {
|
|
|
8
8
|
hasMore?: boolean;
|
|
9
9
|
showPagination?: boolean;
|
|
10
10
|
year?: number;
|
|
11
|
+
/**
|
|
12
|
+
* Líneas de dependencias (texto completo). En móvil se muestra solo el acrónimo
|
|
13
|
+
* tras el separador "·" (p. ej. "… · UNP" → "UNP").
|
|
14
|
+
*/
|
|
15
|
+
orgLines?: readonly string[];
|
|
16
|
+
/** Texto corto del meta en móvil (por defecto "EI UNP"). */
|
|
17
|
+
metaShort?: string;
|
|
11
18
|
}
|
|
12
|
-
export declare function EcoDataTableBandejaFooter({ currentPage, totalPages, onPageChange, totalRecords, pageSize, hasMore, showPagination, year, }: EcoDataTableBandejaFooterProps): ReactElement;
|
|
19
|
+
export declare function EcoDataTableBandejaFooter({ currentPage, totalPages, onPageChange, totalRecords, pageSize, hasMore, showPagination, year, orgLines, metaShort, }: EcoDataTableBandejaFooterProps): ReactElement;
|
|
@@ -8,6 +8,7 @@ export declare function useEcoTableSelection<T extends object>({ data, selection
|
|
|
8
8
|
selectionKey: (keyof T & string) | undefined;
|
|
9
9
|
selectedKeys: string[];
|
|
10
10
|
toggleKey: (key: string) => void;
|
|
11
|
+
setSelectedKeys: (keys: string[]) => void;
|
|
11
12
|
isSelected: (key: string) => boolean;
|
|
12
13
|
hasSelection: boolean;
|
|
13
14
|
};
|
|
@@ -57,4 +57,11 @@ export interface EcoDataTableProps<T extends object = Record<string, unknown>> {
|
|
|
57
57
|
selectionActions?: ReactNode;
|
|
58
58
|
/** Click en fila (p. ej. abrir vista de detalle del caso). */
|
|
59
59
|
onRowClick?: (row: T) => void;
|
|
60
|
+
/**
|
|
61
|
+
* Líneas del branding del footer (texto completo). En ≤768px se muestra solo el
|
|
62
|
+
* acrónimo tras "·". Por defecto: UNP / SESP / GRAERR.
|
|
63
|
+
*/
|
|
64
|
+
footerOrgLines?: readonly string[];
|
|
65
|
+
/** Texto corto del meta en móvil (por defecto "EI UNP"). */
|
|
66
|
+
footerMetaShort?: string;
|
|
60
67
|
}
|
package/dist/lib/ui.d.ts
CHANGED
|
@@ -16,6 +16,7 @@ export { ContenedorVentana } from './ui/contenedor-ventana/ContenedorVentana.tsx
|
|
|
16
16
|
export { CustomModal } from './tables/tabla-registros/modal/Modal.tsx';
|
|
17
17
|
export { EcoModal } from './tables/tabla-registros/modal-v2/EcoModal.tsx';
|
|
18
18
|
export { Animacion } from './ui/animacion/Animacion.tsx';
|
|
19
|
+
export type { AnimationType } from './ui/animacion/Animacion.tsx';
|
|
19
20
|
export { Tarjeta } from './cards/tarjeta/Tarjeta.tsx';
|
|
20
21
|
export { SeccionTarjeta } from './cards/tarjeta/seccion-tarjeta/SeccionTarjeta.tsx';
|
|
21
22
|
export { NuevoElemento } from './cards/tarjeta/nuevo-elemento/NuevoElemento.tsx';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { AnimationType } from '../../ui/animacion/Animacion';
|
|
3
|
+
export type DocumentoVisorEstadoKind = "unsupported" | "error" | "loading";
|
|
4
|
+
export interface DocumentoVisorEstadoProps {
|
|
5
|
+
kind: DocumentoVisorEstadoKind;
|
|
6
|
+
/** Nombre del archivo (se muestra destacado). */
|
|
7
|
+
name?: string;
|
|
8
|
+
mimeType?: string;
|
|
9
|
+
/** Mensaje técnico opcional (p. ej. detalle del error de red). */
|
|
10
|
+
detail?: string;
|
|
11
|
+
allowDownload?: boolean;
|
|
12
|
+
onDownload?: () => void;
|
|
13
|
+
onRetry?: () => void;
|
|
14
|
+
/** Animación de carga. Default: `loading_duck`. */
|
|
15
|
+
animationType?: AnimationType;
|
|
16
|
+
}
|
|
17
|
+
declare const DocumentoVisorEstado: React.FC<DocumentoVisorEstadoProps>;
|
|
18
|
+
export { DocumentoVisorEstado };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
+
import { AnimationType } from '../../ui/animacion/Animacion';
|
|
2
3
|
interface DocumentoProps {
|
|
3
4
|
data: string;
|
|
4
5
|
mimeType: string;
|
|
@@ -7,6 +8,31 @@ interface DocumentoProps {
|
|
|
7
8
|
blobUrl?: string;
|
|
8
9
|
allowDownloadButton?: boolean;
|
|
9
10
|
autoDownloadOnUnsupported?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* Solo visualización (opt-in, default false).
|
|
13
|
+
* - PDF: oculta la barra nativa (`#toolbar=0&navpanes=0&scrollbar=0`)
|
|
14
|
+
* - Audio/video: usa `<audio>`/`<video>` con `controlsList="nodownload"`
|
|
15
|
+
* - Oculta el botón propio de descarga
|
|
16
|
+
* Si no se pasa, el comportamiento queda igual que antes.
|
|
17
|
+
*/
|
|
18
|
+
viewOnly?: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Error de consulta/carga (no es “formato no soportado”).
|
|
21
|
+
* Si se define, muestra el estado de error con `onRetry` si existe.
|
|
22
|
+
*/
|
|
23
|
+
loadError?: string | null;
|
|
24
|
+
/** Reintentar la consulta del documento cuando `loadError` está presente. */
|
|
25
|
+
onRetry?: () => void;
|
|
26
|
+
/**
|
|
27
|
+
* Animación de carga mientras se prepara el blob/visor.
|
|
28
|
+
* Default: `loading_duck`. Ej.: `paloma`, `gato`, `loading_parrot`, etc.
|
|
29
|
+
*/
|
|
30
|
+
animationType?: AnimationType;
|
|
31
|
+
/**
|
|
32
|
+
* Fuerza el estado de carga (mismo shell que error / no soportado).
|
|
33
|
+
* Útil cuando el padre aún está consultando el documento.
|
|
34
|
+
*/
|
|
35
|
+
isLoading?: boolean;
|
|
10
36
|
}
|
|
11
37
|
declare const ModalDocumento: React.FC<DocumentoProps>;
|
|
12
38
|
declare const getIconByType: (tipo?: string) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,8 +1,16 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
+
import { AnimationType } from '../../ui/animacion/Animacion';
|
|
2
3
|
interface VisorDocumentoProps {
|
|
3
4
|
idDocumento: string;
|
|
4
5
|
nombre?: string;
|
|
5
6
|
allowDownloadButton?: boolean;
|
|
7
|
+
/** Solo visualización; se reenvía a ModalDocumento (default false). */
|
|
8
|
+
viewOnly?: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Animación de carga. Default: `loading_duck`.
|
|
11
|
+
* Se reenvía a ModalDocumento (p. ej. `paloma`, `gato`, `loading_parrot`).
|
|
12
|
+
*/
|
|
13
|
+
animationType?: AnimationType;
|
|
6
14
|
}
|
|
7
15
|
declare const VisorDocumento: React.FC<VisorDocumentoProps>;
|
|
8
16
|
export { VisorDocumento };
|
package/dist/lib/utils.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ export { WebSocketProvider, useWebSocketConnection } from './utils/websocket-man
|
|
|
7
7
|
export { useWebSocket } from './utils/websocket-manager/useWebSocket.js';
|
|
8
8
|
export { ModalRadicado } from './utils/modal-radicados/ModalRadicado.js';
|
|
9
9
|
export { ModalDocumento } from './utils/modal-radicados/ModalDocumento.js';
|
|
10
|
+
export { DocumentoVisorEstado } from './utils/modal-radicados/DocumentoVisorEstado.js';
|
|
10
11
|
export { formatDate };
|
|
11
12
|
export * from './utils/notifications/SileoNotifications.js';
|
|
12
13
|
export { Toaster } from './utils/notifications/EcoToaster.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as c, jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import { LogoutButton as n } from "./logout-button/LogoutButton.js";
|
|
3
|
-
import { A as p } from "../../AppList-
|
|
3
|
+
import { A as p } from "../../AppList-DORGpC4I.js";
|
|
4
4
|
import { NotificacionUsuario as d } from "../notificacion-usuario/NotificacionUsuario.js";
|
|
5
5
|
import { UserProfileIcon as m } from "../user-profile-icon/UserProfileIcon.js";
|
|
6
6
|
import '../../assets/IconosSistema.css';const b = ({ elements: r, showLogout: a = !1, notificationType: t = "normal" }) => /* @__PURE__ */ c("div", { className: "iconos-sistema-container", children: [
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as t, Fragment as i, jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { useFinalizarSesion as n } from "../../../auth/hooks/useFinalizarSesion.js";
|
|
3
|
-
import {
|
|
3
|
+
import { _ as s } from "../../../index-BqaJxgOF.js";
|
|
4
4
|
import { L as m } from "../../../index-Cy8qF6oY.js";
|
|
5
5
|
import '../../../assets/LogoutButton.css';const p = () => {
|
|
6
6
|
const { FinSesion: r } = n();
|