Mobile Keyboard Avoidance
Keep the field being typed in, and the button that submits it, visible above the keyboard.
What it adds
Coordinated handling of the on-screen keyboard so the focused input and the primary action stay in view while it is open.
What your agent is told to do
5
What your agent is told to do
5-
1
Identify every screen where a user types on a phone — sign-in, search, comment boxes, checkout, bottom sheets, inline table editors — and confirm for each that the focused field and its submit control remain visible with the keyboard open.
-
2
React to the visual viewport rather than the layout viewport. The layout viewport often does not change when the keyboard opens, so anything keyed to it will believe nothing happened while the bottom half of the screen is covered.
-
3
Bring the focused field into view with the smallest movement that clears the keyboard, and leave a small margin above it. Centring every focused field yanks the page around and loses the user's place in a long form.
-
4
Decide explicitly what fixed footers, sticky action bars, and bottom sheets do when the keyboard opens: ride above it, or unstick and return to the document flow. Both are defensible, but a footer left pinned to the old bottom edge sits underneath the keyboard and its buttons cannot be pressed.
-
5
Do not treat every viewport height change as a keyboard event. Pinch zoom, browser chrome retracting on scroll, and rotation all change the reported height, and scrolling the page in response to them makes the app feel possessed. Choosing which height a container is sized against belongs to Viewport Height Utility; this brief owns only the reaction to the keyboard appearing and disappearing.
Edge cases it handles
7
Edge cases it handles
7- A pinch zoom shrinks the visual viewport exactly as a keyboard does. Treating the two as the same event makes the page scroll away under the user's fingers while they are trying to read something, so distinguish them by whether an input actually holds focus and by the scale factor.
- Scrolling the page in response to focus must be predictable and minimal. An unprompted jump that moves content the user was reading, or that fires again on every keystroke as the field grows, is worse than the field being partly obscured.
- Fixed footers, sticky action bars, and bottom sheets are the usual casualties: they stay glued to the pre-keyboard bottom edge and end up behind the keyboard, taking the submit button with them. Every bottom-anchored element needs a defined keyboard behaviour, and only one of them may own the bottom edge.
- When the keyboard closes, the previous scroll position must be restored rather than left wherever the avoidance logic pushed it. Landing the user halfway down a form they had already scrolled past is disorienting.
- Different platforms report the keyboard differently and some do not report it at all until after it has finished animating, so the layout must settle correctly rather than assuming a single resize event arrives at a useful moment.
- Predictive text bars, autofill suggestion strips, and hardware keyboards attached to tablets all change the covered height without a conventional keyboard being present, so the calculation must use the measured obscured area rather than an assumed keyboard height.
- Moving focus between two adjacent fields must not re-run a full scroll animation each time. Tabbing through a form should feel continuous, not like a series of jumps.
Definition of done
8
Definition of done
8- The focused input and its associated submit control remain visible while the on-screen keyboard is open, on every screen where users type.
- Pinch zoom and browser chrome changes do not trigger keyboard avoidance behaviour.
- Scroll adjustments are the minimum needed to clear the keyboard and do not repeat on every keystroke.
- Every bottom-anchored element has a defined behaviour when the keyboard opens, and none is left unreachable behind it.
- Closing the keyboard restores the scroll position the user had before it opened.
- The obscured area is measured rather than assumed, so predictive bars and hardware keyboards behave correctly.
- The feature matches the existing design system.
- No existing functionality is broken.
Related features
Beautiful Empty States
Beautiful Empty States
Replace blank screens with useful, contextual empty states.
What it does
Every list, table, and dashboard in your app has a "nothing here yet" state. Most
apps ship a blank rectangle — and it is often the very first thing a new user sees.
An empty state should say what belongs here, why it is empty, and what to do next.
How it works
- 1 Inventory the empty cases first. List every collection view in the app and
- 2 Distinguish the three kinds of empty. They are not the same, and must not
- 3 Build one reusable empty-state component from the existing design system,
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/beautiful-empty-states
Media Aspect Ratio System
Media Aspect Ratio System
Give every thumbnail, avatar, and hero a shared, reserved shape so nothing jumps.
What it does
A small set of named aspect ratios applied to every image and video surface, with reserved space, a defined fit, and a defined fallback.
How it works
- 1 Catalogue the media surfaces already in the app — list thumbnails, card covers, avatars, hero banners, video embeds, attachment previews — and reduce them to a handful of named ratios rather than a per-component value.
- 2 Reserve the box before the media loads so the ratio holds space from first paint. Layout that settles after an image arrives moves whatever the user was about to click.
- 3 Set the fit per content type, not per component: faces and product shots crop to fill from a sensible focal point, diagrams and screenshots fit whole with padding, because cropping a diagram loses the content it exists to show.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/media-aspect-ratio-system
Opening Hours Display
Opening Hours Display
Say whether you are open right now and when you next open.
What it does
A live open or closed state alongside the weekly hours, with holiday closures folded in.
How it works
- 1 Lead with the current state in plain words and follow it with the next transition: open until a time, or closed until a day and time. The weekly table is supporting detail, not the headline.
- 2 Store hours as intervals against the business's own zone, and keep holiday and one-off closures as overrides that win over the regular week rather than as edits to it.
- 3 Compute the state on the server for the first render so the page does not briefly claim the wrong thing, then let the page update itself as the clock crosses a boundary without a reload.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/opening-hours-display
How it works
-
1
Copy the link
Grab the Markdown instruction URL for this feature.
-
2
Give it to your AI
Paste it into Claude Code, Cursor, v0, Lovable — whatever you build with.
-
3
It inspects, then implements
Your agent reads your existing app first, then adds the feature to fit it.
Works with your stack
These instructions are written to adapt. They tell the agent to detect your framework, match your existing design system, and reuse what you already have — rather than assuming a particular stack.
Need it tighter than that? Customize the feature and tell it exactly what you're running.