betterme-mobile-clone / profile.html
CSNET's picture
แปลงทั้งเว็บเป็นภาษาไทย และใส่การเชื่อมต่อกับ smartwatch เพื่ออ่านค่าออกกำลังกาย และค่า health ต่างๆมาแสดงผลที
066343e verified
Raw History Blame Contribute Delete
11.3 kB
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>โปรไฟล์ - BetterMe</title>
<link rel="icon" type="image/x-icon" href="/static/favicon.ico">
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/feather-icons"></script>
<link href="https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap" rel="stylesheet">
<style>
body {
font-family: 'Poppins', sans-serif;
background-color: #f8f9fa;
}
.gradient-bg {
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}
.card-shadow {
box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}
.active-tab {
border-bottom: 3px solid #667eea;
}
</style>
</head>
<body class="bg-gray-50">
<!-- Header -->
<header class="bg-white shadow-sm sticky top-0 z-10">
<div class="container mx-auto px-4 py-4 flex justify-between items-center">
<div class="flex items-center">
<button class="p-2 rounded-full text-gray-600" onclick="window.location.href='index.html'">
<i data-feather="arrow-left"></i>
</button>
<h1 class="ml-2 text-xl font-bold text-gray-800">โปรไฟล์ของฉัน</h1>
</div>
<button class="p-2 rounded-full bg-gray-100 text-gray-600">
<i data-feather="settings"></i>
</button>
</div>
</header>
<!-- Profile Header -->
<section class="container mx-auto px-4 py-6">
<div class="bg-white rounded-xl p-6 card-shadow">
<div class="flex items-center">
<div class="w-20 h-20 rounded-full bg-gradient-to-r from-purple-500 to-indigo-600 flex items-center justify-center text-white text-2xl font-bold">S</div>
<div class="ml-6">
<h2 class="text-2xl font-bold text-gray-800">ซาร่า จอห์นสัน</h2>
<p class="text-gray-500 mt-1">เป็นสมาชิกตั้งแต่ ม.ค. 2023</p>
<div class="flex items-center mt-2">
<div class="flex items-center">
<i data-feather="star" class="w-4 h-4 text-yellow-400"></i>
<span class="ml-1 text-sm font-medium text-gray-700">1,240 คะแนน</span>
</div>
<div class="flex items-center ml-4">
<i data-feather="award" class="w-4 h-4 text-blue-500"></i>
<span class="ml-1 text-sm font-medium text-gray-700">12 เหรียญรางวัล</span>
</div>
</div>
</div>
</div>
</div>
</section>
<!-- Stats -->
<section class="container mx-auto px-4 mb-6">
<div class="grid grid-cols-3 gap-4">
<div class="bg-white rounded-xl p-4 card-shadow text-center">
<p class="text-2xl font-bold text-gray-800">7</p>
<p class="text-sm text-gray-500 mt-1">วันติดต่อกัน</p>
</div>
<div class="bg-white rounded-xl p-4 card-shadow text-center">
<p class="text-2xl font-bold text-gray-800">24</p>
<p class="text-sm text-gray-500 mt-1">ทำสำเร็จ</p>
</div>
<div class="bg-white rounded-xl p-4 card-shadow text-center">
<p class="text-2xl font-bold text-gray-800">82</p>
<p class="text-sm text-gray-500 mt-1">คะแนนสุขภาพ</p>
</div>
</div>
</section>
<!-- Preferences -->
<section class="container mx-auto px-4 mb-6">
<div class="bg-white rounded-xl p-5 card-shadow">
<h3 class="font-semibold text-gray-800 mb-4">การตั้งค่า</h3>
<div class="space-y-4">
<div class="flex justify-between items-center pb-3 border-b border-gray-100">
<div class="flex items-center">
<div class="w-10 h-10 rounded-full bg-blue-100 flex items-center justify-center text-blue-500">
<i data-feather="bell"></i>
</div>
<div class="ml-4">
<h4 class="font-medium text-gray-800">การแจ้งเตือน</h4>
<p class="text-sm text-gray-500">การเตือนความจำและการแจ้งเตือน</p>
</div>
</div>
<div class="relative inline-block w-10 mr-2 align-middle select-none">
<input type="checkbox" name="toggle" id="notifications" class="checked:bg-blue-500 outline-none focus:ring-0 rounded-full" checked>
<label for="notifications" class="block h-6 w-10 cursor-pointer rounded-full bg-gray-300"></label>
</div>
</div>
<div class="flex justify-between items-center pb-3 border-b border-gray-100">
<div class="flex items-center">
<div class="w-10 h-10 rounded-full bg-green-100 flex items-center justify-center text-green-500">
<i data-feather="moon"></i>
</div>
<div class="ml-4">
<h4 class="font-medium text-gray-800">โหมดกลางคืน</h4>
<p class="text-sm text-gray-500">เปลี่ยนเป็นธีมสีเข้ม</p>
</div>
</div>
<div class="relative inline-block w-10 mr-2 align-middle select-none">
<input type="checkbox" name="toggle" id="darkmode" class="checked:bg-blue-500 outline-none focus:ring-0 rounded-full">
<label for="darkmode" class="block h-6 w-10 cursor-pointer rounded-full bg-gray-300"></label>
</div>
</div>
<div class="flex justify-between items-center">
<div class="flex items-center">
<div class="w-10 h-10 rounded-full bg-purple-100 flex items-center justify-center text-purple-500">
<i data-feather="globe"></i>
</div>
<div class="ml-4">
<h4 class="font-medium text-gray-800">ภาษา</h4>
<p class="text-sm text-gray-500">ไทย</p>
</div>
</div>
<i data-feather="chevron-right" class="text-gray-400"></i>
</div>
</div>
</div>
</section>
<!-- Account -->
<section class="container mx-auto px-4 mb-6">
<div class="bg-white rounded-xl p-5 card-shadow">
<h3 class="font-semibold text-gray-800 mb-4">บัญชี</h3>
<div class="space-y-4">
<div class="flex items-center pb-3 border-b border-gray-100">
<div class="w-10 h-10 rounded-full bg-yellow-100 flex items-center justify-center text-yellow-500">
<i data-feather="user"></i>
</div>
<div class="ml-4 flex-1">
<h4 class="font-medium text-gray-800">แก้ไขโปรไฟล์</h4>
<p class="text-sm text-gray-500">อัปเดตข้อมูลส่วนตัวของคุณ</p>
</div>
<i data-feather="chevron-right" class="text-gray-400"></i>
</div>
<div class="flex items-center pb-3 border-b border-gray-100">
<div class="w-10 h-10 rounded-full bg-red-100 flex items-center justify-center text-red-500">
<i data-feather="lock"></i>
</div>
<div class="ml-4 flex-1">
<h4 class="font-medium text-gray-800">ความปลอดภัย</h4>
<p class="text-sm text-gray-500">รหัสผ่านและการยืนยันตัวตน</p>
</div>
<i data-feather="chevron-right" class="text-gray-400"></i>
</div>
<div class="flex items-center">
<div class="w-10 h-10 rounded-full bg-gray-100 flex items-center justify-center text-gray-500">
<i data-feather="log-out"></i>
</div>
<div class="ml-4 flex-1">
<h4 class="font-medium text-red-500">ออกจากระบบ</h4>
<p class="text-sm text-gray-500">ลงชื่อออกจากบัญชีของคุณ</p>
</div>
<i data-feather="chevron-right" class="text-gray-400"></i>
</div>
</div>
</div>
</section>
<!-- Bottom Navigation -->
<nav class="fixed bottom-0 left-0 right-0 bg-white border-t border-gray-200">
<div class="container mx-auto px-4">
<div class="flex justify-around">
<a href="index.html" class="flex flex-col items-center py-3 text-gray-500">
<i data-feather="home" class="w-5 h-5 mb-1"></i>
<span class="text-xs">หน้าหลัก</span>
</a>
<a href="progress.html" class="flex flex-col items-center py-3 text-gray-500">
<i data-feather="bar-chart-2" class="w-5 h-5 mb-1"></i>
<span class="text-xs">ความคืบหน้า</span>
</a>
<a href="challenges.html" class="flex flex-col items-center py-3 text-gray-500">
<i data-feather="calendar" class="w-5 h-5 mb-1"></i>
<span class="text-xs">กิจกรรม</span>
</a>
<a href="#" class="flex flex-col items-center py-3 text-indigo-600 active-tab">
<i data-feather="user" class="w-5 h-5 mb-1"></i>
<span class="text-xs">โปรไฟล์</span>
</a>
</div>
</div>
</nav>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
<script>
// Initialize Feather Icons
feather.replace();
// Toggle switch functionality
const toggleSwitches = document.querySelectorAll('input[type="checkbox"]');
toggleSwitches.forEach(switchEl => {
switchEl.addEventListener('change', function() {
if (this.checked) {
this.parentElement.classList.add('bg-blue-500');
} else {
this.parentElement.classList.remove('bg-blue-500');
}
});
});
</script>
</body>
</html>