High Command
LibraryTemplatesGet startedPricing
Get Pro · $79

Guide

Browse everythingGetting startedThemingYour data

Site

HomeTemplatesPricingChangelog

Templates 4

Command centerProFleetProCustomer trackingProField servicePro

Ops and shell 9

App shellProOps modelProAttention queueProMorning briefProShift handoverProLane panelProOwn-fleet partsProAgent action barProCustomizable dashboardPro

Map 17

PMTiles basemapPMTiles routeTrip hologramProBasemap styleMap geometryMapLand texture and dot lensProException heatmap and risk contoursProLane arcsProShipment layerOwn fleet layerProFleet map layersCurated place labels and sitesRoute traceEdge chipsProMap key, filters and paddingMap kitPro

Time and trips 11

Time and trip modelsEvent fieldProIn-transit rowsProImpact lineProActivity barProReplay clockTime controlPlayback overlayProTrip timetableProStage rowWeek cursorPro

Figures, charts and tables 14

Sourced valueKey-figure tileFigure groupPart barBand sparklineKPI stripProChart kitPop barWaterfall cascadeMargin chartsPro13-week cash ladderProWork tableProField railProHorizon gridPro

Zones and dispatch 10

Zones modelDispatch modelProGeofence layerGeofence eventsGeofence drawProService ringsDensity heatmapJob queueProAssign dialogProStop listPro

Design system 3

ThemeShared helpersUI primitives

Routing 3

Offline road routerAustin road graphAustin areas

Libraries 2

Fleet coreRoute core
High Command

Map, fleet and ops-console components for React. Built in-house, copied into your app with the shadcn CLI.

Product

  • Library
  • Templates
  • Pricing
  • Changelog

Build

  • Get started
  • Accessibility
  • Trip hologram

Templates

  • Command center
  • Fleet
  • Field service

New pieces by email. A short note when a release lands.

One email per release. Unsubscribe any time.

© 2026 High Command Pro licenseTermsPrivacyRefundsMap data © OpenStreetMap contributors · OpenFreeMap
Library/Figures, charts and tables

Margin charts

Freight-aware margin: revenue distribution (bar with freight pop-out, or waterfall), the margin band histogram with its tail by customer, lane or mode, the month-on-month margin bridge, month trend bars.

Pro · included in the $79 licenseBlock@highcommand/margin-charts4 files
Get Pro · $79
See it in context
Freight · 12%·Outbound ·Inbound ·Accessorials
Sep 2026 vs AugVolume · Price · Freight cost per order
Why margin after freight moved · Sep 2026 vs Aug 2026
Aug margin after freight
Sep margin after freight

Axis starts at $366k.

Margin after freight rose $41.6k, most of it volume from Hill Country Markets and Atlas Foods Co., partly offset by LTL freight on the Laredo lane. [1][2][3]

41 customers in both months, 3 new, 2 lost. A customer new this month counts all its margin as new; a lost one all of last month's.

Click a figure: what it would open shows here.

Customize
Pro

Part of High Command Pro. The preview and props are open to everyone; installing it needs your license key. Set up your key · Pricing

Installation

$ npx shadcn@latest add @highcommand/margin-charts

Copies the source into your project and pulls in what it needs (6 other items). First time? Add the registry to components.json.

Props

<Distribution />

Where revenue went: product cost, freight and margin after freight, as a bar or a waterfall.

PropTypeDefault
frequiredMarginFigures—

The scope's revenue, costs and margin figures.

variant'bar' | 'waterfall'—

'bar' (default) or 'waterfall'

compactboolean—

A shorter bar (the account profile's Margin section); bar variant only.

stickyboolean—

The account profile: the waterfall drops on the first hover, focus or tap and then stays down.

Also in this item 5

<Pct />3 propsA percent that does not exist (no revenue, or no gross margin) is plain text, not a number button.
PropTypeDefault
vrequiredSourcedValue—

The percent figure; a null value prints a dash.

tone'late' | 'at_risk'—

Status colour for the figure.

classNamestring—

Extra class on the figure.

<TrendBars />2 propsMargin after freight % by order month; a month with no counted orders shows a dash.
PropTypeDefault
trendrequired{ month: string; margin_pct: SourcedValue }[]—

One bar per order month (YYYY-MM), oldest first; the last month is marked with an asterisk.

compactboolean—

A tighter layout with whole-number values.

<Money />3 propsA compact money figure ($2.29M, $414k, $9,950) that opens its source records.
PropTypeDefault
vrequiredSourcedValue—

The money figure.

tone'late' | 'at_risk'—

Status colour for the figure.

classNamestring—

Extra class on the figure.

<MarginBandChart />6 propsA histogram of orders by margin after freight %, with an optional switch to the tail of negative-margin orders by customer, lane or mode.
PropTypeDefault
bandrequiredreadonly MarginBandBin[]—

Every order placed in a bin of its margin after freight %.

marginPctrequiredSourcedValue—

The company's margin after freight %, in the qualifier.

underWaterrequiredSourcedValue—

Orders under water (margin below zero), in the qualifier.

tails{ customer?: readonly MarginTailRow[]; lane?: readonly MarginTailRow[]; mode?: readonly MarginTailRow[] }{}

The tail by customer, lane or mode (each view shows when given).

basisReactNode—

The cost basis note at the qualifier's end ("Avg. purchase cost").

onSelectChartSelect—

A bin or tail row was activated (default: the page opens its `sv`).

<BridgeBox />5 propsPattern 04, concept B (phase 10): why margin after freight moved, behind the month chart.
PropTypeDefault
bridgerequiredBridge—

Why margin moved between two months: its figures, steps and sentence.

onMonth(month: string) => void—

Earlier / Later: load the bridge of another month (from `bridge.months`). Without it the arrows are hidden.

onStep(step: BridgeStep, bridge: Bridge) => void—

A bar's label was activated: open the customers, SKUs or lanes behind it, largest first.

citeHref(c: { type: string; id: string }) => string—

Where a cited record opens. Without it the citations are plain numbers.

defaultOpenbooleanfalse

Start with the bridge open (default: closed until Explain is pressed).

Helpers6 exported functions
  • cents(v: SourcedValue): number

    Freight-aware margin: shared pieces of the margin charts (the distribution, the band, the bridge).

  • pctText(v: SourcedValue): string

    A percent to one decimal ("12.3%"); "—" when the value is null.

  • moneyText(v: SourcedValue): string

    $2.29M, $414k, $9,950: one compact style for every amount on these screens (cents in the records panel).

  • marginTone(v: SourcedValue): "late" | undefined

    Colour means status only: a margin below zero is late (losing money); freight eating half the gross margin or more is at risk.

  • shareTone(v: SourcedValue): "late" | "at_risk" | undefined

    Status for freight as a share of gross margin: late from 100%, at risk from 50%, else none.

  • monthLabel(ym: string, short?: boolean): string

    "YYYY-MM" as "Oct 2026", or "Oct" with `short`.

Dependencies

npm
None beyond React
Builds on
ThemeUI primitivesShared helpersChart kitPop barWaterfall cascade
PreviousWaterfall cascadeNext 13-week cash ladder

On this page

PreviewInstallationPropsDependencies