Update Stripe CLI command and key adjustments in line item components

The Stripe CLI command in the workflow file has been updated to use Docker. Additionally, the keys for line-item-details.tsx have been modified, changing item.id and tier.upTo to index to avoid potential key duplication issues within the same component.
This commit is contained in:
giancarlo
2024-04-15 16:31:22 +08:00
parent 2927d9980b
commit 002d252f36
2 changed files with 4 additions and 4 deletions

View File

@@ -18,13 +18,13 @@ export function LineItemDetails(
) {
return (
<div className={'flex flex-col space-y-1'}>
{props.lineItems.map((item) => {
{props.lineItems.map((item, index) => {
// If the item has a description, we render it as a simple text
// and pass the item as values to the translation so we can use
// the item properties in the translation.
if (item.description) {
return (
<div key={item.id} className={className}>
<div key={index} className={className}>
<span className={'flex items-center space-x-1.5'}>
<PlusSquare className={'w-4'} />
@@ -219,7 +219,7 @@ function Tiers({
return (
<span
className={'text-secondary-foreground flex space-x-1 text-xs'}
key={tier.upTo}
key={index}
>
<span>-</span>