@@ -1160,30 +1160,36 @@ const EventModal: React.FC<BaseEventModalProps> = ({
11601160 { /* Notification Section */ }
11611161 { selectedEventType && (
11621162 < Box sx = { { display : 'flex' , alignItems : 'center' , gap : 2 } } >
1163- < NotificationsIcon
1164- sx = { { color : selectedEventType . sendSlackNotifications ? 'text.secondary' : 'text.disabled' } }
1165- />
1163+ < NotificationsIcon sx = { { color : 'text.secondary' } } />
11661164 < Tooltip
11671165 arrow
11681166 placement = "right"
11691167 title = {
11701168 ! selectedEventType . sendSlackNotifications
11711169 ? 'Slack notifications are disabled for this event type.'
1172- : ! selectedTeams . length && ! workPackageIds . length
1173- ? ''
1174- : 'Slack notifications will be sent for this event. '
1170+ : selectedTeams . length || workPackageIds . length
1171+ ? 'Slack notifications will be sent for this event. '
1172+ : ''
11751173 }
11761174 >
11771175 < Box sx = { { display : 'flex' , alignItems : 'center' , gap : 1 , cursor : 'default' } } >
1178- < NERSwitch checked = { selectedEventType . sendSlackNotifications } disabled />
1179- { selectedEventType . sendSlackNotifications && ! selectedTeams . length && ! workPackageIds . length ? (
1176+ < Typography variant = "body2" color = { 'text.disabled' } fontWeight = { 500 } >
1177+ { selectedEventType . sendSlackNotifications ? 'On' : 'Off' }
1178+ </ Typography >
1179+ { selectedEventType . sendSlackNotifications && ! selectedTeams . length && ! workPackageIds . length && (
11801180 < Box sx = { { display : 'flex' , alignItems : 'center' , gap : 0.5 } } >
11811181 < WarningAmberIcon sx = { { color : 'error.main' , fontSize : 18 } } />
11821182 < Typography variant = "body2" color = "error.main" >
1183- Add a team or work package to send notifications
1183+ Add{ ' ' }
1184+ { selectedEventType . teams && selectedEventType . workPackage
1185+ ? 'a team or work package'
1186+ : selectedEventType . teams
1187+ ? 'a team'
1188+ : 'a work package' } { ' ' }
1189+ to send notifications
11841190 </ Typography >
11851191 </ Box >
1186- ) : null }
1192+ ) }
11871193 </ Box >
11881194 </ Tooltip >
11891195 </ Box >
0 commit comments