diff --git a/modules/docs/mdx/10.0-UPGRADE_GUIDE.mdx b/modules/docs/mdx/10.0-UPGRADE_GUIDE.mdx index 7f940705ce..8dab599244 100644 --- a/modules/docs/mdx/10.0-UPGRADE_GUIDE.mdx +++ b/modules/docs/mdx/10.0-UPGRADE_GUIDE.mdx @@ -13,6 +13,7 @@ any questions. - [useBanner](#useBanner) - [Deprecations](#deprecations) - [InputIconContainer](#input-icon-container) + - [Table](#table) - [Token Updates](#token-updates) - [Space and Depth](#space-and-depth) - [Component Updates](#component-updates) @@ -70,6 +71,10 @@ and browsers can compute the name of the Banner from the text given inside. We've deprecated `InputIconContainer` from [Main](#main) because it doesn't handle bidirectionality or icons at the start of an input. Please consider using [`InputGroup`](https://workday.github.io/canvas-kit/?path=/story/components-inputs-text-input--icons) instead. +### Table + +We've deprecated `Table` and `TableRow` as well as all of their exported members. Please consider using [`Table in Preview`](https://workday.github.io/canvas-kit/?path=/docs/preview-table--basic) instead. + ## Token Updates ### Space and Depth diff --git a/modules/react/table/lib/Table.tsx b/modules/react/table/lib/Table.tsx index 863b2651e9..a9bfcfc464 100644 --- a/modules/react/table/lib/Table.tsx +++ b/modules/react/table/lib/Table.tsx @@ -16,6 +16,10 @@ const TableComponent = styled('table')(type.levels.subtext.large, { }, }); +/** + * @deprecated ⚠️ `Table` has been deprecated and will be removed in a future major version. + * Please consider using [`Table in Preview`](https://workday.github.io/canvas-kit/?path=/docs/preview-table--basic) instead. + */ export class Table extends React.Component> { public render() { const {children, ...elemProps} = this.props; diff --git a/modules/react/table/lib/TableRow.tsx b/modules/react/table/lib/TableRow.tsx index dfa8c85325..245f154b54 100644 --- a/modules/react/table/lib/TableRow.tsx +++ b/modules/react/table/lib/TableRow.tsx @@ -5,6 +5,10 @@ import {colors, space, spaceNumbers, statusColors} from '@workday/canvas-kit-rea import {createComponent, StyledType} from '@workday/canvas-kit-react/common'; import {borderColor, borderWidth, cellBorder} from './Table'; +/** + * @deprecated ⚠️ `Table` has been deprecated and will be removed in a future major version. + * Please consider using [`Table in Preview`](https://workday.github.io/canvas-kit/?path=/docs/preview-table--basic) instead. + */ export enum TableRowState { Error, Alert, @@ -14,6 +18,10 @@ export enum TableRowState { Selected, } +/** + * @deprecated ⚠️ `Table` has been deprecated and will be removed in a future major version. + * Please consider using [`Table in Preview`](https://workday.github.io/canvas-kit/?path=/docs/preview-table--basic) instead. + */ export interface TableRowProps extends React.HTMLAttributes { /** * The state of the TableRow. Accepts `Error`, `Alert`, `InputError`, `InputAlert`, `Hover`, or `Selected`. @@ -192,6 +200,10 @@ const StyledTableRow = styled('tr')( } ); +/** + * @deprecated ⚠️ `Table` has been deprecated and will be removed in a future major version. + * Please consider using [`Table in Preview`](https://workday.github.io/canvas-kit/?path=/docs/preview-table--basic) instead. + */ export const TableRow = createComponent('tr')({ displayName: 'TableRow', Component: (