Free shipping progress bar
A cart that shows live how much is left to add for free shipping, with a progress bar and recalculated totals.
- Tailwind
- React
- CSS
- WordPress
Description
Showing the free-shipping threshold raises the average basket: this component makes it visible and motivating. On every quantity change the bar moves forward, the message “Only €17.10 left for free shipping” updates and the subtotal, shipping and total lines are recalculated; once the threshold is reached the bar turns green and shipping becomes “Free”. The threshold and shipping cost are set with two attributes (data-slg-threshold, data-slg-shipping), prices with an attribute on each line. Accessibility: the bar uses role="progressbar" with a value read in euros, the message is announced by a role="status" region, plus and minus buttons are 44 px, named after the product and disabled at the limits. Amounts formatted the French way with Intl.NumberFormat, bar animation on transform removed with prefers-reduced-motion, AA contrast in light and dark mode, no horizontal scrolling from 360 px. Example: a Provençal delicatessen.
Code
Loading the code…
The code of this component in
Archive contents
seuil-livraison-gratuite-html-tailwind.zip3 files · 5 Ko
- index.html10 Ko
- README.md4 Ko
- LICENSE.md1 Ko
Tags
Updated on December 2, 2026.
Reviews
No reviews yet.
In the same spirit

A limited-time offer bar: countdown to a fixed date, one-click copyable promo code and a fallback message once the offer is over.
- Tailwind
- React
- CSS
- WordPress

A sales card showing the discount that grows with the cart amount (-10% from €50, -15% from €100…) with a progress bar towards the next tier.
- Tailwind
- React
- CSS
- WordPress

A Christmas gift guide filtered by budget and theme, with the number of ideas announced and an empty state offering to show everything again.
- Tailwind
- React
- CSS
- WordPress

The last order dates for delivery before Christmas, per shipping method, with the days left worked out from the visitor’s date.
- Tailwind
- React
- CSS
- WordPress