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

Add loading spinner on login #172

Merged
merged 4 commits into from
Nov 11, 2024
Merged

Conversation

vanderlindenma
Copy link
Collaborator

Screen.Recording.2024-11-08.at.10.08.58.AM.mov

"""
input_style_unchanged = {"width": "250px"}
empty_style_unchanged = {"": ""}
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Would be cleaner to user {} instead, but then mypy complains because it wants to know the type of empty_style_unchanged and it seems python does not infer types for empty dictionaries => using {"": ""} seems simpler than bringing in a whole typing library to handle that error only (from typing import Dict, Optional ... empty_style: Dict[str, Optional[str]] = {}).

empty_style_unchanged,
empty_style_unchanged,
hide_element_style,
)
Copy link
Collaborator Author

@vanderlindenma vanderlindenma Nov 8, 2024

Choose a reason for hiding this comment

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

@MateoLostanlen @fe51 @RonanMorgan Another example where Dash does not scale well. In a "sane" 😉 web framework:

  1. You shouldn't have to repeatedly include placeholders for things you don't want to update: Just pass a map/dict of what you do want to change and the framework should know the rest should be left untouched.
  2. You shouldn't have to go back and forth between the parameters in the head of your function and the return to match the order of the declared outputs and with the order of the returns => just return a map each time.

Maybe there are workarounds to fix that in Dash but this kind of update behavior should really come out of the box.

@vanderlindenma vanderlindenma marked this pull request as ready for review November 8, 2024 15:48
Copy link
Member

@MateoLostanlen MateoLostanlen left a comment

Choose a reason for hiding this comment

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

Thanks for this !

@MateoLostanlen MateoLostanlen merged commit 68a6bce into main Nov 11, 2024
8 checks passed
@MateoLostanlen MateoLostanlen deleted the add_loading_spinner_on_login branch November 11, 2024 01:26
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.

2 participants