diff --git a/README.md b/README.md index f1942dc1..ee9a1af6 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,8 @@ We're eager to provide personalized assistance when deploying your DocsGPT to a [Send Email :email:](mailto:contact@arc53.com?subject=DocsGPT%20support%2Fsolutions) -![video-example-of-docs-gpt](https://d3dg1063dc54p9.cloudfront.net/videos/demov3.gif) + +video-example-of-docs-gpt ## Roadmap diff --git a/frontend/signal-desktop-keyring.gpg b/frontend/signal-desktop-keyring.gpg new file mode 100644 index 00000000..b5e68a04 Binary files /dev/null and b/frontend/signal-desktop-keyring.gpg differ 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 0cdff05f..3d1dc614 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 Info from './assets/info.svg'; import SettingGear from './assets/settingGear.svg'; import Twitter from './assets/TwitterX.svg'; import UploadIcon from './assets/upload.svg'; @@ -41,6 +40,7 @@ import { setSourceDocs, } from './preferences/preferenceSlice'; import Upload from './upload/Upload'; +import Help from './components/Help'; interface NavigationProps { navOpen: boolean; @@ -307,7 +307,6 @@ export default function Navigation({ navOpen, setNavOpen }: NavigationProps) { <> )}
-
@@ -362,68 +361,51 @@ export default function Navigation({ navOpen, setNavOpen }: NavigationProps) {

-
- { - if (isMobile) { - setNavOpen(!navOpen); - } - resetConversation(); - }} - to="/about" - className={({ isActive }) => - `my-auto mx-4 flex h-9 cursor-pointer gap-4 rounded-3xl hover:bg-gray-100 dark:hover:bg-[#28292E] ${ - isActive ? 'bg-gray-3000 dark:bg-[#28292E]' : '' - }` - } - > - icon -

{t('about')}

-
-
- - discord - - - x - - - github - +
+
+ + +
+ + discord + + + x + + + github + +
diff --git a/frontend/src/assets/documentation-dark.svg b/frontend/src/assets/documentation-dark.svg index 78440206..5cbde1b1 100644 --- a/frontend/src/assets/documentation-dark.svg +++ b/frontend/src/assets/documentation-dark.svg @@ -1,3 +1,4 @@ - - + + + 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 @@ - - + + + diff --git a/frontend/src/assets/envelope-dark.svg b/frontend/src/assets/envelope-dark.svg new file mode 100644 index 00000000..a61bec4f --- /dev/null +++ b/frontend/src/assets/envelope-dark.svg @@ -0,0 +1,3 @@ + + + diff --git a/frontend/src/assets/envelope.svg b/frontend/src/assets/envelope.svg new file mode 100644 index 00000000..a4c25032 --- /dev/null +++ b/frontend/src/assets/envelope.svg @@ -0,0 +1,3 @@ + + + diff --git a/frontend/src/components/Help.tsx b/frontend/src/components/Help.tsx new file mode 100644 index 00000000..0112a805 --- /dev/null +++ b/frontend/src/components/Help.tsx @@ -0,0 +1,80 @@ +import { useState, useRef, useEffect } from 'react'; +import Info from '../assets/info.svg'; +import PageIcon from '../assets/documentation.svg'; +import EmailIcon from '../assets/envelope.svg'; +import { useTranslation } from 'react-i18next'; +const Help = () => { + const [isOpen, setIsOpen] = useState(false); + const dropdownRef = useRef(null); + const buttonRef = useRef(null); + const { t } = useTranslation(); + + const toggleDropdown = () => { + setIsOpen((prev) => !prev); + }; + + const handleClickOutside = (event: MouseEvent) => { + if ( + dropdownRef.current && + !dropdownRef.current.contains(event.target as Node) && + buttonRef.current && + !buttonRef.current.contains(event.target as Node) + ) { + setIsOpen(false); + } + }; + + useEffect(() => { + document.addEventListener('mousedown', handleClickOutside); + return () => { + document.removeEventListener('mousedown', handleClickOutside); + }; + }, []); + + return ( +
+ + {isOpen && ( + + )} +
+ ); +}; + +export default Help; diff --git a/frontend/src/components/SourceDropdown.tsx b/frontend/src/components/SourceDropdown.tsx index 6a348161..f92173a0 100644 --- a/frontend/src/components/SourceDropdown.tsx +++ b/frontend/src/components/SourceDropdown.tsx @@ -121,9 +121,12 @@ function SourceDropdown({ className="flex cursor-pointer items-center justify-between hover:bg-gray-100 dark:text-bright-gray dark:hover:bg-purple-taupe" onClick={handleEmptyDocumentSelect} > - { - handlePostDocumentSelect(null); - }}> + { + handlePostDocumentSelect(null); + }} + > {t('none')}
diff --git a/frontend/src/locale/en.json b/frontend/src/locale/en.json index 76bdea56..335d1e6c 100644 --- a/frontend/src/locale/en.json +++ b/frontend/src/locale/en.json @@ -10,6 +10,9 @@ "sourceDocs": "Source", "none": "None", "cancel": "Cancel", + "help":"Help", + "emailUs":"Email us", + "documentation":"documentation", "demo": [ { "header": "Learn about DocsGPT", diff --git a/frontend/src/locale/es.json b/frontend/src/locale/es.json index 793efcb9..9358aafa 100644 --- a/frontend/src/locale/es.json +++ b/frontend/src/locale/es.json @@ -10,6 +10,9 @@ "sourceDocs": "Fuente", "none": "Nada", "cancel": "Cancelar", + "help":"Asistencia", + "emailUs": "Envíanos un correo", + "documentation": "documentación", "demo": [ { "header": "Aprende sobre DocsGPT", diff --git a/frontend/src/locale/i18n.ts b/frontend/src/locale/i18n.ts index 674a3467..72f9ec28 100644 --- a/frontend/src/locale/i18n.ts +++ b/frontend/src/locale/i18n.ts @@ -25,7 +25,7 @@ i18n zh: { translation: zh, }, - "zh-TW": { + 'zh-TW': { translation: zhTW, }, }, diff --git a/frontend/src/locale/jp.json b/frontend/src/locale/jp.json index 725bfeb4..2adc4947 100644 --- a/frontend/src/locale/jp.json +++ b/frontend/src/locale/jp.json @@ -10,6 +10,9 @@ "sourceDocs": "ソース", "none": "なし", "cancel": "キャンセル", + "help":"ヘルプ", + "emailUs": "メールを送る", + "documentation": "ドキュメント", "demo": [ { "header": "DocsGPTについて学ぶ", diff --git a/frontend/src/locale/zh-TW.json b/frontend/src/locale/zh-TW.json index e91005b5..a826baed 100644 --- a/frontend/src/locale/zh-TW.json +++ b/frontend/src/locale/zh-TW.json @@ -10,6 +10,9 @@ "sourceDocs": "原始文件", "none": "無", "cancel": "取消", + "help":"聯繫支援", + "emailUs": "寄送電子郵件給我們", + "documentation": "文件", "demo": [ { "header": "了解 DocsGPT", diff --git a/frontend/src/locale/zh.json b/frontend/src/locale/zh.json index 79cf6341..427bddc4 100644 --- a/frontend/src/locale/zh.json +++ b/frontend/src/locale/zh.json @@ -10,6 +10,9 @@ "sourceDocs": "源", "none": "无", "cancel": "取消", + "help":"联系支持", + "emailUs": "给我们发邮件", + "documentation": "文档", "demo": [ { "header": "了解 DocsGPT",