@czi-sds/mcp 0.3.0 → 0.4.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.
Files changed (145) hide show
  1. package/data/component-props/Accordion.json +14 -15
  2. package/data/component-props/Alert.json +2 -44
  3. package/data/component-props/Autocomplete.json +14 -32
  4. package/data/component-props/Banner.json +11 -12
  5. package/data/component-props/Button.json +17 -82
  6. package/data/component-props/ButtonDropdown.json +26 -0
  7. package/data/component-props/ButtonIcon.json +4 -60
  8. package/data/component-props/ButtonToggle.json +2 -66
  9. package/data/component-props/Callout.json +11 -65
  10. package/data/component-props/CellBasic.json +28 -56
  11. package/data/component-props/CellComponent.json +4 -32
  12. package/data/component-props/CellHeader.json +13 -49
  13. package/data/component-props/ComplexFilter.json +24 -4
  14. package/data/component-props/ContentCard.json +66 -2
  15. package/data/component-props/Dialog.json +26 -0
  16. package/data/component-props/Dropdown.json +29 -67
  17. package/data/component-props/DropdownMenu.json +16 -56
  18. package/data/component-props/HeatmapChart.json +6 -87
  19. package/data/component-props/Icon.json +3 -8
  20. package/data/component-props/InputCheckbox.json +5 -53
  21. package/data/component-props/InputDropdown.json +11 -33
  22. package/data/component-props/InputRadio.json +5 -53
  23. package/data/component-props/InputSearch.json +6 -70
  24. package/data/component-props/InputSlider.json +21 -35
  25. package/data/component-props/InputText.json +7 -63
  26. package/data/component-props/InputToggle.json +5 -54
  27. package/data/component-props/Link.json +18 -0
  28. package/data/component-props/LoadingIndicator.json +1 -2
  29. package/data/component-props/MenuItem.json +11 -41
  30. package/data/component-props/MenuSelect.json +4 -67
  31. package/data/component-props/NavigationFooter.json +0 -8
  32. package/data/component-props/NavigationHeader.json +14 -65
  33. package/data/component-props/NavigationJumpTo.json +0 -40
  34. package/data/component-props/Notification.json +14 -58
  35. package/data/component-props/Pagination.json +8 -33
  36. package/data/component-props/Panel.json +4 -54
  37. package/data/component-props/SegmentedControl.json +0 -55
  38. package/data/component-props/TableRow.json +10 -38
  39. package/data/component-props/Tabs.json +18 -0
  40. package/data/component-props/Tag.json +10 -56
  41. package/data/component-props/TagFilter.json +0 -47
  42. package/data/component-props/Tooltip.json +12 -61
  43. package/data/component-props/TooltipCondensed.json +18 -0
  44. package/data/component-props/TooltipTable.json +0 -4
  45. package/data/zeroheight-exports/Accordion.md +167 -125
  46. package/data/zeroheight-exports/Banner.md +71 -48
  47. package/data/zeroheight-exports/Borders.md +72 -73
  48. package/data/zeroheight-exports/Buttons.md +375 -330
  49. package/data/zeroheight-exports/Callout.md +138 -116
  50. package/data/zeroheight-exports/Colors.md +254 -255
  51. package/data/zeroheight-exports/Content-Card.md +36 -37
  52. package/data/zeroheight-exports/Contributing-to-SDS.md +34 -35
  53. package/data/zeroheight-exports/Control-Inputs.md +289 -234
  54. package/data/zeroheight-exports/Corners.md +63 -64
  55. package/data/zeroheight-exports/Cover-page.md +0 -1
  56. package/data/zeroheight-exports/Dialog.md +237 -179
  57. package/data/zeroheight-exports/Downloads.md +10 -11
  58. package/data/zeroheight-exports/Drop-Shadows.md +40 -41
  59. package/data/zeroheight-exports/Dropdown-Input.md +158 -127
  60. package/data/zeroheight-exports/Dropdown-Menu.md +814 -718
  61. package/data/zeroheight-exports/Element-Status-Tracker.md +191 -192
  62. package/data/zeroheight-exports/Field-Inputs.md +149 -130
  63. package/data/zeroheight-exports/Filters.md +114 -94
  64. package/data/zeroheight-exports/Getting-Started.md +112 -249
  65. package/data/zeroheight-exports/Hero.md +43 -37
  66. package/data/zeroheight-exports/Icons.md +205 -206
  67. package/data/zeroheight-exports/Intent.md +6 -7
  68. package/data/zeroheight-exports/Introduction-to-Bases.md +8 -9
  69. package/data/zeroheight-exports/Introduction-to-Cells.md +11 -12
  70. package/data/zeroheight-exports/Introduction-to-DNA.md +8 -9
  71. package/data/zeroheight-exports/Introduction-to-Genes.md +8 -9
  72. package/data/zeroheight-exports/Introduction.md +52 -53
  73. package/data/zeroheight-exports/Link.md +50 -37
  74. package/data/zeroheight-exports/Lists.md +78 -63
  75. package/data/zeroheight-exports/Loading-Indicator.md +7 -8
  76. package/data/zeroheight-exports/Navigation.md +163 -142
  77. package/data/zeroheight-exports/Notification.md +132 -102
  78. package/data/zeroheight-exports/Panel.md +231 -115
  79. package/data/zeroheight-exports/Responsive-Design.md +35 -32
  80. package/data/zeroheight-exports/Search-Input.md +9 -10
  81. package/data/zeroheight-exports/Search.md +87 -104
  82. package/data/zeroheight-exports/Segmented-Control.md +68 -45
  83. package/data/zeroheight-exports/Spacing.md +210 -211
  84. package/data/zeroheight-exports/Table.md +414 -302
  85. package/data/zeroheight-exports/Tabs.md +126 -98
  86. package/data/zeroheight-exports/Tags.md +148 -118
  87. package/data/zeroheight-exports/Text-Link.md +32 -33
  88. package/data/zeroheight-exports/Theming.md +48 -29
  89. package/data/zeroheight-exports/Tooltips.md +253 -237
  90. package/data/zeroheight-exports/Typography.md +463 -464
  91. package/dist/stdio.js +44 -132
  92. package/package.json +3 -4
  93. package/data/component-props/Chip.json +0 -73
  94. package/data/component-props/List.json +0 -43
  95. package/data/component-props/Menu.json +0 -48
  96. package/data/component-props/Table.json +0 -26
  97. package/data/component-props-storybook/Accordion-storybook.json +0 -45
  98. package/data/component-props-storybook/Alert-storybook.json +0 -30
  99. package/data/component-props-storybook/Autocomplete-storybook.json +0 -67
  100. package/data/component-props-storybook/Banner-storybook.json +0 -78
  101. package/data/component-props-storybook/Button-storybook.json +0 -115
  102. package/data/component-props-storybook/ButtonDropdown-storybook.json +0 -73
  103. package/data/component-props-storybook/ButtonIcon-storybook.json +0 -60
  104. package/data/component-props-storybook/ButtonToggle-storybook.json +0 -68
  105. package/data/component-props-storybook/Callout-storybook.json +0 -90
  106. package/data/component-props-storybook/CellBasic-storybook.json +0 -138
  107. package/data/component-props-storybook/CellComponent-storybook.json +0 -48
  108. package/data/component-props-storybook/CellHeader-storybook.json +0 -71
  109. package/data/component-props-storybook/Chip-storybook.json +0 -26
  110. package/data/component-props-storybook/ComplexFilter-storybook.json +0 -60
  111. package/data/component-props-storybook/ContentCard-storybook.json +0 -175
  112. package/data/component-props-storybook/Dialog-storybook.json +0 -56
  113. package/data/component-props-storybook/Dropdown-storybook.json +0 -93
  114. package/data/component-props-storybook/DropdownMenu-storybook.json +0 -73
  115. package/data/component-props-storybook/HeatmapChart-storybook.json +0 -55
  116. package/data/component-props-storybook/Icon-storybook.json +0 -75
  117. package/data/component-props-storybook/InputCheckbox-storybook.json +0 -57
  118. package/data/component-props-storybook/InputDropdown-storybook.json +0 -80
  119. package/data/component-props-storybook/InputRadio-storybook.json +0 -56
  120. package/data/component-props-storybook/InputSearch-storybook.json +0 -55
  121. package/data/component-props-storybook/InputSlider-storybook.json +0 -55
  122. package/data/component-props-storybook/InputText-storybook.json +0 -59
  123. package/data/component-props-storybook/InputToggle-storybook.json +0 -42
  124. package/data/component-props-storybook/Link-storybook.json +0 -50
  125. package/data/component-props-storybook/List-storybook.json +0 -26
  126. package/data/component-props-storybook/LoadingIndicator-storybook.json +0 -34
  127. package/data/component-props-storybook/Menu-storybook.json +0 -26
  128. package/data/component-props-storybook/MenuItem-storybook.json +0 -74
  129. package/data/component-props-storybook/MenuSelect-storybook.json +0 -38
  130. package/data/component-props-storybook/NavigationFooter-storybook.json +0 -67
  131. package/data/component-props-storybook/NavigationHeader-storybook.json +0 -115
  132. package/data/component-props-storybook/NavigationJumpTo-storybook.json +0 -41
  133. package/data/component-props-storybook/Notification-storybook.json +0 -89
  134. package/data/component-props-storybook/Pagination-storybook.json +0 -50
  135. package/data/component-props-storybook/Panel-storybook.json +0 -52
  136. package/data/component-props-storybook/SegmentedControl-storybook.json +0 -30
  137. package/data/component-props-storybook/Table-storybook.json +0 -26
  138. package/data/component-props-storybook/TableHeader-storybook.json +0 -26
  139. package/data/component-props-storybook/TableRow-storybook.json +0 -62
  140. package/data/component-props-storybook/Tabs-storybook.json +0 -45
  141. package/data/component-props-storybook/Tag-storybook.json +0 -78
  142. package/data/component-props-storybook/TagFilter-storybook.json +0 -30
  143. package/data/component-props-storybook/Tooltip-storybook.json +0 -85
  144. package/data/component-props-storybook/TooltipCondensed-storybook.json +0 -38
  145. package/data/component-props-storybook/TooltipTable-storybook.json +0 -47
@@ -6,8 +6,8 @@ Tables are used to store and visually organize data and other content into a ser
6
6
 
7
7
  ## Table elements
8
8
 
9
- | Tables are made up of a Table Header with as many Table Rows stacked below it as needed. Table Headers contain multiple Header Cells which serve as top-level indicators for the type of content found in the column of cells below each. Similarly, Table Rows are comprised of Basic Cells which contain the bulk of the data within a Table. Follow the usage criteria accompanying each variant as a guide for building a Table for any use case. | | **Jump to element:** Table Anatomy Basic Cell Header Cell Table Row Table Header |
10
- | --- | --- | --- |
9
+ | Tables are made up of a Table Header with as many Table Rows stacked below it as needed. Table Headers contain multiple Header Cells which serve as top-level indicators for the type of content found in the column of cells below each. Similarly, Table Rows are comprised of Basic Cells which contain the bulk of the data within a Table. Follow the usage criteria accompanying each variant as a guide for building a Table for any use case. | | **Jump to element:** Table Anatomy Basic Cell Header Cell Table Row Table Header |
10
+ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --- | -------------------------------------------------------------------------------- |
11
11
 
12
12
  ---
13
13
 
@@ -17,8 +17,8 @@ Tables are used to store and visually organize data and other content into a ser
17
17
 
18
18
  ## Basic Cell
19
19
 
20
- | | In Figma | | | Meets Accessibility | | | In napari hub + .org Codebases |
21
- | --- | --- | --- | --- | --- | --- | --- | --- |
20
+ | | In Figma | | | Meets Accessibility | | | In napari hub + .org Codebases |
21
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------------------------------ |
22
22
 
23
23
  The Basic Cell is the most common cell type comprising a Table. It is intended to be filled with strings of text or numerical values.
24
24
 
@@ -36,14 +36,14 @@ Click on each variant below to enter inspect view and get details on its code at
36
36
 
37
37
  These rules establish how much margin should exist between and around elements. Multiple Basic Cells are placed beside each other to create a Table Row. Stack Table Rows below a Table Header to create a full Table.
38
38
 
39
-  
39
+
40
40
 
41
41
  ---
42
42
 
43
43
  ## Header Cell
44
44
 
45
- | | In Figma | | | Meets Accessibility | | | In napari hub + .org Codebases |
46
- | --- | --- | --- | --- | --- | --- | --- | --- |
45
+ | | In Figma | | | Meets Accessibility | | | In napari hub + .org Codebases |
46
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------------------------------ |
47
47
 
48
48
  Header Cells are placed at the top of Table columns and serve as the header or indicator of the content found in the cells below it.
49
49
 
@@ -65,8 +65,8 @@ These rules establish how much margin should exist between and around elements.
65
65
 
66
66
  ## Table Row
67
67
 
68
- | | In Figma | | | Meets Accessibility | | | In napari hub + .org Codebases |
69
- | --- | --- | --- | --- | --- | --- | --- | --- |
68
+ | | In Figma | | | Meets Accessibility | | | In napari hub + .org Codebases |
69
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------------------------------ |
70
70
 
71
71
  A Table Row is a container filled with multiple Basic Cells placed side-by-side to form a row of different, but related pieces of information that all connect back to the same data source, such as a collected sample. Each data source should have its own row, meaning the Table will have as many Table Rows as there are data sources.
72
72
 
@@ -82,8 +82,8 @@ These rules establish how much margin should exist between and around elements.
82
82
 
83
83
  ## Table Header
84
84
 
85
- | | In Figma | | | Meets Accessibility | | | In napari hub + .org Codebases |
86
- | --- | --- | --- | --- | --- | --- | --- | --- |
85
+ | | In Figma | | | Meets Accessibility | | | In napari hub + .org Codebases |
86
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------------------------------ |
87
87
 
88
88
  A Table Header is a container filled with multiple Header Cells placed side-by-side to form a header row. This row is placed at the top of the Table with each Header Cell in the row serving as the column header for the data in the content cells below it. There can only be one Table Header per Table.
89
89
 
@@ -97,12 +97,12 @@ These rules establish how much margin should exist between and around elements.
97
97
 
98
98
  ## Table Components
99
99
 
100
- | Below you will find an interactive Storybook iframe for Tables. Tabs within each iframe provide a different set of tools: The Controls tab allows you to see and adjust all available props. The Actions tab shows you data displayed by event handler arguments. | | **Jump to component:** CellBasic CellHeader TableRow TableHeader Table |
101
- | --- | --- | --- |
100
+ | Below you will find an interactive Storybook iframe for Tables. Tabs within each iframe provide a different set of tools: The Controls tab allows you to see and adjust all available props. The Actions tab shows you data displayed by event handler arguments. | | **Jump to component:** CellBasic CellHeader TableRow TableHeader Table |
101
+ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --- | ---------------------------------------------------------------------- |
102
102
 
103
103
  ---
104
104
 
105
- >This component appears as it is in the default SDS codebase. Once imported into the napari hub or napari.org codebases, use a theme file to enable the napari visual appearance customization.
105
+ > This component appears as it is in the default SDS codebase. Once imported into the napari hub or napari.org codebases, use a theme file to enable the napari visual appearance customization.
106
106
 
107
107
  The technical documentation and code demos can be found here.
108
108
 
@@ -142,21 +142,21 @@ Tables are used to store and visually organize data and other content into a ser
142
142
 
143
143
  ## Table elements
144
144
 
145
- | Tables can be sorted, either ascending or descending, by clicking on any Header Cell that has sorting enabled. This will rearrange all of the content in the Table by the category in that column. Filters are often used in conjunction with Tables, allowing users to manipulate what content is viewable in the Table by the parameters indicated in the Filter. Follow the usage criteria accompanying each variant as a guide for building a Table for any use case. | | **Jump to element:** Table Anatomy Content Cells Header Cell Table Row Table Header CZ ID Tables |
146
- | --- | --- | --- |
145
+ | Tables can be sorted, either ascending or descending, by clicking on any Header Cell that has sorting enabled. This will rearrange all of the content in the Table by the category in that column. Filters are often used in conjunction with Tables, allowing users to manipulate what content is viewable in the Table by the parameters indicated in the Filter. Follow the usage criteria accompanying each variant as a guide for building a Table for any use case. | | **Jump to element:** Table Anatomy Content Cells Header Cell Table Row Table Header CZ ID Tables |
146
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --- | ------------------------------------------------------------------------------------------------ |
147
147
 
148
148
  ---
149
149
 
150
150
  ## Table Anatomy
151
151
 
152
- Tables are made up of a Table Header with as many Table Rows stacked below it as needed. Table Headers contain multiple Header Cells which serve as top-level indicators for the type of content found in the column of cells below each. Similarly, Table Rows are comprised of two different types of content cells, Basic Cells and Component Cells; these cell types contain the bulk of the data within a Table and are designed to be flexible in their ability to hold nearly any type of content. For Tables with large amounts of data, only data from visible cells will be loaded (colloquially known as *lazy load*); as the user scrolls down the Table, additional data will be pulled from the server and displayed once the data has fully loaded.
152
+ Tables are made up of a Table Header with as many Table Rows stacked below it as needed. Table Headers contain multiple Header Cells which serve as top-level indicators for the type of content found in the column of cells below each. Similarly, Table Rows are comprised of two different types of content cells, Basic Cells and Component Cells; these cell types contain the bulk of the data within a Table and are designed to be flexible in their ability to hold nearly any type of content. For Tables with large amounts of data, only data from visible cells will be loaded (colloquially known as _lazy load_); as the user scrolls down the Table, additional data will be pulled from the server and displayed once the data has fully loaded.
153
153
 
154
154
  ---
155
155
 
156
156
  ## Content Cells
157
157
 
158
- | | In Figma | | | Meets Accessibility | | | In CZ ID Codebase |
159
- | --- | --- | --- | --- | --- | --- | --- | --- |
158
+ | | In Figma | | | Meets Accessibility | | | In CZ ID Codebase |
159
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ----------------- |
160
160
 
161
161
  ### Basic Cell
162
162
 
@@ -174,7 +174,7 @@ Click on each variant below to enter inspect view and get details on its code at
174
174
 
175
175
  **Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
176
176
 
177
-  
177
+
178
178
 
179
179
  ---
180
180
 
@@ -212,14 +212,14 @@ Click on each variant below to enter inspect view and get details on its code at
212
212
 
213
213
  These rules establish how much margin should exist between and around elements. Multiple content cells are placed beside each other to create a Table Row. Stack Table Rows below a Table Header to create a full Table.
214
214
 
215
-  
215
+
216
216
 
217
217
  ---
218
218
 
219
219
  ## Header Cell
220
220
 
221
- | | In Figma | | | Meets Accessibility | | | In CZ ID Codebase |
222
- | --- | --- | --- | --- | --- | --- | --- | --- |
221
+ | | In Figma | | | Meets Accessibility | | | In CZ ID Codebase |
222
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ----------------- |
223
223
 
224
224
  Header Cells are placed at the top of Table columns and serve as the header or indicator of the content found in the cells below it.
225
225
 
@@ -230,11 +230,11 @@ Users are able to manually sort columns in ascending or descending order by clic
230
230
  Each Header Cell can have an optional Tooltip appear when hovered over by using the `shouldShowTooltipOnHover` prop. This can be used to display supplemental information or help further define the contents of the column.
231
231
 
232
232
  | **Default** | **Hover** |
233
- | --- | --- |
233
+ | ----------- | --------- |
234
234
 
235
235
  ---
236
236
 
237
-  
237
+
238
238
 
239
239
  ### Header Cell Variants
240
240
 
@@ -260,8 +260,8 @@ These rules establish how much margin should exist between and around elements.
260
260
 
261
261
  ## Table Row
262
262
 
263
- | | In Figma | | | Meets Accessibility | | | In CZ ID Codebase |
264
- | --- | --- | --- | --- | --- | --- | --- | --- |
263
+ | | In Figma | | | Meets Accessibility | | | In CZ ID Codebase |
264
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ----------------- |
265
265
 
266
266
  A Table Row is a container filled with multiple content cells placed side-by-side to form a row of different, but related pieces of information that all connect back to the same data source, such as a collected sample. Each data source should have its own row, meaning the Table will have as many Table Rows as there are data sources.
267
267
 
@@ -277,7 +277,7 @@ Use the `disabled` prop to gray out all of the cells in the row and make it so u
277
277
 
278
278
  Click on each variant below to enter inspect view and get details on its code attributes and any global styles it uses.
279
279
 
280
-  
280
+
281
281
 
282
282
  ---
283
283
 
@@ -295,17 +295,17 @@ For advanced Tables, Table Rows may have actions tied to them, such as the abili
295
295
 
296
296
  An overflow Icon Button, represented by the `DotsHorizontal3` icon (2), can be used to surface a Dropdown Menu (3) that contains additional actions. This should be used in instances where a large number of actions are needed (generally more than three) or the designer wants to save space in wide Tables that contain many columns. Table Row Actions can either be exposed on hover or can be persistent in the Table at all times.
297
297
 
298
-  
298
+
299
299
 
300
300
  For efficiency, Tables can be designed to allow users to complete actions across multiple Table Rows at the same time, known as bulk actions. Similar to row actions, bulk actions are completed by clicking on corresponding Icon Buttons that are located at the top right of the Table, above the Table Header; they should be inactive when no rows are selected (1).
301
301
 
302
-  
302
+
303
303
 
304
304
  To make Table Rows selectable, designers must include Checkbox Inputs in the first column of the row, providing an input for users to click on and select the row (2); enable the Table Row's `selected` prop to indicate when rows are selected. Once rows are selected, any applicable bulk action Icon Button should become active to allow users to take action across all selected rows (3). In addition to these Icon Buttons, there should be a counter present that indicates how many rows have been selected (4).
305
305
 
306
306
  Because actions taken at the row level will impact stored data in the application, row and bulk actions are completely controlled by the application itself and not the SDS component.
307
307
 
308
-  
308
+
309
309
 
310
310
  ---
311
311
 
@@ -317,8 +317,8 @@ These rules establish how much margin should exist between and around elements.
317
317
 
318
318
  ## Table Header
319
319
 
320
- | | In Figma | | | Meets Accessibility | | | In CZ ID Codebase |
321
- | --- | --- | --- | --- | --- | --- | --- | --- |
320
+ | | In Figma | | | Meets Accessibility | | | In CZ ID Codebase |
321
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ----------------- |
322
322
 
323
323
  A Table Header is a container filled with multiple Header Cells placed side-by-side to form a header row. This row is placed at the top of the Table with each Header Cell in the row serving as the column header for the data in the content cells below it. There can only be one Table Header per Table.
324
324
 
@@ -348,8 +348,8 @@ The following Table configurations are currently in use in CZ ID.
348
348
 
349
349
  ## Table Components
350
350
 
351
- | Below you will find an interactive Storybook iframe for Tables. Tabs within each iframe provide a different set of tools: The Controls tab allows you to see and adjust all available props. The Actions tab shows you data displayed by event handler arguments. | | **Jump to component:** CellBasic CellComponent CellHeader TableRow TableHeader Table |
352
- | --- | --- | --- |
351
+ | Below you will find an interactive Storybook iframe for Tables. Tabs within each iframe provide a different set of tools: The Controls tab allows you to see and adjust all available props. The Actions tab shows you data displayed by event handler arguments. | | **Jump to component:** CellBasic CellComponent CellHeader TableRow TableHeader Table |
352
+ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --- | ------------------------------------------------------------------------------------ |
353
353
 
354
354
  ---
355
355
 
@@ -361,7 +361,7 @@ Storybook
361
361
 
362
362
  ---
363
363
 
364
-  
364
+
365
365
 
366
366
  ### CellComponent
367
367
 
@@ -393,7 +393,7 @@ Storybook
393
393
 
394
394
  Storybook
395
395
 
396
-  
396
+
397
397
 
398
398
  ---
399
399
 
@@ -403,12 +403,12 @@ Tables are used to store and visually organize data and other content into a ser
403
403
 
404
404
  ## Table Components
405
405
 
406
- | Tables are built by combining Header Cells with Basic or Component Cells, providing flexibility for teams to create Tables that house any type of content their product's require. Tables can be sorted, either ascending or descending, by clicking on any Header Cell that has sorting enabled. To avoid slow loading speeds in Tables that contain large amounts of data, they should be split across multiple pages; incorporate a Pagination component to help users navigate between the pages of multi-page Tables. Filters are often used in conjunction with Tables, allowing users to manipulate what content is viewable in the Table by the parameters indicated in the Filter. | | **Jump to element:** Table Anatomy Basic Cell Component Cell Header Cell Table Row Table Header Pagination |
407
- | --- | --- | --- |
406
+ | Tables are built by combining Header Cells with Basic or Component Cells, providing flexibility for teams to create Tables that house any type of content their product's require. Tables can be sorted, either ascending or descending, by clicking on any Header Cell that has sorting enabled. To avoid slow loading speeds in Tables that contain large amounts of data, they should be split across multiple pages; incorporate a Pagination component to help users navigate between the pages of multi-page Tables. Filters are often used in conjunction with Tables, allowing users to manipulate what content is viewable in the Table by the parameters indicated in the Filter. | | **Jump to element:** Table Anatomy Basic Cell Component Cell Header Cell Table Row Table Header Pagination |
407
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --- | ---------------------------------------------------------------------------------------------------------- |
408
408
 
409
409
  ### Visual Preview
410
410
 
411
- >**Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
411
+ > **Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
412
412
 
413
413
  ---
414
414
 
@@ -418,8 +418,8 @@ Tables are used to store and visually organize data and other content into a ser
418
418
 
419
419
  ## Basic Cell
420
420
 
421
- | | In Figma | | | Meets Accessibility | | | In Code |
422
- | --- | --- | --- | --- | --- | --- | --- | --- |
421
+ | | In Figma | | | Meets Accessibility | | | In Code |
422
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------- |
423
423
 
424
424
  ### Live Instance
425
425
 
@@ -433,13 +433,13 @@ Default
433
433
 
434
434
  The Basic Cell is intended to be filled with strings of text or numerical values. A range of elements can be included alongside text, such as Icon Buttons or Tags, to provide additional actions users can take in relation to the content within the cell.
435
435
 
436
- >**Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
436
+ > **Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
437
437
 
438
438
  | Default | Default + Secondary text | Default + Secondary text + Tertiary text | Default (right aligned) |
439
- | --- | --- | --- | --- |
439
+ | ------- | ------------------------ | ---------------------------------------- | ----------------------- |
440
440
 
441
441
  | Default (wrapped) | Hover (truncated) + Tooltip | Basic Cell + Icon | Basic Cell + Tag |
442
- | --- | --- | --- | --- |
442
+ | ----------------- | --------------------------- | ----------------- | ---------------- |
443
443
 
444
444
  ---
445
445
 
@@ -451,8 +451,8 @@ These rules establish how much margin should exist between and around elements.
451
451
 
452
452
  ## Component Cell
453
453
 
454
- | | In Figma | | | Meets Accessibility | | | In Code |
455
- | --- | --- | --- | --- | --- | --- | --- | --- |
454
+ | | In Figma | | | Meets Accessibility | | | In Code |
455
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------- |
456
456
 
457
457
  ### Live Instance
458
458
 
@@ -466,10 +466,10 @@ Default
466
466
 
467
467
  Component Cells can accept any type of element, including any combination or number of components, but should not be used to display text strings (use a Basic Cell for this). Most commonly it is used to hold Buttons, Toggles, and Checkbox Inputs.
468
468
 
469
- >**Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
469
+ > **Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
470
470
 
471
471
  | Default | Filled (left aligned) | Filled (center aligned) | Filled (right aligned) | Filled (fit contents) |
472
- | --- | --- | --- | --- | --- |
472
+ | ------- | --------------------- | ----------------------- | ---------------------- | --------------------- |
473
473
 
474
474
  ---
475
475
 
@@ -481,8 +481,8 @@ These rules establish how much margin should exist between and around elements.
481
481
 
482
482
  ## Header Cell
483
483
 
484
- | | In Figma | | | Meets Accessibility | | | In Code |
485
- | --- | --- | --- | --- | --- | --- | --- | --- |
484
+ | | In Figma | | | Meets Accessibility | | | In Code |
485
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------- |
486
486
 
487
487
  ### Live Instance
488
488
 
@@ -500,10 +500,10 @@ Users are able to manually sort columns in ascending or descending order by clic
500
500
 
501
501
  Each Header Cell can have an optional Tooltip appear when hovered over. This can be used to display supplemental information or help further define the contents of the column below it.
502
502
 
503
- >**Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
503
+ > **Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
504
504
 
505
505
  | Default | Default (center aligned) | Default (right aligned) | Hover + Tooltip | Active (ascending) | Active (descending) |
506
- | --- | --- | --- | --- | --- | --- |
506
+ | ------- | ------------------------ | ----------------------- | --------------- | ------------------ | ------------------- |
507
507
 
508
508
  ---
509
509
 
@@ -515,8 +515,8 @@ These rules establish how much margin should exist between and around elements.
515
515
 
516
516
  ## Table Row
517
517
 
518
- | | In Figma | | | Meets Accessibility | | | In Code |
519
- | --- | --- | --- | --- | --- | --- | --- | --- |
518
+ | | In Figma | | | Meets Accessibility | | | In Code |
519
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------- |
520
520
 
521
521
  ### Live Instance
522
522
 
@@ -535,7 +535,7 @@ The Table Row also has its own set of props that control how the row as a whole
535
535
  Additionally, Checkbox Inputs can be placed within a Component Cell in the first column of a row, giving users the ability to select entire rows and complete bulk actions on them, such as downloading, editing, etc. See the Table Row Actions section below for more details.
536
536
 
537
537
  | Default | Default (no divider) | Hover + Tooltip | Selected | Disabled |
538
- | --- | --- | --- | --- | --- |
538
+ | ------- | -------------------- | --------------- | -------- | -------- |
539
539
 
540
540
  ---
541
541
 
@@ -561,14 +561,14 @@ Because actions taken at the row level will impact stored data in the applicatio
561
561
 
562
562
  ### Table Row Spacing
563
563
 
564
- These rules establish how much margin should exist between and around elements. Stack Table Rows below a Table Header to create a full Table.
564
+ These rules establish how much margin should exist between and around elements. Stack Table Rows below a Table Header to create a full Table.
565
565
 
566
566
  ---
567
567
 
568
568
  ## Table Header
569
569
 
570
- | | In Figma | | | Meets Accessibility | | | In Code |
571
- | --- | --- | --- | --- | --- | --- | --- | --- |
570
+ | | In Figma | | | Meets Accessibility | | | In Code |
571
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------- |
572
572
 
573
573
  ### Live Instance
574
574
 
@@ -586,14 +586,14 @@ A Table Header is a container filled with multiple Header Cells placed side-by-s
586
586
 
587
587
  ### Table Header Spacing
588
588
 
589
- These rules establish how much margin should exist between and around elements. Stack Table Rows below a Table Header to create a full Table.
589
+ These rules establish how much margin should exist between and around elements. Stack Table Rows below a Table Header to create a full Table.
590
590
 
591
591
  ---
592
592
 
593
593
  ## Pagination
594
594
 
595
- | | In Figma | | | Meets Accessibility | | | In Code |
596
- | --- | --- | --- | --- | --- | --- | --- | --- |
595
+ | | In Figma | | | Meets Accessibility | | | In Code |
596
+ | --- | -------- | --- | --- | ------------------- | --- | --- | ------- |
597
597
 
598
598
  ### Live Instance
599
599
 
@@ -610,7 +610,7 @@ Large Tables may have long loading times. To mitigate this, Tables can be split
610
610
  Users are able to click on any page number to jump immediately to that page; otherwise they can use the forward and back Icon Buttons to navigate page-by-page. For Tables that are longer than seven pages, ellipses are displayed to represent any additional pages not viewable. When enabled, the ellipses between page numbers can be clicked on, allowing users to select a page to jump to via a Dropdown Menu. When disabled, the ellipses will still be visible but not interactive.
611
611
 
612
612
  | Default | Default (square) | Hover | Default (ellipsis disabled) | Default (ellipsis enabled) |
613
- | --- | --- | --- | --- | --- |
613
+ | ------- | ---------------- | ----- | --------------------------- | -------------------------- |
614
614
 
615
615
  ---
616
616
 
@@ -622,14 +622,14 @@ These rules establish how much margin should exist between and around elements.
622
622
 
623
623
  ## Table Components
624
624
 
625
- | `Tables` are built by combining `CellHeader` with `CellBasic` or `CellComponent`, providing flexibility for teams to create `Tables` that house any type of content their product's require. `Tables` can be sorted, either ascending or descending, by clicking on any `CellHeader` that has sorting enabled. To avoid slow loading speeds in `Tables` that contain large amounts of data, they should be split across multiple pages; incorporate `Pagination` to help users navigate between the pages of multi-page Tables. `Filters` are often used in conjunction with Tables, allowing users to manipulate what content is viewable in the `Table` by the parameters indicated in the `Filter`. | | **Jump to component:** CellBasic CellComponent CellHeader TableRow Pagination |
626
- | --- | --- | --- |
625
+ | `Tables` are built by combining `CellHeader` with `CellBasic` or `CellComponent`, providing flexibility for teams to create `Tables` that house any type of content their product's require. `Tables` can be sorted, either ascending or descending, by clicking on any `CellHeader` that has sorting enabled. To avoid slow loading speeds in `Tables` that contain large amounts of data, they should be split across multiple pages; incorporate `Pagination` to help users navigate between the pages of multi-page Tables. `Filters` are often used in conjunction with Tables, allowing users to manipulate what content is viewable in the `Table` by the parameters indicated in the `Filter`. | | **Jump to component:** CellBasic CellComponent CellHeader TableRow Pagination |
626
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | --- | ----------------------------------------------------------------------------- |
627
627
 
628
628
  ### Visual Preview
629
629
 
630
- >**Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
630
+ > **Note:** Dotted lines around the cells below are only for demonstration purposes to show the cells' containers; in application, individual cells have no borders.
631
631
 
632
- >**Note:** The code examples below must install dependencies before displaying and may take extra time to load
632
+ > **Note:** The code examples below must install dependencies before displaying and may take extra time to load
633
633
 
634
634
  ---
635
635
 
@@ -643,23 +643,23 @@ The component's source code in the SDS codebase can be found here.
643
643
 
644
644
  Any custom SDS props and MUI props required for implementation are found on the table below. See the MUI documentation for additional optional props.
645
645
 
646
- | Name | Type | Default | Description |
647
- | --- | --- | --- | --- |
648
- | `horizontalAlign` | `"left"` `| "center"` `| "right"` | `"left"` | Horizontal alignment of cell content. |
649
- | `icon` | `Node` | `-` | Places an icon at the left side of the cell component. |
650
- | `iconVerticalAlign` | `"top"` `| "center"` `| "bottom"` | `"top"` | Vertical alignment of the icon component. |
651
- | `primaryText` | `string` | `-` | Primary text value. |
652
- | `primaryTextWrapLineCount` | `number` | `3` | Number of text wrap lines for primary text. |
653
- | `primaryTextComponentSlotBottom` | `ReactNode` | `null` | Component slot below primary text. This will only show if there is no secondary or tertiary text. Remove the default values of secondary and tertiary text to see this in action. |
654
- | `primaryTextComponentSlotRight` | `ReactNode` | `null` | Component slot to the right of primary text |
655
- | `secondaryText` | `string` | `-` | Secondary Text. |
656
- | `secondaryTextWrapLineCount` | `number` | `1` | Number of text wrap lines for secondary text. |
657
- | `tertiaryText` | `string` | `-` | Tertiary Text. |
658
- | `tertiaryTextWrapLineCount` | `number` | `1` | Number of text wrap lines for tertiary text. |
659
- | `shouldShowTooltipOnHover` | `boolean` | `true` | When set to `true`, a tooltip will be shown on cell hover. |
660
- | `shouldTextWrap` | `boolean` | `true` | When set to `true`, wraps the content texts by the number of defined wrap line numbers. |
661
- | `tooltipProps` | `Partial<TooltipProps>` | `{}` | These props will be directly passed to the `Tooltip` component. |
662
- | `verticalAlign` | `"top"` `| "center"` `| "bottom"` | `"top"` | Vertical alignment of the cell content. |
646
+ | Name | Type | Default | Description |
647
+ | -------------------------------- | ----------------------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- | ----------------------------------------- |
648
+ | `horizontalAlign` | `"left"` ` | "center"` ` | "right"` | `"left"` | Horizontal alignment of cell content. |
649
+ | `icon` | `Node` | `-` | Places an icon at the left side of the cell component. |
650
+ | `iconVerticalAlign` | `"top"` ` | "center"` ` | "bottom"` | `"top"` | Vertical alignment of the icon component. |
651
+ | `primaryText` | `string` | `-` | Primary text value. |
652
+ | `primaryTextWrapLineCount` | `number` | `3` | Number of text wrap lines for primary text. |
653
+ | `primaryTextComponentSlotBottom` | `ReactNode` | `null` | Component slot below primary text. This will only show if there is no secondary or tertiary text. Remove the default values of secondary and tertiary text to see this in action. |
654
+ | `primaryTextComponentSlotRight` | `ReactNode` | `null` | Component slot to the right of primary text |
655
+ | `secondaryText` | `string` | `-` | Secondary Text. |
656
+ | `secondaryTextWrapLineCount` | `number` | `1` | Number of text wrap lines for secondary text. |
657
+ | `tertiaryText` | `string` | `-` | Tertiary Text. |
658
+ | `tertiaryTextWrapLineCount` | `number` | `1` | Number of text wrap lines for tertiary text. |
659
+ | `shouldShowTooltipOnHover` | `boolean` | `true` | When set to `true`, a tooltip will be shown on cell hover. |
660
+ | `shouldTextWrap` | `boolean` | `true` | When set to `true`, wraps the content texts by the number of defined wrap line numbers. |
661
+ | `tooltipProps` | `Partial<TooltipProps>` | `{}` | These props will be directly passed to the `Tooltip` component. |
662
+ | `verticalAlign` | `"top"` ` | "center"` ` | "bottom"` | `"top"` | Vertical alignment of the cell content. |
663
663
 
664
664
  ### Code examples
665
665
 
@@ -696,13 +696,11 @@ table {
696
696
 
697
697
  ```json
698
698
  {
699
- "include": [
700
- "./**/*"
701
- ],
699
+ "include": ["./**/*"],
702
700
  "compilerOptions": {
703
701
  "strict": true,
704
702
  "esModuleInterop": true,
705
- "lib": [ "dom", "es2015" ],
703
+ "lib": ["dom", "es2015"],
706
704
  "jsx": "react-jsx"
707
705
  }
708
706
  }
@@ -771,13 +769,12 @@ root.render(
771
769
  <RootApp />
772
770
  </React.StrictMode>
773
771
  );
774
-
775
772
  ```
776
773
 
777
774
  **/public/index.html**
778
775
 
779
776
  ```html
780
- <!DOCTYPE html>
777
+ <!doctype html>
781
778
  <html lang="en">
782
779
  <head>
783
780
  <meta charset="UTF-8" />
@@ -798,13 +795,24 @@ root.render(
798
795
  <div id="root"></div>
799
796
  </body>
800
797
  </html>
801
-
802
798
  ```
803
799
 
804
800
  **/package.json**
805
801
 
806
802
  ```json
807
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
803
+ {
804
+ "dependencies": {
805
+ "react": "^18.0.0",
806
+ "react-dom": "^18.0.0",
807
+ "react-scripts": "^4.0.0"
808
+ },
809
+ "devDependencies": {
810
+ "@types/react": "^18.0.0",
811
+ "@types/react-dom": "^18.0.0",
812
+ "typescript": "^4.0.0"
813
+ },
814
+ "main": "/index.tsx"
815
+ }
808
816
  ```
809
817
 
810
818
  ---
@@ -838,13 +846,11 @@ h1 {
838
846
 
839
847
  ```json
840
848
  {
841
- "include": [
842
- "./**/*"
843
- ],
849
+ "include": ["./**/*"],
844
850
  "compilerOptions": {
845
851
  "strict": true,
846
852
  "esModuleInterop": true,
847
- "lib": [ "dom", "es2015" ],
853
+ "lib": ["dom", "es2015"],
848
854
  "jsx": "react-jsx"
849
855
  }
850
856
  }
@@ -862,7 +868,7 @@ function App() {
862
868
  maxWidth: 160,
863
869
  width: 160,
864
870
  };
865
-
871
+
866
872
  return (
867
873
  <div className="app">
868
874
  <table>
@@ -872,11 +878,18 @@ function App() {
872
878
  primaryText="Primary Text that is longer than expected."
873
879
  secondaryText="Secondary Text that is londer than expected."
874
880
  tertiaryText="Tertiary Text that is lonegrt than expected."
875
- icon={<Icon sdsIcon="Bacteria" sdsSize="l" sdsType="static" color="notice" />}
881
+ icon={
882
+ <Icon
883
+ sdsIcon="Bacteria"
884
+ sdsSize="l"
885
+ sdsType="static"
886
+ color="notice"
887
+ />
888
+ }
876
889
  style={TableCellStyle}
877
890
  tooltipProps={{
878
891
  placement: "right",
879
- sdsStyle: "light"
892
+ sdsStyle: "light",
880
893
  }}
881
894
  />
882
895
  </tr>
@@ -926,13 +939,12 @@ root.render(
926
939
  <RootApp />
927
940
  </React.StrictMode>
928
941
  );
929
-
930
942
  ```
931
943
 
932
944
  **/public/index.html**
933
945
 
934
946
  ```html
935
- <!DOCTYPE html>
947
+ <!doctype html>
936
948
  <html lang="en">
937
949
  <head>
938
950
  <meta charset="UTF-8" />
@@ -953,13 +965,24 @@ root.render(
953
965
  <div id="root"></div>
954
966
  </body>
955
967
  </html>
956
-
957
968
  ```
958
969
 
959
970
  **/package.json**
960
971
 
961
972
  ```json
962
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
973
+ {
974
+ "dependencies": {
975
+ "react": "^18.0.0",
976
+ "react-dom": "^18.0.0",
977
+ "react-scripts": "^4.0.0"
978
+ },
979
+ "devDependencies": {
980
+ "@types/react": "^18.0.0",
981
+ "@types/react-dom": "^18.0.0",
982
+ "typescript": "^4.0.0"
983
+ },
984
+ "main": "/index.tsx"
985
+ }
963
986
  ```
964
987
 
965
988
  ---
@@ -976,10 +999,10 @@ The component's source code in the SDS codebase can be found here.
976
999
 
977
1000
  Any custom SDS props and MUI props required for implementation are found on the table below. See the MUI documentation for additional optional props.
978
1001
 
979
- | Name | Type | Default | Description |
980
- | --- | --- | --- | --- |
981
- | `horizontalAlign` | `"left"` `| "center"` `| "right"` | `"left"` | Specifies the horizontal alignment of the cell content. |
982
- | `verticalAlign` | `"top"` `| "center"` `| "bottom"` | `"top"` | Specifies the vertical alignment of the cell content. |
1002
+ | Name | Type | Default | Description |
1003
+ | ----------------- | ---------- | ----------- | ----------- | -------- | ------------------------------------------------------- |
1004
+ | `horizontalAlign` | `"left"` ` | "center"` ` | "right"` | `"left"` | Specifies the horizontal alignment of the cell content. |
1005
+ | `verticalAlign` | `"top"` ` | "center"` ` | "bottom"` | `"top"` | Specifies the vertical alignment of the cell content. |
983
1006
 
984
1007
  ### Code examples
985
1008
 
@@ -1016,13 +1039,11 @@ table {
1016
1039
 
1017
1040
  ```json
1018
1041
  {
1019
- "include": [
1020
- "./**/*"
1021
- ],
1042
+ "include": ["./**/*"],
1022
1043
  "compilerOptions": {
1023
1044
  "strict": true,
1024
1045
  "esModuleInterop": true,
1025
- "lib": [ "dom", "es2015" ],
1046
+ "lib": ["dom", "es2015"],
1026
1047
  "jsx": "react-jsx"
1027
1048
  }
1028
1049
  }
@@ -1090,13 +1111,12 @@ root.render(
1090
1111
  <RootApp />
1091
1112
  </React.StrictMode>
1092
1113
  );
1093
-
1094
1114
  ```
1095
1115
 
1096
1116
  **/public/index.html**
1097
1117
 
1098
1118
  ```html
1099
- <!DOCTYPE html>
1119
+ <!doctype html>
1100
1120
  <html lang="en">
1101
1121
  <head>
1102
1122
  <meta charset="UTF-8" />
@@ -1117,13 +1137,24 @@ root.render(
1117
1137
  <div id="root"></div>
1118
1138
  </body>
1119
1139
  </html>
1120
-
1121
1140
  ```
1122
1141
 
1123
1142
  **/package.json**
1124
1143
 
1125
1144
  ```json
1126
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
1145
+ {
1146
+ "dependencies": {
1147
+ "react": "^18.0.0",
1148
+ "react-dom": "^18.0.0",
1149
+ "react-scripts": "^4.0.0"
1150
+ },
1151
+ "devDependencies": {
1152
+ "@types/react": "^18.0.0",
1153
+ "@types/react-dom": "^18.0.0",
1154
+ "typescript": "^4.0.0"
1155
+ },
1156
+ "main": "/index.tsx"
1157
+ }
1127
1158
  ```
1128
1159
 
1129
1160
  ---
@@ -1140,16 +1171,16 @@ The component's source code in the SDS codebase can be found here.
1140
1171
 
1141
1172
  Any custom SDS props and MUI props required for implementation are found on the table below. See the MUI documentation for additional optional props.
1142
1173
 
1143
- | Name | Type | Default | Description |
1144
- | --- | --- | --- | --- |
1145
- | `active` | `boolean` | `false` | When `true`, the component is in active state. |
1146
- | `hover` | `boolean` | `false` | By default, the component is not interactive and does not have a hover state. When set to `true`, it displays a `sortIcon` and changes color on hover. |
1147
- | `direction` | `"asc" | "desc"` | `"desc"` | Changes the chevron icon based on the sort direction. |
1148
- | `hideSortIcon` | `boolean` | `false` | If set to `true`, the sort icon becomes hidden. |
1149
- | `horizontalAlign` | `"left"` `| "center"` `| "right"` | `"left"` | Horizontally aligns the component's content. |
1150
- | `shouldShowTooltipOnHover` | `boolean` | `true` | When `true`, show a tooltip on component hover. |
1151
- | `tooltipText` | `string` | `-` | The content of the tooltip. |
1152
- | `tooltipProps` | `Partial<TooltipProps>` | `{}` | These props are directly passed to the tooltip component. |
1174
+ | Name | Type | Default | Description |
1175
+ | -------------------------- | ----------------------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------------------------------------------------- | -------------------------------------------- |
1176
+ | `active` | `boolean` | `false` | When `true`, the component is in active state. |
1177
+ | `hover` | `boolean` | `false` | By default, the component is not interactive and does not have a hover state. When set to `true`, it displays a `sortIcon` and changes color on hover. |
1178
+ | `direction` | `"asc" | "desc"` | `"desc"` | Changes the chevron icon based on the sort direction. |
1179
+ | `hideSortIcon` | `boolean` | `false` | If set to `true`, the sort icon becomes hidden. |
1180
+ | `horizontalAlign` | `"left"` ` | "center"` ` | "right"` | `"left"` | Horizontally aligns the component's content. |
1181
+ | `shouldShowTooltipOnHover` | `boolean` | `true` | When `true`, show a tooltip on component hover. |
1182
+ | `tooltipText` | `string` | `-` | The content of the tooltip. |
1183
+ | `tooltipProps` | `Partial<TooltipProps>` | `{}` | These props are directly passed to the tooltip component. |
1153
1184
 
1154
1185
  ### Code examples
1155
1186
 
@@ -1186,13 +1217,11 @@ table {
1186
1217
 
1187
1218
  ```json
1188
1219
  {
1189
- "include": [
1190
- "./**/*"
1191
- ],
1220
+ "include": ["./**/*"],
1192
1221
  "compilerOptions": {
1193
1222
  "strict": true,
1194
1223
  "esModuleInterop": true,
1195
- "lib": [ "dom", "es2015" ],
1224
+ "lib": ["dom", "es2015"],
1196
1225
  "jsx": "react-jsx"
1197
1226
  }
1198
1227
  }
@@ -1210,9 +1239,7 @@ function App() {
1210
1239
  <table>
1211
1240
  <thead>
1212
1241
  <tr>
1213
- <CellHeader>
1214
- Header
1215
- </CellHeader>
1242
+ <CellHeader>Header</CellHeader>
1216
1243
  </tr>
1217
1244
  </thead>
1218
1245
  </table>
@@ -1260,13 +1287,12 @@ root.render(
1260
1287
  <RootApp />
1261
1288
  </React.StrictMode>
1262
1289
  );
1263
-
1264
1290
  ```
1265
1291
 
1266
1292
  **/public/index.html**
1267
1293
 
1268
1294
  ```html
1269
- <!DOCTYPE html>
1295
+ <!doctype html>
1270
1296
  <html lang="en">
1271
1297
  <head>
1272
1298
  <meta charset="UTF-8" />
@@ -1287,13 +1313,24 @@ root.render(
1287
1313
  <div id="root"></div>
1288
1314
  </body>
1289
1315
  </html>
1290
-
1291
1316
  ```
1292
1317
 
1293
1318
  **/package.json**
1294
1319
 
1295
1320
  ```json
1296
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
1321
+ {
1322
+ "dependencies": {
1323
+ "react": "^18.0.0",
1324
+ "react-dom": "^18.0.0",
1325
+ "react-scripts": "^4.0.0"
1326
+ },
1327
+ "devDependencies": {
1328
+ "@types/react": "^18.0.0",
1329
+ "@types/react-dom": "^18.0.0",
1330
+ "typescript": "^4.0.0"
1331
+ },
1332
+ "main": "/index.tsx"
1333
+ }
1297
1334
  ```
1298
1335
 
1299
1336
  ---
@@ -1310,17 +1347,17 @@ The component's source code in the SDS codebase can be found here.
1310
1347
 
1311
1348
  Any custom SDS props and MUI props required for implementation are found on the table below. See the MUI documentation for additional optional props.
1312
1349
 
1313
- | Name | Type | Default | Description |
1314
- | --- | --- | --- | --- |
1315
- | `disabled` | `boolean` | `false` | When `true`, the row is disabled. |
1316
- | `hover` | `boolean` | `true` | When `true`, the component has a hover style. |
1317
- | `selected` | `boolean` | `false` | When `true`, component is in the selected state. |
1318
- | `rowHeight` | `number` | `-` | Sets a maximum height for the table row. |
1319
- | `shouldShowTooltipOnHover` | `boolean` | `true` | When `true`, a tooltip shows up on component hover. |
1320
- | `tooltipProps` | `Partial<TooltipProps>` | `{}` | These props are directly passed to the tooltip component. |
1321
- | `tooltipText` | `string` | `-` | Tooltip text. |
1322
- | `tooltipSubtitle` | `string` | `-` | Toltip subtitle. |
1323
- | `useDivider` | `boolean` | `true` | If set to `true`, shows a bottom border under the table row. |
1350
+ | Name | Type | Default | Description |
1351
+ | -------------------------- | ----------------------- | ------- | ------------------------------------------------------------ |
1352
+ | `disabled` | `boolean` | `false` | When `true`, the row is disabled. |
1353
+ | `hover` | `boolean` | `true` | When `true`, the component has a hover style. |
1354
+ | `selected` | `boolean` | `false` | When `true`, component is in the selected state. |
1355
+ | `rowHeight` | `number` | `-` | Sets a maximum height for the table row. |
1356
+ | `shouldShowTooltipOnHover` | `boolean` | `true` | When `true`, a tooltip shows up on component hover. |
1357
+ | `tooltipProps` | `Partial<TooltipProps>` | `{}` | These props are directly passed to the tooltip component. |
1358
+ | `tooltipText` | `string` | `-` | Tooltip text. |
1359
+ | `tooltipSubtitle` | `string` | `-` | Toltip subtitle. |
1360
+ | `useDivider` | `boolean` | `true` | If set to `true`, shows a bottom border under the table row. |
1324
1361
 
1325
1362
  ### Code examples
1326
1363
 
@@ -1353,13 +1390,11 @@ h1 {
1353
1390
 
1354
1391
  ```json
1355
1392
  {
1356
- "include": [
1357
- "./**/*"
1358
- ],
1393
+ "include": ["./**/*"],
1359
1394
  "compilerOptions": {
1360
1395
  "strict": true,
1361
1396
  "esModuleInterop": true,
1362
- "lib": [ "dom", "es2015" ],
1397
+ "lib": ["dom", "es2015"],
1363
1398
  "jsx": "react-jsx"
1364
1399
  }
1365
1400
  }
@@ -1439,13 +1474,12 @@ root.render(
1439
1474
  <RootApp />
1440
1475
  </React.StrictMode>
1441
1476
  );
1442
-
1443
1477
  ```
1444
1478
 
1445
1479
  **/public/index.html**
1446
1480
 
1447
1481
  ```html
1448
- <!DOCTYPE html>
1482
+ <!doctype html>
1449
1483
  <html lang="en">
1450
1484
  <head>
1451
1485
  <meta charset="UTF-8" />
@@ -1466,13 +1500,24 @@ root.render(
1466
1500
  <div id="root"></div>
1467
1501
  </body>
1468
1502
  </html>
1469
-
1470
1503
  ```
1471
1504
 
1472
1505
  **/package.json**
1473
1506
 
1474
1507
  ```json
1475
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
1508
+ {
1509
+ "dependencies": {
1510
+ "react": "^18.0.0",
1511
+ "react-dom": "^18.0.0",
1512
+ "react-scripts": "^4.0.0"
1513
+ },
1514
+ "devDependencies": {
1515
+ "@types/react": "^18.0.0",
1516
+ "@types/react-dom": "^18.0.0",
1517
+ "typescript": "^4.0.0"
1518
+ },
1519
+ "main": "/index.tsx"
1520
+ }
1476
1521
  ```
1477
1522
 
1478
1523
  ---
@@ -1516,13 +1561,11 @@ h1 {
1516
1561
 
1517
1562
  ```json
1518
1563
  {
1519
- "include": [
1520
- "./**/*"
1521
- ],
1564
+ "include": ["./**/*"],
1522
1565
  "compilerOptions": {
1523
1566
  "strict": true,
1524
1567
  "esModuleInterop": true,
1525
- "lib": [ "dom", "es2015" ],
1568
+ "lib": ["dom", "es2015"],
1526
1569
  "jsx": "react-jsx"
1527
1570
  }
1528
1571
  }
@@ -1540,15 +1583,9 @@ function App() {
1540
1583
  <table>
1541
1584
  <thead>
1542
1585
  <tr>
1543
- <CellHeader>
1544
- Header
1545
- </CellHeader>
1546
- <CellHeader>
1547
- Header
1548
- </CellHeader>
1549
- <CellHeader>
1550
- Header
1551
- </CellHeader>
1586
+ <CellHeader>Header</CellHeader>
1587
+ <CellHeader>Header</CellHeader>
1588
+ <CellHeader>Header</CellHeader>
1552
1589
  </tr>
1553
1590
  </thead>
1554
1591
  </table>
@@ -1596,13 +1633,12 @@ root.render(
1596
1633
  <RootApp />
1597
1634
  </React.StrictMode>
1598
1635
  );
1599
-
1600
1636
  ```
1601
1637
 
1602
1638
  **/public/index.html**
1603
1639
 
1604
1640
  ```html
1605
- <!DOCTYPE html>
1641
+ <!doctype html>
1606
1642
  <html lang="en">
1607
1643
  <head>
1608
1644
  <meta charset="UTF-8" />
@@ -1623,13 +1659,24 @@ root.render(
1623
1659
  <div id="root"></div>
1624
1660
  </body>
1625
1661
  </html>
1626
-
1627
1662
  ```
1628
1663
 
1629
1664
  **/package.json**
1630
1665
 
1631
1666
  ```json
1632
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
1667
+ {
1668
+ "dependencies": {
1669
+ "react": "^18.0.0",
1670
+ "react-dom": "^18.0.0",
1671
+ "react-scripts": "^4.0.0"
1672
+ },
1673
+ "devDependencies": {
1674
+ "@types/react": "^18.0.0",
1675
+ "@types/react-dom": "^18.0.0",
1676
+ "typescript": "^4.0.0"
1677
+ },
1678
+ "main": "/index.tsx"
1679
+ }
1633
1680
  ```
1634
1681
 
1635
1682
  ---
@@ -1646,16 +1693,16 @@ The component's source code in the SDS codebase can be found here.
1646
1693
 
1647
1694
  Any custom SDS props and MUI props required for implementation are found on the table below. See the MUI documentation for additional optional props.
1648
1695
 
1649
- | Name | Type | Default | Description |
1650
- | --- | --- | --- | --- |
1651
- | `onPageChange` | `(page: number) => void;` | `-` | A callback function triggered when the page number is changed. |
1652
- | `onNextPage` | `() => void;` | `-` | A callback function triggered when the "Next" page button is clicked. |
1653
- | `onPreviousPage` | `() => void;` | `-` | A callback function triggered when the "Previous" page button is clicked. |
1654
- | `pageSize` | `number` | `-` | Specifies the number of items to be shown on each page. |
1655
- | `siblingCount` | `number` | `1` | Specifies the number of siblings for each page number. |
1656
- | `sdsStyle` | `"rounded"` `| "square"` | `"rounded"` | The style of the component. |
1657
- | `totalCount` | `number` | `-` | Total number of items to be paginated. |
1658
- | `truncateDropdown` | `boolean` | `true` | If `true`, a dropdown menu is shown for hidden page numbers. |
1696
+ | Name | Type | Default | Description |
1697
+ | ------------------ | ------------------------- | --------- | ------------------------------------------------------------------------- | --------------------------- |
1698
+ | `onPageChange` | `(page: number) => void;` | `-` | A callback function triggered when the page number is changed. |
1699
+ | `onNextPage` | `() => void;` | `-` | A callback function triggered when the "Next" page button is clicked. |
1700
+ | `onPreviousPage` | `() => void;` | `-` | A callback function triggered when the "Previous" page button is clicked. |
1701
+ | `pageSize` | `number` | `-` | Specifies the number of items to be shown on each page. |
1702
+ | `siblingCount` | `number` | `1` | Specifies the number of siblings for each page number. |
1703
+ | `sdsStyle` | `"rounded"` ` | "square"` | `"rounded"` | The style of the component. |
1704
+ | `totalCount` | `number` | `-` | Total number of items to be paginated. |
1705
+ | `truncateDropdown` | `boolean` | `true` | If `true`, a dropdown menu is shown for hidden page numbers. |
1659
1706
 
1660
1707
  ### Code examples
1661
1708
 
@@ -1688,13 +1735,11 @@ h1 {
1688
1735
 
1689
1736
  ```json
1690
1737
  {
1691
- "include": [
1692
- "./**/*"
1693
- ],
1738
+ "include": ["./**/*"],
1694
1739
  "compilerOptions": {
1695
1740
  "strict": true,
1696
1741
  "esModuleInterop": true,
1697
- "lib": [ "dom", "es2015" ],
1742
+ "lib": ["dom", "es2015"],
1698
1743
  "jsx": "react-jsx"
1699
1744
  }
1700
1745
  }
@@ -1708,9 +1753,8 @@ import { useState } from "react";
1708
1753
  import "./styles.css";
1709
1754
 
1710
1755
  function App() {
1711
-
1712
1756
  const [currentPage, setCurrentPage] = useState(1);
1713
-
1757
+
1714
1758
  return (
1715
1759
  <div className="app">
1716
1760
  <Pagination
@@ -1769,13 +1813,12 @@ root.render(
1769
1813
  <RootApp />
1770
1814
  </React.StrictMode>
1771
1815
  );
1772
-
1773
1816
  ```
1774
1817
 
1775
1818
  **/public/index.html**
1776
1819
 
1777
1820
  ```html
1778
- <!DOCTYPE html>
1821
+ <!doctype html>
1779
1822
  <html lang="en">
1780
1823
  <head>
1781
1824
  <meta charset="UTF-8" />
@@ -1796,13 +1839,24 @@ root.render(
1796
1839
  <div id="root"></div>
1797
1840
  </body>
1798
1841
  </html>
1799
-
1800
1842
  ```
1801
1843
 
1802
1844
  **/package.json**
1803
1845
 
1804
1846
  ```json
1805
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
1847
+ {
1848
+ "dependencies": {
1849
+ "react": "^18.0.0",
1850
+ "react-dom": "^18.0.0",
1851
+ "react-scripts": "^4.0.0"
1852
+ },
1853
+ "devDependencies": {
1854
+ "@types/react": "^18.0.0",
1855
+ "@types/react-dom": "^18.0.0",
1856
+ "typescript": "^4.0.0"
1857
+ },
1858
+ "main": "/index.tsx"
1859
+ }
1806
1860
  ```
1807
1861
 
1808
1862
  ---
@@ -1846,13 +1900,11 @@ h1 {
1846
1900
 
1847
1901
  ```json
1848
1902
  {
1849
- "include": [
1850
- "./**/*"
1851
- ],
1903
+ "include": ["./**/*"],
1852
1904
  "compilerOptions": {
1853
1905
  "strict": true,
1854
1906
  "esModuleInterop": true,
1855
- "lib": [ "dom", "es2015" ],
1907
+ "lib": ["dom", "es2015"],
1856
1908
  "jsx": "react-jsx"
1857
1909
  }
1858
1910
  }
@@ -1861,22 +1913,21 @@ h1 {
1861
1913
  **/App.tsx**
1862
1914
 
1863
1915
  ```tsx
1864
- import {
1865
- CellBasic,
1866
- CellComponent,
1916
+ import {
1917
+ CellBasic,
1918
+ CellComponent,
1867
1919
  CellHeader,
1868
- Icon,
1869
- InputRadio,
1870
- Tag,
1871
- Table,
1872
- TableRow,
1873
- TableHeader
1920
+ Icon,
1921
+ InputRadio,
1922
+ Tag,
1923
+ Table,
1924
+ TableRow,
1925
+ TableHeader,
1874
1926
  } from "@czi-sds/components";
1875
1927
  import { styled, RadioGroup, FormControlLabel } from "@mui/material";
1876
1928
  import "./styles.css";
1877
1929
 
1878
1930
  function App() {
1879
-
1880
1931
  const StyledIconCell = styled("div")`
1881
1932
  align-items: center;
1882
1933
  display: flex;
@@ -1926,15 +1977,17 @@ function App() {
1926
1977
  shouldShowTooltipOnHover={false}
1927
1978
  />
1928
1979
  <CellComponent>
1929
- {["info", "notice", "beta", "negative", "positive"].map((item) => (
1930
- <Tag
1931
- key={item}
1932
- color={item as SdsTagColorType}
1933
- label={item as string}
1934
- sdsStyle="rounded"
1935
- sdsType="secondary"
1936
- />
1937
- ))}
1980
+ {["info", "notice", "beta", "negative", "positive"].map(
1981
+ (item) => (
1982
+ <Tag
1983
+ key={item}
1984
+ color={item as SdsTagColorType}
1985
+ label={item as string}
1986
+ sdsStyle="rounded"
1987
+ sdsType="secondary"
1988
+ />
1989
+ )
1990
+ )}
1938
1991
  </CellComponent>
1939
1992
  <CellBasic
1940
1993
  primaryText="356"
@@ -2068,13 +2121,12 @@ root.render(
2068
2121
  <RootApp />
2069
2122
  </React.StrictMode>
2070
2123
  );
2071
-
2072
2124
  ```
2073
2125
 
2074
2126
  **/public/index.html**
2075
2127
 
2076
2128
  ```html
2077
- <!DOCTYPE html>
2129
+ <!doctype html>
2078
2130
  <html lang="en">
2079
2131
  <head>
2080
2132
  <meta charset="UTF-8" />
@@ -2095,13 +2147,24 @@ root.render(
2095
2147
  <div id="root"></div>
2096
2148
  </body>
2097
2149
  </html>
2098
-
2099
2150
  ```
2100
2151
 
2101
2152
  **/package.json**
2102
2153
 
2103
2154
  ```json
2104
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
2155
+ {
2156
+ "dependencies": {
2157
+ "react": "^18.0.0",
2158
+ "react-dom": "^18.0.0",
2159
+ "react-scripts": "^4.0.0"
2160
+ },
2161
+ "devDependencies": {
2162
+ "@types/react": "^18.0.0",
2163
+ "@types/react-dom": "^18.0.0",
2164
+ "typescript": "^4.0.0"
2165
+ },
2166
+ "main": "/index.tsx"
2167
+ }
2105
2168
  ```
2106
2169
 
2107
2170
  ---
@@ -2110,8 +2173,8 @@ root.render(
2110
2173
 
2111
2174
  ## Table Recipes
2112
2175
 
2113
- | These component recipes show a few of the more complex approaches available for customizing Tables. | | **Jump to recipe:** Text-only Table Table with a custom sorting function Table with custom Tooltips Table with virtualized rows Editable Table Cells with Access to Internal Data Table with Front-End Pagination Table with Back-End Pagination |
2114
- | --- | --- | --- |
2176
+ | These component recipes show a few of the more complex approaches available for customizing Tables. | | **Jump to recipe:** Text-only Table Table with a custom sorting function Table with custom Tooltips Table with virtualized rows Editable Table Cells with Access to Internal Data Table with Front-End Pagination Table with Back-End Pagination |
2177
+ | --------------------------------------------------------------------------------------------------- | --- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
2115
2178
 
2116
2179
  #### Text-only Table
2117
2180
 
@@ -2144,13 +2207,11 @@ h1 {
2144
2207
 
2145
2208
  ```json
2146
2209
  {
2147
- "include": [
2148
- "./**/*"
2149
- ],
2210
+ "include": ["./**/*"],
2150
2211
  "compilerOptions": {
2151
2212
  "strict": true,
2152
2213
  "esModuleInterop": true,
2153
- "lib": [ "dom", "es2015" ],
2214
+ "lib": ["dom", "es2015"],
2154
2215
  "jsx": "react-jsx"
2155
2216
  }
2156
2217
  }
@@ -2322,7 +2383,6 @@ function App() {
2322
2383
  }
2323
2384
 
2324
2385
  export default App;
2325
-
2326
2386
  ```
2327
2387
 
2328
2388
  **/index.tsx**
@@ -2362,13 +2422,12 @@ root.render(
2362
2422
  <RootApp />
2363
2423
  </React.StrictMode>
2364
2424
  );
2365
-
2366
2425
  ```
2367
2426
 
2368
2427
  **/public/index.html**
2369
2428
 
2370
2429
  ```html
2371
- <!DOCTYPE html>
2430
+ <!doctype html>
2372
2431
  <html lang="en">
2373
2432
  <head>
2374
2433
  <meta charset="UTF-8" />
@@ -2389,13 +2448,24 @@ root.render(
2389
2448
  <div id="root"></div>
2390
2449
  </body>
2391
2450
  </html>
2392
-
2393
2451
  ```
2394
2452
 
2395
2453
  **/package.json**
2396
2454
 
2397
2455
  ```json
2398
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
2456
+ {
2457
+ "dependencies": {
2458
+ "react": "^18.0.0",
2459
+ "react-dom": "^18.0.0",
2460
+ "react-scripts": "^4.0.0"
2461
+ },
2462
+ "devDependencies": {
2463
+ "@types/react": "^18.0.0",
2464
+ "@types/react-dom": "^18.0.0",
2465
+ "typescript": "^4.0.0"
2466
+ },
2467
+ "main": "/index.tsx"
2468
+ }
2399
2469
  ```
2400
2470
 
2401
2471
  ---
@@ -2443,20 +2513,17 @@ h1 {
2443
2513
  }
2444
2514
  }
2445
2515
  }
2446
-
2447
2516
  ```
2448
2517
 
2449
2518
  **tsconfig.json**
2450
2519
 
2451
2520
  ```json
2452
2521
  {
2453
- "include": [
2454
- "./**/*"
2455
- ],
2522
+ "include": ["./**/*"],
2456
2523
  "compilerOptions": {
2457
2524
  "strict": true,
2458
2525
  "esModuleInterop": true,
2459
- "lib": [ "dom", "es2015" ],
2526
+ "lib": ["dom", "es2015"],
2460
2527
  "jsx": "react-jsx"
2461
2528
  }
2462
2529
  }
@@ -2634,8 +2701,8 @@ function App() {
2634
2701
  cell.cell.getValue() === "single"
2635
2702
  ? "notice"
2636
2703
  : cell.cell.getValue() === "relationship"
2637
- ? "positive"
2638
- : "negative"
2704
+ ? "positive"
2705
+ : "negative"
2639
2706
  }
2640
2707
  sdsStyle="rounded"
2641
2708
  sdsType="secondary"
@@ -2775,7 +2842,6 @@ function App() {
2775
2842
  }
2776
2843
 
2777
2844
  export default App;
2778
-
2779
2845
  ```
2780
2846
 
2781
2847
  **/index.tsx**
@@ -2815,13 +2881,12 @@ root.render(
2815
2881
  <RootApp />
2816
2882
  </React.StrictMode>
2817
2883
  );
2818
-
2819
2884
  ```
2820
2885
 
2821
2886
  **/public/index.html**
2822
2887
 
2823
2888
  ```html
2824
- <!DOCTYPE html>
2889
+ <!doctype html>
2825
2890
  <html lang="en">
2826
2891
  <head>
2827
2892
  <meta charset="UTF-8" />
@@ -2842,13 +2907,24 @@ root.render(
2842
2907
  <div id="root"></div>
2843
2908
  </body>
2844
2909
  </html>
2845
-
2846
2910
  ```
2847
2911
 
2848
2912
  **/package.json**
2849
2913
 
2850
2914
  ```json
2851
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
2915
+ {
2916
+ "dependencies": {
2917
+ "react": "^18.0.0",
2918
+ "react-dom": "^18.0.0",
2919
+ "react-scripts": "^4.0.0"
2920
+ },
2921
+ "devDependencies": {
2922
+ "@types/react": "^18.0.0",
2923
+ "@types/react-dom": "^18.0.0",
2924
+ "typescript": "^4.0.0"
2925
+ },
2926
+ "main": "/index.tsx"
2927
+ }
2852
2928
  ```
2853
2929
 
2854
2930
  ---
@@ -2882,13 +2958,11 @@ h1 {
2882
2958
 
2883
2959
  ```json
2884
2960
  {
2885
- "include": [
2886
- "./**/*"
2887
- ],
2961
+ "include": ["./**/*"],
2888
2962
  "compilerOptions": {
2889
2963
  "strict": true,
2890
2964
  "esModuleInterop": true,
2891
- "lib": [ "dom", "es2015" ],
2965
+ "lib": ["dom", "es2015"],
2892
2966
  "jsx": "react-jsx"
2893
2967
  }
2894
2968
  }
@@ -3021,8 +3095,8 @@ const columns = [
3021
3095
  info.cell.getValue() === "Single"
3022
3096
  ? "notice"
3023
3097
  : info.cell.getValue() === "In Relationship"
3024
- ? "positive"
3025
- : "negative"
3098
+ ? "positive"
3099
+ : "negative"
3026
3100
  }
3027
3101
  sdsStyle="rounded"
3028
3102
  sdsType="secondary"
@@ -3087,7 +3161,6 @@ function App() {
3087
3161
  }
3088
3162
 
3089
3163
  export default App;
3090
-
3091
3164
  ```
3092
3165
 
3093
3166
  **/index.tsx**
@@ -3127,13 +3200,12 @@ root.render(
3127
3200
  <RootApp />
3128
3201
  </React.StrictMode>
3129
3202
  );
3130
-
3131
3203
  ```
3132
3204
 
3133
3205
  **/public/index.html**
3134
3206
 
3135
3207
  ```html
3136
- <!DOCTYPE html>
3208
+ <!doctype html>
3137
3209
  <html lang="en">
3138
3210
  <head>
3139
3211
  <meta charset="UTF-8" />
@@ -3154,13 +3226,24 @@ root.render(
3154
3226
  <div id="root"></div>
3155
3227
  </body>
3156
3228
  </html>
3157
-
3158
3229
  ```
3159
3230
 
3160
3231
  **/package.json**
3161
3232
 
3162
3233
  ```json
3163
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
3234
+ {
3235
+ "dependencies": {
3236
+ "react": "^18.0.0",
3237
+ "react-dom": "^18.0.0",
3238
+ "react-scripts": "^4.0.0"
3239
+ },
3240
+ "devDependencies": {
3241
+ "@types/react": "^18.0.0",
3242
+ "@types/react-dom": "^18.0.0",
3243
+ "typescript": "^4.0.0"
3244
+ },
3245
+ "main": "/index.tsx"
3246
+ }
3164
3247
  ```
3165
3248
 
3166
3249
  ---
@@ -3224,13 +3307,11 @@ thead {
3224
3307
 
3225
3308
  ```json
3226
3309
  {
3227
- "include": [
3228
- "./**/*"
3229
- ],
3310
+ "include": ["./**/*"],
3230
3311
  "compilerOptions": {
3231
3312
  "strict": true,
3232
3313
  "esModuleInterop": true,
3233
- "lib": [ "dom", "es2015" ],
3314
+ "lib": ["dom", "es2015"],
3234
3315
  "jsx": "react-jsx"
3235
3316
  }
3236
3317
  }
@@ -3402,8 +3483,8 @@ function App() {
3402
3483
  info.cell.getValue() === "single"
3403
3484
  ? "notice"
3404
3485
  : info.cell.getValue() === "relationship"
3405
- ? "positive"
3406
- : "negative"
3486
+ ? "positive"
3487
+ : "negative"
3407
3488
  }
3408
3489
  sdsStyle="rounded"
3409
3490
  sdsType="secondary"
@@ -3552,7 +3633,6 @@ function App() {
3552
3633
  }
3553
3634
 
3554
3635
  export default App;
3555
-
3556
3636
  ```
3557
3637
 
3558
3638
  **/index.tsx**
@@ -3592,13 +3672,12 @@ root.render(
3592
3672
  <RootApp />
3593
3673
  </React.StrictMode>
3594
3674
  );
3595
-
3596
3675
  ```
3597
3676
 
3598
3677
  **/public/index.html**
3599
3678
 
3600
3679
  ```html
3601
- <!DOCTYPE html>
3680
+ <!doctype html>
3602
3681
  <html lang="en">
3603
3682
  <head>
3604
3683
  <meta charset="UTF-8" />
@@ -3619,13 +3698,24 @@ root.render(
3619
3698
  <div id="root"></div>
3620
3699
  </body>
3621
3700
  </html>
3622
-
3623
3701
  ```
3624
3702
 
3625
3703
  **/package.json**
3626
3704
 
3627
3705
  ```json
3628
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
3706
+ {
3707
+ "dependencies": {
3708
+ "react": "^18.0.0",
3709
+ "react-dom": "^18.0.0",
3710
+ "react-scripts": "^4.0.0"
3711
+ },
3712
+ "devDependencies": {
3713
+ "@types/react": "^18.0.0",
3714
+ "@types/react-dom": "^18.0.0",
3715
+ "typescript": "^4.0.0"
3716
+ },
3717
+ "main": "/index.tsx"
3718
+ }
3629
3719
  ```
3630
3720
 
3631
3721
  ---
@@ -3677,20 +3767,17 @@ h1 {
3677
3767
  border: none;
3678
3768
  outline: none;
3679
3769
  }
3680
-
3681
3770
  ```
3682
3771
 
3683
3772
  **tsconfig.json**
3684
3773
 
3685
3774
  ```json
3686
3775
  {
3687
- "include": [
3688
- "./**/*"
3689
- ],
3776
+ "include": ["./**/*"],
3690
3777
  "compilerOptions": {
3691
3778
  "strict": true,
3692
3779
  "esModuleInterop": true,
3693
- "lib": [ "dom", "es2015" ],
3780
+ "lib": ["dom", "es2015"],
3694
3781
  "jsx": "react-jsx"
3695
3782
  }
3696
3783
  }
@@ -3773,15 +3860,19 @@ declare module "@tanstack/react-table" {
3773
3860
 
3774
3861
  const CellEditor = (cell: CellContext<Person, unknown>) => {
3775
3862
  const theme = useTheme();
3776
- const semanticColors = getSemanticColors({theme});
3777
-
3863
+ const semanticColors = getSemanticColors({ theme });
3864
+
3778
3865
  const initialValue = cell.getValue();
3779
3866
  // We need to keep and update the state of the cell normally
3780
3867
  const [value, setValue] = React.useState(initialValue);
3781
3868
 
3782
3869
  // When the input is blurred, we'll call our table meta's updateData function
3783
3870
  const onBlur = () => {
3784
- cell.table.options.meta?.updateData(cell.row.index, cell.column.id, value as Person);
3871
+ cell.table.options.meta?.updateData(
3872
+ cell.row.index,
3873
+ cell.column.id,
3874
+ value as Person
3875
+ );
3785
3876
  };
3786
3877
 
3787
3878
  // If the initialValue is changed external, sync it up with our state
@@ -3798,7 +3889,7 @@ const CellEditor = (cell: CellContext<Person, unknown>) => {
3798
3889
  style={{ color: semanticColors?.base?.textPrimary }}
3799
3890
  />
3800
3891
  );
3801
- }
3892
+ };
3802
3893
 
3803
3894
  // Give our default column cell renderer editing superpowers!
3804
3895
  const defaultColumn: Partial<ColumnDef<Person>> = {
@@ -3954,7 +4045,6 @@ function App() {
3954
4045
  }
3955
4046
 
3956
4047
  export default App;
3957
-
3958
4048
  ```
3959
4049
 
3960
4050
  **/index.tsx**
@@ -3994,13 +4084,12 @@ root.render(
3994
4084
  <RootApp />
3995
4085
  </React.StrictMode>
3996
4086
  );
3997
-
3998
4087
  ```
3999
4088
 
4000
4089
  **/public/index.html**
4001
4090
 
4002
4091
  ```html
4003
- <!DOCTYPE html>
4092
+ <!doctype html>
4004
4093
  <html lang="en">
4005
4094
  <head>
4006
4095
  <meta charset="UTF-8" />
@@ -4021,13 +4110,24 @@ root.render(
4021
4110
  <div id="root"></div>
4022
4111
  </body>
4023
4112
  </html>
4024
-
4025
4113
  ```
4026
4114
 
4027
4115
  **/package.json**
4028
4116
 
4029
4117
  ```json
4030
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
4118
+ {
4119
+ "dependencies": {
4120
+ "react": "^18.0.0",
4121
+ "react-dom": "^18.0.0",
4122
+ "react-scripts": "^4.0.0"
4123
+ },
4124
+ "devDependencies": {
4125
+ "@types/react": "^18.0.0",
4126
+ "@types/react-dom": "^18.0.0",
4127
+ "typescript": "^4.0.0"
4128
+ },
4129
+ "main": "/index.tsx"
4130
+ }
4031
4131
  ```
4032
4132
 
4033
4133
  ---
@@ -4072,13 +4172,11 @@ button {
4072
4172
 
4073
4173
  ```json
4074
4174
  {
4075
- "include": [
4076
- "./**/*"
4077
- ],
4175
+ "include": ["./**/*"],
4078
4176
  "compilerOptions": {
4079
4177
  "strict": true,
4080
4178
  "esModuleInterop": true,
4081
- "lib": [ "dom", "es2015" ],
4179
+ "lib": ["dom", "es2015"],
4082
4180
  "jsx": "react-jsx"
4083
4181
  }
4084
4182
  }
@@ -4237,8 +4335,8 @@ function App() {
4237
4335
  cell.cell.getValue() === "single"
4238
4336
  ? "notice"
4239
4337
  : cell.cell.getValue() === "relationship"
4240
- ? "positive"
4241
- : "negative"
4338
+ ? "positive"
4339
+ : "negative"
4242
4340
  }
4243
4341
  sdsStyle="rounded"
4244
4342
  sdsType="secondary"
@@ -4323,7 +4421,6 @@ function App() {
4323
4421
  }
4324
4422
 
4325
4423
  export default App;
4326
-
4327
4424
  ```
4328
4425
 
4329
4426
  **/index.tsx**
@@ -4363,13 +4460,12 @@ root.render(
4363
4460
  <RootApp />
4364
4461
  </React.StrictMode>
4365
4462
  );
4366
-
4367
4463
  ```
4368
4464
 
4369
4465
  **/public/index.html**
4370
4466
 
4371
4467
  ```html
4372
- <!DOCTYPE html>
4468
+ <!doctype html>
4373
4469
  <html lang="en">
4374
4470
  <head>
4375
4471
  <meta charset="UTF-8" />
@@ -4390,13 +4486,24 @@ root.render(
4390
4486
  <div id="root"></div>
4391
4487
  </body>
4392
4488
  </html>
4393
-
4394
4489
  ```
4395
4490
 
4396
4491
  **/package.json**
4397
4492
 
4398
4493
  ```json
4399
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
4494
+ {
4495
+ "dependencies": {
4496
+ "react": "^18.0.0",
4497
+ "react-dom": "^18.0.0",
4498
+ "react-scripts": "^4.0.0"
4499
+ },
4500
+ "devDependencies": {
4501
+ "@types/react": "^18.0.0",
4502
+ "@types/react-dom": "^18.0.0",
4503
+ "typescript": "^4.0.0"
4504
+ },
4505
+ "main": "/index.tsx"
4506
+ }
4400
4507
  ```
4401
4508
 
4402
4509
  ---
@@ -4447,20 +4554,17 @@ button {
4447
4554
  padding-left: 5px;
4448
4555
  color: #888;
4449
4556
  }
4450
-
4451
4557
  ```
4452
4558
 
4453
4559
  **tsconfig.json**
4454
4560
 
4455
4561
  ```json
4456
4562
  {
4457
- "include": [
4458
- "./**/*"
4459
- ],
4563
+ "include": ["./**/*"],
4460
4564
  "compilerOptions": {
4461
4565
  "strict": true,
4462
4566
  "esModuleInterop": true,
4463
- "lib": [ "dom", "es2015" ],
4567
+ "lib": ["dom", "es2015"],
4464
4568
  "jsx": "react-jsx"
4465
4569
  }
4466
4570
  }
@@ -4650,8 +4754,8 @@ function App() {
4650
4754
  cell.cell.getValue() === "single"
4651
4755
  ? "notice"
4652
4756
  : cell.cell.getValue() === "relationship"
4653
- ? "positive"
4654
- : "negative"
4757
+ ? "positive"
4758
+ : "negative"
4655
4759
  }
4656
4760
  sdsStyle="rounded"
4657
4761
  sdsType="secondary"
@@ -4748,7 +4852,6 @@ function App() {
4748
4852
  }
4749
4853
 
4750
4854
  export default App;
4751
-
4752
4855
  ```
4753
4856
 
4754
4857
  **/index.tsx**
@@ -4792,13 +4895,12 @@ root.render(
4792
4895
  <RootApp />
4793
4896
  </React.StrictMode>
4794
4897
  );
4795
-
4796
4898
  ```
4797
4899
 
4798
4900
  **/public/index.html**
4799
4901
 
4800
4902
  ```html
4801
- <!DOCTYPE html>
4903
+ <!doctype html>
4802
4904
  <html lang="en">
4803
4905
  <head>
4804
4906
  <meta charset="UTF-8" />
@@ -4819,14 +4921,24 @@ root.render(
4819
4921
  <div id="root"></div>
4820
4922
  </body>
4821
4923
  </html>
4822
-
4823
4924
  ```
4824
4925
 
4825
4926
  **/package.json**
4826
4927
 
4827
4928
  ```json
4828
- {"dependencies":{"react":"^18.0.0","react-dom":"^18.0.0","react-scripts":"^4.0.0"},"devDependencies":{"@types/react":"^18.0.0","@types/react-dom":"^18.0.0","typescript":"^4.0.0"},"main":"/index.tsx"}
4929
+ {
4930
+ "dependencies": {
4931
+ "react": "^18.0.0",
4932
+ "react-dom": "^18.0.0",
4933
+ "react-scripts": "^4.0.0"
4934
+ },
4935
+ "devDependencies": {
4936
+ "@types/react": "^18.0.0",
4937
+ "@types/react-dom": "^18.0.0",
4938
+ "typescript": "^4.0.0"
4939
+ },
4940
+ "main": "/index.tsx"
4941
+ }
4829
4942
  ```
4830
4943
 
4831
4944
  ---
4832
-