From 30c378018e7d52f43758badc1e25dde4fd381a8a Mon Sep 17 00:00:00 2001 From: baegteun Date: Sun, 8 Dec 2024 14:47:56 +0900 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=A8=20::=20=EC=BD=94=EB=93=9C=20Format?= =?UTF-8?q?ting=20=EC=A0=81=EC=9A=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../FAQ/FaqContentViewController.swift | 10 +++++++--- .../Views/FAQAnswerTableViewCell.swift | 20 +++++++++---------- 2 files changed, 17 insertions(+), 13 deletions(-) diff --git a/Projects/Features/MyInfoFeature/Sources/ViewControllers/FAQ/FaqContentViewController.swift b/Projects/Features/MyInfoFeature/Sources/ViewControllers/FAQ/FaqContentViewController.swift index f1307eb95..596c91dd5 100644 --- a/Projects/Features/MyInfoFeature/Sources/ViewControllers/FAQ/FaqContentViewController.swift +++ b/Projects/Features/MyInfoFeature/Sources/ViewControllers/FAQ/FaqContentViewController.swift @@ -9,7 +9,7 @@ import Utility public final class FaqContentViewController: UIViewController, ViewControllerFromStoryBoard { @IBOutlet weak var tableView: UITableView! - var viewModel: FAQContentViewModel! + var viewModel: FAQContentViewModel! override public func viewDidLoad() { super.viewDidLoad() @@ -71,12 +71,16 @@ extension FaqContentViewController: UITableViewDataSource { public func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { guard let questionCell = tableView - .dequeueReusableCell(withIdentifier: "FAQQuestionTableViewCell", for: indexPath) as? FAQQuestionTableViewCell + .dequeueReusableCell( + withIdentifier: "FAQQuestionTableViewCell", + for: indexPath + ) as? FAQQuestionTableViewCell else { return UITableViewCell() } guard let answerCell = tableView - .dequeueReusableCell(withIdentifier: "FAQAnswerTableViewCell", for: indexPath) as? FAQAnswerTableViewCell else { + .dequeueReusableCell(withIdentifier: "FAQAnswerTableViewCell", for: indexPath) as? FAQAnswerTableViewCell + else { return UITableViewCell() } diff --git a/Projects/Features/MyInfoFeature/Sources/Views/FAQAnswerTableViewCell.swift b/Projects/Features/MyInfoFeature/Sources/Views/FAQAnswerTableViewCell.swift index 39592a265..fc90fb4d7 100644 --- a/Projects/Features/MyInfoFeature/Sources/Views/FAQAnswerTableViewCell.swift +++ b/Projects/Features/MyInfoFeature/Sources/Views/FAQAnswerTableViewCell.swift @@ -7,17 +7,17 @@ final class FAQAnswerTableViewCell: UITableViewCell { override func awakeFromNib() { super.awakeFromNib() - if Thread.isMainThread { - MainActor.assumeIsolated { - answerLabel.font = DesignSystemFontFamily.Pretendard.medium.font(size: 14) - answerLabel.setTextWithAttributes(kernValue: -0.5, lineSpacing: 6) + if Thread.isMainThread { + MainActor.assumeIsolated { + answerLabel.font = DesignSystemFontFamily.Pretendard.medium.font(size: 14) + answerLabel.setTextWithAttributes(kernValue: -0.5, lineSpacing: 6) + } + } else { + Task { @MainActor in + answerLabel.font = DesignSystemFontFamily.Pretendard.medium.font(size: 14) + answerLabel.setTextWithAttributes(kernValue: -0.5, lineSpacing: 6) + } } - } else { - Task { @MainActor in - answerLabel.font = DesignSystemFontFamily.Pretendard.medium.font(size: 14) - answerLabel.setTextWithAttributes(kernValue: -0.5, lineSpacing: 6) - } - } } }