FIX - complete phone locale fallback

Resolve configured and regional locales through a centralized English fallback for Lua and NUI consumers. Complete the German and English app translation keys, localize remaining picker and attachment copy, and add contract tests that detect missing locale entries.
This commit is contained in:
Leon.Schmidt
2026-08-17 15:01:57 +02:00
parent 9adc5a755f
commit e58f1b6c18
15 changed files with 438 additions and 75 deletions
+1 -1
View File
@@ -263,7 +263,7 @@ local function canonical_crewlink_invite(device, invite_code)
if not group then
return nil
end
local locale = (Locales[Config.Bridge.Locale] or Locales["en"]).Phone.Apps.crewlink
local locale = SkyPhoneLocales.Resolve(Config.Bridge.Locale).Nui.Apps.crewlink
local title = locale.shareInviteTitle:gsub("{group}", function() return group.name end)
local copy_text = locale.shareInviteBody
:gsub("{code}", function() return group.invite_code end)
+1 -1
View File
@@ -914,7 +914,7 @@ Bridge.Callbacks.Register("sky_phone:fliptok:delete", function(source, data)
end)
RegisterCommand(Config.FlipTok.VerifyCommand, function(source, arguments)
local command_locale = (Locales[Config.Bridge.Locale] or Locales["en"]).FlipTokCommand
local command_locale = SkyPhoneLocales.Resolve(Config.Bridge.Locale).FlipTokCommand
local function command_message(template, values)
return template:gsub("{(%w+)}", function(key) return values[key] or "" end)
end
+1 -1
View File
@@ -1435,7 +1435,7 @@ Bridge.Callbacks.Register("sky_phone:picstagram:admin-resolve-report", function(
end)
RegisterCommand(Config.Picstagram.VerifyCommand, function(source, args)
local command_locale = (Locales[Config.Bridge.Locale] or Locales["en"]).PicstagramCommand
local command_locale = SkyPhoneLocales.Resolve(Config.Bridge.Locale).PicstagramCommand
local function command_message(template, values)
return template:gsub("{(%w+)}", function(key)
return values[key] or ""