PageSourceSearch

https://classicsolitaire.com/adnet/privacy/privacy-controls.js?v=1727212583284

js classicsolitaire.com collected 2026-10-09 04:47:43 UTC 5,075 bytes, 152 lines download raw bytes

1"use strict";
2(() =>
3{
4	///js:library:site.privacy-controls
5	/** @file site.privacy-controls.ts */
6	window.games247.privacyControls = (() => {
7		let html = 
8		/*html*/ `
9	<div class="privacy-controls">
10		<p><strong>This website uses cookies</strong></p>
11		<p>This website uses cookies to improve user experience. By using our website you consent to all cookies in accordance with our Cookie Policy. <a target="_blank" href="/cookie-policy.html">Cookie Policy<a></p>
12		<p><strong><u>COOKIE CATEGORIES</u></strong></p>
13		<p>Please choose which cookie categories you accept below:</p>
14		<div>
15			<p><input type="checkbox" checked disabled>&nbsp;<strong>Strictly Necessary</strong></p>
16			<p>Strictly necessary cookies allow core website functionality such as user login and account management. The website cannot be used properly without strictly necessary cookies. These cannot be turned off.</p>
17		</div>
18		<div>
19			<p><input class="cc-perf" type="checkbox">&nbsp;<strong>Performance</strong></p>
20			<p>Performance cookies are used to see how visitors use the website, eg. analytics cookies. Those cookies cannot be used to directly identify a certain visitor.</p>
21		</div>
22		<div>
23			<p><input class="cc-targ" type="checkbox">&nbsp;<strong>Targeting</strong></p>
24			<p>Targeting cookies are used to identify visitors between different websites, eg. content partners, banner networks. Those cookies may be used by companies to build a profile of visitor interests or show relevant ads on other websites.</p>
25		</div>
26		<div>
27			<p><input class="cc-func" type="checkbox">&nbsp;<strong>Functionality</strong></p>
28			<p>Functionality cookies are used to remember visitor information on the website, eg. language, timezone, enhanced content.</p>
29		</div>
30		<div>
31			<p><input class="cc-uncl" type="checkbox">&nbsp;<strong>Unclassified</strong></p>
32			<p>Unclassified cookies are cookies that do not belong to any other category or are in the process of categorization.</p>
33		</div>
34		<div>
35			<div class="privacy-controls-btn accept">Allow All</div>
36			<div class="privacy-controls-btn save">Save</div>
37		</div>
38	</div>
39	`;
40		let css = 
41		/*css*/ `
42	.privacy-controls
43	{
44		display: none;
45		position: fixed;
46		top: 0;
47		left: 0;
48		right: 0;
49		bottom: 0;
50		background: white;
51	
52		overflow-y: auto;
53	
54		padding: 16px;
55		padding-bottom: 32px;
56		z-index: 999999;
57
58		font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, "Helvetica Neue", Cantarell, Arial, Oxygen-Sans, Ubuntu, sans-serif;	/* Native Font Stack */
59	}
60	.privacy-controls input
61	{
62		display: inline-block;
63	}
64	.privacy-controls-btn
65	{
66		float: left;
67	
68		border-radius: 16px;
69		padding: 10px 20px;
70		text-transform: uppercase;
71	
72		cursor: pointer;
73	
74		border: solid 1px #CCCCCC;
75	
76		margin: 8px;
77	}
78	.privacy-controls-btn.accept
79	{
80		float: right;
81		font-weight: bold;
82		color: #FFFFFF;
83		border: solid 2px #4CAF50;
84		box-shadow: 0px 3px 0px rgba(0, 0, 0, 0.2);
85		background: #4CAF50;
86	}
87	
88	html.privacy-controls-open,
89	html.privacy-controls-open body
90	{
91		width: 100% !important;
92		height: 100% !important;
93		overflow: hidden !important;
94	}
95	`;
96		let element = document.createElement("div");
97		let style = document.createElement("style");
98		let chkPerf;
99		let chkTarg;
100		let chkFunc;
101		let chkUncl;
102		let acceptBtn;
103		let saveBtn;
104		// Add to the page
105		element.innerHTML = html;
106		element = element.children.item(0);
107		document.body.appendChild(element);
108		style.innerText = css;
109		document.head.appendChild(style);
110		// Query
111		chkPerf = document.querySelector(".privacy-controls .cc-perf");
112		chkTarg = document.querySelector(".privacy-controls .cc-targ");
113		chkFunc = document.querySelector(".privacy-controls .cc-func");
114		chkUncl = document.querySelector(".privacy-controls .cc-uncl");
115		acceptBtn = document.querySelector(".privacy-controls-btn.accept");
116		saveBtn = document.querySelector(".privacy-controls-btn.save");
117		saveBtn.addEventListener("click", () => {
118			games247.privacy.setLocalConsent(chkPerf.checked, chkTarg.checked, chkFunc.checked, chkUncl.checked);
119			close();
120		});
121		acceptBtn.addEventListener("click", () => {
122			games247.privacy.setLocalConsent(true, true, true, true);
123			close();
124		});
125		/**
126		 * Opens the controls.
127		 */
128		function open() {
129			element.style.display = "block";
130			chkPerf.checked = games247.privacy.isConsented("performance");
131			chkTarg.checked = games247.privacy.isConsented("targeting");
132			chkFunc.checked = games247.privacy.isConsented("functionality");
133			chkUncl.checked = games247.privacy.isConsented("unclassified");
134			document.documentElement.classList.add("privacy-controls-open");
135		}
136		/**
137		 * Closes the controls.
138		 */
139		function close() {
140			element.style.display = "none";
141			document.documentElement.classList.remove("privacy-controls-open");
142			// Spoof a resize event so the game knows to resize (which is required because the scroll bars may have appeared / disappeared)
143			window.dispatchEvent(new Event("resize"));
144		}
145		// If this was loaded, then we want it open
146		open();
147		return {
148			open: open
149		};
150	})();
151	
152})();

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.