-
Notifications
You must be signed in to change notification settings - Fork 841
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Chromium workaround for CSS mask-image bug #7855
Chromium workaround for CSS mask-image bug #7855
Conversation
might want to do the same on these lines in a scss mixin https://github.com/elastic/eui/blob/main/packages/eui/src/global_styling/mixins/_shadow.scss#L97-#L99 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚢 🐈⬛ Looks good to me! Thanks for digging into this. I can confirm it's fixed in Chrome and Edge 👍
- eventually going to be deprecated, but we can cross that bridge when we get to it
@kqualters-elastic Fantastic suggestion! I'll add that here as well, but as a heads up, we're looking to deprecate Sass mixins in the future as there isn't an easy way to keep them dynamic to theme changes/customizations compared to CSS-in-JS. |
Preview staging links for this PR:
|
💚 Build Succeeded
History
cc @cee-chen |
@asharma-5 It will, yes! |
@cee-chen Thanks for the response. |
@asharma-5 We can if requested, but we typically only do so if there's a specific Kibana team or customer requesting the fix. Please let us know if you would like to make that request! |
@cee-chen can you please provide the version of Kibana/elasticsearch in which this fix is released. |
`v95.2.0`⏩`v95.3.0` _[Questions? Please see our Kibana upgrade FAQ.](https://github.com/elastic/eui/blob/main/wiki/eui-team-processes/upgrading-kibana.md#faq-for-kibana-teams)_ --- ## [`v95.3.0`](https://github.com/elastic/eui/releases/v95.3.0) - Updated `EuiThemeProvider`s to allow modifying/setting custom `breakpoint`s in nested usage (as opposed to only at the top `EuiProvider` level) ([#7862](elastic/eui#7862)) **Bug fixes** - Fixed a Chrome/Edge CSS `mask-image` bug that was affecting scroll overflow shadow utilties ([#7855](elastic/eui#7855)) **CSS-in-JS conversions** - Converted `EuiColorPicker` to Emotion; Removed `$euiColorPickerWidth` ([#7845](elastic/eui#7845)) - Converted `EuiColorPickerSwatch` to Emotion ([#7853](elastic/eui#7853)) - Converted `EuiColorPalettePicker` and `EuiColorPaletteDisplay` to Emotion ([#7854](elastic/eui#7854)) - Removed `$euiColorPaletteDisplaySizes` - Removed `@mixin euiColorPaletteInnerBorder` - Removed `$euiColorPickerValueRange0`, `$euiColorPickerValueRange1`, `$euiColorPickerSaturationRange0`, `$euiColorPickerSaturationRange1`, and `$euiColorPickerIndicatorSize` ([#7859](elastic/eui#7859)) **Accessibility** - Updated the `aria-label` attribute for the `EuiFilePicker` remove file button ([#7860](elastic/eui#7860)) --------- Co-authored-by: kibanamachine <[email protected]> Co-authored-by: Elastic Machine <[email protected]>
@asharma-5 Sorry for the delay in responding, I was out on PTO. The fix will be in Kibana v8.15.0+. |
## Summary Fixes positioning of dragged links in the Links panel editor. The issue was caused by the `transform: translateZ(0)` workaround in EUI to fix a [mask image bug](elastic/eui#7855) in Chromium. We fix this by overriding the `transform` for in the `FlyoutBody` of the Links panel editor. Before: https://github.com/user-attachments/assets/8ad10732-dfaa-4464-845b-0a9c4fc6b173 After: https://github.com/user-attachments/assets/e6f0bffe-7eb0-4590-affc-a89bc86b973d
## Summary Fixes positioning of dragged links in the Links panel editor. The issue was caused by the `transform: translateZ(0)` workaround in EUI to fix a [mask image bug](elastic/eui#7855) in Chromium. We fix this by overriding the `transform` for in the `FlyoutBody` of the Links panel editor. Before: https://github.com/user-attachments/assets/8ad10732-dfaa-4464-845b-0a9c4fc6b173 After: https://github.com/user-attachments/assets/e6f0bffe-7eb0-4590-affc-a89bc86b973d (cherry picked from commit e566abf)
…) (#189129) # Backport This will backport the following commits from `main` to `8.15`: - [[Links] Fix positioning of dragged link in links editor (#189122)](#189122) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Nick Peihl","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-07-24T19:49:43Z","message":"[Links] Fix positioning of dragged link in links editor (#189122)\n\n## Summary\r\n\r\nFixes positioning of dragged links in the Links panel editor.\r\n\r\nThe issue was caused by the `transform: translateZ(0)` workaround in EUI\r\nto fix a [mask image bug](elastic/eui#7855) in\r\nChromium. We fix this by overriding the `transform` for in the\r\n`FlyoutBody` of the Links panel editor.\r\n\r\nBefore:\r\n\r\n\r\nhttps://github.com/user-attachments/assets/8ad10732-dfaa-4464-845b-0a9c4fc6b173\r\n\r\nAfter:\r\n\r\n\r\n\r\nhttps://github.com/user-attachments/assets/e6f0bffe-7eb0-4590-affc-a89bc86b973d","sha":"e566abf1cb6317c381431c4902abd5554fea6217","branchLabelMapping":{"^v8.16.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Team:Presentation","v8.15.0","v8.16.0"],"title":"[Links] Fix positioning of dragged link in links editor","number":189122,"url":"https://github.com/elastic/kibana/pull/189122","mergeCommit":{"message":"[Links] Fix positioning of dragged link in links editor (#189122)\n\n## Summary\r\n\r\nFixes positioning of dragged links in the Links panel editor.\r\n\r\nThe issue was caused by the `transform: translateZ(0)` workaround in EUI\r\nto fix a [mask image bug](elastic/eui#7855) in\r\nChromium. We fix this by overriding the `transform` for in the\r\n`FlyoutBody` of the Links panel editor.\r\n\r\nBefore:\r\n\r\n\r\nhttps://github.com/user-attachments/assets/8ad10732-dfaa-4464-845b-0a9c4fc6b173\r\n\r\nAfter:\r\n\r\n\r\n\r\nhttps://github.com/user-attachments/assets/e6f0bffe-7eb0-4590-affc-a89bc86b973d","sha":"e566abf1cb6317c381431c4902abd5554fea6217"}},"sourceBranch":"main","suggestedTargetBranches":["8.15"],"targetPullRequestStates":[{"branch":"8.15","label":"v8.15.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.16.0","branchLabelMappingKey":"^v8.16.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/189122","number":189122,"mergeCommit":{"message":"[Links] Fix positioning of dragged link in links editor (#189122)\n\n## Summary\r\n\r\nFixes positioning of dragged links in the Links panel editor.\r\n\r\nThe issue was caused by the `transform: translateZ(0)` workaround in EUI\r\nto fix a [mask image bug](elastic/eui#7855) in\r\nChromium. We fix this by overriding the `transform` for in the\r\n`FlyoutBody` of the Links panel editor.\r\n\r\nBefore:\r\n\r\n\r\nhttps://github.com/user-attachments/assets/8ad10732-dfaa-4464-845b-0a9c4fc6b173\r\n\r\nAfter:\r\n\r\n\r\n\r\nhttps://github.com/user-attachments/assets/e6f0bffe-7eb0-4590-affc-a89bc86b973d","sha":"e566abf1cb6317c381431c4902abd5554fea6217"}}]}] BACKPORT--> Co-authored-by: Nick Peihl <[email protected]>
@cee-chen Thanks for the response, when 8.15.0 will be available ? |
That I'm not sure about, sorry, I don't closely track Elastic's release schedule. It should be sometime soon however. |
@cee-chen Can you please check internally and provide an tentative date ? |
I am not going to make that information publicly available before Elastic's official announcement, sorry! |
@cee-chen i have upgraded to 8.15.0 but still seeing the same issue, Is the fix included in 8.15.0 ?? elasticsearch@elasticsearch-0:/opt/elasticsearch/bin$ ./elasticsearch --version ./kibana --version can you please help |
Ah, it looks like Tomasz missed the feature freeze cutoff for 8.15 in elastic/kibana#187342 by a few days, and unfortunately the Thank you for your patience on this @asharma-5. As a heads up, this bug only affects Chrome, so temporarily switching to the Firefox or Safari browser will resolve the issue. |
`v95.2.0`⏩`v95.3.0` _[Questions? Please see our Kibana upgrade FAQ.](https://github.com/elastic/eui/blob/main/wiki/eui-team-processes/upgrading-kibana.md#faq-for-kibana-teams)_ --- - Updated `EuiThemeProvider`s to allow modifying/setting custom `breakpoint`s in nested usage (as opposed to only at the top `EuiProvider` level) ([elastic#7862](elastic/eui#7862)) **Bug fixes** - Fixed a Chrome/Edge CSS `mask-image` bug that was affecting scroll overflow shadow utilties ([elastic#7855](elastic/eui#7855)) **CSS-in-JS conversions** - Converted `EuiColorPicker` to Emotion; Removed `$euiColorPickerWidth` ([elastic#7845](elastic/eui#7845)) - Converted `EuiColorPickerSwatch` to Emotion ([elastic#7853](elastic/eui#7853)) - Converted `EuiColorPalettePicker` and `EuiColorPaletteDisplay` to Emotion ([elastic#7854](elastic/eui#7854)) - Removed `$euiColorPaletteDisplaySizes` - Removed `@mixin euiColorPaletteInnerBorder` - Removed `$euiColorPickerValueRange0`, `$euiColorPickerValueRange1`, `$euiColorPickerSaturationRange0`, `$euiColorPickerSaturationRange1`, and `$euiColorPickerIndicatorSize` ([elastic#7859](elastic/eui#7859)) **Accessibility** - Updated the `aria-label` attribute for the `EuiFilePicker` remove file button ([elastic#7860](elastic/eui#7860)) --------- Co-authored-by: kibanamachine <[email protected]> Co-authored-by: Elastic Machine <[email protected]>
## Backport This is a manual backport of EUI v95.3.0 (#187342) which was intended to target 8.15 but was missed due to the `backport:skip` label. The release contains a requested visual bugfix for Chromium users: elastic/eui#7855 (comment) Co-authored-by: Tomasz Kajtoch <[email protected]> Co-authored-by: kibanamachine <[email protected]> Co-authored-by: Elastic Machine <[email protected]>
@cee-chen Thanks for the response. |
Summary
This bug was originally addressed in #6328 / #6343, but it turns out that it's affecting more components than just EuiModal (at least EuiFlyout as well - see elastic/kibana#180828). The browser-level bug in question is being tracked in https://issues.chromium.org/issues/40778541.
The amazing @kqualters-elastic helped us look into the issue and came up with an excellent workaround. Chromium appears to be not correctly applying a stacking context to
mask-image
s with linear gradients and certain other children/properties. Usingtransform: translateZ(0)
forces that stacking context and fixes the bug.NOTE:
will-change: transform
andposition: relative
also works around the bug, but I deemed them to potentially have outsized side effects compared to translateZ.QA
Show Modal
button.euiModalBody__overflow
transform: translateZ(0)
CSS and confirm that it does have a red overlay without the workaround CSSGeneral checklist
REVERT ME
commit- [ ] Checked in mobile- [ ] Checked for accessibility including keyboard-only and screenreader modes- [ ] If applicable, added the breaking change issue label (and filled out the breaking change checklist)