create and update coupon reponsive

This commit is contained in:
hamid zarghami
2025-12-30 14:25:09 +03:30
parent e7042283dc
commit 909bc4f879
3 changed files with 9 additions and 9 deletions
+4 -4
View File
@@ -85,7 +85,7 @@ const CreateCoupon: FC = () => {
<div className='flex justify-end'>
<Button
className='flex gap-4 w-fit px-5'
className='flex gap-4 w-full sm:w-fit px-5'
isloading={isCreating}
onClick={() => formik.handleSubmit()}
>
@@ -96,9 +96,9 @@ const CreateCoupon: FC = () => {
</Button>
</div>
<div className='flex gap-7 mt-7'>
<div className='flex flex-col lg:flex-row gap-7 mt-7'>
<div className='flex-1'>
<div className='bg-white rounded-4xl p-8'>
<div className='bg-white rounded-4xl p-4 sm:p-6 lg:p-8'>
<div className='text-lg font-light mb-6'>کد تخفیف جدید</div>
<CouponBasicInfo
@@ -115,7 +115,7 @@ const CreateCoupon: FC = () => {
</div>
</div>
<div className='w-80 flex-shrink-0'>
<div className='w-full lg:w-80 flex-shrink-0'>
<CouponSidebar
formik={formik}
categories={categories}
+4 -4
View File
@@ -129,7 +129,7 @@ const UpdateCoupon: FC = () => {
<div className='flex justify-end'>
<Button
className='flex gap-4 w-fit px-5'
className='flex gap-4 w-full sm:w-fit px-5'
isloading={isUpdating}
onClick={() => formik.handleSubmit()}
>
@@ -140,9 +140,9 @@ const UpdateCoupon: FC = () => {
</Button>
</div>
<div className='flex gap-7 mt-7'>
<div className='flex flex-col lg:flex-row gap-7 mt-7'>
<div className='flex-1'>
<div className='bg-white rounded-4xl p-8'>
<div className='bg-white rounded-4xl p-4 sm:p-6 lg:p-8'>
<div className='text-lg font-light mb-6'>ویرایش کد تخفیف</div>
<CouponBasicInfo
@@ -163,7 +163,7 @@ const UpdateCoupon: FC = () => {
</div>
</div>
<div className='w-80 flex-shrink-0'>
<div className='w-full lg:w-80 flex-shrink-0'>
<CouponSidebar
formik={formik}
categories={categories}
@@ -23,7 +23,7 @@ interface CouponSidebarProps {
const CouponSidebar: FC<CouponSidebarProps> = ({ formik, categories, foods }) => {
return (
<div className='bg-white rounded-4xl p-6'>
<div className='bg-white rounded-4xl p-4 sm:p-6'>
<div className='mb-6'>
<div className='text-sm mb-3'>وضعیت تخفیف</div>
<SwitchComponent