summaryrefslogtreecommitdiffhomepage
path: root/ios
diff options
context:
space:
mode:
authorJon Petersson <jon.petersson@kvadrat.se>2024-05-20 16:42:07 +0200
committerJon Petersson <jon.petersson@kvadrat.se>2024-05-21 11:42:57 +0200
commit70eb4cc9bf63cfd6685cea101b41adaba2beddde (patch)
treeb3d6f3cdf92ae53fec4e3b1a8bf1ea23cf7ad353 /ios
parent123d2e5e7fddda3244b1a244ad207f602a2c5e22 (diff)
downloadmullvadvpn-70eb4cc9bf63cfd6685cea101b41adaba2beddde.tar.xz
mullvadvpn-70eb4cc9bf63cfd6685cea101b41adaba2beddde.zip
Improve UI of list items in vpn settings view
Diffstat (limited to 'ios')
-rw-r--r--ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsDataSource.swift9
-rw-r--r--ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsViewController.swift1
2 files changed, 6 insertions, 4 deletions
diff --git a/ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsDataSource.swift b/ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsDataSource.swift
index ed4f2727b3..9a05dc04b0 100644
--- a/ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsDataSource.swift
+++ b/ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsDataSource.swift
@@ -359,7 +359,9 @@ final class VPNSettingsDataSource: UITableViewDiffableDataSource<
}
func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView? {
- nil
+ let view = UIView()
+ view.backgroundColor = tableView.backgroundColor
+ return view
}
func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
@@ -370,7 +372,7 @@ final class VPNSettingsDataSource: UITableViewDiffableDataSource<
return 0
default:
- return UITableView.automaticDimension
+ return tableView.estimatedRowHeight
}
}
@@ -380,7 +382,8 @@ final class VPNSettingsDataSource: UITableViewDiffableDataSource<
return switch sectionIdentifier {
// 0 due to there already being a separator between .dnsSettings and .ipOverrides.
case .dnsSettings: 0
- case .ipOverrides: 10
+ case .ipOverrides: UIMetrics.TableView.sectionSpacing
+ case .quantumResistance: tableView.estimatedRowHeight
default: 0.5
}
}
diff --git a/ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsViewController.swift b/ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsViewController.swift
index 3d55f6fd0e..0595024466 100644
--- a/ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsViewController.swift
+++ b/ios/MullvadVPN/View controllers/VPNSettings/VPNSettingsViewController.swift
@@ -40,7 +40,6 @@ class VPNSettingsViewController: UITableViewController, VPNSettingsDataSourceDel
tableView.accessibilityIdentifier = .vpnSettingsTableView
tableView.backgroundColor = .secondaryColor
- tableView.separatorColor = .secondaryColor
tableView.rowHeight = UITableView.automaticDimension
tableView.estimatedRowHeight = 60
tableView.estimatedSectionHeaderHeight = tableView.estimatedRowHeight