-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Add theme.json presets for Border Radius #64041
Comments
@jameskoster @jasmussen @richtabor Would love to hear your thoughts on this. And I think this could use some design help to figure out how to best present it :) |
This would be a small improvement over using theme.json>settings>custom, or trying to keep consistency using a ref in theme.json. |
@carolinan Yeah we already do this in our themes in code. But we often still need to select from different options for what radius should be used on a component level... Like for example two different groups may need different radii. And that is not something that we can really accomplish with just the defaults... Yeah we can hard code it in a pattern but then we loose the ability to change it site wide when the radius needs to be tweaked |
I like that this follows closely to the #63963 concepts pitched. We could reuse that certainly. |
A short-term option could also be to leverage block style variations. They'd be editable via Global Styles, should the need to change them arise, with the changes automatically applied anywhere the variation was applied. |
Can we maybe build upon custom theme.json settings to expose custom presets instead of, or in addition to, using a scale? (similarly to what we have with colors currently) For example: Another way to do it might be adding "Var" to the units drop-down and then manually typing the var name to the input field (maybe in the future have a dropdown or autocomplete). For example, a design might have "soft corners" (let's say We can create: It isn't a small-medium-large sort of thing. Let's say in the future the designer wants to switch from Another way of seeing it is as bringing custom CSS properties (variables) into the editor UI. In the context of border-radius It can be applied either to each corner individually, or to all corners tighter, This is how I understand the original message by @fabiankaegy, but maybe I'm missing something. |
Can I get some help getting these "corner icons" into the icons library? |
@jameskoster happy to help extract the SVGs if you point me to the Figma and have a full table otherwise. |
Here we go... All corners
Top left
Top right
Bottom left
Bottom right
|
Thanks :) |
Like spacing, color, aspect ratios etc. Border Radii are something that should be applied consistently throughout a design. Instead of having to always manually enter the raw px value it would be great to be able to use a variable instead. Ideally this would work similar to the spacing control where you can either provide a variable or enter the raw value.
The text was updated successfully, but these errors were encountered: