click one of the methods whose name start with "$" such as $dom. This opens the function "card".
scroll down to getDocumentScroll(). (The $dom function should no longer be visible).
click on goog.math.Coordinate to load that page.
click the "back" browser button.
Result: you wind up back on the DomHelper page, but the $dom method is not open as it should be. In the Chrome browser console is this error message and stack:
dossier.js:36 Uncaught DOMException: Failed to execute 'querySelector' on 'Element': '#$dom'
is not a valid selector.
at https://google.github.io/closure-library/api/dossier.js:214:161
at Array.forEach (native)
at lh (https://google.github.io/closure-library/api/dossier.js:214:134)
at https://google.github.io/closure-library/api/dossier.js:214:390
at e.c (https://google.github.io/closure-library/api/dossier.js:45:101)
at nc (https://google.github.io/closure-library/api/dossier.js:48:195)
at ic (https://google.github.io/closure-library/api/dossier.js:48:85)
at C.l (https://google.github.io/closure-library/api/dossier.js:47:311)
at Ob (https://google.github.io/closure-library/api/dossier.js:40:42)
at <anonymous>
The error is occuring in the querySelector call in updatePageContent
updatePageContent(data, snapshot, opt_path) {
let newTitle = soy.renderAsFragment(pageTitle, {data});
let newMain = soy.renderAsFragment(mainPageContent, {data});
this.mainEl.innerHTML = '';
this.mainEl.appendChild(newMain);
document.title = newTitle.textContent;
if (snapshot) {
snapshot.getOpenCardList().forEach(id => {
let card = this.mainEl.querySelector(`#${id.replace(/\./g, '\\.')}`);
if (card) {
card.classList.add('open');
}
});
this.mainEl.parentElement.scrollTop = snapshot.getScroll();
} else {
this.mainEl.parentElement.scrollTop = 0;
}
if (opt_path) {
this.historyService_.captureSnapshot(document.title, opt_path);
}
this.initProperties();
this.updateSourceHighlight();
this.navDrawer.updateCurrent();
}
An error occurs when navigating back to a page when the open card was for a method/function whose name starts with "$".
Here are steps to reproduce. I've done this on Mac OS X with Safari and Chrome.
go to https://google.github.io/closure-library/api/goog.dom.DomHelper.html
click one of the methods whose name start with "$" such as
$dom
. This opens the function "card".scroll down to
getDocumentScroll()
. (The$dom
function should no longer be visible).click on
goog.math.Coordinate
to load that page.click the "back" browser button.
Result: you wind up back on the DomHelper page, but the
$dom
method is not open as it should be. In the Chrome browser console is this error message and stack:The error is occuring in the
querySelector
call in updatePageContent