- {typeof option === 'string' ? option : option.name || option.label || option.description}
+ {typeof option === 'string'
+ ? option
+ : option.name || option.label || option.description}
{showEdit && onEdit && (
![]()
Date: Sat, 5 Oct 2024 18:16:09 -0700
Subject: [PATCH 4/6] Addressing comments
---
frontend/src/App.tsx | 6 +-
frontend/src/Navigation.tsx | 33 ++------
frontend/src/assets/documentation-dark.svg | 5 +-
frontend/src/assets/documentation.svg | 5 +-
frontend/src/assets/envelope-dark.svg | 3 +
frontend/src/assets/envelope.svg | 3 +
frontend/src/components/Dropdown.tsx | 94 +++++++++++----------
frontend/src/components/Help.tsx | 97 ++++++++++++++++++++++
frontend/src/components/SourceDropdown.tsx | 9 +-
frontend/src/locale/i18n.ts | 2 +-
10 files changed, 174 insertions(+), 83 deletions(-)
create mode 100644 frontend/src/assets/envelope-dark.svg
create mode 100644 frontend/src/assets/envelope.svg
create mode 100644 frontend/src/components/Help.tsx
diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx
index 1455f495..176ae518 100644
--- a/frontend/src/App.tsx
+++ b/frontend/src/App.tsx
@@ -32,9 +32,9 @@ function MainLayout() {
}
export default function App() {
- const [,,componentMounted] = useDarkTheme();
- if(!componentMounted) {
- return
+ const [, , componentMounted] = useDarkTheme();
+ if (!componentMounted) {
+ return
;
}
return (
diff --git a/frontend/src/Navigation.tsx b/frontend/src/Navigation.tsx
index 621ae96b..09245d9d 100644
--- a/frontend/src/Navigation.tsx
+++ b/frontend/src/Navigation.tsx
@@ -11,7 +11,6 @@ import Discord from './assets/discord.svg';
import Expand from './assets/expand.svg';
import Github from './assets/github.svg';
import Hamburger from './assets/hamburger.svg';
-import InfoDark from './assets/info-dark.svg';
import SettingGear from './assets/settingGear.svg';
import Twitter from './assets/TwitterX.svg';
import UploadIcon from './assets/upload.svg';
@@ -41,7 +40,7 @@ import {
setSourceDocs,
} from './preferences/preferenceSlice';
import Upload from './upload/Upload';
-import Dropdown from './components/Dropdown';
+import Help from './components/Help';
interface NavigationProps {
navOpen: boolean;
@@ -305,7 +304,6 @@ export default function Navigation({ navOpen, setNavOpen }: NavigationProps) {
<>>
)}
-
@@ -360,30 +358,11 @@ export default function Navigation({ navOpen, setNavOpen }: NavigationProps) {
-
-
-

-
{
- if (selectedOption.value === 'documentation') {
- window.open(' https://docs.docsgpt.cloud/', '_blank');
- } else if (selectedOption.value === 'email') {
- window.location.href = `mailto:contact@arc53.com`;
- }
- }}
- />
-
-
+
+
+
+
+
-
+
diff --git a/frontend/src/assets/documentation.svg b/frontend/src/assets/documentation.svg
index f9f7c596..955d392f 100644
--- a/frontend/src/assets/documentation.svg
+++ b/frontend/src/assets/documentation.svg
@@ -1,3 +1,4 @@
-