Skip to content

Commit 949a518

Browse files
authored
fix(NodeEndpointsTooltipContent): change fields order (#1585)
1 parent ff82158 commit 949a518

File tree

1 file changed

+12
-9
lines changed

1 file changed

+12
-9
lines changed

src/components/TooltipsContent/NodeEndpointsTooltipContent/NodeEndpointsTooltipContent.tsx

+12-9
Original file line numberDiff line numberDiff line change
@@ -21,26 +21,29 @@ interface NodeEdpointsTooltipProps {
2121
export const NodeEndpointsTooltipContent = ({data, nodeHref}: NodeEdpointsTooltipProps) => {
2222
const isUserAllowedToMakeChanges = useTypedSelector(selectIsUserAllowedToMakeChanges);
2323
const info: (DefinitionListItemProps & {key: string})[] = [];
24-
if (data?.Host) {
24+
25+
if (data?.Roles?.length) {
2526
info.push({
26-
name: i18n('field_host'),
27-
children: data.Host,
28-
copyText: data.Host,
29-
key: 'Host',
27+
name: i18n('field_roles'),
28+
children: data.Roles.join(', '),
29+
key: 'Roles',
3030
});
3131
}
32+
3233
if (data?.Tenants?.[0]) {
3334
info.push({
3435
name: i18n('field_database'),
3536
children: data.Tenants[0],
3637
key: 'Database',
3738
});
3839
}
39-
if (data?.Roles?.length) {
40+
41+
if (data?.Host) {
4042
info.push({
41-
name: i18n('field_roles'),
42-
children: data.Roles.join(', '),
43-
key: 'Roles',
43+
name: i18n('field_host'),
44+
children: data.Host,
45+
copyText: data.Host,
46+
key: 'Host',
4447
});
4548
}
4649

0 commit comments

Comments
 (0)