@elastic/eui 60.1.2 → 61.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/eui_charts_theme.js +330 -330
- package/dist/eui_charts_theme.js.map +1 -1
- package/dist/eui_theme_dark.css +9 -178
- package/dist/eui_theme_dark.min.css +1 -1
- package/dist/eui_theme_light.css +9 -178
- package/dist/eui_theme_light.min.css +1 -1
- package/es/components/accessibility/skip_link/skip_link.js +1 -1
- package/es/components/accordion/accordion.js +10 -5
- package/es/components/avatar/avatar.js +1 -1
- package/es/components/badge/badge.js +1 -1
- package/es/components/badge/beta_badge/beta_badge.js +1 -1
- package/es/components/basic_table/basic_table.js +1 -1
- package/es/components/basic_table/collapsed_item_actions.js +1 -1
- package/es/components/basic_table/in_memory_table.js +1 -1
- package/es/components/button/_button_content_deprecated.js +1 -1
- package/es/components/button/button.js +2 -2
- package/es/components/button/button_display/_button_display.js +1 -1
- package/es/components/button/button_display/_button_display_content.js +1 -1
- package/es/components/button/button_empty/button_empty.js +1 -1
- package/es/components/button/button_group/button_group.js +1 -1
- package/es/components/button/button_group/button_group_button.js +1 -1
- package/es/components/button/button_icon/button_icon.js +1 -1
- package/es/components/call_out/call_out.js +1 -1
- package/es/components/card/card.js +1 -1
- package/es/components/card/card_select.js +1 -1
- package/es/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.js +1 -1
- package/es/components/comment_list/comment.js +45 -24
- package/es/components/comment_list/comment_event.js +104 -33
- package/es/components/comment_list/comment_event.styles.js +78 -0
- package/es/components/comment_list/comment_list.js +38 -13
- package/es/components/comment_list/comment_timeline.js +22 -34
- package/es/components/context_menu/context_menu.js +1 -1
- package/es/components/datagrid/body/data_grid_body.js +38 -29
- package/es/components/datagrid/body/data_grid_cell.js +130 -56
- package/es/components/datagrid/body/header/data_grid_header_cell.js +100 -31
- package/es/components/datagrid/body/header/data_grid_header_row.js +27 -24
- package/es/components/datagrid/controls/column_sorting_draggable.js +1 -1
- package/es/components/datagrid/data_grid.js +29 -24
- package/es/components/datagrid/utils/focus.js +19 -10
- package/es/components/datagrid/utils/in_memory.js +26 -23
- package/es/components/datagrid/utils/ref.js +24 -3
- package/es/components/datagrid/utils/row_heights.js +27 -33
- package/es/components/date_picker/date_picker.js +2 -2
- package/es/components/date_picker/date_picker_range.js +1 -1
- package/es/components/empty_prompt/empty_prompt.js +1 -1
- package/es/components/form/field_number/field_number.js +1 -1
- package/es/components/form/field_text/field_text.js +2 -2
- package/es/components/form/form_control_layout/form_control_layout.js +2 -2
- package/es/components/form/form_control_layout/form_control_layout_custom_icon.js +1 -1
- package/es/components/form/form_control_layout/form_control_layout_icons.js +2 -2
- package/es/components/header/header_links/header_link.js +1 -1
- package/es/components/header/header_links/header_links.js +9 -1
- package/es/components/header/header_logo.js +1 -1
- package/es/components/icon/assets/cluster.js +41 -0
- package/es/components/icon/assets/container.js +39 -0
- package/es/components/icon/assets/keyboard.js +38 -0
- package/es/components/icon/assets/{keyboard_shortcut.js → kubernetesNode.js} +7 -4
- package/es/components/icon/assets/kubernetesPod.js +41 -0
- package/es/components/icon/assets/namespace.js +41 -0
- package/es/components/icon/icon.js +1 -1
- package/es/components/icon/icon_map.js +6 -1
- package/es/components/key_pad_menu/key_pad_menu_item.js +1 -1
- package/es/components/list_group/list_group.js +2 -2
- package/es/components/list_group/list_group_item.js +2 -2
- package/es/components/list_group/pinnable_list_group/pinnable_list_group.js +4 -4
- package/es/components/loading/loading_logo.js +1 -1
- package/es/components/markdown_editor/markdown_editor.js +1 -1
- package/es/components/markdown_editor/markdown_editor_drop_zone.js +1 -1
- package/es/components/markdown_editor/markdown_editor_footer.js +1 -1
- package/es/components/markdown_editor/markdown_editor_toolbar.js +1 -1
- package/es/components/notification/notification_event.js +2 -2
- package/es/components/notification/notification_event_meta.js +1 -1
- package/es/components/page/page_header/page_header.js +1 -1
- package/es/components/page/page_header/page_header_content.js +1 -1
- package/es/components/page/page_template.js +1 -1
- package/es/components/pagination/pagination_button.js +1 -1
- package/es/components/popover/popover.js +14 -4
- package/es/components/selectable/selectable.js +2 -0
- package/es/components/selectable/selectable_list/selectable_list.js +1 -1
- package/es/components/selectable/selectable_list/selectable_list_item.js +1 -1
- package/es/components/selectable/selectable_templates/selectable_template_sitewide.js +1 -1
- package/es/components/suggest/suggest.js +1 -1
- package/es/components/suggest/suggest_item.js +1 -1
- package/es/components/table/table_header_button.js +1 -1
- package/es/components/text/text.styles.js +5 -4
- package/es/components/timeline/timeline_item.js +1 -2
- package/es/components/timeline/timeline_item_icon.js +1 -1
- package/es/components/toast/global_toast_list.js +1 -1
- package/es/components/toast/toast.js +1 -1
- package/es/components/token/token.js +1 -1
- package/es/components/tool_tip/icon_tip.js +1 -1
- package/es/components/tour/tour.js +8 -0
- package/es/components/tour/tour_step.js +8 -0
- package/es/services/hooks/index.js +1 -0
- package/es/services/hooks/useLatest.js +18 -0
- package/es/test/emotion-prefix.js +1 -1
- package/eui.d.ts +308 -172
- package/i18ntokens.json +49 -33
- package/lib/components/accessibility/skip_link/skip_link.js +1 -1
- package/lib/components/accordion/accordion.js +10 -5
- package/lib/components/avatar/avatar.js +1 -1
- package/lib/components/badge/badge.js +1 -1
- package/lib/components/badge/beta_badge/beta_badge.js +1 -1
- package/lib/components/basic_table/basic_table.js +1 -1
- package/lib/components/basic_table/collapsed_item_actions.js +1 -1
- package/lib/components/basic_table/in_memory_table.js +1 -1
- package/lib/components/button/_button_content_deprecated.js +1 -1
- package/lib/components/button/button.js +2 -2
- package/lib/components/button/button_display/_button_display.js +1 -1
- package/lib/components/button/button_display/_button_display_content.js +1 -1
- package/lib/components/button/button_empty/button_empty.js +1 -1
- package/lib/components/button/button_group/button_group.js +1 -1
- package/lib/components/button/button_group/button_group_button.js +1 -1
- package/lib/components/button/button_icon/button_icon.js +1 -1
- package/lib/components/call_out/call_out.js +1 -1
- package/lib/components/card/card.js +1 -1
- package/lib/components/card/card_select.js +1 -1
- package/lib/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.js +1 -1
- package/lib/components/comment_list/comment.js +44 -25
- package/lib/components/comment_list/comment_event.js +105 -42
- package/lib/components/comment_list/comment_event.styles.js +86 -0
- package/lib/components/comment_list/comment_list.js +39 -13
- package/lib/components/comment_list/comment_timeline.js +23 -46
- package/lib/components/context_menu/context_menu.js +1 -1
- package/lib/components/datagrid/body/data_grid_body.js +38 -29
- package/lib/components/datagrid/body/data_grid_cell.js +129 -55
- package/lib/components/datagrid/body/header/data_grid_header_cell.js +105 -31
- package/lib/components/datagrid/body/header/data_grid_header_row.js +27 -24
- package/lib/components/datagrid/controls/column_sorting_draggable.js +1 -1
- package/lib/components/datagrid/data_grid.js +29 -24
- package/lib/components/datagrid/utils/focus.js +19 -11
- package/lib/components/datagrid/utils/in_memory.js +26 -23
- package/lib/components/datagrid/utils/ref.js +24 -3
- package/lib/components/datagrid/utils/row_heights.js +26 -32
- package/lib/components/date_picker/date_picker.js +2 -2
- package/lib/components/date_picker/date_picker_range.js +1 -1
- package/lib/components/empty_prompt/empty_prompt.js +1 -1
- package/lib/components/form/field_number/field_number.js +1 -1
- package/lib/components/form/field_text/field_text.js +2 -2
- package/lib/components/form/form_control_layout/form_control_layout.js +2 -2
- package/lib/components/form/form_control_layout/form_control_layout_custom_icon.js +1 -1
- package/lib/components/form/form_control_layout/form_control_layout_icons.js +2 -2
- package/lib/components/header/header_links/header_link.js +1 -1
- package/lib/components/header/header_links/header_links.js +9 -1
- package/lib/components/header/header_logo.js +1 -1
- package/lib/components/icon/assets/cluster.js +48 -0
- package/lib/components/icon/assets/container.js +46 -0
- package/lib/components/icon/assets/keyboard.js +45 -0
- package/lib/components/icon/assets/{keyboard_shortcut.js → kubernetesNode.js} +7 -4
- package/lib/components/icon/assets/kubernetesPod.js +48 -0
- package/lib/components/icon/assets/namespace.js +48 -0
- package/lib/components/icon/icon.js +1 -1
- package/lib/components/icon/icon_map.js +6 -1
- package/lib/components/icon/svgs/cluster.svg +3 -0
- package/lib/components/icon/svgs/container.svg +3 -0
- package/lib/components/icon/svgs/keyboard.svg +3 -0
- package/lib/components/icon/svgs/kubernetesNode.svg +3 -0
- package/lib/components/icon/svgs/kubernetesPod.svg +3 -0
- package/lib/components/icon/svgs/namespace.svg +3 -0
- package/lib/components/key_pad_menu/key_pad_menu_item.js +1 -1
- package/lib/components/list_group/list_group.js +2 -2
- package/lib/components/list_group/list_group_item.js +2 -2
- package/lib/components/list_group/pinnable_list_group/pinnable_list_group.js +4 -4
- package/lib/components/loading/loading_logo.js +1 -1
- package/lib/components/markdown_editor/markdown_editor.js +1 -1
- package/lib/components/markdown_editor/markdown_editor_drop_zone.js +1 -1
- package/lib/components/markdown_editor/markdown_editor_footer.js +1 -1
- package/lib/components/markdown_editor/markdown_editor_toolbar.js +1 -1
- package/lib/components/notification/notification_event.js +2 -2
- package/lib/components/notification/notification_event_meta.js +1 -1
- package/lib/components/page/page_header/page_header.js +1 -1
- package/lib/components/page/page_header/page_header_content.js +1 -1
- package/lib/components/page/page_template.js +1 -1
- package/lib/components/popover/popover.js +14 -4
- package/lib/components/selectable/selectable.js +2 -0
- package/lib/components/selectable/selectable_list/selectable_list.js +1 -1
- package/lib/components/selectable/selectable_list/selectable_list_item.js +1 -1
- package/lib/components/selectable/selectable_templates/selectable_template_sitewide.js +1 -1
- package/lib/components/suggest/suggest.js +1 -1
- package/lib/components/suggest/suggest_item.js +1 -1
- package/lib/components/table/table_header_button.js +1 -1
- package/lib/components/text/text.styles.js +4 -3
- package/lib/components/timeline/timeline_item.js +1 -2
- package/lib/components/timeline/timeline_item_icon.js +1 -1
- package/lib/components/toast/global_toast_list.js +1 -1
- package/lib/components/toast/toast.js +1 -1
- package/lib/components/token/token.js +1 -1
- package/lib/components/tool_tip/icon_tip.js +1 -1
- package/lib/services/hooks/index.js +13 -0
- package/lib/services/hooks/useLatest.js +26 -0
- package/lib/test/emotion-prefix.js +1 -1
- package/optimize/es/components/accordion/accordion.js +10 -5
- package/optimize/es/components/comment_list/comment.js +22 -17
- package/optimize/es/components/comment_list/comment_event.js +83 -28
- package/optimize/es/components/comment_list/comment_event.styles.js +78 -0
- package/optimize/es/components/comment_list/comment_list.js +7 -3
- package/optimize/es/components/comment_list/comment_timeline.js +19 -31
- package/optimize/es/components/datagrid/body/data_grid_body.js +11 -5
- package/optimize/es/components/datagrid/body/data_grid_cell.js +18 -9
- package/optimize/es/components/datagrid/body/header/data_grid_header_cell.js +74 -8
- package/optimize/es/components/datagrid/data_grid.js +2 -0
- package/optimize/es/components/datagrid/utils/focus.js +19 -11
- package/optimize/es/components/datagrid/utils/ref.js +24 -3
- package/optimize/es/components/datagrid/utils/row_heights.js +27 -33
- package/optimize/es/components/icon/assets/cluster.js +37 -0
- package/optimize/es/components/icon/assets/container.js +35 -0
- package/optimize/es/components/icon/assets/keyboard.js +34 -0
- package/optimize/es/components/icon/assets/{keyboard_shortcut.js → kubernetesNode.js} +7 -4
- package/optimize/es/components/icon/assets/kubernetesPod.js +37 -0
- package/optimize/es/components/icon/assets/namespace.js +37 -0
- package/optimize/es/components/icon/icon_map.js +6 -1
- package/optimize/es/components/popover/popover.js +6 -4
- package/optimize/es/components/selectable/selectable.js +2 -0
- package/optimize/es/components/text/text.styles.js +5 -4
- package/optimize/es/components/timeline/timeline_item.js +1 -2
- package/optimize/es/services/hooks/index.js +1 -0
- package/optimize/es/services/hooks/useLatest.js +18 -0
- package/optimize/es/test/emotion-prefix.js +1 -1
- package/optimize/lib/components/accordion/accordion.js +8 -5
- package/optimize/lib/components/comment_list/comment.js +21 -17
- package/optimize/lib/components/comment_list/comment_event.js +85 -31
- package/optimize/lib/components/comment_list/comment_event.styles.js +86 -0
- package/optimize/lib/components/comment_list/comment_list.js +8 -3
- package/optimize/lib/components/comment_list/comment_timeline.js +21 -37
- package/optimize/lib/components/datagrid/body/data_grid_body.js +11 -5
- package/optimize/lib/components/datagrid/body/data_grid_cell.js +17 -8
- package/optimize/lib/components/datagrid/body/header/data_grid_header_cell.js +79 -8
- package/optimize/lib/components/datagrid/data_grid.js +2 -0
- package/optimize/lib/components/datagrid/utils/focus.js +19 -11
- package/optimize/lib/components/datagrid/utils/ref.js +24 -3
- package/optimize/lib/components/datagrid/utils/row_heights.js +25 -30
- package/optimize/lib/components/icon/assets/cluster.js +47 -0
- package/optimize/lib/components/icon/assets/container.js +45 -0
- package/optimize/lib/components/icon/assets/keyboard.js +44 -0
- package/{test-env/components/icon/assets/keyboard_shortcut.js → optimize/lib/components/icon/assets/kubernetesNode.js} +7 -4
- package/optimize/lib/components/icon/assets/{keyboard_shortcut.js → kubernetesPod.js} +7 -4
- package/optimize/lib/components/icon/assets/namespace.js +47 -0
- package/optimize/lib/components/icon/icon_map.js +6 -1
- package/optimize/lib/components/icon/svgs/cluster.svg +3 -0
- package/optimize/lib/components/icon/svgs/container.svg +3 -0
- package/optimize/lib/components/icon/svgs/keyboard.svg +3 -0
- package/optimize/lib/components/icon/svgs/kubernetesNode.svg +3 -0
- package/optimize/lib/components/icon/svgs/kubernetesPod.svg +3 -0
- package/optimize/lib/components/icon/svgs/namespace.svg +3 -0
- package/optimize/lib/components/popover/popover.js +6 -4
- package/optimize/lib/components/selectable/selectable.js +2 -0
- package/optimize/lib/components/text/text.styles.js +4 -3
- package/optimize/lib/components/timeline/timeline_item.js +1 -2
- package/optimize/lib/services/hooks/index.js +13 -0
- package/optimize/lib/services/hooks/useLatest.js +26 -0
- package/optimize/lib/test/emotion-prefix.js +1 -1
- package/package.json +3 -3
- package/src/components/datagrid/body/header/_data_grid_header_row.scss +0 -9
- package/src/components/index.scss +0 -1
- package/src/components/markdown_editor/_markdown_editor.scss +3 -2
- package/src/themes/amsterdam/overrides/_index.scss +0 -1
- package/test-env/components/accessibility/skip_link/skip_link.js +1 -1
- package/test-env/components/accordion/accordion.js +8 -5
- package/test-env/components/avatar/avatar.js +1 -1
- package/test-env/components/badge/badge.js +1 -1
- package/test-env/components/badge/beta_badge/beta_badge.js +1 -1
- package/test-env/components/basic_table/basic_table.js +1 -1
- package/test-env/components/basic_table/collapsed_item_actions.js +1 -1
- package/test-env/components/basic_table/in_memory_table.js +1 -1
- package/test-env/components/button/_button_content_deprecated.js +1 -1
- package/test-env/components/button/button.js +2 -2
- package/test-env/components/button/button_display/_button_display.js +1 -1
- package/test-env/components/button/button_display/_button_display_content.js +1 -1
- package/test-env/components/button/button_empty/button_empty.js +1 -1
- package/test-env/components/button/button_group/button_group.js +1 -1
- package/test-env/components/button/button_group/button_group_button.js +1 -1
- package/test-env/components/button/button_icon/button_icon.js +1 -1
- package/test-env/components/call_out/call_out.js +1 -1
- package/test-env/components/card/card.js +1 -1
- package/test-env/components/card/card_select.js +1 -1
- package/test-env/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.js +1 -1
- package/test-env/components/comment_list/comment.js +44 -24
- package/test-env/components/comment_list/comment_event.js +106 -36
- package/test-env/components/comment_list/comment_event.styles.js +86 -0
- package/test-env/components/comment_list/comment_list.js +39 -13
- package/test-env/components/comment_list/comment_timeline.js +23 -39
- package/test-env/components/context_menu/context_menu.js +1 -1
- package/test-env/components/datagrid/body/data_grid_body.js +38 -29
- package/test-env/components/datagrid/body/data_grid_cell.js +129 -55
- package/test-env/components/datagrid/body/header/data_grid_header_cell.js +105 -31
- package/test-env/components/datagrid/body/header/data_grid_header_row.js +27 -24
- package/test-env/components/datagrid/controls/column_sorting_draggable.js +1 -1
- package/test-env/components/datagrid/data_grid.js +29 -24
- package/test-env/components/datagrid/utils/focus.js +19 -11
- package/test-env/components/datagrid/utils/in_memory.js +26 -23
- package/test-env/components/datagrid/utils/ref.js +24 -3
- package/test-env/components/datagrid/utils/row_heights.js +25 -30
- package/test-env/components/date_picker/date_picker.js +2 -2
- package/test-env/components/date_picker/date_picker_range.js +1 -1
- package/test-env/components/empty_prompt/empty_prompt.js +1 -1
- package/test-env/components/form/field_number/field_number.js +1 -1
- package/test-env/components/form/field_text/field_text.js +2 -2
- package/test-env/components/form/form_control_layout/form_control_layout.js +2 -2
- package/test-env/components/form/form_control_layout/form_control_layout_custom_icon.js +1 -1
- package/test-env/components/form/form_control_layout/form_control_layout_icons.js +2 -2
- package/test-env/components/header/header_links/header_link.js +1 -1
- package/test-env/components/header/header_links/header_links.js +9 -1
- package/test-env/components/header/header_logo.js +1 -1
- package/test-env/components/icon/assets/cluster.js +47 -0
- package/test-env/components/icon/assets/container.js +45 -0
- package/test-env/components/icon/assets/keyboard.js +44 -0
- package/test-env/components/icon/assets/kubernetesNode.js +47 -0
- package/test-env/components/icon/assets/kubernetesPod.js +47 -0
- package/test-env/components/icon/assets/namespace.js +47 -0
- package/test-env/components/icon/icon_map.js +6 -1
- package/test-env/components/key_pad_menu/key_pad_menu_item.js +1 -1
- package/test-env/components/list_group/list_group.js +2 -2
- package/test-env/components/list_group/list_group_item.js +2 -2
- package/test-env/components/list_group/pinnable_list_group/pinnable_list_group.js +4 -4
- package/test-env/components/loading/loading_logo.js +1 -1
- package/test-env/components/markdown_editor/markdown_editor.js +1 -1
- package/test-env/components/markdown_editor/markdown_editor_drop_zone.js +1 -1
- package/test-env/components/markdown_editor/markdown_editor_footer.js +1 -1
- package/test-env/components/markdown_editor/markdown_editor_toolbar.js +1 -1
- package/test-env/components/notification/notification_event.js +2 -2
- package/test-env/components/notification/notification_event_meta.js +1 -1
- package/test-env/components/page/page_header/page_header.js +1 -1
- package/test-env/components/page/page_header/page_header_content.js +1 -1
- package/test-env/components/page/page_template.js +1 -1
- package/test-env/components/popover/popover.js +14 -4
- package/test-env/components/selectable/selectable.js +2 -0
- package/test-env/components/selectable/selectable_list/selectable_list.js +1 -1
- package/test-env/components/selectable/selectable_list/selectable_list_item.js +1 -1
- package/test-env/components/selectable/selectable_templates/selectable_template_sitewide.js +1 -1
- package/test-env/components/suggest/suggest.js +1 -1
- package/test-env/components/suggest/suggest_item.js +1 -1
- package/test-env/components/table/table_header_button.js +1 -1
- package/test-env/components/text/text.styles.js +4 -3
- package/test-env/components/timeline/timeline_item.js +1 -2
- package/test-env/components/timeline/timeline_item_icon.js +1 -1
- package/test-env/components/toast/global_toast_list.js +1 -1
- package/test-env/components/toast/toast.js +1 -1
- package/test-env/components/token/token.js +1 -1
- package/test-env/components/tool_tip/icon_tip.js +1 -1
- package/test-env/services/hooks/index.js +13 -0
- package/test-env/services/hooks/useLatest.js +26 -0
- package/test-env/test/emotion-prefix.js +1 -1
- package/lib/components/icon/svgs/keyboard_shortcut.svg +0 -3
- package/optimize/lib/components/icon/svgs/keyboard_shortcut.svg +0 -3
- package/src/components/comment_list/_comment.scss +0 -38
- package/src/components/comment_list/_comment_event.scss +0 -77
- package/src/components/comment_list/_comment_timeline.scss +0 -27
- package/src/components/comment_list/_index.scss +0 -3
- package/src/themes/amsterdam/overrides/_comment.scss +0 -3
|
@@ -7,8 +7,8 @@ import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
8
8
|
import _extends from "@babel/runtime/helpers/extends";
|
|
9
9
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
10
|
-
var _excluded = ["renderCellValue", "column", "setCellContentsRef", "rowHeightsOptions", "rowIndex", "colIndex", "rowHeightUtils", "isDefinedHeight"],
|
|
11
|
-
_excluded2 = ["width", "popoverContext", "interactiveCellId", "columnType", "className", "column", "style", "rowHeightUtils", "rowHeightsOptions", "rowManager"],
|
|
10
|
+
var _excluded = ["renderCellValue", "column", "setCellContentsRef", "rowHeightsOptions", "rowIndex", "colIndex", "ariaRowIndex", "rowHeightUtils", "isDefinedHeight"],
|
|
11
|
+
_excluded2 = ["width", "popoverContext", "interactiveCellId", "columnType", "className", "column", "style", "rowHeightUtils", "rowHeightsOptions", "rowManager", "pagination"],
|
|
12
12
|
_excluded3 = ["isExpandable", "style", "className", "data-test-subj"];
|
|
13
13
|
|
|
14
14
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
@@ -33,7 +33,7 @@ import { tabbable } from 'tabbable';
|
|
|
33
33
|
import { keys } from '../../../services';
|
|
34
34
|
import { EuiScreenReaderOnly } from '../../accessibility';
|
|
35
35
|
import { EuiFocusTrap } from '../../focus_trap';
|
|
36
|
-
import {
|
|
36
|
+
import { EuiI18n } from '../../i18n';
|
|
37
37
|
import { hasResizeObserver } from '../../observer/resize_observer/resize_observer';
|
|
38
38
|
import { DataGridFocusContext } from '../utils/focus';
|
|
39
39
|
import { EuiDataGridCellActions, EuiDataGridCellPopoverActions } from './data_grid_cell_actions';
|
|
@@ -47,16 +47,13 @@ var EuiDataGridCellContent = /*#__PURE__*/memo(function (_ref) {
|
|
|
47
47
|
rowHeightsOptions = _ref.rowHeightsOptions,
|
|
48
48
|
rowIndex = _ref.rowIndex,
|
|
49
49
|
colIndex = _ref.colIndex,
|
|
50
|
+
ariaRowIndex = _ref.ariaRowIndex,
|
|
50
51
|
rowHeightUtils = _ref.rowHeightUtils,
|
|
51
52
|
isDefinedHeight = _ref.isDefinedHeight,
|
|
52
53
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
53
54
|
|
|
54
55
|
// React is more permissible than the TS types indicate
|
|
55
56
|
var CellElement = renderCellValue;
|
|
56
|
-
var positionText = useEuiI18n('euiDataGridCell.position', 'Row: {row}; Column: {col}', {
|
|
57
|
-
row: rowIndex + 1,
|
|
58
|
-
col: colIndex + 1
|
|
59
|
-
});
|
|
60
57
|
return ___EmotionJSX(React.Fragment, null, ___EmotionJSX("div", {
|
|
61
58
|
ref: setCellContentsRef,
|
|
62
59
|
"data-datagrid-cellcontent": true,
|
|
@@ -68,7 +65,15 @@ var EuiDataGridCellContent = /*#__PURE__*/memo(function (_ref) {
|
|
|
68
65
|
rowIndex: rowIndex,
|
|
69
66
|
colIndex: colIndex,
|
|
70
67
|
schema: (column === null || column === void 0 ? void 0 : column.schema) || rest.columnType
|
|
71
|
-
}, rest))), ___EmotionJSX(EuiScreenReaderOnly, null, ___EmotionJSX("p", null,
|
|
68
|
+
}, rest))), ___EmotionJSX(EuiScreenReaderOnly, null, ___EmotionJSX("p", null, '- ', ___EmotionJSX(EuiI18n, {
|
|
69
|
+
token: "euiDataGridCell.position",
|
|
70
|
+
default: "{columnId}, column {col}, row {row}",
|
|
71
|
+
values: {
|
|
72
|
+
columnId: (column === null || column === void 0 ? void 0 : column.displayAsText) || rest.columnId,
|
|
73
|
+
col: colIndex + 1,
|
|
74
|
+
row: ariaRowIndex
|
|
75
|
+
}
|
|
76
|
+
}))));
|
|
72
77
|
});
|
|
73
78
|
export var EuiDataGridCell = /*#__PURE__*/function (_Component) {
|
|
74
79
|
_inherits(EuiDataGridCell, _Component);
|
|
@@ -473,6 +478,7 @@ export var EuiDataGridCell = /*#__PURE__*/function (_Component) {
|
|
|
473
478
|
rowHeightUtils = _this$props8.rowHeightUtils,
|
|
474
479
|
rowHeightsOptions = _this$props8.rowHeightsOptions,
|
|
475
480
|
rowManager = _this$props8.rowManager,
|
|
481
|
+
pagination = _this$props8.pagination,
|
|
476
482
|
rest = _objectWithoutProperties(_this$props8, _excluded2);
|
|
477
483
|
|
|
478
484
|
var rowIndex = rest.rowIndex,
|
|
@@ -482,6 +488,7 @@ export var EuiDataGridCell = /*#__PURE__*/function (_Component) {
|
|
|
482
488
|
var popoverIsOpen = this.isPopoverOpen();
|
|
483
489
|
var showCellActions = this.state.isFocused || this.state.isEntered || this.state.enableInteractions || popoverIsOpen;
|
|
484
490
|
var cellClasses = classNames('euiDataGridRowCell', (_classNames = {}, _defineProperty(_classNames, "euiDataGridRowCell--".concat(columnType), columnType), _defineProperty(_classNames, 'euiDataGridRowCell--open', popoverIsOpen), _classNames), className);
|
|
491
|
+
var ariaRowIndex = pagination ? visibleRowIndex + 1 + pagination.pageSize * pagination.pageIndex : visibleRowIndex + 1;
|
|
485
492
|
|
|
486
493
|
var _this$state$cellProps2 = this.state.cellProps,
|
|
487
494
|
_ = _this$state$cellProps2.isExpandable,
|
|
@@ -590,7 +597,8 @@ export var EuiDataGridCell = /*#__PURE__*/function (_Component) {
|
|
|
590
597
|
setCellContentsRef: this.setCellContentsRef,
|
|
591
598
|
rowHeightsOptions: rowHeightsOptions,
|
|
592
599
|
rowHeightUtils: rowHeightUtils,
|
|
593
|
-
isDefinedHeight: isDefinedHeight
|
|
600
|
+
isDefinedHeight: isDefinedHeight,
|
|
601
|
+
ariaRowIndex: ariaRowIndex
|
|
594
602
|
});
|
|
595
603
|
|
|
596
604
|
var anchorClass = 'euiDataGridRowCell__expandFlex';
|
|
@@ -637,6 +645,7 @@ export var EuiDataGridCell = /*#__PURE__*/function (_Component) {
|
|
|
637
645
|
|
|
638
646
|
var content = ___EmotionJSX("div", _extends({
|
|
639
647
|
role: "gridcell",
|
|
648
|
+
"aria-rowindex": ariaRowIndex,
|
|
640
649
|
tabIndex: this.state.isFocused && !this.state.disableCellTabIndex ? 0 : -1,
|
|
641
650
|
ref: this.cellRef
|
|
642
651
|
}, cellProps, {
|
|
@@ -10,10 +10,12 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
10
10
|
* Side Public License, v 1.
|
|
11
11
|
*/
|
|
12
12
|
import classnames from 'classnames';
|
|
13
|
-
import React, { useContext, useState } from 'react';
|
|
13
|
+
import React, { useContext, useState, useRef, useCallback } from 'react';
|
|
14
|
+
import { tabbable } from 'tabbable';
|
|
15
|
+
import { keys } from '../../../../services';
|
|
14
16
|
import { useGeneratedHtmlId } from '../../../../services/accessibility';
|
|
15
17
|
import { EuiScreenReaderOnly } from '../../../accessibility';
|
|
16
|
-
import { useEuiI18n } from '../../../i18n';
|
|
18
|
+
import { useEuiI18n, EuiI18n } from '../../../i18n';
|
|
17
19
|
import { EuiIcon } from '../../../icon';
|
|
18
20
|
import { EuiListGroup } from '../../../list_group';
|
|
19
21
|
import { EuiPopover } from '../../../popover';
|
|
@@ -88,6 +90,7 @@ export var EuiDataGridHeaderCell = function EuiDataGridHeaderCell(_ref) {
|
|
|
88
90
|
isPopoverOpen = _useState2[0],
|
|
89
91
|
setIsPopoverOpen = _useState2[1];
|
|
90
92
|
|
|
93
|
+
var popoverArrowNavigationProps = usePopoverArrowNavigation();
|
|
91
94
|
var columnActions = getColumnActions({
|
|
92
95
|
column: column,
|
|
93
96
|
columns: columns,
|
|
@@ -123,9 +126,11 @@ export var EuiDataGridHeaderCell = function EuiDataGridHeaderCell(_ref) {
|
|
|
123
126
|
}) : null, sortString && ___EmotionJSX(EuiScreenReaderOnly, null, ___EmotionJSX("div", {
|
|
124
127
|
id: screenReaderId
|
|
125
128
|
}, sortString)), !showColumnActions ? ___EmotionJSX(React.Fragment, null, sortingArrow, ___EmotionJSX("div", {
|
|
126
|
-
className: "euiDataGridHeaderCell__content"
|
|
127
|
-
|
|
128
|
-
|
|
129
|
+
className: "euiDataGridHeaderCell__content",
|
|
130
|
+
title: displayAsText || id
|
|
131
|
+
}, display || displayAsText || id)) : ___EmotionJSX(EuiPopover, _extends({
|
|
132
|
+
className: "eui-fullWidth",
|
|
133
|
+
anchorClassName: "eui-fullWidth",
|
|
129
134
|
panelPaddingSize: "none",
|
|
130
135
|
offset: 7,
|
|
131
136
|
button: ___EmotionJSX("button", {
|
|
@@ -137,7 +142,8 @@ export var EuiDataGridHeaderCell = function EuiDataGridHeaderCell(_ref) {
|
|
|
137
142
|
});
|
|
138
143
|
}
|
|
139
144
|
}, sortingArrow, ___EmotionJSX("div", {
|
|
140
|
-
className: "euiDataGridHeaderCell__content"
|
|
145
|
+
className: "euiDataGridHeaderCell__content",
|
|
146
|
+
title: displayAsText || id
|
|
141
147
|
}, display || displayAsText || id), ___EmotionJSX(EuiIcon, {
|
|
142
148
|
className: "euiDataGridHeaderCell__icon",
|
|
143
149
|
type: "arrowDown",
|
|
@@ -150,9 +156,69 @@ export var EuiDataGridHeaderCell = function EuiDataGridHeaderCell(_ref) {
|
|
|
150
156
|
closePopover: function closePopover() {
|
|
151
157
|
return setIsPopoverOpen(false);
|
|
152
158
|
}
|
|
153
|
-
},
|
|
159
|
+
}, popoverArrowNavigationProps), ___EmotionJSX(EuiListGroup, {
|
|
154
160
|
listItems: columnActions,
|
|
155
161
|
gutterSize: "none",
|
|
156
162
|
"data-test-subj": "dataGridHeaderCellActionGroup-".concat(id)
|
|
157
|
-
})))
|
|
163
|
+
})));
|
|
164
|
+
};
|
|
165
|
+
/**
|
|
166
|
+
* Add keyboard arrow navigation to the cell actions popover
|
|
167
|
+
* to match the UX of the rest of EuiDataGrid
|
|
168
|
+
*/
|
|
169
|
+
|
|
170
|
+
export var usePopoverArrowNavigation = function usePopoverArrowNavigation() {
|
|
171
|
+
var popoverPanelRef = useRef(null);
|
|
172
|
+
var actionsRef = useRef(undefined);
|
|
173
|
+
var panelRef = useCallback(function (ref) {
|
|
174
|
+
popoverPanelRef.current = ref;
|
|
175
|
+
actionsRef.current = ref ? tabbable(ref) : undefined;
|
|
176
|
+
}, []);
|
|
177
|
+
var onKeyDown = useCallback(function (e) {
|
|
178
|
+
var _actionsRef$current;
|
|
179
|
+
|
|
180
|
+
if (e.key !== keys.ARROW_DOWN && e.key !== keys.ARROW_UP) return;
|
|
181
|
+
if (!((_actionsRef$current = actionsRef.current) !== null && _actionsRef$current !== void 0 && _actionsRef$current.length)) return;
|
|
182
|
+
e.preventDefault();
|
|
183
|
+
var initialState = document.activeElement === popoverPanelRef.current;
|
|
184
|
+
var currentIndex = !initialState ? actionsRef.current.findIndex(function (el) {
|
|
185
|
+
return document.activeElement === el;
|
|
186
|
+
}) : -1;
|
|
187
|
+
var lastIndex = actionsRef.current.length - 1;
|
|
188
|
+
var indexToFocus;
|
|
189
|
+
|
|
190
|
+
if (initialState) {
|
|
191
|
+
if (e.key === keys.ARROW_DOWN) {
|
|
192
|
+
indexToFocus = 0;
|
|
193
|
+
} else if (e.key === keys.ARROW_UP) {
|
|
194
|
+
indexToFocus = lastIndex;
|
|
195
|
+
}
|
|
196
|
+
} else {
|
|
197
|
+
if (e.key === keys.ARROW_DOWN) {
|
|
198
|
+
indexToFocus = currentIndex + 1;
|
|
199
|
+
|
|
200
|
+
if (indexToFocus > lastIndex) {
|
|
201
|
+
indexToFocus = 0;
|
|
202
|
+
}
|
|
203
|
+
} else if (e.key === keys.ARROW_UP) {
|
|
204
|
+
indexToFocus = currentIndex - 1;
|
|
205
|
+
|
|
206
|
+
if (indexToFocus < 0) {
|
|
207
|
+
indexToFocus = lastIndex;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
actionsRef.current[indexToFocus].focus();
|
|
213
|
+
}, []);
|
|
214
|
+
return {
|
|
215
|
+
panelRef: panelRef,
|
|
216
|
+
panelProps: {
|
|
217
|
+
onKeyDown: onKeyDown
|
|
218
|
+
},
|
|
219
|
+
popoverScreenReaderText: ___EmotionJSX(EuiI18n, {
|
|
220
|
+
token: "euiDataGridHeaderCell.actionsPopoverScreenReaderText",
|
|
221
|
+
default: "To navigate through the list of column actions, press the Tab or Up and Down arrow keys."
|
|
222
|
+
})
|
|
223
|
+
};
|
|
158
224
|
};
|
|
@@ -233,6 +233,7 @@ export var EuiDataGrid = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
233
233
|
|
|
234
234
|
useImperativeGridRef({
|
|
235
235
|
ref: ref,
|
|
236
|
+
gridRef: gridRef,
|
|
236
237
|
setIsFullScreen: setIsFullScreen,
|
|
237
238
|
focusContext: focusContext,
|
|
238
239
|
cellPopoverContext: cellPopoverContext,
|
|
@@ -336,6 +337,7 @@ export var EuiDataGrid = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
336
337
|
"data-test-subj": "euiDataGridBody",
|
|
337
338
|
className: "euiDataGrid__content",
|
|
338
339
|
role: "grid",
|
|
340
|
+
"aria-rowcount": rowCount,
|
|
339
341
|
id: gridId
|
|
340
342
|
}, wrappingDivFocusProps, gridAriaProps), ___EmotionJSX(EuiDataGridBody, {
|
|
341
343
|
columns: orderedVisibleColumns,
|
|
@@ -46,11 +46,17 @@ export var useFocus = function useFocus(_ref) {
|
|
|
46
46
|
focusedCell = _useState4[0],
|
|
47
47
|
_setFocusedCell = _useState4[1];
|
|
48
48
|
|
|
49
|
-
var setFocusedCell = useCallback(function (
|
|
50
|
-
|
|
49
|
+
var setFocusedCell = useCallback(function (nextFocusedCell) {
|
|
50
|
+
// If the x/y coordinates remained the same, don't update. This keeps the focusedCell
|
|
51
|
+
// reference stable, and allows it to be used in places that need reference equality.
|
|
52
|
+
if (nextFocusedCell[0] === (focusedCell === null || focusedCell === void 0 ? void 0 : focusedCell[0]) && nextFocusedCell[1] === (focusedCell === null || focusedCell === void 0 ? void 0 : focusedCell[1])) {
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
_setFocusedCell(nextFocusedCell);
|
|
51
57
|
|
|
52
58
|
setIsFocusedCellInView(true); // scrolling.ts ensures focused cells are fully in view
|
|
53
|
-
}, []);
|
|
59
|
+
}, [focusedCell]);
|
|
54
60
|
var previousCell = useRef(undefined);
|
|
55
61
|
useEffect(function () {
|
|
56
62
|
if (previousCell.current) {
|
|
@@ -82,13 +88,16 @@ export var useFocus = function useFocus(_ref) {
|
|
|
82
88
|
tabIndex: -1
|
|
83
89
|
} : {
|
|
84
90
|
tabIndex: 0,
|
|
85
|
-
|
|
86
|
-
//
|
|
87
|
-
//
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
91
|
+
onKeyUp: function onKeyUp(e) {
|
|
92
|
+
// Ensure we only manually focus into the grid via keyboard tab -
|
|
93
|
+
// mouse users can accidentally trigger focus by clicking on scrollbars
|
|
94
|
+
if (e.key === keys.TAB) {
|
|
95
|
+
// if e.target (the source element of the `focus event`) matches
|
|
96
|
+
// e.currentTarget (always the div with this onKeyUp listener)
|
|
97
|
+
// then the user has focused directly on the data grid wrapper
|
|
98
|
+
if (e.target === e.currentTarget) {
|
|
99
|
+
focusFirstVisibleInteractiveCell();
|
|
100
|
+
}
|
|
92
101
|
}
|
|
93
102
|
}
|
|
94
103
|
};
|
|
@@ -141,7 +150,6 @@ export var createKeyDownHandler = function createKeyDownHandler(_ref2) {
|
|
|
141
150
|
|
|
142
151
|
var key = event.key,
|
|
143
152
|
ctrlKey = event.ctrlKey;
|
|
144
|
-
console.log('???', event);
|
|
145
153
|
|
|
146
154
|
if (key === keys.ARROW_DOWN) {
|
|
147
155
|
event.preventDefault();
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
import { useImperativeHandle, useCallback } from 'react';
|
|
9
9
|
export var useImperativeGridRef = function useImperativeGridRef(_ref) {
|
|
10
10
|
var ref = _ref.ref,
|
|
11
|
+
gridRef = _ref.gridRef,
|
|
11
12
|
setIsFullScreen = _ref.setIsFullScreen,
|
|
12
13
|
focusContext = _ref.focusContext,
|
|
13
14
|
cellPopoverContext = _ref.cellPopoverContext,
|
|
@@ -62,16 +63,36 @@ export var useImperativeGridRef = function useImperativeGridRef(_ref) {
|
|
|
62
63
|
rowIndex: visibleRowIndex,
|
|
63
64
|
colIndex: colIndex
|
|
64
65
|
});
|
|
65
|
-
}, [_openCellPopover, checkCellExists, findVisibleRowIndex]);
|
|
66
|
+
}, [_openCellPopover, checkCellExists, findVisibleRowIndex]);
|
|
67
|
+
var scrollTo = useCallback(function () {
|
|
68
|
+
var _gridRef$current;
|
|
69
|
+
|
|
70
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
71
|
+
args[_key] = arguments[_key];
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
return (_gridRef$current = gridRef.current) === null || _gridRef$current === void 0 ? void 0 : _gridRef$current.scrollTo.apply(_gridRef$current, args);
|
|
75
|
+
}, [gridRef]);
|
|
76
|
+
var scrollToItem = useCallback(function () {
|
|
77
|
+
var _gridRef$current2;
|
|
78
|
+
|
|
79
|
+
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
80
|
+
args[_key2] = arguments[_key2];
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
return (_gridRef$current2 = gridRef.current) === null || _gridRef$current2 === void 0 ? void 0 : _gridRef$current2.scrollToItem.apply(_gridRef$current2, args);
|
|
84
|
+
}, [gridRef]); // Set the ref APIs
|
|
66
85
|
|
|
67
86
|
useImperativeHandle(ref, function () {
|
|
68
87
|
return {
|
|
69
88
|
setIsFullScreen: setIsFullScreen,
|
|
70
89
|
setFocusedCell: setFocusedCell,
|
|
71
90
|
openCellPopover: openCellPopover,
|
|
72
|
-
closeCellPopover: closeCellPopover
|
|
91
|
+
closeCellPopover: closeCellPopover,
|
|
92
|
+
scrollTo: scrollTo,
|
|
93
|
+
scrollToItem: scrollToItem
|
|
73
94
|
};
|
|
74
|
-
}, [setIsFullScreen, setFocusedCell, openCellPopover, closeCellPopover]);
|
|
95
|
+
}, [setIsFullScreen, setFocusedCell, openCellPopover, closeCellPopover, scrollTo, scrollToItem]);
|
|
75
96
|
};
|
|
76
97
|
/**
|
|
77
98
|
* Throw a digestible error if the consumer attempts to focus into an invalid
|
|
@@ -13,7 +13,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
13
13
|
*/
|
|
14
14
|
import { useEffect, useState, useMemo, useCallback, useContext } from 'react';
|
|
15
15
|
import { isObject, isNumber } from '../../../services/predicate';
|
|
16
|
-
import { useForceRender } from '../../../services';
|
|
16
|
+
import { useForceRender, useLatest } from '../../../services';
|
|
17
17
|
import { DataGridSortingContext } from './sorting'; // TODO: Once JS variables are available, use them here instead of hard-coded maps
|
|
18
18
|
|
|
19
19
|
export var cellPaddingsMap = {
|
|
@@ -24,11 +24,14 @@ export var cellPaddingsMap = {
|
|
|
24
24
|
export var AUTO_HEIGHT = 'auto';
|
|
25
25
|
export var DEFAULT_ROW_HEIGHT = 34;
|
|
26
26
|
export var RowHeightUtils = /*#__PURE__*/function () {
|
|
27
|
-
function RowHeightUtils() {
|
|
27
|
+
function RowHeightUtils(gridRef, rerenderGridBodyRef) {
|
|
28
28
|
var _this = this;
|
|
29
29
|
|
|
30
30
|
_classCallCheck(this, RowHeightUtils);
|
|
31
31
|
|
|
32
|
+
this.gridRef = gridRef;
|
|
33
|
+
this.rerenderGridBodyRef = rerenderGridBodyRef;
|
|
34
|
+
|
|
32
35
|
_defineProperty(this, "styles", {
|
|
33
36
|
paddingTop: 0,
|
|
34
37
|
paddingBottom: 0
|
|
@@ -63,11 +66,7 @@ export var RowHeightUtils = /*#__PURE__*/function () {
|
|
|
63
66
|
|
|
64
67
|
_defineProperty(this, "timerId", void 0);
|
|
65
68
|
|
|
66
|
-
_defineProperty(this, "grid", void 0);
|
|
67
|
-
|
|
68
69
|
_defineProperty(this, "lastUpdatedRow", Infinity);
|
|
69
|
-
|
|
70
|
-
_defineProperty(this, "rerenderGridBody", function () {});
|
|
71
70
|
}
|
|
72
71
|
|
|
73
72
|
_createClass(RowHeightUtils, [{
|
|
@@ -165,6 +164,8 @@ export var RowHeightUtils = /*#__PURE__*/function () {
|
|
|
165
164
|
}, {
|
|
166
165
|
key: "setRowHeight",
|
|
167
166
|
value: function setRowHeight(rowIndex, colId) {
|
|
167
|
+
var _this$rerenderGridBod, _this$rerenderGridBod2;
|
|
168
|
+
|
|
168
169
|
var height = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : DEFAULT_ROW_HEIGHT;
|
|
169
170
|
var visibleRowIndex = arguments.length > 3 ? arguments[3] : undefined;
|
|
170
171
|
var rowHeights = this.heightsCache.get(rowIndex) || new Map();
|
|
@@ -179,7 +180,7 @@ export var RowHeightUtils = /*#__PURE__*/function () {
|
|
|
179
180
|
this.resetRow(visibleRowIndex); // When an auto row height is updated, force a re-render
|
|
180
181
|
// of the grid body to update the unconstrained height
|
|
181
182
|
|
|
182
|
-
this.
|
|
183
|
+
(_this$rerenderGridBod = (_this$rerenderGridBod2 = this.rerenderGridBodyRef).current) === null || _this$rerenderGridBod === void 0 ? void 0 : _this$rerenderGridBod.call(_this$rerenderGridBod2);
|
|
183
184
|
}
|
|
184
185
|
}, {
|
|
185
186
|
key: "pruneHiddenColumnHeights",
|
|
@@ -219,21 +220,11 @@ export var RowHeightUtils = /*#__PURE__*/function () {
|
|
|
219
220
|
}, {
|
|
220
221
|
key: "resetGrid",
|
|
221
222
|
value: function resetGrid() {
|
|
222
|
-
var _this$
|
|
223
|
+
var _this$gridRef$current;
|
|
223
224
|
|
|
224
|
-
(_this$
|
|
225
|
+
(_this$gridRef$current = this.gridRef.current) === null || _this$gridRef$current === void 0 ? void 0 : _this$gridRef$current.resetAfterRowIndex(this.lastUpdatedRow);
|
|
225
226
|
this.lastUpdatedRow = Infinity;
|
|
226
227
|
}
|
|
227
|
-
}, {
|
|
228
|
-
key: "setGrid",
|
|
229
|
-
value: function setGrid(grid) {
|
|
230
|
-
this.grid = grid;
|
|
231
|
-
}
|
|
232
|
-
}, {
|
|
233
|
-
key: "setRerenderGridBody",
|
|
234
|
-
value: function setRerenderGridBody(rerenderGridBody) {
|
|
235
|
-
this.rerenderGridBody = rerenderGridBody;
|
|
236
|
-
}
|
|
237
228
|
}]);
|
|
238
229
|
|
|
239
230
|
return RowHeightUtils;
|
|
@@ -248,22 +239,25 @@ export var useRowHeightUtils = function useRowHeightUtils(_ref2) {
|
|
|
248
239
|
gridStyles = _ref2.gridStyles,
|
|
249
240
|
columns = _ref2.columns,
|
|
250
241
|
rowHeightsOptions = _ref2.rowHeightsOptions;
|
|
251
|
-
var
|
|
252
|
-
return new RowHeightUtils();
|
|
253
|
-
}, []); // Update rowHeightUtils with internal vars from outside dependencies
|
|
242
|
+
var forceRenderRef = useLatest(useForceRender());
|
|
254
243
|
|
|
255
|
-
var
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
244
|
+
var _useState = useState(function () {
|
|
245
|
+
return new RowHeightUtils(gridRef, forceRenderRef);
|
|
246
|
+
}),
|
|
247
|
+
_useState2 = _slicedToArray(_useState, 1),
|
|
248
|
+
rowHeightUtils = _useState2[0]; // Forces a rerender whenever the row heights change, as this can cause the
|
|
260
249
|
// grid to change height/have scrollbars. Without this, grid rerendering is stale
|
|
261
250
|
|
|
251
|
+
|
|
262
252
|
useEffect(function () {
|
|
263
|
-
|
|
253
|
+
if (forceRenderRef.current == null) {
|
|
254
|
+
return;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
requestAnimationFrame(forceRenderRef.current);
|
|
264
258
|
}, [// Effects that should cause rerendering
|
|
265
259
|
rowHeightsOptions === null || rowHeightsOptions === void 0 ? void 0 : rowHeightsOptions.defaultHeight, rowHeightsOptions === null || rowHeightsOptions === void 0 ? void 0 : rowHeightsOptions.rowHeights, // Dependencies
|
|
266
|
-
rowHeightUtils,
|
|
260
|
+
rowHeightUtils, forceRenderRef]); // Re-cache styles whenever grid density changes
|
|
267
261
|
|
|
268
262
|
useEffect(function () {
|
|
269
263
|
rowHeightUtils.cacheStyles({
|
|
@@ -285,10 +279,10 @@ export var useDefaultRowHeight = function useDefaultRowHeight(_ref3) {
|
|
|
285
279
|
// and ignored by auto & static heights (unless the static height is < the min)
|
|
286
280
|
|
|
287
281
|
|
|
288
|
-
var
|
|
289
|
-
|
|
290
|
-
minRowHeight =
|
|
291
|
-
setRowHeight =
|
|
282
|
+
var _useState3 = useState(DEFAULT_ROW_HEIGHT),
|
|
283
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
284
|
+
minRowHeight = _useState4[0],
|
|
285
|
+
setRowHeight = _useState4[1]; // Default/fallback height for all rows
|
|
292
286
|
|
|
293
287
|
|
|
294
288
|
var defaultRowHeight = useMemo(function () {
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
+
var _excluded = ["title", "titleId"];
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
7
|
+
* or more contributor license agreements. Licensed under the Elastic License
|
|
8
|
+
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
|
9
|
+
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
10
|
+
* Side Public License, v 1.
|
|
11
|
+
*/
|
|
12
|
+
// THIS IS A GENERATED FILE. DO NOT MODIFY MANUALLY. @see scripts/compile-icons.js
|
|
13
|
+
import * as React from 'react';
|
|
14
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
15
|
+
|
|
16
|
+
var EuiIconCluster = function EuiIconCluster(_ref) {
|
|
17
|
+
var title = _ref.title,
|
|
18
|
+
titleId = _ref.titleId,
|
|
19
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
20
|
+
|
|
21
|
+
return ___EmotionJSX("svg", _extends({
|
|
22
|
+
width: 16,
|
|
23
|
+
height: 16,
|
|
24
|
+
viewBox: "0 0 16 16",
|
|
25
|
+
fill: "none",
|
|
26
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
27
|
+
"aria-labelledby": titleId
|
|
28
|
+
}, props), title ? ___EmotionJSX("title", {
|
|
29
|
+
id: titleId
|
|
30
|
+
}, title) : null, ___EmotionJSX("path", {
|
|
31
|
+
fillRule: "evenodd",
|
|
32
|
+
clipRule: "evenodd",
|
|
33
|
+
d: "M4.5 7a2.5 2.5 0 100-5 2.5 2.5 0 000 5zm0-6a3.5 3.5 0 013.465 3h3.12a1.5 1.5 0 110 1h-3.12a3.482 3.482 0 01-.662 1.596l2.1 2.1A3.5 3.5 0 118.036 12h-3.12a1.5 1.5 0 110-.999h3.12a3.482 3.482 0 01.662-1.596l-2.1-2.1A3.5 3.5 0 114.5 1zM12 4.5a.5.5 0 101 0 .5.5 0 00-1 0zm-.5 9.5a2.5 2.5 0 110-5 2.5 2.5 0 010 5zM4 11.5a.5.5 0 11-1 0 .5.5 0 011 0z"
|
|
34
|
+
}));
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export var icon = EuiIconCluster;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
+
var _excluded = ["title", "titleId"];
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
7
|
+
* or more contributor license agreements. Licensed under the Elastic License
|
|
8
|
+
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
|
9
|
+
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
10
|
+
* Side Public License, v 1.
|
|
11
|
+
*/
|
|
12
|
+
// THIS IS A GENERATED FILE. DO NOT MODIFY MANUALLY. @see scripts/compile-icons.js
|
|
13
|
+
import * as React from 'react';
|
|
14
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
15
|
+
|
|
16
|
+
var EuiIconContainer = function EuiIconContainer(_ref) {
|
|
17
|
+
var title = _ref.title,
|
|
18
|
+
titleId = _ref.titleId,
|
|
19
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
20
|
+
|
|
21
|
+
return ___EmotionJSX("svg", _extends({
|
|
22
|
+
fill: "none",
|
|
23
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
24
|
+
viewBox: "0 0 16 16",
|
|
25
|
+
"aria-labelledby": titleId
|
|
26
|
+
}, props), title ? ___EmotionJSX("title", {
|
|
27
|
+
id: titleId
|
|
28
|
+
}, title) : null, ___EmotionJSX("path", {
|
|
29
|
+
fillRule: "evenodd",
|
|
30
|
+
clipRule: "evenodd",
|
|
31
|
+
d: "M0 2.5A.5.5 0 01.5 2h15a.5.5 0 010 1H15v10h.5a.5.5 0 010 1H.5a.5.5 0 010-1H1V3H.5a.5.5 0 01-.5-.5zM2 3h12v10H2V3zm3 2a.5.5 0 00-.5.5v5a.5.5 0 001 0v-5A.5.5 0 005 5zm5.5.5a.5.5 0 011 0v5a.5.5 0 01-1 0v-5zM8 5a.5.5 0 00-.5.5v5a.5.5 0 001 0v-5A.5.5 0 008 5z"
|
|
32
|
+
}));
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
export var icon = EuiIconContainer;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
+
var _excluded = ["title", "titleId"];
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
7
|
+
* or more contributor license agreements. Licensed under the Elastic License
|
|
8
|
+
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
|
9
|
+
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
10
|
+
* Side Public License, v 1.
|
|
11
|
+
*/
|
|
12
|
+
// THIS IS A GENERATED FILE. DO NOT MODIFY MANUALLY. @see scripts/compile-icons.js
|
|
13
|
+
import * as React from 'react';
|
|
14
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
15
|
+
|
|
16
|
+
var EuiIconKeyboard = function EuiIconKeyboard(_ref) {
|
|
17
|
+
var title = _ref.title,
|
|
18
|
+
titleId = _ref.titleId,
|
|
19
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
20
|
+
|
|
21
|
+
return ___EmotionJSX("svg", _extends({
|
|
22
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
23
|
+
viewBox: "0 0 16 16",
|
|
24
|
+
"aria-labelledby": titleId
|
|
25
|
+
}, props), title ? ___EmotionJSX("title", {
|
|
26
|
+
id: titleId
|
|
27
|
+
}, title) : null, ___EmotionJSX("path", {
|
|
28
|
+
fillRule: "evenodd",
|
|
29
|
+
clipRule: "evenodd",
|
|
30
|
+
d: "M0 3h16v11H0V3zm15 10V4H1v9h14zM2 5h2v1H2V5zm2 7v-1H2v1h2zm10-1v1h-2v-1h2zm-3 1v-1H5v1h6zM5 5h1v1H5V5zM3 7H2v1h1V7zm3 0h1v1H6V7zM3 9H2v1h1V9zm3 0h1v1H6V9zm2-4H7v1h1V5zM4 7h1v1H4V7zm5 0H8v1h1V7zm1 0h1v1h-1V7zM5 9H4v1h1V9zm3 0h1v1H8V9zm3 0h-1v1h1V9zM9 5h1v1H9V5zm3 0h-1v1h1V5zm1 0h1v1h-1V5zm1 2h-2v3h2V7z"
|
|
31
|
+
}));
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
export var icon = EuiIconKeyboard;
|
|
@@ -13,22 +13,25 @@ var _excluded = ["title", "titleId"];
|
|
|
13
13
|
import * as React from 'react';
|
|
14
14
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var EuiIconKubernetesNode = function EuiIconKubernetesNode(_ref) {
|
|
17
17
|
var title = _ref.title,
|
|
18
18
|
titleId = _ref.titleId,
|
|
19
19
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
20
20
|
|
|
21
21
|
return ___EmotionJSX("svg", _extends({
|
|
22
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
23
22
|
width: 16,
|
|
24
23
|
height: 16,
|
|
25
24
|
viewBox: "0 0 16 16",
|
|
25
|
+
fill: "none",
|
|
26
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
26
27
|
"aria-labelledby": titleId
|
|
27
28
|
}, props), title ? ___EmotionJSX("title", {
|
|
28
29
|
id: titleId
|
|
29
30
|
}, title) : null, ___EmotionJSX("path", {
|
|
30
|
-
|
|
31
|
+
fillRule: "evenodd",
|
|
32
|
+
clipRule: "evenodd",
|
|
33
|
+
d: "M14 11.42V4.58L8 1.152 2 4.58v6.84l6 3.428 6-3.428zM8 16l7-4V4L8 0 1 4v8l7 4zM8 4.607l3 1.714V9.68l-3 1.714-3-1.714V6.32l3-1.714zm4 1.134v4.518l-4 2.286-4-2.286V5.741l4-2.286 4 2.286z"
|
|
31
34
|
}));
|
|
32
35
|
};
|
|
33
36
|
|
|
34
|
-
export var icon =
|
|
37
|
+
export var icon = EuiIconKubernetesNode;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
+
var _excluded = ["title", "titleId"];
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
7
|
+
* or more contributor license agreements. Licensed under the Elastic License
|
|
8
|
+
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
|
9
|
+
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
10
|
+
* Side Public License, v 1.
|
|
11
|
+
*/
|
|
12
|
+
// THIS IS A GENERATED FILE. DO NOT MODIFY MANUALLY. @see scripts/compile-icons.js
|
|
13
|
+
import * as React from 'react';
|
|
14
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
15
|
+
|
|
16
|
+
var EuiIconKubernetesPod = function EuiIconKubernetesPod(_ref) {
|
|
17
|
+
var title = _ref.title,
|
|
18
|
+
titleId = _ref.titleId,
|
|
19
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
20
|
+
|
|
21
|
+
return ___EmotionJSX("svg", _extends({
|
|
22
|
+
width: 16,
|
|
23
|
+
height: 16,
|
|
24
|
+
viewBox: "0 0 16 16",
|
|
25
|
+
fill: "none",
|
|
26
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
27
|
+
"aria-labelledby": titleId
|
|
28
|
+
}, props), title ? ___EmotionJSX("title", {
|
|
29
|
+
id: titleId
|
|
30
|
+
}, title) : null, ___EmotionJSX("path", {
|
|
31
|
+
fillRule: "evenodd",
|
|
32
|
+
clipRule: "evenodd",
|
|
33
|
+
d: "M14 5.151v6.269l-5.5 3.142V8.29L14 5.151zm-.508-.861L8 1.152 2.508 4.29 8 7.424l5.492-3.134zM2 5.151l5.5 3.14v6.272L2 11.42V5.15zM15 12l-7 4-7-4V4l7-4 7 4v8z"
|
|
34
|
+
}));
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export var icon = EuiIconKubernetesPod;
|