PageSourceSearch

https://www.nakayamagumi.com/tmp_js/portfolio.js

js nakayamagumi.com collected 2026-10-06 08:16:12 UTC 2,532 bytes, 68 lines download raw bytes

1$(function(){
2    var parabola = parabola ? parabola : {}
3    parabola.portfolio_activate_section = {};
4
5    parabola.portfolio_activate = function($portfolio){
6        const id = $portfolio.parents('section').attr('id') + '-vue';
7        if (parabola.portfolio_activate_section[id] !== void 0) {
8            return;
9        }
10        $portfolio.attr('id', id);
11
12        var portfolioOptions = function () {
13            var options = {};
14            var data_blog = $portfolio.parents('.section_name').attr('data-section_category');
15            if ('undefined' !== typeof data_blog) {
16                var data_json = JSON.parse(data_blog);
17                options['tag_id'] = data_json.id;
18                options['limit'] = data_json.limit;
19            }
20            return options;
21        };
22
23        var options = portfolioOptions();
24
25        var vm = new Vue({
26            el: '#' + id,
27            data: {
28                portfolios: [],
29                size: $portfolio.data('size')
30            },
31            methods: {
32                load: function() {
33                    var config = {
34                        headers:{
35                            'X-Requested-With': 'XMLHttpRequest',
36                            'Content-Type': 'application/json'
37                        },
38                        withCredentials: true,
39                        params: {
40                            tag_id: options.tag_id,
41                            limit: options.limit || vm.size
42                        }
43                    };
44                    axios.get('/api/portfolios', config)
45                        .then(function(data){ 
46                            vm.portfolios = data.portfolios;
47                            if(vm.portfolios.length === 0 && parent.document.getElementById('editor_frame') === null){
48                                $(vm.$el).parents('.section_name').first().hide();
49                            }
50                            $(document).ready(function () {
51                                $(".portfolio_articles_toggle_display").each(function () {
52                                    $(this).css("display", "");
53                                });
54                            });
55                        })
56                        .catch(function(){ vm.portfolios = []; })
57                }
58            }
59        });
60
61        parabola.portfolio_activate_section[id] = vm;
62        vm.load();
63    };
64
65    $.each($('.portfolio_list'), function(){
66        parabola.portfolio_activate($(this));
67    });
68});

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.