From 54589023ef3fad072421ec81f516c565791f73f5 Mon Sep 17 00:00:00 2001 From: EDEMESSI Florian Date: Thu, 25 Jul 2024 14:43:58 +0100 Subject: [PATCH] minor refactoring --- _data/navigation.yml | 3 ++ _includes/search.html | 89 ++++++++++-------------------------------- assets/css/style.scss | 73 ++++++++++++++++++++++++++++++++++ cheatsheets.markdown | 13 +----- contributions.markdown | 9 ++++- index.markdown | 8 ---- 6 files changed, 105 insertions(+), 90 deletions(-) diff --git a/_data/navigation.yml b/_data/navigation.yml index 600d7e4..b0427a0 100644 --- a/_data/navigation.yml +++ b/_data/navigation.yml @@ -7,6 +7,9 @@ - title: Auteurs url: /authors +- title: Contributeurs + url: /contributors + - title: Tous les articles url: /cheatsheets diff --git a/_includes/search.html b/_includes/search.html index a502034..7fbd57d 100644 --- a/_includes/search.html +++ b/_includes/search.html @@ -1,73 +1,24 @@ - - - - - - - - - - - - - - \ No newline at end of file + } + + diff --git a/assets/css/style.scss b/assets/css/style.scss index 06d3de9..d7ba864 100644 --- a/assets/css/style.scss +++ b/assets/css/style.scss @@ -110,6 +110,79 @@ a:hover { color: yellowgreen; } + +.about { + font-size: 1.3rem; +} + + .hidden { + display: none; + } + +/* The visit-button on index page */ +.visit-btn { + margin-top: 5%; + display: flex; + align-self: center; + max-width: fit-content; + margin-inline: auto; + padding: 1%; + font-size: 1.3rem; + border: 1px black solid; + text-decoration: none; + outline: none; + background: none; + color: green; + box-shadow: 0 0 5px rgba(0, 0, 0, 0.5); +} + +.visit-btn:hover { + text-decoration: none; + background: green; + color: white; +} + + +/* search bar for articles */ + #myInput { + display: block; + background-image: url("{{ '/assets/images/icon-search.png?v=' | append: site.github.build_revision | relative_url }}"); + /* Add a search icon to input */ + background-position: 10px 12px; + background-repeat: no-repeat; + width: 75%; + font-size: 16px; + padding: 12px 20px 12px 40px; + border: 1px solid #ddd; + margin-bottom: 12px; + } + + #myUL { + list-style-type: none; + padding: 0; + margin: 0; + } + + #myUL li a { + border: 1px solid #ddd; + margin-top: -1px; + background-color: #f6f6f6; + padding: 12px; + text-decoration: none; + font-size: 18px; + color: black; + display: block; + } + + #myUL li a:hover:not(.header) { + background-color: #eee; + } + + .articles>h2:only-child { + display: none; + } + + /* Media queries below. handle bigger screens later */ @media screen and (max-width: 700px) { .sidebar { diff --git a/cheatsheets.markdown b/cheatsheets.markdown index 9ed83fc..9c9b242 100644 --- a/cheatsheets.markdown +++ b/cheatsheets.markdown @@ -17,21 +17,14 @@ permalink: /cheatsheets/ {% endunless %} {% endfor %} - - -

Actuellement {{ posts }} articles sont disponibles, répartis en {{ categories }} catégories:

+Actuellement {{ posts }} articles sont disponibles, répartis en {{ categories }} catégories {% assign sortedCategories = site.categories | sort %} {% for category in sortedCategories %} - {% unless category contains 'Menu' or category contains 'Secrets' or category contains 'Exemple'%} + {% unless category contains 'Menu' or category contains 'Exemple'%}

{{ category[0] }} ({{ category[1].size }})

-