staging: match wallet plan limits to pricing cards - #987
Merged
Conversation
Keep the current subscription card aligned with the backend plan matrix by surfacing 5h and 7d usage windows through the self-subscription response and wallet normalization path. Constraint: staging already serves the new plan matrix, and the UI must not invent short-window limits locally. Rejected: static plan-specific markup | it would drift from the API and duplicate data. Confidence: high Scope-risk: moderate Directive: keep window_5h and window_7d mirrored through controller, type, and normalization layers. Tested: go test ./model -run 'TestMigrateStandardSubscriptionPlanLimits(UpdatesDuplicateStandardRows|RestoresExistingRows|UsesPersistedQuotaUnit|RecognizesStagingTestPrefix)|TestStandardSubscriptionPlanLimitsMatchProductContract' -count=1; go test ./controller -run 'TestGetSubscriptionPlansExposesConfiguredUsageLimitsAndShortWindowFields|TestGetSubscriptionPlansAnnotatesTierRankAndRelation' -count=1; bun test src/features/wallet/components/subscription-plans-card.test.tsx Not-tested: full web build and live staging smoke
Keep the live usage meters untouched while making plan-card limits compact and data-driven.\n\nConstraint: console copy must remain localized across all supported languages\nRejected: adding the website Tools Credits block | wallet plan data does not expose that entitlement\nConfidence: high\nScope-risk: narrow\nDirective: keep current-plan progress meters on their existing UsageWindowMeter path\nTested: spec self-review; git diff --check\nNot-tested: implementation and UI tests pending spec review
Lock the approved pricing-card alignment into a test-first implementation sequence.\n\nConstraint: preserve live usage meters and backend contracts\nRejected: broad wallet-card refactor | the change is limited to the summary boundary\nConfidence: high\nScope-risk: narrow\nDirective: implement through the focused PlanLimitSummary path\nTested: plan self-review; placeholder scan; git diff --check\nNot-tested: implementation and UI tests pending
Present short-window caps in one localized pricing-style panel while preserving live usage meters.\n\nConstraint: all user-visible console copy must exist in all eight locales\nRejected: adding a Tools Credits section | wallet plan data has no matching entitlement\nConfidence: high\nScope-risk: narrow\nDirective: keep current-plan UsageWindowMeter layout unchanged\nTested: focused Bun test (81 pass); recharge tests (9 pass); i18n sync; typecheck; touched-file ESLint; JSON key audit; git diff --check\nNot-tested: production deployment and interactive browser screenshot because the local dev browser kept an empty React root
Resolve staging drift while preserving the approved compact wallet limit summary.\n\nConstraint: target staging has advanced and its current-plan meter order is canonical\nRejected: reverting staging's newer current-plan layout | it would regress the target branch\nConfidence: high\nScope-risk: moderate\nDirective: keep plan-card summary changes isolated from live usage-meter behavior\nTested: merged wallet tests (81 pass); recharge tests (9 pass); typecheck; touched-file ESLint; git diff --check\nNot-tested: interactive browser screenshot because local dev browser kept an empty React root
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.
Summary
Validation
The full repository lint still reports pre-existing errors outside this change. The local dev compiler rebuilt successfully; the connected browser kept an empty React root, so interactive screenshot verification remains an environment limitation.