From 5764404f5c974436afc2fd62a1e381973713863d Mon Sep 17 00:00:00 2001 From: chunhtai <47866232+chunhtai@users.noreply.github.com> Date: Thu, 20 Apr 2023 11:23:06 -0700 Subject: [PATCH] fix localization typo for expansionTileExpandedHint (#125212) as title --- .../lib/src/l10n/generated_material_localizations.dart | 2 +- .../flutter_localizations/lib/src/l10n/material_en.arb | 2 +- .../test/material/translations_test.dart | 8 ++++++++ 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/packages/flutter_localizations/lib/src/l10n/generated_material_localizations.dart b/packages/flutter_localizations/lib/src/l10n/generated_material_localizations.dart index 516566ce9399..d57582959839 100644 --- a/packages/flutter_localizations/lib/src/l10n/generated_material_localizations.dart +++ b/packages/flutter_localizations/lib/src/l10n/generated_material_localizations.dart @@ -7327,7 +7327,7 @@ class MaterialLocalizationEn extends GlobalMaterialLocalizations { String get expansionTileCollapsedTapHint => 'Expand for more details'; @override - String get expansionTileExpandedHint => "double tap to collapse'"; + String get expansionTileExpandedHint => 'double tap to collapse'; @override String get expansionTileExpandedTapHint => 'Collapse'; diff --git a/packages/flutter_localizations/lib/src/l10n/material_en.arb b/packages/flutter_localizations/lib/src/l10n/material_en.arb index 18664a22e144..dc2e11e49b51 100644 --- a/packages/flutter_localizations/lib/src/l10n/material_en.arb +++ b/packages/flutter_localizations/lib/src/l10n/material_en.arb @@ -454,7 +454,7 @@ "description": "The verb which describes what happens when a collapsed ExpandIcon toggle button is pressed. This is used by TalkBack on Android to replace the default hint on the accessibility action. The verb will be concatenated with a prefix string which describes how to perform the action, which by default is 'double tap to activate'. In the case of US english, this would be 'double tap to expand.' The exact phrasing of the hint will vary based on locale" }, - "expansionTileExpandedHint": "double tap to collapse'", + "expansionTileExpandedHint": "double tap to collapse", "@expansionTileExpandedHint": { "description": "The verb which describes the tap action on an expanded ExpansionTile. This is used by VoiceOver on iOS and macOS. This string will be appended to the collapsedHint string which describes the action to be performed on an expanded ExpansionTile. In the case of US english, this would be 'Expanded\n double tap to collapse.' The exact phrasing of the hint will vary based on locale" }, diff --git a/packages/flutter_localizations/test/material/translations_test.dart b/packages/flutter_localizations/test/material/translations_test.dart index 4a4866ab727b..c91436203129 100644 --- a/packages/flutter_localizations/test/material/translations_test.dart +++ b/packages/flutter_localizations/test/material/translations_test.dart @@ -118,6 +118,14 @@ void main() { expect(localizations.lastPageTooltip, 'Ikhasi lokugcina'); }); + testWidgets('translations spot check expansionTileExpandedHint', (WidgetTester tester) async { + const Locale locale = Locale.fromSubtags(languageCode: 'en'); + expect(GlobalMaterialLocalizations.delegate.isSupported(locale), isTrue); + final MaterialLocalizations localizations = await GlobalMaterialLocalizations.delegate.load(locale); + expect(localizations, isA()); + expect(localizations.expansionTileExpandedHint, 'double tap to collapse'); + }); + testWidgets('spot check selectedRowCount translations', (WidgetTester tester) async { MaterialLocalizations localizations = await GlobalMaterialLocalizations.delegate.load(const Locale('en')); expect(localizations.selectedRowCountTitle(0), 'No items selected');