10 Commits
Author SHA1 Message Date
Spaghet b03ef1ee43 Remove migration documentation and update dependencies for Astro upgrade 2025-08-24 12:17:08 -04:00
Spaghet c9948befaf Refactor content handling to use Appwrite service instead of Astro collections, remove ViewTransitions import, update test files accordingly 2025-08-23 20:10:43 -04:00
Spaghet 9cc9768121 Update color scheme to spaghetti palette across article layout and work page components 2025-08-22 22:11:29 -04:00
Spaghet 73db6d2cd3 Migrate Astro to latest version and update dependencies
- Updated Astro core package and related integrations to latest versions
- Added environment variable configuration in astro.config.mjs
- Removed deprecated migration plan and favicon.svg files
- Updated Search component to use onCleanup for proper effect cleanup
- Updated Appwrite service integration and configuration
- Removed old migration documentation and scripts
2025-08-22 21:54:30 -04:00
spaghet e5ce8e4783 Improve search functionality with better error handling and form submission 2025-08-22 12:50:17 -04:00
Spaghet 6ab3254384 refactor: Reorganize project structure and update dependencies
- Removed blog, project, and work content files
- Updated package dependencies including npm and removed license metadata
- Refactored component layouts and page routes
- Modified appwrite service for data operations
2025-08-22 00:08:32 -04:00
spaghet 7997eccb12 Refactor layouts to use Appwrite data types and implement search/pagination features 2025-08-21 13:50:56 -04:00
spaghet 03a79e2f79 Migrate content from markdown to Appwrite database
Remove static markdown file dependencies and update all pages/components to fetch data directly from Appwrite collections, while maintaining existing service functions for data retrieval and adding new CRUD operations for projects.
2025-08-19 10:59:50 -04:00
Spaghet 7e3b5b7a55 Appwrite migration WIP 2025-08-16 19:52:14 -04:00
SpaghetGaming 89c5e065de Starting infrastructure for server side image loading 2025-08-14 16:06:25 -04:00
65 changed files with 4767 additions and 12697 deletions

No files matched your search

-63
View File
@@ -1,63 +0,0 @@
# Astro Migration Plan
## Overview
This document outlines the steps to upgrade Astro in this project while maintaining all existing functionality, including the Appwrite integration and security practices.
## Current State
- Astro version: 4.5.18
- Project structure is working with secure environment variable handling
- Appwrite integration properly configured with credentials in .env file
- All configuration fixes have been committed to the dev branch
## Migration Steps
### 1. Preparation
- Ensure all local changes are committed to the dev branch
- Create a backup of current working state (already done)
- Verify all tests pass before starting migration
### 2. Update Dependencies
```bash
# Update Astro core package
npm install astro@latest
# Update related packages
npm install @astrojs/mdx@latest
npm install @astrojs/tailwind@latest
npm install @astrojs/solid-js@latest
npm install @astrojs/sitemap@latest
```
### 3. Configuration Updates
- Review `astro.config.mjs` for any deprecated configurations
- Update integrations syntax if needed
- Ensure Tailwind CSS configuration remains compatible
### 4. Environment Variable Handling
- Verify `import.meta.env` usage is still valid
- Confirm Appwrite integration in `src/lib/appwrite.ts` works with new version
- Test that `.env` variables are properly loaded
### 5. Component Testing
- Test Header component with Appwrite images
- Test Footer component with Appwrite images
- Verify all other components still function correctly
### 6. Build and Deployment Verification
- Run `npm run build` to ensure successful compilation
- Test locally with `npm run preview`
- Verify all images load properly from Appwrite storage
## Security Considerations
- All environment variables remain in `.env` file
- No changes to how sensitive credentials are handled
- Migration maintains the same security practices
## Rollback Plan
If issues arise during migration:
1. Revert to previous commit: `git reset --hard HEAD~1`
2. Check that all functionality works as before
3. Investigate specific breaking changes in Astro release notes
## Timeline
Estimated time: 2-4 hours for full migration and testing
+24 -2
View File
@@ -1,12 +1,34 @@
import { defineConfig } from "astro/config" import { defineConfig, envField } from "astro/config"
import mdx from "@astrojs/mdx" import mdx from "@astrojs/mdx"
import sitemap from "@astrojs/sitemap" import sitemap from "@astrojs/sitemap"
import tailwind from "@astrojs/tailwind" import tailwind from "@astrojs/tailwind"
import solidJs from "@astrojs/solid-js" import solidJs from "@astrojs/solid-js"
import node from "@astrojs/node"
// https://astro.build/config // https://astro.build/config
export default defineConfig({ export default defineConfig({
site: "https://spaghet.io", site: "https://spaghet.io",
integrations: [mdx(), sitemap(), solidJs(), tailwind({ applyBaseStyles: false })], integrations: [mdx(), sitemap(), solidJs(), tailwind({ applyBaseStyles: false })],
output: "static" output: "server",
adapter: node({ mode: "ssr" }),
env: {
schema: {
VITE_APPWRITE_ENDPOINT: envField.string({ context: "server", access: "public" }),
VITE_APPWRITE_PROJECT_ID: envField.string({ context: "server", access: "public" }),
VITE_APPWRITE_BUCKET_ID: envField.string({ context: "server", access: "public" }),
VITE_APPWRITE_DATABASE_ID: envField.string({ context: "server", access: "public" }),
VITE_APPWRITE_BLOG_COLLECTION_ID: envField.string({ context: "server", access: "public" }),
VITE_APPWRITE_PROJECTS_COLLECTION_ID: envField.string({ context: "server", access: "public" }),
VITE_APPWRITE_WORK_COLLECTION_ID: envField.string({ context: "server", access: "public" }),
VITE_APPWRITE_LEGAL_COLLECTION_ID: envField.string({ context: "server", access: "public" }),
PUBLIC_APPWRITE_ENDPOINT: envField.string({ context: "client", access: "public" }),
PUBLIC_APPWRITE_PROJECT_ID: envField.string({ context: "client", access: "public" }),
PUBLIC_APPWRITE_BUCKET_ID: envField.string({ context: "client", access: "public" }),
PUBLIC_APPWRITE_DATABASE_ID: envField.string({ context: "client", access: "public" }),
PUBLIC_APPWRITE_BLOG_COLLECTION_ID: envField.string({ context: "client", access: "public" }),
PUBLIC_APPWRITE_PROJECTS_COLLECTION_ID: envField.string({ context: "client", access: "public" }),
PUBLIC_APPWRITE_WORK_COLLECTION_ID: envField.string({ context: "client", access: "public" }),
PUBLIC_APPWRITE_LEGAL_COLLECTION_ID: envField.string({ context: "client", access: "public" }),
}
}
}) })
-21
View File
@@ -1,21 +0,0 @@
#!/bin/bash
echo "Starting Astro migration process..."
# Step 1: Update dependencies
echo "Updating Astro and related packages..."
npm install astro@latest
npm install @astrojs/mdx@latest
npm install @astrojs/tailwind@latest
npm install @astrojs/solid-js@latest
npm install @astrojs/sitemap@latest
# Step 2: Check for any build issues
echo "Checking if project builds correctly..."
npm run build
# Step 3: Run tests to ensure everything works
echo "Running tests..."
npm test
echo "Migration process completed. Please review any warnings or errors above."
+3631 -5757
View File
File diff suppressed because it is too large. Load diff
+19 -7
View File
@@ -3,12 +3,12 @@
"type": "module", "type": "module",
"version": "1.0.0", "version": "1.0.0",
"scripts": { "scripts": {
"dev": "astro dev", "dev": "dotenv -e .env -- astro dev",
"dev:network": "astro dev --host", "dev:network": "dotenv -e .env -- astro dev --host",
"start": "astro dev", "start": "dotenv -e .env -- astro dev",
"build": "astro check && astro build", "build": "astro check && astro build",
"preview": "astro preview", "preview": "dotenv -e .env -- astro preview",
"preview:network": "astro dev --host", "preview:network": "dotenv -e .env -- astro dev --host",
"astro": "astro", "astro": "astro",
"lint": "eslint .", "lint": "eslint .",
"lint:fix": "eslint . --fix" "lint:fix": "eslint . --fix"
@@ -16,19 +16,31 @@
"dependencies": { "dependencies": {
"@astrojs/check": "^0.5.6", "@astrojs/check": "^0.5.6",
"@astrojs/mdx": "^4.3.3", "@astrojs/mdx": "^4.3.3",
"@astrojs/node": "^9.4.1",
"@astrojs/rss": "^4.0.5", "@astrojs/rss": "^4.0.5",
"@astrojs/sitemap": "^3.5.0", "@astrojs/sitemap": "^3.5.0",
"@astrojs/solid-js": "^5.1.0", "@astrojs/solid-js": "^5.1.0",
"@astrojs/tailwind": "^6.0.2", "@astrojs/tailwind": "^6.0.2",
"@solidjs/testing-library": "^0.8.10",
"@tailwindcss/typography": "^0.5.10", "@tailwindcss/typography": "^0.5.10",
"appwrite": "^18.2.0",
"astro": "^5.13.0", "astro": "^5.13.0",
"clsx": "^2.1.0", "clsx": "^2.1.0",
"fuse.js": "^7.0.0", "fuse.js": "^7.0.0",
"notenv": "^2.0.3",
"npm": "^11.5.2",
"rehype-stringify": "^10.0.1",
"remark": "^15.0.1",
"remark-rehype": "^11.1.2",
"sharp": "^0.33.2", "sharp": "^0.33.2",
"solid-js": "^1.8.15", "solid-js": "^1.8.15",
"tailwind-merge": "^2.2.1", "tailwind-merge": "^2.2.1",
"tailwindcss": "^3.4.1", "tailwindcss": "^3.4.1",
"typescript": "^5.3.3" "ts-node": "^10.9.2",
"typescript": "^5.3.3",
"vitest": "^3.2.4",
"appwrite": "^18.2.0"
},
"devDependencies": {
"dotenv-cli": "^10.0.0"
} }
} }
-5031
View File
File diff suppressed because it is too large. Load diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

+5 -9
View File
@@ -1,9 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 128 128"> <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<path d="M50.4 78.5a75.1 75.1 0 0 0-28.5 6.9l24.2-65.7c.7-2 1.9-3.2 3.4-3.2h29c1.5 0 2.7 1.2 3.4 3.2l24.2 65.7s-11.6-7-28.5-7L67 45.5c-.4-1.7-1.6-2.8-2.9-2.8-1.3 0-2.5 1.1-2.9 2.7L50.4 78.5Zm-1.1 28.2Zm-4.2-20.2c-2 6.6-.6 15.8 4.2 20.2a17.5 17.5 0 0 1 .2-.7 5.5 5.5 0 0 1 5.7-4.5c2.8.1 4.3 1.5 4.7 4.7.2 1.1.2 2.3.2 3.5v.4c0 2.7.7 5.2 2.2 7.4a13 13 0 0 0 5.7 4.9v-.3l-.2-.3c-1.8-5.6-.5-9.5 4.4-12.8l1.5-1a73 73 0 0 0 3.2-2.2 16 16 0 0 0 6.8-11.4c.3-2 .1-4-.6-6l-.8.6-1.6 1a37 37 0 0 1-22.4 2.7c-5-.7-9.7-2-13.2-6.2Z" />
<style> <image width="36" height="36" xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAaYAAAGmCAYAAAA3cSADAAAgAElEQVR4nOydB7wkZZX2n6rqnG4Oc++dyOREGMIMSbKICIooiHENKPqt6xo/XcO6frprDgsqiq7ZdRV1QQQRyVEGGJicw507N9/u27G60vv9zlvV3dV974yDgjMD5++vvR2qq9+qHurpc97nPQdgGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZhGIZh/laUIz2AFzqJ9u5Y71UfeFekb353UFNDxf7tu0vbn3xy5M9/fKQwMWod6fExDMMcbbAwPY/Eu/pSs/7P176YXnD2tZFwEIlYDOFgEIqiiKhV3FF85Jb/GvvDD2/e+9Ad2470WBmGYY4WWJieB9oXn9jVdum1b3VOvey9GVvrLpR0WLYFIYCgpiGViCMZiyEVj0FT4BiP/ParO274wL/lB3Znj/TYGYZhjjQsTM8hnStOm9n95k99Qix9yesMgUTZMJAtFFEqG7BsW94EqZNHNBxGSzKJ1qYkEqoYzdz6zY/v+M7Hv2/pRU7xMQzzooWF6Tkg1toRPu7dX/yIeuZVH7GgxEiAinoZpXIZhmnBtKxphamKoiAVi2FWdydimYEHtnzwoldl+3eMH4ljYRiGOdJoR3oAxzKhaFyZf/U/XdD74R/ebC9cfZUlECQhMgwTluPAdhz3r23Ddmw4zjSiVMoBWgBl08LYZBZWJDV7ztXve1NTAHvH1j2w6UgcF8MwzJGEhemvJNk7t+mEr//pJnHm1V+wQrEuKUimKaMiRwgpRoZtw6w8Z08jShUGtgH9WyAUFXkliOFMLhE76YIrWqGvy2x8jI0RDMO8qGBhepYoioLZF7/+7Hn/ftsd5eaes8uGqVDazhYCDkVIJEiWBd0woJcNGJYNWzhe0nSazKkWAJo6AVV1BerAdgijjMmyqerzT3tFqv/pP5VG+geOwKEyDMMcEXiO6VnQvXB5R9ebP/0ZnHLp2yxbBPK6LuePVMuEk0/DzIzAyE7AKBVhBCKwSXBS7YBa0X/hnnJRuT8No/uAvRuAchFQVHRZ6R8P//cX3/R3PEyGYZgjSuBID+BYYdFr33N2y9u/8POSEupJ53KY2LsD2q4noA7ugDPWD2ukH8ZoP+x8Bk65BDgOEAgALT3AktOBVZcAx50EaEFXlBQSqGnEqWMW0DIDGNoFDO8GRjauOxLHyzAMc6TgiOkvoAVD6sr3fflaXPD2rxRMO3pg4xMo3PxlKBvvg+JFQsIowTH06YWmAglR3xLgZe8GTjhfRkO1oGn69ymOg+4d931z8kef/EBxYlR/Hg6PYRjmqIOF6RD0nXh618z3Xn9jsXfF5aPjYxj55Vdg3XaDm2b7ayGBWn4u8LpPAS3dvrSeMr1AKQq67OyWpqdu+crIrTf9PDMymP9bjolhGOZoh4VpGsjgcOp1/3pp8IoP3Zi21J7+3TuR/dY/As/c/Wx3dPAoqrkbuPY/gTkrfZokfF/J1PfNDhqbxR03fiZ//69unhgdNp79kTEMwxz9sDA1oKgqTn7fF9+Ol//Tt8ZyhcDA3l0wvvF2YOcTh7+PcAzNl/0j9EACJs05DWyG2PIQRHGyfsNYE3DdN4HjTq659sjBdwhxotcWRYx9XQ//6MP33/TFX/xNB8swDHMUwnZxH5FESj3549//mHHOW748lMkG9g8Owb7pn4EtDz2r/SROuxTOwtNhqhEoyTaoPYugLlgN5MYgMkO1Dc0ysOE+4IQLgHiz96QnSoo46O+GcUtr6u9ZdcWK08/tDY7sWJcdGeQaewzDvGBgYfJItHUGT/r8b27MLr/og6OTWXU0k4G483vAfT+p31ALQm3vgygXvOimHiUUQfsV70e2aNRSc6QvwTDUOcdDDO8Ecr5qQ0YJ2LseOO1yQNFqWqR4qUAAqm1BsU0IrWaiFFCU4WjHqsBZV729b/GKjtbi8KaJoQEWKIZhjnlYmACEEyltyb/+/Ju5BWe8PV/SMZHNwRnth/ODDwNGzQwXXXgy2l/3MQROfBmsjnkQI7sBvd6LED/pIuhdiyGqouVLyykalGQrnG2P1g+AoqhkGzD3eJ+V3BW0VqeEppEdwNA+2NkMRDQBBILVt5YsJzzRPHuNs/pV7zr15FWdwZFdT02MjhSev7PFMAzz/PKiF6ZYa0dw2b/f8p3S/DVvK5Io5fIQ9L/f3QBn+1rAseV24eNORPJV70emYMI0TCDRCnXhasAqQ4z1uyaHQAjJS9+NkqX4oqV6t51iFOBMlxrcvxU48zVAIFx9a8CxkBrZibHhEViWBUUvQJ0chdM6Qy7apT0HxocgDB16MBrcG5+5OnXOVW9as2xBeWzDY+t0Xbf/nueSYRjmuUA90gM4kiS6+mKLPvvbn5XmnvIPumkiUyjIskJicgxi/d0Qttt9QglGkLrkWmQm81IzhPd/SiAC7fTXQnvpu2WKTwlFoSVafKIkvI1dgRK5UVj3/2R6p97kMPDEHbXHAui2skiPjlUf0z4UsywFiuhMJaEYOpTxQah7NkPJZbCnIDpv7734Gy3/cfej3edccVYlHcgwDHOs8KIVplhLe3DJF37/M3PeyVdajg29XJbVv2UB1g33w04PV+eQ4ktOQ1F4kQyJiuegE54AqT0LobT1StedNbizGiW5kiDfBFEuwn78Fje6Ohhrb6uKVlKUYQzug+2JYyUj6MCBSDTLRoMin4HlCIhQVI5VG9gBrX8LoBew246eOHTVv9+Dd97webR0x57n08kwDPOc8aIUpmhrZ3jxv9/6Y7178eXUH4naVFB1cJoXoqrg1lN/hKPXpmkCXbPd9J3irnGS0ZK/KKuiQbT1ybvZp+91BU1u4L1um7C3Pgix68lDD2z3024bDABtpTGkxyfcuSYPUcjA7pkPVVXRHgtjbGC/Z5JQIQIhiFAE0EsI7FoPdWAnuf40rDzvw/iXWzcqL7vuDVo4wiWoGIY56nnRzTHFWjtCiz9/+8+N2ce/hqIjwzJlLyRqfW5aNgy9BOfXnwdKNVOD1rsITsdcn8lOcWeNqpZuBcIoAnvWQeTTUKj0UDAMJz8Be2Az7K0PuZZzsocfCtsETrgQanMXQmP90AtFL/gSgGPBDoWABaswo70Nk/17UC6V6tfk0saaJoVKLUxCHXeLkotUWzMWr7mi99K3XtETVfZag7t266XSVEshwzDMUcCLSpjCyabAss//7nvFmSuupiZ+bndZt6usSe0q6PHkKHD7t6umB8IqZKF0zIZSXWuEajpPapOw4RTT7iJcU5eWcGfXExAb7gbIgTeyB7AOs1DD4jUQPQthU1pxcrwigbAL4xAnXIhgOIpmTWC0f5+bJiTRkilHURsWtdDQAlBsG2pmFEpmRAplNpjsHJ+35vVdF1x9uVqc3K7v2bTnoFXOGYZhjhAvGmEKxRKB47921/ezvSveaNmO2+7csuScEhkeSKDoOYcu4nf/qL7qQikLZ+vDEIPbqG0tlFS7rBBBa5ns9ACcXWshNj8I5NPe9jmgkJZRjto+G9qSs6CsvNCNtLKjdaI3hcWnA3OWwwon4DR3SLu6MPJw5p8EpFoxq6MNB7ZuglPZh+vEkAVfpYhVhk3Rk1dkVjVKUNMjUPIZiHAMmWCiW1927hswZ0Uvdj/9IIqTXCCWYZijhheFZSsQCmPZZ3755eLS897vRkqmbHsuEZCN/EplA2WjDHNoD8SnLnLbVhwEpWUGlDknyHVMYmzftEVdU2tegeTqy1EORJHL5iHIpKAIiNw4nPV/grPj8SlroCTX/Btw5lXeB6Hm6iNDRCyKWLmAkf693tyTI0VOETbgiJqYVlx/woFimVBMXbr5Knk/p6UT9ox5QDgKWOYoHvj5Z/Hbr3wLRonr7zEMc8R5UURMC6/9zFvsM6/5D8u2Feosa8hICTKFRzfbsWXEJNNnpuFGTIeKavQ8xNAOWcFLine truncated
path { fill: #000; }
@media (prefers-color-scheme: dark) { </svg>
path { fill: #FFF; }
}
</style>
</svg>

Before

Width:  |  Height:  |  Size: 749 B

After

Width:  |  Height:  |  Size: 65 KiB

+3
View File
@@ -23,5 +23,8 @@
<symbol id="tailwind" viewBox="0 0 47 40" fill="none"> <symbol id="tailwind" viewBox="0 0 47 40" fill="none">
<path fill="#6366f1" d="M23.5 6.5C17.5 6.5 13.75 9.5 12.25 15.5C14.5 12.5 17.125 11.375 20.125 12.125C21.8367 12.5529 23.0601 13.7947 24.4142 15.1692C26.6202 17.4084 29.1734 20 34.75 20C40.75 20 44.5 17 46 11C43.75 14 41.125 15.125 38.125 14.375C36.4133 13.9471 35.1899 12.7053 33.8357 11.3308C31.6297 9.09158 29.0766 6.5 23.5 6.5ZM12.25 20C6.25 20 2.5 23 1 29C3.25 26 5.875 24.875 8.875 25.625C10.5867 26.0529 11.8101 27.2947 13.1642 28.6693C15.3702 30.9084 17.9234 33.5 23.5 33.5C29.5 33.5 33.25 30.5 34.75 24.5C32.5 27.5 29.875 28.625 26.875 27.875C25.1633 27.4471 23.9399 26.2053 22.5858 24.8307C20.3798 22.5916 17.8266 20 12.25 20Z"/> <path fill="#6366f1" d="M23.5 6.5C17.5 6.5 13.75 9.5 12.25 15.5C14.5 12.5 17.125 11.375 20.125 12.125C21.8367 12.5529 23.0601 13.7947 24.4142 15.1692C26.6202 17.4084 29.1734 20 34.75 20C40.75 20 44.5 17 46 11C43.75 14 41.125 15.125 38.125 14.375C36.4133 13.9471 35.1899 12.7053 33.8357 11.3308C31.6297 9.09158 29.0766 6.5 23.5 6.5ZM12.25 20C6.25 20 2.5 23 1 29C3.25 26 5.875 24.875 8.875 25.625C10.5867 26.0529 11.8101 27.2947 13.1642 28.6693C15.3702 30.9084 17.9234 33.5 23.5 33.5C29.5 33.5 33.25 30.5 34.75 24.5C32.5 27.5 29.875 28.625 26.875 27.875C25.1633 27.4471 23.9399 26.2053 22.5858 24.8307C20.3798 22.5916 17.8266 20 12.25 20Z"/>
</symbol> </symbol>
<!-- appwrite icon-->
<symbol id="simple-icons--appwrite" viewBox="0 0 24 24"><path fill="currentColor" d="M24 17.291v5.29H10.557A10.58 10.58 0 0 1 0 12.715v-1.43c.048-.735.174-1.463.374-2.171C1.63 4.673 5.713 1.419 10.557 1.419s8.927 3.254 10.183 7.695h-5.749a5.28 5.28 0 0 0-4.434-2.404a5.28 5.28 0 0 0-4.434 2.404A5.23 5.23 0 0 0 5.267 12a5.27 5.27 0 0 0 1.66 3.848a5.27 5.27 0 0 0 3.63 1.443zm0-6.734v5.291h-9.813A5.28 5.28 0 0 0 15.848 12c0-.5-.07-.984-.199-1.443z"/></symbol>
</defs> </defs>
</svg> </svg>

Before

Width:  |  Height:  |  Size: 4.5 KiB

After

Width:  |  Height:  |  Size: 5.0 KiB

+17 -16
View File
@@ -1,41 +1,42 @@
import { formatDate } from "@lib/utils" import { formatDate } from "@lib/utils"
import type { CollectionEntry } from "astro:content" import type { BlogPost, Project } from "@lib/appwrite-service"
type Props = { type Props = {
entry: CollectionEntry<"blog"> | CollectionEntry<"projects"> entry: BlogPost | Project | any
collection?: string
pill?: boolean pill?: boolean
} }
export default function ArrowCard({entry, pill}: Props) { export default function ArrowCard({entry, pill, collection}: Props) {
return ( return (
<a href={`/${entry.collection}/${entry.slug}`} class="group p-4 gap-3 flex items-center border rounded-lg hover:bg-black/5 hover:dark:bg-white/10 border-black/15 dark:border-white/20 transition-colors duration-300 ease-in-out"> <a href={`/${collection === 'blog' ? 'blog' : 'projects'}/${entry.$id}`} class="group p-4 gap-3 flex items-center border border-spaghetti-brown rounded-lg hover:bg-spaghetti-red/5 hover:dark:bg-spaghetti-cream/10 dark:border-spaghetti-cream/20 transition-colors duration-300 ease-in-out">
<div class="w-full group-hover:text-black group-hover:dark:text-white blend"> <div class="w-full group-hover:text-spaghetti-red group-hover:dark:text-spaghetti-cream blend">
<div class="flex flex-wrap items-center gap-2"> <div class="flex flex-wrap items-center gap-2">
{pill && {pill &&
<div class="text-sm capitalize px-2 py-0.5 rounded-full border border-black/15 dark:border-white/20 bg-spaghetti-yellow/20 dark:bg-spaghetti-yellow/20 text-spaghetti-brown"> <div class="text-sm capitalize px-2 py-0.5 rounded-full border border-black/15 dark:border-spaghetti-cream/20 bg-spaghetti-yellow/20 dark:bg-spaghetti-yellow/20 dark:text-spaghetti-cream">
{entry.collection === "blog" ? "post" : "project"} {collection === "blog" ? "post" : "project"}
</div> </div>
} }
<div class="text-sm uppercase"> <div class="text-sm uppercase text-spaghetti-brown dark:text-spaghetti-yellow">
{formatDate(entry.data.date)} {formatDate(entry.date)}
</div> </div>
</div> </div>
<div class="font-semibold mt-3 text-spaghetti-brown"> <div class="font-semibold mt-3 text-spaghetti-brown/80 dark:text-spaghetti-cream">
{entry.data.title} {entry.title}
</div> </div>
<div class="text-sm line-clamp-2 text-spaghetti-brown"> <div class="text-sm line-clamp-2 text-spaghetti-brown/80 dark:text-spaghetti-cream">
{entry.data.summary} {entry.summary}
</div> </div>
<ul class="flex flex-wrap mt-2 gap-1"> <ul class="flex flex-wrap mt-2 gap-1">
{entry.data.tags.map((tag:string) => ( // this line has an error; Parameter 'tag' implicitly has an 'any' type.ts(7006) {entry.tags.map((tag:string) => (
<li class="text-xs uppercase py-0.5 px-1 rounded bg-spaghetti-yellow/20 dark:bg-spaghetti-yellow/20 text-spaghetti-brown"> <li class="text-xs uppercase py-0.5 px-1 rounded bg-spaghetti-yellow/20 dark:bg-spaghetti-yellow/20 text-spaghetti-brown/80 dark:text-spaghetti-yellow">
{tag} {tag}
</li> </li>
))} ))}
</ul> </ul>
</div> </div>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round" class="stroke-current group-hover:stroke-black group-hover:dark:stroke-white"> <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round" class="stroke-current group-hover:stroke-black group-hover:dark:stroke-spaghetti-yellow">
<line x1="5" y1="12" x2="19" y2="12" class="scale-x-0 group-hover:scale-x-100 translate-x-4 group-hover:translate-x-1 transition-all duration-300 ease-in-out" /> <line x1="5" y1="12" x2="19" y2="12" class="scale-x-0 group-hover:scale-x-100 translate-x-4 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
<polyline points="12 5 19 12 12 19" class="translate-x-0 group-hover:translate-x-1 transition-all duration-300 ease-in-out" /> <polyline points="12 5 19 12 12 19" class="translate-x-0 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
</svg> </svg>
-1
View File
@@ -1,5 +1,4 @@
--- ---
import { ViewTransitions } from "astro:transitions"
interface Props { interface Props {
title: string title: string
+31 -24
View File
@@ -1,25 +1,28 @@
import type { CollectionEntry } from "astro:content" import type { BlogPost } from "@lib/appwrite-service"
import { createEffect, createSignal, For } from "solid-js" import { createEffect, createSignal, For } from "solid-js"
import ArrowCard from "@components/ArrowCard" import ArrowCard from "@components/ArrowCard"
import { cn } from "@lib/utils" import { cn } from "@lib/utils"
type Props = { type Props = {
tags: string[] tags: string[]
data: CollectionEntry<"blog">[] data: BlogPost[] // Using Appwrite data instead of Astro content collections
} }
export default function Blog({ data, tags }: Props) { export default function Blog({ data, tags }: Props) {
const [filter, setFilter] = createSignal(new Set<string>()) const [filter, setFilter] = createSignal(new Set<string>())
const [posts, setPosts] = createSignal<CollectionEntry<"blog">[]>([]) const [posts, setPosts] = createSignal<BlogPost[]>([])
createEffect(() => { createEffect(() => {
setPosts(data.filter((entry) => setPosts(data.filter((entry) => {
Array.from(filter()).every((value) => // Filter by tags
entry.data.tags.some((tag:string) => const tagMatch = Array.from(filter()).every((value) =>
entry.tags.some((tag:string) =>
tag.toLowerCase() === String(value).toLowerCase() tag.toLowerCase() === String(value).toLowerCase()
) )
) )
))
return tagMatch
}))
}) })
function toggleTag(tag: string) { function toggleTag(tag: string) {
@@ -35,22 +38,26 @@ export default function Blog({ data, tags }: Props) {
<div class="grid grid-cols-1 sm:grid-cols-3 gap-6"> <div class="grid grid-cols-1 sm:grid-cols-3 gap-6">
<div class="col-span-3 sm:col-span-1"> <div class="col-span-3 sm:col-span-1">
<div class="sticky top-24"> <div class="sticky top-24">
<div class="text-sm font-semibold uppercase mb-2 text-spaghetti-brown">Filter</div> <div class="text-sm font-semibold uppercase mb-2 text-spaghetti-brown/80 dark:text-spaghetti-cream">Filter</div>
<ul class="flex flex-wrap sm:flex-col gap-1.5"> {/* Tag Filter */}
<For each={tags}> <div class="mb-2">
{(tag) => ( <div class="text-xs uppercase mb-1 text-spaghetti-brown/70">Tags</div>
<li> <ul class="flex flex-wrap sm:flex-col gap-1.5">
<button onClick={() => toggleTag(tag)} class={cn("w-full px-2 py-1 rounded", "whitespace-nowrap overflow-hidden overflow-ellipsis", "flex gap-2 items-center", "bg-spaghetti-yellow/20 dark:bg-spaghetti-yellow/20", "hover:bg-spaghetti-yellow/30 hover:dark:bg-spaghetti-yellow/30", "transition-colors duration-300 ease-in-out", filter().has(tag) && "text-spaghetti-brown dark:text-spaghetti-brown")}> <For each={tags}>
<svg class={cn("size-5 fill-spaghetti-brown/50 dark:fill-spaghetti-brown/50", "transition-colors duration-300 ease-in-out", filter().has(tag) && "fill-spaghetti-brown dark:fill-spaghetti-brown")}> {(tag) => (
<use href={`/ui.svg#square`} class={cn(!filter().has(tag) ? "block" : "hidden")} /> <li>
<use href={`/ui.svg#square-check`} class={cn(filter().has(tag) ? "block" : "hidden")} /> <button onClick={() => toggleTag(tag)} class={cn("w-full px-2 py-1 rounded", "whitespace-nowrap overflow-hidden overflow-ellipsis", "flex gap-2 items-center", "bg-spaghetti-yellow/20 dark:bg-spaghetti-yellow/20", "hover:bg-spaghetti-yellow/30 hover:dark:bg-spaghetti-yellow/30", "transition-colors duration-300 ease-in-out", filter().has(tag) && "text-spaghetti-brown/80 dark:text-spaghetti-brown")}>
</svg> <svg class={cn("size-5 fill-spaghetti-brown/50 dark:fill-spaghetti-brown/50", "transition-colors duration-300 ease-in-out", filter().has(tag) && "fill-spaghetti-brown dark:fill-spaghetti-brown")}>
{tag} <use href={`/ui.svg#square`} class={cn(!filter().has(tag) ? "block" : "hidden")} />
</button> <use href={`/ui.svg#square-check`} class={cn(filter().has(tag) ? "block" : "hidden")} />
</li> </svg>
)} {tag}
</For> </button>
</ul> </li>
)}
</For>
</ul>
</div>
</div> </div>
</div> </div>
<div class="col-span-3 sm:col-span-2"> <div class="col-span-3 sm:col-span-2">
@@ -61,7 +68,7 @@ export default function Blog({ data, tags }: Props) {
<ul class="flex flex-col gap-3"> <ul class="flex flex-col gap-3">
{posts().map((post) => ( {posts().map((post) => (
<li> <li>
<ArrowCard entry={post} /> <ArrowCard entry={post} collection={'blog'} />
</li> </li>
))} ))}
</ul> </ul>
+2 -1
View File
@@ -1,6 +1,7 @@
--- ---
import { SITE, SOCIALS } from "@consts" import { SITE, SOCIALS } from "@consts"
import Container from "@components/Container.astro" import Container from "@components/Container.astro"
// Remove unused storage import
--- ---
<footer class="relative bg-white dark:bg-black"> <footer class="relative bg-white dark:bg-black">
@@ -26,7 +27,7 @@ import Container from "@components/Container.astro"
<div class="grid grid-cols-1 sm:grid-cols-2 gap-3"> <div class="grid grid-cols-1 sm:grid-cols-2 gap-3">
<div class="flex flex-col items-center sm:items-start"> <div class="flex flex-col items-center sm:items-start">
<a href="/" class="flex gap-1 w-fit font-semibold text-current hover:text-black dark:hover:text-white transition-colors duration-300 ease-in-out"> <a href="/" class="flex gap-1 w-fit font-semibold text-current hover:text-black dark:hover:text-white transition-colors duration-300 ease-in-out">
<img src="https://appdev.spaghet.io/v1/storage/buckets/689cda7900102e12abf2/files/689d265e0036955a618d/view?project=689783c90022d294b15c" alt="Logo" class="size-6" /> <img src="/api/assets/689d265e0036955a618d" alt="Logo" class="size-6" />
{SITE.TITLE} {SITE.TITLE}
</a> </a>
</div> </div>
+2 -2
View File
@@ -11,7 +11,7 @@ import Container from "@components/Container.astro"
<div class="relative h-full w-full"> <div class="relative h-full w-full">
<div class="absolute left-0 top-1/2 -translate-y-1/2 flex gap-1 font-semibold"> <div class="absolute left-0 top-1/2 -translate-y-1/2 flex gap-1 font-semibold">
<a href="/" class="flex gap-1 text-current hover:text-spaghetti-brown dark:hover:text-spaghetti-brown transition-colors duration-300 ease-in-out"> <a href="/" class="flex gap-1 text-current hover:text-spaghetti-brown dark:hover:text-spaghetti-brown transition-colors duration-300 ease-in-out">
<img src="${import.meta.env.APPWRITE_ENDPOINT}/v1/storage/buckets/${import.meta.env.APPWRITE_BUCKET_ID}/files/689d265e0036955a618d/view?project=${import.meta.env.APPWRITE_PROJECT_ID}" alt="Logo" class="size-6" /> <img src='/api/assets/689d265e0036955a618d' alt="Logo" class="size-6" />
<div> <div>
{SITE.TITLE} {SITE.TITLE}
</div> </div>
@@ -22,7 +22,7 @@ import Container from "@components/Container.astro"
<nav class="hidden md:flex items-center justify-center text-sm gap-1"> <nav class="hidden md:flex items-center justify-center text-sm gap-1">
{ {
LINKS.map((LINK) => ( LINKS.map((LINK) => (
<a href={LINK.HREF} class={cn("h-8 rounded-full px-3 text-current", "flex items-center justify-center", "transition-colors duration-300 ease-in-out", pathname === LINK.HREF || "/" + subpath?.[0] === LINK.HREF ? "bg-spaghetti-red dark:bg-spaghetti-red text-spaghetti-brown dark:text-spaghetti-brown" : "hover:bg-black/5 dark:hover:bg-white/20 hover:text-black dark:hover:text-white")}> <a href={LINK.HREF} class={cn("h-8 rounded-full px-3 text-current", "flex items-center justify-center", "transition-colors duration-300 ease-in-out", pathname === LINK.HREF || "/" + subpath?.[0] === LINK.HREF ? "bg-spaghetti-red dark:bg-spaghetti-cream text-black dark:text-spaghetti-brown" : "hover:bg-spaghetti-red/5 dark:hover:bg-spaghetti-red/20 hover:text-black dark:hover:text-white")}>
{LINK.TEXT} {LINK.TEXT}
</a> </a>
)) ))
+5 -5
View File
@@ -1,21 +1,21 @@
import type { CollectionEntry } from "astro:content" import type { Project } from "@lib/appwrite-service"
import { createEffect, createSignal, For } from "solid-js" import { createEffect, createSignal, For } from "solid-js"
import ArrowCard from "@components/ArrowCard" import ArrowCard from "@components/ArrowCard"
import { cn } from "@lib/utils" import { cn } from "@lib/utils"
type Props = { type Props = {
tags: string[] tags: string[]
data: CollectionEntry<"projects">[] data: Project[] | any[]
} }
export default function Projects({ data, tags }: Props) { export default function Projects({ data, tags }: Props) {
const [filter, setFilter] = createSignal(new Set<string>()) const [filter, setFilter] = createSignal(new Set<string>())
const [projects, setProjects] = createSignal<CollectionEntry<"projects">[]>([]) const [projects, setProjects] = createSignal<Project[]>([])
createEffect(() => { createEffect(() => {
setProjects(data.filter((entry) => setProjects(data.filter((entry) =>
Array.from(filter()).every((value) => Array.from(filter()).every((value) =>
entry.data.tags.some((tag:string) => entry.tags.some((tag:string) =>
tag.toLowerCase() === String(value).toLowerCase() tag.toLowerCase() === String(value).toLowerCase()
) )
) )
@@ -61,7 +61,7 @@ export default function Projects({ data, tags }: Props) {
<ul class="flex flex-col gap-3"> <ul class="flex flex-col gap-3">
{projects().map((project) => ( {projects().map((project) => (
<li> <li>
<ArrowCard entry={project} /> <ArrowCard entry={project} collection={'projects'} />
</li> </li>
))} ))}
</ul> </ul>
+101 -29
View File
@@ -1,29 +1,52 @@
import type { CollectionEntry } from "astro:content" import type { BlogPost, Project } from "@lib/appwrite-service"
import { createEffect, createSignal } from "solid-js" import { createEffect, createSignal, onCleanup } from "solid-js"
import Fuse from "fuse.js"
import ArrowCard from "@components/ArrowCard" import ArrowCard from "@components/ArrowCard"
import { searchContent } from "@lib/appwrite-service"
type Props = { type Props = {
data: CollectionEntry<"blog">[] query?: string
} }
export default function Search({data}: Props) { export default function Search(props: Props) {
const [query, setQuery] = createSignal("") const [query, setQuery] = createSignal(props.query || "")
const [results, setResults] = createSignal<CollectionEntry<"blog">[]>([]) const [results, setResults] = createSignal<{ posts: BlogPost[], projects: Project[] }>({ posts: [], projects: [] })
const [loading, setLoading] = createSignal(false)
const fuse = new Fuse(data, { const [error, setError] = createSignal<string | null>(null)
keys: ["slug", "data.title", "data.summary", "data.tags"],
includeMatches: true, // Debounce timeout reference
minMatchCharLength: 2, let debounceTimeout: NodeJS.Timeout | null = null
threshold: 0.4,
})
// Use Appwrite SDK to search all data with debouncing
createEffect(() => { createEffect(() => {
if (query().length < 2) { if (query().length < 2) {
setResults([]) setResults({ posts: [], projects: [] })
} else { setError(null)
setResults(fuse.search(query()).map((result) => result.item)) return
} }
// Clear previous timeout
if (debounceTimeout) {
clearTimeout(debounceTimeout)
}
// Set new debounce timeout
debounceTimeout = setTimeout(() => {
setLoading(true)
searchContent(query())
.then(searchResults => {
setResults(searchResults)
setError(null)
})
.catch(err => {
console.error("Search error:", err)
// Handle error gracefully - maybe show an error message to user
setResults({ posts: [], projects: [] })
setError("Search failed. Please try again.")
})
.finally(() => {
setLoading(false)
})
}, 300) // 300ms debounce delay
}) })
const onInput = (e: Event) => { const onInput = (e: Event) => {
@@ -31,26 +54,75 @@ export default function Search({data}: Props) {
setQuery(target.value) setQuery(target.value)
} }
const handleSubmit = (e: Event) => {
e.preventDefault()
// Prevent page refresh by using client-side navigation
if (query().length >= 2) {
// Search will automatically trigger due to createEffect
// Update URL without full page reload
const newUrl = `${window.location.pathname}?search=${encodeURIComponent(query())}`
window.history.pushState({}, "", newUrl)
// Dispatch custom event to update search results (removed for now - not needed with createEffect)
}
}
// Cleanup debounce timeout on component unmount
onCleanup(() => {
if (debounceTimeout) {
clearTimeout(debounceTimeout)
}
})
return ( return (
<div class="flex flex-col"> <div class="flex flex-col">
<div class="relative"> <form onSubmit={handleSubmit} class="relative" classList={{ "animate-pulse": loading() }}>
<input name="search" type="text" value={query()} onInput={onInput} autocomplete="off" spellcheck={false} placeholder="What are you looking for?" class="w-full px-2.5 py-1.5 pl-10 rounded outline-none text-spaghetti-brown bg-spaghetti-yellow/20 dark:bg-spaghetti-yellow/20 border border-spaghetti-yellow/50 dark:border-spaghetti-yellow/50 focus:border-spaghetti-red focus:dark:border-spaghetti-red"/> <input
name="search"
type="text"
value={query()}
onInput={onInput}
autocomplete="off"
spellcheck={false}
placeholder="What are you looking for?"
class="w-full px-2.5 py-1.5 pl-10 rounded outline-none text-spaghetti-brown bg-spaghetti-yellow/20 dark:bg-spaghetti-yellow/20 border border-spaghetti-yellow/50 dark:border-spaghetti-yellow/50 focus:border-spaghetti-red focus:dark:border-spaghetti-red"
/>
<svg class="absolute size-6 left-1.5 top-1/2 -translate-y-1/2 stroke-current"> <svg class="absolute size-6 left-1.5 top-1/2 -translate-y-1/2 stroke-current">
<use href={`/ui.svg#search`}/> <use href={`/ui.svg#search`}/>
</svg> </svg>
</div> </form>
{(query().length >= 2 && results().length >= 1) && ( {error() && <div class="mt-4 text-red-500">{error()}</div>}
{loading() && <div class="mt-4">Searching...<span class="ml-2 animate-spin">⏳</span></div>}
{(query().length >= 2 && (results().posts.length > 0 || results().projects.length > 0)) && (
<div class="mt-12"> <div class="mt-12">
<div class="text-sm uppercase mb-2"> <div class="text-sm uppercase mb-2">
Found {results().length} results for {`'${query()}'`} Found {results().posts.length + results().projects.length} results for {`'${query()}'`}
</div>
<div class="flex flex-col gap-6 mt-4">
{results().posts.length > 0 && (
<div class="border-t border-spaghetti-yellow/30 pt-4">
<div class="text-sm font-bold mb-2">Blog Posts</div>
<ul class="flex flex-col gap-3">
{results().posts.map(result => (
<li>
<ArrowCard entry={result} pill={true} collection={'blog'} />
</li>
))}
</ul>
</div>
)}
{results().projects.length > 0 && (
<div class="border-t border-spaghetti-yellow/30 pt-4">
<div class="text-sm font-bold mb-2">Projects</div>
<ul class="flex flex-col gap-3">
{results().projects.map(result => (
<li>
<ArrowCard entry={result} pill={true} collection={'projects'} />
</li>
))}
</ul>
</div>
)}
</div> </div>
<ul class="flex flex-col gap-3">
{results().map(result => (
<li>
<ArrowCard entry={result} pill={true} />
</li>
))}
</ul>
</div> </div>
)} )}
</div> </div>
@@ -1,80 +0,0 @@
---
title: "Building My Personal Website: From Idea to Deployment"
summary: "A journey through creating my personal portfolio site, from initial concept to hosting on Appwrite with NGINX Proxy Manager."
date: "Aug 12 2025"
draft: false
tags:
- Tutorial
- Astro
- Portfolio
- Hosting
- Appwrite
- Docker
---
As someone who loves spaghetti and all things tech, I've always been fascinated by the perfect balance of structure and creativity. When it came time to create my personal website, I wanted to build something that reflected both my passion for technology and my love for well-organized systems.
## The Concept
I decided to use Astro as the foundation for my portfolio site because of its excellent performance and flexibility. The idea was to create a modern, responsive website that showcases my work and projects while demonstrating my technical skills through the implementation itself.
The site needed to be:
- Fast and performant
- Responsive across all devices
- Easy to maintain and update
- A reflection of my technical expertise
## Development Process
I started by setting up the basic structure using Astro's capabilities. The site features:
- A clean, modern design with dark/light mode support
- Smooth animations and transitions for enhanced user experience
- Integrated blog section for technical articles
- Project showcase with detailed descriptions
- Contact form with email integration
- SEO optimization for better search engine visibility
## Deployment Strategy
This is where things get interesting. As someone running 2 Unraid servers with powerful hardware configurations (128GB RAM, 2 x E5 Xeon CPU, 200TB raw storage on NetApp arrays), I wanted to leverage my existing infrastructure for hosting this personal website.
### My Hosting Setup
I'm planning to host this site on my Appwrite instance, which is part of my comprehensive Docker container ecosystem. The setup includes:
- Appwrite for backend services and database management
- NGINX Proxy Manager (NPM) to expose the site via HTTPS at https://spaghet.io
- A robust Docker infrastructure supporting PostgreSQL, MariaDB, MySQL, MongoDB, Redis, and Minio
### Challenges with Appwrite
While setting up the deployment, I've been working through some configuration challenges with Appwrite. Getting it to behave properly has been a learning experience, but also a great opportunity to dive deep into the platform's capabilities.
The process has involved:
- Understanding Appwrite's API structure
- Configuring proper database connections
- Setting up authentication and user management
- Ensuring proper security configurations
## Technical Details
The site leverages modern web development practices including:
- Component-based architecture with React
- Responsive design principles using Tailwind CSS
- Performance optimization techniques
- Integration with my existing Docker ecosystem
## Why This Approach?
I chose this approach because it reflects how I think about technology - structured, well-organized, and efficient. Just like a perfect bowl of spaghetti, everything has its place and works together seamlessly.
The experience of building and deploying this site has been both challenging and rewarding, showcasing my ability to work with complex systems while maintaining a clear focus on the end-user experience.
## Looking Forward
As I continue to develop this site, I plan to:
- Add more technical articles about my Docker setups and infrastructure
- Expand the blog section with detailed tutorials
- Continue refining the user experience based on feedback
- Document my journey of getting Appwrite to work properly
This project represents not just a portfolio, but also a demonstration of my approach to technology - structured yet creative, efficient yet elegant.
@@ -1,66 +0,0 @@
---
title: "Fixing Appwrite Issues: Correcting NGINX Forwarding and Reverse Proxy Configuration"
summary: "A detailed walkthrough of how I resolved nginx forwarding issues to properly configure reverse proxy redirection for my Appwrite deployments."
date: "Aug 13 2025"
draft: false
tags:
- Tutorial
- Appwrite
- NGINX
- Reverse Proxy
- Docker
- Troubleshooting
---
As someone who loves to dive deep into technical challenges, I recently encountered a frustrating issue with my Appwrite setup that required some serious troubleshooting. The problem was related to nginx forwarding and reverse proxy configuration, which prevented my deployed websites from being properly accessible.
## The Problem
I was working on deploying multiple websites using Appwrite as part of my comprehensive Docker container ecosystem. My setup includes:
- Appwrite for backend services and database management
- NGINX Proxy Manager (NPM) to expose sites via HTTPS
- A robust Docker infrastructure supporting various services
The issue occurred when I tried to access my newly deployed websites through the reverse proxy. Instead of seeing my content, I was encountering errors or being redirected incorrectly.
## Root Cause Analysis
After extensive debugging, I discovered that the problem stemmed from improper nginx configuration for forwarding requests to Appwrite and the correct routing of those requests through my reverse proxy setup.
## The Solution
I had to make several key adjustments:
### 1. Ensuring Proper Reverse Proxy Configuration
Next, I made sure that the reverse proxy was correctly redirecting to my new websites:
```nginx
location / {
proxy_pass http://your-appwrite-container:80;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
```
## Key Takeaways
This experience taught me several important lessons about reverse proxy configuration in Docker environments:
1. **Network Configuration is Critical**: Make sure all containers are on the same network and can communicate properly.
2. **Header Settings Matter**: Properly setting `X-Forwarded-*` headers ensures that applications receive correct information about the original request.
3. **Testing Each Component**: When troubleshooting, test individual components (nginx, appwrite, docker networks) to isolate the root cause.
4. **Documentation**: Keep detailed notes of configuration changes for future reference and easier debugging.
## Final Result
After implementing these fixes, my Appwrite setup was working perfectly with proper nginx forwarding and reverse proxy redirection. I could now access all my deployed websites through the correct HTTPS endpoints managed by NGINX Proxy Manager.
This experience reinforced the importance of understanding how different components in a Docker ecosystem interact with each other, especially when it comes to networking and proxy configurations.
The solution not only fixed my immediate problem but also improved my overall understanding of how to properly configure reverse proxies for complex applications like Appwrite. This knowledge will be invaluable as I continue to expand my infrastructure and deploy more services.
@@ -1,134 +0,0 @@
---
title: "Spaghet.io Website Improvements: A Comprehensive UI/UX Overhaul"
date: 2025-08-13
summary: "Detailed summary of all the UI/UX improvements made to the Spaghet.io website, including dark mode fixes, theme enhancements, and component updates."
tags: [website, ui, ux, improvements, spaghetti]
draft: false
---
## Introduction
This post documents a comprehensive UI/UX overhaul of my personal website, Spaghet.io. The changes were focused on improving visual consistency, fixing dark mode conflicts, and enhancing the overall user experience while maintaining our signature spaghetti-themed aesthetic.
## Goal of This Session
The primary objective was to enhance the website's visual design by:
1. Resolving dark mode conflicts with prose elements
2. Ensuring consistent theme application across all components
3. Fixing text color issues in selected menu items and buttons
4. Making sure the spaghetti theme is consistently applied throughout the site
## Key Improvements Made
### 1. Fixed Dark Mode Conflicts with tw-prose Classes
**Problem**: The website had conflicts where prose elements (blog content) were not respecting our custom theme colors in dark mode, resulting in poor readability.
**Solution**:
- Updated `tailwind.config.mjs` to properly customize typography styles
- Added CSS overrides in `global.css` to ensure spaghetti-themed colors are applied consistently in prose elements
### 2. Enhanced Theme Consistency Across Components
**Problem**: Various components had inconsistent color usage, particularly in text and hover states.
**Solution**:
- Updated Header component to use proper text-spaghetti-brown colors for hover states
- Fixed Footer component with consistent text-spaghetti-brown colors for legal links
- Applied consistent theme classes throughout ArrowCard, Blog, Projects, StackCard, Search, Counter, and Drawer components
### 3. Implemented Spaghetti-Themed Color Palette
**Color Scheme**:
- Main color: `#FDE68A` (spaghetti-yellow)
- Accent color: `#FECACA` (spaghetti-red)
- Background: `#FEF3C7` (spaghetti-cream)
- Text: `#78350F` (spaghetti-brown)
### 4. Fixed Selected Menu Items and Buttons
**Problem**: Selected menu items and buttons had light red backgrounds with white text, which was inconsistent with our theme.
**Solution**:
- Updated Header navigation items to use `text-spaghetti-brown` instead of `text-white` for selected states
- Updated Drawer navigation items to use `text-spaghetti-brown` instead of `text-white` for selected states
- Updated Search button in header to use `text-spaghetti-brown` instead of `text-white` for selected states
- Updated mobile drawer button to use `text-spaghetti-brown` instead of `text-white` for selected states
### 5. Enhanced Hero Section with Spaghetti Theme
**Improvements**:
- Applied consistent text-spaghetti-brown colors throughout the hero section
- Styled call-to-action buttons with spaghetti-red background and spaghetti-yellow borders
- Maintained consistent theme application throughout the entire hero section
## Technical Implementation Details
### CSS Customizations
The following changes were made to `src/styles/global.css`:
```css
/* Override default prose styles to respect our theme */
.prose {
color: var(--spaghetti-brown);
}
.prose a {
color: var(--spaghetti-red);
}
.prose h1,
.prose h2,
.prose h3,
.prose h4,
.prose h5,
.prose h6 {
color: var(--spaghetti-brown);
}
/* Ensure dark mode respects our theme */
.dark .prose {
color: var(--spaghetti-brown);
}
.dark .prose a {
color: var(--spaghetti-red);
}
```
### Component Updates
All affected components were updated to use:
- `text-spaghetti-brown` for text content
- `bg-spaghetti-red` for selected states
- `border-spaghetti-yellow/50` for borders
- Consistent hover effects with appropriate color transitions
## Before and After Comparison
### Navigation Menu
**Before**: Selected items had light red background (`bg-spaghetti-red`) with white text (`text-white`)
**After**: Selected items have light red background (`bg-spaghetti-red`) with dark brown text (`text-spaghetti-brown`)
### Prose Elements
**Before**: Default Tailwind prose styles were overriding our theme colors in dark mode
**After**: Custom CSS ensures consistent spaghetti-themed colors across all content
### Hero Section
**Before**: Inconsistent color usage throughout the hero section
**After**: Cohesive spaghetti theme with consistent text-spaghetti-brown colors for all content
## Future Improvements
While these changes have significantly improved the website's UI/UX, there are always opportunities for further enhancement:
1. Implement more sophisticated animations and transitions
2. Add more interactive elements with our spaghetti theme
3. Continue refining the dark mode experience
4. Explore additional theme variations that maintain the spaghetti aesthetic
## Conclusion
These improvements represent a significant step forward in creating a consistent, visually appealing, and user-friendly website that truly embodies the spirit of spaghetti - structured, well-organized, and satisfying to use. The site now maintains a cohesive design language while providing an enhanced user experience across all device sizes and themes.
The changes ensure that our signature spaghetti theme is consistently applied throughout the entire website, from navigation elements to content presentation, creating a unified and memorable user experience.
@@ -1,51 +0,0 @@
---
title: "Astro Sphere: File Structure"
summary: "You'll find these directories and files in the project. What do they do?"
date: "Mar 17 2024"
draft: true
tags:
- Tutorial
- Astro
- Astro Sphere
---
A one line summary of what each file and directory is for:
```js
/
├── public/ // Files publicly available to the browser
│ ├── fonts/ // The default fonts for Astro Sphere
│ │ └── atkinson-bold.woff // default font weight 700
│ │ └── atkinson-regular.woff // default font weight 400
│ ├── js/ // Javascript that will be imported into <head>
│ │ └── animate.js // function for animating page elements
│ │ └── bg.js // function for generating the background
│ │ └── scroll.js // scroll handler for the header styles
│ │ └── theme.js // controls the light and dark theme
│ └── brand.svg //the icon that displays in header and footer
│ └── favicon.svg //the icon that displays in the browser
│ └── ui.svg // an svg sprite for all ui icons on the website
│ └── social.svg // an svg sprite for all social media icons
│ └── open-graph.jpg // the default image for open-graph
│ └── robots.txt // for web crawlers and bots to index the website
├── src/ // Everything that will be built for the website
│ ├── components/ // All astro and SolidJs components
│ ├── content/ // Contains all static markdown to be compiled
│ │ | blog/ // Contains all blog post markdown
│ │ | projects/ // Contains all projects markdown
│ │ | work/ // Contains all work page markdown
│ │ | legal/ // Contains all legal docs markdown
│ │ └── config.ts // Contains the collection config for Astro
│ ├── layouts/ // Reused layouts across the website
│ └── pages/ // All of the pages on the website
│ └── styles/ // CSS and global tailwind styles
│ └── lib/ // Global helper functions
│ └── consts.ts // Page metadata, general configuration
│ └── types.ts // Types for consts.ts
└── .gitignore // Files and directories to be ignored by Git
└── .eslintignore // Files and directories to be ignored by ESLint
└── eslintrc.cjs // ESLint configuration
└── astro.config.mjs // Astro configuration
└── tailwind.config.mjs // Tailwind configuration
└── tsconfig.json // Typescript configuration
└── package.json // All the installed packages
```
@@ -1,90 +0,0 @@
---
title: "Astro Sphere: Getting Started"
summary: "You've downloaded and installed the project. Let's hit the ground running."
date: "Mar 16 2024"
draft: true
tags:
- Tutorial
- Astro
- Astro Sphere
---
Astro Sphere is designed to be configurable. This article will cover the basics on
configuring the site and make it personal.
### First let's change the url
```js
//astro.config.mjs
export default defineConfig({
site: "https://awesome-portfolio.com", // your domain here
integrations: [mdx(), sitemap(), solidJs(), tailwind({ applyBaseStyles: false })],
})
```
### Next, Let's configure the Site
```js
// src/consts.ts
export const SITE: Site = {
TITLE: "Astro Sphere",
DESCRIPTION: "Welcome to Astro Sphere, a portfolio and blog for designers and developers.",
AUTHOR: "Mark Horn",
}
```
| Field | Type | Description |
| :---------- | :----- | :--------------------------------------------------------------------- |
| TITLE | String | The title of the website. Displayed in header and footer. Used in SEO. |
| DESCRIPTION | String | The description of the index page of the website. Used in SEO. |
| AUTHOR | String | Your name. |
### Change the branding
The browser icon is located in `/public/favicon.svg`
The header and footer branding icon is located in `/public/brand.svg` as a sprite with id="brand"
### The rest of the consts file
Each page has a metadata entry that is useful for SEO.
```js
export const WORK: Page = {
TITLE: "Work",
DESCRIPTION: "Places I have worked.",
}
```
The links that are displayed in the header and drawer
```js
export const LINKS: Links = [
{ HREF: "/", TEXT: "Home" },
{ HREF: "/work", TEXT: "Work" },
{ HREF: "/blog", TEXT: "Blog" },
{ HREF: "/projects", TEXT: "Projects" },
]
```
The social media links
```js
export const SOCIALS: Socials = [
{
NAME: "Github",
ICON: "github",
TEXT: "markhorn-dev",
HREF: "https://github.com/markhorn-dev/astro-sphere"
},
]
```
| Field | Type | Required | Description |
| :---- | :--- | :------- | :---------- |
| NAME | string | yes | Accessible name |
| ICON | string | yes | Refers to the symbol id in `public/social.svg` |
| TEXT | string | yes | Shorthand profile name |
| HREF | string | yes | The link to the social media profile |
@@ -1,87 +0,0 @@
---
title: "Astro Sphere: Adding a new post or project."
summary: "Adding a new article (blog post or project) is pretty easy."
date: "Mar 14 2024"
draft: true
tags:
- Tutorial
- Astro
- Astro Sphere
---
### Basics
Create a folder in the respective collection you wish to create content. The name of the folder will be the slug in which your content will be found.
```text
creating the following
/content/blog/my-new-post/index.md
will be published to
https://yourdomain.com/blog/my-new-post
```
### Frontmatter
Front matter is in yaml if you are familiar with the format. All posts and projects require frontmatter at the top of the document to be imported. All frontmatter must be inside triple dashes, similar to Astro format. See example below.
### Blog Collection
| Field | Type | Req? | Description |
| :------ | :------ | :--- | :------------------------------------------------------------ |
| title | string | yes | Title of the post. Used in SEO. |
| summary | string | yes | Short description of the post. Used in SEO. |
| date | string | yes | Any string date that javascript can convert. Used in sorting |
| tags | array | yes | Post topic. Array of strings. Used in filtering. |
| draft | boolean | no | Hides the post from collections. Unpublished entry. |
Example blog post frontmatter
```yaml
---
title: "Astro Sphere: Adding a new post or project."
summary: "Adding a new article (blog post or project) is pretty easy."
date: "Mar 18 2024"
draft: false
tags:
- Tutorial
- Astro
- Astro Sphere
---
```
### Projects Collection (extends Blog Collection)
| Field | Type | Req? | Description |
| :------ | :------ | :--- | :------------------------------------------------------------ |
| title | string | yes | Title of the post. Used in SEO. |
| summary | string | yes | Short description of the post. Used in SEO. |
| date | string | yes | Any string date that javascript can convert. Used in sorting |
| tags | array | yes | Post topic. Array of strings. Used in filtering. |
| draft | boolean | no | Hides the post from collections. Unpublished entry. |
| demoUrl | string | no | A link to the deployed project, if applicable. |
| repoUrl | string | no | A link to the repository, if applicable. |
Example project frontmatter
```yaml
---
title: "Astro Sphere"
summary: "Astro Sphere, a portfolio and blog for designers and developers."
date: "Mar 18 2024"
draft: false
tags:
- Astro
- Typescript
- Javascript
- Tailwind
- SolidJS
demoUrl: https://astro-sphere.vercel.app
repoUrl: https://github.com/markhorn-dev/astro-sphere
---
```
### Write your content
You've made it this far, all that is left to do is write your content beneath the frontmatter. Writing markdown will be covered in the next article.
@@ -1,236 +0,0 @@
---
title: "Astro Sphere: Writing Markdown"
summary: "Basic Markdown syntax that can be used when writing Markdown content in Astro Sphere."
date: "Mar 13 2024"
draft: true
tags:
- Tutorial
- Astro
- Astro Sphere
- Markdown
---
### Headings
```text
# H1
## H2
### H3
#### H4
##### H5
###### H6
```
# H1
## H2
### H3
#### H4
##### H5
###### H6
### Paragraph
Xerum, quo qui aut unt expliquam qui dolut labo. Aque venitatiusda cum, voluptionse latur sitiae dolessi aut parist aut dollo enim qui voluptate ma dolestendit peritin re plis aut quas inctum laceat est volestemque commosa as cus endigna tectur, offic to cor sequas etum rerum idem sintibus eiur? Quianimin porecus evelectur, cum que nis nust voloribus ratem aut omnimi, sitatur? Quiatem. Nam, omnis sum am facea corem alique molestrunt et eos evelece arcillit ut aut eos eos nus, sin conecerem erum fuga. Ri oditatquam, ad quibus unda veliamenimin cusam et facea ipsamus es exerum sitate dolores editium rerore eost, temped molorro ratiae volorro te reribus dolorer sperchicium faceata tiustia prat.
Itatur? Quiatae cullecum rem ent aut odis in re eossequodi nonsequ idebis ne sapicia is sinveli squiatum, core et que aut hariosam ex eat.
### Images
Relative image in the /public folder
```markdown
![blog placeholder](/open-graph.jpg)
```
![blog placeholder](/open-graph.jpg)
Relative Image in the same folder as the markdown
```markdown
![Test Relative Image](./spongebob.png)
```
![Test Relative Image](./spongebob.png)
## Blockquotes
The blockquote element represents content that is quoted from another source, optionally with a citation which must be within a `footer` or `cite` element, and optionally with in-line changes such as annotations and abbreviations.
### Blockquote without attribution
#### Syntax
```markdown
> Tiam, ad mint andaepu dandae nostion secatur sequo quae.
> **Note** that you can use _Markdown syntax_ within a blockquote.
```
#### Output
> Tiam, ad mint andaepu dandae nostion secatur sequo quae.
> **Note** that you can use _Markdown syntax_ within a blockquote.
### Blockquote with attribution
#### Syntax
```markdown
> Don't communicate by sharing memory, share memory by communicating.<br>
> — <cite>Rob Pike[^1]</cite>
```
#### Output
> Don't communicate by sharing memory, share memory by communicating.<br>
> — <cite>Rob Pike[^1]</cite>
[^1]: The above quote is excerpted from Rob Pike's [talk](https://www.youtube.com/watch?v=PAAkCSZUG1c) during Gopherfest, November 18, 2015.
## Tables
#### Syntax
```markdown
| Italics | Bold | Code |
| --------- | -------- | ------ |
| _italics_ | **bold** | `code` |
```
#### Output
| Italics | Bold | Code |
| --------- | -------- | ------ |
| _italics_ | **bold** | `code` |
## Code Blocks
#### Syntax
we can use 3 backticks ``` in new line and write snippet and close with 3 backticks on new line and to highlight language specific syntac, write one word of language name after first 3 backticks, for eg. html, javascript, css, markdown, typescript, txt, bash
````markdown
```html
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>Example HTML5 Document</title>
</head>
<body>
<p>Test</p>
</body>
</html>
```
````
Output
```html
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>Example HTML5 Document</title>
</head>
<body>
<p>Test</p>
</body>
</html>
```
## List Types
### Ordered List
#### Syntax
```markdown
1. First item
2. Second item
3. Third item
```
#### Output
1. First item
2. Second item
3. Third item
### Unordered List
#### Syntax
```markdown
- List item
- Another item
- And another item
```
#### Output
- List item
- Another item
- And another item
### Nested list
#### Syntax
```markdown
- Fruit
- Apple
- Orange
- Banana
- Dairy
- Milk
- Cheese
```
#### Output
- Fruit
- Apple
- Orange
- Banana
- Dairy
- Milk
- Cheese
## Other Elements — abbr, sub, sup, kbd, mark
#### Syntax
```markdown
<abbr title="Graphics Interchange Format">GIF</abbr> is a bitmap image format.
H<sub>2</sub>O
X<sup>n</sup> + Y<sup>n</sup> = Z<sup>n</sup>
Press <kbd><kbd>CTRL</kbd>+<kbd>ALT</kbd>+<kbd>Delete</kbd></kbd> to end the session.
Most <mark>salamanders</mark> are nocturnal, and hunt for insects, worms, and other small creatures.
```
#### Output
<abbr title="Graphics Interchange Format">GIF</abbr> is a bitmap image format.
H<sub>2</sub>O
X<sup>n</sup> + Y<sup>n</sup> = Z<sup>n</sup>
Press <kbd><kbd>CTRL</kbd>+<kbd>ALT</kbd>+<kbd>Delete</kbd></kbd> to end the session.
Most <mark>salamanders</mark> are nocturnal, and hunt for insects, worms, and other small creatures.
Binary file not shown.

Before

Width:  |  Height:  |  Size: 90 KiB

@@ -1,16 +0,0 @@
---
type Props = {
name: string
}
const { name } = Astro.props
---
<div class="border p-4 bg-yellow-100 text-black">
<div>
Hello,
<span class="font-semibold">
{name}!!!
</span>
</div>
<slot/>
</div>
@@ -1,53 +0,0 @@
---
title: "Astro Sphere: Writing MDX"
summary: "Lorem ipsum dolor sit amet"
date: "Mar 12 2024"
draft: true
tags:
- Tutorial
- Astro
- Astro Sphere
- Markdown
- MDX
---
MDX is a special flavor of Markdown that supports embedded JavaScript & JSX syntax. This unlocks the ability to [mix JavaScript and UI Components into your Markdown content](https://docs.astro.build/en/guides/markdown-content/#mdx-features) for things like interactive charts or alerts.
If you have existing content authored in MDX, this integration will hopefully make migrating to Astro a breeze.
## An astro component with props
```
// Imported from relative path (same dir as markdown file)
import MyComponent from "./MyComponent.astro"
<MyComponent name="You">
Welcome to MDX
</MyComponent>
```
import MyComponent from "./MyComponent.astro"
<MyComponent name="You">
Welcome to MDX
</MyComponent>
## An interactive Solid Js component
```
// Imported from components directory (src/components)
import MyComponent from "@components/Counter"
// Don't forget the astro client:load directive
<Counter client:load />
```
import Counter from "@components/Counter"
<Counter client:load />
<br/>
<br/>
<br/>
@@ -1,54 +0,0 @@
---
title: "Astro Sphere: Social media links"
summary: "A quick tutorial on how to change, add or remove social media links"
date: "Mar 11 2024"
draft: true
tags:
- Tutorial
- Astro
- Astro Sphere
---
Astro Sphere comes preconfigured with social media links for Email, Github, Linked In and Twitter (X), but it's very easy to add more.
### Edit `consts.ts`
```js
// consts.ts
export const SOCIALS: Socials = [
{
NAME: "Github",
ICON: "github",
TEXT: "markhorn-dev",
HREF: "https://github.com/markhorn-dev/astro-sphere"
},
]
```
| Field | Type | Required | Description |
| :---- | :--- | :------- | :---------- |
| NAME | string | yes | Accessible name |
| ICON | string | yes | Refers to the symbol id in `public/social.svg` |
| TEXT | string | yes | Shorthand profile name |
| HREF | string | yes | The link to the social media profile |
### Edit /public/social.svg
Simply add your own symbols to the svg sprite.
It is recommended that all styles be removed from new symbols added, or they may not show up correctly or conflict with Tailwind's classes.
The id should match the icon field as specified in your `consts.ts` file.
```html
<!-- public/social.svg -->
<svg xmlns="http://www.w3.org/2000/svg">
<defs>
<symbol id="github" viewBox="0 0 496 512">
<path d="M165.9 397.4c0 2-2.3 3.6-5.2 3.6-3.3 .3-5.6-1.3-5.6-3.6 0-2 2.3-3.6 5.2-3.6 3-.3 5.6 1.3 5.6 3.6zm-31.1-4.5c-.7 2 1.3 4.3 4.3 4.9 2.6 1 5.6 0 6.2-2s-1.3-4.3-4.3-5.2c-2.6-.7-5.5 .3-6.2 2.3zm44.2-1.7c-2.9 .7-4.9 2.6-4.6 4.9 .3 2 2.9 3.3 5.9 2.6 2.9-.7 4.9-2.6 4.6-4.6-.3-1.9-3-3.2-5.9-2.9zM244.8 8C106.1 8 0 113.3 0 252c0 110.9 69.8 205.8 169.5 239.2 12.8 2.3 17.3-5.6 17.3-12.1 0-6.2-.3-40.4-.3-61.4 0 0-70 15-84.7-29.8 0 0-11.4-29.1-27.8-36.6 0 0-22.9-15.7 1.6-15.4 0 0 24.9 2 38.6 25.8 21.9 38.6 58.6 27.5 72.9 20.9 2.3-16 8.8-27.1 16-33.7-55.9-6.2-112.3-14.3-112.3-110.5 0-27.5 7.6-41.3 23.6-58.9-2.6-6.5-11.1-33.3 2.6-67.9 20.9-6.5 69 27 69 27 20-5.6 41.5-8.5 62.8-8.5s42.8 2.9 62.8 8.5c0 0 48.1-33.6 69-27 13.7 34.7 5.2 61.4 2.6 67.9 16 17.7 25.8 31.5 25.8 58.9 0 96.5-58.9 104.2-114.8 110.5 9.2 7.9 17 22.9 17 46.4 0 33.7-.3 75.4-.3 83.6 0 6.5 4.6 14.4 17.3 12.1C428.2 457.8 496 362.9 496 252 496 113.3 383.5 8 244.8 8zM97.2 352.9c-1.3 1-1 3.3 .7 5.2 1.6 1.6 3.9 2.3 5.2 1 1.3-1 1-3.3-.7-5.2-1.6-1.6-3.9-2.3-5.2-1zm-10.8-8.1c-.7 1.3 .3 2.9 2.3 3.9 1.6 1 3.6 .7 4.3-.7 .7-1.3-.3-2.9-2.3-3.9-2-.6-3.6-.3-4.3 .7zm32.4 35.6c-1.6 1.3-1 4.3 1.3 6.2 2.3 2.3 5.2 2.6 6.5 1 1.3-1.3 .7-4.3-1.3-6.2-2.2-2.3-5.2-2.6-6.5-1zm-11.4-14.7c-1.6 1-1.6 3.6 0 5.9 1.6 2.3 4.3 3.3 5.6 2.3 1.6-1.3 1.6-3.9 0-6.2-1.4-2.3-4-3.3-5.6-2z"/>
</symbol>
</defs>
</svg>
```
-45
View File
@@ -1,45 +0,0 @@
import { defineCollection, z } from "astro:content"
const work = defineCollection({
type: "content",
schema: z.object({
company: z.string(),
role: z.string(),
dateStart: z.coerce.date(),
dateEnd: z.union([z.coerce.date(), z.string()]),
}),
})
const blog = defineCollection({
type: "content",
schema: z.object({
title: z.string(),
summary: z.string(),
date: z.coerce.date(),
tags: z.array(z.string()),
draft: z.boolean().optional(),
}),
})
const projects = defineCollection({
type: "content",
schema: z.object({
title: z.string(),
summary: z.string(),
date: z.coerce.date(),
tags: z.array(z.string()),
draft: z.boolean().optional(),
demoUrl: z.string().optional(),
repoUrl: z.string().optional(),
}),
})
const legal = defineCollection({
type: "content",
schema: z.object({
title: z.string(),
date: z.coerce.date(),
}),
})
export const collections = { work, blog, projects, legal }
-55
View File
@@ -1,55 +0,0 @@
---
title: "Privacy Policy"
date: "08/13/2025"
---
This Privacy Policy describes how Spaghet Tech collects, uses, and protects your personal information when you use our website (https://spaghet.tech).
#### Information We Collect
When you visit our website, we may collect the following types of information:
**Non-personal Identification Information**
- Browser type and version
- Operating system
- Referring web page
- Date and time of access
- IP address (in some cases)
**Personal Identification Information**
We do not currently collect personal identification information from website visitors unless you voluntarily provide it to us through contact forms or other communication methods.
#### How We Use Your Information
We use the collected information for:
- Analyzing usage patterns to improve our website
- Enhancing user experience
- Responding to your inquiries
- Providing information about our services
#### How We Protect Your Information
We implement appropriate security measures to protect against unauthorized access to or alteration of your personal information. These include:
- Secure server technology
- Regular security updates
- Access controls and authentication
#### Sharing Your Information
We do not sell, trade, or rent your personal information to others. We may share information with trusted third parties who assist us in operating our website, conducting our business, or serving our users, so long as those parties agree to keep this information confidential.
#### Cookies
Our website uses cookies to enhance user experience and analyze site usage. You can control cookie settings through your browser preferences.
#### Third-Party Links
Our website may contain links to third-party websites. We are not responsible for the privacy practices or content of these sites.
#### Changes to This Privacy Policy
We may update our Privacy Policy from time to time. We will notify you of any changes by posting the new policy on this page with an updated effective date.
#### Contact Us
If you have any questions about this Privacy Policy, please contact us at quinn@spaghet.tech.
-46
View File
@@ -1,46 +0,0 @@
---
title: "Terms of Use"
date: "08/13/2025"
---
Please read these Terms of Use ("Terms", "Terms of Use") carefully before using the https://spaghet.tech website (the "Service") operated by Spaghet Tech ("us", "we", or "our").
#### Agreement to Terms
By accessing or using our website, you agree to be bound by these Terms of Use and all applicable laws and regulations. If you disagree with any part of these terms, you must not access the website.
#### Intellectual Property Rights
All content on this website, including text, graphics, logos, images, and software, is the property of Spaghet Tech or its licensors and is protected by intellectual property laws.
#### User Representations
By using our website, you represent that you are at least 18 years old and have the legal capacity to enter into these terms.
#### Use of Services
You may use our website for personal informational purposes only. You agree not to:
- Use the website for any unlawful purpose
- Interfere with or disrupt the website's operation
- Attempt to gain unauthorized access to our systems
- Use automated means (bots, scrapers) to access the site
#### Links to Other Websites
Our website may contain links to third-party websites. We do not endorse or assume any responsibility for the content, privacy policies, or practices of these sites.
#### Termination
We may terminate or suspend your access to our website immediately, without prior notice, if you violate these Terms of Use.
#### Governing Law
These terms shall be governed by and construed in accordance with the laws of Ohio, United States, without regard to its conflict of law provisions.
#### Changes to These Terms of Use
We may update our Terms of Use from time to time. We will notify you of any changes by posting the new terms on this page with an updated effective date.
#### Contact Us
If you have any questions about these Terms of Use, please contact us at quinn@spaghet.tech.
-25
View File
@@ -1,25 +0,0 @@
---
title: "Appwrite Integration"
summary: "Custom Appwrite implementation for backend services"
date: "Aug 2025"
draft: false
tags:
- Appwrite
- Backend
- Authentication
- Database
- API
demoUrl: https://appdev.spaghet.io/
---
Implementation of Appwrite as a backend solution for modern web applications. This project demonstrates the integration of Appwrite's comprehensive backend services including authentication, database management, file storage, and cloud functions.
Key features include:
- User authentication and authorization using Appwrite's built-in authentication system
- Database management with support for multiple document collections
- File storage and management capabilities
- Serverless functions for custom business logic
- Real-time database updates and notifications
- RESTful API integration for frontend applications
The project showcases my ability to leverage modern backend-as-a-service platforms to build scalable, secure, and maintainable applications while reducing infrastructure overhead.
@@ -1,27 +0,0 @@
---
title: "Astro Profile"
summary: "Personal portfolio website built with Astro, React, and Tailwind CSS"
date: "Aug 2025"
draft: false
tags:
- Astro
- React
- Tailwind CSS
- JavaScript
- TypeScript
demoUrl: https://home.spaghet.io
repoUrl: https://github.com/spaghetgaming/Spaghet.io
---
A modern personal portfolio website showcasing my work, projects, and technical expertise. Built with Astro for optimal performance and SEO, utilizing React components for interactive elements, and styled with Tailwind CSS for responsive design.
Features include:
- Responsive design that works across all device sizes
- Smooth animations and transitions for enhanced user experience
- Clean, modern aesthetic with dark/light mode support
- Integrated blog section for technical articles
- Project showcase with detailed descriptions
- Contact form with email integration
- SEO optimization for better search engine visibility
The site demonstrates my proficiency in modern web development practices and technologies, including component-based architecture, responsive design principles, and performance optimization techniques.
-26
View File
@@ -1,26 +0,0 @@
---
title: "Gitea Implementation"
summary: "Self-hosted Git service with continuous integration capabilities"
date: "Aug 2025"
draft: false
tags:
- Gitea
- Git
- CI/CD
- DevOps
- Docker
demoUrl: https://gitea.spaghet.io
---
Deployment and configuration of Gitea as a self-hosted Git service for version control and continuous integration. This implementation provides a comprehensive solution for managing code repositories, tracking issues, and automating development workflows.
Key features include:
- Repository management with Git-based version control
- Issue tracking and project management tools
- Continuous integration and deployment capabilities
- User authentication and access control
- Integration with Docker containers for easy deployment
- Customizable webhooks and automation scripts
- Backup and disaster recovery procedures
The project demonstrates my expertise in DevOps practices, infrastructure management, and the implementation of self-hosted solutions that provide greater control and security over development processes.
-32
View File
@@ -1,32 +0,0 @@
---
title: "Home System"
summary: "Technology as Lifestyle - Personal Docker ecosystem with 2 Unraid servers"
date: "Aug 2025"
draft: false
tags:
- Docker
- Unraid
- PostgreSQL
- MariaDB
- MongoDB
- Redis
- Minio
- Kubernetes
- Node-RED
- Authentik
- LDAP
---
Designed and maintained a scalable Docker container ecosystem supporting PostgreSQL, MariaDB, MySQL, MongoDB, Redis, and Minio for high-availability applications, ensuring robust data storage, caching, and object storage solutions.
Configured and secured authentication frameworks using Authentik, Vaultwarden, and LDAP integration, implementing zero-trust security models and access control for internal and external systems.
Deployed and supported proxy and API gateway solutions to enable secure, scalable, and customizable network infrastructure for internal and external applications.
Provided end-to-end support for 30+ users utilizing the containerized applications, including troubleshooting, configuration guidance, and documentation for tools like Zammad, and Immich.
Streamlined DevOps workflows with Node-RED, custom APIs, and automation scripts, enhancing productivity for both personal and team projects.
Maintained and optimized containerized tools for personal and organizational use, ensuring reliability, performance, and user-friendly interfaces.
Handled on-call duties for critical applications, resolving issues and minimizing downtime for users relying on the containerized ecosystem.
@@ -1,192 +0,0 @@
---
title: "Spaghet.io Website"
date: 2025-08-13
summary: "A comprehensive overview of the Spaghet.io personal website, detailing its features, design elements, and technical implementation."
tags: [website, portfolio, personal, astro, spaghetti]
draft: false
---
## Overview
Spaghet.io is my personal website that showcases my professional work, blog posts, projects, and expertise in technology and innovation. The site embodies my passion for spaghetti, noodles, and all things tech through its design and functionality.
## Key Features
### 1. Responsive Design
The website features a fully responsive design that works seamlessly across:
- Desktop browsers
- Tablets
- Mobile devices
- All screen sizes
### 2. Dark Mode Support
**Dual Theme Implementation:**
- Light mode with warm, spaghetti-themed colors
- Dark mode with complementary dark theme that maintains visual consistency
- Smooth transitions between themes
- Automatic theme detection based on system preferences
### 3. Spaghetti-Themed Color Palette
**Primary Colors:**
- **Spaghetti Yellow**: `#FDE68A` - Used for highlights and interactive elements
- **Spaghetti Red**: `#FECACA` - Used for accents and important actions
- **Spaghetti Cream**: `#FEF3C7` - Used for backgrounds and subtle elements
- **Spaghetti Brown**: `#78350F` - Used for text content and primary elements
### 4. Interactive UI Components
**Navigation Elements:**
- Fixed header with smooth scrolling
- Mobile-friendly drawer navigation
- Hover effects with color transitions
- Selected state indicators with consistent theme colors
**Content Presentation:**
- Blog post cards with hover animations
- Project showcase with filtering capabilities
- Tag-based organization system
- Responsive tables and lists
### 5. Technical Implementation
**Built With:**
- **Astro**: Static site generator for optimal performance
- **SolidJS**: For reactive UI components
- **Tailwind CSS**: Utility-first CSS framework
- **TypeScript**: Type safety and enhanced development experience
- **Markdown**: Content management system
### 6. Performance Optimizations
**Optimizations Implemented:**
- Lazy loading of images and components
- Efficient CSS with minimal bundle size
- Optimized JavaScript with tree-shaking
- Responsive image handling
- Minimal third-party dependencies
## UI Components
### Header & Navigation
- Fixed position header with brand logo
- Desktop navigation with hover effects
- Mobile drawer menu with hamburger icon
- Search functionality
- Theme toggle button
### Hero Section
- Animated background elements
- Welcome message with personal introduction
- Call-to-action buttons styled with spaghetti theme
- Responsive text sizing for all devices
### Blog Section
- Recent posts preview
- Filterable by tags
- Card-based layout with hover effects
- Date formatting and categorization
### Projects Section
- Project showcase with filtering capabilities
- Tag-based organization system
- Responsive grid layout
- Detailed project cards with descriptions
### Footer
- Copyright information with current year
- Legal links (Privacy Policy, Terms of Service)
- Social media integration
- Consistent spaghetti-themed styling
## Design Elements
### Visual Theme
The website maintains a consistent spaghetti theme throughout:
- Warm color scheme that evokes feelings of comfort and satisfaction
- Clean, organized layout that mirrors the structure of good spaghetti
- Subtle animations and transitions for enhanced user experience
- Proper contrast ratios for accessibility
### Typography
- Clear hierarchy with appropriate font weights
- Responsive text sizing
- Consistent spacing and alignment
- Readable fonts optimized for both light and dark modes
### Layout Structure
- Grid-based responsive layout
- Consistent padding and margins
- Visual balance across all sections
- Proper use of white space
## Technical Architecture
### Component Structure
The site uses a modular component architecture:
- **Header** - Navigation and branding
- **Footer** - Site information and links
- **Blog** - Content display with filtering
- **Projects** - Portfolio showcase
- **ArrowCard** - Generic card component for content
- **StackCard** - Technology stack display
- **Search** - Search functionality
### Theme System
The theme system supports:
- CSS variables for consistent color management
- Dark mode detection and switching
- Theme persistence across sessions
- Smooth transitions between themes
### Content Management
Content is managed through:
- Markdown files for blog posts and projects
- Astro's content collections
- Frontmatter metadata for categorization
- Template-based generation system
## Responsive Features
### Mobile Experience
- Touch-friendly navigation elements
- Optimized touch targets
- Collapsible sections for smaller screens
- Performance optimized for mobile devices
### Tablet Experience
- Adaptive layout adjustments
- Intermediate view sizes
- Maintained usability across screen sizes
### Desktop Experience
- Full-width content presentation
- Advanced hover effects and animations
- Multi-column layouts where appropriate
## Accessibility
The website includes accessibility features:
- Semantic HTML structure
- Proper contrast ratios for text
- Keyboard navigation support
- Screen reader compatibility
- Responsive design for all devices
## Future Enhancements
Potential future improvements include:
1. Enhanced animation system with more sophisticated transitions
2. Additional interactive elements that reflect the spaghetti theme
3. More advanced filtering and search capabilities
4. Integration with external APIs for dynamic content
5. Expanded multimedia presentation options
6. Improved social sharing features
## Conclusion
Spaghet.io represents a cohesive blend of technical excellence and thematic consistency. The site successfully combines modern web technologies with a playful yet professional spaghetti-themed aesthetic to create an engaging user experience that reflects my passion for both technology and culinary arts.
The implementation maintains the structure and organization that makes good spaghetti satisfying to use, while providing an enjoyable browsing experience across all devices and themes.
@@ -1,16 +0,0 @@
---
title: "Project One"
summary: "Lorem ipsum dolor sit amet"
date: "Mar 18 2022"
draft: true
tags:
- Astro
- Javascript
- Typescript
- Tailwind
- SolidJs
demoUrl: https://astro-sphere-demo.vercel.app
repoUrl: https://github.com/markhorn-dev/astro-sphere
---
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Vitae ultricies leo integer malesuada nunc vel risus commodo viverra. Adipiscing enim eu turpis egestas pretium. Euismod elementum nisi quis eleifend quam adipiscing. In hac habitasse platea dictumst vestibulum. Sagittis purus sit amet volutpat. Netus et malesuada fames ac turpis egestas. Eget magna fermentum iaculis eu non diam phasellus vestibulum lorem. Varius sit amet mattis vulputate enim. Habitasse platea dictumst quisque sagittis. Integer quis auctor elit sed vulputate mi. Dictumst quisque sagittis purus sit amet.
@@ -1,15 +0,0 @@
---
title: "Project Two"
summary: "Lorem ipsum dolor sit amet"
date: "Mar 17 2022"
draft: true
tags:
- Svelte
- Sveltekit
- Typescript
- Tailwind
---
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Vitae ultricies leo integer malesuada nunc vel risus commodo viverra. Adipiscing enim eu turpis egestas pretium. Euismod elementum nisi quis eleifend quam adipiscing. In hac habitasse platea dictumst vestibulum. Sagittis purus sit amet volutpat. Netus et malesuada fames ac turpis egestas. Eget magna fermentum iaculis eu non diam phasellus vestibulum lorem. Varius sit amet mattis vulputate enim. Habitasse platea dictumst quisque sagittis. Integer quis auctor elit sed vulputate mi. Dictumst quisque sagittis purus sit amet.
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Vitae ultricies leo integer malesuada nunc vel risus commodo viverra. Adipiscing enim eu turpis egestas pretium. Euismod elementum nisi quis eleifend quam adipiscing. In hac habitasse platea dictumst vestibulum. Sagittis purus sit amet volutpat. Netus et malesuada fames ac turpis egestas. Eget magna fermentum iaculis eu non diam phasellus vestibulum lorem. Varius sit amet mattis vulputate enim. Habitasse platea dictumst quisque sagittis. Integer quis auctor elit sed vulputate mi. Dictumst quisque sagittis purus sit amet.
@@ -1,12 +0,0 @@
---
title: "Project Three"
summary: "Lorem ipsum dolor sit amet"
date: "Mar 16 2022"
draft: true
tags:
- Vue
- Javascript
- Tailwind
---
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Vitae ultricies leo integer malesuada nunc vel risus commodo viverra. Adipiscing enim eu turpis egestas pretium. Euismod elementum nisi quis eleifend quam adipiscing. In hac habitasse platea dictumst vestibulum. Sagittis purus sit amet volutpat. Netus et malesuada fames ac turpis egestas. Eget magna fermentum iaculis eu non diam phasellus vestibulum lorem. Varius sit amet mattis vulputate enim. Habitasse platea dictumst quisque sagittis. Integer quis auctor elit sed vulputate mi. Dictumst quisque sagittis purus sit amet.
@@ -1,31 +0,0 @@
---
title: "Project Four"
summary: "Lorem ipsum dolor sit amet"
date: "Mar 15 2022"
draft: true
tags:
- React
- Javascript
- StyleX
---
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Vitae ultricies leo integer malesuada nunc vel risus commodo viverra. Adipiscing enim eu turpis egestas pretium.
Euismod elementum nisi quis eleifend quam adipiscing. In hac habitasse platea dictumst vestibulum. Sagittis purus sit amet volutpat. Netus et malesuada fames ac turpis egestas.
Eget magna fermentum iaculis eu non diam phasellus vestibulum lorem.
Varius sit amet mattis vulputate enim. Habitasse platea dictumst quisque sagittis. Integer quis auctor elit sed vulputate mi. Dictumst quisque sagittis purus sit amet.
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Vitae ultricies leo integer malesuada nunc vel risus commodo viverra. Adipiscing enim eu turpis egestas pretium.
Euismod elementum nisi quis eleifend quam adipiscing. In hac habitasse platea dictumst vestibulum. Sagittis purus sit amet volutpat. Netus et malesuada fames ac turpis egestas.
Eget magna fermentum iaculis eu non diam phasellus vestibulum lorem.
Varius sit amet mattis vulputate enim. Habitasse platea dictumst quisque sagittis. Integer quis auctor elit sed vulputate mi. Dictumst quisque sagittis purus sit amet.
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Vitae ultricies leo integer malesuada nunc vel risus commodo viverra. Adipiscing enim eu turpis egestas pretium.
Euismod elementum nisi quis eleifend quam adipiscing. In hac habitasse platea dictumst vestibulum. Sagittis purus sit amet volutpat. Netus et malesuada fames ac turpis egestas.
Eget magna fermentum iaculis eu non diam phasellus vestibulum lorem.
Varius sit amet mattis vulputate enim. Habitasse platea dictumst quisque sagittis. Integer quis auctor elit sed vulputate mi. Dictumst quisque sagittis purus sit amet.
-16
View File
@@ -1,16 +0,0 @@
---
company: "Amazon"
role: "Area Manager"
dateStart: "03/01/2010"
dateEnd: "10/01/2014"
---
Monitored associate productivity metrics and resolved performance barriers.
Conducted training sessions for peers and leadership on new fulfillment tech tools.
Empowered direct reports to enforce safety, quality, and productivity standards.
Recruited top talent for individual contributors to boost team success.
Led cross-functional teams to implement processes improving operational efficiency in North America.
-14
View File
@@ -1,14 +0,0 @@
---
company: "CareWorks Tech"
role: "ServiceNow Developer"
dateStart: "06/01/2016"
dateEnd: "09/01/2017"
---
Experienced ServiceNow developer with expertise in IT Service Management platforms.
Skilled in implementing and customizing ServiceNow solutions for enterprise clients.
Knowledge of ITSM frameworks including INC, PRG, CHG, ESC to support business operations.
Proficient in configuring and maintaining ServiceNow applications to meet client requirements.
-22
View File
@@ -1,22 +0,0 @@
---
company: "Clear Skye"
role: "Technical Architect"
dateStart: "03/01/2022"
dateEnd: "05/01/2023"
---
Proficient in ServiceNow Identity Governance modules (e.g., IdentityIQ, ClearSkye IGA) for designing, configuring, and optimizing workflows for access management, entitlements, and compliance.
Expertise in AWS, Azure, GCP to build scalable, secure, and compliant identity governance architectures for hybrid/multi-cloud environments.
Experience with REST, SOAP, and middleware tools to integrate ClearSkye IGA with identity providers (SAML, OAuth), HR systems, and enterprise apps for seamless data flow.
Knowledge of GDPR, SOC2, ISO 27001, and NIST frameworks to design secure IGA solutions with access controls, audit trails, and regulatory alignment.
Skilled in automating deployment pipelines, IaC (Terraform, CloudFormation), and monitoring tools (Prometheus) to ensure reliable IGA system updates.
Expertise in designing data privacy frameworks, managing user data lifecycle, and leveraging analytics for risk assessments, entitlement audits, and access insights.
Proven ability to collaborate with IT ops, security teams, and business stakeholders to translate governance requirements into technical solutions.
Ability to resolve complex IGA challenges (e.g., entitlement conflicts, access delays) and adapt architectures to evolving compliance, user, and tech trends.
-14
View File
@@ -1,14 +0,0 @@
---
company: "Computer Aid, Inc."
role: "Technical Consultant"
dateStart: "07/01/2019"
dateEnd: "07/01/2021"
---
Technical Consultant for ServiceNow practice with expertise in IT Service Management platforms.
Deep knowledge of ITSM (e.g., INC, PRG, CHG, ESC) and related frameworks to support enterprise clients.
Experience in implementing and optimizing ServiceNow solutions for various business needs.
Strong ability to translate technical requirements into business value for clients.
-8
View File
@@ -1,8 +0,0 @@
---
company: "National Guard Bureau"
role: "Chaplain Assistant"
dateStart: "12/01/2007"
dateEnd: "12/01/2012"
---
Support role within the National Guard Bureau focused on chaplain services and community outreach.
-18
View File
@@ -1,18 +0,0 @@
---
company: "Neoteric Technologies"
role: "Sr. Cloud Architect"
dateStart: "03/01/2021"
dateEnd: "01/01/2022"
---
Results-driven technical leader with deep expertise in cloud architecture and infrastructure design.
Extensive experience in designing scalable, secure, and compliant identity governance architectures for hybrid/multi-cloud environments.
Proficient in AWS, Azure, and GCP platforms to build robust cloud solutions.
Skilled in automating deployment pipelines and implementing Infrastructure as Code (IaC) using tools like Terraform and CloudFormation.
Experience with monitoring tools to ensure reliable system updates and performance optimization.
Knowledge of security frameworks and compliance standards to design secure cloud solutions.
-22
View File
@@ -1,22 +0,0 @@
---
company: "Spaghet Tech"
role: "Creator"
dateStart: "05/01/2023"
dateEnd: ""
---
Deep knowledge of ITSM (e.g., INC, PRB, CHG, ESC, etc.), ITOM (e.g., CMDB, ACC, CertDisc, etc.), and ITAM (e.g., SAM, HAM) to position myself as a trusted advisor.
Proven ability to connect with decision-makers in industries (e.g., healthcare, enterprise services) through professional platforms, conferences, or referrals to secure long-term partnerships.
Skilled in translating technical services (e.g., instance data replication, M365 integration) into business value, ensuring alignment with client goals and fostering trust.
Financial acumen to balance market rates, project scope, and client budgets while offering flexible pricing models (e.g., hourly vs. project-based) to secure work.
Hands-on experience with tools like Docker, Kubernetes, and ITSM/ITOM platforms to deliver scalable, secure, and compliant solutions (e.g., Archiving, Certificate Discovery, CMDB steering).
Ability to coordinate cross-functional teams, manage timelines, and ensure successful delivery of complex projects (e.g., Employee Center Migrations, IDR for global instances).
Quick thinking to address challenges like data replication gaps, integration hurdles, or user support needs for 30+ users, while maintaining system reliability.
Strong customer service skills to provide ongoing support, troubleshoot issues, and retain clients (e.g., maintaining 30+ user satisfaction through proactive documentation and on-call maintenance).
-14
View File
@@ -1,14 +0,0 @@
---
company: "TriMedx"
role: "Senior Software Engineer"
dateStart: "09/01/2017"
dateEnd: "07/01/2019"
---
Experienced software engineer with focus on delivering fast, elegant code along with delightful user interfaces.
Proficient in web technologies including JavaScript, HTML, CSS, React, AngularJS, and Angular.
Strong background in developing marketing and ecommerce websites to complex enterprise applications.
Dedicated to creating functional and aesthetically pleasing digital solutions.
-20
View File
@@ -1,20 +0,0 @@
---
company: "zulily"
role: "Technical Change Manager"
dateStart: "10/01/2014"
dateEnd: "06/01/2016"
---
Designed and maintained internal tools for Fulfillment Center (FC) Operations, including:
Weekly performance monitoring systems with actionable feedback for employee development and recognition.
Employee recognition program to incentivize performance.
Supplies inventory management system (e.g., Corrugated Boxes, Tape, Bubble Wrap) for tracking usage and movement.
Employee kiosks for Overtime sign-ups, Voluntary-Time-Off, Department Transfers, and peer recognition.
Dock Management System to streamline trailer tracking for transportation vendors.
Tested and approved deployments of Fulfillment Center Systems (FCS) tools for fulfillment tasks (e.g., Receive, Stow, Pick, Pack).
Documented and prioritized feature requests, improvements, and bug fixes from FC Operations, managing Agile sprints with weekly and biweekly check-ins to ensure project alignment.
Led operational process improvements to enhance efficiency, scalability, and overall FC operations performance.
+78 -41
View File
@@ -1,58 +1,95 @@
--- ---
import { type CollectionEntry, getCollection } from "astro:content" import type { BlogPost, Project } from "@lib/appwrite-service"
import { getBlogPosts, getProjects } from "@lib/appwrite-service"
type Props = { type Props = {
entry: CollectionEntry<"blog"> | CollectionEntry<"projects"> entry: BlogPost | Project | any
} }
// Get the requested entry
const { entry } = Astro.props const { entry } = Astro.props
const { collection } = entry const collection = entry.$collectionId === process.env.VITE_APPWRITE_BLOG_COLLECTION_ID ? 'blog' : 'projects'
const { Content } = await entry.render()
// Get the next and prev entries (modulo to wrap index) // Get the content from the entry
const items = (await getCollection(collection)) const content = entry.contentHtml
.filter(post => !post.data.draft)
.sort((a, b) => b.data.date.getTime() - a.data.date.getTime()) // Fetch all documents for navigation
const index = items.findIndex(x => x.slug === entry.slug) let prevEntry = null
const prev = items[(index - 1 + items.length) % items.length] let nextEntry = null
const next = items[(index + 1) % items.length]
if (collection === "blog") {
const blogPosts = await getBlogPosts()
// Sort by date descending to get newest first
const sortedPosts = blogPosts.sort((a, b) => new Date(b.date).getTime() - new Date(a.date).getTime())
// Find current post index
const currentIndex = sortedPosts.findIndex(post => post.$id === entry.$id)
if (currentIndex > 0) {
prevEntry = sortedPosts[currentIndex - 1]
}
if (currentIndex < sortedPosts.length - 1) {
nextEntry = sortedPosts[currentIndex + 1]
}
} else if (collection === "projects") {
const projects = await getProjects()
// Sort by date descending to get newest first
const sortedProjects = projects.sort((a, b) => new Date(b.date).getTime() - new Date(a.date).getTime())
// Find current project index
const currentIndex = sortedProjects.findIndex(project => project.$id === entry.$id)
if (currentIndex > 0) {
prevEntry = sortedProjects[currentIndex - 1]
}
if (currentIndex < sortedProjects.length - 1) {
nextEntry = sortedProjects[currentIndex + 1]
}
}
--- ---
<div> <div>
<article> <article class="text-spaghetti-brown/80 dark:text-spaghetti-cream" set:html={content} />
<Content/>
</article>
<div class="grid grid-cols-1 sm:grid-cols-2 gap-4"> <div class="grid grid-cols-1 sm:grid-cols-2 gap-4">
<a href={`/${prev.collection}/${prev.slug}`} class="group p-4 gap-3 flex items-center border rounded-lg hover:bg-black/5 hover:dark:bg-white/10 border-black/15 dark:border-white/20 blend"> {prevEntry && (
<div class="order-2 w-full h-full group-hover:text-black group-hover:dark:text-white blend"> <a href={`/${collection}/${prevEntry.$id}`} class="group p-4 gap-3 flex items-center border rounded-lg hover:bg-black/5 hover:dark:bg-spaghetti-cream/10 border-black/15 dark:border-spaghetti-cream/20 blend">
<div class="flex flex-wrap gap-2"> <div class="order-2 w-full h-full group-hover:text-spaghetti-brown/80 group-hover:dark:text-spaghetti-cream blend">
<div class="text-sm uppercase"> <div class="flex flex-wrap gap-2">
Prev <div class="text-sm uppercase">
Prev
</div>
</div>
<div class="font-semibold mt-3 text-spaghetti-brown/80 dark:text-spaghetti-cream">
{prevEntry.title}
</div> </div>
</div> </div>
<div class="font-semibold mt-3 text-black dark:text-white"> <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round" class="order-1 stroke-current group-hover:stroke-black group-hover:dark:stroke-white rotate-180">
{prev.data.title} <line x1="5" y1="12" x2="19" y2="12" class="scale-x-0 group-hover:scale-x-100 translate-x-4 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
<polyline points="12 5 19 12 12 19" class="translate-x-0 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
</svg>
</a>
)}
{nextEntry && (
<a href={`/${collection}/${nextEntry.$id}`} class="group p-4 gap-3 flex items-center border rounded-lg hover:bg-black/5 hover:dark:bg-spaghetti-cream/10 border-black/15 dark:border-spaghetti-cream/20 transition-colors duration-300 ease-in-out blend dark:text-spaghetti-cream">
<div class="w-full h-full text-right group-hover:text-spaghetti-brown/80 group-hover:dark:text-spaghetti-cream blend">
<div class="text-sm uppercase">
Next
</div>
<div class="font-semibold mt-3 text-spaghetti-brown/80 dark:text-spaghetti-cream">
{nextEntry.title}
</div>
</div> </div>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round" class="stroke-current group-hover:stroke-black group-hover:dark:stroke-white blend">
<line x1="5" y1="12" x2="19" y2="12" class="scale-x-0 group-hover:scale-x-100 translate-x-4 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
<polyline points="12 5 19 12 12 19" class="translate-x-0 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
</svg>
</a>
)}
{!prevEntry && !nextEntry && (
<div class="col-span-2 text-center py-8 text-gray-500 blend">
No adjacent articles available
</div> </div>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round" class="order-1 stroke-current group-hover:stroke-black group-hover:dark:stroke-white rotate-180"> )}
<line x1="5" y1="12" x2="19" y2="12" class="scale-x-0 group-hover:scale-x-100 translate-x-4 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
<polyline points="12 5 19 12 12 19" class="translate-x-0 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
</svg>
</a>
<a href={`/${next.collection}/${next.slug}`} class="group p-4 gap-3 flex items-center border rounded-lg hover:bg-black/5 hover:dark:bg-white/10 border-black/15 dark:border-white/20 transition-colors duration-300 ease-in-out">
<div class="w-full h-full text-right group-hover:text-black group-hover:dark:text-white blend">
<div class="text-sm uppercase">
Next
</div>
<div class="font-semibold mt-3 text-black dark:text-white">
{next.data.title}
</div>
</div>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round" class="stroke-current group-hover:stroke-black group-hover:dark:stroke-white">
<line x1="5" y1="12" x2="19" y2="12" class="scale-x-0 group-hover:scale-x-100 translate-x-4 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
<polyline points="12 5 19 12 12 19" class="translate-x-0 group-hover:translate-x-1 transition-all duration-300 ease-in-out" />
</svg>
</a>
</div> </div>
</div> </div>
+13 -12
View File
@@ -1,27 +1,28 @@
--- ---
import type { CollectionEntry } from "astro:content" import type { BlogPost, Project } from "@lib/appwrite-service"
import { formatDate, readingTime } from "@lib/utils" import { formatDate, readingTime } from "@lib/utils"
type Props = { type Props = {
entry: CollectionEntry<"projects"> | CollectionEntry<"blog"> entry: BlogPost | Project | any
} }
const { entry } = Astro.props const { entry } = Astro.props
const { collection, data, body } = entry const { title, summary, date } = entry
const { title, summary, date } = data const demoUrl = "demoUrl" in entry ? entry.demoUrl : null
const repoUrl = "repoUrl" in entry ? entry.repoUrl : null
const collection = entry.$collectionId === process.env.VITE_APPWRITE_BLOG_COLLECTION_ID ? 'blog' : 'projects'
const body = entry.content
const demoUrl = collection === "projects" ? data.demoUrl : null
const repoUrl = collection === "projects" ? data.repoUrl : null
--- ---
<div> <div>
<a href={`/${collection}`} class="group w-fit p-1.5 gap-1.5 text-sm flex items-center border rounded hover:bg-black/5 hover:dark:bg-white/10 border-black/15 dark:border-white/20 transition-colors duration-300 ease-in-out"> <a href={`/${collection}`} class="group w-fit p-1.5 gap-1.5 text-sm flex items-center border text-spaghetti-brown/100 dark:text-spaghetti-yellow rounded hover:bg-spaghetti-brown/5 hover:dark:bg-spaghetti-red/10 border-spaghetti-brown/15 dark:border-spaghetti-cream/20 transition-colors duration-300 ease-in-out">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round" class="stroke-current group-hover:stroke-black group-hover:dark:stroke-white"> <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round" class="stroke-current group-hover:stroke-spaghetti-brown group-hover:dark:stroke-spaghetti-yellow">
<line x1="19" y1="12" x2="5" y2="12" class="scale-x-0 group-hover:scale-x-100 translate-x-3 group-hover:translate-x-0 transition-all duration-300 ease-in-out" /> <line x1="19" y1="12" x2="5" y2="12" class="scale-x-0 group-hover:scale-x-100 translate-x-3 group-hover:translate-x-0 transition-all duration-300 ease-in-out" />
<polyline points="12 19 5 12 12 5" class="translate-x-1 group-hover:translate-x-0 transition-all duration-300 ease-in-out" /> <polyline points="12 19 5 12 12 5" class="translate-x-1 group-hover:translate-x-0 transition-all duration-300 ease-in-out" />
</svg> </svg>
<div class="w-full group-hover:text-black group-hover:dark:text-white transition-colors duration-300 ease-in-out"> <div class="w-full group-hover:text-spaghetti-brown group-hover:dark:text-spaghetti-yellow transition-colors duration-300 ease-in-out">
Back to {collection} Back to {`${collection.charAt(0).toUpperCase()}${collection.slice(1)}`}
</div> </div>
</a> </a>
<div class="flex flex-wrap text-sm uppercase mt-12 gap-3 opacity-75"> <div class="flex flex-wrap text-sm uppercase mt-12 gap-3 opacity-75">
@@ -38,10 +39,10 @@ const repoUrl = collection === "projects" ? data.repoUrl : null
{readingTime(body)} {readingTime(body)}
</div> </div>
</div> </div>
<h1 class="text-3xl font-semibold text-spaghetti-brown dark:text-spaghetti-brown mt-2"> <h1 class="text-3xl font-semibold text-spaghetti-brown/100 dark:text-spaghetti-cream mt-2">
{title} {title}
</h1> </h1>
<div class="mt-1 text-spaghetti-brown dark:text-spaghetti-brown"> <div class="mt-1 text-spaghetti-brown/80 dark:text-spaghetti-cream">
{summary} {summary}
</div> </div>
{(demoUrl || repoUrl) && {(demoUrl || repoUrl) &&
@@ -0,0 +1,80 @@
import { describe, it, expect } from 'vitest';
import { getBlogPosts, getProjects, getWorkExperiences, getLegalDocuments } from '../appwrite-service';
describe('AppWrite Service', () => {
describe('getBlogPosts', () => {
it('should return an array of blog posts', async () => {
const posts = await getBlogPosts();
expect(Array.isArray(posts)).toBe(true);
expect(posts.length).toBeGreaterThan(0);
// Check that each post has the expected properties
posts.forEach((post) => {
expect(post).toHaveProperty('title');
expect(post).toHaveProperty('summary');
expect(post).toHaveProperty('date');
expect(post).toHaveProperty('tags');
expect(post).toHaveProperty('draft');
expect(post).toHaveProperty('content');
expect(post).toHaveProperty('template');
expect(post).toHaveProperty('featured');
});
});
});
describe('getProjects', () => {
it('should return an array of projects', async () => {
const projects = await getProjects();
expect(Array.isArray(projects)).toBe(true);
expect(projects.length).toBeGreaterThan(0);
// Check that each project has the expected properties
projects.forEach((project) => {
expect(project).toHaveProperty('title');
expect(project).toHaveProperty('summary');
expect(project).toHaveProperty('date');
expect(project).toHaveProperty('tags');
expect(project).toHaveProperty('draft');
expect(project).toHaveProperty('content');
expect(project).toHaveProperty('demoUrl');
expect(project).toHaveProperty('repoUrl');
});
});
});
describe('getWorkExperiences', () => {
it('should return an array of work experiences', async () => {
const workExperiences = await getWorkExperiences();
expect(Array.isArray(workExperiences)).toBe(true);
expect(workExperiences.length).toBeGreaterThan(0);
// Check that each work experience has the expected properties
workExperiences.forEach((work) => {
expect(work).toHaveProperty('company');
expect(work).toHaveProperty('role');
expect(work).toHaveProperty('dateStart');
expect(work).toHaveProperty('content');
expect(work).toHaveProperty('dateEnd');
});
});
});
describe('getLegalDocuments', () => {
it('should return an array of legal documents', async () => {
const legalDocuments = await getLegalDocuments();
expect(Array.isArray(legalDocuments)).toBe(true);
expect(legalDocuments.length).toBeGreaterThan(0);
// Check that each legal document has the expected properties
legalDocuments.forEach((doc) => {
expect(doc).toHaveProperty('title');
expect(doc).toHaveProperty('date');
expect(doc).toHaveProperty('content');
});
});
});
});
+396
View File
@@ -0,0 +1,396 @@
import type { Models, } from "appwrite";
import { Query } from "appwrite";
import { databases, } from "./appwrite"; // Import the already initialized databases instances
import { remark } from "remark";
import remarkRehype from "remark-rehype";
import rehypeStringify from "rehype-stringify";
// We're using the storage instance from appwrite.ts which is properly initialized
// This file only contains service functions and types
/**
* Convert markdown content to HTML
*/
export function convertMarkdownToHTML(markdown: string): string {
if (!markdown) return "";
try {
const file = remark()
.use(remarkRehype)
.use(rehypeStringify)
.processSync(markdown);
return file.toString();
} catch (error) {
console.error("Error converting markdown to HTML:", error);
return markdown; // Return raw markdown if conversion fails
}
}
// Types for our collections
export type BlogPost = Models.Document & {
title: string;
summary: string;
date: Date;
tags: string[];
draft: boolean;
content: string;
contentHtml?: string; // HTML version of the content
image?: string; // File ID for the featured image
template: string; // e.g., "default", "feature", "news"
featured: boolean;
};
export type Project = Models.Document & {
title: string;
summary: string;
date: Date;
tags: string[];
draft: boolean;
demoUrl?: string;
repoUrl?: string;
content: string;
contentHtml?: string; // HTML version of the content
image?: string; // File ID for the featured image
};
export type WorkExperience = Models.Document & {
company: string;
role: string;
dateStart: Date;
content: string;
contentHtml?: string; // HTML version of the content
dateEnd: Date | string;
};
export type LegalDocument = Models.Document & {
title: string;
date: Date;
content: string;
contentHtml?: string; // HTML version of the content
};
// Define a unified type for search results
export type SearchEntry = BlogPost | Project;
// Collection IDs - these should be configured based on your Appwrite setup
let blogCollection = '', projectsCollection = '', workCollection = '', legalCollection = '', databaseID = '';
// Check if we're in a server environment (SSR)
if (typeof window === 'undefined') {
// Server-side: use environment variables directly
blogCollection = process?.env?.VITE_APPWRITE_BLOG_COLLECTION_ID || 'blog';
projectsCollection = process?.env?.VITE_APPWRITE_PROJECTS_COLLECTION_ID || "projects";
workCollection = process?.env?.VITE_APPWRITE_WORK_COLLECTION_ID || "work";
legalCollection = process?.env?.VITE_APPWRITE_LEGAL_COLLECTION_ID || "legal";
databaseID = process.env.VITE_APPWRITE_DATABASE_ID || "main";
} else {
blogCollection = import.meta.env.PUBLIC_APPWRITE_BLOG_COLLECTION_ID || 'blog';
projectsCollection = import.meta.env.PUBLIC_APPWRITE_PROJECTS_COLLECTION_ID || "projects";
workCollection = import.meta.env.PUBLIC_APPwrite_WORK_COLLECTION_ID || "work";
legalCollection = import.meta.env.PUBLIC_APPWRITE_LEGAL_COLLECTION_ID || "legal";
databaseID = import.meta.env.PUBLIC_APPWRITE_DATABASE_ID || "main";
}
/**
* Get blog posts from Appwrite database
*/
export async function getBlogPosts(): Promise<BlogPost[]> {
try {
const response = await databases.listDocuments<BlogPost>(
databaseID,
blogCollection
);
// Convert markdown content to HTML for each post
const postsWithHtml = response.documents.map(post => ({
...post,
contentHtml: convertMarkdownToHTML(post.content)
}));
return postsWithHtml;
} catch (error) {
console.error("Error fetching blog posts:", error);
throw new Error("Failed to fetch blog posts");
}
}
/**
* Get paginated blog posts from Appwrite database
*/
export async function getBlogPostsPaginated(page: number, limit: number): Promise<{ posts: BlogPost[], total: number }> {
try {
// For Appwrite SDK, the correct way to call listDocuments with pagination
const response = await databases.listDocuments<BlogPost>(
databaseID,
blogCollection,
[
// Only fetch published posts (not drafts)
Query.equal("draft", false),
Query.orderDesc('date')
]
);
// Apply pagination manually since Appwrite SDK might not support offset/limit directly in this version
const paginatedPosts = response.documents.slice((page - 1) * limit, page * limit);
// Convert markdown content to HTML for each post
const postsWithHtml = paginatedPosts.map(post => ({
...post,
contentHtml: convertMarkdownToHTML(post.content)
}));
return {
posts: postsWithHtml,
total: response.total
};
} catch (error) {
console.error("Error fetching paginated blog posts:", error);
throw new Error("Failed to fetch paginated blog posts");
}
}
/**
* Get a specific blog post by ID
*/
export async function getBlogPostById(id: string): Promise<BlogPost> {
try {
const response = await databases.getDocument<BlogPost>(
databaseID,
blogCollection,
id
);
// Convert markdown content to HTML
return {
...response,
contentHtml: convertMarkdownToHTML(response.content)
};
} catch (error) {
console.error("Error fetching blog post:", error);
throw new Error("Failed to fetch blog post");
}
}
/**
* Get projects from Appwrite database
*/
export async function getProjects(): Promise<Project[]> {
try {
const response = await databases.listDocuments<Project>(
databaseID,
projectsCollection,
[
// Only fetch published projects (not drafts)
Query.equal("draft", false),
Query.orderDesc('date')
]
);
// Convert markdown content to HTML for each project
const projectsWithHtml = response.documents.map(project => ({
...project,
contentHtml: convertMarkdownToHTML(project.content)
}));
return projectsWithHtml;
} catch (error) {
console.error("Error fetching projects:", error);
throw new Error("Failed to fetch projects");
}
}
/**
* Get paginated projects from Appwrite database
*/
export async function getProjectsPaginated(page: number, limit: number): Promise<{ posts: Project[], total: number }> {
try {
const response = await databases.listDocuments<Project>(
databaseID,
projectsCollection,
[
// Only fetch published projects (not drafts)
Query.equal("draft", false),
Query.orderDesc('date')
]
);
// Apply pagination manually since Appwrite SDK might not support offset/limit directly in this version
const paginatedPosts = response.documents.slice((page - 1) * limit, page * limit);
// Convert markdown content to HTML for each project
const projectsWithHtml = paginatedPosts.map(project => ({
...project,
contentHtml: convertMarkdownToHTML(project.content)
}));
return {
posts: projectsWithHtml,
total: response.total
};
} catch (error) {
console.error("Error fetching paginated projects:", error);
throw new Error("Failed to fetch paginated projects");
}
}
/**
* Get a specific project by ID
*/
export async function getProjectById(id: string): Promise<Project> {
try {
const response = await databases.getDocument<Project>(
databaseID,
projectsCollection,
id
);
// Convert markdown content to HTML
return {
...response,
contentHtml: convertMarkdownToHTML(response.content)
};
} catch (error) {
console.error("Error fetching project:", error);
throw new Error("Failed to fetch project");
}
}
/**
* Get work experiences from Appwrite database
*/
export async function getWorkExperiences(): Promise<WorkExperience[]> {
try {
const response = await databases.listDocuments<WorkExperience>(
databaseID,
workCollection
);
// Convert markdown content to HTML for each project
return response.documents.map(work => ({
...work,
contentHtml: convertMarkdownToHTML(work.content)
}));
} catch (error) {
console.error("Error fetching work experiences:", error);
throw new Error("Failed to fetch work experiences");
}
}
/**
* Get legal documents from Appwrite database
*/
export async function getLegalDocuments(): Promise<LegalDocument[]> {
try {
const response = await databases.listDocuments<LegalDocument>(
databaseID,
legalCollection
);
return response.documents;
} catch (error) {
console.error("Error fetching legal documents:", error);
throw new Error("Failed to fetch legal documents");
}
}
/**
* Perform a search across blog posts and projects using Appwrite SDK
*/
export async function searchContent(query: string): Promise<{ posts: BlogPost[], projects: Project[] }> {
try {
// Search in blog collection for the query term
const blogResponse = await databases.listDocuments<BlogPost>(
databaseID,
blogCollection,
[
Query.and([
Query.equal("draft", false),
Query.or([
Query.search("title", query),
Query.search("summary", query),
Query.search("content", query)
])
]),
Query.orderDesc('date')
]
);
// Search in projects collection for the query term
const projectResponse = await databases.listDocuments<Project>(
databaseID,
projectsCollection,
[
Query.and([
Query.equal("draft", false),
Query.or([
Query.search("title", query),
Query.search("summary", query),
Query.search("content", query)
])
]),
Query.orderDesc('date')
]
);
// Convert markdown content to HTML for blog posts
const blogPostsWithHtml = blogResponse.documents.map(post => ({
...post,
contentHtml: convertMarkdownToHTML(post.content)
}));
// Convert markdown content to HTML for projects
const projectsWithHtml = projectResponse.documents.map(project => ({
...project,
contentHtml: convertMarkdownToHTML(project.content)
}));
return {
posts: blogPostsWithHtml,
projects: projectsWithHtml
};
} catch (error) {
console.error("Error performing search:", error);
// More specific error handling for Appwrite errors
if (error instanceof Error) {
throw new Error(`Search failed: ${error.message}`);
}
throw new Error("Search failed due to an unknown error");
}
}
// Remove the duplicate function - keep only the original searchContent function
// The original searchContent function is already correctly implemented and should be used
/**
* Get a public URL for a file
*/
export function getFileUrl(bucketId: string, fileId: string): string {
return `${process.env.VITE_APPWRITE_ENDPOINT}/storage/buckets/${bucketId}/files/${fileId}/view?project=${process.env.VITE_APPWRITE_PROJECT_ID}`;
}
/**
* Get a preview URL for a file (thumb or preview)
*/
export function getFilePreviewUrl(bucketId: string, fileId: string, type: "thumb" | "preview"): string {
return `${process.env.VITE_APPWRITE_ENDPOINT}/storage/buckets/${bucketId}/files/${fileId}/view?project=${process.env.VITE_APPWRITE_PROJECT_ID}&mode=${type}`;
}
/**
* Get a download URL for a file
*/
export function getFileDownloadUrl(bucketId: string, fileId: string): string {
return `${process.env.VITE_APPWRITE_ENDPOINT}/storage/buckets/${bucketId}/files/${fileId}/download?project=${process.env.VITE_APPWRITE_PROJECT_ID}`;
}
+28 -5
View File
@@ -1,9 +1,32 @@
import { Client, Storage } from "appwrite"; import { Client, Databases } from "appwrite";
const client = new Client(); const client = new Client();
client // Check if we're in a server environment (SSR)
.setEndpoint(import.meta.env.APPWRITE_ENDPOINT) // Your Appwrite endpoint if (typeof window === 'undefined') {
.setProject(import.meta.env.APPWRITE_PROJECT_ID); // Your Project ID // Server-side: use environment variables directly
const endpoint = process.env.VITE_APPWRITE_ENDPOINT;
const projectId = process.env.VITE_APPWRITE_PROJECT_ID;
if (!endpoint || !projectId) {
throw new Error('Appwrite configuration missing in server environment');
}
client
.setEndpoint(endpoint) // Your Appwrite endpoint
.setProject(projectId); // Your Project ID
} else {
// Client-side: use import.meta.env (need to prefix with PUBLIC_ for Astro to make them available)
const endpoint = import.meta.env.PUBLIC_APPWRITE_ENDPOINT;
const projectId = import.meta.env.PUBLIC_APPWRITE_PROJECT_ID;
if (!endpoint || !projectId) {
throw new Error('Appwrite configuration missing in client environment');
}
client
.setEndpoint(endpoint) // Your Appwrite endpoint
.setProject(projectId); // Your Project ID
}
export const storage = new Storage(client); export const databases = new Databases(client);
+2 -1
View File
@@ -5,7 +5,8 @@ export function cn(...inputs: ClassValue[]) {
return twMerge(clsx(inputs)) return twMerge(clsx(inputs))
} }
export function formatDate(date: Date) { export function formatDate(date: Date | string) {
if (typeof date === "string") date = new Date(date)
return Intl.DateTimeFormat("en-US", { return Intl.DateTimeFormat("en-US", {
month: "short", month: "short",
day: "2-digit", day: "2-digit",
+92
View File
@@ -0,0 +1,92 @@
import { type APIRoute } from 'astro';
import { getFileUrl, getFilePreviewUrl } from '../../../lib/appwrite-service.ts';
export const GET: APIRoute = async ({ params, request }) => {
const { fileID } = params;
// Validate that we have a file ID
if (!fileID) {
return new Response(
JSON.stringify({ error: 'File ID is required' }),
{ status: 400, headers: { 'Content-Type': 'application/json' } }
);
}
try {
// Get the bucket ID from environment variables
const bucketId = process.env.VITE_APPWRITE_BUCKET_ID;
if (!bucketId) {
return new Response(
JSON.stringify({ error: 'Bucket ID is not configured' }),
{ status: 500, headers: { 'Content-Type': 'application/json' } }
);
}
// Parse query parameters for preview type
const url = new URL(request.url);
const type = url.searchParams.get('type') as "thumb" | "preview" | null;
let fileUrl: string;
// Determine the appropriate URL based on query parameter or default to view
if (type === 'thumb' || type === 'preview') {
fileUrl = getFilePreviewUrl(bucketId, fileID, type);
} else {
// Default to regular view URL
fileUrl = getFileUrl(bucketId, fileID);
}
// Return a redirect response to the file URL
return new Response(
null,
{
status: 302,
headers: {
'Location': fileUrl
}
}
);
} catch (error) {
console.error('Error fetching file:', error);
return new Response(
JSON.stringify({ error: 'Failed to fetch file' }),
{ status: 500, headers: { 'Content-Type': 'application/json' } }
);
}
};
// Handle HEAD requests for preflight checks
export const HEAD: APIRoute = async ({ params }) => {
const { fileID } = params;
if (!fileID) {
return new Response(
null,
{ status: 400 }
);
}
try {
// Get the bucket ID from environment variables
const bucketId = process.env.VITE_APPWRITE_BUCKET_ID;
if (!bucketId) {
return new Response(
null,
{ status: 500 }
);
}
// For HEAD requests, we just validate that the file URL can be generated
// This is a basic check - in production you might want to actually verify
// that the file exists on Appwrite
const fileUrl = getFileUrl(bucketId, fileID);
// Return a successful response (we don't actually need to return anything specific for HEAD)
return new Response(null, { status: 200 });
} catch (error) {
console.error('Error checking file:', error);
return new Response(null, { status: 500 });
}
};
+16 -13
View File
@@ -1,24 +1,27 @@
--- ---
import { type CollectionEntry, getCollection } from "astro:content"
import PageLayout from "@layouts/PageLayout.astro" import PageLayout from "@layouts/PageLayout.astro"
import TopLayout from "@layouts/TopLayout.astro" import TopLayout from "@layouts/TopLayout.astro"
import BottomLayout from "@layouts/BottomLayout.astro" import BottomLayout from "@layouts/BottomLayout.astro"
import ArticleTopLayout from "@layouts/ArticleTopLayout.astro" import ArticleTopLayout from "@layouts/ArticleTopLayout.astro"
import ArticleBottomLayout from "@layouts/ArticleBottomLayout.astro" import ArticleBottomLayout from "@layouts/ArticleBottomLayout.astro"
import { getBlogPostById } from "@lib/appwrite-service"
// Create the static blog pages
export async function getStaticPaths() {
const posts = await getCollection("blog")
return posts.map((post) => ({
params: { slug: post.slug },
props: post,
}))
}
// Get the requested post // Get the requested post
type Props = CollectionEntry<"blog"> const slug = Astro.params.slug || ''
const post = Astro.props const post = await getBlogPostById(slug)
const { title, summary } = post.data .then(blogPost => {
if (blogPost) {
return blogPost;
}
return null;
})
.catch(error => {
console.error("Error fetching blog post:", error);
return null;
})
const { title, summary } = post || { title: "Post not found", summary: "" }
--- ---
<PageLayout title={title} description={summary}> <PageLayout title={title} description={summary}>
@@ -32,4 +35,4 @@ const { title, summary } = post.data
<ArticleBottomLayout entry={post} /> <ArticleBottomLayout entry={post} />
</div> </div>
</BottomLayout> </BottomLayout>
</PageLayout> </PageLayout>
+19 -7
View File
@@ -1,16 +1,30 @@
--- ---
import { getCollection } from "astro:content"
import PageLayout from "@layouts/PageLayout.astro" import PageLayout from "@layouts/PageLayout.astro"
import TopLayout from "@layouts/TopLayout.astro" import TopLayout from "@layouts/TopLayout.astro"
import BottomLayout from "@layouts/BottomLayout.astro" import BottomLayout from "@layouts/BottomLayout.astro"
import Blog from "@components/Blog" import Blog from "@components/Blog"
import { BLOG } from "@consts" import { BLOG } from "@consts"
import { getBlogPostsPaginated } from "@lib/appwrite-service"
const posts = (await getCollection("blog")) // Get page and limit from URL parameters
.filter(post => !post.data.draft) const url = new URL(typeof window !== 'undefined' ? window.location.href : 'http://localhost')
.sort((a, b) => b.data.date.getTime() - a.data.date.getTime()) const pageParam = url.searchParams.get('page') || '1'
const limitParam = url.searchParams.get('limit') || '10'
const page = parseInt(pageParam)
const limit = parseInt(limitParam)
const tags = [...new Set(posts.flatMap(post => post.data.tags))] // Fetch paginated blog posts
const { posts } = await getBlogPostsPaginated(page, limit)
.then(result => {
return result;
})
.catch(error => {
console.error("Error fetching blog posts:", error);
return { posts: [], total: 0 };
})
// Get all tags for filtering
const tags = [...new Set(posts.flatMap(post => post.tags))]
.sort((a, b) => a.localeCompare(b)) .sort((a, b) => a.localeCompare(b))
--- ---
@@ -26,5 +40,3 @@ const tags = [...new Set(posts.flatMap(post => post.data.tags))]
</div> </div>
</BottomLayout> </BottomLayout>
</PageLayout> </PageLayout>
+37 -30
View File
@@ -1,5 +1,5 @@
--- ---
import { getCollection } from "astro:content" import { getBlogPosts, getProjects } from "@lib/appwrite-service";
import PageLayout from "@layouts/PageLayout.astro" import PageLayout from "@layouts/PageLayout.astro"
import ArrowCard from "@components/ArrowCard" import ArrowCard from "@components/ArrowCard"
import StackCard from "@components/StackCard.astro" import StackCard from "@components/StackCard.astro"
@@ -7,14 +7,15 @@ import { SITE, SOCIALS } from "@consts"
import TwinklingStars from "@components/TwinklingStars.astro" import TwinklingStars from "@components/TwinklingStars.astro"
import MeteorShower from "@components/MeteorShower.astro" import MeteorShower from "@components/MeteorShower.astro"
const posts = (await getCollection("blog")) // Fetch blog posts and projects from Appwrite
.filter(post => !post.data.draft) const posts = (await getBlogPosts())
.sort((a, b) => b.data.date.getTime() - a.data.date.getTime()) .filter(post => !post.draft)
.sort((a, b) => new Date(b.date).getTime() - new Date(a.date).getTime())
.slice(0,3) .slice(0,3)
const projects = (await getCollection("projects")) const projects = (await getProjects())
.filter(project => !project.data.draft) .filter(project => !project.draft)
.sort((a, b) => b.data.date.getTime() - a.data.date.getTime()) .sort((a, b) => new Date(b.date).getTime() - new Date(a.date).getTime())
.slice(0,3) .slice(0,3)
const stack = [ const stack = [
@@ -38,6 +39,11 @@ const stack = [
icon: "tailwind", icon: "tailwind",
href: "https://tailwindcss.com" href: "https://tailwindcss.com"
}, },
{
text: "Appwrite",
icon: "simple-icons--appwrite",
href: "https://appwrite.io"
}
] ]
--- ---
@@ -57,7 +63,7 @@ const stack = [
<div id='stars3' class='fixed inset-0'></div> <div id='stars3' class='fixed inset-0'></div>
</div> </div>
<!-- Dark Theme: Twinkling Stars / Metors --> <!-- Dark Theme: Twinkling Stars / Meteor Shower -->
<div id="galaxy" class="fixed inset-0"> <div id="galaxy" class="fixed inset-0">
<div class="hidden dark:block"> <div class="hidden dark:block">
<TwinklingStars/> <TwinklingStars/>
@@ -77,29 +83,29 @@ const stack = [
</div> </div>
</div> </div>
<div class="animate absolute h-full w-full flex items-center justify-center"> <div class="animate absolute h-full w-full flex items-center justify-center">
<div class='relative w-full h-full flex items-center justify-center'> <div class='relative w-full h-full flex items-center justify-center text-spaghetti-brown/100 dark:text-spaghetti-cream'>
<div class='p-5 text-center'> <div class='p-5 text-center'>
<img src="${import.meta.env.APPWRITE_ENDPOINT}/v1/storage/buckets/${import.meta.env.APPWRITE_BUCKET_ID}/files/689d27a400194d326f69/view?project=${import.meta.env.APPWRITE_PROJECT_ID}" alt="Quinn Marvin" class="rounded-full w-32 h-32 mx-auto mb-4 border-4 border-spaghetti-red" /> <img src='/api/assets/689d27a400194d326f69' alt="Quinn Marvin" class="rounded-full w-32 h-32 mx-auto mb-4 border-4 border-spaghetti-brown dark:border-spaghetti-cream" />
<p class='animated text-lg md:text-xl lg:text-2xl font-semibold opacity-75 text-spaghetti-brown'> <p class='animated text-lg md:text-xl lg:text-2xl font-semibold opacity-75'>
Hello, I am Quinn Marvin Hello, I am Quinn Marvin
</p> </p>
<p class='animated text-2xl md:text-3xl lg:text-4xl font-bold uppercase text-spaghetti-brown'> <p class='animated text-2xl md:text-3xl lg:text-4xl font-bold uppercase'>
CEO / Creator / Innovator CEO / Creator / Innovator
</p> </p>
<p class='animated text-sm md:text-base lg:text-lg opacity-75 text-spaghetti-brown'> <p class='animated text-sm md:text-base lg:text-lg opacity-75'>
Passionate about spaghetti, noodles and all things tech. Passionate about spaghetti, noodles and all things tech.
</p> </p>
<p class='animated text-sm md:text-base lg:text-lg opacity-75 mt-2 text-spaghetti-brown'> <p class='animated text-sm md:text-base lg:text-lg opacity-75 mt-2'>
Running 2 Unraid servers with Docker container ecosystem Running 2 Unraid servers with Docker container ecosystem
</p> </p>
<p class='animated text-sm md:text-base lg:text-lg opacity-75 mt-1 text-spaghetti-brown'> <p class='animated text-sm md:text-base lg:text-lg opacity-75 mt-1'>
Supporting PostgreSQL, MariaDB, MySQL, MongoDB, Redis, and Minio Supporting PostgreSQL, MariaDB, MySQL, MongoDB, Redis, and Minio
</p> </p>
<div id="ctaButtons" class='animated flex flex-wrap gap-4 justify-center mt-5'> <div id="ctaButtons" class='animated flex flex-wrap gap-4 justify-center mt-5'>
<a href='/blog' class='py-2 px-4 rounded truncate text-xs md:text-sm lg:text-base bg-spaghetti-red dark:bg-spaghetti-red text-white dark:text-white hover:opacity-75 blend'> <a href='/blog' class='py-2 px-4 rounded truncate text-xs md:text-sm lg:text-base bg-spaghetti-red dark:bg-spaghetti-red dark:text-spaghetti-brown hover:opacity-75 blend'>
Read my blog Read my blog
</a> </a>
<a href='/work' class='py-2 px-4 truncate rounded text-xs md:text-sm lg:text-base border border-spaghetti-yellow/50 dark:border-spaghetti-yellow/50 hover:bg-spaghetti-yellow/20 hover:dark:bg-spaghetti-yellow/20 blend text-spaghetti-brown dark:text-spaghetti-brown'> <a href='/work' class='py-2 px-4 truncate rounded text-xs md:text-sm lg:text-base border border-spaghetti-yellow/50 dark:border-spaghetti-yellow/50 hover:bg-spaghetti-yellow/20 hover:dark:bg-spaghetti-yellow/20 blend dark:text-spaghetti-cream'>
View my work View my work
</a> </a>
</div> </div>
@@ -108,12 +114,12 @@ const stack = [
</div> </div>
</section> </section>
<div class="relative bg-white dark:bg-black"> <div class="relative bg-white dark:bg-black dark:text-spaghetti-brown">
<div class="mx-auto max-w-screen-sm p-5 space-y-24 pb-16"> <div class="mx-auto max-w-screen-sm p-5 space-y-24 pb-16">
<!-- About Section --> <!-- About Section -->
<section class="animate"> <section class="animate">
<article> <article class="text-spaghetti-brown/100 dark:text-spaghetti-cream">
<p>Hello! I'm Quinn Marvin, a passionate CEO/Creator/Innovator with an unrelenting love for spaghetti, noodles, and all things tech.</p> <p>Hello! I'm Quinn Marvin, a passionate CEO/Creator/Innovator with an unrelenting love for spaghetti, noodles, and all things tech.</p>
<p>With 10+ years of experience building high-performing engineering teams and driving innovation in dynamic environments, I combine deep technical expertise with exceptional emotional intelligence and a human-centered leadership approach.</p> <p>With 10+ years of experience building high-performing engineering teams and driving innovation in dynamic environments, I combine deep technical expertise with exceptional emotional intelligence and a human-centered leadership approach.</p>
<p>I specialize in IT Service Management (ITSM), IT Operations Management (ITOM), and IT Asset Management (ITAM), positioning myself as a trusted advisor to enterprise clients.</p> <p>I specialize in IT Service Management (ITSM), IT Operations Management (ITOM), and IT Asset Management (ITAM), positioning myself as a trusted advisor to enterprise clients.</p>
@@ -127,7 +133,7 @@ const stack = [
<section class="animate"> <section class="animate">
<div class="space-y-4"> <div class="space-y-4">
<div class="flex justify-between"> <div class="flex justify-between">
<p class="font-semibold text-black dark:text-white"> <p class="font-semibold text-spaghetti-brown dark:text-spaghetti-cream">
Recent posts Recent posts
</p> </p>
<a href="/blog" class="w-fit col-span-3 group flex gap-1 items-center underline decoration-[.5px] decoration-black/25 dark:decoration-white/50 hover:decoration-black dark:hover:decoration-white text-black dark:text-white underline-offset-2 blend"> <a href="/blog" class="w-fit col-span-3 group flex gap-1 items-center underline decoration-[.5px] decoration-black/25 dark:decoration-white/50 hover:decoration-black dark:hover:decoration-white text-black dark:text-white underline-offset-2 blend">
@@ -139,7 +145,7 @@ const stack = [
<ul class="space-y-4"> <ul class="space-y-4">
{posts.map((post) => ( {posts.map((post) => (
<li> <li>
<ArrowCard entry={post} /> <ArrowCard entry={post} collection={'blog'} />
</li> </li>
))} ))}
</ul> </ul>
@@ -149,11 +155,11 @@ const stack = [
<!-- Tech Stack Section --> <!-- Tech Stack Section -->
<section class="animate"> <section class="animate">
<div class="space-y-4"> <div class="space-y-4">
<p class="font-semibold text-black dark:text-white"> <p class="font-semibold text-spaghetti-brown dark:text-spaghetti-cream">
Website build with Website build with
</p> </p>
<div class="flex flex-wrap items-center gap-2 mt-5"> <div class="flex flex-wrap items-center gap-2 mt-5">
{stack.map(item => ( {stack.map((item) => (
<StackCard <StackCard
text={item.text} text={item.text}
icon={item.icon} icon={item.icon}
@@ -161,10 +167,10 @@ const stack = [
/> />
))} ))}
</div> </div>
<div> <div class="dark:text-spaghetti-cream">
Performing reactivity and statefulness, special guest Performing reactivity and statefulness, special guest
<a href="https://www.solidjs.com/" target="_blank" class="w-fit group underline decoration-[.5px] decoration-black/25 dark:decoration-white/50 hover:decoration-black dark:hover:decoration-white text-black dark:text-white underline-offset-2 blend"> <a href="https://www.solidjs.com/" target="_blank" class="w-fit group underline decoration-[.5px] decoration-black/25 dark:decoration-white/50 hover:decoration-black dark:hover:decoration-white text-black dark:text-white underline-offset-2 blend">
<span class="text-black/75 dark:text-white/75 group-hover:text-black group-hover:dark:text-white blend"> <span class="text-spaghetti-brown/75 dark:text-spaghetti-cream/75 group-hover:text-spaghetti-brown group-hover:dark:text-spaghetti-cream blend">
SolidJS SolidJS
</span> </span>
</a> </a>
@@ -176,7 +182,7 @@ const stack = [
<section class="animate"> <section class="animate">
<div class="space-y-4"> <div class="space-y-4">
<div class="flex justify-between"> <div class="flex justify-between">
<p class="font-semibold text-black dark:text-white"> <p class="font-semibold text-spaghetti-brown dark:text-spaghetti-cream">
Recent projects Recent projects
</p> </p>
<a href="/projects" class="w-fit col-span-3 group flex gap-1 items-center underline decoration-[.5px] decoration-black/25 dark:decoration-white/50 hover:decoration-black dark:hover:decoration-white text-black dark:text-white underline-offset-2 blend"> <a href="/projects" class="w-fit col-span-3 group flex gap-1 items-center underline decoration-[.5px] decoration-black/25 dark:decoration-white/50 hover:decoration-black dark:hover:decoration-white text-black dark:text-white underline-offset-2 blend">
@@ -188,7 +194,7 @@ const stack = [
<ul class="space-y-4"> <ul class="space-y-4">
{projects.map((project) => ( {projects.map((project) => (
<li> <li>
<ArrowCard entry={project} /> <ArrowCard entry={project} collection={'projects'} />
</li> </li>
))} ))}
</ul> </ul>
@@ -197,15 +203,15 @@ const stack = [
<!-- Contact Section --> <!-- Contact Section -->
<section class="animate"> <section class="animate">
<div> <div class=" text-spaghetti-brown dark:text-spaghetti-cream">
<p class="font-semibold text-black dark:text-white"> <p class="font-semibold">
Let's Connect Let's Connect
</p> </p>
<p> <p>
Reach out to me via email or on social media. Reach out to me via email or on social media.
</p> </p>
<div class="grid grid-cols-4 gap-y-2 mt-4 auto-cols-min"> <div class="grid grid-cols-4 gap-y-2 mt-4 auto-cols-min">
{SOCIALS.map(social => ( {SOCIALS.map((social) => (
<div class="col-span-1 flex items-center gap-1"> <div class="col-span-1 flex items-center gap-1">
<span class="whitespace-nowrap truncate"> <span class="whitespace-nowrap truncate">
{social.NAME} {social.NAME}
@@ -219,6 +225,7 @@ const stack = [
</a> </a>
</div> </div>
))} ))}
</div>
</div> </div>
</section> </section>
</div> </div>
+15 -20
View File
@@ -1,42 +1,37 @@
--- ---
import { type CollectionEntry, getCollection } from "astro:content"
import PageLayout from "@layouts/PageLayout.astro" import PageLayout from "@layouts/PageLayout.astro"
import TopLayout from "@layouts/TopLayout.astro" import TopLayout from "@layouts/TopLayout.astro"
import BottomLayout from "@layouts/BottomLayout.astro" import BottomLayout from "@layouts/BottomLayout.astro"
import { formatDate } from "@lib/utils" import { formatDate } from "@lib/utils"
import { SITE } from "@consts" import { SITE } from "@consts"
import { getLegalDocuments } from "@lib/appwrite-service"
// Create the static pages for legal docs // Get the requested legal doc (simplified approach)
export async function getStaticPaths() { const legalDocs = await getLegalDocuments()
const docs = await getCollection("legal") const doc = legalDocs.find(d => d.$id === Astro.params.slug) || null
return docs.map((doc) => ({
params: { slug: doc.slug }, if (!doc) {
props: doc, // Handle case where document is not found
})) return new Response("Not Found", { status: 404 })
} }
// Get the requested legal doc // Skip render() call since we're using Appwrite data directly
type Props = CollectionEntry<"legal">; // const { Content } = await doc.render();
const doc = Astro.props
const { title, date } = doc.data
const { Content } = await doc.render();
--- ---
<PageLayout title={title} description={`${title} for ${SITE.TITLE}`}> <PageLayout title={doc.title} description={`${doc.title} for ${SITE.TITLE}`}>
<TopLayout> <TopLayout>
<div class="animate"> <div class="animate">
<div class="page-heading"> <div class="page-heading">
{title} {doc.title}
</div> </div>
<p class="font-normal opacity-75"> <p class="font-normal opacity-75">
Last updated: {formatDate(date)} Last updated: {formatDate(doc.date)}
</p> </p>
</div> </div>
</TopLayout> </TopLayout>
<BottomLayout> <BottomLayout>
<article class="animate"> <article class="animate prose dark:prose-invert text-spaghetti-brown/100 dark:text-spaghetti-cream" set:html={doc.contentHtml}></article>
<Content/>
</article>
</BottomLayout> </BottomLayout>
</PageLayout> </PageLayout>
+17 -15
View File
@@ -1,30 +1,32 @@
--- ---
import { type CollectionEntry, getCollection } from "astro:content"
import PageLayout from "@layouts/PageLayout.astro" import PageLayout from "@layouts/PageLayout.astro"
import TopLayout from "@layouts/TopLayout.astro" import TopLayout from "@layouts/TopLayout.astro"
import BottomLayout from "@layouts/BottomLayout.astro" import BottomLayout from "@layouts/BottomLayout.astro"
import ArticleTopLayout from "@layouts/ArticleTopLayout.astro" import ArticleTopLayout from "@layouts/ArticleTopLayout.astro"
import ArticleBottomLayout from "@layouts/ArticleBottomLayout.astro" import ArticleBottomLayout from "@layouts/ArticleBottomLayout.astro"
import { getProjectById } from "@lib/appwrite-service"
// Create the static projects pages
export async function getStaticPaths() {
const projects = await getCollection("projects")
return projects.map((project) => ({
params: { slug: project.slug },
props: project,
}))
}
// Get the requested project // Get the requested project
type Props = CollectionEntry<"projects"> const slug = Astro.params.slug || ''
const project = Astro.props const project = await getProjectById(slug)
const { title, summary } = project.data .then(projectData => {
if (projectData) {
return projectData
}
return null;
})
.catch(error => {
console.error("Error fetching project:", error);
return null;
})
const { title, summary } = project || { title: "Project not found", summary: "" }
--- ---
<PageLayout title={title} description={summary}> <PageLayout title={title} description={summary}>
<TopLayout> <TopLayout>
<div class="animate"> <div class="animate">
<ArticleTopLayout entry={project} /> <ArticleTopLayout entry={project}/>
</div> </div>
</TopLayout> </TopLayout>
<BottomLayout> <BottomLayout>
@@ -32,4 +34,4 @@ const { title, summary } = project.data
<ArticleBottomLayout entry={project} /> <ArticleBottomLayout entry={project} />
</div> </div>
</BottomLayout> </BottomLayout>
</PageLayout> </PageLayout>
+22 -6
View File
@@ -1,16 +1,32 @@
--- ---
import { getCollection } from "astro:content"
import PageLayout from "@layouts/PageLayout.astro" import PageLayout from "@layouts/PageLayout.astro"
import TopLayout from "@layouts/TopLayout.astro" import TopLayout from "@layouts/TopLayout.astro"
import BottomLayout from "@layouts/BottomLayout.astro" import BottomLayout from "@layouts/BottomLayout.astro"
import Projects from "@components/Projects" import Projects from "@components/Projects"
import { PROJECTS } from "@consts" import { PROJECTS } from "@consts"
import { getProjectsPaginated } from "@lib/appwrite-service"
const projects = (await getCollection("projects"))
.filter(project => !project.data.draft)
.sort((a, b) => b.data.date.getTime() - a.data.date.getTime())
const tags = [...new Set(projects.flatMap(project => project.data.tags))] // Get page and limit from URL parameters
const url = new URL(typeof window !== 'undefined' ? window.location.href : 'https://home.spaghet.io')
const pageParam = url.searchParams.get('page') || '1'
const limitParam = url.searchParams.get('limit') || '10'
const page = parseInt(pageParam)
const limit = parseInt(limitParam)
// Fetch paginated projects
const { posts } = await getProjectsPaginated(page, limit)
.then(result => {
console.log(result)
return result;
})
.catch(error => {
console.error("Error fetching projects:", error);
return { posts: [], total: 0 };
})
// Get all tags for filtering
const tags = [...new Set(posts.flatMap(project => project.tags))]
.sort((a, b) => a.localeCompare(b)) .sort((a, b) => a.localeCompare(b))
--- ---
@@ -22,7 +38,7 @@ const tags = [...new Set(projects.flatMap(project => project.data.tags))]
</TopLayout> </TopLayout>
<BottomLayout> <BottomLayout>
<div class="animate"> <div class="animate">
<Projects client:load tags={tags} data={projects} /> <Projects client:load tags={tags} data={posts} />
</div> </div>
</BottomLayout> </BottomLayout>
</PageLayout> </PageLayout>
+18 -13
View File
@@ -1,30 +1,35 @@
import rss from "@astrojs/rss" import rss from "@astrojs/rss"
import { getCollection } from "astro:content"
import { SITE } from "@consts" import { SITE } from "@consts"
import { getBlogPosts, getProjects } from "@lib/appwrite-service"
type Context = { type Context = {
site: string site: string
} }
export async function GET(context: Context) { export async function GET(context: Context) {
const posts = await getCollection("blog") // Get data from Appwrite instead of Astro content collections
const projects = await getCollection("projects") const blogPosts = await getBlogPosts()
const projects = await getProjects()
const items = [...posts, ...projects]
// Combine and sort items by date (most recent first)
items.sort((a, b) => new Date(b.data.date).getTime() - new Date(a.data.date).getTime()) const items = [...blogPosts, ...projects]
.sort((a, b) => new Date(b.date).getTime() - new Date(a.date).getTime())
.map((item) => ({
title: item.title,
description: item.summary,
pubDate: item.date,
link: item.$collectionId === process.env.VITE_APPWRITE_BLOG_COLLECTION_ID ? `/blog/${item.$id}/` : `/projects/${item.$id}/`,
}))
return rss({ return rss({
title: SITE.TITLE, title: SITE.TITLE,
description: SITE.DESCRIPTION, description: SITE.DESCRIPTION,
site: context.site, site: context.site,
items: items.map((item) => ({ items: items.map((item) => ({
title: item.data.title, title: item.title,
description: item.data.summary, description: item.description,
pubDate: item.data.date, pubDate: item.pubDate,
link: item.slug.startsWith("blog") link: item.link,
? `/blog/${item.slug}/`
: `/projects/${item.slug}/`,
})), })),
}) })
} }
+10 -9
View File
@@ -1,18 +1,19 @@
--- ---
import { type CollectionEntry, getCollection } from "astro:content"
import PageLayout from "@layouts/PageLayout.astro" import PageLayout from "@layouts/PageLayout.astro"
import TopLayout from "@layouts/TopLayout.astro" import TopLayout from "@layouts/TopLayout.astro"
import BottomLayout from "@layouts/BottomLayout.astro" import BottomLayout from "@layouts/BottomLayout.astro"
import Search from "@components/Search" import Search from "@components/Search"
import { SEARCH } from "@consts" import { SEARCH } from "@consts"
const posts = (await getCollection("blog")) // The search page now uses client-side search with Appwrite SDK directly
.filter(post => !post.data.draft) // No need to pre-load all data as the Search component handles this via API calls
const projects = (await getCollection("projects")) // Handle URL search parameters - add proper client-side handling for search query
.filter(post => !post.data.draft) const url = new URL(typeof window !== 'undefined' ? window.location.href : 'http://localhost')
const searchParam = url.searchParams.get('search') || ''
const data = [...posts, ...projects] as CollectionEntry<"blog">[] // Pass initial search query to component if present in URL
const initialQuery = searchParam
--- ---
<PageLayout title={SEARCH.TITLE} description={SEARCH.DESCRIPTION}> <PageLayout title={SEARCH.TITLE} description={SEARCH.DESCRIPTION}>
@@ -22,8 +23,8 @@ const data = [...posts, ...projects] as CollectionEntry<"blog">[]
</div> </div>
</TopLayout> </TopLayout>
<BottomLayout> <BottomLayout>
<div class="animate"> <div class="animate" id="search-container">
<Search client:load data={data}/> <Search client:load query={initialQuery}/>
</div> </div>
</BottomLayout> </BottomLayout>
</PageLayout> </PageLayout>
+20 -19
View File
@@ -1,23 +1,25 @@
--- ---
import { getCollection } from "astro:content"
import PageLayout from "@layouts/PageLayout.astro" import PageLayout from "@layouts/PageLayout.astro"
import TopLayout from "@layouts/TopLayout.astro" import TopLayout from "@layouts/TopLayout.astro"
import BottomLayout from "@layouts/BottomLayout.astro" import BottomLayout from "@layouts/BottomLayout.astro"
import { WORK } from "@consts" import { WORK } from "@consts"
import { getWorkExperiences, type WorkExperience } from "@lib/appwrite-service"
const collection = await getCollection("work") type Props = {
entry: WorkExperience
}
collection.sort((a, b) => new Date(b.data.dateStart).getTime() - new Date(a.data.dateStart).getTime()) const work = await getWorkExperiences()
.then(workList => {
const work = await Promise.all( return workList;
collection.map(async (item) => { })
const { Content } = await item.render() .catch(error => {
return { ...item, Content } console.error("Error fetching work experiences:", error);
return [];
}) })
)
function formatWorkDate(input: Date | string) { function formatWorkDate(input: Date | string) {
if (typeof input === "string") return input if (typeof input === "string") input = new Date(input)
const month = input.toLocaleDateString("en-US", { const month = input.toLocaleDateString("en-US", {
month: "short", month: "short",
@@ -37,23 +39,22 @@ function formatWorkDate(input: Date | string) {
<BottomLayout> <BottomLayout>
<ul> <ul>
{ {
work.map((entry) => ( work.sort((a, b) => a.dateEnd > b.dateEnd ? -1 : b.dateEnd > a.dateEnd ? 1 : 0).map((entry) => (
<li class="animate border-b border-black/10 dark:border-white/25 mt-4 py-8 first-of-type:mt-0 first-of-type:pt-0 last-of-type:border-none"> <li class="animate border-b border-black/10 dark:border-white/25 mt-4 py-8 first-of-type:mt-0 first-of-type:pt-0 last-of-type:border-none">
<div class="text-sm uppercase mb-4"> <div class="text-sm uppercase mb-4">
{formatWorkDate(entry.data.dateStart)} - {formatWorkDate(entry.data.dateEnd)} {formatWorkDate(entry.dateStart)} - {formatWorkDate(entry.dateEnd)}
</div> </div>
<div class="text-black dark:text-white font-semibold"> <div class="text-spaghetti-brown/100 dark:text-spaghetti-yellow font-semibold">
{entry.data.company} {entry.company}
</div> </div>
<div class="text-sm font-semibold"> <div class="text-sm font-semibold text-spaghetti-brown/100 dark:text-spaghetti-yellow">
{entry.data.role} {entry.role}
</div> </div>
<article class="prose dark:prose-invert"> <article class="prose dark:prose-invert text-spaghetti-brown/100 dark:text-spaghetti-cream" set:html={entry.contentHtml}></article>
<entry.Content />
</article>
</li> </li>
)) ))
} }
</ul> </ul>
</BottomLayout> </BottomLayout>
</PageLayout> </PageLayout>
+64 -1
View File
@@ -39,7 +39,7 @@ html {
html.dark { html.dark {
color-scheme: dark; color-scheme: dark;
background-color: black; background-color: #000000; /* Darker black for better contrast */
} }
/* Apply pastel cream background to main content areas */ /* Apply pastel cream background to main content areas */
@@ -53,6 +53,69 @@ body {
@apply text-black/75 dark:text-white/75; @apply text-black/75 dark:text-white/75;
} }
/* Better dark mode text contrast */
.dark {
--tw-text-opacity: 1;
color: rgba(255, 255, 255, var(--tw-text-opacity));
}
/* Improved border visibility in dark mode */
.border-black\/15 {
border-color: rgba(255, 255, 255, 0.15) !important;
}
.border-white\/20 {
border-color: rgba(255, 255, 255, 0.2) !important;
}
/* Better contrast for links and important text */
.prose a {
color: var(--spaghetti-red) !important;
}
.prose h1,
.prose h2,
.prose h3,
.prose h4,
.prose h5,
.prose h6 {
color: #ffffff !important;
}
.prose code {
color: #ffffff !important;
}
.prose blockquote {
border-left-color: var(--spaghetti-yellow) !important;
}
.prose th,
.prose td {
color: #ffffff !important;
}
.page-heading {
@apply font-semibold text-black dark:text-white;
}
/* Better contrast for text elements */
.text-spaghetti-brown {
color: #f59e0b !important; /* Amber-400 for better visibility */
}
/* Better background for code blocks in dark mode */
.prose pre {
background-color: #1f2937 !important; /* gray-800 */
color: #f9fafb !important; /* gray-50 */
}
/* Improved dark mode for cards and buttons */
.group:hover .border-black\/15,
.group:hover .border-white\/20 {
border-color: rgba(255, 255, 255, 0.3) !important;
}
/* Pastel Theme Colors */ /* Pastel Theme Colors */
.text-spaghetti-yellow { .text-spaghetti-yellow {
color: var(--spaghetti-yellow); color: var(--spaghetti-yellow);