Skip to content

Commit 48ec79e

Browse files
committed
Add first draft for Activity log behind feature flag
1 parent 1ecfcf4 commit 48ec79e

File tree

5 files changed

+61
-2
lines changed

5 files changed

+61
-2
lines changed

src/App.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import InfoScreenPrivacy from "./screens/info-screen/InfoScreenPrivacy";
1414
import OnboardingWelcomeTopics from "./screens/onboarding-welcome/OnboardingWelcomeTopics";
1515
import InfoScreenNewOrExistingUser from "./screens/info-screen/InfoScreenNewOrExistingUser";
1616
import ProfileScreen from "./screens/profile-screen/ProfileScreen";
17+
import ActivityLogScreen from "./screens/activity-log/ActivityLogScreen";
1718
import {LanguageProvider} from "./language/LanguageContext";
1819

1920
const theme = createTheme({});
@@ -39,6 +40,7 @@ const App = () => {
3940
<Route path="/profile-section/:benefitId" element={<ProfileSectionScreen/>}/>
4041
<Route path="/benefit-page/:id" element={<BenefitPageScreen/>}/>
4142
<Route path="/profile-overview" element={<ProfileScreen/>}/>
43+
<Route path="/activity-log" element={<ActivityLogScreen/>}/>
4244
</Routes>
4345
</div>
4446
</Router>

src/featureFlags.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ const defaultFlags = {
22
newFeedbackSection: true,
33
newCollaborationSection: true,
44
newLanguageToggle: false,
5+
newActivityLog: false,
56
};
67

78
const getFeatureFlag = (flag) => {
@@ -13,6 +14,7 @@ const featureFlags = {
1314
newFeedbackSection: getFeatureFlag('newFeedbackSection'),
1415
newCollaborationSection: getFeatureFlag('newCollaborationSection'),
1516
newLanguageToggle: getFeatureFlag('newLanguageToggle'),
17+
newActivityLog: getFeatureFlag('newActivityLog'),
1618
};
1719

1820
export const setFeatureFlag = (flag, value) => {

src/language/translations.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ const translations = {
88
principles: "Principles",
99
aboutUs: "About us",
1010
improve: "Help us improve",
11-
collaborate: "Collaborate"
11+
collaborate: "Collaborate",
12+
activityLog: "Activity log"
1213
},
1314
hero: {
1415
header: "Check benefits and financial support you can get",
@@ -28,7 +29,8 @@ const translations = {
2829
principles: "Prinzipien",
2930
aboutUs: "Über uns",
3031
improve: "Hilf uns, besser zu werden",
31-
collaborate: "Zusammenarbeit"
32+
collaborate: "Zusammenarbeit",
33+
activityLog: "Aktivitätsprotokoll"
3234
},
3335
hero: {
3436
header: "Finde heraus, welche Leistungen und finanzielle Unterstützung du bekommen könntest",
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
import React from "react";
2+
import {Typography} from "@mui/material";
3+
import VStack from "../../components/VStack";
4+
import InfoScreen from "../info-screen/components/InfoScreen";
5+
6+
const ActivityLogScreen = () => {
7+
return (
8+
<InfoScreen title={'Activity log'}>
9+
<VStack sx={styles.infoBox}>
10+
<Typography sx={styles.infoText}>
11+
<strong>What's happening at the moment:</strong>
12+
<ul>
13+
<li>
14+
A collaboration with ZenDiS is shaping up
15+
</li>
16+
<li>
17+
We applied for some grants &#129310;
18+
</li>
19+
</ul>
20+
</Typography>
21+
<Typography sx={styles.infoText}>
22+
<strong>Milestones in the past:</strong>
23+
<ul>
24+
<li>
25+
<em>2024-09-17</em> Add feedback and collaboration section
26+
</li>
27+
<li>
28+
<em>2024-09-03</em> Live with a first version of 10 social benefits for the <a href="https://prototypefund.de/demo-day/">Prototype Fund
29+
Demo Day</a>
30+
</li>
31+
</ul>
32+
</Typography>
33+
</VStack>
34+
</InfoScreen>
35+
);
36+
}
37+
38+
const styles = {
39+
infoText: {
40+
fontSize: '20px',
41+
textAlign: 'left',
42+
},
43+
infoBox: {
44+
width: '100%',
45+
}
46+
}
47+
48+
export default ActivityLogScreen;

src/screens/landing-page/sections/header/views/HeaderBarDesktop.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@ const HeaderBarDesktop = ({isApp}) => {
1818
{isApp ? null : <LandingPageWAppButton backgroundColor={'primary'}/>}
1919
{isApp ? null : <LandingPageHollowButton text={t('menu.improve')} to={'/#feedback'}/>}
2020
{isApp ? null : <LandingPageHollowButton text={t('menu.collaborate')} to={'/#collaboration'}/>}
21+
{isApp ? null :
22+
featureFlags.newActivityLog ?
23+
<LandingPageHollowButton text={t('menu.activityLog')} to={'/activity-log'}/>
24+
: null
25+
}
2126
</HStack>
2227
<HStack>
2328
<NarBarLink to={"/#about-us"} title={t('menu.aboutUs')}/>

0 commit comments

Comments
 (0)