How davipeter07/alice-blog works
Alice-Blog is a Next.js publication for essays, with reader-facing landing and paginated/tag-filtered articles, nested comments and likes, plus account and admin workflows. The graph shows routes invoking data access or Server Actions, with Prisma as persistence, and captures the documented theme and no-login reading preferences. Unsampled feature paths are included only at directory level when the tree and README establish the capability; their internal links are omitted where no relationship is evidenced.
Main entry points: [slug]/page.tsx Article detail · posts.ts Post data access · prisma.ts PostgreSQL · app/page.tsx Landing experience
Components 25
Reader publishing
- Landing experience
src/app/page.tsx - Landing sections
src/components/blog - Article listing
src/app/blog/page.tsx - Post cards
src/components/blog/post-card.tsx - Article detail
src/app/blog/[slug]/page.tsx - Markdown rendering
src/app/blog/[slug]/page.tsx
Reader engagement
- Nested comments
src/components/blog/comment-section.tsx - Comment interactions
src/hooks/use-comment-section.ts - Comment actions
src/actions/comments.ts - Post likes
src/actions/likes.ts
Identity and admin
- Post administration
src/app/admin/posts - Post editor
src/components/admin/post-form.tsx - Login and registration
src/app/auth - Authentication actions
src/actions/auth.ts - Cookie sessions
src/lib/auth.ts
Reader preferences
- Preferences panel
src/components/preferences/preferences-panel.tsx - Preference state
src/hooks/use-preferences.ts - Theme mode
src/hooks/use-theme-mode.ts - Local preferences
src/lib/preferences.ts
Application services
- Post data access
src/data-access/posts.ts - User data access
src/data-access/users.ts - Comment data access
src/data-access/comments.ts - Like data access
src/data-access/likes.ts - PostgreSQL
src/lib/prisma.ts
Other components
- Reader
Connections 30
- Reader → Landing experience: opens
- Reader → Article listing: browses
- Reader → Article detail: reads
- Landing experience → Landing sections: renders
src/app/page.tsx - Landing experience → Post data access: loads posts
src/app/page.tsx - Article listing → Post data access: loads page
src/app/blog/page.tsx - Article listing → Post cards: renders
src/app/blog/page.tsx - Article detail → Post data access: loads post
src/app/blog/[slug]/page.tsx - Article detail → Markdown rendering: renders content
src/app/blog/[slug]/page.tsx - Article detail → Cookie sessions: reads session
src/app/blog/[slug]/page.tsx - Article detail → Like data access: checks like
src/app/blog/[slug]/page.tsx - Reader → Login and registration: signs in
- Login and registration → Authentication actions: submits forms
src/app/auth/login/login-form.tsx - Authentication actions → User data access: looks up user
src/actions/auth.ts - Authentication actions → Cookie sessions: creates session
src/actions/auth.ts - Post administration → Post data access: loads posts
src/app/admin/posts/page.tsx - Post administration → Post editor: opens editor
src/app/admin/posts/new/page.tsx - Post editor → PostgreSQL: saves via actions
- Nested comments → Comment interactions: uses interactions
- Comment interactions → Comment actions: submits comments
src/hooks/use-comment-section.ts - Comment actions → Comment data access: persists comments
- Post likes → Like data access: records likes
- Preferences panel → Preference state: reads settings
src/components/preferences/preferences-panel.tsx - Preferences panel → Theme mode: sets theme mode
src/components/preferences/preferences-panel.tsx - Preference state → Local preferences: loads and saves
src/hooks/use-preferences.ts - Theme mode → Local preferences: reads mode
src/hooks/use-theme-mode.ts - Post data access → PostgreSQL: queries
src/data-access/posts.ts - User data access → PostgreSQL: queries
src/data-access/users.ts - Comment data access → PostgreSQL: queries
- Like data access → PostgreSQL: queries
src/data-access/likes.ts