Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
douban-api-proxy
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
captainwong
douban-api-proxy
Commits
52be2ad4
Commit
52be2ad4
authored
Oct 03, 2021
by
Ozzie Isaacs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improved DJVU Reader
parent
43fdef5e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
41 additions
and
36 deletions
+41
-36
Djvu_html5.css
cps/static/css/libs/Djvu_html5.css
+4
-4
djvu_reader.js
cps/static/js/reading/djvu_reader.js
+21
-0
readdjvu.html
cps/templates/readdjvu.html
+16
-32
No files found.
cps/static/css/libs/Djvu_html5.css
View file @
52be2ad4
...
...
@@ -35,7 +35,7 @@ body {
float
:
left
;
width
:
40px
;
height
:
40px
;
background-image
:
url("img/toolbar-buttons.png")
;
background-image
:
url("
../../js/libs/djvu_html5/
img/toolbar-buttons.png")
;
background-repeat
:
no-repeat
;
background-size
:
500%
300%
;
}
...
...
@@ -185,10 +185,10 @@ _:-ms-lang(x), .textLayer {
width
:
128px
;
height
:
128px
;
margin
:
-72px
0
0
-64px
;
background-image
:
url("img/status.png")
;
background-image
:
url("
../../js/libs/djvu_html5/
img/status.png")
;
background-repeat
:
no-repeat
;
}
.blankImage
{
background-image
:
url("img/blank.jpg")
;
}
\ No newline at end of file
background-image
:
url("../../js/libs/djvu_html5/img/blank.jpg")
;
}
cps/static/js/reading/djvu_reader.js
0 → 100644
View file @
52be2ad4
/* This file is part of the Calibre-Web (https://github.com/janeczku/calibre-web)
* Copyright (C) 2021 Ozzieisaacs
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
var
DJVU_CONTEXT
=
{
background
:
"#666"
,
uiHideDelay
:
1500
,
};
cps/templates/readdjvu.html
View file @
52be2ad4
<!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, maximum-scale=1, user-scalable=no"
>
<link
type=
"text/css"
rel=
"stylesheet"
href=
"{{ url_for('static', filename='js/libs/djvu_html5/Djvu_html5.css') }}"
>
<title>
{{_('DJVU Reader')}} | {{title}}
</title>
<script
type=
"text/javascript"
language=
"javascript"
src=
"{{ url_for('static', filename='js/libs/djvu_html5/djvu_html5/djvu_html5.nocache.js') }}"
></script>
</head>
<body>
<!-- RECOMMENDED if your web app will not function without JavaScript enabled -->
<noscript>
<div
style=
"width: 22em; position: absolute; left: 50%; margin-left: -11em; color: red; background-color: white; border: 1px solid red; padding: 4px; font-family: sans-serif"
>
Your web browser must have JavaScript enabled in order for this
application to display correctly.
</div>
</noscript>
<div
id=
"djvuContainer"
file=
"{{ url_for('web.serve_book', book_id=djvufile,book_format='djvu') }}"
></div>
<script
type=
"text/javascript"
>
var
DJVU_CONTEXT
=
{
background
:
"#666"
,
uiHideDelay
:
1500
,
};
</script>
</body>
<head>
<meta
http-equiv=
"content-type"
content=
"text/html; charset=UTF-8"
>
<title>
{{_('DJVU Reader')}} | {{title}}
</title>
<meta
name=
"description"
content=
""
>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
>
<meta
name=
"apple-mobile-web-app-capable"
content=
"yes"
>
<link
rel=
"apple-touch-icon"
sizes=
"140x140"
href=
"{{ url_for('static', filename='favicon.ico') }}"
>
<link
rel=
"shortcut icon"
href=
"{{ url_for('static', filename='favicon.ico') }}"
>
<link
type=
"text/css"
rel=
"stylesheet"
href=
"{{ url_for('static', filename='css/libs/Djvu_html5.css') }}"
>
<script
src=
"{{ url_for('static', filename='js/libs/djvu_html5/djvu_html5/djvu_html5.nocache.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/reading/djvu_reader.js') }}"
></script>
</head>
<body>
<div
id=
"djvuContainer"
file=
"{{ url_for('web.serve_book', book_id=djvufile, book_format='djvu') }}"
></div>
</body>
</html>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment