Merge branch 'main' of git.0x2620.org:0x2620/aab21 into main

This commit is contained in:
imohkay 2021-10-26 13:30:41 +05:30
commit 24dfe95559
3 changed files with 16 additions and 2 deletions

View file

@ -58,6 +58,16 @@
padding: 20px 20px;
font-size: 22px;
line-height: 26px;
figure {
width: 100%;
text-align: center;
}
img {
margin: auto;
max-width: 100%;
}
}
}
}

View file

@ -35,7 +35,10 @@ function setVideoSrc(video, src) {
}
})
}
video.src = src.replace('.webm', videoExtension)
src = src.replace('.webm', videoExtension)
if (src != video.src) {
video.src = src
}
}
function updatePlayer(video, frame, currentTime, out, src) {
@ -216,6 +219,7 @@ function renderAnnotation(config, video, ascroll, annotation) {
if (annotation.title) {
figcaption = `<figcaption><a href="${baseURL}/${annotation.id}" target="_blank">${annotation.title}</a></figcaption>`
}
annotation.value = annotation.value.replace('src="/', `src="${baseURL}/`).replace('href="/', `href="${baseURL}/`)
div.innerHTML = `
<div class="frame">
<figure>

View file

@ -6,7 +6,7 @@
{% for text in texts %}
<div class="text">
<h1><a href="{{ text.get_absolute_url }}">{{ text.title | safe }}</a></h1>
<h2>{{ text.byline|safe }}</h2>
<h2>{{ text.byline|striptags }}</h2>
</div>
{% endfor %}
{% endblock %}