MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / constructor

Method constructor

source code/utils/Cursor.ts:155–162  ·  view source on GitHub ↗
(
    readonly measuredText: MeasuredText,
    offset: number = 0,
    readonly selection: number = 0,
  )

Source from the content-addressed store, hash-verified

153export class Cursor {
154 readonly offset: number
155 constructor(
156 readonly measuredText: MeasuredText,
157 offset: number = 0,
158 readonly selection: number = 0,
159 ) {
160 // it's ok for the cursor to be 1 char beyond the end of the string
161 this.offset = Math.max(0, Math.min(this.text.length, offset))
162 }
163
164 static fromText(
165 text: string,

Callers

nothing calls this directly

Calls 1

maxMethod · 0.80

Tested by

no test coverage detected