/* * Spreed WebRTC. * Copyright (C) 2013-2014 struktur AG * * This file is part of Spreed WebRTC. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License * along with this program. If not, see . * */ #chat { pointer-events: none; position: absolute; bottom: 0px; right: $chat-width; top: 0px; width: $chat-width; min-width: $chat-width; z-index: 45; display: none; } .withChat { #chat { display: block; } &.withChatMaximized #chat { left: 0; width: auto; } } .chatcontainer { background: $chat-background; bottom: 0px; left: 0px; right: 0px; top: 0px; overflow: hidden; position: absolute; } .showchatlist { .chatpane { right: 100%; } .chatlist { left: 0; } } .chatlist { background: $chat-background; bottom: 0; left: 100%; position: absolute; top: 0; width: 100%; .list-group { margin-top: -1px; margin-bottom: -1px; max-height: 100%; overflow-x: hidden; overflow-y: auto; } .list-group-item { border-right: none; border-left: none; border-radius: 0; padding-right: 70px; position: relative; min-height: 51px; line-height: 26px; &.newmessage { animation: newmessage 1s ease -0.3s infinite; } &.disabled { color: $chat-disabled; } &:hover button { display: inline; } .fa-lg { display: inline-block; text-align: center; width: 18px; } .badge { background: $chat-badge; border: 1px solid white; position: absolute; right: 50px; top: 14px; } button { display: none; position: absolute; right: 10px; } } } .chatpane { backface-visibility: hidden; bottom: 0; position: absolute; right: 0; top: 0; width: 100%; } .chat { background: $chat-background; display: none; bottom: 0; left: 0; overflow: hidden; pointer-events: auto; position: absolute; right: 0; top: 0; } .chat { &.active { &.visible { display: block; } .chatbody { // nothing } .chatheader { // nothing } } } .chatmenu { position: absolute; top: 36px; left: 0px; right: 0px; height: 36px; padding: 2px 4px; @include breakpt($breakpoint-chat-small, max-height) { display: none; } } .chatbody { border-left: 1px solid $bordercolor; bottom: -1px; left: 0; position: absolute; right: 0; top: 74px; @include breakpt($breakpoint-chat-small, max-height) { border-top: 1px solid $bordercolor; top: 0px; } } .chatheader { background: $chat-header; border-bottom: 1px solid $bordercolor; border-left: 1px solid $bordercolor; height: 36px; left: 0; line-height: 34px; padding: 0 4px 0 8px; position: absolute; right: 0; top: 0; .chatstatusicon { cursor: pointer; display: block; font-size: 1.4em; height: 36px; left: 0; position: absolute; text-align: center; top: 0; width: 36px; } .chatheadertitle { display: inline; padding-left: 28px; } .ctrl { color: $chat-ctrl; position: absolute; right: 1px; top: 0; .#{$fa-css-prefix} { cursor: pointer; padding: 6px; } } span { display: inline-block; max-width: 60%; overflow: hidden; pointer-events: none; text-overflow: ellipsis; vertical-align: middle; white-space: nowrap; } @include breakpt($breakpoint-chat-small, max-height) { display: none; } } .chat .outputbox { bottom: 75px; left: 0; position: absolute; right: 0; top: 0; @include breakpt($breakpoint-chat-small, max-height) { bottom: 45px; } } .chat .output { height: 100%; overflow-x: hidden; overflow-y: auto; padding: 0.4em 0; > i { clear: both; color: $chat-meta; display: block; font-size: .8em; padding: 6px 0; text-align: center; &.p2p { font-weight: bold; padding: 6px 0; } } } .chat.with_pictures .message { &.is_self { padding-right: 54px; .timestamp { right: 58px; } } &.is_remote { padding-left: 58px; } } .chat .message { background: $chat-msg-background; border: 1px solid $chat-msg-border; border-radius: 6px; clear: both; display: block; margin: 0 4px 2px 20px; padding: 8px; position: relative; word-wrap: break-word; ul { list-style-type: none; margin: 0; padding-left: 0; } li { line-height: 1.1em; margin: 4px 0; padding-left: 1.2em; position: relative; &:before { color: $chat-msg-default-icon-color; content: '\f075'; font-family: FontAwesome; left: 0; position: absolute; text-align: center; width: 12px; } } .timestamp { color: $chat-timestamp; font-size: .8em; position: absolute; right: 8px; text-align: right; top: 8px; } .timestamp-space { width:40px; height:10px; float:right; } strong { display: block; padding-bottom: 2px; margin-right: 40px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } } .chat .message { &.is_self li:before { color: $chat-msg-default-icon-color; transform: scale(-1, 1); } li { &.unread:before { content: $chat-msg-unread-icon; color: $chat-msg-unread-icon-color; } &.sending:before { content: $chat-msg-sending-icon; color: $chat-msg-sending-icon-color; } &.sent:before { content: $chat-msg-sent-icon; color: $chat-msg-sent-icon-color; } &.delivered:before { content: $chat-msg-delivered-icon; color: $chat-msg-delivered-icon-color; } &.received:before { content: $chat-msg-received-icon; color: $chat-msg-received-icon-color; } &.read:before { content: $chat-msg-read-icon; color: $chat-msg-read-icon-color; } } } .chat .message { &.is_self .buddyPicture { left: auto; right: 4px; } .buddyPicture { background: $actioncolor1; border-radius: 2px; height: 46px; left: 4px; overflow: hidden; position: absolute; text-align: center; top: 4px; width: 46px; .#{$fa-css-prefix} { color: $actioncolor2; line-height: 46px; } img { display: block; bottom: 0; left: 0; right: 0; position: absolute; top: 0; } } } .chat .message { &:before, &:after { border-style: solid; content: ""; display: block; position: absolute; width: 0; } &.is_remote { background: $chat-msg-remote-background; &:before { // arrow border border-width: 10px 17px 10px 0; border-color: transparent $chat-msg-remote-background; bottom: auto; left: -16px; top: 4px; } &:after { // arrow background border-width: 9px 15px 9px 0; border-color: transparent $chat-msg-remote-background; bottom:auto; left: -15px; top: 5px; } } &.is_self { background: $chat-msg-self-background; margin-right:20px; margin-left: 4px; padding-right: 0; &:before { // arrow border border-width: 10px 0 10px 17px; border-color: transparent $chat-msg-self-background; bottom: auto; right: -16px; top: 4px; } &:after { // arrow background border-width: 9px 0 9px 15px; border-color: transparent $chat-msg-self-background; bottom: auto; right: -15px; top: 5px; } } &.with_name { // none } } .chat { .chatbodybottom { background: $chat-bottom-background; bottom: 1px; left: 0; margin: 0 auto; position: absolute; right: 0; @include breakpt($breakpoint-chat-small, max-height) { height: auto; } } .typinghint { padding: 0 6px 0 6px; white-space: nowrap; overflow: hidden; font-size:.8em; color: $chat-typing; height: 14px; @include breakpt($breakpoint-chat-small, max-height) { display: none; } } .inputbox { position: relative; .btn { position: absolute; right: 6px; top: 1px; padding: .5em 1em; display: none; } > div { border-top: 1px solid $bordercolor; } @include breakpt($breakpoint-chat-small, max-height) { height: auto; } } .input { border-radius: 0; border-color: transparent; box-shadow: none; display: block; height: 54px; max-height: 54px; /* FF hack */ margin: 0; resize: none; width: 100%; &:active, &:focus { border-color: $chat-input-border-color; } @include breakpt($breakpoint-chat-small, max-height) { max-height: 2.5em; } } } @keyframes newmessage { 0% {background-color: $actioncolor1;} 50% {background-color: $componentbg;} 100% {background-color: $actioncolor1;} } .chat.newmessage { .chatheadertitle:after { content: "***"; position: absolute; right: 32px; top: 2px; } .chatheader { animation: newmessage 1s ease -0.3s infinite; } }