Cody Weaver 3c636c1704
[ShadowLayer] Subclass UIView in corner radius example (#5388)
### Context
In working on #4848 I noticed that the example uses an UILabel which may have a different backing layer (possibly CATextLayer) than UIView. This change makes it easier for another team member to address this issue.
### The fix
Subclass UIView which I believe is the most common use case for using a custom shadow layer in this example.
### Related issue
#4848
### Videos
| Before | After |
| - | - |
|![develop](https://user-images.githubusercontent.com/7131294/46751924-efc43800-cc89-11e8-8327-b05f6bb5f3f3.gif)|![shadowafter](https://user-images.githubusercontent.com/7131294/46751933-f357bf00-cc89-11e8-9e17-eea6dd0dd7bd.gif)|
2018-10-10 13:33:15 -04:00

24 lines
860 B
Objective-C

// Copyright 2018-present the Material Components for iOS authors. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#import <UIKit/UIKit.h>
#import "MaterialShadowElevations.h"
@interface ShadowRadiusLabel : UIView
@property(nonatomic, assign) CGFloat cornerRadius;
@property(nonatomic, assign) MDCShadowElevation elevation;
@end