GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(web): New worktree sends no longer wait on a layout command read … · patroza/t3code@60375a5

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • apps/web/src/components/chat
    • useComposerSend.ts
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎apps/web/src/components/chat/useComposerSend.ts‎

Copy file name to clipboardExpand all lines: apps/web/src/components/chat/useComposerSend.ts
+12Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1038,12 +1038,24 @@ export function useComposerSend(input: ComposerSendInput) {
10381038
.getState()
10391039
.getComposerDraft(composerDraftTarget);
10401040
sendInFlightRef.current = true;
1041+
// The commands are read as they are now, which takes a round trip, so the send shows as sending.
1042+
const showsWait = isCurrentRouteThread();
1043+
if (showsWait) {
1044+
beginLocalDispatch({
1045+
preparingWorktree: true,
1046+
submissionIntent:
1047+
submissionIntent === "background" && !isLocalDraftThread
1048+
? "foreground"
1049+
: submissionIntent,
1050+
});
1051+
}
10411052
const layoutApproval = await ensureWorktreeLayoutApproved({
10421053
environmentId,
10431054
projectId: activeProject.id,
10441055
projectTitle: activeProject.title,
10451056
}).finally(() => {
10461057
sendInFlightRef.current = false;
1058+
if (showsWait && isCurrentRouteThread()) resetLocalDispatch();
10471059
});
10481060
if (layoutApproval.status === "cancelled") return;
10491061
if (layoutApproval.status === "blocked") {

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.