fix(ui): the open workflow is in the URL, so chat knows which one you mean

This commit is contained in:
sam committed 2026-11-13 13:26:05 +11:00
1 parent f5be0d60dd
commit 6b7f6f2731
2 files changed
+10 -1

No files matched your search

+3 -1
View File
@@ -663,7 +663,9 @@ export const pageTag = computed(() => {
const label =
route.name === "task-detail"
? `Task #${route.params.id}`
: typeof route.meta.label === "string"
: route.name === "workflows" && typeof route.query.workflow === "string"
? `Workflow ${route.query.workflow}`
: typeof route.meta.label === "string"
? route.meta.label
: page;
return { page, label };
+7
View File
@@ -110,6 +110,13 @@ watch(
},
{ immediate: true },
);
// The selection goes back into ?workflow= so the URL names it: a reload keeps
// it, and the chat's page context tells Archie which workflow is open.
watch(selected, (id) => {
if (!id || route.query.workflow === id) return;
applied = id;
void router.replace({ query: { ...route.query, workflow: id } });
});
// Whether this workflow is still the one archie ships: "Edited" when it has
// been changed, "Custom" when archie ships nothing by that name.
const provenance = computed(() => {