跳到主要内容

Claude Cage · 面向 Claude 的隔离开发环境,支持桌面工作台、多账号、远程部署与移动端连接。上游 Lee-xeo/Claude-Cage 完整源码镜像,非灵栈原创;主许可 MIT,第三方组件遵循各自许可。来源:https://github.com/Lee-xeo/Claude-Cage 。手动同步,不附带 Release 安装包。

浏览文件

agent-icon.jsx

18 行 · 1.1 KB历史下载
1import React from "react";
2
3// Keep the account number legible in conversation rows.
4// The outline inherits the chrome color; the face uses the same UI font.
5export function AgentIcon({ accountNumber, size = 20 }) {
6 const number = Number.isInteger(accountNumber) && accountNumber > 0 ? String(accountNumber) : "";
7 return <svg className="agent-icon" width={size} height={size} viewBox="0 0 24 24"
8 fill="none" stroke="currentColor" strokeWidth="1.75" strokeLinecap="round" strokeLinejoin="round"
9 role="img" aria-label={number ? `Agent · 账号 ${number}` : "Agent"}>
10 <path d="M12 3v3M2 11v5m20-5v5" />
11 <rect x="4" y="6" width="16" height="15" rx="4" />
12 {number ? <text x="12" y="14" dominantBaseline="central" textAnchor="middle"
13 fill="currentColor" stroke="none" fontFamily="var(--ui-font-family, system-ui, sans-serif)"
14 fontSize={number.length === 1 ? 12 : number.length === 2 ? 10 : 8} fontWeight="700"
15 {...(number.length > 2 ? { textLength: 13, lengthAdjust: "spacingAndGlyphs" } : {})}>{number}</text>
16 : <><path d="M8.5 11v2m7-2v2M9 17h6" /></>}
17 </svg>;
18}