Better formatting for setting tooltip

Using inline instead of multiples lines to add tooltip attached to setting into formspec

Co-authored-by: SX <50966843+S-S-X@users.noreply.github.com>
This commit is contained in:
Athozus 2023-09-14 20:34:30 +02:00 committed by GitHub
parent 6b8ce291a2
commit e1ee837a48
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -62,9 +62,7 @@ function mail.show_settings(name)
field_default .. [[]
]]
if data.tooltip then
formspec = formspec .. [[
tooltip[]] .. setting .. ";" .. data.tooltip .. [[]
]]
formspec = formspec .. "tooltip[" .. setting .. ";" .. data.tooltip .. "]"
end
if data.dataset then
local formatted_dataset = table.copy(data.dataset)