From 6c3f31d382c7bad7033944642df6b366b9fa949e Mon Sep 17 00:00:00 2001 From: George Marshall Date: Tue, 13 Jun 2023 08:11:21 -0700 Subject: [PATCH] Adding background/default to BorderColor enum to prevent propType error and updating tests (#19571) --- ui/components/multichain/account-picker/account-picker.js | 4 ++-- .../multichain/account-picker/account-picker.test.js | 1 + ui/helpers/constants/design-system.ts | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ui/components/multichain/account-picker/account-picker.js b/ui/components/multichain/account-picker/account-picker.js index 8ef5c637f..8ac99e61e 100644 --- a/ui/components/multichain/account-picker/account-picker.js +++ b/ui/components/multichain/account-picker/account-picker.js @@ -13,7 +13,7 @@ import { AlignItems, BackgroundColor, BorderRadius, - DISPLAY, + Display, FontWeight, IconColor, Size, @@ -31,7 +31,7 @@ export const AccountPicker = ({ address, name, onClick, disabled }) => { borderRadius={BorderRadius.LG} ellipsis textProps={{ - display: DISPLAY.FLEX, + display: Display.Flex, gap: 2, alignItems: AlignItems.center, }} diff --git a/ui/components/multichain/account-picker/account-picker.test.js b/ui/components/multichain/account-picker/account-picker.test.js index 5c499929d..efc5fb61c 100644 --- a/ui/components/multichain/account-picker/account-picker.test.js +++ b/ui/components/multichain/account-picker/account-picker.test.js @@ -10,6 +10,7 @@ const DEFAULT_PROPS = { name: 'Account 1', address: '0x0dcd5d886577d5081b0c52e242ef29e70be3e7bc', onClick: () => undefined, + disabled: false, }; const render = (props = {}, state = {}) => { diff --git a/ui/helpers/constants/design-system.ts b/ui/helpers/constants/design-system.ts index 4f58aca27..bfab0accc 100644 --- a/ui/helpers/constants/design-system.ts +++ b/ui/helpers/constants/design-system.ts @@ -106,6 +106,7 @@ export enum BorderColor { lineaTestnet = 'lineatestnet', transparent = 'transparent', localhost = 'localhost', + backgroundDefault = 'background-default', // exception for border color when element is meant to look "cut out" } export enum TextColor {