Pārlūkot izejas kodu

Allow setting UITabBarItem.title to default value (#5280)

The default value for `UITabBarItem.title` is `nil` as specified by the docs:
> You should set this property before adding the item to a bar. The default value is nil.
https://developer.apple.com/documentation/uikit/uibaritem/1616412-title

This changes allows for this to be `nil`.
Danilo Bürger 5 gadus atpakaļ
vecāks
revīzija
76d832b683
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1
    1
      lib/ios/RNNTabBarItemCreator.m

+ 1
- 1
lib/ios/RNNTabBarItemCreator.m Parādīt failu

@@ -12,7 +12,7 @@
12 12
 	
13 13
 	tabItem.image = [self getIconImage:icon withTint:iconColor];
14 14
 	tabItem.selectedImage = [self getSelectedIconImage:selectedIcon selectedIconColor:selectedIconColor];
15
-	tabItem.title = [bottomTabOptions.text getWithDefaultValue:@""];
15
+	tabItem.title = [bottomTabOptions.text getWithDefaultValue:nil];
16 16
 	tabItem.tag = bottomTabOptions.tag;
17 17
 	tabItem.accessibilityIdentifier = [bottomTabOptions.testID getWithDefaultValue:nil];
18 18