mirror of
https://github.com/stonith404/pingvin-share.git
synced 2025-01-29 01:28:59 -05:00
Merge branch 'development' into main
This commit is contained in:
commit
603f3db3e3
2 changed files with 5 additions and 2 deletions
|
@ -17,6 +17,8 @@ Demo: https://pingvin-share.dev.eliasschneider.com
|
||||||
|
|
||||||
## ⌨️ Setup
|
## ⌨️ Setup
|
||||||
|
|
||||||
|
> Pleas note that Pingvin Share is in early stage and could include some bugs
|
||||||
|
|
||||||
1. Download the `docker-compose.yml` and `.env.example` file.
|
1. Download the `docker-compose.yml` and `.env.example` file.
|
||||||
2. Rename the `.env.example` file to `.env` and change the environment variables so that they fit to your environment. If you need help with the environment variables take a look [here](#environment-variables)
|
2. Rename the `.env.example` file to `.env` and change the environment variables so that they fit to your environment. If you need help with the environment variables take a look [here](#environment-variables)
|
||||||
3. Run `docker-compose up -d`
|
3. Run `docker-compose up -d`
|
||||||
|
|
|
@ -37,6 +37,7 @@ function App(
|
||||||
|
|
||||||
const getInitalData = async () => {
|
const getInitalData = async () => {
|
||||||
setIsLoading(true);
|
setIsLoading(true);
|
||||||
|
await authService.refreshAccessToken();
|
||||||
setUser(await userService.getCurrentUser());
|
setUser(await userService.getCurrentUser());
|
||||||
setIsLoading(false);
|
setIsLoading(false);
|
||||||
};
|
};
|
||||||
|
@ -47,7 +48,7 @@ function App(
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
setCookies("mantine-color-scheme", systemTheme, {
|
setCookies("color-schema", systemTheme, {
|
||||||
maxAge: 60 * 60 * 24 * 30,
|
maxAge: 60 * 60 * 24 * 30,
|
||||||
});
|
});
|
||||||
setColorScheme(systemTheme);
|
setColorScheme(systemTheme);
|
||||||
|
@ -90,6 +91,6 @@ export default App;
|
||||||
|
|
||||||
App.getInitialProps = ({ ctx }: { ctx: GetServerSidePropsContext }) => {
|
App.getInitialProps = ({ ctx }: { ctx: GetServerSidePropsContext }) => {
|
||||||
return {
|
return {
|
||||||
colorScheme: getCookie("mantine-color-scheme", ctx) || "light",
|
colorScheme: getCookie("color-schema", ctx) || "light",
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Reference in a new issue