How ramxcodes/sleek-portfolio works
1. This is a Next.js 15 App Router portfolio site, so the main architectural boundary is route-based rendering under src/app. Each major page is a separate route: home, blog, projects, journey, work experience, resume, setup, gears, and contact.
2. The site is content-driven rather than CMS-driven. Blog posts, project writeups, and journey content live as MDX files in src/data/*, and route pages under src/app/blog/[slug] and src/app/projects/[slug] read that content through helpers in src/lib/blog.ts and src/lib/project.ts.
3. The UI is organized by feature area in src/components/*. There are reusable “common” primitives for layout and navigation, domain-specific components for blog/projects/experience/contact, and landing-page sections that compose the home page from smaller blocks like Hero, About, Projects, Journey, Blog, Experience, Setup, and CTA.
4. A large portion of the repo is a design-system layer built on shadcn/ui primitives in src/components/ui. These components provide the interactive building blocks used throughout the app: dialogs, forms, tabs, sheets, menus, tooltips, sliders, and similar controls.
5. Styling and shell behavior are global and centralized. src/app/layout.tsx and src/app/globals.css define the application frame, while theme-related providers and switches live in src/components/common/ThemeProviders.tsx and ThemeSwitch.tsx. Tailwind CSS is the styling system, with shadcn patterns layered on top.
6. Content and presentation are separated by a config layer in src/config. These files hold the editable text, links, metadata, and section settings for areas like Hero, Navbar, Projects, Experience, Resume, Footer, Contact, Gears, and SEO metadata, so most site customization happens without touching route code.
7. The contact and chat features are the main server-side/API boundary. src/app/api/contact/route.ts handles the contact form submission flow and is tied to Telegram integration, while src/app/api/chat/route.ts provides a chat endpoint, likely backed by the configured Gemini API key. The repo also includes src/validate/testTelegram.ts to verify Telegram wiring.
8. External integrations are intentionally lightweight and user-facing. Telegram is used as the message delivery backend for the contact form, Gemini is used for chat, and Umami is used for privacy-focused analytics through src/components/analytics/UmamiAnalytics.tsx and src/hooks/use-umami.ts.
9. Static assets are fully local and served from public. That includes blog/project images, fonts, setup files, the animated cat script, and other media referenced by the pages and content components. This makes the portfolio self-contained aside from the external APIs and analytics script.
10. There is a clear split between server-rendered content pages and small client-side enhancements. Hooks like use-mobile, use-haptic-feedback, use-umami, and the Lenis integration add interactivity, while components such as BackToTop, FontSizeControls, ChatBubble, and OnekoCat enhance the UX without changing the content model.
11. The repo is optimized for static content workflows and easy expansion. New blog posts and projects are added by creating MDX files plus matching assets, while new visual technologies/icons are added as isolated SVG/icon components under src/components/technologies or src/components/svgs.
12. Operationally, the project is designed for Bun/Node development and Vercel deployment. Environment variables wire in Telegram, Gemini, the site URL, and Umami, and the presence of next.config.ts, GitHub workflow linting, and Husky pre-commit hooks shows a strong focus on build-time correctness rather than runtime infrastructure.
Main entry points: public Public assets · common Common UI · components Domain UI · analytics Integrations
Components 21
App routes
Next.js App Router pages and API endpoints.
- Root layout · Global shell, providers, and shared frame.
src/app/layout.tsx - Home · Landing page assembled from section components.
src/app/page.tsx - Blog routes · Blog listing and slug pages.
src/app/blog/page.tsx - Blog post · Individual blog post rendering from MDX.
src/app/blog/[slug]/page.tsx - Projects routes · Project listing and slug pages.
src/app/projects/page.tsx - Project page · Individual project rendering from MDX.
src/app/projects/[slug]/page.tsx - Contact API · Server-side contact submission endpoint.
src/app/api/contact/route.ts - Chat API · Server-side chat endpoint.
src/app/api/chat/route.ts
Content layer
MDX content, typed models, and loaders.
- Blog MDX · Blog post content files.
src/data/blog - Project MDX · Project writeups and case studies.
src/data/projects - Journey MDX · Journey content source.
src/data/journey/journey.mdx - Blog loader · Loads and shapes blog content.
src/lib/blog.ts - Project loader · Loads and shapes project content.
src/lib/project.ts - Site config · Editable text, metadata, and section settings.
src/config
UI system
Reusable components, design-system primitives, and page sections.
- Landing sections · Hero, About, Projects, Journey, Blog, Experience, Setup, CTA.
src/components/landing - Common UI · Layout, navigation, theme, and utility components.
src/components/common - Domain UI · Blog, project, experience, contact, gears, and certificates UI.
src/components - UI primitives · Reusable shadcn/ui interaction primitives.
src/components/ui
Infrastructure
Styling, assets, hooks, and external integrations.
- Client hooks · Responsive, haptic, analytics, and scrolling helpers.
src/hooks - Integrations · Telegram, Gemini, and Umami integration surfaces.
src/components/analytics - Public assets · Local images, fonts, setup files, and oneko script.
public
Connections 25
- Root layout → Common UI: wraps · Provides shared providers, navigation, footer, and theme shell.
- Root layout → UI primitives: uses · Imports design-system primitives for app shell interactions.
- Home → Landing sections: composes · Builds the landing page from feature sections.
- Home → Site config: reads · Pulls copy, links, and section settings from config.
- Blog routes → Blog loader: loads · Fetches blog index and metadata.
- Blog post → Blog loader: loads · Resolves slugged blog content and rendering data.
- Blog post → Blog MDX: reads · Consumes MDX posts from the content directory.
- Projects routes → Project loader: loads · Fetches project index and metadata.
- Project page → Project loader: loads · Resolves slugged project content and rendering data.
- Project page → Project MDX: reads · Consumes MDX project writeups.
- Contact API → Integrations: sends · Delivers contact messages through Telegram.
- Chat API → Integrations: calls · Uses the configured Gemini-backed chat flow.
- Blog routes → Domain UI: renders · Uses blog list and post presentation components.
- Project page → Domain UI: renders · Uses project detail and navigation components.
- Landing sections → Domain UI: uses · Composes reusable feature-specific UI blocks.
- Domain UI → UI primitives: built on · Leverages dialogs, forms, tabs, menus, and other primitives.
- Common UI → Client hooks: enhanced by · Client-side utilities power mobile, haptic, and scroll behavior.
- Common UI → Integrations: tracks · Analytics and chat affordances connect to external services.
- Site config → Public assets: references · Site settings point to local media and downloadable files.
- Blog MDX → Public assets: references · Blog MDX can embed local images and media.
- Project MDX → Public assets: references · Project MDX can embed local images, screenshots, and media.
- Public assets → Home: served by · Static files support the rendered pages and sections.
- Public assets → Landing sections: illustrates · Provides imagery, fonts, and setup artifacts used in the UI.
- Client hooks → Common UI: supports · Hooks power responsive and interactive common components.
- Integrations → Root layout: mounted in · Analytics and chat integrations are wired through the app shell.