MCPcopy Create free account
hub / github.com/ChinaSiro/claude-code-sourcemap / right

Method right

restored-src/src/utils/Cursor.ts:311–319  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

309 }
310
311 right(): Cursor {
312 if (this.offset >= this.text.length) return this
313
314 const chip = this.imageRefStartingAt(this.offset)
315 if (chip) return new Cursor(this.measuredText, chip.end)
316
317 const nextOffset = this.measuredText.nextOffset(this.offset)
318 return new Cursor(this.measuredText, Math.min(nextOffset, this.text.length))
319 }
320
321 /**
322 * If an [Image #N] chip ends at `offset`, return its bounds. Used by left()

Callers 11

delMethod · 0.95
deleteToLineEndMethod · 0.95
nextWORDMethod · 0.45
endOfWORDMethod · 0.45
executeXFunction · 0.45
applySingleMotionFunction · 0.45
handleNormalInputFunction · 0.45
handleKeyDownFunction · 0.45
useTextInputFunction · 0.45
mapKeyFunction · 0.45

Calls 3

imageRefStartingAtMethod · 0.95
nextOffsetMethod · 0.45
minMethod · 0.45

Tested by

no test coverage detected