git.shiar.nl
/
sheet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
d1ddd28
)
caniuse: recognise missing support combinations
author
Mischa POSLAWSKY
<perl@shiar.org>
Wed, 10 Nov 2010 18:16:00 +0000
(19:16 +0100)
committer
Mischa POSLAWSKY
<perl@shiar.org>
Wed, 10 Nov 2010 21:40:55 +0000
(22:40 +0100)
browser.plp
patch
|
blob
|
history
diff --git
a/browser.plp
b/browser.plp
index 0f5b704d473a5e88a16387188b512ab37de10d3d..e82e69e4130f4a9228589e48133761fc86782e72 100644
(file)
--- a/
browser.plp
+++ b/
browser.plp
@@
-47,9
+47,11
@@
my $caniuse = from_json($source, {
my %CSTATS = (
n => 'di-b',
y => 'di-aa',
my %CSTATS = (
n => 'di-b',
y => 'di-aa',
- a => 'di-d',
- j => 'di-prop',
- p => 'di-prop',
+ a => 'di-d',
+ 'a x' => 'di-d',
+ j => 'di-prop',
+ p => 'di-prop',
+ 'p j' => 'di-prop',
'y x' => 'di-a',
);
my %CSTATUS = (
'y x' => 'di-a',
);
my %CSTATUS = (
@@
-68,10
+70,10
@@
if (my ($somerow) = values %{ $caniuse->{data} }) {
}
}
}
}
-my $canihas = do 'browser-usage.inc.pl'
;
-for ($! || $@ || ()) {
-
printf "<p>Browser usage data not found: <em>%s</em>.</p>\n", $_
;
-}
+my $canihas = do 'browser-usage.inc.pl'
or do {
+ printf "<p>Browser usage data not found: <em>%s</em>.</p>\n", $_
+
for $! || $@
;
+}
;
my $scorediv = (max(map { sum(values %$_) } values %$canihas) // 1) / 100;
print '<table class="mapped">';
my $scorediv = (max(map { sum(values %$_) } values %$canihas) // 1) / 100;
print '<table class="mapped">';
@@
-91,7
+93,7
@@
print "</thead>\n";
sub featurescore {
# relative amount of support for given feature
sub featurescore {
# relative amount of support for given feature
- state $statspts = { y=>10, 'y x'=>9, a=>5,
j
=>2, p=>1 };
+ state $statspts = { y=>10, 'y x'=>9, a=>5,
'a x'=>5, j=>2, 'p j'
=>2, p=>1 };
my $rank = 0;
if (my $row = shift) {
while (my ($browser, $vercols) = each %versions) {
my $rank = 0;
if (my $row = shift) {
while (my ($browser, $vercols) = each %versions) {