Talos docs

UiProp

Since 0.6

What ctx.ui.set can write.

Plain text

Anything else is refused with ui.set.unknown-prop. A closed set, and everything on it is something a value changes. What is deliberately absent is structure: a binding cannot add a node, remove one or reorder a list, because that is a different tree and a different screen. Structure goes through {@link UiHandle.screen}, which re-registers and is diffed by id. text is the one binding that does not restyle — no selector matches on a node's text — so it is the cheap one, and it is the one a HUD does every frame.

Signature

export type UiProp =
  | "text"
  | "text-key"
  /**
   * What a `text-field` holds (U4).
   *
   * Writing it puts the caret at the end, which is what filling a form in means. Reading it
   * is {@link UiHandle.get}. The change gate applies, so a behaviour may write the same value
   * every frame for nothing.
   */
  | "value"
  | `text-param:${string}`
  | "disabled"
  | "selected"
  | "checked"
  | `data-${string}`
  | `class:${string}`
  | `style:${string}`

Import: import type { UiProp } from "@argus/api"