[PM-37920] fix: Align Plan screen cart summary with web #2683
Open
SaintPatrck wants to merge 2 commits into
Open
[PM-37920] fix: Align Plan screen cart summary with web #2683SaintPatrck wants to merge 2 commits into
SaintPatrck wants to merge 2 commits into
Conversation
…r tax, add Total row) Brings the iOS Plan screen's billing details section into parity with the canonical web cart-summary contract documented in clients/subscription-card-line-item-findings.md. Two behavioral changes: - Estimated Tax always renders when a subscription exists (formats to "$0.00" when zero) instead of being hidden at zero. Tax is in the web spec's "always render" bucket. - A new Total row renders below Estimated Tax with the cadence suffix (e.g. "$25.55 / year"), backed by the existing PremiumSubscription.totalAmount computed property. Both rows remain gated by showBillingDetails (active / past-due / update-payment statuses), preserving web's cart-presence gating. The Total row uses .bodyBold typography per design feedback. This maps web's bodyLargeEmphasis and the Android client's bodyLargeEmphasis = DM Sans W700 15sp/20sp to the iOS style-guide equivalent. The shared billingRow helper now takes an optional font: StyleGuideFont = .body parameter so callers default to the existing body style. Out of scope: storage-cost zero-suppression divergence from web's cart-presence gating is intentionally left for a follow-up. Note: local test execution was deferred to CI. The repo pins Xcode 26.2 (.xcode-version) but the local environment is on 26.1.1, and main-branch code unrelated to this change references ASCredentialServiceIdentifier.IdentifierType.app which requires the iOS 26.2 SDK. CI runs the pinned Xcode and will execute the full test suite. Format and lint were verified locally (swiftformat / swiftlint clean for in-scope paths).
Contributor
|
Claude Code is reviewing this pull request... If this comment does not update with results, check the Actions log. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2683 +/- ##
===========================================
- Coverage 87.24% 41.05% -46.20%
===========================================
Files 1918 593 -1325
Lines 172116 33009 -139107
===========================================
- Hits 150165 13552 -136613
+ Misses 21951 19457 -2494 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
a7191e6 to
635c64f
Compare
b4e6ea3 to
23329e2
Compare
- Splits the billingRow helper so only the label takes a weight override (labelWeight, mirroring the repo's .styleGuide(.body, weight: .bold) pattern). Using .bodyBold directly was ineffective because Text.styleGuide(_:) defaults weight to .regular and applies .fontWeight after the font, overriding the bold baked into the token. - Drops the Storage cost row's > 0 zero-suppression so it always renders within the billing section ($0.00 when zero), matching web's cart-summary always-render pattern alongside Estimated Tax and Total. - Strips task-anchored DocC sentences that just restated names or referenced callers, matching the repo's lean-comment style.
23329e2 to
944aad2
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🎟️ Tracking
PM-37920
📔 Objective
Aligns the Plan screen's billing section with the canonical web cart-summary contract:
$0.00at zero) instead of being hidden.$0.00when zero) instead of being hidden at zero.$25.55 / year), backed byPremiumSubscription.totalAmount.Total typography uses
labelWeight: .bold(via.styleGuide(.body, weight: .bold)) to mirror web'sbodyLargeEmphasis(Android equivalent: DM Sans W700, 15sp/20sp). The sharedbillingRowhelper gained an optionallabelWeight:parameter so other rows are unaffected.📸 Screenshots