Skip to content
WingoUI
ComponentsTemplatesDocsPricingAI agentsBlogChangelogContact
Components
Buttons & Actions
ButtonButton GroupCopy ButtonDelete ButtonTheme ToggleToggleToggle Group
Inputs
Avatar UploadCalendarCheckboxColor PickerComboboxCountry SelectCron PickerCurrency InputDate PickerDate Range PickerDate Time PickerDuration PickerEmail InputEmoji PickerFile UploadFilter BuilderInputInput GroupListboxMasked InputMention InputMonth PickerMulti SelectNumber InputOTP InputPassword InputPhone InputRadio GroupRatingSearch InputSegmented ControlSelectSignature PadSliderSwitchTag InputTextareaTime PickerTimezone SelectTree Select
Forms
Address InputBooking WidgetCSV ImportFieldForm WizardInline EditInvoice line itemsRich Text EditorSchema Builder
Navigation
Back To TopBounce SidebarBreadcrumbCommand MenuGlobal SearchGooey NavHook SidebarNav MenuNav TabsPaginationProximity SidebarScroll ProgressSidebarStepsTable Of ContentsTabsTopbarUser MenuWorkspace Switcher
Overlays
Alert DialogContext MenuDialogDrawerDropdown MenuFamily DrawerHover CardPopoverShare DialogSheetShortcuts DialogTooltipTour
Feedback
AlertBannerCookie ConsentEmoji ReactionEmpty StateNotification BellNotification CenterProgressRoute ProgressSetup ChecklistSkeletonSpinnerToast
Data Display
Approval FlowAvatarBadgeCalendar ViewCode BlockComment ThreadContact cardCountdownDescription ListDiff ViewerFile ListFile managerFolderGanttJSON ViewerKbdLog ViewerMarkdownPresenceSchedulerTagTimelineTree View
Tables & Lists
Audit LogData TableDeal PipelineEditable GridKanbanListMembers tablePermissions MatrixTableTask ListVirtual List
Charts & Stats
Animated CounterArea chartBar chartDonut chartFunnel chartGaugeGitHub ActivityHeatmap calendarLeaderboardLine chartRadar chartRadial barSparklineStat CardTrackerTrend badge
Layout
AccordionApp ShellCardCollapsibleDetail LayoutEntity HeaderPage HeaderScroll AreaSeparatorSettings LayoutSplit ViewToolbar
Media
Audio PlayerCarouselCSV ViewerDOCX EditorDOCX ViewerExcel ViewerFile SystemImage compareImage CropperImage GalleryImage LightboxLocation MapPDF ViewerPowerPoint ViewerQR CodeStep PlayerVideo Player
AI Kit
Agent Status CardChat MessageChat ThreadChat WidgetConversation ListFluid OrbGrid RevealMatrix OrbModel PickerPrompt InputReasoning IndicatorRule BuilderSuggestion ChipsTool Call TimelineUsage MeterVoice InputWorkflow Canvas
Text & Effects
Background PatternGravity LettersMarqueeTerminalText AnimateText Rotate
Mobile
Action SheetBottom Tab BarFABHaptic ButtonHero HeaderInstall PromptLarge Title HeaderNotification BannerOnboarding CarouselPicker WheelPull To RefreshSlide To ConfirmSticky CTA BarSwipe DeckSwipeable Tabs
Commerce
Cart drawerCategory pickerCheckout stepsCoupon inputFavorite buttonFilter panelListing cardListing gridOrder trackerPricePrice rangePricing tableProduct galleryQuantity stepperReviewsSeller card
Marketing Sections
App Download SectionBlog Cards SectionCTA SectionFAQ SectionFeature GridFeature ShowcaseHero SectionIntegrations SectionLogo CloudMarketing FooterMarketing HeaderMarketing SectionNewsletter SectionPricing SectionStats SectionSteps SectionTeam SectionTestimonials SectionTimeline SectionVideo Section
Blocks
Admin Dashboard PageAdmin ShellAI Chat PageAPI Keys PageAutomation Builder PageCheckout PageCRM Contact PageCRM Pipeline PageError PagesInbox PageInvoice PageKPI DashboardListing Detail PageLogin PageMarketplace Home PageMarketplace Search PageMarketplace ShellMobile App HomeOnboarding FlowOrder History PagePost Listing WizardPricing PageProfile PageRegister PageSettings PageUsers Admin Page
Templates
About PageAcademy PageAccessibility PageAffiliate PageAgency PageAI Product PageAppointment Booking PageBlog PageBlog Post PageBug Bounty PageCareers PageChangelog PageCommunity PageCompare PageContact PageCustomer Story PageCustomers PageDemo Booking PageDevelopers PageDocs Home PageDownload PageEnterprise PageEvents PageExperts PageFAQ PageFeature PageGlossary PageHelp Article PageHelp Center PageHome Services PageImpact PageIntegration Detail PageIntegrations PageJob Detail PageLanding PageLaunch PageLegal PageManifesto PagePortfolio PagePress PageProduct Tour PagePromo PageReal Estate PageReferral PageResearch Report PageRestaurant PageRoadmap PageROI Calculator PageSecurity PageSolutions PageStartups PageStatus PageStorefront PageSwitch PageTemplate Gallery PageTravel PageWaitlist PageYear in Review Page
Hooks & Utilities
AI ChatChart kitCommerceDate utilsFile exportFile typesFiltersForm validationHapticsInvoicingMotion presetsNavigationNumber formatRelative timeRomanian locationsSpreadsheetText matchTonesUIProvideruseClipboarduseConsentuseControllableStateuseCooldownuseDebounceuseKeyboardInsetuseLocaleuseLongPressuseMediaControlsuseMediaQueryuseOverflowItemsusePersistedStateuseScrollEdgesuseScrollStateuseSelectionuseShortcutuseStickToBottom
GalleryTheme

AI Kit

Grid Reveal

AI Kit

Grid Reveal React component for Tailwind CSS v4

Fluid OrbMatrix Orb
Live props
Appearance
aspect1
cells180
radius16px
captionColor
shimmer
Content
caption
alt
src
Behavior
estimatedDuration6000ms
progressPaced by time
Layout
captionPosition
Code
import GridReveal from "@/components/ui/grid-reveal"

<GridReveal />
  1. Home
  2. Components
  3. AI Kit
  4. Grid Reveal
Free

Grid Reveal React component for Tailwind CSS v4

v1.0.1·Updated in 1.2.1

A React AI image loading placeholder: a canvas grid that splits while the image generates, then resolves into the real picture.

Press Generate and the frame opens as four cells, then keeps splitting the biggest one in two while the image is on its way. When the picture lands the cells take on its colors, busy parts of the image split first, the gutters close up and the photo fades in. A frosted status pill sits in the bottom left with a slow shimmer, crossfading between lines as the caption changes, and fades out once the reveal is done. Honors prefers-reduced-motion by holding a still frame.

Grid Reveal is a free React component in the React AI components category, written in TypeScript for React 19 and Tailwind CSS v4. It installs as source with npx wingo-ui@latest add grid-reveal, together with UIProvider and the npm package motion.

Add to a project

Requirements: React 19 and Tailwind CSS v4, in Next.js (App Router or Pages), Vite or React Router. Installation guide · Next.js setup · Vite setup

npx wingo-ui@latest add grid-reveal

Usage

Import GridReveal from @/components/ui/grid-reveal.

"use client"

import { useState } from "react"
import GridReveal from "@/components/ui/grid-reveal"

export function Demo() {
  const [src, setSrc] = useState<string | null>(null)

  async function generate() {
    setSrc(null)                   // null is the waiting state, the grid runs while it is empty
    setSrc(await createImage())    // setting it resolves the grid into the picture
  }

  return (
    // the frame fills its parent, so give the parent a width
    <div className="w-64">
      <GridReveal src={src} alt="Generated image" caption="Creating image" />
      <button onClick={generate}>Generate</button>
    </div>
  )
}

// Passing a src that is already loaded skips the wait, so the run flashes by.
// Pass progress when your API reports it: <GridReveal src={src} progress={job.progress} />

Props

  • aspectdefault 1
    number

    Width divided by height of the frame. The frame fills its parent's width, so constrain the parent to size it.

  • captiondefault ""
    string

    Optional status text, shown as a frosted pill in the bottom left of the frame and lit by a slow shimmer. Change it mid-run and the lines crossfade while the pill resizes to suit. Empty renders no pill.

  • altdefault ""
    string

    Describes the finished image for screen readers. The frame is hidden from assistive tech when it is empty.

  • estimatedDurationdefault 6000
    number

    Roughly how long the work takes in milliseconds, used to pace the grid when no progress is passed. Overrunning it is fine, the grid keeps creeping instead of stopping.

  • cellsdefault 180
    number

    How many cells the grid ends on before the photo fades in, from 8 to 400. Fewer cells read as big bold blocks, more as a fine mosaic. A new count shows on the next reveal.

  • radiusdefault 16
    number

    Corner radius of the frame in pixels, drawn as a squircle where the browser supports corner-shape.

  • captionPositiondefault "bottom-left"
    "bottom-left" | "bottom-right" | "top-left" | "top-right"

    The corner the caption pill sits in, 12px from the edges.

  • captionColordefault "rgba(0, 0, 0, 0.45)"
    string

    Any CSS color for the caption pill, drawn over a blur.

  • shimmerdefault true
    boolean

    Sweeps a highlight across the caption text while the image is on its way. Off (and under reduced motion) the text is plain white at 75%.

  • srcdefault ""
    string | null

    Image to reveal. Keep it null while the image is generating, since the grid only runs while this is empty and a src that is already loaded makes the whole run flash by. Cross-origin images need CORS headers for the color pass; without them the grid stays grey and the photo still fades in. In the playground an image URL replaces the sample when the wait is over.

  • progressdefault 0
    number

    Position of the wait from 0 to 1, driving how far the grid has split. It holds at 0.72 until the image decodes, and the image landing is what finishes the reveal. Leave it out to pace by estimatedDuration.

  • onRevealComplete
    () => void

    Fires once the image has fully resolved.

  • onError
    () => void

    Fires when the image fails to load. Without it a broken src leaves the grid waiting, so use it to show your own fallback.

  • className
    string

    Extra classes merged onto the root element (data-slot="grid-reveal"). Other div props are spread onto it too.

  • style
    React.CSSProperties

    Inline styles merged after the aspect ratio, so an aspectRatio here overrides the aspect prop.

Examples

Driven by your API's progress

Pass progress (0 to 1) when your job reports it and the grid splits in step with it instead of pacing itself by estimatedDuration. Setting src is what completes the reveal.

A batch of four

Four generations in a grid, each finishing at its own time. Fewer cells (64) and a smaller radius read better at thumbnail size.

Wide header with a corner caption

A 16:9 frame with a fine 300-cell mosaic, a 24px radius and the caption pill in the top right corner.

Inside a chat reply

The assistant's message holds the frame while the image renders, then swaps its text once the picture lands.

Dependencies

motionui-config

Files

  • components/ui/grid-reveal.tsx

FAQ

Is the React Grid Reveal component free?

Yes. The source is free and needs no account: copy it from the Code tab or install it with the CLI.

How do I install Grid Reveal?

Run npx wingo-ui@latest add grid-reveal. It also adds the Wingo UI item it builds on (UIProvider) and the npm package motion. With shadcn, run npx shadcn@latest add https://wingo-ui.com/r/grid-reveal.json.

See also

SkeletonMatrix OrbFluid OrbReasoning IndicatorProgressChat Message

More React AI components

Workflow CanvasVoice InputModel PickerAgent Status CardChat ThreadChat Widget
All 17 React AI components
PreviousFluid OrbNext Matrix Orb
Starting to generate