From ed5f3b09000b672483426ed9d9dd83ab5e361554 Mon Sep 17 00:00:00 2001 From: Poyraz Avsever Date: Fri, 3 Apr 2026 11:53:22 +0300 Subject: [PATCH] Refactor sitemap and project components; remove snippets page; update project data structure and command palette links --- app/sitemap.ts | 67 ++++- app/snippets/page.tsx | 9 - apps/data-panel/renderer/configs.js | 369 ++++++++++++++++++++++++---- apps/data-panel/renderer/index.html | 181 +++++++++++--- components/projects-content.tsx | 59 ++++- data/projects.ts | 25 +- lib/command-palette-links.ts | 103 ++++++-- lib/links.ts | 1 - 8 files changed, 684 insertions(+), 130 deletions(-) delete mode 100644 app/snippets/page.tsx diff --git a/app/sitemap.ts b/app/sitemap.ts index 150a874..5ed7db8 100644 --- a/app/sitemap.ts +++ b/app/sitemap.ts @@ -1,22 +1,67 @@ import { listBlogDetails } from "@/data/blog-detail"; import type { MetadataRoute } from "next"; -const SITE_URL = process.env.NEXT_PUBLIC_SITE_URL || "https://poyrazavsever.com"; +const SITE_URL = + process.env.NEXT_PUBLIC_SITE_URL || "https://poyrazavsever.com"; export default async function sitemap(): Promise { const posts = await listBlogDetails(); const staticRoutes: MetadataRoute.Sitemap = [ - { url: SITE_URL, lastModified: new Date(), changeFrequency: "weekly", priority: 1.0 }, - { url: `${SITE_URL}/about`, lastModified: new Date(), changeFrequency: "monthly", priority: 0.8 }, - { url: `${SITE_URL}/about/references`, lastModified: new Date(), changeFrequency: "monthly", priority: 0.5 }, - { url: `${SITE_URL}/about/volunteer-community`, lastModified: new Date(), changeFrequency: "monthly", priority: 0.5 }, - { url: `${SITE_URL}/blog`, lastModified: new Date(), changeFrequency: "weekly", priority: 0.9 }, - { url: `${SITE_URL}/projects`, lastModified: new Date(), changeFrequency: "monthly", priority: 0.8 }, - { url: `${SITE_URL}/content`, lastModified: new Date(), changeFrequency: "weekly", priority: 0.7 }, - { url: `${SITE_URL}/contact`, lastModified: new Date(), changeFrequency: "yearly", priority: 0.5 }, - { url: `${SITE_URL}/links`, lastModified: new Date(), changeFrequency: "monthly", priority: 0.4 }, - { url: `${SITE_URL}/snippets`, lastModified: new Date(), changeFrequency: "weekly", priority: 0.7 }, + { + url: SITE_URL, + lastModified: new Date(), + changeFrequency: "weekly", + priority: 1.0, + }, + { + url: `${SITE_URL}/about`, + lastModified: new Date(), + changeFrequency: "monthly", + priority: 0.8, + }, + { + url: `${SITE_URL}/about/references`, + lastModified: new Date(), + changeFrequency: "monthly", + priority: 0.5, + }, + { + url: `${SITE_URL}/about/volunteer-community`, + lastModified: new Date(), + changeFrequency: "monthly", + priority: 0.5, + }, + { + url: `${SITE_URL}/blog`, + lastModified: new Date(), + changeFrequency: "weekly", + priority: 0.9, + }, + { + url: `${SITE_URL}/projects`, + lastModified: new Date(), + changeFrequency: "monthly", + priority: 0.8, + }, + { + url: `${SITE_URL}/content`, + lastModified: new Date(), + changeFrequency: "weekly", + priority: 0.7, + }, + { + url: `${SITE_URL}/contact`, + lastModified: new Date(), + changeFrequency: "yearly", + priority: 0.5, + }, + { + url: `${SITE_URL}/links`, + lastModified: new Date(), + changeFrequency: "monthly", + priority: 0.4, + }, ]; const blogRoutes: MetadataRoute.Sitemap = posts.map((post) => ({ diff --git a/app/snippets/page.tsx b/app/snippets/page.tsx deleted file mode 100644 index 40b8c3b..0000000 --- a/app/snippets/page.tsx +++ /dev/null @@ -1,9 +0,0 @@ -import { SnippetsContent } from "@/components/snippets-content"; -import { listSnippets } from "@/data/snippets"; - -export default async function SnippetsPage() { - const snippets = await listSnippets(); - const categories = ["All", ...new Set(snippets.map((s) => s.category))]; - - return ; -} diff --git a/apps/data-panel/renderer/configs.js b/apps/data-panel/renderer/configs.js index d6e771e..a08d4ba 100644 --- a/apps/data-panel/renderer/configs.js +++ b/apps/data-panel/renderer/configs.js @@ -1,5 +1,11 @@ - -export const BLOG_CATEGORIES = ["Frontend", "UX", "Yazilim", "TypeScript", "Testing", "General"]; +export const BLOG_CATEGORIES = [ + "Frontend", + "UX", + "Yazilim", + "TypeScript", + "Testing", + "General", +]; export const COLLECTION_CONFIGS = { announcement: { @@ -8,10 +14,33 @@ export const COLLECTION_CONFIGS = { fileName: "site-settings.ts", exportName: "ANNOUNCEMENT_ITEMS", fields: [ - { key: "id", label: "ID", required: true, placeholder: "main-announcement" }, - { key: "text", label: "Text", type: "textarea", full: true, required: true, placeholder: "Bu hafta yeni bilesenler eklendi!" }, - { key: "actionLabel", label: "Action Label", required: true, placeholder: "Incele ->" }, - { key: "actionHref", label: "Action Link", type: "url", required: true, placeholder: "https://..." }, + { + key: "id", + label: "ID", + required: true, + placeholder: "main-announcement", + }, + { + key: "text", + label: "Text", + type: "textarea", + full: true, + required: true, + placeholder: "Bu hafta yeni bilesenler eklendi!", + }, + { + key: "actionLabel", + label: "Action Label", + required: true, + placeholder: "Incele ->", + }, + { + key: "actionHref", + label: "Action Link", + type: "url", + required: true, + placeholder: "https://...", + }, ], card: (item) => ({ title: item.id || "Announcement", @@ -25,11 +54,34 @@ export const COLLECTION_CONFIGS = { fileName: "bookmarks.ts", exportName: "BOOKMARKS", fields: [ - { key: "id", label: "ID", required: true, placeholder: "bookmark-poyraz-ui" }, - { key: "title", label: "Title", required: true, placeholder: "Poyraz UI" }, - { key: "href", label: "Link", type: "url", required: true, placeholder: "https://..." }, + { + key: "id", + label: "ID", + required: true, + placeholder: "bookmark-poyraz-ui", + }, + { + key: "title", + label: "Title", + required: true, + placeholder: "Poyraz UI", + }, + { + key: "href", + label: "Link", + type: "url", + required: true, + placeholder: "https://...", + }, { key: "tag", label: "Tag", required: true, placeholder: "UI Kit" }, - { key: "description", label: "Description", type: "textarea", full: true, required: true, placeholder: "Short description" }, + { + key: "description", + label: "Description", + type: "textarea", + full: true, + required: true, + placeholder: "Short description", + }, ], card: (item) => ({ title: item.title || item.id || "Untitled bookmark", @@ -43,12 +95,39 @@ export const COLLECTION_CONFIGS = { fileName: "certificates.ts", exportName: "certificates", fields: [ - { key: "name", label: "Name", required: true, placeholder: "Certificate name" }, - { key: "organization", label: "Organization", required: true, placeholder: "Udemy" }, + { + key: "name", + label: "Name", + required: true, + placeholder: "Certificate name", + }, + { + key: "organization", + label: "Organization", + required: true, + placeholder: "Udemy", + }, { key: "date", label: "Date", required: true, placeholder: "June 2025" }, - { key: "category", label: "Category", required: true, placeholder: "mobile" }, - { key: "image", label: "Image Path", required: true, placeholder: "/certificates/reactnative.png" }, - { key: "description", label: "Description", type: "textarea", full: true, required: true, placeholder: "What this certificate represents" }, + { + key: "category", + label: "Category", + required: true, + placeholder: "mobile", + }, + { + key: "image", + label: "Image Path", + required: true, + placeholder: "/certificates/reactnative.png", + }, + { + key: "description", + label: "Description", + type: "textarea", + full: true, + required: true, + placeholder: "What this certificate represents", + }, ], card: (item) => ({ title: item.name || "Untitled certificate", @@ -62,11 +141,38 @@ export const COLLECTION_CONFIGS = { fileName: "education.ts", exportName: "EDUCATION", fields: [ - { key: "id", label: "ID", required: true, placeholder: "ostim-university" }, - { key: "title", label: "Title", required: true, placeholder: "Software Engineering - 2nd Year Student" }, - { key: "institution", label: "Institution", required: true, placeholder: "OSTIM Technical University" }, - { key: "period", label: "Period", required: true, placeholder: "2024 - Present" }, - { key: "description", label: "Description", type: "textarea", full: true, required: true, placeholder: "Education summary" }, + { + key: "id", + label: "ID", + required: true, + placeholder: "ostim-university", + }, + { + key: "title", + label: "Title", + required: true, + placeholder: "Software Engineering - 2nd Year Student", + }, + { + key: "institution", + label: "Institution", + required: true, + placeholder: "OSTIM Technical University", + }, + { + key: "period", + label: "Period", + required: true, + placeholder: "2024 - Present", + }, + { + key: "description", + label: "Description", + type: "textarea", + full: true, + required: true, + placeholder: "Education summary", + }, ], card: (item) => ({ title: item.title || item.id || "Education", @@ -80,10 +186,30 @@ export const COLLECTION_CONFIGS = { fileName: "experience.ts", exportName: "EXPERIENCE", fields: [ - { key: "id", label: "ID", required: true, placeholder: "omedya-part-time" }, - { key: "role", label: "Role", required: true, placeholder: "Fullstack Developer" }, - { key: "company", label: "Company", required: true, placeholder: "Omedya Bilisim A.S" }, - { key: "period", label: "Period", required: true, placeholder: "August 2025 - Present" }, + { + key: "id", + label: "ID", + required: true, + placeholder: "omedya-part-time", + }, + { + key: "role", + label: "Role", + required: true, + placeholder: "Fullstack Developer", + }, + { + key: "company", + label: "Company", + required: true, + placeholder: "Omedya Bilisim A.S", + }, + { + key: "period", + label: "Period", + required: true, + placeholder: "August 2025 - Present", + }, ], card: (item) => ({ title: item.role || item.id || "Experience", @@ -97,12 +223,47 @@ export const COLLECTION_CONFIGS = { exportName: "REFERENCES", fields: [ { key: "id", label: "ID", required: true, placeholder: "ali-korkmaz" }, - { key: "author", label: "Author", required: true, placeholder: "Ali Korkmaz" }, - { key: "role", label: "Role", required: true, placeholder: "Musteri - 2025" }, - { key: "avatar", label: "Avatar Path", required: true, placeholder: "/avatars/ali.png" }, - { key: "rating", label: "Rating", type: "number", min: 1, max: 5, step: 1, placeholder: "5" }, - { key: "profileHref", label: "Profile Link", type: "url", placeholder: "https://linkedin.com/in/..." }, - { key: "quote", label: "Quote", type: "textarea", full: true, required: true, placeholder: "Reference quote" }, + { + key: "author", + label: "Author", + required: true, + placeholder: "Ali Korkmaz", + }, + { + key: "role", + label: "Role", + required: true, + placeholder: "Musteri - 2025", + }, + { + key: "avatar", + label: "Avatar Path", + required: true, + placeholder: "/avatars/ali.png", + }, + { + key: "rating", + label: "Rating", + type: "number", + min: 1, + max: 5, + step: 1, + placeholder: "5", + }, + { + key: "profileHref", + label: "Profile Link", + type: "url", + placeholder: "https://linkedin.com/in/...", + }, + { + key: "quote", + label: "Quote", + type: "textarea", + full: true, + required: true, + placeholder: "Reference quote", + }, ], card: (item) => ({ title: item.author || item.id || "Reference", @@ -116,12 +277,34 @@ export const COLLECTION_CONFIGS = { fileName: "projects.ts", exportName: "MOBILE_APPS", fields: [ - { key: "id", label: "ID", required: true, placeholder: "mobile-habit-flow" }, - { key: "title", label: "Title", required: true, placeholder: "Habit Flow" }, + { + key: "id", + label: "ID", + required: true, + placeholder: "mobile-habit-flow", + }, + { + key: "title", + label: "Title", + required: true, + placeholder: "Habit Flow", + }, { key: "badge", label: "Badge", placeholder: "React Native" }, - { key: "image", label: "Image Path", required: true, placeholder: "/images/hero1.png" }, + { + key: "image", + label: "Image Path", + required: true, + placeholder: "/images/hero1.png", + }, { key: "href", label: "Link", type: "url", placeholder: "https://..." }, - { key: "description", label: "Description", type: "textarea", full: true, required: true, placeholder: "Project summary" }, + { + key: "description", + label: "Description", + type: "textarea", + full: true, + required: true, + placeholder: "Project summary", + }, ], card: (item) => ({ title: item.title || item.id || "Project", @@ -136,11 +319,69 @@ export const COLLECTION_CONFIGS = { exportName: "WEB_APPS", fields: [ { key: "id", label: "ID", required: true, placeholder: "web-portfolio" }, - { key: "title", label: "Title", required: true, placeholder: "Personal Portfolio" }, + { + key: "title", + label: "Title", + required: true, + placeholder: "Personal Portfolio", + }, { key: "badge", label: "Badge", placeholder: "Next.js" }, - { key: "image", label: "Image Path", required: true, placeholder: "/news/design.svg" }, + { + key: "image", + label: "Image Path", + required: true, + placeholder: "/news/design.svg", + }, { key: "href", label: "Link", type: "url", placeholder: "https://..." }, - { key: "description", label: "Description", type: "textarea", full: true, required: true, placeholder: "Project summary" }, + { + key: "description", + label: "Description", + type: "textarea", + full: true, + required: true, + placeholder: "Project summary", + }, + ], + card: (item) => ({ + title: item.title || item.id || "Project", + meta: [item.badge, item.href], + footer: item.description, + }), + }, + projectsExtensions: { + label: "Projects Extensions", + itemLabel: "Extension Project", + fileName: "projects.ts", + exportName: "EXTENSIONS", + fields: [ + { + key: "id", + label: "ID", + required: true, + placeholder: "extension-theme-tuner", + }, + { + key: "title", + label: "Title", + required: true, + placeholder: "Theme Tuner", + }, + { key: "badge", label: "Badge", placeholder: "VS Code Extension" }, + { + key: "image", + label: "Image Path", + required: true, + placeholder: "/news/design.svg", + }, + { key: "href", label: "Link", type: "url", placeholder: "https://..." }, + { + key: "description", + label: "Description", + type: "textarea", + full: true, + required: true, + placeholder: "Project summary", + }, ], card: (item) => ({ title: item.title || item.id || "Project", @@ -154,12 +395,34 @@ export const COLLECTION_CONFIGS = { fileName: "projects.ts", exportName: "FIGMA_TEMPLATES", fields: [ - { key: "id", label: "ID", required: true, placeholder: "figma-minimal-saas" }, - { key: "title", label: "Title", required: true, placeholder: "Minimal SaaS Landing Kit" }, + { + key: "id", + label: "ID", + required: true, + placeholder: "figma-minimal-saas", + }, + { + key: "title", + label: "Title", + required: true, + placeholder: "Minimal SaaS Landing Kit", + }, { key: "badge", label: "Badge", placeholder: "Figma" }, - { key: "image", label: "Image Path", required: true, placeholder: "/news/design.svg" }, + { + key: "image", + label: "Image Path", + required: true, + placeholder: "/news/design.svg", + }, { key: "href", label: "Link", type: "url", placeholder: "https://..." }, - { key: "description", label: "Description", type: "textarea", full: true, required: true, placeholder: "Project summary" }, + { + key: "description", + label: "Description", + type: "textarea", + full: true, + required: true, + placeholder: "Project summary", + }, ], card: (item) => ({ title: item.title || item.id || "Project", @@ -175,9 +438,21 @@ export const COLLECTION_CONFIGS = { fields: [ { key: "id", label: "ID", required: true, placeholder: "youtube" }, { key: "title", label: "Title", required: true, placeholder: "YouTube" }, - { key: "timeline", label: "Timeline", required: true, placeholder: "2025 - Present" }, + { + key: "timeline", + label: "Timeline", + required: true, + placeholder: "2025 - Present", + }, { key: "link", label: "Link", type: "url", placeholder: "https://..." }, - { key: "focus", label: "Focus", type: "textarea", full: true, required: true, placeholder: "Community contribution summary" }, + { + key: "focus", + label: "Focus", + type: "textarea", + full: true, + required: true, + placeholder: "Community contribution summary", + }, ], card: (item) => ({ title: item.title || item.id || "Community", @@ -191,7 +466,13 @@ export const COLLECTION_CONFIGS = { fileName: "youtube-videos.ts", exportName: "YOUTUBE_VIDEO_LINKS", fields: [ - { key: "url", label: "Video URL", type: "url", required: true, placeholder: "https://www.youtube.com/watch?v=..." }, + { + key: "url", + label: "Video URL", + type: "url", + required: true, + placeholder: "https://www.youtube.com/watch?v=...", + }, ], deserializeItem: (raw) => ({ url: String(raw || "") }), serializeItem: (item) => String(item.url || "").trim(), diff --git a/apps/data-panel/renderer/index.html b/apps/data-panel/renderer/index.html index 8f248f7..ca7480c 100644 --- a/apps/data-panel/renderer/index.html +++ b/apps/data-panel/renderer/index.html @@ -10,26 +10,106 @@

Portfolio Data Panel

-

Manage blog posts, dashboard collections, media files, and publish updates.

+

+ Manage blog posts, dashboard collections, media files, and publish + updates. +

Electron Monorepo
@@ -40,7 +120,9 @@