Components
Mobile App Shell
A safe-area aware phone frame with header, scrollable body and footer slots.
Installation
$ npx veil-ui@latest add mobile-app-shellUsage
import { MobileAppShell } from "@/components/ui/mobile-app-shell";
import { MobileBottomBar } from "@/components/ui/mobile-bottom-bar";
import { MobileHeader } from "@/components/ui/mobile-header";
<MobileAppShell
header={<MobileHeader title="Tasks" subtitle="4 lists" />}
footer={<MobileBottomBar>{footerActions}</MobileBottomBar>}
>
<TaskList />
</MobileAppShell>;Examples
Basic
Tasks
4 lists
- Inbox5
- Today5
- Upcoming8
- Completed9
With fab
Notes
All notes
Design tokens
Updated 2 hours ago
Release checklist
Updated 2 hours ago
Interview notes
Updated 2 hours ago
API reference
The package exports mobile-app-shell along with its composable parts. It forwards standard attributes to its root element; see the examples above for the component-specific props.
Accessibility
- Touch targets are large enough to tap comfortably and keep visible focus rings for keyboard and switch users.
- Gesture interactions (swipe, pull to refresh) have visible button alternatives so they are not the only way to act.
- Sheets, drawers and dialogs follow the underlying accessible primitives for focus trapping and escape handling.
Vue and plain HTML
This component also ships for Vue (Reka UI) and plain HTML. Install it with npx veil-ui add mobile-app-shell --framework vue or switch the framework in components.json.
<script setup lang="ts">
import { cn } from "@/lib/utils";
const props = defineProps<{ class?: string }>();
</script>
<template>
<div
data-slot="mobile-app-shell"
:class="
cn(
'relative flex h-[600px] w-full max-w-sm flex-col overflow-hidden rounded-xl border bg-background shadow-sm',
props.class,
)
"
>
<slot name="header" />
<main class="flex-1 overflow-y-auto overscroll-contain">
<slot />
</main>
<slot name="footer" />
<slot name="floating" />
</div>
</template>