Skip to content
Snippets Groups Projects
Unverified Commit 023cc31d authored by csuadev's avatar csuadev Committed by GitHub
Browse files

Regression: Device management table missing device icon and ip text ellipsis (#26255)

parent 76ca88ca
No related branches found
No related tags found
No related merge requests found
......@@ -2,8 +2,10 @@ import { Box, Icon } from '@rocket.chat/fuselage';
import React, { ComponentProps, ReactElement } from 'react';
const iconMap: Record<string, ComponentProps<typeof Icon>['name']> = {
browser: 'desktop',
mobile: 'mobile',
'browser': 'desktop',
'mobile': 'mobile',
'desktop-app': 'desktop',
'mobile-app': 'mobile',
};
const DeviceIcon = ({ deviceType }: { deviceType: string }): ReactElement => (
......@@ -18,7 +20,7 @@ const DeviceIcon = ({ deviceType }: { deviceType: string }): ReactElement => (
borderRadius='full'
mie='x8'
>
<Icon name={iconMap[deviceType]} size='x14' color='info' />
<Icon name={iconMap[deviceType] || 'globe'} size='x16' color='info' />
</Box>
);
......
......@@ -73,7 +73,7 @@ const DeviceManagementAdminRow = ({
<TableCell withTruncatedText>{username}</TableCell>
{mediaQuery && <TableCell>{formatDateAndTime(loginAt)}</TableCell>}
{mediaQuery && <TableCell withTruncatedText>{_id}</TableCell>}
{mediaQuery && <TableCell>{ip}</TableCell>}
{mediaQuery && <TableCell withTruncatedText>{ip}</TableCell>}
<TableCell onClick={(e): void => e.stopPropagation()}>
<Menu
title={t('Options')}
......
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