packages
4 months ago
00f53f1b378f6c98c043.bundle.min.js
5 months ago
04441cacbcc0ffea6713.bundle.min.js
4 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
254132ea6903b7cf0c30.bundle.js
5 months ago
2934fa380b70eb462ece.bundle.min.js
5 months ago
315ffba5a5bf098be034.bundle.min.js
5 months ago
35423d812dc1d52fdb27.bundle.min.js
5 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
40d841f4b4ce7b1928f5.bundle.js
5 months ago
4246c56134ca9ba65163.bundle.js
5 months ago
45167112673d4bc99f6b.bundle.js
5 months ago
45a55c192b49ad3f224d.bundle.js
5 months ago
45f1ae567e48fe3da9b0.bundle.min.js
8 months ago
4812775bcbc0ff8a9043.bundle.min.js
5 months ago
4886b33c17731474e197.bundle.min.js
5 months ago
54d62e5edbcf81b72a1f.bundle.min.js
5 months ago
5b13d0f77c0ac139c979.bundle.js
5 months ago
5be98965bbdf1c631fdf.bundle.min.js
5 months ago
6a19e86dd8c1f9165dbe.bundle.js
6 months ago
6cb9e42b9b73a76315e0.bundle.js
5 months ago
72459a35b6570acc77f3.bundle.js
5 months ago
75915b40e37cc6d910ef.bundle.js
5 months ago
7745b82dc4a05385ef1f.bundle.js
5 months ago
79016b3aba18d6be6dc3.bundle.min.js
5 months ago
7a5da9cf33b7d3557599.bundle.js
5 months ago
7a8c6c081d659e35d7d2.bundle.min.js
4 months ago
7d17894dc2ca045cfbb5.bundle.min.js
5 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
85106d35eeb23f6f4a33.bundle.min.js
4 months ago
877227b9d759b63096a9.bundle.js
5 months ago
8ac2c6e532225b54dba2.bundle.js
5 months ago
8b4f35f99eb521b37d0c.bundle.js
5 months ago
8b6212b7ad0ef8719b6b.bundle.min.js
5 months ago
8e8b47ad5b4e4d038c80.bundle.js
5 months ago
8ecfd8495b7ec419862a.bundle.js
5 months ago
9167bffba76b36a431f5.bundle.min.js
5 months ago
91c1e96a5c75bbc8ec6d.bundle.js
5 months ago
982fcee032dda41fa3a1.bundle.min.js
5 months ago
9832c866a8fe9b51f9d2.bundle.min.js
5 months ago
9dcd9e88237da6496816.bundle.min.js
5 months ago
9f88a0d716a691c2448a.bundle.min.js
8 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
5 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
6 months 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
5 months ago
admin-top-bar.min.js
5 months ago
admin-top-bar.strings.js
6 months ago
admin.js
4 months ago
admin.min.js
4 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
6 months ago
ai-layout.min.js
6 months ago
ai-layout.min.js.LICENSE.txt
10 months ago
ai-layout.strings.js
4 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
5 months ago
alert.42cc1d522ef5c60bf874.bundle.min.js
8 months ago
alert.fd509aa768e7b35a8e32.bundle.js
6 months ago
announcements-app.js
4 months ago
announcements-app.min.js
4 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
4 months 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
4 months ago
app.js
4 months ago
app.min.js
4 months ago
app.min.js.LICENSE.txt
10 months ago
app.strings.js
4 months ago
atomic-widgets-editor.js
4 months ago
atomic-widgets-editor.min.js
4 months ago
atomic-widgets-editor.min.js.LICENSE.txt
4 months ago
atomic-widgets-editor.strings.js
4 months ago
atomic-widgets-frontend-handler.js
4 months ago
atomic-widgets-frontend-handler.min.js
4 months ago
b09b262748a4be8417ce.bundle.js
5 months ago
b423d91809cf7e0cb8b0.bundle.js
4 months ago
b668f6906820570e60b5.bundle.min.js
5 months ago
b96d70044d0d67c2df19.bundle.min.js
8 months ago
b97ced1683f62f5686fa.bundle.min.js
5 months ago
ba292d36d983cead2a5b.bundle.js
5 months ago
bb708343060feb5c4a5d.bundle.min.js
5 months ago
beta-tester.js
8 months ago
beta-tester.min.js
8 months ago
beta-tester.strings.js
6 months ago
bf55a1adc050b89179ff.bundle.min.js
5 months ago
bff204c1ab0d15e0a69b.bundle.min.js
5 months ago
bfff0d754d68404bd5a6.bundle.js
5 months ago
c13d205fa26f8af1ce7c.bundle.js
6 months ago
c4d335a90ec9a10c603f.bundle.js
4 months ago
cf2707501445e5b44fbe.bundle.js
5 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
4 months ago
common-modules.min.js
4 months ago
common-modules.strings.js
6 months ago
common.js
4 months ago
common.min.js
4 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
d0d9578389b742468cb7.bundle.min.js
5 months ago
d42de03ef4a0f50e39ca.bundle.min.js
5 months ago
d52aa05c75af56327744.bundle.js
6 months ago
d67ddd6f08b08392c42f.bundle.js
6 months ago
daecdcc50702fd1d72f1.bundle.js
6 months ago
daedc6797eaad5c82711.bundle.min.js
8 months ago
db27207322ef9be952ee.bundle.js
5 months ago
dev-tools.js
8 months ago
dev-tools.min.js
8 months ago
dev-tools.strings.js
6 months ago
e-home-screen.js
4 months ago
e-home-screen.min.js
4 months ago
e-home-screen.strings.js
4 months ago
e-react-promotions.js
8 months ago
e-react-promotions.min.js
8 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
e2a127e2fb01b578d2ba.bundle.js
5 months ago
e393545679b12d012fba.bundle.js
5 months ago
e3b540e2c02813e75f38.bundle.min.js
5 months ago
e459c6c89c0c0899c850.bundle.js
6 months ago
e4d209bf3a704ff88e1a.bundle.js
4 months ago
e7d71f4e1d39edbc1fb6.bundle.js
5 months ago
e883e6638ef93bfd3204.bundle.js
6 months ago
editor-document.js
6 months ago
editor-document.min.js
8 months ago
editor-document.strings.js
4 months 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
4 months ago
editor-interactions.min.js
4 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
6 months ago
editor-modules.min.js
6 months ago
editor-modules.min.js.LICENSE.txt
10 months ago
editor-modules.strings.js
4 months 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
4 months ago
editor-one-sidebar-navigation.min.js
4 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
4 months ago
editor-one-top-bar.min.js
4 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
4 months ago
editor-v4-opt-in-alphachip.min.js
4 months ago
editor-v4-opt-in-alphachip.strings.js
5 months ago
editor-v4-opt-in.js
4 months ago
editor-v4-opt-in.min.js
4 months ago
editor-v4-opt-in.min.js.LICENSE.txt
6 months ago
editor-v4-opt-in.strings.js
5 months ago
editor-v4-welcome-opt-in.js
4 months ago
editor-v4-welcome-opt-in.min.js
4 months ago
editor-v4-welcome-opt-in.strings.js
5 months ago
editor.js
4 months ago
editor.min.js
4 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
5 months ago
element-manager-admin.min.js
5 months ago
element-manager-admin.min.js.LICENSE.txt
10 months ago
element-manager-admin.strings.js
5 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
fa64159422dec32bd185.bundle.js
5 months ago
floating-bars.740d06d17cea5cebdb61.bundle.min.js
8 months ago
floating-bars.a6e6a043444b62f64f82.bundle.js
6 months ago
floating-elements-modal.js
5 months ago
floating-elements-modal.min.js
5 months ago
floating-elements-modal.strings.js
6 months ago
frontend-modules.js
4 months ago
frontend-modules.min.js
4 months ago
frontend.js
8 months ago
frontend.min.js
8 months ago
gutenberg.js
8 months ago
gutenberg.min.js
8 months ago
gutenberg.strings.js
6 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
4 months ago
import-export-customization-admin.js
4 months ago
import-export-customization-admin.min.js
4 months ago
import-export-customization-admin.min.js.LICENSE.txt
7 months ago
import-export-customization-admin.strings.js
4 months ago
interactions.js
4 months ago
interactions.min.js
4 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.4d4a9d3b76f7410214c3.bundle.min.js
4 months ago
kit-library.9c4bbee79edf32c6fcb3.bundle.js
4 months ago
lightbox.a1f44406e887981f48c7.bundle.js
6 months ago
lightbox.d1799e507b570f6b0496.bundle.min.js
8 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
6 months ago
nested-elements.min.js
6 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
onboarding.31a5615a753ffac2c800.bundle.min.js
4 months ago
onboarding.63cdf72a450944ebd5f7.bundle.js
4 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
6 months ago
tabs-handler.js
6 months ago
tabs-handler.min.js
6 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.b5766aff4e92f7f6c661.bundle.min.js
6 months ago
text-path.b5766aff4e92f7f6c661.bundle.min.js.LICENSE.txt
6 months ago
text-path.eb787fc2b296f56e6e5f.bundle.js
6 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
4 months ago
webpack.runtime.min.js
4 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
tabs.40498fa771d612162c53.bundle.js
233 lines
| 1 | "use strict"; |
| 2 | (self["webpackChunkelementorFrontend"] = self["webpackChunkelementorFrontend"] || []).push([["tabs"],{ |
| 3 | |
| 4 | /***/ "../assets/dev/js/frontend/handlers/base-tabs.js": |
| 5 | /*!*******************************************************!*\ |
| 6 | !*** ../assets/dev/js/frontend/handlers/base-tabs.js ***! |
| 7 | \*******************************************************/ |
| 8 | /***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 9 | |
| 10 | |
| 11 | |
| 12 | Object.defineProperty(exports, "__esModule", ({ |
| 13 | value: true |
| 14 | })); |
| 15 | exports["default"] = void 0; |
| 16 | __webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 17 | __webpack_require__(/*! core-js/modules/esnext.iterator.filter.js */ "../node_modules/core-js/modules/esnext.iterator.filter.js"); |
| 18 | __webpack_require__(/*! core-js/modules/esnext.iterator.find.js */ "../node_modules/core-js/modules/esnext.iterator.find.js"); |
| 19 | class baseTabs extends elementorModules.frontend.handlers.Base { |
| 20 | getDefaultSettings() { |
| 21 | return { |
| 22 | selectors: { |
| 23 | tablist: '[role="tablist"]', |
| 24 | tabTitle: '.elementor-tab-title', |
| 25 | tabContent: '.elementor-tab-content' |
| 26 | }, |
| 27 | classes: { |
| 28 | active: 'elementor-active' |
| 29 | }, |
| 30 | showTabFn: 'show', |
| 31 | hideTabFn: 'hide', |
| 32 | toggleSelf: true, |
| 33 | hidePrevious: true, |
| 34 | autoExpand: true, |
| 35 | keyDirection: { |
| 36 | ArrowLeft: elementorFrontendConfig.is_rtl ? 1 : -1, |
| 37 | ArrowUp: -1, |
| 38 | ArrowRight: elementorFrontendConfig.is_rtl ? -1 : 1, |
| 39 | ArrowDown: 1 |
| 40 | } |
| 41 | }; |
| 42 | } |
| 43 | getDefaultElements() { |
| 44 | const selectors = this.getSettings('selectors'); |
| 45 | return { |
| 46 | $tabTitles: this.findElement(selectors.tabTitle), |
| 47 | $tabContents: this.findElement(selectors.tabContent) |
| 48 | }; |
| 49 | } |
| 50 | activateDefaultTab() { |
| 51 | const settings = this.getSettings(); |
| 52 | if (!settings.autoExpand || 'editor' === settings.autoExpand && !this.isEdit) { |
| 53 | return; |
| 54 | } |
| 55 | const defaultActiveTab = this.getEditSettings('activeItemIndex') || 1, |
| 56 | originalToggleMethods = { |
| 57 | showTabFn: settings.showTabFn, |
| 58 | hideTabFn: settings.hideTabFn |
| 59 | }; |
| 60 | |
| 61 | // Toggle tabs without animation to avoid jumping |
| 62 | this.setSettings({ |
| 63 | showTabFn: 'show', |
| 64 | hideTabFn: 'hide' |
| 65 | }); |
| 66 | this.changeActiveTab(defaultActiveTab); |
| 67 | |
| 68 | // Return back original toggle effects |
| 69 | this.setSettings(originalToggleMethods); |
| 70 | } |
| 71 | handleKeyboardNavigation(event) { |
| 72 | const tab = event.currentTarget, |
| 73 | $tabList = jQuery(tab.closest(this.getSettings('selectors').tablist)), |
| 74 | // eslint-disable-next-line @wordpress/no-unused-vars-before-return |
| 75 | $tabs = $tabList.find(this.getSettings('selectors').tabTitle), |
| 76 | isVertical = 'vertical' === $tabList.attr('aria-orientation'); |
| 77 | switch (event.key) { |
| 78 | case 'ArrowLeft': |
| 79 | case 'ArrowRight': |
| 80 | if (isVertical) { |
| 81 | return; |
| 82 | } |
| 83 | break; |
| 84 | case 'ArrowUp': |
| 85 | case 'ArrowDown': |
| 86 | if (!isVertical) { |
| 87 | return; |
| 88 | } |
| 89 | event.preventDefault(); |
| 90 | break; |
| 91 | case 'Home': |
| 92 | event.preventDefault(); |
| 93 | $tabs.first().trigger('focus'); |
| 94 | return; |
| 95 | case 'End': |
| 96 | event.preventDefault(); |
| 97 | $tabs.last().trigger('focus'); |
| 98 | return; |
| 99 | default: |
| 100 | return; |
| 101 | } |
| 102 | const tabIndex = tab.getAttribute('data-tab') - 1, |
| 103 | direction = this.getSettings('keyDirection')[event.key], |
| 104 | nextTab = $tabs[tabIndex + direction]; |
| 105 | if (nextTab) { |
| 106 | nextTab.focus(); |
| 107 | } else if (-1 === tabIndex + direction) { |
| 108 | $tabs.last().trigger('focus'); |
| 109 | } else { |
| 110 | $tabs.first().trigger('focus'); |
| 111 | } |
| 112 | } |
| 113 | deactivateActiveTab(tabIndex) { |
| 114 | const settings = this.getSettings(), |
| 115 | activeClass = settings.classes.active, |
| 116 | activeFilter = tabIndex ? '[data-tab="' + tabIndex + '"]' : '.' + activeClass, |
| 117 | $activeTitle = this.elements.$tabTitles.filter(activeFilter), |
| 118 | $activeContent = this.elements.$tabContents.filter(activeFilter); |
| 119 | $activeTitle.add($activeContent).removeClass(activeClass); |
| 120 | $activeTitle.attr({ |
| 121 | tabindex: '-1', |
| 122 | 'aria-selected': 'false', |
| 123 | 'aria-expanded': 'false' |
| 124 | }); |
| 125 | $activeContent[settings.hideTabFn](); |
| 126 | $activeContent.attr('hidden', 'hidden'); |
| 127 | } |
| 128 | activateTab(tabIndex) { |
| 129 | const settings = this.getSettings(), |
| 130 | activeClass = settings.classes.active, |
| 131 | $requestedTitle = this.elements.$tabTitles.filter('[data-tab="' + tabIndex + '"]'), |
| 132 | $requestedContent = this.elements.$tabContents.filter('[data-tab="' + tabIndex + '"]'), |
| 133 | animationDuration = 'show' === settings.showTabFn ? 0 : 400; |
| 134 | $requestedTitle.add($requestedContent).addClass(activeClass); |
| 135 | $requestedTitle.attr({ |
| 136 | tabindex: '0', |
| 137 | 'aria-selected': 'true', |
| 138 | 'aria-expanded': 'true' |
| 139 | }); |
| 140 | $requestedContent[settings.showTabFn](animationDuration, () => elementorFrontend.elements.$window.trigger('elementor-pro/motion-fx/recalc')); |
| 141 | $requestedContent.removeAttr('hidden'); |
| 142 | } |
| 143 | isActiveTab(tabIndex) { |
| 144 | return this.elements.$tabTitles.filter('[data-tab="' + tabIndex + '"]').hasClass(this.getSettings('classes.active')); |
| 145 | } |
| 146 | bindEvents() { |
| 147 | this.elements.$tabTitles.on({ |
| 148 | keydown: event => { |
| 149 | // Support for old markup that includes an `<a>` tag in the tab |
| 150 | if (jQuery(event.target).is('a') && `Enter` === event.key) { |
| 151 | event.preventDefault(); |
| 152 | } |
| 153 | |
| 154 | // We listen to keydowon event for these keys in order to prevent undesired page scrolling |
| 155 | if (['End', 'Home', 'ArrowUp', 'ArrowDown'].includes(event.key)) { |
| 156 | this.handleKeyboardNavigation(event); |
| 157 | } |
| 158 | }, |
| 159 | keyup: event => { |
| 160 | switch (event.code) { |
| 161 | case 'ArrowLeft': |
| 162 | case 'ArrowRight': |
| 163 | this.handleKeyboardNavigation(event); |
| 164 | break; |
| 165 | case 'Enter': |
| 166 | case 'Space': |
| 167 | event.preventDefault(); |
| 168 | this.changeActiveTab(event.currentTarget.getAttribute('data-tab')); |
| 169 | break; |
| 170 | } |
| 171 | }, |
| 172 | click: event => { |
| 173 | event.preventDefault(); |
| 174 | this.changeActiveTab(event.currentTarget.getAttribute('data-tab')); |
| 175 | } |
| 176 | }); |
| 177 | } |
| 178 | onInit(...args) { |
| 179 | super.onInit(...args); |
| 180 | this.activateDefaultTab(); |
| 181 | } |
| 182 | onEditSettingsChange(propertyName) { |
| 183 | if ('activeItemIndex' === propertyName) { |
| 184 | this.activateDefaultTab(); |
| 185 | } |
| 186 | } |
| 187 | changeActiveTab(tabIndex) { |
| 188 | const isActiveTab = this.isActiveTab(tabIndex), |
| 189 | settings = this.getSettings(); |
| 190 | if ((settings.toggleSelf || !isActiveTab) && settings.hidePrevious) { |
| 191 | this.deactivateActiveTab(); |
| 192 | } |
| 193 | if (!settings.hidePrevious && isActiveTab) { |
| 194 | this.deactivateActiveTab(tabIndex); |
| 195 | } |
| 196 | if (!isActiveTab) { |
| 197 | this.activateTab(tabIndex); |
| 198 | } |
| 199 | } |
| 200 | } |
| 201 | exports["default"] = baseTabs; |
| 202 | |
| 203 | /***/ }), |
| 204 | |
| 205 | /***/ "../assets/dev/js/frontend/handlers/tabs.js": |
| 206 | /*!**************************************************!*\ |
| 207 | !*** ../assets/dev/js/frontend/handlers/tabs.js ***! |
| 208 | \**************************************************/ |
| 209 | /***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 210 | |
| 211 | |
| 212 | |
| 213 | var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); |
| 214 | Object.defineProperty(exports, "__esModule", ({ |
| 215 | value: true |
| 216 | })); |
| 217 | exports["default"] = void 0; |
| 218 | var _baseTabs = _interopRequireDefault(__webpack_require__(/*! ./base-tabs */ "../assets/dev/js/frontend/handlers/base-tabs.js")); |
| 219 | class Tabs extends _baseTabs.default { |
| 220 | getDefaultSettings() { |
| 221 | const defaultSettings = super.getDefaultSettings(); |
| 222 | return { |
| 223 | ...defaultSettings, |
| 224 | toggleSelf: false |
| 225 | }; |
| 226 | } |
| 227 | } |
| 228 | exports["default"] = Tabs; |
| 229 | |
| 230 | /***/ }) |
| 231 | |
| 232 | }]); |
| 233 | //# sourceMappingURL=tabs.40498fa771d612162c53.bundle.js.map |