Git Komut Rehberi & Terminal Asistanı
Sıfırdan Yeni Bir Depo Başlatın:
Mevcut Bir Git Deposu veya Klasörü Gönderin:
Hataları Geri Alma, İptal & Temizlik:
Son commit'i geri al (yapılan değişiklikleri korur):
git reset --soft HEAD~1
Yapılan yerel değişiklikleri iptal et (çalışma ağacını temizler):
git restore .
Takip edilmeyen gereksiz dosyaları sil:
git clean -fd
Değişiklikleri geçici sakla ve geri getir (stash):
git stash git stash pop
Dal (Branch) ve Sürüm Etiketleri:
Yeni dal aç ve geçiş yap:
git checkout -b yeni-ozellik git push -u origin yeni-ozellik
Sürüm etiketi (tag) oluştur ve gönder:
git tag -a v1.0.0 -m "Sürüm 1.0.0" git push origin --tags
Compare commits
10
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
29a9fc6e75 | ||
|
|
07719f889f | ||
|
|
5566a43492 | ||
|
|
ab8ffa80ec | ||
|
|
8c19d9f954 | ||
|
|
9151f8445a | ||
|
|
7ad7fb6056 | ||
|
|
c1b69cd0d2 | ||
|
|
7f77281e8a | ||
|
|
c667bf2f28 |
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
node_modules/
|
node_modules/
|
||||||
docs/
|
|
||||||
*.log
|
*.log
|
||||||
.DS_Store
|
.DS_Store
|
||||||
|
dist/
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
docs/
|
|
||||||
*.log
|
|
||||||
.git
|
|
||||||
.github
|
|
||||||
@@ -1,4 +1,3 @@
|
|||||||
try {
|
|
||||||
(function () {
|
(function () {
|
||||||
if (window.__YAKTUBE_ENGINE_LOADED__) return;
|
if (window.__YAKTUBE_ENGINE_LOADED__) return;
|
||||||
window.__YAKTUBE_ENGINE_LOADED__ = true;
|
window.__YAKTUBE_ENGINE_LOADED__ = true;
|
||||||
@@ -287,7 +286,8 @@ try {
|
|||||||
var defaultLoginLink = headerRight.querySelector('my-login-link, a[href*="/login"], .login-button');
|
var defaultLoginLink = headerRight.querySelector('my-login-link, a[href*="/login"], .login-button');
|
||||||
var liveWidget = headerRight.querySelector('#yaknet-header-account-widget');
|
var liveWidget = headerRight.querySelector('#yaknet-header-account-widget');
|
||||||
|
|
||||||
// Always hide duplicate native login link in favor of unified YakNet component
|
if (isAuth) {
|
||||||
|
// Logged In: Show YakNet Profile Menu, Hide default login link
|
||||||
if (defaultLoginLink) {
|
if (defaultLoginLink) {
|
||||||
defaultLoginLink.style.display = 'none';
|
defaultLoginLink.style.display = 'none';
|
||||||
defaultLoginLink.setAttribute('aria-hidden', 'true');
|
defaultLoginLink.setAttribute('aria-hidden', 'true');
|
||||||
@@ -306,8 +306,8 @@ try {
|
|||||||
'client-id="01a03c41-f758-721e-b927-619bffde5c23" ' +
|
'client-id="01a03c41-f758-721e-b927-619bffde5c23" ' +
|
||||||
'redirect-uri="https://yaktube.yakhub.com.tr/plugins/peertube-plugin-auth-yaknet/router/auth-callback" ' +
|
'redirect-uri="https://yaktube.yakhub.com.tr/plugins/peertube-plugin-auth-yaknet/router/auth-callback" ' +
|
||||||
'base-url="https://auth.yakhub.com.tr" ' +
|
'base-url="https://auth.yakhub.com.tr" ' +
|
||||||
'login-url="https://auth.yakhub.com.tr/oauth/authorize?client_id=01a03c41-f758-721e-b927-619bffde5c23&redirect_uri=https%3A%2F%2Fyaktube.yakhub.com.tr%2Fplugins%2Fpeertube-plugin-auth-yaknet%2Frouter%2Fauth-callback&response_type=code&scope=" ' +
|
'login-url="/login" ' +
|
||||||
(isAuth ? 'authenticated="true" ' : 'authenticated="false" ') +
|
'authenticated="true" ' +
|
||||||
'user-name="' +
|
'user-name="' +
|
||||||
displayName.replace(/"/g, '"') +
|
displayName.replace(/"/g, '"') +
|
||||||
'" ' +
|
'" ' +
|
||||||
@@ -332,17 +332,6 @@ try {
|
|||||||
} else {
|
} else {
|
||||||
var el = liveWidget.querySelector('yaknet-account');
|
var el = liveWidget.querySelector('yaknet-account');
|
||||||
if (el) {
|
if (el) {
|
||||||
var authAttr = isAuth ? 'true' : 'false';
|
|
||||||
if (el.getAttribute('authenticated') !== authAttr || el.getAttribute('user-name') !== displayName) {
|
|
||||||
el.setAttribute('authenticated', authAttr);
|
|
||||||
el.setAttribute('user-name', displayName);
|
|
||||||
el.setAttribute('user-email', emailStr);
|
|
||||||
if (typeof el.syncStateFromAttributes === 'function') {
|
|
||||||
el.syncStateFromAttributes();
|
|
||||||
el.render();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (el.shadowRoot) {
|
if (el.shadowRoot) {
|
||||||
var shadowLogoutBtn =
|
var shadowLogoutBtn =
|
||||||
el.shadowRoot.getElementById('logoutBtn') ||
|
el.shadowRoot.getElementById('logoutBtn') ||
|
||||||
@@ -361,6 +350,39 @@ try {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (el.getAttribute('authenticated') !== 'true' || el.getAttribute('user-name') !== displayName) {
|
||||||
|
el.setAttribute('authenticated', 'true');
|
||||||
|
el.setAttribute('user-name', displayName);
|
||||||
|
el.setAttribute('user-email', emailStr);
|
||||||
|
if (typeof el.syncStateFromAttributes === 'function') {
|
||||||
|
el.syncStateFromAttributes();
|
||||||
|
el.render();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
// Not Logged In: Remove YakNet widget to eliminate duplicate button, keep PeerTube native login button clean
|
||||||
|
if (liveWidget) {
|
||||||
|
liveWidget.remove();
|
||||||
|
}
|
||||||
|
if (defaultLoginLink) {
|
||||||
|
defaultLoginLink.style.display = '';
|
||||||
|
defaultLoginLink.removeAttribute('aria-hidden');
|
||||||
|
|
||||||
|
var loginAnchor =
|
||||||
|
defaultLoginLink.tagName.toLowerCase() === 'a' ? defaultLoginLink : defaultLoginLink.querySelector('a');
|
||||||
|
if (loginAnchor) {
|
||||||
|
loginAnchor.setAttribute('aria-label', 'YakNet ile Giriş Yap');
|
||||||
|
loginAnchor.setAttribute('title', 'YakNet Hesabınız ile Giriş Yapın');
|
||||||
|
var spanText = loginAnchor.querySelector('span');
|
||||||
|
if (spanText) {
|
||||||
|
spanText.textContent = 'YakNet ile Giriş Yap';
|
||||||
|
} else {
|
||||||
|
loginAnchor.textContent = 'YakNet ile Giriş Yap';
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -421,9 +443,7 @@ try {
|
|||||||
if (containerToHide && !isLocalLogin) {
|
if (containerToHide && !isLocalLogin) {
|
||||||
var subElements = Array.from(loginCard.children).filter(function (el) {
|
var subElements = Array.from(loginCard.children).filter(function (el) {
|
||||||
return (
|
return (
|
||||||
el.id !== 'yaknet-login-section' &&
|
el.id !== 'yaknet-login-section' && !el.classList.contains('title') && !el.classList.contains('page-title')
|
||||||
!el.classList.contains('title') &&
|
|
||||||
!el.classList.contains('page-title')
|
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -649,9 +669,7 @@ try {
|
|||||||
if (!alt || alt.trim() === '') {
|
if (!alt || alt.trim() === '') {
|
||||||
var card = img.closest('.video-miniature, .video-card, .yaktube-card, [class*="miniature"]');
|
var card = img.closest('.video-miniature, .video-card, .yaktube-card, [class*="miniature"]');
|
||||||
if (card) {
|
if (card) {
|
||||||
var titleEl = card.querySelector(
|
var titleEl = card.querySelector('.video-miniature-name, .video-name, .yaktube-video-name, h3, h4, a[title]');
|
||||||
'.video-miniature-name, .video-name, .yaktube-video-name, h3, h4, a[title]'
|
|
||||||
);
|
|
||||||
var titleText = titleEl ? (titleEl.textContent || titleEl.getAttribute('title') || '').trim() : '';
|
var titleText = titleEl ? (titleEl.textContent || titleEl.getAttribute('title') || '').trim() : '';
|
||||||
if (titleText) {
|
if (titleText) {
|
||||||
img.setAttribute('alt', titleText + ' video kapağı');
|
img.setAttribute('alt', titleText + ' video kapağı');
|
||||||
@@ -1481,10 +1499,7 @@ try {
|
|||||||
if (sData.isImporting) {
|
if (sData.isImporting) {
|
||||||
showModal('[1/2] 📥 Video İndiriliyor...', 'Video sunucuya indiriliyor (' + attempts * 2 + ' sn)...');
|
showModal('[1/2] 📥 Video İndiriliyor...', 'Video sunucuya indiriliyor (' + attempts * 2 + ' sn)...');
|
||||||
} else if (sData.isTranscoding) {
|
} else if (sData.isTranscoding) {
|
||||||
showModal(
|
showModal('[2/2] ⚙️ Oynatıcı Hazırlanıyor...', 'Video işleniyor ve yüksek kalite akış hazırlanıyor...');
|
||||||
'[2/2] ⚙️ Oynatıcı Hazırlanıyor...',
|
|
||||||
'Video işleniyor ve yüksek kalite akış hazırlanıyor...'
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sData.isPublished || (sData.hasFiles && attempts >= 8)) {
|
if (sData.isPublished || (sData.hasFiles && attempts >= 8)) {
|
||||||
@@ -1812,17 +1827,10 @@ try {
|
|||||||
function getRecentSearches() {
|
function getRecentSearches() {
|
||||||
try {
|
try {
|
||||||
var data = localStorage.getItem('yaktube_recent_searches');
|
var data = localStorage.getItem('yaktube_recent_searches');
|
||||||
if (data) {
|
return data ? JSON.parse(data) : [];
|
||||||
var parsed = JSON.parse(data);
|
} catch (e) {
|
||||||
if (Array.isArray(parsed) && parsed.length > 0) return parsed;
|
return [];
|
||||||
}
|
}
|
||||||
} catch (e) {}
|
|
||||||
// Default initial recent searches for first-time visitors
|
|
||||||
var defaults = ['Tarkan', 'Barış Manço', 'Yapay Zeka', 'Canlı Haber'];
|
|
||||||
try {
|
|
||||||
localStorage.setItem('yaktube_recent_searches', JSON.stringify(defaults));
|
|
||||||
} catch (e) {}
|
|
||||||
return defaults;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function saveRecentSearch(query) {
|
function saveRecentSearch(query) {
|
||||||
@@ -1859,19 +1867,6 @@ try {
|
|||||||
{ title: '🎙️ Podcast & Söyleşi', q: 'Podcast Türkçe' }
|
{ title: '🎙️ Podcast & Söyleşi', q: 'Podcast Türkçe' }
|
||||||
];
|
];
|
||||||
|
|
||||||
// Auto capture search query from URL into recent searches
|
|
||||||
function captureUrlSearchQuery() {
|
|
||||||
try {
|
|
||||||
var params = new URLSearchParams(window.location.search);
|
|
||||||
var q = params.get('search') || params.get('q');
|
|
||||||
if (q && q.trim().length >= 2) {
|
|
||||||
saveRecentSearch(q.trim());
|
|
||||||
}
|
|
||||||
} catch (e) {}
|
|
||||||
}
|
|
||||||
captureUrlSearchQuery();
|
|
||||||
window.addEventListener('popstate', captureUrlSearchQuery);
|
|
||||||
|
|
||||||
function renderDynamicSearchChips() {
|
function renderDynamicSearchChips() {
|
||||||
var modal = document.getElementById('yaktube-full-search-modal');
|
var modal = document.getElementById('yaktube-full-search-modal');
|
||||||
if (!modal) return;
|
if (!modal) return;
|
||||||
@@ -1975,7 +1970,17 @@ try {
|
|||||||
'<div id="yaktube-modal-voice-transcript" class="yaktube-modal-voice-transcript">Lütfen aramak istediğiniz videoyu söyleyin...</div>' +
|
'<div id="yaktube-modal-voice-transcript" class="yaktube-modal-voice-transcript">Lütfen aramak istediğiniz videoyu söyleyin...</div>' +
|
||||||
'<button id="yaktube-modal-mic-pulse" class="yaktube-modal-mic-pulse-btn" aria-label="Mikrofonu durdur">🎙️</button>' +
|
'<button id="yaktube-modal-mic-pulse" class="yaktube-modal-mic-pulse-btn" aria-label="Mikrofonu durdur">🎙️</button>' +
|
||||||
'</div>' +
|
'</div>' +
|
||||||
'<div id="yaktube-modal-dynamic-chips-section"></div>' +
|
'<div class="yaktube-modal-section-title">🔥 Hızlı ve Popüler Aramalar</div>' +
|
||||||
|
'<div class="yaktube-modal-chips-grid">' +
|
||||||
|
'<button class="yaktube-modal-chip" data-query="Tarkan">🎵 Tarkan</button>' +
|
||||||
|
'<button class="yaktube-modal-chip" data-query="Barış Manço">🎸 Barış Manço</button>' +
|
||||||
|
'<button class="yaktube-modal-chip" data-query="Python Dersleri">💻 Python Dersleri</button>' +
|
||||||
|
'<button class="yaktube-modal-chip" data-query="Yapay Zeka">🤖 Yapay Zeka</button>' +
|
||||||
|
'<button class="yaktube-modal-chip" data-query="Sesli Kitap">🎧 Sesli Kitap</button>' +
|
||||||
|
'<button class="yaktube-modal-chip" data-query="Canlı Haber">📺 Canlı Haber</button>' +
|
||||||
|
'<button class="yaktube-modal-chip" data-query="Gitar Dersi">🎼 Gitar Dersi</button>' +
|
||||||
|
'<button class="yaktube-modal-chip" data-query="Bilim Belgeseli">🌍 Bilim Belgeseli</button>' +
|
||||||
|
'</div>' +
|
||||||
'<div class="yaktube-modal-hint-footer">' +
|
'<div class="yaktube-modal-hint-footer">' +
|
||||||
'<span>💡 <b>Enter</b> ile ara, <b>Shift+V</b> ile sesli ara</span>' +
|
'<span>💡 <b>Enter</b> ile ara, <b>Shift+V</b> ile sesli ara</span>' +
|
||||||
'<span><b>Escape</b> ile kapat</span>' +
|
'<span><b>Escape</b> ile kapat</span>' +
|
||||||
@@ -2207,10 +2212,7 @@ try {
|
|||||||
|
|
||||||
var nativeInputs = searchContainer.querySelectorAll('input, button');
|
var nativeInputs = searchContainer.querySelectorAll('input, button');
|
||||||
nativeInputs.forEach(function (el) {
|
nativeInputs.forEach(function (el) {
|
||||||
if (
|
if (!el.classList.contains('yaktube-search-trigger-pill') && !el.classList.contains('yaktube-voice-search-btn')) {
|
||||||
!el.classList.contains('yaktube-search-trigger-pill') &&
|
|
||||||
!el.classList.contains('yaktube-voice-search-btn')
|
|
||||||
) {
|
|
||||||
el.style.display = 'none';
|
el.style.display = 'none';
|
||||||
el.setAttribute('tabindex', '-1');
|
el.setAttribute('tabindex', '-1');
|
||||||
el.setAttribute('aria-hidden', 'true');
|
el.setAttribute('aria-hidden', 'true');
|
||||||
@@ -2476,8 +2478,7 @@ try {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function checkAndInjectRelatedVideos(forceReload) {
|
function checkAndInjectRelatedVideos(forceReload) {
|
||||||
var isWatchPage =
|
var isWatchPage = window.location.pathname.includes('/videos/watch/') || window.location.pathname.startsWith('/w/');
|
||||||
window.location.pathname.includes('/videos/watch/') || window.location.pathname.startsWith('/w/');
|
|
||||||
if (!isWatchPage) {
|
if (!isWatchPage) {
|
||||||
var existing = document.getElementById('yaktube-hybrid-related-container');
|
var existing = document.getElementById('yaktube-hybrid-related-container');
|
||||||
if (existing) existing.remove();
|
if (existing) existing.remove();
|
||||||
@@ -2755,10 +2756,7 @@ try {
|
|||||||
card.className = 'yaktube-comment-item';
|
card.className = 'yaktube-comment-item';
|
||||||
card.setAttribute('role', 'article');
|
card.setAttribute('role', 'article');
|
||||||
card.setAttribute('tabindex', '0');
|
card.setAttribute('tabindex', '0');
|
||||||
card.setAttribute(
|
card.setAttribute('aria-label', c.author + ' isimli kullan\u0131c\u0131n\u0131n yorumu: ' + c.content);
|
||||||
'aria-label',
|
|
||||||
c.author + ' isimli kullan\u0131c\u0131n\u0131n yorumu: ' + c.content
|
|
||||||
);
|
|
||||||
card.style.cssText =
|
card.style.cssText =
|
||||||
'background: #1e293b; padding: 14px 16px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.05); display: flex; gap: 12px; align-items: flex-start;';
|
'background: #1e293b; padding: 14px 16px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.05); display: flex; gap: 12px; align-items: flex-start;';
|
||||||
|
|
||||||
@@ -2834,11 +2832,9 @@ try {
|
|||||||
|
|
||||||
// 6. PWA Mobile App Install Engine & Standalone Detection
|
// 6. PWA Mobile App Install Engine & Standalone Detection
|
||||||
var isInsideYakTubeApp =
|
var isInsideYakTubeApp =
|
||||||
(navigator.userAgent && navigator.userAgent.indexOf('YakTubeMobileApp') !== -1) ||
|
navigator.userAgent.indexOf('YakTubeMobileApp') !== -1 ||
|
||||||
(typeof window.matchMedia === 'function' &&
|
window.matchMedia('(display-mode: standalone)').matches ||
|
||||||
window.matchMedia('(display-mode: standalone)') &&
|
window.navigator.standalone === true;
|
||||||
window.matchMedia('(display-mode: standalone)').matches) ||
|
|
||||||
(window.navigator && window.navigator.standalone === true);
|
|
||||||
|
|
||||||
var isMobileDevice = /Android|iPhone|iPad|iPod|Mobile|Tablet/i.test(navigator.userAgent);
|
var isMobileDevice = /Android|iPhone|iPad|iPod|Mobile|Tablet/i.test(navigator.userAgent);
|
||||||
|
|
||||||
@@ -2893,12 +2889,7 @@ try {
|
|||||||
headerButtons.prepend(installBtn);
|
headerButtons.prepend(installBtn);
|
||||||
}
|
}
|
||||||
|
|
||||||
function isYakTubeInstance() {
|
|
||||||
return window.location.hostname.includes('yaktube.yakhub.com.tr') || getInstanceName() === 'YakTube';
|
|
||||||
}
|
|
||||||
|
|
||||||
function injectApkDownloadButton() {
|
function injectApkDownloadButton() {
|
||||||
if (!isYakTubeInstance()) return;
|
|
||||||
// 1. If inside APK: NEVER show APK button
|
// 1. If inside APK: NEVER show APK button
|
||||||
if (isInsideYakTubeApp) {
|
if (isInsideYakTubeApp) {
|
||||||
var existBtnApp = document.getElementById('yaktube-apk-download-btn');
|
var existBtnApp = document.getElementById('yaktube-apk-download-btn');
|
||||||
@@ -2943,7 +2934,6 @@ try {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function injectSidebarApkLink() {
|
function injectSidebarApkLink() {
|
||||||
if (!isYakTubeInstance()) return;
|
|
||||||
// If inside APK: NEVER show in sidebar
|
// If inside APK: NEVER show in sidebar
|
||||||
if (isInsideYakTubeApp) {
|
if (isInsideYakTubeApp) {
|
||||||
var existLink = document.getElementById('yaktube-sidebar-apk-link');
|
var existLink = document.getElementById('yaktube-sidebar-apk-link');
|
||||||
@@ -2991,148 +2981,3 @@ try {
|
|||||||
});
|
});
|
||||||
checkAndInjectWatchPageComments();
|
checkAndInjectWatchPageComments();
|
||||||
})();
|
})();
|
||||||
|
|
||||||
// 5. Background Play (Screen-Off / Minimize) & MediaSession Lock-Screen Controls
|
|
||||||
(function initBackgroundPlaybackEngine() {
|
|
||||||
var videoState = {
|
|
||||||
hasPlayed: false,
|
|
||||||
explicitlyPausedByClick: false,
|
|
||||||
lastPlayTime: 0
|
|
||||||
};
|
|
||||||
|
|
||||||
function attachVideoListeners(video) {
|
|
||||||
if (!video || video.hasAttribute('data-yaktube-bgplay-hooked')) return;
|
|
||||||
video.setAttribute('data-yaktube-bgplay-hooked', 'true');
|
|
||||||
|
|
||||||
video.addEventListener('play', function () {
|
|
||||||
videoState.hasPlayed = true;
|
|
||||||
videoState.explicitlyPausedByClick = false;
|
|
||||||
videoState.lastPlayTime = Date.now();
|
|
||||||
updateMediaSessionMetadata(video);
|
|
||||||
});
|
|
||||||
|
|
||||||
video.addEventListener('ended', function () {
|
|
||||||
videoState.hasPlayed = false;
|
|
||||||
videoState.explicitlyPausedByClick = true;
|
|
||||||
});
|
|
||||||
|
|
||||||
video.addEventListener('timeupdate', function () {
|
|
||||||
updateMediaSessionPosition(video);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// Hook manual play/pause buttons
|
|
||||||
document.addEventListener(
|
|
||||||
'click',
|
|
||||||
function (e) {
|
|
||||||
var target = e.target;
|
|
||||||
if (!target) return;
|
|
||||||
var btn = target.closest(
|
|
||||||
'.vjs-play-control, button[title*="Duraklat"], button[aria-label*="Duraklat"], #yaktube-bar-play-btn'
|
|
||||||
);
|
|
||||||
if (btn) {
|
|
||||||
var video = getVideoElement();
|
|
||||||
if (video && !video.paused) {
|
|
||||||
videoState.explicitlyPausedByClick = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
true
|
|
||||||
);
|
|
||||||
|
|
||||||
function handleVisibilityChange() {
|
|
||||||
var video = getVideoElement();
|
|
||||||
if (!video) return;
|
|
||||||
|
|
||||||
// When screen turns off / tab is hidden:
|
|
||||||
if (document.hidden || document.webkitHidden) {
|
|
||||||
if (videoState.hasPlayed && !videoState.explicitlyPausedByClick) {
|
|
||||||
// Unconditionally keep audio stream active
|
|
||||||
setTimeout(function () {
|
|
||||||
if (video.paused && !videoState.explicitlyPausedByClick) {
|
|
||||||
video.play().catch(function () {});
|
|
||||||
}
|
|
||||||
}, 100);
|
|
||||||
setTimeout(function () {
|
|
||||||
if (video.paused && !videoState.explicitlyPausedByClick) {
|
|
||||||
video.play().catch(function () {});
|
|
||||||
}
|
|
||||||
}, 300);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
document.addEventListener('visibilitychange', handleVisibilityChange, false);
|
|
||||||
document.addEventListener('webkitvisibilitychange', handleVisibilityChange, false);
|
|
||||||
window.addEventListener('pagehide', handleVisibilityChange, false);
|
|
||||||
|
|
||||||
// MediaSession API Integration (Lock Screen, Bluetooth, Smart Watches)
|
|
||||||
function updateMediaSessionMetadata(video) {
|
|
||||||
if (!('mediaSession' in navigator)) return;
|
|
||||||
|
|
||||||
var titleEl = document.querySelector('h1.video-title, .video-name, my-video-watch h1, .title');
|
|
||||||
var title = titleEl ? titleEl.textContent.trim() : 'YakTube Video';
|
|
||||||
var authorEl = document.querySelector('.actor-name, .channel-name, .video-channel-name, a.actor-link');
|
|
||||||
var artist = authorEl ? authorEl.textContent.trim() : 'YakTube';
|
|
||||||
|
|
||||||
var artwork = [];
|
|
||||||
var thumbEl = document.querySelector('meta[property="og:image"]');
|
|
||||||
if (thumbEl && thumbEl.content) {
|
|
||||||
artwork.push({ src: thumbEl.content, sizes: '512x512', type: 'image/jpeg' });
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
|
||||||
navigator.mediaSession.metadata = new MediaMetadata({
|
|
||||||
title: title,
|
|
||||||
artist: artist,
|
|
||||||
album: 'YakTube',
|
|
||||||
artwork: artwork
|
|
||||||
});
|
|
||||||
|
|
||||||
navigator.mediaSession.setActionHandler('play', function () {
|
|
||||||
video.play();
|
|
||||||
announce('Video oynatılıyor.');
|
|
||||||
});
|
|
||||||
navigator.mediaSession.setActionHandler('pause', function () {
|
|
||||||
videoState.pausedByUser = true;
|
|
||||||
video.pause();
|
|
||||||
announce('Video duraklatıldı.');
|
|
||||||
});
|
|
||||||
navigator.mediaSession.setActionHandler('seekbackward', function (details) {
|
|
||||||
var skipTime = details.seekOffset || 10;
|
|
||||||
video.currentTime = Math.max(0, video.currentTime - skipTime);
|
|
||||||
announce(skipTime + ' saniye geri sarıldı.');
|
|
||||||
});
|
|
||||||
navigator.mediaSession.setActionHandler('seekforward', function (details) {
|
|
||||||
var skipTime = details.seekOffset || 10;
|
|
||||||
video.currentTime = Math.min(video.duration || 99999, video.currentTime + skipTime);
|
|
||||||
announce(skipTime + ' saniye ileri sarıldı.');
|
|
||||||
});
|
|
||||||
navigator.mediaSession.setActionHandler('stop', function () {
|
|
||||||
videoState.pausedByUser = true;
|
|
||||||
video.pause();
|
|
||||||
});
|
|
||||||
} catch (e) {}
|
|
||||||
}
|
|
||||||
|
|
||||||
function updateMediaSessionPosition(video) {
|
|
||||||
if (!('mediaSession' in navigator) || !navigator.mediaSession.setPositionState) return;
|
|
||||||
if (isNaN(video.duration) || isNaN(video.currentTime) || video.duration <= 0) return;
|
|
||||||
try {
|
|
||||||
navigator.mediaSession.setPositionState({
|
|
||||||
duration: video.duration,
|
|
||||||
playbackRate: video.playbackRate || 1,
|
|
||||||
position: Math.min(video.currentTime, video.duration)
|
|
||||||
});
|
|
||||||
} catch (e) {}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Auto-hook active video elements
|
|
||||||
setInterval(function () {
|
|
||||||
var video = getVideoElement();
|
|
||||||
if (video) attachVideoListeners(video);
|
|
||||||
}, 1000);
|
|
||||||
})();
|
|
||||||
} catch (err) {
|
|
||||||
console.error('[YakTube] Safe catch error:', err);
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,144 @@
|
|||||||
|
# NLnet Foundation / NGI Zero Grant Application Dossier
|
||||||
|
|
||||||
|
## Project: YakTube (Accessible & Lightweight ActivityPub Media Engine)
|
||||||
|
|
||||||
|
> **Belge Amacı:** Bu dosya, 3 Eylül 2026 tarihinde açılacak olan **NLnet NGI Zero Commons Trust / Digital Accessibility** hibe çağrısı için hazırlanmış resmi İngilizce başvuru taslağıdır. Formdaki sorulara göre kopyala-yapıştır yapmaya hazır şekilde yapılandırılmıştır.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### 1. General & Contact Information / Genel ve İletişim Bilgileri
|
||||||
|
|
||||||
|
- **Project Name (Proje Adı):**
|
||||||
|
`YakTube: Accessible, Lightweight & Decentralized ActivityPub Media Engine`
|
||||||
|
- **Applicant / Contact Person (Başvuran Kişi):**
|
||||||
|
`Enes Yakıştır`
|
||||||
|
- **Email Address (E-posta):**
|
||||||
|
`[email protected]`
|
||||||
|
- **Country (Ülke):**
|
||||||
|
`Turkey`
|
||||||
|
- **Organization / Community (Organizasyon):**
|
||||||
|
`YakNet (YakHub Open Source Accessibility Initiative)`
|
||||||
|
- **Website / Live Demo URL (Canlı Demo):**
|
||||||
|
`https://yaktube.yakhub.com.tr`
|
||||||
|
- **Source Code Repositories (Açık Kaynak Kod Depoları):**
|
||||||
|
- **On-Demand & A11y Plugin (Primary):** `https://yakhub.com.tr/YakNet/peertube-plugin-yaktube-ondemand`
|
||||||
|
- **On-Demand & A11y Plugin (GitHub Mirror):** `https://github.com/yakistir98/peertube-plugin-yaktube-ondemand`
|
||||||
|
- **On-Demand & A11y Plugin (Official NPM Registry):** `https://www.npmjs.com/package/peertube-plugin-yaktube-ondemand`
|
||||||
|
- **YakNet SSO Auth Plugin (Primary):** `https://yakhub.com.tr/YakNet/peertube-plugin-auth-yaknet`
|
||||||
|
- **YakNet SSO Auth Plugin (GitHub Mirror):** `https://github.com/yakistir98/peertube-plugin-auth-yaknet`
|
||||||
|
- **YakNet SSO Auth Plugin (Official NPM Registry):** `https://www.npmjs.com/package/peertube-plugin-auth-yaknet`
|
||||||
|
- **Project License (Açık Kaynak Lisansı):**
|
||||||
|
`AGPLv3 / MIT (OSI-Approved Free & Open Source Licenses)`
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### 1.1 Verified Banking Details / Resmi Banka ve Ödeme Bilgileri (Hakediş İçin Hazır)
|
||||||
|
|
||||||
|
- **Bank Name (Banka):** `Yapı ve Kredi Bankası A.Ş. (Yapı Kredi)`
|
||||||
|
- **Account Holder (Hesap Sahibi):** `Enes Yakıştır`
|
||||||
|
- **Currency (Para Birimi):** `EUR (Euro Vadesiz Hesap)`
|
||||||
|
- **IBAN (Euro IBAN):** `TR350006701000000319490793`
|
||||||
|
- **SWIFT / BIC Code:** `YAPITRIS`
|
||||||
|
- **Country:** `Turkey`
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### 2. Short Project Summary (Abstract) / Proje Kısa Özeti
|
||||||
|
|
||||||
|
_(Formda "Explain the project in simple terms" kısmına yapıştırılacak İngilizce metin)_
|
||||||
|
|
||||||
|
**English Text:**
|
||||||
|
|
||||||
|
> "YakTube is a lightweight, screen-reader-first media syndication engine and client built on top of the open-source PeerTube/ActivityPub ecosystem. While commercial video platforms (like YouTube) and existing alternative frontends suffer from heavy JavaScript bloat, dynamic DOM instability, intrusive tracking, and poor screen-reader accessibility, YakTube provides a 100% WCAG 2.1 AAA-compliant, ad-free streaming and on-demand caching bridge. Developed directly by visually impaired engineers, YakTube includes a specialized PeerTube plugin, an on-demand ingestion bridge, and a sub-5MB native mobile client designed for seamless TalkBack and NVDA screen-reader navigation.
|
||||||
|
>
|
||||||
|
> **Primary Target Beneficiaries:** Blind and visually impaired internet users, assistive technology communities, low-bandwidth regions, and decentralized Fediverse instance administrators seeking European Accessibility Act (EAA) compliance."
|
||||||
|
|
||||||
|
**Türkçe Açıklaması:**
|
||||||
|
YakTube, PeerTube ve ActivityPub ekosistemi üzerinde inşa edilmiş, ekran okuyucu odaklı, hafif bir medya platformu ve istemcisidir. Ticari platformların reklam ve erişilebilirlik engellerini ortadan kaldırarak; görme engelli yazılımcılar tarafından geliştirilmiş %100 WCAG 2.1 AAA uyumlu, reklamsız, 4.5 MB hafif mobil istemcili bir açık kaynak çözümü sunar.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### 3. The Challenge / Problem ve Çözülmek İstenen Zorluk
|
||||||
|
|
||||||
|
_(Formda "What is the problem you are trying to solve?" kısmına yapıştırılacak metin)_
|
||||||
|
|
||||||
|
**English Text:**
|
||||||
|
|
||||||
|
> "Access to digital multimedia remains one of the greatest barriers for visually impaired, blind, and assistive-technology users worldwide.
|
||||||
|
>
|
||||||
|
> 1. **Commercial Monopolies:** Mainstream platforms prioritize visual advertising algorithms, dynamic popups, and non-semantic DOM trees that severely degrade screen-reader experiences (TalkBack, NVDA, VoiceOver).
|
||||||
|
> 2. **Fragility of Scraper Frontends:** Public proxy instances (such as Invidious or Piped) regularly break due to upstream bot-guard countermeasures, lack decentralized ActivityPub federation, and offer zero specialized accessibility audits.
|
||||||
|
> 3. **The Fediverse Accessibility Void:** While PeerTube is the gold standard for decentralized video federation, vanilla instances lack built-in screen-reader ARIA live regions, simplified audio/podcast streaming layouts, and ultra-lightweight mobile clients for low-end devices.
|
||||||
|
>
|
||||||
|
> YakTube directly tackles these issues by engineering an upstream-compatible accessibility layer that empowers blind users to search, cache, stream, and federate media freely without surveillance or assistive barriers."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### 4. Technical Architecture & Innovation / Teknik Çözüm ve İnovasyon
|
||||||
|
|
||||||
|
_(Formda "What is the proposed solution and technical approach?" kısmına yapıştırılacak metin)_
|
||||||
|
|
||||||
|
**English Text:**
|
||||||
|
|
||||||
|
> "YakTube delivers a three-tier technical innovation:
|
||||||
|
>
|
||||||
|
> 1. **WCAG 2.1 AAA Screen-Reader & Pro Video Player Engine:** Re-architecting the web and client interface with strict semantic HTML5, explicit ARIA live regions, natural hands-free voice search (`Web Speech API`), full-featured YouTube keyboard navigation (`Space/K` play-pause, `J/L` 10s seek, `Left/Right` 5s seek, `T` Theater Mode, `I` Instant Video Stats, `C` Subtitles, `0-9` percentage jumps, `>/<` playback speed steps, `Shift+V`, `/`, `Escape`), and distraction-free audio playback modes.
|
||||||
|
> 2. **On-Demand ActivityPub Syndication Bridge:** A custom Node.js and PeerTube plugin controller that accepts search queries, validates media availability, performs automated channel routing (Music, Podcasts, Tech), and caches streams with an automated pruning lifecycle to conserve bandwidth and storage.
|
||||||
|
> 3. **Sub-5MB Native Mobile Client:** A zero-telemetry, lightweight Android client (`tr.com.yaknet.yaktube`) engineered specifically for TalkBack gesture control, eliminating background memory overhead and providing offline cached listening."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### 5. Upstream Ecosystem Benefit / Ekosisteme ve Açık İnternete Faydası
|
||||||
|
|
||||||
|
_(Formda "How will this contribute to the open internet / NGI ecosystem?" kısmına yapıştırılacak metin)_
|
||||||
|
|
||||||
|
**English Text:**
|
||||||
|
|
||||||
|
> "YakTube is not a private silo; all core components are packaged as reusable open-source modules:
|
||||||
|
>
|
||||||
|
> - Any existing PeerTube administrator in the global Fediverse can install the `peertube-plugin-yaktube-ondemand` package with a single click to instantly make their instance 100% accessible to visually impaired communities.
|
||||||
|
> - The native Android client source code will be published as an accessible open-source template for ActivityPub media clients.
|
||||||
|
> - Full compliance with the **European Accessibility Act (EAA)** guidelines, providing a reference implementation for inclusive Fediverse software."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### 6. Work Plan, Milestones & Budget Breakdown / Çalışma Planı ve Bütçe
|
||||||
|
|
||||||
|
_(Talep Edilen Toplam Hibe: **5.000 €** - Geliştirici Ar-Ge Emeği / Developer Labor)_
|
||||||
|
|
||||||
|
#### 📍 Milestone 1: Advanced Screen-Reader Accessibility & WCAG 2.1 AAA Compliance
|
||||||
|
|
||||||
|
- **Estimated Labor:** 50 Hours (Developer R&D / A11y Engineering)
|
||||||
|
- **Budget Allocation:** **2.000 €**
|
||||||
|
- **Deliverables:**
|
||||||
|
- Full keyboard-only and screen-reader audit (NVDA, TalkBack, Orca).
|
||||||
|
- ARIA live region announcements for player states (buffering, playing, volume, subtitles).
|
||||||
|
- High-contrast accessible theme and automated accessibility regression test suite.
|
||||||
|
|
||||||
|
#### 📍 Milestone 2: Native Lightweight Android Client & Upstream Plugin Packaging
|
||||||
|
|
||||||
|
- **Estimated Labor:** 50 Hours (Mobile Client & API Integration)
|
||||||
|
- **Budget Allocation:** **2.000 €**
|
||||||
|
- **Deliverables:**
|
||||||
|
- Open-source release of the sub-5MB native Android client on YakHub and GitHub with APK builds.
|
||||||
|
- Complete TalkBack gesture optimization and background playback support.
|
||||||
|
- NPM packaging of `peertube-plugin-yaktube-ondemand` for standard PeerTube installations.
|
||||||
|
|
||||||
|
#### 📍 Milestone 3: Documentation, Fediverse CI/CD & Production Testing
|
||||||
|
|
||||||
|
- **Estimated Labor:** 25 Hours (DevOps, Documentation & Auditing)
|
||||||
|
- **Budget Allocation:** **1.000 €**
|
||||||
|
- **Deliverables:**
|
||||||
|
- Comprehensive English & Turkish installation and developer documentation on YakHub/GitHub.
|
||||||
|
- Multi-instance ActivityPub federation testing and automated containerized deployment scripts.
|
||||||
|
- Public final milestone report and live release validation.
|
||||||
|
|
||||||
|
- **TOTAL REQUESTED GRANT:** **5.000 €**
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### 7. Why We Are Uniquely Qualified / Neden Bu Projeyi Biz Başarabiliriz?
|
||||||
|
|
||||||
|
**English Text:**
|
||||||
|
|
||||||
|
> "The project lead is a passionate visually impaired software engineer who lives with assistive technology daily. Rather than treating accessibility as an external afterthought, YakTube is built from the ground up through lived experience, practical engineering, and deep commitment to open-source digital sovereignty. A fully functioning live prototype (`yaktube.yakhub.com.tr`) and working APK are already operational, demonstrating technical capability and guaranteed milestone delivery."
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "peertube-plugin-yaktube-ondemand",
|
"name": "peertube-plugin-yaktube-ondemand",
|
||||||
"version": "1.4.12",
|
"version": "1.4.6",
|
||||||
"description": "Accessible On-Demand YouTube Import, Live Streams, Smart Recommendations and A11y Engine for PeerTube",
|
"description": "Accessible On-Demand YouTube Import, Live Streams, Smart Recommendations and A11y Engine for PeerTube",
|
||||||
"main": "main.js",
|
"main": "main.js",
|
||||||
"library": "./main.js",
|
"library": "./main.js",
|
||||||
|
|||||||
@@ -1,29 +1,3 @@
|
|||||||
/* Permanent Aggressive Suppression of Generic JoinPeerTube / Framasoft Open-in-App Banners */
|
|
||||||
my-open-app,
|
|
||||||
my-open-in-app,
|
|
||||||
my-client-app-banner,
|
|
||||||
.open-app-container,
|
|
||||||
.app-banner,
|
|
||||||
[class*='open-app'],
|
|
||||||
[class*='open-in-app'],
|
|
||||||
.mobile-app-banner,
|
|
||||||
.app-promotion,
|
|
||||||
.client-app-banner,
|
|
||||||
a[href*='play.google.com/store/apps/details?id=app.joinpeertube'],
|
|
||||||
a[href*='f-droid.org'],
|
|
||||||
a[href*='joinpeertube'] {
|
|
||||||
display: none !important;
|
|
||||||
visibility: hidden !important;
|
|
||||||
height: 0 !important;
|
|
||||||
width: 0 !important;
|
|
||||||
margin: 0 !important;
|
|
||||||
padding: 0 !important;
|
|
||||||
pointer-events: none !important;
|
|
||||||
opacity: 0 !important;
|
|
||||||
position: absolute !important;
|
|
||||||
z-index: -99999 !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* YakTube Accessibility & On-Demand CSS */
|
/* YakTube Accessibility & On-Demand CSS */
|
||||||
|
|
||||||
:focus-visible {
|
:focus-visible {
|
||||||
|
|||||||
Reference in New Issue
Block a user