React.Basic.Emotion
- Package
- purescript-react-basic-emotion
- Repository
- lumihq/purescript-react-basic-emotion
#ch Source
ch :: Number -> StylePropertyRelative to the width of the "0" (zero) character.
#IsStyleProperty Source
#cm Source
cm :: Number -> StylePropertyCentimeters
#color Source
color :: Color -> StyleProperty#css Source
css :: forall r. Homogeneous r StyleProperty => Record r -> Style#elementKeyed Source
elementKeyed :: forall props. ReactComponent { className :: String | props } -> { className :: String, css :: Style, key :: String | props } -> JSXCreate a JSX node from a ReactComponent, by providing the props.
This function is identical to React.Basic.element plus Emotion's
css prop.
#em Source
em :: Number -> StylePropertyRelative to the font-size of the element (2em means 2 times the size of the current font).
#ex Source
ex :: Number -> StylePropertyRelative to the x-height of the current font (rarely used).
#global Source
global :: ReactComponent { styles :: Style }#inches Source
inches :: Number -> StylePropertyInches (1in ≈ 2.54cm)
#int Source
int :: Int -> StylePropertyCreate a unitless Int property.
Wherever units may be specified, use unit combinators like px
or em instead.
#keyframes Source
keyframes :: forall r. Homogeneous r Style => Record r -> StyleProperty#mm Source
mm :: Number -> StylePropertyMilimeters
#nested Source
nested :: Style -> StyleProperty#num Source
num :: Number -> StylePropertyCreate a unitless Number property.
Wherever units may be specified, use unit combinators like px
or em instead.
#pc Source
pc :: Number -> StylePropertyPicas (1pc = 12 pt)
#percent Source
percent :: Number -> StylePropertyRelative to the parent element.
#pt Source
pt :: Number -> StylePropertyPoints (1pt = 1/72 of 1in)
#px Source
px :: Int -> StylePropertyPixels. This function does not take a Number because approaches to
subpixel rendering vary among browser implementations.
#px' Source
px' :: Number -> StylePropertyPixels and subpixels.
WARNING: Approaches to subpixel rendering vary among browser implementations. This means that non-integer pixel values may be displayed differently in different browsers.
#rem Source
rem :: Number -> StylePropertyRelative to font-size of the root element.
#row Source
row :: StyleProperty#str Source
str :: String -> StyleProperty#url Source
url :: URL -> StyleProperty#var Source
var :: String -> StylePropertyUse a variable name as a property.
Define a property somewhere:
css { "--color-primary": color blue }
Use the var:
css { color: var "--color-primary" }
#vh Source
vh :: Number -> StylePropertyRelative to 1% of the height of the viewport.
#vmax Source
vmax :: Number -> StylePropertyRelative to 1% of viewport's larger dimension.
#vmin Source
vmin :: Number -> StylePropertyRelative to 1% of viewport's smaller dimension.
#vw Source
vw :: Number -> StylePropertyRelative to 1% of the width of the viewport.
- Modules
- React.
Basic. Emotion