Add Photos onboarding step; let pending/rejected users re-edit freely

- New /onboarding/photos step (upload/delete grid, needs >=1 photo to
  continue), inserted as step 2 right after basic info.
- Pending screen gets an "edit your info" entry point into the wizard;
  Rejected screen's edit button now goes there too instead of just
  the read-only profile page.
- Step 1's back button now returns to /home instead of /login when
  the user is already onboarded (was previously always /login).
- Progress bar segments become clickable to jump directly to any step
  once the user is already onboarded.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-16 09:22:32 +03:30
parent 501fa294f4
commit dca8c5e9e3
6 changed files with 168 additions and 18 deletions
+5
View File
@@ -342,6 +342,11 @@ export function submitBasicInfo(payload: {
});
}
// خودِ عکس‌ها با uploadPhoto/deletePhoto آپلود می‌شن؛ این فقط مرحله رو تایید/رد می‌کنه
export function confirmPhotosStep() {
return authRequest<OnboardingStatus>("/onboarding/photos", { method: "POST" });
}
export function submitBodyInfo(payload: { height_cm: number; weight_kg: number }) {
return authRequest<OnboardingStatus>("/onboarding/body-info", {
method: "POST",