@songsid/agend 2.3.5-alpha.6 → 2.3.5-alpha.7
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/dist/auth-api.js +11 -0
- package/dist/auth-api.js.map +1 -1
- package/dist/authority/web-authority.d.ts +13 -0
- package/dist/authority/web-authority.js +12 -0
- package/dist/authority/web-authority.js.map +1 -1
- package/dist/backend/claude-code.js +47 -9
- package/dist/backend/claude-code.js.map +1 -1
- package/dist/backend/kiro.js +1 -1
- package/dist/backend/kiro.js.map +1 -1
- package/dist/build-provenance.json +1 -1
- package/dist/channel/access-manager.d.ts +1 -6
- package/dist/channel/access-manager.js +4 -94
- package/dist/channel/access-manager.js.map +1 -1
- package/dist/channel/adapters/discord.d.ts +0 -2
- package/dist/channel/adapters/discord.js +0 -8
- package/dist/channel/adapters/discord.js.map +1 -1
- package/dist/channel/adapters/telegram.d.ts +0 -3
- package/dist/channel/adapters/telegram.js +1 -30
- package/dist/channel/adapters/telegram.js.map +1 -1
- package/dist/channel/types.d.ts +0 -2
- package/dist/cli.js +1 -19
- package/dist/cli.js.map +1 -1
- package/dist/fleet-manager.d.ts +59 -1
- package/dist/fleet-manager.js +336 -28
- package/dist/fleet-manager.js.map +1 -1
- package/dist/general-knowledge/skills/concepts/SKILL.md +22 -7
- package/dist/general-knowledge/steering/core-rules.md +6 -4
- package/dist/hub/buttons.js +4 -2
- package/dist/hub/buttons.js.map +1 -1
- package/dist/hub/catalog.d.ts +1 -1
- package/dist/hub/catalog.js +82 -15
- package/dist/hub/catalog.js.map +1 -1
- package/dist/hub/compose/server.d.ts +4 -1
- package/dist/hub/compose/server.js +29 -3
- package/dist/hub/compose/server.js.map +1 -1
- package/dist/hub/directory/directory.d.ts +1 -1
- package/dist/hub/directory/directory.js +32 -23
- package/dist/hub/directory/directory.js.map +1 -1
- package/dist/hub/directory/index.d.ts +1 -1
- package/dist/hub/directory/types.d.ts +8 -2
- package/dist/hub/directory/types.js.map +1 -1
- package/dist/hub/group-policy/admin-context.d.ts +23 -0
- package/dist/hub/group-policy/admin-context.js +52 -0
- package/dist/hub/group-policy/admin-context.js.map +1 -0
- package/dist/hub/group-policy/admin-dto.d.ts +235 -0
- package/dist/hub/group-policy/admin-dto.js +55 -0
- package/dist/hub/group-policy/admin-dto.js.map +1 -0
- package/dist/hub/group-policy/admin-inventory.d.ts +24 -0
- package/dist/hub/group-policy/admin-inventory.js +72 -0
- package/dist/hub/group-policy/admin-inventory.js.map +1 -0
- package/dist/hub/group-policy/admin-read.d.ts +21 -0
- package/dist/hub/group-policy/admin-read.js +90 -0
- package/dist/hub/group-policy/admin-read.js.map +1 -0
- package/dist/hub/group-policy/authorization.d.ts +43 -0
- package/dist/hub/group-policy/authorization.js +170 -0
- package/dist/hub/group-policy/authorization.js.map +1 -0
- package/dist/hub/group-policy/resources.d.ts +9 -1
- package/dist/hub/group-policy/resources.js +30 -5
- package/dist/hub/group-policy/resources.js.map +1 -1
- package/dist/hub/group-policy/store.d.ts +8 -2
- package/dist/hub/group-policy/store.js +9 -3
- package/dist/hub/group-policy/store.js.map +1 -1
- package/dist/hub/http/compose.js +6 -7
- package/dist/hub/http/compose.js.map +1 -1
- package/dist/hub/http/core.d.ts +23 -3
- package/dist/hub/http/core.js +138 -5
- package/dist/hub/http/core.js.map +1 -1
- package/dist/hub/http/deps.d.ts +3 -0
- package/dist/hub/policy.d.ts +3 -1
- package/dist/hub/policy.js +13 -6
- package/dist/hub/policy.js.map +1 -1
- package/dist/hub/rooms.d.ts +1 -0
- package/dist/hub/rooms.js +76 -26
- package/dist/hub/rooms.js.map +1 -1
- package/dist/hub/sessions.js +2 -1
- package/dist/hub/sessions.js.map +1 -1
- package/dist/hub/types.d.ts +2 -0
- package/dist/locale.js +26 -20
- package/dist/locale.js.map +1 -1
- package/dist/runtime-api.js +10 -2
- package/dist/runtime-api.js.map +1 -1
- package/dist/settings-api.js +3 -2
- package/dist/settings-api.js.map +1 -1
- package/dist/settings-change.d.ts +10 -0
- package/dist/settings-change.js +17 -1
- package/dist/settings-change.js.map +1 -1
- package/dist/settings-confirmation.d.ts +25 -1
- package/dist/settings-confirmation.js +11 -3
- package/dist/settings-confirmation.js.map +1 -1
- package/dist/settings-effect.js +18 -6
- package/dist/settings-effect.js.map +1 -1
- package/dist/settings-http-confirmation.d.ts +21 -0
- package/dist/settings-http-confirmation.js +74 -3
- package/dist/settings-http-confirmation.js.map +1 -1
- package/dist/structured-signin.js +3 -1
- package/dist/structured-signin.js.map +1 -1
- package/dist/tips.js +4 -4
- package/dist/tips.js.map +1 -1
- package/dist/types.d.ts +2 -0
- package/dist/types.js.map +1 -1
- package/dist/ui/accounts-keepalive.js +4 -3
- package/dist/ui/accounts-manage.js +2 -2
- package/dist/ui/accounts-view.js +18 -7
- package/dist/ui/backend-signin.js +12 -3
- package/dist/ui/general-location.js +28 -14
- package/dist/ui/hub-chat-store.js +2 -1
- package/dist/ui/hub-grant-strings.js +13 -0
- package/dist/ui/hub-owner-strings.js +6 -2
- package/dist/ui/hub-strings.js +4 -2
- package/dist/ui/panel-hub.js +68 -23
- package/dist/ui/panel-log.js +2 -2
- package/dist/ui/panel-runtimes.js +14 -6
- package/dist/ui/panel-settings.js +7 -19
- package/dist/ui/runtime-cli-install.js +24 -4
- package/dist/ui/settings-confirm.js +28 -0
- package/dist/ui/settings-devices.js +6 -10
- package/dist/ui/settings-hub-membership.js +6 -6
- package/dist/ui/settings-hub-section.js +35 -0
- package/dist/ui/settings-hub.js +6 -2
- package/dist/ui/settings-layout.js +6 -2
- package/dist/ui/settings-named-test.js +2 -2
- package/dist/ui/settings-outside.js +1 -1
- package/dist/ui/settings-quota-notice.js +8 -6
- package/dist/ui/settings-registry.js +3 -0
- package/dist/ui/settings-strings.js +6 -6
- package/dist/ui/shared/app-i18n.js +4 -2
- package/dist/ui/shared/app-route.js +1 -1
- package/dist/ui/shared/app-shell.js +102 -5
- package/dist/ui/shared/app.css +16 -0
- package/dist/ui/shared/chat-strings.js +8 -8
- package/dist/ui/shared/hub-owner.css +2 -2
- package/dist/ui/shared/hub-signin.css +24 -0
- package/dist/ui/shared/view-strings.js +4 -4
- package/dist/ui/structured-signin.js +16 -8
- package/dist/usage/providers.d.ts +1 -0
- package/dist/usage/providers.js +13 -9
- package/dist/usage/providers.js.map +1 -1
- package/dist/web-api.d.ts +5 -0
- package/dist/web-api.js +15 -6
- package/dist/web-api.js.map +1 -1
- package/dist/web-remote-access.d.ts +6 -0
- package/dist/web-remote-access.js +10 -1
- package/dist/web-remote-access.js.map +1 -1
- package/dist/web-shell-routes.d.ts +1 -1
- package/dist/web-shell-routes.js +1 -1
- package/dist/web-shell-routes.js.map +1 -1
- package/dist/windows-cli-api.d.ts +8 -0
- package/dist/windows-cli-api.js +10 -0
- package/dist/windows-cli-api.js.map +1 -1
- package/package.json +2 -1
|
@@ -170,7 +170,7 @@ function MachineCard({ machine, busy, action, openDiagnostics, probe, repairUpda
|
|
|
170
170
|
!local && status !== "revoked" && {key:"rename",label:machineText("rename"),icon:"edit",onSelect:()=>setEditing(true)},
|
|
171
171
|
!local && status !== "revoked" && {key:"revoke",label:machineText("revoke"),icon:"close",danger:true,onSelect:()=>action(machine,"revoke")}];
|
|
172
172
|
return html`<article class=${`runtime-machine${local ? " runtime-native-local" : ""}${revoked ? " is-revoked" : ""}`} data-machine-id=${local ? "local" : machine.id}>
|
|
173
|
-
<header><span class="runtime-machine-icon"><${Icon} name="fleet" size=${22} /></span><div><h3>${machine.name}${revoked ? null : html`<span class="runtime-kind">${machineText(local ? "localBadge" : "pairedBadge")}</span>`}</h3><p>${machine.platform === "win32" ? "Windows" : machine.platform || machineText("unknown")}${machine.hostname && machine.hostname !== machine.name ? ` · ${machine.hostname}` : ""} · ${machineText("cliCount",clis.length)}</p></div><span class=${`runtime-status is-${status}`}><span class="windows-cli-dot"></span>${machineText(["available","online","offline","pending","revoked"].includes(status) ? status : "unknown")}</span></header>
|
|
173
|
+
<header><span class="runtime-machine-icon"><${Icon} name="fleet" size=${22} /></span><div><h3>${machine.name}${revoked ? null : html`<span class="runtime-kind">${machineText(local ? "localBadge" : "pairedBadge")}</span>`}</h3><p>${machine.platform === "win32" ? "Windows" : machine.platform || machineText("unknown")}${machine.hostname && machine.hostname !== machine.name ? ` · ${machine.hostname}` : ""} · ${machineText((clis.length) === 1 ? "cliCountOne" : "cliCount",clis.length)}</p></div><span class=${`runtime-status is-${status}`}><span class="windows-cli-dot"></span>${machineText(["available","online","offline","pending","revoked"].includes(status) ? status : "unknown")}</span></header>
|
|
174
174
|
${!local && !revoked && machine.runtimeCompatibility === "incompatible" ? html`<p class="runtime-reinstall" role="alert">${machineText("needsReinstall")}</p>` : null}
|
|
175
175
|
${!local && !revoked && status !== "pending" ? html`<${RuntimeUpdateNotice} machine=${machine} onRepair=${() => repairUpdate(machine)} />` : null}
|
|
176
176
|
${revoked ? null : html`<p class="runtime-inventory-time note">${machine.inventoryUpdatedAt ? machineText("inventoryAt",machineTime(machine.inventoryUpdatedAt)) : machineText("neverDetected")}</p>`}
|
|
@@ -183,7 +183,9 @@ function MachineCard({ machine, busy, action, openDiagnostics, probe, repairUpda
|
|
|
183
183
|
<${Menu} cls="runtime-machine-menu" label=${machineText("machineActions",machine.name)} disabled=${busy} items=${menuItems} />
|
|
184
184
|
</div>
|
|
185
185
|
${info ? html`<${Dialog} title=${`${machineText("machineInfo")} · ${machine.name}`} onClose=${()=>setInfo(false)}><dl class="runtime-machine-facts"><dt>${machineText("machineName")}</dt><dd>${machine.name}</dd><dt>${machineText("hostName")}</dt><dd>${machine.hostname || machine.inventory?.hostname || machineText("unknown")}</dd><dt>${machineText("platform")}</dt><dd>${machine.platform === "win32" ? "Windows" : machine.platform}</dd>${local ? html`<dt>${machineText("home")}</dt><dd>${machine.inventory?.home || machineText("unknown")}</dd>` : html`<dt>${machineText("version")}</dt><dd class="runtime-reported-version">${machine.runtimeInfo?.version || machineText(machine.runtimeInfo ? "versionUnreadable" : "versionNotReported")}</dd>${machine.runtimeInfo ? html`<dt>${machineText("buildId")}</dt><dd class="runtime-reported-build"><code>${machine.runtimeInfo?.buildId || machineText("buildUnavailable")}</code></dd><dt>${machineText("protocols")}</dt><dd>${machine.runtimeInfo?.protocolVersions?.map(v=>`v${v}`).join(", ") || machineText("protocolUnknown")}</dd>` : null}<dt>${machineText("compatibility")}</dt><dd class="runtime-compatibility">${machineText(["compatible","legacy","incompatible"].includes(machine.runtimeCompatibility) ? machine.runtimeCompatibility : "protocolUnknown")}</dd>${machine.runtimeInfo ? html`<dt>${machineText("capabilities")}</dt><dd>${machine.runtimeInfo?.capabilities?.map(capability=>["exec","mcp","panes"].includes(capability) ? machineText(`capability_${capability}`) : capability === "credential-profiles" ? machineText("capability_credentialProfiles") : capability).join(" · ") || machineText("unknown")}</dd>` : null}<dt>${machineText("lastSeenLabel")}</dt><dd>${machineTime(machine.lastSeenAt)}</dd><dt>${machineText("identity")}</dt><dd><code>${machine.id}</code></dd>`}</dl></${Dialog}>` : null}
|
|
186
|
-
${editing ? html`<${Dialog} title=${machineText("rename")} onClose=${()=>setEditing(false)} busy=${busy}
|
|
186
|
+
${editing ? html`<${Dialog} title=${machineText("rename")} onClose=${()=>setEditing(false)} busy=${busy}
|
|
187
|
+
actions=${html`<button type="button" class="btn" disabled=${busy} onClick=${()=>setEditing(false)}>${machineText("cancel")}</button><button class="btn btn-primary" type="submit" form=${`runtime-rename-${machine.id}`} disabled=${busy || !name.trim()}>${machineText("save")}</button>`}>
|
|
188
|
+
<form id=${`runtime-rename-${machine.id}`} class="runtime-rename" onSubmit=${event=>{event.preventDefault();if(name.trim())void action(machine,"rename",{name:name.trim()}).then(ok=>{if(ok)setEditing(false);});}}><label class="field"><span>${machineText("name")}</span><input value=${name} maxLength=${100} onInput=${event=>setName(event.target.value)} /></label></form></${Dialog}>` : null}
|
|
187
189
|
</article>`;
|
|
188
190
|
}
|
|
189
191
|
function RuntimeDiagnosticsDialog({ navKey, machineId, machine, enabled, drafts, session, taskLease, onChanged, onClose }) {
|
|
@@ -399,7 +401,7 @@ export function RuntimesPanel({navKey}) {
|
|
|
399
401
|
if(typeof document !== "undefined")lease.timeout(() => document.getElementById(`runtime-install-tab-${tabItems[next].id}`)?.focus(),0);
|
|
400
402
|
};
|
|
401
403
|
const installTabs=html`<div class="s-page-tabs runtime-install-tabs" role="tablist" aria-label=${machineText("installMethod")}>${tabItems.map((item,index) => html`<button key=${item.id} id=${`runtime-install-tab-${item.id}`} type="button" role="tab" class=${tab === item.id ? "on" : ""} aria-selected=${tab === item.id ? "true" : "false"} aria-controls="runtime-install-panel" tabindex=${tab === item.id ? 0 : -1} onClick=${() => setTab(item.id)} onKeyDown=${event => tabKeys(event,index)}>${item.label}</button>`)}</div>`;
|
|
402
|
-
const addressStep=step(1,machineText("server"),html`<input type="url" aria-label=${machineText("server")} value=${server} disabled=${busy === "download"} spellcheck=${false} onInput=${event => setServer(event.target.value)}
|
|
404
|
+
const addressStep=step(1,machineText("server"),html`<div class="field"><input type="url" aria-label=${machineText("server")} value=${server} disabled=${busy === "download"} spellcheck=${false} onInput=${event => setServer(event.target.value)} /></div><p class="note">${machineText("serverHint")}</p>${command ? null : html`<p role="alert">${machineText("serverInvalid")}</p>`}`);
|
|
403
405
|
const approveStep=step(4,machineText("stepApprove"),html`<p class="note">${machineText("stepApproveHint")}</p>`);
|
|
404
406
|
const windowsSteps=html`${addressStep}
|
|
405
407
|
${step(2,machineText("stepInstall"),html`<p class="note">${machineText("stepInstallHint")}</p>
|
|
@@ -410,10 +412,10 @@ export function RuntimesPanel({navKey}) {
|
|
|
410
412
|
${approveStep}`;
|
|
411
413
|
const zipSteps=html`${addressStep}
|
|
412
414
|
${step(2,machineText("stepDownload"),html`<p class="note">${machineText("stepZipHint")}</p>${download()}${downloadedFor ? html`<p class="note" role="status">${machineText("downloadedFor",downloadedFor)}</p>` : null}`)}
|
|
413
|
-
${step(3,machineText("stepLaunch"),html`<p class="note">${machineText("stepLaunchHint")}</p>${command ? html`<details class="runtime-manual-command"><summary>${machineText("manualCommand")}</summary><label><span>${machineText("command")}</span><input class="runtime-command" value=${command} readOnly=${true} spellcheck=${false} /></label><p class="note">${machineText("manualMultiHint")}</p></details>` : null}`)}
|
|
415
|
+
${step(3,machineText("stepLaunch"),html`<p class="note">${machineText("stepLaunchHint")}</p>${command ? html`<details class="runtime-manual-command"><summary>${machineText("manualCommand")}</summary><label class="field"><span>${machineText("command")}</span><input class="runtime-command" value=${command} readOnly=${true} spellcheck=${false} /></label><p class="note">${machineText("manualMultiHint")}</p></details>` : null}`)}
|
|
414
416
|
${approveStep}`;
|
|
415
417
|
|
|
416
|
-
const computers = html`<section class="runtime-computers"><div class="runtime-computers-heading"><h3>${machineText("computersTitle")}</h3><div class="note">${state.data ? machineText("machineCount",allMachines.length) : !state.error ? html`<${Skeleton} variant="inline" lines=${1} />` : "—"}</div></div>
|
|
418
|
+
const computers = html`<section class="runtime-computers"><div class="runtime-computers-heading"><h3>${machineText("computersTitle")}</h3><div class="note">${state.data ? machineText((allMachines.length) === 1 ? "machineCountOne" : "machineCount",allMachines.length) : !state.error ? html`<${Skeleton} variant="inline" lines=${1} />` : "—"}</div></div>
|
|
417
419
|
<section class="runtime-machines" aria-label=${machineText("machines")}>${!state.data && !state.error ? html`<${Skeleton} variant="cards" lines=${2} label=${machineText("loading")} />` : allMachines.map(machine=>html`<${MachineCard} key=${machine.isLocal ? "local" : machine.id} lease=${lease} onChanged=${state.refresh} machine=${machine} busy=${!!busy || !!machine.probing} action=${action} openDiagnostics=${openDiagnostics} probe=${probeTarget} repairUpdate=${setRepairMachine} />`)}</section>
|
|
418
420
|
${repairMachine ? html`<${Dialog} title=${runtimeUpdateText("repairTitle")} onClose=${() => setRepairMachine(null)}>
|
|
419
421
|
<p>${runtimeUpdateText("repairHint")}</p>
|
|
@@ -430,9 +432,15 @@ export function RuntimesPanel({navKey}) {
|
|
|
430
432
|
${error || state.error ? html`<div class="runtime-error" role="alert"><p>${error || state.error}</p>${state.data && state.error ? html`<p>${machineText("seenCached")}</p>` : null}<button type="button" class="btn btn-sm" onClick=${state.refresh}>${machineText("retry")}</button></div>` : null}
|
|
431
433
|
${pairing ? html`<section class="runtime-pairing" aria-label=${machineText("pairing")}><header><h3>${machineText("pairing")}</h3><p class="note">${machineText("pairingHint")}</p></header><div class="runtime-pairing-body"><div class="runtime-install">${installTabs}<div id="runtime-install-panel" class="runtime-install-panel" role="tabpanel" aria-labelledby=${`runtime-install-tab-${tab}`} data-install-method=${tab}><ol class="runtime-steps">
|
|
432
434
|
${tab === "windows" ? windowsSteps : zipSteps}
|
|
433
|
-
</ol></div></div><aside class=${`runtime-pair-card${awaitingApproval ? " is-pending" : ""}`}><label><span>${machineText("pairingCode")}</span><div class="runtime-pair-code-row"><input class="runtime-pair-code" value=${pairing.code} readOnly=${true} spellcheck=${false} autocomplete="off" /><button type="button" class="btn btn-sm" onClick=${copyCode}><${Icon} name="copy" size=${15} />${machineText(copied ? "codeCopied" : "copyCode")}</button></div></label><p class="note">${machineText("expires",machineTime(pairing.expiresAt))}</p><p class="runtime-pair-status" role="status"><span class="windows-cli-dot"></span>${machineText(awaitingApproval ? "pairingApprove" : "pairingWait")}</p><div class="runtime-pair-actions"><button type="button" class="btn btn-sm" disabled=${!!busy} onClick=${connect}>${machineText("newCode")}</button><button type="button" class="btn btn-ghost btn-sm" onClick=${() => setPairing(null)}>${machineText("closeCode")}</button></div></aside></div></section>` : null}
|
|
435
|
+
</ol></div></div><aside class=${`runtime-pair-card${awaitingApproval ? " is-pending" : ""}`}><label class="field"><span>${machineText("pairingCode")}</span><div class="runtime-pair-code-row"><input class="runtime-pair-code" value=${pairing.code} readOnly=${true} spellcheck=${false} autocomplete="off" /><button type="button" class="btn btn-sm" onClick=${copyCode}><${Icon} name="copy" size=${15} />${machineText(copied ? "codeCopied" : "copyCode")}</button></div></label><p class="note">${machineText("expires",machineTime(pairing.expiresAt))}</p><p class="runtime-pair-status" role="status"><span class="windows-cli-dot"></span>${machineText(awaitingApproval ? "pairingApprove" : "pairingWait")}</p><div class="runtime-pair-actions"><button type="button" class="btn btn-sm" disabled=${!!busy} onClick=${connect}>${machineText("newCode")}</button><button type="button" class="btn btn-ghost btn-sm" onClick=${() => setPairing(null)}>${machineText("closeCode")}</button></div></aside></div></section>` : null}
|
|
434
436
|
<${RuntimeSwitches} lease=${lease} onChanged=${state.refresh} computers=${computers} />
|
|
435
437
|
${diagnosticMachineId !== null ? html`<${RuntimeDiagnosticsDialog} key=${diagnosticMachineId || "local"} navKey=${navKey} machineId=${diagnosticMachineId} machine=${target} enabled=${diagnosticMachineId !== "" || windowsCli} drafts=${drafts.current} session=${taskSessions.current.get(diagnosticMachineId)} taskLease=${lease} onChanged=${state.refresh} onClose=${()=>setDiagnosticMachineId(null)} />` : null}
|
|
436
438
|
<p class="note runtime-operations-note">${machineText("operationsNote")}</p>
|
|
437
439
|
</section>`;
|
|
438
440
|
}
|
|
441
|
+
|
|
442
|
+
// Ridge #3321 S17: one computer, one CLI — not "1 computers", "1 CLIs".
|
|
443
|
+
register("machines", {
|
|
444
|
+
en: { cliCountOne: "{0} CLI", machineCountOne: "{0} computer" },
|
|
445
|
+
"zh-TW": { cliCountOne: "{0} 個 CLI", machineCountOne: "{0} 台電腦" },
|
|
446
|
+
});
|
|
@@ -60,22 +60,7 @@ import { syncStage, useDraft } from "./settings-draft.js";
|
|
|
60
60
|
import { WebAuthorityCard } from "./settings-web-authority.js";
|
|
61
61
|
import { OutsideCard } from "./settings-outside.js";
|
|
62
62
|
import { DevicesCard } from "./settings-devices.js";
|
|
63
|
-
|
|
64
|
-
function HubCardSlot() {
|
|
65
|
-
const [Card, setCard] = useState(null);
|
|
66
|
-
useEffect(() => { let live = true; import("./settings-hub-membership.js").then((m) => { if (live) setCard(() => m.HubMembershipSettings); }, () => {}); return () => { live = false; }; }, []);
|
|
67
|
-
return Card ? html`<${Card} />` : null;
|
|
68
|
-
}
|
|
69
|
-
function HubBrowserCertificateSlot() {
|
|
70
|
-
const [Card, setCard] = useState(null);
|
|
71
|
-
useEffect(() => { let live = true; import("./settings-hub-browser-certificate.js").then(m => { if (live) setCard(() => m.HubBrowserCertificateSettings); }, () => {}); return () => { live = false; }; }, []);
|
|
72
|
-
return Card ? html`<${Card} />` : null;
|
|
73
|
-
}
|
|
74
|
-
function HubRetentionSlot() {
|
|
75
|
-
const [Card, setCard] = useState(null);
|
|
76
|
-
useEffect(() => { let live = true; import("./settings-hub-retention.js").then(m => { if (live) setCard(() => m.HubRetentionSettings); }, () => {}); return () => { live = false; }; }, []);
|
|
77
|
-
return Card ? html`<${Card} />` : null;
|
|
78
|
-
}
|
|
63
|
+
import { HubSection, hubSectionText } from "./settings-hub-section.js";
|
|
79
64
|
import { NamedLinkTest, setTypedTunnelToken } from "./settings-named-test.js";
|
|
80
65
|
import { SignInList } from "./backend-signin.js";
|
|
81
66
|
import { AccountsView, defaultsBackendOptions } from "./accounts-view.js"; // #3212: SignInList stays exported for a page that still imports it
|
|
@@ -93,7 +78,7 @@ const APPLY_ERRORS = new Set(["unsupported_sensitive_effect", "confirmation_diff
|
|
|
93
78
|
"request_no_longer_current", "too_many_pending_changes", "fleet_unavailable", "invalid_settings_effect", "settings_confirmation_unavailable", "failed"]);
|
|
94
79
|
// #2726: a code or words of the setup host (the wizard's commit) in the page's language; anything else as it came.
|
|
95
80
|
export const applyErrorText = (code) => (APPLY_ERRORS.has(code) ? tn(`applyError_${code}`) : tn("applyErrorOther", hostText(String(code), lang())));
|
|
96
|
-
const ICONS = { preferences: "user", look: "palette", agents: "bot", notifications: "sliders", runtimes: "view", "agent-defaults": "sliders", chat: "chat", "web-dashboard": "globe", access: "key", advanced: "code" };
|
|
81
|
+
const ICONS = { preferences: "user", look: "palette", agents: "bot", notifications: "sliders", runtimes: "view", "agent-defaults": "sliders", chat: "chat", "web-dashboard": "globe", access: "key", hub: "plug", advanced: "code" };
|
|
97
82
|
|
|
98
83
|
/** GET under the panel's lease → { ok, status, body }. */
|
|
99
84
|
async function read(lease, path) {
|
|
@@ -434,6 +419,8 @@ export function SettingsPanel({ route, navKey }) {
|
|
|
434
419
|
<details class="s-ui-disclosure s-classic-defaults"><summary>${layoutText("classicDefaults")}</summary><div class="s-disclosure-body"><${General} key=${formKey} ctx=${ctx} part="classic" /></div></details></div>`
|
|
435
420
|
: section === "web-dashboard" ? html`<${WebSection} key=${formKey} ctx=${ctx} staged=${staged} part="dashboard" /><${AppearanceSection} ...${you} part="dashboard" />`
|
|
436
421
|
: section === "access" ? html`<${WebSection} key=${formKey} ctx=${ctx} staged=${staged} part="access" />`
|
|
422
|
+
// alpha.6 feedback (#2): the Hub cards have their own section (they were under Access & security, unfound by search).
|
|
423
|
+
: section === "hub" ? html`<${HubSection} overPublicLink=${typeof document !== "undefined" && document.body?.dataset?.publicLink === "1"} hubHost=${!!ctx.fleet.hub?.hubId} />`
|
|
437
424
|
: html`<${AdvancedSettings} ctx=${ctx} staged=${staged} formKey=${formKey} draftEpoch=${draftEpoch} />`;
|
|
438
425
|
// #2347 §6: the setting a search result opened — brought into view once its section is drawn (its data may still be
|
|
439
426
|
// on its way), focused, and flashed for 2 s.
|
|
@@ -1414,8 +1401,8 @@ function WebSection({ ctx, staged, part = "all" }) {
|
|
|
1414
1401
|
<details class="s-setting-details"><summary>${layoutText("revSessionDetails")}</summary><p class="note">${tn("webSessionHint")}</p><p class="note">${tn("webNotifyLoginHint")}</p></details>
|
|
1415
1402
|
</section>`)}
|
|
1416
1403
|
${!overPublicLink ? html`<${WebAuthorityCard} ctx=${ctx} staged=${staged} />` : null}
|
|
1417
|
-
${
|
|
1418
|
-
${!
|
|
1404
|
+
${/* A tab whose shell is from before Settings → Hub (its app-route.js has no "hub"): the Hub cards stay here. */ ""}
|
|
1405
|
+
${!SETTINGS_SECTIONS.includes("hub") ? html`<${HubSection} overPublicLink=${overPublicLink} hubHost=${!!ctx.fleet.hub?.hubId} />` : null}
|
|
1419
1406
|
<details class="drawer s-terminal-disclosure"><summary>${tn("webTerminalTitle")}</summary><div class="drawer-body">${lock(html`<section class="card s-access-terminal"><h3>${tn("webTerminalTitle")}</h3>
|
|
1420
1407
|
<p class="note">${tn("webTerminalHint")}</p>
|
|
1421
1408
|
<label class=${fc("check", "termOn")}><input id="webTerminalEnabled" type="checkbox" checked=${f.termOn} onChange=${(e) => set("termOn")(e.target.checked)} /><span>${tn("webTerminalEnabled")}</span><${Impact} schema=${schema} field="web_terminal.enabled" /></label>
|
|
@@ -1428,6 +1415,7 @@ function WebSection({ ctx, staged, part = "all" }) {
|
|
|
1428
1415
|
</div><aside class="card s-access-related"><h3>${layoutText("revRelatedAccess")}</h3>
|
|
1429
1416
|
<button type="button" onClick=${() => setAccessTab("guests")}><${Icon} name="user" size=${18} /><span><strong>${layoutText("accessGuests")}</strong><small>${layoutText("revRelatedGuests")}</small></span><${Icon} name="chevron" size=${16} /></button>
|
|
1430
1417
|
<button type="button" onClick=${() => setAccessTab("sharing")}><${Icon} name="globe" size=${18} /><span><strong>${layoutText("accessSharing")}</strong><small>${layoutText("revRelatedSharing")}</small></span><${Icon} name="chevron" size=${16} /></button>
|
|
1418
|
+
${!overPublicLink && SETTINGS_SECTIONS.includes("hub") ? html`<button type="button" onClick=${() => navigate(sectionPath("hub"))}><${Icon} name="plug" size=${18} /><span><strong>${hubSectionText("relatedTitle")}</strong><small>${hubSectionText("relatedHint")}</small></span><${Icon} name="chevron" size=${16} /></button>` : null}
|
|
1431
1419
|
</aside></div>
|
|
1432
1420
|
</${SettingsTabPanel}>
|
|
1433
1421
|
<${SettingsTabPanel} group="access" id="guests" active=${accessTab === "guests"}>
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { html, useEffect, useRef, useState } from "/assets/app-html.js";
|
|
2
2
|
import { register, t } from "/assets/app-i18n.js";
|
|
3
3
|
import { confirmDialog } from "/assets/ui-confirm.js";
|
|
4
|
+
import { ErrorState, Skeleton } from "/assets/ui-states.js";
|
|
4
5
|
|
|
5
6
|
/**
|
|
6
7
|
* #3190 Part 3b: install a CLI on a paired Windows computer, from Settings → Runtime. The page sends only a CLI id; the Runtime on that computer decides the
|
|
@@ -43,6 +44,20 @@ export const OFFICIAL_COMMANDS = [
|
|
|
43
44
|
export const versionNumber = printed => typeof printed === "string" ? /(?<![\d.])\d+\.\d+\.\d+(?:-[0-9A-Za-z.-]+)?(?![\d.])/.exec(printed)?.[0] ?? null : null;
|
|
44
45
|
export const offersCliInstall = machine => !!machine && !machine.isLocal && machine.runtimeInfo?.capabilities?.includes("cli-install") === true && ["online", "offline"].includes(machine.status);
|
|
45
46
|
|
|
47
|
+
// Ridge #3321 S06 / S09: the words of the loading state and the copyable commands.
|
|
48
|
+
register("runtimeInstall", {
|
|
49
|
+
en: { loading: "Reading this computer's install setting…", copy: "Copy", copied: "Copied", switchCommand: "Command for that computer" },
|
|
50
|
+
"zh-TW": { loading: "正在讀取這台電腦的安裝設定…", copy: "複製", copied: "已複製", switchCommand: "在那台電腦執行的指令" },
|
|
51
|
+
});
|
|
52
|
+
/** Ridge #3321 S09: a command to run on that computer — Runtime's labelled command card (runtime-install.css), with Copy. */
|
|
53
|
+
function CommandCard({ label, command }) {
|
|
54
|
+
const [copied, setCopied] = useState(false);
|
|
55
|
+
const copy = async () => { try { await navigator.clipboard.writeText(command); setCopied(true); } catch { /* it is on screen to copy by hand */ } };
|
|
56
|
+
return html`<div class="runtime-command-card"><span class="runtime-command-label">${label}</span><div class="runtime-command-row">
|
|
57
|
+
<pre class="runtime-command-text" tabindex="0" aria-label=${label}><code>${command}</code></pre>
|
|
58
|
+
<button type="button" class="btn btn-sm" onClick=${copy}>${text(copied ? "copied" : "copy")}</button></div></div>`;
|
|
59
|
+
}
|
|
60
|
+
|
|
46
61
|
export function CliInstall({ machine, lease, onChanged }) {
|
|
47
62
|
const [view, setView] = useState(null), [error, setError] = useState(""), [note, setNote] = useState(""), [busy, setBusy] = useState(false);
|
|
48
63
|
const last = useRef("");
|
|
@@ -56,7 +71,8 @@ export function CliInstall({ machine, lease, onChanged }) {
|
|
|
56
71
|
setView(value);
|
|
57
72
|
return value;
|
|
58
73
|
};
|
|
59
|
-
|
|
74
|
+
const [attempt, setAttempt] = useState(0);
|
|
75
|
+
useEffect(() => { if (online) { setError(""); load().catch(() => { if (lease.current()) setError(text("unreadable")); }); } }, [lease, machine.id, online, attempt]);
|
|
60
76
|
const job = view?.job, running = job?.state === "installing";
|
|
61
77
|
// While an install runs the page asks again every few seconds; when it ends the computer's list is refreshed once.
|
|
62
78
|
useEffect(() => {
|
|
@@ -100,15 +116,19 @@ export function CliInstall({ machine, lease, onChanged }) {
|
|
|
100
116
|
${upToDate ? null : html`<button type="button" class="btn btn-sm" disabled=${!allowed || !online || busy || running || !pinned} onClick=${start}>${entry ? text("reinstall", pinned) : text("install", pinned)}</button>`}</li>`;
|
|
101
117
|
};
|
|
102
118
|
return html`<div class="runtime-cli-install"><h4>${text("title")}</h4><p class="note">${text("lead")}</p>
|
|
103
|
-
${!online ? html`<p class="note" role="status">${text("offline")}</p>`
|
|
119
|
+
${!online ? html`<p class="note" role="status">${text("offline")}</p>`
|
|
120
|
+
// Ridge #3321 S06: until the computer's setting and the pinned versions are read, the shared loading state — not a
|
|
121
|
+
// settled-looking form of disabled buttons with empty versions; a first read that fails says so, with Retry.
|
|
122
|
+
: !view ? (error ? html`<${ErrorState} message=${error} onRetry=${() => setAttempt((n) => n + 1)} />` : html`<${Skeleton} variant="rows" lines=${2} label=${text("loading")} />`)
|
|
123
|
+
: !view.capable ? html`<p class="note" role="status">${text("old")}</p>` : html`
|
|
104
124
|
<ul class="runtime-cli-install-list" aria-label=${text("title")}>${INSTALL_CLIS.map(row)}</ul>
|
|
105
125
|
${view && !view.switches ? html`<p class="note" role="status">${text("unreadable")}</p>` : null}
|
|
106
|
-
${switchState && !allowed ? html`<p class="note runtime-cli-install-off" role="status">${text("switchOff")}</p
|
|
126
|
+
${switchState && !allowed ? html`<p class="note runtime-cli-install-off" role="status">${text("switchOff")}</p><${CommandCard} label=${text("switchCommand")} command=${SWITCH_COMMAND} />` : null}
|
|
107
127
|
${allowed ? html`<p class="note">${switchState.until ? text("switchUntil", new Date(switchState.until).toLocaleString()) : text("switchOn")}</p>` : null}
|
|
108
128
|
${running ? html`<p class="note" role="status" aria-busy="true"><span class="out-spin" aria-hidden="true"></span> ${text("installing")}</p>` : null}
|
|
109
129
|
${note ? html`<p class="note" role="status">${note}</p>` : null}
|
|
110
130
|
${error ? html`<p class="runtime-error" role="alert">${error}</p>` : null}`}
|
|
111
131
|
<details class="runtime-cli-install-others"><summary>${text("othersTitle")}</summary><p class="note">${text("othersLead")}</p>
|
|
112
|
-
<ul>${OFFICIAL_COMMANDS.map(item => html`<li key=${item.id}
|
|
132
|
+
<ul>${OFFICIAL_COMMANDS.map(item => html`<li key=${item.id}><${CommandCard} label=${item.administrator ? `${item.label} (${text("needsAdmin")})` : item.label} command=${item.command} /></li>`)}</ul></details>
|
|
113
133
|
</div>`;
|
|
114
134
|
}
|
|
@@ -67,6 +67,13 @@ function publish() {
|
|
|
67
67
|
withdraw: view.can_withdraw && view.state === "pending" ? () => withdraw(view.id) : null,
|
|
68
68
|
// #2868: this browser may confirm it itself now (the server's read says so; it checks again on the click).
|
|
69
69
|
applyNow: view.can_self_confirm && view.state === "pending" ? () => applyNow(view.id) : null,
|
|
70
|
+
// alpha.6 #2c (hmsg-468cc290): a web-only fleet's own page may confirm it with the authenticator's code.
|
|
71
|
+
confirmWithCode: view.totp === "ready" && view.state === "pending" ? (code) => confirmWithCode(view.id, code) : null,
|
|
72
|
+
totpNotSetUp: view.totp === "not_set_up" && view.state === "pending",
|
|
73
|
+
// Over a link (the leader's ruling (b)): no code here — confirm it in the host computer's own browser, or in General.
|
|
74
|
+
onHost: view.totp === "on_host" && view.state === "pending",
|
|
75
|
+
// A link option turned on (#2453, the leader's ruling on D3): only the browser on the AgEnD computer itself confirms it.
|
|
76
|
+
hostBrowser: view.totp === "host_browser" && view.state === "pending",
|
|
70
77
|
dismiss: TERMINAL.has(view.state) ? () => forget(view.id) : null,
|
|
71
78
|
})),
|
|
72
79
|
});
|
|
@@ -168,6 +175,27 @@ export async function applyNow(id) {
|
|
|
168
175
|
return { ok: false, status: res.status };
|
|
169
176
|
}
|
|
170
177
|
|
|
178
|
+
/**
|
|
179
|
+
* alpha.6 feedback #2c (the user's decision hmsg-468cc290): confirm a pending change on this computer's own page with the
|
|
180
|
+
* owner's authenticator code. The server checks the code (each time step once, the fleet-wide wrong-code limit) and asks
|
|
181
|
+
* again at execution. { ok } or why not: "wrong", "paused" (retryAfterMs), "not_here" (this page can no longer), "unavailable".
|
|
182
|
+
*/
|
|
183
|
+
export async function confirmWithCode(id, code) {
|
|
184
|
+
const e = tracked.get(id);
|
|
185
|
+
if (!e) return { ok: false, error: "not_here" };
|
|
186
|
+
const token = ticket(e);
|
|
187
|
+
let res;
|
|
188
|
+
try { res = await api(`/api/settings/pending/${encodeURIComponent(id)}/confirm-totp`, { method: "POST", body: JSON.stringify({ code: String(code || "").replace(/\s+/g, ""), digest: String(e.view.confirm_digest || "") }) }); }
|
|
189
|
+
catch { return { ok: false, error: "unavailable" }; }
|
|
190
|
+
if (isPendingResponse(res) && res.body.pending_change.id === id) { update(res.body.pending_change, token); schedule(); return { ok: true }; }
|
|
191
|
+
if (res.status === 401 && res.body && res.body.error === "wrong_code") return { ok: false, error: "wrong" };
|
|
192
|
+
if (res.status === 429) return { ok: false, error: "paused", retryAfterMs: Number(res.body && res.body.retryAfterMs) || null };
|
|
193
|
+
// The change is not the one this page showed (#3352 security review, point 2): read it again; the code was not used.
|
|
194
|
+
if (res.status === 409 && res.body && res.body.error === "confirmation_changed") return { ok: false, error: "changed" };
|
|
195
|
+
if (res.status === 403) { if (e.view.totp) update({ ...e.view, totp: undefined }, token); return { ok: false, error: "not_here" }; }
|
|
196
|
+
return { ok: false, error: "unavailable" };
|
|
197
|
+
}
|
|
198
|
+
|
|
171
199
|
/** This session's requests still open on the server (after a reload): followed like new ones. */
|
|
172
200
|
export async function attach() {
|
|
173
201
|
let res;
|
|
@@ -12,9 +12,9 @@
|
|
|
12
12
|
// with the authenticator's code. Anyone else sees the card, the explanation and a disabled button. The server decides
|
|
13
13
|
// that on every request and refuses everything else regardless (POST /ui/devices/{lookup,approve,deny} → 403).
|
|
14
14
|
// Refs #3061 (review of P2b): with web authorization off nobody is an owner, so nobody can add a device or sign another out —
|
|
15
|
-
//
|
|
16
|
-
// confirm screen leads with where the request is from and its address (the device
|
|
17
|
-
// faked) and says to allow only when the new device shows the same code.
|
|
15
|
+
// this card is web-only (the reader is on the AgEnD computer's dashboard), so it explains that and does not name General
|
|
16
|
+
// or ask the computer's owner; and the confirm screen leads with where the request is from and its address (the device
|
|
17
|
+
// name is the browser's own word and can be faked) and says to allow only when the new device shows the same code.
|
|
18
18
|
// The words are English and 繁體中文, as everything in src/ui (tests/i18n-ui-literals-2390.test.ts).
|
|
19
19
|
import { html, useEffect, useRef, useState } from "/assets/app-html.js";
|
|
20
20
|
import { t, register } from "/assets/app-i18n.js";
|
|
@@ -46,8 +46,7 @@ register("devices", {
|
|
|
46
46
|
signOutTitle: "Sign out this device?", signOutLead: "{0} will have to sign in again.", signOutGo: "Sign out",
|
|
47
47
|
signedOut: "{0} was signed out.", alreadyGone: "That device is already signed out.",
|
|
48
48
|
notSaved: "Signed out for now, but the change could not be saved: a restart may bring the session back. Fix the permissions on ~/.agend/web-sessions.json and sign it out again.",
|
|
49
|
-
|
|
50
|
-
authorityOffB: " on the AgEnD computer. It ends every session, this one included, and every device has to sign in again.",
|
|
49
|
+
authorityOff: "Web authorization is off, so no device is the owner: none can add a device or sign another one out.",
|
|
51
50
|
},
|
|
52
51
|
"zh-TW": {
|
|
53
52
|
title: "裝置與登入", lead: "用 8 碼代碼讓新裝置登入。在已登入且已驗證擁有者的裝置上,到這裡核准。",
|
|
@@ -73,13 +72,10 @@ register("devices", {
|
|
|
73
72
|
signOutTitle: "登出這台裝置?", signOutLead: "{0} 需要重新登入。", signOutGo: "登出",
|
|
74
73
|
signedOut: "已登出 {0}。", alreadyGone: "這台裝置已經登出了。",
|
|
75
74
|
notSaved: "暫時登出了,但變更沒能存檔:重新啟動後這個工作階段可能會回來。請修正 ~/.agend/web-sessions.json 的權限,再登出一次。",
|
|
76
|
-
|
|
77
|
-
authorityOffB: "。這個指令會結束所有工作階段(包括目前這個),每台裝置都要重新登入。",
|
|
75
|
+
authorityOff: "網頁授權已關閉,所以沒有任何裝置是擁有者:不能新增裝置,也不能登出其他裝置。",
|
|
78
76
|
},
|
|
79
77
|
});
|
|
80
78
|
const td = (k, ...v) => t(`devices.${k}`, ...v);
|
|
81
|
-
/** The one thing that signs other devices out when nobody is an owner: a command, the same in both languages. */
|
|
82
|
-
export const ROTATE_COMMAND = "agend web-token rotate";
|
|
83
79
|
|
|
84
80
|
/** A wait as words: "2 minutes" / 「2 分鐘」 (rounded up). */
|
|
85
81
|
export function pauseWords(ms) {
|
|
@@ -241,7 +237,7 @@ export function DevicesCard() {
|
|
|
241
237
|
</li>`)}</ul>
|
|
242
238
|
${others && !s.owner && !authorityOff ? html`<p class="note" id="devicesSignOutOwnerOnly">${td("signOutOwnerOnly")}</p>` : null}
|
|
243
239
|
${note ? html`<p class=${`note ${note.ok ? "" : "error"}`} role=${note.ok ? "status" : "alert"} id="devicesNote">${note.text}</p>` : null}` : null}
|
|
244
|
-
${authorityOff ? html`<p class="note s-va-warn" id="devicesAuthorityOff">${td("
|
|
240
|
+
${authorityOff ? html`<p class="note s-va-warn" id="devicesAuthorityOff">${td("authorityOff")}</p>`
|
|
245
241
|
: !s.owner ? html`<p class="note" id="devicesOwnerOnly">${td("ownerOnly")}</p>` : null}
|
|
246
242
|
<div class="save-row"><button type="button" class="btn btn-primary" id="devicesAdd" disabled=${!s.owner} onClick=${open}>${td("add")}</button></div>
|
|
247
243
|
${dlg ? html`<${Dialog} title=${td("dlgTitle")} onClose=${close} busy=${busy} actions=${actions}>${body}</${Dialog}>` : null}
|
|
@@ -14,12 +14,12 @@ register("hubMembership", {
|
|
|
14
14
|
retry: "Check again", reload: "Reload page", reloadHint: "Reload the page to refresh the Hub controls.",
|
|
15
15
|
},
|
|
16
16
|
"zh-TW": {
|
|
17
|
-
title: "Hub 成員功能", enabled: "
|
|
18
|
-
hint: "預設關閉。啟用不會自動配對 Hub
|
|
19
|
-
off: "關閉後會停止新的 Hub
|
|
17
|
+
title: "Hub 成員功能", enabled: "允許這個 Fleet 連線至 Hub",
|
|
18
|
+
hint: "預設關閉。啟用不會自動配對 Hub 或分享 Agent;請在下方另外選擇。",
|
|
19
|
+
off: "關閉後會停止新的 Hub 工作與回答傳送,既有 Agent 對話會保留。",
|
|
20
20
|
loading: "正在讀取成員設定…", pending: "等待擁有者確認…",
|
|
21
21
|
failed: "無法確認成員設定是否已變更。請再次檢查,再嘗試其他變更。",
|
|
22
|
-
unavailable: "
|
|
22
|
+
unavailable: "目前無法使用成員設定。請開啟這個 Fleet 自己的擁有者設定頁面,再次檢查。",
|
|
23
23
|
retry: "再次檢查", reload: "重新整理頁面", reloadHint: "請重新整理頁面以更新 Hub 控制項。",
|
|
24
24
|
},
|
|
25
25
|
});
|
|
@@ -66,9 +66,9 @@ export function HubMembershipSettings() {
|
|
|
66
66
|
finally { owner.current.busy = false; if (owner.current.mounted) setBusy(false); }
|
|
67
67
|
};
|
|
68
68
|
if (publicPage) return null;
|
|
69
|
-
return html`<div class="form hub-membership-settings"><section class="card">
|
|
69
|
+
return html`<div class="form hub-membership-settings"><section class="card" id="hub-membership">
|
|
70
70
|
<h3>${copy("title")}</h3><p class="note">${copy("hint")}</p>
|
|
71
|
-
${!view && messageKey === "loading" ? html`<${Skeleton} variant="rows" lines=${2} label=${copy("loading")} />` : html`<label class="check"><input class="s-ui-toggle" type="checkbox" role="switch" checked=${view?.enabled === true}
|
|
71
|
+
${!view && messageKey === "loading" ? html`<${Skeleton} variant="rows" lines=${2} label=${copy("loading")} />` : html`<label class="check"><input id="hubMemberEnabled" class="s-ui-toggle" type="checkbox" role="switch" checked=${view?.enabled === true}
|
|
72
72
|
disabled=${!view || busy} onChange=${e => change(e.target.checked)} /><span>${copy("enabled")}</span></label>`}
|
|
73
73
|
<p class="note">${copy("off")}</p>
|
|
74
74
|
${messageKey && messageKey !== "loading" ? html`<p role="status">${copy(messageKey)}</p>` : null}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
// alpha.6 feedback (#2): Settings → Hub. Everything about this fleet and a Hub in one section, found by search: the
|
|
2
|
+
// membership switch, then (once it is on and the page is marked a member) Connect to a Hub — address and pairing code,
|
|
3
|
+
// the fingerprint to compare, the approval steps, then paired (open, disconnect) — with the agents shared there; and on
|
|
4
|
+
// a fleet that runs a Hub itself, its retention and browser-certificate cards. Each card stays its own lazy module, as
|
|
5
|
+
// it was under Access & security. Never over the public link: the member handlers are this computer's owner's only.
|
|
6
|
+
import { html, useEffect, useState } from "/assets/app-html.js";
|
|
7
|
+
import { register, t } from "/assets/app-i18n.js";
|
|
8
|
+
|
|
9
|
+
register("settingsHubSection", {
|
|
10
|
+
en: {
|
|
11
|
+
publicLink: "Hub settings are only on this fleet's own dashboard, not over the public link.",
|
|
12
|
+
relatedTitle: "Hub", relatedHint: "Connect this fleet to a team Hub and choose which agents to share.",
|
|
13
|
+
},
|
|
14
|
+
"zh-TW": {
|
|
15
|
+
publicLink: "Hub 設定只在這個 Fleet 自己的儀表板上提供,公開連結上沒有。",
|
|
16
|
+
relatedTitle: "Hub", relatedHint: "將這個 Fleet 連線至團隊 Hub,並選擇要分享的 Agent。",
|
|
17
|
+
},
|
|
18
|
+
});
|
|
19
|
+
export const hubSectionText = (key) => t(`settingsHubSection.${key}`);
|
|
20
|
+
|
|
21
|
+
/** A card from its own lazy module (it loads only when this section is drawn). */
|
|
22
|
+
function Lazy({ load, pick }) {
|
|
23
|
+
const [Card, setCard] = useState(null);
|
|
24
|
+
useEffect(() => { let live = true; load().then((m) => { if (live) setCard(() => pick(m)); }, () => {}); return () => { live = false; }; }, []);
|
|
25
|
+
return Card ? html`<${Card} />` : null;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export function HubSection({ overPublicLink, hubHost }) {
|
|
29
|
+
if (overPublicLink) return html`<section class="card s-group" id="hub-public-link"><p class="note">${hubSectionText("publicLink")}</p></section>`;
|
|
30
|
+
return html`<div class="s-hub-section">
|
|
31
|
+
<${Lazy} load=${() => import("./settings-hub-membership.js")} pick=${(m) => m.HubMembershipSettings} />
|
|
32
|
+
${hubHost ? html`<${Lazy} load=${() => import("./settings-hub-retention.js")} pick=${(m) => m.HubRetentionSettings} />
|
|
33
|
+
<${Lazy} load=${() => import("./settings-hub-browser-certificate.js")} pick=${(m) => m.HubBrowserCertificateSettings} />` : null}
|
|
34
|
+
</div>`;
|
|
35
|
+
}
|
package/dist/ui/settings-hub.js
CHANGED
|
@@ -17,6 +17,8 @@ const CONNECT_ERRORS = { address: "errAddress", code: "errCode", busy: "errBusy"
|
|
|
17
17
|
const HOLDS = new Set(["unknown_outcome", "expired", "unsaved", "refused", "revoked", "disconnected"]);
|
|
18
18
|
const PUBLISH_ERRORS = { conflict: "errConflict", unsaved: "errUnsaved", not_paired: "errNotPaired", not_enforceable: "agentNotShareable",
|
|
19
19
|
unknown_view: "agentNotShareable", limit: "errLimit", unavailable: "notAvailable" };
|
|
20
|
+
// The switcher may have cached hub-strings before this action existed. Its original Allow word is still available.
|
|
21
|
+
const allowOnHubLabel = () => { const label = hw("allowOnHub"); return label === "hub.allowOnHub" ? `${hw("allow")}…` : label; };
|
|
20
22
|
|
|
21
23
|
/** A fingerprint: its first 128 bits in groups people compare, the whole digest on request. */
|
|
22
24
|
function Fingerprint({ label, fp }) {
|
|
@@ -147,7 +149,7 @@ export function HubConnectCard() {
|
|
|
147
149
|
${client.stub ? html`<p class="note hub-preview" role="note">${hw("preview")}</p>` : null}
|
|
148
150
|
${body}
|
|
149
151
|
${msg ? html`<p class=${msg.error ? "err" : "note"} role=${msg.error ? "alert" : "status"}>${msg.text}</p>` : null}
|
|
150
|
-
${p && p.state === "paired" ? html`<${HubExposures} client=${client} />` : null}
|
|
152
|
+
${p && p.state === "paired" ? html`<${HubExposures} key=${`${p.binding}|${p.hub.hubId}|${p.hub.fingerprint?.digest}|${safeWebOrigin(p)}`} client=${client} pairing=${p} />` : null}
|
|
151
153
|
</section>`;
|
|
152
154
|
}
|
|
153
155
|
|
|
@@ -156,7 +158,7 @@ export function HubConnectCard() {
|
|
|
156
158
|
* itself (docs/design/hub-representative-agent.md): switching on sends AGENT_CHOICE for the owner's confirmation; a row
|
|
157
159
|
* shared under the older restricted mode says so and offers "Share again" (a new, confirmed revision).
|
|
158
160
|
*/
|
|
159
|
-
function HubExposures({ client }) {
|
|
161
|
+
function HubExposures({ client, pairing }) {
|
|
160
162
|
const [rows, setRows] = useState(null);
|
|
161
163
|
const [readError, setReadError] = useState(false);
|
|
162
164
|
const [busy, setBusy] = useState(null);
|
|
@@ -198,6 +200,8 @@ function HubExposures({ client }) {
|
|
|
198
200
|
: row.policy ? html`<small class="hub-exposure-why">${hw("policy", row.policy.dataView, row.policy.tools.join(", ") || "—")}</small>` : null}
|
|
199
201
|
${!row.enforceable && row.state !== "frozen" && guidanceFor(row.reason)
|
|
200
202
|
? html`<small class="hub-exposure-why hub-provider-guidance">${hw(guidanceFor(row.reason))}</small>` : null}
|
|
203
|
+
${row.state === "published" && !row.pending && /^[a-f0-9-]{36}$/.test(row.exposureId || "") && safeWebOrigin(pairing)
|
|
204
|
+
? html`<div class="field-row"><a class="btn btn-sm" href=${`${safeWebOrigin(pairing)}/ui/hub/exposures?agent=${encodeURIComponent(row.exposureId)}&grant=1`} target="_blank" rel="noopener noreferrer">${allowOnHubLabel()}</a></div>` : null}
|
|
201
205
|
</li>`)}</ul>` : null}
|
|
202
206
|
${msg ? html`<p class=${msg.error ? "err" : "note"} role=${msg.error ? "alert" : "status"}>${msg.text}</p>` : null}
|
|
203
207
|
</div>`;
|
|
@@ -16,6 +16,8 @@ register("settingsLayout", {
|
|
|
16
16
|
"lead_web-dashboard": "Manage fleet-wide dashboard features, branding and resource limits.",
|
|
17
17
|
lead_access: "Manage sign-in, web authority, guests and sharing.",
|
|
18
18
|
lead_advanced: "Inspect and edit fleet configuration, with effective values kept separate.",
|
|
19
|
+
lead_hub: "Connect this fleet to a team Hub, compare its fingerprint, and choose which agents to share there.",
|
|
20
|
+
lead_notifications: "Choose when account usage reminders are sent, and to whom.",
|
|
19
21
|
editor: "Configuration editor", effective: "Effective settings (read only)",
|
|
20
22
|
aiAccounts: "AI accounts and keys", aiAccountsHint: "Sign-ins and supported provider keys on the AgEnD host. Windows CLI status is shown under Runtime.",
|
|
21
23
|
classicDefaults: "ClassicBot defaults and access",
|
|
@@ -30,6 +32,8 @@ register("settingsLayout", {
|
|
|
30
32
|
"lead_web-dashboard": "管理整個 Fleet 的網頁功能、品牌與資源限制。",
|
|
31
33
|
lead_access: "管理登入、網頁授權、訪客與對外分享。",
|
|
32
34
|
lead_advanced: "檢視與編輯 Fleet 設定,並區分目前生效的唯讀內容。",
|
|
35
|
+
lead_hub: "將這個 Fleet 連線至團隊 Hub、比對指紋,並選擇要在那裡分享的 Agent。",
|
|
36
|
+
lead_notifications: "設定帳號用量提醒的時機與傳送對象。",
|
|
33
37
|
editor: "設定編輯器", effective: "生效設定(唯讀)",
|
|
34
38
|
aiAccounts: "AI 帳號與金鑰", aiAccountsHint: "管理 AgEnD 主機的登入與支援的供應商金鑰;Windows CLI 狀態請到 Runtime 查看。",
|
|
35
39
|
classicDefaults: "ClassicBot 預設行為與存取",
|
|
@@ -39,13 +43,13 @@ register("settingsLayout", {
|
|
|
39
43
|
register("settingsLayout", {
|
|
40
44
|
en: {
|
|
41
45
|
aiAccounts: "AI sign-ins and API keys", aiAccountsSummary: "Host CLI sign-ins and provider API keys, managed separately.",
|
|
42
|
-
aiHostScope: "Credentials on the AgEnD host", aiAccountsHint: "
|
|
46
|
+
aiHostScope: "Credentials on the AgEnD host and paired computers", aiAccountsHint: "Sign-ins are listed per computer: this AgEnD host, then each paired computer. Provider API keys belong to the host.", aiWindowsLink: "Manage Windows computers and their CLIs in Runtime",
|
|
43
47
|
apiKeysTitle: "Provider API keys", apiKeysHint: "API credentials for supported provider integrations.", apiKeysUnavailableState: "Not offered", apiKeysUnavailable: "Provider API key management is not offered in this session.",
|
|
44
48
|
apiNewPlaceholder: "Enter an API key to verify", apiReplacePlaceholder: "Enter a replacement API key",
|
|
45
49
|
},
|
|
46
50
|
"zh-TW": {
|
|
47
51
|
aiAccounts: "AI 登入與 API 金鑰", aiAccountsSummary: "分開管理主機 CLI 登入與供應商 API 金鑰。",
|
|
48
|
-
aiHostScope: "AgEnD
|
|
52
|
+
aiHostScope: "AgEnD 主機與已配對電腦上的憑證", aiAccountsHint: "登入依電腦列出:先是這台 AgEnD 主機,再來是每台已配對電腦。供應商 API 金鑰屬於主機。", aiWindowsLink: "前往 Runtime 管理 Windows 電腦與 CLI",
|
|
49
53
|
apiKeysTitle: "供應商 API 金鑰", apiKeysHint: "供支援的供應商整合功能使用的 API 憑證。", apiKeysUnavailableState: "目前未提供", apiKeysUnavailable: "此工作階段未提供供應商 API 金鑰管理。",
|
|
50
54
|
apiNewPlaceholder: "輸入要驗證的 API 金鑰", apiReplacePlaceholder: "輸入替換用的 API 金鑰",
|
|
51
55
|
},
|
|
@@ -17,7 +17,7 @@ register("settings", {
|
|
|
17
17
|
ntNotRun: "Not tested (an earlier step failed).",
|
|
18
18
|
ntTimeout: "The test took too long and was stopped. Test again; if it repeats, check this machine's network.",
|
|
19
19
|
ntCancelled: "Your sign-in ended, so nothing was started. Sign in again and test again.",
|
|
20
|
-
ntCleanup: "The test's connector could not be confirmed stopped.
|
|
20
|
+
ntCleanup: "The test's connector could not be confirmed stopped. Restart AgEnD (Restart now, or /restart in General) before testing or opening the link again.",
|
|
21
21
|
ntStep_values: "The domain, port and token",
|
|
22
22
|
ntStep_origin: "This machine answers on port {1}",
|
|
23
23
|
ntStep_tunnel: "The tunnel connects to Cloudflare",
|
|
@@ -60,7 +60,7 @@ register("settings", {
|
|
|
60
60
|
ntNotRun: "未測試(前面的步驟失敗)。",
|
|
61
61
|
ntTimeout: "測試太久,已經停止。請再測一次;如果一直這樣,請檢查這台主機所在的網路。",
|
|
62
62
|
ntCancelled: "你的登入已結束,所以沒有啟動任何東西。請重新登入後再測。",
|
|
63
|
-
ntCleanup: "
|
|
63
|
+
ntCleanup: "無法確認測試用的連接器已經停止。請先重新啟動 AgEnD(立即重新啟動,或在 General 傳 /restart),再測試或開啟連結。",
|
|
64
64
|
ntStep_values: "網域、port 與 token",
|
|
65
65
|
ntStep_origin: "這台主機在 port {1} 回應",
|
|
66
66
|
ntStep_tunnel: "tunnel 連上 Cloudflare",
|
|
@@ -209,7 +209,7 @@ export function OutsideCard() {
|
|
|
209
209
|
return html`<section class="card s-outside" id="outsideCard" ref=${card}><header class="s-auth-section-head"><div><h3>${to("title")}</h3><p id="outLead">${to("lead")}</p></div><span class=${`s-auth-state${s.enrolled ? " is-usable" : ""}`} id="outState">${to(s.enrolled ? "stateOn" : "stateOff")}</span></header>
|
|
210
210
|
<div class="chips s-out-apps" id="outApps" role="list" aria-label=${to("appsLabel")}><span class="tag" role="listitem">Google Authenticator</span><span class="tag" role="listitem">Microsoft Authenticator</span><span class="tag" role="listitem">${to("appOther")}</span></div>
|
|
211
211
|
${!here ? html`<p class="note" id="outHereOnly">${to("hereOnly")}</p>` : null}
|
|
212
|
-
<label class="check"><input id="outSwitch" type="checkbox" checked=${s.outside} disabled=${!here || busy || (!s.enrolled && !s.outside)}
|
|
212
|
+
<label class="check"><input id="outSwitch" class="s-ui-toggle" type="checkbox" role="switch" checked=${s.outside} disabled=${!here || busy || (!s.enrolled && !s.outside)}
|
|
213
213
|
onChange=${(e) => flip(e.target.checked)} /><span>${to("switch")}</span></label>
|
|
214
214
|
${!s.enrolled ? html`<p class="note" id="outNeedApp">${to("needApp")}</p>` : null}
|
|
215
215
|
${s.outside && open && link.url ? html`<p class="note" id="outOpenAt">${to("openAt", link.url)}${link.quick ? ` ${to("quick")}` : ""}</p>` : null}
|
|
@@ -80,10 +80,12 @@ export function QuotaNoticeSettings({ ctx }) {
|
|
|
80
80
|
const effective = { enabled: true, thresholds: [10], periods: ["weekly"], ...parsed.fleet,
|
|
81
81
|
...(selectedBackend ? parsed[`backend:${selectedBackend}`] : {}), ...(scope.startsWith("agent:") || scope.startsWith("classic:") ? parsed[scope] : {}) };
|
|
82
82
|
const update = k => e => setFields(f => ({ ...f, [fieldKey(scope, k)]: e.target.value }));
|
|
83
|
-
|
|
83
|
+
// alpha.6 feedback (#3): the Settings card (card s-group, as Shared agent settings: a title and its note, the fields in the
|
|
84
|
+
// grid), not a bare heading over full-width fields.
|
|
85
|
+
return html`<section class="card s-group" id="quota-notices"><div><h3>${text.heading}</h3><p class="note">${text.hint}</p><p class="note">${text.defaults}</p></div>
|
|
84
86
|
${!supported ? html`<p role="status">${text.old}</p>` : null}
|
|
85
|
-
${!invalid ? html`<p class="
|
|
86
|
-
<fieldset disabled=${!supported} class="s-quota-fields">
|
|
87
|
+
${!invalid ? html`<p class="note" data-quota-effective>${text.effective}: ${effective.enabled ? text.on : text.off} · ${effective.thresholds.map(v => `${v}%`).join(", ") || "—"} · ${effective.periods.join(", ") || "—"}</p>` : null}
|
|
88
|
+
<fieldset disabled=${!supported} class="s-quota-fields grid2">
|
|
87
89
|
<div class="field"><label for="qn-target">${text.target}</label><select id="qn-target" value=${form.target} onChange=${e => setFields(f => ({ ...f, target: e.target.value }))}>
|
|
88
90
|
<option value="general">${text.general}</option>${Object.entries(instances).filter(([n]) => n !== "general").map(([n, c]) => html`<option value=${n}>${c.display_name || n}</option>`)}
|
|
89
91
|
${form.target !== "general" && !Object.hasOwn(instances, form.target) ? html`<option value=${form.target}>${form.target}</option>` : null}
|
|
@@ -94,7 +96,7 @@ export function QuotaNoticeSettings({ ctx }) {
|
|
|
94
96
|
${Object.entries(classic).map(([n, c]) => html`<option value=${`classic:${n}`}>${text.classic} · ${c.name || c.instanceName || n}</option>`)}
|
|
95
97
|
</select></div>
|
|
96
98
|
<div class="field"><label for="qn-enabled">${text.enabled}</label><select id="qn-enabled" value=${value.enabled} onChange=${update("enabled")}><option value="">${text.inherit}</option><option value="on">${text.on}</option><option value="off">${text.off}</option></select></div>
|
|
97
|
-
<div class="field"><label for="qn-thresholds">${text.thresholds}</label><input id="qn-thresholds" value=${value.thresholds} onInput=${update("thresholds")} placeholder="10" /><p class="
|
|
98
|
-
<div class="field"><label for="qn-periods">${text.periods}</label><input id="qn-periods" value=${value.periods} onInput=${update("periods")} placeholder=${text.periodExample} /><p class="
|
|
99
|
-
</fieldset>${invalid ? html`<p class="feedback error" role="alert">${text.error}</p>` : null}<p class="
|
|
99
|
+
<div class="field"><label for="qn-thresholds">${text.thresholds}</label><input id="qn-thresholds" value=${value.thresholds} onInput=${update("thresholds")} placeholder="10" /><p class="note">${text.thresholdHint}</p></div>
|
|
100
|
+
<div class="field"><label for="qn-periods">${text.periods}</label><input id="qn-periods" value=${value.periods} onInput=${update("periods")} placeholder=${text.periodExample} /><p class="note">${text.periodHint}</p></div>
|
|
101
|
+
</fieldset>${invalid ? html`<p class="feedback error" role="alert">${text.error}</p>` : null}<p class="note">${text.sources}</p></section>`;
|
|
100
102
|
}
|
|
@@ -15,6 +15,9 @@ const L = (en, zh) => ({ en, "zh-TW": zh });
|
|
|
15
15
|
/** [id, section, target, labelKey | label, config key, words en, words zh] */
|
|
16
16
|
const ROWS = [
|
|
17
17
|
["general.location", "agent-defaults", "#general-location", null, null, ["general", "windows", "paired PC", "host", "location"], ["General", "Windows", "電腦", "主機", "執行位置"], L("Run General on", "General 執行位置")],
|
|
18
|
+
// alpha.6 feedback (#2): "hub" found nothing — Settings → Hub's cards. Connect to a Hub is drawn once membership is on.
|
|
19
|
+
["hub.membership", "hub", "#hubMemberEnabled", null, "hub_member.enabled", ["hub", "team hub", "membership", "connect", "join", "pair", "share agents"], ["Hub", "團隊 Hub", "成員", "連線", "加入", "配對", "分享"], L("Allow this fleet to connect to a Hub", "允許這個 Fleet 連線至 Hub")],
|
|
20
|
+
["hub.connect", "hub", "#hub-connect", null, null, ["hub", "connect to a hub", "pairing code", "hub address", "fingerprint", "pair", "unpair", "disconnect", "join"], ["Hub", "連線至 Hub", "配對碼", "Hub 位址", "指紋", "配對", "解除配對", "中斷連線", "加入"], L("Connect to a Hub", "連線至 Hub")],
|
|
18
21
|
["quota.notices", "notifications", "#quota-notices", null, "defaults.quota_notice", ["usage", "quota", "notifications", "remaining", "weekly"], ["用量", "額度", "提醒", "通知", "剩餘"], L("Quota notices", "用量提醒")],
|
|
19
22
|
// You · Preferences
|
|
20
23
|
["profile.name", "preferences", "#profile-name", "settings.profileTitle", null, ["name", "display name", "who agents see", "profile"], ["名字", "名稱", "顯示名稱", "個人資料"]],
|
|
@@ -142,7 +142,7 @@ register("settings", {
|
|
|
142
142
|
tokenShow: "Show the token", tokenHide: "Hide the token", tokenIsBot: "This is {0}.", tokenStatus: "Bot token",
|
|
143
143
|
tokenSet: "Token set", tokenSetAs: "Token set · {0}", tokenMissing: "Token missing", tokenReplace: "Replace",
|
|
144
144
|
tokenStoredAs: "The token is stored on this computer in ~/.agend/.env under this name — generated, and only needed if you manage .env yourself.",
|
|
145
|
-
tokenSavedRestart: "Token saved. This connection
|
|
145
|
+
tokenSavedRestart: "Token saved. This connection was added or changed since AgEnD started, so it starts with the new token when AgEnD restarts (see the restart notice at the top of the page).",
|
|
146
146
|
newBotTokenHint: "Paste the bot's token. It is checked with the platform, then stored on this computer — never in the browser.",
|
|
147
147
|
connectionIdOptional: "Connection id (optional)",
|
|
148
148
|
connConnectedAs: "Connected · {0}", connReconnecting: "Reconnecting…", connStarting: "Starting…", connFailed: "Could not connect",
|
|
@@ -286,7 +286,7 @@ register("settings", {
|
|
|
286
286
|
"sec_windows-cli": "Windows CLI",
|
|
287
287
|
sec_runtimes: "Runtime",
|
|
288
288
|
sec_chat: "Chat & connections", "sec_web-dashboard": "Web dashboard", sec_access: "Access & security",
|
|
289
|
-
sec_notifications: "Notifications", sec_advanced: "Advanced", sec_look: "Look", grp_you: "You", grp_fleet: "Fleet",
|
|
289
|
+
sec_notifications: "Notifications", sec_hub: "Hub", sec_advanced: "Advanced", sec_look: "Look", grp_you: "You", grp_fleet: "Fleet",
|
|
290
290
|
classicDefaultsTitle: "ClassicBot defaults", publicLinkTitle: "Public link & fixed address", webDashboardTitle: "Dashboard features", webSettingsLabel: "Web settings",
|
|
291
291
|
stRunning: "Running",
|
|
292
292
|
stPaused: "Paused",
|
|
@@ -507,7 +507,7 @@ register("settings", {
|
|
|
507
507
|
cssError_owner_css_read_only: "This sign-in can view but not change custom CSS.",
|
|
508
508
|
cssError_owner_css_needs_a_signed_in_person: "Sign in in the browser to change custom CSS.",
|
|
509
509
|
cssError_other: "Not saved ({0}).",
|
|
510
|
-
webLead: "How the web dashboard behaves. A change that loosens access (longer sessions, the browser terminal back on or for longer, the public link) waits for a fleet admin to confirm it in
|
|
510
|
+
webLead: "How the web dashboard behaves. A change that loosens access (longer sessions, the browser terminal back on or for longer, the public link) waits for a fleet admin to confirm it: in General in Telegram or Discord, or here on the dashboard where its card offers that; one that tightens it applies at once.",
|
|
511
511
|
webPublicRefused: "Web settings can't be changed over a public link. Open the dashboard at its own address to change them.",
|
|
512
512
|
webSessionTitle: "Sign-in sessions",
|
|
513
513
|
webSessionHint: "For sign-ins at the dashboard's own address (this computer, the LAN, a tailnet). Over a public link (a temporary one or your permanent link), a session lasts at most 8 h, ends after 30 min idle and never outlives the link; an admin's also never lasts longer than these settings (a guest's follows the guest settings). Shortening ends the sessions it now outlives; lengthening applies to new sign-ins and to an existing one's idle time on its next use. Empty = the default.",
|
|
@@ -795,7 +795,7 @@ register("settings", {
|
|
|
795
795
|
tokenShow: "顯示 token", tokenHide: "隱藏 token", tokenIsBot: "這是 {0}。", tokenStatus: "Bot token",
|
|
796
796
|
tokenSet: "已設定 token", tokenSetAs: "已設定 token · {0}", tokenMissing: "缺少 token", tokenReplace: "更換",
|
|
797
797
|
tokenStoredAs: "token 存在這台電腦的 ~/.agend/.env,用這個名稱——自動產生,只有自行管理 .env 時才需要。",
|
|
798
|
-
tokenSavedRestart: "已儲存 token
|
|
798
|
+
tokenSavedRestart: "已儲存 token。這個連線是在 AgEnD 啟動後才新增或修改的,AgEnD 重新啟動時會用新的 token 啟動(見頁面上方的重新啟動提示)。",
|
|
799
799
|
newBotTokenHint: "貼上 bot 的 token。會先向平台確認,再存到這台電腦——絕不存在瀏覽器。",
|
|
800
800
|
connectionIdOptional: "連線 id(選填)",
|
|
801
801
|
connConnectedAs: "已連線 · {0}", connReconnecting: "重新連線中…", connStarting: "啟動中…", connFailed: "無法連線",
|
|
@@ -939,7 +939,7 @@ register("settings", {
|
|
|
939
939
|
"sec_windows-cli": "Windows CLI",
|
|
940
940
|
sec_runtimes: "Runtime",
|
|
941
941
|
sec_chat: "聊天與連線", "sec_web-dashboard": "網頁儀表板", sec_access: "存取與安全",
|
|
942
|
-
sec_notifications: "通知", sec_advanced: "進階", sec_look: "外觀", grp_you: "你自己", grp_fleet: "整個 Fleet",
|
|
942
|
+
sec_notifications: "通知", sec_hub: "Hub", sec_advanced: "進階", sec_look: "外觀", grp_you: "你自己", grp_fleet: "整個 Fleet",
|
|
943
943
|
classicDefaultsTitle: "ClassicBot 預設值", publicLinkTitle: "公開連結與固定網址", webDashboardTitle: "儀表板功能", webSettingsLabel: "網頁設定",
|
|
944
944
|
stRunning: "執行中",
|
|
945
945
|
stPaused: "已暫停",
|
|
@@ -1159,7 +1159,7 @@ register("settings", {
|
|
|
1159
1159
|
cssError_owner_css_read_only: "這個登入只能檢視、不能變更自訂 CSS。",
|
|
1160
1160
|
cssError_owner_css_needs_a_signed_in_person: "請在瀏覽器登入後再變更自訂 CSS。",
|
|
1161
1161
|
cssError_other: "未儲存({0})。",
|
|
1162
|
-
webLead: "網頁儀表板的行為。放寬存取的變更(延長 session、重新開啟或延長瀏覽器終端機、公開連結)需要 fleet admin
|
|
1162
|
+
webLead: "網頁儀表板的行為。放寬存取的變更(延長 session、重新開啟或延長瀏覽器終端機、公開連結)需要 fleet admin 確認:在 Telegram 或 Discord 的 General,或在儀表板上卡片提供確認的地方;收緊的變更會立即套用。",
|
|
1163
1163
|
webPublicRefused: "無法透過公開連結變更網頁設定。請從儀表板本身的網址開啟後再變更。",
|
|
1164
1164
|
webSessionTitle: "登入 session",
|
|
1165
1165
|
webSessionHint: "適用於從儀表板本身網址登入的 session(本機、區域網路、tailnet)。透過公開連結(臨時連結或你的固定網域)的 session 最長 8 小時、閒置 30 分鐘就結束,也不會超過連結本身;管理者的 session 也不會超過這裡的設定(訪客依訪客設定)。縮短會讓已超過新限制的 session 結束;延長會套用到新的登入,以及既有 session 下次使用時的閒置時間。留空 = 預設值。",
|