diff --git a/packages/gallery/src/components/item/itemView.js b/packages/gallery/src/components/item/itemView.js index ebcd39920..cdc06a9b1 100644 --- a/packages/gallery/src/components/item/itemView.js +++ b/packages/gallery/src/components/item/itemView.js @@ -60,6 +60,7 @@ class ItemView extends React.Component { this.onFocus = this.onFocus.bind(this); this.onBlur = this.onBlur.bind(this); this.checkIfCurrentHoverChanged = this.checkIfCurrentHoverChanged.bind(this); + this.shouldHoverWithoutOverlayAndClickOnMobile = this.shouldHoverWithoutOverlayAndClickOnMobile.bind(this); } //----------------------------------------| ACTIONS |-------------------------------------------// @@ -142,6 +143,8 @@ class ItemView extends React.Component { if (this.shouldShowHoverOnMobile() || this.shouldShowSecondMediaOnMobile()) { this.handleHoverClickOnMobile(e); + } else if (this.shouldHoverWithoutOverlayAndClickOnMobile()) { + this.props.actions.eventsListener(GALLERY_CONSTS.events.HOVER_SET, this.props.idx); } else { this.handleGalleryItemAction(e); } @@ -257,6 +260,16 @@ class ItemView extends React.Component { return false; } + shouldHoverWithoutOverlayAndClickOnMobile() { + return ( + utils.isMobile() && + this.props.options[optionsMap.behaviourParams.item.video.playTrigger] === + GALLERY_CONSTS[optionsMap.behaviourParams.item.video.playTrigger].HOVER && + this.props.options[optionsMap.behaviourParams.item.clickAction] === + GALLERY_CONSTS[optionsMap.behaviourParams.item.clickAction].NOTHING + ); + } + isHighlight() { return this.props.thumbnailHighlightId && this.props.thumbnailHighlightId === this.props.id; }