From fb68af94f1d8f1cc7619fef8097f96e00930a575 Mon Sep 17 00:00:00 2001 From: William Grant Date: Fri, 7 Jun 2024 18:13:49 +1000 Subject: [PATCH] fix: no need for reactnode or string type reactnode supports strings --- ts/components/basic/Heading.tsx | 2 +- ts/components/settings/SessionSettingListItem.tsx | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ts/components/basic/Heading.tsx b/ts/components/basic/Heading.tsx index 31d1f53ba..332080f74 100644 --- a/ts/components/basic/Heading.tsx +++ b/ts/components/basic/Heading.tsx @@ -2,7 +2,7 @@ import { ReactNode } from 'react'; import styled, { CSSProperties } from 'styled-components'; export type HeadingProps = { - children: string | ReactNode; + children: ReactNode; color?: string; style?: CSSProperties; /** center | start (left) | end (right) */ diff --git a/ts/components/settings/SessionSettingListItem.tsx b/ts/components/settings/SessionSettingListItem.tsx index d8639e90f..77c15a5d7 100644 --- a/ts/components/settings/SessionSettingListItem.tsx +++ b/ts/components/settings/SessionSettingListItem.tsx @@ -75,8 +75,8 @@ const StyledSettingItemClickable = styled(StyledSettingItemInline)` `; export const SettingsTitleAndDescription = (props: { - title?: string | ReactNode; - description?: string | ReactNode; + title?: ReactNode; + description?: ReactNode; childrenDescription?: ReactNode; icon?: SessionIconProps; }) => {