diff --git a/public/favicon-old.ico b/public/favicon-old.ico new file mode 100644 index 0000000..60c702a Binary files /dev/null and b/public/favicon-old.ico differ diff --git a/public/favicon.ico b/public/favicon.ico index 60c702a..ba84c73 100644 Binary files a/public/favicon.ico and b/public/favicon.ico differ diff --git a/public/icons/copy.svg b/public/icons/copy.svg new file mode 100644 index 0000000..9445889 --- /dev/null +++ b/public/icons/copy.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/public/icons/delete.svg b/public/icons/delete.svg new file mode 100644 index 0000000..5eff460 --- /dev/null +++ b/public/icons/delete.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/public/icons/download.svg b/public/icons/download.svg new file mode 100644 index 0000000..2fa7c19 --- /dev/null +++ b/public/icons/download.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/public/icons/files/archive.svg b/public/icons/files/archive.svg new file mode 100644 index 0000000..6099e18 --- /dev/null +++ b/public/icons/files/archive.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/public/icons/files/code.svg b/public/icons/files/code.svg new file mode 100644 index 0000000..db55cd5 --- /dev/null +++ b/public/icons/files/code.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/public/icons/files/text-file.svg b/public/icons/files/text-file.svg new file mode 100644 index 0000000..f96f53b --- /dev/null +++ b/public/icons/files/text-file.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/public/icons/home.svg b/public/icons/home.svg new file mode 100644 index 0000000..fa69f39 --- /dev/null +++ b/public/icons/home.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/src/app/_components/ActionButtons.tsx b/src/app/_components/ActionButtons.tsx index dcd89a4..fc975ab 100644 --- a/src/app/_components/ActionButtons.tsx +++ b/src/app/_components/ActionButtons.tsx @@ -26,20 +26,7 @@ export function FileActionsContainer({ onClick={() => handleDownload(fileId, fileName)} className="flex items-center justify-center rounded-full bg-blue-500 p-2 hover:bg-blue-600" > - - - + Download {/* Copy URL Button */} @@ -47,20 +34,7 @@ export function FileActionsContainer({ onClick={() => handleCopyUrl(fileUrl)} className="flex items-center justify-center rounded-full bg-green-500 p-2 hover:bg-green-600" > - - - + Copy URL {/* Remove Button */} @@ -68,20 +42,7 @@ export function FileActionsContainer({ onClick={() => handleRemove(fileId)} className="flex items-center justify-center rounded-full bg-red-500 p-2 hover:bg-red-600" > - - - + Remove ); @@ -89,13 +50,13 @@ export function FileActionsContainer({ export function FileDescriptionContainer({ fileId, - fileDescriprtion, + fileDescription, }: { fileId: string; - fileDescriprtion?: string; + fileDescription?: string; }) { - const [description, setDescription] = useState(fileDescriprtion || ""); // Add state for description + const [description, setDescription] = useState(fileDescription || ""); // Add state for description const { handleDescriptionChange } = useFileActions(() => {}, (description: string) => { setDescription(description); return undefined; diff --git a/src/app/_components/FileGrid.tsx b/src/app/_components/FileGrid.tsx index 2b04552..f031d02 100644 --- a/src/app/_components/FileGrid.tsx +++ b/src/app/_components/FileGrid.tsx @@ -6,6 +6,7 @@ import { useRouter } from "next/navigation"; import { env } from "~/env.js"; import { FilePreview } from "~/app/_components/FilePreview"; import { useFileActions } from "~/app/_components/FileActions"; +import { FileActionsContainer } from "./ActionButtons"; interface FileDetails { id: string; @@ -13,6 +14,7 @@ interface FileDetails { url: string; description: string; extension: string; + isOwner: boolean; // Indicates if the user owns the file } interface FileGridProps { @@ -110,68 +112,12 @@ export default function FileGrid({ session }: FileGridProps) {
- {/* Download Button */} - - - {/* Copy URL Button */} - - - {/* Remove Button */} - +
); diff --git a/src/app/_components/HomeButton.tsx b/src/app/_components/HomeButton.tsx index 51befaf..17a10d0 100644 --- a/src/app/_components/HomeButton.tsx +++ b/src/app/_components/HomeButton.tsx @@ -6,7 +6,7 @@ export function HomeButton() { onClick={() => (window.location.href = "/")} className="rounded-full bg-white/10 px-4 py-2 font-semibold hover:bg-white/20" > - Home + Home ); } \ No newline at end of file