Arjuna Posted June 15 Posted June 15 (edited) Hey all, https://www.yuryourultimaterelationship.com/ I have inserted this code into my site's CSS to create a yellow "underline" effect when someone hovers on a navigation bar item. .header-nav-item:not(.user-accounts-link) a:after { content: ''; display: block; border-bottom: 1.5px solid #FFCA00; transform: scaleX(0); transition: transform 500ms ease-in-out; transform-origin: 0% 50%; } .header-nav-item:not(.user-accounts-link) a:hover:after { transform: scaleX(1); } I would like to fix 2 issues: 1. If a page is selected that is listed in a dropdown menu, the purple underline for the dropdown folder name still shows on hover. I would like it to only have the yellow color when someone hovers. 2. On hover, the yellow underline spans the width of the entire container. I would like it to only underline the page name (same like the purple underline when page is selected). Thanks, all! ❤️ Edited June 15 by Arjuna
Solution Lesum Posted June 15 Solution Posted June 15 Hi @Arjuna To fix the issues you mentioned, add this code under Website > Pages > Website Tools > Custom CSS .header-nav-item.header-nav-item--folder.header-nav-item--active * { background-image: none !important; } span.header-nav-folder-item-content { background-image: none !important; } .header-nav-folder-item a { display: block !important; width: fit-content !important; float: right !important; } If my comments were useful, please like or mark my solution as answer so others can scroll to it quickly. Sam Web Developer & Digital Designer ☕ Did you find my contribution helpful? Buy me a coffee?
Arjuna Posted June 16 Author Posted June 16 Amazing, thank you! This completely removes the purple underline when the page is selected, but actually it looks better this way.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment