getFillOpacity() — supabase Function Reference
Architecture documentation for the getFillOpacity() function in geo.ts from the supabase codebase.
Entity Profile
Relationship Graph
Source Code
apps/studio/components/interfaces/Reports/utils/geo.ts lines 58–70
export const getFillOpacity = (
value: number,
max: number,
theme: MapChartTheme = MAP_CHART_THEME.dark
): number => {
if (max <= 0 || !value) return 1
const ratio = value / max
if (ratio > 0.8) return theme.opacityScale[4]
if (ratio > 0.6) return theme.opacityScale[3]
if (ratio > 0.4) return theme.opacityScale[2]
if (ratio > 0.2) return theme.opacityScale[1]
return theme.opacityScale[0]
}
Domain
Subdomains
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free