Repository navigation
feat(onboarding): show job title eligibility statements for maybe and not eligible roles - #1508
Merged
gabrielseco merged 2 commits intoOct 12, 2026
Merged
Conversation
… not eligible roles When the job_title_eligibility check returns needs_review (maybe) or not_eligible (no), render an info or error statement under role_description on contract details, mirroring Dragon's ineligible role message. The statement follows re-checks and is removed once the role is eligible. Submit is not blocked; the backend still decides. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Contributor
📦 Bundle Size Report
Size Limits
Largest Files (Top 5)
View All Files (291 total)
✅ Bundle size check passed |
Contributor
|
Deploy preview for remote-flows ready!
Deployed with vercel-action |
Contributor
|
Deploy preview for adp-cost-calculator ready!
Deployed with vercel-action |
Contributor
📊 Coverage Report✅ Coverage increased! 🎉
Detailed BreakdownLines Coverage
Statements Coverage
Functions Coverage
Branches Coverage
✅ Coverage check passed |
…e combined Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
cammellos
approved these changes
Oct 12, 2026
gabrielseco
deleted the
feat/onboarding-job-title-eligibility-statements
branch
October 12, 2026 08:17
This was referenced Oct 12, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
When the job title eligibility check on contract details returns
needs_reviewornot_eligible, the Onboarding flow now shows a statement under Role description telling the partner what that means.Why
Since #1413 the SDK runs the check and stores its result in
additional_job_title_eligibility_check_result, but onlyyes_with_ackchanges the UI (the risk acknowledgement). Anoormayberesult showed nothing, so partners had no idea the role couldn't be hired, or was still uncertain.Dragon already shows an error statement under
role_descriptionwhen the result isno(employer/contractDetails/jsfModify.jsx). The backend doesn't send a message formaybeyet, so we add one on the SDK side. Both messages are worded the same way and say "AI" rather than "Remote AI".needs_reviewmaybenot_eligiblenoOther verdicts show nothing. Submit isn't blocked on
no; the backend still decides, same as Dragon.What changed
Toggle details
src/flows/Onboarding/utils.ts: addsgetJobTitleEligibilityStatement(result, countryName), which returns acreateStatementPropertyformaybeandno. If there's no country name, the title says "in this country".src/flows/Onboarding/hooks.tsx: whenjob_title_eligibilityis enabled,role_descriptiongets acalculateDynamicPropertiesthat adds the statement. It goes through the same contract details custom-fields override asequity_compensationanddaily_schedule, so it covers both the JSF v0 and v1 contract details. If an integrator already has acalculateDynamicPropertiesonrole_descriptionin theirjsfModify, theirs still runs and the results are merged. The statement renders throughcomponents.statement, so partners can override how it looks.OnboardingFlowJobTitleEligibility.test.tsx: 4 new tests, each run against the v0 and v1 schemas:maybeshows the info statement,noshows the error statement,eligibleshows nothing, and a re-check switches the statement and then removes it once eligible. They fail without the hook change.Public API: no type or signature changes. The new statements only show when the
job_title_eligibilityfeature is on.Screenshots
Open as a gallery: click a screenshot, then use the arrow keys.
Maybe needs review info statement
No not eligible error statement
Verified against the sandbox gateway with a seeded USA employment and the real AI check (example app,
onboarding-basicdemo): 100 lines of gibberish as the role description returnedneeds_review; a licensed, onsite surgical role returnednot_eligible.Related Resources
domains/shared/employment/employer/contractDetails/jsfModify.jsx(role_descriptionstatement onINELIGIBLE),jobTitleEligibility/components/IneligibleRoleMessage.tsx🤖 Generated with Claude Code
Note
Low Risk
UI-only messaging gated by an existing feature flag; submit behavior is unchanged and partner
jsfModifyhooks are preserved via merge.Overview
Job title eligibility feedback on contract details — When
job_title_eligibilityis enabled, partners now see inline statements under Role description for uncertain or blocked roles, not only the existing risk-acknowledgement path.getJobTitleEligibilityStatementmaps stored check resultsmaybe(needs_review) andno(not_eligible) to info and error statements (country-aware titles, “AI” wording aligned with Dragon). Eligible and other verdicts still show nothing.Onboarding wires this through
role_description’scalculateDynamicPropertiesin contract-details custom fields (JSF v0 and v1), merging with any partnerjsfModifyhook on that field. Tests cover info/error/no-message cases and statement updates when re-checks change the verdict.Reviewed by Cursor Bugbot for commit 1ddb34e. Bugbot is set up for automated code reviews on this repo. Configure here.