X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/4567809ced8050d78560dfe77fef5edfc58dc1c7..76d34d4bd4b31ebbe6847e5b31d2d4b699e75e38:/browser.plp diff --git a/browser.plp b/browser.plp index c890052..dcc7688 100644 --- a/browser.plp +++ b/browser.plp @@ -4,7 +4,7 @@ no if $] >= 5.018, warnings => 'experimental::smartmatch'; Html({ title => 'browser compatibility cheat sheet', - version => '1.4', + version => '1.5', description => [ "Compatibility table of new web features (HTML5, CSS3, SVG, Javascript)", "comparing support and usage share for all popular browser versions.", @@ -83,8 +83,11 @@ while (my ($browser, $row) = each %{ $caniuse->{agents} }) { ]; } -print <<''; -

Alternate rendition of Fyrd's when can I use... page +my $ref = showlink('Can I use', 'https://caniuse.com/'); +$ref =~ s/(?=>)/ title="updated $_"/ + for map { s/[\sT].*//r } $caniuse->{-date} || (); +$ref = "Fyrd's $ref page"; +say '

Alternate rendition of '.$ref; my ($canihas, $usage); my $minusage = $get{threshold} // 1; @@ -106,7 +109,7 @@ given ($get{usage} // 'wm') { my $ref = $canihas->{-title} || 'unknown'; $ref = showlink($ref, $_) for $canihas->{-site} || $canihas->{-source} || (); - $ref .= " $_" for $canihas->{-date} || (); + $ref =~ s/(?=>)/ title="updated $_"/ for $canihas->{-date} || (); print "\nwith $ref browser usage statistics"; } @@ -243,7 +246,7 @@ for my $browser (@browsers) { $span->[-1] eq $lastver ? () : '(development)', ), !defined $lastver && ' class="ex"', - showversions($lastver), + showversions($lastver // $span->[0]), ); } } @@ -511,5 +514,7 @@ sub showversions { - +