Siri: full-width Directions row on price card — fixes squashed 2-line button in narrow snippet

This commit is contained in:
FuelBoard Contributor
2026-08-14 14:45:51 +01:00
parent 6d7254ebba
commit b46c09109e
+3 -3
View File
@@ -356,6 +356,7 @@ struct FuelPriceCard: View {
var directionsIntent: OpenDirectionsIntent? = nil var directionsIntent: OpenDirectionsIntent? = nil
var body: some View { var body: some View {
VStack(alignment: .leading, spacing: 10) {
HStack(spacing: 14) { HStack(spacing: 14) {
Image(systemName: "fuelpump.fill") Image(systemName: "fuelpump.fill")
.font(.title2) .font(.title2)
@@ -374,18 +375,17 @@ struct FuelPriceCard: View {
} }
} }
Spacer(minLength: 8) Spacer(minLength: 8)
VStack(alignment: .trailing, spacing: 6) {
Text(price) Text(price)
.font(.title2.bold()) .font(.title2.bold())
.monospacedDigit() .monospacedDigit()
}
if let directionsIntent { if let directionsIntent {
Button(intent: directionsIntent) { Button(intent: directionsIntent) {
Label("Directions", systemImage: "map.fill") Label("Directions", systemImage: "map.fill")
.font(.footnote.weight(.medium)) .font(.footnote.weight(.medium))
.frame(maxWidth: .infinity)
} }
.buttonStyle(.bordered) .buttonStyle(.bordered)
.controlSize(.small)
}
} }
} }
.padding(12) .padding(12)