diff --git a/ui/src/pages/query-profile/index.tsx b/ui/src/pages/query-profile/index.tsx index fa257733e8..5590ce9085 100644 --- a/ui/src/pages/query-profile/index.tsx +++ b/ui/src/pages/query-profile/index.tsx @@ -90,6 +90,15 @@ export default function QueryProfile(params: any) { URL.revokeObjectURL(tagA.href); document.body.removeChild(tagA); } + function copyToClipboard(profile: string) { + const profileTxt = replaceToTxt(profile); + const textarea = document.createElement("textarea"); + textarea.value = profileTxt; + document.body.appendChild(textarea); + textarea.select(); + document.execCommand('copy'); + document.body.removeChild(textarea); + } return ( @@ -103,6 +112,9 @@ export default function QueryProfile(params: any) { + : ''}