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

celebration-flip

v1.0.1

Published

A beautiful animated flip text component for celebrating milestones with customizable text and hearts

Readme

🎉 CelebrationFlip

A beautiful animated flip text component for celebrating milestones with customizable text and hearts. Perfect for social media celebrations, milestone announcements, and achievement showcases.

npm version License: MIT Bundle Size Downloads

✨ Features

  • 🎬 Smooth flip animations with CSS transforms and 60fps performance
  • 🎨 Fully customizable - Colors, text, duration, and styling
  • 📱 Responsive design - Works perfectly on mobile, tablet, and desktop
  • Ultra lightweight - Less than 5KB minified + gzipped
  • 🔧 Zero configuration - Works out of the box with sensible defaults
  • 🌐 Framework agnostic - React, Vue, Svelte, or vanilla HTML/CSS
  • Accessibility first - Respects prefers-reduced-motion and screen readers
  • 🎯 TypeScript ready - Full type definitions included
  • 📦 Multiple formats - ESM, CommonJS, and UMD builds
  • 🎨 Retro aesthetic - Uses the beautiful "Sixtyfour" pixel font

📦 Installation

# npm
npm install celebration-flip

# yarn
yarn add celebration-flip

# pnpm
pnpm add celebration-flip

# bun
bun add celebration-flip

Or use it directly from CDN (no installation required):

<!-- CSS -->
<link
  rel="stylesheet"
  href="https://unpkg.com/celebration-flip@latest/dist/styles.css"
/>

<!-- ESM -->
<script type="module">
  import { CelebrationFlip } from "https://unpkg.com/celebration-flip@latest/dist/index.esm.js";
</script>

🚀 Quick Start

React Component

import { CelebrationFlip } from "celebration-flip";
import "celebration-flip/dist/styles.css";

function App() {
  return (
    <div
      style={{
        background: "#111",
        minHeight: "100vh",
        display: "grid",
        placeContent: "center",
      }}
    >
      <CelebrationFlip
        mainText="4000 SUSCRIPTORES"
        secondaryText="¡GRACIAS!"
        primaryColor="dodgerblue"
        secondaryColor="hotpink"
        duration={3}
      />
    </div>
  );
}

Vanilla HTML/CSS

<!DOCTYPE html>
<html>
  <head>
    <link
      rel="stylesheet"
      href="https://unpkg.com/celebration-flip/dist/styles.css"
    />
    <style>
      body {
        background: #111;
        margin: 0;
        min-height: 100vh;
        display: grid;
        place-content: center;
      }
    </style>
  </head>
  <body>
    <div
      class="celebration-flip"
      style="--clr-1: dodgerblue; --clr-2: hotpink; --duration: 3s;"
    >
      <div class="flip-text">
        <span>4</span><span>0</span><span>0</span><span>0</span><span></span>
        <span>S</span><span>U</span><span>S</span><span>C</span><span>R</span
        ><span>I</span><span>P</span><span>T</span><span>O</span><span>R</span
        ><span>E</span><span>S</span>
      </div>
      <div class="flip-text">
        <span>♥</span><span>♥</span><span>♥</span><span>♥</span><span></span>
        <span>¡</span><span>G</span><span>R</span><span>A</span><span>C</span
        ><span>I</span><span>A</span><span>S</span><span>!</span><span></span>
        <span>♥</span><span>♥</span><span>♥</span><span>♥</span>
      </div>
    </div>
  </body>
</html>

📖 API Reference

Props (React)

| Prop | Type | Default | Description | | ---------------- | -------- | -------------- | ------------------------------------------------ | | mainText | string | required | Main text to display (e.g., "4000 SUSCRIPTORES") | | secondaryText | string | required | Secondary text to display (e.g., "¡GRACIAS!") | | primaryColor | string | "dodgerblue" | Primary color for main text | | secondaryColor | string | "hotpink" | Secondary color for hearts and secondary text | | duration | number | 3 | Animation duration in seconds | | className | string | "" | Custom CSS class name |

CSS Custom Properties (Vanilla)

| Property | Default | Description | | ------------ | ------------ | --------------------------------------------- | | --clr-1 | dodgerblue | Primary color for main text | | --clr-2 | hotpink | Secondary color for hearts and secondary text | | --duration | 3s | Animation duration |

🎨 Examples

Different Milestones

// 1000 Followers
<CelebrationFlip
  mainText="1000 FOLLOWERS"
  secondaryText="THANK YOU"
  primaryColor="#00ff88"
  secondaryColor="#ff6b35"
/>

// 1M Views
<CelebrationFlip
  mainText="1M VIEWS"
  secondaryText="INCREDIBLE"
  primaryColor="#ff0080"
  secondaryColor="#8000ff"
  duration={2}
/>

// 10K Likes
<CelebrationFlip
  mainText="10K LIKES"
  secondaryText="AMAZING"
  primaryColor="gold"
  secondaryColor="orange"
  duration={4}
/>

Custom Styling

<CelebrationFlip
  mainText="CUSTOM STYLE"
  secondaryText="AWESOME"
  primaryColor="linear-gradient(45deg, #ff6b6b, #4ecdc4)"
  secondaryColor="linear-gradient(45deg, #45b7d1, #96ceb4)"
  className="my-custom-celebration"
/>
.my-custom-celebration {
  filter: drop-shadow(0 0 20px rgba(255, 107, 107, 0.5));
}

🎯 Use Cases

  • 📊 Social Media Milestones - Celebrate follower counts, likes, shares
  • 🏆 Achievement Announcements - App downloads, user registrations
  • 💰 Business Metrics - Revenue goals, customer milestones
  • 🎓 Educational Platforms - Course completions, student enrollments
  • 🎮 Gaming - High scores, level completions
  • 📈 Analytics Dashboards - KPI celebrations

🌐 Browser Support

  • ✅ Chrome 60+
  • ✅ Firefox 55+
  • ✅ Safari 12+
  • ✅ Edge 79+

♿ Accessibility

The component respects the prefers-reduced-motion media query. Users who have requested reduced motion will see a static version without animations.

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

📄 License

MIT © Formmy Team

🔗 Links


Made with ❤️ by the Formmy team