react-data-grid
Advanced tools
Comparing version 7.0.0-beta.34 to 7.0.0-beta.35
@@ -10,2 +10,12 @@ /// <reference types="react" /> | ||
declare interface BaseRenderRowProps<TRow, TSummaryRow = unknown> extends Omit_2<React.HTMLAttributes<HTMLDivElement>, 'style' | 'children'>, Pick<DataGridProps<TRow, TSummaryRow>, 'onCellClick' | 'onCellDoubleClick' | 'onCellContextMenu'> { | ||
viewportColumns: readonly CalculatedColumn<TRow, TSummaryRow>[]; | ||
rowIdx: number; | ||
selectedCellIdx: number | undefined; | ||
isRowSelected: boolean; | ||
gridRowStart: number; | ||
height: number; | ||
selectCell: (position: Position, enableEditor?: Maybe<boolean>) => void; | ||
} | ||
export declare interface CalculatedColumn<TRow, TSummaryRow = unknown> extends Column<TRow, TSummaryRow> { | ||
@@ -20,3 +30,2 @@ readonly idx: number; | ||
readonly isLastFrozenColumn: boolean; | ||
readonly rowGroup: boolean; | ||
readonly renderCell: (props: RenderCellProps<TRow, TSummaryRow>) => ReactNode; | ||
@@ -152,3 +161,3 @@ } | ||
*/ | ||
rowHeight?: Maybe<number | ((args: RowHeightArgs<R>) => number)>; | ||
rowHeight?: Maybe<number | ((row: R) => number)>; | ||
/** | ||
@@ -175,6 +184,2 @@ * The height of the header row in pixels | ||
defaultColumnOptions?: Maybe<DefaultColumnOptions<R, SR>>; | ||
groupBy?: Maybe<readonly string[]>; | ||
rowGrouper?: Maybe<(rows: readonly R[], columnKey: string) => Record<string, readonly R[]>>; | ||
expandedGroupIds?: Maybe<ReadonlySet<unknown>>; | ||
onExpandedGroupIdsChange?: Maybe<(expandedGroupIds: Set<unknown>) => void>; | ||
onFill?: Maybe<(event: FillEvent<R>) => R>; | ||
@@ -315,13 +320,7 @@ onCopy?: Maybe<(event: CopyEvent<R>) => void>; | ||
export declare interface RenderRowProps<TRow, TSummaryRow = unknown> extends Omit_2<React.HTMLAttributes<HTMLDivElement>, 'style' | 'children'>, Pick<DataGridProps<TRow, TSummaryRow>, 'onCellClick' | 'onCellDoubleClick' | 'onCellContextMenu'> { | ||
viewportColumns: readonly CalculatedColumn<TRow, TSummaryRow>[]; | ||
export declare interface RenderRowProps<TRow, TSummaryRow = unknown> extends BaseRenderRowProps<TRow, TSummaryRow> { | ||
row: TRow; | ||
rowIdx: number; | ||
selectedCellIdx: number | undefined; | ||
lastFrozenColumnIndex: number; | ||
copiedCellIdx: number | undefined; | ||
draggedOverCellIdx: number | undefined; | ||
lastFrozenColumnIndex: number; | ||
isRowSelected: boolean; | ||
gridRowStart: number; | ||
height: number; | ||
selectedCellEditor: ReactElement<RenderEditCellProps<TRow>> | undefined; | ||
@@ -332,3 +331,2 @@ selectedCellDragHandle: ReactElement<React.HTMLAttributes<HTMLDivElement>> | undefined; | ||
setDraggedOverRowIdx: ((overRowIdx: number) => void) | undefined; | ||
selectCell: (position: Position, enableEditor?: Maybe<boolean>) => void; | ||
} | ||
@@ -405,3 +403,3 @@ | ||
declare type SharedDivProps = Pick<React.HTMLAttributes<HTMLDivElement>, 'aria-label' | 'aria-labelledby' | 'aria-describedby' | 'className' | 'style'>; | ||
declare type SharedDivProps = Pick<React.HTMLAttributes<HTMLDivElement>, 'role' | 'aria-label' | 'aria-labelledby' | 'aria-describedby' | 'aria-rowcount' | 'className' | 'style'>; | ||
@@ -421,4 +419,14 @@ declare type SharedInputProps = Pick<RenderCheckboxProps, 'disabled' | 'tabIndex' | 'aria-label' | 'aria-labelledby'>; | ||
export declare const TreeDataGrid: <R, SR = unknown, K extends Key = Key>(props: TreeDataGridProps<R, SR, K> & RefAttributes<DataGridHandle>) => JSX.Element; | ||
export declare interface TreeDataGridProps<R, SR = unknown, K extends Key = Key> extends Omit_2<DataGridProps<R, SR, K>, 'role' | 'aria-rowcount' | 'rowHeight' | 'onFill'> { | ||
rowHeight?: Maybe<number | ((args: RowHeightArgs<R>) => number)>; | ||
groupBy: readonly string[]; | ||
rowGrouper: (rows: readonly R[], columnKey: string) => Record<string, readonly R[]>; | ||
expandedGroupIds: ReadonlySet<unknown>; | ||
onExpandedGroupIdsChange: (expandedGroupIds: Set<unknown>) => void; | ||
} | ||
export declare function useRowSelection<R>(): [boolean, (selectRowEvent: SelectRowEvent<R>) => void]; | ||
export { } |
{ | ||
"name": "react-data-grid", | ||
"version": "7.0.0-beta.34", | ||
"version": "7.0.0-beta.35", | ||
"license": "MIT", | ||
@@ -43,3 +43,3 @@ "description": "Feature-rich and customizable data grid React component", | ||
"rome:ci": "rome ci .", | ||
"eslint": "eslint --ext js,ts,tsx --max-warnings 0 --cache --color src test website", | ||
"eslint": "eslint --ext js,ts,tsx --max-warnings 0 --cache --color src test website vite.config.ts", | ||
"eslint:fix": "npm run eslint -- --fix", | ||
@@ -53,3 +53,3 @@ "prettier:check": "prettier --check .", | ||
"dependencies": { | ||
"clsx": "^1.1.1" | ||
"clsx": "^2.0.0" | ||
}, | ||
@@ -64,8 +64,8 @@ "devDependencies": { | ||
"@faker-js/faker": "^8.0.0", | ||
"@ianvs/prettier-plugin-sort-imports": "^4.0.0", | ||
"@linaria/rollup": "^4.3.8", | ||
"@linaria/vite": "^4.2.11", | ||
"@ianvs/prettier-plugin-sort-imports": "^4.0.2", | ||
"@linaria/rollup": "^4.5.2", | ||
"@linaria/vite": "^4.5.2", | ||
"@microsoft/api-extractor": "^7.23.0", | ||
"@rollup/plugin-babel": "^6.0.3", | ||
"@rollup/plugin-node-resolve": "^15.0.0", | ||
"@rollup/plugin-node-resolve": "^15.1.0", | ||
"@testing-library/jest-dom": "^5.16.4", | ||
@@ -77,16 +77,16 @@ "@testing-library/react": "^14.0.0", | ||
"@types/react-dom": "^18.2.4", | ||
"@typescript-eslint/eslint-plugin": "^5.22.0", | ||
"@typescript-eslint/parser": "^5.22.0", | ||
"@vitejs/plugin-react": "^4.0.0", | ||
"@vitest/coverage-v8": "^0.32.0", | ||
"@typescript-eslint/eslint-plugin": "^6.1.0", | ||
"@typescript-eslint/parser": "^6.1.0", | ||
"@vitejs/plugin-react": "^4.0.2", | ||
"@vitest/coverage-v8": "^0.33.0", | ||
"babel-plugin-optimize-clsx": "^2.6.2", | ||
"eslint": "^8.14.0", | ||
"eslint-config-prettier": "^8.5.0", | ||
"eslint-plugin-jest": "^27.0.1", | ||
"eslint": "^8.43.0", | ||
"eslint-config-prettier": "^8.8.0", | ||
"eslint-plugin-jest": "^27.2.2", | ||
"eslint-plugin-jest-dom": "^5.0.1", | ||
"eslint-plugin-node": "^11.1.0", | ||
"eslint-plugin-react": "^7.29.4", | ||
"eslint-plugin-react-hooks": "^4.5.0", | ||
"eslint-plugin-react": "^7.32.2", | ||
"eslint-plugin-react-hooks": "^4.6.0", | ||
"eslint-plugin-sonarjs": "^0.19.0", | ||
"eslint-plugin-testing-library": "^5.9.1", | ||
"eslint-plugin-testing-library": "^5.11.0", | ||
"jsdom": "^22.0.0", | ||
@@ -96,5 +96,5 @@ "jspdf": "^2.5.1", | ||
"lodash-es": "^4.17.21", | ||
"postcss": "^8.4.23", | ||
"postcss-nested": "^6.0.0", | ||
"prettier": "2.8.8", | ||
"postcss": "^8.4.25", | ||
"postcss-nested": "^6.0.1", | ||
"prettier": "3.0.0", | ||
"react": "^18.1.0", | ||
@@ -105,8 +105,8 @@ "react-dnd": "^16.0.1", | ||
"react-router-dom": "^6.11.1", | ||
"rollup": "^3.21.5", | ||
"rollup": "^3.26.2", | ||
"rollup-plugin-postcss": "^4.0.2", | ||
"rome": "12.1.3", | ||
"typescript": "~5.1.3", | ||
"vite": "^4.3.5", | ||
"vitest": "^0.32.0" | ||
"typescript": "~5.1.6", | ||
"vite": "^4.4.2", | ||
"vitest": "^0.33.0" | ||
}, | ||
@@ -113,0 +113,0 @@ "peerDependencies": { |
@@ -150,3 +150,3 @@ # react-data-grid | ||
###### `rowHeight?: Maybe<number | ((args: RowHeightArgs<R>) => number)>` | ||
###### `rowHeight?: Maybe<number | ((row: R) => number)>` | ||
@@ -153,0 +153,0 @@ **Default:** `35` pixels |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
723187
6572
+ Addedclsx@2.1.1(transitive)
- Removedclsx@1.2.1(transitive)
Updatedclsx@^2.0.0