keep edit

This commit is contained in:
edwinQQQ
2025-10-17 14:52:29 +08:00
parent 22185d799e
commit 517365879a
622 changed files with 40518 additions and 7298 deletions

View File

@@ -0,0 +1,37 @@
//
// UIView+GradientLayer.h
// YuMi
//
// Created by P on 2024/11/18.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface UIView (GradientLayer)
/// 为视图添加渐变背景
/// @param colors 渐变颜色数组 (NSArray<UIColor *> *)
/// @param startPoint 渐变起点 (CGPoint)
/// @param endPoint 渐变终点 (CGPoint)
/// @param cornerRadius 圆角半径 (CGFloat)
- (void)addGradientBackgroundWithColors:(NSArray<UIColor *> *)colors
startPoint:(CGPoint)startPoint
endPoint:(CGPoint)endPoint
cornerRadius:(CGFloat)cornerRadius;
/// 移除渐变背景
- (void)removeGradientBackground;
/// 更新渐变背景
/// @param colors 渐变颜色数组 (NSArray<UIColor *> *)
/// @param startPoint 渐变起点 (CGPoint)
/// @param endPoint 渐变终点 (CGPoint)
- (void)updateGradientBackgroundWithColors:(NSArray<UIColor *> *)colors
startPoint:(CGPoint)startPoint
endPoint:(CGPoint)endPoint;
@end
NS_ASSUME_NONNULL_END