質問編集履歴
1
htmlとcssの追加
title
CHANGED
File without changes
|
body
CHANGED
@@ -67,4 +67,114 @@
|
|
67
67
|
}
|
68
68
|
});
|
69
69
|
}
|
70
|
+
```
|
71
|
+
|
72
|
+
```html
|
73
|
+
<!DOCTYPE html>
|
74
|
+
<html lang="ja">
|
75
|
+
<head>
|
76
|
+
<meta charset="UTF-8">
|
77
|
+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
78
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
79
|
+
<title>MyTodoList</title>
|
80
|
+
<link href="https://use.fontawesome.com/releases/v5.15.1/css/all.css" rel="stylesheet">
|
81
|
+
<link rel="stylesheet" href="css/style.css">
|
82
|
+
</head>
|
83
|
+
<body>
|
84
|
+
|
85
|
+
<div class="todo">
|
86
|
+
<header class="header">
|
87
|
+
<h1 class="title">Todo List</h1>
|
88
|
+
<button id="all-clear" type="button"><i class="far fa-trash-alt"></i></button>
|
89
|
+
</header>
|
90
|
+
<form id="list-form" name="listform">
|
91
|
+
<input id="add-value" type="text" placeholder="予定を入力">
|
92
|
+
<button id="add-btn" type="button">追加</button>
|
93
|
+
</form>
|
94
|
+
<ul id="add-list">
|
95
|
+
|
96
|
+
</ul>
|
97
|
+
</div>
|
98
|
+
|
99
|
+
<script src="js/main.js"></script>
|
100
|
+
|
101
|
+
</body>
|
102
|
+
</html>
|
103
|
+
```
|
104
|
+
|
105
|
+
```css
|
106
|
+
html {
|
107
|
+
font-size: 62.5%;
|
108
|
+
}
|
109
|
+
body {
|
110
|
+
font-size: 1.6rem;
|
111
|
+
}
|
112
|
+
button{
|
113
|
+
background-color: transparent;
|
114
|
+
border: none;
|
115
|
+
cursor: pointer;
|
116
|
+
outline: none;
|
117
|
+
padding: 0;
|
118
|
+
border: 3px solid #ccc;
|
119
|
+
appearance: none;
|
120
|
+
}
|
121
|
+
.header {
|
122
|
+
display: flex;
|
123
|
+
justify-content: space-between;
|
124
|
+
align-items: center;
|
125
|
+
}
|
126
|
+
.header h1{
|
127
|
+
font-weight: bold;
|
128
|
+
font-size: 4rem;
|
129
|
+
}
|
130
|
+
ul li {
|
131
|
+
list-style-type: disc;
|
132
|
+
font-size: 30px;
|
133
|
+
border-bottom: 2px solid rgba(189, 186, 186);
|
134
|
+
max-width: 500px;
|
135
|
+
margin: 0 auto;
|
136
|
+
padding: 10px 0;
|
137
|
+
}
|
138
|
+
.item {
|
139
|
+
display: flex;
|
140
|
+
justify-content: space-between;
|
141
|
+
margin-bottom: 20px;
|
142
|
+
}
|
143
|
+
.item-inner {
|
144
|
+
margin: 0;
|
145
|
+
}
|
146
|
+
#add-value {
|
147
|
+
font-size: 20px;
|
148
|
+
}
|
149
|
+
#all-clear {
|
150
|
+
display: block;
|
151
|
+
width: 100px;
|
152
|
+
font-size: 40px;
|
153
|
+
}
|
154
|
+
|
155
|
+
#add-btn {
|
156
|
+
font-size: 15px;
|
157
|
+
font-weight: bold;
|
158
|
+
}
|
159
|
+
|
160
|
+
.todo {
|
161
|
+
background-color: #eee;
|
162
|
+
max-width: 1000px;
|
163
|
+
margin: 0 auto;
|
164
|
+
}
|
165
|
+
|
166
|
+
.line-through {
|
167
|
+
text-decoration: line-through;
|
168
|
+
opacity: .7;
|
169
|
+
}
|
170
|
+
|
171
|
+
#add-list {
|
172
|
+
padding-left: 0;
|
173
|
+
}
|
174
|
+
|
175
|
+
#add-list li button {
|
176
|
+
font-size: 20px;
|
177
|
+
width: 40px;
|
178
|
+
vertical-align: top;
|
179
|
+
}
|
70
180
|
```
|