PageSourceSearch

https://recodh.org/wp-content/themes/kunco/js/scroll/jquery.scrollto.js?ver=6.9.10

js recodh.org collected 2026-10-08 00:04:30 UTC 1,008 bytes, 36 lines download raw bytes

1/*!
2 * jquery.scrollto.js 0.0.1 - https://github.com/yckart/jquery.scrollto.js
3 * Scroll smooth to any element in your DOM.
4 *
5 * Copyright (c) 2012 Yannick Albert (http://yckart.com)
6 * Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php).
7 * 2013/02/17
8 **/
9
10 (function($){
11$.scrollTo = $.fn.scrollTo = function(x, y, options){
12    if (!(this instanceof $)) return $.fn.scrollTo.apply($('html, body'), arguments);
13
14    options = $.extend({}, {
15        gap: {
16            x: 0,
17            y: 0
18        },
19        animation: {
20            easing: 'swing',
21            duration: 600,
22            complete: $.noop,
23            step: $.noop
24        }
25    }, options);
26
27    return this.each(function(){
28        var elem = $(this);
29        elem.stop().animate({
30            scrollLeft: !isNaN(Number(x)) ? x : $(y).offset().left + options.gap.x,
31            scrollTop: !isNaN(Number(y)) ? y : $(y).offset().top + options.gap.y
32        }, options.animation);
33    });
34};
35
36}(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.