UITextProps
Defined in: ui/src/types.ts:491
Props for UIText (used by reconciler and props-driven constructor).
Extends
Section titled “Extends”Properties
Section titled “Properties”alignSelf?
Section titled “alignSelf?”
optionalalignSelf?:"auto"|"center"|"flex-start"|"flex-end"|"stretch"|"baseline"
Defined in: ui/src/types.ts:157
Inherited from
Section titled “Inherited from”bitmap?
Section titled “bitmap?”
optionalbitmap?:boolean
Defined in: ui/src/types.ts:517
Render with a bitmap font instead of canvas-rasterised Text. Pixel-art
escape hatch — canvas text blurs at non-integer scale on non-Retina
displays. Pixi bakes or looks up the glyph atlas from style.fontFamily
(the name an installBitmapFont call registered, or any font for a
dynamic bake) at style.fontSize. Yoga measurement (wrap / truncate) is
unchanged.
bottom?
Section titled “bottom?”
optionalbottom?:PositionValue
Defined in: ui/src/types.ts:183
Offset from the containing block’s bottom edge — px or "<n>%" (only applies to position: "absolute").
Inherited from
Section titled “Inherited from”children?
Section titled “children?”
optionalchildren?:string
Defined in: ui/src/types.ts:493
consumeInput?
Section titled “consumeInput?”
optionalconsumeInput?:boolean
Defined in: ui/src/types.ts:264
Inherited from
Section titled “Inherited from”ConsumeInputProps.consumeInput
optionalflex?:number
Defined in: ui/src/types.ts:156
Shorthand for the common CSS flex: <number> case — expands to
flexGrow: <number>, flexShrink: 1, flexBasis: 0. Use it for a child
that should fill the remaining main-axis space (e.g. the text column
between a fixed icon and a fixed button): sizing from a 0 basis means it
won’t claim its content width and push its siblings, and its text wraps
cleanly. Prefer this over flexGrow: 1 alone, which keeps flexBasis: auto
(content width) and overflows. Explicit flexGrow/flexShrink/flexBasis
override the parts this expands to.
Inherited from
Section titled “Inherited from”flexBasis?
Section titled “flexBasis?”
optionalflexBasis?:LayoutValue
Defined in: ui/src/types.ts:145
Inherited from
Section titled “Inherited from”flexGrow?
Section titled “flexGrow?”
optionalflexGrow?:number
Defined in: ui/src/types.ts:143
Inherited from
Section titled “Inherited from”flexShrink?
Section titled “flexShrink?”
optionalflexShrink?:number
Defined in: ui/src/types.ts:144
Inherited from
Section titled “Inherited from”focusable?
Section titled “focusable?”
optionalfocusable?:boolean
Defined in: ui/src/types.ts:376
Take part in focus navigation. Defaults to true for UIButton,
UICheckbox and the six interactive @pixi/ui wrappers, false for
everything else. false leaves the element enabled for the pointer.
Inherited from
Section titled “Inherited from”focusId?
Section titled “focusId?”
optionalfocusId?:string
Defined in: ui/src/types.ts:382
Name this element so a sibling’s FocusProps.focusNeighbors can point at it. Unique inside one scope: a duplicate id draws a development warning, and the first element in tree order answers to it.
Inherited from
Section titled “Inherited from”focusNeighbors?
Section titled “focusNeighbors?”
optionalfocusNeighbors?:FocusNeighbors
Defined in: ui/src/types.ts:384
Per-direction overrides of the position rule.
Inherited from
Section titled “Inherited from”focusStyle?
Section titled “focusStyle?”
optionalfocusStyle?:UIFocusStyle|null
Defined in: ui/src/types.ts:401
The focus outline for this element alone. Each field falls back to the
plugin-level focusStyle, then to the built-in default. null draws no
outline on this element.
Inherited from
Section titled “Inherited from”height?
Section titled “height?”
optionalheight?:LayoutValue
Defined in: ui/src/types.ts:135
Inherited from
Section titled “Inherited from”
optionalleft?:PositionValue
Defined in: ui/src/types.ts:177
Offset from the containing block’s left edge — px or "<n>%" (only applies to position: "absolute").
Inherited from
Section titled “Inherited from”margin?
Section titled “margin?”
optionalmargin?:number| {bottom?:number;left?:number;right?:number;top?:number; }
Defined in: ui/src/types.ts:140
Inherited from
Section titled “Inherited from”maxHeight?
Section titled “maxHeight?”
optionalmaxHeight?:LayoutValue
Defined in: ui/src/types.ts:139
Inherited from
Section titled “Inherited from”maxWidth?
Section titled “maxWidth?”
optionalmaxWidth?:LayoutValue
Defined in: ui/src/types.ts:137
Inherited from
Section titled “Inherited from”minHeight?
Section titled “minHeight?”
optionalminHeight?:LayoutValue
Defined in: ui/src/types.ts:138
Inherited from
Section titled “Inherited from”minWidth?
Section titled “minWidth?”
optionalminWidth?:LayoutValue
Defined in: ui/src/types.ts:136
Inherited from
Section titled “Inherited from”onAdjust?
Section titled “onAdjust?”
optionalonAdjust?: (direction) =>void
Defined in: ui/src/types.ts:395
Called with -1 for left and 1 for right while this element is
focused, consuming that press. Up and down still move focus.
Parameters
Section titled “Parameters”direction
Section titled “direction”-1 | 1
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”onFocusChange?
Section titled “onFocusChange?”
optionalonFocusChange?: (focused) =>void
Defined in: ui/src/types.ts:390
Called with true when focus arrives and false when it leaves,
including when the scope stops taking input. Use it to show focus without
an outline: a marker beside the row, a swapped sprite, a sound.
Parameters
Section titled “Parameters”focused
Section titled “focused”boolean
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”onHover?
Section titled “onHover?”
optionalonHover?: (hovering) =>void
Defined in: ui/src/types.ts:286
Parameters
Section titled “Parameters”hovering
Section titled “hovering”boolean
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”onPointerOut?
Section titled “onPointerOut?”
optionalonPointerOut?: () =>void
Defined in: ui/src/types.ts:285
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”PointerEventProps.onPointerOut
onPointerOver?
Section titled “onPointerOver?”
optionalonPointerOver?: () =>void
Defined in: ui/src/types.ts:284
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”PointerEventProps.onPointerOver
position?
Section titled “position?”
optionalposition?:"relative"|"absolute"
Defined in: ui/src/types.ts:175
Positioning mode for this element relative to its parent. Defaults to
"relative" — the element flows in the parent’s flex layout. Set to
"absolute" to lift the element out of the flow and pin it via
left / top / right / bottom against the parent’s content box.
A position: "relative" ancestor acts as the containing block for any
absolute-positioned descendants — useful for HUD overlays, modal
backdrops, and badge markers. See <ZStack> in @yagejs/ui-react for
an opinionated overlay primitive.
Inherited from
Section titled “Inherited from”resolution?
Section titled “resolution?”
optionalresolution?:number
Defined in: ui/src/types.ts:524
Per-text render resolution. Mirrors the Pixi v8 Text constructor
option — resolution is NOT a TextStyle property in v8, so this is
the only way to get crisp canvas text without a prototype patch.
Ignored when bitmap is set.
right?
Section titled “right?”
optionalright?:PositionValue
Defined in: ui/src/types.ts:181
Offset from the containing block’s right edge — px or "<n>%" (only applies to position: "absolute").
Inherited from
Section titled “Inherited from”rotation?
Section titled “rotation?”
optionalrotation?:number
Defined in: ui/src/types.ts:199
Rotation in radians about LayoutProps.transformOrigin. Default 0.
Inherited from
Section titled “Inherited from”scale?
Section titled “scale?”
optionalscale?:number| {x:number;y:number; }
Defined in: ui/src/types.ts:197
Scale about LayoutProps.transformOrigin, one number for both axes
or one per axis. Default 1. 0 and negative values are allowed.
Inherited from
Section titled “Inherited from”style?
Section titled “style?”
optionalstyle?:Partial<TextStyleOptions>
Defined in: ui/src/types.ts:494
optionaltop?:PositionValue
Defined in: ui/src/types.ts:179
Offset from the containing block’s top edge — px or "<n>%" (only applies to position: "absolute").
Inherited from
Section titled “Inherited from”transformOrigin?
Section titled “transformOrigin?”
optionaltransformOrigin?:number| {x:number;y:number; }
Defined in: ui/src/types.ts:192
The point scale and rotation turn about, as fractions of the
element’s computed size: 0 is the top-left corner, 0.5 the centre,
{ x: 0.5, y: 1 } the middle of the bottom edge. Default 0. This prop,
scale, rotation and zIndex change how the element is drawn, never
its Yoga box.
Inherited from
Section titled “Inherited from”truncate?
Section titled “truncate?”
optionaltruncate?:"clip"|"ellipsis"
Defined in: ui/src/types.ts:503
Overflow behavior when the rendered text is wider than the layout slot:
- omitted: wrap to the layout width (default)
"clip": render a single line; visible overflow is cut by the parent panel’soverflowsetting."ellipsis": render a single line truncated with UITextProps.truncateWith so the text fits within the layout width.
truncateWith?
Section titled “truncateWith?”
optionaltruncateWith?:string
Defined in: ui/src/types.ts:508
String the "ellipsis" truncate mode appends. Defaults to "…"
(U+2026), which several pixel fonts lack — pass "..." for one of those.
visible?
Section titled “visible?”
optionalvisible?:boolean
Defined in: ui/src/types.ts:184
Inherited from
Section titled “Inherited from”width?
Section titled “width?”
optionalwidth?:LayoutValue
Defined in: ui/src/types.ts:134
Inherited from
Section titled “Inherited from”zIndex?
Section titled “zIndex?”
optionalzIndex?:number
Defined in: ui/src/types.ts:206
Draw and pointer order among the siblings in the same container: a
higher value draws on top and takes the pointer first. Default 0;
siblings with equal values keep the order they were added in. To rise
above an element in a neighbouring container, raise that container.
Inherited from
Section titled “Inherited from”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.