react-icons/md#MdPeople JavaScript Examples
The following examples show how to use
react-icons/md#MdPeople.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: MenuItems.js From MeowForm with MIT License | 6 votes |
function MenuItems({onClose}) {
return (
<div>
<Box>
<MenuButtons link="/dashboard" icon={<MdRemoveFromQueue/>} Tittle="dashboard" click={onClose}></MenuButtons>
<a href="https://docs.meowform.xyz/docs/intro" target="_blank">
<Button ml="1%" mt="5%" width="100%" onClick={onClose}>
<MdFindInPage/>
<Text fontSize="xl" ml="4">
Docs
</Text>
</Button>
</a>
<a href="https://github.com/tewarig/meowForm" target="_blank">
<Button ml="1%" mt="5%" width="100%" onClick={onClose}>
<MdStar/>
<Text fontSize="xl" ml="4">
Star on github
</Text>
</Button>
</a>
<a href="https://github.com/tewarig/meowForm" target="_blank">
<Button ml="1%" mt="5%" width="100%" onClick={onClose}>
<MdPeople/>
<Text fontSize="xl" ml="4">
Support MeowForm
</Text>
</Button>
</a>
</Box>
</div>
);
}
Example #2
Source File: MailboxList.js From CubeMail with MIT License | 4 votes |
MailboxList = () => {
const { getMessages, setCurrentLabel } = useContext(EmailContext);
const [active, setActive] = useState("INBOX");
const handleClick = (e) => {
const categoryId = e.target.id;
setActive(categoryId);
setCurrentLabel(categoryId);
// Get Messages using clicked category
getMessages(categoryId);
};
return (
<Box
w='16%'
h='100%'
bg='white'
border='1px'
borderColor='gray.200'
borderTopLeftRadius='md'
borderBottomLeftRadius='md'
>
<List>
{/* Send Model */}
<ListItem p='0.5rem 1rem 1rem'>
<SendModel />
</ListItem>
{/* Labels Buttons */}
<ListItem>
<Button
id='INBOX'
w='100%'
h='45px'
py={2}
pl={8}
leftIcon={MdInbox}
variantColor='blue'
variant={active === "INBOX" ? "solid" : "ghost"}
justifyContent='flex-start'
onClick={handleClick}
>
Inbox
</Button>
</ListItem>
<ListItem>
<Button
id='STARRED'
w='100%'
h='45px'
py={2}
pl={8}
leftIcon={MdStar}
variantColor='blue'
variant={active === "STARRED" ? "solid" : "ghost"}
justifyContent='flex-start'
onClick={handleClick}
>
Starred
</Button>
</ListItem>
<ListItem>
<Button
id='IMPORTANT'
w='100%'
h='45px'
py={2}
pl={8}
leftIcon={MdLabel}
variantColor='blue'
variant={active === "IMPORTANT" ? "solid" : "ghost"}
justifyContent='flex-start'
onClick={handleClick}
>
Important
</Button>
</ListItem>
<ListItem>
<Button
id='SENT'
w='100%'
h='45px'
py={2}
pl={8}
leftIcon={FiSend}
variantColor='blue'
variant={active === "SENT" ? "solid" : "ghost"}
justifyContent='flex-start'
onClick={handleClick}
>
Sent
</Button>
</ListItem>
<ListItem>
<Button
id='DRAFT'
w='100%'
h='45px'
py={2}
pl={8}
leftIcon={FiFile}
variantColor='blue'
variant={active === "DRAFT" ? "solid" : "ghost"}
justifyContent='flex-start'
onClick={handleClick}
>
Drafts
</Button>
</ListItem>
<ListItem>
<Button
id='TRASH'
w='100%'
h='45px'
py={2}
pl={8}
leftIcon='delete'
variantColor='blue'
variant={active === "TRASH" ? "solid" : "ghost"}
justifyContent='flxex-start'
onClick={handleClick}
>
Trash
</Button>
</ListItem>
<ListItem>
<Button
id='CATEGORY_SOCIAL'
w='100%'
h='45px'
py={2}
pl={8}
leftIcon={MdPeople}
variantColor='blue'
variant={active === "CATEGORY_SOCIAL" ? "solid" : "ghost"}
justifyContent='flxex-start'
onClick={handleClick}
>
Social
</Button>
</ListItem>
<ListItem>
<Button
id='CATEGORY_PROMOTIONS'
w='100%'
h='45px'
py={2}
pl={8}
leftIcon={MdLoyalty}
variantColor='blue'
variant={active === "CATEGORY_PROMOTIONS" ? "solid" : "ghost"}
justifyContent='flxex-start'
onClick={handleClick}
>
Promotions
</Button>
</ListItem>
</List>
</Box>
);
}
Example #3
Source File: index.js From hackchat-client with Do What The F*ck You Want To Public License | 4 votes |
export function MainMenu({
mainMenuIsOpen,
usersMenuIsOpen,
ChannelsModalIsOpen,
joinMenuIsOpen,
localeMenuIsOpen,
onOpenMainMenu,
onCloseMainMenu,
onOpenUsersModal,
onCloseUsersModal,
onOpenChannelsModal,
onCloseChannelsModal,
onOpenJoinMenu,
onCloseJoinMenu,
onOpenLocaleMenu,
onCloseLocaleMenu,
history,
intl,
}) {
useInjectReducer({ key: 'mainMenu', reducer });
const usersBtnToolTip = intl.formatMessage(messages.usersBtnToolTip);
const channelsBtnToolTip = intl.formatMessage(messages.channelsBtnToolTip);
const joinBtnToolTip = intl.formatMessage(messages.joinBtnToolTip);
const languageBtnToolTip = intl.formatMessage(messages.languageBtnToolTip);
const mainIcon = mainMenuIsOpen ? <MdClose /> : <MdMenu />;
const menuBtnText = intl.formatMessage(messages.menuBtnToolTip);
const settingsBtnText = intl.formatMessage(messages.settingsBtnToolTip);
return (
<div>
<Collapse className="fixed-bottom" isOpen={mainMenuIsOpen}>
<Container fluid>
<Row className="mx-auto">
<Col>
<MenuButton
onClick={() => {
if (ChannelsModalIsOpen) {
onCloseUsersModal();
} else {
onOpenUsersModal();
}
}}
toolTip={usersBtnToolTip}
>
<MdPeople />
</MenuButton>
<UsersModal open={usersMenuIsOpen} />
</Col>
</Row>
<Row className="mx-auto">
<Col>
<MenuButton
onClick={() => {
if (ChannelsModalIsOpen) {
onCloseChannelsModal();
} else {
onOpenChannelsModal();
}
}}
toolTip={channelsBtnToolTip}
>
<MdForum />
</MenuButton>
<ChannelsModal open={ChannelsModalIsOpen} />
</Col>
</Row>
<Row className="mx-auto">
<Col>
<MenuButton
onClick={() => {
if (joinMenuIsOpen) {
onCloseJoinMenu();
} else {
onOpenJoinMenu();
}
}}
toolTip={joinBtnToolTip}
>
<FaPlus />
</MenuButton>
<JoinModal open={joinMenuIsOpen} />
</Col>
</Row>
<Row className="mx-auto">
<Col>
<MenuButton
onClick={() => {
if (localeMenuIsOpen) {
onCloseLocaleMenu();
} else {
onOpenLocaleMenu();
}
}}
toolTip={languageBtnToolTip}
>
<MdLanguage />
</MenuButton>
<LocaleModal open={localeMenuIsOpen} />
</Col>
</Row>
<Row className="mx-auto">
<Col>
<MenuButton
onClick={() => {
history.push('/settings');
}}
toolTip={settingsBtnText}
>
<MdSettings />
</MenuButton>
</Col>
</Row>
<Row>
<Col>
<Spacer />
</Col>
</Row>
</Container>
</Collapse>
<MenuButton
isMain
className="fixed-bottom"
onClick={() => {
if (mainMenuIsOpen) {
onCloseMainMenu();
} else {
onOpenMainMenu();
}
}}
toolTip={menuBtnText}
>
{mainIcon}
</MenuButton>
</div>
);
}