Skip to content

[BUG] - Hardcoded AppBar title in TextFitEditor prevents proper localization #348

@Aryan-Singla

Description

@Aryan-Singla

Issue Description:
Currently, in the TextFitEditor screen, the AppBar title is hardcoded as a constant string 'Text Editor'. This string is not part of the project's localization system (app_en.arb), which means it cannot be translated into other languages, creating a gap in the app's internationalization (i18n) support.

Steps to Reproduce:

  • Open the application.
  • Select any display device to go to the Editor.
  • Tap on the Text icon in the bottom menu to open TextFitEditor.
  • Observe the AppBar title; it remains "Text Editor" regardless of the system language settings.

Expected Behavior:
The AppBar title should be dynamically fetched from the localization system using AppLocalizations.of(context). This would allow the screen title to be translated into different languages based on the user's active locale.

Actual Behavior:
The title 'Text Editor' is hardcoded at line 106 in lib/view/text_fit_editor.dart, making it static and non-translatable.

Suggested Fix:

  • Add a new localization key textEditorTitle in lib/l10n/app_en.arb.
  • Update TextFitEditor to utilize this key via AppLocalizations.
  • Add a widget test to ensure UI title persistence and localization accuracy.

Impact:
This leads to an inconsistent and non-localized user experience for non-English speakers, which is a major accessibility gap in a global open-source project.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions