MCPcopy Create free account
hub / github.com/anomalyco/opencode / maxOffset

Function maxOffset

packages/opencode/src/cli/cmd/run/footer.menu.tsx:22–24  ·  view source on GitHub ↗
(count: number, limit: number)

Source from the content-addressed store, hash-verified

20 | { type: "spacer" }
21
22function maxOffset(count: number, limit: number) {
23 return Math.max(0, count - limit)
24}
25
26function previewMargin(limit: number) {
27 return Math.max(0, Math.min(2, Math.floor((limit - 1) / 2)))

Callers 5

WhichKeyPanelFunction · 0.85
clampFunction · 0.85
runFunction · 0.85
revealOffsetFunction · 0.85
moveOffsetFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected