From 030b510e931895025f77f83f55d55b36e8b2faf7 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 30 Aug 2024 14:16:47 +0200 Subject: [PATCH] support "alertStatus" field in address metadata payload --- lib/address/parseMetaPayload.ts | 1 + types/api/addressMetadata.ts | 3 +++ ui/address/details/AddressMetadataAlert.tsx | 2 +- 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/address/parseMetaPayload.ts b/lib/address/parseMetaPayload.ts index c02d2c4f20..f8d6fbc570 100644 --- a/lib/address/parseMetaPayload.ts +++ b/lib/address/parseMetaPayload.ts @@ -30,6 +30,7 @@ export default function parseMetaPayload(meta: AddressMetadataTag['meta']): Addr 'data', 'alertBgColor', 'alertTextColor', + 'alertStatus', ]; for (const stringField of stringFields) { diff --git a/types/api/addressMetadata.ts b/types/api/addressMetadata.ts index caabd8535a..6840a8235f 100644 --- a/types/api/addressMetadata.ts +++ b/types/api/addressMetadata.ts @@ -1,3 +1,5 @@ +import type { AlertStatus } from '@chakra-ui/react'; + export interface AddressMetadataInfo { addresses: Record; @@ -35,6 +37,7 @@ export interface AddressMetadataTagApi extends Omit data?: string; alertBgColor?: string; alertTextColor?: string; + alertStatus?: AlertStatus; } | null; } diff --git a/ui/address/details/AddressMetadataAlert.tsx b/ui/address/details/AddressMetadataAlert.tsx index 707ba804d4..10e024a94f 100644 --- a/ui/address/details/AddressMetadataAlert.tsx +++ b/ui/address/details/AddressMetadataAlert.tsx @@ -23,7 +23,7 @@ const AddressMetadataAlert = ({ tags }: Props) => {