1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

Merge pull request #3160 from thornbill/fix-list-item-encoding

This commit is contained in:
Bill Thornton 2021-11-13 01:04:31 -05:00 committed by GitHub
commit 0fa6dfa611
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -133,21 +133,28 @@ import ServerConnections from '../ServerConnections';
continue; continue;
} }
let elem;
if (i === 0) { if (i === 0) {
if (isLargeStyle) { if (isLargeStyle) {
html += `<${largeTitleTagName} class="listItemBodyText">`; elem = document.createElement(largeTitleTagName);
} else { } else {
html += '<div class="listItemBodyText">'; elem = document.createElement('div');
} }
} else { } else {
html += '<div class="secondary listItemBodyText">'; elem = document.createElement('div');
elem.classList.add('secondary');
} }
html += (textlines[i] || '&nbsp;');
if (i === 0 && isLargeStyle) { elem.classList.add('listItemBodyText');
html += `</${largeTitleTagName}>`;
if (textlines[i]) {
elem.innerText = textlines[i];
} else { } else {
html += '</div>'; elem.innerHTML = '&nbsp;';
} }
html += elem.outerHTML;
} }
return html; return html;