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

[EuiNotificationBadge] The number inside badge looks not centred, corner radius value is different than in the design component #4992

Closed
yiyangliu9286 opened this issue Jul 29, 2021 · 4 comments · Fixed by #5053
Assignees
Labels

Comments

@yiyangliu9286
Copy link

For EuiNotificationBadge, we have noticed that there are slightly differences between the component in the design system in Figma vs. how it looks after implementing it. See screenshots below:

  • In the design system, the radius value is 3. And number looks centred.

Screen Shot 2021-07-22 at 2 01 29 PM (1)

  • In what has been implemented, the radius value looks bigger. The number looks slightly not centred.

Screen Shot 2021-07-22 at 2 01 32 PM

Just wondering if the team could take a look at it when there's a chance? Thanks.

@ecezalp
Copy link

ecezalp commented Jul 29, 2021

so one thing I noticed about this non-centering issue - I believe that when the button is hovered, an underline shows up both for the button copy and for the number within the EuiNotificationBadge, and the number appears centered when the underline is visible. I was unable to remove the underline with any of the usual css tricks - something to keep in mind!

@cchaos
Copy link
Contributor

cchaos commented Jul 29, 2021

Yep because you're putting the badge inside of a button which gets text-decoration: underline on :hover. There's no way to separate out the button content vs non-button content from the consuming side. Usually you can add text-decoration: none !important to the part you don't want to get the attribute.

But I've also seen this pattern emerging more often (notification badge inside a tab) and maybe one we can implement as part of the EuiTab itself.

@ecezalp
Copy link

ecezalp commented Aug 4, 2021

But I've also seen this pattern emerging more often (notification badge inside a tab) and maybe one we can implement as part of the EuiTab itself.

this would be amazing :)

@cchaos
Copy link
Contributor

cchaos commented Aug 20, 2021

I've moved the request for EuiTab to accept secondary content to a new issue #5057 so that this one can be closed via #5053 that addresses the border-radius of the notification badge.

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

Successfully merging a pull request may close this issue.

3 participants