fix button

This commit is contained in:
hamid zarghami
2025-12-16 15:00:18 +03:30
parent b383e54c88
commit 7bd15fce31
2 changed files with 24 additions and 23 deletions
@@ -67,12 +67,14 @@ const CartSummary = ({ description = '', onDescriptionChange }: CartSummaryProps
</div>
</div>
<div className='flex flex-col gap-4'>
<div className='flex flex-col gap-4 pb-24'>
<div>
<div className='text-sm font-semibold'>
{`جمع خرید: ${formatPrice(totalPrice)} تومان`}
</div>
</div>
</div>
<Link
href={'order/checkout/0'}
onClick={(event) => {
@@ -87,13 +89,10 @@ const CartSummary = ({ description = '', onDescriptionChange }: CartSummaryProps
return;
}
}}
className={isCartEmpty ? 'pointer-events-none opacity-60' : ''}
className={`fixed bottom-0 left-0 right-0 z-50 bg-white border-t border-border p-4 w-full ${isCartEmpty ? 'pointer-events-none opacity-60' : ''}`}
>
<div className='flex justify-end'>
<Button className='!w-fit px-4' disabled={isCartEmpty}>{t('ButtonCheckout')}</Button>
</div>
<Button className='!w-full px-4' disabled={isCartEmpty}>{t('ButtonCheckout')}</Button>
</Link>
</div>
{/* {!isCartEmpty && (
<div className='flex items-center justify-between rounded-xl border border-border px-4 py-3 text-xs text-muted-foreground'>
@@ -85,7 +85,7 @@ export const SummarySection = ({ cartModal, onToggleCartModal, deliveryType }: S
return (
<>
<section className="">
<div className="py-3 pb-10">
<div className="py-3 pb-28">
<div className='w-full flex justify-between items-center gap-2'>
<h3 className="text-sm2 font-medium leading-5 inline-block">{t("SectionSummary.Title")}</h3>
<button
@@ -116,7 +116,9 @@ export const SummarySection = ({ cartModal, onToggleCartModal, deliveryType }: S
<span className='font-medium '>{t("SectionSummary.TotalLabel")}</span>
<span className='font-bold place-self-end'>{formatPrice(total)} T</span>
</div>
<Button onClick={handleSubmit} className='mt-6'>
</div>
<div className='fixed bottom-0 left-0 right-0 z-50 bg-white dark:bg-background border-t border-border p-4 w-full'>
<Button onClick={handleSubmit} className='px-10 w-full'>
{t("ButtonSubmit")}
</Button>
</div>