Skip to content

Commit

Permalink
[#5] Improve animation
Browse files Browse the repository at this point in the history
  • Loading branch information
blyscuit committed Oct 19, 2022
1 parent a2efc91 commit 57c6890
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
2 changes: 2 additions & 0 deletions iosApp/Survey.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
09495F5928F92A6F0036BDFB /* RouteCoordinator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 09495F5828F92A6E0036BDFB /* RouteCoordinator.swift */; };
09495F6628FF97080036BDFB /* SplashView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 09495F6528FF97070036BDFB /* SplashView.swift */; };
09495F6828FF97490036BDFB /* ViewId+Splash.swift in Sources */ = {isa = PBXBuildFile; fileRef = 09495F6728FF97490036BDFB /* ViewId+Splash.swift */; };
09495F6A28FFAFA20036BDFB /* ViewId+Splash.swift in Sources */ = {isa = PBXBuildFile; fileRef = 09495F6728FF97490036BDFB /* ViewId+Splash.swift */; };
09636AF228D4779400A5CB97 /* NeuzeitSLTStd-Book.otf in Resources */ = {isa = PBXBuildFile; fileRef = 09636AF028D4779400A5CB97 /* NeuzeitSLTStd-Book.otf */; };
09636AF328D4779400A5CB97 /* NeuzeitSLTStd-BookHeavy.otf in Resources */ = {isa = PBXBuildFile; fileRef = 09636AF128D4779400A5CB97 /* NeuzeitSLTStd-BookHeavy.otf */; };
09636AF628D47A1500A5CB97 /* R.generated.swift in Sources */ = {isa = PBXBuildFile; fileRef = 09636AF528D47A1400A5CB97 /* R.generated.swift */; };
Expand Down Expand Up @@ -1123,6 +1124,7 @@
09636B2428D821FC00A5CB97 /* LoginSpec.swift in Sources */,
09636B3228D8272200A5CB97 /* ScreenProtocol.swift in Sources */,
09636B2128D821EA00A5CB97 /* ViewId.swift in Sources */,
09495F6A28FFAFA20036BDFB /* ViewId+Splash.swift in Sources */,
09636B3628D8285700A5CB97 /* KeyboardScreen.swift in Sources */,
09636B2228D821ED00A5CB97 /* ViewId+Login.swift in Sources */,
09636B3128D8271D00A5CB97 /* LoginScreen.swift in Sources */,
Expand Down
17 changes: 8 additions & 9 deletions iosApp/Survey/Sources/Presentation/Modules/Login/LoginView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ struct LoginView: View {
@State private var password: String = ""
@State private var animating = false

private let animationDuration: Double = 0.8
private let animationDuration: Double = 0.7

var body: some View {
ZStack {
Expand All @@ -25,14 +25,13 @@ struct LoginView: View {
.ignoresSafeArea()
.frame(maxWidth: .infinity, maxHeight: .infinity)

if animating {
Assets.backgroundBlur
.image
.resizable()
.aspectRatio(contentMode: .fill)
.ignoresSafeArea()
.frame(maxWidth: .infinity, maxHeight: .infinity)
}
Assets.backgroundBlur
.image
.resizable()
.aspectRatio(contentMode: .fill)
.ignoresSafeArea()
.frame(maxWidth: .infinity, maxHeight: .infinity)
.opacity(animating ? 1.0 : 0.001)

VStack(
alignment: .center,
Expand Down

0 comments on commit 57c6890

Please sign in to comment.