mirror of
https://github.com/the-djmaze/snappymail.git
synced 2025-02-24 06:47:05 +08:00
Improved decrypted attachments view
This commit is contained in:
parent
ecc669b734
commit
85f9209176
2 changed files with 6 additions and 6 deletions
|
@ -33,6 +33,7 @@ import { SMAudio } from 'Common/Audio';
|
|||
|
||||
import { i18n } from 'Common/Translator';
|
||||
import { attachmentDownload } from 'Common/Links';
|
||||
import { FileInfo } from 'Common/File';
|
||||
|
||||
import { MessageFlagsCache } from 'Common/Cache';
|
||||
|
||||
|
@ -77,13 +78,12 @@ const
|
|||
// if (cd && 'attachment' === cd.value) {
|
||||
let attachment = new AttachmentModel;
|
||||
attachment.mimeType = type.value;
|
||||
attachment.fileName = (type.name || (cd && cd.params.filename));
|
||||
attachment.fileName = type.name || (cd && cd.params.filename) || '';
|
||||
attachment.fileNameExt = attachment.fileName.replace(/^.+(\.[a-z]+)$/, '$1');
|
||||
attachment.fileType = FileInfo.getType('', type.value);
|
||||
attachment.url = part.dataUrl;
|
||||
attachment.friendlySize = FileInfo.friendlySize(part.body.length);
|
||||
/*
|
||||
attachment.fileNameExt = '';
|
||||
attachment.fileType = FileType.Unknown;
|
||||
attachment.friendlySize = '';
|
||||
attachment.isLinked(false);
|
||||
attachment.isThumbnail = false;
|
||||
attachment.contentLocation = '';
|
||||
attachment.download = '';
|
||||
|
|
|
@ -241,7 +241,7 @@
|
|||
<div class="attachmentSize" data-bind="text: friendlySize"></div>
|
||||
</div>
|
||||
<div class="checkboxAttachment fontastic"
|
||||
data-bind="text: checked() ? '☑' : '☐',
|
||||
data-bind="visible: download, text: checked() ? '☑' : '☐',
|
||||
click: function () { checked(!checked()); return false }"></div>
|
||||
</li>
|
||||
</ul>
|
||||
|
|
Loading…
Reference in a new issue