How energyshifter8/survey-filling-site works
This is a Mongolian-language survey and invitation-based talent-assessment frontend. Participants enter a survey or talent invitation, review consent and any required setup, answer questions or assessment sections, and submit their responses. Survey and recruitment flows use separate hooks and API modules; browser session storage preserves survey progress and recruitment state. The graph reflects documented imports and the sampled calls; some assessment details and tracking behavior are unsampled, so their relationships are not inferred.
Main entry points: [token]/page.tsx Talent invitation · [shortUrl]/page.tsx Survey landing · questions/page.tsx Survey questions · use-survey.ts Survey workflow
Components 24
Survey experience
- Survey landing
src/app/s/[shortUrl]/page.tsx - Survey questions
src/app/s/[shortUrl]/questions/page.tsx - Survey completion
src/app/s/[shortUrl]/end/page.tsx - Question fields
src/components/QuestionField.tsx - Survey flow
SurveyFlow.jsx
Talent assessment
- Talent invitation
src/app/talent/[token]/page.tsx - Fullscreen controls
src/components/TalentFullscreen.tsx - Talent status screens
src/components/TalentScreens.tsx - Recruitment flow
RecruitmentTestFlow.jsx - Talent tracking
src/lib/talent-tracking.ts
Shared interface
- Consent modal
src/components/ConsentModal.tsx - Font-size toggle
src/components/FontSizeToggle.tsx - Font-size state
src/lib/font-size-context.tsx
API and state
- Survey workflow
src/lib/use-survey.ts - Recruitment workflow
src/lib/use-recruitment.ts - Survey API
src/lib/api/survey.ts - Recruitment API
src/lib/api/recruitment.ts - Fetch client
src/lib/api/client.ts - Survey session state
src/lib/survey-session.ts - Recruitment session state
src/lib/recruitment-session.ts - Browser session storage
Other components
- Participant
- Survey backend
- Recruitment backend
Connections 26
- Participant → Survey landing: opens survey
src/app/s/[shortUrl]/page.tsx - Survey landing → Consent modal: requests consent
src/app/s/[shortUrl]/page.tsx - Survey landing → Survey workflow: starts session
src/app/s/[shortUrl]/page.tsx - Survey landing → Survey questions: routes to
src/app/s/[shortUrl]/page.tsx - Survey questions → Survey workflow: loads and submits
src/app/s/[shortUrl]/questions/page.tsx - Survey questions → Question fields: renders
src/app/s/[shortUrl]/questions/page.tsx - Survey questions → Survey session state: uses progress
src/app/s/[shortUrl]/questions/page.tsx - Survey completion → Survey API: submits completion
src/app/s/[shortUrl]/end/page.tsx - Survey workflow → Survey API: calls
src/lib/use-survey.ts - Survey workflow → Survey session state: persists session
src/lib/use-survey.ts - Survey API → Fetch client: sends requests
src/lib/api/survey.ts - Fetch client → Survey backend: HTTP requests
- Survey session state → Browser session storage: reads and writes
src/lib/survey-session.ts - Participant → Talent invitation: opens invitation
src/app/talent/[token]/page.tsx - Talent invitation → Consent modal: requests consent
src/app/talent/[token]/page.tsx - Talent invitation → Fullscreen controls: controls fullscreen
src/app/talent/[token]/page.tsx - Talent invitation → Talent status screens: renders status
src/app/talent/[token]/page.tsx - Talent invitation → Recruitment workflow: loads invitation
src/app/talent/[token]/page.tsx - Recruitment workflow → Recruitment API: calls
src/lib/use-recruitment.ts - Recruitment workflow → Recruitment session state: persists state
src/lib/use-recruitment.ts - Recruitment API → Fetch client: sends requests
src/lib/api/recruitment.ts - Fetch client → Recruitment backend: HTTP requests
- Recruitment session state → Browser session storage: reads and writes
- Survey flow → Survey backend: uses client
- Recruitment flow → Recruitment backend: uses client
- Font-size toggle → Font-size state: reads and updates
src/components/FontSizeToggle.tsx