forked from 0x2620/pandora
option to show user in mobile view
This commit is contained in:
parent
b8de041316
commit
4748930460
3 changed files with 10 additions and 2 deletions
|
@ -139,6 +139,10 @@ video, .poster {
|
|||
border: 1px solid blueviolet;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
.annotation .user {
|
||||
opacity: 0.75;
|
||||
}
|
||||
|
||||
@media(max-width:768px) {
|
||||
.annotation a img {
|
||||
width: 100%;
|
||||
|
|
|
@ -137,9 +137,13 @@ async function loadData(id, args) {
|
|||
/href="\//g, `href="${pandora.url.origin}/`
|
||||
)
|
||||
}
|
||||
let content = annotation.value
|
||||
if (!layerData.isSubtitles && layerData.type == "text" && args.show && args.show.includes("user")) {
|
||||
content += `\n<div class="user">— ${annotation.user}</div>`
|
||||
}
|
||||
html.push(`
|
||||
<div class="annotation ${layerData.type}" data-in="${annotation.in}" data-out="${annotation.out}">
|
||||
${annotation.value}
|
||||
${content}
|
||||
</div>
|
||||
`)
|
||||
})
|
||||
|
|
|
@ -14,7 +14,7 @@ function parseURL() {
|
|||
var kv = arg.split('=')
|
||||
k = kv.shift()
|
||||
v = kv.join('=')
|
||||
if (['users', 'layers'].includes(k)) {
|
||||
if (['users', 'layers', 'show'].includes(k)) {
|
||||
v = v.split(',')
|
||||
}
|
||||
return [k, v]
|
||||
|
|
Loading…
Reference in a new issue