Skip to content

feat(desktop): make window title reflect currently selected project a…#31425

Open
OnkelTem wants to merge 1 commit into
anomalyco:devfrom
OnkelTem:feature/reactive-titles
Open

feat(desktop): make window title reflect currently selected project a…#31425
OnkelTem wants to merge 1 commit into
anomalyco:devfrom
OnkelTem:feature/reactive-titles

Conversation

@OnkelTem

@OnkelTem OnkelTem commented Jun 8, 2026

Copy link
Copy Markdown

Issue for this PR

Closes #31423

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

The browser window title was static ("OpenCode") regardless of which project or session was active, making it hard to identify tabs when multiple OpenCode windows are open.

Сhanges

Added a reactive createEffect in the layout component that updates document.title based on the current project and session.

The title now shows a single-letter initial, optional session name, and project name (e.g. M|Refactor store - MyProject).

Small refactor: As I also needed the first() function from project-avatar-v2.tsx/avatar-v2.tsx (dups?), I extracted it from those and placed into ./utils/* and exported.

How did you verify your code works?

Tested in web ui.

Screenshots / recordings

https://www.youtube.com/watch?v=TFx2Pl_9Nv4

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@OnkelTem OnkelTem force-pushed the feature/reactive-titles branch from f83281f to 84520ae Compare June 9, 2026 10:47
@OnkelTem OnkelTem force-pushed the feature/reactive-titles branch from 84520ae to 1b61c98 Compare June 9, 2026 11:55
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.

[FEATURE]: make window title show the currently selected session + project

1 participant