mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Change icon tag to span
This commit is contained in:
parent
ad5c7ec3b4
commit
6fe9a8c3e9
120 changed files with 439 additions and 439 deletions
|
@ -305,14 +305,14 @@ define(["datetime", "events", "itemHelper", "serverNotifications", "dom", "globa
|
|||
var btnCssClass = session.ServerId && session.NowPlayingItem && session.SupportsRemoteControl ? "" : " hide";
|
||||
const playIcon = session.PlayState.IsPaused ? 'pause' : 'play_arrow';
|
||||
|
||||
html += '<button is="paper-icon-button-light" class="sessionCardButton btnSessionPlayPause paper-icon-button-light ' + btnCssClass + '"><i class="material-icons ' + playIcon + '"></i></button>';
|
||||
html += '<button is="paper-icon-button-light" class="sessionCardButton btnSessionStop paper-icon-button-light ' + btnCssClass + '"><i class="material-icons stop"></i></button>';
|
||||
html += '<button is="paper-icon-button-light" class="sessionCardButton btnSessionPlayPause paper-icon-button-light ' + btnCssClass + '"><span class="material-icons ' + playIcon + '"></span></button>';
|
||||
html += '<button is="paper-icon-button-light" class="sessionCardButton btnSessionStop paper-icon-button-light ' + btnCssClass + '"><span class="material-icons stop"></span></button>';
|
||||
|
||||
btnCssClass = session.TranscodingInfo && session.TranscodingInfo.TranscodeReasons && session.TranscodingInfo.TranscodeReasons.length ? "" : " hide";
|
||||
html += '<button is="paper-icon-button-light" class="sessionCardButton btnSessionInfo paper-icon-button-light ' + btnCssClass + '" title="' + globalize.translate("ViewPlaybackInfo") + '"><i class="material-icons info"></i></button>';
|
||||
html += '<button is="paper-icon-button-light" class="sessionCardButton btnSessionInfo paper-icon-button-light ' + btnCssClass + '" title="' + globalize.translate("ViewPlaybackInfo") + '"><span class="material-icons info"></span></button>';
|
||||
|
||||
btnCssClass = session.ServerId && -1 !== session.SupportedCommands.indexOf("DisplayMessage") && session.DeviceId !== connectionManager.deviceId() ? "" : " hide";
|
||||
html += '<button is="paper-icon-button-light" class="sessionCardButton btnSessionSendMessage paper-icon-button-light ' + btnCssClass + '" title="' + globalize.translate("SendMessage") + '"><i class="material-icons message"></i></button>';
|
||||
html += '<button is="paper-icon-button-light" class="sessionCardButton btnSessionSendMessage paper-icon-button-light ' + btnCssClass + '" title="' + globalize.translate("SendMessage") + '"><span class="material-icons message"></span></button>';
|
||||
html += "</div>";
|
||||
|
||||
html += '<div class="sessionNowPlayingStreamInfo" style="padding:.5em 0 1em;">';
|
||||
|
@ -368,7 +368,7 @@ define(["datetime", "events", "itemHelper", "serverNotifications", "dom", "globa
|
|||
html += progress + "%";
|
||||
html += "</progress>";
|
||||
html += "<span style='color:#00a4dc;margin-left:5px;margin-right:5px;'>" + progress + "%</span>";
|
||||
html += '<button type="button" is="paper-icon-button-light" title="' + globalize.translate("ButtonStop") + '" onclick="DashboardPage.stopTask(this, \'' + task.Id + '\');" class="autoSize"><i class="material-icons cancel"></i></button>';
|
||||
html += '<button type="button" is="paper-icon-button-light" title="' + globalize.translate("ButtonStop") + '" onclick="DashboardPage.stopTask(this, \'' + task.Id + '\');" class="autoSize"><span class="material-icons cancel"></span></button>';
|
||||
} else if (task.State === "Cancelling") {
|
||||
html += '<span style="color:#cc0000;">' + globalize.translate("LabelStopping") + "</span>";
|
||||
}
|
||||
|
@ -573,7 +573,7 @@ define(["datetime", "events", "itemHelper", "serverNotifications", "dom", "globa
|
|||
|
||||
let icons = ["play_arrow", "pause"];
|
||||
if (session.PlayState && session.PlayState.IsPaused) icons = icons.reverse();
|
||||
btnSessionPlayPause.querySelector("i").classList.replace(icons[0], icons[1]);
|
||||
btnSessionPlayPause.querySelector(".material-icons").classList.replace(icons[0], icons[1]);
|
||||
|
||||
row.querySelector(".sessionNowPlayingStreamInfo").innerHTML = DashboardPage.getSessionNowPlayingStreamInfo(session);
|
||||
row.querySelector(".sessionNowPlayingTime").innerHTML = DashboardPage.getSessionNowPlayingTime(session);
|
||||
|
|
|
@ -31,14 +31,14 @@ define(["loading", "libraryMenu", "globalize", "listViewStyle", "emby-button"],
|
|||
}
|
||||
itemHtml += '<a class="listItem listItem-border" is="emby-linkbutton" data-ripple="false" href="notificationsetting.html?type=' + notification.Type + '">';
|
||||
if (notification.Enabled) {
|
||||
itemHtml += '<i class="listItemIcon material-icons notifications_active"></i>';
|
||||
itemHtml += '<span class="listItemIcon material-icons notifications_active"></span>';
|
||||
} else {
|
||||
itemHtml += '<i class="listItemIcon material-icons notifications_off" style="background-color:#999;"></i>';
|
||||
itemHtml += '<span class="listItemIcon material-icons notifications_off" style="background-color:#999;"></span>';
|
||||
}
|
||||
itemHtml += '<div class="listItemBody">';
|
||||
itemHtml += '<div class="listItemBodyText">' + notification.Name + "</div>";
|
||||
itemHtml += "</div>";
|
||||
itemHtml += '<button type="button" is="paper-icon-button-light"><i class="material-icons mode_edit"></i></button>';
|
||||
itemHtml += '<button type="button" is="paper-icon-button-light"><span class="material-icons mode_edit"></span></button>';
|
||||
itemHtml += "</a>";
|
||||
return itemHtml;
|
||||
}).join("");
|
||||
|
|
|
@ -103,7 +103,7 @@ define(["loading", "libraryMenu", "globalize", "cardStyle", "emby-button", "emby
|
|||
html += '<div class="cardImage coveredImage" style="background-image:url(\'' + plugin.thumbImage + "');\">";
|
||||
html += "</div>";
|
||||
} else {
|
||||
html += '<i class="cardImageIcon material-icons folder"></i>';
|
||||
html += '<span class="cardImageIcon material-icons folder"></span>';
|
||||
}
|
||||
|
||||
html += "</a>";
|
||||
|
|
|
@ -47,14 +47,14 @@ define(["loading", "libraryMenu", "dom", "globalize", "cardStyle", "emby-button"
|
|||
html += '<div class="cardImage coveredImage" style="background-image:url(\'' + plugin.ImageUrl + "');\">";
|
||||
html += "</div>";
|
||||
} else {
|
||||
html += '<i class="cardImageIcon material-icons folder"></i>';
|
||||
html += '<span class="cardImageIcon material-icons folder"></span>';
|
||||
}
|
||||
|
||||
html += configPageUrl ? "</a>" : "</div>";
|
||||
html += "</div>";
|
||||
html += '<div class="cardFooter">';
|
||||
html += '<div style="text-align:right; float:right;padding-top:5px;">';
|
||||
html += '<button type="button" is="paper-icon-button-light" class="btnCardMenu autoSize"><i class="material-icons more_horiz"></i></button>';
|
||||
html += '<button type="button" is="paper-icon-button-light" class="btnCardMenu autoSize"><span class="material-icons more_horiz"></span></button>';
|
||||
html += "</div>";
|
||||
html += "<div class='cardText'>";
|
||||
html += configPage ? configPage.DisplayName || plugin.Name : plugin.Name;
|
||||
|
|
|
@ -49,7 +49,7 @@ define(["jQuery", "loading", "datetime", "dom", "globalize", "emby-input", "emby
|
|||
var trigger = task.Triggers[i];
|
||||
|
||||
html += '<div class="listItem listItem-border">';
|
||||
html += '<i class="material-icons listItemIcon schedule"></i>';
|
||||
html += '<span class="material-icons listItemIcon schedule"></span>';
|
||||
if (trigger.MaxRuntimeMs) {
|
||||
html += '<div class="listItemBody two-line">';
|
||||
} else {
|
||||
|
@ -68,7 +68,7 @@ define(["jQuery", "loading", "datetime", "dom", "globalize", "emby-input", "emby
|
|||
}
|
||||
|
||||
html += "</div>";
|
||||
html += '<button class="btnDeleteTrigger" data-index="' + i + '" type="button" is="paper-icon-button-light" title="' + globalize.translate("ButtonDelete") + '"><i class="material-icons delete"></i></button>';
|
||||
html += '<button class="btnDeleteTrigger" data-index="' + i + '" type="button" is="paper-icon-button-light" title="' + globalize.translate("ButtonDelete") + '"><span class="material-icons delete"></span></button>';
|
||||
html += "</div>";
|
||||
}
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@ define(["jQuery", "loading", "events", "globalize", "serverNotifications", "date
|
|||
}
|
||||
html += '<div class="listItem listItem-border scheduledTaskPaperIconItem" data-status="' + task.State + '">';
|
||||
html += "<a is='emby-linkbutton' style='margin:0;padding:0;' class='clearLink listItemIconContainer' href='scheduledtask.html?id=" + task.Id + "'>";
|
||||
html += '<i class="material-icons listItemIcon schedule"></i>';
|
||||
html += '<span class="material-icons listItemIcon schedule"></span>';
|
||||
html += "</a>";
|
||||
html += '<div class="listItemBody two-line">';
|
||||
html += "<a class='clearLink' style='margin:0;padding:0;display:block;text-align:left;' is='emby-linkbutton' href='scheduledtask.html?id=" + task.Id + "'>";
|
||||
|
@ -49,9 +49,9 @@ define(["jQuery", "loading", "events", "globalize", "serverNotifications", "date
|
|||
html += "</a>";
|
||||
html += "</div>";
|
||||
if (task.State === "Running") {
|
||||
html += '<button type="button" is="paper-icon-button-light" id="btnTask' + task.Id + '" class="btnStopTask" data-taskid="' + task.Id + '" title="' + globalize.translate("ButtonStop") + '"><i class="material-icons stop"></i></button>';
|
||||
html += '<button type="button" is="paper-icon-button-light" id="btnTask' + task.Id + '" class="btnStopTask" data-taskid="' + task.Id + '" title="' + globalize.translate("ButtonStop") + '"><span class="material-icons stop"></span></button>';
|
||||
} else if (task.State === "Idle") {
|
||||
html += '<button type="button" is="paper-icon-button-light" id="btnTask' + task.Id + '" class="btnStartTask" data-taskid="' + task.Id + '" title="' + globalize.translate("ButtonStart") + '"><i class="material-icons play_arrow"></i></button>';
|
||||
html += '<button type="button" is="paper-icon-button-light" id="btnTask' + task.Id + '" class="btnStartTask" data-taskid="' + task.Id + '" title="' + globalize.translate("ButtonStart") + '"><span class="material-icons play_arrow"></span></button>';
|
||||
}
|
||||
html += "</div>";
|
||||
}
|
||||
|
@ -94,7 +94,7 @@ define(["jQuery", "loading", "events", "globalize", "serverNotifications", "date
|
|||
}
|
||||
|
||||
function setTaskButtonIcon(button, icon) {
|
||||
var inner = button.querySelector("i");
|
||||
var inner = button.querySelector(".material-icons");
|
||||
inner.classList.remove("stop", "play_arrow");
|
||||
inner.classList.add(icon);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue