1
1
<!DOCTYPE html>
2
+ <!--suppress HtmlFormInputWithoutLabel -->
2
3
< html lang ="en ">
3
4
< head >
4
5
< meta charset ="UTF-8 ">
5
6
< title > Movie Exploder!</ title >
6
7
7
8
< link rel ="stylesheet " href ="../css/bootstrap/css/bootstrap.css ">
8
9
< link rel ="stylesheet " href ="../css/site.css ">
10
+ < link rel ="stylesheet " href ="../css/dropdown.css ">
9
11
10
12
</ head >
11
13
< body >
12
14
13
- < div class ="card " id ="app ">
14
- < h1 > Movie Exploder</ h1 >
15
+ < div class ="card " id ="app ">
16
+ < h1 > Movie Exploder</ h1 >
15
17
16
- < div class ="controls ">
17
- <!--suppress HtmlFormInputWithoutLabel -->
18
- < input type ="text " v-model ="search_text "
19
- class ="form-control "
20
- placeholder =" Search for a movie by keyword "
21
- @keyup.enter ="search() "
22
- >
18
+ < div class ="controls ">
19
+ <!--suppress HtmlFormInputWithoutLabel -->
20
+ < input type ="text " v-model ="search_text "
21
+ class ="form-control "
22
+ placeholder =" Search for a movie by keyword "
23
+ @keyup.enter ="search() "
24
+ >
23
25
24
- < div class ="subcontrols ">
26
+ < div class ="subcontrols ">
25
27
26
- < a class ="top_10 " @click ="top_10() "> Top 10</ a >
28
+ < a class ="top_10 " @click ="top_10() "> Top 10</ a >
27
29
28
- < select v-model ="selected_genre ">
29
- < option v-for ="g in genres " :value ="g "> {{g}}</ option >
30
- </ select >
31
-
32
- </ div >
30
+ < select v-model ="selected_genre "
31
+ @change ="load_genre(selected_genre) ">
32
+ < option v-for ="g in genres " :value ="g "> {{g}}</ option >
33
+ </ select >
33
34
34
35
</ div >
35
36
36
- < div class ="movies ">
37
- < div class ="movie " v-for ="m in movies ">
38
- < div class ="title "> {{m.title.toLocaleUpperCase()}}</ div >
39
- < div class ="attributes ">
40
- < span class ="year " v-if ="m.year > 0 "> {{m.year}}</ span >
41
- < span class ="year " v-else > NO YEAR</ span >
42
- < span class ="rating " v-if ="m.rating "> {{m.rating}}</ span >
43
- < span class ="score "> score {{m.imdb_score}}</ span >
44
- </ div >
45
- < div class ="genres ">
46
- < span class ="badge badge-info " v-for ="g in m.genres "> {{g}}</ span >
47
- </ div >
37
+ </ div >
38
+
39
+ < div class ="movies ">
40
+ < div class ="movie " v-for ="m in movies ">
41
+ < div class ="title "> {{m.title.toLocaleUpperCase()}}</ div >
42
+ < div class ="attributes ">
43
+ < span class ="year " v-if ="m.year > 0 "> {{m.year}}</ span >
44
+ < span class ="year " v-else > NO YEAR</ span >
45
+ < span class ="rating " v-if ="m.rating "> {{m.rating}}</ span >
46
+ < span class ="score "> score {{m.imdb_score}}</ span >
47
+ </ div >
48
+ < div class ="genres ">
49
+ < span class ="badge badge-info " v-for ="g in m.genres "> {{g}}</ span >
48
50
</ div >
49
51
</ div >
50
52
</ div >
53
+ </ div >
51
54
52
- < script src ="../js/vue/vue.js "> </ script >
53
- < script src ="../js/fake_data.js "> </ script >
54
- < script src ="../js/site.js "> </ script >
55
+ < script src ="../js/vue/vue.js "> </ script >
56
+ < script src ='https://cdnjs.cloudflare.com/ajax/libs/jquery/2.2.2/jquery.min.js '> </ script >
57
+ < script src ="../js/fake_data.js "> </ script >
58
+ < script src ="../js/site.js "> </ script >
59
+ < script src ="../js/dropdown.js "> </ script >
55
60
56
61
</ body >
57
62
</ html >
0 commit comments