Skip to content

Commit 56df891

Browse files
authored
chore: hide buy credits (#526)
* chore: hide buy credits * feat: update SideNavBar to conditionally show login button or credits options
1 parent e6ca5a4 commit 56df891

File tree

1 file changed

+4
-1
lines changed
  • apps/frontend/src/components/organisms/SideNavBar

1 file changed

+4
-1
lines changed

apps/frontend/src/components/organisms/SideNavBar/index.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ export const SideNavbar = ({ networkId }: SideNavbarProps) => {
5050
return true;
5151
});
5252

53+
const hasBuyCreditsFeature =
54+
features.buyCredits && isLoggedIn && account?.model === AccountModel.OneOff;
55+
5356
return (
5457
<Sidebar className='bg-card'>
5558
<AuthModal
@@ -86,7 +89,7 @@ export const SideNavbar = ({ networkId }: SideNavbarProps) => {
8689
/>
8790
)}
8891
{isLoggedIn && account ? (
89-
features.buyCredits ? (
92+
hasBuyCreditsFeature ? (
9093
<BuyMoreCreditsButton />
9194
) : (
9295
<AskForCreditsButton />

0 commit comments

Comments
 (0)