İlgili sayfayı açın, takip etmek istediğiniz alanın üzerine sağ tıklayıp "İncele" seçeneğini seçin ve alanın ID numarasını tespit edin. Ardından "Console" bölümüne geçip, kodu yapıştırın ve ilgili ID'yi girin. Takip işlemi başlayacak; değişiklik algılandığında sesli ve görsel uyarı verilecektir.
(function() {
const targetId = prompt('Lütfen izlemek istediğiniz alanın ID\'sini girin. Unitmon: statusTable | Türktelekom: container');
if (!targetId) {
alert('Geçerli bir ID girilmedi.');
return;
}
const target = document.getElementById(targetId);
if (!target) {
alert(`ID "${targetId}" bulunamadı.`);
return;
}
const colors = ['red', 'orange', 'yellow', 'green', 'blue', 'indigo', 'violet'];
let alertDiv = document.createElement('div');
alertDiv.style.position = 'fixed';
alertDiv.style.top = '0';
alertDiv.style.left = '0';
alertDiv.style.width = '100vw';
alertDiv.style.height = '100vh';
alertDiv.style.pointerEvents = 'none';
alertDiv.style.zIndex = '9999';
alertDiv.style.mixBlendMode = 'multiply';
alertDiv.style.transition = 'background-color 0.5s ease';
document.body.appendChild(alertDiv);
let animationRunning = false;
function playBeep() {
const AudioContext = window.AudioContext || window.webkitAudioContext;
const audioCtx = new AudioContext();
const oscillator = audioCtx.createOscillator();
const gainNode = audioCtx.createGain();
oscillator.type = 'square';
oscillator.frequency.setValueAtTime(800, audioCtx.currentTime); // Frekans: 800Hz
gainNode.gain.setValueAtTime(0.2, audioCtx.currentTime); // Ses seviyesi
oscillator.connect(gainNode);
gainNode.connect(audioCtx.destination);
oscillator.start();
oscillator.stop(audioCtx.currentTime + 0.3); // 300ms beep
}
function startAnimation() {
if (animationRunning) return;
animationRunning = true;
let i = 0;
playBeep(); // Sesli uyarı
let interval = setInterval(() => {
alertDiv.style.backgroundColor = colors[i % colors.length];
i++;
if (i > colors.length * 4) {
clearInterval(interval);
alertDiv.style.backgroundColor = 'transparent';
animationRunning = false;
}
}, 300);
}
const observer = new MutationObserver(mutations => {
if (mutations.length > 0) {
startAnimation();
console.log(`${targetId} alanında değişiklik tespit edildi!`);
}
});
observer.observe(target, {
attributes: true,
childList: true,
subtree: true,
characterData: true
});
console.log(`${targetId} alanındaki değişiklikleri izliyorum...`);
})();