📜 Tümünü Göster 🔄 Otomatiğe Al var oynatici; var sozler=[ { "time": 29.964631897003173, "text": "Watch the sunrise along the coast", "meaning": "Güneşin doğuşunu izliyoruz" }, { "time": 34.59682808010864, "text": "As we’re both getting old", "meaning": "Birlikte yaşlanırken" }, { "time": 39.62088710490417, "text": "I can’t describe what I’m feeling", "meaning": "Nasıl hissettiğimi anlatamıyorum" }, { "time": 45.38096010871887, "text": "And all I know is we’re going home", "meaning": "Tek bildiğim eve döndüğümüz" }, { "time": 49.42928490653991, "text": "So please don’t let me go, oh", "meaning": "O yüzden lütfen beni bırakma, ah" }, { "time": 53.932726070571896, "text": "Don’t let me go, oh-oh-oh", "meaning": "Beni bırakma, ah-ah-ah" }, { "time": 58.08549294850158, "text": "And if it’s right", "meaning": "Ve doğruysa" }, { "time": 60.821353183105465, "text": "I don’t care how long it takes", "meaning": "Ne kadar sürdüğü umurumda değil" }, { "time": 67.68460982643127, "text": "As long as I’m with you", "meaning": "Seninle olduğum sürece" }, { "time": 70.48524800381469, "text": "I’ve got a smile on my face", "meaning": "Yüzümde bir gülümseme olacak" }, { "time": 75.29325803623962, "text": "Save your tears, it’ll be okay", "meaning": "Tut gözyaşlarını, her şey yoluna girecek" }, { "time": 83.56451896757507, "text": "All I know is you’re here with me", "meaning": "Tek bildiğim, yanımda olduğun" }, { "time": 94.1, "text": "Oh, oh, oh, oh-oh-oh-oh-oh", "meaning": "Ah, ah, ah, ah-ah-ah-ah-ah" }, { "time": 106.23718704196166, "text": "Watch the sunrise as we’re getting old, oh-oh", "meaning": "Birlikte yaşlanırken güneşin doğuşunu izliyoruz, ah-ah" }, { "time": 117.19772905912781, "text": "I can’t describe, whoa-oh", "meaning": "Ah, ah anlatamıyorum" }, { "time": 122.19296204768371, "text": "I wish I could live through every memory again", "meaning": "Her anıyı yeniden yaşamak isterdim" }, { "time": 130.4405330267029, "text": "Just one more time before we float off in the wind", "meaning": "Rüzgarla savrulmadan önce bir kez daha" }, { "time": 136.7, "text": "And all the time we spent", "meaning": "Ve birlikte geçirdiğimiz tüm o zamanı" }, { "time": 139.6409110858307, "text": "Waiting for the light to take us in", "meaning": "Işığın bizi içine almasını bekleyerek geçirdik" }, { "time": 144.9292450114441, "text": "Have been the greatest moments of my life", "meaning": "Hayatımın en güzel anlarıydı" }, { "time": 151.88938602479556, "text": "I don’t care how long it takes", "meaning": "Ne kadar sürdüğü umurumda değil" }, { "time": 158.86503297520449, "text": "As long as I’m with you, I’ve got a smile on my face", "meaning": "Yanımda olduğun sürece yüzümde bir gülümseme olacak" }, { "time": 166.20903292561343, "text": "Save your tears, it’ll be okay", "meaning": "Tut gözyaşlarını, her şey yolunda olacak" }, { "time": 178.68805201716614, "text": "Yeah, if with me", "meaning": "Evet, yanımdaysan eğer" }, { "time": 185.11317711253358, "text": "Oh, oh, oh, oh-oh-oh-oh-oh", "meaning": "Ah, ah, ah, ah-ah-ah-ah-ah" }, { "time": 193.43363897329712, "text": "I can’t describe, oh, oh", "meaning": "Ah, ah anlatamıyorum" } ]; 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: 'B7Y4LHbpXv0', // 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); } }