# `LabelSpec`

> Contract 2.0.0 · package sha256 `a857eca95b35921109faf997094bb4192f12527d9d0fcd4be7e97f06425bad6e` · generated from `configurator-runtime.d.ts` by `services/onsite-scripter/scripts/build-contract-docs.mjs`; edit the source, not this file.

Interface · `import type { LabelSpec } from '@holostep-configurators/runtime-client/contract';` · stable · since 2.0.0 · section 7. Collections and shapes

A label drawn in the scene (text or image on a quad facing the camera). Without [`onTop`](LabelSpec.onTop.md) it is
depth-tested against parts and writes no depth.

## Members

| Member | Kind | Summary |
| --- | --- | --- |
| <a id="text"></a>[`text?`](LabelSpec.text.md) | property | Plain text, on one line, centred in the quad, in `el`'s computed `font-family` and '#000000' with no plate, scaled uniformly to the largest size that fits inside `size`: never stretched or clipped, so a longer string… |
| <a id="image"></a>[`image?`](LabelSpec.image.md) | property | An image instead of text. |
| <a id="size"></a>[`size`](LabelSpec.size.md) | property | Width and height, metres: it scales with distance. |
| <a id="ontop"></a>[`onTop?`](LabelSpec.onTop.md) | property | Drawn over everything, as [`LinesSpec.onTop`](LinesSpec.onTop.md). |

## Declaration

```ts
export interface LabelSpec {
  text?: string;
  image?: TextureInput;
  size: Point2;
  onTop?: boolean;
}
```

## Generic-API test (spec 3.1)

| Rule | Result |
| --- | --- |
| 1. Neutral name | pass: `LabelSpec` names no product |
| 2. A precedent | pass: [Babylon.js SpriteManager](https://github.com/BabylonJS/Babylon.js/blob/master/packages/dev/core/src/Sprites/spriteManager.ts) (row `K50`); [model-viewer (ar, camera-orbit, auto-rotate)](https://modelviewer.dev/docs/) (row `K50`) |
| 3. Two apps, or labs | pass: 3 apps (ledger: app-ddfb017681, app-fc07850558, app-fc306ec3dc) |
| 4. The cheaper fix first | decided per need in Appendix B: rows `K50` at tier stable (a member only where no rule, data, asset or app code serves the need) |
