@elastic/eui 106.7.0 → 107.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (114) hide show
  1. package/dist/eui_theme_amsterdam_dark.json +36 -0
  2. package/dist/eui_theme_amsterdam_dark.json.d.ts +36 -0
  3. package/dist/eui_theme_amsterdam_light.json +36 -0
  4. package/dist/eui_theme_amsterdam_light.json.d.ts +36 -0
  5. package/dist/eui_theme_borealis_dark.json +36 -0
  6. package/dist/eui_theme_borealis_dark.json.d.ts +36 -0
  7. package/dist/eui_theme_borealis_light.json +37 -1
  8. package/dist/eui_theme_borealis_light.json.d.ts +36 -0
  9. package/es/components/badge/beta_badge/beta_badge.js +1 -0
  10. package/es/components/basic_table/basic_table.styles.js +6 -4
  11. package/es/components/bottom_bar/bottom_bar.styles.js +4 -2
  12. package/es/components/code/code_syntax.styles.js +1 -1
  13. package/es/components/collapsible_nav_beta/collapsible_nav_beta.js +1 -1
  14. package/es/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +3 -1
  15. package/es/components/flyout/flyout.styles.js +18 -7
  16. package/es/components/header/header.styles.js +3 -1
  17. package/es/components/icon/icon.js +31 -14
  18. package/es/components/icon/icon_map.js +1 -1
  19. package/es/components/page_template/inner/page_inner.styles.js +3 -1
  20. package/es/components/panel/panel.styles.js +6 -6
  21. package/es/components/table/table_row.styles.js +3 -3
  22. package/es/global_styling/mixins/_shadow.js +14 -2
  23. package/es/themes/amsterdam/global_styling/variables/_shadows.js +439 -0
  24. package/es/themes/amsterdam/theme.js +4 -1
  25. package/es/themes/json/eui_theme_amsterdam_dark.json +36 -0
  26. package/es/themes/json/eui_theme_amsterdam_light.json +36 -0
  27. package/es/themes/json/eui_theme_borealis_dark.json +36 -0
  28. package/es/themes/json/eui_theme_borealis_light.json +37 -1
  29. package/eui.d.ts +159 -4
  30. package/lib/components/badge/beta_badge/beta_badge.js +1 -0
  31. package/lib/components/basic_table/basic_table.styles.js +5 -3
  32. package/lib/components/bottom_bar/bottom_bar.styles.js +4 -2
  33. package/lib/components/code/code_syntax.styles.js +1 -1
  34. package/lib/components/collapsible_nav_beta/collapsible_nav_beta.js +1 -1
  35. package/lib/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +3 -1
  36. package/lib/components/flyout/flyout.styles.js +18 -7
  37. package/lib/components/header/header.styles.js +3 -1
  38. package/lib/components/icon/icon.js +31 -14
  39. package/lib/components/icon/icon_map.js +1 -1
  40. package/lib/components/page_template/inner/page_inner.styles.js +3 -1
  41. package/lib/components/panel/panel.styles.js +5 -5
  42. package/lib/components/table/table_row.styles.js +3 -3
  43. package/lib/global_styling/mixins/_shadow.js +18 -1
  44. package/lib/themes/amsterdam/global_styling/variables/_shadows.js +442 -0
  45. package/lib/themes/amsterdam/theme.js +4 -1
  46. package/lib/themes/json/eui_theme_amsterdam_dark.json +36 -0
  47. package/lib/themes/json/eui_theme_amsterdam_light.json +36 -0
  48. package/lib/themes/json/eui_theme_borealis_dark.json +36 -0
  49. package/lib/themes/json/eui_theme_borealis_light.json +37 -1
  50. package/optimize/es/components/badge/beta_badge/beta_badge.js +1 -0
  51. package/optimize/es/components/basic_table/basic_table.styles.js +6 -4
  52. package/optimize/es/components/bottom_bar/bottom_bar.styles.js +4 -2
  53. package/optimize/es/components/code/code_syntax.styles.js +1 -1
  54. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_beta.js +1 -1
  55. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +3 -1
  56. package/optimize/es/components/flyout/flyout.styles.js +18 -7
  57. package/optimize/es/components/header/header.styles.js +3 -1
  58. package/optimize/es/components/icon/icon.js +31 -14
  59. package/optimize/es/components/icon/icon_map.js +1 -1
  60. package/optimize/es/components/page_template/inner/page_inner.styles.js +3 -1
  61. package/optimize/es/components/panel/panel.styles.js +6 -6
  62. package/optimize/es/components/table/table_row.styles.js +3 -3
  63. package/optimize/es/global_styling/mixins/_shadow.js +14 -2
  64. package/optimize/es/themes/amsterdam/global_styling/variables/_shadows.js +436 -0
  65. package/optimize/es/themes/amsterdam/theme.js +4 -1
  66. package/optimize/es/themes/json/eui_theme_amsterdam_dark.json +36 -0
  67. package/optimize/es/themes/json/eui_theme_amsterdam_light.json +36 -0
  68. package/optimize/es/themes/json/eui_theme_borealis_dark.json +36 -0
  69. package/optimize/es/themes/json/eui_theme_borealis_light.json +37 -1
  70. package/optimize/lib/components/badge/beta_badge/beta_badge.js +1 -0
  71. package/optimize/lib/components/basic_table/basic_table.styles.js +5 -3
  72. package/optimize/lib/components/bottom_bar/bottom_bar.styles.js +4 -2
  73. package/optimize/lib/components/code/code_syntax.styles.js +1 -1
  74. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_beta.js +1 -1
  75. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +3 -1
  76. package/optimize/lib/components/flyout/flyout.styles.js +18 -7
  77. package/optimize/lib/components/header/header.styles.js +3 -1
  78. package/optimize/lib/components/icon/icon.js +31 -14
  79. package/optimize/lib/components/icon/icon_map.js +1 -1
  80. package/optimize/lib/components/page_template/inner/page_inner.styles.js +3 -1
  81. package/optimize/lib/components/panel/panel.styles.js +5 -5
  82. package/optimize/lib/components/table/table_row.styles.js +3 -3
  83. package/optimize/lib/global_styling/mixins/_shadow.js +18 -1
  84. package/optimize/lib/themes/amsterdam/global_styling/variables/_shadows.js +440 -0
  85. package/optimize/lib/themes/amsterdam/theme.js +4 -1
  86. package/optimize/lib/themes/json/eui_theme_amsterdam_dark.json +36 -0
  87. package/optimize/lib/themes/json/eui_theme_amsterdam_light.json +36 -0
  88. package/optimize/lib/themes/json/eui_theme_borealis_dark.json +36 -0
  89. package/optimize/lib/themes/json/eui_theme_borealis_light.json +37 -1
  90. package/package/eui.d.ts +33359 -0
  91. package/package.json +5 -5
  92. package/src/themes/amsterdam/global_styling/mixins/_index.scss +1 -1
  93. package/src/themes/amsterdam/global_styling/mixins/_shadow.scss +100 -0
  94. package/src/themes/amsterdam/global_styling/variables/_index.scss +1 -0
  95. package/src/themes/amsterdam/global_styling/variables/_shadows.scss +20 -0
  96. package/test-env/components/badge/beta_badge/beta_badge.js +1 -0
  97. package/test-env/components/basic_table/basic_table.styles.js +5 -3
  98. package/test-env/components/bottom_bar/bottom_bar.styles.js +4 -2
  99. package/test-env/components/code/code_syntax.styles.js +1 -1
  100. package/test-env/components/collapsible_nav_beta/collapsible_nav_beta.js +1 -1
  101. package/test-env/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +3 -1
  102. package/test-env/components/flyout/flyout.styles.js +18 -7
  103. package/test-env/components/header/header.styles.js +3 -1
  104. package/test-env/components/icon/icon_map.js +1 -1
  105. package/test-env/components/page_template/inner/page_inner.styles.js +3 -1
  106. package/test-env/components/panel/panel.styles.js +5 -5
  107. package/test-env/components/table/table_row.styles.js +3 -3
  108. package/test-env/global_styling/mixins/_shadow.js +18 -1
  109. package/test-env/themes/amsterdam/global_styling/variables/_shadows.js +440 -0
  110. package/test-env/themes/amsterdam/theme.js +4 -1
  111. package/test-env/themes/json/eui_theme_amsterdam_dark.json +36 -0
  112. package/test-env/themes/json/eui_theme_amsterdam_light.json +36 -0
  113. package/test-env/themes/json/eui_theme_borealis_dark.json +36 -0
  114. package/test-env/themes/json/eui_theme_borealis_light.json +37 -1
@@ -56,7 +56,7 @@ var euiCodeSyntaxVariables = exports.euiCodeSyntaxVariables = function euiCodeSy
56
56
  selectorClassColor: euiTheme.components.codeSelectorClassColor,
57
57
  selectorIdColor: euiTheme.components.codeSelectorIdColor,
58
58
  get tokensCss() {
59
- return "\n .token.punctuation:not(.interpolation-punctuation):not([class*='attr-']) {\n opacity: ".concat(highContrastMode ? '1' : '.7', ";\n }\n\n .token.comment,\n .token.prolog,\n .token.doctype,\n .token.cdata,\n .token.coord,\n .token.blockquote {\n color: ").concat(this.commentColor, ";\n font-style: italic;\n }\n\n .token.selector {\n color: ").concat(this.selectorTagColor, ";\n }\n\n .token.string,\n .token.interpolation,\n .token.interpolation-punctuation,\n .token.doc-comment .token.keyword,\n .token.attr-value,\n .token.url .token.content {\n color: ").concat(this.stringColor, ";\n }\n\n .token.number,\n .token.boolean,\n .token.keyword.nil,\n .token.regex,\n .token.variable,\n .token.unit,\n .token.hexcode,\n .token.attr-name,\n .token.attr-equals {\n color: ").concat(this.numberColor, ";\n }\n\n .token.atrule .token.rule,\n .token.keyword {\n color: ").concat(this.keywordColor, ";\n }\n\n .token.function {\n color: ").concat(this.functionTitleColor, ";\n }\n\n .token.tag {\n color: ").concat(this.tagColor, ";\n }\n\n .token.class-name {\n color: ").concat(this.typeColor, ";\n }\n\n .token.property {\n color: ").concat(this.attributeColor, ";\n }\n\n .token.console,\n .token.list-punctuation,\n .token.url-reference,\n .token.url .token.url {\n color: ").concat(this.symbolColor, ";\n }\n\n .token.paramater {\n color: ").concat(this.paramsColor, ";\n }\n\n .token.meta,\n .token.important {\n color: ").concat(this.metaColor, ";\n }\n\n .token.title {\n color: ").concat(this.titleColor, ";\n }\n\n .token.section {\n color: ").concat(this.sectionColor, ";\n }\n\n .token.prefix.inserted,\n .token.prefix.deleted {\n padding-inline-start: -").concat(euiTheme.size.xs, ";\n margin-inline-start: -").concat(euiTheme.size.xs, ";\n }\n\n .token.prefix.inserted {\n box-shadow: -").concat(euiTheme.size.xs, " 0 ").concat(this.additionColor, ";\n color: ").concat(this.additionColor, ";\n }\n\n .token.prefix.deleted {\n box-shadow: -").concat(euiTheme.size.xs, " 0 ").concat(this.deletionColor, ";\n color: ").concat(this.deletionColor, ";\n }\n\n .token.selector .token.class {\n color: ").concat(this.selectorClassColor, ";\n }\n\n .token.selector .token.id {\n color: ").concat(this.selectorIdColor, ";\n }\n\n .token.italic {\n font-style: italic;\n }\n\n .token.important,\n .token.bold {\n font-weight: ").concat(euiTheme.font.weight.bold, ";\n }\n\n .token.url-reference,\n .token.url .token.url {\n text-decoration: underline;\n }\n\n .token.entity {\n cursor: help;\n }");
59
+ return "\n .token.punctuation:not(.interpolation-punctuation):not([class*='attr-']) {\n opacity: ".concat(highContrastMode ? '1' : '.7', ";\n }\n\n .token.comment,\n .token.prolog,\n .token.doctype,\n .token.cdata,\n .token.coord,\n .token.blockquote {\n color: ").concat(this.commentColor, ";\n font-style: italic;\n }\n\n .token.selector {\n color: ").concat(this.selectorTagColor, ";\n }\n\n .token.string,\n .token.interpolation,\n .token.interpolation-punctuation,\n .token.doc-comment .token.keyword,\n .token.attr-value,\n .token.url .token.content {\n color: ").concat(this.stringColor, ";\n }\n\n .token.number,\n .token.boolean,\n .token.keyword.nil,\n .token.regex,\n .token.variable,\n .token.unit,\n .token.hexcode,\n .token.attr-name,\n .token.attr-equals {\n color: ").concat(this.numberColor, ";\n }\n\n .token.atrule .token.rule,\n .token.key.atrule,\n .token.keyword {\n color: ").concat(this.keywordColor, ";\n }\n\n .token.function {\n color: ").concat(this.functionTitleColor, ";\n }\n\n .token.tag {\n color: ").concat(this.tagColor, ";\n }\n\n .token.class-name {\n color: ").concat(this.typeColor, ";\n }\n\n .token.property {\n color: ").concat(this.attributeColor, ";\n }\n\n .token.console,\n .token.list-punctuation,\n .token.url-reference,\n .token.url .token.url {\n color: ").concat(this.symbolColor, ";\n }\n\n .token.paramater {\n color: ").concat(this.paramsColor, ";\n }\n\n .token.meta,\n .token.important {\n color: ").concat(this.metaColor, ";\n }\n\n .token.title {\n color: ").concat(this.titleColor, ";\n }\n\n .token.section {\n color: ").concat(this.sectionColor, ";\n }\n\n .token.prefix.inserted,\n .token.prefix.deleted {\n padding-inline-start: -").concat(euiTheme.size.xs, ";\n margin-inline-start: -").concat(euiTheme.size.xs, ";\n }\n\n .token.prefix.inserted {\n box-shadow: -").concat(euiTheme.size.xs, " 0 ").concat(this.additionColor, ";\n color: ").concat(this.additionColor, ";\n }\n\n .token.prefix.deleted {\n box-shadow: -").concat(euiTheme.size.xs, " 0 ").concat(this.deletionColor, ";\n color: ").concat(this.deletionColor, ";\n }\n\n .token.selector .token.class {\n color: ").concat(this.selectorClassColor, ";\n }\n\n .token.selector .token.id {\n color: ").concat(this.selectorIdColor, ";\n }\n\n .token.italic {\n font-style: italic;\n }\n\n .token.important,\n .token.bold {\n font-weight: ").concat(euiTheme.font.weight.bold, ";\n }\n\n .token.url-reference,\n .token.url .token.url {\n text-decoration: underline;\n }\n\n .token.entity {\n cursor: help;\n }");
60
60
  }
61
61
  };
62
62
  };
@@ -151,7 +151,7 @@ var _EuiCollapsibleNavBeta = function _EuiCollapsibleNavBeta(_ref) {
151
151
  }, [_focusTrapProps]);
152
152
  var classes = (0, _classnames.default)('euiCollapsibleNav', 'euiCollapsibleNavBeta', className);
153
153
  var styles = (0, _services.useEuiMemoizedStyles)(_collapsible_nav_beta.euiCollapsibleNavBetaStyles);
154
- var cssStyles = [styles.euiCollapsibleNavBeta, styles[side], isPush && styles.isPush, isPush && isCollapsed && styles.isPushCollapsed, isOverlayFullWidth && styles.isOverlayFullWidth];
154
+ var cssStyles = [styles.euiCollapsibleNavBeta, isPush && styles.isPush, styles[side], isPush && isCollapsed && styles.isPushCollapsed, isOverlayFullWidth && styles.isOverlayFullWidth];
155
155
  var flyout = (0, _react2.jsx)(_flyout.EuiFlyout, (0, _extends2.default)({
156
156
  "aria-label": defaultAriaLabel
157
157
  }, rest, {
@@ -29,7 +29,9 @@ var euiCollapsibleNavBetaStyles = exports.euiCollapsibleNavBetaStyles = function
29
29
  euiCollapsibleNavBeta: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('top', fixedHeaderOffset), (0, _global_styling.logicalCSS)('padding-bottom', euiTheme.size.xs), ";;label:euiCollapsibleNavBeta;"),
30
30
  left: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('border-right', euiTheme.border.thin), ";;label:left;"),
31
31
  right: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('border-left', euiTheme.border.thin), ";;label:right;"),
32
- isPush: /*#__PURE__*/(0, _react.css)((0, _themes.euiShadowFlat)(euiThemeContext), ";;label:isPush;"),
32
+ isPush: /*#__PURE__*/(0, _react.css)((0, _themes.euiShadowFlat)(euiThemeContext, {
33
+ border: 'none'
34
+ }), ";;label:isPush;"),
33
35
  isPushCollapsed: /*#__PURE__*/(0, _react.css)(_collapsible_nav_body_footer.hideScrollbars, ";;label:isPushCollapsed;"),
34
36
  isOverlayFullWidth: /*#__PURE__*/(0, _react.css)("&.euiFlyout{", (0, _global_styling.logicalCSS)('max-width', '100% !important'), ";};label:isOverlayFullWidth;")
35
37
  };
@@ -29,9 +29,16 @@ var _ref = process.env.NODE_ENV === "production" ? {
29
29
  styles: "animation-duration:0s!important;label:noAnimation;",
30
30
  toString: _EMOTION_STRINGIFIED_CSS_ERROR__
31
31
  };
32
+ var _ref2 = process.env.NODE_ENV === "production" ? {
33
+ name: "rks1ev-overlay",
34
+ styles: "&:has(.euiResizableButton){border-inline:none;};label:overlay;"
35
+ } : {
36
+ name: "rks1ev-overlay",
37
+ styles: "&:has(.euiResizableButton){border-inline:none;};label:overlay;",
38
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
39
+ };
32
40
  var euiFlyoutStyles = exports.euiFlyoutStyles = function euiFlyoutStyles(euiThemeContext) {
33
- var euiTheme = euiThemeContext.euiTheme,
34
- colorMode = euiThemeContext.colorMode;
41
+ var euiTheme = euiThemeContext.euiTheme;
35
42
  return {
36
43
  euiFlyout: /*#__PURE__*/(0, _react.css)("position:fixed;", (0, _global_styling.logicalCSS)('bottom', 0), " ", (0, _global_styling.logicalCSS)('top', 'var(--euiFixedHeadersOffset, 0)'), " ", (0, _global_styling.logicalCSS)('height', 'inherit'), " z-index:", euiTheme.levels.flyout, ";background:", euiTheme.colors.emptyShade, ";display:flex;flex-direction:column;align-items:stretch;&:focus{outline:none;}", maxedFlyoutWidth(euiThemeContext), ";;label:euiFlyout;"),
37
44
  // Flyout sizes
@@ -46,11 +53,15 @@ var euiFlyoutStyles = exports.euiFlyoutStyles = function euiFlyoutStyles(euiThem
46
53
  left: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('left', 0), " clip-path:polygon(0 0, 150% 0, 150% 100%, 0 100%);", _global_styling.euiCanAnimate, "{animation:", euiFlyoutSlideInLeft, " ", euiTheme.animation.normal, " ", euiTheme.animation.resistance, ";};label:left;"),
47
54
  // Type
48
55
  overlay: {
49
- overlay: /*#__PURE__*/(0, _react.css)((0, _euiThemeCommon.euiShadowXLarge)(euiThemeContext, {
50
- borderAllInHighContrastMode: true
51
- }), " &:has(.euiResizableButton){border-inline:none;};label:overlay;"),
52
- left: /*#__PURE__*/(0, _react.css)("border-inline-end:", colorMode === 'DARK' ? "".concat(euiTheme.border.width.thin, " solid\n ").concat(euiTheme.colors.borderBaseFloating) : 'none', ";;label:left;"),
53
- right: /*#__PURE__*/(0, _react.css)("border-inline-start:", colorMode === 'DARK' ? "".concat(euiTheme.border.width.thin, " solid\n ").concat(euiTheme.colors.borderBaseFloating) : 'none', ";;label:right;")
56
+ overlay: _ref2,
57
+ left: /*#__PURE__*/(0, _react.css)((0, _euiThemeCommon.euiShadowXLarge)(euiThemeContext, {
58
+ borderAllInHighContrastMode: true,
59
+ border: 'right'
60
+ }), ";;label:left;"),
61
+ right: /*#__PURE__*/(0, _react.css)((0, _euiThemeCommon.euiShadowXLarge)(euiThemeContext, {
62
+ borderAllInHighContrastMode: true,
63
+ border: 'left'
64
+ }), ";;label:right;")
54
65
  },
55
66
  push: {
56
67
  push: /*#__PURE__*/(0, _react.css)("clip-path:none;z-index:", Number(euiTheme.levels.flyout) - 1, ";;label:push;"),
@@ -31,7 +31,9 @@ var euiHeaderStyles = exports.euiHeaderStyles = function euiHeaderStyles(euiThem
31
31
  height = _euiHeaderVariables.height,
32
32
  padding = _euiHeaderVariables.padding;
33
33
  return {
34
- euiHeader: /*#__PURE__*/(0, _react.css)("display:flex;justify-content:space-between;", (0, _global_styling.logicalCSS)('height', height), " ", (0, _global_styling.logicalCSS)('padding-horizontal', padding), " ", (0, _global_styling.logicalCSS)('border-bottom', euiTheme.border.thin), " ", (0, _euiThemeCommon.euiShadowXSmall)(euiThemeContext), ";;label:euiHeader;"),
34
+ euiHeader: /*#__PURE__*/(0, _react.css)("display:flex;justify-content:space-between;", (0, _global_styling.logicalCSS)('height', height), " ", (0, _global_styling.logicalCSS)('padding-horizontal', padding), " ", (0, _global_styling.logicalCSS)('border-bottom', euiTheme.border.thin), " ", (0, _euiThemeCommon.euiShadowXSmall)(euiThemeContext, {
35
+ border: 'none'
36
+ }), "&+.euiHeader{clip-path:polygon(0 0, 100% 0, 100% 100vh, 0 100vh);};label:euiHeader;"),
35
37
  // Position
36
38
  static: /*#__PURE__*/(0, _react.css)("z-index:", Number(euiTheme.levels.header) - 1, ";position:relative;;label:static;"),
37
39
  fixed: /*#__PURE__*/(0, _react.css)("z-index:", Number(euiTheme.levels.header) + 1, ";position:fixed;", (0, _global_styling.logicalCSS)('top', 0), " ", (0, _global_styling.logicalCSS)('horizontal', 0), ";;label:fixed;"),
@@ -30,7 +30,7 @@ var _services = require("../../services");
30
30
  var _named_colors = require("./named_colors");
31
31
  var _icon = require("./icon.styles");
32
32
  var _react3 = require("@emotion/react");
33
- var _excluded = ["type", "size", "color", "className", "tabIndex", "title", "onIconLoad", "style", "stylesMemoizer"];
33
+ var _excluded = ["type", "size", "color", "className", "tabIndex", "title", "role", "onIconLoad", "style", "stylesMemoizer", "aria-hidden", "titleId"];
34
34
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
35
35
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
36
36
  function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
@@ -194,9 +194,12 @@ var EuiIconClass = exports.EuiIconClass = /*#__PURE__*/function (_PureComponent)
194
194
  className = _this$props.className,
195
195
  tabIndex = _this$props.tabIndex,
196
196
  title = _this$props.title,
197
+ role = _this$props.role,
197
198
  onIconLoad = _this$props.onIconLoad,
198
199
  style = _this$props.style,
199
200
  stylesMemoizer = _this$props.stylesMemoizer,
201
+ ariaHidden = _this$props['aria-hidden'],
202
+ titleId = _this$props.titleId,
200
203
  rest = (0, _objectWithoutProperties2.default)(_this$props, _excluded);
201
204
  var _this$state = this.state,
202
205
  isLoading = _this$state.isLoading,
@@ -221,41 +224,55 @@ var EuiIconClass = exports.EuiIconClass = /*#__PURE__*/function (_PureComponent)
221
224
  var styles = stylesMemoizer(_icon.euiIconStyles);
222
225
  var cssStyles = [styles.euiIcon, styles[size], color && (0, _named_colors.isNamedColor)(color) && styles[color], isCustomColor && styles.customColor, isElasticLogoOutline && styles.logoElasticOutline, isAppIcon && !appIconHasColor && styles.app, isLoading && styles.isLoading, !isLoading && neededLoading && styles.isLoaded];
223
226
  var icon = this.state.icon || _empty.icon;
227
+ var isAriaHidden = [true, 'true'].includes(ariaHidden !== null && ariaHidden !== void 0 ? ariaHidden : false);
228
+ var isPresentationOnly = !(title || this.props['aria-label'] || this.props['aria-labelledby']) || ['none', 'presentation'].includes(role !== null && role !== void 0 ? role : '') || isAriaHidden;
229
+ var accessibleTitle = isPresentationOnly ? undefined : title;
230
+
231
+ // implicitly set the ARIA role for the icon only if:
232
+ // - The user did NOT provide a `role` prop
233
+ // - `aria-hidden` is NOT true
234
+ // This ensures user-supplied `role` and `aria-hidden` always take precedence.
235
+ // If set, role is:
236
+ // - 'presentation' for decorative icons
237
+ // - 'img' for meaningful icons
238
+ var accessibleRole = function () {
239
+ if (isAriaHidden) return undefined;
240
+ if (isPresentationOnly) return 'presentation';
241
+ return 'img';
242
+ }();
224
243
  if (typeof icon === 'string') {
225
244
  return (0, _react3.jsx)("img", (0, _extends2.default)({
226
- alt: title ? title : '',
245
+ alt: accessibleTitle,
227
246
  src: icon,
228
247
  className: classes,
229
248
  css: cssStyles,
230
249
  style: style,
231
- tabIndex: tabIndex
250
+ tabIndex: tabIndex,
251
+ role: role !== null && role !== void 0 ? role : accessibleRole,
252
+ "aria-hidden": ariaHidden
232
253
  }, rest));
233
254
  } else {
234
255
  var Svg = icon;
235
256
 
236
- // If there is no aria-label, aria-labelledby, or title it gets aria-hidden true
237
- var isAriaHidden = !(this.props['aria-label'] || this.props['aria-labelledby'] || this.props.title);
238
-
239
257
  // If no aria-label or aria-labelledby is provided but there's a title, a titleId is generated
240
258
  // The svg aria-labelledby attribute gets this titleId
241
259
  // The svg title element gets this titleId as an id
242
- var titleId = !this.props['aria-label'] && !this.props['aria-labelledby'] && title ? {
243
- titleId: generateId()
260
+ var accessibleTitleId = !this.props['aria-label'] && !this.props['aria-labelledby'] && title ? {
261
+ titleId: titleId || generateId()
244
262
  } : undefined;
245
263
  return (0, _react3.jsx)(Svg, (0, _extends2.default)({
246
264
  className: classes,
247
265
  style: optionalCustomStyles,
248
266
  css: cssStyles,
249
267
  tabIndex: tabIndex,
250
- role: "img",
251
- title: title
252
- }, titleId, {
268
+ title: accessibleTitle,
269
+ role: role !== null && role !== void 0 ? role : accessibleRole,
270
+ "aria-hidden": ariaHidden
271
+ }, accessibleTitleId, {
253
272
  "data-icon-type": iconTitle,
254
273
  "data-is-loaded": isLoaded || undefined,
255
274
  "data-is-loading": isLoading || undefined
256
- }, rest, {
257
- "aria-hidden": isAriaHidden || rest['aria-hidden']
258
- }));
275
+ }, rest));
259
276
  }
260
277
  }
261
278
  }]);
@@ -507,7 +507,7 @@ var typeToPathMap = exports.typeToPathMap = {
507
507
  vulnerabilityManagementApp: 'app_vulnerability_management',
508
508
  warning: 'warning',
509
509
  warningFilled: 'warning',
510
- // NOTE: To be deprecated in favor of `export`
510
+ // NOTE: To be deprecated in favor of `warning`
511
511
  watchesApp: 'app_watches',
512
512
  web: 'web',
513
513
  wordWrap: 'wordWrap',
@@ -19,7 +19,9 @@ var euiPageInnerStyles = exports.euiPageInnerStyles = function euiPageInnerStyle
19
19
  var euiTheme = euiThemeContext.euiTheme;
20
20
  return {
21
21
  euiPageInner: /*#__PURE__*/(0, _react.css)("display:flex;flex-direction:column;align-items:stretch;flex:1 1 100%;", (0, _global_styling.logicalCSS)('max-width', '100%'), " ", (0, _global_styling.logicalCSS)('min-width', '0'), ";;label:euiPageInner;"),
22
- panelled: /*#__PURE__*/(0, _react.css)("background:", euiThemeContext.euiTheme.colors.backgroundBasePlain, ";", (0, _euiThemeCommon.euiShadow)(euiThemeContext, 'm'), ";;label:panelled;"),
22
+ panelled: /*#__PURE__*/(0, _react.css)("background:", euiThemeContext.euiTheme.colors.backgroundBasePlain, ";", (0, _euiThemeCommon.euiShadow)(euiThemeContext, 'm', {
23
+ border: 'none'
24
+ }), ";;label:panelled;"),
23
25
  border: {
24
26
  top: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('border-top', euiTheme.border.thin), ";;label:top;"),
25
27
  left: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('border-left', euiTheme.border.thin), ";;label:left;")
@@ -27,7 +27,9 @@ var euiPanelBorderStyles = exports.euiPanelBorderStyles = function euiPanelBorde
27
27
  euiTheme.colors.borderBaseFloating is enough then */
28
28
  var hasVisibleBorder = hasFloatingBorder && colorMode === 'DARK';
29
29
  return (0, _high_contrast.highContrastModeStyles)(euiThemeContext, {
30
- none: "\n /* Using a pseudo element for the border instead of floating border only \n because the transparent border might otherwise be visible with arbitrary \n full-width/height content in light mode. */\n &::after {\n content: '';\n position: absolute;\n /* ensure to keep on top of flush content */\n z-index: 0;\n inset: 0;\n border: ".concat(euiTheme.border.width.thin, " solid\n ").concat((borderColor !== null && borderColor !== void 0 ? borderColor : hasVisibleBorder) ? euiTheme.border.color : euiTheme.colors.borderBaseFloating, ";\n border-radius: inherit;\n pointer-events: none;\n }\n "),
30
+ none: "\n /* Using a pseudo element for the border instead of floating border only\n because the transparent border might otherwise be visible with arbitrary\n full-width/height content in light mode. */\n ".concat((0, _euiThemeCommon.euiBorderStyles)(euiThemeContext, {
31
+ borderColor: (borderColor !== null && borderColor !== void 0 ? borderColor : hasVisibleBorder) ? euiTheme.border.color : euiTheme.colors.borderBaseFloating
32
+ }), "\n "),
31
33
  preferred: "\n border: ".concat(euiTheme.border.thin, ";\n ")
32
34
  });
33
35
  };
@@ -53,9 +55,7 @@ var euiPanelStyles = exports.euiPanelStyles = function euiPanelStyles(euiThemeCo
53
55
  // Base
54
56
  euiPanel: _ref2,
55
57
  grow: _ref,
56
- hasShadow: /*#__PURE__*/(0, _react.css)((0, _euiThemeCommon.euiShadow)(euiThemeContext, 'm'), " ", euiPanelBorderStyles(euiThemeContext, {
57
- hasFloatingBorder: false
58
- }), ";;label:hasShadow;"),
58
+ hasShadow: /*#__PURE__*/(0, _react.css)((0, _euiThemeCommon.euiShadow)(euiThemeContext, 'm'), ";;label:hasShadow;"),
59
59
  hasBorder: /*#__PURE__*/(0, _react.css)(euiPanelBorderStyles(euiThemeContext, {
60
60
  borderColor: euiTheme.border.color,
61
61
  hasFloatingBorder: false
@@ -66,7 +66,7 @@ var euiPanelStyles = exports.euiPanelStyles = function euiPanelStyles(euiThemeCo
66
66
  },
67
67
  // Setup interactive behavior
68
68
  isClickable: /*#__PURE__*/(0, _react.css)(_global_styling.euiCanAnimate, "{transition:box-shadow ", euiTheme.animation.fast, " ", euiTheme.animation.resistance, ",transform ", euiTheme.animation.fast, " ", euiTheme.animation.resistance, ";}&:enabled{display:block;", (0, _global_styling.logicalCSS)('width', '100%'), " ", (0, _global_styling.logicalTextAlignCSS)('left'), ";}&:hover,&:focus{", (0, _high_contrast.highContrastModeStyles)(euiThemeContext, {
69
- none: (0, _euiThemeCommon.euiShadow)(euiThemeContext, 'l'),
69
+ none: (0, _euiThemeCommon.euiShadowHover)(euiThemeContext, 'l'),
70
70
  // Windows high contrast themes ignore box-shadows - use a filter workaround instead
71
71
  preferred: "\n &:not(.euiPanel--transparent) {\n filter: drop-shadow(0 ".concat(euiTheme.border.width.thick, " 0 ").concat(euiTheme.border.color, ");\n }\n ")
72
72
  }), " transform:translateY(-2px);cursor:pointer;};label:isClickable;")
@@ -53,7 +53,7 @@ var euiTableRowStyles = exports.euiTableRowStyles = function euiTableRowStyles(e
53
53
  * Right column styles + border
54
54
  * Used for cell actions and row expander arrow
55
55
  */
56
- hasRightColumn: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('padding-right', mobileSizes.actions.width), " &::after{content:'';position:absolute;", (0, _global_styling.logicalCSS)('vertical', 0), " ", (0, _global_styling.logicalCSS)('right', mobileSizes.actions.width), " ", (0, _global_styling.logicalCSS)('border-right', euiTheme.border.thin), ";};label:hasRightColumn;"),
56
+ hasRightColumn: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('padding-right', mobileSizes.actions.width), " &::before{content:'';position:absolute;", (0, _global_styling.logicalCSS)('vertical', 0), " ", (0, _global_styling.logicalCSS)('right', mobileSizes.actions.width), " ", (0, _global_styling.logicalCSS)('border-right', euiTheme.border.thin), ";};label:hasRightColumn;"),
57
57
  /**
58
58
  * Bottom of card - expanded rows
59
59
  */
@@ -61,8 +61,8 @@ var euiTableRowStyles = exports.euiTableRowStyles = function euiTableRowStyles(e
61
61
  // On mobile, visually move the expanded row to join up with the
62
62
  // preceding table row via negative margins
63
63
  'margin-top', (0, _global_styling.mathWithUnits)([cellContentPadding, euiTheme.border.width.thin], function (x, y) {
64
- return (x + y) * -1;
65
- })), (0, _global_styling.logicalCSS)('padding-left', cellContentPadding), " ", (0, _global_styling.logicalCSS)('border-top', euiTheme.border.thin), " ", (0, _global_styling.logicalCSS)('border-top-left-radius', 0), " ", (0, _global_styling.logicalCSS)('border-top-right-radius', 0), ">.euiTableRowCell{", (0, _global_styling.logicalCSS)('width', '100%'), ";}", expandedAnimationCss, ";;label:expanded;")
64
+ return (x + y * 2) * -1;
65
+ })), (0, _global_styling.logicalCSS)('padding-left', cellContentPadding), " ", (0, _global_styling.logicalCSS)('border-top', euiTheme.border.thin), " ", (0, _global_styling.logicalCSS)('border-top-left-radius', 0), " ", (0, _global_styling.logicalCSS)('border-top-right-radius', 0), " &:after{", (0, _global_styling.logicalCSS)('border-top', 'none'), ";}clip-path:polygon(-50% 0, 150% 0, 150% 100vh, -50% 100vh);>.euiTableRowCell{", (0, _global_styling.logicalCSS)('width', '100%'), ";}", expandedAnimationCss, ";;label:expanded;")
66
66
  }
67
67
  };
68
68
  };
@@ -15,6 +15,12 @@ Object.defineProperty(exports, "euiShadowFlat", {
15
15
  return _euiThemeCommon.euiShadowFlat;
16
16
  }
17
17
  });
18
+ Object.defineProperty(exports, "euiShadowHover", {
19
+ enumerable: true,
20
+ get: function get() {
21
+ return _euiThemeCommon.euiShadowHover;
22
+ }
23
+ });
18
24
  Object.defineProperty(exports, "euiShadowLarge", {
19
25
  enumerable: true,
20
26
  get: function get() {
@@ -51,7 +57,7 @@ Object.defineProperty(exports, "euiSlightShadowHover", {
51
57
  return _euiThemeCommon.euiSlightShadowHover;
52
58
  }
53
59
  });
54
- exports.useEuiSlightShadowHover = exports.useEuiShadowFlat = exports.useEuiShadow = void 0;
60
+ exports.useEuiSlightShadowHover = exports.useEuiShadowHover = exports.useEuiShadowFlat = exports.useEuiShadow = void 0;
55
61
  var _euiThemeCommon = require("@elastic/eui-theme-common");
56
62
  var _theme = require("../../services/theme");
57
63
  /*
@@ -62,10 +68,15 @@ var _theme = require("../../services/theme");
62
68
  * Side Public License, v 1.
63
69
  */
64
70
 
71
+ /** @deprecated */
72
+
73
+ /** @deprecated use euiShadowHover/useEuiShadowHover instead */
65
74
  var useEuiSlightShadowHover = exports.useEuiSlightShadowHover = function useEuiSlightShadowHover(options) {
66
75
  var euiThemeContext = (0, _theme.useEuiTheme)();
67
76
  return (0, _euiThemeCommon.euiSlightShadowHover)(euiThemeContext, options);
68
77
  };
78
+
79
+ /** @deprecated - useEuiShadow instead */
69
80
  var useEuiShadowFlat = exports.useEuiShadowFlat = function useEuiShadowFlat(options) {
70
81
  var euiThemeContext = (0, _theme.useEuiTheme)();
71
82
  return (0, _euiThemeCommon.euiShadowFlat)(euiThemeContext, options);
@@ -75,4 +86,10 @@ var useEuiShadow = exports.useEuiShadow = function useEuiShadow() {
75
86
  var options = arguments.length > 1 ? arguments[1] : undefined;
76
87
  var euiThemeContext = (0, _theme.useEuiTheme)();
77
88
  return (0, _euiThemeCommon.euiShadow)(euiThemeContext, size, options);
89
+ };
90
+ var useEuiShadowHover = exports.useEuiShadowHover = function useEuiShadowHover() {
91
+ var size = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'l';
92
+ var options = arguments.length > 1 ? arguments[1] : undefined;
93
+ var euiThemeContext = (0, _theme.useEuiTheme)();
94
+ return (0, _euiThemeCommon.euiShadowHover)(euiThemeContext, size, options);
78
95
  };