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

Function processDateCursorLeft

packages/effect/src/unstable/cli/Prompt.ts:1638–1650  ·  view source on GitHub ↗
(state: DateState)

Source from the content-addressed store, hash-verified

1636}
1637
1638const processDateCursorLeft = (state: DateState) => {
1639 const previous = state.dateParts[state.cursor].previousPart()
1640 if (Option.isSome(previous)) {
1641 return Action.NextFrame({
1642 state: {
1643 ...state,
1644 typed: "",
1645 cursor: state.dateParts.indexOf(previous.value)
1646 }
1647 })
1648 }
1649 return Action.Beep()
1650}
1651
1652const processDateCursorRight = (state: DateState) => {
1653 const next = state.dateParts[state.cursor].nextPart()

Callers 1

handleDateProcessFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected