Skip to content

Commit

Permalink
Adjusted banner to accommodate both iPhone and iPad in various sizes
Browse files Browse the repository at this point in the history
  • Loading branch information
tobihagemann committed Nov 30, 2024
1 parent 68bc598 commit db6f899
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Cryptomator/VaultList/VaultListViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,10 @@ class VaultListViewController: ListViewController<VaultCellViewModel> {
let textLabel = UILabel()
textLabel.text = "Lifetime License is 33%* off in December!"
textLabel.textColor = .white
textLabel.font = UIFont.preferredFont(forTextStyle: .body)
textLabel.font = UIFont.preferredFont(forTextStyle: .footnote)
textLabel.adjustsFontSizeToFitWidth = true
textLabel.minimumScaleFactor = 0.5
textLabel.numberOfLines = 2
textLabel.translatesAutoresizingMaskIntoConstraints = false

let dismissButton = UIButton(type: .close)
Expand Down Expand Up @@ -187,7 +188,7 @@ class VaultListViewController: ListViewController<VaultCellViewModel> {
banner.trailingAnchor.constraint(equalTo: view.trailingAnchor, constant: -16),
banner.bottomAnchor.constraint(equalTo: view.safeAreaLayoutGuide.bottomAnchor, constant: -16),
banner.centerXAnchor.constraint(equalTo: view.centerXAnchor),
banner.heightAnchor.constraint(equalToConstant: 60)
banner.heightAnchor.constraint(equalToConstant: 50)
])

bannerView = banner
Expand Down

0 comments on commit db6f899

Please sign in to comment.