Files
o2o-weather/admin/reels/intro/compositions/s7.html
T

35 lines
2.8 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: #e3efff; color: #28304a; }
#s7-world { position: absolute; inset: 0; }
#s7-title { position: absolute; left: 90px; top: 230px; width: 900px; font: 400 112px/1.18 'Jua', sans-serif; letter-spacing: -2px; word-break: keep-all; }
#s7-title .w { display: inline-block; margin-right: 0.22em; }
#s7-phone { position: absolute; left: 180px; top: 560px; width: 720px; height: 1500px; padding: 22px; border: 12px solid #28304a; border-radius: 88px; background: #28304a; box-shadow: 0 30px 70px rgba(40, 48, 74, 0.3); overflow: hidden; }
#s7-phone img { display: block; width: 100%; border-radius: 52px; }
#s7-chip { position: absolute; left: 560px; top: 480px; padding: 18px 36px; border-radius: 28px; background: #d4552a; color: #fff; font: 800 56px/1 'Pretendard', sans-serif; letter-spacing: -1px; box-shadow: 0 12px 34px rgba(212, 85, 42, 0.35); white-space: nowrap; transform-origin: 50% 50%; z-index: 2; }
#s7-note { position: absolute; left: 90px; top: 500px; font: 600 36px/1 'Pretendard', sans-serif; color: #546078; }
</style>
<div id="root" data-composition-id="s7" data-width="1080" data-height="1920">
<div id="s7-world" class="clip" data-start="0" data-duration="3" data-layout-allow-overlap>
<h1 id="s7-title"><span class="w">지금</span><span class="w">내</span><span class="w">동네</span><br /><span class="w">1위는?</span></h1>
<div id="s7-phone"><img src="assets/img/shot-home.webp" alt="날씨각 홈 화면" /></div>
<div id="s7-chip">68가지 각</div>
<p id="s7-note">실제 화면 · 10.24 마포구</p>
</div>
</div>
<script>
const tl = gsap.timeline({ paused: true });
// 진짜 홈 화면이 아래서 올라오고, 제목이 맺히고, 68가지 칩이 튕김
tl.fromTo("#s7-phone", { y: 1400 }, { y: 0, duration: 0.7, ease: "power4.out" }, 0.05);
tl.fromTo("#s7-title .w", { opacity: 0, filter: "blur(8px)" }, { opacity: 1, filter: "blur(0px)", duration: 0.13, ease: "power4.out", stagger: 0.07 }, 0.4);
tl.fromTo("#s7-chip", { scale: 0.4, opacity: 0, rotate: -8 }, { scale: 1, opacity: 1, rotate: -6, duration: 0.45, ease: "back.out(1.6)" }, 1.2);
tl.fromTo("#s7-note", { opacity: 0 }, { opacity: 1, duration: 0.2, ease: "power2.out" }, 0.6);
// 폰이 아래로 빠지며 엔드카드로
tl.to("#s7-phone", { y: 1500, duration: 0.3, ease: "power3.in" }, 2.7);
tl.to(["#s7-title", "#s7-chip", "#s7-note"], { opacity: 0, filter: "blur(8px)", duration: 0.2, ease: "power3.in" }, 2.75);
window.__timelines["s7"] = tl;
</script>
</template>