fix: #3634875 Use whole translatable strings per generator instead of putting the type label into a sentence

Issue: https://www.drupal.org/project/ai_media/issues/3634875

Each generator now declares its own complete strings as whole t() strings: field title, Generate button, progress message, mode switch label, and the "not offered" and "not set up" messages. AiMediaGeneration::noun() and the @what label placeholders are removed. Translators get whole sentences instead of a type label put into English, which languages with gender, case or articles cannot translate.

English output is unchanged. Generators from other modules get generic whole-sentence fallbacks. A Kernel test pins every string and shows an Arabic translation reaching the button and the switch.

Before (1.0.x): "Décrivez le image", the article cannot follow the noun. Varbase Starter, Gin, French, Image and SVG pages.

Before (1.0.x): Décrivez le image and Générer image on the Image page, Décrivez le SVG and Générer SVG on the SVG page

After: "Décrivez l'image" and "Générer une image" as whole French strings. Varbase Starter, Gin, French, Image and SVG pages.

After: Décrivez l'image and Générer une image on the Image page, Décrivez le SVG and Générer un SVG on the SVG page

AI-Generated: Yes

Checkpoints:

  • File an issue
  • Addition/Change/Update/Fix
  • Testing to ensure no regression
  • Automated unit testing coverage
  • Automated functional testing coverage
  • UX/UI designer responsibilities
  • Readability
  • Accessibility
  • Performance
  • Security
  • Developer Documentation
  • User Guide Documentation
  • Reviewed by human
  • Code review by maintainers
  • Full testing and approval
  • Credit contributors
  • Review with the product owner
  • Release notes snippet
  • Release

🤖 Generated with Claude Code

Edited by Rajab Natshah

Merge request reports

Loading
Loading