Components/Account

Account

Profile, security, sessions and notifications, with confirmed removal.

Since 0.9.3BETA

Usage

Account center

Switch tabs; removing sessions and turning off two-factor both ask first. Sample data.

Loading demo...

Overview

The Tuff account center: profile, security, sessions and notifications on one page, with the avatar and email verification always shown in the header.

  • Display name and bio are editable; username and email are read-only, and saving shows a short notice.
  • The two-factor switch asks before it turns off and stays on until the reader confirms.
  • Sessions lists signed-in devices and tags the current one as "This device"; removing one session or all others asks first.
  • The danger zone holds one action, Remove other sessions, and no timer runs it; the button is disabled when there are no other sessions.
  • Security alerts stay on in notifications. Wide (≥ 960px) adds an App column; narrow (< 640px) moves the tabs to the top and keeps only the device and action columns.

Customization

  • With a real account, replace the sample data with the account service's API; the avatar, email and verification come from the service, not a copy in the template.
  • Removing sessions and turning off two-factor should call the API only after the modal is confirmed; on failure, keep the modal open and offer a retry.
  • The "This device" tag comes from the current session the server returns, not from a guess in the front end.
  • Keep security alerts fixed on in any new notification row, and explain why in its description.
RegionComponentsRole
Profile headerTxAvatar, TxStatusBadgeAvatar, name and verification status
TabsTxTabs / TxTabItemGroup / TxTabItemProfile, security, sessions and notifications sections
Profile formTuffInput, TxTextareaDisplay name, read-only email and bio
SecurityTxGroupBlock / TxBlockSlot, TuffSwitch, TxButtonTwo-factor sign-in and password
SessionsTxDataTable, TxTag, TxIconButtonSigned-in devices, the "This device" tag and removal
Danger zoneTxCard, TxButtonRemoving all other sessions
Confirmation and feedbackTxModal, TxToastPanelConfirm before removal, and the result notice