refactored layouts for extra window

This commit is contained in:
zadam
2020-04-25 23:52:13 +02:00
parent 87a1e98fa2
commit 75c58cbf79
16 changed files with 193 additions and 318 deletions

View File

@@ -13,10 +13,6 @@ async function index(req, res) {
let view = req.cookies['trilium-device'] === 'mobile' ? 'mobile' : 'desktop';
if (req.query.extra) {
view = 'extra';
}
const csrfToken = req.csrfToken();
log.info(`Generated CSRF token ${csrfToken} with secret ${res.getHeader('set-cookie')}`);
@@ -30,7 +26,8 @@ async function index(req, res) {
maxSyncIdAtLoad: await sql.getValue("SELECT MAX(id) FROM sync"),
instanceName: config.General ? config.General.instanceName : null,
appCssNoteIds: await getAppCssNoteIds(),
isDev: env.isDev()
isDev: env.isDev(),
isMainWindow: !req.query.extra
});
}