# ali-hmed/netsom-desk-mobile architecture

> Architecture diagram of the GitHub repository ali-hmed/netsom-desk-mobile, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-27). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ali-hmed/netsom-desk-mobile
- Repository: https://github.com/ali-hmed/netsom-desk-mobile

## Overview

This is a mobile workspace and task-management app. A user enters through onboarding or sign-in, restores or establishes a session, then works within a selected workspace across dashboard, tasks, calendar, analytics, todos, team, inbox, and profile screens. The sampled task screen loads and edits workspace tasks through a service backed by the remote API; authentication also persists credentials and workspace selection securely. The README is empty, and several routes were not sampled, so their capabilities are represented from the route tree without assuming internal calls.

Main entry points: [`services/workspace.service.ts`](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/workspace.service.ts) (Workspace service), [`services/auth.service.ts`](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/auth.service.ts) (Authentication service), [`app/index.tsx`](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/index.tsx) (Initial routing), [`services/secure-store.service.ts`](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/secure-store.service.ts) (Secure storage)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Entry and account"]
  node_entrypoint["Initial routing<br/>[index.tsx]"]
  node_onboarding["Onboarding<br/>[onboarding.tsx]"]
  node_login["Sign in<br/>[login.tsx]"]
  node_register["Registration<br/>[register.tsx]"]
  node_authservice["Authentication service<br/>[auth.service.ts]"]
  node_profile["Profile<br/>[profile.tsx]"]
end

subgraph group_work["Workspace operations"]
  node_dashboard["Dashboard<br/>[dashboard.tsx]"]
  node_tasks["Task management<br/>[tasks.tsx]"]
  node_calendar["Calendar<br/>[calendar.tsx]"]
  node_analytics["Analytics<br/>[analytics.tsx]"]
  node_todos["To-dos<br/>[todos.tsx]"]
  node_team["Team management<br/>[team.tsx]"]
  node_inbox["Notifications inbox<br/>[inbox.tsx]"]
  node_workspaceui["Workspace controls"]
end

subgraph group_state["Session and preferences"]
  node_authstore["Auth state<br/>[useAuthStore.ts]"]
  node_secure["Secure storage"]
  node_themehook["Theme resolution<br/>[useTheme.ts]"]
  node_themestore["Theme preference<br/>[useThemeStore.ts]"]
end

subgraph group_transport["Backend access"]
  node_workspace["Workspace service"]
  node_api["API client<br/>[api.ts]"]
end

node_user(("Mobile user"))
node_backend[("Application backend")]

node_user -->|"opens app"| node_entrypoint
node_entrypoint -->|"reads token"| node_secure
node_entrypoint -->|"restores session"| node_authservice
node_entrypoint -->|"routes on success"| node_dashboard
node_entrypoint -->|"routes otherwise"| node_onboarding
node_onboarding -->|"opens sign-in"| node_login
node_login -->|"signs in"| node_authservice
node_register -->|"registers account"| node_authservice
node_authservice -->|"requests auth"| node_api
node_authservice -->|"persists session"| node_secure
node_authservice -->|"updates session"| node_authstore
node_authservice -->|"calls endpoints"| node_backend
node_user -->|"views workspace"| node_dashboard
node_dashboard -->|"loads metrics"| node_workspace
node_tasks -->|"loads and edits tasks"| node_workspace
node_calendar -->|"loads appointments"| node_workspace
node_todos -->|"manages todos"| node_workspace
node_analytics -->|"loads workspace data"| node_workspace
node_team -->|"manages members"| node_workspace
node_inbox -->|"handles notifications"| node_workspace
node_workspaceui -->|"manages workspaces"| node_workspace
node_workspaceui -->|"updates selection"| node_authstore
node_workspaceui -->|"stores selection"| node_secure
node_workspace -->|"sends requests"| node_api
node_api -->|"transfers data"| node_backend
node_profile -->|"uses account operations"| node_authservice
node_themehook -->|"reads preference"| node_themestore
node_themestore -->|"persists preference"| node_secure

click node_entrypoint "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/index.tsx"
click node_onboarding "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/onboarding.tsx"
click node_login "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(auth)/login.tsx"
click node_register "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(auth)/register.tsx"
click node_authservice "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/auth.service.ts"
click node_profile "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/profile.tsx"
click node_dashboard "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/dashboard.tsx"
click node_tasks "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/tasks.tsx"
click node_calendar "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/calendar.tsx"
click node_analytics "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/analytics.tsx"
click node_todos "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/todos.tsx"
click node_team "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/team.tsx"
click node_inbox "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/inbox.tsx"
click node_workspaceui "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/components/ui/WorkspaceScreen.tsx"
click node_workspace "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/workspace.service.ts"
click node_api "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/api.ts"
click node_authstore "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/store/useAuthStore.ts"
click node_secure "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/secure-store.service.ts"
click node_themehook "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/hooks/useTheme.ts"
click node_themestore "https://github.com/ali-hmed/netsom-desk-mobile/blob/main/store/useThemeStore.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_entrypoint,node_onboarding,node_login,node_register,node_authservice,node_profile,node_user toneBlue
class node_dashboard,node_tasks,node_calendar,node_analytics,node_todos,node_team,node_inbox,node_workspaceui,node_backend toneAmber
class node_authstore,node_secure,node_themehook,node_themestore toneMint
class node_workspace,node_api toneRose
```

## Components

### Entry and account

- [Initial routing](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/index.tsx): `app/index.tsx`
- [Onboarding](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/onboarding.tsx): `app/onboarding.tsx`
- [Sign in](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(auth)/login.tsx): `app/(auth)/login.tsx`
- [Registration](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(auth)/register.tsx): `app/(auth)/register.tsx`
- [Authentication service](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/auth.service.ts): `services/auth.service.ts`
- [Profile](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/profile.tsx): `app/profile.tsx`

### Workspace operations

- [Dashboard](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/dashboard.tsx): `app/(tabs)/dashboard.tsx`
- [Task management](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/tasks.tsx): `app/(tabs)/tasks.tsx`
- [Calendar](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/calendar.tsx): `app/(tabs)/calendar.tsx`
- [Analytics](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/analytics.tsx): `app/(tabs)/analytics.tsx`
- [To-dos](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/todos.tsx): `app/(tabs)/todos.tsx`
- [Team management](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/(tabs)/team.tsx): `app/(tabs)/team.tsx`
- [Notifications inbox](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/app/inbox.tsx): `app/inbox.tsx`
- [Workspace controls](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/components/ui/WorkspaceScreen.tsx): `components/ui/WorkspaceScreen.tsx`

### Session and preferences

- [Auth state](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/store/useAuthStore.ts): `store/useAuthStore.ts`
- [Secure storage](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/secure-store.service.ts): `services/secure-store.service.ts`
- [Theme resolution](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/hooks/useTheme.ts): `hooks/useTheme.ts`
- [Theme preference](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/store/useThemeStore.ts): `store/useThemeStore.ts`

### Backend access

- [Workspace service](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/workspace.service.ts): `services/workspace.service.ts`
- [API client](https://github.com/ali-hmed/netsom-desk-mobile/blob/main/services/api.ts): `services/api.ts`

### Other components

- **Mobile user**
- **Application backend**

## Connections

- Mobile user → Initial routing: opens app
- Initial routing → Secure storage: reads token
- Initial routing → Authentication service: restores session
- Initial routing → Dashboard: routes on success
- Initial routing → Onboarding: routes otherwise
- Onboarding → Sign in: opens sign-in
- Sign in → Authentication service: signs in
- Registration → Authentication service: registers account
- Authentication service → API client: requests auth
- Authentication service → Secure storage: persists session
- Authentication service → Auth state: updates session
- Authentication service → Application backend: calls endpoints
- Mobile user → Dashboard: views workspace
- Dashboard → Workspace service: loads metrics
- Task management → Workspace service: loads and edits tasks
- Calendar → Workspace service: loads appointments
- To-dos → Workspace service: manages todos
- Analytics → Workspace service: loads workspace data
- Team management → Workspace service: manages members
- Notifications inbox → Workspace service: handles notifications
- Workspace controls → Workspace service: manages workspaces
- Workspace controls → Auth state: updates selection
- Workspace controls → Secure storage: stores selection
- Workspace service → API client: sends requests
- API client → Application backend: transfers data
- Profile → Authentication service: uses account operations
- Theme resolution → Theme preference: reads preference
- Theme preference → Secure storage: persists preference
