回答編集履歴
2
質問の変更に伴い追記
answer
CHANGED
@@ -10,4 +10,34 @@
|
|
10
10
|
.cssacc{
|
11
11
|
float:left;
|
12
12
|
}
|
13
|
+
```
|
14
|
+
|
15
|
+
# 質問の変更に伴い追記
|
16
|
+
|
17
|
+
```css
|
18
|
+
section {
|
19
|
+
position: relative;
|
20
|
+
}
|
21
|
+
|
22
|
+
input {
|
23
|
+
position: absolute;
|
24
|
+
top: calc( 14px + 0.5em );
|
25
|
+
margin: 0 1em;
|
26
|
+
}
|
27
|
+
|
28
|
+
label{
|
29
|
+
text-indent: 1em;
|
30
|
+
}
|
31
|
+
```
|
32
|
+
|
33
|
+
```html
|
34
|
+
<section>
|
35
|
+
<label for="label1">クリックして表示1</label>
|
36
|
+
<input type="checkbox" id="label1" class="cssacc" />
|
37
|
+
<div class="accshow">
|
38
|
+
<p>
|
39
|
+
こんにちは1
|
40
|
+
</p>
|
41
|
+
</div>
|
42
|
+
</section>
|
13
43
|
```
|
1
訂正
answer
CHANGED
@@ -7,4 +7,7 @@
|
|
7
7
|
/*display: block;*/
|
8
8
|
display: inline-block;
|
9
9
|
}
|
10
|
+
.cssacc{
|
11
|
+
float:left;
|
12
|
+
}
|
10
13
|
```
|