diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
index 304501a..8255a1a 100644
--- a/.github/workflows/deploy.yml
+++ b/.github/workflows/deploy.yml
@@ -1,8 +1,10 @@
-name: Deploy Vite site to Pages
+name: Redirect GitHub Pages to Cloudflare
+# The site lives on Cloudflare now; GitHub Pages only forwards old links.
on:
push:
branches: ["main"]
+ paths: ["gh-pages/**", ".github/workflows/deploy.yml"]
workflow_dispatch:
permissions:
@@ -15,34 +17,17 @@ concurrency:
cancel-in-progress: false
jobs:
- build:
- runs-on: ubuntu-latest
- steps:
- - name: Checkout
- uses: actions/checkout@v4
- - name: Setup Node
- uses: actions/setup-node@v4
- with:
- node-version: "22"
- cache: npm
- - name: Setup Pages
- uses: actions/configure-pages@v5
- - name: Install dependencies
- run: npm ci
- - name: Build
- run: npm run build
- - name: Upload artifact
- uses: actions/upload-pages-artifact@v3
- with:
- path: ./dist
-
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
- needs: build
steps:
- - name: Deploy to GitHub Pages
- id: deployment
+ - uses: actions/checkout@v4
+ - run: cp gh-pages/index.html gh-pages/404.html
+ - uses: actions/configure-pages@v5
+ - uses: actions/upload-pages-artifact@v3
+ with:
+ path: ./gh-pages
+ - id: deployment
uses: actions/deploy-pages@v4
diff --git a/gh-pages/index.html b/gh-pages/index.html
new file mode 100644
index 0000000..434e30b
--- /dev/null
+++ b/gh-pages/index.html
@@ -0,0 +1,17 @@
+
+
+
+
+
+ Pietro Quintavalle — moved
+
+
+
+
+
+
+
+
+ This portfolio has moved to __NEW_URL__.
+
+
diff --git a/public/404.html b/public/404.html
new file mode 100644
index 0000000..ef9f2ae
--- /dev/null
+++ b/public/404.html
@@ -0,0 +1,74 @@
+
+
+
+
+
+ 404 — Pietro Quintavalle
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
Error 404. Nothing is mounted at this path.
+
404
+
Empty slot in the rack.
+
The page you asked for doesn't exist, or it moved when the site did. Everything that matters is one click away.
+
+
+
+
+ No link on this port
+
+
diff --git a/src/content.ts b/src/content.ts
index d7d5801..4348848 100644
--- a/src/content.ts
+++ b/src/content.ts
@@ -2,7 +2,7 @@
export const EMAIL = '0pietroquintavalle0@gmail.com'
export const GITHUB = 'https://github.com/Quinta0'
export const LINKEDIN = 'https://linkedin.com/in/pietro-quintavalle'
-export const WHOAMI = 'https://quinta0.github.io/whoami'
+export const WHOAMI = '__NEW_URL__'
export const GITLAB = 'https://gitlab.com/Quinta0'
export const CODEBERG = 'https://codeberg.org/Quinta'
diff --git a/standalone.html b/standalone.html
index cf48206..1eab154 100644
--- a/standalone.html
+++ b/standalone.html
@@ -184,6 +184,8 @@ footer{padding:40px clamp(20px,6vw,120px);font-size:13px;color:var(--muted);disp
+
+
@@ -369,7 +371,7 @@ footer{padding:40px clamp(20px,6vw,120px);font-size:13px;color:var(--muted);disp
+41 79 906 82 53
GitHub
LinkedIn
- whoami
+ whoami
@@ -387,16 +389,20 @@ const isMobile = coarse || innerWidth < 760;
/* ---------- Three.js particle sculpture ---------- */
const canvas = document.getElementById('scene');
+const hasThree = typeof THREE !== 'undefined';
let renderer;
-try { renderer = new THREE.WebGLRenderer({canvas, antialias:false, alpha:true, powerPreference:'high-performance'}); }
-catch(e){ canvas.style.display='none'; }
+if (hasThree) {
+ try { renderer = new THREE.WebGLRenderer({canvas, antialias:false, alpha:true, powerPreference:'high-performance'}); }
+ catch(e){}
+}
+if (!renderer) canvas.style.display = 'none';
const COUNT = isMobile ? 6000 : 15000;
-const scene = new THREE.Scene();
-const camera = new THREE.PerspectiveCamera(42, innerWidth/innerHeight, 0.1, 100);
-camera.position.set(0, 0, 18);
-const group = new THREE.Group();
-scene.add(group);
+const scene = hasThree ? new THREE.Scene() : null;
+const camera = hasThree ? new THREE.PerspectiveCamera(42, innerWidth/innerHeight, 0.1, 100) : null;
+const group = hasThree ? new THREE.Group() : null;
+if (camera) camera.position.set(0, 0, 18);
+if (scene && group) scene.add(group);
const rnd = (a=1,b=0)=>Math.random()*(a-b)+b;
@@ -635,6 +641,7 @@ let hoverT=0, hoverCur=0, swapCur=1, hoverKey=null, hoverLabel=null;
let progT=0, progCur=0, keyEls=null;
let scrollT=0, scrollCur=0, mx=0,my=0, mxCur=0,myCur=0, mouseOn=0, mouseOnCur=0;
function updateScroll(){
+ if(!hasThree)return;
const max=document.documentElement.scrollHeight-innerHeight; scrollT=max>0?scrollY/max:0;
if(!keyEls) keyEls=['.hero','#work','#skills','#contact'].map(q=>document.querySelector(q));
const c=keyEls.map(el=>el.offsetTop+el.offsetHeight/2-innerHeight/2), y=scrollY;
@@ -647,8 +654,11 @@ addEventListener('pointermove',e=>{ mx=(e.clientX/innerWidth)*2-1; my=-(e.client
addEventListener('pointerleave',()=>{mouseOn=0});
document.addEventListener('mouseleave',()=>{mouseOn=0});
-const plane=new THREE.Plane(new THREE.Vector3(0,0,1),0), ray=new THREE.Raycaster(), hit=new THREE.Vector3(), ndc=new THREE.Vector2();
-const clock=new THREE.Clock();
+const plane = hasThree ? new THREE.Plane(new THREE.Vector3(0,0,1),0) : null;
+const ray = hasThree ? new THREE.Raycaster() : null;
+const hit = hasThree ? new THREE.Vector3() : null;
+const ndc = hasThree ? new THREE.Vector2() : null;
+const clock = hasThree ? new THREE.Clock() : null;
let introT=0;
function frame(){
@@ -788,8 +798,7 @@ document.querySelectorAll('nav a[href^="#"]').forEach(a=>a.addEventListener('cli
/* boot: wait for the display font so the PQ sampling is right, then go */
function boot(){
- if(!renderer)return;
- buildParticles(); resize(); updateScroll(); frame();
+ if(renderer){ buildParticles(); resize(); updateScroll(); frame(); }
setTimeout(()=>name.classList.add('on'),150);
}
if(document.fonts&&document.fonts.load){ Promise.race([document.fonts.load('800 300px Syne'),new Promise(r=>setTimeout(r,1500))]).then(boot,boot); } else boot();
diff --git a/vite.config.ts b/vite.config.ts
index 8198233..9ffcc67 100644
--- a/vite.config.ts
+++ b/vite.config.ts
@@ -2,6 +2,5 @@ import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
export default defineConfig({
- base: '/whoami/',
plugins: [react()],
})
diff --git a/wrangler.jsonc b/wrangler.jsonc
new file mode 100644
index 0000000..7800661
--- /dev/null
+++ b/wrangler.jsonc
@@ -0,0 +1,8 @@
+{
+ "name": "whoami",
+ "compatibility_date": "2026-09-28",
+ "assets": {
+ "directory": "./dist",
+ "not_found_handling": "404-page"
+ }
+}