[8.0][RAC] 19482 t grid fix always show checkboxes (#119608)

* Add showCheckboxes prop

* Hide leading checkboxes from Alerts page and updates the tests.

* Skip tests

* Skip test

* Testing FLAKY tls alert

* Remove exclusive test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
This commit is contained in:
Faisal Kanout 2021-11-30 16:21:20 +03:00 committed by GitHub
parent de1ed18832
commit d69aa8b200
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 13 additions and 6 deletions

View file

@ -122,6 +122,7 @@ interface OwnProps {
ruleProducer?: string;
}) => boolean;
totalSelectAllAlerts?: number;
showCheckboxes?: boolean;
}
const defaultUnit = (n: number) => i18n.ALERTS_UNIT(n);

View file

@ -118,6 +118,7 @@ export interface TGridStandaloneProps {
bulkActions?: BulkActionsProp;
data?: DataPublicPluginStart;
unit?: (total: number) => React.ReactNode;
showCheckboxes?: boolean;
}
const TGridStandaloneComponent: React.FC<TGridStandaloneProps> = ({
@ -151,6 +152,7 @@ const TGridStandaloneComponent: React.FC<TGridStandaloneProps> = ({
trailingControlColumns,
data,
unit,
showCheckboxes = true,
}) => {
const dispatch = useDispatch();
const columnsHeader = isEmpty(columns) ? defaultHeaders : columns;
@ -320,7 +322,7 @@ const TGridStandaloneComponent: React.FC<TGridStandaloneProps> = ({
indexNames,
itemsPerPage: itemsPerPageStore,
itemsPerPageOptions,
showCheckboxes: true,
showCheckboxes,
})
);
dispatch(
@ -406,6 +408,7 @@ const TGridStandaloneComponent: React.FC<TGridStandaloneProps> = ({
unit={unit}
filterStatus={filterStatus}
trailingControlColumns={trailingControlColumns}
showCheckboxes={showCheckboxes}
/>
</ScrollableFlexItem>
</FullWidthFlexGroup>