diff --git a/client/public/Somaiya.jpg b/client/public/Somaiya.jpg new file mode 100644 index 0000000..660b421 Binary files /dev/null and b/client/public/Somaiya.jpg differ diff --git a/client/src/App.css b/client/src/App.css index 511542b..fe20edc 100644 --- a/client/src/App.css +++ b/client/src/App.css @@ -22,8 +22,8 @@ } body { - background-color: #96aefb; - background: linear-gradient(to right, #dab8fc, #afc2ff); + background-color:#ffffff; + /* background: linear-gradient(to right, #dab8fc, #afc2ff); */ display: flex; align-items: center; justify-content: center; diff --git a/client/src/App.js b/client/src/App.js index ff01a0a..ee5983c 100644 --- a/client/src/App.js +++ b/client/src/App.js @@ -5,6 +5,8 @@ import AuthPage from "./Pages/Login"; import HomePage from "./Pages/HomePage"; import ForgetPwPage from "./Pages/ForgetPw"; import ResetPwPage from "./Pages/ResetPw"; +import FilterPage from "./Pages/FilterPage"; +import WelcomeWithFilter from "./Pages/WelcomeWithFilter"; import "react-toastify/dist/ReactToastify.css"; function App() { @@ -12,10 +14,12 @@ function App() { }> + } /> }> }> }> }> + } /> ); diff --git a/client/src/Pages/FilterPage.css b/client/src/Pages/FilterPage.css new file mode 100644 index 0000000..8e3dce8 --- /dev/null +++ b/client/src/Pages/FilterPage.css @@ -0,0 +1,53 @@ +.filter-container { + text-align: center; + margin-top: 30px; + } + + .filter-form select, + .filter-form button { + margin: 10px; + padding: 8px; + } + + .table-container { + margin-top: 20px; + display: flex; + justify-content: center; + } + + .table-container table { + width: 80%; + border-collapse: collapse; + } + + .table-container th, + .table-container td { + border: 1px solid #ddd; + padding: 8px; + } + + .table-container th { + background-color: maroon; + color: white; + } + + .active-button { + background-color: #800000; /* Highlight color */ + color: white; + border: none; + padding: 10px 20px; + cursor: pointer; + } + + button { + margin: 5px; + padding: 10px 20px; + cursor: pointer; + background-color: #ddd; + border: 1px solid #ccc; + } + + button:hover { + background-color: #ccc; + } + \ No newline at end of file diff --git a/client/src/Pages/FilterPage.jsx b/client/src/Pages/FilterPage.jsx new file mode 100644 index 0000000..b026251 --- /dev/null +++ b/client/src/Pages/FilterPage.jsx @@ -0,0 +1,71 @@ +import React, { useState } from "react"; +import "./FilterPage.css"; + +const FilterPage = ({ onApplyFilter }) => { + const [selectedOption, setSelectedOption] = useState(null); + const [formData, setFormData] = useState({ + scheme: "", + year: "", + }); + + const handleInputChange = (e) => { + const { name, value } = e.target; + setFormData({ ...formData, [name]: value }); + }; + + const handleApplyFilter = () => { + if (!formData.scheme || !formData.year) { + alert("Please select both Scheme and Year before applying the filter."); + return; + } + if (!selectedOption) { + alert("Please select either 'Course' or 'Faculty' before applying the filter."); + return; + } + onApplyFilter(); // Trigger the table display + }; + + const handleSelectOption = (option) => { + setSelectedOption(option); + }; + + return ( +
+
+ + + + + +
+
+ ); +}; + +export default FilterPage; diff --git a/client/src/Pages/Navbar.css b/client/src/Pages/Navbar.css new file mode 100644 index 0000000..e69de29 diff --git a/client/src/Pages/Navbar.jsx b/client/src/Pages/Navbar.jsx new file mode 100644 index 0000000..e69de29 diff --git a/client/src/Pages/Welcom.css b/client/src/Pages/Welcom.css new file mode 100644 index 0000000..4d3f5b8 --- /dev/null +++ b/client/src/Pages/Welcom.css @@ -0,0 +1,27 @@ +.welcom-container { + text-align: center; + margin-top: 50px; + } + + .welcom-message h1 { + font-size: 2rem; + margin-bottom: 10px; + } + + .welcom-message p { + font-size: 1.2rem; + color: #555; + } + + .next-button { + padding: 10px 20px; + background-color: maroon; + color: white; + border: none; + cursor: pointer; + } + + .next-button:hover { + background-color: darkred; + } + \ No newline at end of file diff --git a/client/src/Pages/Welcom.jsx b/client/src/Pages/Welcom.jsx new file mode 100644 index 0000000..e955afd --- /dev/null +++ b/client/src/Pages/Welcom.jsx @@ -0,0 +1,25 @@ +import React from "react"; +import { useNavigate } from "react-router-dom"; +import "./Welcom.css"; + +const Welcom = () => { + const navigate = useNavigate(); + + const goToFilterPage = () => { + navigate("/Filter"); + }; + + return ( +
+
+

Welcome, John Doe

+

You’re signed in as DEC/EIC

+
+ +
+ ); +}; + +export default Welcom; diff --git a/client/src/Pages/WelcomeWithFilter.css b/client/src/Pages/WelcomeWithFilter.css new file mode 100644 index 0000000..f1a94fb --- /dev/null +++ b/client/src/Pages/WelcomeWithFilter.css @@ -0,0 +1,126 @@ +.welcome-with-filter-container { + display: flex; + flex-direction: column; + height: 100vh; + font-family: "Arial", sans-serif; + background-color: #ffffff; + } + + /* Filter Section (Top) */ + .filter-section { + display: flex; + padding: 10px 20px; + background-color: #800000; /* Dark red background */ + gap: 10px; + justify-content: center; + flex-wrap: wrap; /* Makes the items wrap if screen width is small */ + } + + .filter-section select, + .filter-section button { + flex: 1; /* Fields will take up equal space */ + max-width: 200px; /* Ensures fields don't get too wide */ + padding: 8px 12px; + border-radius: 5px; + border: none; + font-size: 14px; + text-align: center; + } + + .filter-section select { + background-color: #fff; + color: #333; + transition: border 0.3s ease; + } + + .filter-section select:focus { + border: 2px solid #b22222; /* Highlighted border on focus */ + } + + .filter-section button { + background-color: #b22222; + color: #fff; + cursor: pointer; + transition: background-color 0.3s ease, transform 0.2s ease; + } + + .filter-section button:hover, + .filter-section button:focus { + background-color: #a50000; /* Darker red for hover/active state */ + transform: scale(1.05); /* Subtle enlargement */ + } + + /* Welcome Section */ + .welcome-section { + display: flex; + flex: 1; + flex-direction: row; + align-items: center; + justify-content: space-between; + padding: 20px; + } + + .welcome-content { + flex: 1; + padding: 20px; + display: flex; + flex-direction: column; + justify-content: center; + text-align: left; + } + + .welcome-message h1 { + font-size: 32px; + font-weight: bold; + color: #333; + margin-bottom: 10px; + } + + .welcome-message p { + font-size: 18px; + color: #555; + } + + .image-container { + flex: 1; + height: 100%; + overflow: hidden; + } + + .welcome-image { + width: 100%; + height: 100%; + object-fit: cover; + } + + /* Table Styling */ + .table-container { + width: 90%; + margin: 20px auto; + background-color: #fff; + border-radius: 8px; + box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); + } + + table { + width: 100%; + border-collapse: collapse; + } + + table th, + table td { + border: 1px solid #ddd; + padding: 10px; + text-align: center; + font-size: 14px; + } + + table th { + background-color: #f4f4f4; + font-weight: bold; + } + + table tr:hover { + background-color: #f9f9f9; + } + \ No newline at end of file diff --git a/client/src/Pages/WelcomeWithFilter.jsx b/client/src/Pages/WelcomeWithFilter.jsx new file mode 100644 index 0000000..d0834c7 --- /dev/null +++ b/client/src/Pages/WelcomeWithFilter.jsx @@ -0,0 +1,64 @@ +import React, { useState } from "react"; +import FilterPage from "./FilterPage"; +import "./WelcomeWithFilter.css"; + +const WelcomeWithFilter = () => { + const [showTable, setShowTable] = useState(false); // State to toggle between table and welcome content + + const handleApplyFilter = () => { + setShowTable(true); // Show table and replace the welcome content + }; + + return ( +
+ {/* Filter Section */} +
+ +
+ + {/* Lower Section */} +
+ {showTable ? ( + // Show the table when 'Apply Filter' is clicked +
+ + + + + + + + + + {Array.from({ length: 10 }).map((_, index) => ( + + + + + + ))} + +
Course IDCourse NameAvailability
Course-{index + 1}Sample CourseAvailable
+
+ ) : ( + // Show the welcome content by default +
+
+

Welcome, John Doe

+

You’re signed in as DEC/EIC

+
+
+ Welcome Illustration +
+
+ )} +
+
+ ); +}; + +export default WelcomeWithFilter;