view products
This commit is contained in:
@@ -16,6 +16,8 @@ export interface CartQuantityControlProps {
|
||||
addLabel?: string
|
||||
/** متن دکمه در حالت loading */
|
||||
addingLabel?: string
|
||||
/** عرض کامل (۱۰۰٪) */
|
||||
fullWidth?: boolean
|
||||
}
|
||||
|
||||
const Spinner = () => (
|
||||
@@ -30,11 +32,12 @@ export function CartQuantityControl({
|
||||
addDisabled = false,
|
||||
addLabel = 'افزودن',
|
||||
addingLabel = 'در حال افزودن...',
|
||||
fullWidth = false,
|
||||
}: CartQuantityControlProps) {
|
||||
return (
|
||||
<motion.div
|
||||
whileTap={{ scale: 1.05 }}
|
||||
className="bg-background active:drop-shadow-xs max-w-[115px] rounded-md w-full h-8 inline-flex p-1 justify-between items-center gap-2 relative overflow-hidden"
|
||||
className={`bg-background active:drop-shadow-xs rounded-md h-8 inline-flex p-1 justify-between items-center gap-2 relative overflow-hidden ${fullWidth ? 'w-full' : 'max-w-[115px] w-full'}`}
|
||||
>
|
||||
{quantity <= 0 ? (
|
||||
<button
|
||||
|
||||
Reference in New Issue
Block a user