| 1 | import { |
| 2 | type CheckpointDiffState, |
| 3 | type CheckpointDiffTarget, |
| 4 | } from "@t3tools/client-runtime/state/threads"; |
| 5 | |
| 6 | import { useCheckpointDiff as useCheckpointDiffQuery } from "../state/queries"; |
| 7 | |
| 8 | export function useCheckpointDiff( |
| 9 | target: CheckpointDiffTarget, |
| 10 | options?: { readonly enabled?: boolean }, |
| 11 | ): CheckpointDiffState { |
| 12 | const state = useCheckpointDiffQuery(target, options); |
| 13 | return { |
| 14 | data: state.data, |
| 15 | error: state.error, |
| 16 | isPending: state.isPending, |
| 17 | }; |
| 18 | } |