vue-intergrall-plugins 1.0.65 → 1.0.66
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.
|
@@ -10061,8 +10061,8 @@ var __vue_staticRenderFns__$3 = [];
|
|
|
10061
10061
|
/* style */
|
|
10062
10062
|
var __vue_inject_styles__$3 = function __vue_inject_styles__(inject) {
|
|
10063
10063
|
if (!inject) return;
|
|
10064
|
-
inject("data-v-
|
|
10065
|
-
source: ".email-file{display:flex;align-items:center;justify-content:flex-end;flex-direction:column;min-width:50px;width:auto;max-width:100px;height:70px;position:relative}.anexo-img{display:flex;justify-content:center;align-items:center;width:100%;height:100%;overflow:hidden;background-color:rgba(0,0,0,.2);border-radius:2.5px;cursor:pointer;opacity:.9;transition:opacity 150ms}.anexo-img:hover{opacity:1}.anexo-img img{max-width:100%;font-size:.8rem}.anexo-video{width:100%;height:100%;max-width:100
|
|
10064
|
+
inject("data-v-5fc0ce34_0", {
|
|
10065
|
+
source: ".email-file{display:flex;align-items:center;justify-content:flex-end;flex-direction:column;min-width:50px;width:auto;max-width:100px;height:70px;position:relative}.anexo-img{display:flex;justify-content:center;align-items:center;width:100%;height:100%;overflow:hidden;background-color:rgba(0,0,0,.2);border-radius:2.5px;cursor:pointer;opacity:.9;transition:opacity 150ms}.anexo-img:hover{opacity:1}.anexo-img img{max-width:100%;font-size:.8rem}.anexo-video{width:100%;height:100%;max-width:100%;overflow:hidden}.anexo-video video{max-width:100%}.box-shadow{-webkit-box-shadow:0 3px 1px -2px rgba(0,0,0,.2),0 2px 2px 0 rgba(0,0,0,.14),0 1px 5px 0 rgba(0,0,0,.12);-moz-box-shadow:0 3px 1px -2px rgba(0,0,0,.2),0 2px 2px 0 rgba(0,0,0,.14),0 1px 5px 0 rgba(0,0,0,.12);box-shadow:0 3px 1px -2px rgba(0,0,0,.2),0 2px 2px 0 rgba(0,0,0,.14),0 1px 5px 0 rgba(0,0,0,.12)}.anexo-icone{display:flex;justify-content:center;align-items:center;font-size:30px;cursor:pointer}.anexo-icone:hover{opacity:1}.anexo-icone:visited{color:inherit}.anexo-icone.pdf{position:relative}.anexo-icone.pdf svg{color:#e74c3c}.anexo-icone.pdf::after{content:\"\";position:absolute;bottom:2px;transform:translateY(2px);width:20px;height:20px}.anexo-icone.doc{color:#15517f}.anexo-icone.doc::after{content:\"\";position:absolute;width:20px;height:20px}.anexo-download{position:absolute;top:0;right:0;border-radius:5px;padding:5px;display:flex;justify-content:center;align-items:center;color:#222;background-color:#fff;z-index:1;font-size:.8rem;cursor:pointer}.anexo-name{max-width:100%;font-size:.8rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:2px 0 5px 0;height:20px}.anexo-icone,.anexo-img,.anexo-video{max-height:calc(100% - 20px)}",
|
|
10066
10066
|
map: undefined,
|
|
10067
10067
|
media: undefined
|
|
10068
10068
|
});
|
|
@@ -10070,7 +10070,7 @@ var __vue_inject_styles__$3 = function __vue_inject_styles__(inject) {
|
|
|
10070
10070
|
/* scoped */
|
|
10071
10071
|
var __vue_scope_id__$3 = undefined;
|
|
10072
10072
|
/* module identifier */
|
|
10073
|
-
var __vue_module_identifier__$3 = "data-v-
|
|
10073
|
+
var __vue_module_identifier__$3 = "data-v-5fc0ce34";
|
|
10074
10074
|
/* functional template */
|
|
10075
10075
|
var __vue_is_functional_template__$3 = false;
|
|
10076
10076
|
/* style inject shadow dom */
|
|
@@ -10199,6 +10199,12 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10199
10199
|
return [];
|
|
10200
10200
|
}
|
|
10201
10201
|
},
|
|
10202
|
+
copia: {
|
|
10203
|
+
type: Array,
|
|
10204
|
+
default: function _default() {
|
|
10205
|
+
return [];
|
|
10206
|
+
}
|
|
10207
|
+
},
|
|
10202
10208
|
html: {
|
|
10203
10209
|
type: String,
|
|
10204
10210
|
default: ""
|
|
@@ -10269,6 +10275,10 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10269
10275
|
};
|
|
10270
10276
|
},
|
|
10271
10277
|
computed: {
|
|
10278
|
+
paraCopia: function paraCopia() {
|
|
10279
|
+
if (!this.copia || !this.copia.length) return this.para && this.para.length ? this.para : [];
|
|
10280
|
+
return this.para && this.para.length ? this.para.concat(this.copia) : this.copia;
|
|
10281
|
+
},
|
|
10272
10282
|
formattedDate: function formattedDate() {
|
|
10273
10283
|
return this.formataDateHoraDateFns(this.dataHora, this.dataServer, this.dicionario);
|
|
10274
10284
|
},
|
|
@@ -10282,12 +10292,12 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10282
10292
|
});
|
|
10283
10293
|
return str;
|
|
10284
10294
|
};
|
|
10285
|
-
|
|
10295
|
+
var infos = [{
|
|
10286
10296
|
label: 'De:',
|
|
10287
|
-
value: formatAsString(this.from)
|
|
10297
|
+
value: this.from && this.from.length ? formatAsString(this.from) : '--'
|
|
10288
10298
|
}, {
|
|
10289
10299
|
label: 'Para:',
|
|
10290
|
-
value: formatAsString(this.para)
|
|
10300
|
+
value: this.para && this.para.length ? formatAsString(this.para) : '--'
|
|
10291
10301
|
}, {
|
|
10292
10302
|
label: 'Assunto:',
|
|
10293
10303
|
value: this.htmlEntityToEmoji(this.replaceUnicodeWithEmoji(this.assunto)) || '(Sem assunto)'
|
|
@@ -10295,18 +10305,30 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10295
10305
|
label: 'Data:',
|
|
10296
10306
|
value: this.formataDataHora(this.dataHora) || '--'
|
|
10297
10307
|
}];
|
|
10308
|
+
if (this.copia && this.copia.length) {
|
|
10309
|
+
infos.push({
|
|
10310
|
+
label: this.dicionario.tit_copia,
|
|
10311
|
+
value: formatAsString(this.copia)
|
|
10312
|
+
});
|
|
10313
|
+
}
|
|
10314
|
+
return infos;
|
|
10298
10315
|
}
|
|
10299
10316
|
},
|
|
10300
10317
|
watch: {
|
|
10301
10318
|
isOpen: 'updateIframeContent'
|
|
10302
10319
|
},
|
|
10303
10320
|
mounted: function mounted() {
|
|
10321
|
+
var _this = this;
|
|
10304
10322
|
this.updateIframeContent();
|
|
10305
10323
|
this.adjustMaxWidth();
|
|
10306
10324
|
if (this.refKey) this.$root.$refs["".concat(refKey)] = this;
|
|
10325
|
+
setTimeout(function () {
|
|
10326
|
+
if (_this.isIframeLoading) _this.adjustIframeHeight();
|
|
10327
|
+
}, 15000);
|
|
10307
10328
|
},
|
|
10308
10329
|
methods: {
|
|
10309
10330
|
returnAuthorName: function returnAuthorName() {
|
|
10331
|
+
if (!this.from || !this.from.length) return this.autor || '';
|
|
10310
10332
|
var _this$from$ = this.from[0],
|
|
10311
10333
|
mail = _this$from$.mail,
|
|
10312
10334
|
name = _this$from$.name;
|
|
@@ -10316,24 +10338,26 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10316
10338
|
return name;
|
|
10317
10339
|
},
|
|
10318
10340
|
updateIframeContent: function updateIframeContent() {
|
|
10319
|
-
var
|
|
10341
|
+
var _this2 = this;
|
|
10320
10342
|
this.$nextTick(function () {
|
|
10321
|
-
if (
|
|
10322
|
-
var iframe =
|
|
10343
|
+
if (_this2.isOpen && _this2.isIframeLoading) {
|
|
10344
|
+
var iframe = _this2.$refs.emailIframe;
|
|
10345
|
+
if (!iframe) return;
|
|
10323
10346
|
var doc = iframe.contentDocument || iframe.contentWindow.document;
|
|
10347
|
+
if (!doc) return;
|
|
10324
10348
|
doc.open();
|
|
10325
|
-
doc.write(
|
|
10349
|
+
doc.write(_this2.html);
|
|
10326
10350
|
doc.close();
|
|
10327
10351
|
var images = doc.getElementsByTagName('img');
|
|
10328
10352
|
var imagesLoaded = 0;
|
|
10329
10353
|
var imageLoadHandler = function imageLoadHandler() {
|
|
10330
10354
|
imagesLoaded++;
|
|
10331
10355
|
if (imagesLoaded === images.length) {
|
|
10332
|
-
|
|
10356
|
+
_this2.adjustIframeHeight();
|
|
10333
10357
|
}
|
|
10334
10358
|
};
|
|
10335
10359
|
if (images.length === 0) {
|
|
10336
|
-
|
|
10360
|
+
_this2.adjustIframeHeight();
|
|
10337
10361
|
} else {
|
|
10338
10362
|
var _iterator = _createForOfIteratorHelper(images),
|
|
10339
10363
|
_step;
|
|
@@ -10353,10 +10377,10 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10353
10377
|
});
|
|
10354
10378
|
},
|
|
10355
10379
|
adjustIframeHeight: function adjustIframeHeight() {
|
|
10356
|
-
var
|
|
10380
|
+
var _this3 = this;
|
|
10357
10381
|
this.$nextTick(function () {
|
|
10358
|
-
var iframe =
|
|
10359
|
-
var emailParent =
|
|
10382
|
+
var iframe = _this3.$refs.emailIframe;
|
|
10383
|
+
var emailParent = _this3.$refs.emailIframeParent;
|
|
10360
10384
|
if (iframe && emailParent) {
|
|
10361
10385
|
setTimeout(function () {
|
|
10362
10386
|
var doc = iframe.contentDocument || iframe.contentWindow.document;
|
|
@@ -10366,15 +10390,15 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10366
10390
|
emailParent.style.minHeight = "".concat(value, "px");
|
|
10367
10391
|
}, 10);
|
|
10368
10392
|
}
|
|
10369
|
-
if (
|
|
10393
|
+
if (_this3.isIframeLoading) _this3.isIframeLoading = false;
|
|
10370
10394
|
});
|
|
10371
10395
|
},
|
|
10372
10396
|
toggleShowInfos: function toggleShowInfos() {
|
|
10373
|
-
var
|
|
10397
|
+
var _this4 = this;
|
|
10374
10398
|
this.showInfos = !this.showInfos;
|
|
10375
10399
|
if (this.showInfos) {
|
|
10376
10400
|
this.$nextTick(function () {
|
|
10377
|
-
|
|
10401
|
+
_this4.adjustTopPosition();
|
|
10378
10402
|
});
|
|
10379
10403
|
}
|
|
10380
10404
|
},
|
|
@@ -10395,10 +10419,10 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10395
10419
|
}
|
|
10396
10420
|
},
|
|
10397
10421
|
adjustMaxWidth: function adjustMaxWidth() {
|
|
10398
|
-
var
|
|
10422
|
+
var _this5 = this;
|
|
10399
10423
|
this.$nextTick(function () {
|
|
10400
|
-
var toContainer =
|
|
10401
|
-
var dateContainer =
|
|
10424
|
+
var toContainer = _this5.$refs.emailToContainer;
|
|
10425
|
+
var dateContainer = _this5.$refs.emailDate;
|
|
10402
10426
|
if (!toContainer || !dateContainer) return;
|
|
10403
10427
|
toContainer.style.maxWidth = "calc(100% - ".concat(dateContainer.offsetWidth, "px)");
|
|
10404
10428
|
});
|
|
@@ -10433,7 +10457,10 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10433
10457
|
return "<".concat(mail || '--').concat(index !== length - 1 && isOpen ? '>, ' : '>');
|
|
10434
10458
|
},
|
|
10435
10459
|
formattedToName: function formattedToName(name, index, length) {
|
|
10436
|
-
|
|
10460
|
+
var addVirgulaDps = index < length - 1;
|
|
10461
|
+
var addVirgulaAntes = index === 1 && length >= 2;
|
|
10462
|
+
var text = index === 0 ? "Para: ".concat(name || '') : name ? "".concat(addVirgulaAntes ? ', ' : '').concat(name).concat(addVirgulaDps ? ', ' : '') : '';
|
|
10463
|
+
return text;
|
|
10437
10464
|
},
|
|
10438
10465
|
returnMainValue: function returnMainValue() {
|
|
10439
10466
|
if (this.isMainEmail) return this.htmlEntityToEmoji(this.replaceUnicodeWithEmoji(this.assunto)) || '(Sem assunto)';
|
|
@@ -10444,6 +10471,22 @@ var EmailTo = __vue_component__$4;var script$1 = {
|
|
|
10444
10471
|
event.preventDefault();
|
|
10445
10472
|
event.stopPropagation();
|
|
10446
10473
|
this.toggleIsOpen();
|
|
10474
|
+
},
|
|
10475
|
+
returnParams: function returnParams(params) {
|
|
10476
|
+
var _this6 = this;
|
|
10477
|
+
var defaultParams = {
|
|
10478
|
+
message: this.mensagem
|
|
10479
|
+
};
|
|
10480
|
+
if (!params) return defaultParams;
|
|
10481
|
+
var keys = params.instanceKeys.split("|");
|
|
10482
|
+
if (!keys || !keys.length) return _objectSpread2({
|
|
10483
|
+
defaultParams: defaultParams
|
|
10484
|
+
}, params.values);
|
|
10485
|
+
var customParams = _objectSpread2({}, params.values);
|
|
10486
|
+
keys.forEach(function (key) {
|
|
10487
|
+
if (_this6[key]) customParams[key] = _this6[key];else console.warn("Cant find ".concat(key, " on 'this' instance"));
|
|
10488
|
+
});
|
|
10489
|
+
return Object.keys(customParams).length ? customParams : defaultParams;
|
|
10447
10490
|
}
|
|
10448
10491
|
}
|
|
10449
10492
|
};/* script */
|
|
@@ -10461,19 +10504,19 @@ var __vue_render__$1 = function __vue_render__() {
|
|
|
10461
10504
|
return _vm.openByItem($event);
|
|
10462
10505
|
}
|
|
10463
10506
|
}
|
|
10464
|
-
}, [_vm._ssrNode((_vm.showInfos ? "<div class=\"email-overlay\" data-v-
|
|
10507
|
+
}, [_vm._ssrNode((_vm.showInfos ? "<div class=\"email-overlay\" data-v-82cc4396></div>" : "<!---->") + " "), _vm.autor ? _vm._ssrNode("<div" + _vm._ssrClass("email-author", [_vm.origem]) + " data-v-82cc4396>", "</div>", [_c('fa-icon', {
|
|
10465
10508
|
class: [_vm.origem],
|
|
10466
10509
|
attrs: {
|
|
10467
10510
|
"icon": ['fas', 'reply'],
|
|
10468
10511
|
"title": "Enviado por: " + _vm.autor
|
|
10469
10512
|
}
|
|
10470
|
-
}), _vm._ssrNode(" <p" + _vm._ssrAttr("title", _vm.returnAuthorName()) + " class=\"email-author-name\" data-v-
|
|
10513
|
+
}), _vm._ssrNode(" <p" + _vm._ssrAttr("title", _vm.returnAuthorName()) + " class=\"email-author-name\" data-v-82cc4396>" + _vm._ssrEscape(_vm._s(_vm.returnAuthorName())) + "</p> "), _c('fa-icon', {
|
|
10471
10514
|
staticClass: "email-to-svg",
|
|
10472
10515
|
attrs: {
|
|
10473
10516
|
"icon": ['fas', _vm.origem === 'outros' ? 'user' : 'headset'],
|
|
10474
10517
|
"title": "E-mail " + (_vm.origem === 'outros' ? 'recebido' : 'enviado')
|
|
10475
10518
|
}
|
|
10476
|
-
})], 2) : _vm._e(), _vm._ssrNode(" "), _vm.customButtons && _vm.customButtons.length ? _vm._ssrNode("<div class=\"email-custom-buttons\" data-v-
|
|
10519
|
+
})], 2) : _vm._e(), _vm._ssrNode(" "), _vm.customButtons && _vm.customButtons.length ? _vm._ssrNode("<div class=\"email-custom-buttons\" data-v-82cc4396>", "</div>", _vm._l(_vm.customButtons, function (button, index) {
|
|
10477
10520
|
return _c('span', {
|
|
10478
10521
|
directives: [{
|
|
10479
10522
|
name: "show",
|
|
@@ -10504,22 +10547,22 @@ var __vue_render__$1 = function __vue_render__() {
|
|
|
10504
10547
|
"innerHTML": _vm._s(button.svgIcon)
|
|
10505
10548
|
}
|
|
10506
10549
|
})], 1);
|
|
10507
|
-
}), 0) : _vm._e(), _vm._ssrNode(" "), _vm._ssrNode("<div class=\"email-header\" data-v-
|
|
10550
|
+
}), 0) : _vm._e(), _vm._ssrNode(" "), _vm._ssrNode("<div class=\"email-header\" data-v-82cc4396>", "</div>", [_vm._ssrNode("<p" + _vm._ssrAttr("title", _vm.returnMainValue()) + " class=\"email-subject\" data-v-82cc4396>" + _vm._ssrEscape("\n " + _vm._s(_vm.returnMainValue()) + "\n ") + "</p> "), _vm._ssrNode("<div class=\"header-container\" data-v-82cc4396>", "</div>", [_vm._ssrNode("<div" + _vm._ssrClass(null, "email-header-content" + (_vm.isOpen ? ' open' : '')) + " data-v-82cc4396>", "</div>", [_vm._ssrNode("<div class=\"email-header-infos\" data-v-82cc4396>", "</div>", [_vm.para && _vm.para.length ? [_vm._ssrNode("<div class=\"email-to-from-container\" data-v-82cc4396>", "</div>", [_vm._l(_vm.paraCopia, function (recipient, index) {
|
|
10508
10551
|
return _c('EmailTo', {
|
|
10509
10552
|
key: "to-" + index,
|
|
10510
10553
|
attrs: {
|
|
10511
|
-
"currentName": _vm.formattedToName(recipient.name, index, _vm.
|
|
10554
|
+
"currentName": _vm.formattedToName(recipient.name, index, _vm.paraCopia.length),
|
|
10512
10555
|
"mail": recipient.mail,
|
|
10513
|
-
"showMail": _vm.
|
|
10556
|
+
"showMail": _vm.isOpen
|
|
10514
10557
|
}
|
|
10515
10558
|
});
|
|
10516
10559
|
}), _vm._ssrNode(" "), _vm._ssrNode("<div class=\"email-to-btn\"" + _vm._ssrStyle(null, null, {
|
|
10517
10560
|
display: _vm.isOpen ? '' : 'none'
|
|
10518
|
-
}) + " data-v-
|
|
10561
|
+
}) + " data-v-82cc4396>", "</div>", [_c('fa-icon', {
|
|
10519
10562
|
attrs: {
|
|
10520
10563
|
"icon": ['fas', 'caret-down']
|
|
10521
10564
|
}
|
|
10522
|
-
})], 1)], 2)] : _vm._e(), _vm._ssrNode(" " + (!_vm.isMainEmail && _vm.isOpen ? "<div class=\"email-subject-secondary\" data-v-
|
|
10565
|
+
})], 1)], 2)] : _vm._e(), _vm._ssrNode(" " + (!_vm.isMainEmail && _vm.isOpen ? "<div class=\"email-subject-secondary\" data-v-82cc4396><span class=\"email-subject-span\" data-v-82cc4396>" + _vm._ssrEscape(_vm._s("Assunto: " + (_vm.htmlEntityToEmoji(_vm.replaceUnicodeWithEmoji(_vm.assunto)) || '(Sem assunto)'))) + "</span></div>" : "<!---->"))], 2)]), _vm._ssrNode(" "), _vm._ssrNode("<span" + _vm._ssrAttr("title", _vm.formattedDate) + _vm._ssrClass(null, "email-date " + (_vm.isOpen ? _vm.isOpenClass : _vm.isClosedClass)) + " data-v-82cc4396>", "</span>", [_c('fa-icon', {
|
|
10523
10566
|
attrs: {
|
|
10524
10567
|
"icon": ['fas', 'calendar']
|
|
10525
10568
|
}
|
|
@@ -10540,12 +10583,12 @@ var __vue_render__$1 = function __vue_render__() {
|
|
|
10540
10583
|
}
|
|
10541
10584
|
}
|
|
10542
10585
|
}, [_vm._ssrNode(_vm._ssrList(_vm.mailInfos, function (info, index) {
|
|
10543
|
-
return "<li class=\"email-info\" data-v-
|
|
10586
|
+
return "<li class=\"email-info\" data-v-82cc4396><span data-v-82cc4396>" + _vm._ssrEscape(_vm._s(info.label)) + "</span>" + _vm._ssrEscape("\n " + _vm._s(info.value) + "\n ") + "</li>";
|
|
10544
10587
|
}))]) : _vm._e(), _vm._ssrNode(" " + (_vm.isOpen ? "<span" + _vm._ssrClass(null, ['email-actions box-shadow', {
|
|
10545
10588
|
active: _vm.actionsOpen
|
|
10546
10589
|
}, {
|
|
10547
10590
|
main: _vm.isMainEmail
|
|
10548
|
-
}]) + " data-v-
|
|
10591
|
+
}]) + " data-v-82cc4396><span data-v-82cc4396></span> <span data-v-82cc4396></span> <span data-v-82cc4396></span></span>" : "<!---->") + " "), _vm.actionsOpen && _vm.isOpen ? _c('ul', {
|
|
10549
10592
|
directives: [{
|
|
10550
10593
|
name: "clickaway",
|
|
10551
10594
|
rawName: "v-clickaway",
|
|
@@ -10558,7 +10601,7 @@ var __vue_render__$1 = function __vue_render__() {
|
|
|
10558
10601
|
$event.stopPropagation();
|
|
10559
10602
|
}
|
|
10560
10603
|
}
|
|
10561
|
-
}, [_vm._ssrNode("<li class=\"email-action\" data-v-
|
|
10604
|
+
}, [_vm._ssrNode("<li class=\"email-action\" data-v-82cc4396>" + _vm._ssrEscape("\n " + _vm._s(!_vm.openMessage ? 'Visualizar' : 'Esconder') + " texto do e-mail\n ") + "</li>")]) : _vm._e()], 2), _vm._ssrNode(" "), _c('transition', {
|
|
10562
10605
|
attrs: {
|
|
10563
10606
|
"name": "show-y-top"
|
|
10564
10607
|
}
|
|
@@ -10576,7 +10619,7 @@ var __vue_render__$1 = function __vue_render__() {
|
|
|
10576
10619
|
class: "email-html " + (_vm.isIframeLoading ? 'visibility-hidden' : '')
|
|
10577
10620
|
}), _vm._v(" "), _vm.openMessage ? _c('span', {
|
|
10578
10621
|
staticClass: "email-raw"
|
|
10579
|
-
}, [_vm._v(_vm._s(_vm.mensagem))]) : _vm._e()], 1)]), _vm._ssrNode(" "), _vm.anexos && _vm.anexos.length ? _vm._ssrNode("<div class=\"email-files\" data-v-
|
|
10622
|
+
}, [_vm._v(_vm._s(_vm.mensagem))]) : _vm._e()], 1)]), _vm._ssrNode(" "), _vm.anexos && _vm.anexos.length ? _vm._ssrNode("<div class=\"email-files\" data-v-82cc4396>", "</div>", _vm._l(_vm.anexos, function (anexo, index) {
|
|
10580
10623
|
return _c('EmailFile', {
|
|
10581
10624
|
key: index,
|
|
10582
10625
|
attrs: {
|
|
@@ -10591,20 +10634,20 @@ var __vue_staticRenderFns__$1 = [];
|
|
|
10591
10634
|
/* style */
|
|
10592
10635
|
var __vue_inject_styles__$1 = function __vue_inject_styles__(inject) {
|
|
10593
10636
|
if (!inject) return;
|
|
10594
|
-
inject("data-v-
|
|
10595
|
-
source: ".show-y-top-enter-active[data-v-
|
|
10637
|
+
inject("data-v-82cc4396_0", {
|
|
10638
|
+
source: ".show-y-top-enter-active[data-v-82cc4396],.show-y-top-leave-enter[data-v-82cc4396]{opacity:1;transform:translateY(0);transition:all .2s linear}.show-y-top-enter[data-v-82cc4396],.show-y-top-leave-to[data-v-82cc4396]{opacity:0;transform:translateY(-2%)}",
|
|
10596
10639
|
map: undefined,
|
|
10597
10640
|
media: undefined
|
|
10598
|
-
}), inject("data-v-
|
|
10599
|
-
source: "@import url(https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap);.visibility-hidden{visibility:hidden}.box-shadow-active{box-shadow:0 0 4px 2px rgba(0,0,0,.25)!important}.bg-dark-white-2{background-color:#f7f7f7}.bg-white{background-color:#fff}.cursor-pointer{cursor:pointer}.email-overlay{width:100%;height:100%;background-color:transparent;z-index:1;position:absolute;top:0;left:0}.email-item{font-family:Roboto,sans-serif;flex:1;margin:0 0 10px 0;color:#222;min-height:60px;display:flex;flex-wrap:wrap;padding:10px;border-radius:5px;transition:all 150ms ease-in-out;max-width:100%;width:100%;overflow:hidden;position:relative}.email-item.outros{border-left:3px solid #33b8df}.email-author-name{margin:0 5px;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.email-author.outros{color:#33b8df}.email-author.outros>svg:nth-child(1){transform:rotate(180deg)}.email-author.principal{color:#ebb552}.email-item.principal{border-left:3px solid #ebb552}.email-item.info-open{overflow:visible}.email-header{width:100%;display:flex;flex-direction:column;cursor:pointer;border-top-right-radius:5px;border-top-left-radius:5px;position:relative;overflow:visible}.header-container{display:flex;overflow:hidden;position:relative}.email-header-content{display:flex;align-items:center;flex:1;min-width:250px}.email-header-infos{display:flex;flex-direction:column;flex:1}.email-subject{margin:5px 0 0 0;font-size:1.025rem;cursor:pointer}.email-date{--width:245px;font-size:.8rem;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;position:absolute;right:0;top:0;min-width:var(--width);width:var(--width);max-width:var(--width);display:flex;justify-content:flex-end;gap:3px;align-items:center}.email-content{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;width:100%;background-color:#fff;position:relative;max-width:100%}.email-actions{align-self:flex-end;display:flex;border-radius:10px;cursor:pointer;align-items:center;justify-content:center;gap:3px;padding:5px 7px;background-color:#ddd;position:absolute;right:0;top:30px;z-index:1}.email-actions.main{top:
|
|
10641
|
+
}), inject("data-v-82cc4396_1", {
|
|
10642
|
+
source: "@import url(https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap);.visibility-hidden{visibility:hidden}.box-shadow-active{box-shadow:0 0 4px 2px rgba(0,0,0,.25)!important}.bg-dark-white-2{background-color:#f7f7f7}.bg-white{background-color:#fff}.cursor-pointer{cursor:pointer}.email-overlay{width:100%;height:100%;background-color:transparent;z-index:1;position:absolute;top:0;left:0}.email-item{font-family:Roboto,sans-serif;flex:1;margin:0 0 10px 0;color:#222;min-height:60px;display:flex;flex-wrap:wrap;padding:10px;border-radius:5px;transition:all 150ms ease-in-out;max-width:100%;width:100%;overflow:hidden;position:relative}.email-item.outros{border-left:3px solid #33b8df}.email-author-name{margin:0 5px;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.email-author.outros{color:#33b8df}.email-author.outros>svg:nth-child(1){transform:rotate(180deg)}.email-author.principal{color:#ebb552}.email-item.principal{border-left:3px solid #ebb552}.email-item.info-open{overflow:visible}.email-header{width:100%;display:flex;flex-direction:column;cursor:pointer;border-top-right-radius:5px;border-top-left-radius:5px;position:relative;overflow:visible}.header-container{display:flex;overflow:hidden;position:relative}.email-header-content{display:flex;align-items:center;flex:1;min-width:250px}.email-header-infos{display:flex;flex-direction:column;flex:1}.email-subject{margin:5px 0 0 0;font-size:1.025rem;cursor:pointer}.email-date{--width:245px;font-size:.8rem;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;position:absolute;right:0;top:0;min-width:var(--width);width:var(--width);max-width:var(--width);display:flex;justify-content:flex-end;gap:3px;align-items:center}.email-content{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;width:100%;background-color:#fff;position:relative;max-width:100%}.email-actions{align-self:flex-end;display:flex;border-radius:10px;cursor:pointer;align-items:center;justify-content:center;gap:3px;padding:5px 7px;background-color:#ddd;position:absolute;right:0;top:30px;z-index:1}.email-actions.main{top:10px}.email-actions.active{background-color:#dfdfdf}.email-actions>span{width:4px;height:4px;min-width:4px;min-height:4px;max-width:4px;max-height:4px;background-color:#222;border-radius:50%}.email-actions-list{position:absolute;right:45px;width:250px;top:5px;margin:0;list-style-type:none;padding:0;border-radius:5px;z-index:1}.email-action{background-color:#dfdfdf;padding:5px 10px;cursor:pointer;transition:background-color 150ms ease-in-out;font-size:.9rem;user-select:none}.email-action:nth-child(1){border-top-left-radius:5px;border-top-right-radius:5px}.email-action:last-child{border-bottom-left-radius:5px;border-bottom-right-radius:5px}.email-action:hover{background-color:#ccc}.email-html{width:100%;min-width:300px;max-width:100%;border:none;overflow:auto}.email-raw{width:100%;max-width:100%;padding:15px;font-size:.9rem;color:#222}.email-files{display:flex;gap:10px;flex-wrap:wrap;width:100%;cursor:default;margin-top:5px}.email-header-content,.email-header-infos{max-width:100%;overflow:hidden}.email-to-from-container{margin-bottom:5px;max-width:100%;min-width:250px;overflow:hidden;display:flex;align-items:center;flex-wrap:wrap;flex:1;gap:5px}.email-to-btn{padding:0 5px;font-size:.9rem;cursor:pointer;color:#666}.email-to-infos{position:absolute;bottom:-325px;border:1px solid #ccc;z-index:2;padding:10px;background-color:#fff;max-height:300px;overflow-y:auto;overflow-x:hidden;width:300px;display:flex;flex-direction:column;gap:5px;margin:0;cursor:default}.email-info{width:100%;font-size:.8rem}.email-info>span{font-size:.75rem;color:gray;margin-right:3px}.email-author{display:flex;align-items:center;height:5px;font-size:.75rem;font-weight:700;transform:translateY(-2px);width:100%;cursor:pointer}.email-subject-secondary{margin-top:-5px}.email-subject-span{font-size:.7rem;color:gray}.email-to-svg{font-size:.85rem}.email-custom-buttons{display:flex;gap:7px;position:absolute;top:5px;right:5px;z-index:1;font-size:.8rem}.menu-mensagem{cursor:pointer;padding:1px}",
|
|
10600
10643
|
map: undefined,
|
|
10601
10644
|
media: undefined
|
|
10602
10645
|
});
|
|
10603
10646
|
};
|
|
10604
10647
|
/* scoped */
|
|
10605
|
-
var __vue_scope_id__$1 = "data-v-
|
|
10648
|
+
var __vue_scope_id__$1 = "data-v-82cc4396";
|
|
10606
10649
|
/* module identifier */
|
|
10607
|
-
var __vue_module_identifier__$1 = "data-v-
|
|
10650
|
+
var __vue_module_identifier__$1 = "data-v-82cc4396";
|
|
10608
10651
|
/* functional template */
|
|
10609
10652
|
var __vue_is_functional_template__$1 = false;
|
|
10610
10653
|
/* style inject shadow dom */
|
package/package.json
CHANGED
|
@@ -26,9 +26,9 @@
|
|
|
26
26
|
<div class="email-header-infos">
|
|
27
27
|
<template v-if="para && para.length">
|
|
28
28
|
<div class="email-to-from-container" ref="emailToContainer">
|
|
29
|
-
<EmailTo v-for="(recipient, index) in
|
|
30
|
-
:currentName="formattedToName(recipient.name, index,
|
|
31
|
-
:showMail="
|
|
29
|
+
<EmailTo v-for="(recipient, index) in paraCopia" :key="`to-${index}`"
|
|
30
|
+
:currentName="formattedToName(recipient.name, index, paraCopia.length)" :mail="recipient.mail"
|
|
31
|
+
:showMail="isOpen" />
|
|
32
32
|
<div class="email-to-btn" v-show="isOpen" @click.stop="toggleShowInfos()">
|
|
33
33
|
<fa-icon :icon="['fas', 'caret-down']" />
|
|
34
34
|
</div>
|
|
@@ -106,6 +106,10 @@ export default {
|
|
|
106
106
|
type: Array,
|
|
107
107
|
default: () => []
|
|
108
108
|
},
|
|
109
|
+
copia: {
|
|
110
|
+
type: Array,
|
|
111
|
+
default: () => []
|
|
112
|
+
},
|
|
109
113
|
html: {
|
|
110
114
|
type: String,
|
|
111
115
|
default: ""
|
|
@@ -174,6 +178,10 @@ export default {
|
|
|
174
178
|
};
|
|
175
179
|
},
|
|
176
180
|
computed: {
|
|
181
|
+
paraCopia() {
|
|
182
|
+
if (!this.copia || !this.copia.length) return this.para && this.para.length ? this.para : []
|
|
183
|
+
return this.para && this.para.length ? this.para.concat(this.copia) : this.copia
|
|
184
|
+
},
|
|
177
185
|
formattedDate() {
|
|
178
186
|
return this.formataDateHoraDateFns(this.dataHora, this.dataServer, this.dicionario);
|
|
179
187
|
},
|
|
@@ -186,14 +194,14 @@ export default {
|
|
|
186
194
|
return str
|
|
187
195
|
}
|
|
188
196
|
|
|
189
|
-
|
|
197
|
+
const infos = [
|
|
190
198
|
{
|
|
191
199
|
label: 'De:',
|
|
192
|
-
value: formatAsString(this.from)
|
|
200
|
+
value: this.from && this.from.length ? formatAsString(this.from) : '--'
|
|
193
201
|
},
|
|
194
202
|
{
|
|
195
203
|
label: 'Para:',
|
|
196
|
-
value: formatAsString(this.para)
|
|
204
|
+
value: this.para && this.para.length ? formatAsString(this.para) : '--'
|
|
197
205
|
},
|
|
198
206
|
{
|
|
199
207
|
label: 'Assunto:',
|
|
@@ -204,6 +212,15 @@ export default {
|
|
|
204
212
|
value: this.formataDataHora(this.dataHora) || '--'
|
|
205
213
|
},
|
|
206
214
|
]
|
|
215
|
+
|
|
216
|
+
if (this.copia && this.copia.length) {
|
|
217
|
+
infos.push({
|
|
218
|
+
label: this.dicionario.tit_copia,
|
|
219
|
+
value: formatAsString(this.copia)
|
|
220
|
+
})
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
return infos
|
|
207
224
|
},
|
|
208
225
|
},
|
|
209
226
|
watch: {
|
|
@@ -214,9 +231,14 @@ export default {
|
|
|
214
231
|
this.adjustMaxWidth()
|
|
215
232
|
|
|
216
233
|
if (this.refKey) this.$root.$refs[`${refKey}`] = this
|
|
234
|
+
|
|
235
|
+
setTimeout(() => {
|
|
236
|
+
if (this.isIframeLoading) this.adjustIframeHeight()
|
|
237
|
+
}, 15000);
|
|
217
238
|
},
|
|
218
239
|
methods: {
|
|
219
240
|
returnAuthorName() {
|
|
241
|
+
if (!this.from || !this.from.length) return this.autor || ''
|
|
220
242
|
const { mail, name } = this.from[0]
|
|
221
243
|
if (!name) return mail
|
|
222
244
|
if (!mail) return name
|
|
@@ -227,7 +249,9 @@ export default {
|
|
|
227
249
|
this.$nextTick(() => {
|
|
228
250
|
if (this.isOpen && this.isIframeLoading) {
|
|
229
251
|
const iframe = this.$refs.emailIframe;
|
|
252
|
+
if (!iframe) return
|
|
230
253
|
const doc = iframe.contentDocument || iframe.contentWindow.document;
|
|
254
|
+
if (!doc) return
|
|
231
255
|
doc.open();
|
|
232
256
|
doc.write(this.html);
|
|
233
257
|
doc.close();
|
|
@@ -333,7 +357,10 @@ export default {
|
|
|
333
357
|
return `<${mail || '--'}${index !== length - 1 && isOpen ? '>, ' : '>'}`;
|
|
334
358
|
},
|
|
335
359
|
formattedToName(name, index, length) {
|
|
336
|
-
|
|
360
|
+
let addVirgulaDps = index < length - 1
|
|
361
|
+
let addVirgulaAntes = index === 1 && length >= 2
|
|
362
|
+
const text = index === 0 ? `Para: ${name || ''}` : name ? `${addVirgulaAntes ? ', ' : ''}${name}${addVirgulaDps ? ', ' : ''}` : '';
|
|
363
|
+
return text
|
|
337
364
|
},
|
|
338
365
|
returnMainValue() {
|
|
339
366
|
if (this.isMainEmail) return this.htmlEntityToEmoji(this.replaceUnicodeWithEmoji(this.assunto)) || '(Sem assunto)'
|
|
@@ -346,6 +373,28 @@ export default {
|
|
|
346
373
|
event.stopPropagation();
|
|
347
374
|
|
|
348
375
|
this.toggleIsOpen();
|
|
376
|
+
},
|
|
377
|
+
returnParams(params) {
|
|
378
|
+
const defaultParams = {
|
|
379
|
+
message: this.mensagem,
|
|
380
|
+
};
|
|
381
|
+
|
|
382
|
+
if (!params) return defaultParams;
|
|
383
|
+
|
|
384
|
+
const keys = params.instanceKeys.split("|");
|
|
385
|
+
if (!keys || !keys.length)
|
|
386
|
+
return {
|
|
387
|
+
defaultParams,
|
|
388
|
+
...params.values,
|
|
389
|
+
};
|
|
390
|
+
|
|
391
|
+
const customParams = { ...params.values };
|
|
392
|
+
keys.forEach((key) => {
|
|
393
|
+
if (this[key]) customParams[key] = this[key];
|
|
394
|
+
else console.warn(`Cant find ${key} on 'this' instance`);
|
|
395
|
+
});
|
|
396
|
+
|
|
397
|
+
return Object.keys(customParams).length ? customParams : defaultParams;
|
|
349
398
|
}
|
|
350
399
|
}
|
|
351
400
|
};
|
|
@@ -530,7 +579,7 @@ export default {
|
|
|
530
579
|
}
|
|
531
580
|
|
|
532
581
|
.email-actions.main {
|
|
533
|
-
top:
|
|
582
|
+
top: 10px
|
|
534
583
|
}
|
|
535
584
|
|
|
536
585
|
.email-actions.active {
|