Skip to content

xujiale todolist #7

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
125 changes: 125 additions & 0 deletions xujiale to-do list/css.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
body {
margin: 0px;
padding: 0px;
font-size: 16px;
background-color: gainsboro;
}
header {
height: 50px;
background-color: PURPLE;
}
header section {
margin: 0 auto;
width: 40%;
}

header section label {
float: left;
line-height: 50px;
font-size: 20px;
}

#add_list {
float: right;
margin-top: 11px;
width: 60%;
height: 24px;
border-radius: 5px;
box-shadow: 0 1px 0 black;
font-size: 18px;
text-indent: 10px;
}

h1 {
position: relative;
}

h1 span {
position: absolute;
top: 1px;
right: 5px;
display: inline-block;
width: 23px;
height: 50px;
border-radius: 23px;
line-height: 23px;
font-size: 18px;
text-align: center;
background: #D200D2;
}

.content {
width: 40%;
margin: 0 auto;
}

li {
position: relative;
margin-bottom: 10px;
border-radius: 5px;
padding: 0 10px;
height: 32px;
box-shadow: 0 1px 0 black;
line-height: 32px;
background-color: burlywood;
list-style: none;
}

ol li input {
position: absolute;
top: 4px;
left: 10px;
width: 20px;
height: 20px;
cursor: pointer;
}
p{
margin: 0;
}
ol li p {
display: inline;
margin-left: 35px;
}

ol li p input{
top: 5px;
margin-left: 35px;
width: 70%;
height: 14px;
font-size: 14px;
line-height: 14px;
}

ol li a {
position: absolute;
top: 8px;
right: 10px;
display: inline-block;
border: 1px;
border-radius: 50%;
width: 16px;
height: 16px;
font-size: 32px;
line-height: 10px;
color: red;
font-weight: bolder;
cursor: pointer;
background-color: gray;
}

#clear {
width: 100px;
margin: 0 auto;
}

#clearbutton {
border-color: red;
border-radius: 5px;
box-shadow: 0 1px 0 yellow;
cursor: pointer;
}

button h3{
font-size: 13px;
line-height: 13px;
}
32 changes: 32 additions & 0 deletions xujiale to-do list/html.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1个空格缩进的格式比较奇怪,目前我们团队里用的是4个空格

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

了解了

<title>todolist</title>
<link rel="stylesheet" href="css.css">
</head>
<body>

<header>
<section>
<label for="add_list">My todolist</label>
<input type="text" id="add_list" name="add_list" placeholder="type here" required>
</section>
</header>

<div class="content">
<h1>未完成<span id="todocount"></span></h1>
<ol id="todolist">
</ol>

<h1>已完成<span id="donecount"></span></h1>
<ol id="donelist">
</ol>
</div>

<div id="clear">
<span style="white-space:pre;"> </span><button id="clearbutton"><h3>清除</h3></button>
</div>
<script src="todolist-prime.js"></script>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里的JS文件缺失

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

那个时候上传的时候还没学好jsT_T

</body>
</html>