ui: tweaks

This commit is contained in:
cha0s 2020-07-18 20:05:18 -05:00
parent 8db939655f
commit 6f423a2723
3 changed files with 16 additions and 9 deletions

View File

@ -27,7 +27,15 @@ export default function Channel(props) {
) )
} }
<span className="muted">{prefix}</span> <span className="muted">{prefix}</span>
<span className="channel__name">{name}</span> <span
className={classnames(
'channel__name',
{long: name && name.length >= 12},
{superlong: name && name.length >= 16},
)}
>
{name}
</span>
</> </>
); );
return ( return (
@ -38,11 +46,7 @@ export default function Channel(props) {
href href
? ( ? (
<Link <Link
className={classnames( className="channel__link"
'channel__link',
{long: name && name.length >= 12},
{superlong: name && name.length >= 16},
)}
to={href} to={href}
> >
{content} {content}

View File

@ -28,13 +28,16 @@
padding: 0.4em; padding: 0.4em;
text-align: center; text-align: center;
} }
}
.channel__name {
&.long { &.long {
font-size: 0.8em; font-size: 0.8em;
padding: 1.4em; padding-top: 0.2em;
} }
&.superlong { &.superlong {
font-size: 0.6em; font-size: 0.6em;
padding: 2em; padding-top: 0.4em;
} }
} }

View File

@ -1,6 +1,6 @@
.chat--messages { .chat--messages {
background-image: url('./dark.png'); background-image: url('./dark.png');
box-shadow: 0 0 10px #171717 inset; box-shadow: 0 0 5px #171717 inset;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
overflow: hidden; overflow: hidden;