# `Overlays`

> 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 { Overlays } from '@holostep-configurators/runtime-client/contract';` · stable · since 2.0.0 · section 13. Overlays

Screen overlays. Declarative: the last call wins. Immediate configuration, not operations; during
a hold they apply at the reveal. A call made inside `work` is never staged, joined or rolled
back: a rollback or a supersede keeps the last call, which then shows over the old scene, so
set overlays for a generated product after its write resolves 'committed'. Style with `::part(badge)`, `::part(badge-label)`,
`::part(ruler)`, `::part(ruler-label)`. Runtime overlays are never in a capture. The default
badge's edge keeps 3:1 contrast over any part behind it (WCAG 1.4.11), and system colours in
forced-colors mode; a `::part(badge)` override keeps a 3:1 edge too.

## Members

| Member | Kind | Summary |
| --- | --- | --- |
| <a id="hotspots"></a>[`hotspots`](Overlays.hotspots.md) | property | Runtime-drawn `<button>` badges with a text label, at world points. |
| <a id="anchors"></a>[`anchors`](Overlays.anchors.md) | property | Points tracked for your own DOM; positions arrive through 'anchors:moved'. |
| <a id="dimensions"></a>[`dimensions`](Overlays.dimensions.md) | method | Rulers for the matched parts' bounds; null hides them. |

## Declaration

```ts
export interface Overlays {
  readonly hotspots: {
    set(badges: readonly HotspotBadge[]): void;
    clear?(): void;
  };
  readonly anchors: {
    set(anchors: readonly AnchorSpec[], options?: AnchorOptions): void;
    clear(): void;
  };
  dimensions(query: Query | null, options?: DimensionOptions): void;
}
```

## Generic-API test (spec 3.1)

| Rule | Result |
| --- | --- |
| 1. Neutral name | pass: `Overlays` names no product |
| 2. A precedent | not recorded: no ledger row (coverage.json) names this member or its owner |
| 3. Two apps, or labs | pass: 2 apps (fleet cross-check: app-37356bf09f, app-fd09090420) |
| 4. The cheaper fix first | not recorded per member (Appendix B decides it per need) |
