Skip to content

Commit 47f6da0

Browse files
committed
initial commit
0 parents  commit 47f6da0

17 files changed

Lines changed: 1545 additions & 0 deletions

File tree

‎.github/workflows/deploy.yml‎

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Deploy to GitHub Pages
2+
3+
on:
4+
push:
5+
branches: [main]
6+
workflow_dispatch:
7+
8+
permissions:
9+
contents: read
10+
pages: write
11+
id-token: write
12+
13+
concurrency:
14+
group: pages
15+
cancel-in-progress: true
16+
17+
jobs:
18+
build:
19+
runs-on: ubuntu-latest
20+
steps:
21+
- uses: actions/checkout@v4
22+
- uses: oven-sh/setup-bun@v2
23+
with:
24+
bun-version: latest
25+
- run: bun install --frozen-lockfile || bun install
26+
- run: bun run build
27+
- uses: actions/upload-pages-artifact@v3
28+
with:
29+
path: ./dist
30+
31+
deploy:
32+
needs: build
33+
runs-on: ubuntu-latest
34+
environment:
35+
name: github-pages
36+
url: ${{ steps.deployment.outputs.page_url }}
37+
steps:
38+
- id: deployment
39+
uses: actions/deploy-pages@v4

‎.gitignore‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
node_modules
2+
dist
3+
.astro
4+
.DS_Store
5+
*.log
6+
.env
7+
.env.*
8+
!.env.example

‎README.md‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# alperdev.codes
2+
3+
Personal portfolio built with Astro, React, Tailwind v4, and Framer Motion.
4+
5+
## Development
6+
7+
```bash
8+
bun install
9+
bun run dev
10+
```
11+
12+
## Content
13+
14+
- `src/content/site.json` - bio, socials, labels
15+
- `src/content/projects.json` - project list
16+
17+
## Deploy
18+
19+
Push to `main`. GitHub Actions builds and deploys to GitHub Pages.

‎astro.config.mjs‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { defineConfig } from 'astro/config';
2+
import react from '@astrojs/react';
3+
import tailwindcss from '@tailwindcss/vite';
4+
5+
export default defineConfig({
6+
site: 'https://alperdev.codes',
7+
integrations: [react()],
8+
vite: {
9+
plugins: [tailwindcss()],
10+
},
11+
});

‎bun.lock‎

Lines changed: 1081 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json‎

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
{
2+
"name": "alperdev-portfolio",
3+
"type": "module",
4+
"version": "0.1.0",
5+
"private": true,
6+
"scripts": {
7+
"dev": "astro dev",
8+
"build": "astro build",
9+
"preview": "astro preview",
10+
"astro": "astro"
11+
},
12+
"dependencies": {
13+
"@astrojs/react": "^4.2.1",
14+
"@react-three/drei": "^10.7.7",
15+
"@react-three/fiber": "^9.6.1",
16+
"@tailwindcss/vite": "^4.0.0",
17+
"astro": "^5.1.1",
18+
"framer-motion": "^11.15.0",
19+
"react": "^19.0.0",
20+
"react-dom": "^19.0.0",
21+
"tailwindcss": "^4.0.0",
22+
"three": "^0.184.0"
23+
},
24+
"devDependencies": {
25+
"@types/react": "^19.0.2",
26+
"@types/react-dom": "^19.0.2",
27+
"@types/three": "^0.184.0"
28+
}
29+
}

‎public/.nojekyll‎

Whitespace-only changes.

‎public/CNAME‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
alperdev.codes

‎public/icon.jpg‎

20.8 KB
Loading

‎src/components/Controls.tsx‎

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
import { useEffect, useState } from "react";
2+
3+
type Theme = "light" | "dark";
4+
5+
export default function Controls() {
6+
const [theme, setTheme] = useState<Theme>("light");
7+
8+
useEffect(() => {
9+
const t = (document.documentElement.dataset.theme as Theme) || "light";
10+
setTheme(t);
11+
}, []);
12+
13+
function toggleTheme() {
14+
const next: Theme = theme === "dark" ? "light" : "dark";
15+
document.documentElement.classList.toggle("dark", next === "dark");
16+
document.documentElement.dataset.theme = next;
17+
localStorage.setItem("theme", next);
18+
setTheme(next);
19+
}
20+
21+
return (
22+
<button
23+
onClick={toggleTheme}
24+
className="font-sans text-sm text-[var(--fg-faint)] hover:text-[var(--fg)] transition-colors"
25+
>
26+
{theme === "dark" ? "light" : "dark"}
27+
</button>
28+
);
29+
}

0 commit comments

Comments
 (0)