File tree Expand file tree Collapse file tree 1 file changed +12
-13
lines changed
docs/1-trial-session/03-css Expand file tree Collapse file tree 1 file changed +12
-13
lines changed Original file line number Diff line number Diff line change @@ -105,30 +105,29 @@ HTMLファイルとCSSファイルを分けて作成する場合、`style`属性
105105
106106## 演習問題1
107107
108- 下のような、文字色が黄色、背景色が好きな色 (この例では黒) の` Hello CSS! ` をブラウザで表示してみましょう。使用するプロパティは` color ` 、` background-color ` です。` style ` 属性を用いる方法と、CSSファイルを用いる方法の両方で試してみましょう。
108+ 次のように、` Hello CSS! ` と表示するページを作成してみましょう。
109+
110+ ` Hello CSS! ` という文字列を表示し、` color ` プロパティと` background-color ` プロパティを使って、文字色を黄色、背景色を黒色にしてください。
109111
110112![ Hello CSS!] ( yellow-hello-css.png )
111113
112114<Answer title = " Hello CSS!" >
113115
114116``` html title="index.html"
115- <!doctype html>
116- <html lang =" ja" >
117- <head >
118- <meta charset =" utf-8" />
119- <link rel =" stylesheet" href =" ./style.css" />
120- <title >Title</title >
121- </head >
122- <body >
123- <div style =" color : yellow ; background-color : black " >Hello CSS!</div >
124- </body >
125- </html >
117+ <div id =" greeting" >Hello CSS!</div >
126118```
127119
128- </Answer >
120+ ``` css title="style.css"
121+ #greeting {
122+ color : yellow ;
123+ background-color : black ;
124+ }
125+ ```
129126
130127<ViewSource url = { import .meta .url } path = " _samples/yellow-hello-css" />
131128
129+ </Answer >
130+
132131## 演習問題2
133132
134133次のような条件を満たす要素を選択するセレクタは何でしょうか。
You can’t perform that action at this time.
0 commit comments