- Nowdatabase
+ NOW Database
Site under construction.
-
- This version is running on test data. May contain incorrect and outdated information.
-
+ {ENV !== 'prod' && (
+
+ This version is running on test data. May contain incorrect and outdated information.
+
+ )}
Project repository:{' '}
https://github.com/nowcommunity/nowdatabase
@@ -17,6 +20,13 @@ export const FrontPage = () => {
"New Issue" -button on this page:{' '}
GitHub Issues
+
+ The old application: https://nowdatabase.luomus.fi/
+
+
+ Information about the database and NOW community:{' '}
+ https://nowdatabase.org/
+
)
}
diff --git a/frontend/src/components/NavBar.tsx b/frontend/src/components/NavBar.tsx
index 063c4fb2..d40b3bf1 100644
--- a/frontend/src/components/NavBar.tsx
+++ b/frontend/src/components/NavBar.tsx
@@ -6,6 +6,7 @@ import { api } from '../redux/api'
import { MouseEvent, useState } from 'react'
import { Role } from '@/types'
import { useUser } from '@/hooks/user'
+import { ENV } from '@/util/config'
type LinkDefinition = { title: string; url: string; children?: LinkDefinition[]; allowedRoles?: Role[] }
@@ -108,12 +109,17 @@ export const NavBar = () => {
)
}
+ const getModeText = () => {
+ if (ENV === 'staging') return '(test)'
+ if (ENV === 'dev') return '(dev)'
+ return ''
+ }
return (