fix relative img/href links
This commit is contained in:
parent
2bf9deb42c
commit
6c22fa70de
1 changed files with 5 additions and 0 deletions
|
@ -114,6 +114,11 @@ async function loadData(id, args) {
|
|||
${layerData.title}
|
||||
</h3>`)
|
||||
data.layers[layer].forEach(annotation => {
|
||||
annotation.value = annotation.value.replace(
|
||||
/src="\//g, `src="${pandora.url.origin}/`
|
||||
).replace(
|
||||
/href="\//g, `href="${pandora.url.origin}/`
|
||||
)
|
||||
html.push(`
|
||||
<div class="annotation ${layerData.type}" data-in="${annotation.in}" data-out="${annotation.out}">
|
||||
${annotation.value}
|
||||
|
|
Loading…
Reference in a new issue