css

package
v0.0.0-...-765903b Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2020 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Escape

func Escape(s string) string

Escape returns the string escaped and quoted in double quotes.

func WrapHTML

func WrapHTML(css string) template.HTML

func WrapHTMLTo

func WrapHTMLTo(w io.Writer, css string) error

Types

type Rule

type Rule struct {
	Selector   string
	Properties [][2]string
}

func Content

func Content(selector, content string) Rule

func Single

func Single(selector, key, value string) Rule

func (*Rule) AddProperty

func (r *Rule) AddProperty(property, value string)

func (Rule) CSS

func (r Rule) CSS() string

func (Rule) HTML

func (r Rule) HTML() template.HTML

func (*Rule) SetProperty

func (r *Rule) SetProperty(property, value string)

type Rules

type Rules []Rule

func (*Rules) AddRule

func (rs *Rules) AddRule(r Rule)

func (*Rules) CSS

func (rs *Rules) CSS() string

func (*Rules) HTML

func (rs *Rules) HTML() template.HTML

func (*Rules) SetProperty

func (rs *Rules) SetProperty(selector, property, value string)

func (*Rules) SetRule

func (rs *Rules) SetRule(r Rule)

Jump to

Keyboard shortcuts

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