An open API service indexing awesome lists of open source software.

https://github.com/sohom09/calculator

A sleek, responsive Calculator Web Application built using HTML, CSS, and JavaScript.
https://github.com/sohom09/calculator

calculator coding css3 html-css-javascript html5 javascript project

Last synced: 22 days ago
JSON representation

A sleek, responsive Calculator Web Application built using HTML, CSS, and JavaScript.

Awesome Lists containing this project

README

          

# ๐ŸŒ— Gradient Calculator Web App

A sleek, responsive **Calculator Web Application** built using **HTML**, **CSS**, and **JavaScript**. This project features a beautiful **linear gradient light/dark mode toggle**, basic arithmetic operations, percentage calculations, button **sound effects**, and full **keyboard input support** Creating a basic calculator to do basic arithmetic operations. Using HTML, CSS, JS..

---

## ๐Ÿ”ฎ Features

- ๐ŸŽจ **Light & Dark Themes** with smooth linear gradients
- ๐Ÿงฎ Basic operations: `+`, `โˆ’`, `ร—`, `รท`, `.`, `%`
- ๐ŸŒ— **Theme toggle** (โ˜€๏ธ Light โ†” ๐ŸŒ™ Dark)
- ๐Ÿ”Š Button **click sound effects**
- โŒ **Clear all** function (`AC` and โœ–)
- โŒจ๏ธ **Keyboard support** for all inputs
- ๐Ÿ“ฑ Fully **responsive design** for mobile and desktop

---

## ๐Ÿ”— Live Preview

๐Ÿ‘‰ [Click to open the calculator](https://htmlpreview.github.io/?https://github.com/sohom09/calculator/blob/main/index.html)

---

## ๐Ÿ–ผ๏ธ Screenshots

| Light Mode | Dark Mode |
|------------|-----------|
| ![Light](light-mode.png) | ![Dark](dark-mode.png) |

---

## ๐Ÿ“‚ Project Structure
- ๐Ÿ“ calculator-gradient-theme/
โ”œโ”€โ”€ index.html # HTML layout and structure
โ”œโ”€โ”€ style.css # Linear gradient themes, layout, responsiveness
โ”œโ”€โ”€ script.js # Logic, sound, toggle, keyboard input
โ”œโ”€โ”€ click.mp3 # Button click sound effect
โ””โ”€โ”€ README.md # Project documentation
---

## ๐Ÿš€ How to Run Locally

1. **Clone the repository**
```bash
git clone https://github.com/sohom09/calculator.git

## 2. Navigate to the project folder
```bash
cd calculator-gradient-theme

## 3. Open index.html in your browser.

### ๐Ÿ› ๏ธ Tech Stack
- HTML5 โ€“ Markup structure
- CSS3 โ€“ Styling, linear gradients, responsive design
- JavaScript (Vanilla) โ€“ Calculator logic, DOM interaction, sound effects

### ๐Ÿ“Œ Notes
- The % button divides the current value by 100.
- The ร— icon acts as a visual "Clear All" (same as AC).
- eval() is used for expression evaluation โ€” secure for local projects, but not recommended in production apps.

### ๐Ÿ’ก Future Enhancements
๐Ÿง  Calculation history

๐Ÿ“ Scientific calculator mode (sin, cos, log, etc.)

๐Ÿ’พ Remember theme preference using localStorage

### ๐Ÿค Contribution
Feel free to fork the repo, submit pull requests, or suggest features!

### ๐Ÿ“œ License
This project is open-source and available under the MIT License.

### ๐Ÿ‘ค Author
- Developed by Sohom Chakraborty

### ๐Ÿ”— GitHub Profile