0.1.9 • Published 2 years ago

clickfusion v0.1.9

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

ClickFusion

Version Downloads GitHub issues GitHub pull requests License

Welcome to ClickFusion, your go-to library for interactive button effects! This npm package simplifies adding particle effects to your buttons, links, divs or other DOMs. Offering a React functional component to make your UI interactive and delightful.

Quick Links

Table of Contents

Setting up ClickFusion

Installation

You can install ClickFusion using:

Using npm

npm i clickfusion

Running the Development Server

After installation, you can run your development server:

npm run dev

This will usually start your development server on port 3000. Open http://localhost:3000 in your web browser to see your app.

Quick Example

Here's a simple example of how to use ClickFusion in your React application:

import { ClickFusion } from 'clickfusion';

export default function App() {
  return (
    <ClickFusion effect="coolmode">
      <button>
        Click Me!
      </button>
    </ClickFusion>
  );
}

Comprehensive Example

Below is an example that demonstrates the usage of all three effects (coolmode, rainmode, partymode, confettimode, codemode, dragmode) with full property customization.

import { ClickFusion } from 'clickfusion';

export default function App() {
  return (
    <div>
      {/* Using coolmode effect */}
      <ClickFusion 
        effect="coolmode"
        particleOptions={{
          particle: 'customParticleURL', // Optional: string
          size: 40, // Optional: number
          speedHorz: 5, // Optional: number
          speedUp: 10 // Optional: number
        }}
      >
        <button>
          Click Me for Cool Effect!
        </button>
      </ClickFusion>
      
      {/* Using rainmode effect */}
      <ClickFusion
        effect="rainmode"
        particleOptions={{
          particle: 'customParticleURL', // Optional: string
          size: 50, // Optional: number
          speedDown: 5, // Optional: number
          particleCount: 30 // Optional: number
        }}
      >
        <button>
          Click Me for Rain Effect!
        </button>
      </ClickFusion>
      
      {/* Using partymode effect */}
      <ClickFusion
        effect="partymode"
        particleOptions={{
          size: 20, // Optional: number
          particleCount: 45 // Optional: number
        }}
      >
        <button>
          Click Me for Party Effect!
        </button>
      </ClickFusion>

      {/* Using confettimode effect */}
      <ClickFusion 
        effect="confettimode"
        particleOptions={{
          particleCount: 200, // Optional: number
          speedDown: 5, // Optional: number
          color: 'rainbow' // Optional: 'rainbow' | 'red' | 'orange' | 'yellow' | 'green' | 'blue' | 'purple'
        }}
      >
        <button>
          Click Me for Confetti Effect!
        </button>
      </ClickFusion>

      {/* Using codemode effect */}
      <ClickFusion 
        effect="codemode"
        particleOptions={{
          particleCount: 30, // Optional: number
          speedDown: 5, // Optional: number
          color: 'light' // Optional: 'light' | 'dark'
        }}
      >
        <button>
          Click Me for Code Effect!
        </button>
      </ClickFusion>

      {/* Using dragmode effect */}
      <ClickFusion 
        effect="dragmode"
        particleOptions={{
          width: 300, // Optional: number
          height: 300, // Optional: number
          color: 'dark' // Optional: 'light' | 'dark' Transparent by default
        }}
      >
        <button>
          Click Me for Drag Effect!
        </button>
      </ClickFusion>
    </div>
  );
}

Features

Customizable Effects

ClickFusion is highly customizable. Whether you're looking to change particle images, sizes, or speeds, we've got you covered. Learn More

Type Safety

Our TypeScript support ensures a robust and type-safe development experience. Learn More

Contributing

Feel free to dive into our GitHub repository to explore the code and contribute.

License

This project is licensed under the MIT License.

0.1.8

2 years ago

0.1.9

2 years ago

0.1.7

3 years ago

0.1.69

3 years ago

0.1.68

3 years ago

0.1.67

3 years ago

0.1.66

3 years ago

0.1.65

3 years ago

0.1.64

3 years ago

0.1.63

3 years ago

0.1.62

3 years ago

0.1.61

3 years ago

0.1.6

3 years ago

0.1.58

3 years ago

0.1.57

3 years ago

0.1.56

3 years ago

0.1.55

3 years ago

0.1.54

3 years ago

0.1.53

3 years ago

0.1.52

3 years ago

0.1.51

3 years ago

0.1.5

3 years ago

0.1.4-8.2

3 years ago

0.1.471

3 years ago

0.1.48

3 years ago

0.1.47

3 years ago

0.1.46

3 years ago

0.1.44

3 years ago

0.1.43

3 years ago

0.1.42

3 years ago

0.1.41

3 years ago

0.1.4

3 years ago

0.1.39

3 years ago

0.1.38

3 years ago

0.1.37

3 years ago

0.1.36

3 years ago

0.1.35

3 years ago

0.1.34

3 years ago

0.1.33

3 years ago

0.1.32

3 years ago

0.1.31

3 years ago

0.1.3

3 years ago

0.1.29

3 years ago

0.1.28

3 years ago

0.1.27

3 years ago

0.1.26

3 years ago

0.1.25

3 years ago

0.1.24

3 years ago

0.1.23

3 years ago

0.1.22

3 years ago

0.1.21

3 years ago

0.1.2

3 years ago

0.1.19

3 years ago

0.1.18

3 years ago

0.1.17

3 years ago

0.1.16

3 years ago

0.1.15

3 years ago

0.1.14

3 years ago

0.1.13

3 years ago

0.1.12

3 years ago

0.1.11

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago