PageSourceSearch

https://yonghwi-kwon.github.io/seed/js/custom.js

js yonghwi-kwon.github.io collected 2026-10-03 10:13:30 UTC 3,967 bytes, 135 lines download raw bytes

1/*-----------------------------------------------------------
2* Template Name    : Kerri | Responsive Bootstrap 4 Personal Template
3* Author           : SRBThemes
4* Created          : March 2018
5* File Description : Main Js file of the template
6*------------------------------------------------------------
7*/
8
9! function($) {
10    "use strict";
11
12    var KerriApp = function() {};
13
14    //PreLoader
15    KerriApp.prototype.initPreLoader = function() {
16        $('#status').fadeOut();
17        $('#preloader').delay(350).fadeOut('slow');
18        $('body').delay(350).css({
19            'overflow': 'visible'
20        });
21    },
22
23    //scroll
24    KerriApp.prototype.initStickyMenu = function() {
25        var navbar = document.querySelector('nav')
26        window.onscroll = function() {
27          // pageYOffset or scrollY
28          if (window.pageYOffset > 200) {
29            navbar.classList.add('stickyadd')
30          } else {
31            navbar.classList.remove('stickyadd')
32          }
33        }
34    },
35
36    //Scrollspy
37    KerriApp.prototype.initScrollspy = function() {
38        var scrollSpy = new bootstrap.ScrollSpy(document.body, {
39            target: '#main_nav',
40            offset: 70
41        })
42    },
43
44    //Work
45    KerriApp.prototype.initWork = function() {
46        $(window).on('load', function () {
47            var $container = $('.work-filter');
48            var $filter = $('#menu-filter');
49            $container.isotope({
50                filter: '*',
51                layoutMode: 'masonry',
52                animationOptions: {
53                    duration: 750,
54                    easing: 'linear'
55                }
56            });
57
58            $filter.find('a').on("click",function() {
59                var selector = $(this).attr('data-filter');
60                $filter.find('a').removeClass('active');
61                $(this).addClass('active');
62                $container.isotope({
63                    filter: selector,
64                    animationOptions: {
65                        animationDuration: 750,
66                        easing: 'linear',
67                        queue: false,
68                    }
69                });
70                return false;
71            });
72        });
73    },
74
75    //Magnificpop
76    KerriApp.prototype.initMagnificPopup = function() {
77        $('.img-zoom').magnificPopup({
78            type: 'image',
79            closeOnContentClick: true,
80            mainClass: 'mfp-fade',
81            gallery: {
82                enabled: true,
83                navigateByImgClick: true,
84                preload: [0, 1]
85            }
86        });
87    },
88
89    // BACK TO TOP
90    KerriApp.prototype.initBackToTop = function() {
91        $(window).on('scroll',function(){
92            if ($(this).scrollTop() > 100) {
93                $('.back_top').fadeIn();
94            } else {
95                $('.back_top').fadeOut();
96            }
97        }); 
98        $('.back_top').click(function(){
99            $("html, body").animate({ scrollTop: 0 }, 1000);
100            return false;
101        });
102    },
103
104    //Client
105    KerriApp.prototype.initTestimonial = function() {
106        $('.owl-carousel').owlCarousel({
107            loop:true,
108            nav:false,
109            items:1,
110            autoplay:true,
111            autoplayTimeout:5000,
112            autoplayHoverPause:true,
113            autoHeight: false,
114            autoHeightClass: 'owl-height'
115        })
116    }
117
118    KerriApp.prototype.init = function() {
119        this.initPreLoader();
120        this.initStickyMenu();
121        this.initScrollspy();
122        this.initWork();
123        this.initMagnificPopup();
124        this.initBackToTop();
125        this.initTestimonial();
126    },
127    //init
128    $.KerriApp = new KerriApp, $.KerriApp.Constructor = KerriApp
129}(window.jQuery),
130
131//initializing
132function($) {
133    "use strict";
134    $.KerriApp.init();
135}(window.jQuery);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.