fix: storybook font rendering and shared fonts module #1
+14
-6
@@ -1,13 +1,21 @@
|
|||||||
import type { NextConfig } from 'next';
|
import type { NextConfig } from 'next';
|
||||||
|
|
||||||
/* output: 'export' is opt-in via STATIC_EXPORT=true.
|
/* PocketBase origin — used to allowlist remote images.
|
||||||
* Set this in CI/deploy — not locally — so the mock API route works
|
* PB_HOSTNAME and PB_PORT are server-only env vars; safe to read here. */
|
||||||
* during development and local builds. */
|
const pbHostname = process.env.PB_HOSTNAME ?? '127.0.0.1';
|
||||||
const isExport = process.env.STATIC_EXPORT === 'true';
|
const pbPort = parseInt(process.env.PB_PORT ?? '8090', 10);
|
||||||
|
|
||||||
const nextConfig: NextConfig = {
|
const nextConfig: NextConfig = {
|
||||||
...(isExport ? { output: 'export' } : {}),
|
output: 'standalone',
|
||||||
images: { unoptimized: true },
|
images: {
|
||||||
|
remotePatterns: [
|
||||||
|
{
|
||||||
|
protocol: 'http',
|
||||||
|
hostname: pbHostname,
|
||||||
|
port: String(pbPort),
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
experimental: {
|
experimental: {
|
||||||
viewTransition: true,
|
viewTransition: true,
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user