diff --git a/src/components/ExternalLink.tsx b/src/components/ExternalLink.tsx new file mode 100644 index 0000000..5232a9d --- /dev/null +++ b/src/components/ExternalLink.tsx @@ -0,0 +1,23 @@ +import React from "react"; +import { FontAwesomeIcon } from "@fortawesome/react-fontawesome"; +import { faExternalLinkAlt } from "@fortawesome/free-solid-svg-icons"; + +type ExternalLinkProps = { + href: string; +}; + +const ExternalLink: React.FC = ({ href, children }) => ( + + + {children} + + + +); + +export default ExternalLink; diff --git a/src/components/TransactionType.tsx b/src/components/TransactionType.tsx index ab4c58a..e7faa6c 100644 --- a/src/components/TransactionType.tsx +++ b/src/components/TransactionType.tsx @@ -1,20 +1,29 @@ import React from "react"; +import ExternalLink from "./ExternalLink"; type TransactionTypeProps = { type: number; }; const TransactionType: React.FC = ({ type }) => { - let description: string; + let description: React.ReactNode; switch (type) { case 0: description = "legacy"; break; case 1: - description = "EIP-2930"; + description = ( + + EIP-2930 + + ); break; case 2: - description = "EIP-1559"; + description = ( + + EIP-1559 + + ); break; default: description = "unknown";