-
Notifications
You must be signed in to change notification settings - Fork 0
/
transition-orientation.html
52 lines (40 loc) · 1.25 KB
/
transition-orientation.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
48
49
50
51
52
<!DOCTYPE html>
<html lang="pt-BR">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Animações JS -Orientação da transição</title>
<link rel="stylesheet" href="node_modules/animate.css/animate.min.css">
<link rel="stylesheet" href="node_modules/bootstrap/dist/css/bootstrap.min.css">
<style>
.fade-transition-enter-active, .fade-transition-leave-active {
transition: opacity .3s ease-in-out;
}
.fade-transition-enter, .fade-transition-leave-to {
opacity: 0;
}
</style>
</head>
<body>
<div id="transitions">
<h1>Hcode Treinamentos Animações</h1>
<input type="text" v-model="name">
<transition
name="fade-transition"
mode="out-in"
>
<h3 v-if="name.length > 10" key="success" class="alert-success">Nome válido</h3>
<h4 v-else key="error" class="alert-danger">Nome incorreto</h4>
</transition>
</div>
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<script>
let app = new Vue({
el: '#transitions',
data: {
name: 'George Lucas'
}
})
</script>
</body>
</html>