From 46ffbb5d9de6b006d76c511e31402e70be4f0355 Mon Sep 17 00:00:00 2001 From: anovazzi1 Date: Mon, 29 May 2023 22:54:22 -0300 Subject: [PATCH 1/7] added custom icons for companies, first version --- src/frontend/src/icons/Airbyte/airbyte.svg | 22 + src/frontend/src/icons/Airbyte/index.tsx | 8 + src/frontend/src/icons/AzLogo/az_logo.svg | 49 ++ src/frontend/src/icons/AzLogo/index.tsx | 8 + src/frontend/src/icons/Bing/bing.svg | 1 + src/frontend/src/icons/Bing/index.tsx | 8 + src/frontend/src/icons/ChromaIcon/index.tsx | 4 +- src/frontend/src/icons/Cohere/cohere.svg | 16 + src/frontend/src/icons/Cohere/index.tsx | 8 + .../src/icons/Evernote/evernote-icon.svg | 1 + src/frontend/src/icons/Evernote/index.tsx | 8 + .../Facebook_Messenger_logo_2020.svg | 2 + .../src/icons/FacebookMessenger/index.tsx | 8 + .../src/icons/GitBook/gitbook-svgrepo-com.svg | 2 + src/frontend/src/icons/GitBook/index.tsx | 8 + src/frontend/src/icons/Google/google.svg | 1 + src/frontend/src/icons/Google/index.tsx | 8 + .../src/icons/HuggingFace/hf-logo.svg | 8 + src/frontend/src/icons/HuggingFace/index.tsx | 8 + .../src/icons/IFixIt/ifixit-seeklogo.com.svg | 1 + src/frontend/src/icons/IFixIt/index.tsx | 8 + src/frontend/src/icons/Meta/index.tsx | 8 + src/frontend/src/icons/Meta/meta-icon.svg | 1 + .../src/icons/Midjorney/Midjourney_Emblem.svg | 53 +++ src/frontend/src/icons/Midjorney/index.tsx | 8 + src/frontend/src/icons/Notion/Notion-logo.svg | 4 + src/frontend/src/icons/Notion/index.tsx | 8 + src/frontend/src/icons/OpenAi/index.tsx | 8 + src/frontend/src/icons/OpenAi/openAI.svg | 1 + .../src/icons/PowerPoint/PowerPoint.svg | 52 +++ src/frontend/src/icons/PowerPoint/index.tsx | 8 + src/frontend/src/icons/QDrant/QDrant.svg | 20 + src/frontend/src/icons/QDrant/index.tsx | 8 + src/frontend/src/icons/ReadTheDocs/index.tsx | 8 + .../icons/ReadTheDocs/readthedocsio-icon.svg | 1 + src/frontend/src/icons/Searx/Searx_logo.svg | 198 ++++++++ src/frontend/src/icons/Searx/index.tsx | 8 + src/frontend/src/icons/Slack/index.tsx | 8 + src/frontend/src/icons/Slack/slack-icon.svg | 6 + src/frontend/src/icons/Weaviate/index.tsx | 8 + src/frontend/src/icons/Weaviate/weaviate.svg | 142 ++++++ .../src/icons/Wikipedia/Wikipedia.svg | 424 ++++++++++++++++++ src/frontend/src/icons/Wikipedia/index.tsx | 8 + src/frontend/src/icons/Wolfram/index.tsx | 8 + src/frontend/src/icons/Wolfram/wolfram.svg | 250 +++++++++++ src/frontend/src/icons/Word/index.tsx | 8 + src/frontend/src/icons/Word/word.svg | 50 +++ .../icons/hackerNews/Y_Combinator_logo.svg | 7 + src/frontend/src/icons/hackerNews/index.tsx | 8 + src/frontend/src/icons/index.tsx | 1 - src/frontend/src/utils.ts | 50 ++- 51 files changed, 1554 insertions(+), 5 deletions(-) create mode 100644 src/frontend/src/icons/Airbyte/airbyte.svg create mode 100644 src/frontend/src/icons/Airbyte/index.tsx create mode 100644 src/frontend/src/icons/AzLogo/az_logo.svg create mode 100644 src/frontend/src/icons/AzLogo/index.tsx create mode 100644 src/frontend/src/icons/Bing/bing.svg create mode 100644 src/frontend/src/icons/Bing/index.tsx create mode 100644 src/frontend/src/icons/Cohere/cohere.svg create mode 100644 src/frontend/src/icons/Cohere/index.tsx create mode 100644 src/frontend/src/icons/Evernote/evernote-icon.svg create mode 100644 src/frontend/src/icons/Evernote/index.tsx create mode 100644 src/frontend/src/icons/FacebookMessenger/Facebook_Messenger_logo_2020.svg create mode 100644 src/frontend/src/icons/FacebookMessenger/index.tsx create mode 100644 src/frontend/src/icons/GitBook/gitbook-svgrepo-com.svg create mode 100644 src/frontend/src/icons/GitBook/index.tsx create mode 100644 src/frontend/src/icons/Google/google.svg create mode 100644 src/frontend/src/icons/Google/index.tsx create mode 100644 src/frontend/src/icons/HuggingFace/hf-logo.svg create mode 100644 src/frontend/src/icons/HuggingFace/index.tsx create mode 100644 src/frontend/src/icons/IFixIt/ifixit-seeklogo.com.svg create mode 100644 src/frontend/src/icons/IFixIt/index.tsx create mode 100644 src/frontend/src/icons/Meta/index.tsx create mode 100644 src/frontend/src/icons/Meta/meta-icon.svg create mode 100644 src/frontend/src/icons/Midjorney/Midjourney_Emblem.svg create mode 100644 src/frontend/src/icons/Midjorney/index.tsx create mode 100644 src/frontend/src/icons/Notion/Notion-logo.svg create mode 100644 src/frontend/src/icons/Notion/index.tsx create mode 100644 src/frontend/src/icons/OpenAi/index.tsx create mode 100644 src/frontend/src/icons/OpenAi/openAI.svg create mode 100644 src/frontend/src/icons/PowerPoint/PowerPoint.svg create mode 100644 src/frontend/src/icons/PowerPoint/index.tsx create mode 100644 src/frontend/src/icons/QDrant/QDrant.svg create mode 100644 src/frontend/src/icons/QDrant/index.tsx create mode 100644 src/frontend/src/icons/ReadTheDocs/index.tsx create mode 100644 src/frontend/src/icons/ReadTheDocs/readthedocsio-icon.svg create mode 100644 src/frontend/src/icons/Searx/Searx_logo.svg create mode 100644 src/frontend/src/icons/Searx/index.tsx create mode 100644 src/frontend/src/icons/Slack/index.tsx create mode 100644 src/frontend/src/icons/Slack/slack-icon.svg create mode 100644 src/frontend/src/icons/Weaviate/index.tsx create mode 100644 src/frontend/src/icons/Weaviate/weaviate.svg create mode 100644 src/frontend/src/icons/Wikipedia/Wikipedia.svg create mode 100644 src/frontend/src/icons/Wikipedia/index.tsx create mode 100644 src/frontend/src/icons/Wolfram/index.tsx create mode 100644 src/frontend/src/icons/Wolfram/wolfram.svg create mode 100644 src/frontend/src/icons/Word/index.tsx create mode 100644 src/frontend/src/icons/Word/word.svg create mode 100644 src/frontend/src/icons/hackerNews/Y_Combinator_logo.svg create mode 100644 src/frontend/src/icons/hackerNews/index.tsx delete mode 100644 src/frontend/src/icons/index.tsx diff --git a/src/frontend/src/icons/Airbyte/airbyte.svg b/src/frontend/src/icons/Airbyte/airbyte.svg new file mode 100644 index 000000000..eefa1bceb --- /dev/null +++ b/src/frontend/src/icons/Airbyte/airbyte.svg @@ -0,0 +1,22 @@ + + + + + + diff --git a/src/frontend/src/icons/Airbyte/index.tsx b/src/frontend/src/icons/Airbyte/index.tsx new file mode 100644 index 000000000..c116b5ad2 --- /dev/null +++ b/src/frontend/src/icons/Airbyte/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as AirbyteSVG } from "./airbyte.svg"; + +export const AirbyteIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/AzLogo/az_logo.svg b/src/frontend/src/icons/AzLogo/az_logo.svg new file mode 100644 index 000000000..4f2e75777 --- /dev/null +++ b/src/frontend/src/icons/AzLogo/az_logo.svg @@ -0,0 +1,49 @@ + + diff --git a/src/frontend/src/icons/AzLogo/index.tsx b/src/frontend/src/icons/AzLogo/index.tsx new file mode 100644 index 000000000..96a8a058a --- /dev/null +++ b/src/frontend/src/icons/AzLogo/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as AzSVG } from "./az_logo.svg"; + +export const AzIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Bing/bing.svg b/src/frontend/src/icons/Bing/bing.svg new file mode 100644 index 000000000..0d93e379c --- /dev/null +++ b/src/frontend/src/icons/Bing/bing.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/src/icons/Bing/index.tsx b/src/frontend/src/icons/Bing/index.tsx new file mode 100644 index 000000000..abaf31be4 --- /dev/null +++ b/src/frontend/src/icons/Bing/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as BingSVG } from "./bing.svg"; + +export const BingIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/ChromaIcon/index.tsx b/src/frontend/src/icons/ChromaIcon/index.tsx index 2e4790edc..913d651f4 100644 --- a/src/frontend/src/icons/ChromaIcon/index.tsx +++ b/src/frontend/src/icons/ChromaIcon/index.tsx @@ -1,10 +1,8 @@ import React, { forwardRef } from "react"; import { ReactComponent as ChromaSVG } from "./chroma.svg"; -const ChromaIcon = forwardRef>( +export const ChromaIcon = forwardRef>( (props, ref) => { return ; } ); - -export default ChromaIcon; diff --git a/src/frontend/src/icons/Cohere/cohere.svg b/src/frontend/src/icons/Cohere/cohere.svg new file mode 100644 index 000000000..54ead3cf1 --- /dev/null +++ b/src/frontend/src/icons/Cohere/cohere.svg @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/frontend/src/icons/Cohere/index.tsx b/src/frontend/src/icons/Cohere/index.tsx new file mode 100644 index 000000000..0a071b510 --- /dev/null +++ b/src/frontend/src/icons/Cohere/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as CohereSVG } from "./cohere.svg"; + +export const CohereIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Evernote/evernote-icon.svg b/src/frontend/src/icons/Evernote/evernote-icon.svg new file mode 100644 index 000000000..2a3495980 --- /dev/null +++ b/src/frontend/src/icons/Evernote/evernote-icon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/src/icons/Evernote/index.tsx b/src/frontend/src/icons/Evernote/index.tsx new file mode 100644 index 000000000..23e9bc43f --- /dev/null +++ b/src/frontend/src/icons/Evernote/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as EvernoteSVG } from "./evernote-icon.svg"; + +export const EvernoteIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/FacebookMessenger/Facebook_Messenger_logo_2020.svg b/src/frontend/src/icons/FacebookMessenger/Facebook_Messenger_logo_2020.svg new file mode 100644 index 000000000..bd980c3af --- /dev/null +++ b/src/frontend/src/icons/FacebookMessenger/Facebook_Messenger_logo_2020.svg @@ -0,0 +1,2 @@ + + diff --git a/src/frontend/src/icons/FacebookMessenger/index.tsx b/src/frontend/src/icons/FacebookMessenger/index.tsx new file mode 100644 index 000000000..4450570aa --- /dev/null +++ b/src/frontend/src/icons/FacebookMessenger/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as FacebookMessengerSVG } from "./Facebook_Messenger_logo_2020.svg"; + +export const FBIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/GitBook/gitbook-svgrepo-com.svg b/src/frontend/src/icons/GitBook/gitbook-svgrepo-com.svg new file mode 100644 index 000000000..75eaa6da1 --- /dev/null +++ b/src/frontend/src/icons/GitBook/gitbook-svgrepo-com.svg @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/src/frontend/src/icons/GitBook/index.tsx b/src/frontend/src/icons/GitBook/index.tsx new file mode 100644 index 000000000..e25f52d58 --- /dev/null +++ b/src/frontend/src/icons/GitBook/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as GitBookSVG } from "./gitbook-svgrepo-com.svg"; + +export const GitBookIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Google/google.svg b/src/frontend/src/icons/Google/google.svg new file mode 100644 index 000000000..b518c5270 --- /dev/null +++ b/src/frontend/src/icons/Google/google.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/src/icons/Google/index.tsx b/src/frontend/src/icons/Google/index.tsx new file mode 100644 index 000000000..527469ca0 --- /dev/null +++ b/src/frontend/src/icons/Google/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as GoogleSVG } from "./google.svg"; + +export const GoogleIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/HuggingFace/hf-logo.svg b/src/frontend/src/icons/HuggingFace/hf-logo.svg new file mode 100644 index 000000000..ab959d165 --- /dev/null +++ b/src/frontend/src/icons/HuggingFace/hf-logo.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/frontend/src/icons/HuggingFace/index.tsx b/src/frontend/src/icons/HuggingFace/index.tsx new file mode 100644 index 000000000..eab851696 --- /dev/null +++ b/src/frontend/src/icons/HuggingFace/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as HugginFaceSVG } from "./hf-logo.svg"; + +export const HugginFaceIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/IFixIt/ifixit-seeklogo.com.svg b/src/frontend/src/icons/IFixIt/ifixit-seeklogo.com.svg new file mode 100644 index 000000000..cbb67cf79 --- /dev/null +++ b/src/frontend/src/icons/IFixIt/ifixit-seeklogo.com.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/src/icons/IFixIt/index.tsx b/src/frontend/src/icons/IFixIt/index.tsx new file mode 100644 index 000000000..9124266e4 --- /dev/null +++ b/src/frontend/src/icons/IFixIt/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as IFixItSVG } from "./ifixit-seeklogo.com.svg"; + +export const IFixIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Meta/index.tsx b/src/frontend/src/icons/Meta/index.tsx new file mode 100644 index 000000000..0aabeea74 --- /dev/null +++ b/src/frontend/src/icons/Meta/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as MetaSVG } from "./meta-icon.svg"; + +export const MetaIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Meta/meta-icon.svg b/src/frontend/src/icons/Meta/meta-icon.svg new file mode 100644 index 000000000..f5e8b583c --- /dev/null +++ b/src/frontend/src/icons/Meta/meta-icon.svg @@ -0,0 +1 @@ +facebook-meta \ No newline at end of file diff --git a/src/frontend/src/icons/Midjorney/Midjourney_Emblem.svg b/src/frontend/src/icons/Midjorney/Midjourney_Emblem.svg new file mode 100644 index 000000000..9c90d37e2 --- /dev/null +++ b/src/frontend/src/icons/Midjorney/Midjourney_Emblem.svg @@ -0,0 +1,53 @@ + + + + + + + + diff --git a/src/frontend/src/icons/Midjorney/index.tsx b/src/frontend/src/icons/Midjorney/index.tsx new file mode 100644 index 000000000..450666cfe --- /dev/null +++ b/src/frontend/src/icons/Midjorney/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as MidjorneySVG } from "./Midjourney_Emblem.svg"; + +export const MidjorneyIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Notion/Notion-logo.svg b/src/frontend/src/icons/Notion/Notion-logo.svg new file mode 100644 index 000000000..bf6442f76 --- /dev/null +++ b/src/frontend/src/icons/Notion/Notion-logo.svg @@ -0,0 +1,4 @@ + + + + diff --git a/src/frontend/src/icons/Notion/index.tsx b/src/frontend/src/icons/Notion/index.tsx new file mode 100644 index 000000000..9666ce80b --- /dev/null +++ b/src/frontend/src/icons/Notion/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as NotionSVG } from "./Notion-logo.svg"; + +export const NotionIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/OpenAi/index.tsx b/src/frontend/src/icons/OpenAi/index.tsx new file mode 100644 index 000000000..ae50fbce3 --- /dev/null +++ b/src/frontend/src/icons/OpenAi/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as OpenAiSVG } from "./openAI.svg"; + +export const OpenAiIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/OpenAi/openAI.svg b/src/frontend/src/icons/OpenAi/openAI.svg new file mode 100644 index 000000000..e81233fe6 --- /dev/null +++ b/src/frontend/src/icons/OpenAi/openAI.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/src/icons/PowerPoint/PowerPoint.svg b/src/frontend/src/icons/PowerPoint/PowerPoint.svg new file mode 100644 index 000000000..1b9ee4383 --- /dev/null +++ b/src/frontend/src/icons/PowerPoint/PowerPoint.svg @@ -0,0 +1,52 @@ + + + + + + + + + + +]> + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/frontend/src/icons/PowerPoint/index.tsx b/src/frontend/src/icons/PowerPoint/index.tsx new file mode 100644 index 000000000..fbb68d533 --- /dev/null +++ b/src/frontend/src/icons/PowerPoint/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as PowerPointSVG } from "./PowerPoint.svg"; + +export const PowerPointIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/QDrant/QDrant.svg b/src/frontend/src/icons/QDrant/QDrant.svg new file mode 100644 index 000000000..a53c6596c --- /dev/null +++ b/src/frontend/src/icons/QDrant/QDrant.svg @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/frontend/src/icons/QDrant/index.tsx b/src/frontend/src/icons/QDrant/index.tsx new file mode 100644 index 000000000..7e8ec655d --- /dev/null +++ b/src/frontend/src/icons/QDrant/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as QDrantSVG } from "./QDrant.svg"; + +export const QDrantIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/ReadTheDocs/index.tsx b/src/frontend/src/icons/ReadTheDocs/index.tsx new file mode 100644 index 000000000..c87a624de --- /dev/null +++ b/src/frontend/src/icons/ReadTheDocs/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as ReadTheDocsSVG } from "./readthedocsio-icon.svg"; + +export const ReadTheDocsIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/ReadTheDocs/readthedocsio-icon.svg b/src/frontend/src/icons/ReadTheDocs/readthedocsio-icon.svg new file mode 100644 index 000000000..22f38b47a --- /dev/null +++ b/src/frontend/src/icons/ReadTheDocs/readthedocsio-icon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/src/icons/Searx/Searx_logo.svg b/src/frontend/src/icons/Searx/Searx_logo.svg new file mode 100644 index 000000000..45eecb16c --- /dev/null +++ b/src/frontend/src/icons/Searx/Searx_logo.svg @@ -0,0 +1,198 @@ + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + diff --git a/src/frontend/src/icons/Searx/index.tsx b/src/frontend/src/icons/Searx/index.tsx new file mode 100644 index 000000000..c1196c68a --- /dev/null +++ b/src/frontend/src/icons/Searx/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as SearxSVG } from "./Searx_logo.svg"; + +export const SearxIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Slack/index.tsx b/src/frontend/src/icons/Slack/index.tsx new file mode 100644 index 000000000..ec5bdc108 --- /dev/null +++ b/src/frontend/src/icons/Slack/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as SlackSVG } from "./slack-icon.svg"; + +export const SlackIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Slack/slack-icon.svg b/src/frontend/src/icons/Slack/slack-icon.svg new file mode 100644 index 000000000..c5f26c10e --- /dev/null +++ b/src/frontend/src/icons/Slack/slack-icon.svg @@ -0,0 +1,6 @@ + \ No newline at end of file diff --git a/src/frontend/src/icons/Weaviate/index.tsx b/src/frontend/src/icons/Weaviate/index.tsx new file mode 100644 index 000000000..f454e4f15 --- /dev/null +++ b/src/frontend/src/icons/Weaviate/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as WeaviateSVG } from "./weaviate.svg"; + +export const WeaviateIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Weaviate/weaviate.svg b/src/frontend/src/icons/Weaviate/weaviate.svg new file mode 100644 index 000000000..d5b3bda24 --- /dev/null +++ b/src/frontend/src/icons/Weaviate/weaviate.svg @@ -0,0 +1,142 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/frontend/src/icons/Wikipedia/Wikipedia.svg b/src/frontend/src/icons/Wikipedia/Wikipedia.svg new file mode 100644 index 000000000..aa0cec73f --- /dev/null +++ b/src/frontend/src/icons/Wikipedia/Wikipedia.svg @@ -0,0 +1,424 @@ + + + + + + + image/svg+xml + + + Wikipedia's W + + + STyx + + + none + + + Wikipedia + favicon + + + 2007-06-26 + + + GFDL + + + W de Wikipédia + + + Inkscape + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/frontend/src/icons/Wikipedia/index.tsx b/src/frontend/src/icons/Wikipedia/index.tsx new file mode 100644 index 000000000..06c1c5b4d --- /dev/null +++ b/src/frontend/src/icons/Wikipedia/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as WikipediaSVG } from "./Wikipedia.svg"; + +export const WikipediaIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Wolfram/index.tsx b/src/frontend/src/icons/Wolfram/index.tsx new file mode 100644 index 000000000..c8b94ebf1 --- /dev/null +++ b/src/frontend/src/icons/Wolfram/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as WolframSVG } from "./wolfram.svg"; + +export const WolframIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Wolfram/wolfram.svg b/src/frontend/src/icons/Wolfram/wolfram.svg new file mode 100644 index 000000000..105a2c12b --- /dev/null +++ b/src/frontend/src/icons/Wolfram/wolfram.svg @@ -0,0 +1,250 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/frontend/src/icons/Word/index.tsx b/src/frontend/src/icons/Word/index.tsx new file mode 100644 index 000000000..8c6cf9f31 --- /dev/null +++ b/src/frontend/src/icons/Word/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as WordSVG } from "./word.svg"; + +export const WordIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/Word/word.svg b/src/frontend/src/icons/Word/word.svg new file mode 100644 index 000000000..2060f5289 --- /dev/null +++ b/src/frontend/src/icons/Word/word.svg @@ -0,0 +1,50 @@ + + + + + + + + + + +]> + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/frontend/src/icons/hackerNews/Y_Combinator_logo.svg b/src/frontend/src/icons/hackerNews/Y_Combinator_logo.svg new file mode 100644 index 000000000..b502950a2 --- /dev/null +++ b/src/frontend/src/icons/hackerNews/Y_Combinator_logo.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/src/frontend/src/icons/hackerNews/index.tsx b/src/frontend/src/icons/hackerNews/index.tsx new file mode 100644 index 000000000..d1c47e7db --- /dev/null +++ b/src/frontend/src/icons/hackerNews/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as HackerNewsSVG } from "./Y_Combinator_logo.svg"; + +export const HackerNewsIcon = forwardRef>( + (props, ref) => { + return ; + } +); diff --git a/src/frontend/src/icons/index.tsx b/src/frontend/src/icons/index.tsx deleted file mode 100644 index 2b01bf567..000000000 --- a/src/frontend/src/icons/index.tsx +++ /dev/null @@ -1 +0,0 @@ -export { default as ChromaIcon } from "./ChromaIcon"; diff --git a/src/frontend/src/utils.ts b/src/frontend/src/utils.ts index ef944aa47..585e93664 100644 --- a/src/frontend/src/utils.ts +++ b/src/frontend/src/utils.ts @@ -20,7 +20,31 @@ import { Connection, Edge, Node, ReactFlowInstance, addEdge } from "reactflow"; import { FlowType, NodeType } from "./types/flow"; import { APITemplateType, TemplateVariableType } from "./types/api"; import _ from "lodash"; -import { ChromaIcon } from "./icons"; +import { ChromaIcon} from "./icons/ChromaIcon"; +import { AirbyteIcon } from "./icons/Airbyte"; +import { AzIcon } from "./icons/AzLogo"; +import { BingIcon } from "./icons/Bing"; +import { CohereIcon } from "./icons/Cohere"; +import { EvernoteIcon } from "./icons/Evernote"; +import { FBIcon } from "./icons/FacebookMessenger"; +import { GitBookIcon } from "./icons/GitBook"; +import { GoogleIcon } from "./icons/Google"; +import { HackerNewsIcon } from "./icons/hackerNews"; +import { HugginFaceIcon } from "./icons/HuggingFace"; +import { IFixIcon } from "./icons/IFixIt"; +import { MetaIcon } from "./icons/Meta"; +import { MidjorneyIcon } from "./icons/Midjorney"; +import { NotionIcon } from "./icons/Notion"; +import { OpenAiIcon } from "./icons/OpenAi"; +import { PowerPointIcon } from "./icons/PowerPoint"; +import { QDrantIcon } from "./icons/QDrant"; +import { ReadTheDocsIcon } from "./icons/ReadTheDocs"; +import { SearxIcon } from "./icons/Searx"; +import { SlackIcon } from "./icons/Slack"; +import { WeaviateIcon } from "./icons/Weaviate"; +import { WikipediaIcon } from "./icons/Wikipedia"; +import { WolframIcon } from "./icons/Wolfram"; +import { WordIcon } from "./icons/Word"; import { v4 as uuidv4 } from "uuid"; export function classNames(...classes: Array) { @@ -125,6 +149,30 @@ export const nodeIcons: { >; } = { Chroma: ChromaIcon, + Airbyte: AirbyteIcon, + AzLogo: AzIcon, + Bing: BingIcon, + Cohere: CohereIcon, + Evernote: EvernoteIcon, + FacebookMessenger: FBIcon, + GitBook: GitBookIcon, + Google: GoogleIcon, + HackerNews: HackerNewsIcon, + HuggingFace: HugginFaceIcon, + IFixIt: IFixIcon, + Meta: MetaIcon, + Midjorney: MidjorneyIcon, + Notion: NotionIcon, + OpenAi: OpenAiIcon, + PowerPoint: PowerPointIcon, + QDrant: QDrantIcon, + ReadTheDocs: ReadTheDocsIcon, + Searx: SearxIcon, + Slack: SlackIcon, + Weaviate: WeaviateIcon, + Wikipedia: WikipediaIcon, + Wolfram: WolframIcon, + Word: WordIcon, agents: RocketLaunchIcon, chains: LinkIcon, memories: CpuChipIcon, From 8b5a4438805fa682357f9fec56b7c3cbfcf82628 Mon Sep 17 00:00:00 2001 From: anovazzi1 Date: Mon, 29 May 2023 22:54:30 -0300 Subject: [PATCH 2/7] added custom icons for companies, first version --- src/frontend/src/icons/Airbyte/index.tsx | 11 ++++++----- src/frontend/src/icons/ChromaIcon/index.tsx | 11 ++++++----- src/frontend/src/icons/Cohere/index.tsx | 11 ++++++----- src/frontend/src/icons/Evernote/index.tsx | 11 ++++++----- src/frontend/src/icons/GitBook/index.tsx | 11 ++++++----- src/frontend/src/icons/Google/index.tsx | 11 ++++++----- src/frontend/src/icons/HuggingFace/index.tsx | 11 ++++++----- src/frontend/src/icons/Midjorney/index.tsx | 11 ++++++----- src/frontend/src/icons/Notion/index.tsx | 11 ++++++----- src/frontend/src/icons/OpenAi/index.tsx | 11 ++++++----- src/frontend/src/icons/PowerPoint/index.tsx | 11 ++++++----- src/frontend/src/icons/QDrant/index.tsx | 11 ++++++----- src/frontend/src/icons/ReadTheDocs/index.tsx | 11 ++++++----- src/frontend/src/icons/Weaviate/index.tsx | 11 ++++++----- src/frontend/src/icons/Wikipedia/index.tsx | 11 ++++++----- src/frontend/src/icons/Wolfram/index.tsx | 11 ++++++----- src/frontend/src/icons/hackerNews/index.tsx | 11 ++++++----- src/frontend/src/utils.ts | 2 +- 18 files changed, 103 insertions(+), 86 deletions(-) diff --git a/src/frontend/src/icons/Airbyte/index.tsx b/src/frontend/src/icons/Airbyte/index.tsx index c116b5ad2..6fb8daf24 100644 --- a/src/frontend/src/icons/Airbyte/index.tsx +++ b/src/frontend/src/icons/Airbyte/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as AirbyteSVG } from "./airbyte.svg"; -export const AirbyteIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const AirbyteIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/ChromaIcon/index.tsx b/src/frontend/src/icons/ChromaIcon/index.tsx index 913d651f4..afcb868a8 100644 --- a/src/frontend/src/icons/ChromaIcon/index.tsx +++ b/src/frontend/src/icons/ChromaIcon/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as ChromaSVG } from "./chroma.svg"; -export const ChromaIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const ChromaIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/Cohere/index.tsx b/src/frontend/src/icons/Cohere/index.tsx index 0a071b510..bcb15dd24 100644 --- a/src/frontend/src/icons/Cohere/index.tsx +++ b/src/frontend/src/icons/Cohere/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as CohereSVG } from "./cohere.svg"; -export const CohereIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const CohereIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/Evernote/index.tsx b/src/frontend/src/icons/Evernote/index.tsx index 23e9bc43f..685d9da13 100644 --- a/src/frontend/src/icons/Evernote/index.tsx +++ b/src/frontend/src/icons/Evernote/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as EvernoteSVG } from "./evernote-icon.svg"; -export const EvernoteIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const EvernoteIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/GitBook/index.tsx b/src/frontend/src/icons/GitBook/index.tsx index e25f52d58..0e312a8e1 100644 --- a/src/frontend/src/icons/GitBook/index.tsx +++ b/src/frontend/src/icons/GitBook/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as GitBookSVG } from "./gitbook-svgrepo-com.svg"; -export const GitBookIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const GitBookIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/Google/index.tsx b/src/frontend/src/icons/Google/index.tsx index 527469ca0..5159ba23b 100644 --- a/src/frontend/src/icons/Google/index.tsx +++ b/src/frontend/src/icons/Google/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as GoogleSVG } from "./google.svg"; -export const GoogleIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const GoogleIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/HuggingFace/index.tsx b/src/frontend/src/icons/HuggingFace/index.tsx index eab851696..44fc68609 100644 --- a/src/frontend/src/icons/HuggingFace/index.tsx +++ b/src/frontend/src/icons/HuggingFace/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as HugginFaceSVG } from "./hf-logo.svg"; -export const HugginFaceIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const HugginFaceIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/Midjorney/index.tsx b/src/frontend/src/icons/Midjorney/index.tsx index 450666cfe..fd09aa700 100644 --- a/src/frontend/src/icons/Midjorney/index.tsx +++ b/src/frontend/src/icons/Midjorney/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as MidjorneySVG } from "./Midjourney_Emblem.svg"; -export const MidjorneyIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const MidjorneyIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/Notion/index.tsx b/src/frontend/src/icons/Notion/index.tsx index 9666ce80b..265a5c153 100644 --- a/src/frontend/src/icons/Notion/index.tsx +++ b/src/frontend/src/icons/Notion/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as NotionSVG } from "./Notion-logo.svg"; -export const NotionIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const NotionIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/OpenAi/index.tsx b/src/frontend/src/icons/OpenAi/index.tsx index ae50fbce3..940f4f908 100644 --- a/src/frontend/src/icons/OpenAi/index.tsx +++ b/src/frontend/src/icons/OpenAi/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as OpenAiSVG } from "./openAI.svg"; -export const OpenAiIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const OpenAiIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/PowerPoint/index.tsx b/src/frontend/src/icons/PowerPoint/index.tsx index fbb68d533..89d6fb53b 100644 --- a/src/frontend/src/icons/PowerPoint/index.tsx +++ b/src/frontend/src/icons/PowerPoint/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as PowerPointSVG } from "./PowerPoint.svg"; -export const PowerPointIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const PowerPointIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/QDrant/index.tsx b/src/frontend/src/icons/QDrant/index.tsx index 7e8ec655d..5bc03e070 100644 --- a/src/frontend/src/icons/QDrant/index.tsx +++ b/src/frontend/src/icons/QDrant/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as QDrantSVG } from "./QDrant.svg"; -export const QDrantIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const QDrantIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/ReadTheDocs/index.tsx b/src/frontend/src/icons/ReadTheDocs/index.tsx index c87a624de..87a327912 100644 --- a/src/frontend/src/icons/ReadTheDocs/index.tsx +++ b/src/frontend/src/icons/ReadTheDocs/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as ReadTheDocsSVG } from "./readthedocsio-icon.svg"; -export const ReadTheDocsIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const ReadTheDocsIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/Weaviate/index.tsx b/src/frontend/src/icons/Weaviate/index.tsx index f454e4f15..f1aeeb1af 100644 --- a/src/frontend/src/icons/Weaviate/index.tsx +++ b/src/frontend/src/icons/Weaviate/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as WeaviateSVG } from "./weaviate.svg"; -export const WeaviateIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const WeaviateIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/Wikipedia/index.tsx b/src/frontend/src/icons/Wikipedia/index.tsx index 06c1c5b4d..446f9c108 100644 --- a/src/frontend/src/icons/Wikipedia/index.tsx +++ b/src/frontend/src/icons/Wikipedia/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as WikipediaSVG } from "./Wikipedia.svg"; -export const WikipediaIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const WikipediaIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/Wolfram/index.tsx b/src/frontend/src/icons/Wolfram/index.tsx index c8b94ebf1..8f1b3e089 100644 --- a/src/frontend/src/icons/Wolfram/index.tsx +++ b/src/frontend/src/icons/Wolfram/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as WolframSVG } from "./wolfram.svg"; -export const WolframIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const WolframIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/icons/hackerNews/index.tsx b/src/frontend/src/icons/hackerNews/index.tsx index d1c47e7db..787a94274 100644 --- a/src/frontend/src/icons/hackerNews/index.tsx +++ b/src/frontend/src/icons/hackerNews/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as HackerNewsSVG } from "./Y_Combinator_logo.svg"; -export const HackerNewsIcon = forwardRef>( - (props, ref) => { - return ; - } -); +export const HackerNewsIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/utils.ts b/src/frontend/src/utils.ts index 585e93664..be7314ade 100644 --- a/src/frontend/src/utils.ts +++ b/src/frontend/src/utils.ts @@ -20,7 +20,7 @@ import { Connection, Edge, Node, ReactFlowInstance, addEdge } from "reactflow"; import { FlowType, NodeType } from "./types/flow"; import { APITemplateType, TemplateVariableType } from "./types/api"; import _ from "lodash"; -import { ChromaIcon} from "./icons/ChromaIcon"; +import { ChromaIcon } from "./icons/ChromaIcon"; import { AirbyteIcon } from "./icons/Airbyte"; import { AzIcon } from "./icons/AzLogo"; import { BingIcon } from "./icons/Bing"; From 44faf64e09fe560db21a3ba219f3e991026ebd32 Mon Sep 17 00:00:00 2001 From: Gabriel Almeida Date: Mon, 29 May 2023 23:45:13 -0300 Subject: [PATCH 3/7] =?UTF-8?q?=F0=9F=94=A8=20refactor(utils.ts):=20rename?= =?UTF-8?q?=20nodeIcons=20keys=20to=20improve=20semantics=20The=20keys=20o?= =?UTF-8?q?f=20the=20nodeIcons=20object=20have=20been=20renamed=20to=20imp?= =?UTF-8?q?rove=20semantics=20and=20readability.=20The=20new=20names=20are?= =?UTF-8?q?=20more=20descriptive=20of=20the=20functionality=20of=20the=20c?= =?UTF-8?q?orresponding=20icons.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/frontend/src/utils.ts | 38 +++++++++++++++++++++----------------- 1 file changed, 21 insertions(+), 17 deletions(-) diff --git a/src/frontend/src/utils.ts b/src/frontend/src/utils.ts index be7314ade..2c895938c 100644 --- a/src/frontend/src/utils.ts +++ b/src/frontend/src/utils.ts @@ -149,29 +149,33 @@ export const nodeIcons: { >; } = { Chroma: ChromaIcon, - Airbyte: AirbyteIcon, - AzLogo: AzIcon, - Bing: BingIcon, + AirbyteJSONLoader: AirbyteIcon, + // AZLyricsLoader: AzIcon, + BingSearchAPIWrapper: BingIcon, Cohere: CohereIcon, - Evernote: EvernoteIcon, - FacebookMessenger: FBIcon, - GitBook: GitBookIcon, - Google: GoogleIcon, - HackerNews: HackerNewsIcon, - HuggingFace: HugginFaceIcon, - IFixIt: IFixIcon, + CohereEmbeddings: CohereIcon, + EverNoteLoader: EvernoteIcon, + FacebookChatLoader: FBIcon, + GitbookLoader: GitBookIcon, + GoogleSearchAPIWrapper: GoogleIcon, + HNLoader: HackerNewsIcon, + HuggingFaceHub: HugginFaceIcon, + HuggingFaceEmbeddings: HugginFaceIcon, + IFixitLoader: IFixIcon, Meta: MetaIcon, Midjorney: MidjorneyIcon, - Notion: NotionIcon, - OpenAi: OpenAiIcon, + NotionDirectoryLoader: NotionIcon, + ChatOpenAI: OpenAiIcon, + OpenAI: OpenAiIcon, + OpenAIEmbeddings: OpenAiIcon, PowerPoint: PowerPointIcon, - QDrant: QDrantIcon, + Qdrant: QDrantIcon, ReadTheDocs: ReadTheDocsIcon, Searx: SearxIcon, - Slack: SlackIcon, - Weaviate: WeaviateIcon, - Wikipedia: WikipediaIcon, - Wolfram: WolframIcon, + SlackDirectoryLoader: SlackIcon, + // Weaviate: WeaviateIcon, + // WikipediaAPIWrapper: WikipediaIcon, + WolframAlphaQueryRun: WolframIcon, Word: WordIcon, agents: RocketLaunchIcon, chains: LinkIcon, From ca151c6661071ac1e60d73dfdb5befea2b5f9513 Mon Sep 17 00:00:00 2001 From: anovazzi1 Date: Tue, 30 May 2023 00:16:19 -0300 Subject: [PATCH 4/7] fix refresh error --- src/frontend/src/contexts/tabsContext.tsx | 33 ++++++++++---------- src/frontend/src/icons/Serper/index.tsx | 8 +++++ src/frontend/src/icons/Serper/serper.svg | 38 +++++++++++++++++++++++ src/frontend/src/utils.ts | 7 ++++- 4 files changed, 69 insertions(+), 17 deletions(-) create mode 100644 src/frontend/src/icons/Serper/index.tsx create mode 100644 src/frontend/src/icons/Serper/serper.svg diff --git a/src/frontend/src/contexts/tabsContext.tsx b/src/frontend/src/contexts/tabsContext.tsx index 480a154f8..ff882e1b6 100644 --- a/src/frontend/src/contexts/tabsContext.tsx +++ b/src/frontend/src/contexts/tabsContext.tsx @@ -21,24 +21,24 @@ import { v4 as uuidv4 } from "uuid"; import { addEdge } from "reactflow"; const TabsContextInitialValue: TabsContextType = { - save: () => {}, + save: () => { }, tabIndex: 0, - setTabIndex: (index: number) => {}, + setTabIndex: (index: number) => { }, flows: [], - removeFlow: (id: string) => {}, - addFlow: (flowData?: any) => {}, - updateFlow: (newFlow: FlowType) => {}, + removeFlow: (id: string) => { }, + addFlow: (flowData?: any) => { }, + updateFlow: (newFlow: FlowType) => { }, incrementNodeId: () => uuidv4(), - downloadFlow: (flow: FlowType) => {}, - uploadFlow: () => {}, - hardReset: () => {}, + downloadFlow: (flow: FlowType) => { }, + uploadFlow: () => { }, + hardReset: () => { }, disableCopyPaste: false, - setDisableCopyPaste: (state: boolean) => {}, + setDisableCopyPaste: (state: boolean) => { }, getNodeId: () => "", paste: ( selection: { nodes: any; edges: any }, position: { x: number; y: number } - ) => {}, + ) => { }, }; export const TabsContext = createContext( @@ -59,7 +59,7 @@ export function TabsProvider({ children }: { children: ReactNode }) { } function save() { let Saveflows = [...flows]; - if (Saveflows.length !== 0) + if (Saveflows.length !== 0) { Saveflows.forEach((flow) => { if (flow.data && flow.data?.nodes) flow.data?.nodes.forEach((node) => { @@ -71,10 +71,11 @@ export function TabsProvider({ children }: { children: ReactNode }) { }); }); }); - window.localStorage.setItem( - "tabsData", - JSON.stringify({ tabIndex, flows: Saveflows, id }) - ); + window.localStorage.setItem( + "tabsData", + JSON.stringify({ tabIndex, flows: Saveflows, id }) + ); + } } useEffect(() => { //save tabs locally @@ -108,7 +109,7 @@ export function TabsProvider({ children }: { children: ReactNode }) { templates[node.data.type]["description"]; node.data.node.template = updateTemplate( templates[node.data.type][ - "template" + "template" ] as unknown as APITemplateType, node.data.node.template as APITemplateType diff --git a/src/frontend/src/icons/Serper/index.tsx b/src/frontend/src/icons/Serper/index.tsx new file mode 100644 index 000000000..2100695ff --- /dev/null +++ b/src/frontend/src/icons/Serper/index.tsx @@ -0,0 +1,8 @@ +import React, { forwardRef } from "react"; +import { ReactComponent as SerperSVG } from "./serper.svg"; + +export const SerperIcon = forwardRef>( + (props, ref) => { + return ; + } +); \ No newline at end of file diff --git a/src/frontend/src/icons/Serper/serper.svg b/src/frontend/src/icons/Serper/serper.svg new file mode 100644 index 000000000..a984dbfe8 --- /dev/null +++ b/src/frontend/src/icons/Serper/serper.svg @@ -0,0 +1,38 @@ + + + + diff --git a/src/frontend/src/utils.ts b/src/frontend/src/utils.ts index 2c895938c..5f8e85242 100644 --- a/src/frontend/src/utils.ts +++ b/src/frontend/src/utils.ts @@ -45,6 +45,7 @@ import { WeaviateIcon } from "./icons/Weaviate"; import { WikipediaIcon } from "./icons/Wikipedia"; import { WolframIcon } from "./icons/Wolfram"; import { WordIcon } from "./icons/Word"; +import { SerperIcon } from "./icons/Serper"; import { v4 as uuidv4 } from "uuid"; export function classNames(...classes: Array) { @@ -150,6 +151,7 @@ export const nodeIcons: { } = { Chroma: ChromaIcon, AirbyteJSONLoader: AirbyteIcon, + // SerpAPIWrapper: SerperIcon, // AZLyricsLoader: AzIcon, BingSearchAPIWrapper: BingIcon, Cohere: CohereIcon, @@ -158,6 +160,8 @@ export const nodeIcons: { FacebookChatLoader: FBIcon, GitbookLoader: GitBookIcon, GoogleSearchAPIWrapper: GoogleIcon, + GoogleSearchResults: GoogleIcon, + GoogleSearchRun: GoogleIcon, HNLoader: HackerNewsIcon, HuggingFaceHub: HugginFaceIcon, HuggingFaceEmbeddings: HugginFaceIcon, @@ -175,7 +179,8 @@ export const nodeIcons: { SlackDirectoryLoader: SlackIcon, // Weaviate: WeaviateIcon, // WikipediaAPIWrapper: WikipediaIcon, - WolframAlphaQueryRun: WolframIcon, + // WolframAlphaQueryRun: WolframIcon, + // WolframAlphaAPIWrapper: WolframIcon, Word: WordIcon, agents: RocketLaunchIcon, chains: LinkIcon, From 8a2cf0f72141c00406f07be0740c327be6740253 Mon Sep 17 00:00:00 2001 From: anovazzi1 Date: Tue, 30 May 2023 00:16:30 -0300 Subject: [PATCH 5/7] format --- src/frontend/src/contexts/tabsContext.tsx | 22 +++++++++++----------- src/frontend/src/icons/Serper/index.tsx | 11 ++++++----- src/frontend/src/utils.ts | 2 +- 3 files changed, 18 insertions(+), 17 deletions(-) diff --git a/src/frontend/src/contexts/tabsContext.tsx b/src/frontend/src/contexts/tabsContext.tsx index ff882e1b6..1a95d3157 100644 --- a/src/frontend/src/contexts/tabsContext.tsx +++ b/src/frontend/src/contexts/tabsContext.tsx @@ -21,24 +21,24 @@ import { v4 as uuidv4 } from "uuid"; import { addEdge } from "reactflow"; const TabsContextInitialValue: TabsContextType = { - save: () => { }, + save: () => {}, tabIndex: 0, - setTabIndex: (index: number) => { }, + setTabIndex: (index: number) => {}, flows: [], - removeFlow: (id: string) => { }, - addFlow: (flowData?: any) => { }, - updateFlow: (newFlow: FlowType) => { }, + removeFlow: (id: string) => {}, + addFlow: (flowData?: any) => {}, + updateFlow: (newFlow: FlowType) => {}, incrementNodeId: () => uuidv4(), - downloadFlow: (flow: FlowType) => { }, - uploadFlow: () => { }, - hardReset: () => { }, + downloadFlow: (flow: FlowType) => {}, + uploadFlow: () => {}, + hardReset: () => {}, disableCopyPaste: false, - setDisableCopyPaste: (state: boolean) => { }, + setDisableCopyPaste: (state: boolean) => {}, getNodeId: () => "", paste: ( selection: { nodes: any; edges: any }, position: { x: number; y: number } - ) => { }, + ) => {}, }; export const TabsContext = createContext( @@ -109,7 +109,7 @@ export function TabsProvider({ children }: { children: ReactNode }) { templates[node.data.type]["description"]; node.data.node.template = updateTemplate( templates[node.data.type][ - "template" + "template" ] as unknown as APITemplateType, node.data.node.template as APITemplateType diff --git a/src/frontend/src/icons/Serper/index.tsx b/src/frontend/src/icons/Serper/index.tsx index 2100695ff..77ea58077 100644 --- a/src/frontend/src/icons/Serper/index.tsx +++ b/src/frontend/src/icons/Serper/index.tsx @@ -1,8 +1,9 @@ import React, { forwardRef } from "react"; import { ReactComponent as SerperSVG } from "./serper.svg"; -export const SerperIcon = forwardRef>( - (props, ref) => { - return ; - } -); \ No newline at end of file +export const SerperIcon = forwardRef< + SVGSVGElement, + React.PropsWithChildren<{}> +>((props, ref) => { + return ; +}); diff --git a/src/frontend/src/utils.ts b/src/frontend/src/utils.ts index 5f8e85242..cebf4fb02 100644 --- a/src/frontend/src/utils.ts +++ b/src/frontend/src/utils.ts @@ -180,7 +180,7 @@ export const nodeIcons: { // Weaviate: WeaviateIcon, // WikipediaAPIWrapper: WikipediaIcon, // WolframAlphaQueryRun: WolframIcon, - // WolframAlphaAPIWrapper: WolframIcon, + // WolframAlphaAPIWrapper: WolframIcon, Word: WordIcon, agents: RocketLaunchIcon, chains: LinkIcon, From 82a8b633a6b3395096276ace308d96dcd945f17a Mon Sep 17 00:00:00 2001 From: anovazzi1 Date: Tue, 30 May 2023 00:40:50 -0300 Subject: [PATCH 6/7] new save function to prevent break with large files --- src/frontend/src/contexts/tabsContext.tsx | 38 +++++++++++++---------- 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/src/frontend/src/contexts/tabsContext.tsx b/src/frontend/src/contexts/tabsContext.tsx index 1a95d3157..2c3103477 100644 --- a/src/frontend/src/contexts/tabsContext.tsx +++ b/src/frontend/src/contexts/tabsContext.tsx @@ -19,6 +19,7 @@ import { typesContext } from "./typesContext"; import { APITemplateType, TemplateVariableType } from "../types/api"; import { v4 as uuidv4 } from "uuid"; import { addEdge } from "reactflow"; +import _ from "lodash"; const TabsContextInitialValue: TabsContextType = { save: () => {}, @@ -58,25 +59,30 @@ export function TabsProvider({ children }: { children: ReactNode }) { return newNodeId.current; } function save() { - let Saveflows = [...flows]; - if (Saveflows.length !== 0) { + // added clone deep to avoid mutating the original object + let Saveflows = _.cloneDeep(flows); + if (Saveflows.length !== 0){ Saveflows.forEach((flow) => { - if (flow.data && flow.data?.nodes) - flow.data?.nodes.forEach((node) => { - Object.keys(node.data.node.template).forEach((key) => { - if (node.data.node.template[key].type === "file") { - // ! Commenting this out for now, as it is causing issues with the file upload - // node.data.node.template[key].content = ""; - } - }); - }); - }); + if(flow.data && flow.data?.nodes) flow.data?.nodes.forEach((node) => { + console.log(node.data.type) + //looking for file fields to prevent saving the content and breaking the flow for exceeding the the data limite for local storage + Object.keys(node.data.node.template).forEach((key) => { + console.log(node.data.node.template[key].type) + if(node.data.node.template[key].type==="file"){ + console.log(node.data.node.template[key]) + node.data.node.template[key].content = null; + node.data.node.template[key].value = ""; + + } + }) + }) + }) window.localStorage.setItem( - "tabsData", - JSON.stringify({ tabIndex, flows: Saveflows, id }) - ); + "tabsData", + JSON.stringify({ tabIndex, flows:Saveflows, id}) + ); } - } + } useEffect(() => { //save tabs locally save(); From 1981321b1a6b73754f647772c1c51efc6f39d98b Mon Sep 17 00:00:00 2001 From: anovazzi1 Date: Tue, 30 May 2023 00:41:07 -0300 Subject: [PATCH 7/7] format --- src/frontend/src/contexts/tabsContext.tsx | 40 +++++++++++------------ 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/src/frontend/src/contexts/tabsContext.tsx b/src/frontend/src/contexts/tabsContext.tsx index 2c3103477..18927a480 100644 --- a/src/frontend/src/contexts/tabsContext.tsx +++ b/src/frontend/src/contexts/tabsContext.tsx @@ -60,29 +60,29 @@ export function TabsProvider({ children }: { children: ReactNode }) { } function save() { // added clone deep to avoid mutating the original object - let Saveflows = _.cloneDeep(flows); - if (Saveflows.length !== 0){ + let Saveflows = _.cloneDeep(flows); + if (Saveflows.length !== 0) { Saveflows.forEach((flow) => { - if(flow.data && flow.data?.nodes) flow.data?.nodes.forEach((node) => { - console.log(node.data.type) - //looking for file fields to prevent saving the content and breaking the flow for exceeding the the data limite for local storage - Object.keys(node.data.node.template).forEach((key) => { - console.log(node.data.node.template[key].type) - if(node.data.node.template[key].type==="file"){ - console.log(node.data.node.template[key]) - node.data.node.template[key].content = null; - node.data.node.template[key].value = ""; - - } - }) - }) - }) + if (flow.data && flow.data?.nodes) + flow.data?.nodes.forEach((node) => { + console.log(node.data.type); + //looking for file fields to prevent saving the content and breaking the flow for exceeding the the data limite for local storage + Object.keys(node.data.node.template).forEach((key) => { + console.log(node.data.node.template[key].type); + if (node.data.node.template[key].type === "file") { + console.log(node.data.node.template[key]); + node.data.node.template[key].content = null; + node.data.node.template[key].value = ""; + } + }); + }); + }); window.localStorage.setItem( - "tabsData", - JSON.stringify({ tabIndex, flows:Saveflows, id}) - ); + "tabsData", + JSON.stringify({ tabIndex, flows: Saveflows, id }) + ); } - } + } useEffect(() => { //save tabs locally save();