Aesthetic task manager built with Spring Boot 4, Thymeleaf, and MySQL β designed to make staying organized feel a little more bloomy.
Spring-Boot Todo application is a server-rendered task management web app with a kawaii aesthetic. It features priority levels, filterable task views, a live progress bar, inline editing, and a soft pastel UI with falling sakura petals, a cat mascot, and friendly toast notifications.
Built as a learning project to demonstrate clean Spring Boot architecture β controller / service / repository layering, DTOs, bean validation, centralized exception handling, and proper HTTP method semantics β wrapped in a thoughtful, animated UI.
| Category | What you get |
|---|---|
| Task management | Create, toggle, edit, and delete tasks |
| Priority levels | Low π± Β· Medium πΈ Β· High π₯ with colored badges |
| Filter tabs | All / Active / Done β with live counts per tab |
| Progress tracking | Live progress bar with shimmer + completion celebration |
| Bulk actions | One-click "Clear completed" with confirmation |
| Inline edit | Modal dialog prefilled with current task data |
| Toast notifications | Friendly feedback after every action |
| Cute aesthetic | Sakura Kawaii palette, cat mascot π±, falling petals, heartbeat footer |
| Responsive | Mobile-first layout, works from 360px upward |
| Accessible | ARIA labels, keyboard-navigable modal (ESC to close), prefers-reduced-motion support |
| Layer | Technology |
|---|---|
| Language | Java 17 |
| Framework | Spring Boot 4.1.0 |
| Web | Spring MVC + Thymeleaf |
| Persistence | Spring Data JPA Β· Hibernate |
| Database | MySQL 8+ |
| Validation | Bean Validation (JSR-380) |
| Build tool | Maven 3.9+ (wrapper included) |
| Frontend | Vanilla CSS + JS (no framework), Bootstrap Icons, Google Fonts |
| Boilerplate | Lombok |
src/main/java/com/bishwakarma/learning/todoapp/
βββ TodoAppApplication.java β Spring Boot entry point
βββ controller/
β βββ TodoController.java β HTTP routing (GET/POST/PATCH/DELETE)
βββ service/
β βββ TodoService.java β Business logic, @Transactional boundary
βββ repository/
β βββ TodoRepository.java β Spring Data JPA + custom queries
βββ entity/
β βββ Todo.java β JPA entity with timestamps + priority
βββ dto/
β βββ TodoRequest.java β Validated input payload
β βββ TodoResponse.java β Read-only view DTO
βββ enums/
β βββ Priority.java β LOW / MEDIUM / HIGH with UI metadata
βββ exception/
βββ TodoNotFoundException.java
βββ GlobalExceptionHandler.java β @ControllerAdvice
src/main/resources/
βββ application.properties β Env-var-aware configuration
βββ static/
β βββ css/style.css β Sakura Kawaii theme
β βββ js/app.js β Edit-modal interactions
βββ templates/
βββ index.html β Main Thymeleaf view
βββ error.html β Friendly error fallback
- JDK 17+
- Maven 3.9+ (or use the bundled
./mvnw) - MySQL 8+ running on
localhost:3306
The JDBC URL includes createDatabaseIfNotExist=true, so you only need a user with database-creation privileges:
CREATE USER IF NOT EXISTS 'todo_user'@'%' IDENTIFIED BY 'TodoApp_Password2026!';
GRANT ALL PRIVILEGES ON *.* TO 'todo_user'@'%';
FLUSH PRIVILEGES;https://github.com/Manish-Royan/Spring-Boot-Todo-Application.git
cd Spring-Boot-Todo-Application-main
./mvnw spring-boot:runOpen http://localhost:8080 β you should see the Spring-Boot Todo UI πΈ
The defaults work out-of-the-box for local dev. For a different setup, set environment variables:
export TODO_DB_URL='jdbc:mysql://localhost:3306/todo_db?useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=UTC&createDatabaseIfNotExist=true'
export TODO_DB_USER='your_user'
export TODO_DB_PASSWORD='your_password'
./mvnw spring-boot:run./mvnw clean package
java -jar target/todoApp-1.0.0.jar| Method | URL | Purpose |
|---|---|---|
GET |
/ |
Home page (supports ?filter=all|active|completed) |
POST |
/todos |
Create a new todo |
PATCH |
/todos/{id}/toggle |
Toggle the done flag |
PATCH |
/todos/{id} |
Edit title / priority |
DELETE |
/todos/{id} |
Delete a single todo |
DELETE |
/todos/completed |
Bulk-clear completed todos |
Browsers only support
GET/POSTnatively βPATCHandDELETEgo through a hidden_methodinput. The filter is enabled viaspring.mvc.hiddenmethod.filter.enabled=trueinapplication.properties.
The Sakura Kawaii palette is defined as CSS custom properties at the top of style.css:
| Token | Colour | Used for |
|---|---|---|
--pink-50 |
#fff5f8 |
Page background base |
--pink-200 |
#ffd6e4 |
Borders, soft accents |
--pink-400 |
#ff8fab |
Primary accent (buttons) |
--pink-500 |
#f569a0 |
Headings, strong accent |
--peach |
#ffb7a3 |
Secondary accent (progress gradient) |
--cream |
#fffaf3 |
Page background secondary |
--mint-deep |
#7ec8a3 |
Completed state |
Fonts: Pacifico (logo), Quicksand (headings), Nunito (body) β all from Google Fonts.
./mvnw testThe smoke test (TodoAppApplicationTests) uses H2 in-memory so it doesn't require a running MySQL β the test profile swaps the datasource via @TestPropertySource.
This project follows the classic 3-layer Spring architecture:
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Controller (HTTP routing, view rendering) β
β β β
β Service (business logic, @Transactional) β
β β β
β Repository (Spring Data JPA, custom queries) β
β β β
β Database (MySQL) β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
- DTOs (
TodoRequest/TodoResponse) decouple the wire format from the persistence format and prevent mass-assignment. @ControllerAdvicecentralizes error handling β every exception maps to a user-friendly outcome (toast notification or cute error page).- JPA lifecycle callbacks (
@PrePersist/@PreUpdate) auto-populatecreatedAt/updatedAt. - Bean Validation (
@NotBlank,@Size) rejects bad input at the API boundary with a 400, not a 500.
Possible future enhancements:
- Pagination for large task lists
- Search/filter by title substring
- Drag-and-drop reordering with
order_indexfield - Due dates with overdue highlighting
- Categories / tags (many-to-many)
- REST endpoints + AJAX (no full page reload)
- Service-layer unit tests with Mockito
- Docker Compose for one-command setup
- Deploy to Railway / Fly.io / Render
Released under the MIT License. See LICENSE for details.
made with passion πΈ
Happy Coding π€
