OPUS/UI

Navigation

Glitch Text

RGB-split slice glitch from two pseudo-element copies — always on, or only while hovered. Zero JS.

cssrsc2 files · 62 locdeps: clsx, tailwind-merge
SIGNAL LOSThover to corrupt

Installation

With the shadcn CLI, pointing at this platform’s registry:

npx shadcn@latest add https://opusui.131199999.xyz/r/glitch-text.json

Or offline, straight from your opus55 checkout (copies every file it needs):

node ../tailwind_component/opus55/scripts/add.mjs glitch-text

Usage

import { GlitchText } from "@/components/opus/text/glitch-text";

<GlitchText text="SIGNAL LOST" />

API

PropTypeDefaultDescription
textstring—Text (copied into data-text for the layers).
onHoverbooleanfalseGlitch only while hovered.
speednumber2.2Seconds per cycle.
colorA / colorBstring—Split colours.

Command palette