PageSourceSearch

https://www.caritas-zaragoza.org/main-files/themes/101wp-child/mod…/donacion-rapida-build.js?ver=1.0.0

js caritas-zaragoza.org collected 2026-09-26 05:49:13 UTC 1,374 bytes, 55 lines download raw bytes

1(function ($) {
2    'use strict';
3
4    var instances = [];
5
6
7    function onReady() {
8        $('.module.donacion-rapida').each(function () {
9            instances.push(initInstance($(this)));
10        });
11    }
12
13    function initInstance(view) {
14
15        // Private properties
16        // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
17
18        var $view = view,
19            id = $view.data('id');
20
21        // Private methods
22        // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
23
24        // instance object
25        var instance = {
26            init: function () {
27                // Remove this lines this and the next line
28                // console.log('Instance of donacion-rapida initialized with id and view: ', id, view);
29
30                $view.find('.open-shopping').on('click', function(e){
31
32                    if(!/^-?\d*[.,]?\d*$/.test($(e.currentTarget).attr('data-amount'))){
33
34                        $view.find('input.other-quantity').addClass('error');
35
36                        e.stopPropagation();
37
38                    }else{
39
40                        $view.find('input.other-quantity').removeClass('error');
41
42                    }
43
44                });
45
46            }
47        };
48
49        instance.init();
50        return instance;
51    }
52
53    // DOMContentLoaded
54    $(onReady);
55})(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.