# Based on Mojolicious::Plugin::Number::Commify
my $THOUSAND_SEP_RE = qr/(
  ^[-+]?           # beginning of number.
  \d+?             # first digits before first comma
  (?=              # followed by, (but not included in the match) :
    (?>(?:\d{3})+) # some positive multiple of three digits.
    (?!\d)         # an *exact* multiple, not x * 3 + 1 or whatever.
  )|               # or:
  \G\d{3}          # after the last group, get three digits
  (?=\d)           # but they have to have more digits after them.
)/x;

{
  _ => sub { $_->locale },
  de => {
    numf => sub {
      shift;
      my %val = @_;
      my $num = $val{number} or return 0;
      $num =~ s/$THOUSAND_SEP_RE/$1\./g;
      return $num;
    },
    about => 'Über KorAP',
    login => 'Anmelden',
    logout => 'Abmelden',
    register => 'Registrieren',
    pwdforgotten => 'Password vergessen?',
    searchjob => '»<%== $q %>« <% if (param("collection-name")) { %>in »<%== param("collection-name") %>« <% } elsif (param("collection")) { %>im definierten Korpus <% } %>mit <%== loc("QL_" . $ql, "unbekannter Anfragesprache") %>',
    searchtitle => 'KorAP: Finde <%== loc("searchjob") %>',
    searchplaceholder => 'Finde ...',
    go => 'Los!',
    in => 'in',
    by => 'von',
    pwd => 'Passwort',
    email => 'Email',
    userormail => 'Benutzername oder Email',
    with => 'mit',
    glimpse => {
      desc => 'Zeige nur die ersten Treffer in beliebiger Reihenfolge'
    },
    activateJS => 'Für den vollen Funktionsumfang aktivieren Sie bitte JavaScript!',
    faq => 'Häufige Fragen',
    tutorial => 'Einführung',
    pubOn => 'veröffentlicht am',
    matchCount => 'Treffer',
    noMatches => 'Es wurden keine Treffer für <%== loc("searchjob") %> gefunden.',
    notFound => '404 - Seite nicht gefunden',
    jsFile => 'kalamar-<%= $Kalamar::VERSION %>-de.js',
    underConstruction => 'In Vorbereitung!',
    loginExplanation => 'Anmeldung mit einem registrierten Cosmas-II-Konto',
    korap => {
      -short => 'KorAP',
      desc => 'KorAP - Korpusanalyseplattform der nächsten Generation',
      overview => 'KorAP - Übersicht',
    },
    Auth => {
      loginSuccess => 'Anmeldung erfolgreich',
      loginFail => 'Anmeldung fehlgeschlagen',
      logoutSuccess => 'Abmeldung erfolgreich',
      logoutFail => 'Abmeldung fehlgeschlagen'
    },
    Template => {
      intro => 'de/intro',
      doc => {
        ql => {
          'poliqarp-plus' => 'de/doc/ql/poliqarp-plus'
        },
        api => {
          'koralquery' => 'de/doc/api/koralquery'
        },
        data => {
          'annotation' => 'de/doc/data/annotation'
        },
        korap => {
          'kalamar' => 'de/doc/korap/kalamar',
          'karang' => 'de/doc/korap/karang',
          'koral' => 'de/doc/korap/koral',
          'krill' => 'de/doc/korap/krill',
          'kustvakt' => 'de/doc/korap/kustvakt'
        }
      }
    },
    Nav => {
      'ql' => 'Anfragesprachen',
      '#segments' => 'Einfache Segmente',
      '#complex' => 'Komplexe Segmente',
      '#spans' => 'Span Segmente',
      '#paradigmatic-operators' => 'Paradigmatische Operatoren',
      '#syntagmatic-operators' => 'Syntagmatische Operatoren',
      '#class-operators' => 'Klassen Operatoren',
      'regexp' => 'Reguläre Ausdrücke',
      'data' => 'Daten',
      'corpus' => 'Korpora',
      'annotation' => 'Annotationen',
      '#default-foundries' => 'Standard Foundries',
      'faq' => 'Häufig gestellte Fragen'
    }
  },
  -en => {
    jsFile => 'kalamar-<%= $Kalamar::VERSION %>-en.js',
    numf => sub {
      shift;
      my %val = @_;
      my $num = $val{number} or return 0;
      $num =~ s/$THOUSAND_SEP_RE/$1\,/g;
      return $num;
    },
    about => 'About KorAP',
    login => 'Login',
    logout => 'Logout',
    register => 'Register',
    pwdforgotten => 'Password forgotten?',
    go => 'Go!',
    searchjob => '»<%== $q %>« <% if (param("collection-name")) { %>in »<%== param("collection-name") %>« <% } elsif (param("collection")) { %>in the defined corpus <% } %>with <%== loc("QL_". $ql, "unknown query language") %>',
    searchtitle => 'KorAP: Find <%== loc("searchjob") %>',
    searchplaceholder => 'Find ...',
    in => 'in',
    by => 'by',
    pwd => 'Password',
    email => 'Email',
    userormail => 'Username or Email',
    with => 'with',
    pubOn => 'published on',
    matchCount => '<%= quant($found, "match", "matches") %>',
    noMatches => 'There were no matches found for <%== loc("searchjob") %>.',
    notFound => '404 - Page not found',
    glimpse => {
      -short => 'Glimpse',
      desc => 'Just show the first matches in arbitrary order'
    },
    activateJS => 'To make use of all features, please activate JavaScript!',
    faq => 'F.A.Q.',
    underConstruction => 'Under Construction!',
    loginExplanation => 'Login with a registered Cosmas-II account',
    tutorial => 'Tutorial',
    korap => {
      -short => 'KorAP',
      desc => 'KorAP - Corpus Analysis Platform',
      overview => 'KorAP - Overview'
    },
    QL => {
      poliqarp => 'Poliqarp',
      cosmas2 => 'Cosmas II',
      annis => 'Annis QL',
      cql => 'CQL v1.2',
      fcsql => 'FCSQL'
    },
    Auth => {
      loginSuccess => 'Login successful',
      loginFail => 'Access denied',
      logoutSuccess => 'Logout successful',
      logoutFail => 'Logout failed'
    },
    Template => {
      intro => 'intro',
      doc => {
        ql => {
          'poliqarp-plus' => 'doc/ql/poliqarp-plus'
        },
        api => {
          'koralquery' => 'doc/api/koralquery'
        },
        data => {
          'annotation' => 'doc/data/annotation'
        },
        korap => {
          'kalamar' => 'doc/korap/kalamar',
          'karang' => 'doc/korap/karang',
          'koral' => 'doc/korap/koral',
          'krill' => 'doc/korap/krill',
          'kustvakt' => 'doc/korap/kustvakt'
        }
      }
    },
    Nav => {
      'ql' => 'Query Languages',
      '#segments' => 'Simple Segments',
      '#complex' => 'Complex Segments',
      '#spans' => 'Span Segments',
      '#paradigmatic-operators' => 'Paradigmatic Operators',
      '#syntagmatic-operators' => 'Syntagmatic Operators',
      '#class-operators' => 'Class Operators',
      'regexp' => 'Regular Expressions',
      'data' => 'Data',
      'corpus' => 'Corpora',
      'annotation' => 'Annotations',
      '#default-foundries' => 'Default Foundries',
      'faq' => 'F.A.Q.'
    }
  }
};
