fix click.stop

This commit is contained in:
Freeplay 2023-05-08 15:39:20 -04:00
parent 5cbd2a53b2
commit 09610b89cb

View file

@ -16,6 +16,7 @@
:data-count=" :data-count="
mediaList.filter((media) => previewable(media)).length mediaList.filter((media) => previewable(media)).length
" "
@click.stop
> >
<template <template
v-for="media in mediaList.filter((media) => v-for="media in mediaList.filter((media) =>
@ -26,7 +27,6 @@
v-if="media.type.startsWith('video')" v-if="media.type.startsWith('video')"
:key="media.id" :key="media.id"
:video="media" :video="media"
@click.stop
/> />
<XImage <XImage
v-else-if="media.type.startsWith('image')" v-else-if="media.type.startsWith('image')"
@ -35,7 +35,6 @@
:data-id="media.id" :data-id="media.id"
:image="media" :image="media"
:raw="raw" :raw="raw"
@click.stop
/> />
</template> </template>
</div> </div>
@ -190,6 +189,7 @@ const previewable = (file: misskey.entities.DriveFile): boolean => {
margin-top: 4px; margin-top: 4px;
border-radius: var(--radius); border-radius: var(--radius);
overflow: hidden; overflow: hidden;
pointer-events: none;
&:before { &:before {
content: ""; content: "";
@ -209,6 +209,7 @@ const previewable = (file: misskey.entities.DriveFile): boolean => {
> * { > * {
overflow: hidden; overflow: hidden;
border-radius: 6px; border-radius: 6px;
pointer-events: all;
} }
&[data-count="1"] { &[data-count="1"] {