diff --git a/browser/devtools/highlighter/inspector.jsm b/browser/devtools/highlighter/inspector.jsm index 31219064ca5a..4498e60a4589 100644 --- a/browser/devtools/highlighter/inspector.jsm +++ b/browser/devtools/highlighter/inspector.jsm @@ -1247,6 +1247,10 @@ InspectorUI.prototype = { if (computed) { computed.parentNode.removeChild(computed); } + let autosizer = node.querySelector(".autosizer"); + if (autosizer) { + autosizer.parentNode.removeChild(autosizer); + } } let text = node.textContent; diff --git a/browser/devtools/styleinspector/CssRuleView.jsm b/browser/devtools/styleinspector/CssRuleView.jsm index 8454afa5249e..179708e87030 100644 --- a/browser/devtools/styleinspector/CssRuleView.jsm +++ b/browser/devtools/styleinspector/CssRuleView.jsm @@ -1375,6 +1375,7 @@ InplaceEditor.prototype = { // up to the client), and b) without tweaking the style of the // original element, it might wrap differently or something. this._measurement = this.doc.createElementNS(HTML_NS, "span"); + this._measurement.className = "autosizer"; this.elt.parentNode.appendChild(this._measurement); let style = this._measurement.style; style.visibility = "hidden";