Builder Events Analytics & Custom Tracking

Privacy-friendly custom event tracking across the Uniform Builder lifecycle, with a dedicated admin dashboard section showing builder funnel metrics, customization actions, and engagement data powered by Plausible.

Overview

Full custom event tracking is now wired into every stage of the Uniform Builder, giving the team actionable data on how users progress through the design funnel, which customization features they use most, and where they drop off. All data is privacy-friendly (no PII) and visible in the admin analytics dashboard alongside existing traffic metrics.

Custom Events Tracked

Lifecycle Events

EventFires When
Builder OpenedUser enters the builder for any product
Builder Step ViewedUser navigates to a new step (designs, colors, text, graphics, roster, review)
Builder CompletedUser reaches the review step
Request a Quote ClickedUser clicks the "Request a Quote" button on review
Draft LoadedA previously saved draft is restored from localStorage

Customization Action Events

EventFires When
Design SelectedUser picks a design template
Color ChangedUser changes a color zone value (debounced 1.5 s)
Text Item AddedUser adds a new text element
Graphic UploadedUser uploads a logo/graphic via the Team Upload tab
Graphic Added from LibraryUser picks a graphic from the shared library
Roster CSV ImportedUser imports a player roster via CSV
View Mode ChangedUser toggles between 2D and 3D canvas views
Co-create InvitedUser creates a real-time collaboration session

Catalogue Events

EventFires When
Customize ClickedCaptured via Builder Opened when entering from the catalogue

Event Properties

Every event can carry optional metadata to power drill-down analysis:

  • sport — sport category (e.g. baseball, basketball)
  • product — product slug
  • step — current builder step ID
  • template_id — selected design template (system ID, not user input)
  • color_zone — which zone was changed (primary, secondary, accent, etc.)
  • graphic_source — upload vs library
  • graphic_format — SVG, PNG, JPG, WEBP
  • view_mode — 2d or 3d
  • roster_count — number of players imported via CSV
  • text_count / graphic_count — item totals at time of addition

No personally identifiable information (PII) is ever sent.

Admin Dashboard — Builder Events Table

A new Builder Events section appears at the bottom of the admin analytics dashboard (/admin). It shows:

  • Event name and category (Lifecycle / Customization / Catalogue)
  • Total fires (how many times the event occurred)
  • Unique visitors (how many distinct users triggered it)
  • Proportional bar indicator for quick visual comparison
  • Respects the existing period selector (today, 7 days, 30 days, 6 months, 12 months)

Data is fetched server-side via the Plausible Stats API v2 in parallel with existing analytics — no additional page load latency.

Technical Details

Client-Side Helper

A typed trackBuilderEvent() helper in builder/_lib/analytics/ provides:

  • Type-safe event namesBuilderEventName union type prevents typos at compile time
  • Type-safe propertiesBuilderEventProps interface constrains allowed keys
  • SSR safety — silently no-ops when window.plausible is unavailable
  • Debounced varianttrackBuilderEventDebounced() collapses rapid-fire events (e.g. color picker dragging) into a single fire after 1.5 s of inactivity

Server-Side Service

Two new methods on PlausibleService:

  • getCustomEvents(period, limit) — breakdown by event:goal (Plausible Stats API v2)
  • getCustomEventBreakdown(eventName, propDimension, period) — drill into a single event by any custom property (ready for future use)

Integration Points

FileEvent(s)
builder-layout.tsxBuilder Opened
use-builder-step.tsBuilder Step Viewed
review-step.tsxBuilder Completed, Request a Quote Clicked
builder-data-context.tsxDraft Loaded
designs-step.tsxDesign Selected
colors-step.tsxColor Changed (debounced)
text-step.tsxText Item Added
graphics-step.tsxGraphic Uploaded, Graphic Added from Library
roster-step.tsxRoster CSV Imported
builder-context.tsxView Mode Changed
co-create-button.tsxCo-create Invited

KPIs

  • Funnel analysis — Builder entry rate, step completion rate, drop-off by step, time to review
  • Customization depth — Design switches, color zones customized, text/graphic counts, roster sizes
  • Engagement — 2D vs 3D usage, collaboration invite rate, draft resume rate
  • Operational — Quote conversion rate, popular templates and placements