@acvl/frontend-components 0.0.107 → 0.0.109
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/cjs/index.js +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/index.d.ts +50 -6
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1241,6 +1241,12 @@ interface APIcontextProps {
|
|
|
1241
1241
|
useGetPreferenciasDeExportacionQuery: any;
|
|
1242
1242
|
useGuardarPreferenciaDeExportacionMutation: any;
|
|
1243
1243
|
useBorrarPreferenciaDeExportacionMutation: any;
|
|
1244
|
+
/**
|
|
1245
|
+
* `POST <ruta>/` con `{ ids }` → `{ eliminados, omitidos: [{ id, motivo }] }`: el borrado en
|
|
1246
|
+
* lote de las grillas. La ruta la anuncia el backend en la respuesta del listado. Opcional —
|
|
1247
|
+
* una app que no lo da simplemente no ofrece la acción.
|
|
1248
|
+
*/
|
|
1249
|
+
useEliminarVariosMutation?: any;
|
|
1244
1250
|
}
|
|
1245
1251
|
declare const APIContext: React$1.Context<APIcontextProps | null>;
|
|
1246
1252
|
declare const APIProvider: ({ children, hooks, }: {
|
|
@@ -1468,6 +1474,14 @@ declare const es: {
|
|
|
1468
1474
|
instruccion: (palabra: string) => string;
|
|
1469
1475
|
exito: string;
|
|
1470
1476
|
};
|
|
1477
|
+
borradoEnLote: {
|
|
1478
|
+
accion: string;
|
|
1479
|
+
titulo: string;
|
|
1480
|
+
mensaje: (total: number) => string;
|
|
1481
|
+
excedeTope: (tope: number) => string;
|
|
1482
|
+
exito: (total: number) => string;
|
|
1483
|
+
resumen: (eliminados: number, omitidos: number) => string;
|
|
1484
|
+
};
|
|
1471
1485
|
errores: {
|
|
1472
1486
|
accesoNoPermitido: string;
|
|
1473
1487
|
sinPermisos: string;
|
|
@@ -2513,6 +2527,11 @@ interface CustomFilterDef {
|
|
|
2513
2527
|
* `"popper"` floats it off the toolbar button, the way it used to.
|
|
2514
2528
|
*/
|
|
2515
2529
|
type FiltersVariant = "drawer" | "popper";
|
|
2530
|
+
interface ExtraToolbarAction {
|
|
2531
|
+
label: string;
|
|
2532
|
+
onClick: (rowSelectionModel: GridRowSelectionModel) => void;
|
|
2533
|
+
validation?: (rowSelectionModel: GridRowSelectionModel) => boolean;
|
|
2534
|
+
}
|
|
2516
2535
|
|
|
2517
2536
|
/**
|
|
2518
2537
|
* What the grid hands its RTK lazy query — the corrected `GridArgs`.
|
|
@@ -2748,6 +2767,8 @@ interface GridLayerContribution {
|
|
|
2748
2767
|
appendColumns?: GridColDefPropsOverrides[];
|
|
2749
2768
|
/** Appended after the consumer's own toolbar buttons, in `LAYER_ORDER`. */
|
|
2750
2769
|
toolbarButtons?: NonNullable<CustomToolbarProps["extraButtons"]>;
|
|
2770
|
+
/** Appended after the consumer's own selection actions (the ⋮ menu), in `LAYER_ORDER`. */
|
|
2771
|
+
selectionActions?: ExtraToolbarAction[];
|
|
2751
2772
|
/** Suggested props. The consumer's `dataGridProps` still wins. */
|
|
2752
2773
|
defaults?: Partial<MyDataGridProps>;
|
|
2753
2774
|
/**
|
|
@@ -3131,7 +3152,12 @@ interface DetailFormApi {
|
|
|
3131
3152
|
skipToken?: boolean;
|
|
3132
3153
|
};
|
|
3133
3154
|
mutate: {
|
|
3134
|
-
|
|
3155
|
+
/**
|
|
3156
|
+
* El hook de la mutación (`useMutateXMutation`). Sin él el registro es de sólo lectura
|
|
3157
|
+
* —una bitácora, un trabajo en segundo plano—: no se ofrece editar aunque el registro
|
|
3158
|
+
* traiga `obj_permissions.edit`, igual que con `disable`.
|
|
3159
|
+
*/
|
|
3160
|
+
mutation?: any;
|
|
3135
3161
|
args?: any;
|
|
3136
3162
|
disable?: boolean;
|
|
3137
3163
|
successMessage?: string | ((response: any) => string);
|
|
@@ -3361,8 +3387,16 @@ interface DetailExtraButton {
|
|
|
3361
3387
|
/**
|
|
3362
3388
|
* Condition on top of `pageType`, checked against the loaded record. Typically one of its
|
|
3363
3389
|
* own flags (`puede_cerrar`), so what the backend allows is what the user sees.
|
|
3390
|
+
*
|
|
3391
|
+
* Those flags describe what is saved, so `context.isDirty` lets an action that acts on the
|
|
3392
|
+
* saved record step aside while the form holds unsaved changes —the user saves first—.
|
|
3364
3393
|
*/
|
|
3365
|
-
display?: (data: any) => boolean;
|
|
3394
|
+
display?: (data: any, context: ExtraButtonContext) => boolean;
|
|
3395
|
+
}
|
|
3396
|
+
/** The state of the shell around the record, for `DetailExtraButton.display`. */
|
|
3397
|
+
interface ExtraButtonContext {
|
|
3398
|
+
/** The form has unsaved changes. Always `false` outside create/edit. */
|
|
3399
|
+
isDirty: boolean;
|
|
3366
3400
|
}
|
|
3367
3401
|
|
|
3368
3402
|
interface DetailPageV2Props {
|
|
@@ -3796,6 +3830,12 @@ interface ServerGridState {
|
|
|
3796
3830
|
rows: readonly any[];
|
|
3797
3831
|
rowCount: number;
|
|
3798
3832
|
permissions: ServerGridPermissions;
|
|
3833
|
+
/**
|
|
3834
|
+
* Where the bulk delete of these rows goes, as the backend advertises it in the list
|
|
3835
|
+
* response — only to superusers, only for the resource whose rows these are. Absent, the
|
|
3836
|
+
* grid doesn't offer it.
|
|
3837
|
+
*/
|
|
3838
|
+
eliminarVarios?: string;
|
|
3799
3839
|
isLoading: boolean;
|
|
3800
3840
|
isFetching: boolean;
|
|
3801
3841
|
isError: boolean;
|
|
@@ -4180,8 +4220,11 @@ interface DrawerGridDrawerConfig {
|
|
|
4180
4220
|
create?: ReactNode;
|
|
4181
4221
|
record?: ReactNode | ((id: GridRowId) => ReactNode);
|
|
4182
4222
|
};
|
|
4183
|
-
/**
|
|
4184
|
-
|
|
4223
|
+
/**
|
|
4224
|
+
* Create-mode API (opened by the "Quick create" menu option). Without it the drawer has no
|
|
4225
|
+
* create mode: the grid's create option keeps its full-page route.
|
|
4226
|
+
*/
|
|
4227
|
+
create?: {
|
|
4185
4228
|
mutation: any;
|
|
4186
4229
|
/** Defaults to `"create"`. */
|
|
4187
4230
|
pageType?: PageType;
|
|
@@ -4191,7 +4234,8 @@ interface DrawerGridDrawerConfig {
|
|
|
4191
4234
|
record: {
|
|
4192
4235
|
/** Single-record query hook, called with `{ id, ...args(id) }`. */
|
|
4193
4236
|
query: any;
|
|
4194
|
-
|
|
4237
|
+
/** Without it the record is read-only: the drawer never offers to edit it. */
|
|
4238
|
+
mutation?: any;
|
|
4195
4239
|
/**
|
|
4196
4240
|
* Defaults to `"detail"` (read-only), matching a row-click. Use `"edit"` for an always
|
|
4197
4241
|
* editable drawer — a `"detail"` drawer already opens editing while the grid itself is
|
|
@@ -5344,4 +5388,4 @@ declare const mutationParams: (arg: any) => {
|
|
|
5344
5388
|
declare const mutationId: (arg: any) => any;
|
|
5345
5389
|
|
|
5346
5390
|
export { APIContext, APIProvider, AccountMenuContent, ActiveCell, ActiveIcon, Base, ButtonWithDrawer, COLOR_SCHEME_SELECTOR, CSVUpload, CatalogoItem, CatalogoList, ChipCell, ConfirmDialog, ContentBorderRadiusContext, ContentLayout, ControlledAddressAutocomplete, ControlledAmountWithCurrency, ControlledAutocomplete, ControlledColor, ControlledDate$1 as ControlledDate, ControlledDate as ControlledDate_v2, ControlledDropdown, ControlledFileField$1 as ControlledFileField, ControlledFileField as ControlledFileField_v2, FileUploadBox as ControlledFileUploadBox, ControlledNumber, ControlledPhoneNumber, ControlledSelect$1 as ControlledSelect, ControlledSelect as ControlledSelect_v2, ControlledSlider as ControlledSimpleSlider, ControlledSlider$1 as ControlledSlider, ControlledSwitch, ControlledText, ControlledTimePicker, ControlledToggleButtons, CoverPage, CreateButtonBase, CreateButtonWithMenuOptions, CrudDropdown, CustomNoRows, DEFAULT_CONTENT_BORDER_RADIUS, DEFAULT_FORM_BREAKPOINTS, DEFAULT_PAGINATION, DRAWER_Z_INDEX, Dato, DeleteButton, DeleteConfirmationDialog, DetailFormDialog as DetailFormDialog_v2, DetailFormDrawer as DetailFormDrawer_v2, DetailForm as DetailForm_v2, DetailPage$1 as DetailPage, DetailPage as DetailPage_v2, Documento, DrawerGrid as DrawerGrid_v2, EditButton, ExportCSV$1 as ExportCSV, ExportCSV as ExportCSV_v2, ExtraButtons, FILTERS_DRAWER_GAP, FORM_CONTAINER_NAME, GlobalSearch, GrillaHastaElFondo, HEADER_CONTAINER, HEADER_NARROW, HiddenPageHeaderContext, HistorialDrawer, KpiCard, LAYER_ORDER, ListPage, Lista, Loadable, LoadingComponent, LocaleContext, LocaleProvider, Logo, MainDrawer, MainDrawer$1 as MainDrawer_v2, MainLayout, MenuItemWithLoading, ModuleCard, MoreOptions, MyGridEditSingleSelect, NavigationContext, NavigationProvider, NormalOrIcon, NotAllowed, NotFound, NotificationItem, NotificationsBell, ObjectProgressStack, OverModalContext, OverModalProvider, PageActionsHostContext, PageBadgeHostContext, PageInfo, PageInfoHostContext, PaginaLegal, Panel, Parrafo, PollingCountdownChip, PulseDot, RESPONSIVE_ACTION_MODES, ResponsiveActions, SIDE_PANEL_WIDTH_VAR, SaveCancelButton, Seccion, ServerGrid as ServerGrid_v2, SidePanelHostContext, StatusBadge, StickyPageHeaderContext, StyledMenu, StyledToggleButtonGroup, Subtitulo, TEXTOS, Tabs, Titulo, Transitions, TrueFalse, UncontrolledText, aplicarLocaleDeDayjs, buildEstadoTabs, changeTitle, closeProgressSnack, columnasDeCatalogo, composeGridProps, crearFabricaDeCatalogos, deleteColumn$1 as deleteColumn, deleteColumn as deleteColumn_v2, drawerZIndex, editColumn, filterQuery, filtersPanelFrameSx, formContainerSx, formGridSx, formParser, headerContainerSx, _default as headerReducer, localeDeNumeros, localeTextDeMUI, localeTextDeToolpad, manualCacheRefresh, mergeSettings, mutationData, mutationId, mutationParams, openProgressSnack, pageSizeOptions, query, renderChipCell, renderEditCellWithErrorTooltip, resolveChipOption, resolveInitialState, resolveStatusColor, setErrors, singularizarPalabra, singularizarTitulo, _default$1 as snackProgressReducer, statusColors, tags, theme, togglableFields, updateProgressSnackData, useAPI, useColorMode, useContentBorderRadius, useDetailForm, useHasPermission, useHasPermission_v2, useHiddenPageHeader, useHiddenPageHeaderHost, useKeyboardShortcut, useLocale, useMutationHandler, useNavigation, useOverModal, usePageActionsHost, usePageBadgeHost, usePageInfoHost, useServerGrid, useSidePanelHost, useStickyPageHeader, useStickyPageHeaderHost, useTextos, valueLabel };
|
|
5347
|
-
export type { APIcontextProps, AccountMenuContentProps, AccountMenuItem, AddressValue, AppTheme, AutocompleteOption, BuildEstadoTabsOptions, CSVMenuOptionProps, CatalogoAPI, CatalogoItemProps, CatalogoListProps, ChipCellProps, ChipColor, ChipOption, ColorMode, ComoOpcionesProps, ConfirmDialogProps, ControlledAutocompleteProps, ControlledInput, CrearCatalogoAPI, CustomFilterDef, CustomToolbarProps, DefinicionDeCatalogo, DeleteGridColumnsProps$1 as DeleteGridColumnsProps, DetachedPage, DetailExtraButton, DetailFormApi, DetailFormConfig, DetailFormController, DetailFormDialogProps, DetailFormDrawerNavigation, DetailFormDrawerProps, DetailFormProps, DetailFormStatus, DetailPageV2Props, DetailRenderProps, DrawerGridDrawerConfig, DrawerGridEditConfig, DrawerGridProps, EditGridColumnsProps, EditReadOnlyFields, EstadoDeFiltro, EstadoTabConfig, ExportCSVProps as ExportCSVProps_v2, ExtraCreateOptionProps, FieldFilter, FieldProps$1 as FieldProps, FieldValidationProps, FilterInput, FormBreakpoint, FormGridSxOptions, GlobalSearchOption, GlobalSearchProps, GridArgs, GridColDefPropsOverrides, GridLayerContribution, GridLayerId, GridLayerMap, GrillaHastaElFondoProps, HiddenPageHeaderHost, InsigniaDeCatalogo, JSONFormProps, JSONParserProps, KeyboardShortcut, KpiCardProps, ListaProps, Locale, LocaleContextProps, LocaleProviderProps, MainDrawerV2Props, MainLayoutFooterConfig, MainLayoutPageHeaderProps, MainLayoutProps, MainLayoutSidebarFooterProps, MutationArgs, MyDataGridProps, MyGridFilterModel, MyTab, MyTabProps, NotificationItemProps, NotificationsApi, NotificationsBellProps, PageActionsHost, PageBadgeHost, PageInfoHost, PageInfoProps, PageType, PaginaLegalProps, PanelProps, PollingCountdownChipProps, ProgressStatusProps, PulseDotProps, ResponsiveAction, ResponsiveActionsMode, ResponsiveActionsProps, RowsSnapshot, RutasDePaginaLegal, SeccionProps, ServerGridArgs, ServerGridCreateApi, ServerGridDataApi, ServerGridDeleteApi, ServerGridEditApi, ServerGridEditToggleApi, ServerGridHandle, ServerGridProps, ServerGridSnapshot, ServerGridState, SidePanelHost, StatusColor, StickyPageHeaderHost, Textos, TextosDePaginaLegal, UseColorModeResult, UseServerGridOptions };
|
|
5391
|
+
export type { APIcontextProps, AccountMenuContentProps, AccountMenuItem, AddressValue, AppTheme, AutocompleteOption, BuildEstadoTabsOptions, CSVMenuOptionProps, CatalogoAPI, CatalogoItemProps, CatalogoListProps, ChipCellProps, ChipColor, ChipOption, ColorMode, ComoOpcionesProps, ConfirmDialogProps, ControlledAutocompleteProps, ControlledInput, CrearCatalogoAPI, CustomFilterDef, CustomToolbarProps, DefinicionDeCatalogo, DeleteGridColumnsProps$1 as DeleteGridColumnsProps, DetachedPage, DetailExtraButton, DetailFormApi, DetailFormConfig, DetailFormController, DetailFormDialogProps, DetailFormDrawerNavigation, DetailFormDrawerProps, DetailFormProps, DetailFormStatus, DetailPageV2Props, DetailRenderProps, DrawerGridDrawerConfig, DrawerGridEditConfig, DrawerGridProps, EditGridColumnsProps, EditReadOnlyFields, EstadoDeFiltro, EstadoTabConfig, ExportCSVProps as ExportCSVProps_v2, ExtraButtonContext, ExtraCreateOptionProps, FieldFilter, FieldProps$1 as FieldProps, FieldValidationProps, FilterInput, FormBreakpoint, FormGridSxOptions, GlobalSearchOption, GlobalSearchProps, GridArgs, GridColDefPropsOverrides, GridLayerContribution, GridLayerId, GridLayerMap, GrillaHastaElFondoProps, HiddenPageHeaderHost, InsigniaDeCatalogo, JSONFormProps, JSONParserProps, KeyboardShortcut, KpiCardProps, ListaProps, Locale, LocaleContextProps, LocaleProviderProps, MainDrawerV2Props, MainLayoutFooterConfig, MainLayoutPageHeaderProps, MainLayoutProps, MainLayoutSidebarFooterProps, MutationArgs, MyDataGridProps, MyGridFilterModel, MyTab, MyTabProps, NotificationItemProps, NotificationsApi, NotificationsBellProps, PageActionsHost, PageBadgeHost, PageInfoHost, PageInfoProps, PageType, PaginaLegalProps, PanelProps, PollingCountdownChipProps, ProgressStatusProps, PulseDotProps, ResponsiveAction, ResponsiveActionsMode, ResponsiveActionsProps, RowsSnapshot, RutasDePaginaLegal, SeccionProps, ServerGridArgs, ServerGridCreateApi, ServerGridDataApi, ServerGridDeleteApi, ServerGridEditApi, ServerGridEditToggleApi, ServerGridHandle, ServerGridProps, ServerGridSnapshot, ServerGridState, SidePanelHost, StatusColor, StickyPageHeaderHost, Textos, TextosDePaginaLegal, UseColorModeResult, UseServerGridOptions };
|
package/package.json
CHANGED