mirror of
https://github.com/hyprwm/hyprland-website.git
synced 2024-11-17 02:45:59 +01:00
pluginSlice fix fullscreen btn with sliding
This commit is contained in:
parent
8b291f8821
commit
07417aca1f
2 changed files with 20 additions and 18 deletions
|
@ -3,7 +3,6 @@
|
|||
import PlayIcon from '~icons/mingcute/play-circle-line'
|
||||
import { inview } from 'svelte-inview'
|
||||
import IconFullscreen from '~icons/mingcute/fullscreen-fill'
|
||||
import { onMount } from 'svelte'
|
||||
|
||||
/** @type {string} */
|
||||
export let src
|
||||
|
@ -55,8 +54,6 @@
|
|||
on:pause={() => (isPaused = true)}
|
||||
{autoplay}
|
||||
on:play={() => (isPaused = false)}
|
||||
on:mouseenter
|
||||
on:mouseleave
|
||||
/>
|
||||
|
||||
<button on:click={makeFullscreen} class="absolute bottom-2 left-2 z-10">
|
||||
|
|
|
@ -117,6 +117,12 @@
|
|||
'z-10 h-[20rem] min-w-0 transition-transform sm:h-[25rem] md:h-[30rem] lg:h-[37rem]',
|
||||
isHoveringVideo && '-translate-x-56'
|
||||
)}
|
||||
>
|
||||
<div
|
||||
class="h-full w-full"
|
||||
on:mouseenter={slideVideoIn}
|
||||
on:mouseleave={slideVideoOut}
|
||||
role="complementary"
|
||||
>
|
||||
{#each items as { src, poster }, index}
|
||||
<Video
|
||||
|
@ -129,10 +135,9 @@
|
|||
on:pause={pauseVideos}
|
||||
on:play={playVideos}
|
||||
videoClass="h-[inherit] aspect-video"
|
||||
on:mouseenter={slideVideoIn}
|
||||
on:mouseleave={slideVideoOut}
|
||||
/>
|
||||
{/each}
|
||||
</div>
|
||||
<div
|
||||
class="pt-5 text-sm font-medium text-slate-300 md:text-base [&>a:hover]:text-cyan-300 [&>a:hover]:underline [&>a]:font-bold"
|
||||
>
|
||||
|
|
Loading…
Reference in a new issue