Hi and thanks in advance,
In CSS I have created a right facing arrow used to denote a range of years which is displayed in a number of submenus in an ul horizontal menu
eg: the text in the submenus is something like:
'2020 > 2021'
'2018 > 2019'
'2016 > 2017'
(where the '>' is a placeholder for my actual arrows)
Currently, when the li is hovered, the text changes color from black to white and I want my arrow to also change to white.
I create the right facing arrow like this ...
[CODE lang="css" title="Arrow code"]
.arrow {
width: 0;
height: 0;
border-left: 4px solid transparent;
border-right: 4px solid transparent;
border-bottom: 4px solid black;
display: inline-block;
padding-bottom: 5px; /* align and center the arrow with the text */
}
/* Transform the arrow to the right orientation */
.right {
transform: rotate(90deg);
-webkit-transform: rotate(90deg);
}
/* This changes the text in the submenu to white and the background to green when hovered over */
.dropDownMenu ul li a:hover {
background-color: #164149; /* Dark Green */
color: White;
}
/* Here is the pertinent HTML to display the arrow in the menu text */
<ul>
<li><a href="#"><img src="http://sharepoint/GSites/Dnt/OP/OP_Res/files.png" width="20" align="middle" border="none"><span class="nav-text"> 2021 <i class="arrow right"></i> 2023</span></a>[/CODE]
In CSS I have created a right facing arrow used to denote a range of years which is displayed in a number of submenus in an ul horizontal menu
eg: the text in the submenus is something like:
'2020 > 2021'
'2018 > 2019'
'2016 > 2017'
(where the '>' is a placeholder for my actual arrows)
Currently, when the li is hovered, the text changes color from black to white and I want my arrow to also change to white.
I create the right facing arrow like this ...
[CODE lang="css" title="Arrow code"]
.arrow {
width: 0;
height: 0;
border-left: 4px solid transparent;
border-right: 4px solid transparent;
border-bottom: 4px solid black;
display: inline-block;
padding-bottom: 5px; /* align and center the arrow with the text */
}
/* Transform the arrow to the right orientation */
.right {
transform: rotate(90deg);
-webkit-transform: rotate(90deg);
}
/* This changes the text in the submenu to white and the background to green when hovered over */
.dropDownMenu ul li a:hover {
background-color: #164149; /* Dark Green */
color: White;
}
/* Here is the pertinent HTML to display the arrow in the menu text */
<ul>
<li><a href="#"><img src="http://sharepoint/GSites/Dnt/OP/OP_Res/files.png" width="20" align="middle" border="none"><span class="nav-text"> 2021 <i class="arrow right"></i> 2023</span></a>[/CODE]