@@ -550,15 +550,20 @@ export default function Header() {
550550 </ button >
551551 </ div >
552552
553- { /* 移动端只显示登录和菜单按钮 */ }
553+ { /* 移动端只显示创建计时器和菜单按钮 */ }
554554 < div className = "flex items-center md:hidden" >
555- { /* 移动端登录按钮 */ }
555+ { /* 移动端创建计时器按钮 */ }
556556 < button
557557 className = "p-2 rounded-full btn-glass-hover text-gray-700 dark:text-gray-300 cursor-pointer"
558- onClick = { openLoginModal }
559- data-umami-event = { t ( 'header.login' ) }
558+ onClick = { ( ) => {
559+ setIsTimerTypeModalOpen ( true ) ;
560+ if ( window . location . hash !== '#add' ) {
561+ window . location . hash = 'add' ;
562+ }
563+ } }
564+ data-umami-event = { t ( 'timer.create' ) }
560565 >
561- < FiUser className = "text-xl" />
566+ < FiPlus className = "text-xl" />
562567 </ button >
563568
564569 { /* 移动端菜单按钮 */ }
@@ -639,20 +644,17 @@ export default function Header() {
639644 < span className = "text-xs ml-2 flex-1 text-right" > { t ( 'header.settings' ) } </ span >
640645 </ button >
641646
642- { /* 添加"添加计时器 "按钮 */ }
647+ { /* 添加"登录 "按钮 */ }
643648 < button
644649 className = "flex items-center justify-between p-3 rounded-lg bg-white/10 dark:bg-black/10 backdrop-blur-sm border border-gray-200/60 dark:border-white/10 text-gray-700 dark:text-gray-300 hover:bg-white/20 dark:hover:bg-black/20 cursor-pointer transition-colors"
645650 onClick = { ( ) => {
646- setIsTimerTypeModalOpen ( true ) ;
651+ openLoginModal ( ) ;
647652 setIsMenuOpen ( false ) ;
648- if ( window . location . hash !== '#add' ) {
649- window . location . hash = 'add' ;
650- }
651653 } }
652- data-umami-event = { t ( 'timer.create ' ) }
654+ data-umami-event = { t ( 'header.login ' ) }
653655 >
654- < FiPlus className = "text-xl" />
655- < span className = "text-xs ml-2 flex-1 text-right" > { t ( 'timer.create ' ) } </ span >
656+ < FiUser className = "text-xl" />
657+ < span className = "text-xs ml-2 flex-1 text-right" > { t ( 'header.login ' ) } </ span >
656658 </ button >
657659
658660 { /* 添加"分享"按钮 */ }
0 commit comments