Module:Infobox interval: Difference between revisions

Plumtree (talk | contribs)
m In-browser sound generation (no, you won't hear anything without custom JS from User:Plumtree/common.js)
Plumtree (talk | contribs)
mNo edit summary
Line 230: Line 230:
'[[File:' .. sound .. '|270px]]<br/><small>[[:File:' .. sound .. '|[sound info]]]</small>'
'[[File:' .. sound .. '|270px]]<br/><small>[[:File:' .. sound .. '|[sound info]]]</small>'
})
})
else
elseif rational then
local hz = rat.hz(ratio)
local hz = rat.hz(ratio)
table.insert(infobox_data, {
if hz > 0 then
frame:expandTemplate{
table.insert(infobox_data, {
title = 'User:Plumtree/Interval Sound',
frame:expandTemplate{
args = { Frequency=tostring(hz), Timbre='violin' }
title = 'User:Plumtree/Interval Sound',
}
args = { Frequency=tostring(hz), Timbre='violin' }
})
}
})
end
end
end