refactor: update vessel registration route and clarify navigation logic in OperationsOnboardingPage

This commit is contained in:
estifanos
2026-08-18 11:36:35 +00:00
parent 2257989821
commit 1509f8ca1f

View File

@@ -5,16 +5,20 @@ import { OperationsFormContent } from '../../profile/components/OperationsFormCo
/**
* Where a fresh applicant lands after declaring themselves. Someone who says
* "I own a vessel" came here to register, so they are taken straight to that
* form instead of a dashboard that only links to it. A seafarer goes to
* `/profile` instead — registration is built from the profile
* "I own a vessel" came here to register, so they are taken to that service's
* own page — which lists what they already hold and starts the application —
* rather than dropped straight into the wizard with no way back. A seafarer
* goes to `/profile` instead — registration is built from the profile
* (`RequireSeafarerProfile`), and a brand-new signup has none of it yet, so
* sending them straight to the wizard would only bounce them back here.
* Seafarer wins when both are ticked; the other form is one nav click away.
* Seafarer wins when both are ticked; the other page is one nav click away.
*
* A licence type with no page of its own falls through to the dashboard,
* where the catalogue offers it.
*/
const NEXT_STEP: Record<string, string> = {
SEAFARER_REGISTRATION: '/profile',
VESSEL_REGISTRATION: '/licensing/VESSEL_REGISTRATION/apply',
VESSEL_REGISTRATION: '/vessel-registration',
};
function nextStepFor(selectedKeys: string[]): string {