Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default dark mode#164 #168

Merged
merged 2 commits into from
Jun 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions client/src/components/auth/expert/ExpertSignup.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Link, useNavigate } from "react-router-dom";
import axios from "axios";
import { motion } from "framer-motion";
import { useTheme } from "../../providers/ThemeProvider";

import image1 from "../../../assets/img1.png";
const ExpertSignup = () => {
const { isDarkMode } = useTheme();
const navigate = useNavigate();
Expand Down Expand Up @@ -115,7 +115,7 @@ const ExpertSignup = () => {
<button
onClick={addAvatar}
type="button"
className=" mt-6 bg-green-400 w-32 h-12 rounded-lg text-xl border-none hover:bg-green-500 active:bg-green-600"
className=" mt-6 bg-green-400 w-32 h-12 text-xl border-none rounded-3xl mb-6 hover:bg-green-500 active:bg-green-600"
>
Add Avatar
</button>
Expand Down Expand Up @@ -237,6 +237,7 @@ const ExpertSignup = () => {
</motion.form>
</div>
<div className={`flex-1 flex flex-col items-center justify-center bg-card-custom-gradient p-3 ${isDarkMode ? 'bg-card-custom-gradient' :' bg-teal-500 text-white'}`}>
<img src={image1}alt="Hello" height={300} width={300}/>
<h1 className="text-white text-2xl font-[serif]">Already a registered expert?</h1>
<Link to='/expertlogin'>
<motion.button
Expand Down
2 changes: 1 addition & 1 deletion client/src/components/auth/student/StudentSignup.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ const StudentSignup = () => {
type="submit"
className="mt-4 bg-teal-500 text-white font-bold text-md py-3 px-8 rounded-full transition-all hover:bg-teal-600"
whileHover={{ scale: 1.05 }}
whileTap={{ scale: 0.95 }}
whileTap={{ scale: 0.95 }}
>
Sign up
</motion.button>
Expand Down
2 changes: 1 addition & 1 deletion client/src/components/providers/ThemeProvider.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const ThemeContext = createContext();


export const ThemeProvider = ({ children }) => {
const [isDarkMode, setIsDarkMode] = useState(false);
const [isDarkMode, setIsDarkMode] = useState(true);

const toggleTheme = () => {
setIsDarkMode(prevMode => !prevMode);
Expand Down