PageSourceSearch

https://mbi74.ru/bitrix/components/ktoto/message/templates/.default/script.js

js mbi74.ru collected 2026-10-02 12:51:21 UTC 1,308 bytes, 33 lines download raw bytes

1$( document ).ready(function() {
2    function checkCookies(){
3        let cookieDate = localStorage.getItem('cookieMessageDate');
4        let cookieNotification = document.getElementById('messageModal');
5		let seconds = document.getElementById('seconds');
6
7		if (!!cookieNotification && !!seconds){
8			let cookieBtn = cookieNotification.querySelector('.closeModal');
9			let cookieBtn2 = cookieNotification.querySelector('.closeModal2');
10
11			seconds = seconds.innerHTML;
12			
13			// При клике на кнопку, в локальное хранилище записывается текущая дата в системе UNIX
14			cookieBtn.addEventListener('click', function(){
15				localStorage.setItem( 'cookieMessageDate', Date.now() );
16				cookieNotification.classList.remove('show');
17			})
18	
19			cookieBtn2.addEventListener('click', function(){
20				localStorage.setItem( 'cookieMessageDate', Date.now() );
21				cookieNotification.classList.remove('show');
22			})
23	
24			// Если записи нет или она просрочена на 1 год, то показываем информацию 
25			setTimeout(function() {
26				if( !cookieDate || (+cookieDate + 31536000000) < Date.now() ){
27					cookieNotification.classList.add('show');
28				}
29			}, (seconds * 1000));
30		}
31    }
32    checkCookies();
33});

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.