- {lesson.title} + {NOT_ENROLLED_HEADER}
- - {String.prototype.toUpperCase.call(LESSON_TYPE_VIDEO) === - lesson.type && ( -+ {lesson.title} +
+-
- {items.map((item: ComponentScaffoldMenuItem, index: number) =>
- item.href ? (
-
- {
- setOpen(false);
- navigateTo(item.href as string);
- }}
- style={{
- backgroundColor:
- router.asPath === item.href
- ? "#d6d6d6"
- : "inherit",
- }}
- className={`flex items-center px-2 py-3 hover:!bg-slate-100 cursor-pointer ${
- item.icon && item.iconPlacementRight
- ? "justify-between"
- : "justify-start"
- }`}
- >
- {item.icon && !item.iconPlacementRight && (
- {item.icon}- )} -
{item.label as string}
- {item.icon && item.iconPlacementRight && ( -{item.icon}- )} -
- ) : (
- - - {item.label as string} - - ), + {items.map( + (item: ComponentScaffoldMenuItem | Divider, index: number) => + item === "divider" ? ( + + ) : item.href ? ( +
- {
+ setOpen(false);
+ navigateTo(item.href as string);
+ }}
+ style={{
+ backgroundColor:
+ router.asPath === item.href
+ ? "#d6d6d6"
+ : "inherit",
+ }}
+ className={`flex items-center px-2 py-3 hover:!bg-slate-200 cursor-pointer ${
+ item.icon && item.iconPlacementRight
+ ? "justify-between"
+ : "justify-start"
+ }`}
+ >
+ {item.icon && !item.iconPlacementRight && (
+ {item.icon}+ )} +
{item.label as string}
+ {item.icon && item.iconPlacementRight && ( +{item.icon}+ )} +
+ ) : (
+ -
+ {item.label as string}
+ {item.badge &&
{item.badge} } +
+ ),
)}
+ {course.title} +
+ {(profile.fetched + ? !isEnrolled(course.courseId, profile) && + checkPermission(profile.permissions, [ + permissions.enrollInCourse, + ]) + : true) && ( +{profile.fetched}
+