perf: avoid redundant tab metadata writes

Merged
TE
2mo ago
+47-30

Bonsplit tab updates now write each metadata field only when its value changes, including presence through the current tab item. This keeps a title update paired with an unchanged custom-title flag from invalidating readers of the tab bar's per-tab projection.

Validation: added an observation regression covering the fields read by TabBarView.body and cmux's title plus unchanged hasCustomTitle update shape.

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.


Summary by cubic

Avoids redundant tab metadata writes so observers tracking tab fields are no longer invalidated by unchanged values.

  • updateTab now writes each metadata field only when its value changes, including presence via the current tab item.
  • Adds a regression test verifying a title update with an unchanged custom-title flag does not invalidate the tab bar's per-tab projection.