message

package
v0.0.0-...-bc11ca3 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetCompatibleLanguage

func GetCompatibleLanguage(ctx context.Context, supportedTags []language.Tag) (language.Tag, structured_error.StructuredError)

func GetLanguage

func GetLanguage(ctx context.Context) language.Tag

func LoadMessages

func LoadMessages() error

func WithLanguage

func WithLanguage(ctx context.Context, tag language.Tag) context.Context

Types

type Localized

type Localized string

func AddDescription

func AddDescription(ctx context.Context, altText Localized, description Localized) Localized

func AddOCR

func AddOCR(ctx context.Context, description Localized, ocr Localized) Localized

func CombineDescriptions

func CombineDescriptions(ctx context.Context, descriptions []string) Localized

func CombineMessages

func CombineMessages(messages []Localized, joiner string) Localized

func HasAltText

func HasAltText(ctx context.Context, userDisplayName string, altText string) Localized

func HelpMessage

func HelpMessage(ctx context.Context) Localized

func LabelImage

func LabelImage(ctx context.Context, description Localized, index int) Localized

func NoAltText

func NoAltText(ctx context.Context, userDisplayName string) Localized

func UnknownCommandMessage

func UnknownCommandMessage(ctx context.Context) Localized

func Unlocalized

func Unlocalized(message string) Localized

func (Localized) IsEmpty

func (l Localized) IsEmpty() bool

Jump to

Keyboard shortcuts

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