Skip to content

Custom sidebar: expose workspace emoji in data context - #20828

Merged
austinywang merged 2 commits into
mainfrom
fix/18988-sidebar-context
Oct 15, 2026
Merged

austinywang merged 2 commits into
mainfrom
fix/18988-sidebar-context

Conversation

@austinywang

@austinywang austinywang commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Custom JavaScript sidebars can already write the system clipboard through the gesture-gated clipboard.write(text) API from #19333, but their workspace context still has no separate emoji value. This adds an optional workspaces[i].emoji field derived from the display title's leading emoji grapheme, while preserving the full title value for existing sidebars.

The value travels through the typed workspace snapshot, is omitted when no leading emoji is present, and is covered by projection tests and the custom-sidebar contract documentation.

Closes #18988

Verification

  • python3 scripts/localize-changes (passed; no localization keys changed)
  • python3 scripts/localization_catalog.py check (passed)
  • python3 scripts/verify-local.py --only test-wiring (passed)
  • Swift package tests and syntax parsing were not run locally because this checkout has no swiftc/Swift toolchain; CI should execute CustomSidebarDataContextBuilderTests.

Changelog

Added

  • Expose a leading workspace emoji in custom sidebar workspace data.

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


Summary by cubic

Adds an optional workspaces[i].emoji field to the custom sidebar data context, derived from the leading emoji grapheme of the workspace display title. Sidebars using the full title value are unaffected, and the field is omitted when no leading emoji exists. Closes #18988.

New Features

  • Derives the emoji from the first grapheme of the display title and omits it when the title doesn't start with an emoji-presentation character.
  • Updates CustomSidebarWorkspaceSnapshot with the optional emoji property and documents the new field in docs/custom-sidebars.md.

Written for commit c72fdff. Summary will update on new commits.

View guided diff Turn on auto-fix

@coderabbitai

coderabbitai Bot commented Oct 15, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 14 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 10 included reviews currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Repository: manaflow-ai/cmux/.coderabbit.yaml
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 960a239f-b655-46ac-8f29-7c42e5b02414
📥 Commits

Reviewing files that changed from the base of the PR and between 9d01f95 and c72fdff.

📒 Files selected for processing: 5
  • Packages/macOS/CmuxSidebar/Sources/CmuxSidebar/Layout/CustomSidebarDataContextBuilder.swift
  • Packages/macOS/CmuxSidebar/Sources/CmuxSidebar/Layout/CustomSidebarWorkspaceSnapshot.swift
  • Packages/macOS/CmuxSidebar/Tests/CmuxSidebarTests/CustomSidebarDataContextBuilderTests.swift
  • Sources/Workspace+CustomSidebarSnapshot.swift
  • docs/custom-sidebars.md
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@github-actions

Copy link
Copy Markdown
Contributor

Dogfood tours of c72fdff9

sidebar-and-chrome-tour at c72fdff9: not run

skipped: CI built this head on a runner pool whose products the UI test Macs cannot load, and media never compiles one; gh workflow run pr-media.yml -f pr=<n> -f allow_compile=true does

Tours are picked by the paths globs in dogfood/scenarios/*.json; a Dogfood-tours: a, b line in the description picks them instead (none turns this off). Look at every frame before merging: a green tour only means no step failed.

@austinywang

Copy link
Copy Markdown
Contributor Author

Closeout verification update:\n\n- The PR head matches the verified local and remote branch head.\n- The PR is open, non-draft, mergeable, and clean.\n- Required checks are green or intentionally skipped.\n- No unresolved review threads remain.\n\nThis PR is ready for review. No merge was performed.

@austinywang
austinywang merged commit ec21dd9 into main Oct 15, 2026
75 checks passed
@austinywang
austinywang deleted the fix/18988-sidebar-context branch October 15, 2026 23:50
@github-actions

Copy link
Copy Markdown
Contributor

Merge receipt for c72fdff9fa: every check was green at merge (20 verified; 21 skipped by policy). Full suite runs on main after merge.

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.

Custom sidebar: expose clipboard write (Copy Workspace ID) + workspace emoji in data context

1 participant