Problem
The agent/NGO profile header shows a "Responsiveness" status row (the trustLevel field — i18n key dashboard.agentProfile.trustLevel → "Responsiveness") even when an NGO is viewing their own profile. This is meant to be an internal coordinator/admin-facing metric and shouldn't be visible to NGO users at all.
Looking at src/components/Dashboard/Profile/sections/ProfileHeader/agent/AgentHeader.tsx, the editable TrustLevelDropdown is already correctly gated behind isAuthorized:
<StatusRowField
title={t("dashboard.agentProfile.trustLevel")}
extra={
isAuthorized && (
<TrustLevelDropdown ... />
)
}
/>
But the StatusRowField itself — including its "Responsiveness" title — always renders; only the dropdown content inside extra is conditional. So an unauthorized viewer (an NGO viewing their own profile) still sees the row, just with an empty "–" value, instead of the row being hidden entirely.
Steps to reproduce
- Log in as an NGO/agent user
- View your own profile
- Observe the "Responsiveness" row shows "–", directly above the District row
Expected
The entire "Responsiveness" row should be hidden from NGO self-view — visible only to coordinators/admins. Likely fix: wrap the whole StatusRowField (not just its extra content) in the isAuthorized check.
Problem
The agent/NGO profile header shows a "Responsiveness" status row (the
trustLevelfield — i18n keydashboard.agentProfile.trustLevel→ "Responsiveness") even when an NGO is viewing their own profile. This is meant to be an internal coordinator/admin-facing metric and shouldn't be visible to NGO users at all.Looking at
src/components/Dashboard/Profile/sections/ProfileHeader/agent/AgentHeader.tsx, the editableTrustLevelDropdownis already correctly gated behindisAuthorized:But the
StatusRowFielditself — including its "Responsiveness" title — always renders; only the dropdown content insideextrais conditional. So an unauthorized viewer (an NGO viewing their own profile) still sees the row, just with an empty "–" value, instead of the row being hidden entirely.Steps to reproduce
Expected
The entire "Responsiveness" row should be hidden from NGO self-view — visible only to coordinators/admins. Likely fix: wrap the whole
StatusRowField(not just itsextracontent) in theisAuthorizedcheck.