Skip to content

Commit

Permalink
fix: generate-i18n scripti
Browse files Browse the repository at this point in the history
Signed-off-by: Innei <i@innei.in>
  • Loading branch information
Innei committed Sep 22, 2024
1 parent 1e212ef commit fd361e8
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions apps/renderer/src/@types/constants.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// This file is auto-generated by scripts/generate-i18n-locale.ts
// DONT EDIT THIS FILE MANUALLY
export const currentSupportedLanguages = [
"en",
"ja",
Expand Down
2 changes: 2 additions & 0 deletions apps/renderer/src/@types/default-resource.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// This file is auto-generated by scripts/generate-i18n-locale.ts
// DONT EDIT THIS FILE MANUALLY
import en from "../../../../locales/app/en.json"
import common_ardz from "../../../../locales/common/ar-DZ.json"
import common_ariq from "../../../../locales/common/ar-IQ.json"
Expand Down
2 changes: 1 addition & 1 deletion scripts/generate-i18n-locale.ts
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,7 @@ function updateConstantsFile(sourceFile: ts.SourceFile, locale: string): string
(context) => (rootNode) => {
function visit(node: ts.Node): ts.Node {
if (ts.isVariableDeclaration(node) && ts.isIdentifier(node.name)) {
if (node.name.text === "langs") {
if (node.name.text === "currentSupportedLanguages") {
return updateLangsArray(node, locale)
}
if (node.name.text === "dayjsLocaleImportMap") {
Expand Down

0 comments on commit fd361e8

Please sign in to comment.