From 4f1242ca873df8c167530475fcbd80808dc94a7d Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Tue, 17 Nov 2026 11:53:41 +0100 Subject: assistant: output folder from the daemon's out_dir The settings page edits out_dir in the daemon's config.toml, with the daemon's resolved default as placeholder; the canvas takes the folder from hello instead of asking xdg-user-dir itself. Co-Authored-By: Claude Opus 5.5 --- desktop/modules/assistant/AssistantPage.qml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'desktop/modules/assistant/AssistantPage.qml') diff --git a/desktop/modules/assistant/AssistantPage.qml b/desktop/modules/assistant/AssistantPage.qml index d74e66b..0875a5d 100644 --- a/desktop/modules/assistant/AssistantPage.qml +++ b/desktop/modules/assistant/AssistantPage.qml @@ -359,6 +359,25 @@ Column { } } + Labelled { + objectName: "key:out_dir" + label: "Output folder" + Field { + anchors.fill: parent + value: page.v.out_dir ?? "" + placeholder: page.d.out_dir ?? "" + bad: page.asst.invalid["key:out_dir"] ?? false + // Where the canvas and tools write files; the daemon refuses + // anything but an absolute or ~ path, so a bad one never saves. + onEdited: t => { + const s = t.trim(); + const ok = s === "" || s.startsWith("/") || s === "~" || s.startsWith("~/"); + page.asst.markInvalid("key:out_dir", !ok); + if (ok) page.asst.setKey("out_dir", s ? page.asst.quote(s) : null); + } + } + } + // The prompt is long and multi-line, so it gets its own box and an // explicit Save rather than Enter. Column { -- cgit v1.2.3