'use client' import type { WorkReviewAnnotationShape } from '@/types/work-review' export const WORK_REVIEW_ANNOTATION_COLORS = [ { value: '#0050cb', label: '蓝色' }, { value: '#d92d20', label: '红色' }, { value: '#087a3c', label: '绿色' }, { value: '#8a5200', label: '棕色' }, { value: '#101828', label: '黑色' }, { value: '#ffffff', label: '白色' }, ] as const export type WorkReviewDrawingTool = Exclude const TOOLS: Array<{ value: WorkReviewDrawingTool; label: string }> = [ { value: 'rectangle', label: '矩形框选' }, { value: 'ellipse', label: '椭圆框选' }, { value: 'arrow', label: '箭头标注' }, ] function ToolIcon({ tool }: { tool: WorkReviewDrawingTool }) { if (tool === 'rectangle') { return } if (tool === 'ellipse') { return } return ( <> ) } export function WorkReviewAnnotationToolbar({ tool, color, canUndo, onToolChange, onColorChange, onUndo, onClose, }: { tool: WorkReviewDrawingTool color: string canUndo: boolean onToolChange: (tool: WorkReviewDrawingTool) => void onColorChange: (color: string) => void onUndo: () => void onClose: () => void }) { return (
{TOOLS.map((item) => ( ))}
) }