Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sign in button background color not displayed correctly #160

Open
2 tasks done
lkoehl opened this issue Mar 23, 2023 · 4 comments
Open
2 tasks done

Sign in button background color not displayed correctly #160

lkoehl opened this issue Mar 23, 2023 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@lkoehl
Copy link

lkoehl commented Mar 23, 2023

Bug report

  • I confirm this is a bug with Supabase, not with my own application.
  • I confirm I have searched the Docs, GitHub Discussions, and Discord.

Describe the bug

The sign in button from the login form doesn't always show the correct background color. You can take a look at #106 where I provided screenshots of the example project.

To Reproduce

Check the codesandbox for a MWE. Remove line 6 in App.tsx and compare the background color of the sign in button.

If you also check App.module.css you can see, that it is an empty file.

Expected behavior

The background color of the login button remains consistent.

@lkoehl lkoehl added the bug Something isn't working label Mar 23, 2023
@silentworks
Copy link
Contributor

But line 6 is your app code. This is a very confusing example of the issue as the variable on line 6 isn't being used anywhere, this is not an Auth UI issue, this is an application code issue. If you remove line 28 - 41 you will see the default theme.

@silentworks silentworks self-assigned this Mar 26, 2023
@silentworks silentworks added invalid This doesn't seem right and removed bug Something isn't working labels Mar 26, 2023
@lkoehl
Copy link
Author

lkoehl commented Mar 28, 2023

@silentworks I don't fully understand the problem. I can see it being an application issue as well as an Auth UI issue. As you said, that line 6 is not used anywhere, it should not affect the code. But it does affect it, even the default theme!
I removed lines 28 - 41 and uncommented/commented line 6 again, and the default theme view changes (see screenshots). Since I don't fully understand the implementation of the UI library, I can't pinpoint the problem. But the custom app code is a fix for a bug reported in #106. Without line 6, the sign in button isn't styled correctly. This leads me to believe that it is an Auth UI issue.

Without the fix in line 6 (note that the background color is not applied properly)
removed2

With line 6 (default theme)
working2

@silentworks silentworks added bug Something isn't working and removed invalid This doesn't seem right labels Mar 28, 2023
@silentworks
Copy link
Contributor

@lkoehl ah I see what you mean, I've changed this back to a bug and will investigate it further to try and find what's going wrong here. It looks like something is leaking into the css variables and how they work from the app code.

@SandersTDavid
Copy link

I encountered this issue while using a custom theme and hex colors for the brand and brandAccent. However, I resolved it by switching to the rgb() format, and the button background filled in with my custom color as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants