stylisehelper

package
v1.0.0-my-beta19 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 18, 2023 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type StyledTextRoot

type StyledTextRoot struct {
	StoArray []styling.StyledTextOption
}

StyledTextRoot is used to create an array of styling.StyledTextOption from the input string through its various methods.

func Start

Start function creates an StyledTextRoot with the provided styling.StyledTextOption.

func (*StyledTextRoot) Bold

func (sh *StyledTextRoot) Bold(s string) *StyledTextRoot

Bold appends the provided string as bold to the styled text root.

func (*StyledTextRoot) Code

func (sh *StyledTextRoot) Code(s string) *StyledTextRoot

Code appends the provided string as code/mono to the styled text root.

func (*StyledTextRoot) Italic

func (sh *StyledTextRoot) Italic(s string) *StyledTextRoot

Italic appends the provided string as italic to the styled text root.

func (sh *StyledTextRoot) Link(text, url string) *StyledTextRoot

Link appends the provided link to the styled text root.

func (*StyledTextRoot) Mention

func (sh *StyledTextRoot) Mention(text string, user interface{}) *StyledTextRoot

Mention creates a telegram user mention link with the provided user and text to display.

func (*StyledTextRoot) Plain

func (sh *StyledTextRoot) Plain(s string) *StyledTextRoot

Plain appends he provided string as plain text to the styled text root.

func (*StyledTextRoot) Spoiler

func (sh *StyledTextRoot) Spoiler(s string) *StyledTextRoot

Spoiler appends the provided string as spoiler to the styled text root.

func (*StyledTextRoot) Strike

func (sh *StyledTextRoot) Strike(s string) *StyledTextRoot

Strike appends the provided string as strike to the styled text root.

func (*StyledTextRoot) Underline

func (sh *StyledTextRoot) Underline(s string) *StyledTextRoot

Underline appends the provided string as underline to the styled text root.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL