definition change of :: before :: after pseudo elements (#44188)
This commit is contained in:
@ -9,7 +9,7 @@ dashedName: create-a-more-complex-shape-using-css-and-html
|
|||||||
|
|
||||||
# --description--
|
# --description--
|
||||||
|
|
||||||
One of the most popular shapes in the world is the heart shape, and in this challenge you'll create one using pure CSS. But first, you need to understand the `::before` and `::after` pseudo-elements. These pseudo-elements are used to add something before or after a selected element. In the following example, a `::before` pseudo-element is used to add a rectangle to an element with the class `heart`:
|
One of the most popular shapes in the world is the heart shape, and in this challenge you'll create one using pure CSS. But first, you need to understand the `::before` and `::after` pseudo-elements. ::before creates a pseudo-element that is the first child of the selected element; ::after creates a pseudo-element that is the last child of the selected element. In the following example, a `::before` pseudo-element is used to add a rectangle to an element with the class `heart`:
|
||||||
|
|
||||||
```css
|
```css
|
||||||
.heart::before {
|
.heart::before {
|
||||||
|
Reference in New Issue
Block a user