Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump sdk + Favourites filters implementation #2484

Merged
merged 3 commits into from
Feb 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ElementX.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -6781,7 +6781,7 @@
repositoryURL = "https://github.com/matrix-org/matrix-rust-components-swift";
requirement = {
kind = exactVersion;
version = 1.1.40;
version = 1.1.41;
};
};
821C67C9A7F8CC3FD41B28B4 /* XCRemoteSwiftPackageReference "emojibase-bindings" */ = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/matrix-org/matrix-rust-components-swift",
"state" : {
"revision" : "c0101eb908a7a1afd2f1c099472f7e8526a2ac45",
"version" : "1.1.40"
"revision" : "d773c12e46b01b6512b9b3581268093c8ba4d55d",
"version" : "1.1.41"
}
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ enum RoomListFilter: Int, CaseIterable, Identifiable {
}
}

var rustFilter: RoomListEntriesDynamicFilterKind? {
var rustFilter: RoomListEntriesDynamicFilterKind {
switch self {
case .people:
return .category(expect: .people)
Expand All @@ -65,8 +65,7 @@ enum RoomListFilter: Int, CaseIterable, Identifiable {
case .unreads:
return .unread
case .favourites:
// Not implemented yet
return nil
return .favourite
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ class RoomSummaryProvider: RoomSummaryProviderProtocol {
case .excludeAll:
_ = listUpdatesSubscriptionResult?.controller.setFilter(kind: .none)
case let .include(predicate):
var filters = predicate.filters.compactMap(\.rustFilter)
var filters = predicate.filters.map(\.rustFilter)
if let query = predicate.query {
filters.append(.normalizedMatchRoomName(pattern: query.lowercased()))
}
Expand Down
1 change: 1 addition & 0 deletions changelog.d/pr-2484.wip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Favourite filter implemented.
2 changes: 1 addition & 1 deletion project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ packages:
# Element/Matrix dependencies
MatrixRustSDK:
url: https://github.com/matrix-org/matrix-rust-components-swift
exactVersion: 1.1.40
exactVersion: 1.1.41
# path: ../matrix-rust-sdk
Compound:
url: https://github.com/element-hq/compound-ios
Expand Down
Loading