clean up UserArea, UserSettingsProfilePage, user header, updateUser mutation
Created by: sqs
This is mostly a cleanup of tech debt.
- Move the user event log tab into the user settings sidebar. Let's use the tabs (which are quite prominent) in the user area for things that users need in their usual workflow, not for site admin and audit stuff.
- Make the GraphQL mutation
updateUser
return aUser
instead ofEmptyResponse
so the caller can get the newly updated user in the same query. This is how most of our other mutations work. - Clean up the UserArea code: make it a function component, remove needless props, etc.
- Clean up the page for editing a user's profile.
The GraphQL change is technically a breaking change, but I don't see any usage of the updateUser
mutation outside of the app itself. The src
CLI does not expose a command for updateUser
either.
Merge request reports
Activity
Created by: sourcegraph-bot
Notifying subscribers in CODENOTIFY files for diff e4958b671babc04d515ab4dda52d0a6b4f1ab1c7...ca2f3ea6b94d4c945719dd9d8973ad7b52db60e5.
Notify File(s) @eseliger client/web/src/integration/campaigns.test.ts Created by: codecov[bot]
Codecov Report
Merging #14397 into main will decrease coverage by
0.00%
. The diff coverage is90.58%
.@@ Coverage Diff @@ ## main #14397 +/- ## ========================================== - Coverage 52.21% 52.20% -0.01% ========================================== Files 1554 1556 +2 Lines 79363 79296 -67 Branches 7098 6980 -118 ========================================== - Hits 41437 41395 -42 + Misses 34179 34154 -25 Partials 3747 3747
Flag Coverage Δ #go 52.42% <100.00%> (+<0.01%)
#integration 30.40% <89.02%> (-0.19%)
#storybook 22.18% <0.00%> (+0.03%)
#typescript 51.66% <90.47%> (-0.05%)
#unit 33.87% <29.76%> (+0.22%)
Impacted Files Coverage Δ client/web/src/user/area/UserAreaHeader.tsx 75.00% <ø> (ø)
client/web/src/user/area/navitems.ts 100.00% <ø> (ø)
client/web/src/user/area/routes.tsx 60.00% <ø> (+2.85%)
client/web/src/user/settings/backend.tsx 38.09% <ø> (-8.34%)
client/web/src/enterprise/user/settings/routes.tsx 53.33% <50.00%> (ø)
.../user/settings/profile/UserSettingsProfilePage.tsx 77.77% <82.35%> (+3.05%)
...rc/user/settings/profile/UserProfileFormFields.tsx 84.61% <84.61%> (ø)
.../src/user/settings/profile/EditUserProfileForm.tsx 91.66% <91.66%> (ø)
...t/web/src/enterprise/user/settings/sidebaritems.ts 100.00% <100.00%> (ø)
client/web/src/user/area/UserArea.tsx 96.66% <100.00%> (+9.62%)
... and 7 more Created by: tjkandala
I get a 404 when I click on the event log sidebar item, and I also still see the event log tab. I opened a PR to this branch that implements what I thought were the intentional changes.
Please register or sign in to reply