Skip to content

Reduce session action render cost#5900

Merged
ComputelessComputer merged 1 commit into
mainfrom
fix/reduce-session-action-render-cost
Jul 4, 2026
Merged

Reduce session action render cost#5900
ComputelessComputer merged 1 commit into
mainfrom
fix/reduce-session-action-render-cost

Conversation

@ComputelessComputer

@ComputelessComputer ComputelessComputer commented Jul 4, 2026

Copy link
Copy Markdown
Collaborator

Reuse derived session view state in floating actions and avoid broad content checks in the overflow menu upload gate.


Note

Low Risk
Refactor of visibility logic with existing tests; behavior should match prior FAB/overflow rules if currentView stays in sync with the editor.

Overview
Reduces session UI render work by passing the already-derived currentView from the session shell into FloatingActionButton instead of re-deriving the editor tab inside the FAB (via useCurrentNoteTab).

The FAB now hoists Tinybase/AI subscriptions once and drives listen/chat/summary/transcript visibility through pure helpers (shouldShowChatFab, getGenerateSummaryNoteId, getTranscriptFloatingAction) that take currentView plus fetched state.

The overflow menu replaces the broad useCurrentNoteHasContent check with useUploadCurrentViewHasContent, which only reads raw_md, enhanced content, or transcript presence for the active view when deciding whether upload actions appear.

Tests add a renderFloatingActionButton helper with an explicit currentView prop and mock store cells for overflow upload gating.

Reviewed by Cursor Bugbot for commit 0838e9e. Bugbot is set up for automated code reviews on this repo. Configure here.

@netlify

netlify Bot commented Jul 4, 2026

Copy link
Copy Markdown

Deploy Preview for old-char ready!

Name Link
🔨 Latest commit 625568f
🔍 Latest deploy log https://app.netlify.com/projects/old-char/deploys/6a488f285d06e10008adffc9
😎 Deploy Preview https://deploy-preview-5900--old-char.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 4ec39ec. Configure here.

Comment thread apps/desktop/src/session/index.tsx Outdated
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch 5 times, most recently from 40fee69 to 625568f Compare July 4, 2026 04:42
@ComputelessComputer ComputelessComputer changed the base branch from main to fix/unmount-sidebar-timeline-on-collapse July 4, 2026 04:42
@ComputelessComputer ComputelessComputer force-pushed the fix/unmount-sidebar-timeline-on-collapse branch from 808f09c to 4199771 Compare July 4, 2026 05:06
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch from 625568f to e7a2eb1 Compare July 4, 2026 05:06
@ComputelessComputer ComputelessComputer force-pushed the fix/unmount-sidebar-timeline-on-collapse branch from 4199771 to 1bd8cf9 Compare July 4, 2026 05:34
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch from e7a2eb1 to 7a36050 Compare July 4, 2026 05:34
@ComputelessComputer ComputelessComputer force-pushed the fix/unmount-sidebar-timeline-on-collapse branch from 1bd8cf9 to d94aafc Compare July 4, 2026 05:57
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch from 7a36050 to 7bfdd35 Compare July 4, 2026 05:57
@ComputelessComputer ComputelessComputer force-pushed the fix/unmount-sidebar-timeline-on-collapse branch from d94aafc to 722219d Compare July 4, 2026 06:16
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch from 7bfdd35 to 96364af Compare July 4, 2026 06:16
@ComputelessComputer ComputelessComputer force-pushed the fix/unmount-sidebar-timeline-on-collapse branch from 722219d to e8ecfa8 Compare July 4, 2026 06:35
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch from 96364af to fb04600 Compare July 4, 2026 06:35
@ComputelessComputer ComputelessComputer force-pushed the fix/unmount-sidebar-timeline-on-collapse branch from e8ecfa8 to 35e25ae Compare July 4, 2026 06:39
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch from fb04600 to fc6e88a Compare July 4, 2026 06:39
@ComputelessComputer ComputelessComputer force-pushed the fix/unmount-sidebar-timeline-on-collapse branch from 35e25ae to 8b8a826 Compare July 4, 2026 06:42
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch from fc6e88a to a561f6c Compare July 4, 2026 06:42
Reuse derived session view state in floating actions and avoid broad content checks in the overflow menu upload gate.
@ComputelessComputer ComputelessComputer force-pushed the fix/reduce-session-action-render-cost branch from a561f6c to 0838e9e Compare July 4, 2026 06:43
@ComputelessComputer ComputelessComputer changed the base branch from fix/unmount-sidebar-timeline-on-collapse to main July 4, 2026 06:43
@ComputelessComputer ComputelessComputer merged commit 29d2a1b into main Jul 4, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant