From 5ff3d7ae16a6ad89c145e0ead952f6724e5c26da Mon Sep 17 00:00:00 2001 From: Nastya Date: Sun, 15 Jun 2025 20:43:39 +0300 Subject: [PATCH] 3 min --- src/pages/PersonalizationAI/CopyButton.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/pages/PersonalizationAI/CopyButton.tsx b/src/pages/PersonalizationAI/CopyButton.tsx index 9bcf0fe6..df82a2f5 100644 --- a/src/pages/PersonalizationAI/CopyButton.tsx +++ b/src/pages/PersonalizationAI/CopyButton.tsx @@ -35,7 +35,7 @@ export const CopyButton = ({ created_at, onCopy, text }: CopyButtonProps) => { const now = new Date().getTime(); const created = getCreatedTime(created_at); const diffInMinutes = (now - created) / (1000 * 60); - return diffInMinutes < 2; + return diffInMinutes < 3; }); useEffect(() => { @@ -49,14 +49,14 @@ export const CopyButton = ({ created_at, onCopy, text }: CopyButtonProps) => { setIsLoading(true); } - if (diffInMinutes < 2) { - const timeLeft = Math.ceil((2 - diffInMinutes) * 60 * 1000); + if (diffInMinutes < 3) { + const timeLeft = Math.ceil((3 - diffInMinutes) * 60 * 1000); setTimeLeft(formatTimeLeft(timeLeft)); const timer = setInterval(() => { const currentTime = new Date().getTime(); const elapsed = currentTime - created; - const remaining = 2 * 60 * 1000 - elapsed; + const remaining = 3 * 60 * 1000 - elapsed; if (remaining <= 0) { setIsLoading(false);