Add license information
This commit is contained in:
@ -35,6 +35,20 @@
|
||||
$str('author'):
|
||||
"unknown author"):
|
||||
$str('author');
|
||||
$: hrefLicense = album && album.license ? (
|
||||
typeof album.license === 'object' ?
|
||||
`${base}/license`:
|
||||
typeof album.license === 'string' ?
|
||||
`${galleryBase}/license/${album.license}`:
|
||||
null):
|
||||
null;
|
||||
$: displayLicense = album && album.license ? (
|
||||
typeof album.license === 'object' ?
|
||||
album.license.title:
|
||||
typeof album.license === 'string' ?
|
||||
((l: any) => l ? $strf(l.titleShort || l.title) : album?.license)(licenses.find(l => l.type === album?.license)):
|
||||
"All rights reserved"):
|
||||
"All rights reserved";
|
||||
</script>
|
||||
|
||||
<header>
|
||||
@ -53,12 +67,12 @@
|
||||
<dt>{displayAuthorsTitle}</dt>
|
||||
<dd>{displayAuthors}</dd>
|
||||
<dt>{$str('license')}</dt>
|
||||
<dd><a href={`${base}/license`} tabindex="0">{album.license}</a></dd>
|
||||
<dd><a href={hrefLicense} tabindex="0">{displayLicense}</a></dd>
|
||||
</dl>
|
||||
<menu>
|
||||
{#if album.allowDownload !== false}
|
||||
<li>
|
||||
<a href={`${base}/download`} tabindex="0">{$str('download-all')}</a>
|
||||
<a data-sveltekit-reload href={`${base}/download`} tabindex="0">{$str('download-all')}</a>
|
||||
</li>
|
||||
{/if}
|
||||
</menu>
|
||||
|
||||
Reference in New Issue
Block a user