PageSourceSearch

https://www.montemarmaritim.com/themes/default/js/pop-up.js?v=1679992465

js montemarmaritim.com collected 2026-10-04 20:11:46 UTC 3,348 bytes, 86 lines download raw bytes

1/*************************************************************************/
2/**************************** VER MÁS POP-UPS ****************************/
3/*************************************************************************/
4// Se abre el pop up
5$(".more.pop-up a").on("click", function (e) {
6    e.preventDefault();
7    e.stopPropagation();
8    let content = $(this).siblings(".more__text").html();
9    $("#more__pop-up .more__pop-up__text").html(content);
10    $("#more__pop-up").removeClass("invisible");
11});
12// Se cierra el pop up
13$(".more__pop-up__close, .more__pop-up__background").on("click", function (e) {
14    $("#more__pop-up").addClass("invisible");
15});
16
17/*************************************************************************/
18/**************************** VER MÁS POP-UPS ****************************/
19/*************************************************************************/
20
21
22/*************************************************************************/
23/*********************** POP UP DE CARGA DE LA WEB ***********************/
24/*************************************************************************/
25$( document ).ready(function() {
26    var nbModal = $('.js-nb-modal'),
27        DEFAULT_DELAY_SHOW_MODAL = 5,
28        DEFAULT_EXPIRATION_MODAL = 5,
29        delayModal = nbModal.data('delay') === '' ? DEFAULT_DELAY_SHOW_MODAL : nbModal.data('delay'),
30        expirationModal = nbModal.data('expiration') === '' ? DEFAULT_EXPIRATION_MODAL : nbModal.data('expiration');
31
32    /* Se comprueba si existen promociones activas. */
33    if (nbModal.length && Tools.readCookie('nb_modal') === null) {
34
35        /* Modal - configuración */
36        var setNbModal = function () {
37
38            /* Se comprueba si es la primera vez que se visita. */
39            if (!Tools.readCookie("nb_modal")) {
40
41                if (expirationModal !== '' && !isNaN(parseInt(expirationModal))) {
42                    expirationModal = parseInt(expirationModal);
43                }
44
45                $.magnificPopup.open({
46                    mainClass: 'my-mfp-zoom-in custom-mfp',
47                    items: {
48                        src: '#nb-modal',
49                        type: 'inline'
50                    },
51                    closeOnContentClick: false,
52                    closeOnBgClick: true,
53                    showCloseBtn: true,
54                    removalDelay: 500,
55                    fixedContentPos: false,
56
57                    callbacks: {
58                        close: function () {
59                            Tools.createCookie("nb_modal", 1, expirationModal);
60                        }
61                    }
62                });
63            }
64
65        };
66
67        /* Transforma el valor en segundos */
68        var milliseconds = function (x) {
69            var result = DEFAULT_DELAY_SHOW_MODAL;
70
71            if (!isNaN(x) && !isNaN(parseInt(x))) {
72                result = x;
73            }
74            return result * 1000;
75        };
76
77        var delayShow = milliseconds(delayModal);
78
79        /* Llamamos a función para lanzar el modal */
80        setTimeout(setNbModal, delayShow);
81    }
82});
83
84/*************************************************************************/
85/*********************** FIN POP UP DE CARGA DE LA WEB ***********************/
86/*************************************************************************/

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.