Creator Profile Hub - Design Document

Overview

Profile pages are configurable dashboards — not static display pages. Creators compose their profile from a library of section types, arrange them freely, and store the layout as a portable JSON configuration. The same system powers creator profiles and project profiles.

Strategic Positioning: The Creator's Home Base

Echo of Dreams is not just another AI chat platform. It's where creators live — the canonical hub that links out to everywhere they publish.

Creators who build detailed characters, lorebooks, and RPG experiences also publish on other platforms. Some of those platforms host content we don't (and won't) host. That's fine. We don't fight "competition" — we become something different entirely. We provide the infrastructure that no other platform does: deep lorebooks, composable modes, curated packages, analytics. The profile is where all of this comes together — a professional home base that links out to every platform where the creator has a presence.

The creator profile is a portfolio and hub, not just a listing page. It shows what the creator builds here, links to where else they publish, and surfaces dynamic engagement data (trending characters, most-chatted, recently updated) to keep the profile alive without constant manual curation.

This applies to two profile types that share the same customization system:

Profile Type Current Route Who Sees It
Creator Profile /creator/:slug Anyone browsing the platform
Project Profile /projects/share/:shareToken Anyone with the share link (see Creator Workbench — Project Profile Page)

Both profile types use the same section primitives, JSON layout config, and rendering pipeline. The data model is shared; only the entity it attaches to differs.

Layout: Header + Tabs + Dashboard

Profile pages use a header + tabs + dashboard layout:

Zone Purpose
Header Banner, avatar, name/bio, follow/favorite actions, "Edit profile" button for owners. Fixed at the top of the page.
Tab bar Horizontal strip directly under the header listing the creator's views (e.g., Home, RPGs, Lorebooks, Support Me). Each tab owns its own grid and sections. One tab is the default.
Dashboard grid The currently-selected tab's grid — the configurable surface. Creators compose each tab independently.

See Tabs (Multiple Views) for how tabs work. The same framing applies to creator profiles and project profiles.


Implementation Plan (Sliced)

Ship the foundation first, then add sections one at a time. Each section slice is independently shippable — it lands a new type in the section registry along with its sub-function, renderer, and drawer editor. The "Add section" picker exposes only sections that have shipped.

Slice 0 — Foundation. ✅ Shipped. Delivered:

Section slices (status):

  1. ✅ about (free, default-on)
  2. ✅ characters / modes / lorebooks (free, default-on — parity with the legacy profile)
  3. ✅ packages (free)
  4. ✅ platforms (free section: the funding and recognized presets always render; only a custom entry needs a profile slot to show publicly — ProfileFreeBaselineProjector. The earlier "competing-platform presets require a slot" split was retired.)
  5. ✅ projects (free)
  6. 📋 featured (Slot) — design intent: collapses into a display.mode = 'featured' variant of entity-list rather than a separate type
  7. 📋 spotlight (Slot) — same pattern as featured
  8. ✅ stats_overview (Slot)
  9. 📋 trending (Slot) — same display-mode pattern
  10. 📋 announcements (Slot)
  11. 📋 community (Slot, post-v1)
  12. 📋 activity (Slot, post-v1)

Project profile slice. ✅ Shipped at /project/:slug. The project-profile branch shares all section primitives with creator profiles; layout customization is gated on can_manage. Owner-as-viewer drafts work via project membership lookup (can_view).

Project follows. 📋 Planned. Today user_follows is creator-scoped only — there is no follow action on project profiles. The plan is to add project-scoped follows (either a sibling user_project_follows table or a polymorphic generalization of user_follows) so the project profile header can surface a follow action mirroring the creator profile, and so downstream features (Badges and Perks, notification fan-out, follower counts on project headers) can rely on it.

OpenGraph + production-readiness. ✅ Shipped. Public profile pages serve OG meta tags via cf-worker bot rewrites. Project visibility gate enforced inside the OG repo lookup (private projects return the not-found shell). Cache-Control: private, max-age=30, must-revalidate on public GETs. Per-IP rate limits (40/min + 600/h) on /api/users/* and /api/projects/*.


Current State

The legacy listing-style profile (CreatorProfilePage.tsx) has been retired. Profile pages — both creator (/creator/:slug) and project (/project/:slug) — are now dashboard pages composed from typed sections with server-driven content.

A creator who does nothing gets a default layout with their About + Characters + Modes + Lorebooks sections pre-arranged. They can drag, resize, add, remove, and configure sections via the in-page edit drawer + floating toolbar. Edits autosave; conflicts surface 412 with editor attribution.

The remaining section types (featured / spotlight / trending / announcements / community / activity) are reserved in the catalog as coming_soon: true — picker shows them but they can't be added yet. The plan now collapses featured / spotlight / trending into display.mode variants of the existing entity-list types rather than shipping them as separate section types — design discussion pending before implementation.

For the operational reference (file map, behaviors, gotchas, known gaps), see docs-internal/architecture/profile/PROFILE_DASHBOARDS.md and the root CLAUDE.md "Profile Dashboards" section.


Design Goals

  1. Dashboard, not page — The profile is a composable dashboard. Creators pick sections, arrange them, configure each one. The result feels like their platform, not a generic listing.
  2. JSON-driven layout — The entire page composition is a JSON document. Extensible (new section types don't require schema changes), shareable (export your layout, import someone else's), versionable.
  3. Server-driven rendering — The server resolves the JSON config into a full response with populated content. The client is a dumb renderer — no layout logic, no permission filtering.
  4. Progressive — A creator who does nothing gets a perfectly functional default profile. Customization is opt-in and incremental.
  5. Consistent primitives — Creator profiles and project profiles use the same section/layout system so the codebase stays simple.
  6. Performant — Profile pages are public-facing and high-traffic. Customization data must be cheap to query.

Customization Features

1. Announcement Banner

The profile banner reuses the existing HeroBanner component (shared/src/components/common/HeroBanner.tsx) — the same component that powers the hub page announcement carousel via AnnouncementBanners.

This is NOT a separate feature from the hub announcements — it's the same system. The hub has platform-level banners managed by admins; profile pages have creator-level banners managed by the creator. Same component, same data shape, different ownership.

┌─────────────────────────────────────────────────────────────────────┐
│                                                                     │
│   ╔═══════════════════════════════════════════════════════════════╗ │
│   ║  [Background image: fantasy landscape]                       ║ │
│   ║                                                              ║ │
│   ║  Crystal of Dawn RPG                                         ║ │
│   ║  A new chapter awaits                                        ║ │
│   ║  Chapter 3 is now live — continue the adventure.             ║ │
│   ║                                                              ║ │
│   ║  [ Play Now → ]                            ● ○ ○             ║ │
│   ╚═══════════════════════════════════════════════════════════════╝ │
│                                                                     │
│   [Avatar] WorldBuilder42                                           │
│   Fantasy world builder and RPG designer.                           │
│   1,280 followers · 342 favorites                                   │
│                                                                     │
└─────────────────────────────────────────────────────────────────────┘

2. Visibility

Every profile has an allowAnonymousView toggle that controls whether unauthenticated visitors can view the page via its link.

Naming note: this is deliberately not called isPublic. Throughout the rest of the codebase, isPublic on an entity means "published / publicly listed." That's a separate concept from whether anonymous visitors can reach a page by link. Keeping the names distinct avoids conflation.

This setting controls visibility only, not authorship. The creator always sees their own profile; the toggle only governs who else can reach it. It also does not override per-entity permissions — a private lorebook referenced in a featured/spotlight section still won't appear to viewers who lack can_view on it, regardless of this flag.

Scope per profile type:

Profile type allowAnonymousView: true means allowAnonymousView: false means
Creator profile (/creator/:slug) Logged-out visitors can view Must be logged in to view
Project profile (/projects/share/:shareToken) Share token works for anonymous visitors Share token only works for authenticated users whose entity_permissions grant matches

Server enforcement: the profile page endpoint checks allowAnonymousView before resolving sections. For anonymous requests to a profile with the flag off, it returns 401 without running any section sub-functions (cheap reject). For project profiles, the share-token resolver additionally requires granted_to_user_id IS NULL on the permission row when allowAnonymousView: true (unlisted-link grants).

Project profiles — the implemented predicate (WP-02, 2026-07). The row above says what the share-token route does; it isn't the whole gate, and "authenticated" on its own was never meant to be one. A signed-in stranger could read any private project profile until this was tightened. fn_can_view_project_profile is now the single gate, run by both the page read and the "Load more" pagination path, and allows a read when — in order:

  1. Anonymous caller — allowAnonymousView and nothing else. A share token is neither required nor sufficient here: logged-out project-token holders are bounced to login before this call, and a creator profile's projects section links anonymously-viewable projects with plain /project/{slug} URLs carrying no token.
  2. Project owner — always.
  3. Accepted member (project_members.joined_at IS NOT NULL) with any access flag. This is an explicit carve-out, not an inference from login: the profile shows in-line drafts to members with can_view and emits isInsiderViewer for that tier, so a member who couldn't open the page couldn't have member-only content. A pending invitation is not membership — same rule as vw_user_projects and fn_profile_has_active_slot.
  4. Not private at all — allowAnonymousView, or projects.is_public (the /browse catalog flag, whose cards deep-link to /project/{slug} with no token).
  5. Otherwise: the project's own share token, and only when the grant behind it applies to the caller — scoped to this project, still live (rotation/deletion revokes instantly), carrying at least one flag, and either the unlisted link grant or a grant addressed to that caller. A grant addressed to someone else never counts.

Anything else is a 401. Creator profiles are unchanged — they remain a public identity surface where allowAnonymousView governs the logged-out tier and any signed-in viewer may read.

Default: false — profiles require login by default. Creators explicitly opt in from the edit drawer.

3. Color Theme

A creator-chosen accent color that tints the profile's visual elements. This is NOT a full theme — it's a single accent color that the profile renderer uses to derive highlights, borders, and gradient overlays.

What the accent color affects:

4. Tabs (Multiple Views)

A profile can have multiple tabs, each with its own grid layout and sections. Tabs are rendered as a horizontal tab bar under the header. One tab is marked isDefault: true and is the landing view when the profile loads without an explicit tab in the URL.

Tabs let a creator organize their home along audience intent rather than content type:

Each tab is an independent grid: its own columns/rowHeight/gap override (optional — inherits profile defaults if omitted) and its own sections array with positions.

Data shape per tab:

{
  "key": "rpgs",
  "label": "RPGs",
  "slug": "rpgs",
  "isDefault": false,
  "visible": true,
  "grid": { "columns": 12, "rowHeight": 80, "gap": 16 },
  "sections": [ /* section objects with x/y/w/h */ ]
}

Routing:

/creator/:slug                        → creator profile, default tab
/creator/:slug/:tabSlug               → creator profile, specified tab
/projects/share/:shareToken           → project profile, default tab
/projects/share/:shareToken/:tabSlug  → project profile, specified tab

:slug replaces the legacy /creator/:id integer-id route — all creator profile URLs are slug-based now. The slug comes from the user's username (or a dedicated profile_slug column if usernames turn out to be unsuitable as URL segments; decide in Slice 0).

Unknown tab slugs fall back to the default tab (no 404 — friendlier for links that outlive a renamed tab). Unknown creator slugs return 404.

Reserved slugs

Certain values are reserved by routing and can't be used as creator slugs or tab slugs:

The slug validator rejects reserved values at save time and during signup/rename.

Limits:

Edit mode interactions:

Mobile: the tab bar scrolls horizontally with snap-points. The grid inside the active tab uses the single-column collapse from Responsive Behavior.

5. Profile Sections & Grid Layout

The profile page is composed of sections — discrete content blocks — arranged on a dashboard grid. Creators drag sections into position, resize them by column span and row span, and adjust the overall column count. The full composition is stored as a JSON layout config.

Grid Model

The dashboard uses a fixed-column grid (like Grafana, Notion databases, or react-grid-layout). Each section occupies a rectangular cell defined by (x, y, w, h):

Top-level grid settings live on the layout config:

"grid": {
  "columns": 12,
  "rowHeight": 80,
  "gap": 16
}

gap controls the spacing between sections. The spacing inside a section (the inset between the section card edge and its content) is a renderer presentation default, not a config field — it keeps the "dumb renderer" contract and stays consistent across every section type so the layout reads evenly by default. There is no per-section padding knob in the config today.

Responsive Behavior (v1)

On viewports narrower than the md breakpoint the grid collapses to a single column, sections render stacked in y-then-x order, and w is ignored. Per-breakpoint layouts (different positions for mobile vs desktop) are out of scope for v1 — a section that works nicely at w: 6 on desktop is expected to still render acceptably at full width on mobile.

To help creators verify that expectation without resizing their window, the edit toolbar carries a Desktop ⇄ Mobile preview toggle. Selecting Mobile renders the single-column collapse read-only inside a centred phone frame; it's a preview only — editing (drag / resize) still happens in the desktop layout, and the toggle adds no per-breakpoint layout data (the config still stores one set of (x, y, w, h)).

Drag, Drop & Resize

In the edit drawer the profile switches to an edit mode overlay where each section shows drag handles and resize grips:

Saving commits the new (x, y, w, h) values to the config in a single PUT. Cancelling discards them.

Section Min/Max Constraints

Some section types look bad below a certain width. The section renderer registry declares minW, minH, and optional maxW per type; the grid enforces these during drag/resize so creators can't break the layout.

Section Type minW minH Notes
about 3 2 Below 3 cols bio wraps ugly
platforms 3 2 Card grid needs room
stats_overview 4 1 Stat boxes need horizontal space
spotlight 6 3 Deep-dive display
featured 4 3 Needs at least 2 cards wide
trending 3 3 Ranked list
announcements 4 2 Feed readability
characters / modes / lorebooks / packages / projects 4 3 Card grid
community (post-v1) 6 4 Threaded discussion needs room
activity (post-v1) 3 3 Feed list

Built-in Section Types

Section Type Content Default Visible
about Bio text, links, joined date Yes
platforms Links to creator's presence on other AI platforms and external sites No
announcements Creator announcements feed (text posts with optional images) No
stats_overview Dashboard-style stat boxes — total chats, unique users, avg rating, top character No
featured Hand-picked items the creator wants to highlight (any entity type) No
spotlight Deep-dive on a single entity — full description, stats, CTA No
trending Auto-populated: most-chatted characters/packages over a configurable window (7d/30d) No
characters Filterable grid of public characters with inline "Load more" Yes
packages Published packages (deliverables) — same config + pagination as characters Yes (if any)
modes Filterable grid of public modes with inline "Load more" Yes
lorebooks Filterable grid of public lorebooks with inline "Load more" Yes
projects Project cards linking to project profile pages No
community (post-v1) Community board — threaded discussions, pinned posts. Deferred until moderation tooling lands. No
activity (post-v1) Recent publishing activity (new characters, updated packages, etc.). Source TBD. No

Default layouts for the initial visible sections come from the default config — they're positioned on a 12-column grid, not a linear order.

Multiple instances: Some section types can appear more than once. A creator can have two spotlight sections (one for a character, one for a package), multiple featured sections with different curations, or multiple community boards for different topics. The key in the JSON config distinguishes instances.

Section Configuration

Each section has:

Creators place and size sections via drag-and-drop on the grid. Position is stored as (x, y, w, h) on each section — no separate sort order.

Entity-List Sections (characters, modes, lorebooks, packages)

These four section types share one config schema — EntityListSectionConfig — so the same edit UI and the same server-side resolver power all of them. A creator with two characters sections (say "Romance" on one tab, "Horror" on another) gets two genuinely different content slices, not two identical grids.

{
  "filter": {
    "tags": [12, 47],
    "excludeTags": [99],
    "characterType": "narrator",
    "category": "fantasy",
    "search": null
  },
  "sort": { "by": "favorites", "direction": "desc" },
  "display": {
    "mode": "grid",
    "limit": 12,
    "loadMoreEnabled": true
  }
}
Field Default What it does
filter.tags none Restrict to entities tagged with all of these (max 16 IDs).
filter.excludeTags none Drop entities tagged with any of these (max 16 IDs).
filter.characterType none Characters only — narrator, character, etc. Ignored on other types.
filter.category none Characters only. Ignored on other types.
filter.search none Free-text match on name/description (max 80 chars).
sort.by updated One of: updated, published, created, favorites, name. updated is the latest change readers can see, or the release if that's later. published (characters, modes, lorebooks) is when the entity went public; created is when its draft was started. favorites is characters only.
sort.direction desc asc or desc.
display.mode grid grid, carousel, or featured. (Renderer reserved for future variants — grid is the only mode shipped today.)
display.limit 12 Initial page size, 1–24.
display.loadMoreEnabled true When false, the "Load more" button never renders even if more rows exist.

Inline "Load more" — When the section's first page (display.limit rows) doesn't cover the full match set, the server emits a loadMore descriptor on section.content and the client renders a "Load more (N remaining)" button at the bottom of the section. Clicking it fetches the next page from GET /api/{users|projects}/{slug}/profile/sections/{tabKey}/{sectionKey}/items?page=N, which reuses the same stored config server-side — filter, sort, and page size stay consistent across pages. New items append in place; the page never reloads.

6. Announcements

The announcements section is a creator-managed news feed. Creators post text updates with optional images — release notes, event callouts, status updates, community messages.

┌─ Announcements ────────────────────────────────────────────────┐
│                                                                │
│  📌 Chapter 3 Now Live!                         Mar 15, 2026  │
│  The Crystal of Dawn adventure continues. New lorebook         │
│  entries, two new characters, and a rebalanced combat mode.    │
│  [ Play Chapter 3 → ]                                          │
│  ─────────────────────────────────────────────────────────────  │
│  Server maintenance complete                    Mar 10, 2026  │
│  Everything is back up. Thanks for your patience!              │
│  ─────────────────────────────────────────────────────────────  │
│  New character: The Wandering Sage              Mar 5, 2026   │
│  A mysterious figure who appears at crossroads...              │
│                                                                │
│  [View all announcements]                                      │
│                                                                │
└────────────────────────────────────────────────────────────────┘

The featured section is a curated showcase — the creator hand-picks specific items to highlight. This is distinct from the auto-populated content sections (characters, modes, lorebooks) which show everything.

Data model: A simple ordered list of (entity_type, entity_id, blurb?, sort_order) stored in the section's config.

8. Spotlight

The spotlight section hooks into a single entity and gives it a deep-dive presentation — bigger than a card, smaller than a full page. Think of it as a featured item that gets its own section with rich detail.

┌─ ⭐ Character Spotlight ──────────────────────────────────────┐
│                                                                │
│  ┌──────────┐  Elara the Narrator                              │
│  │          │  ★ 4.8 · 2,340 messages · 89 favorites           │
│  │  [Avatar]│                                                   │
│  │          │  "My most popular character — a fourth-wall-      │
│  │          │   breaking narrator who guides your adventure     │
│  └──────────┘   while dropping hints about a deeper mystery."  │
│                                                                │
│  A mysterious narrator who seems to know more than she lets    │
│  on. She'll guide your story while weaving in cryptic clues    │
│  about the world's hidden truths...                            │
│                                                                │
│                              [ Start Chatting → ]              │
│                                                                │
└────────────────────────────────────────────────────────────────┘

Config shape:

{
  "entityType": "character",
  "entityId": 45,
  "blurb": "My most popular character — ...",
  "showStats": true,
  "ctaLabel": "Start Chatting"
}

9. Community Board

The community section adds a discussion board to the profile page — a place for the creator's audience to post, discuss, and engage. This turns the profile from a one-way showcase into a two-way community space.

┌─ Community ────────────────────────────────────────────────────┐
│                                                                │
│  📌 Rules & Guidelines                    by WorldBuilder42   │
│  Be respectful, stay on topic, no spoilers for Chapter 3.     │
│  ─────────────────────────────────────────────────────────────  │
│                                                                │
│  [New Post]                                                    │
│                                                                │
│  "Elara's hints in Chapter 2 are wild"     by DreamWalker99  │
│  Did anyone else notice she says "the clock always...          │
│  💬 12 replies · ♥ 8                                           │
│  ─────────────────────────────────────────────────────────────  │
│  "Best mode for combat scenarios?"         by RuneFanatic     │
│  I've been trying different modes with the Crystal of Dawn..   │
│  💬 5 replies · ♥ 3                                            │
│                                                                │
│  [Load more]                                                   │
│                                                                │
└────────────────────────────────────────────────────────────────┘

Config shape:

{
  "topic": "General Discussion",
  "allowNewPosts": true,
  "pinnedPostIds": [101, 102],
  "sortBy": "newest"
}

Optional links displayed in the about section or as icons below the banner.

11. Platforms (Cross-Platform Hub)

The platforms section is the strategic centerpiece of the creator hub concept. It displays links to the creator's presence on other AI character platforms — with recognized platform icons, profile URLs, and optional character counts.

This is what makes Echo of Dreams a hub rather than just a platform. No other AI chat service links to competitors. We do, because we're not competing on the same axis. We compete on creator infrastructure (lorebooks, modes, packages, analytics). The characters might also live on JanitorAI, Character.AI, or Chai — and the creator's profile here is where you find all of them.

Recognized platforms:

Platforms fall into two categories, which drives slot gating (see Slot Gating):

Creator-funding platforms — available on every profile, slot or no slot. These help the creator earn from their work; we want every creator to be able to surface them, because we benefit when creators get paid.

Platform Icon URL Pattern Tier
Patreon Platform logo patreon.com/... Default
Ko-fi Platform logo ko-fi.com/... Default
Buy Me a Coffee Platform logo buymeacoffee.com/... Default
GitHub Sponsors Platform logo github.com/sponsors/... Default

Other AI platforms and custom links — slot-only. These are the "Linktree for AI character creators" presets plus the custom URL escape hatch.

Platform Icon URL Pattern Tier
Character.AI Platform logo character.ai/public-profile/... Slot
JanitorAI Platform logo janitorai.com/profiles/... Slot
Chai Platform logo chai-research.com/... Slot
SillyTavern (GitHub) Platform logo GitHub repo link Slot
Chub Platform logo chub.ai/users/... Slot
Venus Platform logo venus.chub.ai/users/... Slot
Pygmalion Platform logo Link Slot
Poe Platform logo poe.com/... Slot
CrushOn Platform logo crushon.ai/... Slot
Custom Globe icon Any URL Slot

The preset catalog lives server-side so new presets can be promoted between tiers (or added entirely) without a client deploy.

┌─ Find Me Everywhere ──────────────────────────────────────────┐
│                                                                │
│  ┌──────────────┐  ┌──────────────┐  ┌──────────────┐        │
│  │ [C.AI logo]  │  │ [Janitor]    │  │ [Chub logo]  │        │
│  │ Character.AI │  │ JanitorAI    │  │ Chub         │        │
│  │ 28 characters│  │ 42 characters│  │ 15 characters│        │
│  │ [ Visit → ]  │  │ [ Visit → ]  │  │ [ Visit → ]  │        │
│  └──────────────┘  └──────────────┘  └──────────────┘        │
│                                                                │
│  ┌──────────────┐  ┌──────────────┐                           │
│  │ [Ko-fi logo] │  │ [Patreon]    │                           │
│  │ Ko-fi        │  │ Patreon      │                           │
│  │ Support me   │  │ Exclusive    │                           │
│  │ [ Visit → ]  │  │ [ Visit → ]  │                           │
│  └──────────────┘  └──────────────┘                           │
│                                                                │
└────────────────────────────────────────────────────────────────┘

Why this matters strategically:

Monetization angle: Creators with paid support links (Ko-fi, Patreon, Buy Me a Coffee) can include those too. We take no cut — it's their profile. This goodwill drives creator loyalty.

Config shape:

{
  "platforms": [
    { "type": "janitorai", "url": "https://janitorai.com/profiles/worldbuilder42", "label": "JanitorAI", "characterCount": 42 },
    { "type": "characterai", "url": "https://character.ai/public-profile/...", "label": "Character.AI", "characterCount": 28 },
    { "type": "custom", "url": "https://ko-fi.com/worldbuilder42", "label": "Ko-fi", "description": "Support my work" }
  ]
}

12. Stats Overview (Dashboard Boxes)

The stats_overview section displays key creator metrics in a compact dashboard-style layout — card boxes with numbers and labels, similar to an analytics dashboard but public-facing.

Available stats:

Stat Source Display
Total conversations mv_user_stats "12.4K conversations"
Total messages received web_message_stats aggregate "84K messages"
Unique users chatted Distinct user count from conversations "3.2K users"
Average rating Package ratings aggregate "★ 4.6 avg"
Public characters Character count "28 characters"
Public lorebook entries Lorebook entry aggregate "1,420 entries"
Follower count user_follows count "1.2K followers"
Active packages Published package count "5 packages"
┌─ Creator Stats ───────────────────────────────────────────────┐
│                                                                │
│  ┌────────────┐ ┌────────────┐ ┌────────────┐ ┌────────────┐ │
│  │   12.4K    │ │    3.2K    │ │   ★ 4.6    │ │     28     │ │
│  │conversations│ │   users   │ │  avg rating │ │ characters │ │
│  └────────────┘ └────────────┘ └────────────┘ └────────────┘ │
│                                                                │
└────────────────────────────────────────────────────────────────┘

Config shape:

{
  "stats": ["conversations", "unique_users", "avg_rating", "characters"],
  "layout": "row"
}

The trending section auto-populates with the creator's most-engaged content over a configurable time window. No manual curation — the data drives the display.

This solves a real problem: creator profiles go stale. A creator who published 20 characters but hasn't touched their profile in months still has a living community chatting with their characters. The trending section surfaces that activity automatically.

┌─ Trending This Week ──────────────────────────────────────────┐
│                                                                │
│  1. ↑ Elara the Narrator          234 new conversations       │
│     ──────────────────────────────────────────────────────     │
│  2. — Crystal of Dawn RPG          189 new conversations      │
│     ──────────────────────────────────────────────────────     │
│  3. ↑ The Wandering Sage            78 new conversations      │
│     ──────────────────────────────────────────────────────     │
│  4. ↓ Noir Detective                45 new conversations      │
│                                                                │
└────────────────────────────────────────────────────────────────┘

Config shape:

{
  "window": "7d",
  "maxItems": 4,
  "entityTypes": ["character", "package"]
}

Server-side: Queries conversation/message stats within the time window, grouped by entity. The data already exists in web_message_stats — this is a view over existing data, not a new tracking system.


JSON Layout Config

The entire profile composition is stored as a single JSON document. This is the core design decision — instead of relational tables for sections, featured items, and ordering, the layout is a JSON blob that the server interprets and the client renders.

Why JSON instead of relational tables?

Concern Relational (old approach) JSON config
Adding section types Schema migration Just add a new type string — no migration
Multiple instances Awkward (unique constraint on section_type) Natural (array of objects, each with a key)
Per-section config Separate config columns or a JSONB column anyway Config is inline — one document describes everything
Sharing/export Query multiple tables, reconstruct Copy/paste JSON. Import someone else's layout.
Versioning Diff across tables Diff a single document
Ordering Sort order integers Grid coordinates (x, y, w, h) per section — captures position AND size in one move
Dashboard grid Separate layout table joined to sections Grid settings + positions are all inline in the same document

The JSON config is not the content — it's the layout. Content (characters, lorebook entries, messages) stays in relational tables. The config just says "put a spotlight section for character uuid-xyz at grid cell (0, 0, 12, 4), a featured section at (0, 4, 8, 3), and a community board at (0, 7, 12, 6)."

Config Shape

{
  "version": 1,
  "allowAnonymousView": true,
  "accentColor": "#7c3aed",
  "grid": {
    "columns": 12,
    "rowHeight": 80,
    "gap": 16
  },
  "banners": [
    {
      "id": "banner-1",
      "title": "Crystal of Dawn RPG",
      "subtitle": "A new chapter awaits",
      "description": "Chapter 3 is now live — continue the adventure.",
      "imageUrl": "/banners/cod-chapter3.jpg",
      "ctaLabel": "Play Now",
      "ctaUrl": "/packages/12",
      "overlayPosition": "left",
      "colorBackdrop": "rgba(0,0,0,0.6)"
    }
  ],
  "socialLinks": [
    { "type": "twitter", "label": "@worldbuilder42", "url": "https://x.com/worldbuilder42" },
    { "type": "discord", "label": "WB42's Server", "url": "https://discord.gg/..." }
  ],
  "tabs": [
    {
      "key": "home",
      "label": "Home",
      "slug": "home",
      "isDefault": true,
      "visible": true,
      "sections": [
        { "key": "about",             "type": "about",          "displayName": "About",               "visible": true, "x": 0, "y": 0, "w": 4, "h": 3 },
        { "key": "platforms",         "type": "platforms",      "displayName": "Find Me Everywhere",  "visible": true, "x": 4, "y": 0, "w": 8, "h": 3,
          "config": { "platforms": [
            { "type": "janitorai",   "url": "https://janitorai.com/profiles/worldbuilder42", "label": "JanitorAI",    "characterCount": 42 },
            { "type": "characterai", "url": "https://character.ai/public-profile/...",       "label": "Character.AI", "characterCount": 28 },
            { "type": "chub",        "url": "https://chub.ai/users/worldbuilder42",          "label": "Chub",         "characterCount": 15 },
            { "type": "kofi",        "url": "https://ko-fi.com/worldbuilder42",              "label": "Ko-fi",        "description": "Support my work" }
          ]}
        },
        { "key": "stats-overview",    "type": "stats_overview", "displayName": "Creator Stats",       "visible": true, "x": 0, "y": 3, "w": 12, "h": 1,
          "config": { "stats": ["conversations", "unique_users", "avg_rating", "characters"], "layout": "row" }
        },
        { "key": "spotlight-elara",   "type": "spotlight",      "displayName": "Character Spotlight", "visible": true, "x": 0, "y": 4, "w": 8, "h": 4,
          "config": { "entityType": "character", "entityUuid": "b8f1c6d8-2a4b-4f2b-9a3d-1c3e5f7a9b11", "blurb": "My most popular character.", "showStats": true, "ctaLabel": "Start Chatting" }
        },
        { "key": "trending-weekly",   "type": "trending",       "displayName": "Trending This Week",  "visible": true, "x": 8, "y": 4, "w": 4, "h": 4,
          "config": { "window": "7d", "maxItems": 4, "entityTypes": ["character", "package"] }
        },
        { "key": "featured-best",     "type": "featured",       "displayName": "Showcase",            "visible": true, "x": 0, "y": 8, "w": 12, "h": 4,
          "config": { "items": [
            { "entityType": "package",   "entityUuid": "c2e9a1b7-...", "blurb": "My flagship creation" },
            { "entityType": "lorebook",  "entityUuid": "4f7d8e21-...", "blurb": null },
            { "entityType": "character", "entityUuid": "b8f1c6d8-...", "blurb": "Fan favorite" }
          ]}
        }
      ]
    },
    {
      "key": "rpgs",
      "label": "RPGs",
      "slug": "rpgs",
      "isDefault": false,
      "visible": true,
      "sections": [
        { "key": "rpg-spotlight", "type": "spotlight", "displayName": "Flagship Campaign", "visible": true, "x": 0, "y": 0, "w": 12, "h": 4,
          "config": { "entityType": "package", "entityUuid": "c2e9a1b7-...", "blurb": "The Crystal of Dawn RPG — a complete tabletop fantasy experience.", "ctaLabel": "Play Now" }
        },
        { "key": "rpg-packages",  "type": "packages",  "displayName": "All Packages",      "visible": true, "x": 0, "y": 4, "w": 12, "h": 4,
          "config": { "display": { "limit": 12 }, "sort": { "by": "favorites", "direction": "desc" } }
        },
        { "key": "rpg-modes",     "type": "modes",     "displayName": "Game Modes",        "visible": true, "x": 0, "y": 8, "w": 6,  "h": 4,
          "config": { "filter": { "tags": [42] }, "display": { "limit": 8 } }
        },
        { "key": "rpg-lorebooks", "type": "lorebooks", "displayName": "World Lorebooks",   "visible": true, "x": 6, "y": 8, "w": 6,  "h": 4,
          "config": { "display": { "limit": 8 } }
        }
      ]
    },
    {
      "key": "support",
      "label": "Support Me",
      "slug": "support",
      "isDefault": false,
      "visible": true,
      "sections": [
        { "key": "support-banner",    "type": "spotlight",  "displayName": "Become a Patron",  "visible": true, "x": 0, "y": 0, "w": 12, "h": 4,
          "config": { "entityType": "package", "entityUuid": "c2e9a1b7-...", "blurb": "Support my work for early access and monthly exclusive lore drops.", "ctaLabel": "Join Patreon" }
        },
        { "key": "support-platforms", "type": "platforms",  "displayName": "Where to Support", "visible": true, "x": 0, "y": 4, "w": 12, "h": 3,
          "config": { "platforms": [
            { "type": "patreon",         "url": "https://patreon.com/worldbuilder42" },
            { "type": "kofi",            "url": "https://ko-fi.com/worldbuilder42" }
          ]}
        }
      ]
    }
  ]
}

Key design points:

Sharing & Import

Because the layout is a single JSON document, creators can:

Data Model

Profile Customization Table

CREATE TABLE profile_customizations (
    id SERIAL PRIMARY KEY,

    -- Polymorphic owner: uses EntityType from Core/Entities/EntityRegistry.cs
    -- 3 = Creator (user profile), 7 = Project (project profile)
    entity_type SMALLINT NOT NULL,
    entity_id INTEGER NOT NULL,

    -- JSON layout config (the full dashboard composition)
    layout_config JSONB NOT NULL DEFAULT '{}'::jsonb,

    -- Timestamps
    created_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP,
    updated_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP,

    UNIQUE(entity_type, entity_id)
);

COMMENT ON TABLE profile_customizations IS 'Dashboard-style profile customization. Layout, sections, banners, and config stored as a JSON document.';

Announcements Table

Announcement content lives in its own table (not in the JSON config) because announcements are timestamped, user-generated content that other users interact with.

CREATE TABLE profile_announcements (
    id SERIAL PRIMARY KEY,
    customization_id INTEGER NOT NULL REFERENCES profile_customizations(id) ON DELETE CASCADE,

    title VARCHAR(200),
    body TEXT NOT NULL,
    image_url VARCHAR(500),
    cta_label VARCHAR(50),
    cta_url VARCHAR(500),
    is_pinned BOOLEAN NOT NULL DEFAULT FALSE,

    created_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP,
    updated_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP
);

CREATE INDEX idx_profile_announcements_customization
    ON profile_announcements (customization_id, is_pinned DESC, created_at DESC);

COMMENT ON TABLE profile_announcements IS 'Creator announcements displayed on profile pages. Supports pinning and optional CTA links.';

Community Board Tables

Community content also lives in relational tables — posts and replies are user-generated, need moderation, and have their own lifecycle.

CREATE TABLE community_boards (
    id SERIAL PRIMARY KEY,
    customization_id INTEGER NOT NULL REFERENCES profile_customizations(id) ON DELETE CASCADE,
    section_key VARCHAR(50) NOT NULL,  -- matches the section key in JSON config

    topic VARCHAR(100),
    allow_new_posts BOOLEAN NOT NULL DEFAULT TRUE,

    created_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP,

    UNIQUE(customization_id, section_key)
);

CREATE TABLE community_posts (
    id SERIAL PRIMARY KEY,
    board_id INTEGER NOT NULL REFERENCES community_boards(id) ON DELETE CASCADE,
    user_id INTEGER NOT NULL REFERENCES users(id) ON DELETE CASCADE,

    body TEXT NOT NULL,
    image_url VARCHAR(500),
    is_pinned BOOLEAN NOT NULL DEFAULT FALSE,
    is_deleted BOOLEAN NOT NULL DEFAULT FALSE,

    reply_count INTEGER NOT NULL DEFAULT 0,
    like_count INTEGER NOT NULL DEFAULT 0,

    created_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP,
    updated_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP
);

CREATE INDEX idx_community_posts_board
    ON community_posts (board_id, is_pinned DESC, created_at DESC)
    WHERE is_deleted = FALSE;

CREATE TABLE community_replies (
    id SERIAL PRIMARY KEY,
    post_id INTEGER NOT NULL REFERENCES community_posts(id) ON DELETE CASCADE,
    user_id INTEGER NOT NULL REFERENCES users(id) ON DELETE CASCADE,

    body TEXT NOT NULL,
    is_deleted BOOLEAN NOT NULL DEFAULT FALSE,

    created_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP
);

CREATE INDEX idx_community_replies_post
    ON community_replies (post_id, created_at ASC)
    WHERE is_deleted = FALSE;

CREATE TABLE community_post_likes (
    user_id INTEGER NOT NULL REFERENCES users(id) ON DELETE CASCADE,
    post_id INTEGER NOT NULL REFERENCES community_posts(id) ON DELETE CASCADE,
    created_at TIMESTAMPTZ NOT NULL DEFAULT CURRENT_TIMESTAMP,

    PRIMARY KEY (user_id, post_id)
);

COMMENT ON TABLE community_boards IS 'Discussion boards linked to profile sections. One board per community section instance.';
COMMENT ON TABLE community_posts IS 'User-created discussion posts on community boards.';
COMMENT ON TABLE community_replies IS 'Replies to community posts. Flat (one level deep, no nesting).';

Architecture: Server-Driven Profile Page

The profile page follows the same server-driven model as the Project Profile Page. The server assembles the full profile response — layout, sections, content — and the client renders it.

API Endpoints

GET /api/users/{slug}/profile/page                                  (creator profile, public)
GET /api/projects/{slug}/profile/page                               (project profile, public)
GET /api/users/me/profile/customization                             (owner reads layout for edit drawer)
PUT /api/users/me/profile/customization                             (owner writes layout)
GET /api/creator/projects/{id}/profile/customization                (project edit, gated on can_manage)
PUT /api/creator/projects/{id}/profile/customization                (project edit, gated on can_manage)
GET /api/profile/section-catalog                                    (per-tier "Add block" picker list)

GET /api/users/{slug}/profile/sections/{tabKey}/{sectionKey}/items?page=N
GET /api/projects/{slug}/profile/sections/{tabKey}/{sectionKey}/items?page=N
    Inline "Load more" for entity-list sections. Reuses the same anonymity
    gate as the page endpoint and the same stored config server-side, so
    filter / sort / page-size stay consistent across pages.

Response Shape

The server reads the JSON layout config, resolves each section's content, and returns a populated response. The client renders it. Every section in the response carries its grid coordinates (x, y, w, h) alongside its content payload so the client can place it on the grid without a second lookup. Grid settings are included at the response root. header.canEdit tells the client whether to show the "Edit profile" button.

Below, grid coordinates are shown on the first section as an example and omitted from later sections for brevity — the real response includes them on every section.

{
  "header": {
    "name": "WorldBuilder42",
    "avatarUrl": "/avatars/wb42.png",
    "bio": "Fantasy world builder and RPG designer.",
    "accentColor": "#7c3aed",
    "followerCount": 1280,
    "favoriteCount": 342,
    "isFollowing": false,
    "isFavorite": false,
    "canEdit": false,
    "socialLinks": [
      { "type": "twitter", "label": "@worldbuilder42", "url": "https://x.com/worldbuilder42" },
      { "type": "discord", "label": "WB42's Server", "url": "https://discord.gg/..." }
    ]
  },
  "grid": { "columns": 12, "rowHeight": 80, "gap": 16 },
  "banners": [
    {
      "id": "banner-1",
      "title": "Crystal of Dawn RPG",
      "subtitle": "A new chapter awaits",
      "description": "Chapter 3 is now live — continue the adventure.",
      "imageUrl": "/banners/cod-chapter3.jpg",
      "ctaLabel": "Play Now",
      "ctaUrl": "/packages/12",
      "overlayPosition": "left"
    }
  ],
  "sections": [
    {
      "key": "about",
      "type": "about",
      "displayName": "About",
      "x": 0, "y": 0, "w": 4, "h": 3,
      "content": {
        "bio": "Fantasy world builder and RPG designer.",
        "joinedAt": "2024-06-15T00:00:00Z"
      }
    },
    {
      "key": "platforms",
      "type": "platforms",
      "displayName": "Find Me Everywhere",
      "content": {
        "platforms": [
          { "type": "janitorai", "url": "https://janitorai.com/profiles/worldbuilder42", "label": "JanitorAI", "iconUrl": "/icons/platforms/janitorai.svg", "characterCount": 42 },
          { "type": "characterai", "url": "https://character.ai/public-profile/...", "label": "Character.AI", "iconUrl": "/icons/platforms/characterai.svg", "characterCount": 28 },
          { "type": "chub", "url": "https://chub.ai/users/worldbuilder42", "label": "Chub", "iconUrl": "/icons/platforms/chub.svg", "characterCount": 15 },
          { "type": "custom", "url": "https://ko-fi.com/worldbuilder42", "label": "Ko-fi", "iconUrl": null, "description": "Support my work" }
        ]
      }
    },
    {
      "key": "stats-overview",
      "type": "stats_overview",
      "displayName": "Creator Stats",
      "content": {
        "stats": [
          { "key": "conversations", "label": "Conversations", "value": "12.4K" },
          { "key": "unique_users", "label": "Users", "value": "3.2K" },
          { "key": "avg_rating", "label": "Avg Rating", "value": "★ 4.6" },
          { "key": "characters", "label": "Characters", "value": "28" }
        ]
      }
    },
    {
      "key": "announcements-main",
      "type": "announcements",
      "displayName": "News",
      "content": {
        "items": [
          { "id": 1, "title": "Chapter 3 Now Live!", "body": "The Crystal of Dawn adventure continues...", "isPinned": true, "ctaLabel": "Play Chapter 3", "ctaUrl": "/packages/12", "createdAt": "2026-03-15T..." },
          { "id": 2, "title": null, "body": "Server maintenance complete. Thanks for your patience!", "isPinned": false, "ctaLabel": null, "ctaUrl": null, "createdAt": "2026-03-10T..." }
        ],
        "totalCount": 8,
        "hasMore": true
      }
    },
    {
      "key": "spotlight-elara",
      "type": "spotlight",
      "displayName": "Character Spotlight",
      "content": {
        "entityType": "character",
        "id": 45,
        "name": "Elara the Narrator",
        "description": "A mysterious narrator who seems to know more than she lets on...",
        "avatarUrl": "...",
        "coverImageUrl": "...",
        "blurb": "My most popular character — a fourth-wall-breaking narrator.",
        "stats": { "messageCount": 2340, "favoriteCount": 89, "conversationCount": 189 },
        "ctaLabel": "Start Chatting",
        "ctaUrl": "/chat/character/45"
      }
    },
    {
      "key": "featured-best",
      "type": "featured",
      "displayName": "Showcase",
      "content": {
        "items": [
          { "entityType": "package", "id": 12, "name": "Crystal of Dawn RPG", "description": "A complete tabletop fantasy adventure", "coverImageUrl": "...", "blurb": "My flagship creation" },
          { "entityType": "lorebook", "id": 78, "name": "Realms Lore", "description": "142 entries of world lore", "coverImageUrl": null, "blurb": null }
        ]
      }
    },
    {
      "key": "trending-weekly",
      "type": "trending",
      "displayName": "Trending This Week",
      "content": {
        "window": "7d",
        "items": [
          { "rank": 1, "entityType": "character", "id": 45, "name": "Elara the Narrator", "avatarUrl": "...", "conversationCount": 234, "trend": "up" },
          { "rank": 2, "entityType": "package", "id": 12, "name": "Crystal of Dawn RPG", "coverImageUrl": "...", "conversationCount": 189, "trend": "flat" },
          { "rank": 3, "entityType": "character", "id": 67, "name": "The Wandering Sage", "avatarUrl": "...", "conversationCount": 78, "trend": "up" },
          { "rank": 4, "entityType": "character", "id": 23, "name": "Noir Detective", "avatarUrl": "...", "conversationCount": 45, "trend": "down" }
        ]
      }
    },
    {
      "key": "characters",
      "type": "characters",
      "displayName": "Characters",
      "content": {
        "items": [ "..." ],
        "loadMore": {
          "hasMore": true,
          "totalCount": 47,
          "nextPage": 2,
          "pageSize": 12
        }
      }
    },
    {
      "key": "community-general",
      "type": "community",
      "displayName": "Community",
      "content": {
        "boardId": 1,
        "topic": "General Discussion",
        "allowNewPosts": true,
        "posts": [
          { "id": 101, "userId": 99, "userName": "DreamWalker99", "avatarUrl": "...", "body": "Elara's hints in Chapter 2 are wild...", "isPinned": false, "replyCount": 12, "likeCount": 8, "isLiked": false, "createdAt": "..." },
          { "id": 102, "userId": 77, "userName": "RuneFanatic", "avatarUrl": "...", "body": "Best mode for combat scenarios?...", "isPinned": false, "replyCount": 5, "likeCount": 3, "isLiked": true, "createdAt": "..." }
        ],
        "totalCount": 34,
        "hasMore": true
      }
    }
  ]
}

What the server does

  1. Loads the layout_config JSON from profile_customizations (or generates defaults if none exists)
  2. Returns grid settings (columns, rowHeight, gap) at the response root for the client to render the dashboard grid
  3. Reads the banners array and returns it directly (no content resolution needed — banners are self-contained)
  4. Iterates sections, skipping visible: false entries. Each surviving section keeps its (x, y, w, h) coordinates in the response.
  5. For each visible section, resolves the content based on type:
    • about — bio, joined date, social links from the config
    • platforms — returns platform links directly from the config with resolved icon URLs
    • stats_overview — queries mv_user_stats, conversation/message aggregates, and package ratings to compute stat values
    • announcements — queries profile_announcements for this profile, ordered by pinned + recency
    • spotlight — loads the referenced entity's full data, stats, and description
    • featured — resolves each entity reference, filters by viewer permissions
    • trending — queries web_message_stats for conversations within the time window, grouped by entity, ranked by count. Compares to previous window to determine trend direction (up/flat/down).
    • characters / modes / lorebooks / packages — entity-list sections, resolved through the same path. Reads the section's EntityListSectionConfig (filter / sort / display.limit), runs it through IBrowseRepository scoped to the profile owner, and emits a loadMore descriptor when more rows exist than the first page covers.
    • community — loads the matching community_boards + recent posts
    • projects — projects with share tokens
    • activity — recent changelog entries for public entities
  6. Returns only visible sections with populated content. Hidden sections and sections referencing inaccessible entities are excluded.

What the client does

  1. Fetches the profile response
  2. Renders banners via the HeroBanner component (same as hub)
  3. Renders the header (avatar, name, bio, social links) using the accent color. Shows the "Edit profile" button when header.canEdit is true.
  4. Lays out the sections array on a CSS grid derived from grid.columns / grid.rowHeight / grid.gap, placing each section at its (x, y, w, h). Below the mobile breakpoint, coordinates are ignored and sections stack y-then-x at full width.
  5. No layout logic (positions, permissions, ordering) lives on the client — it just renders what the server returned. Drag, drop, and resize interactions in edit mode update the config and PUT it back; the client never decides visibility on its own.
  6. Entity-list sections render their initial items immediately. When the section's content.loadMore descriptor is present, a "Load more" button appears at the bottom; clicking it fetches the next page from the section's load-more endpoint and appends in place. No full page reload, no waterfall of per-section requests on first paint.

Why server-driven

Same rationale as the project profile page:


Customization UI

Creators configure their profile from an edit drawer opened on the profile page itself — not a separate settings page. Owners (for creator profiles) and project admins (for project profiles) see an "Edit profile" button in the profile header; clicking it opens a right-side drawer and switches the live profile into edit mode — a dashboard grid overlay where sections are draggable, resizable, and removable. The drawer holds global settings; the grid itself is the section editor.

The same drawer component is used for both creator and project profiles — it's scoped to whichever entity it was opened on. Non-owners never see the button.

Layout

Edit mode has two surfaces: the drawer (global settings) and the grid (section placement). Both are live — changes reflect immediately on the profile behind them.

Drawer (right-side panel, ~360px wide):

┌─ Profile Settings ─────────────────────┐
│                                        │
│  ┌─ Visibility ─────────────────────┐  │
│  │ ( ) Signed-in users only         │  │
│  │ (●) Anyone with link             │  │
│  └──────────────────────────────────┘  │
│                                        │
│  ┌─ Grid ───────────────────────────┐  │
│  │ Columns: ( 1 )( 2 )( 3 )( 4 )    │  │
│  │          ( 6 )(●12)              │  │
│  │ Row height: [ 80px ▾ ]           │  │
│  │ Gap:        [ 16px ▾ ]           │  │
│  └──────────────────────────────────┘  │
│                                        │
│  ┌─ Banner ─────────────────────────┐  │
│  │ [preview] [Upload] [Remove]      │  │
│  └──────────────────────────────────┘  │
│                                        │
│  ┌─ Color Theme ────────────────────┐  │
│  │ Accent: [ColorPicker ●]          │  │
│  └──────────────────────────────────┘  │
│                                        │
│  ┌─ Social Links ───────────────────┐  │
│  │ 🐦 Twitter  [@wb42           ][✕]│  │
│  │ 💬 Discord  [discord.gg/...  ][✕]│  │
│  │ [+ Add Link]                     │  │
│  └──────────────────────────────────┘  │
│                                        │
│  [+ Add Section ▾]                     │
│                                        │
│  [Discard]              [Save Changes] │
└────────────────────────────────────────┘

Grid (the profile itself, in edit mode):

┌──────────────────────────────────────────────────────────┐
│  About           │  Find Me Everywhere         [✕]       │
│  [drag] [✕]      │  [drag] [✕]                           │
│                  │                                        │
│  (0,0,4,3)       │  (4,0,8,3)                             │
│                  │                                    ╲◢  │  ← resize grip
├──────────────────────────────────────────────────────────┤
│  Creator Stats                                    [✕]    │
│  [drag]                                                   │
│  (0,3,12,1)                                           ╲◢  │
├──────────────────────────────────────────────────────────┤
│  News                      │  Character Spotlight  [✕]  │
│  [drag] [✕]                │  [drag] [✕]                 │
│                            │                              │
│  (0,4,6,4)                 │  (6,4,6,4)              ╲◢  │
└──────────────────────────────────────────────────────────┘

[+ empty cell — click to add section here]

Each section card in edit mode has:

The existing "Sections list" from the previous drawer layout is removed — the grid IS the section list. │ └────────────────────────────────────────────────────────────┘ │ │ │ │ ┌─ Featured Items ──────────────────────────────────────────┐ │ │ │ Drag to reorder. These appear in your Showcase section. │ │ │ │ │ │ │ │ ≡ 📦 Crystal of Dawn RPG [My flagship creation] [✕]│ │ │ │ ≡ 📚 Realms Lore [ ] [✕]│ │ │ │ ≡ 🧑 Elara the Narrator [Fan favorite ] [✕]│ │ │ │ │ │ │ │ [+ Add Featured Item] (opens entity picker) │ │ │ └────────────────────────────────────────────────────────────┘ │

Key interactions


Project Profile Customization

Project profiles use the same customization system. The profile_customizations table uses entity_type = 7 (Project) instead of entity_type = 3 (Creator), matching the canonical EntityType enum in Core/Entities/EntityRegistry.cs.

Project profile customization is accessed from the workbench's project settings (right drawer or header menu). The UI is the same as the creator profile customization, but scoped to the project.

Differences from creator profiles:

Aspect Creator Profile Project Profile
Banner Creator's personal banner Project-specific banner (e.g., game artwork)
Accent color Creator's brand color Project's theme color
Featured items Any of the creator's public entities Only items within the project
Social links Creator's social accounts Project-specific links (e.g., game wiki, community Discord)
Default sections about, characters, modes, lorebooks about, deliverables, items (grouped by type)
Access Public (authenticated users) Share-token gated (see Project Profile Page)

Client Rendering

The client renders profiles using a generic ProfilePage component that accepts the server response and maps each section to a renderer.

// Section renderer registry — same pattern as the workbench Map node registry
const sectionRenderers: Record<string, React.ComponentType<SectionProps>> = {
  about: AboutSection,
  platforms: PlatformLinksSection,
  stats_overview: StatsOverviewSection,
  announcements: AnnouncementFeedSection,
  spotlight: SpotlightSection,
  featured: FeaturedSection,
  trending: TrendingSection,
  characters: CharacterGridSection,
  packages: PackageGridSection,
  modes: ModeGridSection,
  lorebooks: LorebookGridSection,
  projects: ProjectCardSection,
  community: CommunityBoardSection,
  activity: ActivityFeedSection,
}

The renderer lays the sections out on a CSS grid derived from the response's grid settings, placing each section at its (x, y, w, h). Unknown section types are skipped (forward compatibility — the server just won't include section types the client hasn't learned to render).

<div
  className="profile-grid"
  style={{
    display: 'grid',
    gridTemplateColumns: `repeat(${grid.columns}, 1fr)`,
    gridAutoRows: `${grid.rowHeight}px`,
    gap: grid.gap,
  }}
>
  {sections.map(section => {
    const Renderer = sectionRenderers[section.type]
    if (!Renderer) return null
    return (
      <div
        key={section.key}
        style={{
          gridColumn: `${section.x + 1} / span ${section.w}`,
          gridRow: `${section.y + 1} / span ${section.h}`,
        }}
      >
        <Renderer section={section} />
      </div>
    )
  })}
</div>

Because sections are keyed (not just typed), the renderer uses key as the React key — critical for multiple instances of the same type (two spotlights, two community boards).

In edit mode, the <div className="profile-grid"> is replaced by a drag-and-drop grid library (e.g., react-grid-layout or react-mosaic) that wraps the same renderer map and emits (x, y, w, h) changes back to the local draft config. The pick of library is an implementation detail — the config shape is library-agnostic.

Mobile Collapse

Below the md breakpoint the grid drops to gridTemplateColumns: '1fr' and sections render stacked in y-then-x order with h preserved (so a tall spotlight still takes multiple rows) but w ignored. Edit mode is disabled on mobile — customization happens on desktop. On desktop, the edit toolbar's Mobile preview toggle renders this same single-column collapse inside a phone frame so creators can check the small-screen result before they ship it (see Responsive Behavior).

Accent Color Application

The accent color from the server response is applied via CSS custom properties scoped to the profile page container:

<div
  className="profile-page"
  style={{
    '--profile-accent': accentColor,
    '--profile-accent-light': lighten(accentColor, 0.85),
    '--profile-accent-dark': darken(accentColor, 0.2),
  } as React.CSSProperties}
>
  {/* Profile content uses var(--profile-accent) */}
</div>

This keeps the accent color scoped to the profile page without affecting the global design system.


Default Behavior

Creators who never customize their profile get the default JSON layout config:

{
  "version": 1,
  "allowAnonymousView": false,
  "accentColor": null,
  "grid": { "columns": 12, "rowHeight": 80, "gap": 16 },
  "banners": [],
  "socialLinks": [],
  "tabs": [
    {
      "key": "home",
      "label": "Home",
      "slug": "home",
      "isDefault": true,
      "visible": true,
      "sections": [
        { "key": "about",      "type": "about",      "displayName": "About",      "visible": true,  "x": 0, "y": 0,  "w": 12, "h": 2, "config": {} },
        { "key": "platforms",  "type": "platforms",  "displayName": "Find Me Everywhere", "visible": false, "x": 0, "y": 2,  "w": 12, "h": 3, "config": { "platforms": [] } },
        { "key": "characters", "type": "characters", "displayName": "Characters", "visible": true,  "x": 0, "y": 5,  "w": 12, "h": 4, "config": { "maxItems": 12 } },
        { "key": "packages",   "type": "packages",   "displayName": "Packages",   "visible": true,  "x": 0, "y": 9,  "w": 12, "h": 3, "config": { "maxItems": 6 } },
        { "key": "modes",      "type": "modes",      "displayName": "Modes",      "visible": true,  "x": 0, "y": 12, "w": 12, "h": 4, "config": { "maxItems": 12 } },
        { "key": "lorebooks",  "type": "lorebooks",  "displayName": "Lorebooks",  "visible": true,  "x": 0, "y": 16, "w": 12, "h": 4, "config": { "maxItems": 12 } }
      ]
    }
  ]
}

When only one tab exists, the client hides the tab bar entirely — default profiles look identical to a tab-less profile.

The default experience is identical to the current profile page. Customization is purely additive. The default config is generated by the server when no profile_customizations row exists — it's never stored until the creator makes their first change.


Implementation Notes

Database

JSON Config Validation

The server validates the JSON config on save:

Invalid sections are rejected with specific error messages — the config is saved atomically (all or nothing).

Caching

Profile pages are read-heavy, write-rare. Consider:

Image Storage

Banner images and announcement images use the same upload/storage pipeline as character avatars and cover images. No new infrastructure needed.

Layout Presets

Platform-shipped starter templates help creators get started quickly:

Preset Sections Included
Minimal about, characters
Showcase about, banner, featured, characters, packages, modes, lorebooks
Creator Hub about, platforms, stats_overview, banner, trending, featured, characters, packages
Community Hub about, banner, announcements, featured, characters, community
RPG Creator about, banner, spotlight (main package), featured, characters, packages, community, activity

Presets are JSON config files stored server-side. Applying a preset replaces the current config (with confirmation). Creators can then customize from there.


Slot Gating

Profile customization splits between default profile (no slot assigned) and slotted profile (a Project Slot is assigned to this profile). Default profiles look respectable and functional; slotted profiles unlock the full dashboard-building experience.

Where slots come from: Project Slots are an Echo-priced subscription — 500☆/mo recurring from the user's persistent wallet. A creator can assign a slot to their own creator profile or to a project profile. The Echoes can come from anywhere: a Pro subscription's 1,500☆/mo grant covers up to 3 Slots (with leftover for other features); a Premium grant of 4,000☆/mo covers up to 8; a Free user can subscribe to a Slot directly by buying an Echo bundle. See Daily Tasks & Echo Economy — Echo-Subscription Catalog for the full catalog and the recurring-debit mechanics.

Throughout this doc, "slot" means "a Project Slot is assigned to the profile in question." A creator with a Pro subscription and one slot picks where the slot lives — own profile or one project, not both. Buying additional slots covers additional surfaces.

Feature Matrix

Feature Default Profile Slotted Profile
Banner Single image, no text/overlay/CTA Full HeroBanner — title, subtitle, description, CTA, overlay position, color overrides, carousel (multiple banners)
Anonymous view toggle (allowAnonymousView) Yes Yes
Multiple tabs (views) Up to 2 tabs Up to 10 tabs
Accent color Yes Yes
Social links Yes Yes
About section Yes Yes
Platforms section — creator-funding presets (Patreon, Ko-fi, Buy Me a Coffee, GitHub Sponsors) Yes Yes
Platforms section — competing AI platform presets (Character.AI, JanitorAI, Chub, etc.) + custom URLs — Yes
Content grids (characters, modes, lorebooks, packages) Yes Yes
Section reordering Yes Yes
Section visibility toggle Yes Yes
Custom section display names — Yes
Stats overview section — Yes
Trending section — Yes
Announcements section — Yes
Spotlight section — Yes
Featured section — Yes
Community boards — Yes
Activity feed section — Yes
Multiple instances of same section type — Yes
Layout import/export — Yes
Layout presets — Yes (default profile gets the default layout only)

Default Profile Banner

Default profiles get a simple banner image — no text overlay, no CTA button, no carousel rotation. Just a visual header.

Default banner:
┌─────────────────────────────────────────────────────────────────┐
│                                                                 │
│              [Full-width background image]                      │
│                                                                 │
└─────────────────────────────────────────────────────────────────┘

Slotted banner:
┌─────────────────────────────────────────────────────────────────┐
│                                                                 │
│   Crystal of Dawn RPG              [Background image]           │
│   A new chapter awaits                                          │
│   Chapter 3 is now live.                                        │
│                                                                 │
│   [ Play Now → ]                                   ● ○ ○       │
│                                                                 │
└─────────────────────────────────────────────────────────────────┘

The server enforces this: when resolving the layout config for a slot-less profile, banner objects are stripped down to imageUrl only. The client never receives title/subtitle/description/CTA fields for default profiles.

Server-Side Enforcement

The server enforces slot gating at two points:

1. Config save (write path):

When a slot-less profile saves its config, the server:

// Pseudo-code for config validation
var hasSlot = await _slots.IsAssignedAsync(profileEntityType, profileEntityId);
if (!hasSlot)
{
    if (config.Banners.Count > 1)
        errors.Add("Multiple banners require a Project Slot.");

    foreach (var banner in config.Banners)
    {
        banner.Title = null;
        banner.Subtitle = null;
        banner.Description = null;
        banner.CtaLabel = null;
        banner.CtaUrl = null;
    }

    // Platforms section: slot-less profiles restricted to creator-funding presets only
    var platformSection = config.Sections.FirstOrDefault(s => s.Type == "platforms");
    if (platformSection != null)
    {
        var disallowed = platformSection.Config.Platforms
            .Where(p => !DefaultPlatformPresets.Contains(p.Type))
            .Select(p => p.Type)
            .ToList();
        if (disallowed.Any())
            errors.Add($"Platform types [{string.Join(", ", disallowed)}] require a Project Slot. Default profiles support creator-funding presets (Patreon, Ko-fi, Buy Me a Coffee, GitHub Sponsors) only.");
    }

    var slotSections = config.Sections
        .Where(s => SlotOnlySectionTypes.Contains(s.Type));
    // Note: "platforms" is NOT in SlotOnlySectionTypes — slot-less profiles can use it with the creator-funding preset subset.
    if (slotSections.Any())
        errors.Add($"Section types [{string.Join(", ", slotSections.Select(s => s.Type))}] require a Project Slot.");
}

2. Config resolve (read path):

When serving a profile page, the server also filters based on whether the profile has a slot assigned (not based on the viewer's state). A slot-less profile never renders slot-only sections, even if the viewer is on Premium.

This handles the lapse case cleanly: a creator who had a slot, configured slot-only sections, then let the slot lapse — their saved config is retained, but the server won't render the slot-only sections until the slot is re-assigned. Reactivating the slot brings the configuration back exactly as it was.

Slot Lookup

The gate is a single lookup per profile against the project_slot_assignments table (or equivalent — see Tiers & Limits). The check is "is there an active Project Slot assigned to this profile's (entity_type, entity_id)?" rather than "what's the owner's subscription tier?"

This keeps the gating mechanism orthogonal to subscription tier:

The implementation reads the slot status during the fn_get_profile_page orchestrator pass and passes it into the section catalog filter.

Upgrade Prompts

When a creator tries to add a slot-only section on a slot-less profile:

┌────────────────────────────────────────────────────────────────┐
│                                                                │
│  Stats, Trending, Announcements, Spotlights, Featured          │
│  sections, and Community Boards are part of the Studio set.    │
│                                                                │
│  Add a Project Slot to this profile to unlock the full         │
│  dashboard. Slots also discount paid-experience platform fees  │
│  and expand creator inventory headroom on this project.        │
│                                                                │
│  [ Subscribe to a Project Slot — 500☆/mo → ]                   │
│                                                                │
└────────────────────────────────────────────────────────────────┘

The "+ Add Section" button in the customization UI shows all section types; slot-only types are visually marked with a "Project Slot" badge on slot-less profiles. The creator can see what's available, which drives slot-purchase interest at the moment of intent.

A creator on Pro or Premium with an unassigned bundled slot sees a friendlier variant: "You have 1 unused Project Slot. Assign it to this profile?"


Acceptance Criteria

The feature is not done until every box is verified ✅ against the running product. (Current state: all hold as of the 2026-06-24 rework. Any change touching the gate must re-verify them.)

User use cases — satisfiable + accessible (verify by driving the UI):

Behavior:

Invariants that must stay true (the spec'd-free baseline — accessibility is free):

Edges: