From 5909cb601ed3792255cab087ccde8d640f6a7482 Mon Sep 17 00:00:00 2001 From: matevip Date: Fri, 8 May 2026 15:09:37 +0800 Subject: [PATCH] fix(ui/workflows): publish dialog auto-closes on compile failure --- mateclaw-ui/src/views/Workflows.vue | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/mateclaw-ui/src/views/Workflows.vue b/mateclaw-ui/src/views/Workflows.vue index 046505f2..16915d91 100644 --- a/mateclaw-ui/src/views/Workflows.vue +++ b/mateclaw-ui/src/views/Workflows.vue @@ -748,6 +748,15 @@ async function onPublishSubmit(payload: { note: string }) { await reload() } catch (e) { handleCompileError(e) + // Close the publish dialog on failure so the operator sees the + // errors-panel + Monaco markers underneath instead of staring at a + // dialog that just twitched. Also surface a toast with the error + // count so the redirect to the editor is obvious — the panel is + // below the fold on smaller viewports. + publishDialogOpen.value = false + if (compileErrors.value.length) { + ElMessage.error(t('workflows.status.compileFailed', { count: compileErrors.value.length })) + } } finally { busy.value = false }