Skip to content

@minecraft/server-ui


@minecraft/server-ui / ButtonOptions

Interface: ButtonOptions

Defined in: @minecraft/server-ui/index.d.ts:1513

Options for configuring a button component.

Properties

disabled?

optional disabled?: boolean | ObservableBoolean

Defined in: @minecraft/server-ui/index.d.ts:1520

Remarks

When true or bound to a true ObservableBoolean, the button is shown but cannot be pressed.


tooltip?

optional tooltip?: string | ObservableString | ObservableUIRawMessage | UIRawMessage

Defined in: @minecraft/server-ui/index.d.ts:1527

Remarks

Text shown in a tooltip when the player hovers over the button.


visible?

optional visible?: boolean | ObservableBoolean

Defined in: @minecraft/server-ui/index.d.ts:1534

Remarks

When false or bound to a false ObservableBoolean, the button is hidden.