@royaloperahouse/harmonic 0.1.8-o → 0.1.8-q

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.
@@ -7520,6 +7520,19 @@ var Swipe = /*#__PURE__*/forwardRef(function (_ref, ref) {
7520
7520
  var _useState5 = useState(infinite ? clonesCount : 0),
7521
7521
  currentIndex = _useState5[0],
7522
7522
  setCurrentIndex = _useState5[1];
7523
+ useEffect(function () {
7524
+ var handler = function handler(e) {
7525
+ if (isClickPrevented.current) {
7526
+ e.preventDefault();
7527
+ e.stopPropagation();
7528
+ }
7529
+ };
7530
+ var el = containerRef.current;
7531
+ el == null || el.addEventListener('click', handler, true);
7532
+ return function () {
7533
+ return el == null ? void 0 : el.removeEventListener('click', handler, true);
7534
+ };
7535
+ }, []);
7523
7536
  useEffect(function () {
7524
7537
  if (!onIndexChange) return;
7525
7538
  if (!infinite) {
@@ -7695,8 +7708,7 @@ var Swipe = /*#__PURE__*/forwardRef(function (_ref, ref) {
7695
7708
  className: "swipe-track-wrapper",
7696
7709
  translateX: dragTranslateX !== null ? dragTranslateX : getTranslateX(),
7697
7710
  transitioning: transitioning && dragTranslateX === null,
7698
- onTransitionEnd: handleTransitionEnd,
7699
- onClickCapture: onClickCapture
7711
+ onTransitionEnd: handleTransitionEnd
7700
7712
  }, slides.map(function (child, index) {
7701
7713
  var isVisible = visibleIndexes.includes(index);
7702
7714
  return /*#__PURE__*/React__default.cloneElement(child, {
@@ -7708,7 +7720,9 @@ var Swipe = /*#__PURE__*/forwardRef(function (_ref, ref) {
7708
7720
  },
7709
7721
  onFocus: function onFocus() {
7710
7722
  return onSlideFocus(isVisible, index);
7711
- }
7723
+ },
7724
+ onClick: onClickCapture,
7725
+ onClickCapture: onClickCapture
7712
7726
  });
7713
7727
  })));
7714
7728
  });