r2 vs r3
......
55
66
||<tablewidth=100%><tablebgcolor=#ffffff,#1f1f1f><tablecolor=#222,#eee> 글자색 || {{{@fg@}}} ||
77
|| 배경색 || {{{@bg@}}} ||
8
|| 기준 대비비 || {{{@기준@}}}:1 ||
8
|| 대비비 || {{{@ratio@}}}:1 ||
9
|| 기준 || {{{@level@}}} ||
910
10
{{{#!if (function(f,b,t){function n(c){c=String(c).trim();if(c.charAt(0)=='#')c=c.substr(1);if(c.length==3)c=c.charAt(0)+c.charAt(0)+c.charAt(1)+c.charAt(1)+c.charAt(2)+c.charAt(2);return c;}function v(c,i){return parseInt(c.substr(i,2),16)/255;}function l(x){return x<=0.04045?x/12.92:Math.pow((x+0.055)/1.055,2.4);}function y(c){c=n(c);return 0.2126*l(v(c,0))+0.7152*l(v(c,2))+0.0722*l(v(c,4));}var a=y(f),d=y(b),hi=a>d?a:d,lo=a>d?d:a;return ((hi+0.05)/(lo+0.05))>=Number(t);})('@fg@','@bg@',@기준@)
11
{{{#!if @ratio@ >= 7
1112
{{{#!wiki style="margin-top:6px; padding:6px 8px; border-left:4px solid #2ecc71; background:#eafaf1; color:#145a32;"
12
'''통과''' — 입력한 기준 대비비 이상입니다.
13
'''AAA 통과''' — 일반 텍스트 기준으로도 충분합니다.
1314
}}}
1415
}}}
1516
16
{{{#!if !((function(f,b,t){function n(c){c=String(c).trim();if(c.charAt(0)=='#')c=c.substr(1);if(c.length==3)c=c.charAt(0)+c.charAt(0)+c.charAt(1)+c.charAt(1)+c.charAt(2)+c.charAt(2);return c;}function v(c,i){return parseInt(c.substr(i,2),16)/255;}function l(x){return x<=0.04045?x/12.92:Math.pow((x+0.055)/1.055,2.4);}function y(c){c=n(c);return 0.2126*l(v(c,0))+0.7152*l(v(c,2))+0.0722*l(v(c,4));}var a=y(f),d=y(b),hi=a>d?a:d,lo=a>d?d:a;return ((hi+0.05)/(lo+0.05))>=Number(t);})('@fg@','@bg@',@기준@))
17
{{{#!if @ratio@ >= 4.5 && @ratio@ < 7
18
{{{#!wiki style="margin-top:6px; padding:6px 8px; border-left:4px solid #27ae60; background:#eafaf1; color:#145a32;"
19
'''AA 통과''' — 일반 텍스트 기준을 만족합니다.
20
}}}
21
}}}
22
23
{{{#!if @ratio@ >= 3 && @ratio@ < 4.5
24
{{{#!wiki style="margin-top:6px; padding:6px 8px; border-left:4px solid #f39c12; background:#fff8e1; color:#7d4f00;"
25
'''큰 글자 AA만 통과''' — 일반 본문용으로는 부족합니다.
26
}}}
27
}}}
28
29
{{{#!if @ratio@ < 3
1730
{{{#!wiki style="margin-top:6px; padding:6px 8px; border-left:4px solid #e74c3c; background:#fdedec; color:#78281f;"
18
'''미달''' — 입력한 기준 대비비보다 낮습니다.
31
'''미달''' — 글자 기준 만족하지 못합니다.
1932
}}}
2033
}}}