diff --git a/apps/web/config/billing.sample.config.ts b/apps/web/config/billing.sample.config.ts index b33b62ec3..23bac72b0 100644 --- a/apps/web/config/billing.sample.config.ts +++ b/apps/web/config/billing.sample.config.ts @@ -33,14 +33,7 @@ export default createBillingSchema({ id: 'price_1NNwYHI1i3VnbZTqI2UzaHIe', name: 'Addon 2', cost: 9.99, - type: 'metered' as const, - unit: 'GB', - tiers: [ - { - cost: 0.5, - upTo: 'unlimited', - }, - ], + type: 'flat' as const, }, ], }, diff --git a/packages/billing/gateway/src/components/pricing-table.tsx b/packages/billing/gateway/src/components/pricing-table.tsx index b15fb665f..e4ab8b96b 100644 --- a/packages/billing/gateway/src/components/pricing-table.tsx +++ b/packages/billing/gateway/src/components/pricing-table.tsx @@ -150,9 +150,11 @@ function PricingItem( const lineItem = props.primaryLineItem; - // we want to exclude the primary plan from the list of line items - // since we are displaying the primary line item separately as the main price - const lineItemsToDisplay = props.plan.lineItems; + // we exclude flat line items from the details since + // it doesn't need further explanation + const lineItemsToDisplay = props.plan.lineItems.filter((item) => { + return item.type !== 'flat'; + }); return (