2023-07-10 10:15:17 +02:00
|
|
|
<script>
|
2023-08-17 16:45:47 +02:00
|
|
|
import { getIsMobile } from '$lib/Helper.mjs'
|
2023-07-10 10:15:17 +02:00
|
|
|
import Button from '$lib/components/Button.svelte'
|
2023-08-17 16:45:47 +02:00
|
|
|
import Logo from '$lib/images/logos/hyprland-color.svg'
|
|
|
|
import { onMount } from 'svelte'
|
2023-07-10 10:15:17 +02:00
|
|
|
import Firefly from './Firefly.svelte'
|
|
|
|
import { inview } from 'svelte-inview'
|
|
|
|
|
|
|
|
let isVisible = true
|
2023-08-17 16:45:47 +02:00
|
|
|
let isMobile = false
|
|
|
|
|
|
|
|
onMount(() => {
|
|
|
|
isMobile = getIsMobile()
|
|
|
|
})
|
2023-07-10 10:15:17 +02:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<section
|
2023-08-17 16:45:47 +02:00
|
|
|
class="w-full relative flex flex-col items-center justify-center min-h-[100svh] overflow-x-hidden h-max"
|
2023-07-10 10:15:17 +02:00
|
|
|
use:inview
|
2023-07-22 20:44:24 +02:00
|
|
|
on:inview_change={({ detail: { inView } }) => {
|
2023-07-10 10:15:17 +02:00
|
|
|
isVisible = inView
|
|
|
|
}}
|
|
|
|
>
|
|
|
|
<!-- Hero text and logo -->
|
|
|
|
<div class="flex h-screen min-h-max justify-center flex-col items-center z-10">
|
2023-08-17 16:45:47 +02:00
|
|
|
<div class="text-center -mt-20 items-center flex flex-col gap-6 mb-8">
|
|
|
|
<img src={Logo} alt="Hyprland Logo" class="h-36 mb-4 ani-in fill-mode-backwards" />
|
2023-07-22 20:44:24 +02:00
|
|
|
<div class="relative ani-in fill-mode-backwards [animation-delay:584ms]">
|
2023-08-05 20:33:07 +02:00
|
|
|
<h1
|
2023-08-17 16:45:47 +02:00
|
|
|
class="text-5xl md:text-7xl p-2 font-bold bg-clip-text text-transparent font-london hyprgradient tracking-wider md:tracking-widest"
|
2023-08-05 20:33:07 +02:00
|
|
|
>
|
|
|
|
Hyprland
|
|
|
|
</h1>
|
2023-07-10 10:15:17 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<h2
|
2023-07-31 11:32:19 +02:00
|
|
|
class="ani-in text-center mb-10 [animation-delay:944ms] fill-mode-backwards font-medium text-xl text-blue-200/60"
|
2023-07-10 10:15:17 +02:00
|
|
|
>
|
|
|
|
Dynamic tiling Wayland compositor<br />with the looks.
|
|
|
|
</h2>
|
|
|
|
|
|
|
|
<div
|
2023-07-22 20:44:24 +02:00
|
|
|
class="flex gap-6 items-center animate-in fade-in-0 slide-in-from-bottom-4 [animation-delay:1390ms] duration-500 fill-mode-backwards"
|
2023-07-10 10:15:17 +02:00
|
|
|
>
|
|
|
|
<a href="https://wiki.hyprland.org/Getting-Started/Installation/">
|
|
|
|
<Button size="lg">Install</Button>
|
|
|
|
</a>
|
2023-08-17 16:45:47 +02:00
|
|
|
<a href="https://wiki.hyprland.org/Getting-Started/">
|
|
|
|
<Button type="fancyOutline" size="lg">Wiki</Button>
|
|
|
|
</a>
|
2023-07-10 10:15:17 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- Fireflies -->
|
|
|
|
{#if isVisible}
|
|
|
|
<div
|
2023-08-17 16:45:47 +02:00
|
|
|
class="absolute animate-in fade-in-0 [animation-delay:900ms] [animation-duration:4500ms] fill-mode-backwards pointer-events-none max-w-screen inset-0 overflow-hidden -z-10"
|
2023-07-10 10:15:17 +02:00
|
|
|
>
|
2023-07-22 20:44:24 +02:00
|
|
|
<div class="bg-gradient-to-t from-black z-10 w-full h-52 absolute bottom-0" />
|
2023-07-10 10:15:17 +02:00
|
|
|
|
2023-08-17 16:45:47 +02:00
|
|
|
{#each { length: 40 } as _}
|
|
|
|
<Firefly />
|
|
|
|
{/each}
|
2023-07-10 10:15:17 +02:00
|
|
|
</div>
|
|
|
|
{/if}
|
|
|
|
|
|
|
|
<!-- Gradient background -->
|
|
|
|
<div
|
2023-07-22 20:44:24 +02:00
|
|
|
class="absolute -z-50 max-w-screen w-screen min-h-screen h-full right-0 top-0 overflow-hidden"
|
2023-07-10 10:15:17 +02:00
|
|
|
>
|
|
|
|
<div class="absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2">
|
|
|
|
<div
|
|
|
|
class="bg-gradient-radial via-emerald-300/0 to-emerald-200/0 from-sky-400/20 bg"
|
|
|
|
style="--seed: 20;"
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
<div class="absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2">
|
|
|
|
<div
|
|
|
|
class="bg-gradient-radial to-cyan-400/0 from-blue-500/10 bg"
|
|
|
|
style="--offset: -3s; --seed: 4; --duration:102s"
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</section>
|
|
|
|
|
|
|
|
<style lang="postcss">
|
|
|
|
.bg {
|
|
|
|
width: calc(120vw + 500px);
|
|
|
|
height: calc(120vh + 500px);
|
|
|
|
|
|
|
|
animation: move var(--duration, 50s) ease-in-out var(--offset, 0ms) infinite alternate both;
|
|
|
|
}
|
|
|
|
|
|
|
|
@keyframes move {
|
|
|
|
0% {
|
|
|
|
transform: translate3d(
|
|
|
|
calc(10vw * sin(var(--seed, 1))),
|
|
|
|
calc(20vh * sin(var(--seed, 1))),
|
|
|
|
0px
|
|
|
|
);
|
|
|
|
}
|
|
|
|
30% {
|
|
|
|
transform: translate3d(
|
|
|
|
calc(-20vw * sin(var(--seed, 1))),
|
|
|
|
calc(12vh * sin(var(--seed, 1))),
|
|
|
|
0px
|
|
|
|
);
|
|
|
|
}
|
|
|
|
70% {
|
|
|
|
transform: translate3d(
|
|
|
|
calc(-230px * sin(var(--seed, 1))),
|
|
|
|
calc(-160px * sin(var(--seed, 1))),
|
|
|
|
0px
|
|
|
|
);
|
|
|
|
opacity: sin(var(--seed, 1));
|
|
|
|
}
|
|
|
|
to {
|
|
|
|
transform: translate3d(
|
|
|
|
calc(50px * sin(var(--seed, 1))),
|
|
|
|
calc(200px * sin(var(--seed, 1))),
|
|
|
|
0px
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
@keyframes slidein {
|
|
|
|
from {
|
|
|
|
transform: translateX(0%);
|
|
|
|
}
|
|
|
|
|
|
|
|
to {
|
|
|
|
transform: translateX(100%);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.ani-in {
|
2023-08-17 16:45:47 +02:00
|
|
|
@apply animate-in fade-in-0 slide-in-from-bottom-4 ease-in-out [animation-duration:800ms];
|
2023-07-10 10:15:17 +02:00
|
|
|
}
|
|
|
|
</style>
|