Trans extension

on

Properties

tr String

Available on String, provided by the Trans extension

no setter

Methods

trArgs([List<String> args = const []]) String

Available on String, provided by the Trans extension

trParams([Map<String, String> params = const {}]) String

Available on String, provided by the Trans extension

Translates this key with tr, then replaces every @name placeholder in the result with the value mapped to name in params.
trPlural([String? pluralKey, int? i, List<String> args = const []]) String

Available on String, provided by the Trans extension

trPluralCases(Map<PluralCase, String> caseKeys, int count, [List<String> args = const []]) String

Available on String, provided by the Trans extension

Translates the plural form of this key that matches count, supporting every CLDR plural category — unlike trPlural, which only distinguishes count == 1 from everything else.
trPluralCasesParams(Map<PluralCase, String> caseKeys, int count, [Map<String, String> params = const {}]) String

Available on String, provided by the Trans extension

Translates the plural form of this key that matches count, like trPluralCases, but substitutes named @placeholder parameters via trParams and params instead of positional %s arguments.
trPluralParams([String? pluralKey, int? i, Map<String, String> params = const {}]) String

Available on String, provided by the Trans extension