feat: admin API integration, LogoMark, settings page, i18n, RTL font, docs
- Wire admin API into homepage + templates page (ISR 60s, null fallback) - Add src/lib/admin-api.ts with safeFetch helper - Add adminProjectToTemplateItem + adminProjectToCatalogTemplate mappers - Add LogoMark SVG component, replace Sparkles icon in Navbar/Footer/Sidebar - Add public/favicon.svg (SVG brand mark) - Rewrite opengraph-image.tsx with FlatRender branding - Add RTL/Persian font cascade: unlayered [dir=rtl] block forces Vazirmatn - Dashboard Settings page: Profile, Security, Billing, Notifications sections - Add src/lib/supabase/client.ts browser client - Admin API: GET /me, PATCH /profile, POST /change-password endpoints - Admin API DTOs: AdminUserDto, UpdateProfileRequest, ChangePasswordRequest - Admin UI Settings page with TanStack Query + mutations - Add CLAUDE.md + README.md to both repos for new-machine onboarding - Update PROJECT_MEMORY.md with session log - Add appsettings.Development.json.example template
This commit is contained in:
+57
-8
@@ -185,11 +185,40 @@
|
||||
- [x] `supabase/migrations/001_profiles.sql` — profiles table, RLS
|
||||
- [x] `supabase/migrations/002_render_jobs.sql` — render_jobs table, RLS
|
||||
- [x] `supabase/migrations/003_projects.sql` — projects table, RLS, updated_at trigger
|
||||
- [x] `.env.example` — all required env vars documented
|
||||
- [x] `.env.example` — all required env vars documented (including `ADMIN_API_URL`)
|
||||
- [x] `next.config.mjs` — webpack globalObject fix + COOP/COEP headers (required for ffmpeg.wasm)
|
||||
- [x] `.cursorrules` — full project rules for Cursor AI
|
||||
- [x] `tailwind.config.ts` — custom colors, font families
|
||||
- [x] `tailwind.config.ts` — custom colors, font families (heading, body, vazirmatn)
|
||||
- [x] `components.json` — shadcn/ui config
|
||||
- [x] `CLAUDE.md` — Claude Code instructions (auto-read on session start)
|
||||
- [x] `public/favicon.svg` — brand favicon (SVG, blue rounded square + play icon)
|
||||
|
||||
### i18n
|
||||
- [x] `messages/fa.json` + `messages/en.json` — full translations for all public pages
|
||||
- [x] Namespaces: hero, nav, products, templates, pricing, testimonials, faq, footer, metadata, videoMaker, imageMaker
|
||||
- [x] `globals.css` — `[dir="rtl"]` block forces Vazirmatn on all elements in Persian locale
|
||||
- [x] `src/i18n/routing.ts` — `fa` default (no prefix), `en` at `/en/`
|
||||
|
||||
### Brand / Logo
|
||||
- [x] `src/components/ui/LogoMark.tsx` — inline SVG brand mark (play triangle + 3 layer bars in blue square)
|
||||
- [x] Navbar, Footer, DashboardSidebar — all use `<LogoMark>` (removed old `<Sparkles>` icon)
|
||||
- [x] `app/opengraph-image.tsx` — proper FlatRender OG image (1200×630, headline + feature pills)
|
||||
|
||||
### Admin Panel integration
|
||||
- [x] `src/lib/admin-api.ts` — `fetchCategories`, `fetchProjects`, `fetchProject`, `isAdminApiAvailable`
|
||||
- [x] `app/[locale]/page.tsx` — async, fetches 8 projects → `<TemplateGallery adminItems={...}>`
|
||||
- [x] `app/[locale]/templates/page.tsx` — async, fetches 100 video projects → `initialCatalog`
|
||||
- [x] `TemplateGallery.tsx` — accepts `adminItems` prop, maps `AdminProject` → `TemplateItem`
|
||||
- [x] `VideoTemplatesPageContent.tsx` — accepts `initialCatalog` prop
|
||||
- [x] `video-templates-catalog.ts` — `adminProjectToCatalogTemplate()` mapper added
|
||||
|
||||
### Dashboard Settings
|
||||
- [x] `/dashboard/settings` — full settings page (Profile, Security, Billing, Notifications, Danger zone)
|
||||
- [x] `src/lib/supabase/client.ts` — browser Supabase client (for client-side auth updates)
|
||||
- [x] `SettingsProfile.tsx` — editable display name via `supabase.auth.updateUser`
|
||||
- [x] `SettingsSecurity.tsx` — change password (re-authenticates first)
|
||||
- [x] `SettingsBilling.tsx` — plan info + features + Stripe billing portal link
|
||||
- [x] `SettingsNotifications.tsx` — 4 email toggle switches
|
||||
|
||||
---
|
||||
|
||||
@@ -197,20 +226,29 @@
|
||||
|
||||
_Nothing currently in progress._
|
||||
|
||||
### Landing page status (2026-05-21 polish)
|
||||
- `npx tsc --noEmit` — clean (no TypeScript errors)
|
||||
- Tailwind `rf.blue` / `rf.blue-light` — `#2563EB` / `#EFF6FF`
|
||||
- Remaining pre-launch work is env/migrations/E2E tests (see Must Do backlog), not landing UI
|
||||
### Status as of 2026-05-27
|
||||
- `npx tsc --noEmit` — clean (zero TypeScript errors)
|
||||
- All public pages fully built and i18n'd (fa + en)
|
||||
- Admin panel fully built (backend + frontend) — needs real Postgres + MinIO credentials
|
||||
- Admin API integrated into Next.js with ISR fallback
|
||||
- Logo, favicon, OG image all done
|
||||
- Dashboard settings page fully functional
|
||||
- Next step: fill in `.env.local` credentials and test end-to-end
|
||||
|
||||
---
|
||||
|
||||
## 📋 Backlog (Next Tasks)
|
||||
|
||||
### 🔴 Must Do Before Launch
|
||||
- [ ] Create `.env.local` from `.env.example` and fill in real keys ← NOT DONE YET
|
||||
- [ ] Run Supabase migrations (`001` → `002` → `003`) in SQL Editor ← NOT DONE YET
|
||||
- [ ] Create `.env.local` from `.env.example` and fill in Supabase + Stripe keys
|
||||
- [ ] Run Supabase migrations (`001` → `002` → `003`) in SQL Editor
|
||||
- [ ] Set up admin API: copy `appsettings.Development.json.example` → `appsettings.Development.json`, fill Postgres + MinIO
|
||||
- [ ] Seed first admin: `POST /api/auth/seed` with email + password
|
||||
- [ ] Upload real template categories + projects via admin panel (auto-appears on website)
|
||||
- [ ] Add real logo image/video assets (currently using picsum + Mixkit placeholders)
|
||||
- [ ] Test full auth flow (sign up → dashboard → create project → open studio)
|
||||
- [ ] Test ffmpeg.wasm trimmer end-to-end in browser
|
||||
- [ ] Build settings page "Delete account" confirmation flow
|
||||
|
||||
### 🟡 UI Polish (Cursor screenshot-driven)
|
||||
- [x] Navbar: Video/Image Maker + Learn dropdowns (Renderforest-style, no mega menu)
|
||||
@@ -356,3 +394,14 @@ supabase/
|
||||
| 2026-05-21 | Discovered `ProductsMegaMenu` already fully built — moved from backlog to done |
|
||||
| 2026-05-21 | Added `PricingCompareTable` with 5 feature sections matching Renderforest /subscription layout |
|
||||
| 2026-05-21 | Scene thumbnails: `thumbnailUrl` on Scene, `updateSceneThumbnail`, `DraggableSceneItem` img preview |
|
||||
| 2026-05-27 | Built admin panel at `D:\Projects\flatrender-admin`: .NET 10 API + React SPA. Categories/Projects/Media CRUD, JWT auth, MinIO storage, public endpoints |
|
||||
| 2026-05-27 | i18n: added `videoMaker` + `imageMaker` namespaces (fa + en), wired `useTranslations` in all 8 components |
|
||||
| 2026-05-27 | Wired admin API into Next.js: `admin-api.ts`, homepage + templates page async with ISR, `TemplateGallery` accepts `adminItems` |
|
||||
| 2026-05-27 | RTL fix: `globals.css` `[dir="rtl"]` block forces Vazirmatn on every text element |
|
||||
| 2026-05-27 | `LogoMark` SVG component — replaces Sparkles in Navbar, Footer, DashboardSidebar; `public/favicon.svg` added |
|
||||
| 2026-05-27 | OG image rebranded FlatRender with logo, feature pills |
|
||||
| 2026-05-27 | Dashboard settings page: Profile, Security (pw change), Billing (plan + Stripe link), Notifications toggles |
|
||||
| 2026-05-27 | Admin API: added `GET /api/auth/me`, `PATCH /api/auth/profile`, `POST /api/auth/change-password` |
|
||||
| 2026-05-27 | Admin UI: Settings page (profile edit + password change), Settings link in sidebar |
|
||||
| 2026-05-27 | `appsettings.Development.json.example` created for admin API local setup |
|
||||
| 2026-05-27 | `CLAUDE.md` created — Claude Code auto-reads on session start |
|
||||
|
||||
Reference in New Issue
Block a user