From 03051f7a5c3f623c5ae01d6ff31047e133ff7032 Mon Sep 17 00:00:00 2001 From: Cee Chen <549407+cee-chen@users.noreply.github.com> Date: Mon, 1 May 2023 10:05:11 -0700 Subject: [PATCH] Upgrade EUI to v77.1.2 (#156232) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Summary `eui@77.1.1` ⏩ `eui@77.1.2` This upgrade consists of a backport release intended to fix a major bug where portals within `EuiFlyout`s and `EuiModal`s are not scrollable. fixes https://github.com/elastic/kibana/issues/156161 This release also adds functionality that resolves the need for a TODO workaround added in https://github.com/elastic/kibana/pull/153227 --- ## [`77.1.2`](https://github.com/elastic/eui/tree/v77.1.2) - Updated `EuiFocusTrap` to support the `gapMode` prop configuration (now defaults to `padding`) ([#6744](https://github.com/elastic/eui/pull/6744)) **Bug fixes** - Fixed the `scrollLock` property on `EuiFocusTrap` (and other components using `EuiFocusTrap`, such as `EuiFlyout` and `EuiModal`) to no longer block scrolling on nested portalled content, such as combobox dropdowns ([#6744](https://github.com/elastic/eui/pull/6744)) --------- Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> (cherry picked from commit 0564e5434e56ca24c7cbb3fbf4a58d6242714e71) --- package.json | 2 +- src/core/public/styles/_base.scss | 9 --------- src/dev/license_checker/config.ts | 2 +- yarn.lock | 11 ++++++----- 4 files changed, 8 insertions(+), 16 deletions(-) diff --git a/package.json b/package.json index 7946fc7b4701ba..166faa62dbca2a 100644 --- a/package.json +++ b/package.json @@ -96,7 +96,7 @@ "@elastic/datemath": "5.0.3", "@elastic/elasticsearch": "npm:@elastic/elasticsearch-canary@8.6.0-canary.3", "@elastic/ems-client": "8.4.0", - "@elastic/eui": "77.1.1", + "@elastic/eui": "77.1.2", "@elastic/filesaver": "1.1.2", "@elastic/node-crypto": "1.2.1", "@elastic/numeral": "^2.5.1", diff --git a/src/core/public/styles/_base.scss b/src/core/public/styles/_base.scss index 1e8e6c7411e4d8..de138cdf402e6e 100644 --- a/src/core/public/styles/_base.scss +++ b/src/core/public/styles/_base.scss @@ -34,12 +34,3 @@ .euiPageHeader--bottomBorder:not(.euiPageHeader--tabsAtBottom):not([class*='euiPageHeader--padding']) { padding-bottom: $euiSizeL; } - -// Kibana's body ignores the `margin-right !important` set by react-remove-scroll-bar -// (used by EUI's focus trap component & prevents page width jumps on full-screen overlays) -// due to the 100% width/min-width CSS set by Kibana in other places. To work around this, we -// grab the `--removed-body-scroll-bar-size` var added by the library & manually set `padding` -// TODO: Use `gapMode` instead once https://github.com/theKashey/react-focus-on/issues/65 is fixed -.kbnBody { - padding-right: var(--removed-body-scroll-bar-size, 0); -} diff --git a/src/dev/license_checker/config.ts b/src/dev/license_checker/config.ts index 75a12b0884f8ad..aefe4bbd7e8ed2 100644 --- a/src/dev/license_checker/config.ts +++ b/src/dev/license_checker/config.ts @@ -85,6 +85,6 @@ export const LICENSE_OVERRIDES = { 'jsts@1.6.2': ['Eclipse Distribution License - v 1.0'], // cf. https://github.com/bjornharrtell/jsts '@mapbox/jsonlint-lines-primitives@2.0.2': ['MIT'], // license in readme https://github.com/tmcw/jsonlint '@elastic/ems-client@8.4.0': ['Elastic License 2.0'], - '@elastic/eui@77.1.1': ['SSPL-1.0 OR Elastic License 2.0'], + '@elastic/eui@77.1.2': ['SSPL-1.0 OR Elastic License 2.0'], 'language-subtag-registry@0.3.21': ['CC-BY-4.0'], // retired ODC‑By license https://github.com/mattcg/language-subtag-registry }; diff --git a/yarn.lock b/yarn.lock index f2f58c3bea3692..dac99a567fbe29 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1543,10 +1543,10 @@ resolved "https://registry.yarnpkg.com/@elastic/eslint-plugin-eui/-/eslint-plugin-eui-0.0.2.tgz#56b9ef03984a05cc213772ae3713ea8ef47b0314" integrity sha512-IoxURM5zraoQ7C8f+mJb9HYSENiZGgRVcG4tLQxE61yHNNRDXtGDWTZh8N1KIHcsqN1CEPETjuzBXkJYF/fDiQ== -"@elastic/eui@77.1.1": - version "77.1.1" - resolved "https://registry.yarnpkg.com/@elastic/eui/-/eui-77.1.1.tgz#82f4294bf3239d5d825c1d939c49d125bfdbeb72" - integrity sha512-guJmHoGDbvKh/738taKDZGSdNk+OXMse513oPaPf4NoXpQUeYvl3gLT50mX5J4nwILS1LFKNGrbU2Es77HM1cQ== +"@elastic/eui@77.1.2": + version "77.1.2" + resolved "https://registry.yarnpkg.com/@elastic/eui/-/eui-77.1.2.tgz#85c20c682058ada1a9478af2894c290cc20c1678" + integrity sha512-cq7TI/rOomifh/KXU1V+wGirClomkMcQ166K9/7eMyqJb50AAuweu5JkjiDRNvB06uX1lDP6GjSb+oGvf8885A== dependencies: "@types/chroma-js" "^2.0.0" "@types/lodash" "^4.14.160" @@ -1570,6 +1570,7 @@ react-focus-on "^3.7.0" react-input-autosize "^3.0.0" react-is "^17.0.2" + react-remove-scroll-bar "^2.3.4" react-virtualized-auto-sizer "^1.0.6" react-window "^1.8.6" refractor "^3.5.0" @@ -24228,7 +24229,7 @@ react-refresh@^0.11.0: resolved "https://registry.yarnpkg.com/react-refresh/-/react-refresh-0.11.0.tgz#77198b944733f0f1f1a90e791de4541f9f074046" integrity sha512-F27qZr8uUqwhWZboondsPx8tnC3Ct3SxZA3V5WyEvujRyyNv0VYPhoBg1gZ8/MV5tubQp76Trw8lTv9hzRBa+A== -react-remove-scroll-bar@^2.3.3: +react-remove-scroll-bar@^2.3.3, react-remove-scroll-bar@^2.3.4: version "2.3.4" resolved "https://registry.yarnpkg.com/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.4.tgz#53e272d7a5cb8242990c7f144c44d8bd8ab5afd9" integrity sha512-63C4YQBUt0m6ALadE9XV56hV8BgJWDmmTPY758iIJjfQKt2nYwoUrPk0LXRXcB/yIj82T1/Ixfdpdk68LwIB0A==