From 0bae15e8c330da4d6b3988ee978dd17ef54bc1c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=B6khan=20Gurbeto=C4=9Flu?= Date: Tue, 16 Oct 2018 06:23:15 +0300 Subject: [PATCH] Clarification of the declaration order overriding (#19046) * Clarification of the declaration order overriding Previous text was talking about an override but it may also confuse readers that the override was done in the order of the listing of class names inside the h1. I also added an extra case to better clarify the situation. * Small change mentioning the order of declaration Missed an order of declaration emphasis on my previous commit, adding it on this one. --- ...rride-class-declarations-by-styling-id-attributes.english.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/curriculum/challenges/english/01-responsive-web-design/basic-css/override-class-declarations-by-styling-id-attributes.english.md b/curriculum/challenges/english/01-responsive-web-design/basic-css/override-class-declarations-by-styling-id-attributes.english.md index 36f500de3f..0b6104d113 100644 --- a/curriculum/challenges/english/01-responsive-web-design/basic-css/override-class-declarations-by-styling-id-attributes.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/basic-css/override-class-declarations-by-styling-id-attributes.english.md @@ -7,7 +7,7 @@ videoUrl: 'https://scrimba.com/c/cRkpDhB' ## Description
-We just proved that browsers read CSS from top to bottom. That means that, in the event of a conflict, the browser will use whichever CSS declaration came last. +We just proved that browsers read CSS from top to bottom in order of their declaration. That means that, in the event of a conflict, the browser will use whichever CSS declaration came last. Notice that if we even had put blue-text before pink-text in our h1 element's classes, it would still look at the declaration order and not the order of their use! But we're not done yet. There are other ways that you can override CSS. Do you remember id attributes? Let's override your pink-text and blue-text classes, and make your h1 element orange, by giving the h1 element an id and then styling that id.