From c5a446fffc7c281cef6ae192878dc2fa86d15187 Mon Sep 17 00:00:00 2001 From: barshathakuri Date: Thu, 5 Dec 2024 18:03:24 +0545 Subject: [PATCH] Fix label type for chip component --- .changeset/cold-dingos-cross.md | 5 +++++ packages/ui/src/components/Chip/index.tsx | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 .changeset/cold-dingos-cross.md diff --git a/.changeset/cold-dingos-cross.md b/.changeset/cold-dingos-cross.md new file mode 100644 index 0000000000..3a5e6d74a9 --- /dev/null +++ b/.changeset/cold-dingos-cross.md @@ -0,0 +1,5 @@ +--- +"@ifrc-go/ui": patch +--- + +Fix label type for chip component diff --git a/packages/ui/src/components/Chip/index.tsx b/packages/ui/src/components/Chip/index.tsx index e136a938a6..6365b00638 100644 --- a/packages/ui/src/components/Chip/index.tsx +++ b/packages/ui/src/components/Chip/index.tsx @@ -1,4 +1,4 @@ -import { useCallback } from 'react'; +import React, { useCallback } from 'react'; import { CloseFillIcon } from '@ifrc-go/icons'; import { _cs, @@ -22,7 +22,7 @@ const chipVariantToClassNameMap: Record = { export interface Props { className?: string; name: N; - label: string; + label: React.ReactNode; variant?: ChipVariant; onDelete?: (name: N, e: React.MouseEvent) => void; }