add schudual function

This commit is contained in:
Bkk1234 committed 2026-09-25 04:20:16 +07:00
1 parent d198430310
commit 88311326e6
252 files changed
+4803 -579

No files matched your search

+44 -14
View File
@@ -7,6 +7,8 @@
<link href="https://fonts.googleapis.com/css2?family=Noto+Sans+Thai:wght@400;500;600;700;800&family=Prompt:wght@400;500;600;700&display=swap" rel="stylesheet">
<link href="../../frontend-web-transit/web-transit/css/main-theme.css" rel="stylesheet">
<link href="./_shared.css" rel="stylesheet">
<link href="./vendor/leaflet/leaflet.css" rel="stylesheet">
<link href="./map.css" rel="stylesheet">
<link rel="icon" type="image/png" href="../.image/icons/minibus-512x512.png">
<style>
.mu-card.empty { width: 100%; padding: 16px; text-align: center; color: #6f7b95; background: #fff7fb; border: 1px dashed #f4c7df; }
@@ -24,7 +26,7 @@
display: flex;
align-items: center;
justify-content: center;
background: linear-gradient(135deg, #7a4cc0 0%, #b07ce0 100%);
background: linear-gradient(135deg, #8b5cf6 0%, #c084fc 100%);
position: relative;
}
.mu-card-head::after { display: none; }
@@ -36,12 +38,25 @@
text-shadow: 0 4px 12px rgba(0,0,0,.25);
letter-spacing: .02em;
}
/* zone tint overrides */
.tag-sky ~ .mu-grid .mu-card-head,
.mu-zone:has(.tag-sky) .mu-card-head { background: linear-gradient(135deg, #3071b8 0%, #6ea7e8 100%); }
.mu-zone:has(.tag-purple) .mu-card-head { background: linear-gradient(135deg, #7a4cc0 0%, #b07ce0 100%); }
.mu-zone:has(.tag-pink) .mu-card-head { background: linear-gradient(135deg, #bb3a78 0%, #f08bb9 100%); }
.mu-zone:has(.tag-mint) .mu-card-head { background: linear-gradient(135deg, #1f8765 0%, #51c39c 100%); }
/* zone tint — พื้นหลังการ์ดตามหมวดเส้นทาง (ตัวการ์ด = เฉดอ่อน / หัวการ์ด = เฉดสด) */
.mu-zone:has(.tag-sky) { --zone-tint: #eff6ff; }
.mu-zone:has(.tag-purple) { --zone-tint: #f5f3ff; }
.mu-zone:has(.tag-pink) { --zone-tint: #fdf2f8; }
.mu-zone:has(.tag-yellow) { --zone-tint: #fffbeb; }
.mu-zone .mu-card,
.mu-zone .mu-route-info { background: var(--zone-tint, #fff); }
.mu-zone:has(.tag-sky) .mu-card-head { background: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%); }
.mu-zone:has(.tag-purple) .mu-card-head { background: linear-gradient(135deg, #8b5cf6 0%, #c084fc 100%); }
.mu-zone:has(.tag-pink) .mu-card-head { background: linear-gradient(135deg, #ec4899 0%, #f472b6 100%); }
.mu-zone:has(.tag-yellow) .mu-card-head { background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%); }
/* การ์ดที่ยังไม่มีข้อมูล (is-empty): พื้นเทา + N/A แทนเลขสาย ไม่มีเงาตัวอักษร */
.mu-card.is-empty,
.mu-card.is-empty .mu-route-info { background: #f0f2f5; }
.mu-card.is-empty .mu-card-head { background: #e4e7eb; }
.mu-card.is-empty .mu-route-number { color: #5b636e !important; text-shadow: none !important; font-size: 42px !important; }
.mu-card.is-empty { cursor: default; }
.mu-card.is-empty:hover { transform: none; box-shadow: 0 4px 14px rgba(20,40,90,.06); }
.mu-route-info { padding: 14px 16px 16px; background: #fff; }
.mu-route-name { margin: 0 0 10px; font-size: .95rem; color: #1f2a44; font-weight: 700; }
@@ -87,6 +102,7 @@
margin: 2px auto 0;
}
.mu-select-field { flex: 1 1 250px; min-width: 240px; text-align: left; }
.mu-route-selector.single { max-width: 440px; }
.mu-select-field > label {
display: flex;
align-items: center;
@@ -163,17 +179,26 @@
.mu-zone-tag.tag-sky { background: #dbeafe; color: #1d4ed8; }
.mu-zone-tag.tag-pink { background: #fce7f3; color: #be185d; }
.mu-zone-tag.tag-purple { background: #ede9fe; color: #6d28d9; }
.mu-zone-tag.tag-mint { background: #d1fae5; color: #047857; }
.mu-zone-tag.tag-yellow { background: #fdf1d3; color: #8a6100; }
/* คำอธิบายสีการ์ดตามหมวดเส้นทาง */
.mu-legend { background: #fff; border: 1px solid #e9eef7; border-radius: 14px; padding: 16px 18px; margin-bottom: 26px; box-shadow: 0 4px 14px rgba(20,40,90,.05); }
.mu-legend-title { margin: 0 0 12px; font-size: .95rem; font-weight: 800; color: #1f2a44; }
.mu-legend-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px 18px; }
.mu-legend-list li { display: flex; align-items: center; gap: 9px; font-size: .86rem; color: #3d4a63; }
.mu-legend-list .sw { width: 26px; height: 16px; border-radius: 4px; flex: none; border: 1px solid rgba(20,40,90,.12); }
.sw-bangkok { background: linear-gradient(135deg, #3b82f6, #60a5fa); }
.sw-interprov { background: linear-gradient(135deg, #8b5cf6, #c084fc); }
.sw-inprov { background: linear-gradient(135deg, #ec4899, #f472b6); }
.sw-municipal { background: linear-gradient(135deg, #f59e0b, #fbbf24); }
.sw-empty { background: #e4e7eb; }
.mu-legend-note { margin: 12px 0 0; color: #6f7b95; font-size: .82rem; }
.mu-zone-sub, .mu-zone-desc { color: #6f7b95; font-size: .88rem; margin: 0; }
.mu-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 18px; }
/* Cards */
a.mu-card { display: block; text-decoration: none; color: inherit; background: #fff; border-radius: 16px; overflow: hidden; box-shadow: 0 4px 14px rgba(20,40,90,.06); transition: transform .15s, box-shadow .15s; }
a.mu-card:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(20,40,90,.1); }
/* Zone tints — apply via nth pattern using zone tag presence */
.mu-zone:nth-of-type(1) .mu-card-head { background: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%) !important; }
.mu-zone:nth-of-type(2) .mu-card-head { background: linear-gradient(135deg, #8b5cf6 0%, #c084fc 100%) !important; }
.mu-zone:nth-of-type(3) .mu-card-head { background: linear-gradient(135deg, #ec4899 0%, #f472b6 100%) !important; }
.mu-card { display: block; text-decoration: none; color: inherit; background: #fff; border-radius: 16px; overflow: hidden; box-shadow: 0 4px 14px rgba(20,40,90,.06); transition: transform .15s, box-shadow .15s; }
.mu-card:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(20,40,90,.1); }
.mu-card-head { aspect-ratio: auto !important; height: 130px !important; display: flex !important; align-items: center; justify-content: center; position: relative; }
.mu-card-head::after { display: none !important; }
.mu-card-head .mu-route-number { position: static !important; color: #fff !important; font-size: 52px !important; font-weight: 900; text-shadow: 0 4px 12px rgba(0,0,0,.2) !important; letter-spacing: .02em; margin: 0; }
@@ -185,6 +210,7 @@
.badge-sky { background: #dbeafe; color: #1d4ed8; }
.badge-pink { background: #fce7f3; color: #be185d; }
.badge-mint { background: #d1fae5; color: #047857; }
.badge-gray { background: #e8eaed; color: #5b636e; }
.mu-route-chip-wrap { display:flex; gap: 8px; }
/* Summary stats */
@@ -276,6 +302,8 @@
<link rel="apple-touch-icon" href="../.image/icons/minibus-192x192.png">
<script src="./pwa.js" defer></script>
<script src="./i18n.js" defer></script>
<script src="./vendor/leaflet/leaflet.js" defer></script>
<script src="./map.js" defer></script>
<script src="./router.js" defer></script>
<link rel="stylesheet" href="./responsive.css">
</head>
@@ -361,6 +389,8 @@
<path d="M12 9v4" />
<path d="M12 17h.01" />
</symbol>
<symbol id="ic-share-2" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="18" cy="5" r="3"/><circle cx="6" cy="12" r="3"/><circle cx="18" cy="19" r="3"/><line x1="8.59" y1="13.51" x2="15.42" y2="17.49"/><line x1="15.41" y1="6.51" x2="8.59" y2="10.49"/></symbol>
<symbol id="ic-link" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71"/><path d="M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"/></symbol>
</svg>
<header class="mu-topbar">