mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
add show method for PlaylistEditor Class
This commit is contained in:
parent
675a59adc4
commit
d702ad938a
7 changed files with 37 additions and 11 deletions
|
@ -6,7 +6,6 @@ import dom from '../../scripts/dom';
|
|||
import './multiSelect.scss';
|
||||
import ServerConnections from '../ServerConnections';
|
||||
import alert from '../alert';
|
||||
import PlaylistEditor from '../playlisteditor/playlisteditor';
|
||||
import confirm from '../confirm/confirm';
|
||||
import itemHelper from '../itemHelper';
|
||||
import datetime from '../../scripts/datetime';
|
||||
|
@ -269,9 +268,16 @@ function showMenuForSelectedItems(e) {
|
|||
dispatchNeedsRefresh();
|
||||
break;
|
||||
case 'playlist':
|
||||
new PlaylistEditor({
|
||||
items: items,
|
||||
serverId: serverId
|
||||
import('../playlisteditor/playlisteditor').then(({ default: PlaylistEditor }) => {
|
||||
const playlistEditor = new PlaylistEditor();
|
||||
playlistEditor.show({
|
||||
items: items,
|
||||
serverId: serverId
|
||||
}).catch(() => {
|
||||
// Dialog closed
|
||||
});
|
||||
}).catch(err => {
|
||||
console.error('[AddToPlaylist] failed to load playlist editor', err);
|
||||
});
|
||||
hideSelections();
|
||||
dispatchNeedsRefresh();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue