I'm facing an issue with the hover effect on my Metronic dropdown menu. When I hover over the menu button, everything works fine, but when I move to the options in the menu, it turns white. I suspect this might be due to two button activations happening simultaneously or one activation getting deactivated upon entering the menu options.
https://i.sstatic.net/IYsQcypW.png
The cursor is currently hovering over the menu button
https://i.sstatic.net/oTpsuvWA.png
The cursor is now over some option in the drop-down menu
Here is the code snippet:
<div class="d-flex align-items-center ms-1 ms-lg-3">
<div class="menu menu-column menu-gray-600 menu-active-primary menu-hover-light-primary fw-semibold w-30px h-30px w-md-40px h-md-40px" data-kt-menu="true">
<!-- Menu item -->
<div class="menu-item menu-item-calendar" data-kt-menu-trigger="hover" data-kt-menu-placement="bottom-end">
<!-- Menu link -->
<a href="#" class="btn btn-icon btn-active-light-primary btn-custom w-30px h-30px w-md-40px h-md-40px" data-kt-menu-trigger="{default:'click', lg: 'hover'}" data-kt-menu-attach="parent" data-kt-menu-placement="bottom-end">
<span class="svg-icon svg-icon-1">
<svg width="24" height="24" viewBox="0 2 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<!-- SVG -->
</svg>
</span>
</a>
<!-- Menu sub -->
<div class="menu menu-sub menu-sub-dropdown menu-column menu-rounded menu-title-gray-700 menu-icon-muted menu-active-bg menu-state-color fw-semibold py-4 fs-base w-175px" data-kt-menu="true">
<!-- Menu item: Local -->
<div class="menu-item px-3 my-0">
<a href="<?= site_url('calendar') ?>" class="menu-link px-3 py-2">
<span class="menu-icon svg-icon svg-icon-1">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<!-- SVG -->
</svg>
</span>
<span class="menu-title">Local</span>
</a>
</div>
<!-- Menu item: Outlook -->
<div class="menu-item px-3 my-0">
<a href="#" id="botonOutlook" class="menu-link px-3 py-2">
<span class="menu-icon svg-icon svg-icon-1">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<!-- SVG -->
</svg>
</span>
<span class="menu-title">Outlook</span>
</a>
</div>
<!-- Menu item: Google -->
<div class="menu-item px-3 my-0">
<a href="#" id="botonGoogle" class="menu-link px-3 py-2">
<span class="menu-icon">
<img src="assets/media/logos/gmanu.png" width="25" height="25" class="google-icon" />
</span>
<span class="menu-title">Google</span>
</a>
</div>
</div>
</div>
</div>
</div>
I also have another dropdown menu that is already implemented and works as expected:
https://i.sstatic.net/8a6Z0CTK.png
https://i.sstatic.net/V083isut.png
The hover effect remains consistent even when navigating through the options.
Below is the code for this working dropdown menu:
<div class="d-flex align-items-center ms-1 ms-lg-3">
<a href="#" class="btn btn-icon btn-active-light-primary btn-custom w-30px h-30px w-md-40px h-md-40px" data-kt-menu-trigger="{default:'click', lg: 'hover'}" data-kt-menu-attach="parent" data-kt-menu-placement="bottom-end">
<span class="svg-icon theme-light-show svg-icon-1">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<!-- SVG -->
</svg>
</span>
<span class="svg-icon theme-dark-show svg-icon-1">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<!-- SVG -->
</svg>
</span>
</a>
<div class="menu menu-sub menu-sub-dropdown menu-column menu-rounded menu-title-gray-700 menu-icon-muted menu-active-bg menu-state-color fw-semibold py-4 fs-base w-175px" data-kt-menu="true" data-kt-element="theme-mode-menu">
<div class="menu-item px-3 my-0">
<a href="#" class="menu-link px-3 py-2" data-kt-element="mode" data-kt-value="light">
<span class="menu-icon" data-kt-element="icon">
<span class="svg-icon svg-icon-3">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<!-- SVG -->
</svg>
</span>
</span>
<span class="menu-title"><?= lang('General.light') ?></span>
</a>
</div>
<div class="menu-item px-3 my-0">
<a href="#" class="menu-link px-3 py-2" data-kt-element="mode" data-kt-value="dark">
<span class="menu-icon" data-kt-element="icon">
<span class="svg-icon svg-icon-3">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<!-- SVG -->
</svg>
</span>
</span>
<span class="menu-title"><?= lang('General.dark') ?></span>
</a>
</div>
</div>
</div>
Thank you all very much!