diff --git a/CHANGELOG.md b/CHANGELOG.md index a45b1656..6a1292cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed - Added missing space above gallery component +- Updated gallery analytics ### Security diff --git a/src/nationalarchives/components/gallery/analytics.js b/src/nationalarchives/components/gallery/analytics.js index 92cde88e..ada1e940 100644 --- a/src/nationalarchives/components/gallery/analytics.js +++ b/src/nationalarchives/components/gallery/analytics.js @@ -15,8 +15,7 @@ export default [ }, { eventName: "click", - targetElement: - ".tna-gallery__navigation-button tna-gallery__navigation-prev", + targetElement: ".tna-gallery__navigation-prev", on: "click", data: { value: ($el, $scope) => @@ -27,8 +26,7 @@ export default [ }, { eventName: "click", - targetElement: - ".tna-gallery__navigation-button tna-gallery__navigation-next", + targetElement: ".tna-gallery__navigation-next", on: "click", data: { value: ($el, $scope) => @@ -38,26 +36,24 @@ export default [ }, }, { - eventName: "key press", + eventName: "keypress", on: "keydown", data: { value: ($el, $scope, event) => event.key, }, }, { - eventName: "click", + eventName: "enter-fullscreen", targetElement: '.tna-gallery__options button[value="enter-fullscreen"]', on: "click", - data: { state: "enter" }, }, { - eventName: "click", + eventName: "exit-fullscreen", targetElement: '.tna-gallery__options button[value="exit-fullscreen"]', on: "click", - data: { state: "exit" }, }, { - eventName: "click", + eventName: "index", targetElement: '.tna-gallery__options button[value="show-index"]', on: "click", },