From f9a681fce7cbb9e3868fa78db62ec97b386bb98e Mon Sep 17 00:00:00 2001 From: Jinjing <6427696+AmethystLiang@users.noreply.github.com> Date: Mon, 8 Jun 2026 01:10:29 -0700 Subject: [PATCH] Constrain create-workspace dialog height for long orca.yaml scripts (#4873) - Limit command preview blocks to 12rem (max-h-48) with scroll - Cap dialog body to viewport height minus 2rem - Add sr-only accessible description to the dialog --- .../src/components/NewWorkspaceComposerCard.tsx | 5 +++-- .../src/components/NewWorkspaceComposerModal.tsx | 14 ++++++++++++-- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/src/renderer/src/components/NewWorkspaceComposerCard.tsx b/src/renderer/src/components/NewWorkspaceComposerCard.tsx index 2dabc2b803c..a3d8ce543b8 100644 --- a/src/renderer/src/components/NewWorkspaceComposerCard.tsx +++ b/src/renderer/src/components/NewWorkspaceComposerCard.tsx @@ -115,7 +115,8 @@ function SetupCommandPreview({
orca.yaml
{headerAction} -
+        {/* Why: long orca.yaml scripts must not grow the create dialog past the viewport. */}
+        
           {setupConfig.command}
         
@@ -130,7 +131,7 @@ function SetupCommandPreview({ {headerAction} -
+      
         {setupConfig.command}
       
diff --git a/src/renderer/src/components/NewWorkspaceComposerModal.tsx b/src/renderer/src/components/NewWorkspaceComposerModal.tsx index 4e41117f6d1..152cecad3ca 100644 --- a/src/renderer/src/components/NewWorkspaceComposerModal.tsx +++ b/src/renderer/src/components/NewWorkspaceComposerModal.tsx @@ -1,6 +1,12 @@ import React, { useCallback, useEffect, useMemo, useState } from 'react' import { useAppStore } from '@/store' -import { Dialog, DialogContent, DialogHeader, DialogTitle } from '@/components/ui/dialog' +import { + Dialog, + DialogContent, + DialogDescription, + DialogHeader, + DialogTitle +} from '@/components/ui/dialog' import NewWorkspaceComposerCard from '@/components/NewWorkspaceComposerCard' import AgentSettingsDialog from '@/components/agent/AgentSettingsDialog' import { useComposerState } from '@/hooks/useComposerState' @@ -74,7 +80,7 @@ function ComposerModalBody({ return ( { // Why: Radix's FocusScope fires this once the dialog has mounted. // preventDefault stops it from focusing whatever first-tabbable it @@ -221,9 +227,13 @@ function QuickTabBody({ <> {primaryActionLabel} + + Choose the project, workspace name, and agent before creating the workspace. +