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
fix(watch): support PeerTube v8 /w/:slug URLs in transcript and continue watching
This commit is contained in:
@@ -1767,7 +1767,9 @@ try {
|
||||
var isTranscriptPanelOpen = false;
|
||||
|
||||
function getActiveWatchVideoSlug() {
|
||||
var m = window.location.pathname.match(/\/videos\/watch\/([a-zA-Z0-9_-]+)/);
|
||||
var m =
|
||||
window.location.pathname.match(/\/videos\/watch\/([a-zA-Z0-9_-]+)/) ||
|
||||
window.location.pathname.match(/\/w\/([a-zA-Z0-9_-]+)/);
|
||||
return m ? m[1] : null;
|
||||
}
|
||||
|
||||
@@ -2325,6 +2327,8 @@ try {
|
||||
modal.querySelector('#yaktube-queue-clear').addEventListener('click', function () {
|
||||
savePlayQueue([]);
|
||||
renderDrawer();
|
||||
var closeEl = modal.querySelector('#yaktube-queue-close');
|
||||
if (closeEl) closeEl.focus();
|
||||
announce('Çalma sırası tamamen temizlendi.');
|
||||
});
|
||||
modal.querySelectorAll('.yaktube-queue-play-one').forEach(function (b) {
|
||||
@@ -8970,13 +8974,25 @@ try {
|
||||
videoState.hasPlayed = false;
|
||||
videoState.explicitlyPausedByClick = true;
|
||||
try {
|
||||
recordContinueWatchingProgress(video, true);
|
||||
recordContinueWatchingProgress(video, true, true);
|
||||
} catch (e) {}
|
||||
try {
|
||||
showPostVideoUpNextOverlay();
|
||||
} catch (e) {}
|
||||
});
|
||||
|
||||
video.addEventListener('pause', function () {
|
||||
try {
|
||||
recordContinueWatchingProgress(video, false, true);
|
||||
} catch (e) {}
|
||||
});
|
||||
|
||||
video.addEventListener('seeked', function () {
|
||||
try {
|
||||
recordContinueWatchingProgress(video, false, true);
|
||||
} catch (e) {}
|
||||
});
|
||||
|
||||
video.addEventListener('timeupdate', function () {
|
||||
updateMediaSessionPosition(video);
|
||||
if (
|
||||
@@ -8988,7 +9004,7 @@ try {
|
||||
video.currentTime = abLoopState.a;
|
||||
}
|
||||
try {
|
||||
recordContinueWatchingProgress(video, false);
|
||||
recordContinueWatchingProgress(video, false, false);
|
||||
} catch (e) {}
|
||||
try {
|
||||
checkSmartPrefetchOnTimeUpdate(video);
|
||||
@@ -9159,13 +9175,13 @@ try {
|
||||
} catch (e) {}
|
||||
}
|
||||
|
||||
function recordContinueWatchingProgress(video, isEnded) {
|
||||
function recordContinueWatchingProgress(video, isEnded, forceSave) {
|
||||
if (!video || !isWatchUrl() || isEmbedUrl()) return;
|
||||
var slug = getActiveWatchVideoSlug();
|
||||
if (!slug) return;
|
||||
|
||||
var now = Date.now();
|
||||
if (!isEnded && now - lastContinueSaveTs < 4000) return;
|
||||
if (!isEnded && !forceSave && now - lastContinueSaveTs < 4000) return;
|
||||
|
||||
var dur = Number(video.duration || 0);
|
||||
var cur = Number(video.currentTime || 0);
|
||||
@@ -9199,7 +9215,7 @@ try {
|
||||
|
||||
var entry = {
|
||||
slug: slug,
|
||||
url: '/videos/watch/' + slug,
|
||||
url: '/w/' + slug,
|
||||
startTime: Math.floor(cur),
|
||||
duration: Math.floor(dur),
|
||||
pct: Math.min(99, Math.max(2, Math.round(ratio * 100))),
|
||||
@@ -9260,6 +9276,12 @@ try {
|
||||
.join('|');
|
||||
|
||||
var shelf = document.getElementById('yaktube-continue-watching-shelf');
|
||||
if (shelf && (!shelf.isConnected || !document.body.contains(shelf))) {
|
||||
try {
|
||||
shelf.remove();
|
||||
} catch (e) {}
|
||||
shelf = null;
|
||||
}
|
||||
if (shelf) {
|
||||
var curSig = shelf.getAttribute('data-render-sig');
|
||||
if (chipsBar && shelf.previousElementSibling !== chipsBar && chipsBar.parentElement) {
|
||||
|
||||
Reference in New Issue
Block a user