Skip to content

Commit

Permalink
added new icons in CustomFontAwesomeIcon.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
danielecalda committed Sep 25, 2023
1 parent 758dcd2 commit c5a3838
Showing 1 changed file with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
import { faForumbee } from "@fortawesome/free-brands-svg-icons";
import { faCalendar } from "@fortawesome/free-solid-svg-icons";
import { faFileAlt } from "@fortawesome/free-solid-svg-icons/faFileAlt";
import { faUser } from "@fortawesome/free-solid-svg-icons";
import { faSitemap } from "@fortawesome/free-solid-svg-icons";
import { faWikipediaW } from "@fortawesome/free-brands-svg-icons";

export function CustomFontAwesomeIcon<E>({
result
Expand All @@ -17,6 +20,14 @@ export function CustomFontAwesomeIcon<E>({
if (realResult.source.documentTypes.includes("calendar")) {
return <FontAwesomeIcon icon={faCalendar} />;
}

if (realResult.source.documentTypes.includes("user")) {
return <FontAwesomeIcon icon={faUser} />;
}
if (realResult.source.documentTypes.includes("site")) {
return <FontAwesomeIcon icon={faSitemap} />;
}
if (realResult.source.documentTypes.includes("wiki")) {
return <FontAwesomeIcon icon={faWikipediaW} />;
}
return <FontAwesomeIcon icon={faFileAlt} />;
}

0 comments on commit c5a3838

Please sign in to comment.