Skip to content

Firework Celebration

A success button that bursts into colorful exploding sparks with a celebratory feel

Firework Celebration

by FreeCsStyles Dev's

AnimatedCelebratory
🌐🎨⚛️💚🅰️🔥☁️
#firework#celebration#spark#success#explode#celebrate#confetti

Embed this component

Paste this snippet into any site — the design renders in a sandboxed iframe served from /embed/firework-celebration.

<iframe src="/embed/firework-celebration" sandbox="allow-scripts" loading="lazy" title="Firework Celebration" style="border:0;width:100%;height:480px;overflow:hidden"></iframe>

Implementation code

Copy the HTML and CSS for Firework Celebration, or grab a framework-specific implementation. The HTML and CSS variants are self-contained; framework variants assume that framework's project setup.

HTML
<button class="btn-firework"><span class="text">Success</span></button>
CSS
.btn-firework{width:160px;height:50px;border-radius:12px;border:none;background:#2563eb;color:#fff;font-size:16px;font-weight:700;cursor:pointer;position:relative;display:flex;align-items:center;justify-content:center;overflow:hidden;transition:all .4s;font-family:system-ui,sans-serif;box-shadow:0 4px 15px rgba(37,99,235,.4)}.btn-firework .firework-spark{position:absolute;width:6px;height:6px;border-radius:50%;opacity:0;pointer-events:none}.btn-firework.is-launched{background:#16a34a}.btn-firework.is-launched .firework-spark{animation:explode-spark .8s forwards ease-out}@keyframes explode-spark{0%{transform:translate(0,0) scale(1);opacity:1}100%{transform:translate(var(--tx),var(--ty)) scale(0);opacity:0}}
Tailwind CSS
<button class="w-[160px] h-[50px] rounded-xl border-none bg-blue-600 text-white font-bold cursor-pointer relative flex items-center justify-center overflow-hidden transition-all duration-[400ms] font-sans shadow-[0_4px_15px_rgba(37,99,235,0.4)]"><span class="relative z-10">🎉 Success</span></button>
React
import { useState } from 'react';
export function FireworkCelebration() {
  const [phase, setPhase] = useState('idle');
  const handleClick = () => {
    if (phase !== 'idle') return;
    setPhase('launched');
    setTimeout(() => setPhase('idle'), 3500);
  };
  return (
    <button onClick={handleClick} disabled={phase !== 'idle'}
      style={{ width: 160, height: 50, borderRadius: 12, border: 'none', background: phase === 'launched' ? '#16a34a' : '#2563eb', color: '#fff', fontSize: 16, fontWeight: 'bold', cursor: 'pointer', position: 'relative', display: 'flex', alignItems: 'center', justifyContent: 'center', overflow: 'hidden', fontFamily: 'system-ui,sans-serif', transition: 'all 0.4s', boxShadow: phase === 'launched' ? '0 4px 15px rgba(22,163,74,0.4)' : '0 4px 15px rgba(37,99,235,0.4)' }}>
      <span>{phase === 'idle' ? '🎉 Success' : '✨ Celebrating!'}</span>
    </button>
  );
}
Vue
<template>
  <button class="btn-firework" :class="phase" @click="handleClick" :disabled="phase!=='idle'">
    <span class="text">{{ phase==='idle' ? 'Success' : 'Celebrating!' }}</span>
  </button>
</template>
<script setup>
import { ref } from 'vue';
const phase = ref('idle');
function handleClick() {
  if (phase.value !== 'idle') return;
  phase.value = 'launched';
  setTimeout(() => phase.value = 'idle', 3500);
}
</script>
Svelte
<script>
  let phase = 'idle';
  function handleClick() { if (phase !== 'idle') return; phase = 'launched'; setTimeout(() => phase = 'idle', 3500); }
</script>
<button class="btn-firework" class:is-launched={phase==='launched'} on:click={handleClick} disabled={phase!=='idle'}>
  <span class="text">{phase==='idle' ? 'Success' : 'Celebrating!'}</span>
</button>
Angular
import { Component } from '@angular/core';
@Component({
  selector: 'app-firework-celebration',
  template: `<button class="btn-firework" [class.is-launched]="phase==='launched'" (click)="handleClick()" [disabled]="phase!=='idle'"><span class="text">{{ phase==='idle' ? 'Success' : 'Celebrating!' }}</span></button>`,
  styles: [`.btn-firework{width:160px;height:50px;border-radius:12px;border:none;background:#2563eb;color:#fff;font-size:16px;font-weight:700;cursor:pointer;position:relative;display:flex;align-items:center;justify-content:center;overflow:hidden}.btn-firework.is-launched{background:#16a34a}`]
})
export class FireworkCelebrationComponent { phase='idle';handleClick(){if(this.phase!=='idle')return;this.phase='launched';setTimeout(()=>this.phase='idle',3500);}}
LWC — HTML template
<template><button class="btn-firework" onclick={handleClick} disabled={disabled}><span>{label}</span></button></template>
LWC — JavaScript
import { LightningElement } from 'lwc';
export default class FireworkCelebration extends LightningElement {
  phase = 'idle';
  get disabled() { return this.phase !== 'idle'; }
  get label() { return this.phase==='idle'?'🎉 Success':'✨ Celebrating!'; }
  handleClick() { if(this.phase!=='idle')return;this.phase='launched';setTimeout(()=>this.phase='idle',3500); }
}
LWC — CSS
.btn-firework{width:160px;height:50px;border-radius:12px;border:none;background:#2563eb;color:#fff;font-size:16px;font-weight:700;cursor:pointer;position:relative;display:flex;align-items:center;justify-content:center;overflow:hidden;transition:all .4s}.btn-firework.is-launched{background:#16a34a}
LWC — Configuration
<?xml version="1.0" encoding="UTF-8"?>
<LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata">
  <apiVersion>59.0</apiVersion>
  <isExposed>true</isExposed>
  <targets><target>lightning__AppPage</target><target>lightning__RecordPage</target><target>lightning__HomePage</target></targets>
</LightningComponentBundle>

Where Firework Celebration fits

  • Success Actions
  • Celebrations
  • Achievements
  • Form Submit
  • Positive Feedback

Interaction states & animations

  • Spark Explosion
  • Celebration Burst

Topics

  • #firework
  • #celebration
  • #spark
  • #success
  • #explode
  • #celebrate
  • #confetti

Accessibility notes

Animation is decorative. Button text remains readable. Respect reduced-motion preference.

Browser support

  • All modern browsers