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

Make non-critical warnings less intrusive #393

Open
1 task done
surchs opened this issue Dec 7, 2024 · 5 comments
Open
1 task done

Make non-critical warnings less intrusive #393

surchs opened this issue Dec 7, 2024 · 5 comments
Assignees
Labels
flag:discuss Flag issue that needs to be discussed before it can be implemented.

Comments

@surchs
Copy link
Contributor

surchs commented Dec 7, 2024

Is there an existing issue for this?

  • I have searched the existing issues

New feature

I would like to have a way of removing / hiding the non-critical warnings from the UI. Right now I get a lot of warnings even if nothing is really broken - and as a regular user I cannot do anything about these warnings (other than click them away one by one):

Image

I propose we make the current behaviour a "debug" mode and make it default to "off". In the new "normal mode", I would either see only critical error messages (i.e. no results / something broken) or I see only a little counter of warnings and errors - e.g. with a badge https://mui.com/material-ui/react-badge/

Image

I can then do some UI action (e.g. click the badge) to expand these warnings and look at them.

Unclear documentation

No response

@Tusharjamdade
Copy link

@surchs I can take this up and try to fix the issue. Please assign it to me.

@surchs
Copy link
Contributor Author

surchs commented Dec 19, 2024

Hey @Tusharjamdade, thanks for your interest in contributing. I think the best way to do this is to discuss in the issue a bit how you want to implement it, and then we can discuss the details in a draft PR.

@Tusharjamdade
Copy link

Hi @surchs,

To implement MUI Badges like the one shown in the example image, we can add them to the navbar (Navbar.tsx). In App.tsx, we can store all the warnings or non-critical issues in a state variable and pass these warnings as props to the Navbar component. The badge value can then be dynamically updated based on the warnings.

Additionally, we can add a dropdown to the badge to display non-critical warnings. For critical warnings, we can display them as we did previously. Please let me know if my approach is irrelevant or needs improvement.

@surchs
Copy link
Contributor Author

surchs commented Dec 19, 2024

Hey @Tusharjamdade , that sounds cool to me. @rmanaem, do you have any opinions on the placement for the warnings-badge? Navbar makes sense?

@surchs surchs added the flag:discuss Flag issue that needs to be discussed before it can be implemented. label Dec 19, 2024
@Tusharjamdade
Copy link

Hi @surchs @rmanaem,

I have implemented the mail badge as discussed. Please let me know if any improvements or additional changes are needed. Once I receive confirmation, I will open a PR.

Thank you!

Neurobagel.Query.Tool.mp4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
flag:discuss Flag issue that needs to be discussed before it can be implemented.
Projects
Status: No status
Development

No branches or pull requests

2 participants