Mobile › Feedback

EmptyState

What a screen shows when there is nothing yet: what it is for and the one step to fill it.

Installation

npx expo install plankui-mobile react-native-safe-area-context expo-haptics

Usage

import { EmptyState } from "plankui-mobile";

<EmptyState
  icon={<FolderIcon color={t.c.accent} size={30} />}
  title="No projects yet"
  message="Projects you create or join show up here."
  action={{ label: "New project", onPress: create }}
/>

iOS and Android

iOS: Centred, with a filled button.

Android: Centred, with a Material filled button.

API reference

PropTypeDefaultDescription
iconReactNode–Drawn on a tinted tile.
titlestringWhat is missing.
messagestring–What will appear here.
action{ label: string; onPress: () => void }–The one step to fill it.