- Current Version: {appVersion}
+ Current Version: {appVersion || 'Loading...'}
diff --git a/src/routes/changelog.yaml/+server.ts b/src/routes/changelog.yaml/+server.ts
index 5f5e66c..f885c89 100644
--- a/src/routes/changelog.yaml/+server.ts
+++ b/src/routes/changelog.yaml/+server.ts
@@ -5,14 +5,14 @@ import type { RequestHandler } from '@sveltejs/kit';
export const GET: RequestHandler = async () => {
try {
// Try multiple possible locations for changelog.yaml
- // 1. In public directory (development)
- // 2. In build/client (production - where SvelteKit copies public files)
- // 3. In the copied public directory (Docker)
+ // 1. In static directory (development)
+ // 2. In build/client (production - where SvelteKit copies static files)
+ // 3. In the copied static directory (Docker)
const possiblePaths = [
- join(process.cwd(), 'public', 'changelog.yaml'),
+ join(process.cwd(), 'static', 'changelog.yaml'),
join(process.cwd(), 'build', 'client', 'changelog.yaml'),
- join(process.cwd(), '..', 'public', 'changelog.yaml'),
- '/app/public/changelog.yaml' // Docker container path
+ join(process.cwd(), '..', 'static', 'changelog.yaml'),
+ '/app/static/changelog.yaml' // Docker container path
];
let changelogContent: string | null = null;
diff --git a/src/routes/healthz.json/+server.ts b/src/routes/healthz.json/+server.ts
index 615d7ac..44dafe6 100644
--- a/src/routes/healthz.json/+server.ts
+++ b/src/routes/healthz.json/+server.ts
@@ -4,8 +4,8 @@ import type { RequestHandler } from './$types';
export const GET: RequestHandler = async () => {
try {
- // Try to read from public/healthz.json (generated at build time)
- const healthzPath = join(process.cwd(), 'public', 'healthz.json');
+ // Try to read from static/healthz.json (generated at build time)
+ const healthzPath = join(process.cwd(), 'static', 'healthz.json');
const healthzContent = readFileSync(healthzPath, 'utf-8');
const healthz = JSON.parse(healthzContent);
diff --git a/src/vite-env.d.ts b/src/vite-env.d.ts
index 6fc2700..c71e8c7 100644
--- a/src/vite-env.d.ts
+++ b/src/vite-env.d.ts
@@ -4,6 +4,7 @@ interface ImportMetaEnv {
readonly VITE_DEFAULT_RELAYS?: string;
readonly VITE_ZAP_THRESHOLD?: string;
readonly VITE_THREAD_TIMEOUT_DAYS?: string;
+ readonly VITE_APP_VERSION?: string;
}
interface ImportMeta {
diff --git a/public/aither.png b/static/aither.png
similarity index 100%
rename from public/aither.png
rename to static/aither.png
diff --git a/public/apple-touch-icon-114x114.png b/static/apple-touch-icon-114x114.png
similarity index 100%
rename from public/apple-touch-icon-114x114.png
rename to static/apple-touch-icon-114x114.png
diff --git a/public/apple-touch-icon-120x120.png b/static/apple-touch-icon-120x120.png
similarity index 100%
rename from public/apple-touch-icon-120x120.png
rename to static/apple-touch-icon-120x120.png
diff --git a/public/apple-touch-icon-144x144.png b/static/apple-touch-icon-144x144.png
similarity index 100%
rename from public/apple-touch-icon-144x144.png
rename to static/apple-touch-icon-144x144.png
diff --git a/public/apple-touch-icon-152x152.png b/static/apple-touch-icon-152x152.png
similarity index 100%
rename from public/apple-touch-icon-152x152.png
rename to static/apple-touch-icon-152x152.png
diff --git a/public/apple-touch-icon-180x180.png b/static/apple-touch-icon-180x180.png
similarity index 100%
rename from public/apple-touch-icon-180x180.png
rename to static/apple-touch-icon-180x180.png
diff --git a/public/apple-touch-icon-57x57.png b/static/apple-touch-icon-57x57.png
similarity index 100%
rename from public/apple-touch-icon-57x57.png
rename to static/apple-touch-icon-57x57.png
diff --git a/public/apple-touch-icon-60x60.png b/static/apple-touch-icon-60x60.png
similarity index 100%
rename from public/apple-touch-icon-60x60.png
rename to static/apple-touch-icon-60x60.png
diff --git a/public/apple-touch-icon-72x72.png b/static/apple-touch-icon-72x72.png
similarity index 100%
rename from public/apple-touch-icon-72x72.png
rename to static/apple-touch-icon-72x72.png
diff --git a/public/apple-touch-icon-76x76.png b/static/apple-touch-icon-76x76.png
similarity index 100%
rename from public/apple-touch-icon-76x76.png
rename to static/apple-touch-icon-76x76.png
diff --git a/public/changelog.yaml b/static/changelog.yaml
similarity index 92%
rename from public/changelog.yaml
rename to static/changelog.yaml
index 06501ed..5351357 100644
--- a/public/changelog.yaml
+++ b/static/changelog.yaml
@@ -1,4 +1,6 @@
versions:
+ '0.3.2':
+ - 'Expanded /repos to handle GitLab, Gitea, and OneDev repositories'
'0.3.1':
- 'Media attachments rendering in all feeds and views'
- 'NIP-92/NIP-94 image tags support'
diff --git a/public/favicon.ico b/static/favicon.ico
similarity index 100%
rename from public/favicon.ico
rename to static/favicon.ico
diff --git a/static/healthz.json b/static/healthz.json
new file mode 100644
index 0000000..434f84c
--- /dev/null
+++ b/static/healthz.json
@@ -0,0 +1,8 @@
+{
+ "status": "ok",
+ "service": "aitherboard",
+ "version": "0.3.2",
+ "buildTime": "2026-02-14T07:34:30.130Z",
+ "gitCommit": "unknown",
+ "timestamp": 1771054470130
+}
\ No newline at end of file
diff --git a/public/icons/arrow-left.svg b/static/icons/arrow-left.svg
similarity index 100%
rename from public/icons/arrow-left.svg
rename to static/icons/arrow-left.svg
diff --git a/public/icons/bookmark.svg b/static/icons/bookmark.svg
similarity index 100%
rename from public/icons/bookmark.svg
rename to static/icons/bookmark.svg
diff --git a/public/icons/check.svg b/static/icons/check.svg
similarity index 100%
rename from public/icons/check.svg
rename to static/icons/check.svg
diff --git a/public/icons/chevron-down.svg b/static/icons/chevron-down.svg
similarity index 100%
rename from public/icons/chevron-down.svg
rename to static/icons/chevron-down.svg
diff --git a/public/icons/chevron-up.svg b/static/icons/chevron-up.svg
similarity index 100%
rename from public/icons/chevron-up.svg
rename to static/icons/chevron-up.svg
diff --git a/public/icons/code.svg b/static/icons/code.svg
similarity index 100%
rename from public/icons/code.svg
rename to static/icons/code.svg
diff --git a/public/icons/copy.svg b/static/icons/copy.svg
similarity index 100%
rename from public/icons/copy.svg
rename to static/icons/copy.svg
diff --git a/public/icons/database.svg b/static/icons/database.svg
similarity index 100%
rename from public/icons/database.svg
rename to static/icons/database.svg
diff --git a/public/icons/download.svg b/static/icons/download.svg
similarity index 100%
rename from public/icons/download.svg
rename to static/icons/download.svg
diff --git a/public/icons/edit.svg b/static/icons/edit.svg
similarity index 100%
rename from public/icons/edit.svg
rename to static/icons/edit.svg
diff --git a/public/icons/eye.svg b/static/icons/eye.svg
similarity index 100%
rename from public/icons/eye.svg
rename to static/icons/eye.svg
diff --git a/public/icons/file-text.svg b/static/icons/file-text.svg
similarity index 100%
rename from public/icons/file-text.svg
rename to static/icons/file-text.svg
diff --git a/public/icons/heart.svg b/static/icons/heart.svg
similarity index 100%
rename from public/icons/heart.svg
rename to static/icons/heart.svg
diff --git a/public/icons/highlight.svg b/static/icons/highlight.svg
similarity index 100%
rename from public/icons/highlight.svg
rename to static/icons/highlight.svg
diff --git a/public/icons/image.svg b/static/icons/image.svg
similarity index 100%
rename from public/icons/image.svg
rename to static/icons/image.svg
diff --git a/public/icons/key.svg b/static/icons/key.svg
similarity index 100%
rename from public/icons/key.svg
rename to static/icons/key.svg
diff --git a/public/icons/link.svg b/static/icons/link.svg
similarity index 100%
rename from public/icons/link.svg
rename to static/icons/link.svg
diff --git a/public/icons/log-in.svg b/static/icons/log-in.svg
similarity index 100%
rename from public/icons/log-in.svg
rename to static/icons/log-in.svg
diff --git a/public/icons/log-out.svg b/static/icons/log-out.svg
similarity index 100%
rename from public/icons/log-out.svg
rename to static/icons/log-out.svg
diff --git a/public/icons/message-square.svg b/static/icons/message-square.svg
similarity index 100%
rename from public/icons/message-square.svg
rename to static/icons/message-square.svg
diff --git a/public/icons/moon.svg b/static/icons/moon.svg
similarity index 100%
rename from public/icons/moon.svg
rename to static/icons/moon.svg
diff --git a/public/icons/plus.svg b/static/icons/plus.svg
similarity index 100%
rename from public/icons/plus.svg
rename to static/icons/plus.svg
diff --git a/public/icons/radio.svg b/static/icons/radio.svg
similarity index 100%
rename from public/icons/radio.svg
rename to static/icons/radio.svg
diff --git a/public/icons/search.svg b/static/icons/search.svg
similarity index 100%
rename from public/icons/search.svg
rename to static/icons/search.svg
diff --git a/public/icons/send.svg b/static/icons/send.svg
similarity index 100%
rename from public/icons/send.svg
rename to static/icons/send.svg
diff --git a/public/icons/settings.svg b/static/icons/settings.svg
similarity index 100%
rename from public/icons/settings.svg
rename to static/icons/settings.svg
diff --git a/public/icons/share.svg b/static/icons/share.svg
similarity index 100%
rename from public/icons/share.svg
rename to static/icons/share.svg
diff --git a/public/icons/smile.svg b/static/icons/smile.svg
similarity index 100%
rename from public/icons/smile.svg
rename to static/icons/smile.svg
diff --git a/public/icons/sun.svg b/static/icons/sun.svg
similarity index 100%
rename from public/icons/sun.svg
rename to static/icons/sun.svg
diff --git a/public/icons/trash.svg b/static/icons/trash.svg
similarity index 100%
rename from public/icons/trash.svg
rename to static/icons/trash.svg
diff --git a/public/icons/upload.svg b/static/icons/upload.svg
similarity index 100%
rename from public/icons/upload.svg
rename to static/icons/upload.svg
diff --git a/public/icons/user.svg b/static/icons/user.svg
similarity index 100%
rename from public/icons/user.svg
rename to static/icons/user.svg
diff --git a/public/icons/video.svg b/static/icons/video.svg
similarity index 100%
rename from public/icons/video.svg
rename to static/icons/video.svg
diff --git a/public/icons/volume.svg b/static/icons/volume.svg
similarity index 100%
rename from public/icons/volume.svg
rename to static/icons/volume.svg
diff --git a/public/icons/x.svg b/static/icons/x.svg
similarity index 100%
rename from public/icons/x.svg
rename to static/icons/x.svg
diff --git a/public/icons/zap.svg b/static/icons/zap.svg
similarity index 100%
rename from public/icons/zap.svg
rename to static/icons/zap.svg
diff --git a/public/og-image.png b/static/og-image.png
similarity index 100%
rename from public/og-image.png
rename to static/og-image.png
diff --git a/svelte.config.js b/svelte.config.js
index 7f39c07..e94896b 100644
--- a/svelte.config.js
+++ b/svelte.config.js
@@ -18,7 +18,7 @@ const config = {
handleUnseenRoutes: 'ignore',
handleHttpError: ({ path, referrer, message }) => {
// Ignore 404s for static assets during prerendering
- // These will be available at runtime from the public directory
+ // These will be available at runtime from the static directory
if (path === '/favicon.ico' || path === '/og-image.png') {
return;
}
diff --git a/vite.config.js b/vite.config.js
deleted file mode 100644
index 539084f..0000000
--- a/vite.config.js
+++ /dev/null
@@ -1,28 +0,0 @@
-import { sveltekit } from '@sveltejs/kit/vite';
-import { defineConfig } from 'vite';
-import { execSync } from 'child_process';
-export default defineConfig({
- plugins: [
- sveltekit(),
- {
- name: 'generate-healthz',
- buildStart() {
- try {
- execSync('node scripts/generate-healthz.js', { stdio: 'inherit' });
- }
- catch (error) {
- console.warn('Failed to generate healthz.json:', error);
- }
- }
- }
- ],
- server: {
- port: 5173,
- strictPort: false
- },
- build: {
- target: 'esnext',
- sourcemap: true
- }
-});
-//# sourceMappingURL=vite.config.js.map
\ No newline at end of file
diff --git a/vite.config.js.map b/vite.config.js.map
deleted file mode 100644
index 8dcc85e..0000000
--- a/vite.config.js.map
+++ /dev/null
@@ -1 +0,0 @@
-{"version":3,"file":"vite.config.js","sourceRoot":"","sources":["vite.config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAEzC,eAAe,YAAY,CAAC;IAC1B,OAAO,EAAE;QACP,SAAS,EAAE;QACX;YACE,IAAI,EAAE,kBAAkB;YACxB,UAAU;gBACR,IAAI,CAAC;oBACH,QAAQ,CAAC,kCAAkC,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;gBACrE,CAAC;gBAAC,OAAO,KAAK,EAAE,CAAC;oBACf,OAAO,CAAC,IAAI,CAAC,kCAAkC,EAAE,KAAK,CAAC,CAAC;gBAC1D,CAAC;YACH,CAAC;SACF;KACF;IACD,MAAM,EAAE;QACN,IAAI,EAAE,IAAI;QACV,UAAU,EAAE,KAAK;KAClB;IACD,KAAK,EAAE;QACL,MAAM,EAAE,QAAQ;QAChB,SAAS,EAAE,IAAI;KAChB;CACF,CAAC,CAAC"}
\ No newline at end of file
diff --git a/vite.config.ts b/vite.config.ts
index 7b1e2bf..28efce6 100644
--- a/vite.config.ts
+++ b/vite.config.ts
@@ -3,9 +3,26 @@ import { defineConfig } from 'vite';
import { execSync } from 'child_process';
import { SvelteKitPWA } from '@vite-pwa/sveltekit';
import compression from 'vite-plugin-compression';
+import { readFileSync } from 'fs';
+import { join } from 'path';
+
+// Read version from package.json for environment variable injection
+function getPackageVersion(): string {
+ try {
+ const packageJsonPath = join(process.cwd(), 'package.json');
+ const packageJson = JSON.parse(readFileSync(packageJsonPath, 'utf-8'));
+ return packageJson.version || '0.3.2';
+ } catch {
+ return '0.3.2';
+ }
+}
export default defineConfig({
- publicDir: 'public',
+ publicDir: 'static',
+ define: {
+ // Inject version from package.json at build time
+ 'import.meta.env.VITE_APP_VERSION': JSON.stringify(getPackageVersion()),
+ },
plugins: [
sveltekit(),
compression({
@@ -23,6 +40,7 @@ export default defineConfig({
registerType: 'autoUpdate',
workbox: {
globPatterns: ['**/*.{js,css,html,ico,png,svg,woff,woff2,webp,avif}'],
+ maximumFileSizeToCacheInBytes: 3 * 1024 * 1024, // 3 MB to handle large chunks
runtimeCaching: [
{
urlPattern: /^https:\/\/.*\.(?:png|jpg|jpeg|svg|gif|webp|avif)$/i,