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 | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0156 | matrix-client-android composer: markdown, replies, edits, reactions, media | pending | high | 2026-05-24 |
|
|
|
|
Objetivo
Composer Compose con markdown shortcuts, replies, edits, reactions emoji, threads, upload media (camara nativa, galeria, voice msg con MediaRecorder opus). Drag&drop archivos compartidos via share sheet Android.
Tareas
- ViewModel:
ComposerViewModel(matrixClient, roomId)— methodssendText,sendReply,editMessage,sendReaction,uploadMedia,recordVoice.
- Compose:
ComposerconOutlinedTextField+ toolbar (markdown shortcuts B/I/code).- Hotkeys soft keyboard: Send action en IME.
AttachmentMenu: botones camara, galeria, file, voice.EmojiPickeroverlay (reusar libreria existente o componente propio).ReactionBardebajo deEventBubblecon aggregates.ThreadScreen— nueva pantalla full para thread (no panel lateral como en PC, por screen real estate movil).- Voice recording UI: hold-to-record con waveform preview + cancelar al deslizar.
- Backend:
- Upload media: comprimir imagenes si >2MB antes de upload (
androidx.exifinterfacepara preservar orientacion). - Voice:
MediaRecordercon OPUS, 32kbps, ogg container. - Markdown -> HTML local con
markwonlibrary (lightweight, no Goldmark equivalente).
- Upload media: comprimir imagenes si >2MB antes de upload (
- Share intent:
IntentFilterparaandroid.intent.action.SEND+ tipos image/video/text/file -> abre composer del room seleccionado.
- Tests:
- Instrumented
SendMarkdownTest—**bold**formateado en Element Web. - Instrumented
EditMessageTest— edicion in-place propagada. - Instrumented
VoiceMsgTest— graba 5s + upload + play en Element Web.
- Instrumented
Funciones del registry a crear
markdown_to_matrix_html_kotlin_core— wrapper markwon con sanitizer.image_compress_kotlin_core— resize + recompress JPEG.voice_record_kotlin_infra— MediaRecorder opus wrapper.Composer_kotlin_ui— Compose composer + toolbar + attachment menu.ReactionBar_kotlin_ui— composable reactions.ThreadScreen_kotlin_ui— pantalla thread.
Acceptance
- Mensaje markdown se ve formateado en Element Web.
- Reply con quote del msg padre.
- Edit in-place propagado en ambos clientes.
- Reaccion emoji bidireccional.
- Upload imagen 5MB -> compresion a ~1MB -> envio + thumbnail OK.
- Voice msg 5s reproducible en Element Web.
- Share intent desde galeria abre composer con imagen pre-cargada.
Notas
- Sanitizer HTML server-side delegado a matrix-rust-sdk (mismo allowlist que cliente PC).
- Voice msg: encode opus 32kbps, max 5min.
- Markwon vs goldmark: ambos cumplen el rol equivalente en su stack. Salida HTML compatible Matrix.
- Drag&drop: en Android = share sheet o picker, no drag&drop nativo como en PC.