clay-0.13.1: CSS preprocessor as embedded Haskell.

Safe HaskellNone
LanguageHaskell98

Clay.Size

Contents

Synopsis

Size type.

data Size a Source #

Instances

Fractional (Size Percentage) Source # 
Fractional (Size LengthUnit) Source # 
Num (Size Percentage) Source # 
Num (Size LengthUnit) Source # 
Show (Size a) Source # 

Methods

showsPrec :: Int -> Size a -> ShowS #

show :: Size a -> String #

showList :: [Size a] -> ShowS #

Val (Size a) Source # 

Methods

value :: Size a -> Value Source #

Other (Size a) Source # 

Methods

other :: Value -> Size a Source #

Normal (Size a) Source # 

Methods

normal :: Size a Source #

None (Size a) Source # 

Methods

none :: Size a Source #

Inherit (Size a) Source # 

Methods

inherit :: Size a Source #

Auto (Size a) Source # 

Methods

auto :: Size a Source #

VerticalAlign (Size a) Source # 

Methods

verticalAlign :: Size a -> Css Source #

Loc (Size a) Source # 

Methods

location :: Size a -> Location Source #

nil :: Size a Source #

Zero size.

unitless :: Double -> Size a Source #

Unitless size (as recommended for line-height).

Size constructors.

cm :: Double -> Size LengthUnit Source #

Size in centimeters.

mm :: Double -> Size LengthUnit Source #

Size in millimeters.

inches :: Double -> Size LengthUnit Source #

Size in inches (1in = 2.54 cm).

px :: Double -> Size LengthUnit Source #

Size in pixels.

pt :: Double -> Size LengthUnit Source #

Size in points (1pt = 1/72 of 1in).

pc :: Double -> Size LengthUnit Source #

Size in picas (1pc = 12pt).

em :: Double -> Size LengthUnit Source #

Size in em's (computed cssDoubleText of the font-size).

ex :: Double -> Size LengthUnit Source #

SimpleSize in ex'es (x-height of the first avaliable font).

pct :: Double -> Size Percentage Source #

SimpleSize in percents.

rem :: Double -> Size LengthUnit Source #

SimpleSize in rem's (em's, but always relative to the root element).

vw :: Double -> Size LengthUnit Source #

SimpleSize in vw's (1vw = 1% of viewport width).

vh :: Double -> Size LengthUnit Source #

SimpleSize in vh's (1vh = 1% of viewport height).

vmin :: Double -> Size LengthUnit Source #

SimpleSize in vmin's (the smaller of vw or vh).

vmax :: Double -> Size LengthUnit Source #

SimpleSize in vmax's (the larger of vw or vh).

Calculation operators for calc

(@+@) :: Size a -> Size b -> Size (SizeCombination a b) infixl 6 Source #

Plus operator to combine sizes into calc function

(@-@) :: Size a -> Size b -> Size (SizeCombination a b) infixl 6 Source #

Minus operator to combine sizes into calc function

(@*) :: Size a -> Double -> Size a infixl 7 Source #

Reversed times operator to combine sizes into calc function

(*@) :: Double -> Size a -> Size a infixl 7 Source #

Times operator to combine sizes into calc function

(@/) :: Size a -> Double -> Size a infixl 7 Source #

Division operator to combine sizes into calc function

Shorthands for properties that can be applied separately to each box side.

sym :: (a -> a -> a -> a -> Css) -> a -> Css Source #

sym2 :: (a -> a -> a -> a -> Css) -> a -> a -> Css Source #

sym3 :: (a -> a -> a -> a -> Css) -> a -> a -> a -> Css Source #

Angle type.

data Angle a Source #

Instances

Fractional (Angle Turn) Source # 
Fractional (Angle Grad) Source # 
Fractional (Angle Rad) Source # 
Fractional (Angle Deg) Source # 
Num (Angle Turn) Source # 
Num (Angle Grad) Source # 
Num (Angle Rad) Source # 
Num (Angle Deg) Source # 
Val (Angle a) Source # 

Methods

value :: Angle a -> Value Source #

Other (Angle a) Source # 

Methods

other :: Value -> Angle a Source #

Inherit (Angle a) Source # 

Methods

inherit :: Angle a Source #

Auto (Angle a) Source # 

Methods

auto :: Angle a Source #

Constructing angles.

deg :: Double -> Angle Deg Source #

Angle in degrees.

rad :: Double -> Angle Rad Source #

Angle in radians.

grad :: Double -> Angle Grad Source #

Angle in gradians (also knows as gons or grades).

turn :: Double -> Angle Turn Source #

Angle in turns.