Skip to content
Snippets Groups Projects
Unverified Commit 94850a7f authored by amolghode1981's avatar amolghode1981 Committed by GitHub
Browse files

[NEW] New button for network outage (#25499)

parent 2d40378f
No related branches found
No related tags found
No related merge requests found
......@@ -31,10 +31,24 @@ export const OmnichannelCallToggleReady = (): ReactElement => {
return t('Cannot_disable_while_on_call');
};
const getIcon = (): 'phone-issue' | 'phone' | 'phone-disabled' => {
if (networkStatus === 'offline') {
return 'phone-issue';
}
return registered ? 'phone' : 'phone-disabled';
};
const getColor = (): 'warning' | 'success' | undefined => {
if (networkStatus === 'offline') {
return 'warning';
}
return registered ? 'success' : undefined;
};
const voipCallIcon = {
title: getTooltip(),
color: registered ? 'success' : undefined,
icon: registered ? 'phone' : 'phone-disabled',
color: getColor(),
icon: getIcon(),
} as const;
useEffect(() => {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment