40 lines
3.0 KiB
HTML
40 lines
3.0 KiB
HTML
<template>
|
|
<style>
|
|
@font-face { font-family: 'Jua'; src: url('assets/fonts/Jua-Regular.ttf'); }
|
|
@font-face { font-family: 'Pretendard'; src: url('assets/fonts/PretendardVariable.woff2'); font-weight: 100 900; }
|
|
#root { position: absolute; inset: 0; overflow: hidden; background: #cfe3fb; color: #fff; }
|
|
#s5-world { position: absolute; inset: 0; }
|
|
#s5-cam { position: absolute; inset: 0; transform-origin: 50% 50%; }
|
|
#s5-bg { position: absolute; left: 0; top: 0; width: 1080px; height: 1920px; object-fit: cover; }
|
|
#s5-walk { position: absolute; left: 620px; top: 1140px; width: 300px; }
|
|
#s5-chip { position: absolute; left: 90px; top: 560px; display: flex; align-items: center; gap: 22px; padding: 22px 40px 22px 24px; border-radius: 32px; background: #fff; color: #28304a; box-shadow: 0 12px 34px rgba(40, 48, 74, 0.28); transform-origin: 0% 50%; }
|
|
#s5-chip img { width: 110px; height: 110px; }
|
|
#s5-chip .n { font: 800 54px/1 'Pretendard', sans-serif; letter-spacing: -1px; white-space: nowrap; }
|
|
#s5-chip .v { font: 800 92px/1 'Pretendard', sans-serif; color: #d4552a; letter-spacing: -2px; min-width: 120px; text-align: right; }
|
|
#s5-line { position: absolute; left: 90px; top: 760px; width: 900px; font: 400 76px/1.2 'Jua', sans-serif; letter-spacing: -1px; color: #28304a; text-shadow: 0 0 22px rgba(255, 255, 255, 0.85), 0 4px 14px rgba(255, 255, 255, 0.6); word-break: keep-all; }
|
|
</style>
|
|
<div id="root" data-composition-id="s5" data-width="1080" data-height="1920">
|
|
<div id="s5-world" class="clip" data-start="0" data-duration="2">
|
|
<div id="s5-cam">
|
|
<img id="s5-bg" src="assets/bg/mountain.webp" alt="" />
|
|
<img id="s5-walk" src="assets/icons/walk.png" alt="" />
|
|
<div id="s5-chip"><img src="assets/icons/walk.png" alt="" /><span class="n">산책각</span><span class="v" id="s5-score">0</span></div>
|
|
<p id="s5-line">숲길 산책 딱 좋은 날</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<script>
|
|
const tl = gsap.timeline({ paused: true });
|
|
tl.fromTo("#s5-cam", { y: 420, filter: "blur(16px)", scale: 1.12 }, { y: 0, filter: "blur(0px)", duration: 0.25, ease: "expo.out" }, 0);
|
|
tl.to("#s5-cam", { scale: 1.06, duration: 1.5, ease: "power2.inOut" }, 0.25);
|
|
// 산책 아이콘: 걷는 듯 위아래 (유한 반복)
|
|
tl.fromTo("#s5-walk", { y: 0, x: 20 }, { y: -8, x: -30, duration: 0.4, ease: "sine.inOut", repeat: 4, yoyo: true }, 0);
|
|
tl.fromTo("#s5-chip", { scale: 0.5, x: -80, opacity: 0 }, { scale: 1, x: 0, opacity: 1, duration: 0.45, ease: "back.out(1.6)" }, 0.2);
|
|
const score = { v: 0 };
|
|
tl.to(score, { v: 81, duration: 0.6, ease: "power2.out", onUpdate: () => { document.getElementById("s5-score").textContent = Math.round(score.v); } }, 0.3);
|
|
tl.fromTo("#s5-line", { opacity: 0, filter: "blur(8px)" }, { opacity: 1, filter: "blur(0px)", duration: 0.2, ease: "power4.out" }, 0.28);
|
|
tl.to("#s5-cam", { y: -420, filter: "blur(16px)", duration: 0.18, ease: "power3.in" }, 1.84);
|
|
window.__timelines["s5"] = tl;
|
|
</script>
|
|
</template>
|