@mui/x-data-grid 8.16.0 → 8.17.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/CHANGELOG.md +108 -1
- package/colDef/gridCheckboxSelectionColDef.js +0 -2
- package/components/GridColumnSortButton.d.ts +1 -1
- package/components/GridFooter.d.ts +2 -3
- package/components/GridFooter.js +0 -2
- package/components/GridHeader.d.ts +1 -2
- package/components/GridHeaders.d.ts +1 -2
- package/components/GridHeaders.js +0 -2
- package/components/GridNoColumnsOverlay.d.ts +2 -3
- package/components/GridNoColumnsOverlay.js +0 -2
- package/components/GridNoResultsOverlay.d.ts +2 -3
- package/components/GridNoResultsOverlay.js +0 -2
- package/components/GridNoRowsOverlay.d.ts +2 -3
- package/components/GridNoRowsOverlay.js +0 -2
- package/components/GridPagination.d.ts +1 -2
- package/components/GridScrollArea.d.ts +1 -2
- package/components/GridScrollShadows.d.ts +1 -2
- package/components/GridScrollbarFillerCell.d.ts +1 -2
- package/components/GridScrollbarFillerCell.js +0 -2
- package/components/base/GridFooterPlaceholder.d.ts +1 -2
- package/components/base/GridFooterPlaceholder.js +0 -2
- package/components/base/GridOverlays.d.ts +1 -1
- package/components/cell/GridActionsCell.d.ts +2 -3
- package/components/cell/GridActionsCell.js +2 -0
- package/components/cell/GridActionsCellItem.js +5 -18
- package/components/cell/GridBooleanCell.d.ts +1 -1
- package/components/cell/GridCell.js +8 -1
- package/components/cell/GridEditBooleanCell.d.ts +2 -2
- package/components/cell/GridEditDateCell.d.ts +2 -2
- package/components/cell/GridEditInputCell.d.ts +1 -1
- package/components/cell/GridEditInputCell.js +0 -68
- package/components/cell/GridEditSingleSelectCell.d.ts +2 -3
- package/components/cell/GridSkeletonCell.d.ts +1 -1
- package/components/columnHeaders/ColumnHeaderMenuIcon.d.ts +1 -1
- package/components/columnHeaders/GridColumnGroupHeader.d.ts +1 -1
- package/components/columnHeaders/GridColumnHeaderFilterIconButton.d.ts +1 -1
- package/components/columnHeaders/GridColumnHeaderItem.d.ts +1 -1
- package/components/columnHeaders/GridColumnHeaderSeparator.d.ts +1 -1
- package/components/columnHeaders/GridColumnHeaderSortIcon.d.ts +1 -1
- package/components/columnHeaders/GridColumnHeaderTitle.d.ts +1 -1
- package/components/columnsManagement/GridColumnsManagement.d.ts +1 -2
- package/components/menu/GridMenu.d.ts +1 -1
- package/components/menu/columnMenu/GridColumnHeaderMenu.d.ts +1 -1
- package/components/menu/columnMenu/GridColumnMenu.d.ts +2 -3
- package/components/menu/columnMenu/GridColumnMenu.js +0 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuColumnsItem.d.ts +1 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuFilterItem.d.ts +1 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuHideItem.d.ts +1 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuManageItem.d.ts +1 -2
- package/components/menu/columnMenu/menuItems/GridColumnMenuSortItem.d.ts +1 -2
- package/components/panel/GridColumnsPanel.d.ts +1 -2
- package/components/panel/GridColumnsPanel.js +0 -2
- package/components/panel/GridPanelContent.d.ts +1 -1
- package/components/panel/GridPanelContext.d.ts +1 -1
- package/components/panel/GridPanelFooter.d.ts +1 -1
- package/components/panel/GridPanelHeader.d.ts +1 -1
- package/components/panel/GridPreferencesPanel.d.ts +1 -2
- package/components/panel/GridPreferencesPanel.js +0 -2
- package/components/panel/filterPanel/GridFilterInputBoolean.d.ts +1 -2
- package/components/panel/filterPanel/GridFilterInputDate.d.ts +1 -2
- package/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.d.ts +1 -2
- package/components/panel/filterPanel/GridFilterInputMultipleValue.d.ts +1 -2
- package/components/panel/filterPanel/GridFilterInputSingleSelect.d.ts +1 -2
- package/components/panel/filterPanel/GridFilterInputValue.d.ts +1 -2
- package/components/quickFilter/QuickFilter.d.ts +1 -1
- package/components/toolbar/GridToolbar.d.ts +1 -2
- package/components/toolbar/GridToolbar.js +0 -2
- package/components/toolbar/GridToolbarExport.d.ts +2 -2
- package/components/toolbar/GridToolbarQuickFilter.d.ts +1 -2
- package/components/toolbar/GridToolbarQuickFilter.js +0 -2
- package/components/toolbarV8/GridToolbar.d.ts +3 -3
- package/components/virtualization/GridBottomContainer.d.ts +1 -1
- package/components/virtualization/GridTopContainer.d.ts +1 -1
- package/components/virtualization/GridVirtualScroller.d.ts +1 -1
- package/components/virtualization/GridVirtualScrollerFiller.d.ts +1 -2
- package/context/GridContextProvider.d.ts +1 -1
- package/esm/colDef/gridCheckboxSelectionColDef.js +0 -1
- package/esm/components/GridColumnSortButton.d.ts +1 -1
- package/esm/components/GridFooter.d.ts +2 -3
- package/esm/components/GridFooter.js +0 -1
- package/esm/components/GridHeader.d.ts +1 -2
- package/esm/components/GridHeaders.d.ts +1 -2
- package/esm/components/GridHeaders.js +0 -1
- package/esm/components/GridNoColumnsOverlay.d.ts +2 -3
- package/esm/components/GridNoColumnsOverlay.js +0 -1
- package/esm/components/GridNoResultsOverlay.d.ts +2 -3
- package/esm/components/GridNoResultsOverlay.js +0 -1
- package/esm/components/GridNoRowsOverlay.d.ts +2 -3
- package/esm/components/GridNoRowsOverlay.js +0 -1
- package/esm/components/GridPagination.d.ts +1 -2
- package/esm/components/GridScrollArea.d.ts +1 -2
- package/esm/components/GridScrollShadows.d.ts +1 -2
- package/esm/components/GridScrollbarFillerCell.d.ts +1 -2
- package/esm/components/GridScrollbarFillerCell.js +0 -1
- package/esm/components/base/GridFooterPlaceholder.d.ts +1 -2
- package/esm/components/base/GridFooterPlaceholder.js +0 -1
- package/esm/components/base/GridOverlays.d.ts +1 -1
- package/esm/components/cell/GridActionsCell.d.ts +2 -3
- package/esm/components/cell/GridActionsCell.js +2 -0
- package/esm/components/cell/GridActionsCellItem.js +4 -17
- package/esm/components/cell/GridBooleanCell.d.ts +1 -1
- package/esm/components/cell/GridCell.js +8 -1
- package/esm/components/cell/GridEditBooleanCell.d.ts +2 -2
- package/esm/components/cell/GridEditDateCell.d.ts +2 -2
- package/esm/components/cell/GridEditInputCell.d.ts +1 -1
- package/esm/components/cell/GridEditInputCell.js +0 -68
- package/esm/components/cell/GridEditSingleSelectCell.d.ts +2 -3
- package/esm/components/cell/GridSkeletonCell.d.ts +1 -1
- package/esm/components/columnHeaders/ColumnHeaderMenuIcon.d.ts +1 -1
- package/esm/components/columnHeaders/GridColumnGroupHeader.d.ts +1 -1
- package/esm/components/columnHeaders/GridColumnHeaderFilterIconButton.d.ts +1 -1
- package/esm/components/columnHeaders/GridColumnHeaderItem.d.ts +1 -1
- package/esm/components/columnHeaders/GridColumnHeaderSeparator.d.ts +1 -1
- package/esm/components/columnHeaders/GridColumnHeaderSortIcon.d.ts +1 -1
- package/esm/components/columnHeaders/GridColumnHeaderTitle.d.ts +1 -1
- package/esm/components/columnsManagement/GridColumnsManagement.d.ts +1 -2
- package/esm/components/menu/GridMenu.d.ts +1 -1
- package/esm/components/menu/columnMenu/GridColumnHeaderMenu.d.ts +1 -1
- package/esm/components/menu/columnMenu/GridColumnMenu.d.ts +2 -3
- package/esm/components/menu/columnMenu/GridColumnMenu.js +0 -1
- package/esm/components/menu/columnMenu/menuItems/GridColumnMenuColumnsItem.d.ts +1 -2
- package/esm/components/menu/columnMenu/menuItems/GridColumnMenuFilterItem.d.ts +1 -2
- package/esm/components/menu/columnMenu/menuItems/GridColumnMenuHideItem.d.ts +1 -2
- package/esm/components/menu/columnMenu/menuItems/GridColumnMenuManageItem.d.ts +1 -2
- package/esm/components/menu/columnMenu/menuItems/GridColumnMenuSortItem.d.ts +1 -2
- package/esm/components/panel/GridColumnsPanel.d.ts +1 -2
- package/esm/components/panel/GridColumnsPanel.js +0 -1
- package/esm/components/panel/GridPanelContent.d.ts +1 -1
- package/esm/components/panel/GridPanelContext.d.ts +1 -1
- package/esm/components/panel/GridPanelFooter.d.ts +1 -1
- package/esm/components/panel/GridPanelHeader.d.ts +1 -1
- package/esm/components/panel/GridPreferencesPanel.d.ts +1 -2
- package/esm/components/panel/GridPreferencesPanel.js +0 -1
- package/esm/components/panel/filterPanel/GridFilterInputBoolean.d.ts +1 -2
- package/esm/components/panel/filterPanel/GridFilterInputDate.d.ts +1 -2
- package/esm/components/panel/filterPanel/GridFilterInputMultipleSingleSelect.d.ts +1 -2
- package/esm/components/panel/filterPanel/GridFilterInputMultipleValue.d.ts +1 -2
- package/esm/components/panel/filterPanel/GridFilterInputSingleSelect.d.ts +1 -2
- package/esm/components/panel/filterPanel/GridFilterInputValue.d.ts +1 -2
- package/esm/components/quickFilter/QuickFilter.d.ts +1 -1
- package/esm/components/toolbar/GridToolbar.d.ts +1 -2
- package/esm/components/toolbar/GridToolbar.js +0 -1
- package/esm/components/toolbar/GridToolbarExport.d.ts +2 -2
- package/esm/components/toolbar/GridToolbarQuickFilter.d.ts +1 -2
- package/esm/components/toolbar/GridToolbarQuickFilter.js +0 -1
- package/esm/components/toolbarV8/GridToolbar.d.ts +3 -3
- package/esm/components/virtualization/GridBottomContainer.d.ts +1 -1
- package/esm/components/virtualization/GridTopContainer.d.ts +1 -1
- package/esm/components/virtualization/GridVirtualScroller.d.ts +1 -1
- package/esm/components/virtualization/GridVirtualScrollerFiller.d.ts +1 -2
- package/esm/context/GridContextProvider.d.ts +1 -1
- package/esm/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +2 -2
- package/esm/hooks/features/pagination/useGridPaginationModel.js +5 -3
- package/esm/index.js +1 -1
- package/esm/internals/demo/TailwindDemoContainer.d.ts +1 -1
- package/esm/locales/arSD.js +12 -12
- package/esm/locales/caES.d.ts +2 -0
- package/esm/locales/caES.js +291 -0
- package/esm/locales/index.d.ts +1 -0
- package/esm/locales/index.js +1 -0
- package/esm/material/icons/index.d.ts +0 -1
- package/esm/material/icons/index.js +0 -1
- package/esm/utils/css/context.d.ts +3 -3
- package/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +2 -2
- package/hooks/features/pagination/useGridPaginationModel.js +5 -3
- package/index.js +1 -1
- package/internals/demo/TailwindDemoContainer.d.ts +1 -1
- package/locales/arSD.js +12 -12
- package/locales/caES.d.ts +2 -0
- package/locales/caES.js +297 -0
- package/locales/index.d.ts +1 -0
- package/locales/index.js +11 -0
- package/material/icons/index.d.ts +0 -1
- package/material/icons/index.js +0 -2
- package/package.json +3 -3
- package/utils/css/context.d.ts +3 -3
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
3
|
const _excluded = ["className", "csvOptions", "printOptions", "excelOptions", "showQuickFilter", "quickFilterProps"];
|
|
4
|
-
import * as React from 'react';
|
|
5
4
|
import PropTypes from 'prop-types';
|
|
6
5
|
import { forwardRef } from '@mui/x-internals/forwardRef';
|
|
7
6
|
import { GridToolbarContainer } from "../containers/GridToolbarContainer.js";
|
|
@@ -27,11 +27,11 @@ export interface GridToolbarExportProps {
|
|
|
27
27
|
};
|
|
28
28
|
[x: `data-${string}`]: string;
|
|
29
29
|
}
|
|
30
|
-
declare function GridCsvExportMenuItem(props: GridCsvExportMenuItemProps):
|
|
30
|
+
declare function GridCsvExportMenuItem(props: GridCsvExportMenuItemProps): import("react/jsx-runtime").JSX.Element;
|
|
31
31
|
declare namespace GridCsvExportMenuItem {
|
|
32
32
|
var propTypes: any;
|
|
33
33
|
}
|
|
34
|
-
declare function GridPrintExportMenuItem(props: GridPrintExportMenuItemProps):
|
|
34
|
+
declare function GridPrintExportMenuItem(props: GridPrintExportMenuItemProps): import("react/jsx-runtime").JSX.Element;
|
|
35
35
|
declare namespace GridPrintExportMenuItem {
|
|
36
36
|
var propTypes: any;
|
|
37
37
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import { TextFieldProps } from "../../models/gridBaseSlots.js";
|
|
3
2
|
import { GridFilterModel } from "../../models/gridFilterModel.js";
|
|
4
3
|
export type GridToolbarQuickFilterProps = {
|
|
@@ -31,7 +30,7 @@ export type GridToolbarQuickFilterProps = {
|
|
|
31
30
|
/**
|
|
32
31
|
* @deprecated Use the {@link https://mui.com/x/react-data-grid/components/quick-filter/ Quick Filter} component instead. This component will be removed in a future major release.
|
|
33
32
|
*/
|
|
34
|
-
declare function GridToolbarQuickFilter(props: GridToolbarQuickFilterProps):
|
|
33
|
+
declare function GridToolbarQuickFilter(props: GridToolbarQuickFilterProps): import("react/jsx-runtime").JSX.Element;
|
|
35
34
|
declare namespace GridToolbarQuickFilter {
|
|
36
35
|
var propTypes: any;
|
|
37
36
|
}
|
|
@@ -2,7 +2,6 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
2
2
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
3
|
const _excluded = ["quickFilterParser", "quickFilterFormatter", "debounceMs", "className", "slotProps"],
|
|
4
4
|
_excluded2 = ["ref", "slotProps"];
|
|
5
|
-
import * as React from 'react';
|
|
6
5
|
import PropTypes from 'prop-types';
|
|
7
6
|
import composeClasses from '@mui/utils/composeClasses';
|
|
8
7
|
import { styled } from '@mui/system';
|
|
@@ -5,12 +5,12 @@ interface GridToolbarInternalProps {
|
|
|
5
5
|
additionalExportMenuItems?: (onMenuItemClick: () => void) => React.ReactNode;
|
|
6
6
|
}
|
|
7
7
|
export type GridToolbarProps = GridSlotProps['toolbar'] & GridToolbarInternalProps;
|
|
8
|
-
declare function GridToolbarDivider(props: GridSlotProps['baseDivider']):
|
|
8
|
+
declare function GridToolbarDivider(props: GridSlotProps['baseDivider']): import("react/jsx-runtime").JSX.Element;
|
|
9
9
|
declare namespace GridToolbarDivider {
|
|
10
10
|
var propTypes: any;
|
|
11
11
|
}
|
|
12
|
-
declare function GridToolbarLabel(props: React.HTMLAttributes<HTMLSpanElement>):
|
|
13
|
-
declare function GridToolbar(props: GridToolbarProps):
|
|
12
|
+
declare function GridToolbarLabel(props: React.HTMLAttributes<HTMLSpanElement>): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
declare function GridToolbar(props: GridToolbarProps): import("react/jsx-runtime").JSX.Element;
|
|
14
14
|
declare namespace GridToolbar {
|
|
15
15
|
var propTypes: any;
|
|
16
16
|
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
export type GridBottomContainerProps = React.PropsWithChildren;
|
|
3
|
-
export declare function GridBottomContainer(props: GridBottomContainerProps):
|
|
3
|
+
export declare function GridBottomContainer(props: GridBottomContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
export declare function GridTopContainer(props: React.PropsWithChildren):
|
|
2
|
+
export declare function GridTopContainer(props: React.PropsWithChildren): import("react/jsx-runtime").JSX.Element;
|
|
@@ -2,5 +2,5 @@ import * as React from 'react';
|
|
|
2
2
|
export interface GridVirtualScrollerProps {
|
|
3
3
|
children?: React.ReactNode;
|
|
4
4
|
}
|
|
5
|
-
declare function GridVirtualScroller(props: GridVirtualScrollerProps):
|
|
5
|
+
declare function GridVirtualScroller(props: GridVirtualScrollerProps): import("react/jsx-runtime").JSX.Element;
|
|
6
6
|
export { GridVirtualScroller };
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
type Props = {
|
|
3
2
|
/** The number of rows */
|
|
4
3
|
rowsLength: number;
|
|
5
4
|
};
|
|
6
5
|
declare function GridVirtualScrollerFiller({
|
|
7
6
|
rowsLength
|
|
8
|
-
}: Props):
|
|
7
|
+
}: Props): import("react/jsx-runtime").JSX.Element | null;
|
|
9
8
|
declare const Memoized: typeof GridVirtualScrollerFiller;
|
|
10
9
|
export { Memoized as GridVirtualScrollerFiller };
|
|
@@ -48,8 +48,8 @@ export declare const useGridColumnHeaders: (props: UseGridColumnHeadersProps) =>
|
|
|
48
48
|
};
|
|
49
49
|
visibleColumns: GridStateColDef[];
|
|
50
50
|
columnPositions: number[];
|
|
51
|
-
getFillers: (params: GetHeadersParams | undefined, children: React.ReactNode, leftOverflow: number, borderBottom?: boolean) =>
|
|
52
|
-
getColumnHeadersRow: () =>
|
|
51
|
+
getFillers: (params: GetHeadersParams | undefined, children: React.ReactNode, leftOverflow: number, borderBottom?: boolean) => import("react/jsx-runtime").JSX.Element;
|
|
52
|
+
getColumnHeadersRow: () => import("react/jsx-runtime").JSX.Element;
|
|
53
53
|
getColumnsToRender: (params?: GetHeadersParams) => {
|
|
54
54
|
renderedColumns: GridStateColDef[];
|
|
55
55
|
firstColumnToRender: number;
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
4
|
import * as React from 'react';
|
|
5
|
+
import debounce from '@mui/utils/debounce';
|
|
5
6
|
import { isDeepEqual } from '@mui/x-internals/isDeepEqual';
|
|
6
7
|
import { gridFilterModelSelector, gridFilterActiveItemsSelector } from "../filter/gridFilterSelector.js";
|
|
7
8
|
import { gridDensityFactorSelector } from "../density/index.js";
|
|
@@ -174,6 +175,7 @@ export const useGridPaginationModel = (apiRef, props) => {
|
|
|
174
175
|
});
|
|
175
176
|
}
|
|
176
177
|
}, [apiRef]);
|
|
178
|
+
const debouncedNavigateToStart = React.useMemo(() => debounce(navigateToStart, 0), [navigateToStart]);
|
|
177
179
|
|
|
178
180
|
/**
|
|
179
181
|
* Resets the page only if the active items or quick filter has changed from the last time.
|
|
@@ -190,12 +192,12 @@ export const useGridPaginationModel = (apiRef, props) => {
|
|
|
190
192
|
return;
|
|
191
193
|
}
|
|
192
194
|
previousFilterModel.current = currentActiveFilters;
|
|
193
|
-
|
|
194
|
-
}, [apiRef,
|
|
195
|
+
debouncedNavigateToStart();
|
|
196
|
+
}, [apiRef, debouncedNavigateToStart]);
|
|
195
197
|
useGridEvent(apiRef, 'viewportInnerSizeChange', handleUpdateAutoPageSize);
|
|
196
198
|
useGridEvent(apiRef, 'paginationModelChange', handlePaginationModelChange);
|
|
197
199
|
useGridEvent(apiRef, 'rowCountChange', handleRowCountChange);
|
|
198
|
-
useGridEvent(apiRef, 'sortModelChange',
|
|
200
|
+
useGridEvent(apiRef, 'sortModelChange', debouncedNavigateToStart);
|
|
199
201
|
useGridEvent(apiRef, 'filterModelChange', handleFilterModelChange);
|
|
200
202
|
|
|
201
203
|
/**
|
package/esm/index.js
CHANGED
|
@@ -7,5 +7,5 @@ interface TailwindDemoContainerProps {
|
|
|
7
7
|
* WARNING: This is an internal component used in documentation to inject the Tailwind script.
|
|
8
8
|
* Please do not use it in your application.
|
|
9
9
|
*/
|
|
10
|
-
export declare function TailwindDemoContainer(props: TailwindDemoContainerProps): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> |
|
|
10
|
+
export declare function TailwindDemoContainer(props: TailwindDemoContainerProps): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
11
11
|
export {};
|
package/esm/locales/arSD.js
CHANGED
|
@@ -160,18 +160,18 @@ const arSDGrid = {
|
|
|
160
160
|
collapseDetailPanel: 'طوي',
|
|
161
161
|
// Pagination
|
|
162
162
|
paginationRowsPerPage: 'عدد الصفوف في الصفحة:',
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
163
|
+
paginationDisplayedRows: ({
|
|
164
|
+
from,
|
|
165
|
+
to,
|
|
166
|
+
count,
|
|
167
|
+
estimated
|
|
168
|
+
}) => {
|
|
169
|
+
if (!estimated) {
|
|
170
|
+
return `\u200E${to}-${from}\u200E من ${count !== -1 ? count : `أكثر من ${to}`}`;
|
|
171
|
+
}
|
|
172
|
+
const estimatedLabel = estimated && estimated > to ? `حوالي ${estimated}` : `أكثر من ${to}`;
|
|
173
|
+
return `\u200E${to}-${from}\u200E من ${count !== -1 ? count : estimatedLabel}`;
|
|
174
|
+
},
|
|
175
175
|
paginationItemAriaLabel: type => {
|
|
176
176
|
if (type === 'first') {
|
|
177
177
|
return 'انتقل إلى الصفحة الأولى';
|
|
@@ -0,0 +1,291 @@
|
|
|
1
|
+
import { getGridLocalization } from "../utils/getGridLocalization.js";
|
|
2
|
+
const caESGrid = {
|
|
3
|
+
// Root
|
|
4
|
+
noRowsLabel: 'Sense files',
|
|
5
|
+
noResultsOverlayLabel: "No s'han trobat resultats",
|
|
6
|
+
noColumnsOverlayLabel: 'Cap columna',
|
|
7
|
+
noColumnsOverlayManageColumns: 'Gestiona les columnes',
|
|
8
|
+
emptyPivotOverlayLabel: 'Afegiu camps a files, columnes i valors per crear una taula dinàmica',
|
|
9
|
+
// Density selector toolbar button text
|
|
10
|
+
toolbarDensity: 'Densitat',
|
|
11
|
+
toolbarDensityLabel: 'Densitat',
|
|
12
|
+
toolbarDensityCompact: 'Compacta',
|
|
13
|
+
toolbarDensityStandard: 'Estàndard',
|
|
14
|
+
toolbarDensityComfortable: 'Còmoda',
|
|
15
|
+
// Columns selector toolbar button text
|
|
16
|
+
toolbarColumns: 'Columnes',
|
|
17
|
+
toolbarColumnsLabel: 'Selecciona columnes',
|
|
18
|
+
// Filters toolbar button text
|
|
19
|
+
toolbarFilters: 'Filtres',
|
|
20
|
+
toolbarFiltersLabel: 'Mostra filtres',
|
|
21
|
+
toolbarFiltersTooltipHide: 'Amaga filtres',
|
|
22
|
+
toolbarFiltersTooltipShow: 'Mostra filtres',
|
|
23
|
+
toolbarFiltersTooltipActive: count => count > 1 ? `${count} filtres actius` : `${count} filtre actiu`,
|
|
24
|
+
// Quick filter toolbar field
|
|
25
|
+
toolbarQuickFilterPlaceholder: 'Cerca…',
|
|
26
|
+
toolbarQuickFilterLabel: 'Cerca',
|
|
27
|
+
toolbarQuickFilterDeleteIconLabel: 'Neteja',
|
|
28
|
+
// Export selector toolbar button text
|
|
29
|
+
toolbarExport: 'Exporta',
|
|
30
|
+
toolbarExportLabel: 'Exporta',
|
|
31
|
+
toolbarExportCSV: 'Baixa com a CSV',
|
|
32
|
+
toolbarExportPrint: 'Imprimeix',
|
|
33
|
+
toolbarExportExcel: 'Baixa com a Excel',
|
|
34
|
+
// Toolbar pivot button
|
|
35
|
+
toolbarPivot: 'Taula dinàmica',
|
|
36
|
+
// Toolbar charts button
|
|
37
|
+
toolbarCharts: 'Gràfics',
|
|
38
|
+
// Toolbar AI Assistant button
|
|
39
|
+
toolbarAssistant: "Assistent d'IA",
|
|
40
|
+
// Columns management text
|
|
41
|
+
columnsManagementSearchTitle: 'Cerca',
|
|
42
|
+
columnsManagementNoColumns: 'Sense columnes',
|
|
43
|
+
columnsManagementShowHideAllText: 'Mostra/Amaga-ho tot',
|
|
44
|
+
columnsManagementReset: 'Restableix',
|
|
45
|
+
columnsManagementDeleteIconLabel: 'Neteja',
|
|
46
|
+
// Filter panel text
|
|
47
|
+
filterPanelAddFilter: 'Afegeix filtre',
|
|
48
|
+
filterPanelRemoveAll: "Elimina'ls tots",
|
|
49
|
+
filterPanelDeleteIconLabel: 'Esborra',
|
|
50
|
+
filterPanelLogicOperator: 'Operador lògic',
|
|
51
|
+
filterPanelOperator: 'Operadors',
|
|
52
|
+
filterPanelOperatorAnd: 'I',
|
|
53
|
+
filterPanelOperatorOr: 'O',
|
|
54
|
+
filterPanelColumns: 'Columnes',
|
|
55
|
+
filterPanelInputLabel: 'Valor',
|
|
56
|
+
filterPanelInputPlaceholder: 'Valor del filtre',
|
|
57
|
+
// Filter operators text
|
|
58
|
+
filterOperatorContains: 'conté',
|
|
59
|
+
filterOperatorDoesNotContain: 'no conté',
|
|
60
|
+
filterOperatorEquals: 'és igual a',
|
|
61
|
+
filterOperatorDoesNotEqual: 'no és igual a',
|
|
62
|
+
filterOperatorStartsWith: 'comença per',
|
|
63
|
+
filterOperatorEndsWith: 'acaba en',
|
|
64
|
+
filterOperatorIs: 'és',
|
|
65
|
+
filterOperatorNot: 'no és',
|
|
66
|
+
filterOperatorAfter: 'és posterior',
|
|
67
|
+
filterOperatorOnOrAfter: 'és igual o posterior',
|
|
68
|
+
filterOperatorBefore: 'és anterior',
|
|
69
|
+
filterOperatorOnOrBefore: 'és igual o anterior',
|
|
70
|
+
filterOperatorIsEmpty: 'està buit',
|
|
71
|
+
filterOperatorIsNotEmpty: 'no està buit',
|
|
72
|
+
filterOperatorIsAnyOf: 'és qualsevol de',
|
|
73
|
+
'filterOperator=': '=',
|
|
74
|
+
'filterOperator!=': '!=',
|
|
75
|
+
'filterOperator>': '>',
|
|
76
|
+
'filterOperator>=': '>=',
|
|
77
|
+
'filterOperator<': '<',
|
|
78
|
+
'filterOperator<=': '<=',
|
|
79
|
+
// Header filter operators text
|
|
80
|
+
headerFilterOperatorContains: 'Conté',
|
|
81
|
+
headerFilterOperatorDoesNotContain: 'No conté',
|
|
82
|
+
headerFilterOperatorEquals: 'És igual a',
|
|
83
|
+
headerFilterOperatorDoesNotEqual: 'No és igual a',
|
|
84
|
+
headerFilterOperatorStartsWith: 'Comença per',
|
|
85
|
+
headerFilterOperatorEndsWith: 'Acaba en',
|
|
86
|
+
headerFilterOperatorIs: 'És',
|
|
87
|
+
headerFilterOperatorNot: 'No és',
|
|
88
|
+
headerFilterOperatorAfter: 'És posterior a',
|
|
89
|
+
headerFilterOperatorOnOrAfter: 'És igual o posterior a',
|
|
90
|
+
headerFilterOperatorBefore: 'És anterior a',
|
|
91
|
+
headerFilterOperatorOnOrBefore: 'És igual o anterior a',
|
|
92
|
+
headerFilterOperatorIsEmpty: 'Està buit',
|
|
93
|
+
headerFilterOperatorIsNotEmpty: 'No està buit',
|
|
94
|
+
headerFilterOperatorIsAnyOf: 'És qualsevol de',
|
|
95
|
+
'headerFilterOperator=': 'És igual a',
|
|
96
|
+
'headerFilterOperator!=': 'No és igual a',
|
|
97
|
+
'headerFilterOperator>': 'És més gran que',
|
|
98
|
+
'headerFilterOperator>=': 'És més gran o igual que',
|
|
99
|
+
'headerFilterOperator<': 'És més petit que',
|
|
100
|
+
'headerFilterOperator<=': 'És més petit o igual que',
|
|
101
|
+
headerFilterClear: 'Neteja filtres',
|
|
102
|
+
// Filter values text
|
|
103
|
+
filterValueAny: 'qualsevol',
|
|
104
|
+
filterValueTrue: 'veritable',
|
|
105
|
+
filterValueFalse: 'fals',
|
|
106
|
+
// Column menu text
|
|
107
|
+
columnMenuLabel: 'Menú',
|
|
108
|
+
columnMenuAriaLabel: columnName => `Menú de la columna ${columnName}`,
|
|
109
|
+
columnMenuShowColumns: 'Mostra columnes',
|
|
110
|
+
columnMenuManageColumns: 'Gestiona columnes',
|
|
111
|
+
columnMenuFilter: 'Filtre',
|
|
112
|
+
columnMenuHideColumn: 'Amaga',
|
|
113
|
+
columnMenuUnsort: 'Desordena',
|
|
114
|
+
columnMenuSortAsc: 'Ordena ASC',
|
|
115
|
+
columnMenuSortDesc: 'Ordena DESC',
|
|
116
|
+
columnMenuManagePivot: 'Gestiona la taula dinàmica',
|
|
117
|
+
columnMenuManageCharts: 'Gestiona els gràfics',
|
|
118
|
+
// Column header text
|
|
119
|
+
columnHeaderFiltersTooltipActive: count => count > 1 ? `${count} filtres actius` : `${count} filtre actiu`,
|
|
120
|
+
columnHeaderFiltersLabel: 'Mostra filtres',
|
|
121
|
+
columnHeaderSortIconLabel: 'Ordena',
|
|
122
|
+
// Rows selected footer text
|
|
123
|
+
footerRowSelected: count => count > 1 ? `${count.toLocaleString()} files seleccionades` : `${count.toLocaleString()} fila seleccionada`,
|
|
124
|
+
// Total row amount footer text
|
|
125
|
+
footerTotalRows: 'Files totals:',
|
|
126
|
+
// Total visible row amount footer text
|
|
127
|
+
footerTotalVisibleRows: (visibleCount, totalCount) => `${visibleCount.toLocaleString()} de ${totalCount.toLocaleString()}`,
|
|
128
|
+
// Checkbox selection text
|
|
129
|
+
checkboxSelectionHeaderName: 'Casella de selecció',
|
|
130
|
+
checkboxSelectionSelectAllRows: 'Selecciona totes les files',
|
|
131
|
+
checkboxSelectionUnselectAllRows: 'Desselecciona totes les files',
|
|
132
|
+
checkboxSelectionSelectRow: 'Selecciona fila',
|
|
133
|
+
checkboxSelectionUnselectRow: 'Desselecciona fila',
|
|
134
|
+
// Boolean cell text
|
|
135
|
+
booleanCellTrueLabel: 'sí',
|
|
136
|
+
booleanCellFalseLabel: 'no',
|
|
137
|
+
// Actions cell more text
|
|
138
|
+
actionsCellMore: 'més',
|
|
139
|
+
// Column pinning text
|
|
140
|
+
pinToLeft: "Fixa a l'esquerra",
|
|
141
|
+
pinToRight: 'Fixa a la dreta',
|
|
142
|
+
unpin: 'Desfixa',
|
|
143
|
+
// Tree Data
|
|
144
|
+
treeDataGroupingHeaderName: 'Grup',
|
|
145
|
+
treeDataExpand: 'mostra fills',
|
|
146
|
+
treeDataCollapse: 'amaga fills',
|
|
147
|
+
// Grouping columns
|
|
148
|
+
groupingColumnHeaderName: 'Grup',
|
|
149
|
+
groupColumn: name => `Agrupa per ${name}`,
|
|
150
|
+
unGroupColumn: name => `No agrupis per ${name}`,
|
|
151
|
+
// Master/detail
|
|
152
|
+
detailPanelToggle: 'Alterna detall',
|
|
153
|
+
expandDetailPanel: 'Expandeix',
|
|
154
|
+
collapseDetailPanel: 'Contrau',
|
|
155
|
+
// Pagination
|
|
156
|
+
paginationRowsPerPage: 'Files per pàgina:',
|
|
157
|
+
paginationDisplayedRows: ({
|
|
158
|
+
from,
|
|
159
|
+
to,
|
|
160
|
+
count,
|
|
161
|
+
estimated
|
|
162
|
+
}) => {
|
|
163
|
+
if (!estimated) {
|
|
164
|
+
return `${from}–${to} de ${count !== -1 ? count : `més de ${to}`}`;
|
|
165
|
+
}
|
|
166
|
+
const estimatedLabel = estimated && estimated > to ? `al voltant de ${estimated}` : `més de ${to}`;
|
|
167
|
+
return `${from}–${to} de ${count !== -1 ? count : estimatedLabel}`;
|
|
168
|
+
},
|
|
169
|
+
paginationItemAriaLabel: type => {
|
|
170
|
+
if (type === 'first') {
|
|
171
|
+
return 'Vés a la primera pàgina';
|
|
172
|
+
}
|
|
173
|
+
if (type === 'last') {
|
|
174
|
+
return "Vés a l'última pàgina";
|
|
175
|
+
}
|
|
176
|
+
if (type === 'next') {
|
|
177
|
+
return 'Vés a la pàgina següent';
|
|
178
|
+
}
|
|
179
|
+
// if (type === 'previous') {
|
|
180
|
+
return 'Vés a la pàgina anterior';
|
|
181
|
+
},
|
|
182
|
+
// Row reordering text
|
|
183
|
+
rowReorderingHeaderName: 'Reordena files',
|
|
184
|
+
// Aggregation
|
|
185
|
+
aggregationMenuItemHeader: 'Agregació',
|
|
186
|
+
aggregationFunctionLabelNone: 'cap',
|
|
187
|
+
aggregationFunctionLabelSum: 'suma',
|
|
188
|
+
aggregationFunctionLabelAvg: 'mitjana',
|
|
189
|
+
aggregationFunctionLabelMin: 'mínim',
|
|
190
|
+
aggregationFunctionLabelMax: 'màxim',
|
|
191
|
+
aggregationFunctionLabelSize: 'recompte',
|
|
192
|
+
// Pivot panel
|
|
193
|
+
pivotToggleLabel: 'Taula dinàmica',
|
|
194
|
+
pivotRows: 'Files',
|
|
195
|
+
pivotColumns: 'Columnes',
|
|
196
|
+
pivotValues: 'Valors',
|
|
197
|
+
pivotCloseButton: 'Tanca la configuració de taula dinàmica',
|
|
198
|
+
pivotSearchButton: 'Camps de cerca',
|
|
199
|
+
pivotSearchControlPlaceholder: 'Camps de cerca',
|
|
200
|
+
pivotSearchControlLabel: 'Camps de cerca',
|
|
201
|
+
pivotSearchControlClear: 'Neteja la cerca',
|
|
202
|
+
pivotNoFields: 'Cap camp',
|
|
203
|
+
pivotMenuMoveUp: 'Mou amunt',
|
|
204
|
+
pivotMenuMoveDown: 'Mou avall',
|
|
205
|
+
pivotMenuMoveToTop: 'Mou al principi',
|
|
206
|
+
pivotMenuMoveToBottom: 'Mou al final',
|
|
207
|
+
pivotMenuRows: 'Files',
|
|
208
|
+
pivotMenuColumns: 'Columnes',
|
|
209
|
+
pivotMenuValues: 'Valors',
|
|
210
|
+
pivotMenuOptions: 'Opcions del camp',
|
|
211
|
+
pivotMenuAddToRows: 'Afegeix a files',
|
|
212
|
+
pivotMenuAddToColumns: 'Afegeix a columnes',
|
|
213
|
+
pivotMenuAddToValues: 'Afegeix a valors',
|
|
214
|
+
pivotMenuRemove: 'Elimina',
|
|
215
|
+
pivotDragToRows: 'Arrossega aquí per crear files',
|
|
216
|
+
pivotDragToColumns: 'Arrossega aquí per crear columnes',
|
|
217
|
+
pivotDragToValues: 'Arrossega aquí per crear valors',
|
|
218
|
+
pivotYearColumnHeaderName: '(Any)',
|
|
219
|
+
pivotQuarterColumnHeaderName: '(Trimestre)',
|
|
220
|
+
// Charts configuration panel
|
|
221
|
+
chartsNoCharts: 'No hi ha cap gràfic disponible',
|
|
222
|
+
chartsChartNotSelected: 'Selecciona un tipus de gràfic per configurar les seves opcions',
|
|
223
|
+
chartsTabChart: 'Gràfic',
|
|
224
|
+
chartsTabFields: 'Camps',
|
|
225
|
+
chartsTabCustomize: 'Personalitza',
|
|
226
|
+
chartsCloseButton: 'Tanca la configuració de gràfics',
|
|
227
|
+
chartsSyncButtonLabel: 'Sincronitza gràfic',
|
|
228
|
+
chartsSearchPlaceholder: 'Camps de cerca',
|
|
229
|
+
chartsSearchLabel: 'Camps de cerca',
|
|
230
|
+
chartsSearchClear: 'Neteja la cerca',
|
|
231
|
+
chartsNoFields: 'Cap camp',
|
|
232
|
+
chartsFieldBlocked: 'Aquest camp no es pot afegir a cap secció',
|
|
233
|
+
chartsCategories: 'Categories',
|
|
234
|
+
chartsSeries: 'Sèries',
|
|
235
|
+
chartsMenuAddToDimensions: dimensionLabel => `Afegeix a ${dimensionLabel}`,
|
|
236
|
+
chartsMenuAddToValues: valuesLabel => `Afegeix a ${valuesLabel}`,
|
|
237
|
+
chartsMenuMoveUp: 'Mou amunt',
|
|
238
|
+
chartsMenuMoveDown: 'Mou avall',
|
|
239
|
+
chartsMenuMoveToTop: 'Mou al principi',
|
|
240
|
+
chartsMenuMoveToBottom: 'Mou al final',
|
|
241
|
+
chartsMenuOptions: 'Opcions del camp',
|
|
242
|
+
chartsMenuRemove: 'Elimina',
|
|
243
|
+
chartsDragToDimensions: dimensionLabel => `Arrossega aquí per utilitzar la columna com a ${dimensionLabel}`,
|
|
244
|
+
chartsDragToValues: valuesLabel => `Arrossega aquí per utilitzar la columna com a ${valuesLabel}`,
|
|
245
|
+
// AI Assistant panel
|
|
246
|
+
aiAssistantPanelTitle: "Assistent d'IA",
|
|
247
|
+
aiAssistantPanelClose: "Tanca l'assistent d'IA",
|
|
248
|
+
aiAssistantPanelNewConversation: 'Nova conversa',
|
|
249
|
+
aiAssistantPanelConversationHistory: 'Historial de converses',
|
|
250
|
+
aiAssistantPanelEmptyConversation: "L'historial de converses és buit",
|
|
251
|
+
aiAssistantSuggestions: 'Suggeriments',
|
|
252
|
+
// Prompt field
|
|
253
|
+
promptFieldLabel: 'Petició',
|
|
254
|
+
promptFieldPlaceholder: 'Escriu una petició…',
|
|
255
|
+
promptFieldPlaceholderWithRecording: 'Escriu o enregistra una petició…',
|
|
256
|
+
promptFieldPlaceholderListening: 'Esperant una petició…',
|
|
257
|
+
promptFieldSpeechRecognitionNotSupported: 'El reconeixement de veu no és compatible amb aquest navegador',
|
|
258
|
+
promptFieldSend: 'Envia',
|
|
259
|
+
promptFieldRecord: 'Enregistra',
|
|
260
|
+
promptFieldStopRecording: "Atura l'enregistrament",
|
|
261
|
+
// Prompt
|
|
262
|
+
promptRerun: 'Torna a executar',
|
|
263
|
+
promptProcessing: 'Processant…',
|
|
264
|
+
promptAppliedChanges: "S'han aplicat els canvis",
|
|
265
|
+
// Prompt changes
|
|
266
|
+
promptChangeGroupDescription: column => `Agrupa per ${column}`,
|
|
267
|
+
promptChangeAggregationLabel: (column, aggregation) => `${column} (${aggregation})`,
|
|
268
|
+
promptChangeAggregationDescription: (column, aggregation) => `Agrega ${column} (${aggregation})`,
|
|
269
|
+
promptChangeFilterLabel: (column, operator, value) => {
|
|
270
|
+
if (operator === 'is any of') {
|
|
271
|
+
return `${column} és un de: ${value}`;
|
|
272
|
+
}
|
|
273
|
+
return `${column} ${operator} ${value}`;
|
|
274
|
+
},
|
|
275
|
+
promptChangeFilterDescription: (column, operator, value) => {
|
|
276
|
+
if (operator === 'is any of') {
|
|
277
|
+
return `Filtra per ${column} quan sigui un de: ${value}`;
|
|
278
|
+
}
|
|
279
|
+
return `Filtra per ${column} ${operator} ${value}`;
|
|
280
|
+
},
|
|
281
|
+
promptChangeSortDescription: (column, direction) => `Ordena per ${column} (${direction})`,
|
|
282
|
+
promptChangePivotEnableLabel: 'Taula dinàmica',
|
|
283
|
+
promptChangePivotEnableDescription: 'Activa la taula dinàmica',
|
|
284
|
+
promptChangePivotColumnsLabel: count => `Columnes (${count})`,
|
|
285
|
+
promptChangePivotColumnsDescription: (column, direction) => `${column}${direction ? ` (${direction})` : ''}`,
|
|
286
|
+
promptChangePivotRowsLabel: count => `Files (${count})`,
|
|
287
|
+
promptChangePivotValuesLabel: count => `Valors (${count})`,
|
|
288
|
+
promptChangePivotValuesDescription: (column, aggregation) => `${column} (${aggregation})`,
|
|
289
|
+
promptChangeChartsLabel: (dimensionsCount, valuesCount) => `Dimensions (${dimensionsCount}), Valors (${valuesCount})`
|
|
290
|
+
};
|
|
291
|
+
export const caES = getGridLocalization(caESGrid);
|
package/esm/locales/index.d.ts
CHANGED
package/esm/locales/index.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
export declare const GridArrowUpwardIcon: (props: import("@mui/x-data-grid").GridBaseIconProps) => React.ReactNode;
|
|
3
2
|
export declare const GridArrowDownwardIcon: (props: import("@mui/x-data-grid").GridBaseIconProps) => React.ReactNode;
|
|
4
3
|
export declare const GridKeyboardArrowRight: (props: import("@mui/x-data-grid").GridBaseIconProps) => React.ReactNode;
|
|
@@ -2,13 +2,13 @@ import * as React from 'react';
|
|
|
2
2
|
export declare function useCSSVariablesClass(): string;
|
|
3
3
|
export declare function useCSSVariablesContext(): {
|
|
4
4
|
className: string;
|
|
5
|
-
tag:
|
|
5
|
+
tag: import("react/jsx-runtime").JSX.Element;
|
|
6
6
|
};
|
|
7
7
|
export declare function GridPortalWrapper({
|
|
8
8
|
children
|
|
9
9
|
}: {
|
|
10
10
|
children: React.ReactNode;
|
|
11
|
-
}):
|
|
11
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
export declare function GridCSSVariablesContext(props: {
|
|
13
13
|
children: any;
|
|
14
|
-
}):
|
|
14
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -48,8 +48,8 @@ export declare const useGridColumnHeaders: (props: UseGridColumnHeadersProps) =>
|
|
|
48
48
|
};
|
|
49
49
|
visibleColumns: GridStateColDef[];
|
|
50
50
|
columnPositions: number[];
|
|
51
|
-
getFillers: (params: GetHeadersParams | undefined, children: React.ReactNode, leftOverflow: number, borderBottom?: boolean) =>
|
|
52
|
-
getColumnHeadersRow: () =>
|
|
51
|
+
getFillers: (params: GetHeadersParams | undefined, children: React.ReactNode, leftOverflow: number, borderBottom?: boolean) => import("react/jsx-runtime").JSX.Element;
|
|
52
|
+
getColumnHeadersRow: () => import("react/jsx-runtime").JSX.Element;
|
|
53
53
|
getColumnsToRender: (params?: GetHeadersParams) => {
|
|
54
54
|
renderedColumns: GridStateColDef[];
|
|
55
55
|
firstColumnToRender: number;
|
|
@@ -9,6 +9,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
9
9
|
exports.useGridPaginationModel = exports.getDerivedPaginationModel = void 0;
|
|
10
10
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
11
|
var React = _interopRequireWildcard(require("react"));
|
|
12
|
+
var _debounce = _interopRequireDefault(require("@mui/utils/debounce"));
|
|
12
13
|
var _isDeepEqual = require("@mui/x-internals/isDeepEqual");
|
|
13
14
|
var _gridFilterSelector = require("../filter/gridFilterSelector");
|
|
14
15
|
var _density = require("../density");
|
|
@@ -182,6 +183,7 @@ const useGridPaginationModel = (apiRef, props) => {
|
|
|
182
183
|
});
|
|
183
184
|
}
|
|
184
185
|
}, [apiRef]);
|
|
186
|
+
const debouncedNavigateToStart = React.useMemo(() => (0, _debounce.default)(navigateToStart, 0), [navigateToStart]);
|
|
185
187
|
|
|
186
188
|
/**
|
|
187
189
|
* Resets the page only if the active items or quick filter has changed from the last time.
|
|
@@ -198,12 +200,12 @@ const useGridPaginationModel = (apiRef, props) => {
|
|
|
198
200
|
return;
|
|
199
201
|
}
|
|
200
202
|
previousFilterModel.current = currentActiveFilters;
|
|
201
|
-
|
|
202
|
-
}, [apiRef,
|
|
203
|
+
debouncedNavigateToStart();
|
|
204
|
+
}, [apiRef, debouncedNavigateToStart]);
|
|
203
205
|
(0, _utils.useGridEvent)(apiRef, 'viewportInnerSizeChange', handleUpdateAutoPageSize);
|
|
204
206
|
(0, _utils.useGridEvent)(apiRef, 'paginationModelChange', handlePaginationModelChange);
|
|
205
207
|
(0, _utils.useGridEvent)(apiRef, 'rowCountChange', handleRowCountChange);
|
|
206
|
-
(0, _utils.useGridEvent)(apiRef, 'sortModelChange',
|
|
208
|
+
(0, _utils.useGridEvent)(apiRef, 'sortModelChange', debouncedNavigateToStart);
|
|
207
209
|
(0, _utils.useGridEvent)(apiRef, 'filterModelChange', handleFilterModelChange);
|
|
208
210
|
|
|
209
211
|
/**
|
package/index.js
CHANGED
|
@@ -7,5 +7,5 @@ interface TailwindDemoContainerProps {
|
|
|
7
7
|
* WARNING: This is an internal component used in documentation to inject the Tailwind script.
|
|
8
8
|
* Please do not use it in your application.
|
|
9
9
|
*/
|
|
10
|
-
export declare function TailwindDemoContainer(props: TailwindDemoContainerProps): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> |
|
|
10
|
+
export declare function TailwindDemoContainer(props: TailwindDemoContainerProps): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
11
11
|
export {};
|
package/locales/arSD.js
CHANGED
|
@@ -166,18 +166,18 @@ const arSDGrid = {
|
|
|
166
166
|
collapseDetailPanel: 'طوي',
|
|
167
167
|
// Pagination
|
|
168
168
|
paginationRowsPerPage: 'عدد الصفوف في الصفحة:',
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
169
|
+
paginationDisplayedRows: ({
|
|
170
|
+
from,
|
|
171
|
+
to,
|
|
172
|
+
count,
|
|
173
|
+
estimated
|
|
174
|
+
}) => {
|
|
175
|
+
if (!estimated) {
|
|
176
|
+
return `\u200E${to}-${from}\u200E من ${count !== -1 ? count : `أكثر من ${to}`}`;
|
|
177
|
+
}
|
|
178
|
+
const estimatedLabel = estimated && estimated > to ? `حوالي ${estimated}` : `أكثر من ${to}`;
|
|
179
|
+
return `\u200E${to}-${from}\u200E من ${count !== -1 ? count : estimatedLabel}`;
|
|
180
|
+
},
|
|
181
181
|
paginationItemAriaLabel: type => {
|
|
182
182
|
if (type === 'first') {
|
|
183
183
|
return 'انتقل إلى الصفحة الأولى';
|