Commit 0735a8d2 authored by pete谢兆麟's avatar pete谢兆麟

Merge branch 'youhua-dev' of http://gitlab.galaxy-immi.com/mobile-group/galaxy-iOS into youhua-dev

parents 3ad19e16 84e0788d
......@@ -17,7 +17,7 @@ platform :ios do
youhua_branch = "youhua-dev"
#打包正使用的分支
myPack_branch = "main"
myPack_branch = "youhua-dev"
# 打adhoc包 执行命令 fastlane galaxyTest
lane :galaxyTest do
......
......@@ -409,8 +409,6 @@
A5C382CC2B5EA11800C5E65C /* YHContractCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5C382CB2B5EA11800C5E65C /* YHContractCell.swift */; };
A5C382CF2B5F9A9100C5E65C /* YHServiceCenterMainViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5C382CE2B5F9A9100C5E65C /* YHServiceCenterMainViewModel.swift */; };
A5C382D12B5FAAB300C5E65C /* YHContactItemModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5C382D02B5FAAB300C5E65C /* YHContactItemModel.swift */; };
A5C468572BFB1DAB0015E726 /* YHCommonAlertView2.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5C468562BFB1DAB0015E726 /* YHCommonAlertView2.swift */; };
A5C468592BFB37380015E726 /* YHCommonAlertView3.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5C468582BFB37380015E726 /* YHCommonAlertView3.swift */; };
A5C5B2EE2B4F9B8800A7C5D1 /* Localizable.xcstrings in Resources */ = {isa = PBXBuildFile; fileRef = A5C5B2ED2B4F9B8800A7C5D1 /* Localizable.xcstrings */; };
A5D001212BAA9D99001F003C /* YHChoiceButtonHoldView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5D001202BAA9D99001F003C /* YHChoiceButtonHoldView.swift */; };
A5D0012A2BABC84A001F003C /* YHFileListHeaerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5D001272BABC84A001F003C /* YHFileListHeaerView.swift */; };
......@@ -881,8 +879,6 @@
A5C382CB2B5EA11800C5E65C /* YHContractCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHContractCell.swift; sourceTree = "<group>"; };
A5C382CE2B5F9A9100C5E65C /* YHServiceCenterMainViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHServiceCenterMainViewModel.swift; sourceTree = "<group>"; };
A5C382D02B5FAAB300C5E65C /* YHContactItemModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHContactItemModel.swift; sourceTree = "<group>"; };
A5C468562BFB1DAB0015E726 /* YHCommonAlertView2.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCommonAlertView2.swift; sourceTree = "<group>"; };
A5C468582BFB37380015E726 /* YHCommonAlertView3.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCommonAlertView3.swift; sourceTree = "<group>"; };
A5C5B2ED2B4F9B8800A7C5D1 /* Localizable.xcstrings */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json.xcstrings; path = Localizable.xcstrings; sourceTree = "<group>"; };
A5D001202BAA9D99001F003C /* YHChoiceButtonHoldView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHChoiceButtonHoldView.swift; sourceTree = "<group>"; };
A5D001272BABC84A001F003C /* YHFileListHeaerView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = YHFileListHeaerView.swift; sourceTree = "<group>"; };
......@@ -1414,8 +1410,6 @@
0435FA802BA186D600024EAE /* YHMyFileMethodTableViewCell.swift */,
044CF8D32BB6BCF700008CE8 /* YHSignatureUploadTableViewCell.swift */,
0435FA7E2BA178C100024EAE /* YHCommonAlertView.swift */,
A5C468562BFB1DAB0015E726 /* YHCommonAlertView2.swift */,
A5C468582BFB37380015E726 /* YHCommonAlertView3.swift */,
);
path = V;
sourceTree = "<group>";
......@@ -2836,7 +2830,6 @@
045EEE932B9F171A0022A143 /* YHPreviewInfoSingleLineTitleView.swift in Sources */,
045EEF1D2B9F171A0022A143 /* YHAddressPickView.swift in Sources */,
A58AC0A12BAC0B2900A30FA9 /* YHFileListItemView.swift in Sources */,
A5C468572BFB1DAB0015E726 /* YHCommonAlertView2.swift in Sources */,
045EEED12B9F171A0022A143 /* YHScorePersonInfoCell.swift in Sources */,
044CF8D42BB6BCF700008CE8 /* YHSignatureUploadTableViewCell.swift in Sources */,
A567E5B02BD7643D00D5D5A0 /* YHHomeWebBottomView.swift in Sources */,
......@@ -2971,7 +2964,6 @@
A5ACE9302B4564F7002C94D2 /* Algorithm.swift in Sources */,
045EEED52B9F171A0022A143 /* YHEducationRequestViewModel.swift in Sources */,
045EEEB62B9F171A0022A143 /* YHWorkExperienceItemView.swift in Sources */,
A5C468592BFB37380015E726 /* YHCommonAlertView3.swift in Sources */,
A58A8C942BA6C7C600632765 /* YHCertificateEntryModel.swift in Sources */,
045EEEB82B9F171A0022A143 /* YHWorkExampleMessageView.swift in Sources */,
04F4B76B2BAA7E1E00D13284 /* YHCertificateTemplateSheetView.swift in Sources */,
......@@ -3102,7 +3094,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxyTestEnv.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
FRAMEWORK_SEARCH_PATHS = (
......@@ -3305,7 +3297,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxyDebug.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
FRAMEWORK_SEARCH_PATHS = (
......@@ -3350,7 +3342,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxy.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
FRAMEWORK_SEARCH_PATHS = (
......
......@@ -112,7 +112,7 @@ extension YHTabBarViewController {
//展示tabbar上的横线
func handleTabBarLine() -> Void {
let rect = CGRect.init(x:0,y:0,width:KScreenWidth,height:0.5)
let fillColor = UIColor(hex:0x121A26,transparency: 0.05)!
let fillColor = UIColor.mainTextColor5
let img = UIImage.from(color: fillColor, rect: rect)
UIView.transition(with:self.tabBar, duration:0.5, options: .transitionCrossDissolve) {
......
......@@ -17,8 +17,8 @@ class YHBasicContentView: ESTabBarItemContentView {
// 此渲染模式会影响图片颜色哦
renderingMode = .alwaysOriginal
textColor = UIColor(hex: 0x121A26)
highlightTextColor = UIColor(hex: 0x121A26)
textColor = UIColor.mainTextColor
highlightTextColor = UIColor.mainTextColor
titleLabel.font = UIFont.PFSC_R(ofSize: 14)
}
......
......@@ -55,7 +55,7 @@ class YHEmptyDataView: UIView {
var tipsLabel: UILabel = {
let label = UILabel()
label.textColor = UIColor.init(hex: 0x121A26, alpha: 0.5)
label.textColor = UIColor.mainTextColor50
label.font = UIFont.PFSC_R(ofSize: 14)
label.textAlignment = .center
label.text = "暂无内容".local
......
......@@ -156,7 +156,7 @@ private extension YHHomePageViewController {
homeCollectView.contentInset = UIEdgeInsets(top: YHHomeHeadView.viewH, left: 0, bottom: 0, right: 0)
let tmpHeadView = homeCollectView.es.addYHPullToRefresh {
self.loadFirstData()
self.getData()
}
var r = tmpHeadView.frame
......
......@@ -10,12 +10,23 @@ import Foundation
import FSPagerView
import Kingfisher
let bannerSildingInterval = 3.0
class YHHomeBannerView: UIView {
static let viewH : CGFloat = KScreenWidth - 20.0 * 2
var dataArr: [YHBannerModel] = [] {
didSet {
// 设置为0是先停掉自动滑动定时器
bannerView.automaticSlidingInterval = 0
self.indicatorView.indicatorItems = self.dataArr.count
bannerView.reloadData()
// 指定指示器为第一个
self.indicatorView.curIndicatorIndex = 0
// 指定显示图片为第一个
bannerView.selectItem(at: 0, animated: false)
// 开启定时器开始滚动
bannerView.automaticSlidingInterval = bannerSildingInterval
}
}
......@@ -34,7 +45,7 @@ class YHHomeBannerView: UIView {
view.dataSource = self
view.bounces = false
view.isInfinite = true
view.automaticSlidingInterval = 3
view.automaticSlidingInterval = bannerSildingInterval
view.register(YHHomeBannerCollectionViewCell.self, forCellWithReuseIdentifier: "cell")
view.itemSize = CGSizeMake(YHHomeBannerView.viewH, YHHomeBannerView.viewH)//FSPagerView.automaticSize
return view
......
......@@ -39,7 +39,7 @@ class YHHomeCollectionViewCell: UICollectionViewCell {
lazy var descripeLable:UILabel = {
let label = UILabel()
label.text = ""
label.textColor = UIColor(hex: 0x121A26, alpha: 1.0)
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_R(ofSize: 14)
label.numberOfLines = 2
label.lineBreakMode = .byTruncatingTail
......@@ -63,7 +63,7 @@ class YHHomeCollectionViewCell: UICollectionViewCell {
lazy var numLable:UILabel = {
let label = UILabel()
label.text = ""
label.textColor = UIColor(hex: 0x121A264D, alpha: 0.3)
label.textColor = UIColor.mainTextColor30
label.font = UIFont.PFSC_R(ofSize: 12)
return label
}()
......
......@@ -40,7 +40,7 @@ class YHSearchInfoBar: UIView {
textField.attributedPlaceholder = NSAttributedString(string: "香港身份".local, attributes: [NSAttributedString.Key.foregroundColor : UIColor(hex: 0x94A3B8)])
textField.font = UIFont.PFSC_M(ofSize: 12)
textField.tintColor = UIColor.brandMainColor
textField.textColor = UIColor(hexString: "#121A26")
textField.textColor = UIColor.mainTextColor30
textField.clearButtonMode = .whileEditing
textField.addTarget(self, action: #selector(textFieldChanged(textField:)), for: .editingChanged)
textField.delegate = self
......
......@@ -43,7 +43,7 @@ class YHSearchInfoCell: UITableViewCell {
var label = UILabel()
label.font = Self.textFont
label.textAlignment = .left
label.textColor = UIColor(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
label.numberOfLines = 2
return label
}()
......@@ -84,7 +84,7 @@ class YHSearchInfoCell: UITableViewCell {
func renderHighLightText(_ text: String) {
var attributedString = NSMutableAttributedString(string:self.model.title, attributes: [
.foregroundColor: UIColor(hex: 0x121A26),
.foregroundColor: UIColor.mainTextColor,
.font: Self.textFont
])
if isEmptyString(text) {
......
......@@ -16,7 +16,7 @@ class YHSearchInfoHistoryCell: UICollectionViewCell {
var label = UILabel()
label.font = .PFSC_R(ofSize: 12)
label.textAlignment = .left
label.textColor = UIColor(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
return label
}()
......
......@@ -139,17 +139,17 @@ class YHServiceOrderAlertView: UIView {
make.top.equalTo(157)
}
let a: ASAttributedString = .init("1.当前仅支持查看", .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.7)))
let a: ASAttributedString = .init("1.当前仅支持查看", .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor.mainTextColor.withAlphaComponent(0.7)))
let aa: ASAttributedString = .init(NSAttributedString(string: "优才订单"), .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor.brandMainColor))
let aaa: ASAttributedString = .init(",如果是签约了其他高才、专才、留学等订单,请与您的服务管家或销售顾问企微沟通联系哦", .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.7)))
let aaa: ASAttributedString = .init(",如果是签约了其他高才、专才、留学等订单,请与您的服务管家或销售顾问企微沟通联系哦", .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor.mainTextColor.withAlphaComponent(0.7)))
let b: ASAttributedString = .init(NSAttributedString(string: "2.使用其他手机号签约合同/订单,请退出登录"), .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.7)))
let b: ASAttributedString = .init(NSAttributedString(string: "2.使用其他手机号签约合同/订单,请退出登录"), .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor.mainTextColor.withAlphaComponent(0.7)))
let bb: ASAttributedString = .init("切换账号", .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor.brandMainColor))
let bbb: ASAttributedString = .init("查看", .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.7)))
let bbb: ASAttributedString = .init("查看", .font(UIFont.PFSC_M(ofSize: 15)),.foreground(UIColor.mainTextColor.withAlphaComponent(0.7)))
measageLabel.attributed.text = a + aa + aaa
subMeasageLabel.attributed.text = b + bb + bbb
......
......@@ -76,7 +76,7 @@ class YHOrderDetailViewController: YHBaseViewController {
orderLabel = {
let label = UILabel()
label.font = UIFont.PFSC_M(ofSize: 14)
label.textColor = UIColor(hex: 0x121A26).withAlphaComponent(0.5)
label.textColor = UIColor.mainTextColor.withAlphaComponent(0.5)
label.text = "合同编号: "
return label
}()
......@@ -90,7 +90,7 @@ class YHOrderDetailViewController: YHBaseViewController {
phoneLabel = {
let label = UILabel()
label.font = UIFont.PFSC_M(ofSize: 14)
label.textColor = UIColor(hex: 0x121A26).withAlphaComponent(0.5)
label.textColor = UIColor.mainTextColor.withAlphaComponent(0.5)
label.text = "签约手机号:"
return label
}()
......@@ -104,7 +104,7 @@ class YHOrderDetailViewController: YHBaseViewController {
orderNumLabel = {
let label = UILabel()
label.font = UIFont.PFSC_M(ofSize: 14)
label.textColor = UIColor(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
label.text = model.orderSn
label.textAlignment = .right
return label
......@@ -119,7 +119,7 @@ class YHOrderDetailViewController: YHBaseViewController {
phoneNumLabel = {
let label = UILabel()
label.font = UIFont.PFSC_M(ofSize: 14)
label.textColor = UIColor(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
label.text = model.mobile
label.textAlignment = .right
return label
......
......@@ -263,14 +263,14 @@ extension YHServiceCenterMainViewController {
}
}
if doneCount == 6 {
let a: ASAttributedString = .init("您好,\(name),您的资料已全部准备完成,已进入", .font(UIFont.PFSC_R(ofSize: 13)),.foreground(UIColor(hex: 0x121a26)))
let a: ASAttributedString = .init("您好,\(name),您的资料已全部准备完成,已进入", .font(UIFont.PFSC_R(ofSize: 13)),.foreground(UIColor.mainTextColor))
let aa: ASAttributedString = .init(NSAttributedString(string: "全套资料审核"), .font(UIFont.PFSC_M(ofSize: 13)),.foreground(UIColor.brandMainColor))
let aaa: ASAttributedString = .init("阶段,审核没问题会安排递交入境处哦~", .font(UIFont.PFSC_R(ofSize: 13)),.foreground(UIColor(hex: 0x121a26)))
let aaa: ASAttributedString = .init("阶段,审核没问题会安排递交入境处哦~", .font(UIFont.PFSC_R(ofSize: 13)),.foreground(UIColor.mainTextColor))
self.nameLabel.attributed.text = a + aa + aaa
} else {
let a: ASAttributedString = .init("您好,\(name),您当前处于", .font(UIFont.PFSC_R(ofSize: 13)),.foreground(UIColor(hex: 0x121a26)))
let a: ASAttributedString = .init("您好,\(name),您当前处于", .font(UIFont.PFSC_R(ofSize: 13)),.foreground(UIColor.mainTextColor))
let aa: ASAttributedString = .init(NSAttributedString(string: "信息提交"), .font(UIFont.PFSC_M(ofSize: 13)),.foreground(UIColor.brandMainColor))
let aaa: ASAttributedString = .init("阶段,让我们一起共同完成您的身份申请之旅吧~", .font(UIFont.PFSC_R(ofSize: 13)),.foreground(UIColor(hex: 0x121a26)))
let aaa: ASAttributedString = .init("阶段,让我们一起共同完成您的身份申请之旅吧~", .font(UIFont.PFSC_R(ofSize: 13)),.foreground(UIColor.mainTextColor))
self.nameLabel.attributed.text = a + aa + aaa
}
}
......
......@@ -39,30 +39,83 @@ class YHCommonAlertView: UIView {
addGestureRecognizer(tap)
setView()
}
func setContent(_ title: String? = nil, _ message: String? = nil, _ leftButtonString: String? = nil, _ rightButtonString: String? = nil) {
self.titleLabel.text = title
self.messageLabel.text = message
self.disAgressButton.setTitle(leftButtonString, for: .normal)
self.agreeButton.setTitle(rightButtonString, for: .normal)
titleLabel.text = title
messageLabel.text = message
disAgressButton.setTitle(leftButtonString, for: .normal)
agreeButton.setTitle(rightButtonString, for: .normal)
centerView.snp.remakeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(299)
// make.height.equalTo(164)
}
if title?.count == 0 || title == nil {
centerView.snp.remakeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(299)
make.height.equalTo(164)
}
lineView.isHidden = true
messageLabel.snp.remakeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.lessThanOrEqualTo(60)
make.height.greaterThanOrEqualTo(21)
make.top.equalTo(37)
}
lineView.isHidden = true
} else {
lineView.isHidden = false
messageLabel.snp.remakeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.greaterThanOrEqualTo(21)
make.top.equalTo(lineView.snp.bottom).offset(21)
}
}
if leftButtonString?.isEmpty == false && rightButtonString?.isEmpty == false {
disAgressButton.isHidden = false
agreeButton.isHidden = false
disAgressButton.snp.remakeConstraints { make in
make.top.equalTo(messageLabel.snp.bottom).offset(36)
make.left.equalTo(16)
make.bottom.equalTo(-21)
make.width.equalTo(128)
make.height.equalTo(45)
}
agreeButton.snp.remakeConstraints { make in
make.top.equalTo(disAgressButton.snp.top)
make.width.equalTo(disAgressButton.snp.width)
make.height.equalTo(disAgressButton.snp.height)
make.right.equalToSuperview().offset(-kMargin)
}
} else {
disAgressButton.isHidden = true
agreeButton.isHidden = false
agreeButton.snp.remakeConstraints { make in
make.top.equalTo(messageLabel.snp.bottom).offset(36)
make.height.equalTo(45)
make.right.equalToSuperview().offset(-kMargin)
make.left.equalToSuperview().offset(kMargin)
make.bottom.equalToSuperview().offset(-kMargin)
}
if rightButtonString?.isEmpty == true && leftButtonString?.isEmpty == true {
agreeButton.setTitle("我知道了", for: .normal)
} else if leftButtonString?.isEmpty == true {
} else {
agreeButton.setTitle(leftButtonString, for: .normal)
}
}
}
......@@ -104,7 +157,6 @@ class YHCommonAlertView: UIView {
messageLabel = {
let label = UILabel()
label.textAlignment = .center
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_R(ofSize: 16)
label.numberOfLines = 0
......@@ -122,7 +174,7 @@ class YHCommonAlertView: UIView {
disAgressButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0xffffff)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("不同意", for: .normal)
button.setTitleColor( UIColor.brandMainColor, for: .normal)
......@@ -143,7 +195,7 @@ class YHCommonAlertView: UIView {
agreeButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor.brandMainColor
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 14)
button.contentHorizontalAlignment = .center
button.setTitle("同意", for: .normal)
button.setTitleColor( UIColor(hex:0xffffff), for: .normal)
......
//
// YHCommonAlertView2.swift
// galaxy
//
// Created by davidhuangA on 2024/5/20.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHCommonAlertView2: UIView {
typealias AgreeBlock = () -> ()
var agreeBlock: AgreeBlock?
var cancelBlcok: AgreeBlock?
var centerView: UIView!
var titleLabel: UILabel!
var lineView: UIView!
var messageLabel: UILabel!
var agreeButton: UIButton!
var disAgressButton: UIButton!
var isFullGuestureEnabel : Bool = true //view响应全局手势 默认响应
static func show(_ title: String? = nil, _ message: String? = nil, _ leftButtonString: String? = nil, _ rightButtonString: String? = nil,fullGuestureEnable : Bool = true,cancelCallBack: (() -> Void)? = nil, callBack: @escaping (() -> Void)) {
let view = YHCommonAlertView2(frame: CGRect(x: 0, y: 0, width: KScreenWidth, height: KScreenHeight))
view.agreeBlock = callBack
view.cancelBlcok = cancelCallBack
view.setContent(title, message, leftButtonString, rightButtonString)
view.isFullGuestureEnabel = fullGuestureEnable
let window = UIApplication.shared.yhKeyWindow()
window?.addSubview(view)
}
override init(frame: CGRect) {
super.init(frame: frame)
backgroundColor = UIColor(white: 0.5, alpha: 0.1)
let tap = UITapGestureRecognizer(target: self, action: #selector(handleTap))
tap.delegate = self
addGestureRecognizer(tap)
setView()
}
func setContent(_ title: String? = nil, _ message: String? = nil, _ leftButtonString: String? = nil, _ rightButtonString: String? = nil) {
self.titleLabel.text = title
self.messageLabel.text = message
self.disAgressButton.setTitle(leftButtonString, for: .normal)
self.agreeButton.setTitle(rightButtonString, for: .normal)
if title?.count == 0 || title == nil {
centerView.snp.remakeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(299)
make.height.equalTo(164)
}
messageLabel.snp.remakeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.lessThanOrEqualTo(60)
make.top.equalTo(37)
}
lineView.isHidden = true
} else {
lineView.isHidden = false
centerView.snp.remakeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(299)
make.height.equalTo(334)
}
messageLabel.snp.remakeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.equalTo(172)
make.top.equalTo(lineView.snp.bottom).offset(21)
}
}
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setView() {
backgroundColor = UIColor(hex: 0x0000, alpha: 0.5)
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = kCornerRadius6
return view
}()
addSubview(centerView)
centerView.snp.makeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(299)
make.height.equalTo(187)
}
titleLabel = {
let label = UILabel()
label.textAlignment = .center
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_M(ofSize: 17)
label.numberOfLines = 0
return label
}()
centerView.addSubview(titleLabel)
titleLabel.snp.makeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.equalTo(20)
make.top.equalTo(16)
}
messageLabel = {
let label = UILabel()
label.textAlignment = .left
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_R(ofSize: 16)
label.numberOfLines = 0
return label
}()
centerView.addSubview(messageLabel)
messageLabel.snp.makeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.equalTo(42)
make.top.equalTo(63)
}
disAgressButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0xffffff)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.contentHorizontalAlignment = .center
button.setTitle("不同意", for: .normal)
button.setTitleColor( UIColor.brandMainColor, for: .normal)
button.layer.cornerRadius = kCornerRadius3
button.layer.borderWidth = 1
button.layer.borderColor = UIColor.brandMainColor.cgColor
button.addTarget(self, action: #selector(disagree), for: .touchUpInside)
return button
}()
centerView.addSubview(disAgressButton)
disAgressButton.snp.makeConstraints { make in
make.left.equalTo(16)
make.bottom.equalTo(-21)
make.width.equalTo(128)
make.height.equalTo(45)
}
agreeButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor.brandMainColor
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 = kCornerRadius3
button.addTarget(self, action: #selector(agree), for: .touchUpInside)
return button
}()
centerView.addSubview(agreeButton)
agreeButton.snp.makeConstraints { make in
make.right.equalTo(-16)
make.bottom.equalTo(-21)
make.width.equalTo(128)
make.height.equalTo(45)
}
lineView = {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xF0F0F0)
return line
}()
centerView.addSubview(lineView)
lineView.snp.makeConstraints { make in
make.left.right.equalTo(0)
make.height.equalTo(1)
make.top.equalTo(titleLabel.snp.bottom).offset(12)
}
}
@objc func agree() {
if let block = self.agreeBlock {
block()
}
dismiss()
}
@objc private func handleTap(_ sender: AnyObject?) {
print("处理点击手势")
if isFullGuestureEnabel {
dismiss()
}
}
@objc func disagree() {
if let block = self.cancelBlcok {
block()
}
dismiss()
}
func dismiss() {
removeFromSuperview()
}
}
extension YHCommonAlertView2: UIGestureRecognizerDelegate {
func gestureRecognizer(_ gestureRecognizer:UIGestureRecognizer, shouldReceive touch:UITouch) -> Bool {
if touch.view == self {
return true
}
return false
}
}
//
// YHCommonAlertView3.swift
// galaxy
//
// Created by davidhuangA on 2024/5/20.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHCommonAlertView3: UIView {
typealias AgreeBlock = () -> ()
var agreeBlock: AgreeBlock?
var cancelBlcok: AgreeBlock?
var centerView: UIView!
var titleLabel: UILabel!
var lineView: UIView!
var messageLabel: UILabel!
var agreeButton: UIButton!
var disAgressButton: UIButton!
var isFullGuestureEnabel : Bool = true //view响应全局手势 默认响应
static func show(_ title: String? = nil, _ message: String? = nil, _ leftButtonString: String? = nil, _ rightButtonString: String? = nil,fullGuestureEnable : Bool = true,cancelCallBack: (() -> Void)? = nil, callBack: @escaping (() -> Void)) {
let view = YHCommonAlertView3(frame: CGRect(x: 0, y: 0, width: KScreenWidth, height: KScreenHeight))
view.agreeBlock = callBack
view.cancelBlcok = cancelCallBack
view.setContent(title, message, leftButtonString, rightButtonString)
view.isFullGuestureEnabel = fullGuestureEnable
let window = UIApplication.shared.yhKeyWindow()
window?.addSubview(view)
}
override init(frame: CGRect) {
super.init(frame: frame)
backgroundColor = UIColor(white: 0.5, alpha: 0.1)
let tap = UITapGestureRecognizer(target: self, action: #selector(handleTap))
tap.delegate = self
addGestureRecognizer(tap)
setView()
}
func setContent(_ title: String? = nil, _ message: String? = nil, _ leftButtonString: String? = nil, _ rightButtonString: String? = nil) {
self.titleLabel.text = title
self.messageLabel.text = message
self.disAgressButton.setTitle(leftButtonString, for: .normal)
self.agreeButton.setTitle(rightButtonString, for: .normal)
if title?.count == 0 || title == nil {
centerView.snp.remakeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(299)
make.height.equalTo(164)
}
messageLabel.snp.remakeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.lessThanOrEqualTo(60)
make.top.equalTo(37)
}
lineView.isHidden = true
} else {
lineView.isHidden = false
centerView.snp.remakeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(299)
// make.height.equalTo(257 + 18)
}
messageLabel.snp.remakeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
// make.height.equalTo(88 + 18)
make.top.equalTo(lineView.snp.bottom).offset(21)
}
disAgressButton.isHidden = true
agreeButton.snp.remakeConstraints { make in
make.right.equalTo(-16)
make.bottom.equalTo(-17)
make.left.equalTo(kMargin)
make.height.equalTo(45)
make.top.equalTo(messageLabel.snp.bottom).offset(28)
}
}
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setView() {
backgroundColor = UIColor(hex: 0x0000, alpha: 0.5)
centerView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = kCornerRadius6
return view
}()
addSubview(centerView)
centerView.snp.makeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(299)
make.height.equalTo(187)
}
titleLabel = {
let label = UILabel()
label.textAlignment = .center
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_M(ofSize: 17)
label.numberOfLines = 0
return label
}()
centerView.addSubview(titleLabel)
titleLabel.snp.makeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.equalTo(20)
make.top.equalTo(16)
}
messageLabel = {
let label = UILabel()
label.textAlignment = .left
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_R(ofSize: 16)
label.numberOfLines = 0
return label
}()
centerView.addSubview(messageLabel)
messageLabel.snp.makeConstraints { make in
make.left.equalTo(22)
make.right.equalTo(-22)
make.height.equalTo(42)
make.top.equalTo(63)
}
disAgressButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor(hex:0xffffff)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.contentHorizontalAlignment = .center
button.setTitle("不同意", for: .normal)
button.setTitleColor( UIColor.brandMainColor, for: .normal)
button.layer.cornerRadius = kCornerRadius3
button.layer.borderWidth = 1
button.layer.borderColor = UIColor.brandMainColor.cgColor
button.addTarget(self, action: #selector(disagree), for: .touchUpInside)
return button
}()
centerView.addSubview(disAgressButton)
disAgressButton.snp.makeConstraints { make in
make.left.equalTo(16)
make.bottom.equalTo(-21)
make.width.equalTo(128)
make.height.equalTo(45)
}
agreeButton = {
let button = UIButton(type: .custom)
button.backgroundColor = UIColor.brandMainColor
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 = kCornerRadius3
button.addTarget(self, action: #selector(agree), for: .touchUpInside)
return button
}()
centerView.addSubview(agreeButton)
agreeButton.snp.makeConstraints { make in
make.right.equalTo(-16)
make.bottom.equalTo(-21)
make.width.equalTo(128)
make.height.equalTo(45)
}
lineView = {
let line = UIView()
line.backgroundColor = UIColor(hex: 0xF0F0F0)
return line
}()
centerView.addSubview(lineView)
lineView.snp.makeConstraints { make in
make.left.right.equalTo(0)
make.height.equalTo(1)
make.top.equalTo(titleLabel.snp.bottom).offset(12)
}
}
@objc func agree() {
if let block = self.agreeBlock {
block()
}
dismiss()
}
@objc private func handleTap(_ sender: AnyObject?) {
print("处理点击手势")
if isFullGuestureEnabel {
dismiss()
}
}
@objc func disagree() {
if let block = self.cancelBlcok {
block()
}
dismiss()
}
func dismiss() {
removeFromSuperview()
}
}
extension YHCommonAlertView3: UIGestureRecognizerDelegate {
func gestureRecognizer(_ gestureRecognizer:UIGestureRecognizer, shouldReceive touch:UITouch) -> Bool {
if touch.view == self {
return true
}
return false
}
}
......@@ -19,24 +19,7 @@ class YHInformationFillTipsAlertView: UIView {
var messageLabel: UILabel!
var agreeButton: UIButton!
var disAgressButton: UIButton!
//头部背景图片
lazy var headBkgImagV: UIImageView = {
let imagV = UIImageView()
imagV.image = UIImage(named: "submit_success_bkg")
imagV.contentMode = .scaleAspectFill
return imagV
}()
//头部背景图片
lazy var successIcon: UIImageView = {
let imagV = UIImageView()
imagV.image = UIImage(named: "submit_success_icon")
imagV.contentMode = .scaleAspectFill
return imagV
}()
var homeTableView: UITableView = {
let tableView = UITableView(frame: .zero, style: .plain)
tableView.backgroundColor = .clear
......
......@@ -22,7 +22,7 @@ class YHServiceNoOrderView: UIView {
private lazy var tipsLab : UILabel = {
let lable = UILabel()
lable.textColor = UIColor.init(hex: 0x121A26)
lable.textColor = UIColor.mainTextColor
lable.font = UIFont.PFSC_M(ofSize: 14)
lable.textAlignment = .center
lable.text = "您还没有相关订单"
......@@ -50,7 +50,7 @@ class YHServiceNoOrderView: UIView {
btn.layer.cornerRadius = kCornerRadius3
btn.clipsToBounds = true
btn.titleLabel?.font = UIFont.PFSC_M(ofSize: 13)
btn.setTitleColor(UIColor.init(hex: 0x121A26), for: .normal)
btn.setTitleColor(UIColor.mainTextColor, for: .normal)
btn.backgroundColor = UIColor.init(hex: 0xF4F6FA)
return btn
}()
......
......@@ -65,7 +65,7 @@ extension YHServiceOrderProgressTableViewCell {
messageLabel.text = "您还有" + "\(model.num)" + "份信息待填写哦~"
// 0未知 1待开始 2进行中 3 已完成
if model.status == 1 {
titleLabel.textColor = UIColor(hex: 0x121a26,transparency: 0.5)
titleLabel.textColor = UIColor.mainTextColor50
messageLabel.textColor = UIColor(hex: 0x94a3b8,transparency: 0.5)
buttonLabel.text = "待开始"
buttonLabel.backgroundColor = UIColor(hex: 0xb8babe,transparency: 0.5)
......@@ -94,8 +94,8 @@ extension YHServiceOrderProgressTableViewCell {
titleLabel.text = "我的文书"
messageLabel.text = "您的文书还没确认哦~"
}
let b: ASAttributedString = .init(NSAttributedString(string: "\(model.percentage)"), .font(UIFont(name: "DINAlternate-Bold", size: 24)!),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.3)))
let bb: ASAttributedString = .init("%", .font(UIFont.PFSC_M(ofSize: 10)),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.3)))
let b: ASAttributedString = .init(NSAttributedString(string: "\(model.percentage)"), .font(UIFont(name: "DINAlternate-Bold", size: 24)!),.foreground(UIColor.mainTextColor.withAlphaComponent(0.3)))
let bb: ASAttributedString = .init("%", .font(UIFont.PFSC_M(ofSize: 10)),.foreground(UIColor.mainTextColor.withAlphaComponent(0.3)))
progressLabel.attributed.text = b + bb
}
if model.status == 2 {
......@@ -163,8 +163,8 @@ extension YHServiceOrderProgressTableViewCell {
}
}
let b: ASAttributedString = .init(NSAttributedString(string: "\(model.percentage)"), .font(UIFont(name: "DINAlternate-Bold", size: 24)!),.foreground(UIColor(hex: 0x121a26)))
let bb: ASAttributedString = .init("%", .font(UIFont.PFSC_M(ofSize: 10)),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.3)))
let b: ASAttributedString = .init(NSAttributedString(string: "\(model.percentage)"), .font(UIFont(name: "DINAlternate-Bold", size: 24)!),.foreground(UIColor.mainTextColor))
let bb: ASAttributedString = .init("%", .font(UIFont.PFSC_M(ofSize: 10)),.foreground(UIColor.mainTextColor.withAlphaComponent(0.3)))
progressLabel.attributed.text = b + bb
}
if model.status == 3 {
......@@ -199,8 +199,8 @@ extension YHServiceOrderProgressTableViewCell {
titleLabel.text = "我的文书"
messageLabel.text = "恭喜您,文件已全部确认完~"
}
let b: ASAttributedString = .init(NSAttributedString(string: "\(model.percentage)"), .font(UIFont(name: "DINAlternate-Bold", size: 24)!),.foreground(UIColor(hex: 0x121a26)))
let bb: ASAttributedString = .init("%", .font(UIFont.PFSC_M(ofSize: 10)),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.3)))
let b: ASAttributedString = .init(NSAttributedString(string: "\(model.percentage)"), .font(UIFont(name: "DINAlternate-Bold", size: 24)!),.foreground(UIColor.mainTextColor))
let bb: ASAttributedString = .init("%", .font(UIFont.PFSC_M(ofSize: 10)),.foreground(UIColor.mainTextColor.withAlphaComponent(0.3)))
progressLabel.attributed.text = b + bb
}
if model.status == 4 {
......@@ -250,8 +250,8 @@ extension YHServiceOrderProgressTableViewCell {
let aaa: ASAttributedString = .init("正在制作中哦~", .font(UIFont.PFSC_M(ofSize: 13)),.foreground(UIColor(hex: 0x94a3b8)))
messageLabel.attributed.text = a + aa + aaa
}
let b: ASAttributedString = .init(NSAttributedString(string: "\(model.percentage)"), .font(UIFont(name: "DINAlternate-Bold", size: 24)!),.foreground(UIColor(hex: 0x121a26)))
let bb: ASAttributedString = .init("%", .font(UIFont.PFSC_M(ofSize: 10)),.foreground(UIColor(hex: 0x121a26).withAlphaComponent(0.3)))
let b: ASAttributedString = .init(NSAttributedString(string: "\(model.percentage)"), .font(UIFont(name: "DINAlternate-Bold", size: 24)!),.foreground(UIColor.mainTextColor))
let bb: ASAttributedString = .init("%", .font(UIFont.PFSC_M(ofSize: 10)),.foreground(UIColor.mainTextColor.withAlphaComponent(0.3)))
progressLabel.attributed.text = b + bb
}
if model.percentage == 0 {
......
......@@ -180,7 +180,7 @@ class YHCodeSueecssViewController: YHBaseViewController {
if success == false {
if error?.errorCode == YHErrorCode.unregisterError.rawValue {
YHCommonAlertView3.show("状态提示", "您的账号已注销,暂时无法登录app \n \r\n具体详情可邮件联系\r\nnick.gzm@galaxyoversea.com", "取消", "我知道了") {
YHCommonAlertView.show("状态提示", "您的账号已注销,暂时无法登录app \n \r\n具体详情可邮件联系\r\nnick.gzm@galaxyoversea.com", "", "我知道了") {
self.navigationController?.popViewController()
}
} else {
......
......@@ -42,7 +42,7 @@ class YHCodeSueecssWithVideoBkgViewController: YHBaseViewController {
lazy var frontHoldView: UIView = {
let view = UIView()
view.backgroundColor = UIColor(hex: 0x121A26, alpha: 0.32)
view.backgroundColor = UIColor.mainTextColor30
return view
}()
......@@ -96,7 +96,7 @@ extension YHCodeSueecssWithVideoBkgViewController {
if success == false {
if error?.errorCode == YHErrorCode.unregisterError.rawValue {
YHCommonAlertView3.show("状态提示", "您的账号已注销,暂时无法登录app \n \r\n具体详情可邮件联系\r\nnick.gzm@galaxyoversea.com", "取消", "我知道了") {
YHCommonAlertView.show("状态提示", "您的账号已注销,暂时无法登录app \n \r\n具体详情可邮件联系\r\nnick.gzm@galaxyoversea.com", "", "我知道了") {
self.navigationController?.popViewController()
}
} else {
......@@ -252,7 +252,7 @@ extension YHCodeSueecssWithVideoBkgViewController {
let button = UILabel()
button.font = UIFont.PFSC_M(ofSize: 16)
button.text = "重新发送(58)"
button.textColor = UIColor.init(hex: 0x121A26)
button.textColor = UIColor.mainTextColor
button.textAlignment = .center
button.isHidden = false
button.layer.cornerRadius = 24
......
......@@ -53,7 +53,7 @@ class YHPhoneLiginWithVideoBkgViewController: YHBaseViewController {
lazy var frontHoldView: UIView = {
let view = UIView()
view.backgroundColor = UIColor(hex: 0x121A26, alpha: 0.32)
view.backgroundColor = UIColor.mainTextColor30
return view
}()
......
......@@ -14,7 +14,11 @@ class YHLoginPrivacyView: UIView {
var serviceButton: UIButton!
var andLabel: UILabel!
var privacyButton: UIButton!
var isAgree: Bool = false
var isAgree: Bool = false {
didSet{
agreeButton.isSelected = isAgree
}
}
override init(frame: CGRect) {
super.init(frame: frame)
......@@ -45,7 +49,7 @@ class YHLoginPrivacyView: UIView {
let label = UILabel()
label.text = "我已阅读并同意"
label.font = UIFont.PFSC_R(ofSize: 12)
label.textColor = UIColor.labelTextColor2
label.textColor = UIColor(hex: 0xffffff, alpha: 0.7)
label.textAlignment = .left
return label
}()
......@@ -76,7 +80,7 @@ class YHLoginPrivacyView: UIView {
let label = UILabel()
label.text = "和"
label.font = UIFont.PFSC_R(ofSize: 12)
label.textColor = UIColor.labelTextColor2
label.textColor = UIColor(hex: 0xffffff, alpha: 0.7)
label.textAlignment = .left
return label
}()
......
......@@ -36,7 +36,7 @@ class YHMessageListVC: YHBaseViewController {
let bar = UIView()
let titleLabel = UILabel()
titleLabel.textColor = UIColor(hex: 0x121A26)
titleLabel.textColor = UIColor.mainTextColor
titleLabel.textAlignment = .left
titleLabel.font = UIFont.PFSC_M(ofSize:21)
titleLabel.text = "消息"
......@@ -325,7 +325,7 @@ extension YHMessageListVC: UITableViewDelegate, UITableViewDataSource {
}
let label = UILabel()
label.textColor = UIColor(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
label.textAlignment = .left
label.font = UIFont.PFSC_R(ofSize:13)
label.text = "开启通知,及时掌握最新消息".local
......
......@@ -89,7 +89,7 @@ class YHDetailMessageCell: UITableViewCell {
contentView.backgroundColor = UIColor(hex:0xF8F8F8)
timeLabel = UILabel()
timeLabel.textColor = UIColor(hex: 0x121A26, alpha: 0.3)
timeLabel.textColor = UIColor.mainTextColor30
timeLabel.textAlignment = .center
timeLabel.font = UIFont.PFSC_R(ofSize:12)
timeLabel.text = "2023-09-13"
......@@ -118,7 +118,7 @@ class YHDetailMessageCell: UITableViewCell {
detailLabel.textAlignment = .left
detailLabel.numberOfLines = 0
detailLabel.font = UIFont.PFSC_R(ofSize:14)
detailLabel.textColor = UIColor(hex: 0x121A26, alpha: 0.7)
detailLabel.textColor = UIColor.mainTextColor70
whiteView.addSubview(detailLabel)
lineView = UIView()
......@@ -183,12 +183,12 @@ class YHDetailMessageCell: UITableViewCell {
func updateModel() {
let text1: ASAttributedString = .init("林先生,您好,您尚有20%内容未填写,请到", .font(UIFont.PFSC_R(ofSize: 14)), .foreground(UIColor(hex: 0x121A26, alpha: 0.7)))
let text1: ASAttributedString = .init("林先生,您好,您尚有20%内容未填写,请到", .font(UIFont.PFSC_R(ofSize: 14)), .foreground(UIColor.mainTextColor70))
let text2: ASAttributedString = .init("服务中心-资料上传", .font(UIFont.PFSC_R(ofSize: 14)),.foreground(UIColor.brandMainColor), .action {
})
let text3: ASAttributedString = .init("去填写,请您尽快完成~", .font(UIFont.PFSC_R(ofSize: 14)),.foreground(UIColor(hex: 0x121A26, alpha: 0.7)))
let text3: ASAttributedString = .init("去填写,请您尽快完成~", .font(UIFont.PFSC_R(ofSize: 14)),.foreground(UIColor.mainTextColor70))
detailLabel.attributed.text = text1 + text2 + text3
}
......
......@@ -119,19 +119,19 @@ class YHMessageSessionCell: UITableViewCell {
iconContentView.addSubview(badgeLabel)
nameLabel = UILabel()
nameLabel.textColor = UIColor(hex:0x121A26)
nameLabel.textColor = UIColor.mainTextColor
nameLabel.textAlignment = .left
nameLabel.font = UIFont.PFSC_M(ofSize:15)
contentView.addSubview(nameLabel)
detailLabel = UILabel()
detailLabel.textColor = UIColor(hex:0x121A26, alpha: 0.5)
detailLabel.textColor = UIColor.mainTextColor50
detailLabel.textAlignment = .left
detailLabel.font = UIFont.PFSC_R(ofSize:12)
contentView.addSubview(detailLabel)
timeLabel = UILabel()
timeLabel.textColor = UIColor(hex:0x121A26, alpha: 0.3)
timeLabel.textColor = UIColor.mainTextColor30
timeLabel.textAlignment = .right
timeLabel.font = UIFont.PFSC_R(ofSize:11)
timeLabel.setContentCompressionResistancePriority(.required, for: .horizontal)
......@@ -139,7 +139,7 @@ class YHMessageSessionCell: UITableViewCell {
contentView.addSubview(timeLabel)
bottomLineView = UIView()
bottomLineView.backgroundColor = UIColor(hex:0x121A26,transparency: 0.05)
bottomLineView.backgroundColor = UIColor.mainTextColor5
contentView.addSubview(bottomLineView)
iconContentView.snp.makeConstraints { make in
......
......@@ -50,7 +50,7 @@ class YHAboutUsViewController: YHBaseViewController {
lazy var aboutLabel = {
var label = UILabel()
label.text = "关于银河".local
label.textColor = UIColor.init(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
label.textAlignment = NSTextAlignment.left
label.font = UIFont.PFSC_B(ofSize: 21)
return label
......@@ -69,7 +69,7 @@ class YHAboutUsViewController: YHBaseViewController {
lazy var advantageLabel = {
var label = UILabel()
label.text = "四大优势"
label.textColor = UIColor.init(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
label.textAlignment = .center
label.font = UIFont.PFSC_B(ofSize: 17)
return label
......
......@@ -12,7 +12,7 @@ class YHDeviceInfoViewController: YHBaseViewController {
lazy var deviceInfoLabel: UILabel = {
let label = UILabel()
label.textColor = UIColor(hex:0x121A26)
label.textColor = UIColor.mainTextColor
label.textAlignment = .left
label.font = UIFont.PFSC_M(ofSize:15)
label.numberOfLines = 0
......
......@@ -138,7 +138,7 @@ extension YHMyNotifySettingVC: UITableViewDelegate, UITableViewDataSource {
view.backgroundColor = UIColor(hex: 0xF8FAFB)
let label = UILabel()
label.textColor = UIColor(hex: 0x121A26, alpha: 0.5)
label.textColor = UIColor.mainTextColor50
label.textAlignment = .left
label.font = UIFont.PFSC_R(ofSize:12)
label.numberOfLines = 0
......
......@@ -250,7 +250,7 @@ extension YHMyPermissionSettingVC: UITableViewDelegate, UITableViewDataSource {
view.backgroundColor = UIColor(hex: 0xF8FAFB)
let label = UILabel()
label.textColor = UIColor(hex: 0x121A26, alpha: 0.5)
label.textColor = UIColor.mainTextColor50
label.textAlignment = .left
label.font = UIFont.PFSC_R(ofSize:12)
label.numberOfLines = 0
......
......@@ -40,7 +40,7 @@ class YHMySettingViewController: YHBaseViewController, ConstraintRelatableTarget
let btn = UIButton()
btn.setTitle("注销账号".local, for: .normal)
btn.titleLabel?.font = UIFont.PFSC_R(ofSize: 13)
btn.setTitleColor(UIColor(hexString:"#121A26",transparency: 0.3), for: .normal)
btn.setTitleColor(UIColor.mainTextColor30, for: .normal)
btn.backgroundColor = .clear
btn.addTarget(self, action: #selector(clickRegBtn), for: .touchUpInside)
return btn
......@@ -180,7 +180,7 @@ class YHMySettingViewController: YHBaseViewController, ConstraintRelatableTarget
//点击注销按钮
@objc func clickRegBtn() {
YHCommonAlertView2.show("风险提示", "您正在进行账号注销操作,一旦完成注销,您将无法再登录\"银河港生活\"APP,并因此无法在APP中继续现有的服务流程。\n \n真心希望您能留下来,继续享受银河港生活为您提供的精彩服务。", "取消", "坚持注销") {
YHCommonAlertView.show("风险提示", "您正在进行账号注销操作,一旦完成注销,您将无法再登录\"银河港生活\"APP,并因此无法在APP中继续现有的服务流程。\n \n真心希望您能留下来,继续享受银河港生活为您提供的精彩服务。", "取消", "坚持注销") {
self.unRegisterAPPOp()
}
......@@ -230,7 +230,7 @@ extension YHMySettingViewController : UITableViewDelegate, UITableViewDataSource
if item.type == .version {
cell.isShowRedPoint = item.isShowRedPoint
var detailText = "已是最新版"
var detailColor = UIColor.init(hex: 0x121A26, alpha: 0.3)
var detailColor = UIColor.mainTextColor30
if let configModel = YHConfigManager.shared.reqVM.configModel, configModel.suggest_updating == true {
detailText = "去更新"
detailColor = UIColor.brandMainColor
......
......@@ -30,7 +30,7 @@ class YHAboutUsAdvantageCell: UICollectionViewCell {
lazy var titleLabel:UILabel = {
let label = UILabel()
label.textColor = UIColor.init(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
label.textAlignment = .center
label.font = UIFont.PFSC_B(ofSize: 14)
return label
......@@ -38,7 +38,7 @@ class YHAboutUsAdvantageCell: UICollectionViewCell {
lazy var detailLabel:UILabel = {
let label = UILabel()
label.textColor = UIColor(hex: 0x121A2680, alpha: 0.5)
label.textColor = UIColor.mainTextColor50
label.numberOfLines = 0
label.textAlignment = .center
label.font = UIFont.PFSC_R(ofSize: 11)
......
......@@ -12,8 +12,8 @@ class YHMyPermissionCell: UITableViewCell {
static let cellReuseIdentifier = "YHMyPermissionCell"
static let enableColor = UIColor(hex: 0x121A26, alpha: 0.3)
static let disableColor = UIColor(hex: 0x121A26, alpha: 0.7)
static let enableColor = UIColor.mainTextColor30
static let disableColor = UIColor.mainTextColor70
var titleLabel: UILabel!
var statusLabel: UILabel!
......@@ -33,7 +33,7 @@ class YHMyPermissionCell: UITableViewCell {
self.selectionStyle = .none
titleLabel = UILabel()
titleLabel.textColor = UIColor(hex:0x121A26)
titleLabel.textColor = UIColor.mainTextColor
titleLabel.textAlignment = .left
titleLabel.font = UIFont.PFSC_R(ofSize: 15)
contentView.addSubview(titleLabel)
......
......@@ -86,7 +86,7 @@ class YHFindAppNewVersionView: UIView {
lazy var titleLabel: UILabel = {
let label = UILabel()
label.textColor = UIColor.init(hex: 0x121A26)
label.textColor = UIColor.mainTextColor
label.font = UIFont.PFSC_B(ofSize:20)
label.text = "发现新版本"
return label
......
......@@ -27,7 +27,12 @@ extension UIColor {
static let brandMainColor6: UIColor = UIColor(hexString: "#0046B4",transparency: 0.06)!
//标题/主内容
static let mainTextColor : UIColor = UIColor(hexString: "#222222")!
// static let mainTextColor : UIColor = UIColor(hexString: "#222222")!
static let mainTextColor : UIColor = UIColor(hexString: "#121A26")!
static let mainTextColor5 : UIColor = UIColor(hexString: "#121A26",transparency: 0.05)!
static let mainTextColor30 : UIColor = UIColor(hexString: "#121A26",transparency: 0.3)!
static let mainTextColor50 : UIColor = UIColor(hexString: "#121A26",transparency: 0.5)!
static let mainTextColor70 : UIColor = UIColor(hexString: "#121A26",transparency: 0.7)!
//次内容一
static let subTextColor : UIColor = UIColor(hexString: "#4E4E4E")!
......
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