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

[Shared UX] Move Solution Toolbar components to package #134392

Merged

Conversation

clintandrewhall
Copy link
Contributor

@clintandrewhall clintandrewhall commented Jun 14, 2022

Summary

As titled, moving another set of components to a package.

Open Questions

  • @cchaos Any feedback on the package name? We still haven't created the actual SolutionToolbar yet.
  • @thompsongl IconButtonGroup is using an emotion technique I'm not familiar with, and it's also not working, (the styles are being overloaded by specificity). Can you assist with a technique to be more current that also works?

@clintandrewhall clintandrewhall added review loe:small Small Level of Effort release_note:skip Skip the PR/issue when compiling release notes impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. backport:skip This commit does not require backporting Team:SharedUX Team label for AppEx-SharedUX (formerly Global Experience) v8.4.0 labels Jun 14, 2022
@clintandrewhall clintandrewhall requested a review from a team June 14, 2022 19:39
@clintandrewhall clintandrewhall requested review from a team as code owners June 14, 2022 19:39
@thompsongl
Copy link
Contributor

the styles are being overloaded by specificity

As in the IconButtonGroup styles applied by Emotion are overridden by those from Sass/compiled CSS?

@cchaos
Copy link
Contributor

cchaos commented Jun 14, 2022

Any feedback on the package name? We still haven't created the actual SolutionToolbar yet.

I would be descriptive about what it is: ButtonToolbar since it just groups buttons together but then not to be confused with buttonGroup

Copy link
Contributor

@cchaos cchaos left a comment

Choose a reason for hiding this comment

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

Found a few lingering mentions of "Solution"

@clintandrewhall
Copy link
Contributor Author

@thompsongl You can see the issue here: https://ci-artifacts.kibana.dev/storybooks/pr-134392/f0093ba142591a6e8320a9daba00e05a5f3fa28c/shared_ux/index.html?path=/story/solution-toolbar-buttons--icon-button-group

The styles are overridden by the base EUI styles. Curious how to adapt the Emotion styles to overcome that specificity. And this used to work, AFAIK.

Screen Shot 2022-06-15 at 9 31 00 AM

Screen Shot 2022-06-15 at 9 31 06 AM

@thompsongl
Copy link
Contributor

Spoke to @clintandrewhall about the specificity problem and it's a known effect. The EUI team has a fix in the works that will enable Kibana to better order styles coming from Emotion: elastic/eui#5853

This will be available and enabled in Kibana by 8.4 FF. You'll need to do no extra work.

If you want to increase specificity in the meantime, you can chain the selector in question:
'&.euiButtonGroupButton' to '&.euiButtonGroupButton.euiButtonGroupButton' or '&.euiButtonGroupButton.euiButtonGroupButton.euiButtonGroupButton'

@clintandrewhall
Copy link
Contributor Author

Thanks @thompsongl ... we'll just leave as-is, for now, and let your fix take care of it.

@cchaos
Copy link
Contributor

cchaos commented Jun 15, 2022

we'll just leave as-is

Are the any actual usages of this right now? I would be concerned about this visual regression even if temporary. But if it's not consumed just yet, then we're ok.

@clintandrewhall
Copy link
Contributor Author

@cchaos yeah, it's not used anywhere yet

Copy link
Contributor

@ThomThomson ThomThomson left a comment

Choose a reason for hiding this comment

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

Presentation team changes LGTM, just changes to deprecation comments.

@clintandrewhall clintandrewhall requested a review from cchaos June 16, 2022 02:05
@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
dashboard 425 419 -6
discover 594 588 -6
home 147 141 -6
kibanaOverview 179 173 -6
lens 926 920 -6
observability 497 491 -6
securitySolution 3078 3072 -6
visualizations 377 371 -6
total -48

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/shared-ux-button-toolbar - 6 +6
@kbn/shared-ux-components 15 7 -8
total -2

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
dashboard 391.4KB 391.4KB -1.0B

Public APIs missing exports

Total count of every type that is part of your API that should be exported but is not. This will cause broken links in the API documentation system. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats exports for more detailed information.

id before after diff
@kbn/shared-ux-components 3 2 -1
Unknown metric groups

API count

id before after diff
@kbn/shared-ux-button-toolbar - 20 +20
@kbn/shared-ux-components 21 13 -8
total +12

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

Copy link
Contributor

@majagrubic majagrubic left a comment

Choose a reason for hiding this comment

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

Tested in storybook in Chrome on Mac OSX, works as expected. Had only a brief look at the code, since it's mostly moving files around, I wasn't expecting any major changes.

@clintandrewhall clintandrewhall merged commit 9ec4d31 into elastic:main Jun 21, 2022
@clintandrewhall clintandrewhall self-assigned this Jun 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. loe:small Small Level of Effort release_note:skip Skip the PR/issue when compiling release notes review Team:SharedUX Team label for AppEx-SharedUX (formerly Global Experience) v8.4.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants