import React from 'react'; import { downloadBlob } from '@fortissimo/util'; export interface DownloadProps { value?: string; name?: string; } export function Download(props: DownloadProps) { return ( { e.preventDefault(); if (!props.value) return; await downloadBlob({ url: props.value, filename: props.name || props.value }); }} > {props.name || props.value || ''} ); }