mirror of
https://github.com/Portabase/portabase.git
synced 2026-07-14 11:16:13 +02:00
19 lines
571 B
TypeScript
19 lines
571 B
TypeScript
import {FileText} from "lucide-react";
|
|
import {JobLog} from "@/db/schema/17_job-log";
|
|
import {Button} from "@/components/ui/button";
|
|
import {useLogsModal} from "@/features/logs/components/logs-modal-context";
|
|
|
|
export type LogsModalTriggerProps = {
|
|
logs: JobLog[]
|
|
}
|
|
|
|
export const LogsModalTrigger = ({logs}: LogsModalTriggerProps) => {
|
|
const {openModal} = useLogsModal();
|
|
return (
|
|
<Button disabled={logs.length == 0} variant="outline" size="sm" onClick={()=> {
|
|
openModal(logs);
|
|
}}>
|
|
<FileText />
|
|
</Button>
|
|
)
|
|
} |