Skip to content

Herk Edit Kit by Nate Herk: edit videos, reels, and YouTube Shorts with Codex or Claude Code. 15 skills, transcript-driven cuts, storytelling, 406 motion-graphics cards, and HyperFrames templates.

3.6 KB
Raw Blame
<template id="beat-2-text-template">
  <div
    data-composition-id="beat-2-text"
    data-start="0"
    data-duration="1.99"
    data-width="1920"
    data-height="1080"
  >
    <!-- Top-of-frame single-row layout: kicker + headline inline, so the text
         lives above Nate's face instead of crossing it. -->
    <div class="b2-wrap">
      <div class="b2-kicker">ON-SCREEN TEXT · DEMO</div>
      <div class="b2-headline">TEXT ON SCREEN</div>
    </div>

    <!-- Whip streak that covers the entrance cut. -->
    <div class="b2-whip"></div>

    <style>
      [data-composition-id="beat-2-text"] {
        position: absolute;
        inset: 0;
        overflow: hidden;
        font-family: "Inter", sans-serif;
      }
      [data-composition-id="beat-2-text"] .b2-wrap {
        position: absolute;
        top: 48px;
        left: 50%;
        transform: translateX(-50%);
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 24px;
      }
      [data-composition-id="beat-2-text"] .b2-kicker {
        font-family: "JetBrains Mono", monospace;
        font-size: 20px;
        font-weight: 600;
        letter-spacing: 0.34em;
        color: #d97757;
        text-shadow: 0 0 14px rgba(217, 119, 87, 0.6);
      }
      [data-composition-id="beat-2-text"] .b2-headline {
        font-size: 68px;
        font-weight: 900;
        letter-spacing: -0.02em;
        line-height: 1;
        white-space: nowrap;
        background: linear-gradient(180deg, #ffffff 0%, #b8b8b8 60%, #f1f1f1 100%);
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
        text-shadow:
          0 0 26px rgba(255, 255, 255, 0.4),
          0 0 52px rgba(255, 255, 255, 0.18);
      }
      [data-composition-id="beat-2-text"] .b2-whip {
        position: absolute;
        top: 200px;
        left: -200px;
        width: 700px;
        height: 14px;
        background: linear-gradient(90deg,
          transparent, rgba(255,255,255,0.95), transparent);
        filter: blur(8px);
        opacity: 0;
      }
    </style>

    <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/gsap.min.js"></script>
    <script>
      (() => {
        window.__timelines = window.__timelines || {};
        const tl = gsap.timeline({ paused: true });
        const root = '[data-composition-id="beat-2-text"]';

        // Local 0.00 == master 3.95. Word "text" lands at master 4.36 == local 0.41.
        // Slam timing: whip streak peaks at local 0.35, content lands at 0.41.

        // Whip first — ripples across from left to right, peaks mid-frame.
        tl.set(`${root} .b2-whip`, { xPercent: 0, opacity: 0 }, 0);
        tl.to(`${root} .b2-whip`,
          { xPercent: 220, opacity: 1, duration: 0.22, ease: "power3.in" }, 0.20);
        tl.to(`${root} .b2-whip`,
          { opacity: 0, duration: 0.12, ease: "power2.out" }, 0.42);

        // Kicker slides in from the left, slightly ahead of the slam.
        tl.from(`${root} .b2-kicker`,
          { x: -30, opacity: 0, duration: 0.32, ease: "expo.out" }, 0.28);

        // Headline SLAM — lands on word "text" (local 0.41). Scale-down +
        // motion-blur entrance: feels like it punches through from behind.
        // Tightened overshoot (1.4 instead of 1.8) since the 68px headline on
        // a single row doesn't need as much travel to feel like a slam.
        tl.from(`${root} .b2-headline`,
          { scale: 1.4, opacity: 0, filter: "blur(18px)",
            duration: 0.45, ease: "power4.out" }, 0.34);

        // Duration anchor.
        tl.to({}, { duration: 1.99 }, 0);
        window.__timelines["beat-2-text"] = tl;
      })();
    </script>
  </div>
</template>