Skip to content

FE-2331 feat(billing-web): confirm a reactivation charge before subscribing and surface a refused subscribe - #17943

Merged
dante01yoon merged 4 commits into
fe-2331-billing-web-subscription-actionsfrom
fe-2331-billing-web-reactivation-confirm
Sep 18, 2026
Merged

dante01yoon merged 4 commits into
fe-2331-billing-web-subscription-actionsfrom
fe-2331-billing-web-reactivation-confirm

Conversation

@dante01yoon

@dante01yoon dante01yoon commented Sep 17, 2026 •

Copy link
Copy Markdown
Collaborator

Linear FE-2331. Stacked on #17937 → #17936. Closes the one thing #17937's Review Focus said it surfaced but did not handle.

Why

A cancelled subscription is reactivated by subscribing again, and the server wants that charge confirmed in so many words. It says so in one of two places: the quote carries requires_reactivation_confirmation: true, or — when the quote did not know — the subscribe answers REACTIVATION_CONFIRMATION_REQUIRED and expects the host to re-quote and resend with confirm_reactivation. #17936 handled neither: the first case paid without asking, the second case read as a generic failure. And a refused subscribe of any kind showed the customer nothing at all — checkout.subscribe's result was discarded, so a REQUEST_FAILED left the form exactly as it was, with no sign anything had happened.

How

In CheckoutView:

  • The quote decides first. reactivationRequired follows preview.requires_reactivation_confirmation, reset on every new quote; while it is set, canSubmit is false until the customer ticks "Your subscription was cancelled. I confirm the {amount} charge to reactivate it." The amount is the quote's amount_due_cents (falling back to cost_today_cents), formatted with the app's currency format — the same figure the summary panel shows as "Total due today", so the confirmation names the charge they are looking at.
  • The server can override. confirm now awaits the result. On REACTIVATION_CONFIRMATION_REQUIRED it re-quotes the plan (previewSubscribe again, so the amount is the server's current one), sets reactivationRequired, and stops. No operation was issued, so the form is still mounted; the customer confirms and pays again, and the resend carries confirm_reactivation: true and the fresh token.
  • Every other refusal is shown. submitFailure renders coded('failure', code) above the pay button; the form stays.

This is the cloud app's handleSubscription loop reduced to what a hosted page needs: it does not re-check the amount before the confirmed send (the quote identity on the request is what the server validates), and it does not carry the "amount changed since you confirmed" branch, because a re-quote here always resets the confirmation.

Review focus

The re-quote happens after the server's refusal, not before the first send. The cloud app re-previews before sending when it already knows the subscription is cancelled. This page trusts the quote it was given and lets the server say otherwise once; the cost is one round trip on the rare path, the benefit is no second source of "is this cancelled" on the client.

fake.subscribe is now typed as a Mock so the test can script one refusal followed by an acceptance. The other fake commands keep their plain function types.

Verification

pnpm -C apps/billing-web typecheck   # clean
pnpm -C apps/billing-web test:unit   # 13 files, 111 tests (+3)
pnpm -C apps/billing-web lint        # clean

The three new scenarios: the quote-named confirmation gates the pay button and lands confirm_reactivation: true; the server-demanded one re-quotes, gates, and the resend carries the new token plus the flag; a refused subscribe shows our copy and keeps the form.

AS IS / TO BE

  • AS IS — a cancelled workspace could be charged for reactivation with no confirmation; a server-side demand for one read as a generic error; any refused subscribe was silent.
  • TO BE — the charge is named and confirmed before it is sent, whichever side asked; refusals are shown.

No UI reaches production until hosted_billing_destination says billing_web.

Where this sits in the plan

Billing SDK track FE-2210 (implementation plan V2); remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

Phase Item Ticket Status
7 What belongs in @comfyorg/account-ui (ADR-0034) FE-2218 merged (#17927)
7 billing-web Vercel deployment config FE-2218 merged (#17788)
7 Package release workflows + versioning ADR FE-2218 merged (#17881)
7 Publish report through a workflow_run consumer FE-2218 merged (#17952)
7 account-ui builds to dist and packs clean FE-2218 merged (#17929)
7 account-ui drops its unpublished dependencies, joins smoke:pack FE-2218 merged (#17932)
7 billing-web report-only CSP and framing denial FE-2218 merged (#17941)
8 ui Promote the Stripe payment UI into account-ui FE-2331 open (#17934)
8 ui billing-web checkout, result page, invoices through the portal FE-2331 open (#17936)
8 ui billing-web cancel / resubscribe on the subscription surface FE-2331 open (#17937)
8 ui billing-web reactivation confirmation, refused subscribe surfaced FE-2331 this PR
8 ui billing-web Playwright harness against a mocked Cloud FE-2218 merged (#17947)
9 Status and balance reads on the rail FE-2216 merged (#17940)
9 Plan catalog read on the rail FE-2216 merged (#17942)
9 Capabilities and saved payment methods on the rail FE-2216 merged (#17946)
9 Legacy billingOperationStore removal FE-2216 after the flags flip
7 First publish of account-core, billing-contract, ingest-types FE-2218 published on next
7 account-ui joins the release tables FE-2218 open (#17989)
7 Phase 7 host proof: live top-up on billing.comfy.org FE-2218 gated (flags, CNAME, key)
6 Phase 6 live E2E evidence table FE-2217 gated (staging flags)
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged #17881)"]
  PUBREP["publish report via workflow_run (merged #17952)"]
  UIB["account-ui dist build (merged #17929)"]
  DEPS["drop unpublished deps (merged #17932)"]
  CSP["billing-web CSP (merged #17941)"]
  PROMO["Stripe payment form in account-ui (#17934)"]
  CHK["billing-web checkout + result + invoices (#17936)"]
  SUBW["billing-web cancel / resubscribe (#17937)"]
  REACT["reactivation confirmation (#17943)"]
  E2E["billing-web Playwright harness (#17947)"]
  RD1["status + balance on the rail (#17940)"]
  RD2["plans on the rail (#17942)"]
  RD3["capabilities + payment methods on the rail (merged #17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB["first publish: three packages on next"]
  UIPUB["account-ui joins the release tables (#17989)"]
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> UIPUB
  PUB --> UIPUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style REACT stroke:#0366d6,stroke-width:4px
Loading

@dante01yoon
dante01yoon requested a review from a team as a code owner September 17, 2026 17:07
@vercel

vercel Bot commented Sep 17, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
billing-web Ignored Ignored Sep 17, 2026 5:07pm UTC

Request Review

@coderabbitai

coderabbitai Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 1f3153df-e000-4c6a-ba18-081b04a1e970

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

📦 Bundle Size

⏳ Size data collection in progress…

⚡ Performance Report

canvas-idle: · 60.0 avg FPS · 59.9 P5 FPS ✅ (target: ≥52) · 0ms TBT · 59.5 MB heap
canvas-mouse-sweep: · 60.0 avg FPS · 59.7 P5 FPS ✅ (target: ≥52) · 0ms TBT · 69.8 MB heap
canvas-zoom-sweep: · 60.0 avg FPS · 59.9 P5 FPS ✅ (target: ≥52) · 0ms TBT · 61.8 MB heap
dom-widget-clipping: · 60.0 avg FPS · 59.7 P5 FPS ✅ (target: ≥52) · 0ms TBT · 76.8 MB heap
large-graph-idle: · 60.0 avg FPS · 59.7 P5 FPS ✅ (target: ≥52) · 0ms TBT · 78.4 MB heap
large-graph-pan: · 60.0 avg FPS · 59.5 P5 FPS ✅ (target: ≥52) · 0ms TBT · 73.6 MB heap
large-graph-zoom: · 60.0 avg FPS · 59.7 P5 FPS ✅ (target: ≥52) · 0ms TBT · 79.2 MB heap
legacy-node-drag: · 60.0 avg FPS · 59.5 P5 FPS ✅ (target: ≥52) · 0ms TBT · 83.5 MB heap
minimap-idle: · 60.0 avg FPS · 59.7 P5 FPS ✅ (target: ≥52) · 0ms TBT · 75.8 MB heap
subgraph-dom-widget-clipping: · 60.0 avg FPS · 59.9 P5 FPS ✅ (target: ≥52) · 0ms TBT · 73.6 MB heap
subgraph-idle: · 60.0 avg FPS · 59.5 P5 FPS ✅ (target: ≥52) · 0ms TBT · 64.4 MB heap
subgraph-mouse-sweep: · 60.0 avg FPS · 59.9 P5 FPS ✅ (target: ≥52) · 0ms TBT · 68.4 MB heap
subgraph-transition-enter: · 60.0 avg FPS · 59.5 P5 FPS ✅ (target: ≥52) · 139ms TBT · 98.0 MB heap
viewport-pan-sweep: · 60.0 avg FPS · 59.7 P5 FPS ✅ (target: ≥52) · 0ms TBT · 74.4 MB heap
vue-large-graph-idle: · 56.2 avg FPS · 59.7 P5 FPS ✅ (target: ≥52) · 0ms TBT · 169.4 MB heap
vue-large-graph-pan: · 56.2 avg FPS · 59.9 P5 FPS ✅ (target: ≥52) · 73ms TBT · 182.0 MB heap
vue-node-resize-workload: · 55.4 avg FPS · 59.9 P5 FPS ✅ (target: ≥52) · 390ms TBT · 173.8 MB heap
vue-zoom-out-idle: · 57.1 avg FPS · 59.5 P5 FPS ✅ (target: ≥52) · 0ms TBT · 173.0 MB heap
workflow-execution: · 60.0 avg FPS · 59.7 P5 FPS ✅ (target: ≥52) · 0ms TBT · 63.3 MB heap

ℹ️ No baseline found — significance unavailable.

Absolute values
Metric Value
canvas-idle: avg frame time 17ms
canvas-idle: p95 frame time 17ms
canvas-idle: layout duration 0ms
canvas-idle: style recalc duration 7ms
canvas-idle: layout count 0
canvas-idle: style recalc count 8
canvas-idle: task duration 337ms
canvas-idle: script duration 8ms
canvas-idle: TBT 0ms
canvas-idle: heap used 59.5 MB
canvas-idle: DOM nodes -124
canvas-idle: event listeners -170
canvas-mouse-sweep: avg frame time 17ms
canvas-mouse-sweep: p95 frame time 17ms
canvas-mouse-sweep: layout duration 5ms
canvas-mouse-sweep: style recalc duration 33ms
canvas-mouse-sweep: layout count 14
canvas-mouse-sweep: style recalc count 78
canvas-mouse-sweep: task duration 930ms
canvas-mouse-sweep: script duration 174ms
canvas-mouse-sweep: TBT 0ms
canvas-mouse-sweep: heap used 69.8 MB
canvas-mouse-sweep: DOM nodes -262
canvas-mouse-sweep: event listeners -156
canvas-zoom-sweep: avg frame time 17ms
canvas-zoom-sweep: p95 frame time 17ms
canvas-zoom-sweep: layout duration 1ms
canvas-zoom-sweep: style recalc duration 15ms
canvas-zoom-sweep: layout count 6
canvas-zoom-sweep: style recalc count 31
canvas-zoom-sweep: task duration 286ms
canvas-zoom-sweep: script duration 10ms
canvas-zoom-sweep: TBT 0ms
canvas-zoom-sweep: heap used 61.8 MB
canvas-zoom-sweep: DOM nodes 76
canvas-zoom-sweep: event listeners 19
dom-widget-clipping: avg frame time 17ms
dom-widget-clipping: p95 frame time 17ms
dom-widget-clipping: layout duration 0ms
dom-widget-clipping: style recalc duration 8ms
dom-widget-clipping: layout count 0
dom-widget-clipping: style recalc count 12
dom-widget-clipping: task duration 433ms
dom-widget-clipping: script duration 159ms
dom-widget-clipping: TBT 0ms
dom-widget-clipping: heap used 76.8 MB
dom-widget-clipping: DOM nodes 19
dom-widget-clipping: event listeners 2
large-graph-idle: avg frame time 17ms
large-graph-idle: p95 frame time 17ms
large-graph-idle: layout duration 0ms
large-graph-idle: style recalc duration 7ms
large-graph-idle: layout count 0
large-graph-idle: style recalc count 7
large-graph-idle: task duration 561ms
large-graph-idle: script duration 32ms
large-graph-idle: TBT 0ms
large-graph-idle: heap used 78.4 MB
large-graph-idle: DOM nodes -249
large-graph-idle: event listeners -168
large-graph-pan: avg frame time 17ms
large-graph-pan: p95 frame time 17ms
large-graph-pan: layout duration 0ms
large-graph-pan: style recalc duration 11ms
large-graph-pan: layout count 0
large-graph-pan: style recalc count 66
large-graph-pan: task duration 1612ms
large-graph-pan: script duration 836ms
large-graph-pan: TBT 0ms
large-graph-pan: heap used 73.6 MB
large-graph-pan: DOM nodes -240
large-graph-pan: event listeners -88
large-graph-zoom: avg frame time 17ms
large-graph-zoom: p95 frame time 17ms
large-graph-zoom: layout duration 13ms
large-graph-zoom: style recalc duration 11ms
large-graph-zoom: layout count 60
large-graph-zoom: style recalc count 62
large-graph-zoom: task duration 1563ms
large-graph-zoom: script duration 767ms
large-graph-zoom: TBT 0ms
large-graph-zoom: heap used 79.2 MB
large-graph-zoom: DOM nodes 4
large-graph-zoom: event listeners 9
legacy-node-drag: avg frame time 17ms
legacy-node-drag: p95 frame time 17ms
legacy-node-drag: layout duration 0ms
legacy-node-drag: style recalc duration 8ms
legacy-node-drag: layout count 0
legacy-node-drag: style recalc count 42
legacy-node-drag: task duration 1927ms
legacy-node-drag: script duration 1019ms
legacy-node-drag: TBT 0ms
legacy-node-drag: heap used 83.5 MB
legacy-node-drag: DOM nodes -260
legacy-node-drag: event listeners 94
minimap-idle: avg frame time 17ms
minimap-idle: p95 frame time 17ms
minimap-idle: layout duration 0ms
minimap-idle: style recalc duration 4ms
minimap-idle: layout count 0
minimap-idle: style recalc count 5
minimap-idle: task duration 543ms
minimap-idle: script duration 30ms
minimap-idle: TBT 0ms
minimap-idle: heap used 75.8 MB
minimap-idle: DOM nodes -260
minimap-idle: event listeners -169
subgraph-dom-widget-clipping: avg frame time 17ms
subgraph-dom-widget-clipping: p95 frame time 17ms
subgraph-dom-widget-clipping: layout duration 0ms
subgraph-dom-widget-clipping: style recalc duration 11ms
subgraph-dom-widget-clipping: layout count 0
subgraph-dom-widget-clipping: style recalc count 48
subgraph-dom-widget-clipping: task duration 391ms
subgraph-dom-widget-clipping: script duration 141ms
subgraph-dom-widget-clipping: TBT 0ms
subgraph-dom-widget-clipping: heap used 73.6 MB
subgraph-dom-widget-clipping: DOM nodes 21
subgraph-dom-widget-clipping: event listeners 8
subgraph-idle: avg frame time 17ms
subgraph-idle: p95 frame time 17ms
subgraph-idle: layout duration 0ms
subgraph-idle: style recalc duration 8ms
subgraph-idle: layout count 0
subgraph-idle: style recalc count 11
subgraph-idle: task duration 436ms
subgraph-idle: script duration 7ms
subgraph-idle: TBT 0ms
subgraph-idle: heap used 64.4 MB
subgraph-idle: DOM nodes -274
subgraph-idle: event listeners -200
subgraph-mouse-sweep: avg frame time 17ms
subgraph-mouse-sweep: p95 frame time 17ms
subgraph-mouse-sweep: layout duration 5ms
subgraph-mouse-sweep: style recalc duration 26ms
subgraph-mouse-sweep: layout count 18
subgraph-mouse-sweep: style recalc count 77
subgraph-mouse-sweep: task duration 760ms
subgraph-mouse-sweep: script duration 105ms
subgraph-mouse-sweep: TBT 0ms
subgraph-mouse-sweep: heap used 68.4 MB
subgraph-mouse-sweep: DOM nodes -277
subgraph-mouse-sweep: event listeners -202
subgraph-transition-enter: avg frame time 17ms
subgraph-transition-enter: p95 frame time 17ms
subgraph-transition-enter: layout duration 13ms
subgraph-transition-enter: style recalc duration 28ms
subgraph-transition-enter: layout count 5
subgraph-transition-enter: style recalc count 18
subgraph-transition-enter: task duration 864ms
subgraph-transition-enter: script duration 28ms
subgraph-transition-enter: TBT 139ms
subgraph-transition-enter: heap used 98.0 MB
subgraph-transition-enter: DOM nodes 13587
subgraph-transition-enter: event listeners 2387
viewport-pan-sweep: avg frame time 17ms
viewport-pan-sweep: p95 frame time 17ms
viewport-pan-sweep: layout duration 0ms
viewport-pan-sweep: style recalc duration 34ms
viewport-pan-sweep: layout count 0
viewport-pan-sweep: style recalc count 248
viewport-pan-sweep: task duration 5610ms
viewport-pan-sweep: script duration 2710ms
viewport-pan-sweep: TBT 0ms
viewport-pan-sweep: heap used 74.4 MB
viewport-pan-sweep: DOM nodes -247
viewport-pan-sweep: event listeners -153
vue-large-graph-idle: avg frame time 18ms
vue-large-graph-idle: p95 frame time 17ms
vue-large-graph-idle: layout duration 0ms
vue-large-graph-idle: style recalc duration 0ms
vue-large-graph-idle: layout count 0
vue-large-graph-idle: style recalc count 0
vue-large-graph-idle: task duration 16286ms
vue-large-graph-idle: script duration 254ms
vue-large-graph-idle: TBT 0ms
vue-large-graph-idle: heap used 169.4 MB
vue-large-graph-idle: DOM nodes -8061
vue-large-graph-idle: event listeners -14925
vue-large-graph-pan: avg frame time 18ms
vue-large-graph-pan: p95 frame time 17ms
vue-large-graph-pan: layout duration 0ms
vue-large-graph-pan: style recalc duration 16ms
vue-large-graph-pan: layout count 0
vue-large-graph-pan: style recalc count 170
vue-large-graph-pan: task duration 19791ms
vue-large-graph-pan: script duration 865ms
vue-large-graph-pan: TBT 73ms
vue-large-graph-pan: heap used 182.0 MB
vue-large-graph-pan: DOM nodes -8061
vue-large-graph-pan: event listeners -14921
vue-node-resize-workload: avg frame time 18ms
vue-node-resize-workload: p95 frame time 17ms
vue-node-resize-workload: layout duration 22ms
vue-node-resize-workload: style recalc duration 76ms
vue-node-resize-workload: layout count 20
vue-node-resize-workload: style recalc count 20
vue-node-resize-workload: task duration 6004ms
vue-node-resize-workload: script duration 105ms
vue-node-resize-workload: TBT 390ms
vue-node-resize-workload: heap used 173.8 MB
vue-node-resize-workload: DOM nodes -8061
vue-node-resize-workload: event listeners -14923
vue-zoom-out-idle: avg frame time 18ms
vue-zoom-out-idle: p95 frame time 17ms
vue-zoom-out-idle: layout duration 0ms
vue-zoom-out-idle: style recalc duration 0ms
vue-zoom-out-idle: layout count 0
vue-zoom-out-idle: style recalc count 0
vue-zoom-out-idle: task duration 8171ms
vue-zoom-out-idle: script duration 144ms
vue-zoom-out-idle: TBT 0ms
vue-zoom-out-idle: heap used 173.0 MB
vue-zoom-out-idle: DOM nodes -1
vue-zoom-out-idle: event listeners -10
workflow-execution: avg frame time 17ms
workflow-execution: p95 frame time 17ms
workflow-execution: layout duration 2ms
workflow-execution: style recalc duration 25ms
workflow-execution: layout count 4
workflow-execution: style recalc count 17
workflow-execution: task duration 116ms
workflow-execution: script duration 13ms
workflow-execution: TBT 0ms
workflow-execution: heap used 63.3 MB
workflow-execution: DOM nodes 142
workflow-execution: event listeners 50
Raw data
{
  "timestamp": "2026-09-18T10:29:09.124Z",
  "gitSha": "e7cd975b34acaa95c08f7e400272469540d0c5b6",
  "branch": "fe-2331-billing-web-reactivation-confirm",
  "measurements": [
    {
      "name": "canvas-idle",
      "durationMs": 2013.3650000000216,
      "styleRecalcs": 8,
      "styleRecalcDurationMs": 6.990999999999999,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 332.058,
      "heapDeltaBytes": 8241816,
      "heapUsedBytes": 69579016,
      "domNodes": -263,
      "jsHeapTotalBytes": 4448256,
      "scriptDurationMs": 7.7780000000000005,
      "eventListeners": -154,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.66999999999998,
      "p95FrameDurationMs": 16.699999999999818
    },
    {
      "name": "canvas-idle",
      "durationMs": 2001.8460000000005,
      "styleRecalcs": 8,
      "styleRecalcDurationMs": 7.367,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 342.9409999999999,
      "heapDeltaBytes": -7386992,
      "heapUsedBytes": 55264792,
      "domNodes": 16,
      "jsHeapTotalBytes": 4448256,
      "scriptDurationMs": 8.039000000000001,
      "eventListeners": -186,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.699999999999818
    },
    {
      "name": "canvas-mouse-sweep",
      "durationMs": 2059.0559999999414,
      "styleRecalcs": 81,
      "styleRecalcDurationMs": 36.756,
      "layouts": 14,
      "layoutDurationMs": 5.217,
      "taskDurationMs": 1021.5770000000002,
      "heapDeltaBytes": 15825860,
      "heapUsedBytes": 78271096,
      "domNodes": -263,
      "jsHeapTotalBytes": 5758976,
      "scriptDurationMs": 184.455,
      "eventListeners": -156,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "canvas-mouse-sweep",
      "durationMs": 1840.806999999927,
      "styleRecalcs": 75,
      "styleRecalcDurationMs": 29.046000000000003,
      "layouts": 14,
      "layoutDurationMs": 4.468,
      "taskDurationMs": 837.828,
      "heapDeltaBytes": 5512588,
      "heapUsedBytes": 68177996,
      "domNodes": -260,
      "jsHeapTotalBytes": 5758976,
      "scriptDurationMs": 163.80899999999997,
      "eventListeners": -156,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.699999999999818
    },
    {
      "name": "canvas-zoom-sweep",
      "durationMs": 1706.9029999998975,
      "styleRecalcs": 30,
      "styleRecalcDurationMs": 15.196,
      "layouts": 6,
      "layoutDurationMs": 1.0569999999999997,
      "taskDurationMs": 247.125,
      "heapDeltaBytes": 2053712,
      "heapUsedBytes": 64913452,
      "domNodes": 76,
      "jsHeapTotalBytes": 5242880,
      "scriptDurationMs": 10.318000000000001,
      "eventListeners": 19,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "canvas-zoom-sweep",
      "durationMs": 1665.4110000000628,
      "styleRecalcs": 31,
      "styleRecalcDurationMs": 14.525000000000002,
      "layouts": 6,
      "layoutDurationMs": 1.017,
      "taskDurationMs": 324.755,
      "heapDeltaBytes": 2167908,
      "heapUsedBytes": 64617556,
      "domNodes": 76,
      "jsHeapTotalBytes": 4718592,
      "scriptDurationMs": 10.530000000000001,
      "eventListeners": 19,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "dom-widget-clipping",
      "durationMs": 634.4360000000506,
      "styleRecalcs": 11,
      "styleRecalcDurationMs": 7.261999999999998,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 445.00900000000007,
      "heapDeltaBytes": 17874968,
      "heapUsedBytes": 80541072,
      "domNodes": 18,
      "jsHeapTotalBytes": 6029312,
      "scriptDurationMs": 161.797,
      "eventListeners": 2,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.699999999999818
    },
    {
      "name": "dom-widget-clipping",
      "durationMs": 608.3139999999503,
      "styleRecalcs": 12,
      "styleRecalcDurationMs": 7.931000000000001,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 421.60800000000006,
      "heapDeltaBytes": 17822072,
      "heapUsedBytes": 80489300,
      "domNodes": 20,
      "jsHeapTotalBytes": 5505024,
      "scriptDurationMs": 155.902,
      "eventListeners": 2,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.800000000000182
    },
    {
      "name": "large-graph-idle",
      "durationMs": 2032.055000000014,
      "styleRecalcs": 5,
      "styleRecalcDurationMs": 5.052000000000001,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 544.3889999999999,
      "heapDeltaBytes": 3609596,
      "heapUsedBytes": 84102264,
      "domNodes": -248,
      "jsHeapTotalBytes": -794624,
      "scriptDurationMs": 31.521999999999995,
      "eventListeners": -154,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.66333333333335,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "large-graph-idle",
      "durationMs": 2056.4410000000635,
      "styleRecalcs": 8,
      "styleRecalcDurationMs": 8.434000000000001,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 578.0160000000001,
      "heapDeltaBytes": -401620,
      "heapUsedBytes": 80278516,
      "domNodes": -249,
      "jsHeapTotalBytes": 778240,
      "scriptDurationMs": 32.30699999999999,
      "eventListeners": -182,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.800000000000182
    },
    {
      "name": "large-graph-pan",
      "durationMs": 2240.3759999999693,
      "styleRecalcs": 67,
      "styleRecalcDurationMs": 11.744000000000002,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 1626.9199999999996,
      "heapDeltaBytes": -5910832,
      "heapUsedBytes": 75145772,
      "domNodes": -225,
      "jsHeapTotalBytes": 1527808,
      "scriptDurationMs": 840.488,
      "eventListeners": -182,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.800000000000182
    },
    {
      "name": "large-graph-pan",
      "durationMs": 2208.8309999999183,
      "styleRecalcs": 64,
      "styleRecalcDurationMs": 9.318000000000003,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 1596.266,
      "heapDeltaBytes": 14421412,
      "heapUsedBytes": 79211176,
      "domNodes": -255,
      "jsHeapTotalBytes": 225280,
      "scriptDurationMs": 830.9089999999999,
      "eventListeners": 6,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.800000000000182
    },
    {
      "name": "large-graph-zoom",
      "durationMs": 3492.982999999981,
      "styleRecalcs": 61,
      "styleRecalcDurationMs": 10.069,
      "layouts": 60,
      "layoutDurationMs": 12.717,
      "taskDurationMs": 1632.6069999999997,
      "heapDeltaBytes": 8405540,
      "heapUsedBytes": 74879812,
      "domNodes": 2,
      "jsHeapTotalBytes": 524288,
      "scriptDurationMs": 768.2150000000001,
      "eventListeners": 10,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "large-graph-zoom",
      "durationMs": 3439.348999999993,
      "styleRecalcs": 62,
      "styleRecalcDurationMs": 11.571000000000002,
      "layouts": 60,
      "layoutDurationMs": 13.036000000000001,
      "taskDurationMs": 1493.7700000000002,
      "heapDeltaBytes": 8481596,
      "heapUsedBytes": 91312484,
      "domNodes": 6,
      "jsHeapTotalBytes": 4456448,
      "scriptDurationMs": 765.4669999999999,
      "eventListeners": 8,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "legacy-node-drag",
      "durationMs": 3171.026999999981,
      "styleRecalcs": 41,
      "styleRecalcDurationMs": 5.531999999999999,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 1924.172,
      "heapDeltaBytes": 25905464,
      "heapUsedBytes": 91870692,
      "domNodes": -255,
      "jsHeapTotalBytes": 942080,
      "scriptDurationMs": 1030.6709999999998,
      "eventListeners": 188,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.670000000000012,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "legacy-node-drag",
      "durationMs": 3060.3250000000344,
      "styleRecalcs": 43,
      "styleRecalcDurationMs": 9.902999999999999,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 1929.507,
      "heapDeltaBytes": -674564,
      "heapUsedBytes": 83304356,
      "domNodes": -264,
      "jsHeapTotalBytes": 1720320,
      "scriptDurationMs": 1006.7520000000001,
      "eventListeners": 0,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666696,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "minimap-idle",
      "durationMs": 2018.036000000052,
      "styleRecalcs": 4,
      "styleRecalcDurationMs": 3.1499999999999964,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 517.018,
      "heapDeltaBytes": -4057172,
      "heapUsedBytes": 83934492,
      "domNodes": -255,
      "jsHeapTotalBytes": -1544192,
      "scriptDurationMs": 28.873999999999995,
      "eventListeners": -154,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.800000000000182
    },
    {
      "name": "minimap-idle",
      "durationMs": 2011.737999999923,
      "styleRecalcs": 6,
      "styleRecalcDurationMs": 5.493000000000001,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 568.2570000000001,
      "heapDeltaBytes": -13359416,
      "heapUsedBytes": 75133868,
      "domNodes": -265,
      "jsHeapTotalBytes": 290816,
      "scriptDurationMs": 30.533000000000005,
      "eventListeners": -184,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "subgraph-dom-widget-clipping",
      "durationMs": 591.9119999999793,
      "styleRecalcs": 46,
      "styleRecalcDurationMs": 9.469,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 390.2559999999999,
      "heapDeltaBytes": 13498324,
      "heapUsedBytes": 77020216,
      "domNodes": 18,
      "jsHeapTotalBytes": 5767168,
      "scriptDurationMs": 142.799,
      "eventListeners": 8,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.66333333333335,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "subgraph-dom-widget-clipping",
      "durationMs": 559.8700000000463,
      "styleRecalcs": 49,
      "styleRecalcDurationMs": 11.9,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 391.182,
      "heapDeltaBytes": 13632240,
      "heapUsedBytes": 77246780,
      "domNodes": 24,
      "jsHeapTotalBytes": 5242880,
      "scriptDurationMs": 138.975,
      "eventListeners": 8,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "subgraph-idle",
      "durationMs": 2017.9160000000138,
      "styleRecalcs": 11,
      "styleRecalcDurationMs": 8.693000000000001,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 435.747,
      "heapDeltaBytes": 5030088,
      "heapUsedBytes": 68895908,
      "domNodes": -273,
      "jsHeapTotalBytes": 5234688,
      "scriptDurationMs": 6.8020000000000005,
      "eventListeners": -200,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.66333333333332,
      "p95FrameDurationMs": 16.800000000000182
    },
    {
      "name": "subgraph-idle",
      "durationMs": 2006.1660000000074,
      "styleRecalcs": 10,
      "styleRecalcDurationMs": 7.508999999999999,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 436.792,
      "heapDeltaBytes": 2264112,
      "heapUsedBytes": 66129332,
      "domNodes": -274,
      "jsHeapTotalBytes": 4972544,
      "scriptDurationMs": 7.1229999999999976,
      "eventListeners": -200,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.66333333333332,
      "p95FrameDurationMs": 16.800000000000182
    },
    {
      "name": "subgraph-mouse-sweep",
      "durationMs": 1718.1880000000547,
      "styleRecalcs": 77,
      "styleRecalcDurationMs": 25.823999999999998,
      "layouts": 18,
      "layoutDurationMs": 4.9399999999999995,
      "taskDurationMs": 749.878,
      "heapDeltaBytes": 9503296,
      "heapUsedBytes": 73305768,
      "domNodes": -277,
      "jsHeapTotalBytes": 6021120,
      "scriptDurationMs": 103.087,
      "eventListeners": -202,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "subgraph-mouse-sweep",
      "durationMs": 1708.641000000057,
      "styleRecalcs": 77,
      "styleRecalcDurationMs": 26.17,
      "layouts": 18,
      "layoutDurationMs": 5.1579999999999995,
      "taskDurationMs": 769.486,
      "heapDeltaBytes": 6469096,
      "heapUsedBytes": 70097144,
      "domNodes": -276,
      "jsHeapTotalBytes": 6021120,
      "scriptDurationMs": 107.363,
      "eventListeners": -202,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.66333333333335,
      "p95FrameDurationMs": 16.699999999999818
    },
    {
      "name": "subgraph-transition-enter",
      "durationMs": 1367.1850000000632,
      "styleRecalcs": 18,
      "styleRecalcDurationMs": 27.843,
      "layouts": 5,
      "layoutDurationMs": 12.723999999999998,
      "taskDurationMs": 864.4889999999998,
      "heapDeltaBytes": 20081528,
      "heapUsedBytes": 102751180,
      "domNodes": 13587,
      "jsHeapTotalBytes": 10747904,
      "scriptDurationMs": 28.38600000000001,
      "eventListeners": 2387,
      "totalBlockingTimeMs": 139,
      "frameDurationMs": 16.666666666666636,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "viewport-pan-sweep",
      "durationMs": 8273.357999999917,
      "styleRecalcs": 248,
      "styleRecalcDurationMs": 33.63099999999999,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 5613.074,
      "heapDeltaBytes": -24160,
      "heapUsedBytes": 79952640,
      "domNodes": -249,
      "jsHeapTotalBytes": -831488,
      "scriptDurationMs": 2699.7960000000003,
      "eventListeners": -168,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "viewport-pan-sweep",
      "durationMs": 8318.253000000026,
      "styleRecalcs": 248,
      "styleRecalcDurationMs": 34.82299999999999,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 5607.790000000001,
      "heapDeltaBytes": -4114296,
      "heapUsedBytes": 75987004,
      "domNodes": -245,
      "jsHeapTotalBytes": 217088,
      "scriptDurationMs": 2719.9460000000004,
      "eventListeners": -138,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.670000000000012,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "vue-large-graph-idle",
      "durationMs": 16832.475000000046,
      "styleRecalcs": 0,
      "styleRecalcDurationMs": 0,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 16322.195000000002,
      "heapDeltaBytes": -58165956,
      "heapUsedBytes": 165219696,
      "domNodes": -8061,
      "jsHeapTotalBytes": -14094336,
      "scriptDurationMs": 252.55300000000003,
      "eventListeners": -14926,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 17.780000000000047,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "vue-large-graph-idle",
      "durationMs": 16748.751000000084,
      "styleRecalcs": 0,
      "styleRecalcDurationMs": 0,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 16249.383000000002,
      "heapDeltaBytes": -25169204,
      "heapUsedBytes": 190072620,
      "domNodes": -8061,
      "jsHeapTotalBytes": -14163968,
      "scriptDurationMs": 255.87699999999995,
      "eventListeners": -14924,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 17.780000000000047,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "vue-large-graph-pan",
      "durationMs": 20297.538999999917,
      "styleRecalcs": 167,
      "styleRecalcDurationMs": 16.315999999999995,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 19881.622999999996,
      "heapDeltaBytes": -19742176,
      "heapUsedBytes": 190670408,
      "domNodes": -8061,
      "jsHeapTotalBytes": -10874880,
      "scriptDurationMs": 875.119,
      "eventListeners": -14920,
      "totalBlockingTimeMs": 22,
      "frameDurationMs": 17.776666666666642,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "vue-large-graph-pan",
      "durationMs": 20036.969999999885,
      "styleRecalcs": 172,
      "styleRecalcDurationMs": 16.155999999999977,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 19700.644999999997,
      "heapDeltaBytes": -39950824,
      "heapUsedBytes": 190914276,
      "domNodes": -8061,
      "jsHeapTotalBytes": -11935744,
      "scriptDurationMs": 855.001,
      "eventListeners": -14922,
      "totalBlockingTimeMs": 123,
      "frameDurationMs": 17.780000000000047,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "vue-node-resize-workload",
      "durationMs": 6110.326999999984,
      "styleRecalcs": 20,
      "styleRecalcDurationMs": 75.88999999999999,
      "layouts": 20,
      "layoutDurationMs": 22.118,
      "taskDurationMs": 5992.96,
      "heapDeltaBytes": -31611124,
      "heapUsedBytes": 182090588,
      "domNodes": -8061,
      "jsHeapTotalBytes": 13963264,
      "scriptDurationMs": 105.67500000000001,
      "eventListeners": -14922,
      "totalBlockingTimeMs": 405,
      "frameDurationMs": 17.776666666666642,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "vue-node-resize-workload",
      "durationMs": 6094.370000000026,
      "styleRecalcs": 20,
      "styleRecalcDurationMs": 76.66600000000001,
      "layouts": 20,
      "layoutDurationMs": 22.663000000000004,
      "taskDurationMs": 6014.745000000001,
      "heapDeltaBytes": -48898560,
      "heapUsedBytes": 182484684,
      "domNodes": -8061,
      "jsHeapTotalBytes": 16457728,
      "scriptDurationMs": 103.54900000000002,
      "eventListeners": -14924,
      "totalBlockingTimeMs": 374,
      "frameDurationMs": 18.333333333333332,
      "p95FrameDurationMs": 16.700000000000728
    },
    {
      "name": "vue-zoom-out-idle",
      "durationMs": 8400.240000000053,
      "styleRecalcs": 0,
      "styleRecalcDurationMs": 0,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 8172.229000000001,
      "heapDeltaBytes": -12236184,
      "heapUsedBytes": 171384972,
      "domNodes": -1,
      "jsHeapTotalBytes": -10485760,
      "scriptDurationMs": 147.11000000000007,
      "eventListeners": -10,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 17.776666666666642,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "vue-zoom-out-idle",
      "durationMs": 8411.967999999888,
      "styleRecalcs": 0,
      "styleRecalcDurationMs": 0,
      "layouts": 0,
      "layoutDurationMs": 0,
      "taskDurationMs": 8169.467999999998,
      "heapDeltaBytes": 12430140,
      "heapUsedBytes": 191479688,
      "domNodes": 0,
      "jsHeapTotalBytes": -12320768,
      "scriptDurationMs": 140.39599999999996,
      "eventListeners": -10,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 17.223333333333358,
      "p95FrameDurationMs": 16.799999999999272
    },
    {
      "name": "workflow-execution",
      "durationMs": 500.42099999996026,
      "styleRecalcs": 24,
      "styleRecalcDurationMs": 33.126000000000005,
      "layouts": 6,
      "layoutDurationMs": 2.7779999999999996,
      "taskDurationMs": 155.30800000000002,
      "heapDeltaBytes": 5374232,
      "heapUsedBytes": 67544768,
      "domNodes": 155,
      "jsHeapTotalBytes": 262144,
      "scriptDurationMs": 18.956999999999994,
      "eventListeners": 83,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.699999999999818
    },
    {
      "name": "workflow-execution",
      "durationMs": 109.97100000008686,
      "styleRecalcs": 9,
      "styleRecalcDurationMs": 16.132,
      "layouts": 2,
      "layoutDurationMs": 1.2879999999999998,
      "taskDurationMs": 76.85899999999998,
      "heapDeltaBytes": 3000708,
      "heapUsedBytes": 65155948,
      "domNodes": 128,
      "jsHeapTotalBytes": 0,
      "scriptDurationMs": 6.479,
      "eventListeners": 17,
      "totalBlockingTimeMs": 0,
      "frameDurationMs": 16.666666666666668,
      "p95FrameDurationMs": 16.800000000000182
    }
  ]
}

🔬 E2E Coverage

Metric Covered Total Pct
Lines 51395 78051 65.8% 🟡
Functions 0 0 — —
Branches 0 0 — —
Top 10 files by uncovered lines
File Coverage Missed
src/LGraphCanvas.ts 67.8% 1155
src/LGraphNode.ts 70.4% 382
src/extensions/core/cameraInfo/CameraInfoViewport.ts 2.5% 344
src/renderer/extensions/layerEditor/composables/useLayerEditorSession.ts 40.1% 332
src/platform/workspace/stores/workspaceAuthStore.ts 33.7% 323
src/platform/workspace/stores/billingOperationStore.ts 7.9% 316
src/LGraph.ts 79.3% 261
src/platform/workspace/stores/teamWorkspaceStore.ts 38.9% 256
src/scripts/app.ts 72.2% 255
src/core/billing/operationLifecycle.ts 0.9% 232

🎨 Storybook: ✅ Built — View Storybook

Details

⏰ Completed at: 09/18/2026, 10:19:18 AM UTC

Links

🌐 Website E2E

Tip

All tests passed.

Status ✅ Passed
Report View Report

🎭 Playwright: ✅ 2039 passed, 0 failed · 1 flaky

📊 Browser Reports
  • chromium: View Report (✅ 2018 / ❌ 0 / ⚠️ 1 / ⏭️ 13)
  • chromium-2x: View Report (✅ 2 / ❌ 0 / ⚠️ 0 / ⏭️ 0)
  • chromium-0.5x: View Report (✅ 1 / ❌ 0 / ⚠️ 0 / ⏭️ 0)
  • mobile-chrome: View Report (✅ 18 / ❌ 0 / ⚠️ 0 / ⏭️ 0)

@codecov

codecov Bot commented Sep 17, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 91.66667% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
apps/billing-web/src/views/CheckoutView.vue 88.88% 0 Missing and 2 partials ⚠️
@@                             Coverage Diff                              @@
##           fe-2331-billing-web-subscription-actions   #17943      +/-   ##
============================================================================
- Coverage                                     83.73%   82.72%   -1.01%     
============================================================================
  Files                                          2267     2931     +664     
  Lines                                        128080   144317   +16237     
  Branches                                      34438    37104    +2666     
============================================================================
+ Hits                                         107245   119389   +12144     
- Misses                                        20503    23667    +3164     
- Partials                                        332     1261     +929     
Flag Coverage Δ
billing-web-unit 78.88% <91.66%> (+1.05%) ⬆️
e2e 65.84% <ø> (-0.01%) ⬇️
unit 79.07% <ø> (ø)
website-unit 74.74% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
apps/billing-web/src/components/CheckoutSubmit.vue 100.00% <100.00%> (ø)
apps/billing-web/src/views/CheckoutView.vue 86.20% <88.88%> (+5.38%) ⬆️

... and 668 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions github-actions Bot added the risk:xhigh PR risk grade (advisory shadow check; grader-owned) label Sep 17, 2026
pull Bot pushed a commit to Penguinjanator/ComfyUI_frontend that referenced this pull request Sep 17, 2026
…y and deny framing (Comfy-Org#17941)

Linear FE-2218. Based on `main`; independent of the billing-web feature
stack. Closes the "CSP" half of the last open line in the hosted-billing
TDD's *Can start immediately* list.

## Why

Comfy-Org#17788 gave `apps/billing-web` `noindex`, `nosniff` and a referrer
policy, and left CSP open. This is a payment surface that loads three
third parties — Stripe, Cloudflare Turnstile and Firebase — and talks to
one of three Cloud origins; nothing today says which origins it may load
from or connect to, so a compromised dependency or an injected script
has the whole web to reach.

## How

**Report-only first, on purpose.** The header ships as
`Content-Security-Policy-Report-Only`. A violation is logged in the
console and blocks nothing. The alternative — enforcing on the first try
— fails in exactly the way that is worst here: a missing origin does not
error, it makes a card form not mount or a 3DS frame not open, which
reads to the customer as "payment is broken". The README states the
promotion criterion: a preview that completes email and Google sign-in,
a card checkout with a 3DS challenge, and a portal round-trip with a
clean console. The console's report on that pass is the list of origins
to add.

**The allowlist is what the app actually loads**, not a template:

| Directive | Origins | For |
| --- | --- | --- |
| `script-src` | `js.stripe.com`, `challenges.cloudflare.com`,
`apis.google.com` | Stripe.js (`@stripe/stripe-js` injects it),
Turnstile, the Firebase popup sign-in helper |
| `connect-src` | `cloud.comfy.org`, `stagingcloud.comfy.org`,
`testcloud.comfy.org`, `api.stripe.com`,
`identitytoolkit.googleapis.com`, `securetoken.googleapis.com`,
`dreamboothy.firebaseapp.com`, `dreamboothy-dev.firebaseapp.com` |
billing reads and commands (all three families, since `vercel.json` is
one file), Elements, sign-in and token refresh |
| `frame-src` | `js.stripe.com`, `hooks.stripe.com`,
`challenges.cloudflare.com`, `dreamboothy.firebaseapp.com`,
`dreamboothy-dev.firebaseapp.com`, `apis.google.com` | Elements, the 3DS
challenge, Turnstile, the Firebase auth iframe (`signInWithPopup` — the
package never uses the redirect flow) |
| `style-src` | `'self' 'unsafe-inline'` | Vue-managed inline styles |
| `img-src` | `'self' data: https://*.stripe.com` | Stripe card-brand
art |
| `default-src`, `base-uri`, `form-action` | `'self'` | |
| `object-src` | `'none'` | |
| `frame-ancestors` | `'none'` | see below |

**`X-Frame-Options: DENY` is enforced, not report-only.** Billing is
opened as its own tab (`openDisownedTab` in the cloud app) and is never
embedded; there is no consumer to break and clickjacking a checkout is
the attack the header exists for. `frame-ancestors 'none'` says the same
thing in the CSP for browsers that prefer it.

## Review focus

**The two Firebase auth domains.** `signInWithPopup` loads the gapi
helper from `apis.google.com` and mounts the auth iframe on the
project's `authDomain`. The three Cloud families report two projects in
`/api/features`: `dreamboothy` for production and `dreamboothy-dev` for
staging and test, so both auth domains are listed rather than
`*.firebaseapp.com`, which would admit every Firebase project. A
deployment pointed at another project adds its domain to `connect-src`
and `frame-src`; the README says so.

**No reporting endpoint, on purpose.** The header carries no
`report-to`: this origin has no server to receive reports, so violations
are visible only in a console with devtools open. That is the stated
scope of the report-only phase, which is verified by hand on previews
per the README's promotion criterion. After promotion a production
violation is invisible until an endpoint exists, and adding one is the
first change to make when it does.

**`www.googleapis.com` is not listed.** `@firebase/auth` 1.10.8 contacts
`identitytoolkit.googleapis.com`, `securetoken.googleapis.com`,
`apis.google.com/js/api.js` and the auth domain's `/__/auth/*` paths,
and nothing else; the host was in an earlier revision defensively and is
out.

**Browser tests are not in this PR.** `browser_tests/` is the cloud
app's harness (`comfyPage`, its backend fixtures); `apps/billing-web`
has no Playwright project yet. A mock-driven harness for it is its own
piece of work and waits on Comfy-Org#17936, which gives it a checkout to drive.

## Verification

`vercel.json` parses; `oxfmt` clean. No runtime code changed, so no unit
tests are affected. The header is verified on a Vercel preview, which is
what report-only is for.

## AS IS / TO BE

- **AS IS** — no CSP, no framing protection; the app may load from and
connect to any origin.
- **TO BE** — framing denied; every third-party origin named and
reported against, with a stated path to enforcement.

No user-visible change.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | approved
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 | open
(Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | open
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | open (Comfy-Org#17932) |
| 7 | **billing-web report-only CSP and framing denial** | FE-2218 |
**this PR** |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| open (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | open (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | open (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
open (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 | after
Comfy-Org#17881 merges |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (Comfy-Org#17952)"]
  UIB["account-ui dist build (Comfy-Org#17929)"]
  DEPS["drop unpublished deps (Comfy-Org#17932)"]
  CSP["billing-web CSP (Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish, after Comfy-Org#17881"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style CSP stroke:#0366d6,stroke-width:4px
```
@dante01yoon
dante01yoon force-pushed the fe-2331-billing-web-subscription-actions branch from 3a2b410 to 9efe52f Compare September 17, 2026 22:15
@dante01yoon
dante01yoon force-pushed the fe-2331-billing-web-reactivation-confirm branch from 9f081ec to 8638fe6 Compare September 17, 2026 22:15
pull Bot pushed a commit to Mu-L/ComfyUI_frontend that referenced this pull request Sep 17, 2026
…sumer instead of the pull_request job (Comfy-Org#17952)

Linear FE-2218. Stacked on Comfy-Org#17881; the direction ShihChi chose on its
review thread (option 2, "the real split"), built as the follow-up that
thread proposed.

## Why

`publish-package-on-merge.yaml` runs on `pull_request: closed`, and its
`comment_package_publish` job carried `pull-requests: write` and
`issues: write` to post the release links onto the Release PR.
`.github/AGENTS.md` says never to write PR comments from a
`pull_request` workflow: that trigger runs the workflow definition from
the pull request's own merge ref, so a job with write permission is
PR-authored code holding a write token. The job was gated on `merged ==
true` and the in-repo `Release` label, which a fork cannot acquire, but
the rule exists so that the next reader does not have to re-derive that
argument, and the review asked for the split rather than the exception.

## How

The two-workflow split the repository already uses for size, perf and
e2e reports:

- **Producer** (`publish-package-on-merge.yaml`):
`comment_package_publish` is replaced by `publish_report`, which holds
`contents: read` only. It writes the release links — one npm link per
published package, from the resolve job's matrix, plus the merge commit
— and the PR number into a `publish-report` artifact. `pull-requests:
write` and `issues: write` are gone from the workflow.
- **Consumer** (`pr-publish-report.yaml`, new): `workflow_run` on the
on-merge publish, so it runs the default branch's definition. On a
successful run it downloads the artifact from the triggering run, reads
the PR number, and upserts the `release` section of the unified PR
report through `.github/actions/upsert-comment-section`, the same
section and marker the old job wrote. A run that found no version change
uploads nothing and the consumer skips.

The report body is built with `jq` from the matrix rather than
`comment-release-links`, because that action reads the previous version
from `HEAD^1` and formats a `v…v` compare link that suits the root
package and the design system; a package publish has no such tag and its
useful link is the npm version page.

ADR-0033's workflow table gains the consumer row and says the on-merge
job writes the links to an artifact.

## Verification

Both workflow files parse; `oxfmt` clean. The consumer's download step
and the report format were checked by hand (`jq` dry run on a one-entry
matrix). The path runs only on a merged Release PR, so the first live
check is the first package release after this lands: the `release`
section on that PR should carry the npm links, written by `PR: Publish
Report` rather than the publish workflow.

## AS IS / TO BE

No user-visible change.

- **AS IS** — the `pull_request`-triggered publish workflow posts the
release links itself, holding `pull-requests: write`.
- **TO BE** — the publish workflow only reads; a `workflow_run` consumer
on the default branch posts the links.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | **Publish report through a `workflow_run` consumer** | FE-2218 |
**this PR** |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | open
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | open (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| open (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | open (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | open (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
open (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 |
unblocked: Comfy-Org#17881 is on main |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (Comfy-Org#17952)"]
  UIB["account-ui dist build (Comfy-Org#17929)"]
  DEPS["drop unpublished deps (Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish: workflows are on main, awaiting go"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style PUBREP stroke:#0366d6,stroke-width:4px
```
pull Bot pushed a commit to Mu-L/ComfyUI_frontend that referenced this pull request Sep 17, 2026
…s publishable (Comfy-Org#17929)

Linear FE-2218. Depends on the boundary recorded in Comfy-Org#17927.

## Why

`@comfyorg/account-ui` is the package Platform installs, and it is the
only
workspace package that ships Vue. Comfy-Org#17882 made `account-core`,
`billing-contract` and `ingest-types` publishable; `account-ui` was left
out,
and Comfy-Org#17881 says so in a comment on its own version gate — "add
account-ui to
it when the package goes public."

It was left out because the others build with `tsc -p
tsconfig.build.json`,
which cannot emit `.vue`. The package had no `tsconfig.build.json`, no
bundler
config, no `files`, and no `publishConfig`, so `pnpm pack` would have
uploaded
`src` — which the shared publishable rules reject outright
(`NON_PUBLIC_FILE` matches `^src/`).

## How

A Vite library build, one entry per published export, so `dist` mirrors
the
export map and importing `@comfyorg/account-ui/auth/regionGate` pulls
that
module rather than the package.

- `packages/account-ui/vite.config.ts` — eight entries, ES only, `vue()`
for
the SFCs and `vite-plugin-dts` for declarations with `cleanVueFileName`
so
  `PasswordRules.vue` emits `PasswordRules.d.ts` rather than
`PasswordRules.vue.d.ts`. Vue, VueUse and the sibling `@comfyorg`
packages
are external: a bundled Vue would give the consumer two runtimes, and
the
  injection keys the billing composables share are identity-compared.
- `packages/account-ui/tsconfig.build.json` — excludes tests and
  `__fixtures__`, which the tarball rules also reject.
- `packages/account-ui/package.json` — `files`, `sideEffects`,
repository
metadata, and a `publishConfig.exports` that resolves every subpath into
  `dist`, matching what `account-core` does.
- `.github/workflows/ci-packages-pack.yaml` — `account-ui` joins the
matrix
  and the path filter, so the same `check:pack` gate runs on it.
- `eslint.config.ts` — the new config file joins `allowDefaultProject`,
as the
  sibling `vitest.config.ts` files already do.

`build` runs `vite build --logLevel error`. That is not cosmetic:
`packPublishable` reads `pnpm pack --json` over a pipe, and `prepack`
writes
to the same stdout, so Vite's default build summary lands in the middle
of the
JSON and the check dies on `Unexpected token 'v'`. The three `tsc`
packages
never hit this because `tsc` is silent on success; quieting Vite makes
`account-ui` behave the same way, and errors still print and still fail
the
build.

## Verification

```
pnpm -C packages/account-ui build        # 8 entries, 28 packed files
pnpm -C packages/account-core run check:pack "$PWD/packages/account-ui"
  -> @comfyorg/account-ui: 28 packed files are publishable
pnpm -C packages/account-ui typecheck    # clean
pnpm -C packages/account-ui test         # 16 files, 79 tests
pnpm -C packages/account-ui lint         # clean
```

`dist` contains no test file and no `__fixtures__` entry.

## What this does NOT do, and it matters

**This PR does not make `@comfyorg/account-ui` installable from npm.**
The
tarball is now well formed, which is necessary and not sufficient. Its
runtime
`dependencies` are three workspace packages, and none of them is on the
registry:

| dependency | reached from | state |
| --- | --- | --- |
| `@comfyorg/account-core` | the billing composables | publishable since
Comfy-Org#17882, still `private` |
| `@comfyorg/tailwind-utils` | `cn()` in `PasswordRules.vue` | exports
`./src/index.ts`, no `files`, no `publishConfig` |
| `@comfyorg/shared-frontend-utils` | `isInChina()` in `regionGate.ts` |
same, plus it depends on `@comfyorg/object-info-parser` |

`pnpm pack` rewrites `workspace:*` to a version number, so the published
manifest *looks* correct and `check:pack` passes — the failure would
land on
the consumer's `npm install`, not here. The check that would catch it is
`smoke:pack`, which installs into a clean consumer; extending it to
`account-ui` requires those three packages to be packable first, so it
is not
in this PR.

Two things to decide before anything is published, neither of which is
mine
to settle:

1. **Licensing.** `account-ui` is MIT. `@comfyorg/object-info-parser` is
   GPL-3.0-only, and npm installs a package's whole `dependencies` graph
   regardless of which entry the consumer imports — so publishing
`shared-frontend-utils` as it stands puts GPL code in the install tree
of
   an MIT package. `@comfyorg/tailwind-utils` and
   `@comfyorg/shared-frontend-utils` carry no `license` field at all.
2. **Whether the dependency is worth keeping.** `account-ui` uses
exactly two
things from those packages: `cn()` and `isInChina()`. Relocating those
two
would drop `shared-frontend-utils` and `object-info-parser` out of the
publishing problem entirely, along with the licensing question above.
That
   is a smaller change than making three more packages publishable.

## AS IS / TO BE

No runtime or UI change. `account-ui`'s source exports are untouched, so
every
in-workspace consumer — the cloud app, `apps/website`,
`apps/billing-web` —
resolves exactly what it resolved before; `publishConfig` applies only
at
publish time.

- **AS IS** — `pnpm pack` on `account-ui` produces a tarball of `src`
that the
shared rules reject, and the package is absent from the pack CI matrix.
- **TO BE** — it produces a `dist` tarball that passes the same
`check:pack` gate as the other three, enforced in CI on every PR
touching
  `packages/account-ui/**`.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 | open
(Comfy-Org#17952) |
| 7 | **`account-ui` builds to dist and packs clean** | FE-2218 | **this
PR** |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | open (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| open (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | open (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | open (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
open (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 |
unblocked: Comfy-Org#17881 is on main |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (Comfy-Org#17952)"]
  UIB["account-ui dist build (Comfy-Org#17929)"]
  DEPS["drop unpublished deps (Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish: workflows are on main, awaiting go"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style UIB stroke:#0366d6,stroke-width:4px
```
@christian-byrne

Copy link
Copy Markdown
Contributor

Chased the fallow failure so you do not have to. Partial answer, and the missing half is a tooling problem rather than yours.

What is certain: the gate is real — gate: new-only, 1 finding(s) at error severity in changed files, exit 1.

What is not discoverable: which finding. We went through all four places it should be:

  • the job log names the count and the verdict, never the finding;
  • no artifacts are retained on the run (gh run download → "no valid artifacts found"), so the SARIF is gone;
  • the check summary is empty;
  • the annotations API is capped. The run itself says so: "fallow emitted 16 annotations; GitHub shows at most 10 per type per step". Paging returns 14, and ten of them are pre-existing package.json devDependency warnings (picocolors, openai, mixpanel-browser, …) that have nothing to do with your four files. They consumed the quota that the gating finding needed.

The one thing fallow reported inside your diff is a warning, not an error:

apps/billing-web/src/views/CheckoutView.vue:205 — High cognitive complexity (moderate). Function <template> — cognitive 23, threshold 15, cyclomatic 9.

That is the template growing a v-if reactivation block and a v-if failure line on top of what was already there. If fallow's gate counts that moderate finding as error-severity — its annotation level and its gate severity are not obviously the same scale — then extracting the reactivation <label> into a small component clears it. If it does not, then the gating finding is genuinely invisible and no amount of reading the PR will surface it.

Fastest path: pnpm fallow audit --changed-since <base> locally will print it in one line. We could not run it here — fallow is declared in package.json but not installed in our worktree, and we are not going to install into a shared tree to find out.

Two things worth separating, since only one is yours:

  1. Your PR may well need one small extraction in the template. Cheap either way — the complexity warning is fair on its own merits now that the view carries quote, reactivation and failure states.
  2. A check that fails a merge without naming the reason is the actual defect here, and it is ours, not yours. This is the third shape of it we have logged this week, after the backport job on Phase 3/4 billing backports to core/1.54 and cloud/1.54 fail silently: the release branches have no account package #17774 and create-tag on cloud release tags are silently missing: create-tag push rejected for want of workflows scope #17925 — a job whose outcome is legible only to whoever thinks to dig. We will take the annotation-cap problem separately; the ten package.json warnings crowding out a blocking finding is a repo-wide issue that will do this to somebody else next week.

No review round from us on this PR yet — we are working up the stack in order and #17936 is next. Not blocking you on it.

@dante01yoon

Copy link
Copy Markdown
Collaborator Author

fallow was red at 26833e81b0 on one error-severity finding: apps/billing-web/src/views/CheckoutView.vue:205 <template> at cognitive complexity 23 against a threshold of 15 (cyclomatic was 9, just inside its own limit). The reactivation checkbox and the refused-subscribe line this PR adds both sit six levels deep inside the payment form's #submit slot, and nesting is what cognitive complexity charges for.

Fixed in 2d07d867cc by moving that slot's body into apps/billing-web/src/components/CheckoutSubmit.vue. The rendered markup is unchanged — the reactivation cases in CheckoutView.test.ts query by role and still pass untouched, which is what makes it a safe extraction rather than a rewrite.

Verified locally at 2d07d867cc: fallow audit --changed-since 9efe52fbd4 prints No issues in 6 changed files (exit 0), billing-web unit 13 files / 111 tests pass, and root + per-package typecheck, oxlint --type-aware, eslint, stylelint and oxfmt are all clean.

#17947 is stacked on this branch and picks the change up on the next stack rebase; its own fallow run is scoped to its own diff, so it was never red for this.

@dante01yoon
dante01yoon force-pushed the fe-2331-billing-web-subscription-actions branch from 9efe52f to 7fd4256 Compare September 17, 2026 23:04
@dante01yoon
dante01yoon force-pushed the fe-2331-billing-web-reactivation-confirm branch from 2d07d86 to f4eb453 Compare September 17, 2026 23:05
dante01yoon added a commit that referenced this pull request Sep 18, 2026
…inst a mocked Cloud and identity (#17947)

Linear FE-2218. Stacked on #17943 → #17937 → #17936 → #17934 → #17932 →
#17929; merge after them. Closes the "browser tests" half of the last
open line in the hosted-billing TDD's *Can start immediately* list
(#17941 closed the CSP half).

## Why

`apps/billing-web` had unit tests only. Every view is covered with a
fake billing client handed in through `provide`, which proves the views
but not the app: that a customer arriving on an entry link is taken
through sign-in and back, that the session mint carries the identity
token and the reads carry the workspace token, that a hosted redirect
actually leaves the page, and that a bad link explains itself rather
than bouncing. Those are the things a preview deployment gets checked
for by hand before a promotion, and nothing ran them on every PR.

`browser_tests/` is the cloud app's harness — `comfyPage`, a ComfyUI
backend, its fixtures — and cannot drive this origin. #17936 gave the
app a checkout, a result page and the portal hand-off, which is what a
harness needs to drive.

## How

A Playwright project of the app's own, `apps/billing-web/e2e`, against a
**production build** of the app with the `test` Cloud family, a Firebase
project that exists only in the fixtures, and no Stripe key — so every
checkout routes hosted and no provider script loads. The build takes its
variables from the suite, never from a local `.env`.

**Everything the app can reach is answered in-process**
(`e2e/fixtures/cloud.ts`): the two Firebase endpoints an email sign-in
touches, the token refresh, the Cloud token exchange, every billing
route the SDK reads or commands, and the page a portal redirect lands
on. A catch-all registered first refuses any other origin, so a passing
spec has not contacted a real service. Each answer carries the CORS
headers a real Cloud would and preflights are answered, because to the
browser these are cross-origin responses.

`cloud.scenario` is what the mocked Cloud holds; a spec mutates it
before navigating or from a `cloud.reply` handler to model a server-side
change (the cancel spec flips `can_cancel` to `can_reactivate` when the
cancel lands). `cloud.requests` records what the app sent.
`signIn(path)` opens an entry link, goes through the email form and
resolves once the app is back on that link.

**15 specs**, ~4 s wall clock:

| Spec | Proves |
| --- | --- |
| `sign-in` | entry link → sign-in with `returnTo` → back on the intent;
the mint carries the Firebase token, reads carry the workspace JWT; a
reload restores without the form |
| `subscription` | catalog with the current plan marked and priced;
choosing a plan posts `preview-subscribe` and continues to checkout; a
checkout link with no plan sends the customer to choose one; cancel
needs a confirmation step, posts once, polls the operation and then
offers resubscribe; only server-allowed actions render |
| `result` | a pending `billing_op_id` on status is recovered and
reported on the return link as `billing_result=success&billing_ref=…`;
nothing pending says so |
| `invoices`, `payment-methods` | the portal hand-off leaves the page
with `return_url` set to the page; saved cards listed with the default
marked; empty state |
| `entry` | unknown product, unregistered return target, unknown intent
each explain themselves instead of redirecting |

**CI**: `CI: Billing Web E2E` runs in the Playwright container on every
PR that touches the app or a package, with the same gate job shape as
the unit workflow; the report is uploaded on failure.

## Verification

- `pnpm --filter @comfyorg/billing-web test:e2e`: 15 passed.
- `pnpm --filter @comfyorg/billing-web typecheck`, `lint`, `pnpm knip`
clean; `e2e/` is in the app's `tsconfig` and lint scope.

## AS IS / TO BE

No product change.

- **AS IS** — the hosted surfaces are proven view by view against a fake
client; the app as deployed is checked by hand on a preview.
- **TO BE** — every PR drives the deployed shape of the app in a
browser: sign-in, session, reads, commands, redirects and entry errors,
with no network beyond the test.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 | open
(#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | open
(#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | open (#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (#17943) |
| 8 ui | **billing-web Playwright harness against a mocked Cloud** |
FE-2218 | **this PR** |
| 9 | Status and balance reads on the rail | FE-2216 | open (#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | open (#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
open (#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 |
unblocked: #17881 is on main |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged #17881)"]
  PUBREP["publish report via workflow_run (#17952)"]
  UIB["account-ui dist build (#17929)"]
  DEPS["drop unpublished deps (#17932)"]
  CSP["billing-web CSP (merged #17941)"]
  PROMO["Stripe payment form in account-ui (#17934)"]
  CHK["billing-web checkout + result + invoices (#17936)"]
  SUBW["billing-web cancel / resubscribe (#17937)"]
  REACT["reactivation confirmation (#17943)"]
  E2E["billing-web Playwright harness (#17947)"]
  RD1["status + balance on the rail (#17940)"]
  RD2["plans on the rail (#17942)"]
  RD3["capabilities + payment methods on the rail (#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish: workflows are on main, awaiting go"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style E2E stroke:#0366d6,stroke-width:4px
```

@christian-byrne christian-byrne left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving at 9b3ffd3f86. CI is fully green now — fallow passes and there are no genuine failures on the head, so the thing we could not diagnose for you last night is closed.

The consent reset is the detail that matters most here, and it is right.

watch(preview, (quoted) => {
  reactivationRequired.value = quoted?.requires_reactivation_confirmation === true
  reactivationConfirmed.value = false
})

Clearing reactivationConfirmed on every new quote means a customer who agreed to a charge cannot have that agreement carried onto a re-quoted, different charge. That is exactly the case the server-driven path creates: REACTIVATION_CONFIRMATION_REQUIRED triggers a re-quote and then asks again, and without the reset the previous tick's consent would satisfy the new gate. Easy to omit, expensive if omitted, and it is here.

The gate is single and correct. One canSubmit at line 77, and it is the one that gates on reactivation:

(preview.value?.allowed ?? false) &&
(!reactivationRequired.value || reactivationConfirmed.value)

We checked the history because ff1d2fbf15 ("keep one canSubmit") implied there had been two, and there had — ec8c54e932 carried declarations at both line 76 and line 120, the second being the ungated preview.value?.allowed ?? false. Worth recording that this never reached a head CI evaluated: it was introduced and removed inside the same push, and the head that fallow failed on earlier had only one declaration. So this was self-caught, not a near miss that CI let through. We are noting it only because the two-declaration state, had it landed, would have been the ungated version winning on a payment page.

Both directions of the reactivation requirement are covered. The quote can declare it up front (requires_reactivation_confirmation), or the server can refuse the subscribe with REACTIVATION_CONFIRMATION_REQUIRED, in which case the plan is re-quoted before the customer is asked. confirm_reactivation: true is sent only when confirmed. That is the right shape: the client never assumes it knows the answer, and the server's refusal is a normal path rather than an error.

f4eb45314d lifting the pay action out of the template is a good call independently — that template had grown a quote panel, a reactivation block and a failure line, and it was the one thing in this diff we would have flagged on readability.

No findings. Note that #17947 merged into this branch rather than into main, so this PR now carries the browser-test harness we approved separately; nothing in it changed on the way in.

Approved.

pull Bot pushed a commit to Penguinjanator/ComfyUI_frontend that referenced this pull request Sep 18, 2026
…s when a rail is on (Comfy-Org#17940)

Linear FE-2216. Independent of the billing-web stack; based on `main`.

## Why

Since Comfy-Org#17665 and Comfy-Org#17853 the cloud app's billing *writes* run on the SDK
rail behind the two flags, but its *reads* never moved:
`useWorkspaceBilling.fetchStatus` and `fetchBalance` still call
`workspaceApi` directly. `createBillingSdk` builds the status, credits,
capabilities, plans and payment-methods readers and disposes them, and
nothing in the app reads through them —
`sdk.paymentMethods.invalidate()` is called with no reader behind it.

That is a real inconsistency, not a tidiness gap. After a subscribe on
the rail, `refreshAfterSubscriptionChange` reads through the SDK's
`credits` and `status` readers (the commands refresh them on success),
then `reconcileBillingStateAfterSubscribe` re-reads the same two things
through the workspace client. The panels render the second read. Two
clients, two caches, one screen.

## How

**A read rail, chosen like the write rails.** `useBillingReadRail()`
returns the SDK store when *either* `billingSdkTopupRailEnabled` or
`billingSdkSubscriptionRailEnabled` is on, null otherwise, and is read
once per fetch and held — a flag flip mid-read must not start on one
client and publish through the other. Either write rail turns the reads
on because a status the SDK's lifecycle recovers from, or a balance its
top-up refreshed, should be the state the panels read, or the rail
settles one thing and the screen shows another.

**Two reads on the store.** `readStatus()` and `readBalance()` wrap
`sdk.status.read()` / `sdk.credits.read()` and return `BillingResult<…>`
in the host's own response types.

**One projection, because the generated types disagree with each
other.** `zBillingStatusResponse` coerces the credit stop's
`credits_monthly` and `stop_usd` (int64) to `bigint`, while the
generated TypeScript type the host reads them through says `number`.
`projectBillingStatus` reads the two back as numbers — whole units
bounded far inside the safe range, the way the core already reads cents
and the capability revision — on both `team_credit_stop` and
`scheduled_change.team_credit_stop`. Balance needs no projection; its
micros are plain numbers in both.

**`fetchStatus` / `fetchBalance`** pick the rail, then run exactly as
before: the same stale-read guards, the same `resumePendingOperation`,
the same `isLoading` / `error` handling. On the rail a `SUPERSEDED`
result is treated as a stale read — nothing published, nothing reported,
which is what a legacy read that lost a workspace race already does. Any
other failure throws a `WorkspaceApiError` carrying the code, so
`initialize`, `retryBillingRead` and
`reconcileBillingStateAfterSubscribe` keep their contract (they expect a
rejection) and `error.value` carries the code.

`fetchPlans` is deliberately not on this PR: the plans catalog is
bigint-heavy (`price_cents`, `credits_cents`, `max_seats`, the seat
summary) and the app's `Plan` type is consumed across the pricing
surfaces, so that projection deserves its own review.

## Review focus

**Turning on the top-up rail now also moves status reads to the SDK.**
Two existing tests in `useWorkspaceBilling.sdk.test.ts` asserted the SDK
was *not* built when only a subscription operation was pending; that
premise no longer holds, since the read itself builds the store. They
now assert what they were really guarding — that `lifecycle.recover`
does not run for a subscription — and stub the SDK status reader instead
of the workspace client.

**The thrown error is a `WorkspaceApiError`, not a bare `Error`.**
`comfy/no-new-error-throw` forbids the latter in production code, and
the class is what the legacy client throws on the same path, so
`error.value` and `isAlreadyInRequestedState` see the shape they already
handle.

## Verification

```
pnpm vitest run useWorkspaceBilling.{,sdk.,subscriptionRail.}test.ts \
  billingSdkStore.test.ts billingStatusView.test.ts useTopupOperation.test.ts
  -> 6 files, 173 tests
pnpm typecheck / eslint / oxlint / knip   # clean
```

New: `billingStatusView.test.ts` (2) pins the bigint projection and the
null pass-through; five read-rail scenarios in
`useWorkspaceBilling.sdk.test.ts` — legacy path with the flag off,
status and balance through the readers, `SUPERSEDED` leaves state and
error untouched, a failed read surfaces the code and rejects.

## AS IS / TO BE

No UI change. Both flags are at 0% in staging and prod, so nothing reads
differently until they move.

- **AS IS** — flag on: writes through the SDK, reads through the
workspace client; a subscribe refreshes the SDK's readers, then the
panels re-read and render the legacy client's answer.
- **TO BE** — flag on: writes and the two reads on the same readers; the
refresh a command performs is the read the panels render. Flag off:
byte-for-byte the legacy path.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 | open
(Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | open
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | open (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| open (Comfy-Org#17947) |
| 9 | **Status and balance reads on the rail** | FE-2216 | **this PR** |
| 9 | Plan catalog read on the rail | FE-2216 | open (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
open (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 |
unblocked: Comfy-Org#17881 is on main |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (Comfy-Org#17952)"]
  UIB["account-ui dist build (Comfy-Org#17929)"]
  DEPS["drop unpublished deps (Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish: workflows are on main, awaiting go"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style RD1 stroke:#0366d6,stroke-width:4px
```
pull Bot pushed a commit to Penguinjanator/ComfyUI_frontend that referenced this pull request Sep 18, 2026
…ndencies (Comfy-Org#17932)

Linear FE-2218. Stacked on Comfy-Org#17929 — review that first.

## Why

Comfy-Org#17929 makes `@comfyorg/account-ui` pack a well-formed `dist` tarball,
and
notes that this is necessary and not sufficient: the package still could
not be
installed from npm, because two of its three runtime dependencies are
unpublished workspace packages that export `./src/*.ts` and carry no
`files`
or `publishConfig`.

`npm view` confirms the state — of the whole `@comfyorg` scope only
`design-system@1.1.0` exists on the registry.

The obstacle was smaller than it looked. `account-ui` used exactly two
things
from those packages:

| import | from | used by |
| --- | --- | --- |
| `cn()` | `@comfyorg/tailwind-utils` | `PasswordRules.vue` |
| `isInChina()` | `@comfyorg/shared-frontend-utils/networkUtil` |
`regionGate.ts` |

Making three more packages publishable — `tailwind-utils`,
`shared-frontend-utils`, and `object-info-parser` beneath it — was the
alternative. It also carried a licensing question: `object-info-parser`
is
GPL-3.0-only, `account-ui` is MIT, and npm installs a package's whole
`dependencies` graph regardless of which entry the consumer imports.
Removing
the two imports removes that question rather than answering it.

## How

**`cn()` was doing nothing here.** Every call was `cn(!checks.x &&
unmetClass)`
— one class source, nothing to merge, so `tailwind-merge`'s conflict
resolution had no conflicts to resolve and `clsx` was collapsing a
single
value. The five bindings become `:class="checks.x ? undefined :
unmetClass"`.
This is not the `:class="[]"` array-merge the guidelines prohibit: there
is no
second class on the element and nothing to merge. If a class ever joins
them,
`cn()` comes back with the host's copy.

**`isInChina()` moves to the package that is its only consumer.** New
file
`packages/account-ui/src/auth/regionProbe.ts`, carrying the region half
of
`networkUtil.ts` verbatim — `getClientCountry`, the trace parse, the
bounded
`fetchWithin`, the Google/Baidu fallback. `useRegionGate` keeps its
signature,
so no call site changes.

Two details worth knowing:

- **It never needed axios.** `isInChina` is `fetch`, `navigator` and
`performance` only; the axios import at the top of `networkUtil.ts`
belongs
to `checkUrlReachable`, which stays behind for `UrlInput.vue`. Importing
the
module for the region probe was pulling in an HTTP client it does not
use.
- **`getClientCountry` and `isInChina` had exactly one production caller
between them**, `regionGate.ts`. Everything else in the grep was a test
  mocking the module. So this is a move, not a split.

`./auth/regionProbe` becomes a published subpath. It is the seam three
host
test suites already control — `CloudSignupView.test.ts`,
`SignInContent.test.ts` and the website's `AuthSignIn.test.ts` each mock
the
probe to drive `useRegionGate` through its deferred, hanging and
rejecting
paths — and they cannot pass an argument through a rendered component
tree, so
the module has to be addressable. Their `vi.mock` specifiers move with
it.

## Result

`account-ui`'s runtime dependencies are now `@comfyorg/account-core`
alone,
which Comfy-Org#17882 already made publishable. The remaining gate on publishing
is
flipping `private` on those two, not making more packages publishable.

## Verification

```
pnpm -C packages/account-ui test              # 17 files, 97 tests
pnpm -C packages/shared-frontend-utils test   # 4 files, 126 tests
pnpm vitest run src/platform/cloud/onboarding/CloudSignupView.test.ts \
                src/components/dialog/content/SignInContent.test.ts   # 18 tests
pnpm -C apps/website exec vitest run src/components/auth/AuthSignIn.test.ts  # 73 tests
pnpm -C packages/account-core run check:pack "$PWD/packages/account-ui"
  -> @comfyorg/account-ui: 30 packed files are publishable
pnpm typecheck / pnpm lint / pnpm knip        # clean
```

The moved tests are unchanged apart from their import path, so the
region
probe keeps the coverage it had in `shared-frontend-utils`.

## AS IS / TO BE

No runtime or UI change. `PasswordRules` renders the same markup — the
unmet
class is applied on exactly the same condition — and `useRegionGate`
resolves
on the same probe with the same signature.

- **AS IS** — `@comfyorg/account-ui` declares three runtime
dependencies, two
  of them unpublishable, one of those transitively GPL-3.0-only.
- **TO BE** — one runtime dependency, already publishable.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 | open
(Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | open
(Comfy-Org#17929) |
| 7 | **`account-ui` drops its unpublished dependencies, joins
`smoke:pack`** | FE-2218 | **this PR** |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| open (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | open (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | open (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
open (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 |
unblocked: Comfy-Org#17881 is on main |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (Comfy-Org#17952)"]
  UIB["account-ui dist build (Comfy-Org#17929)"]
  DEPS["drop unpublished deps (Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish: workflows are on main, awaiting go"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style DEPS stroke:#0366d6,stroke-width:4px
```
pull Bot pushed a commit to Penguinjanator/ComfyUI_frontend that referenced this pull request Sep 18, 2026
…hen a rail is on (Comfy-Org#17942)

Linear FE-2216. Stacked on Comfy-Org#17940, which put status and balance on the
rail and deferred the catalog to its own review — this is that review.

## Why

Comfy-Org#17940 left `fetchPlans` on the workspace client on purpose: the plan
catalog is the bigint-heaviest response the SDK decodes, and the app's
`Plan` type is consumed across the pricing surfaces, so the projection
deserved its own diff. With status and balance on the rail, the catalog
was the last read the panels took from a different client than the one
the commands refresh.

## How

**`projectBillingPlans`** (`billingPlansView.ts`) — the counterpart of
`projectBillingStatus`. `zGetBillingPlansResponse` coerces every int64
to `bigint`: `price_cents`, `credits_cents`, `max_seats`, the seat
summary's two totals, and in the credit-stop ladder `credits` plus the
monthly and yearly `list_price_cents` / `price_cents`. The generated
type the pricing surfaces read them through says `number` for all of
them. The projection reads each back as a number — cents, credits and
seat counts, bounded far inside the safe range — and touches nothing
else: availability, tier, duration and slug pass through, and a catalog
without a ladder comes out without one. `BillingPlansView.test.ts` pins
every converted field and the absent-ladder case.

**`readPlans()`** on the SDK store, next to `readStatus` /
`readBalance`, and on the `BillingReadRail` interface.

**`readOnRail` moves to its own module** (`composables/readOnRail.ts`)
rather than living inside `useBillingReadRail.ts`, so
`useBillingPlans.test.ts` can replace the rail with a focused full mock
— the repo's `no-import-actual` rule forbids `importOriginal` — while
the helper it exercises stays real.

**`useBillingPlans.fetchPlans`** picks the rail once per fetch, the way
the other reads do, and adopts the response through one `adopt()`; a
`SUPERSEDED` read adopts nothing. The singleton, its de-duplication and
its consumers (`UnifiedPricingTable`, `useWorkspaceBilling`) are
untouched — every surface that reads the catalog moves together, because
there is one catalog.

## Review focus

**The mock in `useBillingPlans.test.ts` now defines
`WorkspaceApiError`.** That file already full-mocks `workspaceApi` with
only `getBillingPlans`; `readOnRail` throws the module's error class, so
the mock needs it. The stand-in is `class extends Error {}` — only its
message reaches `error.value`, which the failed-read case asserts.

**Same gate as Comfy-Org#17940:** either write-rail flag turns the read on. Flag
off is byte-for-byte the legacy path.

## Verification

```
pnpm vitest run useBillingPlans.test.ts billingPlansView.test.ts \
  useWorkspaceBilling.{,sdk.}test.ts billingSdkStore.test.ts UnifiedPricingTable.test.ts
  -> 6 files, 200 tests
pnpm typecheck / eslint / oxlint / knip   # clean
```

New: `billingPlansView.test.ts` (2), three rail scenarios in
`useBillingPlans.test.ts` — the catalog through the reader with the
client untouched, `SUPERSEDED` leaves the previous catalog and no error,
a failed read surfaces its code.

### Why no Playwright regression test

Both `fix(` commits here are boundary conditions inside the projection
and the
composable, and each ships its regression test in the same commit:

- `afd9907` refuses a catalog value past `Number.MAX_SAFE_INTEGER`
instead of
rounding it. No Cloud catalog produces a price, credit or seat count
anywhere
near 2^53 — the guard exists so that a future one could never be
silently
  rounded into a wrong price — so no browser fixture reaches it.
  `billingPlansView.test.ts` drives the boundary directly.
- `1f80420` keeps a reported plans failure when the next read returns
`SUPERSEDED`. Reaching it needs two overlapping in-flight reads whose
second
one is superseded; Playwright cannot order that deterministically
against a
  backend, while `useBillingPlans.test.ts` pins it exactly.

Neither has a UI surface of its own: the first refuses inside the
projection
before anything renders, the second restores the same error object the
pricing
surfaces already display. The path is behind the two rail flags as well,
both at
0% in staging and prod, so an end-to-end test would have to force-enable
a flag
that ships off and assert a configuration no environment runs.

## AS IS / TO BE

No UI change; both flags at 0%.

- **AS IS** — flag on: status and balance through the SDK readers, the
catalog through the workspace client.
- **TO BE** — flag on: all three reads through the readers the commands
already refresh.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 | open
(Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | open
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | open (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| open (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | open (Comfy-Org#17940) |
| 9 | **Plan catalog read on the rail** | FE-2216 | **this PR** |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
open (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 |
unblocked: Comfy-Org#17881 is on main |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (Comfy-Org#17952)"]
  UIB["account-ui dist build (Comfy-Org#17929)"]
  DEPS["drop unpublished deps (Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish: workflows are on main, awaiting go"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style RD2 stroke:#0366d6,stroke-width:4px
```
pull Bot pushed a commit to Penguinjanator/ComfyUI_frontend that referenced this pull request Sep 18, 2026
…rough the SDK readers when a rail is on (Comfy-Org#17946)

Linear FE-2216. Stacked on Comfy-Org#17942 (plans) → Comfy-Org#17940 (status, balance);
merge after both.

## Why

With a write rail on, the cloud app reads status, balance and plans
through the SDK's readers (Comfy-Org#17940, Comfy-Org#17942) so the panels show the state
the rail settled. Two reads still went around the SDK: the capabilities
snapshot (`useBillingCapabilities`) and the saved payment methods
(`useHasSavedPaymentMethod`, the checkout's default-card pick). The
shared top-up flow in `@comfyorg/account-ui` reads capabilities through
the SDK's own cache, so with the rail on the app and the shared flow
could hold two different capability snapshots for one workspace, and a
saved-card list the SDK invalidated after a portal round-trip stayed as
the legacy client last read it.

## How

`BillingReadRail` gains `readCapabilities(options)` and
`readPaymentMethods()`; the SDK store serves both from its readers.
`projectBillingCapabilities` turns the SDK snapshot back into the
`BillingCapabilitiesResponse` the composable already holds: `expires_at`
is the instant the SDK stops serving the snapshot, `resolved_for` is the
scope it was resolved for. No int64 in either body, so no safe-range
projection this time.

The capabilities composable keeps every push concern it owns — the
expiry timer, visibility gating, backoff, the revision listener — and
only swaps the read underneath. A first read for a scope takes the SDK's
cached snapshot, which is what the shared top-up flow just read; a
revalidation, which the composable only starts when a mutation or the
timer said the snapshot is stale, passes `forceRefresh` so the SDK cache
cannot answer it.

`readOnRail` now carries the failure's `httpStatus` into the thrown
`WorkspaceApiError`, so the composable's denial rule (401/403 fails
closed, no retry) reads the same on either rail. A `SUPERSEDED` read —
the SDK's scope moved on under the read while the stores' did not —
retries on the outage timer without a report, because the next read
answers for whichever scope settles.

The two saved-card readers pick the rail once per fetch, like every
other read.

## Verification

- `billingCapabilitiesView.test.ts`: snapshot → response projection.
- `useBillingCapabilities.test.ts`: rail read applied without the legacy
client; revalidation after a mutation revision bypasses the SDK cache;
`ACCESS_DENIED`/403 fails closed with no retry and `REQUEST_FAILED`/503
keeps the owner fallback and retries, as the legacy statuses do; a
superseded read retries unreported.
- `useHasSavedPaymentMethod.test.ts`, `useSubscriptionCheckout.test.ts`:
default-card pick through the rail; superseded → unknown; failed rail
read reported with its status.
- `pnpm typecheck`, `pnpm knip`, lint clean.

## AS IS / TO BE

No user-visible change while both rail flags are off. With a rail on:

- **AS IS** — capabilities and saved cards read by the legacy client;
the shared top-up flow and the app can disagree on what the customer may
do.
- **TO BE** — every billing read the app makes with a rail on comes from
the SDK's readers; one snapshot per scope.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 | open
(Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | open
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | open (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| open (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | open (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | open (Comfy-Org#17942) |
| 9 | **Capabilities and saved payment methods on the rail** | FE-2216 |
**this PR** |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 |
unblocked: Comfy-Org#17881 is on main |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (Comfy-Org#17952)"]
  UIB["account-ui dist build (Comfy-Org#17929)"]
  DEPS["drop unpublished deps (Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish: workflows are on main, awaiting go"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style RD3 stroke:#0366d6,stroke-width:4px
```
@dante01yoon
dante01yoon force-pushed the fe-2331-billing-web-subscription-actions branch from 7fd4256 to 0f37339 Compare September 18, 2026 10:15
…te (FE-2331)

The reactivation checkbox and the refused-subscribe line pushed the
CheckoutView template's cognitive complexity to 23 against fallow's
threshold of 15, because both sit six levels deep inside the payment
form's submit slot.

Move that slot's body into CheckoutSubmit.vue. The rendered markup is
unchanged, so the existing CheckoutView cases cover it.
…inst a mocked Cloud and identity (#17947)

Linear FE-2218. Stacked on #17943 → #17937 → #17936 → #17934 → #17932 →
#17929; merge after them. Closes the "browser tests" half of the last
open line in the hosted-billing TDD's *Can start immediately* list
(#17941 closed the CSP half).

## Why

`apps/billing-web` had unit tests only. Every view is covered with a
fake billing client handed in through `provide`, which proves the views
but not the app: that a customer arriving on an entry link is taken
through sign-in and back, that the session mint carries the identity
token and the reads carry the workspace token, that a hosted redirect
actually leaves the page, and that a bad link explains itself rather
than bouncing. Those are the things a preview deployment gets checked
for by hand before a promotion, and nothing ran them on every PR.

`browser_tests/` is the cloud app's harness — `comfyPage`, a ComfyUI
backend, its fixtures — and cannot drive this origin. #17936 gave the
app a checkout, a result page and the portal hand-off, which is what a
harness needs to drive.

## How

A Playwright project of the app's own, `apps/billing-web/e2e`, against a
**production build** of the app with the `test` Cloud family, a Firebase
project that exists only in the fixtures, and no Stripe key — so every
checkout routes hosted and no provider script loads. The build takes its
variables from the suite, never from a local `.env`.

**Everything the app can reach is answered in-process**
(`e2e/fixtures/cloud.ts`): the two Firebase endpoints an email sign-in
touches, the token refresh, the Cloud token exchange, every billing
route the SDK reads or commands, and the page a portal redirect lands
on. A catch-all registered first refuses any other origin, so a passing
spec has not contacted a real service. Each answer carries the CORS
headers a real Cloud would and preflights are answered, because to the
browser these are cross-origin responses.

`cloud.scenario` is what the mocked Cloud holds; a spec mutates it
before navigating or from a `cloud.reply` handler to model a server-side
change (the cancel spec flips `can_cancel` to `can_reactivate` when the
cancel lands). `cloud.requests` records what the app sent.
`signIn(path)` opens an entry link, goes through the email form and
resolves once the app is back on that link.

**15 specs**, ~4 s wall clock:

| Spec | Proves |
| --- | --- |
| `sign-in` | entry link → sign-in with `returnTo` → back on the intent;
the mint carries the Firebase token, reads carry the workspace JWT; a
reload restores without the form |
| `subscription` | catalog with the current plan marked and priced;
choosing a plan posts `preview-subscribe` and continues to checkout; a
checkout link with no plan sends the customer to choose one; cancel
needs a confirmation step, posts once, polls the operation and then
offers resubscribe; only server-allowed actions render |
| `result` | a pending `billing_op_id` on status is recovered and
reported on the return link as `billing_result=success&billing_ref=…`;
nothing pending says so |
| `invoices`, `payment-methods` | the portal hand-off leaves the page
with `return_url` set to the page; saved cards listed with the default
marked; empty state |
| `entry` | unknown product, unregistered return target, unknown intent
each explain themselves instead of redirecting |

**CI**: `CI: Billing Web E2E` runs in the Playwright container on every
PR that touches the app or a package, with the same gate job shape as
the unit workflow; the report is uploaded on failure.

## Verification

- `pnpm --filter @comfyorg/billing-web test:e2e`: 15 passed.
- `pnpm --filter @comfyorg/billing-web typecheck`, `lint`, `pnpm knip`
clean; `e2e/` is in the app's `tsconfig` and lint scope.

## AS IS / TO BE

No product change.

- **AS IS** — the hosted surfaces are proven view by view against a fake
client; the app as deployed is checked by hand on a preview.
- **TO BE** — every PR drives the deployed shape of the app in a
browser: sign-in, session, reads, commands, redirects and entry errors,
with no network beyond the test.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 | open
(#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | open
(#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | open (#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (#17943) |
| 8 ui | **billing-web Playwright harness against a mocked Cloud** |
FE-2218 | **this PR** |
| 9 | Status and balance reads on the rail | FE-2216 | open (#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | open (#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
open (#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish (`private` off), Platform install | FE-2218 |
unblocked: #17881 is on main |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged #17881)"]
  PUBREP["publish report via workflow_run (#17952)"]
  UIB["account-ui dist build (#17929)"]
  DEPS["drop unpublished deps (#17932)"]
  CSP["billing-web CSP (merged #17941)"]
  PROMO["Stripe payment form in account-ui (#17934)"]
  CHK["billing-web checkout + result + invoices (#17936)"]
  SUBW["billing-web cancel / resubscribe (#17937)"]
  REACT["reactivation confirmation (#17943)"]
  E2E["billing-web Playwright harness (#17947)"]
  RD1["status + balance on the rail (#17940)"]
  RD2["plans on the rail (#17942)"]
  RD3["capabilities + payment methods on the rail (#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB(["first publish: workflows are on main, awaiting go"])
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> PUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style E2E stroke:#0366d6,stroke-width:4px
```
@dante01yoon
dante01yoon force-pushed the fe-2331-billing-web-reactivation-confirm branch from 9b3ffd3 to ce20984 Compare September 18, 2026 10:17
@dante01yoon

Copy link
Copy Markdown
Collaborator Author

Rebased after #17937's branch was rewritten under this one. Base stays
fe-2331-billing-web-subscription-actions, since neither #17936 nor #17937 has
merged yet.

9b3ffd3f86 → ce20984b1d, replaying all four commits onto 0f37339506. No
merge commits in the range — #17947 came in as a squash — so the replay is linear.

The diff this PR contributes is byte-identical:

git diff 7fd4256399..9b3ffd3f86   # against the old subscription-actions tip
git diff 0f37339506..ce20984b1d   # against the rebased tip

Both hash to f88c304805041181bc156f6e5d63b7bd29db1aec. Still 25 files,
+1169/−23.

Verified on the rebased head:

  • canSubmit is declared exactly once in CheckoutView.vue. Checking that
    by name rather than by scan, because this is the PR where a conflict-free
    rebase silently produced a second declaration (ff1d2fbf15), and the ungated
    one would have won on a payment page.
  • pnpm --filter @comfyorg/billing-web typecheck — clean, and tsconfig.json
    includes e2e/**/*, so the harness this PR carries is covered by that run.
  • pnpm --filter @comfyorg/billing-web test:unit — 111 tests, 13 files, all pass.
  • Remaining repeated-declaration hits (arrival/quoted in CheckoutView.vue,
    url in e2e/fixtures/cloud.ts, subscription in e2e/sign-in.spec.ts) are
    separate function scopes, which vue-tsc passing confirms.

That closes the rebase chain: #17936 on main, #17937 on it, this on #17937. The
only thing gating all three is a re-approval on #17936.

Still open from your approval here: the E2E origin-blocking finding on #17947 —
nothing proves the catch-all still blocks. That harness is in this PR's diff, so
I can close it here rather than as a follow-up. Say the word and I will add the
requestfailed assertion to the shared fixture; I will mutation-check it first
(origin === E2E_ORIGIN → true) so we are not landing another test that
cannot fail.

pull Bot pushed a commit to Mu-L/ComfyUI_frontend that referenced this pull request Sep 18, 2026
…ared package (Comfy-Org#17934)

Linear FE-2331. Stacked on Comfy-Org#17932 → Comfy-Org#17929 (both merged; this now
targets `main`). Implements decision 1 of ADR-PACKAGES-ACCOUNT-UI-0034
(Comfy-Org#17927, approved).

## Why

`apps/billing-web` renders `/v1/checkout` as a static mock with
`checkout-enabled` false. The working flow — mount Stripe Elements,
validate,
`createConfirmationToken`, hand the token to `subscribe` — lived in
`src/platform/workspace/components/UnifiedStripePaymentSelector.vue`,
inside
the private root package, which exposes no entry points and which
nothing
depends on. There was no specifier `apps/billing-web` could import it
by, so
hosted checkout was a choice between promoting the component and writing
a
second one. ADR-0034 settled that: a payment surface more than one host
renders
belongs to the package.

## How

`packages/account-ui/src/billing/stripe/`, exported as
`@comfyorg/account-ui/billing/stripe`. Per ADR-0034 decision 3 it is a
separate
entry point with `@stripe/stripe-js` as an **optional** peer, so a host
wanting
only the composables in `./billing` never installs the provider.

Decision 4 says promoted components take their host couplings as inputs.
Three
were imports and are now inputs:

| was | is |
| --- | --- |
| `Button` from the cloud app's design system | the `submit` slot, with
`disabled` / `loading` / `verificationPending` slot props |
| `useTelemetry()` + `getActiveCheckoutJourney()` | a `phase` emit
carrying `StripePaymentPhase` |
| `useI18n()` and seven `$t` keys | a `copy` prop, as
`PasswordRules.vue` already does |

A fourth was `import.meta.env.VITE_STRIPE_PUBLISHABLE_KEY`, which a
package
cannot read on the host's behalf — now a `publishableKey` prop.

The phase union is the package's own four members, not the host's nine.
The
form reports what happened; whether a journey is active, and what
context to
stamp on it, stays with the host — which is also the one guard that
could not
move, since the package cannot know the active journey belongs to a
later
checkout.

**The Tailwind classes stay.** They resolve against
`@comfyorg/design-system`
tokens, which both hosts already load, and ADR-0034's rule 4 names the
button,
the telemetry sink and the journey events specifically. "Unstyled" means
not
choosing a design system, not shipping unclassed markup.

`UnifiedStripePaymentSelector.vue` survives as the cloud app's binding —
same
props, same emits, so `SubscriptionAddPaymentPreviewWorkspace.vue` is
untouched.

## Review focus

**The Stripe entry is bundler-only, and the smoke test now says so out
loud.**
Adding it to the packed-tarball smoke test failed the plain-node import
with
`ERR_UNSUPPORTED_DIR_IMPORT`: `@stripe/stripe-js@9.12.1` publishes **no
`exports` map**, so `@stripe/stripe-js/pure` is a legacy directory
specifier —
a bundler probes it for an extension, node ESM refuses it. Reaching past
it to
`pure/index.mjs` would depend on an undeclared internal path, and
importing the
non-`pure` entry would reintroduce the side-effect script injection
`/pure`
exists to avoid.

So the entry is listed in `BUNDLER_ONLY_ENTRIES` and skipped in the node
sweep
only — `tsc --module nodenext --strict` still resolves a type and a
value from
it, and the run prints `bundler-only, skipped under node` rather than
passing
silently. Every host that renders this form builds through Vite. Worth a
second
opinion on whether the exclusion is the right call or whether the entry
should
carry a different loader.

**The test split.** The 23 provider tests move to the package against
the same
Stripe mocks; their telemetry assertions become assertions on what the
form
reported. Four new tests stay in the cloud app for the binding itself —
key,
translated copy, the slotted button's disabled state, and that a phase
arriving
with no active journey is dropped. That last one is the behaviour the
old file
covered only incidentally.

## Verification

```
pnpm -C packages/account-ui test          # 18 files, 119 tests (22 in the new suite)
pnpm vitest run .../UnifiedStripePaymentSelector.test.ts          # 4 tests
pnpm vitest run .../SubscriptionAddPaymentPreviewWorkspace.test.ts # 22 tests, untouched
pnpm --filter @comfyorg/account-core smoke:pack                    # passes
pnpm -C packages/account-core run check:pack "$PWD/packages/account-ui"
  -> @comfyorg/account-ui: 34 packed files are publishable
pnpm typecheck / pnpm lint / pnpm knip    # clean
```

### Why no Playwright regression test

`9cd35ce5` carries a `fix(` subject, so the end-to-end coverage check
asks for
one. There is no route from `browser_tests/` to the line it changes.

The guard lives inside `StripePaymentForm.submit()`. In the app that
form is
reached only through `UnifiedStripePaymentSelector` →
`SubscriptionAddPaymentPreviewWorkspace`, which mounts real Stripe
Payment and
Address Elements from `js.stripe.com` in a cross-origin iframe. No spec
in
`browser_tests/` mounts Stripe Elements — the billing specs there mock
the
billing JSON and stop short of the card form — so an end-to-end test
would
first need a live publishable key and a Stripe iframe harness. Even with
one,
the window is not orderable from a browser: the guard fires only when
`onBeforeUnmount` runs between `createConfirmationToken` being issued
and its
continuation resuming, and Playwright cannot hold that call open and
close the
dialog inside it.

A unit regression test was written and deliberately not committed,
because it
cannot fail — the state it would assert against cannot occur. The first
statement of `emit()` in `@vue/runtime-core@3.5.42` is
`if (instance.isUnmounted) return`, and `instance.isUnmounted` is
already `true`
by the time any awaited continuation resumes: with the gate resolved
from inside
`onBeforeUnmount` itself, the hook sees `isUnmounted=false` and the very
next
microtask sees `true`, with zero calls reaching the parent's handler.
Asserting
on `emitted()` is worse than inconclusive — after `unmount()` it returns
`{}`,
so the assertion is green whatever the component did. The two sibling
unmount
paths that *are* observable are already covered —
`StripePaymentForm.test.ts:273` (a submit rejection resolving after
unmount) and
`:295` (an element event after unmount).

The guard is left in as defense in depth on the money path, alongside
the same
shape in `reportPhase` one screen up, but it is unreachable rather than
a live
fix. `f568762d20` then lifts the validate-then-mint
sequence into `mintConfirmationToken()` so `submit()` stays inside
fallow's
complexity threshold; that commit is a pure extraction with no behavior
change,
covered by the 22 existing tests in the suite.

## AS IS / TO BE

No UI change: the rendered form is the same markup with the same
classes, the
same Stripe Elements configuration, and the same button. The cloud app's
component keeps its props and emits, so its only caller is unchanged and
the
22 tests around that caller pass untouched — which is the evidence that
the
behaviour moved without changing.

- **AS IS** — one checkout form, reachable only from the cloud app;
`apps/billing-web` shows a hardcoded mock.
- **TO BE** — the same form in `@comfyorg/account-ui/billing/stripe`,
rendered by the cloud app through a binding, and available to
`apps/billing-web` and the Platform install.

Wiring `apps/billing-web` to it is the next PR, not this one: this is
the move, with the cloud app proving it still works.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 |
merged (Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | merged
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | merged (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | **Promote the Stripe payment UI into `account-ui`** | FE-2331 |
**this PR** |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| merged (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | merged (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | merged (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
merged (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish of `account-core`, `billing-contract`,
`ingest-types` | FE-2218 | published on `next` |
| 7 | `account-ui` joins the release tables | FE-2218 | open (Comfy-Org#17989) |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (merged Comfy-Org#17952)"]
  UIB["account-ui dist build (merged Comfy-Org#17929)"]
  DEPS["drop unpublished deps (merged Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (merged Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB["first publish: three packages on next"]
  UIPUB["account-ui joins the release tables (Comfy-Org#17989)"]
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> UIPUB
  PUB --> UIPUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style PROMO stroke:#0366d6,stroke-width:4px
```
pull Bot pushed a commit to Mu-L/ComfyUI_frontend that referenced this pull request Sep 18, 2026
…e package for release (Comfy-Org#17989)

## Why

`@comfyorg/account-ui` is the fourth package in the SDK release plan and
the
only one still held behind the `private: true` latch. The two PRs that
ADR-RELEASES-PACKAGES-0033 named as its precondition have both landed —
Comfy-Org#17929 gave it a `dist` build with declarations, Comfy-Org#17932 cut the two
workspace
dependencies that were never going to be published — and
`ci-packages-pack.yaml` has been validating its tarball on every PR
since.
Nothing has registered it for release, so the machinery that publishes
the
other three cannot see it.

The reason the ADR held it back no longer holds either. It said the
package
had "exactly one consumer inside this repository". On `main` today it
has
three — the cloud app, `apps/website` and `apps/billing-web` — and
ADR-PACKAGES-ACCOUNT-UI-0034 makes it the home of the shared payment UI
those
hosts render, with Platform as a fourth consumer that installs from npm
rather
than from this workspace. That turns its export map into an external
contract,
which is the condition the release ADR set.

## Root cause

Two latent defects, both invisible while the package was private:

1. `packages/account-ui/package.json` declared
`"@comfyorg/account-core": "workspace:*"`. pnpm rewrites that protocol
at
pack time, and `workspace:*` becomes an **exact** pin while
`workspace:^`
   becomes a caret range. ADR-0033 chose `workspace:^` for internal
   dependencies precisely so a consumer installing both `account-ui` and
`account-core` gets one copy; an exact pin makes that a lockfile
conflict
at the first divergent alpha. `account-core` already uses `workspace:^`
   for `ingest-types`; `account-ui` was the one manifest that did not.

2. `packages/account-core/scripts/smokePack.ts` packs four packages —
   `account-ui` was added to `PUBLISHED_PACKAGES` by Comfy-Org#17932 — but its
   docstring still said three.

## How

Six files, no runtime code:

- **`packages/account-ui/package.json`** — remove `private: true`, and
switch
  the `account-core` dependency to `workspace:^`.
- **`publish-package.yaml`** — `account-ui` joins the `package` choice
input
  and the npm-name resolve table.
- **`version-bump-package.yaml`** — same two places, with
`ALPHA_GATED=true`.
That is the load-bearing half: `patch` on `1.0.0-alpha.0` is `1.0.0`,
and
the merge path publishes a non-prerelease version to `latest`. The gate
rejects any increment but `pre*` with the `alpha` id, which is what
ADR-0033
  §Versioning policy requires for the hand-written packages.
- **`publish-package-on-merge.yaml`** —
`packages/account-ui/package.json`
joins the `paths` filter and the package loop that compares each
manifest's
  version against its first parent.
- **ADR-0033** — amended where it described `account-ui` as pending:
Context,
  the parameterized-table bullet, the `private` latch bullet, Versioning
  policy, Sequencing, the Positive consequence, the fourth-candidate
follow-up, and the "five or more published packages" trigger for
revisiting
Changesets. The ADR's own instruction is that promoting a package means
  amending that section and the gate together, so both move in this PR.
- **`smokePack.ts`** — the docstring's package count.

**This PR publishes nothing.** It registers the package and removes the
latch;
the first `@comfyorg/account-ui` version reaches npm only when someone
runs
`version-bump-package.yaml` for it and merges the `Release`-labelled PR
that
opens. Per the sequencing in ADR-0033 that bump comes after
`account-core`,
which is already on `next`, because `account-core` is `account-ui`'s one
runtime dependency and resolves from the registry.

## AS IS / TO BE

This is release plumbing with no user-facing surface, so there is no
screen to
capture. The observable behaviour is the published manifest and the
workflow
inputs; both are reproducible from this branch.

**AS IS** — the package could not be selected for release, and its
packed
manifest pinned the core exactly:

```
$ gh workflow view publish-package.yaml   # package choices
account-core, billing-contract, ingest-types

$ pnpm -C packages/account-ui pack && tar -xzOf *.tgz package/package.json
private: true
deps:    { "@comfyorg/account-core": "1.0.0-alpha.0" }
```

A dispatch for `account-ui` was not offered, and had the latch been
removed
alone, the `Verify package` step's own guard is what would have caught
it.

**TO BE** — measured on this branch:

```
$ pnpm -C packages/account-ui pack && tar -xzOf *.tgz package/package.json
private: <absent>
deps:    { "@comfyorg/account-core": "^1.0.0-alpha.0" }

$ pnpm -C packages/account-core run check:pack packages/account-ui
@comfyorg/account-ui: 30 packed files are publishable

$ pnpm --filter @comfyorg/account-core smoke:pack
@comfyorg/account-ui/billing:                 imported under node
@comfyorg/account-ui/auth/PasswordRules:      imported under node
@comfyorg/account-ui/auth/SocialAuthButtons:  imported under node
@comfyorg/account-ui/auth/TurnstileWidget:    imported under node
@comfyorg/account-ui/auth/regionGate:         imported under node
@comfyorg/account-ui/auth/regionProbe:        imported under node
@comfyorg/account-ui/auth/turnstileGate:      imported under node
@comfyorg/account-ui/auth/lifecycleScope:     imported under node
@comfyorg/account-ui/auth/useGenerationGuard: imported under node
@comfyorg/account-ui/package.json:            imported under node
tsc (nodenext, strict): a type and a value resolved from every entry
packed tarball smoke test passed
```

All nine entries plus the manifest import from a throwaway npm project
outside
the workspace, and `tsc` under `nodenext` resolves a type and a value
from
each. That is the proof the `private` latch was waiting on.

The alpha gate, simulated against the shipped case statement:

| package | increment | pre-id | outcome |
| --- | --- | --- | --- |
| `account-ui` | `patch` | — | rejected (would produce `1.0.0` →
`latest`) |
| `account-ui` | `minor` | `alpha` | rejected (increment) |
| `account-ui` | `prerelease` | `beta` | rejected (pre-id) |
| `account-ui` | `prerelease` | `alpha` | allowed → `1.0.0-alpha.1` |
| `ingest-types` | `patch` | — | allowed (outside the gate, by ADR) |

## Verification

- `pnpm -C packages/account-ui typecheck`, `build`, `test` (97 tests, 17
files)
- `pnpm -C packages/account-core typecheck`
- `pnpm -C packages/account-core run check:pack packages/account-ui`
- `pnpm --filter @comfyorg/account-core smoke:pack`
- `pnpm lint`, `pnpm format`, `pnpm knip`, `pnpm adr:check`
- All three workflow files parse, and the resolve table maps all four
packages
  and rejects an unknown one.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 |
merged (Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | merged
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | merged (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | open (Comfy-Org#17936) |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| merged (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | merged (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | merged (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
merged (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish of `account-core`, `billing-contract`,
`ingest-types` | FE-2218 | published on `next` |
| 7 | **`account-ui` joins the release tables** | FE-2218 | **this PR**
|
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (merged Comfy-Org#17952)"]
  UIB["account-ui dist build (merged Comfy-Org#17929)"]
  DEPS["drop unpublished deps (merged Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (merged Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB["first publish: three packages on next"]
  UIPUB["account-ui joins the release tables (Comfy-Org#17989)"]
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> UIPUB
  PUB --> UIPUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style UIPUB stroke:#0366d6,stroke-width:4px
```
@dante01yoon
dante01yoon merged commit 66f8981 into fe-2331-billing-web-subscription-actions Sep 18, 2026
107 checks passed
@dante01yoon
dante01yoon deleted the fe-2331-billing-web-reactivation-confirm branch September 18, 2026 13:05
dante01yoon added a commit that referenced this pull request Sep 18, 2026
dante01yoon added a commit that referenced this pull request Sep 18, 2026
pull Bot pushed a commit to Penguinjanator/ComfyUI_frontend that referenced this pull request Sep 18, 2026
…esult page and invoices through the portal (Comfy-Org#17936)

Linear FE-2331. Stacked on Comfy-Org#17934 → Comfy-Org#17932 → Comfy-Org#17929. Closes the
"billing-web is not yet a checkout" line in the hosted-billing TDD's
*Current state (2026-09-17)*.

## Why

`apps/billing-web` had every read it needs and exactly one write:
`openPaymentPortal`. `/v1/checkout` rendered a static mock with
`checkout-enabled` false, `/v1/result` and `/v1/invoices` rendered a
placeholder, and the subscription surface's "Pay and subscribe" button
was disabled with the copy "Payment actions will be connected through
Billing SDK." Comfy-Org#17934 put the Stripe payment form in
`@comfyorg/account-ui/billing/stripe` precisely so this app could render
it; this is the PR that does.

## How

**`/v1/checkout` — `CheckoutView`.** The entry's `plan` is quoted
through `usePreviewSubscribe`; the quote fills the summary panel (plan
name, price per period, credits, amount due today) and hands the form
its amount, currency and `payment_method_configuration_id`. The form's
confirmation token goes to `useCheckout().subscribe` together with
`plan_slug`, the quote's `quote_id` / `quote_version`, and a
`return_url` built with `buildBillingEntryUrl` pointing at this origin's
`/v1/result` with the same product, return target and plan. From then on
the page renders `CheckoutSteps` over the lifecycle's projection —
`preview` while polling, `verifying` on a challenge, `declined` /
`processing_error` with the retry that returns to the form — and the
`success` phase of the summary panel with a return link carrying
`billing_result=success&billing_ref=<op id>`. A hosted continuation
(`needs_payment_method`) redirects this tab through the composable's
`openUrl`; an embedded one drives 3DS through
`createStripeChallengePort`, which loads Stripe on the first challenge
and reports `provider_unavailable` rather than throwing when it cannot.

**`/v1/result` — `ResultView`.** Nothing about the payment travels in
the URL. On mount it calls `lifecycle.recover()` — the server's pending
operation first, then the tab's pointer — and renders `CheckoutSteps`
over whatever came back, with the return link's outcome derived from the
step (`success` / `cancelled` / `pending`) and the operation id as the
reference. "No payment in progress" when there is nothing to recover.

**`/v1/invoices` — `InvoicesView`.** Follows the cloud app: one button,
`openPaymentPortal({ returnUrl: location.href })`, `location.assign`. No
reader, no backend route, as decided on 2026-09-17.

**Subscription surface.** `SubscriptionQuote` emits `checkout`;
`SubscriptionPanel` pushes `/v1/checkout` with the entry's query plus
the chosen `plan`, so product and return target travel with it. The
button is enabled only for a quote the server `allowed`.

**Composition.** `embeddedCheckoutAvailable` now follows
`VITE_STRIPE_PUBLISHABLE_KEY` (new in `.env_example` and the README;
absent means every operation routes hosted, exactly as before).
`HostedSurface` takes a `returnResult` so a surface can put an outcome
on the trip back. `EmbeddedCheckout` keeps its summary panel and success
phase, takes the provider form through a `form` slot, and prices a
yearly plan by its own period instead of a derived per-month figure; its
mock card block, the dead promotion-code input and the `checkoutEnabled`
prop are gone. `/` becomes a plain front door ("open billing from your
Comfy product") since the scaffold's mock no longer exists.

## Review focus

**The subscribe request shape.** `plan_slug`, `confirmation_token`,
`quote_id`, `quote_version`, `return_url` — the generated
`zSubscribeRequest` accepts more (`promotion_code`,
`team_credit_stop_id`, `saved_payment_method_id`, `billing_cycle`). None
is wired here: no promotion input survives, saved cards are a later
slice, and the cycle is the plan's. Worth confirming the quote identity
is what the server expects on the hosted rail the way it is on the cloud
app's.

**`amountDueCents` falls back to `cost_today_cents`** when the quote
carries no `amount_due_cents`, on both the summary and the form's
amount. That is a display and Elements-mode amount only; the charge is
priced server-side from the quote.

**Recovery on `/v1/result` uses `useCheckout`** rather than a bare
`useBillingOperation`, so the same `openUrl` / `challengePort`
continuation runs if a recovered operation still offers one. That is
deliberate — a customer who closed the provider tab lands here and
should be able to continue — but it does mean the result page can
redirect.

## Verification

```
pnpm -C apps/billing-web typecheck     # clean
pnpm -C apps/billing-web test:unit     # 13 files, 103 tests
pnpm -C apps/billing-web lint          # clean
pnpm knip                              # clean
```

New: `CheckoutView.test.ts` (9), `ResultView.test.ts` (3),
`InvoicesView.test.ts` (2). Rewritten for the new shape:
`EmbeddedCheckout.test.ts`, `SubscriptionView.test.ts` (router-backed,
continue → checkout), `router.test.ts` and `App.test.ts` (front door).
The fake client now publishes the operation a `subscribe` or a `recover`
produces to lifecycle subscribers, so every projection the views render
is exercised through the real composables, not stubbed. The provider
form is mocked here; it is covered in the package against the real
Stripe mocks.

### Why no `browser_tests/` regression test

The two `fix(` commits on this branch repair code this same PR
introduces. `CheckoutView.vue` is added here — `git diff --name-status
origin/main...44b4f50` reports it as `A` — and both mismatches were
found in review before any of it shipped. There is no released behaviour
to regress against.

An end-to-end test is also not reachable at this point in the stack.
`browser_tests/` drives `http://localhost:8188`
(`browser_tests/fixtures/ComfyPage.ts:240`), the ComfyUI frontend served
by a ComfyUI backend, and it has no fixture that serves
`apps/billing-web` — a separate Vite app on its own origin, with its own
dev server and its own Playwright project. That project
(`apps/billing-web/e2e/`, `apps/billing-web/playwright.config.ts`,
merged as Comfy-Org#17947) is not on this branch: it arrives two PRs later, on
Comfy-Org#17943.

Both fixes are route-watcher behaviour inside one component, so
`CheckoutView.test.ts` is the level that proves them, and both tests
were mutation-checked rather than written to pass:

| test | mutation that breaks it |
| --- | --- |
| `keeps a live operation on the plan it was quoted for` | remove the
guard |
| `still quotes when the lifecycle already carries an operation at
mount` | drop the `previous` clause |

## AS IS / TO BE

- **AS IS** — `/v1/checkout`: a hardcoded "Creator, $28.00" mock with
every control disabled. `/v1/result`, `/v1/invoices`: "not available
yet". Subscription quote: a disabled pay button.
- **TO BE** — `/v1/checkout` quotes the linked plan, collects a card
through the shared form, subscribes, drives 3DS or redirects, and shows
the SDK's eight-state projection through to success with a way back.
`/v1/result` recovers and reports. `/v1/invoices` opens the portal. The
quote continues into checkout.

No production traffic reaches these pages until
`hosted_billing_destination` says `billing_web`; the Vercel project's
`VITE_STRIPE_PUBLISHABLE_KEY` is an owner action alongside the token and
the CNAME.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 |
merged (Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | merged
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | merged (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
open (Comfy-Org#17934) |
| 8 ui | **billing-web checkout, result page, invoices through the
portal** | FE-2331 | **this PR** |
| 8 ui | billing-web cancel / resubscribe on the subscription surface |
FE-2331 | open (Comfy-Org#17937) |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | open (Comfy-Org#17943) |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| merged (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | merged (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | merged (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
merged (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish of `account-core`, `billing-contract`,
`ingest-types` | FE-2218 | published on `next` |
| 7 | `account-ui` joins the release tables | FE-2218 | open (Comfy-Org#17989) |
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (merged Comfy-Org#17952)"]
  UIB["account-ui dist build (merged Comfy-Org#17929)"]
  DEPS["drop unpublished deps (merged Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (Comfy-Org#17936)"]
  SUBW["billing-web cancel / resubscribe (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (merged Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB["first publish: three packages on next"]
  UIPUB["account-ui joins the release tables (Comfy-Org#17989)"]
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> UIPUB
  PUB --> UIPUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style CHK stroke:#0366d6,stroke-width:4px
```
pull Bot pushed a commit to Mu-L/ComfyUI_frontend that referenced this pull request Sep 18, 2026
… surface, gated by the server's capabilities (Comfy-Org#17937)

Linear FE-2331. Stacked on Comfy-Org#17936 → Comfy-Org#17934 → Comfy-Org#17932 → Comfy-Org#17929. The last
write action `apps/billing-web` was missing.

## Why

After Comfy-Org#17936 the hosted app could subscribe, pay and recover, but a
customer on `/v1/subscription` still had no way to leave a plan or come
back to one: the surface listed plans and quoted a change, nothing else.
Cancel and resubscribe exist on the SDK (`commands.cancelSubscription`,
`useCheckout().resubscribe`) and ride the cloud app's rail since Comfy-Org#17853;
this gives the hosted surface the same two actions.

## How

`SubscriptionActions.vue`, rendered under the current-plan line:

- **Gated by the server, not by local state.** On mount it reads
`capabilities` and offers *Cancel subscription* only for `can_cancel`,
*Resubscribe* only for `can_reactivate`. Neither button exists for a
workspace the server says cannot do it, which is the same rule the cloud
app's popover follows.
- **Cancel confirms first.** One click shows "Cancel your subscription?
You can resubscribe at any time." with *Confirm cancellation* / *Keep my
plan*; only the confirmation calls `commands.cancelSubscription()`.
Cancel is not a checkout, so it goes straight to the command, as
`useCheckout`'s own docstring says it should.
- **Resubscribe runs on `useCheckout`**, because the server may answer
with a payment step; the composable's continuation redirects this tab to
the hosted page (or drives 3DS through `createStripeChallengePort` when
a key is configured), and `/v1/result` recovers on the way back — the
path Comfy-Org#17936 built.
- **After either succeeds**, the panel invalidates and re-reads
capabilities with `forceRefresh` (so the buttons flip immediately) and
emits `changed`, on which the panel refreshes the plan catalog (so the
current-plan line follows). A non-`succeeded` terminal phase and every
coded failure render our own copy: new `hosted.outcome.*` lines for
`failed` / `timed_out` / `reconciliation_needed` / `superseded`, and
three `hosted.failure` codes the subscription commands can return that
had no line yet (`REACTIVATION_CONFIRMATION_REQUIRED`,
`CONFLICTING_PAYMENT_METHOD`, `MISSING_PAYMENT_METHOD_URL`).

## Review focus

**`REACTIVATION_CONFIRMATION_REQUIRED` is surfaced, not handled.** The
server asks the host to re-preview and resend with
`confirm_reactivation`; here it reads as "Confirm the reactivation
charge before continuing" and stops. Wiring the confirm loop is a
follow-up — the cloud app's equivalent lives in
`useSubscriptionCheckout` and is not small.

**The fake client now answers `capabilities.read`** with every
capability denied unless a test grants one, and scripts
`cancelSubscription` / `resubscribe` like `subscribe`. That is what lets
the existing `SubscriptionView` tests keep passing unchanged (no buttons
appear for them) while the five new ones exercise the gate, the confirm
step, the back-out, resubscribe, and a refused cancel.

## Verification

```
pnpm -C apps/billing-web typecheck   # clean
pnpm -C apps/billing-web test:unit   # 13 files, 108 tests (+5)
pnpm -C apps/billing-web lint        # clean
```

## Why the regression coverage is not under `browser_tests/`

`browser_tests/` is the ComfyUI graph editor's suite: the root
`playwright.config.ts` points `testDir` at it, and `ci-tests-e2e.yaml`
runs it inside `comfyui-ci-container` with a live ComfyUI Python server
started per job. `apps/billing-web` is a separate Vite entry with no
ComfyUI backend behind it, so a spec placed under `browser_tests/`
cannot load the surface this PR changes.

The equivalent end-to-end coverage lives in `apps/billing-web/e2e`,
against a Cloud and identity the suite mocks in-process, and runs on
this PR through `ci-billing-web-e2e.yaml`: `subscription.spec.ts` covers
*cancels after a confirmation step and then offers to resubscribe* and
*shows only the actions the server allows*. The capability-refresh hold
that `fix(billing-web): hold the subscription actions through the
capability refresh` addressed is pinned by *keeps the action disabled
until the capability refresh lands* in `SubscriptionView.test.ts`.

## AS IS / TO BE

- **AS IS** — `/v1/subscription` shows the catalog and a quote; the only
write reachable from the hosted app is the payment portal.
- **TO BE** — the surface offers cancel (with confirmation) and
resubscribe exactly when the server permits them, runs both on the SDK
commands, and refreshes what the change touched.

No UI reaches production until `hosted_billing_destination` says
`billing_web`.

## Where this sits in the plan

Billing SDK track FE-2210 ([implementation plan
V2](https://app.notion.com/p/3d86d73d36508152b92cdbdfdfe83ac8));
remaining work on FE-2216 / FE-2217 / FE-2218 / FE-2331.

| Phase | Item | Ticket | Status |
| --- | --- | --- | --- |
| 7 | What belongs in `@comfyorg/account-ui` (ADR-0034) | FE-2218 |
merged (Comfy-Org#17927) |
| 7 | billing-web Vercel deployment config | FE-2218 | merged (Comfy-Org#17788) |
| 7 | Package release workflows + versioning ADR | FE-2218 | merged
(Comfy-Org#17881) |
| 7 | Publish report through a `workflow_run` consumer | FE-2218 |
merged (Comfy-Org#17952) |
| 7 | `account-ui` builds to dist and packs clean | FE-2218 | merged
(Comfy-Org#17929) |
| 7 | `account-ui` drops its unpublished dependencies, joins
`smoke:pack` | FE-2218 | merged (Comfy-Org#17932) |
| 7 | billing-web report-only CSP and framing denial | FE-2218 | merged
(Comfy-Org#17941) |
| 8 ui | Promote the Stripe payment UI into `account-ui` | FE-2331 |
merged (Comfy-Org#17934) |
| 8 ui | billing-web checkout, result page, invoices through the portal
| FE-2331 | merged (Comfy-Org#17936) |
| 8 ui | **billing-web cancel / resubscribe on the subscription
surface** | FE-2331 | **this PR** |
| 8 ui | billing-web reactivation confirmation, refused subscribe
surfaced | FE-2331 | squashed into Comfy-Org#17937 — **not on `main`** |
| 8 ui | billing-web Playwright harness against a mocked Cloud | FE-2218
| merged (Comfy-Org#17947) |
| 9 | Status and balance reads on the rail | FE-2216 | merged (Comfy-Org#17940) |
| 9 | Plan catalog read on the rail | FE-2216 | merged (Comfy-Org#17942) |
| 9 | Capabilities and saved payment methods on the rail | FE-2216 |
merged (Comfy-Org#17946) |
| 9 | Legacy `billingOperationStore` removal | FE-2216 | after the flags
flip |
| 7 | First publish of `account-core`, `billing-contract`,
`ingest-types` | FE-2218 | published on `next` |
| 7 | `account-ui` joins the release tables | FE-2218 | merged (Comfy-Org#17989)
|
| 7 | Phase 7 host proof: live top-up on billing.comfy.org | FE-2218 |
gated (flags, CNAME, key) |
| 6 | Phase 6 live E2E evidence table | FE-2217 | gated (staging flags)
|

```mermaid
flowchart LR
  ADR["ADR-0034 (merged)"]
  REL["release workflows + ADR-0033 (merged Comfy-Org#17881)"]
  PUBREP["publish report via workflow_run (merged Comfy-Org#17952)"]
  UIB["account-ui dist build (merged Comfy-Org#17929)"]
  DEPS["drop unpublished deps (merged Comfy-Org#17932)"]
  CSP["billing-web CSP (merged Comfy-Org#17941)"]
  PROMO["Stripe payment form in account-ui (merged Comfy-Org#17934)"]
  CHK["billing-web checkout + result + invoices (merged Comfy-Org#17936)"]
  SUBW["cancel / resubscribe + reactivation (Comfy-Org#17937)"]
  REACT["reactivation confirmation (Comfy-Org#17943, inside Comfy-Org#17937)"]
  E2E["billing-web Playwright harness (Comfy-Org#17947)"]
  RD1["status + balance on the rail (Comfy-Org#17940)"]
  RD2["plans on the rail (Comfy-Org#17942)"]
  RD3["capabilities + payment methods on the rail (merged Comfy-Org#17946)"]
  LEG(["legacy store removal, after the flags"])
  PUB["first publish: three packages on next"]
  UIPUB["account-ui release tables (merged Comfy-Org#17989)"]
  H(["Phase 7 host proof"])
  E(["Phase 6 evidence"])
  OW{{"OWNER staging flags, CNAME, Stripe key"}}
  ADR --> PROMO
  UIB --> DEPS --> PROMO --> CHK --> SUBW --> REACT --> E2E
  REL --> PUBREP
  REL --> PUB
  DEPS --> UIPUB
  PUB --> UIPUB
  RD1 --> RD2 --> RD3 --> LEG
  CHK --> H
  CSP --> H
  OW -.-> H
  OW -.-> E
  OW -.-> LEG
  style ADR fill:#d4edda,stroke:#155724
  style REL fill:#d4edda,stroke:#155724
  style CSP fill:#d4edda,stroke:#155724
  style SUBW stroke:#0366d6,stroke-width:4px
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk:xhigh PR risk grade (advisory shadow check; grader-owned)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants