diff --git a/doric-iOS/Pod/Classes/Shader/DoricTextNode.m b/doric-iOS/Pod/Classes/Shader/DoricTextNode.m index 45dd4052..3a9bf44b 100644 --- a/doric-iOS/Pod/Classes/Shader/DoricTextNode.m +++ b/doric-iOS/Pod/Classes/Shader/DoricTextNode.m @@ -180,6 +180,16 @@ - (void)blendView:(UILabel *)view forPropName:(NSString *)name propValue:(id)pro }]; }]; + } else if ([name isEqualToString:@"shadow"]) { + NSDictionary *dic = prop; + CGFloat opacity = [(NSNumber *) dic[@"opacity"] floatValue]; + if (opacity > CGFLOAT_MIN) { + UIColor *color = DoricColor((NSNumber *) dic[@"color"]); + view.layer.shadowColor = color.CGColor; + view.layer.shadowRadius = [(NSNumber *) dic[@"radius"] floatValue]; + view.layer.shadowOffset = CGSizeMake([(NSNumber *) dic[@"offsetX"] floatValue], [(NSNumber *) dic[@"offsetY"] floatValue]); + view.layer.shadowOpacity = (float) opacity; + } } else { [super blendView:view forPropName:name propValue:prop]; }