@arbor-education/design-system.components 0.15.0 → 0.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.gather/skills/write-stories/SKILL.md +207 -271
- package/.storybook/preview.ts +5 -0
- package/CHANGELOG.md +17 -0
- package/README.md +8 -0
- package/component-library.md +144 -13
- package/dist/components/articleCard/ArticleCard.stories.d.ts +137 -11
- package/dist/components/articleCard/ArticleCard.stories.d.ts.map +1 -1
- package/dist/components/articleCard/ArticleCard.stories.js +358 -91
- package/dist/components/articleCard/ArticleCard.stories.js.map +1 -1
- package/dist/components/avatar/Avatar.stories.d.ts +6 -6
- package/dist/components/avatar/Avatar.stories.d.ts.map +1 -1
- package/dist/components/avatar/Avatar.stories.js +393 -49
- package/dist/components/avatar/Avatar.stories.js.map +1 -1
- package/dist/components/avatarGroup/AvatarGroup.stories.d.ts +9 -7
- package/dist/components/avatarGroup/AvatarGroup.stories.d.ts.map +1 -1
- package/dist/components/avatarGroup/AvatarGroup.stories.js +688 -65
- package/dist/components/avatarGroup/AvatarGroup.stories.js.map +1 -1
- package/dist/components/banner/Banner.stories.d.ts.map +1 -1
- package/dist/components/banner/Banner.stories.js +7 -3
- package/dist/components/banner/Banner.stories.js.map +1 -1
- package/dist/components/card/Card.stories.d.ts +105 -4
- package/dist/components/card/Card.stories.d.ts.map +1 -1
- package/dist/components/card/Card.stories.js +336 -18
- package/dist/components/card/Card.stories.js.map +1 -1
- package/dist/components/combobox/Combobox.stories.d.ts +134 -21
- package/dist/components/combobox/Combobox.stories.d.ts.map +1 -1
- package/dist/components/combobox/Combobox.stories.js +676 -175
- package/dist/components/combobox/Combobox.stories.js.map +1 -1
- package/dist/components/datePicker/DatePicker.stories.d.ts +119 -27
- package/dist/components/datePicker/DatePicker.stories.d.ts.map +1 -1
- package/dist/components/datePicker/DatePicker.stories.js +575 -47
- package/dist/components/datePicker/DatePicker.stories.js.map +1 -1
- package/dist/components/dateTimePicker/DateTimePicker.stories.d.ts +155 -39
- package/dist/components/dateTimePicker/DateTimePicker.stories.d.ts.map +1 -1
- package/dist/components/dateTimePicker/DateTimePicker.stories.js +674 -103
- package/dist/components/dateTimePicker/DateTimePicker.stories.js.map +1 -1
- package/dist/components/editableText/EditableText.stories.d.ts +53 -12
- package/dist/components/editableText/EditableText.stories.d.ts.map +1 -1
- package/dist/components/editableText/EditableText.stories.js +401 -64
- package/dist/components/editableText/EditableText.stories.js.map +1 -1
- package/dist/components/formField/FormField.d.ts +4 -0
- package/dist/components/formField/FormField.d.ts.map +1 -1
- package/dist/components/formField/FormField.js +2 -1
- package/dist/components/formField/FormField.js.map +1 -1
- package/dist/components/formField/FormField.test.js +5 -0
- package/dist/components/formField/FormField.test.js.map +1 -1
- package/dist/components/formField/fieldset/Fieldset.stories.d.ts +56 -4
- package/dist/components/formField/fieldset/Fieldset.stories.d.ts.map +1 -1
- package/dist/components/formField/fieldset/Fieldset.stories.js +534 -28
- package/dist/components/formField/fieldset/Fieldset.stories.js.map +1 -1
- package/dist/components/formField/inputs/checkbox/CheckboxGroup.d.ts +3 -1
- package/dist/components/formField/inputs/checkbox/CheckboxGroup.d.ts.map +1 -1
- package/dist/components/formField/inputs/checkbox/CheckboxInput.js +1 -1
- package/dist/components/formField/inputs/checkbox/CheckboxInput.js.map +1 -1
- package/dist/components/formField/inputs/colourPickerDropdown/ColourPickerDropdown.stories.d.ts +95 -1
- package/dist/components/formField/inputs/colourPickerDropdown/ColourPickerDropdown.stories.d.ts.map +1 -1
- package/dist/components/formField/inputs/colourPickerDropdown/ColourPickerDropdown.stories.js +386 -9
- package/dist/components/formField/inputs/colourPickerDropdown/ColourPickerDropdown.stories.js.map +1 -1
- package/dist/components/formField/inputs/radio/RadioButtonGroup.d.ts +6 -2
- package/dist/components/formField/inputs/radio/RadioButtonGroup.d.ts.map +1 -1
- package/dist/components/formField/inputs/radio/RadioButtonGroup.js.map +1 -1
- package/dist/components/formField/inputs/radio/RadioButtonInput.stories.d.ts.map +1 -1
- package/dist/components/formField/inputs/radio/RadioButtonInput.stories.js +61 -49
- package/dist/components/formField/inputs/radio/RadioButtonInput.stories.js.map +1 -1
- package/dist/components/formField/inputs/selectDropdown/SelectDropdown.stories.d.ts +188 -166
- package/dist/components/formField/inputs/selectDropdown/SelectDropdown.stories.d.ts.map +1 -1
- package/dist/components/formField/inputs/selectDropdown/SelectDropdown.stories.js +821 -160
- package/dist/components/formField/inputs/selectDropdown/SelectDropdown.stories.js.map +1 -1
- package/dist/components/formField/inputs/time/TimeInput.stories.d.ts +176 -22
- package/dist/components/formField/inputs/time/TimeInput.stories.d.ts.map +1 -1
- package/dist/components/formField/inputs/time/TimeInput.stories.js +851 -92
- package/dist/components/formField/inputs/time/TimeInput.stories.js.map +1 -1
- package/dist/components/formField/label/Label.stories.d.ts +54 -5
- package/dist/components/formField/label/Label.stories.d.ts.map +1 -1
- package/dist/components/formField/label/Label.stories.js +238 -4
- package/dist/components/formField/label/Label.stories.js.map +1 -1
- package/dist/components/icoText/IcoText.stories.d.ts +32 -6
- package/dist/components/icoText/IcoText.stories.d.ts.map +1 -1
- package/dist/components/icoText/IcoText.stories.js +309 -14
- package/dist/components/icoText/IcoText.stories.js.map +1 -1
- package/dist/components/kpiCard/KPICard.stories.d.ts +100 -2
- package/dist/components/kpiCard/KPICard.stories.d.ts.map +1 -1
- package/dist/components/kpiCard/KPICard.stories.js +354 -10
- package/dist/components/kpiCard/KPICard.stories.js.map +1 -1
- package/dist/components/kvpList/KVPList.stories.d.ts +57 -4
- package/dist/components/kvpList/KVPList.stories.d.ts.map +1 -1
- package/dist/components/kvpList/KVPList.stories.js +403 -10
- package/dist/components/kvpList/KVPList.stories.js.map +1 -1
- package/dist/components/modal/Modal.stories.d.ts +113 -9
- package/dist/components/modal/Modal.stories.d.ts.map +1 -1
- package/dist/components/modal/Modal.stories.js +633 -13
- package/dist/components/modal/Modal.stories.js.map +1 -1
- package/dist/components/modal/modalManager/ModalManager.stories.d.ts +34 -10
- package/dist/components/modal/modalManager/ModalManager.stories.d.ts.map +1 -1
- package/dist/components/modal/modalManager/ModalManager.stories.js +463 -85
- package/dist/components/modal/modalManager/ModalManager.stories.js.map +1 -1
- package/dist/components/pill/Pill.d.ts.map +1 -1
- package/dist/components/pill/Pill.js +1 -1
- package/dist/components/pill/Pill.js.map +1 -1
- package/dist/components/pill/Pill.stories.d.ts.map +1 -1
- package/dist/components/pill/Pill.stories.js +11 -13
- package/dist/components/pill/Pill.stories.js.map +1 -1
- package/dist/components/row/Row.stories.d.ts +1 -2
- package/dist/components/row/Row.stories.d.ts.map +1 -1
- package/dist/components/row/Row.stories.js +360 -50
- package/dist/components/row/Row.stories.js.map +1 -1
- package/dist/components/searchBar/SearchBar.stories.d.ts +52 -4
- package/dist/components/searchBar/SearchBar.stories.d.ts.map +1 -1
- package/dist/components/searchBar/SearchBar.stories.js +428 -36
- package/dist/components/searchBar/SearchBar.stories.js.map +1 -1
- package/dist/components/section/Section.stories.d.ts +11 -41
- package/dist/components/section/Section.stories.d.ts.map +1 -1
- package/dist/components/section/Section.stories.js +494 -56
- package/dist/components/section/Section.stories.js.map +1 -1
- package/dist/components/singleUser/SingleUser.stories.d.ts +5 -4
- package/dist/components/singleUser/SingleUser.stories.d.ts.map +1 -1
- package/dist/components/singleUser/SingleUser.stories.js +303 -31
- package/dist/components/singleUser/SingleUser.stories.js.map +1 -1
- package/dist/components/slideoverManager/SlideoverManager.stories.d.ts +32 -11
- package/dist/components/slideoverManager/SlideoverManager.stories.d.ts.map +1 -1
- package/dist/components/slideoverManager/SlideoverManager.stories.js +380 -84
- package/dist/components/slideoverManager/SlideoverManager.stories.js.map +1 -1
- package/dist/components/table/DSDefaultColDef.d.ts.map +1 -1
- package/dist/components/table/DSDefaultColDef.js +4 -3
- package/dist/components/table/DSDefaultColDef.js.map +1 -1
- package/dist/components/table/Table.d.ts +6 -1
- package/dist/components/table/Table.d.ts.map +1 -1
- package/dist/components/table/Table.js +8 -3
- package/dist/components/table/Table.js.map +1 -1
- package/dist/components/table/Table.stories.d.ts +2 -0
- package/dist/components/table/Table.stories.d.ts.map +1 -1
- package/dist/components/table/Table.stories.js +357 -3
- package/dist/components/table/Table.stories.js.map +1 -1
- package/dist/components/table/TableFooter.stories.d.ts +49 -0
- package/dist/components/table/TableFooter.stories.d.ts.map +1 -0
- package/dist/components/table/TableFooter.stories.js +137 -0
- package/dist/components/table/TableFooter.stories.js.map +1 -0
- package/dist/components/table/TableHeader.stories.d.ts +93 -0
- package/dist/components/table/TableHeader.stories.d.ts.map +1 -0
- package/dist/components/table/TableHeader.stories.js +176 -0
- package/dist/components/table/TableHeader.stories.js.map +1 -0
- package/dist/components/table/cellEditors/DateCellEditor.stories.d.ts +44 -0
- package/dist/components/table/cellEditors/DateCellEditor.stories.d.ts.map +1 -0
- package/dist/components/table/cellEditors/DateCellEditor.stories.js +186 -0
- package/dist/components/table/cellEditors/DateCellEditor.stories.js.map +1 -0
- package/dist/components/table/cellRenderers/BooleanCellRenderer.stories.d.ts +40 -0
- package/dist/components/table/cellRenderers/BooleanCellRenderer.stories.d.ts.map +1 -0
- package/dist/components/table/cellRenderers/BooleanCellRenderer.stories.js +209 -0
- package/dist/components/table/cellRenderers/BooleanCellRenderer.stories.js.map +1 -0
- package/dist/components/table/cellRenderers/ButtonCellRenderer.stories.d.ts +48 -0
- package/dist/components/table/cellRenderers/ButtonCellRenderer.stories.d.ts.map +1 -0
- package/dist/components/table/cellRenderers/ButtonCellRenderer.stories.js +244 -0
- package/dist/components/table/cellRenderers/ButtonCellRenderer.stories.js.map +1 -0
- package/dist/components/table/cellRenderers/CheckboxCellRenderer.d.ts.map +1 -1
- package/dist/components/table/cellRenderers/CheckboxCellRenderer.js +3 -1
- package/dist/components/table/cellRenderers/CheckboxCellRenderer.js.map +1 -1
- package/dist/components/table/cellRenderers/CheckboxCellRenderer.stories.d.ts +64 -0
- package/dist/components/table/cellRenderers/CheckboxCellRenderer.stories.d.ts.map +1 -0
- package/dist/components/table/cellRenderers/CheckboxCellRenderer.stories.js +241 -0
- package/dist/components/table/cellRenderers/CheckboxCellRenderer.stories.js.map +1 -0
- package/dist/components/table/cellRenderers/DefaultCellRenderer.stories.d.ts +55 -0
- package/dist/components/table/cellRenderers/DefaultCellRenderer.stories.d.ts.map +1 -0
- package/dist/components/table/cellRenderers/DefaultCellRenderer.stories.js +245 -0
- package/dist/components/table/cellRenderers/DefaultCellRenderer.stories.js.map +1 -0
- package/dist/components/table/cellRenderers/InlineTextCellRenderer.stories.d.ts +67 -0
- package/dist/components/table/cellRenderers/InlineTextCellRenderer.stories.d.ts.map +1 -0
- package/dist/components/table/cellRenderers/InlineTextCellRenderer.stories.js +221 -0
- package/dist/components/table/cellRenderers/InlineTextCellRenderer.stories.js.map +1 -0
- package/dist/components/table/cellRenderers/SelectDropdownCellRenderer.stories.d.ts +75 -0
- package/dist/components/table/cellRenderers/SelectDropdownCellRenderer.stories.d.ts.map +1 -0
- package/dist/components/table/cellRenderers/SelectDropdownCellRenderer.stories.js +270 -0
- package/dist/components/table/cellRenderers/SelectDropdownCellRenderer.stories.js.map +1 -0
- package/dist/components/table/columnFilters/BooleanFilter.stories.d.ts +57 -0
- package/dist/components/table/columnFilters/BooleanFilter.stories.d.ts.map +1 -0
- package/dist/components/table/columnFilters/BooleanFilter.stories.js +198 -0
- package/dist/components/table/columnFilters/BooleanFilter.stories.js.map +1 -0
- package/dist/components/table/columnFilters/TimeFilter.stories.d.ts +58 -0
- package/dist/components/table/columnFilters/TimeFilter.stories.d.ts.map +1 -0
- package/dist/components/table/columnFilters/TimeFilter.stories.js +207 -0
- package/dist/components/table/columnFilters/TimeFilter.stories.js.map +1 -0
- package/dist/components/table/pagination/PaginationPanel.stories.d.ts +113 -0
- package/dist/components/table/pagination/PaginationPanel.stories.d.ts.map +1 -0
- package/dist/components/table/pagination/PaginationPanel.stories.js +272 -0
- package/dist/components/table/pagination/PaginationPanel.stories.js.map +1 -0
- package/dist/components/table/tableControls/TableControls.stories.d.ts +151 -0
- package/dist/components/table/tableControls/TableControls.stories.d.ts.map +1 -0
- package/dist/components/table/tableControls/TableControls.stories.js +356 -0
- package/dist/components/table/tableControls/TableControls.stories.js.map +1 -0
- package/dist/components/table/tableControls/TableSettingsDropdown.d.ts +27 -1
- package/dist/components/table/tableControls/TableSettingsDropdown.d.ts.map +1 -1
- package/dist/components/table/tableControls/TableSettingsDropdown.js +53 -26
- package/dist/components/table/tableControls/TableSettingsDropdown.js.map +1 -1
- package/dist/components/table/tableControls/TableSettingsDropdown.test.d.ts +2 -0
- package/dist/components/table/tableControls/TableSettingsDropdown.test.d.ts.map +1 -0
- package/dist/components/table/tableControls/TableSettingsDropdown.test.js +178 -0
- package/dist/components/table/tableControls/TableSettingsDropdown.test.js.map +1 -0
- package/dist/components/tabs/Tabs.stories.d.ts +22 -4
- package/dist/components/tabs/Tabs.stories.d.ts.map +1 -1
- package/dist/components/tabs/Tabs.stories.js +398 -22
- package/dist/components/tabs/Tabs.stories.js.map +1 -1
- package/dist/components/tabs/TabsItem.stories.d.ts +54 -1
- package/dist/components/tabs/TabsItem.stories.d.ts.map +1 -1
- package/dist/components/tabs/TabsItem.stories.js +61 -9
- package/dist/components/tabs/TabsItem.stories.js.map +1 -1
- package/dist/components/toast/Toast.stories.d.ts +103 -10
- package/dist/components/toast/Toast.stories.d.ts.map +1 -1
- package/dist/components/toast/Toast.stories.js +409 -47
- package/dist/components/toast/Toast.stories.js.map +1 -1
- package/dist/components/toggle/Toggle.stories.d.ts +61 -46
- package/dist/components/toggle/Toggle.stories.d.ts.map +1 -1
- package/dist/components/toggle/Toggle.stories.js +311 -122
- package/dist/components/toggle/Toggle.stories.js.map +1 -1
- package/dist/components/tooltip/Tooltip.stories.d.ts +78 -6
- package/dist/components/tooltip/Tooltip.stories.d.ts.map +1 -1
- package/dist/components/tooltip/Tooltip.stories.js +413 -7
- package/dist/components/tooltip/Tooltip.stories.js.map +1 -1
- package/dist/components/tooltip/TooltipWrapper.stories.d.ts +71 -7
- package/dist/components/tooltip/TooltipWrapper.stories.d.ts.map +1 -1
- package/dist/components/tooltip/TooltipWrapper.stories.js +238 -10
- package/dist/components/tooltip/TooltipWrapper.stories.js.map +1 -1
- package/dist/index.css +8 -0
- package/dist/index.css.map +1 -1
- package/dist/utils/PopupParentContext.stories.d.ts +17 -0
- package/dist/utils/PopupParentContext.stories.d.ts.map +1 -0
- package/dist/utils/PopupParentContext.stories.js +266 -0
- package/dist/utils/PopupParentContext.stories.js.map +1 -0
- package/dist/utils/getDefaultPopupParent.d.ts.map +1 -1
- package/dist/utils/getDefaultPopupParent.js +6 -0
- package/dist/utils/getDefaultPopupParent.js.map +1 -1
- package/package.json +1 -1
- package/src/components/articleCard/ArticleCard.stories.tsx +524 -111
- package/src/components/avatar/Avatar.stories.tsx +504 -59
- package/src/components/avatarGroup/AvatarGroup.stories.tsx +977 -175
- package/src/components/banner/Banner.stories.tsx +7 -3
- package/src/components/card/Card.stories.tsx +466 -36
- package/src/components/combobox/Combobox.stories.tsx +867 -260
- package/src/components/datePicker/DatePicker.stories.tsx +777 -60
- package/src/components/dateTimePicker/DateTimePicker.stories.tsx +910 -132
- package/src/components/editableText/EditableText.stories.tsx +567 -91
- package/src/components/formField/FormField.test.tsx +6 -0
- package/src/components/formField/FormField.tsx +5 -0
- package/src/components/formField/fieldset/Fieldset.stories.tsx +761 -51
- package/src/components/formField/inputs/checkbox/CheckboxGroup.tsx +1 -1
- package/src/components/formField/inputs/checkbox/CheckboxInput.tsx +1 -1
- package/src/components/formField/inputs/colourPickerDropdown/ColourPickerDropdown.stories.tsx +504 -11
- package/src/components/formField/inputs/radio/RadioButtonGroup.tsx +17 -4
- package/src/components/formField/inputs/radio/RadioButtonInput.stories.tsx +71 -59
- package/src/components/formField/inputs/selectDropdown/SelectDropdown.stories.tsx +1079 -168
- package/src/components/formField/inputs/time/TimeInput.stories.tsx +1140 -104
- package/src/components/formField/label/Label.stories.tsx +317 -8
- package/src/components/icoText/IcoText.stories.tsx +442 -31
- package/src/components/kpiCard/KPICard.stories.tsx +475 -30
- package/src/components/kvpList/KVPList.stories.tsx +593 -26
- package/src/components/modal/Modal.stories.tsx +963 -26
- package/src/components/modal/modalManager/ModalManager.stories.tsx +612 -454
- package/src/components/pill/Pill.stories.tsx +11 -13
- package/src/components/pill/Pill.tsx +1 -0
- package/src/components/row/Row.stories.tsx +474 -58
- package/src/components/searchBar/SearchBar.stories.tsx +570 -38
- package/src/components/section/Section.stories.tsx +723 -70
- package/src/components/singleUser/SingleUser.stories.tsx +393 -34
- package/src/components/slideoverManager/SlideoverManager.stories.tsx +572 -342
- package/src/components/table/DSDefaultColDef.ts +25 -5
- package/src/components/table/Table.stories.tsx +411 -3
- package/src/components/table/Table.tsx +9 -2
- package/src/components/table/TableFooter.stories.tsx +196 -0
- package/src/components/table/TableHeader.stories.tsx +251 -0
- package/src/components/table/cellEditors/DateCellEditor.stories.tsx +245 -0
- package/src/components/table/cellRenderers/BooleanCellRenderer.stories.tsx +278 -0
- package/src/components/table/cellRenderers/ButtonCellRenderer.stories.tsx +333 -0
- package/src/components/table/cellRenderers/CheckboxCellRenderer.stories.tsx +337 -0
- package/src/components/table/cellRenderers/CheckboxCellRenderer.tsx +5 -1
- package/src/components/table/cellRenderers/DefaultCellRenderer.stories.tsx +342 -0
- package/src/components/table/cellRenderers/InlineTextCellRenderer.stories.tsx +292 -0
- package/src/components/table/cellRenderers/SelectDropdownCellRenderer.stories.tsx +369 -0
- package/src/components/table/columnFilters/BooleanFilter.stories.tsx +268 -0
- package/src/components/table/columnFilters/TimeFilter.stories.tsx +281 -0
- package/src/components/table/pagination/PaginationPanel.stories.tsx +327 -0
- package/src/components/table/tableControls/TableControls.stories.tsx +415 -0
- package/src/components/table/tableControls/TableSettingsDropdown.test.tsx +207 -0
- package/src/components/table/tableControls/TableSettingsDropdown.tsx +103 -39
- package/src/components/tabs/Tabs.stories.tsx +540 -60
- package/src/components/tabs/TabsItem.stories.tsx +82 -8
- package/src/components/toast/Toast.stories.tsx +539 -77
- package/src/components/toggle/Toggle.stories.tsx +371 -135
- package/src/components/tooltip/Tooltip.stories.tsx +606 -15
- package/src/components/tooltip/TooltipWrapper.stories.tsx +348 -12
- package/src/docs/Contributing.mdx +241 -0
- package/src/docs/UsingComponents.mdx +93 -0
- package/src/docs/Welcome.mdx +68 -0
- package/src/global.scss +7 -0
- package/src/utils/PopupParentContext.stories.tsx +367 -0
- package/src/utils/getDefaultPopupParent.ts +6 -0
- package/.ralph/storybook-upgrade/knowledge.md +0 -308
- package/.ralph/storybook-upgrade/prd.json +0 -777
- package/.ralph/storybook-upgrade/progress.md +0 -342
- package/src/components/table/TableWIP.mdx +0 -3
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { Controls, Heading as DocHeading, Markdown, Primary as DocPrimary, Stories, Subtitle, Title, } from '@storybook/addon-docs/blocks';
|
|
4
|
+
import { fn } from 'storybook/test';
|
|
5
|
+
import { TimeFilter, doesTimeFilterPass } from './TimeFilter/TimeFilter';
|
|
6
|
+
import { Table } from '../../table/Table';
|
|
7
|
+
// ---------------------------------------------------------------------------
|
|
8
|
+
// Docs page content
|
|
9
|
+
// ---------------------------------------------------------------------------
|
|
10
|
+
const DESCRIPTION_INTRO = [
|
|
11
|
+
'`TimeFilter` is an AG Grid column filter component for time-string columns.',
|
|
12
|
+
'It renders a filter-type selector (**Before**, **After**, **At**) and a time input,',
|
|
13
|
+
'then calls `onModelChange` with a `{ filterType, pivot }` model when either changes.',
|
|
14
|
+
'',
|
|
15
|
+
'Register it via the AG Grid `filter` column definition property alongside `doesTimeFilterPass`.',
|
|
16
|
+
].join('\n');
|
|
17
|
+
const USAGE_GUIDANCE = [
|
|
18
|
+
'### When to use',
|
|
19
|
+
'',
|
|
20
|
+
'- On columns containing time strings (e.g. `"09:30"`, `"14:45"`) that need a time-based filter',
|
|
21
|
+
'- When users need to find rows before, after, or at a specific time',
|
|
22
|
+
'',
|
|
23
|
+
'---',
|
|
24
|
+
'',
|
|
25
|
+
'### Registration',
|
|
26
|
+
'',
|
|
27
|
+
'```tsx',
|
|
28
|
+
"import { TimeFilter, doesTimeFilterPass } from '@arbor-education/design-system.components';",
|
|
29
|
+
'',
|
|
30
|
+
'const colDefs = [',
|
|
31
|
+
' {',
|
|
32
|
+
" field: 'startTime',",
|
|
33
|
+
' filter: { component: TimeFilter, doesFilterPass: doesTimeFilterPass },',
|
|
34
|
+
' },',
|
|
35
|
+
'];',
|
|
36
|
+
'```',
|
|
37
|
+
'',
|
|
38
|
+
'---',
|
|
39
|
+
'',
|
|
40
|
+
'### Filter model',
|
|
41
|
+
'',
|
|
42
|
+
'```ts',
|
|
43
|
+
'type TimeFilterModel = {',
|
|
44
|
+
" filterType: 'before' | 'after' | 'equal';",
|
|
45
|
+
' pivot: string; // HH:mm format, e.g. "09:30"',
|
|
46
|
+
'};',
|
|
47
|
+
'```',
|
|
48
|
+
'',
|
|
49
|
+
'---',
|
|
50
|
+
'',
|
|
51
|
+
'### `doesTimeFilterPass`',
|
|
52
|
+
'',
|
|
53
|
+
'`doesTimeFilterPass` is the companion filter function. Import it alongside `TimeFilter` and pass',
|
|
54
|
+
'it to `doesFilterPass` in your column definition. It compares the cell value (time string or `Date`)',
|
|
55
|
+
'against the `pivot` using the selected `filterType`.',
|
|
56
|
+
].join('\n');
|
|
57
|
+
const RELATED_COMPONENTS = [
|
|
58
|
+
'## Related components',
|
|
59
|
+
'',
|
|
60
|
+
'[Table](?path=/docs/components-table--docs) · [BooleanFilter](?path=/docs/components-table-columnfilters-booleanfilter--docs)',
|
|
61
|
+
].join('\n');
|
|
62
|
+
const PROPS_INTRO = 'The preview below is interactive — change the filter type or time value to see the model update in the **Actions** panel.';
|
|
63
|
+
// ---------------------------------------------------------------------------
|
|
64
|
+
// Custom DocsPage
|
|
65
|
+
// ---------------------------------------------------------------------------
|
|
66
|
+
function TimeFilterDocsPage() {
|
|
67
|
+
return (_jsxs(_Fragment, { children: [_jsx(Title, {}), _jsx(Subtitle, {}), _jsx(Markdown, { children: DESCRIPTION_INTRO }), _jsx(DocHeading, { children: "Interactive example" }), _jsx(Markdown, { children: PROPS_INTRO }), _jsx(DocPrimary, {}), _jsx(Controls, {}), _jsx(DocHeading, { children: "Usage guidance" }), _jsx(Markdown, { children: USAGE_GUIDANCE }), _jsx(DocHeading, { children: "Examples" }), _jsx(Stories, { title: "" }), _jsx(Markdown, { children: RELATED_COMPONENTS })] }));
|
|
68
|
+
}
|
|
69
|
+
// ---------------------------------------------------------------------------
|
|
70
|
+
// Meta
|
|
71
|
+
// ---------------------------------------------------------------------------
|
|
72
|
+
const meta = {
|
|
73
|
+
title: 'Components/Table/ColumnFilters/TimeFilter',
|
|
74
|
+
component: TimeFilter,
|
|
75
|
+
tags: ['autodocs'],
|
|
76
|
+
parameters: {
|
|
77
|
+
layout: 'padded',
|
|
78
|
+
docs: { page: TimeFilterDocsPage },
|
|
79
|
+
},
|
|
80
|
+
argTypes: {
|
|
81
|
+
model: {
|
|
82
|
+
description: 'The current filter model. `null` means no filter is active. Provide `{ filterType, pivot }` to pre-set the filter.',
|
|
83
|
+
control: false,
|
|
84
|
+
table: { type: { summary: '{ filterType: "before" | "after" | "equal"; pivot: string } | null' }, defaultValue: { summary: 'null' } },
|
|
85
|
+
},
|
|
86
|
+
onModelChange: {
|
|
87
|
+
description: 'Called whenever the user changes the filter type or time value. Receives the new `{ filterType, pivot }` model.',
|
|
88
|
+
control: false,
|
|
89
|
+
table: { type: { summary: '(model: TimeFilterModel) => void' } },
|
|
90
|
+
},
|
|
91
|
+
},
|
|
92
|
+
args: {
|
|
93
|
+
onModelChange: fn(),
|
|
94
|
+
},
|
|
95
|
+
};
|
|
96
|
+
export default meta;
|
|
97
|
+
const withDescription = (story, description) => ({
|
|
98
|
+
...story,
|
|
99
|
+
parameters: {
|
|
100
|
+
...story.parameters,
|
|
101
|
+
docs: { ...story.parameters?.docs, description: { story: description } },
|
|
102
|
+
},
|
|
103
|
+
});
|
|
104
|
+
// ---------------------------------------------------------------------------
|
|
105
|
+
// Stories
|
|
106
|
+
// ---------------------------------------------------------------------------
|
|
107
|
+
export const Default = withDescription({
|
|
108
|
+
args: {
|
|
109
|
+
model: null,
|
|
110
|
+
onModelChange: fn(),
|
|
111
|
+
},
|
|
112
|
+
}, 'No active filter (`model: null`) — filter type defaults to **Before**, time input is empty.');
|
|
113
|
+
export const BeforeNoon = withDescription({
|
|
114
|
+
parameters: { controls: { disable: true } },
|
|
115
|
+
args: {
|
|
116
|
+
model: { filterType: 'before', pivot: '12:00' },
|
|
117
|
+
onModelChange: fn(),
|
|
118
|
+
},
|
|
119
|
+
}, '**Before 12:00** — shows rows where the cell value is a time before noon.');
|
|
120
|
+
export const AfterNine = withDescription({
|
|
121
|
+
parameters: { controls: { disable: true } },
|
|
122
|
+
args: {
|
|
123
|
+
model: { filterType: 'after', pivot: '09:00' },
|
|
124
|
+
onModelChange: fn(),
|
|
125
|
+
},
|
|
126
|
+
}, '**After 09:00** — shows rows where the cell value is a time after 9am.');
|
|
127
|
+
export const ExactTime = withDescription({
|
|
128
|
+
parameters: { controls: { disable: true } },
|
|
129
|
+
args: {
|
|
130
|
+
model: { filterType: 'equal', pivot: '14:30' },
|
|
131
|
+
onModelChange: fn(),
|
|
132
|
+
},
|
|
133
|
+
}, '**At 14:30** — shows rows where the cell value exactly matches the pivot time.');
|
|
134
|
+
export const Controlled = withDescription({
|
|
135
|
+
parameters: { controls: { disable: true } },
|
|
136
|
+
render: () => {
|
|
137
|
+
const [model, setModel] = React.useState(null);
|
|
138
|
+
return (_jsxs("div", { style: { display: 'flex', flexDirection: 'column', gap: '12px' }, children: [_jsx(TimeFilter, { model: model, onModelChange: setModel }), _jsx("pre", { style: { fontSize: '12px', background: 'var(--color-neutral-50)', padding: '8px', borderRadius: '4px' }, children: model ? JSON.stringify(model, null, 2) : 'null' })] }));
|
|
139
|
+
},
|
|
140
|
+
}, 'Fully controlled — the current model is rendered below the filter as JSON. Interact with the filter to see the model update in real time.');
|
|
141
|
+
const TIME_FILTER_IN_TABLE_DATA = [
|
|
142
|
+
{ pupil: 'Alice Johnson', registrationTime: '08:45' },
|
|
143
|
+
{ pupil: 'Bob Smith', registrationTime: '09:15' },
|
|
144
|
+
{ pupil: 'Charlie Brown', registrationTime: '09:00' },
|
|
145
|
+
{ pupil: 'Diana Prince', registrationTime: '10:30' },
|
|
146
|
+
{ pupil: 'Ethan Hunt', registrationTime: '08:30' },
|
|
147
|
+
];
|
|
148
|
+
export const InATable = withDescription({
|
|
149
|
+
parameters: {
|
|
150
|
+
controls: { disable: true },
|
|
151
|
+
docs: {
|
|
152
|
+
source: {
|
|
153
|
+
language: 'tsx',
|
|
154
|
+
code: `
|
|
155
|
+
import {
|
|
156
|
+
Table,
|
|
157
|
+
TimeFilter,
|
|
158
|
+
doesTimeFilterPass,
|
|
159
|
+
} from '@arbor-education/design-system.components';
|
|
160
|
+
|
|
161
|
+
const rowData = [
|
|
162
|
+
{ pupil: 'Alice Johnson', registrationTime: '08:45' },
|
|
163
|
+
{ pupil: 'Bob Smith', registrationTime: '09:15' },
|
|
164
|
+
{ pupil: 'Charlie Brown', registrationTime: '09:00' },
|
|
165
|
+
{ pupil: 'Diana Prince', registrationTime: '10:30' },
|
|
166
|
+
{ pupil: 'Ethan Hunt', registrationTime: '08:30' },
|
|
167
|
+
];
|
|
168
|
+
|
|
169
|
+
function TimeFilterExample() {
|
|
170
|
+
return (
|
|
171
|
+
<Table
|
|
172
|
+
rowData={rowData}
|
|
173
|
+
columnDefs={[
|
|
174
|
+
{ field: 'pupil', headerName: 'Pupil', flex: 2 },
|
|
175
|
+
{
|
|
176
|
+
field: 'registrationTime',
|
|
177
|
+
headerName: 'Registration time',
|
|
178
|
+
flex: 1,
|
|
179
|
+
editable: false,
|
|
180
|
+
filter: { component: TimeFilter, doesFilterPass: doesTimeFilterPass },
|
|
181
|
+
suppressHeaderFilterButton: false,
|
|
182
|
+
},
|
|
183
|
+
]}
|
|
184
|
+
defaultColDef={{ flex: 1, minWidth: 120, suppressHeaderFilterButton: true }}
|
|
185
|
+
domLayout="autoHeight"
|
|
186
|
+
/>
|
|
187
|
+
);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
export default TimeFilterExample;
|
|
191
|
+
`.trim(),
|
|
192
|
+
},
|
|
193
|
+
},
|
|
194
|
+
},
|
|
195
|
+
render: () => (_jsx(Table, { rowData: TIME_FILTER_IN_TABLE_DATA, columnDefs: [
|
|
196
|
+
{ field: 'pupil', headerName: 'Pupil', flex: 2 },
|
|
197
|
+
{
|
|
198
|
+
field: 'registrationTime',
|
|
199
|
+
headerName: 'Registration time',
|
|
200
|
+
flex: 1,
|
|
201
|
+
editable: false,
|
|
202
|
+
filter: { component: TimeFilter, doesFilterPass: doesTimeFilterPass },
|
|
203
|
+
suppressHeaderFilterButton: false,
|
|
204
|
+
},
|
|
205
|
+
], defaultColDef: { flex: 1, minWidth: 120, suppressHeaderFilterButton: true }, domLayout: "autoHeight" })),
|
|
206
|
+
}, '`TimeFilter` wired up inside a full `Table`. Click the funnel icon in the **Registration time** column header to open the filter panel — choose **Before**, **After**, or **At** and enter a time (e.g. `09:00`) to filter the rows.');
|
|
207
|
+
//# sourceMappingURL=TimeFilter.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TimeFilter.stories.js","sourceRoot":"","sources":["../../../../src/components/table/columnFilters/TimeFilter.stories.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EACL,QAAQ,EACR,OAAO,IAAI,UAAU,EACrB,QAAQ,EACR,OAAO,IAAI,UAAU,EACrB,OAAO,EACP,QAAQ,EACR,KAAK,GACN,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,EAAE,EAAE,MAAM,gBAAgB,CAAC;AACpC,OAAO,EAAE,UAAU,EAAE,kBAAkB,EAAE,M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AAE;YACV,EAAE,KAAK,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE;YAChD;gBACE,KAAK,EAAE,kBAAkB;gBACzB,UAAU,EAAE,mBAAmB;gBAC/B,IAAI,EAAE,CAAC;gBACP,QAAQ,EAAE,KAAK;gBACf,MAAM,EAAE,EAAE,SAAS,EAAE,UAAU,EAAE,cAAc,EAAE,kBAAkB,EAAE;gBACrE,0BAA0B,EAAE,KAAK;aAClC;SACF,EACD,aAAa,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,QAAQ,EAAE,GAAG,EAAE,0BAA0B,EAAE,IAAI,EAAE,EAC3E,SAAS,EAAC,YAAY,GACtB,CACH;CACF,EACD,sOAAsO,CACvO,CAAC"}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react-vite';
|
|
2
|
+
import { PaginationPanel } from './PaginationPanel';
|
|
3
|
+
declare function PaginationPanelDocsPage(): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare const meta: {
|
|
5
|
+
title: string;
|
|
6
|
+
component: (props: {
|
|
7
|
+
className?: string;
|
|
8
|
+
} & import("./RowCountInfo").RowCountInfoProps & import("./PaginationControls").PaginationControlsProps & import("./PageSizeSelector").PageSizeSelectorProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
tags: string[];
|
|
10
|
+
parameters: {
|
|
11
|
+
layout: string;
|
|
12
|
+
docs: {
|
|
13
|
+
page: typeof PaginationPanelDocsPage;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
argTypes: {
|
|
17
|
+
totalRows: {
|
|
18
|
+
description: string;
|
|
19
|
+
control: "number";
|
|
20
|
+
table: {
|
|
21
|
+
type: {
|
|
22
|
+
summary: string;
|
|
23
|
+
};
|
|
24
|
+
defaultValue: {
|
|
25
|
+
summary: string;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
totalPages: {
|
|
30
|
+
description: string;
|
|
31
|
+
control: "number";
|
|
32
|
+
table: {
|
|
33
|
+
type: {
|
|
34
|
+
summary: string;
|
|
35
|
+
};
|
|
36
|
+
defaultValue: {
|
|
37
|
+
summary: string;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
onPageChange: {
|
|
42
|
+
description: string;
|
|
43
|
+
control: false;
|
|
44
|
+
table: {
|
|
45
|
+
type: {
|
|
46
|
+
summary: string;
|
|
47
|
+
};
|
|
48
|
+
defaultValue: {
|
|
49
|
+
summary: string;
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
availableSizes: {
|
|
54
|
+
description: string;
|
|
55
|
+
control: false;
|
|
56
|
+
table: {
|
|
57
|
+
type: {
|
|
58
|
+
summary: string;
|
|
59
|
+
};
|
|
60
|
+
defaultValue: {
|
|
61
|
+
summary: string;
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
};
|
|
65
|
+
initialPageSize: {
|
|
66
|
+
description: string;
|
|
67
|
+
control: "number";
|
|
68
|
+
table: {
|
|
69
|
+
type: {
|
|
70
|
+
summary: string;
|
|
71
|
+
};
|
|
72
|
+
defaultValue: {
|
|
73
|
+
summary: string;
|
|
74
|
+
};
|
|
75
|
+
};
|
|
76
|
+
};
|
|
77
|
+
onPageSizeChange: {
|
|
78
|
+
description: string;
|
|
79
|
+
control: false;
|
|
80
|
+
table: {
|
|
81
|
+
type: {
|
|
82
|
+
summary: string;
|
|
83
|
+
};
|
|
84
|
+
defaultValue: {
|
|
85
|
+
summary: string;
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
};
|
|
89
|
+
className: {
|
|
90
|
+
description: string;
|
|
91
|
+
control: "text";
|
|
92
|
+
table: {
|
|
93
|
+
type: {
|
|
94
|
+
summary: string;
|
|
95
|
+
};
|
|
96
|
+
defaultValue: {
|
|
97
|
+
summary: string;
|
|
98
|
+
};
|
|
99
|
+
};
|
|
100
|
+
};
|
|
101
|
+
};
|
|
102
|
+
args: {
|
|
103
|
+
onPageChange: import("@vitest/spy").Mock<(...args: any[]) => any>;
|
|
104
|
+
onPageSizeChange: import("@vitest/spy").Mock<(...args: any[]) => any>;
|
|
105
|
+
};
|
|
106
|
+
};
|
|
107
|
+
export default meta;
|
|
108
|
+
type Story = StoryObj<typeof PaginationPanel>;
|
|
109
|
+
export declare const Default: Story;
|
|
110
|
+
export declare const PageNavigationOnly: Story;
|
|
111
|
+
export declare const PageSizeSelectorOnly: Story;
|
|
112
|
+
export declare const ServerSidePagination: Story;
|
|
113
|
+
//# sourceMappingURL=PaginationPanel.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PaginationPanel.stories.d.ts","sourceRoot":"","sources":["../../../../src/components/table/pagination/PaginationPanel.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAW5D,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AA+HpD,iBAAS,uBAAuB,4CAmB/B;AAMD,QAAA,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiD8B,CAAC;AAEzC,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,eAAe,CAAC,CAAC;AAkB9C,eAAO,MAAM,OAAO,EAAE,KAarB,CAAC;AAEF,eAAO,MAAM,kBAAkB,EAAE,KAWhC,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,KAYlC,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,KAmDlC,CAAC"}
|
|
@@ -0,0 +1,272 @@
|
|
|
1
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Controls, Heading as DocHeading, Markdown, Primary as DocPrimary, Stories, Subtitle, Title, } from '@storybook/addon-docs/blocks';
|
|
3
|
+
import { fn } from 'storybook/test';
|
|
4
|
+
import { PaginationPanel } from './PaginationPanel';
|
|
5
|
+
// ---------------------------------------------------------------------------
|
|
6
|
+
// Docs page content
|
|
7
|
+
// ---------------------------------------------------------------------------
|
|
8
|
+
const DESCRIPTION_INTRO = [
|
|
9
|
+
'`PaginationPanel` is the pre-composed footer slot for the Arbor data table.',
|
|
10
|
+
'It renders a three-part `<nav>`: a **row count** (how many rows are visible),',
|
|
11
|
+
'**page controls** (first / prev / page-number input / next / last), and a **page-size selector** dropdown.',
|
|
12
|
+
'',
|
|
13
|
+
'Every part is opt-in — only pass the props for the sections you need.',
|
|
14
|
+
'Pass the entire `<PaginationPanel />` element as the `footerContent` prop of `<Table />`.',
|
|
15
|
+
].join('\n');
|
|
16
|
+
const USAGE_GUIDANCE = [
|
|
17
|
+
'### When to use',
|
|
18
|
+
'',
|
|
19
|
+
'- As the `footerContent` of a `<Table />` to give it standard pagination controls',
|
|
20
|
+
'- When you need a page-size selector alongside page navigation in a single composable component',
|
|
21
|
+
'- When implementing server-side pagination (pass `totalPages` + `onPageChange` + `onPageSizeChange`)',
|
|
22
|
+
'',
|
|
23
|
+
'---',
|
|
24
|
+
'',
|
|
25
|
+
'### When NOT to use',
|
|
26
|
+
'',
|
|
27
|
+
'| Situation | Alternative |',
|
|
28
|
+
'|---|---|',
|
|
29
|
+
'| You only need page navigation | Use `PaginationControls` directly |',
|
|
30
|
+
'| You only need a page-size selector | Use `PageSizeSelector` directly |',
|
|
31
|
+
'| The table has no pagination | Omit `footerContent` entirely |',
|
|
32
|
+
'',
|
|
33
|
+
'---',
|
|
34
|
+
'',
|
|
35
|
+
'### Sub-component summary',
|
|
36
|
+
'',
|
|
37
|
+
'| Sub-component | Key props | Notes |',
|
|
38
|
+
'|---|---|---|',
|
|
39
|
+
'| `RowCountInfo` | `totalRows` | Returns `null` when used outside a `<Table />` — it reads row count from `GridApiContext` |',
|
|
40
|
+
'| `PaginationControls` | `totalPages`, `onPageChange` | Works standalone; falls back to `GridApiContext` when no props are passed |',
|
|
41
|
+
'| `PageSizeSelector` | `availableSizes`, `initialPageSize`, `onPageSizeChange` | Works standalone; falls back to `GridApiContext` when no props are passed |',
|
|
42
|
+
].join('\n');
|
|
43
|
+
const DEVELOPER_NOTES = [
|
|
44
|
+
'### Wiring into `<Table />`',
|
|
45
|
+
'',
|
|
46
|
+
'```tsx',
|
|
47
|
+
"import { Table, PaginationPanel } from '@arbor-education/design-system.components';",
|
|
48
|
+
'',
|
|
49
|
+
'function MyTable() {',
|
|
50
|
+
' return (',
|
|
51
|
+
' <Table',
|
|
52
|
+
' rowData={rows}',
|
|
53
|
+
' columnDefs={colDefs}',
|
|
54
|
+
' footerContent={(',
|
|
55
|
+
' <PaginationPanel',
|
|
56
|
+
' availableSizes={[10, 25, 50, 100]}',
|
|
57
|
+
' initialPageSize={25}',
|
|
58
|
+
' onPageSizeChange={setPageSize}',
|
|
59
|
+
' />',
|
|
60
|
+
' )}',
|
|
61
|
+
' />',
|
|
62
|
+
' );',
|
|
63
|
+
'}',
|
|
64
|
+
'```',
|
|
65
|
+
'',
|
|
66
|
+
'---',
|
|
67
|
+
'',
|
|
68
|
+
'### Server-side pagination',
|
|
69
|
+
'',
|
|
70
|
+
'When your data is fetched page-by-page from an API, pass `totalPages` and `onPageChange`:',
|
|
71
|
+
'',
|
|
72
|
+
'```tsx',
|
|
73
|
+
'function ServerTable() {',
|
|
74
|
+
' const [page, setPage] = useState(0);',
|
|
75
|
+
' const [pageSize, setPageSize] = useState(25);',
|
|
76
|
+
' const { data, totalPages } = useMyApiQuery({ page, pageSize });',
|
|
77
|
+
'',
|
|
78
|
+
' return (',
|
|
79
|
+
' <Table',
|
|
80
|
+
' rowData={data}',
|
|
81
|
+
' columnDefs={colDefs}',
|
|
82
|
+
' footerContent={(',
|
|
83
|
+
' <PaginationPanel',
|
|
84
|
+
' totalPages={totalPages}',
|
|
85
|
+
' onPageChange={setPage}',
|
|
86
|
+
' availableSizes={[10, 25, 50]}',
|
|
87
|
+
' initialPageSize={pageSize}',
|
|
88
|
+
' onPageSizeChange={setPageSize}',
|
|
89
|
+
' />',
|
|
90
|
+
' )}',
|
|
91
|
+
' />',
|
|
92
|
+
' );',
|
|
93
|
+
'}',
|
|
94
|
+
'```',
|
|
95
|
+
'',
|
|
96
|
+
'---',
|
|
97
|
+
'',
|
|
98
|
+
'### `RowCountInfo` and `GridApiContext`',
|
|
99
|
+
'',
|
|
100
|
+
'`RowCountInfo` reads the displayed row count from `GridApiContext` — this context is provided',
|
|
101
|
+
'automatically by `<Table />`. When `PaginationPanel` is rendered outside a `<Table />`',
|
|
102
|
+
'(as in these Storybook stories), `RowCountInfo` returns `null` and the row-count text is not shown.',
|
|
103
|
+
'Pass `totalRows` to supply a value manually in server-side scenarios.',
|
|
104
|
+
'',
|
|
105
|
+
'---',
|
|
106
|
+
'',
|
|
107
|
+
'### TypeScript types',
|
|
108
|
+
'',
|
|
109
|
+
'```ts',
|
|
110
|
+
"import { PaginationPanel } from '@arbor-education/design-system.components';",
|
|
111
|
+
"import type { PaginationControlsProps, PageSizeSelectorProps, RowCountInfoProps } from '@arbor-education/design-system.components';",
|
|
112
|
+
'```',
|
|
113
|
+
].join('\n');
|
|
114
|
+
const RELATED_COMPONENTS = [
|
|
115
|
+
'## Related components',
|
|
116
|
+
'',
|
|
117
|
+
'[Table](?path=/docs/components-table--docs) · [TableControls](?path=/docs/components-table-tablecontrols--docs) · [Button](?path=/docs/components-button--docs)',
|
|
118
|
+
].join('\n');
|
|
119
|
+
const PROPS_INTRO = 'The preview below is wired to the **Controls** panel — toggle props to see the panel update in real time. Note that `RowCountInfo` (the row-count text on the left) only displays inside a `<Table />`; it returns `null` in this standalone preview.';
|
|
120
|
+
// ---------------------------------------------------------------------------
|
|
121
|
+
// Custom DocsPage
|
|
122
|
+
// ---------------------------------------------------------------------------
|
|
123
|
+
function PaginationPanelDocsPage() {
|
|
124
|
+
return (_jsxs(_Fragment, { children: [_jsx(Title, {}), _jsx(Subtitle, {}), _jsx(Markdown, { children: DESCRIPTION_INTRO }), _jsx(DocHeading, { children: "Interactive example" }), _jsx(Markdown, { children: PROPS_INTRO }), _jsx(DocPrimary, {}), _jsx(Controls, {}), _jsx(DocHeading, { children: "Usage guidance" }), _jsx(Markdown, { children: USAGE_GUIDANCE }), _jsx(DocHeading, { children: "Developer notes" }), _jsx(Markdown, { children: DEVELOPER_NOTES }), _jsx(DocHeading, { children: "Examples" }), _jsx(Stories, { title: "" }), _jsx(Markdown, { children: RELATED_COMPONENTS })] }));
|
|
125
|
+
}
|
|
126
|
+
// ---------------------------------------------------------------------------
|
|
127
|
+
// Meta
|
|
128
|
+
// ---------------------------------------------------------------------------
|
|
129
|
+
const meta = {
|
|
130
|
+
title: 'Components/Table/PaginationPanel',
|
|
131
|
+
component: PaginationPanel,
|
|
132
|
+
tags: ['autodocs'],
|
|
133
|
+
parameters: {
|
|
134
|
+
layout: 'padded',
|
|
135
|
+
docs: { page: PaginationPanelDocsPage },
|
|
136
|
+
},
|
|
137
|
+
argTypes: {
|
|
138
|
+
totalRows: {
|
|
139
|
+
description: 'Total number of rows in the dataset. Passed to `RowCountInfo` for the "Showing X of Y results" label. Only relevant when used outside a `<Table />` (which provides this automatically via `GridApiContext`).',
|
|
140
|
+
control: 'number',
|
|
141
|
+
table: { type: { summary: 'number' }, defaultValue: { summary: 'undefined' } },
|
|
142
|
+
},
|
|
143
|
+
totalPages: {
|
|
144
|
+
description: 'Total number of pages. Passed to `PaginationControls`. Required for server-side pagination; when omitted the control reads from `GridApiContext`.',
|
|
145
|
+
control: 'number',
|
|
146
|
+
table: { type: { summary: 'number' }, defaultValue: { summary: 'undefined' } },
|
|
147
|
+
},
|
|
148
|
+
onPageChange: {
|
|
149
|
+
description: 'Called with the zero-indexed new page number when the user navigates. Required for server-side pagination; when omitted the control drives the AG Grid API directly.',
|
|
150
|
+
control: false,
|
|
151
|
+
table: { type: { summary: '(newPage: number) => void' }, defaultValue: { summary: 'undefined' } },
|
|
152
|
+
},
|
|
153
|
+
availableSizes: {
|
|
154
|
+
description: 'Array of page sizes shown in the `PageSizeSelector` dropdown. Defaults to `[10, 20, 30, 50, 100, 200, 300, 500, 1000, "All"]`.',
|
|
155
|
+
control: false,
|
|
156
|
+
table: { type: { summary: '(number | "All")[]' }, defaultValue: { summary: 'undefined' } },
|
|
157
|
+
},
|
|
158
|
+
initialPageSize: {
|
|
159
|
+
description: 'The initially selected page size in the `PageSizeSelector`.',
|
|
160
|
+
control: 'number',
|
|
161
|
+
table: { type: { summary: 'number | "All"' }, defaultValue: { summary: 'undefined' } },
|
|
162
|
+
},
|
|
163
|
+
onPageSizeChange: {
|
|
164
|
+
description: 'Called with the newly selected page size when the user changes it. Required for server-side pagination; when omitted the control drives the AG Grid API directly.',
|
|
165
|
+
control: false,
|
|
166
|
+
table: { type: { summary: '(newPageSize: number | "All") => void' }, defaultValue: { summary: 'undefined' } },
|
|
167
|
+
},
|
|
168
|
+
className: {
|
|
169
|
+
description: 'Additional CSS class name(s) to apply to the root `<nav>` element.',
|
|
170
|
+
control: 'text',
|
|
171
|
+
table: { type: { summary: 'string' }, defaultValue: { summary: 'undefined' } },
|
|
172
|
+
},
|
|
173
|
+
},
|
|
174
|
+
args: {
|
|
175
|
+
onPageChange: fn(),
|
|
176
|
+
onPageSizeChange: fn(),
|
|
177
|
+
},
|
|
178
|
+
};
|
|
179
|
+
export default meta;
|
|
180
|
+
// ---------------------------------------------------------------------------
|
|
181
|
+
// Helper
|
|
182
|
+
// ---------------------------------------------------------------------------
|
|
183
|
+
const withDescription = (story, description) => ({
|
|
184
|
+
...story,
|
|
185
|
+
parameters: {
|
|
186
|
+
...story.parameters,
|
|
187
|
+
docs: { ...story.parameters?.docs, description: { story: description } },
|
|
188
|
+
},
|
|
189
|
+
});
|
|
190
|
+
// ---------------------------------------------------------------------------
|
|
191
|
+
// Stories
|
|
192
|
+
// ---------------------------------------------------------------------------
|
|
193
|
+
export const Default = withDescription({
|
|
194
|
+
args: {
|
|
195
|
+
totalPages: 10,
|
|
196
|
+
onPageChange: fn(),
|
|
197
|
+
availableSizes: [10, 25, 50, 100],
|
|
198
|
+
initialPageSize: 25,
|
|
199
|
+
onPageSizeChange: fn(),
|
|
200
|
+
},
|
|
201
|
+
}, 'The interactive canvas — all three sections visible: row count (hidden outside a `<Table />`), '
|
|
202
|
+
+ 'page navigation controls, and a page-size selector. '
|
|
203
|
+
+ 'Use the Controls panel to adjust `totalPages` and `initialPageSize`.');
|
|
204
|
+
export const PageNavigationOnly = withDescription({
|
|
205
|
+
parameters: { controls: { disable: true } },
|
|
206
|
+
args: {
|
|
207
|
+
totalPages: 5,
|
|
208
|
+
onPageChange: fn(),
|
|
209
|
+
},
|
|
210
|
+
}, 'Only `PaginationControls` — first, previous, page input, next, and last buttons. '
|
|
211
|
+
+ '`totalPages` drives the upper bound; `onPageChange` receives the zero-indexed new page number. '
|
|
212
|
+
+ 'No `PageSizeSelector` props are passed so that section is omitted.');
|
|
213
|
+
export const PageSizeSelectorOnly = withDescription({
|
|
214
|
+
parameters: { controls: { disable: true } },
|
|
215
|
+
args: {
|
|
216
|
+
availableSizes: [10, 25, 50, 100, 'All'],
|
|
217
|
+
initialPageSize: 25,
|
|
218
|
+
onPageSizeChange: fn(),
|
|
219
|
+
},
|
|
220
|
+
}, 'Only `PageSizeSelector` — a dropdown listing the available page sizes. '
|
|
221
|
+
+ 'No `totalPages` / `onPageChange` props are passed so the page-navigation section is omitted. '
|
|
222
|
+
+ 'When used inside a `<Table />` without `onPageSizeChange`, selecting a size updates the AG Grid pagination automatically.');
|
|
223
|
+
export const ServerSidePagination = withDescription({
|
|
224
|
+
parameters: {
|
|
225
|
+
controls: { disable: true },
|
|
226
|
+
docs: {
|
|
227
|
+
source: {
|
|
228
|
+
language: 'tsx',
|
|
229
|
+
code: `
|
|
230
|
+
import { useState } from 'react';
|
|
231
|
+
import { Table, PaginationPanel } from '@arbor-education/design-system.components';
|
|
232
|
+
|
|
233
|
+
function ServerTable() {
|
|
234
|
+
const [page, setPage] = useState(0);
|
|
235
|
+
const [pageSize, setPageSize] = useState(25);
|
|
236
|
+
const { data, totalPages, totalRows } = useMyApiQuery({ page, pageSize });
|
|
237
|
+
|
|
238
|
+
return (
|
|
239
|
+
<Table
|
|
240
|
+
rowData={data}
|
|
241
|
+
columnDefs={colDefs}
|
|
242
|
+
footerContent={(
|
|
243
|
+
<PaginationPanel
|
|
244
|
+
totalRows={totalRows}
|
|
245
|
+
totalPages={totalPages}
|
|
246
|
+
onPageChange={setPage}
|
|
247
|
+
availableSizes={[10, 25, 50, 100]}
|
|
248
|
+
initialPageSize={pageSize}
|
|
249
|
+
onPageSizeChange={setPageSize}
|
|
250
|
+
/>
|
|
251
|
+
)}
|
|
252
|
+
/>
|
|
253
|
+
);
|
|
254
|
+
}
|
|
255
|
+
export default ServerTable;
|
|
256
|
+
`.trim(),
|
|
257
|
+
},
|
|
258
|
+
},
|
|
259
|
+
},
|
|
260
|
+
args: {
|
|
261
|
+
totalRows: 347,
|
|
262
|
+
totalPages: 14,
|
|
263
|
+
onPageChange: fn(),
|
|
264
|
+
availableSizes: [10, 25, 50, 100],
|
|
265
|
+
initialPageSize: 25,
|
|
266
|
+
onPageSizeChange: fn(),
|
|
267
|
+
},
|
|
268
|
+
}, 'Server-side pagination pattern — `totalPages` and `onPageChange` are controlled externally by your data-fetching layer. '
|
|
269
|
+
+ '`totalRows` is provided manually (not derived from the grid). '
|
|
270
|
+
+ 'In this standalone preview `RowCountInfo` still returns `null` (no `GridApiContext`), '
|
|
271
|
+
+ 'but the code example shows the full wiring pattern.');
|
|
272
|
+
//# sourceMappingURL=PaginationPanel.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PaginationPanel.stories.js","sourceRoot":"","sources":["../../../../src/components/table/pagination/PaginationPanel.stories.tsx"],"names":[],"mappings":";AACA,OA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