PageSourceSearch

https://salon.ru/js/mainPageMore.js

js salon.ru collected 2026-10-02 10:09:15 UTC 1,795 bytes, 49 lines download raw bytes

1var mainPageMore = (function ($, clickSelector) {
2    var o = new Object();
3    o.clickSelector = clickSelector;
4    o.loadMore = function (e) {
5        var cur = $('.js-main-page-nav .active[role="presentation"] a[role="tab"]');
6        if (cur.length > 0) {
7            var page = parseInt(cur.attr('data-current-page'));
8            if (isNaN(page)) {
9                page = 0;
10            }
11
12            // OnTheIO
13            if (Object.prototype.hasOwnProperty.call(window, 'io')) {
14                window.io({
15                    event: 'pageviews',
16                    config_page_url: document.baseURI
17                });
18            }
19            // OnTheIO
20
21            //$(o.clickSelector).hide();
22            page++;
23            $.ajax({
24                async: false,
25                url: '/get-publications/' + cur.attr('aria-controls') + '/' + page,
26                success: function(data, textStatus, jqXHR) {
27                    cur.attr('data-current-page', page);
28
29                    var gridSelector, gridItemSelector;
30                    if(cur.attr('aria-controls') === 'architects') {
31                        gridSelector = '.js-creators-grid';
32                        gridItemSelector = '.js-creators-grid-item';
33                    } else {
34                        gridSelector = '.js-grid';
35                        gridItemSelector = '.js-grid-item';
36                    }
37
38                    $(data).find(gridItemSelector).each(function(i,e){
39                       $('.js-main-page-tabcontent .tab-pane.active ' + gridSelector).append($(e).clone());
40                    });
41                    mainTab();
42                }
43            });
44        }
45        return false;
46    };
47    $(clickSelector).click(o.loadMore);
48    return o;
49}(jQuery, '.js-more-articles'));

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.