Commit 2a204210 authored by Phạm Quang Bảo's avatar Phạm Quang Bảo

update/add hover button category

parent 984d0f95
...@@ -81,6 +81,7 @@ const Home = () => { ...@@ -81,6 +81,7 @@ const Home = () => {
{/* Banner */} {/* Banner */}
<Swiper <Swiper
modules={[Autoplay]} modules={[Autoplay]}
// navigation
autoplay={{ delay: 4000, disableOnInteraction: false }} autoplay={{ delay: 4000, disableOnInteraction: false }}
loop loop
slidesPerView={1} slidesPerView={1}
...@@ -123,7 +124,6 @@ const Home = () => { ...@@ -123,7 +124,6 @@ const Home = () => {
<Swiper <Swiper
modules={[Autoplay]} modules={[Autoplay]}
// navigation // navigation
// pagination={{ clickable: true }}
autoplay={{ delay: 4000, disableOnInteraction: false }} autoplay={{ delay: 4000, disableOnInteraction: false }}
loop loop
spaceBetween={30} spaceBetween={30}
...@@ -187,7 +187,7 @@ const Home = () => { ...@@ -187,7 +187,7 @@ const Home = () => {
{/* category tabs */} {/* category tabs */}
<div className='flex mb-5 flex-wrap justify-between'> <div className='flex mb-5 flex-wrap justify-between'>
<button <button
className={`w-22 cursor-pointer px-4 py-1 rounded-md border ${'all' === tab ? 'border-blue-700 bg-blue-50' : 'border-gray-300 bg-white'}`} className={`w-22 cursor-pointer hover:bg-border-blue-700 hover:bg-blue-50 px-4 py-1 rounded-md border ${'all' === tab ? 'border-blue-700 bg-blue-50' : 'border-gray-300 bg-white'}`}
onClick={() => setTab('all')} onClick={() => setTab('all')}
> >
Tất cả Tất cả
...@@ -195,7 +195,7 @@ const Home = () => { ...@@ -195,7 +195,7 @@ const Home = () => {
{categoryData?.responseData.rows.slice(0, 3).map((category) => ( {categoryData?.responseData.rows.slice(0, 3).map((category) => (
<button <button
key={category.id} key={category.id}
className={`w-22 cursor-pointer px-4 py-1 rounded-md border ${category.name === tab ? 'border-blue-700 bg-blue-50' : 'border-gray-300 bg-white'}`} className={`w-22 cursor-pointer hover:bg-border-blue-700 hover:bg-blue-50 px-4 py-1 rounded-md border ${category.name === tab ? 'border-blue-700 bg-blue-50' : 'border-gray-300 bg-white'}`}
onClick={() => setTab(category.name)} onClick={() => setTab(category.name)}
> >
{category.name} {category.name}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment