Add events to sidebar
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
parent
403bcba525
commit
0481e528af
2 changed files with 19 additions and 0 deletions
|
@ -34,6 +34,7 @@ const messages = defineMessages({
|
||||||
logout: { id: 'navigation_bar.logout', defaultMessage: 'Logout' },
|
logout: { id: 'navigation_bar.logout', defaultMessage: 'Logout' },
|
||||||
bookmarks: { id: 'column.bookmarks', defaultMessage: 'Bookmarks' },
|
bookmarks: { id: 'column.bookmarks', defaultMessage: 'Bookmarks' },
|
||||||
lists: { id: 'column.lists', defaultMessage: 'Lists' },
|
lists: { id: 'column.lists', defaultMessage: 'Lists' },
|
||||||
|
events: { id: 'column.events', defaultMessage: 'Events' },
|
||||||
invites: { id: 'navigation_bar.invites', defaultMessage: 'Invites' },
|
invites: { id: 'navigation_bar.invites', defaultMessage: 'Invites' },
|
||||||
developers: { id: 'navigation.developers', defaultMessage: 'Developers' },
|
developers: { id: 'navigation.developers', defaultMessage: 'Developers' },
|
||||||
addAccount: { id: 'profile_dropdown.add_account', defaultMessage: 'Add an existing account' },
|
addAccount: { id: 'profile_dropdown.add_account', defaultMessage: 'Add an existing account' },
|
||||||
|
@ -208,6 +209,15 @@ const SidebarMenu: React.FC = (): JSX.Element | null => {
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
{features.events && (
|
||||||
|
<SidebarLink
|
||||||
|
to='/events'
|
||||||
|
icon={require('@tabler/icons/calendar-event.svg')}
|
||||||
|
text={intl.formatMessage(messages.events)}
|
||||||
|
onClick={onClose}
|
||||||
|
/>
|
||||||
|
)}
|
||||||
|
|
||||||
{settings.get('isDeveloper') && (
|
{settings.get('isDeveloper') && (
|
||||||
<SidebarLink
|
<SidebarLink
|
||||||
to='/developers'
|
to='/developers'
|
||||||
|
|
|
@ -13,6 +13,7 @@ const messages = defineMessages({
|
||||||
follow_requests: { id: 'navigation_bar.follow_requests', defaultMessage: 'Follow requests' },
|
follow_requests: { id: 'navigation_bar.follow_requests', defaultMessage: 'Follow requests' },
|
||||||
bookmarks: { id: 'column.bookmarks', defaultMessage: 'Bookmarks' },
|
bookmarks: { id: 'column.bookmarks', defaultMessage: 'Bookmarks' },
|
||||||
lists: { id: 'column.lists', defaultMessage: 'Lists' },
|
lists: { id: 'column.lists', defaultMessage: 'Lists' },
|
||||||
|
events: { id: 'column.events', defaultMessage: 'Events' },
|
||||||
developers: { id: 'navigation.developers', defaultMessage: 'Developers' },
|
developers: { id: 'navigation.developers', defaultMessage: 'Developers' },
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -57,6 +58,14 @@ const SidebarNavigation = () => {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (features.events) {
|
||||||
|
menu.push({
|
||||||
|
to: '/events',
|
||||||
|
text: intl.formatMessage(messages.events),
|
||||||
|
icon: require('@tabler/icons/calendar-event.svg'),
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
if (settings.get('isDeveloper')) {
|
if (settings.get('isDeveloper')) {
|
||||||
menu.push({
|
menu.push({
|
||||||
to: '/developers',
|
to: '/developers',
|
||||||
|
|
Loading…
Reference in a new issue