Blazored / Menu

A JavaScript free menu library for Blazor and Razor Components applications.
https://blazored.github.io/Menu
MIT License
176 stars 32 forks source link

Clicking Plus causes open/close immediately #4

Closed LorenDorez closed 5 years ago

LorenDorez commented 5 years ago

Because you have the onclick event for both the span and the icon it causes a double-click essentially. I would just leave the one on the span

For Reference

@inherits BlazoredSubMenuBase

<li class="blazored-sub-menu-header @(IsOpen ? "open" : string.Empty)">
    <span onclick="@ToggleSubMenu"><i onclick="@ToggleSubMenu">@Icon</i> @Header</span>
    <ul class="blazored-sub-menu">
        @ChildContent
    </ul>
</li>
chrissainty commented 5 years ago

Fixed