| 1 | import { GitBranch } from "lucide-react"; |
| 2 | import { useT } from "../lib/i18n"; |
| 3 | |
| 4 | export function ProjectTreeSessionBadges({ node, forkedFromLabel, recoveryLabel }: { |
| 5 | node: { historical?: boolean; historicalBranch?: boolean }; |
| 6 | forkedFromLabel?: string; |
| 7 | recoveryLabel?: string; |
| 8 | }) { |
| 9 | const t = useT(); |
| 10 | return <> |
| 11 | {node.historical && <span className="project-tree__topic-recovery">{t(node.historicalBranch ? "history.branchBadge" : "history.legacyBadge")}</span>} |
| 12 | {forkedFromLabel && <span className="project-tree__topic-recovery" title={forkedFromLabel}><GitBranch size={10} />{forkedFromLabel}</span>} |
| 13 | {recoveryLabel && <span className="project-tree__topic-recovery" title={recoveryLabel}>{recoveryLabel}</span>} |
| 14 | </>; |
| 15 | } |
| 16 |