-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
126 lines (105 loc) · 5.19 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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
<!DOCTYPE html>
<html lang="en">
<head>
<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>Document</title>
<!-- js -->
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<script src="https://cdn.jsdelivr.net/npm/axios@0.21.1/dist/axios.min.js"></script>
<script src="js/script.js"></script>
<!-- css -->
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css">
<link rel="stylesheet" href="css/style.css">
</head>
<body>
<div id="app">
<div class="container">
<div class="row">
<div class="header-left">
<img src="https://image.tmdb.org/t/p/w342/wwemzKWzjKYJFfCeiB57q3r4Bcm.png" alt="">
<ul>
<li><a href="">Home</a></li>
<li><a href="">Serie TV</a></li>
<li><a href="">Film</a></li>
<li><a href="">Originali</a></li>
<li><a href="">Aggiunti di recente</a></li>
<li><a href="">La mia lista</a></li>
</ul>
</div>
<div class="header-right">
<input type="text" v-model="search">
<button @click="startSearch()">Cerca</button>
</div>
</div>
<div class="grid">
<!-- PRINT MOVIES -->
<div v-for="movie in printMovies" class="card movies">
<img v-if="movie.poster_path" :src="`https://image.tmdb.org/t/p/w342${movie.poster_path}`" alt="">
<!-- <img v-else :src="`https://image.tmdb.org/t/p/w342${movie.backdrop_path}`" alt=""> -->
<div class="to-hover">
<!-- title -->
<h4><span>Titolo: </span>{{ movie.title }}</h4>
<h5 v-if="movie.title != movie.original_title">
<span>Titolo originale: </span>
{{ movie.original_title }}
</h5>
<!-- rating -->
<div class="stars">
<i v-for="star in movie.vote_average" class="fas fa-star gold"></i>
<i v-for="star in (5 - movie.vote_average)" class="fas fa-star gray"></i>
</div>
<!-- info -->
<span class="genres">{{ movie.genre_names }}</span>
<p v-if="movie.actors" class="cast">Cast:
<span>
{{ movie.actors }}
</span>
</p>
<p v-if="movie.overview" class="overview">Overview: {{ movie.overview }}</p>
<img v-if="movie.flag" :src="movie.flag" alt="" class="flag">
<div v-else class="lang">
<p>{{ movie.original_language }}</p>
</div>
</div>
</div>
<!-- PRINT SERIES -->
<div v-for="serie in printSeries" class="card series">
<img v-if="serie.poster_path" :src="`https://image.tmdb.org/t/p/w342${serie.poster_path}`" alt="">
<div class="to-hover">
<!-- title -->
<h4><span>Titolo: </span>{{ serie.name }}</h4>
<h5 v-if="serie.name != serie.original_name">
<span>Titolo originale: </span>
{{ serie.original_name }}
</h5>
<!-- rating -->
<div class="stars">
<i v-for="star in serie.vote_average" class="fas fa-star gold"></i>
<i v-for="star in (5 - serie.vote_average)" class="fas fa-star"></i>
</div>
<!-- info -->
<span class="genres">{{ serie.genre_names }}</span>
<p v-if="serie.actors" class="cast">Cast:
<span>
{{ serie.actors }}
</span>
</p>
<p v-if="serie.overview" class="overview">Overview: {{ serie.overview }}</p>
<img v-if="serie.flag" :src="serie.flag" alt="" class="flag">
<div v-else class="lang">
<p>{{ serie.original_language }}</p>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
<!-- TODO
- attributi immagini con la chiave dell'item?
- sistemare stelline e numero stelline
- togliere ultima virgola in cast e genres
-->