diff --git a/Domains/Frontend/MiniProjects/BirthdayReminder/README.md b/Domains/Frontend/MiniProjects/BirthdayReminder/README.md new file mode 100644 index 00000000..34c2c3de --- /dev/null +++ b/Domains/Frontend/MiniProjects/BirthdayReminder/README.md @@ -0,0 +1,49 @@ +# ๐ Birthday Reminder App + +**Contributor:** [Tanmay-Kad](https://github.com/Tanmay-Kad) + +--- + +## ๐งพ Description +A **modern and interactive Birthday Reminder web app** that helps you keep track of your loved ones' birthdays effortlessly. +This app lets you add, view, and delete birthdays โ with automatic countdowns and a **confetti celebration** when itโs someoneโs birthday! ๐ + +Built with **HTML**, **CSS (Tailwind)**, and **JavaScript**, it provides a smooth and elegant user experience with local storage support to remember all your entries. + +--- + +## ๐ Features +- Add birthdays with **name** and **date**. +- Displays countdown for **upcoming birthdays**. +- Automatic sorting of birthdays (nearest first). +- Beautiful **confetti animation** when it's someone's birthday ๐. +- Option to **delete birthdays** anytime. +- Data stored using **LocalStorage** (persists even after refreshing). +- Fully responsive and modern UI using **Tailwind CSS**. + +--- + +## ๐ก Bonus Features +- ๐ Confetti animation for birthday celebrations. +- ๐ Automatic day calculation for each entry. +- โจ Smooth hover effects and transitions. +- ๐๏ธ Slide-in delete button on hover. + +--- + +## ๐งฉ Tech Stack +- **HTML5** โ Structure and layout +- **Tailwind CSS** โ Styling and responsiveness +- **JavaScript (Vanilla)** โ Logic, animations, and LocalStorage + +--- + +## ๐น๏ธ How to Use +1. Open `index.html` in your browser. +2. Enter a **name** and **birthdate**. +3. Click **โAdd Birthdayโ**. +4. View the countdown for upcoming birthdays. +5. Watch the confetti rain down when itโs someoneโs special day! ๐ +6. Use the **delete button** (๐๏ธ) to remove any entry. + +--- \ No newline at end of file diff --git a/Domains/Frontend/MiniProjects/BirthdayReminder/index.html b/Domains/Frontend/MiniProjects/BirthdayReminder/index.html new file mode 100644 index 00000000..1bb5fd52 --- /dev/null +++ b/Domains/Frontend/MiniProjects/BirthdayReminder/index.html @@ -0,0 +1,49 @@ + + +
+ + +Never miss a special day again!
+No birthdays added yet.
'; + return; + } + + let isBirthdayToday = false; + + birthdays.forEach(birthday => { + const daysLeft = birthday.daysLeft; + const formattedDate = new Date(birthday.date).toLocaleDateString('en-US', { month: 'long', day: 'numeric' }); + + let countdownText = ''; + let bgColor = 'bg-white'; + let textColor = 'text-gray-800'; + + if (daysLeft === 0) { + countdownText = `๐ It's Today! Happy Birthday!`; + bgColor = 'bg-rose-100'; + isBirthdayToday = true; + } else if (daysLeft === 1) { + countdownText = `${daysLeft} day left`; + } else { + countdownText = `${daysLeft} days left`; + } + + const item = document.createElement('div'); + item.className = `birthday-item flex items-center justify-between p-3 ${bgColor} rounded-lg shadow-sm transition-all`; + + item.innerHTML = ` +${birthday.name}
+${formattedDate}
+${countdownText}
+ +