dsh-remote-window 0.1.0-alpha.3 → 0.1.0-alpha.5

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/lib/client.js CHANGED
@@ -50,7 +50,6 @@ window.__ModuleLoader__.load({
50
50
  "list.workspaces.empty": "还没有远程工作区。",
51
51
  "list.kind.ssh": "SSH",
52
52
  "list.endpoint": "{username}@{host}:{port}",
53
- "list.endpoint.wsl": "WSL · {distro}",
54
53
  "list.status.unknown": "未连接",
55
54
  "list.status.ready": "已连接",
56
55
  "list.status.failed": "连接失败",
@@ -117,7 +116,9 @@ window.__ModuleLoader__.load({
117
116
  "remote.connect.auth.agent": "SSH Agent",
118
117
  "remote.connect.secret": "密码",
119
118
  "remote.connect.privateKeyPath": "私钥路径",
120
- "remote.connect.privateKeyHint": "本机路径,凭据只留在本机。",
119
+ "remote.connect.privateKeyHint": "从 `~/.ssh` 下发现的私钥里选择,或手动填写本机路径;凭据只留在本机。",
120
+ "remote.connect.privateKeyFound": "已发现 {count} 个私钥",
121
+ "remote.connect.privateKeyNone": "`~/.ssh` 下没有发现可用私钥,请手动填写路径。",
121
122
  "remote.connect.passphrase": "私钥口令(可选)",
122
123
  "remote.connect.passphraseHint": "有口令时填写,只留在本机。",
123
124
  "remote.connect.dshHome": "server DSH_HOME(可选)",
@@ -144,20 +145,10 @@ window.__ModuleLoader__.load({
144
145
  "remote.connect.runtime.hint": "选择 server 端使用哪种 DSH 运行时。",
145
146
  "remote.connect.runtime.auto": "自动(优先复用全局 DSH)",
146
147
  "connect.local.title": "模型来源",
147
- "connect.local.hint": "默认使用本机模型:agent 仍在 server 运行,模型请求经 SSH 反向隧道转发到本机。本机 DSH 的所有 provider/模型会自动加载,可在此勾选要暴露的模型。",
148
148
  "connect.local.source.local": "本地模型",
149
149
  "connect.local.source.server": "server 模型",
150
150
  "connect.local.serverHint": "使用 server profile 自己的模型配置;需要 server 已配置可用的 API key。",
151
- "connect.local.auto.hint": "自动发现本机 DSH 的全部 provider 与模型;只有勾选的模型会经 SSH 反向隧道暴露给 server 侧,无需 endpoint 或 API key。",
152
- "connect.local.auto.refresh": "刷新",
153
- "connect.local.auto.refreshing": "正在读取本机模型…",
154
- "connect.local.auto.summary": "{providers} 个 provider · 已选 {selected}/{models} 个模型",
155
- "connect.local.auto.providerCount": "已选 {selected}/{total}",
156
- "connect.local.auto.selectAll": "全选",
157
- "connect.local.auto.clear": "清空",
158
- "connect.local.auto.providers": "本机 provider",
159
- "connect.local.auto.empty": "当前 DSH 没有可用的模型 provider;请先在 client 端 DSH 里配置一个模型 provider。",
160
- "connect.local.autoFailed": "保存本机模型设置失败。",
151
+ "connect.local.auto.forwardAll": "使用本机的模型。",
161
152
  "connect.local.discoverFailed": "读取本机模型失败:{message}",
162
153
  "connect.local.failed": "本地模型请求失败:{message}",
163
154
  "connect.progress.elapsed": "已用 {seconds}s",
@@ -417,23 +408,6 @@ window.__ModuleLoader__.load({
417
408
  "method.selected": "已选择",
418
409
  "method.ssh.aria": "使用 SSH 连接",
419
410
  "method.wsl.aria": "进入本机的 WSL 发行版",
420
- "config.wslDistro": "发行版",
421
- "config.wslDistro.hint": "检测到的 WSL 发行版,运行在菜单里切换",
422
- "config.wslDistro.placeholder": "发行版名称,例如 Ubuntu-22.04",
423
- "config.wslDistro.pick": "选择发行版",
424
- "config.wslDistro.required": "请选择一个 WSL 发行版",
425
- "config.wslUser": "用户名(可选)",
426
- "config.wslUser.hint": "留空则使用该发行版的默认用户",
427
- "config.wslUser.placeholder": "默认用户",
428
- "config.wsl.note": "WSL 目标运行在本机,不需要主机密钥或密码;执行世界与工具调用都发生在该发行版内。",
429
- "wsl.detecting": "正在检测发行版…",
430
- "wsl.detected": "已检测到 {count} 个发行版",
431
- "wsl.empty": "未检测到发行版,可直接输入名称",
432
- "wsl.unavailable": "无法检测:{reason}",
433
- "wsl.default": "默认",
434
- "wsl.state.running": "运行中",
435
- "wsl.state.stopped": "已停止",
436
- "wsl.state.installing": "安装中",
437
411
  "config.title": "填写配置",
438
412
  "config.description": "别名必填,连接成功后会被保存。",
439
413
  "config.alias": "别名",
@@ -717,7 +691,6 @@ window.__ModuleLoader__.load({
717
691
  "list.workspaces.empty": "No remote workspaces yet.",
718
692
  "list.kind.ssh": "SSH",
719
693
  "list.endpoint": "{username}@{host}:{port}",
720
- "list.endpoint.wsl": "WSL · {distro}",
721
694
  "list.status.unknown": "Not connected",
722
695
  "list.status.ready": "Connected",
723
696
  "list.status.failed": "Failed",
@@ -784,7 +757,9 @@ window.__ModuleLoader__.load({
784
757
  "remote.connect.auth.agent": "SSH agent",
785
758
  "remote.connect.secret": "Password",
786
759
  "remote.connect.privateKeyPath": "Private key path",
787
- "remote.connect.privateKeyHint": "A local path; credentials never leave this machine.",
760
+ "remote.connect.privateKeyHint": "Pick a key discovered under `~/.ssh`, or type a local path; credentials never leave this machine.",
761
+ "remote.connect.privateKeyFound": "{count} private keys found",
762
+ "remote.connect.privateKeyNone": "No usable private key under `~/.ssh`; type a path.",
788
763
  "remote.connect.passphrase": "Key passphrase (optional)",
789
764
  "remote.connect.passphraseHint": "Only when the key has one; kept on this machine.",
790
765
  "remote.connect.dshHome": "Server DSH_HOME (optional)",
@@ -811,20 +786,10 @@ window.__ModuleLoader__.load({
811
786
  "remote.connect.runtime.hint": "Choose which DSH runtime the server uses.",
812
787
  "remote.connect.runtime.auto": "Automatic (prefer global DSH)",
813
788
  "connect.local.title": "Model source",
814
- "connect.local.hint": "Local model is the default: the agent still runs on the server, while model requests are forwarded to this machine through an SSH reverse tunnel. Every provider/model of this DSH is discovered automatically; check the ones to expose.",
815
789
  "connect.local.source.local": "Local model",
816
790
  "connect.local.source.server": "Server model",
817
791
  "connect.local.serverHint": "Use the server profile’s own model configuration; the server must already have a working API key.",
818
- "connect.local.auto.hint": "Discover every provider and model of the current DSH automatically. Only the checked models are exposed to the server through the SSH reverse tunnel; no endpoint or API key needed.",
819
- "connect.local.auto.refresh": "Refresh",
820
- "connect.local.auto.refreshing": "Reading local models…",
821
- "connect.local.auto.summary": "{providers} provider(s) · {selected}/{models} model(s) selected",
822
- "connect.local.auto.providerCount": "{selected}/{total} selected",
823
- "connect.local.auto.selectAll": "Select all",
824
- "connect.local.auto.clear": "Clear",
825
- "connect.local.auto.providers": "Local providers",
826
- "connect.local.auto.empty": "The current DSH exposes no usable model provider yet. Configure a model provider in the client DSH first.",
827
- "connect.local.autoFailed": "Saving the local-model settings failed.",
792
+ "connect.local.auto.forwardAll": "This machine's models are used.",
828
793
  "connect.local.discoverFailed": "Reading local models failed: {message}",
829
794
  "connect.local.failed": "Local model request failed: {message}",
830
795
  "connect.progress.elapsed": "Elapsed {seconds}s",
@@ -1084,23 +1049,6 @@ window.__ModuleLoader__.load({
1084
1049
  "method.selected": "Selected",
1085
1050
  "method.ssh.aria": "Connect over SSH",
1086
1051
  "method.wsl.aria": "Enter a local WSL distribution",
1087
- "config.wslDistro": "Distribution",
1088
- "config.wslDistro.hint": "Detected WSL distributions; pick one in the menu",
1089
- "config.wslDistro.placeholder": "Distribution name, e.g. Ubuntu-22.04",
1090
- "config.wslDistro.pick": "Pick a distribution",
1091
- "config.wslDistro.required": "A WSL distribution is required",
1092
- "config.wslUser": "User (optional)",
1093
- "config.wslUser.hint": "Leave empty to use the distribution's default user",
1094
- "config.wslUser.placeholder": "Default user",
1095
- "config.wsl.note": "A WSL target runs on this machine, so there is no host key or password; the execution world and every tool call happen inside that distribution.",
1096
- "wsl.detecting": "Detecting distributions…",
1097
- "wsl.detected": "{count} distribution(s) detected",
1098
- "wsl.empty": "No distribution detected — type a name instead",
1099
- "wsl.unavailable": "Detection failed: {reason}",
1100
- "wsl.default": "default",
1101
- "wsl.state.running": "running",
1102
- "wsl.state.stopped": "stopped",
1103
- "wsl.state.installing": "installing",
1104
1052
  "config.title": "Configuration",
1105
1053
  "config.description": "The alias is required and is saved after a successful connection.",
1106
1054
  "config.alias": "Alias",
@@ -2070,19 +2018,19 @@ window.__ModuleLoader__.load({
2070
2018
  state() {
2071
2019
  return call("state", {});
2072
2020
  },
2073
- /**
2074
- * Installed WSL distributions (`wsl.exe -l -v`).
2075
- *
2076
- * Windows hosts only; elsewhere the route answers 400 and the caller never
2077
- * asks, because the WSL method is not offered there at all.
2078
- */
2079
- wslDistros() {
2080
- return call("wsl-distros", {});
2081
- },
2082
2021
  /** Aliases parsed from the local `~/.ssh/config`, plus parser warnings. */
2083
2022
  sshAliases() {
2084
2023
  return call("ssh-aliases", {});
2085
2024
  },
2025
+ /**
2026
+ * Private keys discoverable under `~/.ssh` on this host.
2027
+ *
2028
+ * Only paths cross the wire; the dialog offers them as datalist options and
2029
+ * still lets the user type a path that is not listed.
2030
+ */
2031
+ sshKeys() {
2032
+ return call("ssh-keys", {});
2033
+ },
2086
2034
  /** Resolved connection fields for one alias (host/port/user/identity). */
2087
2035
  aliasPrefill(alias) {
2088
2036
  return call("alias-prefill", { alias });
@@ -2786,29 +2734,6 @@ window.__ModuleLoader__.load({
2786
2734
  connectV1(request) {
2787
2735
  return call("v1/connect", request);
2788
2736
  },
2789
- /** Read the saved local-model settings (never the API key; only `hasApiKey`). */
2790
- localLlmRead(targetId) {
2791
- return call("local-llm/read", targetId === void 0 ? {} : { targetId });
2792
- },
2793
- /** Save the local-model mode and (auto) selected models; optionally an API key. */
2794
- localLlmSave(request) {
2795
- return call("local-llm/save", request);
2796
- },
2797
- /**
2798
- * Discover the model providers the client DSH exposes (`local-llm/discover`).
2799
- * The host answers `local-llm-providers-unavailable` when none is usable.
2800
- */
2801
- localLlmDiscover() {
2802
- return call("local-llm/discover", {});
2803
- },
2804
- /** Probe the local OpenAI-compatible endpoint and return its model ids. */
2805
- localLlmProbe(request) {
2806
- return call("local-llm/probe", request);
2807
- },
2808
- /** Remove the stored local-model API key. */
2809
- localLlmClearKey() {
2810
- return call("local-llm/clear-key", {});
2811
- },
2812
2737
  /** Read the progress buffer for one connect attempt. */
2813
2738
  connectProgress(attemptId) {
2814
2739
  return call("v1/connect/progress", { attemptId });
@@ -5796,6 +5721,7 @@ button.dsh-rwv-conv-crumb:hover {
5796
5721
  loading: false,
5797
5722
  clientId: value.clientId,
5798
5723
  pluginVersion: value.pluginVersion,
5724
+ platform: value.platform,
5799
5725
  order,
5800
5726
  connections: mappedConnections
5801
5727
  });
@@ -6677,204 +6603,9 @@ button.dsh-rwv-conv-crumb:hover {
6677
6603
  privateKeyPath: "",
6678
6604
  dshHome: "",
6679
6605
  runtimePolicy: "auto",
6680
- modelSource: "local",
6681
- localProviders: [],
6682
- localProvidersLoading: false,
6683
- localProvidersLoaded: false,
6684
- localSelection: {},
6685
- localSettingsLoading: false
6686
- } });
6687
- hydrateLocalLlmSettings();
6688
- }
6689
- /** Fold a `local-llm/read` selection list into the dialog's per-provider map. */
6690
- function selectionRecord(selection) {
6691
- const record = {};
6692
- for (const entry of selection) record[entry.providerId] = [...entry.models];
6693
- return record;
6694
- }
6695
- /**
6696
- * Fold a fresh catalog into the current selection.
6697
- *
6698
- * - a provider the user has never seen is fully selected;
6699
- * - a provider whose saved selection exists keeps exactly those models
6700
- * (first discovery after hydration — the saved selection is authoritative);
6701
- * - on a later discovery, models that appeared since the previous catalog are
6702
- * selected by default unless the user had explicitly deselected them, while
6703
- * previously deselected models stay deselected.
6704
- */
6705
- function mergeLocalSelection(providers, previousSelection, previousProviders) {
6706
- const previousCatalog = new Map(previousProviders.map((provider) => [provider.id, new Set(provider.models.map((model) => model.id))]));
6707
- const selection = {};
6708
- for (const provider of providers) {
6709
- const chosen = previousSelection[provider.id];
6710
- if (chosen === void 0) {
6711
- selection[provider.id] = provider.models.map((model) => model.id);
6712
- continue;
6713
- }
6714
- const selected = new Set(chosen);
6715
- const known = previousCatalog.get(provider.id);
6716
- selection[provider.id] = provider.models.map((model) => model.id).filter((id) => selected.has(id) || known !== void 0 && !known.has(id));
6717
- }
6718
- return selection;
6719
- }
6720
- /** The save payload's selection: catalog order, only models still offered. */
6721
- function localSelectionPayload(dialog) {
6722
- if (dialog.localProviders.length > 0) return dialog.localProviders.map((provider) => {
6723
- const selected = new Set(dialog.localSelection[provider.id] ?? []);
6724
- return {
6725
- providerId: provider.id,
6726
- models: provider.models.map((model) => model.id).filter((id) => selected.has(id))
6727
- };
6728
- });
6729
- const entries = Object.entries(dialog.localSelection);
6730
- if (entries.length === 0) return void 0;
6731
- return entries.map(([providerId, models]) => ({
6732
- providerId,
6733
- models: [...models]
6734
- }));
6735
- }
6736
- /**
6737
- * Patch local-model fields without clearing a connect error.
6738
- *
6739
- * Hydration/discovery run in the background while a submit may be failing; the
6740
- * user-visible `error` belongs to the submit and must survive those patches.
6741
- */
6742
- function patchLocalDialog(patch) {
6743
- const current = state.connectDialog;
6744
- if (current === void 0) return;
6745
- commit({ connectDialog: {
6746
- ...current,
6747
- ...patch
6748
- } });
6749
- }
6750
- /**
6751
- * Read the saved local-model settings into the open connect dialog.
6752
- *
6753
- * The local source is always "auto" now: the discovery catalog is the only
6754
- * model list, and a saved `selection` decides which discovered models start
6755
- * checked. `undefined` selection means "everything selected", which the first
6756
- * discovery then materializes. An older host may not serve `local-llm/read`;
6757
- * the dialog then starts with an all-selected catalog and the host resolves
6758
- * the source at connect time (no fallback to server models).
6759
- */
6760
- async function hydrateLocalLlmSettings() {
6761
- if (state.connectDialog === void 0) return;
6762
- patchLocalDialog({ localSettingsLoading: true });
6763
- try {
6764
- const read = await remoteApi.localLlmRead();
6765
- if (state.connectDialog === void 0) return;
6766
- patchLocalDialog({
6767
- localSettingsLoading: false,
6768
- ...read.selection === void 0 ? {} : { localSelection: selectionRecord(read.selection) }
6769
- });
6770
- } catch {
6771
- if (state.connectDialog === void 0) return;
6772
- patchLocalDialog({ localSettingsLoading: false });
6773
- }
6774
- discoverLocalProviders();
6775
- }
6776
- /**
6777
- * Discover the model providers the client DSH exposes (`local-llm/discover`).
6778
- *
6779
- * The grouped checklist is driven by this catalog; an empty result is a
6780
- * successful discovery, not an error — the UI then tells the user to configure
6781
- * a provider in this DSH installation. A re-discovery keeps the user's
6782
- * deselections and selects newly appeared providers/models by default.
6783
- */
6784
- async function discoverLocalProviders() {
6785
- const dialog = state.connectDialog;
6786
- if (dialog === void 0 || dialog.localProvidersLoading) return;
6787
- patchLocalDialog({
6788
- localProvidersLoading: true,
6789
- localError: void 0
6790
- });
6791
- try {
6792
- const result = await remoteApi.localLlmDiscover();
6793
- const current = state.connectDialog;
6794
- if (current === void 0) return;
6795
- patchLocalDialog({
6796
- localProvidersLoading: false,
6797
- localProvidersLoaded: true,
6798
- localProviders: result.providers,
6799
- localSelection: mergeLocalSelection(result.providers, current.localSelection, current.localProviders)
6800
- });
6801
- } catch (error) {
6802
- if (state.connectDialog === void 0) return;
6803
- patchLocalDialog({
6804
- localProvidersLoading: false,
6805
- localProvidersLoaded: true,
6806
- localError: t("connect.local.discoverFailed", { message: describeFailure(error) })
6807
- });
6808
- }
6809
- }
6810
- /** Toggle one discovered model in the local-source selection. */
6811
- function toggleLocalModel(providerId, modelId) {
6812
- const dialog = state.connectDialog;
6813
- if (dialog === void 0) return;
6814
- const current = dialog.localSelection[providerId] ?? [];
6815
- const next = current.includes(modelId) ? current.filter((id) => id !== modelId) : [...current, modelId];
6816
- const provider = dialog.localProviders.find((candidate) => candidate.id === providerId);
6817
- const ordered = provider === void 0 ? next : provider.models.map((model) => model.id).filter((id) => next.includes(id));
6818
- commit({ connectDialog: {
6819
- ...dialog,
6820
- localSelection: {
6821
- ...dialog.localSelection,
6822
- [providerId]: ordered
6823
- }
6606
+ modelSource: "local"
6824
6607
  } });
6825
6608
  }
6826
- /** Select every discovered model of one provider, or clear it. */
6827
- function setLocalProviderSelected(providerId, selected) {
6828
- const dialog = state.connectDialog;
6829
- if (dialog === void 0) return;
6830
- const provider = dialog.localProviders.find((candidate) => candidate.id === providerId);
6831
- const models = selected ? provider?.models.map((model) => model.id) ?? [...dialog.localSelection[providerId] ?? []] : [];
6832
- commit({ connectDialog: {
6833
- ...dialog,
6834
- localSelection: {
6835
- ...dialog.localSelection,
6836
- [providerId]: models
6837
- }
6838
- } });
6839
- }
6840
- /** Fold a local-model route failure into the dialog without leaking a URL secret. */
6841
- function patchLocalError(message) {
6842
- const dialog = state.connectDialog;
6843
- if (dialog === void 0) return;
6844
- commit({ connectDialog: {
6845
- ...dialog,
6846
- localSettingsLoading: false,
6847
- ...message === void 0 ? { localError: void 0 } : { localError: message }
6848
- } });
6849
- }
6850
- /**
6851
- * Persist the local source before connecting: always `auto` (the only UI mode)
6852
- * plus the selected models. An unhydrated/empty catalog sends no `selection`,
6853
- * which the host reads as "all discovered models".
6854
- * @returns true when the host accepted the settings.
6855
- */
6856
- async function saveLocalLlmSettings() {
6857
- const dialog = state.connectDialog;
6858
- if (dialog === void 0) return false;
6859
- patchLocalError(void 0);
6860
- patchLocalDialog({ localSettingsLoading: true });
6861
- const selection = localSelectionPayload(dialog);
6862
- try {
6863
- const read = await remoteApi.localLlmSave({
6864
- mode: "auto",
6865
- ...selection === void 0 ? {} : { selection }
6866
- });
6867
- if (state.connectDialog === void 0) return true;
6868
- patchLocalDialog({
6869
- localSettingsLoading: false,
6870
- ...read.selection === void 0 ? {} : { localSelection: selectionRecord(read.selection) }
6871
- });
6872
- return true;
6873
- } catch (error) {
6874
- patchLocalError(t("connect.local.failed", { message: describeFailure(error) }));
6875
- return false;
6876
- }
6877
- }
6878
6609
  /** Close the v1 connect dialog and drop its secret. */
6879
6610
  function closeConnectDialog() {
6880
6611
  commit({ connectDialog: void 0 });
@@ -6930,32 +6661,6 @@ button.dsh-rwv-conv-crumb:hover {
6930
6661
  } });
6931
6662
  return;
6932
6663
  }
6933
- if (dialog.modelSource === "local") {
6934
- if (dialog.localProvidersLoaded && !dialog.localProvidersLoading && dialog.localProviders.length === 0 && dialog.localError === void 0) {
6935
- commit({ connectDialog: {
6936
- ...dialog,
6937
- phase: "failed",
6938
- error: {
6939
- code: "local-llm-unconfigured",
6940
- message: t("connect.local.auto.empty")
6941
- }
6942
- } });
6943
- return;
6944
- }
6945
- if (!await saveLocalLlmSettings()) {
6946
- const message = state.connectDialog?.localError ?? t("connect.local.autoFailed");
6947
- const current = state.connectDialog;
6948
- if (current !== void 0) commit({ connectDialog: {
6949
- ...current,
6950
- phase: "failed",
6951
- error: {
6952
- code: "local-llm-save-failed",
6953
- message
6954
- }
6955
- } });
6956
- return;
6957
- }
6958
- }
6959
6664
  const attemptId = typeof crypto !== "undefined" && typeof crypto.randomUUID === "function" ? crypto.randomUUID() : `connect-${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 10)}`;
6960
6665
  commit({ connectDialog: {
6961
6666
  ...dialog,
@@ -7387,6 +7092,47 @@ button.dsh-rwv-conv-crumb:hover {
7387
7092
  refreshTimers.clear();
7388
7093
  revealedLocal.clear();
7389
7094
  }
7095
+ /**
7096
+ * Whether one method exists on a host platform.
7097
+ * @param method - wizard method id.
7098
+ * @param platform - `process.platform` of the harness host (`'win32'`, `'darwin'`, `'linux'`).
7099
+ * @returns true when the method may be offered on that platform.
7100
+ */
7101
+ function methodAvailable(method, platform) {
7102
+ if (method === "ssh") return true;
7103
+ if (method === "docker") return false;
7104
+ return false;
7105
+ }
7106
+ //#endregion
7107
+ //#region src/client/method-cards.ts
7108
+ /**
7109
+ * The connection methods the v3 connect dialog's step 1 presents.
7110
+ *
7111
+ * Kept as a **pure module** (no React, no shell services) for two reasons:
7112
+ *
7113
+ * - the acceptance criterion for step 1 is "ssh only, and no reserved/teaser
7114
+ * card" — a list that can be asserted directly in a test, which a component
7115
+ * table inside `remote-dialogs.tsx` cannot be (that file imports the shell's
7116
+ * runtime module table, which this repository does not install);
7117
+ * - visibility must be decided by the *shared* predicate the host validates
7118
+ * `connect/start` with ({@link methodAvailable}), so "hidden on the client"
7119
+ * and "refused on the host" cannot drift.
7120
+ */
7121
+ /** Offered methods, in display order. */
7122
+ const OFFERED_METHODS = ["ssh"];
7123
+ /**
7124
+ * The offered methods this host platform can actually run.
7125
+ *
7126
+ * Today that is `['ssh']` everywhere: `methodAvailable` returns false for WSL
7127
+ * until its transport exists, and for the reserved container method on every
7128
+ * platform. Keeping the filter means the dialog never needs a second gate when
7129
+ * a method becomes available.
7130
+ * @param platform - the harness host's `process.platform` (`'win32'`, `'darwin'`, …).
7131
+ * @returns the methods to render as cards, in display order.
7132
+ */
7133
+ function offeredMethods(platform) {
7134
+ return OFFERED_METHODS.filter((method) => methodAvailable(method, platform));
7135
+ }
7390
7136
  //#endregion
7391
7137
  //#region src/client/remote-dialogs.tsx
7392
7138
  /**
@@ -7439,15 +7185,30 @@ button.dsh-rwv-conv-crumb:hover {
7439
7185
  skipped: "connect.status.skipped",
7440
7186
  failed: "connect.status.failed"
7441
7187
  };
7442
- /** Checked model count per provider (missing key = none checked yet). */
7443
- function selectedModelCount(provider, selection) {
7444
- const checked = new Set(selection[provider.id] ?? []);
7445
- return provider.models.reduce((total, model) => total + (checked.has(model.id) ? 1 : 0), 0);
7446
- }
7447
- /** Total number of discovered models across every provider. */
7448
- function totalModelCount(providers) {
7449
- return providers.reduce((total, provider) => total + provider.models.length, 0);
7450
- }
7188
+ /**
7189
+ * Method-card copy, keyed by the pure module's offered-method ids.
7190
+ *
7191
+ * The card list itself comes from {@link offeredMethods} — the same predicate
7192
+ * the host validates — so a method only appears when its transport exists
7193
+ * (`methodAvailable`). WSL keeps its translated copy here so the day
7194
+ * `WSL_TRANSPORT_ENABLED` flips the card renders a real label instead of a raw
7195
+ * key; the config step below is SSH-only and must grow WSL fields before that
7196
+ * flip adds it to `OFFERED_METHODS`.
7197
+ */
7198
+ const METHOD_CARD_COPY = {
7199
+ ssh: {
7200
+ name: "method.ssh.name",
7201
+ description: "method.ssh.description",
7202
+ aria: "method.ssh.aria"
7203
+ },
7204
+ wsl: {
7205
+ name: "method.wsl.name",
7206
+ description: "method.wsl.description",
7207
+ aria: "method.wsl.aria"
7208
+ }
7209
+ };
7210
+ /** Id of the datalist that offers the private keys found under `~/.ssh`. */
7211
+ const SSH_KEY_LIST_ID = "dsh-rw-ssh-key-options";
7451
7212
  function ConnectDialog(props) {
7452
7213
  const dialog = props.state.connectDialog;
7453
7214
  const [step, setStep] = (0, react.useState)("method");
@@ -7455,6 +7216,8 @@ button.dsh-rwv-conv-crumb:hover {
7455
7216
  const [aliasWarnings, setAliasWarnings] = (0, react.useState)([]);
7456
7217
  const [aliasesLoading, setAliasesLoading] = (0, react.useState)(false);
7457
7218
  const [aliasesLoaded, setAliasesLoaded] = (0, react.useState)(false);
7219
+ const [sshKeyOptions, setSshKeyOptions] = (0, react.useState)([]);
7220
+ const [sshKeysLoaded, setSshKeysLoaded] = (0, react.useState)(false);
7458
7221
  const [aliasChoice, setAliasChoice] = (0, react.useState)("");
7459
7222
  const [configError, setConfigError] = (0, react.useState)(void 0);
7460
7223
  const [advancedOpen, setAdvancedOpen] = (0, react.useState)(false);
@@ -7484,6 +7247,19 @@ button.dsh-rwv-conv-crumb:hover {
7484
7247
  aliasesLoaded,
7485
7248
  aliasesLoading
7486
7249
  ]);
7250
+ (0, react.useEffect)(() => {
7251
+ if (step !== "config" || dialog?.authKind !== "privateKey" || sshKeysLoaded) return;
7252
+ api.sshKeys().then((result) => {
7253
+ setSshKeyOptions(result.keys);
7254
+ setSshKeysLoaded(true);
7255
+ }).catch(() => {
7256
+ setSshKeysLoaded(true);
7257
+ });
7258
+ }, [
7259
+ step,
7260
+ dialog?.authKind,
7261
+ sshKeysLoaded
7262
+ ]);
7487
7263
  (0, react.useEffect)(() => {
7488
7264
  if (step !== "connect") return;
7489
7265
  if (props.state.connectDialog?.phase !== "idle") return;
@@ -7646,23 +7422,23 @@ button.dsh-rwv-conv-crumb:hover {
7646
7422
  }),
7647
7423
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
7648
7424
  className: "dsh-rw-methods",
7649
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
7425
+ children: offeredMethods(props.state.platform ?? "").map((method) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
7650
7426
  type: "button",
7651
7427
  className: "dsh-rw-method",
7652
- "data-selected": "true",
7653
- "aria-pressed": true,
7654
- "aria-label": t("method.ssh.aria"),
7428
+ "data-selected": method === "ssh" ? "true" : void 0,
7429
+ "aria-pressed": method === "ssh",
7430
+ "aria-label": t(METHOD_CARD_COPY[method].aria),
7655
7431
  onClick: () => {
7656
7432
  setStep("config");
7657
7433
  },
7658
7434
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
7659
7435
  className: "dsh-rw-method-name",
7660
- children: t("method.ssh.name")
7436
+ children: t(METHOD_CARD_COPY[method].name)
7661
7437
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
7662
7438
  className: "dsh-rw-method-description",
7663
- children: t("method.ssh.description")
7439
+ children: t(METHOD_CARD_COPY[method].description)
7664
7440
  })]
7665
- })
7441
+ }, method))
7666
7442
  })
7667
7443
  ]
7668
7444
  }),
@@ -7804,16 +7580,31 @@ button.dsh-rwv-conv-crumb:hover {
7804
7580
  onChange: (event) => patch({ secret: event.target.value })
7805
7581
  })
7806
7582
  }),
7807
- dialog.authKind === "privateKey" && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
7583
+ dialog.authKind === "privateKey" && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Field, {
7808
7584
  label: t("remote.connect.privateKeyPath"),
7809
7585
  hint: t("remote.connect.privateKeyHint"),
7810
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
7811
- className: "dsh-rw-rename-input",
7812
- value: dialog.privateKeyPath,
7813
- disabled: submitting,
7814
- placeholder: "~/.ssh/id_ed25519",
7815
- onChange: (event) => patch({ privateKeyPath: event.target.value })
7816
- })
7586
+ children: [
7587
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
7588
+ className: "dsh-rw-rename-input",
7589
+ value: dialog.privateKeyPath,
7590
+ disabled: submitting,
7591
+ placeholder: "~/.ssh/id_ed25519",
7592
+ list: SSH_KEY_LIST_ID,
7593
+ onChange: (event) => patch({ privateKeyPath: event.target.value })
7594
+ }),
7595
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("datalist", {
7596
+ id: SSH_KEY_LIST_ID,
7597
+ children: sshKeyOptions.map((option) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
7598
+ value: option.path,
7599
+ label: option.label
7600
+ }, option.path))
7601
+ }),
7602
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
7603
+ className: "dsh-rw-hint",
7604
+ "data-testid": "dsh-rw-ssh-keys",
7605
+ children: sshKeyOptions.length === 0 ? t("remote.connect.privateKeyNone") : t("remote.connect.privateKeyFound", { count: String(sshKeyOptions.length) })
7606
+ })
7607
+ ]
7817
7608
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
7818
7609
  label: t("remote.connect.passphrase"),
7819
7610
  hint: t("remote.connect.passphraseHint"),
@@ -7832,9 +7623,7 @@ button.dsh-rwv-conv-crumb:hover {
7832
7623
  open: advancedOpen,
7833
7624
  expandable: true,
7834
7625
  onToggle: () => {
7835
- const next = !advancedOpen;
7836
- setAdvancedOpen(next);
7837
- if (next && dialog.modelSource === "local" && !dialog.localProvidersLoaded && !dialog.localProvidersLoading) discoverLocalProviders();
7626
+ setAdvancedOpen(!advancedOpen);
7838
7627
  },
7839
7628
  expandOnRowClick: true,
7840
7629
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
@@ -7860,7 +7649,6 @@ button.dsh-rwv-conv-crumb:hover {
7860
7649
  "data-testid": "dsh-rw-model-source",
7861
7650
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
7862
7651
  label: t("connect.local.title"),
7863
- hint: t("connect.local.hint"),
7864
7652
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.SegmentedControl, {
7865
7653
  id: "dsh-rw-connect-model-source",
7866
7654
  value: dialog.modelSource,
@@ -7873,126 +7661,15 @@ button.dsh-rwv-conv-crumb:hover {
7873
7661
  value: "server",
7874
7662
  label: t("connect.local.source.server")
7875
7663
  }],
7876
- onChange: (next) => patch({
7877
- modelSource: next,
7878
- localError: void 0
7879
- })
7664
+ onChange: (next) => patch({ modelSource: next })
7880
7665
  })
7881
7666
  }), dialog.modelSource === "server" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
7882
7667
  className: "dsh-rw-hint",
7883
7668
  children: t("connect.local.serverHint")
7884
- }) : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
7885
- className: "dsh-rw-local-auto",
7886
- children: [
7887
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
7888
- className: "dsh-rw-hint",
7889
- children: t("connect.local.auto.hint")
7890
- }),
7891
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
7892
- className: "dsh-rw-inline dsh-rw-local-models-row",
7893
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
7894
- variant: "outline",
7895
- size: "sm",
7896
- disabled: submitting || dialog.localProvidersLoading || dialog.localSettingsLoading,
7897
- onClick: () => {
7898
- discoverLocalProviders();
7899
- },
7900
- children: dialog.localProvidersLoading ? t("connect.local.auto.refreshing") : t("connect.local.auto.refresh")
7901
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
7902
- className: "dsh-rw-hint",
7903
- "data-testid": "dsh-rw-local-summary",
7904
- children: t("connect.local.auto.summary", {
7905
- providers: dialog.localProviders.length,
7906
- selected: dialog.localProviders.reduce((total, provider) => total + selectedModelCount(provider, dialog.localSelection), 0),
7907
- models: totalModelCount(dialog.localProviders)
7908
- })
7909
- })]
7910
- }),
7911
- dialog.localProvidersLoaded && dialog.localProviders.length === 0 && !dialog.localProvidersLoading && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
7912
- className: "dsh-rw-hint",
7913
- "data-testid": "dsh-rw-local-empty",
7914
- children: t("connect.local.auto.empty")
7915
- }),
7916
- dialog.localProviders.length > 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
7917
- className: "dsh-rw-local-catalog",
7918
- "aria-label": t("connect.local.auto.providers"),
7919
- children: dialog.localProviders.map((provider) => {
7920
- const checked = new Set(dialog.localSelection[provider.id] ?? []);
7921
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
7922
- className: "dsh-rw-local-provider",
7923
- "data-testid": `dsh-rw-local-provider-${provider.id}`,
7924
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
7925
- className: "dsh-rw-local-provider-head",
7926
- children: [
7927
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
7928
- className: "dsh-rw-local-provider-name",
7929
- children: provider.name
7930
- }),
7931
- provider.name !== provider.id && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
7932
- className: "dsh-rw-local-provider-id",
7933
- children: provider.id
7934
- }),
7935
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
7936
- className: "dsh-rw-local-provider-count",
7937
- children: t("connect.local.auto.providerCount", {
7938
- selected: selectedModelCount(provider, dialog.localSelection),
7939
- total: provider.models.length
7940
- })
7941
- }),
7942
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
7943
- className: "dsh-rw-local-provider-actions",
7944
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
7945
- variant: "ghost",
7946
- size: "sm",
7947
- disabled: submitting,
7948
- onClick: () => {
7949
- setLocalProviderSelected(provider.id, true);
7950
- },
7951
- children: t("connect.local.auto.selectAll")
7952
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
7953
- variant: "ghost",
7954
- size: "sm",
7955
- disabled: submitting,
7956
- onClick: () => {
7957
- setLocalProviderSelected(provider.id, false);
7958
- },
7959
- children: t("connect.local.auto.clear")
7960
- })]
7961
- })
7962
- ]
7963
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
7964
- className: "dsh-rw-local-model-list",
7965
- children: provider.models.map((model) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
7966
- className: "dsh-rw-local-model-option",
7967
- children: [
7968
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
7969
- type: "checkbox",
7970
- checked: checked.has(model.id),
7971
- disabled: submitting,
7972
- "data-testid": `dsh-rw-local-model-${provider.id}-${model.id}`,
7973
- onChange: () => {
7974
- toggleLocalModel(provider.id, model.id);
7975
- }
7976
- }),
7977
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
7978
- className: "dsh-rw-local-model-name",
7979
- children: model.name
7980
- }),
7981
- model.name !== model.id && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
7982
- className: "dsh-rw-local-model-id",
7983
- children: model.id
7984
- })
7985
- ]
7986
- }, model.id))
7987
- })]
7988
- }, provider.id);
7989
- })
7990
- }),
7991
- dialog.localError !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
7992
- className: "dsh-rw-side-error",
7993
- children: dialog.localError
7994
- })
7995
- ]
7669
+ }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
7670
+ className: "dsh-rw-hint",
7671
+ "data-testid": "dsh-rw-local-auto-hint",
7672
+ children: t("connect.local.auto.forwardAll")
7996
7673
  })]
7997
7674
  })
7998
7675
  ]
@@ -8128,10 +7805,6 @@ button.dsh-rwv-conv-crumb:hover {
8128
7805
  dialog.error !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
8129
7806
  className: "dsh-rw-side-error",
8130
7807
  children: dialog.error.message
8131
- }),
8132
- dialog.error === void 0 && dialog.localError !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
8133
- className: "dsh-rw-side-error",
8134
- children: dialog.localError
8135
7808
  })
8136
7809
  ]
8137
7810
  })
@@ -8814,7 +8487,7 @@ button.dsh-rwv-conv-crumb:hover {
8814
8487
  const connected = isConnected(view);
8815
8488
  const phase = view.connection?.phase ?? (view.target.status === "ready" ? "ready" : "stopped");
8816
8489
  const failed = view.connection?.error !== void 0 || view.error !== void 0;
8817
- const endpoint = view.target.kind === "wsl" ? view.target.wslDistro ?? view.target.host : `${view.target.username}@${view.target.host}`;
8490
+ const endpoint = `${view.target.username}@${view.target.host}`;
8818
8491
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
8819
8492
  className: "dsh-rw-rail-target",
8820
8493
  "data-active": active ? "true" : void 0,
@@ -9772,34 +9445,6 @@ ${OFFICIAL_UI_STYLES.replace(/\.dsh-rwv-input-([A-Za-z0-9_-]+)/gu, ".uV2eYG_$1")
9772
9445
  min-height: 0;
9773
9446
  }
9774
9447
 
9775
- .dsh-rw-stack {
9776
- display: flex;
9777
- flex-direction: column;
9778
- gap: 14px;
9779
- min-height: 0;
9780
- }
9781
-
9782
- .dsh-rw-scroll {
9783
- display: flex;
9784
- flex-direction: column;
9785
- gap: 14px;
9786
- max-height: 54vh;
9787
- overflow: auto;
9788
- padding-right: 2px;
9789
- }
9790
-
9791
- .dsh-rw-steps {
9792
- display: flex;
9793
- flex-wrap: wrap;
9794
- gap: 6px;
9795
- }
9796
-
9797
- .dsh-rw-step-pill {
9798
- display: inline-flex;
9799
- align-items: center;
9800
- gap: 6px;
9801
- }
9802
-
9803
9448
  .dsh-rw-section {
9804
9449
  display: flex;
9805
9450
  flex-direction: column;
@@ -9973,95 +9618,6 @@ ${OFFICIAL_UI_STYLES.replace(/\.dsh-rwv-input-([A-Za-z0-9_-]+)/gu, ".uV2eYG_$1")
9973
9618
  font-size: 11px;
9974
9619
  color: var(--dsw-alias-label-caption);
9975
9620
  }
9976
-
9977
- /* --------------------------- step-3 scan panels (new cards, layout only)
9978
-
9979
- These are NOT the sidebar's rows: they are the two panels step 3 shows under
9980
- its connection-method cards (the reuse candidate list and the upload summary).
9981
- Every colour/spacing value comes from the shell's tokens, so the cards follow
9982
- the active theme like the rest of the plugin. */
9983
-
9984
- .dsh-rw-scan {
9985
- display: flex;
9986
- flex-direction: column;
9987
- gap: 8px;
9988
- }
9989
-
9990
- .dsh-rw-candidates {
9991
- display: flex;
9992
- flex-direction: column;
9993
- gap: 6px;
9994
- }
9995
-
9996
- .dsh-rw-candidate {
9997
- display: flex;
9998
- align-items: flex-start;
9999
- gap: 10px;
10000
- width: 100%;
10001
- padding: 8px 10px;
10002
- border: 0.5px solid var(--dsw-alias-border-l2);
10003
- border-radius: var(--dsw-radius-md);
10004
- background: var(--dsw-alias-bg-layer-1);
10005
- color: var(--dsw-alias-label-primary);
10006
- font: inherit;
10007
- font-size: 13px;
10008
- text-align: left;
10009
- cursor: pointer;
10010
- }
10011
-
10012
- .dsh-rw-candidate:hover:not(:disabled) {
10013
- background: var(--dsw-alias-interactive-bg-hover);
10014
- }
10015
-
10016
- .dsh-rw-candidate[data-selected="true"] {
10017
- border-color: var(--dsw-alias-state-business-primary);
10018
- }
10019
-
10020
- .dsh-rw-candidate:disabled {
10021
- cursor: not-allowed;
10022
- opacity: 0.6;
10023
- }
10024
-
10025
- .dsh-rw-candidate-main {
10026
- display: flex;
10027
- flex: 1 1 auto;
10028
- flex-direction: column;
10029
- gap: 3px;
10030
- min-width: 0;
10031
- }
10032
-
10033
- .dsh-rw-candidate-path {
10034
- font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
10035
- font-size: 12px;
10036
- word-break: break-all;
10037
- }
10038
-
10039
- .dsh-rw-candidate-meta {
10040
- display: flex;
10041
- align-items: center;
10042
- gap: 6px;
10043
- flex-wrap: wrap;
10044
- font-size: 11px;
10045
- color: var(--dsw-alias-label-tertiary);
10046
- }
10047
-
10048
- .dsh-rw-candidate-note {
10049
- font-size: 11px;
10050
- color: var(--dsw-alias-label-caption);
10051
- }
10052
-
10053
- .dsh-rw-candidate-reason {
10054
- font-size: 11px;
10055
- line-height: 16px;
10056
- color: var(--dsw-alias-state-error-primary);
10057
- }
10058
-
10059
- .dsh-rw-candidate-action {
10060
- flex: none;
10061
- font-size: 11px;
10062
- color: var(--dsw-alias-label-secondary);
10063
- }
10064
-
10065
9621
  /* ---------------------------------------------------------------- fields */
10066
9622
 
10067
9623
  .dsh-rw-fields {
@@ -10070,12 +9626,6 @@ ${OFFICIAL_UI_STYLES.replace(/\.dsh-rwv-input-([A-Za-z0-9_-]+)/gu, ".uV2eYG_$1")
10070
9626
  gap: 12px;
10071
9627
  }
10072
9628
 
10073
- .dsh-rw-grid {
10074
- display: grid;
10075
- grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
10076
- gap: 12px;
10077
- }
10078
-
10079
9629
  .dsh-rw-field {
10080
9630
  display: flex;
10081
9631
  flex-direction: column;
@@ -10211,25 +9761,6 @@ ${OFFICIAL_UI_STYLES.replace(/\.dsh-rwv-input-([A-Za-z0-9_-]+)/gu, ".uV2eYG_$1")
10211
9761
  overflow-wrap: anywhere;
10212
9762
  }
10213
9763
 
10214
- .dsh-rw-hostkey {
10215
- display: flex;
10216
- flex-direction: column;
10217
- gap: 10px;
10218
- padding: 12px;
10219
- border: 0.5px solid var(--dsw-alias-state-warn-primary);
10220
- border-radius: var(--dsw-radius-md);
10221
- background: var(--dsw-alias-bg-layer-1);
10222
- }
10223
-
10224
- .dsh-rw-hostkey-title {
10225
- display: flex;
10226
- align-items: center;
10227
- gap: 6px;
10228
- font-size: 13px;
10229
- font-weight: 500;
10230
- color: var(--dsw-alias-state-warn-primary);
10231
- }
10232
-
10233
9764
  /* ------------------------------------------------------------- directory */
10234
9765
 
10235
9766
  .dsh-rw-crumbs {
@@ -11970,116 +11501,6 @@ ${OFFICIAL_UI_STYLES.replace(/\.dsh-rwv-input-([A-Za-z0-9_-]+)/gu, ".uV2eYG_$1")
11970
11501
  gap: 10px;
11971
11502
  }
11972
11503
 
11973
- .dsh-rw-local-models-row {
11974
- flex-wrap: wrap;
11975
- gap: 8px;
11976
- align-items: center;
11977
- }
11978
-
11979
- .dsh-rw-local-catalog {
11980
- display: flex;
11981
- flex-direction: column;
11982
- gap: 8px;
11983
- max-height: 320px;
11984
- overflow-y: auto;
11985
- overscroll-behavior: contain;
11986
- }
11987
-
11988
- .dsh-rw-local-provider {
11989
- padding: 8px 10px;
11990
- border: 0.5px solid var(--dsw-alias-border-l1);
11991
- border-radius: var(--dsw-radius-md);
11992
- background: var(--dsw-alias-bg-layer-1);
11993
- }
11994
-
11995
- .dsh-rw-local-provider-head {
11996
- display: flex;
11997
- align-items: center;
11998
- gap: 8px;
11999
- min-width: 0;
12000
- }
12001
-
12002
- .dsh-rw-local-provider-name {
12003
- min-width: 0;
12004
- overflow: hidden;
12005
- font-size: 12px;
12006
- font-weight: 600;
12007
- color: var(--dsw-alias-label-primary);
12008
- text-overflow: ellipsis;
12009
- white-space: nowrap;
12010
- }
12011
-
12012
- .dsh-rw-local-provider-id {
12013
- min-width: 0;
12014
- overflow: hidden;
12015
- font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
12016
- font-size: 11px;
12017
- color: var(--dsw-alias-label-tertiary);
12018
- text-overflow: ellipsis;
12019
- white-space: nowrap;
12020
- }
12021
-
12022
- .dsh-rw-local-provider-count {
12023
- flex: none;
12024
- font-size: 11px;
12025
- color: var(--dsw-alias-label-caption);
12026
- font-variant-numeric: tabular-nums;
12027
- }
12028
-
12029
- .dsh-rw-local-provider-actions {
12030
- flex: none;
12031
- gap: 2px;
12032
- margin-left: auto;
12033
- }
12034
-
12035
- .dsh-rw-local-model-list {
12036
- display: flex;
12037
- flex-direction: column;
12038
- gap: 1px;
12039
- margin-top: 6px;
12040
- }
12041
-
12042
- .dsh-rw-local-model-option {
12043
- display: flex;
12044
- align-items: center;
12045
- gap: 8px;
12046
- padding: 3px 2px;
12047
- border-radius: var(--dsw-radius-sm);
12048
- font-size: 12px;
12049
- line-height: 18px;
12050
- color: var(--dsw-alias-label-secondary);
12051
- cursor: pointer;
12052
- }
12053
-
12054
- .dsh-rw-local-model-option:hover {
12055
- background: var(--dsw-alias-bg-secondary, rgb(127 127 127 / 10%));
12056
- }
12057
-
12058
- .dsh-rw-local-model-option input[type='checkbox'] {
12059
- flex: none;
12060
- margin: 0;
12061
- accent-color: var(--dsw-alias-brand-primary, #4d6bfe);
12062
- }
12063
-
12064
- .dsh-rw-local-model-name {
12065
- min-width: 0;
12066
- overflow: hidden;
12067
- text-overflow: ellipsis;
12068
- white-space: nowrap;
12069
- }
12070
-
12071
- .dsh-rw-local-model-id {
12072
- min-width: 0;
12073
- margin-left: auto;
12074
- padding-left: 8px;
12075
- overflow: hidden;
12076
- font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
12077
- font-size: 11px;
12078
- color: var(--dsw-alias-label-tertiary);
12079
- text-overflow: ellipsis;
12080
- white-space: nowrap;
12081
- }
12082
-
12083
11504
  /* Elapsed time next to the primary connect action while submitting. */
12084
11505
  .dsh-rw-connect-elapsed {
12085
11506
  font-size: 12px;