Skip to content

Commit

Permalink
fix warnings for cell missing style
Browse files Browse the repository at this point in the history
Signed-off-by: Ihor Dykhta <dikhta.igor@gmail.com>
  • Loading branch information
igorDykhta committed Mar 1, 2025
1 parent 4d3fbc0 commit 0bd6c57
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/components/src/common/data-table/header-cell.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ type HeaderCellProps = {
props: DataTableProps;
toggleMoreOptions: (moreOptionsColumn: string) => void;
moreOptionsColumn: null | string;
style: CSSProperties;
};

const HeaderCellFactory = (FieldToken: React.FC<FieldTokenProps>) => {
Expand Down
4 changes: 4 additions & 0 deletions src/components/src/common/data-table/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -404,6 +404,8 @@ interface DataTableState {
showStats?: boolean;
}

const DUMMY_STYLE = {};

DataTableFactory.deps = [HeaderCellFactory];
function DataTableFactory(
HeaderCell: ReturnType<typeof HeaderCellFactory>
Expand Down Expand Up @@ -550,6 +552,8 @@ function DataTableFactory(
props={props}
toggleMoreOptions={toggleMoreOptions}
moreOptionsColumn={moreOptionsColumn}
// pass dummy style to prevent warnings from react-virtualized Grid
style={DUMMY_STYLE}
/>
);
return HeaderCellRenderer;
Expand Down

0 comments on commit 0bd6c57

Please sign in to comment.