@chat21/chat21-ionic 3.4.26-rc1 → 3.4.26

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/CHANGELOG.md CHANGED
@@ -8,10 +8,14 @@
8
8
  ### **Copyrigth**:
9
9
  *Tiledesk SRL*
10
10
 
11
+ # 3.4.26 in PROD
12
+
13
+ # 3.4.26-rc2
14
+ - **removed**: archive button on list conversations if is not on mobile device
15
+
11
16
  # 3.4.26-rc1
12
17
  - **added**: tiledesk_projectID query param to manage user status
13
18
  - **added**: token to managane ticket feature
14
- - **added**: getOsCode login into utils.ts
15
19
 
16
20
  # 3.4.25 in PROD
17
21
  - **changed**: pipe marked to support malicious text input
@@ -34,24 +38,6 @@
34
38
  # 3.4.22 in PROD
35
39
  - **added**: managed allowed_upload_extentions from project settings
36
40
 
37
- # 3.4.21-rc6
38
- - **added**: managed allowed_upload_extentions from project settings
39
-
40
- # 3.4.21-rc5
41
- - **added**: setConversation as read when agent click on it
42
-
43
- # 3.4.21-rc4
44
- - **added**: ability to init and decrement new conversation count badge
45
-
46
- # 3.4.21-rc3
47
- - **changed**: badge notification for agentDesktop
48
-
49
- # 3.4.21-rc2
50
- - **added**: count in newConversation handler event
51
-
52
- # 3.4.21-rc1
53
- - **added**: implement badge notification for agentDesktop sw when new conversation is assigned to logged agent
54
-
55
41
  # 3.4.21 in PROD
56
42
 
57
43
  # 3.4.20 in PROD
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@chat21/chat21-ionic",
3
3
  "author": "Tiledesk SRL",
4
- "version": "3.4.26-rc1",
4
+ "version": "3.4.26",
5
5
  "license": "MIT License",
6
6
  "homepage": "https://tiledesk.com/",
7
7
  "repository": {
@@ -168,7 +168,6 @@ export class AppComponent implements OnInit {
168
168
  }, { capture: true });
169
169
  }
170
170
 
171
-
172
171
  listenChatAlreadyOpenWithoutParamsInMobileMode() {
173
172
  this.events.subscribe('noparams:mobile', (isAlreadyOpenInMobileMode) => {
174
173
  // console.log('[APP-COMP] Chat is Already Open In Mobile Mode ', isAlreadyOpenInMobileMode)
@@ -333,7 +332,7 @@ export class AppComponent implements OnInit {
333
332
 
334
333
  listenToPostMsgs() {
335
334
  window.addEventListener("message", (event) => {
336
- // this.logger.log("[APP-COMP] message event ", event);
335
+ this.logger.log("[APP-COMP] message event ", event);
337
336
 
338
337
  if (event && event.data && event.data.action && event.data.parameter) {
339
338
  if (event.data.action === 'openJoinConversationModal') {
@@ -1111,7 +1110,6 @@ export class AppComponent implements OnInit {
1111
1110
  if (conversation && conversation.is_new === true && this.isInitialized) {
1112
1111
  this.manageTabNotification('conv_added', conversation.sound)
1113
1112
  this.manageEventNewConversation(conversation)
1114
- this.setNotification();
1115
1113
  }
1116
1114
  if(conversation) this.updateConversationsOnStorage()
1117
1115
  });
@@ -1346,10 +1344,7 @@ export class AppComponent implements OnInit {
1346
1344
 
1347
1345
  subscribeConversationSelected= (conversation: ConversationModel) => {
1348
1346
  if(conversation && conversation.is_new){
1349
- this.audio_NewConv.pause();
1350
- this.conversationsHandlerService.setConversationRead(conversation.uid)
1351
- //UPDATE NOTIFICATION FOR NEW CONVERSATION COUNT
1352
- this.setNotification();
1347
+ this.audio_NewConv.pause()
1353
1348
  }
1354
1349
  }
1355
1350
 
@@ -1425,9 +1420,6 @@ export class AppComponent implements OnInit {
1425
1420
  this.logger.debug('[APP-COMP]-CONVS - INIT CONV CONVS 2', conversations)
1426
1421
  this.events.publish('appcompSubscribeToConvs:loadingIsActive', false);
1427
1422
  }
1428
-
1429
- //INIT NOTIFICATION FOR NEW CONVERSATION COUNT
1430
- this.setNotification();
1431
1423
  });
1432
1424
 
1433
1425
  }
@@ -1644,14 +1636,6 @@ export class AppComponent implements OnInit {
1644
1636
  this.triggerEvents.triggerOnNewConversationInit(conversation)
1645
1637
  }
1646
1638
 
1647
- private setNotification() {
1648
- this.logger.log('[APP-COMP] setNotification for NEW CONVERSATION');
1649
- if(window['AGENTDESKTOP']){
1650
- this.logger.log('[APP-COMP] manageNotification AGENTDESKTOP exist', window['AGENTDESKTOP']);
1651
- window['AGENTDESKTOP']['TAB'].Badge(this.conversationsHandlerService.countIsNew().toString())
1652
- }
1653
- }
1654
-
1655
1639
 
1656
1640
  @HostListener('document:visibilitychange', [])
1657
1641
  visibilitychange() {
@@ -122,7 +122,7 @@
122
122
  {{conversation?.conversation_with_fullname}}
123
123
  </span>
124
124
  </div>
125
- <div class="conversation_message truncate" [ngClass]="{'truncate-on-desktop': !isApp}">
125
+ <div class="conversation_message truncate" [ngClass]="{'truncate-on-desktop': !IS_ON_MOBILE_DEVICE}">
126
126
 
127
127
  <!-- -------------------------------------------------------------------------- -->
128
128
  <!-- if conversation type is image display the image icon before the message -->
@@ -130,7 +130,7 @@
130
130
  <!-- <div *ngIf="conversation.type === 'image'" class="icon-image-before-msg-wpr">
131
131
  <ion-icon name="image-outline" class="icon-image-before-msg"></ion-icon>
132
132
  </div>
133
- <p [class.not-read]="conversation.is_new" class="truncate" [ngClass]="{'truncate-on-desktop': !isApp}"
133
+ <p [class.not-read]="conversation.is_new" class="truncate" [ngClass]="{'truncate-on-desktop': !IS_ON_MOBILE_DEVICE}"
134
134
  [innerHTML]="conversation.last_message_text"></p> -->
135
135
 
136
136
  <!-- <div *ngIf="conversation.type === 'image'" class="icon-image-before-msg-wpr"> -->
@@ -146,7 +146,7 @@
146
146
  </ion-label>
147
147
  </div>
148
148
 
149
- <ion-note *ngIf="!conversation.archived" class="conversation_time" [ngClass]="{'is-on-mobile': isApp}">
149
+ <ion-note *ngIf="!conversation.archived" class="conversation_time" [ngClass]="{'is-on-mobile': IS_ON_MOBILE_DEVICE}">
150
150
  {{conversation.timestamp | amTimeAgo}}
151
151
  </ion-note>
152
152
  <ion-note item-end *ngIf="conversation?.archived" class="conversation_time">
@@ -162,7 +162,7 @@
162
162
 
163
163
  <ion-buttons slot="end">
164
164
  <ion-button *ngIf="!conversation.archived" placement="bottom"
165
- [ngClass]="{'hide': !isApp, 'button-on-desktop': !isApp, 'button-on-mobile': isApp }"
165
+ [ngClass]="{'hide': !IS_ON_MOBILE_DEVICE, 'button-on-desktop': !IS_ON_MOBILE_DEVICE, 'button-on-mobile': IS_ON_MOBILE_DEVICE }"
166
166
  id="{{ 'close_conversation_button' + conversation.uid }}" class="close-conversation-button" ion-button clear
167
167
  item-end (click)="closeConversation(conversation);$event.stopPropagation();" padding>
168
168
  <ion-icon slot="icon-only" style="display:block;" id="{{ 'close_button_icon' + conversation.uid }}" name="archive-outline" item-end></ion-icon>
@@ -171,7 +171,7 @@
171
171
  </ion-button>
172
172
 
173
173
  <!-- <ion-button *ngIf="conversation?.recipient.startsWith('support-group') && !conversation.archived" [tooltip]="joinTooltip" [options]="tooltip_options" placement="bottom" content-type="template"
174
- [ngClass]="{'hide': !isApp, 'button-on-desktop': !isApp, 'button-on-mobile': isApp }"
174
+ [ngClass]="{'hide': !IS_ON_MOBILE_DEVICE, 'button-on-desktop': !IS_ON_MOBILE_DEVICE, 'button-on-mobile': IS_ON_MOBILE_DEVICE }"
175
175
  id="{{ 'join_conversation_button' + conversation.uid }}" class="close-conversation-button" ion-button clear
176
176
  item-end (click)="joinConversation(conversation);$event.stopPropagation();" padding>
177
177
  <ion-icon slot="icon-only" style="display:block;" id="{{ 'join_button_icon' + conversation.uid }}" name="link-outline" item-end></ion-icon>
@@ -193,7 +193,7 @@
193
193
 
194
194
  <!-- && !conversation?.archived -->
195
195
  <div item-end class="notification_point"
196
- [ngClass]="{'notification_point-on-desktop': !isApp, 'notification_point-on-mobile': isApp }"
196
+ [ngClass]="{'notification_point-on-desktop': !IS_ON_MOBILE_DEVICE, 'notification_point-on-mobile': IS_ON_MOBILE_DEVICE }"
197
197
  *ngIf="conversation.is_new">
198
198
  </div>
199
199
 
@@ -187,6 +187,10 @@ ion-item:hover {
187
187
  ion-buttons {
188
188
  ion-button {
189
189
  display: block;
190
+
191
+ &.hide {
192
+ display: none;
193
+ }
190
194
  }
191
195
  }
192
196
  }
@@ -102,9 +102,8 @@ export class IonListConversationsComponent extends ListConversationsComponent im
102
102
 
103
103
  }
104
104
  ngOnInit() {
105
- this.isApp = this.platform.is('ios') || this.platform.is('android')
106
- this.logger.log('[ION-LIST-CONVS-COMP] - ngOnInit - IS-APP ', this.isApp);
107
105
  this.IS_ON_MOBILE_DEVICE = isOnMobileDevice()
106
+ this.logger.log('[ION-LIST-CONVS-COMP] - ngOnInit - IS_ON_MOBILE_DEVICE ', this.IS_ON_MOBILE_DEVICE);
108
107
  }
109
108
 
110
109
  ngOnChanges(changes: { [property: string]: SimpleChange }) {