Versions in this module Expand all Collapse all v0 v0.6.0 Aug 11, 2026 Changes in this version + var DefaultPreset = Preset + var FormattedTextPreset = Preset + var NonInteractablePreset = Preset + var StandardTags standardTags + type ArgumentError struct + Message string + func (e *ArgumentError) Error() string + type ArgumentQueue struct + func (q *ArgumentQueue) HasNext() bool + func (q *ArgumentQueue) PeekOr(errorMessage string) string + func (q *ArgumentQueue) Pop() (value string, ok bool) + func (q *ArgumentQueue) PopOr(errorMessage string) string + func (q *ArgumentQueue) Remaining() int + func (q *ArgumentQueue) Rest() []string + type ModifyingTag interface + Apply func(current c.Component, depth int) c.Component + PostVisit func() + Visit func(node *Node) type Node + Tag Tag + type Option func(*options) + func WithDebug(fn func(string)) Option + func WithPreprocessor(p Preprocessor) Option + func WithStrict(strict bool) Option + func WithTagResolver(r TagResolver) Option + func WithTags(resolver TagResolver) Option + type ParserDirective int + const Reset + type Preprocessor func(input string) string + type Preset []Option + func (p Preset) Apply() Option + type StyleApplicable interface + func ClickStyle(ev c.ClickEvent) StyleApplicable + func ColorStyle(col mccolor.Color) StyleApplicable + func DecorationStyle(dec c.Decoration, on bool) StyleApplicable + func FontStyle(k key.Key) StyleApplicable + func HoverStyle(ev c.HoverEvent) StyleApplicable + func InsertionStyle(v string) StyleApplicable + func ShadowStyle(sc *c.ShadowColor) StyleApplicable + type Tag struct + func ComponentTag(comp c.Component) Tag + func DirectiveTag(d ParserDirective) Tag + func ModifyingTagValue(m ModifyingTag) Tag + func Parsed(value string) Tag + func StylingTag(styles ...StyleApplicable) Tag + func (t Tag) SelfClosing() Tag + type TagResolver interface + ResolveTag func(name string, args *ArgumentQueue) (tag Tag, ok bool) + func Resolver(name string, d ParserDirective) TagResolver + type TagResolverBuilder struct + func NewTagResolverBuilder() *TagResolverBuilder + func (b *TagResolverBuilder) Build() TagResolver + func (b *TagResolverBuilder) Resolver(r TagResolver) *TagResolverBuilder + type TagResolverFunc func(name string, args *ArgumentQueue) (Tag, bool) + func (f TagResolverFunc) ResolveTag(name string, args *ArgumentQueue) (Tag, bool) v0.5.1 Aug 9, 2026 v0.5.0 Aug 9, 2026 v0.4.0 Aug 9, 2026 v0.3.1 Aug 9, 2026 Changes in this version + func MustDeserialize(input string) *c.Text + type Kind int + const KindElement + const KindText + type Node struct + Args []string + Children []*Node + Closed bool + Kind Kind + Name string + SelfClosed bool + Text string v0.3.0 Aug 9, 2026 v0.2.1 Jul 31, 2026 Changes in this version + func ToMinekube(c *Component) component.Component type Component + func FromMinekube(mc component.Component) *Component v0.2.0 Jul 31, 2026 v0.1.0 Jul 30, 2026 Changes in this version + const Bold + const Italic + const Obfuscated + const Strikethrough + const Underlined + var AllDecorations = []string + func EscapeTags(input string, placeholders ...Placeholder) string + func NamedColorName(c *Color) string + func Parse(str string) string + func PlainText(c *Component) string + func Serialize(c *Component) string + func StripTags(input string, placeholders ...Placeholder) string + type ClickAction string + const ChangePage + const CopyToClipboard + const OpenFile + const OpenURL + const RunCommand + const SuggestCommand + type ClickEvent struct + Action ClickAction + Value string + type Color struct + B uint8 + G uint8 + R uint8 + func FromHex(s string) *Color + func HSVColor(h, s, v float64) *Color + func LerpColor(t float64, a, b *Color) *Color + func RGB(r, g, b uint8) *Color + func ResolveColor(name string) *Color + func (c *Color) Equal(o *Color) bool + func (c *Color) HexString() string + type Component struct + Children []*Component + Style Style + Text string + func Deserialize(input string, placeholders ...Placeholder) (*Component, error) + func DeserializeStrict(input string, placeholders ...Placeholder) (*Component, error) + func Empty() *Component + func Text(s string) *Component + func (c *Component) Append(children ...*Component) *Component + func (c *Component) Clone() *Component + type HoverAction string + const ShowText + type HoverEvent struct + Action HoverAction + Value *Component + type ParseError struct + Message string + func (e *ParseError) Error() string + type Placeholder struct + Component *Component + Name string + func ComponentPlaceholder(name string, c *Component) Placeholder + func StringPlaceholder(name, value string) Placeholder + func TextPlaceholder(name, miniMessage string) Placeholder + type Style struct + ClickEvent *ClickEvent + Color *Color + Decorations map[string]TriState + Font *string + HoverEvent *HoverEvent + Insertion *string + func NewStyle() Style + func (s Style) Clone() Style + func (s Style) IsEmpty() bool + func (s Style) Merge(other Style) Style + type TokenType int + const TokenCloseTag + const TokenOpenCloseTag + const TokenOpenTag + const TokenTagValue + const TokenText + type TriState int + const False + const True + const Unset