Skip to content

Commit bebc572

Browse files
added responsiveness in admin.jsx
1 parent 605f2bb commit bebc572

File tree

6 files changed

+11
-10
lines changed

6 files changed

+11
-10
lines changed

admin/src/components/Dashboard/DashboardPage.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const DashboardPage = () => {
2525
return (
2626
<div className="dashboard flex">
2727

28-
<div className="flex flex-col max-md:w-full max-md:ml-0 ml-[20%] w-[80%] p-4 py-6 bg-gray-100">
28+
<div className="flex flex-col max-md:w-full max-md:ml-0 w-screen p-4 py-6 bg-gray-100">
2929

3030
<div className="flex w-[100%] items-center justify-between mb-6">
3131
<h1 className="text-xl max-md:ml-1 max-md:w-[90%] font-semibold text-gray-800">

admin/src/components/Dashboard/Logo.jsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ See the License for the specific language governing permissions and
1515
limitations under the License.
1616
*/
1717

18-
import React from "react";
18+
1919
const Logo = () => {
2020
return (
21-
<div className="flex items-center gap-2"> {/* Removed styling classes and w-full */}
22-
<img src="/logo/EduMatrix2.png" className="h-14 w-auto object-contain" alt="EduMatrix Logo" /> {/* Increased height to h-14 */}
23-
<p className="font-bold text-2xl text-gray-800">EduMatrix</p> {/* Increased text size to text-2xl */}
21+
<div className="flex justify-center items-center gap-1"> {/* Removed styling classes and w-full */}
22+
<img src="/logo/EduMatrix2.png" className="h-12 rounded-full object-contain" alt="EduMatrix Logo" /> {/* Increased height to h-14 */}
23+
<p className="font-bold text-4xl text-white ">EduMatrix</p> {/* Increased text size to text-2xl */}
2424
</div>
2525
);
2626
};

admin/src/components/Student/Students.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ function Students() {
217217
</form>
218218
</div>
219219
</div>
220-
</div>
220+
221221
);
222222
}
223223

admin/src/shared/Sidebar.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ const Sidebar = () => {
7777
<ul className="flex flex-col px-3 w-full h-full"> {/* Removed md:ml-10, added px-3 */}
7878
{/* Fixed Logo */}
7979
{/* Added p-4 and background to this sticky div. Note: p-4 on this div inside a px-3 ul means logo area has more effective padding. This could be adjusted if needed. */}
80-
<div className="sticky top-0 z-20 p-4 bg-gradient-to-tr from-indigo-800 to-blue-700 -mx-3"> {/* Added -mx-3 to make this div full-bleed against parent's px-3 */}
80+
<div className="sticky top-3 z-20 p-3 max-md:mt-10 max-md:w-[300px] rounded-full mb-8 border-blue-500 border "> {/* Added -mx-3 to make this div full-bleed against parent's px-3 */}
8181
<Logo />
8282
</div>
8383
{/* Scrollable nav items */}
@@ -285,7 +285,7 @@ const Sidebar = () => {
285285
onClick={toggleMobileMenu}
286286
className="p-2 rounded-md bg-blue-700 text-white"
287287
>
288-
{isMobileMenuOpen ? <CloseIcon /> : <MenuIcon />}
288+
{isMobileMenuOpen ? <CloseIcon className="text-white bg-red-700 rounded-md w-6 h-6" /> : <MenuIcon className="text-white" />}
289289
</button>
290290
</div>
291291

client/src/pages/Home/HomePage.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ const HomePage = () => {
100100

101101
<div className="flex gap-5 max-md:flex-col-reverse justify-center items-center">
102102
<div className="flex flex-col gap-3 cursor-pointer">
103-
{CardUtils.map((props) => (
104-
<CardComponent {...props} />
103+
{CardUtils.map((props, index) => (
104+
<CardComponent key={index} {...props} />
105105
))}
106106
</div>
107107

client/src/shared/Sidebar.jsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+

0 commit comments

Comments
 (0)