mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-11-20 21:19:33 +01:00
fix(response-viewer): keep a path link's label in the prose font, pin its edges
Merge-time fix for #665. - A markdown link converted to a preview link became `a.rv-path`, so its label ("Our incident record") took the path style: monospace, 0.92em and `word-break: break-all`, which split prose mid-word on a phone. The anchor now also carries `rv-path-link`, and `.rv-text a.rv-path.rv-path-link` resets font and word-break, as the File Viewer does for its labelled document links. - The first new test adds `/tmp/a.json?raw=true` (pins the `?query` strip) and `/tmp/` (pins the trailing-slash folder check, since findFilePathLinks finds no folder in a bare `/tmp/`), and checks the new class. - The `_linkifyFilePaths` JSDoc and docs/architecture-invariants.md say the function also rewrites anchors whose href is a scheme-less, non-`//` path, on purpose without FILE_PATH_LINK_PATTERN's root and extension filter. - Mobile Guide: "a web link" in the response viewer opens a tab. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
6f785e116f
commit
fde23e3a07
5 files changed
+28
-5
No files matched your search
@@ -14926,6 +14926,14 @@ html:is([data-skin="paper-gray"], [data-skin="solarized-light"], [data-skin="cat
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
/* A markdown link whose target is a path (`[Our incident record](/tmp/x.json)`)
|
||||
takes the rv-path shape for the click delegate, but its text is a label, not a
|
||||
path: keep it in the prose font and never break it mid-word. */
|
||||
.rv-text a.rv-path.rv-path-link {
|
||||
font: inherit;
|
||||
word-break: normal;
|
||||
}
|
||||
|
||||
/* Tables — scroll wrapper keeps table proper while allowing horizontal overflow */
|
||||
.rv-table-wrap {
|
||||
margin: 1em 0;
|
||||
|
||||
Reference in new issue
Block a user