From f59c74f0c1ac6ec5363aae1c069c9fe5fe68cab7 Mon Sep 17 00:00:00 2001 From: devarsheecodess Date: Tue, 8 Oct 2024 02:29:44 +0530 Subject: [PATCH 1/3] Added dropdown #368 --- ambtracker.html | 27 +++++ driver.html | 31 +++++- hospital.html | 27 +++++ manage.html | 38 ++++++- src/css/driver.css | 255 ++++++++++++++++++++++--------------------- src/css/hospital.css | 6 - src/css/manage.css | 84 ++++++++++++++ 7 files changed, 335 insertions(+), 133 deletions(-) diff --git a/ambtracker.html b/ambtracker.html index 6613b0a9..b60df009 100644 --- a/ambtracker.html +++ b/ambtracker.html @@ -84,9 +84,23 @@

ambu

Flow

  • Manage Ambulance
  • +
    + +
  • +
    + + +
    @@ -130,6 +144,19 @@

    ambu

    Flow

    // Initialize the map when the window loads window.onload = initMap; + // Dropdown + let flag = false + document.getElementById('dropdown').addEventListener('click', () => { + const dropdown = document.querySelector('.dropdown-menu'); + if (flag) { + dropdown.style.display = 'none'; + flag = false; + } else { + dropdown.style.display = 'block'; + flag = true; + } + }); + function logout() { const confirmLogout = confirm('Are you sure you want to logout?'); if (confirmLogout) { diff --git a/driver.html b/driver.html index 565ac753..dc0fc453 100644 --- a/driver.html +++ b/driver.html @@ -5,6 +5,7 @@ Driver Dashboard + @@ -17,7 +18,6 @@ } #driverImage { - width: 100%; height: 320px; margin-bottom: 20px; } @@ -47,8 +47,24 @@

    ambu

    Flow

  • Manage Ambulance
  • +
    + +
  • +
    + + + + +

    Welcome, Driver ___

    You are currently: OFF DUTY

    @@ -142,6 +158,19 @@

    Welcome, Driver ___

    alert("Logged out successfully!"); } } + + // Dropdown + let flag = false + document.getElementById('dropdown').addEventListener('click', () => { + const dropdown = document.querySelector('.dropdown-menu'); + if (flag) { + dropdown.style.display = 'none'; + flag = false; + } else { + dropdown.style.display = 'block'; + flag = true; + } + }); diff --git a/hospital.html b/hospital.html index 8149c8b7..7cf5196a 100644 --- a/hospital.html +++ b/hospital.html @@ -24,8 +24,23 @@

    ambu

    Flow

  • Manage Ambulance
  • +
    + +
  • +
    + + + +
    Bobble-AI Logo @@ -39,6 +54,18 @@

    ambu

    Flow

  • Manage Status
  • Manage Driver
  • Manage Ambulance
  • -
  • +
  • +
    + +
  • +
    + + +

    Manage Status

    @@ -123,6 +137,19 @@

    Add Ambulance

    section.classList.add('active'); } + // Dropdown + let flag = false + document.getElementById('dropdown').addEventListener('click', () => { + const dropdown = document.querySelector('.dropdown-menu'); + if (flag) { + dropdown.style.display = 'none'; + flag = false; + } else { + dropdown.style.display = 'block'; + flag = true; + } + }); + // Function to hide a section function hideSection(section) { section.classList.add('hidden'); @@ -303,6 +330,15 @@

    Add Ambulance

    } else return }); + // Logout (for small screens) + function logout1(){ + cf = confirm('Are you sure you want to logout?'); + if (cf) { + window.location.href = 'index.html'; + alert("Logged out successfully!"); + } else return + } + \ No newline at end of file diff --git a/src/css/driver.css b/src/css/driver.css index d234c2ba..d08516e7 100644 --- a/src/css/driver.css +++ b/src/css/driver.css @@ -1,196 +1,201 @@ @import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"); - /* General Reset */ * { - margin: 0; - padding: 0; - box-sizing: border-box; - font-family: 'Poppins', sans-serif; + margin: 0; + padding: 0; + font-family: "Poppins", sans-serif; +} + +header { + width: 100%; } /* Navbar Enhancements */ .navbar { - background-color: #34495e; - padding: 20px 40px; - display: flex; - justify-content: space-between; - align-items: center; - width: 1527px; - box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1); - margin-bottom: 20px; - } - - .navbar img { - height: 50px; - margin-right: 10px; - } - - .navbar-logo { - display: flex; - justify-content: center; - align-items: center; - } - - .navbar-logo h2 { - color: #ecf0f1; - margin: 0; - font-size: 24px; - } - - .navbar-links { - list-style: none; - display: flex; - gap: 25px; - font-weight: 400; - } - - .navbar-links li { - font-weight: 400; - } - - .navbar-links a { - color: #ecf0f1; - text-decoration: none; - font-weight: 600; - font-size: 18px; - transition: color 0.3s ease; - } - - .navbar-links a:hover { - text-decoration: underline; - text-underline-offset: 5px; - color: #3dbdec; - text-decoration-thickness: 3px; - } + background-color: #34495e; + padding: 20px 40px; + width: 100%; + display: flex; + justify-content: space-between; + align-items: center; + box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1); + margin-bottom: 20px; +} + +.navbar img { + height: 50px; + margin-right: 10px; +} + +.navbar-logo { + display: flex; + justify-content: center; + align-items: center; +} + +.navbar-logo h2 { + color: #ecf0f1; + margin: 0; + font-size: 24px; +} + +.navbar-links { + list-style: none; + display: flex; + gap: 20px; + font-weight: 400; +} + +.navbar-links li { + font-weight: 400; +} + +.navbar-links li:nth-child(5) { + margin-right: 70px; +} + +.navbar-links a { + color: #ecf0f1; + text-decoration: none; + font-weight: 600; + font-size: 18px; + transition: color 0.3s ease; +} + +.navbar-links a:hover { + text-decoration: underline; + text-underline-offset: 5px; + color: #3dbdec; + text-decoration-thickness: 3px; +} /* Body Styling */ body { - font-family: "Poppins", sans-serif; - background: #e8f5e9; - display: flex; - flex-direction: column; - justify-content: center; - align-items: center; + font-family: "Poppins", sans-serif; + background: #e8f5e9; + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; } html { - overflow-y: scroll; + overflow-y: scroll; } html::-webkit-scrollbar { - width: 9px; - transition: width 0.3s ease; - margin: 10px; + width: 9px; + transition: width 0.3s ease; + margin: 10px; } html::-webkit-scrollbar-thumb { - border-radius: 10px; - background: rgba(216, 216, 216, 0.74); - box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5); + border-radius: 10px; + background: rgba(216, 216, 216, 0.74); + box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5); } html::-webkit-scrollbar-thumb:window-inactive { - background: rgb(156, 156, 156); + background: rgb(156, 156, 156); } /* Dashboard Container */ .dashboard-container { - background-color: white; - padding: 40px; - border-radius: 15px; - text-align: center; - box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); - width: 400px; - margin-bottom: 14px; + background-color: white; + padding: 30px; + border-radius: 20px; + text-align: center; + box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); + margin-bottom: 14px; } .dashboard-container h1 { - font-size: 28px; - color: #388e3c; - margin-bottom: 20px; + font-size: 28px; + color: #388e3c; + margin-bottom: 20px; } .dashboard-container p { - font-size: 18px; - color: #555; - margin-bottom: 20px; + font-size: 18px; + color: #555; + margin-bottom: 20px; } #working-status { - margin-top: 20px; - font-size: 16px; - color: #00796b; + margin-top: 20px; + font-size: 16px; + color: #00796b; } /* Availability Toggle */ .availability-toggle { - display: flex; - justify-content: center; - align-items: center; - gap: 20px; + display: flex; + justify-content: center; + align-items: center; + gap: 20px; } /* Toggle Switch Styling */ .switch { - position: relative; - display: inline-block; - width: 60px; - height: 34px; + position: relative; + display: inline-block; + width: 60px; + height: 34px; } .switch input { - opacity: 0; - width: 0; - height: 0; + opacity: 0; + width: 0; + height: 0; } .slider { - position: absolute; - cursor: pointer; - top: 0; - left: 0; - right: 0; - bottom: 0; - background-color: #ccc; - transition: 0.4s; - border-radius: 34px; + position: absolute; + cursor: pointer; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: #ccc; + transition: 0.4s; + border-radius: 34px; } .slider:before { - position: absolute; - content: ""; - height: 26px; - width: 26px; - left: 4px; - bottom: 4px; - background-color: white; - transition: 0.4s; - border-radius: 50%; + position: absolute; + content: ""; + height: 26px; + width: 26px; + left: 4px; + bottom: 4px; + background-color: white; + transition: 0.4s; + border-radius: 50%; } input:checked + .slider { - background-color: #388e3c; + background-color: #388e3c; } input:checked + .slider:before { - transform: translateX(26px); + transform: translateX(26px); } /* Round Toggle */ .slider.round { - border-radius: 34px; + border-radius: 34px; } .slider.round:before { - border-radius: 50%; + border-radius: 50%; } .toggle-container { - margin-top: 20px; - display: flex; - align-items: center; + margin-top: 20px; + display: flex; + align-items: center; } .toggle-container p { - margin-left: 10px; -} \ No newline at end of file + margin-left: 10px; +} diff --git a/src/css/hospital.css b/src/css/hospital.css index da8080aa..a9aa6484 100644 --- a/src/css/hospital.css +++ b/src/css/hospital.css @@ -41,12 +41,6 @@ html::-webkit-scrollbar-thumb:window-inactive { font-size: 24px; } -.navbar-links { - list-style: none; - display: flex; - gap: 25px; -} - .navbar-links a { color: #ecf0f1; text-decoration: none; diff --git a/src/css/manage.css b/src/css/manage.css index 7332a2ab..3b6d81d6 100644 --- a/src/css/manage.css +++ b/src/css/manage.css @@ -245,6 +245,35 @@ select:focus { text-decoration-thickness: 3px; } +/* Dropdown Menu */ +.navbar-links2 { + list-style: none; + display: flex; + flex-direction: column; + gap: 70px; + padding: 10px; + font-weight: 400; +} + +.navbar-links2 li { + font-weight: 400; +} + +.navbar-links2 a { + color: #ecf0f1; + text-decoration: none; + font-weight: 600; + font-size: 18px; + transition: color 0.3s ease; +} + +.navbar-links2 a:hover { + text-decoration: underline; + text-underline-offset: 5px; + color: #3dbdec; + text-decoration-thickness: 3px; +} + /* Enhance Dashboard Layout */ /* Adjusting body to accommodate dashboard layout */ body { @@ -257,3 +286,58 @@ body { .manage-container { flex: 1; } + +.resp { + display: none; + justify-content: center; + align-items: center; + list-style: none; + color: white; +} + +.dropdown-menu { + display: none; +} + +.dropdown-menu { + display: none; + flex-direction: column; + background-color: #34495ee7; + padding: 10px; + color: black; + position: absolute; + top: 13%; + left: 50%; + transform: translateX(-50%); + z-index: 999; /* Ensure it shows above */ + width: 100%; + text-align: center; + height: 100%; /* Adjust height automatically */ + overflow: visible; +} + +/* Responsive Header */ +@media (max-width: 968px) { + .navbar-links { + display: none; + } + .resp { + display: flex; + gap: 10px; + font-size: 20px; + } + #dropdown { + background-color: transparent; + border: 1px solid transparent; + font-size: 20px; + color: white; + } + + .navbar-logo img { + height: 40px; + } + + .navbar-logo h2 { + font-size: 20px; + } +} From 0200c3a7fe4274b46b9490855119a970dda3ecf8 Mon Sep 17 00:00:00 2001 From: VivekShahare04 Date: Tue, 8 Oct 2024 07:50:16 +0530 Subject: [PATCH 2/3] index and features file updated with script --- features.html | 58 +++++++++++++++++++++++++++++++++++++++++++++------ index.html | 44 +++++++++++++++++++++++++------------- script.js | 3 ++- 3 files changed, 83 insertions(+), 22 deletions(-) diff --git a/features.html b/features.html index 7206f1b5..72610615 100644 --- a/features.html +++ b/features.html @@ -100,6 +100,13 @@ transform: translateY(0); } } + #thankYouMessage { + margin-top: 20px; + font-size: 18px; + color: green; + display: none; /* Initially hidden */ + } + @@ -218,12 +225,20 @@

    Follow Us

    -
    -

    Subscribe to Our Newsletter

    -
    -

    - -
    +
    +
    Subscribe to Newsletter
    +
    + +
    + + +
    +
    +
    + + +
    @@ -235,5 +250,36 @@

    Subscribe to Our Newsletter

    + + diff --git a/index.html b/index.html index 5e745241..da37da85 100644 --- a/index.html +++ b/index.html @@ -319,21 +319,21 @@

    Follow Us

    -
    -

    Subscribe to Our Newsletter

    -
    -

    - -
    -
    +
    +

    Subscribe to Our Newsletter

    +
    +

    + +
    + +
    @@ -366,6 +366,20 @@

    Subscribe to Our Newsletter

    window.onload = function () { document.getElementById("home-link").classList.add("active"); }; + + const thankYouMessage = document.getElementById("thankYouMessage"); + const form = document.getElementById("subscribeForm"); + + form.addEventListener("submit", function(event) { + event.preventDefault(); // Prevent form from refreshing the page + + // Show Thank You Message after subscribing + thankYouMessage.style.display = 'block'; + + // Optionally clear the input field after subscribing + document.getElementById("emailInput").value = ''; + }); + diff --git a/script.js b/script.js index 4f2048b7..df7d7d11 100644 --- a/script.js +++ b/script.js @@ -23,4 +23,5 @@ accordions.forEach((accordion, index) => { } }); }); -}); \ No newline at end of file +}); + From 03f57446b992e6468b9a35e6929834d61ad94c0f Mon Sep 17 00:00:00 2001 From: VivekShahare04 Date: Tue, 8 Oct 2024 08:07:40 +0530 Subject: [PATCH 3/3] changes made in file team --- team.html | 164 ++++++++++++++++++++---------------------------------- 1 file changed, 60 insertions(+), 104 deletions(-) diff --git a/team.html b/team.html index d99ad5dc..e24352df 100644 --- a/team.html +++ b/team.html @@ -5,21 +5,11 @@ Team - + +