JSFiddle - React, Tailwind, and code Playground
HTML
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.8.1/slick.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.8.1/slick.js"></script>
<section class="shop">
<div class="container">
<div class="shop__holder">
<div class="shop__box shop__box--content">
<div class="shop__wrap">
<div class="shop__item">
<div class="shop__row">
<div class="shop__slider">
<div class="shop__pic" style="background-image: url(img/shop/shop-1.png);">
</div>
<div class="shop__pic" style="background-image: url(img/shop/shop-2.png);">
</div>
</div>
<button class="shop__add">
<svg viewBox="-10 2 420 392" class="shop__icon">
<use xlink:href="#cart"></use>
</svg>
</button>
<ul class="shop__size">
<li class="shop__user">xs</li>
<li class="shop__user shop__user--active">s</li>
<li class="shop__user">m</li>
<li class="shop__user shop__user--active">l</li>
</ul>
</div>
<p class="shop__title">Товар 1</p>
<div class="shop__block">
<p class="shop__price">5000 </p>
</div>
</div>
<div class="shop__item" >
<div class="shop__row">
<div class="shop__slider">
<div class="shop__pic" style="background-image: url(img/shop/shop-2.png);"></div>
</div>
<button class="shop__add">
<svg viewBox="-10 2 420 392" class="shop__icon">
<use xlink:href="#cart"></use>
</svg>
</button>
<ul class="shop__size">
<li class="shop__user">xs</li>
<li class="shop__user shop__user--active">s</li>
<li class="shop__user">m</li>
<li class="shop__user shop__user--active">l</li>
</ul>
</div>
<p class="shop__title">Товар 2</p>
<div class="shop__block">
<p class="shop__price shop__price--old">5000...
CSS
.shop {
background-color: #fff;
padding-top: 80px;
padding-bottom: 190px;
}
.shop .select__wrap {
max-width: 290px;
margin-bottom: 32px;
}
.shop .select__placeholder {
border: 1px solid #ECEDF3;
border-radius: 4px;
}
.shop .select__list {
margin-top: 10px;
border: 1px solid #ECEDF3;
border-radius: 4px;
}
.shop__wrap {
display: grid;
grid-template-columns: repeat(3, 1fr);
grid-gap: 32px 40px;
}
.shop__item {
outline: 1px solid blue;
}
.shop__pic {
display: block;
height: 0px;
padding-top: 22%;
background-repeat: no-repeat;
background-size: cover;
background-position: center;
}
.shop__holder {
display: flex;
}
.shop__box--aside {
width: 290px;
padding-top: 2px;
}
.shop__box--content {
width: calc(100% - 290px);
padding-right: 40px;
}
.shop__subtitle {
font-size: 14px;
line-height: 1.2;
color: #3D3F42;
text-transform: uppercase;
padding-bottom: 24px;
font-weight: 600;
}
.shop__list {
display: flex;
flex-direction: column;
padding-bottom: 48px;
}
.shop__list--size .shop__col {
text-transform: uppercase;
}
.shop__col {
cursor: pointer;
display: inline-block;
width: max-content;
font-size: 14px;
line-height: 1.2;
color: #9F9F9F;
margin-bottom: 16px;
}
.shop__row {
position: relative;
margin-bottom: 15px;
outline: 2px solid red;
}
.shop__add {
cursor: pointer;
position: absolute;
top: 10px;
left: 10px;
width: 18px;
height: 18px;
border: none;
outline: none;
padding: 0px;
background-color: transparent;
}
.shop__add--active .shop__icon {
fill: #3D3F42;
}
.shop__icon {
width: 100%;
height: 100%;
display: block;
fill: #fff;
stroke-width: 30px;
stroke: #3D3F42;
}
.shop__size {
position: absolute;
z-index: 2;
left: 0px;
bottom: 0px;
width: 100%;
opacity: 0;
visibility: hidden;
display: flex;
justify-content: center;
background-color: rgba(249, 249, 249, 0.8);
padding: 0 12px;
padding-top: 23px;
margin: 0 -12px;
transition: 0.3s opacity;
}
.shop__user {
cursor: default;
font-size:...
JavaScript
$(document).ready(function() {
var shop = $('.shop__slider');
shop.slick({
infinite: true,
// speed: 600,
slidesToShow: 1,
// autoplay: true,
//autoplaySpeed:5000,
draggable: true,
fade: false,
arrows: false,
prevArrow: '<button class="events__arrow events__arrow--dir_left"></div>',
nextArrow: '<button class="events__arrow events__arrow--dir_right"></button>',
dots: false,
});
});