Update index.html
Browse files- index.html +11 -12
index.html
CHANGED
|
@@ -239,7 +239,7 @@ function createUserMessage(text) {
|
|
| 239 |
prefix = 'ุงุนุทูู ุฑุฏ ู
ูุตู ูู
ูุณุน: ';
|
| 240 |
}
|
| 241 |
|
| 242 |
-
return
|
| 243 |
<div class="message flex justify-end mb-4">
|
| 244 |
<div class="max-w-[80%]">
|
| 245 |
<div class="bg-indigo-500 text-white rounded-lg p-4 shadow-sm">
|
|
@@ -247,11 +247,11 @@ function createUserMessage(text) {
|
|
| 247 |
</div>
|
| 248 |
</div>
|
| 249 |
</div>
|
| 250 |
-
|
| 251 |
}
|
| 252 |
|
| 253 |
function createBotMessage(text, messageId) {
|
| 254 |
-
return
|
| 255 |
<div class="message flex justify-start mb-4">
|
| 256 |
<div class="flex-shrink-0 mt-1">
|
| 257 |
<img src="https://ufastpro.com/wp-content/uploads/2024/12/3.png" alt="Bot Avatar" class="bot-avatar">
|
|
@@ -288,7 +288,7 @@ function createBotMessage(text, messageId) {
|
|
| 288 |
</div>
|
| 289 |
</div>
|
| 290 |
</div>
|
| 291 |
-
|
| 292 |
}
|
| 293 |
|
| 294 |
async function typeText(elementId, text) {
|
|
@@ -309,18 +309,18 @@ function toggleSendButton(isGenerating) {
|
|
| 309 |
const sendButton = document.getElementById('sendMessage');
|
| 310 |
if (isGenerating) {
|
| 311 |
sendButton.classList.add('stop-generation');
|
| 312 |
-
sendButton.innerHTML =
|
| 313 |
<svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
| 314 |
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12"></path>
|
| 315 |
</svg>
|
| 316 |
-
|
| 317 |
} else {
|
| 318 |
sendButton.classList.remove('stop-generation');
|
| 319 |
-
sendButton.innerHTML =
|
| 320 |
<svg class="w-6 h-6 transform rotate-90" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
| 321 |
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 10l7-7m0 0l7 7m-7-7v18"></path>
|
| 322 |
</svg>
|
| 323 |
-
|
| 324 |
}
|
| 325 |
}
|
| 326 |
|
|
@@ -393,12 +393,12 @@ document.addEventListener('click', async (e) => {
|
|
| 393 |
await navigator.clipboard.writeText(text);
|
| 394 |
e.target.closest('.copy-button').textContent = 'ุชู
ุงููุณุฎ!';
|
| 395 |
setTimeout(() => {
|
| 396 |
-
e.target.closest('.copy-button').innerHTML =
|
| 397 |
<svg class="w-4 h-4" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
| 398 |
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M8 5H6a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2v-1M8 5a2 2 0 002 2h2a2 2 0 002-2M8 5a2 2 0 012-2h2a2 2 0 012 2m0 0h2a2 2 0 012 2v3m2 4H10m0 0l3-3m-3 3l3 3"></path>
|
| 399 |
</svg>
|
| 400 |
ูุณุฎ
|
| 401 |
-
|
| 402 |
}, 2000);
|
| 403 |
}
|
| 404 |
|
|
@@ -454,5 +454,4 @@ messagesContainer.insertAdjacentHTML('beforeend', createBotMessage('', initialMe
|
|
| 454 |
typeText(initialMessageId, 'ู
ุฑุญุจุงู! ููู ูู
ูููู ู
ุณุงุนุฏุชู ุงูููู
ุ');
|
| 455 |
</script>
|
| 456 |
</body>
|
| 457 |
-
</html>
|
| 458 |
-
|
|
|
|
| 239 |
prefix = 'ุงุนุทูู ุฑุฏ ู
ูุตู ูู
ูุณุน: ';
|
| 240 |
}
|
| 241 |
|
| 242 |
+
return `
|
| 243 |
<div class="message flex justify-end mb-4">
|
| 244 |
<div class="max-w-[80%]">
|
| 245 |
<div class="bg-indigo-500 text-white rounded-lg p-4 shadow-sm">
|
|
|
|
| 247 |
</div>
|
| 248 |
</div>
|
| 249 |
</div>
|
| 250 |
+
`;
|
| 251 |
}
|
| 252 |
|
| 253 |
function createBotMessage(text, messageId) {
|
| 254 |
+
return `
|
| 255 |
<div class="message flex justify-start mb-4">
|
| 256 |
<div class="flex-shrink-0 mt-1">
|
| 257 |
<img src="https://ufastpro.com/wp-content/uploads/2024/12/3.png" alt="Bot Avatar" class="bot-avatar">
|
|
|
|
| 288 |
</div>
|
| 289 |
</div>
|
| 290 |
</div>
|
| 291 |
+
`;
|
| 292 |
}
|
| 293 |
|
| 294 |
async function typeText(elementId, text) {
|
|
|
|
| 309 |
const sendButton = document.getElementById('sendMessage');
|
| 310 |
if (isGenerating) {
|
| 311 |
sendButton.classList.add('stop-generation');
|
| 312 |
+
sendButton.innerHTML = `
|
| 313 |
<svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
| 314 |
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12"></path>
|
| 315 |
</svg>
|
| 316 |
+
`;
|
| 317 |
} else {
|
| 318 |
sendButton.classList.remove('stop-generation');
|
| 319 |
+
sendButton.innerHTML = `
|
| 320 |
<svg class="w-6 h-6 transform rotate-90" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
| 321 |
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 10l7-7m0 0l7 7m-7-7v18"></path>
|
| 322 |
</svg>
|
| 323 |
+
`;
|
| 324 |
}
|
| 325 |
}
|
| 326 |
|
|
|
|
| 393 |
await navigator.clipboard.writeText(text);
|
| 394 |
e.target.closest('.copy-button').textContent = 'ุชู
ุงููุณุฎ!';
|
| 395 |
setTimeout(() => {
|
| 396 |
+
e.target.closest('.copy-button').innerHTML = `
|
| 397 |
<svg class="w-4 h-4" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
| 398 |
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M8 5H6a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2v-1M8 5a2 2 0 002 2h2a2 2 0 002-2M8 5a2 2 0 012-2h2a2 2 0 012 2m0 0h2a2 2 0 012 2v3m2 4H10m0 0l3-3m-3 3l3 3"></path>
|
| 399 |
</svg>
|
| 400 |
ูุณุฎ
|
| 401 |
+
`;
|
| 402 |
}, 2000);
|
| 403 |
}
|
| 404 |
|
|
|
|
| 454 |
typeText(initialMessageId, 'ู
ุฑุญุจุงู! ููู ูู
ูููู ู
ุณุงุนุฏุชู ุงูููู
ุ');
|
| 455 |
</script>
|
| 456 |
</body>
|
| 457 |
+
</html>
|
|
|