@elastic/eui 88.5.4 → 89.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (206) hide show
  1. package/dist/eui_theme_dark.css +26 -526
  2. package/dist/eui_theme_dark.min.css +1 -1
  3. package/dist/eui_theme_light.css +26 -526
  4. package/dist/eui_theme_light.min.css +1 -1
  5. package/es/components/basic_table/basic_table.js +7 -2
  6. package/es/components/basic_table/in_memory_table.js +7 -2
  7. package/es/components/collapsible_nav/collapsible_nav.js +5 -0
  8. package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +4 -2
  9. package/es/components/color_picker/index.js +0 -4
  10. package/es/components/combo_box/combo_box.js +142 -304
  11. package/es/components/combo_box/combo_box_input/combo_box_input.js +0 -13
  12. package/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +34 -118
  13. package/es/components/context_menu/context_menu_panel.js +6 -6
  14. package/es/components/flex/flex_grid.styles.js +1 -1
  15. package/es/components/flex/flex_group.styles.js +1 -1
  16. package/es/components/flyout/flyout.js +32 -33
  17. package/es/components/flyout/flyout.styles.js +13 -3
  18. package/es/components/form/range/dual_range.js +4 -0
  19. package/es/components/form/range/range.js +4 -0
  20. package/es/components/index.js +0 -1
  21. package/es/components/popover/input_popover.js +47 -3
  22. package/es/components/popover/popover.js +2 -2
  23. package/es/components/table/table_row_cell.js +27 -9
  24. package/es/components/text_truncate/index.js +1 -0
  25. package/es/components/text_truncate/text_block_truncate.js +78 -0
  26. package/es/global_styling/reset/global_styles.js +16 -2
  27. package/es/services/accessibility/index.js +0 -3
  28. package/es/services/index.js +1 -1
  29. package/es/test/rtl/component_helpers.d.ts +2 -0
  30. package/es/test/rtl/component_helpers.js +29 -1
  31. package/eui.d.ts +375 -667
  32. package/i18ntokens.json +52 -286
  33. package/lib/components/basic_table/basic_table.js +7 -2
  34. package/lib/components/basic_table/in_memory_table.js +7 -2
  35. package/lib/components/collapsible_nav/collapsible_nav.js +5 -0
  36. package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +4 -2
  37. package/lib/components/color_picker/index.js +0 -7
  38. package/lib/components/combo_box/combo_box.js +141 -303
  39. package/lib/components/combo_box/combo_box_input/combo_box_input.js +0 -13
  40. package/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +34 -118
  41. package/lib/components/context_menu/context_menu_panel.js +5 -5
  42. package/lib/components/flex/flex_grid.styles.js +1 -1
  43. package/lib/components/flex/flex_group.styles.js +1 -1
  44. package/lib/components/flyout/flyout.js +31 -32
  45. package/lib/components/flyout/flyout.styles.js +19 -10
  46. package/lib/components/form/range/dual_range.js +4 -0
  47. package/lib/components/index.js +0 -11
  48. package/lib/components/popover/input_popover.js +48 -3
  49. package/lib/components/popover/popover.js +1 -1
  50. package/lib/components/table/table_row_cell.js +26 -8
  51. package/lib/components/text_truncate/index.js +7 -0
  52. package/lib/components/text_truncate/text_block_truncate.js +85 -0
  53. package/lib/global_styling/reset/global_styles.js +16 -2
  54. package/lib/services/accessibility/index.js +0 -21
  55. package/lib/services/index.js +0 -21
  56. package/lib/test/rtl/component_helpers.d.ts +2 -0
  57. package/lib/test/rtl/component_helpers.js +31 -2
  58. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +4 -2
  59. package/optimize/es/components/color_picker/index.js +0 -4
  60. package/optimize/es/components/combo_box/combo_box.js +137 -304
  61. package/optimize/es/components/combo_box/combo_box_input/combo_box_input.js +0 -12
  62. package/optimize/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +28 -107
  63. package/optimize/es/components/context_menu/context_menu_panel.js +6 -6
  64. package/optimize/es/components/flex/flex_grid.styles.js +1 -1
  65. package/optimize/es/components/flex/flex_group.styles.js +1 -1
  66. package/optimize/es/components/flyout/flyout.js +32 -33
  67. package/optimize/es/components/flyout/flyout.styles.js +13 -3
  68. package/optimize/es/components/index.js +0 -1
  69. package/optimize/es/components/popover/input_popover.js +43 -3
  70. package/optimize/es/components/popover/popover.js +2 -2
  71. package/optimize/es/components/table/table_row_cell.js +13 -5
  72. package/optimize/es/components/text_truncate/index.js +1 -0
  73. package/optimize/es/components/text_truncate/text_block_truncate.js +58 -0
  74. package/optimize/es/global_styling/reset/global_styles.js +13 -2
  75. package/optimize/es/services/accessibility/index.js +0 -3
  76. package/optimize/es/services/index.js +1 -1
  77. package/optimize/es/test/rtl/component_helpers.d.ts +2 -0
  78. package/optimize/es/test/rtl/component_helpers.js +29 -1
  79. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +4 -2
  80. package/optimize/lib/components/color_picker/index.js +0 -7
  81. package/optimize/lib/components/combo_box/combo_box.js +136 -303
  82. package/optimize/lib/components/combo_box/combo_box_input/combo_box_input.js +0 -12
  83. package/optimize/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +28 -107
  84. package/optimize/lib/components/context_menu/context_menu_panel.js +5 -5
  85. package/optimize/lib/components/flex/flex_grid.styles.js +1 -1
  86. package/optimize/lib/components/flex/flex_group.styles.js +1 -1
  87. package/optimize/lib/components/flyout/flyout.js +31 -32
  88. package/optimize/lib/components/flyout/flyout.styles.js +19 -10
  89. package/optimize/lib/components/index.js +0 -11
  90. package/optimize/lib/components/popover/input_popover.js +44 -3
  91. package/optimize/lib/components/popover/popover.js +1 -1
  92. package/optimize/lib/components/table/table_row_cell.js +12 -4
  93. package/optimize/lib/components/text_truncate/index.js +7 -0
  94. package/optimize/lib/components/text_truncate/text_block_truncate.js +66 -0
  95. package/optimize/lib/global_styling/reset/global_styles.js +19 -10
  96. package/optimize/lib/services/accessibility/index.js +0 -21
  97. package/optimize/lib/services/index.js +0 -21
  98. package/optimize/lib/test/rtl/component_helpers.d.ts +2 -0
  99. package/optimize/lib/test/rtl/component_helpers.js +31 -2
  100. package/package.json +1 -1
  101. package/src/components/combo_box/combo_box_options_list/_combo_box_options_list.scss +5 -15
  102. package/src/components/context_menu/_context_menu_panel.scss +4 -0
  103. package/src/components/index.scss +0 -1
  104. package/src/global_styling/mixins/_index.scss +0 -1
  105. package/src/global_styling/variables/_index.scss +0 -1
  106. package/src/test/README.md +0 -15
  107. package/src/themes/amsterdam/global_styling/mixins/_index.scss +0 -1
  108. package/test-env/components/basic_table/basic_table.js +7 -2
  109. package/test-env/components/basic_table/in_memory_table.js +7 -2
  110. package/test-env/components/collapsible_nav/collapsible_nav.js +5 -0
  111. package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +4 -2
  112. package/test-env/components/color_picker/index.js +0 -7
  113. package/test-env/components/combo_box/combo_box.js +141 -303
  114. package/test-env/components/combo_box/combo_box_input/combo_box_input.js +0 -13
  115. package/test-env/components/combo_box/combo_box_options_list/combo_box_options_list.js +33 -117
  116. package/test-env/components/context_menu/context_menu_panel.js +5 -5
  117. package/test-env/components/flex/flex_grid.styles.js +1 -1
  118. package/test-env/components/flex/flex_group.styles.js +1 -1
  119. package/test-env/components/flyout/flyout.styles.js +19 -10
  120. package/test-env/components/form/range/dual_range.js +4 -0
  121. package/test-env/components/index.js +0 -11
  122. package/test-env/components/popover/input_popover.js +48 -3
  123. package/test-env/components/popover/popover.js +1 -1
  124. package/test-env/components/table/table_row_cell.js +26 -8
  125. package/test-env/components/text_truncate/index.js +7 -0
  126. package/test-env/components/text_truncate/text_block_truncate.js +82 -0
  127. package/test-env/global_styling/reset/global_styles.js +19 -10
  128. package/test-env/services/accessibility/index.js +0 -21
  129. package/test-env/services/index.js +0 -21
  130. package/test-env/test/rtl/component_helpers.js +31 -2
  131. package/es/components/color_picker/color_stops/color_stop_thumb.js +0 -371
  132. package/es/components/color_picker/color_stops/color_stop_thumb.styles.js +0 -55
  133. package/es/components/color_picker/color_stops/color_stops.js +0 -499
  134. package/es/components/color_picker/color_stops/color_stops.styles.js +0 -61
  135. package/es/components/color_picker/color_stops/index.js +0 -9
  136. package/es/components/color_picker/color_stops/utils.js +0 -95
  137. package/es/components/suggest/index.js +0 -10
  138. package/es/components/suggest/suggest.a11y.js +0 -70
  139. package/es/components/suggest/suggest.js +0 -347
  140. package/es/components/suggest/suggest_item.js +0 -123
  141. package/es/components/suggest/types.js +0 -9
  142. package/es/services/accessibility/accessible_click_keys.js +0 -17
  143. package/es/services/accessibility/cascading_menu_keys.js +0 -28
  144. package/es/services/accessibility/combo_box_keys.js +0 -25
  145. package/lib/components/color_picker/color_stops/color_stop_thumb.js +0 -380
  146. package/lib/components/color_picker/color_stops/color_stop_thumb.styles.js +0 -62
  147. package/lib/components/color_picker/color_stops/color_stops.js +0 -505
  148. package/lib/components/color_picker/color_stops/color_stops.styles.js +0 -67
  149. package/lib/components/color_picker/color_stops/index.js +0 -12
  150. package/lib/components/color_picker/color_stops/utils.js +0 -108
  151. package/lib/components/suggest/index.js +0 -19
  152. package/lib/components/suggest/suggest.a11y.js +0 -73
  153. package/lib/components/suggest/suggest.js +0 -356
  154. package/lib/components/suggest/suggest_item.js +0 -130
  155. package/lib/components/suggest/types.js +0 -16
  156. package/lib/services/accessibility/accessible_click_keys.js +0 -21
  157. package/lib/services/accessibility/cascading_menu_keys.js +0 -35
  158. package/lib/services/accessibility/combo_box_keys.js +0 -32
  159. package/optimize/es/components/color_picker/color_stops/color_stop_thumb.js +0 -329
  160. package/optimize/es/components/color_picker/color_stops/color_stop_thumb.styles.js +0 -55
  161. package/optimize/es/components/color_picker/color_stops/color_stops.js +0 -444
  162. package/optimize/es/components/color_picker/color_stops/color_stops.styles.js +0 -61
  163. package/optimize/es/components/color_picker/color_stops/index.js +0 -9
  164. package/optimize/es/components/color_picker/color_stops/utils.js +0 -90
  165. package/optimize/es/components/suggest/index.js +0 -10
  166. package/optimize/es/components/suggest/suggest.a11y.js +0 -70
  167. package/optimize/es/components/suggest/suggest.js +0 -256
  168. package/optimize/es/components/suggest/suggest_item.js +0 -89
  169. package/optimize/es/components/suggest/types.js +0 -9
  170. package/optimize/es/services/accessibility/accessible_click_keys.js +0 -14
  171. package/optimize/es/services/accessibility/cascading_menu_keys.js +0 -28
  172. package/optimize/es/services/accessibility/combo_box_keys.js +0 -25
  173. package/optimize/lib/components/color_picker/color_stops/color_stop_thumb.js +0 -339
  174. package/optimize/lib/components/color_picker/color_stops/color_stop_thumb.styles.js +0 -62
  175. package/optimize/lib/components/color_picker/color_stops/color_stops.js +0 -451
  176. package/optimize/lib/components/color_picker/color_stops/color_stops.styles.js +0 -67
  177. package/optimize/lib/components/color_picker/color_stops/index.js +0 -12
  178. package/optimize/lib/components/color_picker/color_stops/utils.js +0 -106
  179. package/optimize/lib/components/suggest/index.js +0 -19
  180. package/optimize/lib/components/suggest/suggest.a11y.js +0 -73
  181. package/optimize/lib/components/suggest/suggest.js +0 -266
  182. package/optimize/lib/components/suggest/suggest_item.js +0 -96
  183. package/optimize/lib/components/suggest/types.js +0 -16
  184. package/optimize/lib/services/accessibility/accessible_click_keys.js +0 -20
  185. package/optimize/lib/services/accessibility/cascading_menu_keys.js +0 -35
  186. package/optimize/lib/services/accessibility/combo_box_keys.js +0 -32
  187. package/src/components/suggest/_index.scss +0 -5
  188. package/src/components/suggest/_suggest_input.scss +0 -4
  189. package/src/components/suggest/_suggest_item.scss +0 -103
  190. package/src/components/suggest/_variables.scss +0 -13
  191. package/src/global_styling/mixins/_header.scss +0 -29
  192. package/src/global_styling/variables/_header.scss +0 -3
  193. package/test-env/components/color_picker/color_stops/color_stop_thumb.js +0 -372
  194. package/test-env/components/color_picker/color_stops/color_stop_thumb.styles.js +0 -62
  195. package/test-env/components/color_picker/color_stops/color_stops.js +0 -494
  196. package/test-env/components/color_picker/color_stops/color_stops.styles.js +0 -67
  197. package/test-env/components/color_picker/color_stops/index.js +0 -12
  198. package/test-env/components/color_picker/color_stops/utils.js +0 -106
  199. package/test-env/components/suggest/index.js +0 -19
  200. package/test-env/components/suggest/suggest.a11y.js +0 -73
  201. package/test-env/components/suggest/suggest.js +0 -348
  202. package/test-env/components/suggest/suggest_item.js +0 -129
  203. package/test-env/components/suggest/types.js +0 -16
  204. package/test-env/services/accessibility/accessible_click_keys.js +0 -20
  205. package/test-env/services/accessibility/cascading_menu_keys.js +0 -35
  206. package/test-env/services/accessibility/combo_box_keys.js +0 -32
@@ -18,14 +18,13 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
18
18
  var _react = _interopRequireWildcard(require("react"));
19
19
  var _classnames = _interopRequireDefault(require("classnames"));
20
20
  var _services = require("../../services");
21
- var _popover = require("../../services/popover");
22
- var _portal = require("../portal");
21
+ var _popover = require("../popover");
23
22
  var _i18n = require("../i18n");
24
23
  var _matching_options = require("./matching_options");
25
24
  var _combo_box_input = require("./combo_box_input/combo_box_input");
26
25
  var _combo_box_options_list = require("./combo_box_options_list");
27
26
  var _react2 = require("@emotion/react");
28
- var _excluded = ["data-test-subj", "async", "className", "compressed", "customOptionText", "fullWidth", "id", "inputRef", "isCaseSensitive", "isClearable", "isDisabled", "isInvalid", "isLoading", "noSuggestions", "onBlur", "onChange", "onCreateOption", "onSearchChange", "options", "placeholder", "renderOption", "rowHeight", "selectedOptions", "singleSelection", "prepend", "sortMatchesBy", "delimiter", "append", "autoFocus", "truncationProps", "aria-label", "aria-labelledby"];
27
+ var _excluded = ["data-test-subj", "async", "className", "compressed", "customOptionText", "fullWidth", "id", "inputRef", "isCaseSensitive", "isClearable", "isDisabled", "isInvalid", "isLoading", "noSuggestions", "onBlur", "onChange", "onCreateOption", "onSearchChange", "options", "placeholder", "renderOption", "rowHeight", "selectedOptions", "singleSelection", "prepend", "sortMatchesBy", "delimiter", "append", "autoFocus", "truncationProps", "inputPopoverProps", "aria-label", "aria-labelledby"];
29
28
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
30
29
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
31
30
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
@@ -63,9 +62,6 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
63
62
  activeOptionIndex: -1,
64
63
  hasFocus: false,
65
64
  isListOpen: false,
66
- listElement: null,
67
- listPosition: 'bottom',
68
- listZIndex: undefined,
69
65
  matchingOptions: (0, _matching_options.getMatchingOptions)({
70
66
  options: _this.props.options,
71
67
  selectedOptions: _this.props.selectedOptions,
@@ -75,118 +71,43 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
75
71
  showPrevSelected: Boolean(_this.props.singleSelection),
76
72
  sortMatchesBy: _this.props.sortMatchesBy
77
73
  }),
78
- searchValue: initialSearchValue,
79
- width: 0
74
+ searchValue: initialSearchValue
80
75
  });
81
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "_isMounted", false);
82
76
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "rootId", (0, _services.htmlIdGenerator)());
83
77
  // Refs
84
78
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "comboBoxRefInstance", null);
85
79
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "comboBoxRefCallback", function (ref) {
86
80
  _this.comboBoxRefInstance = ref;
87
- if (_this.comboBoxRefInstance) {
88
- var comboBoxBounds = _this.comboBoxRefInstance.getBoundingClientRect();
89
- _this.setState({
90
- width: comboBoxBounds.width
91
- });
92
- }
93
81
  });
94
82
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "searchInputRefInstance", null);
95
83
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "searchInputRefCallback", function (ref) {
84
+ var _this$props$inputRef, _this$props;
96
85
  _this.searchInputRefInstance = ref;
97
- if (_this.props.inputRef) _this.props.inputRef(ref);
86
+ (_this$props$inputRef = (_this$props = _this.props).inputRef) === null || _this$props$inputRef === void 0 ? void 0 : _this$props$inputRef.call(_this$props, ref);
98
87
  });
99
88
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "listRefInstance", null);
100
89
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "listRefCallback", function (ref) {
101
- if (_this.comboBoxRefInstance) {
102
- // find the zIndex of the combobox relative to the page body
103
- // and use that to depth-position the list box
104
- // adds an extra `100` to provide some defense around neighboring elements' positioning
105
- var listZIndex = (0, _popover.getElementZIndex)(_this.comboBoxRefInstance, document.body) + 100;
106
- _this.setState({
107
- listZIndex: listZIndex
108
- });
109
- }
110
90
  _this.listRefInstance = ref;
111
91
  });
112
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "toggleButtonRefInstance", null);
113
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "toggleButtonRefCallback", function (ref) {
114
- _this.toggleButtonRefInstance = ref;
115
- });
116
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "optionsRefInstances", []);
117
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "optionRefCallback", function (index, ref) {
118
- _this.optionsRefInstances[index] = ref;
119
- });
120
92
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "openList", function () {
121
93
  _this.setState({
122
94
  isListOpen: true
123
95
  });
124
96
  });
125
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "closeList", function (event) {
126
- if (event && event.target === _this.searchInputRefInstance) {
127
- // really long search values / custom entries triggers a scroll event on the input
128
- // which the EuiComboBoxOptionsList passes through here
129
- return;
130
- }
97
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "closeList", function () {
131
98
  _this.clearActiveOption();
132
99
  _this.setState({
133
- listZIndex: undefined,
134
100
  isListOpen: false
135
101
  });
136
102
  });
137
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "updatePosition", function () {
138
- var listElement = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _this.state.listElement;
139
- if (!_this._isMounted) {
140
- return;
141
- }
142
- if (!_this.state.isListOpen) {
143
- return;
144
- }
145
- if (!listElement) {
146
- return;
147
- }
148
-
149
- // it's possible that updateListPosition is called when listElement is becoming visible, but isn't yet
150
- var listElementBounds = listElement.getBoundingClientRect();
151
- if (listElementBounds.width === 0 || listElementBounds.height === 0) {
152
- return;
153
- }
154
- if (!_this.comboBoxRefInstance) {
155
- return;
156
- }
157
- var comboBoxBounds = _this.comboBoxRefInstance.getBoundingClientRect();
158
- var _ref = (0, _services.findPopoverPosition)({
159
- allowCrossAxis: false,
160
- anchor: _this.comboBoxRefInstance,
161
- popover: listElement,
162
- position: 'bottom'
163
- }),
164
- position = _ref.position,
165
- top = _ref.top;
166
- if (_this.listRefInstance) {
167
- _this.listRefInstance.style.top = "".concat(top, "px");
168
- // listElement doesn't have its width set until after updating the position
169
- // which means the popover service won't know about the correct width
170
- // however, we already know where to position the element
171
- _this.listRefInstance.style.left = "".concat(comboBoxBounds.left + window.pageXOffset, "px");
172
- _this.listRefInstance.style.width = "".concat(comboBoxBounds.width, "px");
173
- }
174
-
175
- // Cache for future calls.
176
- _this.setState({
177
- listElement: listElement,
178
- listPosition: position,
179
- width: comboBoxBounds.width
180
- });
181
- });
182
103
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "incrementActiveOptionIndex", function (amount) {
183
104
  // If there are no options available, do nothing.
184
105
  if (!_this.state.matchingOptions.length) {
185
106
  return;
186
107
  }
187
- _this.setState(function (_ref2) {
188
- var activeOptionIndex = _ref2.activeOptionIndex,
189
- matchingOptions = _ref2.matchingOptions;
108
+ _this.setState(function (_ref) {
109
+ var activeOptionIndex = _ref.activeOptionIndex,
110
+ matchingOptions = _ref.matchingOptions;
190
111
  var nextActiveOptionIndex;
191
112
  if (activeOptionIndex < 0) {
192
113
  // If this is the beginning of the user's keyboard navigation of the menu, then we'll focus
@@ -229,12 +150,12 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
229
150
  _this.onSearchChange('');
230
151
  });
231
152
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "addCustomOption", function (isContainerBlur, searchValue) {
232
- var _this$props = _this.props,
233
- isCaseSensitive = _this$props.isCaseSensitive,
234
- onCreateOption = _this$props.onCreateOption,
235
- options = _this$props.options,
236
- selectedOptions = _this$props.selectedOptions,
237
- singleSelection = _this$props.singleSelection;
153
+ var _this$props2 = _this.props,
154
+ isCaseSensitive = _this$props2.isCaseSensitive,
155
+ onCreateOption = _this$props2.onCreateOption,
156
+ options = _this$props2.options,
157
+ selectedOptions = _this$props2.selectedOptions,
158
+ singleSelection = _this$props2.singleSelection;
238
159
  var matchingOptions = _this.state.matchingOptions;
239
160
  if (_this.doesSearchMatchOnlyOption()) {
240
161
  _this.onAddOption(matchingOptions[0], isContainerBlur);
@@ -281,11 +202,11 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
281
202
  return normalizedSearchSubject === normalizedSearchValue;
282
203
  });
283
204
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "areAllOptionsSelected", function () {
284
- var _this$props2 = _this.props,
285
- options = _this$props2.options,
286
- selectedOptions = _this$props2.selectedOptions,
287
- async = _this$props2.async,
288
- isCaseSensitive = _this$props2.isCaseSensitive;
205
+ var _this$props3 = _this.props,
206
+ options = _this$props3.options,
207
+ selectedOptions = _this$props3.selectedOptions,
208
+ async = _this$props3.async,
209
+ isCaseSensitive = _this$props3.isCaseSensitive;
289
210
  // Assume if this is async then there could be infinite options.
290
211
  if (async) {
291
212
  return false;
@@ -296,8 +217,8 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
296
217
  });
297
218
  });
298
219
  var numberOfSelectedOptions = 0;
299
- selectedOptions.forEach(function (_ref3) {
300
- var label = _ref3.label;
220
+ selectedOptions.forEach(function (_ref2) {
221
+ var label = _ref2.label;
301
222
  var trimmedLabel = (0, _matching_options.transformForCaseSensitivity)(label.trim(), isCaseSensitive);
302
223
  if (flattenOptions.findIndex(function (option) {
303
224
  return option.label === trimmedLabel;
@@ -306,9 +227,8 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
306
227
  return flattenOptions.length === numberOfSelectedOptions;
307
228
  });
308
229
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onComboBoxFocus", function (event) {
309
- if (_this.props.onFocus) {
310
- _this.props.onFocus(event);
311
- }
230
+ var _this$props$onFocus, _this$props4;
231
+ (_this$props$onFocus = (_this$props4 = _this.props).onFocus) === null || _this$props$onFocus === void 0 ? void 0 : _this$props$onFocus.call(_this$props4, event);
312
232
  _this.openList();
313
233
  _this.setState({
314
234
  hasFocus: true
@@ -331,10 +251,9 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
331
251
  var focusedInOptionsList = relatedTarget && _this.listRefInstance && _this.listRefInstance.contains(relatedTarget);
332
252
  var focusedInInput = relatedTarget && _this.comboBoxRefInstance && _this.comboBoxRefInstance.contains(relatedTarget);
333
253
  if (!focusedInOptionsList && !focusedInInput) {
254
+ var _this$props$onBlur, _this$props5;
255
+ (_this$props$onBlur = (_this$props5 = _this.props).onBlur) === null || _this$props$onBlur === void 0 ? void 0 : _this$props$onBlur.call(_this$props5, event);
334
256
  _this.closeList();
335
- if (_this.props.onBlur) {
336
- _this.props.onBlur(event);
337
- }
338
257
  _this.setState({
339
258
  hasFocus: false
340
259
  });
@@ -357,7 +276,9 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
357
276
  }
358
277
  });
359
278
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onKeyDown", function (event) {
279
+ var _this$props$onKeyDown, _this$props6;
360
280
  if (_this.props.isDisabled) return;
281
+ event.persist(); // TODO: Remove once React 16 support is dropped
361
282
  switch (event.key) {
362
283
  case _services.keys.ARROW_UP:
363
284
  event.preventDefault();
@@ -401,9 +322,7 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
401
322
  }
402
323
  break;
403
324
  default:
404
- if (_this.props.onKeyDown) {
405
- _this.props.onKeyDown(event);
406
- }
325
+ (_this$props$onKeyDown = (_this$props6 = _this.props).onKeyDown) === null || _this$props$onKeyDown === void 0 ? void 0 : _this$props$onKeyDown.call(_this$props6, event);
407
326
  }
408
327
  });
409
328
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onOptionEnterKey", function (option) {
@@ -416,21 +335,18 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
416
335
  if (addedOption.disabled) {
417
336
  return;
418
337
  }
419
- var _this$props3 = _this.props,
420
- onChange = _this$props3.onChange,
421
- selectedOptions = _this$props3.selectedOptions,
422
- singleSelectionProp = _this$props3.singleSelection;
338
+ var _this$props7 = _this.props,
339
+ onChange = _this$props7.onChange,
340
+ selectedOptions = _this$props7.selectedOptions,
341
+ singleSelectionProp = _this$props7.singleSelection;
423
342
  var singleSelection = Boolean(singleSelectionProp);
424
343
  var changeOptions = singleSelection ? [addedOption] : selectedOptions.concat(addedOption);
425
- if (onChange) {
426
- onChange(changeOptions);
427
- }
344
+ onChange === null || onChange === void 0 ? void 0 : onChange(changeOptions);
428
345
  _this.clearSearchValue();
429
346
  _this.clearActiveOption();
430
347
  if (!isContainerBlur) {
431
- if (_this.searchInputRefInstance) {
432
- _this.searchInputRefInstance.focus();
433
- }
348
+ var _this$searchInputRefI2;
349
+ (_this$searchInputRefI2 = _this.searchInputRefInstance) === null || _this$searchInputRefI2 === void 0 ? void 0 : _this$searchInputRefI2.focus();
434
350
  }
435
351
  if (singleSelection) {
436
352
  requestAnimationFrame(function () {
@@ -443,36 +359,29 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
443
359
  }
444
360
  });
445
361
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onRemoveOption", function (removedOption) {
446
- var _this$props4 = _this.props,
447
- onChange = _this$props4.onChange,
448
- selectedOptions = _this$props4.selectedOptions;
449
- if (onChange) {
450
- onChange(selectedOptions.filter(function (option) {
451
- return option !== removedOption;
452
- }));
453
- }
362
+ var _this$props8 = _this.props,
363
+ onChange = _this$props8.onChange,
364
+ selectedOptions = _this$props8.selectedOptions;
365
+ onChange === null || onChange === void 0 ? void 0 : onChange(selectedOptions.filter(function (option) {
366
+ return option !== removedOption;
367
+ }));
454
368
  _this.clearActiveOption();
455
369
  });
456
370
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "clearSelectedOptions", function () {
457
- var onChange = _this.props.onChange;
458
- if (onChange) {
459
- onChange([]);
460
- }
371
+ var _this$props$onChange, _this$props9, _this$searchInputRefI3;
372
+ (_this$props$onChange = (_this$props9 = _this.props).onChange) === null || _this$props$onChange === void 0 ? void 0 : _this$props$onChange.call(_this$props9, []);
461
373
 
462
374
  // Clicking the clear button will also cause it to disappear. This would result in focus
463
375
  // shifting unexpectedly to the body element so we set it to the input which is more reasonable,
464
- if (_this.searchInputRefInstance) {
465
- _this.searchInputRefInstance.focus();
466
- }
376
+ (_this$searchInputRefI3 = _this.searchInputRefInstance) === null || _this$searchInputRefI3 === void 0 ? void 0 : _this$searchInputRefI3.focus();
467
377
  if (!_this.state.isListOpen) {
468
378
  _this.openList();
469
379
  }
470
380
  });
471
381
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onComboBoxClick", function () {
382
+ var _this$searchInputRefI4;
472
383
  // When the user clicks anywhere on the box, enter the interaction state.
473
- if (_this.searchInputRefInstance) {
474
- _this.searchInputRefInstance.focus();
475
- }
384
+ (_this$searchInputRefI4 = _this.searchInputRefInstance) === null || _this$searchInputRefI4 === void 0 ? void 0 : _this$searchInputRefI4.focus();
476
385
 
477
386
  // If the user does this from a state in which an option has focus, then we need to reset it or clear it.
478
387
  if (Boolean(_this.props.singleSelection) && _this.props.selectedOptions.length === 1) {
@@ -487,25 +396,20 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
487
396
  }
488
397
  });
489
398
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onOpenListClick", function () {
490
- if (_this.searchInputRefInstance) {
491
- _this.searchInputRefInstance.focus();
492
- }
399
+ var _this$searchInputRefI5;
400
+ (_this$searchInputRefI5 = _this.searchInputRefInstance) === null || _this$searchInputRefI5 === void 0 ? void 0 : _this$searchInputRefI5.focus();
493
401
  if (!_this.state.isListOpen) {
494
402
  _this.openList();
495
403
  }
496
404
  });
497
405
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onOptionListScroll", function () {
498
- if (_this.searchInputRefInstance) {
499
- _this.searchInputRefInstance.focus();
500
- }
501
- });
502
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onCloseListClick", function () {
503
- _this.closeList();
406
+ var _this$searchInputRefI6;
407
+ (_this$searchInputRefI6 = _this.searchInputRefInstance) === null || _this$searchInputRefI6 === void 0 ? void 0 : _this$searchInputRefI6.focus();
504
408
  });
505
409
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onSearchChange", function (searchValue) {
506
- var _this$props5 = _this.props,
507
- onSearchChange = _this$props5.onSearchChange,
508
- delimiter = _this$props5.delimiter;
410
+ var _this$props10 = _this.props,
411
+ onSearchChange = _this$props10.onSearchChange,
412
+ delimiter = _this$props10.delimiter;
509
413
  if (onSearchChange) {
510
414
  var _hasMatchingOptions = _this.state.matchingOptions.length > 0;
511
415
  onSearchChange(searchValue, _hasMatchingOptions);
@@ -519,126 +423,53 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
519
423
  _this.setCustomOptions(false);
520
424
  }
521
425
  });
522
- (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "updateMatchingOptionsIfDifferent", function (newMatchingOptions) {
523
- var _this$state = _this.state,
524
- matchingOptions = _this$state.matchingOptions,
525
- activeOptionIndex = _this$state.activeOptionIndex;
526
- var _this$props6 = _this.props,
527
- singleSelection = _this$props6.singleSelection,
528
- selectedOptions = _this$props6.selectedOptions;
529
- var areOptionsDifferent = false;
530
- if (matchingOptions.length !== newMatchingOptions.length) {
531
- areOptionsDifferent = true;
532
- } else {
533
- for (var i = 0; i < matchingOptions.length; i++) {
534
- if (matchingOptions[i].label !== newMatchingOptions[i].label) {
535
- areOptionsDifferent = true;
536
- break;
537
- }
538
- }
539
- }
540
- if (areOptionsDifferent) {
541
- _this.optionsRefInstances = [];
542
- var nextActiveOptionIndex = activeOptionIndex;
543
- // ensure that the currently selected single option is active if it is in the matchingOptions
544
- if (Boolean(singleSelection) && selectedOptions.length === 1) {
545
- if (newMatchingOptions.includes(selectedOptions[0])) {
546
- nextActiveOptionIndex = newMatchingOptions.indexOf(selectedOptions[0]);
547
- }
548
- }
549
- _this.setState({
550
- matchingOptions: newMatchingOptions,
551
- activeOptionIndex: nextActiveOptionIndex
552
- });
553
- if (!newMatchingOptions.length) {
554
- // Prevent endless setState -> componentWillUpdate -> setState loop.
555
- if (_this.hasActiveOption()) {
556
- _this.clearActiveOption();
557
- }
558
- }
559
- }
560
- });
561
426
  return _this;
562
427
  }
563
428
  (0, _createClass2.default)(EuiComboBox, [{
564
- key: "componentDidMount",
565
- value: function componentDidMount() {
566
- this._isMounted = true;
567
- }
568
- }, {
569
- key: "componentDidUpdate",
570
- value: function componentDidUpdate() {
571
- var _this$props7 = this.props,
572
- options = _this$props7.options,
573
- selectedOptions = _this$props7.selectedOptions,
574
- singleSelection = _this$props7.singleSelection,
575
- sortMatchesBy = _this$props7.sortMatchesBy;
576
- var searchValue = this.state.searchValue;
577
-
578
- // React 16.3 has a bug (fixed in 16.4) where getDerivedStateFromProps
579
- // isn't called after a state change, and we track `searchValue` in state
580
- // instead we need to react to a change in searchValue here
581
- this.updateMatchingOptionsIfDifferent((0, _matching_options.getMatchingOptions)({
582
- options: options,
583
- selectedOptions: selectedOptions,
584
- searchValue: searchValue,
585
- isCaseSensitive: this.props.isCaseSensitive,
586
- isPreFiltered: this.props.async,
587
- showPrevSelected: Boolean(singleSelection),
588
- sortMatchesBy: sortMatchesBy
589
- }));
590
- }
591
- }, {
592
- key: "componentWillUnmount",
593
- value: function componentWillUnmount() {
594
- this._isMounted = false;
595
- }
596
- }, {
597
429
  key: "render",
598
430
  value: function render() {
599
431
  var _this2 = this;
600
- var _this$props8 = this.props,
601
- dataTestSubj = _this$props8['data-test-subj'],
602
- async = _this$props8.async,
603
- className = _this$props8.className,
604
- compressed = _this$props8.compressed,
605
- customOptionText = _this$props8.customOptionText,
606
- fullWidth = _this$props8.fullWidth,
607
- id = _this$props8.id,
608
- inputRef = _this$props8.inputRef,
609
- isCaseSensitive = _this$props8.isCaseSensitive,
610
- isClearable = _this$props8.isClearable,
611
- isDisabled = _this$props8.isDisabled,
612
- isInvalid = _this$props8.isInvalid,
613
- isLoading = _this$props8.isLoading,
614
- noSuggestions = _this$props8.noSuggestions,
615
- onBlur = _this$props8.onBlur,
616
- onChange = _this$props8.onChange,
617
- onCreateOption = _this$props8.onCreateOption,
618
- onSearchChange = _this$props8.onSearchChange,
619
- options = _this$props8.options,
620
- placeholder = _this$props8.placeholder,
621
- renderOption = _this$props8.renderOption,
622
- rowHeight = _this$props8.rowHeight,
623
- selectedOptions = _this$props8.selectedOptions,
624
- singleSelection = _this$props8.singleSelection,
625
- prepend = _this$props8.prepend,
626
- sortMatchesBy = _this$props8.sortMatchesBy,
627
- delimiter = _this$props8.delimiter,
628
- append = _this$props8.append,
629
- autoFocus = _this$props8.autoFocus,
630
- truncationProps = _this$props8.truncationProps,
631
- ariaLabel = _this$props8['aria-label'],
632
- ariaLabelledby = _this$props8['aria-labelledby'],
633
- rest = (0, _objectWithoutProperties2.default)(_this$props8, _excluded);
634
- var _this$state2 = this.state,
635
- activeOptionIndex = _this$state2.activeOptionIndex,
636
- hasFocus = _this$state2.hasFocus,
637
- isListOpen = _this$state2.isListOpen,
638
- listPosition = _this$state2.listPosition,
639
- searchValue = _this$state2.searchValue,
640
- width = _this$state2.width,
641
- matchingOptions = _this$state2.matchingOptions;
432
+ var _this$props11 = this.props,
433
+ dataTestSubj = _this$props11['data-test-subj'],
434
+ async = _this$props11.async,
435
+ className = _this$props11.className,
436
+ compressed = _this$props11.compressed,
437
+ customOptionText = _this$props11.customOptionText,
438
+ fullWidth = _this$props11.fullWidth,
439
+ id = _this$props11.id,
440
+ inputRef = _this$props11.inputRef,
441
+ isCaseSensitive = _this$props11.isCaseSensitive,
442
+ isClearable = _this$props11.isClearable,
443
+ isDisabled = _this$props11.isDisabled,
444
+ isInvalid = _this$props11.isInvalid,
445
+ isLoading = _this$props11.isLoading,
446
+ noSuggestions = _this$props11.noSuggestions,
447
+ onBlur = _this$props11.onBlur,
448
+ onChange = _this$props11.onChange,
449
+ onCreateOption = _this$props11.onCreateOption,
450
+ onSearchChange = _this$props11.onSearchChange,
451
+ options = _this$props11.options,
452
+ placeholder = _this$props11.placeholder,
453
+ renderOption = _this$props11.renderOption,
454
+ rowHeight = _this$props11.rowHeight,
455
+ selectedOptions = _this$props11.selectedOptions,
456
+ singleSelection = _this$props11.singleSelection,
457
+ prepend = _this$props11.prepend,
458
+ sortMatchesBy = _this$props11.sortMatchesBy,
459
+ delimiter = _this$props11.delimiter,
460
+ append = _this$props11.append,
461
+ autoFocus = _this$props11.autoFocus,
462
+ truncationProps = _this$props11.truncationProps,
463
+ inputPopoverProps = _this$props11.inputPopoverProps,
464
+ ariaLabel = _this$props11['aria-label'],
465
+ ariaLabelledby = _this$props11['aria-labelledby'],
466
+ rest = (0, _objectWithoutProperties2.default)(_this$props11, _excluded);
467
+ var _this$state = this.state,
468
+ activeOptionIndex = _this$state.activeOptionIndex,
469
+ hasFocus = _this$state.hasFocus,
470
+ isListOpen = _this$state.isListOpen,
471
+ searchValue = _this$state.searchValue,
472
+ matchingOptions = _this$state.matchingOptions;
642
473
 
643
474
  // Make sure we have a valid ID if users don't pass one as a prop
644
475
  var inputId = id !== null && id !== void 0 ? id : this.rootId('_eui-combobox-id');
@@ -662,12 +493,11 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
662
493
  var optionsList;
663
494
  if (!noSuggestions && isListOpen) {
664
495
  var optionsListDataTestSubj = dataTestSubj ? "".concat(dataTestSubj, "-optionsList") : undefined;
665
- optionsList = (0, _react2.jsx)(_portal.EuiPortal, null, (0, _react2.jsx)(_i18n.EuiI18n, {
496
+ optionsList = (0, _react2.jsx)(_i18n.EuiI18n, {
666
497
  token: "euiComboBox.listboxAriaLabel",
667
498
  default: "Choose from the following options"
668
499
  }, function (listboxAriaLabel) {
669
500
  return (0, _react2.jsx)(_combo_box_options_list.EuiComboBoxOptionsList, {
670
- zIndex: _this2.state.listZIndex,
671
501
  activeOptionIndex: _this2.state.activeOptionIndex,
672
502
  areAllOptionsSelected: _this2.areAllOptionsSelected(),
673
503
  customOptionText: customOptionText,
@@ -682,9 +512,7 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
682
512
  onOptionClick: _this2.onOptionClick,
683
513
  onOptionEnterKey: _this2.onOptionEnterKey,
684
514
  onScroll: _this2.onOptionListScroll,
685
- optionRef: _this2.optionRefCallback,
686
515
  options: options,
687
- position: listPosition,
688
516
  singleSelection: singleSelection,
689
517
  renderOption: renderOption,
690
518
  rootId: _this2.rootId,
@@ -692,14 +520,12 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
692
520
  scrollToIndex: activeOptionIndex,
693
521
  searchValue: searchValue,
694
522
  selectedOptions: selectedOptions,
695
- updatePosition: _this2.updatePosition,
696
- width: width,
697
523
  delimiter: delimiter,
698
524
  getSelectedOptionForSearchValue: _matching_options.getSelectedOptionForSearchValue,
699
525
  listboxAriaLabel: listboxAriaLabel,
700
526
  truncationProps: truncationProps
701
527
  });
702
- }));
528
+ });
703
529
  }
704
530
  return (
705
531
  /**
@@ -715,39 +541,46 @@ var EuiComboBox = /*#__PURE__*/function (_Component) {
715
541
  onKeyDown: this.onKeyDown,
716
542
  onBlur: this.onContainerBlur,
717
543
  ref: this.comboBoxRefCallback
718
- }), (0, _react2.jsx)(_combo_box_input.EuiComboBoxInput, {
719
- compressed: compressed,
720
- focusedOptionId: this.hasActiveOption() ? this.rootId("_option-".concat(this.state.activeOptionIndex)) : undefined,
544
+ }), (0, _react2.jsx)(_popover.EuiInputPopover, (0, _extends2.default)({
721
545
  fullWidth: fullWidth,
722
- hasSelectedOptions: selectedOptions.length > 0,
723
- id: inputId,
724
- inputRef: this.searchInputRefCallback,
725
- isDisabled: isDisabled,
726
- isListOpen: isListOpen,
727
- noIcon: !!noSuggestions,
728
- onChange: this.onSearchChange,
729
- onClear: isClearable && !isDisabled ? this.clearSelectedOptions : undefined,
730
- onClick: this.onComboBoxClick,
731
- onCloseListClick: this.onCloseListClick,
732
- onFocus: this.onComboBoxFocus,
733
- onOpenListClick: this.onOpenListClick,
734
- onRemoveOption: this.onRemoveOption,
735
- placeholder: placeholder,
736
- rootId: this.rootId,
737
- searchValue: searchValue,
738
- selectedOptions: selectedOptions,
739
- singleSelection: singleSelection,
740
- toggleButtonRef: this.toggleButtonRefCallback,
741
- updatePosition: this.updatePosition,
742
- value: value,
743
- append: singleSelection ? append : undefined,
744
- prepend: singleSelection ? prepend : undefined,
745
- isLoading: isLoading,
746
- isInvalid: markAsInvalid,
747
- autoFocus: autoFocus,
748
- "aria-label": ariaLabel,
749
- "aria-labelledby": ariaLabelledby
750
- }), optionsList)
546
+ panelPaddingSize: "none",
547
+ disableFocusTrap: true,
548
+ closeOnScroll: true
549
+ }, inputPopoverProps, {
550
+ isOpen: isListOpen,
551
+ closePopover: this.closeList,
552
+ input: (0, _react2.jsx)(_combo_box_input.EuiComboBoxInput, {
553
+ compressed: compressed,
554
+ focusedOptionId: this.hasActiveOption() ? this.rootId("_option-".concat(this.state.activeOptionIndex)) : undefined,
555
+ fullWidth: fullWidth,
556
+ hasSelectedOptions: selectedOptions.length > 0,
557
+ id: inputId,
558
+ inputRef: this.searchInputRefCallback,
559
+ isDisabled: isDisabled,
560
+ isListOpen: isListOpen,
561
+ noIcon: !!noSuggestions,
562
+ onChange: this.onSearchChange,
563
+ onClear: isClearable && !isDisabled ? this.clearSelectedOptions : undefined,
564
+ onClick: this.onComboBoxClick,
565
+ onCloseListClick: this.closeList,
566
+ onFocus: this.onComboBoxFocus,
567
+ onOpenListClick: this.onOpenListClick,
568
+ onRemoveOption: this.onRemoveOption,
569
+ placeholder: placeholder,
570
+ rootId: this.rootId,
571
+ searchValue: searchValue,
572
+ selectedOptions: selectedOptions,
573
+ singleSelection: singleSelection,
574
+ value: value,
575
+ append: singleSelection ? append : undefined,
576
+ prepend: singleSelection ? prepend : undefined,
577
+ isLoading: isLoading,
578
+ isInvalid: markAsInvalid,
579
+ autoFocus: autoFocus,
580
+ "aria-label": ariaLabel,
581
+ "aria-labelledby": ariaLabelledby
582
+ })
583
+ }), optionsList))
751
584
  );
752
585
  }
753
586
  }], [{