From b37d695091af5bb0da73f226881fc7959102d7d0 Mon Sep 17 00:00:00 2001 From: Daniel Date: Tue, 18 Jul 2023 11:34:43 -0400 Subject: [PATCH] small styling improvement --- pages/dashboard.tsx | 92 ++++++++++++++++++++++++++------------------- 1 file changed, 54 insertions(+), 38 deletions(-) diff --git a/pages/dashboard.tsx b/pages/dashboard.tsx index 4f0e973..9e721ff 100644 --- a/pages/dashboard.tsx +++ b/pages/dashboard.tsx @@ -107,14 +107,18 @@ export default function Dashboard() {

{collections.length}

-

Collections

+

+ {collections.length === 1 ? "Collection" : "Collections"} +

{tags.length}

-

Tags

+

+ {tags.length === 1 ? "Tag" : "Tags"} +

@@ -122,45 +126,57 @@ export default function Dashboard() {
- -
- { - setLinkPinDisclosure(!linkPinDisclosure); - }} - className="flex justify-between gap-2 items-baseline shadow active:shadow-inner duration-100 py-2 px-4 rounded-full" - > -

Pinned Links

+ {links.some((e) => e.pinnedBy && e.pinnedBy[0]) ? ( + +
+ { + setLinkPinDisclosure(!linkPinDisclosure); + }} + className="flex justify-between gap-2 items-baseline shadow active:shadow-inner duration-100 py-2 px-4 rounded-full" + > +

Pinned Links

-
- {linkPinDisclosure ? "Hide" : "Show"} - -
-
+
+ {linkPinDisclosure ? "Hide" : "Show"} + +
+ - - - {links - .filter((e) => e.pinnedBy && e.pinnedBy[0]) - .map((e, i) => ( - - ))} - - + + + {links + .filter((e) => e.pinnedBy && e.pinnedBy[0]) + .map((e, i) => ( + + ))} + + +
+
+ ) : ( +
+

+ No Pinned Links +

+

+ You can Pin Links by clicking on the three dots on each Link and + clicking "Pin to Dashboard." +

- + )} {/*