Skip to content

chauhankashmira/Flower-Animation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Project Title: Flower Animation

Kash Chauhan

This project showcases a beautiful flower animation created using JavaScript, HTML, and CSS. The animation dynamically generates flower petals and animates their growth and movement, resulting in a visually captivating display.

Features

  • Dynamic generation of flower petals.
  • Smooth animations for petal growth and rotation.
  • Configurable options for colors, sizes, and animation speed.
  • Lightweight and runs in the browser with no external dependencies.

Installation

  1. Clone the repository:

    git clone https://github.com/chauhankashmira/flower-animation-js.git
    cd flower-animation-js
  2. Open the index.html file in your browser:

    open index.html

Usage

  1. Edit the config object in the JavaScript file to customize the animation:

    const config = {
        petalCount: 20, // Number of petals per flower
        petalColors: ['#FFB6C1', '#FF69B4', '#FF1493'], // Array of colors
        animationSpeed: 2, // Speed of petal animations in seconds
        flowerSize: 100 // Diameter of the flower in pixels
    };
  2. Refresh the browser to see your changes.

How It Works

The animation is implemented using:

  • HTML5 Canvas for drawing petals and animating them.
  • JavaScript for creating and animating the flower elements dynamically.
  • CSS for styling the background and other elements (if needed).

File Structure

flower-animation-js/
├── index.html      # Main HTML file
├── style.css       # Styles for the page
├── script.js       # JavaScript code for the animation
└── README.md       # Project documentation

Compatibility

  • This project is compatible with all modern browsers that support HTML5 and JavaScript.

Contributing

Contributions are welcome! Feel free to fork this repository, make changes, and submit a pull request.

License

This project is licensed under the MIT License. See the LICENSE file for details.


Enjoy the beauty of animated flowers! 🌸

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published