From 4c62b7571ee8f4de03425cf0fbdd88ce8ef838ea Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Sat, 23 Jan 2021 12:04:58 +0100 Subject: [PATCH] Indent channels and nicks in buffer list --- components/buffer-list.js | 11 ++++++----- style.css | 3 +++ 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/components/buffer-list.js b/components/buffer-list.js index 987667e..704912d 100644 --- a/components/buffer-list.js +++ b/components/buffer-list.js @@ -29,15 +29,16 @@ function BufferItem(props) { name = getNetworkName(props.network, props.bouncerNetwork, props.bouncer); } - var activeClass = props.active ? "active" : ""; - - var unreadClass = ""; + var classes = ["type-" + props.buffer.type]; + if (props.active) { + classes.push("active"); + } if (props.buffer.unread != Unread.NONE) { - unreadClass = "unread-" + props.buffer.unread; + classes.push("unread-" + props.buffer.unread); } return html` -
  • +
  • ${name}
  • `; diff --git a/style.css b/style.css index 8839a72..d598bc8 100644 --- a/style.css +++ b/style.css @@ -72,6 +72,9 @@ body { #buffer-list li.unread-highlight a { color: #22009b; } +#buffer-list li:not(.type-server) a { + padding-left: 20px; +} #buffer-header, #member-list-header { color: var(--main-color);