Component packs › Snippet › Length Budget
Each length limit is a ring and a pin dropped into the text where it ends; pick one to shade what falls past it.
Length Budget is an input from Snippet, a component pack with 7 preview components: Seven preview components that show how a page or post will look before it goes out, measured, not guessed. Price: $2 for the whole pack.
Built with: in-text pins, grapheme count, limit rings.
Code: React and Next.js (TypeScript), Vue 3, plain HTML/CSS/JS, Tailwind CSS v4 and Motion (motion.dev). No npm packages needed. Keyboard accessible, with a reduced-motion version, in dark and light.
| Prop | Type | Default | Description |
|---|---|---|---|
dark | boolean | ||
autoplay | boolean | ||
value | string | ||
limits | [string, number][] | name, characters | |
onChange | (v: { count: number; over: string[] }) => void |
set(text: string): voiddestroy(): voidimport LengthBudget from './LengthBudget';
<LengthBudget />The Vue, HTML, Next.js, Tailwind and Motion versions take the same options.
Good for: SEO and social preview components.