Repository navigation
Conversation
Markdown links inside dialogue messages were not clickable because mouseDelegate.OnAction ignored LeftClick events and dialogue.Component lacked hit-testing to locate links in the messages list. This caused all clicks on links to fall through to standard text selection. Add LinkAt to dialoguetui.Component to hit-test message nodes and extract underlying markdown components across nested spans and handlers. Expose Component() on internal/handler/markdown.Handler. In mouseDelegate.OnAction, query LinkAt on LeftClick and invoke the configured OnLinkClick callback, suppressing text selection when handled. Wire the callback in rune-agent extension to copy http/https URLs to the clipboard and display a success notification. Fixes unstablebuild#7 Signed-off-by: Spandan Mishra <[email protected]>
Also restore four icon glyphs that were corrupted in config.go doc comments. Signed-off-by: ernestrc <[email protected]>
ernestrc
force-pushed
the
fix/agent-dialogue-clickable-links
branch
from
October 8, 2026 12:04
3fdcf98 to
6396695
Compare
ernestrc
enabled auto-merge (squash)
October 8, 2026 12:06
ernestrc
approved these changes
Oct 8, 2026
|
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #7.
Fixes an issue in the
rune-agentdialogue TUI where left-clicking markdown links in sent messages, received messages, or prompt bodies fell through to normal text selection rather than activating the link.Changes
cmd/rune-agent/dialogue/dialoguetui:OnLinkClick func(*url.URL) booltoComponentConfig.(*Component).LinkAt(pos term.Coordinates) *markdown.LinkInfoto traverse visible messages inc.messages, unwrap spans/handlers, and hit-test underlying markdown components.mouseDelegate.OnActionto queryd.comp.LinkAt(pos)onmouse.LeftClick, parse the URL, and invokeOnLinkClick, returningtrueto suppress selection.internal/handler/markdown:Component() *markdown.Componenton*Handlerto permit component unwrapping during layout hit-testing.cmd/rune-agent/extension:ret.cfg.OnLinkClickvianewLinkClickHandler: copieshttpandhttpsURLs toclipboard.Registerand dispatches a success notification viabrowserapi.Notifications.TestMouseDelegate_LinkClickcovering sent messages, received messages, prompt bodies, non-link text fallthrough, unhandled bare anchors, and nil callbacks.TestExtensionDialogue_LinkClick_CopiesToClipboardtesting URL copying, notifications, and non-http filtering.Results
screenrecording-2026-09-20_15-47-56.mp4