npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@buoy-gg/bottom-sheet

v7.0.81

Published

Bottom sheet and floating window components for React Native, with configurable presentation and native-driver animations.

Readme

@buoy-gg/bottom-sheet

A React Native component with bottom-sheet and floating-window modes, configurable headers and footers, and drag-to-resize gestures.

Features

  • 📱 Dual Modes - Bottom sheet and floating window modes
  • 🎨 Fully Customizable - Custom headers, themes, and styles
  • ✋ Touch Gestures - Drag to resize, double-tap to toggle mode, triple-tap to close
  • 🔄 Smooth Transitions - Spring-based animations for natural feel
  • 📐 Smart Boundaries - Respects safe areas and screen boundaries
  • Dependencies - Requires React and React Native and uses Buoy’s shared UI package
  • 🎯 TypeScript - Full type safety and IntelliSense support

Installation

npm install @buoy-gg/bottom-sheet
# or
yarn add @buoy-gg/bottom-sheet
# or
pnpm add @buoy-gg/bottom-sheet

Basic Usage

import React, { useState } from 'react';
import { View, Text, Button } from 'react-native';
import { BottomSheet } from '@buoy-gg/bottom-sheet';

function MyComponent() {
  const [visible, setVisible] = useState(false);

  return (
    <View>
      <Button title="Open Bottom Sheet" onPress={() => setVisible(true)} />

      <BottomSheet
        visible={visible}
        onClose={() => setVisible(false)}
        header={{
          title: "My Bottom Sheet",
          subtitle: "Drag to resize"
        }}
      >
        <View style={{ padding: 20 }}>
          <Text>Your content here!</Text>
        </View>
      </BottomSheet>
    </View>
  );
}

Open the sheet, drag its header, switch modes, and close it to check the basic integration.

Advanced Usage

These snippets reuse visible, its setter, and your own content or save handler from the surrounding component.

Custom Theme

<BottomSheet
  visible={visible}
  onClose={() => setVisible(false)}
  theme={{
    primary: '#FF6B6B',
    secondary: '#4ECDC4',
    background: '#1A1A2E',
    panel: '#16213E',
    success: '#06FFA5',
  }}
>
  <YourContent />
</BottomSheet>

With Footer

<BottomSheet
  visible={visible}
  onClose={() => setVisible(false)}
  footer={
    <View style={{ padding: 16, borderTopWidth: 1, borderTopColor: '#ccc' }}>
      <Button title="Save" onPress={handleSave} />
    </View>
  }
  footerHeight={60}
>
  <YourContent />
</BottomSheet>

Custom Header

<BottomSheet
  visible={visible}
  onClose={() => setVisible(false)}
  header={{
    customContent: (
      <View style={{ padding: 16 }}>
        <Text style={{ fontSize: 18, fontWeight: 'bold' }}>
          Custom Header
        </Text>
      </View>
    )
  }}
>
  <YourContent />
</BottomSheet>

Floating Window Mode

<BottomSheet
  visible={visible}
  onClose={() => setVisible(false)}
  initialMode="floating"
  onModeChange={(mode) => console.log('Mode changed to:', mode)}
>
  <YourContent />
</BottomSheet>

Height Control

<BottomSheet
  visible={visible}
  onClose={() => setVisible(false)}
  initialHeight={500}
  minHeight={200}
  maxHeight={800}
>
  <YourContent />
</BottomSheet>

Props

BottomSheetProps

| Prop | Type | Default | Description | |------|------|---------|-------------| | visible | boolean | required | Controls visibility of the bottom sheet | | onClose | () => void | required | Callback when sheet should close | | children | ReactNode | required | Content to display in the sheet | | header | BottomSheetHeaderConfig | undefined | Header configuration | | styles | CustomStyles | {} | Custom styles for container and content | | minHeight | number | 100 | Minimum height in bottom sheet mode | | maxHeight | number | screen height - safe area | Maximum height in bottom sheet mode | | initialHeight | number | 400 | Initial height in bottom sheet mode | | initialMode | 'bottomSheet' \| 'floating' | 'bottomSheet' | Initial display mode | | onModeChange | (mode) => void | undefined | Callback when mode changes | | footer | ReactNode | undefined | Footer content (sticky at bottom) | | footerHeight | number | 0 | Height of footer for content padding | | onBack | () => void | undefined | Callback for back action (enables top-left corner tap) | | theme | Partial<Theme> | defaultTheme | Custom color theme |

BottomSheetHeaderConfig

| Prop | Type | Description | |------|------|-------------| | title | string | Header title text | | subtitle | string | Header subtitle text | | customContent | ReactNode | Custom header content (replaces title/subtitle) | | hideCloseButton | boolean | Hide the close button |

Gestures

  • Drag Header - Resize bottom sheet or move floating window
  • Double Tap Header - Toggle between bottom sheet and floating modes
  • Triple Tap Header - Close the sheet
  • Drag Corner (Floating) - Resize floating window
  • Tap Top-Right Corner (Floating) - Close the sheet
  • Tap Top-Left Corner (Floating) - Trigger back action (if onBack is provided)
  • Fast Swipe Down - Close bottom sheet

Performance

The component uses React Native animations and gestures. Actual frame rate depends on device load, sheet contents, and your app. Profile dragging and resizing with representative content.

TypeScript

Full TypeScript support with exported types:

import {
  BottomSheet,
  BottomSheetProps,
  BottomSheetMode,
  BottomSheetHeaderConfig
} from '@buoy-gg/bottom-sheet';

License

MIT

Credits

Based on the proven JsModal component from the React Native Buoy toolkit.