LockInput

LockInput: A text input whose focus state subtly "locks" into place — a focus ring scales in from the center and the border tweens to active, giving the impression that the input snaps closed on itself. Free MIT React & Next.js source with Motion and Tailwind CSS, live preview, CLI install and docs.

Install LockInput

npx motion-ui-skill add lock-input

Components install as source into your project. The interactive page also includes preview, code, documentation and install tabs.

Dependencies

  • clsx
  • motion
  • react
  • tailwind-merge

Source files

LockInput

A text input whose focus state subtly "locks" into place — a focus ring scales in from the center and the border tweens to active, giving the impression that the input snaps closed on itself.

Install

npx motion-ui-skill add lock-input

Dependencies

  • clsx
  • motion
  • react
  • tailwind-merge

Usage

"use client";

import { LockInput as LockInput } from "@/components/craft/lock-input";

export function Example() {
  return (
    <div className="p-6">
      <LockInput />
    </div>
  );
}

Browse this category