messages

package
v1.9.7 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2022 License: GPL-2.0 Imports: 5 Imported by: 0

Documentation

Rendered for js/wasm

Index

Constants

This section is empty.

Variables

View Source
var ActiveMessages = RunNewMessages()

Functions

func ToPX

func ToPX(px int) string

func ToPercent

func ToPercent(percent int) string

func ToRem

func ToRem(rem int) string

func ToVW

func ToVW(vw int) string

Types

type Message

type Message struct {
	Type    string
	Content string

	Expire time.Time
	// contains filtered or unexported fields
}

func (*Message) Expired

func (m *Message) Expired() bool

func (*Message) Remove

func (m *Message) Remove()

type Messages

type Messages struct {
	Active          []*Message
	StopMessageLoop chan struct{}
	// contains filtered or unexported fields
}

func NewMessages

func NewMessages() *Messages

func RunNewMessages

func RunNewMessages() *Messages

func (*Messages) Delete added in v1.9.5

func (m *Messages) Delete(msg *Message)

func (*Messages) New added in v1.9.2

func (m *Messages) New(t string, c string, expireMS int, widthPX int) *Message

func (*Messages) NewError added in v1.9.2

func (m *Messages) NewError(c string, expire int, widthPX int) *Message

func (*Messages) NewInfo added in v1.9.2

func (m *Messages) NewInfo(c string, expire int, widthPX int) *Message

func (*Messages) NewSuccess added in v1.9.2

func (m *Messages) NewSuccess(c string, expire int, widthPX int) *Message

func (*Messages) NewWarning added in v1.9.2

func (m *Messages) NewWarning(c string, expire int, widthPX int) *Message

func (*Messages) Stop

func (m *Messages) Stop()

Jump to

Keyboard shortcuts

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