166 lines
4.6 KiB
TypeScript
166 lines
4.6 KiB
TypeScript
export default defineNuxtConfig({
|
|
ssr: false,
|
|
compatibilityDate: "2024-11-01",
|
|
devtools: { enabled: true },
|
|
modules: ["vuetify-nuxt-module", "@vite-pwa/nuxt", "motion-v/nuxt"],
|
|
app: {
|
|
head: {
|
|
titleTemplate: "%s • MonacoUSA Portal",
|
|
title: "MonacoUSA Portal",
|
|
meta: [
|
|
{ property: "og:title", content: "MonacoUSA Portal" },
|
|
{ property: "og:image", content: "/og-image.png" },
|
|
{ name: "twitter:card", content: "summary_large_image" },
|
|
{ name: "viewport", content: "width=device-width, initial-scale=1" },
|
|
{ name: "apple-mobile-web-app-capable", content: "yes" },
|
|
{ name: "apple-mobile-web-app-status-bar-style", content: "default" },
|
|
{ name: "apple-mobile-web-app-title", content: "MonacoUSA Portal" },
|
|
],
|
|
htmlAttrs: {
|
|
lang: "en",
|
|
},
|
|
},
|
|
},
|
|
pwa: {
|
|
registerType: 'autoUpdate',
|
|
manifest: {
|
|
name: 'MonacoUSA Portal',
|
|
short_name: 'MonacoUSA',
|
|
description: 'MonacoUSA Portal - Unified dashboard for tools and services',
|
|
theme_color: '#a31515',
|
|
background_color: '#ffffff',
|
|
display: 'standalone',
|
|
orientation: 'portrait',
|
|
start_url: '/',
|
|
scope: '/',
|
|
icons: [
|
|
{
|
|
src: '/icons/icon-72x72.png',
|
|
sizes: '72x72',
|
|
type: 'image/png'
|
|
},
|
|
{
|
|
src: '/icons/icon-96x96.png',
|
|
sizes: '96x96',
|
|
type: 'image/png'
|
|
},
|
|
{
|
|
src: '/icons/icon-128x128.png',
|
|
sizes: '128x128',
|
|
type: 'image/png'
|
|
},
|
|
{
|
|
src: '/icons/icon-144x144.png',
|
|
sizes: '144x144',
|
|
type: 'image/png'
|
|
},
|
|
{
|
|
src: '/icons/icon-152x152.png',
|
|
sizes: '152x152',
|
|
type: 'image/png'
|
|
},
|
|
{
|
|
src: '/icons/icon-192x192.png',
|
|
sizes: '192x192',
|
|
type: 'image/png'
|
|
},
|
|
{
|
|
src: '/icons/icon-384x384.png',
|
|
sizes: '384x384',
|
|
type: 'image/png'
|
|
},
|
|
{
|
|
src: '/icons/icon-512x512.png',
|
|
sizes: '512x512',
|
|
type: 'image/png'
|
|
}
|
|
]
|
|
},
|
|
workbox: {
|
|
navigateFallback: '/',
|
|
globPatterns: ['**/*.{js,css,html,png,jpg,jpeg,svg,ico}'],
|
|
navigateFallbackDenylist: [/^\/api\//],
|
|
runtimeCaching: [
|
|
{
|
|
urlPattern: /^https:\/\/.*\.monacousa\.org\/.*/i,
|
|
handler: 'NetworkFirst',
|
|
options: {
|
|
cacheName: 'api-cache',
|
|
expiration: {
|
|
maxEntries: 10,
|
|
maxAgeSeconds: 60 * 60 * 24 // 24 hours
|
|
},
|
|
cacheableResponse: {
|
|
statuses: [0, 200]
|
|
}
|
|
}
|
|
}
|
|
],
|
|
skipWaiting: true,
|
|
clientsClaim: true
|
|
},
|
|
client: {
|
|
installPrompt: true,
|
|
periodicSyncForUpdates: 20
|
|
},
|
|
devOptions: {
|
|
enabled: true,
|
|
type: 'module'
|
|
}
|
|
},
|
|
nitro: {
|
|
experimental: {
|
|
wasm: true
|
|
}
|
|
},
|
|
runtimeConfig: {
|
|
// Server-side configuration
|
|
keycloak: {
|
|
issuer: process.env.NUXT_KEYCLOAK_ISSUER || "",
|
|
clientId: process.env.NUXT_KEYCLOAK_CLIENT_ID || "monacousa-portal",
|
|
clientSecret: process.env.NUXT_KEYCLOAK_CLIENT_SECRET || "",
|
|
callbackUrl: process.env.NUXT_KEYCLOAK_CALLBACK_URL || "https://monacousa.org/auth/callback",
|
|
},
|
|
nocodb: {
|
|
url: process.env.NUXT_NOCODB_URL || "",
|
|
token: process.env.NUXT_NOCODB_TOKEN || "",
|
|
baseId: process.env.NUXT_NOCODB_BASE_ID || "",
|
|
},
|
|
minio: {
|
|
endPoint: process.env.NUXT_MINIO_ENDPOINT || "s3.monacousa.org",
|
|
port: parseInt(process.env.NUXT_MINIO_PORT || "443"),
|
|
useSSL: process.env.NUXT_MINIO_USE_SSL !== "false",
|
|
accessKey: process.env.NUXT_MINIO_ACCESS_KEY || "",
|
|
secretKey: process.env.NUXT_MINIO_SECRET_KEY || "",
|
|
bucketName: process.env.NUXT_MINIO_BUCKET_NAME || "monacousa-portal",
|
|
},
|
|
sessionSecret: process.env.NUXT_SESSION_SECRET || "",
|
|
encryptionKey: process.env.NUXT_ENCRYPTION_KEY || "",
|
|
public: {
|
|
// Client-side configuration
|
|
appName: "MonacoUSA Portal",
|
|
domain: process.env.NUXT_PUBLIC_DOMAIN || "monacousa.org",
|
|
},
|
|
},
|
|
vuetify: {
|
|
vuetifyOptions: {
|
|
theme: {
|
|
defaultTheme: "monacousa",
|
|
themes: {
|
|
monacousa: {
|
|
colors: {
|
|
primary: "#a31515",
|
|
secondary: "#ffffff",
|
|
accent: "#f5f5f5",
|
|
error: "#ff5252",
|
|
warning: "#ff9800",
|
|
info: "#2196f3",
|
|
success: "#4caf50",
|
|
},
|
|
},
|
|
},
|
|
},
|
|
},
|
|
},
|
|
});
|