Skip to content

Commit

Permalink
Updated about.jsx
Browse files Browse the repository at this point in the history
  • Loading branch information
shamvrueth committed Nov 4, 2024
1 parent 2db9ef6 commit 1a5be72
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/views/About.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@ import "../styles/about.css";
import styled from 'styled-components';
import CountUp from 'react-countup';
import VisibilitySensor from 'react-visibility-sensor';
import { useState } from 'react';
import { useState, useEffect } from 'react';
import { useNavigate } from 'react-router-dom';
import TeamMembers from '../components/TeamCarousel';
import { width } from '@mui/system';
import AOS from 'aos';
const About = ({ mode, textcolor }) => {
const [viewed, setViewed] = useState({
users: false,
Expand All @@ -21,6 +22,11 @@ const About = ({ mode, textcolor }) => {
hospitals: false,
});

useEffect(() => {
AOS.init({ duration: 2000 });
AOS.refresh();
}, [mode]);

const navigate = useNavigate();
const sloganStyle = {
color: mode === 'dark' ? '#FFFFFF' : textcolor, // Use white for dark mode, otherwise use textcolor
Expand All @@ -32,7 +38,7 @@ const About = ({ mode, textcolor }) => {


{/* Hero Section */}
<div className="slogan" data-aos="zoom-in" data-aos-duration="2000" style={{marginTop:'3.5rem'}>
<div className="slogan" data-aos="zoom-in" data-aos-duration="2000" style={{marginTop:'3.5rem'}}>
<h2>"Your Fitness, Your Future!"</h2>
<h3 style={{ backgroundColor: mode === 'dark' ? '#111118' : '#ffffff', color: textcolor }}>- FitFlex Motto</h3>
<p style={{ backgroundColor: mode === 'dark' ? '#111118' : '#ffffff', color: textcolor }}>
Expand All @@ -47,6 +53,7 @@ const About = ({ mode, textcolor }) => {
sx={{
background: mode === 'dark' ? 'linear-gradient(135deg, #000000, #444444)' : '#fff',
color: mode === 'dark' ? '#fff' : '#000',
ml: 2
}}
data-aos="fade-right"
data-aos-delay="200"
Expand All @@ -66,6 +73,7 @@ const About = ({ mode, textcolor }) => {
sx={{
background: mode === 'dark' ? 'linear-gradient(135deg, #000000, #444444)' : '#fff',
color: mode === 'dark' ? '#fff' : '#000',
ml: 2
}}
data-aos="fade-left"
data-aos-delay="200"
Expand Down

0 comments on commit 1a5be72

Please sign in to comment.