Module:Infobox regtemp: Difference between revisions

m Formatting for the mapping, using the character directly
ArrowHead294 (talk | contribs)
mNo edit summary
Line 2: Line 2:
local u = require("Module:Utils")
local u = require("Module:Utils")
local infobox = require("Module:Infobox")
local infobox = require("Module:Infobox")
local yesno = require("Module:Yesno")


function p.infobox_RT(frame)
function p.infobox_RT(frame)
Line 32: Line 33:
local comp2 = frame.args["comp2"]
local comp2 = frame.args["comp2"]
local acc2 = frame.args["acc2"]
local acc2 = frame.args["acc2"]
local debugg = frame.args["debug"]
local data = {}
local data = {}
Line 124: Line 126:
table.insert(data, {
table.insert(data, {
"Edo join",
"Edo join",
"[[" .. edo_first .. "ed" .. equave_letter .. "|" .. edo_first .. "]] & [[" .. edo_second .. "ed" .. equave_letter .. "|" .. edo_second .. "]]"
"[[" .. edo_first .. "ed" .. equave_letter .. "|" .. edo_first .. "]] & [[" .. edo_second .. "ed" .. equave_letter .. "|" .. edo_second .. "]]"
})
})


table.insert(data, {
table.insert(data, {
"Generator ([[" .. method .. "]])",
"Generator ([[" .. method .. "]])",
"~" .. genfrac .. " = " .. tuning .. "c"
"~" .. genfrac .. " = " .. tuning .. "{{c}}"
})
})


Line 170: Line 172:
local string2 = "(" .. limit1 .. oddlim .. comp1 .. " notes"
local string2 = "(" .. limit1 .. oddlim .. comp1 .. " notes"
if limit2 ~= "0" then
if limit2 ~= "0" then
string1 = string1 .. "; <br> (" .. limit2 .. oddlim .. acc2 .. "c"
string1 = string1 .. ";<br />(" .. limit2 .. oddlim .. acc2 .. "c"
string2 = string2 .. "; <br> (" .. limit2 .. oddlim .. comp2 .. " notes"
string2 = string2 .. ";<br />(" .. limit2 .. oddlim .. comp2 .. " notes"
end
end


Line 189: Line 191:
)
)
return result
return frame:preprocess(debugg == true and "<pre>" .. result .. "</pre>" or result)
end
end