35b4519b94
- fix(pwa): iOS keyboard gap caused by WebKit viewport-fit=cover bug. After keyboard open/close, 100dvh permanently shrinks. Track max innerHeight in --app-height CSS variable as stable replacement. - feat(pwa): auto-prompt notification permission on first login in standalone mode (once only, skips if denied). - refactor: remove duplicate notification toggle from header menu (already in Settings). - feat(dev): expose Vite dev server on network (host: true) for mobile testing via Tailscale. - docs: update README — add Task Progress FAB, fix notification flow description, document OPENAI_API_KEY / VAPID_EMAIL env vars, clarify voice input backends, add CLI --version/--help, update .env.example. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
69 lines
1.8 KiB
TypeScript
69 lines
1.8 KiB
TypeScript
import { defineConfig } from 'vite';
|
|
import react from '@vitejs/plugin-react';
|
|
import tailwindcss from '@tailwindcss/vite';
|
|
import { VitePWA } from 'vite-plugin-pwa';
|
|
import path from 'path';
|
|
|
|
export default defineConfig({
|
|
plugins: [
|
|
react(),
|
|
tailwindcss(),
|
|
VitePWA({
|
|
strategies: 'injectManifest',
|
|
srcDir: 'src',
|
|
filename: 'sw.ts',
|
|
registerType: 'autoUpdate',
|
|
manifest: {
|
|
name: 'ClawTap',
|
|
short_name: 'ClawTap',
|
|
description: 'Control Claude Code from your phone',
|
|
theme_color: '#09090b',
|
|
background_color: '#09090b',
|
|
display: 'standalone',
|
|
orientation: 'portrait',
|
|
scope: '/',
|
|
start_url: '/',
|
|
icons: [
|
|
{ src: '/pwa-192x192.png', sizes: '192x192', type: 'image/png' },
|
|
{ src: '/pwa-512x512.png', sizes: '512x512', type: 'image/png' },
|
|
{ src: '/maskable-512x512.png', sizes: '512x512', type: 'image/png', purpose: 'maskable' },
|
|
],
|
|
shortcuts: [
|
|
{
|
|
name: 'New Chat',
|
|
short_name: 'New',
|
|
url: '/?action=newchat',
|
|
icons: [{ src: '/pwa-192x192.png', sizes: '192x192' }],
|
|
},
|
|
],
|
|
categories: ['developer-tools', 'productivity'],
|
|
},
|
|
injectManifest: {
|
|
globPatterns: ['**/*.{js,css,html,ico,svg,woff2}', 'favicon-*.png', 'apple-touch-icon.png', 'badge-*.png', 'mascot/*.png'],
|
|
},
|
|
}),
|
|
],
|
|
resolve: {
|
|
alias: {
|
|
'@': path.resolve(__dirname, './src'),
|
|
},
|
|
},
|
|
server: {
|
|
host: true,
|
|
proxy: {
|
|
'/api': {
|
|
target: 'https://localhost:3456',
|
|
secure: false,
|
|
},
|
|
'/ws': {
|
|
target: 'wss://localhost:3456',
|
|
ws: true,
|
|
secure: false,
|
|
},
|
|
},
|
|
},
|
|
build: {
|
|
outDir: 'dist',
|
|
},
|
|
});
|