mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-07-27 18:12:29 +08:00
chore(ts/Fattachment): add getContentLength, since contentLength is private
This commit is contained in:
parent
99e520cbbc
commit
5d4dc91cc3
@ -61,6 +61,10 @@ class FAttachment {
|
|||||||
return this.ownerId;
|
return this.ownerId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
getContentLength() {
|
||||||
|
return this.contentLength;
|
||||||
|
}
|
||||||
|
|
||||||
getUtcDateScheduledForErasureSince() {
|
getUtcDateScheduledForErasureSince() {
|
||||||
return this.utcDateScheduledForErasureSince;
|
return this.utcDateScheduledForErasureSince;
|
||||||
}
|
}
|
||||||
|
@ -164,7 +164,7 @@ export default class AttachmentDetailWidget extends BasicWidget {
|
|||||||
$deletionWarning.hide();
|
$deletionWarning.hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
this.$wrapper.find(".attachment-details").text(t("attachment_detail_2.role_and_size", { role: this.attachment.role, size: utils.formatSize(this.attachment.contentLength) }));
|
this.$wrapper.find(".attachment-details").text(t("attachment_detail_2.role_and_size", { role: this.attachment.role, size: utils.formatSize(this.attachment.getContentLength()) }));
|
||||||
this.$wrapper.find(".attachment-actions-container").append(this.attachmentActionsWidget.render());
|
this.$wrapper.find(".attachment-actions-container").append(this.attachmentActionsWidget.render());
|
||||||
|
|
||||||
const { $renderedContent } = await contentRenderer.getRenderedContent(this.attachment, { imageHasZoom: this.isFullDetail });
|
const { $renderedContent } = await contentRenderer.getRenderedContent(this.attachment, { imageHasZoom: this.isFullDetail });
|
||||||
|
Loading…
x
Reference in New Issue
Block a user