@social-mail/social-mail-client 1.0.29 → 1.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/admin/AdminAppIndex.pack.js +57 -9
- package/dist/admin/AdminAppIndex.pack.js.map +1 -1
- package/dist/admin/AdminAppIndex.pack.min.js +4 -4
- package/dist/admin/AdminAppIndex.pack.min.js.map +1 -1
- package/dist/common/controls/html/InlineHtmlEditorWithToolbar.js +1 -0
- package/dist/common/controls/html/InlineHtmlEditorWithToolbar.js.map +1 -1
- package/dist/services/files/LocalFileService.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/web/AppIndex.pack.js +57 -9
- package/dist/web/AppIndex.pack.js.map +1 -1
- package/dist/web/AppIndex.pack.min.js +4 -4
- package/dist/web/AppIndex.pack.min.js.map +1 -1
- package/dist/web/page/mails/ComposeMailPage.js +3 -1
- package/dist/web/page/mails/ComposeMailPage.js.map +1 -1
- package/dist/web/page/mails/ConversationPage.js +5 -6
- package/dist/web/page/mails/ConversationPage.js.map +1 -1
- package/dist/web/page/mails/service/ConversationService.js +48 -2
- package/dist/web/page/mails/service/ConversationService.js.map +1 -1
- package/package.json +1 -1
- package/src/common/controls/html/InlineHtmlEditorWithToolbar.tsx +1 -1
- package/src/services/files/LocalFileService.tsx +1 -0
- package/src/web/page/mails/ComposeMailPage.tsx +3 -1
- package/src/web/page/mails/ConversationPage.tsx +2 -2
- package/src/web/page/mails/service/ConversationService.tsx +50 -2
|
@@ -19197,10 +19197,10 @@ System.register(["@web-atoms/core/dist/core/XNode", "./dom/StyleHelper"], functi
|
|
|
19197
19197
|
|
|
19198
19198
|
AmdLoader.instance.setup("@web-atoms/email-dom/dist/DomToString");
|
|
19199
19199
|
|
|
19200
|
-
System.register(["tslib", "@web-atoms/core/dist/di/DISingleton", "@web-atoms/core/dist/di/Inject", "../../../../services/EntityService", "../../../../model/model", "../../../../common/Sql", "@web-atoms/email-dom/dist/DomToString", "@web-atoms/core/dist/core/XNode"], function (_export, _context) {
|
|
19200
|
+
System.register(["tslib", "@web-atoms/core/dist/di/DISingleton", "@web-atoms/core/dist/di/Inject", "../../../../services/EntityService", "../../../../model/model", "../../../../common/Sql", "@web-atoms/email-dom/dist/DomToString", "@web-atoms/core/dist/core/XNode", "@web-atoms/core/dist/web/controls/AtomControl", "@web-atoms/core/dist/web/core/AtomUI"], function (_export, _context) {
|
|
19201
19201
|
"use strict";
|
|
19202
19202
|
|
|
19203
|
-
var __awaiter, __decorate, __metadata, DISingleton, Inject, EntityService, MailboxThreadEmail, Sql, DomToString, XNode, ConversationService;
|
|
19203
|
+
var __awaiter, __decorate, __metadata, DISingleton, Inject, EntityService, MailboxThreadEmail, Sql, DomToString, XNode, AtomControl, descendentElementIterator, renderMail, ConversationService;
|
|
19204
19204
|
return {
|
|
19205
19205
|
setters: [function (_tslib) {
|
|
19206
19206
|
__awaiter = _tslib.__awaiter;
|
|
@@ -19220,8 +19220,49 @@ System.register(["tslib", "@web-atoms/core/dist/di/DISingleton", "@web-atoms/cor
|
|
|
19220
19220
|
DomToString = _webAtomsEmailDomDistDomToString.default;
|
|
19221
19221
|
}, function (_webAtomsCoreDistCoreXNode) {
|
|
19222
19222
|
XNode = _webAtomsCoreDistCoreXNode.default;
|
|
19223
|
+
}, function (_webAtomsCoreDistWebControlsAtomControl) {
|
|
19224
|
+
AtomControl = _webAtomsCoreDistWebControlsAtomControl.AtomControl;
|
|
19225
|
+
}, function (_webAtomsCoreDistWebCoreAtomUI) {
|
|
19226
|
+
descendentElementIterator = _webAtomsCoreDistWebCoreAtomUI.descendentElementIterator;
|
|
19223
19227
|
}],
|
|
19224
19228
|
execute: function () {
|
|
19229
|
+
_export("renderMail", renderMail = AtomControl.registerProperty("data-html", "html", (c, e, value) => {
|
|
19230
|
+
if (!value) {
|
|
19231
|
+
e.innerHTML = "";
|
|
19232
|
+
return;
|
|
19233
|
+
}
|
|
19234
|
+
const mail = value;
|
|
19235
|
+
const html = mail.htmlBody;
|
|
19236
|
+
const msg = document.createElement("div");
|
|
19237
|
+
if (!html) {
|
|
19238
|
+
for (const iterator of html.split("\n")) {
|
|
19239
|
+
const p = document.createElement("p");
|
|
19240
|
+
p.appendChild(document.createTextNode(iterator));
|
|
19241
|
+
msg.appendChild(p);
|
|
19242
|
+
}
|
|
19243
|
+
e.appendChild(msg);
|
|
19244
|
+
return;
|
|
19245
|
+
}
|
|
19246
|
+
msg.innerHTML = html;
|
|
19247
|
+
for (const iterator of descendentElementIterator(msg)) {
|
|
19248
|
+
if (iterator.tagName === "IMG") {
|
|
19249
|
+
const src = iterator.getAttribute("src");
|
|
19250
|
+
if (src === null || src === void 0 ? void 0 : src.startsWith("cid:")) {
|
|
19251
|
+
const cid = src.substring(4);
|
|
19252
|
+
const a = mail.attachments.find(x => x.contentID === cid);
|
|
19253
|
+
if (a) {
|
|
19254
|
+
iterator.setAttribute("src", `/api/files/${a.appFileID}/${a.appFile.fileContentID}/${a.fileName}`);
|
|
19255
|
+
}
|
|
19256
|
+
}
|
|
19257
|
+
continue;
|
|
19258
|
+
}
|
|
19259
|
+
if (iterator.tagName === "A") {
|
|
19260
|
+
iterator.target = "_blank";
|
|
19261
|
+
}
|
|
19262
|
+
}
|
|
19263
|
+
e.appendChild(msg);
|
|
19264
|
+
return;
|
|
19265
|
+
}));
|
|
19225
19266
|
ConversationService = class ConversationService {
|
|
19226
19267
|
list({
|
|
19227
19268
|
search = "",
|
|
@@ -19258,6 +19299,11 @@ System.register(["tslib", "@web-atoms/core/dist/di/DISingleton", "@web-atoms/cor
|
|
|
19258
19299
|
div.innerHTML = html;
|
|
19259
19300
|
return div.textContent;
|
|
19260
19301
|
}
|
|
19302
|
+
renderHtml(html) {
|
|
19303
|
+
const div = document.createElement("div");
|
|
19304
|
+
div.innerHTML = html;
|
|
19305
|
+
return div.innerHTML;
|
|
19306
|
+
}
|
|
19261
19307
|
toHtml(textBody) {
|
|
19262
19308
|
return DomToString(XNode.create("div", null, ...textBody.split("\n").map(p => XNode.create("p", {
|
|
19263
19309
|
text: p
|
|
@@ -22284,6 +22330,7 @@ System.register(["tslib", "@web-atoms/core/dist/core/XNode", "@web-atoms/web-con
|
|
|
22284
22330
|
return;
|
|
22285
22331
|
}
|
|
22286
22332
|
const file = ce.detail.files[0];
|
|
22333
|
+
file.inline = true;
|
|
22287
22334
|
c.executeCommand("insertHTML", void 0, `<div><img data-content="data-url" data-content-id=${file.appFileID} src="${file.url}" style='max-height: 700px;'/></div>`);
|
|
22288
22335
|
});
|
|
22289
22336
|
_export("MailHtmlEditor", MailHtmlEditor = class MailHtmlEditor extends InlineHtmlEditor {
|
|
@@ -23067,7 +23114,9 @@ System.register(["tslib", "@web-atoms/web-controls/dist/mobile-app/MobileApp", "
|
|
|
23067
23114
|
this.model.attachments.add(EmailAttachment.create({
|
|
23068
23115
|
appFileID: iterator.appFileID,
|
|
23069
23116
|
fileName: iterator.file.name,
|
|
23070
|
-
contentType: iterator.file.type
|
|
23117
|
+
contentType: iterator.file.type,
|
|
23118
|
+
contentDisposition: iterator.inline ? "inline" : "attachment",
|
|
23119
|
+
contentID: iterator.inline ? iterator.appFileID.toString() : void 0
|
|
23071
23120
|
}));
|
|
23072
23121
|
}
|
|
23073
23122
|
});
|
|
@@ -23123,7 +23172,7 @@ System.register(["tslib", "@web-atoms/web-controls/dist/mobile-app/MobileApp", "
|
|
|
23123
23172
|
System.register(["tslib", "@web-atoms/web-controls/dist/mobile-app/MobileApp", "../../../model/model", "@web-atoms/core/dist/core/XNode", "@web-atoms/web-controls/dist/basic/AtomRepeater", "../../../common/controls/repeater/InfiniteRepeater", "./service/ConversationService", "@web-atoms/core/dist/core/InjectProperty", "@web-atoms/core/dist/style/styled", "@web-atoms/core/dist/view-model/Action", "@web-atoms/web-controls/dist/PageNavigator", "./ComposeMailPage"], function (_export, _context) {
|
|
23124
23173
|
"use strict";
|
|
23125
23174
|
|
|
23126
|
-
var __awaiter, __decorate, __metadata, ContentPage, Email, EmailRecipient, XNode, AtomRepeater, InfiniteRepeater, ConversationService, InjectProperty, styled, Action, PageNavigator, ComposeMailPage, ConversationPage, css, id, fixLinks;
|
|
23175
|
+
var __awaiter, __decorate, __metadata, ContentPage, Email, EmailRecipient, XNode, AtomRepeater, InfiniteRepeater, ConversationService, renderMail, InjectProperty, styled, Action, PageNavigator, ComposeMailPage, ConversationPage, css, id, fixLinks;
|
|
23127
23176
|
_export("default", void 0);
|
|
23128
23177
|
return {
|
|
23129
23178
|
setters: [function (_tslib) {
|
|
@@ -23143,6 +23192,7 @@ System.register(["tslib", "@web-atoms/web-controls/dist/mobile-app/MobileApp", "
|
|
|
23143
23192
|
InfiniteRepeater = _commonControlsRepeaterInfiniteRepeater.default;
|
|
23144
23193
|
}, function (_serviceConversationService) {
|
|
23145
23194
|
ConversationService = _serviceConversationService.default;
|
|
23195
|
+
renderMail = _serviceConversationService.renderMail;
|
|
23146
23196
|
}, function (_webAtomsCoreDistCoreInjectProperty) {
|
|
23147
23197
|
InjectProperty = _webAtomsCoreDistCoreInjectProperty.default;
|
|
23148
23198
|
}, function (_webAtomsCoreDistStyleStyled) {
|
|
@@ -23213,11 +23263,9 @@ System.register(["tslib", "@web-atoms/web-controls/dist/mobile-app/MobileApp", "
|
|
|
23213
23263
|
"data-click-event": "reply-email",
|
|
23214
23264
|
class: "fas fa-reply",
|
|
23215
23265
|
title: "Reply"
|
|
23216
|
-
})), XNode.create("div", {
|
|
23217
|
-
class: "message"
|
|
23218
|
-
|
|
23219
|
-
innerHTML: item.htmlBody || this.conversationService.toHtml(item.textBody)
|
|
23220
|
-
}), ((_a = item.attachments) === null || _a === void 0 ? void 0 : _a.length) && XNode.create("div", {
|
|
23266
|
+
})), XNode.create("div", Object.assign({
|
|
23267
|
+
class: "message"
|
|
23268
|
+
}, renderMail(item))), ((_a = item.attachments) === null || _a === void 0 ? void 0 : _a.length) && XNode.create("div", {
|
|
23221
23269
|
class: "attachments",
|
|
23222
23270
|
"data-layout": "flex-wrap-padding"
|
|
23223
23271
|
}, ...item.attachments.map(a => XNode.create("div", null, XNode.create("i", {
|