We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1c49873 commit 852da5dCopy full SHA for 852da5d
packages/curve-ui-kit/src/widgets/Header/useVisibleAppLinks.ts
@@ -0,0 +1,9 @@
1
+import { recordEntries } from '@curvefi/prices-api/objects.util'
2
+import { useAnalyticsApp } from '@ui-kit/hooks/useFeatureFlags'
3
+import { APP_LINK } from '@ui-kit/shared/routes'
4
+
5
+/** Some app links are not always visible, depending on certain situations requiring hooks. */
6
+export function useVisibleAppLinks() {
7
+ const showAnalytics = useAnalyticsApp()
8
+ return recordEntries(APP_LINK).filter(([app]) => app !== 'analytics' || showAnalytics)
9
+}
0 commit comments