Skip to content

feat(ButtonGroup): update design #626

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

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

feat(ButtonGroup): update design #626

wants to merge 1 commit into from

Conversation

ariser
Copy link
Collaborator

@ariser ariser commented Jul 2, 2025

What and Why

Right now it's impossible to tell which one of the two options in ButtonGroup is selected:
image

This update aims to make visuals more clear:
image

ToDos:

  • Apply new design
  • Adjust tokens in design system
    • remove unused
    • add new one for the space around buttons
    • look at active background color in light theme; it's barely visible
  • Update PR after new tokens are added

@ariser ariser requested review from vineethasok and crisalbu July 2, 2025 18:16
Copy link

vercel bot commented Jul 2, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
click-ui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 2, 2025 6:17pm

// TODO remove css variables for radii?
border-radius: ${({ theme, $type }) =>
$type === "default"
? `calc(${theme.click.button.group.radii.all} - var(--outer-spacing))`
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

this does not exactly match what we have in figma

why
nested border-radii are a bit tricky to implement. If the outer radius matches the inner radius, they can look fine when an element in the middle is selected:
image

But when the selected area corner is right next to the outer border area, they start to conflict. Here it's obvious that the spacing around the inner element increases around the corner:
image

To avoid this, inner radius should be reduced by the size of the space between the outer border and the inner element:
image

here is a playground to see how it feels:
https://borderradiuscalculator.vercel.app/

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.

1 participant