vue-intergrall-plugins 0.0.142 → 0.0.146

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.
@@ -6523,6 +6523,9 @@ var script$3 = {
6523
6523
  return {
6524
6524
  strTooltipAux: "",
6525
6525
  linkAux: "",
6526
+ urlSticker: "",
6527
+ urlFileName: "",
6528
+ message: "",
6526
6529
  reply: "reply",
6527
6530
  center: {},
6528
6531
  marker: {},
@@ -6582,8 +6585,39 @@ var script$3 = {
6582
6585
  if (this.mapa) this.setMap();
6583
6586
  if (this.corMsg) this.setCorMsg();
6584
6587
  this.setClasses();
6588
+ this.validadeUrlToMsg();
6585
6589
  },
6586
6590
  methods: {
6591
+ validadeUrlToMsg: function validadeUrlToMsg() {
6592
+ this.message = this.msg;
6593
+
6594
+ if (this.validadeIfExistsSticker()) {
6595
+ this.urlSticker = this.getUrlSticker();
6596
+ this.urlFileName = this.getUrlFileName();
6597
+ this.message = this.removeUrlStickerByString(this.urlSticker);
6598
+ }
6599
+ },
6600
+ getUrlFileName: function getUrlFileName() {
6601
+ var urlRegex = /(?<=\/)[^\/\?#]+(?=[^\/]*$)/;
6602
+ var urlName = this.urlSticker.match(urlRegex)[0];
6603
+ return urlName;
6604
+ },
6605
+ removeUrlStickerByString: function removeUrlStickerByString(url) {
6606
+ var msg = this.message.replace("KSTICKERK ".concat(url), '');
6607
+ return msg;
6608
+ },
6609
+ getUrlSticker: function getUrlSticker() {
6610
+ var urlRegex = /(https?:\/\/[^ ]*)/;
6611
+ var url = this.message.match(urlRegex)[1];
6612
+ return url;
6613
+ },
6614
+ validadeIfExistsSticker: function validadeIfExistsSticker() {
6615
+ if (this.message && this.message.indexOf("KSTICKERK https://smarters") === 0) {
6616
+ return true;
6617
+ }
6618
+
6619
+ return false;
6620
+ },
6587
6621
  setClasses: function setClasses() {
6588
6622
  if (this.hasReply && (this.status == "C" || this.status == "T") && this.iniDialogo == 0) {
6589
6623
  this.reply = "reply reply-with-2-icons";
@@ -6665,7 +6699,7 @@ var __vue_render__$3 = function __vue_render__() {
6665
6699
  "abrir-imagem": _vm.abrirImagem
6666
6700
  }
6667
6701
  })], 1);
6668
- }) : _vm._e(), _vm._ssrNode(" "), _vm.mapa ? _vm._ssrNode("<div class=\"mensagem-div-mapa\">", "</div>", [_c('GmapMap', {
6702
+ }) : _vm._e(), _vm._ssrNode(" " + (_vm.urlSticker ? "<img" + _vm._ssrAttr("src", _vm.urlSticker) + _vm._ssrAttr("title", _vm.urlFileName) + " class=\"default-stick-size\">" : "<!---->") + " "), _vm.mapa ? _vm._ssrNode("<div class=\"mensagem-div-mapa\">", "</div>", [_c('GmapMap', {
6669
6703
  staticClass: "msg-mapa",
6670
6704
  attrs: {
6671
6705
  "id": "mapa_" + _vm.seq,
@@ -6683,7 +6717,7 @@ var __vue_render__$3 = function __vue_render__() {
6683
6717
  "icon": ['fas', 'map-marker-alt']
6684
6718
  }
6685
6719
  })], 2)], 2);
6686
- }), 0) : _vm._e()], 2) : _vm._e(), _vm._ssrNode(" <p>" + _vm._s(_vm.formatMsg(_vm.msg)) + "</p> "), _vm.interatividade ? _c('InteratividadeBotoes', {
6720
+ }), 0) : _vm._e()], 2) : _vm._e(), _vm._ssrNode(" <p>" + _vm._s(_vm.formatMsg(_vm.message)) + "</p> "), _vm.interatividade ? _c('InteratividadeBotoes', {
6687
6721
  attrs: {
6688
6722
  "interatividade": _vm.interatividade
6689
6723
  }
@@ -6840,8 +6874,8 @@ var __vue_staticRenderFns__$3 = [];
6840
6874
 
6841
6875
  var __vue_inject_styles__$3 = function __vue_inject_styles__(inject) {
6842
6876
  if (!inject) return;
6843
- inject("data-v-c1e72e34_0", {
6844
- source: ":root{--message-color:#373737}.fade-enter-active,.fade-leave-active{transition:opacity .5s}.fade-enter,.fade-leave-to{opacity:0}.mensagem{padding:14px 7px;border-radius:2.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:.85rem;word-break:break-word}.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:3px;font-size:.7rem}.star.dourado svg{color:gold}.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:#fff}.mensagem__principal>.mensagem .horario-envio{color:#fff}.mensagem__principal>.mensagem .autor-mensagem{right:5px;color:#fff}.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 .check{display:none}.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:.7em}.info-mapa li.url{font-size:.7em}.tooltip-list{margin:0;padding:0;display:flex;flex-direction:column;justify-content:center;align-items:flex-start}",
6877
+ inject("data-v-6c90394f_0", {
6878
+ source: ":root{--message-color:#373737}.fade-enter-active,.fade-leave-active{transition:opacity .5s}.fade-enter,.fade-leave-to{opacity:0}.mensagem{padding:14px 7px;border-radius:2.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:.85rem;word-break:break-word}.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:3px;font-size:.7rem}.star.dourado svg{color:gold}.default-stick-size{width:250px;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:#fff}.mensagem__principal>.mensagem .horario-envio{color:#fff}.mensagem__principal>.mensagem .autor-mensagem{right:5px;color:#fff}.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 .check{display:none}.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:.7em}.info-mapa li.url{font-size:.7em}.tooltip-list{margin:0;padding:0;display:flex;flex-direction:column;justify-content:center;align-items:flex-start}",
6845
6879
  map: undefined,
6846
6880
  media: undefined
6847
6881
  });
@@ -6852,7 +6886,7 @@ var __vue_inject_styles__$3 = function __vue_inject_styles__(inject) {
6852
6886
  var __vue_scope_id__$3 = undefined;
6853
6887
  /* module identifier */
6854
6888
 
6855
- var __vue_module_identifier__$3 = "data-v-c1e72e34";
6889
+ var __vue_module_identifier__$3 = "data-v-6c90394f";
6856
6890
  /* functional template */
6857
6891
 
6858
6892
  var __vue_is_functional_template__$3 = false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vue-intergrall-plugins",
3
- "version": "0.0.142",
3
+ "version": "0.0.146",
4
4
  "description": "",
5
5
  "main": "dist/vue-intergrall-plugins.ssr.js",
6
6
  "browser": "dist/vue-intergrall-plugins.esm.js",
@@ -6,6 +6,7 @@
6
6
  <AnexoMensagem :dictionary="dictionary" :anexo="anexo" :origemExterna="origemExterna" :dominio="dominio" @abrir-imagem="abrirImagem"/>
7
7
  </div>
8
8
  </template>
9
+ <img class="default-stick-size" v-if="urlSticker" :src="urlSticker" :title="urlFileName">
9
10
  <div v-if="mapa" class="mensagem-div-mapa">
10
11
  <GmapMap
11
12
  :id="`mapa_${seq}`"
@@ -23,7 +24,7 @@
23
24
  </li>
24
25
  </ul>
25
26
  </div>
26
- <p v-html="formatMsg(msg)"></p>
27
+ <p v-html="formatMsg(message)"></p>
27
28
  <InteratividadeBotoes
28
29
  v-if="interatividade"
29
30
  :interatividade="interatividade"
@@ -62,6 +63,9 @@ export default {
62
63
  return{
63
64
  strTooltipAux: "",
64
65
  linkAux: "",
66
+ urlSticker: "",
67
+ urlFileName: "",
68
+ message: "",
65
69
  reply: "reply",
66
70
  center: {},
67
71
  marker: {},
@@ -119,8 +123,37 @@ export default {
119
123
  if(this.mapa) this.setMap()
120
124
  if(this.corMsg) this.setCorMsg()
121
125
  this.setClasses()
126
+ this.validadeUrlToMsg()
122
127
  },
123
128
  methods: {
129
+ validadeUrlToMsg(){
130
+ this.message = this.msg
131
+ if(this.validadeIfExistsSticker()){
132
+ this.urlSticker = this.getUrlSticker()
133
+ this.urlFileName = this.getUrlFileName()
134
+ this.message = this.removeUrlStickerByString(this.urlSticker)
135
+ }
136
+ },
137
+ getUrlFileName(){
138
+ let urlRegex = /(?<=\/)[^\/\?#]+(?=[^\/]*$)/;
139
+ let urlName = this.urlSticker.match(urlRegex)[0];
140
+ return urlName;
141
+ },
142
+ removeUrlStickerByString(url){
143
+ let msg = this.message.replace(`KSTICKERK ${url}`, '')
144
+ return msg;
145
+ },
146
+ getUrlSticker(){
147
+ let urlRegex = /(https?:\/\/[^ ]*)/;
148
+ let url = this.message.match(urlRegex)[1];
149
+ return url;
150
+ },
151
+ validadeIfExistsSticker(){
152
+ if(this.message && this.message.indexOf("KSTICKERK https://smarters") === 0){
153
+ return true;
154
+ }
155
+ return false;
156
+ },
124
157
  setClasses(){
125
158
  if(this.hasReply && (this.status == "C" || this.status == "T") && this.iniDialogo == 0){
126
159
  this.reply = "reply reply-with-2-icons"
@@ -275,6 +308,10 @@ export default {
275
308
  .star.dourado svg{
276
309
  color: gold
277
310
  }
311
+ .default-stick-size{
312
+ width: 250px;
313
+ height: auto;
314
+ }
278
315
  .horario-envio {
279
316
  margin-right: 15px;
280
317
  font-size: 0.7rem;