playbook_ui 16.7.0.pre.alpha.tablewidths16409 → 16.7.0.pre.rc.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 (106) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/pb_advanced_table/Components/RegularTableView.tsx +0 -2
  3. data/app/pb_kits/playbook/pb_advanced_table/Components/TableHeaderCell.tsx +0 -2
  4. data/app/pb_kits/playbook/pb_advanced_table/Components/VirtualizedTableView.tsx +1 -5
  5. data/app/pb_kits/playbook/pb_advanced_table/Hooks/useTableState.ts +0 -24
  6. data/app/pb_kits/playbook/pb_advanced_table/advanced_table.test.jsx +0 -76
  7. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling.jsx +0 -2
  8. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling.md +0 -10
  9. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_grouped_headers_composition.jsx +1 -15
  10. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_infinite_scroll.jsx +2 -2
  11. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_inline_row_loading.jsx +2 -2
  12. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_pinned_rows.jsx +2 -2
  13. data/app/pb_kits/playbook/pb_advanced_table/docs/_mock_data_inline_loading.js +200 -0
  14. data/app/pb_kits/playbook/pb_advanced_table/docs/_mock_data_inline_loading_empty_children.js +42 -0
  15. data/app/pb_kits/playbook/pb_advanced_table/docs/_playground.json +5807 -150
  16. data/app/pb_kits/playbook/pb_advanced_table/docs/_playground.overrides.json +30 -5
  17. data/app/pb_kits/playbook/pb_advanced_table/docs/advanced_table_column_definitions_styling.json +1 -6
  18. data/app/pb_kits/playbook/pb_advanced_table/docs/advanced_table_grouped_headers_composition_mock_data.json +98 -0
  19. data/app/pb_kits/playbook/pb_bread_crumbs/docs/_bread_crumbs_default.jsx +5 -5
  20. data/app/pb_kits/playbook/pb_button/_button.scss +2 -1
  21. data/app/pb_kits/playbook/pb_date/docs/_playground.json +17 -13
  22. data/app/pb_kits/playbook/pb_date/docs/_playground.overrides.json +16 -13
  23. data/app/pb_kits/playbook/pb_date_picker/_date_picker.tsx +2 -3
  24. data/app/pb_kits/playbook/pb_date_picker/date_picker.html.erb +2 -2
  25. data/app/pb_kits/playbook/pb_date_picker/date_picker.rb +1 -2
  26. data/app/pb_kits/playbook/pb_date_picker/date_picker.test.js +0 -31
  27. data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_inline.html.erb +2 -0
  28. data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_inline.jsx +2 -0
  29. data/app/pb_kits/playbook/pb_date_picker/docs/_playground.json +42 -136
  30. data/app/pb_kits/playbook/pb_date_picker/docs/_playground.overrides.json +45 -113
  31. data/app/pb_kits/playbook/pb_date_range_inline/docs/_playground.json +6 -48
  32. data/app/pb_kits/playbook/pb_date_range_stacked/docs/_playground.json +5 -28
  33. data/app/pb_kits/playbook/pb_date_stacked/docs/_playground.json +1 -1
  34. data/app/pb_kits/playbook/pb_date_stacked/docs/_playground.overrides.json +1 -1
  35. data/app/pb_kits/playbook/pb_date_time/docs/_playground.json +3 -16
  36. data/app/pb_kits/playbook/pb_date_time/docs/_playground.overrides.json +3 -16
  37. data/app/pb_kits/playbook/pb_date_time_stacked/docs/_playground.json +15 -11
  38. data/app/pb_kits/playbook/pb_date_time_stacked/docs/_playground.overrides.json +15 -11
  39. data/app/pb_kits/playbook/pb_date_year_stacked/docs/_playground.json +4 -4
  40. data/app/pb_kits/playbook/pb_date_year_stacked/docs/_playground.overrides.json +4 -4
  41. data/app/pb_kits/playbook/pb_detail/docs/_playground.json +18 -12
  42. data/app/pb_kits/playbook/pb_detail/docs/_playground.overrides.json +12 -13
  43. data/app/pb_kits/playbook/pb_dialog/docs/_playground.json +42 -108
  44. data/app/pb_kits/playbook/pb_dialog/docs/_playground.overrides.json +40 -88
  45. data/app/pb_kits/playbook/pb_dialog/index.js +1 -6
  46. data/app/pb_kits/playbook/pb_distribution_bar/docs/_playground.json +7 -65
  47. data/app/pb_kits/playbook/pb_draggable/index.js +1 -6
  48. data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_constrain_height.jsx +0 -18
  49. data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_constrain_height_rails.html.erb +0 -11
  50. data/app/pb_kits/playbook/pb_dropdown/docs/_playground.json +21 -318
  51. data/app/pb_kits/playbook/pb_dropdown/docs/_playground.overrides.json +19 -192
  52. data/app/pb_kits/playbook/pb_empty_state/docs/_playground.json +12 -77
  53. data/app/pb_kits/playbook/pb_file_upload/docs/_playground.json +13 -98
  54. data/app/pb_kits/playbook/pb_link/docs/_playground.json +40 -81
  55. data/app/pb_kits/playbook/pb_link/docs/_playground.overrides.json +30 -88
  56. data/app/pb_kits/playbook/pb_pagination/docs/_pagination_external_control.jsx +1 -22
  57. data/app/pb_kits/playbook/pb_pagination/docs/_pagination_page_change.jsx +2 -22
  58. data/app/pb_kits/playbook/pb_pagination/docs/data.js +23 -0
  59. data/app/pb_kits/playbook/pb_phone_number_input/_phone_number_input.tsx +0 -68
  60. data/app/pb_kits/playbook/pb_phone_number_input/docs/_playground.json +2 -4
  61. data/app/pb_kits/playbook/pb_phone_number_input/docs/example.yml +0 -2
  62. data/app/pb_kits/playbook/pb_phone_number_input/docs/index.js +0 -1
  63. data/app/pb_kits/playbook/pb_phone_number_input/kit.schema.json +0 -8
  64. data/app/pb_kits/playbook/pb_phone_number_input/phone_number_input.rb +0 -3
  65. data/app/pb_kits/playbook/pb_phone_number_input/phone_number_input.test.js +2 -79
  66. data/app/pb_kits/playbook/pb_rich_text_editor/_rich_text_editor.tsx +1 -1
  67. data/app/pb_kits/playbook/pb_rich_text_editor/_tiptap_styles.scss +43 -262
  68. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_templates.jsx +1 -76
  69. data/app/pb_kits/playbook/pb_rich_text_editor/docs/example.yml +0 -2
  70. data/app/pb_kits/playbook/pb_rich_text_editor/docs/templates.js +75 -0
  71. data/app/pb_kits/playbook/pb_rich_text_editor/kit.schema.json +9 -18
  72. data/app/pb_kits/playbook/pb_title/docs/_playground.json +23 -72
  73. data/app/pb_kits/playbook/pb_title/docs/_playground.overrides.json +16 -80
  74. data/app/pb_kits/playbook/pb_tooltip/_tooltip.scss +102 -133
  75. data/app/pb_kits/playbook/pb_tooltip/_tooltip.tsx +41 -54
  76. data/app/pb_kits/playbook/pb_tooltip/tooltip.test.jsx +2 -60
  77. data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_react_hook.jsx +2 -2
  78. data/dist/chunks/{_pb_line_graph-BgsTI0CL.js → _pb_line_graph-D7f-RfJJ.js} +1 -1
  79. data/dist/chunks/_typeahead-DO5eU-VL.js +1 -0
  80. data/dist/chunks/{globalProps-DOB47YGB.js → globalProps-BwwZkfTI.js} +1 -1
  81. data/dist/chunks/{lib-BzglXly2.js → lib-Ch18RlJa.js} +2 -2
  82. data/dist/chunks/vendor.js +3 -3
  83. data/dist/menu.yml +2 -1
  84. data/dist/playbook-rails-react-bindings.js +1 -1
  85. data/dist/playbook-rails.js +1 -1
  86. data/dist/playbook.css +1 -1
  87. data/lib/playbook/version.rb +2 -2
  88. metadata +11 -23
  89. data/app/pb_kits/playbook/pb_advanced_table/Utilities/ColumnLayoutHelper.ts +0 -123
  90. data/app/pb_kits/playbook/pb_advanced_table/docs/advanced_table_mock_data_inline_loading_empty_children.json +0 -41
  91. data/app/pb_kits/playbook/pb_date_range_inline/docs/_playground.overrides.json +0 -57
  92. data/app/pb_kits/playbook/pb_date_range_stacked/docs/_playground.overrides.json +0 -38
  93. data/app/pb_kits/playbook/pb_distribution_bar/docs/_playground.overrides.json +0 -45
  94. data/app/pb_kits/playbook/pb_empty_state/docs/_playground.overrides.json +0 -79
  95. data/app/pb_kits/playbook/pb_file_upload/docs/_playground.overrides.json +0 -99
  96. data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_show_placeholder.html.erb +0 -5
  97. data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_show_placeholder.jsx +0 -14
  98. data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_show_placeholder.md +0 -3
  99. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_rails_default.html.erb +0 -1
  100. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_rails_default.md +0 -12
  101. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_rails_simple.html.erb +0 -9
  102. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_rails_simple.md +0 -8
  103. data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor.html.erb +0 -162
  104. data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor.rb +0 -71
  105. data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor_rails.js +0 -202
  106. data/dist/chunks/_typeahead-D2TWdJTn.js +0 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e4c7d8db60d8c02dea905e6e651b4fa36a82ef629066a79701101efdeb02a997
4
- data.tar.gz: 22c87f688bdc909c17934224b81fc142eff8354f611e47b8ec9a83ad86e25d26
3
+ metadata.gz: 1df511d9cea220056ca66936b64ebebb36c51334bcfaa7fc8f3a77d97625b05d
4
+ data.tar.gz: a34dd71d6896b5cd3d2c2c46dcece4c046072b584d7879b6ee8ddc48378eaf1d
5
5
  SHA512:
6
- metadata.gz: 1a75b42f17664f96dadd39551724b2cf1ae8836490988a5df9aaf1dc52a257367aed7243323ed86ccda5e68de4166662743ceaea02bfc33efa02437dacd7f981
7
- data.tar.gz: a0d86d348851cbb969932187c7a5f4a51f8ad17fc817771469c25538499e436496eb0407b495a3f1498f951c043a6d0fb67be1e10d9fca622b7c361ee6d48721
6
+ metadata.gz: f8cd336c91eb7498940880a19bafc7d49b16c36e4a777e547dc26dcb59e9d6b9bf527ef1763563a313fe7f4b2801b447d7f2b0b540baf830a6fa62589d34d034
7
+ data.tar.gz: 4f9dcad612095338451775807e0dda91a34f834f5d7153dfa08d016b56cbe53fbd24114f39a18eb19b449cc49530f053d252e75b774f5ab2cf417664a424e125
@@ -5,7 +5,6 @@ import { flexRender, Row, Cell } from "@tanstack/react-table"
5
5
  import { GenericObject } from "../../types"
6
6
  import { isChrome } from "../Utilities/BrowserCheck"
7
7
  import { findColumnDefByAccessor } from "../Utilities/ColumnStylingHelper"
8
- import { playbookColumnLayoutStylesFromMeta } from "../Utilities/ColumnLayoutHelper"
9
8
  import { getRowColorClass, shouldShowLoadingIndicator } from "../Utilities/RowUtils"
10
9
 
11
10
  import LoadingInline from "../../pb_loading_inline/_loading_inline"
@@ -95,7 +94,6 @@ const TableCellRenderer = ({
95
94
  )}
96
95
  key={`${cell.id}-data`}
97
96
  style={{
98
- ...playbookColumnLayoutStylesFromMeta(column.columnDef),
99
97
  left: isPinnedLeft
100
98
  ? i === 1 // Accounting for set min-width for first column
101
99
  ? '180px'
@@ -16,7 +16,6 @@ import { SortIconButton } from "./SortIconButton"
16
16
  import { ToggleIconButton } from "./ToggleIconButton"
17
17
  import { displayIcon } from "../Utilities/IconHelpers"
18
18
  import { findColumnDefByAccessor } from "../Utilities/ColumnStylingHelper"
19
- import { playbookColumnLayoutStylesFromMeta } from "../Utilities/ColumnLayoutHelper"
20
19
  import { updateExpandAndCollapseState } from "../Utilities/ExpansionControlHelpers"
21
20
 
22
21
  import { isChrome } from "../Utilities/BrowserCheck"
@@ -199,7 +198,6 @@ const isToggleExpansionEnabled =
199
198
  id={cellId}
200
199
  key={`${header?.id}-header`}
201
200
  style={{
202
- ...playbookColumnLayoutStylesFromMeta(header?.column?.columnDef),
203
201
  backgroundColor: headerBackgroundColor,
204
202
  color: headerFontColor,
205
203
  left: isPinnedLeft
@@ -19,7 +19,6 @@ import { LoadingCell } from "../Components/LoadingCell"
19
19
  import { renderCollapsibleTrail } from "../Components/CollapsibleTrail"
20
20
 
21
21
  import AdvancedTableContext from "../Context/AdvancedTableContext"
22
- import { playbookColumnLayoutStylesFromMeta } from "../Utilities/ColumnLayoutHelper"
23
22
 
24
23
  type VirtualizedTableViewProps = {
25
24
  collapsibleTrail?: boolean
@@ -225,10 +224,7 @@ export const VirtualizedTableView = ({
225
224
  isLastCell && 'last-cell',
226
225
  )}
227
226
  key={`${cell.id}-data`}
228
- style={{
229
- ...playbookColumnLayoutStylesFromMeta(cell.column.columnDef),
230
- width: cellWidth,
231
- }}
227
+ style={{ width: cellWidth }}
232
228
  >
233
229
  {collapsibleTrail && i === 0 && row.depth > 0 && renderCollapsibleTrail(row.depth)}
234
230
  <span id={`${cell.id}-span`}>
@@ -12,10 +12,6 @@ import {
12
12
  import { GenericObject } from "../../types";
13
13
  import { createColumnHelper } from "@tanstack/react-table";
14
14
  import { createCellFunction } from "../Utilities/CellRendererUtils";
15
- import {
16
- buildPlaybookColumnLayoutStyles,
17
- buildTanStackSizingFromColumn,
18
- } from "../Utilities/ColumnLayoutHelper";
19
15
  import { getParentOnlySortedRowModel } from "../Utilities/RowModelUtils";
20
16
 
21
17
  interface UseTableStateProps {
@@ -109,31 +105,11 @@ export function useTableState({
109
105
  columns: buildColumns(column.columns, false),
110
106
  };
111
107
  }
112
- const tanStackSizing = buildTanStackSizingFromColumn(column);
113
- const layoutStyles = buildPlaybookColumnLayoutStyles(column, tanStackSizing);
114
- const userMeta =
115
- column.meta &&
116
- typeof column.meta === "object" &&
117
- !Array.isArray(column.meta)
118
- ? column.meta
119
- : {};
120
- const hasLayoutStyles =
121
- layoutStyles.width !== undefined ||
122
- layoutStyles.minWidth !== undefined ||
123
- layoutStyles.maxWidth !== undefined;
124
-
125
108
  // Define the base column structure
126
109
  const columnStructure = {
127
110
  ...columnHelper.accessor(column.accessor, {
128
111
  header: column.header ?? column.label ?? "",
129
112
  enableSorting: isFirstColumn || column.enableSort === true,
130
- ...tanStackSizing,
131
- meta: {
132
- ...userMeta,
133
- ...(hasLayoutStyles
134
- ? { playbookColumnLayoutStyles: layoutStyles }
135
- : {}),
136
- },
137
113
  }),
138
114
  };
139
115
 
@@ -774,82 +774,6 @@ test("columnStyling.cellPadding sets cell padding", () => {
774
774
  expect(firstEnrollmentCell).toHaveClass('p_none')
775
775
  });
776
776
 
777
- test("columnStyling minWidth, width, and maxWidth apply to header and body cells", () => {
778
- const styledColumnDefs = [
779
- {
780
- accessor: "year",
781
- label: "Year",
782
- cellAccessors: ["quarter", "month", "day"],
783
- columnStyling: { minWidth: 240, width: 260, maxWidth: 400 },
784
- },
785
- {
786
- accessor: "newEnrollments",
787
- label: "New Enrollments",
788
- },
789
- {
790
- accessor: "scheduledMeetings",
791
- label: "Scheduled Meetings",
792
- },
793
- ];
794
-
795
- render(
796
- <AdvancedTable
797
- columnDefinitions={styledColumnDefs}
798
- data={{ testid: testId }}
799
- tableData={MOCK_DATA}
800
- />
801
- );
802
-
803
- const yearHeader = screen.getByText("Year").closest("th");
804
- expect(yearHeader).toHaveStyle({ minWidth: "240px", width: "260px", maxWidth: "400px" });
805
-
806
- const yearCell = screen.getAllByText("2021")[0].closest("td");
807
- expect(yearCell).toHaveStyle({ minWidth: "240px", width: "260px", maxWidth: "400px" });
808
- });
809
-
810
- test("columnDefinitions size, minSize, and maxSize apply layout styles", () => {
811
- const styledColumnDefs = [
812
- {
813
- accessor: "year",
814
- label: "Year",
815
- cellAccessors: ["quarter", "month", "day"],
816
- },
817
- {
818
- accessor: "newEnrollments",
819
- label: "New Enrollments",
820
- size: 180,
821
- minSize: 160,
822
- maxSize: 320,
823
- },
824
- {
825
- accessor: "scheduledMeetings",
826
- label: "Scheduled Meetings",
827
- },
828
- ];
829
-
830
- render(
831
- <AdvancedTable
832
- columnDefinitions={styledColumnDefs}
833
- data={{ testid: testId }}
834
- tableData={MOCK_DATA}
835
- />
836
- );
837
-
838
- const enrollmentsHeader = screen.getByText("New Enrollments").closest("th");
839
- expect(enrollmentsHeader).toHaveStyle({
840
- width: "180px",
841
- minWidth: "160px",
842
- maxWidth: "320px",
843
- });
844
-
845
- const enrollmentsCell = screen.getAllByText("20")[0].closest("td");
846
- expect(enrollmentsCell).toHaveStyle({
847
- width: "180px",
848
- minWidth: "160px",
849
- maxWidth: "320px",
850
- });
851
- });
852
-
853
777
  test("columnStyling.fontColor sets cell font color", () => {
854
778
  const styledColumnDefs = [
855
779
  {
@@ -10,8 +10,6 @@ const AdvancedTableColumnStyling = (props) => {
10
10
  accessor: "year",
11
11
  label: "Year",
12
12
  cellAccessors: ["quarter", "month", "day"],
13
- // Keeps the hierarchy column narrow and stable when rows expand (see kit docs).
14
- columnStyling: { minWidth: 108, width: 124, maxWidth: 168 },
15
13
  },
16
14
  {
17
15
  accessor: "newEnrollments",
@@ -6,14 +6,4 @@ The `columnStyling` prop is an optional item that can be used within `columnDefi
6
6
 
7
7
  3) `fontColor`: This will allow you to control the font color for a given column.
8
8
 
9
- 4) **Column width (layout stability)** — optional keys on `columnStyling` (numbers are treated as **pixels**; you may also use CSS length strings such as `"12rem"` or `"200px"`):
10
-
11
- - `minWidth`: minimum width for the column’s header and body cells (helps prevent horizontal “jump” when row content or expansion depth changes on tables using fixed layout).
12
- - `width`: preferred column width.
13
- - `maxWidth`: maximum column width.
14
-
15
- The live example below narrows the **Year** column (`minWidth` / `width` / `maxWidth`) so the first column stays compact while leaving room for expand and sort controls.
16
-
17
- The same sizing can be expressed with TanStack `ColumnDef` fields on each column definition object (merged into the underlying table model): `size` (width), `minSize`, and `maxSize` (numbers, pixels). If both are present for the same axis, **`columnStyling` string values take precedence**; otherwise `columnStyling` numeric/string values override TanStack numbers when only one source sets that axis. **Grouped columns:** apply width controls on **leaf** column definitions (the columns that have an `accessor`).
18
-
19
9
  `columnStyling` can be used within the columnDefinition of all the columns or some of them, as shown. Each column has its own individual control in this way.
@@ -9,21 +9,7 @@ import ListItem from "../../pb_list/_list_item"
9
9
  import PbReactPopover from "../../pb_popover/_popover"
10
10
  import SectionSeparator from "../../pb_section_separator/_section_separator"
11
11
  import StarRating from "../../pb_star_rating/_star_rating"
12
-
13
- const COMPOSITION_MOCK_DATA = [
14
- { id: "1", year: "2015", newEnrollments: "12", scheduledMeetings: "40", attendanceRate: "62%", classCompletionRate: "28%" },
15
- { id: "2", year: "2016", newEnrollments: "88", scheduledMeetings: "12", attendanceRate: "71%", classCompletionRate: "55%" },
16
- { id: "3", year: "2017", newEnrollments: "34", scheduledMeetings: "67", attendanceRate: "58%", classCompletionRate: "41%" },
17
- { id: "4", year: "2018", newEnrollments: "05", scheduledMeetings: "91", attendanceRate: "44%", classCompletionRate: "73%" },
18
- { id: "5", year: "2019", newEnrollments: "61", scheduledMeetings: "19", attendanceRate: "83%", classCompletionRate: "36%" },
19
- { id: "6", year: "2020", newEnrollments: "19", scheduledMeetings: "54", attendanceRate: "67%", classCompletionRate: "62%" },
20
- { id: "7", year: "2021", newEnrollments: "73", scheduledMeetings: "08", attendanceRate: "52%", classCompletionRate: "49%" },
21
- { id: "8", year: "2022", newEnrollments: "50", scheduledMeetings: "50", attendanceRate: "75%", classCompletionRate: "45%" },
22
- { id: "9", year: "2023", newEnrollments: "95", scheduledMeetings: "03", attendanceRate: "69%", classCompletionRate: "81%" },
23
- { id: "10", year: "2024", newEnrollments: "27", scheduledMeetings: "76", attendanceRate: "91%", classCompletionRate: "22%" },
24
- { id: "11", year: "2025", newEnrollments: "41", scheduledMeetings: "33", attendanceRate: "48%", classCompletionRate: "94%" },
25
- { id: "12", year: "2026", newEnrollments: "66", scheduledMeetings: "66", attendanceRate: "55%", classCompletionRate: "58%" },
26
- ]
12
+ import COMPOSITION_MOCK_DATA from "./advanced_table_grouped_headers_composition_mock_data.json"
27
13
 
28
14
  const LEAF_COUNT = "newEnrollments"
29
15
  const LEAF_SCHEDULED = "scheduledMeetings"
@@ -1,6 +1,6 @@
1
1
  import React from "react"
2
2
  import AdvancedTable from '../_advanced_table'
3
- import INFINITE_SCROLL_MOCK_DATA from "./advanced_table_mock_data_infinite_scroll.json"
3
+ import MOCK_DATA from "./advanced_table_mock_data_infinite_scroll.json"
4
4
 
5
5
  const AdvancedTableInfiniteScroll = (props) => {
6
6
  const columnDefinitions = [
@@ -39,7 +39,7 @@ const AdvancedTableInfiniteScroll = (props) => {
39
39
  <div>
40
40
  <AdvancedTable
41
41
  columnDefinitions={columnDefinitions}
42
- tableData={INFINITE_SCROLL_MOCK_DATA}
42
+ tableData={MOCK_DATA}
43
43
  virtualizedRows
44
44
  {...props}
45
45
  />
@@ -1,8 +1,8 @@
1
1
  import React from "react"
2
2
  import AdvancedTable from '../../pb_advanced_table/_advanced_table'
3
3
  import Caption from '../../pb_caption/_caption'
4
- import MOCK_DATA_INLINE_LOADING from "./advanced_table_mock_data_inline_loading.json"
5
- import MOCK_DATA_INLINE_LOADING_EMPTY_CHILDREN from "./advanced_table_mock_data_inline_loading_empty_children.json"
4
+ import { MOCK_DATA_INLINE_LOADING } from "./_mock_data_inline_loading"
5
+ import { MOCK_DATA_INLINE_LOADING_EMPTY_CHILDREN } from "./_mock_data_inline_loading_empty_children"
6
6
 
7
7
  const AdvancedTableInlineRowLoading = (props) => {
8
8
  const columnDefinitions = [
@@ -1,6 +1,6 @@
1
1
  import React, { useState } from "react"
2
2
  import AdvancedTable from '../_advanced_table'
3
- import MOCK_DATA_WITH_ID from "./advanced_table_mock_data_with_id.json"
3
+ import MOCK_DATA from "./advanced_table_mock_data_with_id.json"
4
4
 
5
5
  const AdvancedTableRowPinning = (props) => {
6
6
  const columnDefinitions = [
@@ -43,7 +43,7 @@ const AdvancedTableRowPinning = (props) => {
43
43
  columnDefinitions={columnDefinitions}
44
44
  maxHeight="xs"
45
45
  pinnedRows={{value: pinnedRows, onChange: setPinnedRows}}
46
- tableData={MOCK_DATA_WITH_ID}
46
+ tableData={MOCK_DATA}
47
47
  tableProps={{sticky: true}}
48
48
  {...props}
49
49
  >
@@ -0,0 +1,200 @@
1
+ export const MOCK_DATA_INLINE_LOADING = [
2
+ {
3
+ year: "2021",
4
+ quarter: null,
5
+ month: null,
6
+ day: null,
7
+ newEnrollments: "20",
8
+ scheduledMeetings: "10",
9
+ attendanceRate: "51%",
10
+ completedClasses: "3",
11
+ classCompletionRate: "33%",
12
+ graduatedStudents: "19",
13
+ children: [],
14
+ },
15
+ {
16
+ year: "2022",
17
+ quarter: null,
18
+ month: null,
19
+ day: null,
20
+ newEnrollments: "25",
21
+ scheduledMeetings: "17",
22
+ attendanceRate: "75%",
23
+ completedClasses: "5",
24
+ classCompletionRate: "45%",
25
+ graduatedStudents: "32",
26
+ children: [
27
+ {
28
+ year: "2022",
29
+ quarter: "Q1",
30
+ month: null,
31
+ day: null,
32
+ newEnrollments: "2",
33
+ scheduledMeetings: "35",
34
+ attendanceRate: "32%",
35
+ completedClasses: "15",
36
+ classCompletionRate: "52%",
37
+ graduatedStudents: "36",
38
+ children: [
39
+ {
40
+ year: "2022",
41
+ quarter: "Q1",
42
+ month: "January",
43
+ day: null,
44
+ newEnrollments: "16",
45
+ scheduledMeetings: "20",
46
+ attendanceRate: "11%",
47
+ completedClasses: "13",
48
+ classCompletionRate: "47%",
49
+ graduatedStudents: "28",
50
+ children: [
51
+ {
52
+ year: "2022",
53
+ quarter: "Q1",
54
+ month: "January",
55
+ day: "15",
56
+ newEnrollments: "34",
57
+ scheduledMeetings: "28",
58
+ attendanceRate: "97%",
59
+ completedClasses: "20",
60
+ classCompletionRate: "15%",
61
+ graduatedStudents: "17",
62
+ },
63
+ {
64
+ year: "2022",
65
+ quarter: "Q1",
66
+ month: "January",
67
+ day: "25",
68
+ newEnrollments: "43",
69
+ scheduledMeetings: "23",
70
+ attendanceRate: "66%",
71
+ completedClasses: "26",
72
+ classCompletionRate: "47%",
73
+ graduatedStudents: "9",
74
+ },
75
+ ],
76
+ },
77
+ {
78
+ year: "2022",
79
+ quarter: "Q1",
80
+ month: "May",
81
+ day: null,
82
+ newEnrollments: "20",
83
+ scheduledMeetings: "41",
84
+ attendanceRate: "95%",
85
+ completedClasses: "26",
86
+ classCompletionRate: "83%",
87
+ graduatedStudents: "43",
88
+ children: [
89
+ {
90
+ year: "2011",
91
+ quarter: "Q1",
92
+ month: "May",
93
+ day: "2",
94
+ newEnrollments: "19",
95
+ scheduledMeetings: "35",
96
+ attendanceRate: "69%",
97
+ completedClasses: "8",
98
+ classCompletionRate: "75%",
99
+ graduatedStudents: "23",
100
+ },
101
+ ],
102
+ },
103
+ ],
104
+ },
105
+ ],
106
+ },
107
+ {
108
+ year: "2023",
109
+ quarter: null,
110
+ month: null,
111
+ day: null,
112
+ newEnrollments: "10",
113
+ scheduledMeetings: "15",
114
+ attendanceRate: "65%",
115
+ completedClasses: "4",
116
+ classCompletionRate: "49%",
117
+ graduatedStudents: "29",
118
+ children: [
119
+ {
120
+ year: "2023",
121
+ quarter: "Q1",
122
+ month: null,
123
+ day: null,
124
+ newEnrollments: "2",
125
+ scheduledMeetings: "35",
126
+ attendanceRate: "32%",
127
+ completedClasses: "15",
128
+ classCompletionRate: "52%",
129
+ graduatedStudents: "36",
130
+ children: [
131
+ {
132
+ year: "2023",
133
+ quarter: "Q1",
134
+ month: "March",
135
+ day: null,
136
+ newEnrollments: "16",
137
+ scheduledMeetings: "20",
138
+ attendanceRate: "11%",
139
+ completedClasses: "13",
140
+ classCompletionRate: "47%",
141
+ graduatedStudents: "28",
142
+ children: [
143
+ {
144
+ year: "2023",
145
+ quarter: "Q1",
146
+ month: "March",
147
+ day: "10",
148
+ newEnrollments: "34",
149
+ scheduledMeetings: "28",
150
+ attendanceRate: "97%",
151
+ completedClasses: "20",
152
+ classCompletionRate: "15%",
153
+ graduatedStudents: "17",
154
+ },
155
+ {
156
+ year: "2023",
157
+ quarter: "Q1",
158
+ month: "March",
159
+ day: "11",
160
+ newEnrollments: "43",
161
+ scheduledMeetings: "23",
162
+ attendanceRate: "66%",
163
+ completedClasses: "26",
164
+ classCompletionRate: "47%",
165
+ graduatedStudents: "9",
166
+ },
167
+ ],
168
+ },
169
+ {
170
+ year: "2023",
171
+ quarter: "Q1",
172
+ month: "April",
173
+ day: null,
174
+ newEnrollments: "20",
175
+ scheduledMeetings: "41",
176
+ attendanceRate: "95%",
177
+ completedClasses: "26",
178
+ classCompletionRate: "83%",
179
+ graduatedStudents: "43",
180
+ children: [
181
+ {
182
+ year: "2023",
183
+ quarter: "Q1",
184
+ month: "April",
185
+ day: "15",
186
+ newEnrollments: "19",
187
+ scheduledMeetings: "35",
188
+ attendanceRate: "69%",
189
+ completedClasses: "8",
190
+ classCompletionRate: "75%",
191
+ graduatedStudents: "23",
192
+ },
193
+ ],
194
+ },
195
+ ],
196
+ },
197
+ ],
198
+ },
199
+ ]
200
+
@@ -0,0 +1,42 @@
1
+ export const MOCK_DATA_INLINE_LOADING_EMPTY_CHILDREN = [
2
+ {
3
+ year: "2021",
4
+ quarter: null,
5
+ month: null,
6
+ day: null,
7
+ newEnrollments: "20",
8
+ scheduledMeetings: "10",
9
+ attendanceRate: "51%",
10
+ completedClasses: "3",
11
+ classCompletionRate: "33%",
12
+ graduatedStudents: "19",
13
+ children: [],
14
+ },
15
+ {
16
+ year: "2022",
17
+ quarter: null,
18
+ month: null,
19
+ day: null,
20
+ newEnrollments: "25",
21
+ scheduledMeetings: "17",
22
+ attendanceRate: "75%",
23
+ completedClasses: "5",
24
+ classCompletionRate: "45%",
25
+ graduatedStudents: "32",
26
+ children: [],
27
+ },
28
+ {
29
+ year: "2023",
30
+ quarter: null,
31
+ month: null,
32
+ day: null,
33
+ newEnrollments: "10",
34
+ scheduledMeetings: "15",
35
+ attendanceRate: "65%",
36
+ completedClasses: "4",
37
+ classCompletionRate: "49%",
38
+ graduatedStudents: "29",
39
+ children: [],
40
+ },
41
+ ]
42
+