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

fix layout quirks

This commit is contained in:
Luke Pulverenti 2016-08-09 01:10:17 -04:00
parent 782d50532d
commit e5525cd630
2 changed files with 11 additions and 7 deletions

View file

@ -541,7 +541,7 @@
} else { } else {
btnCast.querySelector('i').innerHTML = 'cast-connected'; btnCast.querySelector('i').innerHTML = 'cast_connected';
btnCast.classList.add('btnActiveCast'); btnCast.classList.add('btnActiveCast');
context.querySelector('.nowPlayingSelectedPlayer').innerHTML = info.deviceName || info.name; context.querySelector('.nowPlayingSelectedPlayer').innerHTML = info.deviceName || info.name;
} }

View file

@ -121,7 +121,7 @@
function showActivePlayerMenu(playerInfo) { function showActivePlayerMenu(playerInfo) {
require(['dialogHelper', 'emby-checkbox', 'emby-button'], function (dialogHelper) { require(['dialogHelper', 'dialog', 'emby-checkbox', 'emby-button'], function (dialogHelper) {
showActivePlayerMenuInternal(dialogHelper, playerInfo); showActivePlayerMenuInternal(dialogHelper, playerInfo);
}); });
} }
@ -141,11 +141,14 @@
var dlg = dialogHelper.createDialog(dialogOptions); var dlg = dialogHelper.createDialog(dialogOptions);
dlg.classList.add('promptDialog');
html += '<div class="promptDialogContent">';
html += '<h2>'; html += '<h2>';
html += (playerInfo.deviceName || playerInfo.name); html += (playerInfo.deviceName || playerInfo.name);
html += '</h2>'; html += '</h2>';
html += '<div style="padding:0 2em;">'; html += '<div>';
if (playerInfo.supportedCommands.indexOf('DisplayContent') != -1) { if (playerInfo.supportedCommands.indexOf('DisplayContent') != -1) {
@ -158,17 +161,18 @@
html += '</div>'; html += '</div>';
html += '<div class="buttons">'; html += '<div class="promptDialogButtons">';
// On small layouts papepr dialog doesn't respond very well. this button isn't that important here anyway. // On small layouts papepr dialog doesn't respond very well. this button isn't that important here anyway.
if (screen.availWidth >= 600) { if (screen.availWidth >= 600) {
html += '<button is="emby-button" type="button" class="btnRemoteControl">' + Globalize.translate('ButtonRemoteControl') + '</button>'; html += '<button is="emby-button" type="button" class="btnRemoteControl promptDialogButton">' + Globalize.translate('ButtonRemoteControl') + '</button>';
} }
html += '<button is="emby-button" type="button" class="btnDisconnect">' + Globalize.translate('ButtonDisconnect') + '</button>'; html += '<button is="emby-button" type="button" class="btnDisconnect promptDialogButton">' + Globalize.translate('ButtonDisconnect') + '</button>';
html += '<button is="emby-button" type="button" class="btnCancel">' + Globalize.translate('ButtonCancel') + '</button>'; html += '<button is="emby-button" type="button" class="btnCancel promptDialogButton">' + Globalize.translate('ButtonCancel') + '</button>';
html += '</div>'; html += '</div>';
html += '</div>';
dlg.innerHTML = html; dlg.innerHTML = html;
document.body.appendChild(dlg); document.body.appendChild(dlg);