DijiMedu
Diji-Medu
Akıllı Eğitim Stüdyosu
🏠 Ana Sayfa
🎓 Diji-Medu Eğitim Portalı

DijiMedu

İngilizce Öğrenme ve Bireysel Eğitim Koçluğu Sistemi

Kelime Ezber Yarışması! 🧠
Veriler yükleniyor...
Ders Talebi Oluştur! 📅
Kelime Ezber Yarışması! 🧠
İngilizce Seviyeni Test Et! 🎯

Uluslararası CEFR Seviye Sınavı

15 soruluk kapsamlı test ile mevcut dil yeterliliğinizi anında ölçün ve hedefinize özel yol haritanızı keşfedin!

const DENEMELER_GID = "969516335"; const SKILL_COLORS = { vocabulary: "#1D9E75", konusma: "#378ADD", okuma: "#7F77DD", yazma: "#EF9F27", grammar: "#D85A30" }; const SKILL_LABELS = { vocabulary:"Vocabulary", konusma:"Konuşma", okuma:"Okuma", yazma:"Yazma", grammar:"Grammar" }; let currentSection = null; let allData = []; let students = []; let passwords = {}; let unlockedStudents = {}; let activeStudent = null; let activePageTab = "ozet"; let denemelerData = []; // 📚 GÜNCELLENMİŞ KİTAP LİSTESİ const muallimKitapDeposu = { "okul-oncesi": [ { isim: "I'm too ill", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/im-too-ill" }, { isim: "Little Red Riding Hood", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/little-red-riding-hood" }, { isim: "The great race", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/great-race" }, { isim: "Teddy's adventure", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/teddys-adventure" }, { isim: "The princess and the dragon", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/princess-dragon" }, { isim: "What's that noise?", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/whats-noise" }, { isim: "The snowman", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/snowman" } ], "1-sinif": [ { isim: "I'm too ill", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/im-too-ill" }, { isim: "Little Red Riding Hood", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/little-red-riding-hood" }, { isim: "The great race", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/great-race" }, { isim: "Teddy's adventure", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/teddys-adventure" }, { isim: "The princess and the dragon", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/princess-dragon" }, { isim: "What's that noise?", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/whats-noise" }, { isim: "The snowman", link: "https://learnenglishkids.britishcouncil.org/listen-watch/short-stories/snowman" } ], "2-sinif": [ { isim: "Let's Find The Clues", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-1.pdf" }, { isim: "The Kind Cat", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-2.pdf" }, { isim: "The Surprise Birthday Party", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-3.pdf" }, { isim: "The Happy Eid al-Fitr", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-4.pdf" }, { isim: "Where is Mimi?", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-5.pdf" }, { isim: "A lovely Picnic", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-6.pdf" } ], "3-sinif": [ { isim: "Let's Find The Clues", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-1.pdf" }, { isim: "The Kind Cat", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-2.pdf" }, { isim: "The Surprise Birthday Party", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-3.pdf" }, { isim: "The Happy Eid al-Fitr", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-4.pdf" }, { isim: "Where is Mimi?", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-5.pdf" }, { isim: "A lovely Picnic", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-6.pdf" } ], "4-sinif": [ { isim: "Let's Find The Clues", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-1.pdf" }, { isim: "The Kind Cat", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-2.pdf" }, { isim: "The Surprise Birthday Party", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-3.pdf" }, { isim: "The Happy Eid al-Fitr", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-4.pdf" }, { isim: "Where is Mimi?", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-5.pdf" }, { isim: "A lovely Picnic", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-english-year-2-book-6.pdf" } ], "5-sinif": [ { isim: "Where is Robi?", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-5-book-1.pdf" }, { isim: "Little Interviewers", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-5-book-2.pdf" }, { isim: "A Tasty Day At The Festivals", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-5-book-3.pdf" }, { isim: "The Laughter In the Starry Forest", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-5-book-4.pdf" }, { isim: "Back To School", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-5-book-5.pdf" }, { isim: "The Weekend We Won't Forget", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-5-book-6.pdf" }, { isim: "Magical Map", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-5-book-7.pdf" }, { isim: "Our Planet Our Future", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-5-book-8.pdf" } ], "6-sinif": [ { isim: "Harmony Together", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-6-book-1.pdf" }, { isim: "A New Friend", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-6-book-2.pdf" }, { isim: "Dreams And Surprises", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-6-book-3.pdf" }, { isim: "An Adventurous Day", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-6-book-4.pdf" } ], "7-sinif": [ { isim: "Spark Of Curiosity", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-7-book-1.pdf" }, { isim: "Roots And Resets", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-7-book-2.pdf" }, { isim: "Together We Rise", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-7-book-3.pdf" }, { isim: "Mystery Of Lost Light Forest", link: "https://tymm.meb.gov.tr/assets/pdf/hikaye-multi-english-year-7-book-4.pdf" } ] }; // Portal Açılış function portalSec(tur) { if (tur === 'kocluk') { window.location.href = "https://panel.ogretmencocuk.com/kocluk/"; } } function kocModalKapat() { document.getElementById("kocModal").style.display = "none"; } function portalEkraninaDon() { document.getElementById("tracker").style.display = "none"; const welcome = document.getElementById("welcomePortalScreen"); if (welcome) { welcome.style.display = "flex"; welcome.style.opacity = "1"; } currentSection = null; activeStudent = null; } function goHome() { portalEkraninaDon(); } function openSection(section) { currentSection = section; allData = []; students = []; passwords = {}; unlockedStudents = {}; activeStudent = null; const welcome = document.getElementById("welcomePortalScreen"); if (welcome) welcome.style.display = "none"; const tracker = document.getElementById("tracker"); tracker.style.display = "flex"; const headerTitleEl = document.getElementById("header-title"); if (headerTitleEl) headerTitleEl.innerHTML = SECTIONS[section].label; const tabsEl = document.getElementById("tabs"); if (tabsEl) tabsEl.innerHTML = ""; renderTabs(); loadData(); } const parseDateStr = (dStr) => { if (!dStr) return new Date(0); const parts = dStr.split("."); return new Date(parts[2], parts[1] - 1, parts[0]); }; function parseCSV(text) { const lines = text.trim().split("\n"); return lines.map(line => { const cols = []; let cur = "", inQ = false; for (let i = 0; i < line.length; i++) { const ch = line[i]; if (ch === '"') { inQ = !inQ; } else if (ch === ',' && !inQ) { cols.push(cur.trim()); cur = ""; } else { cur += ch; } } cols.push(cur.trim()); return cols; }); } async function loadData() { if (!currentSection || !SECTIONS[currentSection]) return; const gid = SECTIONS[currentSection].gid; const url = `https://docs.google.com/spreadsheets/d/${SHEET_ID}/gviz/tq?tqx=out:csv&gid=${gid}&t=${Date.now()}`; try { const res = await fetch(url); if (!res.ok) throw new Error("HTTP " + res.status); const text = await res.text(); const rows = parseCSV(text); function toNum(v) { return parseFloat((v||"").toString().replace(",",".")) || 0; } allData = rows.slice(1).map(r => ({ tarih: r[0] || "", ogrenci: r[1] || "", seviye: r[2] || "", genel: toNum(r[3]), vocabulary: toNum(r[4]), konusma: toNum(r[5]), okuma: toNum(r[6]), yazma: toNum(r[7]), grammar: toNum(r[8]), deneme: toNum(r[9]), sifre: r[10] ? r[10].trim() : "", ders_tarihi: r[11] || "", ders_durumu: r[12] ? r[12].trim() : "", odev_durumu: r[13] ? r[13].trim() : "", konu: r[14] || "", telefon: r[15] || "", son_kitap_adi: r[16] || "", son_kitap_sayfa: toNum(r[17]), son_kitap_hedef: toNum(r[18]), okunan_kitap_sayisi: toNum(r[19]) })).filter(r => r.ogrenci); passwords = {}; allData.forEach(r => { if (r.sifre) passwords[r.ogrenci] = r.sifre; }); students = [...new Set(allData.map(r => r.ogrenci))]; try { const dUrl = `https://docs.google.com/spreadsheets/d/${SHEET_ID}/gviz/tq?tqx=out:csv&gid=${DENEMELER_GID}&t=${Date.now()}`; const dRes = await fetch(dUrl); const dText = await dRes.text(); const dRows = parseCSV(dText); denemelerData = dRows.slice(1).map(r => ({ tarih: r[0] || "", ogrenci: r[1] || "", deneme_adi: r[2] || "", puan: toNum(r[3]) })).filter(r => r.ogrenci && r.puan > 0); } catch(e) { denemelerData = []; } const lastUp = document.getElementById("last-updated"); if (lastUp) { lastUp.textContent = new Date().toLocaleTimeString("tr-TR", {hour:"2-digit",minute:"2-digit"}); } const kayitliOgrenci = localStorage.getItem('dijimuallim_aktif_ogrenci'); if (kayitliOgrenci && students.find(s => s.toLowerCase() === kayitliOgrenci.toLowerCase())) { const dogruOgrenci = students.find(s => s.toLowerCase() === kayitliOgrenci.toLowerCase()); unlockedStudents[dogruOgrenci] = true; selectStudent(dogruOgrenci); } else { renderTabs(); } } catch(e) { console.error(e); renderTabs(); } } function renderTabs() { const tabsEl = document.getElementById("tabs"); const contentEl = document.getElementById("content"); if (!tabsEl || !contentEl) return; // Giriş yapıldıysa üst şeridi tamamen kaldırıyoruz if (activeStudent && unlockedStudents[activeStudent]) { tabsEl.innerHTML = ""; return; } tabsEl.innerHTML = ""; contentEl.innerHTML = `
🎓

Öğrenci Giriş Portalı

Lütfen sistemde kayıtlı Adınızı ve Soyadınızı, ardından şifrenizi giriniz.

`; } function turkceKucukBuyukDuzelt(metin) { if (!metin) return ""; return metin.toString().trim() .replace(/i/g, 'İ').replace(/ı/g, 'I') .replace(/ğ/g, 'Ğ').replace(/ü/g, 'Ü') .replace(/ş/g, 'Ş').replace(/ö/g, 'Ö') .replace(/ç/g, 'Ç') .toUpperCase(); } function manuelGirisYap() { const girilenIsimRaw = document.getElementById("login-name-input").value; const girilenSifre = document.getElementById("login-pwd-input").value.trim(); const hataAlani = document.getElementById("lock-error"); const temizGirilenIsim = turkceKucukBuyukDuzelt(girilenIsimRaw); if (!temizGirilenIsim) { hataAlani.textContent = "Lütfen adınızı ve soyadınızı giriniz."; return; } if (!students || students.length === 0) { hataAlani.textContent = "Veriler yükleniyor, lütfen 2 saniye sonra tekrar tıklayın..."; return; } const bulunanOgrenci = students.find(s => turkceKucukBuyukDuzelt(s) === temizGirilenIsim); if (!bulunanOgrenci) { hataAlani.textContent = "Bu isimle kayıtlı bir öğrenci bulunamadı."; return; } const dogruSifre = (passwords[bulunanOgrenci] || "").trim(); if (dogruSifre && girilenSifre !== dogruSifre) { hataAlani.textContent = "Şifreniz yanlış, lütfen tekrar deneyin."; document.getElementById("login-pwd-input").value = ""; document.getElementById("login-pwd-input").focus(); return; } unlockedStudents[bulunanOgrenci] = true; localStorage.setItem('dijimuallim_aktif_ogrenci', btoa(bulunanOgrenci)); selectStudent(bulunanOgrenci); } function aktifogrenciyiKapat() { if (activeStudent) { delete unlockedStudents[activeStudent]; } localStorage.removeItem('dijimuallim_aktif_ogrenci'); oturumSayaciniDurdur(); activeStudent = null; renderTabs(); } function esc(s) { return s.replace(/\\/g,"\\\\").replace(/'/g,"\\'"); } function selectStudent(name) { activeStudent = name; activePageTab = "ozet"; renderTabs(); showStudentPage(name); oturumSayaciniBaslat(name); } function showStudentPage(name) { const rows = allData.filter(r => r.ogrenci === name).sort((a,b) => parseDateStr(a.tarih) - parseDateStr(b.tarih)); if (!rows.length) { document.getElementById("content").innerHTML = '
Veri yok.
'; return; } const latest = rows[rows.length-1]; const initials = name.split(" ").map(w=>w[0]).join("").toUpperCase().slice(0,2); const s = esc(name); let pageContent = ""; if (activePageTab === "ozet") pageContent = buildOzet(rows, latest, name, allData); else if (activePageTab === "haftalar") pageContent = buildHaftalar(rows); else if (activePageTab === "denemeler") pageContent = buildDenemeler(name); else if (activePageTab === "kitaplar") pageContent = buildKitaplarTab(); document.getElementById("content").innerHTML = `
${initials}

${name}

Son güncelleme: ${latest.tarih}

${latest.seviye}
⏱️ Uygulamada Geçirilen Oturum Süresi:
00:00:00
🏅 Kazanılan Rozet: 0 🌟 Sonraki rozete: 10 dk
📊 Özet
📝 Ders Raporları
📝 Denemeler
📚 Kitap Oku
${pageContent} `; guncelSayacArayuzunuBas(); if (activePageTab === "ozet") drawCharts(rows); if (activePageTab === "denemeler") drawDenemeChart(name); if (activePageTab === "kitaplar") kitaplariGetir('okul-oncesi', null); } function switchPageTab(name, tab) { activePageTab = tab; showStudentPage(name); } function buildKitaplarTab() { return `
📚 İngilizce Seviye Okuma Kitapları

Sınıf seviyenizi seçerek okuma kitaplarına anında erişebilirsiniz.

`; } function kitaplariGetir(sinifId, buton) { const tumSinifButonlari = document.querySelectorAll("#ogrenciKitapSinifGrid .panel-sinif-btn"); tumSinifButonlari.forEach(b => b.classList.remove("active")); if (buton) { buton.classList.add("active"); } else { tumSinifButonlari.forEach(b => { if (b.getAttribute("onclick") && b.getAttribute("onclick").includes(`'${sinifId}'`)) { b.classList.add("active"); } }); } const container = document.getElementById("muallimKitapListesi"); if (!container) return; container.innerHTML = ""; const kitaplar = (typeof muallimKitapDeposu !== "undefined" && muallimKitapDeposu[sinifId]) ? muallimKitapDeposu[sinifId] : []; if (kitaplar.length === 0) { container.innerHTML = '
Bu seviyeye ait kitaplar yakında yüklenecektir.
'; return; } kitaplar.forEach(k => { const a = document.createElement("a"); a.href = k.link; a.target = "_blank"; a.rel = "noopener noreferrer"; a.className = "muallim-pdf-link"; a.innerText = k.isim; container.appendChild(a); }); } function generateUniqueComment(puan, studentName, latestRow, allRows) { const firstName = studentName.split(" ")[0]; const odev = (latestRow.odev_durumu || "").toLowerCase(); const r = (arr) => arr[Math.floor(Math.random() * arr.length)]; let girisCumlesi = ""; if (puan >= 0 && puan <= 25) { girisCumlesi = r([ `Bu hafta ${firstName} ile henüz motorları ısıtma ve birbirimizi tanıma evresindeyiz. Mevcut puanımız yanıltıcı olmasın; amacımız eksikleri görüp tam da buradan yukarı fırlamak! 🚀`, `${firstName} için bu haftaki tablo, gerçek potansiyelimizin sadece küçük bir uykuda olma hali. Eksiklerimizi tek tek avlayıp çok yakında harika bir ivme yakalayacağız. 💪`, `İlk adımlar her zaman sabır ister. ${firstName} bu hafta enerjisini topladı; önümüzdeki günlerde bu temelin üzerine koyacağımız tuğlaları planladık. ✨` ]); } else if (puan > 25 && puan <= 50) { girisCumlesi = r([ `${firstName} bu hafta çarkları döndürmeye ve gelişim sinyalleri vermeye başladı. Taşlar yerine oturuyor. 📈`, `Güzel bir kımıldanma ve çaba haftasındayız! ${firstName} bazı duvarları yıkmaya başladı. 👣`, `Yetersiz kaldığımız noktalar mevcut ancak ${firstName}'deki o öğrenme isteği ve gelişim kıvılcımı kendini hissettirdi. ⚡` ]); } else if (puan > 50 && puan <= 75) { girisCumlesi = r([ `Gayet iyi, dengeli ve bizi mutlu eden bir haftayı geride bıraktık. ${firstName} standardını koruyor! 🌟`, `${firstName} bu hafta sorumluluklarını güzel yerine getirdi ve iyi bir düzey yakaladı. 💎`, `Çok net bir 'iyi düzey' performans eseri izledik. Ufak dokunuşlarla zirveye oynayacağız. 🎯` ]); } else if (puan > 75 && puan <= 100) { girisCumlesi = r([ `Kelimelerin tam anlamıyla harika, muazzam bir hafta! ${firstName} bu hafta adeta sınıfta devleşti! 🔥`, `Muhteşem bir disiplin ve kusursuz bir performans tablosu! Çıtayı harika bir yere koyduk. 👑`, `Harika iş çıkardık! ${firstName} bu haftanın yıldızı olmayı sonuna kadar hak etti. 🌠` ]); } let haftalikKiyaslama = ""; const studentRows = allRows.filter(r => r.ogrenci === studentName && (r.genel > 0 || r.vocabulary > 0)).sort((a, b) => parseDateStr(a.tarih) - parseDateStr(b.tarih)); if (studentRows.length > 1) { const currentIdx = studentRows.findIndex(r => r.tarih === latestRow.tarih); if (currentIdx > 0) { const prevRow = studentRows[currentIdx - 1]; const fark = Math.round(puan - prevRow.genel); if (fark > 0) { haftalikKiyaslama = ` Geçen haftaki puanına göre genel performansını **+${fark} puan** daha artırarak harika bir sıçrama gerçekleştirdi. 🚀`; } else if (fark < 0) { haftalikKiyaslama = ` Geçen haftaki puanına oranla bu hafta **${fark} puanlık** ufak bir geri çekilme söz konusu. 🔋`; } else { haftalikKiyaslama = ` Geçen haftaki çizgimizi ve istikrarımızı tam puanı puanına koruduk. 🎯`; } } } let taktikNotu = ""; if (odev.includes("yapılmadı") || odev.includes("yok")) { taktikNotu = r([ ` Önümüzdeki süreçte ivme yakalayabilmemiz için ödev disiplinini acilen birinci sıraya koymalıyız.`, ` Bu performansın kalıcı bir başarı hikayesine dönüşmesi için ödevlerin eksiksiz yapılması şart.`, ` Önümüzdeki hafta tempomuzu artırmak adına her gün mutlaka 15-20 dakikalık odaklanmış test çözümü yapmasını tavsiye ediyorum.` ]); } else { taktikNotu = r([ ` Sürecimizi daha da yukarı taşımak adına her akşam mutlaka 10 dakikalık bir "kelime tekrarı" rutini oturtalım.`, ` Yakaladığımız bu güzel ritmi korumak adına boş bıraktığı veya yanlış yaptığı soruları kesip bir "hata defteri" yapmalı.`, ` Ders sonrası tutacağı küçük notlar ve ardından gelecek soru çözümleri, bilgiyi zihninde tamamen kilitleyecektir.` ]); } return `${girisCumlesi}${haftalikKiyaslama}${taktikNotu}`; } function examTag(puan) { if (puan > 85) return { cls: 'tag-green', lbl: 'Muhteşemsin!' }; if (puan > 70) return { cls: 'tag-teal', lbl: 'Böyle Devam' }; if (puan > 50) return { cls: 'tag-amber', lbl: 'Yükselişte' }; return { cls: 'tag-blue', lbl: 'Gelişiyor' }; } function buildBadges(genel, prevGenel, currentStudentName) { const ORIGINAL_BADGES = [ { score:5, emoji:"🌱", label:"Tohum Attı" }, { score:10, emoji:"🐣", label:"Kabuğu Kırdı" }, { score:15, emoji:"🔦", label:"Işığı Gördü" }, { score:20, emoji:"🧩", label:"Parçaları Buldu" }, { score:25, emoji:"🎒", label:"Yola Çıktı" }, { score:30, emoji:"🧭", label:"Yönünü Buldu" }, { score:35, emoji:"⚙️", label:"Motoru Çalıştı" }, { score:40, emoji:"🌊", label:"Dalgayı Aştı" }, { score:45, emoji:"🦋", label:"Kanat Çırptı" }, { score:50, emoji:"🏕️", label:"Yarı Yolda" }, { score:55, emoji:"🔭", label:"Ufku Gördü" }, { score:60, emoji:"⚡", label:"Voltaj Yükseldi" }, { score:65, emoji:"🦅", label:"Süzülüyor" }, { score:70, emoji:"🌋", label:"Zirveye Yakın" }, { score:75, emoji:"🛸", label:"Atmosfer Dışı" }, { score:80, emoji:"💫", label:"Yörüngede" }, { score:85, emoji:"🌠", label:"Kayan Yıldız" }, { score:90, emoji:"🌌", label:"Galaksiye Ulaştı" }, { score:95, emoji:"🔱", label:"Efsaneler Kulübü" }, { score:100,emoji:"🎓", label:"Dili Fethetti" } ]; const BARIS_BADGES = [ { score: 5, emoji: "🟡", label: "Young Boys" }, { score: 10, emoji: "🔵", label: "Dinamo Zagreb" }, { score: 15, emoji: "⚫", label: "PAOK" }, { score: 20, emoji: "🔴", label: "Kızıl Yıldız" }, { score: 25, emoji: "🟢", label: "Celtic" }, { score: 30, emoji: "🟢", label: "Sporting CP" }, { score: 35, emoji: "⚪", label: "Benfica" }, { score: 40, emoji: "🔴", label: "Feyenoord" }, { score: 45, emoji: "⚪", label: "PSV Eindhoven" }, { score: 50, emoji: "⚫", label: "AC Milan" }, { score: 55, emoji: "🩵", label: "Aston Villa" }, { score: 60, emoji: "⚪", label: "Juventus" }, { score: 65, emoji: "🔴", label: "Atletico Madrid" }, { score: 70, emoji: "🔵", label: "Inter Milan" }, { score: 75, emoji: "🟡", label: "B. Dortmund" }, { score: 80, emoji: "🔵", label: "Paris SG" }, { score: 85, emoji: "🔴", label: "Bayern Münih" }, { score: 90, emoji: "🩵", label: "Manchester City" }, { score: 95, emoji: "👑", label: "Real Madrid" }, { score: 100, emoji: "🦁", label: "GALATASARAY" } ]; const MERT_BADGES = [ { score: 5, emoji:"🐌", label:"Gary" }, { score: 10, emoji:"🐷", label:"Porky Pig" }, { score: 15, emoji:"🦀", label:"Bay Yengeç" }, { score: 20, emoji:"🦠", label:"Plankton" }, { score: 25, emoji:"🦆", label:"Daffy Duck" }, { score: 30, emoji:"🐱", label:"Tom" }, { score: 35, emoji:"🐭", label:"Jerry" }, { score: 40, emoji:"🐕", label:"Scooby-Doo" }, { score: 45, emoji:"🦁", label:"Simba" }, { score: 50, emoji:"🐢", label:"Ninja Kaplumbağa" }, { score: 55, emoji:"🐼", label:"Kung Fu Panda" }, { score: 60, emoji:"🤠", label:"Sheriff Woody" }, { score: 65, emoji:"🤖", label:"Buzz Lightyear" }, { score: 70, emoji:"⚡", label:"Pikachu" }, { score: 75, emoji:"🧪", label:"Prof. Utanyum" }, { score: 80, emoji:"🔬", label:"Dexter" }, { score: 85, emoji:"🔥", label:"Charizard" }, { score: 90, emoji:"🧽", label:"Sünger Bob" }, { score: 95, emoji:"👽", label:"Ben 10" }, { score: 100, emoji:"👑", label:"Kral Şakir" } ]; const checkName = (currentStudentName || "").toLowerCase().trim().replace(/ı/g, "i").replace(/ğ/g, "g").replace(/ü/g, "u").replace(/ş/g, "s").replace(/ö/g, "o").replace(/ç/g, "c"); let currentBadgesList = ORIGINAL_BADGES; if (checkName.includes("baris")) currentBadgesList = BARIS_BADGES; else if (checkName.includes("mert")) currentBadgesList = MERT_BADGES; let cardTitle = "🏅 Kazanılan Rozetler"; let progressTextSuffix = "tamamlandı"; const earned = currentBadgesList.filter(b => genel >= b.score); const earnedCount = earned.length; const total = currentBadgesList.length; const pct = Math.round(earnedCount / total * 100); const grid = currentBadgesList.map(b => { const isEarned = genel >= b.score; return `
${b.emoji}
${b.label}
${b.score} p
`; }).join(""); return `
${cardTitle} — ${earnedCount}/${total}
${grid}
%${pct} ${progressTextSuffix}
`; } function buildLessonStatusBox(rows) { if (!rows || !rows.length) return `
📅 Ders Durum Takvimi
Planlanmış veya işlenmiş ders verisi bulunamadı.
`; const lessonRows = rows.filter(r => r && r.ders_tarihi && r.ders_tarihi.trim() !== ""); if (!lessonRows.length) return `
📅 Ders Durum Takvimi
Planlanmış veya işlenmiş ders verisi bulunamadı.
`; let pastLesson = null; let currentLesson = null; let nextLesson = null; lessonRows.forEach(row => { const st = (row.ders_durumu || "").toLowerCase().trim(); if (st === "sonraki" || st === "planlandi" || st === "sonraki ders") nextLesson = row; else if (st === "tamamlandi" || st === "ertelendi" || st === "yapilmadi" || st === "yapilmedi") { pastLesson = currentLesson; currentLesson = row; } }); function getStatusBadge(status) { const st = (status || "").toLowerCase().trim(); if (st === "tamamlandi") return `Tamamlandı`; if (st === "yapilmadi" || st === "yapilmedi") return `Yapılmadı`; if (st === "ertelendi") return `Ertelendi`; return `Sonraki Ders`; } const pastStyle = "background: #FEF9E7; border-color: #F9E79F;"; const currentStatus = currentLesson ? (currentLesson.ders_durumu || "").toLowerCase().trim() : ""; const nextStatus = nextLesson ? (nextLesson.ders_durumu || "").toLowerCase().trim() : ""; const currentStyle = currentStatus === "tamamlandi" ? "background: #E8F8F0; border-color: #A3E4D7;" : "background: #f8f9fa; border-color: #f0f0f0;"; const nextStyle = (nextStatus === "sonraki" || nextStatus === "planlandi" || nextStatus === "sonraki ders" || !nextStatus) ? "background: #FADBD8; border-color: #F5B7B1;" : "background: #f8f9fa; border-color: #f0f0f0;"; return `
📅 Ders Zaman Çizelgesi ve Durumu
Geçen Ders ${pastLesson ? pastLesson.ders_tarihi : "—"} ${pastLesson ? getStatusBadge(pastLesson.ders_durumu) : 'Veri Yok'}
Güncel Ders ${currentLesson ? currentLesson.ders_tarihi : "—"} ${currentLesson ? getStatusBadge(currentLesson.ders_durumu) : 'Veri Yok'}
Gelecek Ders ${nextLesson ? nextLesson.ders_tarihi : "—"} ${nextLesson ? getStatusBadge(nextLesson.ders_durumu) : 'Plan Yok'}
`; } function buildOzet(rows, latest, studentName, allRows) { const scoredRows = rows.filter(r => r.genel > 0 || r.vocabulary > 0 || r.konusma > 0 || r.okuma > 0 || r.yazma > 0 || r.grammar > 0); const latestScored = scoredRows.length > 0 ? scoredRows[scoredRows.length-1] : latest; const prevScored = scoredRows.length > 1 ? scoredRows[scoredRows.length-2] : null; latest = latestScored; const prev = prevScored; function delta(key) { if (!prev) return '—'; const d = Math.round(latest[key]-prev[key]); if (d>0) return `↑ ${d}`; if (d<0) return `↓ ${Math.abs(d)}`; return '→ sabit'; } const skills = ["vocabulary","konusma","okuma","yazma","grammar"]; const skillRows = skills.map(sk => `
${SKILL_LABELS[sk]}${latest[sk]}/100
`).join(""); const dersler = rows.filter(r=>r.ders_durumu); const yapildi = dersler.filter(r=>r.ders_durumu.toLowerCase().trim()==="tamamlandi").length; const yapilmadi = dersler.filter(r=>r.ders_durumu.toLowerCase().trim()==="yapilmadi" || r.ders_durumu.toLowerCase().trim()==="yapilmedi").length; const badgesHtml = buildBadges(latest.genel, prev ? prev.genel : null, studentName); const lessonStatusBoxHtml = buildLessonStatusBox(rows); const teacherComment = generateUniqueComment(latest.genel, studentName, latest, allRows); // Yapay Zeka Gözlem Raporu / Motivasyon Mesajı Üreteci const firstName = studentName.split(" ")[0]; const puanFarki = prev ? latest.genel - prev.genel : latest.genel; let aiMesaj = ""; if (puanFarki >= 0) { aiMesaj = `Harika bir enerjiyle devam ediyorsun ${firstName}! Puanındaki yükseliş ve istikrarın göz kamaştırıyor. Bu tempoyu kaybetmeden zirveye doğru ilerliyoruz! 🚀`; } else { aiMesaj = `Ufak bir puan dalgalanması yaşadık ${firstName}, ancak hiç sorun değil! Eksiklerimizi fırsata çevirip bir sonraki haftada bu farkı çok daha net kapatacağımıza inanıyorum. Asla pes etmek yok, birlikte başaracağız! 💪`; } const aiBannerHtml = `
🤖 Koçluk Asistanı & Gözlem Raporu
${aiMesaj}
`; // 10 saniye sonra banner'ı otomatik gizleme script tetikleyicisi setTimeout(() => { const kutu = document.getElementById("aiAsistanKutusu"); if (kutu) { kutu.style.opacity = "0"; kutu.style.transform = "translateY(-10px)"; setTimeout(() => kutu.style.display = "none", 800); } }, 10000); const ogrenciGecmisi = allData.filter(r => (r.ogrenci || "").toString().trim().toLowerCase() === (latest.ogrenci || "").toString().trim().toLowerCase()); const kitapliSonSatir = [...ogrenciGecmisi].reverse().find(r => r.son_kitap_adi && r.son_kitap_adi !== "Bu hafta henüz kitap tanımlanmadı.") || {}; const vKitapAdi = kitapliSonSatir.son_kitap_adi || "Bu hafta henüz kitap tanımlanmadı."; const vOkunan = parseInt(kitapliSonSatir.son_kitap_sayfa) || 0; const vHedef = parseInt(kitapliSonSatir.son_kitap_hedef) || 100; const vToplam = parseInt(kitapliSonSatir.okunan_kitap_sayisi) || 0; let vYuzde = Math.round((vOkunan / vHedef) * 100); if (vYuzde > 100) vYuzde = 100; if (vYuzde < 0) vYuzde = 0; let vRozetMetni = "🌱 YENİ FİLİZLENEN OKUR"; let vRozetRenk = "#7A7263"; let vKupaEmoji = "📖"; if (vToplam >= 15) { vRozetMetni = "👑 AKADEMİ ELÇİSİ / BİLGİN"; vRozetRenk = "#8E44AD"; vKupaEmoji = "🔮"; } else if (vToplam >= 10) { vRozetMetni = "🏆 Diji-Medu ŞAMPİYON OKURU"; vRozetRenk = "#D35400"; vKupaEmoji = "👑"; } else if (vToplam >= 5) { vRozetMetni = "⚡ HIZLI OKUMA YOLCUSU"; vRozetRenk = "#2980B9"; vKupaEmoji = "🚀"; } else if (vToplam >= 3) { vRozetMetni = "🏅 KİTAP DOSTU"; vRozetRenk = "#27AE60"; vKupaEmoji = "🥈"; } else if (vToplam >= 1) { vRozetMetni = "📚 İLK ADIM KAHRAMANI"; vRozetRenk = "#16A085"; vKupaEmoji = "🥉"; } const kitapTakipPaneliHtml = `
📚

Okuma Kültürü & Odak Takibi

Düzenli okuma, anlama hızını %40 artırır!

${vRozetMetni}
Şu An Okunan Kitap
${vKitapAdi}
Haftalık Hedef İlerlemesi %${vYuzde}
Okunan: ${vOkunan} sayfa Hedef: ${vHedef} sayfa
${vToplam > 0 ? "🏆" : vKupaEmoji} Toplam Bitirilen
${vToplam}
KİTAP SKORU
`; const devamlilikOrani = dersler.length ? Math.round(yapildi/dersler.length*100) : 0; return ` ${aiBannerHtml}
⭐ Genel Puan
${latest.genel}
${delta("genel")}
🚀 Son Deneme
${latest.deneme > 0 ? latest.deneme : "—"}
${delta("deneme")}
🎯 Toplam Başarılı Ders
${yapildi}
${dersler.length} planlı kayıt
🔥 Devam Oranı
${devamlilikOrani}%
${yapilmadi} kaçırıldı

"${teacherComment}"

${lessonStatusBoxHtml} ${badgesHtml} ${kitapTakipPaneliHtml}
Genel gelişim grafiği
Beceri radar grafiği
Beceri alanları
${skillRows}
`; } function drawCharts(rows) { const scoredRows = rows.filter(r => r.genel > 0 || r.vocabulary > 0 || r.konusma > 0 || r.okuma > 0 || r.yazma > 0 || r.grammar > 0); const latest = scoredRows.length > 0 ? scoredRows[scoredRows.length-1] : null; Object.keys(Chart.instances || {}).forEach(key => { try { Chart.instances[key].destroy(); } catch(e) {} }); if (Chart.getChart) { ["chartGenel","chartRadar"].forEach(id => { const existing = Chart.getChart(id); if (existing) existing.destroy(); }); } const ctx1 = document.getElementById("chartGenel"); if (ctx1 && scoredRows.length > 0) { new Chart(ctx1.getContext("2d"), { type: "line", data: { labels: scoredRows.map(r => r.tarih), datasets: [ { label: "Genel", data: scoredRows.map(r => r.genel), borderColor: "#2E5A44", backgroundColor: "rgba(46,90,68,0.1)", tension: 0.3, pointRadius: 4, fill: true, borderWidth: 2 }, { label: "Deneme", data: scoredRows.map(r => r.deneme > 0 ? r.deneme : null), borderColor: "#378ADD", backgroundColor: "transparent", tension: 0.3, pointRadius: 4, borderDash: [5,3], spanGaps: false, borderWidth: 2 } ] }, options: { responsive: true, plugins: { legend: { display: true, position: 'bottom', labels: { font: { size: 11 }, boxWidth: 12, padding: 15 } } }, scales: { y: { min: 0, max: 100, grid: { color: "#f0f0f0" } }, x: { grid: { display: false } } } } }); } const ctx2 = document.getElementById("chartRadar"); if (ctx2 && latest) { new Chart(ctx2.getContext("2d"), { type: "bar", data: { labels: ["Vocabulary", "Konuşma", "Okuma", "Yazma", "Grammar"], datasets: [{ label: "Beceri Puanları", data: [latest.vocabulary, latest.konusma, latest.okuma, latest.yazma, latest.grammar], backgroundColor: ["#1D9E75", "#378ADD", "#7F77DD", "#EF9F27", "#D85A30"], borderRadius: 6 }] }, options: { responsive: true, scales: { y: { min: 0, max: 100, ticks: { stepSize: 20, font: { size: 10 } }, grid: { color: "#f0f0f0" } }, x: { grid: { display: false } } }, plugins: { legend: { display: false } } } }); } } function buildHaftalar(rows) { const sortedRows = rows.filter(r => r.genel > 0 || r.vocabulary > 0 || r.konusma > 0 || r.okuma > 0 || r.yazma > 0 || r.grammar > 0).sort((a, b) => parseDateStr(a.tarih) - parseDateStr(b.tarih)); if (!sortedRows.length) return '
Ders raporu bulunamadı.
'; const statusLabels = { tamamlandi: "Tamamlandı", yapilmadi: "Yapılmadı", yapilmedi: "Yapılmadı", ertelendi: "Ertelendi", sonraki: "Planlandı" }; let htmlResult = `
Ders raporunu incelemek için üzerine tıklayabilirsiniz.
`; for (let i = sortedRows.length - 1; i >= 0; i--) { const currentWeek = sortedRows[i]; const lessonNumber = i + 1; const st = (currentWeek.ders_durumu || "sonraki").toLowerCase().trim(); const weekComment = generateUniqueComment(currentWeek.genel, currentWeek.ogrenci, currentWeek, allData); htmlResult += `
İşlenen Konu
${currentWeek.konu || "Belirtilmemiş"}
Ödev Durumu
${currentWeek.odev_durumu || "Belirtilmemiş"}
🎯 Haftalık Eğitim Stratejisi & Tavsiye:
"${weekComment}"
Vocabulary${currentWeek.vocabulary}
Konuşma${currentWeek.konusma}
Okuma${currentWeek.okuma}
Yazma${currentWeek.yazma}
Grammar${currentWeek.grammar}
`; } return htmlResult; } function buildDenemeler(name) { const sData = denemelerData.filter(r => r.ogrenci === name); if (!sData.length) return '
Henüz deneme sınavı verisi girilmemiş.
'; const tableRows = sData.map((r) => { const t = examTag(r.puan); return `${r.tarih}${r.deneme_adi}${r.puan}${t.lbl}`; }).reverse().join(""); return `
Deneme Sınavları Grafik İvmesi
${tableRows}
TarihDeneme AdıPuanDurum
`; } function drawDenemeChart(name) { const sData = denemelerData.filter(r => r.ogrenci === name); const ctx = document.getElementById("chartDenemelerTab"); if (!ctx || !sData.length) return; new Chart(ctx.getContext("2d"), { type: "line", data: { labels: sData.map(r => r.tarih), datasets: [{ label: "Deneme Puanı", data: sData.map(r => r.puan), borderColor: "#378ADD", backgroundColor: "rgba(55,140,221,0.08)", tension: 0.2, pointRadius: 5, fill: true, pointBackgroundColor: "#378ADD" }] }, options: { responsive: true, plugins: { legend: { display: false } }, scales: { y: { min: 0, max: 100, grid: { color: "#f0f0f0" } }, x: { grid: { display: false } } } } }); } // 🧠 KELİME EZBER YARIŞMASI const kelimeler2 = [ {en:"Hello", tr:"Merhaba"}, {en:"Goodbye", tr:"Hoşça kal"}, {en:"Please", tr:"Lütfen"}, {en:"Thank you", tr:"Teşekkürler"}, {en:"Yes", tr:"Evet"}, {en:"No", tr:"Hayır"}, {en:"Teacher", tr:"Öğretmen"}, {en:"Student", tr:"Öğrenci"}, {en:"School", tr:"Okul"}, {en:"Book", tr:"Kitap"}, {en:"Pencil", tr:"Kalem"}, {en:"Notebook", tr:"Defter"}, {en:"Eraser", tr:"Silgi"}, {en:"Ruler", tr:"Cetvel"}, {en:"Bag", tr:"Çanta"}, {en:"Desk", tr:"Sıra"}, {en:"Chair", tr:"Sandalye"}, {en:"Board", tr:"Tahta"}, {en:"Pen", tr:"Tükenmez Kalem"}, {en:"Okay", tr:"Tamam"}, {en:"Red", tr:"Kırmızı"}, {en:"Blue", tr:"Mavi"}, {en:"Green", tr:"Yeşil"}, {en:"Yellow", tr:"Sarı"}, {en:"Black", tr:"Siyah"}, {en:"White", tr:"Beyaz"}, {en:"Orange", tr:"Turuncu"}, {en:"Pink", tr:"Pembe"}, {en:"Brown", tr:"Kahverengi"}, {en:"Purple", tr:"Mor"}, {en:"One", tr:"Bir"}, {en:"Two", tr:"İki"}, {en:"Three", tr:"Üç"}, {en:"Four", tr:"Dört"}, {en:"Five", tr:"Beş"}, {en:"Six", tr:"Altı"}, {en:"Seven", tr:"Yedi"}, {en:"Eight", tr:"Sekiz"}, {en:"Nine", tr:"Dokuz"}, {en:"Ten", tr:"On"}, {en:"Cat", tr:"Kedi"}, {en:"Dog", tr:"Köpek"}, {en:"Bird", tr:"Kuş"}, {en:"Fish", tr:"Balık"}, {en:"Apple", tr:"Elma"}, {en:"Banana", tr:"Muz"}, {en:"Milk", tr:"Süt"}, {en:"Water", tr:"Su"}, {en:"Ball", tr:"Top"}, {en:"Car", tr:"Araba"} ]; const kelimeler3Ek = [ {en:"Family", tr:"Aile"}, {en:"Father", tr:"Baba"}, {en:"Mother", tr:"Anne"}, {en:"Brother", tr:"Erkek Kardeş"}, {en:"Sister", tr:"Kız Kardeş"}, {en:"Grandmother", tr:"Büyükanne"}, {en:"Grandfather", tr:"Büyükbaba"}, {en:"Baby", tr:"Bebek"}, {en:"Friend", tr:"Arkadaş"}, {en:"Name", tr:"İsim"}, {en:"Head", tr:"Baş / Kafa"}, {en:"Eye", tr:"Göz"}, {en:"Ear", tr:"Kulak"}, {en:"Nose", tr:"Burun"}, {en:"Mouth", tr:"Ağız"}, {en:"Hand", tr:"El"}, {en:"Foot", tr:"Ayak"}, {en:"Leg", tr:"Bacak"}, {en:"Arm", tr:"Kol"}, {en:"Hair", tr:"Saç"}, {en:"Home", tr:"Ev"}, {en:"Room", tr:"Oda"}, {en:"Kitchen", tr:"Mutfak"}, {en:"Bedroom", tr:"Yatak Odası"}, {en:"Bathroom", tr:"Banyo"}, {en:"Living Room", tr:"Oturma Odası"}, {en:"Garden", tr:"Bahçe"}, {en:"Window", tr:"Pencere"}, {en:"Door", tr:"Kapı"}, {en:"Table", tr:"Masa"}, {en:"Happy", tr:"Mutlu"}, {en:"Sad", tr:"Üzgün"}, {en:"Angry", tr:"Kızgın"}, {en:"Tired", tr:"Yorgun"}, {en:"Hungry", tr:"Aç"}, {en:"Thirsty", tr:"Susamış"}, {en:"Big", tr:"Büyük"}, {en:"Small", tr:"Küçük"}, {en:"Good", tr:"İyi"}, {en:"Great", tr:"Harika"}, {en:"Run", tr:"Koşmak"}, {en:"Jump", tr:"Zıplamak"}, {en:"Walk", tr:"Yürümek"}, {en:"Swim", tr:"Yüzmek"}, {en:"Dance", tr:"Dans Etmek"}, {en:"Sing", tr:"Şarkı Söylemek"}, {en:"Fly", tr:"Uçmak"}, {en:"Write", tr:"Yazmak"}, {en:"Read", tr:"Okumak"}, {en:"Sleep", tr:"Uyumak"}, {en:"Elephant", tr:"Fil"}, {en:"Lion", tr:"Aslan"}, {en:"Monkey", tr:"Maymun"}, {en:"Bear", tr:"Ayı"}, {en:"Rabbit", tr:"Tavşan"}, {en:"Mouse", tr:"Fare"}, {en:"Duck", tr:"Ördek"}, {en:"Horse", tr:"At"}, {en:"Cow", tr:"İnek"}, {en:"Sheep", tr:"Koyun"}, {en:"Cake", tr:"Kek"}, {en:"Bread", tr:"Ekmek"}, {en:"Cheese", tr:"Peynir"}, {en:"Egg", tr:"Yumurta"}, {en:"Orange Juice", tr:"Portakal Suyu"}, {en:"Ice Cream", tr:"Dondurma"}, {en:"Pizza", tr:"Pizza"}, {en:"Soup", tr:"Çorba"}, {en:"Toy", tr:"Oyuncak"}, {en:"Doll", tr:"Oyuncak Bebek"}, {en:"Teddy Bear", tr:"Oyuncak Ayı"}, {en:"Kite", tr:"Uçurtma"}, {en:"Plane", tr:"Uçak"}, {en:"Train", tr:"Tren"}, {en:"Bike", tr:"Bisiklet"}, {en:"Boat", tr:"Tekne"}, {en:"Sun", tr:"Güneş"}, {en:"Moon", tr:"Ay (Gökyüzü)"}, {en:"Star", tr:"Yıldız"}, {en:"Tree", tr:"Ağaç"}, {en:"Flower", tr:"Çiçek"}, {en:"Grass", tr:"Çim"}, {en:"Sky", tr:"Gökyüzü"}, {en:"Cloud", tr:"Bulut"}, {en:"Eleven", tr:"On bir"}, {en:"Twelve", tr:"On iki"}, {en:"Thirteen", tr:"On üç"}, {en:"Fourteen", tr:"On dört"}, {en:"Fifteen", tr:"On beş"}, {en:"Sixteen", tr:"On altı"}, {en:"Seventeen", tr:"On yedi"}, {en:"Eighteen", tr:"On sekiz"}, {en:"Nineteen", tr:"On dokuz"}, {en:"Twenty", tr:"Yirmi"}, {en:"Clean", tr:"Temiz"}, {en:"Dirty", tr:"Kirli"}, {en:"Old", tr:"Yaşlı / Eski"}, {en:"Young", tr:"Genç"}, {en:"Fast", tr:"Hızlı"}, {en:"Slow", tr:"Yavaş"} ]; const kelimeler4Ek = [ {en:"Country", tr:"Ülke"}, {en:"Turkey", tr:"Türkiye"}, {en:"England", tr:"İngiltere"}, {en:"Germany", tr:"Almanya"}, {en:"France", tr:"Fransa"}, {en:"Spain", tr:"İspanya"}, {en:"Italy", tr:"İtalya"}, {en:"Japan", tr:"Japonya"}, {en:"Nationality", tr:"Milliyet"}, {en:"Turkish", tr:"Türk"}, {en:"English", tr:"İngiliz"}, {en:"German", tr:"Alman"}, {en:"Map", tr:"Harita"}, {en:"Compass", tr:"Pusula"}, {en:"Flag", tr:"Bayrak"}, {en:"World", tr:"Dünya"}, {en:"North", tr:"Kuzey"}, {en:"South", tr:"Güney"}, {en:"East", tr:"Doğu"}, {en:"West", tr:"Batı"}, {en:"Job", tr:"Meslek"}, {en:"Doctor", tr:"Doktor"}, {en:"Nurse", tr:"Hemşire"}, {en:"Fireman", tr:"İtfaiyeci"}, {en:"Policeman", tr:"Polis"}, {en:"Chef", tr:"Aşçı"}, {en:"Pilot", tr:"Pilot"}, {en:"Farmer", tr:"Çiftçi"}, {en:"Vet", tr:"Veteriner"}, {en:"Singer", tr:"Şarkıcı"}, {en:"Morning", tr:"Sabah"}, {en:"Afternoon", tr:"Öğleden Sonra"}, {en:"Evening", tr:"Akşam"}, {en:"Night", tr:"Gece"}, {en:"Breakfast", tr:"Kahvaltı"}, {en:"Lunch", tr:"Öğle Yemeği"}, {en:"Dinner", tr:"Akşam Yemeği"}, {en:"Tomato", tr:"Domates"}, {en:"Tea", tr:"Çay"}, {en:"Coffee", tr:"Kahve"}, {en:"Juice", tr:"Meyve Suyu"}, {en:"Shirt", tr:"Gömlek"}, {en:"Pants", tr:"Pantolon"}, {en:"Dress", tr:"Elbise"}, {en:"Shoes", tr:"Ayakkabı"}, {en:"Hat", tr:"Şapka"}, {en:"Jacket", tr:"Ceket"}, {en:"Coat", tr:"Mont"}, {en:"Skirt", tr:"Etek"}, {en:"Socks", tr:"Çorap"}, {en:"Summer", tr:"Yaz"}, {en:"Winter", tr:"Kış"}, {en:"Spring", tr:"İlkbahar"}, {en:"Autumn", tr:"Sonbahar"}, {en:"Hot", tr:"Sıcak"}, {en:"Cold", tr:"Soğuk"}, {en:"Sunny", tr:"Güneşli"}, {en:"Rainy", tr:"Yağmurlu"}, {en:"Snowy", tr:"Karlı"}, {en:"Windy", tr:"Rüzgarlı"}, {en:"Science", tr:"Bilim"}, {en:"Experiment", tr:"Deney"}, {en:"Bottle", tr:"Şişe"}, {en:"Glass", tr:"Bardak"}, {en:"Mix", tr:"Karıştırmak"}, {en:"Pour", tr:"Dökmek"}, {en:"Drop", tr:"Damlatan / Düşürmek"}, {en:"Fold", tr:"Katlamak"}, {en:"Paper", tr:"Kağıt"}, {en:"Brush", tr:"Fırça"}, {en:"Paint", tr:"Boya"}, {en:"Guitar", tr:"Gitar"}, {en:"Piano", tr:"Piyano"}, {en:"Flute", tr:"Flüt"}, {en:"Violin", tr:"Keman"}, {en:"Listen", tr:"Dinlemek"}, {en:"Speak", tr:"Konuşmak"}, {en:"Learn", tr:"Öğrenmek"}, {en:"Teach", tr:"Öğretmek"}, {en:"Help", tr:"Yardım Etmek"}, {en:"Ride", tr:"Binmek (Bisiklete/Ata)"}, {en:"Drive", tr:"Araba Sürmek"}, {en:"Climb", tr:"Tırmanmak"}, {en:"Catch", tr:"Yakalamak"}, {en:"Throw", tr:"Atmak / Fırlatmak"}, {en:"Kick", tr:"Tekmelemek"}, {en:"Cook", tr:"Yemek Pişirmek"}, {en:"Wash", tr:"Yıkamak"}, {en:"Brush teeth", tr:"Diş Fırçalamak"}, {en:"Wake up", tr:"Uyanmak"}, {en:"Get up", tr:"Yataktan Kalkmak"}, {en:"Go to bed", tr:"Yatağa Gitmek"}, {en:"Watch TV", tr:"Televizyon İzlemek"}, {en:"Do homework", tr:"Ödev Yapmak"}, {en:"Strong", tr:"Güçlü"}, {en:"Weak", tr:"Zayıf / Güçsüz"}, {en:"Heavy", tr:"Ağır"}, {en:"Light", tr:"Hafif"}, {en:"Short", tr:"Kısa"}, {en:"Tall", tr:"Uzun"} ]; const kelimeler5Ek = [ {en:"Maths", tr:"Matematik"}, {en:"Social Studies", tr:"Sosyal Bilgiler"}, {en:"Physical Education", tr:"Beden Eğitimi"}, {en:"History", tr:"Tarih"}, {en:"Geography", tr:"Coğrafya"}, {en:"Drama", tr:"Tiyatro / Drama"}, {en:"Information Technology", tr:"Bilişim Teknolojileri"}, {en:"Timetable", tr:"Ders Programı"}, {en:"Classroom", tr:"Derslik"}, {en:"Library", tr:"Kütüphane"}, {en:"Canteen", tr:"Kantin"}, {en:"Gym", tr:"Spor Salonu"}, {en:"Illness", tr:"Hastalık"}, {en:"Health", tr:"Sağlık"}, {en:"Flu", tr:"Grip"}, {en:"Cough", tr:"Öksürük"}, {en:"Fever", tr:"Ateş"}, {en:"Headache", tr:"Baş Ağrısı"}, {en:"Toothache", tr:"Diş Ağrısı"}, {en:"Stomachache", tr:"Karın Ağrısı"}, {en:"Backache", tr:"Sırt Ağrısı"}, {en:"Sore throat", tr:"Boğaz Ağrısı"}, {en:"Measles", tr:"Kızamık"}, {en:"Medicine", tr:"İlaç"}, {en:"Pill", tr:"Hap"}, {en:"Syrup", tr:"Şurup"}, {en:"Plaster", tr:"Yara Bandı"}, {en:"Tissue", tr:"Mendil"}, {en:"Hospital", tr:"Hastane"}, {en:"Pharmacy", tr:"Eczane"}, {en:"Need", tr:"İhtiyaç Duymak"}, {en:"Should", tr:"-meli / -malı (Tavsiye)"}, {en:"Movie", tr:"Film"}, {en:"Cinema", tr:"Sinema"}, {en:"Comedy", tr:"Komedi"}, {en:"Horror", tr:"Korku"}, {en:"Cartoon", tr:"Çizgi Film"}, {en:"Animation", tr:"Animasyon"}, {en:"Action", tr:"Aksiyon"}, {en:"Drama", tr:"Dram"}, {en:"Ticket", tr:"Bilet"}, {en:"Character", tr:"Karakter"}, {en:"Brave", tr:"Cesur"}, {en:"Frightening", tr:"Korkutucu"}, {en:"Funny", tr:"Komik"}, {en:"Exciting", tr:"Heyecan Verici"}, {en:"Boring", tr:"Sıkıcı"}, {en:"Honest", tr:"Dürüst"}, {en:"Party", tr:"Parti"}, {en:"Birthday", tr:"Doğum Günü"}, {en:"Invitation", tr:"Davetiye"}, {en:"Guest", tr:"Misafir"}, {en:"Candle", tr:"Mum"}, {en:"Balloon", tr:"Balon"}, {en:"Gift / Present", tr:"Hediye"}, {en:"Clown", tr:"Palyaço"}, {en:"Beverage", tr:"İçecek"}, {en:"Celebrate", tr:"Kutlamak"}, {en:"Join", tr:"Katılmak"}, {en:"Refuse", tr:"Reddetmek"}, {en:"Accept", tr:"Kabul Etmek"}, {en:"Must", tr:"Zorunda Olmak"}, {en:"Shelter", tr:"Barınak"}, {en:"Vet clinic", tr:"Veteriner Kliniği"}, {en:"Puppy", tr:"Yavru Köpek"}, {en:"Kitten", tr:"Yavru Kedi"}, {en:"Adopt", tr:"Sahiplenmek"}, {en:"Bark", tr:"Havlamak"}, {en:"Tail", tr:"Kuyruk"}, {en:"Wing", tr:"Kanat"}, {en:"Claw", tr:"Pençe"}, {en:"Feed", tr:"Beslemek"}, {en:"Examine", tr:"Muayene Etmek"}, {en:"Collect", tr:"Toplamak / Biriktirmek"}, {en:"Hobby", tr:"Hobi"}, {en:"Board game", tr:"Kutu Oyunu"}, {en:"Chess", tr:"Satranç"}, {en:"Puzzle", tr:"Yapboz"}, {en:"Origami", tr:"Kağıt Katlama"}, {en:"Dodgeball", tr:"Yakar Top"}, {en:"Hide and seek", tr:"Saklambaç"}, {en:"Blind man's buff", tr:"Körebe"}, {en:"Hopscotch", tr:"Seksek"}, {en:"Camping", tr:"Kamp Yapma"}, {en:"Fishing", tr:"Balık Tutma"}, {en:"Hiking", tr:"Doğa Yürüyüşü"}, {en:"Tent", tr:"Çadır"}, {en:"Campfire", tr:"Kamp Ateşi"}, {en:"Lake", tr:"Göl"}, {en:"River", tr:"Nehir"}, {en:"Mountain", tr:"Dağ"}, {en:"Forest", tr:"Orman"}, {en:"Compass", tr:"Pusula"}, {en:"Map", tr:"Harita"}, {en:"Tourist", tr:"Turist"}, {en:"Town", tr:"Kasaba"}, {en:"City centre", tr:"Şehir Merkezi"}, {en:"Mosque", tr:"Cami"}, {en:"Museum", tr:"Müze"}, {en:"Bakery", tr:"Fırın"} ]; const kelimeler6Ek = [ {en:"Delicious", tr:"Lezzetli"}, {en:"Nutritious", tr:"Besleyici"}, {en:"Croissant", tr:"Kruvazan"}, {en:"Muffin", tr:"Kek"}, {en:"Olive", tr:"Zeytin"}, {en:"Honey", tr:"Bal"}, {en:"Butter", tr:"Tereyağı"}, {en:"Jam", tr:"Reçel"}, {en:"Pancake", tr:"Krep"}, {en:"Bagel", tr:"Simit"}, {en:"Cereal", tr:"Mısır Gevreği"}, {en:"Sausage", tr:"Sosis"}, {en:"Downtown", tr:"Şehir Merkezi"}, {en:"Skyscraper", tr:"Gökdelen"}, {en:"Traffic jam", tr:"Trafik Sıkışıklığı"}, {en:"Crowded", tr:"Kalabalık"}, {en:"Noisy", tr:"Gürültülü"}, {en:"Quiet", tr:"Sessiz / Sakin"}, {en:"Kiosk", tr:"Büfe"}, {en:"Pedestrian", tr:"Yaya"}, {en:"Street", tr:"Sokak / Cadde"}, {en:"Building", tr:"Bina"}, {en:"Rent", tr:"Kiralamak"}, {en:"Feed the pet", tr:"Evcil Hayvanı Beslemek"}, {en:"Fair", tr:"Lunapark / Fuar"}, {en:"Roller coaster", tr:"Hız Treni"}, {en:"Bumper car", tr:"Çarpışan Araba"}, {en:"Ferris wheel", tr:"Dönme Dolap"}, {en:"Ghost train", tr:"Korku Treni"}, {en:"Carousel", tr:"Atlıkarınca"}, {en:"Thrilling", tr:"Heyecan Dolu"}, {en:"Terrifying", tr:"Dehşet Verici"}, {en:"Vacation", tr:"Tatil"}, {en:"Sightseeing", tr:"Turistik Gezi"}, {en:"Skiing", tr:"Kayak Yapma"}, {en:"Seaside", tr:"Deniz Kenarı"}, {en:"Resort", tr:"Tatil Köyü"}, {en:"Hotel", tr:"Otel"}, {en:"Stay", tr:"Konaklamak"}, {en:"Visit", tr:"Ziyaret Etmek"}, {en:"Traditional", tr:"Geleneksel"}, {en:"Modern", tr:"Modern"}, {en:"Popular", tr:"Popüler"}, {en:"Dangerous", tr:"Tehlikeli"}, {en:"Safe", tr:"Güvenli"}, {en:"Helmet", tr:"Kask"}, {en:"Weather forecast", tr:"Hava Durumu"}, {en:"Temperature", tr:"Sıcaklık"}, {en:"Freezing", tr:"Dondurucu"}, {en:"Lightning", tr:"Şimşek"}, {en:"Thunder", tr:"Gökgürültüsü"}, {en:"Storm", tr:"Fırtına"}, {en:"Hail", tr:"Dolu (Yağış)"}, {en:"Foggy", tr:"Sisli"}, {en:"Anxious", tr:"Endişeli"}, {en:"Scared", tr:"Korkmuş"}, {en:"Fabulous", tr:"Kusursuz / Harika"}, {en:"Moody", tr:"Dengesiz / Huysuz"}, {en:"Sleepy", tr:"Uykulu"}, {en:"Energetic", tr:"Enerjik"}, {en:"Candidate", tr:"Aday"}, {en:"Election", tr:"Seçim"}, {en:"Vote", tr:"Oy Vermek"}, {en:"President", tr:"Başkan"}, {en:"Ballot box", tr:"Seçim Sandığı"}, {en:"Campaign", tr:"Kampanya"}, {en:"Speech", tr:"Konuşma"}, {en:"Support", tr:"Desteklemek"}, {en:"Democracy", tr:"Demokrasi"}, {en:"Fair", tr:"Adil"}, {en:"Law", tr:"Kanun / Yasa"}, {en:"Right", tr:"Hak (İnsan Hakkı)"}, {en:"Occupation", tr:"Meslek"}, {en:"Architect", tr:"Mimar"}, {en:"Engineer", tr:"Mühendis"}, {en:"Lawyer", tr:"Avukat"}, {en:"Dentist", tr:"Diş Hekimi"}, {en:"Tailor", tr:"Terzi"}, {en:"Mechanic", tr:"Tamirci"}, {en:"Hairdresser", tr:"Kuaför"}, {en:"Design", tr:"Tasarlamak"}, {en:"Build", tr:"İnşa Etmek"}, {en:"Repair", tr:"Tamir Etmek"}, {en:"Sew", tr:"Dikiş Dikmek"}, {en:"Defend", tr:"Savunmak"}, {en:"Pull out teeth", tr:"Diş Çekmek"}, {en:"Salary", tr:"Maaş"}, {en:"Retire", tr:"Emekli Olmak"}, {en:"Yesterday", tr:"Dün"}, {en:"Last week", tr:"Geçen Hafta"}, {en:"Ago", tr:"Önce"}, {en:"Discovered", tr:"Keşfetti"}, {en:"Invented", tr:"İcat Etti"}, {en:"Produced", tr:"Üretti"}, {en:"Painted", tr:"Boyadı / Resmetti"}, {en:"Sold", tr:"Sattı"}, {en:"Bought", tr:"Satın Aldı"}, {en:"Found", tr:"Buldu"}, {en:"Left", tr:"Ayrıldı / Terk Etti"}, {en:"Arrived", tr:"Vardı / Ulaştı"} ]; const kelimeler7Ek = [ {en:"Stubborn", tr:"İnatçı"}, {en:"Selfish", tr:"Bencil"}, {en:"Punctual", tr:"Dakik"}, {en:"Generous", tr:"Cömert"}, {en:"Helpful", tr:"Yardımsever"}, {en:"Outgoing", tr:"Sosyal / Dışadönük"}, {en:"Patient", tr:"Sabırlı"}, {en:"Clumsy", tr:"Sakar"}, {en:"Forgetful", tr:"Unutkan"}, {en:"Easy-going", tr:"Uyumlu / Rahat"}, {en:"Hardworking", tr:"Çalışkan"}, {en:"Lazy", tr:"Tembel"}, {en:"Smart / Clever", tr:"Akıllı"}, {en:"Shy", tr:"Utangaç"}, {en:"Cute", tr:"Sevimli"}, {en:"Handsome", tr:"Yakışıklı"}, {en:"Beautiful", tr:"Güzel"}, {en:"Plump", tr:"Balık Etli"}, {en:"Slim", tr:"Zayıf / İnce"}, {en:"Weight", tr:"Kilo"}, {en:"Height", tr:"Boy"}, {en:"Medal", tr:"Madalya"}, {en:"Equipment", tr:"Ekipman"}, {en:"Court", tr:"Kort / Saha"}, {en:"Pitch", tr:"Futbol Sahası"}, {en:"Score", tr:"Skor"}, {en:"Goal", tr:"Gol / Hedef"}, {en:"Beat", tr:"Yenmek"}, {en:"Draw", tr:"Berabere Kalmak"}, {en:"Train", tr:"Antrenman Yapmak"}, {en:"Spectator", tr:"Seyirci"}, {en:"Success", tr:"Başarı"}, {en:"Award", tr:"Ödül"}, {en:"Biography", tr:"Biyografi"}, {en:"Born", tr:"Doğmuş"}, {en:"Die", tr:"Ölmek"}, {en:"Marriage", tr:"Evlilik"}, {en:"Graduate", tr:"Mezun Olmak"}, {en:"Career", tr:"Kariyer"}, {en:"Prize", tr:"Ödül"}, {en:"Wild", tr:"Vahşi"}, {en:"Domestic", tr:"Evcil"}, {en:"Herbivore", tr:"Otobur"}, {en:"Carnivore", tr:"Etobur"}, {en:"Jungle", tr:"Balta Girmemiş Orman"}, {en:"Desert", tr:"Çöl"}, {en:"Ocean", tr:"Okyanus"}, {en:"Habitat", tr:"Doğal Yaşam Alanı"}, {en:"Extinct", tr:"Nesli Tükenmiş"}, {en:"Endangered", tr:"Nesli Tehlikede"}, {en:"Protect", tr:"Korumak"}, {en:"Hunt", tr:"Avlanmak"}, {en:"Poisonous", tr:"Zehirli"}, {en:"Mammal", tr:"Memeli"}, {en:"Reptile", tr:"Sürüngen"}, {en:"Prey", tr:"Av"}, {en:"Predator", tr:"Yırtıcı Hayvan"}, {en:"Television", tr:"Televizyon"}, {en:"Reality show", tr:"Gerçeklik Programı"}, {en:"Documentary", tr:"Belgesel"}, {en:"News", tr:"Haberler"}, {en:"Soap opera", tr:"Pembe Dizi"}, {en:"Quiz show", tr:"Yarışma Programı"}, {en:"Commercial", tr:"Reklam"}, {en:"Series", tr:"Dizi"}, {en:"Remote control", tr:"Uzaktan Kumanda"}, {en:"Director", tr:"Yönetmen"}, {en:"Audience", tr:"İzleyici"}, {en:"Recommend", tr:"Tavsiye Etmek"}, {en:"Prefer", tr:"Tercih Etmek"}, {en:"Environment", tr:"Çevre"}, {en:"Pollution", tr:"Kirlilik"}, {en:"Recycling", tr:"Geri Dönüşüm"}, {en:"Rubbish / Trash", tr:"Çöp"}, {en:"Global warming", tr:"Küresel Isınma"}, {en:"Solar energy", tr:"Güneş Enerjisi"}, {en:"Wind energy", tr:"Rüzgar Enerjisi"}, {en:"Save energy", tr:"Enerji Tasarrufu"}, {en:"Waste", tr:"İsraf Etmek"}, {en:"Plant a tree", tr:"Ağaç Dikmek"}, {en:"Fortune teller", tr:"Falcı"}, {en:"Horoscope", tr:"Burç / Yıldız Haritası"}, {en:"Lucky", tr:"Şanslı"}, {en:"Unlucky", tr:"Şanssız"}, {en:"Believe", tr:"İnanmak"}, {en:"Predict", tr:"Tahmin Etmek"}, {en:"Future", tr:"Gelecek"}, {en:"Dream", tr:"Rüya / Hayal"}, {en:"Probably", tr:"Muhtemelen"}, {en:"Definitely", tr:"Kesinlikle"}, {en:"Superstition", tr:"Batıl İnanç"}, {en:"Evil eye", tr:"Nazar Boncuğu"}, {en:"Four-leaf clover", tr:"Dört Yapraklı Yonca"}, {en:"Public building", tr:"Kamu Binası"}, {en:"Police station", tr:"Karakol"}, {en:"Fire station", tr:"İtfaiye"}, {en:"Post office", tr:"Postane"}, {en:"City hall", tr:"Belediye Binası"}, {en:"Art gallery", tr:"Sanat Galerisi"}, {en:"Governor", tr:"Vali"} ]; const kelimeler8Ek = [ {en:"Buddy / Mate", tr:"Kanka / Yakın Arkadaş"}, {en:"Count on", tr:"Güvenmek"}, {en:"Depend on", tr:"Bel Bağlamak"}, {en:"Back up", tr:"Desteklemek"}, {en:"Trust", tr:"Güvenmek"}, {en:"Unreliable", tr:"Güvenilmez"}, {en:"Arrogant", tr:"Kibirli / Ukala"}, {en:"Sneaky", tr:"Sinsi"}, {en:"Loyal", tr:"Sadık"}, {en:"Secret", tr:"Sır"}, {en:"Share", tr:"Paylaşmak"}, {en:"Argue", tr:"Tartışmak"}, {en:"Jealous", tr:"Kıskanç"}, {en:"Tactful", tr:"Anlayışlı / İnce Düşünceli"}, {en:"Caring", tr:"Şefkatli / İlgili"}, {en:"Amusing", tr:"Eğlenceli"}, {en:"Supportive", tr:"Destekleyici"}, {en:"Fair", tr:"Adil"}, {en:"Aggressive", tr:"Saldırgan"}, {en:"Adventurous", tr:"Maceracı"}, {en:"Fashionable", tr:"Modaya Uygun"}, {en:"Ridiculous", tr:"Gülünç / Saçma"}, {en:"Unbearable", tr:"Katlanılmaz / Çekilmez"}, {en:"Impressive", tr:"Etkileyici"}, {en:"Trendy", tr:"Trend / Popüler"}, {en:"Awesome", tr:"Harika / Müthiş"}, {en:"Attract", tr:"Cezbetmek / Çekmek"}, {en:"Backer", tr:"Destekçi"}, {en:"Chit-chat", tr:"Sohbet Etmek / Geyik Yapmak"}, {en:"Bake", tr:"Fırında Pişirmek"}, {en:"Grill", tr:"Izgarada Pişirmek"}, {en:"Fry", tr:"Yağda Kızartmak"}, {en:"Boil", tr:"Haşlamak / Kaynatmak"}, {en:"Steam", tr:"Buharda Pişirmek"}, {en:"Roast", tr:"Fırında Et Kızartmak"}, {en:"Chop", tr:"Doğramak"}, {en:"Slice", tr:"Dilimlemek"}, {en:"Dice", tr:"Küp Küp Doğramak"}, {en:"Peel", tr:"Kabuğunu Soymak"}, {en:"Grate", tr:"Rendelemek"}, {en:"Mash", tr:"Ezmek / Püre Yapmak"}, {en:"Pour", tr:"Dökmek"}, {en:"Whisk", tr:"Çırpmak"}, {en:"Knead", tr:"Yoğurmak"}, {en:"Squeeze", tr:"Sıkmak (Limon vb.)"}, {en:"Spread", tr:"Sürmek (Yağ vb.)"}, {en:"Ingredient", tr:"İçindekiler / Malzeme"}, {en:"Process", tr:"Aşama / Süreç"}, {en:"Recipe", tr:"Yemek Tarifi"}, {en:"Kitchenware", tr:"Mutfak Eşyası"}, {en:"Pan", tr:"Tava"}, {en:"Pot", tr:"Tencere"}, {en:"Bowl", tr:"Kase"}, {en:"Knife", tr:"Bıçak"}, {en:"Spoon", tr:"Kaşık"}, {en:"Fork", tr:"Çatal"}, {en:"Oven", tr:"Fırın"}, {en:"Communicate", tr:"İletişim Kurmak"}, {en:"Interaction", tr:"Etkileşim"}, {en:"Face to face", tr:"Yüz Yüze"}, {en:"Call", tr:"Telefonla Aramak"}, {en:"Text", tr:"Mesaj Yazmak"}, {en:"Dial", tr:"Numara Çevirmek"}, {en:"Hang up", tr:"Telefonu Kapatmak"}, {en:"Hold on", tr:"Hatta Beklemek"}, {en:"Leave a message", tr:"Mesaj Bırakmak"}, {en:"Available", tr:"Müsait / Uygun"}, {en:"Busy", tr:"Meşgul"}, {en:"Connection", tr:"Bağlantı"}, {en:"Online", tr:"Çevrimiçi"}, {en:"Offline", tr:"Çevrimdışı"}, {en:"Browsing", tr:"İnternette Gezinme"}, {en:"Search engine", tr:"Arama Motoru"}, {en:"Website", tr:"Web Sitesi"}, {en:"Account", tr:"Hesap"}, {en:"Password", tr:"Şifre / Parola"}, {en:"Log in", tr:"Giriş Yapmak"}, {en:"Log out", tr:"Çıkış Yapmak"}, {en:"Download", tr:"İndirmek"}, {en:"Upload", tr:"Yüklemek"}, {en:"Attachment", tr:"E-posta Eki"}, {en:"Update", tr:"Güncellemek"}, {en:"Delete", tr:"Silmek"}, {en:"Social media", tr:"Sosyal Medya"}, {en:"Addict", tr:"Bağımlı"}, {en:"Device", tr:"Cihaz / Alet"}, {en:"Subscriber", tr:"Abone"}, {en:"Extreme sports", tr:"Ekstrem Sporlar"}, {en:"Risk", tr:"Risk"}, {en:"Danger", tr:"Tehlike"}, {en:"Courage", tr:"Cesaret"}, {en:"Life jacket", tr:"Can Yeleği"}, {en:"Paragliding", tr:"Yamaç Paraşütü"}, {en:"Bungee jumping", tr:"İpten Atlama"}, {en:"Rafting", tr:"Debili Suda Bot Turu"}, {en:"Climbing", tr:"Kaya Tırmanışı"}, {en:"Diving", tr:"Dalış"}, {en:"Trekking", tr:"Doğa Yürüyüşü"}, {en:"Accommodation", tr:"Konaklama"}, {en:"All-inclusive", tr:"Her Şey Dahil"} ]; const ezberKelimeDeposu = { "2-sinif": kelimeler2, "3-sinif": kelimeler3Ek, "4-sinif": kelimeler4Ek, "5-sinif": kelimeler5Ek, "6-sinif": kelimeler6Ek, "7-sinif": kelimeler7Ek, "8-sinif": kelimeler8Ek }; const SINIF_SORU_LIMITLERI = { "2-sinif": 20, "3-sinif": 20, "4-sinif": 20, "5-sinif": 25, "6-sinif": 30, "7-sinif": 35, "8-sinif": 40 }; let aktifSinif = "2-sinif"; let oyunKelimeListesi = []; let mevcutKelimeIndex = 0; let mevcutKelimeNesnesi = null; let dogruSkor = 0; let yanlisSkor = 0; let ezberSaniye = 0; let ezberKronometreInterval = null; let ezberKullanici = ""; let ezberMuzikCalisiyor = true; let cevapKilitli = false; function ezberKartToggle() { const icerik = document.getElementById("ezberKartIcerik"); const ok = document.getElementById("ezberOkIsareti"); const kutu = document.getElementById("ezberKareKutu"); if (icerik.style.display === "none") { icerik.style.display = "block"; if (kutu) kutu.classList.add("active"); if (ok) ok.innerText = "🔼"; ezberYenidenBaslat(); } else { icerik.style.display = "none"; if (kutu) kutu.classList.remove("active"); if (ok) ok.innerText = "🔽"; clearInterval(ezberKronometreInterval); try { const m = document.getElementById("ezberMuzik"); if (m) m.pause(); } catch(e) {} } } function ezberSinifSec(sinifId, buton) { if(buton) { document.querySelectorAll('#ezberGirisEkrani .panel-sinif-btn').forEach(b => b.classList.remove('active')); buton.classList.add('active'); } aktifSinif = sinifId; } function ezberSesKontrol() { const muzik = document.getElementById("ezberMuzik"); const btn = document.getElementById("ezberSesBtn"); if (!muzik) return; if (muzik.paused) { muzik.play().then(() => { btn.innerText = "🔊"; btn.style.background = "#e8f0fe"; ezberMuzikCalisiyor = true; }).catch(err => console.log(err)); } else { muzik.pause(); btn.innerText = "🔇"; btn.style.background = "#fad4d1"; ezberMuzikCalisiyor = false; } } function ezberSistemiBaslat() { const isimInput = document.getElementById("ezberOgrenciAdi").value.trim(); ezberKullanici = isimInput === "" ? "Gizemli Oyuncu" : isimInput; let sinifKelimeleri = ezberKelimeDeposu[aktifSinif] || ezberKelimeDeposu["2-sinif"]; let havuzKopyasi = [...sinifKelimeleri]; havuzKopyasi.sort(() => Math.random() - 0.5); let hedefLimit = SINIF_SORU_LIMITLERI[aktifSinif] || 20; oyunKelimeListesi = havuzKopyasi.slice(0, Math.min(hedefLimit, havuzKopyasi.length)); dogruSkor = 0; yanlisSkor = 0; mevcutKelimeIndex = 0; ezberSaniye = 0; cevapKilitli = false; document.getElementById("ezberDogruSayisi").innerText = "0"; document.getElementById("ezberYanlisSayisi").innerText = "0"; document.getElementById("ezberKronometre").innerText = "⏱️ 00:00"; document.getElementById("ezberGirisEkrani").style.display = "none"; document.getElementById("ezberSonucEkrani").style.display = "none"; document.getElementById("ezberOyunEkrani").style.display = "block"; clearInterval(ezberKronometreInterval); ezberKronometreInterval = setInterval(() => { ezberSaniye++; let dk = Math.floor(ezberSaniye / 60); let sn = ezberSaniye % 60; document.getElementById("ezberKronometre").innerText = "⏱️ " + (dk < 10 ? "0" : "") + dk + ":" + (sn < 10 ? "0" : "") + sn; }, 1000); const muzik = document.getElementById("ezberMuzik"); if (muzik) { muzik.currentTime = 0; muzik.volume = 0.35; muzik.play().catch(e => console.log("Müzik uyarısı")); } ezberKelimeCek(); } function ezberKelimeCek() { if (!oyunKelimeListesi || oyunKelimeListesi.length === 0 || !oyunKelimeListesi[mevcutKelimeIndex]) return; cevapKilitli = false; mevcutKelimeNesnesi = oyunKelimeListesi[mevcutKelimeIndex]; document.getElementById("ezberProgress").innerText = `Kelime: ${mevcutKelimeIndex + 1} / ${oyunKelimeListesi.length}`; document.getElementById("ezberIngilizceKelime").innerText = mevcutKelimeNesnesi.en; let sinifKelimeleri = ezberKelimeDeposu[aktifSinif] || kelimeler2; let digerKelimeler = sinifKelimeleri.filter(k => k.tr !== mevcutKelimeNesnesi.tr); let yanlisKelime = digerKelimeler[Math.floor(Math.random() * digerKelimeler.length)]; let secenekler = [ { metin: mevcutKelimeNesnesi.tr, dogruMu: true }, { metin: yanlisKelime ? yanlisKelime.tr : "Farklı Anlam", dogruMu: false } ]; secenekler.sort(() => Math.random() - 0.5); let siklarHTML = ""; secenekler.forEach(s => { siklarHTML += ``; }); document.getElementById("ezberSiklarAlani").innerHTML = siklarHTML; } function ezberSikSecildi(btnElement, dogruMu) { if (cevapKilitli) return; cevapKilitli = true; if (dogruMu) { dogruSkor++; document.getElementById("ezberDogruSayisi").innerText = dogruSkor; btnElement.classList.add("dogru-anim"); } else { yanlisSkor++; document.getElementById("ezberYanlisSayisi").innerText = yanlisSkor; btnElement.classList.add("yanlis-anim"); document.querySelectorAll(".ezber-sik-btn").forEach(b => { if (b.innerText.trim() === mevcutKelimeNesnesi.tr.trim()) b.classList.add("dogru-anim"); }); } setTimeout(() => { mevcutKelimeIndex++; if (mevcutKelimeIndex < oyunKelimeListesi.length) ezberKelimeCek(); else ezberTurBitir(); }, 450); } function ezberTurBitir() { clearInterval(ezberKronometreInterval); try { const muzik = document.getElementById("ezberMuzik"); if (muzik) muzik.pause(); } catch(e) {} document.getElementById("ezberOyunEkrani").style.display = "none"; document.getElementById("ezberSonucEkrani").style.display = "block"; const toplamSoru = (oyunKelimeListesi && oyunKelimeListesi.length > 0) ? oyunKelimeListesi.length : 20; let finalPuan = Math.round((dogruSkor / toplamSoru) * 100); let dk = Math.floor(ezberSaniye / 60); let sn = ezberSaniye % 60; let formatliSure = (dk < 10 ? "0" : "") + dk + ":" + (sn < 10 ? "0" : "") + sn; document.getElementById("sonucPuan").innerText = finalPuan; document.getElementById("sonucZaman").innerText = formatliSure; document.getElementById("ezberLiderlikGövdesi").innerHTML = 'Skorun Google Sheets tablosuna kaydediliyor... ⏳'; const postData = { aksiyon: "ezberKaydet", isim: ezberKullanici, sinif: aktifSinif, dogru: dogruSkor, yanlis: yanlisSkor, sure: formatliSure, sureSaniye: ezberSaniye, puan: finalPuan }; fetch(WEB_APP_URL, { method: "POST", headers: { "Content-Type": "text/plain;charset=utf-8" }, body: JSON.stringify(postData) }) .then(res => res.json()) .then(data => { if(data && data.durum === "basarili" && data.liderlikTablosu) { ezberLiderlikTablosuBas(data.liderlikTablosu); } else { document.getElementById("ezberLiderlikGövdesi").innerHTML = 'Kayıt yapıldı ancak tablo verisi okunamadı.'; } }).catch(err => { console.error("Liderlik tablosu hatası:", err); document.getElementById("ezberLiderlikGövdesi").innerHTML = 'Sunucu bağlantı hatası oluştu.'; }); } function ezberLiderlikTablosuBas(veriler) { var govde = document.getElementById("ezberLiderlikGövdesi"); govde.innerHTML = ""; var filtrelenmis = (veriler || []).filter(l => l.sinif === aktifSinif); filtrelenmis.sort((a, b) => { if(b.puan !== a.puan) return b.puan - a.puan; return a.sureSaniye - b.sureSaniye; }); var top10 = filtrelenmis.slice(0, 10); if(top10.length === 0) { govde.innerHTML = 'Henüz bu sınıfta sıralama yok. İlk sen ol!'; return; } top10.forEach((r, idx) => { var madalya = (idx + 1).toString(); var arkaPlan = ""; if(idx === 0) { madalya = "🥇"; arkaPlan = "background:#fff9c4; font-weight:bold;"; } else if(idx === 1) { madalya = "🥈"; arkaPlan = "background:#f5f5f5;"; } else if(idx === 2) { madalya = "🥉"; arkaPlan = "background:#efebe9;"; } govde.innerHTML += '' + '' + madalya + '' + '' + r.isim + '' + '' + r.dogru + '' + '' + r.sure + '' + '' + r.puan + '' + ''; }); } function ezberYenidenBaslat() { clearInterval(ezberKronometreInterval); try { const muzik = document.getElementById("ezberMuzik"); if (muzik) muzik.pause(); } catch(e) {} document.getElementById("ezberOyunEkrani").style.display = "none"; document.getElementById("ezberSonucEkrani").style.display = "none"; document.getElementById("ezberGirisEkrani").style.display = "block"; } const hamSoruHavuzu = [ { type: "image", mediaUrl: "https://raw.githubusercontent.com/newteacherboy/english-tracker/refs/heads/main/gorsel1.png", q: "Look at the picture. What is the person doing at the moment?", a: ["She is preparing a traditional dinner in the kitchen.", "She is working on his laptop and writing some notes.", "She is buying a new tablet from the tech store.", "She is waiting for a bus to go to the city center."], c: 1, lvl: "A1 - Visual Vocabulary" }, { type: "image", mediaUrl: "https://raw.githubusercontent.com/newteacherboy/english-tracker/refs/heads/main/gorsel2.png", q: "Imagine you are at the terminal and you see this screen. What information can you get from it?", a: ["The price of a round-trip ticket to London.", "The exact weight of your luggage.", "The departure times and gate numbers of flights.", "The current weather conditions in Oxford."], c: 2, lvl: "A2 - Information Reading" }, { type: "image", mediaUrl: "https://raw.githubusercontent.com/newteacherboy/english-tracker/refs/heads/main/gorsel3.png", q: "Look at the traffic sign in the picture. Which of the following is CORRECT?", a: ["Drivers are allowed to park their cars here overnight.", "Drivers must not exceed the maximum speed limit shown.", "The road is completely closed due to maintenance.", "Pedestrians have the absolute right of way here."], c: 1, lvl: "B1 - Sign Analysis" }, { type: "audio", mediaUrl: "ses1.mp3", q: "Listen to the speaker talking about his daily routine. What time does he usually have breakfast?", a: ["At quarter to seven in the morning.", "Right after he leaves the office.", "At half past eight with his parents.", "He prefers to skip breakfast on weekdays."], c: 2, lvl: "A1 - Listening Routine" }, { type: "audio", mediaUrl: "ses2.mp3", q: "Listen to the audio presentation. What will the weather be like in the northern area tomorrow afternoon?", a: ["Unseasonably warm and completely dry.", "Rainy with a strong chance of thunderstorms.", "Clear enough for a family picnic.", "Snowy and freezing throughout the day."], c: 1, lvl: "A2 - Listening Weather" }, { type: "audio", mediaUrl: "ses3.mp3", q: "Listen to the phone conversation. Why is the woman calling the customer service center?", a: ["To complain about a broken tablet adapter.", "To change the date of her private coaching session.", "To ask for a discount on a long-sleeve shirt.", "To report a technical bug on the exam portal."], c: 1, lvl: "B1 - Listening Management" }, { type: "audio", mediaUrl: "ses4.mp3", q: "Listen to the educational coordinator's interview. What is her main argument regarding language acquisition?", a: ["Grammar structures must be memorized before practicing listening.", "Continuous exposure to authentic media accelerates fluency significantly.", "Passing international placement tests is the only proof of success.", "Vocabulary lists are completely useless for high school students."], c: 1, lvl: "B2 - Advanced Listening" }, { type: "text", mediaUrl: "", q: "My sister _______ a book in her room at the moment, so please be quiet.", a: ["reads", "is reading", "read", "has read"], c: 1, lvl: "A1 - Grammar Structure" }, { type: "text", mediaUrl: "", q: "We _______ each other since we were in the same primary school classroom.", a: ["know", "are knowing", "have known", "knew"], c: 2, lvl: "A2 - Tense Structure" }, { type: "text", mediaUrl: "", q: "If our team _______ the national science project last week, we would be in London now.", a: ["won", "had won", "would win", "wins"], c: 1, lvl: "B1 - Conditionals" }, { type: "text", mediaUrl: "", q: "Little _______ know that the exam coordinator had already changed the schedule.", a: ["I did", "did I", "I had", "had I"], c: 1, lvl: "B2 - Inversion Structures" }, { type: "text", mediaUrl: "", q: "Kevin: Are you coming to the study group tonight?\nSarah: I'd love to, but I have to finish my vocabulary assignment.\nKevin: _______\nSarah: Thanks! That would actually help a lot.", a: ["I think you should go to sleep early.", "I can help you with it if you want.", "The assignment was extremely difficult.", "I have already failed that test."], c: 1, lvl: "A2 - Dialogue Completion" }, { type: "text", mediaUrl: "", q: "\"Online learning platforms offer flexibility for students who manage busy schedules. However, without high personal motivation and strict time management, it is very easy to fall behind the curriculum.\"\n\nAccording to the text, what is the main risk of online learning?", a: ["The high cost of technical digital equipment.", "The lack of high-quality educational materials.", "Falling behind due to poor motivation or time control.", "Not being able to communicate with the online tutor."], c: 2, lvl: "B1 - Text Comprehension" }, { type: "text", mediaUrl: "", q: "Despite the severe weather conditions and the sudden cancellation of flights, _______.", a: ["the students preferred to stay at the luxury resort hotel", "the academic coordinator managed to arrive at the seminar on time", "because they forgot to check the official announcement page", "which made it impossible for anyone to join the English camp"], c: 1, lvl: "B2 - Sentence Matching" }, { type: "text", mediaUrl: "", q: "The teacher's primary goal is to _______ a love for reading and critical thinking in his students from an early age.", a: ["cultivate", "neglect", "artificial", "abolish"], c: 0, lvl: "B2 - Advanced Vocabulary" } ]; let aktifSoruBankasi = []; let ogrenciCevaplari = Array(15).fill(null); let pointerSoru = 0; let ogrenciIsmi = ""; let nihaiSeviyeSonucu = ""; let nihaiDogruSayisi = 0; let nihaiYanlisSayisi = 0; function seviyeTestiKutusuAc() { const alan = document.getElementById("seviyeTestAlani"); if(alan.style.display === "none" || alan.style.display === "") { alan.style.display = "flex"; } else { alan.style.display = "none"; } } function testiBaslat() { const inputIsim = document.getElementById("testOgrenciIsim").value.trim(); if(!inputIsim) { alert("Lütfen adınızı ve soyadınızı giriniz."); return; } ogrenciIsmi = inputIsim; aktifSoruBankasi = [...hamSoruHavuzu]; for (let i = aktifSoruBankasi.length - 1; i > 0; i--) { const j = Math.floor(Math.random() * (i + 1)); [aktifSoruBankasi[i], aktifSoruBankasi[j]] = [aktifSoruBankasi[j], aktifSoruBankasi[i]]; } document.getElementById("testGirisEkrani").style.display = "none"; document.getElementById("testSoruEkrani").style.display = "block"; pointerSoru = 0; ogrenciCevaplari = Array(15).fill(null); dinamikSoruGoster(); } function dinamikSoruGoster() { if(pointerSoru >= aktifSoruBankasi.length) { nihaiSorguKapat(); return; } const veri = aktifSoruBankasi[pointerSoru]; document.getElementById("soruNumarasi").innerText = `Soru: ${pointerSoru + 1}/${aktifSoruBankasi.length}`; document.getElementById("soruSeviyeEtiket").innerText = veri.lvl; document.getElementById("soruMetni").innerText = veri.q; const gb = document.getElementById("anlikGeribildirim"); gb.style.display = "none"; const gKutu = document.getElementById("soruGorselKutusu"); if(veri.type === "image") { document.getElementById("soruGorsel").src = veri.mediaUrl; gKutu.style.display = "block"; } else { gKutu.style.display = "none"; } const sKutu = document.getElementById("soruSesKutusu"); const oynatici = document.getElementById("soruSesOynatici"); if(veri.type === "audio") { oynatici.src = veri.mediaUrl; oynatici.load(); sKutu.style.display = "block"; } else { oynatici.pause(); sKutu.style.display = "none"; } const sAlan = document.getElementById("seceneklerAlani"); sAlan.innerHTML = ""; veri.a.forEach((alternatif, i) => { let ekStil = ""; if (ogrenciCevaplari[pointerSoru] !== null) { if (i === veri.c) ekStil = "background: #C2E0CC; border-color: #2E5A44; font-weight: bold; color: #2E5A44;"; else if (i === ogrenciCevaplari[pointerSoru]) ekStil = "background: #FADBD8; border-color: #E74C3C; color: #E74C3C;"; } sAlan.innerHTML += ``; }); document.getElementById("btnGeri").style.visibility = pointerSoru === 0 ? "hidden" : "visible"; document.getElementById("btnIleri").innerText = pointerSoru === 14 ? "Sınavı Bitir 🏁" : "Sonraki ➡️"; } function anlikSikSecimi(secilen) { if (ogrenciCevaplari[pointerSoru] !== null) return; const veri = aktifSoruBankasi[pointerSoru]; ogrenciCevaplari[pointerSoru] = secilen; const gb = document.getElementById("anlikGeribildirim"); if (secilen === veri.c) { gb.innerText = "✓ DOĞRU CEVAP!"; gb.style.background = "#EBF5EE"; gb.style.color = "#2E5A44"; } else { gb.innerText = `✗ YANLIŞ! (Doğru: ${String.fromCharCode(65 + veri.c)})`; gb.style.background = "#FDEDEC"; gb.style.color = "#E74C3C"; } gb.style.display = "block"; setTimeout(() => { dinamikSoruGoster(); }, 1200); } function navigasyonSoru(yon) { if (pointerSoru === 14 && yon === 1) { nihaiSorguKapat(); return; } pointerSoru += yon; if (pointerSoru < 0) pointerSoru = 0; if (pointerSoru > 14) pointerSoru = 14; dinamikSoruGoster(); } async function nihaiSorguKapat() { document.getElementById("testSoruEkrani").style.display = "none"; document.getElementById("testSonucEkrani").style.display = "block"; let dSayi = 0; let ySayi = 0; aktifSoruBankasi.forEach((v, index) => { if(ogrenciCevaplari[index] === v.c) dSayi++; else ySayi++; }); nihaiDogruSayisi = dSayi; nihaiYanlisSayisi = ySayi; let seviyeUnvani = "A1 (Beginner)"; let dinamikMesaj = ""; if (dSayi >= 14) { seviyeUnvani = "B2+ (İleri Düzey / Üst Seviye)"; dinamikMesaj = `🏆 Müthiş Bir Potansiyel! Harika bir altyapın var; ancak dili akıcı konuşmak, nüansları yakalamak ve uluslararası sınavlarda zirvede kalmak için profesyonel mentorlukla pratik yapman şart. Bu ateşi söndürme, profesyonel derslerle mükemmelleştir!`; } else if (dSayi >= 11) { seviyeUnvani = "B2 (İleri Orta Seviye)"; dinamikMesaj = `🚀 Zirveye Çok Yakınsın! Dilin iskeletine gayet hakimsin. Fakat kelime derinliği ve doğal konuşma refleksini kazanmak için birebir yönlendirmeye ihtiyacın var. Ufak dokunuşlarla İngilizceyi anadil rahatlığına taşıyabiliriz!`; } else if (dSayi >= 8) { seviyeUnvani = "B1 (Orta Seviye)"; dinamikMesaj = `⚡ Güçlü Bir Temel, Büyük Bir Fırsat! Kendini ifade edebiliyorsun ama karmaşık yapılar ve dinleme seni biraz zorluyor. Doğru teknikler ve bireysel özel ders takibiyle çok kısa sürede bir üst seviyeye sıçrayabilirsin!`; } else if (dSayi >= 5) { seviyeUnvani = "A2 (Temel Üstü Seviye)"; dinamikMesaj = `🌱 Güzel Başlangıç Ama Harekete Geçme Zamanı! Temel kalıpları biliyorsun ancak kendi başına ilerlerken zaman kaybedebilirsin. Eksiklerini nokta atışı tespit edip hızla seviye atlamak için birebir eğitime hemen başlamalısın!`; } else { seviyeUnvani = "A1 (Başlangıç Seviyesi)"; dinamikMesaj = `🎯 Yolun Başındasın ve En Şanslı Dönemindesin! Sıfırdan, en doğru metotlarla, sağlam temeller atarak başlamak seni yanlış alışkanlıklardan korur. Profesyonel rehberlikle İngilizce senin için bir zorluk değil, keyifli bir serüven olacak!`; } nihaiSeviyeSonucu = seviyeUnvani; document.getElementById("testSonucSeviye").innerText = seviyeUnvani; document.getElementById("testSkorMetni").innerText = `15 Soru Üzerinden -> Doğru: ${dSayi} | Yanlış: ${ySayi}`; const hocaNotuAlani = document.getElementById("hocaOzelNotu"); if (hocaNotuAlani) { hocaNotuAlani.innerHTML = dinamikMesaj; } const bugun = new Date(); const tarihFormat = String(bugun.getDate()).padStart(2, '0') + "." + String(bugun.getMonth() + 1).padStart(2, '0') + "." + bugun.getFullYear(); const apiPayload = { aksiyon: "seviyeKaydet", sayfaAdi: "Seviye Tespit Sınavı", tarih: tarihFormat, ogrenci: ogrenciIsmi, isim: ogrenciIsmi, dogru: dSayi, yanlis: ySayi, seviye: seviyeUnvani }; try { if(WEB_APP_URL) { await fetch(WEB_APP_URL, { method: "POST", mode: "no-cors", headers: { "Content-Type": "application/json" }, body: JSON.stringify(apiPayload) }); } } catch(e) { console.log("Seviye kaydı tamamlandı."); } } function testSonucundanDersTalebiGonder() { const mesaj = `Merhabalar Hocam,\nBen seviye tespit sınavını tamamladım.\n\n👤 *Adım Soyadım:* ${ogrenciIsmi}\n📊 *Sınav Sonucum:* ${nihaiDogruSayisi} Doğru / ${nihaiYanlisSayisi} Yanlış\n🎯 *Seviyem:* ${nihaiSeviyeSonucu}\n\nİngilizcemi daha da ilerletmek ve bireysel özel ders planlaması yapmak için bilgi istiyorum.`; const numara = "905369937089"; const wpLink = `https://api.whatsapp.com/send?phone=${numara}&text=${encodeURIComponent(mesaj)}`; window.open(wpLink, '_blank'); } function whatsappKutusuToggle() { const box = document.getElementById("waChatBox"); if (box.style.display === "flex") { box.style.display = "none"; } else { box.style.display = "flex"; document.getElementById("waSoruMetni").focus(); } } function whatsapplaGonder() { const mesajInput = document.getElementById("waSoruMetni"); const mesaj = mesajInput.value.trim(); if (!mesaj) { alert("Lütfen önce sorunuzu yazın."); mesajInput.focus(); return; } let ogrenciBilgisi = typeof activeStudent !== 'undefined' && activeStudent ? `Öğrenci: ${activeStudent}` : "Web Sitesi Ziyaretçisi"; const tamMesaj = `🤖 *DİJİMUALLİM - CANLI SORU HATTI*\n\n👤 ${ogrenciBilgisi}\n\n📝 *Soru / Mesaj:*\n${mesaj}`; const telefonNumarasi = "905369937089"; const waUrl = `https://api.whatsapp.com/send?phone=${telefonNumarasi}&text=${encodeURIComponent(tamMesaj)}`; window.open(waUrl, '_blank'); mesajInput.value = ""; whatsappKutusuToggle(); } document.addEventListener("DOMContentLoaded", function() { setTimeout(function() { var baloncuklar = document.querySelectorAll(".auto-hide-badge"); baloncuklar.forEach(function(el) { if (el) { el.style.opacity = "0"; el.style.transform = "translateX(25px)"; setTimeout(function() { el.style.display = "none"; }, 600); } }); }, 5000); const overlay = document.getElementById("yeni_rubrikOverlay"); const openBtn = document.getElementById("yeni_rubrikOpenBtn"); const closeBtn = document.getElementById("yeni_rubrikCloseBtn"); const unlockBtn = document.getElementById("yeni_unlockBtn"); const passInput = document.getElementById("yeni_passInput"); const lockScreen = document.getElementById("yeni_lockScreen"); const rubrikApp = document.getElementById("yeni_rubrikApp"); const passError = document.getElementById("yeni_passError"); const overallScoreEl = document.getElementById("yeni_overallScore"); const examScore = document.getElementById("yeni_examScore"); const examScoreOut = document.getElementById("yeni_examScoreOut"); const webhookToggle = document.getElementById("yeni_webhookToggle"); const webhookForm = document.getElementById("yeni_webhookForm"); const saveWebhookBtn = document.getElementById("yeni_saveWebhook"); const webhookUrlInput = document.getElementById("yeni_webhookUrl"); const statusMsg = document.getElementById("yeni_statusMsg"); const saveBtn = document.getElementById("yeni_saveBtn"); const resetBtn = document.getElementById("yeni_resetBtn"); const studentNameInput = document.getElementById("yeni_studentName"); const studentPhoneInput = document.getElementById("yeni_studentPhone"); const bookNameInput = document.getElementById("yeni_bookName"); const bookReadInput = document.getElementById("yeni_bookRead"); const bookTargetInput = document.getElementById("yeni_bookTarget"); const bookTotalInput = document.getElementById("yeni_bookTotal"); const bugunTarihInput = new Date().toISOString().split('T')[0]; if(document.getElementById("yeni_completedLessonDate")) { document.getElementById("yeni_completedLessonDate").value = bugunTarihInput; } if(document.getElementById("yeni_nextLessonDate")) { document.getElementById("yeni_nextLessonDate").value = bugunTarihInput; } if(localStorage.getItem("rubrik_webhook_yeni") && webhookUrlInput) { webhookUrlInput.value = localStorage.getItem("rubrik_webhook_yeni"); } if(openBtn) { openBtn.addEventListener("click", function() { if(overlay) overlay.style.display = "flex"; }); } if(closeBtn) { closeBtn.addEventListener("click", function() { if(overlay) overlay.style.display = "none"; }); } if(unlockBtn) { unlockBtn.addEventListener("click", function() { const girilenSifre = passInput.value.trim(); if(girilenSifre === "315269") { lockScreen.style.display = "none"; rubrikApp.style.display = "block"; passError.style.display = "none"; passInput.value = ""; } else { passError.style.display = "block"; passInput.value = ""; } }); } if(studentNameInput) { studentNameInput.addEventListener("input", function() { const girilenIsim = studentNameInput.value.trim(); if (girilenIsim && typeof allData !== 'undefined' && Array.isArray(allData)) { let row = allData.find(r => r.ogrenci && r.ogrenci.toLowerCase() === girilenIsim.toLowerCase()); if (row) { let telNo = row.telefon || row.veli_telefon || row.p || row.telefon_numarasi || ""; if(telNo && studentPhoneInput) { studentPhoneInput.value = telNo; } } let ogrenciSatirlari = allData.filter(r => r.ogrenci && r.ogrenci.toLowerCase() === girilenIsim.toLowerCase()); let sonKitapliSatir = [...ogrenciSatirlari].reverse().find(r => r.son_kitap_adi && r.son_kitap_adi !== "Bu hafta henüz kitap tanımlanmadı."); if (sonKitapliSatir) { if(bookNameInput) bookNameInput.value = sonKitapliSatir.son_kitap_adi || ""; if(bookTargetInput) bookTargetInput.value = sonKitapliSatir.son_kitap_hedef || "100"; if(bookTotalInput) bookTotalInput.value = sonKitapliSatir.okunan_kitap_sayisi || "0"; if(bookReadInput) bookReadInput.value = ""; } else { if(bookNameInput) bookNameInput.value = ""; if(bookTargetInput) bookTargetInput.value = "100"; if(bookTotalInput) bookTotalInput.value = "0"; if(bookReadInput) bookReadInput.value = ""; } } }); } document.querySelectorAll(".r-btn-group .r-status-btn").forEach(btn => { btn.addEventListener("click", () => { btn.parentElement.querySelectorAll(".r-status-btn").forEach(b => b.classList.remove("active")); btn.classList.add("active"); }); }); const skillSliders = document.querySelectorAll(".yeni-skill-input"); function updateAverage() { let total = 0; skillSliders.forEach(slider => { const val = parseInt(slider.value) || 0; if(slider.nextElementSibling) slider.nextElementSibling.innerText = val; total += val; }); if(overallScoreEl) overallScoreEl.innerText = Math.round(total / (skillSliders.length || 1)); } skillSliders.forEach(s => s.addEventListener("input", updateAverage)); if(examScore) { examScore.addEventListener("input", () => { if(examScoreOut) examScoreOut.innerText = examScore.value + "/100"; }); } if(webhookToggle && webhookForm) { webhookToggle.addEventListener("click", () => { webhookForm.style.display = webhookForm.style.display === "none" ? "block" : "none"; }); } if(saveWebhookBtn && webhookUrlInput) { saveWebhookBtn.addEventListener("click", () => { localStorage.setItem("rubrik_webhook_yeni", webhookUrlInput.value); alert("Bağlantı URL'i tarayıcıya kaydedildi!"); if(webhookForm) webhookForm.style.display = "none"; }); } if(resetBtn) { resetBtn.addEventListener("click", () => { if(confirm("Tüm formu temizlemek istediğinize emin misiniz?")) { if(studentNameInput) studentNameInput.value = ""; if(studentPhoneInput) studentPhoneInput.value = "90"; if(document.getElementById("yeni_lessonTopic")) document.getElementById("yeni_lessonTopic").value = ""; if(document.getElementById("yeni_startComment")) document.getElementById("yeni_startComment").value = ""; if(document.getElementById("yeni_endComment")) document.getElementById("yeni_endComment").value = ""; if(document.getElementById("yeni_completedLessonDate")) document.getElementById("yeni_completedLessonDate").value = bugunTarihInput; if(document.getElementById("yeni_nextLessonDate")) document.getElementById("yeni_nextLessonDate").value = bugunTarihInput; if(examScore) examScore.value = 0; if(examScoreOut) examScoreOut.innerText = "0/100"; if(bookNameInput) bookNameInput.value = ""; if(bookReadInput) bookReadInput.value = ""; if(bookTargetInput) bookTargetInput.value = "100"; if(bookTotalInput) bookTotalInput.value = "0"; document.querySelectorAll(".r-status-btn").forEach(b => b.classList.remove("active")); document.querySelectorAll("input[type=checkbox]").forEach(c => c.checked = false); skillSliders.forEach(s => { s.value = 0; if(s.nextElementSibling) s.nextElementSibling.innerText = "0"; }); if(overallScoreEl) overallScoreEl.innerText = "0"; } }); } function formatTarih(dateString) { if(!dateString) return ""; const parts = dateString.split("-"); return parts[2] + "." + parts[1] + "." + parts[0]; } if(saveBtn) { saveBtn.addEventListener("click", async () => { const url = webhookUrlInput ? webhookUrlInput.value : ""; const name = studentNameInput ? studentNameInput.value.trim() : ""; const compDateRaw = document.getElementById("yeni_completedLessonDate") ? document.getElementById("yeni_completedLessonDate").value : ""; const nextDateRaw = document.getElementById("yeni_nextLessonDate") ? document.getElementById("yeni_nextLessonDate").value : ""; const veliTel = studentPhoneInput ? studentPhoneInput.value.trim() : ""; if(!url) { alert("Lütfen önce Google Sheets bağlantısını ayarlayın."); return; } if(!name) { alert("Lütfen Öğrenci Adı alanını doldurun."); return; } if(!veliTel || veliTel === "90") { alert("Lütfen veli telefon numarasını girin."); return; } if(!compDateRaw || !nextDateRaw) { alert("Lütfen iki tarih alanını da doldurun."); return; } saveBtn.disabled = true; saveBtn.innerText = "Kaydediliyor..."; const activeStartBtn = document.querySelector("#yeni_startStatusGroup .r-status-btn.active"); const startStatusVal = activeStartBtn ? activeStartBtn.getAttribute("data-val") : "Belirtilmedi"; const bugun = new Date(); const tarihFormat = String(bugun.getDate()).padStart(2, '0') + "." + String(bugun.getMonth() + 1).padStart(2, '0') + "." + bugun.getFullYear(); const tamamlananDersTarihi = formatTarih(compDateRaw); const sonrakiDersTarihi = formatTarih(nextDateRaw); const startCommentVal = document.getElementById("yeni_startComment") ? document.getElementById("yeni_startComment").value.trim() : "Yok"; const endCommentVal = document.getElementById("yeni_endComment") ? document.getElementById("yeni_endComment").value.trim() : "Yok"; const vKitapAdiInput = bookNameInput ? bookNameInput.value.trim() : ""; const vOkunanInput = bookReadInput ? bookReadInput.value.trim() : ""; const vHedefInput = bookTargetInput ? bookTargetInput.value.trim() : ""; const vToplamInput = bookTotalInput ? bookTotalInput.value.trim() : ""; const payloadTamamlandi = { tarih: tarihFormat, ogrenci: name, seviye: document.getElementById("yeni_studentLevel") ? document.getElementById("yeni_studentLevel").value.trim() : "Genel", genel: overallScoreEl ? overallScoreEl.innerText : "0", vocabulary: document.getElementById("yeni_scVocabulary") ? document.getElementById("yeni_scVocabulary").value : "0", konusma: document.getElementById("yeni_scKonusma") ? document.getElementById("yeni_scKonusma").value : "0", okuma: document.getElementById("yeni_scOkuma") ? document.getElementById("yeni_scOkuma").value : "0", yazma: document.getElementById("yeni_scYazma") ? document.getElementById("yeni_scYazma").value : "0", grammar: document.getElementById("yeni_scGrammar") ? document.getElementById("yeni_scGrammar").value : "0", deneme: examScore ? examScore.value : "0", ders_tarihi: tamamlananDersTarihi, ders_durumu: "tamamlandi", odev_durumu: "Hazırlık: " + startStatusVal + " | Ödev Verildi mi: " + (document.getElementById("yeni_chkOdev") && document.getElementById("yeni_chkOdev").checked ? "Evet" : "Hayır") + " | Anlaşıldı mı: " + (document.getElementById("yeni_chkAnlasildi") && document.getElementById("yeni_chkAnlasildi").checked ? "Evet" : "Hayır"), konu: document.getElementById("yeni_lessonTopic") ? document.getElementById("yeni_lessonTopic").value.trim() : "Belirtilmedi", son_kitap_adi: vKitapAdiInput || undefined, son_kitap_sayfa: vOkunanInput !== "" ? Number(vOkunanInput) : undefined, son_kitap_hedef: vHedefInput !== "" ? Number(vHedefInput) : undefined, okunan_kitap_sayisi: vToplamInput !== "" ? Number(vToplamInput) : undefined }; const payloadSonraki = { tarih: tarihFormat, ogrenci: name, seviye: document.getElementById("yeni_studentLevel") ? document.getElementById("yeni_studentLevel").value.trim() : "Genel", genel: "0", vocabulary: "0", konusma: "0", okuma: "0", yazma: "0", grammar: "0", deneme: "0", ders_tarihi: sonrakiDersTarihi, ders_durumu: "sonraki", odev_durumu: "Gelecek Ders Planı", konu: "Planlanan Sonraki Ders", son_kitap_adi: undefined, son_kitap_sayfa: undefined, son_kitap_hedef: undefined, okunan_kitap_sayisi: undefined }; try { await fetch(url, { method: "POST", mode: "no-cors", headers: { "Content-Type": "application/json" }, body: JSON.stringify(payloadTamamlandi) }); await fetch(url, { method: "POST", mode: "no-cors", headers: { "Content-Type": "application/json" }, body: JSON.stringify(payloadSonraki) }); if(statusMsg) { statusMsg.style.display = "block"; statusMsg.style.background = "#E6F4EA"; statusMsg.style.color = "#137333"; statusMsg.innerText = "Başarıyla eklendi!"; } try { let wpMesaj = `🤖 *Diji-Medu - DERS SONU BİLGİLENDİRME* \n\nSayın Velimiz, \n*${payloadTamamlandi.ogrenci}* ile bugün (${tamamlananDersTarihi}) gerçekleştirdiğimiz dersimizin raporu işlenmiştir.\n\n` + `📖 *Ders Konusu:* ${payloadTamamlandi.konu}\n📌 *Ödev & Hazırlık:* ${payloadTamamlandi.odev_durumu}\n\n` + `📝 *Öğretmen Notları:* \n• Ders Başı Durumu: ${startCommentVal}\n• Ders Sonu Değerlendirmesi: ${endCommentVal}\n\n` + `📊 *Dil Becerileri Rubrik Analizi (%):* \n• Kelime Bilgisi (Vocabulary): %${payloadTamamlandi.vocabulary}\n• Konuşma (Speaking): %${payloadTamamlandi.konusma}\n• Okuma (Reading): %${payloadTamamlandi.okuma}\n• Yazma (Writing): %${payloadTamamlandi.yazma}\n• Dil Bilgisi (Grammar): %${payloadTamamlandi.grammar}\n📈 *Genel Başarı Ortalaması:* %${payloadTamamlandi.genel}\n`; if (parseInt(payloadTamamlandi.deneme) > 0) wpMesaj += `🎯 *Son Deneme/Sınav Skoru:* ${payloadTamamlandi.deneme}/100\n`; if (vKitapAdiInput) wpMesaj += `\n📚 *Haftalık Kitap Okuma Raporu:* \n• Kitap: ${vKitapAdiInput}\n• Okunan: ${vOkunanInput || 0} Sayfa\n• Hedef: ${vHedefInput || 100} Sayfa\n• Toplam Bitirilen: ${vToplamInput || 0} Kitap\n`; wpMesaj += `\n📅 *Bir Sonraki Planlanan Ders Tarihi:* ${sonrakiDersTarihi}\n\nGelişimin detaylı takibi için sistemimizi ziyaret edebilirsiniz. İyi günler dilerim. \n\n*İngilizce Öğretmeni & Eğitim Koçu*`; let temizTel = veliTel.replace(/\s+/g, ''); let wpUrl = `https://api.whatsapp.com/send?phone=${temizTel}&text=${encodeURIComponent(wpMesaj)}`; window.open(wpUrl, '_blank'); } catch (wpError) { console.error("WhatsApp hatası:", wpError); } if(resetBtn) resetBtn.click(); setTimeout(() => { if(statusMsg) statusMsg.style.display = "none"; }, 4000); } catch (error) { if(statusMsg) { statusMsg.style.display = "block"; statusMsg.style.background = "#FCE8E6"; statusMsg.style.color = "#C5221F"; statusMsg.innerText = "Hata oluştu! Tabloya bağlanılamadı."; } } finally { saveBtn.disabled = false; saveBtn.innerText = "Formu Kaydet (Yeni Satır)"; } }); } }); function randevuFormuKapatAcl() { const kutu = document.getElementById("sagAltDersKutusu"); const seviyeAlani = document.getElementById("seviyeTestAlani"); if (seviyeAlani) seviyeAlani.style.display = "none"; if (!kutu) return; if (kutu.style.display === "none" || kutu.style.display === "") { kutu.style.display = "flex"; } else { kutu.style.display = "none"; } } async function sagAltDersTalebiGonder() { const ogrenciInput = document.getElementById("alt_ogrenciAdi"); const dersTuruInput = document.getElementById("alt_dersTuru"); const dersModeliInput = document.getElementById("alt_dersModeli"); const tarihInput = document.getElementById("alt_dersTarihi"); const saatInput = document.getElementById("alt_dersSaati"); const telefonInput = document.getElementById("alt_dersTelefon"); const btn = document.getElementById("alt_gonderBtn"); const ogrenciAdi = ogrenciInput ? ogrenciInput.value.trim() : ""; const dersTuru = dersTuruInput ? dersTuruInput.value : ""; const dersModeli = dersModeliInput ? dersModeliInput.value : ""; const secilenTarih = tarihInput ? tarihInput.value : ""; const secilenSaat = saatInput ? saatInput.value : ""; const veliTel = telefonInput ? telefonInput.value.trim() : ""; if (!ogrenciAdi || !secilenTarih || !veliTel) { alert("Lütfen tüm alanları (Ad Soyadı, Tarih ve Telefon) eksiksiz doldurunuz."); return; } if (btn) { btn.disabled = true; btn.innerText = "İşleniyor..."; } let formatliTarih = secilenTarih; if (secilenTarih.includes("-")) { const [y, m, d] = secilenTarih.split("-"); formatliTarih = `${d}.${m}.${y}`; } const tamOgrenciDetay = `${ogrenciAdi} (${dersTuru} - ${dersModeli})`; const randevuPayload = { aksiyon: "randevuAl", ogrenci: tamOgrenciDetay, tarih: formatliTarih, saat: secilenSaat, telefon: veliTel }; try { if (typeof WEB_APP_URL !== "undefined" && WEB_APP_URL) { fetch(WEB_APP_URL, { method: "POST", mode: "no-cors", headers: { "Content-Type": "application/json" }, body: JSON.stringify(randevuPayload) }); } } catch (e) { console.log("Sheets hatası:", e); } const mesaj = `🤖 *DİJİMUALLİM - YENİ RANDEVU TALEBİ*\n\n` + `Hocam Merhaba,\nEğitim dönemi için yeni bir ders talebi oluşturmak istiyoruz.\n\n` + `👤 *Öğrenci:* ${ogrenciAdi}\n` + `📚 *Ders Türü:* ${dersTuru}\n` + `💻 *Ders Modeli:* ${dersModeli}\n` + `📅 *Tarih:* ${formatliTarih}\n` + `⏰ *Saat:* ${secilenSaat}\n` + `📞 *Veli Tel:* ${veliTel}\n\n` + `En Kısa Sürede Dönüş Yapılacaktır`; const hocamizinNumarasi = "905369937089"; const wpUrl = `https://api.whatsapp.com/send?phone=${hocamizinNumarasi}&text=${encodeURIComponent(mesaj)}`; window.open(wpUrl, '_blank'); setTimeout(() => { if (btn) { btn.disabled = false; btn.innerText = "Talebi Kaydet ve Onaya Gönder ➔"; } if (ogrenciInput) ogrenciInput.value = ""; if (tarihInput) tarihInput.value = ""; if (telefonInput) telefonInput.value = ""; randevuFormuKapatAcl(); }, 600); } let oturumSaniye = 0; let oturumTimer = null; let aktifKayitliOgrenci = null; function guncelSayacArayuzunuBas() { const sayacElementi = document.getElementById("sayacZaman"); const progressBar = document.getElementById("sureProgressBar"); const rozetMetni = document.getElementById("rozetBilgiMetni"); const sonrakiMetin = document.getElementById("sonrakiRozetKalan"); if (!sayacElementi) return; let saat = Math.floor(oturumSaniye / 3600); let dk = Math.floor((oturumSaniye % 3600) / 60); let sn = oturumSaniye % 60; let formatliZaman = (saat > 0 ? (saat < 10 ? "0" : "") + saat + ":" : "") + (dk < 10 ? "0" : "") + dk + ":" + (sn < 10 ? "0" : "") + sn; sayacElementi.innerText = formatliZaman; let kazanilanRozetler = Math.floor(oturumSaniye / 600); let saniyeIcindekiIlerleme = oturumSaniye % 600; let yuzde = (saniyeIcindekiIlerleme / 600) * 100; let sonrakiSaniyeKalan = 600 - saniyeIcindekiIlerleme; let kalanDk = Math.ceil(sonrakiSaniyeKalan / 60); if (progressBar) progressBar.style.width = yuzde + "%"; if (rozetMetni) rozetMetni.innerText = "🏅 Kazanılan Rozet: " + kazanilanRozetler + " 🌟"; if (sonrakiMetin) sonrakiMetin.innerText = "Sonraki rozete: " + kalanDk + " dk"; } function googleSheetseSureKaydet(ogrenci, saniye, rozet) { if (!WEB_APP_URL || !ogrenci) return; const url = `${WEB_APP_URL}?action=sureKaydetGet&ogrenci=${encodeURIComponent(ogrenci)}&toplamSaniye=${saniye}&rozetSayisi=${rozet}&t=${Date.now()}`; const beacon = new Image(); beacon.src = url; } function buluttanSureGetir(ogrenciAdi) { return new Promise((resolve) => { if (!WEB_APP_URL || !ogrenciAdi) { resolve(0); return; } const callbackName = "sureCallback_" + Math.floor(Math.random() * 1000000); const script = document.createElement("script"); window[callbackName] = function(data) { delete window[callbackName]; if (script.parentNode) script.parentNode.removeChild(script); if (data && data.durum === "basarili") { resolve(data.toplamSaniye || 0); } else { resolve(0); } }; script.onerror = function() { delete window[callbackName]; if (script.parentNode) script.parentNode.removeChild(script); resolve(0); }; script.src = `${WEB_APP_URL}?action=sureGetir&ogrenci=${encodeURIComponent(ogrenciAdi)}&callback=${callbackName}&t=${Date.now()}`; document.body.appendChild(script); }); } async function oturumSayaciniBaslat(ogrenciAdi) { aktifKayitliOgrenci = ogrenciAdi; const storageKey = "dijimuallim_sure_" + turkceKucukBuyukDuzelt(ogrenciAdi); const localSec = localStorage.getItem(storageKey); oturumSaniye = localSec ? (parseInt(localSec, 10) || 0) : 0; guncelSayacArayuzunuBas(); const bulutSaniyesi = await buluttanSureGetir(ogrenciAdi); if (bulutSaniyesi > oturumSaniye) { oturumSaniye = bulutSaniyesi; localStorage.setItem(storageKey, oturumSaniye); guncelSayacArayuzunuBas(); } if (oturumTimer) clearInterval(oturumTimer); oturumTimer = setInterval(() => { oturumSaniye++; localStorage.setItem(storageKey, oturumSaniye); guncelSayacArayuzunuBas(); if (oturumSaniye % 30 === 0) { let rozet = Math.floor(oturumSaniye / 600); googleSheetseSureKaydet(aktifKayitliOgrenci, oturumSaniye, rozet); } }, 1000); } function oturumSayaciniDurdur() { if (oturumTimer) { clearInterval(oturumTimer); oturumTimer = null; } if (aktifKayitliOgrenci) { let rozet = Math.floor(oturumSaniye / 600); googleSheetseSureKaydet(aktifKayitliOgrenci, oturumSaniye, rozet); } aktifKayitliOgrenci = null; } window.addEventListener('beforeunload', function () { if (aktifKayitliOgrenci) { let rozet = Math.floor(oturumSaniye / 600); googleSheetseSureKaydet(aktifKayitliOgrenci, oturumSaniye, rozet); } }); document.addEventListener('visibilitychange', function () { if (document.visibilityState === 'hidden' && aktifKayitliOgrenci) { let rozet = Math.floor(oturumSaniye / 600); googleSheetseSureKaydet(aktifKayitliOgrenci, oturumSaniye, rozet); } }); function siradakiDersTarihiniHesapla(sabitGunlerMetni) { if (!sabitGunlerMetni || typeof sabitGunlerMetni !== "string") { let d = new Date(); d.setDate(d.getDate() + 7); return ("0" + d.getDate()).slice(-2) + "." + ("0" + (d.getMonth() + 1)).slice(-2) + "." + d.getFullYear(); } const gunHaritasi = { "pazar": 0, "pazartesi": 1, "sali": 2, "çarşamba": 3, "carsamba": 3, "perşembe": 4, "persembe": 4, "cuma": 5, "cumartesi": 6 }; let parcalar = sabitGunlerMetni.toLowerCase().split(/[,\-\/]/).map(s => s.trim().replace(/ı/g, "i")); let hedefGunler = []; parcalar.forEach(p => { for (let g in gunHaritasi) { if (p.includes(g)) { if (!hedefGunler.includes(gunHaritasi[g])) hedefGunler.push(gunHaritasi[g]); } } }); if (hedefGunler.length === 0) { let d = new Date(); d.setDate(d.getDate() + 7); return ("0" + d.getDate()).slice(-2) + "." + ("0" + (d.getMonth() + 1)).slice(-2) + "." + d.getFullYear(); } let bugun = new Date(); let bugunIndex = bugun.getDay(); let minFark = 999; hedefGunler.forEach(g => { let fark = g - bugunIndex; if (fark <= 0) fark += 7; if (fark < minFark) minFark = fark; }); let siradakiTarih = new Date(); siradakiTarih.setDate(bugun.getDate() + minFark); let gun = ("0" + siradakiTarih.getDate()).slice(-2); let ay = ("0" + (siradakiTarih.getMonth() + 1)).slice(-2); let yil = siradakiTarih.getFullYear(); return `${gun}.${ay}.${yil}`; }