We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6622111 commit f5efd2aCopy full SHA for f5efd2a
src/librustdoc/html/static/js/main.js
@@ -302,11 +302,10 @@ function preLoadCss(cssUrl) {
302
window.searchState.timeout = null;
303
}
304
},
305
- // @ts-expect-error
306
isDisplayed: () => {
307
const outputElement = window.searchState.outputElement();
308
- return outputElement &&
309
- outputElement.parentElement &&
+ return !!outputElement &&
+ !!outputElement.parentElement &&
310
outputElement.parentElement.id === ALTERNATIVE_DISPLAY_ID;
311
312
// Sets the focus on the search bar at the top of the page
0 commit comments