Four sliders and one declaration
Top-left, top-right, bottom-left and bottom-right each get a range input from 0 to 100 pixels, with the live value printed beside it. A blue rectangle on a grey stage updates while dragging, and one read-only line below collects the shorthand. The script runs once at load with every slider at zero, so the page opens as a plain box.
A worked example
At defaults the output field holds border-radius: 0px 0px 0px 0px;. Set the corners to 20, 40, 10 and 30 and it becomes border-radius: 20px 40px 30px 10px;. That third value is bottom-right and the fourth is bottom-left, because CSS expects the shorthand clockwise while the sliders are laid out as a reading of the grid. Trust the string, not the position of the control.
Why the preview lies at large values
The stage box measures 160 by 128 pixels. Pushing all four sliders to 100 asks for 200 pixels of curve along an edge only 128 tall, and a browser resolves that by scaling every radius by the same factor, 0.64 vertically and 0.8 horizontally. The preview softens into a squircle while the copied CSS still says 100px.
Where it stops
- Whole pixels only, so no percentages or rems, and no elliptical slash syntax for unequal horizontal and vertical radii.
- Equal All copies the top-left value across the other three, overriding corners instead of matching the one just moved.
- The fixed 160 by 128 stage clamps visually at large radii and cannot show a true circle or pill.
- Output is one bare declaration with no selector and no prefixed fallback property.
- Nothing here tests how rounded corners clip an image or a border of their own.
Questions people ask
What radius gives a circle?
At least half the shorter side in pixels, or a large percentage on a square element. Since only pixels are emitted, a 50 percent value by hand is the safer circle.
How is a pill button made?
Match all four corners with Equal All, then use at least half the button height, so a 48 pixel tall control needs 24 or more.
Is the copied line complete?
Yes, it carries the full declaration, and the button sends it to the clipboard without confirmation. Add depth in the box shadow generator, inner space in the padding and margin generator, or a finished surface in the CSS filter generator.