-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathlist.html
92 lines (87 loc) · 2.51 KB
/
list.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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=no" name="viewport">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="format-detection" content="telephone=no, email=no" />
<meta name="screen-orientation" content="portrait">
<meta name="full-screen" content="yes">
<meta name="x5-orientation" content="portrait">
<meta name="x5-fullscreen" content="true">
<meta name="msapplication-tap-highlight" content="no">
<meta name="description" content="" />
<meta name="keywords" content="" />
<meta content="dahuotu" name="author" />
<title>书架</title>
<link rel="shortcut icon" href="favicon.ico">
<link rel="Stylesheet" href="css/reset.css" />
<link rel="stylesheet" href="css/app.css" />
<script type="text/javascript" src="js/flexible.js"></script>
<style type="text/css">
</style>
</head>
<body>
<header>
书架
</header>
<div style="height: 1.1rem;"></div>
<div class="list" id="appform">
<ul class="book">
<template v-for="item in List">
<li @click="clickLink(item.url)">
<div class="img">
{{subBigTitle(item.title)}}
</div>
<div class="title">{{item.title}}</div>
</li>
</template>
</ul>
</div>
<div style="height: 1.1rem;"></div>
<footer>
<div class="nav-flex">
<div class="li" onclick="location.href='index.html'">
<div class="img">搜</div>
<div class="tips">搜小说</div>
</div>
<div class="li" onclick="location.href='list.html'">
<div class="img img-chk">架</div>
<div class="tips">书架</div>
</div>
<div class="li" onclick="location.href='setting.html'">
<div class="img">设</div>
<div class="tips">设置</div>
</div>
</div>
</footer>
</body>
<script type="text/javascript" src="js/vue.js"></script>
<script type="text/javascript" src="js/layer.m/layer.min.js"></script>
<script>
window.onload = function() {
app.getList();
}
var app = new Vue({
el: '#appform',
data: {
links: "",
List: "",
},
methods: {
getList: function() {
console.log(localStorage.valueOf());
var book = localStorage.getItem("bookJson");
app.List = JSON.parse('[' + book + ']');
},
subBigTitle: function(title) {
return title.substring(0, 1);
},
clickLink: function(href) {
location.href = 'read.html?cid=' + href;
},
}
});
</script>
</html>