plugin-jm-server 0.2.2__tar.gz → 0.2.4__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 (63) hide show
  1. plugin_jm_server-0.2.4/PKG-INFO +34 -0
  2. plugin_jm_server-0.2.4/plugin_jm_server/__init__.py +21 -0
  3. plugin_jm_server-0.2.4/plugin_jm_server.egg-info/PKG-INFO +34 -0
  4. plugin_jm_server-0.2.4/plugin_jm_server.egg-info/SOURCES.txt +7 -0
  5. plugin_jm_server-0.2.4/plugin_jm_server.egg-info/requires.txt +1 -0
  6. plugin_jm_server-0.2.4/setup.py +43 -0
  7. plugin_jm_server-0.2.2/PKG-INFO +0 -196
  8. plugin_jm_server-0.2.2/README.md +0 -160
  9. plugin_jm_server-0.2.2/setup.py +0 -57
  10. plugin_jm_server-0.2.2/src/plugin_jm_server/__init__.py +0 -3
  11. plugin_jm_server-0.2.2/src/plugin_jm_server/app.py +0 -511
  12. plugin_jm_server-0.2.2/src/plugin_jm_server/driver.py +0 -88
  13. plugin_jm_server-0.2.2/src/plugin_jm_server/files.py +0 -175
  14. plugin_jm_server-0.2.2/src/plugin_jm_server/message.py +0 -135
  15. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/all.min.css +0 -5
  16. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/bootstrap.css +0 -7770
  17. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/download_error.css +0 -79
  18. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/h5/m_download_error.css +0 -91
  19. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/h5/m_index.css +0 -146
  20. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/h5/m_login.css +0 -107
  21. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/h5/m_message.css +0 -476
  22. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/h5/m_upload.css +0 -179
  23. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/h5/normalize.css +0 -349
  24. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/index.css +0 -729
  25. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/index_spa.css +0 -637
  26. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/login.css +0 -118
  27. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/message.css +0 -516
  28. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/style_photo.css +0 -1
  29. plugin_jm_server-0.2.2/src/plugin_jm_server/static/css/upload.css +0 -161
  30. plugin_jm_server-0.2.2/src/plugin_jm_server/static/img/bg.jpg +0 -0
  31. plugin_jm_server-0.2.2/src/plugin_jm_server/static/img/m_bg.jpeg +0 -0
  32. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/common.js +0 -195
  33. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/h5/m_index.js +0 -39
  34. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/h5/m_upload.js +0 -72
  35. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/index.js +0 -321
  36. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/index_spa.js +0 -896
  37. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/jquery-3.7.1.min.js +0 -2
  38. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/jquery.album-0.2.js +0 -8
  39. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/jquery.lazyload-2.0.js +0 -444
  40. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/jquery.photo-0.3.js +0 -427
  41. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/message.js +0 -301
  42. plugin_jm_server-0.2.2/src/plugin_jm_server/static/js/upload.js +0 -72
  43. plugin_jm_server-0.2.2/src/plugin_jm_server/static/webfonts/fa-regular-400.woff2 +0 -0
  44. plugin_jm_server-0.2.2/src/plugin_jm_server/static/webfonts/fa-solid-900.woff2 +0 -0
  45. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/download_error.html +0 -28
  46. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/index.html +0 -216
  47. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/index_spa.html +0 -144
  48. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/jm_view.html +0 -132
  49. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/login.html +0 -40
  50. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/m_download_error.html +0 -28
  51. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/m_index.html +0 -214
  52. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/m_jm_view.html +0 -128
  53. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/m_login.html +0 -43
  54. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/m_message.html +0 -84
  55. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/m_upload.html +0 -46
  56. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/message.html +0 -91
  57. plugin_jm_server-0.2.2/src/plugin_jm_server/templates/upload.html +0 -47
  58. plugin_jm_server-0.2.2/src/plugin_jm_server.egg-info/PKG-INFO +0 -196
  59. plugin_jm_server-0.2.2/src/plugin_jm_server.egg-info/SOURCES.txt +0 -55
  60. plugin_jm_server-0.2.2/src/plugin_jm_server.egg-info/requires.txt +0 -4
  61. {plugin_jm_server-0.2.2/src → plugin_jm_server-0.2.4}/plugin_jm_server.egg-info/dependency_links.txt +0 -0
  62. {plugin_jm_server-0.2.2/src → plugin_jm_server-0.2.4}/plugin_jm_server.egg-info/top_level.txt +0 -0
  63. {plugin_jm_server-0.2.2 → plugin_jm_server-0.2.4}/setup.cfg +0 -0
@@ -0,0 +1,34 @@
1
+ Metadata-Version: 2.4
2
+ Name: plugin_jm_server
3
+ Version: 0.2.4
4
+ Summary: [DEPRECATED] Renamed to jm-view-server. Installs jm-view-server and forwards to it.
5
+ Home-page: https://github.com/hect0x7/jm-view-server
6
+ Author: hect0x7
7
+ Author-email: 93357912+hect0x7@users.noreply.github.com
8
+ Keywords: python,jmcomic,jm-view-server,18comic,禁漫天堂,NSFW,deprecated
9
+ Classifier: Development Status :: 7 - Inactive
10
+ Requires-Python: >=3.7
11
+ Description-Content-Type: text/markdown
12
+ Requires-Dist: jm-view-server
13
+ Dynamic: author
14
+ Dynamic: author-email
15
+ Dynamic: classifier
16
+ Dynamic: description
17
+ Dynamic: description-content-type
18
+ Dynamic: home-page
19
+ Dynamic: keywords
20
+ Dynamic: requires-dist
21
+ Dynamic: requires-python
22
+ Dynamic: summary
23
+
24
+ # plugin_jm_server 已更名
25
+
26
+ 本包已更名为 **jm-view-server**,此处仅保留为兼容旧用户的重定向薄壳。
27
+
28
+ 请改用:
29
+
30
+ ```shell
31
+ pip install jm-view-server
32
+ ```
33
+
34
+ `import jm_view_server` 代替 `import plugin_jm_server`;CLI 命令 `jms` 与 jmcomic 插件 key `jm_server` 保持不变。
@@ -0,0 +1,21 @@
1
+ """
2
+ [已弃用] plugin_jm_server 已更名为 jm_view_server。
3
+
4
+ 本包仅为兼容旧用户保留,内部转发到新包 jm_view_server。
5
+ 请尽快改用: pip install jm-view-server, 并把 import 从
6
+ `plugin_jm_server` 改为 `jm_view_server`。CLI 命令 `jms` 与
7
+ jmcomic 插件 key `jm_server` 均保持不变。
8
+ """
9
+ import warnings
10
+
11
+ warnings.warn(
12
+ "plugin_jm_server 已更名为 jm_view_server,请改用 "
13
+ "`pip install jm-view-server` 并 `import jm_view_server`。"
14
+ "本包将在后续版本停止维护。",
15
+ DeprecationWarning,
16
+ stacklevel=2,
17
+ )
18
+
19
+ # 转发新包的公共 API 与版本,保证 `from plugin_jm_server import JmServer` 等旧用法可用
20
+ from jm_view_server import * # noqa: F401,F403
21
+ from jm_view_server import __version__ # noqa: F401
@@ -0,0 +1,34 @@
1
+ Metadata-Version: 2.4
2
+ Name: plugin_jm_server
3
+ Version: 0.2.4
4
+ Summary: [DEPRECATED] Renamed to jm-view-server. Installs jm-view-server and forwards to it.
5
+ Home-page: https://github.com/hect0x7/jm-view-server
6
+ Author: hect0x7
7
+ Author-email: 93357912+hect0x7@users.noreply.github.com
8
+ Keywords: python,jmcomic,jm-view-server,18comic,禁漫天堂,NSFW,deprecated
9
+ Classifier: Development Status :: 7 - Inactive
10
+ Requires-Python: >=3.7
11
+ Description-Content-Type: text/markdown
12
+ Requires-Dist: jm-view-server
13
+ Dynamic: author
14
+ Dynamic: author-email
15
+ Dynamic: classifier
16
+ Dynamic: description
17
+ Dynamic: description-content-type
18
+ Dynamic: home-page
19
+ Dynamic: keywords
20
+ Dynamic: requires-dist
21
+ Dynamic: requires-python
22
+ Dynamic: summary
23
+
24
+ # plugin_jm_server 已更名
25
+
26
+ 本包已更名为 **jm-view-server**,此处仅保留为兼容旧用户的重定向薄壳。
27
+
28
+ 请改用:
29
+
30
+ ```shell
31
+ pip install jm-view-server
32
+ ```
33
+
34
+ `import jm_view_server` 代替 `import plugin_jm_server`;CLI 命令 `jms` 与 jmcomic 插件 key `jm_server` 保持不变。
@@ -0,0 +1,7 @@
1
+ setup.py
2
+ plugin_jm_server/__init__.py
3
+ plugin_jm_server.egg-info/PKG-INFO
4
+ plugin_jm_server.egg-info/SOURCES.txt
5
+ plugin_jm_server.egg-info/dependency_links.txt
6
+ plugin_jm_server.egg-info/requires.txt
7
+ plugin_jm_server.egg-info/top_level.txt
@@ -0,0 +1 @@
1
+ jm-view-server
@@ -0,0 +1,43 @@
1
+ """
2
+ 旧包 plugin_jm_server 的打包脚本(重定向薄壳)。
3
+
4
+ 单独发布, 与主包 jm-view-server 互不干扰:
5
+ cd legacy_shim && python -m build && twine upload dist/*
6
+
7
+ 作用: 装了旧包名的用户 `pip install plugin_jm_server` 时,
8
+ 会自动带上新包 jm-view-server, 且旧的 import / `jms` 命令仍可用,
9
+ 运行时打印 DeprecationWarning 引导迁移。
10
+ """
11
+ from setuptools import setup, find_packages
12
+
13
+ setup(
14
+ name='plugin_jm_server',
15
+ version='0.2.4',
16
+ description='[DEPRECATED] Renamed to jm-view-server. Installs jm-view-server and forwards to it.',
17
+ long_description=(
18
+ '# plugin_jm_server 已更名\n\n'
19
+ '本包已更名为 **jm-view-server**,此处仅保留为兼容旧用户的重定向薄壳。\n\n'
20
+ '请改用:\n\n'
21
+ '```shell\n'
22
+ 'pip install jm-view-server\n'
23
+ '```\n\n'
24
+ '`import jm_view_server` 代替 `import plugin_jm_server`;'
25
+ 'CLI 命令 `jms` 与 jmcomic 插件 key `jm_server` 保持不变。\n'
26
+ ),
27
+ long_description_content_type="text/markdown",
28
+ url='https://github.com/hect0x7/jm-view-server',
29
+ author='hect0x7',
30
+ author_email='93357912+hect0x7@users.noreply.github.com',
31
+ packages=find_packages(),
32
+ python_requires=">=3.7",
33
+ # 关键: 安装旧包自动带上新包
34
+ install_requires=[
35
+ 'jm-view-server',
36
+ ],
37
+ keywords=['python', 'jmcomic', 'jm-view-server', '18comic', '禁漫天堂', 'NSFW', 'deprecated'],
38
+ classifiers=[
39
+ "Development Status :: 7 - Inactive",
40
+ ],
41
+ # 不注册 jms 命令: jms 始终由主包 jm-view-server 提供,
42
+ # 避免同时安装两个包时旧包覆盖主包、导致每次都弹弃用告警。
43
+ )
@@ -1,196 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: plugin_jm_server
3
- Version: 0.2.2
4
- Summary: plugin_jm_server, a plugin for jmcomic that can be used to view comics in a web browser.
5
- Home-page: https://github.com/hect0x7/plugin-jm-server
6
- Author: hect0x7
7
- Author-email: 93357912+hect0x7@users.noreply.github.com
8
- Keywords: python,jmcomic,18comic,禁漫天堂,NSFW
9
- Classifier: Development Status :: 4 - Beta
10
- Classifier: Intended Audience :: Developers
11
- Classifier: Programming Language :: Python :: 3.7
12
- Classifier: Programming Language :: Python :: 3.8
13
- Classifier: Programming Language :: Python :: 3.9
14
- Classifier: Programming Language :: Python :: 3.10
15
- Classifier: Programming Language :: Python :: 3.11
16
- Classifier: Programming Language :: Python :: 3.12
17
- Classifier: Operating System :: MacOS
18
- Classifier: Operating System :: POSIX :: Linux
19
- Classifier: Operating System :: Microsoft :: Windows
20
- Requires-Python: >=3.7
21
- Description-Content-Type: text/markdown
22
- Requires-Dist: jmcomic
23
- Requires-Dist: flask
24
- Requires-Dist: psutil
25
- Requires-Dist: cryptography
26
- Dynamic: author
27
- Dynamic: author-email
28
- Dynamic: classifier
29
- Dynamic: description
30
- Dynamic: description-content-type
31
- Dynamic: home-page
32
- Dynamic: keywords
33
- Dynamic: requires-dist
34
- Dynamic: requires-python
35
- Dynamic: summary
36
-
37
- # plugin-jm-server
38
-
39
- “离线版”禁漫天堂
40
-
41
- 该项目会在本地起一个`文件服务器`,支持用浏览器查看文件夹内的图片,界面模仿禁漫的章节观看页面,并适配手机端。
42
-
43
- 用浏览器的好处就是支持很多浏览器插件和脚本,例如:
44
-
45
- * 双页阅读插件:https://sleazyfork.org/zh-CN/scripts/374903-comicread
46
-
47
- # 效果图(文件浏览、整章看图)
48
-
49
- ## 1. 电脑浏览器访问
50
-
51
- ### 登录页
52
- ![](images/3.png)
53
-
54
- ### 文件夹列表页
55
- ![](images/4.png)
56
-
57
- ### 看本模式
58
- ![](images/5.png)
59
-
60
- ### 文件夹&看本 二合一模式
61
- ![](images/8.png)
62
-
63
- ## 2. 手机浏览器访问
64
-
65
- ### 登录页
66
- ![](images/1.jpeg)
67
-
68
- ### 文件夹列表页
69
- ![](images/2.png)
70
-
71
- ### 看本模式
72
- ![](images/7.jpeg)
73
-
74
- ### 局域网消息(方便手机和电脑互传消息)
75
- ![](images/9.png)
76
-
77
-
78
- # 使用方式
79
-
80
-
81
- ## 1. pip安装
82
-
83
- ```shell
84
- pip install plugin_jm_server
85
- ```
86
-
87
-
88
- ## 2. 运行代码
89
-
90
- * **HTTP版**
91
-
92
- ```python
93
- from plugin_jm_server import *
94
-
95
- # http
96
- server = JmServer(
97
- 'D:/',
98
- 'password',
99
- )
100
- server.run(
101
- host='0.0.0.0',
102
- port=80,
103
- )
104
- ```
105
-
106
- * **HTTPS版**
107
-
108
- ```python
109
- from plugin_jm_server import *
110
-
111
- # https
112
- server = JmServer(
113
- 'D:/',
114
- 'password',
115
- )
116
- server.run(
117
- host='0.0.0.0',
118
- port=443,
119
- ssl_context='adhoc',
120
- )
121
- ```
122
-
123
- * 作为jmcomic的插件
124
-
125
- ```yml
126
- # 配置文件
127
- plugins:
128
- after_init:
129
- # after_album:
130
- - plugin: jm_server
131
- kwargs:
132
- password: ''
133
-
134
- ```
135
-
136
- ```python
137
- # 代码
138
- from jmcomic import *
139
-
140
- op = create_option('op.yml')
141
- op.download_album(123)
142
- # 运行到这里,虽然主线程代码执行完毕,但程序不会退出,因为服务器线程还没有结束。
143
- # 控制台会输出提示信息如下(atexit时输出的):
144
- # “主线程执行完毕,但插件jm_server的服务器线程仍运行中,可按下ctrl+c结束程序”
145
- # 此时需要你主动按下ctrl+c终止程序。
146
-
147
- # python 3.12 特别注意:需要插入下面这行代码,服务器才能继续处理请求
148
- op.wait_all_plugins_finish()
149
- ```
150
-
151
-
152
- ## 前端页面与功能介绍
153
-
154
- 本项目提供了一套完整的 Web 前端界面,用于管理和浏览本地图片资源。主要包含以下三个核心页面及其功能:
155
-
156
- ### 1. 登录页
157
- 为了保护个人隐私,系统提供了简单的访问控制。
158
- * **密码验证**:启动时可配置密码,访问时需校验通过。
159
- * **设备自适应**:根据访问设备(手机/电脑)自动适配最佳的登录布局。
160
-
161
- ### 2. 文件夹浏览页(主页)
162
- 这是资源管理的核心入口,支持高效的文件查找与导航。目前最新版本采用了 SPA(单页应用)架构进行全面增强:
163
- * **智能路径导航**:
164
- * **路径补全**:输入路径时自动联想下级文件夹,支持键盘上下键选择及回车跳转。
165
- * **层级跳转**:输入框支持“..”快速返回上一级,并提供“确认”按钮进行精准跳转。
166
- * **可视化展示**:
167
- * **文件夹预览**:鼠标悬停在文件夹上时,会自动展示该文件夹内的首张图片作为封面预览。
168
- * **类型区分**:通过文件夹角标(图标)清晰区分普通文件夹与特殊资源文件夹。
169
- * **辅助功能**:
170
- * **书签管理**:支持将常看目录加入左侧书签栏,方便下次快速访问。
171
- * **本地交互**:支持通过网页菜单直接打开服务器端对应的本地文件夹窗口(Explorer)。
172
-
173
- ### 3. 图片阅读页(看本模式)
174
- 专为漫画阅读优化的沉浸式浏览页面。
175
- * **加载优化**:采用图片懒加载机制,流畅浏览含有数百张图片的大型章节,节省系统资源。
176
- * **多端适配**:
177
- * **PC端**:适合大屏浏览,支持浮动工具栏进行页面跳转、全屏切换等。
178
- * **移动端**:适配触摸操作,提供更好的手机阅读体验。
179
- * **阅读辅助**:
180
- * **浮动菜单**:提供“回到顶部”、“加载全部图片”及“在资源管理器打开”等便捷操作。
181
- * **键盘支持**:支持常用快捷键进行页面滚动和翻页。
182
-
183
- ### 4. 局域网消息中心 (v0.2.2+ New)
184
- 本项目最新版本引入了即时通讯与增强的局域网接入支持。
185
- * **实时互动**:支持服务器与内网设备之间互发即时消息,采用暗色毛玻璃视觉风格。
186
- * **全站通知**:后台实时轮询新消息,支持浏览器原生桌面通知及精美的网页侧边栏滑入提醒。
187
- * **接入优化**:自动识别服务器在局域网内的真实物理 IP,主页提供一键复制功能。
188
- * **非侵入式反馈**:全站移除 alert 阻塞弹窗,所有交互操作结果均通过通知条反馈。
189
-
190
- # 想法起源
191
-
192
- 想法起源:https://github.com/hect0x7/JMComic-Crawler-Python/issues/192
193
-
194
- 基于原项目:https://github.com/AiCorein/Flask-Files-Server
195
-
196
- 为了方便修改,将原项目中的文件复制到本项目中,然后进行修改
@@ -1,160 +0,0 @@
1
- # plugin-jm-server
2
-
3
- “离线版”禁漫天堂
4
-
5
- 该项目会在本地起一个`文件服务器`,支持用浏览器查看文件夹内的图片,界面模仿禁漫的章节观看页面,并适配手机端。
6
-
7
- 用浏览器的好处就是支持很多浏览器插件和脚本,例如:
8
-
9
- * 双页阅读插件:https://sleazyfork.org/zh-CN/scripts/374903-comicread
10
-
11
- # 效果图(文件浏览、整章看图)
12
-
13
- ## 1. 电脑浏览器访问
14
-
15
- ### 登录页
16
- ![](images/3.png)
17
-
18
- ### 文件夹列表页
19
- ![](images/4.png)
20
-
21
- ### 看本模式
22
- ![](images/5.png)
23
-
24
- ### 文件夹&看本 二合一模式
25
- ![](images/8.png)
26
-
27
- ## 2. 手机浏览器访问
28
-
29
- ### 登录页
30
- ![](images/1.jpeg)
31
-
32
- ### 文件夹列表页
33
- ![](images/2.png)
34
-
35
- ### 看本模式
36
- ![](images/7.jpeg)
37
-
38
- ### 局域网消息(方便手机和电脑互传消息)
39
- ![](images/9.png)
40
-
41
-
42
- # 使用方式
43
-
44
-
45
- ## 1. pip安装
46
-
47
- ```shell
48
- pip install plugin_jm_server
49
- ```
50
-
51
-
52
- ## 2. 运行代码
53
-
54
- * **HTTP版**
55
-
56
- ```python
57
- from plugin_jm_server import *
58
-
59
- # http
60
- server = JmServer(
61
- 'D:/',
62
- 'password',
63
- )
64
- server.run(
65
- host='0.0.0.0',
66
- port=80,
67
- )
68
- ```
69
-
70
- * **HTTPS版**
71
-
72
- ```python
73
- from plugin_jm_server import *
74
-
75
- # https
76
- server = JmServer(
77
- 'D:/',
78
- 'password',
79
- )
80
- server.run(
81
- host='0.0.0.0',
82
- port=443,
83
- ssl_context='adhoc',
84
- )
85
- ```
86
-
87
- * 作为jmcomic的插件
88
-
89
- ```yml
90
- # 配置文件
91
- plugins:
92
- after_init:
93
- # after_album:
94
- - plugin: jm_server
95
- kwargs:
96
- password: ''
97
-
98
- ```
99
-
100
- ```python
101
- # 代码
102
- from jmcomic import *
103
-
104
- op = create_option('op.yml')
105
- op.download_album(123)
106
- # 运行到这里,虽然主线程代码执行完毕,但程序不会退出,因为服务器线程还没有结束。
107
- # 控制台会输出提示信息如下(atexit时输出的):
108
- # “主线程执行完毕,但插件jm_server的服务器线程仍运行中,可按下ctrl+c结束程序”
109
- # 此时需要你主动按下ctrl+c终止程序。
110
-
111
- # python 3.12 特别注意:需要插入下面这行代码,服务器才能继续处理请求
112
- op.wait_all_plugins_finish()
113
- ```
114
-
115
-
116
- ## 前端页面与功能介绍
117
-
118
- 本项目提供了一套完整的 Web 前端界面,用于管理和浏览本地图片资源。主要包含以下三个核心页面及其功能:
119
-
120
- ### 1. 登录页
121
- 为了保护个人隐私,系统提供了简单的访问控制。
122
- * **密码验证**:启动时可配置密码,访问时需校验通过。
123
- * **设备自适应**:根据访问设备(手机/电脑)自动适配最佳的登录布局。
124
-
125
- ### 2. 文件夹浏览页(主页)
126
- 这是资源管理的核心入口,支持高效的文件查找与导航。目前最新版本采用了 SPA(单页应用)架构进行全面增强:
127
- * **智能路径导航**:
128
- * **路径补全**:输入路径时自动联想下级文件夹,支持键盘上下键选择及回车跳转。
129
- * **层级跳转**:输入框支持“..”快速返回上一级,并提供“确认”按钮进行精准跳转。
130
- * **可视化展示**:
131
- * **文件夹预览**:鼠标悬停在文件夹上时,会自动展示该文件夹内的首张图片作为封面预览。
132
- * **类型区分**:通过文件夹角标(图标)清晰区分普通文件夹与特殊资源文件夹。
133
- * **辅助功能**:
134
- * **书签管理**:支持将常看目录加入左侧书签栏,方便下次快速访问。
135
- * **本地交互**:支持通过网页菜单直接打开服务器端对应的本地文件夹窗口(Explorer)。
136
-
137
- ### 3. 图片阅读页(看本模式)
138
- 专为漫画阅读优化的沉浸式浏览页面。
139
- * **加载优化**:采用图片懒加载机制,流畅浏览含有数百张图片的大型章节,节省系统资源。
140
- * **多端适配**:
141
- * **PC端**:适合大屏浏览,支持浮动工具栏进行页面跳转、全屏切换等。
142
- * **移动端**:适配触摸操作,提供更好的手机阅读体验。
143
- * **阅读辅助**:
144
- * **浮动菜单**:提供“回到顶部”、“加载全部图片”及“在资源管理器打开”等便捷操作。
145
- * **键盘支持**:支持常用快捷键进行页面滚动和翻页。
146
-
147
- ### 4. 局域网消息中心 (v0.2.2+ New)
148
- 本项目最新版本引入了即时通讯与增强的局域网接入支持。
149
- * **实时互动**:支持服务器与内网设备之间互发即时消息,采用暗色毛玻璃视觉风格。
150
- * **全站通知**:后台实时轮询新消息,支持浏览器原生桌面通知及精美的网页侧边栏滑入提醒。
151
- * **接入优化**:自动识别服务器在局域网内的真实物理 IP,主页提供一键复制功能。
152
- * **非侵入式反馈**:全站移除 alert 阻塞弹窗,所有交互操作结果均通过通知条反馈。
153
-
154
- # 想法起源
155
-
156
- 想法起源:https://github.com/hect0x7/JMComic-Crawler-Python/issues/192
157
-
158
- 基于原项目:https://github.com/AiCorein/Flask-Files-Server
159
-
160
- 为了方便修改,将原项目中的文件复制到本项目中,然后进行修改
@@ -1,57 +0,0 @@
1
- from setuptools import setup, find_packages
2
-
3
- with open("README.md", encoding='utf-8') as f:
4
- long_description = f.read()
5
-
6
- version = None
7
- with open('./src/plugin_jm_server/__init__.py', encoding='utf-8') as f:
8
- for line in f:
9
- if '__version__' in line:
10
- version = line[line.index("'") + 1: line.rindex("'")]
11
- break
12
-
13
- if version is None:
14
- print('Set version first!')
15
- exit(1)
16
-
17
- setup(
18
- name='plugin_jm_server',
19
- version=version,
20
- description='plugin_jm_server, a plugin for jmcomic that can be used to view comics in a web browser.',
21
- long_description_content_type="text/markdown",
22
- long_description=long_description,
23
- url='https://github.com/hect0x7/plugin-jm-server',
24
- author='hect0x7',
25
- author_email='93357912+hect0x7@users.noreply.github.com',
26
- packages=find_packages("src"),
27
- package_dir={"": "src"},
28
- python_requires=">=3.7",
29
- install_requires=[
30
- 'jmcomic',
31
- 'flask',
32
- 'psutil',
33
- 'cryptography',
34
- ],
35
- keywords=['python', 'jmcomic', '18comic', '禁漫天堂', 'NSFW'],
36
- classifiers=[
37
- "Development Status :: 4 - Beta",
38
- "Intended Audience :: Developers",
39
- "Programming Language :: Python :: 3.7",
40
- "Programming Language :: Python :: 3.8",
41
- "Programming Language :: Python :: 3.9",
42
- "Programming Language :: Python :: 3.10",
43
- "Programming Language :: Python :: 3.11",
44
- "Programming Language :: Python :: 3.12",
45
- "Operating System :: MacOS",
46
- "Operating System :: POSIX :: Linux",
47
- "Operating System :: Microsoft :: Windows",
48
- ],
49
- entry_points={
50
- },
51
- package_data={
52
- "plugin_jm_server": [
53
- "static/**",
54
- "templates/**",
55
- ],
56
- }
57
- )
@@ -1,3 +0,0 @@
1
- __version__ = '0.2.2'
2
-
3
- from .app import *