| 123456789101112131415161718192021222324252627282930313233343536373839404142 | 
							- //
 
- //  UIView+PublicInit.m
 
- //  Asteria
 
- //
 
- //  Created by iOS on 2023/4/24.
 
- //
 
- #import "UIView+PublicInit.h"
 
- @implementation UIView (PublicInit)
 
- // MARK: - base create
 
- + (UIView *)baseV {
 
-     UIView *v = [[UIView alloc] init];
 
-     v.backgroundColor = UIColor.whiteColor;
 
-     return v;
 
- }
 
- + (UILabel *)baseLb {
 
-     UILabel *lb = [[UILabel alloc] init];
 
-     lb.font = [UIFont fontWithName:Rob_Regular size:14];
 
-     lb.textColor = [UIColor blackColor];
 
-     lb.backgroundColor = [UIColor clearColor];
 
-     return lb;
 
- }
 
- + (UIImageView *)baseImgV {
 
-     UIImageView *imgV = [[UIImageView alloc] init];
 
-     imgV.contentMode = UIViewContentModeScaleAspectFit;
 
-     return imgV;
 
- }
 
- + (UIStackView *)baseStackV:(BOOL)isVertical {
 
-     UIStackView *stackV = [[UIStackView alloc] init];
 
-     stackV.axis = isVertical ? UILayoutConstraintAxisVertical : UILayoutConstraintAxisHorizontal;
 
-     stackV.spacing = 8;
 
-     stackV.alignment = UIStackViewAlignmentFill;
 
-     stackV.distribution = UIStackViewDistributionFill;
 
-     return stackV;
 
- }
 
- @end
 
 
  |