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

Sizes presets for border-radius #49504

Open
cawa-93 opened this issue Mar 31, 2023 · 1 comment
Open

Sizes presets for border-radius #49504

cawa-93 opened this issue Mar 31, 2023 · 1 comment
Labels
[Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi [Type] Enhancement A suggestion for improvement.

Comments

@cawa-93
Copy link
Contributor

cawa-93 commented Mar 31, 2023

What problem does this address?

My themes have a fixed set of border-radius values. These are complex adaptive values like clamp(2.5rem, 1.912rem + 2.941vw, 3.75rem), not simple fixed values ​​in px or rem.

  1. I cannot configure the theme so that the editor chooses a radius value from one of the preset options. He is always forced to enter some custom number.
  2. In existing controls, it is impossible to set such a complex, adaptive value, using clamp or min/max.

What is your proposed solution?

Provide presets for border.radius such as for spacing.spacingSizes

{
  "border": {
    "radius": false, // to disable custom border-radius and allow only pre-defined 👇🏻
    "radiusSizes": [
		{ "name": "Small", "slug": "small", "size": "clamp(0.625rem, 0.037rem + 2.941vw, 1.875rem)" },
		{ "name": "Big", "slug": "big", "size": "clamp(2.5rem, 1.912rem + 2.941vw, 3.75rem)" }
	]
  }
}
@mrfoxtalbot mrfoxtalbot added [Type] Enhancement A suggestion for improvement. [Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi labels Apr 1, 2023
@mrfoxtalbot
Copy link

mrfoxtalbot commented Apr 3, 2023

it is impossible to set such a complex, adaptive value

I do not think this is possible at the moment, no.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

No branches or pull requests

2 participants