# LayerKeyProps

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

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

## Signature

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

## Properties

### definition

```ts
readonly definition: LayerDefinition;
```

The layer whose legend to draw.

### label

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

The list's accessible name, such as `Key for Earthquakes`.

### layout

```ts
readonly layout?: LayerKeyLayout;
```

How the rows sit: `wrap` (the default) side by side, wrapping as the
line fills; `stacked` one to a line, with the glyphs in a fixed-width
column so the words line up.

### testId

```ts
readonly testId: string;
```

The list's `data-testid`.

## See also

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

Source: [packages/map/src/layers/LayerKey.tsx:9](https://github.com/MapCairn/mapcairn/blob/main/packages/map/src/layers/LayerKey.tsx#L9)
