-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #106 from uselagoon/dependency_updates
- Loading branch information
Showing
25 changed files
with
1,604 additions
and
2,481 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,4 +37,4 @@ services: | |
|
||
networks: | ||
amazeeio-network: | ||
external: true | ||
external: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,54 +1,61 @@ | ||
import 'isomorphic-unfetch'; | ||
import App, { Container, createUrl } from 'next/app'; | ||
import React from 'react'; | ||
import Head from 'next/head'; | ||
import getConfig from 'next/config'; | ||
import Typekit from 'react-typekit'; | ||
import Favicon from 'components/Favicon'; | ||
import Authenticator, { AuthContext } from 'lib/Authenticator'; | ||
import ApiConnection from 'lib/ApiConnection'; | ||
import "isomorphic-unfetch"; | ||
import { useRouter } from "next/router"; | ||
import React from "react"; | ||
import Head from "next/head"; | ||
import getConfig from "next/config"; | ||
import Typekit from "react-typekit"; | ||
import Favicon from "components/Favicon"; | ||
import Authenticator, { AuthContext } from "lib/Authenticator"; | ||
import ApiConnection from "lib/ApiConnection"; | ||
import Script from "next/script"; | ||
import App from "next/app"; | ||
|
||
const { serverRuntimeConfig, publicRuntimeConfig } = getConfig(); | ||
|
||
class MyApp extends App { | ||
render() { | ||
const { router, Component, pageProps, err } = this.props; | ||
const url = createUrl(router); | ||
|
||
// Catch runtime errors in production and skip authentication to avoid | ||
// infinite auth > error > auth > error loops. | ||
if (err) { | ||
return ( | ||
<Container> | ||
<Head> | ||
<link rel="stylesheet" href="/static/normalize.css" /> | ||
<Typekit kitId="ggo2pml" /> | ||
</Head> | ||
<Component {...pageProps} errorMessage={err.toString()} url={url} /> | ||
<Favicon /> | ||
</Container> | ||
); | ||
} | ||
|
||
const LagoonApp = ({ Component, pageProps, err }) => { | ||
const { pathname } = useRouter(); | ||
// Catch runtime errors in production and skip authentication to avoid | ||
// infinite auth > error > auth > error loops. | ||
if (err) { | ||
return ( | ||
<Container> | ||
<> | ||
<Head> | ||
<link rel="stylesheet" href="/static/normalize.css" /> | ||
<Typekit kitId="ggo2pml" /> | ||
<script | ||
type="text/javascript" | ||
src={`${publicRuntimeConfig.KEYCLOAK_API}/js/keycloak.js`} | ||
/> | ||
</Head> | ||
<Authenticator> | ||
<ApiConnection> | ||
<Component {...pageProps} url={url} /> | ||
</ApiConnection> | ||
</Authenticator> | ||
<Component | ||
{...pageProps} | ||
errorMessage={err.toString()} | ||
url={pathname} | ||
/> | ||
<Favicon /> | ||
</Container> | ||
</> | ||
); | ||
} | ||
} | ||
|
||
export default MyApp; | ||
return ( | ||
<> | ||
<Script | ||
src={`${publicRuntimeConfig.KEYCLOAK_API}/js/keycloak.js`} | ||
strategy="beforeInteractive" | ||
/> | ||
<Head> | ||
<link rel="stylesheet" href="/static/normalize.css" /> | ||
<Typekit kitId="ggo2pml" /> | ||
</Head> | ||
<Authenticator> | ||
<ApiConnection> | ||
<Component {...pageProps} url={pathname} /> | ||
</ApiConnection> | ||
</Authenticator> | ||
<Favicon /> | ||
</> | ||
); | ||
}; | ||
|
||
LagoonApp.getInitialProps = async (appContext) => { | ||
const appProps = await App.getInitialProps(appContext); | ||
return { ...appProps }; | ||
}; | ||
|
||
export default LagoonApp; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.