Halftone Background - React Component | Kokonut UI

Halftone Background

Any image, or a lit sphere, printed as a halftone dot screen, with a loupe that looks closer under the cursor, built with React and canvas.

Installation

Halftone Background is a free, open-source React component in the Kokonut UI Backgrounds collection. Add it with the shadcn CLI, which copies the source into components/kokonutui/halftone-background.tsx, so the code is yours to change.

npx shadcn@latest add @kokonutui/halftone-background

Usage

import HalftoneBackground from "@/components/kokonutui/halftone-background";

export default function Example() {
  return <HalftoneBackground />;
}

Props

Dependencies

Needs Version Comes from
cn from lib/utils.ts shadcn init
React 19 Your app
Tailwind CSS 4 Your app

No provider, font or global CSS to set up: the file works as soon as it lands.