Price display: station sign drops the £ (134.9) — matches roadside signs; pounds & pence uses forecourt superscript style £1.29⁹/L (small superscript third digit, small /L); attributed Text on list/widgets/Live Activity, Unicode superscript in Siri cards
This commit is contained in:
@@ -70,8 +70,7 @@ private struct FuelBoardLiveActivityView: View {
|
||||
|
||||
// RIGHT — price
|
||||
VStack(alignment: .trailing, spacing: 2) {
|
||||
Text(context.state.priceText)
|
||||
.font(.title2.bold().monospacedDigit())
|
||||
FuelStore.priceTextAttributed(context.state.pricePence, size: 22, weight: .bold)
|
||||
Text("Tap for directions")
|
||||
.font(.caption2)
|
||||
.foregroundStyle(.secondary)
|
||||
@@ -87,8 +86,7 @@ private struct FuelBoardLiveActivityPriceView: View {
|
||||
let context: ActivityViewContext<FuelBoardLiveActivityAttributes>
|
||||
|
||||
var body: some View {
|
||||
Text(context.state.priceText)
|
||||
.font(.headline.bold().monospacedDigit())
|
||||
FuelStore.priceTextAttributed(context.state.pricePence, size: 17, weight: .bold)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -128,7 +126,7 @@ extension FuelBoardLiveActivityAttributes.ContentState {
|
||||
}
|
||||
|
||||
/// Price string from pence, in the user's chosen display style
|
||||
/// (station sign "£129.9" or pounds "£1.299").
|
||||
/// (station sign "129.9" or pounds "£1.29⁹/L").
|
||||
var priceText: String {
|
||||
FuelStore.priceText(pricePence)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user