vendor dependencies with dep
This commit is contained in:
parent
93d8310491
commit
1384296a47
2712 changed files with 965742 additions and 0 deletions
26
vendor/github.com/vanng822/css/styledeclaration.go
generated
vendored
Normal file
26
vendor/github.com/vanng822/css/styledeclaration.go
generated
vendored
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
package css
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
)
|
||||
|
||||
type CSSStyleDeclaration struct {
|
||||
Property string
|
||||
Value string
|
||||
Important int
|
||||
}
|
||||
|
||||
func NewCSSStyleDeclaration(property, value string, important int) *CSSStyleDeclaration {
|
||||
return &CSSStyleDeclaration{
|
||||
Property: property,
|
||||
Value: value,
|
||||
Important: important,
|
||||
}
|
||||
}
|
||||
|
||||
func (decl *CSSStyleDeclaration) Text() string {
|
||||
if decl.Important == 1 {
|
||||
return fmt.Sprintf("%s: %s !important", decl.Property, decl.Value)
|
||||
}
|
||||
return fmt.Sprintf("%s: %s", decl.Property, decl.Value)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue