From: Mischa POSLAWSKY Date: Tue, 7 May 2024 17:06:27 +0000 (+0200) Subject: keyboard/altgr/index: strip mode links from sample keys again X-Git-Tag: v1.19~7 X-Git-Url: http://git.shiar.net/sheet.git/commitdiff_plain/0e222da060151bc6aa6d5c82962e5e15cfa12070?ds=sidebyside keyboard/altgr/index: strip mode links from sample keys again Broken since commit v1.18-21-gc4ca0bd3e9 (2024-04-23) [keyboard: recombine translations in include syntax]. --- diff --git a/keyboard/altgr/index.inc.plp b/keyboard/altgr/index.inc.plp index a74e012..67249ec 100644 --- a/keyboard/altgr/index.inc.plp +++ b/keyboard/altgr/index.inc.plp @@ -177,8 +177,12 @@ for my $inc (@incs) { my $keydata = Data("$dirbase/$inc.eng"); Shiar_Sheet::Keyboard->new($keydata) }) { - $keys->print_key('', $_, ($keys->{def}{''}{$_} // ['ni']) =~ s/ mode\S*//r) - for @sample; + for my $c (@sample) { + my $def = $keys->{def}{''}{$c} // []; + $def->[0] //= 'ni'; + $def->[0] =~ s/ mode\S*//; + $keys->print_key('', $c, $def); + } } say ''; }