Skip to content

Commit 33bd050

Browse files
committed
add individual examples for data-table icon and header scanarios
1 parent 96f775f commit 33bd050

File tree

1 file changed

+35
-2
lines changed

1 file changed

+35
-2
lines changed

ui/components/data-tables/advanced/example.jsx

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -261,15 +261,48 @@ export let states = [
261261

262262
export let examples = [
263263
{
264-
id: 'header-and-cell-icon',
265-
label: 'Header and Cell Icon',
264+
id: 'header-icon-menu-button',
265+
label: 'Header Icon and Menu Button',
266266
element: (
267267
<Table>
268268
<Thead
269+
actionableMode
269270
columns={columns}
270271
columnsWithEinstein={['Confidence']}
271272
hasMenus
272273
/>
274+
<tbody>
275+
{_.times(rows.length, i => (
276+
<AdvancedDataTableTr key={i} index={i + 1} {...rows[i]} />
277+
))}
278+
</tbody>
279+
</Table>
280+
)
281+
},
282+
{
283+
id: 'header-menu-button',
284+
label: 'Header Menu Button',
285+
element: (
286+
<Table>
287+
<Thead actionableMode columns={columns} hasMenus />
288+
<tbody>
289+
{_.times(rows.length, i => (
290+
<AdvancedDataTableTr key={i} index={i + 1} {...rows[i]} />
291+
))}
292+
</tbody>
293+
</Table>
294+
)
295+
},
296+
{
297+
id: 'cell-icon',
298+
label: 'Cell Icon',
299+
element: (
300+
<Table>
301+
<Thead
302+
actionableMode
303+
className="slds-has-button-menu"
304+
columns={columns}
305+
/>
273306
<tbody>
274307
{_.times(rows.length, i => (
275308
<AdvancedDataTableTr key={i} index={i + 1} {...rows[i]} hasScores />

0 commit comments

Comments
 (0)