Skip to content

Commit 452f171

Browse files
committed
Update domain row layout.
1 parent b1ab68b commit 452f171

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

WooCommerce/Classes/ViewRelated/Dashboard/Settings/Domains/DomainRowView.swift

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -40,17 +40,17 @@ struct DomainRowView: View {
4040
let viewModel: DomainRowViewModel
4141

4242
var body: some View {
43-
VStack(alignment: .leading) {
44-
HStack {
43+
HStack {
44+
VStack(alignment: .leading, spacing: Layout.spacingBetweenNameAndDetail) {
4545
Text(viewModel.attributedName)
46-
if viewModel.isSelected {
47-
Spacer()
48-
Image(uiImage: .checkmarkImage)
49-
.foregroundColor(Color(.brand))
46+
if let attributedDetail = viewModel.attributedDetail {
47+
Text(attributedDetail)
5048
}
5149
}
52-
if let attributedDetail = viewModel.attributedDetail {
53-
Text(attributedDetail)
50+
if viewModel.isSelected {
51+
Spacer()
52+
Image(uiImage: .checkmarkImage)
53+
.foregroundColor(Color(.brand))
5454
}
5555
}
5656
.padding(Layout.insets)
@@ -60,6 +60,7 @@ struct DomainRowView: View {
6060
private extension DomainRowView {
6161
enum Layout {
6262
static let insets: EdgeInsets = .init(top: 10, leading: 16, bottom: 10, trailing: 16)
63+
static let spacingBetweenNameAndDetail: CGFloat = 4
6364
}
6465
}
6566

0 commit comments

Comments
 (0)