Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

211
Views
No se puede crear el botón de desplazamiento del elemento receptivo

Hola chicos, acabo de crear 2 botones para desplazar los artículos de mis productos. Pero no funciona en el diseño receptivo.

ingrese la descripción de la imagen aquí

Puede ver los botones aquí, pero cuando hago clic en este botón, no funcionan bien. En algunas dimensiones funciona bien, pero cuando abro la barra de herramientas del dispositivo y cambio las dimensiones, no funciona.

 const MainContainer = () => { const [{ foodItems, cartShow }, dispatch] = useStateValue(); const [scrollValue, setscrollValue] = useState(0); useEffect(() => {}, [scrollValue]); return ( <div> <div className="w-full h-auto flex flex-col items-center justify-center"> <HomeContainer /> <section className="w-full my-6"> <div className="w-full flex items-center justify-between"> <p className="text-2xl font-semibold capitalize text-headingColor relative before:absolute before:rounded-lg before:content before:w-32 before:h-1 before:-bottom-2 before:left-0 before:bg-gradient-to-tr from-orange-400 to-orange-600 transition-all ease-in-out duration-100"> Yeni və dadlı </p> <div className="hidden lg:flex gap-3 items-center"> <motion.div whileTap={{ scale: 0.75 }} className="w-8 h-8 rounded-lg bg-orange-300 hover:bg-orange-500 cursor-pointer hover:shadow-lg flex items-center justify-center" onClick={() => setscrollValue(-300)} > <MdChevronLeft className="text-lg text-white" /> </motion.div> <motion.div whileTap={{ scale: 0.75 }} className="w-8 h-8 rounded-lg bg-orange-300 hover:bg-orange-500 cursor-pointer hover:shadow-lg flex items-center justify-center" onClick={() => setscrollValue(300)} > <MdChevronRight className="text-lg text-white" /> </motion.div> </div> </div>

Puedo proporcionar un enlace de github si es posible. Gracias

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!