We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9c238a9 commit 8ce4414Copy full SHA for 8ce4414
src/components/ParticipantImages.js
@@ -59,6 +59,11 @@ const ImageList = [
59
},
60
];
61
62
+function shuffleArray(arr) {
63
+ arr.sort(() => Math.random() - 0.5);
64
+ return arr;
65
+}
66
+
67
export default function ParticipantImages() {
68
return (
69
<section className={styles.imageCarousel}>
@@ -70,7 +75,7 @@ export default function ParticipantImages() {
70
75
<div>
71
76
<Carousel showArrows={true} ariaLabel='Images of participants'
72
77
autoPlay={true} interval='6000' infiniteLoop={true}>
73
- {ImageList.map((props, idx) => (
78
+ {shuffleArray(ImageList).map((props, idx) => (
74
79
<div key={idx}>
80
<img src={useBaseUrl(props.img)} />
81
<p className={styles.imageCarouselCaption}>{props.title}</p>
0 commit comments