diff --git a/client/src/components/Tool/utilities.js b/client/src/components/Tool/utilities.js index 1b0a6d5a0ad2..84f9d2bd3fd2 100644 --- a/client/src/components/Tool/utilities.js +++ b/client/src/components/Tool/utilities.js @@ -2,7 +2,9 @@ import { getAppRoot } from "onload/loadConfig"; import { copy } from "utils/clipboard"; export function copyLink(toolId, message) { - copy(`${window.location.origin + getAppRoot()}root?tool_id=${toolId}`, message); + const link = `${window.location.origin + getAppRoot()}root?tool_id=${toolId}`; + // Encode the link to handle special characters in tool id + copy(encodeURI(link), message); } export function copyId(toolId, message) {