From ffeba748c15aa1912b273eeebc1c961f50a924bb Mon Sep 17 00:00:00 2001 From: brave-builds Date: Fri, 20 Sep 2024 17:31:50 +0000 Subject: [PATCH] Uplift of #25675 (squashed) to beta --- .../ShieldsPrivacy/FilterLists/FilterListsView.swift | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ios/brave-ios/Sources/Brave/Frontend/Settings/Features/ShieldsPrivacy/FilterLists/FilterListsView.swift b/ios/brave-ios/Sources/Brave/Frontend/Settings/Features/ShieldsPrivacy/FilterLists/FilterListsView.swift index 45fc52f3134d..94be7d19e6d8 100644 --- a/ios/brave-ios/Sources/Brave/Frontend/Settings/Features/ShieldsPrivacy/FilterLists/FilterListsView.swift +++ b/ios/brave-ios/Sources/Brave/Frontend/Settings/Features/ShieldsPrivacy/FilterLists/FilterListsView.swift @@ -216,7 +216,7 @@ struct FilterListsView: View { } @ViewBuilder private var defaultFilterListRows: some View { - let searchText = searchText.lowercased() + let searchText = searchText #if DEBUG let allEnabled = Binding { filterListStorage.filterLists.allSatisfy({ @@ -385,13 +385,14 @@ struct FilterListsView_Previews: PreviewProvider { extension FilterList { fileprivate func satisfies(searchText: String) -> Bool { guard !searchText.isEmpty else { return true } - return entry.title.contains(searchText) || entry.desc.contains(searchText) + return entry.title.localizedCaseInsensitiveContains(searchText) + || entry.desc.localizedCaseInsensitiveContains(searchText) } } extension FilterListCustomURL { @MainActor fileprivate func satisfies(searchText: String) -> Bool { guard !searchText.isEmpty else { return true } - return setting.externalURL.absoluteString.contains(searchText) + return setting.externalURL.absoluteString.localizedCaseInsensitiveContains(searchText) } }