Link cards (#1587)

Making whole cards clickable
This commit is contained in:
trean
2025-04-23 14:12:05 +02:00
committed by GitHub
parent 148f8f373f
commit b527126e5c
16 changed files with 130 additions and 45 deletions
@@ -106,4 +106,14 @@ document.addEventListener('DOMContentLoaded', function () {
if (document.getElementById('TableOfContents') && document.querySelector('.qdrant-post__body')) {
new TableOfContents('#TableOfContents', '.qdrant-post__body');
}
document.querySelectorAll('.card__content-link').forEach((link) => {
link.addEventListener('click', (e) => {
e.preventDefault();
e.stopPropagation();
const url = link.dataset.href;
window.history.pushState({}, '', url);
window.location.href = url;
});
});
});