forked from rDrama/rDrama
dfs
parent
f70d10a3ee
commit
c9930f1402
|
@ -13,6 +13,13 @@
|
|||
{% endif %}
|
||||
|
||||
<script>
|
||||
function togglevideo(pid) {
|
||||
let vid = document.getElementById(`video-${pid}`).classList
|
||||
vid.toggle('d-none')
|
||||
let vid2 = document.getElementById(`video2-${pid}`)
|
||||
if (vid.contains('d-none')) vid2.pause()
|
||||
else vid2.play()
|
||||
}
|
||||
</script>
|
||||
|
||||
<div style="display:none" id="popover">
|
||||
|
@ -138,7 +145,7 @@
|
|||
<img alt="post thumnail" loading="lazy" src="{{p.thumb_url}}" class="post-img">
|
||||
</a>
|
||||
{% elif p.is_video %}
|
||||
<a href="javascript:void(0)" onclick="document.getElementById('video-{{p.id}}').classList.toggle('d-none');document.getElementById('video2-{{p.id}}').toggle()">
|
||||
<a href="javascript:void(0)" onclick="togglevideo({{p.id}})">
|
||||
<img alt="post thumnail" loading="lazy" src="{{p.thumb_url}}" class="post-img">
|
||||
</a>
|
||||
{% elif p.is_youtube %}
|
||||
|
|
Loading…
Reference in New Issue