enes

Number Box

The NumberBox component allows users to input numeric values with specified constraints such as minimum, maximum, and step values.

Usage

<script>
	import { NumberBox } from 'fluentui-svelte';
</script>

<NumberBox aria-label="Quantity" value={0} min={0} max={100} step={1} />

Shape

Set shape to rounded (default), square, or circular.

Variant

The variant prop determines the visual style of the NumberBox.

Form Control Attributes

Attributes and events apply to the native form field; ref gives you access to it. For the container, use wrapperAttributes and wrapperRef.

Component Props

NameTypeDefaultDescription
value bindablenumber | nullThe current value of the input.
variant'inline' | 'compact''inline'How the increment and decrement buttons are laid out.
TextBoxProps without type
Edit this Doc View as Markdown