Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge to Prod #171

Open
wants to merge 21 commits into
base: prod
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Brain Exercise Initative 🧠

## About
Brain Exercise Initative is a nonprofit focused on preventing memory loss through brain exercise. Through innovative research in Japan, it was found that doing simple math and reading exercises aloud caused improvements in cognitive function. Brain Exercise Initiative builds off of this research, holding brain exercise programs at retirement homes.

Brain Exercise Initative is a nonprofit focused on preventing memory loss through brain exercise. Through innovative research in Japan, it was found that doing simple math and reading exercises aloud caused improvements in cognitive function. Brain Exercise Initiative builds off of this research, holding brain exercise programs at retirement homes.

## Getting Started

Expand All @@ -20,7 +20,6 @@ yarn install

Install [MongoDB Community Server](https://www.mongodb.com/docs/manual/administration/install-community/) to host a local instance of MongoDB. It may also be helpful to download [MongoDB Compass](https://www.mongodb.com/try/download/compass#compass) to view the state of your database.


### Environment Variables

In the root directory, run one of these commands based on your OS:
Expand Down
69 changes: 37 additions & 32 deletions common_utils/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,38 +117,36 @@ export interface IAnalytics {
totalSessionsCompleted: number;
active: boolean;
streak: Days[];
lastSessionsMetrics: [
{
date: Date;
math: {
attempted: boolean;
questionsAttempted: number;
questionsCorrect: number;
finalDifficultyScore: number;
timePerQuestion: number;
};
trivia: {
attempted: boolean;
questionsAttempted: number;
questionsCorrect: number;
timePerQuestion: number;
};
reading: {
attempted: boolean;
passagesRead: number;
timePerPassage: number;
wordsPerMinute: number;
questionsAnswered: number;
skipped: boolean;
};
writing: {
attempted: boolean;
questionsAnswered: number;
timePerQuestion: number;
skipped: boolean;
};
},
];
lastSessionMetrics: {
date: Date;
math: {
attempted: boolean;
questionsAttempted: number;
questionsCorrect: number;
finalDifficultyScore: number;
timePerQuestion: number;
};
trivia: {
attempted: boolean;
questionsAttempted: number;
questionsCorrect: number;
timePerQuestion: number;
};
reading: {
attempted: boolean;
passagesRead: number;
timePerPassage: number;
wordsPerMinute: number;
questionsAnswered: number;
skipped: boolean;
};
writing: {
attempted: boolean;
questionsAnswered: number;
timePerQuestion: number;
skipped: boolean;
};
};
weeklyMetrics: [
{
date: Date;
Expand Down Expand Up @@ -351,6 +349,7 @@ export interface IAggregatedAnalyticsAll
IAggregatedAnalyticsMath,
IAggregatedAnalyticsTrivia,
IAggregatedAnalyticsReading,
PatientStats,
IAggregatedAnalyticsWriting {}

export interface IAggregatedAnalyticsOverall {
Expand Down Expand Up @@ -436,6 +435,7 @@ export interface IAggregatedGroupAnalyticsAll
IAggregatedGroupAnalyticsMath,
IAggregatedGroupAnalyticsReading,
IAggregatedGroupAnalyticsWriting,
PatientStats,
IAggregatedGroupAnalyticsTrivia {}

export type IAggregatedGroupAnalyticsOverall = {
Expand Down Expand Up @@ -466,6 +466,11 @@ export type IAggregatedGroupAnalyticsWriting = {
};
};

export interface PatientStats {
totalPatients: number;
activePatients: number;
}

export interface IGeneralReducer {
pendingApprovals: number;
}
Expand Down
Binary file added public/assets/logo-netlify-large.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading