rslabdocs

Card Expand

The App Store transition, tap a card, it becomes the screen, drag down to send it back.

ReanimatedGesture HandlerSource

Prerequisites

This animation is built on the following libraries. expo install pins the versions that match your SDK, and the CLI tells you exactly which ones are missing when you add the component.


npx expo install react-native-reanimated react-native-gesture-handler @shopify/react-native-skia expo-haptics react-native-safe-area-context @hugeicons/react-native @hugeicons/core-free-icons react-native-css

Install


npx @rslab/cli add card-expand

Usage

import { CardExpand, ExpandCard } from '@/components/ui/CardExpand';

const CARDS: ExpandCard[] = [
  {
    id: 'focus',

    label: 'Featured',

    title: 'Deep Focus',

    subtitle: 'One line under the title.',

    body: 'The long text revealed once the card is fullscreen.',

    colors: ['#3b2f2a', '#8a5a3b'],
  },
];

<CardExpand cards={CARDS} />;

See exactly how this works with an RSLAB subscription.

Get Pro

On this page