| @@ -232,9 +232,8 @@ | ||
| 232 | 232 | } |
| 233 | 233 | })); |
| 234 | 234 | exports.getInteractionsData = getInteractionsData; |
| 235 | 235 | exports.getKeyframes = getKeyframes; |
| 236 | -exports.isFreeFrontendSupportedTrigger = isFreeFrontendSupportedTrigger; | |
| 237 | 236 | exports.parseAnimationName = parseAnimationName; |
| 238 | 237 | Object.defineProperty(exports, "parseInteractionsData", ({ |
| 239 | 238 | enumerable: true, |
| 240 | 239 | get: function get() { |
| @@ -266,16 +265,8 @@ | ||
| 266 | 265 | } |
| 267 | 266 | })); |
| 268 | 267 | var _slicedToArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/slicedToArray */ "../node_modules/@babel/runtime/helpers/slicedToArray.js")); |
| 269 | 268 | var _interactionsSharedUtils = __webpack_require__(/*! ./interactions-shared-utils.js */ "../modules/interactions/assets/js/interactions-shared-utils.js"); |
| 270 | -/** | |
| 271 | - * Triggers the Core `interactions.js` / `editor-interactions.js` bundles run. Pro-only triggers | |
| 272 | - * (e.g. hover, click) must not fall through to the load-time default path. | |
| 273 | - */ | |
| 274 | -var FREE_FRONTEND_SUPPORTED_TRIGGERS = ['load', 'scrollIn', 'scrollOut']; | |
| 275 | -function isFreeFrontendSupportedTrigger(trigger) { | |
| 276 | - return FREE_FRONTEND_SUPPORTED_TRIGGERS.includes(trigger); | |
| 277 | -} | |
| 278 | 269 | function getKeyframes(effect, type, direction) { |
| 279 | 270 | var isIn = 'in' === type; |
| 280 | 271 | var keyframes = {}; |
| 281 | 272 | if ('fade' === effect) { |
| @@ -649,9 +640,9 @@ | ||
| 649 | 640 | return; |
| 650 | 641 | } |
| 651 | 642 | interactions.forEach(function (interaction) { |
| 652 | 643 | var animConfig = (0, _interactionsUtils.extractAnimationConfig)(interaction); |
| 653 | - if (animConfig && !(0, _interactionsUtils.skipInteraction)(animConfig) && (0, _interactionsUtils.isFreeFrontendSupportedTrigger)(animConfig.trigger)) { | |
| 644 | + if (animConfig && !(0, _interactionsUtils.skipInteraction)(animConfig)) { | |
| 654 | 645 | applyAnimation(element, animConfig, animateFunc, inViewFunc); |
| 655 | 646 | } |
| 656 | 647 | }); |
| 657 | 648 | } |
| @@ -672,11 +663,13 @@ | ||
| 672 | 663 | interactions = elementData.interactions; |
| 673 | 664 | if (!elementId || !interactions || !Array.isArray(interactions)) { |
| 674 | 665 | return; |
| 675 | 666 | } |
| 676 | - document.querySelectorAll("[data-interaction-id=\"".concat(elementId, "\"]")).forEach(function (element) { | |
| 677 | - processElementInteractions(element, interactions, animateFunc, inViewFunc); | |
| 678 | - }); | |
| 667 | + var element = document.querySelector("[data-interaction-id=\"".concat(elementId, "\"]")); | |
| 668 | + if (!element) { | |
| 669 | + return; | |
| 670 | + } | |
| 671 | + processElementInteractions(element, interactions, animateFunc, inViewFunc); | |
| 679 | 672 | }); |
| 680 | 673 | return; |
| 681 | 674 | } |
| 682 | 675 | |