daef7ea190
Helper functions (matrix-mas capability group): - mas_client_register_bash_infra: register/sync OAuth clients via mas-cli - mas_syn2mas_migration_bash_infra: dry-run + apply user migration to MAS - synapse_msc3861_enable_go_infra: edit homeserver.yaml MSC3861 block (with diff) - wellknown_oidc_patch_go_infra: patch well-known JSON with msc2965.authentication - synapse_login_flows_check_go_infra: health-check post-migration login flows Flows + issues for custom Matrix clients (PC + Android): - 0010 matrix-client-pc: Wails + React+Mantine (issues 0147-0153) - 0011 matrix-client-android: Kotlin + Compose (issues 0154-0161) - 0162 enable MAS as auth provider (Synapse delegate) — EXECUTED on VPS - 0163 custom admin panel propio (sustituye synapse-admin) Production state (organic-machine.com): - Synapse migrated SQLite -> Postgres - MSC3861 active, password_config disabled - 21 users + 41 access_tokens migrated via syn2mas - 4 MAS clients registered (element, matrix_pc, matrix_android, admin_panel) - synapse-admin container removed + Coolify route deleted - well-known patched with org.matrix.msc2965.authentication Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2.9 KiB
2.9 KiB
id, title, status, priority, created, related_flows, related_issues, dependencies, tags
| id | title | status | priority | created | related_flows | related_issues | dependencies | tags | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0155 | matrix-client-android rooms list + timeline Compose | pending | high | 2026-05-24 |
|
|
|
|
Objetivo
UI Compose con Scaffold que muestre sidebar drawer con rooms y panel principal con timeline. Sync via matrix-rust-sdk (corrutinas + Flow). LazyColumn virtualizado para timeline (perf con miles de mensajes). Swipe-to-react en mensajes. Optimistic UI al enviar (en issue 0156).
Tareas
- ViewModels:
RoomsViewModel(matrixClient)— exponeStateFlow<List<RoomSummary>>. Ordenado porlastActivity.TimelineViewModel(matrixClient, roomId)— exponeStateFlow<List<TimelineEvent>>+loadMore().- Persistencia local con Room DB (
androidx.room) — store rooms + last sync token.
- Compose:
MainScreenconModalNavigationDrawer:- Drawer:
RoomList(LazyColumn conRoomItem: avatar, name, last preview, unread badge). - Content:
TimelineScreen(roomId).
- Drawer:
TimelineScreen:LazyColumnconreverseLayout = true(mensajes recientes abajo).key = { it.eventId }para evitar re-composiciones.LaunchedEffectconLazyListState-> al llegar al top,viewModel.loadMore().EventBubblecomposables segun tipo (text, image, file, redacted).
Avatarcomposable reusable con cache de imagenes (Coil).
- Sync engine:
MatrixSyncService(corrutina supervisor scope) que mantieneclient.syncStream().- Si pasa a background sin call activa, sync se pausa hasta que vuelve foreground (lifecycle-aware).
- Errores de red: backoff exponencial (1s, 2s, 4s ... 60s max).
- Tests:
- Instrumented
RoomsListTest— 3 rooms aparecen en drawer. - Instrumented
TimelinePaginationTest— scroll-up carga 50 msgs anteriores.
- Instrumented
Funciones del registry a crear
matrix_room_summary_kotlin_infra— extractRoomSummaryde matrix-rust-sdk.matrix_timeline_kotlin_infra— Flow de eventos paginados.RoomListScreen_kotlin_ui— Compose drawer rooms.TimelineScreen_kotlin_ui— Compose timeline virtualizado.EventBubble_kotlin_ui— composable burbuja msg.
Acceptance
- Drawer lista rooms del usuario test.
- Click en room muestra timeline ultimos 50 msgs.
- Swipe arriba carga msgs anteriores sin gap.
- Msg enviado desde PC (Wails) aparece en Android en <2s.
- Avion mode + restore: sync resume, no msgs perdidos.
- Cerrar app + reopen: state restaurado desde Room DB, no full re-sync.
Notas
matrix-rust-sdkya gestiona persistencia interna (SQLite + crypto store). Room DB local solo para datos UI-rapidos (room summaries, unread counters).- Read receipts: TBD otro issue.
- DMs detectados via
m.directaccount data. - Spaces:
RoomItemcon icono diferente, colapsable.