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

Merge pull request #2514 from oddstr13/image-fill-resize

Add support for fillWidth and fillHeight
This commit is contained in:
Bill Thornton 2021-04-11 12:30:06 -04:00 committed by GitHub
commit 2c85b7806b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 11 additions and 9 deletions

View file

@ -76,12 +76,13 @@ import ServerConnections from '../ServerConnections';
return '';
}
function getImageUrl(item, width) {
function getImageUrl(item, size) {
const apiClient = ServerConnections.getApiClient(item.ServerId);
let itemId;
const options = {
maxWidth: width,
fillWidth: size,
fillHeight: size,
type: 'Primary'
};
@ -105,10 +106,11 @@ import ServerConnections from '../ServerConnections';
return null;
}
function getChannelImageUrl(item, width) {
function getChannelImageUrl(item, size) {
const apiClient = ServerConnections.getApiClient(item.ServerId);
const options = {
maxWidth: width,
fillWidth: size,
fillHeight: size,
type: 'Primary'
};