From 05f1c0b6c872e18cedadfa432a471087ef2fb043 Mon Sep 17 00:00:00 2001 From: Arkadiusz Fal Date: Sun, 26 Jun 2022 12:51:00 +0200 Subject: [PATCH] Fix sign in required view text layout --- Shared/Views/SignInRequiredView.swift | 5 ++--- Shared/Views/SubscriptionsView.swift | 7 +++++++ 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/Shared/Views/SignInRequiredView.swift b/Shared/Views/SignInRequiredView.swift index d534e93f..3ce36769 100644 --- a/Shared/Views/SignInRequiredView.swift +++ b/Shared/Views/SignInRequiredView.swift @@ -54,7 +54,7 @@ struct SignInRequiredView: View { OpenSettingsButton() #endif } - .frame(minWidth: 0, maxWidth: .infinity, alignment: .center) + .frame(minWidth: 0, maxWidth: .infinity, minHeight: 0, maxHeight: .infinity, alignment: .center) } } @@ -65,7 +65,6 @@ struct SignInRequiredView_Previews: PreviewProvider { Text("Only when signed in") } } - .environmentObject(PlayerModel()) - .environmentObject(InvidiousAPI()) + .injectFixtureEnvironmentObjects() } } diff --git a/Shared/Views/SubscriptionsView.swift b/Shared/Views/SubscriptionsView.swift index e1aa9332..17c88f43 100644 --- a/Shared/Views/SubscriptionsView.swift +++ b/Shared/Views/SubscriptionsView.swift @@ -79,3 +79,10 @@ struct SubscriptionsView: View { } } } + +struct SubscriptonsView_Previews: PreviewProvider { + static var previews: some View { + SubscriptionsView() + .injectFixtureEnvironmentObjects() + } +}