PageSourceSearch

https://torens-auto.com/bitrix/js/main/baseline/dist/baseline.bundle.js?17901309336900

js torens-auto.com collected 2026-09-26 04:23:53 UTC 6,900 bytes, 255 lines download raw bytes

1/* eslint-disable */
2(function (exports) {
3	'use strict';
4
5	const currentBaseline = {"date":"01.09.2026","versions":{"chrome":109,"edge":109,"firefox":115,"safari":16}};
6
7	const DISMISS_KEY = 'bx-baseline-dismiss';
8	const ANALYTICS_KEY = 'bx-baseline-analytics-sent';
9	const PLAN_KEY = JSON.stringify(currentBaseline);
10	function getSettings() {
11		try {
12			const script = document.querySelector('script[data-extension="main.baseline"]');
13			if (!script) {
14				return {
15					helpUrl: '',
16					helpCode: '',
17					collectData: false
18				};
19			}
20			const settings = JSON.parse(script.textContent || '');
21			return {
22				helpUrl: settings && settings.helpUrl || '',
23				helpCode: settings && settings.helpCode || '',
24				collectData: Boolean(settings && settings.collectData)
25			};
26		} catch {
27			return {
28				helpUrl: '',
29				helpCode: '',
30				collectData: false
31			};
32		}
33	}
34	function msg(key) {
35		return typeof BX !== 'undefined' && BX.message && BX.message[key] || '';
36	}
37	function detect() {
38		const uaData = navigator.userAgentData;
39		if (uaData && uaData.brands) {
40			for (let i = 0; i < uaData.brands.length; i++) {
41				if (uaData.brands[i].brand.toLowerCase().includes('chromium')) {
42					return {
43						name: 'chrome',
44						version: Number(uaData.brands[i].version)
45					};
46				}
47			}
48		}
49		const ua = navigator.userAgent;
50		const ieRv = ua.match(/Trident\/.*rv:(\d+)/);
51		if (ieRv) {
52			return {
53				name: 'ie',
54				version: Number(ieRv[1])
55			};
56		}
57		const ieMsie = ua.match(/MSIE\s(\d+)/);
58		if (ieMsie) {
59			return {
60				name: 'ie',
61				version: Number(ieMsie[1])
62			};
63		}
64		const edgeLegacy = ua.match(/Edge\/(\d+)/);
65		if (edgeLegacy && !ua.includes('Edg/')) {
66			return {
67				name: 'edge_legacy',
68				version: Number(edgeLegacy[1])
69			};
70		}
71		const ff = ua.match(/Firefox\/(\d+)/);
72		if (ff) {
73			return {
74				name: 'firefox',
75				version: Number(ff[1])
76			};
77		}
78		const fxios = ua.match(/FxiOS\/(\d+)/);
79		if (fxios) {
80			return {
81				name: 'safari',
82				version: Number(fxios[1])
83			};
84		}
85		const crios = ua.match(/CriOS\/(\d+)/);
86		if (crios) {
87			return {
88				name: 'safari',
89				version: Number(crios[1])
90			};
91		}
92		const isChromiumBased = /Chrome\/|Chromium\//.test(ua);
93		if (!isChromiumBased && /Safari\//.test(ua)) {
94			const safariVersion = ua.match(/Version\/(\d+)/);
95			if (safariVersion) {
96				return {
97					name: 'safari',
98					version: Number(safariVersion[1])
99				};
100			}
101		}
102		const chromium = ua.match(/Chrome\/(\d+)/);
103		if (chromium) {
104			return {
105				name: 'chrome',
106				version: Number(chromium[1])
107			};
108		}
109		return null;
110	}
111	function computeStatus(browser) {
112		if (!browser) {
113			return 'unsupported';
114		}
115		const versions = currentBaseline && currentBaseline.versions;
116		const minVersion = versions && versions[browser.name];
117		if (!minVersion || browser.version < minVersion) {
118			return 'unsupported';
119		}
120		return 'supported';
121	}
122	const DISMISS_TTL = 7 * 24 * 60 * 60 * 1000;
123	function isDismissed() {
124		try {
125			const raw = localStorage.getItem(DISMISS_KEY);
126			if (!raw) {
127				return false;
128			}
129			const data = JSON.parse(raw);
130			return data.plan === PLAN_KEY && Date.now() - data.ts < DISMISS_TTL;
131		} catch {
132			return false;
133		}
134	}
135	function dismiss() {
136		try {
137			localStorage.setItem(DISMISS_KEY, JSON.stringify({
138				plan: PLAN_KEY,
139				ts: Date.now()
140			}));
141		} catch {}
142	}
143	function isAnalyticsSent() {
144		try {
145			return localStorage.getItem(ANALYTICS_KEY) === '1';
146		} catch {
147			return false;
148		}
149	}
150	function sendAnalytics(result, settings) {
151		if (!settings.collectData || isAnalyticsSent()) {
152			return;
153		}
154		if (typeof navigator.sendBeacon !== 'function') {
155			return;
156		}
157		const params = new URLSearchParams();
158		params.set('st[tool]', 'browser_checker');
159		params.set('st[event]', 'browser_version');
160		params.set('st[category]', 'outdated_browser');
161		params.set('st[p1]', result.browser ? result.browser.name : 'unknown');
162		params.set('st[p2]', result.browser ? String(result.browser.version) : '0');
163		navigator.sendBeacon(`/_analytics/?${params}`);
164		try {
165			localStorage.setItem(ANALYTICS_KEY, '1');
166		} catch {}
167	}
168	function isWebView() {
169		if (typeof window.BXMobileApp !== 'undefined') {
170			return true;
171		}
172		const ua = navigator.userAgent;
173		if (ua.includes('BitrixMobile')) {
174			return true;
175		}
176		if (/; wv\)/.test(ua)) {
177			return true;
178		}
179		if (/\bMobile\//.test(ua) && !/Safari\//.test(ua)) {
180			return true;
181		}
182		return false;
183	}
184	function showBanner(text, settings) {
185		if (!text || isDismissed() || isWebView()) {
186			return;
187		}
188		const banner = document.createElement('div');
189		banner.style.cssText = ['position:sticky', 'top:0', 'z-index:995', 'padding:12px 48px 12px 16px', 'font:14px/1.4 -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif', 'color:#611a15', 'background:#fdeded', 'border-bottom:1px solid #f5c6cb'].join(';');
190		const textNode = document.createTextNode(`${text} `);
191		banner.appendChild(textNode);
192		if (settings.helpUrl) {
193			const detailsLink = document.createElement('a');
194			detailsLink.href = settings.helpUrl;
195			detailsLink.target = '_blank';
196			detailsLink.rel = 'noopener noreferrer';
197			detailsLink.textContent = msg('MAIN_BASELINE_DETAILS');
198			detailsLink.style.cssText = 'color:inherit;font-weight:bold';
199			if (settings.helpCode) {
200				detailsLink.onclick = e => {
201					if (typeof BX !== 'undefined' && BX.Helper && BX.Helper.show) {
202						e.preventDefault();
203						BX.Helper.show(settings.helpCode);
204					}
205				};
206			}
207			banner.appendChild(detailsLink);
208		}
209		const closeBtn = document.createElement('button');
210		closeBtn.style.cssText = ['position:absolute', 'top:50%', 'right:12px', 'transform:translateY(-50%)', 'border:none', 'background:none', 'font-size:20px', 'line-height:1', 'cursor:pointer', 'color:inherit', 'opacity:0.7', 'padding:4px 8px'].join(';');
211		closeBtn.textContent = '\u00D7';
212		closeBtn.title = msg('MAIN_BASELINE_CLOSE');
213		closeBtn.onclick = () => {
214			dismiss();
215			if (banner.parentNode) {
216				banner.parentNode.removeChild(banner);
217			}
218		};
219		banner.appendChild(closeBtn);
220		if (document.body) {
221			document.body.insertBefore(banner, document.body.firstChild);
222		} else {
223			document.addEventListener('DOMContentLoaded', () => {
224				document.body.insertBefore(banner, document.body.firstChild);
225			});
226		}
227	}
228	class Baseline {
229		static check() {
230			const browser = detect();
231			const status = computeStatus(browser);
232			const result = {
233				status,
234				browser
235			};
236			if (result.status === 'unsupported') {
237				const settings = getSettings();
238				sendAnalytics(result, settings);
239				showBanner(msg('MAIN_BASELINE_BROWSER_OUTDATED'), settings);
240			}
241			return result;
242		}
243		static isSupported() {
244			return computeStatus(detect()) === 'supported';
245		}
246		static detectBrowser() {
247			return detect();
248		}
249	}
250	Baseline.check();
251
252	exports.Baseline = Baseline;
253
254})(this.BX = this.BX || {});
255//# sourceMappingURL=baseline.bundle.js.map

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.