nestiq-component-library 1.0.24 → 1.0.26
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/dist/components/ImageListPopup/ImageListPopup.d.ts +4 -11
- package/dist/components/PropertyDetailsHeader/PropertyDetailsHeader.d.ts +1 -1
- package/dist/components/PropertyImageList/PropertyImageList.d.ts +4 -11
- package/dist/index.es.js +40 -71
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +39 -70
- package/dist/index.js.map +1 -1
- package/package.json +3 -7
- package/rollup.config.mjs +35 -40
- package/src/components/ImageListPopup/ImageListPopup.css +107 -107
- package/src/components/ImageListPopup/ImageListPopup.tsx +141 -212
- package/src/components/Popup/Popup.tsx +28 -28
- package/src/components/PropertyDetailsHeader/PropertyDetailsHeader.tsx +83 -82
- package/src/components/PropertyImageList/PropertyImageList.tsx +11 -46
- package/tsconfig.json +2 -0
- package/dist/assets/images/heartIcon.svg +0 -3
- package/dist/assets/images/icon-close-white.webp +0 -0
- package/dist/assets/images/no-image-icon.png +0 -0
- package/dist/components/Button/Button.js +0 -6
- package/dist/components/ImageListPopup/ImageListPopup.js +0 -26
- package/dist/components/Popup/Popup.js +0 -12
- package/nestiq-component-library-1.0.22.tgz +0 -0
- /package/dist/assets/images/{Icon_rightArrow.svg → Icon_rightArrow.bced4a705c07148d.svg} +0 -0
- /package/dist/assets/images/{LayersIcon.svg → LayersIcon.34c085c352a2c9c8.svg} +0 -0
- /package/dist/assets/images/{blackarrow-Right.svg → blackarrow-Right.e585ae62dd55abae.svg} +0 -0
- /package/dist/assets/images/{blckarrow-Left.svg → blckarrow-Left.e2134741aa368d30.svg} +0 -0
- /package/dist/assets/images/{chevron-left.svg → chevron-left.04f0a7f16b745c1a.svg} +0 -0
- /package/dist/assets/images/{default-property.jpg → default-property.9987f19670be82b6.jpg} +0 -0
- /package/dist/assets/images/{icon_close_2.png → icon_close_2.e41bb9a4db48e048.png} +0 -0
- /package/dist/assets/images/{icon_gallery.svg → icon_gallery.269b721daf2ca907.svg} +0 -0
- /package/dist/assets/images/{icon_map.svg → icon_map.2318ec664c3e615e.svg} +0 -0
- /package/dist/assets/images/{icon_share_1.svg → icon_share_1.b9ec05630dc1087e.svg} +0 -0
- /package/dist/assets/images/{layer_icon.svg → layer_icon.9b56c187199c44b5.svg} +0 -0
- /package/dist/assets/images/{locationIcon.svg → locationIcon.0af399c78e0cdc20.svg} +0 -0
- /package/dist/assets/images/{locationIconBlack.svg → locationIconBlack.eb8e9e9226b43573.svg} +0 -0
|
@@ -1,107 +1,107 @@
|
|
|
1
|
-
.popup-overlay {
|
|
2
|
-
position: fixed;
|
|
3
|
-
top: 0;
|
|
4
|
-
left: 0;
|
|
5
|
-
right: 0;
|
|
6
|
-
bottom: 0;
|
|
7
|
-
background-color: rgba(0, 0, 0, 0.7);
|
|
8
|
-
display: flex;
|
|
9
|
-
justify-content: center;
|
|
10
|
-
align-items: center;
|
|
11
|
-
z-index: 10000;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
.popup-container {
|
|
15
|
-
background-color: transparent;
|
|
16
|
-
border-radius: 8px;
|
|
17
|
-
max-width: 90%;
|
|
18
|
-
max-height: 90%;
|
|
19
|
-
display: flex;
|
|
20
|
-
flex-direction: column;
|
|
21
|
-
align-items: center;
|
|
22
|
-
position: relative;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
.popup-header {
|
|
26
|
-
display: flex;
|
|
27
|
-
justify-content: center;
|
|
28
|
-
align-items: center;
|
|
29
|
-
width: 100%;
|
|
30
|
-
padding: 1rem;
|
|
31
|
-
position: absolute;
|
|
32
|
-
top: 0;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.popup-title {
|
|
36
|
-
color: white;
|
|
37
|
-
font-size: 24px;
|
|
38
|
-
font-weight: bold;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
.btn-close {
|
|
42
|
-
position: absolute;
|
|
43
|
-
right: 1rem;
|
|
44
|
-
top: 1rem;
|
|
45
|
-
background: none;
|
|
46
|
-
border: none;
|
|
47
|
-
color: white;
|
|
48
|
-
font-size: 24px;
|
|
49
|
-
cursor: pointer;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
.popup-body {
|
|
53
|
-
display: flex;
|
|
54
|
-
justify-content: center;
|
|
55
|
-
align-items: center;
|
|
56
|
-
padding: 1rem;
|
|
57
|
-
position: relative;
|
|
58
|
-
flex: 1;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.main-image {
|
|
62
|
-
max-width: 100%;
|
|
63
|
-
max-height: 80vh;
|
|
64
|
-
border-radius: 8px;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.btn-prev,
|
|
68
|
-
.btn-next {
|
|
69
|
-
background: none;
|
|
70
|
-
border: none;
|
|
71
|
-
color: white;
|
|
72
|
-
font-size: 48px;
|
|
73
|
-
cursor: pointer;
|
|
74
|
-
position: absolute;
|
|
75
|
-
top: 50%;
|
|
76
|
-
transform: translateY(-50%);
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
.btn-prev {
|
|
80
|
-
left: 10px;
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
.btn-next {
|
|
84
|
-
right: 10px;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
.popup-thumbnails {
|
|
88
|
-
display: flex;
|
|
89
|
-
justify-content: center;
|
|
90
|
-
align-items: center;
|
|
91
|
-
gap: 10px;
|
|
92
|
-
padding: 1rem;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
.thumbnail {
|
|
96
|
-
width: 60px;
|
|
97
|
-
height: 60px;
|
|
98
|
-
object-fit: cover;
|
|
99
|
-
border-radius: 8px;
|
|
100
|
-
cursor: pointer;
|
|
101
|
-
opacity: 0.6;
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
.thumbnail.active {
|
|
105
|
-
border: 2px solid white;
|
|
106
|
-
opacity: 1;
|
|
107
|
-
}
|
|
1
|
+
.popup-overlay {
|
|
2
|
+
position: fixed;
|
|
3
|
+
top: 0;
|
|
4
|
+
left: 0;
|
|
5
|
+
right: 0;
|
|
6
|
+
bottom: 0;
|
|
7
|
+
background-color: rgba(0, 0, 0, 0.7);
|
|
8
|
+
display: flex;
|
|
9
|
+
justify-content: center;
|
|
10
|
+
align-items: center;
|
|
11
|
+
z-index: 10000;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.popup-container {
|
|
15
|
+
background-color: transparent;
|
|
16
|
+
border-radius: 8px;
|
|
17
|
+
max-width: 90%;
|
|
18
|
+
max-height: 90%;
|
|
19
|
+
display: flex;
|
|
20
|
+
flex-direction: column;
|
|
21
|
+
align-items: center;
|
|
22
|
+
position: relative;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.popup-header {
|
|
26
|
+
display: flex;
|
|
27
|
+
justify-content: center;
|
|
28
|
+
align-items: center;
|
|
29
|
+
width: 100%;
|
|
30
|
+
padding: 1rem;
|
|
31
|
+
position: absolute;
|
|
32
|
+
top: 0;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.popup-title {
|
|
36
|
+
color: white;
|
|
37
|
+
font-size: 24px;
|
|
38
|
+
font-weight: bold;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.btn-close {
|
|
42
|
+
position: absolute;
|
|
43
|
+
right: 1rem;
|
|
44
|
+
top: 1rem;
|
|
45
|
+
background: none;
|
|
46
|
+
border: none;
|
|
47
|
+
color: white;
|
|
48
|
+
font-size: 24px;
|
|
49
|
+
cursor: pointer;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.popup-body {
|
|
53
|
+
display: flex;
|
|
54
|
+
justify-content: center;
|
|
55
|
+
align-items: center;
|
|
56
|
+
padding: 1rem;
|
|
57
|
+
position: relative;
|
|
58
|
+
flex: 1;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.main-image {
|
|
62
|
+
max-width: 100%;
|
|
63
|
+
max-height: 80vh;
|
|
64
|
+
border-radius: 8px;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.btn-prev,
|
|
68
|
+
.btn-next {
|
|
69
|
+
background: none;
|
|
70
|
+
border: none;
|
|
71
|
+
color: white;
|
|
72
|
+
font-size: 48px;
|
|
73
|
+
cursor: pointer;
|
|
74
|
+
position: absolute;
|
|
75
|
+
top: 50%;
|
|
76
|
+
transform: translateY(-50%);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.btn-prev {
|
|
80
|
+
left: 10px;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.btn-next {
|
|
84
|
+
right: 10px;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.popup-thumbnails {
|
|
88
|
+
display: flex;
|
|
89
|
+
justify-content: center;
|
|
90
|
+
align-items: center;
|
|
91
|
+
gap: 10px;
|
|
92
|
+
padding: 1rem;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.thumbnail {
|
|
96
|
+
width: 60px;
|
|
97
|
+
height: 60px;
|
|
98
|
+
object-fit: cover;
|
|
99
|
+
border-radius: 8px;
|
|
100
|
+
cursor: pointer;
|
|
101
|
+
opacity: 0.6;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.thumbnail.active {
|
|
105
|
+
border: 2px solid white;
|
|
106
|
+
opacity: 1;
|
|
107
|
+
}
|
|
@@ -1,212 +1,141 @@
|
|
|
1
|
-
import "./ImageListPopup.css";
|
|
2
|
-
import React, {
|
|
3
|
-
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
handleArrowClickInMainImage: any
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
<div className="d-flex flex-row">
|
|
143
|
-
{/* Arrows on the main image */}
|
|
144
|
-
</div>
|
|
145
|
-
<div className="d-flex flex-row gap-4 w-100 secondList ">
|
|
146
|
-
<div className="col-lg-12 d-flex flex-row p-1 align-self-center mt-5">
|
|
147
|
-
<div className="col-12 position-relative d-flex justify-content-center">
|
|
148
|
-
{/* <div
|
|
149
|
-
className="col-1 h-100 d-flex position-absolute start-0"
|
|
150
|
-
onClick={() => handleArrowClickInMainImage("left")}
|
|
151
|
-
role="button"
|
|
152
|
-
>
|
|
153
|
-
<div className="col-lg-12 h-100 d-flex flex-column listImageButton border-0 rounded-3">
|
|
154
|
-
<img
|
|
155
|
-
src={iconArrowLeft}
|
|
156
|
-
className="arroIconColour"
|
|
157
|
-
alt="Left Arrow"
|
|
158
|
-
/>
|
|
159
|
-
</div>
|
|
160
|
-
</div> */}
|
|
161
|
-
<div
|
|
162
|
-
className="col-lg-10 rounded-3 h-100 w-100 d-flex flex-row gap-2 overflow-auto "
|
|
163
|
-
ref={props.imageListRef}
|
|
164
|
-
>
|
|
165
|
-
{props.property && (
|
|
166
|
-
<div className="col-lg-5 h-100 w-25 d-flex gap-4 flex-row rounded-3">
|
|
167
|
-
{props.pictureUrls.map((imageUrl, index) => (
|
|
168
|
-
<div
|
|
169
|
-
key={index}
|
|
170
|
-
className="col-lg-12 h-100 d-flex"
|
|
171
|
-
onClick={() => {
|
|
172
|
-
setMainImage(imageUrl);
|
|
173
|
-
setCurrentImageIndex(index);
|
|
174
|
-
props.imageListRef.current.scrollTo({
|
|
175
|
-
left: index * 150,
|
|
176
|
-
behavior: "smooth",
|
|
177
|
-
});
|
|
178
|
-
}}
|
|
179
|
-
role="button"
|
|
180
|
-
>
|
|
181
|
-
<img
|
|
182
|
-
src={imageUrl}
|
|
183
|
-
alt={`Image ${index + 1}`}
|
|
184
|
-
className="col-12 h-100 rounded-3 object-fit-cover"
|
|
185
|
-
/>
|
|
186
|
-
</div>
|
|
187
|
-
))}
|
|
188
|
-
</div>
|
|
189
|
-
)}
|
|
190
|
-
</div>
|
|
191
|
-
{/* <div
|
|
192
|
-
className="col-1 h-100 d-flex position-absolute end-0 top-0"
|
|
193
|
-
onClick={() => handleArrowClickInMainImage("right")}
|
|
194
|
-
role="button"
|
|
195
|
-
>
|
|
196
|
-
<div className="col-lg-12 h-100 d-flex flex-column listImageButton border-0 rounded-3 ms-1">
|
|
197
|
-
<img
|
|
198
|
-
src={iconArrowRight}
|
|
199
|
-
className="arroIconColour"
|
|
200
|
-
alt="Right Arrow"
|
|
201
|
-
/>
|
|
202
|
-
</div>
|
|
203
|
-
</div> */}
|
|
204
|
-
</div>
|
|
205
|
-
</div>
|
|
206
|
-
</div>
|
|
207
|
-
</div>
|
|
208
|
-
</div>
|
|
209
|
-
)}
|
|
210
|
-
</div>
|
|
211
|
-
);
|
|
212
|
-
}
|
|
1
|
+
import "./ImageListPopup.css";
|
|
2
|
+
import React, { useRef, useState } from "react";
|
|
3
|
+
import blcIconArrowRight from "../../assets/Images/blackarrow-Right.svg";
|
|
4
|
+
import blcIconArrowLeft from "../../assets/Images/blckarrow-Left.svg";
|
|
5
|
+
import iconClose from "../../assets/images/icon_close_2.png";
|
|
6
|
+
|
|
7
|
+
interface PopupProps {
|
|
8
|
+
pictureUrls: { title: string; url: string }[];
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export default function ImageListPopup(props: PopupProps) {
|
|
12
|
+
const [showPopUp, setShowPopUp] = useState(true);
|
|
13
|
+
const [currentImageIndex, setCurrentImageIndex] = useState(0);
|
|
14
|
+
const imageListRef = useRef<HTMLDivElement | null>(null);
|
|
15
|
+
|
|
16
|
+
const handleArrowClickInMainImage = (direction: any) => {
|
|
17
|
+
if (props.pictureUrls.length === 0) return;
|
|
18
|
+
|
|
19
|
+
let newIndex = currentImageIndex;
|
|
20
|
+
if (direction === "left") {
|
|
21
|
+
newIndex =
|
|
22
|
+
(currentImageIndex - 1 + props.pictureUrls.length) %
|
|
23
|
+
props.pictureUrls.length;
|
|
24
|
+
} else if (direction === "right") {
|
|
25
|
+
newIndex = (currentImageIndex + 1) % props.pictureUrls.length;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
setCurrentImageIndex(newIndex);
|
|
29
|
+
|
|
30
|
+
imageListRef.current!.scrollTo({
|
|
31
|
+
left: newIndex * 150,
|
|
32
|
+
behavior: "smooth",
|
|
33
|
+
});
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
const handleClose = () => {
|
|
37
|
+
setShowPopUp(false);
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
return (
|
|
41
|
+
<div>
|
|
42
|
+
{showPopUp && (
|
|
43
|
+
<div className="popup-overlay">
|
|
44
|
+
<div className=" d-flex flex-column col-6 ">
|
|
45
|
+
<span className="txt-white">
|
|
46
|
+
{props.pictureUrls[currentImageIndex].title}
|
|
47
|
+
</span>
|
|
48
|
+
<div className="d-flex align-self-end me-0 ms-5">
|
|
49
|
+
<img
|
|
50
|
+
src={iconClose}
|
|
51
|
+
alt="close"
|
|
52
|
+
className="closeIcon"
|
|
53
|
+
onClick={handleClose}
|
|
54
|
+
/>
|
|
55
|
+
</div>
|
|
56
|
+
|
|
57
|
+
<div className="d-flex justify-content-center">
|
|
58
|
+
<div className="p-2 bd-highlight align-self-center align-items-center me-5">
|
|
59
|
+
<div
|
|
60
|
+
className="rounded-circle border onImageArrow start-0 d-flex "
|
|
61
|
+
role="button"
|
|
62
|
+
onClick={() => handleArrowClickInMainImage("left")}
|
|
63
|
+
>
|
|
64
|
+
<img
|
|
65
|
+
src={blcIconArrowLeft}
|
|
66
|
+
className="blackArrow align-self-center"
|
|
67
|
+
alt="Left Arrow"
|
|
68
|
+
/>
|
|
69
|
+
</div>
|
|
70
|
+
</div>
|
|
71
|
+
<div className="p-2 bd-highlight">
|
|
72
|
+
<div
|
|
73
|
+
className=" rounded-5 mainImage "
|
|
74
|
+
style={{
|
|
75
|
+
backgroundImage: `url(${props.pictureUrls[currentImageIndex].url})`,
|
|
76
|
+
height: "350px",
|
|
77
|
+
width: "600px",
|
|
78
|
+
backgroundSize: "cover",
|
|
79
|
+
backgroundPosition: "center",
|
|
80
|
+
}}
|
|
81
|
+
></div>
|
|
82
|
+
</div>
|
|
83
|
+
<div className="p-2 bd-highlight align-self-center ms-5">
|
|
84
|
+
{" "}
|
|
85
|
+
<div
|
|
86
|
+
role="button"
|
|
87
|
+
className="rounded-circle border onImageArrow d-flex justify-content-center"
|
|
88
|
+
onClick={() => handleArrowClickInMainImage("right")}
|
|
89
|
+
>
|
|
90
|
+
<img
|
|
91
|
+
src={blcIconArrowRight}
|
|
92
|
+
className="blackArrow align-self-center"
|
|
93
|
+
alt="Right Arrow"
|
|
94
|
+
/>
|
|
95
|
+
</div>
|
|
96
|
+
</div>
|
|
97
|
+
</div>
|
|
98
|
+
<div className="d-flex flex-row">
|
|
99
|
+
{/* Arrows on the main image */}
|
|
100
|
+
</div>
|
|
101
|
+
<div className="d-flex flex-row gap-4 w-100 secondList ">
|
|
102
|
+
<div className="col-lg-12 d-flex flex-row p-1 align-self-center mt-5">
|
|
103
|
+
<div className="col-12 position-relative d-flex justify-content-center">
|
|
104
|
+
<div
|
|
105
|
+
className="col-lg-10 rounded-3 h-100 w-100 d-flex flex-row gap-2 overflow-auto "
|
|
106
|
+
ref={imageListRef}
|
|
107
|
+
>
|
|
108
|
+
{props.pictureUrls.length > 0 && (
|
|
109
|
+
<div className="col-lg-5 h-100 w-25 d-flex gap-4 flex-row rounded-3">
|
|
110
|
+
{props.pictureUrls.map((picture, index) => (
|
|
111
|
+
<div
|
|
112
|
+
key={index}
|
|
113
|
+
className="col-lg-12 h-100 d-flex"
|
|
114
|
+
onClick={() => {
|
|
115
|
+
setCurrentImageIndex(index);
|
|
116
|
+
imageListRef.current!.scrollTo({
|
|
117
|
+
left: index * 150,
|
|
118
|
+
behavior: "smooth",
|
|
119
|
+
});
|
|
120
|
+
}}
|
|
121
|
+
role="button"
|
|
122
|
+
>
|
|
123
|
+
<img
|
|
124
|
+
src={picture.url}
|
|
125
|
+
alt={`Image ${index + 1}`}
|
|
126
|
+
className="col-12 h-100 rounded-3 object-fit-cover"
|
|
127
|
+
/>
|
|
128
|
+
</div>
|
|
129
|
+
))}
|
|
130
|
+
</div>
|
|
131
|
+
)}
|
|
132
|
+
</div>
|
|
133
|
+
</div>
|
|
134
|
+
</div>
|
|
135
|
+
</div>
|
|
136
|
+
</div>
|
|
137
|
+
</div>
|
|
138
|
+
)}
|
|
139
|
+
</div>
|
|
140
|
+
);
|
|
141
|
+
}
|
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import closeIcon from "../../assets/images/icon_close_2.png";
|
|
3
|
-
import "./Popup.css";
|
|
4
|
-
|
|
5
|
-
interface PopupProps {
|
|
6
|
-
children: React.ReactNode;
|
|
7
|
-
onCloseClick: () => void;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
const Popup: React.FC<PopupProps> = ({ onCloseClick, children }) => {
|
|
11
|
-
return (
|
|
12
|
-
<div className="popup-overlay">
|
|
13
|
-
<div className="shareSection col-12 d-flex position-relative flex-column mx-auto justify-content-center col-5 col-lg-6 d-flex gap-4">
|
|
14
|
-
<div className="end-0 top-0 position-absolute ">
|
|
15
|
-
<img
|
|
16
|
-
src={closeIcon}
|
|
17
|
-
alt="close"
|
|
18
|
-
className="closeIcon me-2"
|
|
19
|
-
onClick={onCloseClick}
|
|
20
|
-
/>
|
|
21
|
-
</div>
|
|
22
|
-
{children}
|
|
23
|
-
</div>
|
|
24
|
-
</div>
|
|
25
|
-
);
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
export default Popup;
|
|
1
|
+
import React from "react";
|
|
2
|
+
import closeIcon from "../../assets/images/icon_close_2.png";
|
|
3
|
+
import "./Popup.css";
|
|
4
|
+
|
|
5
|
+
interface PopupProps {
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
onCloseClick: () => void;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
const Popup: React.FC<PopupProps> = ({ onCloseClick, children }) => {
|
|
11
|
+
return (
|
|
12
|
+
<div className="popup-overlay">
|
|
13
|
+
<div className="shareSection col-12 d-flex position-relative flex-column mx-auto justify-content-center col-5 col-lg-6 d-flex gap-4">
|
|
14
|
+
<div className="end-0 top-0 position-absolute ">
|
|
15
|
+
<img
|
|
16
|
+
src={closeIcon}
|
|
17
|
+
alt="close"
|
|
18
|
+
className="closeIcon me-2"
|
|
19
|
+
onClick={onCloseClick}
|
|
20
|
+
/>
|
|
21
|
+
</div>
|
|
22
|
+
{children}
|
|
23
|
+
</div>
|
|
24
|
+
</div>
|
|
25
|
+
);
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export default Popup;
|