CristianVasile23 / conversation-hud

A simple FoundryVTT module that adds a nice HUD that display the portraits of all the characters present in a conversation.
MIT License
17 stars 3 forks source link

[Bug] Conversation controls are misplaced #15

Closed franckflo closed 1 year ago

franckflo commented 1 year ago

Hi, thanks for this Module that is really nice for theater of the mind encounters!

I noticed a bug. When a conversation is running, I couldn't s see the little icons to save/minimize/hide the conversation I could see in your demo. It turns out, on my setup they are lined up all the way to the right of the page, not on the left of the sidebar as in your demo. I have a couple suggestions to fix that issue:

#sidebar { width: 400px !important; background-size: 400px 100% !important;

Thanks !!

CristianVasile23 commented 1 year ago

Hi there! Thanks for the interest in the module!

As to the issue, that is some strange behavior and I don't really know why that is happening. The way the buttons are placed should be responsive depending on size of the sidebar. They shouldn't appear all the way to the right unless something changes the layout of the interface, which is why I think your issue appears due to the custom CSS you mentioned.

But just to make sure, if you turn off the Custom CSS module (or delete the rule mentioned above I guess), does the issue still appear?

franckflo commented 1 year ago

Hi, that was a good idea, however disabling Custom CSS did not help so I guess it’s something else. I’m going to run a Find the Culprit test run and will report if I find another module causing a conflict.

CristianVasile23 commented 1 year ago

Yep, sound great, keep me posted.

In the meantime, I will also work on adding an option to change the placement of the buttons as I have some ideas for alternative positions that should avoid this issue.

franckflo commented 1 year ago

Hi, FTC found the conflicting module: Mythic UI Rebirth. It's a UI mod for playing antiquity-based games. I'm running Odyssey of the Dragonlords right now, so it'd be nice if we could find a way for both modules to work together. Thanks!

CristianVasile23 commented 1 year ago

Great, thanks for letting me know what the cause of the problem is. I will investigate the module and see if I can come up with a solution that fixes the problem. The fix will probably come either this weekend or sometimes next week when I also add some additional features to the module.

franckflo commented 1 year ago

That's great, thanks a lot for your help!

CristianVasile23 commented 1 year ago

I have added a toggle that should fix the issue you were having in release 4.1.0. By default it is off so you will have to turn it on in the module settings.

The issue was caused by the way most of the custom UI handle the sidebar position. I have no idea why fixed positioning is used as it "breaks" the layout positioning in the page. Fixed positioning shouldn't be used in this case, maybe this is a remnant from the older versions of Foundry, but in the current version I see no reason for fixed positioning to be used for the sidebar.

What the toggle does is to restore the default positioning of the sidebar, thus fixing the overlap. It should work with most of the custom UI modules (I have tested a few), but it might cause some weird behavior on some. Thankfully, Mythic UI seems to work without any issues as far as I can tell. That said, if you encounter any problems, feel free to contact me (here or on discord). And who knows, maybe the with V11 and the UI customization options introduced, maybe this issue will be solved in future releases of the UI modules.

franckflo commented 1 year ago

Hi there. I upgraded to 4.1.0 and It seems the problem is still there with Mythic UI enabled. I also disabled Custom CSS also to make sure that wasn't the issue: No dice. Sorry for the bad news!

CristianVasile23 commented 1 year ago

Have you enabled the fix in the settings? Because by default it is disabled.

franckflo commented 1 year ago

Duh, yes that fixed it :). Thanks a lot!