Skip to content

Commit

Permalink
Initial Commit
Browse files Browse the repository at this point in the history
  • Loading branch information
mrepol742 committed Oct 9, 2023
1 parent b99b6c3 commit b8093b8
Show file tree
Hide file tree
Showing 11 changed files with 166 additions and 43 deletions.
40 changes: 39 additions & 1 deletion css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ nav {
display: none;
}

@media (min-width:420px) {
@media (min-width:995px) {
.sec {
display: inline-block;
}
Expand Down Expand Up @@ -483,4 +483,42 @@ input[type=date]:focus::-webkit-datetime-edit {

.form-group {
margin-bottom: -4% !important;
}

#toplink {
content: var(--topicon);
}

.dropdown>.dropdown-menu {
display: inherit;
transform: scaleY(0);
transform-origin: top;
transition: all 0.3s ease-in-out;
}

.dropdown>.btn.show+.dropdown-menu {
display: inherit;
transform: scaleY(1);
}

@media only screen and (max-device-width: 480px) {

.navbar-brand {
float:none !important;
}
.img-responsive {
margin:0 auto !important;
display:block !important;
}
}

@media (min-width:535px) {

div.dropdown-multicol2{
width: 30em;
}
div.dropdown-multicol2>div.dropdown-col{
display:inline-block;
width: 32%;
}
}
Binary file added favicon_192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added favicon_512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/nav-dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/nav-light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
42 changes: 21 additions & 21 deletions include/footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,16 +65,16 @@
</div>
<br>
<a href="#" class="px-1" target="_blank">
<i class="fa-brands fa-facebook"></i>
<i class="fa-brands fa-facebook"></i>
</a>
<a href="#" class="px-1" target="_blank">
<i class="fa-brands fa-instagram"></i>
<a href="#" class="px-1" target="_blank">
<i class="fa-brands fa-instagram"></i>
</a>
<a href="#" class="px-1" target="_blank">
<i class="fa-brands fa-twitter"></i>
<a href="#" class="px-1" target="_blank">
<i class="fa-brands fa-twitter"></i>
</a>
<a href="#" class="px-1" target="_blank">
<i class="fa-brands fa-youtube"></i>
<a href="#" class="px-1" target="_blank">
<i class="fa-brands fa-youtube"></i>
</a>
<br>
<?php
Expand All @@ -89,18 +89,18 @@
<script>
if ("serviceWorker" in navigator) {
navigator.serviceWorker
.register("<?php echo $directory; ?>sw.js")
.then((reg) => {
if (reg.installing) {
console.log("Service worker installing");
} else if (reg.waiting) {
console.log("Service worker installed");
} else if (reg.active) {
console.log("Service worker active");
}
})
.catch((err) => {
console.error("Service worker failed: ", err);
});
}
.register("<?php echo $directory; ?>sw.js")
.then((reg) => {
if (reg.installing) {
console.log("Service worker installing");
} else if (reg.waiting) {
console.log("Service worker installed");
} else if (reg.active) {
console.log("Service worker active");
}
})
.catch((err) => {
console.error("Service worker failed: ", err);
});
}
</script>
5 changes: 5 additions & 0 deletions include/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@

<link rel="preload" href="<?php echo $directory; ?>images/hamburger-light.svg" as="image" type="image/svg+xml" crossorigin>
<link rel="preload" href="<?php echo $directory; ?>images/hamburger-dark.svg" as="image" type="image/svg+xml" crossorigin>

<link rel="preload" href="<?php echo $directory; ?>images/nav-light.png" as="image" type="image/png" crossorigin>
<link rel="preload" href="<?php echo $directory; ?>images/nav-dark.png" as="image" type="image/png" crossorigin>
<style>
@font-face {
font-family: 'Source Code Pro';
Expand All @@ -37,10 +40,12 @@

body.light-mode {
--menu: url("<?php echo $directory; ?>../images/hamburger-light.svg");
--topicon: url("<?php echo $directory; ?>../images/nav-dark.png");
}

body {
--menu: url("<?php echo $directory; ?>../images/hamburger-dark.svg");
--topicon: url("<?php echo $directory; ?>../images/nav-light.png");
}
</style>
<link href="<?php echo $directory; ?>assets/fontawesome-6.4.2/css/fontawesome.min.css" rel="stylesheet">
Expand Down
71 changes: 61 additions & 10 deletions include/nav.php
Original file line number Diff line number Diff line change
@@ -1,29 +1,80 @@
<nav class="autohide navbar navbar-expand-lg fixed-top scrolled-up scrolled-up-tr">
<div class="container-fluid">
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarText" aria-controls="navbarText" aria-expanded="false" aria-label="Toggle navigation" id="qwe111">
<span class="navbar-toggler-icon" id="qwe"></span>
</button>
<a class="navbar-brand " href="#"><img class="img-responsive" id="toplink" width="60"></a>
<div class="collapse navbar-collapse" id="navbarText">
<ul class="navbar-nav me-auto mb-2 mb-lg-0">
<li class="nav-item">
<a class="nav-link active" href="<?php echo $directory; ?>#"><img src="<?php echo $directory; ?>images/nav.png" width="60"></a>
</li>
<li class="nav-item">
<a class="nav-link active" href="#">About</a>
<a class="nav-link" href="#">About</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Contact Us</a>
</li>
<li class="nav-item dropdown">
<a class="nav-link btn dropdown-toggle" id="navbarDropdown" href="#" role="button" data-bs-toggle="dropdown" aria-expanded="false">
Module
</a>
<div class="dropdown-menu dropdown-multicol2" aria-labelledby="dropdownMenuButton">
<div class="dropdown-col">
<a class="dropdown-item" href="#">Module 1</a>
<a class="dropdown-item" href="#">Module 2</a>
<a class="dropdown-item" href="#">Module 3</a>
<a class="dropdown-item" href="#">Module 4</a>
<a class="dropdown-item" href="#">Module 5</a>
<a class="dropdown-item" href="#">Module 6</a>
</div>
<div class="dropdown-col">
<a class="dropdown-item" href="#">Module 7</a>
<a class="dropdown-item" href="#">Module 8</a>
<a class="dropdown-item" href="#">Module 9</a>
<a class="dropdown-item" href="#">Module 10</a>
<a class="dropdown-item" href="#">Module 11</a>
<a class="dropdown-item" href="#">Module 12</a>
</div>
<div class="dropdown-col">
<a class="dropdown-item" href="#">Module 13</a>
<a class="dropdown-item" href="#">Module 14</a>
<a class="dropdown-item" href="#">Module 15</a>
<a class="dropdown-item" href="#">Module 16</a>
<a class="dropdown-item" href="#">Module 17</a>
<a class="dropdown-item" href="#">Module 18</a>
</div>
<div class="dropdown-col">
<a class="dropdown-item" href="#">Module 19</a>
</div>
</div>
<!--
<ul class="dropdown-menu" aria-labelledby="navbarDropdown">
<a class="dropdown-item" href="#">Module 1</a>
<a class="dropdown-item" href="#">Module 2</a>
<a class="dropdown-item" href="#">Module 3</a>
<a class="dropdown-item" href="#">Module 4</a>
<a class="dropdown-item" href="#">Module 5</a>
<a class="dropdown-item" href="#">Module 6</a>
<a class="dropdown-item" href="#">Module 7</a>
<a class="dropdown-item" href="#">Module 8</a>
<a class="dropdown-item" href="#">Module 9</a>
<a class="dropdown-item" href="#">Module 10</a>
<a class="dropdown-item" href="#">Module 11</a>
<a class="dropdown-item" href="#">Module 12</a>
<a class="dropdown-item" href="#">Module 13</a>
<a class="dropdown-item" href="#">Module 14</a>
<a class="dropdown-item" href="#">Module 15</a>
<a class="dropdown-item" href="#">Module 16</a>
<a class="dropdown-item" href="#">Module 17</a>
<a class="dropdown-item" href="#">Module 18</a>
<a class="dropdown-item" href="#">Module 19</a>
</ul>
-->
</li>
</ul>
</div>
<div>
<ul class="nav navbar-nav" id="rightSide" style="flex-direction: row;">
<li class="nav-item">
<a class="nav-link" href="#">
<span class="text sec px-2">Module</span>
<i class="fa-solid fa-book"></i>
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">
<span class="text sec px-2">Search</span>
Expand Down
43 changes: 36 additions & 7 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,44 @@

<body class="d-flex flex-column min-vh-100">
<?php include("include/nav.php"); ?>


<header>
<div class="card mb-3">
<div class="row g-0">
<div class="col-md-4" id="mobile">
<img class="rounded mx-auto d-block img-fluid"
src="images/cover.png">
</div>
<div class="col-md-8">
<div class="card-body">
<h5 style="color: #4285f4;">Quezon City</h5>
<h1 class="card-title"><strong>Digital Barangay</strong></h1>
<p class="card-text sub-title">
A proposed Local Government Unit Management<br>System Project</p>
<br>
<button type="button" class="btn btn-primary" >Learn more</button>
<a class="accnt px-3"> Procurement
</a>
</div>
</div>
<div class="col-md-4" id="desktop">
<img class="rounded mx-auto d-block img-fluid"
src="images/cover.png">
</div>
</div>

</div>
</header>

<main class="text-center">
This is a test

<h1 style="font-family: Poppins;">This is a poppins font</h1>
<h1 style="font-family: Montserrat;">This is a montserrat font</h1>
<h1 style="font-family: Maven Pro;">This is a maven pro font</h1>
<h1 style="font-family: Source Code Pro;">This is a source code pro font</h1>
<p>A paragraph</p>

</main>
</body>

<?php
include("include/footer.php");
?>
<?php include("include/footer.php");?>
</body>
</html>
6 changes: 3 additions & 3 deletions site.webmanifest
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@
"lang": "en-US",
"icons": [
{
"src": "/favicon_192.png",
"src": "/lgu/favicon_192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/favicon_512.png",
"src": "/lgu/favicon_512.png",
"sizes": "512x512",
"type": "image/png"
}
Expand All @@ -21,5 +21,5 @@
"display": "standalone",
"start_url": "/?utm_source=webmanifest",
"scope": "/",
"prefer_related_applications": false,
"prefer_related_applications": false
}
2 changes: 1 addition & 1 deletion sw.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ self.addEventListener('install', (event) => {

self.addEventListener('fetch', async (event) => {
if (event.request.method !== "GET") return;
if ((event.request.destination === 'image' || event.request.url.includes("/assets/") && event.request.url.includes(atob(domain)))) {
if ((event.request.destination === 'image' || event.request.url.includes("/assets/") && event.request.url.includes(domain))) {
event.respondWith(caches.open(cacheName).then((cache) => {
return cache.match(event.request).then((cachedResponse) => {
return cachedResponse || fetch(event.request.url).then((fetchedResponse) => {
Expand Down

0 comments on commit b8093b8

Please sign in to comment.