@@ -13,7 +13,7 @@ import {Stack} from '../Stack';
1313import { Spinner } from '../Spinner' ;
1414import { Text } from '../Text' ;
1515import {
16- BulkActions ,
16+ BulkAction ,
1717 BulkActionsProps ,
1818 useIsBulkActionsSticky ,
1919} from '../BulkActions' ;
@@ -27,7 +27,7 @@ import {
2727} from '../../utilities/index-provider' ;
2828import { AfterInitialMount } from '../AfterInitialMount' ;
2929import { IndexProvider } from '../IndexProvider' ;
30- import type { NonEmptyArray } from '../../types' ;
30+ import type { ActionListSection , NonEmptyArray } from '../../types' ;
3131
3232import { getTableHeadingsBySelector } from './utilities' ;
3333import { ScrollContainer , Cell , Row } from './components' ;
@@ -62,7 +62,7 @@ interface IndexTableSortToggleLabels {
6262 [ key : number ] : IndexTableSortToggleLabel ;
6363}
6464
65- interface IndexTableHeadingCheckbox {
65+ export interface IndexTableHeadingCheckbox {
6666 label ?: string ;
6767 onChange ?: ( checked : boolean ) => unknown ;
6868 checked ?: boolean | 'indeterminate' ;
@@ -104,6 +104,11 @@ export interface IndexTableBaseProps {
104104 onboardingBadgeText ?: string ;
105105 undoText ?: string ;
106106 checkbox ?: ( props : IndexTableHeadingCheckbox ) => React . ReactNode ;
107+ renderBulkActions ?: ( {
108+ actions,
109+ } : {
110+ actions : ( BulkAction | ActionListSection ) [ ] ;
111+ } ) => React . ReactNode ;
107112}
108113
109114export interface TableHeadingRect {
@@ -137,6 +142,7 @@ function IndexTableBase({
137142 onboardingBadgeText,
138143 undoText,
139144 checkbox,
145+ renderBulkActions,
140146 ...restProps
141147} : IndexTableBaseProps ) {
142148 const {
@@ -531,7 +537,7 @@ function IndexTableBase({
531537 ) ;
532538
533539 const shouldShowActions = ! condensed || selectedItemsCount ;
534- const promotedActions = shouldShowActions ? promotedBulkActions : [ ] ;
540+ // const promotedActions = shouldShowActions ? promotedBulkActions : [];
535541 const actions = shouldShowActions ? bulkActions : [ ] ;
536542
537543 const bulkActionsMarkup =
@@ -548,14 +554,15 @@ function IndexTableBase({
548554 : undefined ,
549555 } }
550556 >
551- < BulkActions
557+ { renderBulkActions ?.( { actions} ) }
558+ { /* <BulkActions
552559 selectMode={selectMode}
553560 promotedActions={promotedActions}
554561 actions={actions}
555562 onSelectModeToggle={condensed ? handleSelectModeToggle : undefined}
556563 isSticky={isBulkActionsSticky}
557564 width={bulkActionsMaxWidth}
558- />
565+ /> */ }
559566 </ div >
560567 ) : null ;
561568
@@ -576,6 +583,7 @@ function IndexTableBase({
576583 onToggleAll = { handleTogglePage }
577584 paginatedSelectAllText = { paginatedSelectAllText }
578585 paginatedSelectAllAction = { paginatedSelectAllAction }
586+ checkbox = { checkbox }
579587 />
580588 { loadingMarkup }
581589 </ div >
@@ -834,9 +842,9 @@ function IndexTableBase({
834842 } ;
835843 }
836844
837- function handleSelectModeToggle ( ) {
838- handleSelectionChange ( SelectionType . All , false ) ;
839- }
845+ // function handleSelectModeToggle() {
846+ // handleSelectionChange(SelectionType.All, false);
847+ // }
840848}
841849
842850const isBreakpointsXS = ( ) => {
0 commit comments