packages
1 month ago
00f53f1b378f6c98c043.bundle.min.js
5 months ago
0352e30f394e8e1dd4dc.bundle.js
2 months ago
0982f37bec0944fbcb10.bundle.js
5 months ago
0bc41c4656ca54cf2aca.bundle.min.js
5 months ago
137ba3baf43f287996c2.bundle.min.js
5 months ago
1564d2bfa4591bf857f3.bundle.min.js
5 months ago
197583acd246fea0e25d.bundle.js
6 months ago
1f7fa1d64dd4cef4a3c0.bundle.js
5 months ago
2140afa714e988f1069e.bundle.js
2 months ago
32f7c5e8db4c8976b254.bundle.js
2 months ago
35423d812dc1d52fdb27.bundle.min.js
5 months ago
397f2d183c19202777d6.bundle.min.js
3 months ago
397f2d183c19202777d6.bundle.min.js.LICENSE.txt
3 months ago
3c18b6eb4e735ca7e8bf.bundle.js
5 months ago
3c838288a9b7ddd2aea4.bundle.min.js
5 months ago
3d1613aca86991103452.bundle.min.js
5 months ago
3d410a099008411bb011.bundle.js
6 months ago
3df4dbb5d612dbdab477.bundle.min.js
2 months ago
40d841f4b4ce7b1928f5.bundle.js
5 months ago
4246c56134ca9ba65163.bundle.js
5 months ago
435080452e81c388e779.bundle.min.js
2 months ago
4812775bcbc0ff8a9043.bundle.min.js
5 months ago
4886b33c17731474e197.bundle.min.js
5 months ago
4927500be197e062162e.bundle.min.js
2 months ago
52ff17c2f566e528dc72.bundle.js
2 months ago
5b13d0f77c0ac139c979.bundle.js
5 months ago
5b74c81f4d425912a202.bundle.min.js
3 months ago
6117d083decd13b6ed73.bundle.js
2 months ago
64b3c0850f66b46478fb.bundle.min.js
2 months ago
6844b6c0a66040e3ca12.bundle.js
2 months ago
6a19e86dd8c1f9165dbe.bundle.js
6 months ago
6caa76d2f6eec6c4e665.bundle.js
3 months ago
6cb9e42b9b73a76315e0.bundle.js
5 months ago
6d09ff0398a56a60654b.bundle.min.js
3 months ago
6f779545aaa23e951088.bundle.min.js
2 months ago
72459a35b6570acc77f3.bundle.js
5 months ago
7745b82dc4a05385ef1f.bundle.js
5 months ago
78dd4dee6173d40eb75a.bundle.min.js
2 months ago
7dae73b622bebe8a5d94.bundle.js
5 months ago
7f2c78456ab3f406f3df.bundle.js
5 months ago
8277989eebcfba278cb0.bundle.min.js
8 months ago
84288e5699f5d8b8b23e.bundle.min.js
5 months ago
877227b9d759b63096a9.bundle.js
5 months ago
8ac2c6e532225b54dba2.bundle.js
5 months ago
8b4f35f99eb521b37d0c.bundle.js
5 months ago
8e5b42844d27eada9b53.bundle.min.js
2 months ago
8e80438d29fc79b648e5.bundle.js
2 months ago
8e8b47ad5b4e4d038c80.bundle.js
5 months ago
8ecfd8495b7ec419862a.bundle.js
5 months ago
979a9c03fe10da23400d.bundle.js
2 months ago
9832c866a8fe9b51f9d2.bundle.min.js
5 months ago
9b97a73ee8fdc5fb7dc3.bundle.js
3 months ago
9bd390911e34b349d8cb.bundle.min.js
2 months ago
9dcd9e88237da6496816.bundle.min.js
5 months ago
9e7e356552c03a622b0f.bundle.js
2 months ago
a2ea929f439e819b924b.bundle.min.js
5 months ago
a9f41949787209626737.bundle.min.js
5 months ago
ac53273f887639e3c6ea.bundle.min.js
5 months ago
accordion.8b0db5058afeb74622f5.bundle.min.js
8 months ago
accordion.b9a0ab19c7c872c405d7.bundle.js
6 months ago
admin-feedback.js
8 months ago
admin-feedback.min.js
8 months ago
admin-feedback.strings.js
3 months ago
admin-modules.js
6 months ago
admin-modules.min.js
6 months ago
admin-modules.min.js.LICENSE.txt
10 months ago
admin-modules.strings.js
1 month ago
admin-notifications.js
8 months ago
admin-notifications.min.js
8 months ago
admin-notifications.strings.js
6 months ago
admin-top-bar.js
2 months ago
admin-top-bar.min.js
2 months ago
admin-top-bar.strings.js
6 months ago
admin.js
2 months ago
admin.min.js
2 months ago
admin.min.js.LICENSE.txt
10 months ago
admin.strings.js
6 months ago
aee13673e923469c3275.bundle.min.js
5 months ago
ai-admin.js
6 months ago
ai-admin.min.js
6 months ago
ai-admin.min.js.LICENSE.txt
10 months ago
ai-admin.strings.js
6 months ago
ai-gutenberg.js
6 months ago
ai-gutenberg.min.js
6 months ago
ai-gutenberg.min.js.LICENSE.txt
10 months ago
ai-gutenberg.strings.js
6 months ago
ai-layout.js
3 months ago
ai-layout.min.js
3 months ago
ai-layout.min.js.LICENSE.txt
10 months ago
ai-layout.strings.js
3 months ago
ai-media-library.js
6 months ago
ai-media-library.min.js
6 months ago
ai-media-library.min.js.LICENSE.txt
10 months ago
ai-media-library.strings.js
6 months ago
ai-unify-product-images.js
6 months ago
ai-unify-product-images.min.js
6 months ago
ai-unify-product-images.min.js.LICENSE.txt
10 months ago
ai-unify-product-images.strings.js
6 months ago
ai.js
6 months ago
ai.min.js
6 months ago
ai.min.js.LICENSE.txt
10 months ago
ai.strings.js
1 month ago
alert.42cc1d522ef5c60bf874.bundle.min.js
8 months ago
alert.fd509aa768e7b35a8e32.bundle.js
6 months ago
announcements-app.js
2 months ago
announcements-app.min.js
2 months ago
announcements-app.min.js.LICENSE.txt
10 months ago
announcements-app.strings.js
6 months ago
app-loader.js
6 months ago
app-loader.min.js
8 months ago
app-loader.strings.js
1 month ago
app-packages.js
5 months ago
app-packages.min.js
5 months ago
app-packages.min.js.LICENSE.txt
10 months ago
app-packages.strings.js
1 month ago
app.js
2 months ago
app.min.js
2 months ago
app.min.js.LICENSE.txt
10 months ago
app.strings.js
1 month ago
atomic-widgets-editor.js
2 months ago
atomic-widgets-editor.min.js
2 months ago
atomic-widgets-editor.min.js.LICENSE.txt
4 months ago
atomic-widgets-editor.strings.js
2 months ago
atomic-widgets-frontend-handler.js
2 months ago
atomic-widgets-frontend-handler.min.js
2 months ago
b09b262748a4be8417ce.bundle.js
5 months ago
b668f6906820570e60b5.bundle.min.js
5 months ago
b96d70044d0d67c2df19.bundle.min.js
8 months ago
b97ced1683f62f5686fa.bundle.min.js
5 months ago
bcb5135af6b817bc9708.bundle.min.js
2 months ago
beta-tester.js
8 months ago
beta-tester.min.js
8 months ago
beta-tester.strings.js
6 months ago
bff204c1ab0d15e0a69b.bundle.min.js
5 months ago
c13d205fa26f8af1ce7c.bundle.js
6 months ago
cf6ec600fcf4e08ba6d3.bundle.js
5 months ago
checklist.js
6 months ago
checklist.min.js
6 months ago
checklist.min.js.LICENSE.txt
10 months ago
checklist.strings.js
6 months ago
cloud-library-screenshot.js
6 months ago
cloud-library-screenshot.min.js
6 months ago
cloud-library-screenshot.min.js.LICENSE.txt
8 months ago
cloud-library-screenshot.strings.js
6 months ago
common-modules.js
2 months ago
common-modules.min.js
2 months ago
common-modules.strings.js
6 months ago
common.js
2 months ago
common.min.js
2 months ago
common.min.js.LICENSE.txt
10 months ago
common.strings.js
6 months ago
contact-buttons.086261d3e9c4d8037686.bundle.js
6 months ago
contact-buttons.e98d0220ce8c38404e7e.bundle.min.js
8 months ago
container-converter.js
8 months ago
container-converter.min.js
8 months ago
container-converter.strings.js
6 months ago
container-editor-handlers.a2e8e48d28c5544fb183.bundle.min.js
4 months ago
container-editor-handlers.e7e069c4e656425c51f8.bundle.js
4 months ago
counter.12335f45aaa79d244f24.bundle.min.js
8 months ago
counter.7310c276bc7865a3d438.bundle.js
6 months ago
d245aa80c28d9ec3617d.bundle.js
3 months ago
d42de03ef4a0f50e39ca.bundle.min.js
5 months ago
d4c67aa71d8173f6201f.bundle.js
2 months ago
d52aa05c75af56327744.bundle.js
6 months ago
d67ddd6f08b08392c42f.bundle.js
6 months ago
daedc6797eaad5c82711.bundle.min.js
8 months ago
db27207322ef9be952ee.bundle.js
5 months ago
design-system-sync.js
2 months ago
design-system-sync.min.js
2 months ago
design-system-sync.strings.js
2 months ago
dev-tools.js
8 months ago
dev-tools.min.js
8 months ago
dev-tools.strings.js
6 months ago
df2f2a2ae20e0181ec2d.bundle.js
2 months ago
e-home-screen.js
2 months ago
e-home-screen.min.js
2 months ago
e-home-screen.strings.js
2 months ago
e-react-promotions.js
2 months ago
e-react-promotions.min.js
2 months ago
e-react-promotions.min.js.LICENSE.txt
2 months ago
e-react-promotions.strings.js
6 months ago
e-wc-product-editor.js
6 months ago
e-wc-product-editor.min.js
8 months ago
e-wc-product-editor.min.js.LICENSE.txt
1 year ago
e-wc-product-editor.strings.js
6 months ago
e1cb4d726bb59646c677.bundle.min.js
8 months ago
e3b540e2c02813e75f38.bundle.min.js
5 months ago
e459c6c89c0c0899c850.bundle.js
6 months ago
e7d71f4e1d39edbc1fb6.bundle.js
5 months ago
eb5018119ee87fd6a7fc.bundle.min.js
2 months ago
editor-document.js
6 months ago
editor-document.min.js
8 months ago
editor-document.strings.js
1 month ago
editor-environment-v2.js
8 months ago
editor-environment-v2.min.js
8 months ago
editor-environment-v2.strings.js
6 months ago
editor-interactions.js
2 months ago
editor-interactions.min.js
2 months ago
editor-interactions.strings.js
6 months ago
editor-loader-v1.js
8 months ago
editor-loader-v1.min.js
8 months ago
editor-loader-v1.strings.js
6 months ago
editor-loader-v2.js
8 months ago
editor-loader-v2.min.js
8 months ago
editor-loader-v2.strings.js
6 months ago
editor-modules.js
2 months ago
editor-modules.min.js
2 months ago
editor-modules.min.js.LICENSE.txt
10 months ago
editor-modules.strings.js
1 month ago
editor-notifications.js
8 months ago
editor-notifications.min.js
8 months ago
editor-notifications.strings.js
6 months ago
editor-one-admin.js
6 months ago
editor-one-admin.min.js
6 months ago
editor-one-admin.strings.js
6 months ago
editor-one-menu.js
5 months ago
editor-one-menu.min.js
5 months ago
editor-one-menu.strings.js
6 months ago
editor-one-sidebar-navigation.js
2 months ago
editor-one-sidebar-navigation.min.js
2 months ago
editor-one-sidebar-navigation.min.js.LICENSE.txt
6 months ago
editor-one-sidebar-navigation.strings.js
6 months ago
editor-one-top-bar.js
2 months ago
editor-one-top-bar.min.js
2 months ago
editor-one-top-bar.min.js.LICENSE.txt
5 months ago
editor-one-top-bar.strings.js
5 months ago
editor-v4-opt-in-alphachip.js
2 months ago
editor-v4-opt-in-alphachip.min.js
2 months ago
editor-v4-opt-in-alphachip.strings.js
2 months ago
editor-v4-opt-in.js
2 months ago
editor-v4-opt-in.min.js
2 months ago
editor-v4-opt-in.min.js.LICENSE.txt
6 months ago
editor-v4-opt-in.strings.js
2 months ago
editor.js
2 months ago
editor.min.js
2 months ago
editor.min.js.LICENSE.txt
6 months ago
editor.strings.js
6 months ago
ef2100ac3eda1a957819.bundle.min.js
8 months ago
ef35c83e4628f0a5c328.bundle.js
5 months ago
element-manager-admin.js
2 months ago
element-manager-admin.min.js
2 months ago
element-manager-admin.min.js.LICENSE.txt
10 months ago
element-manager-admin.strings.js
2 months ago
elementor-admin-bar.js
8 months ago
elementor-admin-bar.min.js
8 months ago
elementor-admin-bar.strings.js
6 months ago
f56b0d1257a5346afe64.bundle.min.js
2 months ago
fdda4547e887fbda71b3.bundle.js
2 months ago
fdf69f4e1f300fb27472.bundle.min.js
2 months ago
floating-bars.740d06d17cea5cebdb61.bundle.min.js
8 months ago
floating-bars.a6e6a043444b62f64f82.bundle.js
6 months ago
floating-elements-modal.js
2 months ago
floating-elements-modal.min.js
2 months ago
floating-elements-modal.strings.js
6 months ago
frontend-modules.js
2 months ago
frontend-modules.min.js
2 months ago
frontend.js
3 months ago
frontend.min.js
3 months ago
gutenberg.js
8 months ago
gutenberg.min.js
8 months ago
gutenberg.strings.js
3 months ago
image-carousel.6167d20b95b33386757b.bundle.min.js
8 months ago
image-carousel.8b25f3674c29b829a867.bundle.js
6 months ago
import-export-admin.js
6 months ago
import-export-admin.min.js
6 months ago
import-export-admin.strings.js
1 month ago
import-export-customization-admin.js
2 months ago
import-export-customization-admin.min.js
2 months ago
import-export-customization-admin.min.js.LICENSE.txt
8 months ago
import-export-customization-admin.strings.js
1 month ago
interactions-shared-utils.js
2 months ago
interactions-shared-utils.min.js
2 months ago
interactions-shared-utils.strings.js
2 months ago
interactions.js
2 months ago
interactions.min.js
2 months ago
interactions.strings.js
6 months ago
kit-elements-defaults-editor.js
6 months ago
kit-elements-defaults-editor.min.js
6 months ago
kit-elements-defaults-editor.min.js.LICENSE.txt
10 months ago
kit-elements-defaults-editor.strings.js
6 months ago
kit-library.a394510096bc447f636d.bundle.min.js
2 months ago
kit-library.b768952e1d4177aa68d8.bundle.js
2 months ago
lightbox.570c05c5a283cfb6b223.bundle.min.js
3 months ago
lightbox.d9ea72d232a14f514ee2.bundle.js
3 months ago
media-hints.js
8 months ago
media-hints.min.js
8 months ago
media-hints.strings.js
6 months ago
nested-accordion.294d40984397351fd0f5.bundle.min.js
4 months ago
nested-accordion.4340b64226322f36bcc0.bundle.js
4 months ago
nested-accordion.js
6 months ago
nested-accordion.min.js
6 months ago
nested-accordion.min.js.LICENSE.txt
10 months ago
nested-accordion.strings.js
6 months ago
nested-elements.js
3 months ago
nested-elements.min.js
3 months ago
nested-elements.strings.js
6 months ago
nested-tabs.7a338e6d7e060c473993.bundle.js
6 months ago
nested-tabs.a2401356d329f179475e.bundle.min.js
6 months ago
nested-tabs.js
6 months ago
nested-tabs.min.js
6 months ago
nested-tabs.min.js.LICENSE.txt
10 months ago
nested-tabs.strings.js
6 months ago
nested-title-keyboard-handler.0c2b498e3e0695a1dc19.bundle.js
6 months ago
nested-title-keyboard-handler.2a67d3cc630e11815acc.bundle.min.js
6 months ago
new-template.js
5 months ago
new-template.min.js
5 months ago
new-template.strings.js
6 months ago
notes.js
8 months ago
notes.min.js
8 months ago
notes.strings.js
6 months ago
pro-free-trial-popup.js
8 months ago
pro-free-trial-popup.min.js
8 months ago
pro-free-trial-popup.strings.js
6 months ago
pro-install-events.js
8 months ago
pro-install-events.min.js
8 months ago
pro-install-events.strings.js
6 months ago
progress.0ea083b809812c0e3aa1.bundle.min.js
8 months ago
progress.b1057ba870016558bce1.bundle.js
6 months ago
responsive-bar.js
8 months ago
responsive-bar.min.js
8 months ago
responsive-bar.strings.js
6 months ago
section-editor-handlers.53ffedef32043348b99b.bundle.min.js
8 months ago
section-editor-handlers.d65899d232b5339510d7.bundle.js
6 months ago
section-frontend-handlers.c3950c6b190ca134bc8d.bundle.js
6 months ago
section-frontend-handlers.d85ab872da118940910d.bundle.min.js
8 months ago
shared-editor-handlers.3023894100138e442ab0.bundle.js
4 months ago
shared-editor-handlers.cacdcbed391abf4b48b0.bundle.min.js
4 months ago
shared-frontend-handlers.03caa53373b56d3bab67.bundle.min.js
8 months ago
shared-frontend-handlers.3b079824c37a5fe2bdaa.bundle.js
6 months ago
styleguide-app-initiator.js
6 months ago
styleguide-app-initiator.min.js
6 months ago
styleguide-app-initiator.min.js.LICENSE.txt
10 months ago
styleguide-app-initiator.strings.js
6 months ago
styleguide-app.04340244193733d78622.bundle.min.js
8 months ago
styleguide-app.36ecabae74d9b87fc5a8.bundle.js
6 months ago
styleguide.js
8 months ago
styleguide.min.js
8 months ago
styleguide.strings.js
4 months ago
tabs-handler.js
2 months ago
tabs-handler.min.js
2 months ago
tabs-preview-handler.js
6 months ago
tabs-preview-handler.min.js
6 months ago
tabs.18344b05d8d1ea0702bc.bundle.min.js
8 months ago
tabs.40498fa771d612162c53.bundle.js
6 months ago
text-editor.0c9960167105139d27c9.bundle.js
6 months ago
text-editor.45609661e409413f1cef.bundle.min.js
8 months ago
text-path.6db73cc0a10a70f128eb.bundle.js
3 months ago
text-path.a67c1f3a78d208bc7e1b.bundle.min.js
3 months ago
toggle.2a177a3ef4785d3dfbc5.bundle.min.js
8 months ago
toggle.b75e66d2aca6f6ee742e.bundle.js
6 months ago
video.6e96510afa701d1f2ebc.bundle.js
6 months ago
video.86d44e46e43d0807e708.bundle.min.js
8 months ago
web-cli.js
6 months ago
web-cli.min.js
6 months ago
web-cli.min.js.LICENSE.txt
10 months ago
web-cli.strings.js
6 months ago
webpack.runtime.js
3 months ago
webpack.runtime.min.js
3 months ago
wp-audio.0ba9114964acf4c37ca2.bundle.js
6 months ago
wp-audio.c9624cb6e5dc9de86abd.bundle.min.js
8 months ago
youtube-handler.js
6 months ago
youtube-handler.min.js
6 months ago
nested-tabs.7a338e6d7e060c473993.bundle.js
503 lines
| 1 | "use strict"; |
| 2 | (self["webpackChunkelementorFrontend"] = self["webpackChunkelementorFrontend"] || []).push([["nested-tabs"],{ |
| 3 | |
| 4 | /***/ "../assets/dev/js/frontend/utils/flex-horizontal-scroll.js": |
| 5 | /*!*****************************************************************!*\ |
| 6 | !*** ../assets/dev/js/frontend/utils/flex-horizontal-scroll.js ***! |
| 7 | \*****************************************************************/ |
| 8 | /***/ ((__unused_webpack_module, exports) => { |
| 9 | |
| 10 | |
| 11 | |
| 12 | Object.defineProperty(exports, "__esModule", ({ |
| 13 | value: true |
| 14 | })); |
| 15 | exports.changeScrollStatus = changeScrollStatus; |
| 16 | exports.setHorizontalScrollAlignment = setHorizontalScrollAlignment; |
| 17 | exports.setHorizontalTitleScrollValues = setHorizontalTitleScrollValues; |
| 18 | function changeScrollStatus(element, event) { |
| 19 | if ('mousedown' === event.type) { |
| 20 | element.classList.add('e-scroll'); |
| 21 | element.dataset.pageX = event.pageX; |
| 22 | } else { |
| 23 | element.classList.remove('e-scroll', 'e-scroll-active'); |
| 24 | element.dataset.pageX = ''; |
| 25 | } |
| 26 | } |
| 27 | |
| 28 | // This function was written using this example https://codepen.io/thenutz/pen/VwYeYEE. |
| 29 | function setHorizontalTitleScrollValues(element, horizontalScrollStatus, event) { |
| 30 | const isActiveScroll = element.classList.contains('e-scroll'), |
| 31 | isHorizontalScrollActive = 'enable' === horizontalScrollStatus, |
| 32 | headingContentIsWiderThanWrapper = element.scrollWidth > element.clientWidth; |
| 33 | if (!isActiveScroll || !isHorizontalScrollActive || !headingContentIsWiderThanWrapper) { |
| 34 | return; |
| 35 | } |
| 36 | event.preventDefault(); |
| 37 | const previousPositionX = parseFloat(element.dataset.pageX), |
| 38 | mouseMoveX = event.pageX - previousPositionX, |
| 39 | maximumScrollValue = 5, |
| 40 | stepLimit = 20; |
| 41 | let toScrollDistanceX = 0; |
| 42 | if (stepLimit < mouseMoveX) { |
| 43 | toScrollDistanceX = maximumScrollValue; |
| 44 | } else if (stepLimit * -1 > mouseMoveX) { |
| 45 | toScrollDistanceX = -1 * maximumScrollValue; |
| 46 | } else { |
| 47 | toScrollDistanceX = mouseMoveX; |
| 48 | } |
| 49 | element.scrollLeft = element.scrollLeft - toScrollDistanceX; |
| 50 | element.classList.add('e-scroll-active'); |
| 51 | } |
| 52 | function setHorizontalScrollAlignment({ |
| 53 | element, |
| 54 | direction, |
| 55 | justifyCSSVariable, |
| 56 | horizontalScrollStatus |
| 57 | }) { |
| 58 | if (!element) { |
| 59 | return; |
| 60 | } |
| 61 | if (isHorizontalScroll(element, horizontalScrollStatus)) { |
| 62 | initialScrollPosition(element, direction, justifyCSSVariable); |
| 63 | } else { |
| 64 | element.style.setProperty(justifyCSSVariable, ''); |
| 65 | } |
| 66 | } |
| 67 | function isHorizontalScroll(element, horizontalScrollStatus) { |
| 68 | return element.clientWidth < getChildrenWidth(element.children) && 'enable' === horizontalScrollStatus; |
| 69 | } |
| 70 | function getChildrenWidth(children) { |
| 71 | let totalWidth = 0; |
| 72 | const parentContainer = children[0].parentNode, |
| 73 | computedStyles = getComputedStyle(parentContainer), |
| 74 | gap = parseFloat(computedStyles.gap) || 0; // Get the gap value or default to 0 if it's not specified |
| 75 | |
| 76 | for (let i = 0; i < children.length; i++) { |
| 77 | totalWidth += children[i].offsetWidth + gap; |
| 78 | } |
| 79 | return totalWidth; |
| 80 | } |
| 81 | function initialScrollPosition(element, direction, justifyCSSVariable) { |
| 82 | const isRTL = elementorFrontend.config.is_rtl; |
| 83 | switch (direction) { |
| 84 | case 'end': |
| 85 | element.style.setProperty(justifyCSSVariable, 'start'); |
| 86 | element.scrollLeft = isRTL ? -1 * getChildrenWidth(element.children) : getChildrenWidth(element.children); |
| 87 | break; |
| 88 | default: |
| 89 | element.style.setProperty(justifyCSSVariable, 'start'); |
| 90 | element.scrollLeft = 0; |
| 91 | } |
| 92 | } |
| 93 | |
| 94 | /***/ }), |
| 95 | |
| 96 | /***/ "../modules/nested-tabs/assets/js/frontend/handlers/nested-tabs.js": |
| 97 | /*!*************************************************************************!*\ |
| 98 | !*** ../modules/nested-tabs/assets/js/frontend/handlers/nested-tabs.js ***! |
| 99 | \*************************************************************************/ |
| 100 | /***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 101 | |
| 102 | |
| 103 | |
| 104 | var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); |
| 105 | Object.defineProperty(exports, "__esModule", ({ |
| 106 | value: true |
| 107 | })); |
| 108 | exports["default"] = void 0; |
| 109 | __webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 110 | __webpack_require__(/*! core-js/modules/esnext.iterator.filter.js */ "../node_modules/core-js/modules/esnext.iterator.filter.js"); |
| 111 | __webpack_require__(/*! core-js/modules/esnext.iterator.find.js */ "../node_modules/core-js/modules/esnext.iterator.find.js"); |
| 112 | var _base = _interopRequireDefault(__webpack_require__(/*! elementor-frontend/handlers/base */ "../assets/dev/js/frontend/handlers/base.js")); |
| 113 | var _flexHorizontalScroll = __webpack_require__(/*! elementor-frontend-utils/flex-horizontal-scroll */ "../assets/dev/js/frontend/utils/flex-horizontal-scroll.js"); |
| 114 | class NestedTabs extends _base.default { |
| 115 | /** |
| 116 | * @param {string|number} tabIndex |
| 117 | * |
| 118 | * @return {string} |
| 119 | */ |
| 120 | getTabTitleFilterSelector(tabIndex) { |
| 121 | return `[${this.getSettings('dataAttributes').tabIndex}="${tabIndex}"]`; |
| 122 | } |
| 123 | |
| 124 | /** |
| 125 | * @param {string|number} tabIndex |
| 126 | * |
| 127 | * @return {string} |
| 128 | */ |
| 129 | getTabContentFilterSelector(tabIndex) { |
| 130 | return `*:nth-child(${tabIndex})`; |
| 131 | } |
| 132 | |
| 133 | /** |
| 134 | * @param {HTMLElement} tabTitleElement |
| 135 | * |
| 136 | * @return {string} |
| 137 | */ |
| 138 | getTabIndex(tabTitleElement) { |
| 139 | return tabTitleElement.getAttribute(this.getSettings('dataAttributes').tabIndex); |
| 140 | } |
| 141 | getActiveTabIndex() { |
| 142 | const settings = this.getSettings(), |
| 143 | activeTitleFilter = settings.ariaAttributes.activeTitleSelector, |
| 144 | tabIndexSelector = settings.dataAttributes.tabIndex, |
| 145 | $activeTitle = this.elements.$tabTitles.filter(activeTitleFilter); |
| 146 | return $activeTitle.attr(tabIndexSelector) || null; |
| 147 | } |
| 148 | getWidgetNumber() { |
| 149 | return this.$element.find('> .elementor-widget-container > .e-n-tabs, > .e-n-tabs').attr('data-widget-number'); |
| 150 | } |
| 151 | getDefaultSettings() { |
| 152 | const widgetNumber = this.getWidgetNumber(); |
| 153 | return { |
| 154 | selectors: { |
| 155 | widgetContainer: `[data-widget-number="${widgetNumber}"]`, |
| 156 | tabTitle: `[aria-controls*="e-n-tab-content-${widgetNumber}"]`, |
| 157 | tabTitleIcon: `[data-tab-title-id*="e-n-tab-title-${widgetNumber}"] > .e-n-tab-icon`, |
| 158 | tabTitleText: `[data-tab-title-id*="e-n-tab-title-${widgetNumber}"] > .e-n-tab-title-text`, |
| 159 | tabContent: `[data-widget-number="${widgetNumber}"] > .e-n-tabs-content > .e-con`, |
| 160 | headingContainer: `[data-widget-number="${widgetNumber}"] > .e-n-tabs-heading`, |
| 161 | activeTabContentContainers: `[id*="e-n-tab-content-${widgetNumber}"].e-active` |
| 162 | }, |
| 163 | classes: { |
| 164 | active: 'e-active' |
| 165 | }, |
| 166 | dataAttributes: { |
| 167 | tabIndex: 'data-tab-index' |
| 168 | }, |
| 169 | ariaAttributes: { |
| 170 | titleStateAttribute: 'aria-selected', |
| 171 | activeTitleSelector: '[aria-selected="true"]' |
| 172 | }, |
| 173 | showTabFn: 'show', |
| 174 | hideTabFn: 'hide', |
| 175 | toggleSelf: false, |
| 176 | hidePrevious: true, |
| 177 | autoExpand: true |
| 178 | }; |
| 179 | } |
| 180 | getDefaultElements() { |
| 181 | const selectors = this.getSettings('selectors'); |
| 182 | return { |
| 183 | $widgetContainer: this.findElement(selectors.widgetContainer), |
| 184 | $tabTitles: this.findElement(selectors.tabTitle), |
| 185 | $tabContents: this.findElement(selectors.tabContent), |
| 186 | $headingContainer: this.findElement(selectors.headingContainer) |
| 187 | }; |
| 188 | } |
| 189 | getKeyboardNavigationSettings() { |
| 190 | return this.getSettings(); |
| 191 | } |
| 192 | activateDefaultTab() { |
| 193 | const settings = this.getSettings(); |
| 194 | const defaultActiveTab = this.getEditSettings('activeItemIndex') || 1, |
| 195 | originalToggleMethods = { |
| 196 | showTabFn: settings.showTabFn, |
| 197 | hideTabFn: settings.hideTabFn |
| 198 | }; |
| 199 | |
| 200 | // Toggle tabs without animation to avoid jumping |
| 201 | this.setSettings({ |
| 202 | showTabFn: 'show', |
| 203 | hideTabFn: 'hide' |
| 204 | }); |
| 205 | this.changeActiveTab(defaultActiveTab); |
| 206 | |
| 207 | // Return back original toggle effects |
| 208 | this.setSettings(originalToggleMethods); |
| 209 | this.elements.$widgetContainer.addClass('e-activated'); |
| 210 | } |
| 211 | deactivateActiveTab(newTabIndex) { |
| 212 | const settings = this.getSettings(), |
| 213 | activeClass = settings.classes.active, |
| 214 | activeTitleFilter = settings.ariaAttributes.activeTitleSelector, |
| 215 | activeContentFilter = '.' + activeClass, |
| 216 | $activeTitle = this.elements.$tabTitles.filter(activeTitleFilter), |
| 217 | $activeContent = this.elements.$tabContents.filter(activeContentFilter); |
| 218 | this.setTabDeactivationAttributes($activeTitle, newTabIndex); |
| 219 | $activeContent.removeClass(activeClass); |
| 220 | $activeContent[settings.hideTabFn](0, () => this.onHideTabContent($activeContent)); |
| 221 | return $activeContent; |
| 222 | } |
| 223 | getTitleActivationAttributes() { |
| 224 | const titleStateAttribute = this.getSettings('ariaAttributes').titleStateAttribute; |
| 225 | return { |
| 226 | tabindex: '0', |
| 227 | [titleStateAttribute]: 'true' |
| 228 | }; |
| 229 | } |
| 230 | setTabDeactivationAttributes($activeTitle) { |
| 231 | const titleStateAttribute = this.getSettings('ariaAttributes').titleStateAttribute; |
| 232 | $activeTitle.attr({ |
| 233 | tabindex: '-1', |
| 234 | [titleStateAttribute]: 'false' |
| 235 | }); |
| 236 | } |
| 237 | onHideTabContent() {} |
| 238 | activateTab(tabIndex) { |
| 239 | const settings = this.getSettings(), |
| 240 | activeClass = settings.classes.active, |
| 241 | animationDuration = 'show' === settings.showTabFn ? 0 : 400; |
| 242 | let $requestedTitle = this.elements.$tabTitles.filter(this.getTabTitleFilterSelector(tabIndex)), |
| 243 | $requestedContent = this.elements.$tabContents.filter(this.getTabContentFilterSelector(tabIndex)); |
| 244 | |
| 245 | // Check if the tabIndex exists. |
| 246 | if (!$requestedTitle.length) { |
| 247 | // Activate the previous tab and ensure that the tab index is not less than 1. |
| 248 | const previousTabIndex = Math.max(tabIndex - 1, 1); |
| 249 | $requestedTitle = this.elements.$tabTitles.filter(this.getTabTitleFilterSelector(previousTabIndex)); |
| 250 | $requestedContent = this.elements.$tabContents.filter(this.getTabContentFilterSelector(previousTabIndex)); |
| 251 | } |
| 252 | $requestedTitle.attr(this.getTitleActivationAttributes()); |
| 253 | $requestedContent.addClass(activeClass); |
| 254 | $requestedContent[settings.showTabFn](animationDuration, () => this.onShowTabContent($requestedContent)); |
| 255 | } |
| 256 | onShowTabContent($requestedContent) { |
| 257 | elementorFrontend.elements.$window.trigger('elementor-pro/motion-fx/recalc'); |
| 258 | elementorFrontend.elements.$window.trigger('elementor/nested-tabs/activate', $requestedContent); |
| 259 | elementorFrontend.elements.$window.trigger('elementor/bg-video/recalc'); |
| 260 | } |
| 261 | isActiveTab(tabIndex) { |
| 262 | const settings = this.getSettings(), |
| 263 | isActiveTabTitle = 'true' === this.elements.$tabTitles.filter(`[${settings.dataAttributes.tabIndex}="${tabIndex}"]`).attr(settings.ariaAttributes.titleStateAttribute), |
| 264 | isActiveTabContent = this.elements.$tabContents.filter(this.getTabContentFilterSelector(tabIndex)).hasClass(this.getActiveClass()); |
| 265 | return isActiveTabTitle && isActiveTabContent; |
| 266 | } |
| 267 | onTabClick(event) { |
| 268 | event.preventDefault(); |
| 269 | this.changeActiveTab(event.currentTarget?.getAttribute(this.getSettings('dataAttributes').tabIndex), true); |
| 270 | } |
| 271 | getTabEvents() { |
| 272 | return { |
| 273 | click: this.onTabClick.bind(this) |
| 274 | }; |
| 275 | } |
| 276 | getHeadingEvents() { |
| 277 | const navigationWrapper = this.elements.$headingContainer[0]; |
| 278 | return { |
| 279 | mousedown: _flexHorizontalScroll.changeScrollStatus.bind(this, navigationWrapper), |
| 280 | mouseup: _flexHorizontalScroll.changeScrollStatus.bind(this, navigationWrapper), |
| 281 | mouseleave: _flexHorizontalScroll.changeScrollStatus.bind(this, navigationWrapper), |
| 282 | mousemove: _flexHorizontalScroll.setHorizontalTitleScrollValues.bind(this, navigationWrapper, this.getHorizontalScrollSetting()) |
| 283 | }; |
| 284 | } |
| 285 | bindEvents() { |
| 286 | this.elements.$tabTitles.on(this.getTabEvents()); |
| 287 | this.elements.$headingContainer.on(this.getHeadingEvents()); |
| 288 | elementorFrontend.elements.$window.on('resize', this.onResizeUpdateHorizontalScrolling.bind(this)); |
| 289 | elementorFrontend.elements.$window.on('resize', this.setTouchMode.bind(this)); |
| 290 | elementorFrontend.elements.$window.on('elementor/nested-tabs/activate', this.reInitSwipers); |
| 291 | elementorFrontend.elements.$window.on('elementor/nested-elements/activate-by-keyboard', this.changeActiveTabByKeyboard.bind(this)); |
| 292 | elementorFrontend.elements.$window.on('elementor/nested-container/atomic-repeater', this.linkContainer.bind(this)); |
| 293 | } |
| 294 | unbindEvents() { |
| 295 | this.elements.$tabTitles.off(); |
| 296 | this.elements.$headingContainer.off(); |
| 297 | this.elements.$tabContents.children().off(); |
| 298 | elementorFrontend.elements.$window.off('resize', this.onResizeUpdateHorizontalScrolling.bind(this)); |
| 299 | elementorFrontend.elements.$window.off('resize', this.setTouchMode.bind(this)); |
| 300 | elementorFrontend.elements.$window.off('elementor/nested-tabs/activate', this.reInitSwipers); |
| 301 | elementorFrontend.elements.$window.off('elementor/nested-elements/activate-by-keyboard', this.changeActiveTabByKeyboard.bind(this)); |
| 302 | elementorFrontend.elements.$window.off('elementor/nested-container/atomic-repeater', this.linkContainer.bind(this)); |
| 303 | } |
| 304 | |
| 305 | /** |
| 306 | * Fixes issues where Swipers that have been initialized while a tab is not visible are not properly rendered |
| 307 | * and when switching to the tab the swiper will not respect any of the chosen `autoplay` related settings. |
| 308 | * |
| 309 | * This is triggered when switching to a nested tab, looks for Swipers in the tab content and reinitializes them. |
| 310 | * |
| 311 | * @param {Object} event - Incoming event. |
| 312 | * @param {Object} content - Active nested tab dom element. |
| 313 | */ |
| 314 | reInitSwipers(event, content) { |
| 315 | const swiperElements = content.querySelectorAll('.swiper'); |
| 316 | for (const element of swiperElements) { |
| 317 | if (!element.swiper) { |
| 318 | return; |
| 319 | } |
| 320 | element.swiper.initialized = false; |
| 321 | element.swiper.init(); |
| 322 | } |
| 323 | } |
| 324 | onInit(...args) { |
| 325 | super.onInit(...args); |
| 326 | if (this.getSettings('autoExpand')) { |
| 327 | this.activateDefaultTab(); |
| 328 | } |
| 329 | (0, _flexHorizontalScroll.setHorizontalScrollAlignment)(this.getHorizontalScrollingSettings()); |
| 330 | this.setTouchMode(); |
| 331 | if ('nested-tabs.default' === this.getSettings('elementName')) { |
| 332 | __webpack_require__.e(/*! import() | nested-title-keyboard-handler */ "nested-title-keyboard-handler").then(__webpack_require__.bind(__webpack_require__, /*! elementor-frontend/handlers/accessibility/nested-title-keyboard-handler */ "../assets/dev/js/frontend/handlers/accessibility/nested-title-keyboard-handler.js")).then(({ |
| 333 | default: NestedTitleKeyboardHandler |
| 334 | }) => { |
| 335 | new NestedTitleKeyboardHandler(this.getKeyboardNavigationSettings()); |
| 336 | }).catch(error => { |
| 337 | // eslint-disable-next-line no-console |
| 338 | console.error('Error importing module:', error); |
| 339 | }); |
| 340 | } |
| 341 | } |
| 342 | onEditSettingsChange(propertyName, value) { |
| 343 | if ('activeItemIndex' === propertyName) { |
| 344 | this.changeActiveTab(value, false); |
| 345 | } |
| 346 | } |
| 347 | onElementChange(propertyName) { |
| 348 | if (this.checkSliderPropsToWatch(propertyName)) { |
| 349 | (0, _flexHorizontalScroll.setHorizontalScrollAlignment)(this.getHorizontalScrollingSettings()); |
| 350 | } |
| 351 | } |
| 352 | checkSliderPropsToWatch(propertyName) { |
| 353 | return 0 === propertyName.indexOf('horizontal_scroll') || 'breakpoint_selector' === propertyName || 0 === propertyName.indexOf('tabs_justify_horizontal') || 0 === propertyName.indexOf('tabs_title_space_between'); |
| 354 | } |
| 355 | |
| 356 | /** |
| 357 | * @param {string} tabIndex |
| 358 | * @param {boolean} fromUser - Whether the call is caused by the user or internal. |
| 359 | */ |
| 360 | changeActiveTab(tabIndex, fromUser = false) { |
| 361 | // `document/repeater/select` is used only in the editor, only when the element |
| 362 | // is in the currently-edited document, and only when its not internal call, |
| 363 | if (fromUser && this.isEdit && this.isElementInTheCurrentDocument()) { |
| 364 | return window.top.$e.run('document/repeater/select', { |
| 365 | container: elementor.getContainer(this.$element.attr('data-id')), |
| 366 | index: parseInt(tabIndex) |
| 367 | }); |
| 368 | } |
| 369 | const isActiveTab = this.isActiveTab(tabIndex), |
| 370 | settings = this.getSettings(); |
| 371 | if ((settings.toggleSelf || !isActiveTab) && settings.hidePrevious) { |
| 372 | this.deactivateActiveTab(tabIndex); |
| 373 | } |
| 374 | if (!settings.hidePrevious && isActiveTab) { |
| 375 | this.deactivateActiveTab(tabIndex); |
| 376 | } |
| 377 | if (!isActiveTab) { |
| 378 | if (this.isAccordionVersion()) { |
| 379 | this.activateMobileTab(tabIndex); |
| 380 | return; |
| 381 | } |
| 382 | this.activateTab(tabIndex); |
| 383 | } |
| 384 | } |
| 385 | changeActiveTabByKeyboard(event, settings) { |
| 386 | if (settings.widgetId.toString() !== this.getID().toString()) { |
| 387 | return; |
| 388 | } |
| 389 | this.changeActiveTab(settings.titleIndex, true); |
| 390 | } |
| 391 | activateMobileTab(tabIndex) { |
| 392 | // Timeout time added to ensure that opening of the active tab starts after closing the other tab on Apple devices. |
| 393 | setTimeout(() => { |
| 394 | this.activateTab(tabIndex); |
| 395 | this.forceActiveTabToBeInViewport(tabIndex); |
| 396 | }, 10); |
| 397 | } |
| 398 | forceActiveTabToBeInViewport(tabIndex) { |
| 399 | if (!elementorFrontend.isEditMode()) { |
| 400 | return; |
| 401 | } |
| 402 | const $activeTabTitle = this.elements.$tabTitles.filter(this.getTabTitleFilterSelector(tabIndex)); |
| 403 | if (!elementor.helpers.isInViewport($activeTabTitle[0])) { |
| 404 | $activeTabTitle[0].scrollIntoView({ |
| 405 | block: 'center' |
| 406 | }); |
| 407 | } |
| 408 | } |
| 409 | getActiveClass() { |
| 410 | const settings = this.getSettings(); |
| 411 | return settings.classes.active; |
| 412 | } |
| 413 | getTabsDirection() { |
| 414 | const currentDevice = elementorFrontend.getCurrentDeviceMode(); |
| 415 | return elementorFrontend.utils.controls.getResponsiveControlValue(this.getElementSettings(), 'tabs_justify_horizontal', '', currentDevice); |
| 416 | } |
| 417 | getHorizontalScrollSetting() { |
| 418 | const currentDevice = elementorFrontend.getCurrentDeviceMode(); |
| 419 | return elementorFrontend.utils.controls.getResponsiveControlValue(this.getElementSettings(), 'horizontal_scroll', '', currentDevice); |
| 420 | } |
| 421 | isAccordionVersion() { |
| 422 | return 'contents' === this.elements.$headingContainer.css('display'); |
| 423 | } |
| 424 | setTouchMode() { |
| 425 | const widgetSelector = this.getSettings('selectors').widgetContainer; |
| 426 | if (elementorFrontend.isEditMode() || 'resize' === event?.type) { |
| 427 | const responsiveDevices = ['mobile', 'mobile_extra', 'tablet', 'tablet_extra'], |
| 428 | currentDevice = elementorFrontend.getCurrentDeviceMode(); |
| 429 | if (-1 !== responsiveDevices.indexOf(currentDevice)) { |
| 430 | this.$element.find(widgetSelector).attr('data-touch-mode', 'true'); |
| 431 | return; |
| 432 | } |
| 433 | } else if ('ontouchstart' in window) { |
| 434 | this.$element.find(widgetSelector).attr('data-touch-mode', 'true'); |
| 435 | return; |
| 436 | } |
| 437 | this.$element.find(widgetSelector).attr('data-touch-mode', 'false'); |
| 438 | } |
| 439 | linkContainer(event) { |
| 440 | const { |
| 441 | container |
| 442 | } = event.detail, |
| 443 | id = container.model.get('id'), |
| 444 | currentId = this.$element.data('id'), |
| 445 | view = container.view.$el; |
| 446 | if (id === currentId) { |
| 447 | this.updateIndexValues(); |
| 448 | this.updateListeners(view); |
| 449 | elementor.$preview[0].contentWindow.dispatchEvent(new CustomEvent('elementor/elements/link-data-bindings')); |
| 450 | } |
| 451 | if (!this.getActiveTabIndex()) { |
| 452 | const targetIndex = event.detail.index + 1 || 1; |
| 453 | this.changeActiveTab(targetIndex); |
| 454 | } |
| 455 | } |
| 456 | updateListeners(view) { |
| 457 | this.elements.$tabContents = view.find(this.getSettings('selectors.tabContent')); |
| 458 | this.elements.$tabTitles = view.find(this.getSettings('selectors.tabTitle')); |
| 459 | this.elements.$tabTitles.on(this.getTabEvents()); |
| 460 | } |
| 461 | updateIndexValues() { |
| 462 | const { |
| 463 | $widgetContainer, |
| 464 | $tabContents, |
| 465 | $tabTitles |
| 466 | } = this.getDefaultElements(), |
| 467 | settings = this.getSettings(), |
| 468 | dataTabIndex = settings.dataAttributes.tabIndex, |
| 469 | widgetNumber = $widgetContainer.data('widgetNumber'); |
| 470 | $tabTitles.each((index, element) => { |
| 471 | const newIndex = index + 1, |
| 472 | updatedTabID = `e-n-tab-title-${widgetNumber}${newIndex}`, |
| 473 | updatedContainerID = `e-n-tab-content-${widgetNumber}${newIndex}`; |
| 474 | element.setAttribute('id', updatedTabID); |
| 475 | element.setAttribute('style', `--n-tabs-title-order: ${newIndex}`); |
| 476 | element.setAttribute(dataTabIndex, newIndex); |
| 477 | element.setAttribute('aria-controls', updatedContainerID); |
| 478 | element.querySelector(settings.selectors.tabTitleIcon)?.setAttribute('data-binding-index', newIndex); |
| 479 | element.querySelector(settings.selectors.tabTitleText).setAttribute('data-binding-index', newIndex); |
| 480 | $tabContents[index].setAttribute('aria-labelledby', updatedTabID); |
| 481 | $tabContents[index].setAttribute(dataTabIndex, newIndex); |
| 482 | $tabContents[index].setAttribute('id', updatedContainerID); |
| 483 | $tabContents[index].setAttribute('style', `--n-tabs-title-order: ${newIndex}`); |
| 484 | }); |
| 485 | } |
| 486 | onResizeUpdateHorizontalScrolling() { |
| 487 | (0, _flexHorizontalScroll.setHorizontalScrollAlignment)(this.getHorizontalScrollingSettings()); |
| 488 | } |
| 489 | getHorizontalScrollingSettings() { |
| 490 | return { |
| 491 | element: this.elements.$headingContainer[0], |
| 492 | direction: this.getTabsDirection(), |
| 493 | justifyCSSVariable: '--n-tabs-heading-justify-content', |
| 494 | horizontalScrollStatus: this.getHorizontalScrollSetting() |
| 495 | }; |
| 496 | } |
| 497 | } |
| 498 | exports["default"] = NestedTabs; |
| 499 | |
| 500 | /***/ }) |
| 501 | |
| 502 | }]); |
| 503 | //# sourceMappingURL=nested-tabs.7a338e6d7e060c473993.bundle.js.map |