From bbc573e290b66f99e29bb793d4b869c60673467c Mon Sep 17 00:00:00 2001 From: Arthur DANJOU Date: Sun, 6 Apr 2025 19:16:28 +0200 Subject: [PATCH] Refactor: Split portfolio to projects and writings sections, and update content structure - Renamed 'portfolio' collection to 'projects' in content configuration. - Introduced a new 'writings' collection with corresponding schema. - Updated README to reflect changes in content structure and navigation. - Removed the old portfolio page and added new pages for projects and writings. - Added multiple new project and writing markdown files with relevant content. - Updated license year to 2025. - Enhanced AppHeader for new navigation links. - Improved ProseImg component styling. --- LICENSE | 2 +- README.md | 145 +++++++---------- app/components/AppHeader.vue | 15 +- app/components/content/ProseImg.vue | 2 +- app/pages/portfolio/index.vue | 148 ------------------ app/pages/projects/[slug].vue | 124 +++++++++++++++ app/pages/projects/index.vue | 92 +++++++++++ app/pages/{portfolio => writings}/[slug].vue | 23 ++- app/pages/writings/index.vue | 118 ++++++++++++++ content.config.ts | 16 +- content/{portfolio => projects}/arthome.md | 5 +- content/{portfolio => projects}/artsite.md | 5 +- content/{portfolio => projects}/bikes-glm.md | 7 +- .../monte-carlo-project.md | 5 +- .../{portfolio => projects}/python-data-ml.md | 5 +- .../schelling-segregation-model.md | 7 +- content/{portfolio => projects}/studies.md | 5 +- .../how-my-website-works.md | 23 ++- .../{portfolio => writings}/neural-network.md | 45 +++--- .../what-is-machine-learning.md | 13 +- .../{portfolio => projects}/arthome/.gitkeep | 0 .../{portfolio => projects}/arthome/cover.png | Bin .../{portfolio => projects}/artsite/cover.png | Bin .../bikes-glm/Report.pdf | Bin .../monte-carlo-project/Report.pdf | Bin .../schelling/Projet.pdf | Bin public/{portfolio => writings}/ML/model.png | Bin public/{portfolio => writings}/ML/r2.png | Bin public/{portfolio => writings}/ML/types.png | Bin .../neural-network/gradient-descent.png | Bin .../neural-network/neural-network-viz.png | Bin .../website-work/nuxt-hub.png | Bin .../website-work/nuxt-studio.png | Bin .../website-work/website.png | Bin types.ts | 12 -- 35 files changed, 481 insertions(+), 336 deletions(-) delete mode 100644 app/pages/portfolio/index.vue create mode 100644 app/pages/projects/[slug].vue create mode 100644 app/pages/projects/index.vue rename app/pages/{portfolio => writings}/[slug].vue (91%) create mode 100644 app/pages/writings/index.vue rename content/{portfolio => projects}/arthome.md (93%) rename content/{portfolio => projects}/artsite.md (90%) rename content/{portfolio => projects}/bikes-glm.md (69%) rename content/{portfolio => projects}/monte-carlo-project.md (87%) rename content/{portfolio => projects}/python-data-ml.md (89%) rename content/{portfolio => projects}/schelling-segregation-model.md (72%) rename content/{portfolio => projects}/studies.md (95%) rename content/{portfolio => writings}/how-my-website-works.md (96%) rename content/{portfolio => writings}/neural-network.md (87%) rename content/{portfolio => writings}/what-is-machine-learning.md (95%) rename public/{portfolio => projects}/arthome/.gitkeep (100%) rename public/{portfolio => projects}/arthome/cover.png (100%) rename public/{portfolio => projects}/artsite/cover.png (100%) rename public/{portfolio => projects}/bikes-glm/Report.pdf (100%) rename public/{portfolio => projects}/monte-carlo-project/Report.pdf (100%) rename public/{portfolio => projects}/schelling/Projet.pdf (100%) rename public/{portfolio => writings}/ML/model.png (100%) rename public/{portfolio => writings}/ML/r2.png (100%) rename public/{portfolio => writings}/ML/types.png (100%) rename public/{portfolio => writings}/neural-network/gradient-descent.png (100%) rename public/{portfolio => writings}/neural-network/neural-network-viz.png (100%) rename public/{portfolio => writings}/website-work/nuxt-hub.png (100%) rename public/{portfolio => writings}/website-work/nuxt-studio.png (100%) rename public/{portfolio => writings}/website-work/website.png (100%) diff --git a/LICENSE b/LICENSE index a869d87..da7b345 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2024 Arthur Danjou +Copyright (c) 2025 Arthur Danjou Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 4566646..9438944 100644 --- a/README.md +++ b/README.md @@ -18,14 +18,9 @@ My professional portfolio built with modern Nuxt.js technologies, showcasing pro - [Features](#-features) - [Tech Stack](#️-tech-stack) - [Project Structure](#-project-structure) -- [Development](#-development) - - [Prerequisites](#prerequisites) - - [Installation](#installation) - - [Configuration](#configuration) - - [Running Locally](#running-locally) - - [Deployment](#deployment) - [Adding Content](#-adding-content) - - [Portfolio Projects](#portfolio-projects) + - [Projects](#projects) + - [Writings](#writings) - [Uses Page](#uses-page) - [Integrations](#-integrations) - [License](#-license) @@ -61,12 +56,14 @@ My professional portfolio built with modern Nuxt.js technologies, showcasing pro ├── assets/ # Static assets like global styles ├── components/ # Vue components ├── content/ # Markdown content for the portfolio -│ ├── portfolio/ # Portfolio projects +│ ├── projects/ # Portfolio projects +│ ├── writings/ # Writings │ └── uses/ # Uses page items ├── layouts/ # Page layouts ├── pages/ # Application pages ├── public/ # Public static files -│ └── portfolio/ # Portfolio images +│ ├── projects/ # Projects images +│ └── writings/ # Writings images ├── server/ # Server API routes ├── utils/ # Utility functions ├── .env.example # Example environment variables @@ -75,88 +72,24 @@ My professional portfolio built with modern Nuxt.js technologies, showcasing pro └── README.md # Project documentation ``` -## 🚀 Development - -### Prerequisites - -- [Node.js](https://nodejs.org/) (v16 or later) -- [pnpm](https://pnpm.io/) (v7 or later) - -### Installation - -```bash -# Clone the repository -git clone https://github.com/yourusername/portfolio-2024.git -cd portfolio-2024 - -# Install dependencies (with hoisting for Nuxt 3 compatibility) -pnpm i --shamefully-hoist -``` - -### Configuration - -Create a `.env` file in the root directory with the following variables: - -```env -# WakaTime Integration -NUXT_WAKATIME_USER_ID=your_wakatime_user_id -NUXT_WAKATIME_CODING=your_wakatime_coding_endpoint -NUXT_WAKATIME_LANGUAGES=your_wakatime_languages_endpoint -NUXT_WAKATIME_OS=your_wakatime_os_endpoint -NUXT_WAKATIME_EDITORS=your_wakatime_editors_endpoint - -# SEO -NUXT_PUBLIC_SITE_URL=https://your-domain.com - -# Nuxt Hub Deployment -NUXT_HUB_PROJECT_KEY=your_nuxt_hub_project_key - -# Discord Integration -NUXT_DISCORD_ID=your_discord_app_id -NUXT_DISCORD_TOKEN=your_discord_token -NUXT_DISCORD_USER_ID=your_discord_user_id - -# Cloud Files -NUXT_PUBLIC_CLOUD_RESUME=https://link-to-your-resume.pdf - -# Internationalization -NUXT_PUBLIC_I18N_BASE_URL=https://your-domain.com -``` - -### Running Locally - -```bash -# Start development server -pnpm dev - -# Build for production -pnpm build - -# Preview production build -pnpm preview -``` - -### Deployment - -The portfolio is configured to deploy automatically using NuxtHub. Push changes to your main branch to trigger a deployment. - ## 🍱 Adding Content -### Portfolio Projects +### Projects -1. Create a new `.md` file in the `/content/portfolio/` directory +1. Create a new `.md` file in the `/content/projects/` directory 2. Follow the structure of existing projects: ```md --- +--- +slug: project-slug title: Project Title -description: Brief description of the project -date: 2023-01-01 -img: /portfolio/project-image.png -tags: [tag1, tag2, tag3] -links: - website: https://project-url.com - github: https://github.com/user/repo +description: A brief description of the project +publishedAt: YYYY/MM/DD +readingTime: 1 +cover: project-slug/cover.png +tags: + - web --- ## Project content goes here @@ -164,20 +97,48 @@ links: Detailed description and information about the project. ``` -3. Add related project images to `/public/portfolio/` +3. Add related project images to `/public/projects/project-slug/` + +### Writings + +1. Create a new `.md` file in the `/content/writings/` directory +2. Follow the structure of existing projects: + +```md +--- +slug: article-slug +title: The title of the article +description: A brief description of the article +readingTime: 1 +publishedAt: YYYY/MM/DD +cover: article-slug/cover.png +tags: + - tag1 + - tag2 + - tag3 +--- + +## Writing content goes here + +Detailed description and information about the article. +``` + +3. Add related writing images to `/public/writings/article-slug/` ### Uses Page Add new items to the `/content/uses/` directory following the existing pattern: -```md ---- -category: Category Name -items: - - name: Item Name - description: Item description - link: https://item-url.com ---- +```json +{ + "name": "Name of the item", + "description": { + "en": "Item description in English", + "fr": "Item description in French", + "es": "Item description in Spanish" + }, + "category": "Item category name" +} ``` ## 🔌 Integrations diff --git a/app/components/AppHeader.vue b/app/components/AppHeader.vue index f11db45..e8014c4 100644 --- a/app/components/AppHeader.vue +++ b/app/components/AppHeader.vue @@ -28,13 +28,22 @@ const navs = [ }, { label: { - en: 'portfolio', - fr: 'portfolio', + en: 'writings', + fr: 'écrits', es: 'escritos', }, - to: '/portfolio', + to: '/writings', icon: 'books-duotone', }, + { + label: { + en: 'projects', + fr: 'projets', + es: 'proyectos', + }, + to: '/projects', + icon: 'code-duotone', + }, { label: { en: 'resume', diff --git a/app/components/content/ProseImg.vue b/app/components/content/ProseImg.vue index a58215e..a83e4aa 100644 --- a/app/components/content/ProseImg.vue +++ b/app/components/content/ProseImg.vue @@ -5,7 +5,7 @@ defineProps<{ src: string, label: string, caption?: string }>()