This commit is contained in:
2026-08-02 17:09:34 +02:00
commit e6bcafdfee
30 changed files with 7154 additions and 0 deletions

23
.gitignore vendored Normal file
View File

@@ -0,0 +1,23 @@
node_modules
# Output
.output
.vercel
.netlify
.wrangler
/.svelte-kit
/build
# OS
.DS_Store
Thumbs.db
# Env
.env
.env.*
!.env.example
!.env.test
# Vite
vite.config.js.timestamp-*
vite.config.ts.timestamp-*

1
.npmrc Normal file
View File

@@ -0,0 +1 @@
engine-strict=true

3
.vscode/extensions.json vendored Normal file
View File

@@ -0,0 +1,3 @@
{
"recommendations": ["svelte.svelte-vscode"]
}

19
Dockerfile Normal file
View File

@@ -0,0 +1,19 @@
# Stage 1: Build SvelteKit application
FROM node:20-alpine AS builder
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build
RUN npm prune --production
# Stage 2: Runtime Environment
FROM node:20-alpine
WORKDIR /app
COPY --from=builder /app/build ./build
COPY --from=builder /app/package.json ./package.json
COPY --from=builder /app/node_modules ./node_modules
EXPOSE 3001
ENV PORT=3001
ENV NODE_ENV=production
CMD ["node", "build/index.js"]

23
README.md Normal file
View File

@@ -0,0 +1,23 @@
# ASF Public Website (`frontend-website`)
This directory contains the public-facing marketing and documentation SvelteKit website for the poultry automation platform.
---
## Technical Stack
- **Framework**: SvelteKit (configured with Static Site Generation adapter for SEO optimization).
- **Styling**: Vanilla CSS.
- **Subdomains**: Mapped to the root domain `https://nabd-co.com` in production configurations.
---
## Execution & Running Locally
To run the development server locally:
```bash
npm install
npm run dev
```
The app is served at `http://localhost:5173` (configured to run on port `3001` inside Docker containers).

20
docker-compose.yml Normal file
View File

@@ -0,0 +1,20 @@
version: '3.8'
services:
frontend-website:
build:
context: .
dockerfile: Dockerfile
container_name: asf_frontend_website
restart: unless-stopped
environment:
- PORT=3001
- NODE_ENV=production
networks:
asf_network:
aliases:
- frontend-website
networks:
asf_network:
external: true

15
jsconfig.json Normal file
View File

@@ -0,0 +1,15 @@
{
"extends": "./.svelte-kit/tsconfig.json",
"compilerOptions": {
"allowJs": true,
"checkJs": true,
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"resolveJsonModule": true,
"skipLibCheck": true,
"sourceMap": true,
"strict": true,
"moduleResolution": "bundler",
"module": "esnext"
}
}

4328
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

26
package.json Normal file
View File

@@ -0,0 +1,26 @@
{
"name": "frontend-website",
"private": true,
"version": "0.0.1",
"type": "module",
"scripts": {
"dev": "vite dev",
"build": "vite build",
"preview": "vite preview",
"prepare": "svelte-kit sync || echo ''",
"check": "svelte-kit sync && svelte-check --tsconfig ./jsconfig.json",
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./jsconfig.json --watch"
},
"dependencies": {
"@sentry/sveltekit": "^8.5.0"
},
"devDependencies": {
"@sveltejs/adapter-node": "^5.2.9",
"@sveltejs/kit": "^2.57.0",
"@sveltejs/vite-plugin-svelte": "^7.0.0",
"svelte": "^5.55.2",
"svelte-check": "^4.4.6",
"typescript": "^6.0.2",
"vite": "^8.0.7"
}
}

13
src/app.d.ts vendored Normal file
View File

@@ -0,0 +1,13 @@
// See https://svelte.dev/docs/kit/types#app.d.ts
// for information about these interfaces
declare global {
namespace App {
// interface Error {}
// interface Locals {}
// interface PageData {}
// interface PageState {}
// interface Platform {}
}
}
export {};

13
src/app.html Normal file
View File

@@ -0,0 +1,13 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="text-scale" content="scale" />
<link rel="icon" type="image/png" href="/favicon.png?v=3" />
%sveltekit.head%
</head>
<body data-sveltekit-preload-data="hover">
<div style="display: contents">%sveltekit.body%</div>
</body>
</html>

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="107" height="128" viewBox="0 0 107 128"><title>svelte-logo</title><path d="M94.157 22.819c-10.4-14.885-30.94-19.297-45.792-9.835L22.282 29.608A29.92 29.92 0 0 0 8.764 49.65a31.5 31.5 0 0 0 3.108 20.231 30 30 0 0 0-4.477 11.183 31.9 31.9 0 0 0 5.448 24.116c10.402 14.887 30.942 19.297 45.791 9.835l26.083-16.624A29.92 29.92 0 0 0 98.235 78.35a31.53 31.53 0 0 0-3.105-20.232 30 30 0 0 0 4.474-11.182 31.88 31.88 0 0 0-5.447-24.116" style="fill:#ff3e00"/><path d="M45.817 106.582a20.72 20.72 0 0 1-22.237-8.243 19.17 19.17 0 0 1-3.277-14.503 18 18 0 0 1 .624-2.435l.49-1.498 1.337.981a33.6 33.6 0 0 0 10.203 5.098l.97.294-.09.968a5.85 5.85 0 0 0 1.052 3.878 6.24 6.24 0 0 0 6.695 2.485 5.8 5.8 0 0 0 1.603-.704L69.27 76.28a5.43 5.43 0 0 0 2.45-3.631 5.8 5.8 0 0 0-.987-4.371 6.24 6.24 0 0 0-6.698-2.487 5.7 5.7 0 0 0-1.6.704l-9.953 6.345a19 19 0 0 1-5.296 2.326 20.72 20.72 0 0 1-22.237-8.243 19.17 19.17 0 0 1-3.277-14.502 17.99 17.99 0 0 1 8.13-12.052l26.081-16.623a19 19 0 0 1 5.3-2.329 20.72 20.72 0 0 1 22.237 8.243 19.17 19.17 0 0 1 3.277 14.503 18 18 0 0 1-.624 2.435l-.49 1.498-1.337-.98a33.6 33.6 0 0 0-10.203-5.1l-.97-.294.09-.968a5.86 5.86 0 0 0-1.052-3.878 6.24 6.24 0 0 0-6.696-2.485 5.8 5.8 0 0 0-1.602.704L37.73 51.72a5.42 5.42 0 0 0-2.449 3.63 5.79 5.79 0 0 0 .986 4.372 6.24 6.24 0 0 0 6.698 2.486 5.8 5.8 0 0 0 1.602-.704l9.952-6.342a19 19 0 0 1 5.295-2.328 20.72 20.72 0 0 1 22.237 8.242 19.17 19.17 0 0 1 3.277 14.503 18 18 0 0 1-8.13 12.053l-26.081 16.622a19 19 0 0 1-5.3 2.328" style="fill:#fff"/></svg>

After

Width:  |  Height:  |  Size: 1.5 KiB

1
src/lib/index.js Normal file
View File

@@ -0,0 +1 @@
// place files you want to import through the `$lib` alias in this folder.

11
src/routes/+layout.svelte Normal file
View File

@@ -0,0 +1,11 @@
<script>
import favicon from '$lib/assets/favicon.svg';
let { children } = $props();
</script>
<svelte:head>
<link rel="icon" href={favicon} />
</svelte:head>
{@render children()}

1370
src/routes/+page.svelte Normal file

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 MiB

BIN
static/animation_onw.mp4 Normal file

Binary file not shown.

BIN
static/company_logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 MiB

BIN
static/favicon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 162 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 159 KiB

View File

@@ -0,0 +1,88 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 800 650" width="100%" height="100%" style="background-color: #0F172A; font-family: 'Segoe UI', system-ui, sans-serif;">
<defs>
<!-- Arrowhead markers -->
<marker id="arrow-blue" viewBox="0 0 10 10" refX="5" refY="5" markerWidth="6" markerHeight="6" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#38BDF8" />
</marker>
<marker id="arrow-gold" viewBox="0 0 10 10" refX="5" refY="5" markerWidth="6" markerHeight="6" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#F59E0B" />
</marker>
<!-- Drop Shadows -->
<filter id="shadow" x="-5%" y="-5%" width="110%" height="110%">
<feDropShadow dx="0" dy="4" stdDeviation="6" flood-color="#000000" flood-opacity="0.4"/>
</filter>
</defs>
<!-- TOP BLOCK: Nabd Cloud + Mobile -->
<g filter="url(#shadow)">
<rect x="220" y="30" width="360" height="90" rx="12" fill="#1E293B" stroke="#38BDF8" stroke-width="2" />
<text x="400" y="70" text-anchor="middle" fill="#F8FAFC" font-size="18" font-weight="bold">Nabd Cloud + Mobile</text>
<text x="400" y="95" text-anchor="middle" fill="#94A3B8" font-size="14">(remote monitor / control)</text>
</g>
<!-- HTTPS OUTBOUND CONNECTION LINE -->
<line x1="400" y1="210" x2="400" y2="130" stroke="#38BDF8" stroke-width="2" stroke-dasharray="6,6" marker-end="url(#arrow-blue)" />
<rect x="300" y="155" width="200" height="26" rx="13" fill="#0F172A" stroke="#38BDF8" stroke-width="1"/>
<text x="400" y="172" text-anchor="middle" fill="#38BDF8" font-size="12" font-weight="bold">HTTPS (outbound from farm)</text>
<!-- MAIN CONTAINER: Poultry Farm -->
<rect x="50" y="210" width="700" height="400" rx="16" fill="#1E293B" fill-opacity="0.6" stroke="#334155" stroke-width="2" stroke-dasharray="4,4" />
<text x="80" y="245" fill="#94A3B8" font-size="14" font-weight="bold" letter-spacing="1">POULTRY FARM</text>
<!-- CENTER BLOCK: Main Hub (Edge Controller) -->
<g filter="url(#shadow)">
<rect x="180" y="270" width="440" height="110" rx="12" fill="#1E293B" stroke="#F59E0B" stroke-width="2" />
<text x="400" y="305" text-anchor="middle" fill="#F59E0B" font-size="20" font-weight="bold">Main Hub (Edge Controller)</text>
<text x="400" y="335" text-anchor="middle" fill="#F8FAFC" font-size="13">Main Controller for Farm &amp; House</text>
<text x="400" y="358" text-anchor="middle" fill="#94A3B8" font-size="12">(Compute, HMI, Actuators, Data Fusion, Alarms, OTA Host)</text>
</g>
<!-- WIRELESS CONNECTION LINES -->
<path d="M 400 380 L 400 440" stroke="#F59E0B" stroke-width="2" />
<path d="M 120 440 L 680 440" stroke="#F59E0B" stroke-width="2" />
<line x1="120" y1="440" x2="120" y2="470" stroke="#F59E0B" stroke-width="2" marker-end="url(#arrow-gold)" />
<line x1="260" y1="440" x2="260" y2="470" stroke="#F59E0B" stroke-width="2" marker-end="url(#arrow-gold)" />
<line x1="400" y1="440" x2="400" y2="470" stroke="#F59E0B" stroke-width="2" marker-end="url(#arrow-gold)" />
<line x1="680" y1="440" x2="680" y2="470" stroke="#F59E0B" stroke-width="2" marker-end="url(#arrow-gold)" />
<rect x="290" y="427" width="220" height="26" rx="13" fill="#0F172A" stroke="#F59E0B" stroke-width="1"/>
<text x="400" y="444" text-anchor="middle" fill="#F59E0B" font-size="12" font-weight="bold">Wi-Fi / MQTT-TLS (Wireless)</text>
<!-- BOTTOM BLOCKS: Sensor Hubs -->
<!-- SH #1 -->
<g filter="url(#shadow)">
<rect x="60" y="480" width="120" height="75" rx="8" fill="#0F172A" stroke="#334155" stroke-width="1.5" />
<text x="120" y="512" text-anchor="middle" fill="#F8FAFC" font-size="15" font-weight="bold">SH #1</text>
<text x="120" y="535" text-anchor="middle" fill="#94A3B8" font-size="11">ESP32-S3</text>
</g>
<!-- SH #2 -->
<g filter="url(#shadow)">
<rect x="200" y="480" width="120" height="75" rx="8" fill="#0F172A" stroke="#334155" stroke-width="1.5" />
<text x="260" y="512" text-anchor="middle" fill="#F8FAFC" font-size="15" font-weight="bold">SH #2</text>
<text x="260" y="535" text-anchor="middle" fill="#94A3B8" font-size="11">ESP32-S3</text>
</g>
<!-- SH #3 -->
<g filter="url(#shadow)">
<rect x="340" y="480" width="120" height="75" rx="8" fill="#0F172A" stroke="#334155" stroke-width="1.5" />
<text x="400" y="512" text-anchor="middle" fill="#F8FAFC" font-size="15" font-weight="bold">SH #3</text>
<text x="400" y="535" text-anchor="middle" fill="#94A3B8" font-size="11">ESP32-S3</text>
</g>
<!-- ELLIPSIS (...) -->
<text x="540" y="525" text-anchor="middle" fill="#94A3B8" font-size="28" font-weight="bold">• • •</text>
<!-- SH #N -->
<g filter="url(#shadow)">
<rect x="620" y="480" width="120" height="75" rx="8" fill="#0F172A" stroke="#334155" stroke-width="1.5" />
<text x="680" y="512" text-anchor="middle" fill="#F8FAFC" font-size="15" font-weight="bold">SH #N</text>
<text x="680" y="535" text-anchor="middle" fill="#94A3B8" font-size="11">ESP32-S3</text>
</g>
<!-- SENSOR HUB FOOTNOTE -->
<text x="400" y="585" text-anchor="middle" fill="#94A3B8" font-size="12">ESP32-S3 Sensor Hub stations in each room (Sensing &amp; Calibration Only)</text>
<text x="400" y="602" text-anchor="middle" fill="#38BDF8" font-size="11" font-weight="bold">N = Sized dynamically based on room length / layout</text>
</svg>

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 118 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 148 KiB

BIN
static/nabd_icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 MiB

3
static/robots.txt Normal file
View File

@@ -0,0 +1,3 @@
# allow crawling everything by default
User-agent: *
Disallow:

15
svelte.config.js Normal file
View File

@@ -0,0 +1,15 @@
import adapter from '@sveltejs/adapter-node';
/** @type {import('@sveltejs/kit').Config} */
const config = {
compilerOptions: {
// Force runes mode for the project, except for libraries. Can be removed in svelte 6.
runes: ({ filename }) => (filename.split(/[/\\]/).includes('node_modules') ? undefined : true)
},
kit: {
// adapter-node compiles SvelteKit to a standalone Node.js server
adapter: adapter()
}
};
export default config;

9
vite.config.js Normal file
View File

@@ -0,0 +1,9 @@
import { sveltekit } from '@sveltejs/kit/vite';
import { defineConfig } from 'vite';
export default defineConfig({
plugins: [sveltekit()],
server: {
allowedHosts: true
}
});