MCPcopy Index your code
hub / github.com/codeaashu/claude-code / _applyMinimumContrast

Method _applyMinimumContrast

src/server/web/public/terminal.js:1477–1486  ·  view source on GitHub ↗
(e3, t3, i3, s3, r2, n2)

Source from the content-addressed store, hash-verified

1475 return C && w && (C.textContent = y), g;
1476 }
1477 _applyMinimumContrast(e3, t3, i3, s3, r2, n2) {
1478 if (1 === this._optionsService.rawOptions.minimumContrastRatio || (0, _.treatGlyphAsBackgroundColor)(s3.getCode())) return false;
1479 const o2 = this._getContrastCache(s3);
1480 let a2;
1481 if (r2 || n2 || (a2 = o2.getColor(t3.rgba, i3.rgba)), void 0 === a2) {
1482 const e4 = this._optionsService.rawOptions.minimumContrastRatio / (s3.isDim() ? 2 : 1);
1483 a2 = c.color.ensureContrastRatio(r2 || t3, n2 || i3, e4), o2.setColor((r2 || t3).rgba, (n2 || i3).rgba, a2 ?? null);
1484 }
1485 return !!a2 && (this._addStyle(e3, `color:${a2.css}`), true);
1486 }
1487 _getContrastCache(e3) {
1488 return e3.isDim() ? this._themeService.colors.halfContrastCache : this._themeService.colors.contrastCache;
1489 }

Callers 1

createRowMethod · 0.80

Calls 6

getColorMethod · 0.80
isDimMethod · 0.80
setColorMethod · 0.80
_addStyleMethod · 0.80
getCodeMethod · 0.45
_getContrastCacheMethod · 0.45

Tested by

no test coverage detected