import React, { useState } from 'react' import { Dialog } from '@jbrowse/core/ui' import { getSession } from '@jbrowse/core/util' import { Button, DialogActions, DialogContent, FormControl, FormControlLabel, Radio, RadioGroup, TextField, Typography, } from '@mui/material' import { observer } from 'mobx-react' import { jsonfetch } from '../../fetchUtils.ts' import type { InterProScanResponse } from '../../launchInterProScan.ts' import type { MsaViewModel } from '../../model.ts' const UserProvidedDomainsDialog = observer(function ({ handleClose, model, }: { handleClose: () => void model: MsaViewModel }) { const [file, setFile] = useState() const [choice, setChoice] = useState('file') const [interProURL, setInterProURL] = useState('') return ( { handleClose() }} open >
Open a JSON file of InterProScan results that you run remotely on EBI servers or locally
{ setChoice(event.target.value) }} > } label="URL" /> } label="File" /> {choice === 'url' ? (
Open a InterProScan JSON file remote URL { setInterProURL(event.target.value) }} />
) : null} {choice === 'file' ? (
Open a InterProScan JSON file file from your local drive
) : null}
) }) export default UserProvidedDomainsDialog