1234567891011121314151617181920212223242526272829303132333435 |
- #import "RNNBottomTabOptions.h"
- #import "DotIndicatorOptions.h"
- #import "DotIndicatorParser.h"
-
- @implementation RNNBottomTabOptions
-
- - (instancetype)initWithDict:(NSDictionary *)dict {
- self = [super init];
- self.tag = arc4random();
-
- self.text = [TextParser parse:dict key:@"text"];
- self.badge = [TextParser parse:dict key:@"badge"];
- self.badgeColor = [ColorParser parse:dict key:@"badgeColor"];
- self.fontFamily = [TextParser parse:dict key:@"fontFamily"];
- self.fontWeight = [TextParser parse:dict key:@"fontWeight"];
- self.testID = [TextParser parse:dict key:@"testID"];
-
- self.dotIndicator = [DotIndicatorParser parse:dict];
-
- self.icon = [ImageParser parse:dict key:@"icon"];
- self.selectedIcon = [ImageParser parse:dict key:@"selectedIcon"];
- self.iconColor = [ColorParser parse:dict key:@"iconColor"];
- self.selectedIconColor = [ColorParser parse:dict key:@"selectedIconColor"];
- self.selectedTextColor = [ColorParser parse:dict key:@"selectedTextColor"];
- self.iconInsets = [DictionaryParser parse:dict key:@"iconInsets"];
-
- self.textColor = [ColorParser parse:dict key:@"textColor"];
- self.fontSize = [NumberParser parse:dict key:@"fontSize"];
- self.visible = [BoolParser parse:dict key:@"visible"];
-
- return self;
- }
-
- @end
|