Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ export default {
},
previewSize: {
type: Number,
default: 128,
default: 384,
},
// In case this component is used to display a file that is being uploaded
// this parameter is used to access the file upload status in the store
Expand Down Expand Up @@ -162,9 +162,9 @@ export default {
}

const previewSize = Math.ceil(this.previewSize * window.devicePixelRatio)
return generateUrl('/core/preview?fileId={fileId}&x={width}&y={height}', {
// expand width but keep a max height
return generateUrl('/core/preview?fileId={fileId}&x=-1&y={height}&a=1', {
fileId: this.id,
width: previewSize,
height: previewSize,
})
},
Expand Down Expand Up @@ -290,14 +290,18 @@ export default {
object-fit: cover;
}

.loading {
display: inline-block;
width: 100%;
margin-left: 32px;
}

.preview {
display: block;
width: 128px;
height: 128px;
display: inline-block;
height: 384px;
}
.preview-64 {
display: block;
width: 64px;
display: inline-block;
height: 64px;
}

Expand All @@ -308,7 +312,6 @@ export default {
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
margin-top: 4px;
}

&:not(.file-preview--viewer-available) {
Expand Down