Skip to content

Commit 716703a

Browse files
committed
Just for testing
1 parent 1222884 commit 716703a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

webapp/src/Twig/TwigExtension.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1155,7 +1155,7 @@ public function fileTypeIcon(string $type): string
11551155
return 'fas fa-file-' . $iconName;
11561156
}
11571157

1158-
private function relativeLuminance(string $rgb): float
1158+
public function relativeLuminance(string $rgb): float
11591159
{
11601160
// See https://en.wikipedia.org/wiki/Relative_luminance
11611161
[$r, $g, $b] = Utils::parseHexColor($rgb);
@@ -1169,7 +1169,7 @@ private function relativeLuminance(string $rgb): float
11691169
return 0.2126 * $lr + 0.7152 * $lg + 0.0722 * $lb;
11701170
}
11711171

1172-
private function apcaContrast(string $fgColor, string $bgColor): float
1172+
public function apcaContrast(string $fgColor, string $bgColor): float
11731173
{
11741174
// Based on WCAG 3.x (https://www.w3.org/TR/wcag-3.0/)
11751175
$luminanceForeground = $this->relativeLuminance($fgColor);
@@ -1185,7 +1185,7 @@ private function apcaContrast(string $fgColor, string $bgColor): float
11851185
/**
11861186
* @return array{string, string}
11871187
*/
1188-
private function hexToForegroundAndBorder(string $rgb): array
1188+
public function hexToForegroundAndBorder(string $rgb): array
11891189
{
11901190
$background = Utils::parseHexColor($rgb);
11911191

0 commit comments

Comments
 (0)