blob: e2f3f6baefc9c5c83fa9300586e4cee4fdbf519f [file] [log] [blame]
Akroncddd1642015-06-10 21:31:53 +02001# Based on Mojolicious::Plugin::Number::Commify
2my $THOUSAND_SEP_RE = qr/(
3 ^[-+]? # beginning of number.
4 \d+? # first digits before first comma
5 (?= # followed by, (but not included in the match) :
6 (?>(?:\d{3})+) # some positive multiple of three digits.
7 (?!\d) # an *exact* multiple, not x * 3 + 1 or whatever.
8 )| # or:
9 \G\d{3} # after the last group, get three digits
10 (?=\d) # but they have to have more digits after them.
11)/x;
12
13{
14 _ => sub { $_->locale },
15 de => {
16 numf => sub {
17 shift;
18 my %val = @_;
19 my $num = $val{number} or return 0;
20 $num =~ s/$THOUSAND_SEP_RE/$1\./g;
21 return $num;
22 },
23 about => 'Über KorAP',
24 login => 'Anmelden',
Akron43a73092016-02-11 21:52:27 +010025 searchjob => '»<%== $q %>« <% if (param("collection-name")) { %>in »<%== param("collection-name") %>«<% } elsif (param("collection")) { %>im definierten Korpus<% } %> mit <%== loc("QL_" . $ql, "unbekannter Anfragesprache") %>',
Akron656c5d92015-11-13 21:17:03 +010026 searchtitle => 'KorAP: Finde <%== loc("searchjob") %>',
Akroncddd1642015-06-10 21:31:53 +020027 searchplaceholder => 'Finde ...',
28 go => 'Los!',
29 in => 'in',
30 by => 'von',
31 with => 'mit',
32 glimpse => {
33 -short => 'Stichprobe',
34 desc => 'Zeige nur die ersten Treffer in beliebiger Reihenfolge'
35 },
36 faq => 'Häufige Fragen',
37 tutorial => 'Einführung',
38 pubOn => 'veröffentlicht am',
39 matchCount => 'Treffer',
Akron656c5d92015-11-13 21:17:03 +010040 noMatches => 'Es wurden keine Treffer für <%== loc("searchjob") %> gefunden.',
Akroncddd1642015-06-10 21:31:53 +020041 notFound => '404 - Seite nicht gefunden',
42 jsFile => 'kalamar-<%= $Kalamar::VERSION %>-de.js',
43 underConstruction => 'In Vorbereitung!',
44 korap => {
45 -short => 'KorAP',
46 desc => 'KorAP - Korpusanalyseplattform der nächsten Generation',
47 overview => 'KorAP - Übersicht',
48 },
49 template => {
50 intro => 'de/intro'
51 }
52 },
53 -en => {
Akron43a73092016-02-11 21:52:27 +010054 jsFile => 'kalamar-<%= $Kalamar::VERSION %>-en.js',
Akroncddd1642015-06-10 21:31:53 +020055 numf => sub {
56 shift;
57 my %val = @_;
58 my $num = $val{number} or return 0;
59 $num =~ s/$THOUSAND_SEP_RE/$1\,/g;
60 return $num;
61 },
62 about => 'About KorAP',
63 login => 'Login',
64 go => 'Go!',
Akron43a73092016-02-11 21:52:27 +010065 searchjob => '»<%== $q %>« <% if (param("collection-name")) { %>in »<%== param("collection-name") %>«<% } elsif (param("collection")) { %>in the defined corpus<% } %> with <%== loc("QL_". $ql, "unknown query language") %>',
Akron656c5d92015-11-13 21:17:03 +010066 searchtitle => 'KorAP: Find <%== loc("searchjob") %>',
Akroncddd1642015-06-10 21:31:53 +020067 searchplaceholder => 'Find ...',
68 in => 'in',
69 by => 'by',
70 with => 'with',
71 pubOn => 'published on',
72 matchCount => '<%= num($found, "match", "matches") %>',
Akron656c5d92015-11-13 21:17:03 +010073 noMatches => 'There were no matches found for <%== loc("searchjob") %>.',
Akroncddd1642015-06-10 21:31:53 +020074 notFound => '404 - Page not found',
75 glimpse => {
76 -short => 'Sample',
77 desc => 'Just show the first matches in arbitrary order'
78 },
79 faq => 'F.A.Q.',
80 underConstruction => 'Under Construction!',
81 tutorial => 'Tutorial',
82 korap => {
83 -short => 'KorAP',
84 desc => 'KorAP - Corpus Analysis Platform',
85 overview => 'KorAP - Overview'
Akron7716f012015-07-01 20:38:32 +020086 },
87 QL => {
88 poliqarp => 'Poliqarp',
89 cosmas2 => 'Cosmas II',
90 annis => 'Annis QL',
91 cql => 'CQL v1.2'
Akroncddd1642015-06-10 21:31:53 +020092 }
93 }
94};