Catman · Stock

Weeks of cover

How many weeks the stock on hand lasts at the current rate of sale, on a track against the band the buyer wants it in: short is a stockout risk, over is cash on a shelf.

@twelfth/weeks-of-coverui@twelfth/market-side@twelfth/retail-format
18 wks6 wks over

Examples

Every state

Short1.5 wks2.5 wks short
In band6 wksIn band
Over18 wks6 wks over
Off the track›40 wks28 wks over
No net salesNo net sales

Aged stock line

No lower bound: anything past 26 weeks is aged cash.

41 wks15 wks over

Dense, for a table cell

›34 wks

Installation

  1. 1. Add the block. It brings what it builds on (market-side, retail-format) with it.

    terminal
    npx shadcn@latest add https://ui.twelfth.ai/r/weeks-of-cover.json
  2. 2. Optional: register the namespace in components.json to write npx shadcn add @twelfth/weeks-of-cover from then on.

    components.json
    {
      "registries": {
        "@twelfth": "https://ui.twelfth.ai/r/{name}.json"
      }
    }

API reference

WeeksOfCover

PropTypeDefaultDescription
weeks*number | null—Saleable units ÷ weekly rate of sale. null when nothing sold.
max*number—Top of the healthy band.
minnumber0Bottom of the band, e.g. lead time plus safety stock.
scalenumbermax × 1.5Weeks the track spans; beyond it the figure reads ›.
showStatebooleantrueSay "6 wks over" beside the figure.

Notes

  • role="meter" with the value, band and state in its label.

No bad cookies on these shelves.

Essential cookies keep the store running. Analytics only if you choose.