@runwell/shopify-toolkit 0.24.1 → 0.24.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "runwell-bundle-system",
3
- "version": "0.4.1",
3
+ "version": "0.4.2",
4
4
  "category": "catalog",
5
5
  "source": "runwell",
6
6
  "base": "bundle-system",
@@ -206,8 +206,14 @@
206
206
  {%- capture tier_label -%}{{ t.qty }}x {{ product.title }}{%- endcapture -%}
207
207
  {%- endif -%}
208
208
 
209
- {%- assign discount_amount = tier_base_price | times: t.discount_pct | divided_by: 100 -%}
210
- {%- assign per_unit_price = tier_base_price | minus: discount_amount -%}
209
+ {%- comment -%}
210
+ Compute per_unit as base * (100 - pct) / 100 directly,
211
+ rather than base - (base * pct / 100). The direct form
212
+ avoids a half-cent rounding step that would otherwise
213
+ push, e.g., 50% off $49.99 from $24.99 up to $25.00.
214
+ {%- endcomment -%}
215
+ {%- assign keep_pct = 100 | minus: t.discount_pct -%}
216
+ {%- assign per_unit_price = tier_base_price | times: keep_pct | divided_by: 100 -%}
211
217
  {%- assign total_price = per_unit_price | times: t.qty -%}
212
218
  {%- assign full_price = tier_base_price | times: t.qty -%}
213
219
  {%- assign savings = full_price | minus: total_price -%}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@runwell/shopify-toolkit",
3
- "version": "0.24.1",
3
+ "version": "0.24.2",
4
4
  "description": "Reusable Shopify theme modules from Runwell. Replaces typically app-driven features (reviews, wishlist, urgency, FAQ, post-purchase upsell, exit popups, free-ship progress, sticky ATC, testimonials, badges, bundles) with native Liquid + JS + CSS that ship across multiple client themes via a config-driven sync CLI.",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",