feat: phase 3 website pages on v1 api

This commit is contained in:
Dwindi Ramadhana
2026-02-03 22:37:52 +07:00
parent 8816522ddd
commit b1aefa6b3d
13 changed files with 563 additions and 4 deletions

42
phase-3-website.md Normal file
View File

@@ -0,0 +1,42 @@
# Phase 3 Website Delivery
## Implemented routes
In `app/routes/web.php`:
- `GET /` (home)
- `GET /emoji/{slug}` (detail)
- `GET /api-docs`
- `GET /pricing`
- `GET /privacy`
- `GET /terms`
## Implemented pages
In `app/resources/views/site/`:
- `layout.blade.php`
- `home.blade.php`
- `emoji-detail.blade.php`
- `api-docs.blade.php`
- `pricing.blade.php`
- `privacy.blade.php`
- `terms.blade.php`
## Behavior
- Home page fetches categories and emojis from the new APIs:
- `/v1/categories`
- `/v1/emojis`
- Supports search/category/subcategory filtering and pagination via "Load more".
- Emoji cards link to server-rendered detail page by slug.
## Controller
- `app/app/Http/Controllers/Web/SiteController.php`
- Handles page rendering and slug-based emoji lookup from configured dataset.
## Test coverage
- `app/tests/Feature/SitePagesTest.php`
- Validates core pages, valid emoji detail, and 404 for invalid slug.