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

Refactor Empty State View: Followup Code Improvements #11735

Open
Profpatsch opened this issue Nov 22, 2024 · 0 comments
Open

Refactor Empty State View: Followup Code Improvements #11735

Profpatsch opened this issue Nov 22, 2024 · 0 comments
Labels
codequality Improvements to the codebase to improve the code quality GUI Issue is related to the graphical user interface rewrite Issues and PRs related to rewrite

Comments

@Profpatsch
Copy link
Contributor

Profpatsch commented Nov 22, 2024

  • storing a Modifier in the EmptyStateSpec is bad practice and also doesn't make much sense (it's the purpose of parent views to decide the modifiers of the children, it's not a property of the children themselves)
    • It should boil down to:
      • removing the modifier field from the Spec
      • specifying the modifier in every usage of EmptyStateComposable(modifier = ...) in compose code to make the layout well-centered and/or well-spaced
      • specifying XML layout parameters in every usage of in XML layout files to make the layout well-centered and/or well-spaced (only those that will then be replaced with an EmptyStateComposable obviously, there are other unrelated ComposeViews I think)
  • the spacing of the UI is not perfect everywhere, but at least with the latest commit the panel is always centered
    • I can't understand why the "Select a playlist" dialog is tight, while "Select a channel" is larger, but I can't debug right now, see below why...
  • (in a future PR!) the error panel should be merged with the empty state panel, since:
    • only one of them is shown at a time
    • the checks for errors are often close to the checks for emptiness, so some checks could be simplified
    • I'm not totally convinced of this though
  • the empty state for unsupported content in the channel fragment does not work, but it didn't work before either, and both my Layout Inspector and by View Designer don't work, so I can't debug right now (Android Studio decided to go on vacation or something)

Originally posted by @Stypox in #11725 (comment)

@Profpatsch Profpatsch added GUI Issue is related to the graphical user interface codequality Improvements to the codebase to improve the code quality rewrite Issues and PRs related to rewrite labels Nov 22, 2024
@Profpatsch Profpatsch moved this to Todo in Rewrite Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
codequality Improvements to the codebase to improve the code quality GUI Issue is related to the graphical user interface rewrite Issues and PRs related to rewrite
Projects
Status: Todo
Development

No branches or pull requests

1 participant