@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
|
@@ -16031,7 +16031,7 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16031
16031
|
setAutoCycleId = _useState2[1];
|
|
16032
16032
|
var handleLeftClick = function handleLeftClick() {
|
|
16033
16033
|
setCurrentImage(function (prevImage) {
|
|
16034
|
-
return (prevImage - 1 + images.length) % images.length;
|
|
16034
|
+
return (prevImage - 1 + (images == null ? void 0 : images.length)) % (images == null ? void 0 : images.length);
|
|
16035
16035
|
});
|
|
16036
16036
|
if (stopAutoCyclingOnInteraction && autoCycleId) {
|
|
16037
16037
|
clearInterval(autoCycleId);
|
|
@@ -16040,7 +16040,7 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16040
16040
|
};
|
|
16041
16041
|
var handleRightClick = function handleRightClick() {
|
|
16042
16042
|
setCurrentImage(function (prevImage) {
|
|
16043
|
-
return (prevImage + 1) % images.length;
|
|
16043
|
+
return (prevImage + 1) % (images == null ? void 0 : images.length);
|
|
16044
16044
|
});
|
|
16045
16045
|
if (stopAutoCyclingOnInteraction && autoCycleId) {
|
|
16046
16046
|
clearInterval(autoCycleId);
|
|
@@ -16051,7 +16051,7 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16051
16051
|
if (autoCycle) {
|
|
16052
16052
|
var id = setInterval(function () {
|
|
16053
16053
|
setCurrentImage(function (prevImage) {
|
|
16054
|
-
return (prevImage + 1) % images.length;
|
|
16054
|
+
return (prevImage + 1) % (images == null ? void 0 : images.length);
|
|
16055
16055
|
});
|
|
16056
16056
|
}, autoCycleDelay);
|
|
16057
16057
|
setAutoCycleId(id);
|
|
@@ -16061,8 +16061,8 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16061
16061
|
clearInterval(autoCycleId);
|
|
16062
16062
|
}
|
|
16063
16063
|
};
|
|
16064
|
-
}, [autoCycle, autoCycleDelay, images.length]);
|
|
16065
|
-
var hasMoreThanOneImage = images.length > 1;
|
|
16064
|
+
}, [autoCycle, autoCycleDelay, images == null ? void 0 : images.length]);
|
|
16065
|
+
var hasMoreThanOneImage = (images == null ? void 0 : images.length) > 1;
|
|
16066
16066
|
return React__default.createElement(ImageContainer, {
|
|
16067
16067
|
style: styles
|
|
16068
16068
|
}, hasMoreThanOneImage && React__default.createElement(CustomLeftArrow, {
|
|
@@ -16073,7 +16073,7 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
16073
16073
|
onPointerDown: handleRightClick
|
|
16074
16074
|
}), React__default.createElement(Carousel, null, React__default.createElement(FadeInCarouselImg, {
|
|
16075
16075
|
key: currentImage,
|
|
16076
|
-
src: images[currentImage],
|
|
16076
|
+
src: images == null ? void 0 : images[currentImage],
|
|
16077
16077
|
alt: "Image " + currentImage
|
|
16078
16078
|
})));
|
|
16079
16079
|
};
|