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

awesome-floating-bubble-carousel

v0.1.3

Published

A floating bubble carousel React component with animated physics and multiple data loading modes.

Readme

Awesome Floating Bubble Carousel

A floating bubble carousel React component with animated physics, glow styling, and multiple data loading modes.

Install

npm install awesome-floating-bubble-carousel

Watch the demo here

Watch the Demo

Quick Usage

import { AwesomeFloatingBubbleCarousel } from "awesome-floating-bubble-carousel";
import type { BubbleCard } from "awesome-floating-bubble-carousel";

const cards: BubbleCard[] = [
  {
    id: 1,
    title: "Abyssal Glow",
    subtitle: "Deep sea bioluminescence",
    tag: "OCEAN",
    body: "In the crushing dark below 1000m, life invents its own light.",
    accent: "#00e5ff",
    accentB: "#0077bb",
  },
  {
    id: 2,
    title: "Coral Mind",
    subtitle: "Reef intelligence",
    tag: "BIO",
    body: "A reef is a distributed mind sensing temperature and chemistry.",
    accent: "#ff6b6b",
    accentB: "#cc2244",
  },
];

export default function Example() {
  return (
    <AwesomeFloatingBubbleCarousel
      data={cards}
      heroSize={320}
      satSize={104}
      autoInterval={4400}
      floatIntensity={0.65}
      onCardChange={(i, c) => console.log("Active:", i, c.title)}
      onCardClick={(c) => console.log("Clicked:", c.title)}
    />
  );
}

Styles

The component includes required animations and font variables in its CSS. Most bundlers will pick this up automatically when you import the component. If your app does not, add an explicit CSS import:

import "awesome-floating-bubble-carousel/dist/awesome-floating-bubble-carousel.css";

Props

| Prop | Type | Default | Description | | ---------------- | ------------------------------------------- | ----------- | ------------------------------------------------------------ | | data | BubbleCard[] | undefined | Static data array. If provided, no fetch happens. | | apiEndpoint | string | undefined | URL to JSON data. Accepts an array or an object with data. | | apiHeaders | Record<string, string> | undefined | Extra request headers for fetch. | | apiTransform | (raw: unknown) => BubbleCard[] | undefined | Transform API response to BubbleCard[]. | | heroSize | number | 320 | Hero bubble diameter in px. | | satSize | number | 104 | Satellite bubble diameter in px. | | autoInterval | number | 4400 | Auto-advance interval in ms. | | floatIntensity | number | 0.65 | Float sway intensity, range 0 to 1. | | onCardClick | (card: BubbleCard) => void | undefined | Click handler for the active (hero) bubble. | | onCardChange | (index: number, card: BubbleCard) => void | undefined | Called when active card changes. |

BubbleCard Shape

| Field | Type | Required | Description | | ---------- | ---------------------------- | -------- | ------------------------------------------- | | id | number | Yes | Unique card id. | | title | string | Yes | Card title. | | subtitle | string | No | Optional subtitle. | | tag | string | No | Small label above the title. | | body | string | No | Description text for the info panel. | | accent | string | Yes | Primary color used for glow and UI accents. | | accentB | string | No | Secondary color used for inner bubble glow. | | imageUrl | string | No | Optional image used inside the bubble. | | onClick | (card: BubbleCard) => void | No | Optional per-card click handler. |

Data Examples

1) Static Data

const cards: BubbleCard[] = [
  {
    id: 1,
    title: 'Midnight Zone',
    subtitle: 'Mesopelagic migration',
    tag: 'DEPTH',
    body: 'Between 200m and 1000m lies the twilight zone.',
    accent: '#38bdf8',
    accentB: '#0c4a6e',
  },
  {
    id: 2,
    title: 'Kelp Cathedral',
    subtitle: 'Submarine forest ecology',
    tag: 'FLORA',
    body: 'Giant kelp builds vertical forests up to 40m tall.',
    accent: '#4ade80',
    accentB: '#14532d',
  },
]

<AwesomeFloatingBubbleCarousel data={cards} />

2) Local JSON File

Create a JSON file and serve it from your app. For Vite, place it in public/data/cards.json.

[
  {
    "id": 1,
    "title": "Thermal Vent",
    "subtitle": "Hydrothermal chemistry",
    "tag": "GEO",
    "body": "Superheated water erupts from the seafloor.",
    "accent": "#f59e0b",
    "accentB": "#92400e"
  },
  {
    "id": 2,
    "title": "Salinity Lens",
    "subtitle": "Halocline stratification",
    "tag": "FLOW",
    "body": "A sharp density boundary acts as a sonar mirror.",
    "accent": "#fb923c",
    "accentB": "#7c2d12"
  }
]
<AwesomeFloatingBubbleCarousel apiEndpoint="/data/cards.json" />

3) Remote API Endpoint

If your API returns { data: [...] }, use apiTransform:

// Example response shape
{
  "data": [
    {
      "id": 1,
      "title": "Abyssal Glow",
      "accent": "#00e5ff"
    }
  ]
}
<AwesomeFloatingBubbleCarousel
  apiEndpoint="https://api.example.com/v1/bubbles"
  apiHeaders={{ Authorization: "Bearer YOUR_TOKEN" }}
  apiTransform={(raw: any) => raw.data}
/>

📊 Mock Data

If you need sample data to test your integration, you can use our pre-configured JSON mock file.

Direct Download

Click the button below to view or save the mock data file:

Download the Document

Note: If the file opens in your browser, just right-click and select "Save As..."