@elastic/eui 60.1.1 → 60.3.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_theme_dark.css +0 -5
- package/dist/eui_theme_dark.min.css +1 -1
- package/dist/eui_theme_light.css +0 -5
- 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 +1 -1
- package/es/components/comment_list/comment_list.js +1 -1
- package/es/components/comment_list/comment_timeline.js +1 -1
- package/es/components/context_menu/context_menu.js +1 -1
- package/es/components/datagrid/body/data_grid_body.js +37 -28
- 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/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/kubernetesNode.js +41 -0
- 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 +5 -0
- 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 +3 -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.js +2 -0
- 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/eui.d.ts +112 -21
- 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 +1 -1
- package/lib/components/comment_list/comment_list.js +1 -1
- package/lib/components/comment_list/comment_timeline.js +1 -1
- package/lib/components/context_menu/context_menu.js +1 -1
- package/lib/components/datagrid/body/data_grid_body.js +37 -28
- 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 -10
- package/lib/components/datagrid/utils/in_memory.js +26 -23
- package/lib/components/datagrid/utils/ref.js +24 -3
- 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/kubernetesNode.js +48 -0
- 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 +5 -0
- package/lib/components/icon/svgs/cluster.svg +3 -0
- package/lib/components/icon/svgs/container.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 +3 -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.js +2 -0
- 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/optimize/es/components/accordion/accordion.js +10 -5
- package/optimize/es/components/datagrid/body/data_grid_body.js +10 -4
- 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 -10
- package/optimize/es/components/datagrid/utils/ref.js +24 -3
- 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/kubernetesNode.js +37 -0
- 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 +5 -0
- package/optimize/es/components/popover/popover.js +6 -4
- package/optimize/es/components/selectable/selectable.js +2 -0
- package/optimize/es/components/selectable/selectable_list/selectable_list.js +2 -0
- package/optimize/es/components/text/text.js +2 -0
- package/optimize/lib/components/accordion/accordion.js +8 -5
- package/optimize/lib/components/datagrid/body/data_grid_body.js +10 -4
- 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 -10
- package/optimize/lib/components/datagrid/utils/ref.js +24 -3
- 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/kubernetesNode.js +47 -0
- package/optimize/lib/components/icon/assets/kubernetesPod.js +47 -0
- package/optimize/lib/components/icon/assets/namespace.js +47 -0
- package/optimize/lib/components/icon/icon_map.js +5 -0
- 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/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/selectable/selectable_list/selectable_list.js +2 -0
- package/optimize/lib/components/text/text.js +2 -0
- package/package.json +3 -3
- package/src/components/datagrid/body/header/_data_grid_header_row.scss +0 -9
- 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 +1 -1
- package/test-env/components/comment_list/comment_list.js +1 -1
- package/test-env/components/comment_list/comment_timeline.js +1 -1
- package/test-env/components/context_menu/context_menu.js +1 -1
- package/test-env/components/datagrid/body/data_grid_body.js +37 -28
- 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 -10
- 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/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/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 +5 -0
- 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 +3 -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.js +2 -0
- 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
|
@@ -52,7 +52,8 @@ export var Cell = function Cell(_ref) {
|
|
|
52
52
|
schemaDetectors = data.schemaDetectors,
|
|
53
53
|
rowHeightsOptions = data.rowHeightsOptions,
|
|
54
54
|
rowHeightUtils = data.rowHeightUtils,
|
|
55
|
-
rowManager = data.rowManager
|
|
55
|
+
rowManager = data.rowManager,
|
|
56
|
+
pagination = data.pagination;
|
|
56
57
|
var popoverContext = useContext(DataGridCellPopoverContext);
|
|
57
58
|
|
|
58
59
|
var _useContext = useContext(DataGridWrapperRowsContext),
|
|
@@ -91,7 +92,8 @@ export var Cell = function Cell(_ref) {
|
|
|
91
92
|
rowHeightUtils: rowHeightUtils,
|
|
92
93
|
setRowHeight: isFirstColumn ? setRowHeight : undefined,
|
|
93
94
|
rowManager: rowManager,
|
|
94
|
-
popoverContext: popoverContext
|
|
95
|
+
popoverContext: popoverContext,
|
|
96
|
+
pagination: pagination
|
|
95
97
|
};
|
|
96
98
|
|
|
97
99
|
if (isLeadingControlColumn) {
|
|
@@ -385,13 +387,16 @@ export var EuiDataGridBody = function EuiDataGridBody(props) {
|
|
|
385
387
|
}
|
|
386
388
|
}, ___EmotionJSX(Grid, _extends({}, virtualizationOptions ? virtualizationOptions : {}, {
|
|
387
389
|
ref: gridRef,
|
|
390
|
+
className: classNames('euiDataGrid__virtualized', virtualizationOptions === null || virtualizationOptions === void 0 ? void 0 : virtualizationOptions.className),
|
|
388
391
|
onItemsRendered: function onItemsRendered(itemsRendered) {
|
|
392
|
+
var _virtualizationOption;
|
|
393
|
+
|
|
389
394
|
gridItemsRendered.current = itemsRendered;
|
|
395
|
+
virtualizationOptions === null || virtualizationOptions === void 0 ? void 0 : (_virtualizationOption = virtualizationOptions.onItemsRendered) === null || _virtualizationOption === void 0 ? void 0 : _virtualizationOption.call(virtualizationOptions, itemsRendered);
|
|
390
396
|
},
|
|
391
397
|
innerElementType: InnerElement,
|
|
392
398
|
outerRef: outerGridRef,
|
|
393
399
|
innerRef: innerGridRef,
|
|
394
|
-
className: "euiDataGrid__virtualized",
|
|
395
400
|
columnCount: visibleColCount,
|
|
396
401
|
width: finalWidth,
|
|
397
402
|
columnWidth: getColumnWidth,
|
|
@@ -412,7 +417,8 @@ export var EuiDataGridBody = function EuiDataGridBody(props) {
|
|
|
412
417
|
interactiveCellId: interactiveCellId,
|
|
413
418
|
rowHeightsOptions: rowHeightsOptions,
|
|
414
419
|
rowHeightUtils: rowHeightUtils,
|
|
415
|
-
rowManager: rowManager
|
|
420
|
+
rowManager: rowManager,
|
|
421
|
+
pagination: pagination
|
|
416
422
|
},
|
|
417
423
|
rowCount: IS_JEST_ENVIRONMENT || headerRowHeight > 0 ? visibleRowCount : 0
|
|
418
424
|
}), Cell), scrollBorderOverlay) : null;
|
|
@@ -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
|
};
|
|
@@ -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
|
|
@@ -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,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 EuiIconKubernetesNode = function EuiIconKubernetesNode(_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 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"
|
|
34
|
+
}));
|
|
35
|
+
};
|
|
36
|
+
|
|
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;
|
|
@@ -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 EuiIconNamespace = function EuiIconNamespace(_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: "M1 1h14v14H1V1zm13 12v1H2V2h12v11zM6 6h4v4H6V6zm-1 5V5h6v6H5z"
|
|
34
|
+
}));
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export var icon = EuiIconNamespace;
|
|
@@ -49,11 +49,13 @@ export var typeToPathMap = {
|
|
|
49
49
|
cloudDrizzle: 'cloudDrizzle',
|
|
50
50
|
cloudStormy: 'cloudStormy',
|
|
51
51
|
cloudSunny: 'cloudSunny',
|
|
52
|
+
cluster: 'cluster',
|
|
52
53
|
codeApp: 'app_code',
|
|
53
54
|
color: 'color',
|
|
54
55
|
compute: 'compute',
|
|
55
56
|
console: 'console',
|
|
56
57
|
consoleApp: 'app_console',
|
|
58
|
+
container: 'container',
|
|
57
59
|
continuityAbove: 'continuityAbove',
|
|
58
60
|
continuityAboveBelow: 'continuityAboveBelow',
|
|
59
61
|
continuityBelow: 'continuityBelow',
|
|
@@ -180,6 +182,8 @@ export var typeToPathMap = {
|
|
|
180
182
|
kqlOperand: 'kql_operand',
|
|
181
183
|
kqlSelector: 'kql_selector',
|
|
182
184
|
kqlValue: 'kql_value',
|
|
185
|
+
kubernetesNode: 'kubernetesNode',
|
|
186
|
+
kubernetesPod: 'kubernetesPod',
|
|
183
187
|
layers: 'layers',
|
|
184
188
|
lensApp: 'app_lens',
|
|
185
189
|
lettering: 'lettering',
|
|
@@ -277,6 +281,7 @@ export var typeToPathMap = {
|
|
|
277
281
|
mobile: 'mobile',
|
|
278
282
|
monitoringApp: 'app_monitoring',
|
|
279
283
|
moon: 'moon',
|
|
284
|
+
namespace: 'namespace',
|
|
280
285
|
nested: 'nested',
|
|
281
286
|
node: 'node',
|
|
282
287
|
notebookApp: 'app_notebook',
|
|
@@ -10,7 +10,7 @@ import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
|
10
10
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
11
11
|
import _typeof from "@babel/runtime/helpers/typeof";
|
|
12
12
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
13
|
-
var _excluded = ["anchorClassName", "anchorPosition", "button", "buttonRef", "insert", "isOpen", "ownFocus", "children", "className", "closePopover", "panelClassName", "panelPaddingSize", "panelProps", "panelRef", "panelStyle", "popoverRef", "hasArrow", "arrowChildren", "repositionOnScroll", "zIndex", "initialFocus", "attachToAnchor", "display", "onTrapDeactivation", "buffer", "aria-label", "aria-labelledby", "container", "focusTrapProps", "tabIndex"];
|
|
13
|
+
var _excluded = ["anchorClassName", "anchorPosition", "button", "buttonRef", "insert", "isOpen", "ownFocus", "children", "className", "closePopover", "panelClassName", "panelPaddingSize", "panelProps", "panelRef", "panelStyle", "popoverScreenReaderText", "popoverRef", "hasArrow", "arrowChildren", "repositionOnScroll", "zIndex", "initialFocus", "attachToAnchor", "display", "offset", "onTrapDeactivation", "buffer", "aria-label", "aria-labelledby", "container", "focusTrapProps", "tabIndex"];
|
|
14
14
|
|
|
15
15
|
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; }
|
|
16
16
|
|
|
@@ -496,6 +496,7 @@ export var EuiPopover = /*#__PURE__*/function (_Component) {
|
|
|
496
496
|
panelProps = _this$props.panelProps,
|
|
497
497
|
panelRef = _this$props.panelRef,
|
|
498
498
|
panelStyle = _this$props.panelStyle,
|
|
499
|
+
popoverScreenReaderText = _this$props.popoverScreenReaderText,
|
|
499
500
|
popoverRef = _this$props.popoverRef,
|
|
500
501
|
hasArrow = _this$props.hasArrow,
|
|
501
502
|
arrowChildren = _this$props.arrowChildren,
|
|
@@ -504,6 +505,7 @@ export var EuiPopover = /*#__PURE__*/function (_Component) {
|
|
|
504
505
|
initialFocus = _this$props.initialFocus,
|
|
505
506
|
attachToAnchor = _this$props.attachToAnchor,
|
|
506
507
|
display = _this$props.display,
|
|
508
|
+
offset = _this$props.offset,
|
|
507
509
|
onTrapDeactivation = _this$props.onTrapDeactivation,
|
|
508
510
|
buffer = _this$props.buffer,
|
|
509
511
|
ariaLabel = _this$props['aria-label'],
|
|
@@ -549,14 +551,14 @@ export var EuiPopover = /*#__PURE__*/function (_Component) {
|
|
|
549
551
|
|
|
550
552
|
var focusTrapScreenReaderText;
|
|
551
553
|
|
|
552
|
-
if (ownFocus) {
|
|
554
|
+
if (ownFocus || popoverScreenReaderText) {
|
|
553
555
|
ariaDescribedby = this.descriptionId;
|
|
554
556
|
focusTrapScreenReaderText = ___EmotionJSX(EuiScreenReaderOnly, null, ___EmotionJSX("p", {
|
|
555
557
|
id: this.descriptionId
|
|
556
|
-
}, ___EmotionJSX(EuiI18n, {
|
|
558
|
+
}, ownFocus && ___EmotionJSX(EuiI18n, {
|
|
557
559
|
token: "euiPopover.screenReaderAnnouncement",
|
|
558
560
|
default: "You are in a dialog. To close this dialog, hit escape."
|
|
559
|
-
})));
|
|
561
|
+
}), popoverScreenReaderText));
|
|
560
562
|
}
|
|
561
563
|
|
|
562
564
|
var arrowClassNames = classNames('euiPopover__panelArrow', "euiPopover__panelArrow--".concat(this.state.arrowPosition));
|
|
@@ -152,6 +152,8 @@ export var EuiSelectable = /*#__PURE__*/function (_Component) {
|
|
|
152
152
|
event.stopPropagation();
|
|
153
153
|
|
|
154
154
|
if (_this.state.activeOptionIndex != null && optionsList) {
|
|
155
|
+
event.persist(); // NOTE: This is needed for React v16 backwards compatibility
|
|
156
|
+
|
|
155
157
|
optionsList.onAddOrRemoveOption(_this.state.visibleOptions[_this.state.activeOptionIndex], event);
|
|
156
158
|
}
|
|
157
159
|
|
|
@@ -154,6 +154,8 @@ export var EuiSelectableList = /*#__PURE__*/function (_Component) {
|
|
|
154
154
|
setActiveOptionIndex(index);
|
|
155
155
|
},
|
|
156
156
|
onClick: function onClick(event) {
|
|
157
|
+
event.persist(); // NOTE: This is needed for React v16 backwards compatibility
|
|
158
|
+
|
|
157
159
|
_this.onAddOrRemoveOption(option, event);
|
|
158
160
|
},
|
|
159
161
|
ref: ref ? ref.bind(null, index) : undefined,
|