+
{facility}
diff --git a/src/app/components/NavigationBar.tsx b/src/app/components/NavigationBar.tsx
index 1a653f9..e25846f 100644
--- a/src/app/components/NavigationBar.tsx
+++ b/src/app/components/NavigationBar.tsx
@@ -22,6 +22,9 @@ const russoOne = Russo_One({
});
const NavigationBar = () => {
+ const [textColor, setTextColor] = useState(
+ window.innerWidth <= 767 ? "black" : "white"
+ );
const buttonBRef = useRef(null);
const [collapseClasses, setCollapseClasses] = useState("");
@@ -32,7 +35,17 @@ const NavigationBar = () => {
useEffect(() => {
let headroom = new Headroom(document.getElementById("navbar-main")!);
headroom.init();
- });
+
+ const handleResize = () => {
+ setTextColor(window.innerWidth <= 767 ? "black" : "white");
+ };
+
+ window.addEventListener("resize", handleResize);
+
+ return () => {
+ window.removeEventListener("resize", handleResize);
+ };
+ }, []);
const handleButtonClick = () => {
if (window.innerWidth <= 767 && buttonBRef.current) {
@@ -51,9 +64,9 @@ const NavigationBar = () => {
>
-
+
Atul Vidhyajyot
-
+