In CSS Documentation Value/Data Types are often written in angle brackets ’<>’ this doesn’t mean that they are html elements it just gives a distinction between a css property and a data type
Numeric Data Types
- Number based values
- used with or without units to define different styles
Integer Data Type
Whole number that can be negative or positive
Number Data Type
A whole number or fraction with decimals
Percentage Data type
A fraction of another value (usually a parent or ancestor element) that uses a <number> with a percentage unit
Dimension Data type
Is a number value with a unit
Represents data types such as <time> <resolution> <length> and more
<time> 12s, 5.5ms
<resolution> 96dpi, 3dppx
<length> 100px, 20vw
Length Data type
is used to define a distance value
Absolute
Fixed units based on physical measurements
Pixels(px) are used for web
px: pixles
cm: centimeters
mm: millimeters
Q: quarter-millimeters
in: inches
pt: points
Relative
Define a length based on another length
em is relative to the font size of an ancestor element
rem is relative to the root element