Skip to content

📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!

added dropdown menu

Vlad Khrystianchuk2e7c9f8a7f66
diff --git a/src/pages/Dashboard/Dashboard.jsx b/src/pages/Dashboard/Dashboard.jsx
index 0a178544c..1e5ee9817 100644
--- a/src/pages/Dashboard/Dashboard.jsx
+++ b/src/pages/Dashboard/Dashboard.jsx
@@ -28,7 +28,7 @@ import { ActivePin, InactivePin, WarningPin } from 'ui/Pin'
import PulsatingCircle from 'ui/icons/PulsatingCircle'
import routes from 'routes'
import {
- isSelfhosted, ENTRIES_PER_PAGE_DASHBOARD, tabForOwnedProject, tabForSharedProject, tabForCaptchaProject, DASHBOARD_TABS,
+ isSelfhosted, ENTRIES_PER_PAGE_DASHBOARD, tabForOwnedProject, tabForSharedProject, tabForCaptchaProject, DASHBOARD_TABS, tabsForDashboard,
} from 'redux/constants'
import EventsRunningOutBanner from 'components/EventsRunningOutBanner'
@@ -315,6 +315,26 @@ const Dashboard = ({
/>
{console.log(activeDashTabLabel)}
</div>
+ <div className='hidden sm:block'>
+ {sharedTotal > 0 && (
+ <nav className='-mb-px flex space-x-8'>
+ {_map(tabsForDashboard, (tab) => (
+ <button
+ key={tab.name}
+ type='button'
+ onClick={() => setTabProjects(tab.name)}
+ className={cx('whitespace-nowrap pb-4 px-1 border-b-2 font-medium text-md', {
+ 'border-indigo-500 text-indigo-600 dark:text-indigo-500': tabProjects === tab.name,
+ 'border-transparent text-gray-500 hover:text-gray-700 hover:border-gray-300 dark:text-gray-400 dark:hover:text-gray-300 dark:hover:border-gray-300': tabProjects !== tab.name,
+ })}
+ aria-current={tab.name === tabProjects ? 'page' : undefined}
+ >
+ {t(tab.label)}
+ </button>
+ ))}
+ </nav>
+ )}
+ </div>
</div>
</div>
{isLoading ? (