main.min.js 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443
  1. var animEndEv = "webkitAnimationEnd animationend";
  2. function notify(e, t, a) {
  3. $.growl({icon: "", title: e, message: t, url: ""}, {
  4. element: "body",
  5. type: a,
  6. allow_dismiss: !0,
  7. placement: {from: "bottom", align: "center"},
  8. offset: {x: 20, y: 85},
  9. spacing: 10,
  10. z_index: 99999,
  11. delay: 3000,
  12. timer: 3e3,
  13. url_target: "_blank",
  14. mouse_over: !1,
  15. animate: {enter: "", exit: ""},
  16. icon_type: "class",
  17. template: '<div data-growl="container" class="alert alert-dismissible" role="alert"><span data-growl="icon"></span><h4 class="heading-6 alert-heading strong-600" data-growl="title">Well done!</h4><p data-growl="message"></p><button type="button" class="close" data-growl="dismiss"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button></div>'
  18. })
  19. }
  20. $(window).on("load resize", function () {
  21. $(".background-image-holder").length && $(".background-image-holder").each(function () {
  22. var e, t = $(this);
  23. if ("fullscreen" == t.data("holder-type")) {
  24. if (t.attr("data-holder-offset")) {
  25. if (t.data("holder-offset")) {
  26. var a = $("body").find(t.data("holder-offset")).height();
  27. e = $(window).height() - a
  28. }
  29. } else e = $(window).height();
  30. $(window).width() > 991 ? $(".background-image-holder").css({height: e + "px"}) : $(".background-image-holder").css({height: "auto"})
  31. }
  32. t.imagesLoaded().done(function (e) {
  33. t.find(".animated").each(function () {
  34. var e = $(this);
  35. if (!e.hasClass("animation-ended")) {
  36. var t = e.data("animation-in"), a = (e.data("animation-out"), e.data("animation-delay"));
  37. setTimeout(function () {
  38. e.addClass("animation-ended " + t, 100).on(animEndEv, function () {
  39. e.removeClass(t)
  40. })
  41. }, a)
  42. }
  43. })
  44. })
  45. }), $(".same-height").length > 0 && $(".same-height").each(function (e, t) {
  46. var a = $(this), n = a.data("same-height");
  47. setTimeout(function () {
  48. var e = $("body").find(n).height();
  49. $(window).width() > 991 ? a.css({height: e + "px"}) : a.css({height: "auto"})
  50. }, 300)
  51. }), $(".swiper-js-container").length > 0 && $(".swiper-js-container").each(function (e, t) {
  52. var a = $(t), n = (u = a.find(".swiper-container")).data("swiper-effect"), i = u.data("swiper-xs-items"),
  53. o = u.data("swiper-sm-items"), s = u.data("swiper-md-items"), d = u.data("swiper-items"),
  54. r = u.data("swiper-xs-space-between"), l = u.data("swiper-sm-space-between"),
  55. c = u.data("swiper-md-space-between"), p = u.data("swiper-space-between");
  56. i = i || d, o = o || d, s = s || d, d = d || 1, r = r || 0, l = l || 0, c = c || 0, p = p || 0;
  57. var u = new Swiper(u, {
  58. pagination: a.find(".swiper-pagination"),
  59. nextButton: a.find(".swiper-button-next"),
  60. prevButton: a.find(".swiper-button-prev"),
  61. slidesPerView: d,
  62. spaceBetween: p,
  63. autoplay: u.data("swiper-autoplay"),
  64. autoHeight: u.data("swiper-autoheight"),
  65. effect: n,
  66. speed: 800,
  67. paginationClickable: !0,
  68. direction: "horizontal",
  69. preventClicks: !0,
  70. preventClicksPropagation: !0,
  71. observer: !0,
  72. observeParents: !0,
  73. breakpoints: {
  74. 460: {slidesPerView: i, spaceBetweenSlides: r},
  75. 767: {slidesPerView: o, spaceBetweenSlides: l},
  76. 991: {slidesPerView: s, spaceBetweenSlides: c},
  77. 1100: {slidesPerView: d, spaceBetweenSlides: p}
  78. },
  79. onInit: function (e) {
  80. $(e.slides[e.activeIndex]).find(".animated").each(function () {
  81. var e = $(this);
  82. if (!e.hasClass("animation-ended")) {
  83. var t = e.data("animation-in"), a = (e.data("animation-out"), e.data("animation-delay"));
  84. setTimeout(function () {
  85. e.addClass("animation-ended " + t, 100).on(animEndEv, function () {
  86. e.removeClass(t)
  87. })
  88. }, a)
  89. }
  90. })
  91. },
  92. onSlideChangeStart: function (e) {
  93. $(e.slides[e.activeIndex]).find(".animated").each(function () {
  94. var e = $(this);
  95. if (!e.hasClass("animation-ended")) {
  96. var t = e.data("animation-in"), a = (e.data("animation-out"), e.data("animation-delay"));
  97. setTimeout(function () {
  98. e.addClass("animation-ended " + t, 100).on(animEndEv, function () {
  99. e.removeClass(t)
  100. })
  101. }, a)
  102. }
  103. })
  104. },
  105. onSlideChangeEnd: function (e) {
  106. $(e.slides[e.previousIndex]).find(".animated").each(function () {
  107. var e = $(this), t = e.data("animation-onetime");
  108. t && 0 != t || e.removeClass("animation-ended")
  109. })
  110. }
  111. })
  112. }), $(window).width() > 0 && $("[data-toggle='headroom']").length > 0 && $("[data-toggle='headroom']").headroom({
  113. offset: 0,
  114. tolerance: {up: 40, down: 5},
  115. classes: {
  116. initial: "headroom",
  117. pinned: "headroom--pinned",
  118. unpinned: "headroom--unpinned",
  119. top: "headroom--top",
  120. notTop: "fixed-top",
  121. bottom: "headroom--bottom"
  122. },
  123. onPin: function () {
  124. if ($(window).offset.top > 0) {
  125. var e = $("[data-toggle='headroom']").height();
  126. $("body").css({"padding-top": e + "px"})
  127. } else $("body").css({"padding-top": 0})
  128. },
  129. onUnpin: function () {
  130. var e = $("[data-toggle='headroom']").height();
  131. $("body").css({"padding-top": e + "px"})
  132. },
  133. onTop: function () {
  134. $("body").css({"padding-top": 0})
  135. },
  136. onBottom: function () {
  137. }
  138. })
  139. }), $(document).ready(function () {
  140. if ($('.dropdown-menu .dropdown-submenu [data-toggle="dropdown"]').on("click", function (e) {
  141. $(this).next().hasClass("show") || $(this).parents(".dropdown-menu").first().find(".show").removeClass("show");
  142. var t = $(this).next(".dropdown-menu");
  143. return t.toggleClass("show"), t.parent().toggleClass("show"), $(this).parents(".nav-item.dropdown.show").on("hidden.bs.dropdown", function (e) {
  144. $(".dropdown-submenu .show").removeClass("show")
  145. }), !1
  146. }), $(".navbar .dropdown-menu").on("click", function (e) {
  147. e.stopPropagation()
  148. }), $(".navbar-onepage .nav-link").on("click", function (e) {
  149. var t = $(this);
  150. $("html, body").stop().animate({scrollTop: $(t.attr("href")).offset().top}, 1500, "easeInOutExpo"), e.preventDefault()
  151. }), $(".hamburger-js")[0] && $(".hamburger-js").each(function () {
  152. var e = $(this);
  153. e.on("click", function (t) {
  154. e.toggleClass("is-active")
  155. })
  156. }), $("[data-footer-reveal]").length && $("[data-footer-reveal]").footerReveal({
  157. shadow: !1,
  158. zIndex: -101
  159. }), $(".adaptive-background").length && $.adaptiveBackground.run({
  160. parent: ".adaptive-background",
  161. normalizeTextColor: !0,
  162. exclude: ["rgb(0,0,0)", "rgba(255,255,255)"]
  163. }), $(".btn-number").click(function (e) {
  164. e.preventDefault(), fieldName = $(this).attr("data-field"), type = $(this).attr("data-type");
  165. var t = $("input[name='" + fieldName + "']"), a = parseInt(t.val());
  166. isNaN(a) ? t.val(0) : "minus" == type ? (a > t.attr("min") && t.val(a - 1).change(), parseInt(t.val()) == t.attr("min") && $(this).attr("disabled", !0)) : "plus" == type && (a < t.attr("max") && t.val(a + 1).change(), parseInt(t.val()) == t.attr("max") && $(this).attr("disabled", !0))
  167. }), $(".input-number").focusin(function () {
  168. $(this).data("oldValue", $(this).val())
  169. }), $(".input-number").change(function () {
  170. minValue = parseInt($(this).attr("min")), maxValue = parseInt($(this).attr("max")), valueCurrent = parseInt($(this).val()), name = $(this).attr("name"), valueCurrent >= minValue ? $(".btn-number[data-type='minus'][data-field='" + name + "']").removeAttr("disabled") : (alert("Sorry, the minimum value was reached"), $(this).val($(this).data("oldValue"))), valueCurrent <= maxValue ? $(".btn-number[data-type='plus'][data-field='" + name + "']").removeAttr("disabled") : (alert("Sorry, the maximum value was reached"), $(this).val($(this).data("oldValue")))
  171. }), $(".input-number").keydown(function (e) {
  172. -1 !== $.inArray(e.keyCode, [46, 8, 9, 27, 13, 190]) || 65 == e.keyCode && !0 === e.ctrlKey || e.keyCode >= 35 && e.keyCode <= 39 || (e.shiftKey || e.keyCode < 48 || e.keyCode > 57) && (e.keyCode < 96 || e.keyCode > 105) && e.preventDefault()
  173. }), $(".textarea-autogrow")[0] && autosize($(".textarea-autogrow")), $(".has-floating-label .form-control").on("focus blur", function (e) {
  174. $(this).parents(".form-group").toggleClass("focused", "focus" === e.type || this.value.length > 0)
  175. }).trigger("blur"), $(".selectpicker").each(function (e, t) {
  176. $(".selectpicker").select2({})
  177. }), $(".datepicker")[0] && $(".datepicker").each(function () {
  178. var e = $(this);
  179. e.flatpickr({
  180. noCalendar: !!e.data("datepicker-no-calendar") && e.data("datepicker-no-calendar"),
  181. enableTime: !!e.data("datepicker-enable-time") && e.data("datepicker-enable-time"),
  182. inline: !!e.data("datepicker-inline") && e.data("datepicker-inline"),
  183. allowInput: !e.data("datepicker-allow-input") || e.data("datepicker-allow-input"),
  184. mode: e.data("datepicker-mode") ? e.data("datepicker-mode") : "single",
  185. static: !0,
  186. inline: !!e.data("datepicker-inline") && e.data("datepicker-inline"),
  187. nextArrow: '<i class="ion-ios-arrow-right" />',
  188. prevArrow: '<i class="ion-ios-arrow-left" />'
  189. })
  190. }), $(".custom-input-file").each(function () {
  191. var e = $(this), t = e.next("label"), a = t.html();
  192. e.on("change", function (e) {
  193. var n = "";
  194. this.files && this.files.length > 1 ? n = (this.getAttribute("data-multiple-caption") || "").replace("{count}", this.files.length) : e.target.value && (n = e.target.value.split("\\").pop()), n ? t.find("span").html(n) : t.html(a)
  195. }), e.on("focus", function () {
  196. e.addClass("has-focus")
  197. }).on("blur", function () {
  198. e.removeClass("has-focus")
  199. })
  200. }), $(".input-slider-container")[0] && $(".input-slider-container").each(function () {
  201. var e = $(this).find(".input-slider"), t = e.attr("id"), a = e.data("range-value-min"),
  202. n = e.data("range-value-max"), i = $(this).find(".range-slider-value"), o = i.attr("id"),
  203. s = i.data("range-value-low"), d = document.getElementById(t), r = document.getElementById(o);
  204. noUiSlider.create(d, {
  205. start: [parseInt(s)],
  206. range: {min: [parseInt(a)], max: [parseInt(n)]}
  207. }), d.noUiSlider.on("update", function (e, t) {
  208. r.textContent = e[t]
  209. })
  210. }), $("#input-slider-range")[0]) {
  211. var e = document.getElementById("input-slider-range"),
  212. t = document.getElementById("input-slider-range-value-low"),
  213. a = document.getElementById("input-slider-range-value-high"), n = [t, a];
  214. noUiSlider.create(e, {
  215. start: [parseInt(t.getAttribute("data-range-value-low")), parseInt(a.getAttribute("data-range-value-high"))],
  216. connect: !0,
  217. range: {
  218. min: parseInt(e.getAttribute("data-range-value-min")),
  219. max: parseInt(e.getAttribute("data-range-value-max"))
  220. }
  221. }), e.noUiSlider.on("update", function (e, t) {
  222. n[t].textContent = e[t]
  223. })
  224. }
  225. $(".card-flip")[0] && $(".card-flip-container").imagesLoaded(function () {
  226. $(".card-flip").each(function () {
  227. $this = $(this), $this.flip({
  228. front: ".card-front",
  229. back: ".card-back",
  230. forceHeight: !0,
  231. trigger: $this.data("flip-trigger") ? $this.data("flip-trigger") : "hover",
  232. reverse: !!$this.data("flip-reverse") && $this.data("flip-reverse")
  233. })
  234. })
  235. }), $(".carousel").carousel({
  236. interval: 5e3,
  237. pause: "hover"
  238. }), $(".scroll-me, [data-scroll-to]").on("click", function (e) {
  239. var t = $(this).data("scroll-to"), a = $(this).data("scroll-to-offset") ? $(this).data("scroll-to-offset") : 0;
  240. $("html, body").stop(!0, !0).animate({scrollTop: $(t).offset().top - a}, 600), e.preventDefault()
  241. });
  242. var i = $(".back-to-top");
  243. if ($(window).scroll(function () {
  244. $(this).scrollTop() > 300 ? i.addClass("back-to-top-is-visible") : i.removeClass("back-to-top-is-visible cd-fade-out"), $(this).scrollTop() > 1200 && i.addClass("back-to-top-fade-out")
  245. }), i.on("click", function (e) {
  246. e.preventDefault(), $("body, html").animate({scrollTop: 0}, 700)
  247. }), $('[data-toggle="light-gallery"]').length > 0 && $('[data-toggle="light-gallery"]').lightGallery({selector: "this"}), $(".light-gallery").length > 0 && $(".light-gallery").each(function () {
  248. $(this).lightGallery({selector: ".item", thumbnail: !0})
  249. }), $('[data-stick-in-parent="true"]').length && $('[data-stick-in-parent="true"]').stick_in_parent(), $(".masonry-container").length && $(".masonry-container").each(function (e, t) {
  250. var a = $(t), n = a.find(".masonry").imagesLoaded(function () {
  251. var e = a.find(".masonry-filter-menu").find(".default"), t = e.data("filter");
  252. void 0 != t && "" != t && ("*" != t && (t = "." + t), e.addClass("active")), n.isotope({
  253. itemSelector: ".masonry-item",
  254. filter: t
  255. })
  256. });
  257. a.find(".masonry-filter-menu").on("click", "a", function () {
  258. var e = $(this).attr("data-filter");
  259. e = "*" == e ? "" : "." + e, n.isotope({filter: e})
  260. })
  261. }), $(".masonry-container").length && $(".masonry-container").each(function (e, t) {
  262. var a = $(t);
  263. a.on("click", "a", function () {
  264. a.find(".active").removeClass("active"), $(this).addClass("active")
  265. })
  266. }), $(".product-swiper-container").length > 0 && $(".product-swiper-container").each(function (e, t) {
  267. $(this).addClass("s-" + e), $(this).find(".swiper-pagination").addClass("sp-" + e), $(".s-" + e).swiper({
  268. speed: 400,
  269. loop: !0,
  270. grabCursor: !0,
  271. pagination: ".sp-" + e,
  272. paginationClickable: !0,
  273. centeredSlides: !1,
  274. preloadImages: !1,
  275. lazyLoading: !0,
  276. observer: !0,
  277. observerParents: !0
  278. })
  279. }), $(".swiper-container-centered").length > 0 && $(".swiper-container-centered").each(function () {
  280. new Swiper(".swiper-container-centered", {
  281. pagination: ".swiper-pagination",
  282. slidesPerView: "auto",
  283. centeredSlides: !0,
  284. paginationClickable: !0,
  285. spaceBetween: 30,
  286. initialSlide: 1,
  287. breakpoints: {
  288. 768: {slidesPerView: 1, spaceBetweenSlides: 0},
  289. 991: {slidesPerView: 2, spaceBetweenSlides: 0}
  290. }
  291. })
  292. }), $(".swiper-container-coverflow").length > 0 && $(".swiper-container-coverflow").each(function () {
  293. new Swiper($(this), {
  294. pagination: $(this).find(".swiper-pagination"),
  295. effect: "coverflow",
  296. grabCursor: !0,
  297. centeredSlides: !0,
  298. initialSlide: $(this).data("swiper-initial-slide"),
  299. slidesPerView: $(this).data("swiper-items"),
  300. coverflow: {rotate: 0, stretch: 0, depth: 300, modifier: 1, slideShadows: !0},
  301. breakpoints: {
  302. 576: {slidesPerView: 1, spaceBetweenSlides: 0, initialSlide: 0},
  303. 768: {slidesPerView: 2, spaceBetweenSlides: 0},
  304. 992: {slidesPerView: 3, spaceBetweenSlides: 0, initialSlide: 2}
  305. }
  306. })
  307. }), $(".paraxify").length > 0) paraxify(".paraxify", {speed: 1, boost: 1});
  308. $(".milestone-count").length > 0 && $(".milestone-count").viewportChecker({
  309. callbackFunction: function (e, t) {
  310. setTimeout(function () {
  311. $(".milestone-count").countTo({
  312. formatter: function (e, t) {
  313. return e.toFixed(t.decimals)
  314. }, onUpdate: function (e) {
  315. console.debug(this)
  316. }, onComplete: function (e) {
  317. console.debug(this)
  318. }
  319. })
  320. }, 500)
  321. }
  322. }), $(".type-this").length > 0 && $(".type-this").each(function () {
  323. var e = $(this).attr("id"), t = $(this).data("type-this");
  324. t = t.split(",");
  325. new Typed("#" + e, {strings: t, typeSpeed: 100, backSpeed: 70, loop: !0})
  326. }), $(".countdown").length > 0 && $(".countdown").each(function () {
  327. var e = $(this), t = e.data("countdown-date");
  328. e.countdown(t).on("update.countdown", function (e) {
  329. $(this).html(e.strftime('<div class="countdown-item"><span class="countdown-digit">%-D</span><span class="countdown-label countdown-days">day%!d</span></div><div class="countdown-item"><span class="countdown-digit">%H</span><span class="countdown-separator">:</span><span class="countdown-label">hr</span></div><div class="countdown-item"><span class="countdown-digit">%M</span><span class="countdown-separator">:</span><span class="countdown-label">min</span></div><div class="countdown-item"><span class="countdown-digit">%S</span><span class="countdown-label">sec</span></div>'))
  330. })
  331. }), $("#btnToggleOptionalFilters").click(function () {
  332. $(this).data("animate-in"), $(this).data("animate-out");
  333. return $(this).hasClass("opened") ? ($(".hidden-form-filters").addClass("hide"), $(this).removeClass("opened")) : ($(this).addClass("opened"), $(".hidden-form-filters").removeClass("hide")), !1
  334. });
  335. var o = $(".rating span.star");
  336. (o.hover(function () {
  337. $(this).addClass("over"), $(this).prevAll().addClass("over")
  338. }, function () {
  339. $(this).removeClass("over"), $(this).prevAll().removeClass("over")
  340. }), o.click(function () {
  341. $(this).parent().children(".star").removeClass("voted"), $(this).prevAll().addClass("voted"), $(this).addClass("voted")
  342. }), $('[data-toggle="tooltip"]').tooltip({html: !0}), $('[data-toggle="popover"]').popover({
  343. placement: $(this).data("placement"),
  344. html: !0
  345. }), $('[data-toggle="global-search"]').click(function () {
  346. var e = $(".global-search"), t = 0;
  347. e.hasClass("in") ? (e.addClass("fadeOut"), e.one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", function () {
  348. e.removeClass("animated fadeOut"), e.removeClass("in"), setTimeout(function () {
  349. $(".navbar").removeClass("global-search-active hide")
  350. }, t)
  351. })) : (e.hasClass("global-search-fullscreen") || e.hasClass("global-search-overlay") ? e.hasClass("global-search-overlay") && $(".navbar").addClass("hide") : ($(".navbar").addClass("global-search-active"), t = 200), setTimeout(function () {
  352. e.addClass("in")
  353. }, t), setTimeout(function () {
  354. e.addClass("animated fadeIn"), e.one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", function () {
  355. e.removeClass("fadeIn")
  356. })
  357. }, 2.5 * t))
  358. }), $(".morphext").length > 0 && $(".morphext").Morphext({
  359. animation: "fadeIn",
  360. separator: ";",
  361. speed: "3000",
  362. complete: function () {
  363. }
  364. }), $(".animate-on-scroll").length > 0 && (wow = new WOW({
  365. boxClass: "animate-on-scroll",
  366. animateClass: "animated",
  367. offset: 100,
  368. mobile: !1,
  369. live: !0
  370. }), wow.init()), $(".accordion--style-1 .collapse, .accordion--style-2 .collapse").on("show.bs.collapse", function () {
  371. $(this).parent().find(".fa-chevron-right").removeClass("fa-chevron-right").addClass("fa-chevron-down")
  372. }).on("hide.bs.collapse", function () {
  373. $(this).parent().find(".fa-chevron-down").removeClass("fa-chevron-down").addClass("fa-chevron-right")
  374. }), $(".spinner .btn:first-of-type").on("click", function () {
  375. $(".spinner input").val(parseInt($(".spinner input").val(), 10) + 1)
  376. }), $(".spinner .btn:last-of-type").on("click", function () {
  377. $(".spinner input").val(parseInt($(".spinner input").val(), 10) - 1)
  378. }), $(".product").on("mouseenter", function () {
  379. if ($(this).find(".product-actions--a").length > 0 && !$(this).find(".product-actions--a").hasClass("in")) {
  380. var e = $(this).find(".product-actions--a"), t = e.data("animation-in");
  381. e.addClass("in animated " + t), e.one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", function () {
  382. e.removeClass("animated " + t)
  383. })
  384. }
  385. }), $(".product").on("mouseleave", function () {
  386. if ($(this).find(".product-actions--a").length > 0 && $(this).find(".product-actions--a").hasClass("in")) {
  387. var e = $(this).find(".product-actions--a"), t = e.data("animation-out");
  388. e.addClass("animated " + t), e.one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", function () {
  389. e.removeClass("in animated " + t)
  390. })
  391. }
  392. }), $("#btn_advanced_search_open").click(function () {
  393. return $(".advanced-search-hidden").hasClass("in") ? $(".advanced-search-hidden").removeClass("in") : $(".advanced-search-hidden").addClass("in"), !1
  394. }), $(".instafeed").length > 0 && $(".instafeed").each(function () {
  395. var e = $(this), t = e.attr("id"), a = e.data("user-id"), n = e.data("limit"), i = e.data("col"),
  396. o = e.data("classes") ? e.data("classes") : "", s = e.data("lightbox") ? " data-fancybox " : "";
  397. new Instafeed({
  398. target: t,
  399. clientId: "c81e735d834e4960ab5bfdc89fff7b7a",
  400. accessToken: "4168279954.c81e735.bd435dd21a344208ad569b028b372088",
  401. get: "user",
  402. userId: a,
  403. limit: n,
  404. resolution: "thumbnail",
  405. template: '<div class="col-sm-' + i + ' col-6"><a href="{{link}}"' + s + '><img src="{{image}}" class="img-fluid ' + o + '" /></a></div>'
  406. }).run()
  407. }), $('[data-toggle="validation"]')[0] && $('[data-toggle="validation"]').each(function () {
  408. var e = $(this), t = document.getElementById(e.attr("id"));
  409. t.addEventListener("submit", function (e) {
  410. !1 === t.checkValidity() && (e.preventDefault(), e.stopPropagation()), t.classList.add("was-validated")
  411. }, !1)
  412. }), $("#form_contact").length > 0 && $("#form_contact").on("submit", function (e) {
  413. var t = $(this), a = t.find('button[type="submit"]').text();
  414. if (!e.isDefaultPrevented()) {
  415. var n = t.serialize(), i = $.ajax({type: "POST", url: t.data("action"), data: n, dataType: "json"});
  416. return t.find('button[type="submit"]').text("Sending..."), i.done(function (e, n) {
  417. var i = e.status;
  418. notify(e.notify_title, e.notify_message, e.notify_type), "success" == i && (t.find(".btn-reset").trigger("click"), t.find(".glyphicon-ok").removeClass("glyphicon-ok")), t.find('button[type="submit"]').text("Message sent!"), setTimeout(function () {
  419. t.find('button[type="submit"]').text(a)
  420. }, 3e3)
  421. }), i.fail(function (e, n) {
  422. e.status;
  423. notify(e.notify_title, e.responseText, "danger"), t.find('button[type="submit"]').text("Error!"), setTimeout(function () {
  424. t.find('button[type="submit"]').text(a)
  425. }, 3e3)
  426. }), !1
  427. }
  428. }), $(".gradientify").length && $(".gradientify").each(function () {
  429. $this.gradientify({
  430. gradients: [{start: [17, 132, 254], stop: [154, 70, 248]}, {
  431. start: [154, 70, 248],
  432. stop: [17, 132, 254]
  433. }], angle: "0deg", fps: 60, transition_time: 10
  434. })
  435. }), $(".btn-clipboard")[0]) && new Clipboard(".btn-clipboard").on("success", function (e) {
  436. e.trigger.innerHTML = '<span class="text-sm">Copied</span>', e.clearSelection(), setTimeout(function () {
  437. e.trigger.innerHTML = '<i class="fa fa-files-o"></i>'
  438. }, 3e3)
  439. })
  440. });