Skip to content

Commit

Permalink
Successfully added the nav bar & button to the People's page
Browse files Browse the repository at this point in the history
  • Loading branch information
Jenpj234 committed Jan 17, 2025
1 parent 9d55544 commit 1578d18
Show file tree
Hide file tree
Showing 2 changed files with 68 additions and 22 deletions.
67 changes: 57 additions & 10 deletions views/js/evently/src/HostList.css
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,22 @@ body {
}

.host-button {
display: inline-block; /* Ensures it doesn't stretch */
margin: 0 auto; /* Centers it if the parent has a fixed width */
text-align: center;
background-color: #0047ff;
color: #fff;
padding: 10px 20px;
font-size: 1rem;
background-color: #007bff; /* Button background color */
color: #fff; /* Button text color */
border: none; /* Remove border */
padding: 0.75rem 1rem; /* Adjust padding as needed */
border: none;
border-radius: 5px;
border-radius: 5rem; /* Optional: Rounds the button edges */
font-size: 1.2rem;
outline: none;
margin: 2rem;
cursor: pointer; /* Pointer cursor on hover */
transition: background 0.25s;
text-decoration: none;
}

.host-button:hover {
background-color: #0036cc;
background-color: #0056b3; /* Darker shade on hover */
}

table {
Expand Down Expand Up @@ -63,7 +65,7 @@ table th, table td {
max-width: 1200px;
margin: 20px auto; /* Centers the grid */
background-color: #d9d9d9;
padding: 30px 10px 140px 20px;
background-attachment: fixed;
}

.accountContainer {
Expand Down Expand Up @@ -101,3 +103,48 @@ table th, table td {
}


.nav-bar-container {
display: flex;
justify-content: center;
align-items: center;
width: 100%; /* Full width */
background: #fff; /* Optional: Background color */
margin: 0; /* Remove default body margin if needed */
}


.account-search-bar {
--padding: 14px;

width: max-content;
display: flex;
align-items: center; /* Align items in the navbar vertically */
gap: 8px; /* Optional: Adds spacing between the button and the navbar content */
padding: var(--padding);
border-radius: 28px;
background: #f6f6f6;
transition: background 0.25s;
}

.account-search-bar:focus-within {
background: #f1f1f1;
}

.account-search-bar input {
font-size: 16px;
font-family: 'Lexend', sans-serif;
color: #333333;
margin-left: var(--padding);
outline: none;
border: none;
background: transparent;
flex: 1;
width: 300px;
padding: 0;
margin-bottom: 0;
}

.account-search-input::placeholder {
color: rgba(0, 0, 0, 0.2)
}

23 changes: 11 additions & 12 deletions views/js/evently/src/HostList.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@ function HostList() {
<div className="header">
<h1>Discover New People</h1>
</div>
<Link to="/create-host" className="host-button">
Join now
</Link>

{/* <table>
<thead>
Expand Down Expand Up @@ -74,10 +71,14 @@ function HostList() {
*/}


<div className="search-bar">
<button className="search-btn"> 🔍 </button>
<input type="text" placeholder="Start Your Search Here!" />

<div class="nav-bar-container">
<Link to="/create-host" className="host-button">Join now</Link>
<div class="account-search-bar">
<span class="account-search-btn"> 🔍</span>
<input class="account-search-input" type="text" placeholder="Start Your Search Here!" />
</div>
</div>


<div class="peopleSection">
Expand All @@ -87,10 +88,10 @@ function HostList() {
<div class="accountInfo">
<img src={profileImage1} alt="Profile picture" className="profile-image" />
</div>
<p>John Doe</p>
<p>Attendee</p>
<h2>John Doe</h2>
<h2>[email protected]</h2>
</div>



<div class="accountContainer">
<div class="accountInfo">
Expand All @@ -113,9 +114,6 @@ function HostList() {
<p>John Doe</p>
</div>




<div class="accountContainer">
<div class="accountInfo">
<img src={profileImage1} alt="Profile picture" className="profile-image" />
Expand All @@ -128,6 +126,7 @@ function HostList() {
<img src={profileImage1} alt="Profile picture" className="profile-image" />
</div>
<p>John Doe</p>

</div>

<div class="accountContainer">
Expand Down

0 comments on commit 1578d18

Please sign in to comment.