Finished bulk delete links

This commit is contained in:
Isaac Wise
2024-02-10 00:37:48 -06:00
parent 193c66123b
commit ea31eb47ae
12 changed files with 195 additions and 20 deletions
@@ -3,8 +3,10 @@ import { LinkIncludingShortenedCollectionAndTags } from "@/types/global";
export default function CardView({
links,
showCheckbox = true,
}: {
links: LinkIncludingShortenedCollectionAndTags[];
showCheckbox?: boolean;
}) {
return (
<div className="grid min-[1900px]:grid-cols-4 xl:grid-cols-3 sm:grid-cols-2 grid-cols-1 gap-5">
@@ -15,6 +17,7 @@ export default function CardView({
link={e}
count={i}
flipDropdown={i === links.length - 1}
showCheckbox={showCheckbox}
/>
);
})}
@@ -3,8 +3,10 @@ import { LinkIncludingShortenedCollectionAndTags } from "@/types/global";
export default function ListView({
links,
showCheckbox = true
}: {
links: LinkIncludingShortenedCollectionAndTags[];
showCheckbox?: boolean;
}) {
return (
<div className="flex flex-col">
@@ -14,6 +16,7 @@ export default function ListView({
key={i}
link={e}
count={i}
showCheckbox={showCheckbox}
flipDropdown={i === links.length - 1}
/>
);
+2 -1
View File
@@ -16,6 +16,7 @@ import Link from "next/link";
import LinkIcon from "./LinkComponents/LinkIcon";
import useOnScreen from "@/hooks/useOnScreen";
import { generateLinkHref } from "@/lib/client/generateLinkHref";
import useAccountStore from "@/store/account";
type Props = {
link: LinkIncludingShortenedCollectionAndTags;
@@ -28,7 +29,7 @@ type Props = {
export default function LinkCard({
link,
flipDropdown,
showCheckbox,
showCheckbox = true,
}: Props) {
const { collections } = useCollectionStore();
+1 -1
View File
@@ -25,7 +25,7 @@ type Props = {
export default function LinkCardCompact({
link,
flipDropdown,
showCheckbox,
showCheckbox = true,
}: Props) {
const { collections } = useCollectionStore();
const { links, setSelectedLinks, selectedLinks } = useLinkStore();