diff --git a/frontend/public/locales/en.json b/frontend/public/locales/en.json index 6b31ac8..60893e8 100644 --- a/frontend/public/locales/en.json +++ b/frontend/public/locales/en.json @@ -131,7 +131,10 @@ "stops.noOffset": "No travel time from the first stop yet", "stops.noBusLine": "No bus line listed", "stops.modeCode": "Search by stop code", - "stops.modePlace": "Search by place name", + "stops.modeNear": "Near me", + "stops.nearCta": "Use my location", + "stops.nearHint": "We ask your device for a location, then rank stops by real distance from their coordinates.", +"stops.modePlace": "Search by place name", "stops.codePh": "3+000", "stops.codeHint": "Type 4 digits and the + sign is added automatically (e.g. 3000 → 3+000)", "stops.codeHintBox": "Type digits in the boxes — empty boxes are filled with 0 automatically. For 4-digit codes such as 8+591, enter 08+591", diff --git a/frontend/public/locales/th.json b/frontend/public/locales/th.json index c3170d7..70f825d 100644 --- a/frontend/public/locales/th.json +++ b/frontend/public/locales/th.json @@ -131,7 +131,10 @@ "stops.noOffset": "ยังไม่ระบุเวลาเดินทางจากจุดแรก", "stops.noBusLine": "ยังไม่ระบุสายรถ", "stops.modeCode": "ค้นหาด้วยรหัสป้าย", - "stops.modePlace": "ค้นหาด้วยชื่อสถานที่", + "stops.modeNear": "ป้ายใกล้ฉัน", + "stops.nearCta": "ขอพิกัดและหาป้ายใกล้ฉัน", + "stops.nearHint": "ระบบจะขอตำแหน่งจากเครื่อง แล้วคำนวณระยะจากพิกัดป้าย/ศาลารถ เรียงจากใกล้ไปไกล", +"stops.modePlace": "ค้นหาด้วยชื่อสถานที่", "stops.codePh": "3+000", "stops.codeHint": "พิมพ์ตัวเลข 4 หลัก ระบบจะเติมเครื่องหมาย + ให้อัตโนมัติ (เช่น 3000 → 3+000)", "stops.codeHintBox": "พิมพ์ตัวเลขในช่อง ระบบจะเติม 0 ให้อัตโนมัติเมื่อเว้นว่าง และถ้าเจอรหัส 4 หลัก เช่น 8+591 ให้กรอก 08+591", diff --git a/frontend/src/components/views/StopsView.tsx b/frontend/src/components/views/StopsView.tsx index 73b1935..16c9f91 100644 --- a/frontend/src/components/views/StopsView.tsx +++ b/frontend/src/components/views/StopsView.tsx @@ -30,6 +30,11 @@ export default function StopsView() { ค้นหาด้วยชื่อสถานที่ + {/* หมวดที่ 3: หาป้ายจากพิกัดผู้ใช้ — ซ่อนอัตโนมัติเมื่อไม่ได้ HTTPS (ดู stops.nearme.ts) */} + {/* โหมด 1: รหัสป้าย (5 ช่อง: 2 หน้า + 3 หลัง) */}
@@ -53,13 +58,19 @@ export default function StopsView() { + {/* หมวดที่ 3: ป้ายใกล้ฉัน — ขอพิกัดจากมือถือ แล้วเรียงป้ายตามระยะจริง */} +
- ย้อนกลับ