blob: ce14d19d1b5d476b38fab5b82e7cacfd501c54f7 [file] [log] [blame]
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -05001body {
Adrien Beraud8e25afb2017-04-19 01:38:57 +02002 margin: 0;
AmarOkb4253242017-07-13 11:21:39 -04003 overflow: hidden;
Adrien Beraud8e25afb2017-04-19 01:38:57 +02004}
5
6#container {
7 position: relative;
8 height: 100%;
9 width: 100%;
AmarOkb4253242017-07-13 11:21:39 -040010 display: flex;
11 flex-direction: column;
12 margin: 0;
13 padding: 0;
AmarOkd55d85e2017-07-14 09:44:05 -040014 justify-content: flex-end;
Adrien Beraud8e25afb2017-04-19 01:38:57 +020015}
16
17#messages {
AmarOkb4253242017-07-13 11:21:39 -040018 position: relative;
AmarOkb4253242017-07-13 11:21:39 -040019 z-index: 0;
Adrien Beraud8e25afb2017-04-19 01:38:57 +020020 width: 100%;
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -050021 overflow-y: scroll;
AmarOkb4253242017-07-13 11:21:39 -040022 height: auto;
AmarOkd55d85e2017-07-14 09:44:05 -040023 max-height: calc(100% - 50px);
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -050024}
25
AmarOkb4253242017-07-13 11:21:39 -040026#sendMessage {
27 display: flex;
28 width: 97%;
29 position: relative;
AmarOkb4253242017-07-13 11:21:39 -040030 transform: translateZ(0);
AmarOkd55d85e2017-07-14 09:44:05 -040031 height: 50px;
AmarOkb4253242017-07-13 11:21:39 -040032 border-top : 2px solid #d3d3d3;
33 padding-right: 10px;
34 margin-left: 1%;
35 margin-right: 1.5%;
36}
37
38#message {
39 width: 100%;
40 border: 0;
41 height: 55px;
42 overflow: hidden;
43 padding-right: 20px;
44 color: black;
45 padding-left: 8px;
AmarOkd55d85e2017-07-14 09:44:05 -040046 flex: 1;
AmarOkb4253242017-07-13 11:21:39 -040047}
48
49#message:focus,
50#message.focus {
51 border: 0;
52 outline: none;
53}
54
55input[placeholder], [placeholder], *[placeholder] {
56 color: #d3d3d3;
57}
58
59#sendBtn {
60 border-radius: 50%;
61 border: 0;
62 width: 40px;
63 height: 40px;
64 margin-top: 8px;
65 transition: all 0.3s ease;
66}
67
68#sendBtn.hover,
69#sendBtn:hover {
70 background: #bae5f0;
71}
72
73#sendBtn.hover svg,
74#sendBtn:hover svg {
75 fill: black;
76}
77
78#sendMessage svg {
79 fill: #666;
80 padding: 5px;
81 width: 100%;
82 height: 100%;
83 transition: all 0.3s ease;
84}
85
86
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -050087.wc {
88 will-change: transform;
89}
90
aviau32b8dd62016-11-02 00:36:57 -040091.status_circle {
92 fill: #A0A0A0;
93 -webkit-animation: circle-dance;
94 -webkit-animation-duration: 0.8s;
95 -webkit-animation-iteration-count: infinite;
96 -webkit-animation-direction: alternate;
97 -webkit-animation-timing-function: ease-in-out;
98}
99
100.anim-first {
101 -webkit-animation-delay: 0.7s;
102}
103
104.anim-second {
105 -webkit-animation-delay: 0.9s;
106}
107
108.anim-third {
109 -webkit-animation-delay: 1.1s;
110}
111
112@-webkit-keyframes circle-dance {
113 0%,50% {
114 -webkit-transform: translateY(0);
115 fill: #A0A0A0;
116 }
117 100% {
118 -webkit-transform: translateY(-8px);
119 fill: #000;
120 }
121}
122
123.status-check {
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -0500124 stroke-dasharray: 17;
125 stroke-dashoffset: 17;
126 -webkit-animation: dash-check;
127 -webkit-animation-duration: 0.4s;
128 -webkit-animation-delay: 0.7s;
129 -webkit-animation-fill-mode: forwards;
130 -webkit-animation-timing-function: ease-in-out;
131 display: none;
132}
133
134.message--sent .status-check {
135 display: inline-block;
aviau32b8dd62016-11-02 00:36:57 -0400136}
137
138@-webkit-keyframes dash-check{
139 from {
140 stroke-dashoffset: 17;
141 }
142 to {
143 stroke-dashoffset: 0;
144 }
145}
146
147.status-x {
148 stroke-dasharray: 12;
149 stroke-dashoffset: 12;
150 -webkit-animation: dash-x;
151 -webkit-animation-duration: 0.2s;
152 -webkit-animation-fill-mode: forwards;
153 -webkit-animation-timing-function: ease-in-out;
154}
155
156.x-first {
157 -webkit-animation-delay: 0.7s;
158}
159
160.x-second {
161 -webkit-animation-delay: 0.9s;
162}
163
164@-webkit-keyframes dash-x{
165 from {
166 stroke-dashoffset: 12;
167 }
168 to {
169 stroke-dashoffset: 0;
170 }
171}
172
173.message_wrapper {
174 transform: scale(0);
175 max-width: 50%;
176 margin: 10px 0;
177 display: inline-block;
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -0500178 padding: 10px;
aviau32b8dd62016-11-02 00:36:57 -0400179 border-radius: 10px;
180 position: relative;
181 -webkit-animation: talk;
182 -webkit-animation-duration: 0.3s;
183 -webkit-animation-delay: 0.1s;
184 -webkit-animation-fill-mode: forwards;
185 -webkit-animation-timing-function: ease-in-out;
186}
187
188.message {
189 font: 0.875em "Open sans",Helvetica,"Segoe UI",sans-serif;
190 margin: 0;
191 display: flex;
192 justify-content: flex-start;
193 align-items: top;
194 overflow: hidden;
195}
196
197.message_out {
198 flex-direction: row-reverse;
199}
200
201.message_sender {
202 display: none;
203}
204
205.sender_image {
206 border-radius: 50%;
207 transition: transform 0.2s ease-in-out;
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -0500208 margin: 10px;
aviau32b8dd62016-11-02 00:36:57 -0400209}
210
211.message_in .sender_image {
212 -webkit-animation-name: enter-stage-left;
213 -webkit-animation-duration: 0.2s;
214 -webkit-animation-timing-function: ease-in-out;
215}
216
217.message_out .sender_image {
218 -webkit-animation-name: enter-stage-right;
219 -webkit-animation-duration: 0.2s;
220 -webkit-animation-timing-function: ease-in-out;
221}
222
223@-webkit-keyframes enter-stage-left {
224 from {
225 transform: translateX(-100%);
226 }
227 to {
228 transform: translateX(0);
229 }
230}
231
232@-webkit-keyframes enter-stage-right {
233 from {
234 transform: translateX(100%);
235 }
236 to {
237 transform: translateX(0);
238 }
239}
240
241.message_out > .message_wrapper {
AmarOkb4253242017-07-13 11:21:39 -0400242 background-color: #cfebf5;
aviau32b8dd62016-11-02 00:36:57 -0400243 border-top-right-radius: 0;
244 transform-origin: top right;
245}
246
247.message_out + .message_out > .message_wrapper {
248 border-top-right-radius: 10px;
249}
250
251.message_in > .message_wrapper {
252 background-color: #DEDEE0;
253 border-top-left-radius: 0;
254 transform-origin: top left;
255}
256
257.message_in + .message_in > .message_wrapper {
258 border-top-left-radius: 10px;
259}
260
261.message_timestamp {
262 font-size: 0.8em;
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -0500263 margin-top: 0.5em;
aviau32b8dd62016-11-02 00:36:57 -0400264 opacity: 1;
265 transition: opacity 0.5s ease-in-out;
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -0500266 line-height: 1em;
267 display: inline-block;
268}
269
270.sent-checkmark {
271 margin-left: 0.313em;
aviau32b8dd62016-11-02 00:36:57 -0400272}
273
274.message_in .message_timestamp {
275 color: #9E9E9E;
276}
277
278@-webkit-keyframes fade-in {
279 from {
280 opacity: 0;
281 }
282 to {
283 opacity: 1;
284 }
285}
286
287.message_text {
288 word-wrap: break-word;
Frédéric Guimont3e5f1b62016-11-22 11:41:38 -0500289 display: block;
aviau32b8dd62016-11-02 00:36:57 -0400290}
291
292@-webkit-keyframes talk {
293 from {
294 transform: scale(0);
295 }
296 to {
297 transform: scale(1);
298 }
299}
300
301.message_in > .message_wrapper:before {
302 content: "";
303 width: 10px;
304 height: 10px;
305 position: absolute;
306 left: -10px;
307 top: 0;
308 background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E %3Cpath d= 'M10,0 L0,0 C10,0 10,10 10,10' fill='%23DEDEE0'/%3E %3C/svg%3E");
309 transform-origin: top left;
310}
311
312.message_in + .message_in > .message_wrapper:before {
313 display: none;
314}
315
316.message_out + .message_out > .message_wrapper:after {
317 display: none;
318}
319
320.message_out > .message_wrapper:after {
321 content: "";
322 width: 10px;
323 height: 10px;
324 position: absolute;
325 right: -10px;
326 top: 0;
AmarOkb4253242017-07-13 11:21:39 -0400327 background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E %3Cpath d= 'M0,0 L10,0 C0,0 0,10 0,10' fill='%23cfebf5'/%3E %3C/svg%3E");
aviau32b8dd62016-11-02 00:36:57 -0400328 transform-origin: top right;
329}
330
331.message_delivery_status {
332 margin: 10px 10px;
333 color: #A0A0A0;
334 opacity: 0;
335 -webkit-animation-name: fade-in;
336 -webkit-animation-duration: 0.2s;
337 -webkit-animation-timing-function: ease-in-out;
338 -webkit-animation-delay: 0.4s;
339 -webkit-animation-fill-mode: forwards;
340 transition: opacity 0.5s ease-in-out;
341}
342
343.message_in + .message_in .sender_image {
344 opacity: 0;
345}
346
347.message_out + .message_out .sender_image {
348 opacity: 0;
349}