Css2.1 syntax
haskell translation of css 2.1 grammar.
See http://www.w3.org/TR/CSS2/grammar.html and http://www.w3.org/TR/CSS2/syndata.html
- data StyleSheet = StyleSheet (Maybe AtCharSet) [AtImport] [StyleBody]
- data StyleBody
- data AtCharSet = AtCharSet String
- data AtImport = AtImport ImportHead [Ident]
- data ImportHead
- data AtMedia = AtMedia [Ident] [RuleSet]
- data AtPage = AtPage (Maybe Ident) (Maybe PseudoPage) [Decl]
- type PseudoPage = Ident
- data AtFontFace = AtFontFace [Decl]
- data RuleSet = RuleSet [Sel] [Decl]
- data Decl = Decl (Maybe Prio) Prop Expr
- type Prop = Ident
- data Prio = Important
- data Expr
- data Sel
- data SimpleSel
- data SubSel
- type Element = String
- data Attr
- type Class = String
- type Id = String
- type AttrIdent = String
- type AttrVal = String
- data PseudoVal
- data Value
- data Ident = Ident String
- data Func = Func Ident Expr
- data Deg = Deg Double
- data Rad = Rad Double
- data Grad = Grad Double
- data Color
- data Hz = Hz Double
- data KHz = KHz Double
- data Em = Em Double
- data Ex = Ex Double
- data Px = Px Int
- data In = In Double
- data Cm = Cm Double
- data Mm = Mm Double
- data Pc = Pc Double
- data Pt = Pt Int
- data Percentage = Percentage Double
- data Ms = Ms Double
- data S = S Double
- data Uri = Uri String
Stylesheet
data StyleSheet Source
AtRule
type PseudoPage = IdentSource
RuleSet
Selectors
Selector
Simple selector
attribute selector
Values
Primitives
data Percentage Source
<percentage>