Skip to content

Commit 89d57ed

Browse files
committed
to do logic
1 parent ee4a97d commit 89d57ed

File tree

6 files changed

+11
-5
lines changed

6 files changed

+11
-5
lines changed

blocks/to-do-list.css

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

blocks/to-do-list.css.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

blocks/to-do-list.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@
8585
&__text {
8686
margin-right: 5px;
8787
padding-top: 3px;
88+
overflow: clip;
8889
}
8990

9091
/**/

index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ <h1 class="main__title">Small JavaScript Projects</h1>
3333

3434
<div class="cards-block__column">
3535
<div class="cards-block__item">
36-
<a href="pages/counter.html" class="cards-block__image">
36+
<a href="pages/reviews.html" class="cards-block__image">
3737
<img src="images/main-page/02.png" alt="Reviews">
3838
</a>
3939
<a href="pages/counter.html" class="cards-block__title">Reviews</a>
@@ -114,7 +114,7 @@ <h1 class="main__title">Small JavaScript Projects</h1>
114114
</a>
115115
<a href="pages/counter.html"
116116
class="cards-block__title">To do list</a>
117-
<p class="cards-block__subtitle">...</p>
117+
<p class="cards-block__subtitle">Listing app.</p>
118118
</div>
119119
</div>
120120

pages/to-do-list.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ <h1 class="main__title">To Do List</h1>
2121
</button>
2222
</form>
2323
<div class="to-do__list">
24-
24+
<!-- tasks-->
2525
</div>
2626
</div>
2727
</div>

scripts/to-do-list.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ form.addEventListener('submit', (e) => {
5959

6060
createAndAppendButtons([listItem])
6161
list.appendChild(listItem)
62-
document.querySelector('.to-do__input').value = ''
62+
63+
const taskInput = document.querySelector('.to-do__input')
64+
65+
taskInput.value = ''
66+
taskInput.focus()
6367
})
6468

0 commit comments

Comments
 (0)