npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@anilreddy11/trivo-ui

v0.4.0

Published

Trivo design system — React Native component library

Readme

@anilreddy11/trivo-ui

Shared design system for Trivo — a dark-theme React Native component library used by trivo-mobile and trivo-web.

Install

npm install @anilreddy11/trivo-ui

Peer dependencies

Your app must already include:

  • react
  • react-native
  • react-native-reanimated
  • react-native-svg
  • react-native-gesture-handler
  • expo-haptics

Configure Reanimated in your app's babel.config.js:

module.exports = {
  presets: ['module:@react-native/babel-preset'],
  plugins: ['react-native-reanimated/plugin'],
};

Quick start

import {
  PageContainer,
  MacroRing,
  SectionHeader,
  colors,
} from '@anilreddy11/trivo-ui';

export function FitnessToday() {
  return (
    <PageContainer>
      <SectionHeader title="Today" subtitle="Your macros" />
      <MacroRing
        calories={{ current: 1420, goal: 2000 }}
        protein={{ current: 98, goal: 150 }}
        carbs={{ current: 145, goal: 200 }}
        fat={{ current: 42, goal: 65 }}
        size={260}
        animated
      />
    </PageContainer>
  );
}

Design tokens

All colors, spacing, typography, and radius values live in tokens:

import { colors, spacing, radius, fontSize, fontWeight } from '@anilreddy11/trivo-ui';

const card = {
  backgroundColor: colors.bg.surface,
  padding: spacing.md,
  borderRadius: radius.md,
};

Never hardcode hex values in consuming apps — import from tokens.

Components

Primitives

| Component | Description | |------------|--------------------------------------------------| | Box | Layout container with spacing props | | Text | Typography with token-based size/weight/color | | Pressable| Reanimated scale press + optional haptic feedback|

Layout

| Component | Description | |-----------------|-----------------------------| | PageContainer | Safe-area scrollable screen | | SectionHeader | Title + optional action | | Divider | Horizontal or vertical rule |

Data display

| Component | Description | |---------------|--------------------------------------------------| | MacroRing | Signature 4-ring animated macro progress | | StatCard | Metric card with accent stripe | | ProgressBar | Animated horizontal bar | | SpendingBar | Stacked budget breakdown | | NutrientRow | Label + progress for one nutrient | | WeightChart | Simple SVG weight trend |

Forms

| Component | Description | |-------------------|--------------------------------| | Input | Text field with label/error | | SearchBar | Debounced search with clear | | QuantitySelector| +/- stepper | | SegmentedControl| Tab-style option picker |

Feedback

| Component | Description | |-------------|--------------------------| | Toast | Auto-dismiss notification| | Modal | Centered overlay dialog | | Skeleton | Loading placeholder | | EmptyState| Zero-data CTA screen |

Trivo AI

| Component | Description | |------------------|--------------------------------| | ChatBubble | User vs assistant message | | TrivoAIInput | Chat input with focus animation| | QuickAddPill | Horizontal suggestion chips | | TypingIndicator| Animated thinking dots | | ApiKeySetup | Anthropic API key onboarding |

MacroRing

The hero fitness component — four concentric rings (calories → protein → carbs → fat) with spring animation, SVG glow on the active ring, and danger + shake when any macro exceeds 100% of goal.

<MacroRing
  calories={{ current: 2100, goal: 2000 }}
  protein={{ current: 120, goal: 150 }}
  carbs={{ current: 180, goal: 200 }}
  fat={{ current: 70, goal: 65 }}
  size={280}
  animated
/>

Ring colors map to tokens:

  • Calories → colors.semantic.info
  • Protein → colors.brand.fitness
  • Carbs → colors.brand.focus
  • Fat → colors.brand.finance

Development

cd trivo-ui
npm install
npm run build

Build output goes to dist/ via TypeScript (tsc).

Publishing

npm login
npm publish --access public

Start at 0.1.0, follow semver for breaking changes.

License

MIT