fix: mobile onboarding viewport + filebrowser demo fixes
Onboarding: - Fixed viewport to use dvh units with position:fixed container - All views use scrollable glass containers that fit within viewport - Responsive typography and spacing (mobile-first breakpoints) - Tighter padding/margins on small screens - RootRedirect checks localStorage first for instant redirect - Spinner only appears after 500ms delay to avoid flash Filebrowser: - Fix CloudFolder null initialPath crash (watch both useNativeUI + section) - Remove unused `host` computed (was causing TS error) - Add mock GET /app/filebrowser/ landing page - Increase express.json limit to 50mb Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
4bc0c4b483
commit
a6c1820a83
@@ -40,7 +40,7 @@ const corsOptions = {
|
||||
}
|
||||
|
||||
app.use(cors(corsOptions))
|
||||
app.use(express.json())
|
||||
app.use(express.json({ limit: '50mb' }))
|
||||
app.use(cookieParser())
|
||||
|
||||
// Mock session storage
|
||||
@@ -1340,6 +1340,15 @@ const MOCK_FILE_CONTENTS = {
|
||||
'/Documents/backup-log.json': JSON.stringify({ backups: [{ id: 'bkp-2025-03-01', timestamp: '2025-03-01T02:00:00Z', type: 'full', apps: ['bitcoin-knots', 'lnd', 'mempool'], size_mb: 2340, status: 'success' }] }, null, 2),
|
||||
}
|
||||
|
||||
// FileBrowser UI (demo placeholder when launched directly)
|
||||
app.get('/app/filebrowser/', (req, res) => {
|
||||
res.type('html').send(`<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1">
|
||||
<title>File Browser</title><style>*{margin:0;padding:0;box-sizing:border-box}body{background:#1a1a2e;color:#e0e0e0;font-family:system-ui,sans-serif;display:flex;align-items:center;justify-content:center;min-height:100vh}
|
||||
.card{background:rgba(0,0,0,0.4);border:1px solid rgba(255,255,255,0.1);border-radius:16px;padding:48px;text-align:center;max-width:400px;backdrop-filter:blur(20px)}
|
||||
h1{font-size:24px;margin-bottom:12px}p{color:rgba(255,255,255,0.6);font-size:14px;line-height:1.6}</style></head>
|
||||
<body><div class="card"><h1>File Browser</h1><p>File Browser is running. Use the Cloud page in Archipelago to manage your files.</p></div></body></html>`)
|
||||
})
|
||||
|
||||
// FileBrowser login - return mock JWT
|
||||
app.post('/app/filebrowser/api/login', (req, res) => {
|
||||
res.send('"mock-filebrowser-token-demo"')
|
||||
|
||||
Reference in New Issue
Block a user