Visual Studio Code, rebuilt in Rust
Rust
fix(statusbar): extension entry icons follow the label color on hover
rokarturecea3adcaf2d
diff --git a/README.md b/README.mdindex 357a7a45b07..e18e37a8bee 100644--- a/README.md+++ b/README.md@@ -11,8 +11,8 @@ Coverage of VS Code 1.147.0, from [port/ledger.md](port/ledger.md) (584 rows). V```mermaidpie showData- "verified" : 418- "ported" : 12+ "verified" : 417+ "ported" : 13"removed" : 126"n/a" : 28```@@ -23,7 +23,7 @@ pie showData| workbench contribution | 66 | 2 | 30 | 3 | `███████████████████░ 97%` || built-in extension | 88 | 1 | 6 | 0 | `████████████████████ 99%` || MainThread* shape (Rust side) | 58 | 1 | 30 | 0 | `████████████████████ 98%` |-| workbench service | 60 | 5 | 23 | 7 | `██████████████████░░ 92%` |+| workbench service | 59 | 6 | 23 | 7 | `██████████████████░░ 91%` || src/vs/editor/contrib | 54 | 0 | 2 | 1 | `████████████████████ 100%` || workbench part | 10 | 1 | 2 | 0 | `██████████████████░░ 91%` || extension host seam | 7 | 0 | 0 | 0 | `████████████████████ 100%` |@@ -31,7 +31,7 @@ pie showData| src/vs/editor | 0 | 2 | 1 | 1 | `░░░░░░░░░░░░░░░░░░░░ 0%` || src/vs/base | 0 | 0 | 2 | 3 | `████████████████████ 100%` || port feature | 1 | 0 | 0 | 0 | `████████████████████ 100%` |-| **all** | **418** | **12** | **126** | **28** | `███████████████████░ 97%` |+| **all** | **417** | **13** | **126** | **28** | `███████████████████░ 97%` |<!-- coverage:end -->`removed` are parts left out by decision: AI features, Microsoft services, telemetry, remote and tunnels ([port/notes.md](port/notes.md)). `n/a` are upstream test infrastructure and the Electron process, IPC and DOM layers the native architecture replaces.diff --git a/native/crates/app/src/workbench/hover/tests.rs b/native/crates/app/src/workbench/hover/tests.rsindex ab0920832ed..eb080a0c61b 100644--- a/native/crates/app/src/workbench/hover/tests.rs+++ b/native/crates/app/src/workbench/hover/tests.rs@@ -250,6 +250,51 @@ fn a_hovered_status_item_is_outlined_and_its_icons_take_the_hover_foreground(cx:assert!(!icons.is_empty() && icons.iter().all(|color| *color == gpui::rgb(0xFF0000).into()), "{icons:?}");}+#[gpui::test]+fn a_hovered_extension_entry_s_icons_follow_its_label_color(cx: &mut TestAppContext) {+ let (workbench, cx) = open_workbench("hover-status-extension", cx);+ let scale = workbench.update_in(cx, |workbench, window, cx| {+ workbench.theme.set_customizations(&serde_json::json!({ "statusBarItem.hoverForeground": "#FF0000" }), &serde_json::json!({}));+ let entry = |id: &str, text: &str, color: Option<&str>| crate::main_thread_status_bar::StatusEntry {+ entry_id: id.into(),+ extension_id: None,+ id: id.into(),+ name: id.into(),+ text: text.into(),+ tooltip: None,+ command: Some(serde_json::json!("noop")),+ color: color.map(|color| serde_json::json!(color)),+ background_color: None,+ kind: None,+ align_left: true,+ priority: 0.,+ secondary: 0,+ show_progress: false,+ };+ workbench.status_entries.push(entry("plain", "$(check) Plain", None));+ workbench.status_entries.push(entry("own", "$(check) Own", Some("#00FF00")));+ cx.notify();+ window.scale_factor()+ });+ cx.run_until_parked();+ // The test platform paints no text glyphs: the icons are the label's sprites.+ let icon_colors_when_hovered = |selector: &'static str, cx: &mut gpui::VisualTestContext| {+ let bounds = cx.debug_bounds(selector).expect("the entry is drawn");+ cx.simulate_mouse_move(bounds.center(), None, Modifiers::none());+ cx.run_until_parked();+ cx.read_rendered_frame(|scene, _| {+ let inside = |sprite: &gpui::MonochromeSprite| bounds.contains(&sprite.bounds.center().map(|v| px(v.0 / scale)));+ scene.monochrome_sprites.iter().filter(|sprite| inside(sprite)).map(|sprite| sprite.color).collect::<Vec<gpui::Hsla>>()+ })+ };+ // statusbarpart.css `a:hover` color and `span.codicon { color: inherit }`.+ let icons = icon_colors_when_hovered("status-bar-entry-plain", cx);+ assert!(!icons.is_empty() && icons.iter().all(|color| *color == gpui::rgb(0xFF0000).into()), "plain: {icons:?}");+ // statusbarItem.ts `applyColor`: the label's inline color wins over the hover rule.+ let icons = icon_colors_when_hovered("status-bar-entry-own", cx);+ assert!(!icons.is_empty() && icons.iter().all(|color| *color == gpui::rgb(0x00FF00).into()), "own: {icons:?}");+}+#[gpui::test]fn a_hover_shows_after_the_delay_and_hides_when_the_pointer_leaves(cx: &mut TestAppContext) {let (workbench, cx) = open_workbench("hover", cx);diff --git a/native/crates/app/src/workbench/status_entries.rs b/native/crates/app/src/workbench/status_entries.rsindex 22116977732..786ea75d593 100644--- a/native/crates/app/src/workbench/status_entries.rs+++ b/native/crates/app/src/workbench/status_entries.rs@@ -46,14 +46,17 @@ impl Workbench {}pub(super) fn extension_status_item(&self, entry: &StatusEntry, foreground: Rgba, cx: &mut Context<Self>) -> Stateful<Div> {+ let own_color = entry.kind.is_none().then(|| entry.color.as_ref().and_then(|color| self.entry_color(color))).flatten();let (color, background) = match entry.kind {Some(kind) => (self.color(&format!("statusBarItem.{kind}Foreground")), self.theme.color(&format!("statusBarItem.{kind}Background"))),- None => (entry.color.as_ref().and_then(|color| self.entry_color(color)).unwrap_or(foreground), entry.background_color.as_ref().and_then(|color| self.entry_color(color))),+ None => (own_color.unwrap_or(foreground), entry.background_color.as_ref().and_then(|color| self.entry_color(color))),};- let mut label = self.highlighted_label(&entry.text, &[], color, 16., color);+ // statusbarItem.ts `applyColor`: an own color is the label's inline style, above statusbarpart.css's `a:hover` color.+ let hover = own_color.is_none().then(|| self.color(&status_item_hover_key(entry.kind, "Foreground")));+ let mut label = self.status_entry_label(&entry.text, color, hover);if entry.show_progress {// statusbarItem.ts: a non-breaking space between the spinner and the text.- label = self.highlighted_label(&format!("\u{a0}{}", entry.text), &[], color, 16., color);+ label = self.status_entry_label(&format!("\u{a0}{}", entry.text), color, hover);// codicon-animations.css: `codicon-modifier-spin` turns once in 1.5s in 30 steps.let path = self.app_root.join("node_modules/@vscode/codicons/src/icons/loading.svg");let spinner = svg()@@ -61,11 +64,13 @@ impl Workbench {.size(px(16.)).flex_none().text_color(color)+ .when_some(hover, |spinner, hover| spinner.group_hover(STATUS_ITEM_GROUP, move |spinner| spinner.text_color(hover))).with_animation("status-progress-spin", Animation::new(Duration::from_millis(1500)).repeat(), |spinner, delta| {spinner.with_transformation(Transformation::rotate(percentage((delta * 30.).floor() / 30.)))});label = div().flex().items_center().child(spinner).child(label);}+ let label = label.when_some(own_color, |label, color| label.text_color(color));let command = entry.command.clone();let (margin, padding) = self.status_item_spacing();let item = div()@@ -99,11 +104,7 @@ impl Workbench {/// hover colors, in modernUI statusBar.css's cornerRadius.small (4px), and in high contrast a 1px dashed/// `contrastActiveBorder` outline inside it.pub(super) fn status_item_hover(&self, item: Stateful<Div>, kind: Option<&str>) -> Stateful<Div> {- let key = |part: &str| match kind {- Some(kind) => format!("statusBarItem.{kind}Hover{part}"),- None => format!("statusBarItem.hover{part}"),- };- let (background, foreground) = (self.color(&key("Background")), self.color(&key("Foreground")));+ let (background, foreground) = (self.color(&status_item_hover_key(kind, "Background")), self.color(&status_item_hover_key(kind, "Foreground")));let outline = self.theme.color("contrastActiveBorder").map(|border| {div().absolute().inset_0().rounded(px(4.)).border_1().border_dashed().border_color(border).invisible().group_hover(STATUS_ITEM_GROUP, |outline| outline.visible())});@@ -117,6 +118,31 @@ impl Workbench {self.styled_icon(name, box_size, 16., |icon| icon.text_color(foreground).group_hover(STATUS_ITEM_GROUP, move |icon| icon.text_color(hover)))}+ /// statusbarItem.ts `StatusBarCodiconLabel`: the `$(icon)`s are `span.codicon`s, `color: inherit` of the label+ /// (statusbarpart.css), so they take the `hover` foreground with its text.+ fn status_entry_label(&self, text: &str, color: Rgba, hover: Option<Rgba>) -> Div {+ let chars: Vec<char> = text.chars().collect();+ let mut label = div().flex().items_center().min_w_0();+ let mut segment = String::new();+ let mut index = 0;+ while index < chars.len() {+ let Some((name, length)) = super::quick_input_view::icon_at(&chars[index..]) else {+ segment.push(chars[index]);+ index += 1;+ continue;+ };+ if !segment.is_empty() {+ label = label.child(std::mem::take(&mut segment));+ }+ label = label.child(self.styled_icon(&name, 16., 16., |icon| icon.text_color(color).when_some(hover, |icon, hover| icon.group_hover(STATUS_ITEM_GROUP, move |icon| icon.text_color(hover)))));+ index += length;+ }+ if !segment.is_empty() {+ label = label.child(segment);+ }+ label+ }+pub(super) fn status_bar_extension_entry(&self, entry: &StatusEntry, foreground: Rgba, cx: &mut Context<Self>) -> Option<AnyElement> {self.status_bar_entry(&entry.id, &entry.name, entry.extension_id.as_deref(), self.extension_status_item(entry, foreground, cx), cx)}@@ -280,6 +306,13 @@ impl Workbench {}}+fn status_item_hover_key(kind: Option<&str>, part: &str) -> String {+ match kind {+ Some(kind) => format!("statusBarItem.{kind}Hover{part}"),+ None => format!("statusBarItem.hover{part}"),+ }+}+/// The name of an editor status entry (editorStatus.ts, editorStatusBar.ts, mediaPreviewStatusBar.ts).pub(super) fn editor_status_entry_name(id: &str) -> &'static str {match id {diff --git a/port/fixtures/extensions/messages/extension.js b/port/fixtures/extensions/messages/extension.jsindex 9901c0d8ef4..c9c942869e2 100644--- a/port/fixtures/extensions/messages/extension.js+++ b/port/fixtures/extensions/messages/extension.js@@ -18,6 +18,16 @@ const shows = {left.tooltip = 'Left entry from an extension';left.command = 'portMessages.info';left.show();+ // Right aligned: the reference's remote indicator moves the left entries.+ const plain = vscode.window.createStatusBarItem('portMessages.plain', vscode.StatusBarAlignment.Right, 1002);+ plain.text = '$(bell) Port plain';+ plain.command = 'portMessages.info';+ plain.show();+ const colored = vscode.window.createStatusBarItem('portMessages.colored', vscode.StatusBarAlignment.Right, 1001);+ colored.text = '$(check) Port colored';+ colored.color = '#00FF00';+ colored.command = 'portMessages.info';+ colored.show();const right = vscode.window.createStatusBarItem('portMessages.right', vscode.StatusBarAlignment.Right, 1000);right.text = 'Port warning';right.backgroundColor = new vscode.ThemeColor('statusBarItem.warningBackground');diff --git a/port/fixtures/ui-pair/statusbar-hover.json b/port/fixtures/ui-pair/statusbar-hover.jsonnew file mode 100644index 00000000000..2695f168e5f--- /dev/null+++ b/port/fixtures/ui-pair/statusbar-hover.json@@ -0,0 +1 @@+[{"wait":4000},{"hover":[748,755]},{"wait":300},{"shot":"plain"},{"hover":[845,755]},{"wait":300},{"shot":"colored"},{"hover":[999,755]},{"wait":300},{"shot":"bell"},{"hover":[62,755]},{"wait":300},{"shot":"problems"}]diff --git a/port/ledger.md b/port/ledger.mdindex f05f75b2776..394cbe0dd42 100644--- a/port/ledger.md+++ b/port/ledger.md@@ -27,7 +27,7 @@ Status: `open`, `in progress`, `waiting on Artur`, `later` (postponed), `done`,| Milestones | M10 settings, storage, profiles | done | `settings.json` (user, workspace, folder, language overrides) feeding both the workbench and `vscode.workspace.getConfiguration`, configuration schema from `contributes.configuration`, the Settings editor and JSON settings with schema validation, global and workspace storage on disk, secret storage in the macOS Keychain, profiles, real `environment` in init data. Import from VS Code, Cursor and VSCodium (Artur, port feature with no upstream counterpart): a command and a first-run offer that read each installed editor's user data (`~/Library/Application Support/{Code,Cursor,VSCodium}/User`: settings.json, keybindings.json, snippets, the color and icon theme ids) and its extension list (`~/.vscode/extensions`, `~/.cursor/extensions`, `~/.vscode-oss/extensions`, installed again from Open VSX), show what will be imported, write it into the active profile and skip settings and extensions the port has removed (AI, sign-in, Microsoft services, telemetry, remote). Open gaps: the gaps column of its unit rows. | api-tests `configuration.test` and `state.test` pass as in the reference; a setting changed in `settings.json` reaches an extension's `onDidChangeConfiguration`; storage survives a restart; importing from a fixture VS Code, Cursor and VSCodium user data folder gives the same settings, keybindings, snippets and theme in the port. || Milestones | M11 workbench layout and chrome | in progress | The part grid with sashes and hidden parts, panel and secondary side bar, view containers and collapsible views, tree views from extensions (with the Refactor Preview of workbench/contrib/bulkEdit, which file operation participants open), editor groups and splits, notifications, dialogs (native open/save), progress, banner, status bar entries from extensions, decorations, window lifecycle (close, quit, hot exit backup), multiple windows, focus and inactive look. Open gaps: the gaps column of its unit rows. | api-tests `window.test` (messages, progress, tree views, status bar) pass as in the reference; pixel-check gains a window with panel and split editor; hot exit restores an unsaved buffer after quit. || Milestones | M12 files, explorer, search, workspace | in progress | File system service with watcher (FSEvents) and extension file system providers, Explorer file operations (new, rename, delete to Trash, drag and drop, copy/paste), Seti file icons, numeric name collation, workspace trust, multi-root `.code-workspace`, recent workspaces, text search through ripgrep, search view and search editor, bulk edits, local history, opener and URL handling. Open gaps: the gaps column of its unit rows. | api-tests `workspace.test`, `workspace.fs.test`, `workspace.event.test`, `workspace.tasks` excluded, and the api-workspace suite pass as in the reference; pixel-check folder window with Seti icons (reference captured without `workbench.iconTheme: null`); `cargo test -p app` sorting test with `file9`/`file10`. |-| Milestones | M13 language features | done | Everything `MainThreadLanguageFeatures` registers, drawn by the native editor: completion, hover, signature help, code actions and lightbulb, code lens, inlay hints, go to definition and peek, references, rename, formatting, document symbols and Outline, semantic tokens, semantic word highlight, links, color picker, linked editing, snippets, call and type hierarchy, inline completions from extensions; diagnostics with squiggles and the Problems panel; comments threads; Emmet; the language status item. Open gaps: the gaps column of its unit rows. | api-tests `languages.test`, `languagefeatures.test`-family and `comments` cases pass as in the reference; with `src/main.ts` open TypeScript completion, hover, go to definition and a diagnostic squiggle work (pixel-check window with a squiggle and the suggest widget). |+| Milestones | M13 language features | in progress | Everything `MainThreadLanguageFeatures` registers, drawn by the native editor: completion, hover, signature help, code actions and lightbulb, code lens, inlay hints, go to definition and peek, references, rename, formatting, document symbols and Outline, semantic tokens, semantic word highlight, links, color picker, linked editing, snippets, call and type hierarchy, inline completions from extensions; diagnostics with squiggles and the Problems panel; comments threads; Emmet; the language status item. Open gaps: the gaps column of its unit rows. | api-tests `languages.test`, `languagefeatures.test`-family and `comments` cases pass as in the reference; with `src/main.ts` open TypeScript completion, hover, go to definition and a diagnostic squiggle work (pixel-check window with a squiggle and the suggest widget). || Milestones | M14 source control and diff | done | SCM view and input box, quick diff gutter, the diff editor (side by side and inline), multi-file diff, merge editor and merge-conflict decorations, timeline, the git, git-base and github extensions fully working (no sign-in: github features that need a token stay off). Open gaps: the gaps column of its unit rows. | api-tests SCM cases pass as in the reference; with the fixture copied into a git repository the SCM view lists a changed file and opening it shows the diff (pixel-check window). || Milestones | M15 terminal, tasks, output | done | Integrated terminal (PTY from Rust, VT parser and renderer in GPUI), shell integration, extension terminals and pseudoterminals, tasks and problem matchers, npm/grunt/gulp/jake task providers, external terminal, Output panel and log viewer. Open gaps: the gaps column of its unit rows. | api-tests `terminal.test`, `terminal.shellIntegration.test` and `workspace.tasks.test` pass as in the reference (run with `SHELL=/bin/bash` as the baseline was); `npm: build` task from the fixture runs in a terminal. || Milestones | M16 debug and testing | in progress | Debug adapter protocol client, launch.json, breakpoints in the gutter, call stack, variables, watch, debug console, JS debugger (`ms-vscode.js-debug`), Test Explorer and test results. Open gaps: the gaps column of its unit rows. | api-tests `debug.test` and testing cases pass as in the reference; a breakpoint in a Node script from the fixture stops and shows variables. |@@ -360,7 +360,7 @@ One row per upstream unit, generated by `bun port/tools/gen-ledger.ts`; mileston| workbench/parts/partGrid | workbench part | M11 | verified | | workbench/layout.rs grid on split_view.rs (splitview.ts priorities, snap, visibility), workbench/part_grid.rs sashes, hidden parts, sizes and visibility in LayoutStateModel storage keys: cargo test -p app layout part_grid split_view (reference geometry at 1024x768, Cmd+B for the next open, sash drag, snap); ui-pair grid steps, port/results/layout.md || workbench/parts/sessions | workbench part | | removed | | no sign-in/AI by decision (port/notes.md); not ported || workbench/parts/sidebar | workbench part | M11 | verified | | Explorer and Search; compact activity bar for top and bottom (side_bar.rs) with every container the activity bar shows: built-in, Testing, extensions' `viewsContainers.activitybar` from startup and after an install, and generated ones (cargo test -p app the_top_activity_bar_shows_contributed_containers; it showed the five built-in ones only until then), No Folder Opened welcome in an empty window (empty_view.rs); pixel-check (port/results/pixels.md, milestone 3): chevron and label edge pixels only; ui-pair port/results/layout.md; verified: every pair of port/results/windows.md (milestone 11 verification) and port/results/references-view.md |-| workbench/parts/statusbar | workbench part | M11 | ported | [3 S] status_entries.rs extension_status_item: an entry's `$(icon)`s keep its color on hover where statusbarpart.css's `color: inherit` takes `statusBarItem.hoverForeground`, and an entry with its own `color` (statusbarItem.ts applyColor, an inline style on the label) still takes the hover foreground; HC dashed hover outline and problems, bell and language detection icons on hover not yet checked against the reference with ui-pair | no-folder and folder colors (problems, bell), no remote indicator (workbench/contrib/remote removed, port/notes.md; cargo test -p app the_status_bar_has_no_remote_indicator), a hovered label's HC dashed `contrastActiveBorder` outline and icons in `statusBarItem.hoverForeground` (a_hovered_status_item_is_outlined_and_its_icons_take_the_hover_foreground), editor items Ln/Col, indentation, encoding, EOL, language with tabular-nums at their shaped widths and their upstream hovers; each item runs its editorStatus.ts command (Go to Line, indentation, encoding, EOL and language pickers: cargo test -p app editor_status); extension entries in statusbarModel.ts order around problems and the editor items (status_entries.rs), and the `status.progress` window progress entry with its spinner; verified: ui-pair messages.json vs the reference (port/results/windows.md, milestone 11 verification): extension entries, warning background, window progress entry, bell |+| workbench/parts/statusbar | workbench part | M11 | ported | [3 S] status_entries.rs status_item_hover: the pointer resting on the problems entry while a new untitled editor opens and takes typing leaves its numbers in the hover foreground but its icons and outline unhovered, the reference keeps the whole hover (seen in a ui-pair run of port/fixtures/ui-pair/statusbar-hover.json with Cmd+N and typing after the `problems` step) | an extension entry's `$(icon)`s and progress spinner in its kind's hover foreground, an entry with its own `color` keeping it on hover (statusbarItem.ts `applyColor`; cargo test -p app a_hovered_extension_entry_s_icons_follow_its_label_color); ui-pair port/fixtures/ui-pair/statusbar-hover.json hc with `PORT_MESSAGES=status`, the messages extension and `statusBarItem.hoverForeground` #FF0000: the hovered plain, colored, bell and problems entries match the reference (dashed outline, red icons and text, the colored entry green; 223 to 403 differing pixels of 48000 at 3% fuzz); the language detection entry draws its icon with the same `status_item_icon`; no-folder and folder colors (problems, bell), no remote indicator (workbench/contrib/remote removed, port/notes.md; cargo test -p app the_status_bar_has_no_remote_indicator), a hovered label's HC dashed `contrastActiveBorder` outline and icons in `statusBarItem.hoverForeground` (a_hovered_status_item_is_outlined_and_its_icons_take_the_hover_foreground), editor items Ln/Col, indentation, encoding, EOL, language with tabular-nums at their shaped widths and their upstream hovers; each item runs its editorStatus.ts command (Go to Line, indentation, encoding, EOL and language pickers: cargo test -p app editor_status); extension entries in statusbarModel.ts order around problems and the editor items (status_entries.rs), and the `status.progress` window progress entry with its spinner; verified: ui-pair messages.json vs the reference (port/results/windows.md, milestone 11 verification): extension entries, warning background, window progress entry, bell || workbench/parts/titlebar | workbench part | M9 | verified | | command center with the folder name, nav and layout actions (Customize Layout runs since port/results/manage-menu.md; with the activity bar on top or bottom the title bar's Manage gear opens MenuId.GlobalActivity below it, cargo test -p app manage_menu); a click on the command center opens Quick Open with the Go to File and Show and Run Commands help picks (port/results/command-center.md); drag region as `-webkit-app-region` (empty bar drags and double-click zooms, command center and layout controls no-drag; cargo test -p app title_bar, port/results/command-center.md); context menus of the bar, the title and the command center with the Command Center, Navigation Controls and Layout Controls toggles and the path items (cargo test -p app title_bar); pixel-check file and titlebar (port/results/pixels.md): blending rounding and glyph edges only; the inactive window: `titleBar.inactiveBackground`/`inactiveForeground`, `commandCenter.inactiveBorder`, contents at 0.6 opacity, `modernUI.inactiveShellBackground` (cargo test -p app theme::tests; ui-pair `new-window.json`, port/results/windows.md) || workbench/parts/views | workbench part | M11 | verified | | Explorer views as panes (view_panes.rs): collapse by mouse and keys, sashes, header drag to reorder with drop overlay, state in workbench.explorer.views.state; no view actions, view menus or hidden views; cargo test -p app view_panes, ui-pair port/results/layout.md; pane headers drawn statically (workbench.rs section_header): no collapse, resize or view actions; verified: ui-pair port/results/references-view.md and every pair of port/results/windows.md (milestone 11 verification): the Explorer panes and contributed views as the reference; Explorer and Source Control views as panes of a ViewPaneContainer (view_panes.rs `PaneContainer`): collapse by mouse and keys, sashes, header drag to reorder with drop overlay, single view merged into the container, header actions, state in the container's storageId; cargo test -p app view_panes scm_container, ui-pair port/results/layout.md and port/fixtures/ui-pair/m11/scm-panes.json (port/notes.md View panes); verified: ui-pair port/results/references-view.md and every pair of port/results/windows.md (milestone 11 verification): the Explorer panes and contributed views as the reference; Run and Debug, Extensions and webview containers still draw section_header rows: no collapse, resize or view actions; welcome buttons draw their `$(icon)`s (cargo test -p app a_welcome_button_draws_its_label_icons; ui-pair port/fixtures/ui-pair/icons/scm-welcome.json: github's Publish to GitHub button with the github codicon as the reference); wrapped text stacks unsnapped 18.2px lines as Chromium (vendor gpui elements/text.rs; cargo test -p app wrapped_lines_keep_their_fractional_line_height): scm-welcome's Publish button 0.5pt from the reference, was 2.5pt; left: the port wraps "Git" of "To learn more about how to use Git" to the next line; a merged view's "..." puts the Views submenu, a separator and the view's own actions (panecomposite.ts `getSecondaryActions`; cargo test -p app a_merged_changes_view_shows_the_views_submenu_in_its_more_actions a_merged_view_without_actions_lists_the_view_toggles_flat) || workbench/services/accessibility | workbench service | M19 | verified | | electron-browser accessibilityService.ts over GPUI: screen reader attach follows Electron's `isAccessibilitySupportEnabled` on macOS (VoiceOver, or an assistive app setting AXManualAccessibility or AXEnhancedUserInterface, as cua-driver does; ui-pair screen-reader-detection.json with accessibility support auto shows the prompt in both), the Screen reader usage detected prompt and status entry; port/tools/a11y-check; cargo test -p app accessib; electron-browser accessibilityService.ts over GPUI: screen reader attach follows is_a11y_active, the Screen reader usage detected prompt and status entry; port/tools/a11y-check; cargo test -p app accessib |@@ -405,7 +405,7 @@ One row per upstream unit, generated by `bun port/tools/gen-ledger.ts`; mileston| workbench/services/keybinding | workbench service | M9 | verified | | Registered commands with `args` metadata are not unbound (the reference's `commandsWithArgs`): keybindings_editor::tests::registered_commands_with_args_metadata_are_not_unbound; keyboard.rs: default-macos.json, contributes.keybindings, keybindings.json reload on a file watcher change after 50 ms (keyboard::tests::an_outside_edit_of_keybindings_json_applies), the troubleshooting log's `keyCode` as `EVENT_KEY_CODE_MAP` inverted (output_view tests), chords with the status bar message, scan code dispatch on the layout's keyboard mapper (`_resolveKeybindingItems`, `keyboard.dispatch`, `keyboard.mapAltGrToCtrlAlt`); cargo test -p app keybindings user_keybindings keyboard_mapper define_keybinding; pixel-check chord; Studio run with the mapper (port/results/keybindings-layout.md); keyboard.rs: default-macos.json, contributes.keybindings, keybindings.json reload, chords with the status bar message; cargo test -p app keybindings user_keybindings; pixel-check chord || workbench/services/label | workbench service | M12 | verified | | file scheme getUriLabel in quick_input.rs path_label and path_label_without_prefix (label.test.ts file scheme, multi-root and explicit separator cases: cargo test -p app path_labels copied_path_labels), tildify (search_view.rs), workspace labels (cargo test -p config labels_a_workspace_file_by_its_name); formatters and URI homes only come from remote resolvers (MainThreadLabelService removed); verified at port-m12b-verify: cargo test -p app path_labels 2/2 || workbench/services/language | workbench service | M7 | verified | | getAssociationByPath with the full glob dialect (languages::tests::file_patterns_take_the_whole_glob_dialect) plus firstLine detection (languages.rs); cargo test -p app languages::tests |-| workbench/services/languageDetection | workbench service | M13 | verified | | language_detection.rs (languageDetectionWebWorker.ts `detectLanguagesImpl`, `adjustLanguageConfidence`, the 10000 char sample) and workbench/language_detection.rs (`LanguageDetectionWorkerClient`: the file name guess first, then @vscode/vscode-languagedetection 1.0.23 with its model in a Bun worker from the app's node_modules, model ids mapped as `getLanguageId`; `autoDetectLanguage` of textEditorModel.ts for untitled models and extensionless plain text files, 600 ms throttle, skipped after an explicit language and with `workbench.editor.languageDetection` off): cargo test -p app language_detection (the worker test runs the real model). The history biases only feed the regexp model, which 1.147.0 does not ship (`vscode-regexp-languagedetection` is not a dependency), so neither side has it; no telemetry |+| workbench/services/languageDetection | workbench service | M13 | ported | [3 S] workbench/language_detection.rs: 4 s after typing a Python snippet into a new untitled editor (Cmd+N in a ui-pair run, hc) the port's language entry shows Python, the reference's still Plain Text, also after 12 s; not yet known whether the reference build lacks the detection model or the port detects where upstream does not | language_detection.rs (languageDetectionWebWorker.ts `detectLanguagesImpl`, `adjustLanguageConfidence`, the 10000 char sample) and workbench/language_detection.rs (`LanguageDetectionWorkerClient`: the file name guess first, then @vscode/vscode-languagedetection 1.0.23 with its model in a Bun worker from the app's node_modules, model ids mapped as `getLanguageId`; `autoDetectLanguage` of textEditorModel.ts for untitled models and extensionless plain text files, 600 ms throttle, skipped after an explicit language and with `workbench.editor.languageDetection` off): cargo test -p app language_detection (the worker test runs the real model). The history biases only feed the regexp model, which 1.147.0 does not ship (`vscode-regexp-languagedetection` is not a dependency), so neither side has it; no telemetry || workbench/services/languageStatus | workbench service | M13 | verified | | `$setLanguageStatus` / `$removeLanguageStatus`, statuses matched by selector, ordered by severity, source, id (workbench/language_status.rs): cargo test -p app language_status || workbench/services/layout | workbench service | M11 | ported | [3 L] editor_status.rs:606, content_hover.rs:498: no workbench-wide Tab order (the browser's DOM order): Tab stops at the content hover's ends, and Tab on the status bar in Tab Focus Mode keeps the focus (port/notes.md Toggle Tab Key Moves Focus) <br> [3 L] workbench.rs:591: the Workbench is one GPUI view, so every scroll frame of any list renders and lays out every part again, where upstream's DOM updates only the scrolled list; `scroll_frame_time` median / p95 at 42d10fe2347: Explorer 11.5 / 15.7 ms, Editor 18.0 / 19.2 to 42.0 ms, Settings 12.4 / 16.8 ms over the 8 ms gate (Extensions 2.8 / 3.0 meets it); per frame taffy lays out the whole workbench (6.6 ms of the Explorer frame), each `key_context` caller clones every `config.*` key (keyboard.rs:400), the menubar and the timeline toolbar are rebuilt; the next step is the part-entity split, side bar first (port/notes.md Scroll frame costs, cheap steps). GUI (Studio at load 33 to 57, 60 Hz display, 690 trackpad events in 7 s): main thread in `Window::draw` 86% scrolling the Explorer (800 files), 89% the Extensions @builtin list (port/notes.md Scroll frame costs) | layout.ts as a split-view tree (workbench/layout.rs): panel position (bottom, top, left, right) and alignment, primary side bar left or right, maximized panel with `panelMaximizationSupportedWhen`, hidden parts, persisted sizes and positions; zen mode (zen_mode.rs) with its settings and restore; centered layout (centered_layout.rs) with its sashes and stored margins; View > Appearance entries and the Panel Position and Align Panel submenus (cargo test -p app -- layout part_grid centered_layout zen_mode); layoutActions.ts Customize Layout quick pick (workbench/customize_layout.rs) with live items, Restore Defaults and Close, Toggle Activity Bar Visibility, Align Quick Input Top/Center (cargo test -p app -- customize_layout toggling_the_activity_bar; ui-pair m11/manage-menu.json, port/results/manage-menu.md; missing until then though the title bar showed its button); ui-pair layout-positions.json and layout-zen.json against the reference (port/results/layout.md). The pairs run with `zenMode.fullScreen` off. Maximize Secondary Side Bar (`workbench.action.maximizeAuxiliaryBar`, `restoreAuxiliaryBar`, `toggleMaximizedAuxiliaryBar`, the title's toggle) hides the other parts and restores them (workbench/panel.rs; cargo test -p app -- maximizing_the_secondary_side_bar_hides_the_other_parts_and_restore_brings_them_back). Zen mode enforces `zenMode.showTabs` on the main editor part until it ends (layout.ts `toggleZenMode` `enforcePartOptions`; workbench/zen_mode.rs `editor_show_tabs`; cargo test -p app -- show_tabs_picks_the_title_control_and_zen_mode_enforces_its_own); navigationActions.ts `workbench.action.focusNextPart`/`focusPreviousPart` (F6, Shift+F6) walk editor, panel, auxiliary bar, status bar, activity bar and side bar past the hidden ones with layout.ts `focusPart` (the pane container's first expanded view; workbench/part_navigation.rs; cargo test -p app f6_walks_the_visible_parts); in an editor window F6 goes between its editor and its own status bar, whose entry focus is kept per window (workbench/auxiliary_windows.rs `auxiliary_status_bar`, workbench/status_entries.rs; cargo test -p app f6_in_an_editor_window_reaches_its_own_status_bar) || workbench/services/lifecycle | workbench service | M11 | ported | [3 L] unattendedRestart.ts: the participants terminalUnattendedRestart.ts, testingUnattendedRestart.ts, webviewUnattendedRestart.ts, notebookUnattendedRestart.ts and testingContinuousRunService.ts `testing.continuousRun` are not ported (the port's terminal has no `hasChildProcesses`), the editor detail names the scheme where upstream names `typeId`, `workbench.floatingWindowNotRestorable` cannot occur (the port's auxiliary windows are all editor parts), and nothing calls `can_restart_unattended` yet: platform/update's `UnattendedRestartScheduler` (restart to update while the screen is locked, with `update.restartWhenIdle` on), `quitAndInstall` with `unattended` and windowsStateHandler.ts `setNextExactRestore` are not ported | workbench/lifecycle.rs: ShutdownReason, onBeforeShutdown vetoes on quit, close button, closeWindow, reload and load (`window.confirmBeforeClose`, backup tracker auto save, hot exit, showSaveConfirm); cargo test -p app lifecycle; no phases or onWillShutdown joiners; workbench/unattended_restart.rs: `canRestartUnattended` with its blocker aggregation and change log, and the participants `workbench.starting` (2.5 s after restore), dialog, quick input, transient workspace, modal editor, editors not restored or not restorable, `debug.sessionActive`, `tasks.running`, the backup tracker's `workingCopy.*` and `cli.waitingForEditorClose`: cargo test -p app unattended_restart (unattendedRestart.test.ts); verified: cargo test -p app backup_tracker lifecycle (workingCopyBackupTracker.test.ts); ui-pair hot-exit.json `dirty`, `restored` vs the reference (port/results/windows.md, milestone 11 verification) |