Wire rich_text messages: Effect::OpenUrl in core, UiMessage mapping, spoiler state #40

Closed
opened 2026-11-11 09:37:42 +00:00 by charles · 1 comment
Owner

Deferred from Task 19 (#19): when it was built, fluxer-core was still empty on foundation (Task 8 not merged) and UiMessage / Local (Task 17) did not exist, so the widget could not reference them.

What is left, once Tasks 8 and 17 are on foundation:

  • Add Effect::OpenUrl(String) to fluxer-core (the plan's Task 19 Interfaces block asks for it) plus the UserAction/reducer path that emits it, and have the apps/fluxer effect executor open the system browser.
  • Map fluxer_ui::widgets::rich_text::Message into UiMessage: LinkClicked(url) -> that action, SpoilerToggled(index) -> toggle the index in UI-local state.
  • Keep the revealed spoilers per message in Local (a BTreeSet<usize> per message id) and pass it as RenderCtx::revealed_spoilers; supply utc_offset and now_unix from the runtime (the widget never reads the OS clock or time zone).

Seen on task/19-ui-rich-text. Task 20 (#20) is the first consumer of the widget.

Deferred from Task 19 (#19): when it was built, `fluxer-core` was still empty on `foundation` (Task 8 not merged) and `UiMessage` / `Local` (Task 17) did not exist, so the widget could not reference them. What is left, once Tasks 8 and 17 are on `foundation`: - Add `Effect::OpenUrl(String)` to `fluxer-core` (the plan's Task 19 Interfaces block asks for it) plus the `UserAction`/reducer path that emits it, and have the `apps/fluxer` effect executor open the system browser. - Map `fluxer_ui::widgets::rich_text::Message` into `UiMessage`: `LinkClicked(url)` -> that action, `SpoilerToggled(index)` -> toggle the index in UI-local state. - Keep the revealed spoilers per message in `Local` (a `BTreeSet<usize>` per message id) and pass it as `RenderCtx::revealed_spoilers`; supply `utc_offset` and `now_unix` from the runtime (the widget never reads the OS clock or time zone). Seen on `task/19-ui-rich-text`. Task 20 (#20) is the first consumer of the widget.
charles added this to the Foundation milestone 2026-11-11 09:37:42 +00:00
Author
Owner

Checked in Text chat 8 (PR #296): on the textchat base, rich_text::Message::LinkClicked maps to UserAction::OpenUrl and Effect::OpenUrl (opened by the runtime), SpoilerToggled toggles the per-message revealed set in screens::main::messages::State, and the shell supplies utc_offset / now_unix. Nothing is left; PR #296 closes this issue on merge.

Checked in Text chat 8 (PR #296): on the textchat base, `rich_text::Message::LinkClicked` maps to `UserAction::OpenUrl` and `Effect::OpenUrl` (opened by the runtime), `SpoilerToggled` toggles the per-message revealed set in `screens::main::messages::State`, and the shell supplies `utc_offset` / `now_unix`. Nothing is left; PR #296 closes this issue on merge.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
charles/fluxer-native#40
No description provided.