MCPcopy Create free account
hub / github.com/CodeGraphContext/CodeGraphContext / clamp

Function clamp

website/src/components/PRReviewer.tsx:340–342  ·  view source on GitHub ↗
(value: number, min: number, max: number)

Source from the content-addressed store, hash-verified

338const DEFAULT_SIDEBAR_W = 300;
339
340function clamp(value: number, min: number, max: number): number {
341 return Math.min(max, Math.max(min, value));
342}
343
344function getNodeDisplayName(node: any): string {
345 const fallback = node?.name ?? node?.label ?? node?.uid ?? node?.node_type ?? node?.type ?? node?.id ?? 'Unknown';

Callers 2

getGraphAwareNodeScaleFunction · 0.70
PRReviewerFunction · 0.70

Calls 1

maxMethod · 0.80

Tested by

no test coverage detected