File tree Expand file tree Collapse file tree 1 file changed +50
-0
lines changed
Expand file tree Collapse file tree 1 file changed +50
-0
lines changed Original file line number Diff line number Diff line change 1+ <!doctype html>
2+ < html lang ="en ">
3+
4+ < head >
5+ < meta charset ="utf-8 ">
6+ < title > Inheritance: simple example</ title >
7+ < link rel ="stylesheet " href ="../styles.css ">
8+ < style >
9+
10+ </ style >
11+
12+ < style class ="editable ">
13+ body {
14+ color : blue;
15+ }
16+
17+ span {
18+ color : black;
19+ }
20+ </ style >
21+ </ head >
22+
23+ < body >
24+ < section class ="preview ">
25+ < p > As the body has been set to have a color of blue this is inherited through the descendants.</ p >
26+ < p > We can change the color by targetting the element with a selector, such as this < span > span</ span > .</ p >
27+ </ section >
28+
29+ < textarea class ="playable playable-css " style ="height: 120px; ">
30+ body {
31+ color: blue;
32+ }
33+
34+ span {
35+ color: black;
36+ }
37+ </ textarea >
38+
39+ < textarea class ="playable playable-html " style ="height: 100px; ">
40+ < p > As the body has been set to have a color of blue this is inherited through the descendants.</ p >
41+ < p > We can change the color by targetting the element with a selector, such as this < span > span</ span > .</ p >
42+ </ textarea >
43+
44+ < div class ="playable-buttons ">
45+ < input id ="reset " type ="button " value ="Reset ">
46+ </ div >
47+ </ body >
48+ < script src ="../playable.js "> </ script >
49+
50+ </ html >
You can’t perform that action at this time.
0 commit comments