vue-intergrall-plugins 0.0.246 → 0.0.247
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/vue-intergrall-plugins.esm.js +136 -93
- package/dist/vue-intergrall-plugins.min.js +1 -1
- package/dist/vue-intergrall-plugins.ssr.js +95 -116
- package/package.json +1 -1
- package/src/lib-components/Messages/AnexoMensagem.vue +110 -40
- package/src/lib-components/Messages/ChatMessages.vue +5 -2
|
@@ -10142,7 +10142,7 @@ var __vue_component__$n = __vue_component__$m;var textoLongo = {
|
|
|
10142
10142
|
case "mp3":
|
|
10143
10143
|
case "audio/mp3":
|
|
10144
10144
|
case "aac":
|
|
10145
|
-
tipoDoc = type;
|
|
10145
|
+
tipoDoc = type.startsWith("audio/") ? type : "audio/".concat(type);
|
|
10146
10146
|
docAnexo = "".concat(dominio, "/callcenter/docs.php?mku=").concat(mku);
|
|
10147
10147
|
nomeArquivo = name;
|
|
10148
10148
|
audio = true;
|
|
@@ -10152,7 +10152,7 @@ var __vue_component__$n = __vue_component__$m;var textoLongo = {
|
|
|
10152
10152
|
case "video":
|
|
10153
10153
|
case "mp4":
|
|
10154
10154
|
case "m4v":
|
|
10155
|
-
tipoDoc = type;
|
|
10155
|
+
tipoDoc = type.startsWith("video/") ? type : "video/".concat(type);
|
|
10156
10156
|
docAnexo = "".concat(dominio, "/callcenter/docs.php?mku=").concat(mku);
|
|
10157
10157
|
nomeArquivo = name;
|
|
10158
10158
|
video = true;
|
|
@@ -10261,6 +10261,40 @@ var __vue_component__$n = __vue_component__$m;var textoLongo = {
|
|
|
10261
10261
|
},
|
|
10262
10262
|
setIcon: function setIcon() {
|
|
10263
10263
|
this.icon = this.fileType === "pdf" ? ['fas', 'file-pdf'] : ['fas', 'file-alt'];
|
|
10264
|
+
},
|
|
10265
|
+
downloadAllFilesHandler: function downloadAllFilesHandler() {
|
|
10266
|
+
try {
|
|
10267
|
+
if (!this.$root.$refs.chatMessages || !this.$root.$refs.chatMessages.referenceSelector) return this.$emit("download-all");
|
|
10268
|
+
var container = document.querySelector("".concat(this.$root.$refs.chatMessages.referenceSelector));
|
|
10269
|
+
if (!container) return this.$emit("download-all");
|
|
10270
|
+
var currentFilesToDownload = container.querySelectorAll("a[download]");
|
|
10271
|
+
if (!currentFilesToDownload.length) return this.$emit("download-all", {
|
|
10272
|
+
status: 'erro',
|
|
10273
|
+
message: 'Sem anexos para fazer o download'
|
|
10274
|
+
});
|
|
10275
|
+
var index = 0;
|
|
10276
|
+
|
|
10277
|
+
var handleInterval = function handleInterval() {
|
|
10278
|
+
if (index > currentFilesToDownload.length) return false;
|
|
10279
|
+
currentFilesToDownload[index] && currentFilesToDownload[index].click();
|
|
10280
|
+
index += 1;
|
|
10281
|
+
return true;
|
|
10282
|
+
};
|
|
10283
|
+
|
|
10284
|
+
var interval = setInterval(function () {
|
|
10285
|
+
var handler = handleInterval();
|
|
10286
|
+
|
|
10287
|
+
if (!handler) {
|
|
10288
|
+
clearInterval(interval);
|
|
10289
|
+
interval = 0;
|
|
10290
|
+
}
|
|
10291
|
+
}, 300);
|
|
10292
|
+
} catch (error) {
|
|
10293
|
+
console.error("Erro ao fazer o donwload de todos anexos");
|
|
10294
|
+
this.$toasted.global.defaultError({
|
|
10295
|
+
msg: error.message ? error.message : error
|
|
10296
|
+
});
|
|
10297
|
+
}
|
|
10264
10298
|
}
|
|
10265
10299
|
}
|
|
10266
10300
|
};//
|
|
@@ -11467,144 +11501,83 @@ var __vue_render__$8 = function __vue_render__() {
|
|
|
11467
11501
|
|
|
11468
11502
|
return _c('div', {
|
|
11469
11503
|
staticClass: "mensagem-div-anexo"
|
|
11470
|
-
}, [_c('
|
|
11471
|
-
|
|
11504
|
+
}, [_vm._ssrNode("<div class=\"anexo-mensagem\" data-v-14bae430>", "</div>", [_vm.imageURL ? _vm._ssrNode("<img" + _vm._ssrAttr("src", _vm.imageURL) + _vm._ssrAttr("alt", _vm.dictionary.alt_msg_img) + " data-v-14bae430>", "</img>") : _vm.audio ? _vm._ssrNode("<audio controls=\"controls\" data-v-14bae430><source" + _vm._ssrAttr("src", _vm.docURL) + _vm._ssrAttr("type", _vm.fileType) + " data-v-14bae430>\n Sem suporte para o elemento audio\n </audio>") : _vm.video ? _vm._ssrNode("<video controls=\"controls\" data-v-14bae430><source" + _vm._ssrAttr("src", _vm.docURL) + _vm._ssrAttr("type", _vm.fileType) + " data-v-14bae430>\n Sem suporte para o elemento video\n </video>") : _vm.docURL ? _vm._ssrNode("<a" + _vm._ssrAttr("href", _vm.docURL) + " target=\"_blank\" rel=\"noreferrer noopener\" class=\"default-doc\" data-v-14bae430>", "</a>", [_c('fa-icon', {
|
|
11505
|
+
class: [_vm.iconClass],
|
|
11472
11506
|
attrs: {
|
|
11473
|
-
"
|
|
11474
|
-
"mode": "out-in"
|
|
11507
|
+
"icon": _vm.icon
|
|
11475
11508
|
}
|
|
11476
|
-
},
|
|
11509
|
+
}), _vm._ssrNode(" <p" + _vm._ssrAttr("title", _vm.filename) + " data-v-14bae430>" + _vm._ssrEscape(_vm._s(_vm.filename)) + "</p>")], 2) : _vm._ssrNode("<span class=\"default-doc\" data-v-14bae430>", "</span>", [_c('fa-icon', {
|
|
11510
|
+
class: [_vm.iconClass ? _vm.iconClass : ''],
|
|
11511
|
+
attrs: {
|
|
11512
|
+
"icon": ['fas', 'file-alt']
|
|
11513
|
+
}
|
|
11514
|
+
}), _vm._ssrNode(" <p" + _vm._ssrAttr("title", _vm.filename) + " data-v-14bae430>" + _vm._ssrEscape(_vm._s(_vm.filename)) + "</p>")], 2), _vm._ssrNode(" "), _vm._ssrNode("<div class=\"file-actions\" data-v-14bae430>", "</div>", [_vm.imageURL ? _vm._ssrNode("<span class=\"file-action-button\" data-v-14bae430>", "</span>", [_c('fa-icon', {
|
|
11477
11515
|
directives: [{
|
|
11478
11516
|
name: "tippy",
|
|
11479
11517
|
rawName: "v-tippy"
|
|
11480
11518
|
}],
|
|
11481
|
-
key: "error-msg",
|
|
11482
|
-
attrs: {
|
|
11483
|
-
"content": _vm.imgMsgErro
|
|
11484
|
-
}
|
|
11485
|
-
}, [_c('div', {
|
|
11486
|
-
staticClass: "alert alert-danger",
|
|
11487
|
-
attrs: {
|
|
11488
|
-
"role": "alert"
|
|
11489
|
-
}
|
|
11490
|
-
}, [_c('fa-icon', {
|
|
11491
|
-
attrs: {
|
|
11492
|
-
"icon": ['fas', 'file-image']
|
|
11493
|
-
}
|
|
11494
|
-
}), _vm._v("\n " + _vm._s(_vm.dictionary.img_com_erro) + "\n ")], 1)]) : _vm._e(), _vm._v(" "), _vm.isLoading ? _c('Loader', {
|
|
11495
|
-
key: "anexo-loader",
|
|
11496
|
-
attrs: {
|
|
11497
|
-
"small": true,
|
|
11498
|
-
"slow": true
|
|
11499
|
-
}
|
|
11500
|
-
}) : _c('div', {
|
|
11501
|
-
key: "anexo-mensagem",
|
|
11502
|
-
staticClass: "anexo-mensagem"
|
|
11503
|
-
}, [_vm.imageURL ? _c('img', {
|
|
11504
|
-
attrs: {
|
|
11505
|
-
"src": _vm.imageURL,
|
|
11506
|
-
"alt": _vm.dictionary.alt_msg_img
|
|
11507
|
-
},
|
|
11508
|
-
on: {
|
|
11509
|
-
"click": function click($event) {
|
|
11510
|
-
return _vm.showImage(_vm.imageURL);
|
|
11511
|
-
}
|
|
11512
|
-
}
|
|
11513
|
-
}) : _vm._e(), _vm._v(" "), _vm.imageURL ? _c('div', {
|
|
11514
|
-
staticClass: "anexos-links-container"
|
|
11515
|
-
}, [_c('a', {
|
|
11516
|
-
attrs: {
|
|
11517
|
-
"href": "#"
|
|
11518
|
-
},
|
|
11519
|
-
on: {
|
|
11520
|
-
"click": function click($event) {
|
|
11521
|
-
$event.preventDefault();
|
|
11522
|
-
return _vm.showImage(_vm.imageURL);
|
|
11523
|
-
}
|
|
11524
|
-
}
|
|
11525
|
-
}, [_vm._v(" " + _vm._s(_vm.dictionary.titulo_visualizar_img) + " ")]), _vm._v(" "), _c('fa-icon', {
|
|
11526
|
-
attrs: {
|
|
11527
|
-
"icon": ['fas', 'search-plus']
|
|
11528
|
-
},
|
|
11529
|
-
on: {
|
|
11530
|
-
"click": function click($event) {
|
|
11531
|
-
return _vm.showImage(_vm.imageURL);
|
|
11532
|
-
}
|
|
11533
|
-
}
|
|
11534
|
-
})], 1) : _vm.docURL ? _c('div', {
|
|
11535
|
-
staticClass: "anexo-container"
|
|
11536
|
-
}, [_vm.audio || _vm.video ? [_vm.audio ? _c('audio', {
|
|
11537
11519
|
attrs: {
|
|
11538
|
-
"
|
|
11539
|
-
"
|
|
11540
|
-
"title": _vm.fileType + " - " + _vm.filename
|
|
11520
|
+
"icon": ['fas', 'search-plus'],
|
|
11521
|
+
"content": "" + _vm.dictionary.titulo_visualizar_img
|
|
11541
11522
|
}
|
|
11542
|
-
},
|
|
11523
|
+
})], 1) : _vm._e(), _vm._ssrNode(" "), _vm.docURL ? _c('a', {
|
|
11524
|
+
directives: [{
|
|
11525
|
+
name: "tippy",
|
|
11526
|
+
rawName: "v-tippy"
|
|
11527
|
+
}],
|
|
11528
|
+
staticClass: "file-action-button",
|
|
11543
11529
|
attrs: {
|
|
11544
11530
|
"href": _vm.docURL,
|
|
11545
11531
|
"target": "_blank",
|
|
11546
|
-
"rel": "noreferrer noopener"
|
|
11547
|
-
|
|
11548
|
-
}, [_vm._v(" " + _vm._s(_vm.dictionary.msg_abrir_audio) + " ")])])]) : _vm._e(), _vm._v(" "), _vm.video ? _c('video', {
|
|
11549
|
-
attrs: {
|
|
11550
|
-
"src": _vm.docURL,
|
|
11551
|
-
"controls": "",
|
|
11552
|
-
"title": _vm.fileType + " - " + _vm.filename
|
|
11532
|
+
"rel": "noreferrer noopener",
|
|
11533
|
+
"content": "Visualizar anexo"
|
|
11553
11534
|
}
|
|
11554
|
-
}, [_c('
|
|
11535
|
+
}, [_c('fa-icon', {
|
|
11555
11536
|
attrs: {
|
|
11556
|
-
"
|
|
11557
|
-
"target": "_blank",
|
|
11558
|
-
"rel": "noreferrer noopener"
|
|
11537
|
+
"icon": ['fas', 'search-plus']
|
|
11559
11538
|
}
|
|
11560
|
-
},
|
|
11539
|
+
})], 1) : _vm._e(), _vm._ssrNode(" "), _vm.imageURL || _vm.docURL ? _c('a', {
|
|
11540
|
+
directives: [{
|
|
11541
|
+
name: "tippy",
|
|
11542
|
+
rawName: "v-tippy"
|
|
11543
|
+
}],
|
|
11544
|
+
staticClass: "file-action-button",
|
|
11561
11545
|
attrs: {
|
|
11562
|
-
"href": _vm.docURL,
|
|
11546
|
+
"href": _vm.imageURL ? _vm.imageURL : _vm.docURL,
|
|
11547
|
+
"download": "" + _vm.filename,
|
|
11563
11548
|
"target": "_blank",
|
|
11564
11549
|
"rel": "noreferrer noopener",
|
|
11565
|
-
"
|
|
11550
|
+
"content": "Fazer o download do anexo"
|
|
11566
11551
|
}
|
|
11567
11552
|
}, [_c('fa-icon', {
|
|
11568
|
-
class: [_vm.iconClass],
|
|
11569
11553
|
attrs: {
|
|
11570
|
-
"icon":
|
|
11571
|
-
}
|
|
11572
|
-
}), _vm._v(" "), _c('p', {
|
|
11573
|
-
domProps: {
|
|
11574
|
-
"textContent": _vm._s(_vm.filename)
|
|
11554
|
+
"icon": ['fas', 'download']
|
|
11575
11555
|
}
|
|
11576
|
-
})], 1) : _c('
|
|
11577
|
-
|
|
11556
|
+
})], 1) : _vm._e(), _vm._ssrNode(" "), _c('span', {
|
|
11557
|
+
directives: [{
|
|
11558
|
+
name: "tippy",
|
|
11559
|
+
rawName: "v-tippy"
|
|
11560
|
+
}],
|
|
11561
|
+
staticClass: "file-action-button",
|
|
11578
11562
|
attrs: {
|
|
11579
|
-
"
|
|
11563
|
+
"content": "Fazer download de todos anexos da tela"
|
|
11564
|
+
},
|
|
11565
|
+
on: {
|
|
11566
|
+
"click": _vm.downloadAllFilesHandler
|
|
11580
11567
|
}
|
|
11581
11568
|
}, [_c('fa-icon', {
|
|
11582
|
-
attrs: {
|
|
11583
|
-
"icon": ['fas', 'file-alt']
|
|
11584
|
-
}
|
|
11585
|
-
}), _vm._v("\n " + _vm._s(_vm.filename) + "\n ")], 1)]], 2) : _vm._e(), _vm._v(" "), _vm.imageURL ? _c('a', {
|
|
11586
|
-
attrs: {
|
|
11587
|
-
"href": _vm.imageURL,
|
|
11588
|
-
"download": "" + _vm.filename,
|
|
11589
|
-
"target": "_blank",
|
|
11590
|
-
"rel": "noreferrer noopener"
|
|
11591
|
-
}
|
|
11592
|
-
}, [_vm._v(" " + _vm._s(_vm.dictionary.titulo_baixar_img) + " "), _c('fa-icon', {
|
|
11593
11569
|
attrs: {
|
|
11594
11570
|
"icon": ['fas', 'download']
|
|
11595
11571
|
}
|
|
11596
|
-
})
|
|
11572
|
+
}), _vm._ssrNode(" "), _c('fa-icon', {
|
|
11597
11573
|
attrs: {
|
|
11598
|
-
"
|
|
11599
|
-
"download": "" + _vm.filename,
|
|
11600
|
-
"target": "_blank",
|
|
11601
|
-
"rel": "noreferrer noopener"
|
|
11574
|
+
"icon": ['fas', 'download']
|
|
11602
11575
|
}
|
|
11603
|
-
},
|
|
11576
|
+
}), _vm._ssrNode(" "), _c('fa-icon', {
|
|
11604
11577
|
attrs: {
|
|
11605
11578
|
"icon": ['fas', 'download']
|
|
11606
11579
|
}
|
|
11607
|
-
})],
|
|
11580
|
+
})], 2)], 2)], 2)]);
|
|
11608
11581
|
};
|
|
11609
11582
|
|
|
11610
11583
|
var __vue_staticRenderFns__$8 = [];
|
|
@@ -11612,8 +11585,8 @@ var __vue_staticRenderFns__$8 = [];
|
|
|
11612
11585
|
|
|
11613
11586
|
var __vue_inject_styles__$8 = function __vue_inject_styles__(inject) {
|
|
11614
11587
|
if (!inject) return;
|
|
11615
|
-
inject("data-v-
|
|
11616
|
-
source: ".fade-enter-active[data-v-
|
|
11588
|
+
inject("data-v-14bae430_0", {
|
|
11589
|
+
source: ".mensagem__principal .default-doc[data-v-14bae430]{background-color:rgba(255,255,255,.1)}.mensagem__outros .default-doc[data-v-14bae430]{background-color:rgba(100,100,100,.1)}.default-doc[data-v-14bae430]{display:flex;align-items:center;padding:10px;border-radius:5px;width:100%;max-width:100%}.default-doc svg[data-v-14bae430]{font-size:1.2rem;margin-right:5px}.default-doc p[data-v-14bae430]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.file-actions[data-v-14bae430]{display:flex;justify-content:flex-end;width:100%;padding:5px}.file-actions a[data-v-14bae430]{margin-right:0}.mensagem__principal .file-action-button[data-v-14bae430]{background-color:rgba(255,255,255,.1)}.mensagem__outros .file-action-button[data-v-14bae430]{background-color:rgba(100,100,100,.1)}.mensagem__principal .file-action-button[data-v-14bae430]:hover{background-color:rgba(255,255,255,.3)}.mensagem__outros .file-action-button[data-v-14bae430]:hover{background-color:rgba(100,100,100,.3)}.file-action-button[data-v-14bae430]{display:flex;justify-content:center;align-items:center;margin-left:12px;cursor:pointer;padding:5px;border-radius:5px;transition:background-color 150ms ease-in-out}.file-action-button a[data-v-14bae430]{margin:0}.fade-enter-active[data-v-14bae430],.fade-leave-active[data-v-14bae430]{transition:opacity .5s}.fade-enter[data-v-14bae430],.fade-leave-to[data-v-14bae430]{opacity:0}.mensagem-div-anexo[data-v-14bae430]{width:100%;display:flex;justify-content:center;align-items:center;flex-direction:column;overflow:hidden}.anexo-container[data-v-14bae430]{width:100%;margin-top:5px;overflow:hidden;display:flex;max-height:300px}.anexo-container .arquivo-erro[data-v-14bae430],.anexo-container a[data-v-14bae430]{padding:10px 15px 15px 15px;display:flex;justify-content:center;align-items:center}.anexo-container p[data-v-14bae430]{text-overflow:ellipsis;overflow:hidden}.anexo-container .arquivo-erro[data-v-14bae430],.anexo-container p[data-v-14bae430]{margin:0;margin-left:15px;font-size:.9rem}.anexo-container svg[data-v-14bae430]{font-size:2rem}.anexo-mensagem audio[data-v-14bae430]{outline:0;width:100%;margin-bottom:5px}.anexo-mensagem video[data-v-14bae430]{flex:1;width:100%;max-width:350px;cursor:pointer;margin-bottom:5px}.anexos-links-container[data-v-14bae430]{width:100%;display:flex;justify-content:center;align-items:center}.anexos-links-container a[data-v-14bae430]{white-space:nowrap;text-overflow:ellipsis;overflow:hidden;margin-right:5px;font-weight:550;color:inherit;text-decoration:none}.anexos-links-container svg[data-v-14bae430]{cursor:pointer}.mensagem-div-anexo img[data-v-14bae430]{cursor:pointer;margin:10px 0;min-width:35px;width:100%;max-width:250px}.anexo-transition[data-v-14bae430]{width:100%;height:100%}.anexo-mensagem[data-v-14bae430]{display:flex;justify-content:center;align-items:center;flex-direction:column;width:100%}.alert-danger[data-v-14bae430]{color:#721c24;background-color:#f8d7da;border-color:#f5c6cb}.alert[data-v-14bae430]{position:relative;padding:.65rem 1.2rem;margin:5px 0;border:1px solid transparent;border-radius:.25rem;text-align:center}.alert svg[data-v-14bae430]{font-size:1.025em;margin-right:2px}.pdf[data-v-14bae430]{color:#e74c3c}.doc[data-v-14bae430]{color:#006bc9}",
|
|
11617
11590
|
map: undefined,
|
|
11618
11591
|
media: undefined
|
|
11619
11592
|
});
|
|
@@ -11621,10 +11594,10 @@ var __vue_inject_styles__$8 = function __vue_inject_styles__(inject) {
|
|
|
11621
11594
|
/* scoped */
|
|
11622
11595
|
|
|
11623
11596
|
|
|
11624
|
-
var __vue_scope_id__$8 = "data-v-
|
|
11597
|
+
var __vue_scope_id__$8 = "data-v-14bae430";
|
|
11625
11598
|
/* module identifier */
|
|
11626
11599
|
|
|
11627
|
-
var __vue_module_identifier__$8 = "data-v-
|
|
11600
|
+
var __vue_module_identifier__$8 = "data-v-14bae430";
|
|
11628
11601
|
/* functional template */
|
|
11629
11602
|
|
|
11630
11603
|
var __vue_is_functional_template__$8 = false;
|
|
@@ -11937,7 +11910,10 @@ var script$5 = {
|
|
|
11937
11910
|
InteratividadeFormulario: InteratividadeFormulario,
|
|
11938
11911
|
LinkPreview: LinkPreview
|
|
11939
11912
|
},
|
|
11940
|
-
props: ["smartchannel", "messageIndex", "dictionary", "autor", "origem", "msg", "link", "anexo", "imgAnexo", "tipoDoc", "docAnexo", "nomeArquivo", "audio", "video", "horario", "status", "logo", "msgTooltip", "seq", "mapa", "histMsg", "erro", "msgErro", "origemExterna", "anexos", "dominio", "corMsg", "interatividade", "msgReply", "hasReply", "iniDialogo", "dialogoId", "dialogoOrigem", "expSessao"],
|
|
11913
|
+
props: ["smartchannel", "messageIndex", "dictionary", "autor", "origem", "msg", "link", "anexo", "imgAnexo", "tipoDoc", "docAnexo", "nomeArquivo", "audio", "video", "horario", "status", "logo", "msgTooltip", "seq", "mapa", "histMsg", "erro", "msgErro", "origemExterna", "anexos", "dominio", "corMsg", "interatividade", "msgReply", "hasReply", "iniDialogo", "dialogoId", "dialogoOrigem", "expSessao", "referenceSelector"],
|
|
11914
|
+
created: function created() {
|
|
11915
|
+
if (!this.$root.$refs.chatMessages) this.$root.$refs.chatMessages = this;
|
|
11916
|
+
},
|
|
11941
11917
|
data: function data() {
|
|
11942
11918
|
return {
|
|
11943
11919
|
strTooltipAux: "",
|
|
@@ -12200,7 +12176,10 @@ var __vue_render__$5 = function __vue_render__() {
|
|
|
12200
12176
|
"dominio": _vm.dominio
|
|
12201
12177
|
},
|
|
12202
12178
|
on: {
|
|
12203
|
-
"abrir-imagem": _vm.abrirImagem
|
|
12179
|
+
"abrir-imagem": _vm.abrirImagem,
|
|
12180
|
+
"download-all": function downloadAll($event) {
|
|
12181
|
+
return _vm.$emit('download-all');
|
|
12182
|
+
}
|
|
12204
12183
|
}
|
|
12205
12184
|
})], 1);
|
|
12206
12185
|
}) : _vm._e(), _vm._v(" "), _vm.urlSticker ? _c('img', {
|
|
@@ -12445,7 +12424,7 @@ var __vue_staticRenderFns__$5 = [];
|
|
|
12445
12424
|
|
|
12446
12425
|
var __vue_inject_styles__$5 = function __vue_inject_styles__(inject) {
|
|
12447
12426
|
if (!inject) return;
|
|
12448
|
-
inject("data-v-
|
|
12427
|
+
inject("data-v-4d7ba00c_0", {
|
|
12449
12428
|
source: ":root{--message-color:#373737;--text-color:#FFF;--light:80;--threshold:60}.fade-enter-active,.fade-leave-active{transition:opacity .5s}.fade-enter,.fade-leave-to{opacity:0}.mensagem{padding:14px 7px;border-radius:5px;min-width:150px;min-height:60px;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;position:relative;max-width:80%;margin-bottom:10px;font-size:.75rem;word-break:break-word;-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)}.mensagem.max-w-60{max-width:60%}.mensagem.mapa{width:100%}.mensagem.hist-msg{animation:show 1s}.mensagem a{margin-right:5px;font-weight:550;color:inherit;text-decoration:none}.mensagem a:hover{text-decoration:underline}.message p{white-space:pre-wrap}.mensagem-anexo a,.mensagem-div-mapa a{white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.reply{cursor:pointer;position:absolute;right:53px;bottom:5px;font-size:.6rem;color:#67a332;width:.9rem;height:.9rem;display:flex;justify-content:center;align-items:center;border-radius:50%;background-color:#fff}.reply svg{margin-top:-1px;margin-right:-1px}.reply-with-2-icons{right:30px}.check{cursor:pointer;position:absolute;right:10px;bottom:2px;font-size:.7rem}.check.visualizado,.check.visualizado svg{color:#006daa}.check.verde,.check.verde svg{color:#4f772d}.check.vermelho,.check.vermelho svg{color:#ba181b}.check.cinza,.check.cinza svg{color:#999}.check.preto,.check.preto svg{color:#666}.star{cursor:pointer;position:absolute;right:30px;bottom:2px;font-size:.4rem;width:11.2px}.default-stick-size{width:180px;height:auto}.horario-envio{margin-right:15px;font-size:.7rem;position:absolute;left:10px;bottom:2px}.autor-mensagem{position:absolute;font-size:.6rem;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;max-width:90%;font-weight:700;top:2px}.mensagem__principal{width:100%;display:flex;justify-content:flex-end}.mensagem__principal>.mensagem::after{content:\"\";width:0;height:0;position:absolute;border-left:10px solid transparent;border-right:10px solid transparent;border-top:10px solid var(--message-color);bottom:5px;right:-10px;transform:rotate(-90deg)}.mensagem__principal>.mensagem{background-color:var(--message-color);color:var(--text-color)}.mensagem__principal>.mensagem .horario-envio{color:var(--text-color)}.mensagem__principal>.mensagem .autor-mensagem{right:5px;color:var(--text-color)}.mensagem__outros{width:100%;display:flex}.mensagem__outros>.mensagem{background-color:#fff;color:#333}.mensagem__outros>.mensagem::after{content:\"\";width:0;height:0;position:absolute;border-left:10px solid transparent;border-right:10px solid transparent;border-top:10px solid #fff;bottom:5px;left:-10px;transform:rotate(90deg)}.mensagem__outros>.autor-mensagem{left:5px;color:#333}.mensagem-div-mapa{width:100%;display:flex;justify-content:center;align-items:center;flex-direction:column;margin-bottom:5px}.msg-mapa{width:100%;min-height:225px;height:100%;box-sizing:initial}.msg-mapa img{max-width:none!important}.info-mapa{list-style-type:none}.info-mapa li.title{font-size:.85em}.info-mapa li.address,.info-mapa li.url{font-size:.85em}.info-mapa li.url{font-size:.85em}.tooltip-list{margin:0;padding:0;display:flex;flex-direction:column;justify-content:center;align-items:flex-start}",
|
|
12450
12429
|
map: undefined,
|
|
12451
12430
|
media: undefined
|
|
@@ -12457,7 +12436,7 @@ var __vue_inject_styles__$5 = function __vue_inject_styles__(inject) {
|
|
|
12457
12436
|
var __vue_scope_id__$5 = undefined;
|
|
12458
12437
|
/* module identifier */
|
|
12459
12438
|
|
|
12460
|
-
var __vue_module_identifier__$5 = "data-v-
|
|
12439
|
+
var __vue_module_identifier__$5 = "data-v-4d7ba00c";
|
|
12461
12440
|
/* functional template */
|
|
12462
12441
|
|
|
12463
12442
|
var __vue_is_functional_template__$5 = false;
|
package/package.json
CHANGED
|
@@ -1,43 +1,41 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="mensagem-div-anexo">
|
|
3
|
-
<
|
|
4
|
-
<
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
3
|
+
<div class="anexo-mensagem">
|
|
4
|
+
<img v-if="imageURL" @click="showImage(imageURL)" :src="imageURL" :alt="dictionary.alt_msg_img">
|
|
5
|
+
<audio v-else-if="audio" controls>
|
|
6
|
+
<source :src="docURL" :type="fileType" />
|
|
7
|
+
Sem suporte para o elemento audio
|
|
8
|
+
</audio>
|
|
9
|
+
<video v-else-if="video" controls>
|
|
10
|
+
<source :src="docURL" :type="fileType" />
|
|
11
|
+
Sem suporte para o elemento video
|
|
12
|
+
</video>
|
|
13
|
+
<a v-else-if="docURL" :href="docURL" target="_blank" rel="noreferrer noopener" class="default-doc">
|
|
14
|
+
<fa-icon :class="[iconClass]" :icon="icon" />
|
|
15
|
+
<p v-text="filename" :title="filename"></p>
|
|
16
|
+
</a>
|
|
17
|
+
<span v-else class="default-doc">
|
|
18
|
+
<fa-icon :class="[iconClass ? iconClass : '']" :icon="['fas', 'file-alt']" />
|
|
19
|
+
<p v-text="filename" :title="filename"></p>
|
|
20
|
+
</span>
|
|
21
|
+
<!-- Acoes -->
|
|
22
|
+
<div class="file-actions">
|
|
23
|
+
<span v-if="imageURL" class="file-action-button" @click="showImage(imageURL)">
|
|
24
|
+
<fa-icon :icon="['fas', 'search-plus']" v-tippy :content="`${dictionary.titulo_visualizar_img}`" />
|
|
25
|
+
</span>
|
|
26
|
+
<a v-if="docURL" :href="docURL" target="_blank" rel="noreferrer noopener" v-tippy :content="`Visualizar anexo`" class="file-action-button">
|
|
27
|
+
<fa-icon :icon="['fas', 'search-plus']" />
|
|
28
|
+
</a>
|
|
29
|
+
<a v-if="imageURL || docURL" :href="imageURL ? imageURL : docURL" :download="`${filename}`" target="_blank" rel="noreferrer noopener" v-tippy :content="`Fazer o download do anexo`" class="file-action-button">
|
|
30
|
+
<fa-icon :icon="['fas', 'download']" />
|
|
31
|
+
</a>
|
|
32
|
+
<span class="file-action-button" v-tippy :content="`Fazer download de todos anexos da tela`" @click="downloadAllFilesHandler">
|
|
33
|
+
<fa-icon :icon="['fas', 'download']" />
|
|
34
|
+
<fa-icon :icon="['fas', 'download']" />
|
|
35
|
+
<fa-icon :icon="['fas', 'download']" />
|
|
36
|
+
</span>
|
|
9
37
|
</div>
|
|
10
|
-
|
|
11
|
-
<div v-else key="anexo-mensagem" class="anexo-mensagem">
|
|
12
|
-
<img v-if="imageURL" @click="showImage(imageURL)" :src="imageURL" :alt="dictionary.alt_msg_img">
|
|
13
|
-
<div class="anexos-links-container" v-if="imageURL">
|
|
14
|
-
<a href="#" @click.prevent="showImage(imageURL)"> {{ dictionary.titulo_visualizar_img }} </a>
|
|
15
|
-
<fa-icon :icon="['fas', 'search-plus']" @click="showImage(imageURL)" />
|
|
16
|
-
</div>
|
|
17
|
-
<div v-else-if="docURL" class="anexo-container">
|
|
18
|
-
<template v-if="audio || video">
|
|
19
|
-
<audio v-if="audio" :src="docURL" controls :title="`${fileType} - ${filename}`">
|
|
20
|
-
<p> {{ dictionary.msg_erro_audio }} <a :href="docURL" target="_blank" rel="noreferrer noopener"> {{ dictionary.msg_abrir_audio }} </a> </p>
|
|
21
|
-
</audio>
|
|
22
|
-
<video v-if="video" :src="docURL" controls :title="`${fileType} - ${filename}`">
|
|
23
|
-
<p> {{ dictionary.msg_erro_video }} <a v-if="fileType != 'erro'" :href="docURL" target="_blank" rel="noreferrer noopener"> {{ dictionary.msg_abrir_video }} </a> </p>
|
|
24
|
-
</video>
|
|
25
|
-
</template>
|
|
26
|
-
<template v-else>
|
|
27
|
-
<a v-if="fileType != 'erro'" :href="docURL" target="_blank" rel="noreferrer noopener" :title="`${fileType} - ${filename}`">
|
|
28
|
-
<fa-icon :class="[iconClass]" :icon="icon" />
|
|
29
|
-
<p v-text="filename"></p>
|
|
30
|
-
</a>
|
|
31
|
-
<p v-else :title="`${fileType} - ${filename}`" class="arquivo-erro">
|
|
32
|
-
<fa-icon :icon="['fas', 'file-alt']" />
|
|
33
|
-
{{ filename }}
|
|
34
|
-
</p>
|
|
35
|
-
</template>
|
|
36
|
-
</div>
|
|
37
|
-
<a v-if="imageURL" :href="imageURL" :download="`${filename}`" target="_blank" rel="noreferrer noopener"> {{ dictionary.titulo_baixar_img }} <fa-icon :icon="['fas', 'download']" /> </a>
|
|
38
|
-
<a v-if="docURL" :href="docURL" :download="`${filename}`" target="_blank" rel="noreferrer noopener"> {{ dictionary.titulo_baixar_doc }} <fa-icon :icon="['fas', 'download']" /> </a>
|
|
39
|
-
</div>
|
|
40
|
-
</transition-group>
|
|
38
|
+
</div>
|
|
41
39
|
</div>
|
|
42
40
|
</template>
|
|
43
41
|
|
|
@@ -105,6 +103,73 @@ export default {
|
|
|
105
103
|
</script>
|
|
106
104
|
|
|
107
105
|
<style scoped>
|
|
106
|
+
.mensagem__principal .default-doc {
|
|
107
|
+
background-color: rgba(255, 255, 255, 0.1);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.mensagem__outros .default-doc {
|
|
111
|
+
background-color: rgba(100, 100, 100, 0.1);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.default-doc {
|
|
115
|
+
display: flex;
|
|
116
|
+
align-items: center;
|
|
117
|
+
padding: 10px;
|
|
118
|
+
border-radius: 5px;
|
|
119
|
+
width: 100%;
|
|
120
|
+
max-width: 100%;
|
|
121
|
+
}
|
|
122
|
+
.default-doc svg {
|
|
123
|
+
font-size: 1.2rem;
|
|
124
|
+
margin-right: 5px;
|
|
125
|
+
}
|
|
126
|
+
.default-doc p {
|
|
127
|
+
overflow: hidden;
|
|
128
|
+
text-overflow: ellipsis;
|
|
129
|
+
white-space: nowrap;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.file-actions {
|
|
133
|
+
display: flex;
|
|
134
|
+
justify-content: flex-end;
|
|
135
|
+
width: 100%;
|
|
136
|
+
padding: 5px;
|
|
137
|
+
}
|
|
138
|
+
.file-actions a {
|
|
139
|
+
margin-right: 0;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
.mensagem__principal .file-action-button {
|
|
143
|
+
background-color: rgba(255, 255, 255, 0.1);
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.mensagem__outros .file-action-button {
|
|
147
|
+
background-color: rgba(100, 100, 100, 0.1);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.mensagem__principal .file-action-button:hover {
|
|
151
|
+
background-color: rgba(255, 255, 255, 0.3);
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.mensagem__outros .file-action-button:hover {
|
|
155
|
+
background-color: rgba(100, 100, 100, 0.3);
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
.file-action-button {
|
|
159
|
+
display: flex;
|
|
160
|
+
justify-content: center;
|
|
161
|
+
align-items: center;
|
|
162
|
+
margin-left: 12px;
|
|
163
|
+
cursor: pointer;
|
|
164
|
+
padding: 5px;
|
|
165
|
+
border-radius: 5px;
|
|
166
|
+
transition: background-color 150ms ease-in-out;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.file-action-button a {
|
|
170
|
+
margin: 0
|
|
171
|
+
}
|
|
172
|
+
|
|
108
173
|
.fade-enter-active, .fade-leave-active {
|
|
109
174
|
transition: opacity .5s;
|
|
110
175
|
}
|
|
@@ -145,15 +210,19 @@ export default {
|
|
|
145
210
|
.anexo-container svg{
|
|
146
211
|
font-size: 2rem;
|
|
147
212
|
}
|
|
148
|
-
|
|
213
|
+
|
|
214
|
+
.anexo-mensagem audio{
|
|
149
215
|
outline: none;
|
|
150
216
|
width: 100%;
|
|
217
|
+
margin-bottom: 5px;
|
|
151
218
|
}
|
|
152
|
-
|
|
219
|
+
|
|
220
|
+
.anexo-mensagem video{
|
|
153
221
|
flex: 1;
|
|
154
222
|
width: 100%;
|
|
155
223
|
max-width: 350px;
|
|
156
224
|
cursor: pointer;
|
|
225
|
+
margin-bottom: 5px;
|
|
157
226
|
}
|
|
158
227
|
|
|
159
228
|
.anexos-links-container{
|
|
@@ -193,6 +262,7 @@ export default {
|
|
|
193
262
|
justify-content: center;
|
|
194
263
|
align-items: center;
|
|
195
264
|
flex-direction: column;
|
|
265
|
+
width: 100%;
|
|
196
266
|
}
|
|
197
267
|
|
|
198
268
|
.alert-danger {
|
|
@@ -222,4 +292,4 @@ export default {
|
|
|
222
292
|
.doc {
|
|
223
293
|
color: #006bc9
|
|
224
294
|
}
|
|
225
|
-
</style>
|
|
295
|
+
</style>
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
<div v-else class="mensagem" :class="{mapa, 'hist-msg' : histMsg, 'max-w-60' : link && !mapa}">
|
|
12
12
|
<template v-if="anexos && anexos.length">
|
|
13
13
|
<div class="mensagem-anexo" v-for="(anexo, index) in anexos" :key="index">
|
|
14
|
-
<AnexoMensagem :dictionary="dictionary" :anexo="anexo" :origemExterna="origemExterna" :dominio="dominio" @abrir-imagem="abrirImagem"/>
|
|
14
|
+
<AnexoMensagem :dictionary="dictionary" :anexo="anexo" :origemExterna="origemExterna" :dominio="dominio" @abrir-imagem="abrirImagem" @download-all="$emit('download-all')"/>
|
|
15
15
|
</div>
|
|
16
16
|
</template>
|
|
17
17
|
<img class="default-stick-size" v-if="urlSticker" :src="urlSticker" :title="urlFileName">
|
|
@@ -78,7 +78,10 @@ import LinkPreview from './LinkPreview'
|
|
|
78
78
|
|
|
79
79
|
export default {
|
|
80
80
|
components: { AnexoMensagem, InteratividadeBotoes, InteratividadeFormulario, LinkPreview },
|
|
81
|
-
props: ["smartchannel", "messageIndex", "dictionary", "autor", "origem", "msg", "link", "anexo", "imgAnexo", "tipoDoc", "docAnexo", "nomeArquivo", "audio", "video", "horario", "status", "logo", "msgTooltip", "seq", "mapa", "histMsg", "erro", "msgErro", "origemExterna", "anexos", "dominio", "corMsg", "interatividade", "msgReply", "hasReply", "iniDialogo", "dialogoId", "dialogoOrigem", "expSessao"],
|
|
81
|
+
props: ["smartchannel", "messageIndex", "dictionary", "autor", "origem", "msg", "link", "anexo", "imgAnexo", "tipoDoc", "docAnexo", "nomeArquivo", "audio", "video", "horario", "status", "logo", "msgTooltip", "seq", "mapa", "histMsg", "erro", "msgErro", "origemExterna", "anexos", "dominio", "corMsg", "interatividade", "msgReply", "hasReply", "iniDialogo", "dialogoId", "dialogoOrigem", "expSessao", "referenceSelector"],
|
|
82
|
+
created() {
|
|
83
|
+
if(!this.$root.$refs.chatMessages) this.$root.$refs.chatMessages = this
|
|
84
|
+
},
|
|
82
85
|
data(){
|
|
83
86
|
return{
|
|
84
87
|
strTooltipAux: "",
|