Vibary.ai
← Vibe Coding

New Posts Pill

A count of fresh items drops in at the top; tapping it returns to the top as they insert.

socialminimalfriendlyautomatic · finite · intermediate · ~0.6s
Variant

The animated component in this preview is rendered from the canonical file shown here. The surrounding demo shell only provides context and is not part of the copied code.

318 lines · react + motion only
import { useEffect, useRef, useState } from "react";
import { AnimatePresence, motion, useReducedMotion } from "motion/react";

/**
 * Vibary · New Posts Pill
 *
 * Fresh items are announced, never forced in. The pill drops from the
 * top edge and waits as long as it takes; only on the tap does the feed

About this pattern

Inserting new items above someone who is mid-read is the rudest thing a feed can do, so nothing moves until it is asked to. The pill drops in from the top edge, waits as long as it takes, and only on the tap does the feed return to the top and the new items arrive on a short stagger. The pill leaves the way it came, which is what makes the return trip legible rather than a sudden scroll.

New items available in a feedUnread updates while scrolled downLive results arriving behind the foldReturn to the top of a timeline

Where it shows up

Screens we drew to show where this motion usually sits. Illustrations, not captures of any product.

  • Priya Raman2hFinally got the trail loop under an hour. Four months of Tuesdays.
    12814
    Marcus Bell5hNew supplier signed. Same rate, twelve more months.
    423
    Social feed

    A floating count waits above the timeline until the reader asks for it.

Related patterns