Commit Graph
287 Commits
Author SHA1 Message Date
Mike Cao eea124bbf8 Migrate UI theme variables to react-zen tokens and update dependency package 2026-08-24 17:02:57 -07:00
Francis Cao a2374e1515 add padding to avoid content and scroll-bar collision in expanded menu 2026-08-17 16:17:23 -07:00
Francis Cao 5ca2be7598 expanded metrics performance updates. 2026-08-13 10:16:29 -07:00
Mike Cao 8a05dfee58 Replace global scrollbars with themed overlay scroll areas 2026-08-07 15:31:14 -07:00
Mike Cao 5d8cf10bf1 Replace Focusable navigation wrappers with tabIndex-based focus handling 2026-08-02 19:42:53 -07:00
Mike Cao cfe8020831 Fix multi-select menus and selected label rendering 2026-07-30 23:47:34 -07:00
Mike Cao 6ac2b9377c Upgrade react-zen and migrate UI components to its updated APIs 2026-07-30 22:35:20 -07:00
Francis Cao 3136e3590a Revert "Move timezone selection to query parameters"
This reverts commit 4d7930060c.
2026-07-27 10:32:28 -07:00
Mike Cao 4d7930060c Move timezone selection to query parameters 2026-07-27 02:24:59 -07:00
Francis Cao 8004afe63d Punycode support. Closes #2170 2026-07-17 10:22:37 -07:00
Mike Cao 306ca4a435 Lint format files. Updated rng function. 2026-06-02 22:35:07 -07:00
Francis Cao a7a0d73dd7 fix PieChart rendering issues by giving default height. 2026-05-18 23:06:47 -07:00
Mike Cao caa200db29 Merge pull request #4259 from yancat160/feat/persist-hidden-events-across-range
fix: keep hidden events hidden across date-range changes
2026-05-15 00:15:40 -04:00
Mike Cao bbe105524d Merge pull request #4257 from yancat160/fix/stable-event-chart-colors
fix: stabilize event chart colors per label
2026-05-14 23:18:07 -04:00
Francis Cao b7e1d902f4 seperate revenue queries for better api/performance. Fix realtime css/ui issues. 2026-05-12 16:44:12 -07:00
Francis Cao c6ec8385c9 Add revenue chart cumulative mode. 2026-05-12 10:32:43 -07:00
Yan 46e1351aed cache hex6 hash per label in color mapping
Address Greptile review on PR #4257: hex6(key) was parsed twice per
label, once in the sort comparator and once when deriving the
preferred palette slot. Cache the parsed integer in a local hashOf
map so the sort comparator and the slot lookup share one computation
per label, no behaviour change.
2026-05-08 09:17:07 -04:00
Yan 4f72d17faf keep hidden events hidden across date-range changes
Clicking a legend item on the events chart toggled hidden via
chart.current.getDatasetMeta(idx).hidden, which lives on Chart.js's
per-dataset meta object. Each time chartData changed (date-range
switch, refetch, focusLabel update) the second useEffect in Chart.tsx
replaces datasets wholesale, Chart.js regenerates the meta, and the
hidden flags vanish, so previously-toggled-off events came back on
their own.

Lift the hidden state into React. EventsChart owns a Set<string> of
hidden labels and passes it down via a new optional hiddenLabels prop
on Chart, plus an onLegendClick callback for controlled toggling.
Chart re-applies hidden after the existing focusLabel pass so the set
survives every data refresh, and falls back to the original
meta-based behaviour when no callback is provided so other charts
(website overview, revenue) keep their existing semantics.

Verified with the seeded Demo SaaS data: hide signup_started in the
Last 24 hours view, switch to Last 7 days then Last 30 days, the
label stays greyed in the legend and absent from the bars; clicking
again restores it. State is component-scoped, so it intentionally
resets on reload or navigation away from the events page.
2026-05-08 08:38:15 -04:00
Yan edcf5bd407 stabilize event chart colors per label
Colors in the events-tab chart were assigned by the dataset index from
Object.keys(map), so changing the date range or reloading the page
reshuffled keys and produced a different color for the same event each
time.

Pick the palette slot deterministically from a hash of the label
(hex6 / FNV-1a), and walk the palette greedily in hash-sorted order so
the assignment is independent of the API response order. When two
labels prefer the same slot, the later one steps to the next free
slot, so the visible set of up to 12 events all get distinct colors.
The right shift on the hash sidesteps the FNV-1a low-bit bias mod 12
(FNV prime is close to 2^24).
2026-05-08 08:00:11 -04:00
Francis Cao fa182d0947 implement URL pageview metric/expanded metric 2026-05-07 16:59:30 -07:00
Francis Cao 7d7dd336f9 fix funnel alias issues. Closes #4144 2026-04-20 12:58:17 -07:00
Francis Cao 0bd5e70df7 Fix build errors, remove active users link on share page. 2026-04-20 08:51:56 -07:00
Mike Cao de46ef9aab Merge pull request #4169 from nurlennart/fix/active-users-link
fix: restore realtime link on active users indicator
2026-04-18 21:28:50 -04:00
Mike Cao cc829c8f6f Replace react-spring with motion, fix breaking changes in react-window/date-fns-tz/pure-rand. 2026-04-18 15:41:25 -07:00
nurlennart c1395aafb4 fix: restore realtime link on active users indicator 2026-04-17 08:49:57 +02:00
Francis Cao 28cfcd0c80 disable active link 2026-04-15 11:02:46 -07:00
Francis Cao 9c8f7704df Fix tooltip in darkmode 2026-03-24 15:29:13 -07:00
Mike Cao 31f322630d Add Badge component and use it for performance page ratings 2026-03-15 20:44:25 -07:00
Francis Cao 48f8cd0ece update performance css, small replay fixes 2026-03-09 18:13:31 -07:00
Francis Cao 1bffb3cbf3 saved session replay implementation checkpoint 2026-03-09 13:51:08 -07:00
Francis Cao acfd4462e3 Improvements to revenue screen 2026-03-06 09:58:43 -08:00
Francis Cao 72bb63fe5e remove listable currency implementation. use formatCount 2026-03-05 12:52:04 -08:00
Francis Cao 383922ab17 performance page polish 2026-03-05 12:21:34 -08:00
Francis Cao f6a6d2cc31 performance updates checkpoint 2026-03-05 10:12:30 -08:00
Mike Cao e2ab4af493 Merge branch 'performance' into dev 2026-02-25 02:27:46 -08:00
Francis Cao 5144aff9cd revenue report enhancements. 2026-02-21 10:57:52 -08:00
Francis Cao 530c21dac0 add limit 50 to event chart, metrics table, and UTM report 2026-02-17 21:55:35 -08:00
Mike CaoandClaude Opus 4.6 fee155c65b fix WeeklyTraffic header clipping in board panels
Separate day name headers into their own grid row instead of embedding
them inside the hourly data grid with marginBottom, which pushed the
text outside the fixed 16px row height.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 17:27:15 -08:00
Mike CaoandClaude Opus 4.6 ce9e2416fb Add Web Vitals performance tracking (LCP, INP, CLS, FCP, TTFB)
End-to-end performance metrics tracking: dedicated database table with
percentile aggregation, tracker collection behind data-perf attribute,
/api/send handling, report API endpoints, and Performance dashboard page
with threshold-based metric cards, time-series chart, and per-page breakdown.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-08 19:25:20 -08:00
Mike Cao 8cd3c03702 Added opacity to tooltips. 2026-02-08 00:04:13 -08:00
Mike CaoandClaude Opus 4.6 50edb71687 Simplify i18n: remove old react-intl artifacts, rename formatMessage to t, replace FormattedMessage with t.rich().
- Rewrite messages.ts to plain string key maps (remove MessageDescriptor)
- Rewrite useMessages hook to expose t from useTranslations() directly
- Rename formatMessage → t across 193 consumer files
- Replace custom FormattedMessage component with next-intl t.rich()
- Update 52 language files to use rich text tags (<b>, <a>)
- Remove all direct imports from @/components/messages in favor of useMessages()

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 11:19:04 -08:00
Mike Cao af2c823c1b Fixed tooltip text sizes. 2026-02-07 03:39:56 -08:00
Francis Cao 795a1caadf fix panel and metrics card css 2026-02-06 17:24:11 -08:00
Francis Cao 895abdbbaf Clean up colors and Selects 2026-02-06 16:48:45 -08:00
Francis Cao 9b814aa1ca revert prisma schema to latest, add global css for scroll-bar, fix css 2026-02-06 15:06:10 -08:00
Mike CaoandClaude Opus 4.6 b3a77d7c04 Fix CompareTables select width, WebsiteSelect min height, and MetricCard gap.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 04:00:42 -08:00
Mike CaoandClaude Opus 4.6 84522b2475 Fix ChangeLabel colors to use react-zen theme variables.
Replace old CSS variables with new theme tokens for success, error,
and neutral states.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 03:31:20 -08:00
Mike CaoandClaude Opus 4.6 1b347531dc Add hover background to MetricsTable rows.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 02:24:41 -08:00
Mike CaoandClaude Opus 4.6 c6dd3fb6ff Rename SideMenu to NavMenu, fix tooltips, and update react-zen.
- Rename SideMenu to NavMenu with visible group title labels and selected item highlighting
- Update react-zen to 0.242.0 and fix responsive breakpoints (xs -> base)
- Style floating tooltips with inverted background across WorldMap, charts, and WeeklyTraffic
- Add CSS variables for primary color and use IconLabel consistently
- Remove stray console.log from LoadingPanel

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 01:58:55 -08:00
Mike CaoandClaude Opus 4.6 7cafc3e61d Replace numeric prop values with named react-zen values.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-05 23:41:10 -08:00