{"version":3,"file":"ComponentsBundle.min.js","sources":["../Components/Main.js"],"sourcesContent":["var axios;\r\nvar Swiper;\r\nvar WebSite;\r\n(function (WebSite) {\r\n var AFWSwiper = (function () {\r\n function AFWSwiper(element, swiperSettings) {\r\n if (swiperSettings === void 0) { swiperSettings = null; }\r\n this.SwiperSettings = null;\r\n var swpSetJson = swiperSettings || element.getAttribute('data-swiper-settings');\r\n if (swpSetJson) {\r\n this.SwiperSettings = JSON.parse(swpSetJson);\r\n }\r\n new Swiper(element, this.SwiperSettings);\r\n }\r\n return AFWSwiper;\r\n }());\r\n WebSite.AFWSwiper = AFWSwiper;\r\n var Main = (function () {\r\n function Main() {\r\n this.homepageMainSwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-homepageMainSwiper-init]')[0];\r\n var el = elements;\r\n var swiper = new Swiper(el, {\r\n slidesPerView: 1,\r\n centeredSlides: true,\r\n loop: true,\r\n autoplay: {\r\n delay: 3000,\r\n disableOnInteraction: false,\r\n },\r\n effect: 'fade',\r\n fadeEffect: {\r\n crossFade: true,\r\n },\r\n breakpoints: {\r\n 992: {\r\n slidesPerView: 1,\r\n },\r\n 768: {\r\n slidesPerView: 1,\r\n }\r\n },\r\n navigation: {\r\n nextEl: '.swiper-homepageMainSwiper-button-next',\r\n prevEl: '.swiper-homepageMainSwiper-button-prev'\r\n },\r\n });\r\n };\r\n this.relatedProductsSwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-relatedProductsSwiper-init]');\r\n elements.forEach(function (el) {\r\n var swiper = new Swiper(el, {\r\n slidesPerView: 3,\r\n observer: true,\r\n observeParents: true,\r\n spaceBetween: 20,\r\n loop: true,\r\n navigation: {\r\n nextEl: '.swiper-relatedProductsSwiper-button-next',\r\n prevEl: '.swiper-relatedProductsSwiper-button-prev'\r\n },\r\n });\r\n });\r\n };\r\n this.gallerySwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-gallerySwiper-init]')[0];\r\n var el = elements;\r\n var swiper = new Swiper(el, {\r\n slidesPerView: 1,\r\n spaceBetween: 30,\r\n centeredSlides: true,\r\n loop: true,\r\n loopAdditionalSlides: 2,\r\n pagination: {\r\n el: '.swiper-gallery-pagination',\r\n type: 'custom',\r\n renderCustom: function (swiper, current, total) {\r\n var text = \"\";\r\n for (var i = 1; i <= total; i++) {\r\n if (i == 1) {\r\n text += \"0\" + current + \"\";\r\n }\r\n var active = (current == i) ? \"active\" : \"\";\r\n text += \"\";\r\n if (i == total) {\r\n text += \"0\" + total + \"\";\r\n }\r\n }\r\n return text;\r\n }\r\n },\r\n on: {\r\n slideChange: function () {\r\n var childNum = $(\".swiper-gallery-pagination\").children().length - 2;\r\n var pagWidth = 550 / childNum;\r\n $(\".custom-pag\").css(\"width\", pagWidth + \"px\");\r\n }\r\n },\r\n breakpoints: {\r\n 992: {\r\n slidesPerView: 1,\r\n },\r\n 768: {\r\n slidesPerView: 1,\r\n }\r\n },\r\n navigation: {\r\n nextEl: '.swiper-gallerySwiper-button-next',\r\n prevEl: '.swiper-gallerySwiper-button-prev'\r\n },\r\n });\r\n };\r\n this.mobileContentSwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-mobileContentSwiper-init]')[0];\r\n var el = elements;\r\n var swiper = new Swiper(el, {\r\n slidesPerView: 1.07,\r\n spaceBetween: 10,\r\n loop: true,\r\n loopAdditionalSlides: 2,\r\n pagination: {\r\n el: '.swiper-mobile-content-pagination',\r\n type: 'custom',\r\n renderCustom: function (swiper, current, total) {\r\n var text = \"\";\r\n for (var i = 1; i <= total; i++) {\r\n if (i == 1) {\r\n text += \"0\" + current + \"\";\r\n }\r\n var active = (current == i) ? \"active\" : \"\";\r\n text += \"\";\r\n if (i == total) {\r\n text += \"0\" + total + \"\";\r\n }\r\n }\r\n return text;\r\n }\r\n },\r\n on: {\r\n slideChange: function () {\r\n var childNum = $(\".swiper-mobile-content-pagination\").children().length - 2;\r\n var pagWidth = 550 / childNum;\r\n $(\".custom-pag\").css(\"width\", pagWidth + \"px\");\r\n }\r\n },\r\n breakpoints: {\r\n 992: {\r\n slidesPerView: 1,\r\n },\r\n 768: {\r\n slidesPerView: 1,\r\n }\r\n },\r\n navigation: {\r\n nextEl: '.swiper-mobileContentSwiper-button-next',\r\n prevEl: '.swiper-mobileContentSwiper-button-prev'\r\n },\r\n });\r\n };\r\n this.mobileNewsContentSwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-mobileNewsContentSwiper-init]')[0];\r\n var el = elements;\r\n var swiper = new Swiper(el, {\r\n slidesPerView: 1.07,\r\n spaceBetween: 10,\r\n loop: true,\r\n loopAdditionalSlides: 2,\r\n pagination: {\r\n el: '.swiper-mobile-news-content-pagination',\r\n type: 'custom',\r\n renderCustom: function (swiper, current, total) {\r\n var text = \"\";\r\n for (var i = 1; i <= total; i++) {\r\n if (i == 1) {\r\n text += \"0\" + current + \"\";\r\n }\r\n var active = (current == i) ? \"active\" : \"\";\r\n text += \"\";\r\n if (i == total) {\r\n text += \"0\" + total + \"\";\r\n }\r\n }\r\n return text;\r\n }\r\n },\r\n on: {\r\n slideChange: function () {\r\n var childNum = $(\".swiper-mobile-news-content-pagination\").children().length - 2;\r\n var pagWidth = 550 / childNum;\r\n $(\".custom-pag\").css(\"width\", pagWidth + \"px\");\r\n }\r\n },\r\n breakpoints: {\r\n 992: {\r\n slidesPerView: 1,\r\n },\r\n 768: {\r\n slidesPerView: 1,\r\n }\r\n },\r\n navigation: {\r\n nextEl: '.swiper-mobileNewsContentSwiper-button-next',\r\n prevEl: '.swiper-mobileNewsContentSwiper-button-prev'\r\n },\r\n });\r\n };\r\n this.mobileBlogGallerySwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-mobileBlogGallerySwiper-init]')[0];\r\n var el = elements;\r\n var swiper = new Swiper(el, {\r\n slidesPerView: 1.14,\r\n centeredSlides: true,\r\n spaceBetween: 10,\r\n loop: true,\r\n loopAdditionalSlides: 2,\r\n pagination: {\r\n el: '.swiper-mobile-blog-gallery-pagination',\r\n type: 'custom',\r\n renderCustom: function (swiper, current, total) {\r\n var text = \"\";\r\n for (var i = 1; i <= total; i++) {\r\n if (i == 1) {\r\n text += \"0\" + current + \"\";\r\n }\r\n var active = (current == i) ? \"active\" : \"\";\r\n text += \"\";\r\n if (i == total) {\r\n text += \"0\" + total + \"\";\r\n }\r\n }\r\n return text;\r\n }\r\n },\r\n on: {\r\n slideChange: function () {\r\n var childNum = $(\".swiper-mobile-blog-gallery-pagination\").children().length - 2;\r\n var pagWidth = 550 / childNum;\r\n $(\".custom-pag\").css(\"width\", pagWidth + \"px\");\r\n }\r\n },\r\n breakpoints: {\r\n 992: {\r\n slidesPerView: 1,\r\n },\r\n 768: {\r\n slidesPerView: 1,\r\n }\r\n },\r\n navigation: {\r\n nextEl: '.swiper-mobileBlogGallerySwiper-button-next',\r\n prevEl: '.swiper-mobileBlogGallerySwiper-button-prev'\r\n },\r\n });\r\n };\r\n this.mobileWhyUsContentSwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-mobileWhyUsContentSwiper-init]')[0];\r\n var el = elements;\r\n var swiper = new Swiper(el, {\r\n slidesPerView: 1,\r\n spaceBetween: 10,\r\n loop: true,\r\n loopAdditionalSlides: 2,\r\n pagination: {\r\n el: '.swiper-mobile-why-us-content-pagination',\r\n type: 'custom',\r\n renderCustom: function (swiper, current, total) {\r\n var text = \"\";\r\n for (var i = 1; i <= total; i++) {\r\n if (i == 1) {\r\n text += \"0\" + current + \"\";\r\n }\r\n var active = (current == i) ? \"active\" : \"\";\r\n text += \"\";\r\n if (i == total) {\r\n text += \"0\" + total + \"\";\r\n }\r\n }\r\n return text;\r\n }\r\n },\r\n on: {\r\n slideChange: function () {\r\n var childNum = $(\".swiper-mobile-why-us-content-pagination\").children().length - 2;\r\n var pagWidth = 550 / childNum;\r\n $(\".custom-pag\").css(\"width\", pagWidth + \"px\");\r\n }\r\n },\r\n breakpoints: {\r\n 992: {\r\n slidesPerView: 1,\r\n },\r\n 768: {\r\n slidesPerView: 1,\r\n }\r\n },\r\n navigation: {\r\n nextEl: '.swiper-mobileWhyUsContentSwiper-button-next',\r\n prevEl: '.swiper-mobileWhyUsContentSwiper-button-prev'\r\n },\r\n });\r\n };\r\n this.mobileCalendarContentSwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-mobileCalendarContentSwiper-init]')[0];\r\n var el = elements;\r\n var swiper = new Swiper(el, {\r\n slidesPerView: 1,\r\n spaceBetween: 10,\r\n centeredSlides: true,\r\n pagination: {\r\n el: '.swiper-mobile-calendar-content-pagination',\r\n type: 'custom',\r\n renderCustom: function (swiper, current, total) {\r\n var text = \"\";\r\n for (var i = 1; i <= total; i++) {\r\n if (i == 1) {\r\n text += \"0\" + current + \"\";\r\n }\r\n var active = (current == i) ? \"active\" : \"\";\r\n text += \"\";\r\n if (i == total) {\r\n text += \"0\" + total + \"\";\r\n }\r\n }\r\n return text;\r\n }\r\n },\r\n breakpoints: {\r\n 992: {\r\n slidesPerView: 1,\r\n },\r\n 768: {\r\n slidesPerView: 1,\r\n }\r\n },\r\n navigation: {\r\n nextEl: '.swiper-mobileCalendarContentSwiper-button-next',\r\n prevEl: '.swiper-mobileCalendarContentSwiper-button-prev'\r\n },\r\n });\r\n };\r\n this.mobileRelatedProductsContentSwiper = function () {\r\n var elements = document.querySelectorAll('[data-swiper-mobileRelatedProductsContentSwiper-init]');\r\n elements.forEach(function (el) {\r\n var swiper = new Swiper(el, {\r\n observer: true,\r\n observeParents: true,\r\n slidesPerView: 2,\r\n spaceBetween: 10,\r\n loop: true,\r\n loopAdditionalSlides: 2,\r\n initialSlide: 0,\r\n pagination: {\r\n el: '.swiper-mobile-related-products-content-pagination',\r\n type: 'custom',\r\n renderCustom: function (swiper, current, total) {\r\n console.log(swiper, current, total);\r\n var text = \"\";\r\n for (var i = 1; i <= total; i++) {\r\n if (i == 1) {\r\n text += \"0\" + current + \"\";\r\n text += \"
\" + Dictionary.Products + \"
\";\r\n products.forEach(function (product) {\r\n html += \"\" + (product.subTitle != null ? product.subTitle : '') + \"
\\n\" + product.title + \"
\" + Dictionary.Blogs + \"
\";\r\n blogposts.forEach(function (blogpost) {\r\n html += \"\" + blogpost.createDate + \"
\" + blogpost.title + \"
\" + Dictionary.News + \"
\";\r\n articles.forEach(function (article) {\r\n html += \"\" + article.createDate + \"
\" + article.title + \"