Skip to content

Interface: ControlSpec<T>

Defined in: control.ts:56

The single-options-object form the aiui compiler completes.

Extends

Type Parameters

T

T

Properties

description?

optional description?: string

Defined in: control.ts:73

Human description — compiler-lifted from the doc comment, or explicit.


loc?

optional loc?: string

Defined in: control.ts:75

Definition site "file:line" — compiler-injected.


max?

optional max?: number

Defined in: control.ts:46

Inclusive upper bound (numbers). Out-of-range writes are CLAMPED.

Inherited from

ControlMeta.max


min?

optional min?: number

Defined in: control.ts:44

Inclusive lower bound (numbers). Out-of-range writes are CLAMPED.

Inherited from

ControlMeta.min


name?

optional name?: string

Defined in: control.ts:62

Identity: durable key + tool name + grep target. Injected by the compiler from the assignment binding (export const kappa = control(…) → "kappa"); write it explicitly to rename a binding WITHOUT resetting durable state.


options?

optional options?: readonly T[]

Defined in: control.ts:52

Legal values (enums). A write outside the set THROWS.

Inherited from

ControlMeta.options


scope?

optional scope?: Scope

Defined in: control.ts:69

Instance qualifier for slice factories (see scope.ts): the effective identity becomes <scope>/<name>, so a slice instantiated twice gets two controls with two durable states instead of silently sharing one. The compiler still injects the LEAF name; the scope is runtime data.


step?

optional step?: number

Defined in: control.ts:48

Snap increment (numbers), anchored at min (else 0).

Inherited from

ControlMeta.step


unit?

optional unit?: string

Defined in: control.ts:50

Display unit ("eV", "ms") — presentation only.

Inherited from

ControlMeta.unit


value

value: T

Defined in: control.ts:71

Initial value (the durable registry adopts an existing one on hot edits).