MCPcopy Create free account
hub / github.com/adobe/react-spectrum / outerBorderStop

Function outerBorderStop

packages/@react-spectrum/ai/src/tokens.macro.ts:160–168  ·  view source on GitHub ↗
(stop: number, variant: string, colorScheme: string, div = 10)

Source from the content-addressed store, hash-verified

158}
159
160function outerBorderStop(stop: number, variant: string, colorScheme: string, div = 10) {
161 let opacity = token(
162 `outer-border.opacity.ob-hue-${variant}.${variant === 'prominent' ? 'value' : colorScheme}`
163 );
164 if (colorScheme === 'light') {
165 opacity = opacity / div;
166 }
167 return `rgb(from ${token(`outer-border.gradient.ob-hue.stop-${stop}.${colorScheme}`)} r g b / ${opacity}%)`;
168}

Callers 1

outerBorderStopsFunction · 0.85

Calls 1

tokenFunction · 0.70

Tested by

no test coverage detected