Added Background Attachment details. (#30016)

* Added Background Attachment details.

Added the information on how to use background-attachment css property

* Added Background Attachment details

added the use of background-attachment property of css

* Add code formatting and reword
This commit is contained in:
Yash Srivastava
2019-03-10 19:30:11 +05:30
committed by The Coding Aviator
parent a5957dea75
commit e91089ccd6

View File

@ -65,6 +65,19 @@ If you do not want the background image to scroll with the rest of the page, use
background-attachment: fixed;
```
### Background Attachment
The background-attachment property sets whether a background image will scroll with the rest of the page, or would remain fixed.
```css
background-image: url("GitHub-Mark.png");
background-repeat: no-repeat;
background-attachment: fixed;
```
Valid Property Values: scroll, fixed, initial, local, inherit
### Shorthand property
You can pass all the properties in one super-property: