@elastic/eui 12.3.1 → 12.4.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/CHANGELOG.md +16 -1
- package/dist/eui.js +1168 -210
- package/dist/eui.js.map +1 -1
- package/dist/eui.min.js +5 -5
- package/es/components/accordion/accordion.js +79 -56
- package/es/components/accordion/accordion.test.js +88 -0
- package/es/components/badge/badge.js +22 -1
- package/es/components/badge/beta_badge/beta_badge.js +22 -1
- package/es/components/combo_box/combo_box.js +2 -1
- package/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +47 -5
- package/es/components/delay_hide/delay_hide.test.js +5 -1
- package/es/components/filter_group/filter_button.js +17 -2
- package/es/components/form/form_control_layout/form_control_layout_custom_icon.js +22 -1
- package/es/components/form/form_control_layout/form_control_layout_icons.js +44 -2
- package/es/components/form/range/dual_range.js +1 -1
- package/es/components/form/range/range.js +1 -1
- package/es/components/form/range/range_highlight.js +1 -1
- package/es/components/form/range/range_label.js +27 -8
- package/es/components/form/range/range_levels.js +13 -8
- package/es/components/form/range/range_levels.test.js +55 -0
- package/es/components/form/range/range_slider.js +12 -8
- package/es/components/form/range/range_thumb.js +35 -3
- package/es/components/form/range/range_ticks.js +43 -22
- package/es/components/form/range/range_tooltip.js +20 -4
- package/es/components/form/range/range_track.js +33 -14
- package/es/components/form/range/range_track.test.js +100 -0
- package/es/components/form/range/range_wrapper.js +9 -2
- package/es/components/header/header_logo.js +22 -1
- package/es/components/icon/assets/cloudDrizzle.js +21 -0
- package/es/components/icon/assets/cloudStormy.js +21 -0
- package/es/components/icon/assets/cloudSunny.js +21 -0
- package/es/components/icon/assets/documentEdit.js +21 -0
- package/es/components/icon/assets/documents.js +21 -0
- package/es/components/icon/assets/popout.js +1 -1
- package/es/components/icon/assets/training.js +21 -0
- package/es/components/icon/assets/videoPlayer.js +21 -0
- package/es/components/icon/icon.js +29 -1
- package/es/components/index.js +1 -0
- package/es/components/inner_text/index.js +1 -0
- package/es/components/inner_text/inner_text.js +66 -0
- package/es/components/inner_text/inner_text.test.js +240 -0
- package/es/components/list_group/list_group_item.js +21 -2
- package/es/components/popover/popover.js +7 -3
- package/es/components/search_bar/query/ast_to_es_query_dsl.js +2 -2
- package/es/components/toast/global_toast_list.js +22 -1
- package/es/components/toast/toast.js +22 -1
- package/es/components/token/token.js +22 -1
- package/es/components/tool_tip/icon_tip.js +22 -1
- package/eui.d.ts +435 -187
- package/lib/components/accordion/accordion.js +79 -55
- package/lib/components/accordion/accordion.test.js +96 -0
- package/lib/components/badge/badge.js +22 -1
- package/lib/components/badge/beta_badge/beta_badge.js +22 -1
- package/lib/components/combo_box/combo_box.js +2 -1
- package/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +47 -5
- package/lib/components/delay_hide/delay_hide.test.js +5 -1
- package/lib/components/filter_group/filter_button.js +18 -2
- package/lib/components/form/form_control_layout/form_control_layout_custom_icon.js +22 -1
- package/lib/components/form/form_control_layout/form_control_layout_icons.js +44 -2
- package/lib/components/form/range/dual_range.js +1 -1
- package/lib/components/form/range/range.js +1 -1
- package/lib/components/form/range/range_label.js +26 -7
- package/lib/components/form/range/range_levels.js +12 -7
- package/lib/components/form/range/range_levels.test.js +63 -0
- package/lib/components/form/range/range_slider.js +13 -8
- package/lib/components/form/range/range_thumb.js +34 -2
- package/lib/components/form/range/range_ticks.js +43 -21
- package/lib/components/form/range/range_tooltip.js +19 -3
- package/lib/components/form/range/range_track.js +32 -13
- package/lib/components/form/range/range_track.test.js +108 -0
- package/lib/components/form/range/range_wrapper.js +9 -4
- package/lib/components/header/header_logo.js +22 -1
- package/lib/components/icon/assets/cloudDrizzle.js +31 -0
- package/lib/components/icon/assets/cloudDrizzle.svg +3 -0
- package/lib/components/icon/assets/cloudStormy.js +31 -0
- package/lib/components/icon/assets/cloudStormy.svg +3 -0
- package/lib/components/icon/assets/cloudSunny.js +31 -0
- package/lib/components/icon/assets/cloudSunny.svg +3 -0
- package/lib/components/icon/assets/documentEdit.js +31 -0
- package/lib/components/icon/assets/documentEdit.svg +3 -0
- package/lib/components/icon/assets/documents.js +31 -0
- package/lib/components/icon/assets/documents.svg +3 -0
- package/lib/components/icon/assets/popout.js +1 -1
- package/lib/components/icon/assets/popout.svg +1 -1
- package/lib/components/icon/assets/training.js +31 -0
- package/lib/components/icon/assets/training.svg +3 -0
- package/lib/components/icon/assets/videoPlayer.js +31 -0
- package/lib/components/icon/assets/videoPlayer.svg +3 -0
- package/lib/components/icon/icon.js +29 -1
- package/lib/components/index.js +14 -0
- package/lib/components/inner_text/index.js +19 -0
- package/lib/components/inner_text/inner_text.js +80 -0
- package/lib/components/inner_text/inner_text.test.js +250 -0
- package/lib/components/list_group/list_group_item.js +22 -3
- package/lib/components/popover/popover.js +7 -3
- package/lib/components/search_bar/query/ast_to_es_query_dsl.js +2 -2
- package/lib/components/toast/global_toast_list.js +22 -1
- package/lib/components/toast/toast.js +22 -1
- package/lib/components/token/token.js +22 -1
- package/lib/components/tool_tip/icon_tip.js +22 -1
- package/package.json +7 -4
- package/postcss.config.js +6 -0
|
@@ -11,6 +11,8 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
11
11
|
|
|
12
12
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
13
|
|
|
14
|
+
var _common = require("../common");
|
|
15
|
+
|
|
14
16
|
var _icon = require("../icon");
|
|
15
17
|
|
|
16
18
|
var _flex = require("../flex");
|
|
@@ -55,7 +57,7 @@ var paddingSizeToClassNameMap = {
|
|
|
55
57
|
l: 'euiAccordion__padding--l',
|
|
56
58
|
xl: 'euiAccordion__padding--xl'
|
|
57
59
|
};
|
|
58
|
-
var PADDING_SIZES =
|
|
60
|
+
var PADDING_SIZES = (0, _common.keysOf)(paddingSizeToClassNameMap);
|
|
59
61
|
exports.PADDING_SIZES = PADDING_SIZES;
|
|
60
62
|
|
|
61
63
|
var EuiAccordion =
|
|
@@ -63,12 +65,26 @@ var EuiAccordion =
|
|
|
63
65
|
function (_Component) {
|
|
64
66
|
_inherits(EuiAccordion, _Component);
|
|
65
67
|
|
|
66
|
-
function EuiAccordion(
|
|
68
|
+
function EuiAccordion() {
|
|
69
|
+
var _getPrototypeOf2;
|
|
70
|
+
|
|
67
71
|
var _this;
|
|
68
72
|
|
|
69
73
|
_classCallCheck(this, EuiAccordion);
|
|
70
74
|
|
|
71
|
-
|
|
75
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
76
|
+
args[_key] = arguments[_key];
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(EuiAccordion)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
80
|
+
|
|
81
|
+
_defineProperty(_assertThisInitialized(_assertThisInitialized(_this)), "childContent", null);
|
|
82
|
+
|
|
83
|
+
_defineProperty(_assertThisInitialized(_assertThisInitialized(_this)), "childWrapper", null);
|
|
84
|
+
|
|
85
|
+
_defineProperty(_assertThisInitialized(_assertThisInitialized(_this)), "state", {
|
|
86
|
+
isOpen: _this.props.initialIsOpen
|
|
87
|
+
});
|
|
72
88
|
|
|
73
89
|
_defineProperty(_assertThisInitialized(_assertThisInitialized(_this)), "setChildContentHeight", function () {
|
|
74
90
|
requestAnimationFrame(function () {
|
|
@@ -77,14 +93,20 @@ function (_Component) {
|
|
|
77
93
|
});
|
|
78
94
|
});
|
|
79
95
|
|
|
96
|
+
_defineProperty(_assertThisInitialized(_assertThisInitialized(_this)), "onToggle", function () {
|
|
97
|
+
_this.setState(function (prevState) {
|
|
98
|
+
return {
|
|
99
|
+
isOpen: !prevState.isOpen
|
|
100
|
+
};
|
|
101
|
+
}, function () {
|
|
102
|
+
_this.props.onToggle && _this.props.onToggle(_this.state.isOpen);
|
|
103
|
+
});
|
|
104
|
+
});
|
|
105
|
+
|
|
80
106
|
_defineProperty(_assertThisInitialized(_assertThisInitialized(_this)), "setChildContentRef", function (node) {
|
|
81
107
|
_this.childContent = node;
|
|
82
108
|
});
|
|
83
109
|
|
|
84
|
-
_this.state = {
|
|
85
|
-
isOpen: props.initialIsOpen
|
|
86
|
-
};
|
|
87
|
-
_this.onToggle = _this.onToggle.bind(_assertThisInitialized(_assertThisInitialized(_this)));
|
|
88
110
|
return _this;
|
|
89
111
|
}
|
|
90
112
|
|
|
@@ -98,23 +120,10 @@ function (_Component) {
|
|
|
98
120
|
value: function componentDidUpdate() {
|
|
99
121
|
this.setChildContentHeight();
|
|
100
122
|
}
|
|
101
|
-
}, {
|
|
102
|
-
key: "onToggle",
|
|
103
|
-
value: function onToggle() {
|
|
104
|
-
var _this2 = this;
|
|
105
|
-
|
|
106
|
-
this.setState(function (prevState) {
|
|
107
|
-
return {
|
|
108
|
-
isOpen: !prevState.isOpen
|
|
109
|
-
};
|
|
110
|
-
}, function () {
|
|
111
|
-
_this2.props.onToggle && _this2.props.onToggle(_this2.state.isOpen);
|
|
112
|
-
});
|
|
113
|
-
}
|
|
114
123
|
}, {
|
|
115
124
|
key: "render",
|
|
116
125
|
value: function render() {
|
|
117
|
-
var
|
|
126
|
+
var _this2 = this;
|
|
118
127
|
|
|
119
128
|
var _this$props = this.props,
|
|
120
129
|
children = _this$props.children,
|
|
@@ -171,7 +180,7 @@ function (_Component) {
|
|
|
171
180
|
}, buttonContent)))), optionalAction), _react.default.createElement("div", {
|
|
172
181
|
className: "euiAccordion__childWrapper",
|
|
173
182
|
ref: function ref(node) {
|
|
174
|
-
|
|
183
|
+
_this2.childWrapper = node;
|
|
175
184
|
},
|
|
176
185
|
id: id
|
|
177
186
|
}, _react.default.createElement(_mutation_observer.EuiMutationObserver, {
|
|
@@ -183,7 +192,7 @@ function (_Component) {
|
|
|
183
192
|
}, function (mutationRef) {
|
|
184
193
|
return _react.default.createElement("div", {
|
|
185
194
|
ref: function ref(_ref) {
|
|
186
|
-
|
|
195
|
+
_this2.setChildContentRef(_ref);
|
|
187
196
|
|
|
188
197
|
mutationRef(_ref);
|
|
189
198
|
}
|
|
@@ -198,51 +207,52 @@ function (_Component) {
|
|
|
198
207
|
}(_react.Component);
|
|
199
208
|
|
|
200
209
|
exports.EuiAccordion = EuiAccordion;
|
|
210
|
+
|
|
211
|
+
_defineProperty(EuiAccordion, "defaultProps", {
|
|
212
|
+
initialIsOpen: false,
|
|
213
|
+
paddingSize: 'none'
|
|
214
|
+
});
|
|
215
|
+
|
|
201
216
|
EuiAccordion.propTypes = {
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
children: _propTypes.default.node,
|
|
217
|
+
className: _propTypes.default.string,
|
|
218
|
+
"aria-label": _propTypes.default.string,
|
|
219
|
+
"data-test-subj": _propTypes.default.string,
|
|
206
220
|
id: _propTypes.default.string.isRequired,
|
|
207
221
|
|
|
208
222
|
/**
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
223
|
+
* Class that will apply to the trigger for the accordion.
|
|
224
|
+
*/
|
|
225
|
+
buttonClassName: _propTypes.default.string,
|
|
212
226
|
|
|
213
227
|
/**
|
|
214
|
-
|
|
215
|
-
|
|
228
|
+
* Class that will apply to the trigger content for the accordion.
|
|
229
|
+
*/
|
|
216
230
|
buttonContentClassName: _propTypes.default.string,
|
|
217
231
|
|
|
218
232
|
/**
|
|
219
|
-
|
|
220
|
-
|
|
233
|
+
* The content of the clickable trigger
|
|
234
|
+
*/
|
|
221
235
|
buttonContent: _propTypes.default.node,
|
|
222
236
|
|
|
223
237
|
/**
|
|
224
|
-
|
|
225
|
-
|
|
238
|
+
* Will appear right aligned against the button. Useful for separate actions like deletions.
|
|
239
|
+
*/
|
|
226
240
|
extraAction: _propTypes.default.node,
|
|
227
241
|
|
|
228
242
|
/**
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
initialIsOpen: _propTypes.default.bool,
|
|
243
|
+
* The accordion will start in the open state.
|
|
244
|
+
*/
|
|
245
|
+
initialIsOpen: _propTypes.default.bool.isRequired,
|
|
232
246
|
|
|
233
247
|
/**
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
248
|
+
* Optional callback method called on open and close with a single `isOpen` parameter
|
|
249
|
+
*/
|
|
250
|
+
onToggle: _propTypes.default.func,
|
|
237
251
|
|
|
238
252
|
/**
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
};
|
|
243
|
-
EuiAccordion.defaultProps = {
|
|
244
|
-
initialIsOpen: false,
|
|
245
|
-
paddingSize: 'none'
|
|
253
|
+
* The padding around the exposed accordion content.
|
|
254
|
+
*/
|
|
255
|
+
paddingSize: _propTypes.default.oneOf(["none", "xs", "s", "m", "l", "xl"]).isRequired
|
|
246
256
|
};
|
|
247
257
|
EuiAccordion.__docgenInfo = {
|
|
248
258
|
"description": "",
|
|
@@ -311,12 +321,26 @@ EuiAccordion.__docgenInfo = {
|
|
|
311
321
|
"required": false,
|
|
312
322
|
"description": "The padding around the exposed accordion content."
|
|
313
323
|
},
|
|
314
|
-
"
|
|
324
|
+
"className": {
|
|
315
325
|
"type": {
|
|
316
|
-
"name": "
|
|
326
|
+
"name": "string"
|
|
317
327
|
},
|
|
318
328
|
"required": false,
|
|
319
|
-
"description": "
|
|
329
|
+
"description": ""
|
|
330
|
+
},
|
|
331
|
+
"aria-label": {
|
|
332
|
+
"type": {
|
|
333
|
+
"name": "string"
|
|
334
|
+
},
|
|
335
|
+
"required": false,
|
|
336
|
+
"description": ""
|
|
337
|
+
},
|
|
338
|
+
"data-test-subj": {
|
|
339
|
+
"type": {
|
|
340
|
+
"name": "string"
|
|
341
|
+
},
|
|
342
|
+
"required": false,
|
|
343
|
+
"description": ""
|
|
320
344
|
},
|
|
321
345
|
"id": {
|
|
322
346
|
"type": {
|
|
@@ -325,19 +349,19 @@ EuiAccordion.__docgenInfo = {
|
|
|
325
349
|
"required": true,
|
|
326
350
|
"description": ""
|
|
327
351
|
},
|
|
328
|
-
"
|
|
352
|
+
"buttonClassName": {
|
|
329
353
|
"type": {
|
|
330
354
|
"name": "string"
|
|
331
355
|
},
|
|
332
356
|
"required": false,
|
|
333
|
-
"description": "Class that will apply to the
|
|
357
|
+
"description": "Class that will apply to the trigger for the accordion."
|
|
334
358
|
},
|
|
335
359
|
"buttonContentClassName": {
|
|
336
360
|
"type": {
|
|
337
361
|
"name": "string"
|
|
338
362
|
},
|
|
339
363
|
"required": false,
|
|
340
|
-
"description": "Class that will apply to the trigger for the accordion."
|
|
364
|
+
"description": "Class that will apply to the trigger content for the accordion."
|
|
341
365
|
},
|
|
342
366
|
"buttonContent": {
|
|
343
367
|
"type": {
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _react = _interopRequireDefault(require("react"));
|
|
4
|
+
|
|
5
|
+
var _enzyme = require("enzyme");
|
|
6
|
+
|
|
7
|
+
var _required_props = require("../../test/required_props");
|
|
8
|
+
|
|
9
|
+
var _accordion = require("./accordion");
|
|
10
|
+
|
|
11
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
12
|
+
|
|
13
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
14
|
+
|
|
15
|
+
var id = 0;
|
|
16
|
+
|
|
17
|
+
var getId = function getId() {
|
|
18
|
+
return "".concat(id++);
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
describe('EuiAccordion', function () {
|
|
22
|
+
test('is rendered', function () {
|
|
23
|
+
var component = (0, _enzyme.render)(_react.default.createElement(_accordion.EuiAccordion, _extends({
|
|
24
|
+
id: getId()
|
|
25
|
+
}, _required_props.requiredProps)));
|
|
26
|
+
expect(component).toMatchSnapshot();
|
|
27
|
+
});
|
|
28
|
+
describe('props', function () {
|
|
29
|
+
describe('buttonContentClassName', function () {
|
|
30
|
+
it('is rendered', function () {
|
|
31
|
+
var component = (0, _enzyme.render)(_react.default.createElement(_accordion.EuiAccordion, {
|
|
32
|
+
id: getId(),
|
|
33
|
+
buttonContentClassName: "button content class name"
|
|
34
|
+
}));
|
|
35
|
+
expect(component).toMatchSnapshot();
|
|
36
|
+
});
|
|
37
|
+
});
|
|
38
|
+
describe('buttonContent', function () {
|
|
39
|
+
it('is rendered', function () {
|
|
40
|
+
var component = (0, _enzyme.render)(_react.default.createElement(_accordion.EuiAccordion, {
|
|
41
|
+
id: getId(),
|
|
42
|
+
buttonContent: _react.default.createElement("div", null, "Button content")
|
|
43
|
+
}));
|
|
44
|
+
expect(component).toMatchSnapshot();
|
|
45
|
+
});
|
|
46
|
+
});
|
|
47
|
+
describe('extraAction', function () {
|
|
48
|
+
it('is rendered', function () {
|
|
49
|
+
var component = (0, _enzyme.render)(_react.default.createElement(_accordion.EuiAccordion, {
|
|
50
|
+
id: getId(),
|
|
51
|
+
extraAction: _react.default.createElement("button", null, "Extra action")
|
|
52
|
+
}));
|
|
53
|
+
expect(component).toMatchSnapshot();
|
|
54
|
+
});
|
|
55
|
+
});
|
|
56
|
+
describe('initialIsOpen', function () {
|
|
57
|
+
it('is rendered', function () {
|
|
58
|
+
var component = (0, _enzyme.render)(_react.default.createElement(_accordion.EuiAccordion, {
|
|
59
|
+
id: getId(),
|
|
60
|
+
initialIsOpen: true
|
|
61
|
+
}, _react.default.createElement("p", null, "You can see me.")));
|
|
62
|
+
expect(component).toMatchSnapshot();
|
|
63
|
+
});
|
|
64
|
+
});
|
|
65
|
+
});
|
|
66
|
+
describe('behavior', function () {
|
|
67
|
+
it('opens when clicked once', function () {
|
|
68
|
+
var component = (0, _enzyme.mount)(_react.default.createElement(_accordion.EuiAccordion, {
|
|
69
|
+
id: getId()
|
|
70
|
+
}));
|
|
71
|
+
component.find('button').simulate('click');
|
|
72
|
+
expect(component).toMatchSnapshot();
|
|
73
|
+
});
|
|
74
|
+
it('closes when clicked twice', function () {
|
|
75
|
+
var component = (0, _enzyme.mount)(_react.default.createElement(_accordion.EuiAccordion, {
|
|
76
|
+
id: getId()
|
|
77
|
+
}));
|
|
78
|
+
component.find('button').simulate('click');
|
|
79
|
+
component.find('button').simulate('click');
|
|
80
|
+
expect(component).toMatchSnapshot();
|
|
81
|
+
});
|
|
82
|
+
it('accepts and calls an optional callback on open and close', function () {
|
|
83
|
+
var onToggleHandler = jest.fn();
|
|
84
|
+
var component = (0, _enzyme.mount)(_react.default.createElement(_accordion.EuiAccordion, {
|
|
85
|
+
id: getId(),
|
|
86
|
+
onToggle: onToggleHandler
|
|
87
|
+
}));
|
|
88
|
+
component.find('button').simulate('click');
|
|
89
|
+
expect(onToggleHandler).toBeCalled();
|
|
90
|
+
expect(onToggleHandler).toBeCalledWith(true);
|
|
91
|
+
component.find('button').simulate('click');
|
|
92
|
+
expect(onToggleHandler).toBeCalled();
|
|
93
|
+
expect(onToggleHandler).toBeCalledWith(false);
|
|
94
|
+
});
|
|
95
|
+
});
|
|
96
|
+
});
|
|
@@ -158,7 +158,7 @@ EuiBadge.propTypes = {
|
|
|
158
158
|
/**
|
|
159
159
|
* Accepts any string from our icon library
|
|
160
160
|
*/
|
|
161
|
-
iconType: _propTypes.default.oneOfType([_propTypes.default.oneOf(["addDataApp", "advancedSettingsApp", "alert", "apmApp", "apmTrace", "apps", "arrowDown", "arrowLeft", "arrowRight", "arrowUp", "asterisk", "auditbeatApp", "beaker", "bell", "bolt", "boxesHorizontal", "boxesVertical", "branch", "broom", "brush", "bug", "bullseye", "calendar", "canvasApp", "codeApp", "check", "checkInCircleFilled", "clock", "compute", "console", "consoleApp", "controlsHorizontal", "controlsVertical", "copy", "copyClipboard", "createAdvancedJob", "createMultiMetricJob", "createPopulationJob", "createSingleMetricJob", "cross", "crossClusterReplicationApp", "crosshairs", "crossInACircleFilled", "cut", "dashboardApp", "database", "dataVisualizer", "devToolsApp", "discoverApp", "document", "dot", "editorAlignCenter", "editorAlignLeft", "editorAlignRight", "editorBold", "editorCodeBlock", "editorComment", "editorDistributeHorizontal", "editorDistributeVertical", "editorHeading", "editorItalic", "editorItemAlignLeft", "editorItemAlignBottom", "editorItemAlignCenter", "editorItemAlignMiddle", "editorItemAlignRight", "editorItemAlignTop", "editorLink", "editorOrderedList", "editorPositionBottomLeft", "editorPositionBottomRight", "editorPositionTopLeft", "editorPositionTopRight", "editorRedo", "editorStrike", "editorTable", "editorUnderline", "editorUndo", "editorUnorderedList", "email", "empty", "emsApp", "exit", "expand", "exportAction", "eye", "eyeClosed", "faceHappy", "faceNeutral", "faceSad", "filebeatApp", "filter", "flag", "folderClosed", "folderOpen", "fullScreen", "gear", "gisApp", "glasses", "globe", "grab", "grabHorizontal", "graphApp", "grid", "grokApp", "heart", "heartbeatApp", "heatmap", "help", "iInCircle", "importAction", "indexClose", "indexEdit", "indexFlush", "indexManagementApp", "indexMapping", "indexOpen", "indexPatternApp", "indexRollupApp", "indexSettings", "infraApp", "inputOutput", "inspect", "invert", "kqlField", "kqlFunction", "kqlOperand", "kqlSelector", "kqlValue", "link", "list", "listAdd", "lock", "lockOpen", "loggingApp", "logoAerospike", "logoApache", "logoAPM", "logoAppSearch", "logoAWS", "logoAWSMono", "logoAzure", "logoAzureMono", "logoBeats", "logoBusinessAnalytics", "logoCeph", "logoCloud", "logoCloudEnterprise", "logoCode", "logoCodesandbox", "logoCouchbase", "logoDocker", "logoDropwizard", "logoElastic", "logoElasticsearch", "logoElasticStack", "logoEnterpriseSearch", "logoEtcd", "logoGCP", "logoGCPMono", "logoGithub", "logoGmail", "logoGolang", "logoHAproxy", "logoIBM", "logoIBMMono", "logoKafka", "logoKibana", "logoKubernetes", "logoLogging", "logoLogstash", "logoMaps", "logoMemcached", "logoMetrics", "logoMongodb", "logoMySQL", "logoNginx", "logoOsquery", "logoPhp", "logoPostgres", "logoPrometheus", "logoRabbitmq", "logoRedis", "logoSecurity", "logoSiteSearch", "logoSketch", "logoSlack", "logoUptime", "logoWebhook", "logoWindows", "logstashFilter", "logstashIf", "logstashInput", "logstashOutput", "logstashQueue", "machineLearningApp", "magnet", "magnifyWithMinus", "magnifyWithPlus", "managementApp", "mapMarker", "memory", "menuLeft", "menuRight", "merge", "metricbeatApp", "minusInCircle", "minusInCircleFilled", "monitoringApp", "moon", "node", "notebookApp", "number", "offline", "online", "packetbeatApp", "pause", "pencil", "pin", "pinFilled", "pipelineApp", "play", "plusInCircle", "plusInCircleFilled", "popout", "questionInCircle", "refresh", "reportingApp", "save", "savedObjectsApp", "scale", "search", "searchProfilerApp", "securityAnalyticsApp", "securityApp", "shard", "share", "snowflake", "sortable", "sortDown", "sortLeft", "sortRight", "sortUp", "spacesApp", "sqlApp", "starEmpty", "starEmptySpace", "starFilled", "starFilledSpace", "starMinusEmpty", "starMinusFilled", "starPlusEmpty", "starPlusFilled", "stats", "stop", "stopFilled", "stopSlash", "storage", "string", "submodule", "swatchInput", "symlink", "tableOfContents", "tag", "tear", "temperature", "timelionApp", "trash", "upgradeAssistantApp", "uptimeApp", "user", "usersRolesApp", "vector", "visArea", "visBarHorizontal", "visBarVertical", "visControls", "visGauge", "visGoal", "visHeatmap", "visLine", "visMapCoordinate", "visMapRegion", "visMetric", "visPie", "visTable", "visTagCloud", "visText", "visTimelion", "visualizeApp", "visVega", "visVisualBuilder", "watchesApp", "wrench", "tokenClass", "tokenProperty", "tokenEnum", "tokenVariable", "tokenMethod", "tokenAnnotation", "tokenException", "tokenInterface", "tokenParameter", "tokenField", "tokenElement", "tokenFunction", "tokenBoolean", "tokenString", "tokenArray", "tokenNumber", "tokenConstant", "tokenObject", "tokenEvent", "tokenKey", "tokenNull", "tokenStruct", "tokenPackage", "tokenOperator", "tokenEnumMember", "tokenRepo", "tokenSymbol", "tokenFile", "tokenModule", "tokenNamespace"]).isRequired, _propTypes.default.string.isRequired, _propTypes.default.element.isRequired]),
|
|
161
|
+
iconType: _propTypes.default.oneOfType([_propTypes.default.oneOf(["addDataApp", "advancedSettingsApp", "alert", "apmApp", "apmTrace", "apps", "arrowDown", "arrowLeft", "arrowRight", "arrowUp", "asterisk", "auditbeatApp", "beaker", "bell", "bolt", "boxesHorizontal", "boxesVertical", "branch", "broom", "brush", "bug", "bullseye", "calendar", "canvasApp", "codeApp", "check", "checkInCircleFilled", "clock", "cloudDrizzle", "cloudStormy", "cloudSunny", "compute", "console", "consoleApp", "controlsHorizontal", "controlsVertical", "copy", "copyClipboard", "createAdvancedJob", "createMultiMetricJob", "createPopulationJob", "createSingleMetricJob", "cross", "crossClusterReplicationApp", "crosshairs", "crossInACircleFilled", "cut", "dashboardApp", "database", "dataVisualizer", "devToolsApp", "discoverApp", "document", "documentEdit", "documents", "dot", "editorAlignCenter", "editorAlignLeft", "editorAlignRight", "editorBold", "editorCodeBlock", "editorComment", "editorDistributeHorizontal", "editorDistributeVertical", "editorHeading", "editorItalic", "editorItemAlignLeft", "editorItemAlignBottom", "editorItemAlignCenter", "editorItemAlignMiddle", "editorItemAlignRight", "editorItemAlignTop", "editorLink", "editorOrderedList", "editorPositionBottomLeft", "editorPositionBottomRight", "editorPositionTopLeft", "editorPositionTopRight", "editorRedo", "editorStrike", "editorTable", "editorUnderline", "editorUndo", "editorUnorderedList", "email", "empty", "emsApp", "exit", "expand", "exportAction", "eye", "eyeClosed", "faceHappy", "faceNeutral", "faceSad", "filebeatApp", "filter", "flag", "folderClosed", "folderOpen", "fullScreen", "gear", "gisApp", "glasses", "globe", "grab", "grabHorizontal", "graphApp", "grid", "grokApp", "heart", "heartbeatApp", "heatmap", "help", "iInCircle", "importAction", "indexClose", "indexEdit", "indexFlush", "indexManagementApp", "indexMapping", "indexOpen", "indexPatternApp", "indexRollupApp", "indexSettings", "infraApp", "inputOutput", "inspect", "invert", "kqlField", "kqlFunction", "kqlOperand", "kqlSelector", "kqlValue", "link", "list", "listAdd", "lock", "lockOpen", "loggingApp", "logoAerospike", "logoApache", "logoAPM", "logoAppSearch", "logoAWS", "logoAWSMono", "logoAzure", "logoAzureMono", "logoBeats", "logoBusinessAnalytics", "logoCeph", "logoCloud", "logoCloudEnterprise", "logoCode", "logoCodesandbox", "logoCouchbase", "logoDocker", "logoDropwizard", "logoElastic", "logoElasticsearch", "logoElasticStack", "logoEnterpriseSearch", "logoEtcd", "logoGCP", "logoGCPMono", "logoGithub", "logoGmail", "logoGolang", "logoHAproxy", "logoIBM", "logoIBMMono", "logoKafka", "logoKibana", "logoKubernetes", "logoLogging", "logoLogstash", "logoMaps", "logoMemcached", "logoMetrics", "logoMongodb", "logoMySQL", "logoNginx", "logoOsquery", "logoPhp", "logoPostgres", "logoPrometheus", "logoRabbitmq", "logoRedis", "logoSecurity", "logoSiteSearch", "logoSketch", "logoSlack", "logoUptime", "logoWebhook", "logoWindows", "logstashFilter", "logstashIf", "logstashInput", "logstashOutput", "logstashQueue", "machineLearningApp", "magnet", "magnifyWithMinus", "magnifyWithPlus", "managementApp", "mapMarker", "memory", "menuLeft", "menuRight", "merge", "metricbeatApp", "minusInCircle", "minusInCircleFilled", "monitoringApp", "moon", "node", "notebookApp", "number", "offline", "online", "packetbeatApp", "pause", "pencil", "pin", "pinFilled", "pipelineApp", "play", "plusInCircle", "plusInCircleFilled", "popout", "questionInCircle", "refresh", "reportingApp", "save", "savedObjectsApp", "scale", "search", "searchProfilerApp", "securityAnalyticsApp", "securityApp", "shard", "share", "snowflake", "sortable", "sortDown", "sortLeft", "sortRight", "sortUp", "spacesApp", "sqlApp", "starEmpty", "starEmptySpace", "starFilled", "starFilledSpace", "starMinusEmpty", "starMinusFilled", "starPlusEmpty", "starPlusFilled", "stats", "stop", "stopFilled", "stopSlash", "storage", "string", "submodule", "swatchInput", "symlink", "tableOfContents", "tag", "tear", "temperature", "timelionApp", "training", "trash", "upgradeAssistantApp", "uptimeApp", "user", "usersRolesApp", "vector", "videoPlayer", "visArea", "visBarHorizontal", "visBarVertical", "visControls", "visGauge", "visGoal", "visHeatmap", "visLine", "visMapCoordinate", "visMapRegion", "visMetric", "visPie", "visTable", "visTagCloud", "visText", "visTimelion", "visualizeApp", "visVega", "visVisualBuilder", "watchesApp", "wrench", "tokenClass", "tokenProperty", "tokenEnum", "tokenVariable", "tokenMethod", "tokenAnnotation", "tokenException", "tokenInterface", "tokenParameter", "tokenField", "tokenElement", "tokenFunction", "tokenBoolean", "tokenString", "tokenArray", "tokenNumber", "tokenConstant", "tokenObject", "tokenEvent", "tokenKey", "tokenNull", "tokenStruct", "tokenPackage", "tokenOperator", "tokenEnumMember", "tokenRepo", "tokenSymbol", "tokenFile", "tokenModule", "tokenNamespace"]).isRequired, _propTypes.default.string.isRequired, _propTypes.default.element.isRequired]),
|
|
162
162
|
|
|
163
163
|
/**
|
|
164
164
|
* The side of the badge the icon should sit
|
|
@@ -366,6 +366,15 @@ EuiBadge.__docgenInfo = {
|
|
|
366
366
|
}, {
|
|
367
367
|
"value": "\"clock\"",
|
|
368
368
|
"computed": false
|
|
369
|
+
}, {
|
|
370
|
+
"value": "\"cloudDrizzle\"",
|
|
371
|
+
"computed": false
|
|
372
|
+
}, {
|
|
373
|
+
"value": "\"cloudStormy\"",
|
|
374
|
+
"computed": false
|
|
375
|
+
}, {
|
|
376
|
+
"value": "\"cloudSunny\"",
|
|
377
|
+
"computed": false
|
|
369
378
|
}, {
|
|
370
379
|
"value": "\"compute\"",
|
|
371
380
|
"computed": false
|
|
@@ -432,6 +441,12 @@ EuiBadge.__docgenInfo = {
|
|
|
432
441
|
}, {
|
|
433
442
|
"value": "\"document\"",
|
|
434
443
|
"computed": false
|
|
444
|
+
}, {
|
|
445
|
+
"value": "\"documentEdit\"",
|
|
446
|
+
"computed": false
|
|
447
|
+
}, {
|
|
448
|
+
"value": "\"documents\"",
|
|
449
|
+
"computed": false
|
|
435
450
|
}, {
|
|
436
451
|
"value": "\"dot\"",
|
|
437
452
|
"computed": false
|
|
@@ -1083,6 +1098,9 @@ EuiBadge.__docgenInfo = {
|
|
|
1083
1098
|
}, {
|
|
1084
1099
|
"value": "\"timelionApp\"",
|
|
1085
1100
|
"computed": false
|
|
1101
|
+
}, {
|
|
1102
|
+
"value": "\"training\"",
|
|
1103
|
+
"computed": false
|
|
1086
1104
|
}, {
|
|
1087
1105
|
"value": "\"trash\"",
|
|
1088
1106
|
"computed": false
|
|
@@ -1101,6 +1119,9 @@ EuiBadge.__docgenInfo = {
|
|
|
1101
1119
|
}, {
|
|
1102
1120
|
"value": "\"vector\"",
|
|
1103
1121
|
"computed": false
|
|
1122
|
+
}, {
|
|
1123
|
+
"value": "\"videoPlayer\"",
|
|
1124
|
+
"computed": false
|
|
1104
1125
|
}, {
|
|
1105
1126
|
"value": "\"visArea\"",
|
|
1106
1127
|
"computed": false
|
|
@@ -80,7 +80,7 @@ EuiBetaBadge.propTypes = {
|
|
|
80
80
|
/**
|
|
81
81
|
* Supply an icon type if the badge should just be an icon
|
|
82
82
|
*/
|
|
83
|
-
iconType: _propTypes.default.oneOfType([_propTypes.default.oneOf(["addDataApp", "advancedSettingsApp", "alert", "apmApp", "apmTrace", "apps", "arrowDown", "arrowLeft", "arrowRight", "arrowUp", "asterisk", "auditbeatApp", "beaker", "bell", "bolt", "boxesHorizontal", "boxesVertical", "branch", "broom", "brush", "bug", "bullseye", "calendar", "canvasApp", "codeApp", "check", "checkInCircleFilled", "clock", "compute", "console", "consoleApp", "controlsHorizontal", "controlsVertical", "copy", "copyClipboard", "createAdvancedJob", "createMultiMetricJob", "createPopulationJob", "createSingleMetricJob", "cross", "crossClusterReplicationApp", "crosshairs", "crossInACircleFilled", "cut", "dashboardApp", "database", "dataVisualizer", "devToolsApp", "discoverApp", "document", "dot", "editorAlignCenter", "editorAlignLeft", "editorAlignRight", "editorBold", "editorCodeBlock", "editorComment", "editorDistributeHorizontal", "editorDistributeVertical", "editorHeading", "editorItalic", "editorItemAlignLeft", "editorItemAlignBottom", "editorItemAlignCenter", "editorItemAlignMiddle", "editorItemAlignRight", "editorItemAlignTop", "editorLink", "editorOrderedList", "editorPositionBottomLeft", "editorPositionBottomRight", "editorPositionTopLeft", "editorPositionTopRight", "editorRedo", "editorStrike", "editorTable", "editorUnderline", "editorUndo", "editorUnorderedList", "email", "empty", "emsApp", "exit", "expand", "exportAction", "eye", "eyeClosed", "faceHappy", "faceNeutral", "faceSad", "filebeatApp", "filter", "flag", "folderClosed", "folderOpen", "fullScreen", "gear", "gisApp", "glasses", "globe", "grab", "grabHorizontal", "graphApp", "grid", "grokApp", "heart", "heartbeatApp", "heatmap", "help", "iInCircle", "importAction", "indexClose", "indexEdit", "indexFlush", "indexManagementApp", "indexMapping", "indexOpen", "indexPatternApp", "indexRollupApp", "indexSettings", "infraApp", "inputOutput", "inspect", "invert", "kqlField", "kqlFunction", "kqlOperand", "kqlSelector", "kqlValue", "link", "list", "listAdd", "lock", "lockOpen", "loggingApp", "logoAerospike", "logoApache", "logoAPM", "logoAppSearch", "logoAWS", "logoAWSMono", "logoAzure", "logoAzureMono", "logoBeats", "logoBusinessAnalytics", "logoCeph", "logoCloud", "logoCloudEnterprise", "logoCode", "logoCodesandbox", "logoCouchbase", "logoDocker", "logoDropwizard", "logoElastic", "logoElasticsearch", "logoElasticStack", "logoEnterpriseSearch", "logoEtcd", "logoGCP", "logoGCPMono", "logoGithub", "logoGmail", "logoGolang", "logoHAproxy", "logoIBM", "logoIBMMono", "logoKafka", "logoKibana", "logoKubernetes", "logoLogging", "logoLogstash", "logoMaps", "logoMemcached", "logoMetrics", "logoMongodb", "logoMySQL", "logoNginx", "logoOsquery", "logoPhp", "logoPostgres", "logoPrometheus", "logoRabbitmq", "logoRedis", "logoSecurity", "logoSiteSearch", "logoSketch", "logoSlack", "logoUptime", "logoWebhook", "logoWindows", "logstashFilter", "logstashIf", "logstashInput", "logstashOutput", "logstashQueue", "machineLearningApp", "magnet", "magnifyWithMinus", "magnifyWithPlus", "managementApp", "mapMarker", "memory", "menuLeft", "menuRight", "merge", "metricbeatApp", "minusInCircle", "minusInCircleFilled", "monitoringApp", "moon", "node", "notebookApp", "number", "offline", "online", "packetbeatApp", "pause", "pencil", "pin", "pinFilled", "pipelineApp", "play", "plusInCircle", "plusInCircleFilled", "popout", "questionInCircle", "refresh", "reportingApp", "save", "savedObjectsApp", "scale", "search", "searchProfilerApp", "securityAnalyticsApp", "securityApp", "shard", "share", "snowflake", "sortable", "sortDown", "sortLeft", "sortRight", "sortUp", "spacesApp", "sqlApp", "starEmpty", "starEmptySpace", "starFilled", "starFilledSpace", "starMinusEmpty", "starMinusFilled", "starPlusEmpty", "starPlusFilled", "stats", "stop", "stopFilled", "stopSlash", "storage", "string", "submodule", "swatchInput", "symlink", "tableOfContents", "tag", "tear", "temperature", "timelionApp", "trash", "upgradeAssistantApp", "uptimeApp", "user", "usersRolesApp", "vector", "visArea", "visBarHorizontal", "visBarVertical", "visControls", "visGauge", "visGoal", "visHeatmap", "visLine", "visMapCoordinate", "visMapRegion", "visMetric", "visPie", "visTable", "visTagCloud", "visText", "visTimelion", "visualizeApp", "visVega", "visVisualBuilder", "watchesApp", "wrench", "tokenClass", "tokenProperty", "tokenEnum", "tokenVariable", "tokenMethod", "tokenAnnotation", "tokenException", "tokenInterface", "tokenParameter", "tokenField", "tokenElement", "tokenFunction", "tokenBoolean", "tokenString", "tokenArray", "tokenNumber", "tokenConstant", "tokenObject", "tokenEvent", "tokenKey", "tokenNull", "tokenStruct", "tokenPackage", "tokenOperator", "tokenEnumMember", "tokenRepo", "tokenSymbol", "tokenFile", "tokenModule", "tokenNamespace"]).isRequired, _propTypes.default.string.isRequired, _propTypes.default.element.isRequired]),
|
|
83
|
+
iconType: _propTypes.default.oneOfType([_propTypes.default.oneOf(["addDataApp", "advancedSettingsApp", "alert", "apmApp", "apmTrace", "apps", "arrowDown", "arrowLeft", "arrowRight", "arrowUp", "asterisk", "auditbeatApp", "beaker", "bell", "bolt", "boxesHorizontal", "boxesVertical", "branch", "broom", "brush", "bug", "bullseye", "calendar", "canvasApp", "codeApp", "check", "checkInCircleFilled", "clock", "cloudDrizzle", "cloudStormy", "cloudSunny", "compute", "console", "consoleApp", "controlsHorizontal", "controlsVertical", "copy", "copyClipboard", "createAdvancedJob", "createMultiMetricJob", "createPopulationJob", "createSingleMetricJob", "cross", "crossClusterReplicationApp", "crosshairs", "crossInACircleFilled", "cut", "dashboardApp", "database", "dataVisualizer", "devToolsApp", "discoverApp", "document", "documentEdit", "documents", "dot", "editorAlignCenter", "editorAlignLeft", "editorAlignRight", "editorBold", "editorCodeBlock", "editorComment", "editorDistributeHorizontal", "editorDistributeVertical", "editorHeading", "editorItalic", "editorItemAlignLeft", "editorItemAlignBottom", "editorItemAlignCenter", "editorItemAlignMiddle", "editorItemAlignRight", "editorItemAlignTop", "editorLink", "editorOrderedList", "editorPositionBottomLeft", "editorPositionBottomRight", "editorPositionTopLeft", "editorPositionTopRight", "editorRedo", "editorStrike", "editorTable", "editorUnderline", "editorUndo", "editorUnorderedList", "email", "empty", "emsApp", "exit", "expand", "exportAction", "eye", "eyeClosed", "faceHappy", "faceNeutral", "faceSad", "filebeatApp", "filter", "flag", "folderClosed", "folderOpen", "fullScreen", "gear", "gisApp", "glasses", "globe", "grab", "grabHorizontal", "graphApp", "grid", "grokApp", "heart", "heartbeatApp", "heatmap", "help", "iInCircle", "importAction", "indexClose", "indexEdit", "indexFlush", "indexManagementApp", "indexMapping", "indexOpen", "indexPatternApp", "indexRollupApp", "indexSettings", "infraApp", "inputOutput", "inspect", "invert", "kqlField", "kqlFunction", "kqlOperand", "kqlSelector", "kqlValue", "link", "list", "listAdd", "lock", "lockOpen", "loggingApp", "logoAerospike", "logoApache", "logoAPM", "logoAppSearch", "logoAWS", "logoAWSMono", "logoAzure", "logoAzureMono", "logoBeats", "logoBusinessAnalytics", "logoCeph", "logoCloud", "logoCloudEnterprise", "logoCode", "logoCodesandbox", "logoCouchbase", "logoDocker", "logoDropwizard", "logoElastic", "logoElasticsearch", "logoElasticStack", "logoEnterpriseSearch", "logoEtcd", "logoGCP", "logoGCPMono", "logoGithub", "logoGmail", "logoGolang", "logoHAproxy", "logoIBM", "logoIBMMono", "logoKafka", "logoKibana", "logoKubernetes", "logoLogging", "logoLogstash", "logoMaps", "logoMemcached", "logoMetrics", "logoMongodb", "logoMySQL", "logoNginx", "logoOsquery", "logoPhp", "logoPostgres", "logoPrometheus", "logoRabbitmq", "logoRedis", "logoSecurity", "logoSiteSearch", "logoSketch", "logoSlack", "logoUptime", "logoWebhook", "logoWindows", "logstashFilter", "logstashIf", "logstashInput", "logstashOutput", "logstashQueue", "machineLearningApp", "magnet", "magnifyWithMinus", "magnifyWithPlus", "managementApp", "mapMarker", "memory", "menuLeft", "menuRight", "merge", "metricbeatApp", "minusInCircle", "minusInCircleFilled", "monitoringApp", "moon", "node", "notebookApp", "number", "offline", "online", "packetbeatApp", "pause", "pencil", "pin", "pinFilled", "pipelineApp", "play", "plusInCircle", "plusInCircleFilled", "popout", "questionInCircle", "refresh", "reportingApp", "save", "savedObjectsApp", "scale", "search", "searchProfilerApp", "securityAnalyticsApp", "securityApp", "shard", "share", "snowflake", "sortable", "sortDown", "sortLeft", "sortRight", "sortUp", "spacesApp", "sqlApp", "starEmpty", "starEmptySpace", "starFilled", "starFilledSpace", "starMinusEmpty", "starMinusFilled", "starPlusEmpty", "starPlusFilled", "stats", "stop", "stopFilled", "stopSlash", "storage", "string", "submodule", "swatchInput", "symlink", "tableOfContents", "tag", "tear", "temperature", "timelionApp", "training", "trash", "upgradeAssistantApp", "uptimeApp", "user", "usersRolesApp", "vector", "videoPlayer", "visArea", "visBarHorizontal", "visBarVertical", "visControls", "visGauge", "visGoal", "visHeatmap", "visLine", "visMapCoordinate", "visMapRegion", "visMetric", "visPie", "visTable", "visTagCloud", "visText", "visTimelion", "visualizeApp", "visVega", "visVisualBuilder", "watchesApp", "wrench", "tokenClass", "tokenProperty", "tokenEnum", "tokenVariable", "tokenMethod", "tokenAnnotation", "tokenException", "tokenInterface", "tokenParameter", "tokenField", "tokenElement", "tokenFunction", "tokenBoolean", "tokenString", "tokenArray", "tokenNumber", "tokenConstant", "tokenObject", "tokenEvent", "tokenKey", "tokenNull", "tokenStruct", "tokenPackage", "tokenOperator", "tokenEnumMember", "tokenRepo", "tokenSymbol", "tokenFile", "tokenModule", "tokenNamespace"]).isRequired, _propTypes.default.string.isRequired, _propTypes.default.element.isRequired]),
|
|
84
84
|
|
|
85
85
|
/**
|
|
86
86
|
* One word label like "Beta" or "Lab"
|
|
@@ -246,6 +246,15 @@ EuiBetaBadge.__docgenInfo = {
|
|
|
246
246
|
}, {
|
|
247
247
|
"value": "\"clock\"",
|
|
248
248
|
"computed": false
|
|
249
|
+
}, {
|
|
250
|
+
"value": "\"cloudDrizzle\"",
|
|
251
|
+
"computed": false
|
|
252
|
+
}, {
|
|
253
|
+
"value": "\"cloudStormy\"",
|
|
254
|
+
"computed": false
|
|
255
|
+
}, {
|
|
256
|
+
"value": "\"cloudSunny\"",
|
|
257
|
+
"computed": false
|
|
249
258
|
}, {
|
|
250
259
|
"value": "\"compute\"",
|
|
251
260
|
"computed": false
|
|
@@ -312,6 +321,12 @@ EuiBetaBadge.__docgenInfo = {
|
|
|
312
321
|
}, {
|
|
313
322
|
"value": "\"document\"",
|
|
314
323
|
"computed": false
|
|
324
|
+
}, {
|
|
325
|
+
"value": "\"documentEdit\"",
|
|
326
|
+
"computed": false
|
|
327
|
+
}, {
|
|
328
|
+
"value": "\"documents\"",
|
|
329
|
+
"computed": false
|
|
315
330
|
}, {
|
|
316
331
|
"value": "\"dot\"",
|
|
317
332
|
"computed": false
|
|
@@ -963,6 +978,9 @@ EuiBetaBadge.__docgenInfo = {
|
|
|
963
978
|
}, {
|
|
964
979
|
"value": "\"timelionApp\"",
|
|
965
980
|
"computed": false
|
|
981
|
+
}, {
|
|
982
|
+
"value": "\"training\"",
|
|
983
|
+
"computed": false
|
|
966
984
|
}, {
|
|
967
985
|
"value": "\"trash\"",
|
|
968
986
|
"computed": false
|
|
@@ -981,6 +999,9 @@ EuiBetaBadge.__docgenInfo = {
|
|
|
981
999
|
}, {
|
|
982
1000
|
"value": "\"vector\"",
|
|
983
1001
|
"computed": false
|
|
1002
|
+
}, {
|
|
1003
|
+
"value": "\"videoPlayer\"",
|
|
1004
|
+
"computed": false
|
|
984
1005
|
}, {
|
|
985
1006
|
"value": "\"visArea\"",
|
|
986
1007
|
"computed": false
|
|
@@ -93,6 +93,14 @@ function (_Component) {
|
|
|
93
93
|
});
|
|
94
94
|
});
|
|
95
95
|
|
|
96
|
+
_defineProperty(_assertThisInitialized(_assertThisInitialized(_this)), "closeListOnScroll", function (e) {
|
|
97
|
+
// close the list when a scroll event happens, but not if the scroll happened in the options list
|
|
98
|
+
// this mirrors Firefox's approach of auto-closing `select` elements onscroll
|
|
99
|
+
if (_this.list && _this.list.contains(e.target) === false) {
|
|
100
|
+
_this.props.onCloseList();
|
|
101
|
+
}
|
|
102
|
+
});
|
|
103
|
+
|
|
96
104
|
_defineProperty(_assertThisInitialized(_assertThisInitialized(_this)), "listRef", function (node) {
|
|
97
105
|
_this.props.listRef(node);
|
|
98
106
|
|
|
@@ -105,13 +113,25 @@ function (_Component) {
|
|
|
105
113
|
_createClass(EuiComboBoxOptionsList, [{
|
|
106
114
|
key: "componentDidMount",
|
|
107
115
|
value: function componentDidMount() {
|
|
116
|
+
var _this2 = this;
|
|
117
|
+
|
|
108
118
|
// Wait a frame, otherwise moving focus from one combo box to another will result in the class
|
|
109
119
|
// being removed from the body.
|
|
110
120
|
requestAnimationFrame(function () {
|
|
111
121
|
document.body.classList.add('euiBody-hasPortalContent');
|
|
112
122
|
});
|
|
113
123
|
this.updatePosition();
|
|
114
|
-
window.addEventListener('resize', this.updatePosition);
|
|
124
|
+
window.addEventListener('resize', this.updatePosition); // Firefox will trigger a scroll event in many common situations when the options list div is appended
|
|
125
|
+
// to the DOM; in testing it was always within 100ms, but setting a timeout here for 500ms to be safe
|
|
126
|
+
|
|
127
|
+
setTimeout(function () {
|
|
128
|
+
window.addEventListener('scroll', _this2.closeListOnScroll, {
|
|
129
|
+
passive: true,
|
|
130
|
+
// for better performance as we won't call preventDefault
|
|
131
|
+
capture: true // scroll events don't bubble, they must be captured instead
|
|
132
|
+
|
|
133
|
+
});
|
|
134
|
+
}, 500);
|
|
115
135
|
}
|
|
116
136
|
}, {
|
|
117
137
|
key: "componentDidUpdate",
|
|
@@ -129,11 +149,15 @@ function (_Component) {
|
|
|
129
149
|
value: function componentWillUnmount() {
|
|
130
150
|
document.body.classList.remove('euiBody-hasPortalContent');
|
|
131
151
|
window.removeEventListener('resize', this.updatePosition);
|
|
152
|
+
window.removeEventListener('scroll', this.closeListOnScroll, {
|
|
153
|
+
passive: true,
|
|
154
|
+
capture: true
|
|
155
|
+
});
|
|
132
156
|
}
|
|
133
157
|
}, {
|
|
134
158
|
key: "render",
|
|
135
159
|
value: function render() {
|
|
136
|
-
var
|
|
160
|
+
var _this3 = this;
|
|
137
161
|
|
|
138
162
|
var _this$props = this.props,
|
|
139
163
|
options = _this$props.options,
|
|
@@ -159,7 +183,8 @@ function (_Component) {
|
|
|
159
183
|
dataTestSubj = _this$props['data-test-subj'],
|
|
160
184
|
activeOptionIndex = _this$props.activeOptionIndex,
|
|
161
185
|
rootId = _this$props.rootId,
|
|
162
|
-
|
|
186
|
+
onCloseList = _this$props.onCloseList,
|
|
187
|
+
rest = _objectWithoutProperties(_this$props, ["options", "isLoading", "selectedOptions", "onCreateOption", "searchValue", "matchingOptions", "optionRef", "onOptionClick", "onOptionEnterKey", "areAllOptionsSelected", "getSelectedOptionForSearchValue", "position", "renderOption", "listRef", "updatePosition", "width", "scrollToIndex", "onScroll", "rowHeight", "fullWidth", "data-test-subj", "activeOptionIndex", "rootId", "onCloseList"]);
|
|
163
188
|
|
|
164
189
|
var emptyStateContent;
|
|
165
190
|
|
|
@@ -262,7 +287,7 @@ function (_Component) {
|
|
|
262
287
|
return onOptionClick(option);
|
|
263
288
|
} // onEnterKey={onOptionEnterKey}
|
|
264
289
|
,
|
|
265
|
-
ref: optionRef.bind(
|
|
290
|
+
ref: optionRef.bind(_this3, index),
|
|
266
291
|
isFocused: activeOptionIndex === index,
|
|
267
292
|
id: rootId("_option-".concat(index)),
|
|
268
293
|
title: label,
|
|
@@ -315,7 +340,8 @@ _defineProperty(EuiComboBoxOptionsList, "propTypes", {
|
|
|
315
340
|
rowHeight: _propTypes.default.number,
|
|
316
341
|
fullWidth: _propTypes.default.bool,
|
|
317
342
|
activeOptionIndex: _propTypes.default.number,
|
|
318
|
-
rootId: _propTypes.default.func.isRequired
|
|
343
|
+
rootId: _propTypes.default.func.isRequired,
|
|
344
|
+
onCloseList: _propTypes.default.func.isRequired
|
|
319
345
|
});
|
|
320
346
|
|
|
321
347
|
_defineProperty(EuiComboBoxOptionsList, "defaultProps", {
|
|
@@ -332,6 +358,15 @@ EuiComboBoxOptionsList.__docgenInfo = {
|
|
|
332
358
|
"modifiers": [],
|
|
333
359
|
"params": [],
|
|
334
360
|
"returns": null
|
|
361
|
+
}, {
|
|
362
|
+
"name": "closeListOnScroll",
|
|
363
|
+
"docblock": null,
|
|
364
|
+
"modifiers": [],
|
|
365
|
+
"params": [{
|
|
366
|
+
"name": "e",
|
|
367
|
+
"type": null
|
|
368
|
+
}],
|
|
369
|
+
"returns": null
|
|
335
370
|
}, {
|
|
336
371
|
"name": "listRef",
|
|
337
372
|
"docblock": null,
|
|
@@ -515,6 +550,13 @@ EuiComboBoxOptionsList.__docgenInfo = {
|
|
|
515
550
|
},
|
|
516
551
|
"required": true,
|
|
517
552
|
"description": ""
|
|
553
|
+
},
|
|
554
|
+
"onCloseList": {
|
|
555
|
+
"type": {
|
|
556
|
+
"name": "func"
|
|
557
|
+
},
|
|
558
|
+
"required": true,
|
|
559
|
+
"description": ""
|
|
518
560
|
}
|
|
519
561
|
}
|
|
520
562
|
};
|