MCPcopy Create free account
hub / github.com/Effect-TS/effect / processTextCursorRight

Function processTextCursorRight

packages/effect/src/cli/Prompt.ts:3882–3892  ·  view source on GitHub ↗
(state: TextState)

Source from the content-addressed store, hash-verified

3880}
3881
3882const processTextCursorRight = (state: TextState) => {
3883 if (state.cursor >= state.value.length) {
3884 return Effect.succeed(Action.Beep())
3885 }
3886 const cursor = Math.min(state.cursor + 1, state.value.length)
3887 return Effect.succeed(
3888 Action.NextFrame({
3889 state: { ...state, cursor, error: Option.none() }
3890 })
3891 )
3892}
3893
3894const processTextCursorStart = (state: TextState) =>
3895 Effect.succeed(

Callers 1

handleTextProcessFunction · 0.85

Calls 1

succeedMethod · 0.45

Tested by

no test coverage detected