add current page highlight feature
This commit is contained in:
+61
-1
@@ -90,12 +90,26 @@ img {
|
||||
font-size: 18px;
|
||||
font-weight: 500;
|
||||
transition: background-color 0.2s;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.nav-item:hover {
|
||||
background-color: rgba(0, 0, 0, 0.05);
|
||||
}
|
||||
|
||||
/* Styles pour la page active dans la sidebar */
|
||||
.nav-item.active {
|
||||
background-color: rgba(255, 0, 0, 0.08);
|
||||
font-weight: 600;
|
||||
color: var(--primary-red);
|
||||
box-shadow: inset 3px 0 0 var(--primary-red);
|
||||
}
|
||||
|
||||
.nav-item.active i {
|
||||
color: var(--primary-red);
|
||||
}
|
||||
|
||||
.nav-item i, .nav-item img {
|
||||
margin-right: 15px;
|
||||
width: 24px;
|
||||
@@ -132,6 +146,14 @@ img {
|
||||
transform: translateX(5px);
|
||||
}
|
||||
|
||||
/* Style pour un tag actif */
|
||||
.tag-item.active {
|
||||
background-color: rgba(255, 0, 0, 0.08);
|
||||
color: var(--primary-red);
|
||||
font-weight: 600;
|
||||
box-shadow: inset 3px 0 0 var(--primary-red);
|
||||
}
|
||||
|
||||
.tag-icon {
|
||||
color: var(--primary-red);
|
||||
font-size: 0.9em;
|
||||
@@ -139,10 +161,48 @@ img {
|
||||
transition: transform 0.2s ease;
|
||||
}
|
||||
|
||||
.tag-item:hover .tag-icon {
|
||||
.tag-item:hover .tag-icon,
|
||||
.tag-item.active .tag-icon {
|
||||
transform: scale(1.5);
|
||||
}
|
||||
|
||||
/* Media queries pour le style actif sur les différentes tailles d'écran */
|
||||
@media (max-width: 1200px) and (min-width: 1001px) {
|
||||
.nav-item.active {
|
||||
background-color: rgba(255, 0, 0, 0.15);
|
||||
}
|
||||
|
||||
.nav-item.active::after {
|
||||
content: attr(data-title);
|
||||
position: absolute;
|
||||
left: 70px;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
background: var(--primary-red);
|
||||
color: white;
|
||||
padding: 5px 10px;
|
||||
border-radius: 4px;
|
||||
white-space: nowrap;
|
||||
box-shadow: 0 1px 5px rgba(0,0,0,0.2);
|
||||
z-index: 100;
|
||||
}
|
||||
}
|
||||
|
||||
/* Style pour le menu mobile */
|
||||
.mobile-menu .nav-item.active {
|
||||
background-color: rgba(255, 0, 0, 0.08);
|
||||
color: var(--primary-red);
|
||||
font-weight: 600;
|
||||
box-shadow: inset 3px 0 0 var(--primary-red);
|
||||
}
|
||||
|
||||
.mobile-menu .tag-item.active {
|
||||
background-color: rgba(255, 0, 0, 0.08);
|
||||
color: var(--primary-red);
|
||||
font-weight: 600;
|
||||
box-shadow: inset 3px 0 0 var(--primary-red);
|
||||
}
|
||||
|
||||
/* Header */
|
||||
.header {
|
||||
display: flex;
|
||||
|
||||
Reference in New Issue
Block a user