-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtodo.html
36 lines (34 loc) · 1.21 KB
/
todo.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<!DOCTYPE html>
<html ng-app = "todo">
<head>
<meta charset="UTF-8">
<title> to do list </title>
<link rel="stylesheet" type="text/css" href="todo-styles.css">
</head>
<body>
<div class="everything" ng-controller = "TodoController as todo">
<header>
TO DOs
</header>
<main>
<input type = "text" class="genericBox insertTask" id = "insertTask" placeholder="Add task..." ng-enter = "todo.addTask()" ng-model = "toDoText" ng-change = "todo.check()"/>
<div class="genericBox task" ng-repeat = 'task in todo.tasks' >
<input type="checkbox" class= "checkbox" ng-model="task.done" ng-change = "todo.check()"/><input type="text" class = "taskText done-{{task.done}}" value="{{task.name}}"/><input type="submit" class="eraseButton" value="X" ng-click = "todo.deleteBox(task.name)" />
</div>
<div class="info" ng-show = "todo.tasks" >
{{ todo.getTodos() + " items left"}}
{{todo.getTos}}
</div>
</main>
<footer>
Thannia Blanchet's exercise at Nearsoft <br/>
Using Angular <br/>
July 2014
</footer>
<!-- PROBLEMS:
info div doesnt reload when you add or delete a task -->
</div>
<script src="angular.min.js"></script>
<script src="app.js"></script>
</body>
</html>