Changement du menu pour mes nouvelles activités

This commit is contained in:
leosw
2025-07-13 15:10:56 +02:00
parent 687de1ed71
commit 613776264c
3 changed files with 42 additions and 6 deletions

View File

@@ -5,10 +5,18 @@
</a>
<nav>
<ul>
<li class="on-bar"><a class="on-bar" href="<?=$config['rel_root_folder']?>map">Carte</a></li>
<!-- <li class="on-bar"><a class="on-bar" href="<?=$config['rel_root_folder']?>search">Recherche</a></li>
<li class="on-bar"><a class="on-bar" href="<?=$config['rel_root_folder']?>news">Nouveautés</a></li> -->
<li class="on-bar"><a class="on-bar" href="<?=$config['rel_root_folder']?>community">Contribuer</a></li>
<li class="on-bar with-subtitle"><a class="on-bar" href="<?=$config['rel_root_folder']?>restauration-de-refuges">Restauration<br>
<span class="subtitle">de refuges pastoraux</span></a></li>
<li class="on-bar with-subtitle"><a class="on-bar" href="<?=$config['rel_root_folder']?>metallerie">Métallerie<br>
<span class="subtitle">agricole</span></a></li>
<li class="on-bar has-sub with-subtitle">
<a class="on-bar" href="<?=$config['rel_root_folder']?>map">Inventaire<br>
<span class="subtitle">des cabanes de montagne</span></a>
<ul>
<li><a href="<?=$config['rel_root_folder']?>map">Carte</a></li>
<li><a href="<?=$config['rel_root_folder']?>community">Contribuer</a></li>
</ul>
</li>
<li class="on-bar has-sub">
<? if ($user->id == 0) { ?>
<a class="on-bar" href="#"><i class="icon fas fa-user"></i></a>

View File

@@ -122,6 +122,16 @@ header li a {
header li a:hover, header li a:focus-within {
color: white;
}
header li.with-subtitle a {
padding: 15px 15px 25px;
}
header li .subtitle {
font-size: 80%;
font-style: italic;
white-space: nowrap;
padding-left: 5px;
}
header li:hover a, header li:focus-within a {
border-bottom: 6px solid blue;
@@ -160,6 +170,12 @@ header li.has-sub ul {
background: #212121;
}
header li.with-subtitle ul {
right: unset;
position: relative;
min-width: 100%;
}
header li.has-sub ul li {
display: block;
height: 46px;

View File

@@ -21,12 +21,18 @@ function reduce() {
}, 100, function() {
// Animation complete.
});
$( "header a.on-bar" ).animate({
$( "header li:not(.with-subtitle) a.on-bar" ).animate({
paddingTop: "15px",
paddingBottom: "5px"
}, 100, function() {
// Animation complete.
});
$( "header li.with-subtitle a.on-bar" ).animate({
paddingTop: "5px",
paddingBottom: "15px"
}, 100, function() {
// Animation complete.
});
}
function enlarge() {
@@ -50,12 +56,18 @@ function enlarge() {
}, 100, function() {
// Animation complete.
});
$( "header a.on-bar" ).animate({
$( "header li:not(.with-subtitle) a.on-bar" ).animate({
paddingTop: "25px",
paddingBottom: "15px"
}, 100, function() {
// Animation complete.
});
$( "header li.with-subtitle a.on-bar" ).animate({
paddingTop: "15px",
paddingBottom: "25px"
}, 100, function() {
// Animation complete.
});
}
$(window).scroll(function() {