[% IF songInfoPlayLinks; songInfoPlayLinks; END %]
[%- albumInfo = BLOCK%]
[% IF itemobj.album %]
[% item = BLOCK %]
[% itemobj.album.title || itemobj.album.name | html %][% END %]
[% PROCESS songInfoItem title = "ALBUM" %]
[% END %]
[% END %]
[% IF albumFirst; albumInfo; END %]
[% IF plugin_meta.title %]
[% item = BLOCK %][% plugin_meta.title | html %][% END %]
[% PROCESS songInfoItem title = "TITLE" %]
[% END %]
[% FOREACH role = itemobj.contributorRoles.sort %]
[% contributors = itemobj.contributors.${role} || itemobj.contributorsOfType(role) || itemobj.album.artistsForRoles(role) %]
[% IF contributors %]
[% contributorsHTML = [] %]
[% FOREACH contributor = contributors %]
[% UNLESS notarget; target = "target=\"browser\""; END %]
[%
IF contributor.id;
contributorHTMLFrag = "
$contributor.name";
ELSE;
contributorHTMLFrag = contributor.name;
END
%]
[% contributorsHTML.push(contributorHTMLFrag) %]
[% END %]
[% item = contributorsHTML.join(', ') %]
[% title = role | upper; PROCESS songInfoItem %]
[% END %]
[% END %]
[% IF plugin_meta.artist %]
[% item = BLOCK %][% plugin_meta.artist | html %][% END %]
[% PROCESS songInfoItem title = "ARTIST" %]
[% END %]
[% IF !albumFirst; albumInfo; END %]
[% IF itemobj.genres %] [% genresHTML = [] %]
[% FOREACH genre = itemobj.genres %][% UNLESS notarget; target = "target=\"browser\""; END %]
[% genreHTMLFrag = "
$genre.name" %]
[% genresHTML.push(genreHTMLFrag) %]
[% END %]
[% item = genresHTML.join(', ') %]
[% PROCESS songInfoItem title = "GENRE" %]
[% END %]
[% IF itemobj.year %]
[% item = BLOCK %]
[% itemobj.year| html %][% END %]
[% PROCESS songInfoItem title = "YEAR" %]
[% END %]
[% IF albumDuration %]
[% item = albumDuration; title = "LENGTH"; PROCESS songInfoItem %]
[% END %]
[% IF itemobj.album.compilation %]
[% item = "YES" | string; title = "COMPILATION"; PROCESS songInfoItem %]
[% END %]
[% IF itemobj.album.replay_gain.defined %]
[% item = itemobj.album.replay_gain | format('%2.2f') |html; title = "ALBUMREPLAYGAIN"; PROCESS songInfoItem %]
[% END %]