Skip to content

Commit

Permalink
fix: conditionally render AutomationWalletMode based on appConfig (#658)
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinRohlf authored and moritzkirstein committed Feb 3, 2025
1 parent 29695f6 commit 2d369d6
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/components/Header/UserPreferences/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,23 @@ import Caret from '@images/caret.svg'
import ExternalContent from './ExternalContent'
import AutomationWalletMode from './AutomationWalletMode'
import Onboarding from './Onboarding'
import { useMarketMetadata } from '@context/MarketMetadata'

export default function UserPreferences(): ReactElement {
const { appConfig } = useMarketMetadata()

return (
<Tooltip
content={
<ul className={styles.preferencesDetails}>
<li>
<ExternalContent />
</li>
<li>
<AutomationWalletMode />
</li>
{appConfig.automationConfig.enableAutomation === 'true' && (
<li>
<AutomationWalletMode />
</li>
)}
<li>
<Onboarding />
</li>
Expand Down

0 comments on commit 2d369d6

Please sign in to comment.