Skip to content

fix(contractor-onboarding) - handle empty contractor subscriptions#1016

Merged
gabrielseco merged 8 commits into
mainfrom
handle-empty-contractor-subscriptions
May 14, 2026
Merged

fix(contractor-onboarding) - handle empty contractor subscriptions#1016
gabrielseco merged 8 commits into
mainfrom
handle-empty-contractor-subscriptions

Conversation

@gabrielseco
Copy link
Copy Markdown
Collaborator

@gabrielseco gabrielseco commented May 14, 2026

Handles empty contractor subscriptions and avoids letting people advance...

Note

Medium Risk
Touches pricing-plan selection/validation and dynamically alters JSON-schema required behavior, which can affect onboarding progression and form validation flows. Changes are localized and covered by a new regression test, but mistakes could block users from continuing.

Overview
Handles cases where contractor subscription options are empty after filtering/exclusions.

The pricing-plan UI now renders an explicit empty state ("No available subscriptions") when no options exist, and the contractor subscription schema builder conditionally removes subscription from required via a new jsfModify.required function capability.

On submission, the pricing_plan step now blocks progression with clearer errors when there are no available contractor subscriptions or when a selection is missing, and tests add coverage to ensure users cannot advance when all products are excluded.

Reviewed by Cursor Bugbot for commit 72cdc88. Bugbot is set up for automated code reviews on this repo. Configure here.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 14, 2026

📦 Bundle Size Report

Metric Current Previous Change Status
Total (gzip) 211.77 kB 211.61 kB +154 B (+0.1%) 🔴
Total (raw) 573.41 kB 573.01 kB +391 B (+0.1%) 🔴
CSS (gzip) 20.86 kB 20.86 kB 0 B (0%) 🟢
CSS (raw) 108.83 kB 108.83 kB 0 B (0%) 🟢

Size Limits

  • ✅ Total gzipped: 211.77 kB / 250 kB (84.7%)
  • ✅ Total raw: 573.41 kB / 600 kB (95.6%)
  • ✅ CSS gzipped: 20.86 kB / 25 kB (83.4%)

Largest Files (Top 5)

  1. chunk-5BU3CD2P.js - 14 kB (0 B (0%))
  2. styles.css - 10.43 kB (0 B (0%))
  3. index.css - 10.43 kB (0 B (0%))
  4. index.js - 6.1 kB (-1 B (-0.0%))
  5. chunk-TNQKP2XT.js - 5.89 kB (0 B (0%))
View All Files (312 total)
File Size (gzip) Change
chunk-5BU3CD2P.js 14 kB 0 B (0%)
styles.css 10.43 kB 0 B (0%)
index.css 10.43 kB 0 B (0%)
index.js 6.1 kB -1 B (-0.0%)
chunk-TNQKP2XT.js 5.89 kB 0 B (0%)
chunk-G3R6J4Q7.js 5.81 kB new
chunk-JXAAON7I.js 5.26 kB 0 B (0%)
chunk-J4NCN3TG.js 4.62 kB 0 B (0%)
chunk-Y5VOSPJG.js 4.44 kB new
chunk-72K4C6OR.js 4.06 kB 0 B (0%)

✅ Bundle size check passed

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 14, 2026

Deploy preview for remote-flows ready!

Project:remote-flows
Status: ✅  Deploy successful!
Preview URL:https://remote-flows-32j00gjm4-remotecom.vercel.app
Latest Commit:72cdc88
Inspect:View deployment

Deployed with vercel-action

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 3 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 28ea403. Configure here.

Comment thread src/flows/ContractorOnboarding/hooks.tsx
Comment thread example/src/ContractorOnboarding.tsx Outdated
Comment thread src/flows/ContractorOnboarding/hooks.tsx
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 14, 2026

📊 Coverage Report

✅ Coverage increased! 🎉

Metric Current Previous Change Status
Lines 90.05% 89.99% +0.06% 🟢
Statements 89.72% 89.66% +0.06% 🟢
Functions 87.73% 87.71% +0.02% 🟢
Branches 80.08% 80.04% +0.04% 🟢

Detailed Breakdown

Lines Coverage
  • Covered: 3692 / 4100
  • Coverage: 90.05%
  • Change: +0.06% (14 lines)
Statements Coverage
  • Covered: 3753 / 4183
  • Coverage: 89.72%
  • Change: +0.06% (14 statements)
Functions Coverage
  • Covered: 1001 / 1141
  • Coverage: 87.73%
  • Change: +0.02% (2 functions)
Branches Coverage
  • Covered: 2299 / 2871
  • Coverage: 80.08%
  • Change: +0.04% (14 branches)

✅ Coverage check passed

@gabrielseco gabrielseco self-assigned this May 14, 2026
@gabrielseco gabrielseco changed the title Handle empty contractor subscriptions fix(contractor-onboarding) - handle empty contractor subscriptions May 14, 2026
@gabrielseco gabrielseco merged commit ebdd160 into main May 14, 2026
10 checks passed
@gabrielseco gabrielseco deleted the handle-empty-contractor-subscriptions branch May 14, 2026 15:25
jordividaller pushed a commit that referenced this pull request May 15, 2026
…1016)

* fix(contractor-onboarding) - fix logic

* fix

* revert

* fix(contractor-onboarding) - fix submission

* fix

* remove example

* remove code
@gabrielseco gabrielseco mentioned this pull request May 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants