Skip to content
Open
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
361 changes: 227 additions & 134 deletions client/package-lock.json

Large diffs are not rendered by default.

9 changes: 6 additions & 3 deletions client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"version": "0.1.0",
"private": true,
"dependencies": {
"@babel/runtime": "^7.28.2",
"@emotion/react": "^11.9.3",
"@emotion/styled": "^11.9.3",
"@mui/icons-material": "^5.8.4",
Expand All @@ -13,11 +14,13 @@
"@testing-library/user-event": "^13.5.0",
"axios": "^0.27.2",
"bootstrap": "^5.2.0",
"framer-motion": "^12.23.12",
"lucide-react": "^0.536.0",
"motion": "^12.23.12",
"rc-drawer": "^5.1.0",
"react": "^18.2.0",
"react-bootstrap": "^2.4.0",
"react-dom": "^18.2.0",
"react": "^18.3.1",
"react-bootstrap": "^2.10.10",
"react-dom": "^18.3.1",
"react-icons": "^5.5.0",
"react-loading": "^2.0.3",
"react-router-dom": "^6.3.0",
Expand Down
Binary file added client/public/default-profile.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
74 changes: 38 additions & 36 deletions client/src/components/Account/Account.css
Original file line number Diff line number Diff line change
@@ -1,46 +1,48 @@

.user__account__container {
height: auto;
min-height: 100vh;
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
background-color: var(--bg-primary);
}

/* Dark mode: black background for account */
.dark-mode .user__account__container {
background-color: #000000;
display: flex;
justify-content: center;
padding: 3rem 1rem;
background: #f8f9fa;
margin-top: 150px;
}

.account__container {
height: 100%;
width: 100%;
padding: 5%;
width: 100%;
max-width: 900px;
background: #fff;
border-radius: 12px;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
padding: 2rem;
display: flex;
flex-direction: column;
gap: 2rem;
}

.account__header {
width: 90%;
height: 80px;
font-size: 2rem;
font-weight: bolder;
.account__header h1 {
font-size: 2rem;
font-weight: bold;
text-align: center;
color: #333;
}

.account__header h1{
width: 100%;
height: auto;
font-size: 2.5rem;
font-weight: bolder;
color: var(--text-primary);
/* Responsive */
@media (max-width: 768px) {
.account__container {
padding: 1.5rem;
gap: 1.5rem;
}

.account__header h1 {
font-size: 1.6rem;
}
}

.account__page__detail {
height: auto;
width: 90%;
display: flex;
flex-direction: row;
justify-content: space-between;
flex-wrap: wrap-reverse;
align-items: flex-start;
}
@media (max-width: 480px) {
.account__container {
padding: 1rem;
}

.account__header h1 {
font-size: 1.4rem;
}
}
8 changes: 4 additions & 4 deletions client/src/components/Account/Account.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
import './Account.css';

const Account = (props) => {
const Account = ({ children }) => {
return (
<div className="user__account__container">
<div className="account__container">
<div className="account__header">
<h1>My account</h1>
</div>
<div className="account__page__detail">
{props.children}
{children}
</div>
</div>
</div>
);
}
export default Account;

export default Account;
198 changes: 108 additions & 90 deletions client/src/components/Account/ManageAccount/ManageAccount.css
Original file line number Diff line number Diff line change
@@ -1,124 +1,142 @@
.manage-account-container {
max-width: 600px;
margin: 2rem auto;
padding: 2rem;
background: #fff;
border-radius: 12px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
font-family: 'Segoe UI', sans-serif;
margin-top: 200px;
}

.manage__account__container {
height: auto;
width: 100%;
display: flex;
flex-direction: column;
justify-content: flex-start;
align-items: flex-start;
margin-top: 20px;
.manage-account-header {
text-align: center;
font-size: 1.8rem;
margin-bottom: 2rem;
color: #222;
}

/* Profile Photo Section */
.profile-photo-section {
display: flex;
flex-direction: column;
align-items: center;
gap: 1rem;
margin-bottom: 2rem;
}

.edit__account__container {
width: 100%;
height: 300px;
.profile-photo-preview {
width: 120px;
height: 120px;
object-fit: cover;
border-radius: 50%;
border: 2px solid #ddd;
}

.edit__account {
width: 250px;
height: 100%;
.custom-upload-button {
display: flex;
align-items: center;
background-color: #007bff;
color: #fff;
padding: 0.6rem 1rem;
border-radius: 6px;
font-size: 0.9rem;
cursor: pointer;
transition: background-color 0.2s ease;
}

.edit__account__header {
width:100%;
height: 20%;
font-size: 1.7rem;
font-weight: bolder;
.custom-upload-button:hover {
background-color: #0056b3;
}

.edit__account__form__container {
width:100%;
height: 80%;
/* Form Section */
.account-form {
display: flex;
flex-direction: column;
gap: 1.2rem;
}

.edit__account__form {
width:100%;
height: 100%;
.form-group {
display: flex;
flex-direction: column;
}

.edit__input__container {
height:35%;
width: 100%;
.form-label {
margin-bottom: 0.3rem;
font-weight: 500;
color: #333;
}

.edit__account__input {
height: 50%;
width: 100%;
.form-input {
padding: 0.7rem 1rem;
border: 1px solid #ccc;
border-radius: 6px;
font-size: 1rem;
transition: border-color 0.2s ease;
}

.save__changes__button__container {
height: 30%;
width: 100%;
display: flex;
justify-content: flex-start;
align-items: center;
.form-input::placeholder {
color: #aaa;
font-style: italic;
text-align: start;
}

.save__changes__button {
height: 60%;
width: 50%;
font-size: 1rem;
background-color: #FFE26E;
border-color: #FFE26E;
border-style: dashed;
font-weight:bold;
.form-input:focus {
border-color: #007bff;
outline: none;
}

.separator__line {
margin-top: 20px;
height: 5px;
width: 50%;
background-color: #FFE26E;
/* Buttons */
.actions {
display: flex;
justify-content: space-between;
margin-top: 2rem;
flex-wrap: wrap;
gap: 1rem;
}

/* Delete account form */
.save-btn,
.delete-btn {
flex: 1;
min-width: 140px;
padding: 0.7rem 1rem;
font-size: 1rem;
border-radius: 6px;
cursor: pointer;
border: none;
transition: background-color 0.2s ease;
}

.delete_account__container {
width: 250px;
height: 200px;
display: flex;
justify-content: flex-start;
align-items: center;
.save-btn {
background-color: #28a745;
color: #fff;
}

.delete__account {
height: 100%;
width: 100%;
display: flex;
justify-content: flex-start;
align-self: flex-start;
flex-direction: column;
.save-btn:hover {
background-color: #218838;
}

.delete__account__header {
width: 100%;
height: 30%;
display: flex;
justify-content: flex-start;
align-items: center;
font-size: 1.7rem;
font-weight: bolder;
.delete-btn {
background-color: #dc3545;
color: #fff;
}

.delete__account__prompt {
height: 35%;
width: 100%;
.delete-btn:hover {
background-color: #c82333;
}

.delete__account__button__container {
height: 35%;
/* Responsive */
@media (max-width: 500px) {
.manage-account-container {
padding: 1.5rem 1rem;
}

.actions {
flex-direction: column;
}

.save-btn,
.delete-btn {
width: 100%;
display: flex;
justify-content: flex-start;
}

.delete__account__button {
height: 45px;
width: 160px;
font-size: 1rem;
background-color: #ff6e6e;
border-color: #ff6e6e;
border-style: dashed;
font-weight:bold;
}
}
}
Loading