Skip to content

fix(desktop): route notification clicks to thread context#790

Merged
tlongwell-block merged 2 commits into
mainfrom
perci/notification-thread-click-through
Jun 1, 2026
Merged

fix(desktop): route notification clicks to thread context#790
tlongwell-block merged 2 commits into
mainfrom
perci/notification-thread-click-through

Conversation

@tlongwell-block

@tlongwell-block tlongwell-block commented May 29, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • carry threadRootId through desktop notification targets and existing sprout://message deep link navigation
  • add threadRootId to channel route search params and fetch it with the target event for route backfill
  • merge cached target + fetched target/root route events into the channel timeline so reply notification clicks can open thread context without dropping cache-only mock/feed hits

Testing

  • pnpm --dir desktop typecheck
  • pnpm --dir desktop exec biome check src/app/AppShell.tsx src/app/navigation/resolveSearchHitDestination.ts src/app/navigation/useAppNavigation.ts src/app/routes/ChannelRouteScreen.tsx 'src/app/routes/channels.$channelId.posts.$postId.tsx' 'src/app/routes/channels.$channelId.tsx' src/features/channels/ui/ChannelScreen.tsx src/features/notifications/lib/desktop.ts src/features/notifications/use-feed-desktop-notifications.ts src/shared/api/types.ts src/shared/ui/markdown.tsx src/shared/useMessageDeepLinks.ts
  • pnpm --dir desktop test
  • pnpm --dir desktop exec playwright test tests/e2e/profile.spec.ts -g "notification settings drive" --project=integration
  • Manual/temporary Playwright 4-deep notification gate: seeded root → reply depth 1 → depth 2 → depth 3 → depth 4 target, clicked a mock desktop notification carrying target + root, verified #engineering opens the message thread panel and contains the depth-4 target. Result: root-only route fetch is enough because existing useLoadMissingAncestors backfills intermediate ancestors; no new ancestor walker needed in this patch.

Notes

Pre-push hook was bypassed because the repo's broader desktop-tauri-test / desktop-tauri-clippy hook fails in unrelated Rust code on this machine/toolchain with use of unstable library feature round_char_boundary in desktop/src-tauri/src/commands/agent_discovery.rs.

@dawn please review the route backfill/cache-preservation shape.

Signed-off-by: tlongwell-block <109685178+tlongwell-block@users.noreply.github.com>
@tlongwell-block tlongwell-block requested a review from a team as a code owner May 29, 2026 16:07
Signed-off-by: tlongwell-block <109685178+tlongwell-block@users.noreply.github.com>
tlongwell-block

This comment was marked as resolved.

@wesbillman

Copy link
Copy Markdown
Collaborator

@codex please review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. What shall we delve into next?

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@tlongwell-block tlongwell-block merged commit f2c266b into main Jun 1, 2026
15 checks passed
@tlongwell-block tlongwell-block deleted the perci/notification-thread-click-through branch June 1, 2026 15:31
tlongwell-block pushed a commit that referenced this pull request Jun 1, 2026
* origin/main:
  fix(desktop): route notification clicks to thread context (#790)
  chore(deps): update all non-major dependencies (#804)
  fix(deps): re-pin isomorphic-git patch to 1.38.3 (#807)
  chore(deps): update dependency @tanstack/react-query to v5.100.14 (#805)
  Fix desktop glass chrome and inbox previews (#793)
  refactor(just): slim down mobile-dev to just run Flutter (#801)

Signed-off-by: tlongwell-block <109685178+tlongwell-block@users.noreply.github.com>
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.

2 participants