Skip to content

Commit

Permalink
chore(AnalyticalTable): remove busyIndicatorEnabled prop (#617)
Browse files Browse the repository at this point in the history
BREAKING CHANGE: remove  prop `busyIndicatorEnabled` as it is somehow duplicate to `loading`. The visibility of the busy indicator is now solely controlled by the prop `loading`.
  • Loading branch information
MarcusNotheis authored Jul 23, 2020
1 parent 17ed544 commit ff287cf
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ import { FlexBoxJustifyContent } from '@ui5/webcomponents-react/lib/FlexBoxJusti
}
],
title: 'Table Title',
busyIndicatorEnabled: true,
sortable: true,
filterable: true,
visibleRows: 15,
Expand Down Expand Up @@ -135,7 +134,6 @@ import { FlexBoxJustifyContent } from '@ui5/webcomponents-react/lib/FlexBoxJusti
data={args.data}
columns={args.columns}
loading={args.loading}
busyIndicatorEnabled={args.busyIndicatorEnabled}
alternateRowColor={args.alternateRowColor}
sortable={args.sortable}
filterable={args.filterable}
Expand Down Expand Up @@ -283,7 +281,6 @@ This even works if you resize the browser window!
data={args.dataTree}
columns={args.columns}
loading={args.loading}
busyIndicatorEnabled={args.busyIndicatorEnabled}
sortable={args.sortable}
filterable={args.filterable}
visibleRows={args.visibleRows}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,6 @@ describe('AnalyticalTable', () => {
data={dataTree}
columns={columns}
loading={false}
busyIndicatorEnabled={true}
sortable={true}
filterable={true}
visibleRows={15}
Expand Down
7 changes: 1 addition & 6 deletions packages/main/src/components/AnalyticalTable/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ export interface TableProps extends CommonProps {
minRows?: number;
visibleRows?: number;
loading?: boolean;
busyIndicatorEnabled?: boolean;
noDataText?: string;
rowHeight?: number;
alternateRowColor?: boolean;
Expand Down Expand Up @@ -143,7 +142,6 @@ const AnalyticalTable: FC<TableProps> = forwardRef((props: TableProps, ref: Ref<
onSort,
reactTableOptions,
tableHooks,
busyIndicatorEnabled,
subRowsKey,
onGroup,
rowHeight,
Expand Down Expand Up @@ -403,9 +401,7 @@ const AnalyticalTable: FC<TableProps> = forwardRef((props: TableProps, ref: Ref<
</header>
);
})}
{loading && busyIndicatorEnabled && props.data?.length > 0 && (
<LoadingComponent style={{ width: `${totalColumnsWidth}px` }} />
)}
{loading && props.data?.length > 0 && <LoadingComponent style={{ width: `${totalColumnsWidth}px` }} />}
{loading && props.data?.length === 0 && (
<TablePlaceholder
columns={tableInternalColumns.filter(
Expand Down Expand Up @@ -448,7 +444,6 @@ const AnalyticalTable: FC<TableProps> = forwardRef((props: TableProps, ref: Ref<
AnalyticalTable.displayName = 'AnalyticalTable';
AnalyticalTable.defaultProps = {
loading: false,
busyIndicatorEnabled: true,
sortable: true,
filterable: false,
groupable: false,
Expand Down

0 comments on commit ff287cf

Please sign in to comment.