Page sections / Heroes

Painterly Backdrop App-Window Hero

Left-aligned 22px headline over pill buttons (solid ink and soft gray), then a wide 16:9 framed panel with a muted impressionist landscape painting as full-bleed backdrop. Overlapping macOS-style app windows (three-pane desktop agent, terminal CLI window) with traffic-light dots and heavy soft shadows sit on top; a cookie banner floats in the corner.

Rebuilt from cursor.com in the Warm Paper Editorial style.

npx shadcn@latest add https://justyoink.it/r/warm-paper-editorial/blocks/app-window-hero.json

Looks exactly like cursor.com: brings its fonts and colours, namespaced so your own theme stays untouched.

ImagesSwap it for a library image or one of your own.All images in this style →

Choose an image

Image

Loading…

Usage

Props: headline, primaryLabel, secondaryLabel, imageSrc (backdrop painting, defaults to a stock landscape). Renders standalone with no props.

components/app-window-hero.tsx
"use client";

import { useEffect, useLayoutEffect, useRef, useState, type CSSProperties, type ElementType, type ReactNode, type RefObject } from "react";
export default function PainterlyBackdropAppWindowHero({
  headline = "Meet Quillfern, the writing assistant for thoughtful teams.",
  primaryLabel = "Get the app",
  secondaryLabel = "Book a tour →",
  imageSrc = "https://yoink-app.fly.dev/stock/landscape-4.jpg",
}: {
  headline?: string;
  primaryLabel?: string;
  secondaryLabel?: string;
  imageSrc?: string;
}) {
  const tasks = [
    { t: "Draft spring newsletter", s: "Outline ready for review", time: "now" },
    { t: "Tidy onboarding guide", s: "+12 -4 · Edited headings", time: "now" },
    { t: "Translate help articles", s: "Queued for proofreading", time: "10m" },
    { t: "Refresh pricing page", s: "Waiting on figures", time: "30m" },
  ];
  const dots = (
    <div className="flex gap-1.5" aria-hidden>
      <span className="h-2.5 w-2.5 rounded-full bg-hairline" />
      <span className="h-2.5 w-2.5 rounded-full bg-hairline" />
      <span className="h-2.5 w-2.5 rounded-full bg-hairline" />
    </div>
  );
  return (
    <section className="bg-canvas px-4 py-12 text-ink sm:px-8 md:px-[70px] md:py-20">
      <h1 className="max-w-md text-[22px] leading-[1.5] tracking-[-0.01em]">{headline}</h1>
      <div className="mt-6 flex flex-wrap gap-3">
        <a href="#" className="rounded-pill border border-ink bg-ink px-6 py-3 text-ui text-canvas transition-colors duration-hover-color ease-hover-color hover:border-[#3b3a33] hover:bg-[#3b3a33] focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2">{primaryLabel}</a>
        <a href="#" className="rounded-pill bg-surface-deep px-6 py-3 text-ui transition-colors duration-hover-color ease-hover-color hover:bg-[#e1e0db] focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2">{secondaryLabel}</a>
      </div>

      <div className="relative mt-14 aspect-[4/5] overflow-hidden bg-media-stone sm:aspect-[16/9]">
        <img src={imageSrc} alt="Impressionist-style landscape backdrop" width={1600} height={1200} className="absolute inset-0 h-full w-full object-cover opacity-70 saturate-50" />
        <div className="absolute inset-0 bg-surface/30" />

        <div className="absolute inset-x-[4%] top-[7%] bottom-[7%] flex flex-col overflow-hidden rounded-lg bg-surface shadow-window">
          <div className="flex items-center border-b border-hairline px-3 py-2">
            {dots}
            <span className="flex-1 text-center text-caption text-ink-muted">Quillfern Desktop</span>
          </div>
          <div className="grid min-h-0 flex-1 grid-cols-1 sm:grid-cols-[30%_1fr] lg:grid-cols-[30%_31%_1fr]">
            <div className="hidden border-r border-hairline p-3 sm:block">
              <p className="mb-2 text-product-micro text-ink-faint">READY FOR REVIEW 4</p>
              <Stagger step={140} from="up" distance={8} className="flex flex-col gap-1">
                {tasks.map((k) => (
                  <div key={k.t} className="rounded-md px-2 py-1.5">
                    <div className="flex justify-between text-product-micro"><span className="truncate">{k.t}</span><span className="text-ink-faint">{k.time}</span></div>
                    <div className="truncate text-product-micro text-ink-faint">{k.s}</div>
                  </div>
                ))}
              </Stagger>
            </div>
            <div className="flex flex-col gap-2 border-r border-hairline p-3 text-product-micro">
              <p className="text-ink-muted">Refresh pricing page</p>
              <div className="rounded-md border border-hairline bg-canvas p-2">rewrite the plans section so it sounds friendlier</div>
              <p className="text-ink-faint"><ShimmerText>Reading</ShimmerText> style-notes.md</p>
              <p>I'll tighten the copy and keep the tone warm and plain.</p>
              <div className="rounded-md border border-hairline px-2 py-1.5">content/plans.md <span className="text-positive">+24</span> <span className="text-negative">-9</span></div>
              <div className="mt-auto rounded-md border border-hairline bg-canvas p-2 text-ink-faint">Ask, draft, revise…</div>
            </div>
            <div className="hidden bg-canvas p-6 lg:block">
              <p className="font-serif text-lg italic">Fernhouse Press</p>
              <p className="mt-6 max-w-xs font-serif text-ink-muted">Good writing takes patience. We help small teams find their voice and keep it.</p>
              <div className="mt-6 space-y-3">
                {["2026", "2025", "2024", "2023"].map((y) => (
                  <div key={y} className="flex gap-4 border-t border-hairline pt-2 font-serif text-ink-faint"><span>{y}</span><span>Field notes</span></div>
                ))}
              </div>
            </div>
          </div>
        </div>

        <div className="absolute bottom-[6%] right-[3%] hidden w-[38%] overflow-hidden rounded-lg bg-surface shadow-window md:block">
          <div className="flex items-center border-b border-hairline px-3 py-2">
            {dots}
            <span className="flex-1 text-center text-caption text-ink-muted">Quillfern CLI</span>
          </div>
          <pre className="whitespace-pre-wrap p-3 font-mono text-product-micro leading-5">{"1. Shorten intro paragraphs to two lines\n2. Swap passive verbs for active ones\n3. Check headings for consistency\n\nAll edits are applied to your draft.\nShall I run a readability check?"}</pre>
          <div className="m-3 border border-hairline px-2 py-1.5 font-mono text-product-micro text-ink-faint">→ Add a follow-up</div>
        </div>

        <div role="dialog" aria-label="Privacy notice" className="absolute bottom-[14%] right-[1%] w-[88%] rounded-md bg-surface p-4 shadow-popover sm:w-[44%]">
          <p className="text-product-micro text-ink-muted">We use a few small cookies to keep things running smoothly. You can opt in to extras or decline them at any time in settings.</p>
          <div className="mt-3 flex flex-wrap gap-2">
            <button className="rounded-pill border border-hairline px-3 py-1.5 text-product-micro">Preferences</button>
            <button className="rounded-pill bg-ink px-3 py-1.5 text-product-micro text-canvas">Decline</button>
            <button className="rounded-pill bg-ink px-3 py-1.5 text-product-micro text-canvas">Allow all</button>
          </div>
        </div>
      </div>
    </section>
  );
}

// ---- Yoink motion (inlined, no dependencies): Stagger, ShimmerText ----

const YK_EASE = "cubic-bezier(0.16, 1, 0.3, 1)";

const useYkLayoutEffect = typeof window === "undefined" ? useEffect : useLayoutEffect;

function ykReducedMotion(): boolean {
  return typeof window !== "undefined" && !!window.matchMedia?.("(prefers-reduced-motion: reduce)").matches;
}

// "idle": untouched (visible) · "hidden": waiting below the fold · "shown": play the entrance.
// Content is only hidden once we know we can show it again (IntersectionObserver exists, motion allowed,
// and there is a box to watch), and a safety net reveals anything on screen that is still hidden.
type YkRevealState = "idle" | "hidden" | "shown";

function useYkReveal(ref: RefObject<Element | null>, once = true): YkRevealState {
  const [state, setState] = useState<YkRevealState>("idle");
  useYkLayoutEffect(() => {
    const el = ref.current;
    if (!el || ykReducedMotion() || typeof IntersectionObserver === "undefined") return;
    // watch the element's own box, or its children when it has none (display: contents)
    const boxes = () => (getComputedStyle(el).display === "contents" ? Array.from(el.children) : [el]);
    const onScreen = (t: Element) => {
      const r = t.getBoundingClientRect();
      return (r.width > 0 || r.height > 0) && r.bottom > 0 && r.right > 0 && r.top < window.innerHeight && r.left < window.innerWidth;
    };
    if (!boxes().some((t) => t.getBoundingClientRect().width > 0 || t.getBoundingClientRect().height > 0)) return; // e.g. hidden at mount: leave it visible
    let shown = false;
    const show = (v: boolean) => {
      if (v !== shown) (shown = v), setState(v ? "shown" : "hidden");
    };
    setState("hidden");
    const inView = new Set<Element>();
    const io = new IntersectionObserver((entries) => {
      for (const e of entries) {
        if (e.isIntersecting) inView.add(e.target);
        else inView.delete(e.target);
      }
      if (inView.size) {
        show(true);
        if (once) io.disconnect();
      } else if (!once) show(false);
    });
    const watched = new Set<Element>();
    const watch = () => boxes().forEach((t) => !watched.has(t) && (watched.add(t), io.observe(t)));
    watch();
    // safety net: styles that land after mount (display: contents) get watched too, and nothing
    // stays hidden for more than a moment while it is actually on screen
    const start = Date.now();
    const net = setInterval(() => {
      if (shown) return once && clearInterval(net);
      watch();
      if (Date.now() - start > 2400 && boxes().some(onScreen)) show(true);
    }, 600);
    return () => {
      io.disconnect();
      clearInterval(net);
    };
  }, [once]);
  return state;
}

/** Reveals each direct child one after another when the group scrolls into view. */
function Stagger({
  children,
  step = 90,
  from = "up",
  distance = 20,
  duration = 650,
  delay = 0,
  once = true,
  as = "div",
  className,
  style,
}: {
  children?: ReactNode;
  step?: number;
  from?: "up" | "down" | "left" | "right" | "scale" | "fade";
  distance?: number;
  duration?: number;
  delay?: number;
  once?: boolean;
  as?: ElementType;
  className?: string;
  style?: CSSProperties;
}) {
  const Tag = as;
  const ref = useRef<HTMLElement>(null);
  const state = useYkReveal(ref, once);
  useYkLayoutEffect(() => {
    const items = Array.from(ref.current?.children ?? []) as HTMLElement[];
    if (state === "idle") return;
    const offset = {
      up: `translate3d(0, ${distance}px, 0)`,
      down: `translate3d(0, ${-distance}px, 0)`,
      left: `translate3d(${-distance}px, 0, 0)`,
      right: `translate3d(${distance}px, 0, 0)`,
      scale: "scale(0.92)",
      fade: "none",
    }[from];
    if (state === "hidden") {
      for (const el of items) Object.assign(el.style, { transition: "none", opacity: "0", transform: offset });
      return;
    }
    items.forEach((el, i) => {
      const t = `${duration}ms ${YK_EASE} ${delay + i * step}ms`;
      Object.assign(el.style, { transition: `opacity ${t}, transform ${t}`, opacity: "", transform: "" });
    });
    // hand the children their own transitions back once everything has landed
    const done = setTimeout(() => items.forEach((el) => (el.style.transition = "")), delay + items.length * step + duration + 50);
    return () => clearTimeout(done);
  }, [state]);
  return (
    <Tag ref={ref} className={className} style={style}>
      {children}
    </Tag>
  );
}

const YK_SHIMMER_CSS = `@keyframes yk-shimmer{0%{background-position:100% 0}60%,100%{background-position:0% 0}}
@media (prefers-reduced-motion:reduce){[data-yk-shimmer]{animation:none!important;background:none!important;-webkit-text-fill-color:currentColor!important}}`;

/** A band of light that sweeps across text: headlines, badges, button labels. */
function ShimmerText({
  children = "Now in early access",
  duration = 2.8,
  className,
  style,
}: {
  children?: ReactNode;
  /** seconds per sweep (including a short rest) */
  duration?: number;
  className?: string;
  style?: CSSProperties;
}) {
  // dimmed text with a full-strength band passing over it; follows the text colour in any theme
  const dim = "color-mix(in oklab, currentColor 55%, transparent)";
  return (
    <span className={className} style={style}>
      <style>{YK_SHIMMER_CSS}</style>
      <span
        data-yk-shimmer=""
        style={{
          backgroundImage: `linear-gradient(100deg, ${dim} 0%, ${dim} 40%, currentColor 50%, ${dim} 60%, ${dim} 100%)`,
          backgroundSize: "250% 100%",
          backgroundClip: "text",
          WebkitBackgroundClip: "text",
          WebkitTextFillColor: "transparent",
          animation: `yk-shimmer ${duration}s ease-in-out infinite`,
        }}
      >
        {children}
      </span>
    </span>
  );
}

Quality checks

Automated, in a real browser · 4d ago
—

More from Warm Paper Editorial

The whole style →

Ink and Ghost Pill Buttons

Buttons

Quote Card Grid

Testimonials

Terminal Install Chip

Code blocks

Dated Blog Index Table

Lists

Customer Story Logo Cards

Cards

Hairline Chevron Accordion

FAQ