-
Notifications
You must be signed in to change notification settings - Fork 440
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7eff16f
commit 2c5717f
Showing
6 changed files
with
46 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import type { PropsWithChildren } from "react"; | ||
import { Anchor } from "../ui/Anchor"; | ||
|
||
export const RequirementLink = ({ | ||
href, | ||
children, | ||
}: PropsWithChildren<{ href: string }>) => ( | ||
<Anchor | ||
href={href} | ||
target="_blank" | ||
rel="noopener" | ||
variant="secondary" | ||
showExternal | ||
className="font-medium text-xs" | ||
> | ||
{children} | ||
</Anchor> | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import { RequirementLink } from "@/components/requirements/RequirementLink"; | ||
import type { Meta, StoryObj } from "@storybook/react"; | ||
|
||
const meta: Meta<typeof RequirementLink> = { | ||
title: "Requirement building blocks/RequirementLink", | ||
component: RequirementLink, | ||
}; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj<typeof RequirementLink>; | ||
|
||
export const Default: Story = { | ||
args: { | ||
href: "https://polygonscan.com/token/0xff04820c36759c9f5203021fe051239ad2dcca8a", | ||
children: "Guild Pin contract", | ||
}, | ||
}; |