Skip to content
This repository was archived by the owner on Jan 11, 2023. It is now read-only.

Commit 1278f11

Browse files
authored
Merge pull request #3098 from jasonLaster/6-5
Release a new version of the debugger
2 parents cdccd0a + 843108b commit 1278f11

File tree

8 files changed

+698
-14
lines changed

8 files changed

+698
-14
lines changed

assets/module-manifest.json

Lines changed: 677 additions & 2 deletions
Large diffs are not rendered by default.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "debugger.html",
3-
"version": "0.4.0",
3+
"version": "0.5.0",
44
"license": "MPL-2.0",
55
"repository": {
66
"url": "git://github.com/devtools-html/debugger.html.git",

src/components/Editor/Editor.css

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
.editor-wrapper {
22
--debug-line-background: rgba(226, 236, 247, 0.5);
33
--debug-line-border: rgb(145, 188, 219);
4+
--editor-searchbar-height: 27px;
5+
--editor-second-searchbar-height: 27px;
6+
47
}
58

69
.theme-dark .editor-wrapper {
@@ -20,10 +23,6 @@
2023
--theme-conditional-breakpoint-color: #ccd1d5;
2124
}
2225

23-
.theme-firebug {
24-
--theme-conditional-breakpoint-color: #ccd1d5;
25-
}
26-
2726
.out-of-scope .CodeMirror-line,
2827
.out-of-scope .CodeMirror-linenumber {
2928
opacity: 0.8;

src/components/Editor/SearchBar.css

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
.search-bar {
22
display: flex;
33
flex-direction: column;
4-
--editor-searchbar-height: 27px;
5-
--editor-second-searchbar-height: 27px;
64
}
75

86
.search-bar .search-field {

src/components/Editor/Tabs.js

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,16 @@ function getHiddenTabs(sourceTabs: SourcesList, sourceTabEls) {
4646
return Math.min(...topOffsets);
4747
}
4848

49-
const tabTopOffset = getTopOffset();
50-
return sourceTabs.filter((tab, index) => {
49+
function hasTopOffset(el) {
5150
// adding 10px helps account for cases where the tab might be offset by
5251
// styling such as selected tabs which don't have a border.
53-
return sourceTabEls[index].getBoundingClientRect().top > tabTopOffset + 10;
52+
const tabTopOffset = getTopOffset();
53+
return el.getBoundingClientRect().top > tabTopOffset + 10;
54+
}
55+
56+
return sourceTabs.filter((tab, index) => {
57+
const element = sourceTabEls[index];
58+
return element && hasTopOffset(element);
5459
});
5560
}
5661

src/components/Outline.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class Outline extends Component {
4646

4747
return dom.li(
4848
{
49-
key: `${name}:${location.start.line}`,
49+
key: `${name}:${location.start.line}:${location.start.column}`,
5050
className: "outline-list__element",
5151
onClick: () => this.selectItem(location)
5252
},

src/components/SecondaryPanes/Expressions.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,13 @@ function getValue(expression) {
3636
};
3737
}
3838

39+
if (value.error) {
40+
return {
41+
path: value.from,
42+
value: value.error
43+
};
44+
}
45+
3946
if (typeof value.result == "object") {
4047
return {
4148
path: value.result.actor,

src/test/mochitest/head.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
* @parent mochitest
3333
*/
3434

35-
// shared-head.js handles
35+
// shared-head.js handles imports, constants, and utility functions
3636
Services.scriptloader.loadSubScript(
3737
"chrome://mochitests/content/browser/devtools/client/framework/test/shared-head.js",
3838
this

0 commit comments

Comments
 (0)