@chat21/chat21-ionic 3.0.61-rc11 → 3.0.61-rc15

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 (53) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/angular.json +1 -0
  3. package/package.json +2 -1
  4. package/src/app/app-routing.module.ts +5 -0
  5. package/src/app/app.module.ts +6 -3
  6. package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.html +36 -25
  7. package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.scss +160 -50
  8. package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.ts +101 -18
  9. package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.html +21 -36
  10. package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.scss +19 -7
  11. package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.ts +35 -40
  12. package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component.scss +2 -0
  13. package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component.ts +28 -25
  14. package/src/app/components/conversation-detail/message-text-area/message-text-area.component.html +57 -20
  15. package/src/app/components/conversation-detail/message-text-area/message-text-area.component.scss +32 -9
  16. package/src/app/components/conversation-detail/message-text-area/message-text-area.component.ts +93 -24
  17. package/src/app/components/project-item/project-item.component.scss +1 -1
  18. package/src/app/components/sidebar/sidebar.component.html +36 -35
  19. package/src/app/components/sidebar/sidebar.component.ts +72 -26
  20. package/src/app/components/sidebar-user-details/sidebar-user-details.component.html +7 -0
  21. package/src/app/components/sidebar-user-details/sidebar-user-details.component.scss +13 -1
  22. package/src/app/components/sidebar-user-details/sidebar-user-details.component.ts +11 -7
  23. package/src/app/pages/conversation-detail/conversation-detail.module.ts +5 -1
  24. package/src/app/pages/conversation-detail/conversation-detail.page.html +19 -11
  25. package/src/app/pages/conversation-detail/conversation-detail.page.scss +28 -0
  26. package/src/app/pages/conversation-detail/conversation-detail.page.ts +221 -368
  27. package/src/app/pages/conversations-list/conversations-list.page.ts +6 -18
  28. package/src/app/pages/create-canned-response/create-canned-response-routing.module.ts +17 -0
  29. package/src/app/pages/create-canned-response/create-canned-response.module.ts +30 -0
  30. package/src/app/pages/create-canned-response/create-canned-response.page.html +150 -0
  31. package/src/app/pages/create-canned-response/create-canned-response.page.scss +55 -0
  32. package/src/app/pages/create-canned-response/create-canned-response.page.spec.ts +24 -0
  33. package/src/app/pages/create-canned-response/create-canned-response.page.ts +319 -0
  34. package/src/app/pages/create-requester/create-requester.page.html +1 -1
  35. package/src/app/pages/create-requester/create-requester.page.ts +1 -0
  36. package/src/app/pages/create-ticket/create-ticket.page.html +1 -1
  37. package/src/app/pages/create-ticket/create-ticket.page.ts +13 -4
  38. package/src/app/pages/profile-info/profile-info.page.html +2 -2
  39. package/src/app/pages/profile-info/profile-info.page.scss +12 -1
  40. package/src/app/services/tiledesk/tiledesk.service.ts +28 -0
  41. package/src/app/shared/shared.module.ts +1 -1
  42. package/src/assets/i18n/de.json +17 -3
  43. package/src/assets/i18n/en.json +17 -3
  44. package/src/assets/i18n/es.json +17 -3
  45. package/src/assets/i18n/fr.json +17 -3
  46. package/src/assets/i18n/it.json +17 -3
  47. package/src/assets/i18n/pt.json +17 -3
  48. package/src/assets/i18n/ru.json +17 -3
  49. package/src/assets/i18n/sr.json +17 -3
  50. package/src/assets/i18n/tr.json +17 -3
  51. package/src/chat21-core/providers/firebase/firebase-conversation-handler.ts +8 -3
  52. package/src/chat21-core/utils/utils-message.ts +19 -0
  53. package/src/global.scss +8 -0
@@ -141,7 +141,7 @@
141
141
  <ion-col size="12" style="text-align: center;">
142
142
 
143
143
  <!-- <ion-icon *ngIf="showSpinnerCreateTicket === false" style="font-size: 1.9em;" slot="start" name="checkmark-outline"></ion-icon> -->
144
- <ion-button style="width: 153px;" color="primary" class="submit-btn" type="submit" (click)="createTicket()" [disabled]="ticket_subject === undefined || ticket_message === undefined || ticket_subject?.length === 0 || ticket_message?.length === 0">
144
+ <ion-button style="min-width: 153px;" color="primary" class="submit-btn" type="submit" (click)="createTicket()" [disabled]="ticket_subject === undefined || ticket_message === undefined || ticket_subject?.length === 0 || ticket_message?.length === 0">
145
145
  <ion-icon *ngIf="showSpinnerCreateTicket === false" style="font-size: 1.9em;" slot="start" name="add-circle-outline"></ion-icon>
146
146
  <ion-spinner *ngIf="showSpinnerCreateTicket === true" style="color: #fff; margin: 0px 0.3em 0px -0.3em;" name="bubbles" duration="2" ></ion-spinner>
147
147
  {{'CreateTicket' | translate}}
@@ -188,10 +188,19 @@ export class CreateTicketPage implements OnInit {
188
188
  selectRequester($event) {
189
189
  this.logger.log('[CREATE-TICKET] - SELECT REQUESTER event', $event)
190
190
  this.logger.log('[CREATE-TICKET] - SELECT REQUESTER ID', this.selectedRequester)
191
- this.logger.log('[CREATE-TICKET] - SELECT REQUESTER $event requester_id ', $event.requester_id)
192
- this.logger.log('[CREATE-TICKET] - SELECT REQUESTER $event requestertype ', $event.requestertype)
193
- this.id_for_view_requeter_dtls = $event.requester_id
194
- this.requester_type = $event.requestertype
191
+ if($event && $event.requester_id ) {
192
+ this.id_for_view_requeter_dtls = $event.requester_id
193
+ this.logger.log('[CREATE-TICKET] - SELECT REQUESTER $event requester_id ', $event.requester_id)
194
+ }
195
+
196
+ if($event && $event.requestertype ) {
197
+ this.requester_type = $event.requestertype
198
+ this.logger.log('[CREATE-TICKET] - SELECT REQUESTER $event requestertype ', $event.requestertype)
199
+ }
200
+
201
+
202
+
203
+
195
204
 
196
205
  // const hasFound = this.projectUserAndLeadsArray.filter((obj: any) => {
197
206
  // return obj.id === this.selectedRequester
@@ -77,10 +77,10 @@
77
77
 
78
78
 
79
79
  <ion-footer class="ion-no-border">
80
- <ion-toolbar>
80
+ <!-- <ion-toolbar style="background-color: #1e2129 !important"> -->
81
81
  <div class="content-chat-version">
82
82
  <!-- <p class="chat-title">Tiledesk Chat</p> -->
83
83
  <p class="chat-version">{{ 'LABEL_VERSION' | translate }} {{version}}</p>
84
84
  </div>
85
- </ion-toolbar>
85
+ <!-- </ion-toolbar> -->
86
86
  </ion-footer>
@@ -114,6 +114,15 @@
114
114
  margin-top: 15px;
115
115
  margin-bottom: 5px;
116
116
  }
117
+
118
+ // ion-toolbar {
119
+ // --padding-bottom: 0px;
120
+ // --background: #1e2129 !important;
121
+ // div.toolbar-container {
122
+ // padding: 0px !important;
123
+ // background: #1e2129 !important;
124
+ // }
125
+ // }
117
126
  }
118
127
 
119
128
  .avatar-container {
@@ -250,6 +259,7 @@ ion-footer{
250
259
  .content-chat-version {
251
260
  color: white;
252
261
  padding: 20px;
262
+ background-color: #1e2129;
253
263
  }
254
264
  .chat-title{
255
265
  font-size: 14px;
@@ -261,4 +271,5 @@ ion-footer{
261
271
  font-weight: 400;
262
272
  margin: 0;
263
273
  }
264
- }
274
+ }
275
+
@@ -274,7 +274,35 @@ export class TiledeskService {
274
274
  }
275
275
 
276
276
 
277
+ // -------------------------------------------------------------------------------------
278
+ // @ Create - Save (POST) new canned response
279
+ // -------------------------------------------------------------------------------------
280
+ public createCannedResponse(message: string, title: string, project_id: string, token: string) {
281
+ this.logger.log('[TILEDESK-SERVICE] - CREATE CANNED-RES - token', token);
282
+ const url = this.apiUrl + project_id + '/canned/'
283
+ this.logger.log('[TILEDESK-SERVICE] - CREATE CANNED-RES - URL', url);
284
+
285
+ const httpOptions = {
286
+ headers: new HttpHeaders({
287
+ 'Content-Type': 'application/json',
288
+ Authorization: token
289
+ })
290
+ };
291
+
292
+ const body = { 'text': message, 'title': title };
277
293
 
294
+ this.logger.log('[TILEDESK-SERVICE] CREATE CANNED-RES - BODY ', body);
295
+
296
+ return this.http
297
+ .post(url, JSON.stringify(body), httpOptions)
298
+ .pipe(map((res: any) => {
299
+ this.logger.log('[TILEDESK-SERVICE] - CREATE CANNED-RES - RES ', res);
300
+ return res
301
+ }))
302
+
303
+ }
278
304
 
305
+ // .post(url, JSON.stringify(body), options)
306
+ // .map((res) => res.json());
279
307
 
280
308
  }
@@ -47,7 +47,7 @@ import { MatTooltipModule } from '@angular/material/tooltip';
47
47
  import { MatSnackBarModule } from '@angular/material/snack-bar';
48
48
  import { MatSlideToggleModule } from '@angular/material/slide-toggle';
49
49
 
50
- // import { MessageTextAreaComponent } from '../components/conversation-detail/message-text-area/message-text-area.component';
50
+ // import { MessageTextAreaComponent } from '../components/conversation-detail/message-text-area/message-text-area.component'; // MessageTextAreaComponent is part of the declarations ConversationDetailPageModule
51
51
 
52
52
  @NgModule({
53
53
  declarations: [
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"Sie gehören nicht mehr zu den Teamkollegen, die diese Unterhaltung führen",
229
229
  "TicketSuccessfullyCreated": "Ticket erfolgreich erstellt",
230
230
  "Continue":"Fortsetzen",
231
- "ViewArchivedConversations":"Archivierte Konversationen anzeigen",
232
- "ViewContactsList":"Liste der Kontakte anzeigen",
231
+ "ViewArchivedConversations":"Archivierte Gespräche",
232
+ "ViewContactsList":"Kontaktliste",
233
+ "AddAsCannedResponse":"Als Standardantwort hinzufügen",
234
+ "AddNewCannedResponse":"Fügen Sie eine neue Standardantwort hinzu",
235
+ "TitleIsRequired":"Titel ist erforderlich",
236
+ "MessageIsRequired":"Nachricht ist erforderlich",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Ticket erstellen",
235
239
  "Requester": "Anfragesteller",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Neuen Anforderer erstellen",
248
252
  "Name": "Name",
249
253
  "NameIsRequired": "Name ist erforderlich",
250
- "EnterValidEmail": "Geben Sie eine gültige Email Adresse ein"
254
+ "EnterValidEmail": "Geben Sie eine gültige Email Adresse ein",
255
+ "Title": "Titel",
256
+ "Add": "Hinzufügen",
257
+ "AddCustomization": "Personalisierung hinzufügen",
258
+ "SelectACustomizationToAddToYourMessage": "Personalisierungs-Feld auswählen",
259
+ "recipient_name_desc": "Der Vorname eines Besuchers wird zur Nachricht hinzugefügt.",
260
+ "agent_name_desc": "Der Name des Betreuers wird zur Nachricht hinzugefügt.",
261
+ "First_name_of_recipient": "Vorname des Empfängers",
262
+ "First_name_of_agent": "Vorname des Betreuers",
263
+ "EnterCannedResponseTitle": "Titel der Vordefinierten Anfrage eingeben",
264
+ "WriteMsgToSendToYourVisitors": "Verfassen Sie eine vordefinierte Antwort für Ihre Besucher"
251
265
  }
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"You are no longer among the teammates managing this conversation",
229
229
  "TicketSuccessfullyCreated":"Ticket successfully created",
230
230
  "Continue":"Continue",
231
- "ViewArchivedConversations":"View archived conversations",
232
- "ViewContactsList":"View contacts list",
231
+ "ViewArchivedConversations":"Archived conversations",
232
+ "ViewContactsList":"Contacts list",
233
+ "AddAsCannedResponse":"Add as canned response",
234
+ "AddNewCannedResponse":"Add a new canned response",
235
+ "TitleIsRequired":"Title is required",
236
+ "MessageIsRequired":"Message is required",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Create ticket",
235
239
  "Requester": "Requester",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Create new requester",
248
252
  "Name": "Name",
249
253
  "NameIsRequired": "Name is required",
250
- "EnterValidEmail": "Enter a valid email address"
254
+ "EnterValidEmail": "Enter a valid email address",
255
+ "Title": "Title",
256
+ "Add": "Add",
257
+ "AddCustomization": "Add personalisation",
258
+ "SelectACustomizationToAddToYourMessage": "Select a personalisation value to add to message",
259
+ "recipient_name_desc": "The first name of the person the agent replying to will be added to message.",
260
+ "agent_name_desc": "The name of the agent who is replying will be added to the message.",
261
+ "First_name_of_recipient": "First name of recipient",
262
+ "First_name_of_agent": "First name of agent",
263
+ "EnterCannedResponseTitle": "Enter canned response title",
264
+ "WriteMsgToSendToYourVisitors": "Write a canned response message to send to your visitors"
251
265
  }
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"Ya no estás entre los compañeros de equipo que gestionan esta conversación",
229
229
  "TicketSuccessfullyCreated":"Ticket creado con éxito",
230
230
  "Continue":"Continuar",
231
- "ViewArchivedConversations":"Ver conversaciones archivadas",
232
- "ViewContactsList":"Ver lista de contactos",
231
+ "ViewArchivedConversations":"Conversaciones archivadas",
232
+ "ViewContactsList":"Lista de contactos",
233
+ "AddAsCannedResponse":"Agregar como respuesta predeterminada",
234
+ "AddNewCannedResponse":"Agregar una nueva respuesta predeterminada",
235
+ "TitleIsRequired":"El título es obligatorio",
236
+ "MessageIsRequired":"El mensaje es obligatorio",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Crear ticket",
235
239
  "Requester": "Solicitante",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Crear nuevo solicitante",
248
252
  "Name": "Nombre",
249
253
  "NameIsRequired": "Se requiere nombre",
250
- "EnterValidEmail": "Introduzca una dirección de correo válida"
254
+ "EnterValidEmail": "Introduzca una dirección de correo válida",
255
+ "Title": "Título",
256
+ "Add": "Añadir",
257
+ "AddCustomization": "Añadir personalización",
258
+ "SelectACustomizationToAddToYourMessage": "Seleccione un valor de personalización para agregar al mensaje",
259
+ "recipient_name_desc": "El nombre de la persona a la que responda el agente será añadido al mensaje.",
260
+ "agent_name_desc": "El nombre del agente que está respondiendo será añadido al mensaje.",
261
+ "First_name_of_recipient": "Nombre del destinatario",
262
+ "First_name_of_agent": "Nombre del agente",
263
+ "EnterCannedResponseTitle": "Introduzca el título de la respuesta predefinida",
264
+ "WriteMsgToSendToYourVisitors": "Escribe un mensaje de respuesta enlatado para enviar a tus visitantes"
251
265
  }
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"Vous n'êtes plus parmi les coéquipiers qui gèrent cette conversation",
229
229
  "TicketSuccessfullyCreated":"Ticket créé avec succès",
230
230
  "Continue":"Continuez",
231
- "ViewArchivedConversations":"Consulter les conversations archivées",
232
- "ViewContactsList":"Voir la liste de contacts",
231
+ "ViewArchivedConversations":"Conversations archivées",
232
+ "ViewContactsList":"Liste de contacts",
233
+ "AddAsCannedResponse":"Ajouter comme réponse par défaut",
234
+ "AddNewCannedResponse":"Ajouter une nouvelle réponse par défaut",
235
+ "TitleIsRequired":"Le titre est requis",
236
+ "MessageIsRequired":"Un message est requis",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Créer un ticket",
235
239
  "Requester": "Demandeur",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Créer un nouveau demandeur",
248
252
  "Name": "Nom",
249
253
  "NameIsRequired": "Le nom est requis",
250
- "EnterValidEmail": "Entrez une adresse mail valide"
254
+ "EnterValidEmail": "Entrez une adresse mail valide",
255
+ "Title": "Titre",
256
+ "Add": "Ajouter",
257
+ "AddCustomization": "Ajouter une personnalisation",
258
+ "SelectACustomizationToAddToYourMessage": "Sélectionnez une valeur de personnalisation à ajouter au message",
259
+ "recipient_name_desc": "Le prénom de la personne à qui l'agent répond sera ajouté au message.",
260
+ "agent_name_desc": "Le nom de l'agent qui répond sera ajouté au message.",
261
+ "First_name_of_recipient": "Prénom du destinataire",
262
+ "First_name_of_agent": "Prénom du mandataire",
263
+ "EnterCannedResponseTitle": "Saisissez le titre de la réponse standardisée",
264
+ "WriteMsgToSendToYourVisitors": "Rédigez un message de réponse standardisé à envoyer à vos visiteurs"
251
265
  }
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"Non sei più tra i compagni di squadra che gestiscono questa conversazione",
229
229
  "TicketSuccessfullyCreated":"Ticket creato con successo",
230
230
  "Continue":"Continua",
231
- "ViewArchivedConversations":"Visualizza le conversazioni archiviate",
232
- "ViewContactsList":"Visualizza l'elenco dei contatti",
231
+ "ViewArchivedConversations":"Conversazioni archiviate",
232
+ "ViewContactsList":"Elenco contatti",
233
+ "AddAsCannedResponse":"Aggiungi come risposta predefinita",
234
+ "AddNewCannedResponse":"Aggiungi una nuova risposta predefinita",
235
+ "TitleIsRequired":"Il titolo è obbligatorio",
236
+ "MessageIsRequired":"Il messaggio è obbligatorio",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Crea Ticket",
235
239
  "Requester": "Richiedente",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Crea nuovo richiedente",
248
252
  "Name": "Nome",
249
253
  "NameIsRequired": "Il nome è obbligatorio",
250
- "EnterValidEmail": "Inserire un indirizzo email valido"
254
+ "EnterValidEmail": "Inserire un indirizzo email valido",
255
+ "Title": "Titolo",
256
+ "Add": "Aggiungi",
257
+ "AddCustomization": "Aggiungi personalizzazione",
258
+ "SelectACustomizationToAddToYourMessage": "Seleziona una valore personalizzato da aggiungere al messaggio",
259
+ "recipient_name_desc": "Il nome della persona a cui l'agente sta rispondendo verrà aggiunto al messaggio.",
260
+ "agent_name_desc": "Il nome dell'agente che sta rispondendo verrà aggiunto al messaggio.",
261
+ "First_name_of_recipient": "Nome del destinatario",
262
+ "First_name_of_agent": "Nome dell'agente",
263
+ "EnterCannedResponseTitle": "Inserisci il titolo della risposta predefinita",
264
+ "WriteMsgToSendToYourVisitors": "Scrivi un messaggio di risposta predefinito da inviare ai tuoi visitatori"
251
265
  }
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"Você não está mais entre os colegas de equipe que estão gerenciando esta conversa",
229
229
  "TicketSuccessfullyCreated":"Ticket criado com sucesso",
230
230
  "Continue":"Continuar",
231
- "ViewArchivedConversations":"Ver conversas arquivadas",
232
- "ViewContactsList":"Visualizar lista de contatos",
231
+ "ViewArchivedConversations":"Conversas arquivadas",
232
+ "ViewContactsList":"Lista de contatos",
233
+ "AddAsCannedResponse":"Adicione como resposta padrão",
234
+ "AddNewCannedResponse":"Adicionar uma nova resposta padrão",
235
+ "TitleIsRequired":"O título é obrigatório",
236
+ "MessageIsRequired":"A mensagem é obrigatória",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Criar bilhete",
235
239
  "Requester": "Solicitante",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Criar novo solicitante",
248
252
  "Name": "Nome",
249
253
  "NameIsRequired": "O nome é obrigatório",
250
- "EnterValidEmail": "Digite um endereço de e-mail válido"
254
+ "EnterValidEmail": "Digite um endereço de e-mail válido",
255
+ "Title": "Título",
256
+ "Add": "Adicionar",
257
+ "AddCustomization": "Adicionar personalização",
258
+ "SelectACustomizationToAddToYourMessage": "Selecione um valor de personalização para adicionar à mensagem",
259
+ "recipient_name_desc": "O primeiro nome da pessoa a quem o agente está respondendo será adicionado à mensagem.",
260
+ "agent_name_desc": "O nome do agente que está respondendo será adicionado à mensagem.",
261
+ "First_name_of_recipient": "Nome do destinatário",
262
+ "First_name_of_agent": "Nome do agente",
263
+ "EnterCannedResponseTitle": "Insira o título da resposta predeterminada",
264
+ "WriteMsgToSendToYourVisitors": "Escreva uma mensagem de resposta pronta para enviar aos seus visitantes"
251
265
  }
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"Вы больше не входите в число товарищей по команде, ведущих этот разговор",
229
229
  "TicketSuccessfullyCreated":"Тикет успешно создан",
230
230
  "Continue":"Продолжать",
231
- "ViewArchivedConversations":"Просмотр архивных разговоров",
232
- "ViewContactsList":"Посмотреть список контактов",
231
+ "ViewArchivedConversations":"Заархивированные беседы",
232
+ "ViewContactsList":"Список контактов",
233
+ "AddAsCannedResponse":"Добавить как ответ по умолчанию",
234
+ "AddNewCannedResponse":"Добавить новый ответ по умолчанию",
235
+ "TitleIsRequired":"Требуется заголовок",
236
+ "MessageIsRequired":"Требуется сообщение",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Создать тикет",
235
239
  "Requester": "Заявитель",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Создать нового запросчика",
248
252
  "Name": "Имя",
249
253
  "NameIsRequired": "Укажите имя",
250
- "EnterValidEmail": "Введите действительный адрес электронной почты"
254
+ "EnterValidEmail": "Введите действительный адрес электронной почты",
255
+ "Title": "Заголовок",
256
+ "Add": "Добавлять",
257
+ "AddCustomization": "Добавить персонализацию",
258
+ "SelectACustomizationToAddToYourMessage": "Выберите значение персонализации для добавления к сообщению",
259
+ "recipient_name_desc": "Имя человека, которому отвечает агент, будет добавлено к сообщению.",
260
+ "agent_name_desc": "К сообщению будет добавлено имя отвечающего агента.",
261
+ "First_name_of_recipient": "Имя получателя",
262
+ "First_name_of_agent": "Имя агента",
263
+ "EnterCannedResponseTitle": "Введите готовый заголовок ответа",
264
+ "WriteMsgToSendToYourVisitors": "Напишите готовое ответное сообщение для отправки своим посетителям"
251
265
  }
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"Више нисте међу саиграчима који управљају овим разговором",
229
229
  "TicketSuccessfullyCreated":"Улазница је успешно направљена",
230
230
  "Continue":"Наставити",
231
- "ViewArchivedConversations":"Погледајте архивиране разговоре",
232
- "ViewContactsList":"Погледајте листу контаката",
231
+ "ViewArchivedConversations":"Архивирани разговори",
232
+ "ViewContactsList":"Листа контаката",
233
+ "AddAsCannedResponse":"Додај као задани одговор",
234
+ "AddNewCannedResponse":"Додајте нови подразумевани одговор",
235
+ "TitleIsRequired":"Наслов је обавезан",
236
+ "MessageIsRequired":"Порука је обавезна",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Креирајте карту",
235
239
  "Requester": "Подносилац захтева",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Креирајте нови захтев",
248
252
  "Name": "Име",
249
253
  "NameIsRequired": "Име је обавезно",
250
- "EnterValidEmail": "Унесите исправну е-маил адресу"
254
+ "EnterValidEmail": "Унесите исправну е-маил адресу",
255
+ "Title": "Наслов",
256
+ "Add": "Додати",
257
+ "AddCustomization": "Додајте персонализацију",
258
+ "SelectACustomizationToAddToYourMessage": "Изаберите вредност персонализације коју желите да додате у поруку",
259
+ "recipient_name_desc": "Име особе којој агент одговара биће додато у поруку.",
260
+ "agent_name_desc": "Име агента који одговара биће додато у поруку.",
261
+ "First_name_of_recipient": "Име примаоца",
262
+ "First_name_of_agent": "Име агента",
263
+ "EnterCannedResponseTitle": "Унесите назив унапред припремљеног одговора",
264
+ "WriteMsgToSendToYourVisitors": "Напишите унапред припремљену одговор поруку коју ћете послати посетиоцима"
251
265
  }
@@ -228,8 +228,12 @@
228
228
  "YouAreNoLongerAmongTheTeammatesManagingThisConversation":"Artık bu konuşmayı yöneten takım arkadaşları arasında değilsiniz",
229
229
  "TicketSuccessfullyCreated":"Bilet başarıyla oluşturuldu",
230
230
  "Continue":"Devam",
231
- "ViewArchivedConversations":"Arşivlenmiş konuşmaları görüntüle",
232
- "ViewContactsList":"Kişi listesini görüntüle",
231
+ "ViewArchivedConversations":"Arşivlenmiş konuşmalar",
232
+ "ViewContactsList":"Kişiler listesi",
233
+ "AddAsCannedResponse":"Varsayılan yanıt olarak ekle",
234
+ "AddNewCannedResponse":"Yeni bir hazır yanıt ekle",
235
+ "TitleIsRequired":"Başlık zorunludur",
236
+ "MessageIsRequired":"Mesaj gerekli",
233
237
  "Already_present_in_the_dashboard_json":"........",
234
238
  "CreateTicket": "Bilet oluştur",
235
239
  "Requester": "istekte bulunan",
@@ -247,5 +251,15 @@
247
251
  "CreateNewRequester": "Yeni istek sahibi oluştur",
248
252
  "Name": "İsim",
249
253
  "NameIsRequired": "İsim gerekli",
250
- "EnterValidEmail": "Geçerli bir e-posta adresi girin"
254
+ "EnterValidEmail": "Geçerli bir e-posta adresi girin",
255
+ "Title": "Başlık",
256
+ "Add": "Eklemek",
257
+ "AddCustomization": "Kişiselleştirme ekle",
258
+ "SelectACustomizationToAddToYourMessage": "Mesaja eklemek için bir kişiselleştirme değeri seçin",
259
+ "recipient_name_desc": "Temsilcinin cevap verdiği kişinin adı mesaja eklenecektir.",
260
+ "agent_name_desc": "Cevap veren temsilcinin adı mesaja eklenecektir.",
261
+ "First_name_of_recipient": "Alıcının adı",
262
+ "First_name_of_agent": "Ajanın adı",
263
+ "EnterCannedResponseTitle": "Hazır yanıt başlığını girin",
264
+ "WriteMsgToSendToYourVisitors": "Ziyaretçilerinize göndermek için hazır bir yanıt mesajı yazın"
251
265
  }
@@ -18,11 +18,11 @@ import { ConversationHandlerService } from '../abstract/conversation-handler.ser
18
18
  import { LoggerService } from '../abstract/logger.service';
19
19
  import { LoggerInstance } from '../logger/loggerInstance';
20
20
  // utils
21
- import { MSG_STATUS_RECEIVED, CHAT_REOPENED, CHAT_CLOSED, MEMBER_JOINED_GROUP, TYPE_DIRECT, MESSAGE_TYPE_INFO , TOUCHING_OPERATOR} from '../../utils/constants';
21
+ import { MSG_STATUS_RECEIVED, CHAT_REOPENED, CHAT_CLOSED, MEMBER_JOINED_GROUP, TYPE_DIRECT, MESSAGE_TYPE_INFO, TOUCHING_OPERATOR } from '../../utils/constants';
22
22
  import { compareValues, searchIndexInArrayForUid, conversationMessagesRef } from '../../utils/utils';
23
23
 
24
24
 
25
- import { messageType } from 'src/chat21-core/utils/utils-message';
25
+ import { messageType, isEmojii } from 'src/chat21-core/utils/utils-message';
26
26
 
27
27
 
28
28
 
@@ -156,7 +156,8 @@ export class FirebaseConversationHandler extends ConversationHandlerService {
156
156
  typeMsg,
157
157
  attributes,
158
158
  channelType,
159
- false
159
+ false,
160
+ isEmojii(msg)
160
161
  );
161
162
  const messageRef = firebaseMessagesCustomUid.push({
162
163
  language: lang,
@@ -288,6 +289,10 @@ export class FirebaseConversationHandler extends ConversationHandlerService {
288
289
 
289
290
  // verifico che il sender è il logged user
290
291
  msg.isSender = this.isSender(msg.sender, this.loggedUser.uid);
292
+
293
+ //check if message contains only an emojii
294
+ msg.emoticon = isEmojii(msg.text)
295
+
291
296
  // traduco messaggi se sono del server
292
297
  if (msg.attributes && msg.attributes.subtype) {
293
298
  if (msg.attributes.subtype === 'info' || msg.attributes.subtype === 'info/support') {
@@ -85,6 +85,25 @@ export function messageType(msgType: string, message: any) {
85
85
  }
86
86
  }
87
87
 
88
+ export function isEmojii(message: any){
89
+ if (message.length > 2) {
90
+ return false;
91
+ }
92
+ let fistChar = '';
93
+ try {
94
+ fistChar = message.trim(); // .charAt(0);
95
+ } catch (e) {
96
+ return false;
97
+ }
98
+
99
+ const ranges = ['(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff]|[\u0023-\u0039]\ufe0f?\u20e3|\u3299|\u3297|\u303d|\u3030|\u24c2|\ud83c[\udd70-\udd71]|\ud83c[\udd7e-\udd7f]|\ud83c\udd8e|\ud83c[\udd91-\udd9a]|\ud83c[\udde6-\uddff]|[\ud83c[\ude01-\ude02]|\ud83c\ude1a|\ud83c\ude2f|[\ud83c[\ude32-\ude3a]|[\ud83c[\ude50-\ude51]|\u203c|\u2049|[\u25aa-\u25ab]|\u25b6|\u25c0|[\u25fb-\u25fe]|\u00a9|\u00ae|\u2122|\u2139|\ud83c\udc04|[\u2600-\u26FF]|\u2b05|\u2b06|\u2b07|\u2b1b|\u2b1c|\u2b50|\u2b55|\u231a|\u231b|\u2328|\u23cf|[\u23e9-\u23f3]|[\u23f8-\u23fa]|\ud83c\udccf|\u2934|\u2935|[\u2190-\u21ff])'];
100
+ if (fistChar.match(ranges.join('|'))) {
101
+ return true;
102
+ } else {
103
+ return false;
104
+ }
105
+ }
106
+
88
107
  /** */
89
108
  export function getSizeImg(message: any, maxWidthImage?: number): any {
90
109
  try {
package/src/global.scss CHANGED
@@ -542,6 +542,14 @@ select:-webkit-autofill:focus {
542
542
  color: #f44336;
543
543
  }
544
544
 
545
+ #canned > ion-list > ion-item > div > div.no-canned-available-text {
546
+ color: #1877f2 !important;
547
+ }
548
+
549
+ #canned > ion-list > ion-item > div > div.no-canned-available-text:hover {
550
+ text-decoration: underline;
551
+ }
552
+
545
553
  .highlight-search-string {
546
554
  color: #1877f2 !important;
547
555
  }