I devised a simple technique to showcase an element overlapping another, like an overlay, and it was functioning flawlessly until the point where I needed to incorporate a "button" (styled as a Bootstrap anchor) beneath it.
Here is the initial setup and here is what it looked like after adding the button.
The effect continued to work but now whenever the button or the surrounding area was hovered over, the effect would also be triggered.
So, then I altered the trigger to the hover event of <figure>
:
.box figure:hover + .details {
display: block;
}
This resolved the previous issue, however, a new problem emerged: When I moved the cursor within the .box
, the effect would flicker on and off rapidly, creating an undesirable blinking effect on the overlay.
How can I rectify this?
Please note: It's not feasible for me to relocate the "button" outside of
.box
because in the actual scenario,.box
will repeat based on the number of records retrieved from the database.