sigilUI

Billing Chart

A stacked bar chart for visualizing cost breakdowns and billing trends over time.

@sigil-ui/componentsReact

Preview

Live preview Interactive

Import

import { BillingChart } from "@sigil-ui/components";

Usage

<BillingChart
  currency="$"
  periods={[
    {
      label: "Jan",
      segments: [
        { label: "Compute", value: 120 },
        { label: "Storage", value: 45 },
        { label: "Network", value: 20 },
      ],
    },
  ]}
  showLegend
/>

Props

PropTypeDefaultDescription
periodsBillingPeriod[]—Billing periods with stacked segments
widthnumber500SVG width
heightnumber260SVG height
currencystring"$"Currency symbol for labels
showLegendbooleantrueShow color legend

Token integration

CSS VariablePurpose
--s-primaryFirst segment color
--s-successSecond segment color
--s-warningThird segment color
--s-borderGrid lines
--s-textTotal value labels
--s-text-mutedAxis and legend text
--s-font-monoValue font family