A brief list of CSS property tables, listing some commonly used CSS properties.
Attribute name Attribute meaning Attribute value
Font properties (Font)
The following is the quoted content: font-family What font to use for all fonts font-style Whether the font is italic Normal, italic, oblique font-variant Whether to use small fonts and capitals Normal, small-caps font-weight font thickness Normal, bold, bolder, lithter, etc. font-size font size Absolute-size, relative-size, length, percentage, etc. |
Color and background properties
The following is the quoted content: Color defines the foreground color Background-color defines the background color color Background-image defines the background pattern path Background-repeat repeat mode Repeat-x, repeat-y, no-repeat Background-attachment sets scrolling Scroll, Fixed Background-position initial position Percentage, length, top, left, right, bottom, etc. |
text attribute
The following is the quoted content: Word-spacing The spacing between wordsNormal <length> Letter-spacing The spacing between lettersNormal <length> Text-decoration text decoration styleNone|underline|overline|line-through|blink Vertical-align vertical position Baseline|sub|super|top|text-top|middle|bottom|text-bottom Text-transform text conversion Capitalize|uppercase|lowercase|none Text-align alignmentLeft|right|center|justify Text-indent The indentation method of the first line<length>|<percentage> Line-height The line height of the textNormal|<number>|<length>|<percentage> |
Margin properties
The following is the quoted content: Margin-top top margin Length|percentage|auto Margin-right right margin Length|percentage|auto Margin-bottom bottom margin Length|percentage|auto Margin-left left margin Length|percentage|auto |
padding property
The following is the quoted content: Padding-top top padding distance Length|percentage Padding-right right padding distance Length|percentage Padding-bottom bottom padding distance Length|percentage Padding-left left padding distance Length|percentage |
Border properties
The following is the quoted content: Border-top-width Top border width Thin|medium|thick|length Border-right-width Right border width Thin|medium|thick|length Border-bottom-width bottom border width Thin|medium|thick|length Border-left-width left border width Thin|medium|thick|length Border-width once defines the width Thin|medium|thick|length Border-color sets the border color Color Border-style sets the border style None|dotted|dash|solid, etc. Border-top once defines the top Border-top-width|color, etc. Border-right defines the right Border-top-width|color, etc. once Border-bottom once defines the bottom Border-top-width|color, etc. Border-left defines the left Border-top-width|color, etc. once Width defines the width attribute Length|percentage|auto Height defines the height attribute Length|auto Float text wrappingLeft|right|none Clear Which side surrounds Left|right|none|both |
hierarchical properties
The following is the quoted content: Display defines whether to display Block, inline, list-item, none White-space How to deal with blank Normal, pre, nowrap List-style-type adds item number Disc, circle, square, etc. List-style-image add pattern<url>|none List-style-position The starting position of the second row is Inside, outside List-style defines list <keyword>|<position>|<url> once |
Mouse (Cursor) properties
The following is the quoted content: Auto |