dsh-remote-plugin 0.4.5 → 0.4.9
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.
- package/README.md +6 -3
- package/apk/dsh-remote.apk +0 -0
- package/gateway.cjs +618 -0
- package/package.json +2 -2
- package/public/app.js +548 -18
- package/public/index.html +25 -2
- package/public/styles.css +71 -0
- package/public/update.json +3 -3
- package/public/version.json +1 -1
package/public/index.html
CHANGED
|
@@ -36,6 +36,23 @@
|
|
|
36
36
|
<div id="home-empty" class="empty hidden">暂无会话</div>
|
|
37
37
|
</section>
|
|
38
38
|
|
|
39
|
+
<!-- 文件传输 -->
|
|
40
|
+
<section id="view-files" class="view hidden">
|
|
41
|
+
<div class="fs-head">
|
|
42
|
+
<button id="fs-up" class="icon-btn" title="返回上级" aria-label="返回上级">‹</button>
|
|
43
|
+
<div id="fs-path" class="fs-path">加载中…</div>
|
|
44
|
+
<button id="fs-upload-btn" class="mini-btn">上传</button>
|
|
45
|
+
<button id="fs-refresh" class="icon-btn" title="刷新" aria-label="刷新">⟳</button>
|
|
46
|
+
</div>
|
|
47
|
+
<div id="fs-progress" class="fs-progress hidden">
|
|
48
|
+
<div class="fs-progress-track"><div id="fs-progress-bar" class="fs-progress-bar"></div></div>
|
|
49
|
+
<div id="fs-progress-text" class="fs-progress-text muted">0%</div>
|
|
50
|
+
</div>
|
|
51
|
+
<div id="fs-pull" class="fs-pull">松开刷新</div>
|
|
52
|
+
<div id="fs-list" class="fs-list"></div>
|
|
53
|
+
<input type="file" id="fs-file-input" class="hidden">
|
|
54
|
+
</section>
|
|
55
|
+
|
|
39
56
|
<!-- 会话详情 -->
|
|
40
57
|
<section id="view-session" class="view hidden">
|
|
41
58
|
<div class="session-head">
|
|
@@ -81,8 +98,13 @@
|
|
|
81
98
|
<section id="view-settings" class="view hidden">
|
|
82
99
|
<div class="settings-group">
|
|
83
100
|
<div class="setting-row">
|
|
84
|
-
<div><div class="setting-name"
|
|
85
|
-
<button id="btn-
|
|
101
|
+
<div><div class="setting-name">服务器地址(可多个)</div><div class="setting-desc" id="server-desc">默认 = 当前页面地址</div></div>
|
|
102
|
+
<button id="btn-server-speed" class="mini-btn">测速</button>
|
|
103
|
+
</div>
|
|
104
|
+
<div id="server-list" class="server-list"></div>
|
|
105
|
+
<div class="server-add">
|
|
106
|
+
<input id="server-input" type="url" placeholder="http://IP:8787">
|
|
107
|
+
<button id="btn-server-add" class="mini-btn">添加</button>
|
|
86
108
|
</div>
|
|
87
109
|
<div class="setting-row">
|
|
88
110
|
<div><div class="setting-name">通知</div><div class="setting-desc">收到审批/提问时推送</div></div>
|
|
@@ -118,6 +140,7 @@
|
|
|
118
140
|
|
|
119
141
|
<nav class="bottom-nav">
|
|
120
142
|
<button data-view="view-home" class="nav-btn active"><span class="nav-ico">▤</span><span>会话</span></button>
|
|
143
|
+
<button data-view="view-files" class="nav-btn"><span class="nav-ico">⇅</span><span>文件</span></button>
|
|
121
144
|
<button data-view="view-activity" class="nav-btn"><span class="nav-ico">◷</span><span>待办<b id="nav-pending" class="nav-badge hidden"></b></span></button>
|
|
122
145
|
<button data-view="view-settings" class="nav-btn"><span class="nav-ico">⚙</span><span>设置</span></button>
|
|
123
146
|
</nav>
|
package/public/styles.css
CHANGED
|
@@ -307,6 +307,47 @@ body.in-session .main { padding-bottom: 84px; }
|
|
|
307
307
|
.job-card .job-name { font-weight: 600; font-size: 14px; }
|
|
308
308
|
.job-state { font-size: 12px; color: var(--muted); margin-top: 3px; }
|
|
309
309
|
|
|
310
|
+
/* ---------- 文件传输 ---------- */
|
|
311
|
+
.fs-head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
|
|
312
|
+
.fs-path {
|
|
313
|
+
flex: 1; min-width: 0; font-size: 12.5px; color: var(--muted);
|
|
314
|
+
background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
|
|
315
|
+
padding: 8px 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
|
|
316
|
+
}
|
|
317
|
+
.fs-progress {
|
|
318
|
+
display: flex; align-items: center; gap: 10px;
|
|
319
|
+
background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
|
|
320
|
+
padding: 9px 11px; margin-bottom: 10px;
|
|
321
|
+
}
|
|
322
|
+
.fs-progress-track {
|
|
323
|
+
flex: 1; height: 7px; border-radius: 999px; background: var(--panel-2); overflow: hidden;
|
|
324
|
+
}
|
|
325
|
+
.fs-progress-bar {
|
|
326
|
+
height: 100%; width: 0%; border-radius: 999px;
|
|
327
|
+
background: linear-gradient(90deg, var(--blue), var(--cyan));
|
|
328
|
+
transition: width .15s ease;
|
|
329
|
+
}
|
|
330
|
+
.fs-progress-text { flex-shrink: 0; min-width: 112px; text-align: right; }
|
|
331
|
+
.fs-pull {
|
|
332
|
+
height: 0; overflow: hidden; text-align: center; font-size: 12px; color: var(--cyan);
|
|
333
|
+
transition: height .12s ease; line-height: 26px;
|
|
334
|
+
}
|
|
335
|
+
.fs-list { display: flex; flex-direction: column; gap: 8px; }
|
|
336
|
+
.fs-row {
|
|
337
|
+
display: flex; align-items: center; gap: 11px;
|
|
338
|
+
background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
|
|
339
|
+
padding: 11px 13px; min-width: 0;
|
|
340
|
+
}
|
|
341
|
+
.fs-row:active { background: var(--panel-2); }
|
|
342
|
+
.fs-ico { flex-shrink: 0; font-size: 22px; }
|
|
343
|
+
.fs-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; }
|
|
344
|
+
.fs-name {
|
|
345
|
+
font-size: 14.5px; font-weight: 600; white-space: nowrap;
|
|
346
|
+
overflow: hidden; text-overflow: ellipsis;
|
|
347
|
+
}
|
|
348
|
+
.fs-sub { font-size: 12px; color: var(--muted); margin-top: 1px; }
|
|
349
|
+
.fs-arrow { flex-shrink: 0; color: var(--muted); font-size: 18px; }
|
|
350
|
+
|
|
310
351
|
/* ---------- 设置 ---------- */
|
|
311
352
|
.settings-group {
|
|
312
353
|
background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
|
|
@@ -321,6 +362,36 @@ body.in-session .main { padding-bottom: 84px; }
|
|
|
321
362
|
.setting-desc { font-size: 12px; color: var(--muted); margin-top: 2px; word-break: break-all; }
|
|
322
363
|
.about { text-align: center; color: var(--muted); font-size: 12px; margin-top: 16px; line-height: 1.8; }
|
|
323
364
|
|
|
365
|
+
/* 多服务器列表 */
|
|
366
|
+
.server-list { padding: 0 14px 10px; display: flex; flex-direction: column; gap: 6px; }
|
|
367
|
+
.server-empty { font-size: 12px; color: var(--muted); }
|
|
368
|
+
.server-row {
|
|
369
|
+
display: flex; align-items: center; gap: 8px;
|
|
370
|
+
background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px;
|
|
371
|
+
padding: 8px 10px;
|
|
372
|
+
}
|
|
373
|
+
.server-row.active { border-color: rgba(125, 207, 255, .55); background: rgba(125, 207, 255, .06); }
|
|
374
|
+
.server-url { flex: 1; min-width: 0; font-size: 12.5px; word-break: break-all; }
|
|
375
|
+
.server-badge {
|
|
376
|
+
flex-shrink: 0; font-size: 11px; padding: 1px 7px; border-radius: 999px;
|
|
377
|
+
background: rgba(91, 140, 255, .12); color: var(--blue);
|
|
378
|
+
border: 1px solid rgba(91, 140, 255, .3); white-space: nowrap;
|
|
379
|
+
}
|
|
380
|
+
.server-badge.good { background: rgba(125, 207, 255, .1); color: var(--cyan); border-color: rgba(125, 207, 255, .35); }
|
|
381
|
+
.server-badge.bad { background: rgba(255, 158, 100, .1); color: var(--orange); border-color: rgba(255, 158, 100, .35); }
|
|
382
|
+
.server-del {
|
|
383
|
+
flex-shrink: 0; width: 24px; height: 24px; border-radius: 7px;
|
|
384
|
+
background: var(--panel); border: 1px solid var(--line); color: var(--muted); font-size: 12px;
|
|
385
|
+
}
|
|
386
|
+
.server-del:active { color: var(--danger); }
|
|
387
|
+
.server-add { display: flex; gap: 8px; padding: 0 14px 13px; }
|
|
388
|
+
.server-add input {
|
|
389
|
+
flex: 1; min-width: 0; background: var(--bg-2); color: var(--text);
|
|
390
|
+
border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px;
|
|
391
|
+
font: inherit; font-size: 13px; outline: none;
|
|
392
|
+
}
|
|
393
|
+
.server-add input:focus { border-color: rgba(91, 140, 255, .6); }
|
|
394
|
+
|
|
324
395
|
/* 开关 */
|
|
325
396
|
.switch { position: relative; display: inline-block; width: 46px; height: 27px; flex-shrink: 0; }
|
|
326
397
|
.switch input { opacity: 0; width: 0; height: 0; }
|
package/public/update.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.4.
|
|
2
|
+
"version": "0.4.9",
|
|
3
3
|
"apkUrl": "dsh-remote.apk",
|
|
4
|
-
"releasedAt": "2026-08-
|
|
5
|
-
"notes": "
|
|
4
|
+
"releasedAt": "2026-08-16T03:05:53.903Z",
|
|
5
|
+
"notes": "上传支持分块断点续传(断网重选同一文件接着传); APK 固定签名, 各版本可原地覆盖升级; 发版全自动: tag 后 CI 构建 Release 资产 + npm + 独立仓库"
|
|
6
6
|
}
|
package/public/version.json
CHANGED