From 392ecc99a3331c6e8003974dc82fd2cf094a3a26 Mon Sep 17 00:00:00 2001 From: ehab-hassan Date: Tue, 16 May 2023 14:08:31 +0300 Subject: [PATCH] update css and fix mobile --- config.toml | 4 ++-- css/index.css | 40 ++++++++++++++++++++-------------- templates/partials/header.html | 29 ++++++++++++++---------- 3 files changed, 43 insertions(+), 30 deletions(-) diff --git a/config.toml b/config.toml index c889f19..b40d1e4 100644 --- a/config.toml +++ b/config.toml @@ -67,5 +67,5 @@ paginate_by = 2 paginate_path = "blog-posts" [extra] -header_class = "freeflow" -footer_class = "freeflow" \ No newline at end of file +header_class = "customize" +footer_class = "customize" \ No newline at end of file diff --git a/css/index.css b/css/index.css index e149186..5c126d6 100644 --- a/css/index.css +++ b/css/index.css @@ -173,29 +173,31 @@ font-weight: 500; white-space: normal; } -header .freeflow { - background-color: transparent; - position: absolute; +header .customize { + background-color: transparent; + position: absolute; } -footer .freeflow { - width: 100vw; - background-color: #FFFFFF; - display: flex; - flex-direction: column; - align-items: center; - padding: 40px; +footer .customize { + /* width: 100vw; */ + background-color: #FFFFFF; + display: flex; + flex-direction: column; + align-items: center; + padding-top: 40px; + padding-bottom: 40px; + } -footer .freeflow img { - width: 125px; +footer .customize img { + width: 125px; } -header .freeflow div { - box-shadow: none; - text-transform: uppercase; - font-weight: 700 !important; +header .customize div { + box-shadow: none; + text-transform: capitalize; + font-weight: 700 !important; } button { @@ -355,6 +357,12 @@ header { .header:hover .back { transform: none; } + +a:hover { +color: #636363; + +} + @media (max-width: 768px) { /* h2 { font-size: 3rem; diff --git a/templates/partials/header.html b/templates/partials/header.html index 161de5b..3cba0e0 100644 --- a/templates/partials/header.html +++ b/templates/partials/header.html @@ -12,7 +12,7 @@ function toggleMenu(button) { if (displayedMenu === button.id.split("-")[0]) { - button.className = button.className.replace(" text-blue-500 bg-stone-200 sm:bg-transparent", " text-gray-900"); + button.className = button.className.replace(" text-green-500 bg-stone-200 sm:bg-transparent", " text-gray-900"); hideMenu(button.id.split("-")[0]); button.lastElementChild.className = button.lastElementChild.className.replace("rotate-0", "-rotate-90") displayedMenu = ""; @@ -20,7 +20,7 @@ else { showMenu(button.id.split("-")[0]); button.lastElementChild.className = button.lastElementChild.className.replace("-rotate-90", "rotate-0") - button.className = button.className.replace(" text-gray-900", " text-blue-500 bg-stone-200 sm:bg-transparent"); + button.className = button.className.replace(" text-gray-900", " text-green-500 bg-stone-200 sm:bg-transparent"); displayedMenu = button.id.split("-")[0] } } @@ -79,7 +79,7 @@ buttons.forEach((button) => { button.addEventListener( 'click', function() { handleClick(button) }); }) - document.getElementById("mobile-learn-btn").addEventListener( 'click', toggleMenu); + //document.getElementById("mobile-learn-btn").addEventListener( 'click', toggleMenu); } @@ -97,33 +97,33 @@ {% else %}
{% set header_class = config.extra.header_class | default(value='') %} -
+
- -