@razorpay/blade 12.42.2 → 12.43.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/lib/native/components/Input/TextInput/TextInput.js +1 -1
- package/build/lib/native/components/Input/TextInput/TextInput.js.map +1 -1
- package/build/lib/native/components/Table/TableContext.js +1 -1
- package/build/lib/native/components/Table/TableContext.js.map +1 -1
- package/build/lib/native/components/Table/tokens.js.map +1 -1
- package/build/lib/web/development/components/Input/TextInput/TextInput.js +0 -1
- package/build/lib/web/development/components/Input/TextInput/TextInput.js.map +1 -1
- package/build/lib/web/development/components/InputGroup/InputRow.web.js +4 -3
- package/build/lib/web/development/components/InputGroup/InputRow.web.js.map +1 -1
- package/build/lib/web/development/components/Table/Table.web.js +39 -8
- package/build/lib/web/development/components/Table/Table.web.js.map +1 -1
- package/build/lib/web/development/components/Table/TableBody.web.js +82 -14
- package/build/lib/web/development/components/Table/TableBody.web.js.map +1 -1
- package/build/lib/web/development/components/Table/TableContext.js +2 -1
- package/build/lib/web/development/components/Table/TableContext.js.map +1 -1
- package/build/lib/web/development/components/Table/TableFooter.web.js +15 -3
- package/build/lib/web/development/components/Table/TableFooter.web.js.map +1 -1
- package/build/lib/web/development/components/Table/TableHeader.web.js +15 -3
- package/build/lib/web/development/components/Table/TableHeader.web.js.map +1 -1
- package/build/lib/web/development/components/Table/tokens.js +4 -2
- package/build/lib/web/development/components/Table/tokens.js.map +1 -1
- package/build/lib/web/production/components/Input/TextInput/TextInput.js +0 -1
- package/build/lib/web/production/components/Input/TextInput/TextInput.js.map +1 -1
- package/build/lib/web/production/components/InputGroup/InputRow.web.js +4 -3
- package/build/lib/web/production/components/InputGroup/InputRow.web.js.map +1 -1
- package/build/lib/web/production/components/Table/Table.web.js +39 -8
- package/build/lib/web/production/components/Table/Table.web.js.map +1 -1
- package/build/lib/web/production/components/Table/TableBody.web.js +82 -14
- package/build/lib/web/production/components/Table/TableBody.web.js.map +1 -1
- package/build/lib/web/production/components/Table/TableContext.js +2 -1
- package/build/lib/web/production/components/Table/TableContext.js.map +1 -1
- package/build/lib/web/production/components/Table/TableFooter.web.js +15 -3
- package/build/lib/web/production/components/Table/TableFooter.web.js.map +1 -1
- package/build/lib/web/production/components/Table/TableHeader.web.js +15 -3
- package/build/lib/web/production/components/Table/TableHeader.web.js.map +1 -1
- package/build/lib/web/production/components/Table/tokens.js +4 -2
- package/build/lib/web/production/components/Table/tokens.js.map +1 -1
- package/build/types/components/index.d.ts +48 -8
- package/build/types/components/index.native.d.ts +43 -3
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TableContext.js","sources":["../../../../../../src/components/Table/TableContext.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-empty-function */\n// eslint-disable-next-line @typescript-eslint/no-empty-function\nimport React from 'react';\nimport type { TableNode } from '@table-library/react-table-library/table';\nimport type {\n TableBackgroundColors,\n TableProps,\n TablePaginationType,\n TableHeaderRowProps,\n TableNode as LocalTableNode,\n} from './types';\n\nexport type TableContextType<Item> = {\n selectionType?: TableProps<unknown>['selectionType'];\n selectedRows?: TableNode['id'][];\n totalItems: number;\n toggleRowSelectionById: (id: TableNode['id']) => void;\n toggleAllRowsSelection: () => void;\n deselectAllRows: () => void;\n rowDensity: NonNullable<TableProps<unknown>['rowDensity']>;\n toggleSort: (sortKey: string) => void;\n currentSortedState: {\n sortKey: string;\n isSortReversed: boolean;\n sortableColumns?: string[];\n };\n setPaginationPage: (page: number) => void;\n setPaginationRowSize: (size: number) => void;\n currentPaginationState?: {\n page: number;\n size: number;\n };\n showStripedRows?: boolean;\n disabledRows: TableNode['id'][];\n setDisabledRows: React.Dispatch<React.SetStateAction<TableNode['id'][]>>;\n paginationType: NonNullable<TablePaginationType>;\n setPaginationType: React.Dispatch<React.SetStateAction<NonNullable<TablePaginationType>>>;\n backgroundColor: TableBackgroundColors | 'transparent';\n headerRowDensity?: TableHeaderRowProps['rowDensity'];\n setHeaderRowDensity: React.Dispatch<React.SetStateAction<TableHeaderRowProps['rowDensity']>>;\n showBorderedCells: NonNullable<TableProps<unknown>['showBorderedCells']>;\n hasHoverActions: boolean;\n setHasHoverActions: (hasHoverActions: boolean) => void;\n columnCount: number;\n gridTemplateColumns: string | undefined;\n isVirtualized?: boolean;\n tableData: LocalTableNode<Item>[];\n};\n\nconst TableContext = React.createContext<TableContextType<unknown>>({\n selectionType: 'none',\n selectedRows: undefined,\n totalItems: 0,\n toggleRowSelectionById: () => {},\n toggleAllRowsSelection: () => {},\n deselectAllRows: () => {},\n rowDensity: 'normal',\n toggleSort: () => {},\n currentSortedState: {\n sortKey: '',\n isSortReversed: false,\n },\n setPaginationPage: () => {},\n setPaginationRowSize: () => {},\n disabledRows: [],\n setDisabledRows: () => {},\n paginationType: 'client',\n setPaginationType: () => {},\n backgroundColor: 'surface.background.gray.intense',\n setHeaderRowDensity: () => {},\n showBorderedCells: false,\n hasHoverActions: false,\n setHasHoverActions: () => {},\n columnCount: 0,\n gridTemplateColumns: undefined,\n isVirtualized: false,\n tableData: [],\n});\n\nconst useTableContext = <Item,>(): TableContextType<Item> => {\n const context = React.useContext(TableContext as React.Context<TableContextType<Item>>);\n return context;\n};\n\nexport { useTableContext, TableContext };\n"],"names":["TableContext","React","createContext","selectionType","selectedRows","undefined","totalItems","toggleRowSelectionById","toggleAllRowsSelection","deselectAllRows","rowDensity","toggleSort","currentSortedState","sortKey","isSortReversed","setPaginationPage","setPaginationRowSize","disabledRows","setDisabledRows","paginationType","setPaginationType","backgroundColor","setHeaderRowDensity","showBorderedCells","hasHoverActions","setHasHoverActions","columnCount","gridTemplateColumns","isVirtualized","tableData","useTableContext","context","useContext"],"mappings":";;AAAA;AACA;
|
|
1
|
+
{"version":3,"file":"TableContext.js","sources":["../../../../../../src/components/Table/TableContext.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-empty-function */\n// eslint-disable-next-line @typescript-eslint/no-empty-function\nimport React from 'react';\nimport type { TableNode } from '@table-library/react-table-library/table';\nimport type {\n TableBackgroundColors,\n TableProps,\n TablePaginationType,\n TableHeaderRowProps,\n TableNode as LocalTableNode,\n} from './types';\n\nexport type TableContextType<Item> = {\n selectionType?: TableProps<unknown>['selectionType'];\n selectedRows?: TableNode['id'][];\n totalItems: number;\n toggleRowSelectionById: (id: TableNode['id']) => void;\n toggleAllRowsSelection: () => void;\n deselectAllRows: () => void;\n rowDensity: NonNullable<TableProps<unknown>['rowDensity']>;\n toggleSort: (sortKey: string) => void;\n currentSortedState: {\n sortKey: string;\n isSortReversed: boolean;\n sortableColumns?: string[];\n };\n setPaginationPage: (page: number) => void;\n setPaginationRowSize: (size: number) => void;\n currentPaginationState?: {\n page: number;\n size: number;\n };\n showStripedRows?: boolean;\n disabledRows: TableNode['id'][];\n setDisabledRows: React.Dispatch<React.SetStateAction<TableNode['id'][]>>;\n paginationType: NonNullable<TablePaginationType>;\n setPaginationType: React.Dispatch<React.SetStateAction<NonNullable<TablePaginationType>>>;\n backgroundColor: TableBackgroundColors | 'transparent';\n headerRowDensity?: TableHeaderRowProps['rowDensity'];\n setHeaderRowDensity: React.Dispatch<React.SetStateAction<TableHeaderRowProps['rowDensity']>>;\n showBorderedCells: NonNullable<TableProps<unknown>['showBorderedCells']>;\n hasHoverActions: boolean;\n setHasHoverActions: (hasHoverActions: boolean) => void;\n columnCount: number;\n gridTemplateColumns: string | undefined;\n isVirtualized?: boolean;\n tableData: LocalTableNode<Item>[];\n isGrouped: boolean;\n};\n\nconst TableContext = React.createContext<TableContextType<unknown>>({\n selectionType: 'none',\n selectedRows: undefined,\n totalItems: 0,\n toggleRowSelectionById: () => {},\n toggleAllRowsSelection: () => {},\n deselectAllRows: () => {},\n rowDensity: 'normal',\n toggleSort: () => {},\n currentSortedState: {\n sortKey: '',\n isSortReversed: false,\n },\n setPaginationPage: () => {},\n setPaginationRowSize: () => {},\n disabledRows: [],\n setDisabledRows: () => {},\n paginationType: 'client',\n setPaginationType: () => {},\n backgroundColor: 'surface.background.gray.intense',\n setHeaderRowDensity: () => {},\n showBorderedCells: false,\n hasHoverActions: false,\n setHasHoverActions: () => {},\n columnCount: 0,\n gridTemplateColumns: undefined,\n isVirtualized: false,\n tableData: [],\n isGrouped: false,\n});\n\nconst useTableContext = <Item,>(): TableContextType<Item> => {\n const context = React.useContext(TableContext as React.Context<TableContextType<Item>>);\n return context;\n};\n\nexport { useTableContext, TableContext };\n"],"names":["TableContext","React","createContext","selectionType","selectedRows","undefined","totalItems","toggleRowSelectionById","toggleAllRowsSelection","deselectAllRows","rowDensity","toggleSort","currentSortedState","sortKey","isSortReversed","setPaginationPage","setPaginationRowSize","disabledRows","setDisabledRows","paginationType","setPaginationType","backgroundColor","setHeaderRowDensity","showBorderedCells","hasHoverActions","setHasHoverActions","columnCount","gridTemplateColumns","isVirtualized","tableData","isGrouped","useTableContext","context","useContext"],"mappings":";;AAAA;AACA;AAiDA,IAAMA,YAAY,gBAAGC,cAAK,CAACC,aAAa,CAA4B;AAClEC,EAAAA,aAAa,EAAE,MAAM;AACrBC,EAAAA,YAAY,EAAEC,SAAS;AACvBC,EAAAA,UAAU,EAAE,CAAC;AACbC,EAAAA,sBAAsB,EAAE,SAAAA,sBAAA,GAAM,EAAE;AAChCC,EAAAA,sBAAsB,EAAE,SAAAA,sBAAA,GAAM,EAAE;AAChCC,EAAAA,eAAe,EAAE,SAAAA,eAAA,GAAM,EAAE;AACzBC,EAAAA,UAAU,EAAE,QAAQ;AACpBC,EAAAA,UAAU,EAAE,SAAAA,UAAA,GAAM,EAAE;AACpBC,EAAAA,kBAAkB,EAAE;AAClBC,IAAAA,OAAO,EAAE,EAAE;AACXC,IAAAA,cAAc,EAAE,KAAA;GACjB;AACDC,EAAAA,iBAAiB,EAAE,SAAAA,iBAAA,GAAM,EAAE;AAC3BC,EAAAA,oBAAoB,EAAE,SAAAA,oBAAA,GAAM,EAAE;AAC9BC,EAAAA,YAAY,EAAE,EAAE;AAChBC,EAAAA,eAAe,EAAE,SAAAA,eAAA,GAAM,EAAE;AACzBC,EAAAA,cAAc,EAAE,QAAQ;AACxBC,EAAAA,iBAAiB,EAAE,SAAAA,iBAAA,GAAM,EAAE;AAC3BC,EAAAA,eAAe,EAAE,iCAAiC;AAClDC,EAAAA,mBAAmB,EAAE,SAAAA,mBAAA,GAAM,EAAE;AAC7BC,EAAAA,iBAAiB,EAAE,KAAK;AACxBC,EAAAA,eAAe,EAAE,KAAK;AACtBC,EAAAA,kBAAkB,EAAE,SAAAA,kBAAA,GAAM,EAAE;AAC5BC,EAAAA,WAAW,EAAE,CAAC;AACdC,EAAAA,mBAAmB,EAAEtB,SAAS;AAC9BuB,EAAAA,aAAa,EAAE,KAAK;AACpBC,EAAAA,SAAS,EAAE,EAAE;AACbC,EAAAA,SAAS,EAAE,KAAA;AACb,CAAC,EAAC;AAEF,IAAMC,eAAe,GAAG,SAAlBA,eAAeA,GAAwC;AAC3D,EAAA,IAAMC,OAAO,GAAG/B,cAAK,CAACgC,UAAU,CAACjC,YAAqD,CAAC,CAAA;AACvF,EAAA,OAAOgC,OAAO,CAAA;AAChB;;;;"}
|
|
@@ -3,7 +3,7 @@ import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProper
|
|
|
3
3
|
import 'react';
|
|
4
4
|
import { Footer, FooterRow, FooterCell } from '@table-library/react-table-library/table';
|
|
5
5
|
import styled from 'styled-components';
|
|
6
|
-
import { tableFooter, tableRow } from './tokens.js';
|
|
6
|
+
import { tableFooter, tableRow, classes } from './tokens.js';
|
|
7
7
|
import { ComponentIds } from './componentIds.js';
|
|
8
8
|
import { useTableContext } from './TableContext.js';
|
|
9
9
|
import '../Typography/index.js';
|
|
@@ -25,7 +25,7 @@ import { Text } from '../Typography/Text/Text.js';
|
|
|
25
25
|
|
|
26
26
|
var _excluded = ["children"],
|
|
27
27
|
_excluded2 = ["children"],
|
|
28
|
-
_excluded3 = ["children", "textAlign"];
|
|
28
|
+
_excluded3 = ["children", "textAlign", "gridColumnStart", "gridColumnEnd", "gridRowStart", "gridRowEnd"];
|
|
29
29
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
30
30
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
31
31
|
var StyledFooter = /*#__PURE__*/styled(Footer).withConfig({
|
|
@@ -95,7 +95,8 @@ var StyledFooterCell = /*#__PURE__*/styled(FooterCell).withConfig({
|
|
|
95
95
|
var theme = _ref5.theme,
|
|
96
96
|
$backgroundColor = _ref5.$backgroundColor,
|
|
97
97
|
$rowDensity = _ref5.$rowDensity,
|
|
98
|
-
$textAlign = _ref5.$textAlign
|
|
98
|
+
$textAlign = _ref5.$textAlign,
|
|
99
|
+
gridRow = _ref5.gridRow;
|
|
99
100
|
return {
|
|
100
101
|
'&&&': {
|
|
101
102
|
height: '100%',
|
|
@@ -106,6 +107,7 @@ var StyledFooterCell = /*#__PURE__*/styled(FooterCell).withConfig({
|
|
|
106
107
|
borderTopColor: getIn(theme.colors, tableFooter.borderBottomAndTopColor),
|
|
107
108
|
borderBottomStyle: 'solid',
|
|
108
109
|
borderTopStyle: 'solid',
|
|
110
|
+
gridRow: gridRow,
|
|
109
111
|
'> div': {
|
|
110
112
|
backgroundColor: getIn(theme.colors, tableFooter.backgroundColor),
|
|
111
113
|
display: 'flex',
|
|
@@ -123,12 +125,22 @@ var StyledFooterCell = /*#__PURE__*/styled(FooterCell).withConfig({
|
|
|
123
125
|
var _TableFooterCell = function _TableFooterCell(_ref6) {
|
|
124
126
|
var children = _ref6.children,
|
|
125
127
|
textAlign = _ref6.textAlign,
|
|
128
|
+
gridColumnStart = _ref6.gridColumnStart,
|
|
129
|
+
gridColumnEnd = _ref6.gridColumnEnd,
|
|
130
|
+
gridRowStart = _ref6.gridRowStart,
|
|
131
|
+
gridRowEnd = _ref6.gridRowEnd,
|
|
126
132
|
rest = _objectWithoutProperties(_ref6, _excluded3);
|
|
127
133
|
var isChildrenString = typeof children === 'string';
|
|
128
134
|
var _useTableContext2 = useTableContext(),
|
|
129
135
|
backgroundColor = _useTableContext2.backgroundColor,
|
|
130
136
|
rowDensity = _useTableContext2.rowDensity;
|
|
137
|
+
var hasRowSpan = Boolean(gridRowStart && gridRowEnd);
|
|
138
|
+
var gridRowValue = hasRowSpan ? "".concat(gridRowStart, " / ").concat(gridRowEnd) : undefined;
|
|
131
139
|
return /*#__PURE__*/jsx(StyledFooterCell, _objectSpread(_objectSpread(_objectSpread({
|
|
140
|
+
className: hasRowSpan ? classes.HAS_ROW_SPANNING : '',
|
|
141
|
+
gridColumnStart: gridColumnStart,
|
|
142
|
+
gridColumnEnd: gridColumnEnd,
|
|
143
|
+
gridRow: gridRowValue,
|
|
132
144
|
$backgroundColor: backgroundColor,
|
|
133
145
|
$rowDensity: rowDensity,
|
|
134
146
|
$textAlign: textAlign
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TableFooter.web.js","sources":["../../../../../../src/components/Table/TableFooter.web.tsx"],"sourcesContent":["import React from 'react';\nimport { Footer, FooterRow, FooterCell } from '@table-library/react-table-library/table';\nimport styled from 'styled-components';\nimport { tableFooter, tableRow } from './tokens';\nimport { ComponentIds } from './componentIds';\nimport type {\n TableFooterProps,\n TableFooterRowProps,\n TableFooterCellProps,\n TableBackgroundColors,\n TableProps,\n} from './types';\nimport { useTableContext } from './TableContext';\nimport { Text } from '~components/Typography';\nimport { makeSize, makeSpace } from '~utils';\nimport { MetaConstants, metaAttribute } from '~utils/metaAttribute';\nimport { assignWithoutSideEffects } from '~utils/assignWithoutSideEffects';\nimport getIn from '~utils/lodashButBetter/get';\nimport { size } from '~tokens/global';\nimport { makeAnalyticsAttribute } from '~utils/makeAnalyticsAttribute';\n\nconst StyledFooter = styled(Footer)(({ theme }) => ({\n '&&&': {\n backgroundColor: getIn(theme.colors, tableFooter.backgroundColor),\n '& tr:last-child th': {\n borderBottom: 'none',\n },\n },\n}));\n\nconst _TableFooter = ({ children, ...rest }: TableFooterProps): React.ReactElement => {\n return (\n <StyledFooter\n isFooter\n {...metaAttribute({ name: MetaConstants.TableFooter })}\n {...makeAnalyticsAttribute(rest)}\n >\n {children}\n </StyledFooter>\n );\n};\n\nconst TableFooter = assignWithoutSideEffects(_TableFooter, {\n componentId: ComponentIds.TableFooter,\n});\n\nconst StyledFooterRow = styled(FooterRow)<{ $showBorderedCells: boolean }>(\n ({ theme, $showBorderedCells }) => ({\n '& th': $showBorderedCells\n ? {\n borderRightWidth: makeSpace(getIn(theme.border.width, tableRow.borderBottomWidth)),\n borderRightColor: getIn(theme.colors, tableRow.borderColor),\n borderRightStyle: 'solid',\n }\n : undefined,\n '& th:last-child ': {\n borderRight: 'none',\n },\n }),\n);\n\nconst _TableFooterRow = ({ children, ...rest }: TableFooterRowProps): React.ReactElement => {\n const { showBorderedCells } = useTableContext();\n return (\n <StyledFooterRow\n {...metaAttribute({ name: MetaConstants.TableFooterRow })}\n {...makeAnalyticsAttribute(rest)}\n $showBorderedCells={showBorderedCells}\n >\n {children}\n </StyledFooterRow>\n );\n};\n\nconst TableFooterRow = assignWithoutSideEffects(_TableFooterRow, {\n componentId: ComponentIds.TableFooterRow,\n});\n\nconst StyledFooterCell = styled(FooterCell)<{\n $backgroundColor: TableBackgroundColors;\n $rowDensity: NonNullable<TableProps<unknown>['rowDensity']>;\n $textAlign?: string;\n}>(({ theme, $backgroundColor, $rowDensity, $textAlign }) => ({\n '&&&': {\n height: '100%',\n backgroundColor: getIn(theme.colors, $backgroundColor),\n borderBottomWidth: makeSpace(getIn(theme.border.width, tableFooter.borderBottomAndTopWidth)),\n borderTopWidth: makeSpace(getIn(theme.border.width, tableFooter.borderBottomAndTopWidth)),\n borderBottomColor: getIn(theme.colors, tableFooter.borderBottomAndTopColor),\n borderTopColor: getIn(theme.colors, tableFooter.borderBottomAndTopColor),\n borderBottomStyle: 'solid',\n borderTopStyle: 'solid',\n '> div': {\n backgroundColor: getIn(theme.colors, tableFooter.backgroundColor),\n display: 'flex',\n flexDirection: 'row',\n height: '100%',\n paddingLeft: makeSpace(getIn(theme, tableRow.paddingLeft[$rowDensity])),\n paddingRight: makeSpace(getIn(theme, tableRow.paddingRight[$rowDensity])),\n minHeight: makeSize(getIn(size, tableRow.minHeight[$rowDensity])),\n alignItems: 'center',\n justifyContent: $textAlign ? $textAlign : 'left',\n },\n },\n}));\n\nconst _TableFooterCell = ({\n children,\n textAlign,\n ...rest\n}: TableFooterCellProps): React.ReactElement => {\n const isChildrenString = typeof children === 'string';\n const { backgroundColor, rowDensity } = useTableContext();\n\n return (\n <StyledFooterCell\n $backgroundColor={backgroundColor}\n $rowDensity={rowDensity}\n $textAlign={textAlign}\n {...metaAttribute({ name: MetaConstants.TableFooterCell })}\n {...makeAnalyticsAttribute(rest)}\n >\n {isChildrenString ? (\n <Text size=\"medium\" weight=\"medium\">\n {children}\n </Text>\n ) : (\n children\n )}\n </StyledFooterCell>\n );\n};\n\nconst TableFooterCell = assignWithoutSideEffects(_TableFooterCell, {\n componentId: ComponentIds.TableFooterCell,\n});\n\nexport { TableFooter, TableFooterRow, TableFooterCell };\n"],"names":["StyledFooter","styled","Footer","withConfig","displayName","componentId","_ref","theme","backgroundColor","getIn","colors","tableFooter","borderBottom","_TableFooter","_ref2","children","rest","_objectWithoutProperties","_excluded","_jsx","_objectSpread","isFooter","metaAttribute","name","MetaConstants","TableFooter","makeAnalyticsAttribute","assignWithoutSideEffects","ComponentIds","StyledFooterRow","FooterRow","_ref3","$showBorderedCells","borderRightWidth","makeSpace","border","width","tableRow","borderBottomWidth","borderRightColor","borderColor","borderRightStyle","undefined","borderRight","_TableFooterRow","_ref4","_excluded2","_useTableContext","useTableContext","showBorderedCells","TableFooterRow","StyledFooterCell","FooterCell","_ref5","$backgroundColor","$rowDensity","$textAlign","height","borderBottomAndTopWidth","borderTopWidth","borderBottomColor","borderBottomAndTopColor","borderTopColor","borderBottomStyle","borderTopStyle","display","flexDirection","paddingLeft","paddingRight","minHeight","makeSize","size","alignItems","justifyContent","_TableFooterCell","_ref6","textAlign","_excluded3","isChildrenString","_useTableContext2","rowDensity","TableFooterCell","Text","weight"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqBA,IAAMA,YAAY,gBAAGC,MAAM,CAACC,MAAM,CAAC,CAAAC,UAAA,CAAA;EAAAC,WAAA,EAAA,8BAAA;EAAAC,WAAA,EAAA,cAAA;AAAA,CAAA,CAAA,CAAC,UAAAC,IAAA,EAAA;AAAA,EAAA,IAAGC,KAAK,GAAAD,IAAA,CAALC,KAAK,CAAA;EAAA,OAAQ;AAClD,IAAA,KAAK,EAAE;MACLC,eAAe,EAAEC,KAAK,CAACF,KAAK,CAACG,MAAM,EAAEC,WAAW,CAACH,eAAe,CAAC;AACjE,MAAA,oBAAoB,EAAE;AACpBI,QAAAA,YAAY,EAAE,MAAA;AAChB,OAAA;AACF,KAAA;GACD,CAAA;AAAA,CAAC,CAAC,CAAA;AAEH,IAAMC,YAAY,GAAG,SAAfA,YAAYA,CAAAC,KAAA,EAAoE;AAAA,EAAA,IAA9DC,QAAQ,GAAAD,KAAA,CAARC,QAAQ;AAAKC,IAAAA,IAAI,GAAAC,wBAAA,CAAAH,KAAA,EAAAI,SAAA,CAAA,CAAA;EACvC,oBACEC,GAAA,CAACnB,YAAY,EAAAoB,aAAA,CAAAA,aAAA,CAAAA,aAAA,CAAA;IACXC,QAAQ,EAAA,IAAA;AAAA,GAAA,EACJC,aAAa,CAAC;IAAEC,IAAI,EAAEC,aAAa,CAACC,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CAAA0D,KAAA,EAAAE,UAAA,CAAA,CAAA;AAEP,EAAA,IAAMC,gBAAgB,GAAG,OAAO/D,QAAQ,KAAK,QAAQ,CAAA;AACrD,EAAA,IAAAgE,iBAAA,GAAwC/B,eAAe,EAAE;IAAjDxC,eAAe,GAAAuE,iBAAA,CAAfvE,eAAe;IAAEwE,UAAU,GAAAD,iBAAA,CAAVC,UAAU,CAAA;EAEnC,oBACE7D,GAAA,CAACgC,gBAAgB,EAAA/B,aAAA,CAAAA,aAAA,CAAAA,aAAA,CAAA;AACfkC,IAAAA,gBAAgB,EAAE9C,eAAgB;AAClC+C,IAAAA,WAAW,EAAEyB,UAAW;AACxBxB,IAAAA,UAAU,EAAEoB,SAAAA;AAAU,GAAA,EAClBtD,aAAa,CAAC;IAAEC,IAAI,EAAEC,aAAa,CAACyD,eAAAA;AAAgB,GAAC,CAAC,CAAA,EACtDvD,sBAAsB,CAACV,IAAI,CAAC,CAAA,EAAA,EAAA,EAAA;AAAAD,IAAAA,QAAA,EAE/B+D,gBAAgB,gBACf3D,GAAA,CAAC+D,IAAI,EAAA;AAACX,MAAAA,IAAI,EAAC,QAAQ;AAACY,MAAAA,MAAM,EAAC,QAAQ;AAAApE,MAAAA,QAAA,EAChCA,QAAAA;AAAQ,KACL,CAAC,GAEPA,QAAAA;AACD,GAAA,CACe,CAAC,CAAA;AAEvB,CAAC,CAAA;AAED,IAAMkE,eAAe,gBAAGtD,wBAAwB,CAAC+C,gBAAgB,EAAE;EACjErE,WAAW,EAAEuB,YAAY,CAACqD,eAAAA;AAC5B,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"TableFooter.web.js","sources":["../../../../../../src/components/Table/TableFooter.web.tsx"],"sourcesContent":["import React from 'react';\nimport { Footer, FooterRow, FooterCell } from '@table-library/react-table-library/table';\nimport styled from 'styled-components';\nimport { tableFooter, tableRow, classes } from './tokens';\nimport { ComponentIds } from './componentIds';\nimport type {\n TableFooterProps,\n TableFooterRowProps,\n TableFooterCellProps,\n TableBackgroundColors,\n TableProps,\n} from './types';\nimport { useTableContext } from './TableContext';\nimport { Text } from '~components/Typography';\nimport { makeSize, makeSpace } from '~utils';\nimport { MetaConstants, metaAttribute } from '~utils/metaAttribute';\nimport { assignWithoutSideEffects } from '~utils/assignWithoutSideEffects';\nimport getIn from '~utils/lodashButBetter/get';\nimport { size } from '~tokens/global';\nimport { makeAnalyticsAttribute } from '~utils/makeAnalyticsAttribute';\n\nconst StyledFooter = styled(Footer)(({ theme }) => ({\n '&&&': {\n backgroundColor: getIn(theme.colors, tableFooter.backgroundColor),\n '& tr:last-child th': {\n borderBottom: 'none',\n },\n },\n}));\n\nconst _TableFooter = ({ children, ...rest }: TableFooterProps): React.ReactElement => {\n return (\n <StyledFooter\n isFooter\n {...metaAttribute({ name: MetaConstants.TableFooter })}\n {...makeAnalyticsAttribute(rest)}\n >\n {children}\n </StyledFooter>\n );\n};\n\nconst TableFooter = assignWithoutSideEffects(_TableFooter, {\n componentId: ComponentIds.TableFooter,\n});\n\nconst StyledFooterRow = styled(FooterRow)<{ $showBorderedCells: boolean }>(\n ({ theme, $showBorderedCells }) => ({\n '& th': $showBorderedCells\n ? {\n borderRightWidth: makeSpace(getIn(theme.border.width, tableRow.borderBottomWidth)),\n borderRightColor: getIn(theme.colors, tableRow.borderColor),\n borderRightStyle: 'solid',\n }\n : undefined,\n '& th:last-child ': {\n borderRight: 'none',\n },\n }),\n);\n\nconst _TableFooterRow = ({ children, ...rest }: TableFooterRowProps): React.ReactElement => {\n const { showBorderedCells } = useTableContext();\n return (\n <StyledFooterRow\n {...metaAttribute({ name: MetaConstants.TableFooterRow })}\n {...makeAnalyticsAttribute(rest)}\n $showBorderedCells={showBorderedCells}\n >\n {children}\n </StyledFooterRow>\n );\n};\n\nconst TableFooterRow = assignWithoutSideEffects(_TableFooterRow, {\n componentId: ComponentIds.TableFooterRow,\n});\n\nconst StyledFooterCell = styled(FooterCell)<{\n $backgroundColor: TableBackgroundColors;\n $rowDensity: NonNullable<TableProps<unknown>['rowDensity']>;\n $textAlign?: string;\n gridRow?: string;\n}>(({ theme, $backgroundColor, $rowDensity, $textAlign, gridRow }) => ({\n '&&&': {\n height: '100%',\n backgroundColor: getIn(theme.colors, $backgroundColor),\n borderBottomWidth: makeSpace(getIn(theme.border.width, tableFooter.borderBottomAndTopWidth)),\n borderTopWidth: makeSpace(getIn(theme.border.width, tableFooter.borderBottomAndTopWidth)),\n borderBottomColor: getIn(theme.colors, tableFooter.borderBottomAndTopColor),\n borderTopColor: getIn(theme.colors, tableFooter.borderBottomAndTopColor),\n borderBottomStyle: 'solid',\n borderTopStyle: 'solid',\n gridRow,\n '> div': {\n backgroundColor: getIn(theme.colors, tableFooter.backgroundColor),\n display: 'flex',\n flexDirection: 'row',\n height: '100%',\n paddingLeft: makeSpace(getIn(theme, tableRow.paddingLeft[$rowDensity])),\n paddingRight: makeSpace(getIn(theme, tableRow.paddingRight[$rowDensity])),\n minHeight: makeSize(getIn(size, tableRow.minHeight[$rowDensity])),\n alignItems: 'center',\n justifyContent: $textAlign ? $textAlign : 'left',\n },\n },\n}));\n\nconst _TableFooterCell = ({\n children,\n textAlign,\n gridColumnStart,\n gridColumnEnd,\n gridRowStart,\n gridRowEnd,\n ...rest\n}: TableFooterCellProps): React.ReactElement => {\n const isChildrenString = typeof children === 'string';\n const { backgroundColor, rowDensity } = useTableContext();\n\n const hasRowSpan = Boolean(gridRowStart && gridRowEnd);\n const gridRowValue = hasRowSpan ? `${gridRowStart} / ${gridRowEnd}` : undefined;\n\n return (\n <StyledFooterCell\n className={hasRowSpan ? classes.HAS_ROW_SPANNING : ''}\n gridColumnStart={gridColumnStart}\n gridColumnEnd={gridColumnEnd}\n gridRow={gridRowValue}\n $backgroundColor={backgroundColor}\n $rowDensity={rowDensity}\n $textAlign={textAlign}\n {...metaAttribute({ name: MetaConstants.TableFooterCell })}\n {...makeAnalyticsAttribute(rest)}\n >\n {isChildrenString ? (\n <Text size=\"medium\" weight=\"medium\">\n {children}\n </Text>\n ) : (\n children\n )}\n </StyledFooterCell>\n );\n};\n\nconst TableFooterCell = assignWithoutSideEffects(_TableFooterCell, {\n componentId: ComponentIds.TableFooterCell,\n});\n\nexport { TableFooter, TableFooterRow, TableFooterCell };\n"],"names":["StyledFooter","styled","Footer","withConfig","displayName","componentId","_ref","theme","backgroundColor","getIn","colors","tableFooter","borderBottom","_TableFooter","_ref2","children","rest","_objectWithoutProperties","_excluded","_jsx","_objectSpread","isFooter","metaAttribute","name","MetaConstants","TableFooter","makeAnalyticsAttribute","assignWithoutSideEffects","ComponentIds","StyledFooterRow","FooterRow","_ref3","$showBorderedCells","borderRightWidth","makeSpace","border","width","tableRow","borderBottomWidth","borderRightColor","borderColor","borderRightStyle","undefined","borderRight","_TableFooterRow","_ref4","_excluded2","_useTableContext","useTableContext","showBorderedCells","TableFooterRow","StyledFooterCell","FooterCell","_ref5","$backgroundColor","$rowDensity","$textAlign","gridRow","height","borderBottomAndTopWidth","borderTopWidth","borderBottomColor","borderBottomAndTopColor","borderTopColor","borderBottomStyle","borderTopStyle","display","flexDirection","paddingLeft","paddingRight","minHeight","makeSize","size","alignItems","justifyContent","_TableFooterCell","_ref6","textAlign","gridColumnStart","gridColumnEnd","gridRowStart","gridRowEnd","_excluded3","isChildrenString","_useTableContext2","rowDensity","hasRowSpan","Boolean","gridRowValue","concat","className","classes","HAS_ROW_SPANNING","TableFooterCell","Text","weight"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqBA,IAAMA,YAAY,gBAAGC,MAAM,CAACC,MAAM,CAAC,CAAAC,UAAA,CAAA;EAAAC,WAAA,EAAA,8BAAA;EAAAC,WAAA,EAAA,cAAA;AAAA,CAAA,CAAA,CAAC,UAAAC,IAAA,EAAA;AAAA,EAAA,IAAGC,KAAK,GAAAD,IAAA,CAALC,KAAK,CAAA;EAAA,OAAQ;AAClD,IAAA,KAAK,EAAE;MACLC,eAAe,EAAEC,KAAK,CAACF,KAAK,CAACG,MAAM,EAAE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AgB,EAAA/B,aAAA,CAAAA,aAAA,CAAAA,aAAA,CAAA;AACfsE,IAAAA,SAAS,EAAEJ,UAAU,GAAGK,OAAO,CAACC,gBAAgB,GAAG,EAAG;AACtDd,IAAAA,eAAe,EAAEA,eAAgB;AACjCC,IAAAA,aAAa,EAAEA,aAAc;AAC7BtB,IAAAA,OAAO,EAAE+B,YAAa;AACtBlC,IAAAA,gBAAgB,EAAE9C,eAAgB;AAClC+C,IAAAA,WAAW,EAAE8B,UAAW;AACxB7B,IAAAA,UAAU,EAAEqB,SAAAA;AAAU,GAAA,EAClBvD,aAAa,CAAC;IAAEC,IAAI,EAAEC,aAAa,CAACqE,eAAAA;AAAgB,GAAC,CAAC,CAAA,EACtDnE,sBAAsB,CAACV,IAAI,CAAC,CAAA,EAAA,EAAA,EAAA;AAAAD,IAAAA,QAAA,EAE/BoE,gBAAgB,gBACfhE,GAAA,CAAC2E,IAAI,EAAA;AAACtB,MAAAA,IAAI,EAAC,QAAQ;AAACuB,MAAAA,MAAM,EAAC,QAAQ;AAAAhF,MAAAA,QAAA,EAChCA,QAAAA;AAAQ,KACL,CAAC,GAEPA,QAAAA;AACD,GAAA,CACe,CAAC,CAAA;AAEvB,CAAC,CAAA;AAED,IAAM8E,eAAe,gBAAGlE,wBAAwB,CAACgD,gBAAgB,EAAE;EACjEtE,WAAW,EAAEuB,YAAY,CAACiE,eAAAA;AAC5B,CAAC;;;;"}
|
|
@@ -3,7 +3,7 @@ import _defineProperty from '@babel/runtime/helpers/defineProperty';
|
|
|
3
3
|
import 'react';
|
|
4
4
|
import styled from 'styled-components';
|
|
5
5
|
import { Header, HeaderCell, HeaderRow } from '@table-library/react-table-library/table';
|
|
6
|
-
import { tableHeader, tableRow, checkboxCellWidth } from './tokens.js';
|
|
6
|
+
import { tableHeader, tableRow, classes, checkboxCellWidth } from './tokens.js';
|
|
7
7
|
import { useTableContext } from './TableContext.js';
|
|
8
8
|
import { ComponentIds } from './componentIds.js';
|
|
9
9
|
import '../Checkbox/index.js';
|
|
@@ -36,7 +36,7 @@ import { Text } from '../Typography/Text/Text.js';
|
|
|
36
36
|
import { Checkbox } from '../Checkbox/Checkbox.js';
|
|
37
37
|
|
|
38
38
|
var _excluded = ["children"],
|
|
39
|
-
_excluded2 = ["children", "headerKey", "_hasPadding", "textAlign"],
|
|
39
|
+
_excluded2 = ["children", "headerKey", "_hasPadding", "textAlign", "gridColumnStart", "gridColumnEnd", "gridRowStart", "gridRowEnd"],
|
|
40
40
|
_excluded3 = ["children", "rowDensity"];
|
|
41
41
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
42
42
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
@@ -123,7 +123,8 @@ var StyledHeaderCell = /*#__PURE__*/styled(HeaderCell).withConfig({
|
|
|
123
123
|
$backgroundColor = _ref4.$backgroundColor,
|
|
124
124
|
$rowDensity = _ref4.$rowDensity,
|
|
125
125
|
$hasPadding = _ref4.$hasPadding,
|
|
126
|
-
$textAlign = _ref4.$textAlign
|
|
126
|
+
$textAlign = _ref4.$textAlign,
|
|
127
|
+
gridRow = _ref4.gridRow;
|
|
127
128
|
return {
|
|
128
129
|
'&&&': {
|
|
129
130
|
display: $textAlign ? 'flex' : 'block',
|
|
@@ -137,6 +138,7 @@ var StyledHeaderCell = /*#__PURE__*/styled(HeaderCell).withConfig({
|
|
|
137
138
|
borderBottomStyle: 'solid',
|
|
138
139
|
borderTopStyle: 'solid',
|
|
139
140
|
cursor: $isSortable ? 'pointer' : 'auto',
|
|
141
|
+
gridRow: gridRow,
|
|
140
142
|
'> div': {
|
|
141
143
|
backgroundColor: getIn(theme.colors, tableHeader.backgroundColor),
|
|
142
144
|
display: 'flex',
|
|
@@ -162,6 +164,10 @@ var _TableHeaderCell = function _TableHeaderCell(_ref5) {
|
|
|
162
164
|
_ref5$_hasPadding = _ref5._hasPadding,
|
|
163
165
|
_hasPadding = _ref5$_hasPadding === void 0 ? true : _ref5$_hasPadding,
|
|
164
166
|
textAlign = _ref5.textAlign,
|
|
167
|
+
gridColumnStart = _ref5.gridColumnStart,
|
|
168
|
+
gridColumnEnd = _ref5.gridColumnEnd,
|
|
169
|
+
gridRowStart = _ref5.gridRowStart,
|
|
170
|
+
gridRowEnd = _ref5.gridRowEnd,
|
|
165
171
|
rest = _objectWithoutProperties(_ref5, _excluded2);
|
|
166
172
|
var _useTableContext = useTableContext(),
|
|
167
173
|
toggleSort = _useTableContext.toggleSort,
|
|
@@ -173,8 +179,14 @@ var _TableHeaderCell = function _TableHeaderCell(_ref5) {
|
|
|
173
179
|
var isSortable = headerKey && Boolean((_currentSortedState$s = currentSortedState.sortableColumns) === null || _currentSortedState$s === void 0 ? void 0 : _currentSortedState$s.find(function (key) {
|
|
174
180
|
return key === headerKey;
|
|
175
181
|
}));
|
|
182
|
+
var hasRowSpan = Boolean(gridRowStart && gridRowEnd);
|
|
183
|
+
var gridRowValue = hasRowSpan ? "".concat(gridRowStart, " / ").concat(gridRowEnd) : undefined;
|
|
176
184
|
return /*#__PURE__*/jsxs(StyledHeaderCell, _objectSpread(_objectSpread(_objectSpread({
|
|
177
185
|
tabIndex: 0,
|
|
186
|
+
className: hasRowSpan ? classes.HAS_ROW_SPANNING : '',
|
|
187
|
+
gridColumnStart: gridColumnStart,
|
|
188
|
+
gridColumnEnd: gridColumnEnd,
|
|
189
|
+
gridRow: gridRowValue,
|
|
178
190
|
$isSortable: isSortable,
|
|
179
191
|
$backgroundColor: backgroundColor,
|
|
180
192
|
$rowDensity: headerRowDensity !== null && headerRowDensity !== void 0 ? headerRowDensity : rowDensity,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TableHeader.web.js","sources":["../../../../../../src/components/Table/TableHeader.web.tsx"],"sourcesContent":["import React from 'react';\nimport styled from 'styled-components';\nimport { Header, HeaderRow, HeaderCell } from '@table-library/react-table-library/table';\nimport { checkboxCellWidth, tableHeader, tableRow } from './tokens';\nimport { useTableContext } from './TableContext';\nimport { ComponentIds } from './componentIds';\nimport type {\n TableHeaderRowProps,\n TableHeaderCellProps,\n TableBackgroundColors,\n TableProps,\n} from './types';\nimport type { CheckboxProps } from '~components/Checkbox';\nimport { Checkbox } from '~components/Checkbox';\nimport { Text } from '~components/Typography';\nimport { castWebType, makeMotionTime, makeSize, makeSpace } from '~utils';\nimport { makeAccessible } from '~utils/makeAccessible';\nimport { assignWithoutSideEffects } from '~utils/assignWithoutSideEffects';\nimport BaseBox from '~components/Box/BaseBox';\nimport { MetaConstants, metaAttribute } from '~utils/metaAttribute';\nimport { useTheme } from '~components/BladeProvider';\nimport getIn from '~utils/lodashButBetter/get';\nimport { getFocusRingStyles } from '~utils/getFocusRingStyles';\nimport { size } from '~tokens/global';\nimport { makeAnalyticsAttribute } from '~utils/makeAnalyticsAttribute';\n\nconst SortButton = styled.button(({ theme }) => ({\n cursor: 'pointer',\n border: 'none',\n padding: 0,\n margin: 0,\n borderRadius: theme.border.radius.small,\n background: 'transparent',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n transitionProperty: 'color, box-shadow',\n transitionDuration: castWebType(makeMotionTime(getIn(theme.motion, 'duration.quick'))),\n transitionTimingFunction: (theme.motion.easing.standard as unknown) as string,\n '&:focus-visible': getFocusRingStyles({ theme }),\n}));\n\nconst SortIcon = ({\n isSorted,\n isSortReversed,\n}: {\n isSorted: boolean;\n isSortReversed: boolean;\n}): React.ReactElement => {\n const { theme } = useTheme();\n const defaultColor = getIn(theme.colors, 'interactive.icon.gray.muted');\n const activeColor = getIn(theme.colors, 'interactive.icon.primary.subtle');\n const upArrowColor = isSorted && isSortReversed ? activeColor : defaultColor;\n const downArrowColor = isSorted && !isSortReversed ? activeColor : defaultColor;\n return (\n <SortButton\n {...metaAttribute({ name: MetaConstants.TableSortButton })}\n {...makeAccessible({ label: 'Toggle Sort', role: 'button' })}\n >\n <svg width={20} height={20} fill=\"none\">\n <path\n fill={upArrowColor}\n d=\"M10.59 2.251a.817.817 0 0 0-1.18 0L5.245 6.537a.875.875 0 0 0 0 1.212.817.817 0 0 0 1.179 0L10 4.069l3.577 3.68a.817.817 0 0 0 1.179 0 .874.874 0 0 0 0-1.212L10.589 2.25Z\"\n />\n <path\n fill={downArrowColor}\n d=\"M9.41 17.749a.817.817 0 0 0 1.18 0l4.166-4.286a.874.874 0 0 0 0-1.212.817.817 0 0 0-1.179 0L10 15.931l-3.577-3.68a.817.817 0 0 0-1.179 0 .874.874 0 0 0 0 1.212l4.167 4.286Z\"\n />\n </svg>\n </SortButton>\n );\n};\n\nconst StyledHeader = styled(Header)({\n '&&&': {\n '& tr:first-child th': {\n borderTop: 'none',\n },\n },\n});\n\nconst _TableHeader = ({ children, ...rest }: TableHeaderRowProps): React.ReactElement => {\n return (\n <StyledHeader\n {...metaAttribute({ name: MetaConstants.TableHeader })}\n {...makeAnalyticsAttribute(rest)}\n >\n {children}\n </StyledHeader>\n );\n};\n\nconst TableHeader = assignWithoutSideEffects(_TableHeader, {\n componentId: ComponentIds.TableHeader,\n});\n\nconst StyledHeaderCell = styled(HeaderCell)<{\n $isSortable: boolean;\n $backgroundColor: TableBackgroundColors;\n $rowDensity: NonNullable<TableProps<unknown>['rowDensity']>;\n $hasPadding: boolean;\n $textAlign: 'left' | 'center' | 'right';\n}>(({ theme, $isSortable, $backgroundColor, $rowDensity, $hasPadding, $textAlign }) => ({\n '&&&': {\n display: $textAlign ? 'flex' : 'block',\n justifyContent: $textAlign ? 'space-between' : 'initial',\n height: '100%',\n backgroundColor: getIn(theme.colors, $backgroundColor),\n borderBottomWidth: makeSpace(getIn(theme.border.width, tableHeader.borderBottomAndTopWidth)),\n borderTopWidth: makeSpace(getIn(theme.border.width, tableHeader.borderBottomAndTopWidth)),\n borderBottomColor: getIn(theme.colors, tableHeader.borderBottomAndTopColor),\n borderTopColor: getIn(theme.colors, tableHeader.borderBottomAndTopColor),\n borderBottomStyle: 'solid',\n borderTopStyle: 'solid',\n cursor: $isSortable ? 'pointer' : 'auto',\n '> div': {\n backgroundColor: getIn(theme.colors, tableHeader.backgroundColor),\n display: 'flex',\n flexDirection: 'row',\n justifyContent: $textAlign ? $textAlign : 'space-between',\n alignItems: 'center',\n height: '100%',\n paddingLeft: $hasPadding\n ? makeSpace(getIn(theme, tableRow.paddingLeft[$rowDensity]))\n : undefined,\n paddingRight: $hasPadding\n ? makeSpace(getIn(theme, tableRow.paddingRight[$rowDensity]))\n : undefined,\n minHeight: makeSize(getIn(size, tableRow.minHeight[$rowDensity])),\n },\n '&:focus-visible': getFocusRingStyles({ theme, negativeOffset: true }),\n },\n}));\n\nconst _TableHeaderCell = ({\n children,\n headerKey,\n _hasPadding = true,\n textAlign,\n ...rest\n}: TableHeaderCellProps): React.ReactElement => {\n const {\n toggleSort,\n currentSortedState,\n backgroundColor,\n rowDensity,\n headerRowDensity,\n } = useTableContext();\n const isChildrenString = typeof children === 'string';\n const isSortable =\n headerKey && Boolean(currentSortedState.sortableColumns?.find((key) => key === headerKey));\n return (\n <StyledHeaderCell\n tabIndex={0}\n $isSortable={isSortable}\n $backgroundColor={backgroundColor}\n $rowDensity={headerRowDensity ?? rowDensity}\n $hasPadding={_hasPadding}\n $textAlign={textAlign}\n onClick={() => {\n if (isSortable) {\n toggleSort(headerKey);\n }\n }}\n {...metaAttribute({ name: MetaConstants.TableHeaderCell })}\n {...makeAnalyticsAttribute(rest)}\n >\n <BaseBox display=\"flex\" flexGrow={1} justifyContent={textAlign}>\n {isChildrenString ? (\n <Text size=\"medium\" weight=\"medium\" color=\"surface.text.gray.normal\">\n {children}\n </Text>\n ) : (\n children\n )}\n </BaseBox>\n {isSortable && (\n <BaseBox paddingLeft=\"spacing.2\" backgroundColor=\"transparent\" flexShrink={0}>\n <SortIcon\n isSorted={currentSortedState.sortKey === headerKey}\n isSortReversed={currentSortedState.isSortReversed}\n />\n </BaseBox>\n )}\n </StyledHeaderCell>\n );\n};\n\nconst TableHeaderCell = assignWithoutSideEffects(_TableHeaderCell, {\n componentId: ComponentIds.TableHeaderCell,\n});\n\nconst TableHeaderCellCheckbox = ({\n isChecked,\n isDisabled,\n isIndeterminate,\n onChange,\n}: {\n isChecked: CheckboxProps['isChecked'];\n isDisabled: CheckboxProps['isDisabled'];\n isIndeterminate?: CheckboxProps['isIndeterminate'];\n onChange: CheckboxProps['onChange'];\n}): React.ReactElement => {\n return (\n <TableHeaderCell headerKey=\"SELECT\">\n <BaseBox\n display=\"flex\"\n alignItems=\"center\"\n justifyContent=\"center\"\n flex={1}\n width={makeSize(checkboxCellWidth)}\n >\n <Checkbox\n isChecked={isChecked}\n isDisabled={isDisabled}\n isIndeterminate={isIndeterminate}\n onChange={onChange}\n {...makeAccessible({ label: 'Select All Rows' })}\n />\n </BaseBox>\n </TableHeaderCell>\n );\n};\n\nconst StyledHeaderRow = styled(HeaderRow)<{\n $showBorderedCells: boolean;\n $gridTemplateColumns: string | undefined;\n $hasHoverActions: boolean;\n $selectionType: TableProps<unknown>['selectionType'];\n $columnCount: number;\n $isVirtualized?: boolean;\n}>(\n ({\n theme,\n $showBorderedCells,\n $gridTemplateColumns,\n $hasHoverActions,\n $selectionType,\n $columnCount,\n $isVirtualized,\n }) => ({\n '& th': $showBorderedCells\n ? {\n borderRightWidth: makeSpace(getIn(theme.border.width, tableRow.borderBottomWidth)),\n borderRightColor: getIn(theme.colors, tableRow.borderColor),\n borderRightStyle: 'solid',\n ...($isVirtualized && {\n display: 'grid',\n gridTemplateColumns: $gridTemplateColumns\n ? `${$gridTemplateColumns} ${$hasHoverActions ? 'min-content' : ''}`\n : ` ${\n $selectionType === 'multiple' ? 'min-content' : ''\n } repeat(${$columnCount},minmax(100px, 1fr)) ${\n $hasHoverActions ? 'min-content' : ''\n } !important;`,\n }),\n }\n : undefined,\n '& th:last-child ': {\n borderRight: 'none',\n },\n }),\n);\n\nconst _TableHeaderRow = ({\n children,\n rowDensity,\n ...rest\n}: TableHeaderRowProps): React.ReactElement => {\n const {\n disabledRows,\n selectionType,\n selectedRows,\n totalItems,\n toggleAllRowsSelection,\n setHeaderRowDensity,\n showBorderedCells,\n hasHoverActions,\n gridTemplateColumns,\n columnCount,\n isVirtualized,\n } = useTableContext();\n const isMultiSelect = selectionType === 'multiple';\n const isAllSelected = selectedRows && selectedRows.length === totalItems;\n const isIndeterminate = selectedRows && selectedRows.length > 0 && !isAllSelected;\n const isDisabled = disabledRows && disabledRows.length === totalItems;\n if (rowDensity) {\n setHeaderRowDensity(rowDensity);\n }\n return (\n <StyledHeaderRow\n role=\"rowheader\"\n {...metaAttribute({ name: MetaConstants.TableHeaderRow })}\n {...makeAnalyticsAttribute(rest)}\n $showBorderedCells={showBorderedCells}\n $gridTemplateColumns={gridTemplateColumns}\n $hasHoverActions={hasHoverActions}\n $selectionType={selectionType}\n $columnCount={columnCount}\n $isVirtualized={isVirtualized}\n >\n {isMultiSelect && (\n <TableHeaderCellCheckbox\n isChecked={isAllSelected}\n isDisabled={isDisabled}\n isIndeterminate={isIndeterminate}\n onChange={() => toggleAllRowsSelection()}\n />\n )}\n {children}\n {hasHoverActions ? <TableHeaderCell _hasPadding={false}>Actions</TableHeaderCell> : null}\n </StyledHeaderRow>\n );\n};\n\nconst TableHeaderRow = assignWithoutSideEffects(_TableHeaderRow, {\n componentId: ComponentIds.TableHeaderRow,\n});\n\nexport { TableHeader, TableHeaderRow, TableHeaderCell };\n"],"names":["SortButton","styled","button","withConfig","displayName","componentId","_ref","theme","cursor","border","padding","margin","borderRadius","radius","small","background","display","alignItems","justifyContent","transitionProperty","transitionDuration","castWebType","makeMotionTime","getIn","motion","transitionTimingFunction","easing","standard","getFocusRingStyles","SortIcon","_ref2","isSorted","isSortReversed","_useTheme","useTheme","defaultColor","colors","activeColor","upArrowColor","downArrowColor","_jsx","_objectSpread","metaAttribute","name","MetaConstants","TableSortButton","makeAccessible","label","role","children","_jsxs","width","height","fill","d","StyledHeader","Header","borderTop","_TableHeader","_ref3","rest","_objectWithoutProperties","_excluded","TableHeader","makeAnalyticsAttribute","assignWithoutSideEffects","ComponentIds","StyledHeaderCell","HeaderCell","_ref4","$isSortable","$backgroundColor","$rowDensity","$hasPadding","$textAlign","backgroundColor","borderBottomWidth","makeSpace","tableHeader","borderBottomAndTopWidth","borderTopWidth","borderBottomColor","borderBottomAndTopColor","borderTopColor","borderBottomStyle","borderTopStyle","flexDirection","paddingLeft","tableRow","undefined","paddingRight","minHeight","makeSize","size","negativeOffset","_TableHeaderCell","_ref5","_currentSortedState$s","headerKey","_ref5$_hasPadding","_hasPadding","textAlign","_excluded2","_useTableContext","useTableContext","toggleSort","currentSortedState","rowDensity","headerRowDensity","isChildrenString","isSortable","Boolean","sortableColumns","find","key","tabIndex","onClick","TableHeaderCell","BaseBox","flexGrow","Text","weight","color","flexShrink","sortKey","TableHeaderCellCheckbox","_ref6","isChecked","isDisabled","isIndeterminate","onChange","flex","checkboxCellWidth","Checkbox","StyledHeaderRow","HeaderRow","_ref7","$showBorderedCells","$gridTemplateColumns","$hasHoverActions","$selectionType","$columnCount","$isVirtualized","borderRightWidth","borderRightColor","borderColor","borderRightStyle","gridTemplateColumns","concat","borderRight","_TableHeaderRow","_ref8","_excluded3","_useTableContext2","disabledRows","selectionType","selectedRows","totalItems","toggleAllRowsSelection","setHeaderRowDensity","showBorderedCells","hasHoverActions","columnCount","isVirtualized","isMultiSelect","isAllSelected","length","TableHeaderRow"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BA,IAAMA,UAAU,gBAAGC,MAA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EtB,CAAC,CAAA;AAED,IAAMsH,cAAc,gBAAGtG,wBAAwB,CAACqF,eAAe,EAAE;EAC/DjJ,WAAW,EAAE6D,YAAY,CAACqG,cAAAA;AAC5B,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"TableHeader.web.js","sources":["../../../../../../src/components/Table/TableHeader.web.tsx"],"sourcesContent":["import React from 'react';\nimport styled from 'styled-components';\nimport { Header, HeaderRow, HeaderCell } from '@table-library/react-table-library/table';\nimport { checkboxCellWidth, tableHeader, tableRow, classes } from './tokens';\nimport { useTableContext } from './TableContext';\nimport { ComponentIds } from './componentIds';\nimport type {\n TableHeaderRowProps,\n TableHeaderCellProps,\n TableBackgroundColors,\n TableProps,\n} from './types';\nimport type { CheckboxProps } from '~components/Checkbox';\nimport { Checkbox } from '~components/Checkbox';\nimport { Text } from '~components/Typography';\nimport { castWebType, makeMotionTime, makeSize, makeSpace } from '~utils';\nimport { makeAccessible } from '~utils/makeAccessible';\nimport { assignWithoutSideEffects } from '~utils/assignWithoutSideEffects';\nimport BaseBox from '~components/Box/BaseBox';\nimport { MetaConstants, metaAttribute } from '~utils/metaAttribute';\nimport { useTheme } from '~components/BladeProvider';\nimport getIn from '~utils/lodashButBetter/get';\nimport { getFocusRingStyles } from '~utils/getFocusRingStyles';\nimport { size } from '~tokens/global';\nimport { makeAnalyticsAttribute } from '~utils/makeAnalyticsAttribute';\n\nconst SortButton = styled.button(({ theme }) => ({\n cursor: 'pointer',\n border: 'none',\n padding: 0,\n margin: 0,\n borderRadius: theme.border.radius.small,\n background: 'transparent',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n transitionProperty: 'color, box-shadow',\n transitionDuration: castWebType(makeMotionTime(getIn(theme.motion, 'duration.quick'))),\n transitionTimingFunction: (theme.motion.easing.standard as unknown) as string,\n '&:focus-visible': getFocusRingStyles({ theme }),\n}));\n\nconst SortIcon = ({\n isSorted,\n isSortReversed,\n}: {\n isSorted: boolean;\n isSortReversed: boolean;\n}): React.ReactElement => {\n const { theme } = useTheme();\n const defaultColor = getIn(theme.colors, 'interactive.icon.gray.muted');\n const activeColor = getIn(theme.colors, 'interactive.icon.primary.subtle');\n const upArrowColor = isSorted && isSortReversed ? activeColor : defaultColor;\n const downArrowColor = isSorted && !isSortReversed ? activeColor : defaultColor;\n return (\n <SortButton\n {...metaAttribute({ name: MetaConstants.TableSortButton })}\n {...makeAccessible({ label: 'Toggle Sort', role: 'button' })}\n >\n <svg width={20} height={20} fill=\"none\">\n <path\n fill={upArrowColor}\n d=\"M10.59 2.251a.817.817 0 0 0-1.18 0L5.245 6.537a.875.875 0 0 0 0 1.212.817.817 0 0 0 1.179 0L10 4.069l3.577 3.68a.817.817 0 0 0 1.179 0 .874.874 0 0 0 0-1.212L10.589 2.25Z\"\n />\n <path\n fill={downArrowColor}\n d=\"M9.41 17.749a.817.817 0 0 0 1.18 0l4.166-4.286a.874.874 0 0 0 0-1.212.817.817 0 0 0-1.179 0L10 15.931l-3.577-3.68a.817.817 0 0 0-1.179 0 .874.874 0 0 0 0 1.212l4.167 4.286Z\"\n />\n </svg>\n </SortButton>\n );\n};\n\nconst StyledHeader = styled(Header)({\n '&&&': {\n '& tr:first-child th': {\n borderTop: 'none',\n },\n },\n});\n\nconst _TableHeader = ({ children, ...rest }: TableHeaderRowProps): React.ReactElement => {\n return (\n <StyledHeader\n {...metaAttribute({ name: MetaConstants.TableHeader })}\n {...makeAnalyticsAttribute(rest)}\n >\n {children}\n </StyledHeader>\n );\n};\n\nconst TableHeader = assignWithoutSideEffects(_TableHeader, {\n componentId: ComponentIds.TableHeader,\n});\n\nconst StyledHeaderCell = styled(HeaderCell)<{\n $isSortable: boolean;\n $backgroundColor: TableBackgroundColors;\n $rowDensity: NonNullable<TableProps<unknown>['rowDensity']>;\n $hasPadding: boolean;\n $textAlign: 'left' | 'center' | 'right';\n gridRow?: string;\n}>(({ theme, $isSortable, $backgroundColor, $rowDensity, $hasPadding, $textAlign, gridRow }) => ({\n '&&&': {\n display: $textAlign ? 'flex' : 'block',\n justifyContent: $textAlign ? 'space-between' : 'initial',\n height: '100%',\n backgroundColor: getIn(theme.colors, $backgroundColor),\n borderBottomWidth: makeSpace(getIn(theme.border.width, tableHeader.borderBottomAndTopWidth)),\n borderTopWidth: makeSpace(getIn(theme.border.width, tableHeader.borderBottomAndTopWidth)),\n borderBottomColor: getIn(theme.colors, tableHeader.borderBottomAndTopColor),\n borderTopColor: getIn(theme.colors, tableHeader.borderBottomAndTopColor),\n borderBottomStyle: 'solid',\n borderTopStyle: 'solid',\n cursor: $isSortable ? 'pointer' : 'auto',\n gridRow,\n '> div': {\n backgroundColor: getIn(theme.colors, tableHeader.backgroundColor),\n display: 'flex',\n flexDirection: 'row',\n justifyContent: $textAlign ? $textAlign : 'space-between',\n alignItems: 'center',\n height: '100%',\n paddingLeft: $hasPadding\n ? makeSpace(getIn(theme, tableRow.paddingLeft[$rowDensity]))\n : undefined,\n paddingRight: $hasPadding\n ? makeSpace(getIn(theme, tableRow.paddingRight[$rowDensity]))\n : undefined,\n minHeight: makeSize(getIn(size, tableRow.minHeight[$rowDensity])),\n },\n '&:focus-visible': getFocusRingStyles({ theme, negativeOffset: true }),\n },\n}));\n\nconst _TableHeaderCell = ({\n children,\n headerKey,\n _hasPadding = true,\n textAlign,\n gridColumnStart,\n gridColumnEnd,\n gridRowStart,\n gridRowEnd,\n ...rest\n}: TableHeaderCellProps): React.ReactElement => {\n const {\n toggleSort,\n currentSortedState,\n backgroundColor,\n rowDensity,\n headerRowDensity,\n } = useTableContext();\n const isChildrenString = typeof children === 'string';\n const isSortable =\n headerKey && Boolean(currentSortedState.sortableColumns?.find((key) => key === headerKey));\n\n const hasRowSpan = Boolean(gridRowStart && gridRowEnd);\n const gridRowValue = hasRowSpan ? `${gridRowStart} / ${gridRowEnd}` : undefined;\n\n return (\n <StyledHeaderCell\n tabIndex={0}\n className={hasRowSpan ? classes.HAS_ROW_SPANNING : ''}\n gridColumnStart={gridColumnStart}\n gridColumnEnd={gridColumnEnd}\n gridRow={gridRowValue}\n $isSortable={isSortable}\n $backgroundColor={backgroundColor}\n $rowDensity={headerRowDensity ?? rowDensity}\n $hasPadding={_hasPadding}\n $textAlign={textAlign}\n onClick={() => {\n if (isSortable) {\n toggleSort(headerKey);\n }\n }}\n {...metaAttribute({ name: MetaConstants.TableHeaderCell })}\n {...makeAnalyticsAttribute(rest)}\n >\n <BaseBox display=\"flex\" flexGrow={1} justifyContent={textAlign}>\n {isChildrenString ? (\n <Text size=\"medium\" weight=\"medium\" color=\"surface.text.gray.normal\">\n {children}\n </Text>\n ) : (\n children\n )}\n </BaseBox>\n {isSortable && (\n <BaseBox paddingLeft=\"spacing.2\" backgroundColor=\"transparent\" flexShrink={0}>\n <SortIcon\n isSorted={currentSortedState.sortKey === headerKey}\n isSortReversed={currentSortedState.isSortReversed}\n />\n </BaseBox>\n )}\n </StyledHeaderCell>\n );\n};\n\nconst TableHeaderCell = assignWithoutSideEffects(_TableHeaderCell, {\n componentId: ComponentIds.TableHeaderCell,\n});\n\nconst TableHeaderCellCheckbox = ({\n isChecked,\n isDisabled,\n isIndeterminate,\n onChange,\n}: {\n isChecked: CheckboxProps['isChecked'];\n isDisabled: CheckboxProps['isDisabled'];\n isIndeterminate?: CheckboxProps['isIndeterminate'];\n onChange: CheckboxProps['onChange'];\n}): React.ReactElement => {\n return (\n <TableHeaderCell headerKey=\"SELECT\">\n <BaseBox\n display=\"flex\"\n alignItems=\"center\"\n justifyContent=\"center\"\n flex={1}\n width={makeSize(checkboxCellWidth)}\n >\n <Checkbox\n isChecked={isChecked}\n isDisabled={isDisabled}\n isIndeterminate={isIndeterminate}\n onChange={onChange}\n {...makeAccessible({ label: 'Select All Rows' })}\n />\n </BaseBox>\n </TableHeaderCell>\n );\n};\n\nconst StyledHeaderRow = styled(HeaderRow)<{\n $showBorderedCells: boolean;\n $gridTemplateColumns: string | undefined;\n $hasHoverActions: boolean;\n $selectionType: TableProps<unknown>['selectionType'];\n $columnCount: number;\n $isVirtualized?: boolean;\n}>(\n ({\n theme,\n $showBorderedCells,\n $gridTemplateColumns,\n $hasHoverActions,\n $selectionType,\n $columnCount,\n $isVirtualized,\n }) => ({\n '& th': $showBorderedCells\n ? {\n borderRightWidth: makeSpace(getIn(theme.border.width, tableRow.borderBottomWidth)),\n borderRightColor: getIn(theme.colors, tableRow.borderColor),\n borderRightStyle: 'solid',\n ...($isVirtualized && {\n display: 'grid',\n gridTemplateColumns: $gridTemplateColumns\n ? `${$gridTemplateColumns} ${$hasHoverActions ? 'min-content' : ''}`\n : ` ${\n $selectionType === 'multiple' ? 'min-content' : ''\n } repeat(${$columnCount},minmax(100px, 1fr)) ${\n $hasHoverActions ? 'min-content' : ''\n } !important;`,\n }),\n }\n : undefined,\n '& th:last-child ': {\n borderRight: 'none',\n },\n }),\n);\n\nconst _TableHeaderRow = ({\n children,\n rowDensity,\n ...rest\n}: TableHeaderRowProps): React.ReactElement => {\n const {\n disabledRows,\n selectionType,\n selectedRows,\n totalItems,\n toggleAllRowsSelection,\n setHeaderRowDensity,\n showBorderedCells,\n hasHoverActions,\n gridTemplateColumns,\n columnCount,\n isVirtualized,\n } = useTableContext();\n const isMultiSelect = selectionType === 'multiple';\n const isAllSelected = selectedRows && selectedRows.length === totalItems;\n const isIndeterminate = selectedRows && selectedRows.length > 0 && !isAllSelected;\n const isDisabled = disabledRows && disabledRows.length === totalItems;\n if (rowDensity) {\n setHeaderRowDensity(rowDensity);\n }\n return (\n <StyledHeaderRow\n role=\"rowheader\"\n {...metaAttribute({ name: MetaConstants.TableHeaderRow })}\n {...makeAnalyticsAttribute(rest)}\n $showBorderedCells={showBorderedCells}\n $gridTemplateColumns={gridTemplateColumns}\n $hasHoverActions={hasHoverActions}\n $selectionType={selectionType}\n $columnCount={columnCount}\n $isVirtualized={isVirtualized}\n >\n {isMultiSelect && (\n <TableHeaderCellCheckbox\n isChecked={isAllSelected}\n isDisabled={isDisabled}\n isIndeterminate={isIndeterminate}\n onChange={() => toggleAllRowsSelection()}\n />\n )}\n {children}\n {hasHoverActions ? <TableHeaderCell _hasPadding={false}>Actions</TableHeaderCell> : null}\n </StyledHeaderRow>\n );\n};\n\nconst TableHeaderRow = assignWithoutSideEffects(_TableHeaderRow, {\n componentId: ComponentIds.TableHeaderRow,\n});\n\nexport { TableHeader, TableHeaderRow, TableHeaderCell };\n"],"names":["SortButton","styled","button","withConfig","displayName","componentId","_ref","theme","cursor","border","padding","margin","borderRadius","radius","small","background","display","alignItems","justifyContent","transitionProperty","transitionDuration","castWebType","makeMotionTime","getIn","motion","transitionTimingFunction","easing","standard","getFocusRingStyles","SortIcon","_ref2","isSorted","isSortReversed","_useTheme","useTheme","defaultColor","colors","activeColor","upArrowColor","downArrowColor","_jsx","_objectSpread","metaAttribute","name","MetaConstants","TableSortButton","makeAccessible","label","role","children","_jsxs","width","height","fill","d","StyledHeader","Header","borderTop","_TableHeader","_ref3","rest","_objectWithoutProperties","_excluded","TableHeader","makeAnalyticsAttribute","assignWithoutSideEffects","ComponentIds","StyledHeaderCell","HeaderCell","_ref4","$isSortable","$backgroundColor","$rowDensity","$hasPadding","$textAlign","gridRow","backgroundColor","borderBottomWidth","makeSpace","tableHeader","borderBottomAndTopWidth","borderTopWidth","borderBottomColor","borderBottomAndTopColor","borderTopColor","borderBottomStyle","borderTopStyle","flexDirection","paddingLeft","tableRow","undefined","paddingRight","minHeight","makeSize","size","negativeOffset","_TableHeaderCell","_ref5","_currentSortedState$s","headerKey","_ref5$_hasPadding","_hasPadding","textAlign","gridColumnStart","gridColumnEnd","gridRowStart","gridRowEnd","_excluded2","_useTableContext","useTableContext","toggleSort","currentSortedState","rowDensity","headerRowDensity","isChildrenString","isSortable","Boolean","sortableColumns","find","key","hasRowSpan","gridRowValue","concat","tabIndex","className","classes","HAS_ROW_SPANNING","onClick","TableHeaderCell","BaseBox","flexGrow","Text","weight","color","flexShrink","sortKey","TableHeaderCellCheckbox","_ref6","isChecked","isDisabled","isIndeterminate","onChange","flex","checkboxCellWidth","Checkbox","StyledHeaderRow","HeaderRow","_ref7","$showBorderedCells","$gridTemplateColumns","$hasHoverActions","$selectionType","$columnCount","$isVirtualized","borderRightWidth","borderRightColor","borderColor","borderRightStyle","gridTemplateColumns","borderRight","_TableHeaderRow","_ref8","_excluded3","_useTableContext2","disabledRows","selectionType","selectedRows","totalItems","toggleAllRowsSelection","setHeaderRowDensity","showBorderedCells","hasHoverActions","columnCount","isVirtualized","isMultiSelect","isAllSelected","length","TableHeaderRow"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BA,IAAMA,UAAU,gBAAGC,MAAM,CAACC,MAAM,CAAAC,UAAA,CAAA;EAAAC,WAAA,EAAA,4BAAA;EAAAC,WAAA,EAAA,UAAA;AAAA,CAAA,CAAA,CAAC,UAAAC,IAAA,EAAA;AAAA,EAAA,IAAGC,KAAK,GAAAD,IAAA,CAALC,KAAK,CAAA;EAAA,OAAQ;AAC/CC,IAAAA,MAAM,EAAE,SAAS;AACjBC,IAAAA,MAAM,EAAE,MAAM;AACdC,IAAAA,OAAO,EAAE,CAAC;AACVC,IAAAA,MAAM,EAAE,CAAC;AACTC,IAAAA,YAAY,EAAEL,KAAK,CAACE,MAAM,CAACI,MAAM,CAACC,KAAK;AACvCC,IAAAA,UAAU,EAAE,aAAa;AACzBC,IAAAA,OAAO,EAAE,MAAM;AACfC,IAAAA,UAAU,EAAE,QAAQ;AACpBC,IAAAA,cAAc,EAAE,QAAQ;AACxBC,IAAAA,kBAAkB,EAAE,mBAAmB;AACvCC,IAAAA,kBAAkB,EAAEC,WAAW,CAACC,cAAc,CAACC,KAAK,CAAChB,KAAK,CAACiB,MAAM,EAAE,gBAAgB,CAAC,CAAC,CAAC;AACtFC,IAAAA,wBAAwB,EAAGlB,KAAK,CAACiB,MAAM,CAACE,MAAM,CAACC,QAA8B;IAC7E,iBAAiB,EAAEC,kBAAkB,CAAC;AAAErB,MAAAA,KAAK,EAALA,KAAAA;KAAO,CAAA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ottomWidth: 'thin',
|
|
88
88
|
borderColor: 'surface.border.gray.muted',
|
|
89
89
|
backgroundColorMotionEasing: 'easing.standard',
|
|
90
|
-
backgroundColorMotionDuration: 'duration.xquick'
|
|
90
|
+
backgroundColorMotionDuration: 'duration.xquick',
|
|
91
|
+
groupHeaderBackgroundColor: 'surface.background.gray.moderate'
|
|
91
92
|
};
|
|
92
93
|
var tableToolbar = {
|
|
93
94
|
backgroundColor: 'transparent',
|
|
@@ -132,7 +133,8 @@ var rowDensityToIsTableInputCellMapping = {
|
|
|
132
133
|
var classes = {
|
|
133
134
|
HOVER_ACTIONS: 'hover-actions',
|
|
134
135
|
HOVER_ACTIONS_LAYER2: 'hover-actions-layer-2',
|
|
135
|
-
HOVER_ACTIONS_LAYER3: 'hover-actions-layer-3'
|
|
136
|
+
HOVER_ACTIONS_LAYER3: 'hover-actions-layer-3',
|
|
137
|
+
HAS_ROW_SPANNING: 'has-row-spanning'
|
|
136
138
|
};
|
|
137
139
|
|
|
138
140
|
export { checkboxCellWidth, classes, firstColumnStickyZIndex, refreshWrapperZIndex, rowDensityToIsTableInputCellMapping, tableBackgroundColor, tableEditableCellRowDensityToInputSizeMap, tableFooter, tableHeader, tablePagination, tableRow, tableToolbar, validationStateToInputTrailingIconMap };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokens.js","sources":["../../../../../../src/components/Table/tokens.ts"],"sourcesContent":["import { AlertCircleIcon, CheckIcon } from '~components/Icons';\nimport { size } from '~tokens/global';\n\nconst firstColumnStickyZIndex = 2;\n\nconst refreshWrapperZIndex = 3;\n\nconst checkboxCellWidth = size['44'];\n\nconst tableBackgroundColor = 'surface.background.gray.intense';\nconst tableHeader = {\n paddingTop: 'spacing.5',\n paddingBottom: 'spacing.5',\n paddingLeft: 'spacing.4',\n paddingRight: 'spacing.4',\n backgroundColor: 'interactive.background.gray.default',\n borderBottomAndTopWidth: 'thin',\n borderBottomAndTopColor: 'surface.border.gray.muted',\n} as const;\n\nconst tableFooter = {\n paddingTop: 'spacing.5',\n paddingBottom: 'spacing.5',\n paddingLeft: 'spacing.4',\n paddingRight: 'spacing.4',\n borderBottomAndTopWidth: 'thin',\n borderBottomAndTopColor: 'surface.border.gray.muted',\n backgroundColor: 'interactive.background.gray.default',\n} as const;\n\nconst tableRow = {\n paddingLeft: {\n compact: 'spacing.4',\n normal: 'spacing.4',\n comfortable: 'spacing.4',\n },\n paddingRight: {\n compact: 'spacing.4',\n normal: 'spacing.4',\n comfortable: 'spacing.4',\n },\n minHeight: {\n compact: '36',\n normal: '48',\n comfortable: '60',\n },\n nonStripe: {\n backgroundColor: 'transparent',\n backgroundColorHover: 'interactive.background.gray.default',\n backgroundColorFocus: 'transparent',\n // TODO: Rebranding - on design side: explore pressed state color change, right now both hover & active are same\n backgroundColorActive: 'interactive.background.gray.default',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorSelectedHover: 'interactive.background.primary.fadedHighlighted',\n backgroundColorSelectedFocus: 'interactive.background.primary.faded',\n backgroundColorSelectedActive: 'interactive.background.primary.fadedHighlighted',\n },\n nonStripeWrapper: {\n // not used anywhere\n backgroundColor: 'transparent',\n backgroundColorHover: 'transparent',\n backgroundColorFocus: 'transparent',\n backgroundColorActive: 'interactive.background.gray.default',\n backgroundColorSelected: 'transparent',\n backgroundColorSelectedHover: 'transparent',\n backgroundColorSelectedFocus: 'transparent',\n backgroundColorSelectedActive: 'transparent',\n },\n stripe: {\n backgroundColor: 'transparent',\n backgroundColorHover: 'interactive.background.gray.default',\n backgroundColorFocus: 'transparent',\n backgroundColorActive: 'interactive.background.gray.default',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorSelectedHover: 'interactive.background.primary.fadedHighlighted',\n backgroundColorSelectedFocus: 'interactive.background.primary.faded',\n backgroundColorSelectedActive: 'interactive.background.primary.fadedHighlighted',\n },\n stripeWrapper: {\n backgroundColor: 'interactive.background.gray.default',\n backgroundColorHover: 'interactive.background.gray.default',\n backgroundColorFocus: 'interactive.background.gray.default',\n backgroundColorActive: 'interactive.background.gray.default',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorSelectedHover: 'interactive.background.primary.faded',\n backgroundColorSelectedFocus: 'interactive.background.primary.faded',\n backgroundColorSelectedActive: 'interactive.background.primary.faded',\n },\n borderBottomWidth: 'thin',\n borderColor: 'surface.border.gray.muted',\n backgroundColorMotionEasing: 'easing.standard',\n backgroundColorMotionDuration: 'duration.xquick',\n} as const;\n\nconst tableToolbar = {\n backgroundColor: 'transparent',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorMotionEasing: 'easing.standard',\n backgroundColorMotionDuration: 'duration.xquick',\n} as const;\n\nconst tablePagination = {\n padding: 'spacing.4',\n pageSelectionButton: {\n backgroundColor: 'transparent',\n backgroundColorHover: 'interactive.background.gray.default',\n backgroundColorActive: 'interactive.background.gray.highlighted',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorSelectedHover: 'interactive.background.primary.fadedHighlighted',\n backgroundColorSelectedActive: 'interactive.background.primary.fadedHighlighted',\n padding: 'spacing.2',\n borderRadius: 'small',\n focusRingColor: 'surface.border.primary.muted',\n textColor: 'surface.text.gray.subtle',\n textColorSelected: 'surface.text.primary.normal',\n height: size['32'],\n width: size['32'],\n },\n defaultPageSize: 10,\n} as const;\n\nconst tableEditableCellRowDensityToInputSizeMap = {\n compact: 'medium',\n normal: 'large',\n comfortable: 'medium',\n} as const;\n\nconst validationStateToInputTrailingIconMap = {\n none: undefined,\n success: CheckIcon,\n error: AlertCircleIcon,\n};\n\nconst rowDensityToIsTableInputCellMapping = {\n comfortable: false,\n normal: true,\n compact: true,\n};\n\nconst classes = {\n HOVER_ACTIONS: 'hover-actions',\n HOVER_ACTIONS_LAYER2: 'hover-actions-layer-2',\n HOVER_ACTIONS_LAYER3: 'hover-actions-layer-3',\n};\n\nexport {\n tableHeader,\n tableFooter,\n tableRow,\n tableToolbar,\n tablePagination,\n refreshWrapperZIndex,\n tableBackgroundColor,\n firstColumnStickyZIndex,\n checkboxCellWidth,\n tableEditableCellRowDensityToInputSizeMap,\n validationStateToInputTrailingIconMap,\n rowDensityToIsTableInputCellMapping,\n classes,\n};\n"],"names":["firstColumnStickyZIndex","refreshWrapperZIndex","checkboxCellWidth","size","tableBackgroundColor","tableHeader","paddingTop","paddingBottom","paddingLeft","paddingRight","backgroundColor","borderBottomAndTopWidth","borderBottomAndTopColor","tableFooter","tableRow","compact","normal","comfortable","minHeight","nonStripe","backgroundColorHover","backgroundColorFocus","backgroundColorActive","backgroundColorSelected","backgroundColorSelectedHover","backgroundColorSelectedFocus","backgroundColorSelectedActive","nonStripeWrapper","stripe","stripeWrapper","borderBottomWidth","borderColor","backgroundColorMotionEasing","backgroundColorMotionDuration","tableToolbar","tablePagination","padding","pageSelectionButton","borderRadius","focusRingColor","textColor","textColorSelected","height","width","defaultPageSize","tableEditableCellRowDensityToInputSizeMap","validationStateToInputTrailingIconMap","none","undefined","success","CheckIcon","error","AlertCircleIcon","rowDensityToIsTableInputCellMapping","classes","HOVER_ACTIONS","HOVER_ACTIONS_LAYER2","HOVER_ACTIONS_LAYER3"],"mappings":";;;;;;AAGMA,IAAAA,uBAAuB,GAAG,EAAC;AAE3BC,IAAAA,oBAAoB,GAAG,EAAC;AAE9B,IAAMC,iBAAiB,GAAGC,IAAI,CAAC,IAAI,EAAC;AAE9BC,IAAAA,oBAAoB,GAAG,kCAAiC;AAC9D,IAAMC,WAAW,GAAG;AAClBC,EAAAA,UAAU,EAAE,WAAW;AACvBC,EAAAA,aAAa,EAAE,WAAW;AAC1BC,EAAAA,WAAW,EAAE,WAAW;AACxBC,EAAAA,YAAY,EAAE,WAAW;AACzBC,EAAAA,eAAe,EAAE,qCAAqC;AACtDC,EAAAA,uBAAuB,EAAE,MAAM;AAC/BC,EAAAA,uBAAuB,EAAE,2BAAA;AAC3B,EAAU;AAEV,IAAMC,WAAW,GAAG;AAClBP,EAAAA,UAAU,EAAE,WAAW;AACvBC,E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AChEC,IAAAA,uBAAuB,EAAE,sCAAsC;AAC/DC,IAAAA,4BAA4B,EAAE,iDAAiD;AAC/EE,IAAAA,6BAA6B,EAAE,iDAAiD;AAChFU,IAAAA,OAAO,EAAE,WAAW;AACpBE,IAAAA,YAAY,EAAE,OAAO;AACrBC,IAAAA,cAAc,EAAE,8BAA8B;AAC9CC,IAAAA,SAAS,EAAE,0BAA0B;AACrCC,IAAAA,iBAAiB,EAAE,6BAA6B;AAChDC,IAAAA,MAAM,EAAEvC,IAAI,CAAC,IAAI,CAAC;IAClBwC,KAAK,EAAExC,IAAI,CAAC,IAAI,CAAA;GACjB;AACDyC,EAAAA,eAAe,EAAE,EAAA;AACnB,EAAU;AAEV,IAAMC,yCAAyC,GAAG;AAChD9B,EAAAA,OAAO,EAAE,QAAQ;AACjBC,EAAAA,MAAM,EAAE,OAAO;AACfC,EAAAA,WAAW,EAAE,QAAA;AACf,EAAU;AAEV,IAAM6B,qCAAqC,GAAG;AAC5CC,EAAAA,IAAI,EAAEC,SAAS;AACfC,EAAAA,OAAO,EAAEC,SAAS;AAClBC,EAAAA,KAAK,EAAEC,eAAAA;AACT,EAAC;AAED,IAAMC,mCAAmC,GAAG;AAC1CpC,EAAAA,WAAW,EAAE,KAAK;AAClBD,EAAAA,MAAM,EAAE,IAAI;AACZD,EAAAA,OAAO,EAAE,IAAA;AACX,EAAC;AAED,IAAMuC,OAAO,GAAG;AACdC,EAAAA,aAAa,EAAE,eAAe;AAC9BC,EAAAA,oBAAoB,EAAE,uBAAuB;AAC7CC,EAAAA,oBAAoB,EAAE,uBAAA;AACxB;;;;"}
|
|
1
|
+
{"version":3,"file":"tokens.js","sources":["../../../../../../src/components/Table/tokens.ts"],"sourcesContent":["import { AlertCircleIcon, CheckIcon } from '~components/Icons';\nimport { size } from '~tokens/global';\n\nconst firstColumnStickyZIndex = 2;\n\nconst refreshWrapperZIndex = 3;\n\nconst checkboxCellWidth = size['44'];\n\nconst tableBackgroundColor = 'surface.background.gray.intense';\nconst tableHeader = {\n paddingTop: 'spacing.5',\n paddingBottom: 'spacing.5',\n paddingLeft: 'spacing.4',\n paddingRight: 'spacing.4',\n backgroundColor: 'interactive.background.gray.default',\n borderBottomAndTopWidth: 'thin',\n borderBottomAndTopColor: 'surface.border.gray.muted',\n} as const;\n\nconst tableFooter = {\n paddingTop: 'spacing.5',\n paddingBottom: 'spacing.5',\n paddingLeft: 'spacing.4',\n paddingRight: 'spacing.4',\n borderBottomAndTopWidth: 'thin',\n borderBottomAndTopColor: 'surface.border.gray.muted',\n backgroundColor: 'interactive.background.gray.default',\n} as const;\n\nconst tableRow = {\n paddingLeft: {\n compact: 'spacing.4',\n normal: 'spacing.4',\n comfortable: 'spacing.4',\n },\n paddingRight: {\n compact: 'spacing.4',\n normal: 'spacing.4',\n comfortable: 'spacing.4',\n },\n minHeight: {\n compact: '36',\n normal: '48',\n comfortable: '60',\n },\n nonStripe: {\n backgroundColor: 'transparent',\n backgroundColorHover: 'interactive.background.gray.default',\n backgroundColorFocus: 'transparent',\n // TODO: Rebranding - on design side: explore pressed state color change, right now both hover & active are same\n backgroundColorActive: 'interactive.background.gray.default',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorSelectedHover: 'interactive.background.primary.fadedHighlighted',\n backgroundColorSelectedFocus: 'interactive.background.primary.faded',\n backgroundColorSelectedActive: 'interactive.background.primary.fadedHighlighted',\n },\n nonStripeWrapper: {\n // not used anywhere\n backgroundColor: 'transparent',\n backgroundColorHover: 'transparent',\n backgroundColorFocus: 'transparent',\n backgroundColorActive: 'interactive.background.gray.default',\n backgroundColorSelected: 'transparent',\n backgroundColorSelectedHover: 'transparent',\n backgroundColorSelectedFocus: 'transparent',\n backgroundColorSelectedActive: 'transparent',\n },\n stripe: {\n backgroundColor: 'transparent',\n backgroundColorHover: 'interactive.background.gray.default',\n backgroundColorFocus: 'transparent',\n backgroundColorActive: 'interactive.background.gray.default',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorSelectedHover: 'interactive.background.primary.fadedHighlighted',\n backgroundColorSelectedFocus: 'interactive.background.primary.faded',\n backgroundColorSelectedActive: 'interactive.background.primary.fadedHighlighted',\n },\n stripeWrapper: {\n backgroundColor: 'interactive.background.gray.default',\n backgroundColorHover: 'interactive.background.gray.default',\n backgroundColorFocus: 'interactive.background.gray.default',\n backgroundColorActive: 'interactive.background.gray.default',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorSelectedHover: 'interactive.background.primary.faded',\n backgroundColorSelectedFocus: 'interactive.background.primary.faded',\n backgroundColorSelectedActive: 'interactive.background.primary.faded',\n },\n borderBottomWidth: 'thin',\n borderColor: 'surface.border.gray.muted',\n backgroundColorMotionEasing: 'easing.standard',\n backgroundColorMotionDuration: 'duration.xquick',\n groupHeaderBackgroundColor: 'surface.background.gray.moderate',\n} as const;\n\nconst tableToolbar = {\n backgroundColor: 'transparent',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorMotionEasing: 'easing.standard',\n backgroundColorMotionDuration: 'duration.xquick',\n} as const;\n\nconst tablePagination = {\n padding: 'spacing.4',\n pageSelectionButton: {\n backgroundColor: 'transparent',\n backgroundColorHover: 'interactive.background.gray.default',\n backgroundColorActive: 'interactive.background.gray.highlighted',\n backgroundColorSelected: 'interactive.background.primary.faded',\n backgroundColorSelectedHover: 'interactive.background.primary.fadedHighlighted',\n backgroundColorSelectedActive: 'interactive.background.primary.fadedHighlighted',\n padding: 'spacing.2',\n borderRadius: 'small',\n focusRingColor: 'surface.border.primary.muted',\n textColor: 'surface.text.gray.subtle',\n textColorSelected: 'surface.text.primary.normal',\n height: size['32'],\n width: size['32'],\n },\n defaultPageSize: 10,\n} as const;\n\nconst tableEditableCellRowDensityToInputSizeMap = {\n compact: 'medium',\n normal: 'large',\n comfortable: 'medium',\n} as const;\n\nconst validationStateToInputTrailingIconMap = {\n none: undefined,\n success: CheckIcon,\n error: AlertCircleIcon,\n};\n\nconst rowDensityToIsTableInputCellMapping = {\n comfortable: false,\n normal: true,\n compact: true,\n};\n\nconst classes = {\n HOVER_ACTIONS: 'hover-actions',\n HOVER_ACTIONS_LAYER2: 'hover-actions-layer-2',\n HOVER_ACTIONS_LAYER3: 'hover-actions-layer-3',\n HAS_ROW_SPANNING: 'has-row-spanning',\n};\n\nexport {\n tableHeader,\n tableFooter,\n tableRow,\n tableToolbar,\n tablePagination,\n refreshWrapperZIndex,\n tableBackgroundColor,\n firstColumnStickyZIndex,\n checkboxCellWidth,\n tableEditableCellRowDensityToInputSizeMap,\n validationStateToInputTrailingIconMap,\n rowDensityToIsTableInputCellMapping,\n classes,\n};\n"],"names":["firstColumnStickyZIndex","refreshWrapperZIndex","checkboxCellWidth","size","tableBackgroundColor","tableHeader","paddingTop","paddingBottom","paddingLeft","paddingRight","backgroundColor","borderBottomAndTopWidth","borderBottomAndTopColor","tableFooter","tableRow","compact","normal","comfortable","minHeight","nonStripe","backgroundColorHover","backgroundColorFocus","backgroundColorActive","backgroundColorSelected","backgroundColorSelectedHover","backgroundColorSelectedFocus","backgroundColorSelectedActive","nonStripeWrapper","stripe","stripeWrapper","borderBottomWidth","borderColor","backgroundColorMotionEasing","backgroundColorMotionDuration","groupHeaderBackgroundColor","tableToolbar","tablePagination","padding","pageSelectionButton","borderRadius","focusRingColor","textColor","textColorSelected","height","width","defaultPageSize","tableEditableCellRowDensityToInputSizeMap","validationStateToInputTrailingIconMap","none","undefined","success","CheckIcon","error","AlertCircleIcon","rowDensityToIsTableInputCellMapping","classes","HOVER_ACTIONS","HOVER_ACTIONS_LAYER2","HOVER_ACTIONS_LAYER3","HAS_ROW_SPANNING"],"mappings":";;;;;;AAGMA,IAAAA,uBAAuB,GAAG,EAAC;AAE3BC,IAAAA,oBAAoB,GAAG,EAAC;AAE9B,IAAMC,iBAAiB,GAAGC,IAAI,CAAC,IAAI,EAAC;AAE9BC,IAAAA,oBAAoB,GAAG,kCAAiC;AAC9D,IAAMC,WAAW,GAAG;AAClBC,EAAAA,UAAU,EAAE,W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Ae;AAC9BC,EAAAA,oBAAoB,EAAE,uBAAuB;AAC7CC,EAAAA,oBAAoB,EAAE,uBAAuB;AAC7CC,EAAAA,gBAAgB,EAAE,kBAAA;AACpB;;;;"}
|
|
@@ -21204,7 +21204,7 @@ type InputRowProps = {
|
|
|
21204
21204
|
testID?: string;
|
|
21205
21205
|
};
|
|
21206
21206
|
|
|
21207
|
-
declare const InputRow: React__default.ForwardRefExoticComponent<InputRowProps & React__default.RefAttributes<
|
|
21207
|
+
declare const InputRow: React__default.ForwardRefExoticComponent<InputRowProps & React__default.RefAttributes<HTMLDivElement>>;
|
|
21208
21208
|
|
|
21209
21209
|
type ListItemProps = {
|
|
21210
21210
|
/**
|
|
@@ -26155,6 +26155,35 @@ type TableData<Item> = {
|
|
|
26155
26155
|
nodes: TableNode<Item>[];
|
|
26156
26156
|
};
|
|
26157
26157
|
type TableBackgroundColors = `surface.background.gray.${DotNotationToken<Theme['colors']['surface']['background']['gray']>}`;
|
|
26158
|
+
/**
|
|
26159
|
+
* Common grid spanning properties for table cells
|
|
26160
|
+
*/
|
|
26161
|
+
type TableCellGridSpanningProps = {
|
|
26162
|
+
/**
|
|
26163
|
+
* Grid column start position (1-based). Used for CSS Grid column spanning.
|
|
26164
|
+
* @example
|
|
26165
|
+
* <TableCell gridColumnStart={1} gridColumnEnd={4}>Spans columns 1-3</TableCell>
|
|
26166
|
+
*/
|
|
26167
|
+
gridColumnStart?: number;
|
|
26168
|
+
/**
|
|
26169
|
+
* Grid column end position (1-based). Used for CSS Grid column spanning.
|
|
26170
|
+
* @example
|
|
26171
|
+
* <TableCell gridColumnStart={1} gridColumnEnd={4}>Spans columns 1-3</TableCell>
|
|
26172
|
+
*/
|
|
26173
|
+
gridColumnEnd?: number;
|
|
26174
|
+
/**
|
|
26175
|
+
* Grid row start position (1-based). Used for CSS Grid row spanning.
|
|
26176
|
+
* @example
|
|
26177
|
+
* <TableCell gridRowStart={1} gridRowEnd={3}>Spans rows 1-2</TableCell>
|
|
26178
|
+
*/
|
|
26179
|
+
gridRowStart?: number;
|
|
26180
|
+
/**
|
|
26181
|
+
* Grid row end position (1-based). Used for CSS Grid row spanning.
|
|
26182
|
+
* @example
|
|
26183
|
+
* <TableCell gridRowStart={1} gridRowEnd={3}>Spans rows 1-2</TableCell>
|
|
26184
|
+
*/
|
|
26185
|
+
gridRowEnd?: number;
|
|
26186
|
+
};
|
|
26158
26187
|
type TableHeaderProps = {
|
|
26159
26188
|
/**
|
|
26160
26189
|
* The children of TableHeader should be TableHeaderRow
|
|
@@ -26203,7 +26232,7 @@ type TableHeaderCellProps = {
|
|
|
26203
26232
|
**/
|
|
26204
26233
|
textAlign?: 'left' | 'center' | 'right';
|
|
26205
26234
|
_hasPadding?: boolean;
|
|
26206
|
-
} & DataAnalyticsAttribute;
|
|
26235
|
+
} & TableCellGridSpanningProps & DataAnalyticsAttribute;
|
|
26207
26236
|
type TableProps<Item> = {
|
|
26208
26237
|
/**
|
|
26209
26238
|
* The children of the Table component should be a function that returns TableHeader, TableBody and TableFooter components.
|
|
@@ -26329,6 +26358,12 @@ type TableProps<Item> = {
|
|
|
26329
26358
|
* The backgroundColor prop determines the background color of the table.
|
|
26330
26359
|
**/
|
|
26331
26360
|
backgroundColor?: TableBackgroundColors | 'transparent';
|
|
26361
|
+
/**
|
|
26362
|
+
* The isGrouped prop determines whether the table has grouped data with parent-child relationships or not.
|
|
26363
|
+
* When true, enables tree-aware selection where selecting a parent automatically selects all children.
|
|
26364
|
+
* The default value is `false`.
|
|
26365
|
+
**/
|
|
26366
|
+
isGrouped?: boolean;
|
|
26332
26367
|
} & DataAnalyticsAttribute & StyledPropsBlade;
|
|
26333
26368
|
type Identifier = string | number;
|
|
26334
26369
|
type TableBodyProps<Item> = {
|
|
@@ -26418,7 +26453,12 @@ type TableCellProps = {
|
|
|
26418
26453
|
* @private
|
|
26419
26454
|
*/
|
|
26420
26455
|
_hasPadding?: boolean;
|
|
26421
|
-
|
|
26456
|
+
/**
|
|
26457
|
+
* The backgroundColor prop determines the background color of the table cell.
|
|
26458
|
+
* The default value is `transparent`.
|
|
26459
|
+
**/
|
|
26460
|
+
backgroundColor?: TableBackgroundColors | 'transparent';
|
|
26461
|
+
} & TableCellGridSpanningProps & DataAnalyticsAttribute;
|
|
26422
26462
|
type TableEditableCellProps = Pick<BaseInputProps, 'validationState' | 'placeholder' | 'defaultValue' | 'name' | 'onChange' | 'onFocus' | 'onBlur' | 'value' | 'isDisabled' | 'isRequired' | 'prefix' | 'suffix' | 'maxCharacters' | 'autoFocus' | 'keyboardReturnKeyType' | 'autoCompleteSuggestionType' | 'onSubmit' | 'autoCapitalize' | 'testID' | 'onClick' | 'leadingIcon' | 'trailingButton' | 'errorText' | 'successText'> & {
|
|
26423
26463
|
accessibilityLabel: NonNullable<BaseInputProps['accessibilityLabel']>;
|
|
26424
26464
|
inputType?: Extract<BaseInputProps['type'], 'text' | 'number' | 'email' | 'tel' | 'url'>;
|
|
@@ -26459,7 +26499,7 @@ type TableFooterCellProps = {
|
|
|
26459
26499
|
* The default value is `left`.
|
|
26460
26500
|
**/
|
|
26461
26501
|
textAlign?: 'left' | 'center' | 'right';
|
|
26462
|
-
} & DataAnalyticsAttribute;
|
|
26502
|
+
} & TableCellGridSpanningProps & DataAnalyticsAttribute;
|
|
26463
26503
|
type TablePaginationCommonProps = {
|
|
26464
26504
|
/**
|
|
26465
26505
|
* The default page size.
|
|
@@ -26563,19 +26603,19 @@ type TableToolbarActionsProps = {
|
|
|
26563
26603
|
children?: React__default.ReactNode;
|
|
26564
26604
|
} & StyledPropsBlade & DataAnalyticsAttribute;
|
|
26565
26605
|
|
|
26566
|
-
declare const Table: <Item>({ children, data, multiSelectTrigger, selectionType, onSelectionChange, isHeaderSticky, isFooterSticky, isFirstColumnSticky, rowDensity, onSortChange, sortFunctions, toolbar, pagination, height, showStripedRows, gridTemplateColumns, isLoading, isRefreshing, showBorderedCells, defaultSelectedIds, backgroundColor, ...rest }: TableProps<Item>) => React__default.ReactElement;
|
|
26606
|
+
declare const Table: <Item>({ children, data, multiSelectTrigger, selectionType, onSelectionChange, isHeaderSticky, isFooterSticky, isFirstColumnSticky, rowDensity, onSortChange, sortFunctions, toolbar, pagination, height, showStripedRows, gridTemplateColumns, isLoading, isRefreshing, showBorderedCells, defaultSelectedIds, backgroundColor, isGrouped, ...rest }: TableProps<Item>) => React__default.ReactElement;
|
|
26567
26607
|
|
|
26568
26608
|
declare const TableHeader: ({ children, ...rest }: TableHeaderRowProps) => React__default.ReactElement;
|
|
26569
|
-
declare const TableHeaderCell: ({ children, headerKey, _hasPadding, textAlign, ...rest }: TableHeaderCellProps) => React__default.ReactElement;
|
|
26609
|
+
declare const TableHeaderCell: ({ children, headerKey, _hasPadding, textAlign, gridColumnStart, gridColumnEnd, gridRowStart, gridRowEnd, ...rest }: TableHeaderCellProps) => React__default.ReactElement;
|
|
26570
26610
|
declare const TableHeaderRow: ({ children, rowDensity, ...rest }: TableHeaderRowProps) => React__default.ReactElement;
|
|
26571
26611
|
|
|
26572
26612
|
declare const TableBody: <Item>({ children, ...rest }: TableBodyProps<Item>) => React__default.ReactElement;
|
|
26573
|
-
declare const TableCell: ({ children, textAlign, _hasPadding, ...rest }: TableCellProps) => React__default.ReactElement;
|
|
26613
|
+
declare const TableCell: ({ children, textAlign, _hasPadding, gridColumnStart, gridColumnEnd, gridRowStart, gridRowEnd, ...rest }: TableCellProps) => React__default.ReactElement;
|
|
26574
26614
|
declare const TableRow: <Item>({ children, item, isDisabled, onHover, onClick, hoverActions, testID, ...rest }: TableRowProps<Item>) => React__default.ReactElement;
|
|
26575
26615
|
|
|
26576
26616
|
declare const TableFooter: ({ children, ...rest }: TableFooterProps) => React__default.ReactElement;
|
|
26577
26617
|
declare const TableFooterRow: ({ children, ...rest }: TableFooterRowProps) => React__default.ReactElement;
|
|
26578
|
-
declare const TableFooterCell: ({ children, textAlign, ...rest }: TableFooterCellProps) => React__default.ReactElement;
|
|
26618
|
+
declare const TableFooterCell: ({ children, textAlign, gridColumnStart, gridColumnEnd, gridRowStart, gridRowEnd, ...rest }: TableFooterCellProps) => React__default.ReactElement;
|
|
26579
26619
|
|
|
26580
26620
|
declare const TablePagination: ({ currentPage: controlledCurrentPage, onPageChange, onPageSizeChange, defaultPageSize, showPageSizePicker, showPageNumberSelector, showLabel, label, totalItemCount, paginationType, ...rest }: TablePaginationProps) => React__default.ReactElement;
|
|
26581
26621
|
|
|
@@ -14988,6 +14988,35 @@ type TableData<Item> = {
|
|
|
14988
14988
|
nodes: TableNode<Item>[];
|
|
14989
14989
|
};
|
|
14990
14990
|
type TableBackgroundColors = `surface.background.gray.${DotNotationToken<Theme['colors']['surface']['background']['gray']>}`;
|
|
14991
|
+
/**
|
|
14992
|
+
* Common grid spanning properties for table cells
|
|
14993
|
+
*/
|
|
14994
|
+
type TableCellGridSpanningProps = {
|
|
14995
|
+
/**
|
|
14996
|
+
* Grid column start position (1-based). Used for CSS Grid column spanning.
|
|
14997
|
+
* @example
|
|
14998
|
+
* <TableCell gridColumnStart={1} gridColumnEnd={4}>Spans columns 1-3</TableCell>
|
|
14999
|
+
*/
|
|
15000
|
+
gridColumnStart?: number;
|
|
15001
|
+
/**
|
|
15002
|
+
* Grid column end position (1-based). Used for CSS Grid column spanning.
|
|
15003
|
+
* @example
|
|
15004
|
+
* <TableCell gridColumnStart={1} gridColumnEnd={4}>Spans columns 1-3</TableCell>
|
|
15005
|
+
*/
|
|
15006
|
+
gridColumnEnd?: number;
|
|
15007
|
+
/**
|
|
15008
|
+
* Grid row start position (1-based). Used for CSS Grid row spanning.
|
|
15009
|
+
* @example
|
|
15010
|
+
* <TableCell gridRowStart={1} gridRowEnd={3}>Spans rows 1-2</TableCell>
|
|
15011
|
+
*/
|
|
15012
|
+
gridRowStart?: number;
|
|
15013
|
+
/**
|
|
15014
|
+
* Grid row end position (1-based). Used for CSS Grid row spanning.
|
|
15015
|
+
* @example
|
|
15016
|
+
* <TableCell gridRowStart={1} gridRowEnd={3}>Spans rows 1-2</TableCell>
|
|
15017
|
+
*/
|
|
15018
|
+
gridRowEnd?: number;
|
|
15019
|
+
};
|
|
14991
15020
|
type TableHeaderProps = {
|
|
14992
15021
|
/**
|
|
14993
15022
|
* The children of TableHeader should be TableHeaderRow
|
|
@@ -15036,7 +15065,7 @@ type TableHeaderCellProps = {
|
|
|
15036
15065
|
**/
|
|
15037
15066
|
textAlign?: 'left' | 'center' | 'right';
|
|
15038
15067
|
_hasPadding?: boolean;
|
|
15039
|
-
} & DataAnalyticsAttribute;
|
|
15068
|
+
} & TableCellGridSpanningProps & DataAnalyticsAttribute;
|
|
15040
15069
|
type TableProps<Item> = {
|
|
15041
15070
|
/**
|
|
15042
15071
|
* The children of the Table component should be a function that returns TableHeader, TableBody and TableFooter components.
|
|
@@ -15162,6 +15191,12 @@ type TableProps<Item> = {
|
|
|
15162
15191
|
* The backgroundColor prop determines the background color of the table.
|
|
15163
15192
|
**/
|
|
15164
15193
|
backgroundColor?: TableBackgroundColors | 'transparent';
|
|
15194
|
+
/**
|
|
15195
|
+
* The isGrouped prop determines whether the table has grouped data with parent-child relationships or not.
|
|
15196
|
+
* When true, enables tree-aware selection where selecting a parent automatically selects all children.
|
|
15197
|
+
* The default value is `false`.
|
|
15198
|
+
**/
|
|
15199
|
+
isGrouped?: boolean;
|
|
15165
15200
|
} & DataAnalyticsAttribute & StyledPropsBlade;
|
|
15166
15201
|
type Identifier = string | number;
|
|
15167
15202
|
type TableBodyProps<Item> = {
|
|
@@ -15251,7 +15286,12 @@ type TableCellProps = {
|
|
|
15251
15286
|
* @private
|
|
15252
15287
|
*/
|
|
15253
15288
|
_hasPadding?: boolean;
|
|
15254
|
-
|
|
15289
|
+
/**
|
|
15290
|
+
* The backgroundColor prop determines the background color of the table cell.
|
|
15291
|
+
* The default value is `transparent`.
|
|
15292
|
+
**/
|
|
15293
|
+
backgroundColor?: TableBackgroundColors | 'transparent';
|
|
15294
|
+
} & TableCellGridSpanningProps & DataAnalyticsAttribute;
|
|
15255
15295
|
type TableEditableCellProps = Pick<BaseInputProps, 'validationState' | 'placeholder' | 'defaultValue' | 'name' | 'onChange' | 'onFocus' | 'onBlur' | 'value' | 'isDisabled' | 'isRequired' | 'prefix' | 'suffix' | 'maxCharacters' | 'autoFocus' | 'keyboardReturnKeyType' | 'autoCompleteSuggestionType' | 'onSubmit' | 'autoCapitalize' | 'testID' | 'onClick' | 'leadingIcon' | 'trailingButton' | 'errorText' | 'successText'> & {
|
|
15256
15296
|
accessibilityLabel: NonNullable<BaseInputProps['accessibilityLabel']>;
|
|
15257
15297
|
inputType?: Extract<BaseInputProps['type'], 'text' | 'number' | 'email' | 'tel' | 'url'>;
|
|
@@ -15292,7 +15332,7 @@ type TableFooterCellProps = {
|
|
|
15292
15332
|
* The default value is `left`.
|
|
15293
15333
|
**/
|
|
15294
15334
|
textAlign?: 'left' | 'center' | 'right';
|
|
15295
|
-
} & DataAnalyticsAttribute;
|
|
15335
|
+
} & TableCellGridSpanningProps & DataAnalyticsAttribute;
|
|
15296
15336
|
type TablePaginationCommonProps = {
|
|
15297
15337
|
/**
|
|
15298
15338
|
* The default page size.
|