@elastic/eui 65.0.2 → 66.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/eui_theme_dark.css +24 -196
- package/dist/eui_theme_dark.min.css +1 -1
- package/dist/eui_theme_light.css +24 -196
- package/dist/eui_theme_light.min.css +1 -1
- package/es/components/basic_table/basic_table.js +13 -2
- package/es/components/basic_table/in_memory_table.js +13 -2
- package/es/components/card/card.styles.js +2 -2
- package/es/components/combo_box/combo_box.js +2 -15
- package/es/components/datagrid/body/data_grid_body.js +17 -6
- package/es/components/datagrid/body/data_grid_cell.js +29 -12
- package/es/components/datagrid/body/header/data_grid_header_cell.js +17 -6
- package/es/components/datagrid/body/header/data_grid_header_row.js +17 -6
- package/es/components/datagrid/data_grid.js +17 -6
- package/es/components/datagrid/utils/in_memory.js +17 -6
- package/es/components/description_list/description_list.js +11 -3
- package/es/components/description_list/description_list_context.js +2 -1
- package/es/components/description_list/description_list_description.js +3 -1
- package/es/components/description_list/description_list_description.styles.js +5 -2
- package/es/components/description_list/description_list_title.js +3 -2
- package/es/components/description_list/description_list_title.styles.js +7 -3
- package/es/components/description_list/description_list_types.js +2 -1
- package/es/components/form/field_search/field_search.js +6 -16
- package/es/components/form/range/range_input.js +1 -1
- package/es/components/header/header_section/header_section_item.js +4 -3
- package/es/components/icon/icon.js +1 -9
- package/es/components/list_group/list_group.js +7 -1
- package/es/components/list_group/list_group_item.js +10 -3
- package/es/components/list_group/pinnable_list_group/pinnable_list_group.js +13 -1
- package/es/components/modal/modal.js +1 -3
- package/es/components/observer/mutation_observer/mutation_observer.js +1 -1
- package/es/components/page/page_sidebar/page_sidebar.js +5 -1
- package/es/components/table/table_row_cell.js +4 -6
- package/es/components/tabs/tabbed_content/tabbed_content.js +2 -19
- package/es/global_styling/mixins/_typography.js +1 -1
- package/es/services/theme/hooks.js +11 -16
- package/eui.d.ts +29 -10
- package/i18ntokens.json +18 -18
- package/lib/components/basic_table/basic_table.js +13 -2
- package/lib/components/basic_table/in_memory_table.js +13 -2
- package/lib/components/card/card.styles.js +2 -2
- package/lib/components/combo_box/combo_box.js +2 -15
- package/lib/components/datagrid/body/data_grid_body.js +17 -6
- package/lib/components/datagrid/body/data_grid_cell.js +29 -12
- package/lib/components/datagrid/body/header/data_grid_header_cell.js +17 -6
- package/lib/components/datagrid/body/header/data_grid_header_row.js +17 -6
- package/lib/components/datagrid/data_grid.js +17 -6
- package/lib/components/datagrid/utils/in_memory.js +17 -6
- package/lib/components/description_list/description_list.js +11 -3
- package/lib/components/description_list/description_list_context.js +2 -1
- package/lib/components/description_list/description_list_description.js +3 -1
- package/lib/components/description_list/description_list_description.styles.js +5 -2
- package/lib/components/description_list/description_list_title.js +3 -2
- package/lib/components/description_list/description_list_title.styles.js +7 -3
- package/lib/components/description_list/description_list_types.js +4 -2
- package/lib/components/form/field_search/field_search.js +6 -16
- package/lib/components/form/range/range_input.js +1 -1
- package/lib/components/header/header_section/header_section_item.js +4 -3
- package/lib/components/icon/icon.js +1 -9
- package/lib/components/list_group/list_group.js +7 -1
- package/lib/components/list_group/list_group_item.js +10 -3
- package/lib/components/list_group/pinnable_list_group/pinnable_list_group.js +13 -1
- package/lib/components/modal/modal.js +1 -3
- package/lib/components/observer/mutation_observer/mutation_observer.js +1 -1
- package/lib/components/page/page_sidebar/page_sidebar.js +5 -1
- package/lib/components/table/table_row_cell.js +4 -6
- package/lib/components/tabs/tabbed_content/tabbed_content.js +2 -19
- package/lib/global_styling/mixins/_typography.js +1 -1
- package/lib/services/theme/hooks.js +10 -15
- package/optimize/es/components/card/card.styles.js +2 -2
- package/optimize/es/components/combo_box/combo_box.js +2 -15
- package/optimize/es/components/description_list/description_list.js +5 -2
- package/optimize/es/components/description_list/description_list_context.js +2 -1
- package/optimize/es/components/description_list/description_list_description.js +3 -1
- package/optimize/es/components/description_list/description_list_description.styles.js +5 -2
- package/optimize/es/components/description_list/description_list_title.js +3 -2
- package/optimize/es/components/description_list/description_list_title.styles.js +7 -3
- package/optimize/es/components/description_list/description_list_types.js +2 -1
- package/optimize/es/components/form/field_search/field_search.js +6 -16
- package/optimize/es/components/form/range/range_input.js +1 -1
- package/optimize/es/components/header/header_section/header_section_item.js +4 -3
- package/optimize/es/components/icon/icon.js +1 -9
- package/optimize/es/components/list_group/list_group_item.js +3 -2
- package/optimize/es/components/modal/modal.js +1 -3
- package/optimize/es/components/observer/mutation_observer/mutation_observer.js +1 -1
- package/optimize/es/components/page/page_sidebar/page_sidebar.js +5 -1
- package/optimize/es/components/tabs/tabbed_content/tabbed_content.js +2 -19
- package/optimize/es/global_styling/mixins/_typography.js +1 -1
- package/optimize/es/services/theme/hooks.js +11 -16
- package/optimize/lib/components/card/card.styles.js +2 -2
- package/optimize/lib/components/combo_box/combo_box.js +2 -15
- package/optimize/lib/components/description_list/description_list.js +5 -2
- package/optimize/lib/components/description_list/description_list_context.js +2 -1
- package/optimize/lib/components/description_list/description_list_description.js +3 -1
- package/optimize/lib/components/description_list/description_list_description.styles.js +5 -2
- package/optimize/lib/components/description_list/description_list_title.js +3 -2
- package/optimize/lib/components/description_list/description_list_title.styles.js +7 -3
- package/optimize/lib/components/description_list/description_list_types.js +4 -2
- package/optimize/lib/components/form/field_search/field_search.js +6 -16
- package/optimize/lib/components/form/range/range_input.js +1 -1
- package/optimize/lib/components/header/header_section/header_section_item.js +4 -3
- package/optimize/lib/components/icon/icon.js +1 -9
- package/optimize/lib/components/list_group/list_group_item.js +3 -2
- package/optimize/lib/components/modal/modal.js +1 -3
- package/optimize/lib/components/observer/mutation_observer/mutation_observer.js +1 -1
- package/optimize/lib/components/page/page_sidebar/page_sidebar.js +5 -1
- package/optimize/lib/components/tabs/tabbed_content/tabbed_content.js +2 -19
- package/optimize/lib/global_styling/mixins/_typography.js +1 -1
- package/optimize/lib/services/theme/hooks.js +10 -15
- package/package.json +1 -1
- package/src/components/badge/_badge.scss +0 -5
- package/src/components/datagrid/body/header/_data_grid_header_row.scss +1 -1
- package/src/components/filter_group/_filter_group.scss +3 -1
- package/src/components/flex/_flex_group.scss +2 -11
- package/src/components/flex/_flex_item.scss +0 -6
- package/src/components/form/field_search/_field_search.scss +0 -5
- package/src/components/form/form_control_layout/_form_control_layout_delimited.scss +0 -3
- package/src/components/form/form_row/_form_row.scss +0 -1
- package/src/components/header/header_section/_header_section_item.scss +1 -1
- package/src/components/list_group/_list_group_item.scss +3 -25
- package/src/components/modal/_modal.scss +5 -20
- package/src/components/page/page_content/_page_content.scss +0 -1
- package/src/components/table/_responsive.scss +0 -1
- package/src/components/table/_table.scss +0 -5
- package/src/global_styling/mixins/_form.scss +0 -4
- package/src/global_styling/mixins/_helpers.scss +0 -8
- package/src/global_styling/mixins/_typography.scss +1 -5
- package/src/global_styling/utility/_index.scss +0 -1
- package/test-env/components/basic_table/basic_table.js +13 -2
- package/test-env/components/basic_table/in_memory_table.js +13 -2
- package/test-env/components/card/card.styles.js +2 -2
- package/test-env/components/combo_box/combo_box.js +2 -15
- package/test-env/components/datagrid/body/data_grid_body.js +17 -6
- package/test-env/components/datagrid/body/data_grid_cell.js +29 -12
- package/test-env/components/datagrid/body/header/data_grid_header_cell.js +17 -6
- package/test-env/components/datagrid/body/header/data_grid_header_row.js +17 -6
- package/test-env/components/datagrid/data_grid.js +17 -6
- package/test-env/components/datagrid/utils/in_memory.js +17 -6
- package/test-env/components/description_list/description_list.js +11 -3
- package/test-env/components/description_list/description_list_context.js +2 -1
- package/test-env/components/description_list/description_list_description.js +3 -1
- package/test-env/components/description_list/description_list_description.styles.js +5 -2
- package/test-env/components/description_list/description_list_title.js +3 -2
- package/test-env/components/description_list/description_list_title.styles.js +7 -3
- package/test-env/components/description_list/description_list_types.js +4 -2
- package/test-env/components/form/field_search/field_search.js +6 -16
- package/test-env/components/form/range/range_input.js +1 -1
- package/test-env/components/header/header_section/header_section_item.js +4 -3
- package/test-env/components/list_group/list_group.js +7 -1
- package/test-env/components/list_group/list_group_item.js +10 -3
- package/test-env/components/list_group/pinnable_list_group/pinnable_list_group.js +13 -1
- package/test-env/components/modal/modal.js +1 -3
- package/test-env/components/observer/mutation_observer/mutation_observer.js +1 -1
- package/test-env/components/page/page_sidebar/page_sidebar.js +5 -1
- package/test-env/components/table/table_row_cell.js +4 -6
- package/test-env/components/tabs/tabbed_content/tabbed_content.js +2 -19
- package/test-env/global_styling/mixins/_typography.js +1 -1
- package/test-env/services/theme/hooks.js +10 -15
- package/src/global_styling/utility/_utility.scss +0 -15
|
@@ -12,9 +12,9 @@ import { euiTitle } from '../title/title.styles';
|
|
|
12
12
|
export var euiDescriptionListTitleStyles = function euiDescriptionListTitleStyles(euiThemeContext) {
|
|
13
13
|
var euiTheme = euiThemeContext.euiTheme,
|
|
14
14
|
colorMode = euiThemeContext.colorMode;
|
|
15
|
-
var columnDisplay = "\n
|
|
15
|
+
var columnDisplay = "\n ".concat(logicalCSS('width', '50%'), "\n ").concat(logicalCSS('padding-right', euiTheme.size.s), "\n ");
|
|
16
16
|
return {
|
|
17
|
-
euiDescriptionList__title: /*#__PURE__*/css(euiTextBreakWord(), "
|
|
17
|
+
euiDescriptionList__title: /*#__PURE__*/css(euiTextBreakWord(), ";;label:euiDescriptionList__title;"),
|
|
18
18
|
// Types
|
|
19
19
|
row: /*#__PURE__*/css(";label:row;"),
|
|
20
20
|
column: /*#__PURE__*/css(columnDisplay, ";;label:column;"),
|
|
@@ -32,6 +32,10 @@ export var euiDescriptionListTitleStyles = function euiDescriptionListTitleStyle
|
|
|
32
32
|
compressed: /*#__PURE__*/css(euiFontSize(euiThemeContext, 'xs'), ";", logicalCSS('padding-vertical', '0'), " ", logicalCSS('padding-horizontal', euiTheme.size.xs), ";;label:compressed;")
|
|
33
33
|
},
|
|
34
34
|
// Alignment
|
|
35
|
-
right: /*#__PURE__*/css(logicalTextAlignCSS('right'), ";;label:right;")
|
|
35
|
+
right: /*#__PURE__*/css(logicalTextAlignCSS('right'), ";;label:right;"),
|
|
36
|
+
// Gutter
|
|
37
|
+
// Add margin only to the non-first <dt>.
|
|
38
|
+
s: /*#__PURE__*/css("&:not(:first-of-type){", logicalCSS('margin-top', euiTheme.size.s), ";};label:s;"),
|
|
39
|
+
m: /*#__PURE__*/css("&:not(:first-of-type){", logicalCSS('margin-top', euiTheme.size.base), ";};label:m;")
|
|
36
40
|
};
|
|
37
41
|
};
|
|
@@ -86,26 +86,16 @@ export var EuiFieldSearch = /*#__PURE__*/function (_Component) {
|
|
|
86
86
|
|
|
87
87
|
if (nativeInputValueSetter) {
|
|
88
88
|
nativeInputValueSetter.call(_this.inputElement, '');
|
|
89
|
-
} // dispatch input event
|
|
89
|
+
} // dispatch input event
|
|
90
90
|
|
|
91
91
|
|
|
92
|
-
var event
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
bubbles: true,
|
|
97
|
-
cancelable: false
|
|
98
|
-
});
|
|
99
|
-
} else {
|
|
100
|
-
// IE11
|
|
101
|
-
event = document.createEvent('Event');
|
|
102
|
-
event.initEvent('input', true, false);
|
|
103
|
-
}
|
|
92
|
+
var event = new Event('input', {
|
|
93
|
+
bubbles: true,
|
|
94
|
+
cancelable: false
|
|
95
|
+
});
|
|
104
96
|
|
|
105
97
|
if (_this.inputElement) {
|
|
106
|
-
|
|
107
|
-
_this.inputElement.dispatchEvent(event);
|
|
108
|
-
} // set focus on the search field
|
|
98
|
+
_this.inputElement.dispatchEvent(event); // set focus on the search field
|
|
109
99
|
|
|
110
100
|
|
|
111
101
|
_this.inputElement.focus();
|
|
@@ -34,7 +34,7 @@ export var EuiRangeInput = function EuiRangeInput(_ref) {
|
|
|
34
34
|
autoSize = _ref$autoSize === void 0 ? true : _ref$autoSize,
|
|
35
35
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
36
36
|
|
|
37
|
-
// Chrome will properly size the input based on the max value, but FF
|
|
37
|
+
// Chrome will properly size the input based on the max value, but FF does not.
|
|
38
38
|
// Calculate the width of the input based on highest number of characters.
|
|
39
39
|
// Add 2 to accommodate for input stepper
|
|
40
40
|
var widthStyle = autoSize ? {
|
|
@@ -29,10 +29,11 @@ export var EuiHeaderSectionItem = function EuiHeaderSectionItem(_ref) {
|
|
|
29
29
|
className = _ref.className,
|
|
30
30
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
31
31
|
|
|
32
|
-
var classes = classNames('euiHeaderSectionItem', borderToClassNameMap[border], className);
|
|
33
|
-
|
|
32
|
+
var classes = classNames('euiHeaderSectionItem', borderToClassNameMap[border], className); // we check if there is any children and if not, we don't render anything
|
|
33
|
+
|
|
34
|
+
return children ? ___EmotionJSX("div", _extends({
|
|
34
35
|
className: classes
|
|
35
|
-
}, rest), children);
|
|
36
|
+
}, rest), children) : null;
|
|
36
37
|
};
|
|
37
38
|
EuiHeaderSectionItem.propTypes = {
|
|
38
39
|
className: PropTypes.string,
|
|
@@ -249,14 +249,7 @@ export var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
249
249
|
|
|
250
250
|
var styles = euiIconStyles(theme);
|
|
251
251
|
var cssStyles = [styles.euiIcon, styles[size], color && isNamedColor(color) && styles[color], isCustomColor && styles.customColor, isElasticLogoOutline && styles.logoElasticOutline, isAppIcon && !appIconHasColor && styles.app, isLoading && styles.isLoading, !isLoading && neededLoading && styles.isLoaded];
|
|
252
|
-
var icon = this.state.icon || empty;
|
|
253
|
-
// focusable="false".
|
|
254
|
-
// - If there's no tabindex specified, we'll default the icon to not be focusable,
|
|
255
|
-
// which is how SVGs behave in Chrome, Safari, and FF.
|
|
256
|
-
// - If tabindex is -1, then the consumer wants the icon to be focusable by JavaScript only.
|
|
257
|
-
// - If the tabindex is 0, the consumer wants the icon to be keyboard focusable.
|
|
258
|
-
|
|
259
|
-
var focusable = tabIndex == null || tabIndex === -1 ? 'false' : 'true';
|
|
252
|
+
var icon = this.state.icon || empty;
|
|
260
253
|
|
|
261
254
|
if (typeof icon === 'string') {
|
|
262
255
|
return ___EmotionJSX("img", _extends({
|
|
@@ -288,7 +281,6 @@ export var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
288
281
|
style: optionalCustomStyles,
|
|
289
282
|
css: cssStyles,
|
|
290
283
|
tabIndex: tabIndex,
|
|
291
|
-
focusable: focusable,
|
|
292
284
|
role: "img",
|
|
293
285
|
title: title,
|
|
294
286
|
"data-icon-type": iconTitle,
|
|
@@ -262,7 +262,13 @@ EuiListGroup.propTypes = {
|
|
|
262
262
|
* Pass-through ref reference specifically for targeting
|
|
263
263
|
* instances where the item content is rendered as a `button`
|
|
264
264
|
*/
|
|
265
|
-
buttonRef: PropTypes.any
|
|
265
|
+
buttonRef: PropTypes.any,
|
|
266
|
+
|
|
267
|
+
/**
|
|
268
|
+
* Text to be displayed in the tooltip when `showToolTip` is true.
|
|
269
|
+
* By default the text will be same as the label text.
|
|
270
|
+
*/
|
|
271
|
+
toolTipText: PropTypes.string
|
|
266
272
|
}).isRequired),
|
|
267
273
|
|
|
268
274
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _excluded = ["label", "isActive", "isDisabled", "href", "target", "rel", "className", "iconType", "icon", "iconProps", "extraAction", "onClick", "size", "color", "showToolTip", "wrapText", "buttonRef"],
|
|
1
|
+
var _excluded = ["label", "isActive", "isDisabled", "href", "target", "rel", "className", "iconType", "icon", "iconProps", "extraAction", "onClick", "size", "color", "showToolTip", "wrapText", "buttonRef", "toolTipText"],
|
|
2
2
|
_excluded2 = ["iconType", "alwaysShow", "className", "isDisabled"];
|
|
3
3
|
|
|
4
4
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
@@ -74,6 +74,7 @@ export var EuiListGroupItem = function EuiListGroupItem(_ref) {
|
|
|
74
74
|
showToolTip = _ref$showToolTip === void 0 ? false : _ref$showToolTip,
|
|
75
75
|
wrapText = _ref.wrapText,
|
|
76
76
|
buttonRef = _ref.buttonRef,
|
|
77
|
+
toolTipText = _ref.toolTipText,
|
|
77
78
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
78
79
|
|
|
79
80
|
var isHrefValid = !href || validateHref(href);
|
|
@@ -175,7 +176,7 @@ export var EuiListGroupItem = function EuiListGroupItem(_ref) {
|
|
|
175
176
|
className: classes
|
|
176
177
|
}, ___EmotionJSX(EuiToolTip, {
|
|
177
178
|
anchorClassName: "euiListGroupItem__tooltip",
|
|
178
|
-
content: label,
|
|
179
|
+
content: toolTipText !== null && toolTipText !== void 0 ? toolTipText : label,
|
|
179
180
|
position: "right",
|
|
180
181
|
delay: "long"
|
|
181
182
|
}, itemContent));
|
|
@@ -318,5 +319,11 @@ EuiListGroupItem.propTypes = {
|
|
|
318
319
|
* Pass-through ref reference specifically for targeting
|
|
319
320
|
* instances where the item content is rendered as a `button`
|
|
320
321
|
*/
|
|
321
|
-
buttonRef: PropTypes.any
|
|
322
|
+
buttonRef: PropTypes.any,
|
|
323
|
+
|
|
324
|
+
/**
|
|
325
|
+
* Text to be displayed in the tooltip when `showToolTip` is true.
|
|
326
|
+
* By default the text will be same as the label text.
|
|
327
|
+
*/
|
|
328
|
+
toolTipText: PropTypes.string
|
|
322
329
|
};
|
|
@@ -252,6 +252,12 @@ EuiPinnableListGroup.propTypes = {
|
|
|
252
252
|
*/
|
|
253
253
|
buttonRef: PropTypes.any,
|
|
254
254
|
|
|
255
|
+
/**
|
|
256
|
+
* Text to be displayed in the tooltip when `showToolTip` is true.
|
|
257
|
+
* By default the text will be same as the label text.
|
|
258
|
+
*/
|
|
259
|
+
toolTipText: PropTypes.string,
|
|
260
|
+
|
|
255
261
|
/**
|
|
256
262
|
* Saves the pinned status and changes the visibility of the pin icon
|
|
257
263
|
*/
|
|
@@ -362,7 +368,13 @@ EuiPinnableListGroup.propTypes = {
|
|
|
362
368
|
* Pass-through ref reference specifically for targeting
|
|
363
369
|
* instances where the item content is rendered as a `button`
|
|
364
370
|
*/
|
|
365
|
-
buttonRef: PropTypes.any
|
|
371
|
+
buttonRef: PropTypes.any,
|
|
372
|
+
|
|
373
|
+
/**
|
|
374
|
+
* Text to be displayed in the tooltip when `showToolTip` is true.
|
|
375
|
+
* By default the text will be same as the label text.
|
|
376
|
+
*/
|
|
377
|
+
toolTipText: PropTypes.string
|
|
366
378
|
}).isRequired)]),
|
|
367
379
|
|
|
368
380
|
/**
|
|
@@ -77,9 +77,7 @@ export var EuiModal = function EuiModal(_ref) {
|
|
|
77
77
|
color: "text",
|
|
78
78
|
"aria-label": closeModal
|
|
79
79
|
});
|
|
80
|
-
}),
|
|
81
|
-
className: "euiModal__flex"
|
|
82
|
-
}, children))));
|
|
80
|
+
}), children)));
|
|
83
81
|
};
|
|
84
82
|
EuiModal.propTypes = {
|
|
85
83
|
className: PropTypes.string,
|
|
@@ -65,7 +65,7 @@ export var EuiMutationObserver = /*#__PURE__*/function (_EuiObserver) {
|
|
|
65
65
|
}(EuiObserver);
|
|
66
66
|
|
|
67
67
|
var makeMutationObserver = function makeMutationObserver(node, _observerOptions, callback) {
|
|
68
|
-
//
|
|
68
|
+
// The MutationObserver polyfill used in Kibana (for Jest) implements
|
|
69
69
|
// an older spec in which specifying `attributeOldValue` or `attributeFilter`
|
|
70
70
|
// without specifying `attributes` results in a `SyntaxError`.
|
|
71
71
|
// The following logic patches the newer spec in which `attributes: true` can be
|
|
@@ -64,13 +64,17 @@ export var EuiPageSidebar = function EuiPageSidebar(_ref) {
|
|
|
64
64
|
setInlineStyles = _useState2[1];
|
|
65
65
|
|
|
66
66
|
useEffect(function () {
|
|
67
|
+
var updatedStyles = _objectSpread(_objectSpread({}, style), logicalStyle('min-width', isResponding ? '100%' : minWidth));
|
|
68
|
+
|
|
67
69
|
if (sticky) {
|
|
68
70
|
var _document$body$datase;
|
|
69
71
|
|
|
70
72
|
var euiHeaderFixedCounter = Number((_document$body$datase = document.body.dataset.fixedHeaders) !== null && _document$body$datase !== void 0 ? _document$body$datase : 0);
|
|
71
73
|
var offset = _typeof(sticky) === 'object' ? sticky === null || sticky === void 0 ? void 0 : sticky.offset : themeContext.euiTheme.base * 3 * euiHeaderFixedCounter;
|
|
72
|
-
|
|
74
|
+
updatedStyles = _objectSpread(_objectSpread(_objectSpread({}, updatedStyles), logicalStyle('top', offset)), logicalStyle('max-height', "calc(100vh - ".concat(offset, "px)")));
|
|
73
75
|
}
|
|
76
|
+
|
|
77
|
+
setInlineStyles(updatedStyles);
|
|
74
78
|
}, [style, sticky, themeContext.euiTheme.base, isResponding, minWidth]);
|
|
75
79
|
return ___EmotionJSX("div", _extends({
|
|
76
80
|
className: className,
|
|
@@ -203,9 +203,8 @@ EuiTableRowCell.propTypes = {
|
|
|
203
203
|
showOnHover: PropTypes.bool,
|
|
204
204
|
|
|
205
205
|
/**
|
|
206
|
-
*
|
|
207
|
-
*
|
|
208
|
-
* `.eui-textBreakWord`.
|
|
206
|
+
* Creates a text wrapper around cell content that helps word break or truncate
|
|
207
|
+
* long text correctly.
|
|
209
208
|
*/
|
|
210
209
|
textOnly: PropTypes.bool,
|
|
211
210
|
|
|
@@ -226,9 +225,8 @@ EuiTableRowCell.propTypes = {
|
|
|
226
225
|
showOnHover: PropTypes.bool,
|
|
227
226
|
|
|
228
227
|
/**
|
|
229
|
-
*
|
|
230
|
-
*
|
|
231
|
-
* `.eui-textBreakWord`.
|
|
228
|
+
* Creates a text wrapper around cell content that helps word break or truncate
|
|
229
|
+
* long text correctly.
|
|
232
230
|
*/
|
|
233
231
|
textOnly: PropTypes.bool,
|
|
234
232
|
|
|
@@ -136,24 +136,6 @@ export var EuiTabbedContent = /*#__PURE__*/function (_Component) {
|
|
|
136
136
|
}
|
|
137
137
|
|
|
138
138
|
_createClass(EuiTabbedContent, [{
|
|
139
|
-
key: "componentDidMount",
|
|
140
|
-
value: function componentDidMount() {
|
|
141
|
-
// IE11 doesn't support the `relatedTarget` event property for blur events
|
|
142
|
-
// but does add it for focusout. React doesn't support `onFocusOut` so here we are.
|
|
143
|
-
if (this.tabsRef.current) {
|
|
144
|
-
// Current short-term solution for event listener (see https://github.com/elastic/eui/pull/2717)
|
|
145
|
-
this.tabsRef.current.addEventListener('focusout', this.removeFocus);
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
}, {
|
|
149
|
-
key: "componentWillUnmount",
|
|
150
|
-
value: function componentWillUnmount() {
|
|
151
|
-
if (this.tabsRef.current) {
|
|
152
|
-
// Current short-term solution for event listener (see https://github.com/elastic/eui/pull/2717)
|
|
153
|
-
this.tabsRef.current.removeEventListener('focusout', this.removeFocus);
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
}, {
|
|
157
139
|
key: "render",
|
|
158
140
|
value: function render() {
|
|
159
141
|
var _this2 = this;
|
|
@@ -182,7 +164,8 @@ export var EuiTabbedContent = /*#__PURE__*/function (_Component) {
|
|
|
182
164
|
ref: this.tabsRef,
|
|
183
165
|
expand: expand,
|
|
184
166
|
size: size,
|
|
185
|
-
onFocus: this.initializeFocus
|
|
167
|
+
onFocus: this.initializeFocus,
|
|
168
|
+
onBlur: this.removeFocus
|
|
186
169
|
}, tabs.map(function (tab) {
|
|
187
170
|
var id = tab.id,
|
|
188
171
|
name = tab.name,
|
|
@@ -29,7 +29,7 @@ export var useEuiFontSize = function useEuiFontSize(scale, options) {
|
|
|
29
29
|
*/
|
|
30
30
|
|
|
31
31
|
export var euiTextBreakWord = function euiTextBreakWord() {
|
|
32
|
-
return "\n overflow-wrap: break-word !important; // makes sure the long string will wrap and not bust out of the container\n word-
|
|
32
|
+
return "\n overflow-wrap: break-word !important; // makes sure the long string will wrap and not bust out of the container\n word-break: break-word;\n";
|
|
33
33
|
};
|
|
34
34
|
/**
|
|
35
35
|
* Prevent text from wrapping onto multiple lines, and truncate with an ellipsis.
|
|
@@ -7,18 +7,21 @@ function _extends() { _extends = Object.assign || function (target) { for (var i
|
|
|
7
7
|
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
8
8
|
* Side Public License, v 1.
|
|
9
9
|
*/
|
|
10
|
-
import React, { forwardRef, useContext } from 'react';
|
|
10
|
+
import React, { forwardRef, useContext, useMemo } from 'react';
|
|
11
11
|
import { EuiThemeContext, EuiModificationsContext, EuiColorModeContext } from './context';
|
|
12
12
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
13
13
|
export var useEuiTheme = function useEuiTheme() {
|
|
14
14
|
var theme = useContext(EuiThemeContext);
|
|
15
15
|
var colorMode = useContext(EuiColorModeContext);
|
|
16
16
|
var modifications = useContext(EuiModificationsContext);
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
17
|
+
var assembledTheme = useMemo(function () {
|
|
18
|
+
return {
|
|
19
|
+
euiTheme: theme,
|
|
20
|
+
colorMode: colorMode,
|
|
21
|
+
modifications: modifications
|
|
22
|
+
};
|
|
23
|
+
}, [theme, colorMode, modifications]);
|
|
24
|
+
return assembledTheme;
|
|
22
25
|
};
|
|
23
26
|
// Provide the component props interface as the generic to allow the docs props table to populate.
|
|
24
27
|
// e.g., `const EuiComponent = withEuiTheme<EuiComponentProps>(_EuiComponent)`
|
|
@@ -26,17 +29,9 @@ export var withEuiTheme = function withEuiTheme(Component) {
|
|
|
26
29
|
var componentName = Component.displayName || Component.name || 'ComponentWithTheme';
|
|
27
30
|
|
|
28
31
|
var Render = function Render(props, ref) {
|
|
29
|
-
var
|
|
30
|
-
euiTheme = _useEuiTheme.euiTheme,
|
|
31
|
-
colorMode = _useEuiTheme.colorMode,
|
|
32
|
-
modifications = _useEuiTheme.modifications;
|
|
33
|
-
|
|
32
|
+
var theme = useEuiTheme();
|
|
34
33
|
return ___EmotionJSX(Component, _extends({
|
|
35
|
-
theme:
|
|
36
|
-
euiTheme: euiTheme,
|
|
37
|
-
colorMode: colorMode,
|
|
38
|
-
modifications: modifications
|
|
39
|
-
},
|
|
34
|
+
theme: theme,
|
|
40
35
|
ref: ref
|
|
41
36
|
}, props));
|
|
42
37
|
};
|
package/eui.d.ts
CHANGED
|
@@ -9471,7 +9471,7 @@ declare module '@elastic/eui/src/components/combo_box/combo_box' {
|
|
|
9471
9471
|
areAllOptionsSelected: () => boolean;
|
|
9472
9472
|
onComboBoxFocus: FocusEventHandler<HTMLInputElement>;
|
|
9473
9473
|
setCustomOptions: (isContainerBlur: boolean) => void;
|
|
9474
|
-
onContainerBlur:
|
|
9474
|
+
onContainerBlur: FocusEventHandler<HTMLDivElement>;
|
|
9475
9475
|
onKeyDown: KeyboardEventHandler<HTMLDivElement>;
|
|
9476
9476
|
onOptionEnterKey: OptionHandler<T>;
|
|
9477
9477
|
onOptionClick: OptionHandler<T>;
|
|
@@ -9970,6 +9970,11 @@ declare module '@elastic/eui/src/components/list_group/list_group_item' {
|
|
|
9970
9970
|
* instances where the item content is rendered as a `button`
|
|
9971
9971
|
*/
|
|
9972
9972
|
buttonRef?: React.Ref<HTMLButtonElement>;
|
|
9973
|
+
/**
|
|
9974
|
+
* Text to be displayed in the tooltip when `showToolTip` is true.
|
|
9975
|
+
* By default the text will be same as the label text.
|
|
9976
|
+
*/
|
|
9977
|
+
toolTipText?: string;
|
|
9973
9978
|
};
|
|
9974
9979
|
export const EuiListGroupItem: FunctionComponent<EuiListGroupItemProps>;
|
|
9975
9980
|
export {};
|
|
@@ -12268,7 +12273,7 @@ declare module '@elastic/eui/src/components/tabs/tabs' {
|
|
|
12268
12273
|
|
|
12269
12274
|
}
|
|
12270
12275
|
declare module '@elastic/eui/src/components/tabs/tabbed_content/tabbed_content' {
|
|
12271
|
-
import { Component, HTMLAttributes, ReactNode } from 'react';
|
|
12276
|
+
import { Component, HTMLAttributes, ReactNode, FocusEvent } from 'react';
|
|
12272
12277
|
import { EuiTabsSizes } from '@elastic/eui/src/components/tabs/tabs';
|
|
12273
12278
|
import { EuiTabProps } from '@elastic/eui/src/components/tabs/tab';
|
|
12274
12279
|
import { CommonProps } from '@elastic/eui/src/components/common';
|
|
@@ -12320,11 +12325,9 @@ declare module '@elastic/eui/src/components/tabs/tabbed_content/tabbed_content'
|
|
|
12320
12325
|
private readonly rootId;
|
|
12321
12326
|
private readonly tabsRef;
|
|
12322
12327
|
constructor(props: EuiTabbedContentProps);
|
|
12323
|
-
componentDidMount(): void;
|
|
12324
|
-
componentWillUnmount(): void;
|
|
12325
12328
|
focusTab: () => void;
|
|
12326
12329
|
initializeFocus: () => void;
|
|
12327
|
-
removeFocus: (blurEvent: FocusEvent) => void;
|
|
12330
|
+
removeFocus: (blurEvent: FocusEvent<HTMLDivElement>) => void;
|
|
12328
12331
|
onTabClick: (selectedTab: EuiTabbedContentTab) => void;
|
|
12329
12332
|
render(): JSX.Element;
|
|
12330
12333
|
}
|
|
@@ -13226,6 +13229,10 @@ declare module '@elastic/eui/src/components/description_list/description_list_ty
|
|
|
13226
13229
|
* Props object to be passed to `EuiDescriptionListDescription`
|
|
13227
13230
|
*/
|
|
13228
13231
|
descriptionProps?: HTMLAttributes<HTMLElement> & CommonProps;
|
|
13232
|
+
/**
|
|
13233
|
+
* Vertical spacing added between `EuiDescriptionList` elements
|
|
13234
|
+
*/
|
|
13235
|
+
gutterSize?: EuiDescriptionListGutterSizes;
|
|
13229
13236
|
}
|
|
13230
13237
|
export const TYPES: readonly ["row", "inline", "column", "responsiveColumn"];
|
|
13231
13238
|
export type EuiDescriptionListType = typeof TYPES[number];
|
|
@@ -13233,6 +13240,8 @@ declare module '@elastic/eui/src/components/description_list/description_list_ty
|
|
|
13233
13240
|
export type EuiDescriptionListAlignment = typeof ALIGNMENTS[number];
|
|
13234
13241
|
export const TEXT_STYLES: readonly ["normal", "reverse"];
|
|
13235
13242
|
export type EuiDescriptionListTextStyle = typeof TEXT_STYLES[number];
|
|
13243
|
+
export const GUTTER_SIZES: readonly ["s", "m"];
|
|
13244
|
+
export type EuiDescriptionListGutterSizes = typeof GUTTER_SIZES[number];
|
|
13236
13245
|
|
|
13237
13246
|
}
|
|
13238
13247
|
declare module '@elastic/eui/src/components/description_list/description_list_title.styles' {
|
|
@@ -13253,12 +13262,14 @@ declare module '@elastic/eui/src/components/description_list/description_list_ti
|
|
|
13253
13262
|
compressed: import("@emotion/utils").SerializedStyles;
|
|
13254
13263
|
};
|
|
13255
13264
|
right: import("@emotion/utils").SerializedStyles;
|
|
13265
|
+
s: import("@emotion/utils").SerializedStyles;
|
|
13266
|
+
m: import("@emotion/utils").SerializedStyles;
|
|
13256
13267
|
};
|
|
13257
13268
|
|
|
13258
13269
|
}
|
|
13259
13270
|
declare module '@elastic/eui/src/components/description_list/description_list_context' {
|
|
13260
13271
|
|
|
13261
|
-
import { EuiDescriptionListProps } from '@elastic/eui/src/components/description_list/description_list_types'; type EuiDescriptionListContextValues = Required<Pick<EuiDescriptionListProps, 'type' | 'textStyle' | 'align'>> & {
|
|
13272
|
+
import { EuiDescriptionListProps } from '@elastic/eui/src/components/description_list/description_list_types'; type EuiDescriptionListContextValues = Required<Pick<EuiDescriptionListProps, 'type' | 'textStyle' | 'align' | 'gutterSize'>> & {
|
|
13262
13273
|
compressed?: EuiDescriptionListProps['compressed'];
|
|
13263
13274
|
};
|
|
13264
13275
|
export const contextDefaults: EuiDescriptionListContextValues;
|
|
@@ -13292,6 +13303,8 @@ declare module '@elastic/eui/src/components/description_list/description_list_de
|
|
|
13292
13303
|
normal: import("@emotion/utils").SerializedStyles;
|
|
13293
13304
|
};
|
|
13294
13305
|
left: import("@emotion/utils").SerializedStyles;
|
|
13306
|
+
s: import("@emotion/utils").SerializedStyles;
|
|
13307
|
+
m: import("@emotion/utils").SerializedStyles;
|
|
13295
13308
|
};
|
|
13296
13309
|
|
|
13297
13310
|
}
|
|
@@ -18076,9 +18089,8 @@ declare module '@elastic/eui/src/components/table/table_row_cell' {
|
|
|
18076
18089
|
*/
|
|
18077
18090
|
showOnHover?: boolean;
|
|
18078
18091
|
/**
|
|
18079
|
-
*
|
|
18080
|
-
*
|
|
18081
|
-
* `.eui-textBreakWord`.
|
|
18092
|
+
* Creates a text wrapper around cell content that helps word break or truncate
|
|
18093
|
+
* long text correctly.
|
|
18082
18094
|
*/
|
|
18083
18095
|
textOnly?: boolean;
|
|
18084
18096
|
/**
|
|
@@ -18512,6 +18524,10 @@ declare module '@elastic/eui/src/components/basic_table/table_types' {
|
|
|
18512
18524
|
*/
|
|
18513
18525
|
sortable?: boolean | ((item: T) => Primitive);
|
|
18514
18526
|
isExpander?: boolean;
|
|
18527
|
+
/**
|
|
18528
|
+
* Creates a text wrapper around cell content that helps word break or truncate
|
|
18529
|
+
* long text correctly.
|
|
18530
|
+
*/
|
|
18515
18531
|
textOnly?: boolean;
|
|
18516
18532
|
/**
|
|
18517
18533
|
* Defines the horizontal alignment of the column
|
|
@@ -18818,7 +18834,10 @@ declare module '@elastic/eui/src/components/basic_table/basic_table' {
|
|
|
18818
18834
|
*/
|
|
18819
18835
|
tableLayout?: 'fixed' | 'auto';
|
|
18820
18836
|
/**
|
|
18821
|
-
* Applied to table cells
|
|
18837
|
+
* Applied to table cells. Any cell using a render function will set this to be false.
|
|
18838
|
+
*
|
|
18839
|
+
* Creates a text wrapper around cell content that helps word break or truncate
|
|
18840
|
+
* long text correctly.
|
|
18822
18841
|
*/
|
|
18823
18842
|
textOnly?: boolean;
|
|
18824
18843
|
} type BasicTableWithPaginationProps<T> = Omit<BasicTableProps<T>, 'pagination' | 'onChange'> & {
|
package/i18ntokens.json
CHANGED
|
@@ -21,11 +21,11 @@
|
|
|
21
21
|
"highlighting": "string",
|
|
22
22
|
"loc": {
|
|
23
23
|
"start": {
|
|
24
|
-
"line":
|
|
24
|
+
"line": 312,
|
|
25
25
|
"column": 6
|
|
26
26
|
},
|
|
27
27
|
"end": {
|
|
28
|
-
"line":
|
|
28
|
+
"line": 312,
|
|
29
29
|
"column": 79
|
|
30
30
|
}
|
|
31
31
|
},
|
|
@@ -37,11 +37,11 @@
|
|
|
37
37
|
"highlighting": "string",
|
|
38
38
|
"loc": {
|
|
39
39
|
"start": {
|
|
40
|
-
"line":
|
|
40
|
+
"line": 674,
|
|
41
41
|
"column": 10
|
|
42
42
|
},
|
|
43
43
|
"end": {
|
|
44
|
-
"line":
|
|
44
|
+
"line": 678,
|
|
45
45
|
"column": 12
|
|
46
46
|
}
|
|
47
47
|
},
|
|
@@ -53,11 +53,11 @@
|
|
|
53
53
|
"highlighting": "string",
|
|
54
54
|
"loc": {
|
|
55
55
|
"start": {
|
|
56
|
-
"line":
|
|
56
|
+
"line": 687,
|
|
57
57
|
"column": 12
|
|
58
58
|
},
|
|
59
59
|
"end": {
|
|
60
|
-
"line":
|
|
60
|
+
"line": 691,
|
|
61
61
|
"column": 14
|
|
62
62
|
}
|
|
63
63
|
},
|
|
@@ -69,11 +69,11 @@
|
|
|
69
69
|
"highlighting": "string",
|
|
70
70
|
"loc": {
|
|
71
71
|
"start": {
|
|
72
|
-
"line":
|
|
72
|
+
"line": 695,
|
|
73
73
|
"column": 12
|
|
74
74
|
},
|
|
75
75
|
"end": {
|
|
76
|
-
"line":
|
|
76
|
+
"line": 699,
|
|
77
77
|
"column": 14
|
|
78
78
|
}
|
|
79
79
|
},
|
|
@@ -85,11 +85,11 @@
|
|
|
85
85
|
"highlighting": "string",
|
|
86
86
|
"loc": {
|
|
87
87
|
"start": {
|
|
88
|
-
"line":
|
|
88
|
+
"line": 704,
|
|
89
89
|
"column": 10
|
|
90
90
|
},
|
|
91
91
|
"end": {
|
|
92
|
-
"line":
|
|
92
|
+
"line": 708,
|
|
93
93
|
"column": 12
|
|
94
94
|
}
|
|
95
95
|
},
|
|
@@ -101,11 +101,11 @@
|
|
|
101
101
|
"highlighting": "string",
|
|
102
102
|
"loc": {
|
|
103
103
|
"start": {
|
|
104
|
-
"line":
|
|
104
|
+
"line": 750,
|
|
105
105
|
"column": 6
|
|
106
106
|
},
|
|
107
107
|
"end": {
|
|
108
|
-
"line":
|
|
108
|
+
"line": 750,
|
|
109
109
|
"column": 77
|
|
110
110
|
}
|
|
111
111
|
},
|
|
@@ -117,11 +117,11 @@
|
|
|
117
117
|
"highlighting": "string",
|
|
118
118
|
"loc": {
|
|
119
119
|
"start": {
|
|
120
|
-
"line":
|
|
120
|
+
"line": 1143,
|
|
121
121
|
"column": 8
|
|
122
122
|
},
|
|
123
123
|
"end": {
|
|
124
|
-
"line":
|
|
124
|
+
"line": 1143,
|
|
125
125
|
"column": 79
|
|
126
126
|
}
|
|
127
127
|
},
|
|
@@ -133,11 +133,11 @@
|
|
|
133
133
|
"highlighting": "string",
|
|
134
134
|
"loc": {
|
|
135
135
|
"start": {
|
|
136
|
-
"line":
|
|
136
|
+
"line": 1363,
|
|
137
137
|
"column": 8
|
|
138
138
|
},
|
|
139
139
|
"end": {
|
|
140
|
-
"line":
|
|
140
|
+
"line": 1367,
|
|
141
141
|
"column": 9
|
|
142
142
|
}
|
|
143
143
|
},
|
|
@@ -773,11 +773,11 @@
|
|
|
773
773
|
"highlighting": "string",
|
|
774
774
|
"loc": {
|
|
775
775
|
"start": {
|
|
776
|
-
"line":
|
|
776
|
+
"line": 968,
|
|
777
777
|
"column": 10
|
|
778
778
|
},
|
|
779
779
|
"end": {
|
|
780
|
-
"line":
|
|
780
|
+
"line": 971,
|
|
781
781
|
"column": 11
|
|
782
782
|
}
|
|
783
783
|
},
|
|
@@ -1251,6 +1251,11 @@ EuiBasicTable.propTypes = {
|
|
|
1251
1251
|
*/
|
|
1252
1252
|
sortable: _propTypes.default.oneOfType([_propTypes.default.bool.isRequired, _propTypes.default.func.isRequired]),
|
|
1253
1253
|
isExpander: _propTypes.default.bool,
|
|
1254
|
+
|
|
1255
|
+
/**
|
|
1256
|
+
* Creates a text wrapper around cell content that helps word break or truncate
|
|
1257
|
+
* long text correctly.
|
|
1258
|
+
*/
|
|
1254
1259
|
textOnly: _propTypes.default.bool,
|
|
1255
1260
|
|
|
1256
1261
|
/**
|
|
@@ -1597,11 +1602,17 @@ EuiBasicTable.propTypes = {
|
|
|
1597
1602
|
tableLayout: _propTypes.default.oneOf(["fixed", "auto"]),
|
|
1598
1603
|
|
|
1599
1604
|
/**
|
|
1600
|
-
* Applied to table cells
|
|
1605
|
+
* Applied to table cells. Any cell using a render function will set this to be false.
|
|
1606
|
+
*
|
|
1607
|
+
* Creates a text wrapper around cell content that helps word break or truncate
|
|
1608
|
+
* long text correctly.
|
|
1601
1609
|
*/
|
|
1602
1610
|
|
|
1603
1611
|
/**
|
|
1604
|
-
* Applied to table cells
|
|
1612
|
+
* Applied to table cells. Any cell using a render function will set this to be false.
|
|
1613
|
+
*
|
|
1614
|
+
* Creates a text wrapper around cell content that helps word break or truncate
|
|
1615
|
+
* long text correctly.
|
|
1605
1616
|
*/
|
|
1606
1617
|
textOnly: _propTypes.default.bool
|
|
1607
1618
|
};
|