Skip to content

Commit

Permalink
Show empty on error for home
Browse files Browse the repository at this point in the history
  • Loading branch information
Samuel Oldham committed Sep 25, 2024
1 parent 4dfa43d commit 71f20c0
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions psst-gui/src/ui/home.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ fn simple_title_label(title: &str) -> impl Widget<AppState> {
}

pub fn made_for_you() -> impl Widget<AppState> {
Async::new(spinner_widget, loaded_results_widget, error_widget)
Async::new(spinner_widget, loaded_results_widget, || {Empty})
.lens(
Ctx::make(
AppState::common_ctx,
Expand All @@ -66,7 +66,7 @@ pub fn made_for_you() -> impl Widget<AppState> {
}

pub fn recommended_stations() -> impl Widget<AppState> {
Async::new(spinner_widget, loaded_results_widget, error_widget)
Async::new(spinner_widget, loaded_results_widget, || {Empty})
.lens(
Ctx::make(
AppState::common_ctx,
Expand All @@ -83,7 +83,7 @@ pub fn recommended_stations() -> impl Widget<AppState> {
}

pub fn uniquely_yours() -> impl Widget<AppState> {
Async::new(spinner_widget, loaded_results_widget, error_widget)
Async::new(spinner_widget, loaded_results_widget, || {Empty})
.lens(
Ctx::make(
AppState::common_ctx,
Expand All @@ -100,7 +100,7 @@ pub fn uniquely_yours() -> impl Widget<AppState> {
}

pub fn user_top_mixes() -> impl Widget<AppState> {
Async::new(spinner_widget, loaded_results_widget, error_widget)
Async::new(spinner_widget, loaded_results_widget, || {Empty})
.lens(
Ctx::make(
AppState::common_ctx,
Expand All @@ -117,7 +117,7 @@ pub fn user_top_mixes() -> impl Widget<AppState> {
}

pub fn best_of_artists() -> impl Widget<AppState> {
Async::new(spinner_widget, loaded_results_widget, error_widget)
Async::new(spinner_widget, loaded_results_widget, || {Empty})
.lens(
Ctx::make(
AppState::common_ctx,
Expand All @@ -134,7 +134,7 @@ pub fn best_of_artists() -> impl Widget<AppState> {
}

pub fn your_shows() -> impl Widget<AppState> {
Async::new(spinner_widget, loaded_results_widget, error_widget)
Async::new(spinner_widget, loaded_results_widget, || {Empty})
.lens(
Ctx::make(
AppState::common_ctx,
Expand All @@ -151,7 +151,7 @@ pub fn your_shows() -> impl Widget<AppState> {
}

pub fn jump_back_in() -> impl Widget<AppState> {
Async::new(spinner_widget, loaded_results_widget, error_widget)
Async::new(spinner_widget, loaded_results_widget, || {Empty})
.lens(
Ctx::make(
AppState::common_ctx,
Expand All @@ -168,7 +168,7 @@ pub fn jump_back_in() -> impl Widget<AppState> {
}

pub fn shows_that_you_might_like() -> impl Widget<AppState> {
Async::new(spinner_widget, loaded_results_widget, error_widget)
Async::new(spinner_widget, loaded_results_widget, || {Empty})
.lens(
Ctx::make(
AppState::common_ctx,
Expand Down

0 comments on commit 71f20c0

Please sign in to comment.