From 8a95563976579af9841fb97724ebca28bc045e8f Mon Sep 17 00:00:00 2001 From: CMK Date: Mon, 18 Apr 2022 10:39:28 +0800 Subject: [PATCH] chore: use fixed height searchBar --- Mastodon/Scene/Search/Search/SearchViewController.swift | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Mastodon/Scene/Search/Search/SearchViewController.swift b/Mastodon/Scene/Search/Search/SearchViewController.swift index 7594eb47..982844f5 100644 --- a/Mastodon/Scene/Search/Search/SearchViewController.swift +++ b/Mastodon/Scene/Search/Search/SearchViewController.swift @@ -15,7 +15,7 @@ import MastodonLocalization final class HeightFixedSearchBar: UISearchBar { override var intrinsicContentSize: CGSize { - return CGSize(width: CGFloat.greatestFiniteMagnitude, height: CGFloat.greatestFiniteMagnitude) + return CGSize(width: CGFloat.greatestFiniteMagnitude, height: 36) } } @@ -179,14 +179,14 @@ extension SearchViewController: UISearchControllerDelegate { //extension SearchViewController: UICollectionViewDelegate { // func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) { // logger.log(level: .debug, "\((#file as NSString).lastPathComponent, privacy: .public)[\(#line, privacy: .public)], \(#function, privacy: .public): select item at: \(indexPath.debugDescription)") -// +// // defer { // collectionView.deselectItem(at: indexPath, animated: true) // } -// +// // guard let diffableDataSource = viewModel.diffableDataSource else { return } // guard let item = diffableDataSource.itemIdentifier(for: indexPath) else { return } -// +// // switch item { // case .trend(let hashtag): // let viewModel = HashtagTimelineViewModel(context: context, hashtag: hashtag.name)