File tree Expand file tree Collapse file tree
apps/mobile/src/features/threads Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1104,20 +1104,22 @@ export function NewTaskDraftScreen(props: {
11041104 />
11051105 ) }
11061106 label = { workspaceLabel }
1107- maxWidth = { flow . workspaceMode === "local" ? 220 : 148 }
1107+ maxWidth = "100%"
11081108 onPress = { ( ) => flow . setWorkspaceMode ( flow . workspaceMode === "local" ? "worktree" : "local" ) }
11091109 showChevron = { false }
11101110 />
11111111
1112- < ComposerInlineControl
1113- accessibilityLabel = { `${ flow . workspaceMode === "worktree" ? "Base branch" : "Branch" } : ${ selectedBranchLabel } ` }
1114- chevronDirection = "right"
1115- disabled = { isComposerInteractionLocked || ! flow . isGitRepo }
1116- icon = "arrow.triangle.branch"
1117- label = { showBranchLoading ? "Loading branches…" : selectedBranchLabel }
1118- maxWidth = { 190 }
1119- onPress = { ( ) => openContextPicker ( "NewTaskBranch" ) }
1120- />
1112+ < View className = "min-w-0 shrink" >
1113+ < ComposerInlineControl
1114+ accessibilityLabel = { `${ flow . workspaceMode === "worktree" ? "Base branch" : "Branch" } : ${ selectedBranchLabel } ` }
1115+ chevronDirection = "right"
1116+ disabled = { isComposerInteractionLocked || ! flow . isGitRepo }
1117+ icon = "arrow.triangle.branch"
1118+ label = { showBranchLoading ? "Loading branches…" : selectedBranchLabel }
1119+ maxWidth = "100%"
1120+ onPress = { ( ) => openContextPicker ( "NewTaskBranch" ) }
1121+ />
1122+ </ View >
11211123 </ View >
11221124 ) ;
11231125
@@ -1173,7 +1175,7 @@ export function NewTaskDraftScreen(props: {
11731175 draftMode = { {
11741176 content : heroViewport ,
11751177 controls : (
1176- < View className = "px-3 pb-1" >
1178+ < View className = "pb-1" >
11771179 { projectClone && projectClone . phase !== "done" && selectedProject ? (
11781180 < View className = "px-1 pb-2" >
11791181 < ProjectCloneBanner
Original file line number Diff line number Diff line change @@ -233,6 +233,7 @@ export interface ThreadComposerProps {
233233 readonly canOperateThread : boolean ;
234234 readonly placeholder : string ;
235235 readonly contentMaxWidth ?: number ;
236+ readonly draftControls ?: ReactNode ;
236237 readonly bottomInset ?: number ;
237238 readonly connectionState : RemoteClientConnectionState ;
238239 readonly environmentLabel : string | null ;
@@ -891,6 +892,7 @@ export const ThreadComposer = function ThreadComposer(props: ThreadComposerProps
891892 className = "relative w-full self-center"
892893 style = { { maxWidth : props . contentMaxWidth } }
893894 >
895+ { props . draftControls }
894896 { ! isSubmissionLocked &&
895897 composerMenu . trigger &&
896898 ( composerMenu . items . length > 0 || composerMenu . trigger . kind === "pull-request" ) ? (
Original file line number Diff line number Diff line change @@ -1660,7 +1660,6 @@ export const ThreadDetailScreen = function ThreadDetailScreen(props: ThreadDetai
16601660 </ View >
16611661 ) : (
16621662 < >
1663- { props . draftMode ?. controls }
16641663 < ThreadComposer
16651664 isDraft = { Boolean ( props . draftMode ) }
16661665 canOperateThread = { props . canOperateThread }
@@ -1674,6 +1673,7 @@ export const ThreadDetailScreen = function ThreadDetailScreen(props: ThreadDetai
16741673 : "Ask the repo agent, or run a command…"
16751674 }
16761675 contentMaxWidth = { contentMaxWidth }
1676+ draftControls = { props . draftMode ?. controls }
16771677 connectionState = { props . connectionStateLabel }
16781678 environmentLabel = { props . environmentLabel }
16791679 selectedThread = { props . selectedThread }
You can’t perform that action at this time.
0 commit comments