@@ -438,6 +438,10 @@ const signIn = () =>
438438 connection .value ?.().signal .next (ClubsConnectionSignal .SignInRequest )
439439
440440onMounted (async () => {
441+ // setTimeout(() => {
442+ // stakeSuccessful.value = true
443+ // }, 2000)
444+
441445 const { connection : _connection } = await import (' ../../../connection' )
442446 connection .value = _connection
443447
@@ -587,29 +591,36 @@ onUnmounted(() => {
587591 <div
588592 class =" grid grid-cols-[auto_auto_1fr] items-center justify-between gap-4"
589593 >
590- <span
591- v-if =" !previewImageSrc && previewVideoSrc"
592- class =" w-36 rounded-lg border border-black/20 bg-black/10 p-1"
593- >
594- <VideoFetch
595- :url =" previewVideoSrc"
596- :videoClass =" `w-full rounded aspect-square`"
597- />
598- </span >
594+ <span class =" contents" >
595+ <!-- This uses CSS instead of Vue's slot fallback content because Astro always inserts an empty element into the slot. -->
596+ <span class =" peer contents" >
597+ <slot name =" preview" />
598+ </span >
599+ <span class =" contents peer-has-[:not(:empty)]:hidden" >
600+ <span
601+ v-if =" !previewImageSrc && previewVideoSrc"
602+ class =" w-36 rounded-lg border border-black/20 bg-black/10 p-1"
603+ >
604+ <VideoFetch
605+ :url =" previewVideoSrc"
606+ :videoClass =" `w-full rounded aspect-square`"
607+ />
608+ </span >
599609
600- <span
601- v-if =" !previewVideoSrc"
602- class =" h-auto min-h-24 w-24 rounded-lg border border-black/20 bg-black/10 p-1"
603- >
604- <img
605- v-if =" previewImageSrc"
606- ref =" imageRef"
607- class =" h-auto w-full rounded-lg object-cover object-center"
608- />
609- <Skeleton
610- v-if =" previewImageSrc === undefined"
611- class =" mx-auto aspect-square h-full w-full"
612- />
610+ <span
611+ v-if =" !previewVideoSrc"
612+ class =" h-auto min-h-24 w-24 rounded-lg border border-black/20 bg-black/10 p-1"
613+ >
614+ <img
615+ v-if =" previewImageSrc"
616+ ref =" imageRef"
617+ class =" h-auto w-full rounded-lg object-cover object-center"
618+ />
619+ <Skeleton
620+ v-if =" previewImageSrc === undefined"
621+ class =" mx-auto aspect-square h-full w-full"
622+ /> </span
623+ ></span >
613624 </span >
614625 <h3 class =" text-balance break-all font-bold" >{{ previewName }}</h3 >
615626 <span class =" justify-self-end" >
@@ -905,6 +916,9 @@ onUnmounted(() => {
905916 :video-src =" previewVideoSrc"
906917 :base =" props.base"
907918 >
919+ <template #preview >
920+ <slot name =" result:preview" />
921+ </template >
908922 <template #before :preview >
909923 <slot name =" result:before:preview" />
910924 </template >
0 commit comments