Skip to content

Commit 8d431e1

Browse files
committed
feat(agent-tars-web-ui): enhance go to task history
1 parent 0f67d33 commit 8d431e1

File tree

1 file changed

+17
-8
lines changed

1 file changed

+17
-8
lines changed

multimodal/agent-tars-web-ui/src/v2/components/Welcome/WelcomePage.tsx

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import {
88
FiMonitor,
99
FiFile,
1010
FiZap,
11-
FiMessageSquare,
11+
FiArrowUpRight,
1212
} from 'react-icons/fi';
1313
import { useSession } from '../../hooks/useSession';
1414

@@ -245,23 +245,28 @@ const WelcomePage: React.FC = () => {
245245
className="flex justify-end mt-2 mr-1"
246246
>
247247
<motion.button
248-
whileHover={{ scale: 1.05 }}
249-
whileTap={{ scale: 0.95 }}
248+
whileHover={{ scale: 1.01 }}
249+
whileTap={{ scale: 0.98 }}
250250
onClick={handleDirectChat}
251251
disabled={isLoading || isDirectChatLoading}
252-
className={`flex items-center gap-1 px-3 py-1.5 rounded-3xl text-sm text-gray-700 dark:text-gray-200 bg-white dark:bg-gray-800 border border-gray-200/70 dark:border-gray-700/30 shadow-sm hover:shadow transition-all duration-200 ${
253-
isLoading || isDirectChatLoading ? 'opacity-60 cursor-not-allowed' : ''
252+
className={`flex items-center gap-1.5 py-1 text-sm text-gray-500 dark:text-gray-400 relative group transition-colors duration-300 ${
253+
isLoading || isDirectChatLoading
254+
? 'opacity-60 cursor-not-allowed'
255+
: 'cursor-pointer group-hover:text-gray-900 dark:group-hover:text-gray-100'
254256
}`}
255257
type="button"
256258
>
259+
<span className="group-hover:text-gray-900 dark:group-hover:text-gray-100 transition-colors duration-300">
260+
Go to task history
261+
</span>
257262
{isDirectChatLoading ? (
258263
<motion.div
259264
animate={{ rotate: 360 }}
260265
transition={{ duration: 1, repeat: Infinity, ease: 'linear' }}
261266
className="w-4 h-4"
262267
>
263268
<svg
264-
className="w-4 h-4 text-accent-500"
269+
className="w-4 h-4 text-gray-500 dark:text-gray-400"
265270
viewBox="0 0 24 24"
266271
fill="none"
267272
xmlns="http://www.w3.org/2000/svg"
@@ -276,9 +281,13 @@ const WelcomePage: React.FC = () => {
276281
</svg>
277282
</motion.div>
278283
) : (
279-
<FiMessageSquare className="text-accent-500" size={14} />
284+
<FiArrowUpRight
285+
className="text-gray-500 dark:text-gray-400 group-hover:text-gray-900 dark:group-hover:text-gray-100 transition-colors duration-300"
286+
size={14}
287+
/>
280288
)}
281-
<span>Go to task history</span>
289+
{/* 添加下划线动画效果 - 黑白风格 */}
290+
<span className="absolute bottom-0 left-0 w-0 h-[1px] bg-gray-500 dark:bg-gray-400 group-hover:w-full group-hover:bg-gray-900 dark:group-hover:bg-gray-100 transition-all duration-300"></span>
282291
</motion.button>
283292
</motion.div>
284293

0 commit comments

Comments
 (0)