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AA4B,CAAC;AAE/CoB,UAAU,CAACF,IAAI,CAAC,CAAC;AAEjBG,SAAS,CAAClB,EAAE,CAAC,eAAe,EAAE,UAAUC,KAAK,EAAE;EAC7C,IAAIA,KAAK,CAACC,IAAI,KAAK,OAAO,IAAID,KAAK,CAACE,GAAG,KAAK,OAAO,IAAIF,KAAK,CAACE,GAAG,KAAK,GAAG,EAAE;IACxEF,KAAK,CAACG,cAAc,CAAC,CAAC;IACtB,IAAMe,YAAY,GAAGtB,6CAAC,CAAC,IAAI,CAAC,CAACY,OAAO,CAAC,eAAe,CAAC;IACrD,IAAMW,cAAc,GAAGD,YAAY,CAACT,IAAI,CAAC,uBAAuB,CAAC;IACjE,IAAMW,MAAM,GAAGF,YAAY,CAACd,QAAQ,CAAC,MAAM,CAAC;IAE5C,IAAIgB,MAAM,EAAE;MACVF,YAAY,CAACP,WAAW,CAAC,MAAM,CAAC;MAChCQ,cAAc,CAACT,OAAO,CAAC,CAAC;MACxBd,6CAAC,CAAC,IAAI,CAAC,CAACU,IAAI,CAAC,eAAe,EAAE,OAAO,CAAC;MACtCa,cAAc,CAACb,IAAI,CAAC,QAAQ,EAAE,QAAQ,CAAC;IACzC,CAAC,MAAM;MACLY,YAAY,CAACL,QAAQ,CAAC,MAAM,CAAC;MAC7BM,cAAc,CAACP,SAAS,CAAC,CAAC;MAC1BhB,6CAAC,CAAC,IAAI,CAAC,CAACU,IAAI,CAAC,eAAe,EAAE,MAAM,CAAC;MACrCa,cAAc,CAACE,UAAU,CAAC,QAAQ,CAAC;IACrC;EACF;AACF,CAAC,CAAC","sources":["webpack://skeleton-theme/./blocks/tabs/tabs.js"],"sourcesContent":["import $ from 'jquery';\n\nconst navItemMobile = $('.tab-content__nav-item'),\n navItemDesktop = $('.tabs-nav__item');\n\nnavItemMobile.on('click keydown', function (event) {\n if (event.type === 'click' || event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n if (!$(this).hasClass('active')) {\n let tabId = $(this).attr('data-tab');\n let thisTabParent = $(this).closest('.tabs-wrapper');\n thisTabParent.find('.tab-content__item').slideUp().removeClass('active');\n thisTabParent\n .find('.tab-content__item[data-tab=\"' + tabId + '\"]')\n .slideDown()\n .addClass('active');\n thisTabParent.find('.tab-content__nav-item').removeClass('active');\n thisTabParent.find('.tabs-nav__item').removeClass('active');\n thisTabParent\n .find('.tabs-nav__item[data-tab=\"' + tabId + '\"]')\n .addClass('active');\n thisTabParent\n .find('.tab-content__nav-item[data-tab=\"' + tabId + '\"]')\n .addClass('active');\n }\n }\n});\n\nnavItemDesktop.on('click keydown', function (event) {\n if (event.type === 'click' || event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n if (!$(this).hasClass('active')) {\n let tabId = $(this).attr('data-tab');\n let thisTabParent = $(this).closest('.tabs-wrapper');\n thisTabParent.find('.tab-content__item').removeClass('active').hide();\n thisTabParent\n .find('.tab-content__item[data-tab=\"' + tabId + '\"]')\n .addClass('active')\n .show();\n thisTabParent.find('.tab-content__nav-item').removeClass('active');\n thisTabParent.find('.tabs-nav__item').removeClass('active');\n thisTabParent\n .find('.tabs-nav__item[data-tab=\"' + tabId + '\"]')\n .addClass('active');\n thisTabParent\n .find('.tab-content__nav-item[data-tab=\"' + tabId + '\"]')\n .addClass('active');\n }\n }\n});\n\nlet itemHidden = $('.tab-faq-item__hidden');\nlet itemShown = $('.tab-faq-item .shown-title');\n\nitemHidden.hide();\n\nitemShown.on('click keydown', function (event) {\n if (event.type === 'click' || event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n const $currentItem = $(this).closest('.tab-faq-item');\n const $currentHidden = $currentItem.find('.tab-faq-item__hidden');\n const isOpen = $currentItem.hasClass('open');\n\n if (isOpen) {\n $currentItem.removeClass('open');\n $currentHidden.slideUp();\n $(this).attr('aria-expanded', 'false');\n $currentHidden.attr('hidden', 'hidden');\n } else {\n $currentItem.addClass('open');\n $currentHidden.slideDown();\n $(this).attr('aria-expanded', 'true');\n $currentHidden.removeAttr('hidden');\n }\n }\n});\n"],"names":["$","navItemMobile","navItemDesktop","on","event","type","key","preventDefault","hasClass","tabId","attr","thisTabParent","closest","find","slideUp","removeClass","slideDown","addClass","hide","show","itemHidden","itemShown","$currentItem","$currentHidden","isOpen","removeAttr"],"sourceRoot":""}