Dropdown menu item text color changes to grey after I add a Url for navigation.

So when I add a Url for navigation on a dropdown menu item, my coloring disappears.  As soon as I remove the Url it goes back to blue.  Can't figure it out.



 <SfDropDownButton  CssClass="e-caret-hide" Content="SERVICES">
            <DropDownMenuItems>
                <DropDownMenuItem Text="UI Web Design" Url="/UIDesign"></DropDownMenuItem>
                <DropDownMenuItem Text="UI Mobile Design" Url="/UIDesign" ></DropDownMenuItem>
                <DropDownMenuItem Text="Backend Development" Url="/BackendDevelopment" ></DropDownMenuItem>
                <DropDownMenuItem Text="QA-Audits" ></DropDownMenuItem>
            </DropDownMenuItems>
</SfDropDownButton>


/****************************
        Buttons
******************************/


 .e-dropdown-btn, .e-dropdown-btn.e-btn {
        color: white;
        font-size: 23px;
        margin-left: 2em;
        background: none;
        padding: .25em 0;
        border: none;

    }

    .e-dropdown-btn:hover {
       color: red;
       border: none;
    }

       .e-dropdown-popup {/******PopUP********/
        background: white;
        border: 1px solid red;
        color: darkblue;
        border-radius: 7px;
        width: 25%;
    }

    .e-dropdown-popup ul .e-item:hover {/*****Dropdown list items on hover******/
        color: red;
        background: white;
        font-size: 25px;
        font-weight: 700;
    }

    .e-dropdown-popup ul .e-item{/*****Dropdown list items before hover*****/
        color: darkblue;
        background: white;
        font-size: 20px;
        font-weight: 700;
        margin: .25em 0;
    }

    .e-dropdown-btn.e-active {/*********Dropdown on active*********/
        border: none;
        color: red;
    }



1 Reply

YA YuvanShankar Arunagiri Syncfusion Team May 30, 2022 03:36 PM UTC

Hi William,


We have checked the reported query and provide the separate css style for url contains tag of dropdown button item. Please refer the below code snippet.


[Index.razor]:


.e-dropdown-popup .e-item .e-menu-url { /******PopUP********/

            background: white;

            color: darkblue !important;

        }

 

.e-dropdown-popup ul .e-item .e-menu-url:hover { /*****Dropdown list items on hover******/

            color: red !important;

            background: white;

            font-size: 25px;

            font-weight: 700;

        }


Could you please check the above code and get back to us, if you need any further assistance on this. 


Regards,

Yuvan Shankar A


Loader.
Up arrow icon