This commit is contained in:
1 parent
850766d54f
commit
f825a523ab
4 files changed
+19
-17
No files matched your search
@@ -2,6 +2,7 @@
|
||||
|
||||
import { useState } from "react";
|
||||
import { Card, Button } from "@/shared/components";
|
||||
import { useCopyToClipboard } from "@/shared/hooks/useCopyToClipboard";
|
||||
import dynamic from "next/dynamic";
|
||||
|
||||
const Editor = dynamic(() => import("@monaco-editor/react"), { ssr: false });
|
||||
@@ -187,9 +188,11 @@ export default function TranslatorPage() {
|
||||
}
|
||||
};
|
||||
|
||||
const { copy } = useCopyToClipboard();
|
||||
|
||||
const handleCopy = async (id) => {
|
||||
if (!contents[id]) return;
|
||||
await navigator.clipboard.writeText(contents[id]);
|
||||
copy(contents[id], `translator-step-${id}`);
|
||||
};
|
||||
|
||||
const handleFormat = (id) => {
|
||||
|
||||
Reference in new issue
Block a user