Documentation
¶
Index ¶
- Variables
- func Nest(xs ...any) (r *nest)
- func Rules(r ...*RuleStruct) *rules
- func Super(sel ...Selecter) Selecter
- type CssStringer
- type Import
- type RuleStruct
- func (me *RuleStruct) Child(sel Selecter, xs ...any) (i *RuleStruct)
- func (me *RuleStruct) Compose(parents ...*RuleStruct) (newrule *RuleStruct)
- func (me *RuleStruct) Copy() (newrule *RuleStruct)
- func (me *RuleStruct) Descendant(sel Selecter, xs ...any) (i *RuleStruct)
- func (me *RuleStruct) DirectFollows(sel Selecter, xs ...any) (i *RuleStruct)
- func (me *RuleStruct) Each(sel Selecter, xs ...any) (i *RuleStruct)
- func (me *RuleStruct) Embed(selector Selecter) (newrule *RuleStruct)
- func (me *RuleStruct) Follows(sel Selecter, xs ...any) (i *RuleStruct)
- func (me *RuleStruct) ForEach(c SelecterAdder, sel ...Selecter) *RuleStruct
- func (me *RuleStruct) Nest(xs ...any) (i *RuleStruct)
- func (me *RuleStruct) String() string
- func (me *RuleStruct) Style(kvpairs ...string) *RuleStruct
- func (me *RuleStruct) WithComment(comment string) *RuleStruct
Constants ¶
This section is empty.
Variables ¶
View Source
var ParentSelector = SelectorString("&")
Functions ¶
func Rules ¶
func Rules(r ...*RuleStruct) *rules
Types ¶
type CssStringer ¶
type CssStringer interface {
Css() string
}
type RuleStruct ¶
type RuleStruct struct { Comment string Selector Selecter Styling Styling Parent *RuleStruct // contains filtered or unexported fields }
func Css ¶
func Css(xs ...any) *RuleStruct
func Rule ¶
func Rule(xs ...any) (r *RuleStruct)
func (*RuleStruct) Child ¶
func (me *RuleStruct) Child(sel Selecter, xs ...any) (i *RuleStruct)
func (*RuleStruct) Compose ¶
func (me *RuleStruct) Compose(parents ...*RuleStruct) (newrule *RuleStruct)
returns a copy that is a composition of this rule with the styles of other rules
func (*RuleStruct) Descendant ¶
func (me *RuleStruct) Descendant(sel Selecter, xs ...any) (i *RuleStruct)
func (*RuleStruct) DirectFollows ¶
func (me *RuleStruct) DirectFollows(sel Selecter, xs ...any) (i *RuleStruct)
func (*RuleStruct) Each ¶
func (me *RuleStruct) Each(sel Selecter, xs ...any) (i *RuleStruct)
func (*RuleStruct) Embed ¶
func (me *RuleStruct) Embed(selector Selecter) (newrule *RuleStruct)
returns a copy that is embedded in the selector
func (*RuleStruct) Follows ¶
func (me *RuleStruct) Follows(sel Selecter, xs ...any) (i *RuleStruct)
func (*RuleStruct) ForEach ¶
func (me *RuleStruct) ForEach(c SelecterAdder, sel ...Selecter) *RuleStruct
for each selector, my selectors is prefixed and my rules are applied
func (*RuleStruct) Nest ¶
func (me *RuleStruct) Nest(xs ...any) (i *RuleStruct)
func (*RuleStruct) String ¶
func (me *RuleStruct) String() string
func (*RuleStruct) Style ¶
func (me *RuleStruct) Style(kvpairs ...string) *RuleStruct
adds given styles
func (*RuleStruct) WithComment ¶ added in v0.13.44
func (me *RuleStruct) WithComment(comment string) *RuleStruct
Click to show internal directories.
Click to hide internal directories.