MCPcopy Index your code
hub / github.com/codeaashu/claude-code / imageRefEndingAt

Method imageRefEndingAt

src/utils/Cursor.ts:325–328  ·  view source on GitHub ↗

* If an [Image #N] chip ends at `offset`, return its bounds. Used by left() * to hop the cursor over the chip instead of stepping into it.

(offset: number)

Source from the content-addressed store, hash-verified

323 * to hop the cursor over the chip instead of stepping into it.
324 */
325 imageRefEndingAt(offset: number): { start: number; end: number } | null {
326 const m = this.text.slice(0, offset).match(/\[Image #\d+\]$/)
327 return m ? { start: offset - m[0].length, end: offset } : null
328 }
329
330 imageRefStartingAt(offset: number): { start: number; end: number } | null {
331 const m = this.text.slice(offset).match(/^\[Image #\d+\]/)

Callers 1

leftMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected