46 Commits

Author SHA1 Message Date
Usman Baig
8c0700f406 fix: filter by all merged referrers when clicking a group (e.g. Pulse covers both prod and staging) 2026-03-28 00:24:04 +01:00
Usman Baig
94f9db9e51 feat: add Pulse to referrer registry — shows 'Pulse' with logo for pulse.ciphera.net and pulse-staging.ciphera.net 2026-03-28 00:05:51 +01:00
Usman Baig
5dfc3a5636 ci: use self-hosted runner, add filter/date/client tests 2026-03-24 19:58:57 +01:00
Usman Baig
a3c1af7c95 fix: frontend consistency audit — 55 files cleaned up
Consistency fixes:
- Extract getThisWeekRange/getThisMonthRange to shared lib/utils/dateRanges.ts
  (removed 4 identical copy-pasted definitions)
- Add error boundaries for behavior, cdn, search, pagespeed pages
  (4 new error.tsx files — previously fell through to generic parent error)
- Add "View setup guide" CTA to empty states on journeys and behavior pages
  (previously showed text with no actionable button)
- Fix non-lazy useState initializer in funnel detail page
- Fix Bot & Spam settings header from text-xl to text-2xl (matches all other sections)
- Add useMinimumLoading to PageSpeed skeleton (consistent with all other pages)

Cleanup:
- Remove 438 redundant dark: class prefixes (app is dark-mode only)
  text-neutral-500 dark:text-neutral-400 → text-neutral-400 (206 occurrences)
  text-neutral-900 dark:text-white → text-white (232 occurrences)
- Remove dead @stripe/react-stripe-js and @stripe/stripe-js packages
  (billing migrated to Polar, no code imports Stripe)
- Remove duplicate motion package (framer-motion is the one actually used)
2026-03-23 19:50:16 +01:00
Usman Baig
55a08301f4 fix(build): extract FAVICON_SERVICE_URL to prevent server-side createContext error
The share/[id] layout is a server component that imported FAVICON_SERVICE_URL
from icons.tsx, pulling in the entire React icon registry and triggering
createContext on the server. Moved the constant to its own favicon.ts module.
2026-03-23 13:29:53 +01:00
Usman Baig
75bf8acd1e refactor(referrers): unify icon, display name, and favicon into single registry
Replace three separate data structures (getReferrerIcon if-chain,
REFERRER_DISPLAY_OVERRIDES, REFERRER_PREFER_ICON) with a single
REFERRER_REGISTRY. All matching is now exact key/hostname lookup
via resolveReferrer() — no more substring includes() that caused
collisions like t.co matching reddit.com.
2026-03-23 13:21:15 +01:00
Usman Baig
4064f7eabf fix(referrers): prevent t.co substring match on reddit.com
"reddit.com".includes("t.co") was true, causing Reddit to show the
X icon. Use exact match or slash-delimited check instead.
2026-03-23 13:12:57 +01:00
Usman Baig
508bb006a8 fix(referrers): replace low-res Google favicon globe with proper icons
Detect Google's 16x16 default globe fallback via naturalWidth on load
and fall back to Phosphor icons. Add Chrome icon for googlechrome.github.io,
CursorClick for Direct, and abbreviation support (ig, fb, yt).
2026-03-23 12:23:10 +01:00
Usman Baig
5008992f59 feat: replace Phosphor brand icons with real SVG logos
Uses @icons-pack/react-simple-icons for available brands (Google,
Facebook, Instagram, GitHub, YouTube, Reddit, etc.) and inline SVGs
for brands missing from the package (X, LinkedIn, OpenAI, Bing).
All icons now show actual brand logos with correct colors.
2026-03-21 23:38:55 +01:00
Usman Baig
5b0d0e1dc1 fix: use Phosphor icons for all known referrers, skip unreliable favicons
Google's favicon service returns wrong/low-quality icons for known
services. Now all major platforms, search engines, and AI assistants
use their Phosphor icon directly. Favicons only fetched for unknown
domains.
2026-03-21 23:22:31 +01:00
Usman Baig
bf3097c26e fix: invert macOS and PlayStation icons in dark mode
Both logos are dark/black and disappear against dark backgrounds.
Apply dark:invert CSS filter to flip them to white in dark mode.
2026-03-19 13:19:08 +01:00
Usman Baig
1696e428ab feat: add real OS logo icons for 16 operating systems
Replace Phosphor generic icons with branded logos from
ngeenx/operating-system-logos. Covers Windows, macOS, Linux, Android,
iOS, ChromeOS, HarmonyOS, KaiOS, Tizen, webOS, FreeBSD, OpenBSD,
NetBSD, PlayStation, Xbox, and Nintendo.
2026-03-19 11:23:29 +01:00
Usman Baig
a7ac2cb9d7 feat: add browser logo icons for all detected browsers
Use real browser logos from alrra/browser-logos (SVG where available,
PNG fallback for archived browsers). Replaces the generic globe icon
with actual Chrome, Firefox, Safari, Edge, Opera, Brave, Vivaldi, Arc,
Samsung Internet, UC Browser, Yandex, Waterfox, Pale Moon, DuckDuckGo,
Maxthon, Silk, Puffin, Tor, and Opera Mini logos.
2026-03-19 11:09:16 +01:00
Usman Baig
b305b5345b refactor: remove performance insights (Web Vitals) feature entirely
Remove Performance tab, PerformanceStats component, settings toggle,
Web Vitals observers from tracking script, and all related API types
and SWR hooks. Duration tracking is preserved.
2026-03-14 22:47:33 +01:00
Usman Baig
25210013d3 feat: centralise date/time formatting with European conventions
All dates now use day-first ordering (14 Mar 2025) and 24-hour time
(14:30) via a single formatDate.ts module, replacing scattered inline
toLocaleDateString/toLocaleTimeString calls across 12 files.
2026-03-14 13:31:30 +01:00
Usman Baig
3fc0dec9d9 fix: show branded icons for UA-inferred referrers instead of broken favicons
Plain name referrers like "Instagram" or "WhatsApp" (inferred from
User-Agent) were being passed to the favicon service as invalid
domains, returning a generic globe. Now skips favicon fetch for
any referrer without a dot, falling through to Phosphor icons.
2026-03-12 12:31:21 +01:00
Usman Baig
7bd922a012 feat: add shared link referrer icon and new social platform icons
Add branded icons for WhatsApp, Telegram, Snapchat, Pinterest, Threads.
Add link icon for new "Shared Link" referrer category. Update changelog.
2026-03-12 12:08:07 +01:00
Usman Baig
205cdf314c perf: bound SWR cache, clean stale storage, cap annotations
Add LRU cache provider (200 entries) to prevent unbounded SWR memory
growth. Clean up stale PKCE localStorage keys on app init. Cap chart
annotations to 20 visible reference lines with overflow indicator.
2026-03-10 21:19:33 +01:00
Usman Baig
7f9ad0e977 refactor: switch icons from react-icons to Phosphor
Replace react-icons and @radix-ui/react-icons with @phosphor-icons/react
for a consistent icon style across all dashboard panels.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-09 00:23:31 +01:00
Usman Baig
e72e6f2ec5 feat: add AI traffic source identification
Display proper brand icons and names for AI referrers (ChatGPT,
Perplexity, Claude, Gemini, Copilot, DeepSeek, Grok, Meta AI,
You.com, Phind) in Top Referrers panel.
2026-03-06 19:25:05 +01:00
Usman Baig
b7426d6128 fix: login loading overlay, deduplicate getCookieDomain (F-18, F-11)
- Login page shows LoadingOverlay during redirect instead of blank screen
- Extract getCookieDomain() to shared lib/utils/cookies.ts
2026-03-01 21:02:28 +01:00
Usman Baig
c9123832a5 fix: fix broken images from CSP, remove dead code, upgrade React types
- Add ciphera.net and *.gstatic.com to CSP img-src (fixes app switcher
  icons and site favicons blocked by Content Security Policy)
- Delete 6 unused component/utility files and orphaned test
- Upgrade @types/react and @types/react-dom to v19 (matches React 19 runtime)
- Fix logger test to use vi.stubEnv for React 19 type compatibility
2026-03-01 15:33:37 +01:00
Usman Baig
b3a303d6df fix: improve session management and UI highlights 2026-03-01 13:53:54 +01:00
Usman Baig
b5f83ce582 feat: add unit tests and CI configuration 2026-03-01 00:11:54 +01:00
Usman Baig
22bc18a7cc chore: update CHANGELOG.md to include Request ID tracing for debugging, enhancing request tracking across services, and update API client to propagate Request ID in headers 2026-02-27 17:26:08 +01:00
Usman Baig
39eac4100e feat: update favicon retrieval to use a centralized service URL for consistency across the application 2026-02-22 21:02:11 +01:00
Usman Baig
2d0307d328 fix: enhance error logging by replacing console.error with a centralized logger across the application to improve security and maintainability 2026-02-22 20:57:21 +01:00
Usman Baig
8007900940 feat: enhance accessibility across the application by improving keyboard navigation and screen reader support for various components 2026-02-22 20:39:18 +01:00
Usman Baig
d1d82f5b3c feat: refine data retention adjustment logic in SiteSettingsPage to snap to nearest valid option upon subscription load 2026-02-21 19:58:48 +01:00
Usman Baig
1ae20dba4c feat: add data retention settings to SiteSettingsPage, including subscription-based options and UI updates for user interaction 2026-02-21 18:21:43 +01:00
Usman Baig
ae91147b6c chore: update @ciphera-net/ui dependency to version 0.0.57 in package.json and package-lock.json; refactor imports across multiple components for consistency 2026-02-17 20:49:55 +01:00
Usman Baig
3b9f33b838 fix: extract notification utility functions for better code organization and reuse in NotificationsPage and NotificationCenter 2026-02-16 20:46:36 +01:00
Usman Baig
08110d7245 chore: update CHANGELOG for version 0.5.1-alpha and replace Twitter icon with X logo in referrer display 2026-02-12 21:55:49 +01:00
Usman Baig
4aefca7118 feat: add "Updated X ago" display for realtime indicators and implement auto-refresh tick functionality 2026-02-11 20:49:09 +01:00
Usman Baig
16d8765f46 feat: enhance Top Referrers display by merging referrer rows and adding friendly names 2026-02-11 16:57:01 +01:00
Usman Baig
ddbb2494b1 feat: add getReferrerDisplayName utility to enhance referrer display in ExportModal and TopReferrers components 2026-02-11 16:43:35 +01:00
Usman Baig
51648c82c7 chore: update CHANGELOG.md for 0.3.0-alpha release and implement favicon support in Top Referrers component 2026-02-11 16:34:44 +01:00
Usman Baig
eaf02c853f fix: improve error handling across various components; utilize getAuthErrorMessage for consistent user-facing error messages 2026-02-03 19:31:26 +01:00
Usman Baig
e75d70269f refactor(replay): remove session replay functionality and related components to streamline codebase 2026-01-23 18:21:50 +01:00
Usman Baig
035d78175f refactor: update branding from Ciphera Pulse to Pulse across the application for consistency and clarity 2026-01-19 16:58:09 +01:00
Usman Baig
9dbe74fd9f refactor: update references from Ciphera Analytics to Ciphera Pulse across the application for consistent branding and messaging 2026-01-19 16:49:42 +01:00
Usman Baig
861ce94e05 feat: add privacy snippet feature in site settings for easy copying to privacy policy 2026-01-19 15:09:09 +01:00
Usman Baig
42492d64b9 feat(analytics): add icons for browsers, devices, OS, and referrers 2026-01-16 23:39:10 +01:00
Usman Baig
63921d5e04 fix: remove temporary merged files 2026-01-16 22:26:05 +01:00
Usman Baig
19392ab385 feat: display screen resolution, content stats, and advanced metrics on dashboard 2026-01-16 22:22:02 +01:00
Usman Baig
8e10a05eb1 Initial commit: Analytics frontend implementation 2026-01-16 13:14:19 +01:00