@acvl/frontend-components 0.0.107 → 0.0.108
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 +40 -4
- 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);
|
|
@@ -3796,6 +3822,12 @@ interface ServerGridState {
|
|
|
3796
3822
|
rows: readonly any[];
|
|
3797
3823
|
rowCount: number;
|
|
3798
3824
|
permissions: ServerGridPermissions;
|
|
3825
|
+
/**
|
|
3826
|
+
* Where the bulk delete of these rows goes, as the backend advertises it in the list
|
|
3827
|
+
* response — only to superusers, only for the resource whose rows these are. Absent, the
|
|
3828
|
+
* grid doesn't offer it.
|
|
3829
|
+
*/
|
|
3830
|
+
eliminarVarios?: string;
|
|
3799
3831
|
isLoading: boolean;
|
|
3800
3832
|
isFetching: boolean;
|
|
3801
3833
|
isError: boolean;
|
|
@@ -4180,8 +4212,11 @@ interface DrawerGridDrawerConfig {
|
|
|
4180
4212
|
create?: ReactNode;
|
|
4181
4213
|
record?: ReactNode | ((id: GridRowId) => ReactNode);
|
|
4182
4214
|
};
|
|
4183
|
-
/**
|
|
4184
|
-
|
|
4215
|
+
/**
|
|
4216
|
+
* Create-mode API (opened by the "Quick create" menu option). Without it the drawer has no
|
|
4217
|
+
* create mode: the grid's create option keeps its full-page route.
|
|
4218
|
+
*/
|
|
4219
|
+
create?: {
|
|
4185
4220
|
mutation: any;
|
|
4186
4221
|
/** Defaults to `"create"`. */
|
|
4187
4222
|
pageType?: PageType;
|
|
@@ -4191,7 +4226,8 @@ interface DrawerGridDrawerConfig {
|
|
|
4191
4226
|
record: {
|
|
4192
4227
|
/** Single-record query hook, called with `{ id, ...args(id) }`. */
|
|
4193
4228
|
query: any;
|
|
4194
|
-
|
|
4229
|
+
/** Without it the record is read-only: the drawer never offers to edit it. */
|
|
4230
|
+
mutation?: any;
|
|
4195
4231
|
/**
|
|
4196
4232
|
* Defaults to `"detail"` (read-only), matching a row-click. Use `"edit"` for an always
|
|
4197
4233
|
* editable drawer — a `"detail"` drawer already opens editing while the grid itself is
|
package/package.json
CHANGED