-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathangular.html
More file actions
34 lines (34 loc) · 1.5 KB
/
angular.html
File metadata and controls
34 lines (34 loc) · 1.5 KB
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
<!DOCTYPE html>
<html lang="fr" ng-app="demoApp">
<head>
<meta charset="utf-8" />
<title>Todo List</title>
<link rel="stylesheet" href="web/css/style.css">
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.3.12/angular.js"></script>
<script src="js/todoList.js"></script>
</head>
<body>
<header>
<h1>Todo List</h1>
</header>
<section ng-controller="todoCtrl">
<form id="todo-form" ng-submit="addTodo()">
<input id="new-todo" placeholder="Que devez-vous faire ?" ng-model="newTodo" />
</form>
<article ng-show="todos.length">
<ul id="todo-list">
<li ng-repeat="todo in todos" ng-class="{completed: todo.completed}">
<div class="view">
<input class="mark" type="checkbox" ng-model="todo.completed" />
<span>{{todo.title}}</span>
<span class="close" ng-click="removeTodo(todo)">x</span>
</div>
</li>
</ul>
<input id="mark-all" type="checkbox" ng-model="allChecked" ng-click="markAll(allChecked)" />
<label class="btn btn-info" for="mark-all">Tout cocher</label>
<button class="btn btn-danger" ng-click="clearCompletedTodos()">Supprimer les tâches cochées</button>
</article>
</section>
</body>
</html>