Direct link to the article Platform News: Prefers Contrast, MathML, :is(), and CSS Background Initial Values

Platform News: Prefers Contrast, MathML, :is(), and CSS Background Initial Values

In this week’s round-up, prefers-contrast lands in Safari, MathML gets some attention, :is() is actually quite forgiving, more ADA-related lawsuits, inconsistent initial values for CSS Backgrounds properties can lead to unwanted — but sorta neat — patterns.…

Avatar of Šime Vidas
Šime Vidas on (Updated on )

background-position

The background-position property in CSS allows you to move a background image (or gradient) around within its container.

html {
  background-position: 100px 5px; 
}

It has three different types of values:

  • Length values (e.g. 100px 5px)
  • Percentages (e.g. 100%
Avatar of Chris Coyier
Chris Coyier on (Updated on )