From 3693708d4fc7a4c2416339738552d9449d4ce0ed Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 14:57:01 +0300 Subject: [PATCH 01/13] =?UTF-8?q?feat(list):=20add=20List8View,=20a=20labe?= =?UTF-8?q?l=20=E2=86=94=20avatar=20+=20value=20row?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The design system's list-8 (Design system – iOS, node 2881:69): a tertiary Subhead-medium label on the left and, right-aligned, a round 24pt avatar and a Subhead value. The avatar is the caller's view; the row sizes and clips it, and VoiceOver reads the row as one element. Co-Authored-By: Claude Opus 5.5 --- README.md | 3 +- Sources/DashUIKit/Table List/List8View.swift | 78 ++++++++++++++++++++ docs/lists-and-rows.md | 19 +++++ 3 files changed, 99 insertions(+), 1 deletion(-) create mode 100644 Sources/DashUIKit/Table List/List8View.swift diff --git a/README.md b/README.md index b378873..8a6a9db 100644 --- a/README.md +++ b/README.md @@ -81,6 +81,7 @@ a component already exists before building your own. | `MenuItem` | Settings/menu row with flexible trailing accessory | [Lists & rows](docs/lists-and-rows.md) | | `RadioButtonRow` | Selectable row — radio or checkbox style | [Lists & rows](docs/lists-and-rows.md) | | `List1View` | Simple label ↔ value row | [Lists & rows](docs/lists-and-rows.md) | +| `List8View` | Label ↔ avatar + value row | [Lists & rows](docs/lists-and-rows.md) | | `NavigationBar` | Custom three-slot nav bar + `NavigationBarElement` buttons | [Navigation & containers](docs/navigation-and-containers.md) | | `BottomSheet` | Sheet chrome (grabber + nav bar) with self-sizing support | [Navigation & containers](docs/navigation-and-containers.md) | | `MenuViewModifier` | Card chrome — rounded background + shadow | [Navigation & containers](docs/navigation-and-containers.md) | @@ -99,7 +100,7 @@ a component already exists before building your own. Sources/DashUIKit/ Button/ DashButton Components/ Components (EnterAmount/, Geometry/, Icons/, Illustrations/) - Table List/ List1View + Table List/ List1View, List8View ViewModifiers/ MenuViewModifier Foundation/ Color / Font / typography / Image / Bundle helpers Resources/ Media.xcassets (colors, icons, illustrations) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift new file mode 100644 index 0000000..1620126 --- /dev/null +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -0,0 +1,78 @@ +// +// Created by Roman Chornyi +// Copyright © 2026 Dash Core Group. All rights reserved. +// +// Licensed under the MIT License (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://opensource.org/licenses/MIT +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// + + +import SwiftUI + +/// A label ↔ value row with a round 24 pt avatar before the value — the design system's +/// `list-8`, for "who" rows such as the recipient on a payment confirmation. +/// +/// The avatar is the caller's view: the row sizes it to 24 × 24 and clips it round. It is +/// hidden from VoiceOver, which reads the row as one element, "label, value". +@available(iOS 14, macOS 11, *) +public struct List8View: View { + + public var label: String + public var value: String + private let avatar: Avatar + + public init(label: String, value: String, @ViewBuilder avatar: () -> Avatar) { + self.label = label + self.value = value + self.avatar = avatar() + } + + public var body: some View { + HStack(alignment: .top, spacing: 20) { + Text(label) + .dashFont(.subheadMedium) + .foregroundColor(Color.dash.tertiaryText) + .lineLimit(1) + .fixedSize() + + HStack(spacing: 8) { + avatar + .frame(width: 24, height: 24) + .clipShape(Circle()) + .accessibilityHidden(true) + + Text(value) + .dashFont(.subhead) + .foregroundColor(Color.dash.primaryText) + .lineLimit(1) + .truncationMode(.tail) + } + .frame(maxWidth: .infinity, alignment: .trailing) + } + .padding(.horizontal, 14) + .padding(.vertical, 12) + .frame(minHeight: 46) + .accessibilityElement(children: .combine) + } +} + +@available(iOS 17, macOS 14, *) +#Preview { + VStack(spacing: 0) { + List8View(label: "To", value: "username") { + Circle().fill(Color.dash.gray300) + } + List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { + Circle().fill(Color.dash.gray300) + } + } +} diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index 8db289b..c6ea0d6 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -181,3 +181,22 @@ on the right (value is right-aligned and can wrap). Useful for detail / summary ```swift List1View(label: "Network", value: "Dash") ``` + +--- + +## List8View + +File `Table List/List8View.swift` · `@available(iOS 14, macOS 11, *)` + +A label ↔ value row with a round avatar before the value — for "who" rows, such as the +recipient on a payment confirmation. Generic over the avatar view, which the row sizes to +24 × 24 and clips round; the library does not load images itself. + +```swift +List8View(label: "To", value: "username") { + Image("avatar").resizable().scaledToFill() // @ViewBuilder avatar +} +``` + +The label never truncates; the value stays on one line and truncates with `…`. VoiceOver +reads the row as one element ("To, username") and skips the avatar. From 0c54238ccd79bfac0ce3a7e4e45d64ecd658e381 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:00:27 +0300 Subject: [PATCH 02/13] fix(list): centre List8View on its avatar and keep the label in bounds Label and value centre on the 24pt avatar instead of the label riding 2pt high; the label no longer uses fixedSize, so a long one cannot push the row past its container; drop the no-op minHeight and truncation mode; guard the preview with #if DEBUG and add a long-label state; list List8View in docs/README.md and CLAUDE.md. Co-Authored-By: Claude Opus 5.5 --- CLAUDE.md | 2 +- Sources/DashUIKit/Table List/List8View.swift | 20 +++++++++++++------- docs/README.md | 3 ++- docs/lists-and-rows.md | 6 ++++-- 4 files changed, 20 insertions(+), 11 deletions(-) diff --git a/CLAUDE.md b/CLAUDE.md index e7f2e39..180f438 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -39,7 +39,7 @@ Sources/DashUIKit/ Geometry/ Layout readers + scale-to-fit helpers Icons/ Code-drawn icons (XmarkIcon, CheckmarkIcon, ChevronIcon, InfoRoundIcon) Illustrations/ Loading / success / error illustrations - Table List/ List1View (label/value row) + Table List/ List1View (label/value row), List8View (label/avatar + value row) ViewModifiers/ MenuViewModifier (card chrome) Foundation/ Color / Font / DashTextStyle / Image / line-height / Bundle Resources/ Media.xcassets (colors, icons, illustrations) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index 1620126..d40a2ef 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -21,8 +21,9 @@ import SwiftUI /// A label ↔ value row with a round 24 pt avatar before the value — the design system's /// `list-8`, for "who" rows such as the recipient on a payment confirmation. /// -/// The avatar is the caller's view: the row sizes it to 24 × 24 and clips it round. It is -/// hidden from VoiceOver, which reads the row as one element, "label, value". +/// The avatar is the caller's view: the row sizes it to a fixed 24 × 24, as the design does, +/// and clips it round. It is hidden from VoiceOver, which reads the row as one element, +/// "label, value". A row with no avatar is a `List1View`. @available(iOS 14, macOS 11, *) public struct List8View: View { @@ -37,12 +38,12 @@ public struct List8View: View { } public var body: some View { - HStack(alignment: .top, spacing: 20) { + HStack(spacing: 20) { Text(label) .dashFont(.subheadMedium) .foregroundColor(Color.dash.tertiaryText) .lineLimit(1) - .fixedSize() + .layoutPriority(1) HStack(spacing: 8) { avatar @@ -54,19 +55,19 @@ public struct List8View: View { .dashFont(.subhead) .foregroundColor(Color.dash.primaryText) .lineLimit(1) - .truncationMode(.tail) } .frame(maxWidth: .infinity, alignment: .trailing) } .padding(.horizontal, 14) .padding(.vertical, 12) - .frame(minHeight: 46) .accessibilityElement(children: .combine) } } +#if DEBUG + @available(iOS 17, macOS 14, *) -#Preview { +#Preview("Every state") { VStack(spacing: 0) { List8View(label: "To", value: "username") { Circle().fill(Color.dash.gray300) @@ -74,5 +75,10 @@ public struct List8View: View { List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { Circle().fill(Color.dash.gray300) } + List8View(label: "A longer translated label", value: "a-very-long-username") { + Circle().fill(Color.dash.gray300) + } } } + +#endif diff --git a/docs/README.md b/docs/README.md index dd05369..d8042f1 100644 --- a/docs/README.md +++ b/docs/README.md @@ -18,7 +18,7 @@ and callbacks; they render and report intent. They require `import DashUIKit` an `ReceiveEstimateView`, `DashAmount`, `DashBalanceView`, `DashPickerView`, `CurrencyOption`. - **[Lists & rows](lists-and-rows.md)** — `CoinSelector`, `MenuItem`, - `ConverterCard`, `TransactionView`, `RadioButtonRow`, `List1View`. + `ConverterCard`, `TransactionView`, `RadioButtonRow`, `List1View`, `List8View`. - **[Navigation & containers](navigation-and-containers.md)** — `NavigationBar`, `NavigationBarElement`, `TopIntroView`, `BottomSheet`, `MenuViewModifier`. - **[Feedback](feedback.md)** — `Toast`, `SystemMessageView`, @@ -53,6 +53,7 @@ and callbacks; they render and report intent. They require `import DashUIKit` an | `EnterAmountView` (`EnterAmountStyle`) | [Amount & currency](amount-and-currency.md#enteramountview) | | `ErrorIllustration` | [Feedback](feedback.md#successillustration--errorillustration) | | `List1View` | [Lists & rows](lists-and-rows.md#list1view) | +| `List8View` | [Lists & rows](lists-and-rows.md#list8view) | | `LoadingIllustration` / `LoadingSpinner` | [Feedback](feedback.md#loadingillustration--loadingspinner) | | `MenuItem` (`MenuItemAccessory`, `MenuItemInfo`) | [Lists & rows](lists-and-rows.md#menuitem) | | `MenuViewModifier` | [Navigation & containers](navigation-and-containers.md#menuviewmodifier) | diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index c6ea0d6..f7b61e6 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -198,5 +198,7 @@ List8View(label: "To", value: "username") { } ``` -The label never truncates; the value stays on one line and truncates with `…`. VoiceOver -reads the row as one element ("To, username") and skips the avatar. +Both texts stay on one line; the value truncates first, the label only when it alone is too +wide. Label and value are centred on the avatar. The avatar keeps its 24 pt at every text +size. VoiceOver reads the row as one element ("To, username") and skips the avatar. For a +row with no avatar, use `List1View`. From 1b1ecb5436812cc89922d2d7365c219bf2e3eb49 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:06:22 +0300 Subject: [PATCH 03/13] fix(list): keep the List8View value visible and its end readable A long label no longer takes the width ahead of the value: the two share it, so the recipient never shrinks to a bare ellipsis. The value truncates in the middle, keeping the end of a username. Docs now say the avatar gets a 24pt frame (the caller passes a view that fills it) and that the row is 48pt, and drop the Dynamic Type claim. Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 12 ++++++++---- docs/lists-and-rows.md | 14 ++++++++------ 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index d40a2ef..ca5881e 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -21,9 +21,13 @@ import SwiftUI /// A label ↔ value row with a round 24 pt avatar before the value — the design system's /// `list-8`, for "who" rows such as the recipient on a payment confirmation. /// -/// The avatar is the caller's view: the row sizes it to a fixed 24 × 24, as the design does, -/// and clips it round. It is hidden from VoiceOver, which reads the row as one element, -/// "label, value". A row with no avatar is a `List1View`. +/// The avatar is the caller's view, laid out in a fixed 24 × 24 frame and clipped round; pass +/// a view that fills its frame (a `resizable()` image, a shape). It is hidden from VoiceOver, +/// which reads the row as one element, "label, value". A row with no avatar is a `List1View`. +/// +/// Both texts stay on one line. When they do not fit together they share the width, so the +/// value never disappears behind a long label; the value truncates in the middle, keeping the +/// end of a username that may be what tells two recipients apart. @available(iOS 14, macOS 11, *) public struct List8View: View { @@ -43,7 +47,6 @@ public struct List8View: View { .dashFont(.subheadMedium) .foregroundColor(Color.dash.tertiaryText) .lineLimit(1) - .layoutPriority(1) HStack(spacing: 8) { avatar @@ -55,6 +58,7 @@ public struct List8View: View { .dashFont(.subhead) .foregroundColor(Color.dash.primaryText) .lineLimit(1) + .truncationMode(.middle) } .frame(maxWidth: .infinity, alignment: .trailing) } diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index f7b61e6..1424721 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -189,8 +189,9 @@ List1View(label: "Network", value: "Dash") File `Table List/List8View.swift` · `@available(iOS 14, macOS 11, *)` A label ↔ value row with a round avatar before the value — for "who" rows, such as the -recipient on a payment confirmation. Generic over the avatar view, which the row sizes to -24 × 24 and clips round; the library does not load images itself. +recipient on a payment confirmation. Generic over the avatar view, which the row lays out in a +fixed 24 × 24 frame and clips round; pass a view that fills its frame (a `resizable()` image, +a shape). The library does not load images itself. ```swift List8View(label: "To", value: "username") { @@ -198,7 +199,8 @@ List8View(label: "To", value: "username") { } ``` -Both texts stay on one line; the value truncates first, the label only when it alone is too -wide. Label and value are centred on the avatar. The avatar keeps its 24 pt at every text -size. VoiceOver reads the row as one element ("To, username") and skips the avatar. For a -row with no avatar, use `List1View`. +Both texts stay on one line. When they do not fit together they share the width, so the value +never disappears behind a long label; the value truncates in the middle ("alice-of…ments"), +keeping the end of a username visible. Label and value are centred on the avatar, which makes +the row 48 pt tall — 4 pt taller than a `List1View`. VoiceOver reads the row as one element +("To, username") and skips the avatar. For a row with no avatar, use `List1View`. From 1a39caeb3dc91eed5b8aa98827d48963310d97b1 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:09:54 +0300 Subject: [PATCH 04/13] fix(list): let a long List8View label keep the room a short value leaves The trailing group took every spare point (maxWidth .infinity), capping the label at half the row even beside a three-letter value. A Spacer(minLength: 20) between them gives each text its own width and splits only when both are long. Preview gains the long-label/short-value state. Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index ca5881e..8888623 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -42,12 +42,14 @@ public struct List8View: View { } public var body: some View { - HStack(spacing: 20) { + HStack(spacing: 0) { Text(label) .dashFont(.subheadMedium) .foregroundColor(Color.dash.tertiaryText) .lineLimit(1) + Spacer(minLength: 20) + HStack(spacing: 8) { avatar .frame(width: 24, height: 24) @@ -60,7 +62,6 @@ public struct List8View: View { .lineLimit(1) .truncationMode(.middle) } - .frame(maxWidth: .infinity, alignment: .trailing) } .padding(.horizontal, 14) .padding(.vertical, 12) @@ -79,6 +80,9 @@ public struct List8View: View { List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { Circle().fill(Color.dash.gray300) } + List8View(label: "A longer translated label", value: "bob") { + Circle().fill(Color.dash.gray300) + } List8View(label: "A longer translated label", value: "a-very-long-username") { Circle().fill(Color.dash.gray300) } From b2b9c88674807a72aa0af9be0122facb437a6555 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:13:20 +0300 Subject: [PATCH 05/13] style(list): trim the List8View header whitespace Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index 8888623..fed659a 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -1,4 +1,4 @@ -// +// // Created by Roman Chornyi // Copyright © 2026 Dash Core Group. All rights reserved. // @@ -15,7 +15,6 @@ // limitations under the License. // - import SwiftUI /// A label ↔ value row with a round 24 pt avatar before the value — the design system's From 6118f0c36b6335c0528c5e335a5e6385bb690b0f Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:15:19 +0300 Subject: [PATCH 06/13] docs(list): compare List8View's height with a one-line List1View Co-Authored-By: Claude Opus 5.5 --- docs/lists-and-rows.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index 1424721..2a21240 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -202,5 +202,5 @@ List8View(label: "To", value: "username") { Both texts stay on one line. When they do not fit together they share the width, so the value never disappears behind a long label; the value truncates in the middle ("alice-of…ments"), keeping the end of a username visible. Label and value are centred on the avatar, which makes -the row 48 pt tall — 4 pt taller than a `List1View`. VoiceOver reads the row as one element +the row 48 pt tall — 4 pt taller than a one-line `List1View`. VoiceOver reads the row as one element ("To, username") and skips the avatar. For a row with no avatar, use `List1View`. From b594ea6702663f19d08dd59d22979056262d1f41 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:21:50 +0300 Subject: [PATCH 07/13] feat(list): make the List8View avatar optional List8View(label:value:) builds the row without an avatar: the value stands alone at the trailing edge and the row is 44pt. The avatar variant is unchanged. Co-Authored-By: Claude Opus 5.5 --- CLAUDE.md | 2 +- README.md | 2 +- Sources/DashUIKit/Table List/List8View.swift | 31 +++++++++++++++----- docs/lists-and-rows.md | 14 +++++---- 4 files changed, 33 insertions(+), 16 deletions(-) diff --git a/CLAUDE.md b/CLAUDE.md index 180f438..28b31af 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -39,7 +39,7 @@ Sources/DashUIKit/ Geometry/ Layout readers + scale-to-fit helpers Icons/ Code-drawn icons (XmarkIcon, CheckmarkIcon, ChevronIcon, InfoRoundIcon) Illustrations/ Loading / success / error illustrations - Table List/ List1View (label/value row), List8View (label/avatar + value row) + Table List/ List1View (label/value row), List8View (label/value row, optional avatar) ViewModifiers/ MenuViewModifier (card chrome) Foundation/ Color / Font / DashTextStyle / Image / line-height / Bundle Resources/ Media.xcassets (colors, icons, illustrations) diff --git a/README.md b/README.md index 8a6a9db..12a55da 100644 --- a/README.md +++ b/README.md @@ -81,7 +81,7 @@ a component already exists before building your own. | `MenuItem` | Settings/menu row with flexible trailing accessory | [Lists & rows](docs/lists-and-rows.md) | | `RadioButtonRow` | Selectable row — radio or checkbox style | [Lists & rows](docs/lists-and-rows.md) | | `List1View` | Simple label ↔ value row | [Lists & rows](docs/lists-and-rows.md) | -| `List8View` | Label ↔ avatar + value row | [Lists & rows](docs/lists-and-rows.md) | +| `List8View` | Label ↔ value row with an optional avatar | [Lists & rows](docs/lists-and-rows.md) | | `NavigationBar` | Custom three-slot nav bar + `NavigationBarElement` buttons | [Navigation & containers](docs/navigation-and-containers.md) | | `BottomSheet` | Sheet chrome (grabber + nav bar) with self-sizing support | [Navigation & containers](docs/navigation-and-containers.md) | | `MenuViewModifier` | Card chrome — rounded background + shadow | [Navigation & containers](docs/navigation-and-containers.md) | diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index fed659a..bbcc6bf 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -20,9 +20,10 @@ import SwiftUI /// A label ↔ value row with a round 24 pt avatar before the value — the design system's /// `list-8`, for "who" rows such as the recipient on a payment confirmation. /// -/// The avatar is the caller's view, laid out in a fixed 24 × 24 frame and clipped round; pass -/// a view that fills its frame (a `resizable()` image, a shape). It is hidden from VoiceOver, -/// which reads the row as one element, "label, value". A row with no avatar is a `List1View`. +/// The avatar is optional. When given, it is the caller's view, laid out in a fixed 24 × 24 +/// frame and clipped round; pass a view that fills its frame (a `resizable()` image, a shape). +/// It is hidden from VoiceOver, which reads the row as one element, "label, value". Without +/// one (`List8View(label:value:)`) the value stands alone at the trailing edge. /// /// Both texts stay on one line. When they do not fit together they share the width, so the /// value never disappears behind a long label; the value truncates in the middle, keeping the @@ -32,7 +33,7 @@ public struct List8View: View { public var label: String public var value: String - private let avatar: Avatar + private let avatar: Avatar? public init(label: String, value: String, @ViewBuilder avatar: () -> Avatar) { self.label = label @@ -50,10 +51,12 @@ public struct List8View: View { Spacer(minLength: 20) HStack(spacing: 8) { - avatar - .frame(width: 24, height: 24) - .clipShape(Circle()) - .accessibilityHidden(true) + if let avatar { + avatar + .frame(width: 24, height: 24) + .clipShape(Circle()) + .accessibilityHidden(true) + } Text(value) .dashFont(.subhead) @@ -68,6 +71,17 @@ public struct List8View: View { } } +@available(iOS 14, macOS 11, *) +public extension List8View where Avatar == EmptyView { + + /// A row without an avatar. + init(label: String, value: String) { + self.label = label + self.value = value + self.avatar = nil + } +} + #if DEBUG @available(iOS 17, macOS 14, *) @@ -76,6 +90,7 @@ public struct List8View: View { List8View(label: "To", value: "username") { Circle().fill(Color.dash.gray300) } + List8View(label: "To", value: "username") List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { Circle().fill(Color.dash.gray300) } diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index 2a21240..a6d5740 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -188,19 +188,21 @@ List1View(label: "Network", value: "Dash") File `Table List/List8View.swift` · `@available(iOS 14, macOS 11, *)` -A label ↔ value row with a round avatar before the value — for "who" rows, such as the -recipient on a payment confirmation. Generic over the avatar view, which the row lays out in a -fixed 24 × 24 frame and clips round; pass a view that fills its frame (a `resizable()` image, -a shape). The library does not load images itself. +A label ↔ value row with an optional round avatar before the value — for "who" rows, such as +the recipient on a payment confirmation. Generic over the avatar view, which the row lays out +in a fixed 24 × 24 frame and clips round; pass a view that fills its frame (a `resizable()` +image, a shape). The library does not load images itself. ```swift List8View(label: "To", value: "username") { Image("avatar").resizable().scaledToFill() // @ViewBuilder avatar } + +List8View(label: "To", value: "username") // no avatar ``` Both texts stay on one line. When they do not fit together they share the width, so the value never disappears behind a long label; the value truncates in the middle ("alice-of…ments"), keeping the end of a username visible. Label and value are centred on the avatar, which makes -the row 48 pt tall — 4 pt taller than a one-line `List1View`. VoiceOver reads the row as one element -("To, username") and skips the avatar. For a row with no avatar, use `List1View`. +the row 48 pt tall (44 pt without an avatar, like a one-line `List1View`). VoiceOver reads the +row as one element ("To, username") and skips the avatar. From 2cfeeee48e3c556ec7945f30275d2dc2a967811c Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:25:43 +0300 Subject: [PATCH 08/13] feat(list): let a List8View avatar be decided at runtime init(label:value:avatar: Avatar?) drops the avatar slot for nil, where an if inside the builder would still reserve 24pt and leave a gap, and keeps rows with and without an avatar one type. Docs say when to use it and how a no-avatar List8View differs from List1View; the summary line calls the avatar optional; a long no-avatar preview state. Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 19 ++++++++++++++----- docs/lists-and-rows.md | 10 ++++++++++ 2 files changed, 24 insertions(+), 5 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index bbcc6bf..68ccd98 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -17,13 +17,14 @@ import SwiftUI -/// A label ↔ value row with a round 24 pt avatar before the value — the design system's +/// A label ↔ value row with an optional round avatar before the value — the design system's /// `list-8`, for "who" rows such as the recipient on a payment confirmation. /// -/// The avatar is optional. When given, it is the caller's view, laid out in a fixed 24 × 24 -/// frame and clipped round; pass a view that fills its frame (a `resizable()` image, a shape). -/// It is hidden from VoiceOver, which reads the row as one element, "label, value". Without -/// one (`List8View(label:value:)`) the value stands alone at the trailing edge. +/// The avatar is the caller's view, laid out in a fixed 24 × 24 frame and clipped round; pass +/// a view that fills its frame (a `resizable()` image, a shape). It is hidden from VoiceOver, +/// which reads the row as one element, "label, value". Without one — `List8View(label:value:)`, +/// or `avatar: nil` when only some recipients have one — the value stands alone at the +/// trailing edge and the row takes no avatar space. /// /// Both texts stay on one line. When they do not fit together they share the width, so the /// value never disappears behind a long label; the value truncates in the middle, keeping the @@ -41,6 +42,13 @@ public struct List8View: View { self.avatar = avatar() } + /// A row whose avatar is decided at runtime: `nil` lays the row out without one. + public init(label: String, value: String, avatar: Avatar?) { + self.label = label + self.value = value + self.avatar = avatar + } + public var body: some View { HStack(spacing: 0) { Text(label) @@ -91,6 +99,7 @@ public extension List8View where Avatar == EmptyView { Circle().fill(Color.dash.gray300) } List8View(label: "To", value: "username") + List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row", avatar: Circle?.none) List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { Circle().fill(Color.dash.gray300) } diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index a6d5740..ab56a89 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -199,10 +199,20 @@ List8View(label: "To", value: "username") { } List8View(label: "To", value: "username") // no avatar + +List8View(label: "To", value: name, // avatar decided at runtime + avatar: image.map { Image(uiImage: $0).resizable() }) ``` +Use the `avatar:` value init, not an `if` inside the builder, when only some recipients have +an avatar: a builder that draws nothing still reserves the 24 pt slot, while `nil` removes it. + Both texts stay on one line. When they do not fit together they share the width, so the value never disappears behind a long label; the value truncates in the middle ("alice-of…ments"), keeping the end of a username visible. Label and value are centred on the avatar, which makes the row 48 pt tall (44 pt without an avatar, like a one-line `List1View`). VoiceOver reads the row as one element ("To, username") and skips the avatar. + +Without an avatar it differs from `List1View` on purpose: the value keeps one line (truncating +in the middle) and the row is one VoiceOver element. Use `List8View` for a recipient or other +identifier, `List1View` for a value that should wrap. From 3362bd92dd94e122e4ccbec04f9969f8184ae8b7 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:31:04 +0300 Subject: [PATCH 09/13] refactor(list): drop the List8View avatar value init A builder that draws nothing already takes no space (measured: an empty if, EmptyView and the no-avatar init all lay out alike), so the Avatar? init and optional storage were not needed. The no-avatar init delegates to the builder one; docs show the if-let builder for recipients that only sometimes have an avatar. Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 27 ++++++-------------- docs/lists-and-rows.md | 10 ++++---- 2 files changed, 13 insertions(+), 24 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index 68ccd98..6136869 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -23,7 +23,7 @@ import SwiftUI /// The avatar is the caller's view, laid out in a fixed 24 × 24 frame and clipped round; pass /// a view that fills its frame (a `resizable()` image, a shape). It is hidden from VoiceOver, /// which reads the row as one element, "label, value". Without one — `List8View(label:value:)`, -/// or `avatar: nil` when only some recipients have one — the value stands alone at the +/// or a builder that draws nothing (`{ if let image { … } }`) — the value stands alone at the /// trailing edge and the row takes no avatar space. /// /// Both texts stay on one line. When they do not fit together they share the width, so the @@ -34,7 +34,7 @@ public struct List8View: View { public var label: String public var value: String - private let avatar: Avatar? + private let avatar: Avatar public init(label: String, value: String, @ViewBuilder avatar: () -> Avatar) { self.label = label @@ -42,13 +42,6 @@ public struct List8View: View { self.avatar = avatar() } - /// A row whose avatar is decided at runtime: `nil` lays the row out without one. - public init(label: String, value: String, avatar: Avatar?) { - self.label = label - self.value = value - self.avatar = avatar - } - public var body: some View { HStack(spacing: 0) { Text(label) @@ -59,12 +52,10 @@ public struct List8View: View { Spacer(minLength: 20) HStack(spacing: 8) { - if let avatar { - avatar - .frame(width: 24, height: 24) - .clipShape(Circle()) - .accessibilityHidden(true) - } + avatar + .frame(width: 24, height: 24) + .clipShape(Circle()) + .accessibilityHidden(true) Text(value) .dashFont(.subhead) @@ -84,9 +75,7 @@ public extension List8View where Avatar == EmptyView { /// A row without an avatar. init(label: String, value: String) { - self.label = label - self.value = value - self.avatar = nil + self.init(label: label, value: value) { EmptyView() } } } @@ -99,7 +88,7 @@ public extension List8View where Avatar == EmptyView { Circle().fill(Color.dash.gray300) } List8View(label: "To", value: "username") - List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row", avatar: Circle?.none) + List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row", ) List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { Circle().fill(Color.dash.gray300) } diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index ab56a89..f7dd562 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -200,17 +200,17 @@ List8View(label: "To", value: "username") { List8View(label: "To", value: "username") // no avatar -List8View(label: "To", value: name, // avatar decided at runtime - avatar: image.map { Image(uiImage: $0).resizable() }) +List8View(label: "To", value: name) { // only some recipients have one + if let image { Image(uiImage: image).resizable().scaledToFill() } +} ``` -Use the `avatar:` value init, not an `if` inside the builder, when only some recipients have -an avatar: a builder that draws nothing still reserves the 24 pt slot, while `nil` removes it. +A builder that draws nothing takes no space: the row lays out as if it had no avatar. Both texts stay on one line. When they do not fit together they share the width, so the value never disappears behind a long label; the value truncates in the middle ("alice-of…ments"), keeping the end of a username visible. Label and value are centred on the avatar, which makes -the row 48 pt tall (44 pt without an avatar, like a one-line `List1View`). VoiceOver reads the +the row 48 pt tall; without an avatar it is as tall as a one-line `List1View`. VoiceOver reads the row as one element ("To, username") and skips the avatar. Without an avatar it differs from `List1View` on purpose: the value keeps one line (truncating From 6f2dada972c6b9de7ed2fbfd2ad4f38def65bd16 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:34:54 +0300 Subject: [PATCH 10/13] docs(list): say which empty List8View avatar takes no space Only a builder that produces no view (an if without an else) collapses; an invisible view such as Color.clear keeps the slot. State the no-avatar height plainly, drop a stray trailing comma, and preview the if-false avatar. Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 9 ++++++--- docs/lists-and-rows.md | 5 +++-- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index 6136869..23499e4 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -23,8 +23,9 @@ import SwiftUI /// The avatar is the caller's view, laid out in a fixed 24 × 24 frame and clipped round; pass /// a view that fills its frame (a `resizable()` image, a shape). It is hidden from VoiceOver, /// which reads the row as one element, "label, value". Without one — `List8View(label:value:)`, -/// or a builder that draws nothing (`{ if let image { … } }`) — the value stands alone at the -/// trailing edge and the row takes no avatar space. +/// or a builder that produces no view (an `if` without an `else`, `{ if let image { … } }`) — +/// the value stands alone at the trailing edge and the row takes no avatar space. A view that +/// produces something invisible (`Color.clear`) still takes the slot. /// /// Both texts stay on one line. When they do not fit together they share the width, so the /// value never disappears behind a long label; the value truncates in the middle, keeping the @@ -88,7 +89,9 @@ public extension List8View where Avatar == EmptyView { Circle().fill(Color.dash.gray300) } List8View(label: "To", value: "username") - List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row", ) + List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { + if Bool(false) { Circle().fill(Color.dash.gray300) } + } List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { Circle().fill(Color.dash.gray300) } diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index f7dd562..47521d3 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -205,12 +205,13 @@ List8View(label: "To", value: name) { // only some recipients have o } ``` -A builder that draws nothing takes no space: the row lays out as if it had no avatar. +A builder that produces no view (an `if` without an `else`) takes no space: the row lays out as +if it had no avatar. A view that is merely invisible (`Color.clear`) still takes the 24 pt slot. Both texts stay on one line. When they do not fit together they share the width, so the value never disappears behind a long label; the value truncates in the middle ("alice-of…ments"), keeping the end of a username visible. Label and value are centred on the avatar, which makes -the row 48 pt tall; without an avatar it is as tall as a one-line `List1View`. VoiceOver reads the +the row 48 pt tall; without an avatar it is the text's height plus the 12 pt padding. VoiceOver reads the row as one element ("To, username") and skips the avatar. Without an avatar it differs from `List1View` on purpose: the value keeps one line (truncating From 44385a992b7b0df04d1d036410dea86c96fbade4 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 15:38:26 +0300 Subject: [PATCH 11/13] docs(list): tighten the List8View empty-avatar and height notes Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 2 +- docs/lists-and-rows.md | 14 ++++++++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index 23499e4..adbb661 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -23,7 +23,7 @@ import SwiftUI /// The avatar is the caller's view, laid out in a fixed 24 × 24 frame and clipped round; pass /// a view that fills its frame (a `resizable()` image, a shape). It is hidden from VoiceOver, /// which reads the row as one element, "label, value". Without one — `List8View(label:value:)`, -/// or a builder that produces no view (an `if` without an `else`, `{ if let image { … } }`) — +/// or a builder that produces no view (`EmptyView()`, an `if` without an `else`) — /// the value stands alone at the trailing edge and the row takes no avatar space. A view that /// produces something invisible (`Color.clear`) still takes the slot. /// diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index 47521d3..0cb0c0d 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -201,18 +201,20 @@ List8View(label: "To", value: "username") { List8View(label: "To", value: "username") // no avatar List8View(label: "To", value: name) { // only some recipients have one - if let image { Image(uiImage: image).resizable().scaledToFill() } + if let avatar { avatar.resizable().scaledToFill() } // avatar: Image? } ``` -A builder that produces no view (an `if` without an `else`) takes no space: the row lays out as -if it had no avatar. A view that is merely invisible (`Color.clear`) still takes the 24 pt slot. +A builder that produces no view (an `if` without an `else`, `EmptyView()`) takes no space: the +row lays out as if it had no avatar. A view that is merely invisible (`Color.clear`) still takes +the 24 pt slot. For an avatar that is still loading, draw a placeholder instead of nothing, or +the value moves 32 pt left when the image arrives. Both texts stay on one line. When they do not fit together they share the width, so the value never disappears behind a long label; the value truncates in the middle ("alice-of…ments"), -keeping the end of a username visible. Label and value are centred on the avatar, which makes -the row 48 pt tall; without an avatar it is the text's height plus the 12 pt padding. VoiceOver reads the -row as one element ("To, username") and skips the avatar. +keeping the end of a username visible. With an avatar, label and value are centred on it and +the row is 48 pt tall; without one it is the text's height plus 12 pt above and below. +VoiceOver reads the row as one element ("To, username") and skips the avatar. Without an avatar it differs from `List1View` on purpose: the value keeps one line (truncating in the middle) and the row is one VoiceOver element. Use `List8View` for a recipient or other From 728f6e9efc5b6ab56fcba10466f1e8470af04b57 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 16:05:00 +0300 Subject: [PATCH 12/13] feat(list): let the caller choose how a List8View value truncates truncationMode defaults to .middle, which keeps a username's end; a display name reads better cut at the tail. The modifier sits on the inner Text, so it has to be a parameter rather than an outer modifier. The preview's if-false avatar row says what it exercises. Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 25 +++++++++++++++----- docs/lists-and-rows.md | 5 ++-- 2 files changed, 22 insertions(+), 8 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index adbb661..7db60f1 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -28,18 +28,26 @@ import SwiftUI /// produces something invisible (`Color.clear`) still takes the slot. /// /// Both texts stay on one line. When they do not fit together they share the width, so the -/// value never disappears behind a long label; the value truncates in the middle, keeping the -/// end of a username that may be what tells two recipients apart. +/// value never disappears behind a long label. The value truncates in the middle by default, +/// keeping the end of a username that may be what tells two recipients apart; pass +/// `truncationMode: .tail` for a display name. @available(iOS 14, macOS 11, *) public struct List8View: View { public var label: String public var value: String + public var truncationMode: Text.TruncationMode private let avatar: Avatar - public init(label: String, value: String, @ViewBuilder avatar: () -> Avatar) { + public init( + label: String, + value: String, + truncationMode: Text.TruncationMode = .middle, + @ViewBuilder avatar: () -> Avatar + ) { self.label = label self.value = value + self.truncationMode = truncationMode self.avatar = avatar() } @@ -62,7 +70,7 @@ public struct List8View: View { .dashFont(.subhead) .foregroundColor(Color.dash.primaryText) .lineLimit(1) - .truncationMode(.middle) + .truncationMode(truncationMode) } } .padding(.horizontal, 14) @@ -75,8 +83,8 @@ public struct List8View: View { public extension List8View where Avatar == EmptyView { /// A row without an avatar. - init(label: String, value: String) { - self.init(label: label, value: value) { EmptyView() } + init(label: String, value: String, truncationMode: Text.TruncationMode = .middle) { + self.init(label: label, value: value, truncationMode: truncationMode) { EmptyView() } } } @@ -89,9 +97,14 @@ public extension List8View where Avatar == EmptyView { Circle().fill(Color.dash.gray300) } List8View(label: "To", value: "username") + // An avatar builder that produces no view lays out like the no-avatar row above. + // `Bool(false)`, not `false`, keeps the compiler from warning about dead code. List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { if Bool(false) { Circle().fill(Color.dash.gray300) } } + List8View(label: "To", value: "Alexandra Konstantinopoulou-Whitfield", truncationMode: .tail) { + Circle().fill(Color.dash.gray300) + } List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { Circle().fill(Color.dash.gray300) } diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index 0cb0c0d..ef384b9 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -211,8 +211,9 @@ the 24 pt slot. For an avatar that is still loading, draw a placeholder instead the value moves 32 pt left when the image arrives. Both texts stay on one line. When they do not fit together they share the width, so the value -never disappears behind a long label; the value truncates in the middle ("alice-of…ments"), -keeping the end of a username visible. With an avatar, label and value are centred on it and +never disappears behind a long label. The value truncates in the middle by default +("alice-of…ments"), keeping the end of a username visible; pass `truncationMode: .tail` for a +display name ("Alexandra Kon…"). With an avatar, label and value are centred on it and the row is 48 pt tall; without one it is the text's height plus 12 pt above and below. VoiceOver reads the row as one element ("To, username") and skips the avatar. From a678b6a452a9fbfebac91b99db808e211d336300 Mon Sep 17 00:00:00 2001 From: romchornyi <270373998+romchornyi@users.noreply.github.com> Date: Mon, 19 Oct 2026 16:10:35 +0300 Subject: [PATCH 13/13] docs(list): say an outer truncationMode reaches only the List8View label The tail-truncation preview uses a name long enough to cut; the empty avatar row uses a plain if false (it does not warn); the List1View comparison calls middle truncation the default. Co-Authored-By: Claude Opus 5.5 --- Sources/DashUIKit/Table List/List8View.swift | 8 ++++---- docs/lists-and-rows.md | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Sources/DashUIKit/Table List/List8View.swift b/Sources/DashUIKit/Table List/List8View.swift index 7db60f1..49d779f 100644 --- a/Sources/DashUIKit/Table List/List8View.swift +++ b/Sources/DashUIKit/Table List/List8View.swift @@ -30,7 +30,8 @@ import SwiftUI /// Both texts stay on one line. When they do not fit together they share the width, so the /// value never disappears behind a long label. The value truncates in the middle by default, /// keeping the end of a username that may be what tells two recipients apart; pass -/// `truncationMode: .tail` for a display name. +/// `truncationMode: .tail` for a display name. The value sets its own mode, so a +/// `.truncationMode(_:)` modifier on the row reaches only the label. @available(iOS 14, macOS 11, *) public struct List8View: View { @@ -98,11 +99,10 @@ public extension List8View where Avatar == EmptyView { } List8View(label: "To", value: "username") // An avatar builder that produces no view lays out like the no-avatar row above. - // `Bool(false)`, not `false`, keeps the compiler from warning about dead code. List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { - if Bool(false) { Circle().fill(Color.dash.gray300) } + if false { Circle().fill(Color.dash.gray300) } } - List8View(label: "To", value: "Alexandra Konstantinopoulou-Whitfield", truncationMode: .tail) { + List8View(label: "To", value: "Alexandra Konstantinopoulou-Whitfield of the Treasury Reserve", truncationMode: .tail) { Circle().fill(Color.dash.gray300) } List8View(label: "To", value: "a-very-long-username-that-does-not-fit-the-row") { diff --git a/docs/lists-and-rows.md b/docs/lists-and-rows.md index ef384b9..c75da4c 100644 --- a/docs/lists-and-rows.md +++ b/docs/lists-and-rows.md @@ -217,6 +217,6 @@ display name ("Alexandra Kon…"). With an avatar, label and value are centred o the row is 48 pt tall; without one it is the text's height plus 12 pt above and below. VoiceOver reads the row as one element ("To, username") and skips the avatar. -Without an avatar it differs from `List1View` on purpose: the value keeps one line (truncating -in the middle) and the row is one VoiceOver element. Use `List8View` for a recipient or other +Without an avatar it differs from `List1View` on purpose: the value keeps one line (truncating, +in the middle by default) and the row is one VoiceOver element. Use `List8View` for a recipient or other identifier, `List1View` for a value that should wrap.