fix: rename omnibusRate prop and enable for regular RateCard
This commit is contained in:
@@ -17,7 +17,7 @@ const meta: Meta<typeof CampaignRateCard> = {
|
||||
bannerText: { control: 'text' },
|
||||
rate: { control: 'object' },
|
||||
memberRate: { control: 'object' },
|
||||
referenceRate: { control: 'object' },
|
||||
omnibusRate: { control: 'object' },
|
||||
comparisonRate: { control: 'object' },
|
||||
approximateRate: { control: 'object' },
|
||||
},
|
||||
@@ -42,7 +42,7 @@ export const Default: Story = {
|
||||
label: 'Approx.',
|
||||
unit: 'EUR',
|
||||
},
|
||||
referenceRate: {
|
||||
omnibusRate: {
|
||||
price: '249',
|
||||
label: 'Lowest past price (last 30 days)',
|
||||
unit: 'EUR',
|
||||
@@ -111,7 +111,7 @@ export const CampaignOmnibus: Story = {
|
||||
label: 'Approx.',
|
||||
unit: 'EUR',
|
||||
},
|
||||
referenceRate: {
|
||||
omnibusRate: {
|
||||
price: '101',
|
||||
label: 'Lowest past price (last 30 days)',
|
||||
unit: 'EUR',
|
||||
|
||||
@@ -15,7 +15,7 @@ interface CampaignRateCardProps {
|
||||
bannerText: string
|
||||
rate: Rate
|
||||
memberRate?: Rate
|
||||
referenceRate: Rate
|
||||
omnibusRate?: Rate
|
||||
comparisonRate?: Omit<Rate, 'label'>
|
||||
isHighlightedRate?: boolean
|
||||
approximateRate?: Rate
|
||||
@@ -33,7 +33,7 @@ export default function CampaignRateCard({
|
||||
memberRate,
|
||||
approximateRate,
|
||||
comparisonRate,
|
||||
referenceRate,
|
||||
omnibusRate,
|
||||
bannerText,
|
||||
isHighlightedRate,
|
||||
handleChange,
|
||||
@@ -134,14 +134,14 @@ export default function CampaignRateCard({
|
||||
</div>
|
||||
) : null}
|
||||
</div>
|
||||
{referenceRate ? (
|
||||
{omnibusRate ? (
|
||||
<footer className={styles.footer}>
|
||||
<Typography variant="Tag/sm">
|
||||
<p>{referenceRate.label}</p>
|
||||
<p>{omnibusRate.label}</p>
|
||||
</Typography>
|
||||
<Typography variant="Tag/sm">
|
||||
<p>
|
||||
{referenceRate.price} {referenceRate.unit}
|
||||
{omnibusRate.price} {omnibusRate.unit}
|
||||
</p>
|
||||
</Typography>
|
||||
</footer>
|
||||
|
||||
Reference in New Issue
Block a user