diff --git a/Sources/Model/Settings.swift b/Sources/Model/Settings.swift index 5ff8b351..da951b22 100755 --- a/Sources/Model/Settings.swift +++ b/Sources/Model/Settings.swift @@ -32,6 +32,9 @@ import Photos /// Main background color public lazy var backgroundColor: UIColor = .systemBackgroundColor + /// Color for backgroun of drop downs + public lazy var dropDownBackgroundColor: UIColor = .clear + /// What color to fill the circle with public lazy var selectionFillColor: UIColor = UIView().tintColor diff --git a/Sources/Presentation/Dropdown/DropdownPresentationController.swift b/Sources/Presentation/Dropdown/DropdownPresentationController.swift index a45cbd6c..bf202c50 100644 --- a/Sources/Presentation/Dropdown/DropdownPresentationController.swift +++ b/Sources/Presentation/Dropdown/DropdownPresentationController.swift @@ -71,7 +71,11 @@ class DropdownPresentationController: UIPresentationController { // Match color with navigation bar presentedViewController.view.backgroundColor = navigationBar.barTintColor } else { - position = .zero + if #available(iOS 11.0, *) { + position = CGPoint(x: containerView.safeAreaInsets.left, y: containerView.safeAreaInsets.top) + } else { + position = .zero + } } return CGRect(origin: position, size: size) diff --git a/Sources/Scene/Albums/AlbumsViewController.swift b/Sources/Scene/Albums/AlbumsViewController.swift index 9d372cda..72bed40a 100755 --- a/Sources/Scene/Albums/AlbumsViewController.swift +++ b/Sources/Scene/Albums/AlbumsViewController.swift @@ -57,7 +57,7 @@ class AlbumsViewController: UIViewController { tableView.register(AlbumCell.self, forCellReuseIdentifier: AlbumCell.identifier) tableView.dataSource = dataSource tableView.delegate = self - tableView.backgroundColor = .clear + tableView.backgroundColor = settings.theme.dropDownBackgroundColor view.addSubview(tableView) let lineHeight: CGFloat = 0.5