Compare commits
15 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| da5ac1a7d9 | |||
| dc28d73e98 | |||
| 8367393813 | |||
| d0762a177e | |||
| 628009d468 | |||
| d1ac06b636 | |||
| 429520d6c1 | |||
| ba3248e3f2 | |||
| e5ceb3c74d | |||
| 072d792017 | |||
| 8bc027d9b4 | |||
| a6316748b3 | |||
| c67d2a4045 | |||
| 72203909e6 | |||
| 2e4b0ee04d |
@@ -1,41 +0,0 @@
|
||||
name: CI + E2E
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
e2e:
|
||||
runs-on: self-hosted
|
||||
timeout-minutes: 10
|
||||
steps:
|
||||
- name: Run E2E tests
|
||||
id: e2e
|
||||
run: |
|
||||
cd /home/clems/mascarade/web
|
||||
BASE_URL=http://localhost:3100 npx playwright test --reporter=line 2>&1 | tee /tmp/e2e-output.txt
|
||||
PASSED=$(grep -oP '\d+ passed' /tmp/e2e-output.txt | grep -oP '\d+' || echo 0)
|
||||
FAILED=$(grep -oP '\d+ failed' /tmp/e2e-output.txt | grep -oP '\d+' || echo 0)
|
||||
echo "passed=$PASSED" >> $GITHUB_OUTPUT
|
||||
echo "failed=$FAILED" >> $GITHUB_OUTPUT
|
||||
if [ "${FAILED:-0}" != "0" ] && [ "${FAILED:-0}" != "" ]; then exit 1; fi
|
||||
|
||||
- name: Notify ntfy on failure
|
||||
if: failure()
|
||||
run: |
|
||||
curl -s -d "E2E FAILED: ${{ steps.e2e.outputs.failed }} tests failed on $(date '+%H:%M')" \
|
||||
-H "Title: Ops ER E2E Failed" \
|
||||
-H "Priority: high" \
|
||||
-H "Tags: rotating_light" \
|
||||
https://ntfy.saillant.cc/ops-alerts 2>/dev/null || true
|
||||
|
||||
- name: Notify ntfy on success
|
||||
if: success()
|
||||
run: |
|
||||
curl -s -d "E2E OK: ${{ steps.e2e.outputs.passed }} passed" \
|
||||
-H "Title: Ops ER E2E Pass" \
|
||||
-H "Priority: low" \
|
||||
-H "Tags: white_check_mark" \
|
||||
https://ntfy.saillant.cc/ops-alerts 2>/dev/null || true
|
||||
@@ -0,0 +1,46 @@
|
||||
name: CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 10
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 22
|
||||
cache: npm
|
||||
|
||||
- name: Install
|
||||
run: npm ci
|
||||
|
||||
- name: Typecheck (non-blocking — repo has known type debt)
|
||||
continue-on-error: true
|
||||
run: npm run typecheck
|
||||
|
||||
- name: Build
|
||||
run: npm run build
|
||||
|
||||
- name: Tracking check (non-blocking)
|
||||
continue-on-error: true
|
||||
run: npm run tracking:check
|
||||
|
||||
- name: Image budget (non-blocking)
|
||||
continue-on-error: true
|
||||
run: npm run image:budget
|
||||
|
||||
- name: Notify ntfy on failure
|
||||
if: failure()
|
||||
run: |
|
||||
curl -s -d "CI FAILED on ${{ github.ref_name }} @ $(date '+%H:%M') — ${{ github.sha }}" \
|
||||
-H "Title: ER github.io CI Failed" \
|
||||
-H "Priority: high" \
|
||||
-H "Tags: rotating_light" \
|
||||
https://ntfy.saillant.cc/ops-alerts 2>/dev/null || true
|
||||
@@ -1,83 +0,0 @@
|
||||
name: Deploy to Tower
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
concurrency:
|
||||
group: deploy-production
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
build-and-deploy:
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
PUBLIC_SITE_URL: https://www.lelectronrare.fr/
|
||||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup Node
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 22
|
||||
cache: npm
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Build site
|
||||
run: npm run build
|
||||
|
||||
- name: Deploy to Tower
|
||||
uses: appleboy/scp-action@v0.1.7
|
||||
with:
|
||||
host: ${{ secrets.TOWER_HOST }}
|
||||
username: ${{ secrets.TOWER_USER }}
|
||||
key: ${{ secrets.TOWER_SSH_KEY }}
|
||||
source: "dist/"
|
||||
target: "/home/clems/electron-rare-site/"
|
||||
overwrite: true
|
||||
rm: true
|
||||
|
||||
- name: Restart site container
|
||||
uses: appleboy/ssh-action@v1.0.3
|
||||
with:
|
||||
host: ${{ secrets.TOWER_HOST }}
|
||||
username: ${{ secrets.TOWER_USER }}
|
||||
key: ${{ secrets.TOWER_SSH_KEY }}
|
||||
script: |
|
||||
cd /home/clems/electron-rare-site
|
||||
docker rm -f electron-rare-site 2>/dev/null || true
|
||||
docker run -d \
|
||||
--name electron-rare-site \
|
||||
--network mascarade-frontend \
|
||||
-v /home/clems/electron-rare-site/dist:/app/dist \
|
||||
-v /home/clems/electron-rare-site/node_modules:/app/node_modules \
|
||||
-w /app \
|
||||
-p 4321:4321 \
|
||||
-e HOST=0.0.0.0 \
|
||||
-e PORT=4321 \
|
||||
--restart unless-stopped \
|
||||
node:22-alpine \
|
||||
node dist/server/entry.mjs
|
||||
|
||||
- name: Verify deployment
|
||||
uses: appleboy/ssh-action@v1.0.3
|
||||
with:
|
||||
host: ${{ secrets.TOWER_HOST }}
|
||||
username: ${{ secrets.TOWER_USER }}
|
||||
key: ${{ secrets.TOWER_SSH_KEY }}
|
||||
script: |
|
||||
sleep 5
|
||||
STATUS=$(curl -s -o /dev/null -w '%{http_code}' http://127.0.0.1:4321/)
|
||||
if [ "$STATUS" != "200" ]; then
|
||||
echo "Site returned $STATUS instead of 200"
|
||||
exit 1
|
||||
fi
|
||||
echo "Site is live (HTTP 200)"
|
||||
@@ -41,14 +41,16 @@ jobs:
|
||||
fi
|
||||
done
|
||||
|
||||
CHECK_STATE="unknown"
|
||||
REQUIRED_CHECKS_LIST="(unknown)"
|
||||
if [ "$PROTECTION_HTTP_CODE" = "200" ]; then
|
||||
REQ_CHECK_CHECKS=$(echo "$PROTECTION_JSON" | jq -r '.required_status_checks.checks[]?.context // empty' | grep -Fx 'Cross-stack coherence' || true)
|
||||
REQ_CHECK_CONTEXTS=$(echo "$PROTECTION_JSON" | jq -r '.required_status_checks.contexts[]? // empty' | grep -Fx 'Cross-stack coherence' || true)
|
||||
if [ -n "$REQ_CHECK_CHECKS" ] || [ -n "$REQ_CHECK_CONTEXTS" ]; then
|
||||
CHECK_STATE="required"
|
||||
else
|
||||
CHECK_STATE="not-required"
|
||||
REQUIRED_CHECKS_LIST="$(echo "$PROTECTION_JSON" | jq -r '
|
||||
[
|
||||
(.required_status_checks.contexts // [])[],
|
||||
(.required_status_checks.checks // [])[].context
|
||||
] | unique | .[]
|
||||
' 2>/dev/null || true)"
|
||||
if [ -z "$REQUIRED_CHECKS_LIST" ]; then
|
||||
REQUIRED_CHECKS_LIST="(none)"
|
||||
fi
|
||||
fi
|
||||
|
||||
@@ -58,10 +60,15 @@ jobs:
|
||||
echo "Generated: $NOW_UTC"
|
||||
echo "Repository: $GH_REPO"
|
||||
echo
|
||||
echo "## Branch Protection (main)"
|
||||
echo "- Cross-stack coherence: $CHECK_STATE"
|
||||
if [ "$CHECK_STATE" = "unknown" ]; then
|
||||
echo "## Branch Protection (main) — Required Status Checks"
|
||||
if [ "$PROTECTION_HTTP_CODE" != "200" ]; then
|
||||
echo "- Note: branch protection endpoint not readable with current token (HTTP $PROTECTION_HTTP_CODE)."
|
||||
elif [ "$REQUIRED_CHECKS_LIST" = "(none)" ]; then
|
||||
echo "- No required status checks configured."
|
||||
else
|
||||
echo "$REQUIRED_CHECKS_LIST" | while IFS= read -r ctx; do
|
||||
[ -n "$ctx" ] && echo "- $ctx"
|
||||
done
|
||||
fi
|
||||
echo
|
||||
echo "## Expected Labels"
|
||||
|
||||
@@ -32,3 +32,9 @@ artifacts/imagegen/
|
||||
artifacts/qa-test/*/responsive-v12-pass2/
|
||||
artifacts/qa-test/*/deploy-sftp-dryrun.txt
|
||||
.env
|
||||
|
||||
# wrangler files
|
||||
.wrangler
|
||||
.dev.vars*
|
||||
!.dev.vars.example
|
||||
!.env.example
|
||||
|
||||
+4
-2
@@ -3,6 +3,8 @@ import { defineConfig } from 'astro/config';
|
||||
import react from '@astrojs/react';
|
||||
import tailwindcss from '@tailwindcss/vite';
|
||||
|
||||
import cloudflare from "@astrojs/cloudflare";
|
||||
|
||||
const normalizeUrl = (value) => (value.endsWith('/') ? value : `${value}/`);
|
||||
const rawSiteUrl = process.env.PUBLIC_SITE_URL || process.env.EXTERNAL_SITE_URL || 'https://electron-rare.github.io/';
|
||||
const siteUrl = normalizeUrl(rawSiteUrl);
|
||||
@@ -13,9 +15,9 @@ export default defineConfig({
|
||||
site: siteUrl,
|
||||
base: basePath,
|
||||
output: 'server',
|
||||
adapter: node({ mode: 'standalone' }),
|
||||
adapter: cloudflare(),
|
||||
integrations: [react()],
|
||||
vite: {
|
||||
plugins: [tailwindcss()]
|
||||
}
|
||||
});
|
||||
});
|
||||
Generated
+1591
-5
File diff suppressed because it is too large
Load Diff
+7
-3
@@ -7,7 +7,7 @@
|
||||
"dev": "astro dev",
|
||||
"build": "astro build",
|
||||
"build:external": "node scripts/build-astro-external.mjs",
|
||||
"preview": "astro preview",
|
||||
"preview": "npm run build && wrangler dev",
|
||||
"astro": "astro",
|
||||
"typecheck": "astro check",
|
||||
"storybook": "storybook dev -p 6006",
|
||||
@@ -20,9 +20,12 @@
|
||||
"preflight:pages": "npm run lab:build && npm run tracking:check && npm run image:budget && npm run storybook:build",
|
||||
"deploy:ftp": "bash scripts/deploy-ovh-ftp.sh dist",
|
||||
"deploy:web:ftp": "npm run build:external && npm run deploy:ftp",
|
||||
"deploy:web:sftp": "npm run build:external && bash scripts/deploy-ovh-sftp.sh dist"
|
||||
"deploy:web:sftp": "npm run build:external && bash scripts/deploy-ovh-sftp.sh dist",
|
||||
"deploy": "npm run build && wrangler deploy",
|
||||
"cf-typegen": "wrangler types"
|
||||
},
|
||||
"dependencies": {
|
||||
"@astrojs/cloudflare": "12",
|
||||
"@astrojs/node": "^9.4.5",
|
||||
"@astrojs/react": "^4.4.1",
|
||||
"@radix-ui/react-slot": "^1.2.3",
|
||||
@@ -48,7 +51,8 @@
|
||||
"@storybook/react-vite": "^9.1.5",
|
||||
"@tailwindcss/vite": "^4.1.13",
|
||||
"storybook": "^9.1.5",
|
||||
"typescript": "^5.9.2"
|
||||
"typescript": "^5.9.2",
|
||||
"wrangler": "^4.86.0"
|
||||
},
|
||||
"overrides": {
|
||||
"@astrojs/language-server": {
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
_worker.js
|
||||
_routes.json
|
||||
@@ -109,18 +109,18 @@ const SECTIONS: Section[] = [
|
||||
// 4. CAS — recul caméra, vue des 4 mosfets, tuiles + médias visibles
|
||||
{ id: 'cas', start: 0.41, end: 0.65,
|
||||
camOffset: [0.5, -0.5, -3.0], camOffsetEnd: [-0.5, -0.3, -2.5], focus: null, explode: 1 },
|
||||
// 7a. MEDIA — vidéo 1, caméra de l'autre côté (Z négatif)
|
||||
// 7a. MEDIA — vidéo 1, caméra de l'autre côté (Z négatif), zoom serré
|
||||
{ id: 'media', start: 0.65, end: 0.69,
|
||||
camOffset: [0.2, 0.0, -1.0], camOffsetEnd: [0.0, 0.0, -0.8], focus: 2, explode: 1 },
|
||||
camOffset: [0.12, 0.0, -0.6], camOffsetEnd: [0.0, 0.0, -0.5], focus: 2, explode: 1 },
|
||||
// 7b. MEDIA — vidéo 2
|
||||
{ id: 'media', start: 0.69, end: 0.73,
|
||||
camOffset: [0.2, 0.0, -1.0], camOffsetEnd: [-0.1, 0.0, -0.8], focus: 3, explode: 1 },
|
||||
camOffset: [0.12, 0.0, -0.6], camOffsetEnd: [-0.06, 0.0, -0.5], focus: 3, explode: 1 },
|
||||
// 7c. MEDIA — vidéo 3
|
||||
{ id: 'media', start: 0.73, end: 0.77,
|
||||
camOffset: [-0.1, 0.0, -1.0], camOffsetEnd: [-0.3, 0.0, -0.8], focus: 4, explode: 1 },
|
||||
camOffset: [-0.06, 0.0, -0.6], camOffsetEnd: [-0.18, 0.0, -0.5], focus: 4, explode: 1 },
|
||||
// 7d. MEDIA — carrousel photos
|
||||
{ id: 'media', start: 0.77, end: 0.81,
|
||||
camOffset: [-0.2, 0.0, -1.0], camOffsetEnd: [0.1, 0.0, -0.8], focus: 5, explode: 1 },
|
||||
camOffset: [-0.12, 0.0, -0.6], camOffsetEnd: [0.06, 0.0, -0.5], focus: 5, explode: 1 },
|
||||
// 8. FORMATS
|
||||
{ id: 'formats', start: 0.81, end: 0.91,
|
||||
camOffset: [2.4, 3.0, 4.0], camOffsetEnd: [1.6, 2.4, 3.0], focus: null, explode: 1, explodeEnd: 0 },
|
||||
@@ -154,14 +154,14 @@ const PCB_LABELS: PcbLabel[] = [
|
||||
// 5. HAUT — centre-haut BMU
|
||||
{ section: 'exp-consulting', cardIndex: 0, localOffset: [0.3, 0.005, -0.45],
|
||||
title: 'Consulting & Formation', sub: 'Audit · Transfert · Pédagogie · Projet' },
|
||||
// 6-9. CAS — les 4 tuiles visibles en même temps, face bottom des mosfets
|
||||
{ section: 'cas', cardIndex: 2, localOffset: [0.0, 0.0, -0.08],
|
||||
// 6-9. CAS — les 4 tuiles visibles en même temps, sous l image/video sur la face bottom des mosfets
|
||||
{ section: 'cas', cardIndex: 2, localOffset: [0.0, 0.5, 0.0],
|
||||
title: 'Industries créatives', sub: 'Audio embarqué · Batterie LiFePO4 · KXKM' },
|
||||
{ section: 'cas', cardIndex: 3, localOffset: [0.0, 0.0, -0.08],
|
||||
title: 'Industrie', sub: 'Production V3.2 · KXKM ESP32 → STM32F030' },
|
||||
{ section: 'cas', cardIndex: 4, localOffset: [0.0, 0.0, -0.08],
|
||||
{ section: 'cas', cardIndex: 3, localOffset: [0.0, 0.5, 0.0],
|
||||
title: 'Industrie', sub: 'Production V3.2 · KXKM ESP32 → STM32F070' },
|
||||
{ section: 'cas', cardIndex: 4, localOffset: [0.0, 0.5, 0.0],
|
||||
title: 'Formation', sub: 'PCB · KiCad · µC' },
|
||||
{ section: 'cas', cardIndex: 5, localOffset: [0.0, 0.0, -0.08],
|
||||
{ section: 'cas', cardIndex: 5, localOffset: [0.0, 0.5, 0.0],
|
||||
title: 'Service', sub: 'Mise en service · Maintenance · Support terrain' },
|
||||
// 9. Conception — Mosfet #1 (card 2)
|
||||
{ section: 'formats', cardIndex: 2, localOffset: [0.0, 0.005, 0.0],
|
||||
@@ -194,33 +194,33 @@ function PcbTile({ offset, title, sub, visible, section, href }: {
|
||||
|
||||
const content = (
|
||||
<div style={{
|
||||
minWidth: isBig ? '340px' : '260px',
|
||||
padding: isBig ? '24px 36px' : '14px 24px',
|
||||
minWidth: isBig ? '680px' : '520px',
|
||||
padding: isBig ? '48px 72px' : '28px 48px',
|
||||
textAlign: 'center',
|
||||
background: isClickable ? 'rgba(0,0,0,0.7)' : 'rgba(0,0,0,0.55)',
|
||||
border: isClickable ? '2px solid #5bd1d8' : '1.5px solid rgba(255,255,255,0.4)',
|
||||
borderRadius: isClickable ? '12px' : '8px',
|
||||
backdropFilter: 'blur(4px)',
|
||||
border: isClickable ? '4px solid #5bd1d8' : '3px solid rgba(255,255,255,0.4)',
|
||||
borderRadius: isClickable ? '24px' : '16px',
|
||||
cursor: isClickable ? 'pointer' : 'default',
|
||||
transform: 'translate3d(0,0,0)',
|
||||
}}>
|
||||
<div style={{
|
||||
fontSize: isBig ? '24px' : '18px',
|
||||
fontSize: isBig ? '48px' : '36px',
|
||||
fontWeight: 800,
|
||||
color: isClickable ? '#5bd1d8' : '#fff',
|
||||
letterSpacing: '0.05em', textTransform: 'uppercase',
|
||||
fontFamily: "'Courier New', monospace",
|
||||
}}>{title}</div>
|
||||
{sub && <div style={{
|
||||
fontSize: isBig ? '14px' : '12px',
|
||||
fontSize: isBig ? '28px' : '24px',
|
||||
color: 'rgba(255,255,255,0.55)',
|
||||
marginTop: isBig ? '10px' : '6px',
|
||||
marginTop: isBig ? '20px' : '12px',
|
||||
fontFamily: "'Courier New', monospace", letterSpacing: '0.03em',
|
||||
}}>{sub}</div>}
|
||||
</div>
|
||||
);
|
||||
|
||||
return (
|
||||
<Html position={offset} center distanceFactor={isBig ? 0.4 : 0.8}
|
||||
<Html position={offset} center distanceFactor={isBig ? 0.2 : 0.4}
|
||||
style={{
|
||||
opacity: visible ? 1 : 0,
|
||||
transition: 'opacity 0.5s',
|
||||
@@ -248,6 +248,26 @@ function CardModel({ file }: { file: string }) {
|
||||
return <primitive object={cloned} />;
|
||||
}
|
||||
|
||||
/* ── Cover-fit helper: crop centered to target aspect (like CSS object-fit:cover) ── */
|
||||
function applyCoverFit(texture: THREE.Texture, targetAspect: number) {
|
||||
const img = texture.image as (HTMLImageElement | HTMLVideoElement | { width: number; height: number; videoWidth?: number; videoHeight?: number } | undefined);
|
||||
if (!img) return;
|
||||
const w = (img as HTMLVideoElement).videoWidth || (img as HTMLImageElement).width;
|
||||
const h = (img as HTMLVideoElement).videoHeight || (img as HTMLImageElement).height;
|
||||
if (!w || !h) return;
|
||||
const sourceAspect = w / h;
|
||||
if (sourceAspect > targetAspect) {
|
||||
texture.repeat.set(targetAspect / sourceAspect, 1);
|
||||
texture.offset.set((1 - targetAspect / sourceAspect) / 2, 0);
|
||||
} else {
|
||||
texture.repeat.set(1, sourceAspect / targetAspect);
|
||||
texture.offset.set(0, (1 - sourceAspect / targetAspect) / 2);
|
||||
}
|
||||
texture.needsUpdate = true;
|
||||
}
|
||||
|
||||
const MEDIA_ASPECT = 4 / 3;
|
||||
|
||||
/* ── Video plane on PCB bottom (real 3D mesh with VideoTexture) ── */
|
||||
function PcbVideoMesh({ offset, src, visible }: {
|
||||
offset: [number, number, number]; src: string; visible: boolean;
|
||||
@@ -256,9 +276,8 @@ function PcbVideoMesh({ offset, src, visible }: {
|
||||
const videoRef = useRef<HTMLVideoElement | null>(null);
|
||||
const texRef = useRef<THREE.VideoTexture | null>(null);
|
||||
|
||||
// Mosfet card local space: ~0.38 x 0.86 (XZ), Y = thickness
|
||||
// Plane size: cover most of the bottom face
|
||||
const planeW = 1.9, planeH = 4.275;
|
||||
// Plane size in 4:3 landscape, sized to leave vertical room for caption tile below
|
||||
const planeW = 1.2, planeH = planeW / MEDIA_ASPECT;
|
||||
|
||||
useEffect(() => {
|
||||
const video = document.createElement('video');
|
||||
@@ -276,7 +295,10 @@ function PcbVideoMesh({ offset, src, visible }: {
|
||||
tex.colorSpace = THREE.SRGBColorSpace;
|
||||
texRef.current = tex;
|
||||
|
||||
return () => { video.pause(); video.src = ''; tex.dispose(); };
|
||||
const onMeta = () => applyCoverFit(tex, MEDIA_ASPECT);
|
||||
video.addEventListener('loadedmetadata', onMeta);
|
||||
|
||||
return () => { video.removeEventListener('loadedmetadata', onMeta); video.pause(); video.src = ''; tex.dispose(); };
|
||||
}, [src]);
|
||||
|
||||
useEffect(() => {
|
||||
@@ -331,12 +353,16 @@ function PcbCarouselMesh({ offset, visible }: {
|
||||
const textures = useRef<THREE.Texture[]>([]);
|
||||
const [idx, setIdx] = useState(0);
|
||||
const autoTimer = useRef(0);
|
||||
const planeW = 1.9, planeH = 4.275;
|
||||
const planeW = 1.2, planeH = planeW / MEDIA_ASPECT;
|
||||
|
||||
useEffect(() => {
|
||||
const loader = new THREE.TextureLoader();
|
||||
textures.current = CAROUSEL_PHOTOS.map(url => {
|
||||
const t = loader.load(url);
|
||||
const t = loader.load(url, (loaded) => {
|
||||
loaded.colorSpace = THREE.SRGBColorSpace;
|
||||
loaded.minFilter = THREE.LinearFilter;
|
||||
applyCoverFit(loaded, MEDIA_ASPECT);
|
||||
});
|
||||
t.colorSpace = THREE.SRGBColorSpace;
|
||||
t.minFilter = THREE.LinearFilter;
|
||||
return t;
|
||||
@@ -501,7 +527,7 @@ function Assembly({ scrollRef, onSection }: {
|
||||
|
||||
const camPos = target.clone().add(offset);
|
||||
|
||||
camera.position.lerp(camPos, Math.min(1, delta * 2));
|
||||
camera.position.lerp(camPos, Math.min(1, delta * 1));
|
||||
camera.lookAt(target);
|
||||
|
||||
// Update section
|
||||
@@ -570,10 +596,10 @@ export function BmuViewer() {
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<div style={{ position: 'fixed', inset: 0, width: '100vw', height: '100vh', zIndex: 0, pointerEvents: 'none' }}>
|
||||
<div style={{ position: 'fixed', inset: 0, width: '100vw', height: '100vh', zIndex: 0, pointerEvents: 'auto' }}>
|
||||
<Canvas gl={{ antialias: true, alpha: true, powerPreference: 'high-performance' }}
|
||||
dpr={[1, 1.5]} camera={{ fov: 35, near: 0.01, far: 50 }}
|
||||
style={{ background: 'transparent', pointerEvents: 'none' }}>
|
||||
dpr={[1, 2]} camera={{ fov: 35, near: 0.01, far: 50 }}
|
||||
style={{ background: 'transparent', pointerEvents: 'auto', touchAction: 'pan-y' }}>
|
||||
<ambientLight intensity={0.5} />
|
||||
<directionalLight position={[5, 8, 5]} intensity={2.2} color="#ffffff" />
|
||||
<directionalLight position={[-3, 4, -2]} intensity={0.9} color="#5bd1d8" />
|
||||
|
||||
@@ -92,14 +92,14 @@
|
||||
<h2>Cas concret</h2>
|
||||
<div class="card">
|
||||
<p class="card-t">Mise en production et correction V3.2 KXKM</p>
|
||||
<p class="card-desc">Mise en production du hardware ESP32, correction des bugs V3.2, passage STM32F030. Tests terrain, validation embarquée, documentation technique.</p>
|
||||
<p class="card-desc" style="color:#a78bfa;margin-top:8px;">→ Production V3.2 livrée · Migration STM32F030 validée</p>
|
||||
<p class="card-desc">Mise en production du hardware ESP32, correction des bugs V3.2, passage vers STM32F070 avec auto_boot, et constitution du dossier de production. Tests terrain, validation embarquée, documentation technique.</p>
|
||||
<p class="card-desc" style="color:#a78bfa;margin-top:8px;">→ Production V3.2 livrée · Migration STM32F070 + auto_boot validés · Dossier de production fourni</p>
|
||||
</div>
|
||||
|
||||
<h2>À propos</h2>
|
||||
<div class="card">
|
||||
<p class="card-t">Clément Saillant — 10 ans d'expérience</p>
|
||||
<p class="card-desc">Cyborg en systèmes électroniques, j'interviens depuis 10 ans sur des projets allant du spectacle vivant à l'industrie automatisée, en passant par l'énergie et la formation. Contributeur open-source (KiCad, KXKM), ambassadeur IA appliquée à l'électronique.</p>
|
||||
<p class="card-t">Clément Saillant — plus de 10 ans d'expérience</p>
|
||||
<p class="card-desc">Expert en systèmes électroniques, j'interviens depuis plus de 10 ans sur des projets allant du spectacle vivant à l'industrie automatisée, en passant par l'énergie et la formation. Contributeur open-source (KiCad, KXKM), ambassadeur IA appliquée à l'électronique.</p>
|
||||
<p class="card-desc">Secteurs : industries créatives, ferroviaire, automatisme industriel, éducation, énergie/stockage.</p>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -41,7 +41,7 @@ import { BmuViewer } from '@/components/BmuViewer';
|
||||
* { margin: 0; padding: 0; box-sizing: border-box; }
|
||||
html { background: #06080b; color: #fff; overflow-x: hidden; }
|
||||
body { background: #06080b; min-height: 100vh; font-family: 'Courier New', monospace; }
|
||||
.scroll-track { height: 1000vh; position: relative; z-index: 1; }
|
||||
.scroll-track { height: 1000vh; position: relative; z-index: 1; pointer-events: none; }
|
||||
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
|
||||
|
||||
/* Loader */
|
||||
@@ -94,7 +94,7 @@ import { BmuViewer } from '@/components/BmuViewer';
|
||||
/* Formats */
|
||||
.ov-formats { bottom: clamp(30px, 5vh, 60px); left: 50%; transform: translateX(-50%); display: flex; gap: 12px; max-width: 820px; width: 92vw; }
|
||||
.ov-formats.on { transform: translateX(-50%); }
|
||||
.fmt { flex: 1; padding: 14px 16px; border-radius: 8px; background: rgba(6,8,11,0.7); backdrop-filter: blur(12px); border: 1px solid rgba(255,255,255,0.05); text-align: center; text-decoration: none; color: inherit; cursor: pointer; transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease; }
|
||||
.fmt { flex: 1; padding: 14px 16px; border-radius: 8px; background: rgba(6,8,11,0.7); backdrop-filter: blur(12px); border: 1px solid rgba(255,255,255,0.05); text-align: center; text-decoration: none; color: inherit; cursor: pointer; pointer-events: auto; transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease; }
|
||||
.fmt:hover { background: rgba(6,8,11,0.85); border-color: rgba(255,255,255,0.18); transform: translateY(-2px); }
|
||||
.fmt-t { font-size: 13px; font-weight: 700; color: #fff; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 4px; }
|
||||
.fmt-d { font-size: 10px; color: rgba(255,255,255,0.35); }
|
||||
@@ -242,7 +242,7 @@ import { BmuViewer } from '@/components/BmuViewer';
|
||||
<h2>Ils m'ont fait confiance</h2>
|
||||
<p>KXKM (spectacle vivant), secteur ferroviaire, industrie automatisée, écoles d'art numérique.</p>
|
||||
<h2>À propos</h2>
|
||||
<p>Clément Saillant — 10 ans d'expérience en systèmes électroniques. Contributeur open-source KiCad et KXKM. Ambassadeur IA appliquée à l'électronique.</p>
|
||||
<p>Clément Saillant — plus de 10 ans d'expérience en systèmes électroniques. Contributeur open-source KiCad et KXKM. Ambassadeur IA appliquée à l'électronique.</p>
|
||||
<p>Contact : <a href="/contact/">Parlons de votre projet</a> — contact@lelectronrare.fr · <a href="https://blog.saillant.cc">Blog technique</a></p>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ import { BmuViewer } from '@/components/BmuViewer';
|
||||
* { margin: 0; padding: 0; box-sizing: border-box; }
|
||||
html { background: #06080b; color: #fff; overflow-x: hidden; }
|
||||
body { background: #06080b; min-height: 100vh; font-family: 'Courier New', monospace; }
|
||||
.scroll-track { height: 1000vh; position: relative; z-index: 1; }
|
||||
.scroll-track { height: 1000vh; position: relative; z-index: 1; pointer-events: none; }
|
||||
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
|
||||
|
||||
/* Loader */
|
||||
@@ -85,7 +85,7 @@ import { BmuViewer } from '@/components/BmuViewer';
|
||||
/* Formats */
|
||||
.ov-formats { bottom: clamp(30px, 5vh, 60px); left: 50%; transform: translateX(-50%); display: flex; gap: 12px; max-width: 820px; width: 92vw; }
|
||||
.ov-formats.on { transform: translateX(-50%); }
|
||||
.fmt { flex: 1; padding: 14px 16px; border-radius: 8px; background: rgba(6,8,11,0.7); backdrop-filter: blur(12px); border: 1px solid rgba(255,255,255,0.05); text-align: center; text-decoration: none; color: inherit; cursor: pointer; transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease; }
|
||||
.fmt { flex: 1; padding: 14px 16px; border-radius: 8px; background: rgba(6,8,11,0.7); backdrop-filter: blur(12px); border: 1px solid rgba(255,255,255,0.05); text-align: center; text-decoration: none; color: inherit; cursor: pointer; pointer-events: auto; transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease; }
|
||||
.fmt:hover { background: rgba(6,8,11,0.85); border-color: rgba(255,255,255,0.18); transform: translateY(-2px); }
|
||||
.fmt-t { font-size: 13px; font-weight: 700; color: #fff; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 4px; }
|
||||
.fmt-d { font-size: 10px; color: rgba(255,255,255,0.35); }
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"$schema": "node_modules/wrangler/config-schema.json",
|
||||
"name": "electron-rare",
|
||||
"compatibility_date": "2026-04-28",
|
||||
"observability": {
|
||||
"enabled": true
|
||||
},
|
||||
"main": "dist/_worker.js/index.js",
|
||||
"compatibility_flags": [
|
||||
"global_fetch_strictly_public",
|
||||
"nodejs_compat"
|
||||
],
|
||||
"assets": {
|
||||
"binding": "ASSETS",
|
||||
"directory": "dist"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user