Skip to content

Feat/federated nodes#2

Merged
AdamLBS merged 3 commits intomainfrom
feat/federated-nodes
Apr 26, 2026
Merged

Feat/federated nodes#2
AdamLBS merged 3 commits intomainfrom
feat/federated-nodes

Conversation

@AdamLBS
Copy link
Copy Markdown
Contributor

@AdamLBS AdamLBS commented Apr 26, 2026

This pull request introduces support for federated (cross-node) chat sessions in the app, along with UI improvements to distinguish federated chats and various code refactors to support these features. The main changes include updating session creation to handle federated addresses, enhancing the ChatView model to represent federated chats, updating the user list to prevent duplicate conversations, and improving the UI to clearly indicate external chats.

Federation support and session creation:

  • The createSession function now accepts an optional recipientUserAddress for federated users, fetches device keys via a proxy endpoint when needed, and treats HTTP 202 as a successful session initiation. [1] [2] [3] [4]
  • The session payload and device handling have been updated to support federated users, and the UserDevice model adds a fromFederatedJson constructor to handle federated device formats. [1] [2]

Model enhancements for federated chats:

  • ChatView now includes a federatedAddress field, an isRemote getter, and logic to parse and serialize this information. [1] [2] [3] [4]
  • PendingSession includes the otpkUsed field, and its parsing is updated to handle empty or missing values. [1] [2] [3]

User interface improvements for federated chats:

  • The conversations list (ConversationsScreen) displays an "ext" badge and the federated address for remote chats, with distinct styling.
  • The user list screen now prevents starting duplicate chats by excluding users already in conversation, and adds a tabbed interface for local and federated user search.

CocoaPods and iOS build integration:

  • The iOS project adds a Podfile and updates .xcconfig files to integrate CocoaPods, preparing for dependencies required by federated features. [1] [2] [3]

Minor fixes and refactors:

  • Minor code cleanups, improved comments, and UI tweaks (e.g., fixing border color usage and widget structure in the conversations screen). [1] [2] [3]

These changes collectively enable seamless support for federated messaging and improve the user experience when interacting with both local and remote users.

AdamLBS added 3 commits April 18, 2026 16:21
- Implemented a new tab for federated user connections in UserListScreen.
- Added functionality to connect to users on external HushNet nodes using their full address.
- Created a FederatedAddress utility class to parse and validate federated addresses.
- Enhanced user experience with confirmation dialogs for session creation.
- Updated KeyProvider to fetch remote user device keys.
- Modified MessageService to include optional user address in message payloads.
- Updated macOS project files to support CocoaPods integration.
- Added necessary entitlements for network access in macOS app.
- Updated dependencies in pubspec.lock for improved compatibility and features.
- Implemented a new SettingsScreen with user information, node settings, and security details.
- Added navigation to SettingsScreen from ConversationsScreen.
- Enhanced UserListScreen to filter out existing partners based on passed IDs.
- Updated NodeService to manage WebSocket connection state and retry logic.
- Refactored KeyProvider and SessionService for improved key management and error handling.
- Integrated url_launcher package for external link handling across platforms.
- Updated generated plugin registrants for Linux, macOS, and Windows to include url_launcher.
- Updated pubspec.yaml and pubspec.lock to include url_launcher dependencies.
@AdamLBS AdamLBS self-assigned this Apr 26, 2026
@AdamLBS AdamLBS added the enhancement New feature or request label Apr 26, 2026
@AdamLBS AdamLBS merged commit 34752a4 into main Apr 26, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant