Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
531b385
add initial db setup
vtotalova Nov 25, 2025
6871c30
remove redundant fields in db
vtotalova Dec 2, 2025
5e76c47
Merge branch 'main' into feature/db-setup
vtotalova Dec 2, 2025
377fab2
fix CI and code quality issues
vtotalova Dec 2, 2025
f114fa8
remove manually migration, update db setup
vtotalova Dec 3, 2025
f8c2983
Merge branch 'main' into feature/db-setup
vtotalova Dec 3, 2025
2b86a16
check resolved
vtotalova Dec 3, 2025
515d35f
Merge branch 'feature/db-setup' of github.com:ls1intum/memo into feat…
vtotalova Dec 3, 2025
68bf56e
feat: enhance database schema and migration system
vtotalova Dec 3, 2025
5c538fe
style: fix prettier formatting
vtotalova Dec 3, 2025
0d2d8dd
docs: clarify Prisma Studio usage and DATABASE_URL
vtotalova Dec 9, 2025
1b6cb4f
docs: clarify database setup and .env file usage
vtotalova Dec 9, 2025
626561c
remove unnecessary code
vtotalova Dec 9, 2025
9b19b68
fix npm Ci issues
vtotalova Dec 9, 2025
1bffd0d
update doc
vtotalova Dec 9, 2025
c7fe36a
fix CI issued
vtotalova Dec 9, 2025
a7f4c7f
fix inconsistency between prisma clinet and db setup file
vtotalova Dec 10, 2025
abb04f0
Update prisma/migrations/20251203125815_init/migration.sql
vtotalova Dec 10, 2025
791f7f3
Update prisma/schema.prisma
vtotalova Dec 10, 2025
555c4b7
set up domain core
vtotalova Dec 10, 2025
b3f6bc6
Merge branch 'feature/db-setup' into feature/setup-domain-core-db-com…
vtotalova Dec 10, 2025
0fefd69
fix code formatting issues
vtotalova Dec 10, 2025
1e768ae
fix: export RelationshipType from domain core and update imports
vtotalova Dec 10, 2025
1df11b0
Merge branch 'main' into feature/setup-domain-core-db-communication
vtotalova Dec 10, 2025
ab4d9f2
move prisma build stage upper
vtotalova Dec 10, 2025
3e271ef
Merge branch 'feature/setup-domain-core-db-communication' of github.c…
vtotalova Dec 10, 2025
89eae3f
cosmetic minor changes
vtotalova Dec 15, 2025
c0da752
fix test code issues
vtotalova Dec 15, 2025
90e8429
feat: streamline design and update page content
markstockhausen Dec 16, 2025
375b283
style: fix invalid Tailwind spacing and replace remote images with pl…
markstockhausen Dec 16, 2025
8fb7df0
Merge remote-tracking branch 'origin/feature/landing-about-design-upd…
markstockhausen Dec 16, 2025
e63ea1b
feat: add database seeding with demo user and competencies
markstockhausen Dec 16, 2025
4f3e3e7
feat: refine session flow with competency fetching, tooltips, badges,…
markstockhausen Dec 16, 2025
71902f4
feat: impement competency relation adding and undo functionality
markstockhausen Dec 16, 2025
b4fa25d
feat: enhance competency relation adding and add undo functionality
markstockhausen Dec 16, 2025
37acd88
chore: enhance code style
markstockhausen Dec 16, 2025
b43eb04
chore: fix session suspense and lint issues
markstockhausen Dec 16, 2025
7c2cd5e
chore: implement AI suggestions
markstockhausen Dec 16, 2025
4e92a93
Resolve conflicts with main
markstockhausen Dec 23, 2025
7785e0a
chore: resolve merge conflicts
markstockhausen Dec 23, 2025
4cb5dde
chore: resolve merge conflicts
markstockhausen Dec 23, 2025
622d4cc
chore: update references
markstockhausen Dec 23, 2025
b72d851
chore: add getRandomCompetencies()
markstockhausen Dec 23, 2025
b34375a
chore: update component
markstockhausen Dec 23, 2025
4715055
style: conform to Prettier formatting
markstockhausen Dec 23, 2025
6daa23a
refactor: remove server action overhead
markstockhausen Jan 11, 2026
b2dac0c
style: fix format
markstockhausen Jan 11, 2026
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
10 changes: 10 additions & 0 deletions DATABASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ npm run db:migrate
| `db:studio` | Open Prisma Studio GUI |
| `db:reset` | Reset database (⚠️ destroys data) |
| `db:generate` | Regenerate Prisma Client |
| `db:seed` | Seed demo user + competencies |

## Common Tasks

Expand Down Expand Up @@ -88,6 +89,15 @@ npx prisma migrate status
npm run db:reset
```

**Seed demo content (user + 5 competencies):**

```bash
npm run db:seed
```

Creates a demo user (`demo@memo.local`) and 5 sample competencies. Idempotent, safe to run multiple
times.

## Schema

See [prisma/schema.prisma](prisma/schema.prisma) for the complete schema.
Expand Down
15 changes: 15 additions & 0 deletions app/actions/competencies.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,21 @@ export async function getAllCompetenciesAction() {
}
}

export async function getRandomCompetenciesAction(count: number = 2) {
try {
const competencies = await competencyService.getRandomCompetencies(count);
return { success: true, competencies };
} catch (error) {
return {
success: false,
error:
error instanceof Error
? error.message
: 'Failed to fetch random competencies',
};
}
}

export async function updateCompetencyAction(
id: string,
title?: string,
Expand Down
29 changes: 29 additions & 0 deletions app/actions/users.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,32 @@ export async function deleteUserAction(id: string) {
};
}
}

/**
* Gets or creates the demo user for development/testing purposes.
* Returns the demo user with email 'demo@memo.local'.
*/
export async function getOrCreateDemoUserAction() {
try {
// Try to find existing demo user
let user = await userService.getUserByEmail('demo@memo.local');

// If not found, create it
if (!user) {
user = await userService.createUser({
name: 'Demo User',
email: 'demo@memo.local',
});
}

return { success: true, user };
} catch (error) {
return {
success: false,
error:
error instanceof Error
? error.message
: 'Failed to get or create demo user',
};
}
}
90 changes: 0 additions & 90 deletions app/dashboard/page.tsx

This file was deleted.

28 changes: 17 additions & 11 deletions app/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,17 +35,10 @@ const [leadProblem, ...otherProblems] = problemStatements;
export default function Page() {
return (
<div className="relative min-h-screen overflow-hidden bg-gradient-to-br from-[#d7e3ff] via-[#f3f5ff] to-[#e8ecff] text-slate-900">
<div className="absolute inset-0 -z-10 opacity-70">
<div className="absolute left-1/2 top-[-6rem] h-[36rem] w-[36rem] -translate-x-1/2 rounded-full bg-white/80 blur-[140px]" />
<div className="absolute left-[10%] top-[22%] h-80 w-80 rounded-full bg-[#7fb0ff]/35 blur-[120px]" />
<div className="absolute right-[14%] top-[28%] h-[22rem] w-[22rem] rounded-[40%] bg-gradient-to-br from-[#ffdff3]/55 via-[#fff3f8]/35 to-transparent blur-[140px]" />
</div>
<LiquidGlassGradient />

<main className="relative z-20 mx-auto flex w-full max-w-6xl flex-col gap-28 px-6 pb-4 pt-[11.5rem] lg:px-0">
<section
id="overview"
className="grid items-center gap-16 pb-8 animate-in fade-in slide-in-from-bottom-4 duration-700"
>
<section id="overview" className="grid items-center gap-16 pb-8">
<div className="space-y-12">
<div className="space-y-8">
<h1 className="text-balance text-[3.2rem] font-semibold leading-[1.04] tracking-tight text-slate-900 sm:text-[3.9rem] lg:text-[4.9rem]">
Expand All @@ -66,7 +59,7 @@ export default function Page() {
className="h-12 rounded-full bg-[#0a4da2] px-7 text-base font-semibold text-white shadow-[0_18px_45px_-26px_rgba(7,30,84,0.75)] transition hover:bg-[#0d56b5]"
asChild
>
<a href="/onboarding">Start Contributing</a>
<a href="/session">Start Contributing</a>
</Button>
</div>
<div className="relative flex justify-center pt-20 pb-12">
Expand Down Expand Up @@ -125,7 +118,7 @@ export default function Page() {

<section
id="challenges"
className="relative isolate left-1/2 right-1/2 w-screen -translate-x-1/2 transform px-6 pb-[8.5rem] pt-32 lg:px-0 -mt-24"
className="relative isolate left-1/2 right-1/2 w-screen -translate-x-1/2 transform px-6 pb-12 pt-32 lg:px-0 -mt-24"
>
<div className="absolute inset-0 bg-white" aria-hidden />
<div
Expand Down Expand Up @@ -191,3 +184,16 @@ export default function Page() {
</div>
);
}

function LiquidGlassGradient() {
return (
<div className="pointer-events-none absolute inset-0 -z-10 overflow-hidden">
<div className="absolute inset-0 bg-[radial-gradient(circle_at_top,_rgba(255,255,255,0.9),_rgba(237,242,255,0.6))]" />
<div className="absolute left-1/2 top-[-8rem] h-[44rem] w-[44rem] -translate-x-1/2 rounded-[50%] bg-white/80 blur-[140px] opacity-85 mix-blend-screen" />
<div className="absolute left-[12%] top-[22%] h-80 w-80 rounded-full bg-[#7fb0ff]/40 blur-[120px] mix-blend-screen" />
<div className="absolute right-[18%] top-[30%] h-[26rem] w-[24rem] rounded-[40%] bg-gradient-to-br from-[#ffdff3]/65 via-[#fff3f8]/45 to-transparent blur-[150px] mix-blend-screen" />
<div className="absolute bottom-[-10rem] left-1/2 h-[36rem] w-[50rem] -translate-x-1/2 rounded-[220px] bg-white/70 blur-[160px] opacity-95 mix-blend-screen" />
<div className="absolute left-1/3 top-[58%] h-72 w-72 rounded-full bg-[#9ce8d1]/35 blur-[130px] mix-blend-screen" />
</div>
);
}
Loading