From: E.Smith <31170571+azlm8t@users.noreply.github.com> Date: Wed, 22 Nov 2017 10:54:03 +0000 (+0000) Subject: ui: Don't display subtitle if it is same as summary. (#4594). X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d7cab04a8a7259d82d72a56bef7b8209ebf1a848;p=thirdparty%2Ftvheadend.git ui: Don't display subtitle if it is same as summary. (#4594). Some OTA don't have a separate sub-title and description/summary so if they are the same then don't display it as a sub-title since the description is often long. Issue: #4594. --- diff --git a/src/webui/static/app/dvr.js b/src/webui/static/app/dvr.js index 2bacdb20f..a6b385059 100644 --- a/src/webui/static/app/dvr.js +++ b/src/webui/static/app/dvr.js @@ -53,7 +53,7 @@ tvheadend.dvrDetails = function(uuid) { displayTitle += " (" + copyright_year + ")"; if (title) content += '
' + displayTitle + '
'; - if (subtitle) + if (subtitle && (!desc || (desc && subtitle != desc))) content += '
' + subtitle + '
'; if (episode) content += '
' + episode + '
'; diff --git a/src/webui/static/app/epg.js b/src/webui/static/app/epg.js index 5b39ba9f2..f07418989 100644 --- a/src/webui/static/app/epg.js +++ b/src/webui/static/app/epg.js @@ -107,7 +107,9 @@ tvheadend.epgDetails = function(event) { if (icons) content += '
' + icons + '
'; content += '
' + event.title; - if (event.subtitle) + // Some OTA have the same subtitle and summary so don't display subtitle + // since summary can be long. + if (event.subtitle && (!event.summary || (event.summary && event.subtitle != event.summary))) content += " : " + event.subtitle; if (event.copyright_year) content += " (" + event.copyright_year + ")";