feat: only show eintreten in beginning
This commit is contained in:
parent
fbc586371e
commit
40232189a0
@ -1,7 +1,10 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
|
import { createEventDispatcher } from 'svelte';
|
||||||
|
|
||||||
|
const dispatch = createEventDispatcher();
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<button>
|
<button on:click={() => dispatch('click')}>
|
||||||
<slot />
|
<slot />
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
@ -18,11 +21,12 @@
|
|||||||
border-style: solid;
|
border-style: solid;
|
||||||
border-width: 30px;
|
border-width: 30px;
|
||||||
border-image: url(/border.png);
|
border-image: url(/border.png);
|
||||||
|
border-color: transparent;
|
||||||
border-image-repeat: stretch;
|
border-image-repeat: stretch;
|
||||||
border-image-slice: 24% 23%;
|
border-image-slice: 24% 23%;
|
||||||
transition: border-image-slice 0.3s ease, filter 0.3s ease;
|
transition: border-image-slice 0.3s ease, filter 0.3s ease;
|
||||||
will-change: contents;
|
will-change: contents;
|
||||||
transform: translateZ(0);
|
transform: translateZ(1px);
|
||||||
}
|
}
|
||||||
|
|
||||||
button:hover {
|
button:hover {
|
||||||
|
@ -31,6 +31,6 @@
|
|||||||
onMount(async () => {
|
onMount(async () => {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
frame();
|
frame();
|
||||||
}, 5000);
|
}, 0);
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
@ -31,6 +31,8 @@
|
|||||||
.wrapper > div > :global(svg) {
|
.wrapper > div > :global(svg) {
|
||||||
overflow: visible;
|
overflow: visible;
|
||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
|
will-change: contents;
|
||||||
|
transform: translateZ(1px);
|
||||||
}
|
}
|
||||||
|
|
||||||
.wrapper > div :global(path) {
|
.wrapper > div :global(path) {
|
||||||
|
@ -3,31 +3,67 @@
|
|||||||
import Confetti from '$lib/components/confetti.svelte';
|
import Confetti from '$lib/components/confetti.svelte';
|
||||||
import Mask from '$lib/components/mask.svelte';
|
import Mask from '$lib/components/mask.svelte';
|
||||||
import Maskenball from '$lib/components/maskenball.svelte';
|
import Maskenball from '$lib/components/maskenball.svelte';
|
||||||
|
import { onMount } from 'svelte';
|
||||||
|
let curtainsIn = false;
|
||||||
|
let curtainsOut = false;
|
||||||
|
|
||||||
|
onMount(() => {
|
||||||
|
setTimeout(() => {
|
||||||
|
curtainsIn = true;
|
||||||
|
}, 2000);
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div class="background">
|
<div class="background {curtainsIn ? 'curtains-in' : ''} {curtainsOut ? 'curtains-out' : ''}">
|
||||||
<div class="drapery" />
|
<div class="drapery" />
|
||||||
<img alt="curtain left" class="curtain-right" src="/curtain.png" />
|
<img alt="curtain left" class="curtain-right" src="/curtain.png" />
|
||||||
<img alt="curtain right" class="curtain-left" src="/curtain.png" />
|
<img alt="curtain right" class="curtain-left" src="/curtain.png" />
|
||||||
</div>
|
</div>
|
||||||
<Confetti />
|
<Confetti />
|
||||||
<div class="mask-anim">
|
<div class="mask-anim">
|
||||||
<Mask />
|
<!-- <Mask /> -->
|
||||||
</div>
|
</div>
|
||||||
<Maskenball />
|
<!-- <Maskenball /> -->
|
||||||
<div class="center">
|
<div class="center">
|
||||||
<Button>Eintreten</Button>
|
<Button on:click={() => (curtainsOut = true)}>Enter the Dungeon</Button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
.background {
|
.background {
|
||||||
opacity: 0.9;
|
opacity: 0.9;
|
||||||
|
transition: transform 2s ease;
|
||||||
|
transform: scale(1);
|
||||||
|
top: 0px;
|
||||||
|
position: absolute;
|
||||||
|
width: 100vw;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.background.curtains-out {
|
||||||
|
transform: scale(4) translateY(-100vh);
|
||||||
|
}
|
||||||
|
|
||||||
.center {
|
.center {
|
||||||
display: flex;
|
display: grid;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
margin-top: 50px;
|
position: absolute;
|
||||||
|
height: 100vh;
|
||||||
|
width: 100vw;
|
||||||
|
top: 0px;
|
||||||
|
align-items: center;
|
||||||
|
animation: fadeIn 5s ease forwards;
|
||||||
|
animation-delay: 1s;
|
||||||
|
opacity: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@keyframes fadeIn {
|
||||||
|
from {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.drapery {
|
.drapery {
|
||||||
background-image: url('/drapery.png');
|
background-image: url('/drapery.png');
|
||||||
background-position: center top;
|
background-position: center top;
|
||||||
@ -37,14 +73,17 @@
|
|||||||
width: 100vw;
|
width: 100vw;
|
||||||
height: 300px;
|
height: 300px;
|
||||||
background-repeat: repeat-x;
|
background-repeat: repeat-x;
|
||||||
background-size: 500px;
|
background-size: 600px 200px;
|
||||||
z-index: 3;
|
z-index: 3;
|
||||||
filter: brightness(1.2) contrast(1.2) saturate(1.3) hue-rotate(-15deg)
|
filter: brightness(1.2) contrast(1.2) saturate(1.3) hue-rotate(-15deg)
|
||||||
drop-shadow(0px 0px 50px black);
|
drop-shadow(0px 0px 50px black);
|
||||||
animation: draperyIn 2s 2s ease forwards;
|
|
||||||
animation-delay: 2s;
|
|
||||||
transform: translateY(-500px) scaleY(0);
|
transform: translateY(-500px) scaleY(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.curtains-in .drapery {
|
||||||
|
animation: draperyIn 2s ease forwards;
|
||||||
|
}
|
||||||
|
|
||||||
@keyframes draperyIn {
|
@keyframes draperyIn {
|
||||||
from {
|
from {
|
||||||
transform: translateY(-500px) scaleY(0);
|
transform: translateY(-500px) scaleY(0);
|
||||||
@ -60,10 +99,14 @@
|
|||||||
width: 400px;
|
width: 400px;
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
filter: brightness(0.8) contrast(1.1) saturate(0.6);
|
filter: brightness(0.8) contrast(1.1) saturate(0.6);
|
||||||
animation: moveInRight 2s ease forwards;
|
animation-delay: 0s;
|
||||||
animation-delay: 2s;
|
|
||||||
transform: translateX(120%) rotate(-10deg);
|
transform: translateX(120%) rotate(-10deg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.curtains-in .curtain-right {
|
||||||
|
animation: moveInRight 2s ease forwards;
|
||||||
|
}
|
||||||
|
|
||||||
@keyframes moveInRight {
|
@keyframes moveInRight {
|
||||||
from {
|
from {
|
||||||
transform: translateX(120%) rotate(-10deg);
|
transform: translateX(120%) rotate(-10deg);
|
||||||
@ -83,11 +126,14 @@
|
|||||||
width: 400px;
|
width: 400px;
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
filter: brightness(0.8) contrast(1.1) saturate(0.6);
|
filter: brightness(0.8) contrast(1.1) saturate(0.6);
|
||||||
animation: moveInLeft 2s ease forwards;
|
animation-delay: 0s;
|
||||||
animation-delay: 2s;
|
|
||||||
transform: translateX(-120%) rotate(10deg) scaleX(-1);
|
transform: translateX(-120%) rotate(10deg) scaleX(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.curtains-in .curtain-left {
|
||||||
|
animation: moveInLeft 2s ease forwards;
|
||||||
|
}
|
||||||
|
|
||||||
@keyframes moveInLeft {
|
@keyframes moveInLeft {
|
||||||
from {
|
from {
|
||||||
transform: translateX(-120%) rotate(10deg) scaleX(-1);
|
transform: translateX(-120%) rotate(10deg) scaleX(-1);
|
||||||
|
Loading…
Reference in New Issue
Block a user