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

Enhancement/input component hiding of error icon #318

Closed
wants to merge 5 commits into from
Closed

Enhancement/input component hiding of error icon #318

wants to merge 5 commits into from

Conversation

FatumaA
Copy link

@FatumaA FatumaA commented Jan 22, 2022

What kind of change does this PR introduce?

Enhancement: Input component hiding of error icon
Closes #311

What is the current behavior?

Input component always shows an error icon when in error sttae

Please link any relevant issues here.
Closes #311

What is the new behavior?

Error icon in input can be toggled

Feel free to include screenshots if it includes visual changes.

supabse.ui.-.error.icon.mov

Additional context

Add any other context or screenshots.

Make error icon optional when input component is in error state
@FatumaA FatumaA changed the base branch from master to alpha January 22, 2022 11:29
@MildTomato
Copy link
Contributor

Awesome!

@FatumaA would you be able to do the same for the following?

InputNumber
Select
Listbox

@FatumaA
Copy link
Author

FatumaA commented Jan 23, 2022

@MildTomato I've updated the PR to include InputNumber and Select. The Listbox does not seem as straight forward

@@ -214,11 +217,11 @@ function InputNumber({
/>
</div> */}
{icon && <InputIconContainer icon={icon} />}
{error ? (
{error && (
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the logic is possibly wrong here, as error could be defined and hideErrorIcon could be true.
But then. the <div> below this line will still get rendered.

Might need to have a variable above like, const showErrorIcon = error && !hideErrorIcon and then use that variable instead of error on line 220.

I think the same can be applied to all files you've changed.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've made the requested changes in the last commit

@MildTomato
Copy link
Contributor

Supabase UI is being deprecated.

As part of that, we are closing Pull Requests in this repo for now.

If you'd like to still make these changes, you could consider making these changes in https:/supabase/supabase/tree/master/packages/ui


We are moving the components to the main mono repo at https:/supabase/supabase.

The auth component has been moved to it's own repo and package. https:/supabase-community/auth-ui. You can also read the docs for auth ui here.

@MildTomato MildTomato closed this Jan 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Input component hiding of error icon
3 participants