@zhangfengshun/dsh-remote-ssh 1.3.0 → 1.3.1

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/CHANGELOG.md CHANGED
@@ -2,6 +2,10 @@
2
2
 
3
3
  本文件的版本号与 `package.json` 的 `version` 保持一致。每个版本对应一个 Cordis Package 快照(`pkg-N`)。
4
4
 
5
+ ## [1.3.1] — 修复远程文件树滚动
6
+ ### 修复
7
+ - 「远程文件」页签改为 flex 布局:文件树在文件很多时占据剩余高度并内部滚动(`flex:1; overflow-y:auto`),不再因父容器 `overflow:hidden` 而无法往下拉。
8
+
5
9
  ## [1.3.0] — 外观跟随主题
6
10
  ### 新增
7
11
  - 远程连接相关界面(设置小节、远程文件 / 终端页签、添加工作区弹窗)的颜色全部改用 DSH 主题 token(`--dsw-alias-*`),自动跟随 DSH 明暗主题(`body[data-ds-dark-theme]`)切换,不再硬编码深色配色。
package/lib/client.js CHANGED
@@ -341,36 +341,38 @@ window.__ModuleLoader__.load({
341
341
  });
342
342
  }
343
343
 
344
- return h("div", null,
345
- h("div", { className: "rssh-row" },
346
- h("span", { className: "rssh-label" }, t("files.workspace")),
347
- h("select", { className: "rssh-select", value: wsId || "", onChange: function (e) { setWsId(e.target.value); setProfileId(""); } },
348
- h("option", { value: "" }, t("files.selectWorkspace")),
349
- workspaces.map(function (w) { return h("option", { key: w.id, value: w.id }, w.title); })
350
- )
351
- ),
352
- h("div", { className: "rssh-row" },
353
- h("span", { className: "rssh-label" }, t("files.orProfile")),
354
- h("select", { className: "rssh-select", value: profileId, onChange: function (e) { setProfileId(e.target.value); setWsId(""); } },
355
- h("option", { value: "" }, t("common.selectProfile")),
356
- profiles.map(function (p) { return h("option", { key: p.id, value: p.id }, p.name); })
357
- )
358
- ),
359
- wsId ? h("div", { className: "rssh-row" },
360
- h("span", { className: "rssh-label" }, t("files.defaultDir")),
344
+ return h("div", { style: { display: "flex", flexDirection: "column", flex: 1, minHeight: 0, overflow: "hidden" } },
345
+ h("div", { style: { flex: "none" } },
346
+ h("div", { className: "rssh-row" },
347
+ h("span", { className: "rssh-label" }, t("files.workspace")),
348
+ h("select", { className: "rssh-select", value: wsId || "", onChange: function (e) { setWsId(e.target.value); setProfileId(""); } },
349
+ h("option", { value: "" }, t("files.selectWorkspace")),
350
+ workspaces.map(function (w) { return h("option", { key: w.id, value: w.id }, w.title); })
351
+ )
352
+ ),
353
+ h("div", { className: "rssh-row" },
354
+ h("span", { className: "rssh-label" }, t("files.orProfile")),
355
+ h("select", { className: "rssh-select", value: profileId, onChange: function (e) { setProfileId(e.target.value); setWsId(""); } },
356
+ h("option", { value: "" }, t("common.selectProfile")),
357
+ profiles.map(function (p) { return h("option", { key: p.id, value: p.id }, p.name); })
358
+ )
359
+ ),
360
+ wsId ? h("div", { className: "rssh-row" },
361
+ h("span", { className: "rssh-label" }, t("files.defaultDir")),
362
+ h("div", { className: "rssh-pathbar" },
363
+ h("input", { className: "rssh-input", value: defaultDir, onChange: function (e) { setDefaultDir(e.target.value); }, placeholder: "/home/user/project" }),
364
+ h("button", { className: "rssh-btn", onClick: saveDefaultDir }, t("common.save"))
365
+ )
366
+ ) : null,
361
367
  h("div", { className: "rssh-pathbar" },
362
- h("input", { className: "rssh-input", value: defaultDir, onChange: function (e) { setDefaultDir(e.target.value); }, placeholder: "/home/user/project" }),
363
- h("button", { className: "rssh-btn", onClick: saveDefaultDir }, t("common.save"))
364
- )
365
- ) : null,
366
- h("div", { className: "rssh-pathbar" },
367
- h("input", { className: "rssh-input", value: path, onChange: function (e) { setPath(e.target.value); }, placeholder: "/home/user" }),
368
- h("button", { className: "rssh-btn", onClick: function () { load(profileId, path); } }, t("common.open")),
369
- h("button", { className: "rssh-btn", onClick: goUp }, t("common.up"))
368
+ h("input", { className: "rssh-input", value: path, onChange: function (e) { setPath(e.target.value); }, placeholder: "/home/user" }),
369
+ h("button", { className: "rssh-btn", onClick: function () { load(profileId, path); } }, t("common.open")),
370
+ h("button", { className: "rssh-btn", onClick: goUp }, t("common.up"))
371
+ ),
372
+ loading ? h("div", { className: "rssh-muted" }, t("common.loading")) : null,
373
+ err ? h("div", { className: "rssh-err", style: { whiteSpace: "pre-wrap" } }, err) : null
370
374
  ),
371
- loading ? h("div", { className: "rssh-muted" }, t("common.loading")) : null,
372
- err ? h("div", { className: "rssh-err", style: { whiteSpace: "pre-wrap" } }, err) : null,
373
- h("div", { style: { marginTop: 6 } },
375
+ h("div", { style: { flex: 1, minHeight: 0, overflowY: "auto", marginTop: 6 } },
374
376
  entries.map(function (e) {
375
377
  return h("div", { key: e.name, className: "rssh-tree-item", onClick: function () { openEntry(e); } },
376
378
  h("span", { className: e.type === "directory" ? "rssh-tree-dir" : "rssh-tree-file" }, e.type === "directory" ? "📁 " + e.name : "📄 " + e.name),
@@ -378,7 +380,7 @@ window.__ModuleLoader__.load({
378
380
  );
379
381
  })
380
382
  ),
381
- openFile ? h("div", null,
383
+ openFile ? h("div", { style: { flex: "none" } },
382
384
  h("div", { className: "rssh-pathbar", style: { marginTop: 8 } },
383
385
  h("span", { className: "rssh-title", style: { flex: 1, wordBreak: "break-all" } }, openFile.path),
384
386
  h("button", { className: "rssh-btn", onClick: saveFile }, t("common.save")),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zhangfengshun/dsh-remote-ssh",
3
- "version": "1.3.0",
3
+ "version": "1.3.1",
4
4
  "description": "DSH web plugin: VSCode Remote-SSH-like remote development (SSH to supercomputers/servers, remote workspace, file explorer, integrated terminal), integrated with dsh-better-sidebar and DSH settings.",
5
5
  "keywords": [
6
6
  "dsh",