plugin-jm-server 0.1.17__tar.gz → 0.1.18__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/PKG-INFO +1 -1
  2. plugin_jm_server-0.1.18/src/plugin_jm_server/__init__.py +3 -0
  3. plugin_jm_server-0.1.18/src/plugin_jm_server/static/js/common.js +50 -0
  4. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/jm_view.html +17 -2
  5. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server.egg-info/PKG-INFO +1 -1
  6. plugin_jm_server-0.1.17/src/plugin_jm_server/__init__.py +0 -3
  7. plugin_jm_server-0.1.17/src/plugin_jm_server/static/js/common.js +0 -16
  8. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/README.md +0 -0
  9. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/setup.cfg +0 -0
  10. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/setup.py +0 -0
  11. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/app.py +0 -0
  12. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/driver.py +0 -0
  13. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/files.py +0 -0
  14. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/all.min.css +0 -0
  15. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/bootstrap.css +0 -0
  16. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/download_error.css +0 -0
  17. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/h5/m_download_error.css +0 -0
  18. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/h5/m_index.css +0 -0
  19. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/h5/m_login.css +0 -0
  20. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/h5/m_upload.css +0 -0
  21. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/h5/normalize.css +0 -0
  22. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/index.css +0 -0
  23. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/login.css +0 -0
  24. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/style_photo.css +0 -0
  25. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/css/upload.css +0 -0
  26. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/img/bg.jpg +0 -0
  27. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/img/m_bg.jpeg +0 -0
  28. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/js/h5/m_index.js +0 -0
  29. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/js/h5/m_upload.js +0 -0
  30. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/js/index.js +0 -0
  31. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/js/jquery-3.7.1.min.js +0 -0
  32. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/js/jquery.album-0.2.js +0 -0
  33. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/js/upload.js +0 -0
  34. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/webfonts/fa-regular-400.woff2 +0 -0
  35. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/static/webfonts/fa-solid-900.woff2 +0 -0
  36. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/download_error.html +0 -0
  37. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/index.html +0 -0
  38. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/login.html +0 -0
  39. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/m_download_error.html +0 -0
  40. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/m_index.html +0 -0
  41. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/m_jm_view.html +0 -0
  42. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/m_login.html +0 -0
  43. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/m_upload.html +0 -0
  44. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server/templates/upload.html +0 -0
  45. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server.egg-info/SOURCES.txt +0 -0
  46. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server.egg-info/dependency_links.txt +0 -0
  47. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server.egg-info/requires.txt +0 -0
  48. {plugin_jm_server-0.1.17 → plugin_jm_server-0.1.18}/src/plugin_jm_server.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: plugin_jm_server
3
- Version: 0.1.17
3
+ Version: 0.1.18
4
4
  Summary: plugin_jm_server, a plugin for jmcomic that can be used to view comics in a web browser.
5
5
  Home-page: https://github.com/hect0x7/plugin-jm-server
6
6
  Author: hect0x7
@@ -0,0 +1,3 @@
1
+ __version__ = '0.1.18'
2
+
3
+ from .app import *
@@ -0,0 +1,50 @@
1
+ document.addEventListener('DOMContentLoaded', () => {
2
+ // 右侧菜单采用双击显示/隐藏
3
+ const element = document.querySelector('.menu-bolock');
4
+ document.addEventListener('dblclick', () => {
5
+ if (element.style.display === 'none') {
6
+ element.style.display = 'block';
7
+ } else {
8
+ element.style.display = 'none';
9
+ }
10
+ });
11
+
12
+ // 跳转到底部
13
+ document.getElementById('gobottom')
14
+ .addEventListener('click', () => {
15
+ window.scrollTo(0, document.body.scrollHeight);
16
+ });
17
+
18
+ // 选择页码跳转图片
19
+ document.getElementById('pageselect').addEventListener('change', function () {
20
+ let selectedValue = this.value;
21
+ if (selectedValue !== null) {
22
+ const divid = "page_" + selectedValue;
23
+ let element = document.getElementById(divid);
24
+ if (element) {
25
+ let settop = element.offsetTop - 28 - document.getElementById('Comic_Top_Nav').offsetHeight;
26
+ window.scrollTo(0, settop);
27
+ }
28
+ document.getElementById('pageselect').value = selectedValue;
29
+ }
30
+ });
31
+
32
+ window.addEventListener('scroll', function () {
33
+ let wsTop = window.scrollY
34
+ let pageDivs = document.querySelectorAll('div[id*="page_"]');
35
+ let toPage = pageDivs.length - 1;
36
+
37
+ for (let div of pageDivs) {
38
+ let divTop = div.offsetTop;
39
+ if (divTop > wsTop) {
40
+ toPage = parseInt(div.getAttribute("data-page"));
41
+ break
42
+ }
43
+ }
44
+
45
+ console.log('toPage:', toPage)
46
+ document.getElementById('pageselect').value = toPage;
47
+ });
48
+
49
+
50
+ });
@@ -9,10 +9,10 @@
9
9
  <link href="../static/css/bootstrap.css" rel="stylesheet">
10
10
  <script src="../static/js/jquery-3.7.1.min.js"></script>
11
11
  <script src="../static/js/jquery.album-0.2.js"></script>
12
+ <script src="../static/js/common.js"></script>
12
13
  <link rel="stylesheet" href="../static/css/index.css">
13
14
  <link rel="stylesheet" href="../static/css/all.min.css">
14
15
  <link rel="stylesheet" href="../static/css/style_photo.css">
15
- <script src="../static/js/common.js"></script>
16
16
  <style>
17
17
  img {
18
18
  width: 100%;
@@ -25,6 +25,8 @@
25
25
  <body>
26
26
 
27
27
  <div class="container">
28
+ <div id="Comic_Top_Nav">
29
+ </div>
28
30
  <div class="row">
29
31
  <div style="padding:0">
30
32
  <div class="panel panel-default">
@@ -44,7 +46,10 @@
44
46
  </div>
45
47
  #}
46
48
  {% for image in data.images %}
47
- <div class="center scramble-page" id="{{ image.filename }}" >
49
+ <div class="center scramble-page"
50
+ id="page_{{ loop.index0 }}"
51
+ data-page="{{ loop.index0 }}"
52
+ >
48
53
  <img src="{{ image.data_original }}"
49
54
  data-original="{{ image.data_original }}"
50
55
  class="lazy_img img-responsive-mw lazy-loaded"
@@ -104,6 +109,16 @@
104
109
  <li>
105
110
  <a id="gobottom" href="javascript:void(0)"><i class="far fa-caret-square-up"></i><span>跳到最后</span></a>
106
111
  </li>
112
+ <div>
113
+ <!--suppress HtmlFormInputWithoutLabel -->
114
+ <select id="pageselect">
115
+ {% for image in data.images %}
116
+ <option value="{{ loop.index0 }}">
117
+ {{ loop.index }}/{{ loop.length }}
118
+ </option>
119
+ {% endfor %}
120
+ </select>
121
+ </div>
107
122
  </ul>
108
123
  </div>
109
124
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: plugin_jm_server
3
- Version: 0.1.17
3
+ Version: 0.1.18
4
4
  Summary: plugin_jm_server, a plugin for jmcomic that can be used to view comics in a web browser.
5
5
  Home-page: https://github.com/hect0x7/plugin-jm-server
6
6
  Author: hect0x7
@@ -1,3 +0,0 @@
1
- __version__ = '0.1.17'
2
-
3
- from .app import *
@@ -1,16 +0,0 @@
1
- document.addEventListener('DOMContentLoaded', () => {
2
- const element = document.querySelector('.menu-bolock');
3
- document.addEventListener('dblclick', () => {
4
- if (element.style.display === 'none') {
5
- element.style.display = 'block';
6
- } else {
7
- element.style.display = 'none';
8
- }
9
- });
10
-
11
- // id=gobottom,对这个元素实现跳转到页面最底部
12
- const bottom = document.getElementById('gobottom');
13
- bottom.addEventListener('click', () => {
14
- window.scrollTo(0, document.body.scrollHeight);
15
- });
16
- });