-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
47 lines (44 loc) · 1.89 KB
/
index.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
37
38
39
40
41
42
43
44
45
46
47
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
<link rel="stylesheet" href="index.css">
<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">
</head>
<body>
<div id="app">
<div class="container">
<header class="head">
<span>{{ title }}</span>
</header>
<form>
<div class="append-group">
<input id="inputField" class="form-control" type="text" placeholder="Add task" v-model="inputTask">
<button type="button" class=" btn-append btn btn-secondary" @click.prevent="addItem" >Add task</button>
</div>
</form>
<div class="container-task">
<div class="task-title"><span>Tasks</span></div>
<div class="task-items">
<transition-group name="fade">
<div class="container-task-descr" :key="task" v-for="(task, index) in tasks">
<div class="task-descr" :class="{'order-task': (index%2 !== 0)}">
<p>{{ task.task }}</p>
<button class="btn btn-danger" @click ="deleteItem(index)">
<span aria-hidden="true"> ×</span>
</button>
</div>
</div>
</transition-group>
</div>
</div>
</div>
</div>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<script type="text/javascript" src="/js/client/vue.js"></script>
</body>
</html>