diff --git a/apps/rowboat/app/projects/[projectId]/sources/new/form.tsx b/apps/rowboat/app/projects/[projectId]/sources/new/form.tsx
index 6a4c8f5f..32a4f7d7 100644
--- a/apps/rowboat/app/projects/[projectId]/sources/new/form.tsx
+++ b/apps/rowboat/app/projects/[projectId]/sources/new/form.tsx
@@ -24,28 +24,34 @@ export function Form({
const [sourceType, setSourceType] = useState("");
const router = useRouter();
- const dropdownOptions = [
+ let dropdownOptions = [
{
key: "text",
label: "Text",
startContent:
},
- {
- key: "urls",
- label: "Scrape URLs",
- startContent:
- },
- {
+ ];
+ if (useRagUploads) {
+ dropdownOptions.push({
key: "files_local",
label: "Upload files (Local)",
startContent:
- },
- {
+ });
+ }
+ if (useRagS3Uploads) {
+ dropdownOptions.push({
key: "files_s3",
label: "Upload files (S3)",
startContent:
- }
- ];
+ });
+ }
+ if (useRagScraping) {
+ dropdownOptions.push({
+ key: "urls",
+ label: "Scrape URLs",
+ startContent:
+ });
+ }
async function createUrlsDataSource(formData: FormData) {
const source = await createDataSource({
@@ -131,11 +137,6 @@ export function Form({
value={sourceType}
onChange={setSourceType}
options={dropdownOptions}
- disabledKeys={[
- ...(useRagUploads ? [] : ['files_local']),
- ...(useRagS3Uploads ? [] : ['files_s3']),
- ...(useRagScraping ? [] : ['urls']),
- ]}
/>
{sourceType === "urls" &&