📜 Tümünü Göster 🔄 Otomatiğe Al var oynatici; var sozler=[ { "time": 0, "text": "Can’t you see?", "meaning": "Anlamıyor musun?" }, { "time": 8.562432152587892, "text": "I love you", "meaning": "Seni seviyorum" }, { "time": 9.961876938964844, "text": "Please don’t break my heart in two", "meaning": "Lütfen kalbimi kırma" }, { "time": 13.441187969482423, "text": "That’s not hard to do", "meaning": "Bunu yapmak zor değil" }, { "time": 15.67361983215332, "text": "’cause I don’t have a wooden heart", "meaning": "Çünkü tahtadan bir kalbim yok" }, { "time": 21.665182912261965, "text": "And if you say goodbye", "meaning": "Ve eğer elveda dersen" }, { "time": 24.601990139236452, "text": "Then I know that I would cry", "meaning": "Ben ağlıyor olacağım" }, { "time": 28.193426219345092, "text": "Maybe I would die", "meaning": "Belki de ölürüm" }, { "time": 30.40124206866455, "text": "’cause I don’t have a wooden heart", "meaning": "Çünkü tahtadan bir kalbim yok" }, { "time": 36.32193597711181, "text": "There’s no strings upon this love of mine", "meaning": "Benim aşkımda hiç hile yok" }, { "time": 42.28183795231628, "text": "It was always you from the start", "meaning": "Başından beri hep sen vardın" }, { "time": 47.993744062942504, "text": "Treat me nice", "meaning": "Bana güzel davran" }, { "time": 49.617952866485595, "text": "Treat me good", "meaning": "Bana iyi davran" }, { "time": 50.993316076293944, "text": "Treat me like you really should", "meaning": "Bana gerçekten olması gerektiği gibi davran" }, { "time": 54.45766398092651, "text": "’cause I’m not made of wood", "meaning": "Çünkü ben tahtadan yapılmadım" }, { "time": 56.84908809536743, "text": "And I don’t have a wooden heart", "meaning": "Haliyle tahtadan bir kalbim yok" }, { "time": 62.753598074386595, "text": "Muss ich denn, muss ich denn", "meaning": "Mecbur muyum, mecbur muyum" }, { "time": 65.70513301144409, "text": "Zum Städtele hinaus,", "meaning": "Kasabayı terk etmeye?" }, { "time": 69.3536880667572, "text": "Städtele hinaus", "meaning": "Terk etmeye?" }, { "time": 71.64947897520446, "text": "Und du, mein Schatz, bleibst hier?", "meaning": "Ya sen sevgilim, burada kalmaya?" }, { "time": 77.45798394277953, "text": "Muss ich denn, muss ich denn", "meaning": "Mecbur muyum, mecbur muyum" }, { "time": 80.42577283024598, "text": "Zum Städtele hinaus,", "meaning": "Kasabayı terk etmeye?" }, { "time": 84.04949897520447, "text": "Städtele hinaus", "meaning": "Terk etmeye?" }, { "time": 86.39379496948241, "text": "Und du, mein Schatz, bleibst hier?", "meaning": "Ya sen sevgilim, burada kalmaya?" }, { "time": 92.25733110871887, "text": "There’s no strings upon this love of mine", "meaning": "Benim aşkımda hiç hile yok" }, { "time": 98.20135111253357, "text": "It was always you from the start", "meaning": "Başından beri hep sen vardın" }, { "time": 103.92863491226196, "text": "Sei mir gut,", "meaning": "İyi davran bana," }, { "time": 105.62541213732909, "text": "Sei mir gut,", "meaning": "İyi davran bana," }, { "time": 107, "text": "Sei mir wie du wirklich sollst…", "meaning": "Gerçekten olması gerektiği gibi iyi davran bana…" }, { "time": 110.6686857844696, "text": "Wie du wirklich sollst…", "meaning": "Gerçekten olması gerektiği gibi…" }, { "time": 112.94184803623962, "text": "Cause I don’t have a wooden heart", "meaning": "Çünkü tahtadan bir kalbim yok" } ]; var mevcutSatir=-1; var lastMevcutSatir=-1; var sozlerGuncelleInterval; // Şarkı sözlerini oluşturma fonksiyonu sozlerOlustur(); // Tümünü göster ikonuna tıklama document.getElementById('show-all-icon').addEventListener('click', function(){ document.getElementById('sozler-kapsayici').style.height='auto'; document.getElementById('sozler-kapsayici').style.overflowY='visible'; this.style.display='none'; document.getElementById('scroll-icon').style.display='inline'; }); // Scroll moduna dön ikonuna tıklama document.getElementById('scroll-icon').addEventListener('click', function(){ document.getElementById('sozler-kapsayici').style.height='400px'; document.getElementById('sozler-kapsayici').style.overflowY='auto'; this.style.display='none'; document.getElementById('show-all-icon').style.display='inline'; }); function onYouTubeIframeAPIReady(){ oynatici=new YT.Player('oynatici', { height: '315', width: '560', videoId: 'C8TGpW04hjg', // Buraya YouTube video ID'sini girin playerVars: { autoplay: 0, controls: 1, mute: 0, disablekb: 0, rel: 0, showinfo: 0, modestbranding: 1 }, events: { 'onStateChange': oynaticiDurumDegisti } }); } function oynaticiDurumDegisti(event){ if(event.data==YT.PlayerState.PLAYING||event.data==YT.PlayerState.PAUSED||event.data==YT.PlayerState.BUFFERING){ if(!sozlerGuncelleInterval){ sozleriGuncelle(); sozlerGuncelleInterval=setInterval(sozleriGuncelle, 200); } }else{ clearInterval(sozlerGuncelleInterval); sozlerGuncelleInterval=null; } } function sozleriGuncelle(){ if(!oynatici||!oynatici.getCurrentTime) return; var currentTime=oynatici.getCurrentTime(); for (var i=0; i < sozler.length; i++){ if(currentTime >=sozler[i].time&&(!sozler[i + 1]||currentTime < sozler[i + 1].time)){ if(mevcutSatir!==i){ mevcutSatir=i; sozlerStilGuncelle(); } break; } } } function sozlerStilGuncelle(){ if(lastMevcutSatir >=0){ var lastLineEl=document.getElementById('soz-' + lastMevcutSatir); if(lastLineEl){ lastLineEl.classList.remove('current'); lastLineEl.classList.add('passed'); } } var currentLineEl=document.getElementById('soz-' + mevcutSatir); if(currentLineEl){ currentLineEl.classList.add('current'); currentLineEl.classList.remove('passed'); // Mevcut satırı ekranın ortasında göstermek için otomatik kaydırma var sozlerKapsayici=document.getElementById('sozler-kapsayici'); var containerHeight=sozlerKapsayici.clientHeight; var currentLineOffset=currentLineEl.offsetTop - sozlerKapsayici.offsetTop; var scrollPosition=currentLineOffset - (containerHeight / 2) + (currentLineEl.clientHeight / 2); // Yumuşak kaydırma için özel fonksiyon animateScroll(sozlerKapsayici, scrollPosition, 300); } lastMevcutSatir=mevcutSatir; } function animateScroll(element, to, duration){ var start=element.scrollTop; var change=to - start; var startTime=performance.now(); function animateScrollStep(currentTime){ var elapsedTime=currentTime - startTime; var progress=Math.min(elapsedTime / duration, 1); element.scrollTop=start + change * easeInOutQuad(progress); if(progress < 1){ requestAnimationFrame(animateScrollStep); } } requestAnimationFrame(animateScrollStep); } function easeInOutQuad(t){ return t < 0.5 ? 2*t*t:-1+(4-2*t)*t; } function sozlerOlustur(){ var sozlerKapsayici=document.getElementById('sozler-kapsayici'); sozlerKapsayici.innerHTML=''; for (var i=0; i < sozler.length; i++){ var lyricDiv=document.createElement('div'); lyricDiv.className='sozler-satir'; lyricDiv.id='soz-' + i; lyricDiv.setAttribute('data-time', sozler[i].time); var textDiv=document.createElement('div'); textDiv.textContent=sozler[i].text; var meaningDiv=document.createElement('div'); meaningDiv.className='sozler-anlam'; meaningDiv.textContent=sozler[i].meaning; lyricDiv.appendChild(textDiv); lyricDiv.appendChild(meaningDiv); lyricDiv.addEventListener('click', function(){ var time=parseFloat(this.getAttribute('data-time')); oynatici.seekTo(time, true); }); sozlerKapsayici.appendChild(lyricDiv); } }