Bug 1269938 - Position cert error debug information using the body's scrollHeight. r=Gijs
MozReview-Commit-ID: FBV2z1WlxjK
--- a/browser/base/content/aboutNetError.xhtml
+++ b/browser/base/content/aboutNetError.xhtml
@@ -397,16 +397,17 @@
// Initialize the error code link embedded in the error message to
// display debug information about the cert error.
var errorCode = document.getElementById("errorCode");
if (errorCode) {
errorCode.href = "#technicalInformation";
errorCode.addEventListener("click", () => {
var div = document.getElementById("certificateErrorDebugInformation");
if (toggleDisplay(div) == "block") {
+ div.style.top = document.body.scrollHeight + "px";
div.scrollIntoView({block: "start", behavior: "smooth"});
}
}, false);
}
}
// Initialize the cert domain link.
var link = document.getElementById('cert_domain_link');
--- a/browser/themes/shared/aboutNetError.css
+++ b/browser/themes/shared/aboutNetError.css
@@ -119,17 +119,16 @@ span#hostname {
}
#certificateErrorDebugInformation {
display: none;
background-color: var(--in-content-box-background-hover) !important;
border-top: 1px solid var(--in-content-border-color);
position: absolute;
left: 0%;
- top: 100%;
width: 65%;
padding: 1em 17.5%;
}
#certificateErrorText {
font-family: monospace;
white-space: pre-wrap;
padding: 1em 0;