@plumile/ui 0.1.134 → 0.1.142
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/README.md +129 -15
- package/lib/esm/admin/organisms/admin_sidebar/AdminSidebar.js +4 -4
- package/lib/esm/admin/organisms/admin_sidebar/adminSidebar.css.js +0 -2
- package/lib/esm/admin/organisms/admin_topbar/adminTopbar.css.js +1 -0
- package/lib/esm/admin/templates/admin_shell_layout/AdminShellLayout.js +2 -2
- package/lib/esm/admin/templates/admin_shell_layout/AdminShellLayout.js.map +1 -1
- package/lib/esm/atomic/atoms/badge/Badge.js.map +1 -1
- package/lib/esm/atomic/atoms/error_message/ErrorMessage.js +9 -8
- package/lib/esm/atomic/atoms/error_message/ErrorMessage.js.map +1 -1
- package/lib/esm/atomic/atoms/error_message/errorMessage.css.js +1 -0
- package/lib/esm/atomic/molecules/card/Card.js +17 -19
- package/lib/esm/atomic/molecules/card/Card.js.map +1 -1
- package/lib/esm/atomic/molecules/empty-state/EmptyState.css.js +80 -2
- package/lib/esm/atomic/molecules/empty-state/EmptyState.css.js.map +1 -1
- package/lib/esm/atomic/molecules/empty-state/EmptyState.js +50 -28
- package/lib/esm/atomic/molecules/empty-state/EmptyState.js.map +1 -1
- package/lib/esm/atomic/molecules/form_error/FormError.js +29 -19
- package/lib/esm/atomic/molecules/form_error/FormError.js.map +1 -1
- package/lib/esm/atomic/molecules/form_error/formError.css.js +1 -1
- package/lib/esm/atomic/molecules/form_error/formError.css.js.map +1 -1
- package/lib/esm/atomic/molecules/markdown/components/MarkdownDelete.css.js +0 -1
- package/lib/esm/atomic/molecules/markdown/components/MarkdownHeading.css.js +1 -0
- package/lib/esm/atomic/molecules/tabs/Tabs.js +82 -28
- package/lib/esm/atomic/molecules/tabs/Tabs.js.map +1 -1
- package/lib/esm/atomic/molecules/tabs/tabs.css.js +50 -8
- package/lib/esm/atomic/molecules/tabs/tabs.css.js.map +1 -1
- package/lib/esm/atomic/organisms/sidebar/NavigationSidebar.js +48 -48
- package/lib/esm/atomic/organisms/sidebar/NavigationSidebar.js.map +1 -1
- package/lib/esm/backoffice/atoms/status_badge/StatusBadge.js.map +1 -1
- package/lib/esm/backoffice/molecules/backoffice_audit_metadata_panel/BackofficeAuditMetadataPanel.js +38 -0
- package/lib/esm/backoffice/molecules/backoffice_audit_metadata_panel/BackofficeAuditMetadataPanel.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_field/BackofficeDetailField.js +35 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_field/BackofficeDetailField.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_field/backofficeDetailField.css.js +16 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_field/backofficeDetailField.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_flag_tag/BackofficeDetailFlagTag.js +25 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_flag_tag/BackofficeDetailFlagTag.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_flag_tag/backofficeDetailFlagTag.css.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_flag_tag/backofficeDetailFlagTag.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_section/BackofficeDetailSection.js +37 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_section/BackofficeDetailSection.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_section/backofficeDetailSection.css.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_section/backofficeDetailSection.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_tagged_value/BackofficeDetailTaggedValue.js +19 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_tagged_value/BackofficeDetailTaggedValue.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_tagged_value/backofficeDetailTaggedValue.css.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_detail_tagged_value/backofficeDetailTaggedValue.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_empty_state/BackofficeEmptyState.js +15 -32
- package/lib/esm/backoffice/molecules/backoffice_empty_state/BackofficeEmptyState.js.map +1 -1
- package/lib/esm/backoffice/molecules/backoffice_enum_label/BackofficeEnumLabel.js +11 -0
- package/lib/esm/backoffice/molecules/backoffice_enum_label/BackofficeEnumLabel.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_form_section/BackofficeFormSection.js +17 -18
- package/lib/esm/backoffice/molecules/backoffice_form_section/BackofficeFormSection.js.map +1 -1
- package/lib/esm/backoffice/molecules/backoffice_json_viewer/LazyBackofficeJsonViewer.helpers.js +12 -0
- package/lib/esm/backoffice/molecules/backoffice_json_viewer/LazyBackofficeJsonViewer.helpers.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_json_viewer/LazyBackofficeJsonViewer.js +15 -20
- package/lib/esm/backoffice/molecules/backoffice_json_viewer/LazyBackofficeJsonViewer.js.map +1 -1
- package/lib/esm/backoffice/molecules/backoffice_key_value_list/BackofficeKeyValueList.js +23 -16
- package/lib/esm/backoffice/molecules/backoffice_key_value_list/BackofficeKeyValueList.js.map +1 -1
- package/lib/esm/backoffice/molecules/backoffice_key_value_list/backofficeKeyValueList.css.js +2 -2
- package/lib/esm/backoffice/molecules/backoffice_key_value_list/backofficeKeyValueList.css.js.map +1 -1
- package/lib/esm/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.helpers.js +11 -0
- package/lib/esm/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.helpers.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.js +55 -0
- package/lib/esm/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_list_footer/backofficeListFooter.css.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_list_footer/backofficeListFooter.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_payload_viewer/BackofficePayloadViewer.helpers.js +15 -0
- package/lib/esm/backoffice/molecules/backoffice_payload_viewer/BackofficePayloadViewer.helpers.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_payload_viewer/BackofficePayloadViewer.js +63 -0
- package/lib/esm/backoffice/molecules/backoffice_payload_viewer/BackofficePayloadViewer.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_payload_viewer/backofficePayloadViewer.css.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_payload_viewer/backofficePayloadViewer.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_picker/BackofficePicker.js +76 -0
- package/lib/esm/backoffice/molecules/backoffice_picker/BackofficePicker.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_picker/backofficePicker.css.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_picker/backofficePicker.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_reference_value/BackofficeReferenceValue.js +23 -0
- package/lib/esm/backoffice/molecules/backoffice_reference_value/BackofficeReferenceValue.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_reference_value/backofficeReferenceValue.css.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_reference_value/backofficeReferenceValue.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_scope_stack/BackofficeScopeStack.js +18 -0
- package/lib/esm/backoffice/molecules/backoffice_scope_stack/BackofficeScopeStack.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_status_group/BackofficeStatusGroup.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_status_group/BackofficeStatusGroup.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_status_meta_badge/BackofficeStatusMetaBadge.js +28 -0
- package/lib/esm/backoffice/molecules/backoffice_status_meta_badge/BackofficeStatusMetaBadge.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_status_meta_badge/backofficeStatusMetaBadge.css.js +8 -0
- package/lib/esm/backoffice/molecules/backoffice_status_meta_badge/backofficeStatusMetaBadge.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_toolbar/BackofficeToolbar.js +60 -0
- package/lib/esm/backoffice/molecules/backoffice_toolbar/BackofficeToolbar.js.map +1 -0
- package/lib/esm/backoffice/molecules/backoffice_toolbar/backofficeToolbar.css.js +14 -0
- package/lib/esm/backoffice/molecules/backoffice_toolbar/backofficeToolbar.css.js.map +1 -0
- package/lib/esm/backoffice/molecules/bulk_actions_bar/bulkActionsBar.css.js +1 -1
- package/lib/esm/backoffice/molecules/bulk_actions_bar/bulkActionsBar.css.js.map +1 -1
- package/lib/esm/backoffice/molecules/confirm_dialog/ConfirmDialog.js +3 -3
- package/lib/esm/backoffice/molecules/confirm_dialog/ConfirmDialog.js.map +1 -1
- package/lib/esm/backoffice/molecules/global_search_input/GlobalSearchInput.js +4 -4
- package/lib/esm/backoffice/molecules/sidebar_collapse_toggle/sidebarCollapseToggle.css.js +1 -1
- package/lib/esm/backoffice/molecules/sidebar_collapse_toggle/sidebarCollapseToggle.css.js.map +1 -1
- package/lib/esm/backoffice/molecules/sidebar_nav_item/SidebarNavItem.js +60 -60
- package/lib/esm/backoffice/molecules/sidebar_nav_item/SidebarNavItem.js.map +1 -1
- package/lib/esm/backoffice/molecules/sidebar_nav_item/sidebarNavItem.css.js +2 -2
- package/lib/esm/backoffice/molecules/sidebar_nav_item/sidebarNavItem.css.js.map +1 -1
- package/lib/esm/backoffice/molecules/sidebar_nav_section/SidebarNavSection.js +96 -96
- package/lib/esm/backoffice/molecules/sidebar_nav_section/SidebarNavSection.js.map +1 -1
- package/lib/esm/backoffice/molecules/sidebar_nav_section/sidebarNavSection.css.js +2 -2
- package/lib/esm/backoffice/molecules/sidebar_nav_section/sidebarNavSection.css.js.map +1 -1
- package/lib/esm/backoffice/molecules/sidebar_profile_menu/BackofficeSidebarProfileMenu.js +52 -52
- package/lib/esm/backoffice/molecules/sidebar_profile_menu/BackofficeSidebarProfileMenu.js.map +1 -1
- package/lib/esm/backoffice/molecules/sidebar_profile_menu/sidebarProfileMenu.css.js +6 -6
- package/lib/esm/backoffice/molecules/sidebar_profile_menu/sidebarProfileMenu.css.js.map +1 -1
- package/lib/esm/backoffice/organisms/audit_timeline/AuditTimeline.js +69 -34
- package/lib/esm/backoffice/organisms/audit_timeline/AuditTimeline.js.map +1 -1
- package/lib/esm/backoffice/organisms/audit_timeline/auditTimeline.css.js +22 -2
- package/lib/esm/backoffice/organisms/audit_timeline/auditTimeline.css.js.map +1 -1
- package/lib/esm/backoffice/organisms/backoffice_data_table/BackofficeDataTable.js +4 -4
- package/lib/esm/backoffice/organisms/backoffice_data_table/BackofficeDataTable.js.map +1 -1
- package/lib/esm/backoffice/templates/detail_page_template/DetailPageTemplate.js +70 -40
- package/lib/esm/backoffice/templates/detail_page_template/DetailPageTemplate.js.map +1 -1
- package/lib/esm/backoffice/templates/detail_page_template/detailPageTemplate.css.js +66 -3
- package/lib/esm/backoffice/templates/detail_page_template/detailPageTemplate.css.js.map +1 -1
- package/lib/esm/components/dashboard/activity_card/ActivityCard.js +4 -4
- package/lib/esm/components/dashboard/dashboard_metric_group/DashboardMetricGroup.css.js +9 -0
- package/lib/esm/components/dashboard/dashboard_metric_group/DashboardMetricGroup.css.js.map +1 -0
- package/lib/esm/components/dashboard/dashboard_metric_group/DashboardMetricGroup.js +30 -0
- package/lib/esm/components/dashboard/dashboard_metric_group/DashboardMetricGroup.js.map +1 -0
- package/lib/esm/components/dashboard/dashboard_panel/DashboardPanel.css.js +8 -0
- package/lib/esm/components/dashboard/dashboard_panel/DashboardPanel.css.js.map +1 -0
- package/lib/esm/components/dashboard/dashboard_panel/DashboardPanel.js +16 -0
- package/lib/esm/components/dashboard/dashboard_panel/DashboardPanel.js.map +1 -0
- package/lib/esm/components/dashboard/dashboard_quick_actions/DashboardQuickActions.css.js +8 -0
- package/lib/esm/components/dashboard/dashboard_quick_actions/DashboardQuickActions.css.js.map +1 -0
- package/lib/esm/components/dashboard/dashboard_quick_actions/DashboardQuickActions.js +27 -0
- package/lib/esm/components/dashboard/dashboard_quick_actions/DashboardQuickActions.js.map +1 -0
- package/lib/esm/components/dashboard/dashboard_status_list/DashboardStatusList.css.js +8 -0
- package/lib/esm/components/dashboard/dashboard_status_list/DashboardStatusList.css.js.map +1 -0
- package/lib/esm/components/dashboard/dashboard_status_list/DashboardStatusList.js +28 -0
- package/lib/esm/components/dashboard/dashboard_status_list/DashboardStatusList.js.map +1 -0
- package/lib/esm/components/dashboard/metric_card/MetricCard.css.js +30 -2
- package/lib/esm/components/dashboard/metric_card/MetricCard.css.js.map +1 -1
- package/lib/esm/components/dashboard/metric_card/MetricCard.js +40 -26
- package/lib/esm/components/dashboard/metric_card/MetricCard.js.map +1 -1
- package/lib/esm/components/dashboard/metric_tile_group/MetricTileGroup.css.js +23 -2
- package/lib/esm/components/dashboard/metric_tile_group/MetricTileGroup.css.js.map +1 -1
- package/lib/esm/components/dashboard/metric_tile_group/MetricTileGroup.js +16 -4
- package/lib/esm/components/dashboard/metric_tile_group/MetricTileGroup.js.map +1 -1
- package/lib/esm/components/dashboard/status_summary_panel/StatusSummaryPanel.js +4 -4
- package/lib/esm/components/dashboard/timeline_event_row/TimelineEventRow.css.js +14 -2
- package/lib/esm/components/dashboard/timeline_event_row/TimelineEventRow.css.js.map +1 -1
- package/lib/esm/components/dashboard/timeline_event_row/TimelineEventRow.js +46 -25
- package/lib/esm/components/dashboard/timeline_event_row/TimelineEventRow.js.map +1 -1
- package/lib/esm/components/data-table/DataTable.css.js +19 -19
- package/lib/esm/components/data-table/DataTable.css.js.map +1 -1
- package/lib/esm/components/data-table/DataTable.js +142 -76
- package/lib/esm/components/data-table/DataTable.js.map +1 -1
- package/lib/esm/components/data-table/ResponsiveRecordList.js.map +1 -1
- package/lib/esm/components/data-table/VirtualizedConnectionTable.css.js +2 -2
- package/lib/esm/components/data-table/VirtualizedConnectionTable.css.js.map +1 -1
- package/lib/esm/components/data-table/VirtualizedConnectionTable.js +177 -170
- package/lib/esm/components/data-table/VirtualizedConnectionTable.js.map +1 -1
- package/lib/esm/components/feedback/InlineBanner.js +49 -0
- package/lib/esm/components/feedback/InlineBanner.js.map +1 -0
- package/lib/esm/components/feedback/OperationFeedback.css.js +2 -2
- package/lib/esm/components/feedback/OperationFeedback.css.js.map +1 -1
- package/lib/esm/components/feedback/OperationFeedback.js +20 -24
- package/lib/esm/components/feedback/OperationFeedback.js.map +1 -1
- package/lib/esm/components/feedback/inlineBanner.css.js +19 -0
- package/lib/esm/components/feedback/inlineBanner.css.js.map +1 -0
- package/lib/esm/components/infinite/InfiniteScrollTrigger.js +31 -23
- package/lib/esm/components/infinite/InfiniteScrollTrigger.js.map +1 -1
- package/lib/esm/components/layout/ActionPanel.css.js +2 -2
- package/lib/esm/components/layout/ActionPanel.css.js.map +1 -1
- package/lib/esm/components/layout/ActionPanel.js +29 -35
- package/lib/esm/components/layout/ActionPanel.js.map +1 -1
- package/lib/esm/components/layout/PageShell.css.js +2 -20
- package/lib/esm/components/layout/PageShell.css.js.map +1 -1
- package/lib/esm/components/layout/PageShell.js +155 -279
- package/lib/esm/components/layout/PageShell.js.map +1 -1
- package/lib/esm/components/layout/ResizableSplitView.css.js +8 -0
- package/lib/esm/components/layout/ResizableSplitView.css.js.map +1 -0
- package/lib/esm/components/layout/ResizableSplitView.js +176 -0
- package/lib/esm/components/layout/ResizableSplitView.js.map +1 -0
- package/lib/esm/components/layout/Surface.css.js +41 -0
- package/lib/esm/components/layout/Surface.css.js.map +1 -0
- package/lib/esm/components/layout/Surface.js +61 -0
- package/lib/esm/components/layout/Surface.js.map +1 -0
- package/lib/esm/components/layout/toolbar/Toolbar.css.js +64 -0
- package/lib/esm/components/layout/toolbar/Toolbar.css.js.map +1 -0
- package/lib/esm/components/layout/toolbar/Toolbar.js +36 -0
- package/lib/esm/components/layout/toolbar/Toolbar.js.map +1 -0
- package/lib/esm/components/navigation/sidebar/SidebarNavigation.js +89 -0
- package/lib/esm/components/navigation/sidebar/SidebarNavigation.js.map +1 -0
- package/lib/esm/components/navigation/sidebar/SidebarNavigationItem.js +2 -0
- package/lib/esm/components/navigation/sidebar/SidebarNavigationSection.js +2 -0
- package/lib/esm/components/navigation/sidebar/SidebarProfileMenu.js +2 -0
- package/lib/esm/components/navigation/sidebar/sidebarNavigation.css.js +48 -0
- package/lib/esm/components/navigation/sidebar/sidebarNavigation.css.js.map +1 -0
- package/lib/esm/components/subscriptions/RefetchNeededBanner.js +16 -23
- package/lib/esm/components/subscriptions/RefetchNeededBanner.js.map +1 -1
- package/lib/esm/i18n/locales/en/ui.js +16 -5
- package/lib/esm/i18n/locales/en/ui.js.map +1 -1
- package/lib/esm/i18n/locales/fr/ui.js +16 -5
- package/lib/esm/i18n/locales/fr/ui.js.map +1 -1
- package/lib/esm/index.js +237 -233
- package/lib/esm/internal/data-table/virtualization.js +1 -1
- package/lib/esm/internal/data-table/virtualization.js.map +1 -1
- package/lib/esm/internal/infinite/infiniteLoad.js +23 -0
- package/lib/esm/internal/infinite/infiniteLoad.js.map +1 -0
- package/lib/esm/node_modules/dompurify/dist/purify.es.js +290 -246
- package/lib/esm/node_modules/dompurify/dist/purify.es.js.map +1 -1
- package/lib/esm/node_modules/katex/dist/katex.js +1561 -1599
- package/lib/esm/node_modules/katex/dist/katex.js.map +1 -1
- package/lib/esm/style.css +1 -1
- package/lib/esm/theme/backofficeTheme.css.js +100 -0
- package/lib/esm/theme/backofficeTheme.css.js.map +1 -1
- package/lib/esm/theme/publicTheme.css.js +100 -0
- package/lib/esm/theme/publicTheme.css.js.map +1 -1
- package/lib/esm/theme/theme.css.js +200 -0
- package/lib/esm/theme/themeContract.css.js +359 -309
- package/lib/esm/theme/themeContract.css.js.map +1 -1
- package/lib/types/admin/templates/admin_shell_layout/AdminShellLayout.d.ts +4 -4
- package/lib/types/admin/templates/admin_shell_layout/AdminShellLayout.d.ts.map +1 -1
- package/lib/types/atomic/atoms/badge/Badge.d.ts +3 -3
- package/lib/types/atomic/atoms/badge/Badge.d.ts.map +1 -1
- package/lib/types/atomic/atoms/error_message/ErrorMessage.d.ts +1 -1
- package/lib/types/atomic/atoms/error_message/ErrorMessage.d.ts.map +1 -1
- package/lib/types/atomic/molecules/card/Card.d.ts.map +1 -1
- package/lib/types/atomic/molecules/empty-state/EmptyState.css.d.ts +56 -5
- package/lib/types/atomic/molecules/empty-state/EmptyState.css.d.ts.map +1 -1
- package/lib/types/atomic/molecules/empty-state/EmptyState.d.ts +14 -4
- package/lib/types/atomic/molecules/empty-state/EmptyState.d.ts.map +1 -1
- package/lib/types/atomic/molecules/form_error/FormError.d.ts +5 -2
- package/lib/types/atomic/molecules/form_error/FormError.d.ts.map +1 -1
- package/lib/types/atomic/molecules/form_error/formError.css.d.ts.map +1 -1
- package/lib/types/atomic/molecules/tabs/Tabs.d.ts +16 -7
- package/lib/types/atomic/molecules/tabs/Tabs.d.ts.map +1 -1
- package/lib/types/atomic/molecules/tabs/tabs.css.d.ts +21 -2
- package/lib/types/atomic/molecules/tabs/tabs.css.d.ts.map +1 -1
- package/lib/types/backoffice/atoms/status_badge/StatusBadge.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/backoffice_audit_metadata_panel/BackofficeAuditMetadataPanel.d.ts +21 -0
- package/lib/types/backoffice/molecules/backoffice_audit_metadata_panel/BackofficeAuditMetadataPanel.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_detail_field/BackofficeDetailField.d.ts +17 -0
- package/lib/types/backoffice/molecules/backoffice_detail_field/BackofficeDetailField.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_detail_field/backofficeDetailField.css.d.ts +14 -0
- package/lib/types/backoffice/molecules/backoffice_detail_field/backofficeDetailField.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_detail_flag_tag/BackofficeDetailFlagTag.d.ts +11 -0
- package/lib/types/backoffice/molecules/backoffice_detail_flag_tag/BackofficeDetailFlagTag.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_detail_flag_tag/backofficeDetailFlagTag.css.d.ts +4 -0
- package/lib/types/backoffice/molecules/backoffice_detail_flag_tag/backofficeDetailFlagTag.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_detail_section/BackofficeDetailSection.d.ts +12 -0
- package/lib/types/backoffice/molecules/backoffice_detail_section/BackofficeDetailSection.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_detail_section/backofficeDetailSection.css.d.ts +6 -0
- package/lib/types/backoffice/molecules/backoffice_detail_section/backofficeDetailSection.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_detail_tagged_value/BackofficeDetailTaggedValue.d.ts +13 -0
- package/lib/types/backoffice/molecules/backoffice_detail_tagged_value/BackofficeDetailTaggedValue.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_detail_tagged_value/backofficeDetailTaggedValue.css.d.ts +3 -0
- package/lib/types/backoffice/molecules/backoffice_detail_tagged_value/backofficeDetailTaggedValue.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_empty_state/BackofficeEmptyState.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/backoffice_enum_label/BackofficeEnumLabel.d.ts +9 -0
- package/lib/types/backoffice/molecules/backoffice_enum_label/BackofficeEnumLabel.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_form_section/BackofficeFormSection.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/backoffice_json_viewer/LazyBackofficeJsonViewer.d.ts +0 -3
- package/lib/types/backoffice/molecules/backoffice_json_viewer/LazyBackofficeJsonViewer.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/backoffice_json_viewer/LazyBackofficeJsonViewer.helpers.d.ts +5 -0
- package/lib/types/backoffice/molecules/backoffice_json_viewer/LazyBackofficeJsonViewer.helpers.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_key_value_list/BackofficeKeyValueList.d.ts +8 -2
- package/lib/types/backoffice/molecules/backoffice_key_value_list/BackofficeKeyValueList.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/backoffice_key_value_list/backofficeKeyValueList.css.d.ts +3 -0
- package/lib/types/backoffice/molecules/backoffice_key_value_list/backofficeKeyValueList.css.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.d.ts +23 -0
- package/lib/types/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.helpers.d.ts +25 -0
- package/lib/types/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.helpers.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/{backoffice_infinite_list_status/backofficeInfiniteListStatus.css.d.ts → backoffice_list_footer/backofficeListFooter.css.d.ts} +3 -2
- package/lib/types/backoffice/molecules/backoffice_list_footer/backofficeListFooter.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_payload_viewer/BackofficePayloadViewer.d.ts +26 -0
- package/lib/types/backoffice/molecules/backoffice_payload_viewer/BackofficePayloadViewer.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_payload_viewer/BackofficePayloadViewer.helpers.d.ts +7 -0
- package/lib/types/backoffice/molecules/backoffice_payload_viewer/BackofficePayloadViewer.helpers.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_payload_viewer/backofficePayloadViewer.css.d.ts +6 -0
- package/lib/types/backoffice/molecules/backoffice_payload_viewer/backofficePayloadViewer.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_picker/BackofficePicker.d.ts +35 -0
- package/lib/types/backoffice/molecules/backoffice_picker/BackofficePicker.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_picker/backofficePicker.css.d.ts +9 -0
- package/lib/types/backoffice/molecules/backoffice_picker/backofficePicker.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_reference_value/BackofficeReferenceValue.d.ts +10 -0
- package/lib/types/backoffice/molecules/backoffice_reference_value/BackofficeReferenceValue.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_reference_value/backofficeReferenceValue.css.d.ts +3 -0
- package/lib/types/backoffice/molecules/backoffice_reference_value/backofficeReferenceValue.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_scope_stack/BackofficeScopeStack.d.ts +15 -0
- package/lib/types/backoffice/molecules/backoffice_scope_stack/BackofficeScopeStack.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_status_group/BackofficeStatusGroup.d.ts +8 -0
- package/lib/types/backoffice/molecules/backoffice_status_group/BackofficeStatusGroup.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_status_meta_badge/BackofficeStatusMetaBadge.d.ts +14 -0
- package/lib/types/backoffice/molecules/backoffice_status_meta_badge/BackofficeStatusMetaBadge.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_status_meta_badge/backofficeStatusMetaBadge.css.d.ts +2 -0
- package/lib/types/backoffice/molecules/backoffice_status_meta_badge/backofficeStatusMetaBadge.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_toolbar/BackofficeToolbar.d.ts +22 -0
- package/lib/types/backoffice/molecules/backoffice_toolbar/BackofficeToolbar.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/backoffice_toolbar/backofficeToolbar.css.d.ts +18 -0
- package/lib/types/backoffice/molecules/backoffice_toolbar/backofficeToolbar.css.d.ts.map +1 -0
- package/lib/types/backoffice/molecules/bulk_actions_bar/bulkActionsBar.css.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/sidebar_collapse_toggle/sidebarCollapseToggle.css.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/sidebar_nav_item/SidebarNavItem.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/sidebar_nav_item/sidebarNavItem.css.d.ts +1 -0
- package/lib/types/backoffice/molecules/sidebar_nav_item/sidebarNavItem.css.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/sidebar_nav_section/SidebarNavSection.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/sidebar_nav_section/sidebarNavSection.css.d.ts +2 -0
- package/lib/types/backoffice/molecules/sidebar_nav_section/sidebarNavSection.css.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/sidebar_profile_menu/BackofficeSidebarProfileMenu.d.ts.map +1 -1
- package/lib/types/backoffice/molecules/sidebar_profile_menu/sidebarProfileMenu.css.d.ts +8 -0
- package/lib/types/backoffice/molecules/sidebar_profile_menu/sidebarProfileMenu.css.d.ts.map +1 -1
- package/lib/types/backoffice/organisms/audit_timeline/AuditTimeline.d.ts +20 -2
- package/lib/types/backoffice/organisms/audit_timeline/AuditTimeline.d.ts.map +1 -1
- package/lib/types/backoffice/organisms/audit_timeline/auditTimeline.css.d.ts +32 -2
- package/lib/types/backoffice/organisms/audit_timeline/auditTimeline.css.d.ts.map +1 -1
- package/lib/types/backoffice/organisms/backoffice_data_table/BackofficeDataTable.d.ts +2 -2
- package/lib/types/backoffice/organisms/backoffice_data_table/BackofficeDataTable.d.ts.map +1 -1
- package/lib/types/backoffice/templates/detail_page_template/DetailPageTemplate.d.ts +12 -1
- package/lib/types/backoffice/templates/detail_page_template/DetailPageTemplate.d.ts.map +1 -1
- package/lib/types/backoffice/templates/detail_page_template/detailPageTemplate.css.d.ts +25 -4
- package/lib/types/backoffice/templates/detail_page_template/detailPageTemplate.css.d.ts.map +1 -1
- package/lib/types/components/dashboard/dashboard_metric_group/DashboardMetricGroup.css.d.ts +4 -0
- package/lib/types/components/dashboard/dashboard_metric_group/DashboardMetricGroup.css.d.ts.map +1 -0
- package/lib/types/components/dashboard/dashboard_metric_group/DashboardMetricGroup.d.ts +19 -0
- package/lib/types/components/dashboard/dashboard_metric_group/DashboardMetricGroup.d.ts.map +1 -0
- package/lib/types/components/dashboard/dashboard_panel/DashboardPanel.css.d.ts +2 -0
- package/lib/types/components/dashboard/dashboard_panel/DashboardPanel.css.d.ts.map +1 -0
- package/lib/types/components/dashboard/dashboard_panel/DashboardPanel.d.ts +11 -0
- package/lib/types/components/dashboard/dashboard_panel/DashboardPanel.d.ts.map +1 -0
- package/lib/types/components/dashboard/dashboard_quick_actions/DashboardQuickActions.css.d.ts +5 -0
- package/lib/types/components/dashboard/dashboard_quick_actions/DashboardQuickActions.css.d.ts.map +1 -0
- package/lib/types/components/dashboard/dashboard_quick_actions/DashboardQuickActions.d.ts +14 -0
- package/lib/types/components/dashboard/dashboard_quick_actions/DashboardQuickActions.d.ts.map +1 -0
- package/lib/types/components/dashboard/dashboard_status_list/DashboardStatusList.css.d.ts +6 -0
- package/lib/types/components/dashboard/dashboard_status_list/DashboardStatusList.css.d.ts.map +1 -0
- package/lib/types/components/dashboard/dashboard_status_list/DashboardStatusList.d.ts +14 -0
- package/lib/types/components/dashboard/dashboard_status_list/DashboardStatusList.d.ts.map +1 -0
- package/lib/types/components/dashboard/metric_card/MetricCard.css.d.ts +38 -1
- package/lib/types/components/dashboard/metric_card/MetricCard.css.d.ts.map +1 -1
- package/lib/types/components/dashboard/metric_card/MetricCard.d.ts +7 -1
- package/lib/types/components/dashboard/metric_card/MetricCard.d.ts.map +1 -1
- package/lib/types/components/dashboard/metric_tile_group/MetricTileGroup.css.d.ts +17 -1
- package/lib/types/components/dashboard/metric_tile_group/MetricTileGroup.css.d.ts.map +1 -1
- package/lib/types/components/dashboard/metric_tile_group/MetricTileGroup.d.ts +4 -1
- package/lib/types/components/dashboard/metric_tile_group/MetricTileGroup.d.ts.map +1 -1
- package/lib/types/components/dashboard/timeline_event_row/TimelineEventRow.css.d.ts +31 -2
- package/lib/types/components/dashboard/timeline_event_row/TimelineEventRow.css.d.ts.map +1 -1
- package/lib/types/components/dashboard/timeline_event_row/TimelineEventRow.d.ts +8 -3
- package/lib/types/components/dashboard/timeline_event_row/TimelineEventRow.d.ts.map +1 -1
- package/lib/types/components/data-table/DataTable.css.d.ts +1 -0
- package/lib/types/components/data-table/DataTable.css.d.ts.map +1 -1
- package/lib/types/components/data-table/DataTable.d.ts +54 -3
- package/lib/types/components/data-table/DataTable.d.ts.map +1 -1
- package/lib/types/components/data-table/ResponsiveRecordList.d.ts +1 -4
- package/lib/types/components/data-table/ResponsiveRecordList.d.ts.map +1 -1
- package/lib/types/components/data-table/VirtualizedConnectionTable.css.d.ts +0 -1
- package/lib/types/components/data-table/VirtualizedConnectionTable.css.d.ts.map +1 -1
- package/lib/types/components/data-table/VirtualizedConnectionTable.d.ts +11 -5
- package/lib/types/components/data-table/VirtualizedConnectionTable.d.ts.map +1 -1
- package/lib/types/{backoffice/molecules/inline_banner → components/feedback}/InlineBanner.d.ts +4 -2
- package/lib/types/components/feedback/InlineBanner.d.ts.map +1 -0
- package/lib/types/components/feedback/OperationFeedback.css.d.ts +0 -1
- package/lib/types/components/feedback/OperationFeedback.css.d.ts.map +1 -1
- package/lib/types/components/feedback/OperationFeedback.d.ts.map +1 -1
- package/lib/types/components/feedback/inlineBanner.css.d.ts.map +1 -0
- package/lib/types/components/infinite/InfiniteScrollTrigger.d.ts.map +1 -1
- package/lib/types/components/layout/ActionPanel.css.d.ts +1 -0
- package/lib/types/components/layout/ActionPanel.css.d.ts.map +1 -1
- package/lib/types/components/layout/ActionPanel.d.ts.map +1 -1
- package/lib/types/components/layout/PageShell.css.d.ts +1 -14
- package/lib/types/components/layout/PageShell.css.d.ts.map +1 -1
- package/lib/types/components/layout/PageShell.d.ts +1 -3
- package/lib/types/components/layout/PageShell.d.ts.map +1 -1
- package/lib/types/components/layout/ResizableSplitView.css.d.ts +8 -0
- package/lib/types/components/layout/ResizableSplitView.css.d.ts.map +1 -0
- package/lib/types/components/layout/ResizableSplitView.d.ts +27 -0
- package/lib/types/components/layout/ResizableSplitView.d.ts.map +1 -0
- package/lib/types/components/layout/Surface.css.d.ts +31 -0
- package/lib/types/components/layout/Surface.css.d.ts.map +1 -0
- package/lib/types/components/layout/Surface.d.ts +30 -0
- package/lib/types/components/layout/Surface.d.ts.map +1 -0
- package/lib/types/components/layout/toolbar/Toolbar.css.d.ts +40 -0
- package/lib/types/components/layout/toolbar/Toolbar.css.d.ts.map +1 -0
- package/lib/types/components/layout/toolbar/Toolbar.d.ts +35 -0
- package/lib/types/components/layout/toolbar/Toolbar.d.ts.map +1 -0
- package/lib/types/components/navigation/sidebar/SidebarNavigation.d.ts +57 -0
- package/lib/types/components/navigation/sidebar/SidebarNavigation.d.ts.map +1 -0
- package/lib/types/components/navigation/sidebar/SidebarNavigationItem.d.ts +2 -0
- package/lib/types/components/navigation/sidebar/SidebarNavigationItem.d.ts.map +1 -0
- package/lib/types/components/navigation/sidebar/SidebarNavigationSection.d.ts +2 -0
- package/lib/types/components/navigation/sidebar/SidebarNavigationSection.d.ts.map +1 -0
- package/lib/types/components/navigation/sidebar/SidebarProfileMenu.d.ts +2 -0
- package/lib/types/components/navigation/sidebar/SidebarProfileMenu.d.ts.map +1 -0
- package/lib/types/components/navigation/sidebar/sidebarNavigation.css.d.ts +19 -0
- package/lib/types/components/navigation/sidebar/sidebarNavigation.css.d.ts.map +1 -0
- package/lib/types/components/subscriptions/RefetchNeededBanner.d.ts.map +1 -1
- package/lib/types/i18n/resources.d.ts +32 -14
- package/lib/types/i18n/resources.d.ts.map +1 -1
- package/lib/types/index.d.ts +33 -33
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/internal/data-table/virtualization.d.ts +2 -2
- package/lib/types/internal/data-table/virtualization.d.ts.map +1 -1
- package/lib/types/internal/infinite/infiniteLoad.d.ts +27 -0
- package/lib/types/internal/infinite/infiniteLoad.d.ts.map +1 -0
- package/lib/types/theme/backofficeTheme.css.d.ts +100 -0
- package/lib/types/theme/backofficeTheme.css.d.ts.map +1 -1
- package/lib/types/theme/publicTheme.css.d.ts +100 -0
- package/lib/types/theme/publicTheme.css.d.ts.map +1 -1
- package/lib/types/theme/sprinkles.css.d.ts +2 -2
- package/lib/types/theme/themeContract.css.d.ts +50 -0
- package/lib/types/theme/themeContract.css.d.ts.map +1 -1
- package/package.json +3 -3
- package/src/i18n/locales/en/ui.json +16 -7
- package/src/i18n/locales/fr/ui.json +16 -7
- package/lib/esm/atomic/molecules/card/Card.css.js +0 -8
- package/lib/esm/atomic/molecules/card/Card.css.js.map +0 -1
- package/lib/esm/atomic/molecules/form/FormErrorBanner.css.js +0 -8
- package/lib/esm/atomic/molecules/form/FormErrorBanner.css.js.map +0 -1
- package/lib/esm/atomic/molecules/form/FormErrorBanner.js +0 -17
- package/lib/esm/atomic/molecules/form/FormErrorBanner.js.map +0 -1
- package/lib/esm/atomic/templates/detail-page/DetailPage.js +0 -49
- package/lib/esm/atomic/templates/detail-page/DetailPage.js.map +0 -1
- package/lib/esm/atomic/templates/detail-page/detailPage.css.js +0 -8
- package/lib/esm/atomic/templates/detail-page/detailPage.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_detail_layout/BackofficeDetailLayout.js +0 -33
- package/lib/esm/backoffice/molecules/backoffice_detail_layout/BackofficeDetailLayout.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_detail_layout/backofficeDetailLayout.css.js +0 -8
- package/lib/esm/backoffice/molecules/backoffice_detail_layout/backofficeDetailLayout.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_empty_state/backofficeEmptyState.css.js +0 -8
- package/lib/esm/backoffice/molecules/backoffice_empty_state/backofficeEmptyState.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_filters_bar/BackofficeFiltersBar.js +0 -36
- package/lib/esm/backoffice/molecules/backoffice_filters_bar/BackofficeFiltersBar.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_filters_bar/backofficeFiltersBar.css.js +0 -8
- package/lib/esm/backoffice/molecules/backoffice_filters_bar/backofficeFiltersBar.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_form_section/backofficeFormSection.css.js +0 -8
- package/lib/esm/backoffice/molecules/backoffice_form_section/backofficeFormSection.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_infinite_list_status/BackofficeInfiniteListStatus.js +0 -37
- package/lib/esm/backoffice/molecules/backoffice_infinite_list_status/BackofficeInfiniteListStatus.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_infinite_list_status/backofficeInfiniteListStatus.css.js +0 -8
- package/lib/esm/backoffice/molecules/backoffice_infinite_list_status/backofficeInfiniteListStatus.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_load_more/BackofficeLoadMore.js +0 -35
- package/lib/esm/backoffice/molecules/backoffice_load_more/BackofficeLoadMore.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_load_more/backofficeLoadMore.css.js +0 -8
- package/lib/esm/backoffice/molecules/backoffice_load_more/backofficeLoadMore.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_table_toolbar/BackofficeTableToolbar.js +0 -41
- package/lib/esm/backoffice/molecules/backoffice_table_toolbar/BackofficeTableToolbar.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_table_toolbar/backofficeTableToolbar.css.js +0 -8
- package/lib/esm/backoffice/molecules/backoffice_table_toolbar/backofficeTableToolbar.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_tabs/BackofficeTabs.js +0 -46
- package/lib/esm/backoffice/molecules/backoffice_tabs/BackofficeTabs.js.map +0 -1
- package/lib/esm/backoffice/molecules/backoffice_tabs/backofficeTabs.css.js +0 -17
- package/lib/esm/backoffice/molecules/backoffice_tabs/backofficeTabs.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/inline_banner/InlineBanner.js +0 -46
- package/lib/esm/backoffice/molecules/inline_banner/InlineBanner.js.map +0 -1
- package/lib/esm/backoffice/molecules/inline_banner/inlineBanner.css.js +0 -19
- package/lib/esm/backoffice/molecules/inline_banner/inlineBanner.css.js.map +0 -1
- package/lib/esm/backoffice/molecules/table_toolbar/TableToolbar.js +0 -41
- package/lib/esm/backoffice/molecules/table_toolbar/TableToolbar.js.map +0 -1
- package/lib/esm/backoffice/molecules/table_toolbar/tableToolbar.css.js +0 -8
- package/lib/esm/backoffice/molecules/table_toolbar/tableToolbar.css.js.map +0 -1
- package/lib/esm/backoffice/organisms/backoffice_virtualized_connection_table/BackofficeVirtualizedConnectionTable.js +0 -26
- package/lib/esm/backoffice/organisms/backoffice_virtualized_connection_table/BackofficeVirtualizedConnectionTable.js.map +0 -1
- package/lib/esm/backoffice/organisms/backoffice_virtualized_connection_table/backofficeVirtualizedConnectionTable.css.js +0 -8
- package/lib/esm/backoffice/organisms/backoffice_virtualized_connection_table/backofficeVirtualizedConnectionTable.css.js.map +0 -1
- package/lib/esm/backoffice/organisms/backoffice_virtualized_connection_table/helpers.js +0 -18
- package/lib/esm/backoffice/organisms/backoffice_virtualized_connection_table/helpers.js.map +0 -1
- package/lib/esm/components/dashboard/section_nav/SectionNav.css.js +0 -8
- package/lib/esm/components/dashboard/section_nav/SectionNav.css.js.map +0 -1
- package/lib/esm/components/dashboard/section_nav/SectionNav.js +0 -25
- package/lib/esm/components/dashboard/section_nav/SectionNav.js.map +0 -1
- package/lib/esm/components/dashboard/segmented_nav/SegmentedNav.css.js +0 -8
- package/lib/esm/components/dashboard/segmented_nav/SegmentedNav.css.js.map +0 -1
- package/lib/esm/components/dashboard/segmented_nav/SegmentedNav.js +0 -24
- package/lib/esm/components/dashboard/segmented_nav/SegmentedNav.js.map +0 -1
- package/lib/esm/components/layout/AppShell.js +0 -19
- package/lib/esm/components/layout/AppShell.js.map +0 -1
- package/lib/esm/components/layout/SidebarPageLayout.js +0 -16
- package/lib/esm/components/layout/SidebarPageLayout.js.map +0 -1
- package/lib/esm/components/layout/SplitViewLayout.css.js +0 -8
- package/lib/esm/components/layout/SplitViewLayout.css.js.map +0 -1
- package/lib/esm/components/layout/SplitViewLayout.js +0 -18
- package/lib/esm/components/layout/SplitViewLayout.js.map +0 -1
- package/lib/esm/components/layout/TabsContentLayout.css.js +0 -8
- package/lib/esm/components/layout/TabsContentLayout.css.js.map +0 -1
- package/lib/esm/components/layout/TabsContentLayout.js +0 -31
- package/lib/esm/components/layout/TabsContentLayout.js.map +0 -1
- package/lib/esm/components/layout/ToolbarRow.css.js +0 -8
- package/lib/esm/components/layout/ToolbarRow.css.js.map +0 -1
- package/lib/esm/components/layout/ToolbarRow.js +0 -12
- package/lib/esm/components/layout/ToolbarRow.js.map +0 -1
- package/lib/esm/components/subscriptions/RefetchNeededBanner.css.js +0 -8
- package/lib/esm/components/subscriptions/RefetchNeededBanner.css.js.map +0 -1
- package/lib/types/atomic/molecules/card/Card.css.d.ts +0 -5
- package/lib/types/atomic/molecules/card/Card.css.d.ts.map +0 -1
- package/lib/types/atomic/molecules/form/FormErrorBanner.css.d.ts +0 -2
- package/lib/types/atomic/molecules/form/FormErrorBanner.css.d.ts.map +0 -1
- package/lib/types/atomic/molecules/form/FormErrorBanner.d.ts +0 -7
- package/lib/types/atomic/molecules/form/FormErrorBanner.d.ts.map +0 -1
- package/lib/types/atomic/templates/detail-page/DetailPage.d.ts +0 -19
- package/lib/types/atomic/templates/detail-page/DetailPage.d.ts.map +0 -1
- package/lib/types/atomic/templates/detail-page/detailPage.css.d.ts +0 -9
- package/lib/types/atomic/templates/detail-page/detailPage.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_detail_layout/BackofficeDetailLayout.d.ts +0 -10
- package/lib/types/backoffice/molecules/backoffice_detail_layout/BackofficeDetailLayout.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_detail_layout/backofficeDetailLayout.css.d.ts +0 -7
- package/lib/types/backoffice/molecules/backoffice_detail_layout/backofficeDetailLayout.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_empty_state/backofficeEmptyState.css.d.ts +0 -6
- package/lib/types/backoffice/molecules/backoffice_empty_state/backofficeEmptyState.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_filters_bar/BackofficeFiltersBar.d.ts +0 -13
- package/lib/types/backoffice/molecules/backoffice_filters_bar/BackofficeFiltersBar.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_filters_bar/backofficeFiltersBar.css.d.ts +0 -6
- package/lib/types/backoffice/molecules/backoffice_filters_bar/backofficeFiltersBar.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_form_section/backofficeFormSection.css.d.ts +0 -5
- package/lib/types/backoffice/molecules/backoffice_form_section/backofficeFormSection.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_infinite_list_status/BackofficeInfiniteListStatus.d.ts +0 -16
- package/lib/types/backoffice/molecules/backoffice_infinite_list_status/BackofficeInfiniteListStatus.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_infinite_list_status/backofficeInfiniteListStatus.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_load_more/BackofficeLoadMore.d.ts +0 -13
- package/lib/types/backoffice/molecules/backoffice_load_more/BackofficeLoadMore.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_load_more/backofficeLoadMore.css.d.ts +0 -5
- package/lib/types/backoffice/molecules/backoffice_load_more/backofficeLoadMore.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_table_toolbar/BackofficeTableToolbar.d.ts +0 -16
- package/lib/types/backoffice/molecules/backoffice_table_toolbar/BackofficeTableToolbar.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_table_toolbar/backofficeTableToolbar.css.d.ts +0 -10
- package/lib/types/backoffice/molecules/backoffice_table_toolbar/backofficeTableToolbar.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_tabs/BackofficeTabs.d.ts +0 -19
- package/lib/types/backoffice/molecules/backoffice_tabs/BackofficeTabs.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/backoffice_tabs/backofficeTabs.css.d.ts +0 -15
- package/lib/types/backoffice/molecules/backoffice_tabs/backofficeTabs.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/inline_banner/InlineBanner.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/inline_banner/inlineBanner.css.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/table_toolbar/TableToolbar.d.ts +0 -13
- package/lib/types/backoffice/molecules/table_toolbar/TableToolbar.d.ts.map +0 -1
- package/lib/types/backoffice/molecules/table_toolbar/tableToolbar.css.d.ts +0 -6
- package/lib/types/backoffice/molecules/table_toolbar/tableToolbar.css.d.ts.map +0 -1
- package/lib/types/backoffice/organisms/backoffice_virtualized_connection_table/BackofficeVirtualizedConnectionTable.d.ts +0 -31
- package/lib/types/backoffice/organisms/backoffice_virtualized_connection_table/BackofficeVirtualizedConnectionTable.d.ts.map +0 -1
- package/lib/types/backoffice/organisms/backoffice_virtualized_connection_table/backofficeVirtualizedConnectionTable.css.d.ts +0 -5
- package/lib/types/backoffice/organisms/backoffice_virtualized_connection_table/backofficeVirtualizedConnectionTable.css.d.ts.map +0 -1
- package/lib/types/backoffice/organisms/backoffice_virtualized_connection_table/helpers.d.ts +0 -5
- package/lib/types/backoffice/organisms/backoffice_virtualized_connection_table/helpers.d.ts.map +0 -1
- package/lib/types/components/dashboard/section_nav/SectionNav.css.d.ts +0 -4
- package/lib/types/components/dashboard/section_nav/SectionNav.css.d.ts.map +0 -1
- package/lib/types/components/dashboard/section_nav/SectionNav.d.ts +0 -15
- package/lib/types/components/dashboard/section_nav/SectionNav.d.ts.map +0 -1
- package/lib/types/components/dashboard/segmented_nav/SegmentedNav.css.d.ts +0 -4
- package/lib/types/components/dashboard/segmented_nav/SegmentedNav.css.d.ts.map +0 -1
- package/lib/types/components/dashboard/segmented_nav/SegmentedNav.d.ts +0 -15
- package/lib/types/components/dashboard/segmented_nav/SegmentedNav.d.ts.map +0 -1
- package/lib/types/components/layout/AppShell.d.ts +0 -17
- package/lib/types/components/layout/AppShell.d.ts.map +0 -1
- package/lib/types/components/layout/SidebarPageLayout.d.ts +0 -15
- package/lib/types/components/layout/SidebarPageLayout.d.ts.map +0 -1
- package/lib/types/components/layout/SplitViewLayout.css.d.ts +0 -3
- package/lib/types/components/layout/SplitViewLayout.css.d.ts.map +0 -1
- package/lib/types/components/layout/SplitViewLayout.d.ts +0 -11
- package/lib/types/components/layout/SplitViewLayout.d.ts.map +0 -1
- package/lib/types/components/layout/TabsContentLayout.css.d.ts +0 -6
- package/lib/types/components/layout/TabsContentLayout.css.d.ts.map +0 -1
- package/lib/types/components/layout/TabsContentLayout.d.ts +0 -9
- package/lib/types/components/layout/TabsContentLayout.d.ts.map +0 -1
- package/lib/types/components/layout/ToolbarRow.css.d.ts +0 -2
- package/lib/types/components/layout/ToolbarRow.css.d.ts.map +0 -1
- package/lib/types/components/layout/ToolbarRow.d.ts +0 -8
- package/lib/types/components/layout/ToolbarRow.d.ts.map +0 -1
- package/lib/types/components/subscriptions/RefetchNeededBanner.css.d.ts +0 -5
- package/lib/types/components/subscriptions/RefetchNeededBanner.css.d.ts.map +0 -1
- /package/lib/types/{backoffice/molecules/inline_banner → components/feedback}/inlineBanner.css.d.ts +0 -0
|
@@ -1,16 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import { useCallback as m, useEffect as h, useLayoutEffect as g, useMemo as _, useRef as v, useState as pe } from "react";
|
|
8
|
-
import { jsx as y, jsxs as b } from "react/jsx-runtime";
|
|
1
|
+
import { DataTableBody as e, DataTableEmptyRow as t, DataTableHeader as n, DataTableRoot as r, DataTableRow as i } from "./DataTable.js";
|
|
2
|
+
import { resolveInfiniteRootMargin as a, shouldTriggerInfiniteLoad as o } from "../../internal/infinite/infiniteLoad.js";
|
|
3
|
+
import { bodyViewport as s, sentinel as c, spacer as l } from "./VirtualizedConnectionTable.css.js";
|
|
4
|
+
import { clamp as ee, computeVirtualWindowBounds as te, isVerticallyScrollable as u, shouldTriggerVirtualizedInfiniteLoad as ne } from "../../internal/data-table/virtualization.js";
|
|
5
|
+
import { useCallback as d, useEffect as f, useLayoutEffect as p, useMemo as m, useRef as h, useState as re } from "react";
|
|
6
|
+
import { Fragment as ie, jsx as g, jsxs as _ } from "react/jsx-runtime";
|
|
9
7
|
//#region src/components/data-table/VirtualizedConnectionTable.tsx
|
|
10
|
-
var
|
|
8
|
+
var v = (e) => {
|
|
11
9
|
let t = e;
|
|
12
10
|
for (; t != null;) {
|
|
13
|
-
if (
|
|
11
|
+
if (u({
|
|
14
12
|
overflowY: window.getComputedStyle(t).overflowY,
|
|
15
13
|
scrollHeight: t.scrollHeight,
|
|
16
14
|
clientHeight: t.clientHeight
|
|
@@ -18,212 +16,221 @@ var x = (e) => e == null ? null : d({ minVisibleAt: e }), S = (e) => {
|
|
|
18
16
|
t = t.parentElement;
|
|
19
17
|
}
|
|
20
18
|
return null;
|
|
21
|
-
},
|
|
22
|
-
let
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
if (!B) return null;
|
|
26
|
-
let e = E.rowHeightPx;
|
|
19
|
+
}, y = ({ columns: u, rows: y, getRowId: b, emptyState: ae, className: oe, headerClassName: se, bodyClassName: ce, rowClassName: x, gridTemplateClassName: S, gridTemplateColumns: C, kind: w, density: T, headerBehavior: le, rowState: E, classes: D, bodyScrollMode: O = "page", bodyFooterNode: ue, virtualization: k, infiniteScroll: A, hasNextPage: j = !1, isLoadingMore: M = !1, onLoadMore: N, ariaLabel: de, ariaLabelledBy: fe }) => {
|
|
20
|
+
let P = h(null), F = h(null), I = h(null), L = h(null), R = h(null), z = h(null), B = h(!1), V = k?.enabled === !0, H = m(() => {
|
|
21
|
+
if (!V) return null;
|
|
22
|
+
let e = k.rowHeightPx;
|
|
27
23
|
return typeof e == "number" && Number.isFinite(e) && e > 0 ? e : 56;
|
|
28
|
-
}, [
|
|
29
|
-
if (!
|
|
30
|
-
let e = 10, t =
|
|
24
|
+
}, [V, k]), U = m(() => {
|
|
25
|
+
if (!V) return 0;
|
|
26
|
+
let e = 10, t = k.overscan;
|
|
31
27
|
return typeof t == "number" && Number.isFinite(t) && (e = t), Math.max(0, e);
|
|
32
|
-
}, [
|
|
33
|
-
|
|
34
|
-
}, [
|
|
28
|
+
}, [V, k]), W = A?.thresholdPx ?? 800, G = A?.autoLoad ?? !0, K = A?.enabled === !0, q = O === "contained", J = K && j && !M && N != null, Y = d(() => {
|
|
29
|
+
N?.();
|
|
30
|
+
}, [N]), [pe, me] = re(() => ({
|
|
35
31
|
startIndex: 0,
|
|
36
|
-
endIndex: Math.min(
|
|
37
|
-
})),
|
|
38
|
-
let
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
children: r.cell(t)
|
|
55
|
-
}, r.id);
|
|
56
|
-
})
|
|
57
|
-
}, o);
|
|
32
|
+
endIndex: Math.min(y.length, 50)
|
|
33
|
+
})), X = d((e, t, n) => {
|
|
34
|
+
let r = {};
|
|
35
|
+
return typeof n == "number" && (r.height = n), /* @__PURE__ */ g(i, {
|
|
36
|
+
row: e,
|
|
37
|
+
index: t,
|
|
38
|
+
columns: u,
|
|
39
|
+
getRowId: b,
|
|
40
|
+
kind: w,
|
|
41
|
+
density: T,
|
|
42
|
+
rowClassName: x,
|
|
43
|
+
rowState: E,
|
|
44
|
+
gridTemplateClassName: S,
|
|
45
|
+
gridTemplateColumns: C,
|
|
46
|
+
classes: D,
|
|
47
|
+
style: r,
|
|
48
|
+
cellMode: "singleLine"
|
|
49
|
+
}, b(e, t));
|
|
58
50
|
}, [
|
|
59
|
-
|
|
60
|
-
|
|
51
|
+
D,
|
|
52
|
+
u,
|
|
53
|
+
T,
|
|
54
|
+
b,
|
|
55
|
+
S,
|
|
61
56
|
C,
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
57
|
+
w,
|
|
58
|
+
x,
|
|
59
|
+
E
|
|
60
|
+
]), Z = d(() => {
|
|
61
|
+
if (!V) return;
|
|
62
|
+
let e = H;
|
|
67
63
|
if (e == null) return;
|
|
68
|
-
let t =
|
|
64
|
+
let t = I.current;
|
|
69
65
|
if (t == null) return;
|
|
70
|
-
let n =
|
|
71
|
-
if (
|
|
66
|
+
let n = F.current, r = R.current, i = r?.clientHeight ?? window.innerHeight, a = 0;
|
|
67
|
+
if (q && n != null) i = n.clientHeight, a = n.scrollTop;
|
|
72
68
|
else {
|
|
73
69
|
let e = r?.getBoundingClientRect().top ?? 0, n = t.getBoundingClientRect().top - e;
|
|
74
70
|
a = Math.max(0, -n);
|
|
75
71
|
}
|
|
76
|
-
let
|
|
77
|
-
rowCount:
|
|
72
|
+
let s = a + i, c = y.length * e, l = ee(s, 0, c), { startIndex: u, endIndex: d } = te({
|
|
73
|
+
rowCount: y.length,
|
|
78
74
|
rowHeightPx: e,
|
|
79
|
-
overscan:
|
|
75
|
+
overscan: U,
|
|
80
76
|
visibleTop: a,
|
|
81
|
-
visibleBottom:
|
|
77
|
+
visibleBottom: s
|
|
82
78
|
});
|
|
83
|
-
|
|
84
|
-
startIndex:
|
|
85
|
-
endIndex:
|
|
86
|
-
}),
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
79
|
+
me((e) => e.startIndex === u && e.endIndex === d ? e : {
|
|
80
|
+
startIndex: u,
|
|
81
|
+
endIndex: d
|
|
82
|
+
}), o({
|
|
83
|
+
enabled: K,
|
|
84
|
+
hasNext: j,
|
|
85
|
+
isLoading: M,
|
|
86
|
+
autoLoad: G,
|
|
87
|
+
isCoolingDown: B.current
|
|
88
|
+
}) && J && ne({
|
|
89
|
+
autoLoad: G,
|
|
90
|
+
canLoadMore: J,
|
|
91
|
+
totalHeight: c,
|
|
92
|
+
visibleBottom: l,
|
|
93
|
+
thresholdPx: W,
|
|
94
|
+
isCoolingDown: B.current
|
|
95
|
+
}) && (B.current = !0, Y(), window.setTimeout(() => {
|
|
96
|
+
B.current = !1;
|
|
95
97
|
}, 250));
|
|
96
98
|
}, [
|
|
97
|
-
|
|
99
|
+
G,
|
|
100
|
+
J,
|
|
101
|
+
j,
|
|
98
102
|
q,
|
|
99
|
-
K,
|
|
100
|
-
B,
|
|
101
|
-
H,
|
|
102
103
|
V,
|
|
103
|
-
|
|
104
|
+
K,
|
|
105
|
+
M,
|
|
104
106
|
U,
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
107
|
+
H,
|
|
108
|
+
y.length,
|
|
109
|
+
W,
|
|
110
|
+
Y
|
|
111
|
+
]), Q = d(() => {
|
|
112
|
+
z.current ??= window.requestAnimationFrame(() => {
|
|
113
|
+
z.current = null, Z();
|
|
109
114
|
});
|
|
110
|
-
}, [
|
|
111
|
-
|
|
112
|
-
if (!
|
|
113
|
-
let e =
|
|
114
|
-
e != null && (
|
|
115
|
+
}, [Z]);
|
|
116
|
+
p(() => {
|
|
117
|
+
if (!V) return;
|
|
118
|
+
let e = P.current;
|
|
119
|
+
e != null && (q ? R.current = F.current : R.current = v(e), Q());
|
|
115
120
|
}, [
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
]),
|
|
120
|
-
if (!
|
|
121
|
-
let e =
|
|
122
|
-
|
|
121
|
+
q,
|
|
122
|
+
V,
|
|
123
|
+
Q
|
|
124
|
+
]), f(() => {
|
|
125
|
+
if (!V) return;
|
|
126
|
+
let e = R.current ?? window, t = () => {
|
|
127
|
+
Q();
|
|
123
128
|
};
|
|
124
129
|
return e.addEventListener("scroll", t, { passive: !0 }), window.addEventListener("resize", t), () => {
|
|
125
130
|
e.removeEventListener("scroll", t), window.removeEventListener("resize", t);
|
|
126
131
|
};
|
|
127
|
-
}, [
|
|
128
|
-
if (
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
+
}, [V, Q]), f(() => {
|
|
133
|
+
if (V || !o({
|
|
134
|
+
enabled: K,
|
|
135
|
+
hasNext: j,
|
|
136
|
+
isLoading: M,
|
|
137
|
+
autoLoad: G,
|
|
138
|
+
isCoolingDown: !1
|
|
139
|
+
}) || !J) return;
|
|
140
|
+
let e = L.current;
|
|
141
|
+
if (e == null || typeof window > "u" || typeof IntersectionObserver > "u") return;
|
|
142
|
+
let t = R.current, n = new IntersectionObserver((e) => {
|
|
132
143
|
let [t] = e;
|
|
133
|
-
t != null && t.isIntersecting &&
|
|
134
|
-
|
|
144
|
+
t != null && t.isIntersecting && o({
|
|
145
|
+
enabled: K,
|
|
146
|
+
hasNext: j,
|
|
147
|
+
isLoading: M,
|
|
148
|
+
autoLoad: G,
|
|
149
|
+
isCoolingDown: B.current
|
|
150
|
+
}) && (B.current = !0, Y(), window.setTimeout(() => {
|
|
151
|
+
B.current = !1;
|
|
135
152
|
}, 250));
|
|
136
153
|
}, {
|
|
137
154
|
root: t,
|
|
138
|
-
rootMargin:
|
|
155
|
+
rootMargin: a({ thresholdPx: W })
|
|
139
156
|
});
|
|
140
157
|
return n.observe(e), () => {
|
|
141
158
|
n.disconnect();
|
|
142
159
|
};
|
|
143
160
|
}, [
|
|
144
|
-
W,
|
|
145
|
-
q,
|
|
146
161
|
G,
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
return i != null && r.push(i), t.className != null && r.push(t.className), t.isPrimary && r.push(ne, w?.primaryHeaderCell), t.align != null && r.push(n({ align: t.align })), /* @__PURE__ */ y("div", {
|
|
165
|
-
role: "columnheader",
|
|
166
|
-
className: e(...r),
|
|
167
|
-
children: t.header
|
|
168
|
-
}, t.id);
|
|
169
|
-
})
|
|
170
|
-
})
|
|
171
|
-
}), Q;
|
|
172
|
-
if (p.length === 0) Q = /* @__PURE__ */ y("div", {
|
|
173
|
-
className: e(c, w?.emptyRow),
|
|
174
|
-
role: "row",
|
|
175
|
-
children: /* @__PURE__ */ y("div", {
|
|
176
|
-
role: "cell",
|
|
177
|
-
children: me ?? /* @__PURE__ */ y("div", {
|
|
178
|
-
className: e("ysn84625 txvbqb9w txvbqb19cb txvbqb16fa", w?.emptyCell),
|
|
179
|
-
children: A("common.table.empty")
|
|
180
|
-
})
|
|
181
|
-
})
|
|
162
|
+
J,
|
|
163
|
+
j,
|
|
164
|
+
K,
|
|
165
|
+
V,
|
|
166
|
+
M,
|
|
167
|
+
W,
|
|
168
|
+
Y
|
|
169
|
+
]), p(() => {
|
|
170
|
+
if (V) return;
|
|
171
|
+
let e = P.current;
|
|
172
|
+
e != null && (q ? R.current = F.current : R.current = v(e));
|
|
173
|
+
}, [q, V]);
|
|
174
|
+
let $;
|
|
175
|
+
if (y.length === 0) $ = /* @__PURE__ */ g(t, {
|
|
176
|
+
emptyState: ae,
|
|
177
|
+
density: T,
|
|
178
|
+
classes: D
|
|
182
179
|
});
|
|
183
|
-
else if (
|
|
184
|
-
let { startIndex: e, endIndex: t } =
|
|
185
|
-
|
|
186
|
-
className:
|
|
187
|
-
ref:
|
|
180
|
+
else if (V && H != null) {
|
|
181
|
+
let { startIndex: e, endIndex: t } = pe, n = e * H, r = (y.length - t) * H, i = y.slice(e, t);
|
|
182
|
+
$ = /* @__PURE__ */ _("div", {
|
|
183
|
+
className: s,
|
|
184
|
+
ref: I,
|
|
188
185
|
children: [
|
|
189
|
-
/* @__PURE__ */
|
|
190
|
-
className:
|
|
186
|
+
/* @__PURE__ */ g("div", {
|
|
187
|
+
className: l,
|
|
191
188
|
style: { height: n }
|
|
192
189
|
}),
|
|
193
|
-
i.map((t, n) =>
|
|
194
|
-
/* @__PURE__ */
|
|
195
|
-
className:
|
|
190
|
+
i.map((t, n) => X(t, e + n, H)),
|
|
191
|
+
/* @__PURE__ */ g("div", {
|
|
192
|
+
className: l,
|
|
196
193
|
style: { height: r }
|
|
197
194
|
})
|
|
198
195
|
]
|
|
199
196
|
});
|
|
200
|
-
} else
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
ref:
|
|
207
|
-
className:
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
197
|
+
} else $ = /* @__PURE__ */ g(ie, { children: y.map((e, t) => X(e, t, null)) });
|
|
198
|
+
let he = null;
|
|
199
|
+
return !V && K && G && (he = /* @__PURE__ */ g("div", {
|
|
200
|
+
ref: L,
|
|
201
|
+
className: c
|
|
202
|
+
})), /* @__PURE__ */ _(r, {
|
|
203
|
+
ref: P,
|
|
204
|
+
className: oe,
|
|
205
|
+
kind: w,
|
|
206
|
+
bodyScrollMode: O,
|
|
207
|
+
classes: D,
|
|
208
|
+
ariaLabel: de,
|
|
209
|
+
ariaLabelledBy: fe,
|
|
210
|
+
children: [/* @__PURE__ */ g(n, {
|
|
211
|
+
columns: u,
|
|
212
|
+
kind: w,
|
|
213
|
+
density: T,
|
|
214
|
+
headerBehavior: le,
|
|
215
|
+
headerClassName: se,
|
|
216
|
+
gridTemplateClassName: S,
|
|
217
|
+
gridTemplateColumns: C,
|
|
218
|
+
classes: D
|
|
219
|
+
}), /* @__PURE__ */ _(e, {
|
|
220
|
+
ref: F,
|
|
221
|
+
className: ce,
|
|
222
|
+
kind: w,
|
|
223
|
+
bodyScrollMode: O,
|
|
224
|
+
classes: D,
|
|
225
|
+
children: [
|
|
226
|
+
$,
|
|
227
|
+
he,
|
|
228
|
+
ue
|
|
229
|
+
]
|
|
223
230
|
})]
|
|
224
231
|
});
|
|
225
232
|
};
|
|
226
233
|
//#endregion
|
|
227
|
-
export {
|
|
234
|
+
export { y as VirtualizedConnectionTable };
|
|
228
235
|
|
|
229
236
|
//# sourceMappingURL=VirtualizedConnectionTable.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VirtualizedConnectionTable.js","names":[],"sources":["../../../../src/components/data-table/VirtualizedConnectionTable.tsx"],"sourcesContent":["import {\n useCallback,\n useEffect,\n useLayoutEffect,\n useMemo,\n useRef,\n useState,\n type CSSProperties,\n type JSX,\n} from 'react';\n\nimport type { DataTableBreakpoint } from './tableBreakpoints.js';\nimport type {\n DataTableBodyScrollMode,\n DataTableColumn,\n DataTableKind,\n GetRowId,\n} from './DataTable.js';\nimport * as dataTableStyles from './DataTable.css.js';\nimport * as styles from './VirtualizedConnectionTable.css.js';\n\nimport { buildDataTableInlineTemplate } from '../../internal/data-table/layout.js';\nimport {\n clamp,\n computeVirtualWindowBounds,\n isVerticallyScrollable,\n shouldTriggerInfiniteLoad,\n type VirtualWindow,\n} from '../../internal/data-table/virtualization.js';\nimport { cx } from '../../theme/tools.js';\nimport { useUiTranslation } from '../../i18n/useUiTranslation.js';\nimport type { SlotClasses } from '../../styles/slots.js';\n\nexport type VirtualizationConfig = {\n enabled: boolean;\n rowHeightPx: number;\n overscan: number;\n};\n\nexport type InfiniteScrollConfig = {\n enabled: boolean;\n thresholdPx?: number;\n autoLoad?: boolean;\n};\n\ntype DataTableSlot =\n | 'container'\n | 'header'\n | 'headerRow'\n | 'headerCell'\n | 'primaryHeaderCell'\n | 'body'\n | 'row'\n | 'rowEven'\n | 'rowOdd'\n | 'cell'\n | 'primaryCell'\n | 'emptyRow'\n | 'emptyCell';\n\nexport type VirtualizedConnectionTableProps<Row> = {\n columns: readonly DataTableColumn<Row>[];\n rows: readonly Row[];\n getRowId: GetRowId<Row>;\n emptyState?: JSX.Element;\n className?: string;\n gridTemplateColumns?: string;\n kind?: DataTableKind;\n classes?: SlotClasses<DataTableSlot>;\n bodyScrollMode?: DataTableBodyScrollMode;\n\n virtualization?: VirtualizationConfig;\n\n infiniteScroll?: InfiniteScrollConfig;\n hasNextPage?: boolean;\n isLoadingMore?: boolean;\n onLoadMore?: () => void;\n ariaLabel?: string;\n ariaLabelledBy?: string;\n};\n\nconst getVisibilityClass = (minVisibleAt?: DataTableBreakpoint) => {\n if (minVisibleAt == null) {\n return null;\n }\n return dataTableStyles.hideBelowRecipe({ minVisibleAt });\n};\n\nconst findScrollParent = (el: HTMLElement | null): HTMLElement | null => {\n let current: HTMLElement | null = el;\n while (current != null) {\n const style = window.getComputedStyle(current);\n if (\n isVerticallyScrollable({\n overflowY: style.overflowY,\n scrollHeight: current.scrollHeight,\n clientHeight: current.clientHeight,\n })\n ) {\n return current;\n }\n current = current.parentElement;\n }\n return null;\n};\n\nexport const VirtualizedConnectionTable = <Row,>({\n columns,\n rows,\n getRowId,\n emptyState,\n className,\n gridTemplateColumns,\n kind,\n classes,\n bodyScrollMode = 'page',\n virtualization,\n infiniteScroll,\n hasNextPage = false,\n isLoadingMore = false,\n onLoadMore,\n ariaLabel,\n ariaLabelledBy,\n}: VirtualizedConnectionTableProps<Row>): JSX.Element => {\n const { t } = useUiTranslation();\n const resolvedKind: DataTableKind = kind ?? 'default';\n const resolvedAriaLabel = ariaLabel ?? t('common.table.label');\n let tableAriaLabel: string | undefined = resolvedAriaLabel;\n if (ariaLabelledBy != null) {\n tableAriaLabel = undefined;\n }\n const containerRef = useRef<HTMLDivElement>(null);\n const bodyScrollerRef = useRef<HTMLDivElement>(null);\n const bodyRef = useRef<HTMLDivElement>(null);\n const sentinelRef = useRef<HTMLDivElement>(null);\n const scrollParentRef = useRef<HTMLElement | null>(null);\n const rafRef = useRef<number | null>(null);\n const loadMoreCooldownRef = useRef(false);\n\n const isVirtualized = virtualization?.enabled === true;\n const rowHeightPx = useMemo(() => {\n if (!isVirtualized) {\n return null;\n }\n\n const configuredRowHeight = virtualization.rowHeightPx;\n if (\n typeof configuredRowHeight === 'number' &&\n Number.isFinite(configuredRowHeight) &&\n configuredRowHeight > 0\n ) {\n return configuredRowHeight;\n }\n\n return 56;\n }, [isVirtualized, virtualization]);\n\n const overscan = useMemo(() => {\n if (!isVirtualized) {\n return 0;\n }\n\n let nextOverscan = 10;\n const configuredOverscan = virtualization.overscan;\n if (\n typeof configuredOverscan === 'number' &&\n Number.isFinite(configuredOverscan)\n ) {\n nextOverscan = configuredOverscan;\n }\n return Math.max(0, nextOverscan);\n }, [isVirtualized, virtualization]);\n\n const thresholdPx = infiniteScroll?.thresholdPx ?? 800;\n const autoLoad = infiniteScroll?.autoLoad ?? true;\n const infiniteEnabled = infiniteScroll?.enabled === true;\n const hasContainedBodyScroll = bodyScrollMode === 'contained';\n\n const canLoadMore =\n infiniteEnabled && hasNextPage && !isLoadingMore && onLoadMore != null;\n\n const triggerLoadMore = useCallback(() => {\n if (onLoadMore == null) {\n return;\n }\n onLoadMore();\n }, [onLoadMore]);\n\n const [windowState, setWindowState] = useState<VirtualWindow>(() => {\n return { startIndex: 0, endIndex: Math.min(rows.length, 50) };\n });\n\n const inlineTemplateStyle = useMemo(() => {\n return buildDataTableInlineTemplate(columns.length, gridTemplateColumns);\n }, [columns.length, gridTemplateColumns]);\n\n const renderRow = useCallback(\n (row: Row, index: number, heightPx?: number | null): JSX.Element => {\n const rowId = getRowId(row, index);\n const rowClasses = [\n dataTableStyles.row({ kind: resolvedKind }),\n classes?.row,\n ];\n if (index % 2 === 0) {\n rowClasses.push(\n dataTableStyles.rowEven({ kind: resolvedKind }),\n classes?.rowEven,\n );\n } else {\n rowClasses.push(\n dataTableStyles.rowOdd({ kind: resolvedKind }),\n classes?.rowOdd,\n );\n }\n const rowStyle: CSSProperties = { ...inlineTemplateStyle };\n if (typeof heightPx === 'number') {\n rowStyle.height = heightPx;\n }\n return (\n <div\n key={rowId}\n role=\"row\"\n className={cx(...rowClasses)}\n style={rowStyle}\n >\n {columns.map((column) => {\n const cellClasses = [\n dataTableStyles.cell({ kind: resolvedKind }),\n styles.singleLineCell,\n classes?.cell,\n ];\n const visibilityClass = getVisibilityClass(column.minVisibleAt);\n if (visibilityClass != null) {\n cellClasses.push(visibilityClass);\n }\n if (column.className != null) {\n cellClasses.push(column.className);\n }\n if (column.isPrimary) {\n cellClasses.push(\n dataTableStyles.primaryCell,\n classes?.primaryCell,\n );\n }\n if (column.align != null) {\n cellClasses.push(\n dataTableStyles.alignRecipe({ align: column.align }),\n );\n }\n return (\n <div key={column.id} role=\"cell\" className={cx(...cellClasses)}>\n {column.cell(row)}\n </div>\n );\n })}\n </div>\n );\n },\n [classes, columns, getRowId, inlineTemplateStyle, resolvedKind],\n );\n\n const computeVirtualWindow = useCallback(() => {\n if (!isVirtualized) {\n return;\n }\n const height = rowHeightPx;\n if (height == null) {\n return;\n }\n const bodyEl = bodyRef.current;\n if (bodyEl == null) {\n return;\n }\n\n const bodyScroller = bodyScrollerRef.current;\n const scrollParent = scrollParentRef.current;\n let viewportHeight = scrollParent?.clientHeight ?? window.innerHeight;\n let visibleTop = 0;\n if (hasContainedBodyScroll && bodyScroller != null) {\n viewportHeight = bodyScroller.clientHeight;\n visibleTop = bodyScroller.scrollTop;\n } else {\n const parentRectTop = scrollParent?.getBoundingClientRect().top ?? 0;\n const bodyRectTop = bodyEl.getBoundingClientRect().top;\n const relativeTop = bodyRectTop - parentRectTop;\n visibleTop = Math.max(0, -relativeTop);\n }\n const visibleBottom = visibleTop + viewportHeight;\n\n const totalHeight = rows.length * height;\n const clampedBottom = clamp(visibleBottom, 0, totalHeight);\n const { startIndex, endIndex } = computeVirtualWindowBounds({\n rowCount: rows.length,\n rowHeightPx: height,\n overscan,\n visibleTop,\n visibleBottom,\n });\n\n setWindowState((prev) => {\n if (prev.startIndex === startIndex && prev.endIndex === endIndex) {\n return prev;\n }\n return { startIndex, endIndex };\n });\n\n if (\n shouldTriggerInfiniteLoad({\n autoLoad,\n canLoadMore,\n totalHeight,\n visibleBottom: clampedBottom,\n thresholdPx,\n isCoolingDown: loadMoreCooldownRef.current,\n })\n ) {\n loadMoreCooldownRef.current = true;\n triggerLoadMore();\n window.setTimeout(() => {\n loadMoreCooldownRef.current = false;\n }, 250);\n }\n }, [\n autoLoad,\n canLoadMore,\n hasContainedBodyScroll,\n isVirtualized,\n overscan,\n rowHeightPx,\n rows.length,\n thresholdPx,\n triggerLoadMore,\n ]);\n\n const scheduleCompute = useCallback(() => {\n if (rafRef.current != null) {\n return;\n }\n rafRef.current = window.requestAnimationFrame(() => {\n rafRef.current = null;\n computeVirtualWindow();\n });\n }, [computeVirtualWindow]);\n\n useLayoutEffect(() => {\n if (!isVirtualized) {\n return;\n }\n const container = containerRef.current;\n if (container == null) {\n return;\n }\n if (hasContainedBodyScroll) {\n scrollParentRef.current = bodyScrollerRef.current;\n } else {\n scrollParentRef.current = findScrollParent(container);\n }\n scheduleCompute();\n }, [hasContainedBodyScroll, isVirtualized, scheduleCompute]);\n\n useEffect(() => {\n if (!isVirtualized) {\n return undefined;\n }\n const scrollParent = scrollParentRef.current;\n const target: HTMLElement | Window = scrollParent ?? window;\n\n const handler = () => {\n scheduleCompute();\n };\n\n target.addEventListener('scroll', handler, { passive: true });\n window.addEventListener('resize', handler);\n\n return () => {\n target.removeEventListener('scroll', handler);\n window.removeEventListener('resize', handler);\n };\n }, [isVirtualized, scheduleCompute]);\n\n useEffect(() => {\n if (isVirtualized) {\n return undefined;\n }\n if (!infiniteEnabled || !autoLoad || !canLoadMore) {\n return undefined;\n }\n const sentinel = sentinelRef.current;\n if (sentinel == null) {\n return undefined;\n }\n\n const scrollParent = scrollParentRef.current;\n\n const observer = new IntersectionObserver(\n (entries) => {\n const [entry] = entries;\n if (entry == null) {\n return;\n }\n\n if (entry.isIntersecting && !loadMoreCooldownRef.current) {\n loadMoreCooldownRef.current = true;\n triggerLoadMore();\n window.setTimeout(() => {\n loadMoreCooldownRef.current = false;\n }, 250);\n }\n },\n {\n root: scrollParent,\n rootMargin: `0px 0px ${thresholdPx}px 0px`,\n },\n );\n\n observer.observe(sentinel);\n return () => {\n observer.disconnect();\n };\n }, [\n autoLoad,\n canLoadMore,\n infiniteEnabled,\n isVirtualized,\n thresholdPx,\n triggerLoadMore,\n ]);\n\n useLayoutEffect(() => {\n if (isVirtualized) {\n return;\n }\n const container = containerRef.current;\n if (container == null) {\n return;\n }\n if (hasContainedBodyScroll) {\n scrollParentRef.current = bodyScrollerRef.current;\n } else {\n scrollParentRef.current = findScrollParent(container);\n }\n }, [hasContainedBodyScroll, isVirtualized]);\n\n const headerRow = (\n <div\n className={cx(\n dataTableStyles.header({ kind: resolvedKind }),\n classes?.header,\n )}\n role=\"rowgroup\"\n >\n <div\n className={cx(dataTableStyles.headerRow, classes?.headerRow)}\n role=\"row\"\n style={inlineTemplateStyle}\n >\n {columns.map((column) => {\n const headerClasses = [\n dataTableStyles.headerCell({ kind: resolvedKind }),\n classes?.headerCell,\n ];\n const visibilityClass = getVisibilityClass(column.minVisibleAt);\n if (visibilityClass != null) {\n headerClasses.push(visibilityClass);\n }\n if (column.className != null) {\n headerClasses.push(column.className);\n }\n if (column.isPrimary) {\n headerClasses.push(\n dataTableStyles.primaryHeaderCell,\n classes?.primaryHeaderCell,\n );\n }\n if (column.align != null) {\n headerClasses.push(\n dataTableStyles.alignRecipe({ align: column.align }),\n );\n }\n return (\n <div\n key={column.id}\n role=\"columnheader\"\n className={cx(...headerClasses)}\n >\n {column.header}\n </div>\n );\n })}\n </div>\n </div>\n );\n\n let bodyRows: JSX.Element;\n if (rows.length === 0) {\n bodyRows = (\n <div\n className={cx(dataTableStyles.emptyRow, classes?.emptyRow)}\n role=\"row\"\n >\n <div role=\"cell\">\n {emptyState ?? (\n <div className={cx(dataTableStyles.emptyCell, classes?.emptyCell)}>\n {t('common.table.empty')}\n </div>\n )}\n </div>\n </div>\n );\n } else if (isVirtualized && rowHeightPx != null) {\n const { startIndex, endIndex } = windowState;\n const topSpacerHeight = startIndex * rowHeightPx;\n const bottomSpacerHeight = (rows.length - endIndex) * rowHeightPx;\n const slice = rows.slice(startIndex, endIndex);\n bodyRows = (\n <div className={styles.bodyViewport} ref={bodyRef}>\n <div className={styles.spacer} style={{ height: topSpacerHeight }} />\n {slice.map((row, sliceIndex) => {\n const absoluteIndex = startIndex + sliceIndex;\n return renderRow(row, absoluteIndex, rowHeightPx);\n })}\n <div className={styles.spacer} style={{ height: bottomSpacerHeight }} />\n </div>\n );\n } else {\n bodyRows = (\n <div ref={bodyRef}>\n {rows.map((row, index) => {\n return renderRow(row, index, null);\n })}\n </div>\n );\n }\n\n let sentinelNode: JSX.Element | null = null;\n if (!isVirtualized && infiniteEnabled && autoLoad) {\n sentinelNode = <div ref={sentinelRef} className={styles.sentinel} />;\n }\n\n let containedContainerClassName: string | null = null;\n let containedBodyClassName: string | null = null;\n if (hasContainedBodyScroll) {\n containedContainerClassName = dataTableStyles.containerWithContainedBody;\n containedBodyClassName = dataTableStyles.bodyContained;\n }\n\n return (\n <div\n ref={containerRef}\n className={cx(\n dataTableStyles.container({ kind: resolvedKind }),\n containedContainerClassName,\n classes?.container,\n className,\n )}\n role=\"table\"\n aria-label={tableAriaLabel}\n aria-labelledby={ariaLabelledBy}\n data-scroll-mode={bodyScrollMode}\n >\n {headerRow}\n <div\n ref={bodyScrollerRef}\n className={cx(\n dataTableStyles.body({ kind: resolvedKind }),\n containedBodyClassName,\n classes?.body,\n )}\n role=\"rowgroup\"\n data-scroll-mode={bodyScrollMode}\n >\n {bodyRows}\n {sentinelNode}\n </div>\n </div>\n );\n};\n"],"mappings":";;;;;;;;;AAiFA,IAAM,KAAsB,MACtB,KAAgB,OACX,OAEF,EAAgC,EAAE,iBAAc,CAAC,EAGpD,KAAoB,MAA+C;CACvE,IAAI,IAA8B;CAClC,OAAO,KAAW,OAAM;EAEtB,IACE,EAAuB;GACrB,WAHU,OAAO,iBAAiB,EAGvB,CAAM;GACjB,cAAc,EAAQ;GACtB,cAAc,EAAQ;GACvB,CAAC,EAEF,OAAO;EAET,IAAU,EAAQ;;CAEpB,OAAO;GAGI,KAAoC,EAC/C,YACA,SACA,aACA,gBACA,eACA,yBACA,UACA,YACA,oBAAiB,QACjB,mBAC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EACjB,oBAAkB;YAXpB,CAaG,IACD,kBAAC,OAAD;GACE,KAAK;GACL,WAAW,EACT,EAAqB,EAAE,MAAM,GAAc,CAAC,EAC5C,GACA,GAAS,KACV;GACD,MAAK;GACL,oBAAkB;aARpB,CAUG,GACA,GACG;KACF"}
|
|
1
|
+
{"version":3,"file":"VirtualizedConnectionTable.js","names":[],"sources":["../../../../src/components/data-table/VirtualizedConnectionTable.tsx"],"sourcesContent":["import {\n useCallback,\n useEffect,\n useLayoutEffect,\n useMemo,\n useRef,\n useState,\n type CSSProperties,\n type JSX,\n type ReactNode,\n} from 'react';\n\nimport {\n DataTableBody,\n DataTableEmptyRow,\n DataTableHeader,\n DataTableRoot,\n DataTableRow,\n type DataTableBodyScrollMode,\n type DataTableColumn,\n type DataTableDensity,\n type DataTableHeaderBehavior,\n type DataTableKind,\n type DataTableRowState,\n type DataTableSlot,\n type GetRowId,\n} from './DataTable.js';\nimport * as styles from './VirtualizedConnectionTable.css.js';\n\nimport {\n clamp,\n computeVirtualWindowBounds,\n isVerticallyScrollable,\n shouldTriggerVirtualizedInfiniteLoad,\n type VirtualWindow,\n} from '../../internal/data-table/virtualization.js';\nimport {\n resolveInfiniteRootMargin,\n shouldTriggerInfiniteLoad,\n} from '../../internal/infinite/infiniteLoad.js';\nimport type { SlotClasses } from '../../styles/slots.js';\n\nexport type VirtualizationConfig = {\n enabled: boolean;\n rowHeightPx: number;\n overscan: number;\n};\n\nexport type InfiniteScrollConfig = {\n enabled: boolean;\n thresholdPx?: number;\n autoLoad?: boolean;\n};\n\nexport type VirtualizedConnectionTableProps<Row> = {\n columns: readonly DataTableColumn<Row>[];\n rows: readonly Row[];\n getRowId: GetRowId<Row>;\n emptyState?: JSX.Element;\n className?: string;\n headerClassName?: string;\n bodyClassName?: string;\n rowClassName?: (row: Row, index: number) => string | null | undefined;\n gridTemplateClassName?: string;\n gridTemplateColumns?: string;\n kind?: DataTableKind;\n density?: DataTableDensity;\n headerBehavior?: DataTableHeaderBehavior;\n rowState?: (row: Row, index: number) => DataTableRowState;\n classes?: SlotClasses<DataTableSlot>;\n bodyScrollMode?: DataTableBodyScrollMode;\n bodyFooterNode?: ReactNode;\n\n virtualization?: VirtualizationConfig;\n\n infiniteScroll?: InfiniteScrollConfig;\n hasNextPage?: boolean;\n isLoadingMore?: boolean;\n onLoadMore?: () => void;\n ariaLabel?: string;\n ariaLabelledBy?: string;\n};\n\nconst findScrollParent = (el: HTMLElement | null): HTMLElement | null => {\n let current: HTMLElement | null = el;\n while (current != null) {\n const style = window.getComputedStyle(current);\n if (\n isVerticallyScrollable({\n overflowY: style.overflowY,\n scrollHeight: current.scrollHeight,\n clientHeight: current.clientHeight,\n })\n ) {\n return current;\n }\n current = current.parentElement;\n }\n return null;\n};\n\nexport const VirtualizedConnectionTable = <Row,>({\n columns,\n rows,\n getRowId,\n emptyState,\n className,\n headerClassName,\n bodyClassName,\n rowClassName,\n gridTemplateClassName,\n gridTemplateColumns,\n kind,\n density,\n headerBehavior,\n rowState,\n classes,\n bodyScrollMode = 'page',\n bodyFooterNode,\n virtualization,\n infiniteScroll,\n hasNextPage = false,\n isLoadingMore = false,\n onLoadMore,\n ariaLabel,\n ariaLabelledBy,\n}: VirtualizedConnectionTableProps<Row>): JSX.Element => {\n const containerRef = useRef<HTMLDivElement>(null);\n const bodyScrollerRef = useRef<HTMLDivElement>(null);\n const bodyRef = useRef<HTMLDivElement>(null);\n const sentinelRef = useRef<HTMLDivElement>(null);\n const scrollParentRef = useRef<HTMLElement | null>(null);\n const rafRef = useRef<number | null>(null);\n const loadMoreCooldownRef = useRef(false);\n\n const isVirtualized = virtualization?.enabled === true;\n const rowHeightPx = useMemo(() => {\n if (!isVirtualized) {\n return null;\n }\n\n const configuredRowHeight = virtualization.rowHeightPx;\n if (\n typeof configuredRowHeight === 'number' &&\n Number.isFinite(configuredRowHeight) &&\n configuredRowHeight > 0\n ) {\n return configuredRowHeight;\n }\n\n return 56;\n }, [isVirtualized, virtualization]);\n\n const overscan = useMemo(() => {\n if (!isVirtualized) {\n return 0;\n }\n\n let nextOverscan = 10;\n const configuredOverscan = virtualization.overscan;\n if (\n typeof configuredOverscan === 'number' &&\n Number.isFinite(configuredOverscan)\n ) {\n nextOverscan = configuredOverscan;\n }\n return Math.max(0, nextOverscan);\n }, [isVirtualized, virtualization]);\n\n const thresholdPx = infiniteScroll?.thresholdPx ?? 800;\n const autoLoad = infiniteScroll?.autoLoad ?? true;\n const infiniteEnabled = infiniteScroll?.enabled === true;\n const hasContainedBodyScroll = bodyScrollMode === 'contained';\n\n const canLoadMore =\n infiniteEnabled && hasNextPage && !isLoadingMore && onLoadMore != null;\n\n const triggerLoadMore = useCallback(() => {\n if (onLoadMore == null) {\n return;\n }\n onLoadMore();\n }, [onLoadMore]);\n\n const [windowState, setWindowState] = useState<VirtualWindow>(() => {\n return { startIndex: 0, endIndex: Math.min(rows.length, 50) };\n });\n\n const renderRow = useCallback(\n (row: Row, index: number, heightPx?: number | null): JSX.Element => {\n const rowStyle: CSSProperties = {};\n if (typeof heightPx === 'number') {\n rowStyle.height = heightPx;\n }\n return (\n <DataTableRow\n key={getRowId(row, index)}\n row={row}\n index={index}\n columns={columns}\n getRowId={getRowId}\n kind={kind}\n density={density}\n rowClassName={rowClassName}\n rowState={rowState}\n gridTemplateClassName={gridTemplateClassName}\n gridTemplateColumns={gridTemplateColumns}\n classes={classes}\n style={rowStyle}\n cellMode=\"singleLine\"\n />\n );\n },\n [\n classes,\n columns,\n density,\n getRowId,\n gridTemplateClassName,\n gridTemplateColumns,\n kind,\n rowClassName,\n rowState,\n ],\n );\n\n const computeVirtualWindow = useCallback(() => {\n if (!isVirtualized) {\n return;\n }\n const height = rowHeightPx;\n if (height == null) {\n return;\n }\n const bodyEl = bodyRef.current;\n if (bodyEl == null) {\n return;\n }\n\n const bodyScroller = bodyScrollerRef.current;\n const scrollParent = scrollParentRef.current;\n let viewportHeight = scrollParent?.clientHeight ?? window.innerHeight;\n let visibleTop = 0;\n if (hasContainedBodyScroll && bodyScroller != null) {\n viewportHeight = bodyScroller.clientHeight;\n visibleTop = bodyScroller.scrollTop;\n } else {\n const parentRectTop = scrollParent?.getBoundingClientRect().top ?? 0;\n const bodyRectTop = bodyEl.getBoundingClientRect().top;\n const relativeTop = bodyRectTop - parentRectTop;\n visibleTop = Math.max(0, -relativeTop);\n }\n const visibleBottom = visibleTop + viewportHeight;\n\n const totalHeight = rows.length * height;\n const clampedBottom = clamp(visibleBottom, 0, totalHeight);\n const { startIndex, endIndex } = computeVirtualWindowBounds({\n rowCount: rows.length,\n rowHeightPx: height,\n overscan,\n visibleTop,\n visibleBottom,\n });\n\n setWindowState((prev) => {\n if (prev.startIndex === startIndex && prev.endIndex === endIndex) {\n return prev;\n }\n return { startIndex, endIndex };\n });\n\n if (\n shouldTriggerInfiniteLoad({\n enabled: infiniteEnabled,\n hasNext: hasNextPage,\n isLoading: isLoadingMore,\n autoLoad,\n isCoolingDown: loadMoreCooldownRef.current,\n }) &&\n canLoadMore &&\n shouldTriggerVirtualizedInfiniteLoad({\n autoLoad,\n canLoadMore,\n totalHeight,\n visibleBottom: clampedBottom,\n thresholdPx,\n isCoolingDown: loadMoreCooldownRef.current,\n })\n ) {\n loadMoreCooldownRef.current = true;\n triggerLoadMore();\n window.setTimeout(() => {\n loadMoreCooldownRef.current = false;\n }, 250);\n }\n }, [\n autoLoad,\n canLoadMore,\n hasNextPage,\n hasContainedBodyScroll,\n isVirtualized,\n infiniteEnabled,\n isLoadingMore,\n overscan,\n rowHeightPx,\n rows.length,\n thresholdPx,\n triggerLoadMore,\n ]);\n\n const scheduleCompute = useCallback(() => {\n if (rafRef.current != null) {\n return;\n }\n rafRef.current = window.requestAnimationFrame(() => {\n rafRef.current = null;\n computeVirtualWindow();\n });\n }, [computeVirtualWindow]);\n\n useLayoutEffect(() => {\n if (!isVirtualized) {\n return;\n }\n const container = containerRef.current;\n if (container == null) {\n return;\n }\n if (hasContainedBodyScroll) {\n scrollParentRef.current = bodyScrollerRef.current;\n } else {\n scrollParentRef.current = findScrollParent(container);\n }\n scheduleCompute();\n }, [hasContainedBodyScroll, isVirtualized, scheduleCompute]);\n\n useEffect(() => {\n if (!isVirtualized) {\n return undefined;\n }\n const scrollParent = scrollParentRef.current;\n const target: HTMLElement | Window = scrollParent ?? window;\n\n const handler = () => {\n scheduleCompute();\n };\n\n target.addEventListener('scroll', handler, { passive: true });\n window.addEventListener('resize', handler);\n\n return () => {\n target.removeEventListener('scroll', handler);\n window.removeEventListener('resize', handler);\n };\n }, [isVirtualized, scheduleCompute]);\n\n useEffect(() => {\n if (isVirtualized) {\n return undefined;\n }\n if (\n !shouldTriggerInfiniteLoad({\n enabled: infiniteEnabled,\n hasNext: hasNextPage,\n isLoading: isLoadingMore,\n autoLoad,\n isCoolingDown: false,\n }) ||\n !canLoadMore\n ) {\n return undefined;\n }\n const sentinel = sentinelRef.current;\n if (sentinel == null) {\n return undefined;\n }\n if (\n typeof window === 'undefined' ||\n typeof IntersectionObserver === 'undefined'\n ) {\n return undefined;\n }\n\n const scrollParent = scrollParentRef.current;\n\n const observer = new IntersectionObserver(\n (entries) => {\n const [entry] = entries;\n if (entry == null) {\n return;\n }\n\n if (\n entry.isIntersecting &&\n shouldTriggerInfiniteLoad({\n enabled: infiniteEnabled,\n hasNext: hasNextPage,\n isLoading: isLoadingMore,\n autoLoad,\n isCoolingDown: loadMoreCooldownRef.current,\n })\n ) {\n loadMoreCooldownRef.current = true;\n triggerLoadMore();\n window.setTimeout(() => {\n loadMoreCooldownRef.current = false;\n }, 250);\n }\n },\n {\n root: scrollParent,\n rootMargin: resolveInfiniteRootMargin({ thresholdPx }),\n },\n );\n\n observer.observe(sentinel);\n return () => {\n observer.disconnect();\n };\n }, [\n autoLoad,\n canLoadMore,\n hasNextPage,\n infiniteEnabled,\n isVirtualized,\n isLoadingMore,\n thresholdPx,\n triggerLoadMore,\n ]);\n\n useLayoutEffect(() => {\n if (isVirtualized) {\n return;\n }\n const container = containerRef.current;\n if (container == null) {\n return;\n }\n if (hasContainedBodyScroll) {\n scrollParentRef.current = bodyScrollerRef.current;\n } else {\n scrollParentRef.current = findScrollParent(container);\n }\n }, [hasContainedBodyScroll, isVirtualized]);\n\n let bodyRows: JSX.Element;\n if (rows.length === 0) {\n bodyRows = (\n <DataTableEmptyRow\n emptyState={emptyState}\n density={density}\n classes={classes}\n />\n );\n } else if (isVirtualized && rowHeightPx != null) {\n const { startIndex, endIndex } = windowState;\n const topSpacerHeight = startIndex * rowHeightPx;\n const bottomSpacerHeight = (rows.length - endIndex) * rowHeightPx;\n const slice = rows.slice(startIndex, endIndex);\n bodyRows = (\n <div className={styles.bodyViewport} ref={bodyRef}>\n <div className={styles.spacer} style={{ height: topSpacerHeight }} />\n {slice.map((row, sliceIndex) => {\n const absoluteIndex = startIndex + sliceIndex;\n return renderRow(row, absoluteIndex, rowHeightPx);\n })}\n <div className={styles.spacer} style={{ height: bottomSpacerHeight }} />\n </div>\n );\n } else {\n bodyRows = (\n <>\n {rows.map((row, index) => {\n return renderRow(row, index, null);\n })}\n </>\n );\n }\n\n let sentinelNode: JSX.Element | null = null;\n if (!isVirtualized && infiniteEnabled && autoLoad) {\n sentinelNode = <div ref={sentinelRef} className={styles.sentinel} />;\n }\n\n return (\n <DataTableRoot\n ref={containerRef}\n className={className}\n kind={kind}\n bodyScrollMode={bodyScrollMode}\n classes={classes}\n ariaLabel={ariaLabel}\n ariaLabelledBy={ariaLabelledBy}\n >\n <DataTableHeader\n columns={columns}\n kind={kind}\n density={density}\n headerBehavior={headerBehavior}\n headerClassName={headerClassName}\n gridTemplateClassName={gridTemplateClassName}\n gridTemplateColumns={gridTemplateColumns}\n classes={classes}\n />\n <DataTableBody\n ref={bodyScrollerRef}\n className={bodyClassName}\n kind={kind}\n bodyScrollMode={bodyScrollMode}\n classes={classes}\n >\n {bodyRows}\n {sentinelNode}\n {bodyFooterNode}\n </DataTableBody>\n </DataTableRoot>\n );\n};\n"],"mappings":";;;;;;;AAmFA,IAAM,KAAo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GACZ;GACT,CAAA,EACF,kBAAC,GAAD;GACE,KAAK;GACL,WAAW;GACL;GACU;GACP;aALX;IAOG;IACA;IACA;IACa;KACF"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { cx as e } from "../../theme/tools.js";
|
|
2
|
+
import { ModalCloseSvg as t } from "../../icons/ModalCloseSvg.js";
|
|
3
|
+
import { actions as n, closeButton as r, container as i, content as a, description as o, title as s, toneRecipe as c } from "./inlineBanner.css.js";
|
|
4
|
+
import { jsx as l, jsxs as u } from "react/jsx-runtime";
|
|
5
|
+
import { useTranslation as d } from "react-i18next";
|
|
6
|
+
//#region src/components/feedback/InlineBanner.tsx
|
|
7
|
+
var f = ({ tone: f = "info", title: p, children: m, actions: h, onDismiss: g, dismissLabel: _, className: v, role: y, ariaLive: b }) => {
|
|
8
|
+
let { t: x } = d("ui", { useSuspense: !1 }), S = typeof g == "function", C = _ ?? x("backoffice.inlineBanner.dismiss"), w = y;
|
|
9
|
+
w ?? (w = "status", f === "danger" && (w = "alert"));
|
|
10
|
+
let T = b;
|
|
11
|
+
T ?? (T = "polite", f === "danger" && (T = "assertive"));
|
|
12
|
+
let E = null;
|
|
13
|
+
p != null && (E = /* @__PURE__ */ l("div", {
|
|
14
|
+
className: s,
|
|
15
|
+
children: p
|
|
16
|
+
}));
|
|
17
|
+
let D = null;
|
|
18
|
+
m != null && (D = /* @__PURE__ */ l("div", {
|
|
19
|
+
className: o,
|
|
20
|
+
children: m
|
|
21
|
+
}));
|
|
22
|
+
let O = null;
|
|
23
|
+
return S && (O = /* @__PURE__ */ l("button", {
|
|
24
|
+
type: "button",
|
|
25
|
+
onClick: g,
|
|
26
|
+
className: r,
|
|
27
|
+
"aria-label": C,
|
|
28
|
+
children: /* @__PURE__ */ l(t, {
|
|
29
|
+
width: 18,
|
|
30
|
+
height: 18,
|
|
31
|
+
"aria-hidden": "true"
|
|
32
|
+
})
|
|
33
|
+
})), /* @__PURE__ */ u("div", {
|
|
34
|
+
className: e(i, c({ tone: f }), v),
|
|
35
|
+
role: w,
|
|
36
|
+
"aria-live": T,
|
|
37
|
+
children: [/* @__PURE__ */ u("div", {
|
|
38
|
+
className: a,
|
|
39
|
+
children: [E, D]
|
|
40
|
+
}), /* @__PURE__ */ u("div", {
|
|
41
|
+
className: n,
|
|
42
|
+
children: [h, O]
|
|
43
|
+
})]
|
|
44
|
+
});
|
|
45
|
+
};
|
|
46
|
+
//#endregion
|
|
47
|
+
export { f as InlineBanner, f as default };
|
|
48
|
+
|
|
49
|
+
//# sourceMappingURL=InlineBanner.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"InlineBanner.js","names":[],"sources":["../../../../src/components/feedback/InlineBanner.tsx"],"sourcesContent":["import { type AriaRole, type JSX, type ReactNode } from 'react';\nimport { useTranslation } from 'react-i18next';\nimport type { RecipeVariants } from '@vanilla-extract/recipes';\n\nimport { ModalCloseSvg } from '../../icons/ModalCloseSvg.js';\nimport { cx } from '../../theme/tools.js';\n\nimport * as styles from './inlineBanner.css.js';\n\nexport type InlineBannerTone = NonNullable<\n NonNullable<RecipeVariants<typeof styles.toneRecipe>>['tone']\n>;\n\nexport type InlineBannerProps = {\n tone?: InlineBannerTone;\n title?: ReactNode;\n children?: ReactNode;\n actions?: ReactNode;\n onDismiss?: () => void;\n dismissLabel?: string;\n className?: string;\n role?: AriaRole;\n ariaLive?: 'off' | 'assertive' | 'polite';\n};\n\nexport const InlineBanner = ({\n tone = 'info',\n title,\n children,\n actions,\n onDismiss,\n dismissLabel,\n className,\n role,\n ariaLive,\n}: InlineBannerProps): JSX.Element => {\n const { t } = useTranslation('ui', { useSuspense: false });\n const showDismiss = typeof onDismiss === 'function';\n const resolvedDismissLabel =\n dismissLabel ?? t('backoffice.inlineBanner.dismiss');\n let resolvedRole = role;\n if (resolvedRole == null) {\n resolvedRole = 'status';\n if (tone === 'danger') {\n resolvedRole = 'alert';\n }\n }\n let resolvedAriaLive = ariaLive;\n if (resolvedAriaLive == null) {\n resolvedAriaLive = 'polite';\n if (tone === 'danger') {\n resolvedAriaLive = 'assertive';\n }\n }\n\n let titleNode: JSX.Element | null = null;\n if (title != null) {\n titleNode = <div className={styles.title}>{title}</div>;\n }\n\n let descriptionNode: JSX.Element | null = null;\n if (children != null) {\n descriptionNode = <div className={styles.description}>{children}</div>;\n }\n\n let dismissNode: JSX.Element | null = null;\n if (showDismiss) {\n dismissNode = (\n <button\n type=\"button\"\n onClick={onDismiss}\n className={styles.closeButton}\n aria-label={resolvedDismissLabel}\n >\n <ModalCloseSvg width={18} height={18} aria-hidden=\"true\" />\n </button>\n );\n }\n\n return (\n <div\n className={cx(styles.container, styles.toneRecipe({ tone }), className)}\n role={resolvedRole}\n aria-live={resolvedAriaLive}\n >\n <div className={styles.content}>\n {titleNode}\n {descriptionNode}\n </div>\n\n <div className={styles.actions}>\n {actions}\n {dismissNode}\n </div>\n </div>\n );\n};\n\nexport default InlineBanner;\n"],"mappings":";;;;;;AAyBA,IAAa,KAAgB,EAC3B,UAAO,QACP,OAAA,GACA,aACA,SAAA,GACA,cACA,iBACA,cACA,SACA,kBACoC;CACpC,IAAM,EAAE,SAAM,EAAe,MAAM,EAAE,aAAa,IAAO,CAAC,EACpD,IAAc,OAAO,KAAc,YACnC,IACJ,KAAgB,EAAE,kCAAkC,EAClD,IAAe;CACnB,AAAI,MACF,IAAe,UACX,MAAS,aACX,IAAe;CAGnB,IAAI,IAAmB;CACvB,AAAI,MACF,IAAmB,UACf,MAAS,aACX,IAAmB;CAIvB,IAAI,IAAgC;CACpC,AAAI,KAAS,SACX,IAAY,kBAAC,OAAD;EAAK,WAAW;YAAe;EAAY,CAAA;CAGzD,IAAI,IAAsC;CAC1C,AAAI,KAAY,SACd,IAAkB,kBAAC,OAAD;EAAK,WAAW;EAAqB;EAAe,CAAA;CAGxE,IAAI,IAAkC;CActC,OAbI,MACF,IACE,kBAAC,UAAD;EACE,MAAK;EACL,SAAS;EACT,WAAW;EACX,cAAY;YAEZ,kBAAC,GAAD;GAAe,OAAO;GAAI,QAAQ;GAAI,eAAY;GAAS,CAAA;EACpD,CAAA,GAKX,kBAAC,OAAD;EACE,WAAW,EAAG,GAAkB,EAAkB,EAAE,SAAM,CAAC,EAAE,EAAU;EACvE,MAAM;EACN,aAAW;YAHb,CAKE,kBAAC,OAAD;GAAK,WAAW;aAAhB,CACG,GACA,EACG;MAEN,kBAAC,OAAD;GAAK,WAAW;aAAhB,CACG,GACA,EACG;KACF"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/* empty css */
|
|
2
2
|
/* empty css */
|
|
3
3
|
//#region src/components/feedback/OperationFeedback.css.ts
|
|
4
|
-
var e = "_19ozap70 txvbqbdr8 txvbqbf6i txvbqbffj txvbqb17w0"
|
|
4
|
+
var e = "_19ozap70 txvbqbdr8 txvbqbf6i txvbqbffj txvbqb17w0";
|
|
5
5
|
//#endregion
|
|
6
|
-
export {
|
|
6
|
+
export { e as stack };
|
|
7
7
|
|
|
8
8
|
//# sourceMappingURL=OperationFeedback.css.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OperationFeedback.css.js","names":[],"sources":["../../../../src/components/feedback/OperationFeedback.css.ts"],"sourcesContent":["import { sprinkles } from '../../theme/sprinkles.css.js';\n\nexport const stack = sprinkles({\n display: 'flex',\n flexDirection: 'column',\n gap: 3,\n width: 'full',\n});\n
|
|
1
|
+
{"version":3,"file":"OperationFeedback.css.js","names":[],"sources":["../../../../src/components/feedback/OperationFeedback.css.ts"],"sourcesContent":["import { sprinkles } from '../../theme/sprinkles.css.js';\n\nexport const stack = sprinkles({\n display: 'flex',\n flexDirection: 'column',\n gap: 3,\n width: 'full',\n});\n"],"mappings":""}
|