Added dark theme. Fixed actor country aggregation.
This commit is contained in:
@@ -175,6 +175,16 @@ export default async function initServer() {
|
||||
// TAGS
|
||||
router.get('/api/tags', fetchTagsApi);
|
||||
|
||||
router.use((req, res, next) => {
|
||||
/* eslint-disable no-param-reassign */
|
||||
res.set('Accept-CH', 'Sec-CH-Prefers-Color-Scheme');
|
||||
res.set('Vary', 'Sec-CH-Prefers-Color-Scheme');
|
||||
res.set('Critical-CH', 'Sec-CH-Prefers-Color-Scheme');
|
||||
/* eslint-enable no-param-reassign */
|
||||
|
||||
next();
|
||||
});
|
||||
|
||||
router.get('*', async (req, res, next) => {
|
||||
const unseenNotifications = await fetchUnseenNotificationsCount(req.user);
|
||||
|
||||
@@ -193,6 +203,7 @@ export default async function initServer() {
|
||||
primaryStash: req.user.primaryStash,
|
||||
},
|
||||
env: {
|
||||
theme: req.cookies.theme || req.headers['sec-ch-prefers-color-scheme'] || 'light',
|
||||
allowLogin: config.auth.login,
|
||||
allowSignup: config.auth.signup,
|
||||
maxMatches: config.database.manticore.maxMatches,
|
||||
|
||||
Reference in New Issue
Block a user