playbook_ui 14.16.0.pre.alpha.play1959tablekitstripedlogicoverridesbackground6893 → 14.16.0.pre.alpha.play1960buttonkitdisablenotworkingdanger6850

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 (30) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/pb_advanced_table/_advanced_table.tsx +84 -86
  3. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_pagination.jsx +1 -0
  4. data/app/pb_kits/playbook/pb_rich_text_editor/_rich_text_editor.tsx +11 -29
  5. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_default.html.erb +1 -1
  6. data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor.html.erb +4 -4
  7. data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor.rb +0 -2
  8. data/app/pb_kits/playbook/pb_table/_table.tsx +0 -4
  9. data/app/pb_kits/playbook/pb_table/docs/example.yml +0 -2
  10. data/app/pb_kits/playbook/pb_table/docs/index.js +0 -2
  11. data/app/pb_kits/playbook/pb_table/styles/_headers.scss +0 -76
  12. data/app/pb_kits/playbook/pb_table/styles/_striped.scss +3 -3
  13. data/app/pb_kits/playbook/pb_table/subcomponents/_table_head.tsx +1 -11
  14. data/app/pb_kits/playbook/pb_table/subcomponents/_table_header.tsx +1 -11
  15. data/app/pb_kits/playbook/pb_table/subcomponents/_table_row.tsx +0 -5
  16. data/app/pb_kits/playbook/pb_table/table.test.js +0 -17
  17. data/dist/chunks/{_typeahead-N-EFroAX.js → _typeahead-HN7DWIZV.js} +1 -1
  18. data/dist/chunks/_weekday_stacked-DpwdSQoj.js +45 -0
  19. data/dist/chunks/vendor.js +1 -1
  20. data/dist/playbook-doc.js +1 -1
  21. data/dist/playbook-rails-react-bindings.js +1 -1
  22. data/dist/playbook-rails.js +1 -1
  23. data/dist/playbook.css +1 -1
  24. data/lib/playbook/version.rb +1 -1
  25. metadata +4 -8
  26. data/app/pb_kits/playbook/pb_table/docs/_table_with_header_style_borderless.jsx +0 -50
  27. data/app/pb_kits/playbook/pb_table/docs/_table_with_header_style_borderless_react.md +0 -1
  28. data/app/pb_kits/playbook/pb_table/docs/_table_with_header_style_floating.jsx +0 -59
  29. data/app/pb_kits/playbook/pb_table/docs/_table_with_header_style_floating_react.md +0 -1
  30. data/dist/chunks/_weekday_stacked-Db780bKR.js +0 -45
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b1b61bbe353c51c6d0b9b65fe43a989ecd07bc6383f816a8ca36385541a8fab3
4
- data.tar.gz: 9e0b3698c30553e33d081a9cd6eb70d1a299b5a309ae197cbb44ce65b1be3e69
3
+ metadata.gz: ec0875c5557cec086ec99ae1cbaf9f47361e3a4584e4b677136fd3ce394db55d
4
+ data.tar.gz: 456a8945cc951c32c481c638e66ee8a685902e1a1b02b75bcd8fb6e5709a5c2e
5
5
  SHA512:
6
- metadata.gz: db55d048eb70afdb219b9e6bcc9eb44301414a209daf19fff52a4b858e744eda43764ce1e3abb7f94c3eb4d8b1fbd208405f1ec45a00bb9bf33cc2049a7cba51
7
- data.tar.gz: 0afca121c5aab26a344906909da824344db35d0fcf0b74c5f4450a1204cd1606ac0888e26c2c7a8dd71a2f4ae128864aae0bb25b928c1da482c78e213522cbe1
6
+ metadata.gz: 7d30f5a21e8502edb67813757f015e1c7b95a1f19cbc435e5e5e553fd0c3477c82fba61713834accd60a58286f500c03623d062183485b6f9a5c98b84b2ceb6a
7
+ data.tar.gz: 67b9bac93175b4881f236ea5f2ceef4023a6eeefea241dc5503ec8e7c27a5d3a128fdc90aa73bde6a8dabc02648ed7450e0fc62e3f75a9a666c65a3b17024215
@@ -167,95 +167,93 @@ const AdvancedTable = (props: AdvancedTableProps) => {
167
167
  const isActionBarVisible = selectableRows && showActionsBar && selectedRowsLength > 0;
168
168
 
169
169
  return (
170
- <>
171
- {/* Top Pagination */}
172
- {pagination && (
173
- <TablePagination
174
- onChange={onPageChange}
175
- position="top"
176
- range={paginationProps?.range}
177
- table={table}
178
- />
179
- )}
180
-
181
- <div
182
- {...ariaProps}
183
- {...dataProps}
184
- {...htmlProps}
185
- className={classes}
186
- id={id}
187
- onScroll={virtualizedRows ? e => fetchMoreOnBottomReached(
188
- e.currentTarget,
189
- fetchNextPage,
190
- isFetching,
191
- totalFetched,
192
- fullData.length
193
- ) : undefined}
194
- ref={tableWrapperRef}
195
- style={tableWrapperStyle as React.CSSProperties}
170
+ <div
171
+ {...ariaProps}
172
+ {...dataProps}
173
+ {...htmlProps}
174
+ className={classes}
175
+ id={id}
176
+ onScroll={virtualizedRows ? e => fetchMoreOnBottomReached(
177
+ e.currentTarget,
178
+ fetchNextPage,
179
+ isFetching,
180
+ totalFetched,
181
+ fullData.length
182
+ ) : undefined}
183
+ ref={tableWrapperRef}
184
+ style={tableWrapperStyle as React.CSSProperties}
185
+ >
186
+ <AdvancedTableProvider
187
+ columnDefinitions={columnDefinitions}
188
+ enableToggleExpansion={enableToggleExpansion}
189
+ enableVirtualization={virtualizedRows}
190
+ expanded={expanded}
191
+ expandedControl={expandedControl}
192
+ handleExpandOrCollapse={handleExpandOrCollapse}
193
+ hasAnySubRows={hasAnySubRows}
194
+ inlineRowLoading={inlineRowLoading}
195
+ isActionBarVisible={isActionBarVisible}
196
+ loading={loading}
197
+ responsive={responsive}
198
+ selectableRows={selectableRows}
199
+ setExpanded={setExpanded}
200
+ showActionsBar={showActionsBar}
201
+ sortControl={sortControl}
202
+ subRowHeaders={tableOptions?.subRowHeaders}
203
+ table={table}
204
+ tableContainerRef={tableWrapperRef}
205
+ toggleExpansionIcon={toggleExpansionIcon}
206
+ virtualizedRows={virtualizedRows}
196
207
  >
197
- <AdvancedTableProvider
198
- columnDefinitions={columnDefinitions}
199
- enableToggleExpansion={enableToggleExpansion}
200
- enableVirtualization={virtualizedRows}
201
- expanded={expanded}
202
- expandedControl={expandedControl}
203
- handleExpandOrCollapse={handleExpandOrCollapse}
204
- hasAnySubRows={hasAnySubRows}
205
- inlineRowLoading={inlineRowLoading}
206
- isActionBarVisible={isActionBarVisible}
207
- loading={loading}
208
- responsive={responsive}
209
- selectableRows={selectableRows}
210
- setExpanded={setExpanded}
211
- showActionsBar={showActionsBar}
212
- sortControl={sortControl}
213
- subRowHeaders={tableOptions?.subRowHeaders}
214
- table={table}
215
- tableContainerRef={tableWrapperRef}
216
- toggleExpansionIcon={toggleExpansionIcon}
217
- virtualizedRows={virtualizedRows}
218
- >
219
- <React.Fragment>
220
- {/* Selection Action Bar */}
221
- <TableActionBar
222
- actions={actions}
223
- isVisible={isActionBarVisible}
224
- selectedCount={selectedRowsLength}
208
+ <React.Fragment>
209
+ {/* Top Pagination */}
210
+ {pagination && (
211
+ <TablePagination
212
+ onChange={onPageChange}
213
+ position="top"
214
+ range={paginationProps?.range}
215
+ table={table}
225
216
  />
217
+ )}
218
+
219
+ {/* Selection Action Bar */}
220
+ <TableActionBar
221
+ actions={actions}
222
+ isVisible={isActionBarVisible}
223
+ selectedCount={selectedRowsLength}
224
+ />
226
225
 
227
- {/* Main Table */}
228
- <Table
229
- className={`${loading ? "content-loading" : ""}`}
230
- dark={dark}
231
- dataTable
232
- numberSpacing="tabular"
233
- responsive="none"
234
- {...tableProps}
235
- >
236
- {children ? (
237
- children
238
- ) : (
239
- <>
240
- <TableHeader />
241
- <TableBody />
242
- </>
243
- )}
244
- </Table>
245
- </React.Fragment>
246
- </AdvancedTableProvider>
247
-
248
- </div>
249
- {/* Bottom Pagination */}
250
- {pagination && (
251
- <TablePagination
252
- onChange={onPageChange}
253
- position="bottom"
254
- range={paginationProps?.range}
255
- table={table}
256
- />
257
- )}
258
- </>
226
+ {/* Main Table */}
227
+ <Table
228
+ className={`${loading ? "content-loading" : ""}`}
229
+ dark={dark}
230
+ dataTable
231
+ numberSpacing="tabular"
232
+ responsive="none"
233
+ {...tableProps}
234
+ >
235
+ {children ? (
236
+ children
237
+ ) : (
238
+ <>
239
+ <TableHeader />
240
+ <TableBody />
241
+ </>
242
+ )}
243
+ </Table>
244
+
245
+ {/* Bottom Pagination */}
246
+ {pagination && (
247
+ <TablePagination
248
+ onChange={onPageChange}
249
+ position="bottom"
250
+ range={paginationProps?.range}
251
+ table={table}
252
+ />
253
+ )}
254
+ </React.Fragment>
255
+ </AdvancedTableProvider>
256
+ </div>
259
257
  );
260
258
  };
261
259
 
@@ -40,6 +40,7 @@ const AdvancedTablePagination = (props) => {
40
40
  <AdvancedTable
41
41
  columnDefinitions={columnDefinitions}
42
42
  pagination
43
+ responsive="none"
43
44
  tableData={PAGINATION_MOCK_DATA}
44
45
  {...props}
45
46
  />
@@ -32,12 +32,11 @@ type RichTextEditorProps = {
32
32
  advancedEditor?: any,
33
33
  advancedEditorToolbar?: boolean,
34
34
  toolbarBottom?: boolean,
35
- children?: React.ReactNode | React.ReactNode[],
35
+ children?: React.ReactNode | React.ReactNode[]
36
36
  className?: string,
37
37
  data?: { [key: string]: string },
38
38
  focus?: boolean,
39
- htmlOptions?: { [key: string]: string | number | boolean | (() => void) },
40
- inputOptions?: { [key: string]: string | number | boolean | (() => void) },
39
+ htmlOptions?: {[key: string]: string | number | boolean | (() => void)},
41
40
  id?: string,
42
41
  inline?: boolean,
43
42
  extensions?: { [key: string]: string }[],
@@ -62,7 +61,6 @@ const RichTextEditor = (props: RichTextEditorProps): React.ReactElement => {
62
61
  data = {},
63
62
  focus = false,
64
63
  htmlOptions = {},
65
- inputOptions = {},
66
64
  inline = false,
67
65
  extensions,
68
66
  name,
@@ -72,7 +70,7 @@ const RichTextEditor = (props: RichTextEditorProps): React.ReactElement => {
72
70
  sticky = false,
73
71
  template = '',
74
72
  value = '',
75
- maxWidth = "md"
73
+ maxWidth="md"
76
74
  } = props
77
75
 
78
76
  const ariaProps = buildAriaProps(aria),
@@ -81,28 +79,12 @@ const RichTextEditor = (props: RichTextEditorProps): React.ReactElement => {
81
79
 
82
80
  const htmlProps = buildHtmlProps(htmlOptions)
83
81
 
84
- const handleOnEditorReady = (editorInstance: Editor) => {
85
- setEditor(editorInstance)
86
- setTimeout(() => {
87
- const oldId = editorInstance.element.getAttribute('input')
88
- if (oldId) {
89
- const hiddenInput = document.getElementById(oldId)
90
- if (hiddenInput) {
91
- const newId = (inputOptions.id as string) || oldId
92
- hiddenInput.id = newId
93
- editorInstance.element.setAttribute('input', newId)
94
-
95
- if (inputOptions.name) {
96
- hiddenInput.setAttribute('name', inputOptions.name as string)
97
- }
98
- }
99
- }
100
- })
101
- }
82
+ const handleOnEditorReady = (editorInstance: Editor) => setEditor(editorInstance),
83
+ element = editor?.element
102
84
 
103
85
  // DOM manipulation must wait for editor to be ready
104
- if (editor && editor.element) {
105
- const toolbarElement = editor.element.parentElement.querySelector('trix-toolbar') as HTMLElement,
86
+ if (editor) {
87
+ const toolbarElement = element.parentElement.querySelector('trix-toolbar') as HTMLElement,
106
88
  blockCodeButton = toolbarElement.querySelector('[data-trix-attribute=code]') as HTMLElement
107
89
 
108
90
  // replace default trix "block code" button with "inline code" button
@@ -136,8 +118,8 @@ const RichTextEditor = (props: RichTextEditorProps): React.ReactElement => {
136
118
  }, [editor, template])
137
119
 
138
120
  useEffect(() => {
139
- if (!editor?.element) return
140
- editor.element.addEventListener('click', ({ target }: Event) => {
121
+ if (!element) return
122
+ element.addEventListener('click', ({ target }: Event) => {
141
123
  const trixEditorContainer = (target as Element).closest('.pb_rich_text_editor_kit')
142
124
  if (!trixEditorContainer) return
143
125
 
@@ -146,7 +128,7 @@ const RichTextEditor = (props: RichTextEditorProps): React.ReactElement => {
146
128
 
147
129
  if (anchorElement.hasAttribute('href')) window.open(anchorElement.href)
148
130
  })
149
- }, [editor])
131
+ }, [element])
150
132
 
151
133
  const richTextEditorClass = 'pb_rich_text_editor_kit',
152
134
  simpleClass = simple ? 'simple' : '',
@@ -155,7 +137,7 @@ const RichTextEditor = (props: RichTextEditorProps): React.ReactElement => {
155
137
  inlineClass = inline ? 'inline' : '',
156
138
  toolbarBottomClass = toolbarBottom ? 'toolbar-bottom' : ''
157
139
 
158
- let css = classnames(globalProps(props, { maxWidth }), className)
140
+ let css = classnames(globalProps(props, {maxWidth}), className)
159
141
  css = classnames(
160
142
  richTextEditorClass,
161
143
  simpleClass,
@@ -1 +1 @@
1
- <%= pb_rails("rich_text_editor", props: {input_options: { id: 'hidden_input_id', name: "hidden_input_name" }, value: "Add your text here. You can format your text, add links, quotes, and bullets."}) %>
1
+ <%= pb_rails("rich_text_editor", props: {id: "default", value: "Add your text here. You can format your text, add links, quotes, and bullets."}) %>
@@ -1,5 +1,5 @@
1
1
  <%= react_component('RichTextEditor',
2
- object.rich_text_options,
3
- aria: object.aria,
4
- data: object.data
5
- ) %>
2
+ object.rich_text_options,
3
+ aria: object.aria,
4
+ data: object.data
5
+ ) %>
@@ -20,7 +20,6 @@ module Playbook
20
20
  prop :value
21
21
  prop :template
22
22
  prop :placeholder
23
- prop :input_options
24
23
 
25
24
  def classname
26
25
  generate_classname("pb_rich_text_editor_kit", simple_class, focus_class, sticky_class, separator: " ")
@@ -50,7 +49,6 @@ module Playbook
50
49
  value: value,
51
50
  template: template,
52
51
  placeholder: placeholder,
53
- inputOptions: input_options,
54
52
  }
55
53
  end
56
54
  end
@@ -21,7 +21,6 @@ type TableProps = {
21
21
  data?: { [key: string]: string },
22
22
  dataTable: boolean,
23
23
  disableHover?: boolean,
24
- headerStyle?: "default" | "borderless" | "floating"
25
24
  htmlOptions?: { [key: string]: string | number | boolean | (() => void) },
26
25
  id?: string,
27
26
  outerPadding?: "none" | "xxs" | "xs" | "sm" | "md" | "lg" | "xl",
@@ -47,7 +46,6 @@ const Table = (props: TableProps): React.ReactElement => {
47
46
  data = {},
48
47
  dataTable = false,
49
48
  disableHover = false,
50
- headerStyle = "default",
51
49
  htmlOptions = {},
52
50
  id,
53
51
  outerPadding = '',
@@ -87,8 +85,6 @@ const Table = (props: TableProps): React.ReactElement => {
87
85
  'sticky-left-column': stickyLeftColumn,
88
86
  'sticky-right-column': stickyRightColumn,
89
87
  'striped': striped,
90
- 'header-borderless': headerStyle === 'borderless',
91
- 'header-floating': headerStyle === 'floating',
92
88
  [outerPaddingCss]: outerPadding !== '',
93
89
  },
94
90
  globalProps(props),
@@ -75,5 +75,3 @@ examples:
75
75
  - table_with_collapsible_with_nested_table: Table with Collapsible with Nested Table
76
76
  - table_with_clickable_rows: Table with Clickable Rows
77
77
  - table_with_selectable_rows: Table with Selectable Rows
78
- - table_with_header_style_borderless: Header Style Borderless
79
- - table_with_header_style_floating: Header Style Floating
@@ -35,5 +35,3 @@ export { default as TableWithCollapsibleWithNestedRows } from './_table_with_col
35
35
  export { default as TableWithCollapsibleWithCustomClick } from './_table_with_collapsible_with_custom_click.jsx'
36
36
  export { default as TableWithSelectableRows } from './_table_with_selectable_rows.jsx'
37
37
  export { default as TableWithClickableRows } from './_table_with_clickable_rows.jsx'
38
- export { default as TableWithHeaderStyleBorderless } from './_table_with_header_style_borderless.jsx'
39
- export { default as TableWithHeaderStyleFloating } from './_table_with_header_style_floating.jsx'
@@ -14,79 +14,3 @@
14
14
  }
15
15
  }
16
16
  }
17
- // remove all outward facing borders from header
18
- .header-borderless > thead,
19
- .header-borderless > thead > tr,
20
- .header-borderless > thead > tr > th,
21
- .header-borderless > .pb_table_thead,
22
- .header-borderless > .pb_table_thead > .pb_table_tr,
23
- .header-borderless > .pb_table_thead .pb_table_th {
24
- border-top: none !important;
25
- border-left: none !important;
26
- border-right: none !important;
27
- }
28
-
29
- // remove bottom border (internal to table) on header cells - only light mode needs this redundancy handled likely due to a difference in the base scss and table-dark.scss
30
- .header-borderless:not(.table-dark) > thead > tr:last-child > th,
31
- .header-borderless:not(.table-dark) > .pb_table_thead > .pb_table_tr:last-child > .pb_table_th {
32
- border-bottom: none !important;
33
- }
34
-
35
- // preserves top rounded corners to header at top of table-card for unnested card
36
- .header-borderless > thead > tr:first-child > th:first-child,
37
- .header-borderless > .pb_table_thead > .pb_table_tr:first-child > .pb_table_th:first-child {
38
- border-top-left-radius: $border_radius_md !important;
39
- }
40
-
41
- .header-borderless > thead > tr:first-child > th:last-child,
42
- .header-borderless > .pb_table_thead > .pb_table_tr:first-child > .pb_table_th:last-child {
43
- border-top-right-radius: $border_radius_md !important;
44
- }
45
-
46
- // ensures top border is from first row of body to prevent double borders
47
- .header-borderless > tbody > tr:first-child > td,
48
- .header-borderless > .pb_table_tbody > .pb_table_tr:first-child > .pb_table_td {
49
- border-top: 1px solid $border_light !important;
50
- }
51
-
52
- // floating code - this carries over everything for header-borderless
53
- .header-floating > thead,
54
- .header-floating > thead > tr,
55
- .header-floating > thead > tr > th,
56
- .header-floating > .pb_table_thead,
57
- .header-floating > .pb_table_thead > .pb_table_tr,
58
- .header-floating > .pb_table_thead .pb_table_th {
59
- border-top: none !important;
60
- border-left: none !important;
61
- border-right: none !important;
62
- }
63
-
64
- .header-floating:not(.table-dark) > thead > tr:last-child > th,
65
- .header-floating:not(.table-dark) > .pb_table_thead > .pb_table_tr:last-child > .pb_table_th {
66
- border-bottom: none !important;
67
- }
68
-
69
- .header-floating > thead > tr:first-child > th:first-child,
70
- .header-floating > .pb_table_thead > .pb_table_tr:first-child > .pb_table_th:first-child {
71
- border-top-left-radius: $border_radius_md !important;
72
- }
73
-
74
- .header-floating > thead > tr:first-child > th:last-child,
75
- .header-floating > .pb_table_thead > .pb_table_tr:first-child > .pb_table_th:last-child {
76
- border-top-right-radius: $border_radius_md !important;
77
- }
78
-
79
- .header-floating > tbody > tr:first-child > td,
80
- .header-floating > .pb_table_tbody > .pb_table_tr:first-child > .pb_table_td {
81
- border-top: 1px solid $border_light !important;
82
- }
83
-
84
- // flatten out corners for floating headerstyle variant to avoid small triangle of white/empty space
85
- .header-floating > thead > tr:first-child > th:first-child,
86
- .header-floating > .pb_table_thead > .pb_table_tr:first-child > .pb_table_th:first-child {
87
- border-top-left-radius: 0 !important;
88
- }
89
- .header-floating > thead > tr:first-child > th:last-child,
90
- .header-floating > .pb_table_thead > .pb_table_tr:first-child > .pb_table_th:last-child {
91
- border-top-right-radius: 0 !important;
92
- }
@@ -1,7 +1,7 @@
1
- [class^=pb_table]:not(:has(colgroup)) {
1
+ [class^=pb_table] {
2
2
  &.striped {
3
3
  tbody, .pb_table_tbody {
4
- tr:nth-child(odd):not(.pb_background_kit), .pb_table_tr:nth-child(odd):not(.pb_background_kit) {
4
+ tr:nth-child(odd), .pb_table_tr:nth-child(odd) {
5
5
  background-color: $bg_light;
6
6
  }
7
7
  }
@@ -10,7 +10,7 @@
10
10
  &.dark {
11
11
  &.striped {
12
12
  tbody, .pb_table_tbody {
13
- tr:nth-child(odd):not(.pb_background_kit), .pb_table_tr:nth-child(odd):not(.pb_background_kit) {
13
+ tr:nth-child(odd), .pb_table_tr:nth-child(odd) {
14
14
  background-color: $bg_dark;
15
15
  }
16
16
  }
@@ -12,7 +12,6 @@ type TableHeadPropTypes = {
12
12
  children: React.ReactNode[] | React.ReactNode;
13
13
  className: string;
14
14
  data?: { [key: string]: string };
15
- headerStyle?: "default" | "borderless" | "floating";
16
15
  htmlOptions?: { [key: string]: string | number | boolean | (() => void) };
17
16
  id?: string;
18
17
  tag?: "table" | "div";
@@ -24,7 +23,6 @@ const TableHead = (props: TableHeadPropTypes): React.ReactElement => {
24
23
  children,
25
24
  className,
26
25
  data = {},
27
- headerStyle = "default",
28
26
  htmlOptions = {},
29
27
  id,
30
28
  tag = "table",
@@ -33,15 +31,7 @@ const TableHead = (props: TableHeadPropTypes): React.ReactElement => {
33
31
  const ariaProps = buildAriaProps(aria);
34
32
  const dataProps = buildDataProps(data);
35
33
  const htmlProps = buildHtmlProps(htmlOptions);
36
- const classes = classnames(
37
- "pb_table_thead",
38
- {
39
- "pb_table_thead_borderless": headerStyle === "borderless" || headerStyle === "floating",
40
- "pb_table_thead_floating": headerStyle === "floating",
41
- },
42
- globalProps(props),
43
- className
44
- );
34
+ const classes = classnames("pb_table_thead", globalProps(props), className);
45
35
  const isTableTag = tag === "table";
46
36
 
47
37
  return (
@@ -12,7 +12,6 @@ type TableHeaderPropTypes = {
12
12
  children: React.ReactNode[] | React.ReactNode;
13
13
  className: string;
14
14
  data?: { [key: string]: string };
15
- headerStyle?: "default" | "borderless" | "floating";
16
15
  htmlOptions?: { [key: string]: string | number | boolean | (() => void) };
17
16
  id?: string;
18
17
  tag?: "table" | "div";
@@ -25,7 +24,6 @@ const TableHeader = (props: TableHeaderPropTypes): React.ReactElement => {
25
24
  children,
26
25
  className,
27
26
  data = {},
28
- headerStyle = "default",
29
27
  htmlOptions = {},
30
28
  id,
31
29
  tag = "table",
@@ -35,15 +33,7 @@ const TableHeader = (props: TableHeaderPropTypes): React.ReactElement => {
35
33
  const ariaProps = buildAriaProps(aria);
36
34
  const dataProps = buildDataProps(data);
37
35
  const htmlProps = buildHtmlProps(htmlOptions);
38
- const classes = classnames(
39
- "pb_table_th",
40
- {
41
- "pb_table_thead_borderless": headerStyle === "borderless" || headerStyle === "floating",
42
- "pb_table_thead_floating": headerStyle === "floating",
43
- },
44
- globalProps(props),
45
- className
46
- );
36
+ const classes = classnames("pb_table_th", globalProps(props), className);
47
37
  const isTableTag = tag === "table";
48
38
 
49
39
  return (
@@ -22,7 +22,6 @@ type TableRowPropTypes = {
22
22
  dark?: boolean;
23
23
  dragId?: string;
24
24
  draggableItem?: boolean;
25
- headerStyle?: "default" | "borderless" | "floating";
26
25
  htmlOptions?: { [key: string]: string | number | boolean | (() => void) };
27
26
  id?: string;
28
27
  toggleCellId?: string;
@@ -42,7 +41,6 @@ const TableRow = (props: TableRowPropTypes): React.ReactElement => {
42
41
  dark = false,
43
42
  dragId,
44
43
  draggableItem = false,
45
- headerStyle = "default",
46
44
  htmlOptions = {},
47
45
  id,
48
46
  toggleCellId,
@@ -62,9 +60,6 @@ const TableRow = (props: TableRowPropTypes): React.ReactElement => {
62
60
  const classes = classnames(
63
61
  buildCss("pb_table_row_kit", sideHighlightClass),
64
62
  "pb_table_tr",
65
- {
66
- "pb_table_tr_borderless_header": headerStyle === "borderless",
67
- },
68
63
  collapsibleRow,
69
64
  globalProps(props),
70
65
  className
@@ -167,20 +167,3 @@ test("Should have outerPadding class", () => {
167
167
  const kit = renderKit(Table, props, { outerPadding: "sm" })
168
168
  expect(kit).toHaveClass("pb_table table-sm table-responsive-collapse table-card outer_padding_space_sm table-collapse-sm")
169
169
  })
170
-
171
- test("when headerStyle is default", () => {
172
- const kit = renderKit(Table, props)
173
- expect(kit).toHaveClass("pb_table table-sm table-responsive-collapse table-card table-collapse-sm")
174
- expect(kit).not.toHaveClass("header-borderless")
175
- expect(kit).not.toHaveClass("header-floating")
176
- })
177
-
178
- test("when headerStyle is borderless", () => {
179
- const kit = renderKit(Table, props, { headerStyle: "borderless" })
180
- expect(kit).toHaveClass("pb_table table-sm table-responsive-collapse table-card header-borderless table-collapse-sm")
181
- })
182
-
183
- test("when headerStyle is floating", () => {
184
- const kit = renderKit(Table, props, { headerStyle: "floating" })
185
- expect(kit).toHaveClass("pb_table table-sm table-responsive-collapse table-card header-floating table-collapse-sm")
186
- })