Flashcards › Technology & Coding › Web Development
CSS Properties
Common CSS properties, selectors and values for styling web pages.
0 of 78 known
78 cards
- colorProperty or termSets the text color
- background-colorProperty or termSets the background color
- background-imageProperty or termSets a background picture
- font-familyProperty or termChooses the typeface
- font-sizeProperty or termSets the text size
- font-weightProperty or termSets how bold text is
- font-styleProperty or termSets italic or normal
- text-alignProperty or termAligns text left, center, right or justify
- text-decorationProperty or termAdds underline, overline or line-through
- text-transformProperty or termChanges case: uppercase, lowercase, capitalize
- line-heightProperty or termSets space between lines of text
- letter-spacingProperty or termSets space between letters
- widthProperty or termSets the width of an element
- heightProperty or termSets the height of an element
- max-widthProperty or termSets the largest width allowed
- min-heightProperty or termSets the smallest height allowed
- marginProperty or termSpace outside an element's border
- paddingProperty or termSpace inside an element between content and border
- borderProperty or termDraws a line around an element
- border-radiusProperty or termRounds the corners of an element
- box-shadowProperty or termAdds a shadow around an element
- text-shadowProperty or termAdds a shadow to text
- opacityProperty or termSets transparency from 0 to 1
- displayProperty or termSets how an element is shown: block, inline, flex, grid, none
- display: noneProperty or termHides an element and its space
- visibility: hiddenProperty or termHides an element but keeps its space
- positionProperty or termSets how an element is positioned: static, relative, absolute, fixed, sticky
- position: relativeProperty or termPositions an element compared to its normal spot
- position: absoluteProperty or termPositions an element relative to its nearest positioned parent
- position: fixedProperty or termKeeps an element in place when scrolling
- position: stickyProperty or termSticks an element once you scroll to it
- top, right, bottom, leftProperty or termOffsets for positioned elements
- z-indexProperty or termSets stacking order of overlapping elements
- floatProperty or termPushes an element to the left or right so text wraps around it
- overflowProperty or termControls what happens when content is too big
- box-sizing: border-boxProperty or termIncludes padding and border in an element's width
- Flexbox (display: flex)Property or termA layout system for rows or columns
- flex-directionProperty or termSets row or column in flexbox
- justify-contentProperty or termAligns flex items along the main axis
- align-itemsProperty or termAligns flex items along the cross axis
- flex-wrapProperty or termLets flex items wrap to the next line
- gapProperty or termSpace between flex or grid items
- flex-growProperty or termHow much an item grows to fill space
- Grid (display: grid)Property or termA two-dimensional layout system
- grid-template-columnsProperty or termDefines the columns of a grid
- grid-template-rowsProperty or termDefines the rows of a grid
- grid-columnProperty or termPlaces an item across columns
- SelectorProperty or termThe part of CSS that picks which elements to style
- Element selectorProperty or termTargets tags, like p { }
- Class selectorProperty or termTargets by class, like .box { }
- ID selectorProperty or termTargets by ID, like #main { }
- Descendant selectorProperty or termTargets elements inside others, like nav a { }
- Child selectorProperty or termTargets direct children only, like ul > li { }
- Universal selectorProperty or term* targets all elements
- Pseudo-classProperty or termA state selector like :hover or :focus
- Pseudo-elementProperty or termSelects part of an element like ::before or ::first-line
- SpecificityProperty or termThe rule deciding which style wins when rules conflict
- CascadeProperty or termStyles are combined in order and importance
- InheritanceProperty or termSome properties pass down from parent to child
- !importantProperty or termMakes a rule override others, to be used rarely
- Media queryProperty or termA rule that applies styles for certain screen sizes
- Responsive designProperty or termPages that adapt to different screen sizes
- Pixels (px)Property or termA fixed unit of size
- em unitProperty or termA size relative to the parent's font size
- rem unitProperty or termA size relative to the root font size
- Percent (%)Property or termA size relative to the parent
- vh and vwProperty or term1% of the viewport height or width
- Hex colorProperty or termA color written as #RRGGBB, like #FF0000
- rgb()Property or termA color written with red, green and blue values
- hsl()Property or termA color written with hue, saturation and lightness
- transitionProperty or termAnimates changes between styles
- transformProperty or termMoves, rotates, scales or skews an element
- animationProperty or termApplies keyframe animation
- @keyframesProperty or termDefines the steps of an animation
- CSS stands forProperty or termCascading Style Sheets
- CSS variableProperty or termA reusable value set with --name and used with var(--name)
- cursorProperty or termChanges the mouse pointer style
- list-styleProperty or termChanges bullets or numbers in lists
Download this deck
- CSVExcel, Google Sheets, Numbers
- Anki / Quizlet (tab-separated)Import straight into Anki or Quizlet
- JSONFor programmers and apps
- Plain textOne card a line, “front : back”, ready for Peabody's flashcard maker to print
Want paper cards? Paste the plain-text download into the flashcard maker.