Commit cf6f517
committed
fix: improve sticky prompt handling and section detection
This commit improves handling of sticky prompts by:
1. Using proper line splitting and startswith check instead of gmatch
2. Fixing the sticky prefix removal to only match start of line
3. Ensuring proper rendering before section/block detection
The changes make sticky prompts more reliable and fix edge cases in the
UI rendering.
Closes CopilotC-Nvim#6141 parent c1c7630 commit cf6f517
2 files changed
Lines changed: 10 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
287 | 287 | | |
288 | 288 | | |
289 | 289 | | |
| 290 | + | |
290 | 291 | | |
291 | 292 | | |
292 | | - | |
293 | | - | |
294 | | - | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
295 | 299 | | |
296 | 300 | | |
297 | 301 | | |
| |||
666 | 670 | | |
667 | 671 | | |
668 | 672 | | |
669 | | - | |
| 673 | + | |
670 | 674 | | |
671 | 675 | | |
672 | 676 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
242 | 242 | | |
243 | 243 | | |
244 | 244 | | |
| 245 | + | |
245 | 246 | | |
246 | 247 | | |
247 | 248 | | |
| |||
279 | 280 | | |
280 | 281 | | |
281 | 282 | | |
| 283 | + | |
282 | 284 | | |
283 | 285 | | |
284 | 286 | | |
| |||
318 | 320 | | |
319 | 321 | | |
320 | 322 | | |
321 | | - | |
322 | 323 | | |
323 | 324 | | |
324 | 325 | | |
| |||
0 commit comments