@chat21/chat21-ionic 3.4.4 → 3.4.5-rc.1

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
@@ -1,5 +1,8 @@
1
1
  # chat21-ionic ver 3.0
2
2
 
3
+ ### 3.4.5-rc.1
4
+ - changed: management of sidebar icon with env variable
5
+
3
6
  ### 3.4.4 in PROD
4
7
 
5
8
  ### 3.4.4-rc.1
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.4",
4
+ "version": "3.4.5-rc.1",
5
5
  "license": "MIT License",
6
6
  "homepage": "https://tiledesk.com/",
7
7
  "repository": {
@@ -101,22 +101,22 @@
101
101
  <!-- ------------------------------------------- -->
102
102
  <!-- Conversations (MONITOR) (click)="goToConversations()" -->
103
103
  <!-- ------------------------------------------- -->
104
- <!-- <ng-container *ngIf="USER_ROLE !== 'agent'"> -->
105
- <div matTooltipClass="custom-mat-tooltip" matTooltip="Monitor"
106
- #tooltip="matTooltip" matTooltipPosition='right' matTooltipHideDelay="100">
107
- <a target="_self" href="{{ dashboard_convs_url }}" class="customAncor">
108
- <!-- <i class="material-icons sidebar-icons">forum</i> -->
109
- <span class="realtime-icon-wpr" >
110
- <svg version="1.1" id="Livello_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
111
- viewBox="0 0 24 24" style="enable-background:new 0 0 24 24;" xml:space="preserve" style="width: 30px;height: 30px;margin-top: 5px;">
112
- <path d="M17.9,11.6l-1.4,1.9l-3.2-5.6l-1-2l-0.2,0.2l-3.7,6.4l-3-4.8L2.7,9.9v2.4l2.4-1.8L9,16.2l3.3-6.2l4,6.7l2.7-3.3
113
- l0.9,0c0.5-0.7,1-1.4,1.4-2L17.9,11.6z"/>
114
- </svg>
115
- </span>
116
-
117
- </a>
118
- </div>
119
- <!-- </ng-container> -->
104
+ <ng-container *ngIf="isVisibleMON">
105
+ <div matTooltipClass="custom-mat-tooltip" matTooltip="Monitor"
106
+ #tooltip="matTooltip" matTooltipPosition='right' matTooltipHideDelay="100">
107
+ <a target="_self" href="{{ dashboard_convs_url }}" class="customAncor">
108
+ <!-- <i class="material-icons sidebar-icons">forum</i> -->
109
+ <span class="realtime-icon-wpr" >
110
+ <svg version="1.1" id="Livello_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
111
+ viewBox="0 0 24 24" style="enable-background:new 0 0 24 24;" xml:space="preserve" style="width: 30px;height: 30px;margin-top: 5px;">
112
+ <path d="M17.9,11.6l-1.4,1.9l-3.2-5.6l-1-2l-0.2,0.2l-3.7,6.4l-3-4.8L2.7,9.9v2.4l2.4-1.8L9,16.2l3.3-6.2l4,6.7l2.7-3.3
113
+ l0.9,0c0.5-0.7,1-1.4,1.4-2L17.9,11.6z"/>
114
+ </svg>
115
+ </span>
116
+
117
+ </a>
118
+ </div>
119
+ </ng-container>
120
120
 
121
121
  </div>
122
122
 
@@ -125,12 +125,14 @@
125
125
  <!-- ------------------------------------------- -->
126
126
  <!-- CONTACTS (LEADS) (click)="goToContacts()" -->
127
127
  <!-- ------------------------------------------- -->
128
- <div matTooltipClass="custom-mat-tooltip" matTooltip="{{ contacts_lbl }}"
129
- #tooltip="matTooltip" matTooltipPosition='right' matTooltipHideDelay="100">
130
- <a target="_self" href="{{ dashboard_contacts_url }}" class="customAncor">
131
- <i class="material-icons sidebar-icons">contacts</i>
132
- </a>
133
- </div>
128
+ <ng-container *ngIf="isVisibleCNT">
129
+ <div matTooltipClass="custom-mat-tooltip" matTooltip="{{ contacts_lbl }}"
130
+ #tooltip="matTooltip" matTooltipPosition='right' matTooltipHideDelay="100">
131
+ <a target="_self" href="{{ dashboard_contacts_url }}" class="customAncor">
132
+ <i class="material-icons sidebar-icons">contacts</i>
133
+ </a>
134
+ </div>
135
+ </ng-container>
134
136
 
135
137
 
136
138
  <!-- ------------------------------------------- -->
@@ -33,6 +33,8 @@ export class SidebarComponent implements OnInit {
33
33
  isVisibleAPP: boolean;
34
34
  isVisibleANA: boolean;
35
35
  isVisibleACT: boolean;
36
+ isVisibleMON: boolean;
37
+ isVisibleCNT: boolean;
36
38
  photo_profile_URL: string;
37
39
  project_id: string;
38
40
  DASHBOARD_URL: string;
@@ -298,26 +300,50 @@ export class SidebarComponent implements OnInit {
298
300
  this.isVisibleAPP = true;
299
301
  }
300
302
  }
303
+
304
+ if (key.includes("MON")) {
305
+ let lbs = key.split(":");
306
+ if (lbs[1] === "F") {
307
+ this.isVisibleMON = false;
308
+ } else {
309
+ this.isVisibleMON = true;
310
+ }
311
+ }
312
+
313
+ if (key.includes("CNT")) {
314
+ let lbs = key.split(":");
315
+ if (lbs[1] === "F") {
316
+ this.isVisibleCNT = false;
317
+ } else {
318
+ this.isVisibleCNT = true;
319
+ }
320
+ }
321
+
301
322
  });
302
323
 
303
324
 
304
325
  if (!this.public_Key.includes("ANA")) {
305
326
  this.isVisibleANA = false;
306
327
  }
307
-
308
328
  if (!this.public_Key.includes("ACT")) {
309
329
  this.isVisibleACT = false;
310
330
  }
311
-
312
-
313
331
  if (!this.public_Key.includes("APP")) {
314
332
  this.isVisibleAPP = false;
315
333
  }
334
+ if (!this.public_Key.includes("MON")) {
335
+ this.isVisibleMON = false;
336
+ }
337
+ if (!this.public_Key.includes("CNT")) {
338
+ this.isVisibleCNT = false;
339
+ }
316
340
 
317
341
  } else {
318
342
  this.isVisibleANA = false;
319
343
  this.isVisibleACT = false;
320
344
  this.isVisibleAPP = false;
345
+ this.isVisibleMON = false;
346
+ this.isVisibleCNT = false;
321
347
  }
322
348
 
323
349