diff --git a/frontend/src/upload/Upload.tsx b/frontend/src/upload/Upload.tsx index f0735bc9..0e45e8c5 100644 --- a/frontend/src/upload/Upload.tsx +++ b/frontend/src/upload/Upload.tsx @@ -4,8 +4,61 @@ import { useDropzone } from 'react-dropzone'; import { useDispatch } from 'react-redux'; import { ActiveState } from '../models/misc'; import { getDocs } from '../preferences/preferenceApi'; +import Arrow2 from '../assets/dropdown-arrow.svg'; import { setSourceDocs } from '../preferences/preferenceSlice'; - +type urlOption = { + label: string, + value: string +} | null +function DropdownUrlType({ + options, + selectedOption, + onSelect, +}: { + options: urlOption[]; + selectedOption: urlOption; + onSelect: (value: urlOption) => void; +}) { + const [isOpen, setIsOpen] = useState(false); + return ( +
Upload New Documentation
-- Please upload .pdf, .txt, .rst, .docx, .md, .zip limited to 25mb -
- setDocName(e.target.value)} - > -Uploaded Files
- {files.map((file) => ( -- {file.name} -
- ))} - {files.length === 0 &&None
} ++ Please upload .pdf, .txt, .rst, .docx, .md, .zip limited to 25mb +
+Uploaded Files
+ {files.map((file) => ( ++ {file.name} +
+ ))} + {files.length === 0 &&None
} +