mirror of
https://github.com/Qortal/Qortal-Hub.git
synced 2025-04-19 01:35:54 +00:00
added pwa for desktop
This commit is contained in:
parent
60ee1084da
commit
fbe876951d
3369
package-lock.json
generated
3369
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -89,6 +89,7 @@
|
||||
"tippy.js": "^6.3.7",
|
||||
"tiptap-extension-resize-image": "^1.1.8",
|
||||
"ts-key-enum": "^2.0.12",
|
||||
"vite-plugin-pwa": "^0.21.1",
|
||||
"vite-plugin-top-level-await": "^1.4.4",
|
||||
"vite-plugin-wasm": "^3.3.0"
|
||||
},
|
||||
|
BIN
public/qortal.png
Normal file
BIN
public/qortal.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 158 KiB |
BIN
public/qortal192.png
Normal file
BIN
public/qortal192.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 32 KiB |
@ -18,7 +18,6 @@ import { mailsAtom, qMailLastEnteredTimestampAtom } from '../../atoms/global';
|
||||
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';
|
||||
import ExpandLessIcon from '@mui/icons-material/ExpandLess';
|
||||
import MarkEmailUnreadIcon from '@mui/icons-material/MarkEmailUnread';
|
||||
import { last } from 'slate';
|
||||
export const isLessThanOneWeekOld = (timestamp) => {
|
||||
// Current time in milliseconds
|
||||
const now = Date.now();
|
||||
|
@ -5,6 +5,7 @@ import react from '@vitejs/plugin-react';
|
||||
import fixReactVirtualized from 'esbuild-plugin-react-virtualized'
|
||||
import wasm from 'vite-plugin-wasm';
|
||||
import topLevelAwait from 'vite-plugin-top-level-await';
|
||||
import { VitePWA } from 'vite-plugin-pwa';
|
||||
|
||||
export default defineConfig({
|
||||
|
||||
@ -14,7 +15,34 @@ export default defineConfig({
|
||||
setupFiles: ['./src/test/setup.ts']
|
||||
},
|
||||
assetsInclude: ['**/*.wasm'],
|
||||
plugins: [react(), wasm(), topLevelAwait()],
|
||||
plugins: [react(), wasm(), topLevelAwait(), VitePWA({
|
||||
registerType: 'prompt',
|
||||
manifest: {
|
||||
name: 'Qortal Hub',
|
||||
short_name: 'Hub',
|
||||
description: 'Your easy access to the Qortal blockchain',
|
||||
start_url: '/',
|
||||
display: 'standalone',
|
||||
theme_color: '#ffffff',
|
||||
background_color: '#ffffff',
|
||||
icons: [
|
||||
{
|
||||
src: '/qortal192.png',
|
||||
sizes: '192x192',
|
||||
type: 'image/png',
|
||||
},
|
||||
{
|
||||
src: '/qortal.png',
|
||||
sizes: '512x512',
|
||||
type: 'image/png',
|
||||
},
|
||||
],
|
||||
},
|
||||
workbox: {
|
||||
maximumFileSizeToCacheInBytes: 5 * 1024 * 1024, // 5MB limit
|
||||
disableDevLogs: true, // Suppresses logs in development
|
||||
},
|
||||
})],
|
||||
optimizeDeps: {
|
||||
esbuildOptions: {
|
||||
plugins: [fixReactVirtualized],
|
||||
|
Loading…
x
Reference in New Issue
Block a user