Skip to content

UIProgressBar

Defined in: ui/src/UIProgressBar.ts:23

A progress bar with track and fill backgrounds.

new UIProgressBar(props): UIProgressBar

Defined in: ui/src/UIProgressBar.ts:42

UIProgressBarProps

UIProgressBar

UIElementBase.constructor

readonly _transform: ElementTransform

Defined in: ui/src/UIElementBase.ts:20

Internal

UIElementBase._transform


readonly container: DisplayContainer

Defined in: ui/src/UIProgressBar.ts:24


readonly yogaNode: Node

Defined in: ui/src/UIProgressBar.ts:25

UIElementBase.yogaNode

get displayObject(): DisplayContainer

Defined in: ui/src/UIProgressBar.ts:27

DisplayContainer

UIElementBase.displayObject


get rotation(): number

Defined in: ui/src/UIElementBase.ts:50

See LayoutProps.rotation.

number

set rotation(value): void

Defined in: ui/src/UIElementBase.ts:54

number

void

UIElementBase.rotation


get scale(): Readonly<{ x: number; y: number; }>

Defined in: ui/src/UIElementBase.ts:41

See LayoutProps.scale.

Readonly<{ x: number; y: number; }>

set scale(value): void

Defined in: ui/src/UIElementBase.ts:45

number | { x: number; y: number; }

void

UIElementBase.scale


get transformOrigin(): Readonly<{ x: number; y: number; }>

Defined in: ui/src/UIElementBase.ts:32

See LayoutProps.transformOrigin.

Readonly<{ x: number; y: number; }>

set transformOrigin(value): void

Defined in: ui/src/UIElementBase.ts:36

number | { x: number; y: number; }

void

UIElementBase.transformOrigin


get value(): number

Defined in: ui/src/UIProgressBar.ts:113

Fill fraction, 0 to 1, as last set. Reads back what update({ value }) clamped, which is not necessarily what was passed in.

number


get visible(): boolean

Defined in: ui/src/UIProgressBar.ts:117

boolean

set visible(v): void

Defined in: ui/src/UIProgressBar.ts:121

boolean

void

UIElementBase.visible


get zIndex(): number

Defined in: ui/src/UIElementBase.ts:59

See LayoutProps.zIndex.

number

set zIndex(value): void

Defined in: ui/src/UIElementBase.ts:63

number

void

UIElementBase.zIndex

_inspectState(): object

Defined in: ui/src/UIProgressBar.ts:175

Internal

What the Inspector reports for this progress bar: whether it takes part in focus navigation, which is off unless the game asked for it, and whether it holds focus right now. A test reads this instead of a screenshot.

object

focusable: boolean

focused: boolean


applyLayout(): void

Defined in: ui/src/UIProgressBar.ts:98

Size track to full computed size, fill proportionally to value.

void


protected applyTransformProps(props): void

Defined in: ui/src/UIElementBase.ts:27

Apply the four transform props present in props. A present key holding undefined resets that prop to its default. Throws before writing anything if a value is not finite.

LayoutProps

void

UIElementBase.applyTransformProps


destroy(): void

Defined in: ui/src/UIProgressBar.ts:180

Idempotent — a second call is a no-op.

void

UIElementBase.destroy


update(p): void

Defined in: ui/src/UIProgressBar.ts:126

Partial<UIProgressBarProps>

void

UIElementBase.update

Coding agents: fetch https://yage.dev/llms.txt first and prefer the Markdown references it links over these HTML pages. This page's Markdown counterpart is /llms/packages/ui.md.