File tree Expand file tree Collapse file tree 1 file changed +14
-6
lines changed
Expand file tree Collapse file tree 1 file changed +14
-6
lines changed Original file line number Diff line number Diff line change @@ -167,6 +167,19 @@ export default class ActionButtonItem extends Component {
167167 textContainerStyle
168168 ] ;
169169
170+ const title = (
171+ React . isValidElement ( this . props . title ) ?
172+ this . props . title
173+ : (
174+ < Text
175+ allowFontScaling = { false }
176+ style = { [ styles . text , this . props . textStyle ] }
177+ >
178+ { this . props . title }
179+ </ Text >
180+ )
181+ )
182+
170183 return (
171184 < TextTouchable
172185 background = { touchableBackground (
@@ -177,12 +190,7 @@ export default class ActionButtonItem extends Component {
177190 onPress = { this . props . onPress }
178191 >
179192 < View style = { textStyles } >
180- < Text
181- allowFontScaling = { false }
182- style = { [ styles . text , this . props . textStyle ] }
183- >
184- { this . props . title }
185- </ Text >
193+ { title }
186194 </ View >
187195 </ TextTouchable >
188196 ) ;
You can’t perform that action at this time.
0 commit comments