mirror of
https://github.com/luanti-org/luanti.git
synced 2025-09-15 18:57:08 +00:00
Add support for translating content titles and descriptions (#12208)
This commit is contained in:
parent
57de599a29
commit
b4be483d3e
12 changed files with 252 additions and 47 deletions
|
@ -114,12 +114,13 @@ local function get_formspec(tabview, name, tabdata)
|
|||
modscreenshot = defaulttexturedir .. "no_screenshot.png"
|
||||
end
|
||||
|
||||
local info = core.get_content_info(selected_pkg.path)
|
||||
local desc = fgettext("No package description available")
|
||||
if info.description and info.description:trim() ~= "" then
|
||||
desc = core.formspec_escape(info.description)
|
||||
if selected_pkg.description and selected_pkg.description:trim() ~= "" then
|
||||
desc = core.formspec_escape(selected_pkg.description)
|
||||
end
|
||||
|
||||
local info = core.get_content_info(selected_pkg.path)
|
||||
|
||||
local title_and_name
|
||||
if selected_pkg.type == "game" then
|
||||
title_and_name = selected_pkg.name
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue