AI analysis An AI search prompt box whose focus ring fades in as the cursor approaches, anticipating user intent.
It is a single-component composition with one rounded search input box centered on a white background and a short gray caption below. Inside the light gray box sit a gray placeholder, a sky-blue gradient pill mode button at the bottom left, and a white circular send button at the bottom right, while a wide soft shadow lifts the box. As the cursor approaches the box, a sky-blue border glow grows stronger, returning to a gray border when the cursor moves away, followed by a flow where text is typed after clicking. It is a useful reference for applying a distance-based focus anticipation micro-interaction to an AI prompt input.
minimal · light-mode · soft-gradient
claude-opus-5-5 · 2026-12-03 07:09 · Confidence 0.80
Original post With Claude Fable 5 making software creation more accessible, interaction design is becoming an even bigger differentiator. So here is a Design Engineering Tip:
Most interfaces wait for users to act. Better interfaces prepare for what users are about to do.
This pattern is called Input Anticipation. By reacting to intent before an interaction happens, products feel faster, smarter, and easier to use.
JS
const box = document.querySelector(".input")
const ring = document.querySelector(".focus-ring")
addEventListener("pointermove", (e) => {
const r = box.getBoundingClientRect()
const dx = Math.max(r.left - e.clientX, 0, e.clientX - r.right)
const dy = Math.max(r. top - e.clientY, 0, e.clientY - r.bottom)
const distance = Math.hypot(dx, dy)
const intent = Math.max(0, 1 - distance / 180) ** 2
ring. style.opacity = intent
})
Save this for later.
477 likes · 12 reposts
x.com/gabriell_lab/status/2065039972483182708