mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
stub out channel mapper popup
This commit is contained in:
parent
cce4c23fe6
commit
57ac888060
4 changed files with 93 additions and 2 deletions
74
dashboard-ui/components/channelmapper/channelmapper.js
Normal file
74
dashboard-ui/components/channelmapper/channelmapper.js
Normal file
|
@ -0,0 +1,74 @@
|
||||||
|
define(['dialogHelper', 'loading', 'connectionManager', 'globalize', 'paper-checkbox', 'emby-input', 'paper-icon-button-light', 'emby-select', 'emby-button'],
|
||||||
|
function (dialogHelper, loading, connectionManager, globalize) {
|
||||||
|
|
||||||
|
var currentServerId;
|
||||||
|
|
||||||
|
function getEditorHtml() {
|
||||||
|
|
||||||
|
var html = '';
|
||||||
|
|
||||||
|
html += '<div class="dialogContent">';
|
||||||
|
html += '<div class="dialogContentInner centeredContent">';
|
||||||
|
html += 'coming soon';
|
||||||
|
html += '</div>';
|
||||||
|
html += '</div>';
|
||||||
|
|
||||||
|
return html;
|
||||||
|
}
|
||||||
|
|
||||||
|
function initEditor(content, items) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
return function () {
|
||||||
|
|
||||||
|
var self = this;
|
||||||
|
|
||||||
|
self.show = function (options) {
|
||||||
|
|
||||||
|
var items = options.items || {};
|
||||||
|
currentServerId = options.serverId;
|
||||||
|
|
||||||
|
var dialogOptions = {
|
||||||
|
removeOnClose: true
|
||||||
|
};
|
||||||
|
|
||||||
|
dialogOptions.size = 'small';
|
||||||
|
|
||||||
|
var dlg = dialogHelper.createDialog(dialogOptions);
|
||||||
|
|
||||||
|
dlg.classList.add('formDialog');
|
||||||
|
dlg.classList.add('ui-body-a');
|
||||||
|
dlg.classList.add('background-theme-a');
|
||||||
|
|
||||||
|
var html = '';
|
||||||
|
var title = globalize.translate('MapChannels');
|
||||||
|
|
||||||
|
html += '<div class="dialogHeader" style="margin:0 0 2em;">';
|
||||||
|
html += '<button is="paper-icon-button-light" class="btnCancel" tabindex="-1"><iron-icon icon="nav:arrow-back"></iron-icon></button>';
|
||||||
|
html += '<div class="dialogHeaderTitle">';
|
||||||
|
html += title;
|
||||||
|
html += '</div>';
|
||||||
|
|
||||||
|
html += '</div>';
|
||||||
|
|
||||||
|
html += getEditorHtml();
|
||||||
|
|
||||||
|
dlg.innerHTML = html;
|
||||||
|
document.body.appendChild(dlg);
|
||||||
|
|
||||||
|
initEditor(dlg, items);
|
||||||
|
|
||||||
|
dlg.querySelector('.btnCancel').addEventListener('click', function () {
|
||||||
|
|
||||||
|
dialogHelper.close(dlg);
|
||||||
|
});
|
||||||
|
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
|
||||||
|
dlg.addEventListener('close', resolve);
|
||||||
|
dialogHelper.open(dlg);
|
||||||
|
});
|
||||||
|
};
|
||||||
|
};
|
||||||
|
});
|
|
@ -175,3 +175,8 @@ h1, h1 a {
|
||||||
.alphabetPicker {
|
.alphabetPicker {
|
||||||
right: 5px !important;
|
right: 5px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.alphaPickerButton.selected {
|
||||||
|
background-color: transparent !important;
|
||||||
|
color: #52B54B !important;
|
||||||
|
}
|
||||||
|
|
|
@ -242,7 +242,9 @@
|
||||||
});
|
});
|
||||||
|
|
||||||
Dashboard.hideLoadingMsg();
|
Dashboard.hideLoadingMsg();
|
||||||
itemsContainer.dispatchEvent(new CustomEvent('timercancelled', {}));
|
itemsContainer.dispatchEvent(new CustomEvent('timercancelled', {
|
||||||
|
bubbles: true
|
||||||
|
}));
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -361,7 +361,7 @@
|
||||||
deleteProvider(page, id);
|
deleteProvider(page, id);
|
||||||
break;
|
break;
|
||||||
case 'map':
|
case 'map':
|
||||||
alert('coming soon');
|
mapChannels(page, id);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
@ -371,6 +371,16 @@
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function mapChannels(page, providerId) {
|
||||||
|
|
||||||
|
require(['components/channelmapper/channelmapper'], function (channelmapper) {
|
||||||
|
new channelmapper().show({
|
||||||
|
serverId: ApiClient.serverInfo().Id,
|
||||||
|
providerId: providerId
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
function deleteProvider(page, id) {
|
function deleteProvider(page, id) {
|
||||||
|
|
||||||
var message = Globalize.translate('MessageConfirmDeleteGuideProvider');
|
var message = Globalize.translate('MessageConfirmDeleteGuideProvider');
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue