fix: Library page LessonListItem Edit/Delete buttons non-functional #24
Labels
No labels
backend
bug
completed
documentation
duplicate
enhancement
feature
frontend
good first issue
help wanted
in-progress
invalid
performance
phase-1
Phase1
Phase2
Phase3
planning
question
refactor
security
test
testing
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Kalle/ATM#24
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
In the Library page (
src/app/[locale]/library/page.tsx), theLessonListItemcomponent has Edit and Delete buttons with empty onClick handlers:Expected Behavior
LessonEditModalwith the selected lessonCurrent State
LessonEditModaland haseditingLessonstatesetEditingLessonsetter exists but is not connected to these buttonsDatabaseAPI.deleteLesson()but is not connectedProposed Fix
Connect the existing state management to the button handlers:
Acceptance Criteria
Priority
HIGH — Basic CRUD operations should work
Files to Modify
src/app/[locale]/library/page.tsx— Connect button handlers✅ Fixed in commit
ebc4448Changes Made
LessonCard & LessonListItem Components:
onEditprop to both componentsLessonEditModalwith lesson dataDatabaseAPI.deleteLesson()Files Modified
src/app/[locale]/library/page.tsx— Connected button handlers, added onEdit prop