Build and maintain the public account experience with Gutenberg blocks.
Page tree
On activation, Page_Provisioner creates (when missing):
| Path | Role |
|---|---|
/my-account/ | Login / entry |
/my-account/verify/ | Magic-link verification |
/my-account/complete-profile/ | Onboarding after first sign-in |
/my-account/profile/ | Dashboard / profile |
Place a User Accounts Controller (prc-user-accounts/controller) on these pages and compose allowed inner blocks (forms, profile, provider buttons, core layout blocks).
Sign-in flow
-
Request a magic link or use a provider
Readers sign in with email magic links or federated providers (Google, Apple, Microsoft, GitHub) via Sign In Providers.
-
Verify
Magic-link users land on
/my-account/verify/. -
Complete profile when needed
New accounts finish first name / last name (and optional fields) on
/my-account/complete-profile/. -
Use gated content and lists
Authenticated readers can open gated content, saved articles, listening history, and dataset history blocks.
There is no password-based server registration endpoint. Authentication is Firebase client-side.
Important blocks
| Block | Name | Role |
|---|---|---|
| User Accounts Controller | prc-user-accounts/controller | Context + interactivity shell |
| Content Gate | prc-user-accounts/content-gate | Show content only when authenticated |
| Profile View | prc-user-accounts/profile | Profile / account UI |
| Sign In Providers | prc-user-accounts/provider-buttons | Federated provider buttons |
| Saved Article Action / List | prc-user-accounts/saved-article-action, saved-articles-list | Save and list articles |
| Listening History List | prc-user-accounts/listening-history-list | Spoken-article listening history |
| User Datasets / Quiz Groups | prc-user-accounts/user-datasets, user-quiz-groups | Download and quiz history |
| Private Files | prc-user-accounts/private-files | Grid or list of DRM-protected downloads |
| Delete User / Data Download | prc-user-accounts/delete-user, user-data-download | Account deletion and export |
| User State / State Check | prc-user-accounts/user-state, user-state-check | Auth-state composition |
Content gating
Wrap premium or members-only sections in Content Gate. Unauthenticated readers see the placeholder inner content. VIP cache personalization varies responses by auth group.
Private Files
Insert Private Files inside a Content Gate. The inspector drop zone attaches media (zip, PDF, images, and other downloadables) and marks each file DRM protected. The published block shows a grid or list. A signed-in reader clicks an item; the grant checks identity, logs the download on the host post and on the user record, then starts the file.
The block inspector Download stats panel shows all-time totals, per-file counts, and a month/day heatmap for that block. Two Private Files blocks on one post have separate counts. The same file listed on two blocks has two counters. Two copies of the same synced pattern on one post share one heatmap.
When the block has two or more files, a search field and a Download a zip of all these files control appear. Search hides rows in that instance only. The zip still includes every file in the block, including rows hidden by search. A successful zip counts each unique file on that block. If any file cannot be granted, the zip is refused and the notice names each blocked file. Each row has a star that saves the file to the reader's account (starredFiles). Stars are not a download grant.