Skip to content
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
135 changes: 13 additions & 122 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,132 +1,23 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="Let's do it is a simple to-do list and task manager">
<meta name="keywords" content="html,css,javascript,to-do,task-list">
<link rel="icon" type="image/ico" href="favicon.ico">
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<link type="text/css" rel="stylesheet" href="style.css">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Merienda&family=Poppins:wght@500&display=swap"
rel="stylesheet">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Merienda&family=Poppins:wght@500&display=swap"
rel="stylesheet">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="style.css">
<title>Let's Do It | ToDo List </title>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Todo List</title>
</head>

<body>
<header>
<div class="container">
<div class="row">
<div class="col-12">
<h1>
Let's Do It<br /><small>A Simple <span id="txt-pop">ToDo List</span> WebApp</small>
</h1>
</div>
</div>
</div>
</header>
<main>
<div class="main2">
<br>
<div class="container mt-3">
<h4>Add Items to The List</h4>

<label id="lblsuccess" class="text-success" style="display: none;">
</label>

<form id="addForm">
<div class="row">
<div class="col-lg-11 col-md-7 col-sm-7">
<input type="text" onkeyup="toggleButton(this, 'submit')" class="form-control" id="item">
</div>

<div class="col-lg-1 col-md-5 col-sm-5 mt-xs-2 mt-md-0">
<input type="submit" class="btn " id="submit" value="Add Task" disabled>
</div>
</div>
</form>

<h4 class="mt-4">Your Tasks</h4>

<form id="addForm">
<ul class="list-group" id="items"></ul>

</form>

<h4 class="mt-4">Completed Tasks</h4>

<form id="completeForm">
<ul class="list-group" id="completedItems"></ul>
<br>
</form>
</div>
<br>
<br>
</div>
</main>
<footer>
<div class="footer-1">
<div class="content">
<div class="left box">
<div class="upper">
<div class="topic">About</div>
<p><span class="quote"> &#8220; </span>Let's Do It!<span class="quote"> &#8221; </span> is a simple ToDo List webapp created using JavaScript, HTML &
CSS</p>
</div>
<div class="lower">
<div class="topic">Contact</div>
<div class="phone">
<a href="#"><i class="fa fa-volume-control-phone"></i>+91 123 456 7891</a>
</div>
<div class="email">
<a href="https://github.com/varunherlekar"><i class="fa fa-user-circle"></i>Varun
Herlekar</a>
<a href="https://type.fit/api/quotes"><i class="fa fa-user-circle"></i>Quotes
API:</a>
</div>
</div>
</div>
<div class="middle box">
<div class="topic">General Message </div>
<div><a href="#">LET'S DO IT,</a></div>
<div><small>A Simple <span id="txt-pop">ToDo List</span> WebApp</small></div>
<div><a href="#"><i class="fa fa-smile-o" , style="color:#e0b02c"></i>
<i class="fa fa-smile-o" , style="color:#e0b02c"></i>
<i class="fa fa-smile-o" , style="color:#e0b02c"></i></a></div>
</div>
<div class="right box">
<div class="topic">Feedback</div>
<form action="#">
<input type="text" placeholder="Enter your valuable feedback">
<input type="submit" name="" value="Send">
<div class="media-icons">
<h1>Todo List</h1>

<a class="Twitter" href="" target="_blank"><i class="fa fa-twitter"></i></a>
<a class="Instagram" href="" target="_blank"><i class="fa fa-instagram"></i></a>
<a class="linkedin" href="" target="_blank"><i class="fa fa-linkedin"></i></a>
<a class="Github" href="" target="_blank"><i class="fa fa-github-square"></i></a>
<a class="Blog" href="" target="_blank"><i class="fa fa-rss-square"></i></a>
</div>
</form>
</div>
</div>
<div class="bottom">
<p>Copyright © 2021 <a href="https://github.com/varunherlekar/lets-do-it"> Varun Herlekar </a> All rights reserved.</p>
<ul>
<li>"new" - Add A Todo List</li>
<li>"list" - List All Todos</li>
<li>"delete" - Remove Specific Todo</li>
<li>"quit" - Quit App</li>
</ul>
<script src="todos.js"></script>

</div>
</div>
</footer>
<script src="app.js" async></script>
</body>

</html>
</html>
37 changes: 37 additions & 0 deletions todos.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
let input = prompt('What would you like to do?');
const todos = ['Collect Chicken Eggs', 'Clean Litte Box'];
while (input !== 'quit' && input !== 'q') {
if (input === 'list') {
console.log('************************')
for (let i = 0; i < todos.length; i++) {
console.log(`${i}: ${todos[i]}`)
}
console.log('************************')

} else if (input === 'new') {
const newTodo = prompt('Ok, what is the new todo?');
todos.push(newTodo)
console.log(`${newTodo} added to the list!`)
}
else if(input === 'delete'){
const index = parseInt(prompt('Ok, enter an index to delete:'))
if(!Number.isNaN(index)){
const deleted = todos.splice(index, 1);
console.log(`Ok, deleted ${deleted}`)
} else{
console.log('Unknown index')
}
}
input = prompt('What would you like to do?')
}
console.log('OK, Quit the app!')