From 58a223ba442ba7322b5a8ce31627f112638cf31f Mon Sep 17 00:00:00 2001 From: Luke Walczak Date: Sat, 11 Mar 2023 15:54:46 +0100 Subject: [PATCH] fix: revert 'replace MaterialCommunityIcon in favor of internal Icon' (#3745) --- src/components/Appbar/AppbarBackIcon.tsx | 6 +++--- src/components/Checkbox/CheckboxAndroid.tsx | 6 +++--- src/components/Checkbox/CheckboxIOS.tsx | 6 +++--- src/components/Chip/Chip.tsx | 9 +++++---- .../DataTable/DataTablePagination.tsx | 18 +++++++++--------- src/components/DataTable/DataTableTitle.tsx | 6 +++--- src/components/Icon.tsx | 9 +++------ src/components/List/ListAccordion.tsx | 6 +++--- src/components/RadioButton/RadioButtonIOS.tsx | 6 +++--- src/components/Searchbar.tsx | 10 +++++----- src/components/Snackbar.tsx | 6 +++--- 11 files changed, 43 insertions(+), 45 deletions(-) diff --git a/src/components/Appbar/AppbarBackIcon.tsx b/src/components/Appbar/AppbarBackIcon.tsx index b6dc6a678e..14aa21ec03 100644 --- a/src/components/Appbar/AppbarBackIcon.tsx +++ b/src/components/Appbar/AppbarBackIcon.tsx @@ -1,7 +1,7 @@ import * as React from 'react'; import { Platform, I18nManager, View, Image, StyleSheet } from 'react-native'; -import Icon from '../Icon'; +import MaterialCommunityIcon from '../MaterialCommunityIcon'; const AppbarBackIcon = ({ size, color }: { size: number; color: string }) => { const iosIconSize = size - 3; @@ -27,8 +27,8 @@ const AppbarBackIcon = ({ size, color }: { size: number; color: string }) => { /> ) : ( - - - ) : ( - ) : ( - ( - ( - ( - ( - - { const theme = useInternalTheme(themeOverrides); const direction = - customDirection || - (typeof source === 'object' && source.direction && source.source + typeof source === 'object' && source.direction && source.source ? source.direction === 'auto' ? I18nManager.getConstants().isRTL ? 'rtl' : 'ltr' : source.direction - : null); + : null; const s = typeof source === 'object' && source.direction && source.source diff --git a/src/components/List/ListAccordion.tsx b/src/components/List/ListAccordion.tsx index a2fb6001b1..ab54276117 100644 --- a/src/components/List/ListAccordion.tsx +++ b/src/components/List/ListAccordion.tsx @@ -12,7 +12,7 @@ import { import { useInternalTheme } from '../../core/theming'; import type { ThemeProp } from '../../types'; -import Icon from '../Icon'; +import MaterialCommunityIcon from '../MaterialCommunityIcon'; import TouchableRipple from '../TouchableRipple/TouchableRipple'; import Text from '../Typography/Text'; import { ListAccordionGroupContext } from './ListAccordionGroup'; @@ -262,8 +262,8 @@ const ListAccordion = ({ isExpanded: isExpanded, }) ) : ( - - ( icon={ icon || (({ size, color }) => ( - ( icon={ clearIcon || (({ size, color }) => ( - { return ( -