Skip to content

Commit 2babfc5

Browse files
committed
🚸 win/linux系统下,鼠标移动到最右上角自动出现关闭按钮
1 parent 45de3f8 commit 2babfc5

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

app/src/pages/_app.tsx

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -437,6 +437,17 @@ export default function App() {
437437
</Button>
438438
)}
439439
</div>
440+
{/* @鹿松狸,鼠标移动到最右上角出现关闭窗口按钮 */}
441+
{!isMac && !isWindowCollapsing && (
442+
<div
443+
className="fixed right-0 top-0 z-50 size-1 cursor-pointer bg-amber-200 transition-all hover:size-14 hover:rounded-bl-2xl hover:bg-red-500"
444+
onClick={() => {
445+
console.log("click Right top");
446+
}}
447+
>
448+
<X className="cursor-pointer" />
449+
</div>
450+
)}
440451

441452
{/* 面板列表 */}
442453
<AppMenu className="absolute left-4 top-16 z-20" open={isMenuOpen} />

0 commit comments

Comments
 (0)