MCPcopy Create free account
hub / github.com/BingyanStudio/github-analyzer / ReportActions

Function ReportActions

web/src/components/report/ReportActions.tsx:13–51  ·  view source on GitHub ↗
({
  isLoading,
  hasReport,
  onBackToDashboard,
  onRegenerateReport,
  onGenerateImage,
}: ReportActionsProps)

Source from the content-addressed store, hash-verified

11}
12
13const ReportActions = ({
14 isLoading,
15 hasReport,
16 onBackToDashboard,
17 onRegenerateReport,
18 onGenerateImage,
19}: ReportActionsProps) => {
20 return (
21 <CardFooter className="flex flex-wrap justify-center gap-3 px-6 py-4 border-t bg-primary/5">
22 <Button onClick={onBackToDashboard} variant="outline">
23 返回仪表盘
24 </Button>
25 <Button
26 onClick={onRegenerateReport}
27 variant="default"
28 disabled={isLoading}
29 >
30 {isLoading ? (
31 <>
32 <Loader2 className="mr-2 h-4 w-4 animate-spin" />
33 重新生成中...
34 </>
35 ) : (
36 <>
37 <RefreshCw className="mr-2 h-4 w-4" />
38 重新生成
39 </>
40 )}
41 </Button>
42 <Button
43 onClick={onGenerateImage}
44 variant="secondary"
45 disabled={isLoading || !hasReport}
46 >
47 生成分享图片
48 </Button>
49 </CardFooter>
50 );
51};
52
53export default ReportActions;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected