feat: Add PWA support and implement drag-and-drop functionality for deck building.
All checks were successful
Build and Deploy / build (push) Successful in 1m28s

This commit is contained in:
2025-12-17 19:16:55 +01:00
parent bf40784667
commit 2bbedfd17f
7 changed files with 4624 additions and 551 deletions

View File

@@ -1,9 +1,34 @@
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
import { VitePWA } from 'vite-plugin-pwa';
import * as path from 'path';
export default defineConfig({
plugins: [react()],
plugins: [
react(),
VitePWA({
registerType: 'autoUpdate',
includeAssets: ['icon.svg'],
manifest: {
name: 'MTG Draft Maker',
short_name: 'MTG Draft',
description: 'Multiplayer Magic: The Gathering Draft Simulator',
theme_color: '#0f172a',
background_color: '#0f172a',
display: 'standalone',
orientation: 'any',
start_url: '/',
icons: [
{
src: 'icon.svg',
sizes: 'any',
type: 'image/svg+xml',
purpose: 'any maskable'
}
]
}
})
],
root: 'client', // Set root to client folder where index.html resides
build: {
outDir: '../dist', // Build to src/dist (outside client)