detached caafe10

fix(omnibox): preserve selected favorite borders (#441)

* fix(omnibox): preserve selected favorite borders

* fix(omnibox): preserve minimal favorite hairline
commit
caafe10a5dd68306dd559557824846c8d97a94b7
author
bnema · · 2026-09-15 16:08 UTC
committer
GitHub · · 2026-09-15 16:08 UTC
parent
a015def
signature
GPG UnverifiedB5690EEEBB952194 The key is unknown
3 files · +32 -0
M CHANGELOG.md +1 -0
@@ -24,6 +24,7 @@ All notable changes to this project will be documented in this file.
2424
2525 ### Fixed
2626
27+- **Omnibox favorite selection**: Selected favorite rows retain their yellow left indicator in every visual style.
2728 - **Popup and floating-pane stability**: Hardened deferred popup cleanup, failed popup creation, opener-capable fallback behavior, and pane/window rollback paths.
2829 - **WebView resource cleanup**: Fixed stale callback, timer, tick, split, hover-controller, and rebuilt-WebView ownership paths that could leak resources or act on detached views.
2930 - **CEF rendering and input**: Improved OSR input and clipboard handling, effective visibility transitions, canvas presentation, repeated GPU relaunch recovery, and runtime propagation to helper processes.
@@ -24,6 +24,7 @@ All notable changes to this project will be documented in this file.
24 24
25 ### Fixed25 ### Fixed
26 26
27+- **Omnibox favorite selection**: Selected favorite rows retain their yellow left indicator in every visual style.
27 - **Popup and floating-pane stability**: Hardened deferred popup cleanup, failed popup creation, opener-capable fallback behavior, and pane/window rollback paths.28 - **Popup and floating-pane stability**: Hardened deferred popup cleanup, failed popup creation, opener-capable fallback behavior, and pane/window rollback paths.
28 - **WebView resource cleanup**: Fixed stale callback, timer, tick, split, hover-controller, and rebuilt-WebView ownership paths that could leak resources or act on detached views.29 - **WebView resource cleanup**: Fixed stale callback, timer, tick, split, hover-controller, and rebuilt-WebView ownership paths that could leak resources or act on detached views.
29 - **CEF rendering and input**: Improved OSR input and clipboard handling, effective visibility transitions, canvas presentation, repeated GPU relaunch recovery, and runtime propagation to helper processes.30 - **CEF rendering and input**: Improved OSR input and clipboard handling, effective visibility transitions, canvas presentation, repeated GPU relaunch recovery, and runtime propagation to helper processes.
M internal/ui/theme/css.go +13 -0
@@ -567,6 +567,11 @@ entry.omnibox-entry.omnibox-entry-bang-active:focus-visible > text {
567567 box-shadow: 0.1875em 0 0 var(--accent) inset;
568568 }
569569
570+.omnibox-style-multiplexer .omnibox-row.omnibox-row-favorite:selected {
571+ border-left-color: var(--warning);
572+ box-shadow: 0.1875em 0 0 var(--warning) inset;
573+}
574+
570575 .omnibox-style-multiplexer .omnibox-favorite-star {
571576 min-width: 1.25em;
572577 margin: 0 0.375em 0 0.125em;
@@ -632,6 +637,10 @@ entry.omnibox-entry.omnibox-entry-bang-active:focus-visible > text {
632637 border-left-color: transparent;
633638 }
634639
640+.omnibox-style-command .omnibox-row.omnibox-row-favorite:selected {
641+ border-left: 0.1875em solid var(--warning);
642+}
643+
635644 .omnibox-style-command .omnibox-favorite-star {
636645 min-width: 1.25em;
637646 margin: 0 0.375em 0 0.125em;
@@ -689,6 +698,10 @@ entry.omnibox-entry.omnibox-entry-bang-active:focus-visible > text {
689698 font-family: var(--font-mono);
690699 }
691700
701+.omnibox-style-minimal .omnibox-row.omnibox-row-favorite:selected {
702+ border-left: 0.125em solid var(--warning);
703+}
704+
692705 .omnibox-style-minimal .omnibox-favorite-star {
693706 color: var(--warning);
694707 opacity: 0.85;
@@ -567,6 +567,11 @@ entry.omnibox-entry.omnibox-entry-bang-active:focus-visible > text {
567 box-shadow: 0.1875em 0 0 var(--accent) inset;567 box-shadow: 0.1875em 0 0 var(--accent) inset;
568 }568 }
569 569
570+.omnibox-style-multiplexer .omnibox-row.omnibox-row-favorite:selected {
571+ border-left-color: var(--warning);
572+ box-shadow: 0.1875em 0 0 var(--warning) inset;
573+}
574+
570 .omnibox-style-multiplexer .omnibox-favorite-star {575 .omnibox-style-multiplexer .omnibox-favorite-star {
571 min-width: 1.25em;576 min-width: 1.25em;
572 margin: 0 0.375em 0 0.125em;577 margin: 0 0.375em 0 0.125em;
@@ -632,6 +637,10 @@ entry.omnibox-entry.omnibox-entry-bang-active:focus-visible > text {
632 border-left-color: transparent;637 border-left-color: transparent;
633 }638 }
634 639
640+.omnibox-style-command .omnibox-row.omnibox-row-favorite:selected {
641+ border-left: 0.1875em solid var(--warning);
642+}
643+
635 .omnibox-style-command .omnibox-favorite-star {644 .omnibox-style-command .omnibox-favorite-star {
636 min-width: 1.25em;645 min-width: 1.25em;
637 margin: 0 0.375em 0 0.125em;646 margin: 0 0.375em 0 0.125em;
@@ -689,6 +698,10 @@ entry.omnibox-entry.omnibox-entry-bang-active:focus-visible > text {
689 font-family: var(--font-mono);698 font-family: var(--font-mono);
690 }699 }
691 700
701+.omnibox-style-minimal .omnibox-row.omnibox-row-favorite:selected {
702+ border-left: 0.125em solid var(--warning);
703+}
704+
692 .omnibox-style-minimal .omnibox-favorite-star {705 .omnibox-style-minimal .omnibox-favorite-star {
693 color: var(--warning);706 color: var(--warning);
694 opacity: 0.85;707 opacity: 0.85;
M internal/ui/theme/css_test.go +18 -0
@@ -302,6 +302,24 @@ func cssBorderWidthEm(t *testing.T, block string) float64 {
302302 return width
303303 }
304304
305+func TestGenerateCSS_SelectedFavoritesKeepWarningBorderInEveryStyle(t *testing.T) {
306+ css := GenerateCSS(DefaultDarkPalette())
307+
308+ for _, style := range []string{"multiplexer", "command", "minimal"} {
309+ selectedSelector := ".omnibox-style-" + style + " .omnibox-row:selected"
310+ favoriteSelector := ".omnibox-style-" + style + " .omnibox-row.omnibox-row-favorite:selected"
311+ favoriteBlock := cssRuleBlock(t, css, favoriteSelector)
312+ assert.Contains(t, favoriteBlock, "var(--warning)", style)
313+ assert.Greater(t, strings.Index(css, favoriteSelector), strings.Index(css, selectedSelector), style)
314+ }
315+
316+ minimal := cssRuleBlock(t, css, ".omnibox-style-minimal .omnibox-row.omnibox-row-favorite:selected")
317+ assert.Contains(t, minimal, "border-left: 0.125em solid var(--warning);")
318+
319+ multiplexer := cssRuleBlock(t, css, ".omnibox-style-multiplexer .omnibox-row.omnibox-row-favorite:selected")
320+ assert.Contains(t, multiplexer, "box-shadow: 0.1875em 0 0 var(--warning) inset;")
321+}
322+
305323 func TestGenerateCSS_OmniboxIncludesVisualConcepts(t *testing.T) {
306324 css := GenerateCSS(DefaultDarkPalette())
307325
@@ -302,6 +302,24 @@ func cssBorderWidthEm(t *testing.T, block string) float64 {
302 return width302 return width
303 }303 }
304 304
305+func TestGenerateCSS_SelectedFavoritesKeepWarningBorderInEveryStyle(t *testing.T) {
306+ css := GenerateCSS(DefaultDarkPalette())
307+
308+ for _, style := range []string{"multiplexer", "command", "minimal"} {
309+ selectedSelector := ".omnibox-style-" + style + " .omnibox-row:selected"
310+ favoriteSelector := ".omnibox-style-" + style + " .omnibox-row.omnibox-row-favorite:selected"
311+ favoriteBlock := cssRuleBlock(t, css, favoriteSelector)
312+ assert.Contains(t, favoriteBlock, "var(--warning)", style)
313+ assert.Greater(t, strings.Index(css, favoriteSelector), strings.Index(css, selectedSelector), style)
314+ }
315+
316+ minimal := cssRuleBlock(t, css, ".omnibox-style-minimal .omnibox-row.omnibox-row-favorite:selected")
317+ assert.Contains(t, minimal, "border-left: 0.125em solid var(--warning);")
318+
319+ multiplexer := cssRuleBlock(t, css, ".omnibox-style-multiplexer .omnibox-row.omnibox-row-favorite:selected")
320+ assert.Contains(t, multiplexer, "box-shadow: 0.1875em 0 0 var(--warning) inset;")
321+}
322+
305 func TestGenerateCSS_OmniboxIncludesVisualConcepts(t *testing.T) {323 func TestGenerateCSS_OmniboxIncludesVisualConcepts(t *testing.T) {
306 css := GenerateCSS(DefaultDarkPalette())324 css := GenerateCSS(DefaultDarkPalette())
307 325

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 8

Tags 42

↑↓ moveenter openesc close