fix(authors): respect user sort preference on author search links#846
Merged
thostetler merged 1 commit intoadsabs:masterfrom Apr 16, 2026
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #846 +/- ##
========================================
- Coverage 62.7% 62.7% -0.0%
========================================
Files 323 323
Lines 38008 38008
Branches 1723 1723
========================================
- Hits 23802 23801 -1
- Misses 14166 14167 +1
Partials 40 40 🚀 New features to boost your workflow:
|
bc7992b to
6705731
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
Risk summary: Low-to-moderate regression risk (changes are localized), with a couple of user-facing/a11y text issues that should be corrected before merge.
This PR updates AllAuthorsModal so author-name search links use the active/user-preferred search sort (instead of hardcoded score desc) and mitigates a pre-existing XSS risk by sanitizing the paper title HTML before rendering.
Changes:
- Resolve an
activeSortfrom the current URL (ifsortis present) or from the user’s stored preferred search sort, and pass it into the author search links. - Sanitize
data.docs[0].titlewithisomorphic-dompurifyprior todangerouslySetInnerHTML.
- author name links in AllAuthorsModal now use the user's preferred sort instead of hardcoded score desc - sanitize title HTML with DOMPurify in AllAuthorsModal
6705731 to
fb4b18f
Compare
shinyichen
approved these changes
Apr 16, 2026
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.
score descCloses SCIX-842