From 98d6b482fd9da9f79033f906f9f0be7531fda4f1 Mon Sep 17 00:00:00 2001 From: j Date: Mon, 25 Oct 2021 16:11:50 +0100 Subject: [PATCH] images --- app/static/css/partials/_ascroll.scss | 10 ++++++++++ app/static/js/ascroll.js | 1 + 2 files changed, 11 insertions(+) diff --git a/app/static/css/partials/_ascroll.scss b/app/static/css/partials/_ascroll.scss index be1dfbd..523779b 100755 --- a/app/static/css/partials/_ascroll.scss +++ b/app/static/css/partials/_ascroll.scss @@ -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%; + } } } } diff --git a/app/static/js/ascroll.js b/app/static/js/ascroll.js index c0de32b..271b3d2 100644 --- a/app/static/js/ascroll.js +++ b/app/static/js/ascroll.js @@ -219,6 +219,7 @@ function renderAnnotation(config, video, ascroll, annotation) { if (annotation.title) { figcaption = `
${annotation.title}
` } + annotation.value = annotation.value.replace('src="/', `src="${baseURL}/`).replace('href="/', `href="${baseURL}/`) div.innerHTML = `