🤖 Merge PR #46269 fix(carbon-components-react): update DataTableSkeleton props by @dabrad26

Add show props for header and toolbar per Carbon (https://react.carbondesignsystem.com/?path=/story/datatableskeleton--default)
This commit is contained in:
David Bradshaw 2020-07-23 13:06:59 -04:00 committed by GitHub
parent ecc0b38f36
commit 3bea70153a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 0 deletions

View File

@ -37,6 +37,7 @@ import {
ButtonRenderIconRenderProps,
Modal,
InlineLoading,
DataTableSkeleton,
} from 'carbon-components-react';
import Link from 'carbon-components-react/lib/components/UIShell/Link';
@ -630,3 +631,12 @@ const sideNavChildren = (
const modal = (
<Modal primaryButtonText={<InlineLoading />} secondaryButtonText={<InlineLoading />} />
)
// DataTableSkeleton
const dataTableSkeleton = (
<DataTableSkeleton showHeader={true} showToolbar={true} columnCount={5} rowCount={6} compact={false} zebra={false} />
);
const dataTableSkeletonBasic = (
<DataTableSkeleton />
);

View File

@ -12,6 +12,8 @@ export interface DataTableSkeletonProps extends InheritedProps {
columnCount?: number;
// headers?: ReadonlyArray<string> | ReadonlyArray<ShapeOf<HeaderType>>; // doesn't seem to be used anymore but prop type is still there so leaving this commented out.
rowCount?: number;
showHeader?: boolean;
showToolbar?: boolean;
zebra?: boolean;
}