mirror of
https://github.com/vercel/commerce.git
synced 2025-07-25 11:11:24 +00:00
feat: adding more information warranty, part number, sku, speciall offers
Signed-off-by: Chloe <pinkcloudvnn@gmail.com>
This commit is contained in:
@@ -11,12 +11,10 @@ type CoreChargeBadgeProps = {
|
||||
|
||||
const CoreChargeBadge = ({ variants, selectedOptions }: CoreChargeBadgeProps) => {
|
||||
const selectedOptionsMap = new Map(selectedOptions.map((option) => [option.name, option.value]));
|
||||
console.log({ selectedOptionsMap, variants });
|
||||
const variant = variants.find((variant: ProductVariant) =>
|
||||
variant.selectedOptions.every((option) => option.value === selectedOptionsMap.get(option.name))
|
||||
);
|
||||
|
||||
console.log({ variant });
|
||||
return <CoreCharge variant={variant} sm />;
|
||||
};
|
||||
|
||||
|
@@ -183,7 +183,7 @@ export default function CartModal({ cart }: { cart: Cart | undefined }) {
|
||||
</div>
|
||||
<a
|
||||
href={cart.checkoutUrl}
|
||||
className="block w-full rounded-full bg-blue-600 p-3 text-center text-sm font-medium text-white opacity-90 hover:opacity-100"
|
||||
className="block w-full rounded-full bg-secondary p-3 text-center text-sm font-medium text-white opacity-90 hover:opacity-100"
|
||||
>
|
||||
Proceed to Checkout
|
||||
</a>
|
||||
|
Reference in New Issue
Block a user