Closed Bug 1880428 Opened 5 months ago Closed 5 months ago

Ensure text selection is visible even if a line is highlighted


(DevTools :: Debugger, task)



(firefox124 fixed)

124 Branch
Tracking Status
firefox124 --- fixed


(Reporter: nchevobbe, Assigned: nchevobbe)




(1 file)

At the moment, the line highlight that we use is an opaque color and it goes in front of the text selection, making it invisible (until the line gets un-highlighted)
In Bug 1878698, we're trying to get rid of unwanted highlighting, but I think we should still try to make the selection visible when the line is highlighted for valid reason.

The background color of the line highlight was opaque, hiding any
text selection that could be on that line.
Using a color with some transparency makes the selection visible.
We take this as an opportunity to fix and refactor the CSS for
line highlight.

Assignee: nobody → nchevobbe
Pushed by
[devtools] Make line highlight background color semi-transparent so text selection is visible. r=ochameau,devtools-reviewers.

Backed out for causing devtools failures on browser_parsable_css.js.

[task 2024-02-15T14:38:30.485Z] 14:38:30     INFO - TEST-START | browser/base/content/test/static/browser_parsable_css.js
[task 2024-02-15T14:38:31.042Z] 14:38:31     INFO - TEST-INFO | started process screentopng
[task 2024-02-15T14:38:31.223Z] 14:38:31     INFO - TEST-INFO | screentopng: exit 0
[task 2024-02-15T14:38:31.223Z] 14:38:31     INFO - Buffered messages logged at 14:38:30
[task 2024-02-15T14:38:31.223Z] 14:38:31     INFO - Entering test bound checkAllTheCSS
[task 2024-02-15T14:38:31.223Z] 14:38:31     INFO - Console message: [JavaScript Warning: "This page is in Quirks Mode. Page layout may be impacted. For Standards Mode use “<!DOCTYPE html>”." {file: "chrome://mochitests/content/browser/browser/base/content/test/static/dummy_page.html" line: 0}]
[task 2024-02-15T14:38:31.224Z] 14:38:31     INFO - Console message: [JavaScript Warning: "Unknown property ‘-moz-border-radius’.  Declaration dropped." {file: "chrome://devtools/content/shared/sourceeditor/codemirror/lib/codemirror.css?always-parse-css-0.6455610939751529" line: 244}]
[task 2024-02-15T14:38:31.224Z] 14:38:31     INFO - Buffered messages logged at 14:38:31
[task 2024-02-15T14:38:31.225Z] 14:38:31     INFO - Console message: [JavaScript Warning: "Unknown property ‘-moz-border-radius’.  Declaration dropped." {file: "chrome://devtools/content/shared/sourceeditor/codemirror/lib/codemirror.css" line: 244}]
[task 2024-02-15T14:38:31.225Z] 14:38:31     INFO - Ignored error "Unknown property ‘-moz-border-radius’.  Declaration dropped." on chrome://devtools/content/shared/sourceeditor/codemirror/lib/codemirror.css because of allowlist item {"sourceName":"/codemirror\\.css$/i","isFromDevTools":true,"used":true}
[task 2024-02-15T14:38:31.225Z] 14:38:31     INFO - TEST-PASS | browser/base/content/test/static/browser_parsable_css.js | All the styles (185) loaded without errors. - 
[task 2024-02-15T14:38:31.226Z] 14:38:31     INFO - Buffered messages finished
[task 2024-02-15T14:38:31.226Z] 14:38:31     INFO - TEST-UNEXPECTED-FAIL | browser/base/content/test/static/browser_parsable_css.js | Unused allowlist item: {"sourceName":"/devtools\\/content\\/debugger\\/src\\/components\\/([A-z\\/]+).css/i","isFromDevTools":true} - 
[task 2024-02-15T14:38:31.226Z] 14:38:31     INFO - Stack trace:
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - chrome://mochikit/content/browser-test.js:test_ok:1592
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - chrome://mochitests/content/browser/browser/base/content/test/static/browser_parsable_css.js:checkAllowlist:564
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - chrome://mochitests/content/browser/browser/base/content/test/static/browser_parsable_css.js:checkAllTheCSS:568
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - chrome://mochikit/content/browser-test.js:handleTask:1139
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - chrome://mochikit/content/browser-test.js:_runTaskBasedTest:1211
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - chrome://mochikit/content/browser-test.js:Tester_execTest:1353
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - chrome://mochikit/content/browser-test.js:nextTest/<:1128
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:SimpleTest.waitForFocus/<:1058
[task 2024-02-15T14:38:31.227Z] 14:38:31     INFO - Leaving test bound checkAllTheCSS
[task 2024-02-15T14:38:31.356Z] 14:38:31     INFO - GECKO(1313) | MEMORY STAT | vsize 11912MB | residentFast 550MB | heapAllocated 240MB
[task 2024-02-15T14:38:31.359Z] 14:38:31     INFO - TEST-OK | browser/base/content/test/static/browser_parsable_css.js | took 871ms
[task 2024-02-15T14:38:31.373Z] 14:38:31     INFO - checking window state
[task 2024-02-15T14:38:31.380Z] 14:38:31     INFO - TEST-START | devtools/client/framework/test/browser_about-devtools-toolbox_load.js
Flags: needinfo?(nchevobbe)
Pushed by
[devtools] Make line highlight background color semi-transparent so text selection is visible. r=ochameau,devtools-reviewers.
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → 124 Branch
Flags: needinfo?(nchevobbe)
You need to log in before you can comment on or make changes to this bug.