mirror of
https://github.com/TeamNewPipe/website
synced 2025-10-06 00:22:38 +02:00
20 lines
631 B
JavaScript
20 lines
631 B
JavaScript
---
|
|
# yaml header to enable parsing
|
|
# without this header, the {{ site.url }} is not parsed
|
|
#// noinspection JSAnnotator
|
|
---
|
|
$(document).ready(function() {
|
|
/*
|
|
Make single post tiles clickable
|
|
*/
|
|
$('.border-box').click(function (event) {
|
|
if (event.target.nodeName === 'a' || event.target.nodeName === 'A'
|
|
|| event.target.tagName === 'a' || event.target.tagName === 'A') {
|
|
return;
|
|
}
|
|
let url = $(this).attr('data-href');
|
|
if (url !== undefined && url != null && url !== "" && url.startsWith("{{ site.url }}"))
|
|
window.location.href = url;
|
|
});
|
|
});
|