@@ -1,5 +1,6 @@
11import { Markdown } from "@urbit/foundation-design-system";
2−import classnames from "classnames";
2+import EcosystemBadge from "./Badge";
3+
34import Link from "next/link";
45export default function Post({ post }) {
56 return ["featured-1", "featured-2", "featured-3"].map((feat) => {
@@ -34,7 +35,7 @@ export default function Post({ post }) {
3435 <h4 className="text-xl pb-2 leading-6 font-bold">
3536 {post?.[feat].title}
3637 </h4>
37− {badge(post[feat].type)}
38+ <EcosystemBadge type={post[feat].type} />
3839 </div>
3940 </div>
4041 <div className="markdown mt-8 mb-8">
@@ -94,22 +95,4 @@ export default function Post({ post }) {
9495 });
9596}
9697
97−const badge = (type) => {
98− return (
99− <div
100− className={classnames(
101− "uppercase font-bold text-white text-xs w-fit rounded-lg mb-2 px-2 py-1",
102− {
103− "bg-[#B37ED7]": type === "Organization",
104− "bg-[#83b2d4]": type === "Application",
105− "bg-wall-600": type === "Podcast",
106− "bg-[#8dd5b1]": type === "Marketplace",
107− "bg-[#B5966D]": type === "Article",
108− "bg-[#219DFF]": type === "Group",
109− }
110− )}
111− >
112− {type}
113− </div>
114− );
115−};
98+