Repository navigation
Web: tell the owner when an administrator acts on their account - #378
Merged
Merged
Conversation
An admin reset of System Safety, an early finalise of queued deletions, cancelled visibility changes, a revoked session or API key, a tier change: all of these were recorded on the Account page's admin activity card and nowhere the owner would see without going looking. A banner now sits at the top of the app for any admin action newer than the owner has acknowledged, naming the action in plain words, when, and the reason the admin gave, with a link to the full record. Actions that undo a protection the owner set or change how they sign in get the critical colour; the rest are warnings. Dismissing stores the newest action's timestamp in the web client settings, the way announcement dismissals do, so it follows the account across browsers and can never cover an action that happens later. Driven by the existing self-only admin-activity feed, so nothing an admin can do reaches the card without also reaching the banner. The card now describes each action in words beside its raw name, from the same table.
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.
Closes #339. Web only; no backend change.
GET /v1/auth/admin-activityfeed (first page) and shows any entry newer than the owner has acknowledged: what was done, in plain words, when, the reason the admin entered, "plus N more" when several are unseen, and a link to the Account page's full record. Actions that undo a protection the owner set or change how they sign in (System Safety reset, bypassing queued deletions, cancelling staged exposures, session or API-key revocation, password reset, email change, 2FA disable, share-grant revocation, publishing block) get the critical colour; everything else is a warning.created_attoadmin_activity_seen_atin the web client-settings blob, the same mechanism announcement dismissals use, and falls back to a session-only dismissal if that write fails. Because it is a timestamp rather than a flag, a dismissal can never hide an action that happens after it.lib/admin.ts. Unknown action names fall back to the raw name so a new server-side action is never silently hidden.useClientSettingsmoved out of the announcement banner file into a hook module, so both banners share it without tripping the fast-refresh lint rule.admin_activity_seen_atconvention for a native client that wants the same banner; changelog entry.Verification