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

feat:Home page #10

Merged
merged 1 commit into from
Sep 26, 2023
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
23 changes: 23 additions & 0 deletions app/views/home.view.php
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
<?php
require_once('../app/views/layout/header.php');


?>

<nav class="navbar">
<div class="logo">
<img src="<?=ROOT_DIR?>/assets/images/logo.png" alt="logo">
</div>
<ul class="nav-menu">
<li class="nav-menu-item"><a href="#">Home</a></li>
<li class="nav-menu-item"><a href="#">About</a></li>
<li class="nav-menu-item"><a href="#">Services</a></li>
<li class="nav-menu-item"><a href="#">Portfolio</a></li>
<li class="nav-menu-item"><a href="#">Contact</a></li>
</ul>
<div class="login-button"><a href="#">Login</a></div>
</nav>

<?php require_once('../app/views/sections/hero.php');
?>

<h1> Home page view </h1>


Expand Down
2 changes: 2 additions & 0 deletions app/views/layout/footer.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
</body>
</html>
8 changes: 8 additions & 0 deletions app/views/layout/header.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@

<html>
<head>
<title>Wanderlust</title>
<link rel="stylesheet" type="text/css" href="<?=ROOT_DIR ?>/assets/css/style.css">
</head>
<body>

9 changes: 9 additions & 0 deletions app/views/sections/hero.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<div class="hero">
<div class="hero-content">
<h1 class="hero-title">Your Title Goes Here</h1>
<p class="hero-description">A short description of your hero section.</p>
</div>
<div class="hero-image">
<img src="your-image.jpg" alt="Hero Image">
</div>
</div>
136 changes: 136 additions & 0 deletions public/assets/css/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,136 @@
/* Navbar container */
.navbar {
background-color: #F4F4F4; /* Off-white background */
display: flex;
justify-content: space-between;
align-items: center;
padding: 10px 20px;
}

/* Logo styling */
.logo {
color: #4C5039; /* Complementary color for text */
font-size: 24px;
font-weight: bold;
}

/* Menu styling */
.nav-menu {
list-style: none;
display: flex;
}

.nav-menu-item {
margin-right: 20px;
}

.nav-menu-item a {
text-decoration: none;
color: #4C5039; /* Complementary color for text */
font-weight: bold;
}

/* Login button styling */
.login-button {
background-color: #F4F4F4; /* Complementary color */
color: #4C5039;
padding: 10px 20px;
border-radius: 5px;
text-decoration: none;
border-width: 1px;
border-style: solid;
border-color: #4C5039;
}
.login-button a {
text-decoration: none;
color: #4C5039;
}

/* Media query for mobile responsiveness */
@media screen and (max-width: 768px) {
.nav-menu {
display: none;
}

.nav-menu.active {
display: flex;
flex-direction: column;
position: absolute;
top: 60px;
left: 0;
background-color: #F4F4F4; /* Off-white background */
width: 100%;
padding: 10px 0;
}

.nav-menu-item {
margin: 10px 0;
}

.nav-menu-toggle {
display: block;
color: #4C5039; /* Complementary color for text */
font-size: 24px;
cursor: pointer;
}
}

/* Background color */
body {
background-color: #F4F4F4; /* Off-white background */
}

/* Hero section container */
.hero {
display: flex;
flex-direction: column;
align-items: center;
text-align: center;
padding: 40px;
}

/* Hero content (title and description) */
.hero-content {
max-width: 600px; /* Adjust as needed */
}

.hero-title {
font-size: 32px;
font-weight: bold;
margin-bottom: 20px;
}

.hero-description {
font-size: 18px;
margin-bottom: 40px;
}

/* Hero image */
.hero-image img {
max-width: 100%; /* Ensure the image fits within its container */
}

/* Media query for mobile responsiveness */
@media screen and (max-width: 768px) {
.hero {
padding: 20px; /* Reduce padding for smaller screens */
}

.hero-content {
text-align: center;
order: 2; /* Move the content below the image on smaller screens */
}

.hero-image {
order: 1; /* Move the image above the content on smaller screens */
margin-bottom: 20px; /* Add spacing between image and content */
}

.hero-title {
font-size: 28px; /* Adjust font size for smaller screens */
}

.hero-description {
font-size: 16px; /* Adjust font size for smaller screens */
}
}
Binary file added public/assets/images/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.