@k2b/ui 0.53.0 → 0.55.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/dist/base.css +103 -0
- package/dist/browser/actions/SortableList.js +174 -0
- package/dist/browser/actions/SortableList.js.map +1 -0
- package/dist/browser/actions/Toolbar.js +186 -101
- package/dist/browser/actions/Toolbar.js.map +1 -1
- package/dist/browser/actions/drag-and-drop.js +2 -1
- package/dist/browser/actions/drag-and-drop.js.map +1 -1
- package/dist/browser/actions/index.js +1 -0
- package/dist/browser/actions/index.js.map +1 -1
- package/dist/browser/actions/sortable-list-messages.js +35 -0
- package/dist/browser/actions/sortable-list-messages.js.map +1 -0
- package/dist/browser/chart-inspection.js +2 -1
- package/dist/browser/chart-inspection.js.map +1 -1
- package/dist/browser/charts/core/balance-flow-data.js +93 -0
- package/dist/browser/charts/core/balance-flow-data.js.map +1 -0
- package/dist/browser/charts/core/balance-flow-fields.js +19 -0
- package/dist/browser/charts/core/balance-flow-fields.js.map +1 -0
- package/dist/browser/charts/core/balance-flow-frame.js +44 -0
- package/dist/browser/charts/core/balance-flow-frame.js.map +1 -0
- package/dist/browser/charts/core/balance-flow-messages.js +49 -0
- package/dist/browser/charts/core/balance-flow-messages.js.map +1 -0
- package/dist/browser/charts/core/balance-flow-size.js +42 -0
- package/dist/browser/charts/core/balance-flow-size.js.map +1 -0
- package/dist/browser/charts/core/balance-flow.js +195 -0
- package/dist/browser/charts/core/balance-flow.js.map +1 -0
- package/dist/browser/charts/core/calendar-layout.js +105 -0
- package/dist/browser/charts/core/calendar-layout.js.map +1 -0
- package/dist/browser/charts/core/calendar.js +2 -104
- package/dist/browser/charts/core/calendar.js.map +1 -1
- package/dist/browser/charts/core/index.js +9 -1
- package/dist/browser/charts/core/index.js.map +1 -1
- package/dist/browser/charts/core/inspection.js +2 -1
- package/dist/browser/charts/core/inspection.js.map +1 -1
- package/dist/browser/charts/core/number-format.js +53 -0
- package/dist/browser/charts/core/number-format.js.map +1 -0
- package/dist/browser/charts/core/registry.js +3 -1
- package/dist/browser/charts/core/registry.js.map +1 -1
- package/dist/browser/charts/core/render-size.js +2 -0
- package/dist/browser/charts/core/render-size.js.map +1 -1
- package/dist/browser/charts/core/render.js +8 -1
- package/dist/browser/charts/core/render.js.map +1 -1
- package/dist/browser/charts/core/snapshot.js +3 -3
- package/dist/browser/charts/core/snapshot.js.map +1 -1
- package/dist/browser/charts/core/types.js.map +1 -1
- package/dist/browser/charts/description.js.map +1 -1
- package/dist/browser/charts.js +2 -0
- package/dist/browser/charts.js.map +1 -1
- package/dist/browser/content/Chart.js +3 -1
- package/dist/browser/content/Chart.js.map +1 -1
- package/dist/browser/content/ChartBalanceFlow.js +90 -0
- package/dist/browser/content/ChartBalanceFlow.js.map +1 -0
- package/dist/browser/content/ChartExplorer.js +1 -1
- package/dist/browser/content/ChartExplorer.js.map +1 -1
- package/dist/browser/content/ChartRoot.js +1 -1
- package/dist/browser/content/ChartRoot.js.map +1 -1
- package/dist/browser/content/DataTable.js +212 -261
- package/dist/browser/content/DataTable.js.map +1 -1
- package/dist/browser/content/FileView.js +70 -99
- package/dist/browser/content/FileView.js.map +1 -1
- package/dist/browser/content/LoadMore.js +185 -0
- package/dist/browser/content/LoadMore.js.map +1 -0
- package/dist/browser/content/MapDialog.js +686 -0
- package/dist/browser/content/MapDialog.js.map +1 -0
- package/dist/browser/content/MapTile.js +139 -0
- package/dist/browser/content/MapTile.js.map +1 -0
- package/dist/browser/content/MapView.js +19 -8
- package/dist/browser/content/MapView.js.map +1 -1
- package/dist/browser/content/PdfPages.js +638 -0
- package/dist/browser/content/PdfPages.js.map +1 -0
- package/dist/browser/content/PdfViewer.js +264 -553
- package/dist/browser/content/PdfViewer.js.map +1 -1
- package/dist/browser/content/VirtualFeed.js +379 -89
- package/dist/browser/content/VirtualFeed.js.map +1 -1
- package/dist/browser/content/chart-balance-flow-controller.js +184 -0
- package/dist/browser/content/chart-balance-flow-controller.js.map +1 -0
- package/dist/browser/content/chart-balance-flow.js +6 -0
- package/dist/browser/content/chart-balance-flow.js.map +1 -0
- package/dist/browser/content/chart-inspection-core.js +1 -73
- package/dist/browser/content/chart-inspection-core.js.map +1 -1
- package/dist/browser/content/chart-inspection-mount.js +75 -0
- package/dist/browser/content/chart-inspection-mount.js.map +1 -0
- package/dist/browser/content/chart-svg.js +1 -1
- package/dist/browser/content/chart-svg.js.map +1 -1
- package/dist/browser/content/feed-messages.js +22 -2
- package/dist/browser/content/feed-messages.js.map +1 -1
- package/dist/browser/content/index.js +4 -1
- package/dist/browser/content/index.js.map +1 -1
- package/dist/browser/content/map-dialog-messages.js +47 -0
- package/dist/browser/content/map-dialog-messages.js.map +1 -0
- package/dist/browser/content/map-navigation.js +15 -0
- package/dist/browser/content/map-navigation.js.map +1 -0
- package/dist/browser/content/map-view-messages.js +4 -0
- package/dist/browser/content/map-view-messages.js.map +1 -1
- package/dist/browser/content/map-view-types.js.map +1 -1
- package/dist/browser/content/pdf-messages.js +8 -8
- package/dist/browser/content/pdf-messages.js.map +1 -1
- package/dist/browser/feedback/dialog-core.js +22 -10
- package/dist/browser/feedback/dialog-core.js.map +1 -1
- package/dist/browser/feedback/index.js.map +1 -1
- package/dist/browser/feedback/prompt-confirm.js +25 -14
- package/dist/browser/feedback/prompt-confirm.js.map +1 -1
- package/dist/browser/feedback/prompts.js +46 -38
- package/dist/browser/feedback/prompts.js.map +1 -1
- package/dist/browser/feedback/success-check.js +60 -0
- package/dist/browser/feedback/success-check.js.map +1 -0
- package/dist/browser/feedback/toast-hit.js +16 -0
- package/dist/browser/feedback/toast-hit.js.map +1 -0
- package/dist/browser/feedback/toast-messages.js +6 -2
- package/dist/browser/feedback/toast-messages.js.map +1 -1
- package/dist/browser/feedback/toast.js +609 -98
- package/dist/browser/feedback/toast.js.map +1 -1
- package/dist/browser/intl/messages.js +4 -0
- package/dist/browser/intl/messages.js.map +1 -1
- package/dist/browser/layout/AppWorkspace.js +58 -21
- package/dist/browser/layout/AppWorkspace.js.map +1 -1
- package/dist/browser/layout/BottomSheet.js +58 -40
- package/dist/browser/layout/BottomSheet.js.map +1 -1
- package/dist/browser/layout/Breadcrumbs.js +97 -0
- package/dist/browser/layout/Breadcrumbs.js.map +1 -0
- package/dist/browser/layout/DetailPanel.js +27 -27
- package/dist/browser/layout/DetailPanel.js.map +1 -1
- package/dist/browser/layout/Discussion.js +119 -160
- package/dist/browser/layout/Discussion.js.map +1 -1
- package/dist/browser/layout/PanelDialog.js +130 -116
- package/dist/browser/layout/PanelDialog.js.map +1 -1
- package/dist/browser/layout/index.js +1 -0
- package/dist/browser/layout/index.js.map +1 -1
- package/dist/browser/layout/sheet-motion.js +479 -0
- package/dist/browser/layout/sheet-motion.js.map +1 -0
- package/dist/browser/surfaces/NoticeCard.js +68 -47
- package/dist/browser/surfaces/NoticeCard.js.map +1 -1
- package/dist/browser/surfaces/Skeleton.js +32 -0
- package/dist/browser/surfaces/Skeleton.js.map +1 -1
- package/dist/browser/surfaces/index.js +1 -1
- package/dist/browser/surfaces/index.js.map +1 -1
- package/dist/browser/text-editor/TextEditor.js +7 -3
- package/dist/browser/text-editor/TextEditor.js.map +1 -1
- package/dist/browser/text-editor/clipboard-html.js +62 -26
- package/dist/browser/text-editor/clipboard-html.js.map +1 -1
- package/dist/browser/text-editor/clipboard-loading.js +44 -15
- package/dist/browser/text-editor/clipboard-loading.js.map +1 -1
- package/dist/browser/text-editor/engine.js +9 -4
- package/dist/browser/text-editor/engine.js.map +1 -1
- package/dist/browser/text-editor/format.js +37 -1
- package/dist/browser/text-editor/format.js.map +1 -1
- package/dist/browser/text-editor/paste.js +2 -1
- package/dist/browser/text-editor/paste.js.map +1 -1
- package/dist/ssr/actions/SortableList.js +116 -0
- package/dist/ssr/actions/SortableList.js.map +1 -0
- package/dist/ssr/actions/Toolbar.js +89 -35
- package/dist/ssr/actions/Toolbar.js.map +1 -1
- package/dist/ssr/actions/drag-and-drop.js +2 -1
- package/dist/ssr/actions/drag-and-drop.js.map +1 -1
- package/dist/ssr/actions/index.js +1 -0
- package/dist/ssr/actions/index.js.map +1 -1
- package/dist/ssr/actions/sortable-list-messages.js +35 -0
- package/dist/ssr/actions/sortable-list-messages.js.map +1 -0
- package/dist/ssr/chart-inspection.js +2 -1
- package/dist/ssr/chart-inspection.js.map +1 -1
- package/dist/ssr/charts/core/balance-flow-data.js +93 -0
- package/dist/ssr/charts/core/balance-flow-data.js.map +1 -0
- package/dist/ssr/charts/core/balance-flow-fields.js +19 -0
- package/dist/ssr/charts/core/balance-flow-fields.js.map +1 -0
- package/dist/ssr/charts/core/balance-flow-frame.js +44 -0
- package/dist/ssr/charts/core/balance-flow-frame.js.map +1 -0
- package/dist/ssr/charts/core/balance-flow-messages.js +49 -0
- package/dist/ssr/charts/core/balance-flow-messages.js.map +1 -0
- package/dist/ssr/charts/core/balance-flow-size.js +42 -0
- package/dist/ssr/charts/core/balance-flow-size.js.map +1 -0
- package/dist/ssr/charts/core/balance-flow.js +195 -0
- package/dist/ssr/charts/core/balance-flow.js.map +1 -0
- package/dist/ssr/charts/core/calendar-layout.js +105 -0
- package/dist/ssr/charts/core/calendar-layout.js.map +1 -0
- package/dist/ssr/charts/core/calendar.js +2 -104
- package/dist/ssr/charts/core/calendar.js.map +1 -1
- package/dist/ssr/charts/core/index.js +9 -1
- package/dist/ssr/charts/core/index.js.map +1 -1
- package/dist/ssr/charts/core/inspection.js +2 -1
- package/dist/ssr/charts/core/inspection.js.map +1 -1
- package/dist/ssr/charts/core/number-format.js +53 -0
- package/dist/ssr/charts/core/number-format.js.map +1 -0
- package/dist/ssr/charts/core/registry.js +3 -1
- package/dist/ssr/charts/core/registry.js.map +1 -1
- package/dist/ssr/charts/core/render-size.js +2 -0
- package/dist/ssr/charts/core/render-size.js.map +1 -1
- package/dist/ssr/charts/core/render.js +8 -1
- package/dist/ssr/charts/core/render.js.map +1 -1
- package/dist/ssr/charts/core/snapshot.js +3 -3
- package/dist/ssr/charts/core/snapshot.js.map +1 -1
- package/dist/ssr/charts/core/types.js.map +1 -1
- package/dist/ssr/charts/description.js.map +1 -1
- package/dist/ssr/charts.js +2 -0
- package/dist/ssr/charts.js.map +1 -1
- package/dist/ssr/content/Chart.js +3 -1
- package/dist/ssr/content/Chart.js.map +1 -1
- package/dist/ssr/content/ChartBalanceFlow.js +69 -0
- package/dist/ssr/content/ChartBalanceFlow.js.map +1 -0
- package/dist/ssr/content/ChartExplorer.js +1 -1
- package/dist/ssr/content/ChartExplorer.js.map +1 -1
- package/dist/ssr/content/ChartRoot.js +1 -1
- package/dist/ssr/content/ChartRoot.js.map +1 -1
- package/dist/ssr/content/DataTable.js +72 -118
- package/dist/ssr/content/DataTable.js.map +1 -1
- package/dist/ssr/content/FileView.js +39 -50
- package/dist/ssr/content/FileView.js.map +1 -1
- package/dist/ssr/content/LoadMore.js +146 -0
- package/dist/ssr/content/LoadMore.js.map +1 -0
- package/dist/ssr/content/MapDialog.js +469 -0
- package/dist/ssr/content/MapDialog.js.map +1 -0
- package/dist/ssr/content/MapTile.js +92 -0
- package/dist/ssr/content/MapTile.js.map +1 -0
- package/dist/ssr/content/MapView.js +12 -8
- package/dist/ssr/content/MapView.js.map +1 -1
- package/dist/ssr/content/PdfPages.js +538 -0
- package/dist/ssr/content/PdfPages.js.map +1 -0
- package/dist/ssr/content/PdfViewer.js +226 -457
- package/dist/ssr/content/PdfViewer.js.map +1 -1
- package/dist/ssr/content/VirtualFeed.js +292 -44
- package/dist/ssr/content/VirtualFeed.js.map +1 -1
- package/dist/ssr/content/chart-balance-flow-controller.js +184 -0
- package/dist/ssr/content/chart-balance-flow-controller.js.map +1 -0
- package/dist/ssr/content/chart-balance-flow.js +6 -0
- package/dist/ssr/content/chart-balance-flow.js.map +1 -0
- package/dist/ssr/content/chart-inspection-core.js +1 -73
- package/dist/ssr/content/chart-inspection-core.js.map +1 -1
- package/dist/ssr/content/chart-inspection-mount.js +75 -0
- package/dist/ssr/content/chart-inspection-mount.js.map +1 -0
- package/dist/ssr/content/chart-svg.js +1 -1
- package/dist/ssr/content/chart-svg.js.map +1 -1
- package/dist/ssr/content/feed-messages.js +22 -2
- package/dist/ssr/content/feed-messages.js.map +1 -1
- package/dist/ssr/content/index.js +4 -1
- package/dist/ssr/content/index.js.map +1 -1
- package/dist/ssr/content/map-dialog-messages.js +47 -0
- package/dist/ssr/content/map-dialog-messages.js.map +1 -0
- package/dist/ssr/content/map-navigation.js +15 -0
- package/dist/ssr/content/map-navigation.js.map +1 -0
- package/dist/ssr/content/map-view-messages.js +4 -0
- package/dist/ssr/content/map-view-messages.js.map +1 -1
- package/dist/ssr/content/map-view-types.js.map +1 -1
- package/dist/ssr/content/pdf-messages.js +8 -8
- package/dist/ssr/content/pdf-messages.js.map +1 -1
- package/dist/ssr/feedback/dialog-core.js +22 -10
- package/dist/ssr/feedback/dialog-core.js.map +1 -1
- package/dist/ssr/feedback/index.js.map +1 -1
- package/dist/ssr/feedback/prompt-confirm.js +13 -2
- package/dist/ssr/feedback/prompt-confirm.js.map +1 -1
- package/dist/ssr/feedback/prompts.js +32 -24
- package/dist/ssr/feedback/prompts.js.map +1 -1
- package/dist/ssr/feedback/success-check.js +47 -0
- package/dist/ssr/feedback/success-check.js.map +1 -0
- package/dist/ssr/feedback/toast-hit.js +16 -0
- package/dist/ssr/feedback/toast-hit.js.map +1 -0
- package/dist/ssr/feedback/toast-messages.js +6 -2
- package/dist/ssr/feedback/toast-messages.js.map +1 -1
- package/dist/ssr/feedback/toast.js +609 -98
- package/dist/ssr/feedback/toast.js.map +1 -1
- package/dist/ssr/intl/messages.js +4 -0
- package/dist/ssr/intl/messages.js.map +1 -1
- package/dist/ssr/layout/AppWorkspace.js +39 -5
- package/dist/ssr/layout/AppWorkspace.js.map +1 -1
- package/dist/ssr/layout/BottomSheet.js +32 -4
- package/dist/ssr/layout/BottomSheet.js.map +1 -1
- package/dist/ssr/layout/Breadcrumbs.js +62 -0
- package/dist/ssr/layout/Breadcrumbs.js.map +1 -0
- package/dist/ssr/layout/DetailPanel.js +10 -10
- package/dist/ssr/layout/DetailPanel.js.map +1 -1
- package/dist/ssr/layout/Discussion.js +39 -65
- package/dist/ssr/layout/Discussion.js.map +1 -1
- package/dist/ssr/layout/PanelDialog.js +54 -35
- package/dist/ssr/layout/PanelDialog.js.map +1 -1
- package/dist/ssr/layout/index.js +1 -0
- package/dist/ssr/layout/index.js.map +1 -1
- package/dist/ssr/layout/sheet-motion.js +479 -0
- package/dist/ssr/layout/sheet-motion.js.map +1 -0
- package/dist/ssr/surfaces/NoticeCard.js +33 -17
- package/dist/ssr/surfaces/NoticeCard.js.map +1 -1
- package/dist/ssr/surfaces/Skeleton.js +32 -0
- package/dist/ssr/surfaces/Skeleton.js.map +1 -1
- package/dist/ssr/surfaces/index.js +1 -1
- package/dist/ssr/surfaces/index.js.map +1 -1
- package/dist/ssr/text-editor/TextEditor.js +7 -3
- package/dist/ssr/text-editor/TextEditor.js.map +1 -1
- package/dist/ssr/text-editor/clipboard-html.js +62 -26
- package/dist/ssr/text-editor/clipboard-html.js.map +1 -1
- package/dist/ssr/text-editor/clipboard-loading.js +44 -15
- package/dist/ssr/text-editor/clipboard-loading.js.map +1 -1
- package/dist/ssr/text-editor/engine.js +9 -4
- package/dist/ssr/text-editor/engine.js.map +1 -1
- package/dist/ssr/text-editor/format.js +37 -1
- package/dist/ssr/text-editor/format.js.map +1 -1
- package/dist/ssr/text-editor/paste.js +2 -1
- package/dist/ssr/text-editor/paste.js.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/types/actions/SortableList.d.ts +26 -0
- package/dist/types/actions/Toolbar.d.ts +11 -0
- package/dist/types/actions/drag-and-drop.d.ts +2 -0
- package/dist/types/actions/index.d.ts +2 -0
- package/dist/types/actions/sortable-list-messages.d.ts +15 -0
- package/dist/types/chart-inspection.d.ts +2 -1
- package/dist/types/charts/core/balance-flow-data.d.ts +37 -0
- package/dist/types/charts/core/balance-flow-fields.d.ts +13 -0
- package/dist/types/charts/core/balance-flow-frame.d.ts +4 -0
- package/dist/types/charts/core/balance-flow-messages.d.ts +97 -0
- package/dist/types/charts/core/balance-flow-size.d.ts +21 -0
- package/dist/types/charts/core/balance-flow.d.ts +70 -0
- package/dist/types/charts/core/calendar-layout.d.ts +67 -0
- package/dist/types/charts/core/calendar.d.ts +2 -64
- package/dist/types/charts/core/index.d.ts +9 -1
- package/dist/types/charts/core/number-format.d.ts +28 -0
- package/dist/types/charts/core/registry.d.ts +2 -0
- package/dist/types/charts/core/types.d.ts +1 -0
- package/dist/types/charts/description.d.ts +17 -0
- package/dist/types/charts.d.ts +2 -0
- package/dist/types/content/ChartBalanceFlow.d.ts +17 -0
- package/dist/types/content/ChartRoot.d.ts +2 -1
- package/dist/types/content/DataTable.d.ts +7 -1
- package/dist/types/content/LoadMore.d.ts +41 -0
- package/dist/types/content/MapDialog.d.ts +105 -0
- package/dist/types/content/MapTile.d.ts +37 -0
- package/dist/types/content/PdfPages.d.ts +57 -0
- package/dist/types/content/PdfViewer.d.ts +35 -19
- package/dist/types/content/VirtualFeed.d.ts +57 -18
- package/dist/types/content/chart-balance-flow-controller.d.ts +12 -0
- package/dist/types/content/chart-balance-flow.d.ts +4 -0
- package/dist/types/content/chart-inspection-core.d.ts +0 -17
- package/dist/types/content/chart-inspection-mount.d.ts +21 -0
- package/dist/types/content/feed-messages.d.ts +10 -0
- package/dist/types/content/index.d.ts +6 -3
- package/dist/types/content/map-dialog-messages.d.ts +19 -0
- package/dist/types/content/map-navigation.d.ts +13 -0
- package/dist/types/content/map-view-messages.d.ts +2 -0
- package/dist/types/content/map-view-types.d.ts +5 -0
- package/dist/types/content/pdf-messages.d.ts +2 -2
- package/dist/types/feedback/dialog-core.d.ts +6 -0
- package/dist/types/feedback/index.d.ts +2 -2
- package/dist/types/feedback/prompt-confirm.d.ts +2 -0
- package/dist/types/feedback/prompts.d.ts +5 -1
- package/dist/types/feedback/success-check.d.ts +4 -0
- package/dist/types/feedback/toast-hit.d.ts +5 -0
- package/dist/types/feedback/toast-messages.d.ts +3 -1
- package/dist/types/feedback/toast.d.ts +42 -5
- package/dist/types/intl/messages.d.ts +2 -0
- package/dist/types/layout/AppWorkspace.d.ts +10 -0
- package/dist/types/layout/BottomSheet.d.ts +6 -0
- package/dist/types/layout/Breadcrumbs.d.ts +19 -0
- package/dist/types/layout/DetailPanel.d.ts +4 -1
- package/dist/types/layout/PanelDialog.d.ts +5 -0
- package/dist/types/layout/index.d.ts +2 -1
- package/dist/types/layout/sheet-motion.d.ts +32 -0
- package/dist/types/surfaces/NoticeCard.d.ts +14 -1
- package/dist/types/surfaces/Skeleton.d.ts +13 -1
- package/dist/types/surfaces/index.d.ts +1 -1
- package/dist/types/text-editor/TextEditor.d.ts +5 -0
- package/dist/types/text-editor/clipboard-loading.d.ts +2 -3
- package/dist/types/text-editor/engine.d.ts +6 -1
- package/dist/types/text-editor/format.d.ts +3 -1
- package/package.json +2 -2
- package/dist/browser/content/PdfPreview.js +0 -448
- package/dist/browser/content/PdfPreview.js.map +0 -1
- package/dist/ssr/content/PdfPreview.js +0 -300
- package/dist/ssr/content/PdfPreview.js.map +0 -1
- package/dist/types/content/PdfPreview.d.ts +0 -26
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { type JSX } from "solid-js";
|
|
2
|
+
export type SortableListProps<Item> = {
|
|
3
|
+
items: readonly Item[];
|
|
4
|
+
/** Stable identity of an item. Rows are keyed by it, so a newer copy of an item keeps its row and focus. */
|
|
5
|
+
itemKey: (item: Item) => string;
|
|
6
|
+
/** Names the item for its handle, the drag preview, and announcements. */
|
|
7
|
+
itemLabel: (item: Item) => string;
|
|
8
|
+
/** Tabler class for the drag preview; defaults to the grip. */
|
|
9
|
+
itemIcon?: (item: Item) => string | undefined;
|
|
10
|
+
/** Moves the item to `index` of the list as it is now. The host owns the order and saves it. */
|
|
11
|
+
onMove: (key: string, index: number) => void;
|
|
12
|
+
/** Names the list for assistive technology. */
|
|
13
|
+
label?: string;
|
|
14
|
+
disabled?: boolean;
|
|
15
|
+
class?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Renders one row, once per key; place `handle` where the row's grip belongs. Read the item through `item`, which
|
|
18
|
+
* always returns the current copy, so the row updates in place and its grip keeps focus.
|
|
19
|
+
*/
|
|
20
|
+
children: (item: () => Item, handle: JSX.Element) => JSX.Element;
|
|
21
|
+
};
|
|
22
|
+
/**
|
|
23
|
+
* An ordered list whose rows move by their grip: drag it, or focus it and use the arrow keys, Home, or End. Moves go
|
|
24
|
+
* through `onMove`; the list renders `items` as given, so the host's order is the only order.
|
|
25
|
+
*/
|
|
26
|
+
export declare function SortableList<Item>(props: SortableListProps<Item>): JSX.Element;
|
|
@@ -8,6 +8,12 @@ export type ToolbarProps = {
|
|
|
8
8
|
variant?: "inline" | "floating";
|
|
9
9
|
/** The edge a floating toolbar sticks to while its column scrolls. Defaults to `bottom`. */
|
|
10
10
|
edge?: "top" | "bottom";
|
|
11
|
+
/**
|
|
12
|
+
* `danger` makes a floating toolbar the one red pill of a stopped state, such as an editor that can no longer save.
|
|
13
|
+
* It spans its row in place of the usual pills, and screen readers announce its labels at once. Inline toolbars
|
|
14
|
+
* ignore it.
|
|
15
|
+
*/
|
|
16
|
+
tone?: "danger";
|
|
11
17
|
class?: string;
|
|
12
18
|
};
|
|
13
19
|
export type ToolbarActionProps = {
|
|
@@ -34,6 +40,11 @@ export type ToolbarActionProps = {
|
|
|
34
40
|
};
|
|
35
41
|
export type ToolbarLabelProps = {
|
|
36
42
|
children: JSX.Element;
|
|
43
|
+
/**
|
|
44
|
+
* Follows the label while it fits, such as the reason after "Not saved". A narrow toolbar hides it whole before
|
|
45
|
+
* actions give up their labels; screen readers always read it.
|
|
46
|
+
*/
|
|
47
|
+
detail?: JSX.Element;
|
|
37
48
|
class?: string;
|
|
38
49
|
};
|
|
39
50
|
export type ToolbarGroupProps = {
|
|
@@ -23,6 +23,8 @@ type Target = {
|
|
|
23
23
|
disabled?: boolean;
|
|
24
24
|
drop: (payload: DragPayload) => void;
|
|
25
25
|
};
|
|
26
|
+
/** Speaks through the drag live region of `origin`'s container; SortableList shares it for keyboard moves. */
|
|
27
|
+
export declare const announce: (origin: HTMLElement, text: string) => void;
|
|
26
28
|
export declare const registerDropTarget: (element: HTMLElement, initial: Omit<Target, "element">) => {
|
|
27
29
|
update(next: Omit<Target, "element">): void;
|
|
28
30
|
dispose(): void;
|
|
@@ -23,6 +23,8 @@ export type { SegmentedControlProps, SegmentOption } from "./SegmentedControl";
|
|
|
23
23
|
export { SegmentedControl } from "./SegmentedControl";
|
|
24
24
|
export type { SelectionToolbarProps } from "./SelectionToolbar";
|
|
25
25
|
export { SelectionToolbar } from "./SelectionToolbar";
|
|
26
|
+
export type { SortableListProps } from "./SortableList";
|
|
27
|
+
export { SortableList } from "./SortableList";
|
|
26
28
|
export type { SplitButtonProps } from "./SplitButton";
|
|
27
29
|
export { SplitButton } from "./SplitButton";
|
|
28
30
|
export type { SpotlightButtonProps, SpotlightButtonVariant, SpotlightSearchOptions, SpotlightSearchResolver, } from "./SpotlightSearch";
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
declare const sortableListMessages: import("@k2b/stdlib").Catalog<{
|
|
2
|
+
handle: ({ label }: {
|
|
3
|
+
label: string;
|
|
4
|
+
}) => string;
|
|
5
|
+
hint: string;
|
|
6
|
+
moved: ({ label, position, count }: {
|
|
7
|
+
label: string;
|
|
8
|
+
position: number;
|
|
9
|
+
count: number;
|
|
10
|
+
}) => string;
|
|
11
|
+
}>;
|
|
12
|
+
export type SortableListMessages = ReturnType<(typeof sortableListMessages)["resolve"]>["t"];
|
|
13
|
+
export declare const useSortableListMessages: () => (() => SortableListMessages);
|
|
14
|
+
export declare const checkSortableListMessages: () => import("@k2b/stdlib").CatalogIssue[];
|
|
15
|
+
export {};
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
export { type ChartCursor, createChartCursor } from "./content/chart-cursor";
|
|
2
|
-
export { type ChartDatumRef, type
|
|
2
|
+
export { type ChartDatumRef, type ChartKind, type ChartSelection, type ChartTooltip, type ChartTooltipFormatter, isChartDatum, sameChartDatum, } from "./content/chart-inspection-core";
|
|
3
|
+
export { type ChartInspection, type InspectChartOptions, inspectChart } from "./content/chart-inspection-mount";
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { BalanceFlowPeriod } from "./balance-flow-size";
|
|
2
|
+
import type { ChartOptions } from "./svg-common";
|
|
3
|
+
import type { ChartDatum } from "./types";
|
|
4
|
+
export type BalanceFlowOptions = ChartOptions & {
|
|
5
|
+
periods: BalanceFlowPeriod[];
|
|
6
|
+
currency: string;
|
|
7
|
+
locale?: string;
|
|
8
|
+
/** Period used by row/summary helpers; the continuous frame always opens at the newest end. */
|
|
9
|
+
period?: number;
|
|
10
|
+
format?: (value: number) => string;
|
|
11
|
+
valueLabel?: string;
|
|
12
|
+
displayWidth?: number;
|
|
13
|
+
};
|
|
14
|
+
export declare const balanceFlowAmount: (spec: Pick<BalanceFlowOptions, "locale" | "currency" | "format">, value: number) => string;
|
|
15
|
+
export declare const balanceFlowDisplayAmount: (spec: Pick<BalanceFlowOptions, "locale" | "currency" | "format">, row: Pick<BalanceFlowRow, "direction" | "value">) => string;
|
|
16
|
+
export { balanceFlowWords } from "./balance-flow-messages";
|
|
17
|
+
export type BalanceFlowRow = {
|
|
18
|
+
label: string;
|
|
19
|
+
value: number;
|
|
20
|
+
direction: "balance" | "in" | "out" | "neutral";
|
|
21
|
+
key: string;
|
|
22
|
+
};
|
|
23
|
+
export declare function balanceFlowRows(spec: BalanceFlowOptions, index?: number): BalanceFlowRow[];
|
|
24
|
+
export declare const balanceFlowDirection: (direction: string, locale?: string) => string;
|
|
25
|
+
export declare const balanceFlowSummary: (spec: BalanceFlowOptions, index?: number) => string;
|
|
26
|
+
/** Same column order and text as editor chartRows/chartTooltip. */
|
|
27
|
+
export declare function balanceFlowTooltip(datum: ChartDatum, locale?: string): {
|
|
28
|
+
title: string | undefined;
|
|
29
|
+
rows: {
|
|
30
|
+
label: string;
|
|
31
|
+
value: string;
|
|
32
|
+
}[];
|
|
33
|
+
};
|
|
34
|
+
/** A shared boundary is described once, in the preceding period's closing datum. */
|
|
35
|
+
export declare const balanceFlowBoundaryLabel: (spec: BalanceFlowOptions, index: number) => string;
|
|
36
|
+
/** Full table data includes zero flows, although zero-width links have no inspection target. */
|
|
37
|
+
export declare function balanceFlowDatums(spec: BalanceFlowOptions): ChartDatum[];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare const balanceFlowFields: (locale?: string) => {
|
|
2
|
+
balancePeriod: string;
|
|
3
|
+
balanceDirection: string;
|
|
4
|
+
chartFields: ({ key }: {
|
|
5
|
+
key: string;
|
|
6
|
+
}) => string;
|
|
7
|
+
} | {
|
|
8
|
+
balancePeriod: string;
|
|
9
|
+
balanceDirection: string;
|
|
10
|
+
chartFields: ({ key }: {
|
|
11
|
+
key: string;
|
|
12
|
+
}) => string;
|
|
13
|
+
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type BalanceFlowOptions } from "./balance-flow";
|
|
2
|
+
export type BalanceFlowState = "data" | "loading" | "empty" | "error" | "stale";
|
|
3
|
+
/** SSR-complete continuous canvas; reversed flex origin reveals the newest month without script. */
|
|
4
|
+
export declare function renderBalanceFlowHtml(spec: BalanceFlowOptions, state?: BalanceFlowState, error?: string, view?: "chart" | "table", retry?: boolean, standalone?: boolean): string;
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
export declare const balanceFlowWords: (locale?: string) => {
|
|
2
|
+
balancePeriod: string;
|
|
3
|
+
balanceDirection: string;
|
|
4
|
+
chartFields: ({ key }: {
|
|
5
|
+
key: string;
|
|
6
|
+
}) => string;
|
|
7
|
+
balanceOpening: string;
|
|
8
|
+
balanceClosing: string;
|
|
9
|
+
balanceInflows: string;
|
|
10
|
+
balanceOutflows: string;
|
|
11
|
+
balanceBalance: string;
|
|
12
|
+
balanceAvailable: string;
|
|
13
|
+
balanceOwed: string;
|
|
14
|
+
balancePrevious: string;
|
|
15
|
+
balanceNext: string;
|
|
16
|
+
balanceEmpty: string;
|
|
17
|
+
balanceInvalid: string;
|
|
18
|
+
balanceStale: string;
|
|
19
|
+
balanceRetry: string;
|
|
20
|
+
balanceKeyboard: string;
|
|
21
|
+
chartView: string;
|
|
22
|
+
chartDiagram: string;
|
|
23
|
+
chartData: string;
|
|
24
|
+
chartLoading: string;
|
|
25
|
+
} | {
|
|
26
|
+
balancePeriod: string;
|
|
27
|
+
balanceDirection: string;
|
|
28
|
+
chartFields: ({ key }: {
|
|
29
|
+
key: string;
|
|
30
|
+
}) => string;
|
|
31
|
+
balanceOpening: string;
|
|
32
|
+
balanceClosing: string;
|
|
33
|
+
balanceInflows: string;
|
|
34
|
+
balanceOutflows: string;
|
|
35
|
+
balanceBalance: string;
|
|
36
|
+
balanceAvailable: string;
|
|
37
|
+
balanceOwed: string;
|
|
38
|
+
balancePrevious: string;
|
|
39
|
+
balanceNext: string;
|
|
40
|
+
balanceEmpty: string;
|
|
41
|
+
balanceInvalid: string;
|
|
42
|
+
balanceStale: string;
|
|
43
|
+
balanceRetry: string;
|
|
44
|
+
balanceKeyboard: string;
|
|
45
|
+
chartView: string;
|
|
46
|
+
chartDiagram: string;
|
|
47
|
+
chartData: string;
|
|
48
|
+
chartLoading: string;
|
|
49
|
+
} | {
|
|
50
|
+
balancePeriod: string;
|
|
51
|
+
balanceDirection: string;
|
|
52
|
+
chartFields: ({ key }: {
|
|
53
|
+
key: string;
|
|
54
|
+
}) => string;
|
|
55
|
+
balanceOpening: string;
|
|
56
|
+
balanceClosing: string;
|
|
57
|
+
balanceInflows: string;
|
|
58
|
+
balanceOutflows: string;
|
|
59
|
+
balanceBalance: string;
|
|
60
|
+
balanceAvailable: string;
|
|
61
|
+
balanceOwed: string;
|
|
62
|
+
balancePrevious: string;
|
|
63
|
+
balanceNext: string;
|
|
64
|
+
balanceEmpty: string;
|
|
65
|
+
balanceInvalid: string;
|
|
66
|
+
balanceStale: string;
|
|
67
|
+
balanceRetry: string;
|
|
68
|
+
balanceKeyboard: string;
|
|
69
|
+
chartView: string;
|
|
70
|
+
chartDiagram: string;
|
|
71
|
+
chartData: string;
|
|
72
|
+
chartLoading: string;
|
|
73
|
+
} | {
|
|
74
|
+
balancePeriod: string;
|
|
75
|
+
balanceDirection: string;
|
|
76
|
+
chartFields: ({ key }: {
|
|
77
|
+
key: string;
|
|
78
|
+
}) => string;
|
|
79
|
+
balanceOpening: string;
|
|
80
|
+
balanceClosing: string;
|
|
81
|
+
balanceInflows: string;
|
|
82
|
+
balanceOutflows: string;
|
|
83
|
+
balanceBalance: string;
|
|
84
|
+
balanceAvailable: string;
|
|
85
|
+
balanceOwed: string;
|
|
86
|
+
balancePrevious: string;
|
|
87
|
+
balanceNext: string;
|
|
88
|
+
balanceEmpty: string;
|
|
89
|
+
balanceInvalid: string;
|
|
90
|
+
balanceStale: string;
|
|
91
|
+
balanceRetry: string;
|
|
92
|
+
balanceKeyboard: string;
|
|
93
|
+
chartView: string;
|
|
94
|
+
chartDiagram: string;
|
|
95
|
+
chartData: string;
|
|
96
|
+
chartLoading: string;
|
|
97
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/** Portable balance-flow data. Amounts keep the decimal value supplied by the author. */
|
|
2
|
+
export type BalanceFlowItem = {
|
|
3
|
+
label: string;
|
|
4
|
+
value: number;
|
|
5
|
+
};
|
|
6
|
+
export type BalanceFlowPeriod = {
|
|
7
|
+
label: string;
|
|
8
|
+
opening: number;
|
|
9
|
+
inflows: BalanceFlowItem[];
|
|
10
|
+
outflows: BalanceFlowItem[];
|
|
11
|
+
closing: number;
|
|
12
|
+
};
|
|
13
|
+
/** Retain the period identity across the JSON, frame and Notebook diagnostic boundaries. */
|
|
14
|
+
export declare class BalanceFlowError extends RangeError {
|
|
15
|
+
readonly period: number;
|
|
16
|
+
readonly periodLabel: string;
|
|
17
|
+
constructor(period: number, periodLabel: string, message: string);
|
|
18
|
+
}
|
|
19
|
+
export declare function validateBalanceFlow(periods: readonly BalanceFlowPeriod[]): void;
|
|
20
|
+
/** One content height for every period and state, independent of the selected month and measured browser width. */
|
|
21
|
+
export declare const balanceFlowHeight: (periods: readonly BalanceFlowPeriod[], height?: number) => number;
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { type BalanceFlowOptions } from "./balance-flow-data";
|
|
2
|
+
export * from "./balance-flow-data";
|
|
3
|
+
export { BalanceFlowError, type BalanceFlowItem, type BalanceFlowPeriod, balanceFlowHeight, validateBalanceFlow, } from "./balance-flow-size";
|
|
4
|
+
export declare const balanceFlowColors: {
|
|
5
|
+
balance: string;
|
|
6
|
+
in: string;
|
|
7
|
+
out: string;
|
|
8
|
+
neutral: string;
|
|
9
|
+
};
|
|
10
|
+
/** Common scale and bottom edge make every closing/opening join geometrically identical. */
|
|
11
|
+
export declare function balanceFlowLayout(spec: BalanceFlowOptions): {
|
|
12
|
+
nodes: {
|
|
13
|
+
id: string;
|
|
14
|
+
index: number;
|
|
15
|
+
incoming: number;
|
|
16
|
+
outgoing: number;
|
|
17
|
+
value: number;
|
|
18
|
+
stage: number;
|
|
19
|
+
x: number;
|
|
20
|
+
y: number;
|
|
21
|
+
height: number;
|
|
22
|
+
showLabel: boolean;
|
|
23
|
+
}[];
|
|
24
|
+
width: number;
|
|
25
|
+
height: number;
|
|
26
|
+
header: {
|
|
27
|
+
height: number;
|
|
28
|
+
};
|
|
29
|
+
nodeWidth: number;
|
|
30
|
+
links: {
|
|
31
|
+
source: string;
|
|
32
|
+
target: string;
|
|
33
|
+
value: number;
|
|
34
|
+
sourceNode: {
|
|
35
|
+
id: string;
|
|
36
|
+
index: number;
|
|
37
|
+
incoming: number;
|
|
38
|
+
outgoing: number;
|
|
39
|
+
value: number;
|
|
40
|
+
stage: number;
|
|
41
|
+
x: number;
|
|
42
|
+
y: number;
|
|
43
|
+
height: number;
|
|
44
|
+
showLabel: boolean;
|
|
45
|
+
};
|
|
46
|
+
targetNode: {
|
|
47
|
+
id: string;
|
|
48
|
+
index: number;
|
|
49
|
+
incoming: number;
|
|
50
|
+
outgoing: number;
|
|
51
|
+
value: number;
|
|
52
|
+
stage: number;
|
|
53
|
+
x: number;
|
|
54
|
+
y: number;
|
|
55
|
+
height: number;
|
|
56
|
+
showLabel: boolean;
|
|
57
|
+
};
|
|
58
|
+
thickness: number;
|
|
59
|
+
sy: number;
|
|
60
|
+
ty: number;
|
|
61
|
+
x1: number;
|
|
62
|
+
x2: number;
|
|
63
|
+
path: string;
|
|
64
|
+
}[];
|
|
65
|
+
rows: import("./balance-flow-data").BalanceFlowRow[];
|
|
66
|
+
labelY: Map<number, number>;
|
|
67
|
+
scale: number;
|
|
68
|
+
bottom: number;
|
|
69
|
+
};
|
|
70
|
+
export declare function renderBalanceFlowSvg(spec: BalanceFlowOptions): string;
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { type ChartOptions, type HeatmapOptions } from "./svg-common";
|
|
2
|
+
export type CalendarHeatmapOptions = ChartOptions & {
|
|
3
|
+
layout: "calendar";
|
|
4
|
+
data: [string, number | null][];
|
|
5
|
+
scale: "sequential" | "diverging";
|
|
6
|
+
/** Unit shown beside each tooltip value. */
|
|
7
|
+
label?: string;
|
|
8
|
+
locale?: string;
|
|
9
|
+
format?: (value: number) => string;
|
|
10
|
+
displayWidth?: number;
|
|
11
|
+
};
|
|
12
|
+
export type HeatmapChartOptions = (HeatmapOptions & {
|
|
13
|
+
layout?: undefined;
|
|
14
|
+
}) | CalendarHeatmapOptions;
|
|
15
|
+
export declare const DAY = 86400000;
|
|
16
|
+
/** Bound sparse inputs too: three leap years of daily observations. */
|
|
17
|
+
export declare const CALENDAR_MAX_DAYS = 1098;
|
|
18
|
+
export declare function calendarDay(value: string): number;
|
|
19
|
+
/** Intl uses 1..7, JS dates use 0..6. Old engines use an explicit locale fallback. */
|
|
20
|
+
export declare function calendarWeekStart(locale?: string): number;
|
|
21
|
+
export declare const calendarWords: (locale?: string) => {
|
|
22
|
+
day: string;
|
|
23
|
+
less: string;
|
|
24
|
+
more: string;
|
|
25
|
+
moreIn: string;
|
|
26
|
+
moreOut: string;
|
|
27
|
+
};
|
|
28
|
+
export declare const calendarColor: (scale: CalendarHeatmapOptions["scale"], value: number) => "var(--k2b-flow-in-mark,#0891b2)" | "var(--k2b-flow-out-mark,#8b5cf6)" | "var(--stdlib-chart-c1,#3b82f6)";
|
|
29
|
+
export declare const pixels: (value: number) => string;
|
|
30
|
+
export declare function calendarLayout(spec: CalendarHeatmapOptions, size?: {
|
|
31
|
+
width: number;
|
|
32
|
+
height: number;
|
|
33
|
+
}): {
|
|
34
|
+
width: number;
|
|
35
|
+
height: number;
|
|
36
|
+
minWidth: number;
|
|
37
|
+
maxWidth: number;
|
|
38
|
+
firstMonday: number;
|
|
39
|
+
lastDay: number;
|
|
40
|
+
weekStart: number;
|
|
41
|
+
weeks: number;
|
|
42
|
+
min: number;
|
|
43
|
+
max: number;
|
|
44
|
+
absMax: number;
|
|
45
|
+
cell: number;
|
|
46
|
+
cellWidth: number;
|
|
47
|
+
top: number;
|
|
48
|
+
cells: {
|
|
49
|
+
date: string;
|
|
50
|
+
value: number;
|
|
51
|
+
index: number;
|
|
52
|
+
time: number;
|
|
53
|
+
week: number;
|
|
54
|
+
weekday: number;
|
|
55
|
+
x: number;
|
|
56
|
+
y: number;
|
|
57
|
+
intensity: number;
|
|
58
|
+
color: string;
|
|
59
|
+
}[];
|
|
60
|
+
};
|
|
61
|
+
/** A calendar viewport reserves the same content height in every request state. */
|
|
62
|
+
export declare function calendarViewportHeight(size: {
|
|
63
|
+
width: number;
|
|
64
|
+
height: number;
|
|
65
|
+
minWidth: number;
|
|
66
|
+
maxWidth: number;
|
|
67
|
+
}, availableWidth?: string): string;
|
|
@@ -1,66 +1,4 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
export type CalendarHeatmapOptions
|
|
3
|
-
layout: "calendar";
|
|
4
|
-
data: [string, number | null][];
|
|
5
|
-
scale: "sequential" | "diverging";
|
|
6
|
-
/** Unit shown beside each tooltip value. */
|
|
7
|
-
label?: string;
|
|
8
|
-
locale?: string;
|
|
9
|
-
format?: (value: number) => string;
|
|
10
|
-
displayWidth?: number;
|
|
11
|
-
};
|
|
12
|
-
export type HeatmapChartOptions = (HeatmapOptions & {
|
|
13
|
-
layout?: undefined;
|
|
14
|
-
}) | CalendarHeatmapOptions;
|
|
15
|
-
/** Bound sparse inputs too: three leap years of daily observations. */
|
|
16
|
-
export declare const CALENDAR_MAX_DAYS = 1098;
|
|
17
|
-
export declare function calendarDay(value: string): number;
|
|
18
|
-
/** Intl uses 1..7, JS dates use 0..6. Old engines use an explicit locale fallback. */
|
|
19
|
-
export declare function calendarWeekStart(locale?: string): number;
|
|
20
|
-
export declare const calendarWords: (locale?: string) => {
|
|
21
|
-
day: string;
|
|
22
|
-
less: string;
|
|
23
|
-
more: string;
|
|
24
|
-
moreIn: string;
|
|
25
|
-
moreOut: string;
|
|
26
|
-
};
|
|
27
|
-
export declare function calendarLayout(spec: CalendarHeatmapOptions, size?: {
|
|
28
|
-
width: number;
|
|
29
|
-
height: number;
|
|
30
|
-
}): {
|
|
31
|
-
width: number;
|
|
32
|
-
height: number;
|
|
33
|
-
minWidth: number;
|
|
34
|
-
maxWidth: number;
|
|
35
|
-
firstMonday: number;
|
|
36
|
-
lastDay: number;
|
|
37
|
-
weekStart: number;
|
|
38
|
-
weeks: number;
|
|
39
|
-
min: number;
|
|
40
|
-
max: number;
|
|
41
|
-
absMax: number;
|
|
42
|
-
cell: number;
|
|
43
|
-
cellWidth: number;
|
|
44
|
-
top: number;
|
|
45
|
-
cells: {
|
|
46
|
-
date: string;
|
|
47
|
-
value: number;
|
|
48
|
-
index: number;
|
|
49
|
-
time: number;
|
|
50
|
-
week: number;
|
|
51
|
-
weekday: number;
|
|
52
|
-
x: number;
|
|
53
|
-
y: number;
|
|
54
|
-
intensity: number;
|
|
55
|
-
color: string;
|
|
56
|
-
}[];
|
|
57
|
-
};
|
|
1
|
+
import { type CalendarHeatmapOptions, type HeatmapChartOptions } from "./calendar-layout";
|
|
2
|
+
export { CALENDAR_MAX_DAYS, type CalendarHeatmapOptions, calendarDay, calendarLayout, calendarViewportHeight, calendarWeekStart, calendarWords, type HeatmapChartOptions, } from "./calendar-layout";
|
|
58
3
|
export declare function renderCalendarSvg(spec: CalendarHeatmapOptions): string;
|
|
59
4
|
export declare const renderHeatmapSvg: (spec: HeatmapChartOptions) => string;
|
|
60
|
-
/** A calendar viewport reserves the same content height in every request state. */
|
|
61
|
-
export declare function calendarViewportHeight(size: {
|
|
62
|
-
width: number;
|
|
63
|
-
height: number;
|
|
64
|
-
minWidth: number;
|
|
65
|
-
maxWidth: number;
|
|
66
|
-
}, availableWidth?: string): string;
|
|
@@ -4,10 +4,17 @@ export { renderStateTimelineSvg, type StateTimelineChartOptions, type StateTimel
|
|
|
4
4
|
export { type ChartTimeAxis } from "../../content/chart-time-axis";
|
|
5
5
|
export { calendarTimeLabel, calendarTimeTicks, chartTimeStep } from "../../content/chart-time-calendar";
|
|
6
6
|
export { type AreaOptions, areaLayout, renderAreaSvg } from "./area";
|
|
7
|
+
export { balanceFlowColors, balanceFlowLayout, renderBalanceFlowSvg } from "./balance-flow";
|
|
8
|
+
export * from "./balance-flow-data";
|
|
9
|
+
export { balanceFlowFields } from "./balance-flow-fields";
|
|
10
|
+
export * from "./balance-flow-frame";
|
|
11
|
+
export { balanceFlowWords } from "./balance-flow-messages";
|
|
12
|
+
export * from "./balance-flow-size";
|
|
7
13
|
export { renderBarBaseSvg } from "./bar-base-render";
|
|
8
14
|
export { renderBarChartSvg } from "./bar-render";
|
|
9
15
|
export * from "./bubble";
|
|
10
|
-
export
|
|
16
|
+
export { renderCalendarSvg, renderHeatmapSvg } from "./calendar";
|
|
17
|
+
export { CALENDAR_MAX_DAYS, type CalendarHeatmapOptions, calendarDay, calendarLayout, calendarViewportHeight, calendarWeekStart, calendarWords, type HeatmapChartOptions, } from "./calendar-layout";
|
|
11
18
|
export { nestedDotOptions } from "./dot-options";
|
|
12
19
|
export { renderDotMatrixLayoutSvg } from "./dots";
|
|
13
20
|
export { type FunnelLayout, type FunnelOptions, funnelLayout, renderFunnelLayoutSvg, renderFunnelSvg } from "./funnel";
|
|
@@ -18,6 +25,7 @@ export { lineBase } from "./line-base";
|
|
|
18
25
|
export { renderLineDetailsSvg } from "./line-details";
|
|
19
26
|
export { lineDetailsEnabled, lineForecastLayout } from "./line-options";
|
|
20
27
|
export { map } from "./map";
|
|
28
|
+
export { balanceFlowRenderOptions, type ChartRenderSettings, chartNumberFormatters } from "./number-format";
|
|
21
29
|
export { chartSvgWithUiPalette } from "./palette";
|
|
22
30
|
export * from "./pareto";
|
|
23
31
|
export * from "./radar";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import type { ChartInput, ChartNumberFormat } from "../description";
|
|
2
|
+
import type { BalanceFlowOptions } from "./balance-flow-data";
|
|
3
|
+
type BalanceFlowInput = Extract<ChartInput, {
|
|
4
|
+
kind: "balanceFlow";
|
|
5
|
+
}>;
|
|
6
|
+
export type ChartRenderSettings = {
|
|
7
|
+
width?: number;
|
|
8
|
+
legend?: "svg" | "outside";
|
|
9
|
+
formats?: {
|
|
10
|
+
x?: (v: number) => string;
|
|
11
|
+
y?: (v: number) => string;
|
|
12
|
+
value?: (v: number) => string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Value precision and tick precision share the same style and units; ticks must remain distinct. A currency without
|
|
17
|
+
* `decimals` or compact notation writes cents only when one of the formatted `values` has them: 418,000 € rather than
|
|
18
|
+
* 418,000.00 €.
|
|
19
|
+
*/
|
|
20
|
+
export declare const chartNumberFormatters: (format: ChartNumberFormat | undefined, locale: string, values?: readonly number[]) => {
|
|
21
|
+
value: (v: number) => string;
|
|
22
|
+
tick: (v: number) => string;
|
|
23
|
+
};
|
|
24
|
+
/** BalanceFlow's formatting is loaded with its drawing, not with every app-frame prelude. */
|
|
25
|
+
export declare function balanceFlowRenderOptions(input: BalanceFlowInput, locale: string, options?: ChartRenderSettings): BalanceFlowOptions & {
|
|
26
|
+
kind: "balanceFlow";
|
|
27
|
+
};
|
|
28
|
+
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { renderStateTimelineSvg } from "../../content/chart-state-timeline";
|
|
2
2
|
import { renderAreaSvg } from "./area";
|
|
3
|
+
import { renderBalanceFlowSvg } from "./balance-flow";
|
|
3
4
|
import { renderBarChartSvg } from "./bar-render";
|
|
4
5
|
import { renderBubbleSvg } from "./bubble";
|
|
5
6
|
import { renderHeatmapSvg } from "./calendar";
|
|
@@ -36,6 +37,7 @@ export declare const chartRenderers: {
|
|
|
36
37
|
bubble: typeof renderBubbleSvg;
|
|
37
38
|
radar: typeof renderRadarSvg;
|
|
38
39
|
sankey: typeof renderSankeySvg;
|
|
40
|
+
balanceFlow: typeof renderBalanceFlowSvg;
|
|
39
41
|
};
|
|
40
42
|
type Kind = keyof typeof chartRenderers;
|
|
41
43
|
type ChartKinds = {
|
|
@@ -50,6 +50,23 @@ type Common = {
|
|
|
50
50
|
};
|
|
51
51
|
};
|
|
52
52
|
type Variants<N> = {
|
|
53
|
+
kind: "balanceFlow";
|
|
54
|
+
currency: string;
|
|
55
|
+
locale?: string;
|
|
56
|
+
periods: {
|
|
57
|
+
label: string;
|
|
58
|
+
opening: number;
|
|
59
|
+
inflows: {
|
|
60
|
+
label: string;
|
|
61
|
+
value: number;
|
|
62
|
+
}[];
|
|
63
|
+
outflows: {
|
|
64
|
+
label: string;
|
|
65
|
+
value: number;
|
|
66
|
+
}[];
|
|
67
|
+
closing: number;
|
|
68
|
+
}[];
|
|
69
|
+
} | {
|
|
53
70
|
kind: "waterfall";
|
|
54
71
|
start: {
|
|
55
72
|
label: string;
|
package/dist/types/charts.d.ts
CHANGED
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
export * from "./charts/core";
|
|
5
5
|
export type * from "./charts/description";
|
|
6
6
|
export type { ChartKindProps, ChartLabels, ChartProps, ChartRenderOptions } from "./content/Chart";
|
|
7
|
+
export { mountBalanceFlow } from "./content/chart-balance-flow";
|
|
8
|
+
export { mountBalanceFlowController } from "./content/chart-balance-flow-controller";
|
|
7
9
|
export { type BarChartLayout, type BarChartOptions, barChartLayout } from "./content/chart-bar";
|
|
8
10
|
export { calendarInspectionNavigation, mountCalendarScroll } from "./content/chart-calendar";
|
|
9
11
|
export { sankeyInspectionNavigation } from "./content/chart-sankey";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type JSX } from "solid-js";
|
|
2
|
+
import type { BalanceFlowOptions } from "../charts/core/balance-flow";
|
|
3
|
+
import { type BalanceFlowState } from "../charts/core/balance-flow-frame";
|
|
4
|
+
import type { ChartDatumRef, ChartSelection, ChartTooltipFormatter } from "../charts/core/inspection";
|
|
5
|
+
export type BalanceFlowUiProps = BalanceFlowOptions & {
|
|
6
|
+
class?: string;
|
|
7
|
+
style?: JSX.CSSProperties | string;
|
|
8
|
+
state?: BalanceFlowState;
|
|
9
|
+
selected?: ChartDatumRef | null;
|
|
10
|
+
error?: string;
|
|
11
|
+
onRetry?: () => void;
|
|
12
|
+
view?: "chart" | "table";
|
|
13
|
+
onViewChange?: (view: "chart" | "table") => void;
|
|
14
|
+
onSelect?: (selection: ChartSelection) => void;
|
|
15
|
+
tooltip?: ChartTooltipFormatter;
|
|
16
|
+
};
|
|
17
|
+
export declare function ChartBalanceFlow(props: BalanceFlowUiProps): JSX.Element;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { JSX } from "solid-js";
|
|
2
2
|
import type { ChartDrawingOptions } from "../charts/core/render";
|
|
3
|
+
import type { BalanceFlowUiProps } from "./ChartBalanceFlow";
|
|
3
4
|
import type { ChartCursor } from "./chart-cursor";
|
|
4
5
|
import { type ChartDatumRef, type ChartKind, type ChartSelection, type ChartTooltipFormatter } from "./chart-inspection-core";
|
|
5
6
|
/**
|
|
@@ -87,6 +88,6 @@ export type ChartProps = {
|
|
|
87
88
|
tooltip?: ChartTooltipFormatter;
|
|
88
89
|
/** Optional shared X cursor for line charts. */
|
|
89
90
|
cursor?: ChartCursor;
|
|
90
|
-
};
|
|
91
|
+
} & (K extends "balanceFlow" ? BalanceFlowUiProps : {});
|
|
91
92
|
}[ChartKind];
|
|
92
93
|
export declare const renderChartRoot: (props: ChartProps, renderChartSvg: typeof import("../charts/core/render").renderChartSvg) => JSX.Element;
|
|
@@ -100,12 +100,18 @@ export type DataTableProps<T> = {
|
|
|
100
100
|
renderCell?: DataTableRenderCell<T>;
|
|
101
101
|
renderHeader?: DataTableRenderHeader<T>;
|
|
102
102
|
footer?: DataTableFooter<T>;
|
|
103
|
+
/** More rows follow the loaded ones; the table's end shows the shared `LoadMore` edge. */
|
|
103
104
|
hasMore?: boolean;
|
|
105
|
+
/** The owner loads the next page right now. */
|
|
104
106
|
loadingMore?: boolean;
|
|
105
107
|
loading?: boolean;
|
|
106
108
|
/** Initial placeholder count, clamped to an integer from 1 to 50. Defaults to 5. */
|
|
107
109
|
loadingRows?: number;
|
|
108
|
-
|
|
110
|
+
/**
|
|
111
|
+
* Called when the end of the table comes within reach while `hasMore` is true, or by its "Load more" button.
|
|
112
|
+
* Append the next page to `rows`. A returned promise that rejects shows the error with "Try again".
|
|
113
|
+
*/
|
|
114
|
+
onLoadMore?: () => unknown;
|
|
109
115
|
empty?: JSX.Element;
|
|
110
116
|
density?: "compact" | "normal";
|
|
111
117
|
stickyHeader?: boolean;
|