Repository navigation
React migration 5/6: user profile page - #942
Open
devin-ai-integration[bot] wants to merge 4 commits into
Open
devin-ai-integration[bot] wants to merge 4 commits into
devin-ai-integration[bot] wants to merge 4 commits into
Conversation
Co-Authored-By: Matthew Guerra <matthew.guerra@cognition.ai>
Author
|
I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".
|
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
Co-Authored-By: Matthew Guerra <matthew.guerra@cognition.ai>
Author
There was a problem hiding this comment.
Devin Review found 1 finding. Devin automatically fixed it.
Fixed by Devin (1)
- Pending profile transitions go untested — Added a pg→sama navigation test with a held pg request; it checks the abort and exposed that a late pg resolve overwrote state, so UserPage now ignores results after abort.
Co-Authored-By: Matthew Guerra <matthew.guerra@cognition.ai>
Co-Authored-By: Matthew Guerra <matthew.guerra@cognition.ai>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR ports
user/intoreact-app/and replaces the placeholderUserPage. It is stacked on #938 (foundation) and independent of #939–#941.UserPageloadsfetchUser(id)in an effect with anAbortController. The foundation pointsfetchUseratapi.hnpwa.com/v0/user/:id.jsonbecausenode-hnapi's/userreturns 404. While loading it shows the loader, and on failure it showsErrorMessage("Could not load user <id>.").Profile: <id>and a back button →navigate(-1)), the name,karma ★andCreated <created>.aboutappears only when the user has one.aboutis rendered throughDOMPurify.sanitize(utils/sanitize.ts) to keep Angular's[innerHTML]sanitization. React migration 4/6: item details, polls and recursive comments #941 adds the same helper and dependency with identical content, so whichever lands second merges cleanly..user-page, and:host >>> prebecomes.user-page pre.UserPage.test.tsxcovers the profile fields, sanitizedabout, the emptyaboutcase, the back button and the unknown-user error. Lint, typecheck, 24 tests and the build pass.This duplicates #933 from an earlier parallel migration stack. Only one of them should land.
Devin-Org: engineering
Link to Devin session: https://devin-gtm.devinenterprise.com/sessions/a08488aa0df94f1ba5fcd309e7df132d
Link to Bot: https://devin-gtm.devinenterprise.com/org/devin-gtm/bots/a78446fd2653463e94cefb31caca525b
Open in Devin Desktop: https://devin-gtm.devinenterprise.com/desktop/session/a08488aa0df94f1ba5fcd309e7df132d?variant=devin
Note
Devin could not open this Pull Request as matthewguerra-cog: they have no GitHub connection usable for this repository.
As a fallback, Devin opened this PR as itself.
🟢 Devin fixed the finding · Follow Devin's work