diff --git a/src/app/play/page.tsx b/src/app/play/page.tsx index 9246024..285177a 100644 --- a/src/app/play/page.tsx +++ b/src/app/play/page.tsx @@ -525,6 +525,11 @@ function PlayPageClient() { // 清理URL参数(移除index参数) if (searchParams.has('index')) { const newUrl = new URL(window.location.href); + newUrl.searchParams.set('year', detailData.year || 'unknown'); + newUrl.searchParams.set( + 'title', + detailData.title || videoTitleRef.current + ); newUrl.searchParams.delete('index'); newUrl.searchParams.delete('position'); window.history.replaceState({}, '', newUrl.toString()); diff --git a/src/components/EpisodeSelector.tsx b/src/components/EpisodeSelector.tsx index 419c0c9..bfc8361 100644 --- a/src/components/EpisodeSelector.tsx +++ b/src/components/EpisodeSelector.tsx @@ -522,25 +522,26 @@ const EpisodeSelector: React.FC = ({ {(() => { const sourceKey = `${source.source}-${source.id}`; const videoInfo = videoInfoMap.get(sourceKey); - - if (videoInfo && !videoInfo.hasError) { - return ( -
-
- {videoInfo.loadSpeed} + if (videoInfo) { + if (!videoInfo.hasError) { + return ( +
+
+ {videoInfo.loadSpeed} +
+
+ {videoInfo.pingTime}ms +
-
- {videoInfo.pingTime}ms + ); + } else { + return ( +
+ 无测速数据
-
- ); + ); // 占位div + } } - - return ( -
- 无测速数据 -
- ); // 占位div })()}