Commit graph

13837 commits

Author SHA1 Message Date
f2b95d6b8a fix(wallet): replace text-marker hack with proper raw event API (room.sendRaw + MsgLikeKind.Other)
- Add Timeline.sendRaw() to send custom Matrix events
- Add CustomEventContent type for receiving custom events
- Update TimelineEventContentMapper to handle MsgLikeKind.Other
- Update TimelineItemContentFactory to intercept payment events
- Rewrite DefaultPaymentEventSender to use sendRaw instead of text markers
- Update TimelineItemContentPaymentFactory to parse raw JSON
- Remove text-marker detection from TimelineItemContentMessageFactory
- Update tests to use raw event API
- Mark raw event SDK blocker as RESOLVED in BLOCKERS.md

Event type: co.sulkta.payment.request (reverse-domain format)
Status updates: co.sulkta.payment.status

Benefits:
- Proper Matrix protocol compliance
- No JSON embedded in text messages
- Events won't be indexed by search
- Clean separation from regular messages
2026-03-27 11:45:12 -07:00
adee67cf0d feat(wallet): payment card timeline item and raw event handling (Tasks 7+8)
Task 7: Timeline Payment Card
- TimelineItemPaymentView integration with TimelineItemEventContentView
- Payment card rendering for both sender and recipient perspectives
- Unit tests for TimelineItemPaymentContent

Task 8: Raw Event Handling
- Modified TimelineItemContentMessageFactory to intercept payment events
- Added isSentByMe parameter propagation through content factories
- FakePaymentEventSender for testing
- Unit tests for TimelineItemContentPaymentFactory

SDK Limitation Workaround:
Since matrix-rust-sdk doesn't expose raw event sending or UnknownContent
raw JSON, payment events are encoded as text messages with a marker:
[cardano-payment:v1]{...json...}

This falls back gracefully for non-wallet clients while enabling
rich payment card rendering for wallet-enabled clients.
2026-03-27 11:08:03 -07:00
39561e1aeb feat(wallet): payment flow UI — entry, confirmation, progress screens (Task 6)
Implements the payment flow UI for the Element X ADA wallet:

## Screens
- PaymentEntryScreen: Amount/recipient input with pre-filling from /pay command
- PaymentConfirmationScreen: Transaction details with fee estimation (FLAG_SECURE)
- PaymentProgressScreen: Submission status with polling for confirmation

## Features
- Biometric authentication before payment confirmation
- Matrix user detection with 'hasn't linked wallet' inline message
- CardanoScan explorer link for transaction viewing
- Testnet warning banner
- Insufficient funds detection

## Wire-up
- MessageComposerPresenter intercepts /pay commands
- SlashCommandParser integration for command detection
- Navigation to PaymentFlowNode on valid /pay command
- Snackbar error on parse errors

## Technical
- Circuit presenter pattern with Molecule/Turbine tests
- @PreviewsDayNight for all Composables
- Metro DI integration
- Fake implementations for testing

Includes PaymentEntryPresenterTest, PaymentConfirmationPresenterTest,
PaymentProgressPresenterTest with comprehensive coverage.
2026-03-27 11:04:41 -07:00
9439f5a227 feat(wallet): transaction builder, UTXO selection, and status poller (Task 4)
## What's new

### API module additions
- ProtocolParameters: data class for fee calculation params
- PaymentRequest: transaction request model
- SignedTransaction: signed transaction result model
- TransactionBuilder: interface for building/signing transactions
- PaymentStatusPoller: interface for polling tx confirmation

### CardanoClient updates
- Added getProtocolParameters() to interface
- Implemented in KoiosCardanoClient with retry logic

### Implementation
- DefaultTransactionBuilder: builds and signs transactions using cardano-client-lib
  - Largest-first UTXO selection
  - Fee calculation via protocol parameters
  - Min UTXO validation (1 ADA minimum)
  - Secure key handling (zeroed after use)
- DefaultPaymentStatusPoller: polls Koios for tx confirmation
  - 10s polling interval, 60 attempts max (~10 minutes)
  - Emits TxStatus.PENDING -> CONFIRMED/FAILED flow

### Test module
- FakeTransactionBuilder: configurable success/failure responses
- FakePaymentStatusPoller: configurable status sequences
- Updated FakeCardanoClient with getProtocolParameters()

### Unit tests
- TransactionBuilderTest: UTXO selection, fee calculation, error handling
- PaymentStatusPollerTest: polling behavior, error recovery
2026-03-27 10:52:15 -07:00
19637833a6 docs: update BLOCKERS.md with Task 3 completion status 2026-03-27 10:39:53 -07:00
db4c262b27 feat(wallet): /pay slash command parser and composer integration (Task 5)
Implements Task 5 of Phase 1:

New files:
- ParsedPayCommand.kt: Sealed interface for parse results
  - WithAddressRecipient: Pay to Cardano address
  - WithMatrixRecipient: Pay to Matrix user (requires lookup)
  - AmountOnly: Amount specified, prompt for recipient
  - Empty: Open payment flow with no prefilled data
  - ParseError: Parse error with human-readable reason

- SlashCommandParser.kt: Full /pay command parser
  - Handles: /pay, /pay 10, /pay 10 ADA, /pay 10 tADA
  - Matrix recipients: /pay 10 ADA @user:server
  - Cardano addresses: /pay 10 ADA addr1...
  - Validates amounts (decimal support, max supply check)
  - Validates addresses (prefix, length, network match)
  - Comprehensive error messages

- SlashCommandParserTest.kt: 40+ unit tests covering all patterns

Modified files:
- ResolvedSuggestion.kt: Added Command type for slash commands
- SuggestionsProcessor.kt: /pay shows as autocomplete suggestion
- MarkdownTextEditorState.kt: Command insertion in text editor
- MessageComposerPresenter.kt: Command handling in InsertSuggestion

Note: MessageComposerPresenter sendMessage interception deferred to
Task 6 (requires PaymentFlowPresenter for navigation).
2026-03-27 10:38:46 -07:00
880454847e docs: resolve Phase 1 design decisions and add emulator info
- Q1 RESOLVED: per-session wallet scope (Phase 3: optional sharing)
- Q2 RESOLVED: invalidate keys on biometric change (intentional)
- Q3 RESOLVED: testnet first, single config point for mainnet swap
- Added Android emulator connection info (ADB + noVNC)
2026-03-27 10:34:48 -07:00
9ff2b0964a docs: add BLOCKERS.md documenting Task 1 status and questions
- Documents what was completed vs what needs verification
- Lists items requiring Android SDK to test (compilation, ktlint, tests)
- Raises 3 questions requiring human decision:
  1. Wallet scope (per-session vs app-wide)
  2. Key storage behavior on biometric changes
  3. Testnet vs mainnet for initial development
2026-03-27 10:06:19 -07:00
225afc3108 feat(wallet): scaffold wallet module structure
Task 1 of Phase 1 - Module Scaffolding

- Created features/wallet/api module with WalletEntryPoint and WalletState
- Created features/wallet/impl module with Metro DI setup
- Created features/wallet/test module with FakeWalletEntryPoint
- Added PaymentFlowNode placeholder with Appyx navigation
- Added Cardano client library dependencies (0.7.1)
- Added proguard rules for Cardano library
- Added basic unit tests for WalletState

The module follows Element X patterns:
- Metro for dependency injection (@ContributesTo, @ContributesBinding, @ContributesNode)
- Appyx for navigation (BaseFlowNode pattern)
- api/impl/test module separation
- Feature entry point pattern for navigation

This module scaffolding blocks all subsequent tasks (2-8) in Phase 1.
2026-03-27 10:04:58 -07:00
Benoit Marty
cbb220f08d
Merge pull request #6472 from element-hq/feature/bma/inReplyUi
Update replied message UI
2026-03-27 10:17:01 +01:00
renovate[bot]
5975454424
fix(deps): update dependency com.google.firebase:firebase-bom to v34.11.0 (#6478)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-27 08:13:05 +01:00
renovate[bot]
81cc055c91
fix(deps): update dependency io.element.android:emojibase-bindings to v1.5.1 (#6474)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-27 08:11:54 +01:00
Jorge Martin Espinosa
bba2e6df3f
Fix ForegroundServiceDidNotStartInTimeException (#6470)
* Start the `FetchPushForegroundService ` in foreground ASAP. This is a first step to mitigate `ForegroundServiceDidNotStartInTimeException` being thrown.

* Don't stop the service immediately if it's running but not in foreground. Try waiting up to 5s for it to be in foreground.
2026-03-27 06:54:27 +00:00
Benjamin Bouvier
ef041baeb4
chore: update the build-rust-sdk script (#6476) 2026-03-27 07:36:48 +01:00
Benoit Marty
8851476bc7 Kotlin 2.3.20 2026-03-26 11:32:40 +01:00
Benoit Marty
360fe65277
Merge pull request #6358 from element-hq/renovate/io.element.android-element-call-embedded-0.x
Update dependency io.element.android:element-call-embedded to v0.18.0
2026-03-25 19:02:27 +01:00
Benoit Marty
dc5889c05c
Merge pull request #6437 from element-hq/renovate/kotlin
Update kotlin to v2.3.20
2026-03-25 19:01:34 +01:00
ganfra
cd695d948e
Merge pull request #6442 from element-hq/renovate/nschloe-action-cached-lfs-checkout-1.x
Update nschloe/action-cached-lfs-checkout action to v1.2.4
2026-03-25 17:21:33 +01:00
ganfra
71dd68746b
Merge pull request #6449 from element-hq/renovate/sqldelight
Update sqldelight to v2.3.2
2026-03-25 17:18:36 +01:00
Benoit Marty
1de3729792
Merge pull request #6446 from bxdxnn/misc/bullet-margin
Add margin after bullet points
2026-03-25 17:05:48 +01:00
Benoit Marty
7d28c52242 Cleanup 2026-03-25 16:51:41 +01:00
ElementBot
6c32b27cbd Update screenshots 2026-03-25 14:43:07 +00:00
Benoit Marty
747f588fa7 Update UI of replies. 2026-03-25 15:27:36 +01:00
Benoit Marty
087c159325
Merge pull request #6459 from element-hq/feature/bma/iterateOnBadgeColors
Sync compound tokens https://github.com/element-hq/compound-design-tokens/releases/tag/v8.0.0
2026-03-25 14:28:15 +01:00
Benoit Marty
16e9cb64ce
Merge pull request #6468 from element-hq/feature/bma/aiStuff
Add instructions for AI
2026-03-25 14:23:43 +01:00
Jorge Martin Espinosa
5024e314b6
Add some instructions for features to the community PR notice message (#6465) 2026-03-25 12:28:55 +01:00
Benoit Marty
d1d2f851ee Create AGENTS.md 2026-03-25 12:19:26 +01:00
Benoit Marty
dc55d3d1af Add question about AI usage in the Pull Request template. 2026-03-25 09:46:08 +01:00
Benoit Marty
6ca3e11392 Fix grammar issue. 2026-03-25 09:40:12 +01:00
renovate[bot]
5a9bb9eaaf
Update metro to v0.11.4 (#6448)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-25 08:26:24 +01:00
renovate[bot]
9585636306
Update dependency io.sentry:sentry-android to v8.36.0 (#6461)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-25 08:16:30 +01:00
ElementBot
e2eefdbf63 Update screenshots 2026-03-24 17:25:47 +00:00
Benoit Marty
f4adde627f Use Folder icon from Compound. 2026-03-24 18:06:08 +01:00
Benoit Marty
aa5b1f5a07
Merge pull request #6456 from element-hq/feature/bma/iterateOnSpaceHeader
Iterate on space header
2026-03-24 17:54:02 +01:00
ElementBot
0723641b8a Update screenshots 2026-03-24 16:16:30 +00:00
ElementBot
968b967864 Update screenshots 2026-03-24 16:04:35 +00:00
Benoit Marty
78d500ba55 Edit room detail: increase avatar size. #6458 2026-03-24 16:56:34 +01:00
Benoit Marty
8e1388efb7 Add border for Neutral badge. 2026-03-24 16:39:37 +01:00
Benoit Marty
e9811ada20 Add missing color in preview. 2026-03-24 16:33:20 +01:00
Benoit Marty
eef20f723b Update colors of permalinks. 2026-03-24 16:31:15 +01:00
Benoit Marty
6ce20d2e9e Import compound token v8.0.0
./tools/compound/import_tokens.sh -b v8.0.0
2026-03-24 15:59:50 +01:00
ganfra
92920b862b
Merge pull request #6342 from element-hq/feature/fga/live_location_sharing_setup
Setup live location sharing feature
2026-03-24 15:46:45 +01:00
Benoit Marty
3439def2c5 Add Figma link on MatrixBadgeAtom 2026-03-24 15:43:04 +01:00
ganfra
417701d541 Changelog for version 26.03.4 2026-03-24 15:20:03 +01:00
ganfra
d95ac8b181 Merge tag '26.03.4' into develop 2026-03-24 15:19:14 +01:00
Benoit Marty
c45b131a84 AvatarPickerView: ensure the pencil icon always has the same size and improve the preview. 2026-03-24 15:18:35 +01:00
Benoit Marty
a9c7c26535 Iterate design on EditUserProfileView 2026-03-24 15:04:55 +01:00
ganfra
ac7dd6beab Merge branch 'release/26.03.4' 2026-03-24 14:02:30 +01:00
ganfra
ee13774949 Adding fastlane file for version 26.03.4 2026-03-24 14:01:27 +01:00
ganfra
64ea57a432 Setting version for the release 26.03.4 2026-03-24 14:01:25 +01:00