cdts/xdts-ios 3/TreeHole/Code/Utility/InputView/PYInputView.h

54 lines
1.2 KiB
C
Raw Normal View History

2023-07-27 09:20:00 +08:00
//
// PYInputView.h
// Food
//
// Created by ko1o on 2019/7/16.
// Copyright © 2019年 ko1o. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "UITextField+MTLimit.h"
#import "PYGetSmsCodeButton.h"
NS_ASSUME_NONNULL_BEGIN
typedef NS_ENUM(NSUInteger, PYInputViewType) {
PYInputViewTypeNormal,
PYInputViewTypeVerifyCode,
PYInputViewTypeForm, // 表单
};
typedef NS_ENUM(NSUInteger, PYInputViewLineLead) {
PYInputViewLineLeadTitle,
PYInputViewLineLeadField,
};
@interface PYInputView : UIView
@property (nonatomic, strong) UITextField *textField;
@property (nonatomic, strong) NSString *text;
@property (nonatomic, assign) BOOL enablePick;
@property (nonatomic, assign) PYInputViewType type;
@property (nonatomic, assign) CGFloat titleWidth;
@property (nonatomic, strong) UIView *lineView;
@property (nonatomic, strong) PYGetSmsCodeButton *smsCodeButton;
@property (nonatomic, assign) PYInputViewLineLead lead;
+ (instancetype)inputViewWithType:(PYInputViewType)type
keyboardType:(UIKeyboardType)keyboardType
title:(NSString *)title
placeholder:(NSString *)placeholder
unit:(NSString * _Nullable)unit;
@end
NS_ASSUME_NONNULL_END