components

package
v0.0.0-...-cc2decb Latest Latest
Warning

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

Go to latest
Published: May 26, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ID    = "id"
	NAME  = "name"
	CLASS = "class"
	STYLE = "style"
)
View Source
const (
	FOR     = "for"
	CAPTION = "caption"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Component

type Component struct {
	Id    StringProperty
	Name  StringProperty
	Class StringSliceProperty
	Style StringSliceProperty
}

func (Component) HTML

func (component Component) HTML() (string, error)

type Label

type Label struct {
	For     StringProperty
	Caption StringProperty
}

type Page

type Page struct {
	Components []*Component
}

func NewPage

func NewPage() (*Page, error)

func (Page) HTML

func (page Page) HTML() (string, error)

type Property

type Property[T any] struct {
	// contains filtered or unexported fields
}

func (Property[T]) Get

func (property Property[T]) Get() T

func (Property[T]) HTML

func (property Property[T]) HTML() string

func (*Property[T]) Set

func (property *Property[T]) Set(data T)

type StringProperty

type StringProperty struct {
	Property[string]
}

func (StringProperty) HTML

func (stringProperty StringProperty) HTML() string

type StringSliceProperty

type StringSliceProperty struct {
	Property[[]string]
}

func (StringSliceProperty) HTML

func (stringSliceProperty StringSliceProperty) HTML() string

Jump to

Keyboard shortcuts

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