Skip to content

fix: include tax in cumulative value breakdown when tax is not inclusive#282

Merged
paulofph merged 2 commits into
mainfrom
fix/tax-breakdown
May 25, 2026
Merged

fix: include tax in cumulative value breakdown when tax is not inclusive#282
paulofph merged 2 commits into
mainfrom
fix/tax-breakdown

Conversation

@paulofph
Copy link
Copy Markdown
Member

When isTaxInclusive=false and a tax rate is provided, both tierAmountDecimal (unit price per tier) and totalAmountDecimal (total for that tier) now correctly include the tax amount. This makes the breakdown transparent and shows how the final price was calculated from the base price plus tax.

  • Calculate unitAmountWithTax for unit price display
  • Apply tax multiplier to tier amounts in breakdown when isTaxInclusive=false
  • Update test expectations to reflect gross amounts in breakdown

When isTaxInclusive=false and a tax rate is provided, both tierAmountDecimal
(unit price per tier) and totalAmountDecimal (total for that tier) now correctly
include the tax amount. This makes the breakdown transparent and shows how the
final price was calculated from the base price plus tax.

- Calculate unitAmountWithTax for unit price display
- Apply tax multiplier to tier amounts in breakdown when isTaxInclusive=false
- Update test expectations to reflect gross amounts in breakdown

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented May 25, 2026

🦋 Changeset detected

Latest commit: 9e380f5

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@epilot/pricing Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Copy Markdown
Member

@alexmarqs alexmarqs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm! good catch!

@paulofph paulofph merged commit dda5555 into main May 25, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants