@rpg-engine/long-bow 0.5.67 → 0.5.68
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/long-bow.cjs.development.js +6 -6
- package/dist/long-bow.cjs.development.js.map +1 -1
- package/dist/long-bow.cjs.production.min.js +1 -1
- package/dist/long-bow.cjs.production.min.js.map +1 -1
- package/dist/long-bow.esm.js +6 -6
- package/dist/long-bow.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/ImageCarousel/SimpleImageCarousel.tsx +6 -6
package/dist/long-bow.esm.js
CHANGED
|
@@ -16027,7 +16027,7 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16027
16027
|
setAutoCycleId = _useState2[1];
|
|
16028
16028
|
var handleLeftClick = function handleLeftClick() {
|
|
16029
16029
|
setCurrentImage(function (prevImage) {
|
|
16030
|
-
return (prevImage - 1 + images.length) % images.length;
|
|
16030
|
+
return (prevImage - 1 + (images == null ? void 0 : images.length)) % (images == null ? void 0 : images.length);
|
|
16031
16031
|
});
|
|
16032
16032
|
if (stopAutoCyclingOnInteraction && autoCycleId) {
|
|
16033
16033
|
clearInterval(autoCycleId);
|
|
@@ -16036,7 +16036,7 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16036
16036
|
};
|
|
16037
16037
|
var handleRightClick = function handleRightClick() {
|
|
16038
16038
|
setCurrentImage(function (prevImage) {
|
|
16039
|
-
return (prevImage + 1) % images.length;
|
|
16039
|
+
return (prevImage + 1) % (images == null ? void 0 : images.length);
|
|
16040
16040
|
});
|
|
16041
16041
|
if (stopAutoCyclingOnInteraction && autoCycleId) {
|
|
16042
16042
|
clearInterval(autoCycleId);
|
|
@@ -16047,7 +16047,7 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16047
16047
|
if (autoCycle) {
|
|
16048
16048
|
var id = setInterval(function () {
|
|
16049
16049
|
setCurrentImage(function (prevImage) {
|
|
16050
|
-
return (prevImage + 1) % images.length;
|
|
16050
|
+
return (prevImage + 1) % (images == null ? void 0 : images.length);
|
|
16051
16051
|
});
|
|
16052
16052
|
}, autoCycleDelay);
|
|
16053
16053
|
setAutoCycleId(id);
|
|
@@ -16057,8 +16057,8 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16057
16057
|
clearInterval(autoCycleId);
|
|
16058
16058
|
}
|
|
16059
16059
|
};
|
|
16060
|
-
}, [autoCycle, autoCycleDelay, images.length]);
|
|
16061
|
-
var hasMoreThanOneImage = images.length > 1;
|
|
16060
|
+
}, [autoCycle, autoCycleDelay, images == null ? void 0 : images.length]);
|
|
16061
|
+
var hasMoreThanOneImage = (images == null ? void 0 : images.length) > 1;
|
|
16062
16062
|
return React.createElement(ImageContainer, {
|
|
16063
16063
|
style: styles
|
|
16064
16064
|
}, hasMoreThanOneImage && React.createElement(CustomLeftArrow, {
|
|
@@ -16069,7 +16069,7 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16069
16069
|
onPointerDown: handleRightClick
|
|
16070
16070
|
}), React.createElement(Carousel, null, React.createElement(FadeInCarouselImg, {
|
|
16071
16071
|
key: currentImage,
|
|
16072
|
-
src: images[currentImage],
|
|
16072
|
+
src: images == null ? void 0 : images[currentImage],
|
|
16073
16073
|
alt: "Image " + currentImage
|
|
16074
16074
|
})));
|
|
16075
16075
|
};
|