Mr-Thack / kerplunk

The Kerplunk Social Media Application
Other
1 stars 1 forks source link

Fix modal background breaking the site on chatroom creation #4

Closed superrhodes closed 1 year ago

superrhodes commented 1 year ago

When a chatroom is created, a div that has to do with the modal system fills the screen. While it isn't visible, it prevents clicking on anything and the user has to reload their browser.

superrhodes commented 1 year ago

Screencast from 2023-06-16 03-04-25.webm my mouse isn't visible as screen recording is broken, but you can see the point.

superrhodes commented 1 year ago

It seems that the success/failure modals being made in a separate function made them get overwritten by something else, which visibly made them pop out quickly or not show up at all when they should've waited for user input. This led to their backdrop staying on the screen, which covered the whole site and made everything unclickable. I moved the modals to the main function, which did complicate the code a bit, but it works now so I don't even care anymore.