-
-
Notifications
You must be signed in to change notification settings - Fork 130
/
chat-box.component.scss
134 lines (121 loc) · 2.82 KB
/
chat-box.component.scss
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
//@import "animation-helper";
//.flex-vert-center {
// display: flex;
// align-items: center;
//}
/* CHAT BUTTON
-------------------------------------------------- */
.chat-button {
position: fixed !important;
bottom: 25px;
right: 25px;
z-index: 5;
}
/* CHAT BOX
-------------------------------------------------- */
.chat-box {
background: #efefef;
position: fixed;
bottom: 50px;
right: 30px;
width: 351px;
height: 60vh;
min-width: 350px;
min-height: 400px;
max-width: 85vw;
max-height: 85vh;
border-radius: 5px;
z-index: 10;
box-shadow: 0px 5px 35px 9px #ccc;
/* Medium devices (tablets, 768px and up)*/
@media (min-width: 768px) {
min-height: 30vh;
height: 40vh;
}
/* Large devices (desktops, 992px and up)*/
@media (min-width: 992px) {
height: 60vh;
}
/* Chat Drawer */
//mat-drawer {
// width: 280px;
//}
/* Chat Header */
.header {
min-height: 72px !important;
border-top-left-radius: 5px;
border-top-right-radius: 5px;
}
/* Chat Messages */
.body {
padding: 15px;
overflow-y: scroll;
@media only screen and (max-width: 500px) {
height: 40vh;
}
/* Chat Messages */
.message {
padding: 8px 16px;
font-weight: 400;
text-transform: none;
text-align: center;
font-size: 16px;
letter-spacing: 0.5px;
margin: 0 0 2px 0;
max-width: 65%;
float: none;
clear: both;
line-height: 1.5em;
transition: all 200ms;
box-sizing: content-box;
&.to {
color: #212121;
background: rgba(255, 255, 255, 0.84);
border-radius: 5px 15px 15px 15px;
text-align: left;
word-break: break-all;
transform-origin: left top;
}
&.from {
color: #fff;
background: rgba(44, 44, 44, 0.67);
box-shadow: none;
float: right;
position: relative;
transform-origin: right top;
margin: 8px 0 10px 2px;
border-radius: 15px 15px 5px 15px;
text-align: center;
display: inline-block;
text-decoration: none;
word-break: normal;
/* animation-duration: 1s; */
animation-name: animate-reply;
animation-play-state: paused;
animation-fill-mode: forwards;
/* opacity: 0; */
transform: translate3d(0px, 0px, 0px);
animation-delay: -3s;
-webkit-animation-delay: -3s;
}
&.to + &.to,
&.from + &.from {
margin-top: -10px;
}
}
}
}
/* Chat Content */
.card-content {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
/* Custom mat-form-field-outline */
:host /deep/ mat-form-field.mat-form-field-appearance-outline.custom-outline .mat-form-field-wrapper {
padding-bottom: 0;
margin: 0;
//.mat-form-field-outline {
// display: none;
//}
}