Conversation
nshirley
approved these changes
Aug 12, 2026
vpomerleau
reviewed
Aug 12, 2026
vpomerleau
left a comment
Contributor
There was a problem hiding this comment.
I thought the ticket was intended for the admin panel "Account history", but maybe I misunderstood?
Nice improvement to settings though, this also mitigates something I noticed on another ticket, where the rendered list could come up shorter than 20 when some events are hidden. Filtering after fetching 100 means its pretty guaranteed that we'll have 20+ visible.
| className="cta-neutral cta-base-p mt-4 w-full" | ||
| onClick={() => setShowAll(true)} | ||
| > | ||
| Show more |
Contributor
There was a problem hiding this comment.
Should we also have a reverse button to collapse the list once it's expanded? And/or only show an additional 20 with each "show more" click?
bcolsson
approved these changes
Aug 12, 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.
Because
.limit(20)inSecurityEvent.findByUid. The page itself never capped anything.This pull request
limitargument toSecurityEvent.findByUidand raises the default to 100 (security-event.ts).PageRecentActivity/index.tsx).HIDDEN_SECURITY_EVENT_NAMESfilter, so 20 visible rows show and hidden events stay hidden once expanded.recent-activity-show-more-buttonstring and tests for the cap, the button, and the filter.One side effect worth knowing:
GET /accountreturns this same list, so it now returns up to 100 entries. The page seeds its first render from that field, so both sources need the same limit.Issue that this pull request solves
Closes: https://mozilla-hub.atlassian.net/browse/FXA-14318
Checklist
Other information
How to test: open Settings, then "Recent account activity". An account with more than 20 events shows 20 rows and a "Show more" button that reveals the rest.