@chat21/chat21-ionic 3.0.80 → 3.0.81-rc.2
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 +75 -3
- package/README.md +2 -2
- package/angular.json +1 -0
- package/deploy_amazon_beta.sh +29 -0
- package/deploy_amazon_prod.sh +30 -0
- package/package.json +2 -2
- package/src/app/app.component.html +7 -1
- package/src/app/app.component.scss +18 -2
- package/src/app/app.component.ts +113 -17
- package/src/app/app.module.ts +3 -1
- package/src/app/chatlib/conversation-detail/conversation-content/conversation-content.component.ts +8 -1
- package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.html +77 -23
- package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.scss +168 -86
- package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.ts +39 -2
- package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.html +11 -24
- package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.scss +6 -10
- package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.spec.ts +2 -2
- package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.ts +16 -25
- package/src/app/chatlib/conversation-detail/message/buttons/action-button/action-button.component.html +5 -1
- package/src/app/chatlib/conversation-detail/message/buttons/action-button/action-button.component.scss +22 -15
- package/src/app/chatlib/conversation-detail/message/buttons/action-button/action-button.component.ts +25 -5
- package/src/app/chatlib/conversation-detail/message/buttons/link-button/link-button.component.html +2 -1
- package/src/app/chatlib/conversation-detail/message/buttons/link-button/link-button.component.scss +14 -15
- package/src/app/chatlib/conversation-detail/message/buttons/link-button/link-button.component.ts +24 -5
- package/src/app/chatlib/conversation-detail/message/buttons/text-button/text-button.component.html +6 -1
- package/src/app/chatlib/conversation-detail/message/buttons/text-button/text-button.component.scss +12 -13
- package/src/app/chatlib/conversation-detail/message/buttons/text-button/text-button.component.ts +26 -5
- package/src/app/chatlib/conversation-detail/message/frame/frame.component.html +8 -2
- package/src/app/chatlib/conversation-detail/message/frame/frame.component.scss +36 -0
- package/src/app/chatlib/conversation-detail/message/frame/frame.component.ts +2 -2
- package/src/app/chatlib/conversation-detail/message/html/html.component.ts +0 -1
- package/src/app/chatlib/conversation-detail/message/image/image.component.html +1 -1
- package/src/app/chatlib/conversation-detail/message/image/image.component.scss +17 -5
- package/src/app/chatlib/conversation-detail/message/image/image.component.ts +1 -1
- package/src/app/chatlib/conversation-detail/message/info-message/info-message.component.scss +3 -2
- package/src/app/chatlib/conversation-detail/message/message-attachment/message-attachment.component.html +16 -6
- package/src/app/chatlib/conversation-detail/message/message-attachment/message-attachment.component.scss +1 -3
- package/src/app/chatlib/conversation-detail/message/message-attachment/message-attachment.component.ts +2 -0
- package/src/app/chatlib/list-conversations-component/ion-list-conversations/ion-list-conversations.component.html +78 -52
- package/src/app/chatlib/list-conversations-component/ion-list-conversations/ion-list-conversations.component.scss +62 -20
- package/src/app/chatlib/list-conversations-component/ion-list-conversations/ion-list-conversations.component.ts +14 -10
- package/src/app/components/canned-response/canned-response.component.html +9 -8
- package/src/app/components/canned-response/canned-response.component.scss +24 -2
- package/src/app/components/canned-response/canned-response.component.ts +5 -5
- package/src/app/components/contacts-directory/contacts-directory.component.html +22 -26
- package/src/app/components/contacts-directory/contacts-directory.component.scss +8 -6
- package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component.html +61 -42
- package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component.scss +98 -61
- package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component.ts +9 -25
- package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component_2.html +116 -0
- package/src/app/components/conversation-detail/message-text-area/message-text-area.component.html +8 -6
- package/src/app/components/conversation-detail/message-text-area/message-text-area.component.scss +4 -4
- package/src/app/components/conversation-detail/message-text-area/message-text-area.component.ts +25 -87
- package/src/app/components/conversation-info/info-content/info-content.component.html +2 -1
- package/src/app/components/conversation-info/info-content/info-content.component.ts +3 -2
- package/src/app/components/conversation-info/info-direct/info-direct.component.html +1 -9
- package/src/app/components/conversation-info/info-direct/info-direct.component.ts +0 -2
- package/src/app/components/conversation-info/info-group/info-group.component.html +44 -108
- package/src/app/components/conversation-info/info-group/info-group.component.scss +101 -61
- package/src/app/components/conversation-info/info-group/info-group.component.ts +1 -0
- package/src/app/components/{ddp-header/ddp-header.component.html → conversations-list/header-conversations-list/header-conversations-list.component.html} +3 -3
- package/src/app/components/{ddp-header/ddp-header.component.scss → conversations-list/header-conversations-list/header-conversations-list.component.scss} +16 -4
- package/src/app/components/{conversation-detail/bubble-my-message/bubble-my-message.component.spec.ts → conversations-list/header-conversations-list/header-conversations-list.component.spec.ts} +6 -6
- package/src/app/components/{ddp-header/ddp-header.component.ts → conversations-list/header-conversations-list/header-conversations-list.component.ts} +7 -16
- package/src/app/components/conversations-list/header-conversations-list-archived/header-conversations-list-archived.component.html +12 -0
- package/src/app/components/conversations-list/header-conversations-list-archived/header-conversations-list-archived.component.scss +14 -0
- package/src/app/components/{conversation-detail/option-header/option-header.component.spec.ts → conversations-list/header-conversations-list-archived/header-conversations-list-archived.component.spec.ts} +5 -5
- package/src/app/components/{conversation-detail/option-header/option-header.component.ts → conversations-list/header-conversations-list-archived/header-conversations-list-archived.component.ts} +5 -4
- package/src/app/components/navbar/navbar.component.html +103 -0
- package/src/app/components/navbar/navbar.component.scss +249 -0
- package/src/app/components/{ddp-header/ddp-header.component.spec.ts → navbar/navbar.component.spec.ts} +6 -6
- package/src/app/components/navbar/navbar.component.ts +189 -0
- package/src/app/components/project-item/project-item.component.html +98 -149
- package/src/app/components/project-item/project-item.component.scss +42 -35
- package/src/app/components/project-item/project-item.component.ts +16 -4
- package/src/app/components/sidebar-user-details/sidebar-user-details.component.html +3 -3
- package/src/app/components/sidebar-user-details/sidebar-user-details.component.ts +2 -7
- package/src/app/components/utils/user-presence/user-presence.component.html +7 -2
- package/src/app/components/utils/user-presence/user-presence.component.scss +35 -18
- package/src/app/components/utils/user-presence/user-presence.component.ts +6 -10
- package/src/app/pages/contacts-directory/contacts-directory.page.html +1 -1
- package/src/app/pages/contacts-directory/contacts-directory.page.scss +41 -0
- package/src/app/pages/contacts-directory/contacts-directory.page.ts +2 -0
- package/src/app/pages/conversation-detail/conversation-detail.module.ts +0 -8
- package/src/app/pages/conversation-detail/conversation-detail.page.html +40 -23
- package/src/app/pages/conversation-detail/conversation-detail.page.scss +40 -250
- package/src/app/pages/conversation-detail/conversation-detail.page.ts +184 -117
- package/src/app/pages/conversations-list/conversations-list.page.html +11 -8
- package/src/app/pages/conversations-list/conversations-list.page.scss +11 -2
- package/src/app/pages/conversations-list/conversations-list.page.ts +25 -22
- package/src/app/pages/create-canned-response/create-canned-response.page.ts +13 -13
- package/src/app/pages/loader-preview/loader-preview.page.html +1 -1
- package/src/app/pages/loader-preview/loader-preview.page.scss +4 -0
- package/src/app/pages/loader-preview/loader-preview.page.ts +1 -2
- package/src/app/pages/profile-info/profile-info.page.html +2 -4
- package/src/app/pages/unassigned-conversations/unassigned-conversations.page.html +1 -1
- package/src/app/pages/unassigned-conversations/unassigned-conversations.page.scss +42 -0
- package/src/app/pages/unassigned-conversations/unassigned-conversations.page.ts +1 -0
- package/src/app/services/canned-responses/canned-responses.service.ts +26 -0
- package/src/app/services/projects/projects.service.spec.ts +12 -0
- package/src/app/services/projects/projects.service.ts +43 -0
- package/src/app/services/tiledesk/tiledesk.service.ts +2 -26
- package/src/app/shared/shared.module.ts +24 -33
- package/src/assets/i18n/ar.json +278 -265
- package/src/assets/i18n/az.json +14 -1
- package/src/assets/i18n/de.json +15 -2
- package/src/assets/i18n/en.json +15 -2
- package/src/assets/i18n/es.json +15 -2
- package/src/assets/i18n/fr.json +14 -1
- package/src/assets/i18n/it.json +14 -1
- package/src/assets/i18n/kk.json +15 -2
- package/src/assets/i18n/pt.json +15 -2
- package/src/assets/i18n/ru.json +14 -1
- package/src/assets/i18n/sr.json +277 -264
- package/src/assets/i18n/sv.json +15 -2
- package/src/assets/i18n/tr.json +15 -2
- package/src/assets/i18n/uk.json +15 -2
- package/src/assets/i18n/uz.json +14 -1
- package/src/assets/js/chat21client.js +177 -149
- package/src/assets/sounds/interface-start.mp3 +0 -0
- package/src/assets/sounds/wheep-wheep.mp3 +0 -0
- package/src/chat-config-native-mqtt.json +5 -1
- package/src/chat21-core/models/conversation.ts +0 -1
- package/src/chat21-core/models/projects.ts +27 -0
- package/src/chat21-core/providers/firebase/firebase-typing.service.ts +7 -9
- package/src/chat21-core/utils/constants.ts +6 -1
- package/src/chat21-core/utils/convertRequestToConversation.ts +41 -0
- package/src/chat21-core/utils/user-typing/user-typing.component.html +8 -5
- package/src/chat21-core/utils/user-typing/user-typing.component.scss +87 -17
- package/src/chat21-core/utils/user-typing/user-typing.component.ts +12 -94
- package/src/chat21-core/utils/utils.ts +38 -10
- package/src/global.scss +52 -56
- package/src/index.html +2 -2
- package/src/variables.scss +30 -10
- package/src/app/components/conversation-detail/bubble-day-message/bubble-day-message.component.html +0 -3
- package/src/app/components/conversation-detail/bubble-day-message/bubble-day-message.component.scss +0 -21
- package/src/app/components/conversation-detail/bubble-day-message/bubble-day-message.component.spec.ts +0 -24
- package/src/app/components/conversation-detail/bubble-day-message/bubble-day-message.component.ts +0 -14
- package/src/app/components/conversation-detail/bubble-my-message/bubble-my-message.component.html +0 -54
- package/src/app/components/conversation-detail/bubble-my-message/bubble-my-message.component.scss +0 -98
- package/src/app/components/conversation-detail/bubble-my-message/bubble-my-message.component.ts +0 -84
- package/src/app/components/conversation-detail/bubble-others-message/bubble-others-message.component.html +0 -30
- package/src/app/components/conversation-detail/bubble-others-message/bubble-others-message.component.scss +0 -83
- package/src/app/components/conversation-detail/bubble-others-message/bubble-others-message.component.spec.ts +0 -24
- package/src/app/components/conversation-detail/bubble-others-message/bubble-others-message.component.ts +0 -68
- package/src/app/components/conversation-detail/bubble-system-message/bubble-system-message.component.html +0 -3
- package/src/app/components/conversation-detail/bubble-system-message/bubble-system-message.component.scss +0 -10
- package/src/app/components/conversation-detail/bubble-system-message/bubble-system-message.component.spec.ts +0 -24
- package/src/app/components/conversation-detail/bubble-system-message/bubble-system-message.component.ts +0 -14
- package/src/app/components/conversation-detail/option-header/option-header.component.html +0 -13
- package/src/app/components/conversation-detail/option-header/option-header.component.scss +0 -0
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ConversationModel } from 'src/chat21-core/models/conversation';
|
|
1
2
|
import { EventsService } from './../../services/events-service';
|
|
2
3
|
import { Component, EventEmitter, HostListener, OnInit, Output } from '@angular/core';
|
|
3
4
|
import { WebsocketService } from 'src/app/services/websocket/websocket.service';
|
|
@@ -11,6 +12,8 @@ import { TiledeskAuthService } from 'src/chat21-core/providers/tiledesk/tiledesk
|
|
|
11
12
|
import { TiledeskService } from 'src/app/services/tiledesk/tiledesk.service';
|
|
12
13
|
import { WebSocketJs } from 'src/app/services/websocket/websocket-js';
|
|
13
14
|
import { AppConfigProvider } from 'src/app/services/app-config';
|
|
15
|
+
import { ConvertRequestToConversation } from 'src/chat21-core/utils/convertRequestToConversation';
|
|
16
|
+
import { compareValues } from 'src/chat21-core/utils/utils';
|
|
14
17
|
|
|
15
18
|
@Component({
|
|
16
19
|
selector: 'app-project-item',
|
|
@@ -28,6 +31,7 @@ export class ProjectItemComponent implements OnInit {
|
|
|
28
31
|
tiledeskToken: string;
|
|
29
32
|
|
|
30
33
|
unservedRequestCount: number = 0;
|
|
34
|
+
unservedConversations: ConversationModel[] = [];
|
|
31
35
|
currentUserRequestCount: number;
|
|
32
36
|
ROLE_IS_AGENT: boolean;
|
|
33
37
|
currentUserId: string;
|
|
@@ -54,7 +58,8 @@ export class ProjectItemComponent implements OnInit {
|
|
|
54
58
|
public tiledeskService: TiledeskService,
|
|
55
59
|
public webSocketJs: WebSocketJs,
|
|
56
60
|
private appConfigProvider: AppConfigProvider,
|
|
57
|
-
public events: EventsService
|
|
61
|
+
public events: EventsService,
|
|
62
|
+
public convertRequestToConversation: ConvertRequestToConversation
|
|
58
63
|
) { }
|
|
59
64
|
|
|
60
65
|
ngOnInit() {
|
|
@@ -132,9 +137,10 @@ export class ProjectItemComponent implements OnInit {
|
|
|
132
137
|
'LABEL_NOT_AVAILABLE',
|
|
133
138
|
'LABEL_BUSY',
|
|
134
139
|
'VIEW_ALL_CONVERSATIONS',
|
|
135
|
-
'
|
|
136
|
-
'
|
|
137
|
-
'
|
|
140
|
+
'UnassignedConversations',
|
|
141
|
+
// 'CONVERSATIONS_IN_QUEUE',
|
|
142
|
+
// 'CONVERSATION_IN_QUEUE',
|
|
143
|
+
// 'NO_CONVERSATION_IN_QUEUE',
|
|
138
144
|
'PINNED_PROJECT',
|
|
139
145
|
'CHANGE_PINNED_PROJECT',
|
|
140
146
|
"CHANGE_TO_YOUR_STATUS_TO_AVAILABLE",
|
|
@@ -307,10 +313,16 @@ export class ProjectItemComponent implements OnInit {
|
|
|
307
313
|
if (r['status'] === 100) {
|
|
308
314
|
if (this.hasmeInAgents(r['agents']) === true) {
|
|
309
315
|
count = count + 1;
|
|
316
|
+
let conv = this.convertRequestToConversation.getConvFromRequest(r)
|
|
317
|
+
if(!this.unservedConversations.find((el) => {return el.uid === conv.uid})){
|
|
318
|
+
this.unservedConversations.push(conv)
|
|
319
|
+
this.unservedConversations.sort(compareValues('timestamp', 'desc'))
|
|
320
|
+
}
|
|
310
321
|
}
|
|
311
322
|
}
|
|
312
323
|
});
|
|
313
324
|
//not sound if unservedRequest is already chached and web-sk is closed and restart again
|
|
325
|
+
// this.logger.log('updateUnservedRequestCount::: count , unservedRequestCount ', count , this.unservedRequestCount)
|
|
314
326
|
if(count > this.unservedRequestCount ){
|
|
315
327
|
this.events.publish('unservedRequest:count', count)
|
|
316
328
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
<span class="user-details-dshbrd-lang-code" style="text-transform: uppercase;color: #647491;">
|
|
6
6
|
{{chat_lang}}
|
|
7
7
|
</span>
|
|
8
|
-
<img [src]="flag_url" style="width: auto;height: 19px; position: relative;top: 1px;">
|
|
8
|
+
<img *ngIf="flag_url" [src]="flag_url" style="width: auto;height: 19px; position: relative;top: 1px;">
|
|
9
9
|
|
|
10
10
|
</div>
|
|
11
11
|
|
|
@@ -79,11 +79,11 @@
|
|
|
79
79
|
[clearable]="false"
|
|
80
80
|
[searchable]="false">
|
|
81
81
|
<ng-template ng-label-tmp let-item="item">
|
|
82
|
-
<img style="width: 15px;height: 15px;position: relative; top: 1px;" height="15" width="15" [src]="item
|
|
82
|
+
<img style="width: 15px;height: 15px;position: relative; top: 1px;" height="15" width="15" [src]="item?.avatar" />
|
|
83
83
|
<span id="sidebaravatar_{{item.name}}" style="text-transform: capitalize; margin-left:8px"> {{item.label}} </span>
|
|
84
84
|
</ng-template>
|
|
85
85
|
<ng-template ng-option-tmp let-item="item" let-index="index">
|
|
86
|
-
<img style="width: 15px;height: 15px;position: relative; top: 1px;" height="15" width="15" [src]="item
|
|
86
|
+
<img style="width: 15px;height: 15px;position: relative; top: 1px;" height="15" width="15" [src]="item?.avatar" />
|
|
87
87
|
<span id="sidebaravatar_{{item.name}}" style="text-transform: capitalize; margin-left:8px"> {{item.label}} </span>
|
|
88
88
|
</ng-template>
|
|
89
89
|
</ng-select>
|
|
@@ -78,6 +78,8 @@ export class SidebarUserDetailsComponent implements OnInit, OnChanges {
|
|
|
78
78
|
// this.listenOpenUserSidebarEvent();
|
|
79
79
|
}
|
|
80
80
|
|
|
81
|
+
ngOnChanges() { }
|
|
82
|
+
|
|
81
83
|
subcribeToAuthStateChanged() {
|
|
82
84
|
this.messagingAuthService.BSAuthStateChanged.subscribe((state) => {
|
|
83
85
|
this.logger.log('[SIDEBAR-USER-DETAILS] BSAuthStateChanged ', state)
|
|
@@ -356,13 +358,6 @@ export class SidebarUserDetailsComponent implements OnInit, OnChanges {
|
|
|
356
358
|
});
|
|
357
359
|
}
|
|
358
360
|
|
|
359
|
-
|
|
360
|
-
ngOnChanges() { }
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
361
|
changeAvailabilityStateInUserDetailsSidebar(selectedStatusID) {
|
|
367
362
|
this.logger.log('[SIDEBAR-USER-DETAILS] - changeAvailabilityState projectid', this.project._id, ' available 1: ', selectedStatusID);
|
|
368
363
|
|
|
@@ -1,2 +1,7 @@
|
|
|
1
|
-
<div
|
|
2
|
-
<div class="
|
|
1
|
+
<div id="presence-container">
|
|
2
|
+
<div class="status-icon-container" [class.mobile]="isMobile">
|
|
3
|
+
<svg xmlns="http://www.w3.org/2000/svg" [class.online]="online" height="15" width="15" viewBox="0 0 24 24" fill="#000000"><path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></svg>
|
|
4
|
+
</div>
|
|
5
|
+
<!-- <div class="status-icon" [class.online]="online" [style.border-color]="borderColor"></div> -->
|
|
6
|
+
<div class="online-point">{{status}}</div>
|
|
7
|
+
</div>
|
|
@@ -1,24 +1,41 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
#presence-container{
|
|
2
|
+
display: flex;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.status-icon-container{
|
|
6
|
+
position: fixed;
|
|
7
|
+
top: 22px;
|
|
8
|
+
left: 30px;
|
|
9
|
+
background-color: white;
|
|
10
|
+
height: 17px;
|
|
11
|
+
width: 17px;
|
|
8
12
|
border-radius: 50%;
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
13
|
+
display: flex;
|
|
14
|
+
align-items: center;
|
|
15
|
+
justify-content: center;
|
|
16
|
+
|
|
17
|
+
&.mobile{
|
|
18
|
+
top: 36px;
|
|
19
|
+
left: 50px;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
svg{
|
|
23
|
+
fill: #f44336;
|
|
24
|
+
|
|
25
|
+
&.online{
|
|
26
|
+
fill: #4caf50;
|
|
27
|
+
}
|
|
12
28
|
}
|
|
13
29
|
|
|
14
30
|
}
|
|
31
|
+
|
|
15
32
|
.online-point {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
color:
|
|
21
|
-
font-size:
|
|
22
|
-
|
|
23
|
-
|
|
33
|
+
display: inline-flex;
|
|
34
|
+
align-items: center;
|
|
35
|
+
line-height: 1.2rem;
|
|
36
|
+
font-weight: 500;
|
|
37
|
+
color: #779bbb;
|
|
38
|
+
font-size: 10px;
|
|
39
|
+
max-width: 90%;
|
|
40
|
+
margin-right: 5px;
|
|
24
41
|
}
|
|
@@ -17,11 +17,10 @@ import { LoggerInstance } from 'src/chat21-core/providers/logger/loggerInstance'
|
|
|
17
17
|
})
|
|
18
18
|
|
|
19
19
|
export class UserPresenceComponent implements OnInit, OnDestroy {
|
|
20
|
+
|
|
20
21
|
@Input() idUser: string;
|
|
22
|
+
@Input() isMobile: boolean;
|
|
21
23
|
@Input() translationMap: Map<string, string>;
|
|
22
|
-
@Input() fontColor: string;
|
|
23
|
-
@Input() borderColor: string;
|
|
24
|
-
|
|
25
24
|
|
|
26
25
|
public online = true;
|
|
27
26
|
public status = '';
|
|
@@ -47,9 +46,6 @@ export class UserPresenceComponent implements OnInit, OnDestroy {
|
|
|
47
46
|
|
|
48
47
|
/** */
|
|
49
48
|
initialize() {
|
|
50
|
-
if (this.translationMap) {
|
|
51
|
-
this.status = this.translationMap.get('LABEL_ACTIVE_NOW');
|
|
52
|
-
}
|
|
53
49
|
this.logger.log('[USER-PRESENCE-COMP] - initialize - this.translationMap', this.translationMap);
|
|
54
50
|
this.logger.log('[USER-PRESENCE-COMP] - initialize - this.status', this.status);
|
|
55
51
|
this.logger.log('[USER-PRESENCE-COMP] - initialize - idUser ->', this.idUser);
|
|
@@ -122,11 +118,11 @@ export class UserPresenceComponent implements OnInit, OnDestroy {
|
|
|
122
118
|
this.logger.log('[USER-PRESENCE-COMP] userIsOnLine - userId: ', userId, ' - isOnline: ', isOnline);
|
|
123
119
|
this.online = isOnline;
|
|
124
120
|
if (isOnline) {
|
|
125
|
-
this.status = this.translationMap.get('
|
|
121
|
+
this.status = this.translationMap.get('LABEL_ONLINE');
|
|
126
122
|
} else {
|
|
127
|
-
this.status = this.translationMap.get('
|
|
123
|
+
this.status = this.translationMap.get('LABEL_OFFLINE');
|
|
128
124
|
if (this.lastConnectionDate && this.lastConnectionDate.trim() !== '') {
|
|
129
|
-
this.status = this.lastConnectionDate
|
|
125
|
+
this.status = this.status + ' (' + this.lastConnectionDate + ')'
|
|
130
126
|
}
|
|
131
127
|
}
|
|
132
128
|
}
|
|
@@ -141,7 +137,7 @@ export class UserPresenceComponent implements OnInit, OnDestroy {
|
|
|
141
137
|
this.logger.log('[USER-PRESENCE-COMP] userLastConnection - lastConnectionDate', lastConnectionDate);
|
|
142
138
|
this.lastConnectionDate = lastConnectionDate;
|
|
143
139
|
if (this.online === false) {
|
|
144
|
-
this.status = this.lastConnectionDate
|
|
140
|
+
this.status = this.translationMap.get('LABEL_OFFLINE') + ' (' + this.lastConnectionDate + ')'
|
|
145
141
|
}
|
|
146
142
|
}
|
|
147
143
|
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
ion-toolbar {
|
|
2
|
+
height: var(--header-height);
|
|
3
|
+
&:not(.mobile){
|
|
4
|
+
--background: var(--list-bkg-color);
|
|
5
|
+
border: none;
|
|
6
|
+
}
|
|
7
|
+
&.mobile{
|
|
8
|
+
border-bottom: 1px solid rgba(0, 0, 0, 0.05);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
ion-button{
|
|
12
|
+
--color: var(--basic-blue);
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
ion-content {
|
|
17
|
+
// overwrite inline styles
|
|
18
|
+
--offset-bottom: auto!important;
|
|
19
|
+
--overflow: hidden;
|
|
20
|
+
overflow: scroll;
|
|
21
|
+
&:not(.mobile){
|
|
22
|
+
background: var(--list-bkg-color);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
&::-webkit-scrollbar {
|
|
26
|
+
width: 6px;
|
|
27
|
+
height: 8px;
|
|
28
|
+
display: none;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
&::-webkit-scrollbar-track {
|
|
32
|
+
background: #f9f9f9;
|
|
33
|
+
}
|
|
34
|
+
&::-webkit-scrollbar-thumb {
|
|
35
|
+
background-color: #b9b9b9;
|
|
36
|
+
border-radius: 0px;
|
|
37
|
+
}
|
|
38
|
+
&::-webkit-scrollbar-thumb:hover {
|
|
39
|
+
background-color: #727272;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -17,7 +17,9 @@ import { LoggerInstance } from 'src/chat21-core/providers/logger/loggerInstance'
|
|
|
17
17
|
styleUrls: ['./contacts-directory.page.scss'],
|
|
18
18
|
})
|
|
19
19
|
export class ContactsDirectoryPage implements OnInit {
|
|
20
|
+
|
|
20
21
|
@Input() token: string;
|
|
22
|
+
@Input() isMobile: boolean;
|
|
21
23
|
// @Input() user: string;
|
|
22
24
|
|
|
23
25
|
public contacts: Array<UserModel>;
|
|
@@ -21,10 +21,6 @@ import { ConversationDetailPage } from './conversation-detail.page';
|
|
|
21
21
|
// tslint:disable-next-line: max-line-length
|
|
22
22
|
import { HeaderConversationDetailComponent } from '../../components/conversation-detail/header-conversation-detail/header-conversation-detail.component';
|
|
23
23
|
import { MessageTextAreaComponent } from '../../components/conversation-detail/message-text-area/message-text-area.component';
|
|
24
|
-
import { BubbleDayMessageComponent } from '../../components/conversation-detail/bubble-day-message/bubble-day-message.component';
|
|
25
|
-
import { BubbleSystemMessageComponent } from '../../components/conversation-detail/bubble-system-message/bubble-system-message.component';
|
|
26
|
-
import { BubbleMyMessageComponent } from '../../components/conversation-detail/bubble-my-message/bubble-my-message.component';
|
|
27
|
-
import { BubbleOthersMessageComponent } from '../../components/conversation-detail/bubble-others-message/bubble-others-message.component';
|
|
28
24
|
// import { InfoContentComponent } from '../../components/conversation-info/info-content/info-content.component';
|
|
29
25
|
// import { InfoDirectComponent } from '../../components/conversation-info/info-direct/info-direct.component';
|
|
30
26
|
import { InfoContentComponent } from 'src/app/components/conversation-info/info-content/info-content.component';
|
|
@@ -65,10 +61,6 @@ import { PickerModule } from '@ctrl/ngx-emoji-mart';
|
|
|
65
61
|
HeaderConversationDetailComponent,
|
|
66
62
|
MessageTextAreaComponent,
|
|
67
63
|
CannedResponseComponent,
|
|
68
|
-
// BubbleDayMessageComponent,
|
|
69
|
-
// BubbleSystemMessageComponent,
|
|
70
|
-
// BubbleMyMessageComponent,
|
|
71
|
-
// BubbleOthersMessageComponent,
|
|
72
64
|
// InfoContentComponent,
|
|
73
65
|
// InfoSupportGroupComponent,
|
|
74
66
|
// InfoDirectComponent,
|
|
@@ -1,23 +1,29 @@
|
|
|
1
1
|
<span *ngIf="conversationWith && loggedUser; then showConversation else showPlaceholder"></span>
|
|
2
2
|
<ng-template #showPlaceholder>
|
|
3
|
+
|
|
4
|
+
<ion-header no-border class="ion-no-border" [class.mobile]="isMobile">
|
|
5
|
+
<ion-toolbar [class.mobile]="isMobile">
|
|
6
|
+
|
|
7
|
+
</ion-toolbar>
|
|
8
|
+
</ion-header>
|
|
3
9
|
<!-- class="splash-page" -->
|
|
4
|
-
<ion-content padding>
|
|
10
|
+
<ion-content padding id="contentPlaceholder" [class.mobile]="isMobile">
|
|
5
11
|
<!-- <div padding class="image-splash-page"></div>
|
|
6
12
|
<div padding class="title-splash-page">
|
|
7
13
|
text new conversation + button
|
|
8
14
|
</div> -->
|
|
15
|
+
|
|
9
16
|
|
|
10
|
-
<ion-grid
|
|
11
|
-
<ion-row class="ion-justify-content-center ion-align-items-center" style="
|
|
17
|
+
<ion-grid class="grid_content" [class.mobile]="isMobile">
|
|
18
|
+
<ion-row class="row_content ion-justify-content-center ion-align-items-center" style="flex-direction: column">
|
|
12
19
|
<span *ngIf="isOnline === true && !showSpinner"
|
|
13
|
-
style="color: #92949c; font-size: 16px;line-height: 18px;
|
|
20
|
+
style="color: #92949c; font-size: 16px;line-height: 18px;">
|
|
14
21
|
<span *ngIf="conversation_count > 0 ">
|
|
15
22
|
{{'PleaseSelectChatToStartMessaging' | translate }}
|
|
16
23
|
</span>
|
|
17
24
|
<span *ngIf="conversation_count === 0" style="line-height: 1.2;color: #4b5258;
|
|
18
25
|
font-weight: 500;">
|
|
19
26
|
{{'ALL_CONVS_SERVED' | translate}}
|
|
20
|
-
|
|
21
27
|
</span>
|
|
22
28
|
|
|
23
29
|
</span>
|
|
@@ -37,15 +43,13 @@
|
|
|
37
43
|
[idLoggedUser]="loggedUser.uid"
|
|
38
44
|
[conversationUid]="conversationWith"
|
|
39
45
|
[conversationAvatar]="conversationAvatar"
|
|
40
|
-
[
|
|
41
|
-
[
|
|
42
|
-
[conv_type]="conv_type"
|
|
43
|
-
(eventOpenCloseInfoConversation)="returnOpenCloseInfoConversation($event)">
|
|
46
|
+
[translationsMap]="translationsHeaderMap"
|
|
47
|
+
[conv_type]="conv_type">
|
|
44
48
|
</app-header-conversation-detail>
|
|
45
49
|
|
|
46
|
-
<ion-content id="conv-details">
|
|
47
|
-
<ion-grid class="grid_content">
|
|
48
|
-
<ion-row class="row_content">
|
|
50
|
+
<ion-content id="conv-details" [class.mobile]="isMobile">
|
|
51
|
+
<ion-grid class="grid_content" [class.mobile]="isMobile">
|
|
52
|
+
<ion-row class="row_content" [class.mobile]="isMobile">
|
|
49
53
|
<ion-col id="chatArea" [class.mobile]="isMobile" [class.open]="openInfoConversation"
|
|
50
54
|
[ngClass]="{'chat-area-apps-sidebar-wide': appsidebarIsWide === true}">
|
|
51
55
|
|
|
@@ -98,10 +102,15 @@
|
|
|
98
102
|
</ng-template>
|
|
99
103
|
|
|
100
104
|
<ng-template #content_messages>
|
|
101
|
-
<ion-content #ionContentChatArea appScrollbarTheme class="ionContentChatArea"
|
|
102
|
-
(
|
|
103
|
-
(
|
|
104
|
-
(
|
|
105
|
+
<ion-content #ionContentChatArea appScrollbarTheme class="ionContentChatArea"
|
|
106
|
+
(drop)="drop($event)"
|
|
107
|
+
(dragover)="allowDrop($event)"
|
|
108
|
+
(dragleave)="drag($event)"
|
|
109
|
+
[scrollEvents]="true"
|
|
110
|
+
(ionScrollStart)="logScrollStart($event)"
|
|
111
|
+
(ionScroll)="logScrolling($event)"
|
|
112
|
+
(ionScrollEnd)="logScrollEnd($event)"
|
|
113
|
+
[class.active]="true">
|
|
105
114
|
|
|
106
115
|
<!-- ----------------------------------------------------------- -->
|
|
107
116
|
<!-- DROPZONE -->
|
|
@@ -125,7 +134,12 @@
|
|
|
125
134
|
[senderId]="loggedUser.uid"
|
|
126
135
|
[baseLocation]="window?.location?.origin"
|
|
127
136
|
[areVisibleCAR]="areVisibleCAR"
|
|
128
|
-
[supportMode]= "supportMode"
|
|
137
|
+
[supportMode]= "supportMode"
|
|
138
|
+
[isMobile]="isMobile"
|
|
139
|
+
[isTypings]="isTypings"
|
|
140
|
+
[idUserTypingNow]="idUserTypingNow"
|
|
141
|
+
[nameUserTypingNow]="nameUserTypingNow"
|
|
142
|
+
[translationMap]="translationsContentMap"
|
|
129
143
|
[stylesMap]="styleMap"
|
|
130
144
|
(onBeforeMessageRender)="onBeforeMessageRenderFN($event)"
|
|
131
145
|
(onAfterMessageRender)="onAfterMessageRenderFN($event)"
|
|
@@ -133,7 +147,8 @@
|
|
|
133
147
|
(onScrollContent)="returnOnScrollContent($event)"
|
|
134
148
|
(onMenuOptionShow)="returnOnMenuOption($event)"
|
|
135
149
|
(onElementRendered)="onElementRenderedFN($event)"
|
|
136
|
-
(onAddUploadingBubble)="addUploadingBubbleEvent($event)"
|
|
150
|
+
(onAddUploadingBubble)="addUploadingBubbleEvent($event)"
|
|
151
|
+
(onOpenCloseInfoConversation)="onOpenCloseInfoConversation($event)">
|
|
137
152
|
</ion-conversation-detail>
|
|
138
153
|
|
|
139
154
|
</ion-content>
|
|
@@ -155,7 +170,8 @@
|
|
|
155
170
|
[conversationWith]="conversationWith"
|
|
156
171
|
[conversationWithFullname]="conversationWithFullname"
|
|
157
172
|
[currentString]="messageStr"
|
|
158
|
-
[
|
|
173
|
+
[stylesMap]="styleMap"
|
|
174
|
+
[translationMap]="translationsMap"
|
|
159
175
|
(onLoadedCannedResponses)="onLoadedCannedResponses($event)"
|
|
160
176
|
(onClickCanned)="replaceTagInMessage($event)"
|
|
161
177
|
(onClickAddCannedResponse)="presentCreateCannedResponseModal()">
|
|
@@ -211,9 +227,9 @@
|
|
|
211
227
|
[loggedUser]="loggedUser"
|
|
212
228
|
[conversationWith]="conversationWith"
|
|
213
229
|
[tagsCannedFilter]="tagsCannedFilter"
|
|
214
|
-
[translationMap]="
|
|
230
|
+
[translationMap]="translationsMap"
|
|
215
231
|
[fileUploadAccept]="appConfigProvider.getConfig().fileUploadAccept"
|
|
216
|
-
[isOpenInfoConversation]="
|
|
232
|
+
[isOpenInfoConversation]="openInfoConversation"
|
|
217
233
|
[dropEvent]="dropEvent"
|
|
218
234
|
[disableTextarea]="disableTextarea"
|
|
219
235
|
(eventChangeTextArea)="returnChangeTextArea($event)"
|
|
@@ -230,10 +246,11 @@
|
|
|
230
246
|
[ngClass]="{'info-convs-apps-sidebar-wide': appsidebarIsWide === true}">
|
|
231
247
|
<app-info-content
|
|
232
248
|
[openInfoConversation]="openInfoConversation"
|
|
233
|
-
[translationMap]="translationMap"
|
|
234
249
|
[loggedUser]="loggedUser"
|
|
235
250
|
[tenant]="tenant"
|
|
236
|
-
[groupDetail]="groupDetail"
|
|
251
|
+
[groupDetail]="groupDetail"
|
|
252
|
+
[isMobile]="isMobile"
|
|
253
|
+
[translationMap]="translationsMap">
|
|
237
254
|
</app-info-content>
|
|
238
255
|
</ion-col>
|
|
239
256
|
|