shadcn.io is an independent project built on shadcn/ui
A small button is disabled. A 12px spinner sits before the words Please Wait. The spinner is hidden from assistive tech. No request runs.
Use the small size in a table row or a toolbar. The wheel is 12px so it matches the shorter button. A full-width wait can use the default button, and a known fraction fits Progress. In React, Ark UI does not pick the small size.
Installation
Anatomy

Usage
<Button disabled size="sm">
<Spinner aria-hidden="true" className="size-3" data-icon="inline-start" />
Please Wait
</Button>FAQ
How is this button small?
size is sm on the Button. The Spinner also has size-3 (12px), so the wheel matches the shorter button. The default spinner is size-4.
How does the spinner sit in front of Please Wait?
The Spinner is the first child, with data-icon set to inline-start and className set to size-3. The button spaces that icon before the words.
Why is the small button disabled?
So it can't be pressed again while the label is Please Wait. disabled is set, and the button keeps its sm size at reduced opacity.
Can the label be shorter?
Yes. This file uses "Please Wait". A shorter string such as "Wait" or "Saving" still sits after the size-3 spinner. Keep size="sm" and data-icon.
API Reference
Button
Sets disabled and size="sm". The rest is on the Button page.
Spinner
Sets aria-hidden and data-icon="inline-start". The rest is on the Spinner page.




