Skip to content

📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!

(add) other page for field passwod and some improvments

kruzhambusd6ec2b4c0bbb
diff --git a/src/App.tsx b/src/App.tsx
index bf6832f36..78137c366 100644
--- a/src/App.tsx
+++ b/src/App.tsx
@@ -62,6 +62,7 @@ const MediaAndPress = lazy(() => import('pages/Press'))
const TransferProjectConfirm = lazy(() => import('pages/Project/Settings/TransferProject/TransferProjectConfirm'))
const TransferProjectReject = lazy(() => import('pages/Project/Settings/TransferProject/TransferProjectReject'))
const Socialised = lazy(() => import('pages/Auth/Socialised'))
+const ProjectProtectedPassword = lazy(() => import('pages/Project/ProjectProtectedPassword'))
const minimalFooterPages = [
'/projects', '/dashboard', '/settings', '/contact',
@@ -242,6 +243,7 @@ const App = () => {
<Route path={routes.transfer_confirm} component={TransferProjectConfirm} exact />
<Route path={routes.transfer_reject} component={TransferProjectReject} exact />
<Route path={routes.socialised} component={Socialised} exact />
+ <Route path={routes.project_protected_password} component={ProjectProtectedPassword} exact />
<Route path='*' component={NotFound} />
</Switch>
</Suspense>
diff --git a/src/pages/Project/ProjectProtectedPassword/index.tsx b/src/pages/Project/ProjectProtectedPassword/index.tsx
new file mode 100644
index 000000000..2771ca140
--- /dev/null
+++ b/src/pages/Project/ProjectProtectedPassword/index.tsx
@@ -0,0 +1,7 @@
+import React from 'react'
+
+const ProjectProtectedPassword = () => {
+ return <div>ProjectProtectedPassword</div>
+}
+
+export default ProjectProtectedPassword
diff --git a/src/pages/Project/View/ViewProject.tsx b/src/pages/Project/View/ViewProject.tsx
index cb7f6a647..ed749c223 100644
--- a/src/pages/Project/View/ViewProject.tsx
+++ b/src/pages/Project/View/ViewProject.tsx
@@ -1398,9 +1398,11 @@ const ViewProject = ({
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [chartType])
- if (project.isPasswordProtected && _isEmpty(passwordHash)) {
+ // if (project.isPasswordProtected && _isEmpty(passwordHash)) {
+ // eslint-disable-next-line no-constant-condition
+ if (true) {
// write password modal
- return ''
+ return <div>asdsa</div>
}
if (!isLoading) {
diff --git a/src/routes.ts b/src/routes.ts
index 6bb9bab82..f63f5ae51 100644
--- a/src/routes.ts
+++ b/src/routes.ts
@@ -30,6 +30,7 @@ const routes = Object.freeze({
transfer_confirm: '/project/transfer/confirm',
transfer_reject: '/project/transfer/cancel',
socialised: '/socialised',
+ project_protected_password: '/projects/:id/password',
})
export default routes