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

Add detail view buttons

This commit is contained in:
grafixeyehero 2024-09-08 20:15:20 +03:00
parent f7fcf44f94
commit 690b1fbed5
11 changed files with 692 additions and 4 deletions

View file

@ -351,12 +351,13 @@ export function getCommands(options) {
return commands;
}
function getResolveFunction(resolve, id, changed, deleted) {
function getResolveFunction(resolve, commandId, changed, deleted, itemId) {
return function () {
resolve({
command: id,
command: commandId,
updated: changed,
deleted: deleted
deleted: deleted,
itemId: itemId
});
};
}
@ -533,7 +534,7 @@ function executeCommand(item, id, options) {
getResolveFunction(resolve, id)();
break;
case 'delete':
deleteItem(apiClient, item).then(getResolveFunction(resolve, id, true, true), getResolveFunction(resolve, id));
deleteItem(apiClient, item).then(getResolveFunction(resolve, id, true, true, itemId), getResolveFunction(resolve, id));
break;
case 'share':
navigator.share({