view src/chat.css @ 60:3521166513b3

finish invite
author Franklin Schmidt <fschmidt@gmail.com>
date Tue, 04 Mar 2025 20:31:00 -0700
parents 323ddacc1593
children afd5ab5b02a2
line wrap: on
line source

body {
	position: fixed;
	top: 0;
	bottom: 0;
	left: 0;
	right: 0;
}

div[chat_content] {
	display: flex;
	height: calc(100% - 32px);
}

div[chats] > div {
	margin-top: 2px;
	margin-bottom: 2px;
	padding-top: 16px;
	padding-bottom: 16px;
	padding-left: 8px;
	padding-right: 8px;
	border-radius: 4px;
	cursor: pointer;
}

div[chats] > div:hover,
div[chats] > div[selected] {
	background-color: LightBlue;
}

div[posts] {
	width: 100%;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

div[chat_content][show="intro"] div[posts] {
	display: none;
}

div[posts] > * {
	padding-right: 3vw;
}

div[top] {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

div[top] h3 a {
	display: inline-block;
	margin-bottom: -5px;
}
div[top] h3 a img {
	display: block;
}

div[main] {
	overflow-y: auto;
}

div[post] {
	margin-top: 16px;
	margin-bottom: 16px;
}

div[intro] {
	width: 100%;
	display: flex;
	flex-direction: column;
	align-items: center;
}

div[intro] form {
	max-width: 100%;
}
div[intro] input[type=email] {
	width: 250px;
	max-width: 100%;
}

div[who] {
	display: flex;
	justify-content: space-between;
	font-size: 12px;
	color: grey;
}

span[pulldown] {
	position: relative;
	width: 16px;
	display: inline-block;
	vertical-align: middle;
}

span[pulldown] > div {
	display: none;
	top: 0;
	right: 100%;
	z-index: 2;
	position: absolute;
	border: 1px solid #cccccc;
	border-radius: 4px;
	text-align: left;
	background-color: #eeeeee;
	padding: 5px 0;
}

span[pulldown] > div > span {
	white-space: nowrap;
	display: block;
	padding: 3px 16px;
	xcolor: #333333;
	cursor: pointer;
}

span[pulldown] > div > span:hover {
	color: #ffffff;
	background-color: #428bca;
}

div[text] {
	white-space: pre-wrap;
}

div[input] {
	padding-top: 1em;
	padding-bottom: 1em;
	display: flex;
	gap: 8px;
	align-items: flex-end;
}

div[input] textarea {
	flex-grow: 1;
	max-height: 150px;
	resize: none;
}

dialog textarea {
	width: 600px;
	max-width: 80vw;
}

span[online] {
	display: inline-block;
	aspect-ratio: 1;
	background-color: grey;
	height: 0.6em;
	border-radius: 50%;
	margin-left: 4px;
}

span[unread] {
	font-size: small;
	display: inline-block;
	background-color: DodgerBlue;
	color: white;
	padding: 2px;
	border-radius: calc(1em + 4px);
	min-width: calc(1em + 4px);
	text-align: center;
	line-height: 1;
}
span[unread="0"] {
	display: none;
}

@media (min-width: 700px) {
	div[chat_content] {
		margin-left: calc(3% - 8px);
		margin-right: 0;
	}

	div[chat_content][show="chats"] div[intro],
	div[chat_content][show="posts"] div[intro] {
		display: none;
	}

	div[chats] {
		overflow-y: auto;
		width: 250px;
		padding-right: 8px;
		flex-shrink: 0;
	}

	div[intro],
	div[posts] {
		padding-left: 8px;
		border-left: 1px solid grey;
	}

	div[top] img[back] {
		display: none;
	}
}

@media (max-width: 699px) {
	div[chat_content][show="intro"],
	div[chat_content][show="chats"] {
		flex-direction: column;
		overflow-y: auto;
	}
	div[chat_content][show="posts"] {
		margin-left: 3%;
	}

	div[chat_content][show="chats"] div[posts],
	div[chat_content][show="posts"] div[intro],
	div[chat_content][show="posts"] div[chats] {
		display: none;
	}

	div[chats],
	div[intro] {
		padding-left: 3%;
		padding-right: 3%;
	}

	div[chats] {
		width: 100%;
	}

	div[intro] {
		margin-top: 20px;
		border-top: 1px solid grey;
	}

	div[intro] [or] {
		display: none;
	}

	div[chat_content][show="posts"] {
		margin-right: 0;
	}

	div[top] h3 {
		display: flex;
		gap: 6px;
	}
}