-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(sw): use fully typed locales #14470
refactor(sw): use fully typed locales #14470
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ぱっと見良さそうです。ありがとうございます🙏🏻
ただ、私はi18nについてあまり詳しくないので他のレビュワーの意見を募集したいと思います。
このPRによるapi.jsonの差分 差分はこちら--- base
+++ head
@@ -78484,7 +78484,87 @@
]
},
"achievement": {
- "type": "string"
+ "type": "string",
+ "enum": [
+ "notes1",
+ "notes10",
+ "notes100",
+ "notes500",
+ "notes1000",
+ "notes5000",
+ "notes10000",
+ "notes20000",
+ "notes30000",
+ "notes40000",
+ "notes50000",
+ "notes60000",
+ "notes70000",
+ "notes80000",
+ "notes90000",
+ "notes100000",
+ "login3",
+ "login7",
+ "login15",
+ "login30",
+ "login60",
+ "login100",
+ "login200",
+ "login300",
+ "login400",
+ "login500",
+ "login600",
+ "login700",
+ "login800",
+ "login900",
+ "login1000",
+ "passedSinceAccountCreated1",
+ "passedSinceAccountCreated2",
+ "passedSinceAccountCreated3",
+ "loggedInOnBirthday",
+ "loggedInOnNewYearsDay",
+ "noteClipped1",
+ "noteFavorited1",
+ "myNoteFavorited1",
+ "profileFilled",
+ "markedAsCat",
+ "following1",
+ "following10",
+ "following50",
+ "following100",
+ "following300",
+ "followers1",
+ "followers10",
+ "followers50",
+ "followers100",
+ "followers300",
+ "followers500",
+ "followers1000",
+ "collectAchievements30",
+ "viewAchievements3min",
+ "iLoveMisskey",
+ "foundTreasure",
+ "client30min",
+ "client60min",
+ "noteDeletedWithin1min",
+ "postedAtLateNight",
+ "postedAt0min0sec",
+ "selfQuote",
+ "htl20npm",
+ "viewInstanceChart",
+ "outputHelloWorldOnScratchpad",
+ "open3windows",
+ "driveFolderCircularReference",
+ "reactWithoutRead",
+ "clickedClickHere",
+ "justPlainLucky",
+ "setNameToSyuilo",
+ "cookieClicked",
+ "brainDiver",
+ "smashTestNotificationButton",
+ "tutorialCompleted",
+ "bubbleGameExplodingHead",
+ "bubbleGameDoubleExplodingHead"
+ ]
}
},
"required": [ |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #14470 +/- ##
===========================================
- Coverage 41.69% 41.58% -0.11%
===========================================
Files 1551 1551
Lines 197046 196999 -47
Branches 3620 3617 -3
===========================================
- Hits 82161 81925 -236
- Misses 114293 114510 +217
+ Partials 592 564 -28 ☔ View full report in Codecov by Sentry. |
🙏🏿 |
What
Service Worker においても型安全な
i18n
を用いるようにします。Why
型安全
Additional info (optional)
Service Worker のコンテクストでは
import.meta
はエラーになる?ようなので In-Source Testing はやめて別ファイルに切り出しましたChecklist