E-Commerce
Stock/Availability Indicator
Dot-and-label status line that derives in-stock/low-stock/out-of-stock from a quantity and threshold, or accepts an explicit status.
$ velocityx add stock-availability-indicator Built for astro.
Full docs for Stock/Availability Indicator →
Needs a licence key —
subscribe here, then
velocityx loginonce.
Props
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| quantity | number | No | ||
| lowStockThreshold | number | No | 5 | |
| status | 'in-stock' | 'low-stock' | 'out-of-stock' | 'backorder' | No | ||
| expectedDate | string | No | ||
| className | string | No | '' |
File this creates
The CLI writes this path into your project, relative to its root — nothing else moves.
components/velocity/stock-availability-indicator/StockAvailabilityIndicator.astro Using the Stock/Availability Indicator component
Install it with velocityx add stock-availability-indicator.
The CLI writes the source straight into your project — no runtime dependency, no registry
lock-in, and it themes itself from the same primary-*/accent-* scale as the rest of the library.
Related components
More from E-Commerce.
Order totals block listing subtotal, shipping, tax and discount rows that only render when passed, plus a grand total.
astroResponsive image-and-label tile grid linking into catalogue categories, with an optional item count.
astroCentred placeholder for an empty cart with icon, copy and a continue-shopping CTA.
astroPost-checkout success panel with order number, delivery estimate, line items and total paid.
astro