Skip to content
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

[Emotion] Convert EuiPortal #6075

Merged
merged 4 commits into from
Jul 28, 2022
Merged

Conversation

elizabetdev
Copy link
Contributor

@elizabetdev elizabetdev commented Jul 26, 2022

Summary

This PR moves .euiBody-hasPortalContent styles that used to live in _portal.scss to Emotion EuiGlobalStyles (src/global_styling/reset/global_styles.tsx).

The class name .euiBody-hasPortalContent is currently being used in:

  • src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx
  • src/components/tool_tip/tool_tip_popover.tsx

Checklist

  • [ ] Checked in both light and dark modes
  • [ ] Checked in mobile
  • Checked in Chrome, Safari, Edge, and Firefox
  • [ ] Props have proper autodocs and playground toggles
  • [ ] Added documentation
  • [ ] Checked Code Sandbox works for any docs examples
  • [ ] Added or updated jest and cypress tests
  • [ ] Checked for breaking changes and labeled appropriately
  • [ ] Checked for accessibility including keyboard-only and screenreader modes
  • [ ] Updated the Figma library counterpart
  • A changelog entry exists and is marked appropriately

@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_6075/

@chandlerprall
Copy link
Contributor

An alternative (which would be a breaking change) would be to move the global style to the tooltip & combobox components' render. Constance's investigation in (#6055 (comment)) makes me tend to prefer the approach in this PR to retain the global class name and avoid potential, and unknown, breaks.

@elizabetdev elizabetdev marked this pull request as ready for review July 28, 2022 10:41
@elizabetdev
Copy link
Contributor Author

@chandlerprall this PR is ready for review.

Based on work done in #6055, I'm not completely sure what was the decision regarding the .euiBody-hasPortalContent styles. Happy to close this PR if you want to go on a different path.

@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_6075/

Copy link
Contributor

@chandlerprall chandlerprall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This satisfies the conversion for EuiPortal and makes the combobox/tooltip dependency on the global style more explicit. When those other components are converted we can revisit if the global classname is what we want vs. moving it into those components on-demand.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants