Documentation
¶
Overview ¶
Package htmlcss provides HTML/CSS related utilities
Index ¶
- func AddClassNames(original string, classes ...string) string
- func ParseHtmlTagAttributes(input interface{}) (attributes map[string]interface{}, err error)
- func ParseHtmlTagInlineKey(input string) (key string, ok bool)
- func ParseHtmlTagKeyValue(input string) (key, value string, ok bool)
- type CssClass
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddClassNames ¶
func ParseHtmlTagAttributes ¶
func ParseHtmlTagInlineKey ¶
func ParseHtmlTagKeyValue ¶
Types ¶
type CssClass ¶
type CssClass interface {
// Has returns true if the given class name is present within this
// CssClass instance
Has(name string) (present bool)
// Add appends the given class name to this CssClass instance
Add(name string)
// Rem removes the given class name from this CssClass instance
Rem(name string)
// List returns a list of the class names within this CssClass instance,
// in the order they were added
List() (list []string)
// Apply takes an HTML tag's class attribute value and adds all classes
// to this CssClass instance
Apply(class string)
// String returns the HTML class attribute value for this CssClass
// instance
String() (class string)
}
func ParseClass ¶
Click to show internal directories.
Click to hide internal directories.