Bugfix: conflicting File object with native JS

Cleanup: Stores and tooltips
This commit is contained in:
djmaze 2021-02-17 14:40:21 +01:00
parent 1df2e00862
commit db0d03db83
43 changed files with 204 additions and 295 deletions

View file

@ -10,7 +10,7 @@ import { serverRequestRaw } from 'Common/Links';
import FolderStore from 'Stores/User/Folder';
import { File } from 'Common/File';
import { FileInfo } from 'Common/File';
import { AttachmentCollectionModel } from 'Model/AttachmentCollection';
import { EmailCollectionModel } from 'Model/EmailCollection';
import { AbstractModel } from 'Knoin/AbstractModel';
@ -85,7 +85,7 @@ export class MessageModel extends AbstractModel {
this.threads = ko.observableArray();
this.addComputables({
attachmentIconClass: () => File.getCombinedIconClass(this.hasAttachments() ? this.attachmentsSpecData() : []),
attachmentIconClass: () => FileInfo.getCombinedIconClass(this.hasAttachments() ? this.attachmentsSpecData() : []),
threadsLen: () => this.threads.length,
isImportant: () => MessagePriority.High === this.priority(),
});
@ -169,7 +169,7 @@ export class MessageModel extends AbstractModel {
* @returns {string}
*/
friendlySize() {
return File.friendlySize(this.size());
return FileInfo.friendlySize(this.size());
}
computeSenderEmail() {