mirror of
https://github.com/spacebarchat/client.git
synced 2024-11-22 10:22:30 +01:00
add chevrons to member list sections
This commit is contained in:
parent
887b8940f9
commit
ca1f5cb9d9
@ -1,5 +1,6 @@
|
||||
import React from "react";
|
||||
import styled from "styled-components";
|
||||
import Icon from "./Icon";
|
||||
|
||||
const Container = styled.div`
|
||||
padding: 24px 8px 0 16px;
|
||||
@ -11,6 +12,9 @@ const Title = styled.span`
|
||||
color: var(--text-secondary);
|
||||
user-select: none;
|
||||
cursor: pointer;
|
||||
|
||||
display: flex;
|
||||
align-items: center;
|
||||
`;
|
||||
|
||||
const Wrapper = styled.div<{ open?: boolean }>`
|
||||
@ -40,7 +44,10 @@ function ListSection(props: Props) {
|
||||
|
||||
return (
|
||||
<Container>
|
||||
<Title onClick={toggle}>{props.name}</Title>
|
||||
<Title onClick={toggle}>
|
||||
<Icon icon={open ? "mdiChevronRight" : "mdiChevronDown"} size={"16px"} />
|
||||
{props.name}
|
||||
</Title>
|
||||
<Wrapper open={open}>
|
||||
{props.items.map((item) => (
|
||||
<Item>{item}</Item>
|
||||
|
Loading…
Reference in New Issue
Block a user