661eedc03a
* only consider short-heights when not smallscreen; hide status bar when small screen, but leave shadow; * fix max char counting bugs with paste, yet be still be able to use modifier keys even when max chars reached * rmeove 'chat' button; move into textarea * use image for emoji picker for sizing consitency * cleanup unused things * - totally unecessary emoji picker style improvements - totally necessary doctype added to emoji picker so it shows up more stable-y on mobile views * more stable layout positioning for chat panel without hacky margins, so that the bottom of the message list will always be on top of the form input, and not behind it at any point. * hide header on touch screens when screns are small and screen height is short (possibly when keyboard is up), so that there's more visibliity to see messages. this only works on chrome, not ios safari right now, due to the position: fixed of things. * move char counting to keyup instead * address message text horiz overflow (#157) * dont jumpToBottom if user has scrolled about 200px from the bottom (#101) * scroll to bottom on resize too * cleanup * revert test bool * typo * re-readjust short-wide case again * - add focus to input field after emoji is selected, put cursor at end - instead of smooth scrolling to bottom, just jump there.
225 lines
3.8 KiB
CSS
225 lines
3.8 KiB
CSS
/*
|
|
Specific styles for main app layout.
|
|
May have overrides for other components with own stylesheets.
|
|
*/
|
|
|
|
/* variables */
|
|
:root {
|
|
--header-height: 3.5em;
|
|
--right-col-width: 24em;
|
|
--video-container-height: calc((9 / 16) * 100vw);
|
|
--header-bg-color: rgba(20,0,40,1);
|
|
--user-image-width: 10em;
|
|
}
|
|
|
|
html {
|
|
font-size: 14px;
|
|
}
|
|
|
|
a:hover {
|
|
text-decoration: underline;
|
|
}
|
|
|
|
.scrollbar-hidden::-webkit-scrollbar {
|
|
width: 0px;
|
|
background: transparent;
|
|
}
|
|
|
|
|
|
#app-container * {
|
|
transition: all .25s;
|
|
}
|
|
|
|
button[disabled] {
|
|
opacity: .5;
|
|
pointer-events: none;
|
|
}
|
|
|
|
.visually-hidden {
|
|
position: absolute !important;
|
|
height: 1px;
|
|
width: 1px;
|
|
overflow: hidden;
|
|
clip: rect(1px 1px 1px 1px); /* IE6, IE7 */
|
|
clip: rect(1px, 1px, 1px, 1px);
|
|
white-space: nowrap; /* added line */
|
|
}
|
|
|
|
|
|
header {
|
|
height: var(--header-height);
|
|
background-color: var(--header-bg-color);
|
|
display: block;
|
|
}
|
|
|
|
#logo-container {
|
|
background-size: 1.35em;
|
|
}
|
|
|
|
#chat-toggle {
|
|
min-width: 3rem;
|
|
}
|
|
|
|
|
|
#user-info-change {
|
|
display: none;
|
|
}
|
|
|
|
|
|
#stream-info span {
|
|
font-size: .70rem;
|
|
}
|
|
|
|
|
|
/* ************************************************ */
|
|
|
|
#video-container {
|
|
height: var(--video-container-height);
|
|
margin-top: var(--header-height);
|
|
position: relative;
|
|
width: 100%;
|
|
|
|
min-height: 480px;
|
|
max-height: calc(100vh - var(--header-height) - 3rem);
|
|
background-size: 30%;
|
|
}
|
|
#video-container #video {
|
|
transition: opacity .5s;
|
|
opacity: 0;
|
|
pointer-events: none;
|
|
}
|
|
.online #video-container #video {
|
|
opacity: 1;
|
|
pointer-events: auto;
|
|
}
|
|
|
|
/* *********** overrides when chat is off ***************************** */
|
|
|
|
|
|
.no-chat footer {
|
|
justify-content: center;
|
|
}
|
|
|
|
.no-chat #chat-toggle {
|
|
opacity: .75;
|
|
}
|
|
|
|
.no-chat #chat-container-wrap {
|
|
display: none;
|
|
}
|
|
|
|
/* *********** overrides when chat is on ***************************** */
|
|
|
|
.chat {
|
|
--content-width: calc(100vw - var(--right-col-width));
|
|
}
|
|
.chat #chat-container-wrap {
|
|
display: block;
|
|
}
|
|
|
|
.chat #video-container,
|
|
.chat #stream-info,
|
|
.chat #user-content {
|
|
width: var(--content-width);
|
|
}
|
|
|
|
.chat #video-container {
|
|
height: calc((9 / 16) * var(--content-width));
|
|
}
|
|
|
|
.short-wide.chat #video-container {
|
|
height: calc(100vh - var(--header-height) - 3rem);
|
|
min-height: auto;
|
|
}
|
|
|
|
.short-wide #message-input {
|
|
height: 3rem;
|
|
}
|
|
|
|
|
|
|
|
|
|
/* *********** single col layout ***************************** */
|
|
|
|
.single-col {
|
|
--right-col-width: 0px;
|
|
--video-container-height: calc((9 / 16) * 100vw);
|
|
}
|
|
.single-col main {
|
|
position: fixed;
|
|
width: 100%;
|
|
z-index: 40;
|
|
}
|
|
.single-col #chat-container {
|
|
position: fixed;
|
|
bottom: 0;
|
|
width: 100%;
|
|
height: auto;
|
|
}
|
|
|
|
.single-col.chat #video-container,
|
|
.single-col.no-chat #video-container,
|
|
.single-col #video-container #video,
|
|
.single-col.chat #video-container #video {
|
|
width: 100vw;
|
|
height: var(--video-container-height);
|
|
min-height: 212px;
|
|
}
|
|
.single-col #user-content,
|
|
.single-col #chat-container-wrap {
|
|
margin-top: calc(var(--video-container-height) + var(--header-height) + 1rem);
|
|
}
|
|
.single-col #user-content .user-content {
|
|
flex-wrap: wrap;
|
|
justify-content: center;
|
|
}
|
|
.single-col.chat #user-content {
|
|
display: none;
|
|
}
|
|
.single-col #messages-container {
|
|
flex-grow: 2;
|
|
margin-top: calc(var(--video-container-height));
|
|
}
|
|
.single-col #message-input-container {
|
|
width: 100%;
|
|
}
|
|
|
|
.single-col #stream-info {
|
|
height: 0;
|
|
padding: 0;
|
|
}
|
|
.single-col #stream-info span {
|
|
display: none;
|
|
}
|
|
|
|
.single-col #message-input-wrap {
|
|
max-height: 3em;
|
|
}
|
|
|
|
@media screen and (max-height: 500px) {
|
|
.single-col.touch-screen {
|
|
--header-height: 0px;
|
|
}
|
|
.single-col.touch-screen header {
|
|
display: none;
|
|
}
|
|
}
|
|
|
|
|
|
/* ************************************************8 */
|
|
|
|
|
|
@media screen and (max-width: 860px) {
|
|
:root {
|
|
--right-col-width: 20em;
|
|
--user-image-width: 6em;
|
|
}
|
|
#video-container {
|
|
min-height: 240px;
|
|
}
|
|
.instance-title {
|
|
font-size: 1rem;
|
|
}
|
|
|
|
}
|