Skip to content

Commit

Permalink
TW-1614: Temple Tap Airdrop confirmation. Remove button from asset pages
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-tsx committed Dec 24, 2024
1 parent 1314162 commit 659082e
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 13 deletions.
22 changes: 12 additions & 10 deletions src/app/layouts/PageLayout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,11 @@ interface ToolbarProps {
hasBackAction?: boolean;
step?: number;
setStep?: (step: number) => void;
adShow?: boolean;
skip?: boolean;
attention?: boolean;
withDonation?: boolean;
withBell?: boolean;
withAd?: boolean;
withAirdrop?: boolean;
}

export let ToolbarElement: HTMLDivElement | null = null;
Expand All @@ -133,10 +134,11 @@ const Toolbar: FC<ToolbarProps> = ({
hasBackAction = true,
step,
setStep,
adShow = false,
skip,
attention,
withBell
withDonation,
withBell,
withAd,
withAirdrop
}) => {
const { historyPosition, pathname } = useLocation();
const { fullPage } = useAppEnv();
Expand Down Expand Up @@ -207,7 +209,7 @@ const Toolbar: FC<ToolbarProps> = ({
return (
<div ref={updateRootRef} className={className}>
<div className="flex-1">
{!isBackButtonAvailable && adShow && <DonationBanner />}
{!isBackButtonAvailable && withDonation && <DonationBanner />}

{isBackButtonAvailable && (
<Button
Expand Down Expand Up @@ -235,11 +237,11 @@ const Toolbar: FC<ToolbarProps> = ({

<div className="flex-1" />

{(attention || withBell) && (
{(withAd || withAirdrop || withBell) && (
<div className="flex items-center gap-x-2 content-end">
{attention && <AdvertisingBanner />}
{attention && <AirdropButton />}
<NotificationsBell />
{withAd && <AdvertisingBanner />}
{withAirdrop && <AirdropButton />}
{withBell && <NotificationsBell />}
</div>
)}

Expand Down
7 changes: 4 additions & 3 deletions src/app/pages/Home/Home.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,10 @@ const Home = memo<Props>(({ assetSlug }) => {
</span>
) : null
}
attention={true}
withBell={true}
adShow
withDonation
withBell
withAd
withAirdrop={!assetSlug}
>
{fullPage && (
<div className="w-full max-w-sm mx-auto">
Expand Down

0 comments on commit 659082e

Please sign in to comment.