Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions apps/web/components/landing-page.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,31 @@ describe('LandingPage', () => {
expect(auraPlusPlusDarkBadgeImage?.getAttribute('height')).toBe('58');
expect(auraPlusPlusDarkBadgeImage?.className).toContain('hidden');
expect(auraPlusPlusDarkBadgeImage?.className).toContain('dark:block');

const openHuntsBadgeLink = screen.getByRole('link', {
name: /OpenHunts Club Member/i
});
expect(openHuntsBadgeLink).toHaveProperty(
'href',
'https://openhunts.com/'
);
expect(openHuntsBadgeLink.getAttribute('target')).toBe('_blank');
expect(openHuntsBadgeLink.getAttribute('rel')).toBe(
'noopener noreferrer'
);
expect(openHuntsBadgeLink.getAttribute('title')).toBe('OpenHunts Club');

const openHuntsBadgeImage = screen.getByAltText(
'OpenHunts Club Member'
);
expect(openHuntsBadgeImage.getAttribute('src')).toBe(
'https://cdn.openhunts.com/badges/club.webp'
);
expect(openHuntsBadgeImage.getAttribute('width')).toBe('486');
expect(openHuntsBadgeImage.getAttribute('height')).toBe('105');
expect(openHuntsBadgeImage.getAttribute('style')).toBe(
'height: auto; width: 195px;'
);
expect(
screen.getByText(
/read or manage vendors, categories, and transactions/i
Expand Down
31 changes: 31 additions & 0 deletions apps/web/components/landing-page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,15 @@ const auraPlusPlusBadge = {
width: 265
} as const;

const openHuntsBadge = {
alt: 'OpenHunts Club Member',
height: 105,
href: 'https://openhunts.com',
src: 'https://cdn.openhunts.com/badges/club.webp',
title: 'OpenHunts Club',
width: 486
} as const;

const apiCurlExample = `curl ${openApiSpecPath}
curl ${mcpEndpointPath} \\
-H "Authorization: Bearer \${XPENSER_API_KEY}"`;
Expand Down Expand Up @@ -599,6 +608,27 @@ function AuraPlusPlusBadge() {
);
}

function OpenHuntsBadge() {
return (
<a
className="block w-fit rounded-md focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
href={openHuntsBadge.href}
rel="noopener noreferrer"
target="_blank"
title={openHuntsBadge.title}
>
{/* biome-ignore lint/performance/noImgElement: OpenHunts provides this hosted badge snippet, and next/image would need remote config for a tiny footer badge. */}
<img
alt={openHuntsBadge.alt}
height={openHuntsBadge.height}
src={openHuntsBadge.src}
style={{ height: 'auto', width: '195px' }}
width={openHuntsBadge.width}
/>
</a>
);
}

function FooterBadges() {
return (
<div className="flex flex-col items-start gap-3 sm:flex-row sm:flex-wrap sm:items-center lg:justify-end">
Expand All @@ -607,6 +637,7 @@ function FooterBadges() {
<EasyDoFollowBadge />
<ScrollLaunchBadge />
<AuraPlusPlusBadge />
<OpenHuntsBadge />
</div>
);
}
Expand Down
Loading