-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
100 lines (84 loc) · 3.23 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title></title>
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<meta name="description" content="">
<meta name="author" content="binux">
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/vue/1.0.21/vue.min.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/vue-resource/0.7.0/vue-resource.min.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/vue-router/0.7.13/vue-router.min.js"></script>
<script src="https://cdn.jsdelivr.net/webtorrent/latest/webtorrent.min.js"></script>
<link rel="stylesheet" href="https://cdn.rawgit.com/jabbany/ABPlayerHTML5/master/build/css/base.min.css">
<script src="https://cdn.rawgit.com/jabbany/ABPlayerHTML5/master/build/js/CommentCoreLibrary.min.js"></script>
<script src="https://cdn.rawgit.com/jabbany/ABPlayerHTML5/master/build/js/ABPlayer.min.js"></script>
<script src = "https://cdn.wilddog.com/js/client/current/wilddog.js" ></script>
<style>
body {
position: relative;
}
#app {
padding-bottom: 40px;
}
span.size {
float: right;
}
footer {
position: absolute;
height: 30px;
width: 100%;
bottom: 0;
margin: 10px 0;
}
.text-center {
text-align: center;
}
</style>
</head>
<body>
<div id='app'>
<h1><a v-link="{ path: '/' }">{{ glob }}</a></h1>
<hr>
<router-view></router-view>
</div>
<footer>
<div class="container">
<p class="text-center">a <a href="https://github.com/binux/" target="_blank">Binux</a>'s project.</p>
</div>
</footer>
<script type="x/template" id="filelist-template">
<ul>
<li v-for="file in files | orderBy 'name'">
<a v-link="{ name: 'video', params: { infohash: file.infoHash } }">{{ file.name }}</a>
<span class="size">{{ file.length | smart-file-size }}</span>
</li>
</ul>
</script>
<script type="x/template" id="video-template">
<p v-show="torrent===null">
infohash: {{ $route.params.infohash }}
grabing meta...
</p>
<div v-show="torrent">
<h2>{{ torrent.files[0].name }}</h2>
<dl>
<dt>infoHash</dt>
<dd><a href="{{ torrent.magnetURI }}">{{ torrent.infoHash }}</a></dd>
<dt>downloaded</dt>
<dd>{{ torrent.downloaded | smart-file-size }}@{{ downloadSpeed | smart-file-size }}/s FROM {{ torrent.numPeers }}conn ({{ (torrent.progress * 100).toFixed(1) }}%)</dd>
<dd v-show="download_link"><a id="save-link" href="{{ download_link }}" download="{{ torrent.files[0].name }}">save</a></dd>
<dt>timeRemaining</dt>
<dd>{{ (timeRemaining / 1000).toFixed(0) }}s</dd>
<dt>uploaded</dt>
<dd>{{ torrent.uploaded | smart-file-size }}@{{ uploadSpeed | smart-file-size }}/s</dd>
</dl>
<div id=video-view></div>
</div>
</script>
<script src="index.js"></script>
</body>
</html>
<!-- vim: set et sw=2 ts=2 sts=2 ff=unix fenc=utf8: -->