@elastic/eui 116.2.0 → 116.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/es/components/avatar/avatar.js +14 -5
- package/es/components/banner/banner.js +202 -0
- package/es/components/banner/banner.styles.js +76 -0
- package/es/components/banner/index.js +9 -0
- package/es/components/basic_table/basic_table.js +21 -10
- package/es/components/basic_table/collapsed_item_actions.js +5 -4
- package/es/components/basic_table/default_item_action.js +3 -5
- package/es/components/breadcrumbs/_breadcrumb_content.js +29 -19
- package/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +2 -1
- package/es/components/context_menu/context_menu_panel_title.js +0 -12
- package/es/components/datagrid/body/cell/data_grid_cell_actions.js +11 -7
- package/es/components/datagrid/controls/display_selector.js +2 -1
- package/es/components/datagrid/controls/keyboard_shortcuts.js +2 -1
- package/es/components/date_picker/auto_refresh/auto_refresh.js +7 -4
- package/es/components/date_picker/react-datepicker/src/index.js +1 -5
- package/es/components/date_picker/super_date_picker/date_popover/absolute_tab.js +6 -3
- package/es/components/date_picker/super_date_picker/date_popover/date_popover_button.js +10 -2
- package/es/components/date_picker/super_date_picker/date_popover/date_popover_button.styles.js +2 -1
- package/es/components/date_picker/super_date_picker/quick_select_popover/quick_select_popover.js +8 -5
- package/es/components/form/field_password/field_password.js +6 -3
- package/es/components/header/header.a11y.js +1 -1
- package/es/components/index.js +1 -0
- package/es/components/markdown_editor/markdown_editor_help_button.js +7 -4
- package/es/components/pagination/pagination_button_arrow.js +6 -2
- package/es/components/panel/panel.styles.js +4 -4
- package/es/components/panel/split_panel/split_panel.styles.js +1 -1
- package/es/components/search_bar/search_bar.js +20 -16
- package/es/components/search_bar/search_box.js +4 -2
- package/es/components/selectable/selectable_list/selectable_list.js +1 -1
- package/es/components/selectable/selectable_list/selectable_list.styles.js +1 -1
- package/es/components/selectable/selectable_templates/selectable_template_sitewide.js +2 -1
- package/es/components/table/sticky_header/context.js +32 -0
- package/es/components/table/sticky_header/index.js +10 -0
- package/es/components/table/sticky_header/sticky_header.js +151 -0
- package/es/components/table/sticky_header/sticky_header.styles.js +43 -0
- package/es/components/table/store/provider.js +37 -0
- package/es/components/table/store/store.js +82 -0
- package/es/components/table/table.js +28 -3
- package/es/components/table/table.styles.js +4 -4
- package/es/components/table/table_header_cell.js +116 -48
- package/es/components/table/table_header_cell_checkbox.js +59 -25
- package/es/components/text_truncate/text_truncate.js +8 -3
- package/es/components/tool_tip/tool_tip.js +1 -1
- package/es/components/tool_tip/tool_tip.styles.js +14 -5
- package/es/utils/publisher.js +53 -0
- package/eui.d.ts +1266 -975
- package/i18ntokens.json +2390 -2372
- package/lib/components/avatar/avatar.js +14 -5
- package/lib/components/banner/banner.js +211 -0
- package/lib/components/banner/banner.styles.js +80 -0
- package/lib/components/banner/index.js +12 -0
- package/lib/components/basic_table/basic_table.js +21 -10
- package/lib/components/basic_table/collapsed_item_actions.js +5 -4
- package/lib/components/basic_table/default_item_action.js +3 -5
- package/lib/components/breadcrumbs/_breadcrumb_content.js +29 -19
- package/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +2 -1
- package/lib/components/context_menu/context_menu_panel_title.js +0 -12
- package/lib/components/datagrid/body/cell/data_grid_cell_actions.js +11 -7
- package/lib/components/datagrid/controls/display_selector.js +2 -1
- package/lib/components/datagrid/controls/keyboard_shortcuts.js +2 -1
- package/lib/components/date_picker/auto_refresh/auto_refresh.js +7 -4
- package/lib/components/date_picker/react-datepicker/src/index.js +0 -4
- package/lib/components/date_picker/super_date_picker/date_popover/absolute_tab.js +6 -3
- package/lib/components/date_picker/super_date_picker/date_popover/date_popover_button.js +10 -2
- package/lib/components/date_picker/super_date_picker/date_popover/date_popover_button.styles.js +2 -1
- package/lib/components/date_picker/super_date_picker/quick_select_popover/quick_select_popover.js +8 -5
- package/lib/components/form/field_password/field_password.js +6 -3
- package/lib/components/header/header.a11y.js +1 -1
- package/lib/components/index.js +11 -0
- package/lib/components/markdown_editor/markdown_editor_help_button.js +7 -4
- package/lib/components/pagination/pagination_button_arrow.js +6 -2
- package/lib/components/panel/panel.styles.js +4 -4
- package/lib/components/panel/split_panel/split_panel.styles.js +1 -1
- package/lib/components/search_bar/search_bar.js +20 -16
- package/lib/components/search_bar/search_box.js +4 -2
- package/lib/components/selectable/selectable_list/selectable_list.js +1 -1
- package/lib/components/selectable/selectable_list/selectable_list.styles.js +1 -1
- package/lib/components/selectable/selectable_templates/selectable_template_sitewide.js +2 -1
- package/lib/components/table/sticky_header/context.js +41 -0
- package/lib/components/table/sticky_header/index.js +19 -0
- package/lib/components/table/sticky_header/sticky_header.js +156 -0
- package/lib/components/table/sticky_header/sticky_header.styles.js +47 -0
- package/lib/components/table/store/provider.js +46 -0
- package/lib/components/table/store/store.js +87 -0
- package/lib/components/table/table.js +28 -3
- package/lib/components/table/table.styles.js +4 -4
- package/lib/components/table/table_header_cell.js +118 -48
- package/lib/components/table/table_header_cell_checkbox.js +62 -25
- package/lib/components/text_truncate/text_truncate.js +8 -3
- package/lib/components/tool_tip/tool_tip.js +1 -1
- package/lib/components/tool_tip/tool_tip.styles.js +14 -5
- package/lib/utils/publisher.js +59 -0
- package/optimize/es/components/avatar/avatar.js +12 -4
- package/optimize/es/components/banner/banner.js +112 -0
- package/optimize/es/components/banner/banner.styles.js +76 -0
- package/optimize/es/components/banner/index.js +9 -0
- package/optimize/es/components/basic_table/basic_table.js +21 -10
- package/optimize/es/components/basic_table/collapsed_item_actions.js +5 -4
- package/optimize/es/components/basic_table/default_item_action.js +3 -5
- package/optimize/es/components/breadcrumbs/_breadcrumb_content.js +27 -18
- package/optimize/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +2 -1
- package/optimize/es/components/datagrid/body/cell/data_grid_cell_actions.js +11 -7
- package/optimize/es/components/datagrid/controls/display_selector.js +2 -1
- package/optimize/es/components/datagrid/controls/keyboard_shortcuts.js +2 -1
- package/optimize/es/components/date_picker/auto_refresh/auto_refresh.js +7 -4
- package/optimize/es/components/date_picker/react-datepicker/src/index.js +1 -5
- package/optimize/es/components/date_picker/super_date_picker/date_popover/absolute_tab.js +6 -3
- package/optimize/es/components/date_picker/super_date_picker/date_popover/date_popover_button.js +10 -2
- package/optimize/es/components/date_picker/super_date_picker/date_popover/date_popover_button.styles.js +2 -1
- package/optimize/es/components/date_picker/super_date_picker/quick_select_popover/quick_select_popover.js +8 -5
- package/optimize/es/components/form/field_password/field_password.js +6 -3
- package/optimize/es/components/header/header.a11y.js +1 -1
- package/optimize/es/components/index.js +1 -0
- package/optimize/es/components/markdown_editor/markdown_editor_help_button.js +7 -4
- package/optimize/es/components/pagination/pagination_button_arrow.js +6 -2
- package/optimize/es/components/panel/panel.styles.js +4 -4
- package/optimize/es/components/panel/split_panel/split_panel.styles.js +1 -1
- package/optimize/es/components/search_bar/search_bar.js +20 -16
- package/optimize/es/components/search_bar/search_box.js +4 -2
- package/optimize/es/components/selectable/selectable_list/selectable_list.js +1 -1
- package/optimize/es/components/selectable/selectable_list/selectable_list.styles.js +1 -1
- package/optimize/es/components/table/sticky_header/context.js +32 -0
- package/optimize/es/components/table/sticky_header/index.js +10 -0
- package/optimize/es/components/table/sticky_header/sticky_header.js +146 -0
- package/optimize/es/components/table/sticky_header/sticky_header.styles.js +43 -0
- package/optimize/es/components/table/store/provider.js +37 -0
- package/optimize/es/components/table/store/store.js +82 -0
- package/optimize/es/components/table/table.js +15 -3
- package/optimize/es/components/table/table.styles.js +4 -4
- package/optimize/es/components/table/table_header_cell.js +116 -48
- package/optimize/es/components/table/table_header_cell_checkbox.js +59 -25
- package/optimize/es/components/text_truncate/text_truncate.js +8 -3
- package/optimize/es/components/tool_tip/tool_tip.js +1 -1
- package/optimize/es/components/tool_tip/tool_tip.styles.js +14 -5
- package/optimize/es/utils/publisher.js +53 -0
- package/optimize/lib/components/avatar/avatar.js +12 -4
- package/optimize/lib/components/banner/banner.js +121 -0
- package/optimize/lib/components/banner/banner.styles.js +80 -0
- package/optimize/lib/components/banner/index.js +12 -0
- package/optimize/lib/components/basic_table/basic_table.js +21 -10
- package/optimize/lib/components/basic_table/collapsed_item_actions.js +5 -4
- package/optimize/lib/components/basic_table/default_item_action.js +3 -5
- package/optimize/lib/components/breadcrumbs/_breadcrumb_content.js +27 -18
- package/optimize/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +2 -1
- package/optimize/lib/components/datagrid/body/cell/data_grid_cell_actions.js +11 -7
- package/optimize/lib/components/datagrid/controls/display_selector.js +2 -1
- package/optimize/lib/components/datagrid/controls/keyboard_shortcuts.js +2 -1
- package/optimize/lib/components/date_picker/auto_refresh/auto_refresh.js +7 -4
- package/optimize/lib/components/date_picker/react-datepicker/src/index.js +0 -4
- package/optimize/lib/components/date_picker/super_date_picker/date_popover/absolute_tab.js +6 -3
- package/optimize/lib/components/date_picker/super_date_picker/date_popover/date_popover_button.js +10 -2
- package/optimize/lib/components/date_picker/super_date_picker/date_popover/date_popover_button.styles.js +2 -1
- package/optimize/lib/components/date_picker/super_date_picker/quick_select_popover/quick_select_popover.js +8 -5
- package/optimize/lib/components/form/field_password/field_password.js +6 -3
- package/optimize/lib/components/header/header.a11y.js +1 -1
- package/optimize/lib/components/index.js +11 -0
- package/optimize/lib/components/markdown_editor/markdown_editor_help_button.js +7 -4
- package/optimize/lib/components/pagination/pagination_button_arrow.js +6 -2
- package/optimize/lib/components/panel/panel.styles.js +4 -4
- package/optimize/lib/components/panel/split_panel/split_panel.styles.js +1 -1
- package/optimize/lib/components/search_bar/search_bar.js +20 -16
- package/optimize/lib/components/search_bar/search_box.js +4 -2
- package/optimize/lib/components/selectable/selectable_list/selectable_list.js +1 -1
- package/optimize/lib/components/selectable/selectable_list/selectable_list.styles.js +1 -1
- package/optimize/lib/components/table/sticky_header/context.js +41 -0
- package/optimize/lib/components/table/sticky_header/index.js +19 -0
- package/optimize/lib/components/table/sticky_header/sticky_header.js +156 -0
- package/optimize/lib/components/table/sticky_header/sticky_header.styles.js +47 -0
- package/optimize/lib/components/table/store/provider.js +46 -0
- package/optimize/lib/components/table/store/store.js +87 -0
- package/optimize/lib/components/table/table.js +15 -3
- package/optimize/lib/components/table/table.styles.js +4 -4
- package/optimize/lib/components/table/table_header_cell.js +119 -48
- package/optimize/lib/components/table/table_header_cell_checkbox.js +62 -25
- package/optimize/lib/components/text_truncate/text_truncate.js +8 -3
- package/optimize/lib/components/tool_tip/tool_tip.js +1 -1
- package/optimize/lib/components/tool_tip/tool_tip.styles.js +14 -5
- package/optimize/lib/utils/publisher.js +59 -0
- package/package.json +2 -2
- package/test-env/components/avatar/avatar.js +14 -5
- package/test-env/components/banner/banner.js +210 -0
- package/test-env/components/banner/banner.styles.js +80 -0
- package/test-env/components/banner/index.js +12 -0
- package/test-env/components/basic_table/basic_table.js +21 -10
- package/test-env/components/basic_table/collapsed_item_actions.js +5 -4
- package/test-env/components/basic_table/default_item_action.js +3 -5
- package/test-env/components/breadcrumbs/_breadcrumb_content.js +29 -19
- package/test-env/components/combo_box/combo_box_options_list/combo_box_options_list.js +2 -1
- package/test-env/components/context_menu/context_menu_panel_title.js +0 -12
- package/test-env/components/datagrid/body/cell/data_grid_cell_actions.js +11 -7
- package/test-env/components/datagrid/controls/display_selector.js +2 -1
- package/test-env/components/datagrid/controls/keyboard_shortcuts.js +2 -1
- package/test-env/components/date_picker/auto_refresh/auto_refresh.js +7 -4
- package/test-env/components/date_picker/react-datepicker/src/index.js +0 -4
- package/test-env/components/date_picker/super_date_picker/date_popover/absolute_tab.js +6 -3
- package/test-env/components/date_picker/super_date_picker/date_popover/date_popover_button.js +10 -2
- package/test-env/components/date_picker/super_date_picker/date_popover/date_popover_button.styles.js +2 -1
- package/test-env/components/date_picker/super_date_picker/quick_select_popover/quick_select_popover.js +8 -5
- package/test-env/components/form/field_password/field_password.js +6 -3
- package/test-env/components/header/header.a11y.js +1 -1
- package/test-env/components/index.js +11 -0
- package/test-env/components/markdown_editor/markdown_editor_help_button.js +7 -4
- package/test-env/components/pagination/pagination_button_arrow.js +6 -2
- package/test-env/components/panel/panel.styles.js +4 -4
- package/test-env/components/panel/split_panel/split_panel.styles.js +1 -1
- package/test-env/components/search_bar/search_bar.js +20 -16
- package/test-env/components/search_bar/search_box.js +4 -2
- package/test-env/components/selectable/selectable_list/selectable_list.js +1 -1
- package/test-env/components/selectable/selectable_list/selectable_list.styles.js +1 -1
- package/test-env/components/selectable/selectable_templates/selectable_template_sitewide.js +2 -1
- package/test-env/components/table/sticky_header/context.js +41 -0
- package/test-env/components/table/sticky_header/index.js +19 -0
- package/test-env/components/table/sticky_header/sticky_header.js +156 -0
- package/test-env/components/table/sticky_header/sticky_header.styles.js +47 -0
- package/test-env/components/table/store/provider.js +46 -0
- package/test-env/components/table/store/store.js +87 -0
- package/test-env/components/table/table.js +28 -3
- package/test-env/components/table/table.styles.js +4 -4
- package/test-env/components/table/table_header_cell.js +119 -48
- package/test-env/components/table/table_header_cell_checkbox.js +62 -25
- package/test-env/components/text_truncate/text_truncate.js +8 -3
- package/test-env/components/tool_tip/tool_tip.js +1 -1
- package/test-env/components/tool_tip/tool_tip.styles.js +14 -5
- package/test-env/utils/publisher.js +59 -0
|
@@ -48,16 +48,13 @@ export var DefaultItemAction = function DefaultItemAction(_ref) {
|
|
|
48
48
|
className: className,
|
|
49
49
|
"aria-labelledby": ariaLabelId,
|
|
50
50
|
isDisabled: !enabled,
|
|
51
|
+
hasAriaDisabled: !enabled,
|
|
51
52
|
color: color,
|
|
52
53
|
iconType: icon,
|
|
53
54
|
onClick: onClick,
|
|
54
55
|
href: href,
|
|
55
56
|
target: action.target,
|
|
56
57
|
"data-test-subj": dataTestSubj
|
|
57
|
-
// If action is disabled, the normal tooltip can't show - attempt to
|
|
58
|
-
// provide some amount of affordance with a browser title tooltip
|
|
59
|
-
,
|
|
60
|
-
title: !enabled ? tooltipContent : undefined
|
|
61
58
|
});
|
|
62
59
|
// actionContent (action.name) is a ReactNode and must be rendered
|
|
63
60
|
// to an element and referenced by ID for screen readers
|
|
@@ -69,6 +66,7 @@ export var DefaultItemAction = function DefaultItemAction(_ref) {
|
|
|
69
66
|
className: className,
|
|
70
67
|
size: "s",
|
|
71
68
|
isDisabled: !enabled,
|
|
69
|
+
hasAriaDisabled: !enabled,
|
|
72
70
|
color: color,
|
|
73
71
|
iconType: icon,
|
|
74
72
|
onClick: onClick,
|
|
@@ -78,5 +76,5 @@ export var DefaultItemAction = function DefaultItemAction(_ref) {
|
|
|
78
76
|
flush: "right"
|
|
79
77
|
}, actionContent);
|
|
80
78
|
}
|
|
81
|
-
return
|
|
79
|
+
return ___EmotionJSX(React.Fragment, null, ___EmotionJSX(EuiToolTip, tooltipProps, button), ariaLabelledBy);
|
|
82
80
|
};
|
|
@@ -2,9 +2,9 @@ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
import _extends from "@babel/runtime/helpers/extends";
|
|
4
4
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
5
|
-
var _excluded = ["text", "truncate", "type", "href", "rel", "onClick", "popoverContent", "popoverProps", "className", "color", "isFirstBreadcrumb", "isLastBreadcrumb", "isOnlyBreadcrumb", "highlightLastBreadcrumb", "truncateLastBreadcrumb"],
|
|
5
|
+
var _excluded = ["text", "truncate", "type", "href", "rel", "onClick", "popoverContent", "popoverProps", "className", "color", "isFirstBreadcrumb", "isLastBreadcrumb", "isOnlyBreadcrumb", "highlightLastBreadcrumb", "truncateLastBreadcrumb", "title"],
|
|
6
6
|
_excluded2 = ["css"],
|
|
7
|
-
_excluded3 = ["popoverContent", "popoverProps", "color", "type", "title", "aria-current", "className", "isLastBreadcrumb", "breadcrumbCss", "truncationCss", "children"];
|
|
7
|
+
_excluded3 = ["popoverContent", "popoverProps", "color", "type", "title", "hasExplicitTitle", "aria-current", "className", "isLastBreadcrumb", "breadcrumbCss", "truncationCss", "children"];
|
|
8
8
|
/*
|
|
9
9
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
10
10
|
* or more contributor license agreements. Licensed under the Elastic License
|
|
@@ -21,6 +21,7 @@ import { EuiLink } from '../link';
|
|
|
21
21
|
import { EuiPopover } from '../popover';
|
|
22
22
|
import { EuiIcon } from '../icon';
|
|
23
23
|
import { useEuiI18n } from '../i18n';
|
|
24
|
+
import { EuiToolTip } from '../tool_tip';
|
|
24
25
|
import { euiBreadcrumbContentStyles, euiBreadcrumbPopoverStyles } from './_breadcrumb_content.styles';
|
|
25
26
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
26
27
|
export var EuiBreadcrumbContent = function EuiBreadcrumbContent(_ref) {
|
|
@@ -39,6 +40,7 @@ export var EuiBreadcrumbContent = function EuiBreadcrumbContent(_ref) {
|
|
|
39
40
|
isOnlyBreadcrumb = _ref.isOnlyBreadcrumb,
|
|
40
41
|
highlightLastBreadcrumb = _ref.highlightLastBreadcrumb,
|
|
41
42
|
truncateLastBreadcrumb = _ref.truncateLastBreadcrumb,
|
|
43
|
+
propTitle = _ref.title,
|
|
42
44
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
43
45
|
var isApplication = type === 'application';
|
|
44
46
|
var classes = classNames('euiBreadcrumb__content', className);
|
|
@@ -61,8 +63,9 @@ export var EuiBreadcrumbContent = function EuiBreadcrumbContent(_ref) {
|
|
|
61
63
|
var linkColor = color || 'subdued';
|
|
62
64
|
var ariaCurrent = highlightLastBreadcrumb ? 'page' : undefined;
|
|
63
65
|
var interactionStyles = (isInteractiveBreadcrumb || isBreadcrumbWithPopover) && !isApplication && styles.isInteractive;
|
|
66
|
+
var hasExplicitTitle = propTitle != null && propTitle !== '';
|
|
64
67
|
return ___EmotionJSX(EuiInnerText, null, function (ref, innerText) {
|
|
65
|
-
var title = innerText === '' ? undefined : innerText;
|
|
68
|
+
var title = propTitle || (innerText === '' ? undefined : innerText);
|
|
66
69
|
var baseProps = {
|
|
67
70
|
ref: ref,
|
|
68
71
|
title: title,
|
|
@@ -74,6 +77,8 @@ export var EuiBreadcrumbContent = function EuiBreadcrumbContent(_ref) {
|
|
|
74
77
|
var _ = baseProps.css,
|
|
75
78
|
popoverButtonProps = _objectWithoutProperties(baseProps, _excluded2);
|
|
76
79
|
return ___EmotionJSX(EuiBreadcrumbPopover, _extends({}, popoverButtonProps, {
|
|
80
|
+
title: title,
|
|
81
|
+
hasExplicitTitle: hasExplicitTitle,
|
|
77
82
|
breadcrumbCss: [].concat(cssStyles, [interactionStyles]),
|
|
78
83
|
truncationCss: truncationStyles,
|
|
79
84
|
isLastBreadcrumb: isLastBreadcrumb,
|
|
@@ -100,6 +105,7 @@ var EuiBreadcrumbPopover = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
100
105
|
color = _ref2.color,
|
|
101
106
|
type = _ref2.type,
|
|
102
107
|
title = _ref2.title,
|
|
108
|
+
hasExplicitTitle = _ref2.hasExplicitTitle,
|
|
103
109
|
ariaCurrent = _ref2['aria-current'],
|
|
104
110
|
className = _ref2.className,
|
|
105
111
|
isLastBreadcrumb = _ref2.isLastBreadcrumb,
|
|
@@ -128,25 +134,28 @@ var EuiBreadcrumbPopover = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
128
134
|
var wrapperStyles = [styles.popoverWrapper.euiBreadcrumb__popoverWrapper, !isLastBreadcrumb && styles.popoverWrapper[type]];
|
|
129
135
|
var buttonStyles = [styles.euiBreadcrumb__popoverButton].concat(_toConsumableArray(breadcrumbCss));
|
|
130
136
|
var truncationStyles = [styles.euiBreadcrumb__popoverTruncation].concat(_toConsumableArray(truncationCss));
|
|
137
|
+
var linkButton = ___EmotionJSX(EuiLink, _extends({
|
|
138
|
+
ref: ref,
|
|
139
|
+
"aria-current": ariaCurrent,
|
|
140
|
+
className: className,
|
|
141
|
+
css: buttonStyles,
|
|
142
|
+
color: color,
|
|
143
|
+
onClick: togglePopover
|
|
144
|
+
}, rest), ___EmotionJSX("span", {
|
|
145
|
+
css: truncationStyles
|
|
146
|
+
}, children), ___EmotionJSX(EuiIcon, {
|
|
147
|
+
type: "chevronSingleDown",
|
|
148
|
+
size: "s",
|
|
149
|
+
"aria-label": " - ".concat(popoverAriaLabel)
|
|
150
|
+
}));
|
|
131
151
|
return ___EmotionJSX(EuiPopover, _extends({}, popoverProps, {
|
|
132
152
|
isOpen: isPopoverOpen,
|
|
133
153
|
closePopover: closePopover,
|
|
134
154
|
css: wrapperStyles,
|
|
135
|
-
button: ___EmotionJSX(
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
className: className,
|
|
140
|
-
css: buttonStyles,
|
|
141
|
-
color: color,
|
|
142
|
-
onClick: togglePopover
|
|
143
|
-
}, rest), ___EmotionJSX("span", {
|
|
144
|
-
css: truncationStyles
|
|
145
|
-
}, children), ___EmotionJSX(EuiIcon, {
|
|
146
|
-
type: "chevronSingleDown",
|
|
147
|
-
size: "s",
|
|
148
|
-
"aria-label": " - ".concat(popoverAriaLabel)
|
|
149
|
-
}))
|
|
155
|
+
button: title ? ___EmotionJSX(EuiToolTip, {
|
|
156
|
+
content: title,
|
|
157
|
+
disableScreenReaderOutput: !hasExplicitTitle
|
|
158
|
+
}, linkButton) : linkButton
|
|
150
159
|
}), typeof popoverContent === 'function' ? popoverContent(closePopover) : popoverContent);
|
|
151
160
|
});
|
|
152
161
|
EuiBreadcrumbPopover.displayName = 'EuiBreadcrumbPopover';
|
|
@@ -121,6 +121,7 @@ export var EuiComboBoxOptionsList = /*#__PURE__*/function (_Component) {
|
|
|
121
121
|
var optionIsFocused = activeOptionIndex === index;
|
|
122
122
|
var optionIsDisabled = option.hasOwnProperty('disabled') && option.disabled === true;
|
|
123
123
|
var hasOnFocusBadge = onFocusBadge && optionIsFocused && !optionIsDisabled;
|
|
124
|
+
var hasNativeTruncation = !hasTruncationProps && !searchValue && rowHeight !== 'auto';
|
|
124
125
|
return ___EmotionJSX(EuiListItemLayout, _extends({
|
|
125
126
|
element: "li",
|
|
126
127
|
role: "option"
|
|
@@ -135,8 +136,8 @@ export var EuiComboBoxOptionsList = /*#__PURE__*/function (_Component) {
|
|
|
135
136
|
// loses focus on selecting an option (due to actively removing it from the list)
|
|
136
137
|
,
|
|
137
138
|
id: rootId("_option-".concat(options.indexOf(option))),
|
|
139
|
+
title: hasNativeTruncation && !toolTipContent ? label : undefined,
|
|
138
140
|
key: (_option$key = option.key) !== null && _option$key !== void 0 ? _option$key : option.label,
|
|
139
|
-
title: label,
|
|
140
141
|
prepend: option.prepend,
|
|
141
142
|
append: hasOnFocusBadge ? ___EmotionJSX(React.Fragment, null, option.append, hitEnterBadge) : option.append,
|
|
142
143
|
checked: checked,
|
|
@@ -16,6 +16,7 @@ import { EuiButtonIcon } from '../../../button/button_icon';
|
|
|
16
16
|
import { EuiButtonEmpty } from '../../../button/button_empty';
|
|
17
17
|
import { EuiFlexGroup, EuiFlexItem } from '../../../flex';
|
|
18
18
|
import { EuiPopoverFooter } from '../../../popover';
|
|
19
|
+
import { EuiToolTip } from '../../../tool_tip';
|
|
19
20
|
import { euiDataGridCellActionsStyles } from './data_grid_cell_actions.styles';
|
|
20
21
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
21
22
|
export var EuiDataGridCellActions = function EuiDataGridCellActions(_ref) {
|
|
@@ -36,18 +37,21 @@ export var EuiDataGridCellActions = function EuiDataGridCellActions(_ref) {
|
|
|
36
37
|
token: "euiDataGridCellActions.expandButtonTitle",
|
|
37
38
|
default: "Click or hit enter to interact with cell content"
|
|
38
39
|
}, function (expandButtonTitle) {
|
|
39
|
-
return ___EmotionJSX(
|
|
40
|
-
|
|
40
|
+
return ___EmotionJSX(EuiToolTip, {
|
|
41
|
+
content: expandButtonTitle,
|
|
42
|
+
disableScreenReaderOutput: true,
|
|
43
|
+
display: "flex"
|
|
44
|
+
}, ___EmotionJSX(EuiButtonIcon, {
|
|
45
|
+
"aria-hidden": true,
|
|
41
46
|
className: "euiDataGridRowCell__actionButtonIcon euiDataGridRowCell__expandCell",
|
|
47
|
+
color: "primary",
|
|
48
|
+
css: styles.euiDataGridRowCell__actionButtonIcon,
|
|
42
49
|
"data-test-subj": "euiDataGridCellExpandButton",
|
|
43
50
|
display: "fill",
|
|
44
|
-
color: "primary",
|
|
45
51
|
iconSize: "s",
|
|
46
52
|
iconType: "maximize",
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
title: expandButtonTitle
|
|
50
|
-
});
|
|
53
|
+
onClick: onExpandClick
|
|
54
|
+
}));
|
|
51
55
|
});
|
|
52
56
|
}, [onExpandClick, styles]);
|
|
53
57
|
var additionalButtons = useMemo(function () {
|
|
@@ -353,7 +353,8 @@ export var useDataGridDisplaySelector = function useDataGridDisplaySelector(show
|
|
|
353
353
|
},
|
|
354
354
|
panelClassName: "euiDataGrid__displayPopoverPanel",
|
|
355
355
|
button: ___EmotionJSX(EuiToolTip, {
|
|
356
|
-
content: buttonLabel
|
|
356
|
+
content: buttonLabel,
|
|
357
|
+
disableScreenReaderOutput: true
|
|
357
358
|
}, ___EmotionJSX(EuiButtonIcon, {
|
|
358
359
|
size: "xs",
|
|
359
360
|
iconType: "controls",
|
|
@@ -35,7 +35,8 @@ export var useDataGridKeyboardShortcuts = function useDataGridKeyboardShortcuts(
|
|
|
35
35
|
anchorPosition: "downRight",
|
|
36
36
|
panelPaddingSize: "none",
|
|
37
37
|
button: ___EmotionJSX(EuiToolTip, {
|
|
38
|
-
content: title
|
|
38
|
+
content: title,
|
|
39
|
+
disableScreenReaderOutput: true
|
|
39
40
|
}, ___EmotionJSX(EuiButtonIcon, {
|
|
40
41
|
size: "xs",
|
|
41
42
|
iconType: "keyboard",
|
|
@@ -16,6 +16,7 @@ import classNames from 'classnames';
|
|
|
16
16
|
import { EuiFieldText, EuiFormPrepend } from '../../form';
|
|
17
17
|
import { EuiButtonEmpty } from '../../button/button_empty/button_empty';
|
|
18
18
|
import { EuiInputPopover, EuiPopover } from '../../popover';
|
|
19
|
+
import { EuiToolTip } from '../../tool_tip';
|
|
19
20
|
import { useEuiI18n } from '../../i18n';
|
|
20
21
|
import { usePrettyInterval } from '../super_date_picker/pretty_interval';
|
|
21
22
|
import { EuiRefreshInterval } from './refresh_interval';
|
|
@@ -110,7 +111,9 @@ export var EuiAutoRefreshButton = function EuiAutoRefreshButton(_ref2) {
|
|
|
110
111
|
})
|
|
111
112
|
});
|
|
112
113
|
return ___EmotionJSX(EuiPopover, {
|
|
113
|
-
button: ___EmotionJSX(
|
|
114
|
+
button: ___EmotionJSX(EuiToolTip, {
|
|
115
|
+
content: isPaused ? autoRefeshLabelOff : autoRefeshLabelOn
|
|
116
|
+
}, ___EmotionJSX(EuiButtonEmpty, _extends({
|
|
114
117
|
onClick: function onClick() {
|
|
115
118
|
return setIsPopoverOpen(function (isOpen) {
|
|
116
119
|
return !isOpen;
|
|
@@ -120,12 +123,12 @@ export var EuiAutoRefreshButton = function EuiAutoRefreshButton(_ref2) {
|
|
|
120
123
|
size: size,
|
|
121
124
|
color: color,
|
|
122
125
|
iconType: "refreshTime",
|
|
123
|
-
|
|
124
|
-
|
|
126
|
+
isDisabled: isDisabled,
|
|
127
|
+
hasAriaDisabled: isDisabled
|
|
125
128
|
}, rest), usePrettyInterval(Boolean(isPaused), refreshInterval, {
|
|
126
129
|
shortHand: shortHand,
|
|
127
130
|
unit: intervalUnits
|
|
128
|
-
})),
|
|
131
|
+
}))),
|
|
129
132
|
isOpen: isPopoverOpen,
|
|
130
133
|
closePopover: function closePopover() {
|
|
131
134
|
setIsPopoverOpen(false);
|
|
@@ -36,7 +36,7 @@ import Calendar from "./calendar";
|
|
|
36
36
|
import React from "react";
|
|
37
37
|
import PropTypes from "prop-types";
|
|
38
38
|
import classnames from "classnames";
|
|
39
|
-
import { newDate, now, cloneDate, isMoment, isDate, isBefore, isAfter, equals, setTime, getMillisecond, getSecond, getMinute, getHour, addDays, addMonths, addWeeks, addYears, subtractDays, subtractMonths, subtractWeeks, subtractYears, isSameTime, isDayDisabled,
|
|
39
|
+
import { newDate, now, cloneDate, isMoment, isDate, isBefore, isAfter, equals, setTime, getMillisecond, getSecond, getMinute, getHour, addDays, addMonths, addWeeks, addYears, subtractDays, subtractMonths, subtractWeeks, subtractYears, isSameTime, isDayDisabled, isDayInRange, getEffectiveMinDate, getEffectiveMaxDate, parseDate, safeDateFormat, getHightLightDaysMap, getYear, getMonth } from "./date_utils";
|
|
40
40
|
import { EuiPopover, popoverAnchorPosition } from '../../../popover/popover';
|
|
41
41
|
import { EuiFieldText } from '../../../form/field_text';
|
|
42
42
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
@@ -248,10 +248,6 @@ var DatePicker = /*#__PURE__*/function (_React$Component) {
|
|
|
248
248
|
_defineProperty(_this, "setSelected", function (date, event, keepInput) {
|
|
249
249
|
var changedDate = date;
|
|
250
250
|
if (changedDate !== null && isDayDisabled(changedDate, _this.props)) {
|
|
251
|
-
if (isOutOfBounds(changedDate, _this.props)) {
|
|
252
|
-
_this.props.onChange(date, event);
|
|
253
|
-
_this.props.onSelect(changedDate, event);
|
|
254
|
-
}
|
|
255
251
|
return;
|
|
256
252
|
}
|
|
257
253
|
if (changedDate !== null && _this.props.selected) {
|
|
@@ -16,6 +16,7 @@ import { useEuiI18n } from '../../../i18n';
|
|
|
16
16
|
import { EuiFormRow, EuiFieldText, EuiFormLabel } from '../../../form';
|
|
17
17
|
import { EuiFlexGroup } from '../../../flex';
|
|
18
18
|
import { EuiButtonIcon } from '../../../button';
|
|
19
|
+
import { EuiToolTip } from '../../../tool_tip';
|
|
19
20
|
import { EuiCode } from '../../../code';
|
|
20
21
|
import { EuiDatePicker } from '../../date_picker';
|
|
21
22
|
import { EuiTimeZoneDisplay } from './timezone_display';
|
|
@@ -174,16 +175,18 @@ export var EuiAbsoluteTab = function EuiAbsoluteTab(_ref) {
|
|
|
174
175
|
prepend: ___EmotionJSX(EuiFormLabel, {
|
|
175
176
|
id: textInputLabelId
|
|
176
177
|
}, labelPrefix)
|
|
177
|
-
})), hasUnparsedText && ___EmotionJSX(
|
|
178
|
+
})), hasUnparsedText && ___EmotionJSX(EuiToolTip, {
|
|
179
|
+
content: submitButtonLabel,
|
|
180
|
+
disableScreenReaderOutput: true
|
|
181
|
+
}, ___EmotionJSX(EuiButtonIcon, {
|
|
178
182
|
type: "submit",
|
|
179
183
|
css: styles.euiAbsoluteTabDateForm__submit,
|
|
180
184
|
size: "s",
|
|
181
185
|
display: "base",
|
|
182
186
|
iconType: "check",
|
|
183
187
|
"aria-label": submitButtonLabel,
|
|
184
|
-
title: submitButtonLabel,
|
|
185
188
|
"data-test-subj": "parseAbsoluteDateFormat"
|
|
186
|
-
})), ___EmotionJSX(EuiTimeZoneDisplay, _extends({
|
|
189
|
+
}))), ___EmotionJSX(EuiTimeZoneDisplay, _extends({
|
|
187
190
|
id: timeZomeDescriptionId
|
|
188
191
|
}, timeZoneDisplayProps)));
|
|
189
192
|
};
|
package/optimize/es/components/date_picker/super_date_picker/date_popover/date_popover_button.js
CHANGED
|
@@ -16,6 +16,7 @@ import classNames from 'classnames';
|
|
|
16
16
|
import { useEuiMemoizedStyles } from '../../../../services';
|
|
17
17
|
import { useEuiI18n } from '../../../i18n';
|
|
18
18
|
import { EuiPopover } from '../../../popover';
|
|
19
|
+
import { EuiToolTip } from '../../../tool_tip';
|
|
19
20
|
import { useFormatTimeString } from '../pretty_duration';
|
|
20
21
|
import { EuiDatePopoverContent } from './date_popover_content';
|
|
21
22
|
import { euiDatePopoverButtonStyles } from './date_popover_button.styles';
|
|
@@ -70,16 +71,23 @@ export var EuiDatePopoverButton = function EuiDatePopoverButton(props) {
|
|
|
70
71
|
} else if (needsUpdating) {
|
|
71
72
|
title = outdatedTitle;
|
|
72
73
|
}
|
|
73
|
-
var
|
|
74
|
+
var rawButton = ___EmotionJSX("button", _extends({
|
|
74
75
|
type: "button",
|
|
75
76
|
onClick: onPopoverToggle,
|
|
76
77
|
className: classes,
|
|
77
|
-
title: title,
|
|
78
78
|
disabled: isDisabled,
|
|
79
79
|
"data-test-subj": "superDatePicker".concat(position, "DatePopoverButton")
|
|
80
80
|
}, buttonProps, {
|
|
81
81
|
css: cssStyles
|
|
82
82
|
}), formattedValue);
|
|
83
|
+
var button = title ? ___EmotionJSX(EuiToolTip, {
|
|
84
|
+
content: title,
|
|
85
|
+
display: "block",
|
|
86
|
+
disableScreenReaderOutput: !isInvalid && !needsUpdating,
|
|
87
|
+
anchorProps: {
|
|
88
|
+
css: styles.tooltipAnchor
|
|
89
|
+
}
|
|
90
|
+
}, rawButton) : rawButton;
|
|
83
91
|
return ___EmotionJSX(EuiPopover, _extends({
|
|
84
92
|
button: button,
|
|
85
93
|
isOpen: isOpen,
|
|
@@ -21,7 +21,8 @@ var _ref = process.env.NODE_ENV === "production" ? {
|
|
|
21
21
|
export var euiDatePopoverButtonStyles = function euiDatePopoverButtonStyles(euiThemeContext) {
|
|
22
22
|
return {
|
|
23
23
|
euiDatePopoverButton: /*#__PURE__*/css(_buttonStyles(euiThemeContext), ";;label:euiDatePopoverButton;"),
|
|
24
|
-
now: _ref
|
|
24
|
+
now: _ref,
|
|
25
|
+
tooltipAnchor: /*#__PURE__*/css(logicalCSS('height', '100%'), " ", logicalCSS('width', '100%'), ";;label:tooltipAnchor;")
|
|
25
26
|
};
|
|
26
27
|
};
|
|
27
28
|
export var _buttonStyles = function _buttonStyles(euiThemeContext) {
|
|
@@ -16,6 +16,7 @@ import { useEuiMemoizedStyles } from '../../../../services';
|
|
|
16
16
|
import { useEuiI18n } from '../../../i18n';
|
|
17
17
|
import { EuiPopover } from '../../../popover';
|
|
18
18
|
import { EuiFormPrepend } from '../../../form';
|
|
19
|
+
import { EuiToolTip } from '../../../tool_tip';
|
|
19
20
|
import { euiQuickSelectPopoverStyles } from './quick_select_popover.styles';
|
|
20
21
|
import { EuiQuickSelectPanel } from './quick_select_panel';
|
|
21
22
|
import { EuiQuickSelect } from './quick_select';
|
|
@@ -63,21 +64,23 @@ export var EuiQuickSelectPopover = function EuiQuickSelectPopover(_ref) {
|
|
|
63
64
|
closePopover();
|
|
64
65
|
}
|
|
65
66
|
}, [_applyTime, closePopover]);
|
|
66
|
-
var
|
|
67
|
+
var buttonLabel = useEuiI18n('euiQuickSelectPopover.buttonLabel', 'Date quick select');
|
|
67
68
|
var quickSelectButtonOnClick = function quickSelectButtonOnClick(e) {
|
|
68
69
|
togglePopover();
|
|
69
70
|
buttonOnClick === null || buttonOnClick === void 0 || buttonOnClick(e);
|
|
70
71
|
};
|
|
71
|
-
var quickSelectButton = ___EmotionJSX(
|
|
72
|
+
var quickSelectButton = ___EmotionJSX(EuiToolTip, {
|
|
73
|
+
content: buttonLabel,
|
|
74
|
+
disableScreenReaderOutput: true
|
|
75
|
+
}, ___EmotionJSX(EuiFormPrepend, _extends({
|
|
72
76
|
element: "button",
|
|
73
77
|
iconLeft: "calendar",
|
|
74
78
|
iconRight: "chevronSingleDown",
|
|
75
79
|
isDisabled: props.isDisabled,
|
|
76
80
|
onClick: quickSelectButtonOnClick,
|
|
77
|
-
"aria-label":
|
|
78
|
-
title: buttonlabel,
|
|
81
|
+
"aria-label": buttonLabel,
|
|
79
82
|
"data-test-subj": "superDatePickerToggleQuickMenuButton"
|
|
80
|
-
}, quickSelectButtonProps));
|
|
83
|
+
}, quickSelectButtonProps)));
|
|
81
84
|
return ___EmotionJSX(EuiPopover, {
|
|
82
85
|
button: quickSelectButton,
|
|
83
86
|
isOpen: isOpen,
|
|
@@ -16,6 +16,7 @@ import classNames from 'classnames';
|
|
|
16
16
|
import { useCombinedRefs, useEuiMemoizedStyles } from '../../../services';
|
|
17
17
|
import { useEuiI18n } from '../../i18n';
|
|
18
18
|
import { EuiButtonIcon } from '../../button';
|
|
19
|
+
import { EuiToolTip } from '../../tool_tip';
|
|
19
20
|
import { EuiFormControlLayout } from '../form_control_layout';
|
|
20
21
|
import { EuiValidatableControl } from '../validatable_control';
|
|
21
22
|
import { useFormContext } from '../eui_form_context';
|
|
@@ -76,16 +77,18 @@ export var EuiFieldPassword = function EuiFieldPassword(props) {
|
|
|
76
77
|
var visibilityToggle = useMemo(function () {
|
|
77
78
|
if (type === 'dual') {
|
|
78
79
|
var isVisible = inputType === 'text';
|
|
79
|
-
return ___EmotionJSX(
|
|
80
|
+
return ___EmotionJSX(EuiToolTip, {
|
|
81
|
+
content: isVisible ? maskPasswordLabel : showPasswordLabel,
|
|
82
|
+
disableScreenReaderOutput: true
|
|
83
|
+
}, ___EmotionJSX(EuiButtonIcon, _extends({
|
|
80
84
|
iconType: isVisible ? 'eyeSlash' : 'eye',
|
|
81
85
|
"aria-label": isVisible ? maskPasswordLabel : showPasswordLabel,
|
|
82
|
-
title: isVisible ? maskPasswordLabel : showPasswordLabel,
|
|
83
86
|
disabled: disabled
|
|
84
87
|
}, dualToggleProps, {
|
|
85
88
|
onClick: function onClick(e) {
|
|
86
89
|
return handleToggle(e, isVisible);
|
|
87
90
|
}
|
|
88
|
-
}));
|
|
91
|
+
})));
|
|
89
92
|
}
|
|
90
93
|
}, [type, inputType, maskPasswordLabel, showPasswordLabel, dualToggleProps, handleToggle, disabled]);
|
|
91
94
|
var finalAppend = useMemo(function () {
|
|
@@ -327,7 +327,7 @@ describe('EuiHeader', function () {
|
|
|
327
327
|
cy.checkAxe();
|
|
328
328
|
});
|
|
329
329
|
it('has zero violations when a hidden breadcrumb is expanded', function () {
|
|
330
|
-
cy.get('
|
|
330
|
+
cy.get('[aria-label="See collapsed breadcrumbs"]').realClick();
|
|
331
331
|
cy.get('a[data-test-subj="cy-breadcrumb-hidden"]').should('exist');
|
|
332
332
|
cy.checkAxe();
|
|
333
333
|
});
|
|
@@ -59,7 +59,8 @@ export var EuiMarkdownEditorHelpButton = function EuiMarkdownEditorHelpButton(_r
|
|
|
59
59
|
var hasUiPluginsWithHelpText = uiPluginsWithHelpText.length > 0;
|
|
60
60
|
if (hasUiPluginsWithHelpText) {
|
|
61
61
|
return ___EmotionJSX(React.Fragment, null, ___EmotionJSX(EuiToolTip, _extends({}, tooltipProps, {
|
|
62
|
-
content: syntaxTitle
|
|
62
|
+
content: syntaxTitle,
|
|
63
|
+
disableScreenReaderOutput: true
|
|
63
64
|
}), ___EmotionJSX(EuiButtonIcon, {
|
|
64
65
|
size: "s",
|
|
65
66
|
css: styles.euiMarkdownEditorFooter__helpButton,
|
|
@@ -109,8 +110,10 @@ export var EuiMarkdownEditorHelpButton = function EuiMarkdownEditorHelpButton(_r
|
|
|
109
110
|
})))));
|
|
110
111
|
} else {
|
|
111
112
|
return ___EmotionJSX(EuiPopover, {
|
|
112
|
-
button: ___EmotionJSX(
|
|
113
|
-
|
|
113
|
+
button: ___EmotionJSX(EuiToolTip, {
|
|
114
|
+
content: syntaxTitle,
|
|
115
|
+
disableScreenReaderOutput: true
|
|
116
|
+
}, ___EmotionJSX(EuiButtonIcon, {
|
|
114
117
|
size: "s",
|
|
115
118
|
css: styles.euiMarkdownEditorFooter__helpButton,
|
|
116
119
|
className: "euiMarkdownEditorFooter__helpButton",
|
|
@@ -120,7 +123,7 @@ export var EuiMarkdownEditorHelpButton = function EuiMarkdownEditorHelpButton(_r
|
|
|
120
123
|
onClick: function onClick() {
|
|
121
124
|
return setIsShowingHelpPopover(!isShowingHelpPopover);
|
|
122
125
|
}
|
|
123
|
-
}),
|
|
126
|
+
})),
|
|
124
127
|
isOpen: isShowingHelpPopover,
|
|
125
128
|
closePopover: function closePopover() {
|
|
126
129
|
return setIsShowingHelpPopover(false);
|
|
@@ -13,6 +13,7 @@ import { EuiButtonIcon } from '../button/button_icon';
|
|
|
13
13
|
import { keysOf } from '../common';
|
|
14
14
|
import { useEuiI18n } from '../i18n';
|
|
15
15
|
import { useEuiTheme } from '../../services';
|
|
16
|
+
import { EuiToolTip } from '../tool_tip';
|
|
16
17
|
import { euiPaginationButtonStyles } from './pagination_button.styles';
|
|
17
18
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
18
19
|
var typeToIconTypeMap = {
|
|
@@ -41,15 +42,18 @@ export var EuiPaginationButtonArrow = function EuiPaginationButtonArrow(_ref) {
|
|
|
41
42
|
buttonProps.href = "#".concat(ariaControls);
|
|
42
43
|
buttonProps['aria-controls'] = ariaControls;
|
|
43
44
|
}
|
|
44
|
-
|
|
45
|
+
var button = ___EmotionJSX(EuiButtonIcon, _extends({
|
|
45
46
|
css: styles.euiPaginationButton,
|
|
46
47
|
className: classNames('euiPaginationArrowButton', className),
|
|
47
48
|
color: "text",
|
|
48
49
|
"aria-label": labels[type],
|
|
49
|
-
title: disabled ? undefined : labels[type],
|
|
50
50
|
isDisabled: disabled,
|
|
51
51
|
onClick: onClick,
|
|
52
52
|
"data-test-subj": "pagination-button-".concat(type),
|
|
53
53
|
iconType: typeToIconTypeMap[type]
|
|
54
54
|
}, buttonProps));
|
|
55
|
+
return disabled ? button : ___EmotionJSX(EuiToolTip, {
|
|
56
|
+
content: labels[type],
|
|
57
|
+
disableScreenReaderOutput: true
|
|
58
|
+
}, button);
|
|
55
59
|
};
|
|
@@ -31,11 +31,11 @@ var _ref = process.env.NODE_ENV === "production" ? {
|
|
|
31
31
|
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
32
32
|
};
|
|
33
33
|
var _ref2 = process.env.NODE_ENV === "production" ? {
|
|
34
|
-
name: "
|
|
35
|
-
styles: "position:relative;flex-grow:0;label:euiPanel;"
|
|
34
|
+
name: "z103qm-euiPanel",
|
|
35
|
+
styles: "position:relative;flex-grow:0;line-height:inherit;label:euiPanel;"
|
|
36
36
|
} : {
|
|
37
|
-
name: "
|
|
38
|
-
styles: "position:relative;flex-grow:0;label:euiPanel;",
|
|
37
|
+
name: "z103qm-euiPanel",
|
|
38
|
+
styles: "position:relative;flex-grow:0;line-height:inherit;label:euiPanel;",
|
|
39
39
|
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
40
40
|
};
|
|
41
41
|
export var euiPanelStyles = function euiPanelStyles(euiThemeContext) {
|
|
@@ -11,7 +11,7 @@ import { css } from '@emotion/react';
|
|
|
11
11
|
import { logicalCSS } from '../../../global_styling';
|
|
12
12
|
import { highContrastModeStyles } from '../../../global_styling/functions/high_contrast';
|
|
13
13
|
export var euiSplitPanelOuterStyles = {
|
|
14
|
-
euiSplitPanelOuter: /*#__PURE__*/css("display:flex;", logicalCSS('min-width', 0), " overflow:hidden;;label:euiSplitPanelOuter;"),
|
|
14
|
+
euiSplitPanelOuter: /*#__PURE__*/css("display:flex;&:enabled{display:flex;}", logicalCSS('min-width', 0), " overflow:hidden;;label:euiSplitPanelOuter;"),
|
|
15
15
|
column: process.env.NODE_ENV === "production" ? {
|
|
16
16
|
name: "ll8kmq-column",
|
|
17
17
|
styles: "flex-direction:column;label:column;"
|
|
@@ -24,6 +24,7 @@ import React, { Component } from 'react';
|
|
|
24
24
|
import { RenderWithEuiTheme, htmlIdGenerator } from '../../services';
|
|
25
25
|
import { isString } from '../../services/predicate';
|
|
26
26
|
import { EuiFlexGroup, EuiFlexItem } from '../flex';
|
|
27
|
+
import { EuiToolTip } from '../tool_tip';
|
|
27
28
|
import { EuiSearchBox } from './search_box';
|
|
28
29
|
import { EuiSearchBarFilters } from './search_filters';
|
|
29
30
|
import { Query } from './query';
|
|
@@ -186,6 +187,21 @@ export var EuiSearchBar = /*#__PURE__*/function (_Component) {
|
|
|
186
187
|
var toolsLeftEl = this.renderTools(toolsLeft);
|
|
187
188
|
var toolsRightEl = this.renderTools(toolsRight);
|
|
188
189
|
var isHintVisible = (_hint$popoverProps$is = hint === null || hint === void 0 || (_hint$popoverProps = hint.popoverProps) === null || _hint$popoverProps === void 0 ? void 0 : _hint$popoverProps.isOpen) !== null && _hint$popoverProps$is !== void 0 ? _hint$popoverProps$is : isHintVisibleState;
|
|
190
|
+
var searchBox = ___EmotionJSX(EuiSearchBox, _extends({}, box, {
|
|
191
|
+
query: queryText,
|
|
192
|
+
onSearch: this.onSearch,
|
|
193
|
+
isInvalid: error != null,
|
|
194
|
+
"aria-describedby": isHintVisible ? "".concat(this.hintId) : undefined,
|
|
195
|
+
hint: hint ? _objectSpread({
|
|
196
|
+
isVisible: isHintVisible,
|
|
197
|
+
setIsVisible: function setIsVisible(isVisible) {
|
|
198
|
+
_this2.setState({
|
|
199
|
+
isHintVisible: isVisible
|
|
200
|
+
});
|
|
201
|
+
},
|
|
202
|
+
id: this.hintId
|
|
203
|
+
}, hint) : undefined
|
|
204
|
+
}));
|
|
189
205
|
return ___EmotionJSX(RenderWithEuiTheme, null, function (euiTheme) {
|
|
190
206
|
return ___EmotionJSX(EuiFlexGroup, {
|
|
191
207
|
gutterSize: "s",
|
|
@@ -195,22 +211,10 @@ export var EuiSearchBar = /*#__PURE__*/function (_Component) {
|
|
|
195
211
|
className: "euiSearchBar__searchHolder",
|
|
196
212
|
css: euiSearchBar__searchHolder(euiTheme),
|
|
197
213
|
grow: true
|
|
198
|
-
}, ___EmotionJSX(
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
title: error ? error.message : undefined,
|
|
203
|
-
"aria-describedby": isHintVisible ? "".concat(_this2.hintId) : undefined,
|
|
204
|
-
hint: hint ? _objectSpread({
|
|
205
|
-
isVisible: isHintVisible,
|
|
206
|
-
setIsVisible: function setIsVisible(isVisible) {
|
|
207
|
-
_this2.setState({
|
|
208
|
-
isHintVisible: isVisible
|
|
209
|
-
});
|
|
210
|
-
},
|
|
211
|
-
id: _this2.hintId
|
|
212
|
-
}, hint) : undefined
|
|
213
|
-
}))), filters && ___EmotionJSX(EuiFlexItem, {
|
|
214
|
+
}, ___EmotionJSX(EuiToolTip, {
|
|
215
|
+
content: error === null || error === void 0 ? void 0 : error.message,
|
|
216
|
+
display: "block"
|
|
217
|
+
}, searchBox)), filters && ___EmotionJSX(EuiFlexItem, {
|
|
214
218
|
className: "euiSearchBar__filtersHolder",
|
|
215
219
|
css: euiSearchBar__filtersHolder(euiTheme),
|
|
216
220
|
grow: false
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
-
var _excluded = ["query", "placeholder", "incremental", "hint"];
|
|
3
|
+
var _excluded = ["query", "placeholder", "incremental", "hint", "onFocus"];
|
|
4
4
|
/*
|
|
5
5
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
6
6
|
* or more contributor license agreements. Licensed under the Elastic License
|
|
@@ -19,6 +19,7 @@ export var EuiSearchBox = function EuiSearchBox(_ref) {
|
|
|
19
19
|
placeholder = _ref.placeholder,
|
|
20
20
|
incremental = _ref.incremental,
|
|
21
21
|
hint = _ref.hint,
|
|
22
|
+
_onFocus = _ref.onFocus,
|
|
22
23
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
23
24
|
var _inputRef = useRef(null);
|
|
24
25
|
useLayoutEffect(function () {
|
|
@@ -39,8 +40,9 @@ export var EuiSearchBox = function EuiSearchBox(_ref) {
|
|
|
39
40
|
incremental: incremental,
|
|
40
41
|
"aria-label": incremental ? ariaLabelIncremental : ariaLabelEnter,
|
|
41
42
|
placeholder: placeholder !== null && placeholder !== void 0 ? placeholder : defaultPlaceholder,
|
|
42
|
-
onFocus: function onFocus() {
|
|
43
|
+
onFocus: function onFocus(e) {
|
|
43
44
|
hint === null || hint === void 0 || hint.setIsVisible(true);
|
|
45
|
+
_onFocus === null || _onFocus === void 0 || _onFocus(e);
|
|
44
46
|
}
|
|
45
47
|
}, rest));
|
|
46
48
|
if (hint) {
|
|
@@ -187,7 +187,7 @@ export var EuiSelectableList = /*#__PURE__*/function (_Component) {
|
|
|
187
187
|
_this.onAddOrRemoveOption(option, event);
|
|
188
188
|
},
|
|
189
189
|
isFocused: isFocused,
|
|
190
|
-
title: searchableLabel || label,
|
|
190
|
+
title: !truncationProps && !option.toolTipContent ? searchableLabel || label : undefined,
|
|
191
191
|
checked: checked,
|
|
192
192
|
disabled: disabled,
|
|
193
193
|
prepend: prepend,
|
|
@@ -45,6 +45,6 @@ export var euiSelectableListGroupLabelStyles = function euiSelectableListGroupLa
|
|
|
45
45
|
return {
|
|
46
46
|
groupLabel: /*#__PURE__*/css(euiTitle(euiThemeContext, 'xxxs'), " position:relative;display:flex;align-items:center;gap:", itemVars.spacing.horizontal, ";", logicalCSS('padding-horizontal', itemVars.textPadding.horizontal), " ", logicalCSS('padding-vertical', spacingVertical), " &:not(:first-child){", logicalCSS('padding-top', mathWithUnits([spacingVertical], function (a) {
|
|
47
47
|
return a * 3;
|
|
48
|
-
})), " &::before{content:'';position:absolute;inset:0;inset-block-start:", spacingVertical, ";", logicalCSS('border-top', "".concat(euiTheme.border.width.thin, " solid ").concat(borderColor)), ";}};label:groupLabel;")
|
|
48
|
+
})), " &::before{content:'';position:absolute;z-index:-1;inset:0;inset-block-start:", spacingVertical, ";", logicalCSS('border-top', "".concat(euiTheme.border.width.thin, " solid ").concat(borderColor)), ";}};label:groupLabel;")
|
|
49
49
|
};
|
|
50
50
|
};
|