chatbot1 / index.html
kritsanan's picture
Add 3 files
bc0dd89 verified
<!DOCTYPE html>
<html lang="th">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>ที่นี่หว้าซำม้อ | Tee Nee Wang Sam Mor</title>
<script src="https://cdn.tailwindcss.com"></script>
<link href="https://fonts.googleapis.com/css2?family=Sarabun:wght@300;400;500;600;700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<style>
body {
font-family: 'Sarabun', sans-serif;
background-color: #FFF9F0;
}
.user-bubble {
background-color: #FFDEAD;
border-radius: 16px 16px 0 16px;
}
.bot-bubble {
background-color: #FFE4B5;
border-radius: 16px 16px 16px 0;
}
.quick-reply {
background-color: #FFE4B5;
border-radius: 20px;
transition: all 0.2s;
}
.quick-reply:hover {
background-color: #FFD699;
}
.pulse {
animation: pulse 1.5s infinite;
}
@keyframes pulse {
0% { opacity: 0.6; }
50% { opacity: 1; }
100% { opacity: 0.6; }
}
.shadow-separator {
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
</style>
</head>
<body class="flex flex-col h-screen">
<!-- Header Section -->
<header class="bg-white shadow-separator fixed top-0 w-full z-10" style="height: 60px;">
<div class="flex items-center justify-between h-full px-4">
<!-- Logo -->
<div class="flex items-center">
<img src="https://img5.pic.in.th/file/secure-sv1/307460108_387435583599238_6386334495691428178_n-removebg-preview.png"
alt="ที่นี่หว้าซำม้อ Logo"
class="h-8">
<div class="ml-2">
<h1 class="text-lg font-semibold text-gray-800">ที่นี่หว้าซำม้อ</h1>
<p class="text-xs text-gray-500">Tee Nee Wang Sam Mor</p>
</div>
</div>
<!-- Header Controls -->
<div class="flex items-center space-x-2">
<!-- LINE Connect -->
<button aria-label="Connect with LINE"
class="w-11 h-11 flex items-center justify-center rounded-full bg-green-500 text-white">
<i class="fab fa-line text-xl"></i>
</button>
<!-- Language Toggle -->
<button aria-label="Toggle language"
class="w-11 h-11 flex items-center justify-center rounded-full bg-gray-100 text-gray-700">
<i class="fas fa-language text-xl"></i>
</button>
</div>
</div>
</header>
<!-- Chat Container -->
<main class="flex-1 overflow-y-auto pt-16 pb-20 px-4 bg-gray-50">
<!-- Welcome Message -->
<div class="mb-4">
<div class="bot-bubble px-4 py-3 max-w-xs md:max-w-md">
<p class="text-gray-800">สวัสดีค่ะ! ยินดีต้อนรับสู่ที่นี่หว้าซำม้อ</p>
<p class="text-gray-800 mt-1">ฉันเป็นผู้ช่วยอัจฉริยะที่พร้อมให้บริการคุณ</p>
<p class="text-xs text-gray-500 mt-2">10:30 น.</p>
</div>
</div>
<!-- User Message -->
<div class="mb-4 flex justify-end">
<div class="user-bubble px-4 py-3 max-w-xs md:max-w-md">
<p class="text-gray-800">อยากทราบข้อมูลเกี่ยวกับวัดอรุณ</p>
<p class="text-xs text-gray-500 mt-2">10:32 น.</p>
</div>
</div>
<!-- Bot Response with Quick Replies -->
<div class="mb-4">
<div class="bot-bubble px-4 py-3 max-w-xs md:max-w-md">
<p class="text-gray-800">วัดอรุณราชวราราม หรือที่นิยมเรียกกันว่า วัดแจ้ง เป็นวัดโบราณสร้างมาตั้งแต่สมัยอยุธยา ตั้งอยู่ริมแม่น้ำเจ้าพระยา</p>
<!-- Media Preview -->
<div class="mt-3 rounded-lg overflow-hidden">
<img src="https://img2.pic.in.th/pic/image-19f4bb7a9e083dc11a.jpg"
alt="วัดอรุณราชวราราม"
class="w-full h-auto">
</div>
<p class="text-xs text-gray-500 mt-2">10:33 น.</p>
</div>
<!-- Quick Replies -->
<div class="mt-2 flex flex-wrap gap-2">
<button class="quick-reply px-4 py-2 text-sm text-gray-800">
ประวัติเพิ่มเติม
</button>
<button class="quick-reply px-4 py-2 text-sm text-gray-800">
เวลาเปิด-ปิด
</button>
<button class="quick-reply px-4 py-2 text-sm text-gray-800">
การเดินทาง
</button>
<button class="quick-reply px-4 py-2 text-sm text-gray-800">
ภาพถ่ายเพิ่มเติม
</button>
</div>
</div>
<!-- Bot Loading State -->
<div class="mb-4">
<div class="bot-bubble px-4 py-3 max-w-xs md:max-w-md flex items-center space-x-2">
<div class="w-2 h-2 rounded-full bg-gray-600 pulse"></div>
<div class="w-2 h-2 rounded-full bg-gray-600 pulse" style="animation-delay: 0.2s"></div>
<div class="w-2 h-2 rounded-full bg-gray-600 pulse" style="animation-delay: 0.4s"></div>
</div>
</div>
</main>
<!-- Input Section -->
<footer class="bg-white border-t border-gray-200 fixed bottom-0 w-full" style="height: 72px;">
<div class="flex items-center h-full px-3">
<!-- Voice Input -->
<button aria-label="Voice input"
class="w-11 h-11 flex items-center justify-center rounded-full text-gray-600">
<i class="fas fa-microphone text-xl"></i>
</button>
<!-- Text Input -->
<div class="flex-1 mx-2">
<input type="text"
placeholder="พิมพ์ข้อความที่นี่..."
class="w-full px-4 py-2 rounded-full border border-gray-300 focus:outline-none focus:ring-2 focus:ring-amber-200 focus:border-transparent"
style="min-height: 44px;">
</div>
<!-- Attachment -->
<button aria-label="Attach file"
class="w-11 h-11 flex items-center justify-center rounded-full text-gray-600 mr-1">
<i class="fas fa-paperclip text-xl"></i>
</button>
<!-- Send Button -->
<button aria-label="Send message"
class="w-11 h-11 flex items-center justify-center rounded-full bg-amber-500 text-white">
<i class="fas fa-paper-plane text-xl"></i>
</button>
</div>
<!-- Quick Action Toolbar (Collapsible) -->
<div class="bg-gray-100 px-3 py-2 flex justify-around">
<button class="flex flex-col items-center text-xs text-gray-700">
<i class="fas fa-map-marker-alt text-lg mb-1"></i>
<span>สถานที่ใกล้ฉัน</span>
</button>
<button class="flex flex-col items-center text-xs text-gray-700">
<i class="fas fa-utensils text-lg mb-1"></i>
<span>อาหารไทย</span>
</button>
<button class="flex flex-col items-center text-xs text-gray-700">
<i class="fas fa-landmark text-lg mb-1"></i>
<span>วัดสำคัญ</span>
</button>
<button class="flex flex-col items-center text-xs text-gray-700">
<i class="fas fa-calendar-alt text-lg mb-1"></i>
<span>กิจกรรม</span>
</button>
</div>
</footer>
<script>
// Simple interaction example
document.addEventListener('DOMContentLoaded', function() {
// Handle quick reply clicks
const quickReplies = document.querySelectorAll('.quick-reply');
quickReplies.forEach(reply => {
reply.addEventListener('click', function() {
const text = this.textContent.trim();
// In a real app, this would send the quick reply text to the chat
console.log('Quick reply selected:', text);
});
});
// Handle send button
const sendButton = document.querySelector('[aria-label="Send message"]');
const inputField = document.querySelector('input[type="text"]');
sendButton.addEventListener('click', function() {
if (inputField.value.trim() !== '') {
// In a real app, this would send the message
console.log('Message sent:', inputField.value);
inputField.value = '';
}
});
// Allow pressing Enter to send
inputField.addEventListener('keypress', function(e) {
if (e.key === 'Enter') {
sendButton.click();
}
});
});
</script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=kritsanan/chatbot1" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>