mirror of
https://github.com/ajnart/homarr.git
synced 2025-11-12 08:25:47 +01:00
🔀 Merge branch 'dev' into tests/add-tests
This commit is contained in:
@@ -2,7 +2,6 @@ import { ColorScheme, ColorSchemeProvider, MantineProvider, MantineTheme } from
|
||||
import { useColorScheme, useHotkeys, useLocalStorage } from '@mantine/hooks';
|
||||
import { ModalsProvider } from '@mantine/modals';
|
||||
import Consola from 'consola';
|
||||
import { NotificationsProvider } from '@mantine/notifications';
|
||||
import { QueryClientProvider } from '@tanstack/react-query';
|
||||
import { ReactQueryDevtools } from '@tanstack/react-query-devtools';
|
||||
import { getCookie } from 'cookies-next';
|
||||
@@ -11,6 +10,7 @@ import { appWithTranslation } from 'next-i18next';
|
||||
import { AppProps } from 'next/app';
|
||||
import Head from 'next/head';
|
||||
import { useEffect, useState } from 'react';
|
||||
import { Notifications } from '@mantine/notifications';
|
||||
import 'video.js/dist/video-js.css';
|
||||
import { ChangeAppPositionModal } from '../components/Dashboard/Modals/ChangePosition/ChangeAppPositionModal';
|
||||
import { ChangeWidgetPositionModal } from '../components/Dashboard/Modals/ChangePosition/ChangeWidgetPositionModal';
|
||||
@@ -112,21 +112,20 @@ function App(
|
||||
withNormalizeCSS
|
||||
>
|
||||
<ConfigProvider>
|
||||
<NotificationsProvider limit={4} position="bottom-left">
|
||||
<ModalsProvider
|
||||
modals={{
|
||||
editApp: EditAppModal,
|
||||
selectElement: SelectElementModal,
|
||||
integrationOptions: WidgetsEditModal,
|
||||
integrationRemove: WidgetsRemoveModal,
|
||||
categoryEditModal: CategoryEditModal,
|
||||
changeAppPositionModal: ChangeAppPositionModal,
|
||||
changeIntegrationPositionModal: ChangeWidgetPositionModal,
|
||||
}}
|
||||
>
|
||||
<Component {...pageProps} />
|
||||
</ModalsProvider>
|
||||
</NotificationsProvider>
|
||||
<Notifications limit={4} position="bottom-left" />
|
||||
<ModalsProvider
|
||||
modals={{
|
||||
editApp: EditAppModal,
|
||||
selectElement: SelectElementModal,
|
||||
integrationOptions: WidgetsEditModal,
|
||||
integrationRemove: WidgetsRemoveModal,
|
||||
categoryEditModal: CategoryEditModal,
|
||||
changeAppPositionModal: ChangeAppPositionModal,
|
||||
changeIntegrationPositionModal: ChangeWidgetPositionModal,
|
||||
}}
|
||||
>
|
||||
<Component {...pageProps} />
|
||||
</ModalsProvider>
|
||||
</ConfigProvider>
|
||||
</MantineProvider>
|
||||
</ColorTheme.Provider>
|
||||
@@ -150,7 +149,7 @@ App.getInitialProps = ({ ctx }: { ctx: GetServerSidePropsContext }) => {
|
||||
Consola.debug(`Overriding the default color scheme with ${process.env.DEFAULT_COLOR_SCHEME}`);
|
||||
}
|
||||
|
||||
const colorScheme: ColorScheme = process.env.DEFAULT_COLOR_SCHEME as ColorScheme ?? 'light';
|
||||
const colorScheme: ColorScheme = (process.env.DEFAULT_COLOR_SCHEME as ColorScheme) ?? 'light';
|
||||
|
||||
return {
|
||||
colorScheme: getCookie('color-scheme', ctx) || 'light',
|
||||
|
||||
Reference in New Issue
Block a user