affectUI › Screens › App screens

Analytics

Revenue dashboard: key figures, revenue by channel, breakdown, top products and weekly trends.

Part of affectUI Pro. Install: npx shadcn@latest add https://www.affectui.com/r/analytics.json · Import from @/components/ui/analytics

When to use

  • Revenue, product or marketing dashboards
  • Overview pages that combine key figures and charts

When not to use

  • Live monitoring with many changing values – use a denser layout

Usage

import { AnalyticsScreen } from "@/components/ui/analytics";

export default function Page() {
  return <AnalyticsScreen workspace="Acme" user={{ name: "Alex Morgan" }} onNavigate={(label) => router.push(routes[label])} />;
}

Props

NameTypeDefaultDescription
onNavigate(label: string) => voidCalled with the label of a sidebar item
workspacestring"Acme"Workspace name in the sidebar
user{ name: string; avatar?: string }{ name: "Alex Morgan" }Account at the bottom of the sidebar
classNamestringExtra class on the root

Accessibility

  • Sidebar items, tabs and toolbar actions are real buttons with labels
  • Icons are decorative and hidden from screen readers

Responsive

  • Fills its container – give it the full viewport height in your app
  • Dark mode built in: switches when an ancestor (usually <html>) has the class dark or data-theme="dark"; colors are CSS variables on .ui-as

Requirements

  • React 19
  • @hugeicons/react
  • @hugeicons/core-free-icons
  • App Shell, KPI Chart and Button (installed with it)