Bring back the plane (IOS-134)
This commit is contained in:
parent
4f870f9bc8
commit
3d1ed86d01
|
@ -135,7 +135,7 @@ extension WelcomeViewController {
|
||||||
view.addSubview(mastodonLogo)
|
view.addSubview(mastodonLogo)
|
||||||
|
|
||||||
NSLayoutConstraint.activate([
|
NSLayoutConstraint.activate([
|
||||||
mastodonLogo.topAnchor.constraint(equalTo: view.safeAreaLayoutGuide.topAnchor, constant: 24),
|
mastodonLogo.topAnchor.constraint(equalTo: view.safeAreaLayoutGuide.topAnchor),
|
||||||
mastodonLogo.centerXAnchor.constraint(equalTo: view.centerXAnchor),
|
mastodonLogo.centerXAnchor.constraint(equalTo: view.centerXAnchor),
|
||||||
mastodonLogo.widthAnchor.constraint(equalToConstant: 300),
|
mastodonLogo.widthAnchor.constraint(equalToConstant: 300),
|
||||||
])
|
])
|
||||||
|
@ -292,21 +292,10 @@ extension WelcomeViewController {
|
||||||
welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.translatesAutoresizingMaskIntoConstraints = false
|
welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.translatesAutoresizingMaskIntoConstraints = false
|
||||||
view.addSubview(welcomeIllustrationView.elephantOnAirplaneWithContrailImageView)
|
view.addSubview(welcomeIllustrationView.elephantOnAirplaneWithContrailImageView)
|
||||||
NSLayoutConstraint.activate([
|
NSLayoutConstraint.activate([
|
||||||
view.leftAnchor.constraint(equalTo: welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.rightAnchor, constant: -104), // add 12pt bleeding
|
view.leftAnchor.constraint(equalTo: welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.rightAnchor, constant: -150),
|
||||||
welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.bottomAnchor.constraint(equalTo: welcomeIllustrationView.leftHillImageView.topAnchor),
|
welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.topAnchor.constraint(equalTo: topPaddingView.bottomAnchor, constant: 20),
|
||||||
// make a little bit large
|
|
||||||
welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.heightAnchor.constraint(equalTo: welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.widthAnchor, multiplier: 105.0/318.0),
|
welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.heightAnchor.constraint(equalTo: welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.widthAnchor, multiplier: 105.0/318.0),
|
||||||
])
|
])
|
||||||
let bottomPaddingView = UIView()
|
|
||||||
bottomPaddingView.translatesAutoresizingMaskIntoConstraints = false
|
|
||||||
view.addSubview(bottomPaddingView)
|
|
||||||
NSLayoutConstraint.activate([
|
|
||||||
bottomPaddingView.topAnchor.constraint(equalTo: welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.bottomAnchor),
|
|
||||||
bottomPaddingView.leadingAnchor.constraint(equalTo: mastodonLogo.leadingAnchor),
|
|
||||||
bottomPaddingView.trailingAnchor.constraint(equalTo: mastodonLogo.trailingAnchor),
|
|
||||||
bottomPaddingView.bottomAnchor.constraint(equalTo: view.centerYAnchor),
|
|
||||||
bottomPaddingView.heightAnchor.constraint(equalTo: topPaddingView.heightAnchor, multiplier: 4),
|
|
||||||
])
|
|
||||||
|
|
||||||
welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.addMotionEffect(
|
welcomeIllustrationView.elephantOnAirplaneWithContrailImageView.addMotionEffect(
|
||||||
UIInterpolatingMotionEffect.motionEffect(minX: -20, maxX: 12, minY: -20, maxY: 12) // maxX should not larger then the bleeding (12pt)
|
UIInterpolatingMotionEffect.motionEffect(minX: -20, maxX: 12, minY: -20, maxY: 12) // maxX should not larger then the bleeding (12pt)
|
||||||
|
|
Loading…
Reference in New Issue