INNER CODE UNIT · Python
initShortcuts
gurkenlabs/litiengine · config/javadoc/generate_js.py:505
function initShortcuts() {
document.addEventListener('keydown', (e) => {
if ((e.ctrlKey || e.metaKey) && e.key.toLowerCase() === 'k') {
e.preventDefault();
const searchInput = document.getElementById('page-search-input') || document.getElementById('search-input');
if (searchInput) {
searchInput.focus();
searchInput.select();
}
}
});
}
function updateTocHeader() {
try {
document.querySelectorAll('nav.toc').forEach(tocNav => {
const tocHeader = tocNav.querySelector('.toc-header');
if (tocHeader && !tocHeader.querySelector('.toc-filter-wrapper')) {