# min-inline-size

> Applies `min-inline-size`.

```ts
import { minIs } from "@sdxc/u/size";
```

Applies `min-inline-size`.

## Quick reference

Every documented call, beside the CSS it emits.

| Call | CSS |
| --- | --- |
| `u.minIs(0)` | `css({ minInlineSize: "calc(var(--ui-spacing, 0.25rem) * 0)" })` |

## Examples

### Basic example

Use `minIs(n)` to give an element a minimum inline size, like buttons that stay at least `minIs(32)` wide however short their label:

```tsx
<div mix={[...]}>
	<button type="button" mix={[minIs(32), ...]}>
		OK
	</button>
	<button type="button" mix={[minIs(32), ...]}>
		Cancel
	</button>
	<button type="button" mix={[minIs(32), ...]}>
		Save and continue
	</button>
</div>
```

### Truncating inside flex

A flex item will not shrink below its content by default, so text truncated inside it overflows instead; use `minIs(0)` on the item to let it shrink:

```tsx
<div mix={[...]}>
	<div mix={[hstack({ gap: 3 }), is(72), ...]}>
		<div mix={[circle(), is(10), shrink(), ...]}>PDF</div>
		<div>
			<p mix={[truncate(), ...]}>
				quarterly-report-final-version-with-every-appendix.pdf
			</p>
		</div>
	</div>
	<div mix={[hstack({ gap: 3 }), is(72), ...]}>
		<div mix={[circle(), is(10), shrink(), ...]}>PDF</div>
		<div mix={[minIs(0)]}>
			<p mix={[truncate(), ...]}>
				quarterly-report-final-version-with-every-appendix.pdf
			</p>
		</div>
	</div>
</div>
```

## Using a custom value

Every scale argument also takes a raw CSS value, which passes through untouched.

```ts
u.minIs("2.75rem")
```

## Applying on a state

Wrap the call in a state utility to scope it to one selector.

```ts
u.hover(u.minIs(0))
```

## Responsive design

Wrap the call in a container query to scope it to one width.

```ts
u.at("md", u.minIs(0))
```

## Customizing your theme

### Customizing spacing

Every numeric step multiplies `--ui-spacing`, so redefining it rescales every spacing and sizing utility at once:

```css
:root {
	--ui-spacing: 0.25rem;
}
```

Every call that names the step now reads the new value:

```ts
minIs(4)
```

## Signature

```ts
u.minIs(value: SizeValue)
```
