feat(dashboard): add content page options menu (#757)

* feat(dashboard): add content page options menu

Add a three-dot menu on the course Content page with actions to unlock
all locked lessons/exercises and toggle content grouping. Reuse shared
locked-content collection logic from course settings.

Co-authored-by: Rotimi Best <[email protected]>

* fix(dashboard): keep unlock-all enabled and add menu icons

Show a success snackbar when all content is already unlocked instead of
disabling the action. Add lock-open and table-of-contents icons to menu items.

Co-authored-by: Rotimi Best <[email protected]>

* fix(dashboard): check courseApi.update return for grouping toggle

Use the update() return value instead of courseApi.success, which can be
false after a successful PUT if the follow-up refresh request fails.

Co-authored-by: Rotimi Best <[email protected]>

---------

Co-authored-by: Rotimi Best <[email protected]>
This commit is contained in:
Rotimi Best
2026-07-15 22:28:23 +01:00
committed by GitHub
co-authored by Rotimi Best
parent bfafc685e0
commit 656fa4fa7e
14 changed files with 231 additions and 26 deletions
@@ -289,7 +289,10 @@
"successful_integration": "Integración exitosa",
"successful_deletion": "Integración eliminada",
"update_successful": "Actualización exitosa",
"unlocked_all_content": "Todos los elementos del curso desbloqueados"
"unlocked_all_content": "Todos los elementos del curso desbloqueados",
"all_content_already_unlocked": "Todo el contenido ya está desbloqueado",
"content_grouping_enabled": "Agrupación de contenidos activada",
"content_grouping_disabled": "Agrupación de contenidos desactivada"
}
},
"people": {
@@ -1320,6 +1323,12 @@
"add_content_create_lesson": "Crear lección",
"add_content_section_title_placeholder": "por ejemplo, Módulo 1: Introducción",
"add_content_lesson_title_placeholder": "por ejemplo, Introducción a las variables",
"content_menu": {
"label": "Opciones de contenido",
"unlock_all": "Desbloquear todo el contenido",
"enable_grouping": "Activar agrupación de contenidos",
"disable_grouping": "Desactivar agrupación de contenidos"
},
"join_lesson": "Unirse a la lección",
"no_link": "Sin enlace",
"no_tutor": "No se agregó ningún tutor",