)],
stylesheet => [qw( light dark circus mono red )],
data => [qw'writing-digits.inc.pl'],
+ raw => <<'EOT',
+<style>
+th:first-child { min-width: 10em }
+</style>
+EOT
});
:>
<div>
<:
-use Shiar_Sheet::FormatChar;
+use Shiar_Sheet::FormatChar 1.08;
my $glyphs = Shiar_Sheet::FormatChar->new;
unless (exists $get{v}) {
$glyphs->{unicode}--;
$glyphs->{style} = 'univer';
}
-my $scriptname = do 'writing-script.inc.pl';
-$_ = qq{<a href="/latin">$_</a>} for $scriptname->{latn} || ();
+my $scriptname = eval { Data('writing-script') };
+$_ = showlink($_, "/latin") for $scriptname->{latn} || ();
-my @table = do "writing-digits.inc.pl";
-die "Table data not found: $_\n" for $@ || $! || ();
+my $table = Data("writing-digits");
-print $glyphs->table([map {
- ref $_ eq 'ARRAY' ? @{$_} : map { ".>$_" }
- $scriptname->{"digits_$_"} || $scriptname->{$_} || $_
-} @table]);
+sub printtable {
+ say '<div class=section>', $glyphs->tabletag;
+ for my $id (@_) {
+ my $info = $table->{$id};
+ my $title = $info->{title} // $scriptname->{$id} || $id;
+ print $glyphs->row([ ".>$title", @{$info->{list}} ]);
+ }
+ say '</table></div>';
+}
-:></div>
+printtable(@{ $table->{$_} }) for @{ $table->{default} };
-<hr>
+say "</div>\n";
+say for '<hr/>', $glyphs->legend;