|
|
@ -36,6 +36,12 @@ import { EmbeddedFile, EMBED_TYPES } from './main'; |
|
|
|
a.click(); |
|
|
|
window.URL.revokeObjectURL(url); |
|
|
|
} |
|
|
|
|
|
|
|
let black = new Set<string>(); |
|
|
|
settings.subscribe(s => { |
|
|
|
black = new Set(s.blacklist); |
|
|
|
}); |
|
|
|
let blackHits = files.filter(file => file.tags?.some(e => black.has(e)) ?? false) ?? ['']; |
|
|
|
</script> |
|
|
|
|
|
|
|
{#if $settings.eye} |
|
|
@ -78,11 +84,25 @@ import { EmbeddedFile, EMBED_TYPES } from './main'; |
|
|
|
class:hasblack={file?.isBlacklisted === true} |
|
|
|
>{file.page.title}</a> |
|
|
|
{/if} |
|
|
|
{#if file.tags} |
|
|
|
<!-- svelte-ignore a11y-missing-content --> |
|
|
|
<details class="tags"> |
|
|
|
<summary |
|
|
|
class:hasembed={file?.embed_type === EMBED_TYPES.MEDIA_EMBED} |
|
|
|
class:hasext={file?.embed_type === EMBED_TYPES.THIRD_EYE} |
|
|
|
class:hasblack={file?.isBlacklisted === true} |
|
|
|
>Tags</summary> |
|
|
|
<ul> |
|
|
|
{#each file.tags as tag} |
|
|
|
<li class:hasblack-bg={black.has(tag)}>{tag}</li> |
|
|
|
{/each} |
|
|
|
</ul> |
|
|
|
</details> |
|
|
|
{/if} |
|
|
|
{#if isNotChrome && isVideo} |
|
|
|
<!-- svelte-ignore a11y-missing-attribute --> |
|
|
|
<a on:click={(ev) => { |
|
|
|
inst.bepis(ev); |
|
|
|
}} alt="By clicking this you agree to stay hydrated" |
|
|
|
<a on:click={(ev) => { inst.bepis(ev); }} |
|
|
|
alt="By clicking this you agree to stay hydrated" |
|
|
|
class="clickable" |
|
|
|
class:hasembed={file?.embed_type === EMBED_TYPES.MEDIA_EMBED} |
|
|
|
class:hasext={file?.embed_type === EMBED_TYPES.THIRD_EYE} |
|
|
@ -102,18 +122,30 @@ import { EmbeddedFile, EMBED_TYPES } from './main'; |
|
|
|
margin-right: 2px; |
|
|
|
} |
|
|
|
|
|
|
|
.clickable:hover { |
|
|
|
text-shadow: 0 0 4px palevioletred; |
|
|
|
} |
|
|
|
.clickable.hasembed { |
|
|
|
.hasembed { |
|
|
|
color: deeppink; |
|
|
|
} |
|
|
|
.clickable.hasext { |
|
|
|
.hasext { |
|
|
|
color: goldenrod; |
|
|
|
} |
|
|
|
.clickable.hasblack { |
|
|
|
.hasblack { |
|
|
|
color: black; |
|
|
|
} |
|
|
|
|
|
|
|
/* |
|
|
|
.hasembed-bg { |
|
|
|
background-color: deeppink; |
|
|
|
} |
|
|
|
.hasext-bg { |
|
|
|
background-color: goldenrod; |
|
|
|
} |
|
|
|
*/ |
|
|
|
.hasblack-bg { |
|
|
|
background-color: black; |
|
|
|
} |
|
|
|
.clickable:hover { |
|
|
|
text-shadow: 0 0 4px palevioletred; |
|
|
|
} |
|
|
|
a.clickable.hasembed { |
|
|
|
color: deeppink !important; |
|
|
|
} |
|
|
@ -123,4 +155,21 @@ import { EmbeddedFile, EMBED_TYPES } from './main'; |
|
|
|
a.clickable.hasblack { |
|
|
|
color: black !important; |
|
|
|
} |
|
|
|
|
|
|
|
details.tags { |
|
|
|
display: inline-block; |
|
|
|
} |
|
|
|
.tags > ul { |
|
|
|
position: absolute; |
|
|
|
min-width: 35px; |
|
|
|
|
|
|
|
list-style: none; |
|
|
|
margin-top: 2px; |
|
|
|
padding: 0; |
|
|
|
background-color: #00000044; |
|
|
|
} |
|
|
|
.tags > ul > li { |
|
|
|
padding: 2px 2px; |
|
|
|
margin-bottom: 2px; |
|
|
|
} |
|
|
|
</style> |
|
|
|