diff --git a/.changeset/remove-xs-size.md b/.changeset/remove-xs-size.md new file mode 100644 index 0000000000..142d7454bd --- /dev/null +++ b/.changeset/remove-xs-size.md @@ -0,0 +1,14 @@ +--- +"@cloudflare/kumo": major +--- + +**BREAKING:** Remove the `xs` size variant from `Button`, `Input`, `InputArea`, `InputGroup`, `Select`, `Combobox`, `Autocomplete`, `SensitiveInput`, and `Toolbar`. + +The type unions no longer include `"xs"` and the runtime `KUMO_*_VARIANTS.size` objects no longer contain an `xs` entry. Passing `size="xs"` will fail TypeScript compilation. Migrate to `size="sm"` — it is the next visual step and remains available. + +**`Banner`:** A `size="sm"` Banner used to render its `Banner.Action` children at Button's `xs` size (h-5). It now renders them at `sm` (h-6.5) instead. `Banner.Action` accepts only `size="sm"` as a consequence. + +**Unaffected:** + +- `Text` — `xs` is a legitimate typographic step (12px) and stays. +- `Banner.Action` — the type still exists but is narrowed to `"sm"` only. diff --git a/packages/kumo-docs-astro/src/components/demos/AutocompleteDemo.tsx b/packages/kumo-docs-astro/src/components/demos/AutocompleteDemo.tsx index bec1fb4cc4..615cc9136e 100644 --- a/packages/kumo-docs-astro/src/components/demos/AutocompleteDemo.tsx +++ b/packages/kumo-docs-astro/src/components/demos/AutocompleteDemo.tsx @@ -210,22 +210,10 @@ export function AutocompleteGroupedDemo() { ); } -/** Demonstrates the four size variants: xs, sm, base, and lg. */ +/** Demonstrates the three size variants: sm, base, and lg. */ export function AutocompleteSizesDemo() { return (
- - - - - {(item: string) => ( - - {item} - - )} - - - diff --git a/packages/kumo-docs-astro/src/components/demos/ButtonDemo.tsx b/packages/kumo-docs-astro/src/components/demos/ButtonDemo.tsx index 7fade2087e..df67f88ee9 100644 --- a/packages/kumo-docs-astro/src/components/demos/ButtonDemo.tsx +++ b/packages/kumo-docs-astro/src/components/demos/ButtonDemo.tsx @@ -42,9 +42,6 @@ export function ButtonSecondaryDestructiveDemo() { export function ButtonSizesDemo() { return (
- diff --git a/packages/kumo-docs-astro/src/components/demos/InputAreaDemo.tsx b/packages/kumo-docs-astro/src/components/demos/InputAreaDemo.tsx index b4f9696153..ce99967564 100644 --- a/packages/kumo-docs-astro/src/components/demos/InputAreaDemo.tsx +++ b/packages/kumo-docs-astro/src/components/demos/InputAreaDemo.tsx @@ -48,11 +48,6 @@ export function InputAreaErrorObjectDemo() { export function InputAreaSizesDemo() { return (
- diff --git a/packages/kumo-docs-astro/src/components/demos/InputDemo.tsx b/packages/kumo-docs-astro/src/components/demos/InputDemo.tsx index 77af223fa0..abfa1dfe0d 100644 --- a/packages/kumo-docs-astro/src/components/demos/InputDemo.tsx +++ b/packages/kumo-docs-astro/src/components/demos/InputDemo.tsx @@ -50,7 +50,6 @@ export function InputErrorObjectDemo() { export function InputSizesDemo() { return (
- diff --git a/packages/kumo-docs-astro/src/components/demos/InputGroupDemo.tsx b/packages/kumo-docs-astro/src/components/demos/InputGroupDemo.tsx index 4adb7052aa..d773c775da 100644 --- a/packages/kumo-docs-astro/src/components/demos/InputGroupDemo.tsx +++ b/packages/kumo-docs-astro/src/components/demos/InputGroupDemo.tsx @@ -226,21 +226,6 @@ export function InputGroupSuffixDemo() { export function InputGroupSizesDemo() { return (
- - - - - - - - - - diff --git a/packages/kumo-docs-astro/src/components/demos/PopoverDemo.tsx b/packages/kumo-docs-astro/src/components/demos/PopoverDemo.tsx index b33afd6e6a..8c7dd1f973 100644 --- a/packages/kumo-docs-astro/src/components/demos/PopoverDemo.tsx +++ b/packages/kumo-docs-astro/src/components/demos/PopoverDemo.tsx @@ -200,7 +200,7 @@ export function PopoverVirtualAnchorDemo() { {row.status}