Commit 88f7c83
committed
feat(diagnostics): make diagnostic messages selectable and copyable
- Refactor diagnostic rendering to use DOM elements (`span.diagnostic`) instead of CSS `::after` pseudo-elements
- Add `DiagnosticRenderer` to manage diagnostic message lifecycle
- Update `Selection` and `Mouse` logic to ignore diagnostic elements during code navigation and cursor placement
- Implement `isInsideDiagnostic` and `getLineTextLength` helpers to correctly handle mixed content lines
- Allow native text selection and copying for diagnostics by bypassing default editor events when interacting with them
- Prevent diagnostic selection interference when selecting code via `.code.selecting` CSS state
- Update backend ignore defaults to include `target` and `node_modules`1 parent 4af8285 commit 88f7c83
11 files changed
Lines changed: 306 additions & 190 deletions
File tree
- anycode-backend/src
- anycode-base/src
- renderer
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
| 11 | + | |
10 | 12 | | |
11 | 13 | | |
12 | 14 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
22 | 25 | | |
23 | 26 | | |
24 | 27 | | |
| |||
0 commit comments