forked from workhorsy/comic_book_reader
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
169 lines (157 loc) · 5.76 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
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
<title>Comic Book Reader</title>
<link type="image/x-icon" href="favicon.ico" rel="shortcut icon" />
<link type="text/css" href="styles.css" media="screen" rel="Stylesheet" />
<script src="js/polyfill.js"></script>
<script>
// Remove WWW from the URL start if present
let is_bad_url = false;
let pair = window.location.href.split('://');
let protocol = pair[0];
let host = pair[1];
if (host.startsWith('www.')) {
host = host.split('www.')[1];
is_bad_url = true;
}
// Change URL from http to https
if (protocol === 'http' && ! host.startsWith('localhost')) {
protocol = 'https';
is_bad_url = true;
}
// Redirect to the proper URL.
// We do this because localStorage and indexedDB will treat
// the domains as different.
if (is_bad_url) {
const new_url = protocol + '://' + host;
window.location = new_url;
}
</script>
<script src="js/i18n.js"></script>
<script src="js/no_more_jquery.js"></script>
<script src="js/utility.js"></script>
<script src="js/settings.js"></script>
<script src="js/db.js"></script>
<script src="js/pica.js"></script>
<script src="js/compatibility.js"></script>
<script src="js/pdf.js"></script>
<script src="js/pdf.worker.js"></script>
<script src="js/version_date.js"></script>
<script src="js/loader.js"></script>
<script src="js/languages.js"></script>
<script src="main.js"></script>
</head>
<body>
<!--<input id="fileInput" type="file" required="required" accept=".cbr, .cbz, .cbt, .rar, .zip, .tar" />-->
<input id="fileInput" type="file" required="required" />
<div id="welcomeScreen">
<div>
<h1 translatable=true>Comic Book Reader</h1>
<p translatable=true>
A touch friendly HTML5 comic book reader that reads CBR, CBZ, CBT, and PDF files.
</p>
<p>
<button id="btnInputTouch" class="touchButton" translatable=true>Start</button>
</p>
<footer>
Copyright © 2017 <a href="https://github.com/workhorsy/comic_book_reader">
Matthew Brennan Jones</a>
</footer>
</div>
</div>
<div id="mainUI" style="display: none;">
<div id="topMenu">
<div id="topMenuPanel" class="unselectable">
<div id="topMenuButtons">
<button id="btnFileLoad" class="touchButton" translatable=true>Open comic file</button>
<button id="btnLibrary" class="touchButton" translatable=true>Library</button>
<button id="btnFullScreen" class="touchButton" translatable=true>Full Screen</button>
<button id="btnSettings" class="touchButton" translatable=true>Settings</button>
</div>
<p><span id="loadError"></span></p>
<div id="comicData">
<span id="nameValue"></span><br>
</div>
<div>
<div id="lblTotalUsersOnline" style="display: none;">
<label translatable=true>Total users online</label> <span id="totalUsersOnline">?</span>
</div>
</div>
<div id="settingsMenu">
<div>
<p>
<label translatable=true>Language: </label>
<select id="btnSelectLanguage">
<option value="en">English</option>
<option value="ar">Arabic (عربى)</option>
<option value="zh">Chinese (中文)</option>
<option value="fr">French (français)</option>
<option value="de">German (Deutsche)</option>
<option value="ja">Japanese (日本語)</option>
<option value="pt">Portuguese (Português)</option>
<option value="ru">Russian (русский)</option>
<option value="es">Spanish (Español)</option>
</select>
</p>
<hr />
<p>
<input id="btnDisableRightClick" class="touchCheckBox" type="checkbox" />
<label for="btnDisableRightClick" class="touchLabel" translatable=true>Allow right click</label>
</p>
<p>
<input id="btnEnableInstallUpdates" class="touchCheckBox" type="checkbox" />
<label for="btnEnableInstallUpdates" class="touchLabel" translatable=true>Check for updates</label>
</p>
<p>
<input id="btnUseHigherQualityPreviews" class="touchCheckBox" type="checkbox" />
<label for="btnUseHigherQualityPreviews" class="touchLabel" translatable=true>Use higher quality page previews</label>
</p>
<p>
<input id="btnUseSmoothingWhenResizingImages" class="touchCheckBox" type="checkbox" />
<label for="btnUseSmoothingWhenResizingImages" class="touchLabel" translatable=true>Use smoothing when resizing images</label>
</p>
<hr />
<p>
<label translatable=true>Storage used:</label>
<span id="totalDBSize" style="margin: 4px;">. . .</span>
</p>
<p>
<button id="btnClearAllData" class="touchButton" translatable=true>Clear all data</button>
</p>
<hr />
<p>
<label translatable=true>Software Version:</label>
<span id="versionDate" style="margin: 4px;">...</span>
</p>
<p>
<button id="btnCheckForUpdatesNow" class="touchButton" translatable=true style="display: none;">Check for updates now</button>
</p>
<p>
<button id="btnHomepage" class="touchButton" translatable=true>Visit home page at github</button>
</p>
</div>
</div>
<div id="libraryMenu">
</div>
</div>
</div>
<div id="bottomMenu" class="unselectable">
<div id="bottomMenuPanel">
</div>
</div>
<div id="wallPaper">
<div id="loadingProgress" class="unselectable">
</div>
<div id="overlayPageNumber" class="unselectable">
</div>
<div id="comicPanel">
<div id="horizontalScroller">
</div>
</div>
</div>
</div>
</body>
</html>