@elastic/eui 83.1.0 → 84.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 +4 -3
- package/dist/eui_theme_dark.min.css +1 -1
- package/dist/eui_theme_light.css +4 -3
- package/dist/eui_theme_light.min.css +1 -1
- package/es/components/accordion/accordion.js +4 -14
- package/es/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.js +1 -1
- package/es/components/focus_trap/focus_trap.js +1 -0
- package/es/components/form/range/dual_range.js +86 -30
- package/es/components/link/link.styles.js +2 -2
- package/es/components/resizable_container/resizable_collapse_button.js +2 -2
- package/es/components/search_bar/index.js +2 -1
- package/es/components/search_bar/search_bar.js +2 -2
- package/es/components/search_bar/search_filters.js +9 -9
- package/eui.d.ts +28 -33
- package/i18ntokens.json +8 -8
- package/lib/components/accordion/accordion.js +4 -14
- package/lib/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.js +1 -1
- package/lib/components/focus_trap/focus_trap.js +1 -0
- package/lib/components/form/range/dual_range.js +86 -30
- package/lib/components/link/link.styles.js +2 -2
- package/lib/components/resizable_container/resizable_collapse_button.js +2 -2
- package/lib/components/search_bar/index.js +8 -1
- package/lib/components/search_bar/search_bar.js +1 -1
- package/lib/components/search_bar/search_filters.js +11 -11
- package/optimize/es/components/accordion/accordion.js +3 -13
- package/optimize/es/components/focus_trap/focus_trap.js +1 -0
- package/optimize/es/components/form/range/dual_range.js +86 -30
- package/optimize/es/components/link/link.styles.js +2 -2
- package/optimize/es/components/resizable_container/resizable_collapse_button.js +2 -2
- package/optimize/es/components/search_bar/index.js +2 -1
- package/optimize/es/components/search_bar/search_bar.js +2 -2
- package/optimize/es/components/search_bar/search_filters.js +8 -8
- package/optimize/lib/components/accordion/accordion.js +3 -13
- package/optimize/lib/components/focus_trap/focus_trap.js +1 -0
- package/optimize/lib/components/form/range/dual_range.js +86 -30
- package/optimize/lib/components/link/link.styles.js +2 -2
- package/optimize/lib/components/resizable_container/resizable_collapse_button.js +2 -2
- package/optimize/lib/components/search_bar/index.js +8 -1
- package/optimize/lib/components/search_bar/search_bar.js +1 -1
- package/optimize/lib/components/search_bar/search_filters.js +10 -10
- package/package.json +5 -4
- package/src/components/combo_box/combo_box_input/_combo_box_pill.scss +4 -0
- package/src/components/filter_group/_filter_group.scss +0 -4
- package/src/components/resizable_container/_resizable_collapse_button.scss +1 -0
- package/test-env/components/accordion/accordion.js +4 -14
- package/test-env/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.js +1 -1
- package/test-env/components/form/range/dual_range.js +86 -30
- package/test-env/components/link/link.styles.js +2 -2
- package/test-env/components/resizable_container/resizable_collapse_button.js +2 -2
- package/test-env/components/search_bar/index.js +8 -1
- package/test-env/components/search_bar/search_bar.js +1 -1
- package/test-env/components/search_bar/search_filters.js +11 -11
|
@@ -376,9 +376,9 @@ var EuiDualRangeClass = /*#__PURE__*/function (_Component) {
|
|
|
376
376
|
tickInterval = _this$props.tickInterval,
|
|
377
377
|
ticks = _this$props.ticks,
|
|
378
378
|
levels = _this$props.levels,
|
|
379
|
-
|
|
379
|
+
_onBlur = _this$props.onBlur,
|
|
380
380
|
onChange = _this$props.onChange,
|
|
381
|
-
|
|
381
|
+
_onFocus = _this$props.onFocus,
|
|
382
382
|
showRange = _this$props.showRange,
|
|
383
383
|
value = _this$props.value,
|
|
384
384
|
isInvalid = _this$props.isInvalid,
|
|
@@ -399,57 +399,113 @@ var EuiDualRangeClass = /*#__PURE__*/function (_Component) {
|
|
|
399
399
|
// Overridable props
|
|
400
400
|
, (0, _extends2.default)({
|
|
401
401
|
"aria-describedby": this.props['aria-describedby'],
|
|
402
|
-
"aria-label": this.props['aria-label']
|
|
402
|
+
"aria-label": this.props['aria-label'],
|
|
403
|
+
disabled: disabled,
|
|
404
|
+
isInvalid: isInvalid,
|
|
405
|
+
name: "".concat(name, "-minValue"),
|
|
406
|
+
value: this.lowerValue,
|
|
407
|
+
readOnly: readOnly
|
|
403
408
|
}, minInputProps, {
|
|
404
409
|
// Non-overridable props
|
|
405
410
|
side: "min",
|
|
406
411
|
min: min,
|
|
407
412
|
max: Number(this.upperValue),
|
|
408
413
|
step: step,
|
|
409
|
-
value: this.lowerValue,
|
|
410
|
-
disabled: disabled,
|
|
411
414
|
compressed: compressed,
|
|
412
|
-
onChange: this.handleLowerInputChange,
|
|
413
|
-
onKeyDown: this.handleInputKeyDown,
|
|
414
|
-
name: "".concat(name, "-minValue"),
|
|
415
|
-
onFocus: canShowDropdown ? this.onInputFocus : onFocus,
|
|
416
|
-
onBlur: canShowDropdown ? this.onInputBlur : onBlur,
|
|
417
|
-
readOnly: readOnly,
|
|
418
415
|
autoSize: !showInputOnly,
|
|
419
416
|
fullWidth: !!showInputOnly && fullWidth,
|
|
420
|
-
isInvalid: isInvalid,
|
|
421
417
|
controlOnly: showInputOnly,
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
418
|
+
onChange: function onChange(event) {
|
|
419
|
+
var _minInputProps$onChan;
|
|
420
|
+
_this2.handleLowerInputChange(event);
|
|
421
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onChan = minInputProps.onChange) === null || _minInputProps$onChan === void 0 ? void 0 : _minInputProps$onChan.call(minInputProps, event);
|
|
422
|
+
},
|
|
423
|
+
onKeyDown: function onKeyDown(event) {
|
|
424
|
+
var _minInputProps$onKeyD;
|
|
425
|
+
_this2.handleInputKeyDown(event);
|
|
426
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onKeyD = minInputProps.onKeyDown) === null || _minInputProps$onKeyD === void 0 ? void 0 : _minInputProps$onKeyD.call(minInputProps, event);
|
|
427
|
+
},
|
|
428
|
+
onFocus: function onFocus(event) {
|
|
429
|
+
var _minInputProps$onFocu;
|
|
430
|
+
if (canShowDropdown) {
|
|
431
|
+
_this2.onInputFocus(event);
|
|
432
|
+
} else {
|
|
433
|
+
_onFocus === null || _onFocus === void 0 ? void 0 : _onFocus(event);
|
|
434
|
+
}
|
|
435
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onFocu = minInputProps.onFocus) === null || _minInputProps$onFocu === void 0 ? void 0 : _minInputProps$onFocu.call(minInputProps, event);
|
|
436
|
+
},
|
|
437
|
+
onBlur: function onBlur(event) {
|
|
438
|
+
var _minInputProps$onBlur;
|
|
439
|
+
if (canShowDropdown) {
|
|
440
|
+
_this2.onInputBlur(event);
|
|
441
|
+
} else {
|
|
442
|
+
_onBlur === null || _onBlur === void 0 ? void 0 : _onBlur(event);
|
|
443
|
+
}
|
|
444
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onBlur = minInputProps.onBlur) === null || _minInputProps$onBlur === void 0 ? void 0 : _minInputProps$onBlur.call(minInputProps, event);
|
|
445
|
+
},
|
|
446
|
+
onMouseDown: function onMouseDown(event) {
|
|
447
|
+
var _minInputProps$onMous;
|
|
448
|
+
if (showInputOnly) {
|
|
449
|
+
_this2.preventPopoverClose = true;
|
|
450
|
+
}
|
|
451
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onMous = minInputProps.onMouseDown) === null || _minInputProps$onMous === void 0 ? void 0 : _minInputProps$onMous.call(minInputProps, event);
|
|
452
|
+
}
|
|
425
453
|
})) : undefined;
|
|
426
454
|
var maxInput = !!showInput ? (0, _react2.jsx)(_range_input.EuiRangeInput
|
|
427
455
|
// Overridable props
|
|
428
456
|
, (0, _extends2.default)({
|
|
429
457
|
"aria-describedby": this.props['aria-describedby'],
|
|
430
|
-
"aria-label": this.props['aria-label']
|
|
458
|
+
"aria-label": this.props['aria-label'],
|
|
459
|
+
disabled: disabled,
|
|
460
|
+
isInvalid: isInvalid,
|
|
461
|
+
name: "".concat(name, "-maxValue"),
|
|
462
|
+
value: this.upperValue,
|
|
463
|
+
readOnly: readOnly
|
|
431
464
|
}, maxInputProps, {
|
|
432
465
|
// Non-overridable props
|
|
433
466
|
side: "max",
|
|
434
467
|
min: Number(this.lowerValue),
|
|
435
468
|
max: max,
|
|
436
469
|
step: step,
|
|
437
|
-
value: this.upperValue,
|
|
438
|
-
disabled: disabled,
|
|
439
470
|
compressed: compressed,
|
|
440
|
-
onChange: this.handleUpperInputChange,
|
|
441
|
-
onKeyDown: this.handleInputKeyDown,
|
|
442
|
-
name: "".concat(name, "-maxValue"),
|
|
443
|
-
onFocus: canShowDropdown ? this.onInputFocus : onFocus,
|
|
444
|
-
onBlur: canShowDropdown ? this.onInputBlur : onBlur,
|
|
445
|
-
readOnly: readOnly,
|
|
446
471
|
autoSize: !showInputOnly,
|
|
447
472
|
fullWidth: !!showInputOnly && fullWidth,
|
|
448
473
|
controlOnly: showInputOnly,
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
474
|
+
onChange: function onChange(event) {
|
|
475
|
+
var _maxInputProps$onChan;
|
|
476
|
+
_this2.handleUpperInputChange(event);
|
|
477
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onChan = maxInputProps.onChange) === null || _maxInputProps$onChan === void 0 ? void 0 : _maxInputProps$onChan.call(maxInputProps, event);
|
|
478
|
+
},
|
|
479
|
+
onKeyDown: function onKeyDown(event) {
|
|
480
|
+
var _maxInputProps$onKeyD;
|
|
481
|
+
_this2.handleInputKeyDown(event);
|
|
482
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onKeyD = maxInputProps.onKeyDown) === null || _maxInputProps$onKeyD === void 0 ? void 0 : _maxInputProps$onKeyD.call(maxInputProps, event);
|
|
483
|
+
},
|
|
484
|
+
onFocus: function onFocus(event) {
|
|
485
|
+
var _maxInputProps$onFocu;
|
|
486
|
+
if (canShowDropdown) {
|
|
487
|
+
_this2.onInputFocus(event);
|
|
488
|
+
} else {
|
|
489
|
+
_onFocus === null || _onFocus === void 0 ? void 0 : _onFocus(event);
|
|
490
|
+
}
|
|
491
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onFocu = maxInputProps.onFocus) === null || _maxInputProps$onFocu === void 0 ? void 0 : _maxInputProps$onFocu.call(maxInputProps, event);
|
|
492
|
+
},
|
|
493
|
+
onBlur: function onBlur(event) {
|
|
494
|
+
var _maxInputProps$onBlur;
|
|
495
|
+
if (canShowDropdown) {
|
|
496
|
+
_this2.onInputBlur(event);
|
|
497
|
+
} else {
|
|
498
|
+
_onBlur === null || _onBlur === void 0 ? void 0 : _onBlur(event);
|
|
499
|
+
}
|
|
500
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onBlur = maxInputProps.onBlur) === null || _maxInputProps$onBlur === void 0 ? void 0 : _maxInputProps$onBlur.call(maxInputProps, event);
|
|
501
|
+
},
|
|
502
|
+
onMouseDown: function onMouseDown(event) {
|
|
503
|
+
var _maxInputProps$onMous;
|
|
504
|
+
if (showInputOnly) {
|
|
505
|
+
_this2.preventPopoverClose = true;
|
|
506
|
+
}
|
|
507
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onMous = maxInputProps.onMouseDown) === null || _maxInputProps$onMous === void 0 ? void 0 : _maxInputProps$onMous.call(maxInputProps, event);
|
|
508
|
+
}
|
|
453
509
|
})) : undefined;
|
|
454
510
|
var classes = (0, _classnames.default)('euiDualRange', className);
|
|
455
511
|
var dualRangeStyles = (0, _dual_range.euiDualRangeStyles)();
|
|
@@ -513,8 +569,8 @@ var EuiDualRangeClass = /*#__PURE__*/function (_Component) {
|
|
|
513
569
|
"aria-hidden": true,
|
|
514
570
|
tabIndex: -1,
|
|
515
571
|
showRange: showRange,
|
|
516
|
-
onFocus:
|
|
517
|
-
onBlur:
|
|
572
|
+
onFocus: _onFocus,
|
|
573
|
+
onBlur: _onBlur
|
|
518
574
|
}, rest)), _this2.state.rangeSliderRefAvailable && (0, _react2.jsx)(_react.default.Fragment, null, isDraggable && _this2.isValid && (0, _react2.jsx)(_range_draggable.EuiRangeDraggable, {
|
|
519
575
|
min: min,
|
|
520
576
|
max: max,
|
|
@@ -14,14 +14,14 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
14
14
|
* Side Public License, v 1.
|
|
15
15
|
*/
|
|
16
16
|
var _colorCSS = function _colorCSS(color) {
|
|
17
|
-
return "\n color: ".concat(color, ";\n\n &:
|
|
17
|
+
return "\n color: ".concat(color, ";\n\n &:target {\n color: darken(").concat(color, ", 10%);\n }\n ");
|
|
18
18
|
};
|
|
19
19
|
var euiLinkHoverCSS = function euiLinkHoverCSS() {
|
|
20
20
|
return "\n text-decoration: underline;\n ";
|
|
21
21
|
};
|
|
22
22
|
exports.euiLinkHoverCSS = euiLinkHoverCSS;
|
|
23
23
|
var euiLinkFocusCSS = function euiLinkFocusCSS(euiTheme) {
|
|
24
|
-
return "\n text-decoration: underline;\n text-decoration-thickness: ".concat(euiTheme.border.width.thick, "
|
|
24
|
+
return "\n text-decoration: underline;\n text-decoration-thickness: ".concat(euiTheme.border.width.thick, ";\n ");
|
|
25
25
|
};
|
|
26
26
|
exports.euiLinkFocusCSS = euiLinkFocusCSS;
|
|
27
27
|
var euiLinkCSS = function euiLinkCSS(euiThemeContext) {
|
|
@@ -49,8 +49,8 @@ var EuiResizableCollapseButton = function EuiResizableCollapseButton(_ref) {
|
|
|
49
49
|
break;
|
|
50
50
|
}
|
|
51
51
|
return (0, _react2.jsx)(_button.EuiButtonIcon, (0, _extends2.default)({
|
|
52
|
-
display: isCollapsed ? 'empty' : '
|
|
53
|
-
color:
|
|
52
|
+
display: isCollapsed ? 'empty' : 'base',
|
|
53
|
+
color: "text"
|
|
54
54
|
}, rest, {
|
|
55
55
|
className: classes,
|
|
56
56
|
iconType: isCollapsed ? COLLAPSED_ICON : NOT_COLLAPSED_ICON
|
|
@@ -15,10 +15,17 @@ Object.defineProperty(exports, "EuiSearchBar", {
|
|
|
15
15
|
return _search_bar.EuiSearchBar;
|
|
16
16
|
}
|
|
17
17
|
});
|
|
18
|
+
Object.defineProperty(exports, "EuiSearchBarFilters", {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: function get() {
|
|
21
|
+
return _search_filters.EuiSearchBarFilters;
|
|
22
|
+
}
|
|
23
|
+
});
|
|
18
24
|
Object.defineProperty(exports, "Query", {
|
|
19
25
|
enumerable: true,
|
|
20
26
|
get: function get() {
|
|
21
27
|
return _search_bar.Query;
|
|
22
28
|
}
|
|
23
29
|
});
|
|
24
|
-
var _search_bar = require("./search_bar");
|
|
30
|
+
var _search_bar = require("./search_bar");
|
|
31
|
+
var _search_filters = require("./search_filters");
|
|
@@ -200,7 +200,7 @@ var EuiSearchBar = /*#__PURE__*/function (_Component) {
|
|
|
200
200
|
var filtersBar = !filters ? undefined : (0, _react2.jsx)(_flex.EuiFlexItem, {
|
|
201
201
|
className: "euiSearchBar__filtersHolder",
|
|
202
202
|
grow: false
|
|
203
|
-
}, (0, _react2.jsx)(_search_filters.
|
|
203
|
+
}, (0, _react2.jsx)(_search_filters.EuiSearchBarFilters, {
|
|
204
204
|
filters: filters,
|
|
205
205
|
query: query,
|
|
206
206
|
onChange: this.onFiltersChange
|
|
@@ -5,7 +5,7 @@ var _typeof = require("@babel/runtime/helpers/typeof");
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.
|
|
8
|
+
exports.EuiSearchBarFilters = void 0;
|
|
9
9
|
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
|
|
10
10
|
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
|
|
11
11
|
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
@@ -26,14 +26,14 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
26
26
|
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
27
27
|
* Side Public License, v 1.
|
|
28
28
|
*/
|
|
29
|
-
var
|
|
30
|
-
(0, _inherits2.default)(
|
|
31
|
-
var _super = _createSuper(
|
|
32
|
-
function
|
|
33
|
-
(0, _classCallCheck2.default)(this,
|
|
29
|
+
var EuiSearchBarFilters = /*#__PURE__*/function (_Component) {
|
|
30
|
+
(0, _inherits2.default)(EuiSearchBarFilters, _Component);
|
|
31
|
+
var _super = _createSuper(EuiSearchBarFilters);
|
|
32
|
+
function EuiSearchBarFilters() {
|
|
33
|
+
(0, _classCallCheck2.default)(this, EuiSearchBarFilters);
|
|
34
34
|
return _super.apply(this, arguments);
|
|
35
35
|
}
|
|
36
|
-
(0, _createClass2.default)(
|
|
36
|
+
(0, _createClass2.default)(EuiSearchBarFilters, [{
|
|
37
37
|
key: "render",
|
|
38
38
|
value: function render() {
|
|
39
39
|
var _this$props = this.props,
|
|
@@ -55,9 +55,9 @@ var EuiSearchFilters = /*#__PURE__*/function (_Component) {
|
|
|
55
55
|
return (0, _react2.jsx)(_filter_group.EuiFilterGroup, null, items);
|
|
56
56
|
}
|
|
57
57
|
}]);
|
|
58
|
-
return
|
|
58
|
+
return EuiSearchBarFilters;
|
|
59
59
|
}(_react.Component);
|
|
60
|
-
exports.
|
|
61
|
-
(0, _defineProperty2.default)(
|
|
60
|
+
exports.EuiSearchBarFilters = EuiSearchBarFilters;
|
|
61
|
+
(0, _defineProperty2.default)(EuiSearchBarFilters, "defaultProps", {
|
|
62
62
|
filters: []
|
|
63
63
|
});
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elastic/eui",
|
|
3
3
|
"description": "Elastic UI Component Library",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "84.0.0",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"main": "lib",
|
|
7
7
|
"module": "es",
|
|
8
8
|
"types": "eui.d.ts",
|
|
9
|
-
"docker_image": "18.16.
|
|
9
|
+
"docker_image": "18.16.1",
|
|
10
10
|
"engines": {
|
|
11
11
|
"node": "16.x || 18.x || >=20.0"
|
|
12
12
|
},
|
|
@@ -56,7 +56,8 @@
|
|
|
56
56
|
},
|
|
57
57
|
"resolutions": {
|
|
58
58
|
"**/prismjs": "1.27.0",
|
|
59
|
-
"**/react": "^17.0.0"
|
|
59
|
+
"**/react": "^17.0.0",
|
|
60
|
+
"react-focus-lock": "^2.9.5"
|
|
60
61
|
},
|
|
61
62
|
"pre-commit": [
|
|
62
63
|
"test-staged"
|
|
@@ -81,7 +82,7 @@
|
|
|
81
82
|
"react-beautiful-dnd": "^13.1.0",
|
|
82
83
|
"react-dropzone": "^11.5.3",
|
|
83
84
|
"react-element-to-jsx-string": "^14.3.4",
|
|
84
|
-
"react-focus-on": "^3.
|
|
85
|
+
"react-focus-on": "^3.9.1",
|
|
85
86
|
"react-input-autosize": "^3.0.0",
|
|
86
87
|
"react-is": "^17.0.2",
|
|
87
88
|
"react-remove-scroll-bar": "^2.3.4",
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
animation: none !important; // stylelint-disable-line declaration-no-important
|
|
17
17
|
// Remove transition from EuiButtonIcon because of the custom transforms
|
|
18
18
|
transition-property: background, box-shadow;
|
|
19
|
+
background: $euiColorEmptyShade;
|
|
19
20
|
|
|
20
21
|
&:focus {
|
|
21
22
|
@include euiSlightShadowHover;
|
|
@@ -18,7 +18,6 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
|
|
|
18
18
|
var _react = _interopRequireWildcard(require("react"));
|
|
19
19
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
20
20
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
21
|
-
var _common = require("../common");
|
|
22
21
|
var _loading = require("../loading");
|
|
23
22
|
var _resize_observer = require("../observer/resize_observer");
|
|
24
23
|
var _text = require("../text");
|
|
@@ -39,15 +38,7 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
39
38
|
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
40
39
|
* Side Public License, v 1.
|
|
41
40
|
*/
|
|
42
|
-
var
|
|
43
|
-
none: '',
|
|
44
|
-
xs: 'euiAccordion__padding--xs',
|
|
45
|
-
s: 'euiAccordion__padding--s',
|
|
46
|
-
m: 'euiAccordion__padding--m',
|
|
47
|
-
l: 'euiAccordion__padding--l',
|
|
48
|
-
xl: 'euiAccordion__padding--xl'
|
|
49
|
-
};
|
|
50
|
-
var PADDING_SIZES = (0, _common.keysOf)(paddingSizeToClassNameMap);
|
|
41
|
+
var PADDING_SIZES = ['none', 'xs', 's', 'm', 'l', 'xl'];
|
|
51
42
|
exports.PADDING_SIZES = PADDING_SIZES;
|
|
52
43
|
var EuiAccordionClass = /*#__PURE__*/function (_Component) {
|
|
53
44
|
(0, _inherits2.default)(EuiAccordionClass, _Component);
|
|
@@ -150,8 +141,7 @@ var EuiAccordionClass = /*#__PURE__*/function (_Component) {
|
|
|
150
141
|
var classes = (0, _classnames.default)('euiAccordion', {
|
|
151
142
|
'euiAccordion-isOpen': isOpen
|
|
152
143
|
}, className);
|
|
153
|
-
var
|
|
154
|
-
var childrenClasses = (0, _classnames.default)(paddingClass, {
|
|
144
|
+
var childrenClasses = (0, _classnames.default)('euiAccordion__children', {
|
|
155
145
|
'euiAccordion__children-isLoading': isLoading
|
|
156
146
|
});
|
|
157
147
|
var buttonClasses = (0, _classnames.default)('euiAccordion__button', buttonClassName, buttonProps === null || buttonProps === void 0 ? void 0 : buttonProps.className);
|
|
@@ -165,7 +155,7 @@ var EuiAccordionClass = /*#__PURE__*/function (_Component) {
|
|
|
165
155
|
var buttonStyles = (0, _accordion.euiAccordionButtonStyles)(theme);
|
|
166
156
|
var cssButtonStyles = [buttonStyles.euiAccordion__button, isDisabled && buttonStyles.disabled, buttonProps === null || buttonProps === void 0 ? void 0 : buttonProps.css];
|
|
167
157
|
var childrenStyles = (0, _accordion.euiAccordionChildrenStyles)(theme);
|
|
168
|
-
var cssChildrenStyles = [childrenStyles.euiAccordion__children, isLoading && childrenStyles.isLoading, paddingSize
|
|
158
|
+
var cssChildrenStyles = [childrenStyles.euiAccordion__children, isLoading && childrenStyles.isLoading, paddingSize && paddingSize !== 'none' && childrenStyles[paddingSize]];
|
|
169
159
|
var childWrapperStyles = (0, _accordion.euiAccordionChildWrapperStyles)(theme);
|
|
170
160
|
var cssChildWrapperStyles = [childWrapperStyles.euiAccordion__childWrapper, isOpen && childWrapperStyles.isOpen];
|
|
171
161
|
var iconButtonStyles = (0, _accordion.euiAccordionIconButtonStyles)(theme);
|
|
@@ -325,7 +315,7 @@ EuiAccordionClass.propTypes = {
|
|
|
325
315
|
/**
|
|
326
316
|
* The padding around the exposed accordion content.
|
|
327
317
|
*/
|
|
328
|
-
paddingSize: _propTypes.default.
|
|
318
|
+
paddingSize: _propTypes.default.any,
|
|
329
319
|
/**
|
|
330
320
|
* Placement of the arrow indicator, or 'none' to hide it.
|
|
331
321
|
*/
|
|
@@ -238,7 +238,7 @@ EuiCollapsibleNavGroup.propTypes = {
|
|
|
238
238
|
/**
|
|
239
239
|
* The padding around the exposed accordion content.
|
|
240
240
|
*/
|
|
241
|
-
paddingSize: _propTypes.default.
|
|
241
|
+
paddingSize: _propTypes.default.any,
|
|
242
242
|
/**
|
|
243
243
|
* Placement of the arrow indicator, or 'none' to hide it.
|
|
244
244
|
*/
|
|
@@ -377,9 +377,9 @@ var EuiDualRangeClass = /*#__PURE__*/function (_Component) {
|
|
|
377
377
|
tickInterval = _this$props.tickInterval,
|
|
378
378
|
ticks = _this$props.ticks,
|
|
379
379
|
levels = _this$props.levels,
|
|
380
|
-
|
|
380
|
+
_onBlur = _this$props.onBlur,
|
|
381
381
|
onChange = _this$props.onChange,
|
|
382
|
-
|
|
382
|
+
_onFocus = _this$props.onFocus,
|
|
383
383
|
showRange = _this$props.showRange,
|
|
384
384
|
value = _this$props.value,
|
|
385
385
|
isInvalid = _this$props.isInvalid,
|
|
@@ -400,57 +400,113 @@ var EuiDualRangeClass = /*#__PURE__*/function (_Component) {
|
|
|
400
400
|
// Overridable props
|
|
401
401
|
, (0, _extends2.default)({
|
|
402
402
|
"aria-describedby": this.props['aria-describedby'],
|
|
403
|
-
"aria-label": this.props['aria-label']
|
|
403
|
+
"aria-label": this.props['aria-label'],
|
|
404
|
+
disabled: disabled,
|
|
405
|
+
isInvalid: isInvalid,
|
|
406
|
+
name: "".concat(name, "-minValue"),
|
|
407
|
+
value: this.lowerValue,
|
|
408
|
+
readOnly: readOnly
|
|
404
409
|
}, minInputProps, {
|
|
405
410
|
// Non-overridable props
|
|
406
411
|
side: "min",
|
|
407
412
|
min: min,
|
|
408
413
|
max: Number(this.upperValue),
|
|
409
414
|
step: step,
|
|
410
|
-
value: this.lowerValue,
|
|
411
|
-
disabled: disabled,
|
|
412
415
|
compressed: compressed,
|
|
413
|
-
onChange: this.handleLowerInputChange,
|
|
414
|
-
onKeyDown: this.handleInputKeyDown,
|
|
415
|
-
name: "".concat(name, "-minValue"),
|
|
416
|
-
onFocus: canShowDropdown ? this.onInputFocus : onFocus,
|
|
417
|
-
onBlur: canShowDropdown ? this.onInputBlur : onBlur,
|
|
418
|
-
readOnly: readOnly,
|
|
419
416
|
autoSize: !showInputOnly,
|
|
420
417
|
fullWidth: !!showInputOnly && fullWidth,
|
|
421
|
-
isInvalid: isInvalid,
|
|
422
418
|
controlOnly: showInputOnly,
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
419
|
+
onChange: function onChange(event) {
|
|
420
|
+
var _minInputProps$onChan;
|
|
421
|
+
_this2.handleLowerInputChange(event);
|
|
422
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onChan = minInputProps.onChange) === null || _minInputProps$onChan === void 0 ? void 0 : _minInputProps$onChan.call(minInputProps, event);
|
|
423
|
+
},
|
|
424
|
+
onKeyDown: function onKeyDown(event) {
|
|
425
|
+
var _minInputProps$onKeyD;
|
|
426
|
+
_this2.handleInputKeyDown(event);
|
|
427
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onKeyD = minInputProps.onKeyDown) === null || _minInputProps$onKeyD === void 0 ? void 0 : _minInputProps$onKeyD.call(minInputProps, event);
|
|
428
|
+
},
|
|
429
|
+
onFocus: function onFocus(event) {
|
|
430
|
+
var _minInputProps$onFocu;
|
|
431
|
+
if (canShowDropdown) {
|
|
432
|
+
_this2.onInputFocus(event);
|
|
433
|
+
} else {
|
|
434
|
+
_onFocus === null || _onFocus === void 0 ? void 0 : _onFocus(event);
|
|
435
|
+
}
|
|
436
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onFocu = minInputProps.onFocus) === null || _minInputProps$onFocu === void 0 ? void 0 : _minInputProps$onFocu.call(minInputProps, event);
|
|
437
|
+
},
|
|
438
|
+
onBlur: function onBlur(event) {
|
|
439
|
+
var _minInputProps$onBlur;
|
|
440
|
+
if (canShowDropdown) {
|
|
441
|
+
_this2.onInputBlur(event);
|
|
442
|
+
} else {
|
|
443
|
+
_onBlur === null || _onBlur === void 0 ? void 0 : _onBlur(event);
|
|
444
|
+
}
|
|
445
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onBlur = minInputProps.onBlur) === null || _minInputProps$onBlur === void 0 ? void 0 : _minInputProps$onBlur.call(minInputProps, event);
|
|
446
|
+
},
|
|
447
|
+
onMouseDown: function onMouseDown(event) {
|
|
448
|
+
var _minInputProps$onMous;
|
|
449
|
+
if (showInputOnly) {
|
|
450
|
+
_this2.preventPopoverClose = true;
|
|
451
|
+
}
|
|
452
|
+
minInputProps === null || minInputProps === void 0 ? void 0 : (_minInputProps$onMous = minInputProps.onMouseDown) === null || _minInputProps$onMous === void 0 ? void 0 : _minInputProps$onMous.call(minInputProps, event);
|
|
453
|
+
}
|
|
426
454
|
})) : undefined;
|
|
427
455
|
var maxInput = !!showInput ? (0, _react2.jsx)(_range_input.EuiRangeInput
|
|
428
456
|
// Overridable props
|
|
429
457
|
, (0, _extends2.default)({
|
|
430
458
|
"aria-describedby": this.props['aria-describedby'],
|
|
431
|
-
"aria-label": this.props['aria-label']
|
|
459
|
+
"aria-label": this.props['aria-label'],
|
|
460
|
+
disabled: disabled,
|
|
461
|
+
isInvalid: isInvalid,
|
|
462
|
+
name: "".concat(name, "-maxValue"),
|
|
463
|
+
value: this.upperValue,
|
|
464
|
+
readOnly: readOnly
|
|
432
465
|
}, maxInputProps, {
|
|
433
466
|
// Non-overridable props
|
|
434
467
|
side: "max",
|
|
435
468
|
min: Number(this.lowerValue),
|
|
436
469
|
max: max,
|
|
437
470
|
step: step,
|
|
438
|
-
value: this.upperValue,
|
|
439
|
-
disabled: disabled,
|
|
440
471
|
compressed: compressed,
|
|
441
|
-
onChange: this.handleUpperInputChange,
|
|
442
|
-
onKeyDown: this.handleInputKeyDown,
|
|
443
|
-
name: "".concat(name, "-maxValue"),
|
|
444
|
-
onFocus: canShowDropdown ? this.onInputFocus : onFocus,
|
|
445
|
-
onBlur: canShowDropdown ? this.onInputBlur : onBlur,
|
|
446
|
-
readOnly: readOnly,
|
|
447
472
|
autoSize: !showInputOnly,
|
|
448
473
|
fullWidth: !!showInputOnly && fullWidth,
|
|
449
474
|
controlOnly: showInputOnly,
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
475
|
+
onChange: function onChange(event) {
|
|
476
|
+
var _maxInputProps$onChan;
|
|
477
|
+
_this2.handleUpperInputChange(event);
|
|
478
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onChan = maxInputProps.onChange) === null || _maxInputProps$onChan === void 0 ? void 0 : _maxInputProps$onChan.call(maxInputProps, event);
|
|
479
|
+
},
|
|
480
|
+
onKeyDown: function onKeyDown(event) {
|
|
481
|
+
var _maxInputProps$onKeyD;
|
|
482
|
+
_this2.handleInputKeyDown(event);
|
|
483
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onKeyD = maxInputProps.onKeyDown) === null || _maxInputProps$onKeyD === void 0 ? void 0 : _maxInputProps$onKeyD.call(maxInputProps, event);
|
|
484
|
+
},
|
|
485
|
+
onFocus: function onFocus(event) {
|
|
486
|
+
var _maxInputProps$onFocu;
|
|
487
|
+
if (canShowDropdown) {
|
|
488
|
+
_this2.onInputFocus(event);
|
|
489
|
+
} else {
|
|
490
|
+
_onFocus === null || _onFocus === void 0 ? void 0 : _onFocus(event);
|
|
491
|
+
}
|
|
492
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onFocu = maxInputProps.onFocus) === null || _maxInputProps$onFocu === void 0 ? void 0 : _maxInputProps$onFocu.call(maxInputProps, event);
|
|
493
|
+
},
|
|
494
|
+
onBlur: function onBlur(event) {
|
|
495
|
+
var _maxInputProps$onBlur;
|
|
496
|
+
if (canShowDropdown) {
|
|
497
|
+
_this2.onInputBlur(event);
|
|
498
|
+
} else {
|
|
499
|
+
_onBlur === null || _onBlur === void 0 ? void 0 : _onBlur(event);
|
|
500
|
+
}
|
|
501
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onBlur = maxInputProps.onBlur) === null || _maxInputProps$onBlur === void 0 ? void 0 : _maxInputProps$onBlur.call(maxInputProps, event);
|
|
502
|
+
},
|
|
503
|
+
onMouseDown: function onMouseDown(event) {
|
|
504
|
+
var _maxInputProps$onMous;
|
|
505
|
+
if (showInputOnly) {
|
|
506
|
+
_this2.preventPopoverClose = true;
|
|
507
|
+
}
|
|
508
|
+
maxInputProps === null || maxInputProps === void 0 ? void 0 : (_maxInputProps$onMous = maxInputProps.onMouseDown) === null || _maxInputProps$onMous === void 0 ? void 0 : _maxInputProps$onMous.call(maxInputProps, event);
|
|
509
|
+
}
|
|
454
510
|
})) : undefined;
|
|
455
511
|
var classes = (0, _classnames.default)('euiDualRange', className);
|
|
456
512
|
var dualRangeStyles = (0, _dual_range.euiDualRangeStyles)();
|
|
@@ -514,8 +570,8 @@ var EuiDualRangeClass = /*#__PURE__*/function (_Component) {
|
|
|
514
570
|
"aria-hidden": true,
|
|
515
571
|
tabIndex: -1,
|
|
516
572
|
showRange: showRange,
|
|
517
|
-
onFocus:
|
|
518
|
-
onBlur:
|
|
573
|
+
onFocus: _onFocus,
|
|
574
|
+
onBlur: _onBlur
|
|
519
575
|
}, rest)), _this2.state.rangeSliderRefAvailable && (0, _react2.jsx)(_react.default.Fragment, null, isDraggable && _this2.isValid && (0, _react2.jsx)(_range_draggable.EuiRangeDraggable, {
|
|
520
576
|
min: min,
|
|
521
577
|
max: max,
|
|
@@ -14,14 +14,14 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
14
14
|
* Side Public License, v 1.
|
|
15
15
|
*/
|
|
16
16
|
var _colorCSS = function _colorCSS(color) {
|
|
17
|
-
return "\n color: ".concat(color, ";\n\n &:
|
|
17
|
+
return "\n color: ".concat(color, ";\n\n &:target {\n color: darken(").concat(color, ", 10%);\n }\n ");
|
|
18
18
|
};
|
|
19
19
|
var euiLinkHoverCSS = function euiLinkHoverCSS() {
|
|
20
20
|
return "\n text-decoration: underline;\n ";
|
|
21
21
|
};
|
|
22
22
|
exports.euiLinkHoverCSS = euiLinkHoverCSS;
|
|
23
23
|
var euiLinkFocusCSS = function euiLinkFocusCSS(euiTheme) {
|
|
24
|
-
return "\n text-decoration: underline;\n text-decoration-thickness: ".concat(euiTheme.border.width.thick, "
|
|
24
|
+
return "\n text-decoration: underline;\n text-decoration-thickness: ".concat(euiTheme.border.width.thick, ";\n ");
|
|
25
25
|
};
|
|
26
26
|
exports.euiLinkFocusCSS = euiLinkFocusCSS;
|
|
27
27
|
var euiLinkCSS = function euiLinkCSS(euiThemeContext) {
|
|
@@ -50,8 +50,8 @@ var EuiResizableCollapseButton = function EuiResizableCollapseButton(_ref) {
|
|
|
50
50
|
break;
|
|
51
51
|
}
|
|
52
52
|
return (0, _react2.jsx)(_button.EuiButtonIcon, (0, _extends2.default)({
|
|
53
|
-
display: isCollapsed ? 'empty' : '
|
|
54
|
-
color:
|
|
53
|
+
display: isCollapsed ? 'empty' : 'base',
|
|
54
|
+
color: "text"
|
|
55
55
|
}, rest, {
|
|
56
56
|
className: classes,
|
|
57
57
|
iconType: isCollapsed ? COLLAPSED_ICON : NOT_COLLAPSED_ICON
|
|
@@ -15,10 +15,17 @@ Object.defineProperty(exports, "EuiSearchBar", {
|
|
|
15
15
|
return _search_bar.EuiSearchBar;
|
|
16
16
|
}
|
|
17
17
|
});
|
|
18
|
+
Object.defineProperty(exports, "EuiSearchBarFilters", {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: function get() {
|
|
21
|
+
return _search_filters.EuiSearchBarFilters;
|
|
22
|
+
}
|
|
23
|
+
});
|
|
18
24
|
Object.defineProperty(exports, "Query", {
|
|
19
25
|
enumerable: true,
|
|
20
26
|
get: function get() {
|
|
21
27
|
return _search_bar.Query;
|
|
22
28
|
}
|
|
23
29
|
});
|
|
24
|
-
var _search_bar = require("./search_bar");
|
|
30
|
+
var _search_bar = require("./search_bar");
|
|
31
|
+
var _search_filters = require("./search_filters");
|
|
@@ -201,7 +201,7 @@ var EuiSearchBar = /*#__PURE__*/function (_Component) {
|
|
|
201
201
|
var filtersBar = !filters ? undefined : (0, _react2.jsx)(_flex.EuiFlexItem, {
|
|
202
202
|
className: "euiSearchBar__filtersHolder",
|
|
203
203
|
grow: false
|
|
204
|
-
}, (0, _react2.jsx)(_search_filters.
|
|
204
|
+
}, (0, _react2.jsx)(_search_filters.EuiSearchBarFilters, {
|
|
205
205
|
filters: filters,
|
|
206
206
|
query: query,
|
|
207
207
|
onChange: this.onFiltersChange
|