diff --git a/Thimra.xcodeproj/project.pbxproj b/Thimra.xcodeproj/project.pbxproj index 5e8b772..f2d7797 100644 --- a/Thimra.xcodeproj/project.pbxproj +++ b/Thimra.xcodeproj/project.pbxproj @@ -226,7 +226,7 @@ INFOPLIST_KEY_UIMainStoryboardFile = ""; INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown"; - IPHONEOS_DEPLOYMENT_TARGET = 14.0; + IPHONEOS_DEPLOYMENT_TARGET = 15.6; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", @@ -263,7 +263,7 @@ INFOPLIST_KEY_UIMainStoryboardFile = ""; INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown"; - IPHONEOS_DEPLOYMENT_TARGET = 14.0; + IPHONEOS_DEPLOYMENT_TARGET = 15.6; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", diff --git a/Thimra/AppDelegate/SceneDelegate.swift b/Thimra/AppDelegate/SceneDelegate.swift index 301b965..ccedbf7 100644 --- a/Thimra/AppDelegate/SceneDelegate.swift +++ b/Thimra/AppDelegate/SceneDelegate.swift @@ -14,9 +14,11 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate { func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) { guard let windowScene = (scene as? UIWindowScene) else { return } + let tabBarController = SPTabBarController() + SPAPPTool.mainTabBarController = tabBarController window = UIWindow(windowScene: windowScene) - window?.rootViewController = SPTabBarController() + window?.rootViewController = tabBarController window?.makeKeyAndVisible() } diff --git a/Thimra/Base/Controller/SPNavigationController.swift b/Thimra/Base/Controller/SPNavigationController.swift index c5349e3..a9f91eb 100644 --- a/Thimra/Base/Controller/SPNavigationController.swift +++ b/Thimra/Base/Controller/SPNavigationController.swift @@ -12,6 +12,8 @@ class SPNavigationController: UINavigationController { override func viewDidLoad() { super.viewDidLoad() self.jx_transitionAwake() + + self.view.backgroundColor = .backgroundColor() // Do any additional setup after loading the view. } diff --git a/Thimra/Base/Controller/SPTabBarController.swift b/Thimra/Base/Controller/SPTabBarController.swift index 9b7254f..4cddd5c 100644 --- a/Thimra/Base/Controller/SPTabBarController.swift +++ b/Thimra/Base/Controller/SPTabBarController.swift @@ -11,6 +11,7 @@ class SPTabBarController: UITabBarController { override func viewDidLoad() { super.viewDidLoad() + self.view.backgroundColor = .backgroundColor() let nav1 = createNavigationController(viewController: SPHomeViewController(), title: "Home".localized, image: UIImage(named: "tabbar_icon_01"), selectedImage: UIImage(named: "tabbar_icon_01_selected")) @@ -36,6 +37,28 @@ class SPTabBarController: UITabBarController { } +extension SPTabBarController { + func onPlayHistory() { +// self.selectedIndex = 1 + var index: Int? + var viewController: SPMyListViewController? + self.viewControllers?.enumerated().forEach({ + guard let nav = $1 as? UINavigationController else { return } + if let vc = nav.viewControllers.first as? SPMyListViewController { + index = $0 + viewController = vc + } + + }) + + if let index = index { + self.selectedIndex = index + viewController?.pageView.selectedIndex = 1 + } + } + +} + extension SPTabBarController { func createNavigationController(viewController: UIViewController, title: String?, image: UIImage?, selectedImage: UIImage?) -> UINavigationController { diff --git a/Thimra/Base/Controller/SPViewController.swift b/Thimra/Base/Controller/SPViewController.swift index 02a0a15..f20f99c 100644 --- a/Thimra/Base/Controller/SPViewController.swift +++ b/Thimra/Base/Controller/SPViewController.swift @@ -57,7 +57,7 @@ class SPViewController: UIViewController, JYPageChildContollerProtocol { } func setBgImageView() { - self.view.backgroundColor = .color121317() + self.view.backgroundColor = .backgroundColor() self.view.addSubview(toGradientView) @@ -116,7 +116,7 @@ class SPViewController: UIViewController, JYPageChildContollerProtocol { extension UIViewController { - func configNavigationBack(_ imageName: String = "left_arrow_icon_01") { + func configNavigationBack(_ imageName: String = "arrow_left_icon_01") { let image = UIImage(named: imageName) let leftBarButtonItem = UIBarButtonItem(image: image, style: .plain ,target: self,action: #selector(handleBack)) diff --git a/Thimra/Base/Define/SPDefine.swift b/Thimra/Base/Define/SPDefine.swift index 4cf5173..a528df9 100644 --- a/Thimra/Base/Define/SPDefine.swift +++ b/Thimra/Base/Define/SPDefine.swift @@ -49,6 +49,7 @@ public let kSPAPPVersion: String = (Bundle.main.infoDictionary!["CFBundleShortVe public let kSPAPPBundleVersion: String = (Bundle.main.infoDictionary!["CFBundleVersion"] as? String) ?? "0" public let kSPAPPBundleName: String = (Bundle.main.infoDictionary!["CFBundleName"] as? String) ?? "" +public let kSPAPPName: String = (Bundle.main.infoDictionary!["CFBundleDisplayName"] as? String) ?? "" //MARK: ------- 打印信息 ---------- public func spLog(message:Any? , file: String = #file, function: String = #function, line: Int = #line) { diff --git a/Thimra/Base/Extension/UIColor+SPAdd.swift b/Thimra/Base/Extension/UIColor+SPAdd.swift index 5738bc1..ea4b39c 100644 --- a/Thimra/Base/Extension/UIColor+SPAdd.swift +++ b/Thimra/Base/Extension/UIColor+SPAdd.swift @@ -13,13 +13,13 @@ extension UIColor { return UIColor(rgb: hex, alpha: alpha) } -// static func backgroundColor() -> UIColor { -// return colorF3F5F7() -// } -// -// + static func backgroundColor() -> UIColor { + return color121317() + } + + static func themeColor() -> UIColor { - return color000000() + return .color121317() } @@ -180,5 +180,17 @@ extension UIColor { static func color6D7A8F(alpha: CGFloat = 1) -> UIColor { return color(hex: 0x6D7A8F, alpha: alpha) } + + static func color8B6C6C(alpha: CGFloat = 1) -> UIColor { + return color(hex: 0x8B6C6C, alpha: alpha) + } + + static func color58484B(alpha: CGFloat = 1) -> UIColor { + return color(hex: 0x58484B, alpha: alpha) + } + + static func colorE6334B(alpha: CGFloat = 1) -> UIColor { + return color(hex: 0xE6334B, alpha: alpha) + } } diff --git a/Thimra/Base/Networking/API/SPVideoAPI.swift b/Thimra/Base/Networking/API/SPVideoAPI.swift index f25306a..e0c829d 100644 --- a/Thimra/Base/Networking/API/SPVideoAPI.swift +++ b/Thimra/Base/Networking/API/SPVideoAPI.swift @@ -91,12 +91,12 @@ class SPVideoAPI: NSObject { } ///历史记录列表 - static func requestPlayHistoryList(page: Int, completer: ((_ listModel: SPListModel?) -> Void)?) { + static func requestPlayHistoryList(page: Int, pageSize: Int = 20, completer: ((_ listModel: SPListModel?) -> Void)?) { var param = SPNetworkParameters(path: "/myHistorys") param.method = .get param.parameters = [ "current_page" : page, - "page_size" : 20 + "page_size" : pageSize ] SPNetwork.request(parameters: param) { (response: SPNetworkResponse>) in diff --git a/Thimra/Base/Networking/Base/SPURLPath.swift b/Thimra/Base/Networking/Base/SPURLPath.swift index 94f2405..61a6315 100644 --- a/Thimra/Base/Networking/Base/SPURLPath.swift +++ b/Thimra/Base/Networking/Base/SPURLPath.swift @@ -19,10 +19,10 @@ import UIKit */ #if DEBUG -let SPBaseURL = "https://test1-api.guyantv.com" -let SPURLPathPrefix = "" -//let SPBaseURL = "https://api-thimratv.thimratv.com" -//let SPURLPathPrefix = "/0a2c5b02" +//let SPBaseURL = "https://test1-api.guyantv.com" +//let SPURLPathPrefix = "" +let SPBaseURL = "https://api-thimratv.thimratv.com" +let SPURLPathPrefix = "/0a2c5b02" let SPWebBaseURL = "https://www.thimratv.com" #else @@ -33,18 +33,17 @@ let SPWebBaseURL = "https://www.thimratv.com" ///用户协议 -let SPUserAgreementWebUrl = SPWebBaseURL + "/user_policy.htm" +let SPUserAgreementWebUrl = SPWebBaseURL + "/user_policy" ///隐私协议 -let SPPrivacyPolicyWebUrl = SPWebBaseURL + "/private.htm" +let SPPrivacyPolicyWebUrl = SPWebBaseURL + "/private" ///儿童个人信息保护规则 -let SPInformationProtectionWebUrl = SPWebBaseURL + "/information_protection.html" +let SPInformationProtectionWebUrl = SPWebBaseURL + "/information_protection" ///第三方共享清单 -let SPInformationSharingWebUrl = SPWebBaseURL + "/information_sharing.html" +let SPInformationSharingWebUrl = SPWebBaseURL + "/information_sharing" ///收集个人信息明示清单 -let SPPersoInforDisclosureWebUrl = SPWebBaseURL + "/persoInfor_disclosure.html" +let SPPersoInforDisclosureWebUrl = SPWebBaseURL + "/persoInfor_disclosure" ///全国青少年互联网文明公约 -let SPCivizatioConventionWebUrl = SPWebBaseURL + "/civizatio_convention.html" -///全国青少年互联网文明公约 -let SPMemberShipAgreementWebUrl = SPWebBaseURL + "/member_ship_agreement.html" +let SPCivizatioConventionWebUrl = SPWebBaseURL + "/civizatio_convention" + diff --git a/Thimra/Base/View/SPTableViewCell.swift b/Thimra/Base/View/SPTableViewCell.swift index 84a1ccf..fd38a95 100644 --- a/Thimra/Base/View/SPTableViewCell.swift +++ b/Thimra/Base/View/SPTableViewCell.swift @@ -9,7 +9,7 @@ import UIKit class SPTableViewCell: UITableViewCell { - var indicatorMargin: CGFloat = 7.5 { + var indicatorMargin: CGFloat = 15 { didSet { indicatorImageView.snp.updateConstraints { make in make.right.equalToSuperview().offset(-indicatorMargin) @@ -24,7 +24,7 @@ class SPTableViewCell: UITableViewCell { } private(set) lazy var indicatorImageView: UIImageView = { - let imageView = UIImageView(image: UIImage(named: "right_arrow_icon_01")) + let imageView = UIImageView(image: UIImage(named: "arrow_right_icon_02")) imageView.isHidden = !showIndicator return imageView }() diff --git a/Thimra/Base/WebView/SPWebView.swift b/Thimra/Base/WebView/SPWebView.swift index c98ee8d..2696bec 100644 --- a/Thimra/Base/WebView/SPWebView.swift +++ b/Thimra/Base/WebView/SPWebView.swift @@ -12,6 +12,11 @@ class SPWebView: WKWebView { weak var delegate: SPWebViewDelegate? + private(set) var scriptMessageHandlerArray: [SPWebViewMessageName] = [ + WebMessageGetUserInfo, + ] + + deinit { self.removeObserver(self, forKeyPath: "estimatedProgress") @@ -21,7 +26,7 @@ class SPWebView: WKWebView { override init(frame: CGRect, configuration: WKWebViewConfiguration) { super.init(frame: frame, configuration: configuration) -// addScriptMessageHandler() + addScriptMessageHandler() _setupInit() } required init?(coder: NSCoder) { @@ -58,6 +63,17 @@ class SPWebView: WKWebView { self.load(request) } + func removeScriptMessageHandler() { + self.scriptMessageHandlerArray.forEach{ + configuration.userContentController.removeScriptMessageHandler(forName: $0) + } + } + func addScriptMessageHandler() { + self.scriptMessageHandlerArray.forEach{ + configuration.userContentController.add(YYWeakProxy(target: self) as! WKScriptMessageHandler, name: $0) + } + } + } //MARK:-------------- WKUIDelegate -------------- diff --git a/Thimra/Base/WebView/SPWebViewController+ScriptMessage.swift b/Thimra/Base/WebView/SPWebViewController+ScriptMessage.swift new file mode 100644 index 0000000..d722a37 --- /dev/null +++ b/Thimra/Base/WebView/SPWebViewController+ScriptMessage.swift @@ -0,0 +1,28 @@ +// +// SPWebViewController+ScriptMessage.swift +// Thimra +// +// Created by Overseas on 2025/4/24. +// + +import UIKit +import WebKit + +typealias SPWebViewMessageName = String + +///获取用户信息 +let WebMessageGetUserInfo: SPWebViewMessageName = "getUserInfo" + + +extension SPWebViewController { + + func _webViewUserContentController(didReceive message: WKScriptMessage) { + let name = message.name + let body = message.body + + +// let js = "window.returnGPSposition('{\"longitude\":\(placemark.longitude ?? 0),\"latitude\":\(placemark.latitude ?? 0)}')" +// self.webView.evaluateJavaScript(js, completionHandler: nil) + + } +} diff --git a/Thimra/Base/WebView/SPWebViewController.swift b/Thimra/Base/WebView/SPWebViewController.swift index 39d1aef..69a9d53 100644 --- a/Thimra/Base/WebView/SPWebViewController.swift +++ b/Thimra/Base/WebView/SPWebViewController.swift @@ -27,6 +27,7 @@ class SPWebViewController: SPViewController { override func viewDidLoad() { super.viewDidLoad() +// self.edgesForExtendedLayout = .top configNavigationBack() _setupUI() @@ -36,6 +37,9 @@ class SPWebViewController: SPViewController { } } + override func setBgImageView() { + self.view.backgroundColor = .backgroundColor() + } override func viewWillAppear(_ animated: Bool) { super.viewWillAppear(animated) @@ -86,4 +90,8 @@ extension SPWebViewController: SPWebViewDelegate { func webView(_ webView: SPWebView, didFailLoadWithError error: any Error) { spLog(message: error) } + + func userContentController(_ userContentController: WKUserContentController, didReceive message: WKScriptMessage) { + _webViewUserContentController(didReceive: message) + } } diff --git a/Thimra/Class/Explore/Controller/SPAllShortViewController.swift b/Thimra/Class/Explore/Controller/SPAllShortViewController.swift index 2c7114e..9d44e00 100644 --- a/Thimra/Class/Explore/Controller/SPAllShortViewController.swift +++ b/Thimra/Class/Explore/Controller/SPAllShortViewController.swift @@ -22,6 +22,16 @@ class SPAllShortViewController: SPViewController { private lazy var dataArr: [SPShortModel] = [] private lazy var page = 1 + private lazy var isOpen = false + private var tagMaxHeight: CGFloat { + var height = CGFloat(MAXFLOAT) + if !isOpen { + height = tagView.tagHeight * 2 + tagView.tagVerticalGap + } + return height + } + + //MARK: UI属性 private lazy var tagView: JXTagView = { let tagView = JXTagView() @@ -44,6 +54,34 @@ class SPAllShortViewController: SPViewController { return tagView }() + ///展开按钮边上的渐变 + private lazy var openGradientLayer: CAGradientLayer = { + let layer = CAGradientLayer() + layer.colors = [UIColor.clear.withAlphaComponent(1).cgColor, UIColor.clear.withAlphaComponent(0).cgColor] + layer.locations = [0, 1] + layer.rasterizationScale = UIScreen.main.scale + layer.startPoint = CGPoint(x: 0.7, y: 0.5) + layer.endPoint = CGPoint(x: 1, y: 1) +// layer.frame = CGRect(x: 0, y: 0, width: 100, height: tagView.height) + + return layer + }() + + private lazy var openButton: UIButton = { + let button = UIButton(type: .custom) + button.setImage(UIImage(named: "arrow_bown_icon_01"), for: .normal) + button.setImage(UIImage(named: "arrow_up_icon_01"), for: .selected) + button.setImage(UIImage(named: "arrow_up_icon_01"), for: [.selected, .highlighted]) + button.addTarget(self, action: #selector(handleOpenButton), for: .touchUpInside) + return button + }() + + private lazy var bgView: UIView = { + let view = UIView() + view.addEffectView(style: .dark) + return view + }() + private lazy var collectionViewLayout: UICollectionViewFlowLayout = { let width = floor((kSPScreenWidth - 32 - 14 * 2) / 3) let height = 145 / 105 * width + 36 @@ -56,12 +94,6 @@ class SPAllShortViewController: SPViewController { return layout }() - private lazy var bgView: UIView = { - let view = UIView() - view.addEffectView(style: .dark) - return view - }() - private lazy var collectionView: SPCollectionView = { let collectionView = SPCollectionView(frame: .zero, collectionViewLayout: collectionViewLayout) collectionView.delegate = self @@ -87,6 +119,18 @@ class SPAllShortViewController: SPViewController { _setupUI() } + override func viewDidLayoutSubviews() { + super.viewDidLayoutSubviews() + + let widht: CGFloat = 100 + let height = self.tagView.tagHeight + let x = self.tagView.width - widht + let y = self.tagView.height - height + +// openGradientLayer.frame = CGRect(x: x, y: y, width: widht, height: height) + openGradientLayer.frame = self.tagView.bounds + } + override func setBgImageView() { } @@ -102,17 +146,39 @@ class SPAllShortViewController: SPViewController { self?.collectionView.sp_endFooterRefreshing() } } + + @objc private func handleOpenButton() { + self.isOpen = !self.isOpen + + self.openButton.isSelected = self.isOpen + + tagView.snp.updateConstraints { make in + make.height.lessThanOrEqualTo(tagMaxHeight) + } + } + + } extension SPAllShortViewController { private func _setupUI() { + tagView.layer.mask = self.openGradientLayer + view.addSubview(tagView) view.addSubview(bgView) + view.addSubview(openButton) bgView.addSubview(collectionView) tagView.snp.makeConstraints { make in make.left.right.equalToSuperview() make.top.equalToSuperview().offset(kSPStatusbarHeight + 40 + 12) + make.height.lessThanOrEqualTo(tagMaxHeight) + } + + openButton.snp.makeConstraints { make in + make.right.equalToSuperview().offset(-16) + make.bottom.equalTo(tagView) + make.height.equalTo(tagView.tagHeight) } bgView.snp.makeConstraints { make in diff --git a/Thimra/Class/Mine/Controller/SPAboutUsViewController.swift b/Thimra/Class/Mine/Controller/SPAboutUsViewController.swift index e510127..515f60d 100644 --- a/Thimra/Class/Mine/Controller/SPAboutUsViewController.swift +++ b/Thimra/Class/Mine/Controller/SPAboutUsViewController.swift @@ -8,11 +8,106 @@ import UIKit class SPAboutUsViewController: SPViewController { - + + private lazy var dataArr: [SPMineItem] = { + let arr = [ + SPMineItem(type: .userAgreement, title: "User Agreement".localized), + SPMineItem(type: .privacyPolicy, title: "Privacy Policy".localized), + SPMineItem(type: .informationProtection, title: "Child Personal Information Protection Rules".localized), + SPMineItem(type: .civizatioConvention, title: "Youth Civilization Convention".localized), + SPMineItem(type: .informationSharing, title: "List of Third-Party Sharing of Personal Information".localized), + SPMineItem(type: .persoInforDisclosure, title: "Explicit List of Personal Information Collection".localized), + ] + return arr + }() + + private lazy var tableView: SPTableView = { + let tableView = SPTableView(frame: .zero, style: .plain) + tableView.delegate = self + tableView.dataSource = self + tableView.rowHeight = 50 + SPAboutUsCell.registerCell(tableView: tableView) + return tableView + }() + + private lazy var headerView: SPAboutUsHeaderView = { + let view = SPAboutUsHeaderView(frame: .init(x: 0, y: 0, width: kSPScreenWidth, height: 200)) + return view + }() + override func viewDidLoad() { super.viewDidLoad() - + self.title = "About Us".localized + + _setupUI() } + override func viewWillAppear(_ animated: Bool) { + super.viewWillAppear(animated) + self.navigationController?.setNavigationBarHidden(false, animated: true) + setNavigationNormalStyle() + } + + override func setBgImageView() { + self.view.backgroundColor = .backgroundColor() + } } + +extension SPAboutUsViewController { + private func _setupUI() { + self.tableView.tableHeaderView = self.headerView + view.addSubview(tableView) + + tableView.snp.makeConstraints { make in + make.edges.equalToSuperview() + } + } + +} + +//MARK: -------------- UITableViewDelegate & UITableViewDataSource -------------- +extension SPAboutUsViewController: UITableViewDelegate, UITableViewDataSource { + func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = SPAboutUsCell.dequeueReusableCell(tableView: tableView, indexPath: indexPath) + cell.item = dataArr[indexPath.row] + return cell + } + + func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + return dataArr.count + } + + func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { + let item = dataArr[indexPath.row] + var urlStr: String? + + switch item.type { + case .userAgreement: + urlStr = SPUserAgreementWebUrl + + case.privacyPolicy: + urlStr = SPPrivacyPolicyWebUrl + + case.informationProtection: + urlStr = SPInformationProtectionWebUrl + + case.civizatioConvention: + urlStr = SPCivizatioConventionWebUrl + + case.informationSharing: + urlStr = SPInformationSharingWebUrl + + case.persoInforDisclosure: + urlStr = SPPersoInforDisclosureWebUrl + + default: break + } + + + + let vc = SPWebViewController() + vc.urlStr = urlStr + self.navigationController?.pushViewController(vc, animated: true) + } +} diff --git a/Thimra/Class/Mine/Controller/SPMineViewController.swift b/Thimra/Class/Mine/Controller/SPMineViewController.swift index 0a3516c..5545a76 100644 --- a/Thimra/Class/Mine/Controller/SPMineViewController.swift +++ b/Thimra/Class/Mine/Controller/SPMineViewController.swift @@ -11,23 +11,26 @@ class SPMineViewController: SPViewController { private lazy var dataArr: [SPMineItem] = { let arr = [ - SPMineItem(type: .orderRecord, iconImage: UIImage(named: "order_record_icon_01"), title: "Order Record".localized), - SPMineItem(type: .language, iconImage: UIImage(named: "language_icon_01"), title: "Language".localized), +// SPMineItem(type: .language, iconImage: UIImage(named: "language_icon_01"), title: "Language".localized), SPMineItem(type: .privacyPolicy, iconImage: UIImage(named: "privacy_policy_icon_01"), title: "Privacy Policy".localized), SPMineItem(type: .userAgreement, iconImage: UIImage(named: "user_agreement_icon_01"), title: "User Agreement".localized), - SPMineItem(type: .helpCenter, iconImage: UIImage(named: "help_center_icon_01"), title: "Help Center".localized), SPMineItem(type: .aboutUs, iconImage: UIImage(named: "about_us_icon_01"), title: "About Us".localized), ] return arr }() + ///是否进入过 + private var isHaveEntered = false + + //MARK: UI 属性 private lazy var headerView: SPMineHeaderView = { - let view = SPMineHeaderView(frame: CGRect(x: 0, y: 0, width: kSPScreenWidth, height: 200)) + let view = SPMineHeaderView() + view.frame = CGRect(x: 0, y: 0, width: kSPScreenWidth, height: view.contentHeight) return view }() private lazy var tableView: SPTableView = { - let tableView = SPTableView(frame: .zero, style: .insetGrouped) + let tableView = SPTableView(frame: .zero, style: .plain) tableView.delegate = self tableView.dataSource = self tableView.rowHeight = 50 @@ -38,17 +41,35 @@ class SPMineViewController: SPViewController { override func viewDidLoad() { super.viewDidLoad() - requestUserInfo() + requestData() _setupUI() } override func viewWillAppear(_ animated: Bool) { super.viewWillAppear(animated) - self.setNavigationNormalStyle() + self.navigationController?.setNavigationBarHidden(true, animated: true) } - + override func viewDidAppear(_ animated: Bool) { + super.viewDidAppear(animated) + if isHaveEntered { + requestData() + } + + isHaveEntered = true + } + + private func updateHeaderView() { + tableView.tableHeaderView = nil + self.headerView.height = self.headerView.contentHeight + + tableView.tableHeaderView = headerView + + + } + + } extension SPMineViewController { @@ -103,11 +124,29 @@ extension SPMineViewController: UITableViewDelegate, UITableViewDataSource { extension SPMineViewController { + private func requestData() { + requestUserInfo() + requestPlayHistoryList() + } + + ///获取用户信息 private func requestUserInfo() { - - SPUserAPI.requestUserInfo { userInfo in - - + SPUserAPI.requestUserInfo { [weak self] userInfo in + guard let self = self else { return } + if let userInfo = userInfo { + self.headerView.userInfo = userInfo + } + } + } + ///获取播放记录 + private func requestPlayHistoryList() { + SPVideoAPI.requestPlayHistoryList(page: 1, pageSize: 3) { [weak self] listModel in + guard let self = self else { return } + if let list = listModel?.list { + self.headerView.playHistoryArr = list + + self.updateHeaderView() + } } } diff --git a/Thimra/Class/Mine/Model/SPMineItem.swift b/Thimra/Class/Mine/Model/SPMineItem.swift index 7f56a06..cfa0b98 100644 --- a/Thimra/Class/Mine/Model/SPMineItem.swift +++ b/Thimra/Class/Mine/Model/SPMineItem.swift @@ -21,6 +21,14 @@ struct SPMineItem { case helpCenter ///关于我们 case aboutUs + ///儿童个人信息保护规则 + case informationProtection + ///全国青少年互联网文明公约 + case civizatioConvention + ///第三方共享清单 + case informationSharing + ///收集个人信息明示清单 + case persoInforDisclosure } diff --git a/Thimra/Class/Mine/View/SPAboutUsCell.swift b/Thimra/Class/Mine/View/SPAboutUsCell.swift new file mode 100644 index 0000000..f933e29 --- /dev/null +++ b/Thimra/Class/Mine/View/SPAboutUsCell.swift @@ -0,0 +1,50 @@ +// +// SPAboutUsCell.swift +// Thimra +// +// Created by Overseas on 2025/4/23. +// + +import UIKit + +class SPAboutUsCell: SPTableViewCell { + + var item: SPMineItem? { + didSet { + titleLabel.text = item?.title + + } + } + + private lazy var titleLabel: UILabel = { + let label = UILabel() + label.font = .fontMedium(ofSize: 14) + label.textColor = .colorFFFFFF() + return label + }() + + override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) { + super.init(style: style, reuseIdentifier: reuseIdentifier) + showIndicator = true + + _setupUI() + } + + @MainActor required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + +} + +extension SPAboutUsCell { + + private func _setupUI() { + contentView.addSubview(titleLabel) + + titleLabel.snp.makeConstraints { make in + make.centerY.equalToSuperview() + make.left.equalToSuperview().offset(16) + } + } + +} diff --git a/Thimra/Class/Mine/View/SPAboutUsHeaderView.swift b/Thimra/Class/Mine/View/SPAboutUsHeaderView.swift new file mode 100644 index 0000000..f1af8b4 --- /dev/null +++ b/Thimra/Class/Mine/View/SPAboutUsHeaderView.swift @@ -0,0 +1,74 @@ +// +// SPAboutUsHeaderView.swift +// Thimra +// +// Created by Overseas on 2025/4/23. +// + +import UIKit + +class SPAboutUsHeaderView: UIView { + + + private lazy var logoImageView: UIImageView = { + let imageView = UIImageView(image: UIImage(named: "about_us_logo_icon")) + imageView.layer.cornerRadius = 8 + imageView.layer.masksToBounds = true + imageView.backgroundColor = .red + return imageView + }() + + private lazy var nameLabel: UILabel = { + let label = UILabel() + label.font = .fontBold(ofSize: 18) + label.textColor = .colorFFFFFF() + label.text = kSPAPPName + return label + }() + + private lazy var versionLabel: UILabel = { + let label = UILabel() + label.font = .fontRegular(ofSize: 12) + label.textColor = .colorFFFFFF(alpha: 0.8) + label.text = "version:\(kSPAPPVersion)" + return label + }() + + override init(frame: CGRect) { + super.init(frame: frame) + + _setupUI() + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + +} + +extension SPAboutUsHeaderView { + + private func _setupUI() { + addSubview(logoImageView) + addSubview(nameLabel) + addSubview(versionLabel) + + logoImageView.snp.makeConstraints { make in + make.centerX.equalToSuperview() + make.top.equalToSuperview().offset(40) + make.width.height.equalTo(100) + } + + nameLabel.snp.makeConstraints { make in + make.centerX.equalToSuperview() + make.top.equalTo(logoImageView.snp.bottom).offset(10) + } + + versionLabel.snp.makeConstraints { make in + make.centerX.equalToSuperview() + make.top.equalTo(nameLabel.snp.bottom).offset(5) + } + + } + +} diff --git a/Thimra/Class/Mine/View/SPMineCell.swift b/Thimra/Class/Mine/View/SPMineCell.swift index 614c2d8..499678e 100644 --- a/Thimra/Class/Mine/View/SPMineCell.swift +++ b/Thimra/Class/Mine/View/SPMineCell.swift @@ -23,15 +23,15 @@ class SPMineCell: SPTableViewCell { private lazy var titleLabel: UILabel = { let label = UILabel() - label.font = .fontRegular(ofSize: 14) - label.textColor = .colorFFFFFF(alpha: 0.9) + label.font = .fontMedium(ofSize: 16) + label.textColor = .colorFFFFFF() return label }() override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) { super.init(style: style, reuseIdentifier: reuseIdentifier) - - self.contentView.backgroundColor = .colorFFFFFF(alpha: 0.04) + showIndicator = true +// self.contentView.backgroundColor = .colorFFFFFF(alpha: 0.04) _setupUI() @@ -51,12 +51,12 @@ extension SPMineCell { iconImageView.snp.makeConstraints { make in make.centerY.equalToSuperview() - make.left.equalToSuperview().offset(10) + make.left.equalToSuperview().offset(16) } titleLabel.snp.makeConstraints { make in make.centerY.equalToSuperview() - make.left.equalToSuperview().offset(40) + make.left.equalToSuperview().offset(46) } } diff --git a/Thimra/Class/Mine/View/SPMineHeaderView.swift b/Thimra/Class/Mine/View/SPMineHeaderView.swift index c4c1f52..7619456 100644 --- a/Thimra/Class/Mine/View/SPMineHeaderView.swift +++ b/Thimra/Class/Mine/View/SPMineHeaderView.swift @@ -8,7 +8,145 @@ import UIKit class SPMineHeaderView: UIView { + + var contentHeight: CGFloat { + var height: CGFloat = kSPStatusbarHeight + 108 + + if playHistoryArr?.count ?? 0 > 0 { + height += playHistoryView.contentHeight + height += 10 + } + + return height + } + + var userInfo: SPUserInfo? { + didSet { + avatarImageView.sp_setImage(url: userInfo?.avator, placeholder: UIImage(named: "avatar_image_01")) + + if let name = userInfo?.family_name, name.count > 0 { + nicknameLabel.text = name + } else { + nicknameLabel.text = "Vistor" + } + idLabel.text = "ID \(userInfo?.customer_id ?? "")" + } + } + + var playHistoryArr: [SPShortModel]? { + didSet { + stackView.removeAllArrangedSubview() + + if let arr = playHistoryArr, arr.count > 0 { + stackView.addArrangedSubview(playHistoryView) + } + + playHistoryView.dataArr = playHistoryArr + } + } + //MARK: UI属性 + private lazy var avatarImageView: SPImageView = { + let imageView = SPImageView(image: UIImage(named: "avatar_image_01")) + imageView.layer.cornerRadius = 31 + imageView.layer.masksToBounds = true + imageView.layer.borderColor = UIColor.colorFFFFFF(alpha: 0.3).cgColor + imageView.layer.borderWidth = 2 + return imageView + }() + + private lazy var nicknameLabel: UILabel = { + let label = UILabel() + label.font = .fontMedium(ofSize: 16) + label.textColor = .colorFFFFFF() + return label + }() + + private lazy var idLabel: UILabel = { + let label = UILabel() + label.font = .fontRegular(ofSize: 14) + label.textColor = .color8B6C6C() + return label + }() + + private lazy var copyButton: UIButton = { + let button = UIButton(type: .custom) + button.setTitle("Copy".localized, for: .normal) + button.setTitleColor(.colorFFFFFF(), for: .normal) + button.titleLabel?.font = .fontRegular(ofSize: 12) + button.setBackgroundImage(UIImage(color: .color58484B(alpha: 0.56)), for: .normal) + button.layer.cornerRadius = 2 + button.layer.masksToBounds = true + button.addTarget(self, action: #selector(handleCopyButton), for: .touchUpInside) + return button + }() + + private lazy var stackView: UIStackView = { + let view = UIStackView() + view.axis = .vertical + return view + }() + + private lazy var playHistoryView: SPMinePlayHistoryView = { + let view = SPMinePlayHistoryView() + return view + }() + override init(frame: CGRect) { + super.init(frame: frame) + _setupUI() + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + @objc private func handleCopyButton() { + SPAPPTool.copy(text: userInfo?.customer_id) + + } + +} + +extension SPMineHeaderView { + + private func _setupUI() { + addSubview(avatarImageView) + addSubview(nicknameLabel) + addSubview(idLabel) + addSubview(copyButton) + addSubview(stackView) + + avatarImageView.snp.makeConstraints { make in + make.left.equalToSuperview().offset(16) + make.top.equalToSuperview().offset(kSPStatusbarHeight + 22) + make.width.height.equalTo(62) + } + + nicknameLabel.snp.makeConstraints { make in + make.left.equalTo(avatarImageView.snp.right).offset(15) + make.top.equalTo(avatarImageView).offset(9) + } + + idLabel.snp.makeConstraints { make in + make.left.equalTo(nicknameLabel) + make.top.equalTo(nicknameLabel.snp.bottom).offset(6) + } + + let copyWidth = (copyButton.currentTitle?.size(font: copyButton.titleLabel?.font ?? .fontRegular(ofSize: 12)).width ?? 0) + 8 + + copyButton.snp.makeConstraints { make in + make.centerY.equalTo(idLabel) + make.left.equalTo(idLabel.snp.right).offset(6) + make.height.equalTo(18) + make.width.equalTo(copyWidth) + } + + stackView.snp.makeConstraints { make in + make.left.right.equalToSuperview() + make.top.equalToSuperview().offset(kSPStatusbarHeight + 108) + } + } + } diff --git a/Thimra/Class/Mine/View/SPMinePlayHistoryCell.swift b/Thimra/Class/Mine/View/SPMinePlayHistoryCell.swift new file mode 100644 index 0000000..eef7bb2 --- /dev/null +++ b/Thimra/Class/Mine/View/SPMinePlayHistoryCell.swift @@ -0,0 +1,86 @@ +// +// SPMinePlayHistoryCell.swift +// Thimra +// +// Created by Overseas on 2025/4/23. +// + +import UIKit + +class SPMinePlayHistoryCell: SPCollectionViewCell { + + var model: SPShortModel? { + didSet { + coverImageView.sp_setImage(url: model?.image_url) + titleLabel.text = model?.name + + let episode_total = "\(model?.episode_total ?? 0)" + let episode = String(format: "EP.%@/%@", "\(model?.current_episode ?? "0")", episode_total) + + let episodeString = NSMutableAttributedString(string: episode) + episodeString.color = .colorE6334B() + + let range = NSRange(location: episode.length() - episode_total.length(), length: episode_total.length()) + episodeString.setColor(.colorAFAFAF(), range: range) + episodeLabel.attributedText = episodeString + } + } + + //MARK: UI属性 + private lazy var coverImageView: SPImageView = { + let imageView = SPImageView() + imageView.layer.cornerRadius = 4 + imageView.layer.masksToBounds = true + return imageView + }() + + private lazy var titleLabel: UILabel = { + let label = UILabel() + label.font = .fontMedium(ofSize: 12) + label.textColor = .colorAFAFAF() + label.numberOfLines = 2 + return label + }() + + private lazy var episodeLabel: UILabel = { + let label = UILabel() + label.font = .fontMedium(ofSize: 12) + return label + }() + + override init(frame: CGRect) { + super.init(frame: frame) + + _setupUI() + } + + @MainActor required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } +} + +extension SPMinePlayHistoryCell { + + private func _setupUI() { + contentView.addSubview(coverImageView) + contentView.addSubview(titleLabel) + contentView.addSubview(episodeLabel) + + coverImageView.snp.makeConstraints { make in + make.left.right.top.equalToSuperview() + make.bottom.equalToSuperview().offset(-58) + } + + titleLabel.snp.makeConstraints { make in + make.left.equalToSuperview() + make.right.lessThanOrEqualToSuperview() + make.top.equalTo(coverImageView.snp.bottom).offset(12) + } + + episodeLabel.snp.makeConstraints { make in + make.left.equalToSuperview() + make.top.equalTo(titleLabel.snp.bottom).offset(4) + } + } + +} diff --git a/Thimra/Class/Mine/View/SPMinePlayHistoryView.swift b/Thimra/Class/Mine/View/SPMinePlayHistoryView.swift new file mode 100644 index 0000000..a7f4462 --- /dev/null +++ b/Thimra/Class/Mine/View/SPMinePlayHistoryView.swift @@ -0,0 +1,139 @@ +// +// SPMinePlayHistoryView.swift +// Thimra +// +// Created by Overseas on 2025/4/23. +// + +import UIKit + +class SPMinePlayHistoryView: UIView { + + var contentHeight: CGFloat { + return collectionViewLayout.itemSize.height + 20 + 12 + } + + override var intrinsicContentSize: CGSize { + return CGSize(width: kSPScreenWidth, height: contentHeight) + } + + var dataArr: [SPShortModel]? { + didSet { + self.collectionView.reloadData() + } + } + + //MARK: UI属性 + private lazy var titleIconImageView: UIImageView = { + let imageView = UIImageView(image: UIImage(named: "history_icon_01")) + return imageView + }() + + private lazy var titleLabel: UILabel = { + let label = UILabel() + label.font = .fontMedium(ofSize: 16) + label.textColor = .colorFFFFFF() + label.text = "Watch History".localized + return label + }() + + private lazy var moreButton: UIButton = { + let button = UIButton(type: .custom) + button.setImage(UIImage(named: "arrow_right_icon_02"), for: .normal) + button.addTarget(self, action: #selector(handleMoreButton), for: .touchUpInside) + return button + }() + + private lazy var collectionViewLayout: UICollectionViewFlowLayout = { + let width = floor((kSPScreenWidth - 32 - 16) / 3) + let height = 145 / 109 * width + 58 + + let layout = UICollectionViewFlowLayout() + layout.itemSize = CGSize(width: width, height: height) + layout.minimumLineSpacing = 8 + layout.minimumInteritemSpacing = 8 + layout.sectionInset = .init(top: 0, left: 16, bottom: 0, right: 16) + return layout + }() + + private lazy var collectionView: SPCollectionView = { + let collectionView = SPCollectionView(frame: .zero, collectionViewLayout: collectionViewLayout) + collectionView.delegate = self + collectionView.dataSource = self + collectionView.isScrollEnabled = false + SPMinePlayHistoryCell.registerCell(collectionView: collectionView) + return collectionView + }() + + override init(frame: CGRect) { + super.init(frame: frame) + + _setupUI() + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + @objc private func handleMoreButton() { + SPAPPTool.mainTabBarController?.onPlayHistory() + } + +} + +extension SPMinePlayHistoryView { + + private func _setupUI() { + addSubview(titleIconImageView) + addSubview(titleLabel) + addSubview(moreButton) + addSubview(collectionView) + + titleIconImageView.snp.makeConstraints { make in + make.left.equalToSuperview().offset(16) + make.top.equalToSuperview() + } + + titleLabel.snp.makeConstraints { make in + make.centerY.equalTo(titleIconImageView) + make.left.equalTo(titleIconImageView.snp.right).offset(12) + } + + moreButton.snp.makeConstraints { make in + make.centerY.equalTo(titleIconImageView) + make.right.equalToSuperview().offset(-3) + make.width.equalTo(40) + make.height.equalTo(40) + } + + collectionView.snp.makeConstraints { make in + make.left.right.bottom.equalToSuperview() + make.height.equalTo(self.collectionViewLayout.itemSize.height) + } + + } + +} + +//MARK: -------------- UICollectionViewDelegate & UICollectionViewDataSource -------------- +extension SPMinePlayHistoryView: UICollectionViewDelegate, UICollectionViewDataSource { + + func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { + let cell = SPMinePlayHistoryCell.dequeueReusableCell(collectionView: collectionView, indexPath: indexPath) + cell.model = self.dataArr?[indexPath.row] + return cell + } + + func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { + return dataArr?.count ?? 0 + } + + func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) { + let model = self.dataArr?[indexPath.row] + + let vc = SPPlayerDetailViewController() + vc.shortPlayId = model?.short_play_id + vc.playHistoryModel = model + self.viewController?.navigationController?.pushViewController(vc, animated: true) + } +} diff --git a/Thimra/Class/MyList/Controller/SPMyListViewController.swift b/Thimra/Class/MyList/Controller/SPMyListViewController.swift index 1ac10ff..e89ba93 100644 --- a/Thimra/Class/MyList/Controller/SPMyListViewController.swift +++ b/Thimra/Class/MyList/Controller/SPMyListViewController.swift @@ -46,7 +46,7 @@ class SPMyListViewController: SPViewController { } //MARK: UI属性 - private lazy var pageView: JYPageController = { + private(set) lazy var pageView: JYPageController = { let pageView = JYPageController() pageView.delegate = self pageView.dataSource = self diff --git a/Thimra/Class/Player/Controller/SPPlayerListViewController.swift b/Thimra/Class/Player/Controller/SPPlayerListViewController.swift index aa51419..dcbbeb2 100644 --- a/Thimra/Class/Player/Controller/SPPlayerListViewController.swift +++ b/Thimra/Class/Player/Controller/SPPlayerListViewController.swift @@ -210,7 +210,9 @@ extension SPPlayerListViewController { collectionView.snp.makeConstraints { make in // make.edges.equalToSuperview() - make.center.equalToSuperview() +// make.center.equalToSuperview() + make.top.equalToSuperview() + make.left.equalToSuperview() make.width.equalTo(self.contentSize.width) make.height.equalTo(self.contentSize.height) } diff --git a/Thimra/Libs/APPTool/SPAPPTool.swift b/Thimra/Libs/APPTool/SPAPPTool.swift index 74f2934..bcfa1cd 100644 --- a/Thimra/Libs/APPTool/SPAPPTool.swift +++ b/Thimra/Libs/APPTool/SPAPPTool.swift @@ -9,6 +9,8 @@ import UIKit class SPAPPTool: NSObject { + static var mainTabBarController: SPTabBarController? + static func getAppDelegate() -> AppDelegate? { return UIApplication.shared.delegate as? AppDelegate } @@ -76,6 +78,7 @@ extension SPAPPTool { if let text = text { let copy = UIPasteboard.general copy.string = text + SPToast.show(text: "Succeed".localized) } } diff --git a/Thimra/Libs/Player/SPPlayer.swift b/Thimra/Libs/Player/SPPlayer.swift index 8f71aaf..2edbf65 100644 --- a/Thimra/Libs/Player/SPPlayer.swift +++ b/Thimra/Libs/Player/SPPlayer.swift @@ -228,18 +228,18 @@ extension SPPlayer { } else if loadState == .playable, isPlaying, self.player.playState != .playStatePlaying { self.start() } - switch loadState { - case .prepare: - spLog(message: "加载状态====准备完成") - case .playable: - spLog(message: "加载状态====可播放") - case .playthroughOK: - spLog(message: "加载状态====将自动播放") - case .stalled: - spLog(message: "加载状态====如果已启动,将自动暂停") - default: - break - } +// switch loadState { +// case .prepare: +// spLog(message: "加载状态====准备完成") +// case .playable: +// spLog(message: "加载状态====可播放") +// case .playthroughOK: +// spLog(message: "加载状态====将自动播放") +// case .stalled: +// spLog(message: "加载状态====如果已启动,将自动暂停") +// default: +// break +// } } //错误信息 diff --git a/Thimra/Source/Assets.xcassets/AppIcon.appiconset/APP图标 (1).jpg b/Thimra/Source/Assets.xcassets/AppIcon.appiconset/APP图标 (1).jpg new file mode 100644 index 0000000..3470a23 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/AppIcon.appiconset/APP图标 (1).jpg differ diff --git a/Thimra/Source/Assets.xcassets/AppIcon.appiconset/Contents.json b/Thimra/Source/Assets.xcassets/AppIcon.appiconset/Contents.json index 2305880..0efd27a 100644 --- a/Thimra/Source/Assets.xcassets/AppIcon.appiconset/Contents.json +++ b/Thimra/Source/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -1,28 +1,7 @@ { "images" : [ { - "idiom" : "universal", - "platform" : "ios", - "size" : "1024x1024" - }, - { - "appearances" : [ - { - "appearance" : "luminosity", - "value" : "dark" - } - ], - "idiom" : "universal", - "platform" : "ios", - "size" : "1024x1024" - }, - { - "appearances" : [ - { - "appearance" : "luminosity", - "value" : "tinted" - } - ], + "filename" : "APP图标 (1).jpg", "idiom" : "universal", "platform" : "ios", "size" : "1024x1024" diff --git a/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/About Us@2x.png b/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/About Us@2x.png deleted file mode 100644 index efea7c3..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/About Us@2x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/About Us@3x.png b/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/About Us@3x.png deleted file mode 100644 index b84fc69..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/About Us@3x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Contents.json index 58cc5d3..5c4d3b1 100644 --- a/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Contents.json +++ b/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Contents.json @@ -5,12 +5,12 @@ "scale" : "1x" }, { - "filename" : "About Us@2x.png", + "filename" : "Frame@2x.png", "idiom" : "universal", "scale" : "2x" }, { - "filename" : "About Us@3x.png", + "filename" : "Frame@3x.png", "idiom" : "universal", "scale" : "3x" } diff --git a/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Frame@2x.png b/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Frame@2x.png new file mode 100644 index 0000000..41206d5 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Frame@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Frame@3x.png b/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Frame@3x.png new file mode 100644 index 0000000..166e1b6 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/about_us_icon_01.imageset/Frame@3x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/about_us_logo_icon.imageset/APP图标 (1).jpg b/Thimra/Source/Assets.xcassets/icon/about_us_logo_icon.imageset/APP图标 (1).jpg new file mode 100644 index 0000000..34ac40b Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/about_us_logo_icon.imageset/APP图标 (1).jpg differ diff --git a/Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/about_us_logo_icon.imageset/Contents.json similarity index 76% rename from Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Contents.json rename to Thimra/Source/Assets.xcassets/icon/about_us_logo_icon.imageset/Contents.json index f6a1eb0..d41a3b7 100644 --- a/Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Contents.json +++ b/Thimra/Source/Assets.xcassets/icon/about_us_logo_icon.imageset/Contents.json @@ -5,12 +5,11 @@ "scale" : "1x" }, { - "filename" : "Help Center@2x.png", + "filename" : "APP图标 (1).jpg", "idiom" : "universal", "scale" : "2x" }, { - "filename" : "Help Center@3x.png", "idiom" : "universal", "scale" : "3x" } diff --git a/Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Contents.json similarity index 76% rename from Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Contents.json rename to Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Contents.json index 3760e29..5c4d3b1 100644 --- a/Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Contents.json +++ b/Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Contents.json @@ -5,12 +5,12 @@ "scale" : "1x" }, { - "filename" : "Order Record@2x.png", + "filename" : "Frame@2x.png", "idiom" : "universal", "scale" : "2x" }, { - "filename" : "Order Record@3x.png", + "filename" : "Frame@3x.png", "idiom" : "universal", "scale" : "3x" } diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Frame@2x.png b/Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Frame@2x.png new file mode 100644 index 0000000..622c749 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Frame@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Frame@3x.png b/Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Frame@3x.png new file mode 100644 index 0000000..73fc2f2 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/arrow_bown_icon_01.imageset/Frame@3x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_left_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/arrow_left_icon_01.imageset/Contents.json index 397dc97..0e8f4d8 100644 --- a/Thimra/Source/Assets.xcassets/icon/arrow_left_icon_01.imageset/Contents.json +++ b/Thimra/Source/Assets.xcassets/icon/arrow_left_icon_01.imageset/Contents.json @@ -18,5 +18,8 @@ "info" : { "author" : "xcode", "version" : 1 + }, + "properties" : { + "template-rendering-intent" : "original" } } diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Contents.json new file mode 100644 index 0000000..5c4d3b1 --- /dev/null +++ b/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Contents.json @@ -0,0 +1,22 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Frame@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Frame@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Frame@2x.png b/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Frame@2x.png new file mode 100644 index 0000000..2827875 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Frame@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Frame@3x.png b/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Frame@3x.png new file mode 100644 index 0000000..35c4f63 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/arrow_right_icon_02.imageset/Frame@3x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Contents.json new file mode 100644 index 0000000..5c4d3b1 --- /dev/null +++ b/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Contents.json @@ -0,0 +1,22 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Frame@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Frame@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Frame@2x.png b/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Frame@2x.png new file mode 100644 index 0000000..44275b9 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Frame@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Frame@3x.png b/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Frame@3x.png new file mode 100644 index 0000000..e1a2774 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/arrow_up_icon_01.imageset/Frame@3x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Help Center@2x.png b/Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Help Center@2x.png deleted file mode 100644 index 3f11205..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Help Center@2x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Help Center@3x.png b/Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Help Center@3x.png deleted file mode 100644 index 955c51e..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/help_center_icon_01.imageset/Help Center@3x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Contents.json new file mode 100644 index 0000000..5c4d3b1 --- /dev/null +++ b/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Contents.json @@ -0,0 +1,22 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Frame@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Frame@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Frame@2x.png b/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Frame@2x.png new file mode 100644 index 0000000..c62bdeb Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Frame@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Frame@3x.png b/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Frame@3x.png new file mode 100644 index 0000000..cbbad1f Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/history_icon_01.imageset/Frame@3x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Contents.json index 20461fd..6a4d508 100644 --- a/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Contents.json +++ b/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Contents.json @@ -5,12 +5,12 @@ "scale" : "1x" }, { - "filename" : "Language@2x.png", + "filename" : "Vector@2x.png", "idiom" : "universal", "scale" : "2x" }, { - "filename" : "Language@3x.png", + "filename" : "Vector@3x.png", "idiom" : "universal", "scale" : "3x" } diff --git a/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Language@2x.png b/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Language@2x.png deleted file mode 100644 index 616ea5c..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Language@2x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Language@3x.png b/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Language@3x.png deleted file mode 100644 index 4be9fd4..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Language@3x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Vector@2x.png b/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Vector@2x.png new file mode 100644 index 0000000..cd118b3 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Vector@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Vector@3x.png b/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Vector@3x.png new file mode 100644 index 0000000..c809f1d Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/language_icon_01.imageset/Vector@3x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Order Record@2x.png b/Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Order Record@2x.png deleted file mode 100644 index 7c0c4ab..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Order Record@2x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Order Record@3x.png b/Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Order Record@3x.png deleted file mode 100644 index 05b3d25..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/order_record_icon_01.imageset/Order Record@3x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Contents.json index 8a1e1bf..5c4d3b1 100644 --- a/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Contents.json +++ b/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Contents.json @@ -5,12 +5,12 @@ "scale" : "1x" }, { - "filename" : "Privacy Policy@2x.png", + "filename" : "Frame@2x.png", "idiom" : "universal", "scale" : "2x" }, { - "filename" : "Privacy Policy@3x.png", + "filename" : "Frame@3x.png", "idiom" : "universal", "scale" : "3x" } diff --git a/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Frame@2x.png b/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Frame@2x.png new file mode 100644 index 0000000..b564c89 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Frame@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Frame@3x.png b/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Frame@3x.png new file mode 100644 index 0000000..144ab45 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Frame@3x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Privacy Policy@2x.png b/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Privacy Policy@2x.png deleted file mode 100644 index 50e814f..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Privacy Policy@2x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Privacy Policy@3x.png b/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Privacy Policy@3x.png deleted file mode 100644 index 266aab3..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/privacy_policy_icon_01.imageset/Privacy Policy@3x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Contents.json index 481be51..5c4d3b1 100644 --- a/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Contents.json +++ b/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Contents.json @@ -5,12 +5,12 @@ "scale" : "1x" }, { - "filename" : "User Agreement@2x.png", + "filename" : "Frame@2x.png", "idiom" : "universal", "scale" : "2x" }, { - "filename" : "User Agreement@3x.png", + "filename" : "Frame@3x.png", "idiom" : "universal", "scale" : "3x" } diff --git a/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Frame@2x.png b/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Frame@2x.png new file mode 100644 index 0000000..f2c0fa9 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Frame@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Frame@3x.png b/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Frame@3x.png new file mode 100644 index 0000000..6599f2c Binary files /dev/null and b/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/Frame@3x.png differ diff --git a/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/User Agreement@2x.png b/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/User Agreement@2x.png deleted file mode 100644 index 2f24541..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/User Agreement@2x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/User Agreement@3x.png b/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/User Agreement@3x.png deleted file mode 100644 index 2658c6b..0000000 Binary files a/Thimra/Source/Assets.xcassets/icon/user_agreement_icon_01.imageset/User Agreement@3x.png and /dev/null differ diff --git a/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Contents.json b/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Contents.json new file mode 100644 index 0000000..19895f8 --- /dev/null +++ b/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Contents.json @@ -0,0 +1,22 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Frame 1912056660@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Frame 1912056660@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Frame 1912056660@2x.png b/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Frame 1912056660@2x.png new file mode 100644 index 0000000..da8eff9 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Frame 1912056660@2x.png differ diff --git a/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Frame 1912056660@3x.png b/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Frame 1912056660@3x.png new file mode 100644 index 0000000..16b6a86 Binary files /dev/null and b/Thimra/Source/Assets.xcassets/image/avatar_image_01.imageset/Frame 1912056660@3x.png differ diff --git a/Thimra/Source/en.lproj/Localizable.strings b/Thimra/Source/en.lproj/Localizable.strings index 6fc5224..6765d13 100644 --- a/Thimra/Source/en.lproj/Localizable.strings +++ b/Thimra/Source/en.lproj/Localizable.strings @@ -20,11 +20,9 @@ "Episodes" = "Episodes"; "Save" = "Save"; "Added" = "Added"; -"Order Record" = "Order Record"; "Language" = "Language"; "Privacy Policy" = "Privacy Policy"; "User Agreement" = "User Agreement"; -"Help Center" = "Help Center"; "About Us" = "About Us"; "My list" = "My list"; "Watch list" = "Watch list"; @@ -44,5 +42,12 @@ "All" = "All"; "Shorts" = "Shorts"; "EP.%@" = "EP.%@"; +"Copy" = "Copy"; +"Succeed" = "Succeed"; +"Watch History" = "Watch History"; +"Child Personal Information Protection Rules" = "Child Personal Information Protection Rules"; +"Youth Civilization Convention" = "Youth Civilization Convention"; +"List of Third-Party Sharing of Personal Information" = "List of Third-Party Sharing of Personal Information"; +"Explicit List of Personal Information Collection" = "Explicit List of Personal Information Collection";