Repository navigation
Expand file tree
/
Copy pathcontent.js
More file actions
69 lines (61 loc) · 1.74 KB
/
Copy pathcontent.js
File metadata and controls
69 lines (61 loc) · 1.74 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
function populate_block() {
// Avoid adding duplicate overlays
if (document.getElementById("stealth-mission-overlay")) return;
// Create the overlay element
const overlay = document.createElement("div");
overlay.id = "stealth-mission-overlay";
overlay.innerHTML = `
<div id="stealth-mission-card">
<div id="stealth-mission-title">MISSION COMPROMISED</div>
<div id="stealth-mission-subtitle">This tab is not part of your current objective.</div>
</div>
`;
// Add styles for the overlay
const style = document.createElement("style");
style.textContent = `
#stealth-mission-overlay {
position: fixed;
inset: 0;
background: rgba(10, 14, 18, 0.72);
backdrop-filter: blur(4px);
z-index: 2147483647;
display: flex;
align-items: center;
justify-content: center;
font-family: Arial, sans-serif;
}
#stealth-mission-card {
width: min(420px, 90vw);
background: #11161b;
color: white;
border-radius: 16px;
padding: 24px;
box-shadow: 0 20px 60px rgba(0,0,0,0.45);
border: 1px solid rgba(255,255,255,0.08);
text-align: center;
}
#stealth-mission-title {
font-size: 24px;
font-weight: 800;
letter-spacing: 0.08em;
color: #ff6b6b;
margin-bottom: 12px;
}
#stealth-mission-subtitle {
font-size: 15px;
font-weight: 600;
margin-bottom: 10px;
}
#stealth-mission-body {
font-size: 14px;
opacity: 0.86;
}
`;
document.documentElement.appendChild(style);
document.documentElement.appendChild(overlay);
}
chrome.runtime.onMessage.addListener((request, sender, sendResponse) => {
if (request.action === "populate_block") {
populate_block();
}
});