From d079e9573d19e098e61effe619a93c50246f726a Mon Sep 17 00:00:00 2001
From: Cee Chen <549407+cee-chen@users.noreply.github.com>
Date: Fri, 3 Nov 2023 10:19:31 -0700
Subject: [PATCH] Upgrade EUI to v90.0.0 (#170179)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
`v89.1.0`⏩`v90.0.0`
The majority of changes in this PR come from:
- **EuiContextMenu** being converted to Emotion
(https://github.com/elastic/eui/pull/7312). If your usage of
`EuiContextMenu` was significantly affected, we recommend pulling down
this PR and QAing it locally.
- `defaultProps` being removed from some very widespread components,
particularly **EuiButton**, in anticipation of React's upcoming
deprecation.
(https://github.com/elastic/eui/commit/b7dc9b4e896c552bec6c0c6b53103643ad9bbe6d)
**NOTE**: This only affected Enzyme snapshots, and did not affect
production behavior.
[Commits](https://github.com/elastic/kibana/pull/170179/commits) have
been broken up by component changes as well as types of changes.
---
## [`90.0.0`](https://github.com/elastic/eui/tree/v90.0.0)
- Updated the `eventColor` prop on `EuiCommentEvent` to apply the color
to the entire comment header.
([#7288](https://github.com/elastic/eui/pull/7288))
- Updated `EuiBasicTable` and `EuiInMemoryTable` to support a new
controlled selection API: `selection.selected`
([#7321](https://github.com/elastic/eui/pull/7321))
**Bug fixes**
- Fixed controlled `EuiFieldNumbers` not correctly updating native
validity state ([#7291](https://github.com/elastic/eui/pull/7291))
- Fixed `EuiListGroupItem` to pass `style` props to the wrapping `
`
element alongside `className` and `css`. All other props will be passed
to the underlying content.
([#7298](https://github.com/elastic/eui/pull/7298))
- Fixed `EuiListGroupItem`'s non-transitioned transform on hover/focus
([#7298](https://github.com/elastic/eui/pull/7298))
- Fixed `EuiDataGrid`s with `gridStyle.stripes` sometimes showing buggy
row striping after being sorted
([#7301](https://github.com/elastic/eui/pull/7301))
- Fixed `EuiDataGrid`'s `gridStyle.rowClasses` API to not conflict with
`gridStyle.stripes` if dynamically updated
([#7301](https://github.com/elastic/eui/pull/7301))
- Fixed `EuiDataGrid`'s `gridStyle.rowClasses` API to support multiple
space-separated classes
([#7301](https://github.com/elastic/eui/pull/7301))
- Fixed `EuiInputPopover` not calling `onPanelResize` callback prop
([#7305](https://github.com/elastic/eui/pull/7305))
- Fixed `EuiDualRange` incorrectly positioning highlights when rendered
with `showInput="inputWithPopover"`
([#7305](https://github.com/elastic/eui/pull/7305))
- Fixed `EuiTabs` incorrectly wrapping text when it should instead
either scroll or truncate
([#7309](https://github.com/elastic/eui/pull/7309))
- `EuiContextMenu` now renders text colors correctly when used within an
`EuiBottomBar` ([#7312](https://github.com/elastic/eui/pull/7312))
- Fixed the width of `EuiSuperDatePicker`'s Absolute date picker
([#7313](https://github.com/elastic/eui/pull/7313))
- Fixed `EuiDataGrid` cells visually cutting off overflowing content a
little too quickly ([#7320](https://github.com/elastic/eui/pull/7320))
**Deprecations**
- Deprecated `EuiBasicTable` and `EuiInMemoryTable`'s ref `setSelection`
API. Use the new `selection.selected` API instead.
([#7321](https://github.com/elastic/eui/pull/7321))
**Breaking changes**
- Removed `EuiPageTemplate_Deprecated`, `EuiPageSideBar_Deprecated`, and
`EuiPageContent*_Deprecated`
([#7265](https://github.com/elastic/eui/pull/7265))
- Removed the `ghost` color option from `EuiButton`, `EuiButtonEmpty`,
and `EuiButtonIcon`. Use an ``
wrapper and `color="text"` instead.
([#7296](https://github.com/elastic/eui/pull/7296))
**Dependency updates**
- Updated `refractor` to v3.6.0
([#7127](https://github.com/elastic/eui/pull/7127))
- Updated `rehype-raw` to v5.1.0
([#7127](https://github.com/elastic/eui/pull/7127))
- Updated `vfile` to v4.2.1
([#7127](https://github.com/elastic/eui/pull/7127))
**Accessibility**
- `EuiContextMenu` now correctly respects reduced motion preferences
([#7312](https://github.com/elastic/eui/pull/7312))
- `EuiAccordion`s no longer attempt to focus child content when the
accordion is externally opened via `forceState`, but will continue to
focus expanded content when users click the toggle button.
([#7314](https://github.com/elastic/eui/pull/7314))
**CSS-in-JS conversions**
- Converted `EuiContextMenu`, `EuiContextMenuPanel`, and
`EuiContextMenuItem` to Emotion; Removed `$euiContextMenuWidth`
([#7312](https://github.com/elastic/eui/pull/7312))
---
package.json | 2 +-
.../project_navigation_service.test.ts | 6 +-
.../fatal_errors_screen.test.tsx.snap | 1 -
.../__snapshots__/i18n_service.test.tsx.snap | 6 +-
.../src/i18n_eui_mapping.tsx | 12 +-
.../__snapshots__/comments.test.tsx.snap | 16 +-
...erate_linked_rules_menu_item.test.tsx.snap | 150 +++----
.../__snapshots__/header_menu.test.tsx.snap | 42 +-
.../__snapshots__/list_header.test.tsx.snap | 62 ++-
.../__snapshots__/menu_items.test.tsx.snap | 124 +++---
.../field_list_filters/field_type_filter.tsx | 7 +-
.../src/user_profiles_popover.test.tsx | 5 +-
.../components/line_style_settings.tsx | 89 ++--
.../no_data_card.component.test.tsx.snap | 6 -
src/dev/license_checker/config.ts | 2 +-
.../time_slider/components/time_slider.tsx | 2 +-
.../__snapshots__/indices_list.test.tsx.snap | 12 +-
.../color/__snapshots__/color.test.tsx.snap | 3 -
.../__snapshots__/static_lookup.test.tsx.snap | 2 -
.../table/__snapshots__/table.test.tsx.snap | 2 -
.../__snapshots__/add_filter.test.tsx.snap | 4 -
.../open_search_panel.test.tsx.snap | 2 -
.../__snapshots__/add_data.test.tsx.snap | 2 -
.../__snapshots__/footer.test.js.snap | 2 -
.../instruction_set.test.js.snap | 10 -
.../saved_objects_installer.test.js.snap | 2 -
.../__snapshots__/controls_tab.test.tsx.snap | 2 -
.../input_control_vis.test.tsx.snap | 8 -
.../public/submit_error_callout.test.tsx | 6 -
.../elastic_agent_card.test.tsx.snap | 10 -
.../top_nav_menu_item.test.tsx.snap | 1 -
.../saved_object_save_modal.test.tsx.snap | 8 -
.../finder/saved_object_finder.test.tsx | 11 +-
.../__snapshots__/flyout.test.tsx.snap | 2 -
.../__snapshots__/table.test.tsx.snap | 10 -
.../share_context_menu.test.tsx.snap | 15 +-
.../__snapshots__/app.test.tsx.snap | 2 +-
.../shareable_runtime/components/app.test.tsx | 4 +-
.../__snapshots__/settings.test.tsx.snap | 388 ++++++++----------
.../footer/settings/settings.test.tsx | 8 +-
.../shareable_runtime/test/interactions.ts | 2 +-
.../shareable_runtime/test/selectors.ts | 2 +-
.../components/all_cases/use_actions.test.tsx | 8 +-
.../all_cases/use_bulk_actions.test.tsx | 8 +-
.../follower_indices_list.test.js | 12 +-
.../__jest__/policy_table.test.tsx | 2 +-
.../home/index_templates_tab.helpers.ts | 4 +-
.../__jest__/components/index_table.test.js | 2 +-
.../helpers/pipelines_list.helpers.ts | 2 +-
.../pipeline_editor.test.js.snap | 24 --
.../pipelines_table.test.js.snap | 2 -
.../custom_icon_modal.test.tsx.snap | 5 -
.../geometry_filter_form.test.js.snap | 2 -
.../add_tooltip_field_popover.test.tsx.snap | 2 -
.../features_tooltip/features_tooltip.tsx | 19 +-
.../__snapshots__/layer_control.test.tsx.snap | 4 -
.../toc_entry_actions_popover.test.tsx.snap | 18 +-
.../__snapshots__/tools_control.test.tsx.snap | 7 +-
.../rule_editor_flyout.test.js.snap | 6 -
.../validate_job_view.test.js.snap | 3 -
.../__snapshots__/calendar_form.test.js.snap | 4 -
.../__snapshots__/events_table.test.js.snap | 2 -
.../__snapshots__/import_modal.test.js.snap | 2 -
.../table/__snapshots__/table.test.js.snap | 1 -
.../add_item_popover.test.js.snap | 6 -
.../delete_filter_list_modal.test.js.snap | 5 -
.../edit_filter_list.test.js.snap | 16 -
.../flyout/__snapshots__/flyout.test.js.snap | 10 -
.../__snapshots__/login_page.test.tsx.snap | 4 -
.../__snapshots__/login_form.test.tsx.snap | 3 -
.../public/assistant/get_comments/index.tsx | 18 +-
.../__snapshots__/index.test.tsx.snap | 4 -
.../upgrade_contents.test.tsx.snap | 4 -
.../modal_all_errors.test.tsx.snap | 2 -
.../__snapshots__/index.test.tsx.snap | 2 -
.../take_action_dropdown/index.test.tsx | 2 +-
.../__snapshots__/index.test.tsx.snap | 2 +-
...ndex_patterns_missing_prompt.test.tsx.snap | 1 -
.../components/resolve_all_conflicts.test.tsx | 2 +-
.../delete_spaces_button.test.tsx.snap | 1 -
.../manage_spaces_button.test.tsx.snap | 1 -
.../components/rule_status_panel.test.tsx | 10 +-
.../checklist_step.test.tsx.snap | 1 -
.../__snapshots__/warning_step.test.tsx.snap | 1 -
.../add_filter_btn.test.tsx | 6 +-
.../observability_log_explorer.ts | 7 +-
.../services/ml/data_frame_analytics_table.ts | 2 +-
.../services/ml/data_visualizer_table.ts | 4 +-
.../cypress/screens/exceptions.ts | 2 +-
yarn.lock | 56 ++-
90 files changed, 524 insertions(+), 839 deletions(-)
diff --git a/package.json b/package.json
index 6d8284bae86b..9af2ce5973b3 100644
--- a/package.json
+++ b/package.json
@@ -102,7 +102,7 @@
"@elastic/datemath": "5.0.3",
"@elastic/elasticsearch": "npm:@elastic/elasticsearch-canary@8.9.1-canary.1",
"@elastic/ems-client": "8.5.0",
- "@elastic/eui": "89.1.0",
+ "@elastic/eui": "90.0.0",
"@elastic/filesaver": "1.1.2",
"@elastic/node-crypto": "1.2.1",
"@elastic/numeral": "^2.5.1",
diff --git a/packages/core/chrome/core-chrome-browser-internal/src/project_navigation/project_navigation_service.test.ts b/packages/core/chrome/core-chrome-browser-internal/src/project_navigation/project_navigation_service.test.ts
index 7e1347f8534c..e42176bc177e 100644
--- a/packages/core/chrome/core-chrome-browser-internal/src/project_navigation/project_navigation_service.test.ts
+++ b/packages/core/chrome/core-chrome-browser-internal/src/project_navigation/project_navigation_service.test.ts
@@ -86,7 +86,7 @@ describe('breadcrumbs', () => {
expect(breadcrumbs).toMatchInlineSnapshot(`
Array [
Object {
- "popoverContent": {
expect(breadcrumbs).toMatchInlineSnapshot(`
Array [
Object {
- "popoverContent": {
expect(breadcrumbs).toMatchInlineSnapshot(`
Array [
Object {
- "popoverContent":
{
'euiCollapsibleNavBeta.ariaLabel': i18n.translate('core.euiCollapsibleNavBeta.ariaLabel', {
defaultMessage: 'Site menu',
}),
+ 'euiCollapsibleNavButton.ariaLabelExpand': i18n.translate(
+ 'core.euiCollapsibleNavButton.ariaLabelExpand',
+ { defaultMessage: 'Expand navigation' }
+ ),
+ 'euiCollapsibleNavButton.ariaLabelCollapse': i18n.translate(
+ 'core.euiCollapsibleNavButton.ariaLabelCollapse',
+ { defaultMessage: 'Collapse navigation' }
+ ),
'euiCollapsibleNavButton.ariaLabelClose': i18n.translate(
'core.euiCollapsibleNavButton.ariaLabelClose',
- { defaultMessage: 'Toggle navigation closed' }
+ { defaultMessage: 'Close navigation' }
),
'euiCollapsibleNavButton.ariaLabelOpen': i18n.translate(
'core.euiCollapsibleNavButton.ariaLabelOpen',
- { defaultMessage: 'Toggle navigation open' }
+ { defaultMessage: 'Open navigation' }
),
'euiColorPicker.alphaLabel': i18n.translate('core.euiColorPicker.alphaLabel', {
defaultMessage: 'Alpha channel (opacity) value',
diff --git a/packages/kbn-securitysolution-exception-list-components/src/exception_item_card/comments/__snapshots__/comments.test.tsx.snap b/packages/kbn-securitysolution-exception-list-components/src/exception_item_card/comments/__snapshots__/comments.test.tsx.snap
index 3520fe5a52f2..ff7dddd2da95 100644
--- a/packages/kbn-securitysolution-exception-list-components/src/exception_item_card/comments/__snapshots__/comments.test.tsx.snap
+++ b/packages/kbn-securitysolution-exception-list-components/src/exception_item_card/comments/__snapshots__/comments.test.tsx.snap
@@ -143,7 +143,7 @@ Object {
class="emotion-euiTimelineItemEvent-top"
>
-
-
+