修复 Windows 会话名称和密钥显示图标

This commit is contained in:
电摇小子
2026-07-14 11:07:35 +08:00
committed by 电摇小子
parent 8bb9576f10
commit 995a95e8dc
4 changed files with 106 additions and 12 deletions
+33 -1
View File
@@ -4,6 +4,38 @@ import ChatWindow from './components/ChatWindow'
import { SettingsPanel } from './components/SettingsPanel'
import { Contact, Message } from '../../shared/types'
function EyeIcon({ hidden }: { hidden: boolean }): React.ReactElement {
return (
<svg viewBox="0 0 24 24" aria-hidden="true" focusable="false">
<path
d="M2.5 12s3.5-6 9.5-6 9.5 6 9.5 6-3.5 6-9.5 6-9.5-6-9.5-6Z"
fill="none"
stroke="currentColor"
strokeWidth="1.8"
strokeLinecap="round"
strokeLinejoin="round"
/>
<circle
cx="12"
cy="12"
r="3"
fill="none"
stroke="currentColor"
strokeWidth="1.8"
/>
{hidden && (
<path
d="M4 4l16 16"
fill="none"
stroke="currentColor"
strokeWidth="1.8"
strokeLinecap="round"
/>
)}
</svg>
)
}
interface SelfInfo {
wxid: string
nickname: string
@@ -760,7 +792,7 @@ function App(): React.ReactElement {
onClick={() => setShowDbKey(!showDbKey)}
title={showDbKey ? '隐藏密钥' : '显示密钥'}
>
{showDbKey ? '隐藏' : '显示'}
<EyeIcon hidden={showDbKey} />
</button>
</div>
<button
+16 -2
View File
@@ -740,11 +740,25 @@ body {
.login-input-toggle {
position: absolute;
right: 8px;
width: 28px;
height: 28px;
display: inline-flex;
align-items: center;
justify-content: center;
background: none;
border: none;
cursor: pointer;
padding: 4px 8px;
font-size: 18px;
padding: 0;
color: #111827;
}
.login-input-toggle svg {
width: 20px;
height: 20px;
}
.login-input-toggle:hover {
color: #07c160;
}
.login-btn {