mikhael28 / paretOS

A high-level operating system to maximize human potential. Live at https://paret0.com
https://paret0.com
GNU General Public License v2.0
35 stars 45 forks source link

Bug: Error Toast Notifications broken due to an issue with new LoaderButton component #171

Closed jayeclark closed 2 years ago

jayeclark commented 2 years ago

Description

There is a bug in the error toast notifications that is currently preventing #140 from being replicated. The recent changes to the LoaderButton component have unexpectedly broken the error toast notification.

Steps to Reproduce

  1. Go to profile
  2. Click the pencil icon next to your name
  3. Attempt to upload a new photo
  4. Observe the console errors - these are coming from the errorToast component. (Removing the buttons from the component resolves the issue.)

Expected behavior

Error notification about "missing region" should appear

Actual behavior

No notification appears and there are errors logged in the console

Reproduces how often

Always

Additional Information

Appears to be an issue with the UseStyles subcomponent. This is almost certainly an issue with the toast rendering that makes the ThemeProvider unavailable to the Toast container. It is not an issue with LoaderButton itself, but rather that the instance of LoaderButton used in the toast notification aren't able to consume the theme from ThemeProvider.

Screen Shot 2022-04-02 at 10 57 55 AM Screen Shot 2022-04-02 at 10 57 41 AM
jayeclark commented 2 years ago
Screen Shot 2022-04-02 at 11 28 16 AM

🤦