# SegmentedControlProps

Props for [`SegmentedControl`](https://docs.mapcairn.com/api/map/SegmentedControl.md).

This is an interface exported by `@mapcairn/map`, checked against version 0.2.0.

## Signature

```ts
import type { SegmentedControlProps } from "@mapcairn/map";
 
interface SegmentedControlProps
```

## Properties

### "data-testid"

```ts
readonly "data-testid"?: string;
```

Applied to the group. Each item gets the same id plus `-` and its value.

### className

```ts
readonly className?: string;
```

Applied to the group element.

### disabled

```ts
readonly disabled?: boolean;
```

Stops every item from being chosen and dims the group.

### label

```ts
readonly label: string;
```

Accessible name of the group, for example "Theme". Required.

### onValueChange

```ts
readonly onValueChange: (value: string) => void;
```

Called with the new value when the user picks a different item.

### options

```ts
readonly options: readonly SegmentedControlOption[];
```

The choices, in display order.

### value

```ts
readonly value: string;
```

The selected value. The component is controlled and always has a selection.

## See also

- [`SegmentedControlOption`](https://docs.mapcairn.com/api/map/SegmentedControlOption.md)

Source: [packages/map/src/ui/SegmentedControl/SegmentedControl.tsx:25](https://github.com/MapCairn/mapcairn/blob/main/packages/map/src/ui/SegmentedControl/SegmentedControl.tsx#L25)
