import { convertFileSrc } from '@tauri-apps/api/tauri'; import classNames from 'classnames'; import type { HttpResponse } from '../../lib/models'; interface Props { response: HttpResponse; className?: string; } export function ImageViewer({ response, className }: Props) { if (response.bodyPath === null) { return
Empty response body
; } const src = convertFileSrc(response.bodyPath); return ( Response preview ); }