Commit 21c42c18 authored by Steven杜宇's avatar Steven杜宇

Merge branch 'develop' into duyu

parents 51329e3e 8be31236
......@@ -46,7 +46,7 @@ class YHTwoOptionAlertView: UIView {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
addSubview(centerView)
......@@ -54,8 +54,8 @@ class YHTwoOptionAlertView: UIView {
messageLabel = {
let label = UILabel()
label.text = ""
label.font = kFont(size: 16)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_R(ofSize: 16)
label.textColor = UIColor.mainTextColor
label.textAlignment = .center
label.numberOfLines = 0
return label
......@@ -65,11 +65,11 @@ class YHTwoOptionAlertView: UIView {
leftButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0xffffff)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("取消".local, for: .normal)
button.setTitleColor( UIColor(hex:0x3c86f8), for: .normal)
button.layer.cornerRadius = 8
button.layer.cornerRadius = kCornerRadius6
button.layer.borderWidth = 1
button.layer.borderColor = UIColor(hex: 0x3c86f8).cgColor
button.addTarget(self, action: #selector(disagree), for: .touchUpInside)
......@@ -80,11 +80,11 @@ class YHTwoOptionAlertView: UIView {
rightButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x3c86f8)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("确认".local, for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
button.layer.cornerRadius = 8
button.layer.cornerRadius = kCornerRadius6
button.addTarget(self, action: #selector(agree), for: .touchUpInside)
return button
}()
......
......@@ -23,7 +23,7 @@ class YHBbxCollectionViewCell: UICollectionViewCell {
lazy var descripeLable:UILabel = {
let label = UILabel()
label.textColor = UIColor(red: 0.315, green: 0.315, blue: 0.315, alpha: 1)
label.font = kFont(size: 12)
label.font = UIFont.PFSC_R(ofSize: 12)
label.textAlignment = .center
label.text = "证件办理"
// label.backgroundColor = .blue
......
......@@ -43,7 +43,7 @@ class YHDavidCell1: UITableViewCell {
lazy var subContentView : UIView = {
let view = UIView()
view.backgroundColor = UIColor(hex: 0x999999, alpha: 1.0)
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
......
......@@ -43,7 +43,7 @@ class YHDavidCell2: UITableViewCell {
lazy var subContentView : UIView = {
let view = UIView()
view.backgroundColor = UIColor(hex: 0x999999, alpha: 1.0)
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
view.layer.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1).cgColor
view.layer.cornerRadius = 10
......
......@@ -63,7 +63,7 @@ class YHDavidCell3: UITableViewCell {
let bbxLable = UILabel()
bbxLable.text = "银河推荐官"
bbxLable.textColor = UIColor(red: 0.2, green: 0.2, blue: 0.2, alpha: 1)
bbxLable.font = kFont(size: 18)
bbxLable.font = UIFont.PFSC_R(ofSize: 18)
subContentView.addSubview(bbxLable)
bbxLable.snp.makeConstraints { make in
......@@ -75,7 +75,7 @@ class YHDavidCell3: UITableViewCell {
desLable.text = "邀请拉新,合作共赢"
desLable.frame = CGRect(x: 0, y: 0, width: 141.5, height: 11.5)
desLable.textColor = UIColor(red: 0.592, green: 0.592, blue: 0.592, alpha: 1)
desLable.font = kFont(size: 10)
desLable.font = UIFont.PFSC_R(ofSize: 10)
subContentView.addSubview(desLable)
desLable.snp.makeConstraints { make in
make.left.equalTo(bbxLable.snp.right).offset(11)
......
......@@ -67,7 +67,7 @@ class YHDavidCell5: UITableViewCell {
let bbxLable = UILabel()
bbxLable.text = "百宝箱"
bbxLable.textColor = UIColor(red: 0.2, green: 0.2, blue: 0.2, alpha: 1)
bbxLable.font = kFont(size: 18)
bbxLable.font = UIFont.PFSC_R(ofSize: 18)
subContentView.addSubview(bbxLable)
bbxLable.snp.makeConstraints { make in
......@@ -79,7 +79,7 @@ class YHDavidCell5: UITableViewCell {
desLable.text = "香港本地宝,智慧小助手"
desLable.frame = CGRect(x: 0, y: 0, width: 141.5, height: 11.5)
desLable.textColor = UIColor(red: 0.592, green: 0.592, blue: 0.592, alpha: 1)
desLable.font = kFont(size: 10)
desLable.font = UIFont.PFSC_R(ofSize: 10)
subContentView.addSubview(desLable)
desLable.snp.makeConstraints { make in
make.left.equalTo(bbxLable.snp.right).offset(11)
......
......@@ -115,7 +115,7 @@ class YHFormPickerView: UIView {
let btn = UIButton()
btn.setTitle("取消".local, for: .normal)
btn.titleLabel?.font = UIFont.PFSC_R(ofSize: 14)
btn.setTitleColor(UIColor(hex: 0x222222), for: .normal)
btn.setTitleColor(UIColor.mainTextColor, for: .normal)
btn.addTarget(self, action: #selector(didClickCancelButton), for: .touchUpInside)
return btn
}()
......
......@@ -35,7 +35,7 @@ class YHFormItemExpireDateCell: UITableViewCell {
let str = (isMust ? ("*"+title) : title)
let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 14),
.foregroundColor: UIColor(hex:0x222222)]
.foregroundColor: UIColor.mainTextColor]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
if isMust {
let starRange = NSRange(location: 0, length: 1)
......@@ -89,7 +89,7 @@ class YHFormItemExpireDateCell: UITableViewCell {
let btn = UIButton(type: .custom)
btn.setTitle("长期".local, for: .normal)
btn.titleLabel?.font = UIFont.PFSC_R(ofSize: 14)
btn.setTitleColor(UIColor(hex: 0x222222), for: .normal)
btn.setTitleColor(UIColor.mainTextColor, for: .normal)
btn.iconInLeft(spacing: 6)
btn.setImage(UIImage(named: "form_square_unselect"), for: .normal)
btn.setImage(UIImage(named: "form_square_select"), for: .selected)
......
......@@ -14,7 +14,7 @@ class YHFormItemOnlyDoubleChoiceCell: UITableViewCell {
let btnWidth = 70.0
let btnHeight = 32.0
let btnTitleSelectColor = UIColor(hex: 0x4487F9)
let btnTitleDefaultColor = UIColor(hex:0x222222)
let btnTitleDefaultColor = UIColor.mainTextColor
let btnBgDefaultColor = UIColor(hex:0xF8F9FB)
let btnBgSelectColor = UIColor(hex:0x4487F9, alpha: 0.08)
let answerBaseTag = 9527
......
......@@ -47,6 +47,8 @@ class YHMainApplicantInformationViewController: YHBaseViewController {
}
func setView() {
view.backgroundColor = .contentBkgColor
stepView = {
let step = YHStepView()
step.dataSource = ["初始信息", "证件上传", "基本信息", "证件信息"]
......
......@@ -36,7 +36,7 @@ class YHSelectCountryViewController: YHBaseViewController {
searchView = {
let searchBar = UITextField()
searchBar.placeholder = "搜索国家/地区"
searchBar.backgroundColor = UIColor(hex: 0xf8f9fb)
searchBar.backgroundColor = UIColor.contentBkgColor
searchBar.keyboardType = .default
searchBar.delegate = self
searchBar.layer.cornerRadius = 21
......@@ -75,8 +75,8 @@ class YHSelectCountryViewController: YHBaseViewController {
flagLabel = {
let label = UILabel()
label.text = "热门国家/地区"
label.textColor = UIColor(hex: 0x222222)
label.font = kFont(size: 14)
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_R(ofSize: 14)
return label
}()
view.addSubview(flagLabel)
......@@ -200,8 +200,8 @@ class YHCountryCollectionViewCell: UICollectionViewCell {
let view = UILabel()
view.textAlignment = .center
view.font = UIFont.PFSC_R(ofSize: 13)
view.textColor = UIColor(hex: 0x222222)
view.backgroundColor = UIColor(hex: 0xf8f9fb)
view.textColor = UIColor.mainTextColor
view.backgroundColor = UIColor.contentBkgColor
view.layer.masksToBounds = true
view.layer.cornerRadius = 16
return view
......@@ -241,7 +241,7 @@ class YHCountryTableViewCell: UITableViewCell {
titleLabel = {
let label = UILabel()
label.font = UIFont.PFSC_R(ofSize: 13)
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
contentView.addSubview(titleLabel)
......
......@@ -28,12 +28,12 @@ class YHBottomNextView: UIView {
func setUpView() {
saveButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0xf8f9fb)
button.titleLabel?.font = kBoldFont(size: 15)
button.backgroundColor = UIColor.contentBkgColor
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.contentHorizontalAlignment = .center
button.setTitle("保存", for: .normal)
button.setTitleColor( UIColor(hex:0x222222), for: .normal)
button.layer.cornerRadius = 8
button.setTitleColor( UIColor.mainTextColor, for: .normal)
button.layer.cornerRadius = kCornerRadius6
button.addTarget(self, action: #selector(save), for: .touchUpInside)
return button
}()
......@@ -47,12 +47,12 @@ class YHBottomNextView: UIView {
nextButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x4d9ff8)
button.titleLabel?.font = kBoldFont(size: 15)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.contentHorizontalAlignment = .center
button.setTitle("下一步", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
button.layer.cornerRadius = 8
button.layer.cornerRadius = kCornerRadius6
button.clipsToBounds = true
button.addTarget(self, action: #selector(goNext), for: .touchUpInside)
return button
}()
......@@ -63,6 +63,10 @@ class YHBottomNextView: UIView {
make.height.equalTo(44)
make.width.equalTo(247)
}
nextButton.layoutIfNeeded()
nextButton.backgroundGradient()
}
......
......@@ -58,7 +58,7 @@ class YHCardExampleView: UIView {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
addSubview(centerView)
......@@ -70,8 +70,8 @@ class YHCardExampleView: UIView {
titleLabel = {
let label = UILabel()
label.text = "身份证示例模板"
label.font = kFont(size: 17)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textColor = UIColor.mainTextColor
label.textAlignment = .left
return label
}()
......@@ -97,7 +97,7 @@ class YHCardExampleView: UIView {
lineView = {
let view = UIView()
view.backgroundColor = UIColor(hex: 0xf0f0f0)
view.backgroundColor = UIColor.separatorColor
return view
}()
centerView.addSubview(lineView)
......@@ -111,8 +111,8 @@ class YHCardExampleView: UIView {
messageLabel = {
let label = UILabel()
label.text = "*须使用二代身份证"
label.font = kFont(size: 14)
label.textColor = UIColor(hex:0xc0c0c0)
label.font = UIFont.PFSC_R(ofSize: 14)
label.textColor = UIColor.placeHolderColor
label.textAlignment = .left
label.numberOfLines = 0
return label
......@@ -154,11 +154,11 @@ class YHCardExampleView: UIView {
bottomButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x4d9ffb)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.contentHorizontalAlignment = .center
button.setTitle("知道了", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
button.layer.cornerRadius = 8
button.layer.cornerRadius = kCornerRadius6
button.addTarget(self, action: #selector(dismiss), for: .touchUpInside)
return button
}()
......@@ -182,8 +182,8 @@ class YHCardExampleView: UIView {
}
let label = UILabel()
label.text = array[i]
label.textColor = UIColor(hex: 0x222222)
label.font = kFont(size: 14)
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_R(ofSize: 14)
centerView.addSubview(label)
label.snp.makeConstraints { make in
make.top.equalTo(73)
......
......@@ -83,8 +83,8 @@ class YHDatePickView: UIView {
titleLabel = {
let label = UILabel()
label.text = "选择出生日期"
label.font = kFont(size: 17)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textColor = UIColor.mainTextColor
label.textAlignment = .center
return label
}()
......@@ -98,10 +98,10 @@ class YHDatePickView: UIView {
closeButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("取消", for: .normal)
button.setTitleColor( UIColor(hex:0x222222), for: .normal)
button.setTitleColor( UIColor.mainTextColor, for: .normal)
button.addTarget(self, action: #selector(dismiss), for: .touchUpInside)
return button
}()
......@@ -115,7 +115,7 @@ class YHDatePickView: UIView {
sureButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("确定", for: .normal)
button.setTitleColor( UIColor(hex:0x4487f9), for: .normal)
......@@ -132,7 +132,7 @@ class YHDatePickView: UIView {
lineView = {
let view = UIView()
view.backgroundColor = UIColor(hex: 0xf0f0f0)
view.backgroundColor = UIColor.separatorColor
return view
}()
centerView.addSubview(lineView)
......
......@@ -57,8 +57,8 @@ class YHImagePickerView: UIView {
titleLabel = {
let label = UILabel()
label.text = "请选择上传方式"
label.font = kFont(size: 17)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textColor = UIColor.mainTextColor
label.textAlignment = .left
return label
}()
......@@ -84,10 +84,10 @@ class YHImagePickerView: UIView {
takePhotoBtton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("拍照上传", for: .normal)
button.setTitleColor( UIColor(hex:0x222222), for: .normal)
button.setTitleColor( UIColor.mainTextColor, for: .normal)
button.addTarget(self, action: #selector(takePhoto), for: .touchUpInside)
return button
}()
......@@ -101,10 +101,10 @@ class YHImagePickerView: UIView {
selectPhotoButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("相册上传", for: .normal)
button.setTitleColor( UIColor(hex:0x222222), for: .normal)
button.setTitleColor( UIColor.mainTextColor, for: .normal)
button.addTarget(self, action: #selector(selectPhoto), for: .touchUpInside)
return button
}()
......@@ -118,7 +118,7 @@ class YHImagePickerView: UIView {
cannalButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("取消", for: .normal)
button.setTitleColor( UIColor(hex:0x909090), for: .normal)
......@@ -135,7 +135,7 @@ class YHImagePickerView: UIView {
for i in 0..<3 {
let view = UIView()
view.backgroundColor = UIColor(hex: 0xf0f0f0)
view.backgroundColor = UIColor.separatorColor
centerView.addSubview(view)
view.snp.makeConstraints { make in
make.left.equalTo(18)
......
......@@ -48,6 +48,8 @@ class YHItemView: UIView {
messageTextField = {
let textField = UITextField()
textField.delegate = self
textField.textColor = UIColor.mainTextColor
textField.font = UIFont.PFSC_M(ofSize: 14)
return textField
}()
addSubview(messageTextField)
......@@ -81,12 +83,12 @@ class YHItemView: UIView {
rightButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
button.setTitleColor(UIColor(hex: 0x4487f9), for: .selected)
button.setTitleColor(UIColor(hex: 0x222222), for: .normal)
button.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
button.setTitleColor(UIColor.brandMainColor, for: .selected)
button.setTitleColor(UIColor.mainTextColor, for: .normal)
button.layer.cornerRadius = 16
button.layer.borderWidth = 1
button.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
button.layer.borderColor = UIColor.brandMainColor.cgColor
button.isSelected = true
button.addTarget(self, action: #selector(rightClick), for: .touchUpInside)
return button
......@@ -101,9 +103,9 @@ class YHItemView: UIView {
leftButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex: 0xf8f9fb)
button.setTitleColor(UIColor(hex: 0x4487f9), for: .selected)
button.setTitleColor(UIColor(hex: 0x222222), for: .normal)
button.backgroundColor = UIColor.contentBkgColor
button.setTitleColor(UIColor.brandMainColor, for: .selected)
button.setTitleColor(UIColor.mainTextColor, for: .normal)
button.layer.cornerRadius = 16
button.addTarget(self, action: #selector(leftClick), for: .touchUpInside)
return button
......@@ -124,7 +126,7 @@ class YHItemView: UIView {
let str = "*" + (dataSource.title ?? "")
let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 14),
.foregroundColor: UIColor(hex:0x222222)
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
let starRange = NSRange(location: 0, length: 1)
......@@ -133,8 +135,8 @@ class YHItemView: UIView {
} else {
let str = dataSource.title ?? ""
let attributes: [NSAttributedString.Key: Any] = [
.font: kFont(size: 14),
.foregroundColor: UIColor(hex:0x222222)
.font: UIFont.PFSC_R(ofSize: 14),
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
titleLabel.attributedText = questionAttrStr
......@@ -193,49 +195,61 @@ class YHItemView: UIView {
leftButton.isSelected = true
rightButton.isSelected = false
leftButton.layer.borderWidth = 1
leftButton.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
leftButton.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor(hex: 0xf8f9fb)
leftButton.layer.borderColor = UIColor.brandMainColor.cgColor
leftButton.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor.contentBkgColor
rightButton.layer.borderWidth = 0
leftButton.titleLabel?.font = UIFont.PFSC_M(ofSize: 13)
rightButton.titleLabel?.font = UIFont.PFSC_R(ofSize: 13)
} else {
rightButton.isSelected = true
leftButton.isSelected = false
rightButton.layer.borderWidth = 1
rightButton.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
rightButton.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor(hex: 0xf8f9fb)
rightButton.layer.borderColor = UIColor.brandMainColor.cgColor
rightButton.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor.contentBkgColor
leftButton.layer.borderWidth = 0
rightButton.titleLabel?.font = UIFont.PFSC_M(ofSize: 13)
leftButton.titleLabel?.font = UIFont.PFSC_R(ofSize: 13)
}
}
@objc func rightClick() {
rightButton.isSelected = true
leftButton.isSelected = false
rightButton.layer.borderWidth = 1
rightButton.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
rightButton.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor(hex: 0xf8f9fb)
rightButton.layer.borderColor = UIColor.brandMainColor.cgColor
rightButton.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor.contentBkgColor
leftButton.layer.borderWidth = 0
dataSource?.message = "0"
dataSource?.value = ["0"]
if let block = block {
block(dataSource ?? YHItemModel())
}
rightButton.titleLabel?.font = UIFont.PFSC_M(ofSize: 13)
leftButton.titleLabel?.font = UIFont.PFSC_R(ofSize: 13)
}
@objc func leftClick() {
leftButton.isSelected = true
rightButton.isSelected = false
leftButton.layer.borderWidth = 1
leftButton.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
leftButton.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor(hex: 0xf8f9fb)
leftButton.layer.borderColor = UIColor.brandMainColor.cgColor
leftButton.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor.contentBkgColor
rightButton.layer.borderWidth = 0
dataSource?.message = "1"
dataSource?.value = ["1"]
if let block = block {
block(dataSource ?? YHItemModel())
}
leftButton.titleLabel?.font = UIFont.PFSC_M(ofSize: 13)
rightButton.titleLabel?.font = UIFont.PFSC_R(ofSize: 13)
}
@objc func centerClick() {
......
......@@ -66,25 +66,28 @@ class YHMainInformationCardTableViewCell: UITableViewCell {
}
func setupUI() {
backgroundColor = UIColor(hex: 0xe9e9e9)
contentView.backgroundColor = .clear
backgroundColor = .clear
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
contentView.addSubview(centerView)
centerView.snp.makeConstraints { make in
make.left.equalTo(16)
make.right.equalTo(-16)
make.top.equalTo(7)
make.bottom.equalTo(-7)
make.bottom.equalTo(-16)
}
titleLabel = {
let label = UILabel()
label.font = kFont(size: 17)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textColor = UIColor.mainTextColor
return label
}()
centerView.addSubview(titleLabel)
......@@ -96,11 +99,11 @@ class YHMainInformationCardTableViewCell: UITableViewCell {
exampleButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x1f93ff).withAlphaComponent(0.12)
button.titleLabel?.font = kBoldFont(size: 10)
button.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 10)
button.contentHorizontalAlignment = .center
button.setTitle("示例模板", for: .normal)
button.setTitleColor( UIColor(hex:0x0085ff), for: .normal)
button.setTitleColor( UIColor.brandMainColor, for: .normal)
button.layer.cornerRadius = 4
button.addTarget(self, action: #selector(exampleClick), for: .touchUpInside)
return button
......@@ -115,7 +118,7 @@ class YHMainInformationCardTableViewCell: UITableViewCell {
let lineView = {
let view = UIView()
view.backgroundColor = UIColor(hex: 0xf0f0f0)
view.backgroundColor = UIColor.separatorColor
return view
}()
centerView.addSubview(lineView)
......@@ -128,8 +131,8 @@ class YHMainInformationCardTableViewCell: UITableViewCell {
frontLabel = {
let label = UILabel()
label.font = kFont(size: 12)
label.textColor = UIColor(hex:0x888f98)
label.font = UIFont.PFSC_R(ofSize: 12)
label.textColor = UIColor.contentBkgColor
label.textAlignment = .center
return label
}()
......@@ -143,8 +146,8 @@ class YHMainInformationCardTableViewCell: UITableViewCell {
backSurfaceLabel = {
let label = UILabel()
label.font = kFont(size: 12)
label.textColor = UIColor(hex:0x888f98)
label.font = UIFont.PFSC_R(ofSize: 12)
label.textColor = UIColor.contentBkgColor
label.textAlignment = .center
return label
}()
......
......@@ -41,11 +41,13 @@ class YHMainInformationTableViewCell: UITableViewCell {
}
func setupUI() {
backgroundColor = UIColor(hex: 0xe9e9e9)
contentView.backgroundColor = .clear
backgroundColor = .clear
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
contentView.addSubview(centerView)
......@@ -58,8 +60,8 @@ class YHMainInformationTableViewCell: UITableViewCell {
titleLabel = {
let label = UILabel()
label.font = kFont(size: 17)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textColor = UIColor.mainTextColor
return label
}()
centerView.addSubview(titleLabel)
......@@ -73,7 +75,7 @@ class YHMainInformationTableViewCell: UITableViewCell {
mainItemView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
centerView.addSubview(mainItemView)
......@@ -88,7 +90,7 @@ class YHMainInformationTableViewCell: UITableViewCell {
mainItemView.removeSubviews()
for i in 0 ..< (dataSource?.models?.count ?? 0) {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
mainItemView.addSubview(line)
line.snp.makeConstraints { make in
make.left.equalTo(18)
......
......@@ -20,7 +20,7 @@ class YHScoreItemCell: UITableViewCell {
private lazy var holdView : UIView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
view.clipsToBounds = true
return view
}()
......
......@@ -126,7 +126,7 @@ class YHOtherPickerView: UIView {
let btn = UIButton()
btn.setTitle("取消".local, for: .normal)
btn.titleLabel?.font = UIFont.PFSC_R(ofSize: 14)
btn.setTitleColor(UIColor(hex: 0x222222), for: .normal)
btn.setTitleColor(UIColor.mainTextColor, for: .normal)
btn.addTarget(self, action: #selector(didClickCancelButton), for: .touchUpInside)
return btn
}()
......
......@@ -137,7 +137,7 @@ extension YHPersonInfoCommonCell {
for (index0,item0) in arrData.enumerated() {
let lable = UILabel()
lable.text = item0.cellTitle
lable.textColor = UIColor(hex: 0x222222)
lable.textColor = UIColor.mainTextColor
lable.font = UIFont.PFSC_M(ofSize: 14)
holdView.addSubview(lable)
lable.snp.makeConstraints { make in
......
......@@ -52,8 +52,8 @@ class YHWorkExampleViewController: YHBaseViewController {
titleLabel = {
let label = UILabel()
label.text = "参考示例"
label.font = kBoldFont(size: 17)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textColor = UIColor.mainTextColor
label.textAlignment = .center
return label
}()
......@@ -67,7 +67,7 @@ class YHWorkExampleViewController: YHBaseViewController {
lineView = {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
return line
}()
view.addSubview(lineView)
......
......@@ -72,7 +72,7 @@ class YHWorkExperienceListViewController: YHBaseViewController {
bottomButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x2274ee)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.contentHorizontalAlignment = .center
button.setTitle("提交", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
......
......@@ -40,8 +40,8 @@ class YHWorkIntroductionViewController: YHBaseViewController {
let array = ["项目名称", "项目时间", "项目业绩/亮点"]
for i in 0..<array.count {
let label = UILabel()
label.textColor = UIColor(hex: 0x222222)
label.font = kFont(size: 14)
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_R(ofSize: 14)
label.text = array[i]
view.addSubview(label)
label.snp.makeConstraints { make in
......@@ -65,7 +65,7 @@ class YHWorkIntroductionViewController: YHBaseViewController {
nameTextField = {
let textField = UITextField()
textField.font = kFont(size: 14)
textField.font = UIFont.PFSC_R(ofSize: 14)
textField.placeholder = "如方便提供,请填写"
return textField
}()
......@@ -79,7 +79,7 @@ class YHWorkIntroductionViewController: YHBaseViewController {
startTextField = {
let textField = UITextField()
textField.font = kFont(size: 14)
textField.font = UIFont.PFSC_R(ofSize: 14)
textField.placeholder = "开始时间"
textField.isEnabled = false
textField.isUserInteractionEnabled = false
......@@ -108,7 +108,7 @@ class YHWorkIntroductionViewController: YHBaseViewController {
endTextField = {
let textField = UITextField()
textField.font = kFont(size: 14)
textField.font = UIFont.PFSC_R(ofSize: 14)
textField.placeholder = "结束时间"
textField.isEnabled = false
textField.isUserInteractionEnabled = false
......@@ -136,7 +136,7 @@ class YHWorkIntroductionViewController: YHBaseViewController {
}
let lineView = UIView()
lineView.backgroundColor = UIColor(hex: 0x222222)
lineView.backgroundColor = UIColor.mainTextColor
view.addSubview(lineView)
lineView.snp.makeConstraints { make in
make.centerY.equalTo(startTextField.snp.centerY)
......@@ -147,8 +147,8 @@ class YHWorkIntroductionViewController: YHBaseViewController {
messageTextField = {
let textField = UITextView()
textField.backgroundColor = UIColor(hex: 0xf8f9fb)
textField.font = kFont(size: 14)
textField.backgroundColor = UIColor.contentBkgColor
textField.font = UIFont.PFSC_R(ofSize: 14)
textField.layer.cornerRadius = 6
textField.delegate = self
return textField
......@@ -163,7 +163,7 @@ class YHWorkIntroductionViewController: YHBaseViewController {
promptsLabel = {
let prompts = UILabel()
prompts.font = kFont(size: 14)
prompts.font = UIFont.PFSC_R(ofSize: 14)
prompts.textColor = UIColor(hex: 0xc0c0c0)
prompts.text = "在职期间负责的核心项目,如果负责过多个项目,请分段描述:\n\n例子:\n\n模式1、本人对XX项目展开深入研究,通过对XX方法/方式,研究出XX。此外,她还指出XX问题,反映了XX。XX的研究成果对XX产生了重要性,为XX领域/方面提供参考依据;\n\n模式2、本人在司参与了XX项目,该项目具有XX突出意义。在此项目中,XX是个难点,本人通过XX方法,实现了XX成果。在XX方面,本人通过XX方式,完成了XX工作。本人凭借在XX领域的丰富经验,推动项目在中国/海外市场取得XX成果。"
prompts.numberOfLines = 0
......@@ -208,7 +208,7 @@ class YHWorkIntroductionViewController: YHBaseViewController {
bottomButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x2274ee)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.contentHorizontalAlignment = .center
button.setTitle("保存", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
......
......@@ -46,7 +46,7 @@ class YHWorkExampleMessageTableViewCell: UITableViewCell {
backgroundColor = .white
centerView = {
let view = UIView()
view.backgroundColor = UIColor(hex: 0xf8f9fb)
view.backgroundColor = UIColor.contentBkgColor
view.layer.cornerRadius = 8
return view
}()
......@@ -60,9 +60,9 @@ class YHWorkExampleMessageTableViewCell: UITableViewCell {
titleLabel = {
let label = UILabel()
label.font = kFont(size: 14)
label.font = UIFont.PFSC_R(ofSize: 14)
label.text = "工作职责范例1"
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
centerView.addSubview(titleLabel)
......@@ -76,7 +76,7 @@ class YHWorkExampleMessageTableViewCell: UITableViewCell {
useButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x2f7ef6).withAlphaComponent(0.08)
button.titleLabel?.font = kBoldFont(size: 12)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 12)
button.contentHorizontalAlignment = .center
button.setTitle("使用此模板", for: .normal)
button.setTitleColor( UIColor(hex:0x2f7ef6), for: .normal)
......@@ -94,7 +94,7 @@ class YHWorkExampleMessageTableViewCell: UITableViewCell {
lineView = {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
return line
}()
centerView.addSubview(lineView)
......@@ -107,8 +107,8 @@ class YHWorkExampleMessageTableViewCell: UITableViewCell {
messageLabel = {
let label = UILabel()
label.numberOfLines = 0
label.font = kFont(size: 14)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_R(ofSize: 14)
label.textColor = UIColor.mainTextColor
return label
}()
centerView.addSubview(messageLabel)
......
......@@ -49,10 +49,10 @@ class YHWorkExampleMessageView: UIView {
titleLabel = {
let label = UILabel()
label.font = kBoldFont(size: 16)
label.font = UIFont.PFSC_M(ofSize: 16)
label.text = "业务支援及人力资源"
label.textAlignment = .left
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
addSubview(titleLabel)
......
......@@ -30,10 +30,10 @@ class YHWorkExampleTypeView: UIView {
func setUpView() {
titleLabel = {
let label = UILabel()
label.font = kBoldFont(size: 14)
label.font = UIFont.PFSC_M(ofSize: 14)
label.text = "请选择您的行业:"
label.textAlignment = .left
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
addSubview(titleLabel)
......@@ -70,8 +70,8 @@ class YHWorkExampleTypeView: UIView {
let button = UIButton(type: .custom)
button.setTitle(dataSource[i], for: .normal)
button.setTitleColor(UIColor(hex: 0x222222), for: .normal)
button.setBackgroundColor(color: UIColor(hex: 0xf8f9fb), forState: .normal)
button.setTitleColor(UIColor.mainTextColor, for: .normal)
button.setBackgroundColor(color: UIColor.contentBkgColor, forState: .normal)
button.titleLabel?.font = UIFont.PFSC_R(ofSize: 13)
button.layer.cornerRadius = 16
button.tag = 3000 + i
......
......@@ -81,12 +81,12 @@ class YHWorkExperienceItemView: UIView {
rightButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
button.setTitleColor(UIColor(hex: 0x4487f9), for: .selected)
button.setTitleColor(UIColor(hex: 0x222222), for: .normal)
button.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
button.setTitleColor(UIColor.brandMainColor, for: .selected)
button.setTitleColor(UIColor.mainTextColor, for: .normal)
button.layer.cornerRadius = 16
button.layer.borderWidth = 1
button.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
button.layer.borderColor = UIColor.brandMainColor.cgColor
button.isSelected = true
button.addTarget(self, action: #selector(rightClick), for: .touchUpInside)
return button
......@@ -101,9 +101,9 @@ class YHWorkExperienceItemView: UIView {
leftButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex: 0xf8f9fb)
button.setTitleColor(UIColor(hex: 0x4487f9), for: .selected)
button.setTitleColor(UIColor(hex: 0x222222), for: .normal)
button.backgroundColor = UIColor.contentBkgColor
button.setTitleColor(UIColor.brandMainColor, for: .selected)
button.setTitleColor(UIColor.mainTextColor, for: .normal)
button.layer.cornerRadius = 16
button.addTarget(self, action: #selector(leftClick), for: .touchUpInside)
return button
......@@ -124,7 +124,7 @@ class YHWorkExperienceItemView: UIView {
let str = "*" + (dataSource.title ?? "")
let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 14),
.foregroundColor: UIColor(hex:0x222222)
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
let starRange = NSRange(location: 0, length: 1)
......@@ -133,8 +133,8 @@ class YHWorkExperienceItemView: UIView {
} else {
let str = dataSource.title ?? ""
let attributes: [NSAttributedString.Key: Any] = [
.font: kFont(size: 14),
.foregroundColor: UIColor(hex:0x222222)
.font: UIFont.PFSC_R(ofSize: 14),
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
titleLabel.attributedText = questionAttrStr
......@@ -193,17 +193,17 @@ class YHWorkExperienceItemView: UIView {
leftButton.isSelected = true
rightButton.isSelected = false
leftButton.layer.borderWidth = 1
leftButton.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
leftButton.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor(hex: 0xf8f9fb)
leftButton.layer.borderColor = UIColor.brandMainColor.cgColor
leftButton.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor.contentBkgColor
rightButton.layer.borderWidth = 0
} else {
rightButton.isSelected = true
leftButton.isSelected = false
rightButton.layer.borderWidth = 1
rightButton.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
rightButton.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor(hex: 0xf8f9fb)
rightButton.layer.borderColor = UIColor.brandMainColor.cgColor
rightButton.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor.contentBkgColor
leftButton.layer.borderWidth = 0
}
}
......@@ -212,9 +212,9 @@ class YHWorkExperienceItemView: UIView {
rightButton.isSelected = true
leftButton.isSelected = false
rightButton.layer.borderWidth = 1
rightButton.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
rightButton.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor(hex: 0xf8f9fb)
rightButton.layer.borderColor = UIColor.brandMainColor.cgColor
rightButton.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor.contentBkgColor
leftButton.layer.borderWidth = 0
dataSource?.message = "0"
dataSource?.value = ["0"]
......@@ -227,9 +227,9 @@ class YHWorkExperienceItemView: UIView {
leftButton.isSelected = true
rightButton.isSelected = false
leftButton.layer.borderWidth = 1
leftButton.layer.borderColor = UIColor(hex: 0x4487f9).cgColor
leftButton.backgroundColor = UIColor(hex: 0x4487f9).withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor(hex: 0xf8f9fb)
leftButton.layer.borderColor = UIColor.brandMainColor.cgColor
leftButton.backgroundColor = UIColor.brandMainColor.withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor.contentBkgColor
rightButton.layer.borderWidth = 0
dataSource?.message = "1"
dataSource?.value = ["1"]
......
......@@ -52,7 +52,7 @@ class YHWorkExperienceListTableViewCell: UITableViewCell {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
contentView.addSubview(centerView)
......@@ -65,9 +65,9 @@ class YHWorkExperienceListTableViewCell: UITableViewCell {
titleLabel = {
let label = UILabel()
label.font = kFont(size: 16)
label.font = UIFont.PFSC_R(ofSize: 16)
label.text = "主申请人工作经历"
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
centerView.addSubview(titleLabel)
......@@ -80,9 +80,9 @@ class YHWorkExperienceListTableViewCell: UITableViewCell {
subTitleLabel = {
let label = UILabel()
label.font = kFont(size: 12)
label.font = UIFont.PFSC_R(ofSize: 12)
label.text = "(从最近一份全职工作开始,直至毕业后的第一份工作)"
label.textColor = UIColor(hex:0x888f98)
label.textColor = UIColor.contentBkgColor
return label
}()
centerView.addSubview(subTitleLabel)
......@@ -95,7 +95,7 @@ class YHWorkExperienceListTableViewCell: UITableViewCell {
cannalButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("取消操作", for: .normal)
button.setTitleColor( UIColor(hex:0x2f7ef6), for: .normal)
......@@ -129,7 +129,7 @@ class YHWorkExperienceListTableViewCell: UITableViewCell {
mainItemView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
centerView.addSubview(mainItemView)
......@@ -155,7 +155,7 @@ class YHWorkExperienceListTableViewCell: UITableViewCell {
mainItemView.removeSubviews()
guard let dataSource = dataSource else {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
mainItemView.addSubview(line)
line.snp.makeConstraints { make in
make.left.equalTo(18)
......@@ -177,7 +177,7 @@ class YHWorkExperienceListTableViewCell: UITableViewCell {
for i in 0 ..< dataSource.count {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
mainItemView.addSubview(line)
line.snp.makeConstraints { make in
make.left.equalTo(18)
......
......@@ -45,7 +45,7 @@ class YHWorkExperienceTableViewCell: UITableViewCell {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
contentView.addSubview(centerView)
......@@ -58,8 +58,8 @@ class YHWorkExperienceTableViewCell: UITableViewCell {
titleLabel = {
let label = UILabel()
label.font = kFont(size: 17)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textColor = UIColor.mainTextColor
return label
}()
centerView.addSubview(titleLabel)
......@@ -73,7 +73,7 @@ class YHWorkExperienceTableViewCell: UITableViewCell {
mainItemView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
centerView.addSubview(mainItemView)
......@@ -89,7 +89,7 @@ class YHWorkExperienceTableViewCell: UITableViewCell {
var y = 0
for i in 0 ..< (dataSource?.models?.count ?? 0) {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
mainItemView.addSubview(line)
line.snp.makeConstraints { make in
make.left.equalTo(18)
......
......@@ -47,7 +47,7 @@ class YHWorkExperienceTextItemView: UIView {
messageTextField = {
let textField = UITextView()
textField.backgroundColor = UIColor(hex: 0xf8f9fb)
textField.backgroundColor = UIColor.contentBkgColor
textField.layer.cornerRadius = 4
textField.delegate = self
return textField
......@@ -61,7 +61,7 @@ class YHWorkExperienceTextItemView: UIView {
promptsLabel = {
let textField = UILabel()
textField.font = kFont(size: 14)
textField.font = UIFont.PFSC_R(ofSize: 14)
textField.textColor = UIColor(hex: 0xc0c0c0)
return textField
}()
......@@ -91,7 +91,7 @@ class YHWorkExperienceTextItemView: UIView {
let str = "*" + (dataSource.title ?? "")
let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 14),
.foregroundColor: UIColor(hex:0x222222)
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
let starRange = NSRange(location: 0, length: 1)
......@@ -100,8 +100,8 @@ class YHWorkExperienceTextItemView: UIView {
} else {
let str = dataSource.title ?? ""
let attributes: [NSAttributedString.Key: Any] = [
.font: kFont(size: 14),
.foregroundColor: UIColor(hex:0x222222)
.font: UIFont.PFSC_R(ofSize: 14),
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
titleLabel.attributedText = questionAttrStr
......
......@@ -32,9 +32,9 @@ class YHWorkFileItemView: UIView {
func setUpView() {
titleLabel = {
let label = UILabel()
label.font = kBoldFont(size: 14)
label.font = UIFont.PFSC_M(ofSize: 14)
label.textAlignment = .left
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
addSubview(titleLabel)
......@@ -47,7 +47,7 @@ class YHWorkFileItemView: UIView {
deleteButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_R(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("删除", for: .normal)
button.setTitleColor( UIColor(hex:0xf81d22), for: .normal)
......
......@@ -49,7 +49,7 @@ class YHWorkFileSyncTableViewCell: UITableViewCell {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
contentView.addSubview(centerView)
......@@ -65,7 +65,7 @@ class YHWorkFileSyncTableViewCell: UITableViewCell {
let str = "*" + "上传文件"
let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 17),
.foregroundColor: UIColor(hex:0x222222)
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
let starRange = NSRange(location: 0, length: 1)
......@@ -84,7 +84,7 @@ class YHWorkFileSyncTableViewCell: UITableViewCell {
mainItemView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
centerView.addSubview(mainItemView)
......@@ -117,7 +117,7 @@ class YHWorkFileSyncTableViewCell: UITableViewCell {
mainItemView.removeSubviews()
for i in 0 ..< (dataSource?.count ?? 0) {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
mainItemView.addSubview(line)
line.snp.makeConstraints { make in
make.left.equalTo(18)
......
......@@ -64,7 +64,7 @@ class YHWorkHighlightsTableViewCell: UITableViewCell {
let str = "*" + "工作亮点"
let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 17),
.foregroundColor: UIColor(hex:0x222222)
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
let starRange = NSRange(location: 0, length: 1)
......@@ -84,7 +84,7 @@ class YHWorkHighlightsTableViewCell: UITableViewCell {
let label = UILabel()
label.text = "温馨提示:如下模板仅供思路参考,工作内容请按您的实际填写,后期文案会基于该内容进行文书材料撰写,望悉知"
label.textColor = UIColor(hex: 0x2f7ef6)
label.font = kFont(size: 12)
label.font = UIFont.PFSC_R(ofSize: 12)
label.numberOfLines = 0
return label
}()
......@@ -98,7 +98,7 @@ class YHWorkHighlightsTableViewCell: UITableViewCell {
lineView = {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
return line
}()
centerView.addSubview(lineView)
......@@ -111,7 +111,7 @@ class YHWorkHighlightsTableViewCell: UITableViewCell {
messageTextField = {
let textField = UITextView()
textField.font = kFont(size: 14)
textField.font = UIFont.PFSC_R(ofSize: 14)
textField.delegate = self
return textField
}()
......@@ -125,7 +125,7 @@ class YHWorkHighlightsTableViewCell: UITableViewCell {
promptsLabel = {
let prompts = UILabel()
prompts.font = kFont(size: 14)
prompts.font = UIFont.PFSC_R(ofSize: 14)
prompts.textColor = UIColor(hex: 0xc0c0c0)
prompts.text = "示例:打破常规,超越同行或其他同事的优秀业绩;或有开创性且突破公司期望的杰出贡献,且给公司带来价值和收益。\n\n请举例2-3个工作亮点:\n\na. 是什么:某项目背景或工作目标或难点\nb.为什么:为什么出现这个项目工作/难点,旨在体现分析过程,为您后面提出解决方案做铺垫\nc.怎么处理:您是怎么把这件事做好的?用了什么技术/方法?有何突出/创新之处?\nd.有什么价值:为公司、客户或您本身带来了哪些价值?客户或您本身带来了哪些价值?\n最好用实际数据证明,比如销售业绩增加了多少,或者利润增加了多少,客户群体增加了多少等。"
prompts.numberOfLines = 0
......@@ -141,8 +141,8 @@ class YHWorkHighlightsTableViewCell: UITableViewCell {
detailLabel = {
let label = UILabel()
label.text = "项目详细介绍"
label.textColor = UIColor(hex: 0x222222)
label.font = kFont(size: 14)
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_R(ofSize: 14)
return label
}()
centerView.addSubview(detailLabel)
......
......@@ -35,9 +35,9 @@ class YHWorkIntroductionItemView: UIView {
func setUpView() {
titleLabel = {
let label = UILabel()
label.font = kBoldFont(size: 14)
label.font = UIFont.PFSC_M(ofSize: 14)
label.textAlignment = .left
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
addSubview(titleLabel)
......@@ -50,9 +50,9 @@ class YHWorkIntroductionItemView: UIView {
subTitleLabel = {
let label = UILabel()
label.font = kBoldFont(size: 12)
label.font = UIFont.PFSC_M(ofSize: 12)
label.textAlignment = .left
label.textColor = UIColor(hex:0x888f98)
label.textColor = UIColor.contentBkgColor
return label
}()
addSubview(subTitleLabel)
......@@ -87,7 +87,7 @@ class YHWorkIntroductionItemView: UIView {
deleteButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_R(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("删除", for: .normal)
button.setTitleColor( UIColor(hex:0xf81d22), for: .normal)
......
......@@ -51,7 +51,7 @@ class YHWorkIntroductionTableViewCell: UITableViewCell {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
contentView.addSubview(centerView)
......@@ -64,9 +64,9 @@ class YHWorkIntroductionTableViewCell: UITableViewCell {
titleLabel = {
let label = UILabel()
label.font = kFont(size: 16)
label.font = UIFont.PFSC_R(ofSize: 16)
label.text = "项目介绍(选填)"
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
centerView.addSubview(titleLabel)
......@@ -79,7 +79,7 @@ class YHWorkIntroductionTableViewCell: UITableViewCell {
cannalButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("取消操作", for: .normal)
button.setTitleColor( UIColor(hex:0x2f7ef6), for: .normal)
......@@ -113,7 +113,7 @@ class YHWorkIntroductionTableViewCell: UITableViewCell {
mainItemView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
centerView.addSubview(mainItemView)
......@@ -146,7 +146,7 @@ class YHWorkIntroductionTableViewCell: UITableViewCell {
mainItemView.removeSubviews()
for i in 0 ..< (dataSource?.count ?? 0) {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
mainItemView.addSubview(line)
line.snp.makeConstraints { make in
make.left.equalTo(18)
......
......@@ -38,9 +38,9 @@ class YHWorkItemView: UIView {
func setUpView() {
titleLabel = {
let label = UILabel()
label.font = kBoldFont(size: 14)
label.font = UIFont.PFSC_M(ofSize: 14)
label.textAlignment = .left
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
addSubview(titleLabel)
......@@ -53,9 +53,9 @@ class YHWorkItemView: UIView {
subTitleLabel = {
let label = UILabel()
label.font = kBoldFont(size: 12)
label.font = UIFont.PFSC_M(ofSize: 12)
label.textAlignment = .left
label.textColor = UIColor(hex:0x888f98)
label.textColor = UIColor.contentBkgColor
return label
}()
addSubview(subTitleLabel)
......@@ -67,9 +67,9 @@ class YHWorkItemView: UIView {
explainLabel = {
let label = UILabel()
label.font = kBoldFont(size: 14)
label.font = UIFont.PFSC_M(ofSize: 14)
label.textAlignment = .right
label.textColor = UIColor(hex:0x888f98)
label.textColor = UIColor.contentBkgColor
return label
}()
addSubview(explainLabel)
......@@ -105,7 +105,7 @@ class YHWorkItemView: UIView {
deleteButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kFont(size: 14)
button.titleLabel?.font = UIFont.PFSC_R(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("删除", for: .normal)
button.contentHorizontalAlignment = .right
......
......@@ -42,7 +42,7 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
contentView.addSubview(centerView)
......@@ -55,9 +55,9 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
titleLabel = {
let label = UILabel()
label.font = kFont(size: 17)
label.font = UIFont.PFSC_M(ofSize: 17)
label.text = "信息选择"
label.textColor = UIColor(hex:0x222222)
label.textColor = UIColor.mainTextColor
return label
}()
centerView.addSubview(titleLabel)
......@@ -70,7 +70,7 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
lineView = {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
return line
}()
centerView.addSubview(lineView)
......@@ -107,7 +107,7 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex: 0x2f7ef6).withAlphaComponent(0.08)
button.setTitleColor(UIColor(hex: 0x2f7ef6), for: .selected)
button.setTitleColor(UIColor(hex: 0x222222), for: .normal)
button.setTitleColor(UIColor.mainTextColor, for: .normal)
button.setTitle("是", for: .normal)
button.titleLabel?.font = UIFont.PFSC_R(ofSize: 13)
button.layer.cornerRadius = 16
......@@ -127,9 +127,9 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
leftButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex: 0xf8f9fb)
button.backgroundColor = UIColor.contentBkgColor
button.setTitleColor(UIColor(hex: 0x2f7ef6), for: .selected)
button.setTitleColor(UIColor(hex: 0x222222), for: .normal)
button.setTitleColor(UIColor.mainTextColor, for: .normal)
button.setTitle("否", for: .normal)
button.titleLabel?.font = UIFont.PFSC_R(ofSize: 13)
button.layer.cornerRadius = 16
......@@ -152,7 +152,7 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
leftButton.layer.borderWidth = 1
leftButton.layer.borderColor = UIColor(hex: 0x2f7ef6).cgColor
leftButton.backgroundColor = UIColor(hex: 0x2f7ef6).withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor(hex: 0xf8f9fb)
rightButton.backgroundColor = UIColor.contentBkgColor
rightButton.layer.borderWidth = 0
} else {
rightButton.isSelected = true
......@@ -160,7 +160,7 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
rightButton.layer.borderWidth = 1
rightButton.layer.borderColor = UIColor(hex: 0x2f7ef6).cgColor
rightButton.backgroundColor = UIColor(hex: 0x2f7ef6).withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor(hex: 0xf8f9fb)
leftButton.backgroundColor = UIColor.contentBkgColor
leftButton.layer.borderWidth = 0
}
}
......@@ -171,7 +171,7 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
rightButton.layer.borderWidth = 1
rightButton.layer.borderColor = UIColor(hex: 0x2f7ef6).cgColor
rightButton.backgroundColor = UIColor(hex: 0x2f7ef6).withAlphaComponent(0.08)
leftButton.backgroundColor = UIColor(hex: 0xf8f9fb)
leftButton.backgroundColor = UIColor.contentBkgColor
leftButton.layer.borderWidth = 0
}
......@@ -181,7 +181,7 @@ class YHWorkMessageSelectTableViewCell: UITableViewCell {
leftButton.layer.borderWidth = 1
leftButton.layer.borderColor = UIColor(hex: 0x2f7ef6).cgColor
leftButton.backgroundColor = UIColor(hex: 0x2f7ef6).withAlphaComponent(0.08)
rightButton.backgroundColor = UIColor(hex: 0xf8f9fb)
rightButton.backgroundColor = UIColor.contentBkgColor
rightButton.layer.borderWidth = 0
}
......
......@@ -62,7 +62,7 @@ class YHWorkResponsibilitiesTableViewCell: UITableViewCell {
let str = "*" + "工作职责"
let attributes: [NSAttributedString.Key: Any] = [
.font: UIFont.PFSC_R(ofSize: 17),
.foregroundColor: UIColor(hex:0x222222)
.foregroundColor: UIColor.mainTextColor
]
let questionAttrStr = NSMutableAttributedString(string: str, attributes: attributes)
let starRange = NSRange(location: 0, length: 1)
......@@ -82,7 +82,7 @@ class YHWorkResponsibilitiesTableViewCell: UITableViewCell {
let label = UILabel()
label.text = "温馨提示:如下模板仅供思路参考,工作内容请按您的实际填写,后期文案会基于该内容进行文书材料撰写,望悉知"
label.textColor = UIColor(hex: 0x2f7ef6)
label.font = kFont(size: 12)
label.font = UIFont.PFSC_R(ofSize: 12)
label.numberOfLines = 0
return label
}()
......@@ -96,7 +96,7 @@ class YHWorkResponsibilitiesTableViewCell: UITableViewCell {
lineView = {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xf0f0f0)
line.backgroundColor = UIColor.separatorColor
return line
}()
centerView.addSubview(lineView)
......@@ -109,7 +109,7 @@ class YHWorkResponsibilitiesTableViewCell: UITableViewCell {
messageTextField = {
let textField = UITextView()
textField.font = kFont(size: 14)
textField.font = UIFont.PFSC_R(ofSize: 14)
textField.delegate = self
return textField
}()
......@@ -123,7 +123,7 @@ class YHWorkResponsibilitiesTableViewCell: UITableViewCell {
promptsLabel = {
let prompts = UILabel()
prompts.font = kFont(size: 14)
prompts.font = UIFont.PFSC_R(ofSize: 14)
prompts.textColor = UIColor(hex: 0xc0c0c0)
prompts.text = "示例:在职期间负责的核心工作职责,建议不要超过3点。如果就职过多个职位,请分段描述:\n\n例子:\n\n模式1、在司担任某某岗位,任职期间,主要负责xxxx工作;在此期间,组建了xxx。实现了xxx;\n\n模式2、在担任xxx岗位期间,主要负责xxxx工作,具体的工作职责包括如下:\n\n2.1)xxxxxxxx;\n2.2)xxxxxxxx;\n2.3)xxxxxxxx;"
prompts.numberOfLines = 0
......
......@@ -44,7 +44,7 @@ class YHSubmitAllInfoCheckView: UIView {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
addSubview(centerView)
......@@ -57,8 +57,8 @@ class YHSubmitAllInfoCheckView: UIView {
// titleLabel = {
// let label = UILabel()
// label.text = "同意隐私协议"
// label.font = kFont(size: 16)
// label.textColor = UIColor(hex:0x222222)
// label.font = UIFont.PFSC_R(ofSize: 16)
// label.textColor = UIColor.mainTextColor
// label.textAlignment = .center
// return label
// }()
......
......@@ -39,7 +39,7 @@ class YHCodeResultViewController: YHBaseViewController {
loginTitleLabel = {
let label = UILabel()
label.text = "登录后更精彩"
label.font = kBoldFont(size: 32)
label.font = UIFont.PFSC_M(ofSize: 32)
label.textColor = UIColor(hex:0xffffff)
return label
}()
......@@ -53,7 +53,7 @@ class YHCodeResultViewController: YHBaseViewController {
loginSubTitleLabel = {
let label = UILabel()
label.text = "香港美好生活期待与你的相遇"
label.font = kFont(size: 20)
label.font = UIFont.PFSC_R(ofSize: 20)
label.textColor = UIColor(hex:0xffffff)
return label
}()
......@@ -67,7 +67,7 @@ class YHCodeResultViewController: YHBaseViewController {
phoneLabel = {
let label = UILabel()
label.text = "已发送验证码至13352933800"
label.font = kBoldFont(size: 17)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textAlignment = .left
label.textColor = UIColor(hex:0xffffff)
return label
......@@ -96,7 +96,7 @@ class YHCodeResultViewController: YHBaseViewController {
getCodeLabel = {
let button = UILabel()
button.font = kBoldFont(size: 16)
button.font = UIFont.PFSC_M(ofSize: 16)
button.text = "重新发送(58s)"
button.textColor = UIColor(hex:0xffffff)
button.isHidden = false
......@@ -112,7 +112,7 @@ class YHCodeResultViewController: YHBaseViewController {
getCodeButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.contentHorizontalAlignment = .left
button.setTitle("重新获取验证码", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
......
......@@ -63,8 +63,8 @@ class YHCodeSueecssViewController: YHBaseViewController {
loginTitleLabel = {
let label = UILabel()
label.text = "请输入验证码"
label.font = kBoldFont(size: 28)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 28)
label.textColor = UIColor.mainTextColor
return label
}()
view.addSubview(loginTitleLabel)
......@@ -79,7 +79,7 @@ class YHCodeSueecssViewController: YHBaseViewController {
let label = UILabel()
label.text = "已发送至 \(phoneNumber ?? "")"
label.font = UIFont.PFSC_R(ofSize: 13)
label.textColor = UIColor(hex:0xc0c0c0)
label.textColor = UIColor.placeHolderColor
return label
}()
view.addSubview(loginSubTitleLabel)
......@@ -113,9 +113,9 @@ class YHCodeSueecssViewController: YHBaseViewController {
getCodeLabel = {
let button = UILabel()
button.font = kBoldFont(size: 12)
button.font = UIFont.PFSC_M(ofSize: 12)
button.text = "重新发送(58s)"
button.textColor = UIColor(hex:0xc0c0c0)
button.textColor = UIColor.placeHolderColor
button.textAlignment = .center
button.isHidden = false
button.layer.cornerRadius = 4
......@@ -133,10 +133,10 @@ class YHCodeSueecssViewController: YHBaseViewController {
getCodeButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 12)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 12)
button.contentHorizontalAlignment = .center
button.setTitle("获取验证码", for: .normal)
button.setTitleColor( UIColor(hex:0x222222), for: .normal)
button.setTitleColor( UIColor.mainTextColor, for: .normal)
button.addTarget(self, action: #selector(startClicked), for: .touchUpInside)
button.isHidden = true
button.layer.cornerRadius = 4
......
......@@ -55,7 +55,7 @@ class YHLoginViewController: YHBaseViewController {
loginTitleLabel = {
let label = UILabel()
label.text = "登录后更精彩"
label.font = kBoldFont(size: 32)
label.font = UIFont.PFSC_M(ofSize: 32)
label.textColor = UIColor(hex:0xffffff)
return label
}()
......@@ -69,7 +69,7 @@ class YHLoginViewController: YHBaseViewController {
loginSubTitleLabel = {
let label = UILabel()
label.text = "香港美好生活期待与你的相遇"
label.font = kFont(size: 20)
label.font = UIFont.PFSC_R(ofSize: 20)
label.textColor = UIColor(hex:0xffffff)
return label
}()
......@@ -83,7 +83,7 @@ class YHLoginViewController: YHBaseViewController {
loginPhoneLabel = {
let label = UILabel()
label.text = "+86 133****3800"
label.font = kBoldFont(size: 20)
label.font = UIFont.PFSC_M(ofSize: 20)
label.textAlignment = .center
label.textColor = UIColor(hex:0xffffff)
return label
......@@ -98,7 +98,7 @@ class YHLoginViewController: YHBaseViewController {
loginButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x4d9ff8)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.contentHorizontalAlignment = .center
button.setTitle("本机号码一键登录", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
......@@ -165,7 +165,7 @@ class YHLoginViewController: YHBaseViewController {
promptsLabel = {
let label = UILabel()
label.text = "其他登录方式(第三方账号注册需绑定手机号)"
label.font = kFont(size: 12)
label.font = UIFont.PFSC_R(ofSize: 12)
label.textColor = UIColor(hex:0xffffff)
label.textAlignment = .center
return label
......
......@@ -81,8 +81,8 @@ class YHPhoneLoginViewController: YHBaseViewController {
loginTitleLabel = {
let label = UILabel()
label.text = "手机号登录"
label.font = kBoldFont(size: 28)
label.textColor = UIColor(hex:0x222222)
label.font = UIFont.PFSC_M(ofSize: 28)
label.textColor = UIColor.mainTextColor
return label
}()
view.addSubview(loginTitleLabel)
......@@ -97,7 +97,7 @@ class YHPhoneLoginViewController: YHBaseViewController {
let label = UILabel()
label.text = "手机号首次登录自动注册"
label.font = UIFont.PFSC_R(ofSize: 13)
label.textColor = UIColor(hex:0xc0c0c0)
label.textColor = UIColor.placeHolderColor
return label
}()
view.addSubview(loginSubTitleLabel)
......@@ -110,8 +110,8 @@ class YHPhoneLoginViewController: YHBaseViewController {
phoneMessageView = {
let view = YHPhoneMessageView()
view.backgroundColor = UIColor(hex:0xf8f9fb)
view.layer.cornerRadius = 6
view.backgroundColor = UIColor.contentBkgColor
view.layer.cornerRadius = kCornerRadius6
view.layer.borderWidth = 1
view.layer.borderColor = UIColor(hex:0xebeef4).cgColor
view.phoneBlock = {[weak self] count in
......@@ -137,7 +137,7 @@ class YHPhoneLoginViewController: YHBaseViewController {
getCodeButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x2274ee).withAlphaComponent(0.4)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.contentHorizontalAlignment = .center
button.setTitle("获取验证码", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
......
......@@ -33,7 +33,7 @@ class YHPickPhoneAddressViewController: YHBaseViewController {
// loginTitleLabel = {
// let label = UILabel()
// label.text = "登录后更精彩"
// label.font = kBoldFont(size: 32)
// label.font = UIFont.PFSC_M(ofSize: 32)
// label.textColor = UIColor(hex:0xffffff)
// return label
// }()
......
......@@ -42,7 +42,7 @@ class YHVerificationCodeLoginController: YHBaseViewController {
loginTitleLabel = {
let label = UILabel()
label.text = "登录后更精彩"
label.font = kBoldFont(size: 32)
label.font = UIFont.PFSC_M(ofSize: 32)
label.textColor = UIColor(hex:0xffffff)
return label
}()
......@@ -56,7 +56,7 @@ class YHVerificationCodeLoginController: YHBaseViewController {
loginSubTitleLabel = {
let label = UILabel()
label.text = "香港美好生活期待与你的相遇"
label.font = kFont(size: 20)
label.font = UIFont.PFSC_R(ofSize: 20)
label.textColor = UIColor(hex:0xffffff)
return label
}()
......@@ -70,7 +70,7 @@ class YHVerificationCodeLoginController: YHBaseViewController {
phoneLabel = {
let label = UILabel()
label.text = "未注册手机验证后完成注册"
label.font = kBoldFont(size: 17)
label.font = UIFont.PFSC_M(ofSize: 17)
label.textAlignment = .left
label.textColor = UIColor(hex:0xffffff)
return label
......@@ -105,7 +105,7 @@ class YHVerificationCodeLoginController: YHBaseViewController {
getCodeButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0xd8d8d8).withAlphaComponent(0.8)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.contentHorizontalAlignment = .center
button.setTitle("获取验证码", for: .normal)
button.setTitleColor( UIColor(hex:0x979797), for: .normal)
......@@ -122,7 +122,7 @@ class YHVerificationCodeLoginController: YHBaseViewController {
}
emailButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.setTitle("邮箱登录", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
return button
......@@ -150,7 +150,7 @@ class YHVerificationCodeLoginController: YHBaseViewController {
promptsLabel = {
let label = UILabel()
label.text = "其他登录方式(第三方账号注册需绑定手机号)"
label.font = kFont(size: 12)
label.font = UIFont.PFSC_R(ofSize: 12)
label.textColor = UIColor(hex:0xffffff)
label.textAlignment = .center
return label
......
......@@ -44,8 +44,8 @@ class YHLoginPrivacyView: UIView {
messageLabel = {
let label = UILabel()
label.text = "我已阅读并同意"
label.font = kFont(size: 12)
label.textColor = UIColor(hex:0x888f98)
label.font = UIFont.PFSC_R(ofSize: 12)
label.textColor = UIColor.contentBkgColor
label.textAlignment = .left
return label
}()
......@@ -58,7 +58,7 @@ class YHLoginPrivacyView: UIView {
serviceButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 12)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 12)
button.contentHorizontalAlignment = .center
button.setTitle("《隐私协议》", for: .normal)
button.setTitleColor(UIColor(hex: 0x2f7ef6), for: .normal)
......@@ -74,8 +74,8 @@ class YHLoginPrivacyView: UIView {
andLabel = {
let label = UILabel()
label.text = "和"
label.font = kFont(size: 12)
label.textColor = UIColor(hex:0x888f98)
label.font = UIFont.PFSC_R(ofSize: 12)
label.textColor = UIColor.contentBkgColor
label.textAlignment = .left
return label
}()
......@@ -87,7 +87,7 @@ class YHLoginPrivacyView: UIView {
}
privacyButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 12)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 12)
button.contentHorizontalAlignment = .center
button.setTitle("《用户条款》", for: .normal)
button.setTitleColor(UIColor(hex: 0x2f7ef6), for: .normal)
......
......@@ -32,7 +32,7 @@ class YHLoginStyleButton: UIButton {
messageLabel = {
let label = UILabel()
label.font = kBoldFont(size: 16)
label.font = UIFont.PFSC_M(ofSize: 16)
label.textColor = UIColor(hex:0xffffff)
label.textAlignment = .right
return label
......
......@@ -28,7 +28,7 @@ class YHPhoneMessageView: UIView {
func setView() {
messageButton = {
let button = UIButton(type: .custom)
button.titleLabel?.font = kBoldFont(size: 16)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 16)
button.setTitle("+86", for: .normal)
button.setTitleColor( UIColor(hex:0x000000), for: .normal)
button.addTarget(self, action: #selector(messageClick), for: .touchUpInside)
......@@ -56,7 +56,7 @@ class YHPhoneMessageView: UIView {
phoneTextField = {
let text = UITextField()
text.placeholder = "请输入签约手机号"
text.font = kFont(size: 16)
text.font = UIFont.PFSC_R(ofSize: 16)
text.textColor = UIColor(hex:0x000000)
text.textAlignment = .left
text.keyboardType = .phonePad
......
......@@ -38,7 +38,7 @@ class YHPrivacyAlertView: UIView {
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = 12
view.layer.cornerRadius = kCornerRadius6
return view
}()
addSubview(centerView)
......@@ -81,11 +81,11 @@ class YHPrivacyAlertView: UIView {
disAgressButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0xffffff)
button.titleLabel?.font = kBoldFont(size: 15)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.contentHorizontalAlignment = .center
button.setTitle("不同意", for: .normal)
button.setTitleColor( UIColor(hex:0x3c86f8), for: .normal)
button.layer.cornerRadius = 8
button.layer.cornerRadius = kCornerRadius6
button.layer.borderWidth = 1
button.layer.borderColor = UIColor(hex: 0x3c86f8).cgColor
button.addTarget(self, action: #selector(disagree), for: .touchUpInside)
......@@ -102,11 +102,11 @@ class YHPrivacyAlertView: UIView {
agreeButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0x3c86f8)
button.titleLabel?.font = kBoldFont(size: 15)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.contentHorizontalAlignment = .center
button.setTitle("同意", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
button.layer.cornerRadius = 8
button.layer.cornerRadius = kCornerRadius6
button.addTarget(self, action: #selector(agree), for: .touchUpInside)
return button
}()
......
......@@ -114,25 +114,6 @@ func kIsEmpty(string: String) -> Bool {
}
}
/** 文字大小设置
* parameter name 字体名字 (为空时默认字体)
* parameter size 字体大小
*/
func kFont(name: String = "", size: CGFloat) -> UIFont {
if !kIsEmpty(string: name) {
return UIFont.init(name: name, size: size)!
}else {
return UIFont.systemFont(ofSize: size)
}
}
func kBoldFont(name: String = "", size: CGFloat) -> UIFont {
if !kIsEmpty(string: name) {
return UIFont.init(name: name, size: size)!
}else {
return UIFont.boldSystemFont(ofSize: size)
}
}
/// 版本号相同:
func systemVersionEqual(version:String) -> Bool {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment