6 Commits

Author SHA1 Message Date
Ivan I. Ovchinnikov 332275eb2e fix(ui): allow header marker edits in read-only dashboard
mattermost--set-header-marker calls replace-match, which raised
"Buffer is read-only" inside toggle, aborting before the collapsed
state was recorded. All marker/overlay mutation now goes through
mattermost--collapse-section with inhibit-read-only bound.
Also deduplicate section rendering into mattermost--insert-section.

fix(mm-client): parse files/info tolerantly and log raw body

Accept array, {file_infos: [...]}, and {order, file_infos: {id: ...}}
shapes; add serde defaults to FileInfo fields. Log body prefix at
debug level to identify the actual Mattermost 10.9.3 response shape.
2026-11-21 13:05:27 +03:00
Ivan I. Ovchinnikov b5777565d7 refactor(bridge): split handlers.rs into modules
- handlers/mod.rs: public handler functions
- handlers/helpers.rs: utility functions (get_client, get_token, etc.)
- handlers/enrich.rs: post enrichment (display names, files)
- Fix FileInfo export in mm-core

feat(ui): preserve collapsed state on dashboard refresh

- Track collapsed team IDs in buffer-local mattermost--collapsed-teams
- Save collapse state before re-rendering (define-derived-mode resets locals)
- Restore collapse state after re-rendering
- Reset dashboard buffer on mattermost-reset-state
2026-11-21 12:13:57 +03:00
Ivan I. Ovchinnikov 452005b98c feat(bridge,ui): sort channels by last activity
- Add last_post_at field to Channel model (Rust)
- Sort channels by last_post_at descending in dashboard (Emacs)
2026-11-21 11:26:25 +03:00
Ivan I. Ovchinnikov 628df77588 fix(ui): repair dashboard parsing and group channels by team
- Read channel type from :type (matches Rust serde rename), not :channel_type
- Group channels by team with Direct messages section last
- Use text properties instead of regex to resolve channel under point
- Fallback "Other" section when bridge omits teams
2026-11-21 11:21:06 +03:00
Ivan I. Ovchinnikov 612456334f feat(ui): working vertical slice — dashboard, channel view, send
- mattermost-dashboard-mode: list channels from bridge
- mattermost-channel-mode: view history and send messages
- Interactive connection prompt (password in memory only)
- Fix JSON array parsing (vectors → lists) in protocol layer
- Add mattermost-reset-state for clean reconnects
- Add dev-check.sh for quick Rust validation
- Verified end-to-end: Emacs → Bridge → Mattermost → back
2026-11-21 09:03:19 +03:00
Ivan I. Ovchinnikov 8e98a68906 feat(bridge,ui): add list_channels API and interactive dashboard
- Add Channel model to mm-core
- Implement get_my_channels in mm-client
- Add list_channels handler and routing in mm-bridge
- Create mattermost-dashboard-mode with interactive connection prompt
- Add dev-check.sh script for quick Rust validation
2026-11-20 18:53:51 +03:00