trWithOption method
Translates the string with optional customization.
name and defaultValue allow specifying translation context or fallback.
replace is a function to replace parts of the string.
applyNumber formats numbers in the string.
applyRtl applies right-to-left formatting if needed.
applyTranslator enables auto-translation when true.
Implementation
String trWithOption({
String? name,
String? defaultValue,
String Function(String)? replace,
bool applyNumber = false,
bool applyRtl = false,
bool applyTranslator = true,
}) {
return Translation.localize(
this,
name: name,
defaultValue: defaultValue,
replace: replace,
applyNumber: applyNumber,
applyRtl: applyRtl,
applyTranslator: applyTranslator,
);
}