Mobile PWA port of the desktop console: bottom-sheet modals, card-list record views, bottom tab nav, vite-plugin-pwa (manifest, service worker, icons). API layer, workflow UIDs, and design tokens reused verbatim.
34 lines
923 B
TypeScript
34 lines
923 B
TypeScript
import { defineConfig } from 'vite'
|
|
import react from '@vitejs/plugin-react'
|
|
import tailwindcss from '@tailwindcss/vite'
|
|
import { VitePWA } from 'vite-plugin-pwa'
|
|
|
|
// https://vite.dev/config/
|
|
export default defineConfig({
|
|
plugins: [
|
|
react(),
|
|
tailwindcss(),
|
|
VitePWA({
|
|
registerType: 'autoUpdate',
|
|
pwaAssets: { image: 'public/logo.svg' },
|
|
manifest: {
|
|
name: 'Krishna Sales',
|
|
short_name: 'Krishna',
|
|
description: 'Field Sales console',
|
|
theme_color: '#0B1B3B',
|
|
background_color: '#0B1B3B',
|
|
display: 'standalone',
|
|
orientation: 'portrait',
|
|
start_url: '/orders',
|
|
scope: '/',
|
|
},
|
|
workbox: {
|
|
navigateFallback: '/index.html',
|
|
navigateFallbackDenylist: [/^\/usr\//, /^\/app\//],
|
|
globPatterns: ['**/*.{js,css,html,svg,png,ico,woff2}'],
|
|
},
|
|
devOptions: { enabled: false },
|
|
}),
|
|
],
|
|
})
|