Skip to content

Commit

Permalink
Added websiteUrl
Browse files Browse the repository at this point in the history
  • Loading branch information
nheek committed Oct 2, 2024
1 parent 5ef4218 commit 4653df8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/app/components/MyFiles/MyFiles.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ const MyFiles = () => {
const [modalMessage, setModalMessage] = useState("");
const [isDeleteConfirmationVisible, setIsDeleteConfirmationVisible] = useState(false);
const [fileToDelete, setFileToDelete] = useState<File | null>(null);
const websiteUrl = process.env.DOMAIN;

const showModal = (title: string, message: string) => {
setModalTitle(title);
Expand Down Expand Up @@ -216,7 +217,7 @@ const MyFiles = () => {
<FontAwesomeIcon icon={faTrash} className="text-red-500" />
</button>
<button
onClick={() => copyToClipboard(`/uploads/${file.saved_name}`)}
onClick={() => copyToClipboard(`${websiteUrl}/uploads/${file.saved_name}`)}
className="py-1 px-2 rounded hover:bg-gray-200 transition"
title="Copy Shareable Link"
>
Expand Down

0 comments on commit 4653df8

Please sign in to comment.