Interface in @minecraft/server
Text with optional translation, as chat and titles take it.
import type { RawMessage } from '@minecraft/server';Properties
Section titled “Properties”optional
text?: string;Literal text.
translate
Section titled “translate”optional
translate?: string;A translation key. Basalt sends the key itself, untranslated.
rawtext
Section titled “rawtext”optional
rawtext?: RawMessage[];Parts joined in order.
Used by
Section titled “Used by”ItemStack.getRawLore, ItemStack.setLore, ContainerSlot.getRawLore, ContainerSlot.setLore, TitleDisplayOptions.subtitle, ScreenDisplay.setTitle, ScreenDisplay.updateSubtitle, ScreenDisplay.setActionBar, BossBar.setTitle, Player.sendMessage, Player.sendToast, Player.addBossBar, World.sendMessage, World.say, BlockSignComponent.setText, ItemBookComponent.rawContents, ItemBookComponent.getRawPageContent, ItemBookComponent.insertPage, ItemBookComponent.setContents, ItemBookComponent.setPageContent, TextPrimitive.text, TextPrimitive.constructor, TextPrimitive.setText, RawText.rawtext