ryceg / Eigengrau-s-Essential-Establishment-Generator

A town generator that is suitable for out of the box play in any fantasy TTRPG setting.
https://eigengrausgenerator.com
MIT License
814 stars 149 forks source link

Multiple popup descriptions can appear simultaneously, sometimes occluding each other #759

Open rhi-gray opened 2 years ago

rhi-gray commented 2 years ago

Describe the bug

When you hover over particular words, a popup appears with a more detailed description. If you move your cursor away from the word, it disappears. However, if you move your cursor over the popup box itself, the popup remains. It is possible to have multiple popups appearing simultaneously and overlapping one another so that text is hidden. This occurs most reliably in tables, such as the town description "Religious Demographics" list, but can be reproduced wherever two separate blue text words appear close on the page.

Bug on the Religious Demographics list: Screenshot from 2022-08-27 12-43-15

Example of the bug occurring elsewhere: Screenshot from 2022-08-27 13-08-09

To Reproduce (bugs MUST be replicable)

Town Seed (click here for info): brokenbubblygazelle

Any seed can be used.

Page to navigate to, buttons to press, etc:

Find somewhere with two spans of blue text in close proximity on the page, in particular with tables including blue spans on every row such as the town Religious Demographics table. Mouse over the lower one to cause the first popup to appear. Then, move your mouse up to the second one, keeping it below the edge of the first popup. The second popup will appear behind the first one.

Additional context

Pretty sure this will be something to do with the bounding box detection including transparent parts of the first popup box (the triangular "tail" bit). Because of the transparency, the cursor registers as being "over" the second blue text while also being within the first popup's hitbox. Should be fairly straightforward to resolve, either by tweaking how the popups disappear or by changing how they look (removing the drop shadow/transparent effect and tail, for example).