diff --git a/ui/components/app/permissions-connect-permission-list/index.scss b/ui/components/app/permissions-connect-permission-list/index.scss index 0f8c53a3f25f..3faa79dca9bf 100644 --- a/ui/components/app/permissions-connect-permission-list/index.scss +++ b/ui/components/app/permissions-connect-permission-list/index.scss @@ -39,3 +39,7 @@ font-weight: bold; } } + +.tooltip-label-item { + font-weight: bold; +} diff --git a/ui/helpers/utils/permission.js b/ui/helpers/utils/permission.js index 9761796e4be5..ba9a87cad5dc 100644 --- a/ui/helpers/utils/permission.js +++ b/ui/helpers/utils/permission.js @@ -69,7 +69,15 @@ const PERMISSION_DESCRIPTIONS = deepFreeze({ , path.join('/'), ]), - description: t('permission_viewNamedBip32PublicKeysDescription'), + description: t('permission_viewBip32PublicKeysDescription', [ + + {friendlyName} + , + path.join('/'), + ]), }; } @@ -81,7 +89,15 @@ const PERMISSION_DESCRIPTIONS = deepFreeze({ , curve, ]), - description: t('permission_viewNamedBip32PublicKeysDescription'), + description: t('permission_viewBip32PublicKeysDescription', [ + + {path.join('/')} + , + path.join('/'), + ]), }; }), [RestrictedMethods.snap_getBip32Entropy]: (t, _, permissionValue) => @@ -102,7 +118,15 @@ const PERMISSION_DESCRIPTIONS = deepFreeze({ , path.join('/'), ]), - description: t('permission_manageNamedBip32KeysDescription'), + description: t('permission_manageBip32KeysDescription', [ + + {friendlyName} + , + curve, + ]), }; } @@ -114,7 +138,15 @@ const PERMISSION_DESCRIPTIONS = deepFreeze({ , curve, ]), - description: t('permission_manageBip32KeysDescription'), + description: t('permission_manageBip32KeysDescription', [ + + {path.join('/')} + , + curve, + ]), }; }), [RestrictedMethods.snap_getBip44Entropy]: (t, _, permissionValue) => @@ -125,7 +157,15 @@ const PERMISSION_DESCRIPTIONS = deepFreeze({ `${coinType} (Unrecognized protocol)`} , ]), - description: t('permission_manageBip44KeysDescription'), + description: t('permission_manageBip44KeysDescription', [ + + {coinTypeToProtocolName(coinType) || + `${coinType} (Unrecognized protocol)`} + , + ]), leftIcon: 'fas fa-door-open', rightIcon: 'fa fa-exclamation-triangle', weight: 1, @@ -161,14 +201,14 @@ const PERMISSION_DESCRIPTIONS = deepFreeze({ {friendlyName} , ]), - description: t('permission_accessSnapDescription'), + description: t('permission_accessSnapDescription', [friendlyName]), }; } return { ...baseDescription, label: t('permission_accessSnap', [snapId]), - description: t('permission_accessSnapDescription'), + description: t('permission_accessSnapDescription', [snapId]), }; }, [EndowmentPermissions['endowment:network-access']]: (t) => ({ @@ -247,7 +287,7 @@ const PERMISSION_DESCRIPTIONS = deepFreeze({ results.push({ ...baseDescription, label: t('permission_rpc', [t('otherSnaps')]), - description: t('permission_rpcDescription'), + description: t('permission_rpcDescription', [t('otherSnaps')]), }); } @@ -255,7 +295,7 @@ const PERMISSION_DESCRIPTIONS = deepFreeze({ results.push({ ...baseDescription, label: t('permission_rpc', [t('websites')]), - description: t('permission_rpcDescription'), + description: t('permission_rpcDescription', [t('websites')]), }); } @@ -360,7 +400,8 @@ export function getRightIcon({ rightIcon, description, weight }) { 'permission__tooltip-icon', weight === 1 && 'permission__tooltip-icon__warning', )} - html={description} + html={
{description}
} + position="bottom" >