Move notifications bell back in labs

This commit is contained in:
Germain 2023-08-31 21:21:32 +01:00
parent 45094bda7c
commit a5e186b978
3 changed files with 23 additions and 10 deletions

View file

@ -106,6 +106,8 @@ export default function RoomHeader({ room }: { room: Room }): JSX.Element {
}, [room, directRoomsList]); }, [room, directRoomsList]);
const e2eStatus = useEncryptionStatus(client, room); const e2eStatus = useEncryptionStatus(client, room);
const notificationsEnabled = useFeatureEnabled("feature_notifications");
return ( return (
<Flex <Flex
as="header" as="header"
@ -187,15 +189,17 @@ export default function RoomHeader({ room }: { room: Room }): JSX.Element {
> >
<ThreadsIcon /> <ThreadsIcon />
</IconButton> </IconButton>
<IconButton {notificationsEnabled && (
indicator={notificationColorToIndicator(globalNotificationState.color)} <IconButton
onClick={() => { indicator={notificationColorToIndicator(globalNotificationState.color)}
showOrHidePanel(RightPanelPhases.NotificationPanel); onClick={() => {
}} showOrHidePanel(RightPanelPhases.NotificationPanel);
title={_t("Notifications")} }}
> title={_t("Notifications")}
<NotificationsIcon /> >
</IconButton> <NotificationsIcon />
</IconButton>
)}
</Flex> </Flex>
{!isDirectMessage && ( {!isDirectMessage && (
<BodyText <BodyText

View file

@ -868,7 +868,8 @@
"hidebold": "Hide notification dot (only display counters badges)", "hidebold": "Hide notification dot (only display counters badges)",
"intentional_mentions": "Enable intentional mentions", "intentional_mentions": "Enable intentional mentions",
"ask_to_join": "Enable ask to join", "ask_to_join": "Enable ask to join",
"new_room_decoration_ui": "Under active development, new room header & details interface" "new_room_decoration_ui": "Under active development, new room header & details interface",
"notifications": "Notifications panel"
}, },
"Thank you for trying the beta, please go into as much detail as you can so we can improve it.": "Thank you for trying the beta, please go into as much detail as you can so we can improve it.", "Thank you for trying the beta, please go into as much detail as you can so we can improve it.": "Thank you for trying the beta, please go into as much detail as you can so we can improve it.",
"Notification Settings": "Notification Settings", "Notification Settings": "Notification Settings",

View file

@ -552,6 +552,14 @@ export const SETTINGS: { [setting: string]: ISetting } = {
default: false, default: false,
controller: new ReloadOnChangeController(), controller: new ReloadOnChangeController(),
}, },
"feature_notifications": {
isFeature: true,
labsGroup: LabGroup.Messaging,
displayName: _td("labs|notifications"),
supportedLevels: LEVELS_FEATURE,
default: false,
controller: new ReloadOnChangeController(),
},
"useCompactLayout": { "useCompactLayout": {
supportedLevels: LEVELS_DEVICE_ONLY_SETTINGS, supportedLevels: LEVELS_DEVICE_ONLY_SETTINGS,
displayName: _td("Use a more compact 'Modern' layout"), displayName: _td("Use a more compact 'Modern' layout"),