Module:Infobox interval region: Difference between revisions

No edit summary
No edit summary
Line 34: Line 34:
})
})
if equave == nil or equave == "" then
table.insert(data, {
"Equave",
"[[" .. equave .. "]]"
})
else
table.insert(data, {
"Equave",
"[[2/1]]"
})
end


Line 72: Line 61:
end
end
table.insert(data, {
table.insert(data, {
string.format("<div style=\"margin-top: 0.6em;\"><b>%s</b></div>", "section_header")
string.format("<div style=\"margin-top: 0.6em;\"><b>%s</b></div>", "JI intervals")
})
})
if ji3 ~= nil and ji3 ~= "" then
table.insert(data, {
"3-limit",
ji3
})
end
if ji5 ~= nil and ji5 ~= "" then
table.insert(data, {
"5-limit",
ji5
})
end
if ji7 ~= nil and ji7 ~= "" then
table.insert(data, {
"7-limit",
ji7
})
end
if ji11 ~= nil and ji11 ~= "" then
table.insert(data, {
"11-limit",
ji11
})
end
if ji13 ~= nil and ji13 ~= "" then
table.insert(data, {
"13-limit",
ji13
})
end
table.insert(data, {
string.format("<div style=\"margin-top: 0.6em;\"><b>%s</b></div>", "Scale info")
})
if moses ~= nil and moses ~= "" then
table.insert(data, {
"[[MOS]]es",
moses
})
end
if equave == nil or equave == "" then
table.insert(data, {
"Equave",
"[[" .. equave .. "]]"
})
else
table.insert(data, {
"Equave",
"[[2/1]]"
})
end
local result = infobox.build(
local result = infobox.build(
   "Interval&nbsp;region",
   "Interval&nbsp;region",
data
data
)
)
return frame:preprocess(debugg == true and "<pre>" .. result .. "</pre>" or result)
return frame:preprocess(debugg == true and "<pre>" .. result .. "</pre>" or result)