+
+
+
+ {{msg.u.name}}
+ {{showDateDuration(msg._updatedAt)}}
+
+
+
{{msg.msg}}
+
+
+
-
-
-
-
-
-
-
- {{file.title}}
-
-
-
-
-
- {{file.description}}
- •
- {{msg.file.type.replace('application/','').toUpperCase()}}
-
+
+
+
+
+
+
+
+
+ {{file.title}}
+
+
+
+
+
+ {{file.description}}
+ •
+ {{msg.file.type.replace('application/','').toUpperCase()}}
+
+
+ {{last ? scrollToBottom() : ''}}
- {{last ? scrollToBottom() : ''}}
diff --git a/src/app/pages/chat/messages/messages.page.scss b/src/app/pages/chat/messages/messages.page.scss
index d7d20cff4..264f55f42 100644
--- a/src/app/pages/chat/messages/messages.page.scss
+++ b/src/app/pages/chat/messages/messages.page.scss
@@ -22,10 +22,18 @@
background: #fff;
.left{
- width: 37px;
+ width: fit-content;
float: left;
- font-size: 35px;
+ //font-size: 35px;
overflow: hidden;
+
+ .header-top-btn{
+ background: transparent;
+ font-size: 25px !important;
+ font-weight: 100 !important;
+ /* color: #0782c9; */
+ color: #42b9fe;
+ }
}
.middle-container{
@@ -36,7 +44,7 @@
padding: 0!important;
float: left;
width:calc(100% - 77px);
- margin: 2.5px 0 0 5px;
+ margin: 0px 0 0 10px;
display: flex;
align-items: center;
}
@@ -44,15 +52,15 @@
.middle-container-options{
padding: 0!important;
- margin: 5px 0 0 5px;
float: left;
- width: calc(100% - 47px);
+ width: calc(100% - 25px);
text-align: right;
/* ion-icon{
font-size: 25px;
} */
.middle-container-options-icons{
+ color: #0782c9;
font-size: 23px;
}
}
@@ -139,6 +147,17 @@
word-wrap: break-word;
-webkit-overflow-scrolling: touch;
+ .messages-list-item-wrapper{
+ overflow: auto;
+ }
+ .messages-list-item-wrapper-active{
+ background: #e6f6ff75 !important;
+ }
+
+ .message-container{
+ //border: 1px solid red;
+ }
+
.incoming-true, .incoming-false{
width: 305px;
diff --git a/src/app/pages/chat/messages/messages.page.ts b/src/app/pages/chat/messages/messages.page.ts
index 3ea67593e..347ac40f5 100644
--- a/src/app/pages/chat/messages/messages.page.ts
+++ b/src/app/pages/chat/messages/messages.page.ts
@@ -54,10 +54,11 @@ export class MessagesPage implements OnInit, AfterViewInit, OnDestroy {
private backgrounds: string[] = ['rgba(0, 0, 255, 0.5)', 'rgba(0, 255, 0.5)', 'rgba(255, 0, 0, 0.5)', 'rgba(255, 255, 0, 0.5)', 'rgba(255, 0, 255, 0.5)', 'rgba(0, 255, 255, 0.5)'];
-private currentColor: string = 'rgba(0, 0, 255, 0.5)';
-private lastOnStart: number = 0;
-private DOUBLE_CLICK_THRESHOLD: number = 500;
-showMessageOptions = false;
+ private currentColor: string = 'rgba(0, 0, 255, 0.5)';
+ private lastOnStart: number = 0;
+ private DOUBLE_CLICK_THRESHOLD: number = 500;
+ showMessageOptions = false;
+ selectedMsgId:string;
constructor(
public popoverController: PopoverController,
@@ -130,7 +131,8 @@ showMessageOptions = false;
gesture.enable();
}
- handlePress(){
+ handlePress(id?:string){
+ this.selectedMsgId = id;
this.showMessageOptions = true;
/* if(!this.showMessageOptions){
this.showMessageOptions = true;
@@ -142,6 +144,7 @@ showMessageOptions = false;
handleClick(){
this.showMessageOptions = false;
+ this.selectedMsgId = "";
}
private onStart() {
@@ -185,7 +188,14 @@ showMessageOptions = false;
"msgId": msgId,
"asUser": false,
}
- this.alertService.confirmDeleteMessage(body);
+ if(msgId){
+ this.alertService.confirmDeleteMessage(body);
+ }
+ else{
+ this.toastService.badRequest('Não foi possível apagar');
+ }
+ this.showMessageOptions = false;
+ this.selectedMsgId = "";
}
setStatus(status:string){