diff --git a/src/components/Greeting.tsx b/src/components/Greeting.tsx
index d52ecc7e3..38f265e41 100644
--- a/src/components/Greeting.tsx
+++ b/src/components/Greeting.tsx
@@ -5,10 +5,12 @@ export const Greeting = () => {
const currentHour = new Date().getHours();
// Determine the appropriate greeting based on the time of day
- let greeting = 'Good Morning';
- if (currentHour >= 12 && currentHour < 18) {
+ let greeting;
+ if (currentHour >= 4 && currentHour < 12) {
+ greeting = 'Good Morning';
+ } else if (currentHour >= 12 && currentHour < 17) {
greeting = 'Good Afternoon';
- } else if (currentHour >= 18 || currentHour < 5) {
+ } else if (currentHour >= 17 && currentHour <= 20) {
greeting = 'Good Evening';
} else {
greeting = 'Surprise to see you here!';
diff --git a/src/components/Sidebar.tsx b/src/components/Sidebar.tsx
index 10614e6e0..c3e70dd37 100644
--- a/src/components/Sidebar.tsx
+++ b/src/components/Sidebar.tsx
@@ -101,6 +101,7 @@ export function Sidebar({
currentUrlContentId,
);
setCurrentActiveContentIds(pathArray || []);
+ setSidebarOpen(false);
}
}
}, [pathName, findPathToContent, fullCourseContent]);
diff --git a/src/components/profile-menu/ProfileDropdown.tsx b/src/components/profile-menu/ProfileDropdown.tsx
index d70504847..84a52359a 100644
--- a/src/components/profile-menu/ProfileDropdown.tsx
+++ b/src/components/profile-menu/ProfileDropdown.tsx
@@ -20,7 +20,6 @@ import {
} from '@/components/ui/dropdown-menu';
import ExternalLinks from './ExternalLinks';
import { signOut } from 'next-auth/react';
-import { SelectTheme } from '../ThemeToggler';
const ProfileDropdown = () => {
const menuItemLinks = [
@@ -78,10 +77,6 @@ const ProfileDropdown = () => {
-
-
-
-
{
signOut();