メニューを切り替える
Toggle preferences menu
個人設定を切り替える
ログインしていません
編集を行うと、IPアドレスが公開されます。

「モジュール:Tracklist」の版間の差分

提供: MONACA Wiki
編集の要約なし
編集の要約なし
238行目: 238行目:
function (a, b) return a[1] < b[1] end
function (a, b) return a[1] < b[1] end
)
)
if md then
for k, v in ipairs(trackA) do
local color = (v[1] % 2 == 0) and '#f7f7f7' or '#fff' --偶数/奇数で別色指定
result = result .. '<tr itemprop="track" itemscope itemtype="http://schema.org/MusicRecording" style="background-color:' .. color .. '; vertical-align:top;"><td style="padding-left:0.5em; text-align:right;"><span itemprop="position">' .. (v['#'] or v[1]) .. '</span>.</td><td>' .. (v.title and ('「<span itemprop="name">' .. v.title .. '</span>」') or 'タイトルなし') .. (v.note and ('<small>(' .. v.note .. ')</small>') or '') .. '</td>' .. writer(v) .. lyrics(v) .. music(v) .. arranger(v) ..  extra(v) .. length(v) .. '</tr>'
end
else
for k, v in ipairs(trackA) do
local color = (v[1] % 2 == 0) and '#f7f7f7' or '#fff'
result = result .. '<tr style="background-color:' .. color .. '; vertical-align:top;"><td style="padding-left:0.5em; text-align:right;">' .. (v['#'] or v[1]) .. '.</td><td>' .. (v.title and ('「' .. v.title .. '」') or 'タイトルなし') .. (v.note and ('<small>(' .. v.note .. ')</small>') or '') .. '</td>' .. writer(v) .. lyrics(v) .. music(v) .. arranger(v) ..  extra(v) .. length(v) .. '</tr>'
end
end
return result
return result
end
end