l-min-components 1.0.1190 → 1.0.1192
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "l-min-components",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1192",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"files": [
|
|
6
6
|
"src/assets",
|
|
@@ -56,6 +56,7 @@
|
|
|
56
56
|
"react-modal": "^3.16.1",
|
|
57
57
|
"react-multi-carousel": "^2.8.5",
|
|
58
58
|
"react-player": "^2.15.1",
|
|
59
|
+
"react-responsive-carousel": "^3.2.23",
|
|
59
60
|
"react-router-dom": "^6.8.2",
|
|
60
61
|
"react-slick": "0.30.2",
|
|
61
62
|
"react-toastify": "^9.1.3",
|
|
@@ -3,9 +3,11 @@ import Button from "../../button";
|
|
|
3
3
|
import UpgradeComponent from "./upgrade";
|
|
4
4
|
import api from "./api";
|
|
5
5
|
import styled from "styled-components";
|
|
6
|
-
import Carousel from "react-multi-carousel";
|
|
7
|
-
import "react-multi-carousel/lib/styles.css";
|
|
6
|
+
// import Carousel from "react-multi-carousel";
|
|
7
|
+
// import "react-multi-carousel/lib/styles.css";
|
|
8
8
|
import moment from "moment";
|
|
9
|
+
import "react-responsive-carousel/lib/styles/carousel.min.css"; // requires a loader
|
|
10
|
+
import { Carousel as ReactCarousl } from "react-responsive-carousel";
|
|
9
11
|
|
|
10
12
|
const EnterpriseRightBar = ({ planState }) => {
|
|
11
13
|
const {
|
|
@@ -22,11 +24,11 @@ const EnterpriseRightBar = ({ planState }) => {
|
|
|
22
24
|
const courses = coursesData?.data?.results;
|
|
23
25
|
const slotData = remainingSlotData?.data;
|
|
24
26
|
|
|
25
|
-
const CustomDots = ({ onClick,
|
|
27
|
+
const CustomDots = ({ onClick, isSelected }) => {
|
|
26
28
|
return (
|
|
27
29
|
<CustomDotsContainer
|
|
28
30
|
onClick={onClick}
|
|
29
|
-
className={`${
|
|
31
|
+
className={`${isSelected ? "active" : ""}`}
|
|
30
32
|
></CustomDotsContainer>
|
|
31
33
|
);
|
|
32
34
|
};
|
|
@@ -48,19 +50,28 @@ const EnterpriseRightBar = ({ planState }) => {
|
|
|
48
50
|
{courses?.length > 0 && courses && (
|
|
49
51
|
<Banner>
|
|
50
52
|
<h3>Courses ending soon</h3>
|
|
51
|
-
<
|
|
52
|
-
responsive={responsive}
|
|
53
|
-
arrows={false}
|
|
54
|
-
showDots
|
|
55
|
-
autoPlaySpeed={1000}
|
|
53
|
+
<ReactCarousl
|
|
54
|
+
// responsive={responsive}
|
|
55
|
+
// arrows={false}
|
|
56
|
+
// showDots
|
|
57
|
+
// autoPlaySpeed={1000}
|
|
58
|
+
// autoPlay
|
|
59
|
+
// infinite
|
|
60
|
+
// transitionDuration={2000}
|
|
61
|
+
// renderDotsOutside
|
|
62
|
+
// containerClass="carousel-container"
|
|
63
|
+
// dotListClass="custom-dot-list-style"
|
|
64
|
+
// defaultActiveIndex={0}
|
|
65
|
+
// customDot={<CustomDots />}
|
|
56
66
|
autoPlay
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
67
|
+
infiniteLoop
|
|
68
|
+
showArrows={false}
|
|
69
|
+
showStatus={false}
|
|
70
|
+
showThumbs={false}
|
|
71
|
+
className="carousel-container"
|
|
72
|
+
renderIndicator={(clickHandler, isSelected) => (
|
|
73
|
+
<CustomDots onClick={clickHandler} isSelected={isSelected} />
|
|
74
|
+
)}
|
|
64
75
|
>
|
|
65
76
|
{courses?.map((course) => (
|
|
66
77
|
<Course key={course?.id}>
|
|
@@ -74,7 +85,19 @@ const EnterpriseRightBar = ({ planState }) => {
|
|
|
74
85
|
</div>
|
|
75
86
|
</Course>
|
|
76
87
|
))}
|
|
77
|
-
|
|
88
|
+
{courses?.map((course) => (
|
|
89
|
+
<Course key={course?.id}>
|
|
90
|
+
<img src={course?.thumbnail_dict?.url} alt="" />
|
|
91
|
+
<div className="content">
|
|
92
|
+
<p className="date">
|
|
93
|
+
<span>Ends:</span>{" "}
|
|
94
|
+
{moment(course?.end_day).format("MMM DD, YYYY")}
|
|
95
|
+
</p>
|
|
96
|
+
<p className="name">{course?.name}</p>
|
|
97
|
+
</div>
|
|
98
|
+
</Course>
|
|
99
|
+
))}
|
|
100
|
+
</ReactCarousl>
|
|
78
101
|
</Banner>
|
|
79
102
|
)}
|
|
80
103
|
<RecentAddedEnterprie>
|
|
@@ -187,17 +210,17 @@ const EnterpriseContainer = styled.div`
|
|
|
187
210
|
width: 231px;
|
|
188
211
|
padding: 20px 12px;
|
|
189
212
|
.carousel-container {
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
213
|
+
position: relative;
|
|
214
|
+
|
|
215
|
+
.control-dots {
|
|
216
|
+
position: absolute;
|
|
217
|
+
left: 50%;
|
|
218
|
+
transform: translateX(-50%);
|
|
219
|
+
display: flex;
|
|
220
|
+
align-items: center;
|
|
221
|
+
gap: 10px;
|
|
222
|
+
justify-content: center;
|
|
223
|
+
bottom: 30;
|
|
201
224
|
}
|
|
202
225
|
}
|
|
203
226
|
`;
|