diff --git a/components/top-navbar.tsx b/components/top-navbar.tsx
index 77f85150c..f51ab693f 100644
--- a/components/top-navbar.tsx
+++ b/components/top-navbar.tsx
@@ -6,6 +6,7 @@ import { Settings, ExternalLink, Briefcase, Images, Sparkles, Trophy, Building2,
import { Button } from "@/components/ui/button";
import { useTheme } from "next-themes";
import { useState, useEffect, useRef } from "react";
+import { createPortal } from "react-dom";
import {
DropdownMenu,
DropdownMenuContent,
@@ -152,7 +153,7 @@ export function TopNavbar({
setEditorImageUrl("");
};
- return (
+ const navContent = (
+ );
- {/* 功能教程弹窗 - 全屏居中 */}
- {showTutorialModal && currentTutorialVideo && (
-
{
+ setShowTutorialModal(false);
+ setCurrentTutorialVideo(null);
+ }}
+ >
+
e.stopPropagation()}
+ >
+ {/* 关闭按钮 */}
+
+
,
+ document.body
+ ) : null;
+
+ return (
+ <>
+ {navContent}
+ {videoModal}
+ >
);
}