Focus Mode
Focus Mode: An atmospheric focus-mode interaction that isolates selected cards or sections by smoothly dimming surrounding distractions with zero layout shift, tactile spring scaling, and Escape key dismissal. Free MIT React & Next.js source with Motion and Tailwind CSS, live preview, CLI install and docs.
Install Focus Mode
npx motion-ui-skill add focus-modeComponents install as source into your project. The interactive page also includes preview, code, documentation and install tabs.
Dependencies
clsxlucide-reactmotionreacttailwind-merge
Source files
Focus Mode
An atmospheric focus-mode interaction that isolates selected cards or sections by smoothly dimming surrounding distractions with zero layout shift, tactile spring scaling, and Escape key dismissal.
Install
npx motion-ui-skill add focus-mode
Dependencies
clsxlucide-reactmotionreacttailwind-merge
Usage
"use client";
import { FocusMode as FocusMode } from "@/components/craft/focus-mode";
export function Example() {
return (
<div className="p-6">
<FocusMode />
</div>
);
}