Repository navigation
FE-3046 refactor(workspace): render the subscription checkout steps from account-ui - #19100
Conversation
…resolved A checkout entry named a plan but its return_to did not resolve through buildReturnUrl, so the form rendered with a Back and Close that led nowhere. readEntry now records UNKNOWN_RETURN_TARGET for that entry, the same path a plan-less link takes.
…stem The cva recipe behind Button.vue lived in the app, so a workspace package could not render a button with the app's classes. It now ships from @comfyorg/design-system/button.variants and every importer reads it there. apps/website keeps its own copy.
…ants' into jaewon/account-ui-checkout-surfaces
…stem The saved-method picker moves into @comfyorg/account-ui next, and it has to render the app's select classes. The recipe now ships from @comfyorg/design-system/select.variants and its three importers read it there.
…form and success The cloud app's embedded checkout steps, as components billing-web can render too: the new-subscription confirm (price breakdown, promo code, saved methods, card form, 3DS and parked-checkout recovery), the plan-change confirm with its reactivation disclosure, the terms notice and the success screen. Hosts pass translated copy, the plan they resolved and the quote. The class recipes and cn() are bundled into the published build, reka-ui is a peer.
…unt-ui The new-subscription confirm, the plan-change confirm and the success step now render @comfyorg/account-ui's checkout components. The app components keep their props and events and bind the app's catalog, translations, Stripe key, theme, subscription status and journey telemetry. The copies they replace (the card-form wrapper, the terms note and the quote formatting helpers) are deleted; their tests move to the package or to the binding.
…ace-adopt-account-ui-checkout
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: Comfy-Org/ComfyUI_frontend/.coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (17)
💤 Files with no reviewable changes (6)
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review. 📝 WalkthroughWalkthroughSubscription workspaces now use shared account UI checkout components for payment confirmation, subscription transitions, and success display. A new composable provides checkout copy and plan data. Cloud tier pricing uses catalog data, and local quote-formatting and duration helpers are removed. ChangesSubscription checkout adoption
Priority: ➖ Normal Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Refactor Suggested reviewers: Merge Risk: ⚪ Minimal · up to The subscription checkout screens now render from the shared account UI components, and the reported renders are identical to before. No concrete regression has been identified. It is reasonable to merge once the normal typecheck and test runs pass. Security Architecture ReviewSecurity architecture risk: 🟡 Moderate · up to Shared components now handle subscription confirmation and payment interactions. The app appears to retain control of checkout state and resulting actions, but end-to-end enforcement and rollout behavior were not established. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
🚥 Pre-merge checks | ✅ 6 | ❓ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (6 passed)
Full details: End-To-End Regression Coverage For FixesExplanation The PR contains bug-fix signals in its commit subjects, and the listed application changes contain no ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
🎨 Storybook: ✅ Built — View Storybook🎭 Playwright: ✅ 2157 passed, 0 failed · 1 flaky📊 Browser Reports
🌾 Fallow: ✅ PassedFallow audits the diff for duplication, complexity and dead code. It gates on new findings only, so when the audit completes, a red is something this PR introduced or moved — never inherited backlog. A red can also mean the audit itself did not finish; the details below say which happened. No new findings in the changed files. Reproduce locally# the base the gate compared against
npx fallow audit --root . --quiet --format json \
--changed-since 8a2ff4eeb534100752d2cfb44c33b00c67f89f62
Full docs: ADR-DEVEX-LINT-0015 🧩 Custom Nodes Ecosystem Matrix: ✅ PassedExecutes the frontend JS of every registry pack that ships any, against this change, in both renderers. The eight
On a pin-bump PR, a red gate means the ecosystem moved — not that your diff broke something. That is what the bump PR is for. Outside a pin bump or a cold rebuild of the unpinned tail, a red means the diff. Note the corpus size and the executed count are different numbers, and the verdict is against the executed count: roughly 3,100 of ~5,100 packs ship no extension-shaped JS and are skipped. Reproduce locally# build one shard's fixture, then run it
python3 scripts/registry-census/build_matrix.py --shard 1/4
MATRIX_RENDERER=vue MATRIX_VUE=1 \
npx vitest run --config vitest.matrix.config.mts
Full docs: scripts/registry-census/README.md 📦 Bundle: 10 MB gzip 🔴 +3.82 kBDetailsSummary
Category Glance App Entry Points — 3.77 kB (baseline 3.77 kB) • ⚪ 0 BMain entry bundles and manifests
Status: 1 added / 1 removed Graph Workspace — 1.45 MB (baseline 1.45 MB) • ⚪ 0 BGraph editor runtime, canvas, workflow orchestration
Status: 2 added / 2 removed / 1 unchanged Views & Navigation — 134 kB (baseline 133 kB) • 🔴 +203 BTop-level views, pages, and routed surfaces
Status: 14 added / 14 removed / 4 unchanged Panels & Settings — 640 kB (baseline 643 kB) • 🟢 -2.97 kBConfiguration panels, inspectors, and settings screens
Status: 12 added / 12 removed / 16 unchanged User & Accounts — 39.4 kB (baseline 39.4 kB) • ⚪ 0 BAuthentication, profile, and account management bundles
Status: 7 added / 7 removed / 4 unchanged Editors & Dialogs — 126 kB (baseline 126 kB) • ⚪ 0 BModals, dialogs, drawers, and in-app editors
Status: 7 added / 7 removed / 1 unchanged UI Components — 125 kB (baseline 125 kB) • ⚪ 0 BReusable component library chunks
Status: 7 added / 7 removed / 9 unchanged Data & Services — 4.02 MB (baseline 4.02 MB) • 🟢 -5.73 kBStores, services, APIs, and repositories
Status: 12 added / 12 removed / 3 unchanged Utilities & Hooks — 579 kB (baseline 582 kB) • 🟢 -3.18 kBHelpers, composables, and utility bundles
Status: 20 added / 21 removed / 16 unchanged Vendor & Third-Party — 17.4 MB (baseline 17.4 MB) • ⚪ 0 BExternal libraries and shared vendor chunks Status: 18 unchanged Other — 17.9 MB (baseline 17.9 MB) • 🔴 +30.8 kBBundles that do not match a named category
Status: 88 added / 87 removed / 213 unchanged ⚡ Performance Report
Show regressions
All metrics
Historical variance (last 15 runs)
Trend (last 15 commits on main)
Raw data{
"timestamp": "2026-09-28T14:31:41.837Z",
"gitSha": "24bb2da284d729c43767d022ca606dcb45071ba6",
"branch": "jaewon/workspace-adopt-account-ui-checkout",
"measurements": [
{
"name": "canvas-idle",
"durationMs": 2058.7639999999965,
"styleRecalcs": 11,
"styleRecalcDurationMs": 6.391999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 551.2009999999999,
"heapDeltaBytes": -27652824,
"heapUsedBytes": 70563184,
"domNodes": -228,
"jsHeapTotalBytes": 3145728,
"scriptDurationMs": 12.423,
"eventListeners": -142,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66585365853659,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-idle",
"durationMs": 2036.8330000000014,
"styleRecalcs": 9,
"styleRecalcDurationMs": 3.702000000000002,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 498.24899999999997,
"heapDeltaBytes": -1474660,
"heapUsedBytes": 77118720,
"domNodes": -228,
"jsHeapTotalBytes": 262144,
"scriptDurationMs": 12.057999999999996,
"eventListeners": -164,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666393442622944,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1936.2439999999879,
"styleRecalcs": 78,
"styleRecalcDurationMs": 20.271,
"layouts": 12,
"layoutDurationMs": 5.314,
"taskDurationMs": 937.884,
"heapDeltaBytes": -12881624,
"heapUsedBytes": 65645500,
"domNodes": -228,
"jsHeapTotalBytes": 262144,
"scriptDurationMs": 165.593,
"eventListeners": -142,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.811304347826088,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "canvas-mouse-sweep",
"durationMs": 1956.935000000044,
"styleRecalcs": 83,
"styleRecalcDurationMs": 26.729999999999997,
"layouts": 12,
"layoutDurationMs": 5.233,
"taskDurationMs": 940.9889999999999,
"heapDeltaBytes": -9976376,
"heapUsedBytes": 68779104,
"domNodes": -228,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 170.934,
"eventListeners": -142,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1747.2019999999588,
"styleRecalcs": 33,
"styleRecalcDurationMs": 11.906,
"layouts": 6,
"layoutDurationMs": 1.653,
"taskDurationMs": 398.42,
"heapDeltaBytes": 1487796,
"heapUsedBytes": 80233160,
"domNodes": 53,
"jsHeapTotalBytes": 3145728,
"scriptDurationMs": 15.107,
"eventListeners": 15,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.664761904761907,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1750.9509999999864,
"styleRecalcs": 32,
"styleRecalcDurationMs": 13.556000000000001,
"layouts": 6,
"layoutDurationMs": 4.554,
"taskDurationMs": 457.418,
"heapDeltaBytes": -22700496,
"heapUsedBytes": 75742796,
"domNodes": -175,
"jsHeapTotalBytes": 3932160,
"scriptDurationMs": 15.271999999999997,
"eventListeners": -127,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665714285714284,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "dom-widget-clipping",
"durationMs": 735.951,
"styleRecalcs": 12,
"styleRecalcDurationMs": 3.8020000000000014,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 490.06899999999996,
"heapDeltaBytes": 18202712,
"heapUsedBytes": 97541348,
"domNodes": 0,
"jsHeapTotalBytes": 3932160,
"scriptDurationMs": 171.749,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66818181818181,
"p95FrameDurationMs": 16.699999999999818
},
{
"name": "dom-widget-clipping",
"durationMs": 764.5790000000261,
"styleRecalcs": 14,
"styleRecalcDurationMs": 5.001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 502.97999999999996,
"heapDeltaBytes": -3549628,
"heapUsedBytes": 94613056,
"domNodes": 0,
"jsHeapTotalBytes": 7340032,
"scriptDurationMs": 170.716,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.664444444444435,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "dom-widget-order-dense-n200-w200-i120",
"durationMs": 1219.4600000000264,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 893.7310000000001,
"heapDeltaBytes": 9050680,
"heapUsedBytes": 86162452,
"domNodes": 0,
"jsHeapTotalBytes": 3833856,
"scriptDurationMs": 67.14300000000001,
"eventListeners": 0,
"totalBlockingTimeMs": 571,
"frameDurationMs": 34.76000000000001,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-order-dense-n200-w200-i120",
"durationMs": 1208.0140000000483,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 881.794,
"heapDeltaBytes": 9888120,
"heapUsedBytes": 85400292,
"domNodes": 0,
"jsHeapTotalBytes": 4096000,
"scriptDurationMs": 68.333,
"eventListeners": 0,
"totalBlockingTimeMs": 570,
"frameDurationMs": 35.291176470588226,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "dom-widget-order-sparse-n1000-w20-i120",
"durationMs": 829.2119999999841,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 454.51700000000005,
"heapDeltaBytes": 14863188,
"heapUsedBytes": 88317544,
"domNodes": 0,
"jsHeapTotalBytes": 266240,
"scriptDurationMs": 148.885,
"eventListeners": 0,
"totalBlockingTimeMs": 200,
"frameDurationMs": 24.508823529411742,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "dom-widget-order-sparse-n1000-w20-i120",
"durationMs": 813.4190000000672,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 411.5700000000002,
"heapDeltaBytes": 12674800,
"heapUsedBytes": 92051316,
"domNodes": 0,
"jsHeapTotalBytes": 266240,
"scriptDurationMs": 135.90200000000002,
"eventListeners": 0,
"totalBlockingTimeMs": 192,
"frameDurationMs": 24.017647058823542,
"p95FrameDurationMs": 16.80000000000109
},
{
"name": "extension-clean-combined-draw",
"durationMs": 9175.264000000026,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 8310.065999999999,
"heapDeltaBytes": 4109004,
"heapUsedBytes": 78419648,
"domNodes": 0,
"jsHeapTotalBytes": -13631488,
"scriptDurationMs": 6753.826,
"eventListeners": 0,
"totalBlockingTimeMs": 618,
"frameDurationMs": 34.2026119402985,
"p95FrameDurationMs": 66.60000000000036
},
{
"name": "extension-clean-combined-draw",
"durationMs": 9546.613999999976,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 8641.966,
"heapDeltaBytes": 10377108,
"heapUsedBytes": 90974960,
"domNodes": 0,
"jsHeapTotalBytes": -14942208,
"scriptDurationMs": 6816.335,
"eventListeners": 0,
"totalBlockingTimeMs": 357,
"frameDurationMs": 31.938461538461535,
"p95FrameDurationMs": 50.100000000000364
},
{
"name": "extension-rgthree-prototype-draw",
"durationMs": 9300.374000000033,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 8435.715999999999,
"heapDeltaBytes": 9816412,
"heapUsedBytes": 90459872,
"domNodes": 0,
"jsHeapTotalBytes": -14417920,
"scriptDurationMs": 6613.072,
"eventListeners": 0,
"totalBlockingTimeMs": 356,
"frameDurationMs": 31.847945205479455,
"p95FrameDurationMs": 50.100000000000364
},
{
"name": "extension-rgthree-prototype-draw",
"durationMs": 9830.876999999986,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 8938.520999999999,
"heapDeltaBytes": 1502052,
"heapUsedBytes": 83210892,
"domNodes": 0,
"jsHeapTotalBytes": -6553600,
"scriptDurationMs": 7105.789,
"eventListeners": 0,
"totalBlockingTimeMs": 535,
"frameDurationMs": 32.13366013071896,
"p95FrameDurationMs": 50.100000000000364
},
{
"name": "large-graph-idle",
"durationMs": 2042.9639999999836,
"styleRecalcs": 6,
"styleRecalcDurationMs": 3.372,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 636.0120000000002,
"heapDeltaBytes": -36631248,
"heapUsedBytes": 82194940,
"domNodes": -228,
"jsHeapTotalBytes": -1409024,
"scriptDurationMs": 39.196,
"eventListeners": -142,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.6655737704918,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-idle",
"durationMs": 2037.6719999999295,
"styleRecalcs": 9,
"styleRecalcDurationMs": 3.088999999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 657.326,
"heapDeltaBytes": -36490260,
"heapUsedBytes": 82262388,
"domNodes": -228,
"jsHeapTotalBytes": -1409024,
"scriptDurationMs": 37.511999999999986,
"eventListeners": -164,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66639344262295,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "large-graph-pan",
"durationMs": 3086.6359999999986,
"styleRecalcs": 67,
"styleRecalcDurationMs": 9.766,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 1745.3010000000002,
"heapDeltaBytes": 1187220,
"heapUsedBytes": 63607420,
"domNodes": -228,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 859.874,
"eventListeners": -142,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66540540540541,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-pan",
"durationMs": 3099.7939999999744,
"styleRecalcs": 66,
"styleRecalcDurationMs": 9.665,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 1772.0889999999997,
"heapDeltaBytes": 26759220,
"heapUsedBytes": 89117684,
"domNodes": -228,
"jsHeapTotalBytes": 225280,
"scriptDurationMs": 862.5189999999999,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666129032258063,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-zoom",
"durationMs": 4020.2899999999886,
"styleRecalcs": 63,
"styleRecalcDurationMs": 11.842000000000002,
"layouts": 60,
"layoutDurationMs": 14.936,
"taskDurationMs": 1840.7880000000002,
"heapDeltaBytes": 9916140,
"heapUsedBytes": 73894892,
"domNodes": -228,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 809.914,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66597510373444,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "large-graph-zoom",
"durationMs": 3854.445999999939,
"styleRecalcs": 63,
"styleRecalcDurationMs": 11.538000000000004,
"layouts": 60,
"layoutDurationMs": 14.651,
"taskDurationMs": 1742.1580000000001,
"heapDeltaBytes": 12584144,
"heapUsedBytes": 76981640,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 781.7579999999999,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66594827586207,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "legacy-node-drag",
"durationMs": 3149.204999999995,
"styleRecalcs": 41,
"styleRecalcDurationMs": 5.972000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 2069.7259999999997,
"heapDeltaBytes": 26443892,
"heapUsedBytes": 90788408,
"domNodes": 0,
"jsHeapTotalBytes": 942080,
"scriptDurationMs": 1033.443,
"eventListeners": 180,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.84438502673797,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "legacy-node-drag",
"durationMs": 3209.634000000051,
"styleRecalcs": 42,
"styleRecalcDurationMs": 6.250000000000002,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 2054.119,
"heapDeltaBytes": 2735752,
"heapUsedBytes": 66532012,
"domNodes": 0,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 1021.9590000000001,
"eventListeners": 180,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.752604166666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "minimap-idle",
"durationMs": 2032.5349999999958,
"styleRecalcs": 5,
"styleRecalcDurationMs": 1.8759999999999992,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 491.896,
"heapDeltaBytes": -38866680,
"heapUsedBytes": 82693720,
"domNodes": -228,
"jsHeapTotalBytes": -360448,
"scriptDurationMs": 33.510999999999996,
"eventListeners": -142,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666115702479335,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "minimap-idle",
"durationMs": 2038.5379999999031,
"styleRecalcs": 7,
"styleRecalcDurationMs": 2.3370000000000024,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 648.013,
"heapDeltaBytes": -37831908,
"heapUsedBytes": 83027284,
"domNodes": -228,
"jsHeapTotalBytes": 950272,
"scriptDurationMs": 38.36299999999999,
"eventListeners": -142,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.80245901639344,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 712.0929999999817,
"styleRecalcs": 46,
"styleRecalcDurationMs": 6.652,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 418.1929999999999,
"heapDeltaBytes": 12589056,
"heapUsedBytes": 93963056,
"domNodes": 0,
"jsHeapTotalBytes": 4194304,
"scriptDurationMs": 144.75199999999998,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.664285714285704,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 695.1090000000022,
"styleRecalcs": 47,
"styleRecalcDurationMs": 7.137,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 427.89,
"heapDeltaBytes": 13156312,
"heapUsedBytes": 93346652,
"domNodes": 0,
"jsHeapTotalBytes": 3932160,
"scriptDurationMs": 147.817,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66341463414634,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-idle",
"durationMs": 2048.528000000033,
"styleRecalcs": 11,
"styleRecalcDurationMs": 4.361999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 524.091,
"heapDeltaBytes": -10060888,
"heapUsedBytes": 70795912,
"domNodes": -244,
"jsHeapTotalBytes": -524288,
"scriptDurationMs": 11.088000000000001,
"eventListeners": -188,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-idle",
"durationMs": 2037.5420000000304,
"styleRecalcs": 10,
"styleRecalcDurationMs": 4.221000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 502.59,
"heapDeltaBytes": -26339360,
"heapUsedBytes": 54124736,
"domNodes": -244,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 10.732,
"eventListeners": -210,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.6655737704918,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1777.2600000000125,
"styleRecalcs": 75,
"styleRecalcDurationMs": 20.471999999999998,
"layouts": 16,
"layoutDurationMs": 6.864999999999999,
"taskDurationMs": 881.764,
"heapDeltaBytes": -18126144,
"heapUsedBytes": 62592524,
"domNodes": -217,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 111.06500000000001,
"eventListeners": -198,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.8247619047619,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1793.382000000065,
"styleRecalcs": 72,
"styleRecalcDurationMs": 20.924000000000007,
"layouts": 16,
"layoutDurationMs": 6.844,
"taskDurationMs": 921.7409999999999,
"heapDeltaBytes": -6962736,
"heapUsedBytes": 74501792,
"domNodes": -244,
"jsHeapTotalBytes": 1310720,
"scriptDurationMs": 116.24,
"eventListeners": -210,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.823584905660372,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-transition-enter",
"durationMs": 1368.5259999999744,
"styleRecalcs": 18,
"styleRecalcDurationMs": 25.978999999999996,
"layouts": 5,
"layoutDurationMs": 11.303,
"taskDurationMs": 906.0109999999999,
"heapDeltaBytes": 21348896,
"heapUsedBytes": 93003592,
"domNodes": 13667,
"jsHeapTotalBytes": 2883584,
"scriptDurationMs": 30.965,
"eventListeners": 2383,
"totalBlockingTimeMs": 125,
"frameDurationMs": 18.949315068493167,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "viewport-pan-sweep",
"durationMs": 10809.717999999975,
"styleRecalcs": 250,
"styleRecalcDurationMs": 34.913,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 6388.044,
"heapDeltaBytes": -34160944,
"heapUsedBytes": 84393004,
"domNodes": -228,
"jsHeapTotalBytes": 94208,
"scriptDurationMs": 2919.324,
"eventListeners": -164,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.691666666666666,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "viewport-pan-sweep",
"durationMs": 10935.36999999992,
"styleRecalcs": 249,
"styleRecalcDurationMs": 34.769999999999996,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 6270.710999999999,
"heapDeltaBytes": -36426468,
"heapUsedBytes": 82888424,
"domNodes": -228,
"jsHeapTotalBytes": -430080,
"scriptDurationMs": 2831.345,
"eventListeners": -164,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.6914373088685,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-idle",
"durationMs": 15369.587000000025,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 15152.151,
"heapDeltaBytes": -29191860,
"heapUsedBytes": 194975940,
"domNodes": -3045,
"jsHeapTotalBytes": 7876608,
"scriptDurationMs": 277.386,
"eventListeners": -14915,
"totalBlockingTimeMs": 0,
"frameDurationMs": 29.493666026871402,
"p95FrameDurationMs": 50
},
{
"name": "vue-large-graph-idle",
"durationMs": 15306.10999999999,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 15073.652,
"heapDeltaBytes": -26896756,
"heapUsedBytes": 180427700,
"domNodes": -3045,
"jsHeapTotalBytes": 12447744,
"scriptDurationMs": 252.64700000000002,
"eventListeners": -14915,
"totalBlockingTimeMs": 0,
"frameDurationMs": 29.30919540229885,
"p95FrameDurationMs": 50.100000000000364
},
{
"name": "vue-large-graph-pan",
"durationMs": 18444.078999999987,
"styleRecalcs": 127,
"styleRecalcDurationMs": 16.807000000000016,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 18358.639,
"heapDeltaBytes": -8165084,
"heapUsedBytes": 164872840,
"domNodes": 0,
"jsHeapTotalBytes": -22282240,
"scriptDurationMs": 853.2829999999999,
"eventListeners": 0,
"totalBlockingTimeMs": 36,
"frameDurationMs": 36.42806324110671,
"p95FrameDurationMs": 66.70000000000073
},
{
"name": "vue-large-graph-pan",
"durationMs": 18637.255000000096,
"styleRecalcs": 127,
"styleRecalcDurationMs": 17.445000000000014,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 18511.299000000003,
"heapDeltaBytes": -18684940,
"heapUsedBytes": 167656436,
"domNodes": -8049,
"jsHeapTotalBytes": -33030144,
"scriptDurationMs": 895.0910000000001,
"eventListeners": -14923,
"totalBlockingTimeMs": 20,
"frameDurationMs": 36.863168316831675,
"p95FrameDurationMs": 66.70000000000073
},
{
"name": "vue-node-resize-workload",
"durationMs": 5658.975999999995,
"styleRecalcs": 20,
"styleRecalcDurationMs": 76.29300000000002,
"layouts": 20,
"layoutDurationMs": 25.552999999999994,
"taskDurationMs": 5586.378000000001,
"heapDeltaBytes": -6477720,
"heapUsedBytes": 173125436,
"domNodes": -8049,
"jsHeapTotalBytes": 12582912,
"scriptDurationMs": 106.87700000000001,
"eventListeners": 0,
"totalBlockingTimeMs": 245,
"frameDurationMs": 32.94360465116279,
"p95FrameDurationMs": 66.69999999999891
},
{
"name": "vue-node-resize-workload",
"durationMs": 5623.8819999999805,
"styleRecalcs": 20,
"styleRecalcDurationMs": 78.50699999999999,
"layouts": 20,
"layoutDurationMs": 26.578000000000003,
"taskDurationMs": 5581.078,
"heapDeltaBytes": 7591780,
"heapUsedBytes": 207891504,
"domNodes": 0,
"jsHeapTotalBytes": 1048576,
"scriptDurationMs": 109.072,
"eventListeners": 0,
"totalBlockingTimeMs": 341,
"frameDurationMs": 34.99875000000001,
"p95FrameDurationMs": 66.70000000000073
},
{
"name": "vue-zoom-out-idle",
"durationMs": 7865.342000000055,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 7792.021999999999,
"heapDeltaBytes": 14278508,
"heapUsedBytes": 179618852,
"domNodes": 0,
"jsHeapTotalBytes": -16515072,
"scriptDurationMs": 151.024,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 31.27370517928287,
"p95FrameDurationMs": 50.10000000000218
},
{
"name": "vue-zoom-out-idle",
"durationMs": 7822.312000000011,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 7709.541,
"heapDeltaBytes": -18605396,
"heapUsedBytes": 193293136,
"domNodes": -3045,
"jsHeapTotalBytes": 7905280,
"scriptDurationMs": 131.02399999999997,
"eventListeners": -14915,
"totalBlockingTimeMs": 0,
"frameDurationMs": 30.59765625,
"p95FrameDurationMs": 50.10000000000218
},
{
"name": "workflow-execution",
"durationMs": 520.2709999999797,
"styleRecalcs": 20,
"styleRecalcDurationMs": 22.224999999999998,
"layouts": 5,
"layoutDurationMs": 2.691,
"taskDurationMs": 216.84799999999998,
"heapDeltaBytes": -44428080,
"heapUsedBytes": 52584244,
"domNodes": -101,
"jsHeapTotalBytes": 4194304,
"scriptDurationMs": 15.464000000000002,
"eventListeners": -106,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.81724137931034,
"p95FrameDurationMs": 33.30000000000018
},
{
"name": "workflow-execution",
"durationMs": 157.87499999999,
"styleRecalcs": 8,
"styleRecalcDurationMs": 17.442,
"layouts": 4,
"layoutDurationMs": 2.399,
"taskDurationMs": 122.05399999999997,
"heapDeltaBytes": -16920996,
"heapUsedBytes": 79951840,
"domNodes": 119,
"jsHeapTotalBytes": 4456448,
"scriptDurationMs": 8.389000000000001,
"eventListeners": 33,
"totalBlockingTimeMs": 0,
"frameDurationMs": 18.75,
"p95FrameDurationMs": 33.399999999999636
},
{
"name": "agent-composer-empty-conversation-typing",
"durationMs": 1104.3160000000398,
"styleRecalcs": 78,
"styleRecalcDurationMs": 115.088,
"layouts": 76,
"layoutDurationMs": 26.934,
"taskDurationMs": 1070.838,
"heapDeltaBytes": 20365312,
"heapUsedBytes": 90620200,
"domNodes": 76,
"jsHeapTotalBytes": 262144,
"scriptDurationMs": 427.56,
"eventListeners": 876,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.665151515151525,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "agent-composer-empty-conversation-typing",
"durationMs": 1253.7969999999632,
"styleRecalcs": 78,
"styleRecalcDurationMs": 130.862,
"layouts": 76,
"layoutDurationMs": 30.625,
"taskDurationMs": 1227.53,
"heapDeltaBytes": 20972760,
"heapUsedBytes": 91268724,
"domNodes": 76,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 523.289,
"eventListeners": 876,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.85571428571428,
"p95FrameDurationMs": 33.30000000000018
},
{
"name": "agent-composer-long-conversation-typing",
"durationMs": 1482.8109999999697,
"styleRecalcs": 78,
"styleRecalcDurationMs": 270.47700000000003,
"layouts": 76,
"layoutDurationMs": 26.741999999999997,
"taskDurationMs": 1467.754,
"heapDeltaBytes": 15052372,
"heapUsedBytes": 130523716,
"domNodes": 76,
"jsHeapTotalBytes": 524288,
"scriptDurationMs": 472.683,
"eventListeners": 876,
"totalBlockingTimeMs": 0,
"frameDurationMs": 18.72345679012344,
"p95FrameDurationMs": 33.30000000000109
},
{
"name": "agent-composer-long-conversation-typing",
"durationMs": 1476.8790000000536,
"styleRecalcs": 78,
"styleRecalcDurationMs": 269.83299999999997,
"layouts": 76,
"layoutDurationMs": 27.588,
"taskDurationMs": 1455.0330000000001,
"heapDeltaBytes": -18315012,
"heapUsedBytes": 110920240,
"domNodes": 76,
"jsHeapTotalBytes": 1310720,
"scriptDurationMs": 466.43500000000006,
"eventListeners": 876,
"totalBlockingTimeMs": 0,
"frameDurationMs": 18.75,
"p95FrameDurationMs": 33.399999999999636
}
]
}🔬 E2E CoverageNote The shard matrix did not pass, so these totals cannot be confirmed comparable with a whole merge.
Top 10 files by uncovered lines
🌐 Website E2ENote Tests are running… View workflow run |
billing-web resolves the plan it checks out from the quote, but the quote does not carry the monthly credit grant the confirm shows. The tiers' prices and grants move here so the app and billing-web read one table.
…ace-adopt-account-ui-checkout
Codecov Report❌ Patch coverage is
@@ Coverage Diff @@
## main #19100 +/- ##
==========================================
+ Coverage 84.17% 85.07% +0.90%
==========================================
Files 3185 2335 -850
Lines 155675 133994 -21681
Branches 42314 34268 -8046
==========================================
- Hits 131037 114001 -17036
+ Misses 23006 19644 -3362
+ Partials 1632 349 -1283
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 860 files with indirect coverage changes 🚀 New features to boost your workflow:
|
…atalog its own entry Both confirm templates exceeded the complexity gate. The new-subscription confirm now composes a summary and a pay-actions component, and picks one pay action in script; the plan-change confirm moves its reactivation banner and plan block into components. Rendered markup is unchanged. The tier catalog moves to @comfyorg/account-ui/billing/catalog, a TS-only entry, so importing it does not pull Vue components into non-Vue consumers such as the Playwright runner.
|
🔗 Commit SHA: d312fb0 | Docs | View more details | Give us feedback! |
…tor, card form and success (Comfy-Org#19099) - Linear: FE-3046 **Merge order:** Comfy-Org#19096 (ADR 0034 amendment) merges first. Until it does, ADR 0034 rule 4 still forbids account-ui from using the design system, which B does. ## Why billing-web is the cloud app's embedded checkout moved to a new tab, with no UX change (ADR BILLING-WEB-0038, Comfy-Org#19096). Today billing-web renders a checkout of its own (`EmbeddedCheckout`, `CheckoutPayment`, `CheckoutSubmit`) that has drifted from the app's: different price layout, no saved-card selection, different copy. For both to render the same screens, the app's confirm, price breakdown, saved-card selector, card form, terms notice and success step have to live where both can import them. This PR adds them to `@comfyorg/account-ui`. Nothing renders them yet, so no visual change. ## How - New entry `@comfyorg/account-ui/billing/checkout`, ported line for line from the app components. Same markup, same classes, same conditions: - `CheckoutSubscribeConfirm` ← `SubscriptionAddPaymentPreviewWorkspace.vue` (plan header, credits, total due, discounts, promo code, saved methods, card form, 3DS prompt, parked-checkout recovery, terms). - `CheckoutTransitionConfirm` ← `SubscriptionTransitionPreviewWorkspace.vue` (immediate vs scheduled change, reactivation banner and threshold checkbox). - `CheckoutSavedMethods` + `CheckoutSavedMethodSelect` ← the saved-method row / `SingleSelect` picker (Reka select with the app's select classes). - `CheckoutPaymentForm` ← `UnifiedStripePaymentSelector.vue` minus the app bindings (key, theme and telemetry become props and a `phase` event). - `CheckoutSuccess` ← `SubscriptionSuccessWorkspace.vue`, with `details`/`actions` slots for the app's team invite. - `CheckoutTermsNote`, `CheckoutPromotionCode`, `CheckoutPaymentNotices`, `CheckoutVerificationPrompt`: blocks both confirms repeated. `CheckoutSubscribeSummary`/`CheckoutSubscribeActions` and `CheckoutReactivationBanner`/`CheckoutTransitionSummary` split the two confirm templates under the fallow complexity gate; the rendered markup is the same. - `checkoutQuote.ts`: the app's `subscriptionQuoteFormatting.ts` + `planDuration.ts`. - `@comfyorg/account-ui/billing/catalog` (TS-only entry): the tiers' prices and monthly credit grants (the numbers in the app's `TIER_PRICING`). The app's confirm reads the grant from this table (`TIER_PRICING`), not from the quote's `new_plan.credits_cents`, so billing-web reads the same table to show the same number; C points the app at it. A separate entry so non-Vue consumers (the Playwright runner imports `tierPricing`) never load the components. - The package has no i18n runtime. Hosts pass a typed `CheckoutCopy`; interpolated strings are functions, and sentences that wrap an element (terms links, reactivation amount) keep `{token}`s that the component splits. - Hosts pass a resolved `CheckoutPlan` (name, monthly/yearly price, credits, `pricedByQuote`) instead of the package reading the tier catalog. - `selectVariants` moves to `@comfyorg/design-system/select.variants` (same move as `buttonVariants` in Comfy-Org#19098), so the picker renders the app's select classes. - Packaging: `design-system` variants and `tailwind-utils`'s `cn` are bundled into the published build (dev dependencies). `tailwind-utils` is not on npm and `design-system` ships TS source, so neither can be a runtime dependency of a published package. `reka-ui` is a peer. The rendered classes need the design-system theme and primeicons at runtime, so `@comfyorg/design-system` and `primeicons` are peers too, and the package description says to load their CSS and add the package's dist to the consumer's Tailwind sources. The smoke test imports the new entry in the typed consumer and treats it as bundler-only, like `billing/stripe`. ### Reactivation renewal date (live testcloud recording) The reactivation notice and the summary could name different renewal days for the same quote. On `m2-qa-0925-3ds` the notice said "renew … on Oct 27" and the summary "Renews … on Oct 25, 2026". - **Summary:** reads `renewal_at ?? new_plan.period_end` (`resolveRenewalDate`). - **Notice:** read `new_plan.period_end` only. When that was absent, it computed `effective_at` + one period on the client (Sep 27 + 1 month = Oct 27). - **Not a server inconsistency:** the server sent one renewal date, `renewal_at`, which the contract defines as "the next recurring charge and target-plan period end". - **Fix:** the notice now reads the same server date as the summary (`resolveRenewalDate`: `renewal_at`, else the plan's server `period_end`). The client-side computation is gone. With no server date, the notice drops its renewal clause through new `reactivation.withoutRenewalDate` copy, the way the summary drops its date. - **Contract:** `renewal_at` is optional in `PreviewSubscribeResponse` ("Optional in the schema for older clients"; "current servers always return this"). The server should always send it; the client no longer computes one when it doesn't. - **Tests:** - A new test fails on the old code (Oct 27 vs Oct 25). - The tests that pinned the client computation (account-ui and the app's `SubscriptionTransitionPreviewWorkspaceReactivation.test.ts`, in C) are replaced by a no-renewal-date test. - C adds the app's `withoutRenewalDate` strings. ## Review Focus - The ports are meant to be verbatim. C (the next PR) swaps the app onto these components and the app's existing component tests (about 2,100 lines across the two confirms and the success step) pass with only stub names changed. That is the parity check. - `CheckoutPlan.pricedByQuote` reproduces the app's price rules exactly, including the odd ones: a tier plan shows the quote's price once one arrives and `$0` on the success step without one; a team credit stop always shows its own price. ## Stack | PR | branch | base | title | |---|---|---|---| | Comfy-Org#19097 | `jaewon/billing-web-remove-plan-grid` | `main` | `FE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selection` | | A Comfy-Org#19098 | `jaewon/design-system-button-variants` | Comfy-Org#19097 | `FE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-system` | | **B (this PR)** | **`jaewon/account-ui-checkout-surfaces`** | **A** | **`FE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and success`** | | C Comfy-Org#19100 | `jaewon/workspace-adopt-account-ui-checkout` | B | `FE-3046 refactor(workspace): render the subscription checkout steps from account-ui` | | D Comfy-Org#19101 | `jaewon/billing-web-shared-checkout` | C | `FE-3046 feat(billing-web): render the shared embedded checkout` | | E Comfy-Org#19104 | `jaewon/billing-web-success-invite` | D | `FE-3046 feat(billing-web): invite your team from the checkout success step` | | F Comfy-Org#19105 | `jaewon/checkout-3ds-failure-copy` | E | `FE-3047 fix(account-ui): clear decline toasts once a retry succeeds` | | G Comfy-Org#19106 | `jaewon/billing-web-return-close-tab` | F | `FE-3048 fix(billing-web): return to the host by closing the checkout tab` | | H Comfy-Org#19115 | `jaewon/checkout-cta-reachable` | G | `FE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm step` | ```mermaid graph LR P0[Comfy-Org#19097: remove plan grid] --> A[A: design-system buttonVariants] A --> B[B: account-ui checkout surfaces] B --> C[C: workspace adopts account-ui] C --> D[D: billing-web shared checkout] D --> E[E: billing-web success invite] E --> F[F: stale decline toasts] F --> G[G: close the billing tab] G --> H[H: reachable checkout CTA] style B fill:#f9d71c,stroke:Comfy-Org#333,color:#000 ``` ## AS IS / TO BE No rendered change: nothing renders these components in this PR. The parity screenshots are on C (Comfy-Org#19100, app before/after, pixel-identical) and D (Comfy-Org#19101, billing-web before/after next to the app). --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
christian-byrne
left a comment
There was a problem hiding this comment.
- The account-ui checkout adoption keeps product-specific orchestration in the host and delegates only the shared surfaces.
- Workspace-bound reads, pending records, and completion remain keyed to the active tab's workspace; this does not introduce cross-tab workspace coupling.
- Exact-head CI is settled after the same-head Playwright rerun: 97 checks succeeded, 16 were skipped, and none are red or pending.
Full context for agent readers
Reviewed at exact head d312fb06515d1b6289e8dfdb3acf0060773434a2. The wrappers pass typed state into the package and faithfully forward mutations while retaining host telemetry, catalog resolution, invitations, persistence, and workspace guards. There are no unresolved review threads.
|
|
…-Org#19101) - Linear: FE-3046 ## Why billing-web is the cloud app's embedded checkout moved to a new tab, with no UX change (ADR BILLING-WEB-0038, Comfy-Org#19096). Its checkout was a separate implementation (`EmbeddedCheckout`, `CheckoutPayment`, `CheckoutSubmit`) with its own layout and copy, no saved-card selection and no promo code. With the app now rendering `@comfyorg/account-ui/billing/checkout` (Comfy-Org#19100), billing-web can render the same steps. ## How - `CheckoutView.vue` renders the shared steps inside `CheckoutFrame.vue`, which reproduces the app's checkout dialog box (the dialog content class from `useSubscriptionDialog` and the embedded-step classes from `SubscriptionRequiredDialogContentUnified`): - `new_subscription` quote → `CheckoutSubscribeConfirm` with the card form, the saved methods from `usePaymentMethods` (default preselected; Change / Add new payment method swap in the card form) and the promo code. - any other transition → `CheckoutTransitionConfirm`, single column, no card form: the server charges the method on file (the Comfy-Org#18684 rule, now through the same component as the app). A reactivation the quote or the server demands shows the app's banner and threshold checkbox. - success → `CheckoutSuccess` (plan card, credits per month); Close returns to the product with the outcome. - Through the payment it behaves like the app: the confirm stays with the pay button busy and a processing (or "verify your payment") toast; a verification that fails in the tab shows the confirm's inline notice; a decline, timeout or refused subscribe shows the app's error toast with its detail copy and leaves the confirm, and a card already typed, in place. `CheckoutToast.vue` is that toast. - Subscribe carries `saved_payment_method_id` for a saved method and `promotion_code` for an applied promo, next to the existing token, quote identity, proration and return URL. - Plan: tier name and monthly credits from `@comfyorg/account-ui/billing/catalog` (Comfy-Org#19099). A team stop's price and credits come from the `/billing/plans` stop the link names, through the same catalog functions as the app's slider and confirm. - Copy: billing-web's `checkout.*` keys are replaced with the app's English strings, key for key. - Page environment: the frame applies what the app's page applies around the dialog — its dark palette's `--interface-stroke`, `color-scheme: dark`, and browser defaults for inputs, the select trigger and links (the app has no Tailwind preflight). `styles.css` sources all of account-ui's billing components (the Stripe form's layout classes were missing); `primeicons` and `reka-ui` are added. - Tests: `CheckoutView.test.ts` rewritten against the shared components (saved method, Change, promo, reactivation, decline/3DS outcomes, Comfy-Org#18684 cases kept); `e2e/checkout.spec.ts` updated plus a saved-method e2e. billing-web e2e 29/29 locally. ### billing-web-only UI deleted - `EmbeddedCheckout`'s split card layout (5/12 summary sidebar, its own card, muted `h1`, lucide back arrow and close X). - Plan title `{tier} · {duration}` ("Pro · Monthly"), hero `$28.00` with "USD per month"/"USD per year", "{amount} billed yearly", "Starting today". - "Credits refill every month" showing `credits_cents` as dollars ("$211.00" for 21,100 credits). - The terms line "By subscribing, you agree to recurring charges until cancellation." (no links). - `CheckoutSubmit`'s pay button and its reactivation checkbox on the card form ("Your subscription was cancelled. I confirm the {amount} charge to reactivate it."); reactivation now uses the app's banner on the plan-change confirm. - Its own Stripe copy ("Choose how you would like to pay.", "The payment form isn't available right now…", its Alipay note, "Something went wrong. Please try again."). - The inline failure paragraph above the pay button. - The `CheckoutSteps` panel that replaced the checkout while paying and after a failure ("Review payment", "Payment declined", "Payment could not be processed", Try again / Use a different payment method / Contact support). - The success panel (tinted check circle, "Your plan was updated. A receipt was sent to your email.", plan line, "Return to {product}" link button). ### billing-web-only UI kept - The way back to the host: Close (the dialog's X and the success step's Close) leaves for the product's return URL instead of closing a dialog. - "Loading…" while the quote loads, and the quote-refused panel with Back (the app never opens the confirm without a quote). - `CheckoutToast`, standing in for the app's toast host (outside the checkout panel). ### Not closed here (see Review Focus) - Team plan success: the app's "Invite your team" step lands in E (Comfy-Org#19104). - Stripe Payment/Address Element options differ in the live recording (Google Pay and a full address on billing-web vs card/Alipay/US bank and name-only in the app). Both hosts now render the same `StripePaymentForm` with the same options; what remains comes from the server's `payment_method_configuration_id` and Stripe's per-domain wallet registration, which need a live backend check. ### Shared with the app, so the hosts can't drift (review fixes) - **Decline copy:** `declineDetailKey(reason)` in account-core is one exhaustive switch over the contract's `BillingDeclineReason`. The app's SDK rail (`topupOperationView.declineDetail`) and billing-web both call it. Before this, billing-web had its own list that omitted `generic`. A reason-less decline (account-core defaults it to `generic`) therefore read "We couldn't update your subscription." on billing-web and "Your bank declined this payment." in the app. The list also carried 15 strings outside the enum. - **Processing vs verify toast:** superseded below. The app's rule is `awaitsHostedAction`, now shared, not `awaitsVerification`. - **Team hero price:** `mapApiTeamCreditStops` and `getStopDiscountedMonthlyUsd` move from the app into `@comfyorg/account-ui/billing/catalog`. The app's pricing table, credit slider and subscription dialog import them from there, and billing-web's `teamCheckoutPlan` prices the stop with them instead of `price_cents / months`. - Tests: table tests for `declineDetailKey` (all 8 reasons) and `awaitsVerification`, the moved stop tests, billing-web decline rows for `generic` / `incorrect_cvc` / `processing_error`, and team monthly/annual stop prices. The e2e that pinned the old reason-less copy now expects the app's decline copy. - Harness: new step P6a2, the server declines with no `decline_reason`. Rerun on D: 0% copy/element difference on every step except P7T, whose team invite is E. Rerun on G (top of stack): 0% on all 15 steps. ### Toasts and success frame (live testcloud recording) - **Why a replica:** billing-web's toast is a measured replica of the app's PrimeVue Aura toast, because AGENTS.md forbids new PrimeVue usage. The parity harness compares every toast (size, colors, fonts, icon, close button, each part's position) and fails on drift. - **Assistive tech:** every toast is `role="alert"`, `aria-live="assertive"`, `aria-atomic="true"`, as PrimeVue renders the app's. The harness compares these too. - **Anchor:** toasts sit top-right. The app anchors its message toasts to the graph canvas panel, which billing-web does not have. - **End date:** the reactivation notice's "set to end on" date now comes from the billing status's `cancel_at`, the field the app reads, instead of the quote's `current_plan.period_end`. Harness step P2e gives the two server values different dates; both hosts show `cancel_at` (Oct 25 vs the quote's Oct 27). - **Toast:** `CheckoutToast` was a look-alike: neutral, no close button, one at a time. It now renders the app's dark Aura PrimeVue toast. - Styling: the severity tint, 36% border and shadow, `blur(10px)`, and a 28px close button. - Layout: the two hosts the app uses. The operation toast is a spinner or prompt beside one line; the message toast is a severity icon, summary and detail. - The numbers come from the app's computed styles, captured by the harness. It is not PrimeVue itself, because AGENTS.md rules out new PrimeVue use in billing-web. - **Lifetimes match the app:** - The progress toast stays while the payment is pending. A closed one stays closed until the operation's state changes. - Errors stay until closed. - "Subscription updated successfully" shows for 5 s after a subscribe the server charged for, like the app's SDK rail (`requiredPayment`). A plan the server activated on the spot gets none. - **Prompt vs spinner:** the app shows the "Verify your payment" prompt only when a hosted action page is waiting. An in-page 3DS challenge keeps the spinner. `awaitsVerification` (adopted in review) also counted the challenge, and the harness showed it disagreed with the app. The app's rule is now `awaitsHostedAction` in account-core, used by the app's `billingSdkStore` and by billing-web. - **Success frame:** the app pins the success frame only after a new subscription. After a plan change it uses the dialog's content-sized box. `CheckoutFrame` gets that `fit` step, so the blank band above "Send invites" is gone. - **Harness:** it now captures the toast region and the frame box on both sides, not just the panel. Toasts are paired by text and compared on size, colors, fonts, icon, close button and each part's position. New step P7C covers success after a plan change that took a payment. At the stack top, all 19 steps show no copy or element difference, the same toasts with the same measurements, and equal frame boxes. **Toasts, app (left) vs billing-web (right): progress, decline, success** <img width="824" alt="D-toasts" src="https://github.com/user-attachments/assets/06d04e8e-6aba-46a8-9287-f43d3019844a" /> **billing-web progress toast, AS IS | TO BE** <img width="1092" alt="D-toast-web-asis-tobe" src="https://github.com/user-attachments/assets/d860df11-e1eb-49e2-ba17-e30efec5723c" /> **P7C success after a plan change: billing-web AS IS | TO BE, then app | billing-web** <img width="1448" alt="D-frame-web" src="https://github.com/user-attachments/assets/36c3a98f-591f-48ca-8a58-03a3273ae90f" /> <img width="1448" alt="D-frame-appweb" src="https://github.com/user-attachments/assets/ecd2c4ee-fbbd-48ba-b55c-b0645b0b5662" /> ### A checkout the server still holds (M2 QA N1) - On mount the view adopts the operation the billing status names (`lifecycle.recover()`), the way the app resumes `pending_billing_op_id`. Before this, opening checkout while an earlier subscription was pending showed a fresh card form or an enabled confirm. Pressing it sent nothing and showed "Something went wrong." - The confirm now gets the app's `action-url`, `authentication-error` and `parked-checkout-recovery`, and `paying` follows the app's `isPolling` rule. An operation parked on `awaiting_payment_method` offers "Complete your payment", and a settling invoice holds the pay action. - A subscribe the core refuses with `OPERATION_ALREADY_PENDING` shows the app's sentence ("A payment you started earlier is still going through…") instead of the generic failure. - Tests: view tests for a parked op and a settling-invoice op, both red without the fix. Harness steps P8a (parked) and P8b (settling invoice) match the app with 0% copy/element difference. - Same on both hosts: the core refuses a second subscribe while the status names a pending one, so on the SDK rail "Complete your payment" answers with that sentence in the app and in billing-web alike. **P8a: parked checkout, Cloud app (left) | billing-web (right)** <img width="1448" alt="D-parked" src="https://github.com/user-attachments/assets/7316e0da-e4df-4fe9-bf7b-5e8d34754efc" /> **P8b: settling invoice, Cloud app (left) | billing-web (right)** <img width="1448" alt="D-held" src="https://github.com/user-attachments/assets/1940763e-3f0a-4b91-9c71-c0d175b0c69a" /> **P6a2: reason-less decline, Cloud app (left) | billing-web (right)** <img width="1448" alt="D-no-reason" src="https://github.com/user-attachments/assets/75d0ed13-bb14-453d-8b73-eda7b23ff754" /> ## Review Focus - The two gaps above. ## Stack | PR | branch | base | title | |---|---|---|---| | Comfy-Org#19097 | `jaewon/billing-web-remove-plan-grid` | `main` | `FE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selection` | | A Comfy-Org#19098 | `jaewon/design-system-button-variants` | Comfy-Org#19097 | `FE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-system` | | B Comfy-Org#19099 | `jaewon/account-ui-checkout-surfaces` | A | `FE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and success` | | C Comfy-Org#19100 | `jaewon/workspace-adopt-account-ui-checkout` | B | `FE-3046 refactor(workspace): render the subscription checkout steps from account-ui` | | **D (this PR)** | **`jaewon/billing-web-shared-checkout`** | **C** | **`FE-3046 feat(billing-web): render the shared embedded checkout`** | | E Comfy-Org#19104 | `jaewon/billing-web-success-invite` | D | `FE-3046 feat(billing-web): invite your team from the checkout success step` | | F Comfy-Org#19105 | `jaewon/checkout-3ds-failure-copy` | E | `FE-3047 fix(account-ui): clear decline toasts once a retry succeeds` | | G Comfy-Org#19106 | `jaewon/billing-web-return-close-tab` | F | `FE-3048 fix(billing-web): return to the host by closing the checkout tab` | | H Comfy-Org#19115 | `jaewon/checkout-cta-reachable` | G | `FE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm step` | ```mermaid graph LR P0[Comfy-Org#19097: remove plan grid] --> A[A: design-system buttonVariants] A --> B[B: account-ui checkout surfaces] B --> C[C: workspace adopts account-ui] C --> D[D: billing-web shared checkout] D --> E[E: billing-web success invite] E --> F[F: stale decline toasts] F --> G[G: close the billing tab] G --> H[H: reachable checkout CTA] style D fill:#f9d71c,stroke:Comfy-Org#333,color:#000 ``` ## AS IS / TO BE ### Live (testcloud) AS IS / TO BE Real app and real billing-web against testcloud, not the harness. Same account and plan change on both sides: Team Monthly team_700 → team_1400 ($1,295/mo) on a cancelled team workspace, which reactivates it (the "Confirm your upgrade" path). Both subscriptions were cancelled again afterwards. - **AS IS:** `main` ec7764f. Embedded = local app on testcloud with `ff:hosted_billing_destination="stripe"`. billing-web = testcloud (`billing_web`) → testbilling. Team Monthly team_700, new subscription. - **TO BE:** stack top f02bdd6 (H Comfy-Org#19115, includes this PR) for both surfaces. Local app (`DEV_SERVER_COMFYUI_URL=https://testcloud.comfy.org/`, testcloud `pk_test`) and local billing-web on :5174 (`VITE_BILLING_ENV=test`). Embedded = `ff:hosted_billing_destination="stripe"` on `m2-qa-0925-3ds` (saved card needs 3DS). billing-web = `"billing_web"` on `m2-qa-0927-full`, handed off from the app's Change plan; the server's `billing_web_url` was cleared in the page so the app opens the local billing-web. **TO BE video, embedded (left) | billing-web (right).** Plan picked in the app → confirm → pay → (3DS on the embedded side's saved card) → "You're all set" with Invite your team → Close. On billing-web, Close closes the tab and the app shows the new credit balance. https://github.com/user-attachments/assets/a4a527e4-9a89-4808-8e27-90b143cc9bce Full-size recordings: embedded https://github.com/user-attachments/assets/fd8f0ea7-6480-4b54-bb28-afc7fffbfdd6 · billing-web https://github.com/user-attachments/assets/1da3540f-fcf6-4691-a075-997b07c364f1 **AS IS video, embedded (left) | billing-web (right)** (new subscription, recorded separately so the timelines do not line up). https://github.com/user-attachments/assets/b653c5ba-2e82-4bfa-bed5-f151109e580e **TO BE per step, embedded (left) | billing-web (right)** 1. Plan chosen in the host app (same dialog; billing-web has no plan picker) <img width="1400" alt="1-plan-picker-in-host" src="https://github.com/user-attachments/assets/2b59d096-c13f-4e8f-a96b-9e86ebee4f58" /> 2. Confirm your upgrade: same notice, summary, discount, total, promo and CTA <img width="1400" alt="2-confirm-top" src="https://github.com/user-attachments/assets/20bbd27d-361c-48d4-8857-ddd6bc71ced3" /> 3. Confirm scrolled inside its frame: terms line reachable on both <img width="1400" alt="3-confirm-scrolled-terms" src="https://github.com/user-attachments/assets/2f3d6e40-6819-4f52-b2f8-b76d829fca1c" /> 4. Paying: busy CTA and "Processing payment — setting up your workspace…" toast <img width="1400" alt="4-processing" src="https://github.com/user-attachments/assets/f5372838-c85d-4113-aece-019ce940cf40" /> 5. Embedded only: Stripe 3DS2 test page for the saved card (billing-web's workspace card did not ask for 3DS) <img width="700" alt="5-embedded-3ds-challenge" src="https://github.com/user-attachments/assets/dbd3abe9-3d90-4da5-b398-945e6f9cefb2" /> 6. You're all set: plan card, 295,400 / month, Invite your team, Send invites, Close <img width="1400" alt="6-success" src="https://github.com/user-attachments/assets/42b820df-b6b8-4748-a768-5969d7474fb4" /> 7. After Close: embedded dialog closes; billing-web tab closes and the app shows 294,054 credits with no Resubscribe <img width="1400" alt="7-after-close" src="https://github.com/user-attachments/assets/4989f353-1d96-4255-b7a4-cd78a092f86e" /> **AS IS per step, embedded (left) | billing-web (right)** <img width="1400" alt="AS IS P1 confirm" src="https://github.com/user-attachments/assets/a027af94-3f09-4ed1-8d13-5a561cb7a788" /> <img width="1400" alt="AS IS P6 decline 0002" src="https://github.com/user-attachments/assets/ec0e267a-8255-4460-98a7-5ef466dcbe8b" /> <img width="1400" alt="AS IS P7 success" src="https://github.com/user-attachments/assets/381b0a9b-93fd-42ef-9200-adc39d42b179" /> <img width="1400" alt="AS IS P7 return to app" src="https://github.com/user-attachments/assets/2754cf9e-e300-4a73-8889-76ed5dbab082" /> **Differences still visible live (TO BE)** - Processing toast: the app's is the blue info toast with a close button; billing-web's `CheckoutToast` is a neutral dark toast without one. - Success: the app's dialog fits its content; billing-web's frame keeps the confirm step's fixed height, so a blank band sits between the email field and Send invites. The app also shows a "Subscription updated successfully" toast; billing-web does not. - Embedded only (pre-existing, N4): a "Couldn't open the payment page — please allow popups" warning appears during the in-page 3DS challenge. - Embedded confirm on `m2-qa-0925-3ds`: the notice says it renews on Oct 27, 2026 while the summary says "Renews at $1,295.00 on Oct 25, 2026". Not compared on billing-web, whose workspace has both dates on Oct 27. **Not recorded live yet** - ~~New subscription (card entry, decline 0002, 3DS 3184 complete and fail).~~ Recorded on billing-web in the live rerun below (workspace `m2-qa-0927-new`). An embedded new-subscription run on the same build was not possible: the account has one free workspace, so the embedded side is covered by the AS IS recording above and the upgrade side-by-side below. - Failed 3DS on the upgrade path: not run, because a failed reactivating upgrade leaves the operation pending and the workspace cannot be cancelled (N6). #### Live rerun on stack top 9dab83d (2026-09-27) **Upgrade, AS IS embedded (left) | TO BE billing-web (right):** Team 147.7K → 295.4K in the app dialog and Team 295.4K → 527.5K on billing-web, both with 3DS complete; same confirm, 3DS and success screens. https://github.com/user-attachments/assets/d4d49d40-27bc-4bbe-8886-99f2df7acd8f **TO BE billing-web, new Team Monthly subscription:** decline (0002) → 3DS fail (3184) → 3DS complete → "You're all set" with Invite your team → Close closes the tab and the app shows the plan. https://github.com/user-attachments/assets/a4c58e5d-429a-4332-bfa4-e10d8621f082 ### Mocked harness Checkout parity harness (`temp/scripts/checkout-parity`, same fixtures on both surfaces, fake `js.stripe.com` masking the Stripe elements; mocked Cloud, not a live backend). Each image: **billing-web AS IS** (`main` ec7764f) | **billing-web TO BE** (this PR, d24d242) | **cloud app** (same build). Copy/element diff app vs billing-web TO BE: none on all 11 steps. Panel pixel diff (app vs TO BE) below; the non-zero ones are the busy button's spinner frame. The harness's style notes that remain pair two same-named elements (the two Stripe masks, the two Close buttons) and are identical in the structure dumps. **P1-confirm-new-personal** — pixel diff 0% <img width="1400" alt="P1-confirm-new-personal" src="https://github.com/user-attachments/assets/062a2b68-9299-4920-b321-0a72b3102918" /> **P1T-confirm-new-team** — pixel diff 0% <img width="1400" alt="P1T-confirm-new-team" src="https://github.com/user-attachments/assets/786f38b6-5f02-4a43-ad63-6a44cb7465a8" /> **P2a-confirm-upgrade-immediate** — pixel diff 0% <img width="1400" alt="P2a-confirm-upgrade-immediate" src="https://github.com/user-attachments/assets/f4fc2395-9cc2-4668-b338-52051f84189f" /> **P2b-confirm-downgrade-zero-due** — pixel diff 0% <img width="1400" alt="P2b-confirm-downgrade-zero-due" src="https://github.com/user-attachments/assets/a4cef7bc-4f04-48e2-b740-85a50ad2b1de" /> **P3-saved-card-selector** — pixel diff 0% <img width="1400" alt="P3-saved-card-selector" src="https://github.com/user-attachments/assets/f4ef89a3-d681-4db3-9209-2f9e7350dae0" /> **P3b-no-saved-cards** — pixel diff 0.000% <img width="1400" alt="P3b-no-saved-cards" src="https://github.com/user-attachments/assets/ac51ce04-ea6b-4a06-a706-5092bbd77b5d" /> **P4-card-entry** — pixel diff 0.000% <img width="1400" alt="P4-card-entry" src="https://github.com/user-attachments/assets/705d93bf-e33c-4376-b357-d4be86f332d3" /> **P5-3ds-in-progress** — pixel diff 0.003% <img width="1400" alt="P5-3ds-in-progress" src="https://github.com/user-attachments/assets/39f72aaa-28b1-4266-bdd5-b14fe4b6a99b" /> **P6a-declined** — pixel diff 0% <img width="1400" alt="P6a-declined" src="https://github.com/user-attachments/assets/66ef6af7-c82b-4f76-b5ca-37896d734420" /> **P6b-3ds-failed** — pixel diff 0.003% <img width="1400" alt="P6b-3ds-failed" src="https://github.com/user-attachments/assets/e18807f0-b0d8-4584-a9fc-86ae86ec26f9" /> **P7-success** — pixel diff 0% <img width="1400" alt="P7-success" src="https://github.com/user-attachments/assets/ecd05652-cee7-4464-bae9-61da565904c8" /> --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…tor, card form and success (#19099) - Linear: FE-3046 **Merge order:** #19096 (ADR 0034 amendment) merges first. Until it does, ADR 0034 rule 4 still forbids account-ui from using the design system, which B does. ## Why billing-web is the cloud app's embedded checkout moved to a new tab, with no UX change (ADR BILLING-WEB-0038, #19096). Today billing-web renders a checkout of its own (`EmbeddedCheckout`, `CheckoutPayment`, `CheckoutSubmit`) that has drifted from the app's: different price layout, no saved-card selection, different copy. For both to render the same screens, the app's confirm, price breakdown, saved-card selector, card form, terms notice and success step have to live where both can import them. This PR adds them to `@comfyorg/account-ui`. Nothing renders them yet, so no visual change. ## How - New entry `@comfyorg/account-ui/billing/checkout`, ported line for line from the app components. Same markup, same classes, same conditions: - `CheckoutSubscribeConfirm` ← `SubscriptionAddPaymentPreviewWorkspace.vue` (plan header, credits, total due, discounts, promo code, saved methods, card form, 3DS prompt, parked-checkout recovery, terms). - `CheckoutTransitionConfirm` ← `SubscriptionTransitionPreviewWorkspace.vue` (immediate vs scheduled change, reactivation banner and threshold checkbox). - `CheckoutSavedMethods` + `CheckoutSavedMethodSelect` ← the saved-method row / `SingleSelect` picker (Reka select with the app's select classes). - `CheckoutPaymentForm` ← `UnifiedStripePaymentSelector.vue` minus the app bindings (key, theme and telemetry become props and a `phase` event). - `CheckoutSuccess` ← `SubscriptionSuccessWorkspace.vue`, with `details`/`actions` slots for the app's team invite. - `CheckoutTermsNote`, `CheckoutPromotionCode`, `CheckoutPaymentNotices`, `CheckoutVerificationPrompt`: blocks both confirms repeated. `CheckoutSubscribeSummary`/`CheckoutSubscribeActions` and `CheckoutReactivationBanner`/`CheckoutTransitionSummary` split the two confirm templates under the fallow complexity gate; the rendered markup is the same. - `checkoutQuote.ts`: the app's `subscriptionQuoteFormatting.ts` + `planDuration.ts`. - `@comfyorg/account-ui/billing/catalog` (TS-only entry): the tiers' prices and monthly credit grants (the numbers in the app's `TIER_PRICING`). The app's confirm reads the grant from this table (`TIER_PRICING`), not from the quote's `new_plan.credits_cents`, so billing-web reads the same table to show the same number; C points the app at it. A separate entry so non-Vue consumers (the Playwright runner imports `tierPricing`) never load the components. - The package has no i18n runtime. Hosts pass a typed `CheckoutCopy`; interpolated strings are functions, and sentences that wrap an element (terms links, reactivation amount) keep `{token}`s that the component splits. - Hosts pass a resolved `CheckoutPlan` (name, monthly/yearly price, credits, `pricedByQuote`) instead of the package reading the tier catalog. - `selectVariants` moves to `@comfyorg/design-system/select.variants` (same move as `buttonVariants` in #19098), so the picker renders the app's select classes. - Packaging: `design-system` variants and `tailwind-utils`'s `cn` are bundled into the published build (dev dependencies). `tailwind-utils` is not on npm and `design-system` ships TS source, so neither can be a runtime dependency of a published package. `reka-ui` is a peer. The rendered classes need the design-system theme and primeicons at runtime, so `@comfyorg/design-system` and `primeicons` are peers too, and the package description says to load their CSS and add the package's dist to the consumer's Tailwind sources. The smoke test imports the new entry in the typed consumer and treats it as bundler-only, like `billing/stripe`. ### Reactivation renewal date (live testcloud recording) The reactivation notice and the summary could name different renewal days for the same quote. On `m2-qa-0925-3ds` the notice said "renew … on Oct 27" and the summary "Renews … on Oct 25, 2026". - **Summary:** reads `renewal_at ?? new_plan.period_end` (`resolveRenewalDate`). - **Notice:** read `new_plan.period_end` only. When that was absent, it computed `effective_at` + one period on the client (Sep 27 + 1 month = Oct 27). - **Not a server inconsistency:** the server sent one renewal date, `renewal_at`, which the contract defines as "the next recurring charge and target-plan period end". - **Fix:** the notice now reads the same server date as the summary (`resolveRenewalDate`: `renewal_at`, else the plan's server `period_end`). The client-side computation is gone. With no server date, the notice drops its renewal clause through new `reactivation.withoutRenewalDate` copy, the way the summary drops its date. - **Contract:** `renewal_at` is optional in `PreviewSubscribeResponse` ("Optional in the schema for older clients"; "current servers always return this"). The server should always send it; the client no longer computes one when it doesn't. - **Tests:** - A new test fails on the old code (Oct 27 vs Oct 25). - The tests that pinned the client computation (account-ui and the app's `SubscriptionTransitionPreviewWorkspaceReactivation.test.ts`, in C) are replaced by a no-renewal-date test. - C adds the app's `withoutRenewalDate` strings. ## Review Focus - The ports are meant to be verbatim. C (the next PR) swaps the app onto these components and the app's existing component tests (about 2,100 lines across the two confirms and the success step) pass with only stub names changed. That is the parity check. - `CheckoutPlan.pricedByQuote` reproduces the app's price rules exactly, including the odd ones: a tier plan shows the quote's price once one arrives and `$0` on the success step without one; a team credit stop always shows its own price. ## Stack | PR | branch | base | title | |---|---|---|---| | #19097 | `jaewon/billing-web-remove-plan-grid` | `main` | `FE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selection` | | A #19098 | `jaewon/design-system-button-variants` | #19097 | `FE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-system` | | **B (this PR)** | **`jaewon/account-ui-checkout-surfaces`** | **A** | **`FE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and success`** | | C #19100 | `jaewon/workspace-adopt-account-ui-checkout` | B | `FE-3046 refactor(workspace): render the subscription checkout steps from account-ui` | | D #19101 | `jaewon/billing-web-shared-checkout` | C | `FE-3046 feat(billing-web): render the shared embedded checkout` | | E #19104 | `jaewon/billing-web-success-invite` | D | `FE-3046 feat(billing-web): invite your team from the checkout success step` | | F #19105 | `jaewon/checkout-3ds-failure-copy` | E | `FE-3047 fix(account-ui): clear decline toasts once a retry succeeds` | | G #19106 | `jaewon/billing-web-return-close-tab` | F | `FE-3048 fix(billing-web): return to the host by closing the checkout tab` | | H #19115 | `jaewon/checkout-cta-reachable` | G | `FE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm step` | ```mermaid graph LR P0[#19097: remove plan grid] --> A[A: design-system buttonVariants] A --> B[B: account-ui checkout surfaces] B --> C[C: workspace adopts account-ui] C --> D[D: billing-web shared checkout] D --> E[E: billing-web success invite] E --> F[F: stale decline toasts] F --> G[G: close the billing tab] G --> H[H: reachable checkout CTA] style B fill:#f9d71c,stroke:#333,color:#000 ``` ## AS IS / TO BE No rendered change: nothing renders these components in this PR. The parity screenshots are on C (#19100, app before/after, pixel-identical) and D (#19101, billing-web before/after next to the app). --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…tor, card form and success (#19099) - Linear: FE-3046 **Merge order:** #19096 (ADR 0034 amendment) merges first. Until it does, ADR 0034 rule 4 still forbids account-ui from using the design system, which B does. ## Why billing-web is the cloud app's embedded checkout moved to a new tab, with no UX change (ADR BILLING-WEB-0038, #19096). Today billing-web renders a checkout of its own (`EmbeddedCheckout`, `CheckoutPayment`, `CheckoutSubmit`) that has drifted from the app's: different price layout, no saved-card selection, different copy. For both to render the same screens, the app's confirm, price breakdown, saved-card selector, card form, terms notice and success step have to live where both can import them. This PR adds them to `@comfyorg/account-ui`. Nothing renders them yet, so no visual change. ## How - New entry `@comfyorg/account-ui/billing/checkout`, ported line for line from the app components. Same markup, same classes, same conditions: - `CheckoutSubscribeConfirm` ← `SubscriptionAddPaymentPreviewWorkspace.vue` (plan header, credits, total due, discounts, promo code, saved methods, card form, 3DS prompt, parked-checkout recovery, terms). - `CheckoutTransitionConfirm` ← `SubscriptionTransitionPreviewWorkspace.vue` (immediate vs scheduled change, reactivation banner and threshold checkbox). - `CheckoutSavedMethods` + `CheckoutSavedMethodSelect` ← the saved-method row / `SingleSelect` picker (Reka select with the app's select classes). - `CheckoutPaymentForm` ← `UnifiedStripePaymentSelector.vue` minus the app bindings (key, theme and telemetry become props and a `phase` event). - `CheckoutSuccess` ← `SubscriptionSuccessWorkspace.vue`, with `details`/`actions` slots for the app's team invite. - `CheckoutTermsNote`, `CheckoutPromotionCode`, `CheckoutPaymentNotices`, `CheckoutVerificationPrompt`: blocks both confirms repeated. `CheckoutSubscribeSummary`/`CheckoutSubscribeActions` and `CheckoutReactivationBanner`/`CheckoutTransitionSummary` split the two confirm templates under the fallow complexity gate; the rendered markup is the same. - `checkoutQuote.ts`: the app's `subscriptionQuoteFormatting.ts` + `planDuration.ts`. - `@comfyorg/account-ui/billing/catalog` (TS-only entry): the tiers' prices and monthly credit grants (the numbers in the app's `TIER_PRICING`). The app's confirm reads the grant from this table (`TIER_PRICING`), not from the quote's `new_plan.credits_cents`, so billing-web reads the same table to show the same number; C points the app at it. A separate entry so non-Vue consumers (the Playwright runner imports `tierPricing`) never load the components. - The package has no i18n runtime. Hosts pass a typed `CheckoutCopy`; interpolated strings are functions, and sentences that wrap an element (terms links, reactivation amount) keep `{token}`s that the component splits. - Hosts pass a resolved `CheckoutPlan` (name, monthly/yearly price, credits, `pricedByQuote`) instead of the package reading the tier catalog. - `selectVariants` moves to `@comfyorg/design-system/select.variants` (same move as `buttonVariants` in #19098), so the picker renders the app's select classes. - Packaging: `design-system` variants and `tailwind-utils`'s `cn` are bundled into the published build (dev dependencies). `tailwind-utils` is not on npm and `design-system` ships TS source, so neither can be a runtime dependency of a published package. `reka-ui` is a peer. The rendered classes need the design-system theme and primeicons at runtime, so `@comfyorg/design-system` and `primeicons` are peers too, and the package description says to load their CSS and add the package's dist to the consumer's Tailwind sources. The smoke test imports the new entry in the typed consumer and treats it as bundler-only, like `billing/stripe`. ### Reactivation renewal date (live testcloud recording) The reactivation notice and the summary could name different renewal days for the same quote. On `m2-qa-0925-3ds` the notice said "renew … on Oct 27" and the summary "Renews … on Oct 25, 2026". - **Summary:** reads `renewal_at ?? new_plan.period_end` (`resolveRenewalDate`). - **Notice:** read `new_plan.period_end` only. When that was absent, it computed `effective_at` + one period on the client (Sep 27 + 1 month = Oct 27). - **Not a server inconsistency:** the server sent one renewal date, `renewal_at`, which the contract defines as "the next recurring charge and target-plan period end". - **Fix:** the notice now reads the same server date as the summary (`resolveRenewalDate`: `renewal_at`, else the plan's server `period_end`). The client-side computation is gone. With no server date, the notice drops its renewal clause through new `reactivation.withoutRenewalDate` copy, the way the summary drops its date. - **Contract:** `renewal_at` is optional in `PreviewSubscribeResponse` ("Optional in the schema for older clients"; "current servers always return this"). The server should always send it; the client no longer computes one when it doesn't. - **Tests:** - A new test fails on the old code (Oct 27 vs Oct 25). - The tests that pinned the client computation (account-ui and the app's `SubscriptionTransitionPreviewWorkspaceReactivation.test.ts`, in C) are replaced by a no-renewal-date test. - C adds the app's `withoutRenewalDate` strings. ## Review Focus - The ports are meant to be verbatim. C (the next PR) swaps the app onto these components and the app's existing component tests (about 2,100 lines across the two confirms and the success step) pass with only stub names changed. That is the parity check. - `CheckoutPlan.pricedByQuote` reproduces the app's price rules exactly, including the odd ones: a tier plan shows the quote's price once one arrives and `$0` on the success step without one; a team credit stop always shows its own price. ## Stack | PR | branch | base | title | |---|---|---|---| | #19097 | `jaewon/billing-web-remove-plan-grid` | `main` | `FE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selection` | | A #19098 | `jaewon/design-system-button-variants` | #19097 | `FE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-system` | | **B (this PR)** | **`jaewon/account-ui-checkout-surfaces`** | **A** | **`FE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and success`** | | C #19100 | `jaewon/workspace-adopt-account-ui-checkout` | B | `FE-3046 refactor(workspace): render the subscription checkout steps from account-ui` | | D #19101 | `jaewon/billing-web-shared-checkout` | C | `FE-3046 feat(billing-web): render the shared embedded checkout` | | E #19104 | `jaewon/billing-web-success-invite` | D | `FE-3046 feat(billing-web): invite your team from the checkout success step` | | F #19105 | `jaewon/checkout-3ds-failure-copy` | E | `FE-3047 fix(account-ui): clear decline toasts once a retry succeeds` | | G #19106 | `jaewon/billing-web-return-close-tab` | F | `FE-3048 fix(billing-web): return to the host by closing the checkout tab` | | H #19115 | `jaewon/checkout-cta-reachable` | G | `FE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm step` | ```mermaid graph LR P0[#19097: remove plan grid] --> A[A: design-system buttonVariants] A --> B[B: account-ui checkout surfaces] B --> C[C: workspace adopts account-ui] C --> D[D: billing-web shared checkout] D --> E[E: billing-web success invite] E --> F[F: stale decline toasts] F --> G[G: close the billing tab] G --> H[H: reachable checkout CTA] style B fill:#f9d71c,stroke:#333,color:#000 ``` ## AS IS / TO BE No rendered change: nothing renders these components in this PR. The parity screenshots are on C (#19100, app before/after, pixel-identical) and D (#19101, billing-web before/after next to the app). --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
… grow the confirm step (#19115) - Linear: FE-3050 ## Why M2 QA: after a failed 3DS on a reactivating upgrade, the verification notice pushed "Confirm & reactivate" and the terms below the checkout frame, with no way to scroll to them. This happened in both the app and billing-web. ## Root cause Both hosts pin the narrow confirm and success steps to `h-[min(740px,85vh|90vh)]` with `overflow-hidden`, so the dialog does not grow with the Stripe iframe. The shared step inside (`CheckoutTransitionConfirm`, `CheckoutSubscribeConfirm`, `CheckoutSuccess`) is `h-full` with nothing that scrolls. Once notices, the reactivation banner or the invite chips make it taller than the box, the bottom is clipped. ## How - `CheckoutTransitionConfirm`, `CheckoutSubscribeConfirm` and `CheckoutSuccess` (account-ui) scroll inside the box: `min-h-0 overflow-y-auto` on the step root. Both hosts keep their pinned height. - The wide card-capture split at xl keeps its current layout (`xl:overflow-visible`). Its payment column already handles the Stripe iframe there. - Red-green (billing-web e2e, same component in both hosts): - Red: `77110aa425`, `billing-web-e2e` [failed](https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36342728733/job/108685901864). - Green: `f02bdd6738`. - The test ("a reactivating upgrade taller than the frame scrolls to its confirm") uses a 520px-tall viewport and scrolls the wheel over the confirm, then asserts "Confirm & reactivate" is in view. ## AS IS / TO BE ### Live (testcloud) Live (testcloud) recordings of the whole stack (stack top f02bdd6, embedded vs billing-web, AS IS and TO BE videos and per-step screenshots) are in #19101 under "Live (testcloud) AS IS / TO BE". TO BE live (f02bdd6), reactivating upgrade. The "Reactivating your subscription" notice pushes the terms line below the frame; the confirm now scrolls inside the frame so "Confirm & reactivate" and the terms line are reachable on both hosts. Embedded (left) | billing-web (right), top of the step and scrolled: <img width="1400" alt="live-confirm-top" src="https://github.com/user-attachments/assets/20bbd27d-361c-48d4-8857-ddd6bc71ced3" /> <img width="1400" alt="live-confirm-scrolled" src="https://github.com/user-attachments/assets/2f3d6e40-6819-4f52-b2f8-b76d829fca1c" /> Not run live: the tallest case, a failed 3DS adding its notice under the reactivation banner. A failed reactivating upgrade leaves the operation pending and the workspace cannot be cancelled afterwards (QA N6), so it stays in the harness. ### Harness This is a parity-harness step with mocked Cloud: P2c, a reactivating upgrade in a 1440x560 window, with the wheel scrolled over the confirm. It reproduces the same clipping QA recorded after a failed 3DS: here the reactivation banner does the growing instead of the verification notice. The full harness rerun on this branch shows 0% copy/element difference on all 18 steps, and P2c is 0% between the hosts. **Cloud app, AS IS | TO BE** <img width="1448" alt="H-app" src="https://github.com/user-attachments/assets/33076467-ac1e-4695-942e-75d1f235346a" /> **billing-web, AS IS | TO BE** <img width="1448" alt="H-web" src="https://github.com/user-attachments/assets/61773efd-fbbd-4fcf-a48c-3a31944076e3" /> ## Stack | PR | branch | base | title | |---|---|---|---| | #19097 | `jaewon/billing-web-remove-plan-grid` | `main` | `FE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selection` | | A #19098 | `jaewon/design-system-button-variants` | #19097 | `FE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-system` | | B #19099 | `jaewon/account-ui-checkout-surfaces` | A | `FE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and success` | | C #19100 | `jaewon/workspace-adopt-account-ui-checkout` | B | `FE-3046 refactor(workspace): render the subscription checkout steps from account-ui` | | D #19101 | `jaewon/billing-web-shared-checkout` | C | `FE-3046 feat(billing-web): render the shared embedded checkout` | | E #19104 | `jaewon/billing-web-success-invite` | D | `FE-3046 feat(billing-web): invite your team from the checkout success step` | | F #19105 | `jaewon/checkout-3ds-failure-copy` | E | `FE-3047 fix(account-ui): clear decline toasts once a retry succeeds` | | G #19106 | `jaewon/billing-web-return-close-tab` | F | `FE-3048 fix(billing-web): return to the host by closing the checkout tab` | | **H (this PR)** | **`jaewon/checkout-cta-reachable`** | **G** | **`FE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm step`** | ```mermaid graph LR P0[#19097: remove plan grid] --> A[A: design-system buttonVariants] A --> B[B: account-ui checkout surfaces] B --> C[C: workspace adopts account-ui] C --> D[D: billing-web shared checkout] D --> E[E: billing-web success invite] E --> F[F: stale decline toasts] F --> G[G: close the billing tab] G --> H[H: reachable checkout CTA] style H fill:#f9d71c,stroke:#333,color:#000 ```
…tab (#19106) - Linear: FE-3048 ## Why Close / "Return to ComfyUI" on billing-web navigated the billing tab to `<host>/?billing_result=success&billing_ref=…`. The customer ended with two product tabs, the outcome query in the URL, and no confirmation in the tab they came from. The embedded checkout's Close just returns to the app in place. ## Root cause billing-web treated "return to the host" as a navigation. The host opens billing-web in a tab of its own (`openHostedBillingTab`), so the host's tab is still there. The way back is to close the billing tab. The app also never removed `billing_result`/`billing_ref` from its URL. ## How - billing-web `returnToHost`: `window.close()`, and only if the tab is still open (`closed` stays false because the customer opened it directly) navigate to the host's URL as before. A tab opened by script may close itself even with `noopener`. Used by the checkout's Back / Close / success Close and by the hosted pages' "Return to …" link. - App: `stripPaymentReturnParams` (run at boot on cloud) also strips `billing_result`/`billing_ref`. They do not count as a pending Stripe payment, and the URL loaders treat them as handled. The app already refreshes billing on return (FE-2618). - Tests: - Unit: CheckoutView closes instead of navigating for Back, Close and the success Close; the app strips the params. - billing-web e2e: a tab opened with `window.open` closes on Close, and a directly opened tab goes back to the host on Back. 31/31 locally. - Red-green: failing tests in `8b7c880b1b`, fix in `4dd355511b`. - Red: Billing Web Unit [https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36335085117](https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36335085117), Billing Web E2E [https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36335085068](https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36335085068) (rerun). - Green: Billing Web Unit [https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36335184604](https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36335184604), Billing Web E2E [https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36335184605](https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36335184605). ## AS IS / TO BE ### Live (testcloud) Live (testcloud) recordings of the whole stack (stack top f02bdd6, embedded vs billing-web, AS IS and TO BE videos and per-step screenshots) are in #19101 under "Live (testcloud) AS IS / TO BE". TO BE live (f02bdd6): Change plan in the local app (`ff:hosted_billing_destination="billing_web"`, workspace `m2-qa-0927-full`) opens billing-web on :5174 in a new tab. Pay → "You're all set" → Close. The billing tab closes, the app tab is back in front with a clean URL, and its account menu shows 294,054 credits (147,700 before) with no Resubscribe. https://github.com/user-attachments/assets/1da3540f-fcf6-4691-a075-997b07c364f1 After Close, embedded (left) | billing-web (right): <img width="1400" alt="live-after-close" src="https://github.com/user-attachments/assets/4989f353-1d96-4255-b7a4-cd78a092f86e" /> ### Harness billing-web e2e harness (mocked Cloud). The checkout tab is opened with `window.open` from another billing-web tab, which stands in for the product tab. The subscribe succeeds, then Close is clicked. The captions give each open tab's URL afterwards. **AS IS (#19105):** the billing tab navigates to the host with `billing_result`/`billing_ref`, so there are two tabs. <img width="1938" alt="G-asis" src="https://github.com/user-attachments/assets/2e97e750-989b-425a-a60e-8800fafa511f" /> **TO BE:** the billing tab closes and only the original tab remains. <img width="1938" alt="G-tobe" src="https://github.com/user-attachments/assets/b95ab6fd-f891-4379-bc39-361a3a6c1f94" /> ## Stack | PR | branch | base | title | |---|---|---|---| | #19097 | `jaewon/billing-web-remove-plan-grid` | `main` | `FE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selection` | | A #19098 | `jaewon/design-system-button-variants` | #19097 | `FE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-system` | | B #19099 | `jaewon/account-ui-checkout-surfaces` | A | `FE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and success` | | C #19100 | `jaewon/workspace-adopt-account-ui-checkout` | B | `FE-3046 refactor(workspace): render the subscription checkout steps from account-ui` | | D #19101 | `jaewon/billing-web-shared-checkout` | C | `FE-3046 feat(billing-web): render the shared embedded checkout` | | E #19104 | `jaewon/billing-web-success-invite` | D | `FE-3046 feat(billing-web): invite your team from the checkout success step` | | F #19105 | `jaewon/checkout-3ds-failure-copy` | E | `FE-3047 fix(account-ui): clear decline toasts once a retry succeeds` | | **G (this PR)** | **`jaewon/billing-web-return-close-tab`** | **F** | **`FE-3048 fix(billing-web): return to the host by closing the checkout tab`** | | H #19115 | `jaewon/checkout-cta-reachable` | G | `FE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm step` | ```mermaid graph LR P0[#19097: remove plan grid] --> A[A: design-system buttonVariants] A --> B[B: account-ui checkout surfaces] B --> C[C: workspace adopts account-ui] C --> D[D: billing-web shared checkout] D --> E[E: billing-web success invite] E --> F[F: stale decline toasts] F --> G[G: close the billing tab] G --> H[H: reachable checkout CTA] style G fill:#f9d71c,stroke:#333,color:#000 ```
…19105) - Linear: FE-3047 ## Why In the real run, a failed 3DS challenge (card 3184, then Fail) first showed "We couldn't complete payment verification. Please try again.". A toast then replaced it with "Your bank declined this payment. Try another payment method or contact your bank.". Separately, after one or more declines, a retry that succeeded left the old decline toasts on screen over "You're all set". ## Root cause - **Wrong copy after a failed 3DS: a server-side cause.** The backend recorded a failed 3DS as a generic decline. It is fixed in BE-17429 / Comfy-Org/cloud#10828, which records `payment_intent_authentication_failure`. With that fix, `GET /api/billing/ops/{id}` returns `decline_reason: authentication_failed`. The frontend already maps that reason to the verification copy, so it does not re-derive it. **The live copy depends on BE-17429 deploying.** - **Stale toasts:** `useSubscriptionCheckout.showSubscribeError` adds a sticky error toast for each refused attempt. Nothing removed those toasts when a later attempt succeeded. - **"Update payment to run" in the top bar:** a different root cause, left out of this PR. The label is the run button's `paymentRecovery` state, which comes from the billing status and not from the checkout's failure copy. ## How - `useSubscriptionCheckout` remembers the error toasts from its attempts and removes them when the checkout reaches success. - Table tests pin the server-reason mapping on every surface. `decline_reason: authentication_failed` and `authentication_required` read as "We couldn't complete payment verification. Please try again." in all four: - the shared lifecycle (`account-core` `operationState`), - the app's SDK rail (`subscriptionOperationView`), - the app's legacy poller (`billingOperationStore`), - billing-web (`CheckoutView`). - There are no lifecycle or poller code changes, so F's diff over E is the toast cleanup plus tests. - Red-green for the toast cleanup: failing test in `5f86dba8a0`, fix in `5982f627c2`. - Red: [CI Tests Unit, run 36334659973](https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36334659973). - Green: [CI Tests Unit, run 36334977694](https://github.com/Comfy-Org/ComfyUI_frontend/actions/runs/36334977694). - `08f850f705` removes the client-side override those commits had added, since the server now sends the reason. ## AS IS / TO BE ### Live (testcloud) Live (testcloud) recordings of the whole stack (stack top f02bdd6, embedded vs billing-web, AS IS and TO BE videos and per-step screenshots) are in #19101 under "Live (testcloud) AS IS / TO BE". Not recorded live for this PR: a decline followed by a successful retry needs the card form, which only the new-subscription path shows. No unsubscribed Stripe-billed workspace is free on the test account (10-workspace limit, and `parity-emb-0927` holds a pending operation). The live TO BE upgrade in #19101 settles without a decline, and neither host shows a stale toast over "You're all set" there. ### Harness Evidence comes from the parity harness with mocked Cloud, not a live backend. **P6c: 3DS fails, then the server settles with `decline_reason: authentication_failed` (what BE-17429 sends).** Both surfaces show the verification copy. The left half is the Cloud app and the right half is billing-web. E shows the same copy, because the mapping already existed. <img width="1448" alt="F-3ds" src="https://github.com/user-attachments/assets/108260c7-5a66-424a-8eb5-3b93b04f0571" /> **P6d: a saved card is declined, then a retry succeeds.** In the Cloud app, E (left) keeps the decline toast over "You're all set". F (right) clears it. <img width="1448" alt="F-toast" src="https://github.com/user-attachments/assets/5a173b2e-7f6e-46ad-9d47-3c6323953fda" /> P6a, P6b, P7 and P7T are unchanged. P6b has the known 0.003% spinner frame. ## Stack | PR | branch | base | title | |---|---|---|---| | #19097 | `jaewon/billing-web-remove-plan-grid` | `main` | `FE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selection` | | A #19098 | `jaewon/design-system-button-variants` | #19097 | `FE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-system` | | B #19099 | `jaewon/account-ui-checkout-surfaces` | A | `FE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and success` | | C #19100 | `jaewon/workspace-adopt-account-ui-checkout` | B | `FE-3046 refactor(workspace): render the subscription checkout steps from account-ui` | | D #19101 | `jaewon/billing-web-shared-checkout` | C | `FE-3046 feat(billing-web): render the shared embedded checkout` | | E #19104 | `jaewon/billing-web-success-invite` | D | `FE-3046 feat(billing-web): invite your team from the checkout success step` | | **F (this PR)** | **`jaewon/checkout-3ds-failure-copy`** | **E** | **`FE-3047 fix(account-ui): clear decline toasts once a retry succeeds`** | | G #19106 | `jaewon/billing-web-return-close-tab` | F | `FE-3048 fix(billing-web): return to the host by closing the checkout tab` | | H #19115 | `jaewon/checkout-cta-reachable` | G | `FE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm step` | ```mermaid graph LR P0[#19097: remove plan grid] --> A[A: design-system buttonVariants] A --> B[B: account-ui checkout surfaces] B --> C[C: workspace adopts account-ui] C --> D[D: billing-web shared checkout] D --> E[E: billing-web success invite] E --> F[F: stale decline toasts] F --> G[G: close the billing tab] G --> H[H: reachable checkout CTA] style F fill:#f9d71c,stroke:#333,color:#000 ```
…9099, #19100, #19101, #19104) (#19442) ## Why Backport of the FE-3046 billing-web shared-checkout stack to `core/1.55`. The auto-backport bot hit cherry-pick conflicts on each of these. The 1.55 release needs billing-web to render the same checkout as the app, including the team invite on success. ## How ### Cherry-picked (in order, `-x`) | PR | main squash | | |---|---|---| | #19098 (A) | | skipped: already on `core/1.55` via #19231 | | #19099 (B) | | skipped: already on `core/1.55` via #19308 | | #19100 (C) | `4bfdc8a68c` | render the subscription checkout steps from account-ui | | #19101 (D) | `d5cf71ce27` | billing-web renders the shared embedded checkout | | #19104 (E) | `592588bdd6` | team invite on the checkout success step (squash includes #19105, #19106, #19115) | No other prerequisite was cherry-picked. ### Conflicts and resolutions - **C, `SubscriptionAddPaymentPreviewWorkspace.stripe.test.ts`** (renamed from `UnifiedStripePaymentSelector.test.ts`). 1.55 mocks telemetry with an explicit factory because it lacks #18497; main automocks it. Took C's file as is. `src/platform/telemetry/__mocks__/index.ts` exists on 1.55, so the automock resolves and the test passes. - **D, `apps/billing-web/src/views/CheckoutView.vue`**. 1.55 has #19305 (backport of #19185, show the server's refusal reason), which main does not have yet. Kept D's checkout and kept 1.55's `refusal()` on the subscribe failure and the quote-failure panel. Also used `refusal()` for D's new promotion-code re-quote failure, as the upstream `jaewon/checkout-quote-stale-recovery` stack does. Dropped the now-unused `coded`. - **E, `apps/billing-web/src/session/billingWebAuth.ts`** (modify/delete). The file does not exist on 1.55 because the unified web session work (#18880, #18881) is not backported. Deleted it and applied E's change to what 1.55 has: `billingWebClient.ts` gains the `BillingWebClient` type (`BillingClient & { invites }`) and `invites: createWorkspaceInviteCommands({ transport })` on its single `createBillingWebClient`. - **E, `BillingShell.vue`**. Kept 1.55's `createBillingWebClient(billingWebSessionClient())` and added E's `provideWorkspaceInvites(client.invites)`. - **E, `HostedSurface.vue`**. Kept 1.55's `useBillingWebSession` and added E's `returnToHost` import (the return link now closes the tab, from #19106). - **E, `CheckoutView.vue`**. Kept `refusal` as above and took E's `inviteCopy` and `useWorkspaceInvites()`. - **E, `useSubscriptionCheckout.ts`**. Kept 1.55's `useEventListener` import and added E's `watch` and `ToastMessageOptions`. 1.55 does not use `onScopeDispose`, so it is not imported. - **E, `useSubscriptionCheckout.test.ts`**. The toast mock gains E's `remove`. 1.55 has no `removeGroup` usage, so `mockToastRemoveGroup` is not added. One extra commit updates a #19305 test case. For a refused subscribe with `OPERATION_ALREADY_PENDING`, it expected the generic failure copy because 1.55 had no copy for that code. D adds that copy, so the case now expects billing-web's own wording, matching the upstream stack. ## Verification - `pnpm typecheck` (app, account-core, billing-web, account-ui, billing-contract): pass - billing-web unit tests: 277/277 - account-ui unit tests: 224/224 - account-core unit tests: 1227/1227 - `src/platform/workspace` + `src/platform/cloud/subscription`: 2320 passed, 1 expected fail - oxfmt, oxlint and eslint on the changed files: clean ## AS IS / TO BE Same UI as the original PRs; see the AS IS / TO BE media in #19101 and #19104. --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…19099, #19100, #19101, #19104) (#19443) ## Why Backport of the FE-3046 billing-web shared-checkout stack to `cloud/1.55`. The auto-backport bot hit cherry-pick conflicts on each of these. The 1.55 release needs billing-web to render the same checkout as the app, including the team invite on success. ## How ### Cherry-picked (in order, `-x`) | PR | main squash | | |---|---|---| | #19098 (A) | | skipped: already on `cloud/1.55` via #19232 | | #19099 (B) | | skipped: already on `cloud/1.55` via #19309 | | #19100 (C) | `4bfdc8a68c` | render the subscription checkout steps from account-ui | | #19101 (D) | `d5cf71ce27` | billing-web renders the shared embedded checkout | | #19104 (E) | `592588bdd6` | team invite on the checkout success step (squash includes #19105, #19106, #19115) | No other prerequisite was cherry-picked. ### Conflicts and resolutions - **C, `SubscriptionAddPaymentPreviewWorkspace.stripe.test.ts`** (renamed from `UnifiedStripePaymentSelector.test.ts`). 1.55 mocks telemetry with an explicit factory because it lacks #18497; main automocks it. Took C's file as is. `src/platform/telemetry/__mocks__/index.ts` exists on 1.55, so the automock resolves and the test passes. - **D, `apps/billing-web/src/views/CheckoutView.vue`**. 1.55 has #19304 (backport of #19185, show the server's refusal reason), which main does not have yet. Kept D's checkout and kept 1.55's `refusal()` on the subscribe failure and the quote-failure panel. Also used `refusal()` for D's new promotion-code re-quote failure, as the upstream `jaewon/checkout-quote-stale-recovery` stack does. Dropped the now-unused `coded`. - **E, `apps/billing-web/src/session/billingWebAuth.ts`** (modify/delete). The file does not exist on 1.55 because the unified web session work (#18880, #18881) is not backported. Deleted it and applied E's change to what 1.55 has: `billingWebClient.ts` gains the `BillingWebClient` type (`BillingClient & { invites }`) and `invites: createWorkspaceInviteCommands({ transport })` on its single `createBillingWebClient`. - **E, `BillingShell.vue`**. Kept 1.55's `createBillingWebClient(billingWebSessionClient())` and added E's `provideWorkspaceInvites(client.invites)`. - **E, `HostedSurface.vue`**. Kept 1.55's `useBillingWebSession` and added E's `returnToHost` import (the return link now closes the tab, from #19106). - **E, `CheckoutView.vue`**. Kept `refusal` as above and took E's `inviteCopy` and `useWorkspaceInvites()`. - **E, `useSubscriptionCheckout.ts`**. Kept 1.55's `useEventListener` import and added E's `watch` and `ToastMessageOptions`. 1.55 does not use `onScopeDispose`, so it is not imported. - **E, `useSubscriptionCheckout.test.ts`**. The toast mock gains E's `remove`. 1.55 has no `removeGroup` usage, so `mockToastRemoveGroup` is not added. The cloud branch takes the same resolved commits from the core backport; they applied without further conflicts. One extra commit updates a #19304 test case. For a refused subscribe with `OPERATION_ALREADY_PENDING`, it expected the generic failure copy because 1.55 had no copy for that code. D adds that copy, so the case now expects billing-web's own wording, matching the upstream stack. ## Verification - `pnpm typecheck` (app, account-core, billing-web, account-ui, billing-contract): pass - billing-web unit tests: 277/277 - account-ui unit tests: 224/224 - account-core unit tests: 1226/1226 - `src/platform/workspace` + `src/platform/cloud/subscription`: 2325 passed, 1 expected fail - oxfmt, oxlint and eslint on the changed files: clean ## AS IS / TO BE Same UI as the original PRs; see the AS IS / TO BE media in #19101 and #19104. --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
… step (Comfy-Org#19104) - Linear: FE-3046 ## Why After a multi-seat (team) subscribe, the cloud app's success step invites the team (`SubscriptionSuccessWorkspace` + `InviteMembersForm`). billing-web's success step (Comfy-Org#19101) showed the plan card and Close only. billing-web is the embedded checkout in a new tab (ADR BILLING-WEB-0038), so it gets the same step. ## How - `@comfyorg/account-core/billing`: `createWorkspaceInviteCommands({ transport })` with `listPendingInvites` and `createInvite` (`GET`/`POST /workspace/invites`, parsed against the generated contract). It runs over the billing session transport, so invites go to the workspace the entry link bound — no second client, no hand-rolled fetch. - `@comfyorg/account-ui/billing/checkout`: `CheckoutTeamSuccess` wraps `CheckoutSuccess` with the app's invite block: same heading, subtext, email tags, invalid / already-invited / seat-cap hints, one invite per address, confirmation message, "Send invites" leading and Close demoted. The invite rules (`inviteEmails.ts`) move from the app into the package and the app imports them from there. - `@comfyorg/design-system/tag.variants`: the tag recipe moves out of the app, as `buttonVariants`/`selectVariants` did, so the package's email tags use the app's classes. - billing-web: the client carries the invite commands; `CheckoutView` reads seats from billing status on success (and again after invites, as the app refreshes status) and renders `CheckoutTeamSuccess`. A failed invite shows the app's "Couldn't send N invites" toast. - `CheckoutFrame`: the app's browser defaults for inputs and links move to a base-layer rule, so a utility (the tags input's `text-sm`) still wins, as it does in the app. ## Review Focus - The app still renders its own `InviteMembersForm` (also used by the invite dialog, with telemetry and the app toast). Switching the app to `CheckoutTeamSuccess` is a follow-up; this PR moves the shared rules, recipe and client so that step is small. - CORS for `/api/workspace/invites` from the billing-web origin is not verified against a live backend (mocked here). ### Checkbox margin (parity) The app has no Tailwind preflight, so its reactivation checkbox keeps the browser's margin. `[data-app-defaults]` now reverts that margin too, which removes a 2px shift in the reactivation notice (harness P2e: 3.4% to 0.01%). ## Stack | PR | branch | base | title | |---|---|---|---| | Comfy-Org#19097 | `jaewon/billing-web-remove-plan-grid` | `main` | `FE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selection` | | A Comfy-Org#19098 | `jaewon/design-system-button-variants` | Comfy-Org#19097 | `FE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-system` | | B Comfy-Org#19099 | `jaewon/account-ui-checkout-surfaces` | A | `FE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and success` | | C Comfy-Org#19100 | `jaewon/workspace-adopt-account-ui-checkout` | B | `FE-3046 refactor(workspace): render the subscription checkout steps from account-ui` | | D Comfy-Org#19101 | `jaewon/billing-web-shared-checkout` | C | `FE-3046 feat(billing-web): render the shared embedded checkout` | | **E (this PR)** | **`jaewon/billing-web-success-invite`** | **D** | **`FE-3046 feat(billing-web): invite your team from the checkout success step`** | | F Comfy-Org#19105 | `jaewon/checkout-3ds-failure-copy` | E | `FE-3047 fix(account-ui): clear decline toasts once a retry succeeds` | | G Comfy-Org#19106 | `jaewon/billing-web-return-close-tab` | F | `FE-3048 fix(billing-web): return to the host by closing the checkout tab` | | H Comfy-Org#19115 | `jaewon/checkout-cta-reachable` | G | `FE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm step` | ```mermaid graph LR P0[Comfy-Org#19097: remove plan grid] --> A[A: design-system buttonVariants] A --> B[B: account-ui checkout surfaces] B --> C[C: workspace adopts account-ui] C --> D[D: billing-web shared checkout] D --> E[E: billing-web success invite] E --> F[F: stale decline toasts] F --> G[G: close the billing tab] G --> H[H: reachable checkout CTA] style E fill:#f9d71c,stroke:Comfy-Org#333,color:#000 ``` ## AS IS / TO BE ### Live (testcloud) Live (testcloud) recordings of the whole stack (stack top f02bdd6, embedded vs billing-web, AS IS and TO BE videos and per-step screenshots) are in Comfy-Org#19101 under "Live (testcloud) AS IS / TO BE". TO BE live, team reactivating upgrade paid on both hosts: "You're all set" with Invite your team on the embedded checkout (left) and billing-web (right). <img width="1400" alt="live-success-invite" src="https://github.com/user-attachments/assets/42b820df-b6b8-4748-a768-5969d7474fb4" /> ### Harness Checkout parity harness step P7T (new: team subscribe → success; mocked Cloud, not a live backend). **billing-web AS IS** (Comfy-Org#19101) | **billing-web TO BE** (this PR) | **cloud app**. TO BE vs app: 0% panel pixel diff, no copy or element differences. The other 11 steps are unchanged (all 0% except the busy spinner frame on P5/P6b, 0.003%). <img width="1558" alt="P7T" src="https://github.com/user-attachments/assets/2af1e0c9-d5f3-4270-8621-b2fb71cdeff3" /> --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…e app does (Comfy-Org#19126) - Linear: FE-3056 ## Why When the server refuses a subscribe because the quote went stale, the embedded checkout re-quotes and tells the customer "Your quote changed. Review the updated amount and try again." billing-web instead shows "We couldn't reach the billing service. Please try again." and keeps the old quote, so every retry is refused the same way. Seen live on testcloud with a Team monthly → annual change (`POST /api/billing/subscribe` → 400 `SUBSCRIPTION_QUOTE_STALE`). ## Root cause `issueSubscribe` in `packages/account-core/src/core/billing/subscriptionCommands.ts` maps only `REACTIVATION_CONFIRMATION_REQUIRED`; any other coded 4xx reaches the host as a generic failure. `CheckoutView.pay` in billing-web has no branch for a stale quote, so the failure copy is the transport one. The app's legacy rail handles the code in `useSubscriptionCheckout.recoverStaleQuote`. ## How - account-core: `SUBSCRIPTION_QUOTE_STALE` becomes the command code `QUOTE_STALE`, the same way the reactivation code is mapped. - billing-web: on `QUOTE_STALE`, re-quote the plan and show the app's copy ("Your quote changed. Review the updated amount and try again."); if the re-quote itself fails, show the app's "quote refresh failed" copy. - Tests: an account-core case for the mapping and a CheckoutView case for the re-quote and copy. Both fail before the fix. - Red: the two new tests fail locally on edd1324 (the CI run for that commit was cancelled by the fix push); green: CI on 2ca20d8. The stale quotes themselves come from the server (non-deterministic `renewal_at` on preview for a monthly → annual change); that was reported to backend separately. ## AS IS / TO BE **AS IS:** billing-web monthly → annual shows "We couldn't reach the billing service" (server 400 `SUBSCRIPTION_QUOTE_STALE`); the same change in the embedded checkout then goes through. https://github.com/user-attachments/assets/b31ba7c9-0db0-4a84-a329-804ed28dac4f **TO BE:** Unit and view tests (CheckoutView re-quotes and shows "Your quote changed. Review the updated amount and try again."). The stale quote is intermittent server-side, so a live TO BE capture is pending the backend fix. ## Stack | PR | Title | |---|---| | Comfy-Org#19097 | FE-3045 drop the billing-web plan grid | | Comfy-Org#19098 | FE-3046 A buttonVariants into design-system | | Comfy-Org#19099 | FE-3046 B account-ui checkout surfaces | | Comfy-Org#19100 | FE-3046 C app renders account-ui checkout | | Comfy-Org#19101 | FE-3046 D billing-web shared checkout | | Comfy-Org#19104 | FE-3046 E invite from the success step | | Comfy-Org#19105 | FE-3047 F clear decline toasts on success | | Comfy-Org#19106 | FE-3048 G return closes the tab | | Comfy-Org#19115 | FE-3050 H CTA reachable | | **this PR** | **FE-3056 I stale quote re-quoted** | ```mermaid graph LR P97[Comfy-Org#19097] --> A[Comfy-Org#19098] --> B[Comfy-Org#19099] --> C[Comfy-Org#19100] --> D[Comfy-Org#19101] --> E[Comfy-Org#19104] --> F[Comfy-Org#19105] --> G[Comfy-Org#19106] --> H[Comfy-Org#19115] --> I[FE-3056]:::me classDef me fill:#f9d71c,stroke:#333,color:#000 ``` --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Why
#19099 moved the app's checkout steps into
@comfyorg/account-ui. Until the app renders those components, the package holds a second copy that nothing keeps in step. This PR makes the app render them, so the app and (in D) billing-web share one implementation. No visual change in the app.How
SubscriptionAddPaymentPreviewWorkspace.vue,SubscriptionTransitionPreviewWorkspace.vueandSubscriptionSuccessWorkspace.vuekeep their props and events, so their parents are untouched. Each now rendersCheckoutSubscribeConfirm,CheckoutTransitionConfirmorCheckoutSuccessand binds what only the app knows:useCheckoutCopy), including theCheckoutPlanbuilt from the tier catalog or the team credit stop,UnifiedStripePaymentSelector.vue),useBillingContext(loaded, cancelled, end date) for the reactivation banner,CheckoutSuccess's slots.UnifiedStripePaymentSelector.vue,SubscriptionTermsNote.vue,subscriptionQuoteFormatting.tsandplanDuration.ts(plus their tests, which the package'scheckoutQuote.test.tsand component tests cover).useSubscriptionCheckoutimportsamountDueTodayChangedfrom the package.TIER_PRICINGspreads the sharedTIER_CATALOG(same numbers) and keeps its app-onlyvideoEstimate.UnifiedStripePaymentSelector.test.tsbecomesSubscriptionAddPaymentPreviewWorkspace.stripe.test.ts: the same key, copy, theme and telemetry assertions against the binding.Review Focus
Parity evidence: the existing component tests for the three steps (
SubscriptionAddPaymentPreviewWorkspace.test.ts,SubscriptionTransitionPreviewWorkspace*.test.ts,SubscriptionSuccessWorkspace.test.ts) pass unchanged, apart from renaming the stubbed children (UnifiedStripePaymentSelector→CheckoutPaymentForm,SingleSelect→CheckoutSavedMethodSelect,SubscriptionTermsNote→CheckoutTermsNote).Stack
jaewon/billing-web-remove-plan-gridmainFE-3045 refactor(billing-web): drop the billing-web plan grid; hosts own plan selectionjaewon/design-system-button-variantsFE-3046 refactor(design-system): move buttonVariants into @comfyorg/design-systemjaewon/account-ui-checkout-surfacesFE-3046 feat(account-ui): shared checkout confirm, saved-method selector, card form and successjaewon/workspace-adopt-account-ui-checkoutFE-3046 refactor(workspace): render the subscription checkout steps from account-uijaewon/billing-web-shared-checkoutFE-3046 feat(billing-web): render the shared embedded checkoutjaewon/billing-web-success-inviteFE-3046 feat(billing-web): invite your team from the checkout success stepjaewon/checkout-3ds-failure-copyFE-3047 fix(account-ui): clear decline toasts once a retry succeedsjaewon/billing-web-return-close-tabFE-3048 fix(billing-web): return to the host by closing the checkout tabjaewon/checkout-cta-reachableFE-3050 fix(account-ui): keep the checkout CTA reachable when notices grow the confirm stepAS IS / TO BE
Each image: left = AS IS (app on #19099, old components), right = TO BE (this PR). Rendered in Storybook (a temporary story, not committed) with the app components' real props, the checkout dialog's frame classes, dark theme, 1440x900, and a fake
js.stripe.com(the same fake billing-web's e2e uses), so the card element area is blank in both. Not against a live backend. AS IS and TO BE are pixel-identical for all four steps (PIL diff: no differing pixels).Confirm + card entry (new subscription, no saved method)
Confirm + saved-card selector (two saved cards)
Plan change (upgrade, no card form)
Success