diff --git a/components/AddLinkModal.tsx b/components/AddLinkModal.tsx index e179a8b..31cf1c2 100644 --- a/components/AddLinkModal.tsx +++ b/components/AddLinkModal.tsx @@ -1,7 +1,8 @@ import React, { useState } from "react"; import CollectionSelection from "./InputSelect/CollectionSelection"; import TagSelection from "./InputSelect/TagSelection"; - +import { FontAwesomeIcon } from "@fortawesome/react-fontawesome"; +import { faPlus } from "@fortawesome/free-solid-svg-icons"; interface NewLink { name: string; url: string; @@ -90,9 +91,10 @@ export default function () {
postLink()} > + Add Link
diff --git a/components/InputSelect/CollectionSelection.tsx b/components/InputSelect/CollectionSelection.tsx index 8a1822f..e603d3a 100644 --- a/components/InputSelect/CollectionSelection.tsx +++ b/components/InputSelect/CollectionSelection.tsx @@ -17,10 +17,14 @@ export default function ({ onChange }: any) { return e.id === collectionId; }); - const defaultCollection = { - value: activeCollection?.id, - label: activeCollection?.name, - }; + let defaultCollection = null; + + if (activeCollection) { + defaultCollection = { + value: activeCollection?.id, + label: activeCollection?.name, + }; + } useEffect(() => { const formatedCollections = collections.map((e) => { diff --git a/components/Sidebar/index.tsx b/components/Sidebar/index.tsx index daa0a5f..9e33899 100644 --- a/components/Sidebar/index.tsx +++ b/components/Sidebar/index.tsx @@ -8,8 +8,9 @@ import { faPlus, faChevronDown, faFolder, - faHouse, + faBoxesStacked, faHashtag, + faBookmark, } from "@fortawesome/free-solid-svg-icons"; import SidebarItem from "./SidebarItem"; import useTagSlice from "@/store/tags"; @@ -50,7 +51,9 @@ export default function () { - + + +

Collections