@chat21/chat21-ionic 3.0.80-rc.1 → 3.0.80

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 (141) hide show
  1. package/CHANGELOG.md +4 -61
  2. package/README.md +2 -2
  3. package/package.json +2 -2
  4. package/src/app/app.component.html +1 -7
  5. package/src/app/app.component.scss +2 -18
  6. package/src/app/app.component.ts +15 -73
  7. package/src/app/app.module.ts +1 -3
  8. package/src/app/chatlib/conversation-detail/conversation-content/conversation-content.component.ts +1 -8
  9. package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.html +23 -75
  10. package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.scss +85 -162
  11. package/src/app/chatlib/conversation-detail/ion-conversation-detail/ion-conversation-detail.component.ts +2 -39
  12. package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.html +19 -7
  13. package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.scss +10 -6
  14. package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.spec.ts +2 -2
  15. package/src/app/chatlib/conversation-detail/message/bubble-message/bubble-message.component.ts +25 -16
  16. package/src/app/chatlib/conversation-detail/message/buttons/action-button/action-button.component.html +1 -5
  17. package/src/app/chatlib/conversation-detail/message/buttons/action-button/action-button.component.scss +15 -22
  18. package/src/app/chatlib/conversation-detail/message/buttons/action-button/action-button.component.ts +5 -25
  19. package/src/app/chatlib/conversation-detail/message/buttons/link-button/link-button.component.html +1 -2
  20. package/src/app/chatlib/conversation-detail/message/buttons/link-button/link-button.component.scss +15 -14
  21. package/src/app/chatlib/conversation-detail/message/buttons/link-button/link-button.component.ts +5 -24
  22. package/src/app/chatlib/conversation-detail/message/buttons/text-button/text-button.component.html +1 -6
  23. package/src/app/chatlib/conversation-detail/message/buttons/text-button/text-button.component.scss +13 -12
  24. package/src/app/chatlib/conversation-detail/message/buttons/text-button/text-button.component.ts +5 -26
  25. package/src/app/chatlib/conversation-detail/message/html/html.component.ts +1 -0
  26. package/src/app/chatlib/conversation-detail/message/info-message/info-message.component.scss +2 -2
  27. package/src/app/chatlib/conversation-detail/message/message-attachment/message-attachment.component.html +6 -16
  28. package/src/app/chatlib/conversation-detail/message/message-attachment/message-attachment.component.scss +3 -1
  29. package/src/app/chatlib/conversation-detail/message/message-attachment/message-attachment.component.ts +0 -2
  30. package/src/app/chatlib/list-conversations-component/ion-list-conversations/ion-list-conversations.component.html +52 -78
  31. package/src/app/chatlib/list-conversations-component/ion-list-conversations/ion-list-conversations.component.scss +20 -62
  32. package/src/app/chatlib/list-conversations-component/ion-list-conversations/ion-list-conversations.component.ts +10 -14
  33. package/src/app/components/canned-response/canned-response.component.html +5 -5
  34. package/src/app/components/canned-response/canned-response.component.scss +1 -1
  35. package/src/app/components/canned-response/canned-response.component.ts +0 -1
  36. package/src/app/components/contacts-directory/contacts-directory.component.html +26 -22
  37. package/src/app/components/contacts-directory/contacts-directory.component.scss +6 -8
  38. package/src/app/components/conversation-detail/bubble-day-message/bubble-day-message.component.html +3 -0
  39. package/src/app/components/conversation-detail/bubble-day-message/bubble-day-message.component.scss +21 -0
  40. package/src/app/components/conversation-detail/bubble-day-message/bubble-day-message.component.spec.ts +24 -0
  41. package/src/app/components/conversation-detail/bubble-day-message/bubble-day-message.component.ts +14 -0
  42. package/src/app/components/conversation-detail/bubble-my-message/bubble-my-message.component.html +54 -0
  43. package/src/app/components/conversation-detail/bubble-my-message/bubble-my-message.component.scss +98 -0
  44. package/src/app/components/{conversations-list/header-conversations-list/header-conversations-list.component.spec.ts → conversation-detail/bubble-my-message/bubble-my-message.component.spec.ts} +6 -6
  45. package/src/app/components/conversation-detail/bubble-my-message/bubble-my-message.component.ts +84 -0
  46. package/src/app/components/conversation-detail/bubble-others-message/bubble-others-message.component.html +30 -0
  47. package/src/app/components/conversation-detail/bubble-others-message/bubble-others-message.component.scss +83 -0
  48. package/src/app/components/conversation-detail/bubble-others-message/bubble-others-message.component.spec.ts +24 -0
  49. package/src/app/components/conversation-detail/bubble-others-message/bubble-others-message.component.ts +68 -0
  50. package/src/app/components/conversation-detail/bubble-system-message/bubble-system-message.component.html +3 -0
  51. package/src/app/components/conversation-detail/bubble-system-message/bubble-system-message.component.scss +10 -0
  52. package/src/app/components/conversation-detail/bubble-system-message/bubble-system-message.component.spec.ts +24 -0
  53. package/src/app/components/conversation-detail/bubble-system-message/bubble-system-message.component.ts +14 -0
  54. package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component.html +42 -61
  55. package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component.scss +61 -98
  56. package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component.ts +25 -9
  57. package/src/app/components/conversation-detail/message-text-area/message-text-area.component.html +5 -6
  58. package/src/app/components/conversation-detail/message-text-area/message-text-area.component.scss +4 -4
  59. package/src/app/components/conversation-detail/message-text-area/message-text-area.component.ts +83 -4
  60. package/src/app/components/conversation-detail/option-header/option-header.component.html +13 -0
  61. package/src/app/components/conversation-detail/option-header/option-header.component.scss +0 -0
  62. package/src/app/components/{conversations-list/header-conversations-list-archived/header-conversations-list-archived.component.spec.ts → conversation-detail/option-header/option-header.component.spec.ts} +5 -5
  63. package/src/app/components/{conversations-list/header-conversations-list-archived/header-conversations-list-archived.component.ts → conversation-detail/option-header/option-header.component.ts} +4 -5
  64. package/src/app/components/conversation-info/info-content/info-content.component.html +1 -2
  65. package/src/app/components/conversation-info/info-content/info-content.component.ts +2 -3
  66. package/src/app/components/conversation-info/info-direct/info-direct.component.html +9 -1
  67. package/src/app/components/conversation-info/info-direct/info-direct.component.ts +2 -0
  68. package/src/app/components/conversation-info/info-group/info-group.component.html +108 -44
  69. package/src/app/components/conversation-info/info-group/info-group.component.scss +61 -101
  70. package/src/app/components/conversation-info/info-group/info-group.component.ts +0 -1
  71. package/src/app/components/{conversations-list/header-conversations-list/header-conversations-list.component.html → ddp-header/ddp-header.component.html} +3 -3
  72. package/src/app/components/{conversations-list/header-conversations-list/header-conversations-list.component.scss → ddp-header/ddp-header.component.scss} +4 -16
  73. package/src/app/components/{navbar/navbar.component.spec.ts → ddp-header/ddp-header.component.spec.ts} +6 -6
  74. package/src/app/components/{conversations-list/header-conversations-list/header-conversations-list.component.ts → ddp-header/ddp-header.component.ts} +16 -7
  75. package/src/app/components/project-item/project-item.component.html +149 -98
  76. package/src/app/components/project-item/project-item.component.scss +35 -42
  77. package/src/app/components/project-item/project-item.component.ts +4 -16
  78. package/src/app/components/sidebar-user-details/sidebar-user-details.component.html +3 -3
  79. package/src/app/components/sidebar-user-details/sidebar-user-details.component.ts +7 -2
  80. package/src/app/components/utils/user-presence/user-presence.component.html +2 -7
  81. package/src/app/components/utils/user-presence/user-presence.component.scss +18 -35
  82. package/src/app/components/utils/user-presence/user-presence.component.ts +10 -6
  83. package/src/app/pages/contacts-directory/contacts-directory.page.html +1 -1
  84. package/src/app/pages/contacts-directory/contacts-directory.page.scss +0 -41
  85. package/src/app/pages/contacts-directory/contacts-directory.page.ts +0 -2
  86. package/src/app/pages/conversation-detail/conversation-detail.module.ts +8 -0
  87. package/src/app/pages/conversation-detail/conversation-detail.page.html +23 -40
  88. package/src/app/pages/conversation-detail/conversation-detail.page.scss +250 -40
  89. package/src/app/pages/conversation-detail/conversation-detail.page.ts +84 -190
  90. package/src/app/pages/conversations-list/conversations-list.page.html +8 -11
  91. package/src/app/pages/conversations-list/conversations-list.page.scss +2 -11
  92. package/src/app/pages/conversations-list/conversations-list.page.ts +22 -25
  93. package/src/app/pages/create-canned-response/create-canned-response.page.ts +13 -13
  94. package/src/app/pages/loader-preview/loader-preview.page.html +1 -1
  95. package/src/app/pages/loader-preview/loader-preview.page.scss +0 -4
  96. package/src/app/pages/loader-preview/loader-preview.page.ts +2 -1
  97. package/src/app/pages/profile-info/profile-info.page.html +4 -2
  98. package/src/app/pages/unassigned-conversations/unassigned-conversations.page.html +1 -1
  99. package/src/app/pages/unassigned-conversations/unassigned-conversations.page.scss +0 -42
  100. package/src/app/pages/unassigned-conversations/unassigned-conversations.page.ts +0 -1
  101. package/src/app/services/canned-responses/canned-responses.service.ts +0 -26
  102. package/src/app/services/tiledesk/tiledesk.service.ts +25 -1
  103. package/src/app/shared/shared.module.ts +33 -24
  104. package/src/assets/i18n/ar.json +265 -278
  105. package/src/assets/i18n/az.json +1 -14
  106. package/src/assets/i18n/de.json +2 -15
  107. package/src/assets/i18n/en.json +2 -15
  108. package/src/assets/i18n/es.json +2 -15
  109. package/src/assets/i18n/fr.json +1 -14
  110. package/src/assets/i18n/it.json +1 -14
  111. package/src/assets/i18n/kk.json +2 -15
  112. package/src/assets/i18n/pt.json +2 -15
  113. package/src/assets/i18n/ru.json +1 -14
  114. package/src/assets/i18n/sr.json +264 -277
  115. package/src/assets/i18n/sv.json +2 -15
  116. package/src/assets/i18n/tr.json +2 -15
  117. package/src/assets/i18n/uk.json +2 -15
  118. package/src/assets/i18n/uz.json +1 -14
  119. package/src/chat21-core/models/conversation.ts +1 -0
  120. package/src/chat21-core/providers/firebase/firebase-typing.service.ts +9 -7
  121. package/src/chat21-core/utils/constants.ts +1 -5
  122. package/src/chat21-core/utils/user-typing/user-typing.component.html +5 -8
  123. package/src/chat21-core/utils/user-typing/user-typing.component.scss +17 -87
  124. package/src/chat21-core/utils/user-typing/user-typing.component.ts +94 -12
  125. package/src/chat21-core/utils/utils.ts +10 -38
  126. package/src/global.scss +57 -48
  127. package/src/index.html +2 -2
  128. package/src/variables.scss +10 -30
  129. package/deploy_amazon_beta.sh +0 -29
  130. package/deploy_amazon_prod.sh +0 -30
  131. package/src/app/components/conversation-detail/header-conversation-detail/header-conversation-detail.component_2.html +0 -116
  132. package/src/app/components/conversations-list/header-conversations-list-archived/header-conversations-list-archived.component.html +0 -12
  133. package/src/app/components/conversations-list/header-conversations-list-archived/header-conversations-list-archived.component.scss +0 -14
  134. package/src/app/components/navbar/navbar.component.html +0 -103
  135. package/src/app/components/navbar/navbar.component.scss +0 -249
  136. package/src/app/components/navbar/navbar.component.ts +0 -189
  137. package/src/app/services/projects/projects.service.spec.ts +0 -12
  138. package/src/app/services/projects/projects.service.ts +0 -43
  139. package/src/assets/sounds/wheep-wheep.mp3 +0 -0
  140. package/src/chat21-core/models/projects.ts +0 -27
  141. package/src/chat21-core/utils/convertRequestToConversation.ts +0 -41
@@ -1,107 +1,158 @@
1
1
  <div class="main-content main-content-project-for-panel">
2
-
3
- <!-- <div class="pinned-project">Pinned project </div> margin-left:4px -->
4
- <div *ngIf="project?.id_project?.status !== 0" class="flex-container-project-for-panel project-row">
5
- <div class="flex-child-left" [tooltip]="conversationsInQueueOnProjectName" [options]="tooltipOptions" placement="top"
6
- content-type="template" (click)="openUnservedConvs()">
7
- <div class="unassigned-notifications-icon-wpr">
8
- <svg viewBox="0 0 24 24" preserveAspectRatio="xMidYMid meet" focusable="false" class="style-scope yt-icon">
9
- <g class="style-scope yt-icon">
10
- <path
11
- d="M10,20h4c0,1.1-0.9,2-2,2S10,21.1,10,20z M20,17.35V19H4v-1.65l2-1.88v-5.15c0-2.92,1.56-5.22,4-5.98V3.96 c0-1.42,1.49-2.5,2.99-1.76C13.64,2.52,14,3.23,14,3.96l0,0.39c2.44,0.75,4,3.06,4,5.98v5.15L20,17.35z M19,17.77l-2-1.88v-5.47 c0-2.47-1.19-4.36-3.13-5.1c-1.26-0.53-2.64-0.5-3.84,0.03C8.15,6.11,7,7.99,7,10.42v5.47l-2,1.88V18h14V17.77z"
12
- class="style-scope yt-icon"></path>
13
- </g>
14
- </svg>
15
- </div>
16
- <div class="unassigned-notifications-badge" *ngIf="unservedRequestCount > 0">
17
- <!-- || currentUserRequestCount > 0 -->
18
- <!-- <span *ngIf="unservedRequestCount > 0 "> -->
19
- <!-- + currentUserRequestCount -->
20
- <span class="notification-count">{{ unservedRequestCount }}</span>
21
- </div>
22
- </div>
23
-
24
-
25
- <div class="flex-child-right">
26
- <div class="project-name-project-for-panel" [tooltip]="conversationsInQueueOnProjectName"
27
- [options]="tooltipOptions" placement="top" content-type="template" (click)="openUnservedConvs()">
28
- <div class="unassigned_label"> <a>{{ translationMap?.get('UnassignedConversations') }}</a> </div>
29
- </div>
30
-
31
- <!-- <div class="availabily-and-busy-wpr">
32
- <div class="availabily---wpr" tooltip="{{avaialble_status_for_tooltip}}" [options]="tooltipOptions">
33
- <div class="onoffswitch"
34
- (click)="$event.stopPropagation();changeAvailabilityState(project?.id_project?._id, project?.ws_projct_user_available)">
35
- <input type="checkbox" name="onoffswitch" class="onoffswitch-checkbox"
36
- id="switchavailableunavailablestatus" tabindex="0" [checked]="project?.ws_projct_user_available">
37
- <label class="onoffswitch-label" for="switchavailableunavailablestatus"></label>
2
+ <div class="container-fluid container-project-for-panel">
3
+
4
+ <div class="left-sidebar">
5
+
6
+ <!-- <loading-spinner *ngIf="showSpinner"></loading-spinner> -->
7
+ <!-- *ngIf="!showSpinner" -->
8
+ <div class="left-sidebar-project" style="margin-right: -10px;">
9
+
10
+ <div class="small-projects-sidebar">
11
+ <!-- <div class="pinned-project">Pinned project </div> margin-left:4px -->
12
+ <div *ngIf="project?.id_project?.status !== 0" class="flex-container-project-for-panel project-row">
13
+ <div class="flex-child-left" [tooltip]="conversationsInQueue" [options]="tooltipOptions" placement="top"
14
+ content-type="template" (click)="openUnservedConvs()">
15
+ <div class="unassigned-notifications-icon-wpr">
16
+ <svg viewBox="0 0 24 24" preserveAspectRatio="xMidYMid meet" focusable="false"
17
+ class="style-scope yt-icon"
18
+ style="pointer-events: none; width: 37px; height:auto; fill: rgb(107,107,107);margin-top: 9px;">
19
+ <g class="style-scope yt-icon">
20
+ <path
21
+ d="M10,20h4c0,1.1-0.9,2-2,2S10,21.1,10,20z M20,17.35V19H4v-1.65l2-1.88v-5.15c0-2.92,1.56-5.22,4-5.98V3.96 c0-1.42,1.49-2.5,2.99-1.76C13.64,2.52,14,3.23,14,3.96l0,0.39c2.44,0.75,4,3.06,4,5.98v5.15L20,17.35z M19,17.77l-2-1.88v-5.47 c0-2.47-1.19-4.36-3.13-5.1c-1.26-0.53-2.64-0.5-3.84,0.03C8.15,6.11,7,7.99,7,10.42v5.47l-2,1.88V18h14V17.77z"
22
+ class="style-scope yt-icon"></path>
23
+ </g>
24
+ </svg>
25
+ </div>
26
+ <div class="unassigned-notifications-badge" *ngIf="unservedRequestCount > 0">
27
+ <!-- || currentUserRequestCount > 0 -->
28
+ <!-- <span *ngIf="unservedRequestCount > 0 "> -->
29
+ <!-- + currentUserRequestCount -->
30
+ <span class="notification-count">{{ unservedRequestCount }}</span>
31
+ </div>
38
32
  </div>
39
- </div>
40
33
 
34
+ <ng-template #conversationsInQueue>
35
+ <span *ngIf="unservedRequestCount > 1">
36
+ {{ unservedRequestCount }}
37
+ {{translationMap?.get('CONVERSATIONS_IN_QUEUE') }}
38
+ </span>
39
+ <span *ngIf="unservedRequestCount === 1">
40
+ {{ unservedRequestCount }}
41
+ {{translationMap?.get('CONVERSATION_IN_QUEUE') }}
42
+ </span>
43
+ <span *ngIf="unservedRequestCount === 0">
44
+ {{translationMap?.get('NO_CONVERSATION_IN_QUEUE') }}
45
+
46
+ </span>
47
+ </ng-template>
48
+
49
+
50
+ <div class="flex-child-right">
51
+ <div class="project-name-project-for-panel" [ngClass]="{'project-name-project-for-panel-on-desktop': IS_ON_MOBILE_DEVICE === false}" [tooltip]="conversationsInQueueOnProjectName"
52
+ [options]="tooltipOptions" placement="top" content-type="template" (click)="openUnservedConvs()">
53
+ <div class="project---name"> {{ project?.id_project?.name }} </div>
54
+ </div>
55
+ <ng-template #conversationsInQueueOnProjectName>
56
+ <span *ngIf="unservedRequestCount > 1">
57
+ {{ unservedRequestCount }}
58
+ {{translationMap?.get('CONVERSATIONS_IN_QUEUE') }}
59
+ </span>
60
+ <span *ngIf="unservedRequestCount === 1">
61
+ {{ unservedRequestCount }}
62
+ {{translationMap?.get('CONVERSATION_IN_QUEUE') }}
63
+ </span>
64
+ <span *ngIf="unservedRequestCount === 0">
65
+ {{translationMap?.get('NO_CONVERSATION_IN_QUEUE') }}
66
+ </span>
67
+ </ng-template>
68
+
69
+ <!-- <div class="availabily-and-busy-wpr">
70
+ <div class="availabily---wpr" tooltip="{{avaialble_status_for_tooltip}}" [options]="tooltipOptions">
71
+ <div class="onoffswitch"
72
+ (click)="$event.stopPropagation();changeAvailabilityState(project?.id_project?._id, project?.ws_projct_user_available)">
73
+ <input type="checkbox" name="onoffswitch" class="onoffswitch-checkbox"
74
+ id="switchavailableunavailablestatus" tabindex="0" [checked]="project?.ws_projct_user_available">
75
+ <label class="onoffswitch-label" for="switchavailableunavailablestatus"></label>
76
+ </div>
77
+ </div>
78
+
79
+
80
+ <!- - (click)="$event.stopPropagation();changeAvailabilityState(project?.id_project?._id, project?.ws_projct_user_available)" - ->
81
+ <span *ngIf="project?.ws_projct_user_available === true" class="availibility-status-text"
82
+ [ngClass]="{'online-text-color' : project?.ws_projct_user_available === true, 'offline-text-color' : project?.ws_projct_user_available === false}">
83
+ {{translationMap?.get('LABEL_AVAILABLE') }}
84
+ </span>
85
+ <!- - (click)="$event.stopPropagation();changeAvailabilityState(project?.id_project?._id, project?.ws_projct_user_available)" - ->
86
+ <span *ngIf="project?.ws_projct_user_available === false" class="availibility-status-text"
87
+ [ngClass]="{'online-text-color' : project?.ws_projct_user_available === true, 'offline-text-color' : project?.ws_projct_user_available === false}">
88
+ {{translationMap?.get('LABEL_NOT_AVAILABLE')}}
89
+ </span>
90
+
91
+ <div class="project-item--isBusy-icon-wpr" *ngIf="project?.ws_projct_user_isBusy === true" tooltip="{{translationMap?.get('LABEL_BUSY')}}"
92
+ [options]="tooltipOptions" placement="top" >
93
+ <svg xmlns="http://www.w3.org/2000/svg" enable-background="new 0 0 24 24" height="16px"
94
+ viewBox="0 0 24 24" width="16px" fill="#FEB92C">
95
+ <g><path d="M0,0h24v24H0V0z" fill="none" /></g>
96
+ <g><path d="M11.99,2C6.47,2,2,6.48,2,12s4.47,10,9.99,10C17.52,22,22,17.52,22,12S17.52,2,11.99,2z M15.29,16.71L11,12.41V7h2v4.59 l3.71,3.71L15.29,16.71z" /></g>
97
+ </svg>
98
+ </div>
99
+ </div>
100
+ </div> -->
101
+
102
+ <div *ngIf="IS_ON_MOBILE_DEVICE === true" class="flex-child-view-all-convs">
103
+ <div class="view-all-convs-icon-wpr" style="cursor: pointer;" [tooltip]="viewAllConvs"
104
+ [options]="tooltipOptions" placement="top" content-type="template">
105
+
106
+ <ion-button ion-button fill="clear" class="open-unserved-convs-btn"
107
+ (click)="openUnservedConvsAndGoToProjectList()">
108
+
109
+ <span class="push-icon-and-list-wpr">
110
+ <!-- <svg version="1.1" id="Livello_1" xmlns="http://www.w3.org/2000/svg"
111
+ xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 24 24"
112
+ style="enable-background:new 0 0 24 24;" xml:space="preserve" style="width: 20px;">
113
+ <style type="text/css">
114
+ .st0 {
115
+ fill: #3880ff;
116
+ }
117
+ </style>
118
+ <path class="st0"
119
+ d="M22.8,15v-2c-1.7,0-3-1.3-3-3V5h1c0.5,0,1-0.5,1-1s-0.5-1-1-1h-10c-0.5,0-1,0.5-1,1s0.5,1,1,1h1v5
120
+ c0,1.7-1.3,3-3,3v2h6v5c0.6,0,1.4,0,2,0v-5H22.8z M12.8,13c0.7-0.9,1-1.9,1-3V5h4v5c0,1.1,0.4,2.2,1,3H12.8z" />
121
+ <rect x="1.2" y="13" class="st0" width="6.3" height="2" />
122
+ <rect x="1.2" y="18" class="st0" width="12.1" height="2" />
123
+ <rect x="1.2" y="7.6" class="st0" width="9.2" height="2" />
124
+ </svg> -->
125
+
126
+ <svg version="1.1" id="Livello_1" xmlns="http://www.w3.org/2000/svg"
127
+ xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 24 24"
128
+ style="enable-background:new 0 0 24 24;" xml:space="preserve" style="width: 16px;">
129
+ <style type="text/css">
130
+ .st0 {
131
+ fill: #165CEE;
132
+ }
133
+ </style>
134
+ <path class="st0" d="M20.6,16.3v-2.4c-2.1,0-3.7-1.6-3.7-3.7V4h1.2c0.6,0,1.2-0.6,1.2-1.2s-0.6-1.2-1.2-1.2H5.9
135
+ c-0.6,0-1.2,0.6-1.2,1.2S5.3,4,5.9,4h1.2v6.1c0,2.1-1.6,3.7-3.7,3.7v2.4h7.3v6.1c0.7,0,1.7,0,2.4,0v-6.1H20.6z M8.3,13.8
136
+ c0.9-1.1,1.2-2.3,1.2-3.7V4h4.9v6.1c0,1.3,0.5,2.7,1.2,3.7H8.3z" />
137
+ </svg>
138
+ </span>
139
+
140
+
141
+
142
+ </ion-button>
143
+ </div>
144
+ <ng-template #viewAllConvs>
145
+ <span>
146
+ {{translationMap?.get('CHANGE_PINNED_PROJECT') }}</span>
147
+ </ng-template>
148
+ </div>
41
149
 
42
- <!- - (click)="$event.stopPropagation();changeAvailabilityState(project?.id_project?._id, project?.ws_projct_user_available)" - ->
43
- <span *ngIf="project?.ws_projct_user_available === true" class="availibility-status-text"
44
- [ngClass]="{'online-text-color' : project?.ws_projct_user_available === true, 'offline-text-color' : project?.ws_projct_user_available === false}">
45
- {{translationMap?.get('LABEL_AVAILABLE') }}
46
- </span>
47
- <!- - (click)="$event.stopPropagation();changeAvailabilityState(project?.id_project?._id, project?.ws_projct_user_available)" - ->
48
- <span *ngIf="project?.ws_projct_user_available === false" class="availibility-status-text"
49
- [ngClass]="{'online-text-color' : project?.ws_projct_user_available === true, 'offline-text-color' : project?.ws_projct_user_available === false}">
50
- {{translationMap?.get('LABEL_NOT_AVAILABLE')}}
51
- </span>
52
-
53
- <div class="project-item--isBusy-icon-wpr" *ngIf="project?.ws_projct_user_isBusy === true" tooltip="{{translationMap?.get('LABEL_BUSY')}}"
54
- [options]="tooltipOptions" placement="top" >
55
- <svg xmlns="http://www.w3.org/2000/svg" enable-background="new 0 0 24 24" height="16px"
56
- viewBox="0 0 24 24" width="16px" fill="#FEB92C">
57
- <g><path d="M0,0h24v24H0V0z" fill="none" /></g>
58
- <g><path d="M11.99,2C6.47,2,2,6.48,2,12s4.47,10,9.99,10C17.52,22,22,17.52,22,12S17.52,2,11.99,2z M15.29,16.71L11,12.41V7h2v4.59 l3.71,3.71L15.29,16.71z" /></g>
59
- </svg>
60
150
  </div>
61
151
  </div>
62
- </div> -->
63
-
64
- <!-- <div *ngIf="IS_ON_MOBILE_DEVICE === true" class="flex-child-view-all-convs">
65
- <div class="view-all-convs-icon-wpr" style="cursor: pointer;" [tooltip]="viewAllConvs"
66
- [options]="tooltipOptions" placement="top" content-type="template">
67
152
 
68
- <ion-button ion-button fill="clear" class="open-unserved-convs-btn"
69
- (click)="openUnservedConvsAndGoToProjectList()">
70
-
71
- <span class="push-icon-and-list-wpr">
72
- <svg version="1.1" id="Livello_1" xmlns="http://www.w3.org/2000/svg"
73
- xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 24 24"
74
- style="enable-background:new 0 0 24 24;" xml:space="preserve" style="width: 16px;">
75
- <style type="text/css">
76
- .st0 {
77
- fill: #165CEE;
78
- }
79
- </style>
80
- <path class="st0" d="M20.6,16.3v-2.4c-2.1,0-3.7-1.6-3.7-3.7V4h1.2c0.6,0,1.2-0.6,1.2-1.2s-0.6-1.2-1.2-1.2H5.9
81
- c-0.6,0-1.2,0.6-1.2,1.2S5.3,4,5.9,4h1.2v6.1c0,2.1-1.6,3.7-3.7,3.7v2.4h7.3v6.1c0.7,0,1.7,0,2.4,0v-6.1H20.6z M8.3,13.8
82
- c0.9-1.1,1.2-2.3,1.2-3.7V4h4.9v6.1c0,1.3,0.5,2.7,1.2,3.7H8.3z" />
83
- </svg>
84
- </span>
85
-
86
-
87
-
88
- </ion-button>
89
- </div>
90
- <ng-template #viewAllConvs>
91
- <span>
92
- {{translationMap?.get('CHANGE_PINNED_PROJECT') }}</span>
93
- </ng-template>
94
- </div> -->
153
+ <!-- </div> -->
95
154
 
155
+ </div>
96
156
  </div>
97
-
98
-
99
- </div>
100
-
101
-
102
- <ng-template #conversationsInQueueOnProjectName>
103
- <span>
104
- ({{ unservedRequestCount }})
105
- {{translationMap?.get('UnassignedConversations') }}
106
- </span>
107
- </ng-template>
157
+ </div>
158
+ </div>
@@ -4,10 +4,13 @@
4
4
  padding-top: 0px;
5
5
  margin-top: 0px !important;
6
6
  padding-bottom: 0px !important;
7
+ // background: #fff;
7
8
  padding-left: 0px;
8
9
  width: 100%;
9
- // min-height: 64px;
10
- // height: 64px;
10
+ // min-height: 70px;
11
+ // height: 70px;
12
+ min-height: 64px;
13
+ height: 64px;
11
14
  position: relative;
12
15
  // top: -5px; //nk x AS
13
16
  }
@@ -212,10 +215,14 @@
212
215
  }
213
216
  }
214
217
 
218
+ .container-project-for-panel {
219
+ padding: 0px !important;
220
+ width: 296px;
221
+ }
222
+
215
223
  .flex-container-project-for-panel {
216
224
  display: flex;
217
- // width: 100%;
218
- // height: 64px;
225
+ width: 100%;
219
226
  justify-content: center;
220
227
  align-items: center;
221
228
  // position: relative;
@@ -224,18 +231,17 @@
224
231
  -o-transition: all 0.2s ease-in;
225
232
  -webkit-transition: all 0.2s ease-in;
226
233
  transition: all 0.2s ease-in;
227
- margin: 6px;
228
- // background-color: rgba(24, 119, 242, 0.1);
229
- border-radius: 5px;
234
+ height: 64px;
230
235
  }
231
236
 
232
- .flex-container-project-for-panel:hover {
233
- background-color: rgba(24, 119, 242, 0.2);
237
+ .flex-container:hover {
238
+ background-color: rgba(200, 200, 200, 0.2);
234
239
  }
235
240
 
236
241
  .flex-child-right {
237
242
  flex: 1;
238
- // padding: 18px 0px;
243
+ padding: 18px 0px;
244
+ // height: 100%;
239
245
  }
240
246
 
241
247
 
@@ -243,7 +249,7 @@
243
249
  // flex: 0 0 20%;
244
250
  width: 60px;
245
251
  text-align: center;
246
- // padding: 18px 0px;
252
+ padding: 18px 0px;
247
253
  height: 100%;
248
254
  }
249
255
  // border: 2px solid yellow;
@@ -303,21 +309,22 @@
303
309
  color: #1e2129;
304
310
  font-weight: 400;
305
311
  margin-left: 10px;
306
- width: 250px;
312
+ width: 185px ;
307
313
  // width: 220px !important;
308
314
  white-space: nowrap !important;
309
315
  overflow: hidden !important;
310
316
  text-overflow: ellipsis !important;
311
317
  font-family: Helvetica, Helvetica, Arial, sans-serif;
312
- font-size: 16px; //14px;
318
+ font-size: 14px;
313
319
  position: relative;
320
+ top: -1px;
314
321
  cursor: pointer;
315
- a {
316
- color: #779bbb
317
- }
318
322
  }
319
323
 
320
324
 
325
+ .project-name-project-for-panel-on-desktop {
326
+ width: 217px
327
+ }
321
328
 
322
329
  // .project-name-project-for-panel:hover span {
323
330
  // color: rgba(0, 0, 0, 0.35);
@@ -325,13 +332,12 @@
325
332
  // width: fit-content;
326
333
  // display: block;
327
334
  // }
328
- .unassigned_label {
335
+ .project---name {
329
336
  width: fit-content;
330
337
 
331
338
  }
332
- .unassigned_label:hover {
333
- color: rgb(100, 131, 158);
334
- // font-weight: 600;
339
+ .project---name:hover {
340
+ color: rgba(0, 0, 0, 0.35);
335
341
  }
336
342
 
337
343
  .view-all-convs-icon:hover {
@@ -446,21 +452,13 @@
446
452
  // top: 3px;
447
453
 
448
454
  position: relative;
449
- // top: -8px;
455
+ top: -8px;
450
456
  background: transparent;
451
457
  border-radius: 50%;
452
- width: 40px; //50px;
458
+ width: 50px;
453
459
  left: 10px;
454
- height: 40px; //50px;
460
+ height: 50px;
455
461
  cursor: pointer;
456
-
457
- svg {
458
- pointer-events: none;
459
- width: 30px;
460
- height: auto;
461
- fill: #779bbb; //rgb(107,107,107);
462
- margin-top: 7px;
463
- }
464
462
  }
465
463
  .unassigned-notifications-icon-wpr:hover {
466
464
  background-color: rgba(0, 0, 0, 0.05);
@@ -469,28 +467,23 @@
469
467
  .unassigned-notifications-badge {
470
468
  position: absolute;
471
469
  // top: 12px;
472
- top: 6px;//14px;
470
+ top: 14px;
473
471
  border-radius: 50%;
474
472
  background: #e41e3f;
475
473
  // width: 24px;
476
474
  // height: 24px;
477
- width: 20px; //22px;
478
- height: 20px; //22px;
475
+ width: 22px;
476
+ height: 22px;
479
477
  color: #fff;
480
478
 
481
- left: 40px; //33px;
479
+ left: 34px;
482
480
  border: 1px solid #fff;
483
-
484
- display: flex;
485
- align-content: center;
486
- justify-content: center;
487
- align-items: center;
488
481
  }
489
482
  .notification-count {
490
- font-size: 10px; //12px;
483
+ font-size: 12px;
491
484
  font-weight: 500;
492
485
  position: relative;
493
- // top: -1px;
486
+ top: -1px;
494
487
  text-align: center;
495
488
  }
496
489
 
@@ -1,4 +1,3 @@
1
- import { ConversationModel } from 'src/chat21-core/models/conversation';
2
1
  import { EventsService } from './../../services/events-service';
3
2
  import { Component, EventEmitter, HostListener, OnInit, Output } from '@angular/core';
4
3
  import { WebsocketService } from 'src/app/services/websocket/websocket.service';
@@ -12,8 +11,6 @@ import { TiledeskAuthService } from 'src/chat21-core/providers/tiledesk/tiledesk
12
11
  import { TiledeskService } from 'src/app/services/tiledesk/tiledesk.service';
13
12
  import { WebSocketJs } from 'src/app/services/websocket/websocket-js';
14
13
  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';
17
14
 
18
15
  @Component({
19
16
  selector: 'app-project-item',
@@ -31,7 +28,6 @@ export class ProjectItemComponent implements OnInit {
31
28
  tiledeskToken: string;
32
29
 
33
30
  unservedRequestCount: number = 0;
34
- unservedConversations: ConversationModel[] = [];
35
31
  currentUserRequestCount: number;
36
32
  ROLE_IS_AGENT: boolean;
37
33
  currentUserId: string;
@@ -58,8 +54,7 @@ export class ProjectItemComponent implements OnInit {
58
54
  public tiledeskService: TiledeskService,
59
55
  public webSocketJs: WebSocketJs,
60
56
  private appConfigProvider: AppConfigProvider,
61
- public events: EventsService,
62
- public convertRequestToConversation: ConvertRequestToConversation
57
+ public events: EventsService
63
58
  ) { }
64
59
 
65
60
  ngOnInit() {
@@ -137,10 +132,9 @@ export class ProjectItemComponent implements OnInit {
137
132
  'LABEL_NOT_AVAILABLE',
138
133
  'LABEL_BUSY',
139
134
  'VIEW_ALL_CONVERSATIONS',
140
- 'UnassignedConversations',
141
- // 'CONVERSATIONS_IN_QUEUE',
142
- // 'CONVERSATION_IN_QUEUE',
143
- // 'NO_CONVERSATION_IN_QUEUE',
135
+ 'CONVERSATIONS_IN_QUEUE',
136
+ 'CONVERSATION_IN_QUEUE',
137
+ 'NO_CONVERSATION_IN_QUEUE',
144
138
  'PINNED_PROJECT',
145
139
  'CHANGE_PINNED_PROJECT',
146
140
  "CHANGE_TO_YOUR_STATUS_TO_AVAILABLE",
@@ -313,16 +307,10 @@ export class ProjectItemComponent implements OnInit {
313
307
  if (r['status'] === 100) {
314
308
  if (this.hasmeInAgents(r['agents']) === true) {
315
309
  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
- }
321
310
  }
322
311
  }
323
312
  });
324
313
  //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)
326
314
  if(count > this.unservedRequestCount ){
327
315
  this.events.publish('unservedRequest:count', count)
328
316
  }
@@ -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 *ngIf="flag_url" [src]="flag_url" style="width: auto;height: 19px; position: relative;top: 1px;">
8
+ <img [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?.avatar" />
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?.avatar" />
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,8 +78,6 @@ export class SidebarUserDetailsComponent implements OnInit, OnChanges {
78
78
  // this.listenOpenUserSidebarEvent();
79
79
  }
80
80
 
81
- ngOnChanges() { }
82
-
83
81
  subcribeToAuthStateChanged() {
84
82
  this.messagingAuthService.BSAuthStateChanged.subscribe((state) => {
85
83
  this.logger.log('[SIDEBAR-USER-DETAILS] BSAuthStateChanged ', state)
@@ -358,6 +356,13 @@ export class SidebarUserDetailsComponent implements OnInit, OnChanges {
358
356
  });
359
357
  }
360
358
 
359
+
360
+ ngOnChanges() { }
361
+
362
+
363
+
364
+
365
+
361
366
  changeAvailabilityStateInUserDetailsSidebar(selectedStatusID) {
362
367
  this.logger.log('[SIDEBAR-USER-DETAILS] - changeAvailabilityState projectid', this.project._id, ' available 1: ', selectedStatusID);
363
368
 
@@ -1,7 +1,2 @@
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
+ <div class="status-icon" [class.online]="online" [style.border-color]="borderColor"></div>
2
+ <div class="online-point" [style.color]="fontColor">{{status}}</div>
@@ -1,41 +1,24 @@
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;
1
+ .status-icon {
2
+ position: absolute;
3
+ width: 14px;
4
+ height: 14px;
5
+ top: 0px;
6
+ left: 0;
7
+ border: 2px solid #ffffff;
12
8
  border-radius: 50%;
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
- }
9
+ background-color: #f44336;
10
+ &.online {
11
+ background-color: #4caf50;
28
12
  }
29
13
 
30
14
  }
31
-
32
15
  .online-point {
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;
16
+ position: absolute;
17
+ display: inline-block;
18
+ top: 0;
19
+ left: 20px;
20
+ color: rgba(255, 255, 255, 0.5);
21
+ font-size: 12px;
22
+ line-height: 14px;
23
+ text-align: left;
41
24
  }
@@ -17,10 +17,11 @@ import { LoggerInstance } from 'src/chat21-core/providers/logger/loggerInstance'
17
17
  })
18
18
 
19
19
  export class UserPresenceComponent implements OnInit, OnDestroy {
20
-
21
20
  @Input() idUser: string;
22
- @Input() isMobile: boolean;
23
21
  @Input() translationMap: Map<string, string>;
22
+ @Input() fontColor: string;
23
+ @Input() borderColor: string;
24
+
24
25
 
25
26
  public online = true;
26
27
  public status = '';
@@ -46,6 +47,9 @@ export class UserPresenceComponent implements OnInit, OnDestroy {
46
47
 
47
48
  /** */
48
49
  initialize() {
50
+ if (this.translationMap) {
51
+ this.status = this.translationMap.get('LABEL_ACTIVE_NOW');
52
+ }
49
53
  this.logger.log('[USER-PRESENCE-COMP] - initialize - this.translationMap', this.translationMap);
50
54
  this.logger.log('[USER-PRESENCE-COMP] - initialize - this.status', this.status);
51
55
  this.logger.log('[USER-PRESENCE-COMP] - initialize - idUser ->', this.idUser);
@@ -118,11 +122,11 @@ export class UserPresenceComponent implements OnInit, OnDestroy {
118
122
  this.logger.log('[USER-PRESENCE-COMP] userIsOnLine - userId: ', userId, ' - isOnline: ', isOnline);
119
123
  this.online = isOnline;
120
124
  if (isOnline) {
121
- this.status = this.translationMap.get('LABEL_ONLINE');
125
+ this.status = this.translationMap.get('LABEL_AVAILABLE');
122
126
  } else {
123
- this.status = this.translationMap.get('LABEL_OFFLINE');
127
+ this.status = this.translationMap.get('LABEL_NOT_AVAILABLE');
124
128
  if (this.lastConnectionDate && this.lastConnectionDate.trim() !== '') {
125
- this.status = this.status + ' (' + this.lastConnectionDate + ')'
129
+ this.status = this.lastConnectionDate;
126
130
  }
127
131
  }
128
132
  }
@@ -137,7 +141,7 @@ export class UserPresenceComponent implements OnInit, OnDestroy {
137
141
  this.logger.log('[USER-PRESENCE-COMP] userLastConnection - lastConnectionDate', lastConnectionDate);
138
142
  this.lastConnectionDate = lastConnectionDate;
139
143
  if (this.online === false) {
140
- this.status = this.translationMap.get('LABEL_OFFLINE') + ' (' + this.lastConnectionDate + ')'
144
+ this.status = this.lastConnectionDate;
141
145
  }
142
146
  }
143
147
  }