vue-intergrall-plugins 1.1.90 → 1.2.18

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.
Files changed (46) hide show
  1. package/README.md +220 -220
  2. package/dist/dist/vue-intergrall-plugins.css +1 -1
  3. package/dist/vue-intergrall-plugins.esm.js +223 -89
  4. package/dist/vue-intergrall-plugins.min.js +11 -11
  5. package/dist/vue-intergrall-plugins.ssr.js +276 -147
  6. package/package.json +1 -1
  7. package/src/lib-components/Buttons/IconButton.vue +27 -27
  8. package/src/lib-components/Buttons/SimpleButton.vue +140 -140
  9. package/src/lib-components/Cards/Card.vue +490 -490
  10. package/src/lib-components/Cards/CardCheck.vue +35 -35
  11. package/src/lib-components/Cards/CardFile.vue +163 -163
  12. package/src/lib-components/Chat/BtnDownloadAllFiles.vue +36 -36
  13. package/src/lib-components/Chat/BtnEmojis.vue +118 -118
  14. package/src/lib-components/Chat/BtnExpand.vue +17 -17
  15. package/src/lib-components/Chat/BtnFiles.vue +486 -486
  16. package/src/lib-components/Chat/BtnMic.vue +60 -60
  17. package/src/lib-components/Chat/BtnScreenShare.vue +31 -31
  18. package/src/lib-components/Chat/BtnStandardMessages.vue +17 -17
  19. package/src/lib-components/Chat/ExpandTextarea.vue +427 -427
  20. package/src/lib-components/Chat/MultipleFilePreview.vue +291 -291
  21. package/src/lib-components/Chat/Picker.vue +525 -525
  22. package/src/lib-components/Chat/RemainingCharacters.vue +28 -28
  23. package/src/lib-components/Chat/SingleFilePreview.vue +94 -94
  24. package/src/lib-components/Chat/SkeletonPicker.vue +110 -110
  25. package/src/lib-components/Chat/StandardMessages.vue +252 -252
  26. package/src/lib-components/Chat/TextFooter.vue +1007 -1007
  27. package/src/lib-components/Email/EmailExpanded.vue +270 -270
  28. package/src/lib-components/Email/EmailFile.vue +192 -192
  29. package/src/lib-components/Email/EmailFrom.vue +66 -66
  30. package/src/lib-components/Email/EmailItem.vue +867 -850
  31. package/src/lib-components/Email/EmailTo.vue +64 -64
  32. package/src/lib-components/Loader/Loader.vue +78 -78
  33. package/src/lib-components/Messages/AnexoMensagem.vue +625 -497
  34. package/src/lib-components/Messages/CardAttachment.vue +61 -61
  35. package/src/lib-components/Messages/CardMessages.vue +687 -687
  36. package/src/lib-components/Messages/ChatMessages.vue +259 -78
  37. package/src/lib-components/Messages/InteratividadeBotoes.vue +197 -197
  38. package/src/lib-components/Messages/InteratividadeContato.vue +32 -32
  39. package/src/lib-components/Messages/InteratividadeContatoItem.vue +235 -235
  40. package/src/lib-components/Messages/InteratividadeFormulario.vue +334 -334
  41. package/src/lib-components/Messages/InteratividadePopup.vue +95 -95
  42. package/src/lib-components/Messages/LinkPreview.vue +176 -176
  43. package/src/lib-components/Scroll/ScrollContent.vue +166 -166
  44. package/src/lib-components/Templates/TemplateGenerator.vue +640 -640
  45. package/src/lib-components/Templates/TemplateMessage.vue +83 -83
  46. package/src/lib-components/Templates/TemplateSingle.vue +478 -478
@@ -1,197 +1,197 @@
1
- <template>
2
- <div class="interatividade">
3
- <div v-if="
4
- interatividade &&
5
- interatividade.parameters &&
6
- interatividade.parameters.button &&
7
- interatividade.parameters.button.length
8
- ">
9
- <div v-for="(button, index) in interatividade.parameters.button" :key="index" class="interatividade-btn">
10
- <p v-if="!button.url" v-html="button.text" class="interatividade-titulo"></p>
11
- <a v-else :href="button.url" target="_blank" rel="noreferrer noopener" class="interatividade-link">
12
- <p v-html="button.text" class="interatividade-titulo"></p>
13
- <fa-icon :icon="['fas', 'external-link-square-alt']" />
14
- </a>
15
- </div>
16
- </div>
17
-
18
- <!-- Tudo aqui abaixo TEORICAMENTE e antigo e nao devera mais cair nas situacoes -->
19
- <div v-if="
20
- interatividade &&
21
- interatividade.parameters &&
22
- interatividade.parameters.button &&
23
- (interatividade.parameters.button.type === 'dynamicURL' ||
24
- interatividade.parameters.button.type === 'staticURL')
25
- " class="interatividade-btn">
26
- <a :href="interatividade.parameters.button.text" target="_blank" rel="noreferrer noopener"
27
- class="interatividade-link">
28
- Acessar <fa-icon :icon="['fas', 'external-link-square-alt']" />
29
- </a>
30
- </div>
31
- <div v-if="
32
- interatividade &&
33
- interatividade.parameters &&
34
- interatividade.parameters.button &&
35
- interatividade.parameters.button.type === 'phoneNumber'
36
- " class="interatividade-btn">
37
- <p class="interatividade-titulo"
38
- :title="`${interatividade.parameters.button.text} (${interatividade.parameters.button.phoneNumber})`" v-text="`${interatividade.parameters.button.text} (${interatividade.parameters.button.phoneNumber})`
39
- "></p>
40
- </div>
41
- <div v-if="
42
- interatividade &&
43
- interatividade.parameters &&
44
- interatividade.parameters.button &&
45
- interatividade.parameters.button.type === 'quickReply'
46
- " class="interatividade-btn">
47
- <p class="interatividade-titulo" :title="`${interatividade.parameters.button.text}`"
48
- v-text="`${interatividade.parameters.button.text}`"></p>
49
- </div>
50
- <transition name="show-x">
51
- <InteratividadePopup v-if="listaEstaAberta" :lista="listaExpandida" :titulo="objItens.list.title"
52
- @close="listaEstaAberta = false" />
53
- </transition>
54
- <template v-if="arrBotoes.length">
55
- <div v-for="(btn, index) in arrBotoes" :key="index" :title="btn.titulo" class="interatividade-btn">
56
- <p v-html="btn.titulo" class="interatividade-titulo"></p>
57
- </div>
58
- </template>
59
- <template v-else-if="Object.keys(objItens).length">
60
- <div class="interatividade-lista" :class="tipoBotoes == 'listItem' ? 'bg-none' : ''">
61
- <div class="interatividade-lista-conteudo"
62
- :class="tipoBotoes == 'listItem' ? 'border-bottom-none padding-none' : ''">
63
- <p v-if="objItens.header && objItens.header.text" v-html="objItens.header.text"
64
- class="interatividade-lista-titulo"></p>
65
- <p v-if="objItens.body && objItens.body.text" v-html="objItens.body.text" class="interatividade-lista-corpo">
66
- </p>
67
- <p v-if="objItens.footer && objItens.footer.text" v-html="objItens.footer.text"
68
- class="interatividade-lista-rodape"></p>
69
- </div>
70
- <p v-if="objItens.list && objItens.list.title" v-html="objItens.list.title" @click="expandirLista"
71
- :class="tipoBotoes == 'listItem' ? 'bg-white border-radius-5 mt-5' : ''" class="interatividade-lista-link">
72
- </p>
73
- </div>
74
- </template>
75
- </div>
76
- </template>
77
-
78
- <script>
79
- import InteratividadePopup from "./InteratividadePopup";
80
-
81
- export default {
82
- components: { InteratividadePopup },
83
- data() {
84
- return {
85
- listaEstaAberta: false,
86
- };
87
- },
88
- props: {
89
- interatividade: {
90
- type: Object,
91
- required: true,
92
- },
93
- },
94
- computed: {
95
- tipoBotoes() {
96
- return this.interatividade.tipo;
97
- },
98
- arrBotoes() {
99
- const { botoes } = this.interatividade;
100
- return botoes ? botoes : [];
101
- },
102
- objItens() {
103
- const { itens } = this.interatividade;
104
- return itens ? itens : {};
105
- },
106
- listaExpandida() {
107
- try {
108
- const { list } = this.objItens;
109
- const { sections } = list;
110
- return sections ? sections : [];
111
- } catch (e) {
112
- console.error("Erro ao definir a lista a ser expandida");
113
- console.error(e);
114
- return [];
115
- }
116
- },
117
- },
118
- methods: {
119
- expandirLista() {
120
- this.listaEstaAberta = !this.listaEstaAberta;
121
- },
122
- },
123
- };
124
- </script>
125
-
126
- <style>
127
- .interatividade-btn {
128
- display: flex;
129
- justify-content: center;
130
- align-items: center;
131
- background-color: #fff;
132
- color: #111b21;
133
- padding: 10px 12px;
134
- border-radius: 5px;
135
- margin-bottom: 10px;
136
- }
137
-
138
- .interatividade-link {
139
- color: #0c5c8f !important;
140
- text-decoration: none;
141
- display: flex;
142
- align-items: center;
143
- justify-content: center;
144
- width: 100%;
145
- gap: 5px;
146
- }
147
-
148
- .interatividade-btn:nth-child(1) {
149
- margin-top: 10px;
150
- }
151
-
152
- .interatividade-titulo {
153
- white-space: nowrap;
154
- text-overflow: ellipsis;
155
- overflow: hidden;
156
- max-width: 100%;
157
- margin: 0;
158
- padding: 0;
159
- }
160
-
161
- .interatividade-lista {
162
- width: 100%;
163
- min-width: 200px;
164
- border-radius: 15px;
165
- background-color: #fff;
166
- color: #333;
167
- margin: 10px 0;
168
- }
169
-
170
- .interatividade-lista-conteudo {
171
- padding: 10px;
172
- border-bottom: 1px solid #d7d7d7;
173
- }
174
-
175
- .interatividade-lista-titulo {
176
- font-weight: bold;
177
- font-size: 19.2px;
178
- margin-bottom: 10px;
179
- }
180
-
181
- .interatividade-lista-rodape {
182
- color: #818181;
183
- margin-top: 5px;
184
- }
185
-
186
- .interatividade-lista-link {
187
- text-align: center;
188
- padding: 10px;
189
- color: rgb(0, 110, 255);
190
- cursor: pointer;
191
- transition: color 200ms ease-in-out;
192
- }
193
-
194
- .interatividade-lista-link:hover {
195
- color: rgb(0, 98, 143);
196
- }
197
- </style>
1
+ <template>
2
+ <div class="interatividade">
3
+ <div v-if="
4
+ interatividade &&
5
+ interatividade.parameters &&
6
+ interatividade.parameters.button &&
7
+ interatividade.parameters.button.length
8
+ ">
9
+ <div v-for="(button, index) in interatividade.parameters.button" :key="index" class="interatividade-btn">
10
+ <p v-if="!button.url" v-html="button.text" class="interatividade-titulo"></p>
11
+ <a v-else :href="button.url" target="_blank" rel="noreferrer noopener" class="interatividade-link">
12
+ <p v-html="button.text" class="interatividade-titulo"></p>
13
+ <fa-icon :icon="['fas', 'external-link-square-alt']" />
14
+ </a>
15
+ </div>
16
+ </div>
17
+
18
+ <!-- Tudo aqui abaixo TEORICAMENTE e antigo e nao devera mais cair nas situacoes -->
19
+ <div v-if="
20
+ interatividade &&
21
+ interatividade.parameters &&
22
+ interatividade.parameters.button &&
23
+ (interatividade.parameters.button.type === 'dynamicURL' ||
24
+ interatividade.parameters.button.type === 'staticURL')
25
+ " class="interatividade-btn">
26
+ <a :href="interatividade.parameters.button.text" target="_blank" rel="noreferrer noopener"
27
+ class="interatividade-link">
28
+ Acessar <fa-icon :icon="['fas', 'external-link-square-alt']" />
29
+ </a>
30
+ </div>
31
+ <div v-if="
32
+ interatividade &&
33
+ interatividade.parameters &&
34
+ interatividade.parameters.button &&
35
+ interatividade.parameters.button.type === 'phoneNumber'
36
+ " class="interatividade-btn">
37
+ <p class="interatividade-titulo"
38
+ :title="`${interatividade.parameters.button.text} (${interatividade.parameters.button.phoneNumber})`" v-text="`${interatividade.parameters.button.text} (${interatividade.parameters.button.phoneNumber})`
39
+ "></p>
40
+ </div>
41
+ <div v-if="
42
+ interatividade &&
43
+ interatividade.parameters &&
44
+ interatividade.parameters.button &&
45
+ interatividade.parameters.button.type === 'quickReply'
46
+ " class="interatividade-btn">
47
+ <p class="interatividade-titulo" :title="`${interatividade.parameters.button.text}`"
48
+ v-text="`${interatividade.parameters.button.text}`"></p>
49
+ </div>
50
+ <transition name="show-x">
51
+ <InteratividadePopup v-if="listaEstaAberta" :lista="listaExpandida" :titulo="objItens.list.title"
52
+ @close="listaEstaAberta = false" />
53
+ </transition>
54
+ <template v-if="arrBotoes.length">
55
+ <div v-for="(btn, index) in arrBotoes" :key="index" :title="btn.titulo" class="interatividade-btn">
56
+ <p v-html="btn.titulo" class="interatividade-titulo"></p>
57
+ </div>
58
+ </template>
59
+ <template v-else-if="Object.keys(objItens).length">
60
+ <div class="interatividade-lista" :class="tipoBotoes == 'listItem' ? 'bg-none' : ''">
61
+ <div class="interatividade-lista-conteudo"
62
+ :class="tipoBotoes == 'listItem' ? 'border-bottom-none padding-none' : ''">
63
+ <p v-if="objItens.header && objItens.header.text" v-html="objItens.header.text"
64
+ class="interatividade-lista-titulo"></p>
65
+ <p v-if="objItens.body && objItens.body.text" v-html="objItens.body.text" class="interatividade-lista-corpo">
66
+ </p>
67
+ <p v-if="objItens.footer && objItens.footer.text" v-html="objItens.footer.text"
68
+ class="interatividade-lista-rodape"></p>
69
+ </div>
70
+ <p v-if="objItens.list && objItens.list.title" v-html="objItens.list.title" @click="expandirLista"
71
+ :class="tipoBotoes == 'listItem' ? 'bg-white border-radius-5 mt-5' : ''" class="interatividade-lista-link">
72
+ </p>
73
+ </div>
74
+ </template>
75
+ </div>
76
+ </template>
77
+
78
+ <script>
79
+ import InteratividadePopup from "./InteratividadePopup";
80
+
81
+ export default {
82
+ components: { InteratividadePopup },
83
+ data() {
84
+ return {
85
+ listaEstaAberta: false,
86
+ };
87
+ },
88
+ props: {
89
+ interatividade: {
90
+ type: Object,
91
+ required: true,
92
+ },
93
+ },
94
+ computed: {
95
+ tipoBotoes() {
96
+ return this.interatividade.tipo;
97
+ },
98
+ arrBotoes() {
99
+ const { botoes } = this.interatividade;
100
+ return botoes ? botoes : [];
101
+ },
102
+ objItens() {
103
+ const { itens } = this.interatividade;
104
+ return itens ? itens : {};
105
+ },
106
+ listaExpandida() {
107
+ try {
108
+ const { list } = this.objItens;
109
+ const { sections } = list;
110
+ return sections ? sections : [];
111
+ } catch (e) {
112
+ console.error("Erro ao definir a lista a ser expandida");
113
+ console.error(e);
114
+ return [];
115
+ }
116
+ },
117
+ },
118
+ methods: {
119
+ expandirLista() {
120
+ this.listaEstaAberta = !this.listaEstaAberta;
121
+ },
122
+ },
123
+ };
124
+ </script>
125
+
126
+ <style>
127
+ .interatividade-btn {
128
+ display: flex;
129
+ justify-content: center;
130
+ align-items: center;
131
+ background-color: #fff;
132
+ color: #111b21;
133
+ padding: 10px 12px;
134
+ border-radius: 5px;
135
+ margin-bottom: 10px;
136
+ }
137
+
138
+ .interatividade-link {
139
+ color: #0c5c8f !important;
140
+ text-decoration: none;
141
+ display: flex;
142
+ align-items: center;
143
+ justify-content: center;
144
+ width: 100%;
145
+ gap: 5px;
146
+ }
147
+
148
+ .interatividade-btn:nth-child(1) {
149
+ margin-top: 10px;
150
+ }
151
+
152
+ .interatividade-titulo {
153
+ white-space: nowrap;
154
+ text-overflow: ellipsis;
155
+ overflow: hidden;
156
+ max-width: 100%;
157
+ margin: 0;
158
+ padding: 0;
159
+ }
160
+
161
+ .interatividade-lista {
162
+ width: 100%;
163
+ min-width: 200px;
164
+ border-radius: 15px;
165
+ background-color: #fff;
166
+ color: #333;
167
+ margin: 10px 0;
168
+ }
169
+
170
+ .interatividade-lista-conteudo {
171
+ padding: 10px;
172
+ border-bottom: 1px solid #d7d7d7;
173
+ }
174
+
175
+ .interatividade-lista-titulo {
176
+ font-weight: bold;
177
+ font-size: 19.2px;
178
+ margin-bottom: 10px;
179
+ }
180
+
181
+ .interatividade-lista-rodape {
182
+ color: #818181;
183
+ margin-top: 5px;
184
+ }
185
+
186
+ .interatividade-lista-link {
187
+ text-align: center;
188
+ padding: 10px;
189
+ color: rgb(0, 110, 255);
190
+ cursor: pointer;
191
+ transition: color 200ms ease-in-out;
192
+ }
193
+
194
+ .interatividade-lista-link:hover {
195
+ color: rgb(0, 98, 143);
196
+ }
197
+ </style>
@@ -1,32 +1,32 @@
1
- <template>
2
- <div>
3
- <InteratividadeContatoItem v-for="(item, index) in interatividade" :key="index" :item="item"
4
- :dictionary="dictionary" :emitContactClick="emitContactClick" @contact-click="emitData" />
5
- </div>
6
- </template>
7
- <script>
8
- import InteratividadeContatoItem from "./InteratividadeContatoItem";
9
-
10
- export default {
11
- components: { InteratividadeContatoItem },
12
- props: {
13
- interatividade: {
14
- type: Array,
15
- required: true,
16
- },
17
- dictionary: {
18
- type: Object,
19
- required: true,
20
- },
21
- emitContactClick: {
22
- type: Boolean,
23
- default: false,
24
- }
25
- },
26
- methods: {
27
- emitData(props) {
28
- this.$emit("contact-click", props);
29
- }
30
- }
31
- };
32
- </script>
1
+ <template>
2
+ <div>
3
+ <InteratividadeContatoItem v-for="(item, index) in interatividade" :key="index" :item="item"
4
+ :dictionary="dictionary" :emitContactClick="emitContactClick" @contact-click="emitData" />
5
+ </div>
6
+ </template>
7
+ <script>
8
+ import InteratividadeContatoItem from "./InteratividadeContatoItem";
9
+
10
+ export default {
11
+ components: { InteratividadeContatoItem },
12
+ props: {
13
+ interatividade: {
14
+ type: Array,
15
+ required: true,
16
+ },
17
+ dictionary: {
18
+ type: Object,
19
+ required: true,
20
+ },
21
+ emitContactClick: {
22
+ type: Boolean,
23
+ default: false,
24
+ }
25
+ },
26
+ methods: {
27
+ emitData(props) {
28
+ this.$emit("contact-click", props);
29
+ }
30
+ }
31
+ };
32
+ </script>