Repository navigation
feat: add tsunami map layer and official social links - #588
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
lowrt
reviewed
Oct 6, 2026
lowrt
reviewed
Oct 6, 2026
PiscesXD
force-pushed
the
feat/tsunami-map-layer
branch
from
October 8, 2026 07:20
c3da814 to
1dd987b
Compare
lowrt
force-pushed
the
feat/tsunami-map-layer
branch
3 times, most recently
from
October 11, 2026 03:47
1691363 to
9b2ba21
Compare
PiscesXD
force-pushed
the
feat/tsunami-map-layer
branch
from
October 11, 2026 05:34
9b2ba21 to
c8d89f1
Compare
Platform: all New(zh-Hant): 地圖可以疊上海嘯警報圖層,看預估浪高、抵達時間與沿岸觀測 New(en-US): the map can overlay tsunami warnings with expected heights, arrival times and coastal readings
Platform: all New(zh-Hant): 地圖預設圖層可以選海嘯警報 New(en-US): the default map layer can be the tsunami overlay
Platform: all Fix(zh-Hant): 修正其他語言的圖層分類標題被換成英文 Fix(en-US): the earthquake layer header no longer falls back to English in other languages
Platform: all Fix(zh-Hant): 修正地圖上的篩選選單展開時沒有動畫、直接出現在畫面上 Fix(en-US): the map's filter menus now expand with an animation instead of just appearing
Platform: all Fix(zh-Hant): 修正地震回放頁的返回與圖例按鈕和地圖上的按鈕高度不一致 Fix(en-US): the replay page's back and legend buttons now match the height of the other map buttons
Platform: all Fix(zh-Hant): 調整海嘯沿岸警戒線圖層順序 Fix(en-US): adjust tsunami coastline layer order
Platform: all New(zh-Hant): 更多頁面新增 DPIP 官方 Threads、Instagram 與 Facebook 連結 New(en-US): the More page links to the official DPIP Threads, Instagram and Facebook accounts
Platform: all Fix(zh-Hant): 海嘯預報海岸線放大地圖後會變粗,不再細到看不清楚 Fix(en-US): the tsunami forecast coastline now thickens as you zoom in instead of staying a hairline
PiscesXD
force-pushed
the
feat/tsunami-map-layer
branch
from
October 11, 2026 13:49
71ad0b0 to
c6fe040
Compare
YinCheng0106
approved these changes
Oct 11, 2026
whes1015
approved these changes
Oct 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
這個 PR 做了什麼
地圖新增 CWA 海嘯警報圖層(預估浪高、抵達時間、沿岸觀測),可設為開啟地圖時的預設圖層,海嘯通知也改為開啟地圖。同一個分支另外補上更多頁面的官方社群連結,並修正幾處地圖浮動按鈕與選單的細節。
正式程式碼
lib/features/tsunami/):API、repository 與TsunamiReport領域模型(freezed);tsunami_layer.dart是地圖圖層,含沿岸警戒線,線寬會隨地圖放大加寬;tsunami_panel.dart是面板;notification_routes.dart讓海嘯通知改開地圖;api.md補上端點。SelectablePill(typhoon_panel.dart−57、selectable_pill.dart+68)。default_map_layer.dart、default_map_layer_ui.dart、map_layer_category.dart)。*_overlay_menu.dart、map_chip_button.dart、map_town_labels.dart);地震回放頁的返回與圖例按鈕對齊地圖 chip(report_replay_page.dart、collapsible_map_legend.dart)。more_page.dart),Facebook 使用exptech.com.tw/dpip_tw_FB。測試
tsunami_report_test.dart(+326)。notification_routes_test.dart、default_map_layer_test.dart、map_layer_category_test.dart、map_page_test.dart、more_page_test.dart,以及地震報告詳情與回放頁的測試。規模:61 個檔案,+4900/−196。其中
tsunami_report.freezed.dart(約 1,459 行)、10 個 l10n 產生檔與 12 個 ARB 屬於產生或翻譯內容,審查時可以略過,重點在上面列出的檔案。相關 issue
未指定相關 issue。
怎麼驗
已跑過的檢查
c6fe0401在本機(Darwin)跑DPIP_NO_CACHE=1 tool/commit.sh,不使用快取:format、analyze、codegen 一致性與完整測試全部通過,測試 3136 個通過、10 個跳過、0 個失敗。CI 跑在 Linux,會呼叫 shell 的測試仍可能有差異。changes、build、Android、codecov/patch、codecov/project已成功;撰寫時iOS與code-review還沒有結果。尚未有紀錄的部分:這份描述沒有記錄實機測試或前後截圖,請審查者在 iOS 與 Android 各確認一次:
安全關鍵部分(海嘯警報):海嘯資料在圖層載入時抓取,沒有走
RealtimeChannel,因此沒有 stale/offline 狀態。載入失敗時,圖層會清空公告並顯示錯誤,不會留著舊資料(見tsunami_layer.dart約 150–155 行)。這是讀程式碼得到的結論,沒有實測過斷網或伺服器錯誤的情況,審查時請特別看這一段。檢查清單
tool/check/commits.sh origin/main..HEAD通過—— commit 訊息就是更新日誌,格式見 commit.md
mise exec -- flutter analyze與mise exec -- flutter test通過AppLocalizations,沒有寫死AppSpacing/AppRadius/AppMotion,深色模式看過,文字對比度可接受